@chotot/clad-ui 3.0.0 → 3.0.1

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 (257) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/README.md +9 -9
  3. package/dist/{chunk-Bmb41Sf3.cjs → _virtual/_rolldown/runtime.cjs} +1 -1
  4. package/dist/brand/ChototLogoText.cjs +1 -0
  5. package/dist/brand/ChototLogoText.es.js +15 -0
  6. package/dist/brand/CtC2C.cjs +1 -0
  7. package/dist/brand/CtC2C.es.js +18 -0
  8. package/dist/brand/CtProperty.cjs +1 -0
  9. package/dist/brand/CtProperty.es.js +204 -0
  10. package/dist/brand/CtVehicle.cjs +1 -0
  11. package/dist/brand/CtVehicle.es.js +70 -0
  12. package/dist/brand/Tot.cjs +1 -0
  13. package/dist/brand/Tot.es.js +17 -0
  14. package/dist/components/Announcer/Announcer.cjs +1 -0
  15. package/dist/components/Announcer/Announcer.es.js +100 -0
  16. package/dist/components/Announcer/announcer.styles.cjs +1 -0
  17. package/dist/components/Announcer/announcer.styles.es.js +24 -0
  18. package/dist/components/Badge/Badge.cjs +1 -0
  19. package/dist/components/Badge/Badge.es.js +83 -0
  20. package/dist/components/Badge/badge.styles.cjs +1 -0
  21. package/dist/components/Badge/badge.styles.es.js +83 -0
  22. package/dist/components/Box/Box.cjs +1 -0
  23. package/dist/components/Box/Box.es.js +72 -0
  24. package/dist/components/Breadcrumbs/BreadcrumbItem.cjs +1 -0
  25. package/dist/components/Breadcrumbs/BreadcrumbItem.es.js +17 -0
  26. package/dist/components/Breadcrumbs/Breadcrumbs.cjs +1 -0
  27. package/dist/components/Breadcrumbs/Breadcrumbs.es.js +44 -0
  28. package/dist/components/Breadcrumbs/breadcrumbs.styles.cjs +1 -0
  29. package/dist/components/Breadcrumbs/breadcrumbs.styles.es.js +5 -0
  30. package/dist/components/Button/Button.cjs +1 -0
  31. package/dist/components/Button/Button.es.js +41 -0
  32. package/dist/components/Button/ButtonLink.cjs +1 -0
  33. package/dist/components/Button/ButtonLink.es.js +5 -0
  34. package/dist/components/Button/GhostButton.cjs +1 -0
  35. package/dist/components/Button/GhostButton.es.js +25 -0
  36. package/dist/components/Button/IconButton.cjs +1 -0
  37. package/dist/components/Button/IconButton.es.js +13 -0
  38. package/dist/components/Button/button.styles.cjs +1 -0
  39. package/dist/components/Button/button.styles.es.js +100 -0
  40. package/dist/components/Checkbox/Checkbox.cjs +1 -0
  41. package/dist/components/Checkbox/Checkbox.es.js +43 -0
  42. package/dist/components/Checkbox/checkbox.styles.cjs +1 -0
  43. package/dist/components/Checkbox/checkbox.styles.es.js +15 -0
  44. package/dist/components/Chip/Chip.cjs +1 -0
  45. package/dist/components/Chip/Chip.es.js +35 -0
  46. package/dist/components/Chip/chip.styles.cjs +1 -0
  47. package/dist/components/Chip/chip.styles.es.js +33 -0
  48. package/dist/components/CurrencyInput/CurrencyInput.cjs +1 -0
  49. package/dist/components/CurrencyInput/CurrencyInput.es.js +142 -0
  50. package/dist/components/CurrencyInput/currency-input.styles.cjs +1 -0
  51. package/dist/components/CurrencyInput/currency-input.styles.es.js +13 -0
  52. package/dist/components/CurrencyInput/utils.cjs +1 -0
  53. package/dist/components/CurrencyInput/utils.es.js +30 -0
  54. package/dist/components/DatePicker/DatePicker.cjs +1 -0
  55. package/dist/components/DatePicker/DatePicker.es.js +354 -0
  56. package/dist/components/DatePicker/DateTimePicker.cjs +1 -0
  57. package/dist/components/DatePicker/DateTimePicker.es.js +416 -0
  58. package/dist/components/DatePicker/date-picker.styles.cjs +1 -0
  59. package/dist/components/DatePicker/date-picker.styles.es.js +8 -0
  60. package/dist/components/DatePicker/date-time-picker.styles.cjs +1 -0
  61. package/dist/components/DatePicker/date-time-picker.styles.es.js +8 -0
  62. package/dist/components/DatePicker/index.d.ts +2 -1
  63. package/dist/components/DatePicker/types.cjs +1 -0
  64. package/dist/components/DatePicker/types.es.js +6 -0
  65. package/dist/components/Drawer/Drawer.cjs +1 -0
  66. package/dist/components/Drawer/Drawer.es.js +407 -0
  67. package/dist/components/Dropdown/Dropdown.cjs +1 -0
  68. package/dist/components/Dropdown/Dropdown.es.js +145 -0
  69. package/dist/components/Dropdown/dropdown.styles.cjs +1 -0
  70. package/dist/components/Dropdown/dropdown.styles.es.js +12 -0
  71. package/dist/components/EmptyState/EmptyState.cjs +2 -0
  72. package/dist/components/EmptyState/EmptyState.es.js +114 -0
  73. package/dist/components/EmptyState/empty-state.styles.cjs +1 -0
  74. package/dist/components/EmptyState/empty-state.styles.es.js +5 -0
  75. package/dist/components/Grid/Col.cjs +1 -0
  76. package/dist/components/Grid/Col.es.js +37 -0
  77. package/dist/components/Grid/Grid.cjs +1 -0
  78. package/dist/components/Grid/Grid.es.js +66 -0
  79. package/dist/components/Input/Input.cjs +1 -0
  80. package/dist/components/Input/Input.es.js +122 -0
  81. package/dist/components/Input/input.styles.cjs +1 -0
  82. package/dist/components/Input/input.styles.es.js +14 -0
  83. package/dist/components/InputGroup/InputGroup.cjs +1 -0
  84. package/dist/components/InputGroup/InputGroup.es.js +16 -0
  85. package/dist/components/InputGroup/input-group.styles.cjs +1 -0
  86. package/dist/components/InputGroup/input-group.styles.es.js +12 -0
  87. package/dist/components/LegacyDialog/DialogMainIcon.cjs +1 -0
  88. package/dist/components/LegacyDialog/DialogMainIcon.es.js +52 -0
  89. package/dist/components/LegacyDialog/LegacyDialog.cjs +1 -0
  90. package/dist/components/LegacyDialog/LegacyDialog.es.js +54 -0
  91. package/dist/components/LegacyPopup/LegacyPopup.cjs +1 -0
  92. package/dist/components/LegacyPopup/LegacyPopup.es.js +72 -0
  93. package/dist/components/MultiSearchDropdown/MultiSearchDropdown.cjs +1 -0
  94. package/dist/components/MultiSearchDropdown/MultiSearchDropdown.es.js +206 -0
  95. package/dist/components/MultiSearchDropdown/multi-search-dropdown.styles.cjs +1 -0
  96. package/dist/components/MultiSearchDropdown/multi-search-dropdown.styles.es.js +12 -0
  97. package/dist/components/Pagination/PageItem.cjs +1 -0
  98. package/dist/components/Pagination/PageItem.es.js +20 -0
  99. package/dist/components/Pagination/Pagination.cjs +1 -0
  100. package/dist/components/Pagination/Pagination.es.js +84 -0
  101. package/dist/components/Pagination/pagination.styles.cjs +1 -0
  102. package/dist/components/Pagination/pagination.styles.es.js +15 -0
  103. package/dist/components/Pagination/types.d.ts +1 -1
  104. package/dist/components/Popover/Popover.cjs +1 -0
  105. package/dist/components/Popover/Popover.es.js +54 -0
  106. package/dist/components/Popover/popover.styles.cjs +1 -0
  107. package/dist/components/Popover/popover.styles.es.js +5 -0
  108. package/dist/components/Popup/Popup.cjs +1 -0
  109. package/dist/components/Popup/Popup.es.js +148 -0
  110. package/dist/components/RadioButton/RadioButton.cjs +1 -0
  111. package/dist/components/RadioButton/RadioButton.es.js +61 -0
  112. package/dist/components/RadioButton/radio-button.styles.cjs +1 -0
  113. package/dist/components/RadioButton/radio-button.styles.es.js +15 -0
  114. package/dist/components/RangeInput/RangeInput.cjs +1 -0
  115. package/dist/components/RangeInput/RangeInput.es.js +32 -0
  116. package/dist/components/RangeInput/range-input.styles.cjs +1 -0
  117. package/dist/components/RangeInput/range-input.styles.es.js +5 -0
  118. package/dist/components/RowItem/RowItem.cjs +1 -0
  119. package/dist/components/RowItem/RowItem.es.js +56 -0
  120. package/dist/components/RowItem/rowitem.styles.cjs +1 -0
  121. package/dist/components/RowItem/rowitem.styles.es.js +23 -0
  122. package/dist/components/SearchInput/SearchInput.cjs +1 -0
  123. package/dist/components/SearchInput/SearchInput.es.js +129 -0
  124. package/dist/components/SearchInput/search-input.styles.cjs +1 -0
  125. package/dist/components/SearchInput/search-input.styles.es.js +12 -0
  126. package/dist/components/Searchbar/Searchbar.cjs +1 -0
  127. package/dist/components/Searchbar/Searchbar.es.js +51 -0
  128. package/dist/components/Searchbar/searchbar.styles.cjs +1 -0
  129. package/dist/components/Searchbar/searchbar.styles.es.js +5 -0
  130. package/dist/components/ShapeIcon/ShapeIcon.cjs +1 -0
  131. package/dist/components/ShapeIcon/ShapeIcon.es.js +22 -0
  132. package/dist/components/ShapeIcon/shape-icon.styles.cjs +1 -0
  133. package/dist/components/ShapeIcon/shape-icon.styles.es.js +65 -0
  134. package/dist/components/Slider/Slider.cjs +1 -0
  135. package/dist/components/Slider/Slider.es.js +169 -0
  136. package/dist/components/Slider/slider.styles.cjs +1 -0
  137. package/dist/components/Slider/slider.styles.es.js +5 -0
  138. package/dist/components/Snack/Snack.cjs +1 -0
  139. package/dist/components/Snack/Snack.es.js +69 -0
  140. package/dist/components/Snack/snack.styles.cjs +1 -0
  141. package/dist/components/Snack/snack.styles.es.js +13 -0
  142. package/dist/components/Tabs/Tab.cjs +1 -0
  143. package/dist/components/Tabs/Tab.es.js +42 -0
  144. package/dist/components/Tabs/Tabs.cjs +1 -0
  145. package/dist/components/Tabs/Tabs.es.js +80 -0
  146. package/dist/components/Tabs/tabs.styles.cjs +1 -0
  147. package/dist/components/Tabs/tabs.styles.es.js +33 -0
  148. package/dist/components/TagCloud/TagCloud.cjs +1 -0
  149. package/dist/components/TagCloud/TagCloud.es.js +47 -0
  150. package/dist/components/TagCloud/tagcloud.styles.cjs +1 -0
  151. package/dist/components/TagCloud/tagcloud.styles.es.js +12 -0
  152. package/dist/components/TextArea/TextArea.cjs +1 -0
  153. package/dist/components/TextArea/TextArea.es.js +104 -0
  154. package/dist/components/TextArea/text-area.styles.cjs +1 -0
  155. package/dist/components/TextArea/text-area.styles.es.js +13 -0
  156. package/dist/components/TextLabel/TextLabel.cjs +1 -0
  157. package/dist/components/TextLabel/TextLabel.es.js +28 -0
  158. package/dist/components/TextLabel/textlabel.styles.cjs +1 -0
  159. package/dist/components/TextLabel/textlabel.styles.es.js +29 -0
  160. package/dist/components/ToggleSwitch/ToggleSwitch.cjs +1 -0
  161. package/dist/components/ToggleSwitch/ToggleSwitch.es.js +37 -0
  162. package/dist/components/ToggleSwitch/toggle-switch.styles.cjs +1 -0
  163. package/dist/components/ToggleSwitch/toggle-switch.styles.es.js +24 -0
  164. package/dist/components/Tooltip/Tooltip.cjs +1 -0
  165. package/dist/components/Tooltip/Tooltip.es.js +103 -0
  166. package/dist/components/Tooltip/tooltip.styles.cjs +1 -0
  167. package/dist/components/Tooltip/tooltip.styles.es.js +12 -0
  168. package/dist/forge/index.cjs +1 -0
  169. package/dist/icons.cjs +1 -1
  170. package/dist/index.cjs +1 -0
  171. package/dist/index.es.js +82 -0
  172. package/dist/styles.css +1 -1
  173. package/dist/types/index.cjs +1 -0
  174. package/dist/types/index.es.js +7 -0
  175. package/dist/typography/BodyAnnotation.cjs +1 -0
  176. package/dist/typography/BodyAnnotation.es.js +10 -0
  177. package/dist/typography/BodyCaption.cjs +1 -0
  178. package/dist/typography/BodyCaption.es.js +10 -0
  179. package/dist/typography/BodyPage.cjs +1 -0
  180. package/dist/typography/BodyPage.es.js +10 -0
  181. package/dist/typography/BodySection.cjs +1 -0
  182. package/dist/typography/BodySection.es.js +10 -0
  183. package/dist/typography/DisplayAnnotation.cjs +1 -0
  184. package/dist/typography/DisplayAnnotation.es.js +10 -0
  185. package/dist/typography/DisplayCaption.cjs +1 -0
  186. package/dist/typography/DisplayCaption.es.js +10 -0
  187. package/dist/typography/DisplayPage.cjs +1 -0
  188. package/dist/typography/DisplayPage.es.js +10 -0
  189. package/dist/typography/DisplayPrice.cjs +1 -0
  190. package/dist/typography/DisplayPrice.es.js +10 -0
  191. package/dist/typography/DisplaySection.cjs +1 -0
  192. package/dist/typography/DisplaySection.es.js +10 -0
  193. package/dist/typography/HeaderAnnotation.cjs +1 -0
  194. package/dist/typography/HeaderAnnotation.es.js +10 -0
  195. package/dist/typography/HeaderCaption.cjs +1 -0
  196. package/dist/typography/HeaderCaption.es.js +10 -0
  197. package/dist/typography/HeaderPage.cjs +1 -0
  198. package/dist/typography/HeaderPage.es.js +10 -0
  199. package/dist/typography/HeaderSection.cjs +1 -0
  200. package/dist/typography/HeaderSection.es.js +10 -0
  201. package/dist/typography/LabelAnnotation.cjs +1 -0
  202. package/dist/typography/LabelAnnotation.es.js +10 -0
  203. package/dist/typography/LabelCaption.cjs +1 -0
  204. package/dist/typography/LabelCaption.es.js +10 -0
  205. package/dist/typography/LabelPage.cjs +1 -0
  206. package/dist/typography/LabelPage.es.js +10 -0
  207. package/dist/typography/LabelSection.cjs +1 -0
  208. package/dist/typography/LabelSection.es.js +10 -0
  209. package/dist/typography/NoteCaption.cjs +1 -0
  210. package/dist/typography/NoteCaption.es.js +10 -0
  211. package/dist/typography/NotePage.cjs +1 -0
  212. package/dist/typography/NotePage.es.js +10 -0
  213. package/dist/typography/NoteSection.cjs +1 -0
  214. package/dist/typography/NoteSection.es.js +10 -0
  215. package/dist/typography/TaglineAnnotation.cjs +1 -0
  216. package/dist/typography/TaglineAnnotation.es.js +10 -0
  217. package/dist/typography/TaglineCaption.cjs +1 -0
  218. package/dist/typography/TaglineCaption.es.js +10 -0
  219. package/dist/typography/TaglineFootext.cjs +1 -0
  220. package/dist/typography/TaglineFootext.es.js +10 -0
  221. package/dist/typography/TaglineSection.cjs +1 -0
  222. package/dist/typography/TaglineSection.es.js +10 -0
  223. package/dist/utils/bundleCss.cjs +1 -1
  224. package/dist/utils/cleanHtml.cjs +1 -0
  225. package/dist/utils/cleanHtml.es.js +6 -0
  226. package/dist/utils/cn.cjs +1 -0
  227. package/dist/utils/cn.es.js +59 -0
  228. package/dist/utils/createUniversalPortal.cjs +1 -0
  229. package/dist/utils/createUniversalPortal.es.js +17 -0
  230. package/dist/utils/floating.cjs +1 -0
  231. package/dist/utils/floating.es.js +374 -0
  232. package/dist/utils/getBreakpointsValues.cjs +1 -0
  233. package/dist/utils/getBreakpointsValues.es.js +27 -0
  234. package/dist/utils/sizes.cjs +1 -0
  235. package/dist/utils/sizes.es.js +30 -0
  236. package/dist/utils/themeTokens.cjs +1 -0
  237. package/dist/utils/themeTokens.es.js +319 -0
  238. package/dist/utils/useBodyScrollLock.cjs +1 -0
  239. package/dist/utils/useBodyScrollLock.es.js +24 -0
  240. package/dist/utils/useScrollTop.cjs +1 -0
  241. package/dist/utils/useScrollTop.es.js +9 -0
  242. package/package.json +6 -6
  243. package/scripts/postinstall.cjs +34 -6
  244. package/skills/clad-ui/SKILL.md +3 -1
  245. package/skills/clad-ui-feedback/SKILL.md +1 -1
  246. package/skills/migrate-clad-ui-v3/SKILL.md +4 -2
  247. package/skills/migrate-clad-ui-v3/references/component-api-changes.md +42 -0
  248. package/skills/migrate-clad-ui-v3/references/token-and-linaria-mapping.md +4 -1
  249. package/src/styles/preset.css +1 -1
  250. package/dist/clad-ui.cjs +0 -2
  251. package/dist/clad-ui.d.ts +0 -2
  252. package/dist/clad-ui.es.js +0 -9791
  253. package/dist/components/Drawer/Drawer.pw.fixtures.d.ts +0 -9
  254. package/dist/components/Grid/Grid.pw.fixtures.d.ts +0 -3
  255. package/dist/components/Popover/Popover.pw.fixtures.d.ts +0 -6
  256. package/dist/components/Popup/Popup.pw.fixtures.d.ts +0 -5
  257. package/dist/components/Tooltip/Tooltip.pw.fixtures.d.ts +0 -1
@@ -0,0 +1,83 @@
1
+ import e from "../../utils/cn.es.js";
2
+ import { badgeVariants as t } from "./badge.styles.es.js";
3
+ import * as n from "react";
4
+ import { jsx as r, jsxs as i } from "react/jsx-runtime";
5
+ //#region src/components/Badge/Badge.tsx
6
+ var a = {
7
+ none: "0",
8
+ xs: "2px",
9
+ sm: "4px",
10
+ md: "8px",
11
+ lg: "12px",
12
+ xl: "20px",
13
+ pill: "9999px",
14
+ circle: "100%"
15
+ }, o = {
16
+ dot: "1px",
17
+ sm: "8px",
18
+ md: "8px",
19
+ lg: "10px"
20
+ }, s = ({ size: s = "sm", children: c = "Default Badge Children", label: l = "", backgroundColor: u = "warning", variant: d = "solid", position: f = "topRight", zIndex: p = 1, borderRadius: m = "none", className: h = "", style: g, ..._ }) => {
21
+ let v = n.useMemo(() => {
22
+ let e = o[s] || "8px", t = s === "dot" ? "100%" : m ? a[m] : a.pill;
23
+ switch (f) {
24
+ case "right": return {
25
+ zIndex: p,
26
+ borderRadius: t,
27
+ top: "50%",
28
+ left: "unset",
29
+ right: `-${e}`,
30
+ transform: "translateX(100%) translateY(-50%)"
31
+ };
32
+ case "topRight": return {
33
+ zIndex: p,
34
+ borderRadius: t,
35
+ top: `-${e}`,
36
+ left: "unset",
37
+ right: `-${e}`,
38
+ transform: "unset"
39
+ };
40
+ case "topLeft": return {
41
+ zIndex: p,
42
+ borderRadius: t,
43
+ top: `-${e}`,
44
+ left: `-${e}`,
45
+ right: "unset",
46
+ transform: "unset"
47
+ };
48
+ default: return {
49
+ zIndex: p,
50
+ borderRadius: t,
51
+ top: "unset",
52
+ left: "unset",
53
+ right: "unset",
54
+ transform: "unset"
55
+ };
56
+ }
57
+ }, [
58
+ f,
59
+ s,
60
+ p,
61
+ m
62
+ ]);
63
+ return /* @__PURE__ */ i("div", {
64
+ className: "badge-wrapper",
65
+ children: [/* @__PURE__ */ r("div", {
66
+ ..._,
67
+ "data-clad": "Badge",
68
+ className: e(t({
69
+ size: s,
70
+ backgroundColor: u,
71
+ variant: d
72
+ }), h),
73
+ style: {
74
+ ...v,
75
+ ...g
76
+ },
77
+ children: s !== "dot" && l
78
+ }), c]
79
+ });
80
+ };
81
+ s.displayName = "Badge";
82
+ //#endregion
83
+ export { s as default };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);var e=(0,require(`tailwind-variants/lite`).tv)({base:`badge`,defaultVariants:{size:`sm`,backgroundColor:`warning`,variant:`solid`},variants:{size:{sm:`badge--sm`,md:`badge--md`,lg:`badge--lg`,dot:`badge--dot`},backgroundColor:{error:``,warning:``,info:``,success:``,neutral:``},variant:{solid:``,tonal:``}},compoundVariants:[{backgroundColor:`error`,variant:`solid`,className:`badge--error-solid`},{backgroundColor:`error`,variant:`tonal`,className:`badge--error-tonal`},{backgroundColor:`warning`,variant:`solid`,className:`badge--warning-solid`},{backgroundColor:`warning`,variant:`tonal`,className:`badge--warning-tonal`},{backgroundColor:`info`,variant:`solid`,className:`badge--info-solid`},{backgroundColor:`info`,variant:`tonal`,className:`badge--info-tonal`},{backgroundColor:`success`,variant:`solid`,className:`badge--success-solid`},{backgroundColor:`success`,variant:`tonal`,className:`badge--success-tonal`},{backgroundColor:`neutral`,variant:`solid`,className:`badge--neutral-solid`},{backgroundColor:`neutral`,variant:`tonal`,className:`badge--neutral-tonal`}]});exports.badgeVariants=e;
@@ -0,0 +1,83 @@
1
+ import { tv as e } from "tailwind-variants/lite";
2
+ //#region src/components/Badge/badge.styles.ts
3
+ var t = e({
4
+ base: "badge",
5
+ defaultVariants: {
6
+ size: "sm",
7
+ backgroundColor: "warning",
8
+ variant: "solid"
9
+ },
10
+ variants: {
11
+ size: {
12
+ sm: "badge--sm",
13
+ md: "badge--md",
14
+ lg: "badge--lg",
15
+ dot: "badge--dot"
16
+ },
17
+ backgroundColor: {
18
+ error: "",
19
+ warning: "",
20
+ info: "",
21
+ success: "",
22
+ neutral: ""
23
+ },
24
+ variant: {
25
+ solid: "",
26
+ tonal: ""
27
+ }
28
+ },
29
+ compoundVariants: [
30
+ {
31
+ backgroundColor: "error",
32
+ variant: "solid",
33
+ className: "badge--error-solid"
34
+ },
35
+ {
36
+ backgroundColor: "error",
37
+ variant: "tonal",
38
+ className: "badge--error-tonal"
39
+ },
40
+ {
41
+ backgroundColor: "warning",
42
+ variant: "solid",
43
+ className: "badge--warning-solid"
44
+ },
45
+ {
46
+ backgroundColor: "warning",
47
+ variant: "tonal",
48
+ className: "badge--warning-tonal"
49
+ },
50
+ {
51
+ backgroundColor: "info",
52
+ variant: "solid",
53
+ className: "badge--info-solid"
54
+ },
55
+ {
56
+ backgroundColor: "info",
57
+ variant: "tonal",
58
+ className: "badge--info-tonal"
59
+ },
60
+ {
61
+ backgroundColor: "success",
62
+ variant: "solid",
63
+ className: "badge--success-solid"
64
+ },
65
+ {
66
+ backgroundColor: "success",
67
+ variant: "tonal",
68
+ className: "badge--success-tonal"
69
+ },
70
+ {
71
+ backgroundColor: "neutral",
72
+ variant: "solid",
73
+ className: "badge--neutral-solid"
74
+ },
75
+ {
76
+ backgroundColor: "neutral",
77
+ variant: "tonal",
78
+ className: "badge--neutral-tonal"
79
+ }
80
+ ]
81
+ });
82
+ //#endregion
83
+ export { t as badgeVariants };
@@ -0,0 +1 @@
1
+ const e=require(`../../_virtual/_rolldown/runtime.cjs`),t=require(`../../utils/cn.cjs`),n=require(`../../utils/cleanHtml.cjs`),r=require(`../../utils/getBreakpointsValues.cjs`),i=require(`../../utils/themeTokens.cjs`);let a=require(`react`);a=e.__toESM(a);let o=require(`react/jsx-runtime`);var s=(e,t)=>r.default(e,t).map(e=>i.SPACE_MAP[e]||i.SPACE_MAP.none),c=(e,t)=>r.default(e,t).map(e=>i.SIZES_TOKENS_MAP[e]||`initial`),l=(e,t)=>r.default(e,t).map(e=>`${i.BORDER_WIDTHS_MAP[e]||i.BORDER_WIDTHS_MAP.none}`),u=(e,t)=>r.default(e,t).map(e=>i.RADII_MAP[e]||i.RADII_MAP.none),d=(e,t)=>r.default(e,t).map(e=>i.SHADOWS_MAP[e]||i.SHADOWS_MAP.none),f=({as:e=`div`,className:r=``,style:a=void 0,borderColor:f=null,alignItems:p=`initial`,justifyContent:m=`initial`,textAlign:h=`initial`,color:g=null,backgroundColor:_=null,backgroundImage:v=``,padding:y=`none`,paddingx:b=null,paddingy:x=null,width:S=`full`,maxWidth:C=`full`,height:w=`initial`,borderWidth:T=`none`,borderRadius:E=`none`,boxShadow:D=`none`,children:O=null,dangerousHtml:k=``,...A})=>{let j=t.default(`clad-box`,(m!==`initial`||p!==`initial`)&&`flex`,r),M;typeof k==`string`&&k.trim()&&(M={__html:n.default(k)});let N=p===`start`&&`flex-start`||p===`end`&&`flex-end`||p,P=m===`start`&&`flex-start`||m===`end`&&`flex-end`||m===`between`&&`space-between`||m===`around`&&`space-around`||m,F=b??y,I=x??y,L=s(F,`initial`),R=s(I,`initial`),z=c(S,`initial`),B=c(C,`initial`),V=c(w,`initial`),H=l(T,`initial`),U=u(E,`initial`),W=d(D,`initial`),G={"--box-color":g&&i.COLORS_MAP[g]||`initial`,"--box-text-align":h,"--box-bg-color":_&&i.COLORS_MAP[_]||`transparent`,"--box-border-color":f&&i.COLORS_MAP[f]||`currentColor`,"--box-bg-image":v?`url(${v})`:`none`,"--box-justify":P,"--box-align":N,"--box-px-0":L[0],"--box-px-1":L[1],"--box-px-2":L[2],"--box-px-3":L[3],"--box-px-4":L[4],"--box-py-0":R[0],"--box-py-1":R[1],"--box-py-2":R[2],"--box-py-3":R[3],"--box-py-4":R[4],"--box-w-0":z[0],"--box-w-1":z[1],"--box-w-2":z[2],"--box-w-3":z[3],"--box-w-4":z[4],"--box-max-w-0":B[0],"--box-max-w-1":B[1],"--box-max-w-2":B[2],"--box-max-w-3":B[3],"--box-max-w-4":B[4],"--box-h-0":V[0],"--box-h-1":V[1],"--box-h-2":V[2],"--box-h-3":V[3],"--box-h-4":V[4],"--box-bw-0":H[0],"--box-bw-1":H[1],"--box-bw-2":H[2],"--box-bw-3":H[3],"--box-bw-4":H[4],"--box-br-0":U[0],"--box-br-1":U[1],"--box-br-2":U[2],"--box-br-3":U[3],"--box-br-4":U[4],"--box-shadow-0":W[0],"--box-shadow-1":W[1],"--box-shadow-2":W[2],"--box-shadow-3":W[3],"--box-shadow-4":W[4],...a};return(0,o.jsx)(e,{...A,className:j,style:G,dangerouslySetInnerHTML:M,"data-clad":`Box`,children:M?null:O})};f.displayName=`Box`,exports.default=f,exports.getBorderWidth=l,exports.getRadiis=u,exports.getShadows=d,exports.getSizes=c,exports.getSpaces=s;
@@ -0,0 +1,72 @@
1
+ import e from "../../utils/cn.es.js";
2
+ import t from "../../utils/cleanHtml.es.js";
3
+ import n from "../../utils/getBreakpointsValues.es.js";
4
+ import { BORDER_WIDTHS_MAP as r, COLORS_MAP as i, RADII_MAP as a, SHADOWS_MAP as o, SIZES_TOKENS_MAP as s, SPACE_MAP as c } from "../../utils/themeTokens.es.js";
5
+ import "react";
6
+ import { jsx as l } from "react/jsx-runtime";
7
+ //#region src/components/Box/Box.tsx
8
+ var u = (e, t) => n(e, t).map((e) => c[e] || c.none), d = (e, t) => n(e, t).map((e) => s[e] || "initial"), f = (e, t) => n(e, t).map((e) => `${r[e] || r.none}`), p = (e, t) => n(e, t).map((e) => a[e] || a.none), m = (e, t) => n(e, t).map((e) => o[e] || o.none), h = ({ as: n = "div", className: r = "", style: a = void 0, borderColor: o = null, alignItems: s = "initial", justifyContent: c = "initial", textAlign: h = "initial", color: g = null, backgroundColor: _ = null, backgroundImage: v = "", padding: y = "none", paddingx: b = null, paddingy: x = null, width: S = "full", maxWidth: C = "full", height: w = "initial", borderWidth: T = "none", borderRadius: E = "none", boxShadow: D = "none", children: O = null, dangerousHtml: k = "", ...A }) => {
9
+ let j = e("clad-box", (c !== "initial" || s !== "initial") && "flex", r), M;
10
+ typeof k == "string" && k.trim() && (M = { __html: t(k) });
11
+ let N = s === "start" && "flex-start" || s === "end" && "flex-end" || s, P = c === "start" && "flex-start" || c === "end" && "flex-end" || c === "between" && "space-between" || c === "around" && "space-around" || c, F = b ?? y, I = x ?? y, L = u(F, "initial"), R = u(I, "initial"), z = d(S, "initial"), B = d(C, "initial"), V = d(w, "initial"), H = f(T, "initial"), U = p(E, "initial"), W = m(D, "initial"), G = {
12
+ "--box-color": g && i[g] || "initial",
13
+ "--box-text-align": h,
14
+ "--box-bg-color": _ && i[_] || "transparent",
15
+ "--box-border-color": o && i[o] || "currentColor",
16
+ "--box-bg-image": v ? `url(${v})` : "none",
17
+ "--box-justify": P,
18
+ "--box-align": N,
19
+ "--box-px-0": L[0],
20
+ "--box-px-1": L[1],
21
+ "--box-px-2": L[2],
22
+ "--box-px-3": L[3],
23
+ "--box-px-4": L[4],
24
+ "--box-py-0": R[0],
25
+ "--box-py-1": R[1],
26
+ "--box-py-2": R[2],
27
+ "--box-py-3": R[3],
28
+ "--box-py-4": R[4],
29
+ "--box-w-0": z[0],
30
+ "--box-w-1": z[1],
31
+ "--box-w-2": z[2],
32
+ "--box-w-3": z[3],
33
+ "--box-w-4": z[4],
34
+ "--box-max-w-0": B[0],
35
+ "--box-max-w-1": B[1],
36
+ "--box-max-w-2": B[2],
37
+ "--box-max-w-3": B[3],
38
+ "--box-max-w-4": B[4],
39
+ "--box-h-0": V[0],
40
+ "--box-h-1": V[1],
41
+ "--box-h-2": V[2],
42
+ "--box-h-3": V[3],
43
+ "--box-h-4": V[4],
44
+ "--box-bw-0": H[0],
45
+ "--box-bw-1": H[1],
46
+ "--box-bw-2": H[2],
47
+ "--box-bw-3": H[3],
48
+ "--box-bw-4": H[4],
49
+ "--box-br-0": U[0],
50
+ "--box-br-1": U[1],
51
+ "--box-br-2": U[2],
52
+ "--box-br-3": U[3],
53
+ "--box-br-4": U[4],
54
+ "--box-shadow-0": W[0],
55
+ "--box-shadow-1": W[1],
56
+ "--box-shadow-2": W[2],
57
+ "--box-shadow-3": W[3],
58
+ "--box-shadow-4": W[4],
59
+ ...a
60
+ };
61
+ return /* @__PURE__ */ l(n, {
62
+ ...A,
63
+ className: j,
64
+ style: G,
65
+ dangerouslySetInnerHTML: M,
66
+ "data-clad": "Box",
67
+ children: M ? null : O
68
+ });
69
+ };
70
+ h.displayName = "Box";
71
+ //#endregion
72
+ export { h as default, f as getBorderWidth, p as getRadiis, m as getShadows, d as getSizes, u as getSpaces };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../../utils/cn.cjs`),t=require(`../../types/index.cjs`),n=require(`./breadcrumbs.styles.cjs`);let r=require(`react`);var i=t.forwardRef((t,i)=>{let{className:a,children:o,as:s=`a`,...c}=t;return(0,r.createElement)(s,{ref:i,className:e.default(n.breadcrumbItemVariants(),a),"data-clad":`BreadcrumbItem`,...c},o)});i.displayName=`BreadcrumbItem`,exports.default=i;
@@ -0,0 +1,17 @@
1
+ import e from "../../utils/cn.es.js";
2
+ import { forwardRef as t } from "../../types/index.es.js";
3
+ import { breadcrumbItemVariants as n } from "./breadcrumbs.styles.es.js";
4
+ import { createElement as r } from "react";
5
+ //#region src/components/Breadcrumbs/BreadcrumbItem.tsx
6
+ var i = t((t, i) => {
7
+ let { className: a, children: o, as: s = "a", ...c } = t;
8
+ return r(s, {
9
+ ref: i,
10
+ className: e(n(), a),
11
+ "data-clad": "BreadcrumbItem",
12
+ ...c
13
+ }, o);
14
+ });
15
+ i.displayName = "BreadcrumbItem";
16
+ //#endregion
17
+ export { i as default };
@@ -0,0 +1 @@
1
+ const e=require(`../../_virtual/_rolldown/runtime.cjs`),t=require(`../../utils/cn.cjs`),n=require(`../../types/index.cjs`),r=require(`./breadcrumbs.styles.cjs`),i=require(`./BreadcrumbItem.cjs`);let a=require(`react`);a=e.__toESM(a);let o=require(`react/jsx-runtime`);var s=n.forwardRef((e,n)=>{let{className:s,children:c,isShow:l=!0,as:u=`ol`,...d}=e;if(!(0,a.isValidElement)(c)&&!Array.isArray(c)||!l)return(0,a.createElement)(`div`,{className:t.default(`breadcrumbs-placeholder`,s)});let f=a.Children.count(c);return(0,a.createElement)(u,{ref:n,className:t.default(r.breadcrumbsVariants(),s),itemScope:!0,itemType:`https://schema.org/BreadcrumbList`,"data-clad":`Breadcrumbs`,...d},a.Children.map(c,(e,t)=>{if(!(0,a.isValidElement)(e))return null;let n=t===f-1,r=e;return(0,o.jsxs)(`li`,{itemProp:`itemListElement`,itemScope:!0,itemType:`https://schema.org/ListItem`,children:[n?(0,o.jsx)(`span`,{className:`breadcrumb-current`,itemProp:`name`,"aria-current":`page`,children:r.props.children}):(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(i.default,{...r.props}),(0,o.jsx)(`span`,{className:`breadcrumb-separator`,"aria-hidden":`true`,children:`/`})]}),(0,o.jsx)(`meta`,{itemProp:`position`,content:(t+1).toString()})]})}))});s.displayName=`Breadcrumbs`,exports.default=s;
@@ -0,0 +1,44 @@
1
+ import e from "../../utils/cn.es.js";
2
+ import { forwardRef as t } from "../../types/index.es.js";
3
+ import { breadcrumbsVariants as n } from "./breadcrumbs.styles.es.js";
4
+ import r from "./BreadcrumbItem.es.js";
5
+ import { Children as i, createElement as a, isValidElement as o } from "react";
6
+ import { Fragment as s, jsx as c, jsxs as l } from "react/jsx-runtime";
7
+ //#region src/components/Breadcrumbs/Breadcrumbs.tsx
8
+ var u = t((t, u) => {
9
+ let { className: d, children: f, isShow: p = !0, as: m = "ol", ...h } = t;
10
+ if (!o(f) && !Array.isArray(f) || !p) return a("div", { className: e("breadcrumbs-placeholder", d) });
11
+ let g = i.count(f);
12
+ return a(m, {
13
+ ref: u,
14
+ className: e(n(), d),
15
+ itemScope: !0,
16
+ itemType: "https://schema.org/BreadcrumbList",
17
+ "data-clad": "Breadcrumbs",
18
+ ...h
19
+ }, i.map(f, (e, t) => {
20
+ if (!o(e)) return null;
21
+ let n = t === g - 1, i = e;
22
+ return /* @__PURE__ */ l("li", {
23
+ itemProp: "itemListElement",
24
+ itemScope: !0,
25
+ itemType: "https://schema.org/ListItem",
26
+ children: [n ? /* @__PURE__ */ c("span", {
27
+ className: "breadcrumb-current",
28
+ itemProp: "name",
29
+ "aria-current": "page",
30
+ children: i.props.children
31
+ }) : /* @__PURE__ */ l(s, { children: [/* @__PURE__ */ c(r, { ...i.props }), /* @__PURE__ */ c("span", {
32
+ className: "breadcrumb-separator",
33
+ "aria-hidden": "true",
34
+ children: "/"
35
+ })] }), /* @__PURE__ */ c("meta", {
36
+ itemProp: "position",
37
+ content: (t + 1).toString()
38
+ })]
39
+ });
40
+ }));
41
+ });
42
+ u.displayName = "Breadcrumbs";
43
+ //#endregion
44
+ export { u as default };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);let e=require(`tailwind-variants/lite`);var t=(0,e.tv)({base:`breadcrumbs`}),n=(0,e.tv)({base:`breadcrumb-item`});exports.breadcrumbItemVariants=n,exports.breadcrumbsVariants=t;
@@ -0,0 +1,5 @@
1
+ import { tv as e } from "tailwind-variants/lite";
2
+ //#region src/components/Breadcrumbs/breadcrumbs.styles.ts
3
+ var t = e({ base: "breadcrumbs" }), n = e({ base: "breadcrumb-item" });
4
+ //#endregion
5
+ export { n as breadcrumbItemVariants, t as breadcrumbsVariants };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../../utils/cn.cjs`),t=require(`../../types/index.cjs`),n=require(`../../utils/sizes.cjs`),r=require(`./button.styles.cjs`);let i=require(`react`),a=require(`@chotot/icons`);function o(e){return e===`accent`||e===`positive`?`success`:e===`critical`?`error`:e===`chotot`||e===`caution`?`primary`:e}var s=t.forwardRef((t,s)=>{let{size:c=`medium`,color:l=`primary`,variant:u=`solid`,radius:d,weight:f,stretch:p=!1,width:m,icon:h=!1,isLoading:g=!1,extraClasses:_,className:v,style:y,children:b,onClick:x,type:S=`button`,as:C=`button`,disabled:w=!1,...T}=t,E=o(l),D=m?{width:n.SIZES_MAP[m]??m,...y}:y,O;return h||(Array.isArray(b)?O=b[1]&&(0,i.isValidElement)(b[1])?`right`:`left`:g&&b&&(O=`left`)),(0,i.createElement)(C,{ref:s,type:C===`button`?S:void 0,className:e.default(r.buttonVariants({size:c,color:E,variant:u,radius:d,weight:f,stretch:p,icon:h,iconPosition:O,isLoading:g}),_,v),style:D,onClick:!w&&!g?x:void 0,"aria-busy":g,"aria-disabled":w||g,disabled:w,"data-clad":`Button`,...T},g&&(0,i.createElement)(a.Loading,{"aria-hidden":!0}),b)});s.displayName=`Button`,exports.default=s;
@@ -0,0 +1,41 @@
1
+ import e from "../../utils/cn.es.js";
2
+ import { forwardRef as t } from "../../types/index.es.js";
3
+ import { SIZES_MAP as n } from "../../utils/sizes.es.js";
4
+ import { buttonVariants as r } from "./button.styles.es.js";
5
+ import { createElement as i, isValidElement as a } from "react";
6
+ import { Loading as o } from "@chotot/icons";
7
+ //#region src/components/Button/Button.tsx
8
+ function s(e) {
9
+ return e === "accent" || e === "positive" ? "success" : e === "critical" ? "error" : e === "chotot" || e === "caution" ? "primary" : e;
10
+ }
11
+ var c = t((t, c) => {
12
+ let { size: l = "medium", color: u = "primary", variant: d = "solid", radius: f, weight: p, stretch: m = !1, width: h, icon: g = !1, isLoading: _ = !1, extraClasses: v, className: y, style: b, children: x, onClick: S, type: C = "button", as: w = "button", disabled: T = !1, ...E } = t, D = s(u), O = h ? {
13
+ width: n[h] ?? h,
14
+ ...b
15
+ } : b, k;
16
+ return g || (Array.isArray(x) ? k = x[1] && a(x[1]) ? "right" : "left" : _ && x && (k = "left")), i(w, {
17
+ ref: c,
18
+ type: w === "button" ? C : void 0,
19
+ className: e(r({
20
+ size: l,
21
+ color: D,
22
+ variant: d,
23
+ radius: f,
24
+ weight: p,
25
+ stretch: m,
26
+ icon: g,
27
+ iconPosition: k,
28
+ isLoading: _
29
+ }), v, y),
30
+ style: O,
31
+ onClick: !T && !_ ? S : void 0,
32
+ "aria-busy": _,
33
+ "aria-disabled": T || _,
34
+ disabled: T,
35
+ "data-clad": "Button",
36
+ ...E
37
+ }, _ && i(o, { "aria-hidden": !0 }), x);
38
+ });
39
+ c.displayName = "Button";
40
+ //#endregion
41
+ export { c as default };
@@ -0,0 +1 @@
1
+ var e=require(`./GhostButton.cjs`).default;exports.default=e;
@@ -0,0 +1,5 @@
1
+ import e from "./GhostButton.es.js";
2
+ //#region src/components/Button/ButtonLink.tsx
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../../utils/cn.cjs`),t=require(`../../types/index.cjs`),n=require(`./button.styles.cjs`);let r=require(`react`);var i=t.forwardRef((t,i)=>{let{as:a=`a`,children:o,disabled:s=!1,className:c,onClick:l,radius:u=`normal`,size:d=`medium`,stretch:f=!1,variant:p=`button`,weight:m=`bold`,color:h=`link`,...g}=t,_=p===`button`?`ghost-button--${h}`:`ghost-button--hyperlink ghost-button--h-${h}`;return(0,r.createElement)(a,{ref:i,className:e.default(n.ghostButtonVariants({size:d,radius:u,weight:m,stretch:f,disabled:s}),_,c),disabled:s&&!0,onClick:!s&&l?l:void 0,"data-clad":`Ghost Button`,...g},o)});i.displayName=`GhostButton`,exports.default=i;
@@ -0,0 +1,25 @@
1
+ import e from "../../utils/cn.es.js";
2
+ import { forwardRef as t } from "../../types/index.es.js";
3
+ import { ghostButtonVariants as n } from "./button.styles.es.js";
4
+ import { createElement as r } from "react";
5
+ //#region src/components/Button/GhostButton.tsx
6
+ var i = t((t, i) => {
7
+ let { as: a = "a", children: o, disabled: s = !1, className: c, onClick: l, radius: u = "normal", size: d = "medium", stretch: f = !1, variant: p = "button", weight: m = "bold", color: h = "link", ...g } = t, _ = p === "button" ? `ghost-button--${h}` : `ghost-button--hyperlink ghost-button--h-${h}`;
8
+ return r(a, {
9
+ ref: i,
10
+ className: e(n({
11
+ size: d,
12
+ radius: u,
13
+ weight: m,
14
+ stretch: f,
15
+ disabled: s
16
+ }), _, c),
17
+ disabled: s && !0,
18
+ onClick: !s && l ? l : void 0,
19
+ "data-clad": "Ghost Button",
20
+ ...g
21
+ }, o);
22
+ });
23
+ i.displayName = "GhostButton";
24
+ //#endregion
25
+ export { i as default };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../../types/index.cjs`),t=require(`./Button.cjs`);let n=require(`react/jsx-runtime`);var r=e.forwardRef((e,r)=>(0,n.jsx)(t.default,{icon:!0,ref:r,"data-clad":`Icon Button`,...e}));r.displayName=`IconButton`,exports.default=r;
@@ -0,0 +1,13 @@
1
+ import { forwardRef as e } from "../../types/index.es.js";
2
+ import t from "./Button.es.js";
3
+ import { jsx as n } from "react/jsx-runtime";
4
+ //#region src/components/Button/IconButton.tsx
5
+ var r = e((e, r) => /* @__PURE__ */ n(t, {
6
+ icon: !0,
7
+ ref: r,
8
+ "data-clad": "Icon Button",
9
+ ...e
10
+ }));
11
+ r.displayName = "IconButton";
12
+ //#endregion
13
+ export { r as default };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);let e=require(`tailwind-variants/lite`);var t=(0,e.tv)({base:`button`,defaultVariants:{size:`medium`,color:`primary`,variant:`solid`},variants:{color:{primary:`button--primary`,success:`button--success`,info:`button--info`,error:`button--error`,neutral:`button--neutral`,tertiary:`button--tertiary`,blank:`button--blank`},size:{small:`button--sm`,medium:`button--md`,large:`button--lg`,xlarge:`button--xl`,sm:`button--sm`,md:`button--md`,lg:`button--lg`,xl:`button--xl`},variant:{default:`button--default`,solid:`button--solid`,outline:`button--outline`,tonal:`button--tonal`},radius:{normal:``,pill:`button--pill`,circle:`button--circle`},weight:{normal:`button--weight-normal`,bold:`button--weight-bold`},stretch:{true:`button--stretch`,false:``},icon:{true:`button--icon`,false:``},iconPosition:{left:`button--i-left`,right:`button--i-right`},isLoading:{true:`button--loading`,false:``}}}),n=(0,e.tv)({base:`ghost-button`,defaultVariants:{size:`medium`,radius:`normal`,weight:`bold`},variants:{size:{small:`ghost-button--sm`,medium:`ghost-button--md`,large:`ghost-button--lg`,xlarge:`ghost-button--xl`,sm:`ghost-button--sm`,md:`ghost-button--md`,lg:`ghost-button--lg`,xl:`ghost-button--xl`},radius:{normal:`ghost-button--r-normal`,pill:`ghost-button--r-pill`,circle:`ghost-button--r-circle`},weight:{normal:`ghost-button--w-normal`,bold:`ghost-button--w-bold`},stretch:{true:`ghost-button--stretch`,false:``},disabled:{true:`ghost-button--disabled`,false:``}}});exports.buttonVariants=t,exports.ghostButtonVariants=n;
@@ -0,0 +1,100 @@
1
+ import { tv as e } from "tailwind-variants/lite";
2
+ //#region src/components/Button/button.styles.ts
3
+ var t = e({
4
+ base: "button",
5
+ defaultVariants: {
6
+ size: "medium",
7
+ color: "primary",
8
+ variant: "solid"
9
+ },
10
+ variants: {
11
+ color: {
12
+ primary: "button--primary",
13
+ success: "button--success",
14
+ info: "button--info",
15
+ error: "button--error",
16
+ neutral: "button--neutral",
17
+ tertiary: "button--tertiary",
18
+ blank: "button--blank"
19
+ },
20
+ size: {
21
+ small: "button--sm",
22
+ medium: "button--md",
23
+ large: "button--lg",
24
+ xlarge: "button--xl",
25
+ sm: "button--sm",
26
+ md: "button--md",
27
+ lg: "button--lg",
28
+ xl: "button--xl"
29
+ },
30
+ variant: {
31
+ default: "button--default",
32
+ solid: "button--solid",
33
+ outline: "button--outline",
34
+ tonal: "button--tonal"
35
+ },
36
+ radius: {
37
+ normal: "",
38
+ pill: "button--pill",
39
+ circle: "button--circle"
40
+ },
41
+ weight: {
42
+ normal: "button--weight-normal",
43
+ bold: "button--weight-bold"
44
+ },
45
+ stretch: {
46
+ true: "button--stretch",
47
+ false: ""
48
+ },
49
+ icon: {
50
+ true: "button--icon",
51
+ false: ""
52
+ },
53
+ iconPosition: {
54
+ left: "button--i-left",
55
+ right: "button--i-right"
56
+ },
57
+ isLoading: {
58
+ true: "button--loading",
59
+ false: ""
60
+ }
61
+ }
62
+ }), n = e({
63
+ base: "ghost-button",
64
+ defaultVariants: {
65
+ size: "medium",
66
+ radius: "normal",
67
+ weight: "bold"
68
+ },
69
+ variants: {
70
+ size: {
71
+ small: "ghost-button--sm",
72
+ medium: "ghost-button--md",
73
+ large: "ghost-button--lg",
74
+ xlarge: "ghost-button--xl",
75
+ sm: "ghost-button--sm",
76
+ md: "ghost-button--md",
77
+ lg: "ghost-button--lg",
78
+ xl: "ghost-button--xl"
79
+ },
80
+ radius: {
81
+ normal: "ghost-button--r-normal",
82
+ pill: "ghost-button--r-pill",
83
+ circle: "ghost-button--r-circle"
84
+ },
85
+ weight: {
86
+ normal: "ghost-button--w-normal",
87
+ bold: "ghost-button--w-bold"
88
+ },
89
+ stretch: {
90
+ true: "ghost-button--stretch",
91
+ false: ""
92
+ },
93
+ disabled: {
94
+ true: "ghost-button--disabled",
95
+ false: ""
96
+ }
97
+ }
98
+ });
99
+ //#endregion
100
+ export { t as buttonVariants, n as ghostButtonVariants };
@@ -0,0 +1 @@
1
+ "use client";require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../../utils/cn.cjs`),t=require(`../../types/index.cjs`),n=require(`./checkbox.styles.cjs`);let r=require(`react`),i=require(`@chotot/icons`);var a=()=>{},o=t.forwardRef((t,o)=>{let{id:s,name:c,value:l,checked:u=!1,indeterminate:d=!1,label:f,color:p=`primary`,disabled:m=!1,onChange:h=a,className:g,..._}=t,v=e.default(n.checkboxVariants({color:p}),d&&`checkbox--indeterminate`,m&&`checkbox--disabled`,f&&`checkbox--with-label`,g),y={id:s,name:c,value:l,checked:u,disabled:m,ref:e=>{e&&(e.indeterminate=d)},"aria-checked":d?`mixed`:u,type:`checkbox`,onChange:h},b=d?(0,r.createElement)(`svg`,{width:16,height:16,viewBox:`0 0 16 16`,fill:`currentColor`,"aria-hidden":!0},(0,r.createElement)(`rect`,{x:3,y:7,width:10,height:2,rx:1})):(0,r.createElement)(i.Check,{"aria-hidden":!0});return(0,r.createElement)(`label`,{ref:o,className:v,"data-clad":`Checkbox`,..._},(0,r.createElement)(`input`,y),(0,r.createElement)(`span`,{"aria-hidden":!0},b),f||null)});o.displayName=`Checkbox`,exports.default=o;
@@ -0,0 +1,43 @@
1
+ "use client";
2
+ import e from "../../utils/cn.es.js";
3
+ import { forwardRef as t } from "../../types/index.es.js";
4
+ import { checkboxVariants as n } from "./checkbox.styles.es.js";
5
+ import { createElement as r } from "react";
6
+ import { Check as i } from "@chotot/icons";
7
+ //#region src/components/Checkbox/Checkbox.tsx
8
+ var a = () => {}, o = t((t, o) => {
9
+ let { id: s, name: c, value: l, checked: u = !1, indeterminate: d = !1, label: f, color: p = "primary", disabled: m = !1, onChange: h = a, className: g, ..._ } = t, v = e(n({ color: p }), d && "checkbox--indeterminate", m && "checkbox--disabled", f && "checkbox--with-label", g), y = {
10
+ id: s,
11
+ name: c,
12
+ value: l,
13
+ checked: u,
14
+ disabled: m,
15
+ ref: (e) => {
16
+ e && (e.indeterminate = d);
17
+ },
18
+ "aria-checked": d ? "mixed" : u,
19
+ type: "checkbox",
20
+ onChange: h
21
+ }, b = d ? r("svg", {
22
+ width: 16,
23
+ height: 16,
24
+ viewBox: "0 0 16 16",
25
+ fill: "currentColor",
26
+ "aria-hidden": !0
27
+ }, r("rect", {
28
+ x: 3,
29
+ y: 7,
30
+ width: 10,
31
+ height: 2,
32
+ rx: 1
33
+ })) : r(i, { "aria-hidden": !0 });
34
+ return r("label", {
35
+ ref: o,
36
+ className: v,
37
+ "data-clad": "Checkbox",
38
+ ..._
39
+ }, r("input", y), r("span", { "aria-hidden": !0 }, b), f || null);
40
+ });
41
+ o.displayName = "Checkbox";
42
+ //#endregion
43
+ export { o as default };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);var e=(0,require(`tailwind-variants/lite`).tv)({base:`checkbox`,defaultVariants:{color:`primary`},variants:{color:{primary:`checkbox--primary`,info:`checkbox--info`,success:`checkbox--success`,error:`checkbox--error`,neutral:`checkbox--neutral`}}});exports.checkboxVariants=e;
@@ -0,0 +1,15 @@
1
+ import { tv as e } from "tailwind-variants/lite";
2
+ //#region src/components/Checkbox/checkbox.styles.ts
3
+ var t = e({
4
+ base: "checkbox",
5
+ defaultVariants: { color: "primary" },
6
+ variants: { color: {
7
+ primary: "checkbox--primary",
8
+ info: "checkbox--info",
9
+ success: "checkbox--success",
10
+ error: "checkbox--error",
11
+ neutral: "checkbox--neutral"
12
+ } }
13
+ });
14
+ //#endregion
15
+ export { t as checkboxVariants };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../../utils/cn.cjs`),t=require(`../../types/index.cjs`),n=require(`./chip.styles.cjs`);let r=require(`react`),i=require(`@chotot/icons`);var a=t.forwardRef((t,a)=>{let{variant:o=`fill`,size:s=`md`,active:c=!1,disabled:l=!1,dropdownIcon:u=!1,icon:d,onClose:f,value:p,children:m,className:h,as:g=`a`,onClick:_,...v}=t,y=typeof f==`function`&&!l&&!u?(0,r.createElement)(`button`,{className:`bg-transparent border-0 flex justify-center items-center w-6 h-6 p-0 m-0 cursor-pointer text-inherit`,type:`button`,onClick:e=>{e.stopPropagation(),f(p,e)}},(0,r.createElement)(i.Close,{"aria-hidden":!0})):null;return(0,r.createElement)(g,{ref:a,className:e.default(n.chipVariants({variant:o,size:s,active:c,disabled:l}),h),"aria-disabled":l||void 0,onClick:l?void 0:_,"data-clad":`Chip`,...v,...l?{href:void 0,tabIndex:-1}:{}},d??null,m,y,u?(0,r.createElement)(i.ChevronDown,{"aria-hidden":!0}):null)});a.displayName=`Chip`,exports.default=a;
@@ -0,0 +1,35 @@
1
+ import e from "../../utils/cn.es.js";
2
+ import { forwardRef as t } from "../../types/index.es.js";
3
+ import { chipVariants as n } from "./chip.styles.es.js";
4
+ import { createElement as r } from "react";
5
+ import { ChevronDown as i, Close as a } from "@chotot/icons";
6
+ //#region src/components/Chip/Chip.tsx
7
+ var o = t((t, o) => {
8
+ let { variant: s = "fill", size: c = "md", active: l = !1, disabled: u = !1, dropdownIcon: d = !1, icon: f, onClose: p, value: m, children: h, className: g, as: _ = "a", onClick: v, ...y } = t, b = typeof p == "function" && !u && !d ? r("button", {
9
+ className: "bg-transparent border-0 flex justify-center items-center w-6 h-6 p-0 m-0 cursor-pointer text-inherit",
10
+ type: "button",
11
+ onClick: (e) => {
12
+ e.stopPropagation(), p(m, e);
13
+ }
14
+ }, r(a, { "aria-hidden": !0 })) : null;
15
+ return r(_, {
16
+ ref: o,
17
+ className: e(n({
18
+ variant: s,
19
+ size: c,
20
+ active: l,
21
+ disabled: u
22
+ }), g),
23
+ "aria-disabled": u || void 0,
24
+ onClick: u ? void 0 : v,
25
+ "data-clad": "Chip",
26
+ ...y,
27
+ ...u ? {
28
+ href: void 0,
29
+ tabIndex: -1
30
+ } : {}
31
+ }, f ?? null, h, b, d ? r(i, { "aria-hidden": !0 }) : null);
32
+ });
33
+ o.displayName = "Chip";
34
+ //#endregion
35
+ export { o as default };
@@ -0,0 +1 @@
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);var e=(0,require(`tailwind-variants/lite`).tv)({base:`chip`,defaultVariants:{variant:`fill`,size:`md`},variants:{variant:{fill:`chip--normal`,normal:`chip--normal`,outline:`chip--outline`,ghost:`chip--ghost`},size:{sm:`chip--sm`,md:`chip--md`,lg:`chip--lg`,xl:`chip--xl`},active:{true:`chip--active`,false:``},disabled:{true:`chip--disabled`,false:``}}});exports.chipVariants=e;