Closed nataliq closed 5 years ago
I've added a new file to presentation and it the test-iOS
on Circle-CI is failing due to
Build input file cannot be found: '/System/Volumes/Data/Users/vasil-nunev/Presentation/Presentation/CustomAdaptivePresentationDelegate.swift' (in target 'Presentation')
Anyone knows how to fix this?
What's new: On iOS 13 we have new default modal presentation called Sheet. The modal Sheets can be dismissed by swiping them down, and in doing so, Presentation framework wasn't disposing the bag of its presentation. This PR makes Presentation's view controller to conform to
UIAdaptivePresentationDelegate
that will handle actions for when the view attempt's, will and did dismiss and disposing the bag appropriately when the view dismisses.In addition, it adds functionality for the developer to pass a block of code when the view attempts to dismiss through a signal in
CustomAdaptivePresentationDelegate
like thisThe
didAttemptToDismissSignal
will fire only if the view controller that's presented has.isModalInPresentation = true
and then the developer can execute a block with what they want to happen when the user attempt to dismiss (optional)This PR also includes a temp solution for #40
More info: #41