fix(message): unmount faded toasts (they block clicks), allow node 21+ - #4
Open
MaxAdams98 wants to merge 1 commit into
Open
fix(message): unmount faded toasts (they block clicks), allow node 21+#4MaxAdams98 wants to merge 1 commit into
MaxAdams98 wants to merge 1 commit into
Conversation
The auto-hide timeout only set visible=false, leaving the toast mounted with pointer-events-auto inside the fixed z-[101] wrapper — an invisible box that swallowed clicks on anything underneath (e.g. a sticky header) until refresh. Reuse hide() so the toast unmounts after its fade, matching the close button. Also relax engines to >=18: apps are running node 22/24 against this fine. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Two small fixes found while building allproof-web on nitro:
Toast pointer-events bug — the auto-hide timeout in
message.tsxonly setsvisible=falseand never clearsmessageObject, so the faded toast stays mounted withpointer-events-autoinside thefixed inset-0 z-[101]wrapper. That leaves an invisible ~350px box over the page (top-center placements sit exactly over a sticky header) which swallows clicks until a refresh. Only the manual close button unmounted it. Fix: the timeout now callshide(), which unmounts the toast 250ms after the fade — same path as the close button.Engines — relaxed
"node": ">=18 <21"to">=18"; apps are running this on node 22/24 without issues and the cap only produces install warnings.