File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -41,9 +41,12 @@ public enum CollectionViewLayouts {
41
41
}
42
42
43
43
public struct List < Separator: View > : CollectionViewLayoutType {
44
+
44
45
45
46
public let direction : CollectionViewListDirection
46
47
48
+ public var showsIndicators : Bool = false
49
+
47
50
public var contentPadding : EdgeInsets
48
51
49
52
private let separator : Separator
@@ -83,12 +86,19 @@ public enum CollectionViewLayouts {
83
86
84
87
return self
85
88
}
86
-
89
+
90
+ public consuming func showsIndicators( _ showsIndicators: Bool ) -> Self {
91
+
92
+ self . showsIndicators = showsIndicators
93
+
94
+ return self
95
+ }
96
+
87
97
public func body( content: Content ) -> some View {
88
98
switch direction {
89
99
case . vertical:
90
100
91
- ScrollView ( . vertical) {
101
+ ScrollView ( . vertical, showsIndicators : showsIndicators ) {
92
102
93
103
if separator is EmptyView {
94
104
LazyVStack {
@@ -114,7 +124,7 @@ public enum CollectionViewLayouts {
114
124
115
125
case . horizontal:
116
126
117
- ScrollView ( . horizontal) {
127
+ ScrollView ( . horizontal, showsIndicators : showsIndicators ) {
118
128
119
129
if separator is EmptyView {
120
130
LazyHStack {
You can’t perform that action at this time.
0 commit comments