react-stately 3.46.0 → 3.47.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (496) hide show
  1. package/dist/exports/Color.cjs.map +1 -1
  2. package/dist/exports/Color.js.map +1 -1
  3. package/dist/exports/Color.mjs.map +1 -1
  4. package/dist/exports/index.cjs.map +1 -1
  5. package/dist/exports/index.js.map +1 -1
  6. package/dist/exports/index.mjs.map +1 -1
  7. package/dist/exports/private/autocomplete/useAutocompleteState.cjs.map +1 -1
  8. package/dist/exports/private/autocomplete/useAutocompleteState.js.map +1 -1
  9. package/dist/exports/private/autocomplete/useAutocompleteState.mjs.map +1 -1
  10. package/dist/exports/private/collections/getChildNodes.cjs.map +1 -1
  11. package/dist/exports/private/collections/getChildNodes.js.map +1 -1
  12. package/dist/exports/private/collections/getChildNodes.mjs.map +1 -1
  13. package/dist/exports/private/flags/flags.cjs.map +1 -1
  14. package/dist/exports/private/flags/flags.js.map +1 -1
  15. package/dist/exports/private/flags/flags.mjs.map +1 -1
  16. package/dist/exports/private/form/useFormValidationState.cjs.map +1 -1
  17. package/dist/exports/private/form/useFormValidationState.js.map +1 -1
  18. package/dist/exports/private/form/useFormValidationState.mjs.map +1 -1
  19. package/dist/exports/private/grid/GridCollection.cjs.map +1 -1
  20. package/dist/exports/private/grid/GridCollection.js.map +1 -1
  21. package/dist/exports/private/grid/GridCollection.mjs.map +1 -1
  22. package/dist/exports/private/steplist/useStepListState.cjs.map +1 -1
  23. package/dist/exports/private/steplist/useStepListState.js.map +1 -1
  24. package/dist/exports/private/steplist/useStepListState.mjs.map +1 -1
  25. package/dist/exports/private/table/TableCollection.cjs.map +1 -1
  26. package/dist/exports/private/table/TableCollection.js.map +1 -1
  27. package/dist/exports/private/table/TableCollection.mjs.map +1 -1
  28. package/dist/exports/private/table/useTreeGridState.cjs.map +1 -1
  29. package/dist/exports/private/table/useTreeGridState.js.map +1 -1
  30. package/dist/exports/private/table/useTreeGridState.mjs.map +1 -1
  31. package/dist/exports/useAsyncList.cjs.map +1 -1
  32. package/dist/exports/useAsyncList.js.map +1 -1
  33. package/dist/exports/useAsyncList.mjs.map +1 -1
  34. package/dist/exports/useCalendarState.cjs.map +1 -1
  35. package/dist/exports/useCalendarState.js.map +1 -1
  36. package/dist/exports/useCalendarState.mjs.map +1 -1
  37. package/dist/exports/useColorAreaState.cjs.map +1 -1
  38. package/dist/exports/useColorAreaState.js.map +1 -1
  39. package/dist/exports/useColorAreaState.mjs.map +1 -1
  40. package/dist/exports/useColorFieldState.cjs.map +1 -1
  41. package/dist/exports/useColorFieldState.js.map +1 -1
  42. package/dist/exports/useColorFieldState.mjs.map +1 -1
  43. package/dist/exports/useColorPickerState.cjs.map +1 -1
  44. package/dist/exports/useColorPickerState.js.map +1 -1
  45. package/dist/exports/useColorPickerState.mjs.map +1 -1
  46. package/dist/exports/useColorSliderState.cjs.map +1 -1
  47. package/dist/exports/useColorSliderState.js.map +1 -1
  48. package/dist/exports/useColorSliderState.mjs.map +1 -1
  49. package/dist/exports/useColorWheelState.cjs.map +1 -1
  50. package/dist/exports/useColorWheelState.js.map +1 -1
  51. package/dist/exports/useColorWheelState.mjs.map +1 -1
  52. package/dist/exports/useComboBoxState.cjs +1 -1
  53. package/dist/exports/useComboBoxState.cjs.map +1 -1
  54. package/dist/exports/useComboBoxState.js +1 -1
  55. package/dist/exports/useComboBoxState.js.map +1 -1
  56. package/dist/exports/useComboBoxState.mjs +1 -1
  57. package/dist/exports/useComboBoxState.mjs.map +1 -1
  58. package/dist/exports/useDateFieldState.cjs.map +1 -1
  59. package/dist/exports/useDateFieldState.js.map +1 -1
  60. package/dist/exports/useDateFieldState.mjs.map +1 -1
  61. package/dist/exports/useDatePickerState.cjs.map +1 -1
  62. package/dist/exports/useDatePickerState.js.map +1 -1
  63. package/dist/exports/useDatePickerState.mjs.map +1 -1
  64. package/dist/exports/useDateRangePickerState.cjs.map +1 -1
  65. package/dist/exports/useDateRangePickerState.js.map +1 -1
  66. package/dist/exports/useDateRangePickerState.mjs.map +1 -1
  67. package/dist/exports/useDisclosureGroupState.cjs.map +1 -1
  68. package/dist/exports/useDisclosureGroupState.js.map +1 -1
  69. package/dist/exports/useDisclosureGroupState.mjs.map +1 -1
  70. package/dist/exports/useDraggableCollectionState.cjs.map +1 -1
  71. package/dist/exports/useDraggableCollectionState.js.map +1 -1
  72. package/dist/exports/useDraggableCollectionState.mjs.map +1 -1
  73. package/dist/exports/useDroppableCollectionState.cjs.map +1 -1
  74. package/dist/exports/useDroppableCollectionState.js.map +1 -1
  75. package/dist/exports/useDroppableCollectionState.mjs.map +1 -1
  76. package/dist/exports/useMenuTriggerState.cjs.map +1 -1
  77. package/dist/exports/useMenuTriggerState.js.map +1 -1
  78. package/dist/exports/useMenuTriggerState.mjs.map +1 -1
  79. package/dist/exports/useMultipleSelectionState.cjs.map +1 -1
  80. package/dist/exports/useMultipleSelectionState.js.map +1 -1
  81. package/dist/exports/useMultipleSelectionState.mjs.map +1 -1
  82. package/dist/exports/useOverlayTriggerState.cjs.map +1 -1
  83. package/dist/exports/useOverlayTriggerState.js.map +1 -1
  84. package/dist/exports/useOverlayTriggerState.mjs.map +1 -1
  85. package/dist/exports/useRangeCalendarState.cjs.map +1 -1
  86. package/dist/exports/useRangeCalendarState.js.map +1 -1
  87. package/dist/exports/useRangeCalendarState.mjs.map +1 -1
  88. package/dist/exports/useSelectState.cjs.map +1 -1
  89. package/dist/exports/useSelectState.js.map +1 -1
  90. package/dist/exports/useSelectState.mjs.map +1 -1
  91. package/dist/exports/useSingleSelectListState.cjs.map +1 -1
  92. package/dist/exports/useSingleSelectListState.js.map +1 -1
  93. package/dist/exports/useSingleSelectListState.mjs.map +1 -1
  94. package/dist/exports/useTableState.cjs.map +1 -1
  95. package/dist/exports/useTableState.js.map +1 -1
  96. package/dist/exports/useTableState.mjs.map +1 -1
  97. package/dist/exports/useTimeFieldState.cjs.map +1 -1
  98. package/dist/exports/useTimeFieldState.js.map +1 -1
  99. package/dist/exports/useTimeFieldState.mjs.map +1 -1
  100. package/dist/exports/useToastState.cjs.map +1 -1
  101. package/dist/exports/useToastState.js.map +1 -1
  102. package/dist/exports/useToastState.mjs.map +1 -1
  103. package/dist/private/autocomplete/useAutocompleteState.cjs.map +1 -1
  104. package/dist/private/autocomplete/useAutocompleteState.js.map +1 -1
  105. package/dist/private/autocomplete/useAutocompleteState.mjs.map +1 -1
  106. package/dist/private/calendar/useCalendarState.cjs +82 -30
  107. package/dist/private/calendar/useCalendarState.cjs.map +1 -1
  108. package/dist/private/calendar/useCalendarState.js +85 -32
  109. package/dist/private/calendar/useCalendarState.js.map +1 -1
  110. package/dist/private/calendar/useCalendarState.mjs +84 -32
  111. package/dist/private/calendar/useCalendarState.mjs.map +1 -1
  112. package/dist/private/calendar/useRangeCalendarState.cjs +53 -40
  113. package/dist/private/calendar/useRangeCalendarState.cjs.map +1 -1
  114. package/dist/private/calendar/useRangeCalendarState.js +55 -43
  115. package/dist/private/calendar/useRangeCalendarState.js.map +1 -1
  116. package/dist/private/calendar/useRangeCalendarState.mjs +55 -42
  117. package/dist/private/calendar/useRangeCalendarState.mjs.map +1 -1
  118. package/dist/private/calendar/utils.cjs +6 -1
  119. package/dist/private/calendar/utils.cjs.map +1 -1
  120. package/dist/private/calendar/utils.js +6 -2
  121. package/dist/private/calendar/utils.js.map +1 -1
  122. package/dist/private/calendar/utils.mjs +6 -2
  123. package/dist/private/calendar/utils.mjs.map +1 -1
  124. package/dist/private/checkbox/useCheckboxGroupState.cjs.map +1 -1
  125. package/dist/private/checkbox/useCheckboxGroupState.js.map +1 -1
  126. package/dist/private/checkbox/useCheckboxGroupState.mjs.map +1 -1
  127. package/dist/private/collections/CollectionBuilder.cjs.map +1 -1
  128. package/dist/private/collections/CollectionBuilder.js.map +1 -1
  129. package/dist/private/collections/CollectionBuilder.mjs.map +1 -1
  130. package/dist/private/collections/Item.cjs +1 -0
  131. package/dist/private/collections/Item.cjs.map +1 -1
  132. package/dist/private/collections/Item.js +1 -0
  133. package/dist/private/collections/Item.js.map +1 -1
  134. package/dist/private/collections/Item.mjs +1 -0
  135. package/dist/private/collections/Item.mjs.map +1 -1
  136. package/dist/private/collections/Section.cjs +1 -0
  137. package/dist/private/collections/Section.cjs.map +1 -1
  138. package/dist/private/collections/Section.js +1 -0
  139. package/dist/private/collections/Section.js.map +1 -1
  140. package/dist/private/collections/Section.mjs +1 -0
  141. package/dist/private/collections/Section.mjs.map +1 -1
  142. package/dist/private/collections/getChildNodes.cjs.map +1 -1
  143. package/dist/private/collections/getChildNodes.js.map +1 -1
  144. package/dist/private/collections/getChildNodes.mjs.map +1 -1
  145. package/dist/private/collections/useCollection.cjs.map +1 -1
  146. package/dist/private/collections/useCollection.js.map +1 -1
  147. package/dist/private/collections/useCollection.mjs.map +1 -1
  148. package/dist/private/color/Color.cjs +15 -9
  149. package/dist/private/color/Color.cjs.map +1 -1
  150. package/dist/private/color/Color.js +15 -9
  151. package/dist/private/color/Color.js.map +1 -1
  152. package/dist/private/color/Color.mjs +15 -9
  153. package/dist/private/color/Color.mjs.map +1 -1
  154. package/dist/private/color/useColorAreaState.cjs.map +1 -1
  155. package/dist/private/color/useColorAreaState.js.map +1 -1
  156. package/dist/private/color/useColorAreaState.mjs.map +1 -1
  157. package/dist/private/color/useColorChannelFieldState.cjs.map +1 -1
  158. package/dist/private/color/useColorChannelFieldState.js.map +1 -1
  159. package/dist/private/color/useColorChannelFieldState.mjs.map +1 -1
  160. package/dist/private/color/useColorFieldState.cjs.map +1 -1
  161. package/dist/private/color/useColorFieldState.js.map +1 -1
  162. package/dist/private/color/useColorFieldState.mjs.map +1 -1
  163. package/dist/private/color/useColorPickerState.cjs.map +1 -1
  164. package/dist/private/color/useColorPickerState.js.map +1 -1
  165. package/dist/private/color/useColorPickerState.mjs.map +1 -1
  166. package/dist/private/color/useColorSliderState.cjs +5 -3
  167. package/dist/private/color/useColorSliderState.cjs.map +1 -1
  168. package/dist/private/color/useColorSliderState.js +5 -3
  169. package/dist/private/color/useColorSliderState.js.map +1 -1
  170. package/dist/private/color/useColorSliderState.mjs +5 -3
  171. package/dist/private/color/useColorSliderState.mjs.map +1 -1
  172. package/dist/private/color/useColorWheelState.cjs.map +1 -1
  173. package/dist/private/color/useColorWheelState.js.map +1 -1
  174. package/dist/private/color/useColorWheelState.mjs.map +1 -1
  175. package/dist/private/combobox/useComboBoxState.cjs +8 -2
  176. package/dist/private/combobox/useComboBoxState.cjs.map +1 -1
  177. package/dist/private/combobox/useComboBoxState.js +8 -2
  178. package/dist/private/combobox/useComboBoxState.js.map +1 -1
  179. package/dist/private/combobox/useComboBoxState.mjs +8 -2
  180. package/dist/private/combobox/useComboBoxState.mjs.map +1 -1
  181. package/dist/private/data/useAsyncList.cjs.map +1 -1
  182. package/dist/private/data/useAsyncList.js.map +1 -1
  183. package/dist/private/data/useAsyncList.mjs.map +1 -1
  184. package/dist/private/data/useListData.cjs.map +1 -1
  185. package/dist/private/data/useListData.js.map +1 -1
  186. package/dist/private/data/useListData.mjs.map +1 -1
  187. package/dist/private/data/useTreeData.cjs.map +1 -1
  188. package/dist/private/data/useTreeData.js.map +1 -1
  189. package/dist/private/data/useTreeData.mjs.map +1 -1
  190. package/dist/private/datepicker/IncompleteDate.cjs +8 -2
  191. package/dist/private/datepicker/IncompleteDate.cjs.map +1 -1
  192. package/dist/private/datepicker/IncompleteDate.js +8 -2
  193. package/dist/private/datepicker/IncompleteDate.js.map +1 -1
  194. package/dist/private/datepicker/IncompleteDate.mjs +8 -2
  195. package/dist/private/datepicker/IncompleteDate.mjs.map +1 -1
  196. package/dist/private/datepicker/placeholders.cjs +5 -0
  197. package/dist/private/datepicker/placeholders.cjs.map +1 -1
  198. package/dist/private/datepicker/placeholders.js +5 -0
  199. package/dist/private/datepicker/placeholders.js.map +1 -1
  200. package/dist/private/datepicker/placeholders.mjs +5 -0
  201. package/dist/private/datepicker/placeholders.mjs.map +1 -1
  202. package/dist/private/datepicker/useDateFieldState.cjs.map +1 -1
  203. package/dist/private/datepicker/useDateFieldState.js.map +1 -1
  204. package/dist/private/datepicker/useDateFieldState.mjs.map +1 -1
  205. package/dist/private/datepicker/useDatePickerState.cjs.map +1 -1
  206. package/dist/private/datepicker/useDatePickerState.js.map +1 -1
  207. package/dist/private/datepicker/useDatePickerState.mjs.map +1 -1
  208. package/dist/private/datepicker/useDateRangePickerState.cjs +1 -1
  209. package/dist/private/datepicker/useDateRangePickerState.cjs.map +1 -1
  210. package/dist/private/datepicker/useDateRangePickerState.js +1 -1
  211. package/dist/private/datepicker/useDateRangePickerState.js.map +1 -1
  212. package/dist/private/datepicker/useDateRangePickerState.mjs +1 -1
  213. package/dist/private/datepicker/useDateRangePickerState.mjs.map +1 -1
  214. package/dist/private/datepicker/useTimeFieldState.cjs.map +1 -1
  215. package/dist/private/datepicker/useTimeFieldState.js.map +1 -1
  216. package/dist/private/datepicker/useTimeFieldState.mjs.map +1 -1
  217. package/dist/private/datepicker/utils.cjs +2 -2
  218. package/dist/private/datepicker/utils.cjs.map +1 -1
  219. package/dist/private/datepicker/utils.js +2 -2
  220. package/dist/private/datepicker/utils.js.map +1 -1
  221. package/dist/private/datepicker/utils.mjs +2 -2
  222. package/dist/private/datepicker/utils.mjs.map +1 -1
  223. package/dist/private/disclosure/useDisclosureGroupState.cjs.map +1 -1
  224. package/dist/private/disclosure/useDisclosureGroupState.js.map +1 -1
  225. package/dist/private/disclosure/useDisclosureGroupState.mjs.map +1 -1
  226. package/dist/private/disclosure/useDisclosureState.cjs.map +1 -1
  227. package/dist/private/disclosure/useDisclosureState.js.map +1 -1
  228. package/dist/private/disclosure/useDisclosureState.mjs.map +1 -1
  229. package/dist/private/dnd/useDraggableCollectionState.cjs.map +1 -1
  230. package/dist/private/dnd/useDraggableCollectionState.js.map +1 -1
  231. package/dist/private/dnd/useDraggableCollectionState.mjs.map +1 -1
  232. package/dist/private/dnd/useDroppableCollectionState.cjs.map +1 -1
  233. package/dist/private/dnd/useDroppableCollectionState.js.map +1 -1
  234. package/dist/private/dnd/useDroppableCollectionState.mjs.map +1 -1
  235. package/dist/private/form/useFormValidationState.cjs.map +1 -1
  236. package/dist/private/form/useFormValidationState.js.map +1 -1
  237. package/dist/private/form/useFormValidationState.mjs.map +1 -1
  238. package/dist/private/grid/GridCollection.cjs.map +1 -1
  239. package/dist/private/grid/GridCollection.js.map +1 -1
  240. package/dist/private/grid/GridCollection.mjs.map +1 -1
  241. package/dist/private/grid/useGridState.cjs.map +1 -1
  242. package/dist/private/grid/useGridState.js.map +1 -1
  243. package/dist/private/grid/useGridState.mjs.map +1 -1
  244. package/dist/private/layout/GridLayout.cjs +8 -3
  245. package/dist/private/layout/GridLayout.cjs.map +1 -1
  246. package/dist/private/layout/GridLayout.js +8 -3
  247. package/dist/private/layout/GridLayout.js.map +1 -1
  248. package/dist/private/layout/GridLayout.mjs +8 -3
  249. package/dist/private/layout/GridLayout.mjs.map +1 -1
  250. package/dist/private/layout/ListLayout.cjs +1 -1
  251. package/dist/private/layout/ListLayout.cjs.map +1 -1
  252. package/dist/private/layout/ListLayout.js +2 -1
  253. package/dist/private/layout/ListLayout.js.map +1 -1
  254. package/dist/private/layout/ListLayout.mjs +1 -1
  255. package/dist/private/layout/ListLayout.mjs.map +1 -1
  256. package/dist/private/layout/TableLayout.cjs +60 -35
  257. package/dist/private/layout/TableLayout.cjs.map +1 -1
  258. package/dist/private/layout/TableLayout.js +65 -38
  259. package/dist/private/layout/TableLayout.js.map +1 -1
  260. package/dist/private/layout/TableLayout.mjs +61 -36
  261. package/dist/private/layout/TableLayout.mjs.map +1 -1
  262. package/dist/private/layout/WaterfallLayout.cjs.map +1 -1
  263. package/dist/private/layout/WaterfallLayout.js.map +1 -1
  264. package/dist/private/layout/WaterfallLayout.mjs.map +1 -1
  265. package/dist/private/list/ListCollection.cjs.map +1 -1
  266. package/dist/private/list/ListCollection.js.map +1 -1
  267. package/dist/private/list/ListCollection.mjs.map +1 -1
  268. package/dist/private/list/useListState.cjs.map +1 -1
  269. package/dist/private/list/useListState.js.map +1 -1
  270. package/dist/private/list/useListState.mjs.map +1 -1
  271. package/dist/private/list/useSingleSelectListState.cjs.map +1 -1
  272. package/dist/private/list/useSingleSelectListState.js.map +1 -1
  273. package/dist/private/list/useSingleSelectListState.mjs.map +1 -1
  274. package/dist/private/menu/useMenuTriggerState.cjs.map +1 -1
  275. package/dist/private/menu/useMenuTriggerState.js.map +1 -1
  276. package/dist/private/menu/useMenuTriggerState.mjs.map +1 -1
  277. package/dist/private/menu/useSubmenuTriggerState.cjs.map +1 -1
  278. package/dist/private/menu/useSubmenuTriggerState.js.map +1 -1
  279. package/dist/private/menu/useSubmenuTriggerState.mjs.map +1 -1
  280. package/dist/private/numberfield/useNumberFieldState.cjs +13 -1
  281. package/dist/private/numberfield/useNumberFieldState.cjs.map +1 -1
  282. package/dist/private/numberfield/useNumberFieldState.js +13 -1
  283. package/dist/private/numberfield/useNumberFieldState.js.map +1 -1
  284. package/dist/private/numberfield/useNumberFieldState.mjs +13 -1
  285. package/dist/private/numberfield/useNumberFieldState.mjs.map +1 -1
  286. package/dist/private/overlays/useOverlayTriggerState.cjs.map +1 -1
  287. package/dist/private/overlays/useOverlayTriggerState.js.map +1 -1
  288. package/dist/private/overlays/useOverlayTriggerState.mjs.map +1 -1
  289. package/dist/private/radio/useRadioGroupState.cjs.map +1 -1
  290. package/dist/private/radio/useRadioGroupState.js.map +1 -1
  291. package/dist/private/radio/useRadioGroupState.mjs.map +1 -1
  292. package/dist/private/searchfield/useSearchFieldState.cjs.map +1 -1
  293. package/dist/private/searchfield/useSearchFieldState.js.map +1 -1
  294. package/dist/private/searchfield/useSearchFieldState.mjs.map +1 -1
  295. package/dist/private/select/useSelectState.cjs.map +1 -1
  296. package/dist/private/select/useSelectState.js.map +1 -1
  297. package/dist/private/select/useSelectState.mjs.map +1 -1
  298. package/dist/private/selection/SelectionManager.cjs +2 -1
  299. package/dist/private/selection/SelectionManager.cjs.map +1 -1
  300. package/dist/private/selection/SelectionManager.js +3 -2
  301. package/dist/private/selection/SelectionManager.js.map +1 -1
  302. package/dist/private/selection/SelectionManager.mjs +2 -1
  303. package/dist/private/selection/SelectionManager.mjs.map +1 -1
  304. package/dist/private/selection/useMultipleSelectionState.cjs.map +1 -1
  305. package/dist/private/selection/useMultipleSelectionState.js.map +1 -1
  306. package/dist/private/selection/useMultipleSelectionState.mjs.map +1 -1
  307. package/dist/private/slider/useSliderState.cjs +22 -2
  308. package/dist/private/slider/useSliderState.cjs.map +1 -1
  309. package/dist/private/slider/useSliderState.js +22 -2
  310. package/dist/private/slider/useSliderState.js.map +1 -1
  311. package/dist/private/slider/useSliderState.mjs +22 -2
  312. package/dist/private/slider/useSliderState.mjs.map +1 -1
  313. package/dist/private/steplist/useStepListState.cjs.map +1 -1
  314. package/dist/private/steplist/useStepListState.js.map +1 -1
  315. package/dist/private/steplist/useStepListState.mjs.map +1 -1
  316. package/dist/private/table/Cell.cjs +2 -1
  317. package/dist/private/table/Cell.cjs.map +1 -1
  318. package/dist/private/table/Cell.js +2 -1
  319. package/dist/private/table/Cell.js.map +1 -1
  320. package/dist/private/table/Cell.mjs +2 -1
  321. package/dist/private/table/Cell.mjs.map +1 -1
  322. package/dist/private/table/Column.cjs +1 -0
  323. package/dist/private/table/Column.cjs.map +1 -1
  324. package/dist/private/table/Column.js +1 -0
  325. package/dist/private/table/Column.js.map +1 -1
  326. package/dist/private/table/Column.mjs +1 -0
  327. package/dist/private/table/Column.mjs.map +1 -1
  328. package/dist/private/table/Row.cjs +2 -1
  329. package/dist/private/table/Row.cjs.map +1 -1
  330. package/dist/private/table/Row.js +2 -1
  331. package/dist/private/table/Row.js.map +1 -1
  332. package/dist/private/table/Row.mjs +2 -1
  333. package/dist/private/table/Row.mjs.map +1 -1
  334. package/dist/private/table/TableBody.cjs +4 -2
  335. package/dist/private/table/TableBody.cjs.map +1 -1
  336. package/dist/private/table/TableBody.js +4 -2
  337. package/dist/private/table/TableBody.js.map +1 -1
  338. package/dist/private/table/TableBody.mjs +4 -2
  339. package/dist/private/table/TableBody.mjs.map +1 -1
  340. package/dist/private/table/TableCollection.cjs +1 -1
  341. package/dist/private/table/TableCollection.cjs.map +1 -1
  342. package/dist/private/table/TableCollection.js +1 -1
  343. package/dist/private/table/TableCollection.js.map +1 -1
  344. package/dist/private/table/TableCollection.mjs +1 -1
  345. package/dist/private/table/TableCollection.mjs.map +1 -1
  346. package/dist/private/table/TableColumnLayout.cjs +4 -1
  347. package/dist/private/table/TableColumnLayout.cjs.map +1 -1
  348. package/dist/private/table/TableColumnLayout.js +4 -1
  349. package/dist/private/table/TableColumnLayout.js.map +1 -1
  350. package/dist/private/table/TableColumnLayout.mjs +4 -1
  351. package/dist/private/table/TableColumnLayout.mjs.map +1 -1
  352. package/dist/private/table/TableHeader.cjs +4 -2
  353. package/dist/private/table/TableHeader.cjs.map +1 -1
  354. package/dist/private/table/TableHeader.js +4 -2
  355. package/dist/private/table/TableHeader.js.map +1 -1
  356. package/dist/private/table/TableHeader.mjs +4 -2
  357. package/dist/private/table/TableHeader.mjs.map +1 -1
  358. package/dist/private/table/TableUtils.cjs +1 -1
  359. package/dist/private/table/TableUtils.cjs.map +1 -1
  360. package/dist/private/table/TableUtils.js +1 -1
  361. package/dist/private/table/TableUtils.js.map +1 -1
  362. package/dist/private/table/TableUtils.mjs +1 -1
  363. package/dist/private/table/TableUtils.mjs.map +1 -1
  364. package/dist/private/table/useTableColumnResizeState.cjs.map +1 -1
  365. package/dist/private/table/useTableColumnResizeState.js.map +1 -1
  366. package/dist/private/table/useTableColumnResizeState.mjs.map +1 -1
  367. package/dist/private/table/useTableState.cjs +2 -1
  368. package/dist/private/table/useTableState.cjs.map +1 -1
  369. package/dist/private/table/useTableState.js +2 -1
  370. package/dist/private/table/useTableState.js.map +1 -1
  371. package/dist/private/table/useTableState.mjs +2 -1
  372. package/dist/private/table/useTableState.mjs.map +1 -1
  373. package/dist/private/table/useTreeGridState.cjs +2 -1
  374. package/dist/private/table/useTreeGridState.cjs.map +1 -1
  375. package/dist/private/table/useTreeGridState.js +2 -1
  376. package/dist/private/table/useTreeGridState.js.map +1 -1
  377. package/dist/private/table/useTreeGridState.mjs +2 -1
  378. package/dist/private/table/useTreeGridState.mjs.map +1 -1
  379. package/dist/private/tabs/useTabListState.cjs.map +1 -1
  380. package/dist/private/tabs/useTabListState.js.map +1 -1
  381. package/dist/private/tabs/useTabListState.mjs.map +1 -1
  382. package/dist/private/toast/useToastState.cjs.map +1 -1
  383. package/dist/private/toast/useToastState.js.map +1 -1
  384. package/dist/private/toast/useToastState.mjs.map +1 -1
  385. package/dist/private/toggle/useToggleGroupState.cjs.map +1 -1
  386. package/dist/private/toggle/useToggleGroupState.js.map +1 -1
  387. package/dist/private/toggle/useToggleGroupState.mjs.map +1 -1
  388. package/dist/private/toggle/useToggleState.cjs.map +1 -1
  389. package/dist/private/toggle/useToggleState.js.map +1 -1
  390. package/dist/private/toggle/useToggleState.mjs.map +1 -1
  391. package/dist/private/tooltip/useTooltipTriggerState.cjs.map +1 -1
  392. package/dist/private/tooltip/useTooltipTriggerState.js.map +1 -1
  393. package/dist/private/tooltip/useTooltipTriggerState.mjs.map +1 -1
  394. package/dist/private/tree/TreeCollection.cjs.map +1 -1
  395. package/dist/private/tree/TreeCollection.js.map +1 -1
  396. package/dist/private/tree/TreeCollection.mjs.map +1 -1
  397. package/dist/private/tree/useTreeState.cjs.map +1 -1
  398. package/dist/private/tree/useTreeState.js.map +1 -1
  399. package/dist/private/tree/useTreeState.mjs.map +1 -1
  400. package/dist/private/utils/number.cjs +2 -1
  401. package/dist/private/utils/number.cjs.map +1 -1
  402. package/dist/private/utils/number.js +2 -1
  403. package/dist/private/utils/number.js.map +1 -1
  404. package/dist/private/utils/number.mjs +2 -1
  405. package/dist/private/utils/number.mjs.map +1 -1
  406. package/dist/private/utils/useControlledState.cjs.map +1 -1
  407. package/dist/private/utils/useControlledState.js.map +1 -1
  408. package/dist/private/utils/useControlledState.mjs.map +1 -1
  409. package/dist/private/virtualizer/Layout.cjs.map +1 -1
  410. package/dist/private/virtualizer/Layout.js.map +1 -1
  411. package/dist/private/virtualizer/Layout.mjs.map +1 -1
  412. package/dist/private/virtualizer/LayoutInfo.cjs +4 -2
  413. package/dist/private/virtualizer/LayoutInfo.cjs.map +1 -1
  414. package/dist/private/virtualizer/LayoutInfo.js +4 -2
  415. package/dist/private/virtualizer/LayoutInfo.js.map +1 -1
  416. package/dist/private/virtualizer/LayoutInfo.mjs +4 -2
  417. package/dist/private/virtualizer/LayoutInfo.mjs.map +1 -1
  418. package/dist/private/virtualizer/Rect.cjs +4 -0
  419. package/dist/private/virtualizer/Rect.cjs.map +1 -1
  420. package/dist/private/virtualizer/Rect.js +4 -0
  421. package/dist/private/virtualizer/Rect.js.map +1 -1
  422. package/dist/private/virtualizer/Rect.mjs +4 -0
  423. package/dist/private/virtualizer/Rect.mjs.map +1 -1
  424. package/dist/private/virtualizer/ReusableView.cjs.map +1 -1
  425. package/dist/private/virtualizer/ReusableView.js.map +1 -1
  426. package/dist/private/virtualizer/ReusableView.mjs.map +1 -1
  427. package/dist/private/virtualizer/Size.cjs.map +1 -1
  428. package/dist/private/virtualizer/Size.js.map +1 -1
  429. package/dist/private/virtualizer/Size.mjs.map +1 -1
  430. package/dist/private/virtualizer/Virtualizer.cjs +4 -4
  431. package/dist/private/virtualizer/Virtualizer.cjs.map +1 -1
  432. package/dist/private/virtualizer/Virtualizer.js +4 -4
  433. package/dist/private/virtualizer/Virtualizer.js.map +1 -1
  434. package/dist/private/virtualizer/Virtualizer.mjs +4 -4
  435. package/dist/private/virtualizer/Virtualizer.mjs.map +1 -1
  436. package/dist/private/virtualizer/useVirtualizerState.cjs.map +1 -1
  437. package/dist/private/virtualizer/useVirtualizerState.js.map +1 -1
  438. package/dist/private/virtualizer/useVirtualizerState.mjs.map +1 -1
  439. package/dist/types/exports/useCalendarState.d.ts +1 -1
  440. package/dist/types/src/autocomplete/useAutocompleteState.d.ts +4 -1
  441. package/dist/types/src/calendar/types.d.ts +50 -14
  442. package/dist/types/src/calendar/useCalendarState.d.ts +20 -6
  443. package/dist/types/src/calendar/useRangeCalendarState.d.ts +14 -5
  444. package/dist/types/src/calendar/utils.d.ts +1 -0
  445. package/dist/types/src/checkbox/useCheckboxGroupState.d.ts +1 -0
  446. package/dist/types/src/collections/useCollection.d.ts +1 -1
  447. package/dist/types/src/color/useColorAreaState.d.ts +21 -8
  448. package/dist/types/src/color/useColorFieldState.d.ts +2 -3
  449. package/dist/types/src/color/useColorSliderState.d.ts +4 -1
  450. package/dist/types/src/color/useColorWheelState.d.ts +5 -1
  451. package/dist/types/src/combobox/useComboBoxState.d.ts +19 -6
  452. package/dist/types/src/data/useAsyncList.d.ts +2 -2
  453. package/dist/types/src/data/useListData.d.ts +13 -1
  454. package/dist/types/src/data/useTreeData.d.ts +11 -0
  455. package/dist/types/src/datepicker/IncompleteDate.d.ts +11 -5
  456. package/dist/types/src/datepicker/types.d.ts +37 -11
  457. package/dist/types/src/datepicker/useDateFieldState.d.ts +13 -4
  458. package/dist/types/src/datepicker/useDatePickerState.d.ts +10 -4
  459. package/dist/types/src/datepicker/useDateRangePickerState.d.ts +12 -3
  460. package/dist/types/src/dnd/useDraggableCollectionState.d.ts +4 -1
  461. package/dist/types/src/form/useFormValidationState.d.ts +4 -1
  462. package/dist/types/src/grid/GridCollection.d.ts +2 -1
  463. package/dist/types/src/grid/useGridState.d.ts +7 -3
  464. package/dist/types/src/layout/GridLayout.d.ts +18 -2
  465. package/dist/types/src/layout/ListLayout.d.ts +34 -12
  466. package/dist/types/src/layout/TableLayout.d.ts +11 -4
  467. package/dist/types/src/layout/WaterfallLayout.d.ts +9 -2
  468. package/dist/types/src/list/useListState.d.ts +2 -2
  469. package/dist/types/src/menu/useMenuTriggerState.d.ts +3 -1
  470. package/dist/types/src/menu/useSubmenuTriggerState.d.ts +2 -2
  471. package/dist/types/src/numberfield/useNumberFieldState.d.ts +15 -11
  472. package/dist/types/src/radio/useRadioGroupState.d.ts +4 -1
  473. package/dist/types/src/select/useSelectState.d.ts +13 -2
  474. package/dist/types/src/selection/types.d.ts +4 -1
  475. package/dist/types/src/selection/useMultipleSelectionState.d.ts +2 -0
  476. package/dist/types/src/slider/useSliderState.d.ts +22 -2
  477. package/dist/types/src/table/Column.d.ts +4 -1
  478. package/dist/types/src/table/Row.d.ts +5 -3
  479. package/dist/types/src/table/TableBody.d.ts +3 -2
  480. package/dist/types/src/table/TableCollection.d.ts +4 -1
  481. package/dist/types/src/table/TableColumnLayout.d.ts +4 -1
  482. package/dist/types/src/table/TableHeader.d.ts +7 -3
  483. package/dist/types/src/table/TableUtils.d.ts +19 -16
  484. package/dist/types/src/table/useTableColumnResizeState.d.ts +5 -3
  485. package/dist/types/src/table/useTableState.d.ts +15 -6
  486. package/dist/types/src/table/useTreeGridState.d.ts +3 -2
  487. package/dist/types/src/toggle/useToggleGroupState.d.ts +1 -0
  488. package/dist/types/src/toggle/useToggleState.d.ts +2 -1
  489. package/dist/types/src/tooltip/useTooltipTriggerState.d.ts +8 -2
  490. package/dist/types/src/tree/useTreeState.d.ts +1 -1
  491. package/dist/types/src/utils/number.d.ts +2 -1
  492. package/dist/types/src/virtualizer/Layout.d.ts +5 -2
  493. package/dist/types/src/virtualizer/LayoutInfo.d.ts +10 -3
  494. package/dist/types/src/virtualizer/Rect.d.ts +4 -0
  495. package/dist/types/src/virtualizer/Virtualizer.d.ts +5 -4
  496. package/package.json +8 -7
@@ -2,6 +2,7 @@ import { LabelableProps, Orientation, RangeInputBase, ValueBase } from '@react-t
2
2
  export interface SliderProps<T = number | number[]> extends RangeInputBase<number>, ValueBase<T>, LabelableProps {
3
3
  /**
4
4
  * The orientation of the Slider.
5
+ *
5
6
  * @default 'horizontal'
6
7
  */
7
8
  orientation?: Orientation;
@@ -11,16 +12,19 @@ export interface SliderProps<T = number | number[]> extends RangeInputBase<numbe
11
12
  onChangeEnd?: (value: T) => void;
12
13
  /**
13
14
  * The slider's minimum value.
15
+ *
14
16
  * @default 0
15
17
  */
16
18
  minValue?: number;
17
19
  /**
18
20
  * The slider's maximum value.
21
+ *
19
22
  * @default 100
20
23
  */
21
24
  maxValue?: number;
22
25
  /**
23
26
  * The slider's step value.
27
+ *
24
28
  * @default 1
25
29
  */
26
30
  step?: number;
@@ -36,29 +40,34 @@ export interface SliderState {
36
40
  readonly defaultValues: number[];
37
41
  /**
38
42
  * Get the value for the specified thumb.
43
+ *
39
44
  * @param index
40
45
  */
41
46
  getThumbValue(index: number): number;
42
47
  /**
43
48
  * Sets the value for the specified thumb.
44
49
  * The actual value set will be clamped and rounded according to min/max/step.
50
+ *
45
51
  * @param index
46
52
  * @param value
47
53
  */
48
54
  setThumbValue(index: number, value: number): void;
49
55
  /**
50
56
  * Sets value for the specified thumb by percent offset (between 0 and 1).
57
+ *
51
58
  * @param index
52
59
  * @param percent
53
60
  */
54
61
  setThumbPercent(index: number, percent: number): void;
55
62
  /**
56
63
  * Whether the specific thumb is being dragged.
64
+ *
57
65
  * @param index
58
66
  */
59
67
  isThumbDragging(index: number): boolean;
60
68
  /**
61
69
  * Set is dragging on the specified thumb.
70
+ *
62
71
  * @param index
63
72
  * @param dragging
64
73
  */
@@ -70,51 +79,61 @@ export interface SliderState {
70
79
  /**
71
80
  * Set focused true on specified thumb. This will remove focus from
72
81
  * any thumb that had it before.
82
+ *
73
83
  * @param index
74
84
  */
75
85
  setFocusedThumb(index: number | undefined): void;
76
86
  /**
77
87
  * Returns the specified thumb's value as a percentage from 0 to 1.
88
+ *
78
89
  * @param index
79
90
  */
80
91
  getThumbPercent(index: number): number;
81
92
  /**
82
93
  * Returns the value as a percent between the min and max of the slider.
94
+ *
83
95
  * @param index
84
96
  */
85
97
  getValuePercent(value: number): number;
86
98
  /**
87
99
  * Returns the string label for the specified thumb's value, per props.formatOptions.
100
+ *
88
101
  * @param index
89
102
  */
90
103
  getThumbValueLabel(index: number): string;
91
104
  /**
92
105
  * Returns the string label for the value, per props.formatOptions.
93
- * @param index
106
+ *
107
+ * @param value
94
108
  */
95
- getFormattedValue(value: number): string;
109
+ getFormattedValue(value?: number | number[]): string;
96
110
  /**
97
111
  * Returns the min allowed value for the specified thumb.
112
+ *
98
113
  * @param index
99
114
  */
100
115
  getThumbMinValue(index: number): number;
101
116
  /**
102
117
  * Returns the max allowed value for the specified thumb.
118
+ *
103
119
  * @param index
104
120
  */
105
121
  getThumbMaxValue(index: number): number;
106
122
  /**
107
123
  * Converts a percent along track (between 0 and 1) to the corresponding value.
124
+ *
108
125
  * @param percent
109
126
  */
110
127
  getPercentValue(percent: number): number;
111
128
  /**
112
129
  * Returns if the specified thumb is editable.
130
+ *
113
131
  * @param index
114
132
  */
115
133
  isThumbEditable(index: number): boolean;
116
134
  /**
117
135
  * Set the specified thumb's editable state.
136
+ *
118
137
  * @param index
119
138
  * @param editable
120
139
  */
@@ -147,6 +166,7 @@ export interface SliderStateOptions<T> extends SliderProps<T> {
147
166
  * Provides state management for a slider component. Stores values for all thumbs,
148
167
  * formats values for localization, and provides methods to update the position
149
168
  * of any thumbs.
169
+ *
150
170
  * @param props
151
171
  */
152
172
  export declare function useSliderState<T extends number | number[]>(props: SliderStateOptions<T>): SliderState;
@@ -33,7 +33,10 @@ export interface ColumnProps<T> {
33
33
  allowsResizing?: boolean;
34
34
  /** Whether the column allows sorting. */
35
35
  allowsSorting?: boolean;
36
- /** Whether a column is a [row header](https://www.w3.org/TR/wai-aria-1.1/#rowheader) and should be announced by assistive technology during row navigation. */
36
+ /**
37
+ * Whether a column is a [row header](https://www.w3.org/TR/wai-aria-1.1/#rowheader) and should be
38
+ * announced by assistive technology during row navigation.
39
+ */
37
40
  isRowHeader?: boolean;
38
41
  /** A string representation of the column's contents, used for accessibility announcements. */
39
42
  textValue?: string;
@@ -6,10 +6,12 @@ import { JSX, ReactElement } from 'react';
6
6
  export type RowElement<T> = ReactElement<RowProps<T>>;
7
7
  export interface RowProps<T> extends LinkDOMProps {
8
8
  /**
9
- * A list of child item objects used when dynamically rendering row children. Requires the feature flag to be
10
- * enabled along with UNSTABLE_allowsExpandableRows, see https://react-spectrum.adobe.com/react-spectrum/TableView.html#expandable-rows.
11
- * @version alpha
9
+ * A list of child item objects used when dynamically rendering row children. Requires the feature
10
+ * flag to be enabled along with UNSTABLE_allowsExpandableRows, see
11
+ * https://react-spectrum.adobe.com/react-spectrum/TableView.html#expandable-rows.
12
+ *
12
13
  * @private
14
+ * @version alpha
13
15
  */
14
16
  UNSTABLE_childItems?: Iterable<T>;
15
17
  /** Rendered contents of the row or row child items. */
@@ -15,8 +15,9 @@ declare namespace TableBody {
15
15
  var getCollectionNode: <T>(props: TableBodyProps<T>) => Generator<PartialNode<T>, any, any>;
16
16
  }
17
17
  /**
18
- * A TableBody is a container for the Row elements of a Table. Rows can be statically defined
19
- * as children, or generated dynamically using a function based on the data passed to the `items` prop.
18
+ * A TableBody is a container for the Row elements of a Table. Rows can be statically defined as
19
+ * children, or generated dynamically using a function based on the data passed to the `items`
20
+ * prop.
20
21
  */
21
22
  declare let _TableBody: <T>(props: TableBodyProps<T>) => JSX.Element;
22
23
  export { _TableBody as TableBody };
@@ -5,7 +5,10 @@ export interface ITableCollection<T> extends IGridCollection<T> {
5
5
  headerRows: GridNode<T>[];
6
6
  /** A list of column nodes in the table. */
7
7
  columns: GridNode<T>[];
8
- /** A set of column keys that serve as the [row header](https://www.w3.org/TR/wai-aria-1.1/#rowheader). */
8
+ /**
9
+ * A set of column keys that serve as the [row
10
+ * header](https://www.w3.org/TR/wai-aria-1.1/#rowheader).
11
+ */
9
12
  rowHeaderColumnKeys: Set<Key>;
10
13
  /** The node that makes up the header of the table. */
11
14
  head?: GridNode<T>;
@@ -13,7 +13,10 @@ export declare class TableColumnLayout<T> {
13
13
  columnMinWidths: Map<Key, number>;
14
14
  columnMaxWidths: Map<Key, number>;
15
15
  constructor(options: TableColumnLayoutOptions<T>);
16
- /** Takes an array of columns and splits it into 2 maps of columns with controlled and columns with uncontrolled widths. */
16
+ /**
17
+ * Takes an array of columns and splits it into 2 maps of columns with controlled and columns with
18
+ * uncontrolled widths.
19
+ */
17
20
  splitColumnsIntoControlledAndUncontrolled(columns: Array<GridNode<T>>): [Map<Key, GridNode<T>>, Map<Key, GridNode<T>>];
18
21
  /** Takes uncontrolled and controlled widths and joins them into a single Map. */
19
22
  recombineColumns(columns: Array<GridNode<T>>, uncontrolledWidths: Map<Key, ColumnSize>, uncontrolledColumns: Map<Key, GridNode<T>>, controlledColumns: Map<Key, GridNode<T>>): Map<Key, ColumnSize>;
@@ -5,7 +5,10 @@ import { JSX, ReactElement } from 'react';
5
5
  export interface TableHeaderProps<T> {
6
6
  /** A list of table columns. */
7
7
  columns?: readonly T[];
8
- /** A list of `Column(s)` or a function. If the latter, a list of columns must be provided using the `columns` prop. */
8
+ /**
9
+ * A list of `Column(s)` or a function. If the latter, a list of columns must be provided using
10
+ * the `columns` prop.
11
+ */
9
12
  children: ColumnElement<T> | ColumnElement<T>[] | ColumnRenderer<T>;
10
13
  }
11
14
  declare function TableHeader<T>(props: TableHeaderProps<T>): ReactElement | null;
@@ -13,8 +16,9 @@ declare namespace TableHeader {
13
16
  var getCollectionNode: <T>(props: TableHeaderProps<T>, context: CollectionBuilderContext<T>) => Generator<PartialNode<T>, void, any>;
14
17
  }
15
18
  /**
16
- * A TableHeader is a container for the Column elements in a Table. Columns can be statically defined
17
- * as children, or generated dynamically using a function based on the data passed to the `columns` prop.
19
+ * A TableHeader is a container for the Column elements in a Table. Columns can be statically
20
+ * defined as children, or generated dynamically using a function based on the data passed to the
21
+ * `columns` prop.
18
22
  */
19
23
  declare let _TableHeader: <T>(props: TableHeaderProps<T>) => JSX.Element;
20
24
  export { _TableHeader as TableHeader };
@@ -14,27 +14,30 @@ export interface IColumn {
14
14
  }
15
15
  /**
16
16
  * Implements the flex algorithm described in https://www.w3.org/TR/css-flexbox-1/#layout-algorithm
17
- * It makes a few constraint/assumptions:
18
- * 1. All basis values are 0 unless it is a static width, then the basis is the static width
19
- * 2. All flex grow and shrink values are equal to the FR specified on the column, grow and shrink for the same column are equal
20
- * 3. We only have one row
21
- * An example of the setup can be seen here https://jsfiddle.net/snowystinger/wv0ymjaf/61/ where I let the browser figure out the
22
- * flex of the columns.
23
- * Note: We differ in one key aspect, all of our column widths must be whole numbers, so we avoid browser
24
- * sub pixel rounding errors. To do this, we use a cascading rounding algorithm to ensure that the sum of the widths is maintained
25
- * while distributing the rounding remainder across the columns.
17
+ * It makes a few constraint/assumptions: 1. All basis values are 0 unless it is a static width,
18
+ * then the basis is the static width 2. All flex grow and shrink values are equal to the FR
19
+ * specified on the column, grow and shrink for the same column are equal 3. We only have one row An
20
+ * example of the setup can be seen here https://jsfiddle.net/snowystinger/wv0ymjaf/61/ where I let
21
+ * the browser figure out the flex of the columns. Note: We differ in one key aspect, all of our
22
+ * column widths must be whole numbers, so we avoid browser sub pixel rounding errors. To do this,
23
+ * we use a cascading rounding algorithm to ensure that the sum of the widths is maintained while
24
+ * distributing the rounding remainder across the columns.
26
25
  *
27
- * As noted in the chrome source code, this algorithm is very accurate, but has the potential to be quadratic.
28
- * They have deemed this to be acceptable because the number of elements is usually small and the flex factors
29
- * are usually not high variance. I believe we can make the same assumptions. Particularly once resizing is
30
- * started, it will convert all columns to the left to static widths, so it will cut down on the number of FR columns.
26
+ * As noted in the chrome source code, this algorithm is very accurate, but has the potential to be
27
+ * quadratic. They have deemed this to be acceptable because the number of elements is usually small
28
+ * and the flex factors are usually not high variance. I believe we can make the same assumptions.
29
+ * Particularly once resizing is started, it will convert all columns to the left to static widths,
30
+ * so it will cut down on the number of FR columns.
31
+ *
32
+ * There are likely faster ways to do this, I've chosen to stick to the spec as closely as possible
33
+ * for readability, accuracy, and for the note that this behaving quadratically is unlikely to be a
34
+ * problem.
31
35
  *
32
- * There are likely faster ways to do this, I've chosen to stick to the spec as closely as possible for readability, accuracy, and for the
33
- * note that this behaving quadratically is unlikely to be a problem.
34
36
  * @param availableWidth - The visible width of the table.
35
37
  * @param columns - The table defined columns.
36
38
  * @param changedColumns - Any columns we want to override, for example, during resizing.
37
39
  * @param getDefaultWidth - A function that returns the default width of a column by its index.
38
- * @param getDefaultMinWidth - A function that returns the default min width of a column by its index.
40
+ * @param getDefaultMinWidth - A function that returns the default min width of a column by its
41
+ * index.
39
42
  */
40
43
  export declare function calculateColumnSizes(availableWidth: number, columns: IColumn[], changedColumns: Map<Key, ColumnSize>, getDefaultWidth?: (index: number) => ColumnSize | null | undefined, getDefaultMinWidth?: (index: number) => ColumnSize | null | undefined): number[];
@@ -37,9 +37,11 @@ export interface TableColumnResizeState<T> {
37
37
  columnWidths: Map<Key, number>;
38
38
  }
39
39
  /**
40
- * Provides column width state management for a table component with column resizing support. Handles building
41
- * a map of column widths calculated from the table's width and any provided column width information from the collection.
42
- * In addition, it tracks the currently resizing column and provides callbacks for updating the widths upon resize operations.
40
+ * Provides column width state management for a table component with column resizing support.
41
+ * Handles building a map of column widths calculated from the table's width and any provided column
42
+ * width information from the collection. In addition, it tracks the currently resizing column and
43
+ * provides callbacks for updating the widths upon resize operations.
44
+ *
43
45
  * @param props - Props for the table.
44
46
  * @param state - State for the table, as returned by `useTableState`.
45
47
  */
@@ -17,6 +17,7 @@ export interface TableProps<T> extends MultipleSelection, Sortable, Expandable {
17
17
  * Most experiences should not modify this option as it eliminates a keyboard user's ability to
18
18
  * easily clear selection. Only use if the escape key is being handled externally or should not
19
19
  * trigger selection clearing contextually.
20
+ *
20
21
  * @default 'clearSelection'
21
22
  */
22
23
  escapeKeyBehavior?: 'clearSelection' | 'none';
@@ -34,9 +35,15 @@ export interface TableState<T> extends GridState<T, ITableCollection<T>> {
34
35
  sortDescriptor: SortDescriptor | null;
35
36
  /** Calls the provided onSortChange handler with the provided column key and sort direction. */
36
37
  sort(columnKey: Key, direction?: 'ascending' | 'descending'): void;
37
- /** Whether keyboard navigation is disabled, such as when the arrow keys should be handled by a component within a cell. */
38
+ /**
39
+ * Whether keyboard navigation is disabled, such as when the arrow keys should be handled by a
40
+ * component within a cell.
41
+ */
38
42
  isKeyboardNavigationDisabled: boolean;
39
- /** Set whether keyboard navigation is disabled, such as when the arrow keys should be handled by a component within a cell. */
43
+ /**
44
+ * Set whether keyboard navigation is disabled, such as when the arrow keys should be handled by a
45
+ * component within a cell.
46
+ */
40
47
  setKeyboardNavigationDisabled: (val: boolean) => void;
41
48
  /** A set of keys for items that are expanded. */
42
49
  expandedKeys: Set<Key>;
@@ -58,18 +65,20 @@ export interface TableStateProps<T> extends MultipleSelectionStateProps, Expanda
58
65
  collection?: ITableCollection<T>;
59
66
  /** Whether the row selection checkboxes should be displayed. */
60
67
  showSelectionCheckboxes?: boolean;
61
- /** Whether the row drag button should be displayed.
68
+ /**
69
+ * Whether the row drag button should be displayed.
70
+ *
62
71
  * @private
63
72
  */
64
73
  showDragButtons?: boolean;
65
- /** @private - do not use unless you know what you're doing. */
74
+ /** @private - Do not use unless you know what you're doing. */
66
75
  UNSAFE_selectionState?: MultipleSelectionState;
67
76
  /** The id of the column that displays hierarchical data. */
68
77
  treeColumn?: Key;
69
78
  }
70
79
  /**
71
- * Provides state management for a table component. Handles building a collection
72
- * of columns and rows from props. In addition, it tracks row selection and manages sort order changes.
80
+ * Provides state management for a table component. Handles building a collection of columns and
81
+ * rows from props. In addition, it tracks row selection and manages sort order changes.
73
82
  */
74
83
  export declare function useTableState<T extends object>(props: TableStateProps<T>): TableState<T>;
75
84
  /**
@@ -20,7 +20,8 @@ export interface TreeGridStateProps<T> extends Omit<TableStateProps<T>, 'collect
20
20
  UNSTABLE_onExpandedChange?: (keys: Set<Key>) => any;
21
21
  }
22
22
  /**
23
- * Provides state management for a tree grid component. Handles building a collection
24
- * of columns and rows from props. In addition, it tracks and manages expanded rows, row selection, and sort order changes.
23
+ * Provides state management for a tree grid component. Handles building a collection of columns and
24
+ * rows from props. In addition, it tracks and manages expanded rows, row selection, and sort order
25
+ * changes.
25
26
  */
26
27
  export declare function UNSTABLE_useTreeGridState<T extends object>(props: TreeGridStateProps<T>): TreeGridState<T>;
@@ -2,6 +2,7 @@ import { Key } from '@react-types/shared';
2
2
  export interface ToggleGroupProps {
3
3
  /**
4
4
  * Whether single or multiple selection is enabled.
5
+ *
5
6
  * @default 'single'
6
7
  */
7
8
  selectionMode?: 'single' | 'multiple';
@@ -20,7 +20,8 @@ export interface ToggleProps extends ToggleStateOptions, Validation<boolean>, Fo
20
20
  */
21
21
  children?: ReactNode;
22
22
  /**
23
- * The value of the input element, used when submitting an HTML form. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#htmlattrdefvalue).
23
+ * The value of the input element, used when submitting an HTML form. See
24
+ * [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#htmlattrdefvalue).
24
25
  */
25
26
  value?: string;
26
27
  }
@@ -5,22 +5,28 @@ export interface TooltipTriggerProps extends OverlayTriggerProps {
5
5
  */
6
6
  isDisabled?: boolean;
7
7
  /**
8
- * The delay time for the tooltip to show up. [See guidelines](https://spectrum.adobe.com/page/tooltip/#Immediate-or-delayed-appearance).
8
+ * The delay time for the tooltip to show up. [See
9
+ * guidelines](https://spectrum.adobe.com/page/tooltip/#Immediate-or-delayed-appearance).
10
+ *
9
11
  * @default 1500
10
12
  */
11
13
  delay?: number;
12
14
  /**
13
- * The delay time for the tooltip to close. [See guidelines](https://spectrum.adobe.com/page/tooltip/#Warmup-and-cooldown).
15
+ * The delay time for the tooltip to close. [See
16
+ * guidelines](https://spectrum.adobe.com/page/tooltip/#Warmup-and-cooldown).
17
+ *
14
18
  * @default 500
15
19
  */
16
20
  closeDelay?: number;
17
21
  /**
18
22
  * By default, opens for both focus and hover. Can be made to open only for focus.
23
+ *
19
24
  * @default 'hover'
20
25
  */
21
26
  trigger?: 'hover' | 'focus';
22
27
  /**
23
28
  * Whether the tooltip should close when the trigger is pressed.
29
+ *
24
30
  * @default true
25
31
  */
26
32
  shouldCloseOnPress?: boolean;
@@ -22,4 +22,4 @@ export interface TreeState<T> {
22
22
  * Provides state management for tree-like components. Handles building a collection
23
23
  * of items from props, item expanded state, and manages multiple selection state.
24
24
  */
25
- export declare function useTreeState<T extends object>(props: TreeProps<T>): TreeState<T>;
25
+ export declare function useTreeState<T>(props: TreeProps<T>): TreeState<T>;
@@ -1,5 +1,6 @@
1
1
  /**
2
- * Takes a value and forces it to the closest min/max if it's outside. Also forces it to the closest valid step.
2
+ * Takes a value and forces it to the closest min/max if it's outside. Also forces it to the closest
3
+ * valid step.
3
4
  */
4
5
  export declare function clamp(value: number, min?: number, max?: number): number;
5
6
  export declare function roundToStepPrecision(value: number, step: number): number;
@@ -11,8 +11,9 @@ import { Virtualizer } from './Virtualizer';
11
11
  * such as its position and size. The Virtualizer is then responsible for creating the actual
12
12
  * views as needed, based on this layout information.
13
13
  *
14
- * Every layout extends from the Layout abstract base class. Layouts must implement the `getVisibleLayoutInfos`,
15
- * `getLayoutInfo`, and `getContentSize` methods. All other methods can be optionally overridden to implement custom behavior.
14
+ * Every layout extends from the Layout abstract base class. Layouts must implement the
15
+ * `getVisibleLayoutInfos`, `getLayoutInfo`, and `getContentSize` methods. All other methods can be
16
+ * optionally overridden to implement custom behavior.
16
17
  */
17
18
  export declare abstract class Layout<T extends object = Node<any>, O = any> implements LayoutDelegate {
18
19
  /** The Virtualizer the layout is currently attached to. */
@@ -20,12 +21,14 @@ export declare abstract class Layout<T extends object = Node<any>, O = any> impl
20
21
  /**
21
22
  * Returns an array of `LayoutInfo` objects which are inside the given rectangle.
22
23
  * Should be implemented by subclasses.
24
+ *
23
25
  * @param rect The rectangle that should contain the returned LayoutInfo objects.
24
26
  */
25
27
  abstract getVisibleLayoutInfos(rect: Rect): LayoutInfo[];
26
28
  /**
27
29
  * Returns a `LayoutInfo` for the given key.
28
30
  * Should be implemented by subclasses.
31
+ *
29
32
  * @param key The key of the LayoutInfo to retrieve.
30
33
  */
31
34
  abstract getLayoutInfo(key: Key): LayoutInfo | null;
@@ -8,7 +8,8 @@ import { Rect } from './Rect';
8
8
  */
9
9
  export declare class LayoutInfo {
10
10
  /**
11
- * The type of element represented by this LayoutInfo. Should match the `type` of the corresponding collection node.
11
+ * The type of element represented by this LayoutInfo. Should match the `type` of the
12
+ * corresponding collection node.
12
13
  */
13
14
  type: string;
14
15
  /**
@@ -31,16 +32,19 @@ export declare class LayoutInfo {
31
32
  * Whether the size is estimated. `false` by default.
32
33
  * Items with estimated sizes will be measured the first time they are added to the DOM.
33
34
  * The estimated size is used to calculate the size and position of the scrollbar.
35
+ *
34
36
  * @default false
35
37
  */
36
38
  estimatedSize: boolean;
37
39
  /**
38
40
  * Whether the layout info sticks to the viewport when scrolling.
41
+ *
39
42
  * @default false
40
43
  */
41
44
  isSticky: boolean;
42
45
  /**
43
46
  * The element's opacity.
47
+ *
44
48
  * @default 1
45
49
  */
46
50
  opacity: number;
@@ -54,12 +58,15 @@ export declare class LayoutInfo {
54
58
  zIndex: number;
55
59
  /**
56
60
  * Whether the element allows its contents to overflow its container.
61
+ *
57
62
  * @default false
58
63
  */
59
64
  allowOverflow: boolean;
60
65
  /**
61
- * @param type The type of element represented by this LayoutInfo. Should match the `type` of the corresponding collection node.
62
- * @param key A unique key for this LayoutInfo. Should match the `key` of the corresponding collection node.
66
+ * @param type The type of element represented by this LayoutInfo. Should match the `type` of the
67
+ * corresponding collection node.
68
+ * @param key A unique key for this LayoutInfo. Should match the `key` of the corresponding
69
+ * collection node.
63
70
  * @param rect The rectangle describing the size and position of this element.
64
71
  */
65
72
  constructor(type: string, key: Key, rect: Rect);
@@ -44,22 +44,26 @@ export declare class Rect {
44
44
  get bottomRight(): Point;
45
45
  /**
46
46
  * Returns whether this rectangle intersects another rectangle.
47
+ *
47
48
  * @param rect - The rectangle to check.
48
49
  */
49
50
  intersects(rect: Rect): boolean;
50
51
  /**
51
52
  * Returns whether this rectangle fully contains another rectangle.
53
+ *
52
54
  * @param rect - The rectangle to check.
53
55
  */
54
56
  containsRect(rect: Rect): boolean;
55
57
  /**
56
58
  * Returns whether the rectangle contains the given point.
59
+ *
57
60
  * @param point - The point to check.
58
61
  */
59
62
  containsPoint(point: Point): boolean;
60
63
  /**
61
64
  * Returns the first corner of this rectangle (from top to bottom, left to right)
62
65
  * that is contained in the given rectangle, or null of the rectangles do not intersect.
66
+ *
63
67
  * @param rect - The rectangle to check.
64
68
  */
65
69
  getCornerInRect(rect: Rect): RectCorner | null;
@@ -22,10 +22,11 @@ interface VirtualizerOptions<T extends object, V> {
22
22
  * a stack, a grid, a circle, or any other layout you can think of. The layout can be changed
23
23
  * dynamically at runtime as well.
24
24
  *
25
- * Layouts produce information on what views should appear in the virtualizer, but do not create
26
- * the views themselves directly. It is the responsibility of the `VirtualizerDelegate` object
27
- * to render elements for each layout info. The virtualizer manages a set of `ReusableView` objects,
28
- * which are reused as the user scrolls by swapping their content with cached elements returned by the delegate.
25
+ * Layouts produce information on what views should appear in the virtualizer, but do not create the
26
+ * views themselves directly. It is the responsibility of the `VirtualizerDelegate` object to render
27
+ * elements for each layout info. The virtualizer manages a set of `ReusableView` objects, which are
28
+ * reused as the user scrolls by swapping their content with cached elements returned by the
29
+ * delegate.
29
30
  */
30
31
  export declare class Virtualizer<T extends object, V> {
31
32
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-stately",
3
- "version": "3.46.0",
3
+ "version": "3.47.0",
4
4
  "description": "Spectrum UI components in React",
5
5
  "license": "Apache-2.0",
6
6
  "main": "./dist/exports/index.cjs",
@@ -37,10 +37,10 @@
37
37
  "url": "https://github.com/adobe/react-spectrum"
38
38
  },
39
39
  "dependencies": {
40
- "@internationalized/date": "^3.12.1",
41
- "@internationalized/number": "^3.6.6",
42
- "@internationalized/string": "^3.2.8",
43
- "@react-types/shared": "^3.34.0",
40
+ "@internationalized/date": "^3.12.2",
41
+ "@internationalized/number": "^3.6.7",
42
+ "@internationalized/string": "^3.2.9",
43
+ "@react-types/shared": "^3.35.0",
44
44
  "@swc/helpers": "^0.5.0",
45
45
  "use-sync-external-store": "^1.6.0"
46
46
  },
@@ -49,7 +49,8 @@
49
49
  },
50
50
  "devDependencies": {
51
51
  "@babel/cli": "^7.24.1",
52
- "@babel/core": "^7.24.3"
52
+ "@babel/core": "^7.24.3",
53
+ "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0-rc.1"
53
54
  },
54
55
  "publishConfig": {
55
56
  "access": "public"
@@ -93,5 +94,5 @@
93
94
  }
94
95
  }
95
96
  },
96
- "gitHead": "a6999bdf494a2e9c0381a5881908328bdd22ddae"
97
+ "gitHead": "3577a20859b9585a000010c720f6ee39c1c588cc"
97
98
  }