@koumoul/vjsf 3.23.4 → 3.23.5
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 +1 -1
- package/src/components/nodes/list.vue +31 -24
package/package.json
CHANGED
|
@@ -223,6 +223,9 @@ const indexedListRules = computed(() => {
|
|
|
223
223
|
return [(/** @type {string} */v) => !props.modelValue.children.some(c => c.key === v), (/** @type {string} */v) => !v || !!props.modelValue.layout.indexed?.some(pattern => v.match(getRegexp(pattern)))]
|
|
224
224
|
})
|
|
225
225
|
|
|
226
|
+
const toggleDialog = (/** @type {boolean} */value) => {
|
|
227
|
+
if (!value) props.statefulLayout.deactivateItem(props.modelValue)
|
|
228
|
+
}
|
|
226
229
|
</script>
|
|
227
230
|
|
|
228
231
|
<template>
|
|
@@ -522,31 +525,35 @@ const indexedListRules = computed(() => {
|
|
|
522
525
|
v-bind="vEditDialogProps"
|
|
523
526
|
:z-index="zIndex"
|
|
524
527
|
class="vjsf-list-dialog"
|
|
528
|
+
@update:model-value="toggleDialog"
|
|
525
529
|
>
|
|
526
|
-
<
|
|
527
|
-
<v-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
530
|
+
<template #default="{ isActive }">
|
|
531
|
+
<v-sheet v-bind="vEditDialogVSheetProps">
|
|
532
|
+
<v-toolbar
|
|
533
|
+
density="compact"
|
|
534
|
+
color="surface"
|
|
535
|
+
class="vjsf-list-dialog-toolbar"
|
|
536
|
+
>
|
|
537
|
+
<v-spacer />
|
|
538
|
+
<v-btn
|
|
539
|
+
:title="modelValue.messages.close"
|
|
540
|
+
:icon="options.icons.close"
|
|
541
|
+
variant="flat"
|
|
542
|
+
density="comfortable"
|
|
543
|
+
:disabled="modelValue.loading"
|
|
544
|
+
@click="isActive.value = false"
|
|
545
|
+
/>
|
|
546
|
+
</v-toolbar>
|
|
547
|
+
<v-row class="ma-0">
|
|
548
|
+
<node
|
|
549
|
+
v-for="grandChild of isSection(children[children.length - 1]) ? children[children.length - 1].children : [children[children.length - 1]]"
|
|
550
|
+
:key="grandChild.fullKey"
|
|
551
|
+
:model-value="/** @type import('../../types.js').VjsfNode */(grandChild)"
|
|
552
|
+
:stateful-layout="statefulLayout"
|
|
553
|
+
/>
|
|
554
|
+
</v-row>
|
|
555
|
+
</v-sheet>
|
|
556
|
+
</template>
|
|
550
557
|
</v-dialog>
|
|
551
558
|
</v-list>
|
|
552
559
|
</v-card>
|