@kjun-ui/react 0.21.0 → 0.22.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 (287) hide show
  1. package/README.md +19 -5
  2. package/dist/index.cjs +8405 -3740
  3. package/dist/index.js +8199 -3512
  4. package/dist/styles.css +2610 -454
  5. package/dist/types/packages/react/src/actions.d.cts +21 -16
  6. package/dist/types/packages/react/src/actions.d.ts +21 -16
  7. package/dist/types/packages/react/src/app-navigation.d.cts +6 -2
  8. package/dist/types/packages/react/src/app-navigation.d.ts +6 -2
  9. package/dist/types/packages/react/src/avatar-group.d.cts +36 -0
  10. package/dist/types/packages/react/src/avatar-group.d.ts +36 -0
  11. package/dist/types/packages/react/src/button.d.cts +14 -6
  12. package/dist/types/packages/react/src/button.d.ts +14 -6
  13. package/dist/types/packages/react/src/calendar.d.cts +6 -2
  14. package/dist/types/packages/react/src/calendar.d.ts +6 -2
  15. package/dist/types/packages/react/src/card.d.cts +10 -3
  16. package/dist/types/packages/react/src/card.d.ts +10 -3
  17. package/dist/types/packages/react/src/carousel.d.cts +8 -1
  18. package/dist/types/packages/react/src/carousel.d.ts +8 -1
  19. package/dist/types/packages/react/src/choice-controls.d.cts +99 -0
  20. package/dist/types/packages/react/src/choice-controls.d.ts +99 -0
  21. package/dist/types/packages/react/src/collapse.d.cts +4 -1
  22. package/dist/types/packages/react/src/collapse.d.ts +4 -1
  23. package/dist/types/packages/react/src/color-picker.d.cts +8 -1
  24. package/dist/types/packages/react/src/color-picker.d.ts +8 -1
  25. package/dist/types/packages/react/src/combobox.d.cts +18 -5
  26. package/dist/types/packages/react/src/combobox.d.ts +18 -5
  27. package/dist/types/packages/react/src/controls.d.cts +7 -74
  28. package/dist/types/packages/react/src/controls.d.ts +7 -74
  29. package/dist/types/packages/react/src/data-state.d.cts +19 -6
  30. package/dist/types/packages/react/src/data-state.d.ts +19 -6
  31. package/dist/types/packages/react/src/date-picker.d.cts +8 -2
  32. package/dist/types/packages/react/src/date-picker.d.ts +8 -2
  33. package/dist/types/packages/react/src/display.d.cts +26 -6
  34. package/dist/types/packages/react/src/display.d.ts +26 -6
  35. package/dist/types/packages/react/src/drawer.d.cts +11 -2
  36. package/dist/types/packages/react/src/drawer.d.ts +11 -2
  37. package/dist/types/packages/react/src/dropdown.d.cts +19 -5
  38. package/dist/types/packages/react/src/dropdown.d.ts +19 -5
  39. package/dist/types/packages/react/src/event-calendar.d.cts +47 -0
  40. package/dist/types/packages/react/src/event-calendar.d.ts +47 -0
  41. package/dist/types/packages/react/src/fab.d.cts +2 -0
  42. package/dist/types/packages/react/src/fab.d.ts +2 -0
  43. package/dist/types/packages/react/src/file-upload-row.d.cts +23 -0
  44. package/dist/types/packages/react/src/file-upload-row.d.ts +23 -0
  45. package/dist/types/packages/react/src/file-upload.d.cts +38 -0
  46. package/dist/types/packages/react/src/file-upload.d.ts +38 -0
  47. package/dist/types/packages/react/src/financial-display.d.cts +32 -11
  48. package/dist/types/packages/react/src/financial-display.d.ts +32 -11
  49. package/dist/types/packages/react/src/floating-panel.d.cts +6 -2
  50. package/dist/types/packages/react/src/floating-panel.d.ts +6 -2
  51. package/dist/types/packages/react/src/index.d.cts +12 -1
  52. package/dist/types/packages/react/src/index.d.ts +12 -1
  53. package/dist/types/packages/react/src/input.d.cts +14 -1
  54. package/dist/types/packages/react/src/input.d.ts +14 -1
  55. package/dist/types/packages/react/src/kpi-hero.d.cts +2 -0
  56. package/dist/types/packages/react/src/kpi-hero.d.ts +2 -0
  57. package/dist/types/packages/react/src/kpi-row.d.cts +5 -0
  58. package/dist/types/packages/react/src/kpi-row.d.ts +5 -0
  59. package/dist/types/packages/react/src/layout-primitives.d.cts +71 -139
  60. package/dist/types/packages/react/src/layout-primitives.d.ts +71 -139
  61. package/dist/types/packages/react/src/list-context.d.cts +2 -1
  62. package/dist/types/packages/react/src/list-context.d.ts +2 -1
  63. package/dist/types/packages/react/src/list.d.cts +39 -8
  64. package/dist/types/packages/react/src/list.d.ts +39 -8
  65. package/dist/types/packages/react/src/market-model.d.cts +13 -1
  66. package/dist/types/packages/react/src/market-model.d.ts +13 -1
  67. package/dist/types/packages/react/src/market-parts.d.cts +9 -0
  68. package/dist/types/packages/react/src/market-parts.d.ts +9 -0
  69. package/dist/types/packages/react/src/market-skeleton.d.cts +7 -1
  70. package/dist/types/packages/react/src/market-skeleton.d.ts +7 -1
  71. package/dist/types/packages/react/src/media.d.cts +6 -2
  72. package/dist/types/packages/react/src/media.d.ts +6 -2
  73. package/dist/types/packages/react/src/modal.d.cts +11 -2
  74. package/dist/types/packages/react/src/modal.d.ts +11 -2
  75. package/dist/types/packages/react/src/navigation.d.cts +34 -5
  76. package/dist/types/packages/react/src/navigation.d.ts +34 -5
  77. package/dist/types/packages/react/src/number-display.d.cts +8 -5
  78. package/dist/types/packages/react/src/number-display.d.ts +8 -5
  79. package/dist/types/packages/react/src/number-input.d.cts +28 -0
  80. package/dist/types/packages/react/src/number-input.d.ts +28 -0
  81. package/dist/types/packages/react/src/popover.d.cts +5 -2
  82. package/dist/types/packages/react/src/popover.d.ts +5 -2
  83. package/dist/types/packages/react/src/pressable.d.cts +17 -0
  84. package/dist/types/packages/react/src/pressable.d.ts +17 -0
  85. package/dist/types/packages/react/src/quantity-stepper.d.cts +3 -1
  86. package/dist/types/packages/react/src/quantity-stepper.d.ts +3 -1
  87. package/dist/types/packages/react/src/range-input.d.cts +15 -3
  88. package/dist/types/packages/react/src/range-input.d.ts +15 -3
  89. package/dist/types/packages/react/src/search-input.d.cts +6 -3
  90. package/dist/types/packages/react/src/search-input.d.ts +6 -3
  91. package/dist/types/packages/react/src/select-control.d.cts +7 -2
  92. package/dist/types/packages/react/src/select-control.d.ts +7 -2
  93. package/dist/types/packages/react/src/side-navigation-layout.d.cts +47 -0
  94. package/dist/types/packages/react/src/side-navigation-layout.d.ts +47 -0
  95. package/dist/types/packages/react/src/side-navigation.d.cts +74 -0
  96. package/dist/types/packages/react/src/side-navigation.d.ts +74 -0
  97. package/dist/types/packages/react/src/skeletons.d.cts +18 -3
  98. package/dist/types/packages/react/src/skeletons.d.ts +18 -3
  99. package/dist/types/packages/react/src/spinner-glyph.d.cts +8 -0
  100. package/dist/types/packages/react/src/spinner-glyph.d.ts +8 -0
  101. package/dist/types/packages/react/src/split-pane.d.cts +18 -5
  102. package/dist/types/packages/react/src/split-pane.d.ts +18 -5
  103. package/dist/types/packages/react/src/stacked-bar.d.cts +3 -1
  104. package/dist/types/packages/react/src/stacked-bar.d.ts +3 -1
  105. package/dist/types/packages/react/src/steps.d.cts +26 -0
  106. package/dist/types/packages/react/src/steps.d.ts +26 -0
  107. package/dist/types/packages/react/src/table-cards.d.cts +4 -12
  108. package/dist/types/packages/react/src/table-cards.d.ts +4 -12
  109. package/dist/types/packages/react/src/table-grid.d.cts +3 -7
  110. package/dist/types/packages/react/src/table-grid.d.ts +3 -7
  111. package/dist/types/packages/react/src/table-groups.d.cts +5 -0
  112. package/dist/types/packages/react/src/table-groups.d.ts +5 -0
  113. package/dist/types/packages/react/src/table-list.d.cts +2 -9
  114. package/dist/types/packages/react/src/table-list.d.ts +2 -9
  115. package/dist/types/packages/react/src/table-model.d.cts +6 -2
  116. package/dist/types/packages/react/src/table-model.d.ts +6 -2
  117. package/dist/types/packages/react/src/tabs.d.cts +3 -1
  118. package/dist/types/packages/react/src/tabs.d.ts +3 -1
  119. package/dist/types/packages/react/src/textarea.d.cts +6 -3
  120. package/dist/types/packages/react/src/textarea.d.ts +6 -3
  121. package/dist/types/packages/react/src/tiles.d.cts +18 -0
  122. package/dist/types/packages/react/src/tiles.d.ts +18 -0
  123. package/dist/types/packages/react/src/time-picker.d.cts +12 -2
  124. package/dist/types/packages/react/src/time-picker.d.ts +12 -2
  125. package/dist/types/packages/react/src/time-wheel.d.cts +18 -0
  126. package/dist/types/packages/react/src/time-wheel.d.ts +18 -0
  127. package/dist/types/packages/react/src/use-filter-scroll.d.cts +5 -0
  128. package/dist/types/packages/react/src/use-filter-scroll.d.ts +5 -0
  129. package/dist/types/shared/package-runtime/accordion-state.d.cts +2 -0
  130. package/dist/types/shared/package-runtime/accordion-state.d.ts +2 -0
  131. package/dist/types/shared/package-runtime/action-size.d.cts +4 -0
  132. package/dist/types/shared/package-runtime/action-size.d.ts +4 -0
  133. package/dist/types/shared/package-runtime/alert-actions.d.cts +7 -0
  134. package/dist/types/shared/package-runtime/alert-actions.d.ts +7 -0
  135. package/dist/types/shared/package-runtime/alert-exit.d.cts +6 -0
  136. package/dist/types/shared/package-runtime/alert-exit.d.ts +6 -0
  137. package/dist/types/shared/package-runtime/alert-live.d.cts +2 -0
  138. package/dist/types/shared/package-runtime/alert-live.d.ts +2 -0
  139. package/dist/types/shared/package-runtime/avatar-group.d.cts +18 -0
  140. package/dist/types/shared/package-runtime/avatar-group.d.ts +18 -0
  141. package/dist/types/shared/package-runtime/badge-tone.d.cts +8 -2
  142. package/dist/types/shared/package-runtime/badge-tone.d.ts +8 -2
  143. package/dist/types/shared/package-runtime/bottom-bar.d.cts +1 -1
  144. package/dist/types/shared/package-runtime/bottom-bar.d.ts +1 -1
  145. package/dist/types/shared/package-runtime/bottom-navigation.d.cts +5 -0
  146. package/dist/types/shared/package-runtime/bottom-navigation.d.ts +5 -0
  147. package/dist/types/shared/package-runtime/calendar.d.cts +21 -7
  148. package/dist/types/shared/package-runtime/calendar.d.ts +21 -7
  149. package/dist/types/shared/package-runtime/card-layout.d.cts +8 -0
  150. package/dist/types/shared/package-runtime/card-layout.d.ts +8 -0
  151. package/dist/types/shared/package-runtime/carousel-scroll.d.cts +2 -0
  152. package/dist/types/shared/package-runtime/carousel-scroll.d.ts +2 -0
  153. package/dist/types/shared/package-runtime/carousel.d.cts +12 -2
  154. package/dist/types/shared/package-runtime/carousel.d.ts +12 -2
  155. package/dist/types/shared/package-runtime/chart-skeleton.d.cts +1 -1
  156. package/dist/types/shared/package-runtime/chart-skeleton.d.ts +1 -1
  157. package/dist/types/shared/package-runtime/clipboard.d.cts +6 -0
  158. package/dist/types/shared/package-runtime/clipboard.d.ts +6 -0
  159. package/dist/types/shared/package-runtime/combobox-options.d.cts +13 -0
  160. package/dist/types/shared/package-runtime/combobox-options.d.ts +13 -0
  161. package/dist/types/shared/package-runtime/combobox.d.cts +3 -1
  162. package/dist/types/shared/package-runtime/combobox.d.ts +3 -1
  163. package/dist/types/shared/package-runtime/copy-button.d.cts +11 -0
  164. package/dist/types/shared/package-runtime/copy-button.d.ts +11 -0
  165. package/dist/types/shared/package-runtime/data-cells.d.cts +36 -0
  166. package/dist/types/shared/package-runtime/data-cells.d.ts +36 -0
  167. package/dist/types/shared/package-runtime/development.d.cts +4 -0
  168. package/dist/types/shared/package-runtime/development.d.ts +4 -0
  169. package/dist/types/shared/package-runtime/distribution.d.cts +36 -1
  170. package/dist/types/shared/package-runtime/distribution.d.ts +36 -1
  171. package/dist/types/shared/package-runtime/drawer-geometry.d.cts +7 -0
  172. package/dist/types/shared/package-runtime/drawer-geometry.d.ts +7 -0
  173. package/dist/types/shared/package-runtime/event-calendar.d.cts +81 -0
  174. package/dist/types/shared/package-runtime/event-calendar.d.ts +81 -0
  175. package/dist/types/shared/package-runtime/external-link.d.cts +4 -0
  176. package/dist/types/shared/package-runtime/external-link.d.ts +4 -0
  177. package/dist/types/shared/package-runtime/file-upload.d.cts +128 -0
  178. package/dist/types/shared/package-runtime/file-upload.d.ts +128 -0
  179. package/dist/types/shared/package-runtime/filter-scroll.d.cts +5 -0
  180. package/dist/types/shared/package-runtime/filter-scroll.d.ts +5 -0
  181. package/dist/types/shared/package-runtime/filter-value.d.cts +2 -0
  182. package/dist/types/shared/package-runtime/filter-value.d.ts +2 -0
  183. package/dist/types/shared/package-runtime/input-field.d.cts +23 -0
  184. package/dist/types/shared/package-runtime/input-field.d.ts +23 -0
  185. package/dist/types/shared/package-runtime/input-variant.d.cts +7 -0
  186. package/dist/types/shared/package-runtime/input-variant.d.ts +7 -0
  187. package/dist/types/shared/package-runtime/kpi.d.cts +13 -0
  188. package/dist/types/shared/package-runtime/kpi.d.ts +13 -0
  189. package/dist/types/shared/package-runtime/layout-primitives.d.cts +115 -6
  190. package/dist/types/shared/package-runtime/layout-primitives.d.ts +115 -6
  191. package/dist/types/shared/package-runtime/list-row.d.cts +43 -6
  192. package/dist/types/shared/package-runtime/list-row.d.ts +43 -6
  193. package/dist/types/shared/package-runtime/market-layout.d.cts +3 -1
  194. package/dist/types/shared/package-runtime/market-layout.d.ts +3 -1
  195. package/dist/types/shared/package-runtime/market-query.d.cts +6 -0
  196. package/dist/types/shared/package-runtime/market-query.d.ts +6 -0
  197. package/dist/types/shared/package-runtime/market-table.d.cts +32 -0
  198. package/dist/types/shared/package-runtime/market-table.d.ts +32 -0
  199. package/dist/types/shared/package-runtime/menu-button.d.cts +4 -0
  200. package/dist/types/shared/package-runtime/menu-button.d.ts +4 -0
  201. package/dist/types/shared/package-runtime/messages/ko.d.cts +74 -1
  202. package/dist/types/shared/package-runtime/messages/ko.d.ts +74 -1
  203. package/dist/types/shared/package-runtime/messages-context.d.cts +66 -1
  204. package/dist/types/shared/package-runtime/messages-context.d.ts +66 -1
  205. package/dist/types/shared/package-runtime/minimum-loading.d.cts +3 -0
  206. package/dist/types/shared/package-runtime/minimum-loading.d.ts +3 -0
  207. package/dist/types/shared/package-runtime/modal-geometry.d.cts +15 -0
  208. package/dist/types/shared/package-runtime/modal-geometry.d.ts +15 -0
  209. package/dist/types/shared/package-runtime/navigation.d.cts +9 -2
  210. package/dist/types/shared/package-runtime/navigation.d.ts +9 -2
  211. package/dist/types/shared/package-runtime/nested-controls.d.cts +7 -0
  212. package/dist/types/shared/package-runtime/nested-controls.d.ts +7 -0
  213. package/dist/types/shared/package-runtime/number-input.d.cts +63 -0
  214. package/dist/types/shared/package-runtime/number-input.d.ts +63 -0
  215. package/dist/types/shared/package-runtime/options.d.cts +25 -5
  216. package/dist/types/shared/package-runtime/options.d.ts +25 -5
  217. package/dist/types/shared/package-runtime/pagination.d.cts +12 -0
  218. package/dist/types/shared/package-runtime/pagination.d.ts +12 -0
  219. package/dist/types/shared/package-runtime/press-repeat.d.cts +13 -0
  220. package/dist/types/shared/package-runtime/press-repeat.d.ts +13 -0
  221. package/dist/types/shared/package-runtime/progress-circle.d.cts +5 -0
  222. package/dist/types/shared/package-runtime/progress-circle.d.ts +5 -0
  223. package/dist/types/shared/package-runtime/progress-marker.d.cts +7 -0
  224. package/dist/types/shared/package-runtime/progress-marker.d.ts +7 -0
  225. package/dist/types/shared/package-runtime/select-trigger.d.cts +23 -0
  226. package/dist/types/shared/package-runtime/select-trigger.d.ts +23 -0
  227. package/dist/types/shared/package-runtime/sheet-drag.d.cts +24 -0
  228. package/dist/types/shared/package-runtime/sheet-drag.d.ts +24 -0
  229. package/dist/types/shared/package-runtime/side-navigation-keys.d.cts +23 -0
  230. package/dist/types/shared/package-runtime/side-navigation-keys.d.ts +23 -0
  231. package/dist/types/shared/package-runtime/side-navigation-scroll.d.cts +7 -0
  232. package/dist/types/shared/package-runtime/side-navigation-scroll.d.ts +7 -0
  233. package/dist/types/shared/package-runtime/side-navigation.d.cts +277 -0
  234. package/dist/types/shared/package-runtime/side-navigation.d.ts +277 -0
  235. package/dist/types/shared/package-runtime/signed-number.d.cts +33 -0
  236. package/dist/types/shared/package-runtime/signed-number.d.ts +33 -0
  237. package/dist/types/shared/package-runtime/skeleton-text.d.cts +4 -0
  238. package/dist/types/shared/package-runtime/skeleton-text.d.ts +4 -0
  239. package/dist/types/shared/package-runtime/slider-view.d.cts +17 -2
  240. package/dist/types/shared/package-runtime/slider-view.d.ts +17 -2
  241. package/dist/types/shared/package-runtime/sparkline.d.cts +8 -4
  242. package/dist/types/shared/package-runtime/sparkline.d.ts +8 -4
  243. package/dist/types/shared/package-runtime/spinner-geometry.d.cts +14 -0
  244. package/dist/types/shared/package-runtime/spinner-geometry.d.ts +14 -0
  245. package/dist/types/shared/package-runtime/split-pane.d.cts +40 -1
  246. package/dist/types/shared/package-runtime/split-pane.d.ts +40 -1
  247. package/dist/types/shared/package-runtime/steps.d.cts +37 -0
  248. package/dist/types/shared/package-runtime/steps.d.ts +37 -0
  249. package/dist/types/shared/package-runtime/tab-keyboard.d.cts +6 -0
  250. package/dist/types/shared/package-runtime/tab-keyboard.d.ts +6 -0
  251. package/dist/types/shared/package-runtime/table-columns.d.cts +8 -0
  252. package/dist/types/shared/package-runtime/table-columns.d.ts +8 -0
  253. package/dist/types/shared/package-runtime/table-model.d.cts +23 -3
  254. package/dist/types/shared/package-runtime/table-model.d.ts +23 -3
  255. package/dist/types/shared/package-runtime/table-presentation.d.cts +11 -2
  256. package/dist/types/shared/package-runtime/table-presentation.d.ts +11 -2
  257. package/dist/types/shared/package-runtime/table.d.cts +15 -2
  258. package/dist/types/shared/package-runtime/table.d.ts +15 -2
  259. package/dist/types/shared/package-runtime/textarea.d.cts +6 -4
  260. package/dist/types/shared/package-runtime/textarea.d.ts +6 -4
  261. package/dist/types/shared/package-runtime/tiles-children.d.cts +7 -0
  262. package/dist/types/shared/package-runtime/tiles-children.d.ts +7 -0
  263. package/dist/types/shared/package-runtime/tiles.d.cts +18 -0
  264. package/dist/types/shared/package-runtime/tiles.d.ts +18 -0
  265. package/dist/types/shared/package-runtime/time-segments.d.cts +24 -0
  266. package/dist/types/shared/package-runtime/time-segments.d.ts +24 -0
  267. package/dist/types/shared/package-runtime/time-wheel.d.cts +54 -0
  268. package/dist/types/shared/package-runtime/time-wheel.d.ts +54 -0
  269. package/dist/types/shared/package-runtime/trailing-overflow.d.cts +1 -0
  270. package/dist/types/shared/package-runtime/trailing-overflow.d.ts +1 -0
  271. package/dist/types/shared/package-runtime/use-color-picker.d.cts +3 -0
  272. package/dist/types/shared/package-runtime/use-color-picker.d.ts +3 -0
  273. package/dist/types/shared/package-runtime/use-copy-feedback.d.cts +10 -0
  274. package/dist/types/shared/package-runtime/use-copy-feedback.d.ts +10 -0
  275. package/dist/types/shared/package-runtime/use-open-state.d.cts +5 -0
  276. package/dist/types/shared/package-runtime/use-open-state.d.ts +5 -0
  277. package/dist/types/shared/package-runtime/use-pending-action.d.cts +6 -0
  278. package/dist/types/shared/package-runtime/use-pending-action.d.ts +6 -0
  279. package/dist/types/shared/package-runtime/use-side-navigation-state.d.cts +25 -0
  280. package/dist/types/shared/package-runtime/use-side-navigation-state.d.ts +25 -0
  281. package/dist/types/shared/package-runtime/use-slide.d.cts +3 -0
  282. package/dist/types/shared/package-runtime/use-slide.d.ts +3 -0
  283. package/package.json +3 -3
  284. package/dist/types/packages/react/src/compound-control.d.cts +0 -1
  285. package/dist/types/packages/react/src/compound-control.d.ts +0 -1
  286. package/dist/types/shared/package-runtime/center-option.d.cts +0 -1
  287. package/dist/types/shared/package-runtime/center-option.d.ts +0 -1
@@ -1,6 +1,6 @@
1
- import { type AriaAttributes, type CSSProperties, type ReactNode } from "react";
2
- import { type InlineAlign, type InlineGap, type InlineJustify, type StackAlign, type StackGap, type TextAlign, type TextTag, type TextTone, type TextVariant } from "../../../shared/package-runtime/layout-primitives.cjs";
3
- export type { InlineAlign, InlineGap, InlineJustify, StackAlign, StackGap, TextAlign, TextTag, TextTone, TextVariant };
1
+ import { type AriaAttributes, type AriaRole, type ComponentPropsWithRef, type CSSProperties, type ReactElement, type ReactNode, type Ref } from "react";
2
+ import { type DirectionValue, type FlexDirection, type InlineAlign, type InlineAlignValue, type InlineGap, type InlineGapValue, type InlineJustify, type InlineRowGap, type InlineRowGapValue, type InsetStep, type JustifyValue, type LegacyStackGap, type PaddingValue, type Responsive, type ResponsiveBasis, type StackAlign, type StackAlignValue, type StackBreakpoint, type StackDivider, type StackGap, type StackGapValue, type StackJustify, type StackTag, type TextAlign, type TextDecoration, type TextTag, type TextTone, type TextVariant } from "../../../shared/package-runtime/layout-primitives.cjs";
3
+ export type { DirectionValue, FlexDirection, InlineAlign, InlineAlignValue, InlineGap, InlineGapValue, InlineJustify, InlineRowGap, InlineRowGapValue, InsetStep, JustifyValue, LegacyStackGap, PaddingValue, Responsive, ResponsiveBasis, StackAlign, StackAlignValue, StackBreakpoint, StackDivider, StackGap, StackGapValue, StackJustify, StackTag, TextAlign, TextDecoration, TextTag, TextTone, TextVariant };
4
4
  interface RootAttributes extends AriaAttributes {
5
5
  id?: string;
6
6
  }
@@ -14,153 +14,85 @@ export interface KjunTextProps extends RootAttributes {
14
14
  align?: TextAlign;
15
15
  /** Clamp to this many lines with an ellipsis; the full text stays in the DOM. */
16
16
  maxLines?: number;
17
+ /** With maxLines, a "더보기" button under the text opens the rest and turns into "접기". It shows only while the text
18
+ * overflows (or is open). The text and the button sit in a wrapper div; the text element keeps the other props. */
19
+ expandable?: boolean;
20
+ /** Whether the expandable text is open; leave it out to let the text keep it. */
21
+ expanded?: boolean;
22
+ onExpandedChange?: (expanded: boolean) => void;
23
+ /** Fixed-width digits, so amounts in a column line up. Size and weight stay the variant's. */
24
+ numeric?: boolean;
25
+ /** "lineThrough" strikes the text, e.g. a price before a discount. */
26
+ decoration?: TextDecoration;
27
+ /** Browser tooltip, e.g. the full sentence of a clamped text. */
28
+ title?: string;
29
+ lang?: string;
30
+ dir?: "ltr" | "rtl" | "auto";
31
+ /** The element, e.g. to move focus to a heading after the screen changes (with tabIndex={-1}). */
32
+ ref?: Ref<HTMLElement>;
33
+ /** -1 lets code focus the text without adding it to the Tab order. */
34
+ tabIndex?: number;
35
+ /** An ARIA role for the element, such as "status" for a message that should be announced. */
36
+ role?: AriaRole;
17
37
  className?: string;
18
38
  style?: CSSProperties;
19
39
  children?: ReactNode;
20
40
  }
21
- export declare function KjunText({ variant, tone, as, align, maxLines, className, style, children, ...rest }: KjunTextProps): import("react").DetailedReactHTMLElement<{
22
- className: string;
23
- "data-kjun-content": string;
24
- "data-tone": "brand" | "secondary" | "inverse" | "danger" | "success" | "warning" | "tertiary" | "disabled" | undefined;
25
- "data-align": TextAlign | undefined;
26
- "data-max-lines": number | undefined;
27
- style: CSSProperties | undefined;
28
- id?: string;
29
- "aria-activedescendant"?: string | undefined;
30
- "aria-atomic"?: (boolean | "false" | "true") | undefined;
31
- "aria-autocomplete"?: "none" | "inline" | "list" | "both" | undefined;
32
- "aria-braillelabel"?: string | undefined;
33
- "aria-brailleroledescription"?: string | undefined;
34
- "aria-busy"?: (boolean | "false" | "true") | undefined;
35
- "aria-checked"?: boolean | "false" | "mixed" | "true" | undefined;
36
- "aria-colcount"?: number | undefined;
37
- "aria-colindex"?: number | undefined;
38
- "aria-colindextext"?: string | undefined;
39
- "aria-colspan"?: number | undefined;
40
- "aria-controls"?: string | undefined;
41
- "aria-current"?: boolean | "false" | "true" | "page" | "step" | "location" | "date" | "time" | undefined;
42
- "aria-describedby"?: string | undefined;
43
- "aria-description"?: string | undefined;
44
- "aria-details"?: string | undefined;
45
- "aria-disabled"?: (boolean | "false" | "true") | undefined;
46
- "aria-dropeffect"?: "none" | "copy" | "execute" | "link" | "move" | "popup" | undefined;
47
- "aria-errormessage"?: string | undefined;
48
- "aria-expanded"?: (boolean | "false" | "true") | undefined;
49
- "aria-flowto"?: string | undefined;
50
- "aria-grabbed"?: (boolean | "false" | "true") | undefined;
51
- "aria-haspopup"?: boolean | "false" | "true" | "menu" | "listbox" | "tree" | "grid" | "dialog" | undefined;
52
- "aria-hidden"?: (boolean | "false" | "true") | undefined;
53
- "aria-invalid"?: boolean | "false" | "true" | "grammar" | "spelling" | undefined;
54
- "aria-keyshortcuts"?: string | undefined;
55
- "aria-label"?: string | undefined;
56
- "aria-labelledby"?: string | undefined;
57
- "aria-level"?: number | undefined;
58
- "aria-live"?: "off" | "assertive" | "polite" | undefined;
59
- "aria-modal"?: (boolean | "false" | "true") | undefined;
60
- "aria-multiline"?: (boolean | "false" | "true") | undefined;
61
- "aria-multiselectable"?: (boolean | "false" | "true") | undefined;
62
- "aria-orientation"?: "horizontal" | "vertical" | undefined;
63
- "aria-owns"?: string | undefined;
64
- "aria-placeholder"?: string | undefined;
65
- "aria-posinset"?: number | undefined;
66
- "aria-pressed"?: boolean | "false" | "mixed" | "true" | undefined;
67
- "aria-readonly"?: (boolean | "false" | "true") | undefined;
68
- "aria-relevant"?: "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text" | "text additions" | "text removals" | undefined;
69
- "aria-required"?: (boolean | "false" | "true") | undefined;
70
- "aria-roledescription"?: string | undefined;
71
- "aria-rowcount"?: number | undefined;
72
- "aria-rowindex"?: number | undefined;
73
- "aria-rowindextext"?: string | undefined;
74
- "aria-rowspan"?: number | undefined;
75
- "aria-selected"?: (boolean | "false" | "true") | undefined;
76
- "aria-setsize"?: number | undefined;
77
- "aria-sort"?: "none" | "ascending" | "descending" | "other" | undefined;
78
- "aria-valuemax"?: number | undefined;
79
- "aria-valuemin"?: number | undefined;
80
- "aria-valuenow"?: number | undefined;
81
- "aria-valuetext"?: string | undefined;
82
- }, HTMLElement>;
83
- export interface KjunStackProps extends RootAttributes {
84
- /** Space between children: space.stack (sm·md·lg) or space.section (section-sm·md·lg). */
85
- gap?: StackGap;
86
- align?: StackAlign;
87
- as?: "div" | "section";
41
+ export declare function KjunText({ variant, tone, as, align, maxLines, numeric, decoration, expandable, expanded: given, onExpandedChange, className, style, children, ...rest }: KjunTextProps): import("react/jsx-runtime").JSX.Element;
42
+ /** Props both KjunStack and KjunInline take. */
43
+ interface FlexOwnProps {
44
+ /** Lay the children out as a column or a row; an object changes it with the width, e.g. { base: "column", medium: "row" }. */
45
+ direction?: DirectionValue;
46
+ /** Inner space from space.inset (sm 12 · md 16 · lg 24) on every side; paddingX and paddingY replace one axis. Takes an object per width like gap. */
47
+ padding?: PaddingValue;
48
+ paddingX?: PaddingValue;
49
+ paddingY?: PaddingValue;
50
+ /** A divider between children: true or "full" a hairline, "inset" a hairline that starts after dividerInset, "strong" a band
51
+ * for sections. A hairline sits inside the gap, so the distance between children stays the gap; a band adds its thickness. */
52
+ divider?: StackDivider;
53
+ /** Where an inset divider starts: space.inset (sm 12 · md 16 · lg 24). Default md. */
54
+ dividerInset?: InsetStep;
55
+ /** What the responsive values follow: viewport (default, CSS media queries) or container, the element's own width, measured. */
56
+ responsive?: ResponsiveBasis;
57
+ /** Main-axis distribution; takes an object per width like gap. */
58
+ justify?: JustifyValue;
88
59
  className?: string;
89
60
  style?: CSSProperties;
90
61
  children?: ReactNode;
91
62
  }
92
- /** Vertical stack. It is not KJUN markup (a data attribute, no kjun- class), so app children keep the styles they would have without it; direct form groups drop their own bottom margin. */
93
- export declare function KjunStack({ gap, align, as, className, style, children, ...rest }: KjunStackProps): import("react").DetailedReactHTMLElement<{
94
- className: string | undefined;
95
- style: CSSProperties | undefined;
96
- "data-kjun-stack": string;
97
- "data-gap": StackGap;
98
- "data-align": StackAlign;
99
- id?: string;
100
- "aria-activedescendant"?: string | undefined;
101
- "aria-atomic"?: (boolean | "false" | "true") | undefined;
102
- "aria-autocomplete"?: "none" | "inline" | "list" | "both" | undefined;
103
- "aria-braillelabel"?: string | undefined;
104
- "aria-brailleroledescription"?: string | undefined;
105
- "aria-busy"?: (boolean | "false" | "true") | undefined;
106
- "aria-checked"?: boolean | "false" | "mixed" | "true" | undefined;
107
- "aria-colcount"?: number | undefined;
108
- "aria-colindex"?: number | undefined;
109
- "aria-colindextext"?: string | undefined;
110
- "aria-colspan"?: number | undefined;
111
- "aria-controls"?: string | undefined;
112
- "aria-current"?: boolean | "false" | "true" | "page" | "step" | "location" | "date" | "time" | undefined;
113
- "aria-describedby"?: string | undefined;
114
- "aria-description"?: string | undefined;
115
- "aria-details"?: string | undefined;
116
- "aria-disabled"?: (boolean | "false" | "true") | undefined;
117
- "aria-dropeffect"?: "none" | "copy" | "execute" | "link" | "move" | "popup" | undefined;
118
- "aria-errormessage"?: string | undefined;
119
- "aria-expanded"?: (boolean | "false" | "true") | undefined;
120
- "aria-flowto"?: string | undefined;
121
- "aria-grabbed"?: (boolean | "false" | "true") | undefined;
122
- "aria-haspopup"?: boolean | "false" | "true" | "menu" | "listbox" | "tree" | "grid" | "dialog" | undefined;
123
- "aria-hidden"?: (boolean | "false" | "true") | undefined;
124
- "aria-invalid"?: boolean | "false" | "true" | "grammar" | "spelling" | undefined;
125
- "aria-keyshortcuts"?: string | undefined;
126
- "aria-label"?: string | undefined;
127
- "aria-labelledby"?: string | undefined;
128
- "aria-level"?: number | undefined;
129
- "aria-live"?: "off" | "assertive" | "polite" | undefined;
130
- "aria-modal"?: (boolean | "false" | "true") | undefined;
131
- "aria-multiline"?: (boolean | "false" | "true") | undefined;
132
- "aria-multiselectable"?: (boolean | "false" | "true") | undefined;
133
- "aria-orientation"?: "horizontal" | "vertical" | undefined;
134
- "aria-owns"?: string | undefined;
135
- "aria-placeholder"?: string | undefined;
136
- "aria-posinset"?: number | undefined;
137
- "aria-pressed"?: boolean | "false" | "mixed" | "true" | undefined;
138
- "aria-readonly"?: (boolean | "false" | "true") | undefined;
139
- "aria-relevant"?: "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text" | "text additions" | "text removals" | undefined;
140
- "aria-required"?: (boolean | "false" | "true") | undefined;
141
- "aria-roledescription"?: string | undefined;
142
- "aria-rowcount"?: number | undefined;
143
- "aria-rowindex"?: number | undefined;
144
- "aria-rowindextext"?: string | undefined;
145
- "aria-rowspan"?: number | undefined;
146
- "aria-selected"?: (boolean | "false" | "true") | undefined;
147
- "aria-setsize"?: number | undefined;
148
- "aria-sort"?: "none" | "ascending" | "descending" | "other" | undefined;
149
- "aria-valuemax"?: number | undefined;
150
- "aria-valuemin"?: number | undefined;
151
- "aria-valuenow"?: number | undefined;
152
- "aria-valuetext"?: string | undefined;
153
- }, HTMLElement>;
154
- export interface KjunInlineProps extends RootAttributes {
155
- /** Space between children: space.inline (xs·sm·md·lg). */
156
- gap?: InlineGap;
157
- align?: InlineAlign;
158
- justify?: InlineJustify;
63
+ /** The tag's own attributes (onSubmit for a form, disabled for a fieldset…) come with as. */
64
+ type WithTag<Own, T extends StackTag> = Own & {
65
+ as?: T;
66
+ } & Omit<ComponentPropsWithRef<T>, keyof Own | "as">;
67
+ export interface KjunStackOwnProps extends FlexOwnProps {
68
+ /** Space between children: space.stack (xs 4 · sm 8 · smMd 12 · md 16 · lg 24) or space.section (sectionSm 32 · sectionMd 48 · sectionLg 64).
69
+ * An object changes it with the width, e.g. { base: "sm", medium: "lg" } (compact 640, medium 768, wide 1024 and up). */
70
+ gap?: StackGapValue;
71
+ /** Cross-axis alignment. With stretch (the default) blocks fill the width while buttons, badges, chips and other
72
+ * content-width controls keep their own; a full-width button says so with block. An object changes it with the width. */
73
+ align?: StackAlignValue;
74
+ }
75
+ /** Element to render with as (ul and ol drop bullets and indent; give them li children); the tag's attributes and ref follow it. */
76
+ export type KjunStackProps<T extends StackTag = "div"> = WithTag<KjunStackOwnProps, T>;
77
+ export interface KjunInlineOwnProps extends FlexOwnProps {
78
+ /** Space between children: space.inline (xs·sm·md·lg). An object changes it with the width like Stack's gap. */
79
+ gap?: InlineGapValue;
80
+ /** The space between wrapped lines: space.stack (xs 4 · sm 8 · smMd 12 · md 16 · lg 24); absent, the lines keep the gap. Takes an object per width. */
81
+ rowGap?: InlineRowGapValue;
82
+ /** Cross-axis alignment; an object changes it with the width. */
83
+ align?: InlineAlignValue;
159
84
  /** Wrap onto new lines when the row runs out of width. Default true. */
160
85
  wrap?: boolean;
86
+ }
87
+ export type KjunInlineProps<T extends StackTag = "div"> = WithTag<KjunInlineOwnProps, T>;
88
+ export interface KjunSpacerProps {
161
89
  className?: string;
162
90
  style?: CSSProperties;
163
- children?: ReactNode;
164
91
  }
92
+ /** Takes the spare length of a Stack or Inline, pushing what follows to the far end: a menu at the top and a profile at the bottom. */
93
+ export declare function KjunSpacer({ className, style }: KjunSpacerProps): import("react/jsx-runtime").JSX.Element;
94
+ /** Vertical stack (direction turns it into a row). It is not KJUN markup (a data attribute, no kjun- class), so app children keep
95
+ * the styles they would have without it; direct form groups drop their own bottom margin. */
96
+ export declare function KjunStack<T extends StackTag = "div">(props: KjunStackProps<T>): ReactElement;
165
97
  /** Horizontal row that wraps by default. Like KjunStack it is not KJUN markup, so app children keep their own styles. */
166
- export declare function KjunInline({ gap, align, justify, wrap, className, style, children, ...rest }: KjunInlineProps): import("react/jsx-runtime").JSX.Element;
98
+ export declare function KjunInline<T extends StackTag = "div">({ wrap, ...props }: KjunInlineProps<T>): ReactElement;
@@ -1,6 +1,6 @@
1
- import { type AriaAttributes, type CSSProperties, type ReactNode } from "react";
2
- import { type InlineAlign, type InlineGap, type InlineJustify, type StackAlign, type StackGap, type TextAlign, type TextTag, type TextTone, type TextVariant } from "../../../shared/package-runtime/layout-primitives.js";
3
- export type { InlineAlign, InlineGap, InlineJustify, StackAlign, StackGap, TextAlign, TextTag, TextTone, TextVariant };
1
+ import { type AriaAttributes, type AriaRole, type ComponentPropsWithRef, type CSSProperties, type ReactElement, type ReactNode, type Ref } from "react";
2
+ import { type DirectionValue, type FlexDirection, type InlineAlign, type InlineAlignValue, type InlineGap, type InlineGapValue, type InlineJustify, type InlineRowGap, type InlineRowGapValue, type InsetStep, type JustifyValue, type LegacyStackGap, type PaddingValue, type Responsive, type ResponsiveBasis, type StackAlign, type StackAlignValue, type StackBreakpoint, type StackDivider, type StackGap, type StackGapValue, type StackJustify, type StackTag, type TextAlign, type TextDecoration, type TextTag, type TextTone, type TextVariant } from "../../../shared/package-runtime/layout-primitives.js";
3
+ export type { DirectionValue, FlexDirection, InlineAlign, InlineAlignValue, InlineGap, InlineGapValue, InlineJustify, InlineRowGap, InlineRowGapValue, InsetStep, JustifyValue, LegacyStackGap, PaddingValue, Responsive, ResponsiveBasis, StackAlign, StackAlignValue, StackBreakpoint, StackDivider, StackGap, StackGapValue, StackJustify, StackTag, TextAlign, TextDecoration, TextTag, TextTone, TextVariant };
4
4
  interface RootAttributes extends AriaAttributes {
5
5
  id?: string;
6
6
  }
@@ -14,153 +14,85 @@ export interface KjunTextProps extends RootAttributes {
14
14
  align?: TextAlign;
15
15
  /** Clamp to this many lines with an ellipsis; the full text stays in the DOM. */
16
16
  maxLines?: number;
17
+ /** With maxLines, a "더보기" button under the text opens the rest and turns into "접기". It shows only while the text
18
+ * overflows (or is open). The text and the button sit in a wrapper div; the text element keeps the other props. */
19
+ expandable?: boolean;
20
+ /** Whether the expandable text is open; leave it out to let the text keep it. */
21
+ expanded?: boolean;
22
+ onExpandedChange?: (expanded: boolean) => void;
23
+ /** Fixed-width digits, so amounts in a column line up. Size and weight stay the variant's. */
24
+ numeric?: boolean;
25
+ /** "lineThrough" strikes the text, e.g. a price before a discount. */
26
+ decoration?: TextDecoration;
27
+ /** Browser tooltip, e.g. the full sentence of a clamped text. */
28
+ title?: string;
29
+ lang?: string;
30
+ dir?: "ltr" | "rtl" | "auto";
31
+ /** The element, e.g. to move focus to a heading after the screen changes (with tabIndex={-1}). */
32
+ ref?: Ref<HTMLElement>;
33
+ /** -1 lets code focus the text without adding it to the Tab order. */
34
+ tabIndex?: number;
35
+ /** An ARIA role for the element, such as "status" for a message that should be announced. */
36
+ role?: AriaRole;
17
37
  className?: string;
18
38
  style?: CSSProperties;
19
39
  children?: ReactNode;
20
40
  }
21
- export declare function KjunText({ variant, tone, as, align, maxLines, className, style, children, ...rest }: KjunTextProps): import("react").DetailedReactHTMLElement<{
22
- className: string;
23
- "data-kjun-content": string;
24
- "data-tone": "brand" | "secondary" | "inverse" | "danger" | "success" | "warning" | "tertiary" | "disabled" | undefined;
25
- "data-align": TextAlign | undefined;
26
- "data-max-lines": number | undefined;
27
- style: CSSProperties | undefined;
28
- id?: string;
29
- "aria-activedescendant"?: string | undefined;
30
- "aria-atomic"?: (boolean | "false" | "true") | undefined;
31
- "aria-autocomplete"?: "none" | "inline" | "list" | "both" | undefined;
32
- "aria-braillelabel"?: string | undefined;
33
- "aria-brailleroledescription"?: string | undefined;
34
- "aria-busy"?: (boolean | "false" | "true") | undefined;
35
- "aria-checked"?: boolean | "false" | "mixed" | "true" | undefined;
36
- "aria-colcount"?: number | undefined;
37
- "aria-colindex"?: number | undefined;
38
- "aria-colindextext"?: string | undefined;
39
- "aria-colspan"?: number | undefined;
40
- "aria-controls"?: string | undefined;
41
- "aria-current"?: boolean | "false" | "true" | "page" | "step" | "location" | "date" | "time" | undefined;
42
- "aria-describedby"?: string | undefined;
43
- "aria-description"?: string | undefined;
44
- "aria-details"?: string | undefined;
45
- "aria-disabled"?: (boolean | "false" | "true") | undefined;
46
- "aria-dropeffect"?: "none" | "copy" | "execute" | "link" | "move" | "popup" | undefined;
47
- "aria-errormessage"?: string | undefined;
48
- "aria-expanded"?: (boolean | "false" | "true") | undefined;
49
- "aria-flowto"?: string | undefined;
50
- "aria-grabbed"?: (boolean | "false" | "true") | undefined;
51
- "aria-haspopup"?: boolean | "false" | "true" | "menu" | "listbox" | "tree" | "grid" | "dialog" | undefined;
52
- "aria-hidden"?: (boolean | "false" | "true") | undefined;
53
- "aria-invalid"?: boolean | "false" | "true" | "grammar" | "spelling" | undefined;
54
- "aria-keyshortcuts"?: string | undefined;
55
- "aria-label"?: string | undefined;
56
- "aria-labelledby"?: string | undefined;
57
- "aria-level"?: number | undefined;
58
- "aria-live"?: "off" | "assertive" | "polite" | undefined;
59
- "aria-modal"?: (boolean | "false" | "true") | undefined;
60
- "aria-multiline"?: (boolean | "false" | "true") | undefined;
61
- "aria-multiselectable"?: (boolean | "false" | "true") | undefined;
62
- "aria-orientation"?: "horizontal" | "vertical" | undefined;
63
- "aria-owns"?: string | undefined;
64
- "aria-placeholder"?: string | undefined;
65
- "aria-posinset"?: number | undefined;
66
- "aria-pressed"?: boolean | "false" | "mixed" | "true" | undefined;
67
- "aria-readonly"?: (boolean | "false" | "true") | undefined;
68
- "aria-relevant"?: "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text" | "text additions" | "text removals" | undefined;
69
- "aria-required"?: (boolean | "false" | "true") | undefined;
70
- "aria-roledescription"?: string | undefined;
71
- "aria-rowcount"?: number | undefined;
72
- "aria-rowindex"?: number | undefined;
73
- "aria-rowindextext"?: string | undefined;
74
- "aria-rowspan"?: number | undefined;
75
- "aria-selected"?: (boolean | "false" | "true") | undefined;
76
- "aria-setsize"?: number | undefined;
77
- "aria-sort"?: "none" | "ascending" | "descending" | "other" | undefined;
78
- "aria-valuemax"?: number | undefined;
79
- "aria-valuemin"?: number | undefined;
80
- "aria-valuenow"?: number | undefined;
81
- "aria-valuetext"?: string | undefined;
82
- }, HTMLElement>;
83
- export interface KjunStackProps extends RootAttributes {
84
- /** Space between children: space.stack (sm·md·lg) or space.section (section-sm·md·lg). */
85
- gap?: StackGap;
86
- align?: StackAlign;
87
- as?: "div" | "section";
41
+ export declare function KjunText({ variant, tone, as, align, maxLines, numeric, decoration, expandable, expanded: given, onExpandedChange, className, style, children, ...rest }: KjunTextProps): import("react/jsx-runtime").JSX.Element;
42
+ /** Props both KjunStack and KjunInline take. */
43
+ interface FlexOwnProps {
44
+ /** Lay the children out as a column or a row; an object changes it with the width, e.g. { base: "column", medium: "row" }. */
45
+ direction?: DirectionValue;
46
+ /** Inner space from space.inset (sm 12 · md 16 · lg 24) on every side; paddingX and paddingY replace one axis. Takes an object per width like gap. */
47
+ padding?: PaddingValue;
48
+ paddingX?: PaddingValue;
49
+ paddingY?: PaddingValue;
50
+ /** A divider between children: true or "full" a hairline, "inset" a hairline that starts after dividerInset, "strong" a band
51
+ * for sections. A hairline sits inside the gap, so the distance between children stays the gap; a band adds its thickness. */
52
+ divider?: StackDivider;
53
+ /** Where an inset divider starts: space.inset (sm 12 · md 16 · lg 24). Default md. */
54
+ dividerInset?: InsetStep;
55
+ /** What the responsive values follow: viewport (default, CSS media queries) or container, the element's own width, measured. */
56
+ responsive?: ResponsiveBasis;
57
+ /** Main-axis distribution; takes an object per width like gap. */
58
+ justify?: JustifyValue;
88
59
  className?: string;
89
60
  style?: CSSProperties;
90
61
  children?: ReactNode;
91
62
  }
92
- /** Vertical stack. It is not KJUN markup (a data attribute, no kjun- class), so app children keep the styles they would have without it; direct form groups drop their own bottom margin. */
93
- export declare function KjunStack({ gap, align, as, className, style, children, ...rest }: KjunStackProps): import("react").DetailedReactHTMLElement<{
94
- className: string | undefined;
95
- style: CSSProperties | undefined;
96
- "data-kjun-stack": string;
97
- "data-gap": StackGap;
98
- "data-align": StackAlign;
99
- id?: string;
100
- "aria-activedescendant"?: string | undefined;
101
- "aria-atomic"?: (boolean | "false" | "true") | undefined;
102
- "aria-autocomplete"?: "none" | "inline" | "list" | "both" | undefined;
103
- "aria-braillelabel"?: string | undefined;
104
- "aria-brailleroledescription"?: string | undefined;
105
- "aria-busy"?: (boolean | "false" | "true") | undefined;
106
- "aria-checked"?: boolean | "false" | "mixed" | "true" | undefined;
107
- "aria-colcount"?: number | undefined;
108
- "aria-colindex"?: number | undefined;
109
- "aria-colindextext"?: string | undefined;
110
- "aria-colspan"?: number | undefined;
111
- "aria-controls"?: string | undefined;
112
- "aria-current"?: boolean | "false" | "true" | "page" | "step" | "location" | "date" | "time" | undefined;
113
- "aria-describedby"?: string | undefined;
114
- "aria-description"?: string | undefined;
115
- "aria-details"?: string | undefined;
116
- "aria-disabled"?: (boolean | "false" | "true") | undefined;
117
- "aria-dropeffect"?: "none" | "copy" | "execute" | "link" | "move" | "popup" | undefined;
118
- "aria-errormessage"?: string | undefined;
119
- "aria-expanded"?: (boolean | "false" | "true") | undefined;
120
- "aria-flowto"?: string | undefined;
121
- "aria-grabbed"?: (boolean | "false" | "true") | undefined;
122
- "aria-haspopup"?: boolean | "false" | "true" | "menu" | "listbox" | "tree" | "grid" | "dialog" | undefined;
123
- "aria-hidden"?: (boolean | "false" | "true") | undefined;
124
- "aria-invalid"?: boolean | "false" | "true" | "grammar" | "spelling" | undefined;
125
- "aria-keyshortcuts"?: string | undefined;
126
- "aria-label"?: string | undefined;
127
- "aria-labelledby"?: string | undefined;
128
- "aria-level"?: number | undefined;
129
- "aria-live"?: "off" | "assertive" | "polite" | undefined;
130
- "aria-modal"?: (boolean | "false" | "true") | undefined;
131
- "aria-multiline"?: (boolean | "false" | "true") | undefined;
132
- "aria-multiselectable"?: (boolean | "false" | "true") | undefined;
133
- "aria-orientation"?: "horizontal" | "vertical" | undefined;
134
- "aria-owns"?: string | undefined;
135
- "aria-placeholder"?: string | undefined;
136
- "aria-posinset"?: number | undefined;
137
- "aria-pressed"?: boolean | "false" | "mixed" | "true" | undefined;
138
- "aria-readonly"?: (boolean | "false" | "true") | undefined;
139
- "aria-relevant"?: "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text" | "text additions" | "text removals" | undefined;
140
- "aria-required"?: (boolean | "false" | "true") | undefined;
141
- "aria-roledescription"?: string | undefined;
142
- "aria-rowcount"?: number | undefined;
143
- "aria-rowindex"?: number | undefined;
144
- "aria-rowindextext"?: string | undefined;
145
- "aria-rowspan"?: number | undefined;
146
- "aria-selected"?: (boolean | "false" | "true") | undefined;
147
- "aria-setsize"?: number | undefined;
148
- "aria-sort"?: "none" | "ascending" | "descending" | "other" | undefined;
149
- "aria-valuemax"?: number | undefined;
150
- "aria-valuemin"?: number | undefined;
151
- "aria-valuenow"?: number | undefined;
152
- "aria-valuetext"?: string | undefined;
153
- }, HTMLElement>;
154
- export interface KjunInlineProps extends RootAttributes {
155
- /** Space between children: space.inline (xs·sm·md·lg). */
156
- gap?: InlineGap;
157
- align?: InlineAlign;
158
- justify?: InlineJustify;
63
+ /** The tag's own attributes (onSubmit for a form, disabled for a fieldset…) come with as. */
64
+ type WithTag<Own, T extends StackTag> = Own & {
65
+ as?: T;
66
+ } & Omit<ComponentPropsWithRef<T>, keyof Own | "as">;
67
+ export interface KjunStackOwnProps extends FlexOwnProps {
68
+ /** Space between children: space.stack (xs 4 · sm 8 · smMd 12 · md 16 · lg 24) or space.section (sectionSm 32 · sectionMd 48 · sectionLg 64).
69
+ * An object changes it with the width, e.g. { base: "sm", medium: "lg" } (compact 640, medium 768, wide 1024 and up). */
70
+ gap?: StackGapValue;
71
+ /** Cross-axis alignment. With stretch (the default) blocks fill the width while buttons, badges, chips and other
72
+ * content-width controls keep their own; a full-width button says so with block. An object changes it with the width. */
73
+ align?: StackAlignValue;
74
+ }
75
+ /** Element to render with as (ul and ol drop bullets and indent; give them li children); the tag's attributes and ref follow it. */
76
+ export type KjunStackProps<T extends StackTag = "div"> = WithTag<KjunStackOwnProps, T>;
77
+ export interface KjunInlineOwnProps extends FlexOwnProps {
78
+ /** Space between children: space.inline (xs·sm·md·lg). An object changes it with the width like Stack's gap. */
79
+ gap?: InlineGapValue;
80
+ /** The space between wrapped lines: space.stack (xs 4 · sm 8 · smMd 12 · md 16 · lg 24); absent, the lines keep the gap. Takes an object per width. */
81
+ rowGap?: InlineRowGapValue;
82
+ /** Cross-axis alignment; an object changes it with the width. */
83
+ align?: InlineAlignValue;
159
84
  /** Wrap onto new lines when the row runs out of width. Default true. */
160
85
  wrap?: boolean;
86
+ }
87
+ export type KjunInlineProps<T extends StackTag = "div"> = WithTag<KjunInlineOwnProps, T>;
88
+ export interface KjunSpacerProps {
161
89
  className?: string;
162
90
  style?: CSSProperties;
163
- children?: ReactNode;
164
91
  }
92
+ /** Takes the spare length of a Stack or Inline, pushing what follows to the far end: a menu at the top and a profile at the bottom. */
93
+ export declare function KjunSpacer({ className, style }: KjunSpacerProps): import("react/jsx-runtime").JSX.Element;
94
+ /** Vertical stack (direction turns it into a row). It is not KJUN markup (a data attribute, no kjun- class), so app children keep
95
+ * the styles they would have without it; direct form groups drop their own bottom margin. */
96
+ export declare function KjunStack<T extends StackTag = "div">(props: KjunStackProps<T>): ReactElement;
165
97
  /** Horizontal row that wraps by default. Like KjunStack it is not KJUN markup, so app children keep their own styles. */
166
- export declare function KjunInline({ gap, align, justify, wrap, className, style, children, ...rest }: KjunInlineProps): import("react/jsx-runtime").JSX.Element;
98
+ export declare function KjunInline<T extends StackTag = "div">({ wrap, ...props }: KjunInlineProps<T>): ReactElement;
@@ -1,8 +1,9 @@
1
1
  /**
2
- * The enclosing KjunListSection's shape: whether it is open and compact, so its rows and a row skeleton in its loading
2
+ * The enclosing KjunListSection's shape: whether it is open, details or compact, so its rows and a row skeleton in its loading
3
3
  * slot draw the same row (open rows' larger lines, compact rows' height).
4
4
  */
5
5
  export declare const ListShapeContext: import("react").Context<{
6
6
  open: boolean;
7
+ details?: boolean;
7
8
  compact: boolean;
8
9
  }>;
@@ -1,8 +1,9 @@
1
1
  /**
2
- * The enclosing KjunListSection's shape: whether it is open and compact, so its rows and a row skeleton in its loading
2
+ * The enclosing KjunListSection's shape: whether it is open, details or compact, so its rows and a row skeleton in its loading
3
3
  * slot draw the same row (open rows' larger lines, compact rows' height).
4
4
  */
5
5
  export declare const ListShapeContext: import("react").Context<{
6
6
  open: boolean;
7
+ details?: boolean;
7
8
  compact: boolean;
8
9
  }>;
@@ -1,9 +1,9 @@
1
1
  import { type CardRadius } from "@kjun-ui/tokens";
2
- import { type MouseEvent, type ReactNode } from "react";
2
+ import { type CSSProperties, type MouseEvent, type ReactNode } from "react";
3
3
  import { type ListChoiceValue, type ListGroupVariant, type ListSectionVariant, type ListSelectionMode } from "../../../shared/package-runtime/list-row.cjs";
4
4
  import { type KjunListReorderControls, type KjunListReorderMove } from "./reorder-controls.cjs";
5
5
  import { type ListLeadingSize } from "../../../shared/package-runtime/list-leading.cjs";
6
- export type { ListChoiceValue, ListGroupVariant, ListSectionVariant } from "../../../shared/package-runtime/list-row.cjs";
6
+ export type { ListChoiceValue, ListGroupVariant, ListSectionVariant, ListTrailingPosition } from "../../../shared/package-runtime/list-row.cjs";
7
7
  export type { ListLeadingSize } from "../../../shared/package-runtime/list-leading.cjs";
8
8
  export type { KjunListReorderControls, KjunListReorderMove } from "./reorder-controls.cjs";
9
9
  export interface KjunListRowProps {
@@ -23,11 +23,25 @@ export interface KjunListRowProps {
23
23
  trailing?: ReactNode;
24
24
  actions?: ReactNode;
25
25
  href?: string;
26
+ /** Where the trailing value sits: "side" (default) is a column beside the whole text; "title" puts it on the title line, so the
27
+ * description and children keep the full text width whatever the value's length (rows with a budget bar line up);
28
+ * "below" gives it its own line under the title across the text width, for long values such as an address. */
29
+ trailingPosition?: "side" | "title" | "below";
30
+ /** Where a link row opens, e.g. "_blank" for a new tab; a new tab gets rel="noopener noreferrer" unless rel is given. */
31
+ target?: string;
32
+ /** The link's rel; by default "noopener noreferrer" for target="_blank". */
33
+ rel?: string;
26
34
  disabled?: boolean;
27
35
  /** Draws the title in the danger role, for rows such as "Delete account". */
28
36
  destructive?: boolean;
37
+ /** The row the list leads to, such as a total or a balance: the title one weight up and the value in the large number
38
+ * type, size and weight only. One or two per section; a details section keeps a little more room above it when it is last. */
39
+ emphasized?: boolean;
29
40
  /** Ends the row with a decorative chevron that marks it as navigation. */
30
41
  chevron?: boolean;
42
+ /** The item open now, such as the message shown beside its list or the settings page in view: the row takes the
43
+ * selected fill and its link or button aria-current ("page" on a link). Not for switch or choice rows. */
44
+ current?: boolean;
31
45
  /** One choice in a single-choice list: true draws a check at the end (in an open section or a multiple-choice list, a filled mark; unchosen rows an empty one). A pressable row given it (true or false) reads as a radio. */
32
46
  selected?: boolean;
33
47
  /** Makes the whole row a switch: it draws one at the end and toggles on any press. */
@@ -42,26 +56,39 @@ export interface KjunListRowProps {
42
56
  ariaLabel?: string;
43
57
  /** Display-only content under the description (a budget bar); no buttons or links inside a pressable row. */
44
58
  children?: ReactNode;
59
+ /** Makes the row open its own content: the row is a button that reports the next state, and ends with a chevron that turns over when open.
60
+ * Not with href, checked, selected or chevron. */
61
+ expanded?: boolean;
62
+ onExpandedChange?: (expanded: boolean) => void;
63
+ /** Shown under the row while expanded, from the line the title starts on. It is outside the button, so it may hold buttons and links. */
64
+ expandedContent?: ReactNode;
45
65
  /** Clamps the title (and the description) to this many lines, ending in an ellipsis. */
46
66
  titleLines?: number;
47
67
  descriptionLines?: number;
48
68
  }
49
- export declare function KjunListRow({ title, description, badge, icon, leadingSize, iconColor, iconBackground, leading, trailing, actions, href, disabled, destructive, chevron, selected: ownSelected, checked, onCheckedChange, busy, value, onClick: ownClick, ariaLabel, children, titleLines, descriptionLines }: KjunListRowProps): import("react/jsx-runtime").JSX.Element;
69
+ export declare function KjunListRow({ title, description, badge, icon, leadingSize, iconColor, iconBackground, leading, trailing, trailingPosition, actions, href, target, rel, disabled, destructive, emphasized, chevron, current, selected: ownSelected, checked, onCheckedChange, busy, value, onClick: ownClick, ariaLabel, children, titleLines, descriptionLines, expanded, onExpandedChange, expandedContent }: KjunListRowProps): import("react/jsx-runtime").JSX.Element;
50
70
  export interface KjunListSectionProps {
51
71
  title?: string;
52
72
  description?: string;
53
73
  actions?: ReactNode;
54
74
  children?: ReactNode;
55
75
  ariaLabel?: string;
76
+ /** A short mark after the title, such as a KjunBadge with the row count; centered on the title's first line and read with the title as the list's name. */
77
+ badge?: ReactNode;
78
+ /** id, class and style of the root section. */
79
+ id?: string;
80
+ className?: string;
81
+ style?: CSSProperties;
56
82
  /** Paints the surface background (default true); false lets the page background show through. */
57
83
  surface?: boolean;
58
- /** Draws dividers between rows (default true). An open section draws none; giving it true warns in development. */
84
+ /** Draws dividers between rows (default true; false in a details section). An open section draws none; giving it true warns in development. */
59
85
  divider?: boolean;
60
- /** "compact" rows keep the 16px inset but are 44 tall (the touch minimum) instead of 56. */
86
+ /** "compact" rows keep the 16px inset but are 44 tall (the touch minimum) instead of 56. A details section keeps its own 32px rows. */
61
87
  density?: "default" | "compact";
62
88
  /** Rounds the rows into a card on the card radius steps; the title, actions and footer stay outside it (default "none", or the KjunListGroup's). An open section has no card. */
63
89
  radius?: CardRadius;
64
- /** "open" puts the rows on the page with no card or dividers: larger titles, icons on rounded squares, and a filled mark for the chosen row (default "default", or "open" in an open KjunListGroup). */
90
+ /** "open" puts the rows on the page with no card or dividers: larger titles, icons on rounded squares, and a filled mark for the chosen row (default "default", or "open" in an open KjunListGroup).
91
+ * "details" is for rows that are read, not pressed ("Payment method / Visa"): 32 tall, no dividers, the label secondary and the value in the text color with the room the label leaves. */
65
92
  variant?: ListSectionVariant;
66
93
  /** "title" is the 16px heading, "label" the small caption above the rows; by default a title with a description is a heading and one without is a label. */
67
94
  titleVariant?: "title" | "label";
@@ -94,14 +121,18 @@ export interface KjunListSectionProps {
94
121
  /** Why moving is off, shown under the rows and read with the buttons. */
95
122
  reorderDisabledText?: string;
96
123
  }
97
- export declare function KjunListSection({ title, description, actions, children, ariaLabel, surface, divider: dividerProp, density, radius, titleVariant, headingLevel, empty, footer, loading, selectionMode, value, onValueChange, variant, reorderable, order, onOrderChange, onReorder, reorderControls, reorderDisabled, reorderDisabledText }: KjunListSectionProps): import("react/jsx-runtime").JSX.Element;
124
+ export declare function KjunListSection({ title, description, badge, id: rootId, className, style, actions, children, ariaLabel, surface, divider: dividerProp, density, radius, titleVariant, headingLevel, empty, footer, loading, selectionMode, value, onValueChange, variant, reorderable, order, onOrderChange, onReorder, reorderControls, reorderDisabled, reorderDisabledText }: KjunListSectionProps): import("react/jsx-runtime").JSX.Element;
98
125
  export interface KjunListGroupProps {
126
+ /** id, class and style of the root. */
127
+ id?: string;
128
+ className?: string;
129
+ style?: CSSProperties;
99
130
  /** "inset" (default) rounds every section and keeps them 24px apart; "flush" keeps square sections 8px apart; "open" puts every section's rows on the page with no card or dividers, 20px apart. */
100
131
  variant?: ListGroupVariant;
101
132
  children: ReactNode;
102
133
  }
103
134
  /** Stacks KjunListSections with one spacing and corner rule, so sections never set radius or gaps one by one. */
104
- export declare function KjunListGroup({ variant, children }: KjunListGroupProps): import("react/jsx-runtime").JSX.Element;
135
+ export declare function KjunListGroup({ variant, children, id, className, style }: KjunListGroupProps): import("react/jsx-runtime").JSX.Element;
105
136
  export interface KjunListItemProps {
106
137
  children: ReactNode;
107
138
  }