Skip to content

Review 5191

Cindy Zhang edited this page Aug 23, 2026 · 1 revision

#5191 — fix: Escape dismisses only the top-most overlay for Lightbox/MobileNav

HelloOjasMutreja · open · view on GitHub

Verdict: comment

These records predate the Review Presentation format for the most part, so the problem/solution/API/theme-target/breaking slots are only filled where the review itself carried them. Reviews from 2026-08-23 on use the full template.

The review · 2026-08-19

Thanks for jumping on this so fast — and sorry, the issue should have told you: #4881 is open and replaces hasActiveFocusTrapEscape() with a layer stack that routes each Escape to the top-most layer. Eight families already register with it. Building on the boolean means this gets undone when that lands, which is on me for not saying so.

The shape once #4881 is in is useLayerDismissal({...}) per component, the way Dialog and Drawer do it — much smaller than what you have here. Happy to ping you when it merges if you want to re-target it.

Your InfoTip finding is separate and real: stopPropagation() without preventDefault(). Worth keeping either way.

[Reviewed by Robohands and the maintainer]

Clone this wiki locally