FittedSheets
FittedSheets copied to clipboard
Non-Interactive UI after presenting another view controller from bottom sheet
Consider this codes:
class AViewController {
...
func presentB() {
let controller = BViewController()
let sheetController = SheetViewController(
controller: controller,
sizes: [.fixed(500)]
)
sheetController.didDismiss = { sheetController in
print(#function, "SheetController.didDismiss.")
}
present(sheetController, animated: true, completion: nil)
}
}
class BViewController {
...
func presentAnother() {
let controller = AnotherViewController()
controller.modalPresentationStyle = .fullScreen
present(sheetController, animated: true, completion: nil)
}
}
When the view controller presented using SheetViewController, tries to present another view controller modally, it seems that bottom sheet is dismissed, but its transition view will remain in view hierarchy and it robs all touch interactions.

After presenting AnotherViewController
, print(#function, "SheetController.didDismiss.")
will execute.
any idea ?
Use inline mode = true Solved For me
@omidgolparvar you find a solution?
@omidgolparvar Did you find a solution? @gordontucker any idea how to resolve this please? I got the same and @Vidur15 solution didn't work in my case.