@wirecore/wirelayer-vue 0.6.0 → 0.7.0

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 (120) hide show
  1. package/dist/{Checkbox-D9f77jtl.js → Checkbox-D175nhKK.js} +26 -22
  2. package/dist/ContextMenu-BEOEyUa6.js +2235 -0
  3. package/dist/{Highlight-Cg8DvCfq.js → Highlight-uwptdaUw.js} +35 -32
  4. package/dist/{Input-BhnYMKjE.js → Input-Cn5q0yVE.js} +48 -35
  5. package/dist/{Select-DAuYpE1c.js → Select-Bd2Vpr7G.js} +173 -164
  6. package/dist/Slider-Cpv7Vj3B.js +143 -0
  7. package/dist/{Tree-DWxqSrO6.js → Tree-fd9LXqgZ.js} +183 -180
  8. package/dist/chart.js +1 -1
  9. package/dist/components/AngleSlider/AngleSlider.vue.d.ts +2 -0
  10. package/dist/components/AngleSlider/AngleSlider.vue.d.ts.map +1 -1
  11. package/dist/components/Autocomplete/Autocomplete.vue.d.ts +2 -0
  12. package/dist/components/Autocomplete/Autocomplete.vue.d.ts.map +1 -1
  13. package/dist/components/Carousel/Carousel.vue.d.ts +2 -0
  14. package/dist/components/Carousel/Carousel.vue.d.ts.map +1 -1
  15. package/dist/components/CascadeSelect/CascadeSelect.vue.d.ts +2 -0
  16. package/dist/components/CascadeSelect/CascadeSelect.vue.d.ts.map +1 -1
  17. package/dist/components/Checkbox/Checkbox.vue.d.ts +2 -0
  18. package/dist/components/Checkbox/Checkbox.vue.d.ts.map +1 -1
  19. package/dist/components/ColorInput/ColorInput.vue.d.ts.map +1 -1
  20. package/dist/components/ColorPicker/ColorPicker.vue.d.ts +2 -0
  21. package/dist/components/ColorPicker/ColorPicker.vue.d.ts.map +1 -1
  22. package/dist/components/Combobox/Combobox.vue.d.ts +2 -0
  23. package/dist/components/Combobox/Combobox.vue.d.ts.map +1 -1
  24. package/dist/components/Confirm/ConfirmDialog.vue.d.ts +5 -0
  25. package/dist/components/Confirm/ConfirmDialog.vue.d.ts.map +1 -1
  26. package/dist/components/Confirm/confirm.d.ts +7 -0
  27. package/dist/components/Confirm/confirm.d.ts.map +1 -1
  28. package/dist/components/DatePicker/DatePicker.vue.d.ts +2 -0
  29. package/dist/components/DatePicker/DatePicker.vue.d.ts.map +1 -1
  30. package/dist/components/DatePicker/DatePickerBase.vue.d.ts +2 -0
  31. package/dist/components/DatePicker/DatePickerBase.vue.d.ts.map +1 -1
  32. package/dist/components/DateRangePicker/DateRangePicker.vue.d.ts +2 -0
  33. package/dist/components/DateRangePicker/DateRangePicker.vue.d.ts.map +1 -1
  34. package/dist/components/Dialog/DialogContent.vue.d.ts +2 -0
  35. package/dist/components/Dialog/DialogContent.vue.d.ts.map +1 -1
  36. package/dist/components/Drawer/DrawerContent.vue.d.ts +2 -0
  37. package/dist/components/Drawer/DrawerContent.vue.d.ts.map +1 -1
  38. package/dist/components/DurationInput/DurationInput.vue.d.ts +2 -0
  39. package/dist/components/DurationInput/DurationInput.vue.d.ts.map +1 -1
  40. package/dist/components/IconButton/IconButton.vue.d.ts +2 -0
  41. package/dist/components/IconButton/IconButton.vue.d.ts.map +1 -1
  42. package/dist/components/Knob/Knob.vue.d.ts +2 -0
  43. package/dist/components/Knob/Knob.vue.d.ts.map +1 -1
  44. package/dist/components/Listbox/Listbox.vue.d.ts +2 -0
  45. package/dist/components/Listbox/Listbox.vue.d.ts.map +1 -1
  46. package/dist/components/MonthPicker/MonthPicker.vue.d.ts +2 -0
  47. package/dist/components/MonthPicker/MonthPicker.vue.d.ts.map +1 -1
  48. package/dist/components/MultiSelect/MultiSelect.vue.d.ts +2 -0
  49. package/dist/components/MultiSelect/MultiSelect.vue.d.ts.map +1 -1
  50. package/dist/components/NumberInput/NumberInput.vue.d.ts +2 -0
  51. package/dist/components/NumberInput/NumberInput.vue.d.ts.map +1 -1
  52. package/dist/components/PasswordInput/PasswordInput.vue.d.ts +2 -0
  53. package/dist/components/PasswordInput/PasswordInput.vue.d.ts.map +1 -1
  54. package/dist/components/PinInput/PinInput.vue.d.ts +2 -0
  55. package/dist/components/PinInput/PinInput.vue.d.ts.map +1 -1
  56. package/dist/components/RadioGroup/RadioGroup.vue.d.ts.map +1 -1
  57. package/dist/components/Rating/Rating.vue.d.ts +2 -0
  58. package/dist/components/Rating/Rating.vue.d.ts.map +1 -1
  59. package/dist/components/SegmentedControl/SegmentedControl.vue.d.ts.map +1 -1
  60. package/dist/components/Select/Select.vue.d.ts +2 -0
  61. package/dist/components/Select/Select.vue.d.ts.map +1 -1
  62. package/dist/components/SelectionCard/CheckboxCard.vue.d.ts +2 -0
  63. package/dist/components/SelectionCard/CheckboxCard.vue.d.ts.map +1 -1
  64. package/dist/components/Slider/Slider.vue.d.ts +2 -0
  65. package/dist/components/Slider/Slider.vue.d.ts.map +1 -1
  66. package/dist/components/Switch/Switch.vue.d.ts +2 -0
  67. package/dist/components/Switch/Switch.vue.d.ts.map +1 -1
  68. package/dist/components/TagsInput/TagsInput.vue.d.ts +2 -0
  69. package/dist/components/TagsInput/TagsInput.vue.d.ts.map +1 -1
  70. package/dist/components/TimePicker/TimePicker.vue.d.ts +2 -0
  71. package/dist/components/TimePicker/TimePicker.vue.d.ts.map +1 -1
  72. package/dist/components/TimeRangePicker/TimeRangePicker.vue.d.ts +2 -0
  73. package/dist/components/TimeRangePicker/TimeRangePicker.vue.d.ts.map +1 -1
  74. package/dist/components/Tooltip/Tooltip.vue.d.ts +3 -0
  75. package/dist/components/Tooltip/Tooltip.vue.d.ts.map +1 -1
  76. package/dist/components/TreeSelect/TreeSelect.vue.d.ts +2 -0
  77. package/dist/components/TreeSelect/TreeSelect.vue.d.ts.map +1 -1
  78. package/dist/components/YearPicker/YearPicker.vue.d.ts +2 -0
  79. package/dist/components/YearPicker/YearPicker.vue.d.ts.map +1 -1
  80. package/dist/data-table/DataTable.vue.d.ts +9 -1
  81. package/dist/data-table/DataTable.vue.d.ts.map +1 -1
  82. package/dist/data-table.js +1007 -994
  83. package/dist/editor.js +1 -1
  84. package/dist/form/FormField.vue.d.ts +3 -0
  85. package/dist/form/FormField.vue.d.ts.map +1 -1
  86. package/dist/form.js +7 -4
  87. package/dist/index.d.ts +1 -1
  88. package/dist/index.d.ts.map +1 -1
  89. package/dist/index.js +5674 -5521
  90. package/dist/label-for-eQvYjsM5.js +8 -0
  91. package/dist/pdf.js +2 -2
  92. package/dist/sources/ActionBar.css +1 -0
  93. package/dist/sources/AppShell.css +1 -0
  94. package/dist/sources/ChatPrompt.css +1 -0
  95. package/dist/sources/Gallery.css +1 -0
  96. package/dist/sources/IconButton.css +1 -0
  97. package/dist/sources/Image.css +1 -0
  98. package/dist/sources/ImageCropper.css +1 -0
  99. package/dist/sources/InlineEdit.css +1 -0
  100. package/dist/sources/Marquee.css +1 -0
  101. package/dist/sources/MegaMenu.css +1 -0
  102. package/dist/sources/Menubar.css +1 -0
  103. package/dist/sources/OrderList.css +1 -0
  104. package/dist/sources/PickList.css +1 -0
  105. package/dist/sources/ScrollTop.css +1 -0
  106. package/dist/{useTree-H8XsFHMk.js → useTree-UhG1TMeM.js} +1 -1
  107. package/dist/utils/label-for.d.ts +3 -0
  108. package/dist/utils/label-for.d.ts.map +1 -0
  109. package/dist/utils/list.d.ts +5 -0
  110. package/dist/utils/list.d.ts.map +1 -1
  111. package/dist/virtual/VirtualSelect.vue.d.ts +2 -0
  112. package/dist/virtual/VirtualSelect.vue.d.ts.map +1 -1
  113. package/dist/virtual.js +207 -197
  114. package/fonts.css +2 -0
  115. package/llms-full.txt +188 -3
  116. package/llms.txt +4 -1
  117. package/package.json +7 -3
  118. package/theme.css +14 -0
  119. package/dist/ContextMenu-C5JKyNlX.js +0 -2209
  120. package/dist/Slider-CyoZc5A8.js +0 -135
@@ -1,17 +1,18 @@
1
1
  import { a as e, n as t } from "./recipes-BlM9aKyt.js";
2
2
  import { t as n } from "./attrs-KNjeRUCf.js";
3
- import { a as r, n as i, r as a } from "./Highlight-Cg8DvCfq.js";
4
- import { Fragment as o, Teleport as s, computed as c, createBlock as l, createCommentVNode as u, createElementBlock as d, createElementVNode as f, createSlots as p, createTextVNode as m, createVNode as h, defineComponent as g, guardReactiveProps as _, mergeProps as v, nextTick as ee, normalizeClass as y, normalizeProps as b, onBeforeUnmount as x, onMounted as S, openBlock as C, ref as w, renderList as T, renderSlot as E, resolveDynamicComponent as D, toDisplayString as O, unref as k, useAttrs as te, useId as ne, watch as A, withCtx as j } from "vue";
3
+ import { a as r, n as i, r as a } from "./Highlight-uwptdaUw.js";
4
+ import { Fragment as o, Teleport as s, computed as c, createBlock as l, createCommentVNode as u, createElementBlock as d, createElementVNode as f, createSlots as p, createTextVNode as m, createVNode as h, defineComponent as g, guardReactiveProps as _, mergeProps as v, nextTick as ee, normalizeClass as y, normalizeProps as b, onBeforeUnmount as te, onMounted as x, openBlock as S, ref as C, renderList as w, renderSlot as T, resolveDynamicComponent as E, toDisplayString as D, unref as O, useAttrs as k, useId as ne, watch as A, withCtx as j } from "vue";
5
5
  import { Check as M, ChevronDown as re, LoaderCircle as N, X as ie } from "@lucide/vue";
6
- import { select as ae, spinner as P } from "@wirecore/wirelayer-recipes";
7
- import { createListCollection as oe } from "@ark-ui/vue/collection";
6
+ import { controlIds as ae, select as oe, spinner as P } from "@wirecore/wirelayer-recipes";
7
+ import { useFieldContext as se } from "@ark-ui/vue/field";
8
+ import { createListCollection as ce } from "@ark-ui/vue/collection";
8
9
  import { Select as F } from "@ark-ui/vue/select";
9
10
  //#region src/components/Spinner/Spinner.vue?vue&type=script&setup=true&lang.ts
10
11
  var I = [
11
12
  "aria-label",
12
13
  "aria-valuenow",
13
14
  "aria-valuetext"
14
- ], se = ["stroke-dasharray"], L = /* @__PURE__ */ g({
15
+ ], L = ["stroke-dasharray"], R = /* @__PURE__ */ g({
15
16
  inheritAttrs: !1,
16
17
  __name: "Spinner",
17
18
  props: {
@@ -21,24 +22,24 @@ var I = [
21
22
  classes: {}
22
23
  },
23
24
  setup(n) {
24
- let r = e(), i = n, a = t("spinner", P, () => i.classes), o = te(), s = c(() => a({ size: i.size })), l = c(() => Math.min(100, Math.max(0, i.value ?? 0))), u = 2 * Math.PI * 9;
25
- return (e, t) => n.value === void 0 ? (C(), d("span", v({ key: 1 }, {
26
- ...k(o),
27
- class: s.value.base({ class: y(k(o).class) })
28
- }, { role: "status" }), [h(k(N), {
25
+ let r = e(), i = n, a = t("spinner", P, () => i.classes), o = k(), s = c(() => a({ size: i.size })), l = c(() => Math.min(100, Math.max(0, i.value ?? 0))), u = 2 * Math.PI * 9;
26
+ return (e, t) => n.value === void 0 ? (S(), d("span", v({ key: 1 }, {
27
+ ...O(o),
28
+ class: s.value.base({ class: y(O(o).class) })
29
+ }, { role: "status" }), [h(O(N), {
29
30
  class: y(s.value.icon()),
30
31
  "aria-hidden": "true"
31
- }, null, 8, ["class"]), f("span", { class: y(s.value.label()) }, O(n.label ?? k(r).common.loading), 3)], 16)) : (C(), d("span", v({ key: 0 }, {
32
- ...k(o),
33
- class: s.value.base({ class: y(k(o).class) })
32
+ }, null, 8, ["class"]), f("span", { class: y(s.value.label()) }, D(n.label ?? O(r).common.loading), 3)], 16)) : (S(), d("span", v({ key: 0 }, {
33
+ ...O(o),
34
+ class: s.value.base({ class: y(O(o).class) })
34
35
  }, {
35
36
  role: "progressbar",
36
- "aria-label": n.label ?? k(r).common.loading,
37
+ "aria-label": n.label ?? O(r).common.loading,
37
38
  "aria-valuemin": "0",
38
39
  "aria-valuemax": "100",
39
40
  "aria-valuenow": l.value,
40
41
  "aria-valuetext": `${Math.round(l.value)} %`
41
- }), [(C(), d("svg", {
42
+ }), [(S(), d("svg", {
42
43
  class: y(s.value.ring()),
43
44
  viewBox: "0 0 24 24",
44
45
  "aria-hidden": "true"
@@ -56,9 +57,9 @@ var I = [
56
57
  "stroke-width": "3",
57
58
  "stroke-linecap": "round",
58
59
  "stroke-dasharray": `${l.value / 100 * u} ${u}`
59
- }, null, 10, se)], 2))], 16, I));
60
+ }, null, 10, L)], 2))], 16, I));
60
61
  }
61
- }), R = ["data-state"], z = /* @__PURE__ */ g({
62
+ }), z = ["data-state"], B = /* @__PURE__ */ g({
62
63
  __name: "ListOption",
63
64
  props: {
64
65
  parts: {},
@@ -69,51 +70,51 @@ var I = [
69
70
  draggable: { type: Boolean }
70
71
  },
71
72
  setup(e) {
72
- return (t, n) => (C(), l(D(e.parts.Item), {
73
+ return (t, n) => (S(), l(E(e.parts.Item), {
73
74
  item: e.option,
74
75
  class: y(e.classes.item),
75
76
  "data-description": e.option.description ? "" : void 0,
76
77
  draggable: e.draggable && !e.option.disabled ? "true" : void 0
77
78
  }, {
78
79
  default: j(() => [
79
- e.checkbox ? (C(), l(D(e.parts.ItemContext), { key: 0 }, {
80
+ e.checkbox ? (S(), l(E(e.parts.ItemContext), { key: 0 }, {
80
81
  default: j((t) => [f("span", {
81
82
  class: y(e.classes.check),
82
83
  "data-state": t.selected ? "checked" : "unchecked",
83
84
  "aria-hidden": "true"
84
- }, [t.selected ? (C(), l(k(M), {
85
+ }, [t.selected ? (S(), l(O(M), {
85
86
  key: 0,
86
87
  class: y(e.classes.checkIcon)
87
- }, null, 8, ["class"])) : u("", !0)], 10, R)]),
88
+ }, null, 8, ["class"])) : u("", !0)], 10, z)]),
88
89
  _: 1
89
90
  })) : u("", !0),
90
- t.$slots.item ? (C(), l(D(e.parts.ItemContext), { key: 1 }, {
91
- default: j((n) => [E(t.$slots, "item", {
91
+ t.$slots.item ? (S(), l(E(e.parts.ItemContext), { key: 1 }, {
92
+ default: j((n) => [T(t.$slots, "item", {
92
93
  item: e.option.item,
93
94
  selected: n.selected,
94
95
  highlighted: n.highlighted,
95
96
  disabled: n.disabled
96
97
  })]),
97
98
  _: 3
98
- })) : (C(), d(o, { key: 2 }, [e.option.icon ? (C(), l(D(e.option.icon), {
99
+ })) : (S(), d(o, { key: 2 }, [e.option.icon ? (S(), l(E(e.option.icon), {
99
100
  key: 0,
100
101
  class: y(e.classes.icon),
101
102
  "aria-hidden": "true"
102
- }, null, 8, ["class"])) : u("", !0), e.option.description ? (C(), d("span", {
103
+ }, null, 8, ["class"])) : u("", !0), e.option.description ? (S(), d("span", {
103
104
  key: 1,
104
105
  class: y(e.classes.itemBody)
105
- }, [(C(), l(D(e.parts.ItemText), { class: y(e.classes.itemText) }, {
106
- default: j(() => [m(O(e.option.label), 1)]),
106
+ }, [(S(), l(E(e.parts.ItemText), { class: y(e.classes.itemText) }, {
107
+ default: j(() => [m(D(e.option.label), 1)]),
107
108
  _: 1
108
- }, 8, ["class"])), f("span", { class: y(e.classes.itemDescription) }, O(e.option.description), 3)], 2)) : (C(), l(D(e.parts.ItemText), {
109
+ }, 8, ["class"])), f("span", { class: y(e.classes.itemDescription) }, D(e.option.description), 3)], 2)) : (S(), l(E(e.parts.ItemText), {
109
110
  key: 2,
110
111
  class: y(e.classes.itemText)
111
112
  }, {
112
- default: j(() => [m(O(e.option.label), 1)]),
113
+ default: j(() => [m(D(e.option.label), 1)]),
113
114
  _: 1
114
115
  }, 8, ["class"]))], 64)),
115
- !e.checkbox && !e.noIndicator ? (C(), l(D(e.parts.ItemIndicator), { key: 3 }, {
116
- default: j(() => [h(k(M), {
116
+ !e.checkbox && !e.noIndicator ? (S(), l(E(e.parts.ItemIndicator), { key: 3 }, {
117
+ default: j(() => [h(O(M), {
117
118
  class: y(e.classes.itemIndicator),
118
119
  "aria-hidden": "true"
119
120
  }, null, 8, ["class"])]),
@@ -128,7 +129,7 @@ var I = [
128
129
  "draggable"
129
130
  ]));
130
131
  }
131
- }), B = /* @__PURE__ */ g({
132
+ }), V = /* @__PURE__ */ g({
132
133
  __name: "LoadMore",
133
134
  props: {
134
135
  active: { type: Boolean },
@@ -136,19 +137,19 @@ var I = [
136
137
  },
137
138
  emits: ["load"],
138
139
  setup(e, { emit: t }) {
139
- let n = e, r = t, i = w(null), a;
140
+ let n = e, r = t, i = C(null), a;
140
141
  function o() {
141
142
  a?.disconnect(), n.active && i.value && typeof IntersectionObserver < "u" && (a = new IntersectionObserver((e) => {
142
143
  e.some((e) => e.isIntersecting) && r("load");
143
144
  }), a.observe(i.value));
144
145
  }
145
- return S(o), A(() => [n.active, n.count], o), x(() => a?.disconnect()), (e, t) => (C(), d("div", {
146
+ return x(o), A(() => [n.active, n.count], o), te(() => a?.disconnect()), (e, t) => (S(), d("div", {
146
147
  ref_key: "element",
147
148
  ref: i,
148
149
  "aria-hidden": "true"
149
150
  }, null, 512));
150
151
  }
151
- }), V = /* @__PURE__ */ g({
152
+ }), H = /* @__PURE__ */ g({
152
153
  __name: "ListOptions",
153
154
  props: {
154
155
  parts: {},
@@ -165,8 +166,8 @@ var I = [
165
166
  emits: ["loadMore"],
166
167
  setup(e, { emit: t }) {
167
168
  let n = t;
168
- return (t, r) => (C(), d(o, null, [
169
- (C(!0), d(o, null, T(e.groups, (n, r) => (C(), d(o, { key: n.label ?? `#${r}` }, [n.label === void 0 ? (C(!0), d(o, { key: 1 }, T(n.options, (n) => (C(), l(z, {
169
+ return (t, r) => (S(), d(o, null, [
170
+ (S(!0), d(o, null, w(e.groups, (n, r) => (S(), d(o, { key: n.label ?? `#${r}` }, [n.label === void 0 ? (S(!0), d(o, { key: 1 }, w(n.options, (n) => (S(), l(B, {
170
171
  key: n.key,
171
172
  parts: e.parts,
172
173
  option: n,
@@ -176,7 +177,7 @@ var I = [
176
177
  draggable: e.draggable
177
178
  }, p({ _: 2 }, [t.$slots.item ? {
178
179
  name: "item",
179
- fn: j((e) => [E(t.$slots, "item", v({ ref_for: !0 }, e))]),
180
+ fn: j((e) => [T(t.$slots, "item", v({ ref_for: !0 }, e))]),
180
181
  key: "0"
181
182
  } : void 0]), 1032, [
182
183
  "parts",
@@ -185,14 +186,14 @@ var I = [
185
186
  "checkbox",
186
187
  "no-indicator",
187
188
  "draggable"
188
- ]))), 128)) : (C(), l(D(e.parts.ItemGroup), {
189
+ ]))), 128)) : (S(), l(E(e.parts.ItemGroup), {
189
190
  key: 0,
190
191
  class: y(e.classes.group)
191
192
  }, {
192
- default: j(() => [(C(), l(D(e.parts.ItemGroupLabel), { class: y(e.classes.groupLabel) }, {
193
- default: j(() => [m(O(n.label), 1)]),
193
+ default: j(() => [(S(), l(E(e.parts.ItemGroupLabel), { class: y(e.classes.groupLabel) }, {
194
+ default: j(() => [m(D(n.label), 1)]),
194
195
  _: 2
195
- }, 1032, ["class"])), (C(!0), d(o, null, T(n.options, (n) => (C(), l(z, {
196
+ }, 1032, ["class"])), (S(!0), d(o, null, w(n.options, (n) => (S(), l(B, {
196
197
  key: n.key,
197
198
  parts: e.parts,
198
199
  option: n,
@@ -202,7 +203,7 @@ var I = [
202
203
  draggable: e.draggable
203
204
  }, p({ _: 2 }, [t.$slots.item ? {
204
205
  name: "item",
205
- fn: j((e) => [E(t.$slots, "item", v({ ref_for: !0 }, e))]),
206
+ fn: j((e) => [T(t.$slots, "item", v({ ref_for: !0 }, e))]),
206
207
  key: "0"
207
208
  } : void 0]), 1032, [
208
209
  "parts",
@@ -214,20 +215,20 @@ var I = [
214
215
  ]))), 128))]),
215
216
  _: 2
216
217
  }, 1032, ["class"]))], 64))), 128)),
217
- e.emptyText !== void 0 && !e.loading && !e.groups.length ? (C(), d("div", {
218
+ e.emptyText !== void 0 && !e.loading && !e.groups.length ? (S(), d("div", {
218
219
  key: 0,
219
220
  role: "option",
220
221
  "aria-disabled": "true",
221
222
  class: y(e.classes.empty)
222
- }, O(e.emptyText), 3)) : u("", !0),
223
- e.loading ? (C(), d("div", {
223
+ }, D(e.emptyText), 3)) : u("", !0),
224
+ e.loading ? (S(), d("div", {
224
225
  key: 1,
225
226
  class: y(e.classes.loading)
226
- }, [h(k(N), {
227
+ }, [h(O(N), {
227
228
  class: y(e.classes.loadingIcon),
228
229
  "aria-hidden": "true"
229
- }, null, 8, ["class"]), m(" " + O(e.loadingText), 1)], 2)) : u("", !0),
230
- e.hasMore ? (C(), l(B, {
230
+ }, null, 8, ["class"]), m(" " + D(e.loadingText), 1)], 2)) : u("", !0),
231
+ e.hasMore ? (S(), l(V, {
231
232
  key: 2,
232
233
  class: y(e.classes.sentinel),
233
234
  active: !e.loading,
@@ -240,14 +241,14 @@ var I = [
240
241
  ])) : u("", !0)
241
242
  ], 64));
242
243
  }
243
- }), ce = ["aria-label", "onClick"], le = [
244
+ }), le = ["aria-label", "onClick"], ue = [
244
245
  "aria-controls",
245
246
  "aria-activedescendant",
246
247
  "aria-label",
247
248
  "placeholder",
248
249
  "value",
249
250
  "onInput"
250
- ], H = /* @__PURE__ */ g({
251
+ ], U = /* @__PURE__ */ g({
251
252
  inheritAttrs: !1,
252
253
  __name: "Select",
253
254
  props: {
@@ -286,6 +287,7 @@ var I = [
286
287
  minSearchLength: {},
287
288
  pageSize: {},
288
289
  standalone: { type: Boolean },
290
+ id: {},
289
291
  classes: {}
290
292
  },
291
293
  emits: [
@@ -293,145 +295,152 @@ var I = [
293
295
  "filterChange",
294
296
  "loadMore"
295
297
  ],
296
- setup(g, { emit: x }) {
297
- let T = e(), M = g, P = t("select", ae, () => M.classes), I = x, se = te(), L = c(() => n(se)), R = c(() => P({
298
+ setup(g, { emit: te }) {
299
+ let w = e(), M = g, P = t("select", oe, () => M.classes), I = te, L = k(), R = c(() => n(L)), z = c(() => P({
298
300
  size: M.size,
299
301
  clearable: M.clearable
300
- })), z = T.select, B = c(() => ({
302
+ })), B = w.select, V = c(() => ({
301
303
  itemValue: M.itemValue,
302
304
  itemLabel: M.itemLabel,
303
305
  itemDisabled: M.itemDisabled,
304
306
  itemGroup: M.itemGroup,
305
307
  itemKeywords: M.itemKeywords,
306
308
  valueKey: M.valueKey
307
- })), H = w(""), U = r({
309
+ })), U = C(""), W = r({
308
310
  items: () => M.items,
309
311
  source: () => M.dataSource,
310
- accessors: () => B.value,
312
+ accessors: () => V.value,
311
313
  pageSize: () => M.pageSize,
312
314
  minSearchLength: () => M.minSearchLength
313
- }), { options: ue, groups: W, ordered: G } = i(() => U.items.value, () => B.value, () => M.filter && !M.manualFilter && !M.dataSource ? H.value : ""), K = c(() => [...ue.value, ...U.resolvedOptions.value]), { selected: q, keys: J, commit: Y, commitKeys: de } = a({
315
+ }), { options: de, groups: G, ordered: K } = i(() => W.items.value, () => V.value, () => M.filter && !M.manualFilter && !M.dataSource ? U.value : ""), q = c(() => [...de.value, ...W.resolvedOptions.value]), { selected: J, keys: Y, commit: X, commitKeys: fe } = a({
314
316
  multiple: !1,
315
317
  model: () => M.modelValue,
316
318
  defaultValue: M.defaultValue,
317
- accessors: () => B.value,
318
- items: K,
319
- emit: (e) => I("update:modelValue", e)
319
+ accessors: () => V.value,
320
+ items: q,
321
+ emit: (e) => I("update:modelValue", e),
322
+ check: {
323
+ component: "Select",
324
+ ready: () => !M.dataSource && !M.loading && M.items.length > 0
325
+ }
320
326
  });
321
- S(() => U.resolve(J.value, K.value)), A(J, (e) => U.resolve(e, K.value));
322
- let X = c(() => M.loading || U.loading.value), Z = c(() => M.hasMore || U.hasMore.value);
323
- function fe() {
324
- M.dataSource ? U.loadMore() : I("loadMore");
327
+ x(() => W.resolve(Y.value, q.value)), A(Y, (e) => W.resolve(e, q.value));
328
+ let Z = c(() => M.loading || W.loading.value), Q = c(() => M.hasMore || W.hasMore.value);
329
+ function pe() {
330
+ M.dataSource ? W.loadMore() : I("loadMore");
325
331
  }
326
- let Q = c(() => q.value[0]), pe = c(() => oe({
327
- items: G.value,
332
+ let $ = c(() => J.value[0]), me = c(() => ce({
333
+ items: K.value,
328
334
  itemToString: (e) => e.label,
329
335
  itemToValue: (e) => e.key,
330
336
  isItemDisabled: (e) => e.disabled
331
- })), me = ne(), he = c(() => M.emptyText ?? U.emptyText.value ?? (H.value ? T.common.noResults : T.common.empty)), $ = c(() => ({
332
- item: R.value.item(),
333
- itemText: R.value.itemText(),
334
- icon: R.value.icon(),
335
- itemIndicator: R.value.itemIndicator(),
336
- itemBody: R.value.itemBody(),
337
- itemDescription: R.value.itemDescription(),
338
- group: R.value.group(),
339
- groupLabel: R.value.groupLabel(),
340
- loading: R.value.loading(),
341
- loadingIcon: R.value.loadingIcon(),
342
- sentinel: R.value.sentinel(),
343
- empty: R.value.empty()
337
+ })), he = ne(), ge = c(() => M.emptyText ?? W.emptyText.value ?? (U.value ? w.common.noResults : w.common.empty)), _e = c(() => ({
338
+ item: z.value.item(),
339
+ itemText: z.value.itemText(),
340
+ icon: z.value.icon(),
341
+ itemIndicator: z.value.itemIndicator(),
342
+ itemBody: z.value.itemBody(),
343
+ itemDescription: z.value.itemDescription(),
344
+ group: z.value.group(),
345
+ groupLabel: z.value.groupLabel(),
346
+ loading: z.value.loading(),
347
+ loadingIcon: z.value.loadingIcon(),
348
+ sentinel: z.value.sentinel(),
349
+ empty: z.value.empty()
344
350
  }));
345
- function ge(e) {
346
- Y([]), e.focus();
351
+ function ve(e) {
352
+ X([]), e.focus();
347
353
  }
348
- function _e(e) {
349
- M.clearable && q.value.length && (e.key === "Backspace" || e.key === "Delete") && (e.preventDefault(), Y([]));
354
+ function ye(e) {
355
+ M.clearable && J.value.length && (e.key === "Backspace" || e.key === "Delete") && (e.preventDefault(), X([]));
350
356
  }
351
- function ve(e, t) {
352
- H.value = t.target.value, I("filterChange", H.value), M.dataSource && U.search(H.value), !(M.manualFilter || M.dataSource) && ee(() => {
353
- let t = G.value.find((e) => !e.disabled);
357
+ function be(e, t) {
358
+ U.value = t.target.value, I("filterChange", U.value), M.dataSource && W.search(U.value), !(M.manualFilter || M.dataSource) && ee(() => {
359
+ let t = K.value.find((e) => !e.disabled);
354
360
  t && e.setHighlightValue(t.key);
355
361
  });
356
362
  }
357
- function ye(e) {
363
+ function xe(e) {
358
364
  (e.key === " " || e.key === "Home" || e.key === "End") && e.stopPropagation();
359
365
  }
360
- function be(e) {
361
- e && U.open(), !e && H.value && (H.value = "", I("filterChange", ""), M.dataSource && U.search(""));
366
+ function Se(e) {
367
+ e && W.open(), !e && U.value && (U.value = "", I("filterChange", ""), M.dataSource && W.search(""));
362
368
  }
363
- let xe = (e) => e.highlightedItem ? e.getItemProps({ item: e.highlightedItem }).id : void 0, Se = {
369
+ let Ce = (e) => e.highlightedItem ? e.getItemProps({ item: e.highlightedItem }).id : void 0, we = {
364
370
  sameWidth: !0,
365
371
  gutter: 4
366
- };
367
- return (e, t) => (C(), l(k(F).Root, v({
368
- class: R.value.base({ class: L.value.className }),
369
- style: L.value.style,
370
- collection: pe.value,
371
- "model-value": k(J),
372
+ }, Te = se(), Ee = c(() => ae(M.id, "trigger", {
373
+ label: Te?.value.ids.label,
374
+ hiddenSelect: Te?.value.ids.control
375
+ }, M.standalone));
376
+ return (e, t) => (S(), l(O(F).Root, v({
377
+ class: z.value.base({ class: R.value.className }),
378
+ style: R.value.style,
379
+ collection: me.value,
380
+ "model-value": O(Y),
372
381
  disabled: g.disabled,
373
382
  invalid: g.invalid,
374
383
  required: g.required,
375
384
  name: g.name,
376
- positioning: Se,
385
+ positioning: we,
377
386
  composite: !g.filter
378
- }, g.standalone ? { ids: {} } : {}, {
387
+ }, Ee.value, {
379
388
  "lazy-mount": "",
380
389
  "unmount-on-exit": "",
381
- onValueChange: t[0] ||= (e) => k(de)(e.value, e.items),
382
- onOpenChange: t[1] ||= (e) => be(e.open)
390
+ onValueChange: t[0] ||= (e) => O(fe)(e.value, e.items),
391
+ onOpenChange: t[1] ||= (e) => Se(e.open)
383
392
  }), {
384
393
  default: j(() => [
385
- h(k(F).Control, b(_(g.clearable ? { class: R.value.control() } : {})), {
386
- default: j(() => [h(k(F).Trigger, v(L.value.rest, {
387
- class: R.value.trigger(),
394
+ h(O(F).Control, b(_(g.clearable ? { class: z.value.control() } : {})), {
395
+ default: j(() => [h(O(F).Trigger, v(R.value.rest, {
396
+ class: z.value.trigger(),
388
397
  "aria-busy": g.loading || void 0,
389
- onKeydown: _e
398
+ onKeydown: ye
390
399
  }), {
391
- default: j(() => [f("span", { class: y(R.value.value()) }, [e.$slots.value && Q.value ? E(e.$slots, "value", { item: Q.value.item }, void 0, void 0, 0) : (C(), d(o, { key: 1 }, [Q.value?.icon ? (C(), l(D(Q.value.icon), {
400
+ default: j(() => [f("span", { class: y(z.value.value()) }, [e.$slots.value && $.value ? T(e.$slots, "value", { item: $.value.item }, void 0, void 0, 0) : (S(), d(o, { key: 1 }, [$.value?.icon ? (S(), l(E($.value.icon), {
392
401
  key: 0,
393
- class: y(R.value.icon()),
402
+ class: y(z.value.icon()),
394
403
  "aria-hidden": "true"
395
- }, null, 8, ["class"])) : u("", !0), h(k(F).ValueText, { placeholder: g.placeholder ?? k(T).common.placeholder }, p({ _: 2 }, [Q.value ? {
404
+ }, null, 8, ["class"])) : u("", !0), h(O(F).ValueText, { placeholder: g.placeholder ?? O(w).common.placeholder }, p({ _: 2 }, [$.value ? {
396
405
  name: "default",
397
- fn: j(() => [m(O(Q.value.label), 1)]),
406
+ fn: j(() => [m(D($.value.label), 1)]),
398
407
  key: "0"
399
- } : void 0]), 1032, ["placeholder"])], 64))], 2), h(k(F).Indicator, { class: y(R.value.indicator()) }, {
400
- default: j(() => [g.loading ? (C(), l(k(N), {
408
+ } : void 0]), 1032, ["placeholder"])], 64))], 2), h(O(F).Indicator, { class: y(z.value.indicator()) }, {
409
+ default: j(() => [g.loading ? (S(), l(O(N), {
401
410
  key: 0,
402
- class: y(R.value.spinner()),
411
+ class: y(z.value.spinner()),
403
412
  "aria-hidden": "true"
404
- }, null, 8, ["class"])) : (C(), l(k(re), {
413
+ }, null, 8, ["class"])) : (S(), l(O(re), {
405
414
  key: 1,
406
- class: y(R.value.indicatorIcon()),
415
+ class: y(z.value.indicatorIcon()),
407
416
  "aria-hidden": "true"
408
417
  }, null, 8, ["class"]))]),
409
418
  _: 1
410
419
  }, 8, ["class"])]),
411
420
  _: 3
412
- }, 16, ["class", "aria-busy"]), g.clearable ? (C(), l(k(F).Context, { key: 0 }, {
413
- default: j((e) => [Q.value && !e.disabled ? (C(), d("button", {
421
+ }, 16, ["class", "aria-busy"]), g.clearable ? (S(), l(O(F).Context, { key: 0 }, {
422
+ default: j((e) => [$.value && !e.disabled ? (S(), d("button", {
414
423
  key: 0,
415
424
  type: "button",
416
425
  tabindex: "-1",
417
- class: y(R.value.clear()),
418
- "aria-label": k(z).clear,
419
- onClick: (t) => ge(e)
420
- }, [h(k(ie), {
421
- class: y(R.value.clearIcon()),
426
+ class: y(z.value.clear()),
427
+ "aria-label": O(B).clear,
428
+ onClick: (t) => ve(e)
429
+ }, [h(O(ie), {
430
+ class: y(z.value.clearIcon()),
422
431
  "aria-hidden": "true"
423
- }, null, 8, ["class"])], 10, ce)) : u("", !0)]),
432
+ }, null, 8, ["class"])], 10, le)) : u("", !0)]),
424
433
  _: 1
425
434
  })) : u("", !0)]),
426
435
  _: 3
427
436
  }, 16),
428
- (C(), l(s, { to: "body" }, [h(k(F).Positioner, null, {
429
- default: j(() => [h(k(F).Content, {
430
- class: y(R.value.content()),
431
- "aria-busy": X.value || void 0,
432
- "aria-label": g.filter ? L.value.rest["aria-label"] : void 0
437
+ (S(), l(s, { to: "body" }, [h(O(F).Positioner, null, {
438
+ default: j(() => [h(O(F).Content, {
439
+ class: y(z.value.content()),
440
+ "aria-busy": Z.value || void 0,
441
+ "aria-label": g.filter ? R.value.rest["aria-label"] : void 0
433
442
  }, {
434
- default: j(() => [g.filter ? (C(), d(o, { key: 0 }, [f("div", { class: y(R.value.header()) }, [h(k(F).Context, null, {
443
+ default: j(() => [g.filter ? (S(), d(o, { key: 0 }, [f("div", { class: y(z.value.header()) }, [h(O(F).Context, null, {
435
444
  default: j((e) => [f("input", {
436
445
  type: "text",
437
446
  role: "combobox",
@@ -439,32 +448,32 @@ var I = [
439
448
  "aria-autocomplete": "list",
440
449
  "aria-expanded": "true",
441
450
  "data-autofocus": "",
442
- "aria-controls": k(me),
443
- "aria-activedescendant": xe(e),
444
- "aria-label": k(z).filter,
445
- placeholder: k(T).combobox.search,
446
- value: H.value,
447
- class: y(R.value.search()),
448
- onInput: (t) => ve(e, t),
449
- onKeydown: ye
450
- }, null, 42, le)]),
451
+ "aria-controls": O(he),
452
+ "aria-activedescendant": Ce(e),
453
+ "aria-label": O(B).filter,
454
+ placeholder: O(w).combobox.search,
455
+ value: U.value,
456
+ class: y(z.value.search()),
457
+ onInput: (t) => be(e, t),
458
+ onKeydown: xe
459
+ }, null, 42, ue)]),
451
460
  _: 1
452
- })], 2), h(k(F).List, {
453
- id: k(me),
454
- class: y(R.value.list())
461
+ })], 2), h(O(F).List, {
462
+ id: O(he),
463
+ class: y(z.value.list())
455
464
  }, {
456
- default: j(() => [h(V, {
457
- parts: k(F),
458
- groups: k(W),
459
- classes: $.value,
460
- loading: X.value,
461
- "loading-text": g.loadingText ?? k(T).common.loading,
462
- "has-more": Z.value,
463
- "empty-text": he.value,
464
- onLoadMore: fe
465
+ default: j(() => [h(H, {
466
+ parts: O(F),
467
+ groups: O(G),
468
+ classes: _e.value,
469
+ loading: Z.value,
470
+ "loading-text": g.loadingText ?? O(w).common.loading,
471
+ "has-more": Q.value,
472
+ "empty-text": ge.value,
473
+ onLoadMore: pe
465
474
  }, p({ _: 2 }, [e.$slots.item ? {
466
475
  name: "item",
467
- fn: j((t) => [E(e.$slots, "item", b(_(t)))]),
476
+ fn: j((t) => [T(e.$slots, "item", b(_(t)))]),
468
477
  key: "0"
469
478
  } : void 0]), 1032, [
470
479
  "parts",
@@ -476,19 +485,19 @@ var I = [
476
485
  "empty-text"
477
486
  ])]),
478
487
  _: 3
479
- }, 8, ["id", "class"])], 64)) : (C(), l(V, {
488
+ }, 8, ["id", "class"])], 64)) : (S(), l(H, {
480
489
  key: 1,
481
- parts: k(F),
482
- groups: k(W),
483
- classes: $.value,
484
- loading: X.value,
485
- "loading-text": g.loadingText ?? k(T).common.loading,
486
- "has-more": Z.value,
487
- "empty-text": he.value,
488
- onLoadMore: fe
490
+ parts: O(F),
491
+ groups: O(G),
492
+ classes: _e.value,
493
+ loading: Z.value,
494
+ "loading-text": g.loadingText ?? O(w).common.loading,
495
+ "has-more": Q.value,
496
+ "empty-text": ge.value,
497
+ onLoadMore: pe
489
498
  }, p({ _: 2 }, [e.$slots.item ? {
490
499
  name: "item",
491
- fn: j((t) => [E(e.$slots, "item", b(_(t)))]),
500
+ fn: j((t) => [T(e.$slots, "item", b(_(t)))]),
492
501
  key: "0"
493
502
  } : void 0]), 1032, [
494
503
  "parts",
@@ -507,12 +516,12 @@ var I = [
507
516
  ])]),
508
517
  _: 3
509
518
  })])),
510
- h(k(F).HiddenSelect),
511
- g.dataSource ? (C(), d("span", {
519
+ h(O(F).HiddenSelect),
520
+ g.dataSource ? (S(), d("span", {
512
521
  key: 0,
513
522
  role: "status",
514
- class: y(R.value.status())
515
- }, O(k(U).announcement.value), 3)) : u("", !0)
523
+ class: y(z.value.status())
524
+ }, D(O(W).announcement.value), 3)) : u("", !0)
516
525
  ]),
517
526
  _: 3
518
527
  }, 16, [
@@ -529,4 +538,4 @@ var I = [
529
538
  }
530
539
  });
531
540
  //#endregion
532
- export { L as i, V as n, B as r, H as t };
541
+ export { R as i, H as n, V as r, U as t };