Repository navigation
feat: animate overlay exit animations - #651
Open
Denny09310 wants to merge 8 commits into
Open
Denny09310 wants to merge 8 commits into
Denny09310 wants to merge 8 commits into
Conversation
ExitAnimationGate owns the closed-but-still-mounted phase every overlay needs: the content registers an exit animation, the owner renders while IsPresent is set, and a reopen or a newer close supersedes an exit still in flight. It is composition rather than a base class, because some owners are contexts and some are components. OverlayExit wraps the waitForExit interop call together with its JS-unavailable fallback, and animation.js is the one implementation of the wait itself, now imported by positioning.js rather than duplicated there. DialogContext moves onto the gate with no behaviour change: the same registrations, supersede rules and completion notification, so Dialog keeps the enter/exit API and lifetime PR blazorblueprintui#615 introduced.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Rebases PR #584 onto
upstream/developand extends PR #615's Dialog exit-animation infrastructure toSheet, Drawer, ContextMenu, NavigationMenu and Toast, reusing the shared
ExitAnimationGate/OverlayExit/animation.jswaitForExitmechanism. Also addsanimation-fill-mode: bothgloballyand a fading native
<dialog>backdrop. Dialog's own exit animations, presets, keyframes, duration,reduced-motion support and native focus/modal behaviour are preserved unchanged.
Type of Change
Testing Checklist
Related Issues
Extends #615. Rebase of #584.
Changes
data-state="closed"until the exit animation completes; reopen mid-exit cancels the close; unmounthappens only after the animation; multiple close requests start a single exit wait.
ToastData.IsDismissing+BbToast.OnDismissedcallback; providerHandleDismissisidempotent while dismissing; removal only after the exit plays.
animation-fill-mode: bothon[data-state="open"], [data-state="closed"]; native<dialog>backdrop fades out (dialog[data-state]::backdroptransition, transparent when closed).instead of hanging.
OverlayExitFallbackTests+OverlayAnimationCssTestsBbToast.OnDismissed. All 1288 C# and 13 JS tests pass.