HeroModifiers will fail when a nested `when` modifier exist
cloxnu opened this issue · comments
Sidney Liu commented
view.heroModifiers = [
.when({ $0.isMatched && $0.matchedView?.alpha != 0 && $0.view.alpha != 0 }, [
.forceNonFade,
.when({ ($0.isAppearing && $0.isPresenting || !$0.isAppearing && !$0.isPresenting) }, .opacity(0)),
]),
]
Look at this, .opacity(0)
will never be added.