@teammodlr/ui-kit 3.0.0-beta.19 → 3.0.0-beta.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
:disable-outside-pointer-events="modal"
|
|
18
18
|
@open-auto-focus="handleOpenAutoFocus"
|
|
19
19
|
@escape-key-down="handleEscapeKeyDown"
|
|
20
|
-
@pointer-down-outside
|
|
21
|
-
@focus-outside="
|
|
22
|
-
@interact-outside
|
|
20
|
+
@pointer-down-outside="handleOutsideEvent"
|
|
21
|
+
@focus-outside="handleOutsideEvent"
|
|
22
|
+
@interact-outside="handleOutsideEvent"
|
|
23
23
|
>
|
|
24
24
|
<FocusScope :trapped="activeFocusTrap" :loop="activeFocusTrap">
|
|
25
25
|
<slot v-if="$slots.container" name="container" :close="close"></slot>
|
|
@@ -247,12 +247,10 @@ export default defineComponent({
|
|
|
247
247
|
zIndex.value = nextZIndex();
|
|
248
248
|
}
|
|
249
249
|
|
|
250
|
-
function
|
|
251
|
-
if (
|
|
252
|
-
|
|
250
|
+
function handleOutsideEvent(event: Event) {
|
|
251
|
+
if (activeFocusTrap.value) {
|
|
252
|
+
event.preventDefault();
|
|
253
253
|
}
|
|
254
|
-
|
|
255
|
-
event.preventDefault();
|
|
256
254
|
}
|
|
257
255
|
|
|
258
256
|
function handleOpenAutoFocus(event: Event) {
|
|
@@ -383,7 +381,7 @@ export default defineComponent({
|
|
|
383
381
|
onEnter,
|
|
384
382
|
handleOpenChange,
|
|
385
383
|
handleOpenAutoFocus,
|
|
386
|
-
|
|
384
|
+
handleOutsideEvent,
|
|
387
385
|
isOpen: computed(() => props.open),
|
|
388
386
|
activeFocusTrap,
|
|
389
387
|
};
|