iryx-ui 0.12.0 → 0.13.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 (225) hide show
  1. package/README.md +35 -1315
  2. package/dist/component-names.d.ts +1 -1
  3. package/dist/component-names.js +1 -1
  4. package/dist/components/Accordion.js +5 -0
  5. package/dist/components/Accordion.vue.d.ts +80 -0
  6. package/dist/components/Accordion.vue_vue_type_script_setup_true_lang.js +87 -0
  7. package/dist/components/Alert.vue.d.ts +1 -1
  8. package/dist/components/Alert.vue_vue_type_script_setup_true_lang.js +7 -7
  9. package/dist/components/App.vue.d.ts +1 -1
  10. package/dist/components/AppShell.js +5 -0
  11. package/dist/components/AppShell.vue.d.ts +46 -0
  12. package/dist/components/AppShell.vue_vue_type_script_setup_true_lang.js +59 -0
  13. package/dist/components/AspectRatio.js +5 -0
  14. package/dist/components/AspectRatio.vue.d.ts +26 -0
  15. package/dist/components/AspectRatio.vue_vue_type_script_setup_true_lang.js +27 -0
  16. package/dist/components/Avatar.js +5 -0
  17. package/dist/components/Avatar.vue.d.ts +52 -0
  18. package/dist/components/Avatar.vue_vue_type_script_setup_true_lang.js +67 -0
  19. package/dist/components/AvatarGroup.js +5 -0
  20. package/dist/components/AvatarGroup.vue.d.ts +39 -0
  21. package/dist/components/AvatarGroup.vue_vue_type_script_setup_true_lang.js +45 -0
  22. package/dist/components/Badge.vue.d.ts +1 -1
  23. package/dist/components/Banner.vue.d.ts +2 -2
  24. package/dist/components/BarChart.vue.d.ts +1 -1
  25. package/dist/components/BarChart.vue_vue_type_script_setup_true_lang.js +14 -14
  26. package/dist/components/Button.vue.d.ts +2 -2
  27. package/dist/components/ButtonGroup.vue.d.ts +1 -1
  28. package/dist/components/Card.vue.d.ts +1 -1
  29. package/dist/components/Collapsible.js +5 -0
  30. package/dist/components/Collapsible.vue.d.ts +58 -0
  31. package/dist/components/Collapsible.vue_vue_type_script_setup_true_lang.js +67 -0
  32. package/dist/components/ColorPicker.js +5 -0
  33. package/dist/components/ColorPicker.vue.d.ts +49 -0
  34. package/dist/components/ColorPicker.vue_vue_type_script_setup_true_lang.js +172 -0
  35. package/dist/components/Combobox.vue.d.ts +6 -6
  36. package/dist/components/CommandPalette.js +5 -0
  37. package/dist/components/CommandPalette.vue.d.ts +63 -0
  38. package/dist/components/CommandPalette.vue_vue_type_script_setup_true_lang.js +185 -0
  39. package/dist/components/Container.js +5 -0
  40. package/dist/components/Container.vue.d.ts +33 -0
  41. package/dist/components/Container.vue_vue_type_script_setup_true_lang.js +40 -0
  42. package/dist/components/ContextMenu.js +5 -0
  43. package/dist/components/ContextMenu.vue.d.ts +42 -0
  44. package/dist/components/ContextMenu.vue_vue_type_script_setup_true_lang.js +49 -0
  45. package/dist/components/DateRangePicker.vue.d.ts +1 -1
  46. package/dist/components/Dialog.vue.d.ts +1 -1
  47. package/dist/components/Drawer.vue.d.ts +2 -2
  48. package/dist/components/EmptyState.vue.d.ts +1 -1
  49. package/dist/components/Input.vue.d.ts +1 -1
  50. package/dist/components/Input.vue_vue_type_script_setup_true_lang.js +4 -4
  51. package/dist/components/Kbd.js +5 -0
  52. package/dist/components/Kbd.vue.d.ts +46 -0
  53. package/dist/components/Kbd.vue_vue_type_script_setup_true_lang.js +41 -0
  54. package/dist/components/LineChart.vue_vue_type_script_setup_true_lang.js +19 -19
  55. package/dist/components/Menubar.js +5 -0
  56. package/dist/components/Menubar.vue.d.ts +62 -0
  57. package/dist/components/Menubar.vue_vue_type_script_setup_true_lang.js +79 -0
  58. package/dist/components/NavigationMenu.js +5 -0
  59. package/dist/components/NavigationMenu.vue.d.ts +75 -0
  60. package/dist/components/NavigationMenu.vue_vue_type_script_setup_true_lang.js +167 -0
  61. package/dist/components/NumberInput.vue_vue_type_script_setup_true_lang.js +2 -2
  62. package/dist/components/PageHeader.js +5 -0
  63. package/dist/components/PageHeader.vue.d.ts +52 -0
  64. package/dist/components/PageHeader.vue_vue_type_script_setup_true_lang.js +59 -0
  65. package/dist/components/PinInput.js +5 -0
  66. package/dist/components/PinInput.vue.d.ts +65 -0
  67. package/dist/components/PinInput.vue_vue_type_script_setup_true_lang.js +76 -0
  68. package/dist/components/Popover.js +5 -0
  69. package/dist/components/Popover.vue.d.ts +75 -0
  70. package/dist/components/Popover.vue_vue_type_script_setup_true_lang.js +99 -0
  71. package/dist/components/Progress.vue.d.ts +20 -1
  72. package/dist/components/Progress.vue_vue_type_script_setup_true_lang.js +84 -44
  73. package/dist/components/RadioGroup.vue_vue_type_script_setup_true_lang.js +4 -1
  74. package/dist/components/ScrollArea.js +5 -0
  75. package/dist/components/ScrollArea.vue.d.ts +41 -0
  76. package/dist/components/ScrollArea.vue_vue_type_script_setup_true_lang.js +68 -0
  77. package/dist/components/ScrollFade.js +5 -0
  78. package/dist/components/ScrollFade.vue.d.ts +36 -0
  79. package/dist/components/ScrollFade.vue_vue_type_script_setup_true_lang.js +59 -0
  80. package/dist/components/Select.vue.d.ts +2 -2
  81. package/dist/components/Sidebar.js +5 -0
  82. package/dist/components/Sidebar.vue.d.ts +72 -0
  83. package/dist/components/Sidebar.vue_vue_type_script_setup_true_lang.js +183 -0
  84. package/dist/components/SignaturePad.js +5 -0
  85. package/dist/components/SignaturePad.vue.d.ts +60 -0
  86. package/dist/components/SignaturePad.vue_vue_type_script_setup_true_lang.js +158 -0
  87. package/dist/components/Skeleton.vue.d.ts +1 -1
  88. package/dist/components/Skeleton.vue_vue_type_script_setup_true_lang.js +8 -8
  89. package/dist/components/Slider.js +5 -0
  90. package/dist/components/Slider.vue.d.ts +80 -0
  91. package/dist/components/Slider.vue_vue_type_script_setup_true_lang.js +115 -0
  92. package/dist/components/Splitter.js +5 -0
  93. package/dist/components/Splitter.vue.d.ts +59 -0
  94. package/dist/components/Splitter.vue_vue_type_script_setup_true_lang.js +69 -0
  95. package/dist/components/Stat.vue.d.ts +1 -1
  96. package/dist/components/Switch.vue.d.ts +1 -0
  97. package/dist/components/Switch.vue_vue_type_script_setup_true_lang.js +7 -3
  98. package/dist/components/Table.vue.d.ts +7 -1
  99. package/dist/components/Table.vue_vue_type_script_setup_true_lang.js +73 -58
  100. package/dist/components/TagsInput.js +5 -0
  101. package/dist/components/TagsInput.vue.d.ts +71 -0
  102. package/dist/components/TagsInput.vue_vue_type_script_setup_true_lang.js +119 -0
  103. package/dist/components/Textarea.vue_vue_type_script_setup_true_lang.js +3 -3
  104. package/dist/components/TimeField.js +5 -0
  105. package/dist/components/TimeField.vue.d.ts +50 -0
  106. package/dist/components/TimeField.vue_vue_type_script_setup_true_lang.js +85 -0
  107. package/dist/components/Timeline.js +5 -0
  108. package/dist/components/Timeline.vue.d.ts +61 -0
  109. package/dist/components/Timeline.vue_vue_type_script_setup_true_lang.js +60 -0
  110. package/dist/components/Toaster.vue.d.ts +1 -1
  111. package/dist/components/Toggle.js +5 -0
  112. package/dist/components/Toggle.vue.d.ts +42 -0
  113. package/dist/components/Toggle.vue_vue_type_script_setup_true_lang.js +52 -0
  114. package/dist/components/ToggleGroup.js +5 -0
  115. package/dist/components/ToggleGroup.vue.d.ts +64 -0
  116. package/dist/components/ToggleGroup.vue_vue_type_script_setup_true_lang.js +78 -0
  117. package/dist/components/Toolbar.js +5 -0
  118. package/dist/components/Toolbar.vue.d.ts +52 -0
  119. package/dist/components/Toolbar.vue_vue_type_script_setup_true_lang.js +94 -0
  120. package/dist/components/Tree.js +5 -0
  121. package/dist/components/Tree.vue.d.ts +70 -0
  122. package/dist/components/Tree.vue_vue_type_script_setup_true_lang.js +112 -0
  123. package/dist/components/index.d.ts +29 -0
  124. package/dist/components/index.js +144 -86
  125. package/dist/composables/appearance.js +5 -1
  126. package/dist/composables/cartesian.d.ts +11 -0
  127. package/dist/composables/cartesian.js +18 -19
  128. package/dist/composables/command-palette.d.ts +42 -0
  129. package/dist/composables/command-palette.js +32 -0
  130. package/dist/composables/date.d.ts +18 -2
  131. package/dist/composables/date.js +23 -12
  132. package/dist/composables/kbd.d.ts +26 -0
  133. package/dist/composables/kbd.js +161 -0
  134. package/dist/composables/navigation-menu.d.ts +29 -0
  135. package/dist/composables/navigation-menu.js +6 -0
  136. package/dist/composables/scroll-fade.d.ts +35 -0
  137. package/dist/composables/scroll-fade.js +36 -0
  138. package/dist/composables/sidebar.d.ts +35 -0
  139. package/dist/composables/sidebar.js +23 -0
  140. package/dist/composables/signature.d.ts +22 -0
  141. package/dist/composables/signature.js +13 -0
  142. package/dist/index.d.ts +35 -0
  143. package/dist/index.js +153 -93
  144. package/dist/theme/accordion.d.ts +68 -0
  145. package/dist/theme/accordion.js +24 -0
  146. package/dist/theme/alert.d.ts +0 -3
  147. package/dist/theme/app-shell.d.ts +77 -0
  148. package/dist/theme/app-shell.js +35 -0
  149. package/dist/theme/avatar.d.ts +253 -0
  150. package/dist/theme/avatar.js +84 -0
  151. package/dist/theme/banner.d.ts +0 -9
  152. package/dist/theme/bar-chart.d.ts +0 -16
  153. package/dist/theme/breadcrumb.d.ts +3 -3
  154. package/dist/theme/button-group.d.ts +0 -3
  155. package/dist/theme/button.d.ts +0 -3
  156. package/dist/theme/card.js +2 -2
  157. package/dist/theme/chart-legend.d.ts +3 -11
  158. package/dist/theme/collapsible.d.ts +44 -0
  159. package/dist/theme/collapsible.js +17 -0
  160. package/dist/theme/color-picker.d.ts +98 -0
  161. package/dist/theme/color-picker.js +19 -0
  162. package/dist/theme/command-palette.d.ts +122 -0
  163. package/dist/theme/command-palette.js +22 -0
  164. package/dist/theme/container.d.ts +101 -0
  165. package/dist/theme/container.js +26 -0
  166. package/dist/theme/date-picker.d.ts +12 -0
  167. package/dist/theme/date-picker.js +1 -1
  168. package/dist/theme/dropdown-menu.d.ts +0 -9
  169. package/dist/theme/file-upload.d.ts +0 -3
  170. package/dist/theme/form.d.ts +12 -12
  171. package/dist/theme/index.d.ts +25 -0
  172. package/dist/theme/kbd.d.ts +71 -0
  173. package/dist/theme/kbd.js +29 -0
  174. package/dist/theme/line-chart.d.ts +0 -9
  175. package/dist/theme/menubar.d.ts +29 -0
  176. package/dist/theme/menubar.js +11 -0
  177. package/dist/theme/navigation-menu.d.ts +161 -0
  178. package/dist/theme/navigation-menu.js +43 -0
  179. package/dist/theme/number-input.d.ts +0 -3
  180. package/dist/theme/page-header.d.ts +47 -0
  181. package/dist/theme/page-header.js +17 -0
  182. package/dist/theme/pagination.d.ts +0 -3
  183. package/dist/theme/pin-input.d.ts +86 -0
  184. package/dist/theme/pin-input.js +32 -0
  185. package/dist/theme/popover.d.ts +119 -0
  186. package/dist/theme/popover.js +31 -0
  187. package/dist/theme/presets.d.ts +0 -2
  188. package/dist/theme/progress.d.ts +93 -0
  189. package/dist/theme/progress.js +37 -7
  190. package/dist/theme/radio-group.d.ts +24 -0
  191. package/dist/theme/radio-group.js +23 -14
  192. package/dist/theme/scroll-area.d.ts +65 -0
  193. package/dist/theme/scroll-area.js +57 -0
  194. package/dist/theme/scroll-fade.d.ts +35 -0
  195. package/dist/theme/scroll-fade.js +12 -0
  196. package/dist/theme/sidebar.d.ts +167 -0
  197. package/dist/theme/sidebar.js +43 -0
  198. package/dist/theme/signature-pad.d.ts +50 -0
  199. package/dist/theme/signature-pad.js +17 -0
  200. package/dist/theme/slider.d.ts +128 -0
  201. package/dist/theme/slider.js +49 -0
  202. package/dist/theme/sparkline.d.ts +0 -6
  203. package/dist/theme/splitter.d.ts +59 -0
  204. package/dist/theme/splitter.js +25 -0
  205. package/dist/theme/stat.d.ts +0 -3
  206. package/dist/theme/stepper.js +2 -2
  207. package/dist/theme/switch.d.ts +53 -29
  208. package/dist/theme/switch.js +33 -8
  209. package/dist/theme/table.d.ts +51 -3
  210. package/dist/theme/table.js +8 -3
  211. package/dist/theme/tabs.d.ts +0 -3
  212. package/dist/theme/tags-input.d.ts +110 -0
  213. package/dist/theme/tags-input.js +42 -0
  214. package/dist/theme/time-field.d.ts +68 -0
  215. package/dist/theme/time-field.js +21 -0
  216. package/dist/theme/timeline.d.ts +182 -0
  217. package/dist/theme/timeline.js +83 -0
  218. package/dist/theme/toggle.d.ts +145 -0
  219. package/dist/theme/toggle.js +84 -0
  220. package/dist/theme/toolbar.d.ts +56 -0
  221. package/dist/theme/toolbar.js +21 -0
  222. package/dist/theme/tree.d.ts +68 -0
  223. package/dist/theme/tree.js +28 -0
  224. package/package.json +2 -2
  225. package/theme.css +221 -0
@@ -26,8 +26,8 @@ type __VLS_Slots = {} & {
26
26
  default?: (props: typeof __VLS_8) => any;
27
27
  };
28
28
  declare const __VLS_base: import("vue").DefineComponent<BadgeProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<BadgeProps> & Readonly<{}>, {
29
- as: string;
30
29
  unstyled: boolean;
30
+ as: string;
31
31
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
32
32
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
33
33
  declare const _default: typeof __VLS_export;
@@ -65,10 +65,10 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {
65
65
  onClose?: (() => any) | undefined;
66
66
  "onUpdate:open"?: ((value: boolean) => any) | undefined;
67
67
  }>, {
68
- as: string;
69
- closeLabel: string;
70
68
  unstyled: boolean;
69
+ as: string;
71
70
  label: string;
71
+ closeLabel: string;
72
72
  contained: boolean;
73
73
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
74
74
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
@@ -90,9 +90,9 @@ type __VLS_Slots = {} & {
90
90
  };
91
91
  declare const __VLS_base: import("vue").DefineComponent<BarChartProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<BarChartProps> & Readonly<{}>, {
92
92
  unstyled: boolean;
93
+ orientation: "vertical" | "horizontal";
93
94
  data: readonly BarChartDatum[];
94
95
  legend: boolean;
95
- orientation: "vertical" | "horizontal";
96
96
  height: number;
97
97
  ticks: number;
98
98
  axis: boolean;
@@ -1,6 +1,6 @@
1
1
  import { useIryxUiConfig as e } from "../config.js";
2
- import { cartesianLayout as t, clampTooltip as n, seriesColor as r, slotOf as i, tooltipHalfWidth as a, warnOnSlotOverflow as o } from "../composables/cartesian.js";
3
- import { useElementSize as s } from "../composables/element-size.js";
2
+ import { useElementSize as t } from "../composables/element-size.js";
3
+ import { cartesianLayout as n, clampTooltip as r, seriesColor as i, slotOf as a, tooltipHalfWidth as o, warnOnSlotOverflow as s } from "../composables/cartesian.js";
4
4
  import { barChartTheme as c } from "../theme/bar-chart.js";
5
5
  import l from "./ChartLegend.js";
6
6
  import { Fragment as u, computed as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, defineComponent as g, guardReactiveProps as _, normalizeClass as v, normalizeProps as y, normalizeStyle as b, openBlock as x, ref as S, renderList as C, renderSlot as w, toDisplayString as T, unref as E } from "vue";
@@ -62,13 +62,13 @@ var ee = ["role", "aria-label"], D = [
62
62
  ui: {}
63
63
  },
64
64
  setup(g) {
65
- let j = g, M = e(), N = d(() => j.unstyled ?? M.unstyled), P = S(), { width: F } = s(P), I = d(() => new Intl.NumberFormat(j.locale, j.format));
65
+ let j = g, M = e(), N = d(() => j.unstyled ?? M.unstyled), P = S(), { width: F } = t(P), I = d(() => new Intl.NumberFormat(j.locale, j.format));
66
66
  function L(e) {
67
67
  return I.value.format(e);
68
68
  }
69
69
  let R = d(() => {
70
70
  let e = j.series?.length ? [...j.series] : [{ key: "value" }];
71
- return o(e.length), e;
71
+ return s(e.length), e;
72
72
  }), z = d(() => R.value.length > 1), oe = d(() => z.value || j.legend && R.value[0].name != null);
73
73
  function B(e, t) {
74
74
  let n = e[t];
@@ -83,7 +83,7 @@ var ee = ["role", "aria-label"], D = [
83
83
  }
84
84
  return [t, n];
85
85
  }
86
- let W = d(() => t({
86
+ let W = d(() => n({
87
87
  orientation: j.orientation,
88
88
  values: H.value ? j.data.flatMap(U) : j.data.flatMap((e) => R.value.map((t) => B(e, t.key))),
89
89
  categories: j.data.length,
@@ -153,25 +153,25 @@ var ee = ["role", "aria-label"], D = [
153
153
  if (!e) return;
154
154
  let t = R.value.map((t, n) => ({
155
155
  name: t.name ?? t.key,
156
- color: r(i(t, n)),
156
+ color: i(a(t, n)),
157
157
  value: B(e, t.key)
158
158
  })).filter((e) => e.value != null).map((e) => ({
159
159
  ...e,
160
160
  value: L(e.value)
161
161
  }));
162
162
  if (!t.length) return;
163
- let o = H.value ? L(U(e).reduce((e, t) => e + t, 0)) : void 0, s = z.value ? Math.max(e.label.length, o ? o.length + 6 : 0, ...t.map((e) => e.name.length + e.value.length + 3)) : e.label.length + t[0].value.length + 2, c = W.value.bandCentre(X.value);
163
+ let n = H.value ? L(U(e).reduce((e, t) => e + t, 0)) : void 0, s = z.value ? Math.max(e.label.length, n ? n.length + 6 : 0, ...t.map((e) => e.name.length + e.value.length + 3)) : e.label.length + t[0].value.length + 2, c = W.value.bandCentre(X.value);
164
164
  if (V.value) {
165
- let r = H.value ? W.value.value(U(e)[0]) : Math.max(...R.value.map((t) => {
165
+ let i = H.value ? W.value.value(U(e)[0]) : Math.max(...R.value.map((t) => {
166
166
  let n = B(e, t.key);
167
167
  return n == null ? -Infinity : W.value.value(n);
168
- })), i = "x".repeat(s), l = a(i), u = r + l + 8, d = u + l <= F.value;
168
+ })), a = "x".repeat(s), l = o(a), u = i + l + 8, d = u + l <= F.value;
169
169
  return {
170
170
  label: e.label,
171
171
  rows: t,
172
- total: o,
172
+ total: n,
173
173
  multi: z.value,
174
- x: n(d ? u : r - l - 8, i, F.value),
174
+ x: r(d ? u : i - l - 8, a, F.value),
175
175
  y: c
176
176
  };
177
177
  }
@@ -182,9 +182,9 @@ var ee = ["role", "aria-label"], D = [
182
182
  return {
183
183
  label: e.label,
184
184
  rows: t,
185
- total: o,
185
+ total: n,
186
186
  multi: z.value,
187
- x: n(c, "x".repeat(s), F.value),
187
+ x: r(c, "x".repeat(s), F.value),
188
188
  y: l
189
189
  };
190
190
  }), Q = d(() => c());
@@ -233,7 +233,7 @@ var ee = ["role", "aria-label"], D = [
233
233
  (x(!0), m(u, null, C(se.value, (e, t) => (x(), m("path", {
234
234
  key: `bar-${e.categoryIndex}-${e.seriesIndex}-${t}`,
235
235
  d: ce(e),
236
- style: b({ fill: E(r)(E(i)(R.value[e.seriesIndex], e.seriesIndex)) }),
236
+ style: b({ fill: E(i)(E(a)(R.value[e.seriesIndex], e.seriesIndex)) }),
237
237
  class: v(ue(e))
238
238
  }, null, 14, k))), 128)),
239
239
  (x(!0), m(u, null, C(j.data, (e, t) => (x(), m(u, { key: `label-${e.label}-${t}` }, [t % le.value === 0 ? (x(), m("text", {
@@ -28,9 +28,9 @@ type __VLS_Slots = {} & {
28
28
  default?: (props: typeof __VLS_13) => any;
29
29
  };
30
30
  declare const __VLS_base: import("vue").DefineComponent<ButtonProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ButtonProps> & Readonly<{}>, {
31
- as: string;
32
- unstyled: boolean;
33
31
  type: "button" | "submit" | "reset";
32
+ unstyled: boolean;
33
+ as: string;
34
34
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
35
35
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
36
36
  declare const _default: typeof __VLS_export;
@@ -19,8 +19,8 @@ type __VLS_Slots = {} & {
19
19
  default?: (props: typeof __VLS_8) => any;
20
20
  };
21
21
  declare const __VLS_base: import("vue").DefineComponent<ButtonGroupProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ButtonGroupProps> & Readonly<{}>, {
22
- as: string;
23
22
  unstyled: boolean;
23
+ as: string;
24
24
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
25
25
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
26
26
  declare const _default: typeof __VLS_export;
@@ -36,8 +36,8 @@ type __VLS_Slots = {} & {
36
36
  footer?: (props: typeof __VLS_16) => any;
37
37
  };
38
38
  declare const __VLS_base: import("vue").DefineComponent<CardProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<CardProps> & Readonly<{}>, {
39
- as: string;
40
39
  unstyled: boolean;
40
+ as: string;
41
41
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
42
42
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
43
43
  declare const _default: typeof __VLS_export;
@@ -0,0 +1,5 @@
1
+ import e from "./Collapsible.vue_vue_type_script_setup_true_lang.js";
2
+ //#region src/components/Collapsible.vue
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };
@@ -0,0 +1,58 @@
1
+ export interface CollapsibleProps {
2
+ /** Label on the trigger. Ignored when the `trigger` slot is used. */
3
+ label?: string;
4
+ /** Starting state when you are not controlling it. */
5
+ defaultOpen?: boolean;
6
+ disabled?: boolean;
7
+ /** Which side of the trigger the chevron sits on. */
8
+ iconPosition?: 'start' | 'end';
9
+ /** Drop the chevron entirely — for a trigger that says "open" some other way. */
10
+ hideIcon?: boolean;
11
+ /**
12
+ * Remove the content from the DOM while closed rather than hiding it.
13
+ * Costs the open animation, so reach for it only when the content is
14
+ * expensive or must not be found by in-page search while shut.
15
+ */
16
+ unmountOnHide?: boolean;
17
+ /** Skip built-in classes; you take over styling entirely. */
18
+ unstyled?: boolean;
19
+ class?: string;
20
+ /** Override classes per slot, e.g. `{ content: 'pt-2' }`. */
21
+ ui?: {
22
+ root?: string;
23
+ trigger?: string;
24
+ content?: string;
25
+ icon?: string;
26
+ };
27
+ }
28
+ /** One region, with no siblings to coordinate with — see `IAccordion` for a list. */
29
+ type __VLS_Props = CollapsibleProps;
30
+ type __VLS_ModelProps = {
31
+ 'open'?: boolean;
32
+ };
33
+ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
34
+ declare var __VLS_14: {
35
+ open: boolean;
36
+ }, __VLS_27: {
37
+ open: boolean;
38
+ };
39
+ type __VLS_Slots = {} & {
40
+ trigger?: (props: typeof __VLS_14) => any;
41
+ } & {
42
+ default?: (props: typeof __VLS_27) => any;
43
+ };
44
+ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
45
+ "update:open": (value: boolean) => any;
46
+ }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
47
+ "onUpdate:open"?: ((value: boolean) => any) | undefined;
48
+ }>, {
49
+ unstyled: boolean;
50
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
51
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
52
+ declare const _default: typeof __VLS_export;
53
+ export default _default;
54
+ type __VLS_WithSlots<T, S> = T & {
55
+ new (): {
56
+ $slots: S;
57
+ };
58
+ };
@@ -0,0 +1,67 @@
1
+ import { useIryxUiConfig as e } from "../config.js";
2
+ import t from "./Icon.js";
3
+ import { collapsibleTheme as n } from "../theme/collapsible.js";
4
+ import { computed as r, createBlock as i, createCommentVNode as a, createTextVNode as o, createVNode as s, defineComponent as c, mergeModels as l, normalizeClass as u, openBlock as d, renderSlot as f, toDisplayString as p, unref as m, useModel as h, withCtx as g } from "vue";
5
+ import { ArrowDown01Icon as _ } from "@hugeicons/core-free-icons";
6
+ import { CollapsibleContent as v, CollapsibleRoot as y, CollapsibleTrigger as b } from "reka-ui";
7
+ //#region src/components/Collapsible.vue?vue&type=script&setup=true&lang.ts
8
+ var x = /*@__PURE__*/ c({
9
+ __name: "Collapsible",
10
+ props: /*@__PURE__*/ l({
11
+ label: {},
12
+ defaultOpen: { type: Boolean },
13
+ disabled: { type: Boolean },
14
+ iconPosition: {},
15
+ hideIcon: { type: Boolean },
16
+ unmountOnHide: { type: Boolean },
17
+ unstyled: {
18
+ type: Boolean,
19
+ default: void 0
20
+ },
21
+ class: {},
22
+ ui: {}
23
+ }, {
24
+ open: {
25
+ type: Boolean,
26
+ default: void 0
27
+ },
28
+ openModifiers: {}
29
+ }),
30
+ emits: ["update:open"],
31
+ setup(c) {
32
+ let l = c, x = h(c, "open"), S = e(), C = r(() => l.unstyled ?? S.unstyled), w = r(() => n({ iconPosition: l.iconPosition }));
33
+ function T(e, t) {
34
+ let n = [l.ui?.[e], t].filter(Boolean).join(" ");
35
+ return C.value ? n : w.value[e]({ class: n });
36
+ }
37
+ return (e, n) => (d(), i(m(y), {
38
+ open: x.value,
39
+ "onUpdate:open": n[0] ||= (e) => x.value = e,
40
+ "default-open": l.defaultOpen,
41
+ disabled: l.disabled,
42
+ "unmount-on-hide": l.unmountOnHide,
43
+ class: u(T("root", l.class))
44
+ }, {
45
+ default: g(({ open: n }) => [s(m(b), { class: u(T("trigger")) }, {
46
+ default: g(() => [f(e.$slots, "trigger", { open: n }, () => [o(p(l.label), 1)]), l.hideIcon ? a("", !0) : (d(), i(t, {
47
+ key: 0,
48
+ icon: m(_),
49
+ class: u(T("icon", n ? "rotate-180" : void 0))
50
+ }, null, 8, ["icon", "class"]))]),
51
+ _: 2
52
+ }, 1032, ["class"]), s(m(v), { class: u(T("content")) }, {
53
+ default: g(() => [f(e.$slots, "default", { open: n })]),
54
+ _: 2
55
+ }, 1032, ["class"])]),
56
+ _: 3
57
+ }, 8, [
58
+ "open",
59
+ "default-open",
60
+ "disabled",
61
+ "unmount-on-hide",
62
+ "class"
63
+ ]));
64
+ }
65
+ });
66
+ //#endregion
67
+ export { x as default };
@@ -0,0 +1,5 @@
1
+ import e from "./ColorPicker.vue_vue_type_script_setup_true_lang.js";
2
+ //#region src/components/ColorPicker.vue
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };
@@ -0,0 +1,49 @@
1
+ export interface ColorPickerProps {
2
+ /**
3
+ * The colour as a hex **string** — `#16a372`, or `#16a372ff` with `alpha`.
4
+ * A string is what goes into a stylesheet, a database column and a design
5
+ * token, so it is what the model holds; the colour object stays inside.
6
+ */
7
+ modelValue?: string;
8
+ /** Add an opacity ramp, and eight hex digits to the model. */
9
+ alpha?: boolean;
10
+ /** Hide the hex field, leaving only the visual controls. */
11
+ hideField?: boolean;
12
+ /**
13
+ * Names the hex input. It sits among unlabelled visual controls, so without
14
+ * one it reaches a screen reader as an anonymous text box.
15
+ */
16
+ fieldLabel?: string;
17
+ /** Preset colours offered under the picker. */
18
+ swatches?: string[];
19
+ disabled?: boolean;
20
+ /** Skip built-in classes; you take over styling entirely. */
21
+ unstyled?: boolean;
22
+ class?: string;
23
+ /** Override classes per slot, e.g. `{ area: 'h-56' }`. */
24
+ ui?: {
25
+ root?: string;
26
+ area?: string;
27
+ thumb?: string;
28
+ sliderThumb?: string;
29
+ slider?: string;
30
+ checkerboard?: string;
31
+ track?: string;
32
+ field?: string;
33
+ input?: string;
34
+ preview?: string;
35
+ swatches?: string;
36
+ swatch?: string;
37
+ };
38
+ }
39
+ declare const __VLS_export: import("vue").DefineComponent<ColorPickerProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
40
+ "update:modelValue": (value: string) => any;
41
+ }, string, import("vue").PublicProps, Readonly<ColorPickerProps> & Readonly<{
42
+ "onUpdate:modelValue"?: ((value: string) => any) | undefined;
43
+ }>, {
44
+ unstyled: boolean;
45
+ modelValue: string;
46
+ fieldLabel: string;
47
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
48
+ declare const _default: typeof __VLS_export;
49
+ export default _default;
@@ -0,0 +1,172 @@
1
+ import { useIryxUiConfig as e } from "../config.js";
2
+ import { colorPickerTheme as t } from "../theme/color-picker.js";
3
+ import { Fragment as n, computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createVNode as c, defineComponent as l, normalizeClass as u, normalizeStyle as d, openBlock as f, ref as p, renderList as m, unref as h, watch as g, withCtx as _ } from "vue";
4
+ import { ColorAreaArea as v, ColorAreaRoot as y, ColorAreaThumb as b, ColorFieldInput as x, ColorFieldRoot as S, ColorSliderRoot as C, ColorSliderThumb as w, ColorSliderTrack as T, ColorSwatchPickerItem as E, ColorSwatchPickerItemSwatch as D, ColorSwatchPickerRoot as O, colorToString as k, convertToHsb as A, normalizeColor as j } from "reka-ui";
5
+ //#region src/components/ColorPicker.vue?vue&type=script&setup=true&lang.ts
6
+ var M = /*@__PURE__*/ l({
7
+ __name: "ColorPicker",
8
+ props: {
9
+ modelValue: { default: "#000000" },
10
+ alpha: { type: Boolean },
11
+ hideField: { type: Boolean },
12
+ fieldLabel: { default: "Hex colour" },
13
+ swatches: {},
14
+ disabled: { type: Boolean },
15
+ unstyled: {
16
+ type: Boolean,
17
+ default: void 0
18
+ },
19
+ class: {},
20
+ ui: {}
21
+ },
22
+ emits: ["update:modelValue"],
23
+ setup(l, { emit: M }) {
24
+ let N = l, P = M, F = (e) => P("update:modelValue", e);
25
+ function I(e) {
26
+ try {
27
+ return A(j(e));
28
+ } catch {
29
+ return {
30
+ space: "hsb",
31
+ h: 0,
32
+ s: 100,
33
+ b: 100,
34
+ alpha: 1
35
+ };
36
+ }
37
+ }
38
+ let L = (e) => k(e, "hex"), R = p(I(N.modelValue)), z = (e) => e.s === 0 || e.b === 0;
39
+ g(() => N.modelValue, (e) => {
40
+ if (L(R.value) === e) return;
41
+ let t = I(e);
42
+ R.value = z(t) ? {
43
+ ...t,
44
+ h: R.value.h
45
+ } : t;
46
+ });
47
+ function B(e) {
48
+ R.value = e, F(L(e));
49
+ }
50
+ function V(e) {
51
+ return B({
52
+ ...A(e),
53
+ h: R.value.h,
54
+ alpha: R.value.alpha
55
+ });
56
+ }
57
+ function H(e) {
58
+ return B({
59
+ ...R.value,
60
+ h: A(e).h
61
+ });
62
+ }
63
+ function U(e) {
64
+ return B({
65
+ ...R.value,
66
+ alpha: A(e).alpha
67
+ });
68
+ }
69
+ let W = e(), G = r(() => N.unstyled ?? W.unstyled), K = r(() => t());
70
+ function q(e, t) {
71
+ let n = [N.ui?.[e], t].filter(Boolean).join(" ");
72
+ return G.value ? n : K.value[e]({ class: n });
73
+ }
74
+ return (e, t) => (f(), o("div", { class: u(q("root", N.class)) }, [
75
+ c(h(y), {
76
+ "color-space": "hsb",
77
+ "x-channel": "saturation",
78
+ "y-channel": "brightness",
79
+ "model-value": R.value,
80
+ disabled: N.disabled,
81
+ class: u(q("area")),
82
+ "onUpdate:color": V
83
+ }, {
84
+ default: _(({ style: e }) => [c(h(v), {
85
+ class: "size-full rounded-[inherit]",
86
+ style: d(e)
87
+ }, {
88
+ default: _(() => [c(h(b), { class: u(q("thumb")) }, null, 8, ["class"])]),
89
+ _: 1
90
+ }, 8, ["style"])]),
91
+ _: 1
92
+ }, 8, [
93
+ "model-value",
94
+ "disabled",
95
+ "class"
96
+ ]),
97
+ c(h(C), {
98
+ "color-space": "hsb",
99
+ channel: "hue",
100
+ "model-value": R.value,
101
+ disabled: N.disabled,
102
+ class: u(q("slider")),
103
+ "onUpdate:color": H
104
+ }, {
105
+ default: _(() => [c(h(T), { class: u(q("track")) }, null, 8, ["class"]), c(h(w), { class: u([q("thumb"), q("sliderThumb")]) }, null, 8, ["class"])]),
106
+ _: 1
107
+ }, 8, [
108
+ "model-value",
109
+ "disabled",
110
+ "class"
111
+ ]),
112
+ N.alpha ? (f(), i(h(C), {
113
+ key: 0,
114
+ "color-space": "hsb",
115
+ channel: "alpha",
116
+ "model-value": R.value,
117
+ disabled: N.disabled,
118
+ class: u(q("slider")),
119
+ "onUpdate:color": U
120
+ }, {
121
+ default: _(() => [
122
+ s("span", { class: u(q("checkerboard")) }, null, 2),
123
+ c(h(T), { class: u(q("track")) }, null, 8, ["class"]),
124
+ c(h(w), { class: u([q("thumb"), q("sliderThumb")]) }, null, 8, ["class"])
125
+ ]),
126
+ _: 1
127
+ }, 8, [
128
+ "model-value",
129
+ "disabled",
130
+ "class"
131
+ ])) : a("", !0),
132
+ N.hideField ? a("", !0) : (f(), i(h(S), {
133
+ key: 1,
134
+ "model-value": N.modelValue,
135
+ disabled: N.disabled,
136
+ class: u(q("field")),
137
+ "onUpdate:modelValue": F
138
+ }, {
139
+ default: _(() => [s("span", { class: u(q("preview")) }, [s("span", { class: u(q("checkerboard", "rounded-none")) }, null, 2), s("span", {
140
+ class: "absolute inset-0",
141
+ style: d({ background: N.modelValue })
142
+ }, null, 4)], 2), c(h(x), {
143
+ "aria-label": N.fieldLabel,
144
+ class: u(q("input"))
145
+ }, null, 8, ["aria-label", "class"])]),
146
+ _: 1
147
+ }, 8, [
148
+ "model-value",
149
+ "disabled",
150
+ "class"
151
+ ])),
152
+ N.swatches?.length ? (f(), i(h(O), {
153
+ key: 2,
154
+ "model-value": N.modelValue,
155
+ class: u(q("swatches")),
156
+ "onUpdate:modelValue": t[0] ||= (e) => F(String(e))
157
+ }, {
158
+ default: _(() => [(f(!0), o(n, null, m(N.swatches, (e) => (f(), i(h(E), {
159
+ key: e,
160
+ value: e,
161
+ class: u(q("swatch"))
162
+ }, {
163
+ default: _(() => [c(h(D), { class: "size-full rounded-[inherit] bg-[var(--reka-color-swatch-color)]" })]),
164
+ _: 1
165
+ }, 8, ["value", "class"]))), 128))]),
166
+ _: 1
167
+ }, 8, ["model-value", "class"])) : a("", !0)
168
+ ], 2));
169
+ }
170
+ });
171
+ //#endregion
172
+ export { M as default };
@@ -74,25 +74,26 @@ type __VLS_Slots = {} & {
74
74
  create?: (props: typeof __VLS_139) => any;
75
75
  };
76
76
  declare const __VLS_base: import("vue").DefineComponent<ComboboxProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
77
- "update:open": (value: boolean) => any;
78
77
  "update:modelValue": (value: AcceptableValue) => any;
79
- create: (query: string) => any;
78
+ "update:open": (value: boolean) => any;
80
79
  highlight: (payload: {
81
80
  ref: HTMLElement;
82
81
  value: AcceptableValue;
83
82
  } | undefined) => any;
83
+ create: (query: string) => any;
84
84
  }, string, import("vue").PublicProps, Readonly<ComboboxProps> & Readonly<{
85
- "onUpdate:open"?: ((value: boolean) => any) | undefined;
86
85
  "onUpdate:modelValue"?: ((value: AcceptableValue) => any) | undefined;
87
- onCreate?: ((query: string) => any) | undefined;
86
+ "onUpdate:open"?: ((value: boolean) => any) | undefined;
88
87
  onHighlight?: ((payload: {
89
88
  ref: HTMLElement;
90
89
  value: AcceptableValue;
91
90
  } | undefined) => any) | undefined;
91
+ onCreate?: ((query: string) => any) | undefined;
92
92
  }>, {
93
+ disabled: boolean;
93
94
  unstyled: boolean;
94
95
  open: boolean;
95
- disabled: boolean;
96
+ defaultOpen: boolean;
96
97
  invalid: boolean;
97
98
  emptyText: string;
98
99
  create: boolean;
@@ -100,7 +101,6 @@ declare const __VLS_base: import("vue").DefineComponent<ComboboxProps, {}, {}, {
100
101
  virtual: boolean;
101
102
  estimateSize: number;
102
103
  overscan: number;
103
- defaultOpen: boolean;
104
104
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
105
105
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
106
106
  declare const _default: typeof __VLS_export;
@@ -0,0 +1,5 @@
1
+ import e from "./CommandPalette.vue_vue_type_script_setup_true_lang.js";
2
+ //#region src/components/CommandPalette.vue
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };
@@ -0,0 +1,63 @@
1
+ import type { CommandEntry, CommandItem } from '../composables/command-palette';
2
+ export interface CommandPaletteProps {
3
+ /** Commands, optionally grouped. An entry with `items` is a group. */
4
+ items?: CommandEntry[];
5
+ placeholder?: string;
6
+ /** Shown when the query matches nothing. Override for non-English apps. */
7
+ emptyText?: string;
8
+ /** Accessible name for the dialog, since a palette has no visible title. */
9
+ label?: string;
10
+ /**
11
+ * Global shortcut that opens it. `mod` is Command on Apple platforms and
12
+ * Control elsewhere. Pass `null` to bind nothing and drive `open` yourself.
13
+ */
14
+ hotkey?: string | null;
15
+ /** Close once a command is chosen. */
16
+ closeOnSelect?: boolean;
17
+ /** Hint row along the bottom. Set `false` to drop it. */
18
+ footer?: boolean;
19
+ /** Skip built-in classes; you take over styling entirely. */
20
+ unstyled?: boolean;
21
+ class?: string;
22
+ ui?: Partial<Record<'overlay' | 'content' | 'header' | 'icon' | 'input' | 'viewport' | 'group' | 'groupLabel' | 'item' | 'itemIcon' | 'itemLabel' | 'shortcut' | 'key' | 'empty' | 'footer' | 'list', string>>;
23
+ }
24
+ type __VLS_Props = CommandPaletteProps;
25
+ type __VLS_ModelProps = {
26
+ 'open'?: boolean;
27
+ };
28
+ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
29
+ declare var __VLS_59: {
30
+ query: string;
31
+ }, __VLS_81: {
32
+ item: CommandItem;
33
+ }, __VLS_93: {};
34
+ type __VLS_Slots = {} & {
35
+ empty?: (props: typeof __VLS_59) => any;
36
+ } & {
37
+ item?: (props: typeof __VLS_81) => any;
38
+ } & {
39
+ footer?: (props: typeof __VLS_93) => any;
40
+ };
41
+ declare const __VLS_base: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
42
+ select: (item: CommandItem) => any;
43
+ "update:open": (value: boolean) => any;
44
+ }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
45
+ onSelect?: ((item: CommandItem) => any) | undefined;
46
+ "onUpdate:open"?: ((value: boolean) => any) | undefined;
47
+ }>, {
48
+ unstyled: boolean;
49
+ label: string;
50
+ placeholder: string;
51
+ footer: boolean;
52
+ emptyText: string;
53
+ hotkey: string | null;
54
+ closeOnSelect: boolean;
55
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
56
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
57
+ declare const _default: typeof __VLS_export;
58
+ export default _default;
59
+ type __VLS_WithSlots<T, S> = T & {
60
+ new (): {
61
+ $slots: S;
62
+ };
63
+ };