asheeui 0.6.2 → 0.6.5

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 (281) hide show
  1. package/dist/AsheeUIProvider.d.ts +34 -0
  2. package/dist/AsheeUIProvider.d.ts.map +1 -1
  3. package/dist/components/accordion/Accordion.d.ts +55 -44
  4. package/dist/components/accordion/Accordion.d.ts.map +1 -1
  5. package/dist/components/accordion/Accordion.js +27 -27
  6. package/dist/components/accordion/accordion-config.d.ts +41 -12
  7. package/dist/components/accordion/accordion-config.d.ts.map +1 -1
  8. package/dist/components/accordion/accordion-styles.d.ts +20 -0
  9. package/dist/components/accordion/accordion-styles.d.ts.map +1 -1
  10. package/dist/components/accordion/accordion-styles.js +1 -1
  11. package/dist/components/autocomplete/Autocomplete.d.ts +59 -39
  12. package/dist/components/autocomplete/Autocomplete.d.ts.map +1 -1
  13. package/dist/components/autocomplete/Autocomplete.js +98 -91
  14. package/dist/components/autocomplete/autocomplete-config.d.ts +9 -62
  15. package/dist/components/autocomplete/autocomplete-config.d.ts.map +1 -1
  16. package/dist/components/autocomplete/autocomplete-config.js +6 -21
  17. package/dist/components/button/Button.d.ts +50 -51
  18. package/dist/components/button/Button.d.ts.map +1 -1
  19. package/dist/components/button/Button.js +19 -19
  20. package/dist/components/button/button-config.d.ts +23 -15
  21. package/dist/components/button/button-config.d.ts.map +1 -1
  22. package/dist/components/button/button-styles.d.ts +11 -1
  23. package/dist/components/button/button-styles.d.ts.map +1 -1
  24. package/dist/components/card/Card.d.ts +85 -43
  25. package/dist/components/card/Card.d.ts.map +1 -1
  26. package/dist/components/card/Card.js +49 -49
  27. package/dist/components/card/card-config.d.ts +35 -18
  28. package/dist/components/card/card-config.d.ts.map +1 -1
  29. package/dist/components/card/card-config.js +0 -2
  30. package/dist/components/card/card-styles.d.ts +17 -1
  31. package/dist/components/card/card-styles.d.ts.map +1 -1
  32. package/dist/components/carousel/Carousel.d.ts +107 -12
  33. package/dist/components/carousel/Carousel.d.ts.map +1 -1
  34. package/dist/components/carousel/Carousel.js +63 -64
  35. package/dist/components/carousel/carousel-config.d.ts +94 -7
  36. package/dist/components/carousel/carousel-config.d.ts.map +1 -1
  37. package/dist/components/carousel/carousel-config.js +6 -4
  38. package/dist/components/carousel/carousel-styles.d.ts +32 -1
  39. package/dist/components/carousel/carousel-styles.d.ts.map +1 -1
  40. package/dist/components/chip/Chip.d.ts +55 -34
  41. package/dist/components/chip/Chip.d.ts.map +1 -1
  42. package/dist/components/chip/Chip.js +71 -72
  43. package/dist/components/chip/chip-config.d.ts +29 -15
  44. package/dist/components/chip/chip-config.d.ts.map +1 -1
  45. package/dist/components/chip/chip-config.js +5 -6
  46. package/dist/components/chip/chip-styles.d.ts +21 -1
  47. package/dist/components/chip/chip-styles.d.ts.map +1 -1
  48. package/dist/components/date-picker/DatePicker.d.ts +166 -2
  49. package/dist/components/date-picker/DatePicker.d.ts.map +1 -1
  50. package/dist/components/date-picker/DatePicker.js +110 -99
  51. package/dist/components/date-picker/date-picker-config.d.ts +31 -0
  52. package/dist/components/date-picker/date-picker-config.d.ts.map +1 -1
  53. package/dist/components/date-picker/date-picker-config.js +8 -16
  54. package/dist/components/date-picker/date-picker-styles.d.ts +21 -1
  55. package/dist/components/date-picker/date-picker-styles.d.ts.map +1 -1
  56. package/dist/components/date-picker/date-picker-styles.js +7 -11
  57. package/dist/components/drawer/Drawer.d.ts +97 -7
  58. package/dist/components/drawer/Drawer.d.ts.map +1 -1
  59. package/dist/components/drawer/Drawer.js +9 -9
  60. package/dist/components/drawer/drawer-config.d.ts +54 -1
  61. package/dist/components/drawer/drawer-config.d.ts.map +1 -1
  62. package/dist/components/drawer/drawer-styles.d.ts +21 -0
  63. package/dist/components/drawer/drawer-styles.d.ts.map +1 -1
  64. package/dist/components/field/FieldShell.d.ts +86 -0
  65. package/dist/components/field/FieldShell.d.ts.map +1 -1
  66. package/dist/components/field/field-config.d.ts +66 -3
  67. package/dist/components/field/field-config.d.ts.map +1 -1
  68. package/dist/components/field/field-config.js +2 -1
  69. package/dist/components/field/field-styles.d.ts +22 -0
  70. package/dist/components/field/field-styles.d.ts.map +1 -1
  71. package/dist/components/field/field-styles.js +10 -0
  72. package/dist/components/field/index.js +1 -0
  73. package/dist/components/image/Image.d.ts +35 -28
  74. package/dist/components/image/Image.d.ts.map +1 -1
  75. package/dist/components/image/Image.js +7 -7
  76. package/dist/components/image/image-config.d.ts +25 -7
  77. package/dist/components/image/image-config.d.ts.map +1 -1
  78. package/dist/components/image/image-styles.d.ts +9 -0
  79. package/dist/components/image/image-styles.d.ts.map +1 -1
  80. package/dist/components/input/Input.d.ts +117 -10
  81. package/dist/components/input/Input.d.ts.map +1 -1
  82. package/dist/components/input/Input.js +20 -20
  83. package/dist/components/input/PasswordInput.d.ts +48 -0
  84. package/dist/components/input/PasswordInput.d.ts.map +1 -1
  85. package/dist/components/input/input-config.d.ts +10 -1
  86. package/dist/components/input/input-config.d.ts.map +1 -1
  87. package/dist/components/input/input-config.js +5 -8
  88. package/dist/components/input/input-styles.d.ts +10 -0
  89. package/dist/components/input/input-styles.d.ts.map +1 -1
  90. package/dist/components/input/input-styles.js +5 -9
  91. package/dist/components/keyboard/OnScreenKeyboard.d.ts +58 -8
  92. package/dist/components/keyboard/OnScreenKeyboard.d.ts.map +1 -1
  93. package/dist/components/keyboard/OnScreenKeyboard.js +49 -48
  94. package/dist/components/keyboard/index.js +1 -1
  95. package/dist/components/keyboard/keyboard-config.d.ts +88 -3
  96. package/dist/components/keyboard/keyboard-config.d.ts.map +1 -1
  97. package/dist/components/keyboard/{default-keyboard-config.js → keyboard-config.js} +7 -1
  98. package/dist/components/keyboard/keyboard-context.d.ts +103 -13
  99. package/dist/components/keyboard/keyboard-context.d.ts.map +1 -1
  100. package/dist/components/keyboard/keyboard-context.js +66 -68
  101. package/dist/components/keyboard/use-keyboard-field.d.ts +37 -0
  102. package/dist/components/keyboard/use-keyboard-field.d.ts.map +1 -1
  103. package/dist/components/link/Link.d.ts +118 -9
  104. package/dist/components/link/Link.d.ts.map +1 -1
  105. package/dist/components/link/Link.js +29 -30
  106. package/dist/components/link/link-config.d.ts +58 -5
  107. package/dist/components/link/link-config.d.ts.map +1 -1
  108. package/dist/components/link/link-styles.d.ts +24 -4
  109. package/dist/components/link/link-styles.d.ts.map +1 -1
  110. package/dist/components/marquee/Marquee.d.ts +77 -8
  111. package/dist/components/marquee/Marquee.d.ts.map +1 -1
  112. package/dist/components/marquee/Marquee.js +5 -5
  113. package/dist/components/marquee/marquee-config.d.ts +74 -0
  114. package/dist/components/marquee/marquee-config.d.ts.map +1 -1
  115. package/dist/components/marquee/marquee-styles.d.ts +12 -0
  116. package/dist/components/marquee/marquee-styles.d.ts.map +1 -1
  117. package/dist/components/modal/Modal.d.ts +113 -25
  118. package/dist/components/modal/Modal.d.ts.map +1 -1
  119. package/dist/components/modal/Modal.js +75 -82
  120. package/dist/components/modal/modal-config.d.ts +59 -1
  121. package/dist/components/modal/modal-config.d.ts.map +1 -1
  122. package/dist/components/modal/modal-styles.d.ts +8 -1
  123. package/dist/components/modal/modal-styles.d.ts.map +1 -1
  124. package/dist/components/modal/modal-styles.js +4 -11
  125. package/dist/components/multi-select/MultiSelect.d.ts +152 -23
  126. package/dist/components/multi-select/MultiSelect.d.ts.map +1 -1
  127. package/dist/components/multi-select/MultiSelect.js +195 -217
  128. package/dist/components/multi-select/multi-select-config.d.ts +61 -23
  129. package/dist/components/multi-select/multi-select-config.d.ts.map +1 -1
  130. package/dist/components/multi-select/multi-select-config.js +16 -25
  131. package/dist/components/multi-select/multi-select-styles.d.ts +17 -0
  132. package/dist/components/multi-select/multi-select-styles.d.ts.map +1 -1
  133. package/dist/components/multi-select/multi-select-styles.js +9 -13
  134. package/dist/components/radio/Radio.d.ts +137 -13
  135. package/dist/components/radio/Radio.d.ts.map +1 -1
  136. package/dist/components/radio/Radio.js +66 -141
  137. package/dist/components/radio/RadioGroup.d.ts +88 -23
  138. package/dist/components/radio/RadioGroup.d.ts.map +1 -1
  139. package/dist/components/radio/RadioGroup.js +141 -66
  140. package/dist/components/radio/radio-config.d.ts +36 -11
  141. package/dist/components/radio/radio-config.d.ts.map +1 -1
  142. package/dist/components/radio/radio-config.js +9 -11
  143. package/dist/components/radio/radio-context.d.ts +44 -1
  144. package/dist/components/radio/radio-context.d.ts.map +1 -1
  145. package/dist/components/radio/radio-styles.d.ts +24 -1
  146. package/dist/components/radio/radio-styles.d.ts.map +1 -1
  147. package/dist/components/resizable-screen/ResizableScreen.d.ts +79 -32
  148. package/dist/components/resizable-screen/ResizableScreen.d.ts.map +1 -1
  149. package/dist/components/resizable-screen/ResizableScreen.js +77 -72
  150. package/dist/components/resizable-screen/resizable-screen-config.d.ts +62 -0
  151. package/dist/components/resizable-screen/resizable-screen-config.d.ts.map +1 -1
  152. package/dist/components/scrollbar/scrollbar-config.d.ts +44 -9
  153. package/dist/components/scrollbar/scrollbar-config.d.ts.map +1 -1
  154. package/dist/components/select/Select.d.ts +157 -17
  155. package/dist/components/select/Select.d.ts.map +1 -1
  156. package/dist/components/select/Select.js +141 -152
  157. package/dist/components/select/select-config.d.ts +26 -19
  158. package/dist/components/select/select-config.d.ts.map +1 -1
  159. package/dist/components/select/select-config.js +5 -21
  160. package/dist/components/select/select-styles.d.ts +10 -0
  161. package/dist/components/select/select-styles.d.ts.map +1 -1
  162. package/dist/components/select/select-styles.js +5 -9
  163. package/dist/components/select-menu/SelectMenu.d.ts +125 -8
  164. package/dist/components/select-menu/SelectMenu.d.ts.map +1 -1
  165. package/dist/components/select-menu/SelectMenu.js +107 -79
  166. package/dist/components/select-menu/index.d.ts +2 -0
  167. package/dist/components/select-menu/index.d.ts.map +1 -1
  168. package/dist/components/select-menu/index.js +1 -0
  169. package/dist/components/select-menu/select-menu-config.d.ts +82 -0
  170. package/dist/components/select-menu/select-menu-config.d.ts.map +1 -0
  171. package/dist/components/select-menu/select-menu-config.js +12 -0
  172. package/dist/components/sidebar/Sidebar.d.ts +151 -51
  173. package/dist/components/sidebar/Sidebar.d.ts.map +1 -1
  174. package/dist/components/sidebar/Sidebar.js +211 -232
  175. package/dist/components/sidebar/sidebar-config.d.ts +140 -21
  176. package/dist/components/sidebar/sidebar-config.d.ts.map +1 -1
  177. package/dist/components/sidebar/sidebar-config.js +9 -12
  178. package/dist/components/sidebar/sidebar-styles.d.ts +24 -0
  179. package/dist/components/sidebar/sidebar-styles.d.ts.map +1 -1
  180. package/dist/components/spinner/spinner-config.d.ts +15 -9
  181. package/dist/components/spinner/spinner-config.d.ts.map +1 -1
  182. package/dist/components/spinner/spinner-styles.d.ts +10 -3
  183. package/dist/components/spinner/spinner-styles.d.ts.map +1 -1
  184. package/dist/components/spinner/spinner.d.ts +27 -20
  185. package/dist/components/spinner/spinner.d.ts.map +1 -1
  186. package/dist/components/spinner/spinner.js +18 -18
  187. package/dist/components/switch/Switch.d.ts +109 -9
  188. package/dist/components/switch/Switch.d.ts.map +1 -1
  189. package/dist/components/switch/Switch.js +19 -19
  190. package/dist/components/switch/switch-config.d.ts +20 -6
  191. package/dist/components/switch/switch-config.d.ts.map +1 -1
  192. package/dist/components/switch/switch-config.js +8 -16
  193. package/dist/components/switch/switch-styles.d.ts +17 -0
  194. package/dist/components/switch/switch-styles.d.ts.map +1 -1
  195. package/dist/components/table/Table.d.ts +101 -28
  196. package/dist/components/table/Table.d.ts.map +1 -1
  197. package/dist/components/table/Table.js +56 -56
  198. package/dist/components/table/table-config.d.ts +75 -8
  199. package/dist/components/table/table-config.d.ts.map +1 -1
  200. package/dist/components/table/table-styles.d.ts +25 -6
  201. package/dist/components/table/table-styles.d.ts.map +1 -1
  202. package/dist/components/tabs/Tabs.d.ts +84 -31
  203. package/dist/components/tabs/Tabs.d.ts.map +1 -1
  204. package/dist/components/tabs/Tabs.js +44 -44
  205. package/dist/components/tabs/tabs-config.d.ts +102 -9
  206. package/dist/components/tabs/tabs-config.d.ts.map +1 -1
  207. package/dist/components/tabs/tabs-styles.d.ts +16 -4
  208. package/dist/components/tabs/tabs-styles.d.ts.map +1 -1
  209. package/dist/components/textarea/Textarea.d.ts +105 -11
  210. package/dist/components/textarea/Textarea.d.ts.map +1 -1
  211. package/dist/components/textarea/Textarea.js +27 -24
  212. package/dist/components/textarea/textarea-config.d.ts +21 -0
  213. package/dist/components/textarea/textarea-config.d.ts.map +1 -1
  214. package/dist/components/textarea/textarea-config.js +8 -16
  215. package/dist/components/textarea/textarea-styles.d.ts +9 -0
  216. package/dist/components/textarea/textarea-styles.d.ts.map +1 -1
  217. package/dist/components/textarea/textarea-styles.js +5 -9
  218. package/dist/components/toast/ToastItem.d.ts +58 -4
  219. package/dist/components/toast/ToastItem.d.ts.map +1 -1
  220. package/dist/components/toast/ToastItem.js +18 -18
  221. package/dist/components/toast/toast-config.d.ts +104 -6
  222. package/dist/components/toast/toast-config.d.ts.map +1 -1
  223. package/dist/components/toast/toast-context.d.ts +123 -11
  224. package/dist/components/toast/toast-context.d.ts.map +1 -1
  225. package/dist/components/toast/toast-context.js +19 -19
  226. package/dist/components/toast/toast-styles.d.ts +27 -5
  227. package/dist/components/toast/toast-styles.d.ts.map +1 -1
  228. package/dist/components/toast/use-pausable-timeout.d.ts +29 -0
  229. package/dist/components/toast/use-pausable-timeout.d.ts.map +1 -1
  230. package/dist/components/tooltip/Tooltip.d.ts +76 -16
  231. package/dist/components/tooltip/Tooltip.d.ts.map +1 -1
  232. package/dist/components/tooltip/Tooltip.js +25 -25
  233. package/dist/components/tooltip/tooltip-config.d.ts +73 -3
  234. package/dist/components/tooltip/tooltip-config.d.ts.map +1 -1
  235. package/dist/components/tooltip/tooltip-styles.d.ts +12 -0
  236. package/dist/components/tooltip/tooltip-styles.d.ts.map +1 -1
  237. package/dist/config/config.d.ts +50 -2
  238. package/dist/config/config.d.ts.map +1 -1
  239. package/dist/config/default-config.d.ts +5 -0
  240. package/dist/config/default-config.d.ts.map +1 -1
  241. package/dist/config/default-config.js +23 -0
  242. package/dist/config/define-config.d.ts +23 -0
  243. package/dist/config/define-config.d.ts.map +1 -1
  244. package/dist/config/resolve-color.d.ts +25 -0
  245. package/dist/config/resolve-color.d.ts.map +1 -1
  246. package/dist/config/resolve-config.d.ts +23 -0
  247. package/dist/config/resolve-config.d.ts.map +1 -1
  248. package/dist/index.css +43 -7
  249. package/dist/index.d.ts +30 -2
  250. package/dist/index.d.ts.map +1 -1
  251. package/dist/index.js +120 -115
  252. package/dist/libs/context.d.ts +50 -1
  253. package/dist/libs/context.d.ts.map +1 -1
  254. package/dist/libs/registry.d.ts +61 -5
  255. package/dist/libs/registry.d.ts.map +1 -1
  256. package/dist/libs/use-isomorphic-layout-effect.d.ts +18 -0
  257. package/dist/libs/use-isomorphic-layout-effect.d.ts.map +1 -1
  258. package/dist/shared/index.d.ts +3 -0
  259. package/dist/shared/index.d.ts.map +1 -0
  260. package/dist/shared/radius.d.ts +37 -1
  261. package/dist/shared/radius.d.ts.map +1 -1
  262. package/dist/shared/variant.d.ts +31 -0
  263. package/dist/shared/variant.d.ts.map +1 -1
  264. package/dist/shared/variant.js +132 -45
  265. package/dist/theme/color.d.ts +89 -1
  266. package/dist/theme/color.d.ts.map +1 -1
  267. package/dist/theme/controller.d.ts +121 -0
  268. package/dist/theme/controller.d.ts.map +1 -1
  269. package/dist/theme/controller.js +84 -0
  270. package/dist/theme/useTheme.d.ts +68 -0
  271. package/dist/theme/useTheme.d.ts.map +1 -1
  272. package/dist/theme/useTheme.js +23 -0
  273. package/dist/utils/index.d.ts +0 -7
  274. package/dist/utils/index.d.ts.map +1 -1
  275. package/dist/utils/resolve-token.d.ts +101 -0
  276. package/dist/utils/resolve-token.d.ts.map +1 -1
  277. package/package.json +1 -1
  278. package/dist/components/keyboard/default-keyboard-config.d.ts +0 -10
  279. package/dist/components/keyboard/default-keyboard-config.d.ts.map +0 -1
  280. package/dist/shared/size.d.ts +0 -2
  281. package/dist/shared/size.d.ts.map +0 -1
@@ -1,10 +1,4 @@
1
- import { Radius } from '../../shared/radius';
2
- import { Size } from '../../shared/size';
3
- import { Color, Variant } from '../../shared/variant';
4
- /** Padding and font-size scale of the button. */
5
- export type ButtonSizeKey = Size;
6
- /** Corner rounding scale of the button. */
7
- export type ButtonRadiusKey = Radius;
1
+ import { Color, Radius, Size, Variant } from '../../shared';
8
2
  /**
9
3
  * Theme configuration options for the Button component.
10
4
  *
@@ -12,32 +6,44 @@ export type ButtonRadiusKey = Radius;
12
6
  * component-level fallback tier of the theme cascade.
13
7
  */
14
8
  export interface ButtonConfig {
15
- /** Visual style variant.
9
+ /**
10
+ * Visual style variant.
11
+ * Controls the background, border, and hover treatment.
16
12
  *
17
13
  * @default "bordered"
18
14
  */
19
15
  variant?: Variant;
20
- /** Theme accent color.
16
+ /**
17
+ * Theme accent color.
18
+ * Controls the color of the button's primary visual elements.
21
19
  *
22
20
  * @default "primary"
23
21
  */
24
22
  color?: Color;
25
- /** Padding and font-size scale.
23
+ /**
24
+ * Padding and font-size scale.
25
+ * Controls the density and text size of the button.
26
26
  *
27
27
  * @default "md"
28
28
  */
29
- size?: ButtonSizeKey;
30
- /** Corner rounding.
29
+ size?: Size;
30
+ /**
31
+ * Corner rounding.
32
+ * Controls the border-radius of the button.
31
33
  *
32
34
  * @default "md"
33
35
  */
34
- radius?: ButtonRadiusKey;
35
- /** Enables the press-down scale animation.
36
+ radius?: Radius;
37
+ /**
38
+ * Enables the press-down scale animation.
39
+ * When true, the button scales down slightly on click.
36
40
  *
37
41
  * @default true
38
42
  */
39
43
  animate?: boolean;
40
- /** Makes the button stretch to fill its parent width.
44
+ /**
45
+ * Makes the button stretch to fill its parent width.
46
+ * When true, the button expands to 100% of its container width.
41
47
  *
42
48
  * @default false
43
49
  */
@@ -58,6 +64,8 @@ declare module "../../libs/registry" {
58
64
  }
59
65
  /**
60
66
  * Hard fallback values used when no config tier provides a value.
67
+ * These values are used when instance props, component config,
68
+ * and global defaults are all undefined.
61
69
  */
62
70
  export declare const FALLBACK_BUTTON_CONFIG: Required<ButtonConfig>;
63
71
  //# sourceMappingURL=button-config.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"button-config.d.ts","sourceRoot":"","sources":["../../../src/components/button/button-config.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAE3D,iDAAiD;AACjD,MAAM,MAAM,aAAa,GAAG,IAAI,CAAC;AAEjC,2CAA2C;AAC3C,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC;AAErC;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC;IACd;;;OAGG;IACH,IAAI,CAAC,EAAE,aAAa,CAAC;IACrB;;;OAGG;IACH,MAAM,CAAC,EAAE,eAAe,CAAC;IACzB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,EAAE,YAIjC,CAAC;AAEF,OAAO,QAAQ,qBAAqB,CAAC;IACnC,UAAU,2BAA2B;QACnC,MAAM,EAAE,YAAY,CAAC;KACtB;CACF;AAID;;GAEG;AACH,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAAC,YAAY,CAOhD,CAAC"}
1
+ {"version":3,"file":"button-config.d.ts","sourceRoot":"","sources":["../../../src/components/button/button-config.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEjE;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC3B;;;;;OAKG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;;;OAKG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC;IAEd;;;;;OAKG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;IAEZ;;;;;OAKG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;;OAKG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;;;OAKG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,EAAE,YAIjC,CAAC;AAEF,OAAO,QAAQ,qBAAqB,CAAC;IACnC,UAAU,2BAA2B;QACnC,MAAM,EAAE,YAAY,CAAC;KACtB;CACF;AAID;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAAC,YAAY,CAOhD,CAAC"}
@@ -1,4 +1,14 @@
1
- import { Size } from '../../shared/size';
1
+ import { Size } from '../../shared';
2
+ /**
3
+ * CSS classes for standard button sizes.
4
+ * Maps size keys to Tailwind classes that control padding, height,
5
+ * font size, and spacing between elements.
6
+ */
2
7
  export declare const BUTTON_SIZE_CLASS: Record<Size, string>;
8
+ /**
9
+ * CSS classes for icon-only button sizes.
10
+ * Maps size keys to Tailwind classes that create square buttons
11
+ * with consistent dimensions for icons.
12
+ */
3
13
  export declare const BUTTON_ICON_SIZE_CLASS: Record<Size, string>;
4
14
  //# sourceMappingURL=button-styles.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"button-styles.d.ts","sourceRoot":"","sources":["../../../src/components/button/button-styles.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAE9C,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIlD,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIvD,CAAC"}
1
+ {"version":3,"file":"button-styles.d.ts","sourceRoot":"","sources":["../../../src/components/button/button-styles.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEzC;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIlD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,EAAE,MAAM,CAAC,IAAI,EAAE,MAAM,CAIvD,CAAC"}
@@ -1,88 +1,108 @@
1
1
  import { ElementType, HTMLAttributes, ReactNode } from 'react';
2
- import { Radius } from '../../shared/radius';
3
- import { Size } from '../../shared/size';
4
2
  import { ImageFit, ImageRatioKey } from '../image/image-config';
5
- import { CardImageLoading, CardImagePosition, CardVariant } from './card-config';
3
+ import { CardConfig, CardImageLoading, CardImagePosition } from './card-config';
4
+ type BaseCardProps = CardConfig & Omit<HTMLAttributes<HTMLDivElement>, "title" | "children">;
6
5
  /**
7
6
  * Configuration options for the Card component.
8
7
  */
9
- export interface CardProps extends Omit<HTMLAttributes<HTMLDivElement>, "title" | "children"> {
10
- /** Visual style variant.
11
- *
12
- * @default "bordered"
13
- */
14
- variant?: CardVariant;
15
- /** Padding and spacing scale for inner content.
16
- *
17
- * @default "md"
18
- */
19
- size?: Size;
20
- /** Corner rounding applied to the card border.
21
- *
22
- * @default "md"
23
- */
24
- radius?: Radius;
25
- /** Enables the press-down scale animation when clickable.
26
- *
27
- * @default true
28
- */
29
- animate?: boolean;
30
- /** Enables interactive hover effects and keyboard accessibility.
8
+ export interface CardProps extends BaseCardProps {
9
+ /**
10
+ * Whether the card is clickable.
11
+ * When true, the card becomes interactive with hover and focus states.
12
+ * This is automatically enabled when href or onClick is provided.
31
13
  *
32
14
  * @default false
33
15
  */
34
16
  isClickable?: boolean;
35
- /** Disables interactive states and dims card opacity.
17
+ /**
18
+ * Disables interactive states and dims card opacity.
19
+ * Disabled cards cannot be clicked or focused.
36
20
  *
37
21
  * @default false
38
22
  */
39
23
  isDisabled?: boolean;
40
- /** Renders the card as a link when provided with `isClickable`. */
24
+ /**
25
+ * Renders the card as a link when provided with `isClickable`.
26
+ * Clicking the card navigates to this URL.
27
+ */
41
28
  href?: string;
42
- /** Heading content rendered above the body. */
29
+ /**
30
+ * Heading content rendered above the body.
31
+ * Typically a string or React element.
32
+ */
43
33
  title?: ReactNode;
44
- /** Supporting text rendered under the title. */
34
+ /**
35
+ * Supporting text rendered under the title.
36
+ * Typically a string providing additional context.
37
+ */
45
38
  description?: ReactNode;
46
- /** Custom header node rendered above the title. */
39
+ /**
40
+ * Custom header node rendered above the title.
41
+ * Useful for adding icons, badges, or metadata.
42
+ */
47
43
  header?: ReactNode;
48
- /** Explicit body content; falls back to `children`. */
44
+ /**
45
+ * Explicit body content; falls back to `children`.
46
+ * Use this when you need to explicitly set the body content.
47
+ */
49
48
  body?: ReactNode;
50
- /** Footer node rendered at the bottom of the content column. */
49
+ /**
50
+ * Footer node rendered at the bottom of the content column.
51
+ * Typically used for actions or additional metadata.
52
+ */
51
53
  footer?: ReactNode;
52
- /** Source URL of the card image. */
54
+ /**
55
+ * Source URL of the card image.
56
+ * When provided, displays an image in the card.
57
+ */
53
58
  imageSrc?: string;
54
- /** Alternative text for the card image.
59
+ /**
60
+ * Alternative text for the card image.
61
+ * Important for accessibility.
55
62
  *
56
63
  * @default ""
57
64
  */
58
65
  imageAlt?: string;
59
- /** Placement of the image relative to the content.
66
+ /**
67
+ * Placement of the image relative to the content.
68
+ * Determines whether the image appears at the top, bottom, or as a background.
60
69
  *
61
70
  * @default "top"
62
71
  */
63
72
  imagePosition?: CardImagePosition;
64
- /** Aspect ratio of the positioned image.
73
+ /**
74
+ * Aspect ratio of the positioned image.
75
+ * Controls the proportional dimensions of the image container.
65
76
  *
66
77
  * @default "video"
67
78
  */
68
79
  imageRatio?: ImageRatioKey;
69
- /** Object-fit strategy of the positioned image.
80
+ /**
81
+ * Object-fit strategy of the positioned image.
82
+ * Controls how the image fills its container.
70
83
  *
71
84
  * @default "cover"
72
85
  */
73
86
  imageFit?: ImageFit;
74
- /** Native loading strategy of the positioned image.
87
+ /**
88
+ * Native loading strategy of the positioned image.
75
89
  *
76
90
  * @default "lazy"
77
91
  */
78
92
  imageLoading?: CardImageLoading;
79
- /** Custom image component to render the card image with instead of
80
- * the native `<img>` tag (e.g. `next/image`). */
93
+ /**
94
+ * Custom image component to render the card image with instead of
95
+ * the native `<img>` tag (e.g. `next/image`).
96
+ */
81
97
  imageComponent?: ElementType;
82
- /** Additional props forwarded to `imageComponent`
83
- * (e.g. `{ priority: true, sizes: "..." }`). */
98
+ /**
99
+ * Additional props forwarded to `imageComponent`
100
+ * (e.g. `{ priority: true, sizes: "..." }`).
101
+ */
84
102
  imageProps?: Record<string, unknown>;
85
- /** Card body content, used when `body` is not provided. */
103
+ /**
104
+ * Card body content, used when `body` is not provided.
105
+ */
86
106
  children?: ReactNode;
87
107
  }
88
108
  /**
@@ -95,6 +115,10 @@ export interface CardProps extends Omit<HTMLAttributes<HTMLDivElement>, "title"
95
115
  * cascade. When `isClickable` is enabled, the card becomes keyboard
96
116
  * accessible and adopts link or button semantics based on `href`.
97
117
  *
118
+ * The component automatically handles accessibility attributes including
119
+ * role, tabIndex, aria-disabled, and proper keyboard interaction with
120
+ * Enter and Space keys.
121
+ *
98
122
  * @param props - Card configuration options and HTML div element props.
99
123
  * @param props.variant - Visual style variant. Defaults to "bordered".
100
124
  * @param props.size - Content density scale. Defaults to "md".
@@ -117,6 +141,7 @@ export interface CardProps extends Omit<HTMLAttributes<HTMLDivElement>, "title"
117
141
  * @param props.imageComponent - Custom image component.
118
142
  * @param props.imageProps - Props forwarded to the image component.
119
143
  * @param props.children - Card body content.
144
+ * @param props.className - Extra CSS classes for the card.
120
145
  *
121
146
  * @example
122
147
  * ```tsx
@@ -136,6 +161,23 @@ export interface CardProps extends Omit<HTMLAttributes<HTMLDivElement>, "title"
136
161
  * );
137
162
  * }
138
163
  * ```
164
+ *
165
+ * @example
166
+ * ```tsx
167
+ * // Clickable card with image
168
+ * <Card
169
+ * isClickable
170
+ * href="/blog/post-1"
171
+ * imageSrc="/images/post-1.jpg"
172
+ * imageAlt="Blog post cover"
173
+ * title="Blog Post Title"
174
+ * description="A brief description of the blog post."
175
+ * />
176
+ * ```
177
+ *
178
+ * @see CardConfig - The configuration type for component defaults.
179
+ * @see useAsheeConfig - Hook for accessing the global configuration.
139
180
  */
140
181
  export declare const Card: import('react').ForwardRefExoticComponent<CardProps & import('react').RefAttributes<HTMLDivElement>>;
182
+ export {};
141
183
  //# sourceMappingURL=Card.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Card.d.ts","sourceRoot":"","sources":["../../../src/components/card/Card.tsx"],"names":[],"mappings":"AAEA,OAAO,EACL,KAAK,WAAW,EAEhB,KAAK,cAAc,EAGnB,KAAK,SAAS,EAEf,MAAM,OAAO,CAAC;AAEf,OAAO,EAAgB,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAS9C,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACrE,OAAO,EAEL,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAEjB,MAAM,eAAe,CAAC;AAQvB;;GAEG;AACH,MAAM,WAAW,SACf,SAAQ,IAAI,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,OAAO,GAAG,UAAU,CAAC;IAClE;;;OAGG;IACH,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB;;;OAGG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;;OAGG;IACH,UAAU,CAAC,EAAE,O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
@@ -1,27 +1,27 @@
1
1
  "use client";
2
- import { jsxs as b, jsx as l } from "react/jsx-runtime";
2
+ import { jsxs as I, jsx as s } from "react/jsx-runtime";
3
3
  import { forwardRef as ie, useId as de } from "react";
4
4
  import { useAsheeConfig as ce } from "../../libs/context.js";
5
- import { RADIUS_CLASS as ue } from "../../shared/radius.js";
6
- import { resolveCascade as v, resolveRadiusKey as fe, resolveAnimate as me, resolveClassKey as y } from "../../utils/resolve-token.js";
7
- import { Image as ve } from "../image/Image.js";
5
+ import { resolveCascade as v, resolveRadiusKey as ue, resolveAnimate as fe, resolveClassKey as y } from "../../utils/resolve-token.js";
6
+ import { Image as me } from "../image/Image.js";
8
7
  import { FALLBACK_CARD_CONFIG as a } from "./card-config.js";
9
- import { CARD_PADDING_CLASS as ye, CARD_GAP_CLASS as he, CARD_HEADER_GAP_CLASS as xe, CARD_VARIANT_CLASS as G } from "./card-styles.js";
8
+ import { CARD_PADDING_CLASS as ve, CARD_GAP_CLASS as ye, CARD_HEADER_GAP_CLASS as he, CARD_VARIANT_CLASS as G } from "./card-styles.js";
9
+ import { RADIUS_CLASS as xe } from "../../shared/radius.js";
10
10
  import { cn as h } from "../../utils/cn.js";
11
- const Ae = ie(
11
+ const ge = ie(
12
12
  ({
13
13
  variant: j,
14
- size: B,
15
- radius: D,
16
- animate: E,
17
- isClickable: K,
14
+ size: K,
15
+ radius: B,
16
+ animate: D,
17
+ isClickable: E,
18
18
  isDisabled: o = !1,
19
19
  href: d,
20
20
  title: x,
21
- description: A,
22
- header: I,
21
+ description: g,
22
+ header: N,
23
23
  body: V,
24
- footer: N,
24
+ footer: b,
25
25
  imageSrc: c,
26
26
  imageAlt: w = "",
27
27
  imagePosition: F,
@@ -35,12 +35,12 @@ const Ae = ie(
35
35
  onClick: f,
36
36
  id: q,
37
37
  style: J,
38
- onKeyDown: g,
38
+ onKeyDown: A,
39
39
  ...M
40
40
  }, Q) => {
41
41
  var k;
42
42
  const z = ce(), e = (k = z.components) == null ? void 0 : k.card, W = de(), X = q ?? W, p = v(
43
- B,
43
+ K,
44
44
  e == null ? void 0 : e.size,
45
45
  void 0,
46
46
  a.size
@@ -49,8 +49,8 @@ const Ae = ie(
49
49
  e == null ? void 0 : e.variant,
50
50
  z.defaultVariant,
51
51
  a.variant
52
- ), Z = fe(
53
- D,
52
+ ), Z = ue(
53
+ B,
54
54
  e == null ? void 0 : e.radius,
55
55
  z.defaultRadius,
56
56
  a.radius
@@ -59,25 +59,25 @@ const Ae = ie(
59
59
  e == null ? void 0 : e.imagePosition,
60
60
  void 0,
61
61
  a.imagePosition
62
- ), i = K ?? !!(d || f) ?? (e == null ? void 0 : e.isClickable) ?? a.isClickable, P = me(
63
- E,
62
+ ), i = E ?? !!(d || f), P = fe(
63
+ D,
64
64
  e == null ? void 0 : e.animate,
65
65
  a.animate
66
66
  ), ee = y(
67
67
  p,
68
- ye,
68
+ ve,
69
69
  a.size
70
70
  ), L = y(
71
71
  p,
72
- he,
72
+ ye,
73
73
  a.size
74
74
  ), re = y(
75
75
  p,
76
- xe,
76
+ he,
77
77
  a.size
78
78
  ), te = y(
79
79
  Z,
80
- ue,
80
+ xe,
81
81
  a.radius
82
82
  ), ae = v(
83
83
  O,
@@ -91,18 +91,18 @@ const Ae = ie(
91
91
  }
92
92
  f == null || f(t), d && !t.defaultPrevented && (window.location.href = d);
93
93
  }, ne = (t) => {
94
- g == null || g(t), i && !o && (t.key === "Enter" || t.key === " ") && (t.preventDefault(), R(t));
94
+ A == null || A(t), i && !o && (t.key === "Enter" || t.key === " ") && (t.preventDefault(), R(t));
95
95
  }, _ = (t) => {
96
96
  if (!c || C !== t) return null;
97
- const s = {
97
+ const l = {
98
98
  top: "w-full shrink-0 rounded-b-none",
99
99
  bottom: "w-full shrink-0 order-last rounded-t-none",
100
100
  background: ""
101
101
  }[t];
102
102
  let n = { ...r ?? {} };
103
103
  if (u) {
104
- const m = (r == null ? void 0 : r.loading) === "lazy", se = (r == null ? void 0 : r.priority) === !0;
105
- (m || se) && console.warn(
104
+ const m = (r == null ? void 0 : r.loading) === "lazy", le = (r == null ? void 0 : r.priority) === !0;
105
+ (m || le) && console.warn(
106
106
  `[Card] ${m ? '`loading="lazy"`' : "`priority={true}`"} with custom image component may cause rendering issues. Consider using \`loading="eager"\` and removing \`priority\` for card images.`
107
107
  ), n = {
108
108
  ...n,
@@ -111,44 +111,44 @@ const Ae = ie(
111
111
  ...n.priority !== void 0 && { priority: !1 }
112
112
  };
113
113
  }
114
- return /* @__PURE__ */ l(
115
- ve,
114
+ return /* @__PURE__ */ s(
115
+ me,
116
116
  {
117
117
  src: c,
118
118
  alt: w,
119
119
  ratio: $ ?? "video",
120
120
  fit: H ?? "cover",
121
- className: s,
121
+ className: l,
122
122
  imageComponent: u,
123
123
  imageProps: n,
124
124
  loading: ae
125
125
  }
126
126
  );
127
- }, le = () => {
127
+ }, se = () => {
128
128
  if (!c || C !== "background") return null;
129
129
  const t = u || "img";
130
- let s = { ...r ?? {} };
130
+ let l = { ...r ?? {} };
131
131
  if (u) {
132
132
  const n = (r == null ? void 0 : r.loading) === "lazy", m = (r == null ? void 0 : r.priority) === !0;
133
133
  (n || m) && console.warn(
134
134
  `[Card] ${n ? '`loading="lazy"`' : "`priority={true}`"} with custom image component may cause rendering issues. Consider using \`loading="eager"\` and removing \`priority\` for card images.`
135
- ), s = {
136
- ...s,
135
+ ), l = {
136
+ ...l,
137
137
  loading: "eager",
138
- ...s.priority !== void 0 && { priority: !1 }
138
+ ...l.priority !== void 0 && { priority: !1 }
139
139
  };
140
140
  }
141
- return /* @__PURE__ */ l("div", { className: "absolute inset-0 z-0 pointer-events-none", children: /* @__PURE__ */ l(
141
+ return /* @__PURE__ */ s("div", { className: "absolute inset-0 z-0 pointer-events-none", children: /* @__PURE__ */ s(
142
142
  t,
143
143
  {
144
144
  src: c,
145
145
  alt: w,
146
146
  className: "h-full w-full object-cover",
147
- ...s
147
+ ...l
148
148
  }
149
149
  ) });
150
150
  }, S = V ?? U;
151
- return /* @__PURE__ */ b(
151
+ return /* @__PURE__ */ I(
152
152
  "div",
153
153
  {
154
154
  ref: Q,
@@ -171,8 +171,8 @@ const Ae = ie(
171
171
  ...M,
172
172
  children: [
173
173
  _("top"),
174
- le(),
175
- /* @__PURE__ */ b(
174
+ se(),
175
+ /* @__PURE__ */ I(
176
176
  "div",
177
177
  {
178
178
  className: h(
@@ -181,20 +181,20 @@ const Ae = ie(
181
181
  L
182
182
  ),
183
183
  children: [
184
- (I || x || A) && /* @__PURE__ */ b("div", { className: h("flex flex-col z-10", re), children: [
185
- I,
186
- x && /* @__PURE__ */ l("h3", { className: "font-semibold leading-tight tracking-tight text-foreground text-lg md:text-xl", children: x }),
187
- A && /* @__PURE__ */ l("p", { className: "text-sm text-muted-foreground leading-relaxed", children: A })
184
+ (N || x || g) && /* @__PURE__ */ I("div", { className: h("flex flex-col z-10", re), children: [
185
+ N,
186
+ x && /* @__PURE__ */ s("h3", { className: "font-semibold leading-tight tracking-tight text-foreground text-lg md:text-xl", children: x }),
187
+ g && /* @__PURE__ */ s("p", { className: "text-sm text-muted-foreground leading-relaxed", children: g })
188
188
  ] }),
189
- S && /* @__PURE__ */ l("div", { className: "flex-1 z-10 text-sm leading-relaxed", children: S }),
190
- N && /* @__PURE__ */ l(
189
+ S && /* @__PURE__ */ s("div", { className: "flex-1 z-10 text-sm leading-relaxed", children: S }),
190
+ b && /* @__PURE__ */ s(
191
191
  "div",
192
192
  {
193
193
  className: h(
194
194
  "flex items-center justify-between z-10 mt-auto pt-2",
195
195
  L
196
196
  ),
197
- children: N
197
+ children: b
198
198
  }
199
199
  )
200
200
  ]
@@ -206,7 +206,7 @@ const Ae = ie(
206
206
  );
207
207
  }
208
208
  );
209
- Ae.displayName = "Card";
209
+ ge.displayName = "Card";
210
210
  export {
211
- Ae as Card
211
+ ge as Card
212
212
  };
@@ -1,5 +1,4 @@
1
- import { Radius } from '../../shared/radius';
2
- import { Size } from '../../shared/size';
1
+ import { Radius, Size } from '../../shared';
3
2
  import { ImageFit, ImageRatioKey } from '../image/image-config';
4
3
  /**
5
4
  * Visual style of the card.
@@ -10,9 +9,16 @@ import { ImageFit, ImageRatioKey } from '../image/image-config';
10
9
  * - `ghost`: Transparent background without a border.
11
10
  */
12
11
  export type CardVariant = "elevated" | "bordered" | "flat" | "ghost";
13
- /** Placement of the card image relative to the content. */
12
+ /**
13
+ * Placement of the card image relative to the content.
14
+ * "top" and "bottom" place the image above or below the content.
15
+ * "background" places the image as a full-bleed background layer.
16
+ */
14
17
  export type CardImagePosition = "top" | "bottom" | "background";
15
- /** Native image loading strategy. */
18
+ /**
19
+ * Native image loading strategy.
20
+ * Controls when the browser loads the image resource.
21
+ */
16
22
  export type CardImageLoading = "lazy" | "eager";
17
23
  /**
18
24
  * Theme configuration options for the Card component.
@@ -21,47 +27,57 @@ export type CardImageLoading = "lazy" | "eager";
21
27
  * component-level fallback tier of the theme cascade.
22
28
  */
23
29
  export interface CardConfig {
24
- /** Visual style variant.
30
+ /**
31
+ * Visual style variant.
32
+ * Controls the card's background, border, and shadow treatment.
25
33
  *
26
34
  * @default "bordered"
27
35
  */
28
36
  variant?: CardVariant;
29
- /** Content padding and spacing scale.
37
+ /**
38
+ * Content padding and spacing scale.
39
+ * Controls the density of the card's internal spacing.
30
40
  *
31
41
  * @default "md"
32
42
  */
33
43
  size?: Size;
34
- /** Corner rounding.
44
+ /**
45
+ * Corner rounding.
46
+ * Controls the border-radius of the card.
35
47
  *
36
48
  * @default "md"
37
49
  */
38
50
  radius?: Radius;
39
- /** Placement of the card image.
51
+ /**
52
+ * Placement of the card image.
53
+ * Determines where the image appears relative to the content.
40
54
  *
41
55
  * @default "top"
42
56
  */
43
57
  imagePosition?: CardImagePosition;
44
- /** Aspect ratio of the positioned image.
58
+ /**
59
+ * Aspect ratio of the positioned image.
60
+ * Controls the proportional dimensions of the image container.
45
61
  *
46
62
  * @default "video"
47
63
  */
48
64
  imageRatio?: ImageRatioKey;
49
- /** Object-fit strategy of the positioned image.
65
+ /**
66
+ * Object-fit strategy of the positioned image.
67
+ * Controls how the image fills its container.
50
68
  *
51
69
  * @default "cover"
52
70
  */
53
71
  imageFit?: ImageFit;
54
- /** Native loading strategy of the positioned image.
72
+ /**
73
+ * Native loading strategy of the positioned image.
55
74
  *
56
75
  * @default "lazy"
57
76
  */
58
77
  imageLoading?: CardImageLoading;
59
- /** Enables interactive hover and keyboard behaviour.
60
- *
61
- * @default false
62
- */
63
- isClickable?: boolean;
64
- /** Enables the press animation when clickable.
78
+ /**
79
+ * Enables the press animation when clickable.
80
+ * When true, the card scales down slightly on click.
65
81
  *
66
82
  * @default true
67
83
  */
@@ -81,6 +97,8 @@ declare module "../../libs/registry" {
81
97
  }
82
98
  /**
83
99
  * Hard fallback values used when no config tier provides a value.
100
+ * These values are used when instance props, component config,
101
+ * and global defaults are all undefined.
84
102
  */
85
103
  export declare const FALLBACK_CARD_CONFIG: {
86
104
  readonly size: "md";
@@ -90,7 +108,6 @@ export declare const FALLBACK_CARD_CONFIG: {
90
108
  readonly imageRatio: "video";
91
109
  readonly imageFit: "cover";
92
110
  readonly imageLoading: "lazy";
93
- readonly isClickable: false;
94
111
  readonly animate: true;
95
112
  };
96
113
  //# sourceMappingURL=card-config.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"card-config.d.ts","sourceRoot":"","sources":["../../../src/components/card/card-config.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAErE;;;;;;;GAOG;AACH,MAAM,MAAM,WAAW,GAAG,UAAU,GAAG,UAAU,GAAG,MAAM,GAAG,OAAO,CAAC;AAErE,2DAA2D;AAC3D,MAAM,MAAM,iBAAiB,GAAG,KAAK,GAAG,QAAQ,GAAG,YAAY,CAAC;AAEhE,qCAAqC;AACrC,MAAM,MAAM,gBAAgB,GAAG,MAAM,GAAG,OAAO,CAAC;AAEhD;;;;;GAKG;AACH,MAAM,WAAW,UAAU;IACzB;;;OAGG;IACH,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB;;;OAGG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,aAAa,CAAC,EAAE,iBAAiB,CAAC;IAClC;;;OAGG;IACH,UAAU,CAAC,EAAE,aAAa,CAAC;IAC3B;;;OAGG;IACH,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB;;;OAGG;IACH,YAAY,CAAC,EAAE,gBAAgB,CAAC;IAChC;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,EAAE,UAO/B,CAAC;AAEF,OAAO,QAAQ,qBAAqB,CAAC;IACnC,UAAU,2BAA2B;QACnC,IAAI,EAAE,UAAU,CAAC;KAClB;CACF;AAID;;GAEG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;CAUvB,CAAC"}
1
+ {"version":3,"file":"card-config.d.ts","sourceRoot":"","sources":["../../../src/components/card/card-config.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAErE;;;;;;;GAOG;AACH,MAAM,MAAM,WAAW,GAAG,UAAU,GAAG,UAAU,GAAG,MAAM,GAAG,OAAO,CAAC;AAErE;;;;GAIG;AACH,MAAM,MAAM,iBAAiB,GAAG,KAAK,GAAG,QAAQ,GAAG,YAAY,CAAC;AAEhE;;;GAGG;AACH,MAAM,MAAM,gBAAg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