We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents ee0a4c6 + c4f0c1b commit 53b9a5aCopy full SHA for 53b9a5a
Sources/PopupView/PopupView.swift
@@ -451,10 +451,12 @@ public struct Popup<PopupContent: View>: ViewModifier {
451
}
452
453
.onChange(of: sheetContentRect.size) { sheetContentRect in
454
+ #if os(iOS)
455
// check if scrollView has already calculated its height, otherwise sheetContentRect is already non-zero but yet incorrect
456
if case .scroll(_) = type, scrollViewRect.height == 0 {
457
return
458
459
+ #endif
460
positionIsCalculatedCallback()
461
if shouldShowContent.wrappedValue { // already displayed but the size has changed
462
actualCurrentOffset = targetCurrentOffset
0 commit comments