Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix bounce when expanding sheet on ios (#5627)

authored by

Hailey and committed by
GitHub
686dfa5f 0ebf6366

+6 -3
+5 -2
modules/bottom-sheet/ios/SheetView.swift
··· 66 66 } 67 67 } 68 68 } 69 + private var prevLayoutDetentIdentifier: UISheetPresentationController.Detent.Identifier? 69 70 70 71 // MARK: - Lifecycle 71 72 ··· 143 144 } 144 145 145 146 func updateLayout() { 146 - if let contentHeight = self.innerView?.subviews.first?.frame.size.height { 147 + if self.prevLayoutDetentIdentifier == self.selectedDetentIdentifier, 148 + let contentHeight = self.innerView?.subviews.first?.frame.size.height { 147 149 self.sheetVc?.updateDetents(contentHeight: self.clampHeight(contentHeight), 148 - preventExpansion: self.preventExpansion) 150 + preventExpansion: self.preventExpansion) 149 151 self.selectedDetentIdentifier = self.sheetVc?.getCurrentDetentIdentifier() 150 152 } 153 + self.prevLayoutDetentIdentifier = self.selectedDetentIdentifier 151 154 } 152 155 153 156 func dismiss() {
+1 -1
modules/bottom-sheet/ios/SheetViewController.swift
··· 62 62 } 63 63 } 64 64 } 65 - 65 + 66 66 func getCurrentDetentIdentifier() -> UISheetPresentationController.Detent.Identifier? { 67 67 guard let sheet = self.sheetPresentationController else { 68 68 return nil