@pantograph/vue 0.32.6 → 0.32.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/dist/ColorPicker/index.js +2 -2
  2. package/dist/ColorPicker/index.umd.cjs +1 -1
  3. package/dist/{ColorPicker.vue_vue_type_style_index_0_lang-ngeRTae-.js → ColorPicker.vue_vue_type_style_index_0_lang-DvAxADqR.js} +1 -1
  4. package/dist/{ColorPicker.vue_vue_type_style_index_0_lang-BrT753B_.js → ColorPicker.vue_vue_type_style_index_0_lang-gWF4xfyP.js} +1 -1
  5. package/dist/ColorSwatchGroup/index.js +1 -1
  6. package/dist/ColorSwatchGroup/index.umd.cjs +1 -1
  7. package/dist/{ColorSwatchGroup.vue_vue_type_style_index_0_lang-_pCAmZ53.js → ColorSwatchGroup.vue_vue_type_style_index_0_lang-CnQvvL-b.js} +1 -1
  8. package/dist/{ColorSwatchGroup.vue_vue_type_style_index_0_lang-B4PdDPjL.js → ColorSwatchGroup.vue_vue_type_style_index_0_lang-D8rV769l.js} +1 -1
  9. package/dist/Combobox/Combobox.d.ts +3 -0
  10. package/dist/Combobox/context.d.ts +1 -0
  11. package/dist/Combobox/index.js +555 -542
  12. package/dist/Combobox/index.umd.cjs +1 -1
  13. package/dist/Comment/CommentMention.d.ts +8 -2
  14. package/dist/Comment/index.js +1 -0
  15. package/dist/Comment/index.umd.cjs +1 -1
  16. package/dist/Dialog/index.js +1 -1
  17. package/dist/Dialog/index.umd.cjs +1 -1
  18. package/dist/Drawer/index.js +9 -9
  19. package/dist/Drawer/index.umd.cjs +1 -1
  20. package/dist/GOPicker/index.js +1 -1
  21. package/dist/GOPicker/index.umd.cjs +1 -1
  22. package/dist/HoverCard/index.js +3 -2
  23. package/dist/HoverCard/index.umd.cjs +1 -1
  24. package/dist/Modal/index.js +10 -10
  25. package/dist/Modal/index.umd.cjs +1 -1
  26. package/dist/Popover/index.js +3 -2
  27. package/dist/Popover/index.umd.cjs +1 -1
  28. package/dist/Popover/type.d.ts +5 -0
  29. package/dist/Select/index.js +2 -2
  30. package/dist/Select/index.umd.cjs +1 -1
  31. package/dist/{Select.vue_vue_type_style_index_0_lang-BmCg9S_L.js → Select.vue_vue_type_style_index_0_lang-BDpLxikv.js} +1 -1
  32. package/dist/{Select.vue_vue_type_style_index_0_lang-BLHjk2Iy.js → Select.vue_vue_type_style_index_0_lang-Cdkv9Op4.js} +1 -1
  33. package/dist/Tree/Tree.model.d.ts +6 -0
  34. package/dist/Tree/index.js +1 -1
  35. package/dist/Tree/index.umd.cjs +1 -1
  36. package/dist/{index-BuEiTBIH.js → index-BxsIulsm.js} +73 -68
  37. package/dist/index-DUdWKbz1.js +1 -0
  38. package/dist/index.js +5 -5
  39. package/dist/index.umd.cjs +1 -1
  40. package/dist/style/index.css +1 -1
  41. package/dist/use/index.js +6 -6
  42. package/dist/use/index.umd.cjs +1 -1
  43. package/dist/utils-gUPbDQWf.js +1 -0
  44. package/dist/{utils-ktMrldiH.js → utils-mW_Rw1i9.js} +16 -15
  45. package/package.json +1 -1
  46. package/dist/index-B2rTP8gs.js +0 -1
  47. package/dist/utils-CCymYPFY.js +0 -1
@@ -1,39 +1,39 @@
1
- import { defineComponent as be, useSlots as ut, onBeforeUnmount as Nt, computed as C, createBlock as j, openBlock as w, unref as i, mergeProps as ce, createSlots as $t, renderList as je, withCtx as W, renderSlot as Ae, normalizeProps as De, guardReactiveProps as Ee, createVNode as ee, h as b, useAttrs as jt, createElementBlock as ye, normalizeClass as Ie, toDisplayString as Kt, ref as ve, watch as Ft, isRef as tt, createCommentVNode as Le, createElementVNode as ot, normalizeStyle as Wt, Fragment as Me } from "vue";
2
- import { createContext as Gt, Slot as Ht, useEmitAsProps as Ut } from "reka-ui";
3
- import { omit as he, isString as lt, cloneDeep as re, isFunction as qt, debounce as at, pick as Jt, last as nt } from "es-toolkit";
4
- import { isEmptyElement as $, useVModel as Pe, useLazyLoading as Qt, useFormInput as Xt, useVirtualScroll as Yt, useInputDataStates as Zt, useCollection as eo, useDisableBodyPointerEvents as to, installComponent as ct } from "@pantograph/utils-vue";
5
- import { getBemBlock as oo, getBemModifier as lo, getBemElement as S, getComponentOptions as _e, normCls as H, isEmptyLikeLodash as K, generateVariantClassList as Q, createOptionGetterFunc as J, usePCId as Re, getPxSize as Ne, getComponentName as pt } from "@pantograph/utils";
6
- import { Popover as ao } from "../Popover/index.js";
7
- import { cva as dt } from "class-variance-authority";
1
+ import { defineComponent as _e, useSlots as mt, onBeforeUnmount as Wt, computed as C, createBlock as $, openBlock as w, unref as s, mergeProps as ce, withModifiers as Ut, createSlots as Gt, renderList as Ue, withCtx as K, renderSlot as Me, normalizeProps as Re, guardReactiveProps as Ne, createVNode as ee, h, useAttrs as Ht, createElementBlock as he, normalizeClass as ze, toDisplayString as qt, ref as ue, watch as Jt, isRef as rt, createCommentVNode as $e, createElementVNode as st, normalizeStyle as Qt, Fragment as je } from "vue";
2
+ import { createContext as Xt, Slot as Yt, useEmitAsProps as Zt } from "reka-ui";
3
+ import { omit as be, isString as it, cloneDeep as re, isFunction as eo, debounce as ut, pick as to, last as ct } from "es-toolkit";
4
+ import { isEmptyElement as N, useVModel as we, useLazyLoading as oo, useFormInput as lo, useVirtualScroll as no, useInputDataStates as ao, useCollection as ro, useDisableBodyPointerEvents as so, installComponent as ft } from "@pantograph/utils-vue";
5
+ import { getBemBlock as io, getBemModifier as uo, getBemElement as S, getComponentOptions as Ce, normCls as U, isEmptyLikeLodash as j, generateVariantClassList as Q, createOptionGetterFunc as J, usePCId as Fe, getPxSize as Ke, getComponentName as vt } from "@pantograph/utils";
6
+ import { Popover as co } from "../Popover/index.js";
7
+ import { cva as yt } from "class-variance-authority";
8
8
  import "../Icon/index.js";
9
9
  import "../Avatar/index.js";
10
10
  import "../GraphicalObject/index.js";
11
- import { a as no, _ as gt } from "../Avatar.vue_vue_type_style_index_0_lang-BBeWgKUx.js";
12
- import { GraphicalObjectGroup as ro } from "../GraphicalObjectGroup/index.js";
13
- import { _ as so } from "../index-BhaFiUPP.js";
14
- import { _ as io } from "../Chip.vue_vue_type_style_index_0_lang-fj2q-7So.js";
11
+ import { a as po, _ as ht } from "../Avatar.vue_vue_type_style_index_0_lang-BBeWgKUx.js";
12
+ import { GraphicalObjectGroup as go } from "../GraphicalObjectGroup/index.js";
13
+ import { _ as mo } from "../index-BhaFiUPP.js";
14
+ import { _ as fo } from "../Chip.vue_vue_type_style_index_0_lang-fj2q-7So.js";
15
15
  import "../Input/index.js";
16
- import { whenever as uo, refDebounced as co } from "@vueuse/core";
17
- import { _ as po } from "../Input.vue_vue_type_script_setup_true_lang-Ga_3LDxv.js";
18
- import { _ as Ke } from "../Icon.vue_vue_type_style_index_0_lang-D3lvOgux.js";
19
- import { g as go, a as mo } from "../Menu.vue_vue_type_style_index_0_lang-bwzZdsoD.js";
16
+ import { _ as vo } from "../Input.vue_vue_type_script_setup_true_lang-Ga_3LDxv.js";
17
+ import { _ as Ge } from "../Icon.vue_vue_type_style_index_0_lang-D3lvOgux.js";
18
+ import { g as yo, a as ho } from "../Menu.vue_vue_type_style_index_0_lang-bwzZdsoD.js";
20
19
  import { i as X } from "../isArray-QlWcxgml.js";
21
- import { _ as mt } from "../GraphicalObject.vue_vue_type_script_setup_true_lang-BC9GfN2v.js";
20
+ import { _ as bt } from "../GraphicalObject.vue_vue_type_script_setup_true_lang-BC9GfN2v.js";
22
21
  import "../ScrollContainer/index.js";
23
22
  import "../Empty/index.js";
24
- import { f as fo, _ as vo, a as yo } from "../index-BuEiTBIH.js";
23
+ import { f as bo, _ as _o, a as Co } from "../index-BxsIulsm.js";
25
24
  import "../MenuItem/index.js";
26
25
  import "../Checkbox/index.js";
27
- import { _ as ho } from "../Checkbox.vue_vue_type_style_index_0_lang-B1Y8EoU2.js";
28
- import { _ as bo } from "../Skeleton.vue_vue_type_style_index_0_lang-aI8FTL_w.js";
29
- import { _ as _o } from "../Divider.vue_vue_type_style_index_0_lang-eXMD78c3.js";
30
- import { a as rt } from "../index-D2tZoezA.js";
31
- import { useConfig as Co } from "../ConfigProvider/index.js";
32
- import { h as st } from "../head-E4xQy0iK.js";
33
- import { _ as So } from "../ScrollContainer.vue_vue_type_style_index_0_lang-DGrpXPJ1.js";
34
- import { _ as ko } from "../Empty.vue_vue_type_style_index_0_lang-yTn4EQKn.js";
35
- const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placeholder"), $e = S(P, "option"), vt = ["sm", "md", "lg"], Bo = ["error", "warning", "success"], We = /* @__PURE__ */ be({
36
- ..._e("ComboboxInput"),
26
+ import { _ as So } from "../Checkbox.vue_vue_type_style_index_0_lang-B1Y8EoU2.js";
27
+ import { _ as ko } from "../Skeleton.vue_vue_type_style_index_0_lang-aI8FTL_w.js";
28
+ import { _ as xo } from "../Divider.vue_vue_type_style_index_0_lang-eXMD78c3.js";
29
+ import { a as pt } from "../index-D2tZoezA.js";
30
+ import { refDebounced as Oo } from "@vueuse/core";
31
+ import { useConfig as Bo } from "../ConfigProvider/index.js";
32
+ import { h as dt } from "../head-E4xQy0iK.js";
33
+ import { _ as Po } from "../ScrollContainer.vue_vue_type_style_index_0_lang-DGrpXPJ1.js";
34
+ import { _ as Io } from "../Empty.vue_vue_type_style_index_0_lang-yTn4EQKn.js";
35
+ const [He, To] = Xt("Combobox"), P = io("combobox"), _t = uo(P, "value-placeholder"), We = S(P, "option"), Ct = ["sm", "md", "lg"], wo = ["error", "warning", "success"], qe = /* @__PURE__ */ _e({
36
+ ...Ce("ComboboxInput"),
37
37
  __name: "ComboboxInput",
38
38
  props: {
39
39
  id: {},
@@ -62,39 +62,42 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
62
62
  status: {},
63
63
  steps: { type: Boolean }
64
64
  },
65
- setup(B) {
66
- const t = B, c = ut(), o = Fe();
67
- uo(() => o.openModel.value && o.inputRef.value, o.focusOnInput), Nt(() => {
65
+ setup(O) {
66
+ const t = O, c = mt(), o = He();
67
+ Wt(() => {
68
68
  o.comboboxInputFocused.value = !1;
69
69
  });
70
- const k = C(() => {
71
- const L = t.placeholder ?? o.props.placeholder ?? "";
72
- return (o.props.headerSearch ? L : o.placeholder.value) ?? L;
73
- }), U = S(P, "input");
74
- return (L, g) => (w(), j(i(po), ce({
75
- ...i(o).comboboxInputBinding.value,
70
+ const b = C(() => {
71
+ const p = t.placeholder ?? o.props.placeholder ?? "";
72
+ return (o.props.headerSearch ? p : o.placeholder.value) ?? p;
73
+ }), G = (p) => {
74
+ o.props.headerSearch && (p.stopPropagation(), p.preventDefault());
75
+ }, H = S(P, "input");
76
+ return (p, x) => (w(), $(s(vo), ce({
77
+ ...s(o).comboboxInputBinding.value,
76
78
  ...t,
77
- disabled: i(o).getDisabled.value || t.disabled
79
+ disabled: s(o).getDisabled.value || t.disabled
78
80
  }, {
79
- placeholder: k.value,
80
- onKeydown: i(o).onKeyDown,
81
- ref: i(o).inputRef,
82
- class: i(H)(i(U), { [i(ft)]: i(o).valuePlaceholder.value }, t.class),
83
- contentFit: !i(o).props.headerSearch && i(o).props.contentFit,
84
- modelValue: i(o).searchModel.value,
85
- "onUpdate:modelValue": g[0] || (g[0] = (d) => i(o).searchModel.value = d)
86
- }), $t({ _: 2 }, [
87
- je(Object.keys(i(he)(c, ["leading"])), (d) => ({
81
+ placeholder: b.value,
82
+ onClick: G,
83
+ onKeydown: Ut(s(o).onKeyDown, ["stop"]),
84
+ ref: s(o).inputRef,
85
+ class: s(U)(s(H), { [s(_t)]: s(o).valuePlaceholder.value }, t.class),
86
+ contentFit: !s(o).props.headerSearch && s(o).props.contentFit,
87
+ modelValue: s(o).searchModel.value,
88
+ "onUpdate:modelValue": x[0] || (x[0] = (d) => s(o).searchModel.value = d)
89
+ }), Gt({ _: 2 }, [
90
+ Ue(Object.keys(s(be)(c, ["leading"])), (d) => ({
88
91
  name: d,
89
- fn: W((y) => [
90
- Ae(L.$slots, d, De(Ee(y)))
92
+ fn: K((a) => [
93
+ Me(p.$slots, d, Re(Ne(a)))
91
94
  ])
92
95
  })),
93
- i(o).props.headerSearch ? {
96
+ s(o).props.headerSearch ? {
94
97
  name: "leading",
95
- fn: W((d) => [
96
- Ae(L.$slots, "leading", De(Ee(d)), () => [
97
- ee(i(Ke), {
98
+ fn: K((d) => [
99
+ Me(p.$slots, "leading", Re(Ne(d)), () => [
100
+ ee(s(Ge), {
98
101
  size: d.iconSize,
99
102
  icon: "tabler:search",
100
103
  flipOnDir: "rtl"
@@ -104,19 +107,19 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
104
107
  key: "0"
105
108
  } : {
106
109
  name: "leading",
107
- fn: W((d) => [
108
- Ae(L.$slots, "leading", De(Ee(d)))
110
+ fn: K((d) => [
111
+ Me(p.$slots, "leading", Re(Ne(d)))
109
112
  ]),
110
113
  key: "1"
111
114
  }
112
115
  ]), 1040, ["placeholder", "onKeydown", "class", "contentFit", "modelValue"]));
113
116
  }
114
- }), Oo = /* @__PURE__ */ be({
115
- ..._e("ComboboxTrigger"),
117
+ }), zo = /* @__PURE__ */ _e({
118
+ ...Ce("ComboboxTrigger"),
116
119
  __name: "ComboboxTrigger",
117
- setup(B) {
118
- const t = Fe(), c = ({ value: r }) => {
119
- r && X(t.model.value) && !t.getDisabled.value && (t.model.value = t.model.value.filter((_) => _ !== r));
120
+ setup(O) {
121
+ const t = He(), c = ({ value: u }) => {
122
+ u && X(t.model.value) && !t.getDisabled.value && (t.model.value = t.model.value.filter((_) => _ !== u));
120
123
  }, o = C(() => {
121
124
  switch (t.getSize.value) {
122
125
  case "sm":
@@ -125,37 +128,37 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
125
128
  default:
126
129
  return "xsm";
127
130
  }
128
- }), k = C(() => {
129
- if (!t.props.multiple && lt(t.model.value) && !K(t.model.value))
131
+ }), b = C(() => {
132
+ if (!t.props.multiple && it(t.model.value) && !j(t.model.value))
130
133
  return t.getOptionByValue(t.model.value);
131
- }), U = (r = k.value) => {
132
- if (t.props.selectedItemIconAsTrailingIcon && (r != null && r._icon))
133
- return r._icon;
134
- }, L = C(() => U()), g = C(() => {
134
+ }), G = (u = b.value) => {
135
+ if (t.props.selectedItemIconAsTrailingIcon && (u != null && u._icon))
136
+ return u._icon;
137
+ }, H = C(() => G()), p = C(() => {
135
138
  if (!t.props.noTrailing)
136
139
  return t.props.trailingIcon ?? "tabler:chevron-down";
137
- }), d = C(() => {
138
- var h, f;
139
- const r = re(t.model.value), _ = X(t.model.value);
140
+ }), x = C(() => {
141
+ var y, f;
142
+ const u = re(t.model.value), _ = X(t.model.value);
140
143
  return {
141
- modelValue: r,
144
+ modelValue: u,
142
145
  open: re(t.openModel.value),
143
146
  option: _ ? void 0 : t.getOptionByValue(t.model.value),
144
- options: _ ? (f = (h = t.model.value).map) == null ? void 0 : f.call(h, t.getOptionByValue).filter(Boolean) : void 0
147
+ options: _ ? (f = (y = t.model.value).map) == null ? void 0 : f.call(y, t.getOptionByValue).filter(Boolean) : void 0
145
148
  };
146
- }), y = (r) => ({
147
- ...d.value,
148
- option: t.getOptionByValue(r)
149
- }), n = S(P, "trigger"), F = dt(n, {
149
+ }), d = (u) => ({
150
+ ...x.value,
151
+ option: t.getOptionByValue(u)
152
+ }), a = S(P, "trigger"), F = yt(a, {
150
153
  variants: {
151
- size: Q(vt, n),
152
- headerSearch: Q("header-search", n),
153
- status: Q(Bo, n),
154
- bordered: Q("bordered", n),
155
- multiple: Q("multiple", n),
156
- contentFit: Q("content-fit", n),
157
- wrapped: Q("wrapped", n),
158
- filled: Q("filled", n)
154
+ size: Q(Ct, a),
155
+ headerSearch: Q("header-search", a),
156
+ status: Q(wo, a),
157
+ bordered: Q("bordered", a),
158
+ multiple: Q("multiple", a),
159
+ contentFit: Q("content-fit", a),
160
+ wrapped: Q("wrapped", a),
161
+ filled: Q("filled", a)
159
162
  }
160
163
  }), Y = C(() => ({
161
164
  type: "button",
@@ -167,96 +170,97 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
167
170
  "aria-haspopup": "listbox",
168
171
  "aria-expanded": t.openModel.value,
169
172
  "data-state": t.openModel.value ? "open" : "closed",
170
- class: H(
173
+ ref: t.triggerRef,
174
+ class: U(
171
175
  F({
172
176
  size: t.getSize.value,
173
- status: t.getStatus.value === "success" && K(t.model.value) ? void 0 : t.getStatus.value,
177
+ status: t.getStatus.value === "success" && j(t.model.value) ? void 0 : t.getStatus.value,
174
178
  bordered: t.props.bordered,
175
179
  multiple: t.props.multiple,
176
180
  contentFit: t.props.contentFit,
177
181
  wrapped: t.props.wrapped,
178
- filled: !K(t.model.value),
182
+ filled: !j(t.model.value),
179
183
  headerSearch: t.props.headerSearch
180
184
  }),
181
185
  t.props.triggerCls
182
186
  ),
183
187
  ...t.comboboxTriggerBinding.value
184
- })), m = (r, _ = o.value) => b(Ke, { icon: r, size: _ }), se = () => {
185
- var h, f;
186
- let r;
187
- const _ = (f = (h = t.slots).triggerTrailing) == null ? void 0 : f.call(
188
- h,
189
- d.value
188
+ })), m = (u, _ = o.value) => h(Ge, { icon: u, size: _ }), se = () => {
189
+ var y, f;
190
+ let u;
191
+ const _ = (f = (y = t.slots).triggerTrailing) == null ? void 0 : f.call(
192
+ y,
193
+ x.value
190
194
  );
191
- if (!$(_)) r = _;
192
- else if (g.value && g.value) {
193
- const A = g.value === !0 ? "tabler:chevron-down" : g.value;
194
- r = m(A);
195
+ if (!N(_)) u = _;
196
+ else if (p.value && p.value) {
197
+ const V = p.value === !0 ? "tabler:chevron-down" : p.value;
198
+ u = m(V);
195
199
  }
196
- if (r)
197
- return b(
200
+ if (u)
201
+ return h(
198
202
  "div",
199
- { class: H(S(n, "trailing"), t.props.triggerTrailingCls) },
200
- r
203
+ { class: U(S(a, "trailing"), t.props.triggerTrailingCls) },
204
+ u
201
205
  );
202
- }, te = (r) => {
203
- var h, f;
204
- const _ = t.getOptionByValue(r) ?? { _key: r };
205
- return b(gt, {
206
+ }, te = (u) => {
207
+ var y, f;
208
+ const _ = t.getOptionByValue(u) ?? { _key: u };
209
+ return h(ht, {
206
210
  size: t.getTagSize.value,
207
- ..._ ? ((f = (h = t.props).getTagProps) == null ? void 0 : f.call(h, _)) ?? {} : {}
211
+ ..._ ? ((f = (y = t.props).getTagProps) == null ? void 0 : f.call(y, _)) ?? {} : {}
208
212
  });
209
- }, pe = (r) => {
210
- var h, f;
211
- const _ = t.getOptionByValue(r) ?? { _key: r };
212
- return b(mt, {
213
- ..._ ? ((f = (h = t.props).getTagProps) == null ? void 0 : f.call(h, _)) ?? {} : {},
213
+ }, pe = (u) => {
214
+ var y, f;
215
+ const _ = t.getOptionByValue(u) ?? { _key: u };
216
+ return h(bt, {
217
+ ..._ ? ((f = (y = t.props).getTagProps) == null ? void 0 : f.call(y, _)) ?? {} : {},
214
218
  size: t.getTagSize.value
215
219
  });
216
- }, Ce = () => {
220
+ }, Se = () => {
217
221
  const _ = (() => {
218
- var h, f;
222
+ var y, f;
219
223
  if (!t.props.multiple && !X(t.model.value) && t.model.value) {
220
- let A;
221
- lt(t.model.value) && !K(t.model.value) && (A = t.model.value);
222
- const q = A ? (f = (h = t.slots).optionLeading) == null ? void 0 : f.call(
223
- h,
224
- go(
224
+ let V;
225
+ it(t.model.value) && !j(t.model.value) && (V = t.model.value);
226
+ const q = V ? (f = (y = t.slots).optionLeading) == null ? void 0 : f.call(
227
+ y,
228
+ yo(
225
229
  t.props.size,
226
- y(A)
230
+ d(V)
227
231
  )
228
- ) : null, Z = !$(q);
229
- if (Z || t.props.tagRenderMode && ["avatar", "go"].includes(t.props.tagRenderMode) || L.value || t.props.leadingIcon) {
230
- let M;
231
- if (Z ? M = q : t.props.tagRenderMode === "avatar" ? M = te(t.model.value) : t.props.tagRenderMode === "go" ? M = pe(t.model.value) : L.value ? M = m(L.value) : t.props.leadingIcon && (M = m(t.props.leadingIcon)), !$(M))
232
- return M;
232
+ ) : null, Z = !N(q);
233
+ if (Z || t.props.tagRenderMode && ["avatar", "go"].includes(t.props.tagRenderMode) || H.value || t.props.leadingIcon) {
234
+ let L;
235
+ if (Z ? L = q : t.props.tagRenderMode === "avatar" ? L = te(t.model.value) : t.props.tagRenderMode === "go" ? L = pe(t.model.value) : H.value ? L = m(H.value) : t.props.leadingIcon && (L = m(t.props.leadingIcon)), !N(L))
236
+ return L;
233
237
  }
234
238
  }
235
239
  return null;
236
240
  })();
237
- return b(
241
+ return h(
238
242
  "div",
239
243
  {
240
- class: H(S(n, "leading"), t.props.triggerLeadingCls),
241
- style: $(_) ? { display: "none" } : void 0
244
+ class: U(S(a, "leading"), t.props.triggerLeadingCls),
245
+ style: N(_) ? { display: "none" } : void 0
242
246
  },
243
247
  _
244
248
  );
245
249
  }, de = () => {
246
- var Z, M;
247
- const r = (M = (Z = t.slots).trigger) == null ? void 0 : M.call(Z, d.value);
248
- if (!$(r))
249
- return b(Ht, he(Y.value, ["class"]), () => r);
250
- const h = () => {
250
+ var Z, L;
251
+ const u = (L = (Z = t.slots).trigger) == null ? void 0 : L.call(Z, x.value);
252
+ if (!N(u))
253
+ return h(Yt, be(Y.value, ["class"]), () => u);
254
+ const y = () => {
251
255
  const z = [], oe = [
252
- S(n, "tags"),
256
+ S(a, "tags"),
253
257
  t.props.triggerContentCls,
254
258
  t.props.triggerContentValueCls
255
- ], D = (() => {
259
+ ], E = (() => {
256
260
  if (t.props.multiple && X(t.model.value)) {
257
261
  if (t.props.tagRenderMode === "avatar")
258
- return b(
259
- no,
262
+ return h(
263
+ po,
260
264
  {
261
265
  maxCount: t.props.maxCount,
262
266
  size: t.getTagSize.value,
@@ -268,8 +272,8 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
268
272
  () => t.model.value.map(te)
269
273
  );
270
274
  if (t.props.tagRenderMode === "go")
271
- return b(
272
- ro,
275
+ return h(
276
+ go,
273
277
  {
274
278
  maxCount: t.props.maxCount,
275
279
  size: t.getTagSize.value,
@@ -281,8 +285,8 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
281
285
  () => t.model.value.map(pe)
282
286
  );
283
287
  if (t.props.tagRenderMode === "chip")
284
- return b(
285
- so,
288
+ return h(
289
+ mo,
286
290
  {
287
291
  maxCount: t.props.maxCount,
288
292
  size: t.getTagSize.value,
@@ -295,127 +299,127 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
295
299
  },
296
300
  () => t.model.value.map((ie) => {
297
301
  var ge, me;
298
- const Te = () => t.getLabelByValue(ie), Se = ({ size: we }) => {
299
- const R = U(t.getOptionByValue(ie)) ?? t.props.leadingIcon;
300
- return R ? m(R, we) : null;
301
- }, ke = t.getOptionByValue(ie);
302
- return b(
303
- io,
302
+ const Ae = () => t.getLabelByValue(ie), ke = ({ size: Ve }) => {
303
+ const M = G(t.getOptionByValue(ie)) ?? t.props.leadingIcon;
304
+ return M ? m(M, Ve) : null;
305
+ }, xe = t.getOptionByValue(ie);
306
+ return h(
307
+ fo,
304
308
  {
305
- ...ke ? ((me = (ge = t.props).getTagProps) == null ? void 0 : me.call(ge, ke)) ?? {} : {},
309
+ ...xe ? ((me = (ge = t.props).getTagProps) == null ? void 0 : me.call(ge, xe)) ?? {} : {},
306
310
  value: ie,
307
- class: H(S(n, "tag"), t.props.tagCls),
308
- closeIconCls: S(n, "tag__close")
311
+ class: U(S(a, "tag"), t.props.tagCls),
312
+ closeIconCls: S(a, "tag__close")
309
313
  },
310
314
  {
311
- text: Te,
312
- leading: Se
315
+ text: Ae,
316
+ leading: ke
313
317
  }
314
318
  );
315
319
  })
316
320
  );
317
321
  }
318
322
  })();
319
- if (D && z.push(D), t.props.headerSearch ? (!t.props.noValueOnPlaceholder || t.props.placeholder) && z.push(
320
- b(
323
+ if (E && z.push(E), t.props.headerSearch ? (!t.props.noValueOnPlaceholder || t.props.placeholder) && z.push(
324
+ h(
321
325
  "div",
322
326
  {
323
- class: H(S(n, "content__value"), {
324
- [ft]: t.valuePlaceholder.value
327
+ class: U(S(a, "content__value"), {
328
+ [_t]: t.valuePlaceholder.value
325
329
  })
326
330
  },
327
331
  t.placeholder.value ?? t.props.placeholder
328
332
  )
329
333
  ) : z.push(
330
- b(We, {
334
+ h(qe, {
331
335
  noValueOnPlaceholder: t.props.noValueOnPlaceholder,
332
336
  searchIcon: !1,
333
337
  bordered: !1,
334
338
  simple: !0
335
339
  })
336
- ), !$(z) || !t.props.contentFit || t.props.trailingIcon)
337
- return b("div", { class: S(n, "content") }, z);
338
- }, f = [], A = Ce();
339
- f.push(A), f.push(h());
340
+ ), !N(z) || !t.props.contentFit || t.props.trailingIcon)
341
+ return h("div", { class: S(a, "content") }, z);
342
+ }, f = [], V = Se();
343
+ f.push(V), f.push(y());
340
344
  const q = se();
341
- return $(q) || f.push(q), b("button", Y.value, f);
345
+ return N(q) || f.push(q), h("div", Y.value, f);
342
346
  };
343
- return (r, _) => (w(), j(de));
347
+ return (u, _) => (w(), $(de));
344
348
  }
345
- }), it = /* @__PURE__ */ be({
346
- ..._e("ComboboxOption"),
349
+ }), gt = /* @__PURE__ */ _e({
350
+ ...Ce("ComboboxOption"),
347
351
  __name: "ComboboxOption",
348
352
  props: {
349
353
  option: {}
350
354
  },
351
- setup(B) {
352
- const t = B, c = Fe(), o = C(() => c.isOptionSelected(t.option._key)), k = (g) => {
353
- var n, F, Y, m, se, te;
354
- const d = [];
355
- !c.props.tree && c.props.multiple && c.props.checkbox && !t.option._noCheckbox && d.push(
356
- b(ho, {
355
+ setup(O) {
356
+ const t = O, c = He(), o = C(() => c.isOptionSelected(t.option._key)), b = (p) => {
357
+ var a, F, Y, m, se, te;
358
+ const x = [];
359
+ !c.props.tree && c.props.multiple && c.props.checkbox && !t.option._noCheckbox && x.push(
360
+ h(So, {
357
361
  unExtendParent: !0,
358
362
  modelValue: o.value,
359
- size: g.checkboxSize,
363
+ size: p.checkboxSize,
360
364
  disabled: t.option._disabled || c.getDisabled.value
361
365
  })
362
366
  );
363
- const y = (F = (n = c.slots).optionLeading) == null ? void 0 : F.call(n, { ...g, option: t.option });
364
- return $(y) ? c.props.tagRenderMode === "avatar" && c.props.showTriggerTagOnOption ? d.push(
365
- b(gt, {
366
- size: g.avatarSize,
367
+ const d = (F = (a = c.slots).optionLeading) == null ? void 0 : F.call(a, { ...p, option: t.option });
368
+ return N(d) ? c.props.tagRenderMode === "avatar" && c.props.showTriggerTagOnOption ? x.push(
369
+ h(ht, {
370
+ size: p.avatarSize,
367
371
  ...((m = (Y = c.props).getTagProps) == null ? void 0 : m.call(Y, t.option)) ?? {}
368
372
  })
369
- ) : c.props.tagRenderMode === "go" && c.props.showTriggerTagOnOption ? d.push(
370
- b(mt, {
371
- size: g.iconSize,
373
+ ) : c.props.tagRenderMode === "go" && c.props.showTriggerTagOnOption ? x.push(
374
+ h(bt, {
375
+ size: p.iconSize,
372
376
  ...((te = (se = c.props).getTagProps) == null ? void 0 : te.call(se, t.option)) ?? {}
373
377
  })
374
- ) : t.option._icon && d.push(b(Ke, { icon: t.option._icon, size: c.getIconSize.value })) : d.push(y), $(d) ? null : d;
375
- }, U = jt(), L = () => {
376
- const g = c.props.tree ? void 0 : t.option._description, d = (qt(c.props.getMenuItemProps) ? c.props.getMenuItemProps(t.option) : c.props.getMenuItemProps) ?? {};
377
- return b(
378
- mo,
378
+ ) : t.option._icon && x.push(h(Ge, { icon: t.option._icon, size: c.getIconSize.value })) : x.push(d), N(x) ? null : x;
379
+ }, G = Ht(), H = () => {
380
+ const p = c.props.tree ? void 0 : t.option._description, x = (eo(c.props.getMenuItemProps) ? c.props.getMenuItemProps(t.option) : c.props.getMenuItemProps) ?? {};
381
+ return h(
382
+ ho,
379
383
  {
380
384
  unExtendParent: !0,
381
385
  class: S(P, "option"),
382
386
  unFocusable: !0,
383
387
  staticStyle: c.props.tree,
384
- description: g,
388
+ description: p,
385
389
  title: t.option._label,
386
390
  key: t.option._key,
387
391
  selected: o.value,
388
- leadingCenter: !!g,
392
+ leadingCenter: !!p,
389
393
  size: c.getSize.value,
390
394
  disabled: c.props.tree ? !1 : t.option._disabled || c.getDisabled.value,
391
395
  onClick: () => c.selectOption(t.option),
392
396
  slotProps: t,
393
- ...d,
394
- ...U
397
+ ...x,
398
+ ...G
395
399
  },
396
400
  {
397
- leading: k,
401
+ leading: b,
398
402
  trailing: c.slots.optionTrailing,
399
403
  title: c.slots.optionTitle,
400
404
  description: c.slots.optionDescription
401
405
  }
402
406
  );
403
407
  };
404
- return (g, d) => (w(), j(L));
408
+ return (p, x) => (w(), $(H));
405
409
  }
406
- }), Po = /* @__PURE__ */ be({
407
- ..._e("ComboboxLabel"),
410
+ }), Ao = /* @__PURE__ */ _e({
411
+ ...Ce("ComboboxLabel"),
408
412
  __name: "ComboboxLabel",
409
413
  props: {
410
414
  label: {}
411
415
  },
412
- setup(B) {
413
- return (t, c) => (w(), ye("div", {
414
- class: Ie(i(S)(i(P), "label"))
415
- }, Kt(B.label), 3));
416
+ setup(O) {
417
+ return (t, c) => (w(), he("div", {
418
+ class: ze(s(S)(s(P), "label"))
419
+ }, qt(O.label), 3));
416
420
  }
417
- }), Io = /* @__PURE__ */ be({
418
- ..._e("Combobox"),
421
+ }), Vo = /* @__PURE__ */ _e({
422
+ ...Ce("Combobox"),
419
423
  __name: "Combobox",
420
424
  props: {
421
425
  modelValue: {},
@@ -507,50 +511,50 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
507
511
  ignoreParentTo: { type: Boolean }
508
512
  },
509
513
  emits: ["update:modelValue", "update:expandedKeys", "keydownEnter", "keydownEscape", "update:search", "fetch", "search", "select", "update:open", "escapeKeyDown", "pointerDownOutside", "focusOutside", "interactOutside", "openAutoFocus", "closeAutoFocus", "openChange"],
510
- setup(B, { expose: t, emit: c }) {
511
- const o = B, k = c, U = () => {
514
+ setup(O, { expose: t, emit: c }) {
515
+ const o = O, b = c, G = () => {
512
516
  var e, l;
513
517
  o.tree && (((e = o.filterOptions) == null ? void 0 : e.expandParent) === "collapse" ? Y([]) : ((l = o.filterOptions) == null ? void 0 : l.expandParent) === "expand" && Y(
514
- z.value.filter((a) => a._hasChildren).map((a) => a._key)
518
+ z.value.filter((n) => n._hasChildren).map((n) => n._key)
515
519
  ));
516
- }, L = at((e) => {
517
- k("search", e), U();
518
- }, 500), g = Pe(o, "search", k, {
520
+ }, H = ut((e) => {
521
+ b("search", e), G();
522
+ }, 500), p = we(o, "search", b, {
519
523
  passive: o.search === void 0,
520
- onChange: L
521
- }), d = co(g, 500), y = Pe(o, "open", k, {
524
+ onChange: H
525
+ }), x = Oo(p, 500), d = we(o, "open", b, {
522
526
  defaultValue: o.defaultOpen,
523
527
  passive: o.open === void 0,
524
528
  onChange(e) {
525
- !e && o.resetSearchTermOnBlur && (g.value = void 0);
529
+ !e && o.resetSearchTermOnBlur && (p.value = void 0);
526
530
  }
527
- }), n = Pe(
531
+ }), a = we(
528
532
  o,
529
533
  "modelValue",
530
- k,
534
+ b,
531
535
  {
532
536
  passive: o.modelValue === void 0,
533
537
  onChange: () => {
534
538
  var e, l;
535
- y.value && !o.multiple && (y.value = !1), R != null && R.value && o.sortSelectedItems && ((l = (e = R == null ? void 0 : R.value) == null ? void 0 : e.measure) == null || l.call(e)), o.resetSearchTermOnSelect && (g.value = void 0);
539
+ d.value && !o.multiple && (d.value = !1, ve()), M != null && M.value && o.sortSelectedItems && ((l = (e = M == null ? void 0 : M.value) == null ? void 0 : e.measure) == null || l.call(e)), o.resetSearchTermOnSelect && (p.value = void 0);
536
540
  }
537
541
  }
538
- ), F = Pe(
542
+ ), F = we(
539
543
  o,
540
544
  "expandedKeys",
541
- k,
545
+ b,
542
546
  {
543
547
  passive: o.expandedKeys === void 0
544
548
  }
545
- ), Y = at(
549
+ ), Y = ut(
546
550
  (e) => {
547
551
  F.value = e;
548
552
  },
549
553
  500,
550
554
  { edges: ["leading"] }
551
- ), m = ut(), se = Ut(k), te = C(() => ({
552
- ...he(se, ["update:modelValue", "update:search", "select"]),
553
- ...Jt(o, [
555
+ ), m = mt(), se = Zt(b), te = C(() => ({
556
+ ...be(se, ["onUpdate:modelValue", "onUpdate:search", "onSelect", "onOpenAutoFocus"]),
557
+ ...to(o, [
554
558
  "placement",
555
559
  "reversePlacementOnDir",
556
560
  "zIndex",
@@ -565,9 +569,9 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
565
569
  "noTrigger"
566
570
  ])
567
571
  // modal: true,
568
- })), pe = ve();
569
- Qt({ target: pe });
570
- const Ce = J({
572
+ })), pe = ue();
573
+ oo({ target: pe });
574
+ const Se = J({
571
575
  key: "value",
572
576
  getter: o.getValue
573
577
  }), de = {
@@ -582,12 +586,12 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
582
586
  getter: o.getDescription,
583
587
  noReturnOption: !0
584
588
  }),
585
- getValue: Ce,
589
+ getValue: Se,
586
590
  getLabel: J({
587
591
  key: "label",
588
592
  getter: o.getLabel,
589
593
  noReturnOption: !0,
590
- defaultValue: Ce
594
+ defaultValue: Se
591
595
  }),
592
596
  getNoCheckbox: J({
593
597
  key: "noCheckbox",
@@ -617,153 +621,153 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
617
621
  getter: o.getIcon,
618
622
  noReturnOption: !0
619
623
  })
620
- }, r = (e, l) => {
621
- var s;
622
- const a = `get${l[0].toUpperCase() + l.slice(1)}`;
623
- return (s = de[a]) == null ? void 0 : s.call(de, e);
624
- }, _ = (e, l, a) => !!(!o.tree && !(l != null && l.length) && (a != null && a.length)), h = C(
625
- () => fo({
626
- getValue: (e, l, a) => {
627
- const s = r(e, "value");
628
- return K(s) && _(e, l, a) ? Re($e) : s;
624
+ }, u = (e, l) => {
625
+ var r;
626
+ const n = `get${l[0].toUpperCase() + l.slice(1)}`;
627
+ return (r = de[n]) == null ? void 0 : r.call(de, e);
628
+ }, _ = (e, l, n) => !!(!o.tree && !(l != null && l.length) && (n != null && n.length)), y = C(
629
+ () => bo({
630
+ getValue: (e, l, n) => {
631
+ const r = u(e, "value");
632
+ return j(r) && _(e, l, n) ? Fe(We) : r;
629
633
  },
630
- getDisabled: (e) => r(e, "disabled"),
634
+ getDisabled: (e) => u(e, "disabled"),
631
635
  arr: o.options ?? [],
632
636
  getChildren: (e, l) => {
633
637
  if (!(l != null && l.length && !o.tree))
634
- return r(e, "options");
638
+ return u(e, "options");
635
639
  },
636
640
  getExtra: (e, l) => {
637
641
  if (l) {
638
- let a = r(l, "label");
639
- return K(a) || (a = String(a)), {
640
- _description: r(l, "description"),
641
- _label: a,
642
- _title: o.tree ? a : void 0,
643
- _noCheckbox: r(l, "noCheckbox"),
644
- _single: r(l, "single"),
645
- _clear: r(l, "clear"),
646
- _icon: r(l, "icon"),
642
+ let n = u(l, "label");
643
+ return j(n) || (n = String(n)), {
644
+ _description: u(l, "description"),
645
+ _label: n,
646
+ _title: o.tree ? n : void 0,
647
+ _noCheckbox: u(l, "noCheckbox"),
648
+ _single: u(l, "single"),
649
+ _clear: u(l, "clear"),
650
+ _icon: u(l, "icon"),
647
651
  _id: S(P, e)
648
652
  };
649
653
  }
650
654
  },
651
655
  allowNoValidKey: _
652
656
  })
653
- ), f = (e, l = !1) => e ? h.value.filter((a) => {
654
- var s;
657
+ ), f = (e, l = !1) => e ? y.value.filter((n) => {
658
+ var r;
655
659
  if (l) {
656
- const x = nt(a._parentKeys ?? []);
657
- return x && x === e;
660
+ const k = ct(n._parentKeys ?? []);
661
+ return k && k === e;
658
662
  }
659
- return (s = a._parentKeys) == null ? void 0 : s.includes(e);
660
- }) : [], A = (e) => {
663
+ return (r = n._parentKeys) == null ? void 0 : r.includes(e);
664
+ }) : [], V = (e) => {
661
665
  var l;
662
- if ((l = h.value) != null && l.length && !K(e))
663
- return h.value.find((a) => a._key === e);
666
+ if ((l = y.value) != null && l.length && !j(e))
667
+ return y.value.find((n) => n._key === e);
664
668
  }, q = (e) => {
665
- const l = A(e);
669
+ const l = V(e);
666
670
  return l && (l._label || l._key) || e;
667
671
  }, Z = (e) => {
668
- const l = A(e);
672
+ const l = V(e);
669
673
  return l ? l._single ?? !1 : !1;
670
- }, M = (e) => e === void 0 ? !1 : Array.isArray(n.value) ? !!(e && n.value.includes(e)) : n.value === e, z = C(() => {
671
- var s, x;
674
+ }, L = (e) => e === void 0 ? !1 : Array.isArray(a.value) ? !!(e && a.value.includes(e)) : a.value === e, z = C(() => {
675
+ var r, k;
672
676
  let e = [];
673
- const l = /* @__PURE__ */ new Set(), a = (u) => {
674
- u != null && u._key && !l.has(u._key) && (e.push(re(u)), l.add(u._key));
677
+ const l = /* @__PURE__ */ new Set(), n = (i) => {
678
+ i != null && i._key && !l.has(i._key) && (e.push(re(i)), l.add(i._key));
675
679
  };
676
- if (d.value ? (h.value.forEach((u) => {
677
- var v, E;
678
- if (u._label && u._label.toLowerCase().includes(d.value.toLowerCase()) && !l.has(u._key)) {
679
- if (a(u), u._hasChildren && f(u._key).forEach(a), (v = o.filterOptions) != null && v.strictNode)
680
- u._parentKeys && u._parentKeys.forEach((p) => {
681
- if (!l.has(p)) {
682
- const ae = A(p);
683
- a(ae);
680
+ if (x.value ? (y.value.forEach((i) => {
681
+ var v, D;
682
+ if (i._label && i._label.toLowerCase().includes(x.value.toLowerCase()) && !l.has(i._key)) {
683
+ if (n(i), i._hasChildren && f(i._key).forEach(n), (v = o.filterOptions) != null && v.strictNode)
684
+ i._parentKeys && i._parentKeys.forEach((g) => {
685
+ if (!l.has(g)) {
686
+ const ne = V(g);
687
+ n(ne);
684
688
  }
685
689
  });
686
- else if ((E = u._parentKeys) != null && E.length) {
687
- const p = st(u._parentKeys);
688
- if (!K(p)) {
689
- if (!l.has(p)) {
690
- const ne = A(p);
691
- a(ne);
690
+ else if ((D = i._parentKeys) != null && D.length) {
691
+ const g = dt(i._parentKeys);
692
+ if (!j(g)) {
693
+ if (!l.has(g)) {
694
+ const ae = V(g);
695
+ n(ae);
692
696
  }
693
- f(p).forEach(a);
697
+ f(g).forEach(n);
694
698
  }
695
699
  }
696
700
  }
697
701
  }), e = e.sort(
698
- (u, V) => h.value.findIndex((v) => v._key === u._key) - h.value.findIndex((v) => v._key === V._key)
699
- )) : e = re(h.value), o.sortSelectedItems && !o.tree && !K(n.value)) {
700
- let u = re(e);
701
- const V = u.filter((I) => M(I._key)), v = Symbol("root"), E = Symbol("rootGroup"), p = {}, ae = (I, N, T = 1) => {
702
- const G = u.splice(I, T);
703
- u.splice(N, 0, ...G);
704
- }, ne = (I) => I ? u.findIndex((N) => N._key === I) : -1, Be = (I) => {
705
- const N = p[I], T = ne(N == null ? void 0 : N.key);
706
- return N != null && N.length ? T + N.length + 1 : T + 1;
702
+ (i, A) => y.value.findIndex((v) => v._key === i._key) - y.value.findIndex((v) => v._key === A._key)
703
+ )) : e = re(y.value), o.sortSelectedItems && !o.tree && !j(a.value)) {
704
+ let i = re(e);
705
+ const A = i.filter((I) => L(I._key)), v = Symbol("root"), D = Symbol("rootGroup"), g = {}, ne = (I, R, T = 1) => {
706
+ const W = i.splice(I, T);
707
+ i.splice(R, 0, ...W);
708
+ }, ae = (I) => I ? i.findIndex((R) => R._key === I) : -1, Ie = (I) => {
709
+ const R = g[I], T = ae(R == null ? void 0 : R.key);
710
+ return R != null && R.length ? T + R.length + 1 : T + 1;
707
711
  };
708
- V.forEach((I) => {
709
- var N;
710
- if ((N = I._parentKeys) != null && N.length) {
711
- const T = st(I._parentKeys);
712
- let G = ne(T);
713
- const et = Math.max(
714
- Be(v),
715
- Be(E)
712
+ A.forEach((I) => {
713
+ var R;
714
+ if ((R = I._parentKeys) != null && R.length) {
715
+ const T = dt(I._parentKeys);
716
+ let W = ae(T);
717
+ const at = Math.max(
718
+ Ie(v),
719
+ Ie(D)
716
720
  );
717
- if (G > et) {
718
- const Oe = f(T).length;
719
- ae(G, et, Oe + 1);
721
+ if (W > at) {
722
+ const Te = f(T).length;
723
+ ne(W, at, Te + 1);
720
724
  }
721
- if (p[E] = {
725
+ if (g[D] = {
722
726
  key: T,
723
727
  length: f(T).length
724
- }, G = ne(T), T && G > -1) {
725
- const Oe = ne(I._key);
726
- if (p[T] === void 0)
727
- ae(Oe, G + 1);
728
+ }, W = ae(T), T && W > -1) {
729
+ const Te = ae(I._key);
730
+ if (g[T] === void 0)
731
+ ne(Te, W + 1);
728
732
  else {
729
- const Rt = Be(T);
730
- ae(Oe, Rt);
733
+ const Kt = Ie(T);
734
+ ne(Te, Kt);
731
735
  }
732
- p[T] = {
736
+ g[T] = {
733
737
  length: void 0,
734
738
  key: I._key
735
739
  };
736
740
  }
737
741
  } else {
738
- const T = ne(I._key), G = Be(v);
739
- T > G && ae(T, G), p[v] = {
742
+ const T = ae(I._key), W = Ie(v);
743
+ T > W && ne(T, W), g[v] = {
740
744
  key: I._key,
741
745
  length: I._hasChildren ? f(I._key).length : void 0
742
746
  };
743
747
  }
744
- u = re(u);
745
- }), e = u;
748
+ i = re(i);
749
+ }), e = i;
746
750
  }
747
751
  if (!o.tree) {
748
- const u = re(e);
749
- for (let V = 0; V < u.length - 1; V++) {
750
- const v = u[V], E = u[V + 1];
751
- !E._divider && (E._hasChildren || (s = v._parentKeys) != null && s.length && !((x = E._parentKeys) != null && x.length)) && (u.splice(V + 1, 0, {
752
- _key: Re($e),
752
+ const i = re(e);
753
+ for (let A = 0; A < i.length - 1; A++) {
754
+ const v = i[A], D = i[A + 1];
755
+ !D._divider && (D._hasChildren || (r = v._parentKeys) != null && r.length && !((k = D._parentKeys) != null && k.length)) && (i.splice(A + 1, 0, {
756
+ _key: Fe(We),
753
757
  _divider: !0,
754
- _id: Re($e)
755
- }), V++);
758
+ _id: Fe(We)
759
+ }), A++);
756
760
  }
757
- e = u;
761
+ e = i;
758
762
  }
759
763
  return e;
760
764
  });
761
- U();
762
- const { getDisabled: oe, getStatus: Ge, getSize: D } = Xt({
765
+ G();
766
+ const { getDisabled: oe, getStatus: Je, getSize: E } = lo({
763
767
  defaults: { size: "md" },
764
768
  exports: ["getDisabled", "getSize", "getStatus"]
765
769
  }), ie = C(() => {
766
- switch (D.value) {
770
+ switch (E.value) {
767
771
  case "sm":
768
772
  return "xsm";
769
773
  case "lg":
@@ -772,8 +776,8 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
772
776
  default:
773
777
  return "sm";
774
778
  }
775
- }), Te = C(() => {
776
- switch (D.value) {
779
+ }), Ae = C(() => {
780
+ switch (E.value) {
777
781
  case "sm":
778
782
  return "2xsm";
779
783
  case "lg":
@@ -782,7 +786,7 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
782
786
  default:
783
787
  return "xsm";
784
788
  }
785
- }), Se = ve(), ke = {
789
+ }), ke = ue(), xe = {
786
790
  sm: 4,
787
791
  md: 6,
788
792
  lg: 8
@@ -793,13 +797,13 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
793
797
  sm: 32,
794
798
  md: 50,
795
799
  lg: 54
796
- }, we = C(() => ({
800
+ }, Ve = C(() => ({
797
801
  get count() {
798
802
  return z.value.length;
799
803
  },
800
804
  getScrollElement: () => {
801
805
  var e;
802
- return (e = Se.value) == null ? void 0 : e.container.viewportElement;
806
+ return (e = ke.value) == null ? void 0 : e.container.viewportElement;
803
807
  },
804
808
  estimateSize: (e) => {
805
809
  const l = z.value[e];
@@ -807,164 +811,174 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
807
811
  if (l._divider)
808
812
  return 1;
809
813
  if (l._label && l._hasChildren)
810
- return 8 + (ge[D.value] ?? ge.md);
814
+ return 8 + (ge[E.value] ?? ge.md);
811
815
  if (l._description)
812
- return me[D.value] ?? me.md;
816
+ return me[E.value] ?? me.md;
813
817
  }
814
- return rt[D.value] ?? rt.md;
818
+ return pt[E.value] ?? pt.md;
815
819
  },
816
820
  overscan: 5,
817
821
  get gap() {
818
- return ke[D.value] ?? 0;
822
+ return xe[E.value] ?? 0;
819
823
  }
820
824
  }));
821
- let R, le;
825
+ let M, le;
822
826
  if (o.virtual) {
823
- const { virtualizer: e, ...l } = Yt(
824
- we
827
+ const { virtualizer: e, ...l } = no(
828
+ Ve
825
829
  );
826
- R = e, le = l;
830
+ M = e, le = l;
827
831
  }
828
- const yt = C(
832
+ const St = C(
829
833
  () => {
830
834
  var e;
831
- return o.virtual ? (((e = R == null ? void 0 : R.value) == null ? void 0 : e.getVirtualItems()) ?? []).map((l) => z.value[l.index]) : z.value;
835
+ return o.virtual ? (((e = M == null ? void 0 : M.value) == null ? void 0 : e.getVirtualItems()) ?? []).map((l) => z.value[l.index]) : z.value;
832
836
  }
833
- ), ht = C(() => (le == null ? void 0 : le.containerStyles.value) ?? {}), {
834
- inputBindings: bt,
835
- rootBindings: _t,
836
- focused: Ct
837
- } = Zt({
837
+ ), kt = C(() => (le == null ? void 0 : le.containerStyles.value) ?? {}), {
838
+ inputBindings: xt,
839
+ rootBindings: Ot,
840
+ focused: Bt
841
+ } = ao({
838
842
  getDisabled: () => oe.value
839
- }), ue = ve(), ze = () => {
840
- var e;
841
- if (ue.value && document.activeElement !== ((e = ue.value) == null ? void 0 : e.input)) {
842
- ue.value.input.style.pointerEvents = "auto";
843
- const l = setTimeout(() => {
844
- var a, s;
845
- (s = (a = ue.value) == null ? void 0 : a.focus) == null || s.call(a), clearTimeout(l);
846
- }, 100);
847
- ue.value.input.style.pointerEvents = "";
843
+ }), Ee = ue(), De = ue();
844
+ let Oe = !1, fe;
845
+ const ve = () => {
846
+ var n;
847
+ const e = ((n = s(De)) == null ? void 0 : n.$el) ?? s(De), l = s(Ee);
848
+ !Oe && (l || e) && (Oe = !0, clearTimeout(fe), l ? (l.input.style.pointerEvents = "auto", fe = setTimeout(() => {
849
+ var r;
850
+ (r = l == null ? void 0 : l.focus) == null || r.call(l), Oe = !1, clearTimeout(fe);
851
+ }, 150), l.input.style.pointerEvents = "") : (e.style.pointerEvents = "auto", fe = setTimeout(() => {
852
+ var r;
853
+ (r = e.focus) == null || r.call(e), Oe = !1, clearTimeout(fe);
854
+ }, 150), e.style.pointerEvents = ""));
855
+ }, Pt = (e) => {
856
+ if (!o.headerSearch || !s(Ee)) {
857
+ e.preventDefault(), ve();
858
+ return;
848
859
  }
849
- }, He = C(
850
- () => !o.noValueOnPlaceholder && (X(n.value) ? n.value.length === 1 && !K(n.value[0]) : !K(n.value))
851
- ), St = C(() => {
852
- if (He.value) {
853
- if (o.multiple && X(n.value))
854
- return q(nt(n.value));
855
- if (!o.multiple && !X(n.value))
856
- return q(n.value);
860
+ b("openAutoFocus", e);
861
+ }, Qe = C(
862
+ () => !o.noValueOnPlaceholder && (X(a.value) ? a.value.length === 1 && !j(a.value[0]) : !j(a.value))
863
+ ), It = C(() => {
864
+ if (Qe.value) {
865
+ if (o.multiple && X(a.value))
866
+ return q(ct(a.value));
867
+ if (!o.multiple && !X(a.value))
868
+ return q(a.value);
857
869
  }
858
- }), { CollectionSlot: kt, CollectionItem: Ue, itemMap: xt, getItems: qe } = eo({
870
+ }), { CollectionSlot: Tt, CollectionItem: Xe, itemMap: wt, getItems: Ye } = ro({
859
871
  isProvider: !0,
860
872
  key: P
861
- }), Je = () => n.value ? Array.isArray(n.value) ? n.value : [n.value] : [], O = ve(), Ve = (e) => {
862
- O.value = e;
863
- }, Qe = (e) => ({
873
+ }), Ze = () => a.value ? Array.isArray(a.value) ? a.value : [a.value] : [], B = ue(), Le = (e) => {
874
+ B.value = e;
875
+ }, et = (e) => ({
864
876
  "data-disabled": e._disabled ? "" : void 0,
865
- "data-highlighted": O.value === e._key ? "" : void 0
866
- }), fe = ve(), Xe = (e, l) => {
867
- var a, s;
868
- if (l && ((a = fe.value) != null && a.onSelect) && o.tree && ((s = fe.value) == null || s.onSelect(e, !M(e == null ? void 0 : e._key))), !(o.tree || !e || !e._key || e._disabled))
877
+ "data-highlighted": B.value === e._key ? "" : void 0
878
+ }), ye = ue(), Be = (e) => {
879
+ s(a) === e && d.value && (d.value = !1);
880
+ }, tt = (e, l) => {
881
+ var n, r;
882
+ if (l && ((n = ye.value) != null && n.onSelect) && o.tree && ((r = ye.value) == null || r.onSelect(e, !L(e == null ? void 0 : e._key))), !(o.tree || !e || !e._key || e._disabled))
869
883
  if (o.multiple)
870
884
  if (e._clear)
871
- n.value = [], k("select", void 0, !1);
885
+ a.value = [], b("select", void 0, !1);
872
886
  else if (e._single)
873
- n.value = [e._key], k("select", e._key, !0, e);
887
+ a.value = [e._key], b("select", e._key, !0, e);
874
888
  else {
875
- let x = X(n.value) ? n.value : [];
876
- const u = x.includes(e._key);
877
- x.length === 1 && Z(x[0]) && e._key !== x[0] && (x = []), u ? (n.value = x.filter((V) => V !== e._key), k("select", e._key, !0, e)) : (n.value = [...x, e._key], k("select", e._key, !1, e));
889
+ let k = X(a.value) ? a.value : [];
890
+ const i = k.includes(e._key);
891
+ k.length === 1 && Z(k[0]) && e._key !== k[0] && (k = []), i ? (a.value = k.filter((A) => A !== e._key), b("select", e._key, !0, e)) : (a.value = [...k, e._key], b("select", e._key, !1, e));
878
892
  }
879
- else e._clear ? (n.value = void 0, k("select", void 0, !1)) : (n.value = e._key, k("select", e._key, !0, e));
880
- }, { getDir: Bt } = Co(), xe = Bt(), Ye = {
881
- props: o,
882
- emit: k,
883
- onKeyDown: (e) => {
884
- var l, a, s, x, u, V;
885
- if (o.headerSearch || e.stopPropagation(), e.key === "Backspace" && o.multiple && X(n.value) && K(g.value))
886
- n.value = n.value.slice(0, -1);
887
- else if (!y.value)
888
- (e.key === "ArrowDown" || e.key === "Enter") && (y.value = !0);
889
- else if (y.value) {
890
- const v = qe(o.tree);
891
- if (e.key === "Escape")
892
- e.preventDefault(), e.stopPropagation(), y.value = !1;
893
- else if (e.key === "Tab" && !o.headerSearch) y.value = !1;
894
- else if (["ArrowDown", "ArrowUp"].includes(e.key)) {
895
- if (v.length) {
896
- const E = v.findIndex(
897
- (p) => O.value && p.value && p.value === O.value
898
- );
899
- if (e.key === "ArrowDown") {
900
- const p = v[E + 1];
901
- O.value = (p == null ? void 0 : p.value) ?? O.value ?? v[0].value;
902
- } else if (e.key === "ArrowUp") {
903
- const p = v[E - 1];
904
- O.value = (p == null ? void 0 : p.value) ?? v[0].value;
905
- }
906
- (a = (l = v.find(
907
- (p) => O.value && p.value && p.value === O.value
908
- )) == null ? void 0 : l.ref) == null || a.scrollIntoView();
893
+ else e._clear ? (Be(void 0), a.value = void 0, b("select", void 0, !1)) : (Be(e._key), a.value = e._key, b("select", e._key, !0, e));
894
+ }, { getDir: zt } = Bo(), Pe = zt(), ot = (e) => {
895
+ var l, n, r, k, i, A;
896
+ if (["Tab", "Escape"].includes(e.key))
897
+ d.value = !1, e.key === "Escape" && b("keydownEscape", e);
898
+ else if (e.key === "Backspace" && o.multiple && X(a.value) && j(p.value))
899
+ a.value = a.value.slice(0, -1);
900
+ else if (!d.value && (e.key.length === 1 && e.key !== " " || ["Enter", "ArrowDown", "ArrowUp"].includes(e.key)))
901
+ d.value = !0;
902
+ else {
903
+ const v = Ye(o.tree);
904
+ if (["ArrowDown", "ArrowUp"].includes(e.key)) {
905
+ if (v.length) {
906
+ const D = v.findIndex(
907
+ (g) => B.value && g.value && g.value === B.value
908
+ );
909
+ if (e.key === "ArrowDown") {
910
+ const g = v[D + 1];
911
+ B.value = (g == null ? void 0 : g.value) ?? B.value ?? v[0].value;
912
+ } else if (e.key === "ArrowUp") {
913
+ const g = v[D - 1];
914
+ B.value = (g == null ? void 0 : g.value) ?? v[0].value;
909
915
  }
910
- } else if (["ArrowLeft", "ArrowRight"].includes(e.key)) {
911
- const E = A(O.value);
912
- v.length && fe.value && o.tree && O.value && E && ((s = F.value) != null && s.includes(O.value) && (xe.value === "ltr" && e.key === "ArrowLeft" || xe.value === "rtl" && e.key === "ArrowRight") || !((x = F.value) != null && x.includes(O.value)) && (xe.value === "ltr" && e.key === "ArrowRight" || xe.value === "rtl" && e.key === "ArrowLeft")) && ((V = (u = fe.value).onExpandKey) == null || V.call(u, E));
913
- } else e.key === "Enter" && (v.length === 1 && v[0].value && O.value !== v[0].value && (O.value = v[0].value), O.value && Xe(A(O.value), !0), k("keydownEnter", e, g.value));
914
- e.key === "Escape" && k("keydownEscape", e);
915
- }
916
- },
917
- searchModel: g,
918
- openModel: y,
919
- model: n,
916
+ (n = (l = v.find(
917
+ (g) => B.value && g.value && g.value === B.value
918
+ )) == null ? void 0 : l.ref) == null || n.scrollIntoView();
919
+ }
920
+ } else if (["ArrowLeft", "ArrowRight"].includes(e.key)) {
921
+ const D = V(B.value);
922
+ v.length && ye.value && o.tree && B.value && D && ((r = F.value) != null && r.includes(B.value) && (Pe.value === "ltr" && e.key === "ArrowLeft" || Pe.value === "rtl" && e.key === "ArrowRight") || !((k = F.value) != null && k.includes(B.value)) && (Pe.value === "ltr" && e.key === "ArrowRight" || Pe.value === "rtl" && e.key === "ArrowLeft")) && ((A = (i = ye.value).onExpandKey) == null || A.call(i, D));
923
+ } else e.key === "Enter" && (v.length === 1 && v[0].value && B.value !== v[0].value && (B.value = v[0].value), B.value && tt(V(B.value), !0), b("keydownEnter", e, p.value));
924
+ }
925
+ }, lt = {
926
+ props: o,
927
+ emit: b,
928
+ onKeyDown: ot,
929
+ searchModel: p,
930
+ openModel: d,
931
+ model: a,
920
932
  slots: m,
921
- valuePlaceholder: He,
922
- placeholder: St,
923
- getOptionByValue: A,
924
- isOptionSelected: M,
933
+ valuePlaceholder: Qe,
934
+ placeholder: It,
935
+ getOptionByValue: V,
936
+ isOptionSelected: L,
925
937
  getLabelByValue: q,
926
938
  getSingleByValue: Z,
927
- inputRef: ue,
928
- focusOnInput: ze,
939
+ inputRef: Ee,
940
+ triggerRef: De,
941
+ focusOnInput: ve,
929
942
  getDisabled: oe,
930
- getStatus: Ge,
931
- getSize: D,
943
+ getStatus: Je,
944
+ getSize: E,
932
945
  getTagSize: ie,
933
- getIconSize: Te,
934
- comboboxInputBinding: bt,
935
- comboboxTriggerBinding: _t,
936
- comboboxInputFocused: Ct,
937
- selectOption: Xe,
938
- itemMap: xt,
939
- getItems: qe,
940
- highlightedOptionKey: O
946
+ getIconSize: Ae,
947
+ comboboxInputBinding: xt,
948
+ comboboxTriggerBinding: Ot,
949
+ comboboxInputFocused: Bt,
950
+ selectOption: tt,
951
+ itemMap: wt,
952
+ getItems: Ye,
953
+ highlightedOptionKey: B
941
954
  };
942
- xo(Ye), Ft(
955
+ To(lt), Jt(
943
956
  () => [o.clearOnChangeMultiple, o.multiple],
944
957
  () => {
945
- o.clearOnChangeMultiple && (n.value = void 0);
958
+ o.clearOnChangeMultiple && (a.value = void 0, d.value = !1);
946
959
  }
947
960
  );
948
- const Ot = C(() => ({
961
+ const At = C(() => ({
949
962
  defaultExpandAll: !0,
950
963
  showLine: !0,
951
964
  disabled: oe.value,
952
965
  selectionBehavior: "replace",
953
966
  ...o.treeProps ?? {},
954
- size: D.value,
967
+ emitReSelect: !0,
968
+ size: E.value,
955
969
  flattenData: !0,
956
970
  outerVirtualScroll: !0,
957
971
  selectable: !0,
958
972
  focusable: !1,
959
973
  multiple: o.multiple,
960
974
  checkable: o.multiple && o.checkbox,
961
- virtual: R,
975
+ virtual: M,
962
976
  syncCheckboxAndSelect: o.multiple,
963
977
  data: z.value,
964
- modelValue: Je(),
965
- checkedKeys: Je(),
978
+ modelValue: Ze(),
979
+ checkedKeys: Ze(),
966
980
  class: S(P, "tree")
967
- })), Pt = C(() => {
981
+ })), Vt = C(() => {
968
982
  const e = o.scrollContainerProps ?? {};
969
983
  return {
970
984
  ...e,
@@ -978,130 +992,129 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
978
992
  style: (le == null ? void 0 : le.scrollWrapperStyles.value) ?? {}
979
993
  }
980
994
  };
981
- }), Ze = S(P, "popup"), It = dt(Ze, {
995
+ }), nt = S(P, "popup"), Et = yt(nt, {
982
996
  variants: {
983
- size: Q(vt, Ze)
997
+ size: Q(Ct, nt)
984
998
  }
985
- }), Tt = C(() => Ne(o.popupWidth, !0)), wt = C(() => Ne(o.popupHeight, !0)), zt = C(() => Ne(o.minWidth, !0)), Vt = () => {
986
- var a, s;
987
- const e = (s = m.header) == null ? void 0 : s.call(m, {
988
- isEmpty: !((a = z.value) != null && a.length),
989
- search: g.value
990
- }), l = !$(e);
999
+ }), Dt = C(() => Ke(o.popupWidth, !0)), Lt = C(() => Ke(o.popupHeight, !0)), Mt = C(() => Ke(o.minWidth, !0)), Rt = () => {
1000
+ var n, r;
1001
+ const e = (r = m.header) == null ? void 0 : r.call(m, {
1002
+ isEmpty: !((n = z.value) != null && n.length),
1003
+ search: p.value
1004
+ }), l = !N(e);
991
1005
  if (l || o.headerSearch)
992
- return b(
1006
+ return h(
993
1007
  "div",
994
1008
  { class: S(P, "header") },
995
- l ? e : b(We, o.headerSearchInputProps || {})
1009
+ l ? e : h(qe, o.headerSearchInputProps || {})
996
1010
  );
997
- }, At = () => {
998
- var a, s;
999
- const e = (s = m.footer) == null ? void 0 : s.call(m, {
1000
- isEmpty: !((a = z.value) != null && a.length),
1001
- search: g.value
1011
+ }, Nt = () => {
1012
+ var n, r;
1013
+ const e = (r = m.footer) == null ? void 0 : r.call(m, {
1014
+ isEmpty: !((n = z.value) != null && n.length),
1015
+ search: p.value
1002
1016
  });
1003
- if (!$(e))
1004
- return b("div", { class: S(P, "footer") }, e);
1005
- }, Dt = () => {
1006
- var a;
1017
+ if (!N(e))
1018
+ return h("div", { class: S(P, "footer") }, e);
1019
+ }, $t = () => {
1020
+ var n;
1007
1021
  const e = {
1008
- type: D.value === "sm" ? "simple" : "advance",
1009
- ...he(o.emptyProps ?? {}, ["class"]),
1010
- class: H(S(P, "empty"), o.emptyCls)
1011
- }, l = (a = m.empty) == null ? void 0 : a.call(m, e);
1012
- return $(l) ? b(ko, e, {
1022
+ type: E.value === "sm" ? "simple" : "advance",
1023
+ ...be(o.emptyProps ?? {}, ["class"]),
1024
+ class: U(S(P, "empty"), o.emptyCls)
1025
+ }, l = (n = m.empty) == null ? void 0 : n.call(m, e);
1026
+ return N(l) ? h(Io, e, {
1013
1027
  title: m.emptyTitle,
1014
1028
  description: m.emptyDescription,
1015
1029
  actions: m.emptyActions,
1016
1030
  image: m.emptyImage
1017
1031
  }) : l;
1018
- }, Et = () => {
1019
- var a;
1020
- const e = (a = m.loading) == null ? void 0 : a.call(m, {});
1021
- return $(e) ? new Array(z.value.length ? 2 : o.loadingRowCount).fill(1).map(
1022
- () => b(bo, {
1023
- size: D.value,
1024
- class: H(S(P, "skeleton"), o.skeletonCls),
1025
- ...he(o.skeletonProps ?? {}, ["class"])
1032
+ }, jt = () => {
1033
+ var n;
1034
+ const e = (n = m.loading) == null ? void 0 : n.call(m, {});
1035
+ return N(e) ? new Array(z.value.length ? 2 : o.loadingRowCount).fill(1).map(
1036
+ () => h(ko, {
1037
+ size: E.value,
1038
+ class: U(S(P, "skeleton"), o.skeletonCls),
1039
+ ...be(o.skeletonProps ?? {}, ["class"])
1026
1040
  })
1027
1041
  ) : e;
1028
- }, Lt = (e, l, a) => {
1029
- const s = e._clear;
1042
+ }, Ft = (e, l, n) => {
1043
+ const r = e._clear, k = e._key;
1030
1044
  if (o.multiple) {
1031
- const x = e._single;
1032
- s ? n.value = [] : x ? n.value = [e._key] : n.value = a;
1033
- } else s || !l ? n.value = void 0 : n.value = e._key;
1034
- k(
1045
+ const i = e._single;
1046
+ r ? a.value = [] : i ? a.value = [k] : a.value = n;
1047
+ } else r || !l ? (Be(void 0), a.value = void 0) : (Be(k), a.value = k);
1048
+ b(
1035
1049
  "select",
1036
- e._key,
1037
- l,
1050
+ r ? void 0 : k,
1051
+ r ? !1 : l,
1038
1052
  e
1039
1053
  );
1040
- }, Mt = (e) => {
1041
- e.key === "ArrowDown" && !y.value ? y.value = !0 : e.key === "Tab" && y.value && (y.value = !1);
1042
1054
  };
1043
- return o.disableOutsidePointerEvents && to(y), t(Ye), (e, l) => (w(), j(i(ao), ce({
1044
- open: i(y),
1045
- "onUpdate:open": l[2] || (l[2] = (a) => tt(y) ? y.value = a : null)
1055
+ return o.disableOutsidePointerEvents && so(d), t(lt), (e, l) => (w(), $(s(co), ce({
1056
+ open: s(d),
1057
+ "onUpdate:open": l[2] || (l[2] = (n) => rt(d) ? d.value = n : null)
1046
1058
  }, te.value, {
1047
1059
  containerProps: {
1048
- ...B.containerProps ?? {},
1049
- onClick: ze
1060
+ ...O.containerProps ?? {},
1061
+ onClick: ve
1050
1062
  },
1051
1063
  noPadding: !0,
1052
- size: i(D),
1064
+ size: s(E),
1053
1065
  containerStyle: {
1054
1066
  pointerEvents: "auto",
1055
- display: i(y) ? void 0 : "none",
1056
- zIndex: B.zIndex,
1057
- "--ptc-combobox-popup-width": B.samePopupWidth ? void 0 : Tt.value,
1058
- "--ptc-combobox-popup-height": wt.value,
1059
- "--ptc-combobox-trigger-min-w": zt.value
1067
+ display: s(d) ? void 0 : "none",
1068
+ zIndex: O.zIndex,
1069
+ "--ptc-combobox-popup-width": O.samePopupWidth ? void 0 : Dt.value,
1070
+ "--ptc-combobox-popup-height": Lt.value,
1071
+ "--ptc-combobox-trigger-min-w": Mt.value
1060
1072
  },
1061
- containerCls: i(H)(i(It)({ size: i(D) }), B.popupCls),
1062
- onKeydown: Mt
1073
+ containerCls: s(U)(s(Et)({ size: s(E) }), O.popupCls),
1074
+ onOpenAutoFocus: Pt,
1075
+ noControl: ""
1063
1076
  }), {
1064
- default: W(() => [
1065
- ee(Oo)
1077
+ default: K(() => [
1078
+ ee(zo, { onKeydown: ot })
1066
1079
  ]),
1067
- content: W(() => [
1068
- ee(Vt),
1069
- ee(i(So), ce({
1080
+ content: K(() => [
1081
+ ee(Rt),
1082
+ ee(s(Po), ce({
1070
1083
  ref_key: "scrollContainerRef",
1071
- ref: Se
1072
- }, Pt.value), {
1073
- default: W(() => [
1074
- z.value.length || B.loading ? (w(), j(i(kt), { key: 0 }, {
1075
- default: W(() => [
1076
- ot("div", {
1077
- class: Ie(i(H)(i(S)(i(P), "options"), B.optionsCls)),
1078
- style: Wt(B.virtual ? ht.value : {}),
1079
- onPointerleave: l[1] || (l[1] = (a) => Ve(void 0))
1084
+ ref: ke
1085
+ }, Vt.value), {
1086
+ default: K(() => [
1087
+ z.value.length || O.loading ? (w(), $(s(Tt), { key: 0 }, {
1088
+ default: K(() => [
1089
+ st("div", {
1090
+ class: ze(s(U)(s(S)(s(P), "options"), O.optionsCls)),
1091
+ style: Qt(O.virtual ? kt.value : {}),
1092
+ onPointerleave: l[1] || (l[1] = (n) => Le(void 0))
1080
1093
  }, [
1081
- B.tree ? (w(), j(i(vo), ce({
1094
+ O.tree ? (w(), $(s(_o), ce({
1082
1095
  key: 0,
1083
1096
  ref_key: "treeRef",
1084
- ref: fe
1085
- }, Ot.value, {
1086
- expandedKeys: i(F),
1087
- "onUpdate:expandedKeys": l[0] || (l[0] = (a) => tt(F) ? F.value = a : null),
1088
- onExpand: ze,
1089
- onSelect: Lt
1097
+ ref: ye
1098
+ }, At.value, {
1099
+ expandedKeys: s(F),
1100
+ "onUpdate:expandedKeys": l[0] || (l[0] = (n) => rt(F) ? F.value = n : null),
1101
+ onExpand: ve,
1102
+ onSelect: Ft
1090
1103
  }), {
1091
- default: W(({ items: a }) => [
1092
- (w(!0), ye(Me, null, je(a, (s) => (w(), j(i(Ue), {
1093
- key: s._key,
1094
- value: s._key,
1095
- id: s._id
1104
+ default: K(({ items: n }) => [
1105
+ (w(!0), he(je, null, Ue(n, (r) => (w(), $(s(Xe), {
1106
+ key: r._key,
1107
+ value: r._key,
1108
+ id: r._id
1096
1109
  }, {
1097
- default: W(() => [
1098
- ee(i(yo), ce({ node: s }, { ref_for: !0 }, Qe(s), {
1099
- onPointermove: (x) => Ve(s._key),
1100
- id: s._id
1110
+ default: K(() => [
1111
+ ee(s(Co), ce({ node: r }, { ref_for: !0 }, et(r), {
1112
+ onPointermove: (k) => Le(r._key),
1113
+ id: r._id
1101
1114
  }), {
1102
- default: W(() => [
1103
- ee(it, {
1104
- option: s
1115
+ default: K(() => [
1116
+ ee(gt, {
1117
+ option: r
1105
1118
  }, null, 8, ["option"])
1106
1119
  ]),
1107
1120
  _: 2
@@ -1111,60 +1124,60 @@ const [Fe, xo] = Gt("Combobox"), P = oo("combobox"), ft = lo(P, "value-placehold
1111
1124
  }, 1032, ["value", "id"]))), 128))
1112
1125
  ]),
1113
1126
  _: 1
1114
- }, 16, ["expandedKeys"])) : (w(!0), ye(Me, { key: 1 }, je(yt.value, (a) => (w(), ye(Me, {
1115
- key: a._key
1127
+ }, 16, ["expandedKeys"])) : (w(!0), he(je, { key: 1 }, Ue(St.value, (n) => (w(), he(je, {
1128
+ key: n._key
1116
1129
  }, [
1117
- a._divider ? (w(), j(_o, { key: 0 })) : a._label && a._hasChildren ? (w(), j(Po, {
1130
+ n._divider ? (w(), $(xo, { key: 0 })) : n._label && n._hasChildren ? (w(), $(Ao, {
1118
1131
  key: 1,
1119
- label: a._label
1120
- }, null, 8, ["label"])) : a._hasChildren ? Le("", !0) : (w(), j(i(Ue), {
1132
+ label: n._label
1133
+ }, null, 8, ["label"])) : n._hasChildren ? $e("", !0) : (w(), $(s(Xe), {
1121
1134
  key: 2,
1122
- value: a._key,
1123
- id: a._id
1135
+ value: n._key,
1136
+ id: n._id
1124
1137
  }, {
1125
- default: W(() => [
1126
- ee(it, ce({ option: a }, { ref_for: !0 }, Qe(a), {
1127
- onPointermove: (s) => Ve(a._key),
1128
- id: a._id
1138
+ default: K(() => [
1139
+ ee(gt, ce({ option: n }, { ref_for: !0 }, et(n), {
1140
+ onPointermove: (r) => Le(n._key),
1141
+ id: n._id
1129
1142
  }), null, 16, ["option", "onPointermove", "id"])
1130
1143
  ]),
1131
1144
  _: 2
1132
1145
  }, 1032, ["value", "id"]))
1133
1146
  ], 64))), 128)),
1134
- B.loading ? (w(), j(Et, { key: 2 })) : Le("", !0)
1147
+ O.loading ? (w(), $(jt, { key: 2 })) : $e("", !0)
1135
1148
  ], 38)
1136
1149
  ]),
1137
1150
  _: 1
1138
- })) : (w(), j(Dt, { key: 1 })),
1139
- B.lazyLoading ? (w(), ye("div", {
1151
+ })) : (w(), $($t, { key: 1 })),
1152
+ O.lazyLoading ? (w(), he("div", {
1140
1153
  key: 2,
1141
- class: Ie(i(S)(i(P), "lazy_loading"))
1154
+ class: ze(s(S)(s(P), "lazy_loading"))
1142
1155
  }, [
1143
- ot("div", {
1144
- class: Ie(i(S)(i(P), "lazy_loading_trigger")),
1156
+ st("div", {
1157
+ class: ze(s(S)(s(P), "lazy_loading_trigger")),
1145
1158
  ref_key: "target",
1146
1159
  ref: pe
1147
1160
  }, null, 2)
1148
- ], 2)) : Le("", !0)
1161
+ ], 2)) : $e("", !0)
1149
1162
  ]),
1150
1163
  _: 1
1151
1164
  }, 16),
1152
- ee(At)
1165
+ ee(Nt)
1153
1166
  ]),
1154
1167
  _: 1
1155
1168
  }, 16, ["open", "containerProps", "size", "containerStyle", "containerCls"]));
1156
1169
  }
1157
- }), cl = ct(Io, pt("Combobox")), pl = ct(
1158
- We,
1159
- pt("ComboboxInput")
1170
+ }), ml = ft(Vo, vt("Combobox")), fl = ft(
1171
+ qe,
1172
+ vt("ComboboxInput")
1160
1173
  );
1161
1174
  export {
1162
- Io as Combobox,
1163
- We as ComboboxInput,
1164
- pl as ComboboxInputPlugin,
1165
- cl as ComboboxPlugin,
1166
- vt as ComboboxSizes,
1167
- Bo as ComboboxStatuses,
1168
- Fe as injectComboboxContext,
1169
- xo as provideComboboxContext
1175
+ Vo as Combobox,
1176
+ qe as ComboboxInput,
1177
+ fl as ComboboxInputPlugin,
1178
+ ml as ComboboxPlugin,
1179
+ Ct as ComboboxSizes,
1180
+ wo as ComboboxStatuses,
1181
+ He as injectComboboxContext,
1182
+ To as provideComboboxContext
1170
1183
  };