@krizaka/ui 3.54.0 → 3.55.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 (495) hide show
  1. package/README.md +1 -0
  2. package/dist/account-menu.d.ts +6 -2
  3. package/dist/account-menu.js +8 -1
  4. package/dist/account-menu.js.map +1 -1
  5. package/dist/account-settings.js +28 -88
  6. package/dist/account-settings.js.map +1 -1
  7. package/dist/anatomy-plate.d.ts +4 -1
  8. package/dist/anatomy-plate.js +4 -0
  9. package/dist/anatomy-plate.js.map +1 -1
  10. package/dist/app-header/search.d.ts +63 -0
  11. package/dist/app-header/search.js +70 -0
  12. package/dist/app-header/search.js.map +1 -0
  13. package/dist/app-header.d.ts +88 -4
  14. package/dist/app-header.js +63 -5
  15. package/dist/app-header.js.map +1 -1
  16. package/dist/app-shell.js +31 -40
  17. package/dist/app-shell.js.map +1 -1
  18. package/dist/argument-card.js +3 -3
  19. package/dist/bird-plate.d.ts +3 -1
  20. package/dist/bird-plate.js +2 -2
  21. package/dist/bird-plate.js.map +1 -1
  22. package/dist/blocks.css +162 -27
  23. package/dist/chat.js +2 -2
  24. package/dist/chat.js.map +1 -1
  25. package/dist/checkbox.js +1 -1
  26. package/dist/checkbox.js.map +1 -1
  27. package/dist/chip.js +5 -98
  28. package/dist/chip.js.map +1 -1
  29. package/dist/choice-grid.js +28 -88
  30. package/dist/choice-grid.js.map +1 -1
  31. package/dist/{chunk-YGIN2YIY.js → chunk-3X3OF4TI.js} +2 -2
  32. package/dist/chunk-3X3OF4TI.js.map +1 -0
  33. package/dist/chunk-5VEVYDVC.js +11 -0
  34. package/dist/chunk-5VEVYDVC.js.map +1 -0
  35. package/dist/chunk-7U5TXA5Q.js +105 -0
  36. package/dist/chunk-7U5TXA5Q.js.map +1 -0
  37. package/dist/{chunk-KBQD6HE3.js → chunk-AEP3K4YD.js} +3 -3
  38. package/dist/{chunk-KBQD6HE3.js.map → chunk-AEP3K4YD.js.map} +1 -1
  39. package/dist/chunk-BDIU5LZB.js +18 -0
  40. package/dist/chunk-BDIU5LZB.js.map +1 -0
  41. package/dist/chunk-CSRKYZ53.js +39 -0
  42. package/dist/chunk-CSRKYZ53.js.map +1 -0
  43. package/dist/chunk-HEKDKM5Y.js +128 -0
  44. package/dist/chunk-HEKDKM5Y.js.map +1 -0
  45. package/dist/chunk-KGLRZMCY.js +16 -0
  46. package/dist/chunk-KGLRZMCY.js.map +1 -0
  47. package/dist/chunk-KID32IRJ.js +18 -0
  48. package/dist/chunk-KID32IRJ.js.map +1 -0
  49. package/dist/{chunk-ZQW7LF4Y.js → chunk-OIMXKRXF.js} +2 -2
  50. package/dist/{chunk-YHKTYFOQ.js → chunk-QWKCNSPF.js} +271 -47
  51. package/dist/chunk-QWKCNSPF.js.map +1 -0
  52. package/dist/{chunk-4LYKBSOG.js → chunk-USPOIQV5.js} +2 -2
  53. package/dist/chunk-USPOIQV5.js.map +1 -0
  54. package/dist/{chunk-7NRSPHAF.js → chunk-VB7MWE2N.js} +2 -2
  55. package/dist/{chunk-7NRSPHAF.js.map → chunk-VB7MWE2N.js.map} +1 -1
  56. package/dist/chunk-VIPSZXO4.js +103 -0
  57. package/dist/chunk-VIPSZXO4.js.map +1 -0
  58. package/dist/chunk-YCZ7N6Q6.js +385 -0
  59. package/dist/chunk-YCZ7N6Q6.js.map +1 -0
  60. package/dist/code-block.js +81 -98
  61. package/dist/code-block.js.map +1 -1
  62. package/dist/combobox.js +2 -2
  63. package/dist/component-page.d.ts +4 -1
  64. package/dist/component-page.js +5 -0
  65. package/dist/component-page.js.map +1 -1
  66. package/dist/continue-prompt.d.ts +4 -1
  67. package/dist/continue-prompt.js +4 -0
  68. package/dist/continue-prompt.js.map +1 -1
  69. package/dist/data-table.d.ts +60 -4
  70. package/dist/data-table.js +19 -7
  71. package/dist/date-picker.js +2 -2
  72. package/dist/date-picker.js.map +1 -1
  73. package/dist/detail-layout.d.ts +28 -17
  74. package/dist/detail-layout.js +73 -16
  75. package/dist/detail-layout.js.map +1 -1
  76. package/dist/doodle.d.ts +21 -0
  77. package/dist/doodle.js +39 -0
  78. package/dist/doodle.js.map +1 -0
  79. package/dist/drop-overlay.d.ts +12 -4
  80. package/dist/drop-overlay.js +16 -6
  81. package/dist/drop-overlay.js.map +1 -1
  82. package/dist/elephant.d.ts +2 -0
  83. package/dist/elephant.js +4 -0
  84. package/dist/elephant.js.map +1 -1
  85. package/dist/field.js +1 -1
  86. package/dist/field.js.map +1 -1
  87. package/dist/filter-bar.js +2 -2
  88. package/dist/force-update-screen.d.ts +5 -1
  89. package/dist/force-update-screen.js +4 -0
  90. package/dist/force-update-screen.js.map +1 -1
  91. package/dist/gallery-page.d.ts +4 -1
  92. package/dist/gallery-page.js +4 -0
  93. package/dist/gallery-page.js.map +1 -1
  94. package/dist/genui.js +5 -5
  95. package/dist/image-cropper.d.ts +10 -2
  96. package/dist/image-cropper.js +4 -0
  97. package/dist/image-cropper.js.map +1 -1
  98. package/dist/kanban.d.ts +3 -0
  99. package/dist/kanban.js +4 -0
  100. package/dist/kanban.js.map +1 -1
  101. package/dist/landscape.d.ts +4 -1
  102. package/dist/landscape.js +4 -0
  103. package/dist/landscape.js.map +1 -1
  104. package/dist/list.js +1 -1
  105. package/dist/maintenance-screen.d.ts +5 -1
  106. package/dist/maintenance-screen.js +4 -0
  107. package/dist/maintenance-screen.js.map +1 -1
  108. package/dist/map.js +6 -0
  109. package/dist/map.js.map +1 -1
  110. package/dist/markdown.d.ts +5 -1
  111. package/dist/markdown.js +12 -5
  112. package/dist/markdown.js.map +1 -1
  113. package/dist/match-dialog.d.ts +4 -1
  114. package/dist/match-dialog.js +4 -0
  115. package/dist/match-dialog.js.map +1 -1
  116. package/dist/media-capture.d.ts +6 -1
  117. package/dist/media-capture.js +4 -0
  118. package/dist/media-capture.js.map +1 -1
  119. package/dist/meter.js +5 -121
  120. package/dist/meter.js.map +1 -1
  121. package/dist/native/map.js +6 -0
  122. package/dist/native/map.js.map +1 -1
  123. package/dist/native/markdown.d.ts +9 -2
  124. package/dist/native/markdown.js +46 -7
  125. package/dist/native/markdown.js.map +1 -1
  126. package/dist/native/media-capture.d.ts +1 -0
  127. package/dist/native/media-capture.js +5 -0
  128. package/dist/native/media-capture.js.map +1 -1
  129. package/dist/native/vertical-video.d.ts +8 -2
  130. package/dist/native/vertical-video.js +6 -0
  131. package/dist/native/vertical-video.js.map +1 -1
  132. package/dist/native.d.ts +94 -4
  133. package/dist/native.js +1236 -1110
  134. package/dist/native.js.map +1 -1
  135. package/dist/nav-bar/me.d.ts +32 -0
  136. package/dist/nav-bar/me.js +23 -0
  137. package/dist/nav-bar/me.js.map +1 -0
  138. package/dist/nav-bar.d.ts +60 -2
  139. package/dist/nav-bar.js +92 -48
  140. package/dist/nav-bar.js.map +1 -1
  141. package/dist/notification-preferences.d.ts +151 -0
  142. package/dist/notification-preferences.js +77 -0
  143. package/dist/notification-preferences.js.map +1 -0
  144. package/dist/page-header.js +1 -1
  145. package/dist/page-header.js.map +1 -1
  146. package/dist/pointer-light.js +5 -0
  147. package/dist/pointer-light.js.map +1 -1
  148. package/dist/product-page.d.ts +4 -1
  149. package/dist/product-page.js +4 -0
  150. package/dist/product-page.js.map +1 -1
  151. package/dist/profile-card.d.ts +119 -1
  152. package/dist/profile-card.js +68 -21
  153. package/dist/profile-card.js.map +1 -1
  154. package/dist/promise-card.d.ts +4 -1
  155. package/dist/promise-card.js +4 -0
  156. package/dist/promise-card.js.map +1 -1
  157. package/dist/quota-meter.d.ts +113 -0
  158. package/dist/quota-meter.js +58 -0
  159. package/dist/quota-meter.js.map +1 -0
  160. package/dist/radio-group.js +6 -8
  161. package/dist/radio-group.js.map +1 -1
  162. package/dist/rail-nav.d.ts +18 -2
  163. package/dist/rail-nav.js +25 -2
  164. package/dist/rail-nav.js.map +1 -1
  165. package/dist/retro-tv.d.ts +30 -0
  166. package/dist/retro-tv.js +124 -0
  167. package/dist/retro-tv.js.map +1 -0
  168. package/dist/router.d.ts +12 -1
  169. package/dist/router.js +85 -8
  170. package/dist/router.js.map +1 -1
  171. package/dist/scroll-stage.d.ts +5 -1
  172. package/dist/scroll-stage.js +5 -0
  173. package/dist/scroll-stage.js.map +1 -1
  174. package/dist/search-field.js +1 -1
  175. package/dist/showcase.d.ts +9 -2
  176. package/dist/showcase.js +5 -0
  177. package/dist/showcase.js.map +1 -1
  178. package/dist/signature.d.ts +19 -0
  179. package/dist/signature.js +39 -0
  180. package/dist/signature.js.map +1 -0
  181. package/dist/site-footer.js +1 -1
  182. package/dist/sites.js +1 -1
  183. package/dist/sites.js.map +1 -1
  184. package/dist/slot.d.ts +1 -1
  185. package/dist/stat.js +1 -1
  186. package/dist/stat.js.map +1 -1
  187. package/dist/status-page.d.ts +4 -1
  188. package/dist/status-page.js +5 -0
  189. package/dist/status-page.js.map +1 -1
  190. package/dist/stuck.d.ts +27 -0
  191. package/dist/stuck.js +26 -0
  192. package/dist/stuck.js.map +1 -0
  193. package/dist/swipe-deck.d.ts +9 -2
  194. package/dist/swipe-deck.js +5 -0
  195. package/dist/swipe-deck.js.map +1 -1
  196. package/dist/switch.js +4 -32
  197. package/dist/switch.js.map +1 -1
  198. package/dist/tabs.d.ts +47 -8
  199. package/dist/tabs.js +62 -12
  200. package/dist/tabs.js.map +1 -1
  201. package/dist/tag-input.js +2 -2
  202. package/dist/tag-selector.js +1 -1
  203. package/dist/terminal-replay.d.ts +4 -1
  204. package/dist/terminal-replay.js +4 -0
  205. package/dist/terminal-replay.js.map +1 -1
  206. package/dist/tree-view.js +4 -0
  207. package/dist/tree-view.js.map +1 -1
  208. package/dist/update-prompt.d.ts +5 -1
  209. package/dist/update-prompt.js +4 -0
  210. package/dist/update-prompt.js.map +1 -1
  211. package/dist/video-player.js +7 -376
  212. package/dist/video-player.js.map +1 -1
  213. package/dist/video-trimmer.d.ts +6 -1
  214. package/dist/video-trimmer.js +4 -0
  215. package/dist/video-trimmer.js.map +1 -1
  216. package/package.json +141 -29
  217. package/registry/account-menu.json +9 -8
  218. package/registry/account-settings.json +2 -2
  219. package/registry/achievement.json +3 -4
  220. package/registry/action-bar.json +3 -3
  221. package/registry/action-sheet.json +1 -0
  222. package/registry/activity-feed.json +2 -1
  223. package/registry/agenda.json +1 -1
  224. package/registry/alert.json +1 -1
  225. package/registry/anatomy-plate.json +13 -5
  226. package/registry/app-header.json +470 -23
  227. package/registry/app-shell.json +2 -2
  228. package/registry/argument-card.json +1 -1
  229. package/registry/audio-player.json +1 -1
  230. package/registry/auth-layout.json +1 -1
  231. package/registry/avatar.json +3 -2
  232. package/registry/badge.json +2 -1
  233. package/registry/bird-plate.json +16 -2
  234. package/registry/button.json +7 -6
  235. package/registry/captcha.json +1 -1
  236. package/registry/card-grid.json +1 -1
  237. package/registry/card.json +7 -6
  238. package/registry/catalogue-page.json +3 -4
  239. package/registry/changelog-page.json +3 -5
  240. package/registry/chapter.json +1 -1
  241. package/registry/chat.json +3 -2
  242. package/registry/checkbox.json +4 -3
  243. package/registry/chip-link.json +2 -2
  244. package/registry/chip-row.json +2 -2
  245. package/registry/chip.json +3 -2
  246. package/registry/choice-grid.json +3 -4
  247. package/registry/code-block.json +1 -1
  248. package/registry/combobox.json +3 -2
  249. package/registry/command.json +2 -2
  250. package/registry/comparison-table.json +1 -1
  251. package/registry/component-page.json +14 -5
  252. package/registry/confirm-button.json +4 -4
  253. package/registry/contact-page.json +1 -1
  254. package/registry/continue-prompt.json +13 -5
  255. package/registry/countdown.json +4 -3
  256. package/registry/cover-hero.json +3 -4
  257. package/registry/cta-panel.json +1 -1
  258. package/registry/dashboard-layout.json +1 -1
  259. package/registry/data-table.json +63 -7
  260. package/registry/date-picker.json +5 -4
  261. package/registry/decision-list.json +1 -1
  262. package/registry/description-list.json +2 -1
  263. package/registry/detail-layout.json +30 -6
  264. package/registry/dialog.json +7 -6
  265. package/registry/docs-article-page.json +3 -4
  266. package/registry/docs-hub-page.json +1 -1
  267. package/registry/docs-layout.json +1 -1
  268. package/registry/docs-nav.json +1 -1
  269. package/registry/document-viewer.json +3 -5
  270. package/registry/doodle.json +209 -0
  271. package/registry/drop-overlay.json +30 -16
  272. package/registry/dropdown-menu.json +2 -2
  273. package/registry/elephant.json +15 -7
  274. package/registry/empty-state.json +2 -1
  275. package/registry/engine-flow.json +1 -1
  276. package/registry/error-page.json +3 -5
  277. package/registry/examples/app-header/family.d.ts +4 -0
  278. package/registry/examples/app-header/family.js +41 -0
  279. package/registry/examples/app-header/family.tsx +37 -0
  280. package/registry/examples/app-header/native/family.d.ts +4 -0
  281. package/registry/examples/app-header/native/family.dark.png +0 -0
  282. package/registry/examples/app-header/native/family.js +25 -0
  283. package/registry/examples/app-header/native/family.light.png +0 -0
  284. package/registry/examples/app-header/native/family.tsx +33 -0
  285. package/registry/examples/data-table/applicant-files.d.ts +4 -0
  286. package/registry/examples/data-table/applicant-files.js +24 -0
  287. package/registry/examples/data-table/applicant-files.tsx +23 -0
  288. package/registry/examples/data-table/checks.d.ts +4 -0
  289. package/registry/examples/data-table/checks.js +25 -0
  290. package/registry/examples/data-table/checks.tsx +24 -0
  291. package/registry/examples/detail-layout/profile.d.ts +4 -0
  292. package/registry/examples/detail-layout/profile.js +26 -0
  293. package/registry/examples/detail-layout/profile.tsx +21 -0
  294. package/registry/examples/doodle/kinds.d.ts +4 -0
  295. package/registry/examples/doodle/kinds.js +17 -0
  296. package/registry/examples/doodle/kinds.tsx +14 -0
  297. package/registry/examples/doodle/margin.d.ts +4 -0
  298. package/registry/examples/doodle/margin.js +17 -0
  299. package/registry/examples/doodle/margin.tsx +17 -0
  300. package/registry/examples/markdown/native/basic.dark.png +0 -0
  301. package/registry/examples/markdown/native/basic.light.png +0 -0
  302. package/registry/examples/markdown/native/wide-table.d.ts +4 -0
  303. package/registry/examples/markdown/native/wide-table.dark.png +0 -0
  304. package/registry/examples/markdown/native/wide-table.js +23 -0
  305. package/registry/examples/markdown/native/wide-table.light.png +0 -0
  306. package/registry/examples/markdown/native/wide-table.tsx +22 -0
  307. package/registry/examples/markdown/wide-table.d.ts +4 -0
  308. package/registry/examples/markdown/wide-table.js +28 -0
  309. package/registry/examples/markdown/wide-table.tsx +23 -0
  310. package/registry/examples/nav-bar/family-product.js +2 -4
  311. package/registry/examples/nav-bar/family-product.tsx +3 -5
  312. package/registry/examples/notification-preferences/default.d.ts +4 -0
  313. package/registry/examples/notification-preferences/default.js +29 -0
  314. package/registry/examples/notification-preferences/default.tsx +28 -0
  315. package/registry/examples/profile-card/banner.d.ts +4 -0
  316. package/registry/examples/profile-card/banner.js +28 -0
  317. package/registry/examples/profile-card/banner.tsx +24 -0
  318. package/registry/examples/profile-card/native/banner.d.ts +4 -0
  319. package/registry/examples/profile-card/native/banner.dark.png +0 -0
  320. package/registry/examples/profile-card/native/banner.js +22 -0
  321. package/registry/examples/profile-card/native/banner.light.png +0 -0
  322. package/registry/examples/profile-card/native/banner.tsx +18 -0
  323. package/registry/examples/quota-meter/default.d.ts +4 -0
  324. package/registry/examples/quota-meter/default.js +26 -0
  325. package/registry/examples/quota-meter/default.tsx +20 -0
  326. package/registry/examples/quota-meter/full.d.ts +4 -0
  327. package/registry/examples/quota-meter/full.js +25 -0
  328. package/registry/examples/quota-meter/full.tsx +18 -0
  329. package/registry/examples/rail-nav/shortcuts.d.ts +4 -0
  330. package/registry/examples/rail-nav/shortcuts.js +49 -0
  331. package/registry/examples/rail-nav/shortcuts.tsx +40 -0
  332. package/registry/examples/retro-tv/cabinet.d.ts +4 -0
  333. package/registry/examples/retro-tv/cabinet.js +12 -0
  334. package/registry/examples/retro-tv/cabinet.tsx +7 -0
  335. package/registry/examples/retro-tv/portable.d.ts +4 -0
  336. package/registry/examples/retro-tv/portable.js +12 -0
  337. package/registry/examples/retro-tv/portable.tsx +7 -0
  338. package/registry/examples/signature/both.d.ts +4 -0
  339. package/registry/examples/signature/both.js +11 -0
  340. package/registry/examples/signature/both.tsx +6 -0
  341. package/registry/examples/signature/variants.d.ts +4 -0
  342. package/registry/examples/signature/variants.js +14 -0
  343. package/registry/examples/signature/variants.tsx +11 -0
  344. package/registry/examples/stuck/card.d.ts +4 -0
  345. package/registry/examples/stuck/card.js +13 -0
  346. package/registry/examples/stuck/card.tsx +14 -0
  347. package/registry/examples/stuck/holds.d.ts +4 -0
  348. package/registry/examples/stuck/holds.js +12 -0
  349. package/registry/examples/stuck/holds.tsx +16 -0
  350. package/registry/examples/stuck/tag.d.ts +4 -0
  351. package/registry/examples/stuck/tag.js +12 -0
  352. package/registry/examples/stuck/tag.tsx +13 -0
  353. package/registry/examples/tabs/binder.d.ts +4 -0
  354. package/registry/examples/tabs/binder.js +22 -0
  355. package/registry/examples/tabs/binder.tsx +20 -0
  356. package/registry/examples/tabs/native/binder.d.ts +4 -0
  357. package/registry/examples/tabs/native/binder.dark.png +0 -0
  358. package/registry/examples/tabs/native/binder.js +26 -0
  359. package/registry/examples/tabs/native/binder.light.png +0 -0
  360. package/registry/examples/tabs/native/binder.tsx +22 -0
  361. package/registry/fab.json +1 -0
  362. package/registry/field.json +3 -2
  363. package/registry/file-upload.json +6 -11
  364. package/registry/filter-bar.json +2 -2
  365. package/registry/flock.json +3 -4
  366. package/registry/footnote.json +2 -3
  367. package/registry/force-update-screen.json +14 -5
  368. package/registry/form.json +5 -4
  369. package/registry/gallery-page.json +14 -5
  370. package/registry/genui.json +2 -2
  371. package/registry/glossary-term.json +1 -1
  372. package/registry/glossary.json +1 -1
  373. package/registry/glow-card.json +2 -2
  374. package/registry/goal-gauge.json +2 -1
  375. package/registry/header.json +1 -0
  376. package/registry/how-it-works-page.json +3 -5
  377. package/registry/image-cropper.json +13 -5
  378. package/registry/image-viewer.json +3 -4
  379. package/registry/index.json +301 -87
  380. package/registry/iso.json +1 -1
  381. package/registry/kanban.json +13 -5
  382. package/registry/kbd.json +1 -1
  383. package/registry/kpi-explained.json +2 -2
  384. package/registry/landing-page.json +3 -5
  385. package/registry/landscape.json +13 -5
  386. package/registry/language-switch.json +1 -1
  387. package/registry/legal-page.json +1 -1
  388. package/registry/link-card.json +1 -1
  389. package/registry/list.json +2 -1
  390. package/registry/loader.json +2 -1
  391. package/registry/longform-page.json +1 -1
  392. package/registry/maintenance-screen.json +14 -5
  393. package/registry/map.json +3 -2
  394. package/registry/markdown.json +86 -9
  395. package/registry/marketing-layout.json +1 -1
  396. package/registry/marquee.json +1 -1
  397. package/registry/mascot-quote.json +1 -1
  398. package/registry/mascot-state.json +12 -11
  399. package/registry/mascots.json +2 -1
  400. package/registry/match-dialog.json +14 -5
  401. package/registry/media-capture.json +14 -5
  402. package/registry/media-gallery.json +3 -5
  403. package/registry/media-grid.json +1 -1
  404. package/registry/media-picker.json +2 -3
  405. package/registry/meta-row.json +2 -1
  406. package/registry/meter.json +4 -3
  407. package/registry/nav-bar.json +100 -9
  408. package/registry/next-actions.json +1 -1
  409. package/registry/notification-preferences.json +250 -0
  410. package/registry/number-ticker.json +2 -1
  411. package/registry/onboarding.json +1 -0
  412. package/registry/opening-hours.json +1 -1
  413. package/registry/otp-input.json +1 -0
  414. package/registry/page-header.json +2 -2
  415. package/registry/page-hero.json +1 -1
  416. package/registry/page-index.json +1 -1
  417. package/registry/page.json +3 -3
  418. package/registry/pagination.json +2 -1
  419. package/registry/permission-prompt.json +2 -2
  420. package/registry/photo-grid.json +4 -4
  421. package/registry/pointer-light.json +6 -2
  422. package/registry/popover.json +2 -2
  423. package/registry/pricing-page.json +4 -6
  424. package/registry/product-page.json +14 -5
  425. package/registry/profile-card.json +232 -8
  426. package/registry/progress.json +4 -3
  427. package/registry/promise-card.json +13 -5
  428. package/registry/pull-to-refresh.json +1 -0
  429. package/registry/quota-meter.json +308 -0
  430. package/registry/radio-group.json +4 -3
  431. package/registry/rail-nav.json +48 -10
  432. package/registry/recipes.json +1 -1
  433. package/registry/retro-tv.json +478 -0
  434. package/registry/router.json +3 -3
  435. package/registry/screen.json +1 -0
  436. package/registry/scroll-stage.json +14 -5
  437. package/registry/search-field.json +3 -2
  438. package/registry/section-backdrop.json +1 -1
  439. package/registry/segmented.json +1 -0
  440. package/registry/separator.json +2 -2
  441. package/registry/service-card.json +1 -1
  442. package/registry/settings-layout.json +2 -1
  443. package/registry/showcase.json +14 -5
  444. package/registry/signature.json +185 -0
  445. package/registry/site-footer.json +3 -3
  446. package/registry/sites.json +2 -2
  447. package/registry/skeleton.json +2 -1
  448. package/registry/skip-link.json +1 -1
  449. package/registry/slider.json +5 -4
  450. package/registry/slot-picker.json +1 -1
  451. package/registry/slot.json +2 -2
  452. package/registry/specimen-tag.json +1 -1
  453. package/registry/spinner.json +4 -3
  454. package/registry/splash-handoff.json +1 -0
  455. package/registry/split-view.json +1 -1
  456. package/registry/stage-banner.json +2 -3
  457. package/registry/stat.json +2 -2
  458. package/registry/status-page.json +13 -5
  459. package/registry/step-progress.json +2 -1
  460. package/registry/step-showcase.json +3 -5
  461. package/registry/stepper.json +2 -1
  462. package/registry/sticky-action.json +1 -1
  463. package/registry/stuck.json +219 -0
  464. package/registry/swipe-deck.json +14 -5
  465. package/registry/swipeable-row.json +1 -0
  466. package/registry/switch.json +3 -2
  467. package/registry/tab-bar.json +1 -0
  468. package/registry/tabs.json +154 -22
  469. package/registry/tag-input.json +1 -1
  470. package/registry/tag-selector.json +2 -1
  471. package/registry/taped-photo.json +1 -1
  472. package/registry/terminal-replay.json +14 -5
  473. package/registry/text-style.json +5 -5
  474. package/registry/theme.json +2 -1
  475. package/registry/toast.json +2 -1
  476. package/registry/toc.json +1 -1
  477. package/registry/tooltip.json +2 -2
  478. package/registry/tree-view.json +6 -2
  479. package/registry/txt.json +1 -0
  480. package/registry/update-prompt.json +14 -5
  481. package/registry/upload-queue.json +1 -1
  482. package/registry/verified-badge.json +6 -6
  483. package/registry/vertical-video.json +8 -3
  484. package/registry/video-player.json +5 -6
  485. package/registry/video-trimmer.json +13 -5
  486. package/registry/virtual.json +2 -2
  487. package/registry/waveform.json +4 -3
  488. package/dist/chunk-4LYKBSOG.js.map +0 -1
  489. package/dist/chunk-HHFWK2HH.js +0 -163
  490. package/dist/chunk-HHFWK2HH.js.map +0 -1
  491. package/dist/chunk-R3LTSMS5.js +0 -75
  492. package/dist/chunk-R3LTSMS5.js.map +0 -1
  493. package/dist/chunk-YGIN2YIY.js.map +0 -1
  494. package/dist/chunk-YHKTYFOQ.js.map +0 -1
  495. /package/dist/{chunk-ZQW7LF4Y.js.map → chunk-OIMXKRXF.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/combobox/combobox.tsx"],"sourcesContent":["// Client. The ARIA 1.2 combobox (`../listbox`): a text input that filters a listbox, the focus never leaves the input\n// (`aria-activedescendant`), the number of results announced in a polite live region. Static options filtered here,\n// or `onSearch` (debounced, the previous request aborted) for a server's; one value or several (chips, Backspace\n// removes the last), and new values created from the query when `creatable`.\nimport { useDebouncedCallback } from \"@krizaka/pacer/react\";\nimport * as React from \"react\";\nimport { tv } from \"tailwind-variants\";\n\nimport { Chip } from \"../chip\";\nimport { CheckGlyph, ChevronGlyph, CloseGlyph, PlusGlyph } from \"../glyphs\";\nimport { useListbox } from \"../listbox\";\nimport { useControllable } from \"../media\";\n\nexport const combobox = tv({\n slots: {\n root: \"relative flex w-full flex-col gap-1.5\",\n label: \"text-xs font-semibold text-fg-secondary\",\n control:\n \"flex min-h-11 w-full flex-wrap items-center gap-1.5 rounded-lg border border-border-default bg-surface-2 py-1.5 pl-2 pr-1 text-sm text-fg \" +\n \"transition-[border-color,box-shadow] focus-within:border-accent focus-within:ring-2 focus-within:ring-ring \" +\n \"data-[invalid]:border-danger data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50\",\n input: \"h-8 min-w-24 flex-1 bg-transparent px-1 text-sm text-fg outline-hidden placeholder:text-fg-muted disabled:cursor-not-allowed\",\n icon:\n \"inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md text-fg-secondary hover:bg-surface-3 hover:text-fg \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\",\n list: \"absolute inset-x-0 top-full z-50 mt-1 max-h-64 overflow-y-auto rounded-lg border border-border-default bg-surface-2 p-1 shadow-lg\",\n option:\n \"flex cursor-pointer select-none items-center gap-2.5 rounded-md px-2.5 py-2 text-sm text-fg \" +\n \"data-[active]:bg-surface-3 aria-disabled:cursor-not-allowed aria-disabled:opacity-40\",\n check: \"h-4 w-4 shrink-0 text-fg-accent\",\n description: \"block text-xs text-fg-secondary\",\n status: \"px-2.5 py-3 text-sm text-fg-secondary\",\n hint: \"text-xs text-fg-secondary\",\n error: \"flex items-center gap-1.5 text-xs font-medium text-fg-danger before:h-1.5 before:w-1.5 before:shrink-0 before:rounded-full before:bg-danger\",\n },\n});\n\nexport type ComboboxOption = {\n /** What the app stores. */\n value: string;\n /** What the person reads, passed translated. */\n label: string;\n /** A second line under the label. */\n description?: string;\n /** Shown but not choosable. */\n disabled?: boolean;\n};\n\nexport type ComboboxLabels = {\n /** No option matches (\"No results\"). */\n empty: string;\n /** While `onSearch` runs (\"Searching…\"). */\n loading: string;\n /** `onSearch` failed (\"Search unavailable\"). */\n error: string;\n /** The option that creates a value: `(query) => \"Create “\" + query + \"”\"`. */\n create: (query: string) => string;\n /** A chip's remove button: `(label) => \"Remove \" + label`. */\n remove: (label: string) => string;\n /** The button that empties a single choice (\"Clear\"). */\n clear: string;\n /** The button that opens the list (\"Show options\"). */\n toggle: string;\n /** Announced when the results change: `(n) => n + \" results\"`. */\n results: (count: number) => string;\n};\n\nexport const comboboxLabels: ComboboxLabels = {\n empty: \"No results\",\n loading: \"Searching…\",\n error: \"Search unavailable\",\n create: (query) => `Create “${query}”`,\n remove: (label) => `Remove ${label}`,\n clear: \"Clear\",\n toggle: \"Show options\",\n results: (count) => (count === 1 ? \"1 result\" : `${count} results`),\n};\n\ntype BaseProps = {\n /** The visible label of the field, passed translated (also its accessible name). */\n label: string;\n /** Hides the label visually, keeping it as the accessible name (a search bar with its own context). */\n hideLabel?: boolean;\n /** The options, filtered as the person types (by `filter`). */\n options?: readonly ComboboxOption[];\n /** Fetches the options for a query (debounced by `debounce`); the `signal` aborts when a newer query starts. */\n onSearch?: (query: string, signal: AbortSignal) => Promise<readonly ComboboxOption[]>;\n /** The wait, in ms, between the last key and `onSearch`. Default 250. */\n debounce?: number;\n /** Whether an option matches a query. Default: its label contains the query, ignoring case and accents. */\n filter?: (option: ComboboxOption, query: string) => boolean;\n /** Offers to create the query as a new value when no option has that exact label. */\n creatable?: boolean;\n /** Turns a query into the created option (an id from the server…). Default `{ value: query, label: query }`. */\n onCreate?: (query: string) => ComboboxOption;\n /** Keys that create the query at once, as Enter does (`[\",\"]` for tags); a paste is split on them too. */\n separators?: readonly string[];\n /** The input's placeholder, passed translated. */\n placeholder?: string;\n /** A help text under the field. */\n hint?: string;\n /** An error under the field: marks it invalid and is read with it. */\n error?: string;\n /** Not available. */\n disabled?: boolean;\n /** The name of a hidden input holding the value(s), for a plain `<form>` post. */\n name?: string;\n /** The words, passed translated; English by default. */\n labels?: Partial<ComboboxLabels>;\n /** Classes merged on the root. */\n className?: string;\n /** The id of the text input (default: generated). */\n id?: string;\n};\n\ntype SingleProps = BaseProps & {\n /** One value (default) or several. */\n multiple?: false;\n /** The chosen option (controlled), `null` for none. */\n value?: ComboboxOption | null;\n /** The chosen option at first, uncontrolled. */\n defaultValue?: ComboboxOption | null;\n /** Called with the chosen option, or `null` when it is cleared. */\n onValueChange?: (value: ComboboxOption | null) => void;\n /** Most options that can be chosen (several values only). */\n maxSelected?: never;\n};\n\ntype MultipleProps = BaseProps & {\n /** Several values, shown as chips. */\n multiple: true;\n /** The chosen options (controlled). */\n value?: readonly ComboboxOption[];\n /** The chosen options at first, uncontrolled. */\n defaultValue?: readonly ComboboxOption[];\n /** Called with every chosen option. */\n onValueChange?: (value: ComboboxOption[]) => void;\n /** Most options that can be chosen; the list stops offering more past it. */\n maxSelected?: number;\n};\n\nexport type ComboboxProps = SingleProps | MultipleProps;\n\nconst fold = (text: string) => text.normalize(\"NFD\").replace(/\\p{Diacritic}/gu, \"\").toLowerCase();\nconst defaultFilter = (option: ComboboxOption, query: string) => fold(option.label).includes(fold(query.trim()));\n\ntype Item = { kind: \"option\"; option: ComboboxOption } | { kind: \"create\"; query: string };\n\n/** A text field that suggests, filters and completes: one value or several (chips), static or fetched, creatable. */\nexport function Combobox(props: ComboboxProps) {\n const {\n label,\n hideLabel,\n options,\n onSearch,\n debounce = 250,\n filter = defaultFilter,\n creatable,\n onCreate = (query: string) => ({ value: query, label: query }),\n separators,\n placeholder,\n hint,\n error,\n disabled,\n name,\n labels: given,\n className,\n id: givenId,\n } = props;\n const labels = { ...comboboxLabels, ...given };\n const s = combobox();\n const autoId = React.useId();\n const inputId = givenId ?? `${autoId}-input`;\n const hintId = `${autoId}-hint`;\n const errorId = `${autoId}-error`;\n const multiple = props.multiple === true;\n\n const [values, setValues] = useControllable<readonly ComboboxOption[]>(\n props.value === undefined ? undefined : multiple ? (props.value as readonly ComboboxOption[]) : props.value ? [props.value as ComboboxOption] : [],\n multiple ? ((props.defaultValue as readonly ComboboxOption[]) ?? []) : props.defaultValue ? [props.defaultValue as ComboboxOption] : [],\n (next) => (multiple ? (props.onValueChange as ((v: ComboboxOption[]) => void) | undefined)?.([...next]) : (props.onValueChange as ((v: ComboboxOption | null) => void) | undefined)?.(next[0] ?? null)),\n );\n const single = multiple ? null : (values[0] ?? null);\n const [query, setQuery] = React.useState(single?.label ?? \"\");\n const [editing, setEditing] = React.useState(false);\n const [open, setOpenState] = React.useState(false);\n const [remote, setRemote] = React.useState<{ query: string; options: readonly ComboboxOption[]; state: \"idle\" | \"loading\" | \"error\" }>({ query: \"\", options: [], state: \"idle\" });\n const request = React.useRef<AbortController | null>(null);\n const inputRef = React.useRef<HTMLInputElement>(null);\n\n // The single choice's label shows in the input while the person is not typing.\n const shownQuery = !multiple && !editing ? (single?.label ?? \"\") : query;\n const searchQuery = editing ? query : \"\";\n\n const search = useDebouncedCallback((text: string) => {\n if (!onSearch) return;\n request.current?.abort();\n const controller = new AbortController();\n request.current = controller;\n onSearch(text, controller.signal).then(\n (found) => !controller.signal.aborted && setRemote({ query: text, options: found, state: \"idle\" }),\n () => !controller.signal.aborted && setRemote({ query: text, options: [], state: \"error\" }),\n );\n }, debounce);\n React.useEffect(() => () => request.current?.abort(), []);\n\n const setOpen = (next: boolean) => {\n if (next && onSearch && remote.state === \"idle\" && remote.query !== searchQuery) {\n setRemote((r) => ({ ...r, state: \"loading\" }));\n search(searchQuery);\n }\n setOpenState(next);\n };\n\n const chosen = new Set(values.map((v) => v.value));\n const source = onSearch ? remote.options : (options ?? []).filter((o) => !searchQuery.trim() || filter(o, searchQuery));\n const full = multiple && props.maxSelected !== undefined && values.length >= props.maxSelected;\n const trimmed = searchQuery.trim();\n const exact = [...source, ...values].some((o) => fold(o.label) === fold(trimmed));\n const items: Item[] = [\n ...source.map((option) => ({ kind: \"option\" as const, option })),\n ...(creatable && trimmed && !exact && !full ? [{ kind: \"create\" as const, query: trimmed }] : []),\n ];\n const isDisabled = (i: number) => {\n const item = items[i];\n if (!item) return true;\n if (item.kind === \"create\") return false;\n return Boolean(item.option.disabled) || (full && !chosen.has(item.option.value));\n };\n\n const commit = (option: ComboboxOption) => {\n if (multiple) {\n setValues(chosen.has(option.value) ? values.filter((v) => v.value !== option.value) : [...values, option]);\n setQuery(\"\");\n listbox.setActive(-1);\n } else {\n setValues([option]);\n setQuery(option.label);\n setEditing(false);\n setOpenState(false);\n }\n };\n const create = (text: string) => {\n const clean = text.trim();\n if (!clean || full) return;\n const existing = [...source, ...values].find((o) => fold(o.label) === fold(clean));\n if (multiple && existing && chosen.has(existing.value)) {\n setQuery(\"\");\n return;\n }\n commit(existing ?? onCreate(clean));\n };\n const pick = (i: number) => {\n const item = items[i];\n if (!item) return;\n if (item.kind === \"create\") create(item.query);\n else commit(item.option);\n };\n\n const listbox = useListbox({ count: items.length, isDisabled, onPick: pick, open, setOpen });\n\n const onChange = (text: string) => {\n setQuery(text);\n setEditing(true);\n listbox.setActive(-1);\n if (onSearch) {\n setRemote((r) => ({ ...r, state: \"loading\" }));\n search(text);\n }\n setOpenState(true);\n if (!multiple && text === \"\" && single) setValues([]);\n };\n\n const onKeyDown = (event: React.KeyboardEvent<HTMLInputElement>) => {\n if (separators?.includes(event.key) && query.trim()) {\n event.preventDefault();\n create(query);\n return;\n }\n if (listbox.onKeyDown(event)) return;\n if (event.key === \"Enter\" && creatable && query.trim()) {\n event.preventDefault();\n create(query);\n } else if (event.key === \"Backspace\" && multiple && query === \"\" && values.length > 0) {\n setValues(values.slice(0, -1));\n } else if (event.key === \"Escape\" && !multiple && editing) {\n setEditing(false);\n setQuery(single?.label ?? \"\");\n }\n };\n\n const onPaste = (event: React.ClipboardEvent<HTMLInputElement>) => {\n if (!separators?.length || !multiple) return;\n const text = event.clipboardData.getData(\"text\");\n const parts = text.split(new RegExp(`[${separators.map((c) => c.replace(/[\\\\\\]^-]/g, \"\\\\$&\")).join(\"\")}\\\\n]`)).map((p) => p.trim()).filter(Boolean);\n if (parts.length < 2) return;\n event.preventDefault();\n const next = [...values];\n for (const part of parts) {\n if (props.maxSelected !== undefined && next.length >= props.maxSelected) break;\n if (next.some((v) => fold(v.label) === fold(part))) continue;\n next.push((options ?? []).find((o) => fold(o.label) === fold(part)) ?? onCreate(part));\n }\n setValues(next);\n };\n\n const loading = Boolean(onSearch) && remote.state === \"loading\";\n const failed = Boolean(onSearch) && remote.state === \"error\";\n const describedBy = [hint ? hintId : null, error ? errorId : null].filter(Boolean).join(\" \") || undefined;\n\n return (\n <div\n className={s.root({ className })}\n onBlur={(event) => {\n if (event.currentTarget.contains(event.relatedTarget as Node | null)) return;\n setOpenState(false);\n if (!multiple) {\n setEditing(false);\n setQuery(single?.label ?? \"\");\n }\n }}\n >\n <label htmlFor={inputId} className={hideLabel ? \"sr-only\" : s.label()}>\n {label}\n </label>\n <div className={s.control()} data-invalid={error ? \"\" : undefined} data-disabled={disabled ? \"\" : undefined} onMouseDown={(event) => {\n if (event.target === event.currentTarget) {\n event.preventDefault();\n inputRef.current?.focus();\n }\n }}>\n {multiple &&\n values.map((option) => (\n <Chip key={option.value} size=\"sm\" removable removeLabel={labels.remove(option.label)} disabled={disabled} onRemove={() => setValues(values.filter((v) => v.value !== option.value))}>\n {option.label}\n </Chip>\n ))}\n <input\n ref={inputRef}\n id={inputId}\n type=\"text\"\n autoComplete=\"off\"\n spellCheck={false}\n {...listbox.inputProps}\n aria-describedby={describedBy}\n aria-invalid={error ? true : undefined}\n aria-busy={loading || undefined}\n value={shownQuery}\n placeholder={multiple && values.length > 0 ? undefined : placeholder}\n disabled={disabled}\n className={s.input()}\n onChange={(event) => onChange(event.target.value)}\n onKeyDown={onKeyDown}\n onPaste={onPaste}\n onClick={() => !open && setOpen(true)}\n />\n {!multiple && single && !disabled ? (\n <button type=\"button\" aria-label={labels.clear} className={s.icon()} onClick={() => {\n setValues([]);\n setQuery(\"\");\n inputRef.current?.focus();\n }}>\n <CloseGlyph className=\"h-4 w-4\" />\n </button>\n ) : null}\n <button type=\"button\" tabIndex={-1} aria-label={labels.toggle} aria-expanded={open} aria-controls={listbox.listId} disabled={disabled} className={s.icon()} onClick={() => {\n setOpen(!open);\n inputRef.current?.focus();\n }}>\n <ChevronGlyph direction={open ? \"up\" : \"down\"} className=\"h-4 w-4\" />\n </button>\n </div>\n {name && values.map((v) => <input key={v.value} type=\"hidden\" name={name} value={v.value} />)}\n <div id={listbox.listId} role=\"listbox\" aria-label={label} aria-multiselectable={multiple || undefined} hidden={!open || (items.length === 0 && !loading && !failed && !labels.empty)} className={s.list()}>\n {open && loading && items.length === 0 ? <div className={s.status()}>{labels.loading}</div> : null}\n {open && failed ? <div className={s.status()}>{labels.error}</div> : null}\n {open && !loading && !failed && items.length === 0 && labels.empty ? <div className={s.status()}>{labels.empty}</div> : null}\n {open &&\n items.map((item, i) =>\n item.kind === \"create\" ? (\n <div key=\"__create\" {...listbox.optionProps(i, false)} className={s.option()}>\n <PlusGlyph className={s.check()} />\n {labels.create(item.query)}\n </div>\n ) : (\n <div key={item.option.value} {...listbox.optionProps(i, chosen.has(item.option.value))} className={s.option()}>\n <span className=\"flex h-4 w-4 shrink-0 items-center justify-center\">{chosen.has(item.option.value) ? <CheckGlyph className={s.check()} /> : null}</span>\n <span className=\"min-w-0 flex-1\">\n {item.option.label}\n {item.option.description ? <span className={s.description()}>{item.option.description}</span> : null}\n </span>\n </div>\n ),\n )}\n </div>\n <span className=\"sr-only\" aria-live=\"polite\" aria-atomic>\n {open && !loading ? labels.results(items.length) : \"\"}\n </span>\n {hint ? (\n <p id={hintId} className={s.hint()}>\n {hint}\n </p>\n ) : null}\n {error ? (\n <p id={errorId} className={s.error()}>\n {error}\n </p>\n ) : null}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAIA,SAAS,4BAA4B;AACrC,YAAY,WAAW;AACvB,SAAS,UAAU;AA4Tb,cAGA,YAHA;AArTC,IAAM,WAAW,GAAG;AAAA,EACzB,OAAO;AAAA,IACL,MAAM;AAAA,IACN,OAAO;AAAA,IACP,SACE;AAAA,IAGF,OAAO;AAAA,IACP,MACE;AAAA,IAEF,MAAM;AAAA,IACN,QACE;AAAA,IAEF,OAAO;AAAA,IACP,aAAa;AAAA,IACb,QAAQ;AAAA,IACR,MAAM;AAAA,IACN,OAAO;AAAA,EACT;AACF,CAAC;AAgCM,IAAM,iBAAiC;AAAA,EAC5C,OAAO;AAAA,EACP,SAAS;AAAA,EACT,OAAO;AAAA,EACP,QAAQ,CAAC,UAAU,gBAAW,KAAK;AAAA,EACnC,QAAQ,CAAC,UAAU,UAAU,KAAK;AAAA,EAClC,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,SAAS,CAAC,UAAW,UAAU,IAAI,aAAa,GAAG,KAAK;AAC1D;AAmEA,IAAM,OAAO,CAAC,SAAiB,KAAK,UAAU,KAAK,EAAE,QAAQ,mBAAmB,EAAE,EAAE,YAAY;AAChG,IAAM,gBAAgB,CAAC,QAAwB,UAAkB,KAAK,OAAO,KAAK,EAAE,SAAS,KAAK,MAAM,KAAK,CAAC,CAAC;AAKxG,SAAS,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EAAE,YAAY,GAAI,eAAK,OAAO,aAAY,IAAU;AAAA,iBAClG;AAAA,iBALQ,KAAK,OAAO,KAMtB;AAAA,UAEJ;AAAA,WACJ;AAAA,QACA,oBAAC,UAAK,WAAU,WAAU,aAAU,UAAS,eAAW,MACrD,kBAAQ,CAAC,UAAU,OAAO,QAAQ,MAAM,MAAM,IAAI,IACrD;AAAA,QACC,OACC,oBAAC,OAAE,IAAI,QAAQ,WAAW,EAAE,KAAK,GAC9B,gBACH,IACE;AAAA,QACH,QACC,oBAAC,OAAE,IAAI,SAAS,WAAW,EAAE,MAAM,GAChC,iBACH,IACE;AAAA;AAAA;AAAA,EACN;AAEJ;","names":["query"]}
1
+ {"version":3,"sources":["../src/combobox/combobox.tsx"],"sourcesContent":["// Client. The ARIA 1.2 combobox (`../listbox`): a text input that filters a listbox, the focus never leaves the input\n// (`aria-activedescendant`), the number of results announced in a polite live region. Static options filtered here,\n// or `onSearch` (debounced, the previous request aborted) for a server's; one value or several (chips, Backspace\n// removes the last), and new values created from the query when `creatable`.\nimport { useDebouncedCallback } from \"@krizaka/pacer/react\";\nimport * as React from \"react\";\nimport { tv } from \"tailwind-variants\";\n\nimport { Chip } from \"../chip\";\nimport { CheckGlyph, ChevronGlyph, CloseGlyph, PlusGlyph } from \"../glyphs\";\nimport { useListbox } from \"../listbox\";\nimport { useControllable } from \"../media\";\n\nexport const combobox = tv({\n slots: {\n root: \"relative flex w-full flex-col gap-1.5\",\n label: \"text-xs font-semibold text-fg-secondary\",\n control:\n \"flex min-h-11 w-full flex-wrap items-center gap-1.5 rounded-lg border border-border-control bg-surface-2 py-1.5 pl-2 pr-1 text-sm text-fg \" +\n \"transition-[border-color,box-shadow] focus-within:border-accent focus-within:ring-2 focus-within:ring-ring \" +\n \"data-[invalid]:border-danger data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50\",\n input: \"h-8 min-w-24 flex-1 bg-transparent px-1 text-sm text-fg outline-hidden placeholder:text-fg-muted disabled:cursor-not-allowed\",\n icon:\n \"inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md text-fg-secondary hover:bg-surface-3 hover:text-fg \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring\",\n list: \"absolute inset-x-0 top-full z-50 mt-1 max-h-64 overflow-y-auto rounded-lg border border-border-default bg-surface-2 p-1 shadow-lg\",\n option:\n \"flex cursor-pointer select-none items-center gap-2.5 rounded-md px-2.5 py-2 text-sm text-fg \" +\n \"data-[active]:bg-surface-3 aria-disabled:cursor-not-allowed aria-disabled:opacity-40\",\n check: \"h-4 w-4 shrink-0 text-fg-accent\",\n description: \"block text-xs text-fg-secondary\",\n status: \"px-2.5 py-3 text-sm text-fg-secondary\",\n hint: \"text-xs text-fg-secondary\",\n error: \"flex items-center gap-1.5 text-xs font-medium text-fg-danger before:h-1.5 before:w-1.5 before:shrink-0 before:rounded-full before:bg-danger\",\n },\n});\n\nexport type ComboboxOption = {\n /** What the app stores. */\n value: string;\n /** What the person reads, passed translated. */\n label: string;\n /** A second line under the label. */\n description?: string;\n /** Shown but not choosable. */\n disabled?: boolean;\n};\n\nexport type ComboboxLabels = {\n /** No option matches (\"No results\"). */\n empty: string;\n /** While `onSearch` runs (\"Searching…\"). */\n loading: string;\n /** `onSearch` failed (\"Search unavailable\"). */\n error: string;\n /** The option that creates a value: `(query) => \"Create “\" + query + \"”\"`. */\n create: (query: string) => string;\n /** A chip's remove button: `(label) => \"Remove \" + label`. */\n remove: (label: string) => string;\n /** The button that empties a single choice (\"Clear\"). */\n clear: string;\n /** The button that opens the list (\"Show options\"). */\n toggle: string;\n /** Announced when the results change: `(n) => n + \" results\"`. */\n results: (count: number) => string;\n};\n\nexport const comboboxLabels: ComboboxLabels = {\n empty: \"No results\",\n loading: \"Searching…\",\n error: \"Search unavailable\",\n create: (query) => `Create “${query}”`,\n remove: (label) => `Remove ${label}`,\n clear: \"Clear\",\n toggle: \"Show options\",\n results: (count) => (count === 1 ? \"1 result\" : `${count} results`),\n};\n\ntype BaseProps = {\n /** The visible label of the field, passed translated (also its accessible name). */\n label: string;\n /** Hides the label visually, keeping it as the accessible name (a search bar with its own context). */\n hideLabel?: boolean;\n /** The options, filtered as the person types (by `filter`). */\n options?: readonly ComboboxOption[];\n /** Fetches the options for a query (debounced by `debounce`); the `signal` aborts when a newer query starts. */\n onSearch?: (query: string, signal: AbortSignal) => Promise<readonly ComboboxOption[]>;\n /** The wait, in ms, between the last key and `onSearch`. Default 250. */\n debounce?: number;\n /** Whether an option matches a query. Default: its label contains the query, ignoring case and accents. */\n filter?: (option: ComboboxOption, query: string) => boolean;\n /** Offers to create the query as a new value when no option has that exact label. */\n creatable?: boolean;\n /** Turns a query into the created option (an id from the server…). Default `{ value: query, label: query }`. */\n onCreate?: (query: string) => ComboboxOption;\n /** Keys that create the query at once, as Enter does (`[\",\"]` for tags); a paste is split on them too. */\n separators?: readonly string[];\n /** The input's placeholder, passed translated. */\n placeholder?: string;\n /** A help text under the field. */\n hint?: string;\n /** An error under the field: marks it invalid and is read with it. */\n error?: string;\n /** Not available. */\n disabled?: boolean;\n /** The name of a hidden input holding the value(s), for a plain `<form>` post. */\n name?: string;\n /** The words, passed translated; English by default. */\n labels?: Partial<ComboboxLabels>;\n /** Classes merged on the root. */\n className?: string;\n /** The id of the text input (default: generated). */\n id?: string;\n};\n\ntype SingleProps = BaseProps & {\n /** One value (default) or several. */\n multiple?: false;\n /** The chosen option (controlled), `null` for none. */\n value?: ComboboxOption | null;\n /** The chosen option at first, uncontrolled. */\n defaultValue?: ComboboxOption | null;\n /** Called with the chosen option, or `null` when it is cleared. */\n onValueChange?: (value: ComboboxOption | null) => void;\n /** Most options that can be chosen (several values only). */\n maxSelected?: never;\n};\n\ntype MultipleProps = BaseProps & {\n /** Several values, shown as chips. */\n multiple: true;\n /** The chosen options (controlled). */\n value?: readonly ComboboxOption[];\n /** The chosen options at first, uncontrolled. */\n defaultValue?: readonly ComboboxOption[];\n /** Called with every chosen option. */\n onValueChange?: (value: ComboboxOption[]) => void;\n /** Most options that can be chosen; the list stops offering more past it. */\n maxSelected?: number;\n};\n\nexport type ComboboxProps = SingleProps | MultipleProps;\n\nconst fold = (text: string) => text.normalize(\"NFD\").replace(/\\p{Diacritic}/gu, \"\").toLowerCase();\nconst defaultFilter = (option: ComboboxOption, query: string) => fold(option.label).includes(fold(query.trim()));\n\ntype Item = { kind: \"option\"; option: ComboboxOption } | { kind: \"create\"; query: string };\n\n/** A text field that suggests, filters and completes: one value or several (chips), static or fetched, creatable. */\nexport function Combobox(props: ComboboxProps) {\n const {\n label,\n hideLabel,\n options,\n onSearch,\n debounce = 250,\n filter = defaultFilter,\n creatable,\n onCreate = (query: string) => ({ value: query, label: query }),\n separators,\n placeholder,\n hint,\n error,\n disabled,\n name,\n labels: given,\n className,\n id: givenId,\n } = props;\n const labels = { ...comboboxLabels, ...given };\n const s = combobox();\n const autoId = React.useId();\n const inputId = givenId ?? `${autoId}-input`;\n const hintId = `${autoId}-hint`;\n const errorId = `${autoId}-error`;\n const multiple = props.multiple === true;\n\n const [values, setValues] = useControllable<readonly ComboboxOption[]>(\n props.value === undefined ? undefined : multiple ? (props.value as readonly ComboboxOption[]) : props.value ? [props.value as ComboboxOption] : [],\n multiple ? ((props.defaultValue as readonly ComboboxOption[]) ?? []) : props.defaultValue ? [props.defaultValue as ComboboxOption] : [],\n (next) => (multiple ? (props.onValueChange as ((v: ComboboxOption[]) => void) | undefined)?.([...next]) : (props.onValueChange as ((v: ComboboxOption | null) => void) | undefined)?.(next[0] ?? null)),\n );\n const single = multiple ? null : (values[0] ?? null);\n const [query, setQuery] = React.useState(single?.label ?? \"\");\n const [editing, setEditing] = React.useState(false);\n const [open, setOpenState] = React.useState(false);\n const [remote, setRemote] = React.useState<{ query: string; options: readonly ComboboxOption[]; state: \"idle\" | \"loading\" | \"error\" }>({ query: \"\", options: [], state: \"idle\" });\n const request = React.useRef<AbortController | null>(null);\n const inputRef = React.useRef<HTMLInputElement>(null);\n\n // The single choice's label shows in the input while the person is not typing.\n const shownQuery = !multiple && !editing ? (single?.label ?? \"\") : query;\n const searchQuery = editing ? query : \"\";\n\n const search = useDebouncedCallback((text: string) => {\n if (!onSearch) return;\n request.current?.abort();\n const controller = new AbortController();\n request.current = controller;\n onSearch(text, controller.signal).then(\n (found) => !controller.signal.aborted && setRemote({ query: text, options: found, state: \"idle\" }),\n () => !controller.signal.aborted && setRemote({ query: text, options: [], state: \"error\" }),\n );\n }, debounce);\n React.useEffect(() => () => request.current?.abort(), []);\n\n const setOpen = (next: boolean) => {\n if (next && onSearch && remote.state === \"idle\" && remote.query !== searchQuery) {\n setRemote((r) => ({ ...r, state: \"loading\" }));\n search(searchQuery);\n }\n setOpenState(next);\n };\n\n const chosen = new Set(values.map((v) => v.value));\n const source = onSearch ? remote.options : (options ?? []).filter((o) => !searchQuery.trim() || filter(o, searchQuery));\n const full = multiple && props.maxSelected !== undefined && values.length >= props.maxSelected;\n const trimmed = searchQuery.trim();\n const exact = [...source, ...values].some((o) => fold(o.label) === fold(trimmed));\n const items: Item[] = [\n ...source.map((option) => ({ kind: \"option\" as const, option })),\n ...(creatable && trimmed && !exact && !full ? [{ kind: \"create\" as const, query: trimmed }] : []),\n ];\n const isDisabled = (i: number) => {\n const item = items[i];\n if (!item) return true;\n if (item.kind === \"create\") return false;\n return Boolean(item.option.disabled) || (full && !chosen.has(item.option.value));\n };\n\n const commit = (option: ComboboxOption) => {\n if (multiple) {\n setValues(chosen.has(option.value) ? values.filter((v) => v.value !== option.value) : [...values, option]);\n setQuery(\"\");\n listbox.setActive(-1);\n } else {\n setValues([option]);\n setQuery(option.label);\n setEditing(false);\n setOpenState(false);\n }\n };\n const create = (text: string) => {\n const clean = text.trim();\n if (!clean || full) return;\n const existing = [...source, ...values].find((o) => fold(o.label) === fold(clean));\n if (multiple && existing && chosen.has(existing.value)) {\n setQuery(\"\");\n return;\n }\n commit(existing ?? onCreate(clean));\n };\n const pick = (i: number) => {\n const item = items[i];\n if (!item) return;\n if (item.kind === \"create\") create(item.query);\n else commit(item.option);\n };\n\n const listbox = useListbox({ count: items.length, isDisabled, onPick: pick, open, setOpen });\n\n const onChange = (text: string) => {\n setQuery(text);\n setEditing(true);\n listbox.setActive(-1);\n if (onSearch) {\n setRemote((r) => ({ ...r, state: \"loading\" }));\n search(text);\n }\n setOpenState(true);\n if (!multiple && text === \"\" && single) setValues([]);\n };\n\n const onKeyDown = (event: React.KeyboardEvent<HTMLInputElement>) => {\n if (separators?.includes(event.key) && query.trim()) {\n event.preventDefault();\n create(query);\n return;\n }\n if (listbox.onKeyDown(event)) return;\n if (event.key === \"Enter\" && creatable && query.trim()) {\n event.preventDefault();\n create(query);\n } else if (event.key === \"Backspace\" && multiple && query === \"\" && values.length > 0) {\n setValues(values.slice(0, -1));\n } else if (event.key === \"Escape\" && !multiple && editing) {\n setEditing(false);\n setQuery(single?.label ?? \"\");\n }\n };\n\n const onPaste = (event: React.ClipboardEvent<HTMLInputElement>) => {\n if (!separators?.length || !multiple) return;\n const text = event.clipboardData.getData(\"text\");\n const parts = text.split(new RegExp(`[${separators.map((c) => c.replace(/[\\\\\\]^-]/g, \"\\\\$&\")).join(\"\")}\\\\n]`)).map((p) => p.trim()).filter(Boolean);\n if (parts.length < 2) return;\n event.preventDefault();\n const next = [...values];\n for (const part of parts) {\n if (props.maxSelected !== undefined && next.length >= props.maxSelected) break;\n if (next.some((v) => fold(v.label) === fold(part))) continue;\n next.push((options ?? []).find((o) => fold(o.label) === fold(part)) ?? onCreate(part));\n }\n setValues(next);\n };\n\n const loading = Boolean(onSearch) && remote.state === \"loading\";\n const failed = Boolean(onSearch) && remote.state === \"error\";\n const describedBy = [hint ? hintId : null, error ? errorId : null].filter(Boolean).join(\" \") || undefined;\n\n return (\n <div\n className={s.root({ className })}\n onBlur={(event) => {\n if (event.currentTarget.contains(event.relatedTarget as Node | null)) return;\n setOpenState(false);\n if (!multiple) {\n setEditing(false);\n setQuery(single?.label ?? \"\");\n }\n }}\n >\n <label htmlFor={inputId} className={hideLabel ? \"sr-only\" : s.label()}>\n {label}\n </label>\n <div className={s.control()} data-invalid={error ? \"\" : undefined} data-disabled={disabled ? \"\" : undefined} onMouseDown={(event) => {\n if (event.target === event.currentTarget) {\n event.preventDefault();\n inputRef.current?.focus();\n }\n }}>\n {multiple &&\n values.map((option) => (\n <Chip key={option.value} size=\"sm\" removable removeLabel={labels.remove(option.label)} disabled={disabled} onRemove={() => setValues(values.filter((v) => v.value !== option.value))}>\n {option.label}\n </Chip>\n ))}\n <input\n ref={inputRef}\n id={inputId}\n type=\"text\"\n autoComplete=\"off\"\n spellCheck={false}\n {...listbox.inputProps}\n aria-describedby={describedBy}\n aria-invalid={error ? true : undefined}\n aria-busy={loading || undefined}\n value={shownQuery}\n placeholder={multiple && values.length > 0 ? undefined : placeholder}\n disabled={disabled}\n className={s.input()}\n onChange={(event) => onChange(event.target.value)}\n onKeyDown={onKeyDown}\n onPaste={onPaste}\n onClick={() => !open && setOpen(true)}\n />\n {!multiple && single && !disabled ? (\n <button type=\"button\" aria-label={labels.clear} className={s.icon()} onClick={() => {\n setValues([]);\n setQuery(\"\");\n inputRef.current?.focus();\n }}>\n <CloseGlyph className=\"h-4 w-4\" />\n </button>\n ) : null}\n <button type=\"button\" tabIndex={-1} aria-label={labels.toggle} aria-expanded={open} aria-controls={listbox.listId} disabled={disabled} className={s.icon()} onClick={() => {\n setOpen(!open);\n inputRef.current?.focus();\n }}>\n <ChevronGlyph direction={open ? \"up\" : \"down\"} className=\"h-4 w-4\" />\n </button>\n </div>\n {name && values.map((v) => <input key={v.value} type=\"hidden\" name={name} value={v.value} />)}\n <div id={listbox.listId} role=\"listbox\" aria-label={label} aria-multiselectable={multiple || undefined} hidden={!open || (items.length === 0 && !loading && !failed && !labels.empty)} className={s.list()}>\n {open && loading && items.length === 0 ? <div className={s.status()}>{labels.loading}</div> : null}\n {open && failed ? <div className={s.status()}>{labels.error}</div> : null}\n {open && !loading && !failed && items.length === 0 && labels.empty ? <div className={s.status()}>{labels.empty}</div> : null}\n {open &&\n items.map((item, i) =>\n item.kind === \"create\" ? (\n <div key=\"__create\" {...listbox.optionProps(i, false)} className={s.option()}>\n <PlusGlyph className={s.check()} />\n {labels.create(item.query)}\n </div>\n ) : (\n <div key={item.option.value} {...listbox.optionProps(i, chosen.has(item.option.value))} className={s.option()}>\n <span className=\"flex h-4 w-4 shrink-0 items-center justify-center\">{chosen.has(item.option.value) ? <CheckGlyph className={s.check()} /> : null}</span>\n <span className=\"min-w-0 flex-1\">\n {item.option.label}\n {item.option.description ? <span className={s.description()}>{item.option.description}</span> : null}\n </span>\n </div>\n ),\n )}\n </div>\n <span className=\"sr-only\" aria-live=\"polite\" aria-atomic>\n {open && !loading ? labels.results(items.length) : \"\"}\n </span>\n {hint ? (\n <p id={hintId} className={s.hint()}>\n {hint}\n </p>\n ) : null}\n {error ? (\n <p id={errorId} className={s.error()}>\n {error}\n </p>\n ) : null}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAIA,SAAS,4BAA4B;AACrC,YAAY,WAAW;AACvB,SAAS,UAAU;AA4Tb,cAGA,YAHA;AArTC,IAAM,WAAW,GAAG;AAAA,EACzB,OAAO;AAAA,IACL,MAAM;AAAA,IACN,OAAO;AAAA,IACP,SACE;AAAA,IAGF,OAAO;AAAA,IACP,MACE;AAAA,IAEF,MAAM;AAAA,IACN,QACE;AAAA,IAEF,OAAO;AAAA,IACP,aAAa;AAAA,IACb,QAAQ;AAAA,IACR,MAAM;AAAA,IACN,OAAO;AAAA,EACT;AACF,CAAC;AAgCM,IAAM,iBAAiC;AAAA,EAC5C,OAAO;AAAA,EACP,SAAS;AAAA,EACT,OAAO;AAAA,EACP,QAAQ,CAAC,UAAU,gBAAW,KAAK;AAAA,EACnC,QAAQ,CAAC,UAAU,UAAU,KAAK;AAAA,EAClC,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,SAAS,CAAC,UAAW,UAAU,IAAI,aAAa,GAAG,KAAK;AAC1D;AAmEA,I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,iBAAO,IAAI,KAAK,OAAO,KAAK,IAAI,oBAAC,cAAW,WAAW,EAAE,MAAM,GAAG,IAAK,MAAK;AAAA,cACjJ,qBAAC,UAAK,WAAU,kBACb;AAAA,qBAAK,OAAO;AAAA,gBACZ,KAAK,OAAO,cAAc,oBAAC,UAAK,WAAW,EAAE,YAAY,GAAI,eAAK,OAAO,aAAY,IAAU;AAAA,iBAClG;AAAA,iBALQ,KAAK,OAAO,KAMtB;AAAA,UAEJ;AAAA,WACJ;AAAA,QACA,oBAAC,UAAK,WAAU,WAAU,aAAU,UAAS,eAAW,MACrD,kBAAQ,CAAC,UAAU,OAAO,QAAQ,MAAM,MAAM,IAAI,IACrD;AAAA,QACC,OACC,oBAAC,OAAE,IAAI,QAAQ,WAAW,EAAE,KAAK,GAC9B,gBACH,IACE;AAAA,QACH,QACC,oBAAC,OAAE,IAAI,SAAS,WAAW,EAAE,MAAM,GAChC,iBACH,IACE;AAAA;AAAA;AAAA,EACN;AAEJ;","names":["query"]}
@@ -0,0 +1,18 @@
1
+ "use client";
2
+
3
+ // src/deprecated.ts
4
+ var DEPRECATED_SINCE = "3.55.0";
5
+ var REMOVED_IN = "4.0.0";
6
+ var warned = /* @__PURE__ */ new Set();
7
+ function warnDeprecated(entry, since = DEPRECATED_SINCE) {
8
+ if (typeof process === "undefined" || process.env.NODE_ENV === "production" || warned.has(entry)) return;
9
+ warned.add(entry);
10
+ console.warn(
11
+ `@krizaka/ui/${entry} is deprecated since ${since} and is removed in ${REMOVED_IN} (ADR-006): no product uses it. Keep it? Comment on krizaka-ui#674 with the issue that needs it. https://ui.krizaka.com/components/${entry.replace(/^native\//, "")}`
12
+ );
13
+ }
14
+
15
+ export {
16
+ warnDeprecated
17
+ };
18
+ //# sourceMappingURL=chunk-BDIU5LZB.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/deprecated.ts"],"sourcesContent":["// The development warning of a deprecated entry (ADR-006 §7, krizaka-ui#674). An entry is deprecated in a minor and\n// removed in the next major; until then it works exactly as before and says so once per page, in development only —\n// never in production, never twice. The same facts live in the entry's `meta.ts` (`status: \"deprecated\"`), which\n// ui.krizaka.com reads for its badge.\n\n/** The release that deprecated the batch. */\nexport const DEPRECATED_SINCE = \"3.55.0\";\n/** The major that removes it. */\nexport const REMOVED_IN = \"4.0.0\";\n\nconst warned = new Set<string>();\n\n/**\n * Warns once per page, in development, that `@krizaka/ui/<entry>` is deprecated. Call it at the top of the entry's\n * components; it costs a `Set` lookup and nothing in production.\n * @param entry the entry's name as imported: `tree-view` for `@krizaka/ui/tree-view`.\n * @param since the release that deprecated it, when it is not this batch's.\n */\nexport function warnDeprecated(entry: string, since: string = DEPRECATED_SINCE): void {\n if (typeof process === \"undefined\" || process.env.NODE_ENV === \"production\" || warned.has(entry)) return;\n warned.add(entry);\n console.warn(\n `@krizaka/ui/${entry} is deprecated since ${since} and is removed in ${REMOVED_IN} (ADR-006): no product uses it. ` +\n `Keep it? Comment on krizaka-ui#674 with the issue that needs it. https://ui.krizaka.com/components/${entry.replace(/^native\\//, \"\")}`,\n );\n}\n\n/** Forgets what was warned (tests only). */\nexport function resetDeprecationWarnings(): void {\n warned.clear();\n}\n"],"mappings":";;;AAMO,IAAM,mBAAmB;AAEzB,IAAM,aAAa;AAE1B,IAAM,SAAS,oBAAI,IAAY;AAQxB,SAAS,eAAe,OAAe,QAAgB,kBAAwB;AACpF,MAAI,OAAO,YAAY,eAAe,QAAQ,IAAI,aAAa,gBAAgB,OAAO,IAAI,KAAK,EAAG;AAClG,SAAO,IAAI,KAAK;AAChB,UAAQ;AAAA,IACN,eAAe,KAAK,wBAAwB,KAAK,sBAAsB,UAAU,sIACuB,MAAM,QAAQ,aAAa,EAAE,CAAC;AAAA,EACxI;AACF;","names":[]}
@@ -0,0 +1,39 @@
1
+ "use client";
2
+
3
+ // src/switch/switch.tsx
4
+ import { Switch as SwitchPrimitive } from "radix-ui";
5
+ import { tv } from "tailwind-variants";
6
+ import { jsx } from "react/jsx-runtime";
7
+ var switchVariants = tv({
8
+ slots: {
9
+ root: "peer relative inline-flex shrink-0 cursor-pointer items-center rounded-full border border-transparent bg-fg-muted transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-surface-0 disabled:cursor-not-allowed disabled:opacity-40 data-[state=checked]:bg-accent aria-invalid:border-danger",
10
+ thumb: "pointer-events-none block rounded-full bg-fg-on-media shadow-sm transition-transform data-[state=unchecked]:translate-x-0.5 motion-reduce:transition-none"
11
+ },
12
+ variants: {
13
+ size: {
14
+ sm: { root: "h-5 w-9", thumb: "h-4 w-4 data-[state=checked]:translate-x-[1.125rem]" },
15
+ md: { root: "h-6 w-11", thumb: "h-5 w-5 data-[state=checked]:translate-x-[1.375rem]" }
16
+ }
17
+ },
18
+ defaultVariants: { size: "md" }
19
+ });
20
+ function Switch({ label, size, invalid, className, ...props }) {
21
+ const s = switchVariants({ size });
22
+ return /* @__PURE__ */ jsx(
23
+ SwitchPrimitive.Root,
24
+ {
25
+ "aria-label": label,
26
+ "aria-invalid": invalid || void 0,
27
+ "data-invalid": invalid ? "" : void 0,
28
+ className: s.root({ className }),
29
+ ...props,
30
+ children: /* @__PURE__ */ jsx(SwitchPrimitive.Thumb, { className: s.thumb() })
31
+ }
32
+ );
33
+ }
34
+
35
+ export {
36
+ switchVariants,
37
+ Switch
38
+ };
39
+ //# sourceMappingURL=chunk-CSRKYZ53.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/switch/switch.tsx"],"sourcesContent":["// Client. Radix Switch: role=\"switch\", aria-checked, Space and Enter toggle, a hidden input inside a form.\nimport { Switch as SwitchPrimitive } from \"radix-ui\";\nimport type * as React from \"react\";\nimport { tv, type VariantProps } from \"tailwind-variants\";\n\nexport const switchVariants = tv({\n slots: {\n root:\n \"peer relative inline-flex shrink-0 cursor-pointer items-center rounded-full border border-transparent bg-fg-muted transition-colors \" +\n \"focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-surface-0 \" +\n \"disabled:cursor-not-allowed disabled:opacity-40 data-[state=checked]:bg-accent aria-invalid:border-danger\",\n thumb:\n \"pointer-events-none block rounded-full bg-fg-on-media shadow-sm transition-transform data-[state=unchecked]:translate-x-0.5 motion-reduce:transition-none\",\n },\n variants: {\n size: {\n sm: { root: \"h-5 w-9\", thumb: \"h-4 w-4 data-[state=checked]:translate-x-[1.125rem]\" },\n md: { root: \"h-6 w-11\", thumb: \"h-5 w-5 data-[state=checked]:translate-x-[1.375rem]\" },\n },\n },\n defaultVariants: { size: \"md\" },\n});\n\nexport type SwitchVariants = VariantProps<typeof switchVariants>;\n\ntype Named =\n | {\n /** The accessible name — required when no visible label names it, passed translated. */\n label: string;\n }\n /** Named by a visible `<label htmlFor={id}>` (e.g. `Field.Label`). */\n | { label?: undefined; id: string }\n /** Named by another element. */\n | { label?: undefined; \"aria-labelledby\": string };\n\nexport type SwitchProps = Omit<React.ComponentProps<typeof SwitchPrimitive.Root>, \"children\"> &\n SwitchVariants &\n Named & {\n /**\n * sm · md.\n * @default \"md\"\n */\n size?: SwitchVariants[\"size\"];\n /** Marks it invalid: aria-invalid and data-invalid. */\n invalid?: boolean;\n };\n\n/** An on/off switch: `checked`/`defaultChecked` + `onCheckedChange`. */\nexport function Switch({ label, size, invalid, className, ...props }: SwitchProps) {\n const s = switchVariants({ size });\n return (\n <SwitchPrimitive.Root\n aria-label={label}\n aria-invalid={invalid || undefined}\n data-invalid={invalid ? \"\" : undefined}\n className={s.root({ className })}\n {...props}\n >\n <SwitchPrimitive.Thumb className={s.thumb()} />\n </SwitchPrimitive.Root>\n );\n}\n"],"mappings":";;;AACA,SAAS,UAAU,uBAAuB;AAE1C,SAAS,UAA6B;AAuDhC;AArDC,IAAM,iBAAiB,GAAG;AAAA,EAC/B,OAAO;AAAA,IACL,MACE;AAAA,IAGF,OACE;AAAA,EACJ;AAAA,EACA,UAAU;AAAA,IACR,MAAM;AAAA,MACJ,IAAI,EAAE,MAAM,WAAW,OAAO,sDAAsD;AAAA,MACpF,IAAI,EAAE,MAAM,YAAY,OAAO,sDAAsD;AAAA,IACvF;AAAA,EACF;AAAA,EACA,iBAAiB,EAAE,MAAM,KAAK;AAChC,CAAC;AA2BM,SAAS,OAAO,EAAE,OAAO,MAAM,SAAS,WAAW,GAAG,MAAM,GAAgB;AACjF,QAAM,IAAI,eAAe,EAAE,KAAK,CAAC;AACjC,SACE;AAAA,IAAC,gBAAgB;AAAA,IAAhB;AAAA,MACC,cAAY;AAAA,MACZ,gBAAc,WAAW;AAAA,MACzB,gBAAc,UAAU,KAAK;AAAA,MAC7B,WAAW,EAAE,KAAK,EAAE,UAAU,CAAC;AAAA,MAC9B,GAAG;AAAA,MAEJ,8BAAC,gBAAgB,OAAhB,EAAsB,WAAW,EAAE,MAAM,GAAG;AAAA;AAAA,EAC/C;AAEJ;","names":[]}
@@ -0,0 +1,128 @@
1
+ // src/meter/meter.tsx
2
+ import { tv } from "tailwind-variants";
3
+
4
+ // src/meter/model.ts
5
+ var MeterOptimum = { Low: "low", High: "high" };
6
+ var MeterLevel = { Ok: "ok", Success: "success", Warning: "warning", Danger: "danger" };
7
+ var clamp01 = (n) => Math.min(1, Math.max(0, n));
8
+ var percent = (ratio) => `${Math.round(ratio * 100)} %`;
9
+ function levelOf(ratio, thresholds, optimum) {
10
+ if (!thresholds) return MeterLevel.Ok;
11
+ const good = optimum === MeterOptimum.Low ? MeterLevel.Success : MeterLevel.Danger;
12
+ const bad = optimum === MeterOptimum.Low ? MeterLevel.Danger : MeterLevel.Success;
13
+ if (ratio >= thresholds.high) return bad;
14
+ return ratio >= thresholds.low ? MeterLevel.Warning : good;
15
+ }
16
+ function meterModel({ value = 0, min = 0, max = 100, valueText, thresholds, optimum = MeterOptimum.Low, parts }) {
17
+ const span = max - min || 1;
18
+ const ratio = clamp01((value - min) / span);
19
+ const shares = (parts ?? []).map((p, i) => ({ ...p, i, ratio: clamp01(p.value / span), words: p.valueText ?? percent(p.value / span) }));
20
+ let start = 0;
21
+ const arcs = parts ? shares.map((p) => {
22
+ const arc = { part: p.i, len: p.ratio, start };
23
+ start += p.ratio;
24
+ return arc;
25
+ }) : [{ part: void 0, len: ratio, start: 0 }];
26
+ return { ratio, level: levelOf(ratio, thresholds, optimum), words: valueText ?? percent(ratio), shares, arcs };
27
+ }
28
+
29
+ // src/meter/meter.tsx
30
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
31
+ var meter = tv({
32
+ slots: {
33
+ root: "flex w-full flex-col gap-1.5",
34
+ header: "flex items-baseline gap-2 text-xs",
35
+ caption: "min-w-0 flex-1 truncate font-medium text-fg",
36
+ figure: "shrink-0 tabular-nums text-fg-secondary",
37
+ track: "relative flex h-2 w-full gap-0.5 overflow-hidden rounded-sm bg-surface-3",
38
+ fill: "h-full rounded-sm transition-[width] duration-700 motion-reduce:transition-none",
39
+ legend: "mt-1 flex flex-wrap gap-x-4 gap-y-1 text-xs text-fg-secondary",
40
+ swatch: "inline-block h-2 w-2 shrink-0 rounded-full",
41
+ ring: "relative inline-flex shrink-0 items-center justify-center",
42
+ center: "absolute inset-0 flex flex-col items-center justify-center text-center"
43
+ },
44
+ variants: {
45
+ size: { sm: { track: "h-1.5", ring: "h-14 w-14" }, md: { ring: "h-24 w-24" }, lg: { track: "h-3", ring: "h-36 w-36" } }
46
+ },
47
+ defaultVariants: { size: "md" }
48
+ });
49
+ var BG = { ok: "bg-accent", success: "bg-success", warning: "bg-warning", danger: "bg-danger" };
50
+ var STROKE = { ok: "stroke-accent", success: "stroke-success", warning: "stroke-warning", danger: "stroke-danger" };
51
+ var PART_BG = ["bg-accent", "bg-fg-secondary", "bg-accent-2", "bg-border-strong"];
52
+ var PART_STROKE = ["stroke-accent", "stroke-fg-secondary", "stroke-accent-2", "stroke-border-strong"];
53
+ function Meter({
54
+ label,
55
+ value = 0,
56
+ min = 0,
57
+ max = 100,
58
+ valueText,
59
+ thresholds,
60
+ optimum = "low",
61
+ parts,
62
+ variant = "bar",
63
+ size = "md",
64
+ showLabel,
65
+ className,
66
+ children,
67
+ ...props
68
+ }) {
69
+ const s = meter({ size });
70
+ const { ratio, level, words, shares, arcs } = meterModel({ value, min, max, valueText, thresholds, optimum, parts });
71
+ const a11y = parts ? { role: "group", "aria-label": label } : { role: "meter", "aria-label": label, "aria-valuemin": min, "aria-valuemax": max, "aria-valuenow": Math.min(max, Math.max(min, value)), "aria-valuetext": words };
72
+ const legend = parts && /* @__PURE__ */ jsx("ul", { className: s.legend(), children: shares.map((p) => /* @__PURE__ */ jsxs("li", { className: "flex items-center gap-1.5", children: [
73
+ /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: [s.swatch(), PART_BG[p.i % PART_BG.length]].join(" ") }),
74
+ /* @__PURE__ */ jsx("span", { className: "text-fg", children: p.label }),
75
+ /* @__PURE__ */ jsx("span", { className: "tabular-nums", children: p.words })
76
+ ] }, p.i)) });
77
+ if (variant === "ring") {
78
+ const r = 44;
79
+ return /* @__PURE__ */ jsxs("div", { ...a11y, "data-level": parts ? void 0 : level, className: ["inline-flex flex-col items-center gap-2", className].filter(Boolean).join(" "), ...props, children: [
80
+ /* @__PURE__ */ jsxs("div", { className: s.ring(), children: [
81
+ /* @__PURE__ */ jsxs("svg", { viewBox: "0 0 100 100", className: "h-full w-full -rotate-90", "aria-hidden": true, children: [
82
+ /* @__PURE__ */ jsx("circle", { cx: "50", cy: "50", r, fill: "none", strokeWidth: "9", className: "stroke-border-default" }),
83
+ arcs.map((arc, i) => {
84
+ const length = Math.max(0, arc.len * 100 - (parts ? 1 : 0));
85
+ return /* @__PURE__ */ jsx(
86
+ "circle",
87
+ {
88
+ cx: "50",
89
+ cy: "50",
90
+ r,
91
+ fill: "none",
92
+ strokeWidth: "9",
93
+ pathLength: 100,
94
+ strokeDasharray: `${length} ${100 - length}`,
95
+ strokeDashoffset: -arc.start * 100,
96
+ className: [arc.part === void 0 ? STROKE[level] : PART_STROKE[arc.part % PART_STROKE.length], "transition-[stroke-dasharray] duration-700 motion-reduce:transition-none"].join(" ")
97
+ },
98
+ i
99
+ );
100
+ })
101
+ ] }),
102
+ children !== void 0 && /* @__PURE__ */ jsx("div", { className: s.center(), children })
103
+ ] }),
104
+ legend
105
+ ] });
106
+ }
107
+ return /* @__PURE__ */ jsxs("div", { ...a11y, "data-level": parts ? void 0 : level, className: s.root({ className }), ...props, children: [
108
+ showLabel && /* @__PURE__ */ jsxs("div", { "aria-hidden": true, className: s.header(), children: [
109
+ /* @__PURE__ */ jsx("span", { className: s.caption(), children: label }),
110
+ !parts && /* @__PURE__ */ jsx("span", { className: s.figure(), children: words })
111
+ ] }),
112
+ /* @__PURE__ */ jsx("div", { "aria-hidden": true, className: s.track(), children: parts ? shares.map((p) => /* @__PURE__ */ jsx("span", { className: [s.fill(), PART_BG[p.i % PART_BG.length]].join(" "), style: { width: `${p.ratio * 100}%` } }, p.i)) : /* @__PURE__ */ jsx("span", { className: [s.fill(), BG[level]].join(" "), style: { width: `${ratio * 100}%` } }) }),
113
+ legend
114
+ ] });
115
+ }
116
+ function MeterValue({ value, caption }) {
117
+ return /* @__PURE__ */ jsxs(Fragment, { children: [
118
+ /* @__PURE__ */ jsx("span", { className: "font-display text-lg font-semibold text-fg tabular-nums", children: value }),
119
+ caption && /* @__PURE__ */ jsx("span", { className: "text-[10px] text-fg-secondary", children: caption })
120
+ ] });
121
+ }
122
+
123
+ export {
124
+ meter,
125
+ Meter,
126
+ MeterValue
127
+ };
128
+ //# sourceMappingURL=chunk-HEKDKM5Y.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/meter/meter.tsx","../src/meter/model.ts"],"sourcesContent":["// Server-safe. A measure within a known range — a quota, a balance, a share — as opposed to the progress of a task.\n// `role=\"meter\"`, its value in words; thresholds turn it to warning then danger (or the reverse when high is good);\n// split into parts (90 % to the creator, 10 % to the platform) it becomes a stacked bar or ring with its legend: the\n// text version of what it draws.\nimport type * as React from \"react\";\nimport { tv } from \"tailwind-variants\";\n\nimport { type MeterLevel, meterModel, type MeterPart, type MeterThresholds } from \"./model\";\n\nexport type { MeterPart };\n\nexport const meter = tv({\n slots: {\n root: \"flex w-full flex-col gap-1.5\",\n header: \"flex items-baseline gap-2 text-xs\",\n caption: \"min-w-0 flex-1 truncate font-medium text-fg\",\n figure: \"shrink-0 tabular-nums text-fg-secondary\",\n track: \"relative flex h-2 w-full gap-0.5 overflow-hidden rounded-sm bg-surface-3\",\n fill: \"h-full rounded-sm transition-[width] duration-700 motion-reduce:transition-none\",\n legend: \"mt-1 flex flex-wrap gap-x-4 gap-y-1 text-xs text-fg-secondary\",\n swatch: \"inline-block h-2 w-2 shrink-0 rounded-full\",\n ring: \"relative inline-flex shrink-0 items-center justify-center\",\n center: \"absolute inset-0 flex flex-col items-center justify-center text-center\",\n },\n variants: {\n size: { sm: { track: \"h-1.5\", ring: \"h-14 w-14\" }, md: { ring: \"h-24 w-24\" }, lg: { track: \"h-3\", ring: \"h-36 w-36\" } },\n },\n defaultVariants: { size: \"md\" },\n});\n\n/** The colour of a fill: by tone (thresholds) or by part (the accent, a neutral, accent-2, a lighter neutral). */\nconst BG: Record<MeterLevel, string> = { ok: \"bg-accent\", success: \"bg-success\", warning: \"bg-warning\", danger: \"bg-danger\" };\nconst STROKE: Record<MeterLevel, string> = { ok: \"stroke-accent\", success: \"stroke-success\", warning: \"stroke-warning\", danger: \"stroke-danger\" };\nconst PART_BG = [\"bg-accent\", \"bg-fg-secondary\", \"bg-accent-2\", \"bg-border-strong\"];\nconst PART_STROKE = [\"stroke-accent\", \"stroke-fg-secondary\", \"stroke-accent-2\", \"stroke-border-strong\"];\n\nexport type MeterProps = Omit<React.ComponentProps<\"div\">, \"children\"> & {\n /** The accessible name (“Storage”, “Split of a tip”) — passed translated; shown with `showLabel`. */\n label: string;\n /** The value, between `min` and `max` (ignored with `parts`). */\n value?: number;\n /**\n * The bottom of the range.\n * @default 0\n */\n min?: number;\n /**\n * The top of the range.\n * @default 100\n */\n max?: number;\n /** The value in words (“42 GB of 50 GB”) — passed translated; default: the percentage. */\n valueText?: string;\n /**\n * Ratios (0–1) where the tone changes: past `high` it is in danger, past `low` in warning — or the reverse with\n * `optimum=\"high\"` (a balance: the lower, the worse). Without thresholds the fill is the brand accent.\n */\n thresholds?: MeterThresholds;\n /**\n * Which end is good.\n * @default \"low\"\n */\n optimum?: \"low\" | \"high\";\n /** Split into parts that add up to `max`: a stacked bar or ring, with its legend. */\n parts?: readonly MeterPart[];\n /**\n * bar · ring.\n * @default \"bar\"\n */\n variant?: \"bar\" | \"ring\";\n /**\n * sm · md · lg: the bar's thickness, the ring's diameter.\n * @default \"md\"\n */\n size?: \"sm\" | \"md\" | \"lg\";\n /** Shows the label and the value above the bar. */\n showLabel?: boolean;\n /** A ring's centre: the value, a word. */\n children?: React.ReactNode;\n};\n\n/** A measure within a range — a quota, a balance, a share — toned by thresholds or split into parts. */\nexport function Meter({\n label,\n value = 0,\n min = 0,\n max = 100,\n valueText,\n thresholds,\n optimum = \"low\",\n parts,\n variant = \"bar\",\n size = \"md\",\n showLabel,\n className,\n children,\n ...props\n}: MeterProps) {\n const s = meter({ size });\n const { ratio, level, words, shares, arcs } = meterModel({ value, min, max, valueText, thresholds, optimum, parts });\n const a11y = parts\n ? { role: \"group\" as const, \"aria-label\": label }\n : { role: \"meter\" as const, \"aria-label\": label, \"aria-valuemin\": min, \"aria-valuemax\": max, \"aria-valuenow\": Math.min(max, Math.max(min, value)), \"aria-valuetext\": words };\n const legend = parts && (\n <ul className={s.legend()}>\n {shares.map((p) => (\n <li key={p.i} className=\"flex items-center gap-1.5\">\n <span aria-hidden className={[s.swatch(), PART_BG[p.i % PART_BG.length]].join(\" \")} />\n <span className=\"text-fg\">{p.label}</span>\n <span className=\"tabular-nums\">{p.words}</span>\n </li>\n ))}\n </ul>\n );\n\n if (variant === \"ring\") {\n const r = 44;\n return (\n <div {...a11y} data-level={parts ? undefined : level} className={[\"inline-flex flex-col items-center gap-2\", className].filter(Boolean).join(\" \")} {...props}>\n <div className={s.ring()}>\n <svg viewBox=\"0 0 100 100\" className=\"h-full w-full -rotate-90\" aria-hidden>\n <circle cx=\"50\" cy=\"50\" r={r} fill=\"none\" strokeWidth=\"9\" className=\"stroke-border-default\" />\n {arcs.map((arc, i) => {\n const length = Math.max(0, arc.len * 100 - (parts ? 1 : 0));\n return (\n <circle\n key={i}\n cx=\"50\"\n cy=\"50\"\n r={r}\n fill=\"none\"\n strokeWidth=\"9\"\n pathLength={100}\n strokeDasharray={`${length} ${100 - length}`}\n strokeDashoffset={-arc.start * 100}\n className={[arc.part === undefined ? STROKE[level] : PART_STROKE[arc.part % PART_STROKE.length], \"transition-[stroke-dasharray] duration-700 motion-reduce:transition-none\"].join(\" \")}\n />\n );\n })}\n </svg>\n {children !== undefined && <div className={s.center()}>{children}</div>}\n </div>\n {legend}\n </div>\n );\n }\n\n return (\n <div {...a11y} data-level={parts ? undefined : level} className={s.root({ className })} {...props}>\n {showLabel && (\n <div aria-hidden className={s.header()}>\n <span className={s.caption()}>{label}</span>\n {!parts && <span className={s.figure()}>{words}</span>}\n </div>\n )}\n <div aria-hidden className={s.track()}>\n {parts ? (\n shares.map((p) => <span key={p.i} className={[s.fill(), PART_BG[p.i % PART_BG.length]].join(\" \")} style={{ width: `${p.ratio * 100}%` }} />)\n ) : (\n <span className={[s.fill(), BG[level]].join(\" \")} style={{ width: `${ratio * 100}%` }} />\n )}\n </div>\n {legend}\n </div>\n );\n}\n\nexport interface MeterValueProps {\n /** The figure. */\n value: React.ReactNode;\n /** A word under it. */\n caption?: React.ReactNode;\n}\n\n/** For the ring's centre when it shows a figure and a word. */\nexport function MeterValue({ value, caption }: MeterValueProps) {\n return (\n <>\n <span className=\"font-display text-lg font-semibold text-fg tabular-nums\">{value}</span>\n {caption && <span className=\"text-[10px] text-fg-secondary\">{caption}</span>}\n </>\n );\n}\n","// Headless: the arithmetic of a Meter, read by the web (`meter.tsx`) and the native (`native/meter.tsx`) alike.\n\nexport interface MeterPart {\n /** Its name (“To the creator”) — passed translated. */\n label: string;\n /** Its value, in the meter's unit. */\n value: number;\n /** Its value in words (“€9.00”), in the legend and for assistive technology; default: its percentage. */\n valueText?: string;\n}\n\n/** Which end of the range is good: `low` (a quota) or `high` (a score, a balance). */\nexport const MeterOptimum = { Low: \"low\", High: \"high\" } as const;\nexport type MeterOptimum = (typeof MeterOptimum)[keyof typeof MeterOptimum];\n\n/** The tone of a fill: the accent without thresholds, otherwise good, warning or bad. */\nexport const MeterLevel = { Ok: \"ok\", Success: \"success\", Warning: \"warning\", Danger: \"danger\" } as const;\nexport type MeterLevel = (typeof MeterLevel)[keyof typeof MeterLevel];\n\nexport interface MeterThresholds {\n readonly low: number;\n readonly high: number;\n}\n\nexport interface MeterInput {\n value?: number;\n min?: number;\n max?: number;\n valueText?: string;\n thresholds?: MeterThresholds;\n optimum?: MeterOptimum;\n parts?: readonly MeterPart[];\n}\n\nexport interface MeterShare extends MeterPart {\n i: number;\n /** Its share of the range, 0–1. */\n ratio: number;\n /** Its value in words. */\n words: string;\n}\n\n/** One arc of a ring, as fractions of the circle: the part it draws (none for the whole value), its length, where it starts. */\nexport interface MeterArc {\n part: number | undefined;\n len: number;\n start: number;\n}\n\nexport interface MeterModel {\n ratio: number;\n level: MeterLevel;\n words: string;\n shares: MeterShare[];\n arcs: MeterArc[];\n}\n\nconst clamp01 = (n: number) => Math.min(1, Math.max(0, n));\nconst percent = (ratio: number) => `${Math.round(ratio * 100)} %`;\n\nfunction levelOf(ratio: number, thresholds: MeterThresholds | undefined, optimum: MeterOptimum): MeterLevel {\n if (!thresholds) return MeterLevel.Ok;\n const good = optimum === MeterOptimum.Low ? MeterLevel.Success : MeterLevel.Danger;\n const bad = optimum === MeterOptimum.Low ? MeterLevel.Danger : MeterLevel.Success;\n if (ratio >= thresholds.high) return bad;\n return ratio >= thresholds.low ? MeterLevel.Warning : good;\n}\n\n/** The ratio, tone, words, parts and ring arcs of a meter. */\nexport function meterModel({ value = 0, min = 0, max = 100, valueText, thresholds, optimum = MeterOptimum.Low, parts }: MeterInput): MeterModel {\n const span = max - min || 1;\n const ratio = clamp01((value - min) / span);\n const shares = (parts ?? []).map((p, i) => ({ ...p, i, ratio: clamp01(p.value / span), words: p.valueText ?? percent(p.value / span) }));\n let start = 0;\n const arcs = parts\n ? shares.map((p) => {\n const arc = { part: p.i, len: p.ratio, start };\n start += p.ratio;\n return arc;\n })\n : [{ part: undefined, len: ratio, start: 0 }];\n return { ratio, level: levelOf(ratio, thresholds, optimum), words: valueText ?? percent(ratio), shares, arcs };\n}\n"],"mappings":";AAKA,SAAS,UAAU;;;ACOZ,IAAM,eAAe,EAAE,KAAK,OAAO,MAAM,OAAO;AAIhD,IAAM,aAAa,EAAE,IAAI,MAAM,SAAS,WAAW,SAAS,WAAW,QAAQ,SAAS;AAyC/F,IAAM,UAAU,CAAC,MAAc,KAAK,IAAI,GAAG,KAAK,IAAI,GAAG,CAAC,CAAC;AACzD,IAAM,UAAU,CAAC,UAAkB,GAAG,KAAK,MAAM,QAAQ,GAAG,CAAC;AAE7D,SAAS,QAAQ,OAAe,YAAyC,SAAmC;AAC1G,MAAI,CAAC,WAAY,QAAO,WAAW;AACnC,QAAM,OAAO,YAAY,aAAa,MAAM,WAAW,UAAU,WAAW;AAC5E,QAAM,MAAM,YAAY,aAAa,MAAM,WAAW,SAAS,WAAW;AAC1E,MAAI,SAAS,WAAW,KAAM,QAAO;AACrC,SAAO,SAAS,WAAW,MAAM,WAAW,UAAU;AACxD;AAGO,SAAS,WAAW,EAAE,QAAQ,GAAG,MAAM,GAAG,MAAM,KAAK,WAAW,YAAY,UAAU,aAAa,KAAK,MAAM,GAA2B;AAC9I,QAAM,OAAO,MAAM,OAAO;AAC1B,QAAM,QAAQ,SAAS,QAAQ,OAAO,IAAI;AAC1C,QAAM,UAAU,SAAS,CAAC,GAAG,IAAI,CAAC,GAAG,OAAO,EAAE,GAAG,GAAG,GAAG,OAAO,QAAQ,EAAE,QAAQ,IA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I,KAAzG,EAAE,CAA0G,CAAE,IAE3I,oBAAC,UAAK,WAAW,CAAC,EAAE,KAAK,GAAG,GAAG,KAAK,CAAC,EAAE,KAAK,GAAG,GAAG,OAAO,EAAE,OAAO,GAAG,QAAQ,GAAG,IAAI,GAAG,GAE3F;AAAA,IACC;AAAA,KACH;AAEJ;AAUO,SAAS,WAAW,EAAE,OAAO,QAAQ,GAAoB;AAC9D,SACE,iCACE;AAAA,wBAAC,UAAK,WAAU,2DAA2D,iBAAM;AAAA,IAChF,WAAW,oBAAC,UAAK,WAAU,iCAAiC,mBAAQ;AAAA,KACvE;AAEJ;","names":[]}
@@ -0,0 +1,16 @@
1
+ // src/deprecated.ts
2
+ var DEPRECATED_SINCE = "3.55.0";
3
+ var REMOVED_IN = "4.0.0";
4
+ var warned = /* @__PURE__ */ new Set();
5
+ function warnDeprecated(entry, since = DEPRECATED_SINCE) {
6
+ if (typeof process === "undefined" || process.env.NODE_ENV === "production" || warned.has(entry)) return;
7
+ warned.add(entry);
8
+ console.warn(
9
+ `@krizaka/ui/${entry} is deprecated since ${since} and is removed in ${REMOVED_IN} (ADR-006): no product uses it. Keep it? Comment on krizaka-ui#674 with the issue that needs it. https://ui.krizaka.com/components/${entry.replace(/^native\//, "")}`
10
+ );
11
+ }
12
+
13
+ export {
14
+ warnDeprecated
15
+ };
16
+ //# sourceMappingURL=chunk-KGLRZMCY.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/deprecated.ts"],"sourcesContent":["// The development warning of a deprecated entry (ADR-006 §7, krizaka-ui#674). An entry is deprecated in a minor and\n// removed in the next major; until then it works exactly as before and says so once per page, in development only —\n// never in production, never twice. The same facts live in the entry's `meta.ts` (`status: \"deprecated\"`), which\n// ui.krizaka.com reads for its badge.\n\n/** The release that deprecated the batch. */\nexport const DEPRECATED_SINCE = \"3.55.0\";\n/** The major that removes it. */\nexport const REMOVED_IN = \"4.0.0\";\n\nconst warned = new Set<string>();\n\n/**\n * Warns once per page, in development, that `@krizaka/ui/<entry>` is deprecated. Call it at the top of the entry's\n * components; it costs a `Set` lookup and nothing in production.\n * @param entry the entry's name as imported: `tree-view` for `@krizaka/ui/tree-view`.\n * @param since the release that deprecated it, when it is not this batch's.\n */\nexport function warnDeprecated(entry: string, since: string = DEPRECATED_SINCE): void {\n if (typeof process === \"undefined\" || process.env.NODE_ENV === \"production\" || warned.has(entry)) return;\n warned.add(entry);\n console.warn(\n `@krizaka/ui/${entry} is deprecated since ${since} and is removed in ${REMOVED_IN} (ADR-006): no product uses it. ` +\n `Keep it? Comment on krizaka-ui#674 with the issue that needs it. https://ui.krizaka.com/components/${entry.replace(/^native\\//, \"\")}`,\n );\n}\n\n/** Forgets what was warned (tests only). */\nexport function resetDeprecationWarnings(): void {\n warned.clear();\n}\n"],"mappings":";AAMO,IAAM,mBAAmB;AAEzB,IAAM,aAAa;AAE1B,IAAM,SAAS,oBAAI,IAAY;AAQxB,SAAS,eAAe,OAAe,QAAgB,kBAAwB;AACpF,MAAI,OAAO,YAAY,eAAe,QAAQ,IAAI,aAAa,gBAAgB,OAAO,IAAI,KAAK,EAAG;AAClG,SAAO,IAAI,KAAK;AAChB,UAAQ;AAAA,IACN,eAAe,KAAK,wBAAwB,KAAK,sBAAsB,UAAU,sIACuB,MAAM,QAAQ,aAAa,EAAE,CAAC;AAAA,EACxI;AACF;","names":[]}
@@ -0,0 +1,18 @@
1
+ "use client";
2
+
3
+ // src/kbd/kbd.tsx
4
+ import { tv } from "tailwind-variants";
5
+ import { jsx } from "react/jsx-runtime";
6
+ var kbdVariants = tv({
7
+ base: "inline-flex shrink-0 items-center justify-center rounded-md border border-border-default border-b-2 bg-surface-2 font-mono font-semibold text-fg-secondary",
8
+ variants: { size: { sm: "h-5 min-w-5 px-1 text-[10px]", md: "h-6 min-w-6 px-1.5 text-xs" } },
9
+ defaultVariants: { size: "md" }
10
+ });
11
+ function Kbd({ size, className, ...props }) {
12
+ return /* @__PURE__ */ jsx("kbd", { className: kbdVariants({ size, className }), ...props });
13
+ }
14
+
15
+ export {
16
+ Kbd
17
+ };
18
+ //# sourceMappingURL=chunk-KID32IRJ.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/kbd/kbd.tsx"],"sourcesContent":["// Server-safe. A key, or a shortcut of several (`<Kbd>⌘</Kbd><Kbd>K</Kbd>`).\nimport type * as React from \"react\";\nimport { tv, type VariantProps } from \"tailwind-variants\";\n\nexport const kbdVariants = tv({\n base:\n \"inline-flex shrink-0 items-center justify-center rounded-md border border-border-default border-b-2 bg-surface-2 \" +\n \"font-mono font-semibold text-fg-secondary\",\n variants: { size: { sm: \"h-5 min-w-5 px-1 text-[10px]\", md: \"h-6 min-w-6 px-1.5 text-xs\" } },\n defaultVariants: { size: \"md\" },\n});\n\nexport type KbdProps = React.ComponentProps<\"kbd\"> & {\n /**\n * sm · md.\n * @default \"md\"\n */\n size?: VariantProps<typeof kbdVariants>[\"size\"];\n};\n\nexport function Kbd({ size, className, ...props }: KbdProps) {\n return <kbd className={kbdVariants({ size, className })} {...props} />;\n}\n"],"mappings":";;;AAEA,SAAS,UAA6B;AAmB7B;AAjBF,IAAM,cAAc,GAAG;AAAA,EAC5B,MACE;AAAA,EAEF,UAAU,EAAE,MAAM,EAAE,IAAI,gCAAgC,IAAI,6BAA6B,EAAE;AAAA,EAC3F,iBAAiB,EAAE,MAAM,KAAK;AAChC,CAAC;AAUM,SAAS,IAAI,EAAE,MAAM,WAAW,GAAG,MAAM,GAAa;AAC3D,SAAO,oBAAC,SAAI,WAAW,YAAY,EAAE,MAAM,UAAU,CAAC,GAAI,GAAG,OAAO;AACtE;","names":[]}
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  Chip
4
- } from "./chunk-HHFWK2HH.js";
4
+ } from "./chunk-VIPSZXO4.js";
5
5
  import {
6
6
  floating
7
7
  } from "./chunk-J3NC6ER4.js";
@@ -176,4 +176,4 @@ export {
176
176
  readFilterParams,
177
177
  writeFilterParams
178
178
  };
179
- //# sourceMappingURL=chunk-ZQW7LF4Y.js.map
179
+ //# sourceMappingURL=chunk-OIMXKRXF.js.map