mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-19 09:42:21 +00:00
Vue kit: UiDialog for the Data Library and scene sharing dialogs
UiDialog is a native <dialog> its owner opens and closes with open: true opens it with showModal() (on mount, for one mounted open), false closes it, and unmounting closes it. Each change is applied once the content has rendered and then emitted as opened or closed, so the Data Library still focuses its search field on open and returns focus to Browse on close. Escape's cancel is prevented and emitted as dismiss; backdropDismiss makes a click on the dialog itself a dismiss too, as the Data Library's was. When the browser closes the dialog on its own while open is still true, browserClose tells the owner, as the Data Library's close listener did; closing on unmount reports nothing. A DOM without showModal() leaves it closed. Attributes, classes, styles and listeners go to the dialog, and element is exposed. The two dialogs share no declarations, so there are no kit rules. dialogs.test.mjs fails if a view writes a <dialog> by hand; the panels drawn as role="dialog" are other controls. Co-authored-by: Manjunath Paparaju <[email protected]>
This commit is contained in:
1 parent
2d7b7be890
commit
ec4a5b6afe
10 files changed
+388
-42
No files matched your search
@@ -244,6 +244,7 @@
|
||||
"src/ui/kit/UiCloseButton.vue",
|
||||
"src/ui/kit/UiSearchField.vue",
|
||||
"src/ui/kit/UiCheckbox.vue",
|
||||
"src/ui/kit/UiDialog.vue",
|
||||
"src/ui/stores/globeActions.js",
|
||||
"src/ui/views/panels/GlobeActions.vue",
|
||||
"src/ui/views/panels/RenderFailure.vue",
|
||||
|
||||
Reference in new issue
Block a user