An elegant presentation API for constructing bottom sheet modals
PanModal
PanModal is an elegant and highly customizable presentation API for constructing bottom sheet modals on iOS.
}
### Updates at Runtime
Values are stored during presentation, so when adjusting at runtime you should call `panModalSetNeedsLayoutUpdate()`
```swift
func viewDidLoad() {
hasLoaded = true
panModalSetNeedsLayoutUpdate()
panModalTransition(to: .shortForm)
}
var shortFormHeight: PanModalHeight {
if hasLoaded {
return .contentHeight(200)
}
return .maxHeight
}
Sample App
Check out the Sample App for more complex configurations of PanModalPresentable
, including navigation controllers and stacked modals.
Documentation
Option + click on any of PanModal's methods or notes for detailed documentation.