@zentauri-ui/zentauri-components 0.0.83 → 0.0.91

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 (132) hide show
  1. package/README.md +50 -29
  2. package/dist/ui/accordion.cjs +311 -0
  3. package/dist/ui/accordion.cjs.map +1 -0
  4. package/dist/ui/accordion.d.cts +70 -0
  5. package/dist/ui/accordion.d.ts +70 -0
  6. package/dist/ui/accordion.js +286 -0
  7. package/dist/ui/accordion.js.map +1 -0
  8. package/dist/ui/alert.cjs +257 -0
  9. package/dist/ui/alert.cjs.map +1 -0
  10. package/dist/ui/alert.d.cts +66 -0
  11. package/dist/ui/alert.d.ts +66 -0
  12. package/dist/ui/alert.js +224 -0
  13. package/dist/ui/alert.js.map +1 -0
  14. package/dist/ui/badge.cjs +192 -0
  15. package/dist/ui/badge.cjs.map +1 -0
  16. package/dist/ui/badge.d.cts +37 -0
  17. package/dist/ui/badge.d.ts +37 -0
  18. package/dist/ui/badge.js +165 -0
  19. package/dist/ui/badge.js.map +1 -0
  20. package/dist/ui/buttons.cjs +202 -0
  21. package/dist/ui/buttons.cjs.map +1 -0
  22. package/dist/ui/buttons.d.cts +27 -0
  23. package/dist/ui/buttons.d.ts +27 -0
  24. package/dist/ui/buttons.js +176 -0
  25. package/dist/ui/buttons.js.map +1 -0
  26. package/dist/ui/card.cjs +293 -0
  27. package/dist/ui/card.cjs.map +1 -0
  28. package/dist/ui/card.d.cts +77 -0
  29. package/dist/ui/card.d.ts +77 -0
  30. package/dist/ui/card.js +258 -0
  31. package/dist/ui/card.js.map +1 -0
  32. package/dist/ui/divider.cjs +229 -0
  33. package/dist/ui/divider.cjs.map +1 -0
  34. package/dist/ui/divider.d.cts +39 -0
  35. package/dist/ui/divider.d.ts +39 -0
  36. package/dist/ui/divider.js +200 -0
  37. package/dist/ui/divider.js.map +1 -0
  38. package/dist/ui/drawer.cjs +408 -0
  39. package/dist/ui/drawer.cjs.map +1 -0
  40. package/dist/ui/drawer.d.cts +81 -0
  41. package/dist/ui/drawer.d.ts +81 -0
  42. package/dist/ui/drawer.js +383 -0
  43. package/dist/ui/drawer.js.map +1 -0
  44. package/dist/ui/dropdown.cjs +302 -0
  45. package/dist/ui/dropdown.cjs.map +1 -0
  46. package/dist/ui/dropdown.d.cts +50 -0
  47. package/dist/ui/dropdown.d.ts +50 -0
  48. package/dist/ui/dropdown.js +278 -0
  49. package/dist/ui/dropdown.js.map +1 -0
  50. package/dist/ui/empty-state.cjs +186 -0
  51. package/dist/ui/empty-state.cjs.map +1 -0
  52. package/dist/ui/empty-state.d.cts +55 -0
  53. package/dist/ui/empty-state.d.ts +55 -0
  54. package/dist/ui/empty-state.js +154 -0
  55. package/dist/ui/empty-state.js.map +1 -0
  56. package/dist/ui/index.d.cts +27 -1164
  57. package/dist/ui/index.d.ts +27 -1164
  58. package/dist/ui/inputs.cjs +458 -0
  59. package/dist/ui/inputs.cjs.map +1 -0
  60. package/dist/ui/inputs.d.cts +35 -0
  61. package/dist/ui/inputs.d.ts +35 -0
  62. package/dist/ui/inputs.js +432 -0
  63. package/dist/ui/inputs.js.map +1 -0
  64. package/dist/ui/modal.cjs +406 -0
  65. package/dist/ui/modal.cjs.map +1 -0
  66. package/dist/ui/modal.d.cts +84 -0
  67. package/dist/ui/modal.d.ts +84 -0
  68. package/dist/ui/modal.js +384 -0
  69. package/dist/ui/modal.js.map +1 -0
  70. package/dist/ui/pagination.cjs +523 -0
  71. package/dist/ui/pagination.cjs.map +1 -0
  72. package/dist/ui/pagination.d.cts +114 -0
  73. package/dist/ui/pagination.d.ts +114 -0
  74. package/dist/ui/pagination.js +494 -0
  75. package/dist/ui/pagination.js.map +1 -0
  76. package/dist/ui/progress.cjs +268 -0
  77. package/dist/ui/progress.cjs.map +1 -0
  78. package/dist/ui/progress.d.cts +61 -0
  79. package/dist/ui/progress.d.ts +61 -0
  80. package/dist/ui/progress.js +237 -0
  81. package/dist/ui/progress.js.map +1 -0
  82. package/dist/ui/select.cjs +360 -0
  83. package/dist/ui/select.cjs.map +1 -0
  84. package/dist/ui/select.d.cts +73 -0
  85. package/dist/ui/select.d.ts +73 -0
  86. package/dist/ui/select.js +327 -0
  87. package/dist/ui/select.js.map +1 -0
  88. package/dist/ui/skeleton.cjs +576 -0
  89. package/dist/ui/skeleton.cjs.map +1 -0
  90. package/dist/ui/skeleton.d.cts +90 -0
  91. package/dist/ui/skeleton.d.ts +90 -0
  92. package/dist/ui/skeleton.js +544 -0
  93. package/dist/ui/skeleton.js.map +1 -0
  94. package/dist/ui/spinner.cjs +219 -0
  95. package/dist/ui/spinner.cjs.map +1 -0
  96. package/dist/ui/spinner.d.cts +27 -0
  97. package/dist/ui/spinner.d.ts +27 -0
  98. package/dist/ui/spinner.js +193 -0
  99. package/dist/ui/spinner.js.map +1 -0
  100. package/dist/ui/table.cjs +328 -0
  101. package/dist/ui/table.cjs.map +1 -0
  102. package/dist/ui/table.d.cts +81 -0
  103. package/dist/ui/table.d.ts +81 -0
  104. package/dist/ui/table.js +293 -0
  105. package/dist/ui/table.js.map +1 -0
  106. package/dist/ui/tabs.cjs +300 -0
  107. package/dist/ui/tabs.cjs.map +1 -0
  108. package/dist/ui/tabs.d.cts +58 -0
  109. package/dist/ui/tabs.d.ts +58 -0
  110. package/dist/ui/tabs.js +274 -0
  111. package/dist/ui/tabs.js.map +1 -0
  112. package/dist/ui/toast.cjs +285 -0
  113. package/dist/ui/toast.cjs.map +1 -0
  114. package/dist/ui/toast.d.cts +86 -0
  115. package/dist/ui/toast.d.ts +86 -0
  116. package/dist/ui/toast.js +258 -0
  117. package/dist/ui/toast.js.map +1 -0
  118. package/dist/ui/toggle.cjs +185 -0
  119. package/dist/ui/toggle.cjs.map +1 -0
  120. package/dist/ui/toggle.d.cts +37 -0
  121. package/dist/ui/toggle.d.ts +37 -0
  122. package/dist/ui/toggle.js +158 -0
  123. package/dist/ui/toggle.js.map +1 -0
  124. package/dist/ui/tooltip.cjs +242 -0
  125. package/dist/ui/tooltip.cjs.map +1 -0
  126. package/dist/ui/tooltip.d.cts +46 -0
  127. package/dist/ui/tooltip.d.ts +46 -0
  128. package/dist/ui/tooltip.js +214 -0
  129. package/dist/ui/tooltip.js.map +1 -0
  130. package/dist/variants-1Bx3BEeS.d.cts +8 -0
  131. package/dist/variants-1Bx3BEeS.d.ts +8 -0
  132. package/package.json +7 -1
@@ -0,0 +1,114 @@
1
+ import * as class_variance_authority from 'class-variance-authority';
2
+ import { VariantProps } from 'class-variance-authority';
3
+ import * as class_variance_authority_types from 'class-variance-authority/types';
4
+ import * as react from 'react';
5
+ import { ComponentPropsWithoutRef } from 'react';
6
+ import { b as buttonVariants } from '../variants-1Bx3BEeS.cjs';
7
+
8
+ declare const Pagination: react.ForwardRefExoticComponent<Omit<Omit<react.DetailedHTMLProps<react.HTMLAttributes<HTMLElement>, HTMLElement>, "ref">, "onChange"> & class_variance_authority.VariantProps<(props?: ({
9
+ appearance?: "default" | "outline" | "link" | "ghost" | "sky" | "rose" | "purple" | "pink" | "orange" | "yellow" | "teal" | "indigo" | "emerald" | "gradient-blue" | "gradient-green" | "gradient-red" | "gradient-yellow" | "gradient-purple" | "gradient-teal" | "gradient-indigo" | "gradient-pink" | "gradient-orange" | "gray" | "violet" | "secondary" | "destructive" | "glass" | "amber" | null | undefined;
10
+ size?: "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | "icon" | null | undefined;
11
+ } & class_variance_authority_types.ClassProp) | undefined) => string> & {
12
+ pageCount: number;
13
+ page?: number;
14
+ defaultPage?: number;
15
+ onPageChange?: (page: number) => void;
16
+ siblingCount?: number;
17
+ boundaryCount?: number;
18
+ showPrevNext?: boolean;
19
+ prevLabel?: string;
20
+ nextLabel?: string;
21
+ ellipsisLabel?: string;
22
+ getPageHref?: (page: number) => string | undefined;
23
+ } & react.RefAttributes<HTMLElement>>;
24
+
25
+ type PaginationPageItem$1 = {
26
+ type: "page";
27
+ value: number;
28
+ } | {
29
+ type: "ellipsis";
30
+ key: string;
31
+ };
32
+ type BuildPaginationItemsParams = {
33
+ pageCount: number;
34
+ currentPage: number;
35
+ siblingCount: number;
36
+ boundaryCount: number;
37
+ };
38
+ /**
39
+ * Builds the ordered list of page numbers and ellipsis markers for a pagination control.
40
+ *
41
+ * Args:
42
+ * pageCount: Total number of pages (must be >= 0).
43
+ * currentPage: Active page index (1-based).
44
+ * siblingCount: How many page buttons to show on each side of the current page.
45
+ * boundaryCount: How many pages to pin at the start and end of the range.
46
+ *
47
+ * Returns:
48
+ * A list of items suitable for rendering, e.g. [1, ellipsis, 4,5,6, ellipsis, 20].
49
+ */
50
+ declare function buildPaginationItems({ pageCount, currentPage, siblingCount, boundaryCount, }: BuildPaginationItemsParams): PaginationPageItem$1[];
51
+ declare function clampPage(page: number, pageCount: number): number;
52
+
53
+ type PaginationAppearance = NonNullable<VariantProps<typeof buttonVariants>["appearance"]>;
54
+ type PaginationSize = NonNullable<VariantProps<typeof buttonVariants>["size"]>;
55
+ type PaginationPageItem = PaginationPageItem$1;
56
+ type UsePaginationParams = {
57
+ pageCount: number;
58
+ page?: number;
59
+ defaultPage?: number;
60
+ siblingCount?: number;
61
+ boundaryCount?: number;
62
+ onPageChange?: (page: number) => void;
63
+ };
64
+ type UsePaginationResult = {
65
+ /** 1-based active page, clamped to `[1, pageCount]`. */
66
+ currentPage: number;
67
+ pageCount: number;
68
+ items: PaginationPageItem[];
69
+ setPage: (page: number) => void;
70
+ goPrev: () => void;
71
+ goNext: () => void;
72
+ canGoPrev: boolean;
73
+ canGoNext: boolean;
74
+ };
75
+ type PaginationProps = Omit<ComponentPropsWithoutRef<"nav">, "onChange"> & VariantProps<typeof buttonVariants> & {
76
+ pageCount: number;
77
+ page?: number;
78
+ defaultPage?: number;
79
+ onPageChange?: (page: number) => void;
80
+ /**
81
+ * Number of page buttons to show on each side of the current page (the “middle” window).
82
+ * @defaultValue 1
83
+ */
84
+ siblingCount?: number;
85
+ /**
86
+ * Number of pages to keep visible at the start and end of the range.
87
+ * @defaultValue 1
88
+ */
89
+ boundaryCount?: number;
90
+ showPrevNext?: boolean;
91
+ prevLabel?: string;
92
+ nextLabel?: string;
93
+ ellipsisLabel?: string;
94
+ /**
95
+ * When set, page controls render as anchors suitable for URL-based pagination.
96
+ */
97
+ getPageHref?: (page: number) => string | undefined;
98
+ };
99
+
100
+ declare function usePagination({ pageCount, page, defaultPage, siblingCount, boundaryCount, onPageChange, }: UsePaginationParams): UsePaginationResult;
101
+
102
+ /**
103
+ * Layout and chrome for the page list cluster. Appearance and size keys align with
104
+ * `components/ui/buttons/variants.ts` for consistent design-system tokens.
105
+ */
106
+ declare const paginationListVariants: (props?: ({
107
+ appearance?: "default" | "outline" | "link" | "ghost" | "sky" | "rose" | "purple" | "pink" | "orange" | "yellow" | "teal" | "indigo" | "emerald" | "gradient-blue" | "gradient-green" | "gradient-red" | "gradient-yellow" | "gradient-purple" | "gradient-teal" | "gradient-indigo" | "gradient-pink" | "gradient-orange" | "gray" | "violet" | "secondary" | "destructive" | "glass" | "amber" | null | undefined;
108
+ size?: "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | "icon" | null | undefined;
109
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
110
+ declare const paginationEllipsisVariants: (props?: ({
111
+ size?: "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | "icon" | null | undefined;
112
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
113
+
114
+ export { Pagination, type PaginationAppearance, type PaginationPageItem, type PaginationProps, type PaginationSize, type UsePaginationParams, type UsePaginationResult, buildPaginationItems, clampPage, paginationEllipsisVariants, paginationListVariants, usePagination };
@@ -0,0 +1,114 @@
1
+ import * as class_variance_authority from 'class-variance-authority';
2
+ import { VariantProps } from 'class-variance-authority';
3
+ import * as class_variance_authority_types from 'class-variance-authority/types';
4
+ import * as react from 'react';
5
+ import { ComponentPropsWithoutRef } from 'react';
6
+ import { b as buttonVariants } from '../variants-1Bx3BEeS.js';
7
+
8
+ declare const Pagination: react.ForwardRefExoticComponent<Omit<Omit<react.DetailedHTMLProps<react.HTMLAttributes<HTMLElement>, HTMLElement>, "ref">, "onChange"> & class_variance_authority.VariantProps<(props?: ({
9
+ appearance?: "default" | "outline" | "link" | "ghost" | "sky" | "rose" | "purple" | "pink" | "orange" | "yellow" | "teal" | "indigo" | "emerald" | "gradient-blue" | "gradient-green" | "gradient-red" | "gradient-yellow" | "gradient-purple" | "gradient-teal" | "gradient-indigo" | "gradient-pink" | "gradient-orange" | "gray" | "violet" | "secondary" | "destructive" | "glass" | "amber" | null | undefined;
10
+ size?: "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | "icon" | null | undefined;
11
+ } & class_variance_authority_types.ClassProp) | undefined) => string> & {
12
+ pageCount: number;
13
+ page?: number;
14
+ defaultPage?: number;
15
+ onPageChange?: (page: number) => void;
16
+ siblingCount?: number;
17
+ boundaryCount?: number;
18
+ showPrevNext?: boolean;
19
+ prevLabel?: string;
20
+ nextLabel?: string;
21
+ ellipsisLabel?: string;
22
+ getPageHref?: (page: number) => string | undefined;
23
+ } & react.RefAttributes<HTMLElement>>;
24
+
25
+ type PaginationPageItem$1 = {
26
+ type: "page";
27
+ value: number;
28
+ } | {
29
+ type: "ellipsis";
30
+ key: string;
31
+ };
32
+ type BuildPaginationItemsParams = {
33
+ pageCount: number;
34
+ currentPage: number;
35
+ siblingCount: number;
36
+ boundaryCount: number;
37
+ };
38
+ /**
39
+ * Builds the ordered list of page numbers and ellipsis markers for a pagination control.
40
+ *
41
+ * Args:
42
+ * pageCount: Total number of pages (must be >= 0).
43
+ * currentPage: Active page index (1-based).
44
+ * siblingCount: How many page buttons to show on each side of the current page.
45
+ * boundaryCount: How many pages to pin at the start and end of the range.
46
+ *
47
+ * Returns:
48
+ * A list of items suitable for rendering, e.g. [1, ellipsis, 4,5,6, ellipsis, 20].
49
+ */
50
+ declare function buildPaginationItems({ pageCount, currentPage, siblingCount, boundaryCount, }: BuildPaginationItemsParams): PaginationPageItem$1[];
51
+ declare function clampPage(page: number, pageCount: number): number;
52
+
53
+ type PaginationAppearance = NonNullable<VariantProps<typeof buttonVariants>["appearance"]>;
54
+ type PaginationSize = NonNullable<VariantProps<typeof buttonVariants>["size"]>;
55
+ type PaginationPageItem = PaginationPageItem$1;
56
+ type UsePaginationParams = {
57
+ pageCount: number;
58
+ page?: number;
59
+ defaultPage?: number;
60
+ siblingCount?: number;
61
+ boundaryCount?: number;
62
+ onPageChange?: (page: number) => void;
63
+ };
64
+ type UsePaginationResult = {
65
+ /** 1-based active page, clamped to `[1, pageCount]`. */
66
+ currentPage: number;
67
+ pageCount: number;
68
+ items: PaginationPageItem[];
69
+ setPage: (page: number) => void;
70
+ goPrev: () => void;
71
+ goNext: () => void;
72
+ canGoPrev: boolean;
73
+ canGoNext: boolean;
74
+ };
75
+ type PaginationProps = Omit<ComponentPropsWithoutRef<"nav">, "onChange"> & VariantProps<typeof buttonVariants> & {
76
+ pageCount: number;
77
+ page?: number;
78
+ defaultPage?: number;
79
+ onPageChange?: (page: number) => void;
80
+ /**
81
+ * Number of page buttons to show on each side of the current page (the “middle” window).
82
+ * @defaultValue 1
83
+ */
84
+ siblingCount?: number;
85
+ /**
86
+ * Number of pages to keep visible at the start and end of the range.
87
+ * @defaultValue 1
88
+ */
89
+ boundaryCount?: number;
90
+ showPrevNext?: boolean;
91
+ prevLabel?: string;
92
+ nextLabel?: string;
93
+ ellipsisLabel?: string;
94
+ /**
95
+ * When set, page controls render as anchors suitable for URL-based pagination.
96
+ */
97
+ getPageHref?: (page: number) => string | undefined;
98
+ };
99
+
100
+ declare function usePagination({ pageCount, page, defaultPage, siblingCount, boundaryCount, onPageChange, }: UsePaginationParams): UsePaginationResult;
101
+
102
+ /**
103
+ * Layout and chrome for the page list cluster. Appearance and size keys align with
104
+ * `components/ui/buttons/variants.ts` for consistent design-system tokens.
105
+ */
106
+ declare const paginationListVariants: (props?: ({
107
+ appearance?: "default" | "outline" | "link" | "ghost" | "sky" | "rose" | "purple" | "pink" | "orange" | "yellow" | "teal" | "indigo" | "emerald" | "gradient-blue" | "gradient-green" | "gradient-red" | "gradient-yellow" | "gradient-purple" | "gradient-teal" | "gradient-indigo" | "gradient-pink" | "gradient-orange" | "gray" | "violet" | "secondary" | "destructive" | "glass" | "amber" | null | undefined;
108
+ size?: "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | "icon" | null | undefined;
109
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
110
+ declare const paginationEllipsisVariants: (props?: ({
111
+ size?: "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "10xl" | "icon" | null | undefined;
112
+ } & class_variance_authority_types.ClassProp) | undefined) => string;
113
+
114
+ export { Pagination, type PaginationAppearance, type PaginationPageItem, type PaginationProps, type PaginationSize, type UsePaginationParams, type UsePaginationResult, buildPaginationItems, clampPage, paginationEllipsisVariants, paginationListVariants, usePagination };