x-prop-tree 0.8.34 → 0.8.35
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/dist/index.js +5 -31
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
(function(){try{document.getElementById(`x-prop-tree`)?.remove();const e = document.createElement(`style`);e.setAttribute(`id`, `x-prop-tree`);const t = document.createTextNode(``);e.appendChild(t);document.head.appendChild(e);}catch(e){console.error('rolldown-plugin-inject-css', e);}})()
|
|
2
2
|
import { n as isEqual, r as cloneDeep, t as omit } from "./vendor.mu9vrf3y.js";
|
|
3
3
|
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, h, inject, isRef, mergeModels, mergeProps, normalizeStyle, onBeforeUnmount, onMounted, onUnmounted, openBlock, provide, ref, renderList, renderSlot, resolveComponent, resolveDirective, toDisplayString, unref, useId, useModel, useTemplateRef, watch, watchEffect, withCtx, withDirectives, withKeys, withModifiers } from "vue";
|
|
4
|
-
import {
|
|
4
|
+
import { eventBus, globalObjects, injectDark, injectLocale, injectViews, openConfirmDlg, openNumberDlg, openPromptDlg, useColor, useSystem, useViewStack } from "x-essential-lib";
|
|
5
5
|
import { getElement, getItems, getPropertyDefault, getPropertyDefaultArray, getTag, getTypes, isHexColor, isThemeColor, makeSlotId, parseNumberUnit, pkgs, rules, themeColors, unwrapSlotId } from "x-runtime-lib";
|
|
6
6
|
import { getListEntry, setCollapse, tidyList } from "x-group-list";
|
|
7
7
|
import { useI18n } from "vue-i18n";
|
|
@@ -1774,7 +1774,7 @@ var index_vue_vue_type_script_setup_true_lang_default$10 = /*@__PURE__*/ defineC
|
|
|
1774
1774
|
const { t } = useI18n();
|
|
1775
1775
|
const { sysBarAvail } = useSystem();
|
|
1776
1776
|
const { backgroundColor0, backgroundColor1, backgroundColor2 } = useColor();
|
|
1777
|
-
|
|
1777
|
+
injectViews();
|
|
1778
1778
|
const json = useModel(__props, "modelValue");
|
|
1779
1779
|
const emit = __emit;
|
|
1780
1780
|
const contStyle = computed(() => {
|
|
@@ -1787,20 +1787,6 @@ var index_vue_vue_type_script_setup_true_lang_default$10 = /*@__PURE__*/ defineC
|
|
|
1787
1787
|
};
|
|
1788
1788
|
});
|
|
1789
1789
|
const editor = useTemplateRef("editor");
|
|
1790
|
-
const name = `propTreejsonEditorDlg${useId()}`;
|
|
1791
|
-
const open = ref(false);
|
|
1792
|
-
const view = computed({
|
|
1793
|
-
get() {
|
|
1794
|
-
return hasView(views, name);
|
|
1795
|
-
},
|
|
1796
|
-
set(val) {
|
|
1797
|
-
if (val) addView(views, name);
|
|
1798
|
-
else delView(views, name);
|
|
1799
|
-
}
|
|
1800
|
-
});
|
|
1801
|
-
function onOpen() {
|
|
1802
|
-
open.value = true;
|
|
1803
|
-
}
|
|
1804
1790
|
async function onClose() {
|
|
1805
1791
|
try {
|
|
1806
1792
|
const newJson = editor.value.save();
|
|
@@ -1814,27 +1800,15 @@ var index_vue_vue_type_script_setup_true_lang_default$10 = /*@__PURE__*/ defineC
|
|
|
1814
1800
|
open.value = false;
|
|
1815
1801
|
}
|
|
1816
1802
|
}
|
|
1817
|
-
|
|
1818
|
-
eventBus.on(name, onOpen);
|
|
1819
|
-
});
|
|
1820
|
-
onBeforeUnmount(() => {
|
|
1821
|
-
eventBus.off(name, onOpen);
|
|
1822
|
-
});
|
|
1823
|
-
watch(open, (val) => {
|
|
1824
|
-
view.value = val;
|
|
1825
|
-
});
|
|
1826
|
-
watch(view, async (val) => {
|
|
1827
|
-
if (!val) await onClose();
|
|
1828
|
-
open.value = val;
|
|
1829
|
-
});
|
|
1803
|
+
const { open } = useViewStack(`propTreejsonEditorDlg${useId()}`, void 0, onClose);
|
|
1830
1804
|
return (_ctx, _cache) => {
|
|
1831
1805
|
const _component_v_btn = resolveComponent("v-btn");
|
|
1832
1806
|
const _component_v_sheet = resolveComponent("v-sheet");
|
|
1833
1807
|
const _component_v_spacer = resolveComponent("v-spacer");
|
|
1834
1808
|
const _component_v_dialog = resolveComponent("v-dialog");
|
|
1835
1809
|
return openBlock(), createBlock(_component_v_dialog, {
|
|
1836
|
-
modelValue: open
|
|
1837
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => open.value = $event),
|
|
1810
|
+
modelValue: unref(open),
|
|
1811
|
+
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => isRef(open) ? open.value = $event : null),
|
|
1838
1812
|
attach: "",
|
|
1839
1813
|
fullscreen: "",
|
|
1840
1814
|
"no-click-animation": "",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "x-prop-tree",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.35",
|
|
4
4
|
"files": [
|
|
5
5
|
"dist"
|
|
6
6
|
],
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"vuetify": "^4.2.1",
|
|
46
46
|
"x-block-lib": "^0.11.11",
|
|
47
47
|
"x-error-lib": "^0.6.5",
|
|
48
|
-
"x-essential-lib": "^0.10.
|
|
48
|
+
"x-essential-lib": "^0.10.42",
|
|
49
49
|
"x-group-list": "^0.4.19",
|
|
50
50
|
"x-runtime-lib": "^0.10.5",
|
|
51
51
|
"x-state-lib": "^0.4.5"
|