stinsen
stinsen copied to clipboard
[Question] @Root animation
UIKit based Coordinators offered the ability to apply transition effects when replacing a root view i.e. with RxFlow you could just do this:
Flows.use(onboardingFlow, when: .ready) { [unowned self] flowRoot in
UIView.transition(with: self.rootWindow, duration: 0.1, options: .transitionCrossDissolve, animations: {}, completion: nil)
self.rootWindow.rootViewController = flowRoot
}
or with XCoordinator you can do:
.presentFullScreen(TabCoordinator().strongRouter, animation: .fade)
Both are used to replace root views, not for a modal transition.
It would be cool if there would be basic support for this in Stinsen like:
@Root(.fade) var start = makeStart
Would that be possible? I honestly didn't find a location in the code where a concrete view switch is happening which could be animated.
Sounds like something that might be a good addition. I'm thinking of adding the possibility of custom push/modals as well (for instance, if you want to push to an alert, a bottom sheet or something similar), that might be a related problem 🙂
Sounds like something that might be a good addition. I'm thinking of adding the possibility of custom push/modals as well (for instance, if you want to push to an alert, a bottom sheet or something similar), that might be a related problem 🙂
This would be an extremely helpful addition! This is the last type of navigation that we're having to support manually.
@rundfunk47 Meanwhile is there any workaround now to change modal transition animation ?
May be we can specify .transition(.opacity)
to some view?