@proyecto-viviana/solidaria 0.4.0 → 0.4.2

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 (480) hide show
  1. package/dist/_chunk/DragManager.js +627 -0
  2. package/dist/_chunk/DragManager.js.map +1 -0
  3. package/dist/_chunk/DragManager.jsx +627 -0
  4. package/dist/_chunk/DragManager.jsx.map +1 -0
  5. package/dist/_chunk/FocusScope.js +400 -0
  6. package/dist/_chunk/FocusScope.js.map +1 -0
  7. package/dist/_chunk/FocusScope.jsx +375 -0
  8. package/dist/_chunk/FocusScope.jsx.map +1 -0
  9. package/dist/_chunk/actiongroup.js +13 -79
  10. package/dist/_chunk/actiongroup.js.map +1 -1
  11. package/dist/_chunk/actiongroup.jsx +13 -79
  12. package/dist/_chunk/actiongroup.jsx.map +1 -1
  13. package/dist/_chunk/{live-announcer.js → announce.js} +1 -1
  14. package/dist/_chunk/announce.js.map +1 -0
  15. package/dist/_chunk/{live-announcer.jsx → announce.jsx} +1 -1
  16. package/dist/_chunk/announce.jsx.map +1 -0
  17. package/dist/_chunk/autocomplete.js +56 -8
  18. package/dist/_chunk/autocomplete.js.map +1 -1
  19. package/dist/_chunk/autocomplete.jsx +56 -8
  20. package/dist/_chunk/autocomplete.jsx.map +1 -1
  21. package/dist/_chunk/breadcrumbs.js +6 -4
  22. package/dist/_chunk/breadcrumbs.js.map +1 -1
  23. package/dist/_chunk/breadcrumbs.jsx +6 -4
  24. package/dist/_chunk/breadcrumbs.jsx.map +1 -1
  25. package/dist/_chunk/button.js +8 -9
  26. package/dist/_chunk/button.js.map +1 -1
  27. package/dist/_chunk/button.jsx +8 -9
  28. package/dist/_chunk/button.jsx.map +1 -1
  29. package/dist/_chunk/calendar.js +27 -26
  30. package/dist/_chunk/calendar.js.map +1 -1
  31. package/dist/_chunk/calendar.jsx +27 -26
  32. package/dist/_chunk/calendar.jsx.map +1 -1
  33. package/dist/_chunk/checkbox.js +5 -4
  34. package/dist/_chunk/checkbox.js.map +1 -1
  35. package/dist/_chunk/checkbox.jsx +5 -4
  36. package/dist/_chunk/checkbox.jsx.map +1 -1
  37. package/dist/_chunk/color.js +302 -18
  38. package/dist/_chunk/color.js.map +1 -1
  39. package/dist/_chunk/color.jsx +302 -18
  40. package/dist/_chunk/color.jsx.map +1 -1
  41. package/dist/_chunk/combobox.js +638 -12
  42. package/dist/_chunk/combobox.js.map +1 -1
  43. package/dist/_chunk/combobox.jsx +638 -12
  44. package/dist/_chunk/combobox.jsx.map +1 -1
  45. package/dist/_chunk/constants.js +19 -0
  46. package/dist/_chunk/constants.js.map +1 -0
  47. package/dist/_chunk/constants.jsx +19 -0
  48. package/dist/_chunk/constants.jsx.map +1 -0
  49. package/dist/_chunk/createCollator.js +3 -171
  50. package/dist/_chunk/createCollator.js.map +1 -1
  51. package/dist/_chunk/createCollator.jsx +3 -165
  52. package/dist/_chunk/createCollator.jsx.map +1 -1
  53. package/dist/_chunk/createField.js +2 -1
  54. package/dist/_chunk/createField.js.map +1 -1
  55. package/dist/_chunk/createField.jsx +2 -1
  56. package/dist/_chunk/createField.jsx.map +1 -1
  57. package/dist/_chunk/createFocus.js +12 -8
  58. package/dist/_chunk/createFocus.js.map +1 -1
  59. package/dist/_chunk/createFocus.jsx +12 -8
  60. package/dist/_chunk/createFocus.jsx.map +1 -1
  61. package/dist/_chunk/createFocusWithin.js +12 -13
  62. package/dist/_chunk/createFocusWithin.js.map +1 -1
  63. package/dist/_chunk/createFocusWithin.jsx +12 -13
  64. package/dist/_chunk/createFocusWithin.jsx.map +1 -1
  65. package/dist/_chunk/createFocusable.js +3 -3
  66. package/dist/_chunk/createFocusable.js.map +1 -1
  67. package/dist/_chunk/createFocusable.jsx +3 -3
  68. package/dist/_chunk/createFocusable.jsx.map +1 -1
  69. package/dist/_chunk/{form.js → createFormReset.js} +1 -1
  70. package/dist/_chunk/createFormReset.js.map +1 -0
  71. package/dist/_chunk/{form.jsx → createFormReset.jsx} +1 -1
  72. package/dist/_chunk/createFormReset.jsx.map +1 -0
  73. package/dist/_chunk/createHover.js +2 -1
  74. package/dist/_chunk/createHover.js.map +1 -1
  75. package/dist/_chunk/createHover.jsx +2 -1
  76. package/dist/_chunk/createHover.jsx.map +1 -1
  77. package/dist/_chunk/createInteractionModality.js +2 -3
  78. package/dist/_chunk/createInteractionModality.js.map +1 -1
  79. package/dist/_chunk/createInteractionModality.jsx +2 -3
  80. package/dist/_chunk/createInteractionModality.jsx.map +1 -1
  81. package/dist/_chunk/createLabel.js +2 -1
  82. package/dist/_chunk/createLabel.js.map +1 -1
  83. package/dist/_chunk/createLabel.jsx +2 -1
  84. package/dist/_chunk/createLabel.jsx.map +1 -1
  85. package/dist/_chunk/createLabels.js +3 -2
  86. package/dist/_chunk/createLabels.js.map +1 -1
  87. package/dist/_chunk/createLabels.jsx +3 -2
  88. package/dist/_chunk/createLabels.jsx.map +1 -1
  89. package/dist/_chunk/createLandmark.js +1 -1
  90. package/dist/_chunk/createLandmark.jsx +1 -1
  91. package/dist/_chunk/createProgressBar.js +2 -1
  92. package/dist/_chunk/createProgressBar.js.map +1 -1
  93. package/dist/_chunk/createProgressBar.jsx +2 -1
  94. package/dist/_chunk/createProgressBar.jsx.map +1 -1
  95. package/dist/_chunk/createSelectableItem.js +7 -3
  96. package/dist/_chunk/createSelectableItem.js.map +1 -1
  97. package/dist/_chunk/createSelectableItem.jsx +7 -3
  98. package/dist/_chunk/createSelectableItem.jsx.map +1 -1
  99. package/dist/_chunk/createStringFormatter.js +61 -0
  100. package/dist/_chunk/createStringFormatter.js.map +1 -0
  101. package/dist/_chunk/createStringFormatter.jsx +61 -0
  102. package/dist/_chunk/createStringFormatter.jsx.map +1 -0
  103. package/dist/_chunk/createToggle.js +5 -4
  104. package/dist/_chunk/createToggle.js.map +1 -1
  105. package/dist/_chunk/createToggle.jsx +5 -4
  106. package/dist/_chunk/createToggle.jsx.map +1 -1
  107. package/dist/_chunk/datepicker.js +1413 -1100
  108. package/dist/_chunk/datepicker.js.map +1 -1
  109. package/dist/_chunk/datepicker.jsx +1413 -1100
  110. package/dist/_chunk/datepicker.jsx.map +1 -1
  111. package/dist/_chunk/disclosure.js +2 -2
  112. package/dist/_chunk/disclosure.js.map +1 -1
  113. package/dist/_chunk/disclosure.jsx +2 -2
  114. package/dist/_chunk/disclosure.jsx.map +1 -1
  115. package/dist/_chunk/dnd.js +1586 -495
  116. package/dist/_chunk/dnd.js.map +1 -1
  117. package/dist/_chunk/dnd.jsx +1586 -495
  118. package/dist/_chunk/dnd.jsx.map +1 -1
  119. package/dist/_chunk/env.js +1 -19
  120. package/dist/_chunk/env.js.map +1 -1
  121. package/dist/_chunk/env.jsx +1 -19
  122. package/dist/_chunk/env.jsx.map +1 -1
  123. package/dist/_chunk/focus.js +1 -1
  124. package/dist/_chunk/focus.js.map +1 -1
  125. package/dist/_chunk/focus.jsx +1 -1
  126. package/dist/_chunk/focus.jsx.map +1 -1
  127. package/dist/_chunk/focus2.js +54 -318
  128. package/dist/_chunk/focus2.js.map +1 -1
  129. package/dist/_chunk/focus2.jsx +53 -292
  130. package/dist/_chunk/focus2.jsx.map +1 -1
  131. package/dist/_chunk/grid.js +1 -1
  132. package/dist/_chunk/grid.jsx +1 -1
  133. package/dist/_chunk/gridlist.js +14 -9
  134. package/dist/_chunk/gridlist.js.map +1 -1
  135. package/dist/_chunk/gridlist.jsx +14 -9
  136. package/dist/_chunk/gridlist.jsx.map +1 -1
  137. package/dist/_chunk/i18n.js +3 -58
  138. package/dist/_chunk/i18n.js.map +1 -1
  139. package/dist/_chunk/i18n.jsx +3 -58
  140. package/dist/_chunk/i18n.jsx.map +1 -1
  141. package/dist/_chunk/interactions.js +99 -9
  142. package/dist/_chunk/interactions.js.map +1 -1
  143. package/dist/_chunk/interactions.jsx +97 -9
  144. package/dist/_chunk/interactions.jsx.map +1 -1
  145. package/dist/_chunk/link.js +2 -1
  146. package/dist/_chunk/link.js.map +1 -1
  147. package/dist/_chunk/link.jsx +2 -1
  148. package/dist/_chunk/link.jsx.map +1 -1
  149. package/dist/_chunk/listbox.js +42 -10
  150. package/dist/_chunk/listbox.js.map +1 -1
  151. package/dist/_chunk/listbox.jsx +42 -10
  152. package/dist/_chunk/listbox.jsx.map +1 -1
  153. package/dist/_chunk/locale.js +173 -0
  154. package/dist/_chunk/locale.js.map +1 -0
  155. package/dist/_chunk/locale.jsx +167 -0
  156. package/dist/_chunk/locale.jsx.map +1 -0
  157. package/dist/_chunk/menu.js +5 -4
  158. package/dist/_chunk/menu.js.map +1 -1
  159. package/dist/_chunk/menu.jsx +5 -4
  160. package/dist/_chunk/menu.jsx.map +1 -1
  161. package/dist/_chunk/numberfield.js +3 -2
  162. package/dist/_chunk/numberfield.js.map +1 -1
  163. package/dist/_chunk/numberfield.jsx +3 -2
  164. package/dist/_chunk/numberfield.jsx.map +1 -1
  165. package/dist/_chunk/overlays.js +1 -1
  166. package/dist/_chunk/overlays.jsx +1 -1
  167. package/dist/_chunk/popover.js +3 -3
  168. package/dist/_chunk/popover.js.map +1 -1
  169. package/dist/_chunk/popover.jsx +3 -3
  170. package/dist/_chunk/popover.jsx.map +1 -1
  171. package/dist/_chunk/radio.js +7 -6
  172. package/dist/_chunk/radio.js.map +1 -1
  173. package/dist/_chunk/radio.jsx +7 -6
  174. package/dist/_chunk/radio.jsx.map +1 -1
  175. package/dist/_chunk/reactivity.js +21 -0
  176. package/dist/_chunk/reactivity.js.map +1 -0
  177. package/dist/_chunk/reactivity.jsx +21 -0
  178. package/dist/_chunk/reactivity.jsx.map +1 -0
  179. package/dist/_chunk/searchfield.js +2 -1
  180. package/dist/_chunk/searchfield.js.map +1 -1
  181. package/dist/_chunk/searchfield.jsx +2 -1
  182. package/dist/_chunk/searchfield.jsx.map +1 -1
  183. package/dist/_chunk/select.js +8 -5
  184. package/dist/_chunk/select.js.map +1 -1
  185. package/dist/_chunk/select.jsx +8 -5
  186. package/dist/_chunk/select.jsx.map +1 -1
  187. package/dist/_chunk/selection.js +8 -21
  188. package/dist/_chunk/selection.js.map +1 -1
  189. package/dist/_chunk/selection.jsx +8 -21
  190. package/dist/_chunk/selection.jsx.map +1 -1
  191. package/dist/_chunk/separator.js +1 -1
  192. package/dist/_chunk/separator.jsx +1 -1
  193. package/dist/_chunk/slider.js +5 -4
  194. package/dist/_chunk/slider.js.map +1 -1
  195. package/dist/_chunk/slider.jsx +5 -4
  196. package/dist/_chunk/slider.jsx.map +1 -1
  197. package/dist/_chunk/spinbutton.js +153 -0
  198. package/dist/_chunk/spinbutton.js.map +1 -0
  199. package/dist/_chunk/spinbutton.jsx +153 -0
  200. package/dist/_chunk/spinbutton.jsx.map +1 -0
  201. package/dist/_chunk/table.js +45 -8
  202. package/dist/_chunk/table.js.map +1 -1
  203. package/dist/_chunk/table.jsx +45 -8
  204. package/dist/_chunk/table.jsx.map +1 -1
  205. package/dist/_chunk/tabs.js +11 -8
  206. package/dist/_chunk/tabs.js.map +1 -1
  207. package/dist/_chunk/tabs.jsx +11 -8
  208. package/dist/_chunk/tabs.jsx.map +1 -1
  209. package/dist/_chunk/tag.js +54 -18
  210. package/dist/_chunk/tag.js.map +1 -1
  211. package/dist/_chunk/tag.jsx +54 -18
  212. package/dist/_chunk/tag.jsx.map +1 -1
  213. package/dist/_chunk/textfield.js +2 -1
  214. package/dist/_chunk/textfield.js.map +1 -1
  215. package/dist/_chunk/textfield.jsx +2 -1
  216. package/dist/_chunk/textfield.jsx.map +1 -1
  217. package/dist/_chunk/toolbar.js +4 -36
  218. package/dist/_chunk/toolbar.js.map +1 -1
  219. package/dist/_chunk/toolbar.jsx +4 -36
  220. package/dist/_chunk/toolbar.jsx.map +1 -1
  221. package/dist/_chunk/tooltip.js +2 -2
  222. package/dist/_chunk/tooltip.js.map +1 -1
  223. package/dist/_chunk/tooltip.jsx +2 -2
  224. package/dist/_chunk/tooltip.jsx.map +1 -1
  225. package/dist/_chunk/tree.js +42 -14
  226. package/dist/_chunk/tree.js.map +1 -1
  227. package/dist/_chunk/tree.jsx +42 -14
  228. package/dist/_chunk/tree.jsx.map +1 -1
  229. package/dist/_chunk/utils.js +59 -19
  230. package/dist/_chunk/utils.js.map +1 -1
  231. package/dist/_chunk/utils.jsx +59 -19
  232. package/dist/_chunk/utils.jsx.map +1 -1
  233. package/dist/_chunk/visually-hidden.js +3 -2
  234. package/dist/_chunk/visually-hidden.js.map +1 -1
  235. package/dist/_chunk/visually-hidden.jsx +3 -2
  236. package/dist/_chunk/visually-hidden.jsx.map +1 -1
  237. package/dist/actiongroup/createActionGroup.d.ts.map +1 -1
  238. package/dist/autocomplete/createAutocomplete.d.ts +10 -7
  239. package/dist/autocomplete/createAutocomplete.d.ts.map +1 -1
  240. package/dist/breadcrumbs/createBreadcrumbs.d.ts.map +1 -1
  241. package/dist/button/createToggleButtonGroup.d.ts.map +1 -1
  242. package/dist/calendar/createCalendar.d.ts.map +1 -1
  243. package/dist/calendar/createCalendarCell.d.ts.map +1 -1
  244. package/dist/calendar/createCalendarGrid.d.ts.map +1 -1
  245. package/dist/calendar/createRangeCalendar.d.ts.map +1 -1
  246. package/dist/calendar/createRangeCalendarCell.d.ts.map +1 -1
  247. package/dist/calendar/intl/index.d.ts +1 -1
  248. package/dist/calendar/intl/index.d.ts.map +1 -1
  249. package/dist/collections/index.js +1 -1
  250. package/dist/collections/index.jsx +1 -1
  251. package/dist/color/createColorArea.d.ts.map +1 -1
  252. package/dist/color/createColorField.d.ts.map +1 -1
  253. package/dist/color/createColorSlider.d.ts.map +1 -1
  254. package/dist/color/createColorSwatch.d.ts.map +1 -1
  255. package/dist/color/createColorWheel.d.ts.map +1 -1
  256. package/dist/color/intl/index.d.ts +30 -0
  257. package/dist/color/intl/index.d.ts.map +1 -0
  258. package/dist/combobox/createComboBox.d.ts.map +1 -1
  259. package/dist/combobox/intl/generated-locales.d.ts +16 -0
  260. package/dist/combobox/intl/generated-locales.d.ts.map +1 -0
  261. package/dist/combobox/intl/index.d.ts +2 -2
  262. package/dist/combobox/intl/index.d.ts.map +1 -1
  263. package/dist/datepicker/createDateField.d.ts +45 -23
  264. package/dist/datepicker/createDateField.d.ts.map +1 -1
  265. package/dist/datepicker/createDatePicker.d.ts +34 -6
  266. package/dist/datepicker/createDatePicker.d.ts.map +1 -1
  267. package/dist/datepicker/createDatePickerGroup.d.ts +13 -13
  268. package/dist/datepicker/createDatePickerGroup.d.ts.map +1 -1
  269. package/dist/datepicker/createDateRangePicker.d.ts +55 -7
  270. package/dist/datepicker/createDateRangePicker.d.ts.map +1 -1
  271. package/dist/datepicker/createDateSegment.d.ts +6 -15
  272. package/dist/datepicker/createDateSegment.d.ts.map +1 -1
  273. package/dist/datepicker/createDisplayNames.d.ts +17 -0
  274. package/dist/datepicker/createDisplayNames.d.ts.map +1 -0
  275. package/dist/datepicker/createTimeField.d.ts +12 -49
  276. package/dist/datepicker/createTimeField.d.ts.map +1 -1
  277. package/dist/datepicker/index.d.ts +3 -3
  278. package/dist/datepicker/index.d.ts.map +1 -1
  279. package/dist/datepicker/index.js +2 -2
  280. package/dist/datepicker/index.jsx +2 -2
  281. package/dist/datepicker/intl.d.ts +12 -0
  282. package/dist/datepicker/intl.d.ts.map +1 -0
  283. package/dist/dnd/DragManager.d.ts +86 -0
  284. package/dist/dnd/DragManager.d.ts.map +1 -0
  285. package/dist/dnd/DropTargetKeyboardNavigation.d.ts +42 -0
  286. package/dist/dnd/DropTargetKeyboardNavigation.d.ts.map +1 -0
  287. package/dist/dnd/createDrag.d.ts.map +1 -1
  288. package/dist/dnd/createDraggableCollection.d.ts.map +1 -1
  289. package/dist/dnd/createDraggableItem.d.ts +12 -7
  290. package/dist/dnd/createDraggableItem.d.ts.map +1 -1
  291. package/dist/dnd/createDroppableCollection.d.ts +7 -15
  292. package/dist/dnd/createDroppableCollection.d.ts.map +1 -1
  293. package/dist/dnd/index.d.ts +5 -1
  294. package/dist/dnd/index.d.ts.map +1 -1
  295. package/dist/dnd/index.js +3 -2
  296. package/dist/dnd/index.jsx +3 -2
  297. package/dist/dnd/intl/index.d.ts +39 -0
  298. package/dist/dnd/intl/index.d.ts.map +1 -0
  299. package/dist/dnd/utils.d.ts +5 -0
  300. package/dist/dnd/utils.d.ts.map +1 -1
  301. package/dist/focus/FocusScope.d.ts +7 -0
  302. package/dist/focus/FocusScope.d.ts.map +1 -1
  303. package/dist/focus/index.d.ts +2 -1
  304. package/dist/focus/index.d.ts.map +1 -1
  305. package/dist/focus/index.js +3 -2
  306. package/dist/focus/index.jsx +3 -2
  307. package/dist/focus/virtualFocus.d.ts +26 -0
  308. package/dist/focus/virtualFocus.d.ts.map +1 -0
  309. package/dist/form/index.js +1 -1
  310. package/dist/form/index.jsx +1 -1
  311. package/dist/gridlist/createGridList.d.ts.map +1 -1
  312. package/dist/i18n/index.js +4 -2
  313. package/dist/i18n/index.jsx +4 -2
  314. package/dist/index.d.ts +3 -3
  315. package/dist/index.d.ts.map +1 -1
  316. package/dist/index.js +18 -12
  317. package/dist/index.jsx +18 -12
  318. package/dist/interactions/FocusableProvider.d.ts.map +1 -1
  319. package/dist/interactions/createFocus.d.ts.map +1 -1
  320. package/dist/interactions/createFocusWithin.d.ts.map +1 -1
  321. package/dist/interactions/createInteractionModality.d.ts.map +1 -1
  322. package/dist/interactions/index.js +1 -2
  323. package/dist/interactions/index.jsx +1 -2
  324. package/dist/label/createLabels.d.ts.map +1 -1
  325. package/dist/listbox/createListBox.d.ts.map +1 -1
  326. package/dist/listbox/createOption.d.ts +1 -1
  327. package/dist/listbox/createOption.d.ts.map +1 -1
  328. package/dist/live-announcer/index.js +1 -1
  329. package/dist/live-announcer/index.jsx +1 -1
  330. package/dist/select/createSelect.d.ts +2 -0
  331. package/dist/select/createSelect.d.ts.map +1 -1
  332. package/dist/selection/createSelectableItem.d.ts.map +1 -1
  333. package/dist/selection/index.js +2 -1
  334. package/dist/selection/index.jsx +2 -1
  335. package/dist/spinbutton/createSpinButton.d.ts +41 -0
  336. package/dist/spinbutton/createSpinButton.d.ts.map +1 -0
  337. package/dist/spinbutton/index.d.ts +3 -0
  338. package/dist/spinbutton/index.d.ts.map +1 -0
  339. package/dist/spinbutton/index.js +2 -0
  340. package/dist/spinbutton/index.jsx +2 -0
  341. package/dist/spinbutton/intl.d.ts +5 -0
  342. package/dist/spinbutton/intl.d.ts.map +1 -0
  343. package/dist/table/createTable.d.ts.map +1 -1
  344. package/dist/table/createTableColumnHeader.d.ts.map +1 -1
  345. package/dist/table/createTableRow.d.ts.map +1 -1
  346. package/dist/table/createTableSelectionCheckbox.d.ts.map +1 -1
  347. package/dist/table/types.d.ts +8 -0
  348. package/dist/table/types.d.ts.map +1 -1
  349. package/dist/table/utils.d.ts +15 -0
  350. package/dist/table/utils.d.ts.map +1 -0
  351. package/dist/tabs/createTabs.d.ts +1 -0
  352. package/dist/tabs/createTabs.d.ts.map +1 -1
  353. package/dist/tag/createTag.d.ts.map +1 -1
  354. package/dist/tag/createTagGroup.d.ts +7 -0
  355. package/dist/tag/createTagGroup.d.ts.map +1 -1
  356. package/dist/toolbar/createToolbar.d.ts.map +1 -1
  357. package/dist/tree/createTree.d.ts.map +1 -1
  358. package/dist/tree/createTreeSelectionCheckbox.d.ts.map +1 -1
  359. package/dist/utils/animation.d.ts.map +1 -1
  360. package/dist/utils/dom.d.ts +1 -0
  361. package/dist/utils/dom.d.ts.map +1 -1
  362. package/dist/utils/index.d.ts +1 -1
  363. package/dist/utils/index.d.ts.map +1 -1
  364. package/dist/utils/index.js +4 -3
  365. package/dist/utils/index.jsx +4 -3
  366. package/package.json +2 -2
  367. package/src/actiongroup/createActionGroup.ts +26 -109
  368. package/src/autocomplete/createAutocomplete.ts +136 -15
  369. package/src/breadcrumbs/createBreadcrumbs.ts +12 -4
  370. package/src/button/createToggleButtonGroup.ts +19 -14
  371. package/src/calendar/createCalendar.ts +3 -4
  372. package/src/calendar/createCalendarCell.ts +17 -3
  373. package/src/calendar/createCalendarGrid.ts +5 -4
  374. package/src/calendar/createRangeCalendar.ts +27 -17
  375. package/src/calendar/createRangeCalendarCell.ts +17 -3
  376. package/src/calendar/intl/index.ts +8 -0
  377. package/src/color/createColorArea.ts +17 -10
  378. package/src/color/createColorField.ts +8 -1
  379. package/src/color/createColorSlider.ts +1 -2
  380. package/src/color/createColorSwatch.ts +4 -2
  381. package/src/color/createColorWheel.ts +0 -6
  382. package/src/color/intl/index.ts +316 -0
  383. package/src/combobox/createComboBox.ts +35 -4
  384. package/src/combobox/intl/generated-locales.ts +635 -0
  385. package/src/combobox/intl/index.ts +8 -2
  386. package/src/datepicker/createDateField.ts +228 -213
  387. package/src/datepicker/createDatePicker.ts +157 -146
  388. package/src/datepicker/createDatePickerGroup.ts +88 -82
  389. package/src/datepicker/createDateRangePicker.ts +230 -179
  390. package/src/datepicker/createDateSegment.ts +386 -389
  391. package/src/datepicker/createDisplayNames.ts +45 -0
  392. package/src/datepicker/createTimeField.ts +36 -129
  393. package/src/datepicker/index.ts +13 -14
  394. package/src/datepicker/intl.ts +633 -0
  395. package/src/dnd/DragManager.ts +693 -0
  396. package/src/dnd/DropTargetKeyboardNavigation.ts +337 -0
  397. package/src/dnd/createDrag.ts +31 -5
  398. package/src/dnd/createDraggableCollection.ts +33 -15
  399. package/src/dnd/createDraggableItem.ts +92 -5
  400. package/src/dnd/createDroppableCollection.ts +487 -373
  401. package/src/dnd/index.ts +11 -0
  402. package/src/dnd/intl/ar-AE.json +29 -0
  403. package/src/dnd/intl/bg-BG.json +29 -0
  404. package/src/dnd/intl/cs-CZ.json +29 -0
  405. package/src/dnd/intl/da-DK.json +29 -0
  406. package/src/dnd/intl/de-DE.json +29 -0
  407. package/src/dnd/intl/el-GR.json +29 -0
  408. package/src/dnd/intl/en-US.json +29 -0
  409. package/src/dnd/intl/es-ES.json +29 -0
  410. package/src/dnd/intl/et-EE.json +29 -0
  411. package/src/dnd/intl/fi-FI.json +29 -0
  412. package/src/dnd/intl/fr-FR.json +29 -0
  413. package/src/dnd/intl/he-IL.json +29 -0
  414. package/src/dnd/intl/hr-HR.json +29 -0
  415. package/src/dnd/intl/hu-HU.json +29 -0
  416. package/src/dnd/intl/index.ts +139 -0
  417. package/src/dnd/intl/it-IT.json +29 -0
  418. package/src/dnd/intl/ja-JP.json +29 -0
  419. package/src/dnd/intl/ko-KR.json +29 -0
  420. package/src/dnd/intl/lt-LT.json +29 -0
  421. package/src/dnd/intl/lv-LV.json +29 -0
  422. package/src/dnd/intl/nb-NO.json +29 -0
  423. package/src/dnd/intl/nl-NL.json +29 -0
  424. package/src/dnd/intl/pl-PL.json +29 -0
  425. package/src/dnd/intl/pt-BR.json +29 -0
  426. package/src/dnd/intl/pt-PT.json +29 -0
  427. package/src/dnd/intl/ro-RO.json +29 -0
  428. package/src/dnd/intl/ru-RU.json +29 -0
  429. package/src/dnd/intl/sk-SK.json +29 -0
  430. package/src/dnd/intl/sl-SI.json +29 -0
  431. package/src/dnd/intl/sr-SP.json +29 -0
  432. package/src/dnd/intl/sv-SE.json +29 -0
  433. package/src/dnd/intl/tr-TR.json +29 -0
  434. package/src/dnd/intl/uk-UA.json +29 -0
  435. package/src/dnd/intl/zh-CN.json +29 -0
  436. package/src/dnd/intl/zh-TW.json +29 -0
  437. package/src/dnd/utils.ts +36 -0
  438. package/src/focus/FocusScope.tsx +120 -12
  439. package/src/focus/index.ts +8 -0
  440. package/src/focus/virtualFocus.ts +55 -0
  441. package/src/gridlist/createGridList.ts +52 -16
  442. package/src/index.ts +11 -3
  443. package/src/interactions/FocusableProvider.tsx +11 -6
  444. package/src/interactions/createFocus.ts +26 -21
  445. package/src/interactions/createFocusWithin.ts +23 -24
  446. package/src/interactions/createInteractionModality.ts +5 -3
  447. package/src/label/createLabels.ts +7 -4
  448. package/src/listbox/createListBox.ts +74 -2
  449. package/src/listbox/createOption.ts +16 -1
  450. package/src/select/createSelect.ts +23 -2
  451. package/src/selection/createSelectableItem.ts +14 -0
  452. package/src/spinbutton/createSpinButton.ts +163 -0
  453. package/src/spinbutton/index.ts +10 -0
  454. package/src/spinbutton/intl.ts +115 -0
  455. package/src/table/createTable.ts +26 -1
  456. package/src/table/createTableColumnHeader.ts +10 -0
  457. package/src/table/createTableRow.ts +10 -0
  458. package/src/table/createTableSelectionCheckbox.ts +24 -1
  459. package/src/table/types.ts +8 -0
  460. package/src/table/utils.ts +41 -0
  461. package/src/tabs/createTabs.ts +53 -12
  462. package/src/tag/createTag.ts +21 -32
  463. package/src/tag/createTagGroup.ts +92 -0
  464. package/src/toolbar/createToolbar.ts +6 -58
  465. package/src/tree/createTree.ts +69 -14
  466. package/src/tree/createTreeSelectionCheckbox.ts +14 -1
  467. package/src/utils/animation.ts +119 -27
  468. package/src/utils/dom.ts +3 -2
  469. package/src/utils/index.ts +2 -0
  470. package/dist/_chunk/createLongPress.js +0 -91
  471. package/dist/_chunk/createLongPress.js.map +0 -1
  472. package/dist/_chunk/createLongPress.jsx +0 -91
  473. package/dist/_chunk/createLongPress.jsx.map +0 -1
  474. package/dist/_chunk/form.js.map +0 -1
  475. package/dist/_chunk/form.jsx.map +0 -1
  476. package/dist/_chunk/live-announcer.js.map +0 -1
  477. package/dist/_chunk/live-announcer.jsx.map +0 -1
  478. package/dist/datepicker/createTimeSegment.d.ts +0 -29
  479. package/dist/datepicker/createTimeSegment.d.ts.map +0 -1
  480. package/src/datepicker/createTimeSegment.ts +0 -352
@@ -8,6 +8,7 @@ import type { JSX } from "solid-js";
8
8
  import { createId } from "@proyecto-viviana/solid-stately";
9
9
  import type { TableState, TableCollection } from "@proyecto-viviana/solid-stately";
10
10
  import type { AriaTableSelectionCheckboxProps, TableSelectionCheckboxAria } from "./types";
11
+ import { getRowLabelledBy } from "./utils";
11
12
 
12
13
  /**
13
14
  * Creates accessibility props for a table row selection checkbox.
@@ -24,10 +25,25 @@ export function createTableSelectionCheckbox<T extends object>(
24
25
  return s.isSelected(p.key);
25
26
  });
26
27
 
28
+ // Mirrors `useGridSelectionCheckbox`'s `!selectionManager.canSelectItem(key)`:
29
+ // a row's checkbox is disabled when selection is off, the key is in
30
+ // `disabledKeys`, or the row/item itself is disabled. This is broader than the
31
+ // row's own focusability gate (which only disables under `disabledBehavior:
32
+ // "all"`) — a row disabled via its `isDisabled` prop still cannot be selected,
33
+ // so its checkbox is disabled regardless of `disabledBehavior`.
34
+ //
35
+ // `isRowDisabled` carries the render-time per-row `isDisabled` that this
36
+ // data-driven port keeps on the row hook rather than the collection node
37
+ // (surfaced via `TableRowContext`); the collection-node check below still
38
+ // applies for any path that does populate `node.isDisabled`.
27
39
  const isDisabled = createMemo(() => {
28
40
  const s = state();
29
41
  const p = props();
30
- return s.isDisabled(p.key);
42
+ if (s.selectionMode === "none" || s.disabledKeys.has(p.key) || p.isRowDisabled) {
43
+ return true;
44
+ }
45
+ const item = s.collection.getItem(p.key);
46
+ return !item || !!item.isDisabled || !!item.props?.isDisabled;
31
47
  });
32
48
 
33
49
  const onChange = () => {
@@ -39,6 +55,9 @@ export function createTableSelectionCheckbox<T extends object>(
39
55
  };
40
56
 
41
57
  const checkboxProps = createMemo(() => {
58
+ const s = state();
59
+ const p = props();
60
+
42
61
  const baseProps: Record<string, unknown> = {
43
62
  id: checkboxId,
44
63
  type: "checkbox",
@@ -46,6 +65,10 @@ export function createTableSelectionCheckbox<T extends object>(
46
65
  disabled: isDisabled(),
47
66
  onChange,
48
67
  "aria-label": "Select",
68
+ // Mirrors `useTableSelectionCheckbox`: the checkbox is labelled by its own
69
+ // "Select" text plus the row's row-header cell(s), so screen readers read
70
+ // "Select Foo.pdf" rather than a bare "Select".
71
+ "aria-labelledby": `${checkboxId} ${getRowLabelledBy(s, p.key)}`,
49
72
  };
50
73
 
51
74
  return baseProps as JSX.InputHTMLAttributes<HTMLInputElement>;
@@ -180,6 +180,14 @@ export interface TableRowGroupAria {
180
180
  export interface AriaTableSelectionCheckboxProps {
181
181
  /** The key of the row. */
182
182
  key: Key;
183
+ /**
184
+ * Whether the owning row is disabled. In upstream RAC the row's `isDisabled`
185
+ * lives on the shared collection node, so `selectionManager.canSelectItem`
186
+ * can read it. In this data-driven port per-row `isDisabled` is a render-time
187
+ * prop threaded through `createTableRow`, so it is surfaced to the sibling
188
+ * checkbox via `TableRowContext` and forwarded here.
189
+ */
190
+ isRowDisabled?: boolean;
183
191
  }
184
192
 
185
193
  /**
@@ -0,0 +1,41 @@
1
+ /**
2
+ * Table accessibility id helpers.
3
+ * Port of @react-aria/table/utils (`getRowLabelledBy` / cell id derivation).
4
+ */
5
+
6
+ import type {
7
+ Key,
8
+ GridNode,
9
+ TableState,
10
+ TableCollection,
11
+ } from "@proyecto-viviana/solid-stately";
12
+ import { getTableData } from "./createTable";
13
+
14
+ /**
15
+ * A row is labelled by its row-header cells. Mirrors `@react-aria/table`'s
16
+ * `getRowLabelledBy`, which joins `getCellId(state, rowKey, columnKey)` across
17
+ * `collection.rowHeaderColumnKeys`. We resolve the actual rowheader cell node
18
+ * and rebuild the exact id string `createTableCell` puts on the element
19
+ * (`${tableId}-${parentKey}-${cellKey}`) so the reference always matches a real
20
+ * element, regardless of the cell-key scheme.
21
+ */
22
+ export function getRowLabelledBy<T extends object>(
23
+ state: TableState<T, TableCollection<T>>,
24
+ rowKey: Key,
25
+ ): string {
26
+ const tableData = getTableData(state);
27
+ const tableId = tableData?.tableId ?? "table";
28
+ const collection = state.collection as TableCollection<T> & {
29
+ getCell?: (rowKey: Key, columnKey: Key) => GridNode<T> | null;
30
+ };
31
+
32
+ return [...collection.rowHeaderColumnKeys]
33
+ .map((columnKey) => {
34
+ const cell = collection.getCell?.(rowKey, columnKey);
35
+ return cell?.parentKey != null
36
+ ? `${tableId}-${String(cell.parentKey)}-${String(cell.key)}`
37
+ : null;
38
+ })
39
+ .filter((id): id is string => id != null)
40
+ .join(" ");
41
+ }
@@ -3,7 +3,7 @@
3
3
  * Based on @react-aria/tabs.
4
4
  */
5
5
 
6
- import { type Accessor, createEffect, createMemo } from "solid-js";
6
+ import { type Accessor, batch, createEffect, createMemo } from "solid-js";
7
7
  import { createFocusRing } from "../interactions";
8
8
  import { createPress } from "../interactions";
9
9
  import { createHover } from "../interactions";
@@ -88,6 +88,7 @@ export interface TabAria {
88
88
  onPointerDown: (e: PointerEvent) => void;
89
89
  onClick: (e: MouseEvent) => void;
90
90
  onFocus: (e: FocusEvent) => void;
91
+ onFocusIn: (e: FocusEvent) => void;
91
92
  onBlur: (e: FocusEvent) => void;
92
93
  };
93
94
  /** Whether the tab is selected. */
@@ -271,12 +272,25 @@ export function createTabList<T>(props: AriaTabListProps, state: TabListState<T>
271
272
 
272
273
  if (nextKey !== null) {
273
274
  e.preventDefault();
274
- state.setFocusedKey(nextKey);
275
- // Selection follows focus only for keyboard navigation in automatic mode
276
- // (mirrors useSelectableCollection's selectOnFocus in navigateToKey).
277
- if (keyboardActivation() === "automatic") {
278
- state.setSelectedKey(nextKey);
279
- }
275
+ // Batch the focus + selection writes so their observable ordering matches
276
+ // React. `setFocusedKey` drives a reactive effect that moves DOM focus
277
+ // (firing native focusout/focusin); `setSelectedKey` calls
278
+ // `onSelectionChange` synchronously. Written bare, Solid flushes the focus
279
+ // effect the instant `setFocusedKey` runs — so focus moves *before* the
280
+ // selection callback, inverting React's order. React batches both state
281
+ // updates in the handler (callback fires synchronously) and defers the
282
+ // focus move to a layout effect. `batch()` is the Solid equivalent: it
283
+ // holds the focus effect until the batch closes, so the synchronous
284
+ // `onSelectionChange` fires first, then focus moves — matching upstream's
285
+ // `callback → focusout → focusin` sequence (D4 event-sequence oracle).
286
+ batch(() => {
287
+ state.setFocusedKey(nextKey);
288
+ // Selection follows focus only for keyboard navigation in automatic mode
289
+ // (mirrors useSelectableCollection's selectOnFocus in navigateToKey).
290
+ if (keyboardActivation() === "automatic") {
291
+ state.setSelectedKey(nextKey);
292
+ }
293
+ });
280
294
  }
281
295
  };
282
296
 
@@ -340,9 +354,17 @@ export function createTab<T>(
340
354
  // keyboard on key down, while touch, pen, and virtual pointers select on
341
355
  // press up.
342
356
  const selectTab = () => {
343
- const tabKey = key();
344
- state.setFocusedKey(tabKey);
345
- state.setSelectedKey(tabKey);
357
+ // Press handlers select only — they do NOT set the focused key. Upstream's
358
+ // useSelectableItem does the same: its press/onSelect path calls
359
+ // replaceSelection, while `focusedKey` is driven exclusively by the DOM
360
+ // `onFocus` handler (see handleFocus below). Setting the focused key here too
361
+ // flipped the roving tabIndex synchronously at pointer-up — *before* the
362
+ // browser's native focus reached the tab — so a touch tap logged the tapped
363
+ // tab with tabIndex 0 at its own `focusin`, where React (which updates
364
+ // tabIndex only on the post-event commit) still shows -1. Letting native
365
+ // focus alone advance `focusedKey` defers the tabIndex flip past the focus
366
+ // event, matching React's D4 event sequence.
367
+ state.setSelectedKey(key());
346
368
  };
347
369
  const { isPressed, pressProps } = createPress({
348
370
  get isDisabled() {
@@ -382,12 +404,30 @@ export function createTab<T>(
382
404
  }
383
405
  };
384
406
 
385
- // Focus management
407
+ // Focus management. The focus ring reacts to the native `focus` event, but the
408
+ // roving-tabindex commit is deliberately bound to `focusin` (see
409
+ // handleFocusIn) so its DOM reflection lands one event later — matching React,
410
+ // whose `onFocus` is a `focusin`-delegated listener at the app root.
386
411
  const handleFocus = (e: FocusEvent) => {
387
- state.setFocusedKey(key());
388
412
  callHandler(focusProps.onFocus, e);
389
413
  };
390
414
 
415
+ // Roving-tabindex commit (D4 event-ordering). React's `onFocus` is delegated
416
+ // to a single `focusin` listener at the app root, so the roving tabIndex it
417
+ // drives reflects one event *after* the native `focus`. Binding the
418
+ // focusedKey write here (to `focusin`) mirrors that timing: the D4 oracle
419
+ // records event targets from a document-level capture-phase listener, which
420
+ // runs before this at-target handler, so a touch tap — whose selection lands
421
+ // on press-up, after focus — is still observed with tabIndex=-1 at `focusin`,
422
+ // exactly as React. A mouse press selects on press-start and syncs focusedKey
423
+ // before focus (createTabListState's selection→focus effect), so its tab
424
+ // already reads tabIndex=0 at `focusin`, again matching React. Setting it on
425
+ // the earlier `focus` event flipped the tab a whole event too soon, so touch
426
+ // taps diverged at `focusin`. See recertification.md D4 event-ordering.
427
+ const handleFocusIn = () => {
428
+ state.setFocusedKey(key());
429
+ };
430
+
391
431
  const handleBlur = (e: FocusEvent) => {
392
432
  callHandler(focusProps.onBlur, e);
393
433
  };
@@ -449,6 +489,7 @@ export function createTab<T>(
449
489
  onPointerDown: handlePointerDown,
450
490
  onClick: handleClick,
451
491
  onFocus: handleFocus,
492
+ onFocusIn: handleFocusIn,
452
493
  onBlur: handleBlur,
453
494
  },
454
495
  isSelected,
@@ -184,13 +184,27 @@ export function createTag<T>(
184
184
  const handleKeyDown = (e: KeyboardEvent) => {
185
185
  if (isDisabled()) return;
186
186
 
187
+ // A TagGroup is inherently horizontal (useTagGroup passes
188
+ // `orientation: 'horizontal'` to the ListKeyboardDelegate), so the inline
189
+ // (Left/Right) axis is the navigation axis and flips under RTL, while the
190
+ // block (Up/Down) axis stays DOM-ordered. Mirror ListKeyboardDelegate:
191
+ // getKeyRightOf = rtl ? previous : next; getKeyLeftOf = rtl ? next : previous;
192
+ // getKeyBelow/Above are never direction-flipped.
193
+ const isRtl = getData()?.direction === "rtl";
194
+
187
195
  switch (e.key) {
188
196
  case "ArrowRight":
197
+ e.preventDefault();
198
+ focusKey(isRtl ? getPreviousFocusableKey(key()) : getNextFocusableKey(key()));
199
+ return;
200
+ case "ArrowLeft":
201
+ e.preventDefault();
202
+ focusKey(isRtl ? getNextFocusableKey(key()) : getPreviousFocusableKey(key()));
203
+ return;
189
204
  case "ArrowDown":
190
205
  e.preventDefault();
191
206
  focusKey(getNextFocusableKey(key()));
192
207
  return;
193
- case "ArrowLeft":
194
208
  case "ArrowUp":
195
209
  e.preventDefault();
196
210
  focusKey(getPreviousFocusableKey(key()));
@@ -226,39 +240,14 @@ export function createTag<T>(
226
240
  }
227
241
  };
228
242
 
229
- // Compute tabIndex
243
+ // Compute tabIndex. Mirror useTag (vendored @react-aria/tag/src/useTag.ts):
244
+ // tabIndex = (!isDisabled && (isFocused || focusedKey == null)) ? 0 : -1
245
+ // Every non-disabled row is a tab stop when nothing is focused yet (so native
246
+ // Shift+Tab from a following element lands on the LAST row); once a key is
247
+ // focused, only that row keeps tabIndex 0 (roving single tab stop).
230
248
  const tabIndex = createMemo(() => {
231
249
  if (isDisabled()) return -1;
232
-
233
- if (isFocused()) {
234
- return 0;
235
- }
236
-
237
- if (state.focusedKey() !== null) {
238
- return -1;
239
- }
240
-
241
- const collection = state.collection();
242
- let defaultTabStop: Key | null = null;
243
-
244
- if (state.selectionMode() !== "none") {
245
- for (const item of collection) {
246
- if (!state.isDisabled(item.key) && state.isSelected(item.key)) {
247
- defaultTabStop = item.key;
248
- break;
249
- }
250
- }
251
- }
252
-
253
- if (defaultTabStop == null) {
254
- defaultTabStop = getFirstFocusableKey();
255
- }
256
-
257
- if (key() === defaultTabStop) {
258
- return 0;
259
- }
260
-
261
- return -1;
250
+ return isFocused() || state.focusedKey() == null ? 0 : -1;
262
251
  });
263
252
 
264
253
  // Filter DOM props
@@ -35,6 +35,12 @@ export interface AriaTagGroupProps {
35
35
  errorMessage?: string;
36
36
  /** Handler that is called when a user removes a tag. */
37
37
  onRemove?: (keys: Set<Key>) => void;
38
+ /**
39
+ * The layout direction, threaded from `useLocale`. A TagGroup navigates on the
40
+ * inline axis, so ArrowLeft/ArrowRight flip under RTL (mirrors the direction
41
+ * the ListKeyboardDelegate receives from useTagGroup).
42
+ */
43
+ direction?: "ltr" | "rtl";
38
44
  }
39
45
 
40
46
  export interface TagGroupAria {
@@ -54,6 +60,7 @@ const tagGroupData = new WeakMap<object, TagGroupData>();
54
60
  interface TagGroupData {
55
61
  id: string;
56
62
  onRemove?: (keys: Set<Key>) => void;
63
+ direction: "ltr" | "rtl";
57
64
  }
58
65
 
59
66
  export function getTagGroupData(state: ListState): TagGroupData | undefined {
@@ -83,6 +90,9 @@ export function createTagGroup<T>(
83
90
  get onRemove() {
84
91
  return getProps().onRemove;
85
92
  },
93
+ get direction() {
94
+ return getProps().direction ?? "ltr";
95
+ },
86
96
  };
87
97
 
88
98
  // Filter DOM props
@@ -133,6 +143,82 @@ export function createTagGroup<T>(
133
143
  return ids.length > 0 ? ids.join(" ") : undefined;
134
144
  };
135
145
 
146
+ const getRef = () => _ref?.() ?? null;
147
+
148
+ // First/last navigable (non-disabled) row keys — the entry targets.
149
+ const getFirstNavigableKey = (): Key | null => {
150
+ const collection = state.collection();
151
+ let candidate = collection.getFirstKey();
152
+ while (candidate != null && state.isDisabled(candidate)) {
153
+ candidate = collection.getKeyAfter(candidate);
154
+ }
155
+ return candidate;
156
+ };
157
+
158
+ const getLastNavigableKey = (): Key | null => {
159
+ const collection = state.collection();
160
+ let candidate = collection.getLastKey();
161
+ while (candidate != null && state.isDisabled(candidate)) {
162
+ candidate = collection.getKeyBefore(candidate);
163
+ }
164
+ return candidate;
165
+ };
166
+
167
+ // Focus marshalling — the grid container is a trampoline. Its roving tabIndex
168
+ // is 0 only while `focusedKey == null` (see gridProps below), so a forward Tab
169
+ // that reaches the standalone container lands on the container itself; move the
170
+ // focused key onto the first/last row and the post-commit effect below pulls
171
+ // REAL DOM focus there while the container rolls to tabIndex -1. Mirrors
172
+ // useSelectableCollection's `onFocus` (via useTagGroup → useGridList). A
173
+ // Shift+Tab arriving directly on a row is handled by the row's own focusable
174
+ // onFocus, since every non-disabled row is a tab stop when nothing is focused.
175
+ const onFocus = (e: FocusEvent) => {
176
+ state.setFocused(true);
177
+
178
+ // `focus` is non-bubbling in Solid, so this fires only when the container
179
+ // itself receives focus; ignore anything that bubbled from a descendant.
180
+ const container = e.currentTarget as HTMLElement | null;
181
+ if (container && e.target && !container.contains(e.target as Node)) return;
182
+ if (state.focusedKey() != null || getProps().isDisabled) return;
183
+
184
+ const relatedTarget = e.relatedTarget as Element | null;
185
+ // Focus arriving from an element that FOLLOWS the group in document order
186
+ // means the user shift-tabbed backward into it → enter at the LAST row;
187
+ // otherwise (forward Tab, or programmatic) enter at the FIRST.
188
+ const enterKey =
189
+ relatedTarget &&
190
+ container &&
191
+ container.compareDocumentPosition(relatedTarget) & Node.DOCUMENT_POSITION_FOLLOWING
192
+ ? getLastNavigableKey()
193
+ : getFirstNavigableKey();
194
+ if (enterKey != null) {
195
+ state.setFocusedKey(enterKey);
196
+ }
197
+ };
198
+
199
+ const onBlur = () => {
200
+ state.setFocused(false);
201
+ };
202
+
203
+ // Once the roving tabindex for the focused key has committed to the DOM, move
204
+ // browser focus onto that row (looked up by its stable data-key), mirroring
205
+ // useSelectableCollection. Only manage focus while it already lives inside the
206
+ // container — i.e. the user is navigating via the trampoline — so a background
207
+ // focusedKey change never yanks focus from elsewhere on the page.
208
+ createEffect(() => {
209
+ const key = state.focusedKey();
210
+ const el = getRef();
211
+ if (!el || key == null) return;
212
+
213
+ const active = document.activeElement;
214
+ if (!active || (active !== el && !el.contains(active))) return;
215
+
216
+ const target = el.querySelector<HTMLElement>(`[data-key="${CSS.escape(String(key))}"]`);
217
+ if (target && target !== active) {
218
+ target.focus();
219
+ }
220
+ });
221
+
136
222
  return {
137
223
  get gridProps() {
138
224
  const p = getProps();
@@ -146,6 +232,12 @@ export function createTagGroup<T>(
146
232
  "aria-relevant": "additions",
147
233
  "aria-describedby": getAriaDescribedBy(),
148
234
  "aria-disabled": p.isDisabled || undefined,
235
+ // Roving container tabIndex mirrors useSelectableCollection: the container
236
+ // is tabbable (0) only while nothing is focused, then rolls to -1 once a
237
+ // row takes focus so Tab exits the group.
238
+ tabIndex: p.isDisabled ? undefined : state.focusedKey() != null ? -1 : 0,
239
+ onFocus,
240
+ onBlur,
149
241
  });
150
242
  },
151
243
  get labelProps() {
@@ -79,47 +79,6 @@ function getActiveElement(doc: Document): Element | null {
79
79
  return activeElement;
80
80
  }
81
81
 
82
- const TEXT_INPUT_TYPES = new Set([
83
- "",
84
- "text",
85
- "search",
86
- "url",
87
- "tel",
88
- "password",
89
- "email",
90
- "number",
91
- "date",
92
- "datetime-local",
93
- "month",
94
- "time",
95
- "week",
96
- ]);
97
-
98
- function isTextInputLikeElement(target: EventTarget | null): boolean {
99
- if (!(target instanceof HTMLElement)) {
100
- return false;
101
- }
102
-
103
- if (target.isContentEditable || !!target.closest('[contenteditable="true"]')) {
104
- return true;
105
- }
106
-
107
- if (target.getAttribute("role") === "textbox") {
108
- return true;
109
- }
110
-
111
- if (target instanceof HTMLTextAreaElement || target instanceof HTMLSelectElement) {
112
- return true;
113
- }
114
-
115
- if (target instanceof HTMLInputElement) {
116
- const type = target.type.toLowerCase();
117
- return TEXT_INPUT_TYPES.has(type);
118
- }
119
-
120
- return false;
121
- }
122
-
123
82
  function createFocusManager(ref: Accessor<HTMLElement | undefined>): FocusManager {
124
83
  return {
125
84
  focusNext(opts: FocusManagerOptions = {}) {
@@ -283,20 +242,6 @@ export function createToolbar(props: AriaToolbarProps = {}): ToolbarAria {
283
242
 
284
243
  const doc = getOwnerDocument(root);
285
244
 
286
- // Text entry controls keep the arrow keys for caret/value navigation.
287
- // Upstream useToolbar has no such guard; a text input placed inside a
288
- // toolbar would otherwise lose caret movement. Kept (narrowed to arrows)
289
- // as a suspected divergence pending a dedicated ActionBar/Toolbar cert.
290
- if (isTextInputLikeElement(target)) {
291
- switch (e.key) {
292
- case "ArrowRight":
293
- case "ArrowLeft":
294
- case "ArrowDown":
295
- case "ArrowUp":
296
- return;
297
- }
298
- }
299
-
300
245
  const dir = locale().direction;
301
246
  const isRTL = dir === "rtl";
302
247
  const isHorizontal = orientation() === "horizontal";
@@ -411,14 +356,17 @@ export function createToolbar(props: AriaToolbarProps = {}): ToolbarAria {
411
356
  return isInToolbar() ? "group" : "toolbar";
412
357
  },
413
358
  get "aria-orientation"() {
414
- return isInToolbar() ? undefined : orientation();
359
+ // Upstream useToolbar emits aria-orientation unconditionally, on the
360
+ // nested role="group" too — not only on the root role="toolbar".
361
+ return orientation();
415
362
  },
416
363
  get "aria-label"() {
417
364
  return ariaLabel();
418
365
  },
419
366
  get "aria-labelledby"() {
420
- // Only use aria-labelledby if no aria-label is provided
421
- return ariaLabel() ? undefined : ariaLabelledby();
367
+ // Mirror useToolbar: `aria-label == null ? aria-labelledby : undefined`.
368
+ // An explicit empty-string aria-label still suppresses labelledby.
369
+ return ariaLabel() == null ? ariaLabelledby() : undefined;
422
370
  },
423
371
  ref: setRef,
424
372
  },
@@ -240,24 +240,76 @@ export function createTree<T extends object, C extends TreeCollection<T> = TreeC
240
240
  }
241
241
  };
242
242
 
243
- const onFocus = () => {
243
+ // The first / last SELECTED key in flattened (visible) order — mirrors React
244
+ // Aria's `SelectionManager.firstSelectedKey`/`lastSelectedKey`, which entry
245
+ // focus prefers over the first/last row.
246
+ const firstSelectedKey = (s: TreeState<T, C>): Key | null => {
247
+ let key = s.collection.getFirstKey();
248
+ while (key != null) {
249
+ if (s.isSelected(key)) return key;
250
+ key = s.collection.getKeyAfter(key);
251
+ }
252
+ return null;
253
+ };
254
+ const lastSelectedKey = (s: TreeState<T, C>): Key | null => {
255
+ let key = s.collection.getLastKey();
256
+ while (key != null) {
257
+ if (s.isSelected(key)) return key;
258
+ key = s.collection.getKeyBefore(key);
259
+ }
260
+ return null;
261
+ };
262
+
263
+ // Entry focus is handled on `focusin` (BUBBLING) rather than `focus`
264
+ // (non-bubbling): React Aria's `useSelectableCollection.onFocus` bubbles, so a
265
+ // Shift+Tab that the browser parks on a tabbable descendant (e.g. a selection
266
+ // checkbox, which is `tabIndex=0` like upstream) still reaches the collection
267
+ // and is redirected to the focused/selected row. A Solid non-bubbling `focus`
268
+ // handler on the treegrid only fires for forward Tab (the container is the first
269
+ // tab stop) and would strand backward entry on the last checkbox — the same
270
+ // trampoline gotcha the TagGroup port hit. See `createListBox.onListBoxFocus`.
271
+ const onFocusIn = (e: FocusEvent) => {
244
272
  const s = state();
245
273
  s.setFocused(true);
246
274
 
247
- // If nothing is focused, focus the first navigable item
248
- if (s.focusedKey == null) {
249
- const firstKey = findNextNavigableKey(s, s.collection.getFirstKey(), (k) =>
250
- s.collection.getKeyAfter(k),
251
- );
252
- if (firstKey != null) {
253
- s.setFocusedKey(firstKey);
254
- }
275
+ const currentTarget = e.currentTarget as Element | null;
276
+ const relatedTarget = e.relatedTarget as Element | null;
277
+ // Internal roving moves (focus already inside the tree) are driven by
278
+ // `onKeyDown`; only seed focus when it enters from OUTSIDE the treegrid.
279
+ if (!currentTarget || (relatedTarget && currentTarget.contains(relatedTarget))) {
280
+ return;
281
+ }
282
+
283
+ let key = s.focusedKey;
284
+ if (key == null) {
285
+ // Shift+Tab backward into the tree (focus arrived from a FOLLOWING element)
286
+ // enters at the last selected row, else the last navigable row; forward Tab
287
+ // enters at the first selected row, else the first navigable row.
288
+ const backward =
289
+ !!relatedTarget &&
290
+ !!(
291
+ currentTarget.compareDocumentPosition(relatedTarget) &
292
+ Node.DOCUMENT_POSITION_FOLLOWING
293
+ );
294
+ key = backward
295
+ ? (lastSelectedKey(s) ??
296
+ findNextNavigableKey(s, s.collection.getLastKey(), (k) => s.collection.getKeyBefore(k)))
297
+ : (firstSelectedKey(s) ??
298
+ findNextNavigableKey(s, s.collection.getFirstKey(), (k) => s.collection.getKeyAfter(k)));
299
+ }
300
+ if (key != null) {
301
+ s.setFocusedKey(key);
255
302
  }
256
303
  };
257
304
 
258
- const onBlur = () => {
305
+ const onFocusOut = (e: FocusEvent) => {
259
306
  const s = state();
260
- s.setFocused(false);
307
+ const currentTarget = e.currentTarget as Element | null;
308
+ const relatedTarget = e.relatedTarget as Element | null;
309
+ // Only clear the focused flag once focus has left the treegrid entirely.
310
+ if (!currentTarget || !relatedTarget || !currentTarget.contains(relatedTarget)) {
311
+ s.setFocused(false);
312
+ }
261
313
  };
262
314
 
263
315
  createEffect(() => {
@@ -295,10 +347,13 @@ export function createTree<T extends object, C extends TreeCollection<T> = TreeC
295
347
  "aria-describedby": p["aria-describedby"],
296
348
  "aria-multiselectable": s.selectionMode === "multiple" ? true : undefined,
297
349
  "aria-disabled": p.isDisabled || undefined,
298
- tabIndex: p.isDisabled ? undefined : 0,
350
+ // Roving container tab stop: `0` while no row is focused (Tab enters the
351
+ // tree), `-1` once a row takes focus (the row holds the tab stop). Mirrors
352
+ // `useSelectableCollection` `tabIndex = focusedKey == null ? 0 : -1`.
353
+ tabIndex: p.isDisabled ? undefined : s.focusedKey == null ? 0 : -1,
299
354
  onKeyDown,
300
- onFocus,
301
- onBlur,
355
+ onFocusIn,
356
+ onFocusOut,
302
357
  };
303
358
 
304
359
  // Add row count for virtualized trees
@@ -5,8 +5,10 @@
5
5
 
6
6
  import { createMemo, type Accessor } from "solid-js";
7
7
  import type { JSX } from "solid-js";
8
+ import { createId } from "@proyecto-viviana/solid-stately";
8
9
  import type { TreeState, TreeCollection } from "@proyecto-viviana/solid-stately";
9
10
  import type { AriaTreeSelectionCheckboxProps, TreeSelectionCheckboxAria } from "./types";
11
+ import { getTreeData } from "./createTree";
10
12
 
11
13
  /**
12
14
  * Creates accessibility props for a tree selection checkbox.
@@ -18,6 +20,16 @@ export function createTreeSelectionCheckbox<
18
20
  props: Accessor<AriaTreeSelectionCheckboxProps>,
19
21
  state: Accessor<TreeState<T, C>>,
20
22
  ): TreeSelectionCheckboxAria {
23
+ const fallbackRowId = createId();
24
+ const checkboxId = createId();
25
+
26
+ // Mirror @react-aria/tree getRowId: the checkbox's aria-labelledby folds its own
27
+ // "Select" label with the row's id so the SR announces "Select <row text>".
28
+ const rowId = createMemo(() => {
29
+ const treeData = getTreeData(state());
30
+ return treeData ? `${treeData.treeId}-row-${String(props().key)}` : fallbackRowId;
31
+ });
32
+
21
33
  const isSelected = createMemo(() => {
22
34
  const s = state();
23
35
  const p = props();
@@ -52,12 +64,13 @@ export function createTreeSelectionCheckbox<
52
64
  const checkboxProps = createMemo(() => {
53
65
  const baseProps: Record<string, unknown> = {
54
66
  type: "checkbox",
67
+ id: checkboxId,
55
68
  "aria-label": "Select",
69
+ "aria-labelledby": `${checkboxId} ${rowId()}`,
56
70
  checked: isSelected(),
57
71
  disabled: isDisabled(),
58
72
  onChange,
59
73
  onClick,
60
- tabIndex: -1, // Use arrow keys to navigate, not tab
61
74
  };
62
75
 
63
76
  return baseProps as JSX.InputHTMLAttributes<HTMLInputElement>;