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
package/dist/index.js CHANGED
@@ -35,60 +35,61 @@ import { resolveConfirm as oe, useConfirm as se, useConfirmState as ce } from ".
35
35
  import { dialogTheme as le } from "./theme/dialog.js";
36
36
  import ue from "./components/Dialog.js";
37
37
  import de from "./components/ConfirmDialog.js";
38
- import { $2aaf608024c21ca1$export$99faa760c7908e4f as fe } from "./node_modules/.pnpm/@internationalized_date@3.12.3/node_modules/@internationalized/date/dist/private/CalendarDate.js";
39
- import { formatIsoDate as pe, isoToday as me, toCalendarDate as he, toIsoDate as ge } from "./composables/date.js";
38
+ import { CalendarDate as fe, formatIsoDate as pe, isoToday as me, toCalendarDate as he, toIsoDate as ge } from "./composables/date.js";
40
39
  import { datePickerTheme as _e } from "./theme/date-picker.js";
41
40
  import ve from "./components/DatePicker.js";
42
41
  import ye from "./components/DateRangePicker.js";
43
- import { dropdownMenuTheme as be } from "./theme/dropdown-menu.js";
44
- import { isSeparator as xe, isSubmenu as Se } from "./composables/dropdown-menu.js";
45
- import Ce from "./components/DropdownMenu.js";
46
- import { emptyStateTheme as we } from "./theme/empty-state.js";
47
- import Te from "./components/EmptyState.js";
48
- import { fileUploadTheme as Ee } from "./theme/file-upload.js";
49
- import De from "./components/FileUpload.js";
50
- import Oe from "./components/Form.js";
51
- import { labelTheme as ke } from "./theme/label.js";
52
- import Ae from "./components/Label.js";
53
- import je from "./components/FormField.js";
54
- import Me from "./components/Input.js";
55
- import { lineChartTheme as Ne } from "./theme/line-chart.js";
56
- import Pe from "./components/LineChart.js";
57
- import { addDecimals as Fe, clampDecimal as Ie, compareDecimals as Le, formatDecimal as Re, formatForLocale as ze, isDecimal as Be, localeSeparators as Ve, parseDecimal as He, parseFromLocale as Ue, roundDecimal as We, toEditable as Ge } from "./composables/decimal.js";
58
- import { numberInputTheme as Ke } from "./theme/number-input.js";
59
- import qe from "./components/NumberInput.js";
60
- import { paginationTheme as Je } from "./theme/pagination.js";
61
- import Ye from "./components/Pagination.js";
62
- import { passwordInputTheme as Xe } from "./theme/password-input.js";
63
- import Ze from "./components/PasswordInput.js";
64
- import { progressTheme as Qe } from "./theme/progress.js";
65
- import $e from "./components/Progress.js";
66
- import { radioGroupTheme as et } from "./theme/radio-group.js";
67
- import tt from "./components/RadioGroup.js";
68
- import { selectTheme as nt } from "./theme/select.js";
69
- import rt from "./components/Select.js";
70
- import { separatorTheme as it } from "./theme/separator.js";
71
- import at from "./components/Separator.js";
72
- import { skeletonTheme as ot } from "./theme/skeleton.js";
73
- import st from "./components/Skeleton.js";
74
- import { sparklineTheme as ct } from "./theme/sparkline.js";
75
- import lt from "./components/Sparkline.js";
76
- import { statTheme as ut } from "./theme/stat.js";
77
- import dt from "./components/Stat.js";
78
- import { stepperTheme as ft } from "./theme/stepper.js";
79
- import pt from "./components/Stepper.js";
80
- import { switchTheme as mt } from "./theme/switch.js";
81
- import ht from "./components/Switch.js";
82
- import { getRowValue as gt, useDataTable as _t } from "./composables/data-table.js";
83
- import { tableTheme as vt } from "./theme/table.js";
84
- import yt from "./components/Table.js";
85
- import { tabsTheme as bt } from "./theme/tabs.js";
86
- import xt from "./components/Tabs.js";
87
- import St from "./components/Textarea.js";
88
- import { useToast as Ct, useToastState as wt } from "./composables/toast.js";
89
- import { toastTheme as Tt } from "./theme/toast.js";
90
- import Et from "./components/Toaster.js";
91
- import { tooltipTheme as Dt } from "./theme/tooltip.js";
92
- import Ot from "./components/Tooltip.js";
93
- import { IryxUi as kt, createIryxUi as At } from "./plugin.js";
94
- export { b as AXIS_GAP, a as Alert, d as App, p as Badge, h as Banner, F as BarChart, L as Breadcrumb, V as Button, U as ButtonGroup, x as CATEGORY_HEIGHT, S as CHAR_WIDTH, fe as CalendarDate, G as Card, P as ChartLegend, q as Checkbox, ae as Combobox, de as ConfirmDialog, ve as DatePicker, ye as DateRangePicker, ue as Dialog, Ce as DropdownMenu, Te as EmptyState, De as FileUpload, Oe as Form, je as FormField, Me as Input, kt as IryxUi, Ae as Label, Pe as LineChart, qe as NumberInput, Ye as Pagination, Ze as PasswordInput, $e as Progress, tt as RadioGroup, C as SERIES_SLOTS, rt as Select, at as Separator, st as Skeleton, lt as Sparkline, dt as Stat, pt as Stepper, ht as Switch, w as TOP_PAD, yt as Table, xt as Tabs, St as Textarea, Et as Toaster, Ot as Tooltip, Fe as addDecimals, i as alertTheme, c as applyTheme, f as badgeTheme, m as bannerTheme, M as barChartTheme, I as breadcrumbTheme, R as buttonGroupContextKey, H as buttonGroupTheme, B as buttonTheme, W as cardTheme, T as cartesianLayout, N as chartLegendTheme, K as checkboxTheme, Ie as clampDecimal, E as clampTooltip, l as clearTheme, ie as comboboxTheme, Le as compareDecimals, e as componentNames, At as createIryxUi, _e as datePickerTheme, t as defaultConfig, le as dialogTheme, be as dropdownMenuTheme, we as emptyStateTheme, g as extent, te as fieldBase, Ee as fileUploadTheme, _ as finiteValues, J as formContextKey, Y as formFieldContextKey, Re as formatDecimal, ze as formatForLocale, pe as formatIsoDate, X as getByPath, gt as getRowValue, o as initAppearance, ne as inputTheme, n as iryxUiConfigKey, Be as isDecimal, xe as isSeparator, Z as isStandardSchema, Se as isSubmenu, me as isoToday, Q as issuePath, ke as labelTheme, Ne as lineChartTheme, v as linearScale, Ve as localeSeparators, y as niceTicks, Ke as numberInputTheme, Je as paginationTheme, He as parseDecimal, Ue as parseFromLocale, Xe as passwordInputTheme, Qe as progressTheme, et as radioGroupTheme, oe as resolveConfirm, We as roundDecimal, nt as selectTheme, it as separatorTheme, D as seriesColor, ot as skeletonTheme, O as slotOf, ct as sparklineTheme, ut as statTheme, ft as stepperTheme, mt as switchTheme, vt as tableTheme, bt as tabsTheme, re as textareaTheme, u as themes, he as toCalendarDate, Ge as toEditable, ge as toIsoDate, Tt as toastTheme, k as tooltipHalfWidth, Dt as tooltipTheme, s as useAppearance, z as useButtonGroup, se as useConfirm, ce as useConfirmState, _t as useDataTable, j as useElementSize, $ as useForm, ee as useFormField, r as useIryxUiConfig, Ct as useToast, wt as useToastState, A as warnOnSlotOverflow };
42
+ import { drawerTheme as be } from "./theme/drawer.js";
43
+ import xe from "./components/Drawer.js";
44
+ import { dropdownMenuTheme as Se } from "./theme/dropdown-menu.js";
45
+ import { isSeparator as Ce, isSubmenu as we } from "./composables/dropdown-menu.js";
46
+ import Te from "./components/DropdownMenu.js";
47
+ import { emptyStateTheme as Ee } from "./theme/empty-state.js";
48
+ import De from "./components/EmptyState.js";
49
+ import { fileUploadTheme as Oe } from "./theme/file-upload.js";
50
+ import ke from "./components/FileUpload.js";
51
+ import Ae from "./components/Form.js";
52
+ import { labelTheme as je } from "./theme/label.js";
53
+ import Me from "./components/Label.js";
54
+ import Ne from "./components/FormField.js";
55
+ import Pe from "./components/Input.js";
56
+ import { lineChartTheme as Fe } from "./theme/line-chart.js";
57
+ import Ie from "./components/LineChart.js";
58
+ import { addDecimals as Le, clampDecimal as Re, compareDecimals as ze, formatDecimal as Be, formatForLocale as Ve, isDecimal as He, localeSeparators as Ue, parseDecimal as We, parseFromLocale as Ge, roundDecimal as Ke, toEditable as qe } from "./composables/decimal.js";
59
+ import { numberInputTheme as Je } from "./theme/number-input.js";
60
+ import Ye from "./components/NumberInput.js";
61
+ import { paginationTheme as Xe } from "./theme/pagination.js";
62
+ import Ze from "./components/Pagination.js";
63
+ import { passwordInputTheme as Qe } from "./theme/password-input.js";
64
+ import $e from "./components/PasswordInput.js";
65
+ import { progressTheme as et } from "./theme/progress.js";
66
+ import tt from "./components/Progress.js";
67
+ import { radioGroupTheme as nt } from "./theme/radio-group.js";
68
+ import rt from "./components/RadioGroup.js";
69
+ import { selectTheme as it } from "./theme/select.js";
70
+ import at from "./components/Select.js";
71
+ import { separatorTheme as ot } from "./theme/separator.js";
72
+ import st from "./components/Separator.js";
73
+ import { skeletonTheme as ct } from "./theme/skeleton.js";
74
+ import lt from "./components/Skeleton.js";
75
+ import { sparklineTheme as ut } from "./theme/sparkline.js";
76
+ import dt from "./components/Sparkline.js";
77
+ import { statTheme as ft } from "./theme/stat.js";
78
+ import pt from "./components/Stat.js";
79
+ import { stepperTheme as mt } from "./theme/stepper.js";
80
+ import ht from "./components/Stepper.js";
81
+ import { switchTheme as gt } from "./theme/switch.js";
82
+ import _t from "./components/Switch.js";
83
+ import { getRowValue as vt, useDataTable as yt } from "./composables/data-table.js";
84
+ import { tableTheme as bt } from "./theme/table.js";
85
+ import xt from "./components/Table.js";
86
+ import { tabsTheme as St } from "./theme/tabs.js";
87
+ import Ct from "./components/Tabs.js";
88
+ import wt from "./components/Textarea.js";
89
+ import { useToast as Tt, useToastState as Et } from "./composables/toast.js";
90
+ import { toastTheme as Dt } from "./theme/toast.js";
91
+ import Ot from "./components/Toaster.js";
92
+ import { tooltipTheme as kt } from "./theme/tooltip.js";
93
+ import At from "./components/Tooltip.js";
94
+ import { IryxUi as jt, createIryxUi as Mt } from "./plugin.js";
95
+ export { b as AXIS_GAP, a as Alert, d as App, p as Badge, h as Banner, F as BarChart, L as Breadcrumb, V as Button, U as ButtonGroup, x as CATEGORY_HEIGHT, S as CHAR_WIDTH, fe as CalendarDate, G as Card, P as ChartLegend, q as Checkbox, ae as Combobox, de as ConfirmDialog, ve as DatePicker, ye as DateRangePicker, ue as Dialog, xe as Drawer, Te as DropdownMenu, De as EmptyState, ke as FileUpload, Ae as Form, Ne as FormField, Pe as Input, jt as IryxUi, Me as Label, Ie as LineChart, Ye as NumberInput, Ze as Pagination, $e as PasswordInput, tt as Progress, rt as RadioGroup, C as SERIES_SLOTS, at as Select, st as Separator, lt as Skeleton, dt as Sparkline, pt as Stat, ht as Stepper, _t as Switch, w as TOP_PAD, xt as Table, Ct as Tabs, wt as Textarea, Ot as Toaster, At as Tooltip, Le as addDecimals, i as alertTheme, c as applyTheme, f as badgeTheme, m as bannerTheme, M as barChartTheme, I as breadcrumbTheme, R as buttonGroupContextKey, H as buttonGroupTheme, B as buttonTheme, W as cardTheme, T as cartesianLayout, N as chartLegendTheme, K as checkboxTheme, Re as clampDecimal, E as clampTooltip, l as clearTheme, ie as comboboxTheme, ze as compareDecimals, e as componentNames, Mt as createIryxUi, _e as datePickerTheme, t as defaultConfig, le as dialogTheme, be as drawerTheme, Se as dropdownMenuTheme, Ee as emptyStateTheme, g as extent, te as fieldBase, Oe as fileUploadTheme, _ as finiteValues, J as formContextKey, Y as formFieldContextKey, Be as formatDecimal, Ve as formatForLocale, pe as formatIsoDate, X as getByPath, vt as getRowValue, o as initAppearance, ne as inputTheme, n as iryxUiConfigKey, He as isDecimal, Ce as isSeparator, Z as isStandardSchema, we as isSubmenu, me as isoToday, Q as issuePath, je as labelTheme, Fe as lineChartTheme, v as linearScale, Ue as localeSeparators, y as niceTicks, Je as numberInputTheme, Xe as paginationTheme, We as parseDecimal, Ge as parseFromLocale, Qe as passwordInputTheme, et as progressTheme, nt as radioGroupTheme, oe as resolveConfirm, Ke as roundDecimal, it as selectTheme, ot as separatorTheme, D as seriesColor, ct as skeletonTheme, O as slotOf, ut as sparklineTheme, ft as statTheme, mt as stepperTheme, gt as switchTheme, bt as tableTheme, St as tabsTheme, re as textareaTheme, u as themes, he as toCalendarDate, qe as toEditable, ge as toIsoDate, Dt as toastTheme, k as tooltipHalfWidth, kt as tooltipTheme, s as useAppearance, z as useButtonGroup, se as useConfirm, ce as useConfirmState, yt as useDataTable, j as useElementSize, $ as useForm, ee as useFormField, r as useIryxUiConfig, Tt as useToast, Et as useToastState, A as warnOnSlotOverflow };
@@ -0,0 +1,110 @@
1
+ export declare const drawerTheme: import("tailwind-variants").TVReturnType<{
2
+ side: {
3
+ right: {
4
+ content: string;
5
+ handle: string;
6
+ };
7
+ left: {
8
+ content: string;
9
+ handle: string;
10
+ };
11
+ top: {
12
+ content: string;
13
+ handle: string;
14
+ };
15
+ bottom: {
16
+ content: string;
17
+ handle: string;
18
+ };
19
+ };
20
+ size: {
21
+ sm: {};
22
+ md: {};
23
+ lg: {};
24
+ xl: {};
25
+ full: {};
26
+ };
27
+ }, {
28
+ overlay: string;
29
+ content: string;
30
+ handle: string;
31
+ header: string;
32
+ title: string;
33
+ description: string;
34
+ body: string;
35
+ footer: string;
36
+ close: string;
37
+ }, undefined, {
38
+ side: {
39
+ right: {
40
+ content: string;
41
+ handle: string;
42
+ };
43
+ left: {
44
+ content: string;
45
+ handle: string;
46
+ };
47
+ top: {
48
+ content: string;
49
+ handle: string;
50
+ };
51
+ bottom: {
52
+ content: string;
53
+ handle: string;
54
+ };
55
+ };
56
+ size: {
57
+ sm: {};
58
+ md: {};
59
+ lg: {};
60
+ xl: {};
61
+ full: {};
62
+ };
63
+ }, {
64
+ overlay: string;
65
+ content: string;
66
+ handle: string;
67
+ header: string;
68
+ title: string;
69
+ description: string;
70
+ body: string;
71
+ footer: string;
72
+ close: string;
73
+ }, import("tailwind-variants").TVReturnType<{
74
+ side: {
75
+ right: {
76
+ content: string;
77
+ handle: string;
78
+ };
79
+ left: {
80
+ content: string;
81
+ handle: string;
82
+ };
83
+ top: {
84
+ content: string;
85
+ handle: string;
86
+ };
87
+ bottom: {
88
+ content: string;
89
+ handle: string;
90
+ };
91
+ };
92
+ size: {
93
+ sm: {};
94
+ md: {};
95
+ lg: {};
96
+ xl: {};
97
+ full: {};
98
+ };
99
+ }, {
100
+ overlay: string;
101
+ content: string;
102
+ handle: string;
103
+ header: string;
104
+ title: string;
105
+ description: string;
106
+ body: string;
107
+ footer: string;
108
+ close: string;
109
+ }, undefined, unknown, unknown, undefined>>;
110
+ export type DrawerSlots = keyof ReturnType<typeof drawerTheme>;
@@ -0,0 +1,100 @@
1
+ import { tv as e } from "tailwind-variants";
2
+ //#region src/theme/drawer.ts
3
+ var t = e({
4
+ slots: {
5
+ overlay: "fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-fade-out data-[state=open]:animate-fade-in",
6
+ content: "iryx-drawer fixed z-50 flex touch-none flex-col gap-4 border-border bg-background p-6 text-foreground shadow-lg outline-none",
7
+ handle: "shrink-0 rounded-full bg-border",
8
+ header: "flex flex-col gap-1",
9
+ title: "text-base leading-none font-semibold",
10
+ description: "text-sm text-muted-foreground",
11
+ body: "-m-1 min-h-0 flex-1 touch-auto overflow-y-auto p-1",
12
+ footer: "flex flex-wrap items-center justify-end gap-2",
13
+ close: "absolute top-4 right-4 rounded-lg p-1 text-muted-foreground transition-colors outline-none hover:bg-accent hover:text-accent-foreground focus-visible:ring-2 focus-visible:ring-primary/50 [&_svg]:size-4"
14
+ },
15
+ variants: {
16
+ side: {
17
+ right: {
18
+ content: "inset-y-0 right-0 h-dvh w-full border-l data-[state=closed]:animate-drawer-out-right data-[state=open]:animate-drawer-in-right",
19
+ handle: "absolute top-1/2 left-1.5 h-10 w-1 -translate-y-1/2"
20
+ },
21
+ left: {
22
+ content: "inset-y-0 left-0 h-dvh w-full border-r data-[state=closed]:animate-drawer-out-left data-[state=open]:animate-drawer-in-left",
23
+ handle: "absolute top-1/2 right-1.5 h-10 w-1 -translate-y-1/2"
24
+ },
25
+ top: {
26
+ content: "inset-x-0 top-0 w-full rounded-b-2xl border-b pb-4 data-[state=closed]:animate-drawer-out-top data-[state=open]:animate-drawer-in-top",
27
+ handle: "order-last mx-auto h-1 w-10"
28
+ },
29
+ bottom: {
30
+ content: "inset-x-0 bottom-0 w-full rounded-t-2xl border-t pt-4 data-[state=closed]:animate-drawer-out-bottom data-[state=open]:animate-drawer-in-bottom",
31
+ handle: "mx-auto h-1 w-10"
32
+ }
33
+ },
34
+ size: {
35
+ sm: {},
36
+ md: {},
37
+ lg: {},
38
+ xl: {},
39
+ full: {}
40
+ }
41
+ },
42
+ compoundVariants: [
43
+ {
44
+ side: ["left", "right"],
45
+ size: "sm",
46
+ class: { content: "sm:max-w-sm" }
47
+ },
48
+ {
49
+ side: ["left", "right"],
50
+ size: "md",
51
+ class: { content: "sm:max-w-md" }
52
+ },
53
+ {
54
+ side: ["left", "right"],
55
+ size: "lg",
56
+ class: { content: "sm:max-w-lg" }
57
+ },
58
+ {
59
+ side: ["left", "right"],
60
+ size: "xl",
61
+ class: { content: "sm:max-w-2xl" }
62
+ },
63
+ {
64
+ side: ["left", "right"],
65
+ size: "full",
66
+ class: { content: "max-w-none" }
67
+ },
68
+ {
69
+ side: ["top", "bottom"],
70
+ size: "sm",
71
+ class: { content: "max-h-[25dvh]" }
72
+ },
73
+ {
74
+ side: ["top", "bottom"],
75
+ size: "md",
76
+ class: { content: "max-h-[40dvh]" }
77
+ },
78
+ {
79
+ side: ["top", "bottom"],
80
+ size: "lg",
81
+ class: { content: "max-h-[60dvh]" }
82
+ },
83
+ {
84
+ side: ["top", "bottom"],
85
+ size: "xl",
86
+ class: { content: "max-h-[80dvh]" }
87
+ },
88
+ {
89
+ side: ["top", "bottom"],
90
+ size: "full",
91
+ class: { content: "h-dvh max-h-none rounded-none" }
92
+ }
93
+ ],
94
+ defaultVariants: {
95
+ side: "right",
96
+ size: "md"
97
+ }
98
+ });
99
+ //#endregion
100
+ export { t as drawerTheme };
@@ -11,6 +11,7 @@ export * from './checkbox';
11
11
  export * from './combobox';
12
12
  export * from './date-picker';
13
13
  export * from './dialog';
14
+ export * from './drawer';
14
15
  export * from './dropdown-menu';
15
16
  export * from './empty-state';
16
17
  export * from './file-upload';
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "iryx-ui",
3
3
  "type": "module",
4
- "version": "0.10.2",
4
+ "version": "0.12.0",
5
5
  "description": "A Vue 3 component library built on Reka UI and Tailwind CSS v4.",
6
6
  "author": "therok1",
7
7
  "license": "MIT",
@@ -55,13 +55,14 @@
55
55
  "@hugeicons/vue": "^1.0.7",
56
56
  "@internationalized/date": "^3.12.3",
57
57
  "@nuxt/kit": "^4.4.8",
58
- "reka-ui": "^2.9.10",
58
+ "reka-ui": "~2.10.3",
59
59
  "tailwind-merge": "^3.6.0",
60
60
  "tailwind-variants": "^3.2.2"
61
61
  },
62
62
  "devDependencies": {
63
63
  "@vitejs/plugin-vue": "^6.0.7",
64
64
  "@vue/test-utils": "^2.4.11",
65
+ "axe-core": "^4.13.0",
65
66
  "happy-dom": "^20.10.2",
66
67
  "typescript": "^6.0.3",
67
68
  "vite": "^8.0.16",
package/theme.css CHANGED
@@ -200,6 +200,19 @@
200
200
  --animate-dialog-in: dialog-in 150ms ease-out;
201
201
  --animate-dialog-out: dialog-out 150ms ease-in;
202
202
  --animate-toast-in: toast-in 150ms ease-out;
203
+ /*
204
+ * One easing for every drawer transition, enter/exit and drag-release alike,
205
+ * so a panel that is let go mid-swipe finishes the way it would have opened.
206
+ */
207
+ --iryx-drawer-ease: cubic-bezier(0.32, 0.72, 0, 1);
208
+ --animate-drawer-in-right: drawer-in-right 300ms var(--iryx-drawer-ease);
209
+ --animate-drawer-out-right: drawer-out-right 300ms var(--iryx-drawer-ease);
210
+ --animate-drawer-in-left: drawer-in-left 300ms var(--iryx-drawer-ease);
211
+ --animate-drawer-out-left: drawer-out-left 300ms var(--iryx-drawer-ease);
212
+ --animate-drawer-in-top: drawer-in-top 300ms var(--iryx-drawer-ease);
213
+ --animate-drawer-out-top: drawer-out-top 300ms var(--iryx-drawer-ease);
214
+ --animate-drawer-in-bottom: drawer-in-bottom 300ms var(--iryx-drawer-ease);
215
+ --animate-drawer-out-bottom: drawer-out-bottom 300ms var(--iryx-drawer-ease);
203
216
  }
204
217
 
205
218
  /* Indeterminate Progress: slide a short bar back and forth across the track. */
@@ -250,3 +263,104 @@
250
263
  transform: translateY(0.5rem);
251
264
  }
252
265
  }
266
+
267
+ /*
268
+ * Drawer enter/exit, one pair per edge.
269
+ *
270
+ * These animate the independent `translate` property, NOT `transform` — the
271
+ * exact opposite of the dialog's constraint, and for the same underlying
272
+ * reason. Reka's drawer follows the finger by writing `transform` from
273
+ * `--drawer-swipe-movement-*` (see `.iryx-drawer` below), so a keyframe on
274
+ * `transform` would clobber the drag offset and the panel would refuse to
275
+ * move under the pointer. `translate` composes with it instead.
276
+ *
277
+ * The slide is the whole animation — fading a panel that is already moving
278
+ * reads as two effects fighting.
279
+ */
280
+ @keyframes drawer-in-right {
281
+ from {
282
+ translate: 100% 0;
283
+ }
284
+ }
285
+
286
+ @keyframes drawer-out-right {
287
+ to {
288
+ translate: 100% 0;
289
+ }
290
+ }
291
+
292
+ @keyframes drawer-in-left {
293
+ from {
294
+ translate: -100% 0;
295
+ }
296
+ }
297
+
298
+ @keyframes drawer-out-left {
299
+ to {
300
+ translate: -100% 0;
301
+ }
302
+ }
303
+
304
+ @keyframes drawer-in-top {
305
+ from {
306
+ translate: 0 -100%;
307
+ }
308
+ }
309
+
310
+ @keyframes drawer-out-top {
311
+ to {
312
+ translate: 0 -100%;
313
+ }
314
+ }
315
+
316
+ @keyframes drawer-in-bottom {
317
+ from {
318
+ translate: 0 100%;
319
+ }
320
+ }
321
+
322
+ @keyframes drawer-out-bottom {
323
+ to {
324
+ translate: 0 100%;
325
+ }
326
+ }
327
+
328
+ /*
329
+ * Drawer drag plumbing.
330
+ *
331
+ * This is plain CSS rather than Tailwind utilities because it is variable
332
+ * arithmetic keyed on an attribute Reka sets at runtime — there is no class
333
+ * name to generate. Reka writes the live drag offset into
334
+ * `--drawer-swipe-movement-x/y` and the resting snap position into
335
+ * `--drawer-snap-point-offset`; both act on the swipe axis, so they add.
336
+ *
337
+ * `[data-swiping]` kills the transition while a finger is down, or the panel
338
+ * lags behind the pointer by a whole easing curve.
339
+ */
340
+ @layer components {
341
+ .iryx-drawer {
342
+ transition: transform 300ms var(--iryx-drawer-ease);
343
+ }
344
+
345
+ .iryx-drawer[data-swipe-direction="up"],
346
+ .iryx-drawer[data-swipe-direction="down"] {
347
+ transform: translate3d(
348
+ 0,
349
+ calc(var(--drawer-swipe-movement-y, 0px) + var(--drawer-snap-point-offset, 0px)),
350
+ 0
351
+ );
352
+ }
353
+
354
+ .iryx-drawer[data-swipe-direction="left"],
355
+ .iryx-drawer[data-swipe-direction="right"] {
356
+ transform: translate3d(
357
+ calc(var(--drawer-swipe-movement-x, 0px) + var(--drawer-snap-point-offset, 0px)),
358
+ 0,
359
+ 0
360
+ );
361
+ }
362
+
363
+ .iryx-drawer[data-swiping] {
364
+ transition-duration: 0ms;
365
+ }
366
+ }