We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1eb7663 commit f56f3f0Copy full SHA for f56f3f0
Sources/AutoResizingSheet/ViewModifiers/AutoResizingSheetViewModifier.swift
@@ -15,12 +15,10 @@ struct AutoResizingSheetViewModifier<SheetContent: View>: ViewModifier {
15
_isPresented = isPresented
16
self.configuration = configuration
17
self.sheetContent = sheetContent as () -> SheetContent
18
- selectedDetent = .medium
19
- detents = []
20
21
let initialDetent: PresentationDetent = .medium
22
- selectedDetent = initialDetent
23
- detents = [initialDetent]
+ _selectedDetent = State(initialValue: initialDetent)
+ _detents = State(initialValue: [initialDetent])
24
if configuration.extendableToFullSize {
25
detents.insert(.large)
26
}
0 commit comments