iryx-ui 0.10.2 → 0.12.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 (54) hide show
  1. package/README.md +593 -496
  2. package/dist/component-names.d.ts +1 -1
  3. package/dist/component-names.js +1 -1
  4. package/dist/components/Alert.vue_vue_type_script_setup_true_lang.js +42 -42
  5. package/dist/components/Banner.vue_vue_type_script_setup_true_lang.js +40 -40
  6. package/dist/components/BarChart.vue.d.ts +13 -0
  7. package/dist/components/BarChart.vue_vue_type_script_setup_true_lang.js +174 -132
  8. package/dist/components/Breadcrumb.vue_vue_type_script_setup_true_lang.js +28 -28
  9. package/dist/components/Button.vue_vue_type_script_setup_true_lang.js +14 -14
  10. package/dist/components/Checkbox.vue_vue_type_script_setup_true_lang.js +37 -30
  11. package/dist/components/Combobox.vue_vue_type_script_setup_true_lang.js +62 -60
  12. package/dist/components/DatePicker.vue_vue_type_script_setup_true_lang.js +65 -65
  13. package/dist/components/DateRangePicker.vue_vue_type_script_setup_true_lang.js +74 -74
  14. package/dist/components/Dialog.vue_vue_type_script_setup_true_lang.js +34 -34
  15. package/dist/components/Drawer.js +5 -0
  16. package/dist/components/Drawer.vue.d.ts +94 -0
  17. package/dist/components/Drawer.vue_vue_type_script_setup_true_lang.js +144 -0
  18. package/dist/components/DropdownMenuItems.vue_vue_type_script_setup_true_lang.js +42 -42
  19. package/dist/components/FileUpload.vue_vue_type_script_setup_true_lang.js +77 -77
  20. package/dist/components/Icon.vue_vue_type_script_setup_true_lang.js +11 -11
  21. package/dist/components/Input.vue_vue_type_script_setup_true_lang.js +33 -33
  22. package/dist/components/NumberInput.vue_vue_type_script_setup_true_lang.js +68 -66
  23. package/dist/components/Pagination.vue.d.ts +1 -1
  24. package/dist/components/Pagination.vue_vue_type_script_setup_true_lang.js +37 -37
  25. package/dist/components/PasswordInput.vue_vue_type_script_setup_true_lang.js +37 -37
  26. package/dist/components/Progress.vue_vue_type_script_setup_true_lang.js +34 -31
  27. package/dist/components/Select.vue_vue_type_script_setup_true_lang.js +47 -45
  28. package/dist/components/Stat.vue_vue_type_script_setup_true_lang.js +27 -27
  29. package/dist/components/Stepper.vue_vue_type_script_setup_true_lang.js +38 -38
  30. package/dist/components/Switch.vue_vue_type_script_setup_true_lang.js +9 -2
  31. package/dist/components/Table.vue_vue_type_script_setup_true_lang.js +87 -87
  32. package/dist/components/Toaster.vue_vue_type_script_setup_true_lang.js +41 -41
  33. package/dist/components/index.d.ts +1 -0
  34. package/dist/components/index.js +54 -52
  35. package/dist/composables/date.js +12 -15
  36. package/dist/index.d.ts +1 -0
  37. package/dist/index.js +55 -54
  38. package/dist/theme/drawer.d.ts +110 -0
  39. package/dist/theme/drawer.js +100 -0
  40. package/dist/theme/index.d.ts +1 -0
  41. package/package.json +3 -2
  42. package/theme.css +114 -0
  43. package/dist/node_modules/.pnpm/@hugeicons_core-free-icons@4.2.3/node_modules/@hugeicons/core-free-icons/dist/esm/index.js +0 -377
  44. package/dist/node_modules/.pnpm/@hugeicons_vue@1.0.7_vue@3.5.35_typescript@6.0.3_/node_modules/@hugeicons/vue/dist/esm/_virtual/_plugin-vue_export-helper.js +0 -8
  45. package/dist/node_modules/.pnpm/@hugeicons_vue@1.0.7_vue@3.5.35_typescript@6.0.3_/node_modules/@hugeicons/vue/dist/esm/components/HugeiconsIcon.vue.js +0 -25
  46. package/dist/node_modules/.pnpm/@hugeicons_vue@1.0.7_vue@3.5.35_typescript@6.0.3_/node_modules/@hugeicons/vue/dist/esm/components/HugeiconsIcon.vue2.js +0 -63
  47. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/CalendarDate.js +0 -122
  48. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/DateFormatter.js +0 -84
  49. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/calendars/GregorianCalendar.js +0 -91
  50. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/conversion.js +0 -107
  51. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/manipulation.js +0 -159
  52. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/queries.js +0 -29
  53. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/string.js +0 -37
  54. package/dist/node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/utils.js +0 -6
@@ -1,11 +1,12 @@
1
- import { MinusSignIcon as e, Tick02Icon as t } from "../node_modules/.pnpm/@hugeicons_core-free-icons@4.2.3/node_modules/@hugeicons/core-free-icons/dist/esm/index.js";
2
- import { useIryxUiConfig as n } from "../config.js";
3
- import r from "./Icon.js";
4
- import { checkboxTheme as i } from "../theme/checkbox.js";
5
- import { computed as a, createBlock as o, createCommentVNode as s, createElementBlock as c, createElementVNode as l, createTextVNode as u, createVNode as d, defineComponent as f, mergeProps as p, normalizeClass as m, openBlock as h, renderSlot as g, toDisplayString as _, unref as v, withCtx as y } from "vue";
1
+ import { useIryxUiConfig as e } from "../config.js";
2
+ import t from "./Icon.js";
3
+ import { checkboxTheme as n } from "../theme/checkbox.js";
4
+ import { computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createTextVNode as c, createVNode as l, defineComponent as u, mergeProps as d, normalizeClass as f, openBlock as p, renderSlot as m, toDisplayString as h, unref as g, withCtx as _ } from "vue";
5
+ import { MinusSignIcon as v, Tick02Icon as y } from "@hugeicons/core-free-icons";
6
6
  import { CheckboxIndicator as b, CheckboxRoot as x, Label as S, useForwardPropsEmits as C, useId as w } from "reka-ui";
7
7
  //#region src/components/Checkbox.vue?vue&type=script&setup=true&lang.ts
8
- var T = ["id"], E = /*@__PURE__*/ f({
8
+ var T = ["id"], E = /*@__PURE__*/ u({
9
+ inheritAttrs: !1,
9
10
  __name: "Checkbox",
10
11
  props: {
11
12
  label: {},
@@ -30,28 +31,31 @@ var T = ["id"], E = /*@__PURE__*/ f({
30
31
  required: { type: Boolean }
31
32
  },
32
33
  emits: ["update:modelValue"],
33
- setup(f, { emit: E }) {
34
- let D = f, O = E, k = C(a(() => {
34
+ setup(u, { emit: E }) {
35
+ let D = u, O = E, k = C(r(() => {
35
36
  let { label: e, description: t, size: n, id: r, unstyled: i, class: a, ui: o, ...s } = D;
36
37
  return s;
37
- }), O), A = w(), j = a(() => D.id ?? A), M = a(() => !!(D.label || D.description)), N = n(), P = a(() => D.unstyled ?? N.unstyled), F = a(() => i({
38
+ }), O), A = w(), j = r(() => D.id ?? A), M = r(() => !!(D.label || D.description)), N = e(), P = r(() => D.unstyled ?? N.unstyled), F = r(() => n({
38
39
  size: D.size,
39
40
  withText: M.value
40
- })), I = a(() => P.value ? D.ui?.wrapper : F.value.wrapper({ class: D.ui?.wrapper })), L = a(() => P.value ? [D.ui?.root, D.class] : F.value.root({ class: [D.ui?.root, D.class] })), R = a(() => P.value ? D.ui?.indicator : F.value.indicator({ class: D.ui?.indicator })), z = a(() => P.value ? D.ui?.content : F.value.content({ class: D.ui?.content })), B = a(() => P.value ? D.ui?.label : F.value.label({ class: D.ui?.label })), V = a(() => P.value ? D.ui?.description : F.value.description({ class: D.ui?.description }));
41
- return (n, i) => M.value ? (h(), c("div", {
41
+ })), I = r(() => P.value ? D.ui?.wrapper : F.value.wrapper({ class: D.ui?.wrapper })), L = r(() => P.value ? [D.ui?.root, D.class] : F.value.root({ class: [D.ui?.root, D.class] })), R = r(() => P.value ? D.ui?.indicator : F.value.indicator({ class: D.ui?.indicator })), z = r(() => P.value ? D.ui?.content : F.value.content({ class: D.ui?.content })), B = r(() => P.value ? D.ui?.label : F.value.label({ class: D.ui?.label })), V = r(() => P.value ? D.ui?.description : F.value.description({ class: D.ui?.description }));
42
+ return (e, n) => M.value ? (p(), o("div", {
42
43
  key: 0,
43
- class: m(I.value)
44
- }, [d(v(x), p({ id: j.value }, v(k), {
44
+ class: f(I.value)
45
+ }, [l(g(x), d({ id: j.value }, {
46
+ ...g(k),
47
+ ...e.$attrs
48
+ }, {
45
49
  "aria-describedby": D.description ? `${j.value}-description` : void 0,
46
50
  class: L.value
47
51
  }), {
48
- default: y(() => [d(v(b), { class: m(R.value) }, {
49
- default: y(() => [g(n.$slots, "default", {}, () => [D.modelValue === "indeterminate" ? (h(), o(r, {
52
+ default: _(() => [l(g(b), { class: f(R.value) }, {
53
+ default: _(() => [m(e.$slots, "default", {}, () => [D.modelValue === "indeterminate" ? (p(), i(t, {
50
54
  key: 0,
51
- icon: v(e)
52
- }, null, 8, ["icon"])) : (h(), o(r, {
55
+ icon: g(v)
56
+ }, null, 8, ["icon"])) : (p(), i(t, {
53
57
  key: 1,
54
- icon: v(t)
58
+ icon: g(y)
55
59
  }, null, 8, ["icon"]))])]),
56
60
  _: 3
57
61
  }, 8, ["class"])]),
@@ -60,27 +64,30 @@ var T = ["id"], E = /*@__PURE__*/ f({
60
64
  "id",
61
65
  "aria-describedby",
62
66
  "class"
63
- ]), l("div", { class: m(z.value) }, [d(v(S), {
67
+ ]), s("div", { class: f(z.value) }, [l(g(S), {
64
68
  for: j.value,
65
- class: m(B.value)
69
+ class: f(B.value)
66
70
  }, {
67
- default: y(() => [g(n.$slots, "label", {}, () => [u(_(D.label), 1)])]),
71
+ default: _(() => [m(e.$slots, "label", {}, () => [c(h(D.label), 1)])]),
68
72
  _: 3
69
- }, 8, ["for", "class"]), D.description || n.$slots.description ? (h(), c("p", {
73
+ }, 8, ["for", "class"]), D.description || e.$slots.description ? (p(), o("p", {
70
74
  key: 0,
71
75
  id: `${j.value}-description`,
72
- class: m(V.value)
73
- }, [g(n.$slots, "description", {}, () => [u(_(D.description), 1)])], 10, T)) : s("", !0)], 2)], 2)) : (h(), o(v(x), p({
76
+ class: f(V.value)
77
+ }, [m(e.$slots, "description", {}, () => [c(h(D.description), 1)])], 10, T)) : a("", !0)], 2)], 2)) : (p(), i(g(x), d({
74
78
  key: 1,
75
79
  id: D.id
76
- }, v(k), { class: L.value }), {
77
- default: y(() => [d(v(b), { class: m(R.value) }, {
78
- default: y(() => [g(n.$slots, "default", {}, () => [D.modelValue === "indeterminate" ? (h(), o(r, {
80
+ }, {
81
+ ...g(k),
82
+ ...e.$attrs
83
+ }, { class: L.value }), {
84
+ default: _(() => [l(g(b), { class: f(R.value) }, {
85
+ default: _(() => [m(e.$slots, "default", {}, () => [D.modelValue === "indeterminate" ? (p(), i(t, {
79
86
  key: 0,
80
- icon: v(e)
81
- }, null, 8, ["icon"])) : (h(), o(r, {
87
+ icon: g(v)
88
+ }, null, 8, ["icon"])) : (p(), i(t, {
82
89
  key: 1,
83
- icon: v(t)
90
+ icon: g(y)
84
91
  }, null, 8, ["icon"]))])]),
85
92
  _: 3
86
93
  }, 8, ["class"])]),
@@ -1,12 +1,13 @@
1
- import { ArrowDown01Icon as e, Tick02Icon as t } from "../node_modules/.pnpm/@hugeicons_core-free-icons@4.2.3/node_modules/@hugeicons/core-free-icons/dist/esm/index.js";
2
- import { useIryxUiConfig as n } from "../config.js";
3
- import r from "./Icon.js";
4
- import { useFormField as i } from "../composables/form.js";
1
+ import { useIryxUiConfig as e } from "../config.js";
2
+ import t from "./Icon.js";
3
+ import { useFormField as n } from "../composables/form.js";
5
4
  import { comboboxTheme as ee } from "../theme/combobox.js";
6
- import { Fragment as a, computed as o, createBlock as s, createCommentVNode as c, createElementBlock as l, createTextVNode as u, createVNode as d, defineComponent as f, mergeProps as p, normalizeClass as m, openBlock as h, ref as g, renderList as _, renderSlot as v, toDisplayString as y, unref as b, vShow as x, withCtx as S, withDirectives as te } from "vue";
7
- import { ComboboxAnchor as ne, ComboboxContent as re, ComboboxEmpty as ie, ComboboxGroup as ae, ComboboxInput as oe, ComboboxItem as C, ComboboxItemIndicator as w, ComboboxLabel as T, ComboboxPortal as se, ComboboxRoot as E, ComboboxTrigger as D, ComboboxViewport as O, ComboboxVirtualizer as k, useFilter as A, useForwardPropsEmits as j } from "reka-ui";
5
+ import { Fragment as r, computed as i, createBlock as a, createCommentVNode as o, createElementBlock as s, createTextVNode as c, createVNode as l, defineComponent as u, mergeProps as d, normalizeClass as f, openBlock as p, ref as m, renderList as h, renderSlot as g, toDisplayString as _, unref as v, vShow as te, withCtx as y, withDirectives as b } from "vue";
6
+ import { ArrowDown01Icon as x, Tick02Icon as S } from "@hugeicons/core-free-icons";
7
+ import { ComboboxAnchor as ne, ComboboxContent as re, ComboboxEmpty as ie, ComboboxGroup as ae, ComboboxInput as oe, ComboboxItem as C, ComboboxItemIndicator as w, ComboboxLabel as se, ComboboxPortal as T, ComboboxRoot as E, ComboboxTrigger as D, ComboboxViewport as O, ComboboxVirtualizer as k, useFilter as A, useForwardPropsEmits as j } from "reka-ui";
8
8
  //#region src/components/Combobox.vue?vue&type=script&setup=true&lang.ts
9
- var M = /*@__PURE__*/ f({
9
+ var M = /*@__PURE__*/ u({
10
+ inheritAttrs: !1,
10
11
  __name: "Combobox",
11
12
  props: {
12
13
  items: {},
@@ -73,9 +74,9 @@ var M = /*@__PURE__*/ f({
73
74
  "update:open",
74
75
  "create"
75
76
  ],
76
- setup(f, { emit: M }) {
77
- let N = f, P = M, F = j(o(() => {
78
- let { items: e, placeholder: t, size: n, invalid: r, id: i, emptyText: ee, create: a, createLabel: o, virtual: s, estimateSize: c, overscan: l, unstyled: u, class: d, ui: f, ...p } = N;
77
+ setup(u, { emit: M }) {
78
+ let N = u, P = M, F = j(i(() => {
79
+ let { items: e, placeholder: t, size: n, invalid: ee, id: r, emptyText: i, create: a, createLabel: o, virtual: s, estimateSize: c, overscan: l, unstyled: u, class: d, ui: f, ...p } = N;
79
80
  return p;
80
81
  }), P);
81
82
  function I(e) {
@@ -87,17 +88,17 @@ var M = /*@__PURE__*/ f({
87
88
  function L(e) {
88
89
  return typeof e != "string" && "items" in e;
89
90
  }
90
- let R = o(() => {
91
+ let R = i(() => {
91
92
  let e = N.items ?? [];
92
93
  return e.some(L) ? e.map((e) => L(e) ? e : {
93
94
  label: "",
94
95
  items: [e]
95
96
  }) : void 0;
96
- }), z = o(() => (N.items ?? []).flatMap((e) => L(e) ? e.items.map(I) : [I(e)])), B = o(() => !!N.virtual), V = g(""), H = g("");
97
+ }), z = i(() => (N.items ?? []).flatMap((e) => L(e) ? e.items.map(I) : [I(e)])), B = i(() => !!N.virtual), V = m(""), H = m("");
97
98
  function U(e) {
98
99
  H.value = e.target.value;
99
100
  }
100
- let { contains: W } = A({ sensitivity: "base" }), G = o(() => {
101
+ let { contains: W } = A({ sensitivity: "base" }), G = i(() => {
101
102
  let e = H.value.trim();
102
103
  return e ? z.value.filter((t) => W(t.label, e)) : z.value;
103
104
  });
@@ -111,7 +112,7 @@ var M = /*@__PURE__*/ f({
111
112
  document.activeElement === t && t.select();
112
113
  }), H.value = "";
113
114
  }
114
- let K = o(() => {
115
+ let K = i(() => {
115
116
  let e = H.value.trim();
116
117
  return !!N.create && e.length > 0 && !z.value.some((t) => t.label.toLowerCase() === e.toLowerCase());
117
118
  });
@@ -121,7 +122,7 @@ var M = /*@__PURE__*/ f({
121
122
  bubbles: !0
122
123
  }));
123
124
  }
124
- let J = i(), ue = o(() => N.id ?? J?.id.value), Y = o(() => N.invalid ?? J?.invalid.value ?? !1), de = n(), X = o(() => N.unstyled ?? de.unstyled), Z = o(() => ee({
125
+ let J = n(), ue = i(() => N.id ?? J?.id.value), Y = i(() => N.invalid ?? J?.invalid.value ?? !1), de = e(), X = i(() => N.unstyled ?? de.unstyled), Z = i(() => ee({
125
126
  size: N.size,
126
127
  invalid: Y.value,
127
128
  disabled: N.disabled
@@ -130,70 +131,71 @@ var M = /*@__PURE__*/ f({
130
131
  let n = N.ui?.[e];
131
132
  return X.value ? [n, t] : Z.value[e]({ class: [n, t] });
132
133
  }
133
- let $ = o(() => X.value ? void 0 : Z.value.itemIndicator());
134
- return (n, i) => (h(), s(b(E), p(b(F), {
134
+ let $ = i(() => X.value ? void 0 : Z.value.itemIndicator());
135
+ return (e, n) => (p(), a(v(E), d(v(F), {
135
136
  "open-on-click": "",
136
137
  class: "contents"
137
138
  }), {
138
- default: S(() => [d(b(ne), { class: m(Q("anchor", N.class)) }, {
139
- default: S(() => [d(b(oe), {
139
+ default: y(() => [l(v(ne), { class: f(Q("anchor", N.class)) }, {
140
+ default: y(() => [l(v(oe), d({
140
141
  id: ue.value,
141
142
  modelValue: V.value,
142
- "onUpdate:modelValue": i[0] ||= (e) => V.value = e,
143
+ "onUpdate:modelValue": n[0] ||= (e) => V.value = e
144
+ }, e.$attrs, {
143
145
  placeholder: N.placeholder,
144
146
  "display-value": ce,
145
147
  "aria-invalid": Y.value || void 0,
146
- "aria-describedby": b(J)?.describedBy.value,
147
- class: m(Q("input")),
148
+ "aria-describedby": v(J)?.describedBy.value,
149
+ class: Q("input"),
148
150
  onFocus: le,
149
151
  onInput: U
150
- }, null, 8, [
152
+ }), null, 16, [
151
153
  "id",
152
154
  "modelValue",
153
155
  "placeholder",
154
156
  "aria-invalid",
155
157
  "aria-describedby",
156
158
  "class"
157
- ]), d(b(D), { class: m(Q("trigger")) }, {
158
- default: S(() => [d(r, { icon: b(e) }, null, 8, ["icon"])]),
159
+ ]), l(v(D), { class: f(Q("trigger")) }, {
160
+ default: y(() => [l(t, { icon: v(x) }, null, 8, ["icon"])]),
159
161
  _: 1
160
162
  }, 8, ["class"])]),
161
163
  _: 1
162
- }, 8, ["class"]), d(b(se), null, {
163
- default: S(() => [d(b(re), {
164
- class: m(Q("content")),
164
+ }, 8, ["class"]), l(v(T), null, {
165
+ default: y(() => [l(v(re), {
166
+ class: f(Q("content")),
165
167
  position: "popper",
166
168
  "side-offset": 4
167
169
  }, {
168
- default: S(() => [d(b(O), { class: m(Q("viewport")) }, {
169
- default: S(() => [
170
- B.value ? te((h(), l("div", {
170
+ default: y(() => [l(v(O), { class: f(Q("viewport")) }, {
171
+ default: y(() => [
172
+ B.value ? b((p(), s("div", {
171
173
  key: 0,
172
- class: m(Q("empty"))
173
- }, [v(n.$slots, "empty", { query: H.value }, () => [u(y(N.emptyText), 1)])], 2)), [[x, !K.value && G.value.length === 0]]) : K.value ? c("", !0) : (h(), s(b(ie), {
174
+ class: f(Q("empty"))
175
+ }, [g(e.$slots, "empty", { query: H.value }, () => [c(_(N.emptyText), 1)])], 2)), [[te, !K.value && G.value.length === 0]]) : K.value ? o("", !0) : (p(), a(v(ie), {
174
176
  key: 1,
175
- class: m(Q("empty"))
177
+ class: f(Q("empty"))
176
178
  }, {
177
- default: S(() => [v(n.$slots, "empty", { query: H.value }, () => [u(y(N.emptyText), 1)])]),
179
+ default: y(() => [g(e.$slots, "empty", { query: H.value }, () => [c(_(N.emptyText), 1)])]),
178
180
  _: 3
179
181
  }, 8, ["class"])),
180
- v(n.$slots, "default", {}, () => [B.value ? (h(), s(b(k), {
182
+ g(e.$slots, "default", {}, () => [B.value ? (p(), a(v(k), {
181
183
  key: 0,
182
184
  options: G.value,
183
185
  "estimate-size": N.estimateSize,
184
186
  overscan: N.overscan,
185
187
  "text-content": (e) => e.label
186
188
  }, {
187
- default: S(({ option: e }) => [d(b(C), {
189
+ default: y(({ option: e }) => [l(v(C), {
188
190
  value: e.value,
189
191
  "text-value": e.label,
190
192
  disabled: e.disabled,
191
- class: m(Q("item"))
193
+ class: f(Q("item"))
192
194
  }, {
193
- default: S(() => [d(b(w), { class: m($.value) }, {
194
- default: S(() => [d(r, { icon: b(t) }, null, 8, ["icon"])]),
195
+ default: y(() => [l(v(w), { class: f($.value) }, {
196
+ default: y(() => [l(t, { icon: v(S) }, null, 8, ["icon"])]),
195
197
  _: 1
196
- }, 8, ["class"]), u(" " + y(e.label), 1)]),
198
+ }, 8, ["class"]), c(" " + _(e.label), 1)]),
197
199
  _: 2
198
200
  }, 1032, [
199
201
  "value",
@@ -207,27 +209,27 @@ var M = /*@__PURE__*/ f({
207
209
  "estimate-size",
208
210
  "overscan",
209
211
  "text-content"
210
- ])) : R.value ? (h(!0), l(a, { key: 1 }, _(R.value, (e, n) => (h(), s(b(ae), {
212
+ ])) : R.value ? (p(!0), s(r, { key: 1 }, h(R.value, (e, n) => (p(), a(v(ae), {
211
213
  key: e.label || n,
212
- class: m(Q("group"))
214
+ class: f(Q("group"))
213
215
  }, {
214
- default: S(() => [e.label ? (h(), s(b(T), {
216
+ default: y(() => [e.label ? (p(), a(v(se), {
215
217
  key: 0,
216
- class: m(Q("groupLabel"))
218
+ class: f(Q("groupLabel"))
217
219
  }, {
218
- default: S(() => [u(y(e.label), 1)]),
220
+ default: y(() => [c(_(e.label), 1)]),
219
221
  _: 2
220
- }, 1032, ["class"])) : c("", !0), (h(!0), l(a, null, _(e.items, (e) => (h(), s(b(C), {
222
+ }, 1032, ["class"])) : o("", !0), (p(!0), s(r, null, h(e.items, (e) => (p(), a(v(C), {
221
223
  key: typeof e == "string" ? e : e.value,
222
224
  value: typeof e == "string" ? e : e.value,
223
225
  "text-value": typeof e == "string" ? e : e.label,
224
226
  disabled: typeof e == "string" ? void 0 : e.disabled,
225
- class: m(Q("item"))
227
+ class: f(Q("item"))
226
228
  }, {
227
- default: S(() => [d(b(w), { class: m($.value) }, {
228
- default: S(() => [d(r, { icon: b(t) }, null, 8, ["icon"])]),
229
+ default: y(() => [l(v(w), { class: f($.value) }, {
230
+ default: y(() => [l(t, { icon: v(S) }, null, 8, ["icon"])]),
229
231
  _: 1
230
- }, 8, ["class"]), u(" " + y(typeof e == "string" ? e : e.label), 1)]),
232
+ }, 8, ["class"]), c(" " + _(typeof e == "string" ? e : e.label), 1)]),
231
233
  _: 2
232
234
  }, 1032, [
233
235
  "value",
@@ -236,17 +238,17 @@ var M = /*@__PURE__*/ f({
236
238
  "class"
237
239
  ]))), 128))]),
238
240
  _: 2
239
- }, 1032, ["class"]))), 128)) : (h(!0), l(a, { key: 2 }, _(z.value, (e) => (h(), s(b(C), {
241
+ }, 1032, ["class"]))), 128)) : (p(!0), s(r, { key: 2 }, h(z.value, (e) => (p(), a(v(C), {
240
242
  key: e.value,
241
243
  value: e.value,
242
244
  "text-value": e.label,
243
245
  disabled: e.disabled,
244
- class: m(Q("item"))
246
+ class: f(Q("item"))
245
247
  }, {
246
- default: S(() => [d(b(w), { class: m($.value) }, {
247
- default: S(() => [d(r, { icon: b(t) }, null, 8, ["icon"])]),
248
+ default: y(() => [l(v(w), { class: f($.value) }, {
249
+ default: y(() => [l(t, { icon: v(S) }, null, 8, ["icon"])]),
248
250
  _: 1
249
- }, 8, ["class"]), u(" " + y(e.label), 1)]),
251
+ }, 8, ["class"]), c(" " + _(e.label), 1)]),
250
252
  _: 2
251
253
  }, 1032, [
252
254
  "value",
@@ -254,21 +256,21 @@ var M = /*@__PURE__*/ f({
254
256
  "disabled",
255
257
  "class"
256
258
  ]))), 128))]),
257
- K.value ? (h(), s(b(C), {
259
+ K.value ? (p(), a(v(C), {
258
260
  key: H.value,
259
261
  value: H.value,
260
262
  "data-create": "",
261
263
  "text-value": H.value,
262
- class: m(Q("item")),
264
+ class: f(Q("item")),
263
265
  onSelect: q
264
266
  }, {
265
- default: S(() => [v(n.$slots, "create", { query: H.value }, () => [u(y(N.createLabel(H.value.trim())), 1)])]),
267
+ default: y(() => [g(e.$slots, "create", { query: H.value }, () => [c(_(N.createLabel(H.value.trim())), 1)])]),
266
268
  _: 3
267
269
  }, 8, [
268
270
  "value",
269
271
  "text-value",
270
272
  "class"
271
- ])) : c("", !0)
273
+ ])) : o("", !0)
272
274
  ]),
273
275
  _: 3
274
276
  }, 8, ["class"])]),
@@ -1,20 +1,20 @@
1
- import { ArrowLeft01Icon as e, ArrowRight01Icon as t, Calendar03Icon as n } from "../node_modules/.pnpm/@hugeicons_core-free-icons@4.2.3/node_modules/@hugeicons/core-free-icons/dist/esm/index.js";
2
- import { useIryxUiConfig as r } from "../config.js";
3
- import i from "./Icon.js";
4
- import { useFormField as a } from "../composables/form.js";
5
- import { formatIsoDate as o, isoToday as ee, toCalendarDate as s, toIsoDate as c } from "../composables/date.js";
6
- import { datePickerTheme as l } from "../theme/date-picker.js";
7
- import { Fragment as u, computed as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createTextVNode as g, createVNode as _, defineComponent as v, mergeModels as y, normalizeClass as b, openBlock as x, ref as S, renderList as C, toDisplayString as w, unref as T, useModel as E, withCtx as D } from "vue";
8
- import { CalendarCell as te, CalendarCellTrigger as ne, CalendarGrid as O, CalendarGridBody as k, CalendarGridHead as A, CalendarGridRow as j, CalendarHeadCell as M, CalendarHeader as N, CalendarHeading as P, CalendarNext as F, CalendarPrev as I, CalendarRoot as L, PopoverContent as R, PopoverPortal as z, PopoverRoot as B, PopoverTrigger as V } from "reka-ui";
1
+ import { useIryxUiConfig as e } from "../config.js";
2
+ import t from "./Icon.js";
3
+ import { useFormField as n } from "../composables/form.js";
4
+ import { formatIsoDate as r, isoToday as i, toCalendarDate as a, toIsoDate as o } from "../composables/date.js";
5
+ import { datePickerTheme as s } from "../theme/date-picker.js";
6
+ import { Fragment as c, computed as l, createBlock as u, createCommentVNode as ee, createElementBlock as d, createElementVNode as f, createTextVNode as p, createVNode as m, defineComponent as h, mergeModels as g, normalizeClass as _, openBlock as v, ref as y, renderList as b, toDisplayString as x, unref as S, useModel as C, withCtx as w } from "vue";
7
+ import { ArrowLeft01Icon as T, ArrowRight01Icon as te, Calendar03Icon as E } from "@hugeicons/core-free-icons";
8
+ import { CalendarCell as D, CalendarCellTrigger as O, CalendarGrid as k, CalendarGridBody as A, CalendarGridHead as j, CalendarGridRow as M, CalendarHeadCell as N, CalendarHeader as P, CalendarHeading as F, CalendarNext as I, CalendarPrev as L, CalendarRoot as R, PopoverContent as z, PopoverPortal as B, PopoverRoot as ne, PopoverTrigger as V } from "reka-ui";
9
9
  //#region src/components/DatePicker.vue?vue&type=script&setup=true&lang.ts
10
10
  var H = [
11
11
  "id",
12
12
  "disabled",
13
13
  "aria-invalid",
14
14
  "aria-describedby"
15
- ], U = { key: 0 }, W = /*@__PURE__*/ v({
15
+ ], U = { key: 0 }, W = /*@__PURE__*/ h({
16
16
  __name: "DatePicker",
17
- props: /*@__PURE__*/ y({
17
+ props: /*@__PURE__*/ g({
18
18
  size: {},
19
19
  placeholder: { default: "Pick a date" },
20
20
  disabled: { type: Boolean },
@@ -44,106 +44,106 @@ var H = [
44
44
  modelModifiers: {}
45
45
  }),
46
46
  emits: ["update:modelValue"],
47
- setup(v) {
48
- let y = v, W = E(v, "modelValue"), G = S(!1), K = a(), q = d(() => y.id ?? K?.id.value), J = d(() => y.invalid ?? K?.invalid.value ?? !1), Y = r(), X = d(() => y.unstyled ?? Y.unstyled), Z = d({
49
- get: () => s(W.value),
47
+ setup(h) {
48
+ let g = h, W = C(h, "modelValue"), G = y(!1), K = n(), q = l(() => g.id ?? K?.id.value), J = l(() => g.invalid ?? K?.invalid.value ?? !1), Y = e(), X = l(() => g.unstyled ?? Y.unstyled), Z = l({
49
+ get: () => a(W.value),
50
50
  set: (e) => {
51
- W.value = c(e);
51
+ W.value = o(e);
52
52
  }
53
- }), re = d(() => s(y.min)), ie = d(() => s(y.max)), Q = d(() => o(W.value, y.locale, y.format));
53
+ }), re = l(() => a(g.min)), ie = l(() => a(g.max)), Q = l(() => r(W.value, g.locale, g.format));
54
54
  function ae() {
55
- W.value = ee(), G.value = !1;
55
+ W.value = i(), G.value = !1;
56
56
  }
57
57
  function oe() {
58
58
  W.value = null, G.value = !1;
59
59
  }
60
- let se = d(() => l({
61
- size: y.size,
60
+ let se = l(() => s({
61
+ size: g.size,
62
62
  invalid: J.value
63
63
  }));
64
64
  function $(e, t) {
65
- let n = y.ui?.[e];
65
+ let n = g.ui?.[e];
66
66
  return X.value ? [n, t] : se.value[e]({ class: [n, t] });
67
67
  }
68
- return (r, a) => (x(), f(T(B), {
68
+ return (e, n) => (v(), u(S(ne), {
69
69
  open: G.value,
70
- "onUpdate:open": a[2] ||= (e) => G.value = e
70
+ "onUpdate:open": n[2] ||= (e) => G.value = e
71
71
  }, {
72
- default: D(() => [_(T(V), { "as-child": "" }, {
73
- default: D(() => [h("button", {
72
+ default: w(() => [m(S(V), { "as-child": "" }, {
73
+ default: w(() => [f("button", {
74
74
  id: q.value,
75
75
  type: "button",
76
- disabled: y.disabled,
76
+ disabled: g.disabled,
77
77
  "aria-invalid": J.value || void 0,
78
- "aria-describedby": T(K)?.describedBy.value,
79
- class: b($("trigger", y.class))
80
- }, [Q.value ? (x(), m("span", U, w(Q.value), 1)) : (x(), m("span", {
78
+ "aria-describedby": S(K)?.describedBy.value,
79
+ class: _($("trigger", g.class))
80
+ }, [Q.value ? (v(), d("span", U, x(Q.value), 1)) : (v(), d("span", {
81
81
  key: 1,
82
- class: b($("placeholder"))
83
- }, w(y.placeholder), 3)), _(i, { icon: T(n) }, null, 8, ["icon"])], 10, H)]),
82
+ class: _($("placeholder"))
83
+ }, x(g.placeholder), 3)), m(t, { icon: S(E) }, null, 8, ["icon"])], 10, H)]),
84
84
  _: 1
85
- }), _(T(z), null, {
86
- default: D(() => [_(T(R), {
87
- class: b($("content")),
85
+ }), m(S(B), null, {
86
+ default: w(() => [m(S(z), {
87
+ class: _($("content")),
88
88
  "side-offset": 4,
89
89
  align: "start"
90
90
  }, {
91
- default: D(() => [_(T(L), {
91
+ default: w(() => [m(S(R), {
92
92
  modelValue: Z.value,
93
- "onUpdate:modelValue": [a[0] ||= (e) => Z.value = e, a[1] ||= (e) => G.value = !1],
93
+ "onUpdate:modelValue": [n[0] ||= (e) => Z.value = e, n[1] ||= (e) => G.value = !1],
94
94
  "min-value": re.value,
95
95
  "max-value": ie.value,
96
- locale: y.locale,
97
- "week-starts-on": y.weekStartsOn,
96
+ locale: g.locale,
97
+ "week-starts-on": g.weekStartsOn,
98
98
  "fixed-weeks": "",
99
99
  "initial-focus": ""
100
100
  }, {
101
- default: D(({ grid: n, weekDays: r }) => [_(T(N), { class: b($("header")) }, {
102
- default: D(() => [
103
- _(T(I), {
104
- "aria-label": y.previousLabel,
105
- class: b($("nav"))
101
+ default: w(({ grid: e, weekDays: n }) => [m(S(P), { class: _($("header")) }, {
102
+ default: w(() => [
103
+ m(S(L), {
104
+ "aria-label": g.previousLabel,
105
+ class: _($("nav"))
106
106
  }, {
107
- default: D(() => [_(i, { icon: T(e) }, null, 8, ["icon"])]),
107
+ default: w(() => [m(t, { icon: S(T) }, null, 8, ["icon"])]),
108
108
  _: 1
109
109
  }, 8, ["aria-label", "class"]),
110
- _(T(P), { class: b($("heading")) }, null, 8, ["class"]),
111
- _(T(F), {
112
- "aria-label": y.nextLabel,
113
- class: b($("nav"))
110
+ m(S(F), { class: _($("heading")) }, null, 8, ["class"]),
111
+ m(S(I), {
112
+ "aria-label": g.nextLabel,
113
+ class: _($("nav"))
114
114
  }, {
115
- default: D(() => [_(i, { icon: T(t) }, null, 8, ["icon"])]),
115
+ default: w(() => [m(t, { icon: S(te) }, null, 8, ["icon"])]),
116
116
  _: 1
117
117
  }, 8, ["aria-label", "class"])
118
118
  ]),
119
119
  _: 1
120
- }, 8, ["class"]), h("div", { class: b($("months")) }, [(x(!0), m(u, null, C(n, (e) => (x(), f(T(O), {
120
+ }, 8, ["class"]), f("div", { class: _($("months")) }, [(v(!0), d(c, null, b(e, (e) => (v(), u(S(k), {
121
121
  key: e.value.toString(),
122
- class: b($("grid"))
122
+ class: _($("grid"))
123
123
  }, {
124
- default: D(() => [_(T(A), null, {
125
- default: D(() => [_(T(j), null, {
126
- default: D(() => [(x(!0), m(u, null, C(r, (e) => (x(), f(T(M), {
124
+ default: w(() => [m(S(j), null, {
125
+ default: w(() => [m(S(M), null, {
126
+ default: w(() => [(v(!0), d(c, null, b(n, (e) => (v(), u(S(N), {
127
127
  key: e,
128
- class: b($("headCell"))
128
+ class: _($("headCell"))
129
129
  }, {
130
- default: D(() => [g(w(e), 1)]),
130
+ default: w(() => [p(x(e), 1)]),
131
131
  _: 2
132
132
  }, 1032, ["class"]))), 128))]),
133
133
  _: 2
134
134
  }, 1024)]),
135
135
  _: 2
136
- }, 1024), _(T(k), null, {
137
- default: D(() => [(x(!0), m(u, null, C(e.rows, (t, n) => (x(), f(T(j), { key: `week-${n}` }, {
138
- default: D(() => [(x(!0), m(u, null, C(t, (t) => (x(), f(T(te), {
136
+ }, 1024), m(S(A), null, {
137
+ default: w(() => [(v(!0), d(c, null, b(e.rows, (t, n) => (v(), u(S(M), { key: `week-${n}` }, {
138
+ default: w(() => [(v(!0), d(c, null, b(t, (t) => (v(), u(S(D), {
139
139
  key: t.toString(),
140
140
  date: t,
141
- class: b($("cell"))
141
+ class: _($("cell"))
142
142
  }, {
143
- default: D(() => [_(T(ne), {
143
+ default: w(() => [m(S(O), {
144
144
  day: t,
145
145
  month: e.value,
146
- class: b($("cellTrigger"))
146
+ class: _($("cellTrigger"))
147
147
  }, null, 8, [
148
148
  "day",
149
149
  "month",
@@ -164,16 +164,16 @@ var H = [
164
164
  "max-value",
165
165
  "locale",
166
166
  "week-starts-on"
167
- ]), h("div", { class: b($("footer")) }, [h("button", {
167
+ ]), f("div", { class: _($("footer")) }, [f("button", {
168
168
  type: "button",
169
- class: b($("action")),
169
+ class: _($("action")),
170
170
  onClick: ae
171
- }, w(y.todayLabel), 3), y.clearable ? (x(), m("button", {
171
+ }, x(g.todayLabel), 3), g.clearable ? (v(), d("button", {
172
172
  key: 0,
173
173
  type: "button",
174
- class: b($("action")),
174
+ class: _($("action")),
175
175
  onClick: oe
176
- }, w(y.clearLabel), 3)) : p("", !0)], 2)]),
176
+ }, x(g.clearLabel), 3)) : ee("", !0)], 2)]),
177
177
  _: 1
178
178
  }, 8, ["class"])]),
179
179
  _: 1