@slotted/react 0.1.0-beta.39 → 0.1.0-beta.40

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 (394) hide show
  1. package/dist/alert-CV8wKS-N.js +179 -0
  2. package/dist/alert.js +1 -1
  3. package/dist/{avatar-DLWElrgg.js → avatar-fHRva5zn.js} +1 -1
  4. package/dist/{avatar-group-DshHqe8B.js → avatar-group-bJaZE1_C.js} +1 -1
  5. package/dist/avatar-group.js +1 -1
  6. package/dist/avatar.js +1 -1
  7. package/dist/calendar-D3QZDlm0.js +598 -0
  8. package/dist/calendar.js +1 -1
  9. package/dist/clock-DzkQa57Q.js +290 -0
  10. package/dist/clock.js +2 -0
  11. package/dist/{dashboard-grid-B6jxBz4j.js → dashboard-grid-DAY_CjCW.js} +1 -1
  12. package/dist/dashboard-grid.js +1 -1
  13. package/dist/{data-grid-Cx0ZOf_e.js → data-grid-B7UuUvBH.js} +42 -37
  14. package/dist/data-grid.js +1 -1
  15. package/dist/{data-list-Cb2sNA6I.js → data-list-CyEq7M2D.js} +1 -1
  16. package/dist/data-list.js +1 -1
  17. package/dist/date-picker-DMcMFW_N.js +344 -0
  18. package/dist/date-picker.js +3 -2
  19. package/dist/date-range-picker-D9zo93NE.js +543 -0
  20. package/dist/date-range-picker.js +2 -2
  21. package/dist/datetime-picker-lOXZbAx_.js +462 -0
  22. package/dist/datetime-picker.js +2 -2
  23. package/dist/datetime-range-picker-DU5ctZbm.js +641 -0
  24. package/dist/datetime-range-picker.js +2 -2
  25. package/dist/divider-DUUPCIh4.js +35 -0
  26. package/dist/divider.js +1 -1
  27. package/dist/docs/alert.examples.md +500 -0
  28. package/dist/docs/alert.json +85 -37
  29. package/dist/docs/alert.md +37 -189
  30. package/dist/docs/aspect-ratio.json +40 -16
  31. package/dist/docs/aspect-ratio.md +204 -29
  32. package/dist/docs/avatar.json +125 -29
  33. package/dist/docs/avatar.md +374 -31
  34. package/dist/docs/badge.json +119 -23
  35. package/dist/docs/badge.md +436 -27
  36. package/dist/docs/calendar.json +53 -5
  37. package/dist/docs/calendar.md +7 -2
  38. package/dist/docs/card.json +98 -10
  39. package/dist/docs/card.md +468 -26
  40. package/dist/docs/clock.json +405 -0
  41. package/dist/docs/clock.md +189 -0
  42. package/dist/docs/container.json +54 -6
  43. package/dist/docs/container.md +247 -17
  44. package/dist/docs/date-picker.examples.md +143 -169
  45. package/dist/docs/date-picker.json +178 -223
  46. package/dist/docs/date-picker.md +44 -50
  47. package/dist/docs/date-range-picker.examples.md +169 -187
  48. package/dist/docs/date-range-picker.json +206 -337
  49. package/dist/docs/date-range-picker.md +52 -67
  50. package/dist/docs/datetime-picker.examples.md +75 -210
  51. package/dist/docs/datetime-picker.json +183 -410
  52. package/dist/docs/datetime-picker.md +50 -72
  53. package/dist/docs/datetime-range-picker.json +225 -502
  54. package/dist/docs/datetime-range-picker.md +250 -101
  55. package/dist/docs/divider.json +71 -7
  56. package/dist/docs/divider.md +281 -13
  57. package/dist/docs/grid.json +76 -12
  58. package/dist/docs/grid.md +376 -18
  59. package/dist/docs/index.md +1 -0
  60. package/dist/docs/inline-message.json +87 -40
  61. package/dist/docs/inline-message.md +314 -71
  62. package/dist/docs/inline.json +65 -9
  63. package/dist/docs/inline.md +276 -13
  64. package/dist/docs/kbd.json +76 -36
  65. package/dist/docs/kbd.md +346 -63
  66. package/dist/docs/link.json +65 -25
  67. package/dist/docs/link.md +317 -60
  68. package/dist/docs/progress-indicator.examples.md +522 -0
  69. package/dist/docs/progress-indicator.json +51 -27
  70. package/dist/docs/progress-indicator.md +13 -238
  71. package/dist/docs/result-state.examples.md +752 -0
  72. package/dist/docs/result-state.json +95 -47
  73. package/dist/docs/result-state.md +45 -228
  74. package/dist/docs/skeleton.json +70 -38
  75. package/dist/docs/skeleton.md +393 -71
  76. package/dist/docs/stack.json +57 -9
  77. package/dist/docs/stack.md +225 -12
  78. package/dist/docs/table.examples.md +6 -10
  79. package/dist/docs/table.json +5 -5
  80. package/dist/docs/table.md +1 -1
  81. package/dist/docs/tag.examples.md +503 -0
  82. package/dist/docs/tag.json +128 -32
  83. package/dist/docs/tag.md +27 -138
  84. package/dist/docs/time-picker.json +162 -300
  85. package/dist/docs/time-picker.md +100 -154
  86. package/dist/docs/time-range-picker.json +203 -465
  87. package/dist/docs/time-range-picker.md +125 -173
  88. package/dist/docs/toast.examples.md +690 -0
  89. package/dist/docs/toast.json +119 -71
  90. package/dist/docs/toast.md +44 -212
  91. package/dist/docs/tree.examples.md +2008 -0
  92. package/dist/docs/tree.json +283 -106
  93. package/dist/docs/tree.md +96 -328
  94. package/dist/docs/visually-hidden.json +38 -6
  95. package/dist/docs/visually-hidden.md +148 -11
  96. package/dist/{entity-picker-CwfA1wr_.js → entity-picker-BwJX0gNJ.js} +1 -1
  97. package/dist/entity-picker.js +1 -1
  98. package/dist/{filter-bar-b8bRNPs9.js → filter-bar-BQZFgV0A.js} +5 -3
  99. package/dist/filter-bar.js +1 -1
  100. package/dist/{import-export-center-C_oNc-RM.js → import-export-center-DWSEOV5Z.js} +3 -3
  101. package/dist/import-export-center.js +1 -1
  102. package/dist/index.js +101 -99
  103. package/dist/{markdown-x59MHBAa.js → markdown-7wOBMXTl.js} +1 -1
  104. package/dist/markdown.js +1 -1
  105. package/dist/picker-frame-_9ZqQOjf.js +43 -0
  106. package/dist/picker-group-CrNRKUxz.js +33 -0
  107. package/dist/picker-head-C_Z0tQGq.js +69 -0
  108. package/dist/picker-jump-BcTRIJs6.js +70 -0
  109. package/dist/picker-range-head-B4tsDOc5.js +100 -0
  110. package/dist/picker-step-MgBwF9g1.js +26 -0
  111. package/dist/read-title-id-DQZVWlMt.js +14 -0
  112. package/dist/result-state-Ct9AB01a.js +123 -0
  113. package/dist/result-state.js +1 -1
  114. package/dist/styles/app-shell.css +1 -1
  115. package/dist/styles/aspect-ratio.css +1 -1
  116. package/dist/styles/attachment.css +1 -1
  117. package/dist/styles/badge.css +1 -1
  118. package/dist/styles/calendar.css +1 -1
  119. package/dist/styles/cascader.css +1 -1
  120. package/dist/styles/chart.css +1 -1
  121. package/dist/styles/clock.css +2 -0
  122. package/dist/styles/code-block.css +1 -1
  123. package/dist/styles/command-palette.css +1 -1
  124. package/dist/styles/dashboard-grid.css +1 -1
  125. package/dist/styles/data-grid.css +14 -10
  126. package/dist/styles/data-list.css +1 -1
  127. package/dist/styles/date-picker.css +4 -2
  128. package/dist/styles/date-range-picker.css +4 -2
  129. package/dist/styles/datetime-picker.css +8 -2
  130. package/dist/styles/datetime-range-picker.css +6 -2
  131. package/dist/styles/detail-panel.css +3 -3
  132. package/dist/styles/entity-picker.css +1 -1
  133. package/dist/styles/event-calendar.css +1 -1
  134. package/dist/styles/filter-bar.css +11 -7
  135. package/dist/styles/grid.css +1 -1
  136. package/dist/styles/image.css +1 -1
  137. package/dist/styles/import-export-center.css +15 -11
  138. package/dist/styles/index.css +21 -17
  139. package/dist/styles/inline.css +1 -1
  140. package/dist/styles/loading-overlay.css +1 -1
  141. package/dist/styles/markdown.css +1 -1
  142. package/dist/styles/multi-select.css +1 -1
  143. package/dist/styles/notification-center.css +1 -1
  144. package/dist/styles/page-header.css +2 -2
  145. package/dist/styles/progress-indicator.css +1 -1
  146. package/dist/styles/side-navigation.css +2 -2
  147. package/dist/styles/skeleton.css +1 -1
  148. package/dist/styles/stack.css +1 -1
  149. package/dist/styles/stat-card.css +1 -1
  150. package/dist/styles/table-of-contents.css +1 -1
  151. package/dist/styles/table.css +14 -10
  152. package/dist/styles/time-picker.css +5 -1
  153. package/dist/styles/time-range-picker.css +5 -1
  154. package/dist/styles/toast.css +1 -1
  155. package/dist/styles/top-navigation.css +1 -1
  156. package/dist/styles/tree.css +1 -1
  157. package/dist/styles/upload.css +1 -1
  158. package/dist/styles/wizard.css +1 -1
  159. package/dist/styles.css +1 -1
  160. package/dist/{table-DqwYPHGS.js → table-MGb3iZY_.js} +11 -6
  161. package/dist/table.js +1 -1
  162. package/dist/time-picker-z4GSRuha.js +313 -0
  163. package/dist/time-picker.js +2 -2
  164. package/dist/time-range-picker-ar40oPcf.js +563 -0
  165. package/dist/time-range-picker.js +2 -2
  166. package/dist/{toast-DHDVXIew.js → toast-Cg28GkqX.js} +121 -117
  167. package/dist/toast.js +1 -1
  168. package/dist/tree-CytfCFT-.js +874 -0
  169. package/dist/tree.js +1 -1
  170. package/dist/types/alert/alert-parts.d.ts +1 -1
  171. package/dist/types/alert/alert-parts.d.ts.map +1 -1
  172. package/dist/types/alert/alert.d.ts.map +1 -1
  173. package/dist/types/alert/alert.types.d.ts +1 -1
  174. package/dist/types/alert/alert.types.d.ts.map +1 -1
  175. package/dist/types/avatar/avatar.d.ts.map +1 -1
  176. package/dist/types/badge/badge.types.d.ts +1 -1
  177. package/dist/types/badge/badge.types.d.ts.map +1 -1
  178. package/dist/types/calendar/calendar-day-cell.d.ts +3 -1
  179. package/dist/types/calendar/calendar-day-cell.d.ts.map +1 -1
  180. package/dist/types/calendar/calendar-header.d.ts +9 -5
  181. package/dist/types/calendar/calendar-header.d.ts.map +1 -1
  182. package/dist/types/calendar/calendar-month-table.d.ts +8 -3
  183. package/dist/types/calendar/calendar-month-table.d.ts.map +1 -1
  184. package/dist/types/calendar/calendar.d.ts +1 -1
  185. package/dist/types/calendar/calendar.d.ts.map +1 -1
  186. package/dist/types/calendar/calendar.types.d.ts +12 -1
  187. package/dist/types/calendar/calendar.types.d.ts.map +1 -1
  188. package/dist/types/clock/clock-body.d.ts +16 -0
  189. package/dist/types/clock/clock-body.d.ts.map +1 -0
  190. package/dist/types/clock/clock-demo.d.ts +15 -0
  191. package/dist/types/clock/clock-demo.d.ts.map +1 -0
  192. package/dist/types/clock/clock-groups.d.ts +15 -0
  193. package/dist/types/clock/clock-groups.d.ts.map +1 -0
  194. package/dist/types/clock/clock-option.d.ts +14 -0
  195. package/dist/types/clock/clock-option.d.ts.map +1 -0
  196. package/dist/types/clock/clock-units.d.ts +13 -0
  197. package/dist/types/clock/clock-units.d.ts.map +1 -0
  198. package/dist/types/clock/clock.d.ts +11 -0
  199. package/dist/types/clock/clock.d.ts.map +1 -0
  200. package/dist/types/clock/clock.types.d.ts +66 -0
  201. package/dist/types/clock/clock.types.d.ts.map +1 -0
  202. package/dist/types/clock/index.d.ts +3 -0
  203. package/dist/types/clock/index.d.ts.map +1 -0
  204. package/dist/types/clock/use-clock-grid.d.ts +28 -0
  205. package/dist/types/clock/use-clock-grid.d.ts.map +1 -0
  206. package/dist/types/clock/use-clock-view.d.ts +16 -0
  207. package/dist/types/clock/use-clock-view.d.ts.map +1 -0
  208. package/dist/types/data-grid/data-grid-filter.d.ts.map +1 -1
  209. package/dist/types/date-picker/date-panel.d.ts +32 -0
  210. package/dist/types/date-picker/date-panel.d.ts.map +1 -0
  211. package/dist/types/date-picker/date-picker-demo.d.ts +8 -15
  212. package/dist/types/date-picker/date-picker-demo.d.ts.map +1 -1
  213. package/dist/types/date-picker/date-picker-panel.d.ts +18 -0
  214. package/dist/types/date-picker/date-picker-panel.d.ts.map +1 -0
  215. package/dist/types/date-picker/date-picker.d.ts +7 -13
  216. package/dist/types/date-picker/date-picker.d.ts.map +1 -1
  217. package/dist/types/date-picker/date-picker.types.d.ts +15 -16
  218. package/dist/types/date-picker/date-picker.types.d.ts.map +1 -1
  219. package/dist/types/date-picker/index.d.ts +1 -1
  220. package/dist/types/date-picker/index.d.ts.map +1 -1
  221. package/dist/types/date-picker/month-picker.d.ts +12 -0
  222. package/dist/types/date-picker/month-picker.d.ts.map +1 -0
  223. package/dist/types/date-picker/use-date-panel.d.ts +50 -0
  224. package/dist/types/date-picker/use-date-panel.d.ts.map +1 -0
  225. package/dist/types/date-picker/use-date-picker.d.ts +24 -0
  226. package/dist/types/date-picker/use-date-picker.d.ts.map +1 -0
  227. package/dist/types/date-range-picker/date-range-control.d.ts +34 -0
  228. package/dist/types/date-range-picker/date-range-control.d.ts.map +1 -0
  229. package/dist/types/date-range-picker/date-range-panel.d.ts +24 -0
  230. package/dist/types/date-range-picker/date-range-panel.d.ts.map +1 -0
  231. package/dist/types/date-range-picker/date-range-picker-demo.d.ts +8 -15
  232. package/dist/types/date-range-picker/date-range-picker-demo.d.ts.map +1 -1
  233. package/dist/types/date-range-picker/date-range-picker.d.ts +11 -21
  234. package/dist/types/date-range-picker/date-range-picker.d.ts.map +1 -1
  235. package/dist/types/date-range-picker/date-range-picker.types.d.ts +12 -26
  236. package/dist/types/date-range-picker/date-range-picker.types.d.ts.map +1 -1
  237. package/dist/types/date-range-picker/index.d.ts +2 -2
  238. package/dist/types/date-range-picker/index.d.ts.map +1 -1
  239. package/dist/types/date-range-picker/range-words.d.ts +30 -0
  240. package/dist/types/date-range-picker/range-words.d.ts.map +1 -0
  241. package/dist/types/date-range-picker/use-date-range-picker.d.ts +32 -0
  242. package/dist/types/date-range-picker/use-date-range-picker.d.ts.map +1 -0
  243. package/dist/types/date-range-picker/use-range-draft.d.ts +39 -0
  244. package/dist/types/date-range-picker/use-range-draft.d.ts.map +1 -0
  245. package/dist/types/date-range-picker/use-range-panel.d.ts +71 -0
  246. package/dist/types/date-range-picker/use-range-panel.d.ts.map +1 -0
  247. package/dist/types/datetime-picker/datetime-picker-defaults.d.ts +3 -9
  248. package/dist/types/datetime-picker/datetime-picker-defaults.d.ts.map +1 -1
  249. package/dist/types/datetime-picker/datetime-picker-demo.d.ts +8 -31
  250. package/dist/types/datetime-picker/datetime-picker-demo.d.ts.map +1 -1
  251. package/dist/types/datetime-picker/datetime-picker-panel.d.ts +23 -0
  252. package/dist/types/datetime-picker/datetime-picker-panel.d.ts.map +1 -0
  253. package/dist/types/datetime-picker/datetime-picker.d.ts +8 -19
  254. package/dist/types/datetime-picker/datetime-picker.d.ts.map +1 -1
  255. package/dist/types/datetime-picker/datetime-picker.types.d.ts +25 -66
  256. package/dist/types/datetime-picker/datetime-picker.types.d.ts.map +1 -1
  257. package/dist/types/datetime-picker/index.d.ts +2 -2
  258. package/dist/types/datetime-picker/index.d.ts.map +1 -1
  259. package/dist/types/datetime-picker/use-datetime-panel.d.ts +69 -0
  260. package/dist/types/datetime-picker/use-datetime-panel.d.ts.map +1 -0
  261. package/dist/types/datetime-picker/use-datetime-picker.d.ts +22 -0
  262. package/dist/types/datetime-picker/use-datetime-picker.d.ts.map +1 -0
  263. package/dist/types/datetime-range-picker/datetime-range-half.d.ts +20 -0
  264. package/dist/types/datetime-range-picker/datetime-range-half.d.ts.map +1 -0
  265. package/dist/types/datetime-range-picker/datetime-range-panel.d.ts +30 -0
  266. package/dist/types/datetime-range-picker/datetime-range-panel.d.ts.map +1 -0
  267. package/dist/types/datetime-range-picker/datetime-range-picker-defaults.d.ts +5 -7
  268. package/dist/types/datetime-range-picker/datetime-range-picker-defaults.d.ts.map +1 -1
  269. package/dist/types/datetime-range-picker/datetime-range-picker-demo.d.ts +8 -24
  270. package/dist/types/datetime-range-picker/datetime-range-picker-demo.d.ts.map +1 -1
  271. package/dist/types/datetime-range-picker/datetime-range-picker.d.ts +12 -24
  272. package/dist/types/datetime-range-picker/datetime-range-picker.d.ts.map +1 -1
  273. package/dist/types/datetime-range-picker/datetime-range-picker.types.d.ts +31 -66
  274. package/dist/types/datetime-range-picker/datetime-range-picker.types.d.ts.map +1 -1
  275. package/dist/types/datetime-range-picker/datetime-range-words.d.ts +40 -0
  276. package/dist/types/datetime-range-picker/datetime-range-words.d.ts.map +1 -0
  277. package/dist/types/datetime-range-picker/index.d.ts +4 -3
  278. package/dist/types/datetime-range-picker/index.d.ts.map +1 -1
  279. package/dist/types/datetime-range-picker/use-datetime-range-draft.d.ts +43 -0
  280. package/dist/types/datetime-range-picker/use-datetime-range-draft.d.ts.map +1 -0
  281. package/dist/types/datetime-range-picker/use-datetime-range-panel.d.ts +82 -0
  282. package/dist/types/datetime-range-picker/use-datetime-range-panel.d.ts.map +1 -0
  283. package/dist/types/datetime-range-picker/use-datetime-range-picker.d.ts +28 -0
  284. package/dist/types/datetime-range-picker/use-datetime-range-picker.d.ts.map +1 -0
  285. package/dist/types/divider/divider.d.ts +1 -1
  286. package/dist/types/divider/divider.d.ts.map +1 -1
  287. package/dist/types/filter-bar/filter-bar-rules.d.ts.map +1 -1
  288. package/dist/types/index.d.ts +1 -0
  289. package/dist/types/index.d.ts.map +1 -1
  290. package/dist/types/picker-panel/picker-footer.d.ts +17 -0
  291. package/dist/types/picker-panel/picker-footer.d.ts.map +1 -0
  292. package/dist/types/picker-panel/picker-frame.d.ts +21 -0
  293. package/dist/types/picker-panel/picker-frame.d.ts.map +1 -0
  294. package/dist/types/picker-panel/picker-group.d.ts +18 -0
  295. package/dist/types/picker-panel/picker-group.d.ts.map +1 -0
  296. package/dist/types/picker-panel/picker-head.d.ts +27 -0
  297. package/dist/types/picker-panel/picker-head.d.ts.map +1 -0
  298. package/dist/types/picker-panel/picker-jump.d.ts +18 -0
  299. package/dist/types/picker-panel/picker-jump.d.ts.map +1 -0
  300. package/dist/types/picker-panel/picker-layer.d.ts +14 -0
  301. package/dist/types/picker-panel/picker-layer.d.ts.map +1 -0
  302. package/dist/types/picker-panel/picker-panel.d.ts +17 -0
  303. package/dist/types/picker-panel/picker-panel.d.ts.map +1 -0
  304. package/dist/types/picker-panel/picker-rail.d.ts +17 -0
  305. package/dist/types/picker-panel/picker-rail.d.ts.map +1 -0
  306. package/dist/types/picker-panel/picker-range-head.d.ts +37 -0
  307. package/dist/types/picker-panel/picker-range-head.d.ts.map +1 -0
  308. package/dist/types/picker-panel/picker-ruler.d.ts +14 -0
  309. package/dist/types/picker-panel/picker-ruler.d.ts.map +1 -0
  310. package/dist/types/picker-panel/picker-step.d.ts +11 -0
  311. package/dist/types/picker-panel/picker-step.d.ts.map +1 -0
  312. package/dist/types/picker-panel/picker-trigger.d.ts +16 -0
  313. package/dist/types/picker-panel/picker-trigger.d.ts.map +1 -0
  314. package/dist/types/picker-panel/use-media-query.d.ts +3 -0
  315. package/dist/types/picker-panel/use-media-query.d.ts.map +1 -0
  316. package/dist/types/picker-panel/use-picker-draft.d.ts +18 -0
  317. package/dist/types/picker-panel/use-picker-draft.d.ts.map +1 -0
  318. package/dist/types/picker-panel/use-picker-layer.d.ts +31 -0
  319. package/dist/types/picker-panel/use-picker-layer.d.ts.map +1 -0
  320. package/dist/types/picker-panel/use-picker-open.d.ts +14 -0
  321. package/dist/types/picker-panel/use-picker-open.d.ts.map +1 -0
  322. package/dist/types/picker-panel/use-picker-position.d.ts +12 -0
  323. package/dist/types/picker-panel/use-picker-position.d.ts.map +1 -0
  324. package/dist/types/picker-panel/use-picker-value.d.ts +20 -0
  325. package/dist/types/picker-panel/use-picker-value.d.ts.map +1 -0
  326. package/dist/types/result-state/result-state.d.ts +32 -2
  327. package/dist/types/result-state/result-state.d.ts.map +1 -1
  328. package/dist/types/table/table-filter.d.ts.map +1 -1
  329. package/dist/types/table/table.types.d.ts +16 -14
  330. package/dist/types/table/table.types.d.ts.map +1 -1
  331. package/dist/types/tag/tag.types.d.ts +1 -1
  332. package/dist/types/tag/tag.types.d.ts.map +1 -1
  333. package/dist/types/time-picker/index.d.ts +2 -2
  334. package/dist/types/time-picker/index.d.ts.map +1 -1
  335. package/dist/types/time-picker/time-picker-defaults.d.ts +0 -7
  336. package/dist/types/time-picker/time-picker-defaults.d.ts.map +1 -1
  337. package/dist/types/time-picker/time-picker-demo.d.ts +15 -0
  338. package/dist/types/time-picker/time-picker-demo.d.ts.map +1 -0
  339. package/dist/types/time-picker/time-picker-panel.d.ts +17 -0
  340. package/dist/types/time-picker/time-picker-panel.d.ts.map +1 -0
  341. package/dist/types/time-picker/time-picker.d.ts +6 -14
  342. package/dist/types/time-picker/time-picker.d.ts.map +1 -1
  343. package/dist/types/time-picker/time-picker.types.d.ts +21 -45
  344. package/dist/types/time-picker/time-picker.types.d.ts.map +1 -1
  345. package/dist/types/time-picker/use-time-panel.d.ts +42 -0
  346. package/dist/types/time-picker/use-time-panel.d.ts.map +1 -0
  347. package/dist/types/time-picker/use-time-picker.d.ts +27 -0
  348. package/dist/types/time-picker/use-time-picker.d.ts.map +1 -0
  349. package/dist/types/time-range-picker/index.d.ts +4 -3
  350. package/dist/types/time-range-picker/index.d.ts.map +1 -1
  351. package/dist/types/time-range-picker/time-range-panel.d.ts +23 -0
  352. package/dist/types/time-range-picker/time-range-panel.d.ts.map +1 -0
  353. package/dist/types/time-range-picker/time-range-picker-defaults.d.ts +2 -4
  354. package/dist/types/time-range-picker/time-range-picker-defaults.d.ts.map +1 -1
  355. package/dist/types/time-range-picker/time-range-picker-demo.d.ts +8 -24
  356. package/dist/types/time-range-picker/time-range-picker-demo.d.ts.map +1 -1
  357. package/dist/types/time-range-picker/time-range-picker.d.ts +12 -28
  358. package/dist/types/time-range-picker/time-range-picker.d.ts.map +1 -1
  359. package/dist/types/time-range-picker/time-range-picker.types.d.ts +24 -64
  360. package/dist/types/time-range-picker/time-range-picker.types.d.ts.map +1 -1
  361. package/dist/types/time-range-picker/time-range-words.d.ts +37 -0
  362. package/dist/types/time-range-picker/time-range-words.d.ts.map +1 -0
  363. package/dist/types/time-range-picker/use-time-range-panel.d.ts +68 -0
  364. package/dist/types/time-range-picker/use-time-range-panel.d.ts.map +1 -0
  365. package/dist/types/time-range-picker/use-time-range-picker.d.ts +25 -0
  366. package/dist/types/time-range-picker/use-time-range-picker.d.ts.map +1 -0
  367. package/dist/types/title-id/read-title-id.d.ts +15 -0
  368. package/dist/types/title-id/read-title-id.d.ts.map +1 -0
  369. package/dist/types/toast/toast.d.ts.map +1 -1
  370. package/dist/types/tree/index.d.ts +1 -1
  371. package/dist/types/tree/index.d.ts.map +1 -1
  372. package/dist/types/tree/tree-parts.d.ts +2 -0
  373. package/dist/types/tree/tree-parts.d.ts.map +1 -1
  374. package/dist/types/tree/tree.d.ts +1 -1
  375. package/dist/types/tree/tree.d.ts.map +1 -1
  376. package/dist/types/tree/tree.types.d.ts +15 -5
  377. package/dist/types/tree/tree.types.d.ts.map +1 -1
  378. package/dist/use-date-picker-DL8tRXji.js +63 -0
  379. package/dist/use-picker-draft-Bw8VFaj0.js +377 -0
  380. package/dist/{wizard-CL6u1aJb.js → wizard-BokOrtwq.js} +1 -1
  381. package/dist/wizard.js +1 -1
  382. package/package.json +10 -6
  383. package/dist/alert-Bi9s1cjV.js +0 -174
  384. package/dist/calendar-CX0wN5Bh.js +0 -564
  385. package/dist/date-picker-CLXTtQGe.js +0 -337
  386. package/dist/date-range-picker-Br0neGyT.js +0 -522
  387. package/dist/datetime-picker-CR-H_BLu.js +0 -683
  388. package/dist/datetime-range-picker-BLo58OIk.js +0 -1050
  389. package/dist/divider-ryFeK0Pi.js +0 -35
  390. package/dist/docs/datetime-range-picker.examples.md +0 -219
  391. package/dist/result-state-BMYhelu1.js +0 -128
  392. package/dist/time-picker-B4-GsO24.js +0 -436
  393. package/dist/time-range-picker-DVOWN8PF.js +0 -800
  394. package/dist/tree-D-y-0TrL.js +0 -794
package/dist/docs/tree.md CHANGED
@@ -21,18 +21,27 @@ import {
21
21
 
22
22
  ## Minimal example
23
23
 
24
- Excerpt — not a complete module
24
+ Example
25
25
 
26
26
  ```tsx
27
- <Tree aria-label="Project files" defaultExpandedKeys={['src']}>
28
- <TreeNode value="src" label="src" meta="12">
29
- <TreeNode value="index.ts" label="index.ts" />
30
- <TreeNode value="lib" label="lib">
31
- <TreeNode value="tree.ts" label="tree.ts" />
32
- </TreeNode>
33
- </TreeNode>
34
- <TreeNode value="readme" label="README.md" />
35
- </Tree>;
27
+ import { Tree, TreeNode } from '@slotted/react/tree';
28
+
29
+ export default function TreeBasic() {
30
+ return (
31
+ <Tree aria-label="Product categories" defaultExpandedKeys={['beverages']} defaultValue="coffee">
32
+ <TreeNode value="beverages" label="Beverages" meta="148">
33
+ <TreeNode value="coffee" label="Coffee" meta="62" />
34
+ <TreeNode value="tea" label="Tea" meta="54" />
35
+ <TreeNode value="soft-drinks" label="Soft drinks" meta="32" />
36
+ </TreeNode>
37
+ <TreeNode value="pantry" label="Pantry" meta="231">
38
+ <TreeNode value="oils" label="Oils and vinegars" meta="87" />
39
+ <TreeNode value="spices" label="Spices" meta="144" />
40
+ </TreeNode>
41
+ <TreeNode value="household" label="Household" meta="76" />
42
+ </Tree>
43
+ );
44
+ }
36
45
  ```
37
46
 
38
47
  ## Anatomy
@@ -59,78 +68,79 @@ Excerpt — not a complete module
59
68
 
60
69
  | Name | Type | Default | Applies to | Description |
61
70
  | --- | --- | --- | --- | --- |
62
- | `value` | `string \| readonly string[] \| null` | — | Tree | The chosen key, or the set of them in multiple. Present means controlled, for the life of the component |
63
- | `defaultValue` | `string \| readonly string[] \| null` | — | Tree | What an uncontrolled tree starts from, read once |
64
- | `expandedKeys` | `readonly string[]` | — | Tree | Which branches are open. Present means controlled; a filter never moves it |
65
- | `defaultExpandedKeys` | `readonly string[]` | — | Tree | The set an uncontrolled tree opens with |
66
- | `activeKey` | `string \| null` | — | Tree | The node the keyboard is on. It is not the selection, and the pattern says so |
67
- | `defaultActiveKey` | `string \| null` | — | Tree | Where the keyboard starts in an uncontrolled tree |
68
- | `size` | `'sm' \| 'md' \| 'lg'` | md | Tree | The type step the rows sit at |
69
- | `variant` | `'plain' \| 'framed'` | plain | Tree | Whether the tree draws its own box |
70
- | `structure` | `'auto' \| 'nested' \| 'flat'` | auto | Tree | Whether the nodes nest in groups or lie flat with their level stated. auto answers flat while windowed |
71
- | `selectionMode` | `'none' \| 'single' \| 'multiple'` | single | Tree | How many nodes may be chosen at once |
72
- | `selectionBehavior` | `'toggle' \| 'replace'` | toggle | Tree | Which of the two models the pattern offers is in force. toggle is the one it recommends |
73
- | `selectionIndicator` | `'auto' \| 'highlight' \| 'checkbox' \| 'none'` | auto | Tree | How the selection is drawn, and which attribute states it. auto reads the mode beside it |
74
- | `selectionCascade` | `'none' \| 'descendants'` | none | Tree | Whether pressing a branch takes its enabled descendants with it. Needs nodes |
75
- | `expandOn` | `'row' \| 'expander'` | row | Tree | What a press on the row does to a branch |
76
- | `focusMode` | `'auto' \| 'roving' \| 'activedescendant'` | auto | Tree | How the keyboard position is expressed. auto answers activedescendant while windowed |
77
- | `guides` | `boolean` | true | Tree | Whether the lines that say which parent a row belongs to are drawn |
78
- | `loop` | `boolean` | false | Tree | Whether the arrows wrap past the ends |
79
- | `typeahead` | `boolean` | true | Tree | Whether typing a name moves the keyboard to it |
80
- | `typeaheadTimeout` | `number` | 500 | Tree | Milliseconds of silence before a new search begins |
81
- | `selectOnFocus` | `boolean` | false | Tree | Whether moving the keyboard also chooses |
82
- | `navigateDisabled` | `boolean` | false | Tree | Whether the arrows land on a disabled node |
83
- | `disallowEmptySelection` | `boolean` | false | Tree | Whether the last chosen node may be unchosen |
84
- | `disallowSelectAll` | `boolean` | false | Tree | Whether Control and A may take the whole set |
85
- | `pageSize` | `number` | 10 | Tree | How far the page keys travel |
86
- | `virtual` | `boolean` | false | Tree | Whether only the rows the viewport covers are rendered |
87
- | `itemSize` | `number` | 32 | Tree | The block size of one row, in pixels. Required whenever virtual |
88
- | `overscan` | `number` | 4 | Tree | Rows rendered either side of the viewport |
89
- | `disabled` | `boolean` | false | Tree | Whether the whole tree refuses the reader |
90
- | `readOnly` | `boolean` | false | Tree | Whether the tree may be read and not moved |
91
- | `required` | `boolean` | false | Tree | Whether a choice is required of the form around it |
92
- | `invalid` | `boolean` | false | Tree | Whether the tree is in error |
93
- | `loading` | `boolean` | false | Tree | Whether the set is still arriving. Writes aria-busy |
94
- | `name` | `string` | — | Tree | Submits one hidden input per chosen key |
95
- | `nodes` | `readonly T[]` | — | Tree | The hierarchy the tree holds. What a cascade, expandAll and the filter read |
96
- | `getKey` | `(node: T) => string` | — | Tree | The identity that survives a reorder |
97
- | `getLabel` | `(node: T) => string` | — | Tree | What the reader sees and what typeahead matches |
98
- | `getChildren` | `(node: T) => readonly T[] \| undefined` | — | Tree | The children, in the nested shape |
99
- | `getLevel` | `(node: T) => number` | — | Tree | The depth, in the already-flat shape a rowset backend returns |
100
- | `hasChildren` | `(node: T) => boolean` | — | Tree | Whether a node is a branch before it can prove it |
101
- | `getChildrenCount` | `(node: T) => number \| undefined` | — | Tree | How many children will arrive, which draws the placeholder |
102
- | `isNodeDisabled` | `(node: T) => boolean` | — | Tree | Which nodes refuse the reader |
103
- | `isNodeLoading` | `(node: T) => boolean` | — | Tree | Which branches are fetching their children |
104
- | `renderNode` | `(node: T, key: string) => ReactNode` | — | Tree | The content of one row. The family renders the row around it |
105
- | `query` | `string` | — | Tree | What the tree filters by. The consumer owns the string and the field |
106
- | `emptyContent` | `ReactNode` | — | Tree | What the tree shows when it holds nothing |
107
- | `render` | `(props: TreeRootProps) => ReactNode` | — | Tree | Substitutes the element the root renders |
108
- | `handleRef` | `Ref<TreeHandle>` | — | Tree | focus, scrollToKey, expand, collapse, expandAll, collapseAll, getActiveKey, getElement |
109
- | `label` | `ReactNode` | — | TreeNode | The node's name, and what names it |
110
- | `description` | `ReactNode` | — | TreeNode | A second line beside the name |
111
- | `icon` | `ReactNode` | — | TreeNode | The leading picture, which the consumer owns whole |
112
- | `meta` | `ReactNode` | — | TreeNode | The trailing count, size or badge |
113
- | `actions` | `ReactNode` | — | TreeNode | The trailing controls, which stay reachable |
114
- | `textValue` | `string` | — | TreeNode | What typeahead matches, when the label is not plain text |
115
- | `match` | `'hit' \| 'ancestor'` | — | TreeNode | Whether a query matched this name or one below it |
116
- | `pinned` | `boolean` | — | TreeNode | Rendered at its own place on the canvas, outside the window |
117
- | `offset` | `number` | — | TreeNode | Where a pinned row sits on the canvas, in pixels |
118
- | `depth` | `number` | — | TreeNode | Stated only by the flat shape; elsewhere the markup says it |
119
- | `TreeDefaultsProvider` | `{ size, variant, expandOn, … }` | — | a subtree | Sets twenty-one axes once for every tree under it. An explicit prop still wins |
120
- | `render` | `(props) => ReactNode` | — | Tree, TreeNode | Renders the part into another element, keeping every attribute and handler it was given |
121
- | `label, description, icon, meta, actions` | `ReactNode` | — | TreeNode | The cells of a row, each one whatever the consumer renders. The family owns no folder glyph of its own |
122
- | `handleRef` | `Ref<TreeHandle>` | — | Tree | focus, scrollToKey, expand, collapse, expandAll, collapseAll, getActiveKey and getElement — the actions a consumer cannot express declaratively |
123
- | `onClick` | `(event: MouseEvent) => void` | — | TreeNode | Runs before the family acts, and preventDefault stops it. Every handler composes rather than replaces |
124
- | `data-expanded, data-selected, data-loading` | `attribute` | — | the node | Every state the contract declares is in the DOM, so an icon can be swapped by state in CSS alone with no prop for it |
71
+ | `value` | `string \| readonly string[] \| null` | — | Tree | The chosen key, or the set of chosen keys in multiple. When it is present the selection is controlled. |
72
+ | `defaultValue` | `string \| readonly string[] \| null` | — | Tree | The selection an uncontrolled tree starts with. |
73
+ | `expandedKeys` | `readonly string[]` | — | Tree | The keys of the open branches. When it is present the expansion is controlled. A query never changes it. |
74
+ | `defaultExpandedKeys` | `readonly string[]` | — | Tree | The branches an uncontrolled tree starts with open. |
75
+ | `activeKey` | `string \| null` | — | Tree | The node the keyboard is on, which is separate from the selection. When it is present the position is controlled. |
76
+ | `defaultActiveKey` | `string \| null` | — | Tree | The node the keyboard starts on in an uncontrolled tree. |
77
+ | `size` | `'sm' \| 'md' \| 'lg'` | md | Tree | The row height, the type size, the glyph size and the indent, which move together. |
78
+ | `variant` | `'plain' \| 'framed'` | plain | Tree | Whether the tree draws its own box. plain draws none and framed draws an edge, a radius and a shadow. |
79
+ | `structure` | `'auto' \| 'nested' \| 'flat'` | auto | Tree | Whether the nodes nest in groups or lie flat with their level stated. auto is flat while virtual and nested otherwise. Only a tree built from nodes can be flat. |
80
+ | `selectionMode` | `'none' \| 'single' \| 'multiple'` | single | Tree | How many nodes can be chosen at once. none writes no selection attribute on any node. |
81
+ | `selectionBehavior` | `'toggle' \| 'replace'` | toggle | Tree | What a plain press does. toggle changes one node and needs no modifier key; replace collapses the selection onto the node pressed, and Ctrl, Command and Shift extend it. |
82
+ | `selectionIndicator` | `'auto' \| 'highlight' \| 'checkbox' \| 'none'` | auto | Tree | How the selection is drawn and which attribute states it. highlight writes aria-selected, checkbox writes aria-checked, and auto draws a checkbox in multiple and a highlight in single. |
83
+ | `selectionCascade` | `'none' \| 'descendants'` | none | Tree | Whether choosing a branch also chooses its enabled descendants. descendants needs nodes. |
84
+ | `expandOn` | `'row' \| 'expander'` | row | Tree | What opens a branch. row gives the whole row and the chevron that job; expander leaves it to the chevron alone. |
85
+ | `focusMode` | `'auto' \| 'roving' \| 'activedescendant'` | auto | Tree | How the position of the keyboard is expressed. auto is activedescendant while virtual and a roving tab stop otherwise. |
86
+ | `guides` | `boolean` | true | Tree | Whether the lines that tie a row to its parent are drawn. |
87
+ | `loop` | `boolean` | false | Tree | Whether the arrow keys wrap past the first and the last node. |
88
+ | `typeahead` | `boolean` | true | Tree | Whether typing a name moves the keyboard to the node that starts with it. |
89
+ | `typeaheadTimeout` | `number` | 500 | Tree | The milliseconds of silence that start a new typeahead search. |
90
+ | `selectOnFocus` | `boolean` | false | Tree | Whether moving the keyboard also chooses the node it lands on. |
91
+ | `navigateDisabled` | `boolean` | false | Tree | Whether the arrow keys land on a disabled node. |
92
+ | `disallowEmptySelection` | `boolean` | false | Tree | Whether the last chosen node stays chosen when it is pressed again. |
93
+ | `disallowSelectAll` | `boolean` | false | Tree | Whether Control+A is kept from choosing every visible node. |
94
+ | `pageSize` | `number` | 10 | Tree | How many nodes Page Up and Page Down move by. |
95
+ | `virtual` | `boolean` | false | Tree | Whether only the rows in view are rendered. It needs nodes and itemSize, and it lays the rows flat. |
96
+ | `itemSize` | `number` | 32 | Tree | The height of one row in pixels, read while virtual. |
97
+ | `overscan` | `number` | 4 | Tree | How many rows are rendered on each side of the rows in view, while virtual. |
98
+ | `disabled` | `boolean` | false | Tree | Whether the whole tree is disabled. |
99
+ | `readOnly` | `boolean` | false | Tree | Whether the selection is fixed while the tree can still be opened and walked. |
100
+ | `required` | `boolean` | false | Tree | Whether the tree states that a choice is required. |
101
+ | `invalid` | `boolean` | false | Tree | Whether the tree is drawn and announced as being in error. |
102
+ | `loading` | `boolean` | false | Tree | Whether the nodes of the tree are still arriving. It writes aria-busy on the tree. |
103
+ | `name` | `string` | — | Tree | The form name. The tree renders one hidden input per chosen key under it. |
104
+ | `nodes` | `readonly T[]` | — | Tree | The hierarchy the tree renders. selectionCascade, expandAll, query and virtual read it. |
105
+ | `getKey` | `(node: T) => string` | — | Tree | Returns the key of a node. It is required with nodes. |
106
+ | `getLabel` | `(node: T) => string` | — | Tree | Returns the name of a node, which is what the row shows and what typeahead and query match. |
107
+ | `getChildren` | `(node: T) => readonly T[] \| undefined` | — | Tree | Returns the children of a node, for a nested hierarchy. |
108
+ | `getLevel` | `(node: T) => number` | — | Tree | Returns the depth of a node, for nodes that arrive as a flat list in reading order. |
109
+ | `hasChildren` | `(node: T) => boolean` | — | Tree | Returns whether a node is a branch before its children have arrived. |
110
+ | `getChildrenCount` | `(node: T) => number \| undefined` | — | Tree | Returns how many children a branch will have. Until all of them arrive, the ones present state the size of the whole set. |
111
+ | `isNodeDisabled` | `(node: T) => boolean` | — | Tree | Returns whether a node is disabled. |
112
+ | `isNodeLoading` | `(node: T) => boolean` | — | Tree | Returns whether the children of a node are arriving. |
113
+ | `query` | `string` | — | Tree | The text the tree filters nodes by. The field it is typed into is yours. |
114
+ | `renderCells` | `(node: T, key: string) => TreeNodeCells` | — | Tree | Returns the icon, label, description, meta and actions of one row of nodes. A cell left out is not drawn, and a label left out is the name getLabel returns. |
115
+ | `messages` | `PartialMessages<TreeMessages>` | — | Tree | The words the tree announces, over the ones of the language in force. |
116
+ | `emptyContent` | `ReactNode` | — | Tree | What the tree shows when it holds no node or the query matches none. |
117
+ | `render` | `(props: TreeRootProps) => ReactNode` | — | Tree | Renders the root as another element. |
118
+ | `handleRef` | `Ref<TreeHandle>` | — | Tree | The imperative handle: focus, scrollToKey, expand, collapse, expandAll, collapseAll, getActiveKey and getElement. |
119
+ | `label` | `ReactNode` | — | TreeNode | The name of the node, which is also its accessible name. |
120
+ | `description` | `ReactNode` | — | TreeNode | A second, muted text after the name. It is hidden when the tree is narrower than 240 pixels. |
121
+ | `icon` | `ReactNode` | — | TreeNode | The leading icon. One node with an icon reserves the same cell on every row. |
122
+ | `meta` | `ReactNode` | — | TreeNode | The trailing count, size or badge. |
123
+ | `actions` | `ReactNode` | — | TreeNode | The trailing controls. A press on one of them does not choose or open the row. |
124
+ | `textValue` | `string` | — | TreeNode | The text typeahead matches, for a label that is not plain text. |
125
+ | `match` | `'hit' \| 'ancestor'` | — | TreeNode | Whether a query matched this node or one below it. The tree writes it on the rows of nodes; a tree you write by hand states it. |
126
+ | `pinned` | `boolean` | — | TreeNode | Whether the node is placed outside the rows in view. The tree sets it while virtual. |
127
+ | `offset` | `number` | — | TreeNode | Where a pinned row sits, in pixels. The tree sets it while virtual. |
128
+ | `depth` | `number` | — | TreeNode | The depth of the node in the flat structure. Elsewhere the markup states it. |
129
+ | `TreeDefaultsProvider` | `{ size, variant, expandOn, … }` | — | a subtree | Sets the axes once for every tree under it. A prop on a tree still wins. |
130
+ | `render` | `(props) => ReactNode` | — | Tree, TreeNode | Renders the part as another element with the attributes and handlers it receives. |
131
+ | `label, description, icon, meta, actions` | `ReactNode` | — | TreeNode | The cells of a row written by hand. Each takes any content. |
132
+ | `handleRef` | `Ref<TreeHandle>` | — | Tree | Reaches focus, scrollToKey, expand, collapse, expandAll, collapseAll, getActiveKey and getElement. |
133
+ | `onClick` | `(event: MouseEvent) => void` | — | TreeNode | Runs before the row acts, and preventDefault keeps the row from acting. |
134
+ | `data-expanded, data-selected, data-loading` | `attribute` | — | the node | The state of a node in the DOM, which lets CSS change an icon by state. |
125
135
 
126
136
  ## Events
127
137
 
128
138
  | Name | Payload | When |
129
139
  | --- | --- | --- |
130
- | `onValueChange` | `(value: string \| readonly string[] \| null, request: ChangeRequest)` | Before the selection moves. The value is one key in single and none, and the set in multiple. The request carries the value it replaces, the reason — pointer, keyboard, select, clear or programmatic — the originating event, and cancel(). |
131
- | `onExpandedKeysChange` | `(keys: readonly string[], request: ChangeRequest)` | Before a branch opens or closes. Reasons: pointer, keyboard, programmatic. A filter is not among them: it holds a path open without moving the set. |
132
- | `onActiveKeyChange` | `(key: string \| null, request: ChangeRequest)` | Before the node the keyboard is on moves. Reasons: pointer, keyboard, programmatic. Closing a branch that holds the active node emits this first, so the pair stays coherent. |
133
- | `onNodeActivate` | `(key: string, reason: 'pointer' \| 'keyboard')` | When a node is pressed, or Enter is pressed on it. It is not the selection: a navigation tree opens a page here and chooses nothing. |
140
+ | `onValueChange` | `(value: string \| readonly string[] \| null, request: ChangeRequest)` | Before the selection changes. The value is one key, or the set in multiple. The request carries the previous value, the reason (pointer, keyboard, select, clear or programmatic), the originating event and cancel(). |
141
+ | `onExpandedKeysChange` | `(keys: readonly string[], request: ChangeRequest)` | Before a branch opens or closes. The reasons are pointer, keyboard and programmatic. A query holds branches open without this event. |
142
+ | `onActiveKeyChange` | `(key: string \| null, request: ChangeRequest)` | Before the keyboard moves to another node. The reasons are pointer, keyboard and programmatic. Closing a branch that holds the active node emits this event first. |
143
+ | `onNodeActivate` | `(key: string, reason: 'pointer' \| 'keyboard')` | When a node is pressed, or Enter is pressed on it. Use it to open what the node stands for; it does not depend on the selection. |
134
144
 
135
145
  ## Axes and defaults
136
146
 
@@ -157,12 +167,14 @@ Excerpt — not a complete module
157
167
 
158
168
  ## Rules
159
169
 
160
- - The tree carries its own accessible name, which the pattern requires: aria-label or aria-labelledby reaches the element with role="tree".
161
- - Each node is named by its own label through aria-labelledby, because a treeitem contains the group holding its children and a name computed from its contents is the whole subtree read aloud.
162
- - aria-expanded is on branches and never on leaves: a leaf carrying it is announced as a parent.
163
- - Selection is stated with aria-selected or with aria-checked and never with both, which the pattern allows only under three conditions it calls extremely rare.
164
- - aria-level, aria-setsize and aria-posinset are written only while the rows are flat — the condition the pattern names — because the nesting is what the browser computes them from otherwise.
165
- - The whole tree is one tab stop. Focus lands on the chosen node when there is one and on the first node otherwise, and a windowed tree keeps the active node in the document rather than letting a recycled row take it away.
170
+ - The tree takes its accessible name from aria-label or aria-labelledby, which reach the element with role="tree".
171
+ - Each node is named by its own label through aria-labelledby. A treeitem contains its children, so a name computed from its contents would be everything under it.
172
+ - aria-expanded is written on branches and never on leaves, which would otherwise be announced as parents.
173
+ - Selection is stated with aria-selected under the highlight and with aria-checked under the checkbox, and never with both.
174
+ - aria-level, aria-setsize and aria-posinset are written while the rows are flat. A nested tree leaves them to the browser, except on the children of a branch that is still missing some of them.
175
+ - The whole tree is one tab stop. Focus lands on the chosen node when there is one and on the first node otherwise, and a virtual tree keeps the active node in the document.
176
+ - A control in the trailing cell of a row is a tab stop of its own and receives its own keys.
177
+ - A branch whose children are arriving has aria-busy, and a polite live region announces the branch and how many items arrived.
166
178
 
167
179
  ## Tokens
168
180
 
@@ -170,248 +182,4 @@ Excerpt — not a complete module
170
182
 
171
183
  ## Examples
172
184
 
173
- ### Opening and closing a branch
174
-
175
- The row opens the branch by default; the second tree gives that job to the chevron alone. Press each of them, then use the sideways arrows on both.
176
-
177
- Excerpt — not a complete module
178
-
179
- ```tsx
180
- <Tree aria-label="Files" expandOn="expander" defaultExpandedKeys={['src']}>
181
- {nodes}
182
- </Tree>;
183
- ```
184
-
185
- ### One choice, several, or none
186
-
187
- Three trees side by side. The multi-select one writes aria-checked and draws a box; the single one writes aria-selected and says it with the band; the third writes neither.
188
-
189
- Excerpt — not a complete module
190
-
191
- ```tsx
192
- <Tree
193
- aria-label="Permissions"
194
- selectionMode="multiple"
195
- defaultValue={['revenue']}
196
- defaultExpandedKeys={['reports']}
197
- >
198
- {nodes}
199
- </Tree>;
200
- ```
201
-
202
- ### A branch that takes its descendants with it
203
-
204
- Press the folder and watch every enabled file under it follow, including the ones inside a branch that is closed. The locked file is left exactly where it was.
205
-
206
- Excerpt — not a complete module
207
-
208
- ```tsx
209
- <Tree
210
- aria-label="Permissions"
211
- selectionMode="multiple"
212
- selectionCascade="descendants"
213
- nodes={roots}
214
- getKey={(node) => node.id}
215
- getLabel={(node) => node.name}
216
- getChildren={(node) => node.children}
217
- />;
218
- ```
219
-
220
- ### How the selection is said
221
-
222
- The same value under the two indicators. The box states aria-checked and is the box the checkbox family draws; the highlight states aria-selected and spends no cell at all.
223
-
224
- Excerpt — not a complete module
225
-
226
- ```tsx
227
- <Tree aria-label="Files" selectionIndicator="checkbox" defaultValue="index.ts">
228
- {nodes}
229
- </Tree>;
230
- ```
231
-
232
- ### The lines that say which parent a row belongs to
233
-
234
- Depth four with the guides on and off. Each line sits under the chevron of the level above it, at one distance from the row it belongs to, at every size.
235
-
236
- Excerpt — not a complete module
237
-
238
- ```tsx
239
- <Tree aria-label="Packages" guides={false} defaultExpandedKeys={['a', 'b', 'c']}>
240
- {nodes}
241
- </Tree>;
242
- ```
243
-
244
- ### The three type steps
245
-
246
- Small, medium and large in a column. The row height, the type, the glyph and the indent all move together, and the distance from a guide to its chevron does not.
247
-
248
- Excerpt — not a complete module
249
-
250
- ```tsx
251
- <Tree aria-label="Files" size="sm" defaultExpandedKeys={['src']}>
252
- {nodes}
253
- </Tree>;
254
- ```
255
-
256
- ### Framed, and inside something that already has an edge
257
-
258
- The framed tree draws its own box; the plain one draws none, for a panel or a drawer that has drawn one already. Both keep the same row.
259
-
260
- Excerpt — not a complete module
261
-
262
- ```tsx
263
- <Tree aria-label="Navigation" variant="plain" defaultExpandedKeys={['reports']}>
264
- {nodes}
265
- </Tree>;
266
- ```
267
-
268
- ### Every state a row can be in
269
-
270
- At rest, hovered, where the keyboard is, chosen, both at once, out of reach, and fetching. Chosen outranks the keyboard, and disabled outranks everything.
271
-
272
- Excerpt — not a complete module
273
-
274
- ```tsx
275
- <TreeNode value="payroll" label="Payroll" description="no access" disabled />;
276
- ```
277
-
278
- ### Nothing yet, and nothing at all
279
-
280
- A tree still loading its roots, and one whose query matched nothing. The empty part replaces no row: the tree keeps its name and its role either way.
281
-
282
- Excerpt — not a complete module
283
-
284
- ```tsx
285
- <Tree aria-label="Files" nodes={[]} getKey={(node) => node.id} emptyContent="No files here" />;
286
- ```
287
-
288
- ### Children that arrive after the branch opens
289
-
290
- Press the folder. The request goes out, the ring stands where the chevron stood, the group says aria-busy, and the placeholder rows are the width names would have been.
291
-
292
- Excerpt — not a complete module
293
-
294
- ```tsx
295
- <Tree
296
- aria-label="Files"
297
- nodes={roots}
298
- getKey={(node) => node.id}
299
- hasChildren={(node) => node.type === 'folder'}
300
- getChildrenCount={(node) => node.count}
301
- isNodeLoading={(node) => pending.has(node.id)}
302
- onExpandedKeysChange={(keys, request) => {
303
- if (request.reason !== 'programmatic') fetchChildren(keys);
304
- setExpanded(keys);
305
- }}
306
- />;
307
- ```
308
-
309
- ### Searching a tree without losing where things are
310
-
311
- Type in the field. Every hit keeps its ancestors, the matched span is marked, and the path is held open for as long as the query lasts without moving the set the reader opened.
312
-
313
- Excerpt — not a complete module
314
-
315
- ```tsx
316
- <>
317
- <TextField aria-label="Search" value={query} onValueChange={setQuery} />
318
- <Tree
319
- aria-label="Files"
320
- query={query}
321
- nodes={roots}
322
- getKey={(node) => node.id}
323
- getLabel={(node) => node.name}
324
- getChildren={(node) => node.children}
325
- />
326
- </>;
327
- ```
328
-
329
- ### Four thousand rows, and the ones on screen
330
-
331
- Scroll it. Only the covered slice is rendered, the rows are laid flat with their level stated, and the node the keyboard is on stays in the document however far it is scrolled away.
332
-
333
- Excerpt — not a complete module
334
-
335
- ```tsx
336
- <Tree
337
- aria-label="Regions"
338
- virtual
339
- itemSize={32}
340
- nodes={roots}
341
- getKey={(node) => node.id}
342
- getLabel={(node) => node.name}
343
- getChildren={(node) => node.children}
344
- />;
345
- ```
346
-
347
- ### Content the tree did not choose
348
-
349
- A name that is one unbroken token, a translated name twice the length, and a right-to-left name in a left-to-right tree. Each takes its own direction and truncates rather than pushing the count out.
350
-
351
- Excerpt — not a complete module
352
-
353
- ```tsx
354
- <TreeNode
355
- value="report"
356
- label="quarterly-report-2026.pdf"
357
- description="edited"
358
- icon={<FileIcon />}
359
- meta="18 kB"
360
- />;
361
- ```
362
-
363
- ### A tree that submits
364
-
365
- One hidden input per chosen key, under the name the form reads. The tree is the control, and a bare form carries the set without a controlled value anywhere.
366
-
367
- Excerpt — not a complete module
368
-
369
- ```tsx
370
- <form action="/permissions" method="post">
371
- <Tree aria-label="Permissions" name="scopes" selectionMode="multiple">
372
- {nodes}
373
- </Tree>
374
- <Button type="submit">Save</Button>
375
- </form>;
376
- ```
377
-
378
- ### What a consumer can put in a row, and set once
379
-
380
- A row with an icon, a count and a trailing control, beside a provider that gives every tree under it the same size and the same expansion target.
381
-
382
- Excerpt — not a complete module
383
-
384
- ```tsx
385
- <TreeDefaultsProvider size="sm" expandOn="expander" guides={false}>
386
- <Tree aria-label="Files">{nodes}</Tree>
387
- </TreeDefaultsProvider>;
388
- ```
389
-
390
- ### Every key the pattern gives a tree
391
-
392
- Tab in and try them: the sideways arrows open, enter and leave a branch; Home and End cross the whole list; the asterisk opens every sibling at the level.
393
-
394
- Excerpt — not a complete module
395
-
396
- ```tsx
397
- <Tree
398
- aria-label="Files"
399
- activeKey={active}
400
- onActiveKeyChange={(key, request) => {
401
- if (request.reason === 'keyboard') announce(key);
402
- setActive(key);
403
- }}
404
- >
405
- {nodes}
406
- </Tree>;
407
- ```
408
-
409
- ### What a reader hears
410
-
411
- The tree carries its own name, each node is named by its own label rather than by the subtree under it, and a branch that is fetching says so through a live region once.
412
-
413
- Excerpt — not a complete module
414
-
415
- ```tsx
416
- <Tree aria-labelledby="files-heading">{nodes}</Tree>;
417
- ```
185
+ See [tree.examples.md](./tree.examples.md).
@@ -34,28 +34,28 @@
34
34
  "type": "boolean",
35
35
  "defaultValue": "false",
36
36
  "appliesTo": "VisuallyHidden",
37
- "description": "Stops hiding the content while focus is inside it"
37
+ "description": "Stops hiding the content while focus is inside it."
38
38
  },
39
39
  {
40
40
  "name": "render",
41
41
  "type": "(props) => ReactNode",
42
42
  "defaultValue": "—",
43
43
  "appliesTo": "VisuallyHidden",
44
- "description": "Renders a different element"
44
+ "description": "Renders a different element."
45
45
  },
46
46
  {
47
47
  "name": "children",
48
48
  "type": "ReactNode",
49
49
  "defaultValue": "—",
50
50
  "appliesTo": "VisuallyHidden",
51
- "description": "Content exposed only to assistive technology"
51
+ "description": "Content exposed only to assistive technology."
52
52
  },
53
53
  {
54
54
  "name": "className",
55
55
  "type": "string",
56
56
  "defaultValue": "—",
57
57
  "appliesTo": "VisuallyHidden",
58
- "description": "Class names, forwarded untouched"
58
+ "description": "Class names, forwarded untouched."
59
59
  }
60
60
  ],
61
61
  "composition": [],
@@ -64,8 +64,8 @@
64
64
  "The content stays in the accessibility tree: the stylesheet clips it rather than applying display: none or visibility: hidden.",
65
65
  "The content costs no space. The element is taken out of flow and held to one pixel, so a control that gains an accessible name this way is the size it was, and a hidden span between two flex items does not become a second gap.",
66
66
  "A screen reader reads the content in document order, so it belongs where it would be read, not at the end of the document.",
67
- "The whole string stays in the document, so a page search finds it and a selection copies it. Hidden text is content, not decoration.",
68
- "focusable is for content a sighted keyboard user must be able to reach, such as a skip link. While focus is inside, the hiding rule stops matching and the element renders as the consumer wrote it — the component paints nothing on the revealed state, so the appearance of a skip link belongs to the link.",
67
+ "The whole string stays in the DOM as text. Hidden text is content, not decoration.",
68
+ "focusable is for content a sighted keyboard user must be able to reach, such as a skip link. While focus is inside, the hiding rule stops matching and the element renders as it was written — the component paints nothing on the revealed state, so the appearance of a skip link belongs to the link.",
69
69
  "The component adds no role and no class. Wrap it in the element that carries the semantics, or hand the wiring to that element with render. Select it in the DOM as [data-ui=\"visually-hidden\"]."
70
70
  ]
71
71
  }
@@ -87,6 +87,38 @@
87
87
  "language": "tsx",
88
88
  "source": "<VisuallyHidden focusable render={(props) => <a {...props} href=\"#main\" />}>\n Skip to content\n</VisuallyHidden>;\n",
89
89
  "verdict": "excerpt"
90
+ },
91
+ {
92
+ "id": "basic",
93
+ "title": "basic.tsx",
94
+ "note": null,
95
+ "language": "tsx",
96
+ "source": "import { Button } from '@slotted/react/button';\nimport { Glyph } from '@slotted/react/icon';\nimport { Inline } from '@slotted/react/inline';\nimport { VisuallyHidden } from '@slotted/react/visually-hidden';\n\nexport default function VisuallyHiddenBasic() {\n return (\n <Inline>\n <Button tone=\"danger\" variant=\"outline\">\n <Glyph name=\"trash\" />\n <VisuallyHidden>Delete invoice INV-20418</VisuallyHidden>\n </Button>\n </Inline>\n );\n}\n",
97
+ "verdict": "example"
98
+ },
99
+ {
100
+ "id": "count",
101
+ "title": "count.tsx",
102
+ "note": null,
103
+ "language": "tsx",
104
+ "source": "import { Glyph } from '@slotted/react/icon';\nimport { Inline } from '@slotted/react/inline';\nimport { Stack } from '@slotted/react/stack';\nimport { Text } from '@slotted/react/typography';\nimport { VisuallyHidden } from '@slotted/react/visually-hidden';\n\nexport default function VisuallyHiddenCount() {\n return (\n <Stack gap={3}>\n <Inline gap={2}>\n <Glyph name=\"bell\" />\n <Text numeric=\"tabular\" weight=\"semibold\">\n 3\n </Text>\n <VisuallyHidden>unread notifications</VisuallyHidden>\n </Inline>\n <Text size=\"sm\" tone=\"muted\">\n Visible: a bell and 3. Read aloud: 3 unread notifications.\n </Text>\n </Stack>\n );\n}\n",
105
+ "verdict": "example"
106
+ },
107
+ {
108
+ "id": "skip-link",
109
+ "title": "skip-link.tsx",
110
+ "note": null,
111
+ "language": "tsx",
112
+ "source": "import { Stack } from '@slotted/react/stack';\nimport { Heading, Text } from '@slotted/react/typography';\nimport { VisuallyHidden } from '@slotted/react/visually-hidden';\n\nexport default function VisuallyHiddenSkipLink() {\n return (\n <Stack gap={3}>\n <VisuallyHidden focusable render={(props) => <a {...props} href=\"#orders-today\" />}>\n Skip to the orders\n </VisuallyHidden>\n <Text size=\"sm\" tone=\"muted\">\n The skip link appears above this text while it has focus.\n </Text>\n <Heading id=\"orders-today\" level={2} size=\"sm\" tabIndex={-1}>\n Orders placed today\n </Heading>\n </Stack>\n );\n}\n",
113
+ "verdict": "example"
114
+ },
115
+ {
116
+ "id": "table-heading",
117
+ "title": "table-heading.tsx",
118
+ "note": null,
119
+ "language": "tsx",
120
+ "source": "import { Button } from '@slotted/react/button';\nimport { Glyph } from '@slotted/react/icon';\nimport {\n Table,\n TableBody,\n TableCaption,\n TableCell,\n TableColumnHeader,\n TableContent,\n TableHead,\n TableRow,\n TableRowHeader,\n} from '@slotted/react/table';\nimport { VisuallyHidden } from '@slotted/react/visually-hidden';\n\nconst ORDERS = [\n { id: 'SO-10421', total: '$1,240.00' },\n { id: 'SO-10422', total: '$860.50' },\n { id: 'SO-10423', total: '$3,410.25' },\n] as const;\n\nexport default function VisuallyHiddenTableHeading() {\n return (\n <Table columns={3}>\n <TableContent>\n <TableCaption>Orders placed today</TableCaption>\n <TableHead>\n <TableRow>\n <TableColumnHeader>Order</TableColumnHeader>\n <TableColumnHeader numeric>Total</TableColumnHeader>\n <TableColumnHeader>\n <VisuallyHidden>Actions</VisuallyHidden>\n </TableColumnHeader>\n </TableRow>\n </TableHead>\n <TableBody>\n {ORDERS.map((order) => (\n <TableRow key={order.id} value={order.id}>\n <TableRowHeader>{order.id}</TableRowHeader>\n <TableCell numeric>{order.total}</TableCell>\n <TableCell>\n <Button tone=\"danger\" variant=\"ghost\">\n <Glyph name=\"trash\" />\n <VisuallyHidden>Cancel order {order.id}</VisuallyHidden>\n </Button>\n </TableCell>\n </TableRow>\n ))}\n </TableBody>\n </TableContent>\n </Table>\n );\n}\n",
121
+ "verdict": "example"
90
122
  }
91
123
  ]
92
124
  }