@cystackapp/ui 1.4.1 → 2.0.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 (201) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +77 -47
  3. package/dist/assets/background-pattern-grid.svg.js +7 -0
  4. package/dist/assets/empty-cloud.svg.js +5 -0
  5. package/dist/components/accordion/Accordion.d.ts +20 -0
  6. package/dist/components/accordion/Accordion.js +36 -0
  7. package/dist/components/accordion/AccordionTestStory.d.ts +3 -0
  8. package/dist/components/alert/Alert.d.ts +15 -0
  9. package/dist/components/alert/Alert.js +54 -0
  10. package/dist/components/avatar/Avatar.d.ts +13 -0
  11. package/dist/components/avatar/Avatar.js +64 -0
  12. package/dist/components/background-pattern/BackgroundPatternGrid.d.ts +1 -0
  13. package/dist/components/background-pattern/BackgroundPatternGrid.js +6 -0
  14. package/dist/components/badge/Badge.d.ts +1 -1
  15. package/dist/components/badge/Badge.js +3 -3
  16. package/dist/components/badge/BadgeTestStory.d.ts +1 -1
  17. package/dist/components/badge/variants/BadgeMore.d.ts +1 -1
  18. package/dist/components/badge/variants/BadgeMoreTestStory.d.ts +1 -1
  19. package/dist/components/badge/variants/BadgeTag.d.ts +1 -1
  20. package/dist/components/badge/variants/BadgeTag.js +1 -1
  21. package/dist/components/banner/Banner.d.ts +9 -0
  22. package/dist/components/banner/Banner.js +21 -0
  23. package/dist/components/breadcrumb/Breadcrumb.d.ts +13 -0
  24. package/dist/components/breadcrumb/Breadcrumb.js +36 -0
  25. package/dist/components/button/Button.d.ts +21 -0
  26. package/dist/components/button/Button.js +49 -0
  27. package/dist/components/button/ButtonLoader.d.ts +7 -0
  28. package/dist/components/button/ButtonLoader.js +44 -0
  29. package/dist/components/button/ButtonTestStory.d.ts +5 -0
  30. package/dist/components/button/button-variants.d.ts +13 -0
  31. package/dist/components/button/button-variants.js +58 -0
  32. package/dist/components/card/Card.d.ts +91 -0
  33. package/dist/components/card/Card.js +56 -0
  34. package/dist/components/card/Card.stories-ct.d.ts +1 -0
  35. package/dist/components/card/CardBody.d.ts +9 -0
  36. package/dist/components/card/CardBody.js +16 -0
  37. package/dist/components/card/CardHeader.d.ts +15 -0
  38. package/dist/components/card/CardHeader.js +79 -0
  39. package/dist/components/card/types.d.ts +1 -0
  40. package/dist/components/chart/chart-legend/ChartLegend.d.ts +38 -0
  41. package/dist/components/chart/chart-legend/ChartLegend.js +57 -0
  42. package/dist/components/chart/chart-legend/ChartLegendItem.d.ts +19 -0
  43. package/dist/components/chart/chart-legend/ChartLegendItem.js +30 -0
  44. package/dist/components/chart/chart-legend/types.d.ts +49 -0
  45. package/dist/components/chart/donut-chart/DonutChart.d.ts +55 -0
  46. package/dist/components/chart/donut-chart/DonutChart.js +110 -0
  47. package/dist/components/chart/donut-chart/DonutSegments.d.ts +25 -0
  48. package/dist/components/chart/donut-chart/DonutSegments.js +51 -0
  49. package/dist/components/chart/donut-chart/donut-tooltip.d.ts +20 -0
  50. package/dist/components/chart/donut-chart/donut-tooltip.js +37 -0
  51. package/dist/components/chart/types.d.ts +8 -0
  52. package/dist/components/checkbox/Checkbox.d.ts +6 -0
  53. package/dist/components/checkbox/Checkbox.js +72 -0
  54. package/dist/components/checkbox/CheckboxTestStory.d.ts +7 -0
  55. package/dist/components/collapsible/Collapsible.d.ts +21 -0
  56. package/dist/components/collapsible/Collapsible.js +50 -0
  57. package/dist/components/combobox/Combobox.d.ts +1 -1
  58. package/dist/components/divider/Divider.d.ts +9 -0
  59. package/dist/components/divider/Divider.js +28 -0
  60. package/dist/components/drawer/Drawer.d.ts +8 -0
  61. package/dist/components/drawer/Drawer.js +68 -0
  62. package/dist/components/dropdown/Dropdown.d.ts +45 -0
  63. package/dist/components/dropdown/Dropdown.js +133 -0
  64. package/dist/components/dropdown/DropdownMenu.d.ts +20 -0
  65. package/dist/components/dropdown/DropdownMenu.js +78 -0
  66. package/dist/components/dropdown/DropdownMenuItem.d.ts +13 -0
  67. package/dist/components/dropdown/DropdownMenuItem.js +49 -0
  68. package/dist/components/dropdown/DropdownTestStory.d.ts +5 -0
  69. package/dist/components/dropdown/dropdown-utils.d.ts +4 -0
  70. package/dist/components/dropdown/dropdown-utils.js +14 -0
  71. package/dist/components/dropdown/types.d.ts +48 -0
  72. package/dist/components/dropdown/use-dropdown-keyboard.d.ts +12 -0
  73. package/dist/components/dropdown/use-dropdown-keyboard.js +49 -0
  74. package/dist/components/empty-state/EmptyState.d.ts +26 -0
  75. package/dist/components/empty-state/EmptyState.js +36 -0
  76. package/dist/components/error-state/ErrorState.d.ts +1 -1
  77. package/dist/components/featured-icon/FeaturedIcon.d.ts +12 -0
  78. package/dist/components/featured-icon/FeaturedIcon.js +44 -0
  79. package/dist/components/form-field/FormField.d.ts +13 -0
  80. package/dist/components/form-field/FormField.js +21 -0
  81. package/dist/components/input/Input.d.ts +11 -0
  82. package/dist/components/input/Input.js +39 -0
  83. package/dist/components/keyboard-shortcut-label/KeyboardShortcutLabel.d.ts +8 -0
  84. package/dist/components/keyboard-shortcut-label/KeyboardShortcutLabel.js +18 -0
  85. package/dist/components/loading-state/Loader.d.ts +20 -0
  86. package/dist/components/loading-state/Loader.js +38 -0
  87. package/dist/components/loading-state/LoadingState.d.ts +15 -0
  88. package/dist/components/loading-state/LoadingState.js +47 -0
  89. package/dist/components/loading-state/locale/en.json.d.ts +6 -0
  90. package/dist/components/loading-state/locale/en.json.js +7 -0
  91. package/dist/components/loading-state/locale/vi.json.d.ts +6 -0
  92. package/dist/components/loading-state/locale/vi.json.js +7 -0
  93. package/dist/components/media/Media.d.ts +7 -0
  94. package/dist/components/media/Media.js +25 -0
  95. package/dist/components/modal/Modal.d.ts +9 -0
  96. package/dist/components/modal/Modal.js +68 -0
  97. package/dist/components/modal/helpers/HeaderIcon.d.ts +8 -0
  98. package/dist/components/modal/helpers/HeaderIcon.js +32 -0
  99. package/dist/components/modal/helpers/Title.d.ts +6 -0
  100. package/dist/components/modal/helpers/Title.js +9 -0
  101. package/dist/components/modal/helpers/circles-sm.svg.js +5 -0
  102. package/dist/components/modal/modal-context.d.ts +2 -0
  103. package/dist/components/modal/modal-context.js +9 -0
  104. package/dist/components/modal/use-click-outside-modal.d.ts +2 -0
  105. package/dist/components/modal/use-click-outside-modal.js +15 -0
  106. package/dist/components/notification/NotificationBanner.d.ts +9 -0
  107. package/dist/components/notification/NotificationBanner.js +97 -0
  108. package/dist/components/notification/icons.d.ts +5 -0
  109. package/dist/components/notification/icons.js +29 -0
  110. package/dist/components/notification/index.d.ts +4 -0
  111. package/dist/components/notification/index.js +26 -0
  112. package/dist/components/notification/locale/en.json.d.ts +8 -0
  113. package/dist/components/notification/locale/en.json.js +7 -0
  114. package/dist/components/notification/locale/vi.json.d.ts +8 -0
  115. package/dist/components/notification/locale/vi.json.js +7 -0
  116. package/dist/components/operating-system-icon/OperatingSystemIcon.d.ts +6 -0
  117. package/dist/components/operating-system-icon/OperatingSystemIcon.js +19 -0
  118. package/dist/components/operating-system-icon/assets/logo-android.svg.js +5 -0
  119. package/dist/components/operating-system-icon/assets/logo-apple.svg.js +5 -0
  120. package/dist/components/operating-system-icon/assets/logo-ubuntu.svg.js +5 -0
  121. package/dist/components/operating-system-icon/assets/logo-windows-10.svg.js +5 -0
  122. package/dist/components/page-title/PageTitle.d.ts +1 -1
  123. package/dist/components/popover/Popover.d.ts +1 -1
  124. package/dist/components/progress-bar/ProgressBar.d.ts +9 -0
  125. package/dist/components/progress-bar/ProgressBar.js +31 -0
  126. package/dist/components/radio/Radio.d.ts +4 -0
  127. package/dist/components/radio/Radio.js +55 -0
  128. package/dist/components/searchbox/Searchbox.d.ts +7 -0
  129. package/dist/components/searchbox/Searchbox.js +15 -0
  130. package/dist/components/select/Select.d.ts +11 -0
  131. package/dist/components/select/Select.js +44 -0
  132. package/dist/components/skeleton/Skeleton.d.ts +14 -0
  133. package/dist/components/skeleton/Skeleton.js +12 -0
  134. package/dist/components/switch/Switch.d.ts +1 -1
  135. package/dist/components/table/Table.d.ts +32 -0
  136. package/dist/components/table/Table.js +128 -0
  137. package/dist/components/table/TableActionButton.d.ts +15 -0
  138. package/dist/components/table/TableActionButton.js +50 -0
  139. package/dist/components/table/TableCell.d.ts +8 -0
  140. package/dist/components/table/TableCell.js +26 -0
  141. package/dist/components/table/TableHeader.d.ts +15 -0
  142. package/dist/components/table/TableHeader.js +36 -0
  143. package/dist/components/table/TableHeaderCell.d.ts +10 -0
  144. package/dist/components/table/TableHeaderCell.js +35 -0
  145. package/dist/components/table/TablePagination.d.ts +6 -0
  146. package/dist/components/table/TablePagination.js +69 -0
  147. package/dist/components/table/TableRow.d.ts +12 -0
  148. package/dist/components/table/TableRow.js +9 -0
  149. package/dist/components/table/expandable/ExpandableTable.d.ts +30 -0
  150. package/dist/components/table/expandable/ExpandableTable.js +156 -0
  151. package/dist/components/table/hooks/use-fit-page-height.d.ts +14 -0
  152. package/dist/components/table/hooks/use-fit-page-height.js +21 -0
  153. package/dist/components/table/hooks/use-row-selection.d.ts +27 -0
  154. package/dist/components/table/hooks/use-row-selection.js +35 -0
  155. package/dist/components/table/locale/en.json.d.ts +13 -0
  156. package/dist/components/table/locale/en.json.js +21 -0
  157. package/dist/components/table/locale/vi.json.d.ts +13 -0
  158. package/dist/components/table/locale/vi.json.js +21 -0
  159. package/dist/components/table/table-utils.d.ts +10 -0
  160. package/dist/components/table/table-utils.js +10 -0
  161. package/dist/components/table/types.d.ts +84 -0
  162. package/dist/components/tabs/Tabs.d.ts +27 -0
  163. package/dist/components/tabs/Tabs.js +75 -0
  164. package/dist/components/tabs/TabsTestStory.d.ts +4 -0
  165. package/dist/components/tags-input/TagsInput.d.ts +18 -0
  166. package/dist/components/tags-input/TagsInput.js +78 -0
  167. package/dist/components/tags-input/TagsInputTestStory.d.ts +3 -0
  168. package/dist/components/textarea/Textarea.d.ts +7 -0
  169. package/dist/components/textarea/Textarea.js +36 -0
  170. package/dist/components/toast/ToastSlice.d.ts +11 -0
  171. package/dist/components/toast/ToastSlice.js +103 -0
  172. package/dist/components/toast/icons.d.ts +8 -0
  173. package/dist/components/toast/icons.js +19 -0
  174. package/dist/components/toast/index.d.ts +4 -0
  175. package/dist/components/toast/index.js +35 -0
  176. package/dist/components/toast/types.d.ts +14 -0
  177. package/dist/components/toast/use-toast-list.d.ts +4 -0
  178. package/dist/components/toast/use-toast-list.js +27 -0
  179. package/dist/components/tooltip/Tooltip.d.ts +1 -1
  180. package/dist/filters/FilterDropdown.d.ts +9 -0
  181. package/dist/filters/FilterDropdown.js +57 -0
  182. package/dist/filters/types.d.ts +11 -0
  183. package/dist/filters/url-params.d.ts +5 -0
  184. package/dist/filters/url-params.js +20 -0
  185. package/dist/filters/use-filters.d.ts +13 -0
  186. package/dist/filters/use-filters.js +63 -0
  187. package/dist/hooks/use-countdown.d.ts +4 -0
  188. package/dist/hooks/use-countdown.js +18 -0
  189. package/dist/i18n/resources.js +23 -0
  190. package/dist/index.d.ts +66 -0
  191. package/dist/index.js +141 -38
  192. package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js +421 -350
  193. package/dist/test-utils/expect-visibility.d.ts +45 -0
  194. package/dist/utils/key-typeguard.d.ts +5 -0
  195. package/dist/utils/key-typeguard.js +6 -0
  196. package/dist/utils/observable.d.ts +7 -0
  197. package/dist/utils/observable.js +22 -0
  198. package/dist/utils/use-debounce.d.ts +1 -0
  199. package/dist/utils/use-debounce.js +11 -0
  200. package/package.json +30 -7
  201. package/theme.css +7 -1
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2022 VanHo
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,14 +1,14 @@
1
1
  # @cystackapp/ui
2
2
 
3
- Reusable React UI components used across CyStack's platform dashboards. Built
4
- with React 18, TypeScript and Tailwind CSS v4.
3
+ CyStack design system — reusable React UI components used across CyStack's
4
+ platform dashboards. Built with React 18, TypeScript and Tailwind CSS v4.
5
5
 
6
6
  ## Installation
7
7
 
8
8
  ```bash
9
- yarn add @cystackapp/ui
10
- # or
11
9
  npm install @cystackapp/ui
10
+ # or
11
+ yarn add @cystackapp/ui
12
12
  ```
13
13
 
14
14
  ### Peer dependencies
@@ -16,17 +16,17 @@ npm install @cystackapp/ui
16
16
  Install these in the host app if not already present:
17
17
 
18
18
  ```bash
19
- yarn add react react-dom react-router-dom react-i18next i18next @untitled-ui/icons-react
19
+ npm install react react-dom react-router-dom react-i18next i18next @untitled-ui/icons-react
20
20
  ```
21
21
 
22
- | Package | Version |
23
- | -------------------------- | ------------ |
24
- | `react` | `^18.0.0` |
25
- | `react-dom` | `^18.0.0` |
26
- | `react-router-dom` | `^6.0.0` |
27
- | `react-i18next` | `^15.0.0` |
28
- | `i18next` | `23.7.7` |
29
- | `@untitled-ui/icons-react` | `^0.1.4` |
22
+ | Package | Version |
23
+ | -------------------------- | --------- |
24
+ | `react` | `^18.0.0` |
25
+ | `react-dom` | `^18.0.0` |
26
+ | `react-router-dom` | `^6.0.0` |
27
+ | `react-i18next` | `^15.0.0` |
28
+ | `i18next` | `>=23` |
29
+ | `@untitled-ui/icons-react` | `^0.1.4` |
30
30
 
31
31
  ## Setup
32
32
 
@@ -39,13 +39,22 @@ use **Tailwind CSS v4** and import the theme once in its root stylesheet:
39
39
  @import "@cystackapp/ui/theme.css";
40
40
  ```
41
41
 
42
- `theme.css` registers CSS variables (color tokens, spacing, etc.) and a `@source`
43
- directive so Tailwind can scan the package's classes.
42
+ `theme.css` registers CSS variables (color tokens, spacing, etc.) and a
43
+ `@source` directive so Tailwind can scan the package's classes.
44
+
45
+ Some components (`Table`, `LoadingState`, `Notification`, …) render translated
46
+ text via `react-i18next`. Merge the package's resources into the host app's
47
+ i18next instance:
48
+
49
+ ```ts
50
+ import { resources as uiResources } from "@cystackapp/ui";
51
+ // merge uiResources into your i18next init
52
+ ```
44
53
 
45
54
  ## Usage
46
55
 
47
56
  ```tsx
48
- import { Badge, Tooltip, Popover, cn } from "@cystackapp/ui";
57
+ import { Badge, Button, Tooltip, cn } from "@cystackapp/ui";
49
58
 
50
59
  export const Example = () => (
51
60
  <Tooltip content="Hello">
@@ -58,47 +67,68 @@ export const Example = () => (
58
67
 
59
68
  ### Available exports
60
69
 
61
- **Components**
70
+ **Form controls** — `Button`, `Input`, `Textarea`, `Checkbox`, `Radio`,
71
+ `Switch`, `Select`, `Combobox`, `Searchbox`, `TagsInput`, `FormField`
72
+
73
+ **Display** — `Badge`, `BadgeTag`, `BadgeMore`, `Avatar`, `Card`, `Divider`,
74
+ `Skeleton`, `ProgressBar`, `Media`, `OperatingSystemIcon`, `FeaturedIcon`,
75
+ `KeyboardShortcutLabel`, `BackgroundPatternGrid`
76
+
77
+ **Feedback** — `Alert`, `Banner`, `Toaster`/`createToast`,
78
+ `NotificationBox`/`createNotification`, `EmptyState`, `ErrorState`,
79
+ `LoadingState`, `Loader`
62
80
 
63
- - `Badge`, `BadgeTag`, `BadgeMore`
64
- - `Combobox`
65
- - `ErrorState`
66
- - `PageTitle`
67
- - `Popover`
68
- - `Switch`
69
- - `Tooltip`
81
+ **Overlays** `Modal`, `Drawer`, `Popover`, `Tooltip`, `Dropdown`
70
82
 
71
- **Hooks**
83
+ **Navigation** — `Tabs`, `Breadcrumb`, `PageTitle`
72
84
 
73
- - `useResizeObserver`
74
- - `useScrollListener`
75
- - `useWindowResizeListener`
76
- - `useMutationObserver`
77
- - `useTransitionEndListener`
78
- - `useAnimationFrame`
79
- - `useElementShift`
80
- - `usePopoverCoord`
81
- - `useValidatedCombobox`
85
+ **Data** `Table`, `ExpandableTable`, `TableActionButton`, `FilterDropdown`,
86
+ `useFilters`, `DonutChart`, `ChartLegend`
82
87
 
83
- **Utilities**
88
+ **Disclosure** — `Accordion`, `Collapsible`
84
89
 
85
- - `cn` — `clsx` + `tailwind-merge` wrapper for conditional class names
86
- - `getBadgeAutoColor`, `TAG_ICON_COLOR_CLASSES`
90
+ **Hooks** — `useResizeObserver`, `useScrollListener`,
91
+ `useWindowResizeListener`, `useMutationObserver`, `useTransitionEndListener`,
92
+ `useAnimationFrame`, `useElementShift`, `usePopoverCoord`,
93
+ `useValidatedCombobox`, `useClickOutsideModal`, `useCountdown`, `useDebounce`,
94
+ `useToastList`
87
95
 
88
- **Types**
96
+ **Utilities** — `cn` (clsx + tailwind-merge), `Observable`,
97
+ `getBadgeAutoColor`, URL param codecs (`stringCodec`, `searchCodec`,
98
+ `numberCodec`, `csvCodec`)
89
99
 
90
- - `BadgeProps`, `BadgeColor`, `BadgeSize`, `BadgeType`
91
- - `ComboboxSuggestionItem`
92
- - `PopoverPosition`
100
+ The authoritative list lives in [`src/index.ts`](./src/index.ts) — anything not
101
+ exported there is internal and may change without notice.
102
+
103
+ ## Development
104
+
105
+ ```bash
106
+ npm install # install dependencies
107
+ npm run storybook # component playground at :6007
108
+ npm run build # build dist/ (vite + dts)
109
+ npm run typecheck # tsc --noEmit
110
+ npm run lint # eslint
111
+ npm run test # vitest + playwright component tests
112
+ npm run i18n # regenerate src/i18n/resources.ts from locale/ folders
113
+ ```
114
+
115
+ Component tests need Playwright browsers on first run:
116
+
117
+ ```bash
118
+ npx playwright install chromium
119
+ ```
93
120
 
94
- The authoritative list lives in
95
- [`src/index.ts`](./src/index.ts) — anything not exported there is internal and
96
- may change without notice.
121
+ ## Publishing
97
122
 
98
- ## Versioning
123
+ CI publishes to npm automatically. On pushes to `main` (or tags), the `build`
124
+ job runs `cystack-deployer`, which builds the [`Dockerfile`](./Dockerfile):
125
+ install → typecheck + lint → build → [`scripts/publish.sh`](./scripts/publish.sh).
126
+ The publish step skips when the version in `package.json` already exists on
127
+ the registry, so re-runs are safe.
99
128
 
100
- Semver via [Changesets](https://github.com/changesets/changesets). Release notes
101
- in [`CHANGELOG.md`](./CHANGELOG.md).
129
+ To release: bump `version` in `package.json`, update `CHANGELOG.md`, and merge
130
+ to `main`. The `NPM_TOKEN` build arg / CI variable must hold an npm automation
131
+ token with publish access to the `@cystackapp` scope.
102
132
 
103
133
  ## License
104
134
 
@@ -0,0 +1,7 @@
1
+ import * as e from "react";
2
+ const E = (t) => /* @__PURE__ */ e.createElement("svg", { width: 480, height: 480, viewBox: "0 0 480 480", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ e.createElement("mask", { id: "mask0_4933_393121", style: {
3
+ maskType: "alpha"
4
+ }, maskUnits: "userSpaceOnUse", x: 0, y: 0, width: 480, height: 480 }, /* @__PURE__ */ e.createElement("rect", { width: 480, height: 480, fill: "url(#paint0_radial_4933_393121)" })), /* @__PURE__ */ e.createElement("g", { mask: "url(#mask0_4933_393121)" }, /* @__PURE__ */ e.createElement("g", { clipPath: "url(#clip0_4933_393121)" }, /* @__PURE__ */ e.createElement("g", { clipPath: "url(#clip1_4933_393121)" }, /* @__PURE__ */ e.createElement("line", { x1: 0.5, x2: 0.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 32.5, x2: 32.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 64.5, x2: 64.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 96.5, x2: 96.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 128.5, x2: 128.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 160.5, x2: 160.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 192.5, x2: 192.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 224.5, x2: 224.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 256.5, x2: 256.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 288.5, x2: 288.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 320.5, x2: 320.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 352.5, x2: 352.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 384.5, x2: 384.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 416.5, x2: 416.5, y2: 480, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { x1: 448.5, x2: 448.5, y2: 480, stroke: "#E9EAEB" })), /* @__PURE__ */ e.createElement("rect", { x: 0.5, y: 0.5, width: 479, height: 479, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("g", { clipPath: "url(#clip2_4933_393121)" }, /* @__PURE__ */ e.createElement("line", { y1: 31.5, x2: 480, y2: 31.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 63.5, x2: 480, y2: 63.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 95.5, x2: 480, y2: 95.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 127.5, x2: 480, y2: 127.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 159.5, x2: 480, y2: 159.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 191.5, x2: 480, y2: 191.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 223.5, x2: 480, y2: 223.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 255.5, x2: 480, y2: 255.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 287.5, x2: 480, y2: 287.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 319.5, x2: 480, y2: 319.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 351.5, x2: 480, y2: 351.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 383.5, x2: 480, y2: 383.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 415.5, x2: 480, y2: 415.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 447.5, x2: 480, y2: 447.5, stroke: "#E9EAEB" }), /* @__PURE__ */ e.createElement("line", { y1: 479.5, x2: 480, y2: 479.5, stroke: "#E9EAEB" })), /* @__PURE__ */ e.createElement("rect", { x: 0.5, y: 0.5, width: 479, height: 479, stroke: "#E9EAEB" }))), /* @__PURE__ */ e.createElement("defs", null, /* @__PURE__ */ e.createElement("radialGradient", { id: "paint0_radial_4933_393121", cx: 0, cy: 0, r: 1, gradientUnits: "userSpaceOnUse", gradientTransform: "translate(240 240) rotate(90) scale(240 240)" }, /* @__PURE__ */ e.createElement("stop", null), /* @__PURE__ */ e.createElement("stop", { offset: 1, stopOpacity: 0 })), /* @__PURE__ */ e.createElement("clipPath", { id: "clip0_4933_393121" }, /* @__PURE__ */ e.createElement("rect", { width: 480, height: 480, fill: "white" })), /* @__PURE__ */ e.createElement("clipPath", { id: "clip1_4933_393121" }, /* @__PURE__ */ e.createElement("rect", { width: 480, height: 480, fill: "white" })), /* @__PURE__ */ e.createElement("clipPath", { id: "clip2_4933_393121" }, /* @__PURE__ */ e.createElement("rect", { width: 480, height: 480, fill: "white" }))));
5
+ export {
6
+ E as default
7
+ };
@@ -0,0 +1,5 @@
1
+ import * as e from "react";
2
+ const r = (t) => /* @__PURE__ */ e.createElement("svg", { width: 180, height: 136, viewBox: "0 0 180 136", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ e.createElement("circle", { cx: 90, cy: 64, r: 64, fill: "#E9EAEB" }), /* @__PURE__ */ e.createElement("circle", { cx: 24, cy: 20, r: 6, fill: "#F5F5F5" }), /* @__PURE__ */ e.createElement("circle", { cx: 21, cy: 112, r: 8, fill: "#F5F5F5" }), /* @__PURE__ */ e.createElement("circle", { cx: 164, cy: 36, r: 8, fill: "#F5F5F5" }), /* @__PURE__ */ e.createElement("circle", { cx: 153, cy: 9, r: 5, fill: "#F5F5F5" }), /* @__PURE__ */ e.createElement("g", { filter: "url(#filter0_ddd_1182_2026)" }, /* @__PURE__ */ e.createElement("path", { d: "M92 16C78.534 16 66.6222 22.6541 59.3733 32.8536C57.0062 32.2954 54.5376 32 52 32C34.3269 32 20 46.3269 20 64C20 81.6731 34.3269 96 52 96H132C147.464 96 160 83.464 160 68C160 52.536 147.464 40 132 40C130.902 40 129.818 40.0633 128.752 40.1863C122.623 25.9596 108.475 16 92 16Z", fill: "#FAFAFA" }), /* @__PURE__ */ e.createElement("circle", { cx: 52, cy: 64, r: 32, fill: "url(#paint0_linear_1182_2026)" }), /* @__PURE__ */ e.createElement("circle", { cx: 92, cy: 56, r: 40, fill: "url(#paint1_linear_1182_2026)" }), /* @__PURE__ */ e.createElement("circle", { cx: 132, cy: 68, r: 28, fill: "url(#paint2_linear_1182_2026)" })), /* @__PURE__ */ e.createElement("path", { d: "M62 88C62 72.536 74.536 60 90 60C105.464 60 118 72.536 118 88C118 103.464 105.464 116 90 116C74.536 116 62 103.464 62 88Z", fill: "#344054", fillOpacity: 0.4 }), /* @__PURE__ */ e.createElement("path", { d: "M100.5 98.5L96.4168 94.4167M99.3333 87.4167C99.3333 92.8935 94.8935 97.3333 89.4167 97.3333C83.9398 97.3333 79.5 92.8935 79.5 87.4167C79.5 81.9398 83.9398 77.5 89.4167 77.5C94.8935 77.5 99.3333 81.9398 99.3333 87.4167Z", stroke: "white", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ e.createElement("defs", null, /* @__PURE__ */ e.createElement("filter", { id: "filter0_ddd_1182_2026", x: 0, y: 16, width: 180, height: 120, filterUnits: "userSpaceOnUse", colorInterpolationFilters: "sRGB" }, /* @__PURE__ */ e.createElement("feFlood", { floodOpacity: 0, result: "BackgroundImageFix" }), /* @__PURE__ */ e.createElement("feColorMatrix", { in: "SourceAlpha", type: "matrix", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0", result: "hardAlpha" }), /* @__PURE__ */ e.createElement("feMorphology", { radius: 1.5, operator: "erode", in: "SourceAlpha", result: "effect1_dropShadow_1182_2026" }), /* @__PURE__ */ e.createElement("feOffset", { dy: 3 }), /* @__PURE__ */ e.createElement("feGaussianBlur", { stdDeviation: 1.5 }), /* @__PURE__ */ e.createElement("feComposite", { in2: "hardAlpha", operator: "out" }), /* @__PURE__ */ e.createElement("feColorMatrix", { type: "matrix", values: "0 0 0 0 0.0392157 0 0 0 0 0.0496732 0 0 0 0 0.0705882 0 0 0 0.04 0" }), /* @__PURE__ */ e.createElement("feBlend", { mode: "normal", in2: "BackgroundImageFix", result: "effect1_dropShadow_1182_2026" }), /* @__PURE__ */ e.createElement("feColorMatrix", { in: "SourceAlpha", type: "matrix", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0", result: "hardAlpha" }), /* @__PURE__ */ e.createElement("feMorphology", { radius: 4, operator: "erode", in: "SourceAlpha", result: "effect2_dropShadow_1182_2026" }), /* @__PURE__ */ e.createElement("feOffset", { dy: 8 }), /* @__PURE__ */ e.createElement("feGaussianBlur", { stdDeviation: 4 }), /* @__PURE__ */ e.createElement("feComposite", { in2: "hardAlpha", operator: "out" }), /* @__PURE__ */ e.createElement("feColorMatrix", { type: "matrix", values: "0 0 0 0 0.0392157 0 0 0 0 0.0496732 0 0 0 0 0.0705882 0 0 0 0.03 0" }), /* @__PURE__ */ e.createElement("feBlend", { mode: "normal", in2: "effect1_dropShadow_1182_2026", result: "effect2_dropShadow_1182_2026" }), /* @__PURE__ */ e.createElement("feColorMatrix", { in: "SourceAlpha", type: "matrix", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0", result: "hardAlpha" }), /* @__PURE__ */ e.createElement("feMorphology", { radius: 4, operator: "erode", in: "SourceAlpha", result: "effect3_dropShadow_1182_2026" }), /* @__PURE__ */ e.createElement("feOffset", { dy: 20 }), /* @__PURE__ */ e.createElement("feGaussianBlur", { stdDeviation: 12 }), /* @__PURE__ */ e.createElement("feComposite", { in2: "hardAlpha", operator: "out" }), /* @__PURE__ */ e.createElement("feColorMatrix", { type: "matrix", values: "0 0 0 0 0.0392157 0 0 0 0 0.0496732 0 0 0 0 0.0705882 0 0 0 0.08 0" }), /* @__PURE__ */ e.createElement("feBlend", { mode: "normal", in2: "effect2_dropShadow_1182_2026", result: "effect3_dropShadow_1182_2026" }), /* @__PURE__ */ e.createElement("feBlend", { mode: "normal", in: "SourceGraphic", in2: "effect3_dropShadow_1182_2026", result: "shape" })), /* @__PURE__ */ e.createElement("linearGradient", { id: "paint0_linear_1182_2026", x1: 27.4286, y1: 42.8571, x2: 84, y2: 96, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ e.createElement("stop", { stopColor: "#D0D5DD" }), /* @__PURE__ */ e.createElement("stop", { offset: 0.350715, stopColor: "white", stopOpacity: 0 })), /* @__PURE__ */ e.createElement("linearGradient", { id: "paint1_linear_1182_2026", x1: 61.2857, y1: 29.5714, x2: 132, y2: 95.9999, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ e.createElement("stop", { stopColor: "#D0D5DD" }), /* @__PURE__ */ e.createElement("stop", { offset: 0.350715, stopColor: "white", stopOpacity: 0 })), /* @__PURE__ */ e.createElement("linearGradient", { id: "paint2_linear_1182_2026", x1: 110.5, y1: 49.5, x2: 160, y2: 96, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ e.createElement("stop", { stopColor: "#D0D5DD" }), /* @__PURE__ */ e.createElement("stop", { offset: 0.350715, stopColor: "white", stopOpacity: 0 }))));
3
+ export {
4
+ r as default
5
+ };
@@ -0,0 +1,20 @@
1
+ import { ReactNode } from 'react';
2
+ interface Props {
3
+ label?: ReactNode;
4
+ children?: ReactNode;
5
+ expanded?: boolean;
6
+ defaultExpanded?: boolean;
7
+ onToggle?: (expanded: boolean) => void;
8
+ className?: string;
9
+ duration?: number;
10
+ }
11
+ /** Accordion item, aka. smooth collapsible container.
12
+ * @param expanded - Controlled state for expansion. When provided, internal state is ignored.
13
+ * @param defaultExpanded - Initial expanded state for uncontrolled mode (default: true).
14
+ * @param onToggle - Called with the next expanded state when the label is clicked.
15
+ * @param label - The trigger element that toggles expansion.
16
+ * @param children - Content hidden when collapsed.
17
+ * @param duration - Transition duration in milliseconds (default: 150).
18
+ */
19
+ export declare const Accordion: ({ label, children, expanded, defaultExpanded, onToggle, className, duration, }: Props) => import("react").JSX.Element;
20
+ export {};
@@ -0,0 +1,36 @@
1
+ import { jsxs as m, jsx as o } from "react/jsx-runtime";
2
+ import { useState as u } from "react";
3
+ import { Collapsible as v } from "../collapsible/Collapsible.js";
4
+ const k = ({
5
+ label: s,
6
+ children: a,
7
+ expanded: r,
8
+ defaultExpanded: c = !0,
9
+ onToggle: n,
10
+ className: l,
11
+ duration: p = 150
12
+ }) => {
13
+ const [x, f] = u(c), d = r !== void 0, e = d ? r : x, i = () => {
14
+ const t = !e;
15
+ d || f(t), n == null || n(t);
16
+ };
17
+ return /* @__PURE__ */ m("div", { className: l, children: [
18
+ /* @__PURE__ */ o(
19
+ "div",
20
+ {
21
+ role: "button",
22
+ tabIndex: 0,
23
+ "aria-expanded": e,
24
+ onClick: i,
25
+ onKeyDown: (t) => {
26
+ (t.key === "Enter" || t.key === " ") && (t.preventDefault(), i());
27
+ },
28
+ children: s
29
+ }
30
+ ),
31
+ /* @__PURE__ */ o(v, { expanded: e, duration: p, children: a })
32
+ ] });
33
+ };
34
+ export {
35
+ k as Accordion
36
+ };
@@ -0,0 +1,3 @@
1
+ export declare const AccordionWithCallbackDisplay: (props: {
2
+ defaultExpanded?: boolean;
3
+ }) => import("react").JSX.Element;
@@ -0,0 +1,15 @@
1
+ import { ReactNode } from 'react';
2
+ export type AlertType = "brand" | "gray" | "success" | "warning" | "error";
3
+ interface Props {
4
+ type?: AlertType;
5
+ title: ReactNode;
6
+ /** Supporting text rendered under the title. */
7
+ detail?: ReactNode;
8
+ /** Optional action row (e.g. buttons/links) rendered under the content. */
9
+ actions?: ReactNode;
10
+ /** When provided, renders a close/dismiss button. */
11
+ onClose?: () => void;
12
+ className?: string;
13
+ }
14
+ export declare const Alert: ({ type, title, detail, actions, onClose, className, }: Props) => import("react").JSX.Element;
15
+ export {};
@@ -0,0 +1,54 @@
1
+ import { jsxs as n, jsx as r } from "react/jsx-runtime";
2
+ import { XClose as o, AlertCircle as d, AlertTriangle as v, CheckCircle as m, InfoCircle as i } from "@untitled-ui/icons-react";
3
+ import { cn as g } from "../../utils/cn.js";
4
+ const b = {
5
+ brand: "border-brand-v2-300 bg-brand-v2-25",
6
+ gray: "border-gray-v2-300 bg-gray-v2-25",
7
+ success: "border-success-v2-300 bg-success-v2-25",
8
+ warning: "border-warning-v2-300 bg-warning-v2-25",
9
+ error: "border-error-v2-300 bg-error-v2-25"
10
+ }, x = {
11
+ brand: /* @__PURE__ */ r(i, { className: "size-5 shrink-0 text-brand-v2-600" }),
12
+ gray: /* @__PURE__ */ r(i, { className: "size-5 shrink-0 text-gray-v2-600" }),
13
+ success: /* @__PURE__ */ r(m, { className: "size-5 shrink-0 text-success-v2-600" }),
14
+ warning: /* @__PURE__ */ r(v, { className: "size-5 shrink-0 text-warning-v2-600" }),
15
+ error: /* @__PURE__ */ r(d, { className: "size-5 shrink-0 text-error-v2-600" })
16
+ }, f = ({
17
+ type: e = "gray",
18
+ title: l,
19
+ detail: s,
20
+ actions: a,
21
+ onClose: t,
22
+ className: c
23
+ }) => /* @__PURE__ */ n(
24
+ "div",
25
+ {
26
+ role: "alert",
27
+ className: g(
28
+ "relative p-4 flex items-start gap-3 rounded-xl border shadow-xs",
29
+ b[e],
30
+ c
31
+ ),
32
+ children: [
33
+ x[e],
34
+ /* @__PURE__ */ n("div", { className: "flex-1 flex flex-col gap-1 min-w-0", children: [
35
+ /* @__PURE__ */ r("span", { className: "text-sm font-semibold text-gray-v2-700 wrap-break-words", children: l }),
36
+ s !== void 0 && /* @__PURE__ */ r("span", { className: "text-sm text-gray-v2-600 wrap-break-words", children: s }),
37
+ a !== void 0 && /* @__PURE__ */ r("div", { className: "mt-2 flex items-center gap-3", children: a })
38
+ ] }),
39
+ t && /* @__PURE__ */ r(
40
+ "button",
41
+ {
42
+ type: "button",
43
+ "aria-label": "Close",
44
+ onClick: t,
45
+ className: "shrink-0 flex p-0.5 text-gray-v2-400 hover:text-gray-v2-600 transition-colors cursor-pointer",
46
+ children: /* @__PURE__ */ r(o, { className: "size-5 shrink-0" })
47
+ }
48
+ )
49
+ ]
50
+ }
51
+ );
52
+ export {
53
+ f as Alert
54
+ };
@@ -0,0 +1,13 @@
1
+ export type AvatarSize = "xs" | "sm" | "md" | "lg" | "xl";
2
+ interface Props {
3
+ /** Image URL. Falls back to initials (from `name`) or a placeholder icon. */
4
+ src?: string;
5
+ /** Used for initials fallback and as the image alt text. */
6
+ name?: string;
7
+ size?: AvatarSize;
8
+ /** Shows an online/offline status indicator dot. */
9
+ status?: "online" | "offline";
10
+ className?: string;
11
+ }
12
+ export declare const Avatar: ({ src, name, size, status, className }: Props) => import("react").JSX.Element;
13
+ export {};
@@ -0,0 +1,64 @@
1
+ import { jsxs as c, jsx as r } from "react/jsx-runtime";
2
+ import { useState as x } from "react";
3
+ import { User01 as d } from "@untitled-ui/icons-react";
4
+ import { cn as i } from "../../utils/cn.js";
5
+ const u = {
6
+ xs: "size-6 text-xs",
7
+ sm: "size-8 text-sm",
8
+ md: "size-10 text-md",
9
+ lg: "size-12 text-lg",
10
+ xl: "size-14 text-xl"
11
+ }, f = {
12
+ xs: "size-4",
13
+ sm: "size-5",
14
+ md: "size-6",
15
+ lg: "size-7",
16
+ xl: "size-8"
17
+ }, S = {
18
+ xs: "size-1.5",
19
+ sm: "size-2",
20
+ md: "size-2.5",
21
+ lg: "size-3",
22
+ xl: "size-3.5"
23
+ };
24
+ function p(s) {
25
+ const e = s.trim().split(/\s+/);
26
+ return e.length === 0 || e[0].length === 0 ? "" : e.length === 1 ? e[0][0].toUpperCase() : (e[0][0] + e[e.length - 1][0]).toUpperCase();
27
+ }
28
+ const E = ({ src: s, name: e, size: t = "md", status: o, className: n }) => {
29
+ const [a, m] = x(!1), g = !!s && !a, l = e ? p(e) : "";
30
+ return /* @__PURE__ */ c(
31
+ "span",
32
+ {
33
+ className: i(
34
+ "relative inline-flex items-center justify-center shrink-0 rounded-full bg-gray-v2-100 border border-gray-v2-200 font-semibold text-gray-v2-600 select-none",
35
+ u[t],
36
+ n
37
+ ),
38
+ children: [
39
+ g ? /* @__PURE__ */ r(
40
+ "img",
41
+ {
42
+ src: s,
43
+ alt: e ?? "",
44
+ onError: () => m(!0),
45
+ className: "size-full rounded-full object-cover"
46
+ }
47
+ ) : l || /* @__PURE__ */ r(d, { className: i("text-gray-v2-500", f[t]) }),
48
+ o && /* @__PURE__ */ r(
49
+ "span",
50
+ {
51
+ className: i(
52
+ "absolute bottom-0 right-0 rounded-full border-[1.5px] border-white",
53
+ o === "online" ? "bg-success-v2-500" : "bg-gray-v2-300",
54
+ S[t]
55
+ )
56
+ }
57
+ )
58
+ ]
59
+ }
60
+ );
61
+ };
62
+ export {
63
+ E as Avatar
64
+ };
@@ -0,0 +1 @@
1
+ export declare const BackgroundPatternGrid: (props: React.SVGProps<SVGSVGElement>) => import("react").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import { jsx as t } from "react/jsx-runtime";
2
+ import o from "../../assets/background-pattern-grid.svg.js";
3
+ const d = (r) => /* @__PURE__ */ t(o, { ...r });
4
+ export {
5
+ d as BackgroundPatternGrid
6
+ };
@@ -26,4 +26,4 @@ export interface BadgeProps {
26
26
  * <Badge iconLeading={<AlertCircle />} onClose={handleDismiss}>Warning</Badge>
27
27
  * ```
28
28
  */
29
- export declare const Badge: ({ children, color, size, type, dot, iconLeading, iconTrailing, onClose, className, }: BadgeProps) => import("react/jsx-runtime").JSX.Element;
29
+ export declare const Badge: ({ children, color, size, type, dot, iconLeading, iconTrailing, onClose, className, }: BadgeProps) => import("react").JSX.Element;
@@ -4,7 +4,7 @@ import { XClose as k } from "@untitled-ui/icons-react";
4
4
  import { cn as u } from "../../utils/cn.js";
5
5
  import { Tooltip as B } from "../tooltip/Tooltip.js";
6
6
  import { useResizeObserver as R } from "../../hooks/element-shift/use-resize-observer.js";
7
- import { BADGE_ICON_SIZE_CLASSES as T, BADGE_DOT_CLASSES as h, BADGE_MODERN_TEXT_CLASSES as w, BADGE_COLOR_CLASSES as G, BADGE_SIZE_CLASSES as O, BADGE_TYPE_CLASSES as v } from "./badge-utils.js";
7
+ import { BADGE_DOT_CLASSES as T, BADGE_ICON_SIZE_CLASSES as h, BADGE_MODERN_TEXT_CLASSES as w, BADGE_COLOR_CLASSES as G, BADGE_SIZE_CLASSES as O, BADGE_TYPE_CLASSES as v } from "./badge-utils.js";
8
8
  const X = ({
9
9
  children: t,
10
10
  color: o = "gray",
@@ -41,7 +41,7 @@ const X = ({
41
41
  {
42
42
  className: u(
43
43
  "size-1.5 rounded-full shrink-0",
44
- h[o]
44
+ T[o]
45
45
  )
46
46
  }
47
47
  ) : null,
@@ -55,7 +55,7 @@ const X = ({
55
55
  "aria-label": typeof t == "string" ? `Remove ${t}` : "Remove",
56
56
  onClick: m,
57
57
  className: "shrink-0 cursor-pointer rounded-full p-0 hover:opacity-70 transition-opacity",
58
- children: /* @__PURE__ */ e(k, { className: T[a] })
58
+ children: /* @__PURE__ */ e(k, { className: h[a] })
59
59
  }
60
60
  ) : null
61
61
  ]
@@ -2,4 +2,4 @@
2
2
  * Test helper that renders a dismissible Badge and displays
3
3
  * whether the onClose callback was fired.
4
4
  */
5
- export declare const BadgeWithCloseDisplay: () => import("react/jsx-runtime").JSX.Element;
5
+ export declare const BadgeWithCloseDisplay: () => import("react").JSX.Element;
@@ -2,5 +2,5 @@ import { ReactNode } from 'react';
2
2
  interface Props {
3
3
  badges: ReactNode[];
4
4
  }
5
- export declare const BadgeMore: ({ badges }: Props) => import("react/jsx-runtime").JSX.Element | null;
5
+ export declare const BadgeMore: ({ badges }: Props) => import("react").JSX.Element | null;
6
6
  export {};
@@ -2,4 +2,4 @@
2
2
  * Test helper that renders a BadgeMore with a fixed set of badges
3
3
  * for use in hover interaction tests.
4
4
  */
5
- export declare const BadgeMoreHoverDisplay: () => import("react/jsx-runtime").JSX.Element;
5
+ export declare const BadgeMoreHoverDisplay: () => import("react").JSX.Element;
@@ -6,5 +6,5 @@ interface Props {
6
6
  name: string;
7
7
  size?: BadgeSize;
8
8
  }
9
- export declare const BadgeTag: ({ name, size }: Props) => import("react/jsx-runtime").JSX.Element;
9
+ export declare const BadgeTag: ({ name, size }: Props) => import("react").JSX.Element;
10
10
  export {};
@@ -2,7 +2,7 @@ import { jsx as o } from "react/jsx-runtime";
2
2
  import { Tag01 as g } from "@untitled-ui/icons-react";
3
3
  import { cn as i } from "../../../utils/cn.js";
4
4
  import { Badge as c } from "../Badge.js";
5
- import { BADGE_COLORS as n, BADGE_ICON_SIZE_CLASSES as l } from "../badge-utils.js";
5
+ import { BADGE_ICON_SIZE_CLASSES as l, BADGE_COLORS as n } from "../badge-utils.js";
6
6
  function u(t) {
7
7
  const r = Array.from(t).reduce(
8
8
  (e, a) => e + a.charCodeAt(0),
@@ -0,0 +1,9 @@
1
+ import { ReactNode } from 'react';
2
+ interface Props {
3
+ icon?: ReactNode;
4
+ message: ReactNode;
5
+ detail?: ReactNode;
6
+ className?: string;
7
+ }
8
+ export declare const Banner: ({ icon, message, detail, className }: Props) => import("react").JSX.Element;
9
+ export {};
@@ -0,0 +1,21 @@
1
+ import { jsxs as n, jsx as r } from "react/jsx-runtime";
2
+ import { cn as l } from "../../utils/cn.js";
3
+ const o = ({ icon: s, message: t, detail: e, className: a }) => /* @__PURE__ */ n(
4
+ "div",
5
+ {
6
+ className: l(
7
+ "px-8 py-3 flex items-center gap-4 bg-brand-v2-600 text-white",
8
+ a
9
+ ),
10
+ children: [
11
+ s,
12
+ /* @__PURE__ */ n("div", { className: "flex flex-col gap-0.5", children: [
13
+ /* @__PURE__ */ r("p", { className: "text-md font-semibold", children: t }),
14
+ e !== void 0 && /* @__PURE__ */ r("span", { className: "text-md font-normal", children: e })
15
+ ] })
16
+ ]
17
+ }
18
+ );
19
+ export {
20
+ o as Banner
21
+ };
@@ -0,0 +1,13 @@
1
+ interface Props {
2
+ homePath: string;
3
+ levels: {
4
+ name: string;
5
+ path: string;
6
+ }[];
7
+ currentPage: {
8
+ name: string;
9
+ tab?: string;
10
+ };
11
+ }
12
+ export declare const Breadcrumb: ({ homePath, levels, currentPage }: Props) => import("react").JSX.Element;
13
+ export {};
@@ -0,0 +1,36 @@
1
+ import { jsxs as e, jsx as a, Fragment as i } from "react/jsx-runtime";
2
+ import { Fragment as o } from "react";
3
+ import { Link as m } from "react-router-dom";
4
+ import { HomeLine as c, ChevronRight as n } from "@untitled-ui/icons-react";
5
+ const x = ({ homePath: s, levels: l, currentPage: r }) => /* @__PURE__ */ e("nav", { "aria-label": "Breadcrumb", className: "flex items-center gap-2", children: [
6
+ /* @__PURE__ */ a(m, { to: s, "aria-label": "Home", children: /* @__PURE__ */ a(c, { className: "h-5 w-5 text-gray-v2" }) }),
7
+ l.map((t) => /* @__PURE__ */ e(o, { children: [
8
+ /* @__PURE__ */ a(n, { className: "h-4 w-4 text-gray-v2-300" }),
9
+ /* @__PURE__ */ a(
10
+ m,
11
+ {
12
+ to: t.path,
13
+ className: "text-sm font-semibold text-gray-v2-600 no-underline",
14
+ children: t.name
15
+ }
16
+ )
17
+ ] }, `breadcrumb-level-${t.path}`)),
18
+ /* @__PURE__ */ a(n, { className: "h-4 w-4 text-gray-v2-300" }),
19
+ /* @__PURE__ */ e(
20
+ "span",
21
+ {
22
+ "aria-current": "page",
23
+ className: "text-sm font-semibold text-brand-v2-700",
24
+ children: [
25
+ r.name,
26
+ r.tab ? /* @__PURE__ */ e(i, { children: [
27
+ /* @__PURE__ */ a("span", { className: "text-brand-v2-300", children: " / " }),
28
+ r.tab
29
+ ] }) : null
30
+ ]
31
+ }
32
+ )
33
+ ] });
34
+ export {
35
+ x as Breadcrumb
36
+ };
@@ -0,0 +1,21 @@
1
+ import { ButtonHTMLAttributes } from 'react';
2
+ import { ButtonColor, ButtonLoadingStyle, ButtonSize, ButtonVariant } from './button-variants';
3
+ export interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
4
+ variant?: ButtonVariant;
5
+ color?: ButtonColor;
6
+ size?: ButtonSize;
7
+ /** Show a loading spinner and disable the button. */
8
+ pending?: boolean;
9
+ /** How the spinner is positioned relative to the button label. */
10
+ loadingStyle?: ButtonLoadingStyle;
11
+ }
12
+ /**
13
+ * @example With icon — size-4 for sm/md, size-5 for lg
14
+ * ```tsx
15
+ * <Button size="md">
16
+ * <Plus className="size-4" />
17
+ * New item
18
+ * </Button>
19
+ * ```
20
+ */
21
+ export declare const Button: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;