@dazhicheng/ui 1.6.55 → 1.6.57

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.
Files changed (32) hide show
  1. package/dist/assets/svg/download.svg.js +1 -1
  2. package/dist/components/tt-area/TtArea.vue.js +1 -1
  3. package/dist/components/tt-button/index.d.ts +28 -28
  4. package/dist/components/tt-button/index.vue.d.ts +16 -16
  5. package/dist/components/tt-custom-export-modal/src/assets/search.svg.js +5 -5
  6. package/dist/components/tt-custom-export-modal/src/assets/star.svg.js +3 -3
  7. package/dist/components/tt-custom-export-modal/src/assets/trash.svg.js +7 -7
  8. package/dist/components/tt-custom-export-modal/src/components/FieldGridSection.vue.js +1 -1
  9. package/dist/components/tt-drawer/index.d.ts +109 -109
  10. package/dist/components/tt-drawer/src/RenderDrawer.vue.d.ts +60 -60
  11. package/dist/components/tt-drawer/src/components/DrawerHeader.vue.js +2 -2
  12. package/dist/components/tt-empty/index.d.ts +4 -4
  13. package/dist/components/tt-form/src/components/FormElInput.vue.d.ts +10 -10
  14. package/dist/components/tt-icon/index.vue.js +2 -2
  15. package/dist/components/tt-image/index.d.ts +29 -29
  16. package/dist/components/tt-image/src/components/ImageViewer.d.ts +20 -20
  17. package/dist/components/tt-image/tt-image.d.ts +29 -29
  18. package/dist/components/tt-input-textarea/index.vue.d.ts +40 -40
  19. package/dist/components/tt-loading/src/loading.vue.js +2 -2
  20. package/dist/components/tt-modal/index.d.ts +150 -150
  21. package/dist/components/tt-modal/src/RenderModal.vue.d.ts +42 -42
  22. package/dist/components/tt-modal/src/hooks/useModalRender.d.ts +17 -17
  23. package/dist/components/tt-panel-select/src/components/PanelMiddle.vue.d.ts +7 -5
  24. package/dist/components/tt-panel-select/src/components/PanelMiddle.vue.js +120 -114
  25. package/dist/components/tt-panel-select/src/index.vue.d.ts +9 -5
  26. package/dist/components/tt-panel-select/src/index.vue.js +275 -229
  27. package/dist/components/tt-panel-select/src/types.d.ts +4 -0
  28. package/dist/components/tt-upload/index.d.ts +60 -60
  29. package/dist/components/tt-upload/src/TtUpload.vue.d.ts +37 -37
  30. package/dist/components/tt-upload/src/typing.d.ts +17 -17
  31. package/dist/style.css +1 -1
  32. package/package.json +3 -3
@@ -1,8 +1,9 @@
1
- import { defineComponent as qe, mergeModels as I, useModel as He, computed as u, watch as O, ref as v, useTemplateRef as $, unref as r, onMounted as Je, createElementBlock as z, openBlock as A, normalizeClass as j, createVNode as q, mergeProps as Qe, withCtx as Xe, withDirectives as Ye, normalizeStyle as Ze, createBlock as H, createCommentVNode as J, nextTick as E } from "vue";
1
+ import { defineComponent as tl, mergeModels as ee, useModel as al, computed as i, watch as N, ref as w, useTemplateRef as L, unref as s, onMounted as ol, createElementBlock as le, openBlock as A, normalizeClass as te, createVNode as ae, mergeProps as nl, withCtx as rl, withDirectives as il, normalizeStyle as sl, createBlock as oe, createCommentVNode as ne, nextTick as P } from "vue";
2
2
  import "../../../node_modules/.pnpm/vue-types@5.1.3_vue@3.5.34_typescript@5.9.3_/node_modules/vue-types/shim/index.modern.js";
3
- import { useDesign as el } from "../../../packages/hooks/src/useDesign.js";
3
+ import { useDesign as ul } from "../../../packages/hooks/src/useDesign.js";
4
4
  import "axios";
5
- import { ElSelect as ll, vLoading as tl } from "element-plus";
5
+ import { ElSelect as cl, vLoading as dl } from "element-plus";
6
+ import { isString as pl } from "../../../packages/utils/src/is.js";
6
7
  import "dayjs";
7
8
  import "numeral";
8
9
  import "xe-utils";
@@ -15,19 +16,20 @@ import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/mode-
15
16
  import "../../../node_modules/.pnpm/crypto-js@4.2.0/node_modules/crypto-js/pad-pkcs7.js";
16
17
  import "lodash-es";
17
18
  import "vue-router";
18
- import { useResizeObserver as al } from "@vueuse/core";
19
- import { useSelectCollapseOptions as ol } from "../../tt-form/src/hooks/useSelectCollapse.js";
20
- import { ALL as nl, DEFAULT_PANEL_SELECT_SEPARATORS as il } from "./common.js";
21
- import rl from "./components/PanelLeft.vue.js";
22
- import ul from "./components/PanelMiddle.vue.js";
23
- import sl from "./components/PanelRight.vue.js";
24
- import { usePanelSelectData as cl } from "./hooks/usePanelData.js";
25
- import { usePanelSelectSelection as dl } from "./hooks/usePanelSelection.js";
19
+ import { useResizeObserver as fl } from "@vueuse/core";
20
+ import { useSelectCollapseOptions as ml } from "../../tt-form/src/hooks/useSelectCollapse.js";
21
+ import { splitPanelSelectText as R, ALL as hl, DEFAULT_PANEL_SELECT_SEPARATORS as vl } from "./common.js";
22
+ import wl from "./components/PanelLeft.vue.js";
23
+ import yl from "./components/PanelMiddle.vue.js";
24
+ import gl from "./components/PanelRight.vue.js";
25
+ import { usePanelSelectData as Cl } from "./hooks/usePanelData.js";
26
+ import { usePanelSelectSelection as kl } from "./hooks/usePanelSelection.js";
26
27
  /* empty css */
27
- const m = 4, Wl = /* @__PURE__ */ qe({
28
+ const h = 4, Jl = /* @__PURE__ */ tl({
28
29
  name: "TtPanelSelect",
29
30
  __name: "index",
30
- props: /* @__PURE__ */ I({
31
+ props: /* @__PURE__ */ ee({
32
+ allowCreate: { type: Boolean, default: !1 },
31
33
  disabled: { type: Boolean, default: !1 },
32
34
  showNav: { type: Boolean, default: !0 },
33
35
  multiple: { type: Boolean, default: !0 },
@@ -48,11 +50,11 @@ const m = 4, Wl = /* @__PURE__ */ qe({
48
50
  immediate: { type: Boolean, default: !0 },
49
51
  beforeFetch: { type: Function, default: void 0 },
50
52
  afterFetch: { type: Function, default: void 0 },
51
- separator: { default: () => [...il] },
53
+ separator: { default: () => [...vl] },
52
54
  pasteSearch: { type: Boolean, default: !0 },
53
55
  alwaysLoad: { type: Boolean, default: !1 },
54
56
  showAll: { type: Boolean, default: !0 },
55
- showAllField: { default: nl },
57
+ showAllField: { default: hl },
56
58
  showPinyinMode: { type: Boolean, default: !1 },
57
59
  showOriginMode: { type: Boolean, default: !0 },
58
60
  leftPlaceholder: { default: "支持模糊搜索" },
@@ -62,56 +64,64 @@ const m = 4, Wl = /* @__PURE__ */ qe({
62
64
  modelValue: {},
63
65
  modelModifiers: {}
64
66
  }),
65
- emits: /* @__PURE__ */ I(["visible-change", "change", "focus"], ["update:modelValue"]),
66
- setup(s, { expose: Q, emit: X }) {
67
- const Y = tl, Z = ll, t = s, C = X, { prefixCls: p } = el("panel-select"), {
68
- loading: ee,
69
- fetchApi: f,
70
- treeOptions: le,
71
- navTreeOptions: F,
72
- navNodes: te,
73
- leafNodes: h,
74
- isFirstLoaded: ae,
75
- buildOptionGroups: oe
76
- } = cl(t), n = He(s, "modelValue");
77
- let P;
78
- const R = u(() => t.disabled), ne = u(() => {
79
- if (!t.multiple) return t.placeholder;
80
- const e = t.showMultiple ? "支持多选和全选" : "支持多选", l = typeof t.placeholder == "string" && t.placeholder.trim() ? t.placeholder.trim().replace(/[,,]\s*$/, "") : "请选择";
81
- return l.includes("支持多选和全选") || l.includes("支持多选") ? l : `${l},${e}`;
82
- }), ie = u(() => {
67
+ emits: /* @__PURE__ */ ee(["visible-change", "change", "focus"], ["update:modelValue"]),
68
+ setup(c, { expose: re, emit: ie }) {
69
+ const se = dl, ue = cl, t = c, b = ie, { prefixCls: f } = ul("panel-select"), {
70
+ loading: B,
71
+ fetchApi: v,
72
+ treeOptions: ce,
73
+ navTreeOptions: T,
74
+ navNodes: de,
75
+ leafNodes: m,
76
+ isFirstLoaded: G,
77
+ filterNodes: pe,
78
+ buildOptionGroups: _
79
+ } = Cl(t), r = al(c, "modelValue");
80
+ let W;
81
+ const D = i(() => t.disabled), fe = i(() => {
82
+ if (!t.multiple)
83
+ return t.allowCreate ? `${t.placeholder ? t.placeholder : "请选择"}(可创建)` : t.placeholder;
84
+ const e = t.showMultiple ? "支持多选和全选" : "支持多选", l = typeof t.placeholder == "string" && t.placeholder.trim() ? t.placeholder.trim().replace(/[,,]\s*$/, "") : "请选择", a = l.includes("支持多选和全选") || l.includes("支持多选") ? l : `${l},${e}`;
85
+ return t.allowCreate ? `${a}(可创建)` : a;
86
+ }), me = i(() => {
83
87
  const e = /* @__PURE__ */ new Map();
84
- return h.value.forEach((l) => e.set(l.value, l.label)), e;
88
+ return m.value.forEach((l) => e.set(l.value, l.label)), e;
85
89
  });
86
90
  function x(e) {
87
- return e === t.showAllField ? { label: "全部", value: t.showAllField } : { label: ie.value.get(e) ?? String(e), value: e };
91
+ return e === t.showAllField ? { label: "全部", value: t.showAllField } : { label: me.value.get(e) ?? String(e), value: e };
88
92
  }
89
- function L(e) {
93
+ function K(e) {
90
94
  if (e != null)
91
95
  return typeof e == "object" && "value" in e ? e.value : e;
92
96
  }
93
- const re = u({
97
+ const U = i({
94
98
  get() {
95
- return Array.isArray(n.value) ? t.multiple ? n.value : n.value.slice(-1) : n.value === void 0 ? [] : [n.value];
99
+ return Array.isArray(r.value) ? t.multiple ? r.value : r.value.slice(-1) : r.value === void 0 ? [] : [r.value];
96
100
  },
97
101
  set(e) {
98
- n.value = t.multiple ? [...e] : e.at(-1);
102
+ r.value = t.multiple ? [...e] : e.at(-1);
99
103
  }
100
- });
101
- O([() => t.multiple, () => n.value], ([e, l]) => {
104
+ }), S = i(() => {
105
+ if (!t.allowCreate) return [];
106
+ const e = new Set(m.value.map((a) => a.value)), l = [];
107
+ return new Set(U.value).forEach((a) => {
108
+ !pl(a) || a === t.showAllField || e.has(a) || l.push({ label: a, value: a, level: 0, path: [], raw: { label: a, value: a } });
109
+ }), l;
110
+ }), V = i(() => [...m.value, ...S.value]);
111
+ N([() => t.multiple, () => r.value], ([e, l]) => {
102
112
  if (e) {
103
- Array.isArray(l) || (n.value = l === void 0 ? [] : [l]);
113
+ Array.isArray(l) || (r.value = l === void 0 ? [] : [l]);
104
114
  return;
105
115
  }
106
- Array.isArray(l) && (n.value = l.at(-1));
116
+ Array.isArray(l) && (r.value = l.at(-1));
107
117
  });
108
- const b = v(), y = v(""), w = v(""), S = v(), V = $("middleRef"), g = $("selectWrapRef"), B = $("selectRef"), M = v(0);
109
- function N() {
118
+ const O = w(), y = w(""), d = w(""), M = w(), $ = L("middleRef"), g = L("selectWrapRef"), I = L("selectRef"), E = w(0);
119
+ function z() {
110
120
  const e = g.value;
111
- e && (M.value = e.offsetWidth);
121
+ e && (E.value = e.offsetWidth);
112
122
  }
113
- al(g, () => N());
114
- const ue = u(() => ({
123
+ fl(g, () => z());
124
+ const he = i(() => ({
115
125
  componentProps: {
116
126
  multiple: t.multiple,
117
127
  component: {
@@ -120,99 +130,133 @@ const m = 4, Wl = /* @__PURE__ */ qe({
120
130
  },
121
131
  component: "TtPanelSelect",
122
132
  selectWrapRef: g,
123
- selectRef: B
124
- })), { selectComponentProps: se } = ol(ue), T = u(() => {
133
+ selectRef: I
134
+ })), { selectComponentProps: ve } = ml(he), j = i(() => {
125
135
  const e = y.value.trim().toLowerCase();
126
- if (!e) return F.value;
136
+ if (!e) return T.value;
127
137
  const l = (a) => {
128
138
  const o = [];
129
- return a.forEach((i) => {
130
- var _;
131
- const c = (_ = i.children) != null && _.length ? l(i.children) : void 0;
132
- (String(i.label).toLowerCase().includes(e) || c && c.length) && o.push({ ...i, children: c != null && c.length ? c : void 0 });
139
+ return a.forEach((n) => {
140
+ var Z;
141
+ const u = (Z = n.children) != null && Z.length ? l(n.children) : void 0;
142
+ (String(n.label).toLowerCase().includes(e) || u && u.length) && o.push({ ...n, children: u != null && u.length ? u : void 0 });
133
143
  }), o;
134
144
  };
135
- return l(F.value);
136
- }), ce = u(() => {
145
+ return l(T.value);
146
+ }), we = i(() => {
137
147
  const e = [], l = (a) => {
138
148
  a.forEach((o) => {
139
- var i;
140
- e.push(o.value), (i = o.children) != null && i.length && l(o.children);
149
+ var n;
150
+ e.push(o.value), (n = o.children) != null && n.length && l(o.children);
141
151
  });
142
152
  };
143
- return l(T.value), e;
144
- }), k = u(() => oe(h.value, w.value)), de = u(() => {
153
+ return l(j.value), e;
154
+ }), C = i(
155
+ () => ge(d.value).map((e) => ({
156
+ label: e,
157
+ value: e,
158
+ level: 0,
159
+ path: [],
160
+ raw: { label: e, value: e }
161
+ }))
162
+ ), ye = i(() => [...V.value, ...C.value]), k = i(() => {
163
+ const e = _(m.value, d.value), l = pe([...S.value, ...C.value], d.value);
164
+ if (!l.length) return e;
165
+ const a = new Map(l.map((u) => [u.value, u])), o = [];
166
+ R(d.value, t.separator).forEach((u) => {
167
+ const F = a.get(u);
168
+ F && (o.push(F), a.delete(u));
169
+ }), o.push(...a.values());
170
+ let n = "__created__";
171
+ for (; e.some((u) => u.value === n); ) n += "_";
172
+ return [{ value: n, label: "自定义", options: o }, ...e];
173
+ });
174
+ function ge(e) {
175
+ if (!t.allowCreate || t.disabled || B.value || t.api && !G.value) return [];
176
+ const l = R(e, t.separator);
177
+ if (!l.length || _(m.value, e).length) return [];
178
+ const a = new Set(V.value.map((o) => `${o.value}`));
179
+ return [...new Set(l)].filter((o) => o !== `${t.showAllField}` && !a.has(o));
180
+ }
181
+ function Ce() {
182
+ if (!C.value.length) return;
183
+ const e = new Set([...S.value, ...C.value].map((a) => a.value)), l = [...new Set(R(d.value, t.separator))].filter(
184
+ (a) => e.has(a)
185
+ );
186
+ Y(l, !0);
187
+ }
188
+ const ke = i(() => {
145
189
  const e = "minmax(var(--tt-panel-select-middle-width, 450px), 1fr)";
146
190
  return t.showNav && !t.multiple ? `200px ${e}` : !t.showNav && t.multiple ? `${e} 180px` : !t.showNav && !t.multiple ? e : `200px ${e} 180px`;
147
- }), pe = u(() => {
191
+ }), Ae = i(() => {
148
192
  const e = "var(--tt-panel-select-middle-width, 450px)";
149
193
  return t.showNav && !t.multiple ? `max(calc(200px + ${e}), 800px)` : !t.showNav && t.multiple ? `max(calc(${e} + 180px), 800px)` : !t.showNav && !t.multiple ? `max(${e}, 800px)` : `max(calc(200px + ${e} + 180px), 800px)`;
150
- }), me = u(() => {
194
+ }), be = i(() => {
151
195
  const e = [];
152
196
  return k.value.forEach((l) => {
153
197
  !(t.showOriginMode && l.value === "__origin__") && e.push({ key: `group-${String(l.value)}`, type: "group", group: l });
154
- const o = Math.ceil(l.options.length / m);
155
- for (let i = 0; i < l.options.length; i += m) {
156
- const c = i / m;
198
+ const o = Math.ceil(l.options.length / h);
199
+ for (let n = 0; n < l.options.length; n += h) {
200
+ const u = n / h;
157
201
  e.push({
158
- key: `options-${String(l.value)}-${i / m}`,
202
+ key: `options-${String(l.value)}-${n / h}`,
159
203
  type: "options",
160
204
  group: l,
161
- options: l.options.slice(i, i + m),
162
- isLast: c === o - 1
205
+ options: l.options.slice(n, n + h),
206
+ isLast: u === o - 1
163
207
  });
164
208
  }
165
209
  }), e;
166
210
  }), {
167
- selectedOptions: fe,
168
- selectedValueSet: G,
169
- isAllChecked: he,
170
- isIndeterminate: ve,
171
- getGroupCheckCount: ye,
172
- handleGroupCheck: we,
173
- handleAllOptionCheck: ge,
174
- handleOptionCheck: ke,
175
- handleOptionsCheck: Ae,
176
- handleCheckAll: Ce,
177
- clearSelected: xe,
178
- removeSelected: be,
179
- withLockedSelectedValues: Se
180
- } = dl({
181
- multiple: u(() => t.multiple),
182
- modelValue: n,
183
- selectedValues: re,
184
- leafNodes: h,
185
- allValue: u(() => t.showAllField)
186
- }), W = u({
211
+ selectedOptions: xe,
212
+ selectedValueSet: q,
213
+ isAllChecked: Se,
214
+ isIndeterminate: Ve,
215
+ getGroupCheckCount: Oe,
216
+ handleGroupCheck: Me,
217
+ handleAllOptionCheck: $e,
218
+ handleOptionCheck: Ee,
219
+ handleOptionsCheck: Fe,
220
+ handleCheckAll: Ne,
221
+ clearSelected: Le,
222
+ removeSelected: Pe,
223
+ withLockedSelectedValues: Re
224
+ } = kl({
225
+ multiple: i(() => t.multiple),
226
+ modelValue: r,
227
+ selectedValues: U,
228
+ leafNodes: ye,
229
+ allValue: i(() => t.showAllField)
230
+ }), H = i({
187
231
  get() {
188
232
  if (t.multiple)
189
- return (Array.isArray(n.value) ? n.value : n.value === void 0 ? [] : [n.value]).map((l) => x(l));
190
- if (Array.isArray(n.value)) {
191
- const e = n.value.at(-1);
233
+ return (Array.isArray(r.value) ? r.value : r.value === void 0 ? [] : [r.value]).map((l) => x(l));
234
+ if (Array.isArray(r.value)) {
235
+ const e = r.value.at(-1);
192
236
  return e === void 0 ? void 0 : x(e);
193
237
  }
194
- return n.value === void 0 ? void 0 : x(n.value);
238
+ return r.value === void 0 ? void 0 : x(r.value);
195
239
  },
196
240
  set(e) {
197
- const l = r(n);
198
- if (P = Array.isArray(l) ? [...l] : l, t.multiple) {
199
- const o = (Array.isArray(e) ? e : []).map((i) => L(i)).filter((i) => i !== void 0);
200
- n.value = Se(o);
241
+ const l = s(r);
242
+ if (W = Array.isArray(l) ? [...l] : l, t.multiple) {
243
+ const o = (Array.isArray(e) ? e : []).map((n) => K(n)).filter((n) => n !== void 0);
244
+ r.value = Re(o);
201
245
  return;
202
246
  }
203
- n.value = L(e);
247
+ r.value = K(e);
204
248
  }
205
- }), D = u(
249
+ }), J = i(
206
250
  () => {
207
251
  const e = {}, l = {};
208
252
  return k.value.forEach((a) => {
209
- const { enabledCount: o, checkedCount: i } = ye(a), c = String(a.value);
210
- e[c] = o > 0 && i === o, l[c] = o > 0 && i > 0 && i < o;
253
+ const { enabledCount: o, checkedCount: n } = Oe(a), u = String(a.value);
254
+ e[u] = o > 0 && n === o, l[u] = o > 0 && n > 0 && n < o;
211
255
  }), { checkedMap: e, indeterminateMap: l };
212
256
  }
213
- ), Ve = u(() => D.value.checkedMap), Me = u(() => D.value.indeterminateMap), Oe = u(() => G.value.has(t.showAllField)), K = u(() => [...t.showAll ? [{ label: "全部", value: t.showAllField }] : [], ...h.value.map((l) => ({ ...l }))]);
214
- function $e(e) {
215
- const l = r(K);
257
+ ), Be = i(() => J.value.checkedMap), Te = i(() => J.value.indeterminateMap), Ge = i(() => q.value.has(t.showAllField)), Q = i(() => [...t.showAll ? [{ label: "全部", value: t.showAllField }] : [], ...V.value.map((l) => ({ ...l }))]);
258
+ function _e(e) {
259
+ const l = s(Q);
216
260
  if (Array.isArray(e)) {
217
261
  const a = new Set(e);
218
262
  return l.filter((o) => o.value !== void 0 && a.has(o.value));
@@ -220,195 +264,197 @@ const m = 4, Wl = /* @__PURE__ */ qe({
220
264
  if (e !== void 0)
221
265
  return l.find((a) => a.value === e);
222
266
  }
223
- function Ee(e) {
267
+ function We(e) {
224
268
  var a;
225
269
  if (t.showPinyinMode || k.value.some((o) => o.value === e.value)) return e.value;
226
- const l = h.value.find((o) => o.path.some((i) => i.value === e.value));
270
+ const l = m.value.find((o) => o.path.some((n) => n.value === e.value));
227
271
  return (a = l == null ? void 0 : l.path.at(-2)) == null ? void 0 : a.value;
228
272
  }
229
- function Fe(e) {
230
- b.value = e.value;
231
- const l = Ee(e);
232
- S.value = void 0, E(() => {
273
+ function De(e) {
274
+ O.value = e.value;
275
+ const l = We(e);
276
+ M.value = void 0, P(() => {
233
277
  var a;
234
- S.value = l, l !== void 0 && ((a = V.value) == null || a.scrollToGroup(l));
278
+ M.value = l, l !== void 0 && ((a = $.value) == null || a.scrollToGroup(l));
235
279
  });
236
280
  }
237
- function Pe(e) {
281
+ function Ke(e) {
238
282
  y.value = e;
239
283
  }
240
- function Re(e) {
241
- w.value = e;
284
+ function Ue(e) {
285
+ d.value = e;
242
286
  }
243
- function Le(e, l) {
287
+ function Ie(e, l) {
244
288
  const a = k.value.find((o) => o.value === e);
245
- a && we(a, l);
289
+ a && Me(a, l);
246
290
  }
247
- async function Be(e) {
291
+ async function ze(e) {
248
292
  var l;
249
- C("visible-change", e), e && (w.value = "", y.value = "", await E(), (l = V.value) == null || l.inputFocus(), N(), t.alwaysLoad ? await f() : !t.immediate && !r(ae) && await f());
293
+ b("visible-change", e), e && (d.value = "", y.value = "", await P(), (l = $.value) == null || l.inputFocus(), z(), t.alwaysLoad ? await v() : !t.immediate && !s(G) && await v());
250
294
  }
251
- function Ne() {
252
- U(P);
295
+ function je() {
296
+ X(W);
253
297
  }
254
- function Te(e) {
255
- C("change", e, [...r(K)], $e(e));
298
+ function qe(e) {
299
+ b("change", e, [...s(Q)], _e(e));
256
300
  }
257
- function Ge(e, l) {
301
+ function He(e, l) {
258
302
  return Array.isArray(e) && Array.isArray(l) ? e.length === l.length && e.every((a, o) => a === l[o]) : e === l;
259
303
  }
260
- function U(e) {
261
- E(() => {
262
- const l = r(n);
263
- Ge(l, e) || Te(l);
304
+ function X(e) {
305
+ P(() => {
306
+ const l = s(r);
307
+ He(l, e) || qe(l);
264
308
  });
265
309
  }
266
- function d(e) {
267
- const l = r(n), a = Array.isArray(l) ? [...l] : l;
268
- e(), U(a);
310
+ function p(e) {
311
+ const l = s(r), a = Array.isArray(l) ? [...l] : l;
312
+ e(), X(a);
269
313
  }
270
- function We(e) {
271
- d(() => {
272
- ge(e);
314
+ function Je(e) {
315
+ p(() => {
316
+ $e(e);
273
317
  });
274
318
  }
275
- function De(e) {
276
- d(() => {
277
- Ce(e);
319
+ function Qe(e) {
320
+ p(() => {
321
+ Ne(e);
278
322
  });
279
323
  }
280
- function Ke(e, l) {
281
- d(() => {
282
- Le(e, l);
324
+ function Xe(e, l) {
325
+ p(() => {
326
+ Ie(e, l);
283
327
  });
284
328
  }
285
- function Ue(e, l) {
286
- d(() => {
287
- ke(e, l);
329
+ function Ye(e, l) {
330
+ p(() => {
331
+ Ee(e, l);
288
332
  });
289
333
  }
290
- function _e(e, l) {
291
- d(() => {
292
- Ae(e, l);
334
+ function Y(e, l) {
335
+ p(() => {
336
+ Fe(e, l);
293
337
  });
294
338
  }
295
- function Ie(e) {
296
- d(() => {
297
- be(e);
339
+ function Ze(e) {
340
+ p(() => {
341
+ Pe(e);
298
342
  });
299
343
  }
300
- function ze() {
301
- d(() => {
302
- xe();
344
+ function el() {
345
+ p(() => {
346
+ Le();
303
347
  });
304
348
  }
305
- function je(e) {
306
- C("focus", e);
349
+ function ll(e) {
350
+ b("focus", e);
307
351
  }
308
- return O(
352
+ return N(
309
353
  () => t.params,
310
354
  () => {
311
- f();
355
+ v();
312
356
  },
313
357
  { deep: !0 }
314
- ), O(
315
- te,
358
+ ), N(
359
+ de,
316
360
  (e) => {
317
361
  var l;
318
- b.value !== void 0 || !e.length || (b.value = (l = e[0]) == null ? void 0 : l.value);
362
+ O.value !== void 0 || !e.length || (O.value = (l = e[0]) == null ? void 0 : l.value);
319
363
  },
320
364
  { immediate: !0 }
321
- ), Je(() => {
322
- t.immediate && f();
323
- }), Q({
365
+ ), ol(() => {
366
+ t.immediate && v();
367
+ }), re({
324
368
  /** 重新加载数据源*/
325
- reload: f,
369
+ reload: v,
326
370
  /** 获取当前归一化后的树形选项数据 */
327
- getOptions: () => r(le),
371
+ getOptions: () => s(ce),
328
372
  /** 获取当前v-model值 */
329
- getValue: () => r(n)
330
- }), (e, l) => (A(), z("div", {
373
+ getValue: () => s(r)
374
+ }), (e, l) => (A(), le("div", {
331
375
  ref_key: "selectWrapRef",
332
376
  ref: g,
333
- class: j(r(p))
377
+ class: te(s(f))
334
378
  }, [
335
- q(r(Z), Qe({
379
+ ae(s(ue), nl({
336
380
  ref_key: "selectRef",
337
- ref: B,
338
- modelValue: W.value,
339
- "onUpdate:modelValue": l[0] || (l[0] = (a) => W.value = a)
340
- }, r(se), {
341
- multiple: s.multiple,
381
+ ref: I,
382
+ modelValue: H.value,
383
+ "onUpdate:modelValue": l[0] || (l[0] = (a) => H.value = a)
384
+ }, s(ve), {
385
+ multiple: c.multiple,
342
386
  filterable: !1,
343
- placeholder: ne.value,
387
+ placeholder: fe.value,
344
388
  persistent: !1,
345
389
  "fallback-placements": ["bottom-start", "bottom-end", "bottom", "top-start", "top-end", "top", "right", "left"],
346
- disabled: s.disabled,
347
- "popper-class": `${r(p)}__popper vxe-table--ignore-clear`,
348
- onVisibleChange: Be,
349
- onChange: Ne,
350
- onFocus: je
390
+ disabled: c.disabled,
391
+ "popper-class": `${s(f)}__popper vxe-table--ignore-clear`,
392
+ onVisibleChange: ze,
393
+ onChange: je,
394
+ onFocus: ll
351
395
  }), {
352
- empty: Xe(() => [
353
- Ye((A(), z("div", {
396
+ empty: rl(() => [
397
+ il((A(), le("div", {
354
398
  "element-loading-text": "加载中",
355
- class: j(`${r(p)}__panel`),
356
- style: Ze({
357
- "--columns": de.value,
358
- "--panel-min-width": pe.value,
359
- "--panel-width": M.value ? `${M.value}px` : "100%"
399
+ class: te(`${s(f)}__panel`),
400
+ style: sl({
401
+ "--columns": ke.value,
402
+ "--panel-min-width": Ae.value,
403
+ "--panel-width": E.value ? `${E.value}px` : "100%"
360
404
  })
361
405
  }, [
362
- t.showNav ? (A(), H(rl, {
406
+ t.showNav ? (A(), oe(wl, {
363
407
  key: 0,
364
- "prefix-cls": r(p),
408
+ "prefix-cls": s(f),
365
409
  keyword: y.value,
366
- "tree-data": T.value,
367
- "expanded-keys": ce.value,
368
- "left-placeholder": s.leftPlaceholder,
369
- "onUpdate:keyword": Pe,
370
- onSelect: Fe
371
- }, null, 8, ["prefix-cls", "keyword", "tree-data", "expanded-keys", "left-placeholder"])) : J("", !0),
372
- q(ul, {
410
+ "tree-data": j.value,
411
+ "expanded-keys": we.value,
412
+ "left-placeholder": c.leftPlaceholder,
413
+ "onUpdate:keyword": Ke,
414
+ onSelect: De
415
+ }, null, 8, ["prefix-cls", "keyword", "tree-data", "expanded-keys", "left-placeholder"])) : ne("", !0),
416
+ ae(yl, {
373
417
  ref_key: "middleRef",
374
- ref: V,
375
- "prefix-cls": r(p),
376
- multiple: s.multiple,
377
- keyword: w.value,
378
- rows: me.value,
379
- disabled: R.value,
418
+ ref: $,
419
+ "allow-create": t.allowCreate,
420
+ "prefix-cls": s(f),
421
+ multiple: c.multiple,
422
+ keyword: d.value,
423
+ rows: be.value,
424
+ disabled: D.value,
380
425
  "show-all": t.showAll,
381
- "option-per-row": m,
426
+ "option-per-row": h,
382
427
  "row-height": 40,
383
- "selected-value-set": r(G),
384
- "is-all-checked": r(he),
385
- "is-indeterminate": r(ve),
386
- "all-checked": Oe.value,
387
- "scroll-to-group-value": S.value,
388
- "group-checked-map": Ve.value,
389
- "group-indeterminate-map": Me.value,
390
- "paste-search": s.pasteSearch,
391
- separator: s.separator,
392
- "middle-placeholder": s.middlePlaceholder,
393
- "show-multiple": s.showMultiple,
394
- "onUpdate:keyword": Re,
395
- onAllCheck: We,
396
- onCheckAll: De,
397
- onGroupCheck: Ke,
398
- onOptionCheck: Ue,
399
- onOptionsCheck: _e
400
- }, null, 8, ["prefix-cls", "multiple", "keyword", "rows", "disabled", "show-all", "selected-value-set", "is-all-checked", "is-indeterminate", "all-checked", "scroll-to-group-value", "group-checked-map", "group-indeterminate-map", "paste-search", "separator", "middle-placeholder", "show-multiple"]),
401
- t.multiple ? (A(), H(sl, {
428
+ "selected-value-set": s(q),
429
+ "is-all-checked": s(Se),
430
+ "is-indeterminate": s(Ve),
431
+ "all-checked": Ge.value,
432
+ "scroll-to-group-value": M.value,
433
+ "group-checked-map": Be.value,
434
+ "group-indeterminate-map": Te.value,
435
+ "paste-search": c.pasteSearch,
436
+ separator: c.separator,
437
+ "middle-placeholder": c.middlePlaceholder,
438
+ "show-multiple": c.showMultiple,
439
+ "onUpdate:keyword": Ue,
440
+ onAllCheck: Je,
441
+ onCheckAll: Qe,
442
+ onGroupCheck: Xe,
443
+ onOptionCheck: Ye,
444
+ onOptionsCheck: Y,
445
+ onSelectCreatedOptions: Ce
446
+ }, null, 8, ["allow-create", "prefix-cls", "multiple", "keyword", "rows", "disabled", "show-all", "selected-value-set", "is-all-checked", "is-indeterminate", "all-checked", "scroll-to-group-value", "group-checked-map", "group-indeterminate-map", "paste-search", "separator", "middle-placeholder", "show-multiple"]),
447
+ t.multiple ? (A(), oe(gl, {
402
448
  key: 1,
403
- "prefix-cls": r(p),
404
- multiple: s.multiple,
405
- disabled: R.value,
406
- "selected-options": r(fe),
407
- onClearAll: ze,
408
- onRemove: Ie
409
- }, null, 8, ["prefix-cls", "multiple", "disabled", "selected-options"])) : J("", !0)
449
+ "prefix-cls": s(f),
450
+ multiple: c.multiple,
451
+ disabled: D.value,
452
+ "selected-options": s(xe),
453
+ onClearAll: el,
454
+ onRemove: Ze
455
+ }, null, 8, ["prefix-cls", "multiple", "disabled", "selected-options"])) : ne("", !0)
410
456
  ], 6)), [
411
- [r(Y), r(ee)]
457
+ [s(se), s(B)]
412
458
  ])
413
459
  ]),
414
460
  _: 1
@@ -417,5 +463,5 @@ const m = 4, Wl = /* @__PURE__ */ qe({
417
463
  }
418
464
  });
419
465
  export {
420
- Wl as default
466
+ Jl as default
421
467
  };