@farris/ui-vue 1.2.8 → 1.2.9
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/accordion/index.esm.js +129 -129
- package/components/accordion/index.umd.cjs +1 -0
- package/components/avatar/index.esm.js +166 -157
- package/components/avatar/index.umd.cjs +1 -0
- package/components/border-editor/index.umd.cjs +1 -0
- package/components/button/index.umd.cjs +1 -0
- package/components/button-edit/index.esm.js +343 -325
- package/components/button-edit/index.umd.cjs +1 -0
- package/components/button-group/index.umd.cjs +1 -0
- package/components/calculator/index.umd.cjs +1 -0
- package/components/calendar/index.esm.js +338 -338
- package/components/calendar/index.umd.cjs +1 -0
- package/components/capsule/index.esm.js +182 -182
- package/components/capsule/index.umd.cjs +1 -0
- package/components/checkbox/index.esm.js +326 -317
- package/components/checkbox/index.umd.cjs +1 -0
- package/components/color-picker/index.esm.js +118 -118
- package/components/color-picker/index.umd.cjs +3 -0
- package/components/combo-list/index.esm.js +338 -325
- package/components/combo-list/index.umd.cjs +1 -0
- package/components/combo-tree/index.esm.js +62 -62
- package/components/combo-tree/index.umd.cjs +1 -0
- package/components/common/index.umd.cjs +1 -0
- package/components/component/index.esm.js +382 -270
- package/components/component/index.umd.cjs +1 -0
- package/components/condition/index.esm.js +1018 -895
- package/components/condition/index.umd.cjs +1 -0
- package/components/content-container/index.esm.js +285 -212
- package/components/content-container/index.umd.cjs +1 -0
- package/components/data-grid/index.css +1 -1
- package/components/data-grid/index.esm.js +4761 -4319
- package/components/data-grid/index.umd.cjs +1 -0
- package/components/data-view/index.esm.js +2901 -2664
- package/components/data-view/index.umd.cjs +1 -0
- package/components/date-picker/index.esm.js +1502 -1488
- package/components/date-picker/index.umd.cjs +1 -0
- package/components/designer-canvas/index.css +1 -1
- package/components/designer-canvas/index.esm.js +938 -928
- package/components/designer-canvas/index.umd.cjs +1 -0
- package/components/designer-outline/index.css +1 -1
- package/components/designer-outline/index.esm.js +27 -27
- package/components/designer-outline/index.umd.cjs +1 -0
- package/components/designer-toolbox/index.esm.js +36 -12
- package/components/designer-toolbox/index.umd.cjs +1 -0
- package/components/discussion-editor/index.umd.cjs +3 -0
- package/components/discussion-list/index.umd.cjs +1 -0
- package/components/drawer/index.umd.cjs +1 -0
- package/components/dropdown/index.esm.js +241 -241
- package/components/dropdown/index.umd.cjs +2 -0
- package/components/dynamic-form/index.esm.js +1074 -885
- package/components/dynamic-form/index.umd.cjs +1 -0
- package/components/dynamic-resolver/index.esm.js +99 -94
- package/components/dynamic-resolver/index.umd.cjs +1 -0
- package/components/dynamic-view/index.umd.cjs +1 -0
- package/components/enum-editor/index.umd.cjs +1 -0
- package/components/events-editor/index.esm.js +577 -522
- package/components/events-editor/index.umd.cjs +1 -0
- package/components/expression-editor/index.esm.js +70 -70
- package/components/expression-editor/index.umd.cjs +1 -0
- package/components/external-container/index.css +1 -1
- package/components/external-container/index.esm.js +2938 -2619
- package/components/external-container/index.umd.cjs +1 -0
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +4766 -4325
- package/components/field-selector/index.umd.cjs +1 -0
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1231 -1215
- package/components/filter-bar/index.umd.cjs +1 -0
- package/components/flow-canvas/index.css +1 -1
- package/components/flow-canvas/index.esm.js +1062 -1052
- package/components/flow-canvas/index.umd.cjs +1 -0
- package/components/image-cropper/index.esm.js +373 -373
- package/components/image-cropper/index.umd.cjs +1 -0
- package/components/input-group/index.esm.js +398 -394
- package/components/input-group/index.umd.cjs +1 -0
- package/components/layout/index.esm.js +268 -268
- package/components/layout/index.umd.cjs +1 -0
- package/components/list-nav/index.esm.js +234 -161
- package/components/list-nav/index.umd.cjs +1 -0
- package/components/list-view/index.css +1 -1
- package/components/list-view/index.esm.js +2288 -2048
- package/components/list-view/index.umd.cjs +1 -0
- package/components/loading/index.umd.cjs +8 -0
- package/components/locale/index.umd.cjs +1 -0
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +5776 -5305
- package/components/lookup/index.umd.cjs +1 -0
- package/components/mapping-editor/index.css +1 -1
- package/components/mapping-editor/index.esm.js +5496 -5036
- package/components/mapping-editor/index.umd.cjs +1 -0
- package/components/message-box/index.umd.cjs +1 -0
- package/components/modal/index.umd.cjs +1 -0
- package/components/nav/index.esm.js +383 -322
- package/components/nav/index.umd.cjs +3 -0
- package/components/notify/index.umd.cjs +1 -0
- package/components/number-range/index.esm.js +273 -269
- package/components/number-range/index.umd.cjs +1 -0
- package/components/number-spinner/index.esm.js +292 -283
- package/components/number-spinner/index.umd.cjs +1 -0
- package/components/order/index.css +1 -1
- package/components/order/index.esm.js +1008 -925
- package/components/order/index.umd.cjs +1 -0
- package/components/page-footer/index.esm.js +98 -98
- package/components/page-footer/index.umd.cjs +1 -0
- package/components/page-header/index.esm.js +949 -847
- package/components/page-header/index.umd.cjs +1 -0
- package/components/pagination/index.esm.js +464 -403
- package/components/pagination/index.umd.cjs +1 -0
- package/components/popover/index.umd.cjs +1 -0
- package/components/progress/index.esm.js +226 -226
- package/components/progress/index.umd.cjs +3 -0
- package/components/property-editor/index.esm.js +1110 -1092
- package/components/property-editor/index.umd.cjs +3 -0
- package/components/property-panel/index.esm.js +520 -513
- package/components/property-panel/index.umd.cjs +1 -0
- package/components/query-solution/index.css +1 -1
- package/components/query-solution/index.esm.js +1714 -1575
- package/components/query-solution/index.umd.cjs +1 -0
- package/components/radio-button/index.esm.js +67 -67
- package/components/radio-button/index.umd.cjs +1 -0
- package/components/radio-group/index.esm.js +298 -289
- package/components/radio-group/index.umd.cjs +1 -0
- package/components/rate/index.esm.js +195 -190
- package/components/rate/index.umd.cjs +1 -0
- package/components/response-layout/index.esm.js +112 -112
- package/components/response-layout/index.umd.cjs +1 -0
- package/components/response-layout-editor/index.esm.js +902 -877
- package/components/response-layout-editor/index.umd.cjs +1 -0
- package/components/response-toolbar/index.esm.js +874 -778
- package/components/response-toolbar/index.umd.cjs +1 -0
- package/components/schema-selector/index.css +1 -1
- package/components/schema-selector/index.esm.js +4594 -4289
- package/components/schema-selector/index.umd.cjs +8 -0
- package/components/search-box/index.esm.js +126 -126
- package/components/search-box/index.umd.cjs +1 -0
- package/components/section/index.esm.js +645 -503
- package/components/section/index.umd.cjs +1 -0
- package/components/smoke-detector/index.esm.js +120 -120
- package/components/smoke-detector/index.umd.cjs +1 -0
- package/components/spacing-editor/index.umd.cjs +1 -0
- package/components/splitter/index.esm.js +421 -348
- package/components/splitter/index.umd.cjs +1 -0
- package/components/step/index.esm.js +219 -219
- package/components/step/index.umd.cjs +1 -0
- package/components/switch/index.esm.js +232 -222
- package/components/switch/index.umd.cjs +1 -0
- package/components/tabs/index.esm.js +1823 -1744
- package/components/tabs/index.umd.cjs +1 -0
- package/components/tags/index.esm.js +399 -401
- package/components/tags/index.umd.cjs +1 -0
- package/components/text/index.esm.js +164 -164
- package/components/text/index.umd.cjs +1 -0
- package/components/textarea/index.esm.js +220 -215
- package/components/textarea/index.umd.cjs +1 -0
- package/components/time-picker/index.esm.js +693 -666
- package/components/time-picker/index.umd.cjs +1 -0
- package/components/tooltip/index.umd.cjs +1 -0
- package/components/transfer/index.css +1 -1
- package/components/transfer/index.esm.js +422 -413
- package/components/transfer/index.umd.cjs +1 -0
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +4799 -4358
- package/components/tree-grid/index.umd.cjs +1 -0
- package/components/tree-view/index.esm.js +2448 -2215
- package/components/tree-view/index.umd.cjs +1 -0
- package/components/uploader/index.esm.js +164 -164
- package/components/uploader/index.umd.cjs +2 -0
- package/components/verify-detail/index.esm.js +143 -143
- package/components/verify-detail/index.umd.cjs +1 -0
- package/components/video/index.esm.js +410 -331
- package/components/video/index.umd.cjs +1 -0
- package/components/weather/index.esm.js +901 -901
- package/components/weather/index.umd.cjs +16 -0
- package/farris.all.esm.js +12305 -11403
- package/farris.all.umd.cjs +8 -8
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/button-edit/src/designer/button-group.design.component.d.ts +7 -0
- package/types/combo-list/src/components/list-container.component.d.ts +3 -0
- package/types/combo-list/src/components/list-container.props.d.ts +5 -1
- package/types/common/entity/entity-schema.d.ts +258 -0
- package/types/component/src/component-ref.props.d.ts +4 -0
- package/types/component/src/composition/inner-component-build-info.d.ts +27 -0
- package/types/component/src/designer/use-designer-rules.d.ts +2 -2
- package/types/data-grid/index.d.ts +5 -2
- package/types/data-grid/src/composition/data-grid-component-creator.service.d.ts +33 -0
- package/types/data-grid/src/data-grid.component.d.ts +2 -1
- package/types/data-grid/src/data-grid.props.d.ts +2 -2
- package/types/data-grid/src/designer/use-group-column.d.ts +20 -0
- package/types/data-grid/src/property-config/data-grid.property-config.d.ts +4 -0
- package/types/data-grid/src/schema/schema-resolver.d.ts +2 -1
- package/types/data-view/components/column-format/boolean.component.d.ts +4 -0
- package/types/data-view/components/column-format/column-format.component.d.ts +4 -0
- package/types/data-view/components/column-format/date.component.d.ts +4 -0
- package/types/data-view/components/column-format/enum.component.d.ts +4 -0
- package/types/data-view/components/column-format/number.component.d.ts +4 -0
- package/types/data-view/composition/pagination/use-pagination.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +18 -6
- package/types/data-view/composition/use-edit.d.ts +2 -1
- package/types/designer-canvas/src/composition/function/use-dragula.d.ts +2 -2
- package/types/designer-canvas/src/types.d.ts +2 -2
- package/types/dynamic-form/index.d.ts +2 -1
- package/types/dynamic-form/src/composition/response-form-component-creator.service.d.ts +31 -0
- package/types/dynamic-form/src/schema/schema-resolver.d.ts +2 -1
- package/types/dynamic-resolver/src/schema-resolver.d.ts +2 -1
- package/types/dynamic-resolver/src/types.d.ts +3 -2
- package/types/response-toolbar/src/response-toolbar.props.d.ts +2 -2
- package/types/response-toolbar/src/schema/schema-mapper.d.ts +4 -0
- package/types/section/src/property-config/section.property-config.d.ts +93 -0
- package/types/section/src/schema/schema-resolver.d.ts +2 -1
- package/types/tabs/src/composition/types.d.ts +2 -2
- package/types/tabs/src/designer/tab-header-item.design.component.d.ts +3 -1
- package/types/tabs/src/property-config/tab-page.property-config.d.ts +60 -0
- package/types/tabs/src/schema/schema-resolver.d.ts +2 -1
- package/types/tags/index.d.ts +36 -5
|
@@ -1,104 +1,104 @@
|
|
|
1
|
-
import { ref as
|
|
1
|
+
import { ref as g, computed as $, createVNode as l, Fragment as B, watch as X, withModifiers as te, withDirectives as ne, vModelText as le, defineComponent as G, createTextVNode as _, inject as se, onMounted as ae } from "vue";
|
|
2
2
|
import { cloneDeep as oe } from "lodash-es";
|
|
3
|
-
import { useIdentify as
|
|
3
|
+
import { useIdentify as ie, useHierarchy as re, useGroupData as ce, usePagination as ue, useDataView as fe, useSelection as de, useEdit as pe, useVisualDataBound as ve, useVisualDataCell as he, useVisualDataRow as ge, useVisualGroupRow as me, useVisualSummaryRow as ye, useVisualData as we } from "../data-view/index.esm.js";
|
|
4
4
|
import { FCheckBox as q } from "../checkbox/index.esm.js";
|
|
5
5
|
const Q = {}, Y = {};
|
|
6
6
|
function z(t) {
|
|
7
|
-
const { properties: e, title: n } = t,
|
|
8
|
-
return i.id = `${n}-${Date.now()}
|
|
7
|
+
const { properties: e, title: n, ignore: u } = t, v = u && Array.isArray(u), a = Object.keys(e).reduce((i, m) => ((!v || !u.find((r) => r == m)) && (i[m] = e[m].type === "object" && e[m].properties ? z(e[m]) : oe(e[m].default)), i), {});
|
|
8
|
+
return (!v || !u.find((i) => i == "id")) && (a.id = `${n}-${Date.now()}`), a;
|
|
9
9
|
}
|
|
10
|
-
function N(t, e = {}) {
|
|
11
|
-
const
|
|
12
|
-
if (
|
|
13
|
-
let
|
|
14
|
-
const
|
|
15
|
-
return
|
|
10
|
+
function N(t, e = {}, n) {
|
|
11
|
+
const u = Q[t];
|
|
12
|
+
if (u) {
|
|
13
|
+
let v = z(u);
|
|
14
|
+
const a = Y[t];
|
|
15
|
+
return v = a ? a({ getSchemaByType: N }, v, e, n) : v, v;
|
|
16
16
|
}
|
|
17
17
|
return null;
|
|
18
18
|
}
|
|
19
|
-
function
|
|
19
|
+
function Ce(t, e) {
|
|
20
20
|
const n = z(e);
|
|
21
|
-
return Object.keys(t).reduce((
|
|
21
|
+
return Object.keys(t).reduce((u, v) => (u[v] && typeof u[v] == "object" ? Object.assign(u[v], t[v]) : u[v] = t[v], u), n), n;
|
|
22
22
|
}
|
|
23
|
-
function
|
|
24
|
-
return Object.keys(t).filter((
|
|
25
|
-
if (e.has(
|
|
26
|
-
const a = e.get(
|
|
23
|
+
function Se(t, e) {
|
|
24
|
+
return Object.keys(t).filter((u) => t[u] != null).reduce((u, v) => {
|
|
25
|
+
if (e.has(v)) {
|
|
26
|
+
const a = e.get(v);
|
|
27
27
|
if (typeof a == "string")
|
|
28
|
-
|
|
28
|
+
u[a] = t[v];
|
|
29
29
|
else {
|
|
30
|
-
const
|
|
31
|
-
Object.assign(
|
|
30
|
+
const i = a(v, t[v], t);
|
|
31
|
+
Object.assign(u, i);
|
|
32
32
|
}
|
|
33
33
|
} else
|
|
34
|
-
|
|
35
|
-
return
|
|
34
|
+
u[v] = t[v];
|
|
35
|
+
return u;
|
|
36
36
|
}, {});
|
|
37
37
|
}
|
|
38
38
|
function be(t, e, n = /* @__PURE__ */ new Map()) {
|
|
39
|
-
const
|
|
40
|
-
return
|
|
39
|
+
const u = Ce(t, e);
|
|
40
|
+
return Se(u, n);
|
|
41
41
|
}
|
|
42
42
|
function ke(t = {}) {
|
|
43
|
-
function e(
|
|
43
|
+
function e(p, d, o, c) {
|
|
44
44
|
if (typeof o == "number")
|
|
45
|
-
return
|
|
45
|
+
return c[p].length === o;
|
|
46
46
|
if (typeof o == "object") {
|
|
47
|
-
const
|
|
48
|
-
if (
|
|
49
|
-
return Number(
|
|
50
|
-
if (
|
|
51
|
-
return Number(
|
|
52
|
-
if (
|
|
53
|
-
return Number(
|
|
47
|
+
const k = Object.keys(o)[0], S = o[k];
|
|
48
|
+
if (k === "not")
|
|
49
|
+
return Number(c[p].length) !== Number(S);
|
|
50
|
+
if (k === "moreThan")
|
|
51
|
+
return Number(c[p].length) >= Number(S);
|
|
52
|
+
if (k === "lessThan")
|
|
53
|
+
return Number(c[p].length) <= Number(S);
|
|
54
54
|
}
|
|
55
55
|
return !1;
|
|
56
56
|
}
|
|
57
|
-
function n(
|
|
58
|
-
return
|
|
57
|
+
function n(p, d, o, c) {
|
|
58
|
+
return c[p] && c[p].propertyValue && String(c[p].propertyValue.value) === String(o);
|
|
59
59
|
}
|
|
60
|
-
const
|
|
60
|
+
const u = /* @__PURE__ */ new Map([
|
|
61
61
|
["length", e],
|
|
62
62
|
["getProperty", n]
|
|
63
63
|
]);
|
|
64
|
-
Object.keys(t).reduce((
|
|
65
|
-
function
|
|
66
|
-
const o =
|
|
67
|
-
return typeof
|
|
68
|
-
if (
|
|
69
|
-
return { target: o, operator: "length", param: null, value:
|
|
70
|
-
const
|
|
71
|
-
return { target: o, operator: "getProperty", param:
|
|
64
|
+
Object.keys(t).reduce((p, d) => (p.set(d, t[d]), p), u);
|
|
65
|
+
function v(p, d) {
|
|
66
|
+
const o = p;
|
|
67
|
+
return typeof d == "number" ? [{ target: o, operator: "length", param: null, value: Number(d) }] : typeof d == "boolean" ? [{ target: o, operator: "getProperty", param: p, value: !!d }] : typeof d == "object" ? Object.keys(d).map((c) => {
|
|
68
|
+
if (c === "length")
|
|
69
|
+
return { target: o, operator: "length", param: null, value: d[c] };
|
|
70
|
+
const k = c, S = d[c];
|
|
71
|
+
return { target: o, operator: "getProperty", param: k, value: S };
|
|
72
72
|
}) : [];
|
|
73
73
|
}
|
|
74
|
-
function a(
|
|
75
|
-
return Object.keys(
|
|
76
|
-
const
|
|
77
|
-
return o.push(...
|
|
74
|
+
function a(p) {
|
|
75
|
+
return Object.keys(p).reduce((o, c) => {
|
|
76
|
+
const k = v(c, p[c]);
|
|
77
|
+
return o.push(...k), o;
|
|
78
78
|
}, []);
|
|
79
79
|
}
|
|
80
|
-
function
|
|
81
|
-
if (
|
|
82
|
-
const o =
|
|
83
|
-
return o && o(
|
|
80
|
+
function i(p, d) {
|
|
81
|
+
if (u.has(p.operator)) {
|
|
82
|
+
const o = u.get(p.operator);
|
|
83
|
+
return o && o(p.target, p.param, p.value, d) || !1;
|
|
84
84
|
}
|
|
85
85
|
return !1;
|
|
86
86
|
}
|
|
87
|
-
function
|
|
88
|
-
return a(
|
|
87
|
+
function m(p, d) {
|
|
88
|
+
return a(p).reduce((k, S) => k && i(S, d), !0);
|
|
89
89
|
}
|
|
90
|
-
function
|
|
91
|
-
const o = Object.keys(
|
|
92
|
-
return
|
|
90
|
+
function r(p, d) {
|
|
91
|
+
const o = Object.keys(p), c = o.includes("allOf"), k = o.includes("anyOf"), S = c || k, D = (S ? p[S ? c ? "allOf" : "anyOf" : "allOf"] : [p]).map((O) => m(O, d));
|
|
92
|
+
return c ? !D.includes(!1) : D.includes(!0);
|
|
93
93
|
}
|
|
94
|
-
return { parseValueSchema:
|
|
94
|
+
return { parseValueSchema: r };
|
|
95
95
|
}
|
|
96
96
|
const Ve = {}, Me = {};
|
|
97
97
|
ke();
|
|
98
|
-
function Z(t, e, n = /* @__PURE__ */ new Map(),
|
|
99
|
-
return Q[e.title] = e, Y[e.title] =
|
|
100
|
-
const
|
|
101
|
-
return Object.assign(
|
|
98
|
+
function Z(t, e, n = /* @__PURE__ */ new Map(), u = (i, m, r) => m, v = {}, a = (i) => i) {
|
|
99
|
+
return Q[e.title] = e, Y[e.title] = u, Ve[e.title] = v, Me[e.title] = a, (i = {}) => {
|
|
100
|
+
const m = be(i, e, n), r = Object.keys(t).reduce((p, d) => (p[d] = t[d].default, p), {});
|
|
101
|
+
return Object.assign(r, m);
|
|
102
102
|
};
|
|
103
103
|
}
|
|
104
104
|
function K(t, e) {
|
|
@@ -110,7 +110,7 @@ const De = /* @__PURE__ */ new Map([
|
|
|
110
110
|
function Te(t, e, n) {
|
|
111
111
|
return e;
|
|
112
112
|
}
|
|
113
|
-
const Oe = "transfer",
|
|
113
|
+
const Oe = "transfer", Ie = "A Farris Component", Fe = "object", je = {
|
|
114
114
|
basic: {
|
|
115
115
|
description: "Basic Infomation",
|
|
116
116
|
title: "基本信息",
|
|
@@ -134,10 +134,10 @@ const Oe = "transfer", Fe = "A Farris Component", Ie = "object", je = {
|
|
|
134
134
|
}
|
|
135
135
|
}, Re = {
|
|
136
136
|
title: Oe,
|
|
137
|
-
description:
|
|
138
|
-
type:
|
|
137
|
+
description: Ie,
|
|
138
|
+
type: Fe,
|
|
139
139
|
categories: je
|
|
140
|
-
}, $e = "https://json-schema.org/draft/2020-12/schema", Pe = "https://farris-design.gitee.io/transfer.schema.json", Ae = "transfer",
|
|
140
|
+
}, $e = "https://json-schema.org/draft/2020-12/schema", Pe = "https://farris-design.gitee.io/transfer.schema.json", Ae = "transfer", Le = "A Farris Component", Ee = "object", He = {
|
|
141
141
|
id: {
|
|
142
142
|
description: "The unique identifier for transfer",
|
|
143
143
|
type: "string"
|
|
@@ -199,17 +199,17 @@ const Oe = "transfer", Fe = "A Farris Component", Ie = "object", je = {
|
|
|
199
199
|
type: "boolean",
|
|
200
200
|
default: !0
|
|
201
201
|
}
|
|
202
|
-
},
|
|
202
|
+
}, _e = [
|
|
203
203
|
"id",
|
|
204
204
|
"type"
|
|
205
205
|
], Ne = {
|
|
206
206
|
$schema: $e,
|
|
207
207
|
$id: Pe,
|
|
208
208
|
title: Ae,
|
|
209
|
-
description:
|
|
210
|
-
type:
|
|
211
|
-
properties:
|
|
212
|
-
required:
|
|
209
|
+
description: Le,
|
|
210
|
+
type: Ee,
|
|
211
|
+
properties: He,
|
|
212
|
+
required: _e
|
|
213
213
|
}, U = {
|
|
214
214
|
dataSource: {
|
|
215
215
|
type: Array,
|
|
@@ -373,173 +373,176 @@ const qe = "https://json-schema.org/draft/2020-12/schema", ze = "https://farris-
|
|
|
373
373
|
Z(ee, Ye, Be, Ge, tt);
|
|
374
374
|
function nt(t, e) {
|
|
375
375
|
function n(a) {
|
|
376
|
-
const
|
|
377
|
-
let
|
|
378
|
-
for (;
|
|
379
|
-
|
|
380
|
-
return
|
|
376
|
+
const i = [];
|
|
377
|
+
let m = a.nextNode();
|
|
378
|
+
for (; m; )
|
|
379
|
+
i.push(m), m = a.nextNode();
|
|
380
|
+
return i;
|
|
381
381
|
}
|
|
382
|
-
function
|
|
383
|
-
const
|
|
384
|
-
return n(
|
|
385
|
-
const
|
|
386
|
-
let
|
|
387
|
-
for (;
|
|
388
|
-
const V =
|
|
382
|
+
function u(a, i) {
|
|
383
|
+
const m = document.createTreeWalker(a, NodeFilter.SHOW_TEXT);
|
|
384
|
+
return n(m).map((o) => ({ textNode: o, text: (o.textContent || "").toLocaleLowerCase() })).map(({ textNode: o, text: c }) => {
|
|
385
|
+
const k = [];
|
|
386
|
+
let S = 0;
|
|
387
|
+
for (; S < c.length; ) {
|
|
388
|
+
const V = c.indexOf(i, S);
|
|
389
389
|
if (V === -1)
|
|
390
390
|
break;
|
|
391
|
-
|
|
391
|
+
k.push(V), S = V + i.length;
|
|
392
392
|
}
|
|
393
|
-
return
|
|
394
|
-
const
|
|
395
|
-
return
|
|
393
|
+
return k.map((V) => {
|
|
394
|
+
const I = new Range();
|
|
395
|
+
return I.setStart(o, V), I.setEnd(o, V + i.length), I;
|
|
396
396
|
});
|
|
397
397
|
}).flat();
|
|
398
398
|
}
|
|
399
|
-
function
|
|
399
|
+
function v(a) {
|
|
400
400
|
if (!CSS.highlights || (CSS.highlights.clear(), !a || !e))
|
|
401
401
|
return;
|
|
402
|
-
const
|
|
403
|
-
CSS.highlights.set("search-result",
|
|
402
|
+
const i = u(e.value, a.toLocaleLowerCase()), m = new Highlight(...i);
|
|
403
|
+
CSS.highlights.set("search-result", m);
|
|
404
404
|
}
|
|
405
|
-
return { search:
|
|
405
|
+
return { search: v };
|
|
406
406
|
}
|
|
407
|
-
function W(t, e, n,
|
|
408
|
-
const
|
|
407
|
+
function W(t, e, n, u, v, a, i, m, r, p) {
|
|
408
|
+
const d = g(t.size), o = g(t.textField), c = g(t.titleField), k = g(t.disableField), S = $(() => {
|
|
409
|
+
var f, y;
|
|
410
|
+
return ((f = t.selection) == null ? void 0 : f.multiSelect) && ((y = t.selection) == null ? void 0 : y.showCheckbox);
|
|
411
|
+
}), {
|
|
409
412
|
onMouseenterItem: V,
|
|
410
|
-
onMouseoverItem:
|
|
413
|
+
onMouseoverItem: I,
|
|
411
414
|
onMouseoutItem: D
|
|
412
415
|
} = a, {
|
|
413
416
|
getKey: M,
|
|
414
|
-
listViewItemClass:
|
|
417
|
+
listViewItemClass: O,
|
|
415
418
|
onCheckItem: P,
|
|
416
419
|
onClickItem: T
|
|
417
|
-
} =
|
|
418
|
-
margin:
|
|
420
|
+
} = i, w = $(() => ({
|
|
421
|
+
margin: d.value === "small" ? "0.25rem 0" : "10px 0"
|
|
419
422
|
}));
|
|
420
|
-
function
|
|
421
|
-
return f.checked =
|
|
422
|
-
class:
|
|
423
|
-
id: M(f,
|
|
424
|
-
key: M(f,
|
|
425
|
-
onClick: (s) => T(s, f,
|
|
426
|
-
onMouseenter: (s) => V(s, f,
|
|
427
|
-
onMouseover: (s) =>
|
|
428
|
-
onMouseout: (s) => D(s, f,
|
|
429
|
-
}, [
|
|
423
|
+
function F(f, y, b) {
|
|
424
|
+
return f.checked = m.findIndexInSelectedItems(f) > -1, l("li", {
|
|
425
|
+
class: O(f, y),
|
|
426
|
+
id: M(f, y),
|
|
427
|
+
key: M(f, y),
|
|
428
|
+
onClick: (s) => T(s, f, y),
|
|
429
|
+
onMouseenter: (s) => V(s, f, y),
|
|
430
|
+
onMouseover: (s) => I(s, f, y),
|
|
431
|
+
onMouseout: (s) => D(s, f, y)
|
|
432
|
+
}, [S.value && l("div", {
|
|
430
433
|
class: "f-list-select",
|
|
431
434
|
onClick: (s) => s.stopPropagation()
|
|
432
435
|
}, [l(q, {
|
|
433
|
-
id: "list-" + M(f,
|
|
436
|
+
id: "list-" + M(f, y),
|
|
434
437
|
customClass: "listview-checkbox",
|
|
435
|
-
disabled: f[
|
|
438
|
+
disabled: f[k.value],
|
|
436
439
|
checked: f.checked,
|
|
437
440
|
"onUpdate:checked": (s) => f.checked = s,
|
|
438
441
|
onChange: (s) => {
|
|
439
|
-
P(f,
|
|
442
|
+
P(f, y, !s.checked);
|
|
440
443
|
}
|
|
441
444
|
}, null)]), l("div", {
|
|
442
445
|
class: "f-list-content"
|
|
443
446
|
}, [l("div", {
|
|
444
|
-
style:
|
|
445
|
-
title: f.raw[
|
|
447
|
+
style: w.value,
|
|
448
|
+
title: f.raw[c.value] || f.raw[o.value]
|
|
446
449
|
}, [f.raw[o.value]])])]);
|
|
447
450
|
}
|
|
448
451
|
return {
|
|
449
|
-
renderItem:
|
|
452
|
+
renderItem: F
|
|
450
453
|
};
|
|
451
454
|
}
|
|
452
|
-
function lt(t, e, n,
|
|
453
|
-
const
|
|
454
|
-
onMouseenterItem:
|
|
455
|
-
onMouseoverItem:
|
|
456
|
-
onMouseoutItem:
|
|
455
|
+
function lt(t, e, n, u, v, a, i, m, r, p) {
|
|
456
|
+
const d = g(t.multiSelect), o = g(t.disableField), {
|
|
457
|
+
onMouseenterItem: c,
|
|
458
|
+
onMouseoverItem: k,
|
|
459
|
+
onMouseoutItem: S
|
|
457
460
|
} = a, {
|
|
458
461
|
getKey: V,
|
|
459
|
-
listViewItemClass:
|
|
462
|
+
listViewItemClass: I,
|
|
460
463
|
onCheckItem: D,
|
|
461
464
|
onClickItem: M
|
|
462
|
-
} =
|
|
463
|
-
function
|
|
465
|
+
} = i;
|
|
466
|
+
function O(T, w, F) {
|
|
464
467
|
return e.slots.content ? l(B, null, [e.slots.content && e.slots.content({
|
|
465
468
|
item: T.raw,
|
|
466
|
-
index:
|
|
467
|
-
selectedItem:
|
|
469
|
+
index: w,
|
|
470
|
+
selectedItem: F
|
|
468
471
|
})]) : l("div", {
|
|
469
472
|
style: "margin: 10px 0;"
|
|
470
473
|
}, [T.raw.name]);
|
|
471
474
|
}
|
|
472
|
-
function P(T,
|
|
475
|
+
function P(T, w, F) {
|
|
473
476
|
return l("li", {
|
|
474
|
-
class:
|
|
475
|
-
id: V(T,
|
|
476
|
-
key: V(T,
|
|
477
|
-
onClick: (f) => M(f, T,
|
|
478
|
-
onMouseenter: (f) =>
|
|
479
|
-
onMouseover: (f) =>
|
|
480
|
-
onMouseout: (f) =>
|
|
481
|
-
}, [
|
|
477
|
+
class: I(T, w),
|
|
478
|
+
id: V(T, w),
|
|
479
|
+
key: V(T, w),
|
|
480
|
+
onClick: (f) => M(f, T, w),
|
|
481
|
+
onMouseenter: (f) => c(f, T, w),
|
|
482
|
+
onMouseover: (f) => k(f, T, w),
|
|
483
|
+
onMouseout: (f) => S(f, T, w)
|
|
484
|
+
}, [d.value && l("div", {
|
|
482
485
|
class: "f-list-select",
|
|
483
486
|
onClick: (f) => f.stopPropagation()
|
|
484
487
|
}, [l(q, {
|
|
485
|
-
id: "list-" + V(T,
|
|
488
|
+
id: "list-" + V(T, w),
|
|
486
489
|
customClass: "listview-checkbox",
|
|
487
490
|
disabled: T[o.value] || !T.checked,
|
|
488
491
|
checked: T.checked,
|
|
489
492
|
"onUpdate:checked": (f) => T.checked = f,
|
|
490
|
-
onChange: (f) => D(T,
|
|
493
|
+
onChange: (f) => D(T, w, !f.checked)
|
|
491
494
|
}, null)]), l("div", {
|
|
492
495
|
class: "f-list-content"
|
|
493
|
-
}, [
|
|
496
|
+
}, [O(T, w, F)])]);
|
|
494
497
|
}
|
|
495
498
|
return {
|
|
496
499
|
renderItem: P
|
|
497
500
|
};
|
|
498
501
|
}
|
|
499
|
-
function st(t, e, n,
|
|
500
|
-
const
|
|
501
|
-
onMouseenterItem:
|
|
502
|
-
onMouseoverItem:
|
|
503
|
-
onMouseoutItem:
|
|
502
|
+
function st(t, e, n, u, v, a, i, m, r, p) {
|
|
503
|
+
const d = g(t.multiSelect), o = g(t.disableField), {
|
|
504
|
+
onMouseenterItem: c,
|
|
505
|
+
onMouseoverItem: k,
|
|
506
|
+
onMouseoutItem: S
|
|
504
507
|
} = a, {
|
|
505
508
|
getKey: V,
|
|
506
|
-
listViewItemClass:
|
|
509
|
+
listViewItemClass: I,
|
|
507
510
|
onCheckItem: D,
|
|
508
511
|
onClickItem: M
|
|
509
|
-
} =
|
|
510
|
-
dragstart:
|
|
512
|
+
} = i, {
|
|
513
|
+
dragstart: O,
|
|
511
514
|
dragenter: P,
|
|
512
515
|
dragover: T,
|
|
513
|
-
dragend:
|
|
514
|
-
} =
|
|
515
|
-
removeItem:
|
|
516
|
-
} =
|
|
517
|
-
margin:
|
|
516
|
+
dragend: w
|
|
517
|
+
} = u, {
|
|
518
|
+
removeItem: F
|
|
519
|
+
} = r, f = $(() => ({
|
|
520
|
+
margin: d.value ? "10px 0" : "10px 0px 10px 14px"
|
|
518
521
|
}));
|
|
519
|
-
function
|
|
522
|
+
function y(h) {
|
|
520
523
|
return l("div", {
|
|
521
524
|
style: f.value
|
|
522
525
|
}, [h.raw.name]);
|
|
523
526
|
}
|
|
524
|
-
function
|
|
525
|
-
return e.slots.itemContent ? e.slots.itemContent :
|
|
527
|
+
function b() {
|
|
528
|
+
return e.slots.itemContent ? e.slots.itemContent : y;
|
|
526
529
|
}
|
|
527
|
-
const s =
|
|
528
|
-
function C(h, j,
|
|
530
|
+
const s = b();
|
|
531
|
+
function C(h, j, A) {
|
|
529
532
|
return l("li", {
|
|
530
|
-
class:
|
|
533
|
+
class: I(h, j),
|
|
531
534
|
id: V(h, j),
|
|
532
535
|
key: V(h, j),
|
|
533
536
|
onClick: (R) => M(R, h, j),
|
|
534
|
-
onMouseenter: (R) =>
|
|
535
|
-
onMouseover: (R) =>
|
|
536
|
-
onMouseout: (R) =>
|
|
537
|
+
onMouseenter: (R) => c(R, h, j),
|
|
538
|
+
onMouseover: (R) => k(R, h, j),
|
|
539
|
+
onMouseout: (R) => S(R, h, j),
|
|
537
540
|
draggable: "true",
|
|
538
|
-
onDragstart: (R) =>
|
|
541
|
+
onDragstart: (R) => O(R, h, j),
|
|
539
542
|
onDragenter: (R) => P(R, j),
|
|
540
|
-
onDragend: (R) =>
|
|
543
|
+
onDragend: (R) => w(R, h),
|
|
541
544
|
onDragover: (R) => T(R, j)
|
|
542
|
-
}, [
|
|
545
|
+
}, [d.value && l("div", {
|
|
543
546
|
class: "f-list-select",
|
|
544
547
|
onClick: (R) => R.stopPropagation()
|
|
545
548
|
}, [l(q, {
|
|
@@ -553,7 +556,7 @@ function st(t, e, n, i, g, a, v, y, c, d) {
|
|
|
553
556
|
class: "f-list-content"
|
|
554
557
|
}, [s(h)]), l("div", {
|
|
555
558
|
class: "f-list-remove",
|
|
556
|
-
onClick: (R) =>
|
|
559
|
+
onClick: (R) => F(j)
|
|
557
560
|
}, [l("div", {
|
|
558
561
|
class: "f-list-remove-icon"
|
|
559
562
|
}, [l("i", {
|
|
@@ -568,204 +571,210 @@ function st(t, e, n, i, g, a, v, y, c, d) {
|
|
|
568
571
|
renderItem: C
|
|
569
572
|
};
|
|
570
573
|
}
|
|
571
|
-
function at(t, e, n,
|
|
574
|
+
function at(t, e, n, u, v, a, i, m, r, p) {
|
|
572
575
|
var V;
|
|
573
|
-
const
|
|
576
|
+
const d = g(((V = t.group) == null ? void 0 : V.groupFields) || []), {
|
|
574
577
|
collpaseGroupIconClass: o
|
|
575
|
-
} =
|
|
576
|
-
toggleGroupRow:
|
|
577
|
-
} =
|
|
578
|
-
function
|
|
579
|
-
D.collapse = !D.collapse, n.value =
|
|
578
|
+
} = v, {
|
|
579
|
+
toggleGroupRow: c
|
|
580
|
+
} = p;
|
|
581
|
+
function k(I, D) {
|
|
582
|
+
D.collapse = !D.collapse, n.value = c(D.collapse ? "collapse" : "expand", D, n.value);
|
|
580
583
|
}
|
|
581
|
-
function
|
|
582
|
-
return
|
|
584
|
+
function S(I, D, M) {
|
|
585
|
+
return I.layer > -1 && l("div", {
|
|
583
586
|
class: "f-navlookup-recentHeader",
|
|
584
|
-
onClick: (
|
|
587
|
+
onClick: (O) => k(O, I)
|
|
585
588
|
}, [l("div", {
|
|
586
589
|
class: "fv-grid-group-row-icon"
|
|
587
590
|
}, [l("span", {
|
|
588
|
-
class: o(
|
|
591
|
+
class: o(I)
|
|
589
592
|
}, null)]), l("div", {
|
|
590
593
|
class: "f-navlookup-recommandLabel"
|
|
591
|
-
}, [
|
|
594
|
+
}, [I.raw[d.value[I.layer]]])]);
|
|
592
595
|
}
|
|
593
596
|
return {
|
|
594
|
-
renderItem:
|
|
597
|
+
renderItem: S
|
|
595
598
|
};
|
|
596
599
|
}
|
|
597
600
|
function ot() {
|
|
598
|
-
const t =
|
|
599
|
-
function
|
|
601
|
+
const t = g(-1), e = g(""), n = g(-1), u = g(!1);
|
|
602
|
+
function v(p, d, o) {
|
|
600
603
|
n.value = o;
|
|
601
604
|
}
|
|
602
|
-
function a(
|
|
603
|
-
|
|
605
|
+
function a(p, d, o) {
|
|
606
|
+
u.value || (n.value = o);
|
|
604
607
|
}
|
|
605
|
-
function
|
|
608
|
+
function i(p, d, o) {
|
|
606
609
|
n.value = -1;
|
|
607
610
|
}
|
|
608
|
-
function
|
|
609
|
-
|
|
611
|
+
function m() {
|
|
612
|
+
u.value = !0;
|
|
610
613
|
}
|
|
611
|
-
function
|
|
612
|
-
|
|
614
|
+
function r() {
|
|
615
|
+
u.value = !1;
|
|
613
616
|
}
|
|
614
617
|
return {
|
|
615
618
|
activeIndex: t,
|
|
616
619
|
focusedItemId: e,
|
|
617
620
|
hoverIndex: n,
|
|
618
|
-
onMouseenterItem:
|
|
621
|
+
onMouseenterItem: v,
|
|
619
622
|
onMouseoverItem: a,
|
|
620
|
-
onMouseoutItem:
|
|
621
|
-
resumeHover:
|
|
622
|
-
suspendHover:
|
|
623
|
+
onMouseoutItem: i,
|
|
624
|
+
resumeHover: r,
|
|
625
|
+
suspendHover: m
|
|
623
626
|
};
|
|
624
627
|
}
|
|
625
|
-
function
|
|
626
|
-
const
|
|
627
|
-
function
|
|
628
|
-
D.stopPropagation(),
|
|
629
|
-
|
|
628
|
+
function it(t, e, n, u) {
|
|
629
|
+
const v = g(t.idField), { dataView: a } = n, i = g(-1), m = g(!1), { activeIndex: r, focusedItemId: p, hoverIndex: d, resumeHover: o, suspendHover: c } = u;
|
|
630
|
+
function k(D, M, O) {
|
|
631
|
+
D.stopPropagation(), c(), M && setTimeout(() => {
|
|
632
|
+
i.value = O, m.value = !0, M.moving = !0;
|
|
630
633
|
});
|
|
631
634
|
}
|
|
632
|
-
function
|
|
633
|
-
if (D.preventDefault(),
|
|
634
|
-
const
|
|
635
|
-
P.splice(
|
|
635
|
+
function S(D, M) {
|
|
636
|
+
if (D.preventDefault(), i.value !== M) {
|
|
637
|
+
const O = a.value[i.value], P = a.value;
|
|
638
|
+
P.splice(i.value, 1), P.splice(M, 0, O), i.value = M;
|
|
636
639
|
}
|
|
637
640
|
}
|
|
638
641
|
function V(D, M) {
|
|
639
642
|
D.preventDefault(), D.dataTransfer && (D.dataTransfer.dropEffect = "move");
|
|
640
643
|
}
|
|
641
|
-
function
|
|
642
|
-
M && (M.moving = !1), a.value.forEach((
|
|
643
|
-
|
|
644
|
-
}),
|
|
644
|
+
function I(D, M) {
|
|
645
|
+
M && (M.moving = !1), a.value.forEach((O, P) => {
|
|
646
|
+
O.__fv_index__ = P;
|
|
647
|
+
}), m.value = !1, o(), d.value = M.raw.__fv_index__, r.value = M.raw.__fv_index__, p.value = M.raw[v.value], e.emit("change", a.value), e.emit("activeChange", M);
|
|
645
648
|
}
|
|
646
649
|
return {
|
|
647
|
-
dragstart:
|
|
648
|
-
dragenter:
|
|
650
|
+
dragstart: k,
|
|
651
|
+
dragenter: S,
|
|
649
652
|
dragover: V,
|
|
650
|
-
dragend:
|
|
651
|
-
isDragging:
|
|
653
|
+
dragend: I,
|
|
654
|
+
isDragging: m
|
|
652
655
|
};
|
|
653
656
|
}
|
|
654
|
-
function
|
|
655
|
-
const { dataView:
|
|
656
|
-
function
|
|
657
|
-
if (a > -1 && a <
|
|
658
|
-
const
|
|
659
|
-
e.emit("removeItem",
|
|
657
|
+
function rt(t, e, n) {
|
|
658
|
+
const { dataView: u } = n;
|
|
659
|
+
function v(a) {
|
|
660
|
+
if (a > -1 && a < u.value.length) {
|
|
661
|
+
const i = u.value.splice(a, 1);
|
|
662
|
+
e.emit("removeItem", i[0]);
|
|
660
663
|
}
|
|
661
664
|
}
|
|
662
|
-
return { removeItem:
|
|
665
|
+
return { removeItem: v };
|
|
663
666
|
}
|
|
664
|
-
function ct(t, e, n,
|
|
665
|
-
const
|
|
666
|
-
p(!0);
|
|
667
|
-
const { isDragging: r } = i, { activeIndex: b, focusedItemId: w, hoverIndex: V } = g, { clearSelection: F, getSelectedItems: D, toggleSelectItem: M } = a, I = p(D());
|
|
667
|
+
function ct(t, e, n, u, v, a) {
|
|
668
|
+
const i = g(t.idField), m = g(t.disableField), r = g(t.draggable), p = g(t.itemClass), d = g(t.selection.multiSelect ?? !1), o = g(t.selection.multiSelectMode), { isDragging: c } = u, { activeIndex: k, focusedItemId: S, hoverIndex: V } = v, { clearSelection: I, getSelectedItems: D, toggleSelectItem: M } = a, O = g(D());
|
|
668
669
|
function P(s, C) {
|
|
669
670
|
const h = {
|
|
671
|
+
"f-listview-item": !0,
|
|
670
672
|
"f-list-view-group-item": !0,
|
|
671
|
-
"f-list-view-draggable-item":
|
|
673
|
+
"f-list-view-draggable-item": r.value,
|
|
672
674
|
"f-un-click": !s.checked,
|
|
673
|
-
"f-un-select": !!s.raw[
|
|
674
|
-
|
|
675
|
-
|
|
675
|
+
"f-un-select": !!s.raw[m.value],
|
|
676
|
+
// 'f-listview-active': item.raw.__fv_index__ === activeIndex.value,
|
|
677
|
+
// 多选
|
|
678
|
+
"f-listview-active": O.value.findIndex(
|
|
679
|
+
(A) => A[i.value] === s.raw[i.value]
|
|
680
|
+
) > -1,
|
|
681
|
+
"f-listview-item-active": O.value.findIndex(
|
|
682
|
+
(A) => A[i.value] === s.raw[i.value]
|
|
683
|
+
) > -1,
|
|
684
|
+
"f-listview-hover": !c.value && C === V.value,
|
|
676
685
|
moving: !!s.moving
|
|
677
686
|
};
|
|
678
|
-
return
|
|
687
|
+
return p.value.split(" ").reduce((A, R) => (A[R] = !0, A), h), h;
|
|
679
688
|
}
|
|
680
689
|
function T(s, C) {
|
|
681
|
-
return s.raw[
|
|
690
|
+
return s.raw[i.value] || "";
|
|
682
691
|
}
|
|
683
|
-
const
|
|
684
|
-
function
|
|
685
|
-
s.checked = h, !s.raw[
|
|
692
|
+
const w = $(() => !d.value);
|
|
693
|
+
function F(s, C, h) {
|
|
694
|
+
s.checked = h, !s.raw[m.value] && (w.value && (S.value = s.raw[i.value]), M(s));
|
|
686
695
|
}
|
|
687
|
-
const f = $(() =>
|
|
688
|
-
function
|
|
689
|
-
if (C.raw[
|
|
696
|
+
const f = $(() => d.value && o.value === "OnCheckClearByClick"), y = $(() => !d.value || d.value && (o.value === "OnCheckAndClick" || o.value === "OnClick"));
|
|
697
|
+
function b(s, C, h) {
|
|
698
|
+
if (C.raw[m.value]) {
|
|
690
699
|
s.preventDefault(), s.stopPropagation();
|
|
691
700
|
return;
|
|
692
701
|
}
|
|
693
|
-
|
|
702
|
+
S.value = C.raw[i.value], k.value = h, f.value && I(n.value), y.value && (M(C), O.value = D()), e.emit("clickItem", { data: O.value, index: h }), e.emit("activeChange", O.value);
|
|
694
703
|
}
|
|
695
704
|
return {
|
|
696
705
|
getKey: T,
|
|
697
706
|
listViewItemClass: P,
|
|
698
|
-
onCheckItem:
|
|
699
|
-
onClickItem:
|
|
707
|
+
onCheckItem: F,
|
|
708
|
+
onClickItem: b
|
|
700
709
|
};
|
|
701
710
|
}
|
|
702
|
-
function ut(t, e, n,
|
|
703
|
-
const
|
|
711
|
+
function ut(t, e, n, u, v, a, i) {
|
|
712
|
+
const m = g(t.view), r = g(t.view === "CardView"), p = g({}), d = g("暂无数据"), o = ot(), c = it(t, e, u, o), k = rt(t, e, u), S = ct(t, e, n, c, o, a), V = $(() => ({
|
|
704
713
|
"f-list-view-group": !0,
|
|
705
|
-
"d-flex":
|
|
706
|
-
"flex-wrap":
|
|
707
|
-
})),
|
|
708
|
-
function
|
|
709
|
-
return
|
|
714
|
+
"d-flex": r.value,
|
|
715
|
+
"flex-wrap": r.value
|
|
716
|
+
})), I = $(() => !!n.value && n.value.length > 0), D = $(() => n.value.length === 0), M = $(() => D.value && !e.slots.empty);
|
|
717
|
+
function O() {
|
|
718
|
+
return m.value === "SingleView" ? W : m.value === "DraggableView" ? st : (m.value === "ContentView" || m.value === "CardView") && e.slots.content ? lt : W;
|
|
710
719
|
}
|
|
711
|
-
const P =
|
|
720
|
+
const P = O(), {
|
|
712
721
|
renderItem: T
|
|
713
|
-
} = P(t, e, n,
|
|
714
|
-
renderItem:
|
|
715
|
-
} = at(t, e, n,
|
|
722
|
+
} = P(t, e, n, c, v, o, S, a, k, i), {
|
|
723
|
+
renderItem: w
|
|
724
|
+
} = at(t, e, n, c, v, o, S, a, k, i), F = [T, w];
|
|
716
725
|
function f() {
|
|
717
|
-
return n.value.filter((s) => s.visible !== !1).map((s, C) =>
|
|
726
|
+
return n.value.filter((s) => s.visible !== !1).map((s, C) => F[s.type](s, C, p));
|
|
718
727
|
}
|
|
719
|
-
function
|
|
728
|
+
function y() {
|
|
720
729
|
return l("div", {
|
|
721
730
|
class: "f-list-view-emptydata"
|
|
722
731
|
}, [l("p", {
|
|
723
732
|
class: "f-empty-title"
|
|
724
|
-
}, [
|
|
733
|
+
}, [d.value])]);
|
|
725
734
|
}
|
|
726
|
-
function
|
|
735
|
+
function b() {
|
|
727
736
|
return l("ul", {
|
|
728
737
|
class: V.value,
|
|
729
738
|
style: "list-style: none;"
|
|
730
|
-
}, [
|
|
739
|
+
}, [I.value && f(), M.value && y(), e.slots.empty && e.slots.empty()]);
|
|
731
740
|
}
|
|
732
741
|
return {
|
|
733
|
-
renderListArea:
|
|
742
|
+
renderListArea: b
|
|
734
743
|
};
|
|
735
744
|
}
|
|
736
745
|
function ft(t, e, n) {
|
|
737
|
-
function
|
|
746
|
+
function u() {
|
|
738
747
|
return e.slots.header && l("div", {
|
|
739
748
|
class: "f-list-view-header"
|
|
740
749
|
}, [e.slots.header()]);
|
|
741
750
|
}
|
|
742
751
|
return {
|
|
743
|
-
renderHeader:
|
|
752
|
+
renderHeader: u
|
|
744
753
|
};
|
|
745
754
|
}
|
|
746
755
|
function J(t, e, n) {
|
|
747
|
-
const
|
|
748
|
-
function c
|
|
756
|
+
const u = g(t.headerClass), v = g(t.placeholder), a = g(""), i = $(() => !a.value), m = $(() => !!a.value);
|
|
757
|
+
function r(c) {
|
|
749
758
|
a.value = "";
|
|
750
759
|
}
|
|
751
|
-
X(a, (
|
|
752
|
-
t.enableHighlightSearch && n.search(
|
|
760
|
+
X(a, (c) => {
|
|
761
|
+
t.enableHighlightSearch && n.search(c), e.emit("afterSearch", c);
|
|
753
762
|
});
|
|
754
|
-
const
|
|
755
|
-
const
|
|
763
|
+
const p = $(() => {
|
|
764
|
+
const c = {
|
|
756
765
|
"form-group": !0,
|
|
757
766
|
"farris-form-group": !0
|
|
758
767
|
};
|
|
759
|
-
return
|
|
768
|
+
return u.value && u.value.split(" ").reduce((S, V) => (S[V] = !0, S), c), c;
|
|
760
769
|
});
|
|
761
|
-
function
|
|
770
|
+
function d(c) {
|
|
762
771
|
}
|
|
763
772
|
function o() {
|
|
764
773
|
return l("div", {
|
|
765
774
|
class: "f-list-view-header",
|
|
766
|
-
onClick: te(() =>
|
|
775
|
+
onClick: te(() => d, ["prevent", "stop"])
|
|
767
776
|
}, [l("div", {
|
|
768
|
-
class:
|
|
777
|
+
class: p.value
|
|
769
778
|
}, [l("div", {
|
|
770
779
|
class: "farris-input-wrap"
|
|
771
780
|
}, [l("div", {
|
|
@@ -774,19 +783,19 @@ function J(t, e, n) {
|
|
|
774
783
|
class: "input-group f-state-editable"
|
|
775
784
|
}, [ne(l("input", {
|
|
776
785
|
class: "form-control f-utils-fill text-left",
|
|
777
|
-
"onUpdate:modelValue": (
|
|
786
|
+
"onUpdate:modelValue": (c) => a.value = c,
|
|
778
787
|
name: "input-group-value",
|
|
779
788
|
type: "text",
|
|
780
|
-
placeholder:
|
|
789
|
+
placeholder: v.value,
|
|
781
790
|
autocomplete: "off"
|
|
782
791
|
}, null), [[le, a.value]]), l("div", {
|
|
783
792
|
class: "input-group-append"
|
|
784
|
-
}, [
|
|
793
|
+
}, [m.value && l("span", {
|
|
785
794
|
class: "input-group-text input-group-clear",
|
|
786
|
-
onClick: (
|
|
795
|
+
onClick: (c) => r()
|
|
787
796
|
}, [l("i", {
|
|
788
797
|
class: "f-icon f-icon-close-circle"
|
|
789
|
-
}, null)]),
|
|
798
|
+
}, null)]), i.value && l("span", {
|
|
790
799
|
class: "input-group-text"
|
|
791
800
|
}, [l("span", {
|
|
792
801
|
class: "f-icon f-icon-search"
|
|
@@ -796,42 +805,42 @@ function J(t, e, n) {
|
|
|
796
805
|
renderHeader: o
|
|
797
806
|
};
|
|
798
807
|
}
|
|
799
|
-
const
|
|
808
|
+
const E = /* @__PURE__ */ G({
|
|
800
809
|
name: "FListView",
|
|
801
810
|
props: ee,
|
|
802
811
|
emits: ["afterSearch", "checkValuesChange", "clickItem", "selectionChange", "removeItem", "change", "activeChange"],
|
|
803
812
|
setup(t, e) {
|
|
804
|
-
const n =
|
|
805
|
-
getVisualData:
|
|
806
|
-
} =
|
|
807
|
-
a.value =
|
|
813
|
+
const n = g(), u = g(!0), v = g(!1), a = g([]), i = 0, m = g(t.columns), r = ie(t), p = re(t), d = ce(t, r), o = ue(t), c = fe(t, /* @__PURE__ */ new Map(), p, r, o), k = de(t, c, r, a, e), S = nt(t, n), V = $(() => c.dataView.value.length), I = pe(t, e, r), D = ve(), M = he(t, {}, D), O = ge(t, I, p, r, D, M), P = me(t, r, M, O), T = ye(t, r, M, O), w = we(t, m, c, V, i, O, P, T), {
|
|
814
|
+
getVisualData: F
|
|
815
|
+
} = w;
|
|
816
|
+
a.value = F(0, V.value + i - 1);
|
|
808
817
|
const f = $(() => {
|
|
809
|
-
const
|
|
818
|
+
const L = {
|
|
810
819
|
"f-list-view": !0,
|
|
811
820
|
"f-list-view-multiple": t.multiSelect
|
|
812
821
|
};
|
|
813
|
-
return t.size !== "default" && (
|
|
814
|
-
}),
|
|
815
|
-
function
|
|
822
|
+
return t.size !== "default" && (L[`${t.size}-item`] = !0), L;
|
|
823
|
+
}), y = $(() => !!e.slots.footer || u.value);
|
|
824
|
+
function b() {
|
|
816
825
|
return t.header === "SearchBar" ? J : t.header === "ContentHeader" ? ft : J;
|
|
817
826
|
}
|
|
818
|
-
const s =
|
|
827
|
+
const s = b(), {
|
|
819
828
|
renderHeader: C
|
|
820
|
-
} = s(t, e,
|
|
829
|
+
} = s(t, e, S), {
|
|
821
830
|
renderListArea: h
|
|
822
|
-
} = ut(t, e, a,
|
|
823
|
-
function j(
|
|
824
|
-
|
|
831
|
+
} = ut(t, e, a, c, d, k, w);
|
|
832
|
+
function j(L) {
|
|
833
|
+
S.search(L);
|
|
825
834
|
}
|
|
826
|
-
function
|
|
827
|
-
|
|
835
|
+
function A(L) {
|
|
836
|
+
L && (c.load(L), a.value = F(0, V.value + i - 1));
|
|
828
837
|
}
|
|
829
838
|
e.expose({
|
|
830
839
|
search: j,
|
|
831
|
-
updateDataSource:
|
|
840
|
+
updateDataSource: A
|
|
832
841
|
});
|
|
833
|
-
function R(
|
|
834
|
-
t.multiSelect && (
|
|
842
|
+
function R(L) {
|
|
843
|
+
t.multiSelect && (L.preventDefault(), L.stopPropagation());
|
|
835
844
|
}
|
|
836
845
|
return () => l("div", {
|
|
837
846
|
class: f.value,
|
|
@@ -840,39 +849,39 @@ const L = /* @__PURE__ */ G({
|
|
|
840
849
|
ref: n,
|
|
841
850
|
class: "f-list-view-content",
|
|
842
851
|
onMouseover: () => {
|
|
843
|
-
|
|
852
|
+
v.value = !0;
|
|
844
853
|
},
|
|
845
854
|
onMouseleave: () => {
|
|
846
|
-
|
|
855
|
+
v.value = !1;
|
|
847
856
|
}
|
|
848
|
-
}, [h()]),
|
|
857
|
+
}, [h()]), y.value && l("div", {
|
|
849
858
|
class: "f-list-view-footer"
|
|
850
859
|
}, [e.slots.footer && e.slots.footer()])]);
|
|
851
860
|
}
|
|
852
|
-
}),
|
|
861
|
+
}), H = /* @__PURE__ */ G({
|
|
853
862
|
name: "FTransfer",
|
|
854
863
|
props: U,
|
|
855
864
|
emits: ["change", "activeChange"],
|
|
856
865
|
setup(t, e) {
|
|
857
|
-
const n =
|
|
858
|
-
function
|
|
859
|
-
const
|
|
860
|
-
|
|
866
|
+
const n = g(t.identifyField), u = g("已选:"), v = g("项数据"), a = g(t.displayType), i = g(!1), m = g(t.dataSource), r = g(t.selections || []), p = $(() => r.value.map((y) => y[n.value])), d = /* @__PURE__ */ new Map(), o = g();
|
|
867
|
+
function c() {
|
|
868
|
+
const y = /* @__PURE__ */ new Map(), b = t.selectionValues || [];
|
|
869
|
+
b.length && b.reduce((C, h) => (C.set(h, !0), C), y);
|
|
861
870
|
const s = t.selections || [];
|
|
862
|
-
s.length && (
|
|
863
|
-
const h = C[n.value], j =
|
|
864
|
-
C.checked = j, j &&
|
|
871
|
+
s.length && (y.clear(), s.reduce((C, h) => (C.set(h[n.value], !0), C), y)), r.value.length || (r.value = m.value.filter((C) => y.has(C[n.value])).map((C) => Object.assign({}, C))), m.value.forEach((C) => {
|
|
872
|
+
const h = C[n.value], j = y.has(h);
|
|
873
|
+
C.checked = j, j && d.set(h, C);
|
|
865
874
|
});
|
|
866
875
|
}
|
|
867
|
-
|
|
868
|
-
const
|
|
869
|
-
function V(
|
|
870
|
-
|
|
876
|
+
c();
|
|
877
|
+
const k = $(() => a.value === "List"), S = $(() => a.value === "Tree");
|
|
878
|
+
function V(y) {
|
|
879
|
+
r.value = y.map((b) => Object.assign({}, b)), e.emit("change", r.value);
|
|
871
880
|
}
|
|
872
|
-
function
|
|
873
|
-
return l(
|
|
881
|
+
function I() {
|
|
882
|
+
return l(E, {
|
|
874
883
|
class: "f-utils-fill",
|
|
875
|
-
data:
|
|
884
|
+
data: m.value,
|
|
876
885
|
multiSelect: !0,
|
|
877
886
|
selection: {
|
|
878
887
|
enableSelectRow: !0,
|
|
@@ -885,10 +894,10 @@ const L = /* @__PURE__ */ G({
|
|
|
885
894
|
draggable: !1,
|
|
886
895
|
header: "Search",
|
|
887
896
|
headerClass: "transfer-search-box",
|
|
888
|
-
"selection-values":
|
|
897
|
+
"selection-values": p.value,
|
|
889
898
|
onSelectionChange: V
|
|
890
899
|
}, {
|
|
891
|
-
default: () => [
|
|
900
|
+
default: () => [_(" ")]
|
|
892
901
|
});
|
|
893
902
|
}
|
|
894
903
|
function D() {
|
|
@@ -901,40 +910,40 @@ const L = /* @__PURE__ */ G({
|
|
|
901
910
|
class: "f-utils-flex-column option-pane-content f-utils-fill"
|
|
902
911
|
}, [l("div", {
|
|
903
912
|
class: "container columns-box d-flex f-utils-fill"
|
|
904
|
-
}, [
|
|
913
|
+
}, [k.value && I(), S.value && D()])])]);
|
|
905
914
|
}
|
|
906
|
-
function
|
|
907
|
-
const
|
|
908
|
-
if (
|
|
909
|
-
|
|
910
|
-
const s =
|
|
911
|
-
s && (s.checked = !1,
|
|
915
|
+
function O(y) {
|
|
916
|
+
const b = y[n.value];
|
|
917
|
+
if (b !== null || b !== void 0) {
|
|
918
|
+
r.value = r.value.filter((C) => C[n.value] !== b);
|
|
919
|
+
const s = d.get(b);
|
|
920
|
+
s && (s.checked = !1, d.delete(b)), e.emit("change", r.value);
|
|
912
921
|
}
|
|
913
922
|
}
|
|
914
|
-
X(
|
|
915
|
-
o.value.updateDataSource(
|
|
923
|
+
X(r, (y) => {
|
|
924
|
+
o.value.updateDataSource(y);
|
|
916
925
|
});
|
|
917
|
-
function P(
|
|
918
|
-
const
|
|
919
|
-
|
|
926
|
+
function P(y) {
|
|
927
|
+
const b = /* @__PURE__ */ new Map();
|
|
928
|
+
r.value.reduce((s, C) => (s.set(C[n.value], C), s), b), r.value = y.map((s) => b.get(s[n.value])), e.emit("change", r.value);
|
|
920
929
|
}
|
|
921
|
-
function T(
|
|
922
|
-
e.emit("activeChange",
|
|
930
|
+
function T(y) {
|
|
931
|
+
e.emit("activeChange", y);
|
|
923
932
|
}
|
|
924
|
-
function
|
|
925
|
-
return l(
|
|
933
|
+
function w() {
|
|
934
|
+
return l(E, {
|
|
926
935
|
ref: o,
|
|
927
936
|
style: "flex:1",
|
|
928
|
-
data:
|
|
937
|
+
data: r.value,
|
|
929
938
|
draggable: !0,
|
|
930
939
|
view: "DraggableView",
|
|
931
940
|
"keep-order": !0,
|
|
932
941
|
onChange: P,
|
|
933
|
-
onRemoveItem:
|
|
942
|
+
onRemoveItem: O,
|
|
934
943
|
onActiveChange: T
|
|
935
944
|
}, null);
|
|
936
945
|
}
|
|
937
|
-
function
|
|
946
|
+
function F() {
|
|
938
947
|
return l("div", {
|
|
939
948
|
class: "f-utils-fill selection-pane d-flex flex-column"
|
|
940
949
|
}, [l("div", {
|
|
@@ -943,142 +952,142 @@ const L = /* @__PURE__ */ G({
|
|
|
943
952
|
class: "selection-pane-title"
|
|
944
953
|
}, [l("span", {
|
|
945
954
|
class: "selection-title"
|
|
946
|
-
}, [
|
|
955
|
+
}, [u.value]), l("span", {
|
|
947
956
|
class: "selection-count"
|
|
948
|
-
}, [
|
|
957
|
+
}, [r.value && r.value.length]), l("span", {
|
|
949
958
|
class: "selection-item-title"
|
|
950
|
-
}, [
|
|
959
|
+
}, [v.value])]), l("div", {
|
|
951
960
|
class: "container columns-box f-utils-fill d-flex"
|
|
952
|
-
}, [
|
|
961
|
+
}, [w()])])]);
|
|
953
962
|
}
|
|
954
963
|
const f = $(() => ({
|
|
955
964
|
transfer: !0,
|
|
956
965
|
row: !0,
|
|
957
|
-
"f-utils-fill":
|
|
966
|
+
"f-utils-fill": i.value
|
|
958
967
|
}));
|
|
959
968
|
return () => l("div", {
|
|
960
969
|
class: f.value,
|
|
961
970
|
style: "height:480px"
|
|
962
|
-
}, [M(),
|
|
971
|
+
}, [M(), F()]);
|
|
963
972
|
}
|
|
964
973
|
});
|
|
965
974
|
function dt(t, e, n) {
|
|
966
975
|
var T;
|
|
967
|
-
function
|
|
976
|
+
function u() {
|
|
968
977
|
}
|
|
969
|
-
const
|
|
970
|
-
function
|
|
978
|
+
const v = "", a = "", i = g();
|
|
979
|
+
function m() {
|
|
971
980
|
return (e == null ? void 0 : e.schema.componentType) !== "frame";
|
|
972
981
|
}
|
|
973
|
-
function
|
|
982
|
+
function r() {
|
|
974
983
|
return !1;
|
|
975
984
|
}
|
|
976
|
-
function
|
|
985
|
+
function p() {
|
|
977
986
|
return (e == null ? void 0 : e.schema.componentType) !== "frame";
|
|
978
987
|
}
|
|
979
|
-
function
|
|
988
|
+
function d() {
|
|
980
989
|
return (e == null ? void 0 : e.schema.componentType) === "frame";
|
|
981
990
|
}
|
|
982
|
-
function o(
|
|
983
|
-
if (!
|
|
991
|
+
function o(w) {
|
|
992
|
+
if (!w || !w.value)
|
|
984
993
|
return null;
|
|
985
|
-
if (
|
|
986
|
-
return
|
|
987
|
-
const
|
|
994
|
+
if (w.value.schema && w.value.schema.type === "component")
|
|
995
|
+
return w.value;
|
|
996
|
+
const F = g(w == null ? void 0 : w.value.parent), f = o(F);
|
|
988
997
|
return f || null;
|
|
989
998
|
}
|
|
990
|
-
function
|
|
991
|
-
const { componentInstance:
|
|
992
|
-
return !
|
|
999
|
+
function c(w = e) {
|
|
1000
|
+
const { componentInstance: F, designerItemElementRef: f } = w;
|
|
1001
|
+
return !F || !F.value ? null : F.value.canMove ? f : c(w.parent);
|
|
993
1002
|
}
|
|
994
|
-
function
|
|
1003
|
+
function k(w) {
|
|
995
1004
|
return !!n;
|
|
996
1005
|
}
|
|
997
|
-
function
|
|
1006
|
+
function S() {
|
|
998
1007
|
return (e == null ? void 0 : e.schema.label) || (e == null ? void 0 : e.schema.title) || (e == null ? void 0 : e.schema.name);
|
|
999
1008
|
}
|
|
1000
1009
|
function V() {
|
|
1001
1010
|
}
|
|
1002
|
-
function
|
|
1011
|
+
function I(w, F) {
|
|
1003
1012
|
}
|
|
1004
|
-
function D(
|
|
1005
|
-
const { componentType:
|
|
1006
|
-
let
|
|
1007
|
-
const
|
|
1008
|
-
return
|
|
1013
|
+
function D(w, F) {
|
|
1014
|
+
const { componentType: f } = w;
|
|
1015
|
+
let y = N(f, w, F);
|
|
1016
|
+
const b = f.toLowerCase().replace("-", "_");
|
|
1017
|
+
return y && !y.id && y.type === f && (y.id = `${b}_${Math.random().toString().slice(2, 6)}`), y;
|
|
1009
1018
|
}
|
|
1010
|
-
function M(
|
|
1011
|
-
const f = String(
|
|
1012
|
-
|
|
1013
|
-
let s = N(f,
|
|
1019
|
+
function M(w, F) {
|
|
1020
|
+
const f = String(w.getAttribute("data-controltype")), y = w.getAttribute("data-feature"), b = y ? JSON.parse(y) : {};
|
|
1021
|
+
b.parentComponentInstance = i.value;
|
|
1022
|
+
let s = N(f, b);
|
|
1014
1023
|
const C = f.toLowerCase().replace("-", "_");
|
|
1015
1024
|
return s && !s.id && s.type === f && (s.id = `${C}_${Math.random().toString().slice(2, 6)}`), s;
|
|
1016
1025
|
}
|
|
1017
|
-
function
|
|
1026
|
+
function O(w) {
|
|
1018
1027
|
}
|
|
1019
|
-
function P(...
|
|
1028
|
+
function P(...w) {
|
|
1020
1029
|
}
|
|
1021
|
-
return
|
|
1022
|
-
canMove:
|
|
1023
|
-
canSelectParent:
|
|
1024
|
-
canDelete:
|
|
1025
|
-
canNested: !
|
|
1030
|
+
return i.value = {
|
|
1031
|
+
canMove: m(),
|
|
1032
|
+
canSelectParent: r(),
|
|
1033
|
+
canDelete: p(),
|
|
1034
|
+
canNested: !d(),
|
|
1026
1035
|
contents: e == null ? void 0 : e.schema.contents,
|
|
1027
1036
|
elementRef: t,
|
|
1028
1037
|
parent: (T = e == null ? void 0 : e.parent) == null ? void 0 : T.componentInstance,
|
|
1029
1038
|
schema: e == null ? void 0 : e.schema,
|
|
1030
|
-
styles:
|
|
1039
|
+
styles: v,
|
|
1031
1040
|
designerClass: a,
|
|
1032
|
-
canAccepts:
|
|
1041
|
+
canAccepts: k,
|
|
1033
1042
|
getBelongedComponentInstance: o,
|
|
1034
|
-
getDraggableDesignItemElement:
|
|
1035
|
-
getDraggingDisplayText:
|
|
1043
|
+
getDraggableDesignItemElement: c,
|
|
1044
|
+
getDraggingDisplayText: S,
|
|
1036
1045
|
getPropConfig: P,
|
|
1037
1046
|
getDragScopeElement: V,
|
|
1038
|
-
onAcceptMovedChildElement:
|
|
1047
|
+
onAcceptMovedChildElement: I,
|
|
1039
1048
|
onAcceptNewChildElement: M,
|
|
1040
|
-
onChildElementMovedOut:
|
|
1049
|
+
onChildElementMovedOut: O,
|
|
1041
1050
|
addNewChildComponentSchema: D,
|
|
1042
|
-
updateDragAndDropRules:
|
|
1043
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
1044
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
1045
|
-
},
|
|
1051
|
+
updateDragAndDropRules: u,
|
|
1052
|
+
triggerBelongedComponentToMoveWhenMoved: g(!1),
|
|
1053
|
+
triggerBelongedComponentToDeleteWhenDeleted: g(!1)
|
|
1054
|
+
}, i;
|
|
1046
1055
|
}
|
|
1047
1056
|
const pt = /* @__PURE__ */ G({
|
|
1048
1057
|
name: "FTransferDesign",
|
|
1049
1058
|
props: U,
|
|
1050
1059
|
emits: ["change"],
|
|
1051
1060
|
setup(t, e) {
|
|
1052
|
-
const n =
|
|
1061
|
+
const n = g(t.identifyField), u = g("已选:"), v = g("项数据"), a = g(t.displayType), i = g(!1), m = g(t.dataSource), r = g(t.selections || []), p = $(() => r.value.map((b) => b[n.value])), d = /* @__PURE__ */ new Map();
|
|
1053
1062
|
function o() {
|
|
1054
|
-
const
|
|
1055
|
-
s.length && s.reduce((h, j) => (h.set(j, !0), h),
|
|
1063
|
+
const b = /* @__PURE__ */ new Map(), s = t.selectionValues || [];
|
|
1064
|
+
s.length && s.reduce((h, j) => (h.set(j, !0), h), b);
|
|
1056
1065
|
const C = t.selections || [];
|
|
1057
|
-
C.length && (
|
|
1058
|
-
const j = h[n.value],
|
|
1059
|
-
h.checked =
|
|
1066
|
+
C.length && (b.clear(), C.reduce((h, j) => (h.set(j[n.value], !0), h), b)), r.value.length || (r.value = m.value.filter((h) => b.has(h[n.value])).map((h) => Object.assign({}, h))), m.value.forEach((h) => {
|
|
1067
|
+
const j = h[n.value], A = b.has(j);
|
|
1068
|
+
h.checked = A, A && d.set(j, h);
|
|
1060
1069
|
});
|
|
1061
1070
|
}
|
|
1062
1071
|
o();
|
|
1063
|
-
const
|
|
1064
|
-
function
|
|
1065
|
-
|
|
1072
|
+
const c = $(() => a.value === "List"), k = $(() => a.value === "Tree");
|
|
1073
|
+
function S(b) {
|
|
1074
|
+
r.value = b.map((s) => Object.assign({}, s)), e.emit("change", r.value);
|
|
1066
1075
|
}
|
|
1067
1076
|
function V() {
|
|
1068
|
-
return l(
|
|
1077
|
+
return l(E, {
|
|
1069
1078
|
class: "f-utils-fill",
|
|
1070
|
-
data:
|
|
1079
|
+
data: m.value,
|
|
1071
1080
|
"multi-select": !0,
|
|
1072
1081
|
draggable: !1,
|
|
1073
1082
|
header: "Search",
|
|
1074
1083
|
headerClass: "transfer-search-box",
|
|
1075
|
-
"selection-values":
|
|
1076
|
-
onSelectionChange:
|
|
1084
|
+
"selection-values": p.value,
|
|
1085
|
+
onSelectionChange: S
|
|
1077
1086
|
}, {
|
|
1078
|
-
default: () => [
|
|
1087
|
+
default: () => [_(" ")]
|
|
1079
1088
|
});
|
|
1080
1089
|
}
|
|
1081
|
-
function
|
|
1090
|
+
function I() {
|
|
1082
1091
|
return l(B, null, null);
|
|
1083
1092
|
}
|
|
1084
1093
|
function D() {
|
|
@@ -1088,31 +1097,31 @@ const pt = /* @__PURE__ */ G({
|
|
|
1088
1097
|
class: "f-utils-flex-column option-pane-content f-utils-fill"
|
|
1089
1098
|
}, [l("div", {
|
|
1090
1099
|
class: "container columns-box d-flex f-utils-fill"
|
|
1091
|
-
}, [
|
|
1100
|
+
}, [c.value && V(), k.value && I()])])]);
|
|
1092
1101
|
}
|
|
1093
|
-
function M(
|
|
1094
|
-
const s =
|
|
1102
|
+
function M(b) {
|
|
1103
|
+
const s = b[n.value];
|
|
1095
1104
|
if (s !== null || s !== void 0) {
|
|
1096
|
-
|
|
1097
|
-
const C =
|
|
1098
|
-
C && (C.checked = !1,
|
|
1105
|
+
r.value = r.value.filter((h) => h[n.value] !== s);
|
|
1106
|
+
const C = d.get(s);
|
|
1107
|
+
C && (C.checked = !1, d.delete(s)), e.emit("change", r.value);
|
|
1099
1108
|
}
|
|
1100
1109
|
}
|
|
1101
|
-
function
|
|
1110
|
+
function O(b) {
|
|
1102
1111
|
const s = /* @__PURE__ */ new Map();
|
|
1103
|
-
|
|
1112
|
+
r.value.reduce((C, h) => (C.set(h[n.value], h), C), s), r.value = b.map((C) => s.get(C[n.value])), e.emit("change", r.value);
|
|
1104
1113
|
}
|
|
1105
1114
|
function P() {
|
|
1106
|
-
return l(
|
|
1115
|
+
return l(E, {
|
|
1107
1116
|
style: "flex:1",
|
|
1108
|
-
data:
|
|
1117
|
+
data: r.value,
|
|
1109
1118
|
draggable: !0,
|
|
1110
1119
|
view: "DraggableView",
|
|
1111
1120
|
"keep-order": !0,
|
|
1112
|
-
onChange:
|
|
1121
|
+
onChange: O,
|
|
1113
1122
|
onRemoveItem: M
|
|
1114
1123
|
}, {
|
|
1115
|
-
default: () => [
|
|
1124
|
+
default: () => [_(" ")]
|
|
1116
1125
|
});
|
|
1117
1126
|
}
|
|
1118
1127
|
function T() {
|
|
@@ -1124,24 +1133,24 @@ const pt = /* @__PURE__ */ G({
|
|
|
1124
1133
|
class: "selection-pane-title"
|
|
1125
1134
|
}, [l("span", {
|
|
1126
1135
|
class: "selection-title"
|
|
1127
|
-
}, [
|
|
1136
|
+
}, [u.value]), l("span", {
|
|
1128
1137
|
class: "selection-count"
|
|
1129
|
-
}, [
|
|
1138
|
+
}, [r.value && r.value.length]), l("span", {
|
|
1130
1139
|
class: "selection-item-title"
|
|
1131
|
-
}, [
|
|
1140
|
+
}, [v.value])]), l("div", {
|
|
1132
1141
|
class: "container columns-box f-utils-fill d-flex"
|
|
1133
1142
|
}, [P()])])]);
|
|
1134
1143
|
}
|
|
1135
|
-
const
|
|
1144
|
+
const w = $(() => ({
|
|
1136
1145
|
transfer: !0,
|
|
1137
1146
|
row: !0,
|
|
1138
|
-
"f-utils-fill":
|
|
1139
|
-
})),
|
|
1147
|
+
"f-utils-fill": i.value
|
|
1148
|
+
})), F = g(), f = se("design-item-context"), y = dt(F, f);
|
|
1140
1149
|
return ae(() => {
|
|
1141
|
-
|
|
1142
|
-
}), e.expose(
|
|
1143
|
-
ref:
|
|
1144
|
-
class:
|
|
1150
|
+
F.value.componentInstance = y;
|
|
1151
|
+
}), e.expose(y.value), () => l("div", {
|
|
1152
|
+
ref: F,
|
|
1153
|
+
class: w.value,
|
|
1145
1154
|
style: "height:480px"
|
|
1146
1155
|
}, [D(), T()]);
|
|
1147
1156
|
}
|
|
@@ -1151,16 +1160,16 @@ const pt = /* @__PURE__ */ G({
|
|
|
1151
1160
|
n.component(e.name, t);
|
|
1152
1161
|
}, t;
|
|
1153
1162
|
};
|
|
1154
|
-
|
|
1155
|
-
t.transfer =
|
|
1163
|
+
H.register = (t, e, n) => {
|
|
1164
|
+
t.transfer = H, e.transfer = x;
|
|
1156
1165
|
};
|
|
1157
|
-
|
|
1166
|
+
H.registerDesigner = (t, e, n) => {
|
|
1158
1167
|
t.transfer = pt, e.transfer = x;
|
|
1159
1168
|
};
|
|
1160
|
-
const
|
|
1169
|
+
const wt = vt(H);
|
|
1161
1170
|
export {
|
|
1162
|
-
|
|
1163
|
-
|
|
1171
|
+
H as FTransfer,
|
|
1172
|
+
wt as default,
|
|
1164
1173
|
x as propsResolver,
|
|
1165
1174
|
U as transferProps
|
|
1166
1175
|
};
|