@kjun-ui/react 0.20.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 (327) hide show
  1. package/README.md +19 -5
  2. package/dist/index.cjs +11354 -4458
  3. package/dist/index.js +10951 -4033
  4. package/dist/styles.css +3948 -738
  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 +14 -5
  8. package/dist/types/packages/react/src/app-navigation.d.ts +14 -5
  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-actions-context.d.cts +2 -0
  16. package/dist/types/packages/react/src/card-actions-context.d.ts +2 -0
  17. package/dist/types/packages/react/src/card.d.cts +23 -6
  18. package/dist/types/packages/react/src/card.d.ts +23 -6
  19. package/dist/types/packages/react/src/carousel.d.cts +8 -1
  20. package/dist/types/packages/react/src/carousel.d.ts +8 -1
  21. package/dist/types/packages/react/src/chip.d.cts +4 -2
  22. package/dist/types/packages/react/src/chip.d.ts +4 -2
  23. package/dist/types/packages/react/src/choice-controls.d.cts +99 -0
  24. package/dist/types/packages/react/src/choice-controls.d.ts +99 -0
  25. package/dist/types/packages/react/src/collapse.d.cts +4 -1
  26. package/dist/types/packages/react/src/collapse.d.ts +4 -1
  27. package/dist/types/packages/react/src/color-picker-parts.d.cts +58 -0
  28. package/dist/types/packages/react/src/color-picker-parts.d.ts +58 -0
  29. package/dist/types/packages/react/src/color-picker.d.cts +58 -0
  30. package/dist/types/packages/react/src/color-picker.d.ts +58 -0
  31. package/dist/types/packages/react/src/combobox.d.cts +18 -5
  32. package/dist/types/packages/react/src/combobox.d.ts +18 -5
  33. package/dist/types/packages/react/src/controls.d.cts +7 -74
  34. package/dist/types/packages/react/src/controls.d.ts +7 -74
  35. package/dist/types/packages/react/src/data-state.d.cts +22 -9
  36. package/dist/types/packages/react/src/data-state.d.ts +22 -9
  37. package/dist/types/packages/react/src/date-picker.d.cts +8 -2
  38. package/dist/types/packages/react/src/date-picker.d.ts +8 -2
  39. package/dist/types/packages/react/src/display.d.cts +40 -11
  40. package/dist/types/packages/react/src/display.d.ts +40 -11
  41. package/dist/types/packages/react/src/drawer.d.cts +11 -2
  42. package/dist/types/packages/react/src/drawer.d.ts +11 -2
  43. package/dist/types/packages/react/src/dropdown.d.cts +19 -5
  44. package/dist/types/packages/react/src/dropdown.d.ts +19 -5
  45. package/dist/types/packages/react/src/event-calendar.d.cts +47 -0
  46. package/dist/types/packages/react/src/event-calendar.d.ts +47 -0
  47. package/dist/types/packages/react/src/fab.d.cts +18 -7
  48. package/dist/types/packages/react/src/fab.d.ts +18 -7
  49. package/dist/types/packages/react/src/file-upload-row.d.cts +23 -0
  50. package/dist/types/packages/react/src/file-upload-row.d.ts +23 -0
  51. package/dist/types/packages/react/src/file-upload.d.cts +38 -0
  52. package/dist/types/packages/react/src/file-upload.d.ts +38 -0
  53. package/dist/types/packages/react/src/financial-display.d.cts +32 -11
  54. package/dist/types/packages/react/src/financial-display.d.ts +32 -11
  55. package/dist/types/packages/react/src/floating-panel.d.cts +6 -2
  56. package/dist/types/packages/react/src/floating-panel.d.ts +6 -2
  57. package/dist/types/packages/react/src/index.d.cts +16 -1
  58. package/dist/types/packages/react/src/index.d.ts +16 -1
  59. package/dist/types/packages/react/src/input.d.cts +14 -1
  60. package/dist/types/packages/react/src/input.d.ts +14 -1
  61. package/dist/types/packages/react/src/kpi-hero.d.cts +55 -0
  62. package/dist/types/packages/react/src/kpi-hero.d.ts +55 -0
  63. package/dist/types/packages/react/src/kpi-row.d.cts +46 -0
  64. package/dist/types/packages/react/src/kpi-row.d.ts +46 -0
  65. package/dist/types/packages/react/src/kpi.d.cts +2 -72
  66. package/dist/types/packages/react/src/kpi.d.ts +2 -72
  67. package/dist/types/packages/react/src/layout-primitives.d.cts +71 -139
  68. package/dist/types/packages/react/src/layout-primitives.d.ts +71 -139
  69. package/dist/types/packages/react/src/list-context.d.cts +9 -0
  70. package/dist/types/packages/react/src/list-context.d.ts +9 -0
  71. package/dist/types/packages/react/src/list.d.cts +84 -11
  72. package/dist/types/packages/react/src/list.d.ts +84 -11
  73. package/dist/types/packages/react/src/market-model.d.cts +13 -1
  74. package/dist/types/packages/react/src/market-model.d.ts +13 -1
  75. package/dist/types/packages/react/src/market-parts.d.cts +9 -0
  76. package/dist/types/packages/react/src/market-parts.d.ts +9 -0
  77. package/dist/types/packages/react/src/market-skeleton.d.cts +7 -1
  78. package/dist/types/packages/react/src/market-skeleton.d.ts +7 -1
  79. package/dist/types/packages/react/src/media.d.cts +6 -2
  80. package/dist/types/packages/react/src/media.d.ts +6 -2
  81. package/dist/types/packages/react/src/modal.d.cts +14 -2
  82. package/dist/types/packages/react/src/modal.d.ts +14 -2
  83. package/dist/types/packages/react/src/navigation.d.cts +36 -6
  84. package/dist/types/packages/react/src/navigation.d.ts +36 -6
  85. package/dist/types/packages/react/src/number-display.d.cts +10 -5
  86. package/dist/types/packages/react/src/number-display.d.ts +10 -5
  87. package/dist/types/packages/react/src/number-input.d.cts +28 -0
  88. package/dist/types/packages/react/src/number-input.d.ts +28 -0
  89. package/dist/types/packages/react/src/popover.d.cts +5 -2
  90. package/dist/types/packages/react/src/popover.d.ts +5 -2
  91. package/dist/types/packages/react/src/pressable.d.cts +17 -0
  92. package/dist/types/packages/react/src/pressable.d.ts +17 -0
  93. package/dist/types/packages/react/src/quantity-stepper.d.cts +3 -1
  94. package/dist/types/packages/react/src/quantity-stepper.d.ts +3 -1
  95. package/dist/types/packages/react/src/range-input.d.cts +15 -3
  96. package/dist/types/packages/react/src/range-input.d.ts +15 -3
  97. package/dist/types/packages/react/src/reorder-controls.d.cts +43 -0
  98. package/dist/types/packages/react/src/reorder-controls.d.ts +43 -0
  99. package/dist/types/packages/react/src/search-input.d.cts +6 -3
  100. package/dist/types/packages/react/src/search-input.d.ts +6 -3
  101. package/dist/types/packages/react/src/select-control.d.cts +7 -2
  102. package/dist/types/packages/react/src/select-control.d.ts +7 -2
  103. package/dist/types/packages/react/src/side-navigation-layout.d.cts +47 -0
  104. package/dist/types/packages/react/src/side-navigation-layout.d.ts +47 -0
  105. package/dist/types/packages/react/src/side-navigation.d.cts +74 -0
  106. package/dist/types/packages/react/src/side-navigation.d.ts +74 -0
  107. package/dist/types/packages/react/src/skeletons.d.cts +19 -3
  108. package/dist/types/packages/react/src/skeletons.d.ts +19 -3
  109. package/dist/types/packages/react/src/spinner-glyph.d.cts +8 -0
  110. package/dist/types/packages/react/src/spinner-glyph.d.ts +8 -0
  111. package/dist/types/packages/react/src/split-pane.d.cts +43 -0
  112. package/dist/types/packages/react/src/split-pane.d.ts +43 -0
  113. package/dist/types/packages/react/src/stacked-bar.d.cts +24 -0
  114. package/dist/types/packages/react/src/stacked-bar.d.ts +24 -0
  115. package/dist/types/packages/react/src/steps.d.cts +26 -0
  116. package/dist/types/packages/react/src/steps.d.ts +26 -0
  117. package/dist/types/packages/react/src/table-cards.d.cts +4 -12
  118. package/dist/types/packages/react/src/table-cards.d.ts +4 -12
  119. package/dist/types/packages/react/src/table-grid.d.cts +3 -7
  120. package/dist/types/packages/react/src/table-grid.d.ts +3 -7
  121. package/dist/types/packages/react/src/table-groups.d.cts +5 -0
  122. package/dist/types/packages/react/src/table-groups.d.ts +5 -0
  123. package/dist/types/packages/react/src/table-list.d.cts +2 -9
  124. package/dist/types/packages/react/src/table-list.d.ts +2 -9
  125. package/dist/types/packages/react/src/table-model.d.cts +6 -2
  126. package/dist/types/packages/react/src/table-model.d.ts +6 -2
  127. package/dist/types/packages/react/src/tabs.d.cts +3 -1
  128. package/dist/types/packages/react/src/tabs.d.ts +3 -1
  129. package/dist/types/packages/react/src/textarea.d.cts +6 -3
  130. package/dist/types/packages/react/src/textarea.d.ts +6 -3
  131. package/dist/types/packages/react/src/tiles.d.cts +18 -0
  132. package/dist/types/packages/react/src/tiles.d.ts +18 -0
  133. package/dist/types/packages/react/src/time-picker.d.cts +12 -2
  134. package/dist/types/packages/react/src/time-picker.d.ts +12 -2
  135. package/dist/types/packages/react/src/time-wheel.d.cts +18 -0
  136. package/dist/types/packages/react/src/time-wheel.d.ts +18 -0
  137. package/dist/types/packages/react/src/use-filter-scroll.d.cts +5 -0
  138. package/dist/types/packages/react/src/use-filter-scroll.d.ts +5 -0
  139. package/dist/types/packages/react/src/zone-gauge.d.cts +28 -0
  140. package/dist/types/packages/react/src/zone-gauge.d.ts +28 -0
  141. package/dist/types/shared/package-runtime/accordion-state.d.cts +2 -0
  142. package/dist/types/shared/package-runtime/accordion-state.d.ts +2 -0
  143. package/dist/types/shared/package-runtime/action-size.d.cts +4 -0
  144. package/dist/types/shared/package-runtime/action-size.d.ts +4 -0
  145. package/dist/types/shared/package-runtime/alert-action-size.d.cts +1 -0
  146. package/dist/types/shared/package-runtime/alert-action-size.d.ts +1 -0
  147. package/dist/types/shared/package-runtime/alert-actions.d.cts +7 -0
  148. package/dist/types/shared/package-runtime/alert-actions.d.ts +7 -0
  149. package/dist/types/shared/package-runtime/alert-exit.d.cts +6 -0
  150. package/dist/types/shared/package-runtime/alert-exit.d.ts +6 -0
  151. package/dist/types/shared/package-runtime/alert-live.d.cts +2 -0
  152. package/dist/types/shared/package-runtime/alert-live.d.ts +2 -0
  153. package/dist/types/shared/package-runtime/avatar-group.d.cts +18 -0
  154. package/dist/types/shared/package-runtime/avatar-group.d.ts +18 -0
  155. package/dist/types/shared/package-runtime/badge-tone.d.cts +8 -2
  156. package/dist/types/shared/package-runtime/badge-tone.d.ts +8 -2
  157. package/dist/types/shared/package-runtime/bottom-bar.d.cts +15 -0
  158. package/dist/types/shared/package-runtime/bottom-bar.d.ts +15 -0
  159. package/dist/types/shared/package-runtime/bottom-navigation.d.cts +30 -0
  160. package/dist/types/shared/package-runtime/bottom-navigation.d.ts +30 -0
  161. package/dist/types/shared/package-runtime/calendar.d.cts +21 -7
  162. package/dist/types/shared/package-runtime/calendar.d.ts +21 -7
  163. package/dist/types/shared/package-runtime/card-layout.d.cts +42 -0
  164. package/dist/types/shared/package-runtime/card-layout.d.ts +42 -0
  165. package/dist/types/shared/package-runtime/carousel-scroll.d.cts +2 -0
  166. package/dist/types/shared/package-runtime/carousel-scroll.d.ts +2 -0
  167. package/dist/types/shared/package-runtime/carousel.d.cts +12 -2
  168. package/dist/types/shared/package-runtime/carousel.d.ts +12 -2
  169. package/dist/types/shared/package-runtime/chart-skeleton.d.cts +2 -2
  170. package/dist/types/shared/package-runtime/chart-skeleton.d.ts +2 -2
  171. package/dist/types/shared/package-runtime/chip-size.d.cts +4 -0
  172. package/dist/types/shared/package-runtime/chip-size.d.ts +4 -0
  173. package/dist/types/shared/package-runtime/clipboard.d.cts +6 -0
  174. package/dist/types/shared/package-runtime/clipboard.d.ts +6 -0
  175. package/dist/types/shared/package-runtime/color-picker-model.d.cts +51 -0
  176. package/dist/types/shared/package-runtime/color-picker-model.d.ts +51 -0
  177. package/dist/types/shared/package-runtime/color-picker.d.cts +92 -0
  178. package/dist/types/shared/package-runtime/color-picker.d.ts +92 -0
  179. package/dist/types/shared/package-runtime/color.d.cts +22 -0
  180. package/dist/types/shared/package-runtime/color.d.ts +22 -0
  181. package/dist/types/shared/package-runtime/combobox-options.d.cts +13 -0
  182. package/dist/types/shared/package-runtime/combobox-options.d.ts +13 -0
  183. package/dist/types/shared/package-runtime/combobox.d.cts +3 -1
  184. package/dist/types/shared/package-runtime/combobox.d.ts +3 -1
  185. package/dist/types/shared/package-runtime/copy-button.d.cts +11 -0
  186. package/dist/types/shared/package-runtime/copy-button.d.ts +11 -0
  187. package/dist/types/shared/package-runtime/data-cells.d.cts +36 -0
  188. package/dist/types/shared/package-runtime/data-cells.d.ts +36 -0
  189. package/dist/types/shared/package-runtime/development.d.cts +4 -0
  190. package/dist/types/shared/package-runtime/development.d.ts +4 -0
  191. package/dist/types/shared/package-runtime/distribution.d.cts +168 -0
  192. package/dist/types/shared/package-runtime/distribution.d.ts +168 -0
  193. package/dist/types/shared/package-runtime/drawer-geometry.d.cts +7 -0
  194. package/dist/types/shared/package-runtime/drawer-geometry.d.ts +7 -0
  195. package/dist/types/shared/package-runtime/empty-geometry.d.cts +19 -0
  196. package/dist/types/shared/package-runtime/empty-geometry.d.ts +19 -0
  197. package/dist/types/shared/package-runtime/event-calendar.d.cts +81 -0
  198. package/dist/types/shared/package-runtime/event-calendar.d.ts +81 -0
  199. package/dist/types/shared/package-runtime/external-link.d.cts +4 -0
  200. package/dist/types/shared/package-runtime/external-link.d.ts +4 -0
  201. package/dist/types/shared/package-runtime/file-upload.d.cts +128 -0
  202. package/dist/types/shared/package-runtime/file-upload.d.ts +128 -0
  203. package/dist/types/shared/package-runtime/filter-scroll.d.cts +5 -0
  204. package/dist/types/shared/package-runtime/filter-scroll.d.ts +5 -0
  205. package/dist/types/shared/package-runtime/filter-value.d.cts +2 -0
  206. package/dist/types/shared/package-runtime/filter-value.d.ts +2 -0
  207. package/dist/types/shared/package-runtime/input-field.d.cts +23 -0
  208. package/dist/types/shared/package-runtime/input-field.d.ts +23 -0
  209. package/dist/types/shared/package-runtime/input-variant.d.cts +7 -0
  210. package/dist/types/shared/package-runtime/input-variant.d.ts +7 -0
  211. package/dist/types/shared/package-runtime/kpi.d.cts +102 -0
  212. package/dist/types/shared/package-runtime/kpi.d.ts +102 -0
  213. package/dist/types/shared/package-runtime/layer-state.d.cts +2 -1
  214. package/dist/types/shared/package-runtime/layer-state.d.ts +2 -1
  215. package/dist/types/shared/package-runtime/layout-primitives.d.cts +115 -6
  216. package/dist/types/shared/package-runtime/layout-primitives.d.ts +115 -6
  217. package/dist/types/shared/package-runtime/list-leading.d.cts +38 -0
  218. package/dist/types/shared/package-runtime/list-leading.d.ts +38 -0
  219. package/dist/types/shared/package-runtime/list-row.d.cts +152 -4
  220. package/dist/types/shared/package-runtime/list-row.d.ts +152 -4
  221. package/dist/types/shared/package-runtime/market-layout.d.cts +6 -2
  222. package/dist/types/shared/package-runtime/market-layout.d.ts +6 -2
  223. package/dist/types/shared/package-runtime/market-query.d.cts +21 -0
  224. package/dist/types/shared/package-runtime/market-query.d.ts +21 -0
  225. package/dist/types/shared/package-runtime/market-table.d.cts +32 -0
  226. package/dist/types/shared/package-runtime/market-table.d.ts +32 -0
  227. package/dist/types/shared/package-runtime/menu-button.d.cts +4 -0
  228. package/dist/types/shared/package-runtime/menu-button.d.ts +4 -0
  229. package/dist/types/shared/package-runtime/messages/ko.d.cts +101 -1
  230. package/dist/types/shared/package-runtime/messages/ko.d.ts +101 -1
  231. package/dist/types/shared/package-runtime/messages-context.d.cts +93 -1
  232. package/dist/types/shared/package-runtime/messages-context.d.ts +93 -1
  233. package/dist/types/shared/package-runtime/minimum-loading.d.cts +3 -0
  234. package/dist/types/shared/package-runtime/minimum-loading.d.ts +3 -0
  235. package/dist/types/shared/package-runtime/modal-geometry.d.cts +15 -0
  236. package/dist/types/shared/package-runtime/modal-geometry.d.ts +15 -0
  237. package/dist/types/shared/package-runtime/navigation.d.cts +9 -2
  238. package/dist/types/shared/package-runtime/navigation.d.ts +9 -2
  239. package/dist/types/shared/package-runtime/nested-controls.d.cts +7 -0
  240. package/dist/types/shared/package-runtime/nested-controls.d.ts +7 -0
  241. package/dist/types/shared/package-runtime/number-input.d.cts +63 -0
  242. package/dist/types/shared/package-runtime/number-input.d.ts +63 -0
  243. package/dist/types/shared/package-runtime/number-sign.d.cts +9 -0
  244. package/dist/types/shared/package-runtime/number-sign.d.ts +9 -0
  245. package/dist/types/shared/package-runtime/options.d.cts +25 -5
  246. package/dist/types/shared/package-runtime/options.d.ts +25 -5
  247. package/dist/types/shared/package-runtime/pagination.d.cts +12 -0
  248. package/dist/types/shared/package-runtime/pagination.d.ts +12 -0
  249. package/dist/types/shared/package-runtime/popover-scroll.d.cts +3 -0
  250. package/dist/types/shared/package-runtime/popover-scroll.d.ts +3 -0
  251. package/dist/types/shared/package-runtime/press-repeat.d.cts +13 -0
  252. package/dist/types/shared/package-runtime/press-repeat.d.ts +13 -0
  253. package/dist/types/shared/package-runtime/progress-circle.d.cts +5 -0
  254. package/dist/types/shared/package-runtime/progress-circle.d.ts +5 -0
  255. package/dist/types/shared/package-runtime/progress-marker.d.cts +7 -0
  256. package/dist/types/shared/package-runtime/progress-marker.d.ts +7 -0
  257. package/dist/types/shared/package-runtime/radio-keyboard.d.cts +2 -0
  258. package/dist/types/shared/package-runtime/radio-keyboard.d.ts +2 -0
  259. package/dist/types/shared/package-runtime/reorder-session.d.cts +62 -0
  260. package/dist/types/shared/package-runtime/reorder-session.d.ts +62 -0
  261. package/dist/types/shared/package-runtime/reorder.d.cts +81 -0
  262. package/dist/types/shared/package-runtime/reorder.d.ts +81 -0
  263. package/dist/types/shared/package-runtime/select-trigger.d.cts +23 -0
  264. package/dist/types/shared/package-runtime/select-trigger.d.ts +23 -0
  265. package/dist/types/shared/package-runtime/sheet-drag.d.cts +24 -0
  266. package/dist/types/shared/package-runtime/sheet-drag.d.ts +24 -0
  267. package/dist/types/shared/package-runtime/side-navigation-keys.d.cts +23 -0
  268. package/dist/types/shared/package-runtime/side-navigation-keys.d.ts +23 -0
  269. package/dist/types/shared/package-runtime/side-navigation-scroll.d.cts +7 -0
  270. package/dist/types/shared/package-runtime/side-navigation-scroll.d.ts +7 -0
  271. package/dist/types/shared/package-runtime/side-navigation.d.cts +277 -0
  272. package/dist/types/shared/package-runtime/side-navigation.d.ts +277 -0
  273. package/dist/types/shared/package-runtime/signed-number.d.cts +33 -0
  274. package/dist/types/shared/package-runtime/signed-number.d.ts +33 -0
  275. package/dist/types/shared/package-runtime/skeleton-text.d.cts +18 -0
  276. package/dist/types/shared/package-runtime/skeleton-text.d.ts +18 -0
  277. package/dist/types/shared/package-runtime/slider-view.d.cts +17 -2
  278. package/dist/types/shared/package-runtime/slider-view.d.ts +17 -2
  279. package/dist/types/shared/package-runtime/sparkline.d.cts +8 -4
  280. package/dist/types/shared/package-runtime/sparkline.d.ts +8 -4
  281. package/dist/types/shared/package-runtime/spinner-geometry.d.cts +14 -0
  282. package/dist/types/shared/package-runtime/spinner-geometry.d.ts +14 -0
  283. package/dist/types/shared/package-runtime/split-pane.d.cts +85 -0
  284. package/dist/types/shared/package-runtime/split-pane.d.ts +85 -0
  285. package/dist/types/shared/package-runtime/steps.d.cts +37 -0
  286. package/dist/types/shared/package-runtime/steps.d.ts +37 -0
  287. package/dist/types/shared/package-runtime/tab-keyboard.d.cts +6 -0
  288. package/dist/types/shared/package-runtime/tab-keyboard.d.ts +6 -0
  289. package/dist/types/shared/package-runtime/table-columns.d.cts +36 -0
  290. package/dist/types/shared/package-runtime/table-columns.d.ts +36 -0
  291. package/dist/types/shared/package-runtime/table-model.d.cts +23 -3
  292. package/dist/types/shared/package-runtime/table-model.d.ts +23 -3
  293. package/dist/types/shared/package-runtime/table-presentation.d.cts +33 -4
  294. package/dist/types/shared/package-runtime/table-presentation.d.ts +33 -4
  295. package/dist/types/shared/package-runtime/table.d.cts +44 -2
  296. package/dist/types/shared/package-runtime/table.d.ts +44 -2
  297. package/dist/types/shared/package-runtime/textarea.d.cts +6 -4
  298. package/dist/types/shared/package-runtime/textarea.d.ts +6 -4
  299. package/dist/types/shared/package-runtime/tiles-children.d.cts +7 -0
  300. package/dist/types/shared/package-runtime/tiles-children.d.ts +7 -0
  301. package/dist/types/shared/package-runtime/tiles.d.cts +18 -0
  302. package/dist/types/shared/package-runtime/tiles.d.ts +18 -0
  303. package/dist/types/shared/package-runtime/time-segments.d.cts +24 -0
  304. package/dist/types/shared/package-runtime/time-segments.d.ts +24 -0
  305. package/dist/types/shared/package-runtime/time-wheel.d.cts +54 -0
  306. package/dist/types/shared/package-runtime/time-wheel.d.ts +54 -0
  307. package/dist/types/shared/package-runtime/trailing-overflow.d.cts +1 -0
  308. package/dist/types/shared/package-runtime/trailing-overflow.d.ts +1 -0
  309. package/dist/types/shared/package-runtime/use-color-picker.d.cts +54 -0
  310. package/dist/types/shared/package-runtime/use-color-picker.d.ts +54 -0
  311. package/dist/types/shared/package-runtime/use-copy-feedback.d.cts +10 -0
  312. package/dist/types/shared/package-runtime/use-copy-feedback.d.ts +10 -0
  313. package/dist/types/shared/package-runtime/use-layer.d.cts +4 -2
  314. package/dist/types/shared/package-runtime/use-layer.d.ts +4 -2
  315. package/dist/types/shared/package-runtime/use-open-state.d.cts +5 -0
  316. package/dist/types/shared/package-runtime/use-open-state.d.ts +5 -0
  317. package/dist/types/shared/package-runtime/use-pending-action.d.cts +6 -0
  318. package/dist/types/shared/package-runtime/use-pending-action.d.ts +6 -0
  319. package/dist/types/shared/package-runtime/use-side-navigation-state.d.cts +25 -0
  320. package/dist/types/shared/package-runtime/use-side-navigation-state.d.ts +25 -0
  321. package/dist/types/shared/package-runtime/use-slide.d.cts +3 -0
  322. package/dist/types/shared/package-runtime/use-slide.d.ts +3 -0
  323. package/package.json +3 -3
  324. package/dist/types/packages/react/src/compound-control.d.cts +0 -1
  325. package/dist/types/packages/react/src/compound-control.d.ts +0 -1
  326. package/dist/types/shared/package-runtime/center-option.d.cts +0 -1
  327. package/dist/types/shared/package-runtime/center-option.d.ts +0 -1
@@ -0,0 +1,128 @@
1
+ import type { KjunMessages } from "./messages/index.cjs";
2
+ export type KjunUploadStatus = "queued" | "uploading" | "done" | "error";
3
+ export interface KjunUploadFile {
4
+ id: string;
5
+ name: string;
6
+ /** Bytes. */
7
+ size: number;
8
+ status: KjunUploadStatus;
9
+ /** 0–100 while uploading; leave it out for an indeterminate bar. */
10
+ progress?: number;
11
+ /** Text shown on a failed row; the default message is used without it. */
12
+ error?: string;
13
+ /** Image thumbnail; the extension is shown without it. */
14
+ previewUrl?: string;
15
+ type?: string;
16
+ }
17
+ export type KjunRejectReason = "type" | "size" | "count";
18
+ export interface KjunRejectedFile<T> {
19
+ file: T;
20
+ reason: KjunRejectReason;
21
+ }
22
+ /** What a Native picker returns; Web hands over File objects instead. */
23
+ export interface KjunPickedFile {
24
+ name: string;
25
+ size: number;
26
+ type?: string;
27
+ uri?: string;
28
+ }
29
+ export interface UploadLimits {
30
+ accept?: string;
31
+ maxSize?: number;
32
+ maxFiles?: number;
33
+ multiple?: boolean;
34
+ current: number;
35
+ }
36
+ export type DragVerdict = "ok" | "type" | "count" | "unknown";
37
+ /** The <input accept> rules: ".ext" by name, "type/*" and "type/sub" by MIME. An empty accept takes anything. */
38
+ export declare function matchesAccept(name: string, type: string | undefined, accept?: string): boolean;
39
+ /** Free places: one in single-file mode (the pick replaces the file), unlimited without maxFiles. */
40
+ export declare function uploadRoom({ maxFiles, multiple, current }: UploadLimits): number;
41
+ /** Checks type, then size, then fills the free places in order; the rest are rejected as count. */
42
+ export declare function screenFiles<T extends {
43
+ name: string;
44
+ size: number;
45
+ type?: string;
46
+ }>(files: T[], limits: UploadLimits): {
47
+ accepted: T[];
48
+ rejected: KjunRejectedFile<T>[];
49
+ };
50
+ /** What a drag can tell before the drop: the number of files and, in some browsers, their MIME types. Never size. */
51
+ export declare function dragVerdict(items: {
52
+ kind: string;
53
+ type: string;
54
+ }[], limits: UploadLimits): {
55
+ verdict: DragVerdict;
56
+ count: number;
57
+ room: number;
58
+ };
59
+ /** Middle truncation: the head may be cut, the tail (last 4 stem characters and the extension) always shows. */
60
+ export declare function splitFileName(name: string): {
61
+ head: string;
62
+ tail: string;
63
+ };
64
+ /** Thumbnail text for a file without a preview: the extension in capitals, at most 4 letters. */
65
+ export declare function extensionLabel(name: string, _type?: string): string;
66
+ /** 1024 steps; one decimal under 100, none from 100 up; no space before the unit. */
67
+ export declare function formatBytes(bytes: number, intl?: string): string;
68
+ export declare function clampProgress(progress: number | undefined): number | undefined;
69
+ export declare function uploadSummary(files: {
70
+ status: KjunUploadStatus;
71
+ }[]): {
72
+ total: number;
73
+ done: number;
74
+ failed: number;
75
+ uploading: number;
76
+ queued: number;
77
+ };
78
+ /** Rows that just became done or failed, for the live region. The first render (no previous state) announces nothing. */
79
+ export declare function uploadTransitions(prev: Record<string, KjunUploadStatus>, files: KjunUploadFile[]): {
80
+ id: string;
81
+ name: string;
82
+ status: "done" | "error";
83
+ }[];
84
+ export declare const uploadStatuses: (files: KjunUploadFile[]) => Record<string, KjunUploadStatus>;
85
+ /** After a row is removed, focus the next row, else the previous one; null means the add button. */
86
+ export declare function focusAfterRemove(ids: string[], removed: string): string | null;
87
+ /** ".pdf,image/png,video/*" → labels ["PDF","PNG"], groups ["video"]; groups are named by the messages. */
88
+ export declare function acceptLabels(accept?: string): {
89
+ labels: string[];
90
+ groups: string[];
91
+ };
92
+ export type KjunUploadSize = "md" | "compact";
93
+ export type KjunUploadTrigger = "area" | "button";
94
+ export type KjunUploadLayout = "list" | "grid";
95
+ export type DragState = {
96
+ verdict: DragVerdict;
97
+ count: number;
98
+ room: number;
99
+ } | null;
100
+ /** How many rejected files are listed by name; the rest fold into one "n more" line. */
101
+ export declare const REJECTION_LINES = 3;
102
+ /** The rejection notice (and its announcement): the first three by name, then one "n more" line. */
103
+ export declare function rejectionLines<T extends {
104
+ name: string;
105
+ }>(m: KjunMessages, list: KjunRejectedFile<T>[], sizeText?: string): string[];
106
+ /** A drag that cannot add anything: a refused type, or no room left at all. */
107
+ export declare const dragBlocked: (drag: DragState) => boolean;
108
+ /** What the zone (empty) or the veil (filled) says and shows while files are dragged over the card. */
109
+ export declare function dragCopy(m: KjunMessages, drag: DragState, types: string, maxFiles?: number): {
110
+ title: string;
111
+ hint: string;
112
+ icon: string;
113
+ blocked: boolean;
114
+ } | null;
115
+ /** The allowed types in words: extensions and exact MIME in capitals, wildcard groups named by the messages. */
116
+ export declare function acceptText(m: KjunMessages, accept?: string): string;
117
+ /** The row's × cancels a file still waiting or uploading and removes one that finished or failed. */
118
+ export declare const removeLabel: (m: KjunMessages, file: {
119
+ name: string;
120
+ status: KjunUploadStatus;
121
+ }) => string;
122
+ /** A tile's name for assistive tech: the file name, then its state in words. */
123
+ export declare function tileLabel(m: KjunMessages, file: KjunUploadFile): string;
124
+ /** Grid columns that keep every tile at least `min` wide, and the tile width that fills the row. */
125
+ export declare function gridColumns(width: number, min: number, gap: number): {
126
+ columns: number;
127
+ tile: number;
128
+ };
@@ -0,0 +1,128 @@
1
+ import type { KjunMessages } from "./messages/index.js";
2
+ export type KjunUploadStatus = "queued" | "uploading" | "done" | "error";
3
+ export interface KjunUploadFile {
4
+ id: string;
5
+ name: string;
6
+ /** Bytes. */
7
+ size: number;
8
+ status: KjunUploadStatus;
9
+ /** 0–100 while uploading; leave it out for an indeterminate bar. */
10
+ progress?: number;
11
+ /** Text shown on a failed row; the default message is used without it. */
12
+ error?: string;
13
+ /** Image thumbnail; the extension is shown without it. */
14
+ previewUrl?: string;
15
+ type?: string;
16
+ }
17
+ export type KjunRejectReason = "type" | "size" | "count";
18
+ export interface KjunRejectedFile<T> {
19
+ file: T;
20
+ reason: KjunRejectReason;
21
+ }
22
+ /** What a Native picker returns; Web hands over File objects instead. */
23
+ export interface KjunPickedFile {
24
+ name: string;
25
+ size: number;
26
+ type?: string;
27
+ uri?: string;
28
+ }
29
+ export interface UploadLimits {
30
+ accept?: string;
31
+ maxSize?: number;
32
+ maxFiles?: number;
33
+ multiple?: boolean;
34
+ current: number;
35
+ }
36
+ export type DragVerdict = "ok" | "type" | "count" | "unknown";
37
+ /** The <input accept> rules: ".ext" by name, "type/*" and "type/sub" by MIME. An empty accept takes anything. */
38
+ export declare function matchesAccept(name: string, type: string | undefined, accept?: string): boolean;
39
+ /** Free places: one in single-file mode (the pick replaces the file), unlimited without maxFiles. */
40
+ export declare function uploadRoom({ maxFiles, multiple, current }: UploadLimits): number;
41
+ /** Checks type, then size, then fills the free places in order; the rest are rejected as count. */
42
+ export declare function screenFiles<T extends {
43
+ name: string;
44
+ size: number;
45
+ type?: string;
46
+ }>(files: T[], limits: UploadLimits): {
47
+ accepted: T[];
48
+ rejected: KjunRejectedFile<T>[];
49
+ };
50
+ /** What a drag can tell before the drop: the number of files and, in some browsers, their MIME types. Never size. */
51
+ export declare function dragVerdict(items: {
52
+ kind: string;
53
+ type: string;
54
+ }[], limits: UploadLimits): {
55
+ verdict: DragVerdict;
56
+ count: number;
57
+ room: number;
58
+ };
59
+ /** Middle truncation: the head may be cut, the tail (last 4 stem characters and the extension) always shows. */
60
+ export declare function splitFileName(name: string): {
61
+ head: string;
62
+ tail: string;
63
+ };
64
+ /** Thumbnail text for a file without a preview: the extension in capitals, at most 4 letters. */
65
+ export declare function extensionLabel(name: string, _type?: string): string;
66
+ /** 1024 steps; one decimal under 100, none from 100 up; no space before the unit. */
67
+ export declare function formatBytes(bytes: number, intl?: string): string;
68
+ export declare function clampProgress(progress: number | undefined): number | undefined;
69
+ export declare function uploadSummary(files: {
70
+ status: KjunUploadStatus;
71
+ }[]): {
72
+ total: number;
73
+ done: number;
74
+ failed: number;
75
+ uploading: number;
76
+ queued: number;
77
+ };
78
+ /** Rows that just became done or failed, for the live region. The first render (no previous state) announces nothing. */
79
+ export declare function uploadTransitions(prev: Record<string, KjunUploadStatus>, files: KjunUploadFile[]): {
80
+ id: string;
81
+ name: string;
82
+ status: "done" | "error";
83
+ }[];
84
+ export declare const uploadStatuses: (files: KjunUploadFile[]) => Record<string, KjunUploadStatus>;
85
+ /** After a row is removed, focus the next row, else the previous one; null means the add button. */
86
+ export declare function focusAfterRemove(ids: string[], removed: string): string | null;
87
+ /** ".pdf,image/png,video/*" → labels ["PDF","PNG"], groups ["video"]; groups are named by the messages. */
88
+ export declare function acceptLabels(accept?: string): {
89
+ labels: string[];
90
+ groups: string[];
91
+ };
92
+ export type KjunUploadSize = "md" | "compact";
93
+ export type KjunUploadTrigger = "area" | "button";
94
+ export type KjunUploadLayout = "list" | "grid";
95
+ export type DragState = {
96
+ verdict: DragVerdict;
97
+ count: number;
98
+ room: number;
99
+ } | null;
100
+ /** How many rejected files are listed by name; the rest fold into one "n more" line. */
101
+ export declare const REJECTION_LINES = 3;
102
+ /** The rejection notice (and its announcement): the first three by name, then one "n more" line. */
103
+ export declare function rejectionLines<T extends {
104
+ name: string;
105
+ }>(m: KjunMessages, list: KjunRejectedFile<T>[], sizeText?: string): string[];
106
+ /** A drag that cannot add anything: a refused type, or no room left at all. */
107
+ export declare const dragBlocked: (drag: DragState) => boolean;
108
+ /** What the zone (empty) or the veil (filled) says and shows while files are dragged over the card. */
109
+ export declare function dragCopy(m: KjunMessages, drag: DragState, types: string, maxFiles?: number): {
110
+ title: string;
111
+ hint: string;
112
+ icon: string;
113
+ blocked: boolean;
114
+ } | null;
115
+ /** The allowed types in words: extensions and exact MIME in capitals, wildcard groups named by the messages. */
116
+ export declare function acceptText(m: KjunMessages, accept?: string): string;
117
+ /** The row's × cancels a file still waiting or uploading and removes one that finished or failed. */
118
+ export declare const removeLabel: (m: KjunMessages, file: {
119
+ name: string;
120
+ status: KjunUploadStatus;
121
+ }) => string;
122
+ /** A tile's name for assistive tech: the file name, then its state in words. */
123
+ export declare function tileLabel(m: KjunMessages, file: KjunUploadFile): string;
124
+ /** Grid columns that keep every tile at least `min` wide, and the tile width that fills the row. */
125
+ export declare function gridColumns(width: number, min: number, gap: number): {
126
+ columns: number;
127
+ tile: number;
128
+ };
@@ -0,0 +1,5 @@
1
+ export declare function trackFilterScroll(row: HTMLElement): {
2
+ /** Scrolls the first selected chip into view: at once the first time, smoothly after that. */
3
+ reveal(): void;
4
+ destroy(): void;
5
+ };
@@ -0,0 +1,5 @@
1
+ export declare function trackFilterScroll(row: HTMLElement): {
2
+ /** Scrolls the first selected chip into view: at once the first time, smoothly after that. */
3
+ reveal(): void;
4
+ destroy(): void;
5
+ };
@@ -0,0 +1,2 @@
1
+ export declare function filterSelected<T>(value: T | T[], option: T, multiple: boolean): boolean;
2
+ export declare function nextFilterValue<T>(value: T | T[], option: T, multiple: boolean): T | T[];
@@ -0,0 +1,2 @@
1
+ export declare function filterSelected<T>(value: T | T[], option: T, multiple: boolean): boolean;
2
+ export declare function nextFilterValue<T>(value: T | T[], option: T, multiple: boolean): T | T[];
@@ -0,0 +1,23 @@
1
+ /** A field holds a value when it is not empty; the number 0 is a value. */
2
+ export declare const inputHasValue: (value: string | number | null | undefined) => boolean;
3
+ /** The clear button shows only while there is a value the person can remove. */
4
+ export declare const inputShowsClear: ({ clearable, value, disabled, readOnly }: {
5
+ clearable?: boolean;
6
+ value: string | number | null | undefined;
7
+ disabled?: boolean;
8
+ readOnly?: boolean;
9
+ }) => boolean;
10
+ /** A password field the person can reveal: the type it renders with and whether the reveal button shows. */
11
+ export declare function inputReveal(type: string | undefined, revealable: boolean | undefined, revealed: boolean): {
12
+ active: boolean;
13
+ type: string | undefined;
14
+ };
15
+ /** Input's character count follows Textarea's: "length/maxLength", over the limit reads as an error. */
16
+ export declare function inputCount(value: string | number | null | undefined, maxLength?: number): {
17
+ remaining: number | null;
18
+ length: number;
19
+ text: string;
20
+ over: boolean;
21
+ };
22
+ /** How long a remote search waits after the last keystroke before it asks loadOptions (ms). */
23
+ export declare const searchLoadDelay = 300;
@@ -0,0 +1,23 @@
1
+ /** A field holds a value when it is not empty; the number 0 is a value. */
2
+ export declare const inputHasValue: (value: string | number | null | undefined) => boolean;
3
+ /** The clear button shows only while there is a value the person can remove. */
4
+ export declare const inputShowsClear: ({ clearable, value, disabled, readOnly }: {
5
+ clearable?: boolean;
6
+ value: string | number | null | undefined;
7
+ disabled?: boolean;
8
+ readOnly?: boolean;
9
+ }) => boolean;
10
+ /** A password field the person can reveal: the type it renders with and whether the reveal button shows. */
11
+ export declare function inputReveal(type: string | undefined, revealable: boolean | undefined, revealed: boolean): {
12
+ active: boolean;
13
+ type: string | undefined;
14
+ };
15
+ /** Input's character count follows Textarea's: "length/maxLength", over the limit reads as an error. */
16
+ export declare function inputCount(value: string | number | null | undefined, maxLength?: number): {
17
+ remaining: number | null;
18
+ length: number;
19
+ text: string;
20
+ over: boolean;
21
+ };
22
+ /** How long a remote search waits after the last keystroke before it asks loadOptions (ms). */
23
+ export declare const searchLoadDelay = 300;
@@ -0,0 +1,7 @@
1
+ /** "plain" drops the field surface: text edited in place, such as a document title or a note body. */
2
+ export type InputVariant = "default" | "plain";
3
+ /** The side inset and side border of a field. A plain field has neither, so its text lines up with the text around it. */
4
+ export declare function inputEdge(variant: InputVariant | undefined, padding: number): {
5
+ padding: number;
6
+ border: number;
7
+ };
@@ -0,0 +1,7 @@
1
+ /** "plain" drops the field surface: text edited in place, such as a document title or a note body. */
2
+ export type InputVariant = "default" | "plain";
3
+ /** The side inset and side border of a field. A plain field has neither, so its text lines up with the text around it. */
4
+ export declare function inputEdge(variant: InputVariant | undefined, padding: number): {
5
+ padding: number;
6
+ border: number;
7
+ };
@@ -0,0 +1,102 @@
1
+ import { type BadgeToneRoles, type BadgeVariant } from "./badge-tone.cjs";
2
+ /** What a masked amount draws in place of its digits. */
3
+ export declare const KPI_MASK = "\u2022\u2022\u2022\u2022";
4
+ /** What a missing value draws unless the app gives its own text. */
5
+ export declare const KPI_MISSING = "\u2014";
6
+ /** Digit height as a share of the font size: Native KPI skeleton bars stand this tall, like Web's 1cap. */
7
+ export declare const KPI_NUMERAL_HEIGHT = 0.72;
8
+ export type KpiDirection = 1 | -1 | 0;
9
+ export type KpiBadgeVariant = "warning" | "success" | "danger" | "price-up" | "price-down" | "info" | "neutral";
10
+ /** The parts of a KPI value the shared rules read; each platform adds its own class or color fields. */
11
+ export interface KpiNumberItem {
12
+ value?: number | string | null;
13
+ decimals?: number;
14
+ semantic?: "price" | "status";
15
+ showSign?: boolean;
16
+ formatter?: (value: number) => string;
17
+ missingText?: string;
18
+ }
19
+ /** One cached formatter per locale and precision; an undefined locale keeps the runtime's default. */
20
+ export declare function kpiNumber(value: number, decimals?: number, locale?: string): string;
21
+ /** The value as it will be shown at this precision, so direction and sign follow the drawn digits. */
22
+ export declare const kpiRound: (value: number, decimals?: number) => number;
23
+ /** null, undefined and non-finite numbers are missing, never zero. */
24
+ export declare const kpiPresent: (value: unknown) => value is number | string;
25
+ /** Up, down or flat as drawn: a number rounds at its decimals; a formatted or string value keeps its raw sign. */
26
+ export declare function kpiDirection(item: KpiNumberItem): KpiDirection;
27
+ /** The price tone a value paints, or null for neutral text. */
28
+ export declare const kpiTone: (item: KpiNumberItem) => "up" | "down" | null;
29
+ /** The value's text: missing text, the app's string or formatter, or the locale's digits with the KPI sign rule. */
30
+ export declare function kpiFormat(item: KpiNumberItem, value?: number | string | null | undefined, locale?: string): string;
31
+ export interface KpiDeltaOptions {
32
+ decimals?: number;
33
+ percentDecimals?: number;
34
+ locale?: string;
35
+ /** With the app's own delta text the digits are unknown, so direction keeps the raw sign. */
36
+ formatted?: boolean;
37
+ }
38
+ export interface KpiDeltaParts {
39
+ direction: KpiDirection;
40
+ sign: string;
41
+ number: string;
42
+ }
43
+ /** One delta number: its drawn direction, its sign and its unsigned digits. */
44
+ export declare function kpiDelta(value: number, kind: "absolute" | "percent", options?: KpiDeltaOptions): KpiDeltaParts;
45
+ /** A finite delta number, or null when the app passed nothing, null or a non-finite value. */
46
+ export declare const kpiDeltaValue: (value: number | null | undefined) => number | null;
47
+ /** The caret marks the first delta number shown, and only when it has a direction. */
48
+ export declare const kpiDeltaIcon: (enabled: boolean, direction: KpiDirection, kind: "absolute" | "percent", hasAbsolute: boolean) => boolean;
49
+ /** The delta line shows with any delta, and while loading when the app passed a delta prop at all. */
50
+ export declare const kpiShowDelta: (absolute: number | null, percent: number | null, description: string, loading: boolean, passed: object | null | undefined) => boolean;
51
+ /** Whether any price colour is painted, so the domain colour contract must be present. */
52
+ export declare function kpiHeroNeedsDomain(options: {
53
+ loading: boolean;
54
+ masked: boolean;
55
+ absolute: number | null;
56
+ percent: number | null;
57
+ decimals?: number;
58
+ percentDecimals?: number;
59
+ formatted?: boolean;
60
+ secondary: KpiNumberItem[];
61
+ }): boolean;
62
+ export declare const kpiRowNeedsDomain: (loading: boolean, masked: boolean, items: (KpiNumberItem & {
63
+ loading?: boolean;
64
+ badge?: {
65
+ variant?: string;
66
+ } | null;
67
+ })[]) => boolean;
68
+ /** Only items marked mobileSecondary fold into the summary's inline footnote; an odd last primary cell takes the full width. */
69
+ export declare function kpiSummaryLayout(items: {
70
+ mobileSecondary?: boolean;
71
+ mobileFull?: boolean;
72
+ }[]): {
73
+ secondary: boolean[];
74
+ lastFull: number;
75
+ };
76
+ /**
77
+ * The phone grid of a KpiRow outside the summary (two columns, or size="sm" wrapping in two): which column each
78
+ * cell takes and whether it starts below the first line. A mobileFull cell takes the whole line, and so does a cell
79
+ * left alone on its line (the last one, or one before a full cell), so no half cell stays empty. Web and Native
80
+ * draw the same dividers from it: a left line on the second column (not for sm), a top line below the first line.
81
+ */
82
+ export declare function kpiGridLayout(items: {
83
+ mobileFull?: boolean;
84
+ }[]): {
85
+ column: number;
86
+ full: boolean;
87
+ top: boolean;
88
+ }[];
89
+ /** A row badge is KjunBadge's tone: neutral is the secondary badge. */
90
+ export declare const kpiBadgeVariant: (variant?: KpiBadgeVariant) => BadgeVariant;
91
+ export declare const kpiBadgeRoles: (variant?: KpiBadgeVariant) => BadgeToneRoles;
92
+ /**
93
+ * Keyboard activation for a clickable cell drawn as a button: Enter acts once on key down (never on auto-repeat),
94
+ * Space acts on key up like a native button, and its key down only stops the page from scrolling.
95
+ */
96
+ export declare function kpiKeyAction(type: "keydown" | "keyup", key: string, repeat: boolean): "activate" | "prevent" | null;
97
+ /** A spoken cell: its non-empty parts in reading order. */
98
+ export declare const kpiSpoken: (...parts: (string | null | undefined | false)[]) => string;
99
+ /** Web: the CSS colour for a tone or direction, or the neutral role. */
100
+ export declare const kpiCssColor: (tone: "up" | "down" | KpiDirection | null, neutral?: string) => string;
101
+ /** Web: the percent chip's tint, the direction's soft fill or the neutral fill when flat. */
102
+ export declare const kpiCssTint: (direction: KpiDirection) => string;
@@ -0,0 +1,102 @@
1
+ import { type BadgeToneRoles, type BadgeVariant } from "./badge-tone.js";
2
+ /** What a masked amount draws in place of its digits. */
3
+ export declare const KPI_MASK = "\u2022\u2022\u2022\u2022";
4
+ /** What a missing value draws unless the app gives its own text. */
5
+ export declare const KPI_MISSING = "\u2014";
6
+ /** Digit height as a share of the font size: Native KPI skeleton bars stand this tall, like Web's 1cap. */
7
+ export declare const KPI_NUMERAL_HEIGHT = 0.72;
8
+ export type KpiDirection = 1 | -1 | 0;
9
+ export type KpiBadgeVariant = "warning" | "success" | "danger" | "price-up" | "price-down" | "info" | "neutral";
10
+ /** The parts of a KPI value the shared rules read; each platform adds its own class or color fields. */
11
+ export interface KpiNumberItem {
12
+ value?: number | string | null;
13
+ decimals?: number;
14
+ semantic?: "price" | "status";
15
+ showSign?: boolean;
16
+ formatter?: (value: number) => string;
17
+ missingText?: string;
18
+ }
19
+ /** One cached formatter per locale and precision; an undefined locale keeps the runtime's default. */
20
+ export declare function kpiNumber(value: number, decimals?: number, locale?: string): string;
21
+ /** The value as it will be shown at this precision, so direction and sign follow the drawn digits. */
22
+ export declare const kpiRound: (value: number, decimals?: number) => number;
23
+ /** null, undefined and non-finite numbers are missing, never zero. */
24
+ export declare const kpiPresent: (value: unknown) => value is number | string;
25
+ /** Up, down or flat as drawn: a number rounds at its decimals; a formatted or string value keeps its raw sign. */
26
+ export declare function kpiDirection(item: KpiNumberItem): KpiDirection;
27
+ /** The price tone a value paints, or null for neutral text. */
28
+ export declare const kpiTone: (item: KpiNumberItem) => "up" | "down" | null;
29
+ /** The value's text: missing text, the app's string or formatter, or the locale's digits with the KPI sign rule. */
30
+ export declare function kpiFormat(item: KpiNumberItem, value?: number | string | null | undefined, locale?: string): string;
31
+ export interface KpiDeltaOptions {
32
+ decimals?: number;
33
+ percentDecimals?: number;
34
+ locale?: string;
35
+ /** With the app's own delta text the digits are unknown, so direction keeps the raw sign. */
36
+ formatted?: boolean;
37
+ }
38
+ export interface KpiDeltaParts {
39
+ direction: KpiDirection;
40
+ sign: string;
41
+ number: string;
42
+ }
43
+ /** One delta number: its drawn direction, its sign and its unsigned digits. */
44
+ export declare function kpiDelta(value: number, kind: "absolute" | "percent", options?: KpiDeltaOptions): KpiDeltaParts;
45
+ /** A finite delta number, or null when the app passed nothing, null or a non-finite value. */
46
+ export declare const kpiDeltaValue: (value: number | null | undefined) => number | null;
47
+ /** The caret marks the first delta number shown, and only when it has a direction. */
48
+ export declare const kpiDeltaIcon: (enabled: boolean, direction: KpiDirection, kind: "absolute" | "percent", hasAbsolute: boolean) => boolean;
49
+ /** The delta line shows with any delta, and while loading when the app passed a delta prop at all. */
50
+ export declare const kpiShowDelta: (absolute: number | null, percent: number | null, description: string, loading: boolean, passed: object | null | undefined) => boolean;
51
+ /** Whether any price colour is painted, so the domain colour contract must be present. */
52
+ export declare function kpiHeroNeedsDomain(options: {
53
+ loading: boolean;
54
+ masked: boolean;
55
+ absolute: number | null;
56
+ percent: number | null;
57
+ decimals?: number;
58
+ percentDecimals?: number;
59
+ formatted?: boolean;
60
+ secondary: KpiNumberItem[];
61
+ }): boolean;
62
+ export declare const kpiRowNeedsDomain: (loading: boolean, masked: boolean, items: (KpiNumberItem & {
63
+ loading?: boolean;
64
+ badge?: {
65
+ variant?: string;
66
+ } | null;
67
+ })[]) => boolean;
68
+ /** Only items marked mobileSecondary fold into the summary's inline footnote; an odd last primary cell takes the full width. */
69
+ export declare function kpiSummaryLayout(items: {
70
+ mobileSecondary?: boolean;
71
+ mobileFull?: boolean;
72
+ }[]): {
73
+ secondary: boolean[];
74
+ lastFull: number;
75
+ };
76
+ /**
77
+ * The phone grid of a KpiRow outside the summary (two columns, or size="sm" wrapping in two): which column each
78
+ * cell takes and whether it starts below the first line. A mobileFull cell takes the whole line, and so does a cell
79
+ * left alone on its line (the last one, or one before a full cell), so no half cell stays empty. Web and Native
80
+ * draw the same dividers from it: a left line on the second column (not for sm), a top line below the first line.
81
+ */
82
+ export declare function kpiGridLayout(items: {
83
+ mobileFull?: boolean;
84
+ }[]): {
85
+ column: number;
86
+ full: boolean;
87
+ top: boolean;
88
+ }[];
89
+ /** A row badge is KjunBadge's tone: neutral is the secondary badge. */
90
+ export declare const kpiBadgeVariant: (variant?: KpiBadgeVariant) => BadgeVariant;
91
+ export declare const kpiBadgeRoles: (variant?: KpiBadgeVariant) => BadgeToneRoles;
92
+ /**
93
+ * Keyboard activation for a clickable cell drawn as a button: Enter acts once on key down (never on auto-repeat),
94
+ * Space acts on key up like a native button, and its key down only stops the page from scrolling.
95
+ */
96
+ export declare function kpiKeyAction(type: "keydown" | "keyup", key: string, repeat: boolean): "activate" | "prevent" | null;
97
+ /** A spoken cell: its non-empty parts in reading order. */
98
+ export declare const kpiSpoken: (...parts: (string | null | undefined | false)[]) => string;
99
+ /** Web: the CSS colour for a tone or direction, or the neutral role. */
100
+ export declare const kpiCssColor: (tone: "up" | "down" | KpiDirection | null, neutral?: string) => string;
101
+ /** Web: the percent chip's tint, the direction's soft fill or the neutral fill when flat. */
102
+ export declare const kpiCssTint: (direction: KpiDirection) => string;
@@ -28,12 +28,13 @@ export declare function createLayerState(): {
28
28
  top: () => LayerEntry | undefined;
29
29
  topPopup: () => LayerEntry | undefined;
30
30
  windowOf: (id?: string) => string | undefined;
31
+ markRestoredFocus(target: FocusTarget): void;
31
32
  isRestoredFocus(target?: FocusTarget | null): boolean;
32
33
  clearRestoredFocus(target?: FocusTarget | null): void;
33
34
  markClosing(id: string): void;
34
35
  subscribe(listener: () => void): () => void;
35
36
  snapshot: () => number;
36
- open(id: string, kind: LayerKind, parent: string | undefined, dismissCallback: () => void, returnTarget?: FocusTarget | null): LayerEntry;
37
+ open(id: string, kind: LayerKind, parent: string | undefined, dismissCallback: () => void, returnTarget?: FocusTarget | null, defaultFocus?: boolean): LayerEntry;
37
38
  remove(id: string, focused?: FocusTarget | null): FocusTarget | null | undefined;
38
39
  requestClose(id: string): void;
39
40
  isActive(id: string): boolean;
@@ -28,12 +28,13 @@ export declare function createLayerState(): {
28
28
  top: () => LayerEntry | undefined;
29
29
  topPopup: () => LayerEntry | undefined;
30
30
  windowOf: (id?: string) => string | undefined;
31
+ markRestoredFocus(target: FocusTarget): void;
31
32
  isRestoredFocus(target?: FocusTarget | null): boolean;
32
33
  clearRestoredFocus(target?: FocusTarget | null): void;
33
34
  markClosing(id: string): void;
34
35
  subscribe(listener: () => void): () => void;
35
36
  snapshot: () => number;
36
- open(id: string, kind: LayerKind, parent: string | undefined, dismissCallback: () => void, returnTarget?: FocusTarget | null): LayerEntry;
37
+ open(id: string, kind: LayerKind, parent: string | undefined, dismissCallback: () => void, returnTarget?: FocusTarget | null, defaultFocus?: boolean): LayerEntry;
37
38
  remove(id: string, focused?: FocusTarget | null): FocusTarget | null | undefined;
38
39
  requestClose(id: string): void;
39
40
  isActive(id: string): boolean;