ScreenLayer
Defined in: src/dom/screen.ts:18
A floating layer stacked above the normal widget tree — a modal dialog or a non-modal sticky panel. Layers share the Screen.overlays paint list but add focus and key-routing semantics on top of it.
Properties
Section titled “Properties”closeOnEscape
Section titled “closeOnEscape”closeOnEscape:
boolean
Defined in: src/dom/screen.ts:24
Esc dismisses the layer (calls onClose) when it bubbles unhandled.
closeOnOutsideClick
Section titled “closeOnOutsideClick”closeOnOutsideClick:
boolean
Defined in: src/dom/screen.ts:26
A click outside the panel dismisses the layer.
keyInterceptor?
Section titled “keyInterceptor?”
optionalkeyInterceptor?: (ev) =>void
Defined in: src/dom/screen.ts:34
Sticky panels: sees key events before they bubble to the focused widget, so
it can claim navigation keys (↑/↓/Enter) while ordinary text still flows to
the focused control below. Set ev.handled to consume the key.
Parameters
Section titled “Parameters”Returns
Section titled “Returns”void
modal:
boolean
Defined in: src/dom/screen.ts:22
Modal layers trap focus and block keys/mouse from reaching the layer below.
onClose?
Section titled “onClose?”
optionalonClose?: () =>void
Defined in: src/dom/screen.ts:28
Invoked when the layer requests to close (Esc / outside click).
Returns
Section titled “Returns”void
previousFocus?
Section titled “previousFocus?”
optionalpreviousFocus?:Widget|null
Defined in: src/dom/screen.ts:36
Focus to restore when a modal layer is removed (filled in by pushLayer).
root:
OverlayRootWidget
Defined in: src/dom/screen.ts:20
The full-screen root the layer’s content is portalled into.