Skip to content

Commit 33d2d34

Browse files
committed
Tweak the exammple
1 parent 9143eb4 commit 33d2d34

1 file changed

Lines changed: 5 additions & 6 deletions

File tree

Example/Example (Shared)/ContentView.swift

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ struct ContentView: View {
1818
var body: some View {
1919
ScrollView {
2020
VStack {
21-
ExampleSection("Resizing automatically (Default)") {
21+
ExampleSection("Self-sizing automatically (Default)") {
2222
ResizingTextView(text: $text1)
2323
}
2424

@@ -58,12 +58,13 @@ struct ContentView: View {
5858
)
5959
}
6060

61-
ExampleSection("Selectable, uneditable, non-greedy short label") {
61+
ExampleSection("Selectable, uneditable, non greedy") {
6262
ResizingTextView(
6363
text: .constant("Lorem ipsum"),
6464
isEditable: false,
6565
hasGreedyWidth: false
6666
)
67+
.background(.yellow)
6768
}
6869
#if os(iOS)
6970
ExampleSection("No autocapitalization") {
@@ -111,8 +112,6 @@ private struct ExampleSection<Content: View>: View {
111112
}
112113
}
113114

114-
struct ContentView_Previews: PreviewProvider {
115-
static var previews: some View {
116-
ContentView()
117-
}
115+
#Preview {
116+
ContentView()
118117
}

0 commit comments

Comments
 (0)