st-comp 0.0.186 → 0.0.188
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/es/ChartLayout.cjs +1 -1
- package/es/ChartLayout.js +14 -13
- package/es/CustomFunction.cjs +1 -1
- package/es/CustomFunction.js +104 -91
- package/es/FactorWarning.cjs +1 -1
- package/es/FactorWarning.js +31 -28
- package/es/Kline.cjs +1 -1
- package/es/Kline.js +17 -14
- package/es/KlineBasic.cjs +1 -1
- package/es/KlineBasic.js +26 -23
- package/es/KlineConfig.cjs +1 -1
- package/es/KlineConfig.js +22 -19
- package/es/KlineNew.cjs +1 -1
- package/es/KlineNew.js +16 -13
- package/es/KlinePlus.cjs +1 -1
- package/es/KlinePlus.js +19 -16
- package/es/Pagination.cjs +1 -1
- package/es/Pagination.js +88 -85
- package/es/PasswordPrompt.cjs +1 -1
- package/es/PasswordPrompt.js +3 -3
- package/es/Table.cjs +1 -1
- package/es/Table.js +34 -32
- package/es/TreeMap.cjs +1 -2
- package/es/TreeMap.js +1 -163
- package/es/User.cjs +1 -1
- package/es/User.js +53 -50
- package/es/VarSelectDialog.cjs +3 -3
- package/es/VarSelectDialog.js +166 -479
- package/es/VarietyAutoComplete.cjs +1 -0
- package/es/VarietyAutoComplete.js +84 -0
- package/es/VarietySearch.cjs +6 -6
- package/es/VarietySearch.js +50 -47
- package/es/VirtualTable.cjs +1 -1
- package/es/VirtualTable.js +33 -31
- package/es/{_initCloneObject-00cee14a.js → _initCloneObject-25087817.js} +24 -23
- package/es/_initCloneObject-95a1fe6e.cjs +1 -0
- package/es/{base-62a70f61.js → base-f5b11441.js} +40 -40
- package/es/config-provider-79c2df1b.cjs +1 -0
- package/es/{config-provider-89aba243.js → config-provider-95d27ce2.js} +9 -8
- package/es/{debounce-5f2ec4be.js → debounce-06f59c68.js} +10 -10
- package/es/{debounce-0b77a317.cjs → debounce-62f5b6e8.cjs} +1 -1
- package/es/{dropdown-0fd8bdbd.js → dropdown-7a853d45.js} +9 -9
- package/es/{dropdown-babf55db.cjs → dropdown-c2ef9062.cjs} +1 -1
- package/es/el-autocomplete-b7bcfb25.cjs +1 -0
- package/es/el-autocomplete-e74d589c.js +328 -0
- package/es/{el-button-338a49b7.cjs → el-button-5973d99c.cjs} +1 -1
- package/es/{el-button-f44cb2cf.js → el-button-5a260464.js} +33 -33
- package/es/{el-dialog-c2451c86.js → el-dialog-8d8f6443.js} +17 -17
- package/es/{el-dialog-45250561.cjs → el-dialog-a24f4f8f.cjs} +1 -1
- package/es/{el-divider-2f300113.js → el-divider-4e1c0fb8.js} +1 -1
- package/es/el-empty-1697ded8.cjs +1 -0
- package/es/{el-empty-87a86f30.js → el-empty-deee6b39.js} +10 -9
- package/es/{el-form-item-64c14a64.js → el-form-item-3167d76a.js} +74 -73
- package/es/el-form-item-8dc6aec8.cjs +12 -0
- package/es/{el-input-ef6edbf3.js → el-input-03aad76d.js} +33 -33
- package/es/{el-input-c663697a.cjs → el-input-06243b61.cjs} +1 -1
- package/es/{el-input-number-cda5c4e1.js → el-input-number-12c09ac3.js} +70 -70
- package/es/{el-input-number-5fda0890.cjs → el-input-number-854b2066.cjs} +1 -1
- package/es/{el-loading-1be77e7c.js → el-loading-86fdef94.js} +5 -5
- package/es/{el-loading-8c3379d5.cjs → el-loading-a536daf8.cjs} +1 -1
- package/es/{el-menu-item-84a4b594.js → el-menu-item-1172154b.js} +22 -22
- package/es/{el-menu-item-cf9e0e36.cjs → el-menu-item-6522d54c.cjs} +1 -1
- package/es/{el-message-c500161d.cjs → el-message-0aeea1a3.cjs} +1 -1
- package/es/{el-message-ba131b90.js → el-message-35d4e3ac.js} +23 -23
- package/es/{el-message-box-743c461a.cjs → el-message-box-2e7304ce.cjs} +1 -1
- package/es/{el-message-box-38779ab9.js → el-message-box-f43b6e7a.js} +20 -20
- package/es/{el-overlay-a6f43919.js → el-overlay-04659660.js} +41 -41
- package/es/{el-overlay-39e2e96f.cjs → el-overlay-ef92f51f.cjs} +1 -1
- package/es/{el-popconfirm-16597a41.js → el-popconfirm-29d538b6.js} +20 -20
- package/es/{el-popconfirm-08b4221f.cjs → el-popconfirm-58a1b946.cjs} +1 -1
- package/es/{el-popper-dca2de0d.cjs → el-popper-c9e0136d.cjs} +1 -1
- package/es/{el-popper-05a8f271.js → el-popper-ee1f8186.js} +79 -79
- package/es/el-scrollbar-05815cf5.cjs +1 -0
- package/es/el-scrollbar-09769d9e.js +395 -0
- package/es/{el-segmented-d68dfe31.js → el-segmented-916b982a.js} +8 -8
- package/es/{el-segmented-c2952e4c.cjs → el-segmented-d454a924.cjs} +1 -1
- package/es/el-select-6d813c15.cjs +1 -0
- package/es/{el-select-7846f331.js → el-select-8cb88e3c.js} +364 -361
- package/es/{el-table-column-cd63e722.js → el-table-column-0c899664.js} +147 -145
- package/es/el-table-column-762a20e0.cjs +14 -0
- package/es/{el-tag-914c96a9.js → el-tag-554c333b.js} +27 -26
- package/es/el-tag-fe492a6d.cjs +1 -0
- package/es/index-34048a1d.js +314 -0
- package/es/{index-b132c1b1.js → index-384ed4b0.js} +3 -3
- package/es/index-5b62ea0e.js +375 -0
- package/es/{index-1c409d46.cjs → index-62573d45.cjs} +1 -1
- package/es/{index-14c322b1.js → index-69a9bd75.js} +2 -2
- package/es/{index-2bf6214c.cjs → index-77f4746b.cjs} +1 -1
- package/es/index-7e4e0bd3.cjs +1 -0
- package/es/index-9780a537.cjs +1 -0
- package/es/{index-e6deec5d.cjs → index-a9d4ef0f.cjs} +1 -1
- package/es/{index-35129268.js → index-b07f58c9.js} +76 -61
- package/es/index-b7fd560c.js +60 -0
- package/es/index-bb833443.cjs +1 -0
- package/es/index-ca7dbd47.cjs +1 -0
- package/es/index-cfeda35a.js +204 -0
- package/es/{index-20749652.js → index-df06f32a.js} +15 -15
- package/es/index-eab8a286.cjs +1 -0
- package/es/raf-fa761d02.js +6 -0
- package/es/{scroll-7d352c1f.js → scroll-9e2dd92b.js} +5 -5
- package/es/style.css +1 -1
- package/es/use-global-config-1923bb6f.js +72 -0
- package/es/use-global-config-c2c5ca8f.cjs +1 -0
- package/es/{validator-f66b0f34.cjs → validator-866ea0bb.cjs} +1 -1
- package/es/{validator-90d3e848.js → validator-fd32f925.js} +1 -1
- package/es/vnode-b906ae6d.cjs +1 -0
- package/es/vnode-f9752526.js +14 -0
- package/es/{zh-cn-de7ae601.cjs → zh-cn-0fa1aa6d.cjs} +1 -1
- package/es/{zh-cn-530f1ed1.js → zh-cn-d667062d.js} +2 -2
- package/lib/bundle.js +1 -1
- package/lib/bundle.umd.cjs +139 -139
- package/lib/{index-26fab3e5.js → index-02706357.js} +14643 -14551
- package/lib/{python-c34eeb40.js → python-42146c31.js} +1 -1
- package/lib/style.css +1 -1
- package/package.json +1 -1
- package/packages/CustomFunction/index.vue +11 -2
- package/packages/VarietyAutoComplete/index.ts +8 -0
- package/packages/VarietyAutoComplete/index.vue +89 -0
- package/packages/index.ts +2 -0
- package/src/pages/VarietyAutoComplete/index.vue +19 -0
- package/src/router/routes.ts +5 -0
- package/es/_initCloneObject-4dd3c9a4.cjs +0 -1
- package/es/config-provider-d82ea78c.cjs +0 -1
- package/es/el-empty-bb2b0235.cjs +0 -1
- package/es/el-form-item-b5f6081b.cjs +0 -12
- package/es/el-scrollbar-31d72626.js +0 -763
- package/es/el-scrollbar-802d874d.cjs +0 -1
- package/es/el-select-8337856d.cjs +0 -1
- package/es/el-table-column-34f080b5.cjs +0 -14
- package/es/el-tag-a2e99294.cjs +0 -1
- package/es/index-34592e82.js +0 -513
- package/es/index-3a74eae4.cjs +0 -1
- package/es/index-8feed26f.cjs +0 -1
- package/es/raf-41aed4d4.js +0 -6
- package/es/use-global-config-53be2b7d.js +0 -71
- package/es/use-global-config-f3664595.cjs +0 -1
- package/es/vnode-6d51e502.cjs +0 -1
- package/es/vnode-8ddc4f78.js +0 -70
|
@@ -1,46 +1,49 @@
|
|
|
1
|
-
import { shallowRef as
|
|
2
|
-
import {
|
|
3
|
-
import { t as
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { b as
|
|
7
|
-
import {
|
|
8
|
-
import { u as
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import { shallowRef as il, ref as T, computed as u, inject as we, getCurrentInstance as Ve, toRaw as rl, watch as G, defineComponent as pe, unref as $e, reactive as de, toRefs as Be, onBeforeUnmount as ft, nextTick as Q, withDirectives as ue, openBlock as v, createElementBlock as w, normalizeClass as b, withModifiers as F, renderSlot as M, createElementVNode as k, toDisplayString as H, vShow as Pe, onMounted as We, normalizeStyle as Ce, createCommentVNode as L, watchEffect as ul, provide as vt, isVNode as dl, resolveComponent as q, resolveDirective as cl, toHandlerKey as pl, createVNode as _, withCtx as $, Fragment as se, renderList as Se, createTextVNode as ot, createBlock as P, withKeys as ie, vModelText as fl, resolveDynamicComponent as Le, mergeProps as at, normalizeProps as vl } from "vue";
|
|
2
|
+
import { t as ml, d as st, e as bl, U as x, C as Fe, a as it, q as hl, u as gl, s as yl, f as Sl, E as Ol } from "./el-popper-ee1f8186.js";
|
|
3
|
+
import { t as rt, E as Cl } from "./index-384ed4b0.js";
|
|
4
|
+
import { j as wl, f as Vl, E as El } from "./index-b07f58c9.js";
|
|
5
|
+
import { g as z, u as Il } from "./index-cfeda35a.js";
|
|
6
|
+
import { b as mt, h as U, u as ce, _ as Ee, i as j, q as Oe, J as ut, a as Tl, f as kl, c as re, P as Dl, e as Ml, d as W, w as Rl, y as bt } from "./base-f5b11441.js";
|
|
7
|
+
import { f as J, d as le, g as $l, u as Ll } from "./index-5b62ea0e.js";
|
|
8
|
+
import { u as ht } from "./index-34048a1d.js";
|
|
9
|
+
import { h as ee, e as Nl, f as Bl, V as Pl, a as Wl, u as Fl, i as dt, t as zl } from "./el-scrollbar-09769d9e.js";
|
|
10
|
+
import { a as Al, u as Kl } from "./index-b7fd560c.js";
|
|
11
|
+
import { s as Hl } from "./scroll-9e2dd92b.js";
|
|
12
|
+
import { t as Gl, d as Ul } from "./debounce-06f59c68.js";
|
|
13
|
+
import { b as jl, C as ql } from "./el-tag-554c333b.js";
|
|
14
|
+
import { f as Ql } from "./vnode-f9752526.js";
|
|
15
|
+
var ct = 1 / 0, Jl = 17976931348623157e292;
|
|
16
|
+
function Xl(e) {
|
|
14
17
|
if (!e)
|
|
15
18
|
return e === 0 ? e : 0;
|
|
16
|
-
if (e =
|
|
19
|
+
if (e = Gl(e), e === ct || e === -ct) {
|
|
17
20
|
var o = e < 0 ? -1 : 1;
|
|
18
|
-
return o *
|
|
21
|
+
return o * Jl;
|
|
19
22
|
}
|
|
20
23
|
return e === e ? e : 0;
|
|
21
24
|
}
|
|
22
|
-
function
|
|
23
|
-
var o =
|
|
25
|
+
function Yl(e) {
|
|
26
|
+
var o = Xl(e), a = o % 1;
|
|
24
27
|
return o === o ? a ? o - a : o : 0;
|
|
25
28
|
}
|
|
26
|
-
function
|
|
29
|
+
function Zl(e, o, a, f) {
|
|
27
30
|
for (var d = e.length, p = a + (f ? 1 : -1); f ? p-- : ++p < d; )
|
|
28
31
|
if (o(e[p], p, e))
|
|
29
32
|
return p;
|
|
30
33
|
return -1;
|
|
31
34
|
}
|
|
32
|
-
var
|
|
35
|
+
var _l = Math.max, xl = Math.min;
|
|
33
36
|
function en(e, o, a) {
|
|
34
37
|
var f = e == null ? 0 : e.length;
|
|
35
38
|
if (!f)
|
|
36
39
|
return -1;
|
|
37
40
|
var d = f - 1;
|
|
38
|
-
return a !== void 0 && (d =
|
|
41
|
+
return a !== void 0 && (d = Yl(a), d = a < 0 ? _l(f + d, 0) : xl(d, f - 1)), Zl(e, jl(o), d, !0);
|
|
39
42
|
}
|
|
40
|
-
const
|
|
41
|
-
function
|
|
42
|
-
const e =
|
|
43
|
-
minWidth: `${Math.max(o.value,
|
|
43
|
+
const gt = 11, tn = 2;
|
|
44
|
+
function ln() {
|
|
45
|
+
const e = il(), o = T(0), a = u(() => ({
|
|
46
|
+
minWidth: `${Math.max(o.value, gt)}px`
|
|
44
47
|
}));
|
|
45
48
|
return ee(e, () => {
|
|
46
49
|
var d, p;
|
|
@@ -51,23 +54,23 @@ function tn() {
|
|
|
51
54
|
inputStyle: a
|
|
52
55
|
};
|
|
53
56
|
}
|
|
54
|
-
const
|
|
57
|
+
const yt = {
|
|
55
58
|
label: "label",
|
|
56
59
|
value: "value",
|
|
57
60
|
disabled: "disabled",
|
|
58
61
|
options: "options"
|
|
59
62
|
};
|
|
60
63
|
function nn(e) {
|
|
61
|
-
const o = u(() => ({ ...
|
|
64
|
+
const o = u(() => ({ ...yt, ...e.props }));
|
|
62
65
|
return {
|
|
63
66
|
aliasProps: o,
|
|
64
|
-
getLabel: (
|
|
65
|
-
getValue: (
|
|
66
|
-
getDisabled: (
|
|
67
|
-
getOptions: (
|
|
67
|
+
getLabel: (l) => z(l, o.value.label),
|
|
68
|
+
getValue: (l) => z(l, o.value.value),
|
|
69
|
+
getDisabled: (l) => z(l, o.value.disabled),
|
|
70
|
+
getOptions: (l) => z(l, o.value.options)
|
|
68
71
|
};
|
|
69
72
|
}
|
|
70
|
-
const
|
|
73
|
+
const St = Symbol("ElSelectGroup"), Ie = Symbol("ElSelect"), Ne = "ElOption", on = mt({
|
|
71
74
|
value: {
|
|
72
75
|
type: [String, Number, Boolean, Object],
|
|
73
76
|
required: !0
|
|
@@ -80,34 +83,34 @@ const Sl = Symbol("ElSelectGroup"), Ie = Symbol("ElSelect"), Ne = "ElOption", on
|
|
|
80
83
|
}), an = (e = "") => e.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
81
84
|
function sn(e, o) {
|
|
82
85
|
const a = we(Ie);
|
|
83
|
-
a ||
|
|
84
|
-
const f = we(
|
|
86
|
+
a || ml(Ne, "usage: <el-select><el-option /></el-select/>");
|
|
87
|
+
const f = we(St, { disabled: !1 }), d = u(() => y(J(a.props.modelValue), e.value)), p = u(() => {
|
|
85
88
|
var i;
|
|
86
89
|
if (a.props.multiple) {
|
|
87
|
-
const O =
|
|
90
|
+
const O = J((i = a.props.modelValue) != null ? i : []);
|
|
88
91
|
return !d.value && O.length >= a.props.multipleLimit && a.props.multipleLimit > 0;
|
|
89
92
|
} else
|
|
90
93
|
return !1;
|
|
91
|
-
}),
|
|
94
|
+
}), l = u(() => {
|
|
92
95
|
var i;
|
|
93
96
|
return (i = e.label) != null ? i : U(e.value) ? "" : e.value;
|
|
94
97
|
}), C = u(() => e.value || e.label || ""), h = u(() => e.disabled || o.groupDisabled || p.value), S = Ve(), y = (i = [], O) => {
|
|
95
98
|
if (U(e.value)) {
|
|
96
99
|
const I = a.props.valueKey;
|
|
97
|
-
return i && i.some((R) =>
|
|
100
|
+
return i && i.some((R) => rl(z(R, I)) === z(O, I));
|
|
98
101
|
} else
|
|
99
102
|
return i && i.includes(O);
|
|
100
|
-
},
|
|
103
|
+
}, m = () => {
|
|
101
104
|
!e.disabled && !f.disabled && (a.states.hoveringIndex = a.optionsArray.indexOf(S.proxy));
|
|
102
105
|
}, s = (i) => {
|
|
103
106
|
const O = new RegExp(an(i), "i");
|
|
104
|
-
o.visible = O.test(String(
|
|
107
|
+
o.visible = O.test(String(l.value)) || e.created;
|
|
105
108
|
};
|
|
106
|
-
return G(() =>
|
|
109
|
+
return G(() => l.value, () => {
|
|
107
110
|
!e.created && !a.props.remote && a.setSelected();
|
|
108
111
|
}), G(() => e.value, (i, O) => {
|
|
109
112
|
const { remote: I, valueKey: R } = a.props;
|
|
110
|
-
if ((I ? i !== O : !
|
|
113
|
+
if ((I ? i !== O : !le(i, O)) && (a.onOptionDestroy(O, S.proxy), a.onOptionCreate(S.proxy)), !e.created && !I) {
|
|
111
114
|
if (R && U(i) && U(O) && i[R] === O[R])
|
|
112
115
|
return;
|
|
113
116
|
a.setSelected();
|
|
@@ -116,11 +119,11 @@ function sn(e, o) {
|
|
|
116
119
|
o.groupDisabled = f.disabled;
|
|
117
120
|
}, { immediate: !0 }), {
|
|
118
121
|
select: a,
|
|
119
|
-
currentLabel:
|
|
122
|
+
currentLabel: l,
|
|
120
123
|
currentValue: C,
|
|
121
124
|
itemSelected: d,
|
|
122
125
|
isDisabled: h,
|
|
123
|
-
hoverItem:
|
|
126
|
+
hoverItem: m,
|
|
124
127
|
updateOption: s
|
|
125
128
|
};
|
|
126
129
|
}
|
|
@@ -129,10 +132,10 @@ const rn = pe({
|
|
|
129
132
|
componentName: Ne,
|
|
130
133
|
props: on,
|
|
131
134
|
setup(e) {
|
|
132
|
-
const o = ce("select"), a =
|
|
135
|
+
const o = ce("select"), a = ht(), f = u(() => [
|
|
133
136
|
o.be("dropdown", "item"),
|
|
134
137
|
o.is("disabled", $e(C)),
|
|
135
|
-
o.is("selected", $e(
|
|
138
|
+
o.is("selected", $e(l)),
|
|
136
139
|
o.is("hovering", $e(s))
|
|
137
140
|
]), d = de({
|
|
138
141
|
index: -1,
|
|
@@ -141,13 +144,13 @@ const rn = pe({
|
|
|
141
144
|
hover: !1
|
|
142
145
|
}), {
|
|
143
146
|
currentLabel: p,
|
|
144
|
-
itemSelected:
|
|
147
|
+
itemSelected: l,
|
|
145
148
|
isDisabled: C,
|
|
146
149
|
select: h,
|
|
147
150
|
hoverItem: S,
|
|
148
151
|
updateOption: y
|
|
149
|
-
} = sn(e, d), { visible:
|
|
150
|
-
h.onOptionCreate(i),
|
|
152
|
+
} = sn(e, d), { visible: m, hover: s } = Be(d), i = Ve().proxy;
|
|
153
|
+
h.onOptionCreate(i), ft(() => {
|
|
151
154
|
const I = i.value;
|
|
152
155
|
Q(() => {
|
|
153
156
|
const { selected: R } = h.states, g = R.some((c) => c.value === i.value);
|
|
@@ -162,10 +165,10 @@ const rn = pe({
|
|
|
162
165
|
id: a,
|
|
163
166
|
containerKls: f,
|
|
164
167
|
currentLabel: p,
|
|
165
|
-
itemSelected:
|
|
168
|
+
itemSelected: l,
|
|
166
169
|
isDisabled: C,
|
|
167
170
|
select: h,
|
|
168
|
-
visible:
|
|
171
|
+
visible: m,
|
|
169
172
|
hover: s,
|
|
170
173
|
states: d,
|
|
171
174
|
hoverItem: S,
|
|
@@ -177,7 +180,7 @@ const rn = pe({
|
|
|
177
180
|
function un(e, o) {
|
|
178
181
|
return ue((v(), w("li", {
|
|
179
182
|
id: e.id,
|
|
180
|
-
class:
|
|
183
|
+
class: b(e.containerKls),
|
|
181
184
|
role: "option",
|
|
182
185
|
"aria-disabled": e.isDisabled || void 0,
|
|
183
186
|
"aria-selected": e.itemSelected,
|
|
@@ -197,13 +200,13 @@ const dn = pe({
|
|
|
197
200
|
componentName: "ElSelectDropdown",
|
|
198
201
|
setup() {
|
|
199
202
|
const e = we(Ie), o = ce("select"), a = u(() => e.props.popperClass), f = u(() => e.props.multiple), d = u(() => e.props.fitInputWidth), p = T("");
|
|
200
|
-
function
|
|
203
|
+
function l() {
|
|
201
204
|
var C;
|
|
202
205
|
const h = (C = e.selectRef) == null ? void 0 : C.offsetWidth;
|
|
203
|
-
h ? p.value = `${h -
|
|
206
|
+
h ? p.value = `${h - tn}px` : p.value = "";
|
|
204
207
|
}
|
|
205
208
|
return We(() => {
|
|
206
|
-
|
|
209
|
+
l(), ee(e.selectRef, l);
|
|
207
210
|
}), {
|
|
208
211
|
ns: o,
|
|
209
212
|
minWidth: p,
|
|
@@ -215,19 +218,19 @@ const dn = pe({
|
|
|
215
218
|
});
|
|
216
219
|
function cn(e, o, a, f, d, p) {
|
|
217
220
|
return v(), w("div", {
|
|
218
|
-
class:
|
|
221
|
+
class: b([e.ns.b("dropdown"), e.ns.is("multiple", e.isMultiple), e.popperClass]),
|
|
219
222
|
style: Ce({ [e.isFitInputWidth ? "width" : "minWidth"]: e.minWidth })
|
|
220
223
|
}, [
|
|
221
224
|
e.$slots.header ? (v(), w("div", {
|
|
222
225
|
key: 0,
|
|
223
|
-
class:
|
|
226
|
+
class: b(e.ns.be("dropdown", "header"))
|
|
224
227
|
}, [
|
|
225
228
|
M(e.$slots, "header")
|
|
226
229
|
], 2)) : L("v-if", !0),
|
|
227
230
|
M(e.$slots, "default"),
|
|
228
231
|
e.$slots.footer ? (v(), w("div", {
|
|
229
232
|
key: 1,
|
|
230
|
-
class:
|
|
233
|
+
class: b(e.ns.be("dropdown", "footer"))
|
|
231
234
|
}, [
|
|
232
235
|
M(e.$slots, "footer")
|
|
233
236
|
], 2)) : L("v-if", !0)
|
|
@@ -235,7 +238,7 @@ function cn(e, o, a, f, d, p) {
|
|
|
235
238
|
}
|
|
236
239
|
var pn = /* @__PURE__ */ Ee(dn, [["render", cn], ["__file", "select-dropdown.vue"]]);
|
|
237
240
|
const fn = (e, o) => {
|
|
238
|
-
const { t: a } =
|
|
241
|
+
const { t: a } = Il(), f = ht(), d = ce("select"), p = ce("input"), l = de({
|
|
239
242
|
inputValue: "",
|
|
240
243
|
options: /* @__PURE__ */ new Map(),
|
|
241
244
|
cachedOptions: /* @__PURE__ */ new Map(),
|
|
@@ -249,106 +252,106 @@ const fn = (e, o) => {
|
|
|
249
252
|
inputHovering: !1,
|
|
250
253
|
menuVisibleOnFocus: !1,
|
|
251
254
|
isBeforeHide: !1
|
|
252
|
-
}), C = T(), h = T(), S = T(), y = T(),
|
|
255
|
+
}), C = T(), h = T(), S = T(), y = T(), m = T(), s = T(), i = T(), O = T(), I = T(), R = T(), g = T(), c = T(!1), V = T(), { form: X, formItem: B } = Nl(), { inputId: A } = Bl(e, {
|
|
253
256
|
formItemContext: B
|
|
254
|
-
}), { valueOnClear: Ke, isEmptyValue:
|
|
257
|
+
}), { valueOnClear: Ke, isEmptyValue: Y } = $l(e), {
|
|
255
258
|
isComposing: He,
|
|
256
|
-
handleCompositionStart:
|
|
257
|
-
handleCompositionUpdate:
|
|
258
|
-
handleCompositionEnd:
|
|
259
|
-
} =
|
|
260
|
-
afterComposition: (
|
|
261
|
-
}), ne = u(() => e.disabled || !!(
|
|
259
|
+
handleCompositionStart: Ot,
|
|
260
|
+
handleCompositionUpdate: Ct,
|
|
261
|
+
handleCompositionEnd: wt
|
|
262
|
+
} = Al({
|
|
263
|
+
afterComposition: (t) => Ze(t)
|
|
264
|
+
}), ne = u(() => e.disabled || !!(X != null && X.disabled)), { wrapperRef: Ge, isFocused: Te, handleBlur: Vt } = Kl(m, {
|
|
262
265
|
disabled: ne,
|
|
263
266
|
afterFocus() {
|
|
264
|
-
e.automaticDropdown && !c.value && (c.value = !0,
|
|
267
|
+
e.automaticDropdown && !c.value && (c.value = !0, l.menuVisibleOnFocus = !0);
|
|
265
268
|
},
|
|
266
|
-
beforeBlur(
|
|
269
|
+
beforeBlur(t) {
|
|
267
270
|
var n, r;
|
|
268
|
-
return ((n = S.value) == null ? void 0 : n.isFocusInsideContent(
|
|
271
|
+
return ((n = S.value) == null ? void 0 : n.isFocusInsideContent(t)) || ((r = y.value) == null ? void 0 : r.isFocusInsideContent(t));
|
|
269
272
|
},
|
|
270
273
|
afterBlur() {
|
|
271
|
-
var
|
|
272
|
-
c.value = !1,
|
|
274
|
+
var t;
|
|
275
|
+
c.value = !1, l.menuVisibleOnFocus = !1, e.validateEvent && ((t = B == null ? void 0 : B.validate) == null || t.call(B, "blur").catch((n) => st()));
|
|
273
276
|
}
|
|
274
|
-
}), ke = u(() => j(e.modelValue) ? e.modelValue.length > 0 : !
|
|
275
|
-
var
|
|
276
|
-
return (
|
|
277
|
-
}),
|
|
278
|
-
const
|
|
279
|
-
return
|
|
280
|
-
const E =
|
|
281
|
-
E > -1 && n.push(
|
|
282
|
-
}), n.length >=
|
|
283
|
-
}), $
|
|
284
|
-
const
|
|
285
|
-
return e.filterable && e.allowCreate &&
|
|
277
|
+
}), ke = u(() => j(e.modelValue) ? e.modelValue.length > 0 : !Y(e.modelValue)), Et = u(() => {
|
|
278
|
+
var t;
|
|
279
|
+
return (t = X == null ? void 0 : X.statusIcon) != null ? t : !1;
|
|
280
|
+
}), It = u(() => e.clearable && !ne.value && ke.value && (Te.value || l.inputHovering)), Ue = u(() => e.remote && e.filterable && !e.remoteShowSuffix ? "" : e.suffixIcon), Tt = u(() => d.is("reverse", !!(Ue.value && c.value))), De = u(() => (B == null ? void 0 : B.validateState) || ""), kt = u(() => De.value && Pl[De.value]), Dt = u(() => e.remote ? 300 : 0), Mt = u(() => e.remote && !l.inputValue && l.options.size === 0), Rt = u(() => e.loading ? e.loadingText || a("el.select.loading") : e.filterable && l.inputValue && l.options.size > 0 && oe.value === 0 ? e.noMatchText || a("el.select.noMatch") : l.options.size === 0 ? e.noDataText || a("el.select.noData") : null), oe = u(() => D.value.filter((t) => t.visible).length), D = u(() => {
|
|
281
|
+
const t = Array.from(l.options.values()), n = [];
|
|
282
|
+
return l.optionValues.forEach((r) => {
|
|
283
|
+
const E = t.findIndex((N) => N.value === r);
|
|
284
|
+
E > -1 && n.push(t[E]);
|
|
285
|
+
}), n.length >= t.length ? n : t;
|
|
286
|
+
}), $t = u(() => Array.from(l.cachedOptions.values())), Lt = u(() => {
|
|
287
|
+
const t = D.value.filter((n) => !n.created).some((n) => n.currentLabel === l.inputValue);
|
|
288
|
+
return e.filterable && e.allowCreate && l.inputValue !== "" && !t;
|
|
286
289
|
}), je = () => {
|
|
287
|
-
e.filterable && re(e.filterMethod) || e.filterable && e.remote && re(e.remoteMethod) || D.value.forEach((
|
|
290
|
+
e.filterable && re(e.filterMethod) || e.filterable && e.remote && re(e.remoteMethod) || D.value.forEach((t) => {
|
|
288
291
|
var n;
|
|
289
|
-
(n =
|
|
292
|
+
(n = t.updateOption) == null || n.call(t, l.inputValue);
|
|
290
293
|
});
|
|
291
|
-
}, qe =
|
|
294
|
+
}, qe = Wl(), Nt = u(() => ["small"].includes(qe.value) ? "small" : "default"), Qe = u({
|
|
292
295
|
get() {
|
|
293
|
-
return c.value && !
|
|
296
|
+
return c.value && !Mt.value;
|
|
294
297
|
},
|
|
295
|
-
set(
|
|
296
|
-
c.value =
|
|
298
|
+
set(t) {
|
|
299
|
+
c.value = t;
|
|
297
300
|
}
|
|
298
|
-
}),
|
|
301
|
+
}), Bt = u(() => {
|
|
299
302
|
if (e.multiple && !Oe(e.modelValue))
|
|
300
|
-
return
|
|
301
|
-
const
|
|
302
|
-
return e.filterable || Oe(
|
|
303
|
-
}),
|
|
304
|
-
var
|
|
305
|
-
const n = (
|
|
306
|
-
return e.multiple || !ke.value ? n :
|
|
307
|
-
}),
|
|
308
|
-
G(() => e.modelValue, (
|
|
309
|
-
e.multiple && e.filterable && !e.reserveKeyword && (
|
|
303
|
+
return J(e.modelValue).length === 0 && !l.inputValue;
|
|
304
|
+
const t = j(e.modelValue) ? e.modelValue[0] : e.modelValue;
|
|
305
|
+
return e.filterable || Oe(t) ? !l.inputValue : !0;
|
|
306
|
+
}), Pt = u(() => {
|
|
307
|
+
var t;
|
|
308
|
+
const n = (t = e.placeholder) != null ? t : a("el.select.placeholder");
|
|
309
|
+
return e.multiple || !ke.value ? n : l.selectedLabel;
|
|
310
|
+
}), Wt = u(() => ut ? null : "mouseenter");
|
|
311
|
+
G(() => e.modelValue, (t, n) => {
|
|
312
|
+
e.multiple && e.filterable && !e.reserveKeyword && (l.inputValue = "", fe("")), ve(), !le(t, n) && e.validateEvent && (B == null || B.validate("change").catch((r) => st()));
|
|
310
313
|
}, {
|
|
311
314
|
flush: "post",
|
|
312
315
|
deep: !0
|
|
313
|
-
}), G(() => c.value, (
|
|
314
|
-
|
|
315
|
-
}), G(() =>
|
|
316
|
-
|
|
316
|
+
}), G(() => c.value, (t) => {
|
|
317
|
+
t ? fe(l.inputValue) : (l.inputValue = "", l.previousQuery = null, l.isBeforeHide = !0), o("visible-change", t);
|
|
318
|
+
}), G(() => l.options.entries(), () => {
|
|
319
|
+
Tl && (ve(), e.defaultFirstOption && (e.filterable || e.remote) && oe.value && Je());
|
|
317
320
|
}, {
|
|
318
321
|
flush: "post"
|
|
319
|
-
}), G([() =>
|
|
320
|
-
|
|
322
|
+
}), G([() => l.hoveringIndex, D], ([t]) => {
|
|
323
|
+
kl(t) && t > -1 ? V.value = D.value[t] || {} : V.value = {}, D.value.forEach((n) => {
|
|
321
324
|
n.hover = V.value === n;
|
|
322
325
|
});
|
|
323
|
-
}),
|
|
324
|
-
|
|
326
|
+
}), ul(() => {
|
|
327
|
+
l.isBeforeHide || je();
|
|
325
328
|
});
|
|
326
|
-
const fe = (
|
|
327
|
-
|
|
328
|
-
},
|
|
329
|
-
const
|
|
330
|
-
|
|
329
|
+
const fe = (t) => {
|
|
330
|
+
l.previousQuery === t || He.value || (l.previousQuery = t, e.filterable && re(e.filterMethod) ? e.filterMethod(t) : e.filterable && e.remote && re(e.remoteMethod) && e.remoteMethod(t), e.defaultFirstOption && (e.filterable || e.remote) && oe.value ? Q(Je) : Q(Ft));
|
|
331
|
+
}, Je = () => {
|
|
332
|
+
const t = D.value.filter((N) => N.visible && !N.disabled && !N.states.groupDisabled), n = t.find((N) => N.created), r = t[0], E = D.value.map((N) => N.value);
|
|
333
|
+
l.hoveringIndex = tt(E, n || r);
|
|
331
334
|
}, ve = () => {
|
|
332
335
|
if (e.multiple)
|
|
333
|
-
|
|
336
|
+
l.selectedLabel = "";
|
|
334
337
|
else {
|
|
335
338
|
const n = j(e.modelValue) ? e.modelValue[0] : e.modelValue, r = Me(n);
|
|
336
|
-
|
|
339
|
+
l.selectedLabel = r.currentLabel, l.selected = [r];
|
|
337
340
|
return;
|
|
338
341
|
}
|
|
339
|
-
const
|
|
340
|
-
Oe(e.modelValue) ||
|
|
341
|
-
|
|
342
|
-
}),
|
|
343
|
-
}, Me = (
|
|
342
|
+
const t = [];
|
|
343
|
+
Oe(e.modelValue) || J(e.modelValue).forEach((n) => {
|
|
344
|
+
t.push(Me(n));
|
|
345
|
+
}), l.selected = t;
|
|
346
|
+
}, Me = (t) => {
|
|
344
347
|
let n;
|
|
345
|
-
const r =
|
|
346
|
-
for (let
|
|
347
|
-
const K = $
|
|
348
|
-
if (r ? z(K.value, e.valueKey) === z(
|
|
348
|
+
const r = Dl(t);
|
|
349
|
+
for (let te = l.cachedOptions.size - 1; te >= 0; te--) {
|
|
350
|
+
const K = $t.value[te];
|
|
351
|
+
if (r ? z(K.value, e.valueKey) === z(t, e.valueKey) : K.value === t) {
|
|
349
352
|
n = {
|
|
350
|
-
index: D.value.filter((
|
|
351
|
-
value:
|
|
353
|
+
index: D.value.filter((Z) => !Z.created).indexOf(K),
|
|
354
|
+
value: t,
|
|
352
355
|
currentLabel: K.currentLabel,
|
|
353
356
|
get isDisabled() {
|
|
354
357
|
return K.isDisabled;
|
|
@@ -359,151 +362,151 @@ const fn = (e, o) => {
|
|
|
359
362
|
}
|
|
360
363
|
if (n)
|
|
361
364
|
return n;
|
|
362
|
-
const E = r ?
|
|
365
|
+
const E = r ? t.label : t ?? "";
|
|
363
366
|
return {
|
|
364
367
|
index: -1,
|
|
365
|
-
value:
|
|
368
|
+
value: t,
|
|
366
369
|
currentLabel: E
|
|
367
370
|
};
|
|
368
|
-
},
|
|
369
|
-
|
|
370
|
-
},
|
|
371
|
-
|
|
372
|
-
},
|
|
373
|
-
|
|
371
|
+
}, Ft = () => {
|
|
372
|
+
l.hoveringIndex = D.value.findIndex((t) => l.selected.some((n) => he(n) === he(t)));
|
|
373
|
+
}, zt = () => {
|
|
374
|
+
l.selectionWidth = Number.parseFloat(window.getComputedStyle(h.value).width);
|
|
375
|
+
}, At = () => {
|
|
376
|
+
l.collapseItemWidth = R.value.getBoundingClientRect().width;
|
|
374
377
|
}, Re = () => {
|
|
375
|
-
var
|
|
376
|
-
(n = (
|
|
378
|
+
var t, n;
|
|
379
|
+
(n = (t = S.value) == null ? void 0 : t.updatePopper) == null || n.call(t);
|
|
380
|
+
}, Xe = () => {
|
|
381
|
+
var t, n;
|
|
382
|
+
(n = (t = y.value) == null ? void 0 : t.updatePopper) == null || n.call(t);
|
|
377
383
|
}, Ye = () => {
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
t.inputValue.length > 0 && !c.value && (c.value = !0), fe(t.inputValue);
|
|
382
|
-
}, Je = (l) => {
|
|
383
|
-
if (t.inputValue = l.target.value, e.remote)
|
|
384
|
+
l.inputValue.length > 0 && !c.value && (c.value = !0), fe(l.inputValue);
|
|
385
|
+
}, Ze = (t) => {
|
|
386
|
+
if (l.inputValue = t.target.value, e.remote)
|
|
384
387
|
_e();
|
|
385
388
|
else
|
|
386
|
-
return
|
|
387
|
-
}, _e =
|
|
388
|
-
|
|
389
|
-
},
|
|
390
|
-
|
|
391
|
-
},
|
|
392
|
-
const r =
|
|
389
|
+
return Ye();
|
|
390
|
+
}, _e = Ul(() => {
|
|
391
|
+
Ye();
|
|
392
|
+
}, Dt.value), ae = (t) => {
|
|
393
|
+
le(e.modelValue, t) || o(Fe, t);
|
|
394
|
+
}, Kt = (t) => en(t, (n) => {
|
|
395
|
+
const r = l.cachedOptions.get(n);
|
|
393
396
|
return r && !r.disabled && !r.states.groupDisabled;
|
|
394
|
-
}),
|
|
395
|
-
if (e.multiple &&
|
|
396
|
-
const n =
|
|
397
|
+
}), Ht = (t) => {
|
|
398
|
+
if (e.multiple && t.code !== bl.delete && t.target.value.length <= 0) {
|
|
399
|
+
const n = J(e.modelValue).slice(), r = Kt(n);
|
|
397
400
|
if (r < 0)
|
|
398
401
|
return;
|
|
399
402
|
const E = n[r];
|
|
400
403
|
n.splice(r, 1), o(x, n), ae(n), o("remove-tag", E);
|
|
401
404
|
}
|
|
402
|
-
},
|
|
403
|
-
const r =
|
|
405
|
+
}, Gt = (t, n) => {
|
|
406
|
+
const r = l.selected.indexOf(n);
|
|
404
407
|
if (r > -1 && !ne.value) {
|
|
405
|
-
const E =
|
|
408
|
+
const E = J(e.modelValue).slice();
|
|
406
409
|
E.splice(r, 1), o(x, E), ae(E), o("remove-tag", n.value);
|
|
407
410
|
}
|
|
408
|
-
|
|
409
|
-
}, xe = (
|
|
410
|
-
|
|
411
|
+
t.stopPropagation(), be();
|
|
412
|
+
}, xe = (t) => {
|
|
413
|
+
t.stopPropagation();
|
|
411
414
|
const n = e.multiple ? [] : Ke.value;
|
|
412
415
|
if (e.multiple)
|
|
413
|
-
for (const r of
|
|
416
|
+
for (const r of l.selected)
|
|
414
417
|
r.isDisabled && n.push(r.value);
|
|
415
|
-
o(x, n), ae(n),
|
|
416
|
-
},
|
|
418
|
+
o(x, n), ae(n), l.hoveringIndex = -1, c.value = !1, o("clear"), be();
|
|
419
|
+
}, et = (t) => {
|
|
417
420
|
var n;
|
|
418
421
|
if (e.multiple) {
|
|
419
|
-
const r =
|
|
420
|
-
E > -1 ? r.splice(E, 1) : (e.multipleLimit <= 0 || r.length < e.multipleLimit) && r.push(
|
|
422
|
+
const r = J((n = e.modelValue) != null ? n : []).slice(), E = tt(r, t);
|
|
423
|
+
E > -1 ? r.splice(E, 1) : (e.multipleLimit <= 0 || r.length < e.multipleLimit) && r.push(t.value), o(x, r), ae(r), t.created && fe(""), e.filterable && !e.reserveKeyword && (l.inputValue = "");
|
|
421
424
|
} else
|
|
422
|
-
!
|
|
423
|
-
|
|
424
|
-
|
|
425
|
+
!le(e.modelValue, t.value) && o(x, t.value), ae(t.value), c.value = !1;
|
|
426
|
+
be(), !c.value && Q(() => {
|
|
427
|
+
me(t);
|
|
425
428
|
});
|
|
426
|
-
},
|
|
427
|
-
var n, r, E, N,
|
|
428
|
-
const K = j(
|
|
429
|
+
}, tt = (t, n) => Oe(n) ? -1 : U(n.value) ? t.findIndex((r) => le(z(r, e.valueKey), he(n))) : t.indexOf(n.value), me = (t) => {
|
|
430
|
+
var n, r, E, N, te;
|
|
431
|
+
const K = j(t) ? t[0] : t;
|
|
429
432
|
let ye = null;
|
|
430
433
|
if (K != null && K.value) {
|
|
431
|
-
const
|
|
432
|
-
|
|
434
|
+
const Z = D.value.filter((sl) => sl.value === K.value);
|
|
435
|
+
Z.length > 0 && (ye = Z[0].$el);
|
|
433
436
|
}
|
|
434
437
|
if (S.value && ye) {
|
|
435
|
-
const
|
|
436
|
-
|
|
438
|
+
const Z = (N = (E = (r = (n = S.value) == null ? void 0 : n.popperRef) == null ? void 0 : r.contentRef) == null ? void 0 : E.querySelector) == null ? void 0 : N.call(E, `.${d.be("dropdown", "wrap")}`);
|
|
439
|
+
Z && Hl(Z, ye);
|
|
437
440
|
}
|
|
438
|
-
(
|
|
439
|
-
},
|
|
440
|
-
|
|
441
|
-
},
|
|
442
|
-
|
|
443
|
-
},
|
|
444
|
-
var
|
|
445
|
-
return (n = (
|
|
446
|
-
}),
|
|
447
|
-
|
|
448
|
-
var
|
|
449
|
-
(
|
|
441
|
+
(te = g.value) == null || te.handleScroll();
|
|
442
|
+
}, Ut = (t) => {
|
|
443
|
+
l.options.set(t.value, t), l.cachedOptions.set(t.value, t);
|
|
444
|
+
}, jt = (t, n) => {
|
|
445
|
+
l.options.get(t) === n && l.options.delete(t);
|
|
446
|
+
}, qt = u(() => {
|
|
447
|
+
var t, n;
|
|
448
|
+
return (n = (t = S.value) == null ? void 0 : t.popperRef) == null ? void 0 : n.contentRef;
|
|
449
|
+
}), Qt = () => {
|
|
450
|
+
l.isBeforeHide = !1, Q(() => {
|
|
451
|
+
var t;
|
|
452
|
+
(t = g.value) == null || t.update(), me(l.selected);
|
|
450
453
|
});
|
|
451
|
-
},
|
|
452
|
-
var
|
|
453
|
-
(
|
|
454
|
-
},
|
|
455
|
-
var
|
|
454
|
+
}, be = () => {
|
|
455
|
+
var t;
|
|
456
|
+
(t = m.value) == null || t.focus();
|
|
457
|
+
}, Jt = () => {
|
|
458
|
+
var t;
|
|
456
459
|
if (c.value) {
|
|
457
460
|
c.value = !1, Q(() => {
|
|
458
461
|
var n;
|
|
459
|
-
return (n =
|
|
462
|
+
return (n = m.value) == null ? void 0 : n.blur();
|
|
460
463
|
});
|
|
461
464
|
return;
|
|
462
465
|
}
|
|
463
|
-
(
|
|
464
|
-
},
|
|
465
|
-
xe(
|
|
466
|
-
},
|
|
466
|
+
(t = m.value) == null || t.blur();
|
|
467
|
+
}, Xt = (t) => {
|
|
468
|
+
xe(t);
|
|
469
|
+
}, Yt = (t) => {
|
|
467
470
|
if (c.value = !1, Te.value) {
|
|
468
|
-
const n = new FocusEvent("blur",
|
|
469
|
-
Q(() =>
|
|
471
|
+
const n = new FocusEvent("blur", t);
|
|
472
|
+
Q(() => Vt(n));
|
|
470
473
|
}
|
|
471
|
-
},
|
|
472
|
-
|
|
473
|
-
},
|
|
474
|
-
ne.value || (
|
|
475
|
-
},
|
|
474
|
+
}, Zt = () => {
|
|
475
|
+
l.inputValue.length > 0 ? l.inputValue = "" : c.value = !1;
|
|
476
|
+
}, lt = () => {
|
|
477
|
+
ne.value || (ut && (l.inputHovering = !0), l.menuVisibleOnFocus ? l.menuVisibleOnFocus = !1 : c.value = !c.value);
|
|
478
|
+
}, _t = () => {
|
|
476
479
|
if (!c.value)
|
|
477
|
-
|
|
480
|
+
lt();
|
|
478
481
|
else {
|
|
479
|
-
const
|
|
480
|
-
|
|
482
|
+
const t = D.value[l.hoveringIndex];
|
|
483
|
+
t && !t.isDisabled && et(t);
|
|
481
484
|
}
|
|
482
|
-
}, he = (
|
|
485
|
+
}, he = (t) => U(t.value) ? z(t.value, e.valueKey) : t.value, xt = u(() => D.value.filter((t) => t.visible).every((t) => t.isDisabled)), el = u(() => e.multiple ? e.collapseTags ? l.selected.slice(0, e.maxCollapseTags) : l.selected : []), tl = u(() => e.multiple ? e.collapseTags ? l.selected.slice(e.maxCollapseTags) : [] : []), nt = (t) => {
|
|
483
486
|
if (!c.value) {
|
|
484
487
|
c.value = !0;
|
|
485
488
|
return;
|
|
486
489
|
}
|
|
487
|
-
if (!(
|
|
488
|
-
|
|
489
|
-
const n = D.value[
|
|
490
|
-
(n.isDisabled || !n.visible) &&
|
|
490
|
+
if (!(l.options.size === 0 || oe.value === 0 || He.value) && !xt.value) {
|
|
491
|
+
t === "next" ? (l.hoveringIndex++, l.hoveringIndex === l.options.size && (l.hoveringIndex = 0)) : t === "prev" && (l.hoveringIndex--, l.hoveringIndex < 0 && (l.hoveringIndex = l.options.size - 1));
|
|
492
|
+
const n = D.value[l.hoveringIndex];
|
|
493
|
+
(n.isDisabled || !n.visible) && nt(t), Q(() => me(V.value));
|
|
491
494
|
}
|
|
492
|
-
},
|
|
495
|
+
}, ll = () => {
|
|
493
496
|
if (!h.value)
|
|
494
497
|
return 0;
|
|
495
|
-
const
|
|
496
|
-
return Number.parseFloat(
|
|
497
|
-
},
|
|
498
|
-
const
|
|
499
|
-
return { maxWidth: `${R.value && e.maxCollapseTags === 1 ?
|
|
500
|
-
}),
|
|
501
|
-
o("popup-scroll",
|
|
498
|
+
const t = window.getComputedStyle(h.value);
|
|
499
|
+
return Number.parseFloat(t.gap || "6px");
|
|
500
|
+
}, nl = u(() => {
|
|
501
|
+
const t = ll(), n = e.filterable ? t + gt : 0;
|
|
502
|
+
return { maxWidth: `${R.value && e.maxCollapseTags === 1 ? l.selectionWidth - l.collapseItemWidth - t - n : l.selectionWidth - n}px` };
|
|
503
|
+
}), ol = u(() => ({ maxWidth: `${l.selectionWidth}px` })), al = (t) => {
|
|
504
|
+
o("popup-scroll", t);
|
|
502
505
|
};
|
|
503
|
-
ee(h,
|
|
506
|
+
ee(h, zt), ee(Ge, Re), ee(I, Xe), ee(R, At);
|
|
504
507
|
let ge;
|
|
505
|
-
return G(() => Qe.value, (
|
|
506
|
-
|
|
508
|
+
return G(() => Qe.value, (t) => {
|
|
509
|
+
t ? ge = ee(O, Re).stop : (ge == null || ge(), ge = void 0);
|
|
507
510
|
}), We(() => {
|
|
508
511
|
ve();
|
|
509
512
|
}), {
|
|
@@ -511,7 +514,7 @@ const fn = (e, o) => {
|
|
|
511
514
|
contentId: f,
|
|
512
515
|
nsSelect: d,
|
|
513
516
|
nsInput: p,
|
|
514
|
-
states:
|
|
517
|
+
states: l,
|
|
515
518
|
isFocused: Te,
|
|
516
519
|
expanded: c,
|
|
517
520
|
optionsArray: D,
|
|
@@ -519,54 +522,54 @@ const fn = (e, o) => {
|
|
|
519
522
|
selectSize: qe,
|
|
520
523
|
filteredOptionsCount: oe,
|
|
521
524
|
updateTooltip: Re,
|
|
522
|
-
updateTagTooltip:
|
|
525
|
+
updateTagTooltip: Xe,
|
|
523
526
|
debouncedOnInputChange: _e,
|
|
524
|
-
onInput:
|
|
525
|
-
deletePrevTag:
|
|
526
|
-
deleteTag:
|
|
527
|
+
onInput: Ze,
|
|
528
|
+
deletePrevTag: Ht,
|
|
529
|
+
deleteTag: Gt,
|
|
527
530
|
deleteSelected: xe,
|
|
528
|
-
handleOptionSelect:
|
|
529
|
-
scrollToOption:
|
|
531
|
+
handleOptionSelect: et,
|
|
532
|
+
scrollToOption: me,
|
|
530
533
|
hasModelValue: ke,
|
|
531
|
-
shouldShowPlaceholder:
|
|
532
|
-
currentPlaceholder:
|
|
533
|
-
mouseEnterEventName:
|
|
534
|
-
needStatusIcon:
|
|
535
|
-
showClearBtn:
|
|
534
|
+
shouldShowPlaceholder: Bt,
|
|
535
|
+
currentPlaceholder: Pt,
|
|
536
|
+
mouseEnterEventName: Wt,
|
|
537
|
+
needStatusIcon: Et,
|
|
538
|
+
showClearBtn: It,
|
|
536
539
|
iconComponent: Ue,
|
|
537
|
-
iconReverse:
|
|
540
|
+
iconReverse: Tt,
|
|
538
541
|
validateState: De,
|
|
539
|
-
validateIcon:
|
|
540
|
-
showNewOption:
|
|
542
|
+
validateIcon: kt,
|
|
543
|
+
showNewOption: Lt,
|
|
541
544
|
updateOptions: je,
|
|
542
|
-
collapseTagSize:
|
|
545
|
+
collapseTagSize: Nt,
|
|
543
546
|
setSelected: ve,
|
|
544
547
|
selectDisabled: ne,
|
|
545
|
-
emptyText:
|
|
546
|
-
handleCompositionStart:
|
|
547
|
-
handleCompositionUpdate:
|
|
548
|
-
handleCompositionEnd:
|
|
549
|
-
onOptionCreate:
|
|
550
|
-
onOptionDestroy:
|
|
551
|
-
handleMenuEnter:
|
|
552
|
-
focus:
|
|
553
|
-
blur:
|
|
554
|
-
handleClearClick:
|
|
555
|
-
handleClickOutside:
|
|
556
|
-
handleEsc:
|
|
557
|
-
toggleMenu:
|
|
558
|
-
selectOption:
|
|
548
|
+
emptyText: Rt,
|
|
549
|
+
handleCompositionStart: Ot,
|
|
550
|
+
handleCompositionUpdate: Ct,
|
|
551
|
+
handleCompositionEnd: wt,
|
|
552
|
+
onOptionCreate: Ut,
|
|
553
|
+
onOptionDestroy: jt,
|
|
554
|
+
handleMenuEnter: Qt,
|
|
555
|
+
focus: be,
|
|
556
|
+
blur: Jt,
|
|
557
|
+
handleClearClick: Xt,
|
|
558
|
+
handleClickOutside: Yt,
|
|
559
|
+
handleEsc: Zt,
|
|
560
|
+
toggleMenu: lt,
|
|
561
|
+
selectOption: _t,
|
|
559
562
|
getValueKey: he,
|
|
560
|
-
navigateOptions:
|
|
563
|
+
navigateOptions: nt,
|
|
561
564
|
dropdownMenuVisible: Qe,
|
|
562
|
-
showTagList:
|
|
563
|
-
collapseTagList:
|
|
564
|
-
popupScroll:
|
|
565
|
+
showTagList: el,
|
|
566
|
+
collapseTagList: tl,
|
|
567
|
+
popupScroll: al,
|
|
565
568
|
getOption: Me,
|
|
566
|
-
tagStyle:
|
|
567
|
-
collapseTagStyle:
|
|
568
|
-
popperRef:
|
|
569
|
-
inputRef:
|
|
569
|
+
tagStyle: nl,
|
|
570
|
+
collapseTagStyle: ol,
|
|
571
|
+
popperRef: qt,
|
|
572
|
+
inputRef: m,
|
|
570
573
|
tooltipRef: S,
|
|
571
574
|
tagTooltipRef: y,
|
|
572
575
|
prefixRef: s,
|
|
@@ -587,19 +590,19 @@ var vn = pe({
|
|
|
587
590
|
let f = [];
|
|
588
591
|
return () => {
|
|
589
592
|
var d, p;
|
|
590
|
-
const
|
|
593
|
+
const l = (d = o.default) == null ? void 0 : d.call(o), C = [];
|
|
591
594
|
function h(S) {
|
|
592
595
|
j(S) && S.forEach((y) => {
|
|
593
|
-
var
|
|
594
|
-
const I = (
|
|
595
|
-
I === "ElOptionGroup" ? h(!
|
|
596
|
+
var m, s, i, O;
|
|
597
|
+
const I = (m = (y == null ? void 0 : y.type) || {}) == null ? void 0 : m.name;
|
|
598
|
+
I === "ElOptionGroup" ? h(!Ml(y.children) && !j(y.children) && re((s = y.children) == null ? void 0 : s.default) ? (i = y.children) == null ? void 0 : i.default() : y.children) : I === "ElOption" ? C.push((O = y.props) == null ? void 0 : O.value) : j(y.children) && h(y.children);
|
|
596
599
|
});
|
|
597
600
|
}
|
|
598
|
-
return
|
|
601
|
+
return l.length && h((p = l[0]) == null ? void 0 : p.children), le(C, f) || (f = C, a && (a.states.optionValues = C)), l;
|
|
599
602
|
};
|
|
600
603
|
}
|
|
601
604
|
});
|
|
602
|
-
const
|
|
605
|
+
const mn = mt({
|
|
603
606
|
name: String,
|
|
604
607
|
id: String,
|
|
605
608
|
modelValue: {
|
|
@@ -617,7 +620,7 @@ const bn = ml({
|
|
|
617
620
|
default: "off"
|
|
618
621
|
},
|
|
619
622
|
automaticDropdown: Boolean,
|
|
620
|
-
size:
|
|
623
|
+
size: Fl,
|
|
621
624
|
effect: {
|
|
622
625
|
type: W(String),
|
|
623
626
|
default: "light"
|
|
@@ -671,22 +674,22 @@ const bn = ml({
|
|
|
671
674
|
type: Number,
|
|
672
675
|
default: 1
|
|
673
676
|
},
|
|
674
|
-
teleported:
|
|
677
|
+
teleported: it.teleported,
|
|
675
678
|
persistent: {
|
|
676
679
|
type: Boolean,
|
|
677
680
|
default: !0
|
|
678
681
|
},
|
|
679
682
|
clearIcon: {
|
|
680
|
-
type:
|
|
681
|
-
default:
|
|
683
|
+
type: dt,
|
|
684
|
+
default: wl
|
|
682
685
|
},
|
|
683
686
|
fitInputWidth: Boolean,
|
|
684
687
|
suffixIcon: {
|
|
685
|
-
type:
|
|
686
|
-
default:
|
|
688
|
+
type: dt,
|
|
689
|
+
default: Vl
|
|
687
690
|
},
|
|
688
|
-
tagType: { ...
|
|
689
|
-
tagEffect: { ...
|
|
691
|
+
tagType: { ...rt.type, default: "info" },
|
|
692
|
+
tagEffect: { ...rt.effect, default: "light" },
|
|
690
693
|
validateEvent: {
|
|
691
694
|
type: Boolean,
|
|
692
695
|
default: !0
|
|
@@ -702,7 +705,7 @@ const bn = ml({
|
|
|
702
705
|
},
|
|
703
706
|
placement: {
|
|
704
707
|
type: W(String),
|
|
705
|
-
values:
|
|
708
|
+
values: hl,
|
|
706
709
|
default: "bottom-start"
|
|
707
710
|
},
|
|
708
711
|
fallbackPlacements: {
|
|
@@ -713,19 +716,19 @@ const bn = ml({
|
|
|
713
716
|
type: [String, Number],
|
|
714
717
|
default: 0
|
|
715
718
|
},
|
|
716
|
-
appendTo:
|
|
719
|
+
appendTo: it.appendTo,
|
|
717
720
|
options: {
|
|
718
721
|
type: W(Array)
|
|
719
722
|
},
|
|
720
723
|
props: {
|
|
721
724
|
type: W(Object),
|
|
722
|
-
default: () =>
|
|
725
|
+
default: () => yt
|
|
723
726
|
},
|
|
724
|
-
...
|
|
725
|
-
...
|
|
727
|
+
...Ll,
|
|
728
|
+
...gl(["ariaLabel"])
|
|
726
729
|
});
|
|
727
|
-
x + "", Fe + "",
|
|
728
|
-
const
|
|
730
|
+
x + "", Fe + "", yl.scroll;
|
|
731
|
+
const bn = pe({
|
|
729
732
|
name: "ElOptionGroup",
|
|
730
733
|
componentName: "ElOptionGroup",
|
|
731
734
|
props: {
|
|
@@ -734,24 +737,24 @@ const mn = pe({
|
|
|
734
737
|
},
|
|
735
738
|
setup(e) {
|
|
736
739
|
const o = ce("select"), a = T(), f = Ve(), d = T([]);
|
|
737
|
-
|
|
740
|
+
vt(St, de({
|
|
738
741
|
...Be(e)
|
|
739
742
|
}));
|
|
740
|
-
const p = u(() => d.value.some((S) => S.visible === !0)),
|
|
743
|
+
const p = u(() => d.value.some((S) => S.visible === !0)), l = (S) => {
|
|
741
744
|
var y;
|
|
742
745
|
return S.type.name === "ElOption" && !!((y = S.component) != null && y.proxy);
|
|
743
746
|
}, C = (S) => {
|
|
744
|
-
const y =
|
|
747
|
+
const y = J(S), m = [];
|
|
745
748
|
return y.forEach((s) => {
|
|
746
749
|
var i;
|
|
747
|
-
|
|
748
|
-
}),
|
|
750
|
+
dl(s) && (l(s) ? m.push(s.component.proxy) : j(s.children) && s.children.length ? m.push(...C(s.children)) : (i = s.component) != null && i.subTree && m.push(...C(s.component.subTree)));
|
|
751
|
+
}), m;
|
|
749
752
|
}, h = () => {
|
|
750
753
|
d.value = C(f.subTree);
|
|
751
754
|
};
|
|
752
755
|
return We(() => {
|
|
753
756
|
h();
|
|
754
|
-
}),
|
|
757
|
+
}), zl(a, h, {
|
|
755
758
|
attributes: !0,
|
|
756
759
|
subtree: !0,
|
|
757
760
|
childList: !0
|
|
@@ -765,14 +768,14 @@ const mn = pe({
|
|
|
765
768
|
function hn(e, o, a, f, d, p) {
|
|
766
769
|
return ue((v(), w("ul", {
|
|
767
770
|
ref: "groupRef",
|
|
768
|
-
class:
|
|
771
|
+
class: b(e.ns.be("group", "wrap"))
|
|
769
772
|
}, [
|
|
770
773
|
k("li", {
|
|
771
|
-
class:
|
|
774
|
+
class: b(e.ns.be("group", "title"))
|
|
772
775
|
}, H(e.label), 3),
|
|
773
776
|
k("li", null, [
|
|
774
777
|
k("ul", {
|
|
775
|
-
class:
|
|
778
|
+
class: b(e.ns.b("group"))
|
|
776
779
|
}, [
|
|
777
780
|
M(e.$slots, "default")
|
|
778
781
|
], 2)
|
|
@@ -781,22 +784,22 @@ function hn(e, o, a, f, d, p) {
|
|
|
781
784
|
[Pe, e.visible]
|
|
782
785
|
]);
|
|
783
786
|
}
|
|
784
|
-
var Ae = /* @__PURE__ */ Ee(
|
|
785
|
-
const
|
|
786
|
-
name:
|
|
787
|
-
componentName:
|
|
787
|
+
var Ae = /* @__PURE__ */ Ee(bn, [["render", hn], ["__file", "option-group.vue"]]);
|
|
788
|
+
const pt = "ElSelect", gn = pe({
|
|
789
|
+
name: pt,
|
|
790
|
+
componentName: pt,
|
|
788
791
|
components: {
|
|
789
792
|
ElSelectMenu: pn,
|
|
790
793
|
ElOption: ze,
|
|
791
794
|
ElOptions: vn,
|
|
792
795
|
ElOptionGroup: Ae,
|
|
793
|
-
ElTag:
|
|
794
|
-
ElScrollbar:
|
|
795
|
-
ElTooltip:
|
|
796
|
-
ElIcon:
|
|
796
|
+
ElTag: Cl,
|
|
797
|
+
ElScrollbar: Sl,
|
|
798
|
+
ElTooltip: Ol,
|
|
799
|
+
ElIcon: El
|
|
797
800
|
},
|
|
798
|
-
directives: { ClickOutside:
|
|
799
|
-
props:
|
|
801
|
+
directives: { ClickOutside: ql },
|
|
802
|
+
props: mn,
|
|
800
803
|
emits: [
|
|
801
804
|
x,
|
|
802
805
|
Fe,
|
|
@@ -818,23 +821,23 @@ const pl = "ElSelect", gn = pe({
|
|
|
818
821
|
}), p = de({
|
|
819
822
|
...Be(e),
|
|
820
823
|
modelValue: d
|
|
821
|
-
}),
|
|
824
|
+
}), l = fn(p, o), { calculatorRef: C, inputStyle: h } = ln(), { getLabel: S, getValue: y, getOptions: m, getDisabled: s } = nn(e), i = (g) => ({
|
|
822
825
|
label: S(g),
|
|
823
826
|
value: y(g),
|
|
824
827
|
disabled: s(g)
|
|
825
828
|
}), O = (g) => g.reduce((c, V) => (c.push(V), V.children && V.children.length > 0 && c.push(...O(V.children)), c), []), I = (g) => {
|
|
826
|
-
|
|
827
|
-
var
|
|
829
|
+
Ql(g || []).forEach((V) => {
|
|
830
|
+
var X;
|
|
828
831
|
if (U(V) && (V.type.name === "ElOption" || V.type.name === "ElTree")) {
|
|
829
832
|
const B = V.type.name;
|
|
830
833
|
if (B === "ElTree") {
|
|
831
|
-
const A = ((
|
|
832
|
-
O(A).forEach((
|
|
833
|
-
|
|
834
|
+
const A = ((X = V.props) == null ? void 0 : X.data) || [];
|
|
835
|
+
O(A).forEach((Y) => {
|
|
836
|
+
Y.currentLabel = Y.label || (U(Y.value) ? "" : Y.value), l.onOptionCreate(Y);
|
|
834
837
|
});
|
|
835
838
|
} else if (B === "ElOption") {
|
|
836
839
|
const A = { ...V.props };
|
|
837
|
-
A.currentLabel = A.label || (U(A.value) ? "" : A.value),
|
|
840
|
+
A.currentLabel = A.label || (U(A.value) ? "" : A.value), l.onOptionCreate(A);
|
|
838
841
|
}
|
|
839
842
|
}
|
|
840
843
|
});
|
|
@@ -846,40 +849,40 @@ const pl = "ElSelect", gn = pe({
|
|
|
846
849
|
e.persistent || I(g);
|
|
847
850
|
}, {
|
|
848
851
|
immediate: !0
|
|
849
|
-
}),
|
|
852
|
+
}), vt(Ie, de({
|
|
850
853
|
props: p,
|
|
851
|
-
states:
|
|
852
|
-
selectRef:
|
|
853
|
-
optionsArray:
|
|
854
|
-
setSelected:
|
|
855
|
-
handleOptionSelect:
|
|
856
|
-
onOptionCreate:
|
|
857
|
-
onOptionDestroy:
|
|
854
|
+
states: l.states,
|
|
855
|
+
selectRef: l.selectRef,
|
|
856
|
+
optionsArray: l.optionsArray,
|
|
857
|
+
setSelected: l.setSelected,
|
|
858
|
+
handleOptionSelect: l.handleOptionSelect,
|
|
859
|
+
onOptionCreate: l.onOptionCreate,
|
|
860
|
+
onOptionDestroy: l.onOptionDestroy
|
|
858
861
|
}));
|
|
859
|
-
const R = u(() => e.multiple ?
|
|
860
|
-
return
|
|
862
|
+
const R = u(() => e.multiple ? l.states.selected.map((g) => g.currentLabel) : l.states.selectedLabel);
|
|
863
|
+
return ft(() => {
|
|
861
864
|
f.appContext.config.warnHandler = void 0;
|
|
862
865
|
}), {
|
|
863
|
-
...
|
|
866
|
+
...l,
|
|
864
867
|
modelValue: d,
|
|
865
868
|
selectedLabel: R,
|
|
866
869
|
calculatorRef: C,
|
|
867
870
|
inputStyle: h,
|
|
868
871
|
getLabel: S,
|
|
869
872
|
getValue: y,
|
|
870
|
-
getOptions:
|
|
873
|
+
getOptions: m,
|
|
871
874
|
getDisabled: s,
|
|
872
875
|
getOptionProps: i
|
|
873
876
|
};
|
|
874
877
|
}
|
|
875
878
|
});
|
|
876
879
|
function yn(e, o) {
|
|
877
|
-
const a = q("el-tag"), f = q("el-tooltip"), d = q("el-icon"), p = q("el-option"),
|
|
880
|
+
const a = q("el-tag"), f = q("el-tooltip"), d = q("el-icon"), p = q("el-option"), l = q("el-option-group"), C = q("el-options"), h = q("el-scrollbar"), S = q("el-select-menu"), y = cl("click-outside");
|
|
878
881
|
return ue((v(), w("div", {
|
|
879
882
|
ref: "selectRef",
|
|
880
|
-
class:
|
|
881
|
-
[
|
|
882
|
-
onMouseleave: (
|
|
883
|
+
class: b([e.nsSelect.b(), e.nsSelect.m(e.selectSize)]),
|
|
884
|
+
[pl(e.mouseEnterEventName)]: (m) => e.states.inputHovering = !0,
|
|
885
|
+
onMouseleave: (m) => e.states.inputHovering = !1
|
|
883
886
|
}, [
|
|
884
887
|
_(f, {
|
|
885
888
|
ref: "tooltipRef",
|
|
@@ -901,14 +904,14 @@ function yn(e, o) {
|
|
|
901
904
|
"show-arrow": e.showArrow,
|
|
902
905
|
offset: e.offset,
|
|
903
906
|
onBeforeShow: e.handleMenuEnter,
|
|
904
|
-
onHide: (
|
|
907
|
+
onHide: (m) => e.states.isBeforeHide = !1
|
|
905
908
|
}, {
|
|
906
909
|
default: $(() => {
|
|
907
|
-
var
|
|
910
|
+
var m;
|
|
908
911
|
return [
|
|
909
912
|
k("div", {
|
|
910
913
|
ref: "wrapperRef",
|
|
911
|
-
class:
|
|
914
|
+
class: b([
|
|
912
915
|
e.nsSelect.e("wrapper"),
|
|
913
916
|
e.nsSelect.is("focused", e.isFocused),
|
|
914
917
|
e.nsSelect.is("hovering", e.states.inputHovering),
|
|
@@ -920,13 +923,13 @@ function yn(e, o) {
|
|
|
920
923
|
e.$slots.prefix ? (v(), w("div", {
|
|
921
924
|
key: 0,
|
|
922
925
|
ref: "prefixRef",
|
|
923
|
-
class:
|
|
926
|
+
class: b(e.nsSelect.e("prefix"))
|
|
924
927
|
}, [
|
|
925
928
|
M(e.$slots, "prefix")
|
|
926
929
|
], 2)) : L("v-if", !0),
|
|
927
930
|
k("div", {
|
|
928
931
|
ref: "selectionRef",
|
|
929
|
-
class:
|
|
932
|
+
class: b([
|
|
930
933
|
e.nsSelect.e("selection"),
|
|
931
934
|
e.nsSelect.is("near", e.multiple && !e.$slots.prefix && !!e.states.selected.length)
|
|
932
935
|
])
|
|
@@ -939,7 +942,7 @@ function yn(e, o) {
|
|
|
939
942
|
}, () => [
|
|
940
943
|
(v(!0), w(se, null, Se(e.showTagList, (s) => (v(), w("div", {
|
|
941
944
|
key: e.getValueKey(s),
|
|
942
|
-
class:
|
|
945
|
+
class: b(e.nsSelect.e("selected-item"))
|
|
943
946
|
}, [
|
|
944
947
|
_(a, {
|
|
945
948
|
closable: !e.selectDisabled && !s.isDisabled,
|
|
@@ -952,14 +955,14 @@ function yn(e, o) {
|
|
|
952
955
|
}, {
|
|
953
956
|
default: $(() => [
|
|
954
957
|
k("span", {
|
|
955
|
-
class:
|
|
958
|
+
class: b(e.nsSelect.e("tags-text"))
|
|
956
959
|
}, [
|
|
957
960
|
M(e.$slots, "label", {
|
|
958
961
|
index: s.index,
|
|
959
962
|
label: s.currentLabel,
|
|
960
963
|
value: s.value
|
|
961
964
|
}, () => [
|
|
962
|
-
|
|
965
|
+
ot(H(s.currentLabel), 1)
|
|
963
966
|
])
|
|
964
967
|
], 2)
|
|
965
968
|
]),
|
|
@@ -980,7 +983,7 @@ function yn(e, o) {
|
|
|
980
983
|
default: $(() => [
|
|
981
984
|
k("div", {
|
|
982
985
|
ref: "collapseItemRef",
|
|
983
|
-
class:
|
|
986
|
+
class: b(e.nsSelect.e("selected-item"))
|
|
984
987
|
}, [
|
|
985
988
|
_(a, {
|
|
986
989
|
closable: !1,
|
|
@@ -992,7 +995,7 @@ function yn(e, o) {
|
|
|
992
995
|
}, {
|
|
993
996
|
default: $(() => [
|
|
994
997
|
k("span", {
|
|
995
|
-
class:
|
|
998
|
+
class: b(e.nsSelect.e("tags-text"))
|
|
996
999
|
}, " + " + H(e.states.selected.length - e.maxCollapseTags), 3)
|
|
997
1000
|
]),
|
|
998
1001
|
_: 1
|
|
@@ -1002,11 +1005,11 @@ function yn(e, o) {
|
|
|
1002
1005
|
content: $(() => [
|
|
1003
1006
|
k("div", {
|
|
1004
1007
|
ref: "tagMenuRef",
|
|
1005
|
-
class:
|
|
1008
|
+
class: b(e.nsSelect.e("selection"))
|
|
1006
1009
|
}, [
|
|
1007
1010
|
(v(!0), w(se, null, Se(e.collapseTagList, (s) => (v(), w("div", {
|
|
1008
1011
|
key: e.getValueKey(s),
|
|
1009
|
-
class:
|
|
1012
|
+
class: b(e.nsSelect.e("selected-item"))
|
|
1010
1013
|
}, [
|
|
1011
1014
|
_(a, {
|
|
1012
1015
|
class: "in-tooltip",
|
|
@@ -1019,14 +1022,14 @@ function yn(e, o) {
|
|
|
1019
1022
|
}, {
|
|
1020
1023
|
default: $(() => [
|
|
1021
1024
|
k("span", {
|
|
1022
|
-
class:
|
|
1025
|
+
class: b(e.nsSelect.e("tags-text"))
|
|
1023
1026
|
}, [
|
|
1024
1027
|
M(e.$slots, "label", {
|
|
1025
1028
|
index: s.index,
|
|
1026
1029
|
label: s.currentLabel,
|
|
1027
1030
|
value: s.value
|
|
1028
1031
|
}, () => [
|
|
1029
|
-
|
|
1032
|
+
ot(H(s.currentLabel), 1)
|
|
1030
1033
|
])
|
|
1031
1034
|
], 2)
|
|
1032
1035
|
]),
|
|
@@ -1039,7 +1042,7 @@ function yn(e, o) {
|
|
|
1039
1042
|
}, 8, ["disabled", "effect", "popper-class", "popper-style", "teleported"])) : L("v-if", !0)
|
|
1040
1043
|
]) : L("v-if", !0),
|
|
1041
1044
|
k("div", {
|
|
1042
|
-
class:
|
|
1045
|
+
class: b([
|
|
1043
1046
|
e.nsSelect.e("selected-item"),
|
|
1044
1047
|
e.nsSelect.e("input-wrapper"),
|
|
1045
1048
|
e.nsSelect.is("hidden", !e.filterable)
|
|
@@ -1051,7 +1054,7 @@ function yn(e, o) {
|
|
|
1051
1054
|
"onUpdate:modelValue": (s) => e.states.inputValue = s,
|
|
1052
1055
|
type: "text",
|
|
1053
1056
|
name: e.name,
|
|
1054
|
-
class:
|
|
1057
|
+
class: b([e.nsSelect.e("input"), e.nsSelect.is(e.selectSize)]),
|
|
1055
1058
|
disabled: e.selectDisabled,
|
|
1056
1059
|
autocomplete: e.autocomplete,
|
|
1057
1060
|
style: Ce(e.inputStyle),
|
|
@@ -1059,7 +1062,7 @@ function yn(e, o) {
|
|
|
1059
1062
|
role: "combobox",
|
|
1060
1063
|
readonly: !e.filterable,
|
|
1061
1064
|
spellcheck: "false",
|
|
1062
|
-
"aria-activedescendant": ((
|
|
1065
|
+
"aria-activedescendant": ((m = e.hoverOption) == null ? void 0 : m.id) || "",
|
|
1063
1066
|
"aria-controls": e.contentId,
|
|
1064
1067
|
"aria-expanded": e.dropdownMenuVisible,
|
|
1065
1068
|
"aria-label": e.ariaLabel,
|
|
@@ -1078,19 +1081,19 @@ function yn(e, o) {
|
|
|
1078
1081
|
onInput: e.onInput,
|
|
1079
1082
|
onClick: F(e.toggleMenu, ["stop"])
|
|
1080
1083
|
}, null, 46, ["id", "onUpdate:modelValue", "name", "disabled", "autocomplete", "tabindex", "readonly", "aria-activedescendant", "aria-controls", "aria-expanded", "aria-label", "onKeydown", "onCompositionstart", "onCompositionupdate", "onCompositionend", "onInput", "onClick"]), [
|
|
1081
|
-
[
|
|
1084
|
+
[fl, e.states.inputValue]
|
|
1082
1085
|
]),
|
|
1083
1086
|
e.filterable ? (v(), w("span", {
|
|
1084
1087
|
key: 0,
|
|
1085
1088
|
ref: "calculatorRef",
|
|
1086
1089
|
"aria-hidden": "true",
|
|
1087
|
-
class:
|
|
1090
|
+
class: b(e.nsSelect.e("input-calculator")),
|
|
1088
1091
|
textContent: H(e.states.inputValue)
|
|
1089
1092
|
}, null, 10, ["textContent"])) : L("v-if", !0)
|
|
1090
1093
|
], 2),
|
|
1091
1094
|
e.shouldShowPlaceholder ? (v(), w("div", {
|
|
1092
1095
|
key: 1,
|
|
1093
|
-
class:
|
|
1096
|
+
class: b([
|
|
1094
1097
|
e.nsSelect.e("selected-item"),
|
|
1095
1098
|
e.nsSelect.e("placeholder"),
|
|
1096
1099
|
e.nsSelect.is("transparent", !e.hasModelValue || e.expanded && !e.states.inputValue)
|
|
@@ -1108,11 +1111,11 @@ function yn(e, o) {
|
|
|
1108
1111
|
], 2),
|
|
1109
1112
|
k("div", {
|
|
1110
1113
|
ref: "suffixRef",
|
|
1111
|
-
class:
|
|
1114
|
+
class: b(e.nsSelect.e("suffix"))
|
|
1112
1115
|
}, [
|
|
1113
1116
|
e.iconComponent && !e.showClearBtn ? (v(), P(d, {
|
|
1114
1117
|
key: 0,
|
|
1115
|
-
class:
|
|
1118
|
+
class: b([e.nsSelect.e("caret"), e.nsSelect.e("icon"), e.iconReverse])
|
|
1116
1119
|
}, {
|
|
1117
1120
|
default: $(() => [
|
|
1118
1121
|
(v(), P(Le(e.iconComponent)))
|
|
@@ -1121,7 +1124,7 @@ function yn(e, o) {
|
|
|
1121
1124
|
}, 8, ["class"])) : L("v-if", !0),
|
|
1122
1125
|
e.showClearBtn && e.clearIcon ? (v(), P(d, {
|
|
1123
1126
|
key: 1,
|
|
1124
|
-
class:
|
|
1127
|
+
class: b([
|
|
1125
1128
|
e.nsSelect.e("caret"),
|
|
1126
1129
|
e.nsSelect.e("icon"),
|
|
1127
1130
|
e.nsSelect.e("clear")
|
|
@@ -1135,7 +1138,7 @@ function yn(e, o) {
|
|
|
1135
1138
|
}, 8, ["class", "onClick"])) : L("v-if", !0),
|
|
1136
1139
|
e.validateState && e.validateIcon && e.needStatusIcon ? (v(), P(d, {
|
|
1137
1140
|
key: 2,
|
|
1138
|
-
class:
|
|
1141
|
+
class: b([
|
|
1139
1142
|
e.nsInput.e("icon"),
|
|
1140
1143
|
e.nsInput.e("validateIcon"),
|
|
1141
1144
|
e.nsInput.is("loading", e.validateState === "validating")
|
|
@@ -1155,7 +1158,7 @@ function yn(e, o) {
|
|
|
1155
1158
|
default: $(() => [
|
|
1156
1159
|
e.$slots.header ? (v(), w("div", {
|
|
1157
1160
|
key: 0,
|
|
1158
|
-
class:
|
|
1161
|
+
class: b(e.nsSelect.be("dropdown", "header")),
|
|
1159
1162
|
onClick: F(() => {
|
|
1160
1163
|
}, ["stop"])
|
|
1161
1164
|
}, [
|
|
@@ -1167,7 +1170,7 @@ function yn(e, o) {
|
|
|
1167
1170
|
tag: "ul",
|
|
1168
1171
|
"wrap-class": e.nsSelect.be("dropdown", "wrap"),
|
|
1169
1172
|
"view-class": e.nsSelect.be("dropdown", "list"),
|
|
1170
|
-
class:
|
|
1173
|
+
class: b([e.nsSelect.is("empty", e.filteredOptionsCount === 0)]),
|
|
1171
1174
|
role: "listbox",
|
|
1172
1175
|
"aria-label": e.ariaLabel,
|
|
1173
1176
|
"aria-orientation": "vertical",
|
|
@@ -1182,21 +1185,21 @@ function yn(e, o) {
|
|
|
1182
1185
|
_(C, null, {
|
|
1183
1186
|
default: $(() => [
|
|
1184
1187
|
M(e.$slots, "default", {}, () => [
|
|
1185
|
-
(v(!0), w(se, null, Se(e.options, (
|
|
1188
|
+
(v(!0), w(se, null, Se(e.options, (m, s) => {
|
|
1186
1189
|
var i;
|
|
1187
1190
|
return v(), w(se, { key: s }, [
|
|
1188
|
-
(i = e.getOptions(
|
|
1191
|
+
(i = e.getOptions(m)) != null && i.length ? (v(), P(l, {
|
|
1189
1192
|
key: 0,
|
|
1190
|
-
label: e.getLabel(
|
|
1191
|
-
disabled: e.getDisabled(
|
|
1193
|
+
label: e.getLabel(m),
|
|
1194
|
+
disabled: e.getDisabled(m)
|
|
1192
1195
|
}, {
|
|
1193
1196
|
default: $(() => [
|
|
1194
|
-
(v(!0), w(se, null, Se(e.getOptions(
|
|
1197
|
+
(v(!0), w(se, null, Se(e.getOptions(m), (O) => (v(), P(p, at({
|
|
1195
1198
|
key: e.getValue(O)
|
|
1196
1199
|
}, e.getOptionProps(O)), null, 16))), 128))
|
|
1197
1200
|
]),
|
|
1198
1201
|
_: 2
|
|
1199
|
-
}, 1032, ["label", "disabled"])) : (v(), P(p,
|
|
1202
|
+
}, 1032, ["label", "disabled"])) : (v(), P(p, vl(at({ key: 1 }, e.getOptionProps(m))), null, 16))
|
|
1200
1203
|
], 64);
|
|
1201
1204
|
}), 128))
|
|
1202
1205
|
])
|
|
@@ -1210,12 +1213,12 @@ function yn(e, o) {
|
|
|
1210
1213
|
]),
|
|
1211
1214
|
e.$slots.loading && e.loading ? (v(), w("div", {
|
|
1212
1215
|
key: 1,
|
|
1213
|
-
class:
|
|
1216
|
+
class: b(e.nsSelect.be("dropdown", "loading"))
|
|
1214
1217
|
}, [
|
|
1215
1218
|
M(e.$slots, "loading")
|
|
1216
1219
|
], 2)) : e.loading || e.filteredOptionsCount === 0 ? (v(), w("div", {
|
|
1217
1220
|
key: 2,
|
|
1218
|
-
class:
|
|
1221
|
+
class: b(e.nsSelect.be("dropdown", "empty"))
|
|
1219
1222
|
}, [
|
|
1220
1223
|
M(e.$slots, "empty", {}, () => [
|
|
1221
1224
|
k("span", null, H(e.emptyText), 1)
|
|
@@ -1223,7 +1226,7 @@ function yn(e, o) {
|
|
|
1223
1226
|
], 2)) : L("v-if", !0),
|
|
1224
1227
|
e.$slots.footer ? (v(), w("div", {
|
|
1225
1228
|
key: 3,
|
|
1226
|
-
class:
|
|
1229
|
+
class: b(e.nsSelect.be("dropdown", "footer")),
|
|
1227
1230
|
onClick: F(() => {
|
|
1228
1231
|
}, ["stop"])
|
|
1229
1232
|
}, [
|
|
@@ -1240,12 +1243,12 @@ function yn(e, o) {
|
|
|
1240
1243
|
]);
|
|
1241
1244
|
}
|
|
1242
1245
|
var Sn = /* @__PURE__ */ Ee(gn, [["render", yn], ["__file", "select.vue"]]);
|
|
1243
|
-
const
|
|
1246
|
+
const Bn = Rl(Sn, {
|
|
1244
1247
|
Option: ze,
|
|
1245
1248
|
OptionGroup: Ae
|
|
1246
|
-
}),
|
|
1247
|
-
|
|
1249
|
+
}), Pn = bt(ze);
|
|
1250
|
+
bt(Ae);
|
|
1248
1251
|
export {
|
|
1249
|
-
|
|
1250
|
-
|
|
1252
|
+
Pn as E,
|
|
1253
|
+
Bn as a
|
|
1251
1254
|
};
|