@farris/ui-vue 1.8.0-alpha.0 → 1.8.0-beta.1
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/components/avatar/index.esm.js +138 -1526
- package/components/avatar/index.umd.cjs +1 -6
- package/components/button/index.css +1 -1
- package/components/button/index.esm.js +15951 -15410
- package/components/button/index.umd.cjs +27 -27
- package/components/calendar/index.esm.js +269 -255
- package/components/calendar/index.umd.cjs +3 -3
- package/components/collection-property-editor/index.esm.js +243 -229
- package/components/collection-property-editor/index.umd.cjs +2 -2
- package/components/combo-list/index.esm.js +32 -32
- package/components/combo-list/index.umd.cjs +1 -1
- package/components/comment/index.esm.js +473 -456
- package/components/comment/index.umd.cjs +6 -6
- package/components/component/index.css +1 -1
- package/components/component/index.esm.js +2503 -2239
- package/components/component/index.umd.cjs +2 -2
- package/components/condition/index.esm.js +1064 -954
- package/components/condition/index.umd.cjs +2 -2
- package/components/data-grid/index.esm.js +1 -1
- package/components/data-grid/index.umd.cjs +1 -1
- package/components/designer-canvas/index.css +1 -1
- package/components/designer-canvas/index.esm.js +3894 -3058
- package/components/designer-canvas/index.umd.cjs +1 -1
- package/components/drawer/index.esm.js +91 -77
- package/components/drawer/index.umd.cjs +2 -2
- package/components/dynamic-form/index.esm.js +220 -215
- package/components/dynamic-form/index.umd.cjs +1 -1
- package/components/dynamic-resolver/index.esm.js +145 -131
- package/components/dynamic-resolver/index.umd.cjs +2 -2
- package/components/dynamic-view/index.esm.js +336 -329
- package/components/dynamic-view/index.umd.cjs +1 -1
- package/components/events-editor/index.esm.js +1611 -1536
- package/components/events-editor/index.umd.cjs +3 -3
- package/components/expression-editor/index.esm.js +219 -219
- package/components/expression-editor/index.umd.cjs +2 -2
- package/components/external-container/index.esm.js +179 -178
- package/components/external-container/index.umd.cjs +1 -1
- package/components/fieldset/index.esm.js +285 -221
- package/components/fieldset/index.umd.cjs +1 -1
- package/components/filter-bar/index.css +1 -0
- package/components/filter-bar/index.esm.js +1512 -1290
- package/components/filter-bar/index.umd.cjs +7 -7
- package/components/filter-condition-editor/index.esm.js +851 -831
- package/components/filter-condition-editor/index.umd.cjs +3 -3
- package/components/flow-canvas/index.esm.js +520 -501
- package/components/flow-canvas/index.umd.cjs +8 -8
- package/components/image/index.esm.js +101 -79
- package/components/image/index.umd.cjs +3 -3
- package/components/language-textbox/index.esm.js +330 -251
- package/components/language-textbox/index.umd.cjs +2 -2
- package/components/list-nav/index.esm.js +399 -313
- package/components/list-nav/index.umd.cjs +1 -1
- package/components/locale/index.esm.js +3 -0
- package/components/locale/index.umd.cjs +1 -1
- package/components/lookup/index.esm.js +997 -976
- package/components/lookup/index.umd.cjs +2 -2
- package/components/mapping-editor/index.esm.js +725 -705
- package/components/mapping-editor/index.umd.cjs +1 -1
- package/components/message-box/index.esm.js +542 -522
- package/components/message-box/index.umd.cjs +1 -1
- package/components/nav/index.esm.js +95 -308
- package/components/nav/index.umd.cjs +1 -1
- package/components/number-range/index.esm.js +115 -107
- package/components/number-range/index.umd.cjs +2 -2
- package/components/order/index.esm.js +56 -54
- package/components/order/index.umd.cjs +1 -1
- package/components/page-footer/index.esm.js +135 -123
- package/components/page-footer/index.umd.cjs +1 -1
- package/components/page-header/index.esm.js +266 -222
- package/components/page-header/index.umd.cjs +1 -1
- package/components/property-panel/index.esm.js +402 -375
- package/components/property-panel/index.umd.cjs +4 -4
- package/components/query-solution/index.esm.js +3171 -3061
- package/components/query-solution/index.umd.cjs +7 -7
- package/components/response-toolbar/index.esm.js +1 -1
- package/components/response-toolbar/index.umd.cjs +1 -1
- package/components/schema-selector/index.esm.js +1620 -1608
- package/components/schema-selector/index.umd.cjs +5 -5
- package/components/scroll-navbar/index.esm.js +150 -136
- package/components/scroll-navbar/index.umd.cjs +2 -2
- package/components/section/index.esm.js +323 -311
- package/components/section/index.umd.cjs +2 -2
- package/components/sort-condition-editor/index.esm.js +850 -830
- package/components/sort-condition-editor/index.umd.cjs +3 -3
- package/components/step/index.esm.js +991 -224
- package/components/step/index.umd.cjs +1 -1
- package/components/tabs/index.esm.js +356 -334
- package/components/tabs/index.umd.cjs +1 -1
- package/components/wizard/index.esm.js +159 -162
- package/components/wizard/index.umd.cjs +1 -1
- package/designer/avatar/index.esm.js +1721 -0
- package/designer/avatar/index.umd.cjs +6 -0
- package/designer/button-edit/index.esm.js +2 -1
- package/designer/button-edit/index.umd.cjs +1 -1
- package/designer/data-grid/index.esm.js +693 -659
- package/designer/data-grid/index.umd.cjs +6 -6
- package/designer/data-view/index.esm.js +90 -78
- package/designer/data-view/index.umd.cjs +2 -2
- package/designer/date-picker/index.esm.js +203 -203
- package/designer/date-picker/index.umd.cjs +1 -1
- package/designer/drawer/index.esm.js +181 -167
- package/designer/drawer/index.umd.cjs +2 -2
- package/designer/dynamic-form/index.esm.js +228 -206
- package/designer/dynamic-form/index.umd.cjs +2 -2
- package/designer/farris-designer.all.esm.js +10014 -9692
- package/designer/farris-designer.all.umd.cjs +18 -18
- package/designer/index.css +1 -1
- package/designer/input-group/index.esm.js +15 -15
- package/designer/input-group/index.umd.cjs +1 -1
- package/designer/nav/index.esm.js +1719 -0
- package/designer/nav/index.umd.cjs +6 -0
- package/designer/number-spinner/index.esm.js +8 -7
- package/designer/number-spinner/index.umd.cjs +1 -1
- package/designer/radio-group/index.esm.js +133 -125
- package/designer/radio-group/index.umd.cjs +2 -2
- package/designer/response-toolbar/index.esm.js +864 -863
- package/designer/response-toolbar/index.umd.cjs +1 -1
- package/designer/section/index.esm.js +245 -183
- package/designer/section/index.umd.cjs +1 -1
- package/designer/tabs/index.css +1 -1
- package/designer/tabs/index.esm.js +3667 -2810
- package/designer/tabs/index.umd.cjs +2 -2
- package/designer/time-picker/index.esm.js +26 -17
- package/designer/time-picker/index.umd.cjs +2 -2
- package/designer/tree-grid/index.esm.js +69 -37
- package/designer/tree-grid/index.umd.cjs +1 -1
- package/designer/wizard/index.esm.js +110 -110
- package/designer/wizard/index.umd.cjs +3 -3
- package/farris.all.esm.js +39993 -39089
- package/farris.all.umd.cjs +36 -36
- package/index.css +1 -1
- package/locales/filter-bar/ui/en.json +1 -0
- package/locales/filter-bar/ui/zh-CHS.json +1 -0
- package/locales/filter-bar/ui/zh-CHT.json +1 -0
- package/locales/ui/en.json +1 -0
- package/locales/ui/zh-CHS.json +1 -0
- package/locales/ui/zh-CHT.json +1 -0
- package/package.json +1 -1
- package/types/avatar/designer.d.ts +28 -0
- package/types/avatar/index.d.ts +0 -15
- package/types/avatar/src/composition/types.d.ts +3 -0
- package/types/avatar/src/composition/use-file.d.ts +19 -0
- package/types/avatar/src/composition/use-image.d.ts +1 -1
- package/types/avatar/src/designer/avatar.design.props.d.ts +24 -0
- package/types/avatar/src/property-config/avatar.property-config.d.ts +11 -13
- package/types/avatar/src/schema/schema-mapper.d.ts +2 -0
- package/types/components.d.ts +3 -0
- package/types/condition/index.d.ts +18 -6
- package/types/condition/src/condition-fields.component.d.ts +9 -3
- package/types/condition/src/condition-fields.design.component.d.ts +9 -3
- package/types/condition/src/condition-list.component.d.ts +9 -3
- package/types/condition/src/condition.props.d.ts +11 -0
- package/types/data-view/designer/property-config/use-appearance.d.ts +17 -10
- package/types/data-view/designer/property-config/use-pagination.d.ts +0 -6
- package/types/designer-canvas/src/composition/dg-control.d.ts +13 -0
- package/types/dynamic-form/src/component/dynamic-form-label/dynamic-form-label.component.d.ts +3 -0
- package/types/dynamic-form/src/component/dynamic-form-label/dynamic-form-label.props.d.ts +4 -0
- package/types/dynamic-resolver/src/converter/tree-auto-check.converter.d.ts +3 -0
- package/types/dynamic-view/src/components/maps.d.ts +130 -4
- package/types/filter-bar/src/composition/types.d.ts +2 -0
- package/types/filter-bar/src/filter-bar.props.d.ts +0 -1
- package/types/filter-bar/src/locale/locale.d.ts +2 -1
- package/types/filter-bar/src/property-config/filter-bar.property-config.d.ts +0 -1
- package/types/language-textbox/index.d.ts +65 -2
- package/types/language-textbox/src/designer/language-textbox.design.component.d.ts +36 -0
- package/types/language-textbox/src/language-textbox.component.d.ts +38 -1
- package/types/language-textbox/src/language-textbox.props.d.ts +20 -0
- package/types/lookup/src/components/popup-container.component.d.ts +3 -3
- package/types/lookup/src/composition/use-compat.d.ts +28 -0
- package/types/lookup/src/composition/use-state.d.ts +1 -0
- package/types/message-box/src/message-box.service.d.ts +2 -1
- package/types/nav/designer.d.ts +28 -0
- package/types/nav/index.d.ts +24 -20
- package/types/nav/src/designer/nav.design.props.d.ts +29 -0
- package/types/nav/src/designer/use-design-rules.d.ts +3 -0
- package/types/nav/src/property-config/nav.property-config.d.ts +9 -0
- package/types/nav/src/schema/schema-mapper.d.ts +4 -0
- package/types/page-footer/src/designer/use-designer-rules.d.ts +2 -2
- package/types/page-header/src/designer/use-designer-rules.d.ts +2 -2
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +1 -0
- package/types/query-solution/src/designer/query-solution-config/composition/use-util.d.ts +1 -1
- package/types/query-solution/src/designer/query-solution-config/query-solution-config.props.d.ts +1 -1
- package/types/section/src/designer/section.design.props.d.ts +4 -0
- package/types/section/src/property-config/section.property-config.d.ts +39 -0
- package/types/section/src/schema/toolbar-resolver.d.ts +0 -1
- package/types/step/src/designer/use-designer-rules.d.ts +3 -0
- package/types/step/src/designer/use-step-creator.d.ts +6 -0
- package/types/step/src/property-config/step.property-config.d.ts +15 -0
- package/types/step/src/schema/schema-resolver.d.ts +2 -1
- package/types/tabs/src/composition/types.d.ts +4 -0
- package/types/tabs/src/tabs.props.d.ts +6 -0
- package/types/tooltip/index.d.ts +3 -3
- package/types/tooltip/src/tooltip.component.d.ts +2 -2
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
var bt = Object.defineProperty;
|
|
2
2
|
var Ct = (n, t, e) => t in n ? bt(n, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : n[t] = e;
|
|
3
3
|
var S = (n, t, e) => Ct(n, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
import { radioCheckboxCommonProps as wt, FormSchemaEntityField$Type as Be, FormSchemaEntityFieldType$Type as Pe, getMaxZIndex as Te, isMobilePhone as xt, useGuid as Ce, withInstall as
|
|
5
|
-
import { resolveAppearance as
|
|
4
|
+
import { radioCheckboxCommonProps as wt, FormSchemaEntityField$Type as Be, FormSchemaEntityFieldType$Type as Pe, getMaxZIndex as Te, isMobilePhone as xt, useGuid as Ce, withInstall as Et } from "../../components/common/index.esm.js";
|
|
5
|
+
import { resolveAppearance as Mt, createPropsResolver as Ve, getPropsResolverGenerator as Oe } from "../../components/dynamic-resolver/index.esm.js";
|
|
6
6
|
import It, { radioGroupProps as Re } from "../../components/radio-group/index.esm.js";
|
|
7
7
|
import { computed as B, createVNode as m, Fragment as le, createTextVNode as Y, nextTick as oe, defineComponent as J, ref as v, inject as ce, onMounted as Z, Teleport as Ne, createApp as we, onUnmounted as me, watch as K, onBeforeMount as Ft, watchEffect as kt, Transition as Le, shallowRef as Bt, render as ve, h as Tt, cloneVNode as St, mergeProps as xe, withDirectives as ye, vShow as Pt, onUpdated as Vt, onBeforeUnmount as Ot, reactive as Rt, vModelText as Se } from "vue";
|
|
8
8
|
import { DgControl as C, canvasChanged as re, refreshCanvas as Nt, useDesignerComponent as Lt } from "../../components/designer-canvas/index.esm.js";
|
|
9
|
-
import { cloneDeep as
|
|
9
|
+
import { cloneDeep as Ee, debounce as At } from "lodash-es";
|
|
10
10
|
import { LocaleService as ne } from "../../components/locale/index.esm.js";
|
|
11
11
|
import "../../components/property-panel/index.esm.js";
|
|
12
12
|
import "../../components/button/index.esm.js";
|
|
@@ -591,7 +591,7 @@ class Gt {
|
|
|
591
591
|
const o = e && e.parent && e.parent.schema;
|
|
592
592
|
if (!o)
|
|
593
593
|
return;
|
|
594
|
-
const i = o.contents.findIndex((a) => a.id === t), l =
|
|
594
|
+
const i = o.contents.findIndex((a) => a.id === t), l = Ee(o.contents[i]);
|
|
595
595
|
o.contents.splice(i, 1), o.contents.splice(i, 0, l), Nt();
|
|
596
596
|
}
|
|
597
597
|
/**
|
|
@@ -625,14 +625,14 @@ class Gt {
|
|
|
625
625
|
const { expressionId: l, expressionInfo: a } = e, { targetId: s, targetType: r, expressionType: d, value: c, message: u } = a, b = this.formSchemaUtils.getModule();
|
|
626
626
|
b.expressions = b.expressions || [];
|
|
627
627
|
const { expressions: p } = b;
|
|
628
|
-
let f = p.find((
|
|
628
|
+
let f = p.find((E) => E.target === s);
|
|
629
629
|
f || (f = { target: s, rules: [], targetType: r }, p.push(f));
|
|
630
|
-
const y = f.rules.find((
|
|
630
|
+
const y = f.rules.find((E) => E.type === d);
|
|
631
631
|
if (y)
|
|
632
632
|
y.value = c, y.message = u;
|
|
633
633
|
else {
|
|
634
|
-
const
|
|
635
|
-
f.rules.push(
|
|
634
|
+
const E = { id: l, type: d, value: c, message: u };
|
|
635
|
+
f.rules.push(E);
|
|
636
636
|
}
|
|
637
637
|
delete e.expressionInfo;
|
|
638
638
|
}
|
|
@@ -725,6 +725,7 @@ S(ie, "fieldControlTypeMapping", {
|
|
|
725
725
|
{ key: C.textarea.type, value: C.textarea.name },
|
|
726
726
|
{ key: C.lookup.type, value: C.lookup.name },
|
|
727
727
|
{ key: C.image.type, value: C.image.name },
|
|
728
|
+
{ key: C.avatar.type, value: C.avatar.name },
|
|
728
729
|
{ key: C["rich-text-editor"].type, value: C["rich-text-editor"].name }
|
|
729
730
|
],
|
|
730
731
|
Decimal: [
|
|
@@ -803,8 +804,8 @@ function Kt(n) {
|
|
|
803
804
|
u.isSupportedClass = !1;
|
|
804
805
|
return;
|
|
805
806
|
}
|
|
806
|
-
let f = p.find((w) => /^col-([1-9]|10|11|12)$/.test(w)), y = p.find((w) => /^col-md-([1-9]|10|11|12)$/.test(w)),
|
|
807
|
-
f = f || "col-12", u.columnInSM = parseInt(f.replace("col-", ""), 10), u.displayWidthInSM = u.columnInSM / 12, u.displayWidthInSM !== 1 && (u.isSupportedClass = !1), y = y || "col-md-" + u.columnInSM, u.columnInMD = parseInt(y.replace("col-md-", ""), 10), u.displayWidthInMD = u.columnInMD / 6, [1, 2].includes(u.displayWidthInMD) || (u.isSupportedClass = !1),
|
|
807
|
+
let f = p.find((w) => /^col-([1-9]|10|11|12)$/.test(w)), y = p.find((w) => /^col-md-([1-9]|10|11|12)$/.test(w)), E = p.find((w) => /^col-xl-([1-9]|10|11|12)$/.test(w)), k = p.find((w) => /^col-el-([1-9]|10|11|12)$/.test(w));
|
|
808
|
+
f = f || "col-12", u.columnInSM = parseInt(f.replace("col-", ""), 10), u.displayWidthInSM = u.columnInSM / 12, u.displayWidthInSM !== 1 && (u.isSupportedClass = !1), y = y || "col-md-" + u.columnInSM, u.columnInMD = parseInt(y.replace("col-md-", ""), 10), u.displayWidthInMD = u.columnInMD / 6, [1, 2].includes(u.displayWidthInMD) || (u.isSupportedClass = !1), E = E || "col-xl-" + u.columnInMD, u.columnInLG = parseInt(E.replace("col-xl-", ""), 10), u.displayWidthInLG = u.columnInLG / 3, [1, 2, 3, 4].includes(u.displayWidthInLG) || (u.isSupportedClass = !1), k = k || "col-el-" + u.columnInLG, u.columnInEL = parseInt(k.replace("col-el-", ""), 10), u.displayWidthInEL = u.columnInEL / 2, [1, 2, 3, 4, 5, 6].includes(u.displayWidthInEL) || (u.isSupportedClass = !1);
|
|
808
809
|
}
|
|
809
810
|
function a(c, u, b, p = !1) {
|
|
810
811
|
let f = !1;
|
|
@@ -814,8 +815,8 @@ function Kt(n) {
|
|
|
814
815
|
return;
|
|
815
816
|
}
|
|
816
817
|
f && (b += 1, f = !1);
|
|
817
|
-
const
|
|
818
|
-
|
|
818
|
+
const E = y.appearance && y.appearance.class, k = new Dt();
|
|
819
|
+
E ? l(E, k) : k.isSupportedClass = !1, k.label = y.label || y.id, k.id = y.id, k.group = b, p && (k.fieldSetId = c.id), e === y.id && (t = b), o.set(y.id, y), u.push(k);
|
|
819
820
|
});
|
|
820
821
|
}
|
|
821
822
|
function s(c) {
|
|
@@ -833,11 +834,11 @@ function Kt(n) {
|
|
|
833
834
|
e = c.id, i = [], o.clear();
|
|
834
835
|
const y = f.contents[0].type === C.fieldset.type ? 0 : 1;
|
|
835
836
|
a(f, i, y);
|
|
836
|
-
const
|
|
837
|
+
const E = i.find((w) => !w.isSupportedClass);
|
|
837
838
|
return {
|
|
838
839
|
defaultState: {
|
|
839
840
|
defaultGroupNumber: t || 1,
|
|
840
|
-
model:
|
|
841
|
+
model: E ? "customize" : "standard"
|
|
841
842
|
},
|
|
842
843
|
importData: i
|
|
843
844
|
};
|
|
@@ -850,16 +851,16 @@ function Kt(n) {
|
|
|
850
851
|
const f = [];
|
|
851
852
|
return c.forEach((y) => {
|
|
852
853
|
var w;
|
|
853
|
-
const
|
|
854
|
+
const E = o.get(y.id), k = E.appearance && E.appearance.class;
|
|
854
855
|
if (k) {
|
|
855
|
-
const N = k.split(" ").filter((z) => !z.startsWith("col-")), T = "col-" + y.columnInSM, H = "col-md-" + y.columnInMD, h = "col-xl-" + y.columnInLG,
|
|
856
|
-
|
|
856
|
+
const N = k.split(" ").filter((z) => !z.startsWith("col-")), T = "col-" + y.columnInSM, H = "col-md-" + y.columnInMD, h = "col-xl-" + y.columnInLG, M = "col-el-" + y.columnInEL, R = [T, H, h, M].concat(N);
|
|
857
|
+
E.appearance.class = R.join(" ");
|
|
857
858
|
}
|
|
858
859
|
if (y.fieldSetId) {
|
|
859
860
|
const O = p.contents.find((T) => T.id === y.fieldSetId), N = f.find((T) => T.id === y.fieldSetId);
|
|
860
|
-
N ? (w = N.contents) == null || w.push(
|
|
861
|
+
N ? (w = N.contents) == null || w.push(E) : (f.push(O), O.contents = [E]);
|
|
861
862
|
} else
|
|
862
|
-
f.push(
|
|
863
|
+
f.push(E);
|
|
863
864
|
}), p.contents = f, p.id;
|
|
864
865
|
}
|
|
865
866
|
return {
|
|
@@ -894,7 +895,7 @@ class _t extends Gt {
|
|
|
894
895
|
},
|
|
895
896
|
{
|
|
896
897
|
label: "onClickLabel",
|
|
897
|
-
name: "
|
|
898
|
+
name: "标签点击事件"
|
|
898
899
|
}
|
|
899
900
|
]);
|
|
900
901
|
S(this, "numberEditorOptions", {
|
|
@@ -908,7 +909,7 @@ class _t extends Gt {
|
|
|
908
909
|
getCommonPropertyConfig(e, o, i = "Card") {
|
|
909
910
|
if (this.propertyConfig.categories.basic = this.getBasicProperties(e, o, i), this.propertyConfig.categories.appearance = this.getAppearanceProperties(e, o), this.propertyConfig.categories.behavior = this.getBehaviorConfig(e, "form-group"), i === "Card") {
|
|
910
911
|
const l = this.getTipsConfig(e);
|
|
911
|
-
this.propertyConfig.categories.behavior.properties = { ...this.propertyConfig.categories.behavior.properties, ...l }, ["time-picker", "date-picker", "lookup", "combo-list", "number-spinner", "input-group"].includes(e.editor.type) && (this.propertyConfig.categories.expansion = this.getExpandProperties(e));
|
|
912
|
+
this.propertyConfig.categories.behavior.properties = { ...this.propertyConfig.categories.behavior.properties, ...l }, ["time-picker", "date-picker", "lookup", "combo-list", "number-spinner", "input-group", "language-textbox"].includes(e.editor.type) && (this.propertyConfig.categories.expansion = this.getExpandProperties(e));
|
|
912
913
|
}
|
|
913
914
|
}
|
|
914
915
|
getPropertyConfig(e, o) {
|
|
@@ -1179,7 +1180,7 @@ class _t extends Gt {
|
|
|
1179
1180
|
});
|
|
1180
1181
|
}
|
|
1181
1182
|
getTipsConfig(e) {
|
|
1182
|
-
return ["time-picker", "date-picker", "lookup", "combo-list", "number-spinner", "input-group", "textarea", "rich-text-editor"].includes(e.editor.type) ? {
|
|
1183
|
+
return ["time-picker", "date-picker", "lookup", "combo-list", "number-spinner", "input-group", "textarea", "rich-text-editor", "language-textbox"].includes(e.editor.type) ? {
|
|
1183
1184
|
enableTips: {
|
|
1184
1185
|
refreshPanelAfterChanged: !0,
|
|
1185
1186
|
description: "",
|
|
@@ -1345,6 +1346,13 @@ class _t extends Gt {
|
|
|
1345
1346
|
}
|
|
1346
1347
|
return e.type;
|
|
1347
1348
|
}
|
|
1349
|
+
updateLinkedLabel(e, o) {
|
|
1350
|
+
if (e.boundEventsList && e.boundEventsList.length > 0) {
|
|
1351
|
+
const i = e.boundEventsList.find((l) => l.boundEvents && l.boundEvents.label === "onClickLabel");
|
|
1352
|
+
o.linkLabel = !!i;
|
|
1353
|
+
} else
|
|
1354
|
+
o.linkLabel = !1;
|
|
1355
|
+
}
|
|
1348
1356
|
/**
|
|
1349
1357
|
* 组装输入类控件的交互面板:包含标签超链、绑定字段值变化前后事件等。
|
|
1350
1358
|
* @param propertyData 属性值
|
|
@@ -1377,7 +1385,7 @@ class _t extends Gt {
|
|
|
1377
1385
|
tabName: "交互",
|
|
1378
1386
|
setPropertyRelates(b, p) {
|
|
1379
1387
|
const f = b.propertyValue;
|
|
1380
|
-
delete e[a.viewModelId], f && (f.setPropertyRelates = this.setPropertyRelates, f.controlInfo = { type: a.getControlMethodType(e), name: e.title }, a.eventsEditorUtils.saveRelatedParameters(e, a.viewModelId, f.events, f)), l && l(b, p, f);
|
|
1388
|
+
delete e[a.viewModelId], f && (f.setPropertyRelates = this.setPropertyRelates, f.controlInfo = { type: a.getControlMethodType(e), name: e.title }, a.eventsEditorUtils.saveRelatedParameters(e, a.viewModelId, f.events, f), a.updateLinkedLabel(f, p)), l && l(b, p, f);
|
|
1381
1389
|
const y = a.designViewModelUtils.getDgViewModel(a.viewModelId);
|
|
1382
1390
|
y && a.designViewModelField && y.changeField(a.designViewModelField.id, { valueChanging: e.fieldValueChanging, valueChanged: e.fieldValueChanged });
|
|
1383
1391
|
}
|
|
@@ -1951,7 +1959,7 @@ class te {
|
|
|
1951
1959
|
}
|
|
1952
1960
|
}
|
|
1953
1961
|
function an(n, t) {
|
|
1954
|
-
const e = v(), o = v(), i = v(), l = v(), a = v(), s = v(), r = v(), d = v(), c = v(), u = v(), b = v(), p = v(n.resizeable), f = v(), y = v(n.draggable),
|
|
1962
|
+
const e = v(), o = v(), i = v(), l = v(), a = v(), s = v(), r = v(), d = v(), c = v(), u = v(), b = v(), p = v(n.resizeable), f = v(), y = v(n.draggable), E = v(!1);
|
|
1955
1963
|
function k() {
|
|
1956
1964
|
const x = o.value || document.body, F = window.getComputedStyle(x);
|
|
1957
1965
|
if (!F || !e.value)
|
|
@@ -2006,7 +2014,7 @@ function an(n, t) {
|
|
|
2006
2014
|
const F = j.fromEvent(x);
|
|
2007
2015
|
F && H(F);
|
|
2008
2016
|
}
|
|
2009
|
-
function
|
|
2017
|
+
function M() {
|
|
2010
2018
|
if (e.value) {
|
|
2011
2019
|
const {
|
|
2012
2020
|
width: x,
|
|
@@ -2029,7 +2037,7 @@ function an(n, t) {
|
|
|
2029
2037
|
}
|
|
2030
2038
|
function R(x) {
|
|
2031
2039
|
if (e.value) {
|
|
2032
|
-
const F =
|
|
2040
|
+
const F = M();
|
|
2033
2041
|
b.value = F;
|
|
2034
2042
|
}
|
|
2035
2043
|
i.value = void 0, l.value = null, a.value = null, s.value = null, r.value = null, d.value = null, c.value = null, document.removeEventListener("mousemove", h), document.removeEventListener("mouseup", R);
|
|
@@ -2078,13 +2086,13 @@ function an(n, t) {
|
|
|
2078
2086
|
function U(x = !0) {
|
|
2079
2087
|
document.body.click();
|
|
2080
2088
|
const F = o.value || document.body, $ = te.getCurrent(F), A = e.value;
|
|
2081
|
-
x && A && (f.value =
|
|
2089
|
+
x && A && (f.value = M(), f.value.transform = A.style.transform), $ && A && (s.value = $, s.value.height -= 14, s.value.width -= 14, A.style.height = s.value.height + "px", A.style.width = s.value.width + "px", A.style.left = "7px", A.style.top = "7px", A.style.transform = "", b.value = {
|
|
2082
2090
|
size: s.value,
|
|
2083
2091
|
position: {
|
|
2084
2092
|
x: 0,
|
|
2085
2093
|
y: 0
|
|
2086
2094
|
}
|
|
2087
|
-
}, y.value = !1,
|
|
2095
|
+
}, y.value = !1, E.value = !0);
|
|
2088
2096
|
}
|
|
2089
2097
|
function q() {
|
|
2090
2098
|
var x, F;
|
|
@@ -2101,7 +2109,7 @@ function an(n, t) {
|
|
|
2101
2109
|
D.style.height = $.height + "px", D.style.width = $.width + "px", D.style.left = `${A.x}px`, D.style.top = `${A.y}px`, D.style.transform = "", b.value = {
|
|
2102
2110
|
size: $,
|
|
2103
2111
|
position: A
|
|
2104
|
-
}, y.value = n.draggable,
|
|
2112
|
+
}, y.value = n.draggable, E.value = !1;
|
|
2105
2113
|
}
|
|
2106
2114
|
}
|
|
2107
2115
|
function _() {
|
|
@@ -2118,7 +2126,7 @@ function an(n, t) {
|
|
|
2118
2126
|
}
|
|
2119
2127
|
function L() {
|
|
2120
2128
|
const x = () => {
|
|
2121
|
-
|
|
2129
|
+
E.value ? U(!1) : _(), document.body.click();
|
|
2122
2130
|
};
|
|
2123
2131
|
return window.addEventListener("resize", x), () => {
|
|
2124
2132
|
window.removeEventListener("resize", x);
|
|
@@ -2132,7 +2140,7 @@ function an(n, t) {
|
|
|
2132
2140
|
maximize: U,
|
|
2133
2141
|
restore: q,
|
|
2134
2142
|
allowDrag: y,
|
|
2135
|
-
isMaximized:
|
|
2143
|
+
isMaximized: E,
|
|
2136
2144
|
unWindowResizeHandle: G,
|
|
2137
2145
|
moveToCenter: _
|
|
2138
2146
|
};
|
|
@@ -2142,39 +2150,39 @@ function sn(n, t, e) {
|
|
|
2142
2150
|
K(() => e.value, (h) => {
|
|
2143
2151
|
a.value.style.cursor = h ? "move" : "default";
|
|
2144
2152
|
});
|
|
2145
|
-
function p(h,
|
|
2146
|
-
if (
|
|
2153
|
+
function p(h, M) {
|
|
2154
|
+
if (M.tagName === "BUTTON")
|
|
2147
2155
|
return !1;
|
|
2148
|
-
if (
|
|
2156
|
+
if (M === h)
|
|
2149
2157
|
return !0;
|
|
2150
|
-
for (const R in
|
|
2151
|
-
if (Object.prototype.hasOwnProperty.call(
|
|
2158
|
+
for (const R in M.children)
|
|
2159
|
+
if (Object.prototype.hasOwnProperty.call(M.children, R) && p(h, M.children[R]))
|
|
2152
2160
|
return !0;
|
|
2153
2161
|
return !1;
|
|
2154
2162
|
}
|
|
2155
2163
|
function f() {
|
|
2156
2164
|
var z, I;
|
|
2157
|
-
let h = u.value.x + c.value.x,
|
|
2158
|
-
l.value === "x" ? (h = ((z = d.value) == null ? void 0 : z.x) || 0, u.value.x = 0) : l.value === "y" && (
|
|
2159
|
-
const R = `translate3d(${Math.round(h)}px, ${Math.round(
|
|
2160
|
-
o.value && (o.value.style.transform = R), b.value.x = h, b.value.y =
|
|
2165
|
+
let h = u.value.x + c.value.x, M = u.value.y + c.value.y;
|
|
2166
|
+
l.value === "x" ? (h = ((z = d.value) == null ? void 0 : z.x) || 0, u.value.x = 0) : l.value === "y" && (M = ((I = d.value) == null ? void 0 : I.y) || 0, u.value.y = 0);
|
|
2167
|
+
const R = `translate3d(${Math.round(h)}px, ${Math.round(M)}px, 0px)`;
|
|
2168
|
+
o.value && (o.value.style.transform = R), b.value.x = h, b.value.y = M;
|
|
2161
2169
|
}
|
|
2162
2170
|
function y() {
|
|
2163
2171
|
if (!s.value || !o.value)
|
|
2164
2172
|
return null;
|
|
2165
|
-
const h = s.value.getBoundingClientRect(),
|
|
2166
|
-
top: h.top <
|
|
2167
|
-
right: h.right >
|
|
2168
|
-
bottom: h.bottom >
|
|
2169
|
-
left: h.left <
|
|
2173
|
+
const h = s.value.getBoundingClientRect(), M = o.value.getBoundingClientRect(), R = {
|
|
2174
|
+
top: h.top < M.top,
|
|
2175
|
+
right: h.right > M.right,
|
|
2176
|
+
bottom: h.bottom > M.bottom,
|
|
2177
|
+
left: h.left < M.left
|
|
2170
2178
|
};
|
|
2171
|
-
return R.top || (u.value.y -=
|
|
2179
|
+
return R.top || (u.value.y -= M.top - h.top), R.bottom || (u.value.y -= M.bottom - h.bottom), R.right || (u.value.x -= M.right - h.right), R.left || (u.value.x -= M.left - h.left), f(), R;
|
|
2172
2180
|
}
|
|
2173
|
-
function
|
|
2181
|
+
function E(h) {
|
|
2174
2182
|
h && (d.value && h.subtract(d.value), u.value.set(h), f(), y());
|
|
2175
2183
|
}
|
|
2176
2184
|
function k(h) {
|
|
2177
|
-
r.value && i.value && (h.stopPropagation(), h.preventDefault(),
|
|
2185
|
+
r.value && i.value && (h.stopPropagation(), h.preventDefault(), E(j.fromEvent(h, a.value)));
|
|
2178
2186
|
}
|
|
2179
2187
|
function w() {
|
|
2180
2188
|
var h;
|
|
@@ -2194,22 +2202,22 @@ function sn(n, t, e) {
|
|
|
2194
2202
|
function T(h) {
|
|
2195
2203
|
if (!e.value || h instanceof MouseEvent && h.button === 2)
|
|
2196
2204
|
return;
|
|
2197
|
-
const
|
|
2198
|
-
a.value !== void 0 &&
|
|
2205
|
+
const M = h.target || h.srcElement;
|
|
2206
|
+
a.value !== void 0 && M && !p(M, a.value) || i.value !== !1 && (document.body.click(), h.stopPropagation(), h.preventDefault(), d.value = j.fromEvent(h, o.value), N(), O());
|
|
2199
2207
|
}
|
|
2200
|
-
function H(h,
|
|
2201
|
-
if (i.value &&
|
|
2208
|
+
function H(h, M, R) {
|
|
2209
|
+
if (i.value && M) {
|
|
2202
2210
|
if (h)
|
|
2203
2211
|
a.value = h;
|
|
2204
2212
|
else if (n.dragHandle) {
|
|
2205
2213
|
if (n.dragHandle instanceof HTMLElement)
|
|
2206
2214
|
a.value = n.dragHandle;
|
|
2207
2215
|
else if (typeof n.dragHandle == "string") {
|
|
2208
|
-
const z =
|
|
2216
|
+
const z = M.querySelector(n.dragHandle);
|
|
2209
2217
|
z && (a.value = z);
|
|
2210
2218
|
}
|
|
2211
2219
|
}
|
|
2212
|
-
o.value =
|
|
2220
|
+
o.value = M, s.value = R, a.value ? (a.value.classList.add("ng-draggable"), a.value.addEventListener("mousedown", T)) : i.value = !1;
|
|
2213
2221
|
}
|
|
2214
2222
|
}
|
|
2215
2223
|
return {
|
|
@@ -2250,7 +2258,7 @@ const ae = /* @__PURE__ */ J({
|
|
|
2250
2258
|
props: ln,
|
|
2251
2259
|
emits: ["update:modelValue", "accept", "cancel", "closed", "resize", "esc", "enter", "stopMove", "buttonClick"],
|
|
2252
2260
|
setup(n, t) {
|
|
2253
|
-
const e = v(n.width || 300), o = v(n.height || 200), i = v(n.modelValue), l = v(""), a = v(n.class), s = v(n.fitContent), r = v(n.showHeader), d = v(""), c = v(n.showCloseButton), u = v(n.showMaxButton), b = v(!1), p = v(n.dialogType), f = v(n.src), y = v(""),
|
|
2261
|
+
const e = v(n.width || 300), o = v(n.height || 200), i = v(n.modelValue), l = v(""), a = v(n.class), s = v(n.fitContent), r = v(n.showHeader), d = v(""), c = v(n.showCloseButton), u = v(n.showMaxButton), b = v(!1), p = v(n.dialogType), f = v(n.src), y = v(""), E = v(n.showButtons), k = v(n.title), w = v(n.containment || null), O = v();
|
|
2254
2262
|
k.value === "错误提示" && (k.value = ne.getLocaleValue("messageBox.errorTitle"));
|
|
2255
2263
|
const N = v(!1);
|
|
2256
2264
|
function T(g, P) {
|
|
@@ -2278,7 +2286,7 @@ const ae = /* @__PURE__ */ J({
|
|
|
2278
2286
|
handle: (g) => {
|
|
2279
2287
|
T(g, !0);
|
|
2280
2288
|
}
|
|
2281
|
-
}], h = v(n.buttons && n.buttons.length ? n.buttons : H),
|
|
2289
|
+
}], h = v(n.buttons && n.buttons.length ? n.buttons : H), M = B(() => !!d.value), R = B(() => !!E.value && !!h.value), z = v(), I = v(), V = v(!1), {
|
|
2282
2290
|
renderResizeBar: U,
|
|
2283
2291
|
maximize: q,
|
|
2284
2292
|
restore: _,
|
|
@@ -2306,7 +2314,7 @@ const ae = /* @__PURE__ */ J({
|
|
|
2306
2314
|
}), K(() => n.showHeader, (g, P) => {
|
|
2307
2315
|
g !== P && (r.value = g);
|
|
2308
2316
|
}), K(() => n.showButtons, (g, P) => {
|
|
2309
|
-
g !== P && (
|
|
2317
|
+
g !== P && (E.value = g);
|
|
2310
2318
|
}), K(() => G.value, (g, P) => {
|
|
2311
2319
|
const X = g || {}, W = P || {};
|
|
2312
2320
|
JSON.stringify(X) !== JSON.stringify(W) && t.emit("resize", {
|
|
@@ -2388,7 +2396,7 @@ const ae = /* @__PURE__ */ J({
|
|
|
2388
2396
|
q(), V.value = !0;
|
|
2389
2397
|
}
|
|
2390
2398
|
async function rt(g, P) {
|
|
2391
|
-
g.handle ? await g.handle(P, g) && t.emit("closed", P) : (typeof g.onClick == "string" && (g.onButtonClick =
|
|
2399
|
+
g.handle ? await g.handle(P, g) && t.emit("closed", P) : (typeof g.onClick == "string" && (g.onButtonClick = Ee(g.onClick || ""), delete g.onClick), t.emit("buttonClick", {
|
|
2392
2400
|
button: g,
|
|
2393
2401
|
$event: P
|
|
2394
2402
|
}));
|
|
@@ -2466,7 +2474,7 @@ const ae = /* @__PURE__ */ J({
|
|
|
2466
2474
|
style: it.value
|
|
2467
2475
|
}, [t.slots.headerTemplate ? t.slots.headerTemplate() : m("div", {
|
|
2468
2476
|
class: "modal-title"
|
|
2469
|
-
}, [
|
|
2477
|
+
}, [M.value && m("span", {
|
|
2470
2478
|
class: d.value,
|
|
2471
2479
|
style: "margin-right: 8px"
|
|
2472
2480
|
}, null), m("span", {
|
|
@@ -2543,7 +2551,7 @@ function dn(n) {
|
|
|
2543
2551
|
const l = v(), a = v(n.class || ""), s = v(!!n.showButtons), r = v(!!n.showHeader), d = v(n.showCloseButton == null ? !0 : n.showCloseButton), c = v(!!n.showFloatingClose), u = v(!0), b = v(n.title || ""), p = n.acceptCallback || (() => {
|
|
2544
2552
|
}), f = n.rejectCallback || (() => {
|
|
2545
2553
|
}), y = n.closedCallback || ((N) => {
|
|
2546
|
-
}),
|
|
2554
|
+
}), E = n.resizeHandle || ((N) => {
|
|
2547
2555
|
}), k = n.stopMoveHandle || ((N) => {
|
|
2548
2556
|
}), w = He(n), O = (N) => {
|
|
2549
2557
|
u.value = !1, e.unmount(), y(N);
|
|
@@ -2569,7 +2577,7 @@ function dn(n) {
|
|
|
2569
2577
|
onCancel: f,
|
|
2570
2578
|
fitContent: n.fitContent == null ? !0 : n.fitContent,
|
|
2571
2579
|
onClosed: O,
|
|
2572
|
-
onResize:
|
|
2580
|
+
onResize: E,
|
|
2573
2581
|
onStopMove: k
|
|
2574
2582
|
}, {
|
|
2575
2583
|
default: () => [w && w(e)]
|
|
@@ -2648,8 +2656,8 @@ class cn {
|
|
|
2648
2656
|
this.isUseEscCloseModal.value = !0, this.activeModalInstance && ((H = this.activeModalInstance.value) == null || H.close(T == null ? void 0 : T.event));
|
|
2649
2657
|
}, {
|
|
2650
2658
|
width: y,
|
|
2651
|
-
height:
|
|
2652
|
-
} = o.value, k = this.adaptToWindow(y || 500,
|
|
2659
|
+
height: E
|
|
2660
|
+
} = o.value, k = this.adaptToWindow(y || 500, E || 320);
|
|
2653
2661
|
Object.assign(o.value, k);
|
|
2654
2662
|
const w = () => m(ae, xe({
|
|
2655
2663
|
ref: this.modalRef,
|
|
@@ -2714,7 +2722,7 @@ function fn(n, t, e, o, i) {
|
|
|
2714
2722
|
})), { judgeCanOpen: r } = Ue(n, i), d = B(() => n.showButtonWhenDisabled || (!n.editable || !n.readonly) && !n.disable), c = ce($e, null), u = v();
|
|
2715
2723
|
async function b(y) {
|
|
2716
2724
|
if (await r() && d.value) {
|
|
2717
|
-
const
|
|
2725
|
+
const E = !!t.slots.default;
|
|
2718
2726
|
if (l.value === "Modal") {
|
|
2719
2727
|
const k = n.modalOptions, w = c == null ? void 0 : c.open({
|
|
2720
2728
|
...k,
|
|
@@ -2727,7 +2735,7 @@ function fn(n, t, e, o, i) {
|
|
|
2727
2735
|
host: document.body,
|
|
2728
2736
|
backgroundColor: "rgba(0,0,0,.15)",
|
|
2729
2737
|
render: () => t.slots.default && t.slots.default()
|
|
2730
|
-
}),
|
|
2738
|
+
}), E && l.value === "Popup" && o.togglePopup(!0), E && a.value && o.hidePopup(), t.emit("clickButton", { origin: y, value: n.modelValue });
|
|
2731
2739
|
}
|
|
2732
2740
|
}
|
|
2733
2741
|
function p(y) {
|
|
@@ -2753,8 +2761,8 @@ function pn(n, t, e, o, i, l) {
|
|
|
2753
2761
|
c(!!i.value);
|
|
2754
2762
|
});
|
|
2755
2763
|
function u(f) {
|
|
2756
|
-
const y = !n.readonly && !n.disable && n.editable,
|
|
2757
|
-
f.stopPropagation(), (y ||
|
|
2764
|
+
const y = !n.readonly && !n.disable && n.editable, E = !n.editable;
|
|
2765
|
+
f.stopPropagation(), (y || E) && (r(""), i.value = "", c(!a.value), t.emit("clear"));
|
|
2758
2766
|
}
|
|
2759
2767
|
function b(f) {
|
|
2760
2768
|
if (s.value) {
|
|
@@ -2783,7 +2791,7 @@ function mn(n, t, e, o, i) {
|
|
|
2783
2791
|
"text-right": n.textAlign === "right",
|
|
2784
2792
|
"form-control": !0,
|
|
2785
2793
|
"f-utils-fill": !0
|
|
2786
|
-
})),
|
|
2794
|
+
})), E = B(() => ({
|
|
2787
2795
|
"input-group": !0,
|
|
2788
2796
|
"f-state-disabled": n.disable,
|
|
2789
2797
|
"f-state-editable": n.editable && !n.disable && !n.readonly,
|
|
@@ -2820,7 +2828,7 @@ function mn(n, t, e, o, i) {
|
|
|
2820
2828
|
function h(I) {
|
|
2821
2829
|
I.target.tagName !== "INPUT" && I.preventDefault(), I.stopPropagation();
|
|
2822
2830
|
}
|
|
2823
|
-
function
|
|
2831
|
+
function M(I) {
|
|
2824
2832
|
t.emit("keydown", I);
|
|
2825
2833
|
}
|
|
2826
2834
|
function R(I) {
|
|
@@ -2836,7 +2844,7 @@ function mn(n, t, e, o, i) {
|
|
|
2836
2844
|
textBoxClass: y,
|
|
2837
2845
|
textBoxPlaceholder: u,
|
|
2838
2846
|
textBoxTitle: c,
|
|
2839
|
-
inputGroupClass:
|
|
2847
|
+
inputGroupClass: E,
|
|
2840
2848
|
hasClearClass: d,
|
|
2841
2849
|
changeTextBoxValue: k,
|
|
2842
2850
|
commitValue: w,
|
|
@@ -2844,7 +2852,7 @@ function mn(n, t, e, o, i) {
|
|
|
2844
2852
|
onClickTextBox: N,
|
|
2845
2853
|
onFocusTextBox: T,
|
|
2846
2854
|
onInput: H,
|
|
2847
|
-
onKeyDownTextBox:
|
|
2855
|
+
onKeyDownTextBox: M,
|
|
2848
2856
|
onKeyUpTextBox: R,
|
|
2849
2857
|
onMouseDownTextBox: h,
|
|
2850
2858
|
onTextBoxValueChange: z
|
|
@@ -2907,17 +2915,17 @@ function gn(n, t, e) {
|
|
|
2907
2915
|
onKeyUpTextBox: p,
|
|
2908
2916
|
onMouseDownTextBox: f,
|
|
2909
2917
|
onTextBoxValueChange: y
|
|
2910
|
-
} = e,
|
|
2918
|
+
} = e, E = v(n.id), {
|
|
2911
2919
|
uuid: k
|
|
2912
2920
|
} = Ce(), w = B(() => ({
|
|
2913
2921
|
// 'border-top-right-radius': '6px',
|
|
2914
2922
|
// 'border-bottom-right-radius': '6px'
|
|
2915
2923
|
}));
|
|
2916
2924
|
Z(() => {
|
|
2917
|
-
var h,
|
|
2918
|
-
n.selectOnCreated && ((h = o.value) == null || h.select()), n.focusOnCreated && ((
|
|
2925
|
+
var h, M;
|
|
2926
|
+
n.selectOnCreated && ((h = o.value) == null || h.select()), n.focusOnCreated && ((M = o.value) == null || M.focus({
|
|
2919
2927
|
preventScroll: !0
|
|
2920
|
-
})),
|
|
2928
|
+
})), E.value || (E.value = "button-edit_" + k(8)), E.value = E.value + "-textbox";
|
|
2921
2929
|
});
|
|
2922
2930
|
const O = v(!1), N = (h) => {
|
|
2923
2931
|
h.preventDefault(), O.value = !0;
|
|
@@ -2973,7 +2981,7 @@ function vn(n, t, e) {
|
|
|
2973
2981
|
o.value = f;
|
|
2974
2982
|
});
|
|
2975
2983
|
const b = v(!n.disable && !n.readonly);
|
|
2976
|
-
K([() => n.disable, () => n.readonly], ([f, y], [
|
|
2984
|
+
K([() => n.disable, () => n.readonly], ([f, y], [E, k]) => {
|
|
2977
2985
|
b.value = !f && !y;
|
|
2978
2986
|
});
|
|
2979
2987
|
function p(f) {
|
|
@@ -3004,8 +3012,8 @@ function yn(n, t, e, o) {
|
|
|
3004
3012
|
enableClearButton: r,
|
|
3005
3013
|
showClearButton: d,
|
|
3006
3014
|
onClearValue: c
|
|
3007
|
-
} = o, u = v(), b = At((
|
|
3008
|
-
l(
|
|
3015
|
+
} = o, u = v(), b = At((E) => {
|
|
3016
|
+
l(E);
|
|
3009
3017
|
}, n.buttonBehavior === "Modal" ? 0 : 200), p = () => {
|
|
3010
3018
|
t.emit("beforeClearValue");
|
|
3011
3019
|
}, f = B(() => ({
|
|
@@ -3035,7 +3043,7 @@ function yn(n, t, e, o) {
|
|
|
3035
3043
|
class: "input-group-text input-group-append-button",
|
|
3036
3044
|
innerHTML: n.buttonContent,
|
|
3037
3045
|
ref: u,
|
|
3038
|
-
onClick: (
|
|
3046
|
+
onClick: (E) => b(E),
|
|
3039
3047
|
onMouseenter: a,
|
|
3040
3048
|
onMouseleave: s
|
|
3041
3049
|
}, null) : null, n.expandable && m("div", {
|
|
@@ -3090,10 +3098,10 @@ const Cn = /* @__PURE__ */ J({
|
|
|
3090
3098
|
hasFocusedTextBox: p,
|
|
3091
3099
|
commitValue: f,
|
|
3092
3100
|
inputGroupClass: y
|
|
3093
|
-
} = b,
|
|
3101
|
+
} = b, E = pn(n, t, i, p, u, b), {
|
|
3094
3102
|
onMouseEnterTextBox: k,
|
|
3095
3103
|
onMouseLeaveTextBox: w
|
|
3096
|
-
} =
|
|
3104
|
+
} = E, O = v(!1), N = B(() => {
|
|
3097
3105
|
const L = {
|
|
3098
3106
|
"f-button-edit": !0,
|
|
3099
3107
|
"f-cmp-inputgroup": !0,
|
|
@@ -3113,17 +3121,17 @@ const Cn = /* @__PURE__ */ J({
|
|
|
3113
3121
|
const G = Array.from(e.value.querySelectorAll(".farris-tag-item"));
|
|
3114
3122
|
return G && G.length && (L = G.map((x) => x.offsetTop).filter((x) => x > 20).length), L;
|
|
3115
3123
|
}
|
|
3116
|
-
const
|
|
3124
|
+
const M = v(h());
|
|
3117
3125
|
Vt(() => {
|
|
3118
|
-
|
|
3126
|
+
M.value = h();
|
|
3119
3127
|
});
|
|
3120
3128
|
function R() {
|
|
3121
|
-
return n.multiSelect && n.inputType === "tag" ? () => m(le, null, [vn(n, i, b)(), !!
|
|
3129
|
+
return n.multiSelect && n.inputType === "tag" ? () => m(le, null, [vn(n, i, b)(), !!M.value && m("div", {
|
|
3122
3130
|
class: "d-flex flex-row mr-2 more-tags",
|
|
3123
3131
|
"more-tags": !0
|
|
3124
3132
|
}, [m("span", {
|
|
3125
3133
|
class: "multi--more-text"
|
|
3126
|
-
}, [Y("+"),
|
|
3134
|
+
}, [Y("+"), M.value])])]) : gn(n, i, b);
|
|
3127
3135
|
}
|
|
3128
3136
|
let z = R();
|
|
3129
3137
|
K([() => n.multiSelect, () => n.inputType], () => {
|
|
@@ -3132,7 +3140,7 @@ const Cn = /* @__PURE__ */ J({
|
|
|
3132
3140
|
const {
|
|
3133
3141
|
renderButtonGroup: I,
|
|
3134
3142
|
buttonHandleElement: V
|
|
3135
|
-
} = yn(n, t, c,
|
|
3143
|
+
} = yn(n, t, c, E), U = bn(n, t, l), q = v(a.value), _ = {
|
|
3136
3144
|
displayText: u,
|
|
3137
3145
|
commitValue: f,
|
|
3138
3146
|
elementRef: e,
|
|
@@ -3202,8 +3210,8 @@ function qe(n, t, e) {
|
|
|
3202
3210
|
return t;
|
|
3203
3211
|
}
|
|
3204
3212
|
const je = /* @__PURE__ */ new Map([
|
|
3205
|
-
["appearance",
|
|
3206
|
-
]), Ge = /* @__PURE__ */ new Map([]), wn = "https://json-schema.org/draft/2020-12/schema", xn = "https://farris-design.gitee.io/radio-group.schema.json",
|
|
3213
|
+
["appearance", Mt]
|
|
3214
|
+
]), Ge = /* @__PURE__ */ new Map([]), wn = "https://json-schema.org/draft/2020-12/schema", xn = "https://farris-design.gitee.io/radio-group.schema.json", En = "item-collection-editor", Mn = "A Farris Input Component", In = "object", Fn = {
|
|
3207
3215
|
id: {
|
|
3208
3216
|
description: "The unique identifier for a item-collection-editor",
|
|
3209
3217
|
type: "string"
|
|
@@ -3293,13 +3301,13 @@ const je = /* @__PURE__ */ new Map([
|
|
|
3293
3301
|
], Bn = [], De = {
|
|
3294
3302
|
$schema: wn,
|
|
3295
3303
|
$id: xn,
|
|
3296
|
-
title:
|
|
3297
|
-
description:
|
|
3304
|
+
title: En,
|
|
3305
|
+
description: Mn,
|
|
3298
3306
|
type: In,
|
|
3299
3307
|
properties: Fn,
|
|
3300
3308
|
required: kn,
|
|
3301
3309
|
ignore: Bn
|
|
3302
|
-
},
|
|
3310
|
+
}, Me = {
|
|
3303
3311
|
/**
|
|
3304
3312
|
* 必填的列
|
|
3305
3313
|
*/
|
|
@@ -3356,9 +3364,9 @@ const je = /* @__PURE__ */ new Map([
|
|
|
3356
3364
|
*/
|
|
3357
3365
|
modalHeight: { type: Number, default: 600 }
|
|
3358
3366
|
};
|
|
3359
|
-
Ve(
|
|
3367
|
+
Ve(Me, De, Ge, qe);
|
|
3360
3368
|
const Tn = Oe(
|
|
3361
|
-
|
|
3369
|
+
Me,
|
|
3362
3370
|
De,
|
|
3363
3371
|
Ge,
|
|
3364
3372
|
qe
|
|
@@ -3416,22 +3424,22 @@ const Tn = Oe(
|
|
|
3416
3424
|
});
|
|
3417
3425
|
function b() {
|
|
3418
3426
|
const h = {};
|
|
3419
|
-
return c.forEach((
|
|
3420
|
-
|
|
3427
|
+
return c.forEach((M) => {
|
|
3428
|
+
M.editor && (M.editor.type === "checkbox" || M.editor.type === "switch") ? h[M.field] = !1 : h[M.field] = "";
|
|
3421
3429
|
}), h;
|
|
3422
3430
|
}
|
|
3423
3431
|
function p() {
|
|
3424
3432
|
if (n.dynamicMappingKeys) {
|
|
3425
|
-
const h = "请先填写XXX。",
|
|
3433
|
+
const h = "请先填写XXX。", M = l.value.trim() ? a.value.trim() ? "" : "枚举名称字段" : "枚举值字段";
|
|
3426
3434
|
return i.warning({
|
|
3427
3435
|
position: "top-center",
|
|
3428
|
-
message: h.replace("XXX",
|
|
3436
|
+
message: h.replace("XXX", M)
|
|
3429
3437
|
}), !1;
|
|
3430
3438
|
}
|
|
3431
3439
|
return !0;
|
|
3432
3440
|
}
|
|
3433
3441
|
function f(h) {
|
|
3434
|
-
const
|
|
3442
|
+
const M = "不允许重复。";
|
|
3435
3443
|
if (!p())
|
|
3436
3444
|
return !1;
|
|
3437
3445
|
if (!h || h.length === 0)
|
|
@@ -3462,7 +3470,7 @@ const Tn = Oe(
|
|
|
3462
3470
|
const L = c.find((G) => G.field === V);
|
|
3463
3471
|
return i.warning({
|
|
3464
3472
|
position: "top-center",
|
|
3465
|
-
message: L.title +
|
|
3473
|
+
message: L.title + M
|
|
3466
3474
|
}), !1;
|
|
3467
3475
|
}
|
|
3468
3476
|
}
|
|
@@ -3471,13 +3479,13 @@ const Tn = Oe(
|
|
|
3471
3479
|
function y() {
|
|
3472
3480
|
if (n.readonly || !p())
|
|
3473
3481
|
return;
|
|
3474
|
-
const h = b(),
|
|
3482
|
+
const h = b(), M = o();
|
|
3475
3483
|
u.push({
|
|
3476
|
-
hId:
|
|
3484
|
+
hId: M,
|
|
3477
3485
|
...h
|
|
3478
|
-
}), d.value.updateDataSource(u), d.value.selectRowById(
|
|
3486
|
+
}), d.value.updateDataSource(u), d.value.selectRowById(M);
|
|
3479
3487
|
}
|
|
3480
|
-
function
|
|
3488
|
+
function E(h) {
|
|
3481
3489
|
u && u.length > 0 ? (h || (h = u[0].hId), d.value.selectRowById(h)) : e = "";
|
|
3482
3490
|
}
|
|
3483
3491
|
function k() {
|
|
@@ -3491,29 +3499,29 @@ const Tn = Oe(
|
|
|
3491
3499
|
const h = u.findIndex((z) => z.hId === e);
|
|
3492
3500
|
u = [...u.filter((z) => z.hId !== e)], d.value.updateDataSource(u);
|
|
3493
3501
|
let R = "";
|
|
3494
|
-
h < u.length && u.length > 0 && (R = u[h].hId),
|
|
3502
|
+
h < u.length && u.length > 0 && (R = u[h].hId), E(R);
|
|
3495
3503
|
}
|
|
3496
3504
|
function w(h) {
|
|
3497
3505
|
if (!h || h.length === 0)
|
|
3498
3506
|
return h;
|
|
3499
|
-
const
|
|
3507
|
+
const M = [];
|
|
3500
3508
|
return h.forEach((R) => {
|
|
3501
3509
|
const {
|
|
3502
3510
|
value: z,
|
|
3503
3511
|
name: I,
|
|
3504
3512
|
...V
|
|
3505
3513
|
} = R, U = Object.assign({}, V);
|
|
3506
|
-
U[l.value.trim()] = z, U[a.value.trim()] = I,
|
|
3507
|
-
}),
|
|
3514
|
+
U[l.value.trim()] = z, U[a.value.trim()] = I, M.push(U);
|
|
3515
|
+
}), M;
|
|
3508
3516
|
}
|
|
3509
3517
|
function O() {
|
|
3510
3518
|
d.value.endEditCell();
|
|
3511
3519
|
const h = [];
|
|
3512
|
-
return u.forEach((
|
|
3520
|
+
return u.forEach((M) => {
|
|
3513
3521
|
const {
|
|
3514
3522
|
hId: R,
|
|
3515
3523
|
...z
|
|
3516
|
-
} =
|
|
3524
|
+
} = M, I = {};
|
|
3517
3525
|
for (const V in z)
|
|
3518
3526
|
V.startsWith("_") || (I[V] = z[V]);
|
|
3519
3527
|
h.push(I);
|
|
@@ -3534,11 +3542,11 @@ const Tn = Oe(
|
|
|
3534
3542
|
getItems: O,
|
|
3535
3543
|
getDataGridDatas: T
|
|
3536
3544
|
}), Z(() => {
|
|
3537
|
-
|
|
3545
|
+
E();
|
|
3538
3546
|
});
|
|
3539
3547
|
function H(h) {
|
|
3540
|
-
var
|
|
3541
|
-
e = (
|
|
3548
|
+
var M;
|
|
3549
|
+
e = (M = h[0]) == null ? void 0 : M.hId;
|
|
3542
3550
|
}
|
|
3543
3551
|
return () => m("div", {
|
|
3544
3552
|
class: "f-utils-fill-flex-column h-100"
|
|
@@ -3612,7 +3620,7 @@ const Tn = Oe(
|
|
|
3612
3620
|
}
|
|
3613
3621
|
function y(w, O) {
|
|
3614
3622
|
}
|
|
3615
|
-
function
|
|
3623
|
+
function E(w) {
|
|
3616
3624
|
return `f-preten-link ${w.customClass ? w.customClass : ""}`;
|
|
3617
3625
|
}
|
|
3618
3626
|
K(e, () => {
|
|
@@ -3623,7 +3631,7 @@ const Tn = Oe(
|
|
|
3623
3631
|
return m(le, null, [m("div", {
|
|
3624
3632
|
class: "after-toast-msg text-right"
|
|
3625
3633
|
}, [!t.slots.default && ((w = i.value.buttons) == null ? void 0 : w.map((O) => m("span", {
|
|
3626
|
-
class:
|
|
3634
|
+
class: E(O),
|
|
3627
3635
|
onClick: (N) => void 0
|
|
3628
3636
|
}, [O.text]))), t.slots.default && t.slots.default()])]);
|
|
3629
3637
|
};
|
|
@@ -3728,16 +3736,16 @@ const de = /* @__PURE__ */ J({
|
|
|
3728
3736
|
top: 20,
|
|
3729
3737
|
bottom: 12
|
|
3730
3738
|
}, s = v(), r = v(n.options), d = v(n.showCloseButton), c = B(() => n.position || "bottom-right"), u = B(() => n.timeout != null ? n.timeout : 3e3), b = B(() => {
|
|
3731
|
-
const
|
|
3739
|
+
const E = n.bottom ? n.bottom : a.bottom, k = n.top ? n.top : a.top, w = {
|
|
3732
3740
|
transition: "all 0.2s ease",
|
|
3733
3741
|
left: c.value.indexOf("left") > -1 ? `${n.left ? n.left : a.left}px` : "",
|
|
3734
3742
|
right: c.value.indexOf("right") > -1 ? `${n.right ? n.right : a.right}px` : "",
|
|
3735
3743
|
top: c.value.indexOf("top") > -1 ? `${k}px` : "",
|
|
3736
|
-
bottom: c.value.indexOf("bottom") > -1 ? `${
|
|
3744
|
+
bottom: c.value.indexOf("bottom") > -1 ? `${E}px` : ""
|
|
3737
3745
|
};
|
|
3738
3746
|
return c.value.indexOf("center") > -1 && (w.left = "50%", w.marginLeft = "calc(-24rem / 2)", c.value === "center-center" && (w.top = "50%", w.transform = "translate(-50%, -50%)")), w;
|
|
3739
3747
|
});
|
|
3740
|
-
function p(
|
|
3748
|
+
function p(E) {
|
|
3741
3749
|
t.emit("close");
|
|
3742
3750
|
}
|
|
3743
3751
|
u.value && setTimeout(() => {
|
|
@@ -3747,15 +3755,15 @@ const de = /* @__PURE__ */ J({
|
|
|
3747
3755
|
container: s,
|
|
3748
3756
|
notifyPosition: c
|
|
3749
3757
|
});
|
|
3750
|
-
function f(
|
|
3758
|
+
function f(E, k) {
|
|
3751
3759
|
p();
|
|
3752
3760
|
}
|
|
3753
3761
|
return () => {
|
|
3754
|
-
var
|
|
3762
|
+
var E;
|
|
3755
3763
|
return e ? m("div", {
|
|
3756
3764
|
class: l.value,
|
|
3757
3765
|
ref: s
|
|
3758
|
-
}, [(
|
|
3766
|
+
}, [(E = n.options) == null ? void 0 : E.message]) : m("div", {
|
|
3759
3767
|
class: l.value,
|
|
3760
3768
|
style: b.value,
|
|
3761
3769
|
ref: s
|
|
@@ -3895,7 +3903,7 @@ de.install = (n) => {
|
|
|
3895
3903
|
};
|
|
3896
3904
|
const Hn = /* @__PURE__ */ J({
|
|
3897
3905
|
name: "FItemCollectionEditor",
|
|
3898
|
-
props:
|
|
3906
|
+
props: Me,
|
|
3899
3907
|
components: {},
|
|
3900
3908
|
emits: ["change"],
|
|
3901
3909
|
setup(n, t) {
|
|
@@ -3908,12 +3916,12 @@ const Hn = /* @__PURE__ */ J({
|
|
|
3908
3916
|
if (l.value && a.value) {
|
|
3909
3917
|
const {
|
|
3910
3918
|
[l.value]: y,
|
|
3911
|
-
[a.value]:
|
|
3919
|
+
[a.value]: E,
|
|
3912
3920
|
...k
|
|
3913
3921
|
} = f, w = k || {};
|
|
3914
|
-
w.value = y, w.name =
|
|
3922
|
+
w.value = y, w.name = E, w.hId = o(), p.push(w);
|
|
3915
3923
|
}
|
|
3916
|
-
})) : (p =
|
|
3924
|
+
})) : (p = Ee(n.modelValue || []), p.forEach((f) => {
|
|
3917
3925
|
f.hId = o();
|
|
3918
3926
|
})), p;
|
|
3919
3927
|
}
|
|
@@ -4142,7 +4150,7 @@ pe.register = (n, t, e, o, i) => {
|
|
|
4142
4150
|
pe.registerDesigner = (n, t, e, o) => {
|
|
4143
4151
|
n["radio-group"] = pe, t["radio-group"] = _e(o);
|
|
4144
4152
|
};
|
|
4145
|
-
const ci =
|
|
4153
|
+
const ci = Et(pe);
|
|
4146
4154
|
export {
|
|
4147
4155
|
pe as FRadioGroupDesign,
|
|
4148
4156
|
ci as default,
|