mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-04-07 19:25:52 +00:00
iOS16+ detents
This commit is contained in:
@@ -8,10 +8,11 @@ extension View {
|
||||
@ViewBuilder content: @escaping () -> Content
|
||||
) -> some View {
|
||||
if #available(iOS 16, *) {
|
||||
sheet(isPresented: isPresented, content: content)
|
||||
.presentationDetents(
|
||||
Set(detents.compactMap { presentationDetent(detent:$0) })
|
||||
sheet(isPresented: isPresented) {
|
||||
content().presentationDetents(
|
||||
Set(detents.compactMap { presentationDetent(detent: $0) })
|
||||
)
|
||||
}
|
||||
} else {
|
||||
ZStack {
|
||||
SheetPresenter(
|
||||
|
||||
Reference in New Issue
Block a user