@das-fed/upf-ui 6.4.0-dev.261 → 6.4.0-dev.262
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/front-end/i18n/front-end-page/dasui_en-US.js +1 -1
- package/front-end/i18n/front-end-page/dasui_zh-CN.js +1 -1
- package/front-end/i18n/front-end-page/dasui_zh-MO.js +1 -1
- package/package.json +3 -3
- package/packages/business-components/process-configuration/index.js +1 -1
- package/packages/business-components/process-configuration/index.js.gz +0 -0
- package/packages/business-components/process-configuration/style.css +1 -1
- package/packages/business-components/process-configuration/style.css.gz +0 -0
- package/packages/components/button/index.js +83 -85
- package/packages/components/button/index.js.gz +0 -0
- package/packages/components/button/style.css +1 -1
- package/packages/components/button/style.css.gz +0 -0
- package/packages/components/checkbox/index.js +1 -1
- package/packages/components/checkbox/index.js.gz +0 -0
- package/packages/components/checkbox/style.css +1 -1
- package/packages/components/checkbox/style.css.gz +0 -0
- package/packages/components/form-item/index.js +466 -471
- package/packages/components/form-item/index.js.gz +0 -0
- package/packages/components/form-item/src/type.d.ts +0 -3
- package/packages/components/form-item/style.css +1 -1
- package/packages/components/form-item/style.css.gz +0 -0
- package/packages/components/input/index.js +911 -921
- package/packages/components/input/index.js.gz +0 -0
- package/packages/components/input/src/index.vue.d.ts +1 -2
- package/packages/components/input/style.css +1 -1
- package/packages/components/input/style.css.gz +0 -0
- package/packages/components/search-form/index.js +3 -3
- package/packages/components/search-form/index.js.gz +0 -0
- package/packages/components/search-form/style.css +1 -1
- package/packages/components/search-form/style.css.gz +0 -0
- package/packages/components/select/index.js +273 -285
- package/packages/components/select/index.js.gz +0 -0
- package/packages/components/select/style.css +1 -1
- package/packages/components/select/style.css.gz +0 -0
- package/packages/components/tree-v2/index.js +1399 -1409
- package/packages/components/tree-v2/index.js.gz +0 -0
- package/packages/components/tree-v2/style.css +1 -1
- package/packages/components/tree-v2/style.css.gz +0 -0
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
import { withInstall as
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
import { Select as
|
|
4
|
-
import { DasCheckbox as
|
|
5
|
-
import { vScrollbar as
|
|
6
|
-
import { DasTooltip as
|
|
7
|
-
import { vDasTooltip as
|
|
8
|
-
import { DasInput as
|
|
9
|
-
import { DasIconXiala as
|
|
10
|
-
import { DasIconEmpty as
|
|
11
|
-
import { DasErrorOverlayModel as
|
|
12
|
-
import { vHoverInside as
|
|
13
|
-
import { t as M, currentLang as
|
|
14
|
-
import { useZIndex as
|
|
15
|
-
import { useModelValue as
|
|
16
|
-
import { calcTextWidth as
|
|
1
|
+
import { withInstall as el } from "@das-fed/upf-utils/with-install/index";
|
|
2
|
+
import { defineComponent as ll, useCssVars as Xl, useAttrs as Jl, computed as s, ref as i, watch as G, useSlots as Ql, onMounted as Ae, onUnmounted as Xe, watchEffect as Je, nextTick as k, resolveComponent as Yl, openBlock as f, createElementBlock as g, normalizeClass as et, normalizeStyle as X, withModifiers as ue, createBlock as K, unref as c, createCommentVNode as L, withDirectives as Te, mergeProps as Le, createSlots as lt, withCtx as m, renderSlot as S, normalizeProps as ie, guardReactiveProps as ce, Fragment as ke, createTextVNode as Ve, toDisplayString as Z, createElementVNode as b, createVNode as V, withKeys as tt } from "vue";
|
|
3
|
+
import { Select as ot, Tag as Ie } from "ant-design-vue";
|
|
4
|
+
import { DasCheckbox as Qe } from "@das-fed/upf-ui/packages/components/checkbox/index";
|
|
5
|
+
import { vScrollbar as nt } from "@das-fed/upf-ui/packages/components/scrollbar/index";
|
|
6
|
+
import { DasTooltip as at } from "@das-fed/upf-ui/packages/components/tooltip/index";
|
|
7
|
+
import { vDasTooltip as Ye } from "@das-fed/upf-ui/packages/components/text-tooltip/index";
|
|
8
|
+
import { DasInput as rt } from "@das-fed/upf-ui/packages/components/input/index";
|
|
9
|
+
import { DasIconXiala as st } from "@das-fed/upf-ui/packages/icons/xiala/index";
|
|
10
|
+
import { DasIconEmpty as ut } from "@das-fed/upf-ui/packages/icons/empty/index";
|
|
11
|
+
import { DasErrorOverlayModel as it } from "@das-fed/upf-ui/packages/components/error-overlay-model/index";
|
|
12
|
+
import { vHoverInside as ct } from "@das-fed/upf-utils/directive";
|
|
13
|
+
import { t as M, currentLang as dt, setI18nRule as ft } from "@das-fed/upf-web/packages/i18n/index";
|
|
14
|
+
import { useZIndex as vt } from "@das-fed/upf-utils/hooks/popup-manager/use-zindex";
|
|
15
|
+
import { useModelValue as pt } from "@das-fed/upf-utils/vue";
|
|
16
|
+
import { calcTextWidth as ht } from "@das-fed/upf-utils/common-tools";
|
|
17
17
|
import "ant-design-vue/es/select/style/css";
|
|
18
18
|
import "ant-design-vue/es/tag/style/css";
|
|
19
|
-
import { SelectOption as
|
|
19
|
+
import { SelectOption as mt } from "ant-design-vue/es"
|
|
20
20
|
import '@das-fed/upf-ui/packages/components/select/style.css';
|
|
21
21
|
;
|
|
22
|
-
const
|
|
22
|
+
const yt = { key: 0 }, gt = ["onClick"], bt = { style: { display: "inline-block" } }, Ct = ["innerHTML"], wt = { key: 0 }, St = { key: 2 }, xt = { style: { display: "inline-block" } }, At = ["innerHTML"], Tt = ["innerHTML"], kt = {
|
|
23
23
|
key: 0,
|
|
24
24
|
class: "das-select-error-label-content das-select-label-content"
|
|
25
|
-
},
|
|
25
|
+
}, Vt = { class: "ant-select ant-select-multiple ant-select-selection-overflow-item ant-select-selection-overflow-item-rest" }, It = { class: "ant-select-selection-item" }, Lt = { class: "ant-select-selection-item-content" }, Mt = ["innerHTML"], Ot = ll({
|
|
26
26
|
inheritAttrs: !1,
|
|
27
27
|
components: {
|
|
28
|
-
VNodes: (p, { attrs:
|
|
28
|
+
VNodes: (p, { attrs: D }) => D.vnodes
|
|
29
29
|
}
|
|
30
|
-
}),
|
|
31
|
-
...
|
|
30
|
+
}), zt = /* @__PURE__ */ ll({
|
|
31
|
+
...Ot,
|
|
32
32
|
__name: "Select",
|
|
33
33
|
props: {
|
|
34
34
|
modelValue: { default: void 0 },
|
|
@@ -72,39 +72,39 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
72
72
|
largeSelectionCollapseThreshold: { default: 200 }
|
|
73
73
|
},
|
|
74
74
|
emits: ["update:model-value", "change", "focus", "blur", "dropdownVisibleChange", "addCustomItem"],
|
|
75
|
-
setup(p, { expose:
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
75
|
+
setup(p, { expose: D, emit: B }) {
|
|
76
|
+
Xl((e) => ({
|
|
77
|
+
v508aeef9: Sl.value,
|
|
78
|
+
b1f81358: xl.value
|
|
79
79
|
}));
|
|
80
|
-
const t = p, x =
|
|
80
|
+
const t = p, x = B, J = Jl(), ol = s(() => {
|
|
81
81
|
const e = {};
|
|
82
82
|
for (const l in J)
|
|
83
|
-
l === "
|
|
83
|
+
l === "onClick" || l.startsWith("onClick") || l === "filterOption" || l === "onSearch" || l === "onPopupScroll" || (e[l] = J[l]);
|
|
84
84
|
return e;
|
|
85
|
-
}), a =
|
|
85
|
+
}), a = pt(t, "modelValue"), Q = s(() => {
|
|
86
86
|
var e;
|
|
87
87
|
return `<span class='key'>${((e = a.value) == null ? void 0 : e.length) ?? 0}</span>`;
|
|
88
|
-
}),
|
|
88
|
+
}), nl = s(() => {
|
|
89
89
|
const e = Array.isArray(a.value) ? a.value.length : a.value ? 1 : 0;
|
|
90
90
|
return M("das-ui-select-selectedItemsCountWithPlaceholder", e);
|
|
91
|
-
}),
|
|
91
|
+
}), $ = i(null), Me = i(null), C = i(!1), Y = s(() => t.isView ? t.noSetDefaultVal ? "" : "-" : t.placeholder || M("请选择")), de = s(() => $.value ? $.value.querySelector(".ant-select-selector") : null), E = i(0), W = i(0), al = s(() => de.value ? t.isTooltip && O.value ? !1 : !t.isTooltip || N.value || !Ue.value || !be.value : !0), rl = s(() => (Array.isArray(a.value) ? a.value.length : a.value) ? Ue.value : Y.value), Oe = () => {
|
|
92
92
|
const e = t.size === "table" ? 12 : 14;
|
|
93
|
-
return
|
|
93
|
+
return ht(Y.value, e);
|
|
94
94
|
}, ze = () => {
|
|
95
|
-
var T,
|
|
96
|
-
const e = (T =
|
|
95
|
+
var T, j, h;
|
|
96
|
+
const e = (T = $.value) == null ? void 0 : T.querySelector(".ant-select-selection-placeholder"), l = (h = (j = A.value) == null ? void 0 : j.$el) == null ? void 0 : h.querySelectorAll(".ant-select-selection-item");
|
|
97
97
|
l && l.length && l.forEach((xe) => xe.removeAttribute("title"));
|
|
98
98
|
let n = (e == null ? void 0 : e.offsetWidth) ?? 0;
|
|
99
99
|
if (n === 0) return n;
|
|
100
100
|
const o = window.getComputedStyle(e, null), u = parseFloat(o.paddingRight), r = parseFloat(o.paddingLeft);
|
|
101
101
|
return n - u - r;
|
|
102
102
|
}, O = i(!1);
|
|
103
|
-
|
|
103
|
+
G(() => [Y.value, a.value], () => {
|
|
104
104
|
k(() => {
|
|
105
|
-
W.value = ze(),
|
|
105
|
+
W.value = ze(), E.value = Oe(), ((Array.isArray(a.value) ? a.value.length : a.value) || W.value === E.value || E.value - W.value < 1) && (O.value = !1);
|
|
106
106
|
});
|
|
107
|
-
}),
|
|
107
|
+
}), G(
|
|
108
108
|
() => {
|
|
109
109
|
var e;
|
|
110
110
|
return (e = Me.value) == null ? void 0 : e.$tooltipRef.popperRef.contentRef;
|
|
@@ -119,84 +119,73 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
119
119
|
}));
|
|
120
120
|
}
|
|
121
121
|
);
|
|
122
|
-
const Pe = i(null),
|
|
123
|
-
|
|
124
|
-
},
|
|
125
|
-
|
|
126
|
-
},
|
|
127
|
-
|
|
128
|
-
A.value.focus(),
|
|
122
|
+
const Pe = i(null), Ne = s(() => t.dropdownMode ?? t.mode ?? ""), F = i(null), sl = i(null), R = i(""), ul = () => {
|
|
123
|
+
F.value = !0;
|
|
124
|
+
}, il = () => {
|
|
125
|
+
F.value = null;
|
|
126
|
+
}, _e = () => {
|
|
127
|
+
R.value && (x("addCustomItem", R.value), k(() => {
|
|
128
|
+
A.value.focus(), R.value = "";
|
|
129
129
|
}));
|
|
130
|
-
},
|
|
131
|
-
t.dropdownMode === "custom" && !
|
|
132
|
-
|
|
130
|
+
}, De = Ql(), fe = () => {
|
|
131
|
+
t.dropdownMode === "custom" && !De.dropdownRender && (F.value = !1, k(() => {
|
|
132
|
+
F.value = null;
|
|
133
133
|
}));
|
|
134
134
|
};
|
|
135
135
|
Ae(() => {
|
|
136
136
|
document.addEventListener("click", fe);
|
|
137
|
-
}),
|
|
137
|
+
}), Xe(() => {
|
|
138
138
|
document.removeEventListener("click", fe);
|
|
139
139
|
});
|
|
140
|
-
const A = i(), H = i(""), ee = i(0),
|
|
140
|
+
const A = i(), H = i(""), ee = i(0), Be = `__DAS_SELECT_COLLAPSED_${Math.random().toString(36).slice(2)}__`, I = s(() => {
|
|
141
141
|
var e;
|
|
142
142
|
return t.fieldNames && t.fieldNames.label ? (e = t.fieldNames) == null ? void 0 : e.label : "label";
|
|
143
|
-
}),
|
|
143
|
+
}), y = s(() => {
|
|
144
144
|
var e;
|
|
145
145
|
return t.fieldNames && t.fieldNames.value ? (e = t.fieldNames) == null ? void 0 : e.value : "value";
|
|
146
|
-
}), ve = i(/* @__PURE__ */ new Map()),
|
|
147
|
-
large: "large",
|
|
148
|
-
middle: "middle",
|
|
149
|
-
default: "middle",
|
|
150
|
-
small: "small",
|
|
151
|
-
mini: "small",
|
|
152
|
-
table: "middle"
|
|
153
|
-
}, vl = {
|
|
154
|
-
large: "36px",
|
|
155
|
-
middle: "32px",
|
|
156
|
-
small: "24px"
|
|
157
|
-
}, pl = (e) => e && e in Be ? e : "middle", hl = s(() => pl(t.size)), $e = s(() => Be[hl.value]), ml = s(() => t.height ?? vl[$e.value]), We = s(() => {
|
|
146
|
+
}), ve = i(/* @__PURE__ */ new Map()), cl = s(() => t.mode === "combobox" ? void 0 : t.mode), dl = s(() => t.size == "middle" ? "defalut" : t.size == "mini" ? "small" : t.size), $e = s(() => {
|
|
158
147
|
const e = Number(t.optionPageSize);
|
|
159
148
|
return Number.isFinite(e) && e > 0 ? Math.floor(e) : 80;
|
|
160
|
-
}),
|
|
149
|
+
}), Ee = (e, l) => {
|
|
161
150
|
Array.isArray(e) && e.forEach((n) => {
|
|
162
|
-
l(n), Array.isArray(n == null ? void 0 : n.children) &&
|
|
151
|
+
l(n), Array.isArray(n == null ? void 0 : n.children) && Ee(n.children, l);
|
|
163
152
|
});
|
|
164
153
|
}, le = (e, l) => {
|
|
165
154
|
if (Array.isArray(e))
|
|
166
155
|
for (const n of e) {
|
|
167
|
-
if ((n == null ? void 0 : n[
|
|
156
|
+
if ((n == null ? void 0 : n[y.value]) == l) return n;
|
|
168
157
|
if (Array.isArray(n == null ? void 0 : n.children)) {
|
|
169
158
|
const o = le(n.children, l);
|
|
170
159
|
if (o) return o;
|
|
171
160
|
}
|
|
172
161
|
}
|
|
173
|
-
},
|
|
174
|
-
|
|
175
|
-
l && l[
|
|
162
|
+
}, fl = (e) => {
|
|
163
|
+
Ee(e, (l) => {
|
|
164
|
+
l && l[y.value] != null && l[I.value] != null && ve.value.set(l[y.value], l[I.value]);
|
|
176
165
|
});
|
|
177
166
|
}, pe = (e) => {
|
|
178
167
|
if (e == null || e === "") return;
|
|
179
168
|
const l = le(t.options, e);
|
|
180
|
-
if (l && l[
|
|
169
|
+
if (l && l[I.value] != null) return l[I.value];
|
|
181
170
|
if (t.preserveLabelWhenMissing)
|
|
182
171
|
return ve.value.get(e);
|
|
183
|
-
},
|
|
172
|
+
}, vl = (e) => {
|
|
184
173
|
const l = Array.isArray(e) ? e.slice() : [];
|
|
185
174
|
return t.preserveLabelWhenMissing ? ((t.mode !== "combobox" && Array.isArray(a.value) ? a.value : a.value != null && a.value !== "" ? [a.value] : []).forEach((o) => {
|
|
186
175
|
if (le(l, o)) return;
|
|
187
176
|
const r = ve.value.get(o);
|
|
188
177
|
r != null && l.unshift({
|
|
189
|
-
[
|
|
190
|
-
[
|
|
178
|
+
[y.value]: o,
|
|
179
|
+
[I.value]: r,
|
|
191
180
|
disabled: !0,
|
|
192
181
|
title: "",
|
|
193
182
|
__dasGhostOption: !0
|
|
194
183
|
});
|
|
195
184
|
}), l.map((o) => (o.title = o.title ? o.title : "", o))) : l.map((o) => (o.title = o.title ? o.title : "", o));
|
|
196
|
-
},
|
|
185
|
+
}, pl = (e) => Array.isArray(e) ? e.some((l) => Array.isArray(l == null ? void 0 : l.children) && l.children.length > 0) : !1, te = s(() => !!t.optionPaging && Array.isArray(t.options) && !pl(t.options)), We = (e, ...l) => {
|
|
197
186
|
const n = J[e];
|
|
198
187
|
Array.isArray(n) ? n.forEach((o) => typeof o == "function" && o(...l)) : typeof n == "function" && n(...l);
|
|
199
|
-
},
|
|
188
|
+
}, Fe = (e, l) => {
|
|
200
189
|
const n = e == null ? "" : String(e), o = J.filterOption;
|
|
201
190
|
if (typeof o == "function")
|
|
202
191
|
try {
|
|
@@ -205,51 +194,51 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
205
194
|
return !1;
|
|
206
195
|
}
|
|
207
196
|
if (o === !1) return !0;
|
|
208
|
-
const u =
|
|
197
|
+
const u = je.value, r = (l == null ? void 0 : l[u]) ?? (l == null ? void 0 : l[I.value]) ?? (l == null ? void 0 : l[y.value]);
|
|
209
198
|
return String(r ?? "").toLowerCase().indexOf(n.toLowerCase()) >= 0;
|
|
210
199
|
}, he = s(() => {
|
|
211
200
|
if (!Array.isArray(t.options)) return;
|
|
212
|
-
const e =
|
|
213
|
-
return Array.isArray(t.options) &&
|
|
214
|
-
}),
|
|
201
|
+
const e = vl(t.options);
|
|
202
|
+
return Array.isArray(t.options) && fl(t.options), e;
|
|
203
|
+
}), Re = s(() => {
|
|
215
204
|
const e = he.value ?? [];
|
|
216
|
-
return !te.value || !H.value ? e : e.filter((l) =>
|
|
205
|
+
return !te.value || !H.value ? e : e.filter((l) => Fe(H.value, l));
|
|
217
206
|
}), z = (e) => {
|
|
218
207
|
t.optionPagingDebug && k(() => {
|
|
219
208
|
});
|
|
220
|
-
}, oe = s(() => t.mode !== "combobox" && Array.isArray(a.value) ? a.value : a.value !== null && a.value !== void 0 && a.value !== "" ? [a.value] : []),
|
|
209
|
+
}, oe = s(() => t.mode !== "combobox" && Array.isArray(a.value) ? a.value : a.value !== null && a.value !== void 0 && a.value !== "" ? [a.value] : []), He = s(() => new Set(oe.value)), hl = s(() => {
|
|
221
210
|
const e = Number(t.largeSelectionCollapseThreshold);
|
|
222
211
|
return Number.isFinite(e) && e >= 0 ? Math.floor(e) : 200;
|
|
223
|
-
}),
|
|
224
|
-
if (H.value ||
|
|
225
|
-
const n = new Set(e.map((u) => u == null ? void 0 : u[
|
|
212
|
+
}), w = s(() => t.mode !== "combobox" && oe.value.length > hl.value), ml = s(() => w.value ? [Be] : a.value), qe = s(() => Array.isArray(t.options) ? t.options.filter((e) => !(e != null && e.disabled)) : []), ne = s(() => qe.value.map((e) => e == null ? void 0 : e[y.value])), me = s(() => ne.value.reduce((e, l) => He.value.has(l) ? e + 1 : e, 0)), yl = (e, l) => {
|
|
213
|
+
if (H.value || w.value || !oe.value.length) return e;
|
|
214
|
+
const n = new Set(e.map((u) => u == null ? void 0 : u[y.value])), o = [];
|
|
226
215
|
return oe.value.forEach((u) => {
|
|
227
216
|
if (n.has(u)) return;
|
|
228
217
|
const r = le(l, u);
|
|
229
218
|
r && (o.push(r), n.add(u));
|
|
230
219
|
}), o.length ? o.concat(e) : e;
|
|
231
|
-
},
|
|
220
|
+
}, gl = s(() => {
|
|
232
221
|
if (!te.value) return he.value;
|
|
233
|
-
const e =
|
|
234
|
-
return
|
|
235
|
-
}),
|
|
236
|
-
ee.value =
|
|
237
|
-
},
|
|
222
|
+
const e = Re.value.slice(0, ee.value);
|
|
223
|
+
return yl(e, he.value ?? []);
|
|
224
|
+
}), Ze = () => {
|
|
225
|
+
ee.value = $e.value, z();
|
|
226
|
+
}, bl = () => {
|
|
238
227
|
te.value && (ee.value = Math.min(
|
|
239
|
-
ee.value +
|
|
240
|
-
|
|
228
|
+
ee.value + $e.value,
|
|
229
|
+
Re.value.length
|
|
241
230
|
), z());
|
|
242
231
|
};
|
|
243
|
-
|
|
244
|
-
() => [t.options, t.optionPaging, t.optionPageSize, H.value,
|
|
245
|
-
|
|
232
|
+
G(
|
|
233
|
+
() => [t.options, t.optionPaging, t.optionPageSize, H.value, I.value, y.value],
|
|
234
|
+
Ze,
|
|
246
235
|
{ immediate: !0 }
|
|
247
236
|
);
|
|
248
|
-
const
|
|
249
|
-
if (
|
|
237
|
+
const ye = i(!1), ge = s(() => {
|
|
238
|
+
if (F.value !== null) return F.value;
|
|
250
239
|
if (t.open !== void 0) return t.open;
|
|
251
|
-
}), P = 1e6, d = i(100), v = i(100),
|
|
252
|
-
|
|
240
|
+
}), P = 1e6, d = i(100), v = i(100), Cl = s(() => w.value ? 0 : d.value), N = i(!1), be = i(!0), Ce = i(!1);
|
|
241
|
+
Je(() => {
|
|
253
242
|
a.value && t.mode == "combobox" && (be.value = !0, setTimeout(() => {
|
|
254
243
|
var l;
|
|
255
244
|
let e = (l = A.value) == null ? void 0 : l.$el.querySelectorAll(".ant-select-selection-item");
|
|
@@ -260,21 +249,21 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
260
249
|
}
|
|
261
250
|
}, 300));
|
|
262
251
|
});
|
|
263
|
-
const
|
|
252
|
+
const wl = () => {
|
|
264
253
|
setTimeout(async () => {
|
|
265
|
-
d.value = 100, await
|
|
254
|
+
d.value = 100, await _(), d.value = v.value, C.value = !0;
|
|
266
255
|
}, 100);
|
|
267
256
|
};
|
|
268
|
-
|
|
269
|
-
|
|
257
|
+
Je(() => {
|
|
258
|
+
Ce.value === !0 && t.mode != "combobox" && a.value && a.value.length > 0 && t.options.length > 0 && (Ce.value = !1, wl());
|
|
270
259
|
}), Ae(() => {
|
|
271
|
-
|
|
260
|
+
Ce.value = !0, t.focusOpen || (v.value = 1, d.value = v.value, C.value = !0);
|
|
272
261
|
});
|
|
273
|
-
const
|
|
274
|
-
"z-index":
|
|
275
|
-
})),
|
|
276
|
-
if (
|
|
277
|
-
return
|
|
262
|
+
const Sl = s(() => t.width ? t.width : "230px"), xl = s(() => t.height ? t.height : "auto"), Ke = i(3e3), Al = s(() => ({
|
|
263
|
+
"z-index": Ke.value
|
|
264
|
+
})), Ue = s(() => {
|
|
265
|
+
if (w.value)
|
|
266
|
+
return nl.value;
|
|
278
267
|
let e = [];
|
|
279
268
|
if (t.mode != "combobox" && Array.isArray(a.value))
|
|
280
269
|
a.value.map((l) => {
|
|
@@ -285,126 +274,125 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
285
274
|
const l = pe(a.value);
|
|
286
275
|
l != null ? e.push(l) : a.value !== null && a.value !== void 0 && a.value !== "" && e.push(String(a.value));
|
|
287
276
|
}
|
|
288
|
-
return
|
|
289
|
-
}),
|
|
277
|
+
return dt.value === "zh-CN" ? e.join("、") : e.join(", ");
|
|
278
|
+
}), Tl = s(() => t.mode === "combobox" ? !1 : ne.value.length > 0 && me.value === ne.value.length), kl = s(() => t.mode === "combobox" ? !1 : me.value > 0 && me.value < ne.value.length), je = s(() => {
|
|
290
279
|
var e, l;
|
|
291
280
|
return t.optionFilterProp ? t.optionFilterProp : (e = t.fieldNames) != null && e.label ? (l = t.fieldNames) == null ? void 0 : l.label : "label";
|
|
292
|
-
}),
|
|
293
|
-
width: typeof t.width == "number" ? t.width + "px" : t.width
|
|
294
|
-
|
|
295
|
-
})), Ce = i(!1), Pl = i({
|
|
281
|
+
}), Vl = s(() => ({
|
|
282
|
+
width: typeof t.width == "number" ? t.width + "px" : t.width
|
|
283
|
+
})), we = i(!1), Il = i({
|
|
296
284
|
display: "block",
|
|
297
285
|
color: "var(--upf-color-error)",
|
|
298
286
|
"white-space": "break-spaces"
|
|
299
|
-
}), q = i(),
|
|
287
|
+
}), q = i(), Ll = () => {
|
|
300
288
|
var n;
|
|
301
|
-
W.value = ze(),
|
|
289
|
+
W.value = ze(), E.value = Oe();
|
|
302
290
|
let e = (n = A.value) == null ? void 0 : n.$el.querySelectorAll(".ant-select-selection-item");
|
|
303
|
-
!!(Array.isArray(a.value) ? a.value.length : e != null && e.length) || W.value ===
|
|
304
|
-
},
|
|
291
|
+
!!(Array.isArray(a.value) ? a.value.length : e != null && e.length) || W.value === E.value || E.value - W.value < 1 ? O.value = !1 : (O.value = !0, q.value && clearTimeout(q.value)), we.value = !0;
|
|
292
|
+
}, Ml = () => {
|
|
305
293
|
q.value = setTimeout(() => {
|
|
306
294
|
O.value = !1;
|
|
307
|
-
}, 200),
|
|
308
|
-
},
|
|
309
|
-
e ?
|
|
310
|
-
},
|
|
311
|
-
e ? (
|
|
295
|
+
}, 200), we.value = !1;
|
|
296
|
+
}, Ol = (e, l) => {
|
|
297
|
+
e ? Ll() : Ml();
|
|
298
|
+
}, zl = (e) => {
|
|
299
|
+
e ? (Ke.value = vt().nextZIndex(), R.value = "", Ze(), z()) : (H.value = "", z()), ae.value = e, t.mode == "combobox" && (e || setTimeout(() => {
|
|
312
300
|
var l, n;
|
|
313
301
|
(n = (l = A.value) == null ? void 0 : l.blur) == null || n.call(l);
|
|
314
302
|
})), x("dropdownVisibleChange", e);
|
|
315
|
-
},
|
|
316
|
-
H.value = e ?? "", z(),
|
|
317
|
-
},
|
|
318
|
-
if (
|
|
303
|
+
}, Pl = (e) => {
|
|
304
|
+
H.value = e ?? "", z(), We("onSearch", e);
|
|
305
|
+
}, Nl = s(() => t.mode === "combobox" ? t.showSearch === !0 : t.mode === "tags" ? !0 : typeof t.showSearch == "boolean" ? t.showSearch : t.mode === "multiple"), _l = s(() => Nl.value ? { onSearch: Pl } : {}), Dl = s(() => ({ ...ol.value, ..._l.value })), Bl = (e) => {
|
|
306
|
+
if (We("onPopupScroll", e), !te.value) return;
|
|
319
307
|
const l = e.target;
|
|
320
308
|
if (!l) return;
|
|
321
|
-
l.scrollHeight - l.scrollTop - l.clientHeight <= 24 &&
|
|
322
|
-
},
|
|
309
|
+
l.scrollHeight - l.scrollTop - l.clientHeight <= 24 && bl();
|
|
310
|
+
}, $l = (e) => {
|
|
323
311
|
let l = e.toString();
|
|
324
312
|
return l.length > t.maxTagTextLength && (l = l.substr(0, t.maxTagTextLength) + "..."), l;
|
|
325
|
-
},
|
|
313
|
+
}, El = (e) => t.isRenderNode ? $.value : t.getPopupContainer === void 0 ? document.body : t.getPopupContainer(e), Wl = (e) => {
|
|
326
314
|
if (e) {
|
|
327
315
|
const l = new Set(Array.isArray(a.value) ? a.value : []), n = Array.isArray(a.value) ? a.value.slice() : [], o = [];
|
|
328
|
-
|
|
329
|
-
const r = u[
|
|
316
|
+
qe.value.forEach((u) => {
|
|
317
|
+
const r = u[y.value];
|
|
330
318
|
l.has(r) || (l.add(r), n.push(r), o.push(u));
|
|
331
319
|
}), a.value = n, se(n, o, "inner");
|
|
332
320
|
} else {
|
|
333
|
-
const l = Array.isArray(t.options) ? t.options : [], n = new Set(l.map((r) => r == null ? void 0 : r[
|
|
321
|
+
const l = Array.isArray(t.options) ? t.options : [], n = new Set(l.map((r) => r == null ? void 0 : r[y.value])), o = new Set(l.filter((r) => r == null ? void 0 : r.disabled).map((r) => r == null ? void 0 : r[y.value])), u = (Array.isArray(a.value) ? a.value : []).filter((r) => n.has(r) && o.has(r));
|
|
334
322
|
a.value = u, se(u, [], "inner");
|
|
335
323
|
}
|
|
336
|
-
},
|
|
324
|
+
}, Fl = (e) => {
|
|
337
325
|
const l = Array.isArray(a.value) ? a.value.slice() : [], n = l.findIndex((o) => o === e);
|
|
338
326
|
return n > -1 ? l.splice(n, 1) : l.push(e), l;
|
|
339
|
-
},
|
|
340
|
-
|
|
341
|
-
},
|
|
342
|
-
if (!
|
|
327
|
+
}, Rl = (e) => {
|
|
328
|
+
w.value && (e.preventDefault(), e.stopPropagation());
|
|
329
|
+
}, Hl = (e, l) => {
|
|
330
|
+
if (!w.value || e != null && e.disabled) return;
|
|
343
331
|
l.preventDefault(), l.stopPropagation();
|
|
344
|
-
const n = e == null ? void 0 : e[
|
|
332
|
+
const n = e == null ? void 0 : e[y.value];
|
|
345
333
|
if (n === void 0) return;
|
|
346
|
-
const o =
|
|
334
|
+
const o = Fl(n);
|
|
347
335
|
a.value = o, se(o, e, "inner");
|
|
348
|
-
},
|
|
336
|
+
}, ql = (e) => {
|
|
349
337
|
if (e.className.indexOf("ant-select-multiple") > -1 && e.children[0])
|
|
350
338
|
return e.children[0];
|
|
351
|
-
},
|
|
339
|
+
}, Zl = (e) => {
|
|
352
340
|
if (t.mode == "combobox") {
|
|
353
341
|
x("focus", e);
|
|
354
342
|
return;
|
|
355
343
|
}
|
|
356
|
-
|
|
357
|
-
}, ae = i(!1),
|
|
344
|
+
ye.value = !0, t.focusOpen && !t.isExterControlCount && (d.value = P, C.value = !1), x("focus", e);
|
|
345
|
+
}, ae = i(!1), Kl = () => {
|
|
358
346
|
ae.value || setTimeout(() => {
|
|
359
347
|
var e, l;
|
|
360
348
|
(l = (e = A.value) == null ? void 0 : e.blur) == null || l.call(e);
|
|
361
349
|
}), t.mode != "combobox";
|
|
362
|
-
},
|
|
350
|
+
}, Ge = (e) => {
|
|
363
351
|
if (k(() => {
|
|
364
352
|
ae.value = !1;
|
|
365
353
|
}), t.mode == "combobox") {
|
|
366
354
|
x("blur", e);
|
|
367
355
|
return;
|
|
368
356
|
}
|
|
369
|
-
|
|
370
|
-
},
|
|
357
|
+
ye.value = !1, t.focusOpen && !t.isExterControlCount && (_(), d.value = v.value, C.value = !0), x("blur", e);
|
|
358
|
+
}, Ul = (e) => {
|
|
371
359
|
e.onClose(), d.value = 100, k(() => {
|
|
372
|
-
t.mode !== "combobox" &&
|
|
360
|
+
t.mode !== "combobox" && ge.value || t.focusOpen && (_(), d.value = v.value, C.value = !0);
|
|
373
361
|
});
|
|
374
362
|
};
|
|
375
|
-
|
|
363
|
+
G(
|
|
376
364
|
() => t.disabled || t.isView,
|
|
377
365
|
(e) => {
|
|
378
366
|
if (e && t.mode !== "combobox") {
|
|
379
|
-
|
|
367
|
+
ye.value = !1;
|
|
380
368
|
let l = new Event("blur");
|
|
381
|
-
|
|
369
|
+
Ge(l);
|
|
382
370
|
}
|
|
383
371
|
}
|
|
384
372
|
);
|
|
385
|
-
let
|
|
386
|
-
const
|
|
387
|
-
|
|
388
|
-
|
|
373
|
+
let U = i(!1);
|
|
374
|
+
const jl = (e) => {
|
|
375
|
+
U.value = e, N.value = !0, k(() => {
|
|
376
|
+
N.value = !1, t.focusOpen && (_(), d.value = e ? P : v.value, C.value = !e);
|
|
389
377
|
});
|
|
390
378
|
};
|
|
391
379
|
let re = null;
|
|
392
380
|
Ae(() => {
|
|
393
381
|
re = new IntersectionObserver((e) => {
|
|
394
382
|
e && e[0] && e[0].intersectionRatio > 0 && t.focusOpen && d.value === 0 && (d.value = 100, k(() => {
|
|
395
|
-
|
|
383
|
+
_(), d.value = v.value, C.value = !0;
|
|
396
384
|
}));
|
|
397
|
-
}), re.observe(
|
|
398
|
-
}),
|
|
385
|
+
}), re.observe($.value);
|
|
386
|
+
}), Xe(() => {
|
|
399
387
|
re && re.disconnect();
|
|
400
388
|
});
|
|
401
|
-
const
|
|
402
|
-
var
|
|
403
|
-
if (
|
|
389
|
+
const _ = () => {
|
|
390
|
+
var j;
|
|
391
|
+
if (w.value) {
|
|
404
392
|
v.value = 0;
|
|
405
393
|
return;
|
|
406
394
|
}
|
|
407
|
-
let e = (
|
|
395
|
+
let e = (j = A.value) == null ? void 0 : j.$el;
|
|
408
396
|
if (!e) return;
|
|
409
397
|
let l = e == null ? void 0 : e.querySelector(".ant-select-selection-overflow");
|
|
410
398
|
if (!l) return;
|
|
@@ -424,24 +412,24 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
424
412
|
}
|
|
425
413
|
if (v.value === 0) {
|
|
426
414
|
let h = r[0], xe = h.querySelector(".anticon-close") ? 86 : 69;
|
|
427
|
-
h && !h.classList.contains("ant-select-selection-overflow-item-rest") && xe <= n - u && !
|
|
415
|
+
h && !h.classList.contains("ant-select-selection-overflow-item-rest") && xe <= n - u && !De.tagRender && (v.value = 1, h.classList.add("ellipsis"));
|
|
428
416
|
}
|
|
429
|
-
},
|
|
430
|
-
|
|
417
|
+
}, Se = i(!1);
|
|
418
|
+
G(
|
|
431
419
|
() => a.value,
|
|
432
420
|
async () => {
|
|
433
|
-
if (
|
|
434
|
-
|
|
421
|
+
if (Se.value) {
|
|
422
|
+
Se.value = !1;
|
|
435
423
|
return;
|
|
436
424
|
}
|
|
437
|
-
t.mode !== "combobox" &&
|
|
425
|
+
t.mode !== "combobox" && ge.value || (N.value = !0, d.value = P, await k(), await _(), N.value = !1, t.isExterControlCount && t.focusOpen ? (d.value = U.value ? P : v.value, C.value = !U.value) : (d.value = v.value, C.value = !0));
|
|
438
426
|
}
|
|
439
427
|
);
|
|
440
|
-
const
|
|
441
|
-
if (!
|
|
428
|
+
const Gl = (e) => {
|
|
429
|
+
if (!w.value || t.mode === "combobox") return e;
|
|
442
430
|
const l = Array.isArray(e) ? e : e == null ? [] : [e];
|
|
443
431
|
if (!l.length) return [];
|
|
444
|
-
const n = Array.from(new Set(l.filter((u) => u !==
|
|
432
|
+
const n = Array.from(new Set(l.filter((u) => u !== Be)));
|
|
445
433
|
if (!n.length) return;
|
|
446
434
|
let o = Array.isArray(a.value) ? a.value.slice() : [];
|
|
447
435
|
return n.forEach((u) => {
|
|
@@ -450,113 +438,113 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
450
438
|
}), o;
|
|
451
439
|
}, se = async (e, l, n = "antdv") => {
|
|
452
440
|
ae.value = !1, t.mode === "combobox" && fe();
|
|
453
|
-
let o = n === "antdv" ?
|
|
441
|
+
let o = n === "antdv" ? Gl(e) : e;
|
|
454
442
|
if (o === void 0) {
|
|
455
443
|
z();
|
|
456
444
|
return;
|
|
457
445
|
}
|
|
458
|
-
|
|
446
|
+
Se.value = !0, t.noDropdown && Array.isArray(o) && t.maxTagsLength < o.length && (o = o.slice(), o.pop()), n === "antdv" && w.value && (a.value = o), N.value = !0, x("update:model-value", o), x("change", o, l), z(), d.value = P, await k(), await _(), N.value = !1, t.isExterControlCount && t.focusOpen && (d.value = U.value ? P : v.value, C.value = !U.value), t.focusOpen || (d.value = v.value);
|
|
459
447
|
};
|
|
460
|
-
return
|
|
448
|
+
return D({
|
|
461
449
|
$select: A,
|
|
462
|
-
toChangeMaxCount:
|
|
450
|
+
toChangeMaxCount: jl
|
|
463
451
|
}), (e, l) => {
|
|
464
|
-
const n =
|
|
465
|
-
return f(),
|
|
452
|
+
const n = Yl("v-nodes");
|
|
453
|
+
return f(), g(
|
|
466
454
|
"div",
|
|
467
455
|
{
|
|
468
|
-
class:
|
|
456
|
+
class: et(["das-ui-select", [
|
|
469
457
|
t.borderType,
|
|
470
458
|
t.isView ? "readonly" : "",
|
|
471
459
|
t.error ? "is-error" : "",
|
|
472
|
-
|
|
460
|
+
C.value ? "show-ellipsis" : ""
|
|
473
461
|
]]),
|
|
474
462
|
ref_key: "$selectBox",
|
|
475
|
-
ref:
|
|
476
|
-
style: X(
|
|
477
|
-
onClick: ue(
|
|
463
|
+
ref: $,
|
|
464
|
+
style: X(Vl.value),
|
|
465
|
+
onClick: ue(Kl, ["stop"])
|
|
478
466
|
},
|
|
479
467
|
[
|
|
480
|
-
de.value ? (f(), K(c(
|
|
468
|
+
de.value ? (f(), K(c(at), {
|
|
481
469
|
key: 0,
|
|
482
470
|
ref_key: "inputTooltipRef",
|
|
483
471
|
ref: Me,
|
|
484
472
|
placement: "top",
|
|
485
473
|
"virtual-triggering": "",
|
|
486
474
|
"virtual-ref": de.value,
|
|
487
|
-
disabled:
|
|
488
|
-
content:
|
|
475
|
+
disabled: al.value,
|
|
476
|
+
content: rl.value
|
|
489
477
|
}, null, 8, ["virtual-ref", "disabled", "content"])) : L("v-if", !0),
|
|
490
|
-
Te((f(), K(c(
|
|
491
|
-
value:
|
|
478
|
+
Te((f(), K(c(ot), Le({ mode: cl.value }, Dl.value, {
|
|
479
|
+
value: ml.value,
|
|
492
480
|
ref_key: "$select",
|
|
493
481
|
ref: A,
|
|
494
|
-
options:
|
|
482
|
+
options: gl.value,
|
|
495
483
|
fieldNames: p.fieldNames,
|
|
496
484
|
bordered: t.borderType === "bordered",
|
|
497
485
|
disabled: t.disabled || t.isView,
|
|
498
486
|
showArrow: !0,
|
|
499
|
-
open: t.noDropdown ? !1 :
|
|
487
|
+
open: t.noDropdown ? !1 : ge.value,
|
|
500
488
|
placeholder: Y.value,
|
|
501
489
|
showSearch: t.showSearch,
|
|
502
|
-
optionFilterProp:
|
|
503
|
-
filterOption:
|
|
504
|
-
size:
|
|
490
|
+
optionFilterProp: je.value,
|
|
491
|
+
filterOption: Fe,
|
|
492
|
+
size: dl.value,
|
|
505
493
|
style: t.size == "mini" || t.size == "table" ? { fontSize: "12px" } : {},
|
|
506
494
|
dropdownClassName: "das-ui-select-dorpdown " + p.dropdownClassName,
|
|
507
|
-
maxTagCount:
|
|
508
|
-
getPopupContainer:
|
|
509
|
-
dropdownStyle:
|
|
510
|
-
onDropdownVisibleChange:
|
|
495
|
+
maxTagCount: Cl.value,
|
|
496
|
+
getPopupContainer: El,
|
|
497
|
+
dropdownStyle: Al.value,
|
|
498
|
+
onDropdownVisibleChange: zl,
|
|
511
499
|
onChange: l[4] || (l[4] = (o, u) => se(o, u, "antdv")),
|
|
512
|
-
onFocus:
|
|
513
|
-
onBlur:
|
|
514
|
-
onPopupScroll:
|
|
515
|
-
}),
|
|
500
|
+
onFocus: Zl,
|
|
501
|
+
onBlur: Ge,
|
|
502
|
+
onPopupScroll: Bl
|
|
503
|
+
}), lt({
|
|
516
504
|
option: m((o) => [
|
|
517
|
-
|
|
505
|
+
S(e.$slots, "option", ie(ce(o)), () => [
|
|
518
506
|
o.children && typeof o.children == "function" ? (f(), K(n, {
|
|
519
507
|
key: 0,
|
|
520
508
|
vnodes: o.children()
|
|
521
|
-
}, null, 8, ["vnodes"])) : (f(),
|
|
509
|
+
}, null, 8, ["vnodes"])) : (f(), g(
|
|
522
510
|
ke,
|
|
523
511
|
{ key: 1 },
|
|
524
512
|
[
|
|
525
513
|
L(' :option="{value, label, [disabled, key, title]}" '),
|
|
526
|
-
p.mode === "combobox" ? Te((f(),
|
|
527
|
-
|
|
528
|
-
Z(o[
|
|
514
|
+
p.mode === "combobox" ? Te((f(), g("div", yt, [
|
|
515
|
+
Ve(
|
|
516
|
+
Z(o[I.value]),
|
|
529
517
|
1
|
|
530
518
|
/* TEXT */
|
|
531
519
|
)
|
|
532
520
|
])), [
|
|
533
|
-
[c(
|
|
534
|
-
]) : (f(),
|
|
521
|
+
[c(Ye)]
|
|
522
|
+
]) : (f(), g(
|
|
535
523
|
ke,
|
|
536
524
|
{ key: 1 },
|
|
537
525
|
[
|
|
538
526
|
L(` <das-tooltip v-if="mode === 'combobox'" placement="right-start" :text="option[labelKeyName]"></das-tooltip> `),
|
|
539
527
|
b("div", {
|
|
540
528
|
class: "das-multiple-option-item",
|
|
541
|
-
onMousedown:
|
|
542
|
-
onClick: (u) =>
|
|
529
|
+
onMousedown: Rl,
|
|
530
|
+
onClick: (u) => Hl(o, u)
|
|
543
531
|
}, [
|
|
544
|
-
(f(), K(c(
|
|
532
|
+
(f(), K(c(Qe), {
|
|
545
533
|
class: "das-select-checkbox",
|
|
546
|
-
modelValue:
|
|
547
|
-
key: o[
|
|
534
|
+
modelValue: He.value.has(o[y.value]),
|
|
535
|
+
key: o[y.value],
|
|
548
536
|
disabled: o.disabled
|
|
549
537
|
}, null, 8, ["modelValue", "disabled"])),
|
|
550
|
-
Te((f(),
|
|
551
|
-
|
|
552
|
-
Z(o[
|
|
538
|
+
Te((f(), g("div", bt, [
|
|
539
|
+
Ve(
|
|
540
|
+
Z(o[I.value]),
|
|
553
541
|
1
|
|
554
542
|
/* TEXT */
|
|
555
543
|
)
|
|
556
544
|
])), [
|
|
557
|
-
[c(
|
|
545
|
+
[c(Ye)]
|
|
558
546
|
])
|
|
559
|
-
], 40,
|
|
547
|
+
], 40, gt)
|
|
560
548
|
],
|
|
561
549
|
2112
|
|
562
550
|
/* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
|
|
@@ -568,24 +556,24 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
568
556
|
], !0)
|
|
569
557
|
]),
|
|
570
558
|
tagRender: m((o) => [
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
closable: !
|
|
559
|
+
S(e.$slots, "tagRender", ie(ce(o)), () => [
|
|
560
|
+
V(c(Ie), {
|
|
561
|
+
closable: !w.value && o.closable,
|
|
574
562
|
style: { "margin-right": "3px", "background-color": "transparent" },
|
|
575
|
-
onClose: (u) =>
|
|
563
|
+
onClose: (u) => Ul(o)
|
|
576
564
|
}, {
|
|
577
565
|
default: m(() => [
|
|
578
|
-
|
|
566
|
+
w.value ? (f(), g("span", {
|
|
579
567
|
key: 0,
|
|
580
568
|
innerHTML: c(M)("das-ui-select-selectedItemsCountWithPlaceholder", Q.value)
|
|
581
|
-
}, null, 8,
|
|
569
|
+
}, null, 8, Ct)) : (f(), g(
|
|
582
570
|
"span",
|
|
583
571
|
{
|
|
584
572
|
key: 1,
|
|
585
573
|
class: "tag-span",
|
|
586
574
|
style: X(t.size == "mini" || t.size == "table" ? { fontSize: "12px" } : {})
|
|
587
575
|
},
|
|
588
|
-
Z(
|
|
576
|
+
Z($l(pe(o.value) ?? o.label ?? String(o.value))),
|
|
589
577
|
5
|
|
590
578
|
/* TEXT, STYLE */
|
|
591
579
|
))
|
|
@@ -596,17 +584,17 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
596
584
|
], !0)
|
|
597
585
|
]),
|
|
598
586
|
dropdownRender: m(({ menuNode: o }) => [
|
|
599
|
-
|
|
587
|
+
S(e.$slots, "dropdownRender", ie(ce({ menuNode: o })), () => {
|
|
600
588
|
var u;
|
|
601
589
|
return [
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
])) :
|
|
590
|
+
Ne.value === "combobox" ? (f(), g("div", wt, [
|
|
591
|
+
V(n, { vnodes: o }, null, 8, ["vnodes"])
|
|
592
|
+
])) : Ne.value === "custom" ? (f(), g("div", {
|
|
605
593
|
key: 1,
|
|
606
594
|
onClick: l[2] || (l[2] = ue(() => {
|
|
607
595
|
}, ["stop"]))
|
|
608
596
|
}, [
|
|
609
|
-
|
|
597
|
+
V(n, { vnodes: o }, null, 8, ["vnodes"]),
|
|
610
598
|
b(
|
|
611
599
|
"div",
|
|
612
600
|
{
|
|
@@ -614,14 +602,14 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
614
602
|
onMousedown: l[1] || (l[1] = (r) => r.preventDefault())
|
|
615
603
|
},
|
|
616
604
|
[
|
|
617
|
-
|
|
605
|
+
V(c(rt), Le({
|
|
618
606
|
ref_key: "testInput",
|
|
619
|
-
ref:
|
|
620
|
-
modelValue:
|
|
621
|
-
"onUpdate:modelValue": l[0] || (l[0] = (r) =>
|
|
622
|
-
onKeyup:
|
|
623
|
-
onFocus: ue(
|
|
624
|
-
onBlur: ue(
|
|
607
|
+
ref: sl,
|
|
608
|
+
modelValue: R.value,
|
|
609
|
+
"onUpdate:modelValue": l[0] || (l[0] = (r) => R.value = r),
|
|
610
|
+
onKeyup: tt(_e, ["enter"]),
|
|
611
|
+
onFocus: ue(ul, ["stop"]),
|
|
612
|
+
onBlur: ue(il, ["stop"]),
|
|
625
613
|
width: "100%",
|
|
626
614
|
borderType: "bordered"
|
|
627
615
|
}, t.inputAttrs), null, 16, ["modelValue"]),
|
|
@@ -629,7 +617,7 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
629
617
|
"div",
|
|
630
618
|
{
|
|
631
619
|
class: "addBtn",
|
|
632
|
-
onClick:
|
|
620
|
+
onClick: _e
|
|
633
621
|
},
|
|
634
622
|
Z(c(M)("添加")),
|
|
635
623
|
1
|
|
@@ -639,9 +627,9 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
639
627
|
32
|
|
640
628
|
/* NEED_HYDRATION */
|
|
641
629
|
)
|
|
642
|
-
])) : (f(),
|
|
643
|
-
|
|
644
|
-
(u = t.options) != null && u.length && t.showSelectAll ? (f(),
|
|
630
|
+
])) : (f(), g("div", St, [
|
|
631
|
+
V(n, { vnodes: o }, null, 8, ["vnodes"]),
|
|
632
|
+
(u = t.options) != null && u.length && t.showSelectAll ? (f(), g(
|
|
645
633
|
"div",
|
|
646
634
|
{
|
|
647
635
|
key: 0,
|
|
@@ -649,15 +637,15 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
649
637
|
onMousedown: l[3] || (l[3] = (r) => r.preventDefault())
|
|
650
638
|
},
|
|
651
639
|
[
|
|
652
|
-
b("div",
|
|
653
|
-
|
|
654
|
-
modelValue:
|
|
655
|
-
indeterminate:
|
|
656
|
-
onChange:
|
|
640
|
+
b("div", xt, [
|
|
641
|
+
V(c(Qe), {
|
|
642
|
+
modelValue: Tl.value,
|
|
643
|
+
indeterminate: kl.value,
|
|
644
|
+
onChange: Wl,
|
|
657
645
|
style: { display: "flex" }
|
|
658
646
|
}, {
|
|
659
647
|
default: m(() => [
|
|
660
|
-
|
|
648
|
+
Ve(
|
|
661
649
|
Z(c(M)("全选")),
|
|
662
650
|
1
|
|
663
651
|
/* TEXT */
|
|
@@ -670,7 +658,7 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
670
658
|
b("span", {
|
|
671
659
|
class: "das-ui-dropdown-has-checked",
|
|
672
660
|
innerHTML: c(M)("das-ui-select-selectedItemsCountWithPlaceholder", Q.value)
|
|
673
|
-
}, null, 8,
|
|
661
|
+
}, null, 8, At)
|
|
674
662
|
],
|
|
675
663
|
32
|
|
676
664
|
/* NEED_HYDRATION */
|
|
@@ -680,20 +668,20 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
680
668
|
}, !0)
|
|
681
669
|
]),
|
|
682
670
|
clearIcon: m(() => [
|
|
683
|
-
|
|
684
|
-
|
|
671
|
+
S(e.$slots, "clearIcon", {}, () => [
|
|
672
|
+
V(c(ut), { size: "medium" })
|
|
685
673
|
], !0)
|
|
686
674
|
]),
|
|
687
675
|
maxTagPlaceholder: m((o) => [
|
|
688
|
-
|
|
676
|
+
S(e.$slots, "maxTagPlaceholder", ie(ce(o)), () => [
|
|
689
677
|
L(" 隐藏tag时显示的内容 "),
|
|
690
|
-
|
|
678
|
+
V(c(Ie), {
|
|
691
679
|
style: X(t.size == "mini" || t.size == "table" ? { fontSize: "12px" } : {})
|
|
692
680
|
}, {
|
|
693
681
|
default: m(() => [
|
|
694
682
|
b("span", {
|
|
695
683
|
innerHTML: c(M)("das-ui-select-selectedItemsCountWithPlaceholder", Q.value)
|
|
696
|
-
}, null, 8,
|
|
684
|
+
}, null, 8, Tt)
|
|
697
685
|
]),
|
|
698
686
|
_: 1
|
|
699
687
|
/* STABLE */
|
|
@@ -702,7 +690,7 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
702
690
|
], !0)
|
|
703
691
|
]),
|
|
704
692
|
notFoundContent: m(() => [
|
|
705
|
-
|
|
693
|
+
S(e.$slots, "notFoundContent", {}, () => [
|
|
706
694
|
l[5] || (l[5] = b(
|
|
707
695
|
"div",
|
|
708
696
|
{ class: "hasNoData" },
|
|
@@ -713,15 +701,15 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
713
701
|
], !0)
|
|
714
702
|
]),
|
|
715
703
|
suffixIcon: m(() => [
|
|
716
|
-
|
|
717
|
-
|
|
704
|
+
S(e.$slots, "suffixIcon", {}, () => [
|
|
705
|
+
V(c(st), {
|
|
718
706
|
class: "das-suffix-icon",
|
|
719
707
|
size: "medium"
|
|
720
708
|
})
|
|
721
709
|
], !0)
|
|
722
710
|
]),
|
|
723
711
|
default: m(() => [
|
|
724
|
-
|
|
712
|
+
S(e.$slots, "default", {}, void 0, !0)
|
|
725
713
|
]),
|
|
726
714
|
_: 2
|
|
727
715
|
/* DYNAMIC */
|
|
@@ -729,44 +717,44 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
729
717
|
e.$slots.menuItemSelectedIcon ? {
|
|
730
718
|
name: "menuItemSelectedIcon",
|
|
731
719
|
fn: m(() => [
|
|
732
|
-
|
|
720
|
+
S(e.$slots, "menuItemSelectedIcon", {}, void 0, !0)
|
|
733
721
|
]),
|
|
734
722
|
key: "0"
|
|
735
723
|
} : void 0,
|
|
736
724
|
e.$slots.placeholder ? {
|
|
737
725
|
name: "placeholder",
|
|
738
726
|
fn: m(() => [
|
|
739
|
-
|
|
727
|
+
S(e.$slots, "placeholder", {}, void 0, !0)
|
|
740
728
|
]),
|
|
741
729
|
key: "1"
|
|
742
730
|
} : void 0,
|
|
743
731
|
e.$slots.removeIcon ? {
|
|
744
732
|
name: "removeIcon",
|
|
745
733
|
fn: m(() => [
|
|
746
|
-
|
|
734
|
+
S(e.$slots, "removeIcon", {}, void 0, !0)
|
|
747
735
|
]),
|
|
748
736
|
key: "2"
|
|
749
737
|
} : void 0
|
|
750
738
|
]), 1040, ["mode", "value", "options", "fieldNames", "bordered", "disabled", "open", "placeholder", "showSearch", "optionFilterProp", "size", "style", "dropdownClassName", "maxTagCount", "dropdownStyle"])), [
|
|
751
|
-
[c(
|
|
752
|
-
[c(
|
|
739
|
+
[c(nt), { target: ql, x: !1 }],
|
|
740
|
+
[c(ct), Ol]
|
|
753
741
|
]),
|
|
754
|
-
p.error && p.errorLabel ? (f(),
|
|
742
|
+
p.error && p.errorLabel ? (f(), g(
|
|
755
743
|
ke,
|
|
756
744
|
{ key: 1 },
|
|
757
745
|
[
|
|
758
|
-
p.errorMode === "default" ? (f(),
|
|
746
|
+
p.errorMode === "default" ? (f(), g("div", kt, [
|
|
759
747
|
b(
|
|
760
748
|
"span",
|
|
761
749
|
{
|
|
762
|
-
style: X(
|
|
750
|
+
style: X(Il.value)
|
|
763
751
|
},
|
|
764
752
|
Z(p.errorLabel),
|
|
765
753
|
5
|
|
766
754
|
/* TEXT, STYLE */
|
|
767
755
|
)
|
|
768
756
|
])) : L("v-if", !0),
|
|
769
|
-
p.errorMode === "overlay" &&
|
|
757
|
+
p.errorMode === "overlay" && we.value ? (f(), K(c(it), {
|
|
770
758
|
key: 1,
|
|
771
759
|
errorLabel: p.errorLabel,
|
|
772
760
|
getEl: () => A.value.$el,
|
|
@@ -785,16 +773,16 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
785
773
|
style: { position: "absolute", left: "-50%", top: "-50%", opacity: "0", "pointer-events": "none" }
|
|
786
774
|
},
|
|
787
775
|
[
|
|
788
|
-
b("div",
|
|
789
|
-
b("div",
|
|
790
|
-
b("span",
|
|
791
|
-
|
|
776
|
+
b("div", Vt, [
|
|
777
|
+
b("div", It, [
|
|
778
|
+
b("span", Lt, [
|
|
779
|
+
V(c(Ie), {
|
|
792
780
|
style: X(t.size == "mini" || t.size == "table" ? { fontSize: "12px" } : {})
|
|
793
781
|
}, {
|
|
794
782
|
default: m(() => [
|
|
795
783
|
b("span", {
|
|
796
784
|
innerHTML: c(M)("das-ui-select-selectedItemsCountWithPlaceholder", Q.value)
|
|
797
|
-
}, null, 8,
|
|
785
|
+
}, null, 8, Mt)
|
|
798
786
|
]),
|
|
799
787
|
_: 1
|
|
800
788
|
/* STABLE */
|
|
@@ -812,23 +800,23 @@ const wt = { key: 0 }, xt = ["onClick"], At = { style: { display: "inline-block"
|
|
|
812
800
|
);
|
|
813
801
|
};
|
|
814
802
|
}
|
|
815
|
-
}),
|
|
816
|
-
const
|
|
817
|
-
for (const [t, x] of
|
|
818
|
-
|
|
819
|
-
return
|
|
820
|
-
},
|
|
821
|
-
function
|
|
822
|
-
const
|
|
803
|
+
}), tl = (p, D) => {
|
|
804
|
+
const B = p.__vccOpts || p;
|
|
805
|
+
for (const [t, x] of D)
|
|
806
|
+
B[t] = x;
|
|
807
|
+
return B;
|
|
808
|
+
}, Pt = /* @__PURE__ */ tl(zt, [["__scopeId", "data-v-00ff3a8a"]]), Nt = {};
|
|
809
|
+
function _t(p, D) {
|
|
810
|
+
const B = mt;
|
|
823
811
|
return f(), K(
|
|
824
|
-
|
|
812
|
+
B,
|
|
825
813
|
Le({ class: "das-ui-select-option" }, p.$attrs),
|
|
826
814
|
null,
|
|
827
815
|
16
|
|
828
816
|
/* FULL_PROPS */
|
|
829
817
|
);
|
|
830
818
|
}
|
|
831
|
-
const
|
|
819
|
+
const Dt = /* @__PURE__ */ tl(Nt, [["render", _t]]), Bt = {
|
|
832
820
|
添加: { "zh-CN": "添加", en: "Add", "zh-MO": "添加", _appCode: "framework" },
|
|
833
821
|
全选: { "zh-CN": "全选", en: "Select All", "zh-MO": "全選", _appCode: "framework" },
|
|
834
822
|
已选: { "zh-CN": "已选", en: "Selected", "zh-MO": "已選", _appCode: "framework" },
|
|
@@ -839,10 +827,10 @@ const Rt = /* @__PURE__ */ nl($t, [["render", Wt]]), Ft = {
|
|
|
839
827
|
_appCode: "framework"
|
|
840
828
|
}
|
|
841
829
|
};
|
|
842
|
-
|
|
843
|
-
const
|
|
830
|
+
ft(Bt);
|
|
831
|
+
const no = el(Pt), ao = el(Dt), ro = { name: "select 选择器" };
|
|
844
832
|
export {
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
833
|
+
no as DasSelect,
|
|
834
|
+
ao as DasSelectOption,
|
|
835
|
+
ro as default
|
|
848
836
|
};
|