@@ -42,66 +42,81 @@ public enum ListAccessoryVisibility {
4242public struct HiddenViewModifier < Content: View > {
4343 let content : Content
4444
45+ /// Apply a variable blur overlay to a view.
46+ public func variableBlur( maxRadius: CGFloat , mask: Image , opaque: Bool ) -> some View {
47+ content. variableBlur ( maxRadius: maxRadius, mask: mask, opaque: opaque)
48+ }
49+
50+ /// Change the toolbar behavior when the window is fullscreen.
51+ /// `.showsWithWindow` is the default behavior. `.showsWithMenuBar` will hide the toolbar when fullscreen.
4552 public func fullScreenToolbarBehavior( _ behavior: FullScreenToolbarBehavior ) -> some View {
4653 content. fullScreenToolbarBehavior ( behavior. toOriginal)
4754 }
4855
56+ /// Get a trigger when a row has been selected by the user, and gets clicked again.
57+ /// This differs from a TapGesture, as there is no time limit between the clicks.
58+ public func onReselect( enabled: Bool , perform: ( ( ) -> ( ) ) ? ) -> some View {
59+ content. onReselect ( isEnabled: enabled, perform: perform)
60+ }
61+
62+ /// Adjust the padding around a Form with FormStyle `.grouped`
4963 public func formInsets( _ edges: Edge . Set , _ value: CGFloat ) -> some View {
5064 content. formInsets ( edges, value)
5165 }
5266
67+ /// Adjust the padding around a Form with FormStyle `.grouped`
5368 public func formInsets( _ edges: Edge . Set , _ value: EdgeInsets ) -> some View {
5469 content. formInsets ( edges, value)
5570 }
5671
57- public func onReselect( enabled: Bool , perform: ( ( ) -> ( ) ) ? ) -> some View {
58- content. onReselect ( isEnabled: enabled, perform: perform)
72+ /// Adjust the inset of an individual row in a Form with FormStyle `.grouped`
73+ public func formRowInsets( _ insets: EdgeInsets ? ) -> some View {
74+ content. formRowInsets ( insets)
5975 }
6076
61- public func variableBlur( maxRadius: CGFloat , mask: Image , opaque: Bool ) -> some View {
62- content. variableBlur ( maxRadius: maxRadius, mask: mask, opaque: opaque)
77+ /// Set the indentation level of a Form row.
78+ public func formRowIndentationLevel( _ level: Int ? ) -> some View {
79+ content. formRowIndentationLevel ( level)
6380 }
6481
82+ /// Change the background color of a Form.
6583 public func formBackground< S: ShapeStyle > ( _ shape: S ? ) -> some View {
6684 content. formBackground ( shape)
6785 }
6886
87+ /// Change the background color of an individual row in a Form.
6988 public func formRowBackground< S: ShapeStyle > ( _ shape: S ? ) -> some View {
7089 content. formRowBackground ( shape)
7190 }
7291
73- public func formInfoAction( action: @escaping ( ) -> Void ) -> some View {
74- content. formInfoAction ( action: action)
75- }
76-
92+ /// Change the background color of a section.
7793 public func sectionBackground( _ visibility: Visibility ) -> some View {
7894 content. sectionBackground ( visibility)
7995 }
8096
81- public func formRowInfoVisibility( _ visibility: Visibility ) -> some View {
82- content. formRowInfoVisibility ( visibility)
97+ /// Add a trailing info icon to a Form row.
98+ /// As an example, see system bluetooth settings.
99+ public func formInfoAction( action: @escaping ( ) -> Void ) -> some View {
100+ content. formInfoAction ( action: action)
83101 }
84102
85- public func formRowIndentationLevel( _ level: Int ? ) -> some View {
86- content. formRowIndentationLevel ( level)
103+ /// Change the visibility of the trailing info icon in a Form row.
104+ public func formRowInfoVisibility( _ visibility: Visibility ) -> some View {
105+ content. formRowInfoVisibility ( visibility)
87106 }
88107
108+ /// Add a trailing Form row view, which becomes visible when hovered over the row.
109+ /// As an example, see system wifi settings.
89110 public func formAccessory( @ViewBuilder accessories: ( ) -> some View ) -> some View {
90111 content. formAccessory ( accessories: accessories)
91112 }
92113
93- public func formRowInsets( _ insets: EdgeInsets ? ) -> some View {
94- content. formRowInsets ( insets)
95- }
96-
114+ /// Change the visibility of the trailing Form row view.
97115 public func formAccessoryVisibility( _ visibility: Visibility ) -> some View {
98116 content. formAccessoryVisibility ( visibility)
99117 }
100118
101- public func listReorderControlVisibility( _ visibility: ListAccessoryVisibility ) -> some View {
102- content. listReorderControlVisibility ( visibility. toOriginal)
103- }
104-
119+ /// Add a bottom row to a Form.
105120 public func bottomBar( @ViewBuilder content: ( ) -> some View ) -> some View {
106121 self . content. bottomBar ( content: content)
107122 }
@@ -111,4 +126,8 @@ public struct HiddenViewModifier<Content: View> {
111126 self . content. accessoryBar ( content: content)
112127 }
113128
129+ /// Control the visibility of the list reorder controls. Untested.
130+ public func listReorderControlVisibility( _ visibility: ListAccessoryVisibility ) -> some View {
131+ content. listReorderControlVisibility ( visibility. toOriginal)
132+ }
114133}
0 commit comments