Changeset 0.37.4 (#216)
Co-authored-by: gobha <jasafpro@gmail.com> Co-committed-by: gobha <jasafpro@gmail.com>
This commit is contained in:
17
src/js/sw/shell/dialog-stack.js
Normal file
17
src/js/sw/shell/dialog-stack.js
Normal file
@@ -0,0 +1,17 @@
|
||||
/**
|
||||
* DialogStack — mounts imperative dialog hosts (ConfirmHost, PromptHost)
|
||||
*
|
||||
* Must be rendered once at the root level and never unmounted,
|
||||
* so sw.confirm() and sw.prompt() work globally.
|
||||
*/
|
||||
const { html } = window;
|
||||
|
||||
import { ConfirmHost } from '../primitives/confirm.js';
|
||||
import { PromptHost } from '../primitives/prompt.js';
|
||||
|
||||
export function DialogStack() {
|
||||
return html`
|
||||
<${ConfirmHost} />
|
||||
<${PromptHost} />
|
||||
`;
|
||||
}
|
||||
Reference in New Issue
Block a user