@workday/canvas-kit-preview-react 16.2.0-0634-next.0 → 16.2.0-0640-next.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 (430) hide show
  1. package/dist/commonjs/color-picker/index.d.ts.map +1 -0
  2. package/dist/commonjs/color-picker/lib/ColorPicker.d.ts.map +1 -0
  3. package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/ColorPicker.js +1 -1
  4. package/dist/commonjs/color-picker/lib/defaultColorSet.d.ts.map +1 -0
  5. package/dist/commonjs/color-picker/lib/parts/ColorReset.d.ts.map +1 -0
  6. package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/parts/ColorReset.js +1 -1
  7. package/dist/commonjs/color-picker/lib/parts/SwatchBook.d.ts.map +1 -0
  8. package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/parts/SwatchBook.js +1 -1
  9. package/dist/commonjs/divider/index.d.ts.map +1 -0
  10. package/dist/commonjs/divider/lib/Divider.d.ts.map +1 -0
  11. package/dist/commonjs/{preview-react/divider → divider}/lib/Divider.js +3 -3
  12. package/dist/commonjs/index.d.ts.map +1 -0
  13. package/dist/commonjs/loading-sparkles/index.d.ts.map +1 -0
  14. package/dist/commonjs/loading-sparkles/lib/LoadingSparkles.d.ts.map +1 -0
  15. package/dist/commonjs/{preview-react/loading-sparkles → loading-sparkles}/lib/LoadingSparkles.js +2 -2
  16. package/dist/commonjs/loading-sparkles/lib/sparkleIcon.d.ts.map +1 -0
  17. package/dist/commonjs/multi-select/index.d.ts.map +1 -0
  18. package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelect.d.ts.map +1 -1
  19. package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectCard.d.ts.map +1 -1
  20. package/dist/commonjs/multi-select/lib/MultiSelectInput.d.ts.map +1 -0
  21. package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectInput.js +3 -3
  22. package/dist/{es6/preview-react → commonjs}/multi-select/lib/MultiSelectItem.d.ts.map +1 -1
  23. package/dist/{es6/preview-react → commonjs}/multi-select/lib/MultiSelectedItem.d.ts.map +1 -1
  24. package/dist/commonjs/multi-select/lib/MultiSelectedList.d.ts.map +1 -0
  25. package/dist/{es6/preview-react → commonjs}/multi-select/lib/useMultiSelectItemRemove.d.ts.map +1 -1
  26. package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/useMultiSelectModel.d.ts.map +1 -1
  27. package/dist/commonjs/radio/index.d.ts.map +1 -0
  28. package/dist/commonjs/radio/lib/RadioButton.d.ts.map +1 -0
  29. package/dist/commonjs/radio/lib/RadioGroup.d.ts.map +1 -0
  30. package/dist/commonjs/{preview-react/radio → radio}/lib/RadioGroup.js +3 -3
  31. package/dist/commonjs/radio/lib/RadioInput.d.ts.map +1 -0
  32. package/dist/commonjs/radio/lib/RadioLabel.d.ts.map +1 -0
  33. package/dist/commonjs/{preview-react/radio → radio}/lib/RadioLabel.js +1 -1
  34. package/dist/commonjs/radio/lib/RadioText.d.ts.map +1 -0
  35. package/dist/commonjs/{preview-react/radio → radio}/lib/RadioText.js +3 -3
  36. package/dist/commonjs/radio/lib/StyledRadioButton.d.ts.map +1 -0
  37. package/dist/commonjs/{preview-react/radio → radio}/lib/StyledRadioButton.js +5 -5
  38. package/dist/commonjs/radio/lib/hooks/useRadioModel.d.ts.map +1 -0
  39. package/dist/commonjs/side-panel/index.d.ts.map +1 -0
  40. package/dist/commonjs/side-panel/lib/SidePanel.d.ts.map +1 -0
  41. package/dist/commonjs/{preview-react/side-panel → side-panel}/lib/SidePanel.js +7 -7
  42. package/dist/commonjs/side-panel/lib/SidePanelToggleButton.d.ts.map +1 -0
  43. package/dist/commonjs/{preview-react/side-panel → side-panel}/lib/SidePanelToggleButton.js +11 -11
  44. package/dist/commonjs/side-panel/lib/hooks.d.ts.map +1 -0
  45. package/dist/commonjs/status-indicator/index.d.ts.map +1 -0
  46. package/dist/commonjs/status-indicator/lib/StatusIndicator.d.ts.map +1 -0
  47. package/dist/commonjs/{preview-react/status-indicator → status-indicator}/lib/StatusIndicator.js +14 -14
  48. package/dist/commonjs/status-indicator/lib/StatusIndicatorIcon.d.ts.map +1 -0
  49. package/dist/commonjs/status-indicator/lib/StatusIndicatorLabel.d.ts.map +1 -0
  50. package/dist/commonjs/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorLabel.js +1 -1
  51. package/dist/commonjs/switch/index.d.ts.map +1 -0
  52. package/dist/commonjs/switch/lib/Switch.d.ts.map +1 -0
  53. package/dist/commonjs/switch/lib/SwitchBackground.d.ts.map +1 -0
  54. package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchBackground.js +1 -1
  55. package/dist/commonjs/switch/lib/SwitchCircle.d.ts.map +1 -0
  56. package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchCircle.js +2 -2
  57. package/dist/commonjs/switch/lib/SwitchContainer.d.ts.map +1 -0
  58. package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchContainer.js +1 -1
  59. package/dist/commonjs/switch/lib/SwitchIcon.d.ts.map +1 -0
  60. package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchIcon.js +2 -2
  61. package/dist/commonjs/switch/lib/SwitchInput.d.ts.map +1 -0
  62. package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchInput.js +3 -3
  63. package/dist/commonjs/tabs/index.d.ts.map +1 -0
  64. package/dist/commonjs/{preview-react/tabs → tabs}/lib/Tabs.d.ts.map +1 -1
  65. package/dist/commonjs/tabs/lib/TabsItem.d.ts.map +1 -0
  66. package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsItem.js +3 -3
  67. package/dist/commonjs/tabs/lib/TabsList.d.ts.map +1 -0
  68. package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsList.js +10 -11
  69. package/dist/commonjs/tabs/lib/TabsOverflowButton.d.ts.map +1 -0
  70. package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsOverflowButton.js +1 -1
  71. package/dist/{es6/preview-react → commonjs}/tabs/lib/TabsPanel.d.ts.map +1 -1
  72. package/dist/commonjs/tabs/lib/TabsPanels.d.ts.map +1 -0
  73. package/dist/commonjs/tabs/lib/useTabsModel.d.ts.map +1 -0
  74. package/dist/commonjs/version/index.d.ts.map +1 -0
  75. package/dist/commonjs/version/lib/version.d.ts.map +1 -0
  76. package/dist/commonjs/{preview-react/version → version}/lib/version.js +1 -1
  77. package/dist/es6/color-picker/index.d.ts.map +1 -0
  78. package/dist/es6/color-picker/lib/ColorPicker.d.ts.map +1 -0
  79. package/dist/es6/{preview-react/color-picker → color-picker}/lib/ColorPicker.js +1 -1
  80. package/dist/es6/color-picker/lib/defaultColorSet.d.ts.map +1 -0
  81. package/dist/es6/color-picker/lib/parts/ColorReset.d.ts.map +1 -0
  82. package/dist/es6/color-picker/lib/parts/ColorReset.js +16 -0
  83. package/dist/es6/color-picker/lib/parts/SwatchBook.d.ts.map +1 -0
  84. package/dist/es6/{preview-react/color-picker → color-picker}/lib/parts/SwatchBook.js +1 -1
  85. package/dist/es6/divider/index.d.ts.map +1 -0
  86. package/dist/es6/divider/lib/Divider.d.ts.map +1 -0
  87. package/dist/es6/{preview-react/divider → divider}/lib/Divider.js +3 -3
  88. package/dist/es6/index.d.ts.map +1 -0
  89. package/dist/es6/loading-sparkles/index.d.ts.map +1 -0
  90. package/dist/es6/loading-sparkles/lib/LoadingSparkles.d.ts.map +1 -0
  91. package/dist/es6/{preview-react/loading-sparkles → loading-sparkles}/lib/LoadingSparkles.js +2 -2
  92. package/dist/es6/loading-sparkles/lib/sparkleIcon.d.ts.map +1 -0
  93. package/dist/es6/multi-select/index.d.ts.map +1 -0
  94. package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelect.d.ts.map +1 -1
  95. package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectCard.d.ts.map +1 -1
  96. package/dist/es6/multi-select/lib/MultiSelectInput.d.ts.map +1 -0
  97. package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectInput.js +3 -3
  98. package/dist/{commonjs/preview-react → es6}/multi-select/lib/MultiSelectItem.d.ts.map +1 -1
  99. package/dist/{commonjs/preview-react → es6}/multi-select/lib/MultiSelectedItem.d.ts.map +1 -1
  100. package/dist/es6/multi-select/lib/MultiSelectedList.d.ts.map +1 -0
  101. package/dist/{commonjs/preview-react → es6}/multi-select/lib/useMultiSelectItemRemove.d.ts.map +1 -1
  102. package/dist/es6/{preview-react/multi-select → multi-select}/lib/useMultiSelectModel.d.ts.map +1 -1
  103. package/dist/es6/radio/index.d.ts.map +1 -0
  104. package/dist/es6/radio/lib/RadioButton.d.ts.map +1 -0
  105. package/dist/es6/radio/lib/RadioGroup.d.ts.map +1 -0
  106. package/dist/es6/{preview-react/radio → radio}/lib/RadioGroup.js +3 -3
  107. package/dist/es6/radio/lib/RadioInput.d.ts.map +1 -0
  108. package/dist/es6/radio/lib/RadioLabel.d.ts.map +1 -0
  109. package/dist/es6/{preview-react/radio → radio}/lib/RadioLabel.js +1 -1
  110. package/dist/es6/radio/lib/RadioText.d.ts.map +1 -0
  111. package/dist/es6/{preview-react/radio → radio}/lib/RadioText.js +3 -3
  112. package/dist/es6/radio/lib/StyledRadioButton.d.ts.map +1 -0
  113. package/dist/es6/{preview-react/radio → radio}/lib/StyledRadioButton.js +5 -5
  114. package/dist/es6/radio/lib/hooks/useRadioModel.d.ts.map +1 -0
  115. package/dist/es6/side-panel/index.d.ts.map +1 -0
  116. package/dist/es6/side-panel/lib/SidePanel.d.ts.map +1 -0
  117. package/dist/es6/{preview-react/side-panel → side-panel}/lib/SidePanel.js +7 -7
  118. package/dist/es6/side-panel/lib/SidePanelToggleButton.d.ts.map +1 -0
  119. package/dist/es6/{preview-react/side-panel → side-panel}/lib/SidePanelToggleButton.js +11 -11
  120. package/dist/es6/side-panel/lib/hooks.d.ts.map +1 -0
  121. package/dist/es6/status-indicator/index.d.ts.map +1 -0
  122. package/dist/es6/status-indicator/lib/StatusIndicator.d.ts.map +1 -0
  123. package/dist/es6/{preview-react/status-indicator → status-indicator}/lib/StatusIndicator.js +14 -14
  124. package/dist/es6/status-indicator/lib/StatusIndicatorIcon.d.ts.map +1 -0
  125. package/dist/es6/status-indicator/lib/StatusIndicatorLabel.d.ts.map +1 -0
  126. package/dist/es6/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorLabel.js +1 -1
  127. package/dist/es6/switch/index.d.ts.map +1 -0
  128. package/dist/es6/switch/lib/Switch.d.ts.map +1 -0
  129. package/dist/es6/switch/lib/SwitchBackground.d.ts.map +1 -0
  130. package/dist/es6/{preview-react/switch → switch}/lib/SwitchBackground.js +1 -1
  131. package/dist/es6/switch/lib/SwitchCircle.d.ts.map +1 -0
  132. package/dist/es6/{preview-react/switch → switch}/lib/SwitchCircle.js +2 -2
  133. package/dist/es6/switch/lib/SwitchContainer.d.ts.map +1 -0
  134. package/dist/es6/{preview-react/switch → switch}/lib/SwitchContainer.js +1 -1
  135. package/dist/es6/switch/lib/SwitchIcon.d.ts.map +1 -0
  136. package/dist/es6/{preview-react/switch → switch}/lib/SwitchIcon.js +2 -2
  137. package/dist/es6/switch/lib/SwitchInput.d.ts.map +1 -0
  138. package/dist/es6/{preview-react/switch → switch}/lib/SwitchInput.js +3 -3
  139. package/dist/es6/tabs/index.d.ts.map +1 -0
  140. package/dist/es6/{preview-react/tabs → tabs}/lib/Tabs.d.ts.map +1 -1
  141. package/dist/es6/tabs/lib/TabsItem.d.ts.map +1 -0
  142. package/dist/es6/{preview-react/tabs → tabs}/lib/TabsItem.js +3 -3
  143. package/dist/es6/tabs/lib/TabsList.d.ts.map +1 -0
  144. package/dist/es6/{preview-react/tabs → tabs}/lib/TabsList.js +10 -11
  145. package/dist/es6/tabs/lib/TabsOverflowButton.d.ts.map +1 -0
  146. package/dist/es6/{preview-react/tabs → tabs}/lib/TabsOverflowButton.js +1 -1
  147. package/dist/{commonjs/preview-react → es6}/tabs/lib/TabsPanel.d.ts.map +1 -1
  148. package/dist/es6/tabs/lib/TabsPanels.d.ts.map +1 -0
  149. package/dist/es6/tabs/lib/useTabsModel.d.ts.map +1 -0
  150. package/dist/es6/version/index.d.ts.map +1 -0
  151. package/dist/es6/version/lib/version.d.ts.map +1 -0
  152. package/dist/es6/version/lib/version.js +1 -0
  153. package/package.json +4 -4
  154. package/tabs/lib/TabsList.tsx +1 -1
  155. package/dist/commonjs/preview-react/color-picker/index.d.ts.map +0 -1
  156. package/dist/commonjs/preview-react/color-picker/lib/ColorPicker.d.ts.map +0 -1
  157. package/dist/commonjs/preview-react/color-picker/lib/defaultColorSet.d.ts.map +0 -1
  158. package/dist/commonjs/preview-react/color-picker/lib/parts/ColorReset.d.ts.map +0 -1
  159. package/dist/commonjs/preview-react/color-picker/lib/parts/SwatchBook.d.ts.map +0 -1
  160. package/dist/commonjs/preview-react/divider/index.d.ts.map +0 -1
  161. package/dist/commonjs/preview-react/divider/lib/Divider.d.ts.map +0 -1
  162. package/dist/commonjs/preview-react/index.d.ts.map +0 -1
  163. package/dist/commonjs/preview-react/loading-sparkles/index.d.ts.map +0 -1
  164. package/dist/commonjs/preview-react/loading-sparkles/lib/LoadingSparkles.d.ts.map +0 -1
  165. package/dist/commonjs/preview-react/loading-sparkles/lib/sparkleIcon.d.ts.map +0 -1
  166. package/dist/commonjs/preview-react/multi-select/index.d.ts.map +0 -1
  167. package/dist/commonjs/preview-react/multi-select/lib/MultiSelectInput.d.ts.map +0 -1
  168. package/dist/commonjs/preview-react/multi-select/lib/MultiSelectedList.d.ts.map +0 -1
  169. package/dist/commonjs/preview-react/radio/index.d.ts.map +0 -1
  170. package/dist/commonjs/preview-react/radio/lib/RadioButton.d.ts.map +0 -1
  171. package/dist/commonjs/preview-react/radio/lib/RadioGroup.d.ts.map +0 -1
  172. package/dist/commonjs/preview-react/radio/lib/RadioInput.d.ts.map +0 -1
  173. package/dist/commonjs/preview-react/radio/lib/RadioLabel.d.ts.map +0 -1
  174. package/dist/commonjs/preview-react/radio/lib/RadioText.d.ts.map +0 -1
  175. package/dist/commonjs/preview-react/radio/lib/StyledRadioButton.d.ts.map +0 -1
  176. package/dist/commonjs/preview-react/radio/lib/hooks/useRadioModel.d.ts.map +0 -1
  177. package/dist/commonjs/preview-react/side-panel/index.d.ts.map +0 -1
  178. package/dist/commonjs/preview-react/side-panel/lib/SidePanel.d.ts.map +0 -1
  179. package/dist/commonjs/preview-react/side-panel/lib/SidePanelToggleButton.d.ts.map +0 -1
  180. package/dist/commonjs/preview-react/side-panel/lib/hooks.d.ts.map +0 -1
  181. package/dist/commonjs/preview-react/status-indicator/index.d.ts.map +0 -1
  182. package/dist/commonjs/preview-react/status-indicator/lib/StatusIndicator.d.ts.map +0 -1
  183. package/dist/commonjs/preview-react/status-indicator/lib/StatusIndicatorIcon.d.ts.map +0 -1
  184. package/dist/commonjs/preview-react/status-indicator/lib/StatusIndicatorLabel.d.ts.map +0 -1
  185. package/dist/commonjs/preview-react/switch/index.d.ts.map +0 -1
  186. package/dist/commonjs/preview-react/switch/lib/Switch.d.ts.map +0 -1
  187. package/dist/commonjs/preview-react/switch/lib/SwitchBackground.d.ts.map +0 -1
  188. package/dist/commonjs/preview-react/switch/lib/SwitchCircle.d.ts.map +0 -1
  189. package/dist/commonjs/preview-react/switch/lib/SwitchContainer.d.ts.map +0 -1
  190. package/dist/commonjs/preview-react/switch/lib/SwitchIcon.d.ts.map +0 -1
  191. package/dist/commonjs/preview-react/switch/lib/SwitchInput.d.ts.map +0 -1
  192. package/dist/commonjs/preview-react/tabs/index.d.ts.map +0 -1
  193. package/dist/commonjs/preview-react/tabs/lib/TabsItem.d.ts.map +0 -1
  194. package/dist/commonjs/preview-react/tabs/lib/TabsList.d.ts.map +0 -1
  195. package/dist/commonjs/preview-react/tabs/lib/TabsOverflowButton.d.ts.map +0 -1
  196. package/dist/commonjs/preview-react/tabs/lib/TabsPanels.d.ts.map +0 -1
  197. package/dist/commonjs/preview-react/tabs/lib/useTabsModel.d.ts.map +0 -1
  198. package/dist/commonjs/preview-react/version/index.d.ts.map +0 -1
  199. package/dist/commonjs/preview-react/version/lib/version.d.ts.map +0 -1
  200. package/dist/commonjs/react/collection/lib/keyUtils.d.ts +0 -26
  201. package/dist/commonjs/react/collection/lib/keyUtils.d.ts.map +0 -1
  202. package/dist/commonjs/react/collection/lib/keyUtils.js +0 -84
  203. package/dist/commonjs/react/collection/lib/useBaseListModel.d.ts +0 -308
  204. package/dist/commonjs/react/collection/lib/useBaseListModel.d.ts.map +0 -1
  205. package/dist/commonjs/react/collection/lib/useBaseListModel.js +0 -195
  206. package/dist/commonjs/react/collection/lib/useCursorListModel.d.ts +0 -1424
  207. package/dist/commonjs/react/collection/lib/useCursorListModel.d.ts.map +0 -1
  208. package/dist/commonjs/react/collection/lib/useCursorListModel.js +0 -396
  209. package/dist/es6/preview-react/color-picker/index.d.ts.map +0 -1
  210. package/dist/es6/preview-react/color-picker/lib/ColorPicker.d.ts.map +0 -1
  211. package/dist/es6/preview-react/color-picker/lib/defaultColorSet.d.ts.map +0 -1
  212. package/dist/es6/preview-react/color-picker/lib/parts/ColorReset.d.ts.map +0 -1
  213. package/dist/es6/preview-react/color-picker/lib/parts/ColorReset.js +0 -16
  214. package/dist/es6/preview-react/color-picker/lib/parts/SwatchBook.d.ts.map +0 -1
  215. package/dist/es6/preview-react/divider/index.d.ts.map +0 -1
  216. package/dist/es6/preview-react/divider/lib/Divider.d.ts.map +0 -1
  217. package/dist/es6/preview-react/index.d.ts.map +0 -1
  218. package/dist/es6/preview-react/loading-sparkles/index.d.ts.map +0 -1
  219. package/dist/es6/preview-react/loading-sparkles/lib/LoadingSparkles.d.ts.map +0 -1
  220. package/dist/es6/preview-react/loading-sparkles/lib/sparkleIcon.d.ts.map +0 -1
  221. package/dist/es6/preview-react/multi-select/index.d.ts.map +0 -1
  222. package/dist/es6/preview-react/multi-select/lib/MultiSelectInput.d.ts.map +0 -1
  223. package/dist/es6/preview-react/multi-select/lib/MultiSelectedList.d.ts.map +0 -1
  224. package/dist/es6/preview-react/radio/index.d.ts.map +0 -1
  225. package/dist/es6/preview-react/radio/lib/RadioButton.d.ts.map +0 -1
  226. package/dist/es6/preview-react/radio/lib/RadioGroup.d.ts.map +0 -1
  227. package/dist/es6/preview-react/radio/lib/RadioInput.d.ts.map +0 -1
  228. package/dist/es6/preview-react/radio/lib/RadioLabel.d.ts.map +0 -1
  229. package/dist/es6/preview-react/radio/lib/RadioText.d.ts.map +0 -1
  230. package/dist/es6/preview-react/radio/lib/StyledRadioButton.d.ts.map +0 -1
  231. package/dist/es6/preview-react/radio/lib/hooks/useRadioModel.d.ts.map +0 -1
  232. package/dist/es6/preview-react/side-panel/index.d.ts.map +0 -1
  233. package/dist/es6/preview-react/side-panel/lib/SidePanel.d.ts.map +0 -1
  234. package/dist/es6/preview-react/side-panel/lib/SidePanelToggleButton.d.ts.map +0 -1
  235. package/dist/es6/preview-react/side-panel/lib/hooks.d.ts.map +0 -1
  236. package/dist/es6/preview-react/status-indicator/index.d.ts.map +0 -1
  237. package/dist/es6/preview-react/status-indicator/lib/StatusIndicator.d.ts.map +0 -1
  238. package/dist/es6/preview-react/status-indicator/lib/StatusIndicatorIcon.d.ts.map +0 -1
  239. package/dist/es6/preview-react/status-indicator/lib/StatusIndicatorLabel.d.ts.map +0 -1
  240. package/dist/es6/preview-react/switch/index.d.ts.map +0 -1
  241. package/dist/es6/preview-react/switch/lib/Switch.d.ts.map +0 -1
  242. package/dist/es6/preview-react/switch/lib/SwitchBackground.d.ts.map +0 -1
  243. package/dist/es6/preview-react/switch/lib/SwitchCircle.d.ts.map +0 -1
  244. package/dist/es6/preview-react/switch/lib/SwitchContainer.d.ts.map +0 -1
  245. package/dist/es6/preview-react/switch/lib/SwitchIcon.d.ts.map +0 -1
  246. package/dist/es6/preview-react/switch/lib/SwitchInput.d.ts.map +0 -1
  247. package/dist/es6/preview-react/tabs/index.d.ts.map +0 -1
  248. package/dist/es6/preview-react/tabs/lib/TabsItem.d.ts.map +0 -1
  249. package/dist/es6/preview-react/tabs/lib/TabsList.d.ts.map +0 -1
  250. package/dist/es6/preview-react/tabs/lib/TabsOverflowButton.d.ts.map +0 -1
  251. package/dist/es6/preview-react/tabs/lib/TabsPanels.d.ts.map +0 -1
  252. package/dist/es6/preview-react/tabs/lib/useTabsModel.d.ts.map +0 -1
  253. package/dist/es6/preview-react/version/index.d.ts.map +0 -1
  254. package/dist/es6/preview-react/version/lib/version.d.ts.map +0 -1
  255. package/dist/es6/preview-react/version/lib/version.js +0 -1
  256. package/dist/es6/react/collection/lib/keyUtils.d.ts +0 -26
  257. package/dist/es6/react/collection/lib/keyUtils.d.ts.map +0 -1
  258. package/dist/es6/react/collection/lib/keyUtils.js +0 -80
  259. package/dist/es6/react/collection/lib/useBaseListModel.d.ts +0 -308
  260. package/dist/es6/react/collection/lib/useBaseListModel.d.ts.map +0 -1
  261. package/dist/es6/react/collection/lib/useBaseListModel.js +0 -187
  262. package/dist/es6/react/collection/lib/useCursorListModel.d.ts +0 -1424
  263. package/dist/es6/react/collection/lib/useCursorListModel.d.ts.map +0 -1
  264. package/dist/es6/react/collection/lib/useCursorListModel.js +0 -379
  265. /package/dist/commonjs/{preview-react/color-picker → color-picker}/index.d.ts +0 -0
  266. /package/dist/commonjs/{preview-react/color-picker → color-picker}/index.js +0 -0
  267. /package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/ColorPicker.d.ts +0 -0
  268. /package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/defaultColorSet.d.ts +0 -0
  269. /package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/defaultColorSet.js +0 -0
  270. /package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/parts/ColorReset.d.ts +0 -0
  271. /package/dist/commonjs/{preview-react/color-picker → color-picker}/lib/parts/SwatchBook.d.ts +0 -0
  272. /package/dist/commonjs/{preview-react/divider → divider}/index.d.ts +0 -0
  273. /package/dist/commonjs/{preview-react/divider → divider}/index.js +0 -0
  274. /package/dist/commonjs/{preview-react/divider → divider}/lib/Divider.d.ts +0 -0
  275. /package/dist/commonjs/{preview-react/index.d.ts → index.d.ts} +0 -0
  276. /package/dist/commonjs/{preview-react/index.js → index.js} +0 -0
  277. /package/dist/commonjs/{preview-react/loading-sparkles → loading-sparkles}/index.d.ts +0 -0
  278. /package/dist/commonjs/{preview-react/loading-sparkles → loading-sparkles}/index.js +0 -0
  279. /package/dist/commonjs/{preview-react/loading-sparkles → loading-sparkles}/lib/LoadingSparkles.d.ts +0 -0
  280. /package/dist/commonjs/{preview-react/loading-sparkles → loading-sparkles}/lib/sparkleIcon.d.ts +0 -0
  281. /package/dist/commonjs/{preview-react/loading-sparkles → loading-sparkles}/lib/sparkleIcon.js +0 -0
  282. /package/dist/commonjs/{preview-react/multi-select → multi-select}/index.d.ts +0 -0
  283. /package/dist/commonjs/{preview-react/multi-select → multi-select}/index.js +0 -0
  284. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelect.d.ts +0 -0
  285. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelect.js +0 -0
  286. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectCard.d.ts +0 -0
  287. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectCard.js +0 -0
  288. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectInput.d.ts +0 -0
  289. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectItem.d.ts +0 -0
  290. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectItem.js +0 -0
  291. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectedItem.d.ts +0 -0
  292. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectedItem.js +0 -0
  293. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectedList.d.ts +0 -0
  294. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/MultiSelectedList.js +0 -0
  295. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/useMultiSelectItemRemove.d.ts +0 -0
  296. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/useMultiSelectItemRemove.js +0 -0
  297. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/useMultiSelectModel.d.ts +0 -0
  298. /package/dist/commonjs/{preview-react/multi-select → multi-select}/lib/useMultiSelectModel.js +0 -0
  299. /package/dist/commonjs/{preview-react/radio → radio}/index.d.ts +0 -0
  300. /package/dist/commonjs/{preview-react/radio → radio}/index.js +0 -0
  301. /package/dist/commonjs/{preview-react/radio → radio}/lib/RadioButton.d.ts +0 -0
  302. /package/dist/commonjs/{preview-react/radio → radio}/lib/RadioButton.js +0 -0
  303. /package/dist/commonjs/{preview-react/radio → radio}/lib/RadioGroup.d.ts +0 -0
  304. /package/dist/commonjs/{preview-react/radio → radio}/lib/RadioInput.d.ts +0 -0
  305. /package/dist/commonjs/{preview-react/radio → radio}/lib/RadioInput.js +0 -0
  306. /package/dist/commonjs/{preview-react/radio → radio}/lib/RadioLabel.d.ts +0 -0
  307. /package/dist/commonjs/{preview-react/radio → radio}/lib/RadioText.d.ts +0 -0
  308. /package/dist/commonjs/{preview-react/radio → radio}/lib/StyledRadioButton.d.ts +0 -0
  309. /package/dist/commonjs/{preview-react/radio → radio}/lib/hooks/useRadioModel.d.ts +0 -0
  310. /package/dist/commonjs/{preview-react/radio → radio}/lib/hooks/useRadioModel.js +0 -0
  311. /package/dist/commonjs/{preview-react/side-panel → side-panel}/index.d.ts +0 -0
  312. /package/dist/commonjs/{preview-react/side-panel → side-panel}/index.js +0 -0
  313. /package/dist/commonjs/{preview-react/side-panel → side-panel}/lib/SidePanel.d.ts +0 -0
  314. /package/dist/commonjs/{preview-react/side-panel → side-panel}/lib/SidePanelToggleButton.d.ts +0 -0
  315. /package/dist/commonjs/{preview-react/side-panel → side-panel}/lib/hooks.d.ts +0 -0
  316. /package/dist/commonjs/{preview-react/side-panel → side-panel}/lib/hooks.js +0 -0
  317. /package/dist/commonjs/{preview-react/status-indicator → status-indicator}/index.d.ts +0 -0
  318. /package/dist/commonjs/{preview-react/status-indicator → status-indicator}/index.js +0 -0
  319. /package/dist/commonjs/{preview-react/status-indicator → status-indicator}/lib/StatusIndicator.d.ts +0 -0
  320. /package/dist/commonjs/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorIcon.d.ts +0 -0
  321. /package/dist/commonjs/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorIcon.js +0 -0
  322. /package/dist/commonjs/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorLabel.d.ts +0 -0
  323. /package/dist/commonjs/{preview-react/switch → switch}/index.d.ts +0 -0
  324. /package/dist/commonjs/{preview-react/switch → switch}/index.js +0 -0
  325. /package/dist/commonjs/{preview-react/switch → switch}/lib/Switch.d.ts +0 -0
  326. /package/dist/commonjs/{preview-react/switch → switch}/lib/Switch.js +0 -0
  327. /package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchBackground.d.ts +0 -0
  328. /package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchCircle.d.ts +0 -0
  329. /package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchContainer.d.ts +0 -0
  330. /package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchIcon.d.ts +0 -0
  331. /package/dist/commonjs/{preview-react/switch → switch}/lib/SwitchInput.d.ts +0 -0
  332. /package/dist/commonjs/{preview-react/tabs → tabs}/index.d.ts +0 -0
  333. /package/dist/commonjs/{preview-react/tabs → tabs}/index.js +0 -0
  334. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/Tabs.d.ts +0 -0
  335. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/Tabs.js +0 -0
  336. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsItem.d.ts +0 -0
  337. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsList.d.ts +0 -0
  338. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsOverflowButton.d.ts +0 -0
  339. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsPanel.d.ts +0 -0
  340. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsPanel.js +0 -0
  341. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsPanels.d.ts +0 -0
  342. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/TabsPanels.js +0 -0
  343. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/useTabsModel.d.ts +0 -0
  344. /package/dist/commonjs/{preview-react/tabs → tabs}/lib/useTabsModel.js +0 -0
  345. /package/dist/commonjs/{preview-react/version → version}/index.d.ts +0 -0
  346. /package/dist/commonjs/{preview-react/version → version}/index.js +0 -0
  347. /package/dist/commonjs/{preview-react/version → version}/lib/version.d.ts +0 -0
  348. /package/dist/es6/{preview-react/color-picker → color-picker}/index.d.ts +0 -0
  349. /package/dist/es6/{preview-react/color-picker → color-picker}/index.js +0 -0
  350. /package/dist/es6/{preview-react/color-picker → color-picker}/lib/ColorPicker.d.ts +0 -0
  351. /package/dist/es6/{preview-react/color-picker → color-picker}/lib/defaultColorSet.d.ts +0 -0
  352. /package/dist/es6/{preview-react/color-picker → color-picker}/lib/defaultColorSet.js +0 -0
  353. /package/dist/es6/{preview-react/color-picker → color-picker}/lib/parts/ColorReset.d.ts +0 -0
  354. /package/dist/es6/{preview-react/color-picker → color-picker}/lib/parts/SwatchBook.d.ts +0 -0
  355. /package/dist/es6/{preview-react/divider → divider}/index.d.ts +0 -0
  356. /package/dist/es6/{preview-react/divider → divider}/index.js +0 -0
  357. /package/dist/es6/{preview-react/divider → divider}/lib/Divider.d.ts +0 -0
  358. /package/dist/es6/{preview-react/index.d.ts → index.d.ts} +0 -0
  359. /package/dist/es6/{preview-react/index.js → index.js} +0 -0
  360. /package/dist/es6/{preview-react/loading-sparkles → loading-sparkles}/index.d.ts +0 -0
  361. /package/dist/es6/{preview-react/loading-sparkles → loading-sparkles}/index.js +0 -0
  362. /package/dist/es6/{preview-react/loading-sparkles → loading-sparkles}/lib/LoadingSparkles.d.ts +0 -0
  363. /package/dist/es6/{preview-react/loading-sparkles → loading-sparkles}/lib/sparkleIcon.d.ts +0 -0
  364. /package/dist/es6/{preview-react/loading-sparkles → loading-sparkles}/lib/sparkleIcon.js +0 -0
  365. /package/dist/es6/{preview-react/multi-select → multi-select}/index.d.ts +0 -0
  366. /package/dist/es6/{preview-react/multi-select → multi-select}/index.js +0 -0
  367. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelect.d.ts +0 -0
  368. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelect.js +0 -0
  369. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectCard.d.ts +0 -0
  370. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectCard.js +0 -0
  371. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectInput.d.ts +0 -0
  372. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectItem.d.ts +0 -0
  373. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectItem.js +0 -0
  374. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectedItem.d.ts +0 -0
  375. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectedItem.js +0 -0
  376. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectedList.d.ts +0 -0
  377. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/MultiSelectedList.js +0 -0
  378. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/useMultiSelectItemRemove.d.ts +0 -0
  379. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/useMultiSelectItemRemove.js +0 -0
  380. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/useMultiSelectModel.d.ts +0 -0
  381. /package/dist/es6/{preview-react/multi-select → multi-select}/lib/useMultiSelectModel.js +0 -0
  382. /package/dist/es6/{preview-react/radio → radio}/index.d.ts +0 -0
  383. /package/dist/es6/{preview-react/radio → radio}/index.js +0 -0
  384. /package/dist/es6/{preview-react/radio → radio}/lib/RadioButton.d.ts +0 -0
  385. /package/dist/es6/{preview-react/radio → radio}/lib/RadioButton.js +0 -0
  386. /package/dist/es6/{preview-react/radio → radio}/lib/RadioGroup.d.ts +0 -0
  387. /package/dist/es6/{preview-react/radio → radio}/lib/RadioInput.d.ts +0 -0
  388. /package/dist/es6/{preview-react/radio → radio}/lib/RadioInput.js +0 -0
  389. /package/dist/es6/{preview-react/radio → radio}/lib/RadioLabel.d.ts +0 -0
  390. /package/dist/es6/{preview-react/radio → radio}/lib/RadioText.d.ts +0 -0
  391. /package/dist/es6/{preview-react/radio → radio}/lib/StyledRadioButton.d.ts +0 -0
  392. /package/dist/es6/{preview-react/radio → radio}/lib/hooks/useRadioModel.d.ts +0 -0
  393. /package/dist/es6/{preview-react/radio → radio}/lib/hooks/useRadioModel.js +0 -0
  394. /package/dist/es6/{preview-react/side-panel → side-panel}/index.d.ts +0 -0
  395. /package/dist/es6/{preview-react/side-panel → side-panel}/index.js +0 -0
  396. /package/dist/es6/{preview-react/side-panel → side-panel}/lib/SidePanel.d.ts +0 -0
  397. /package/dist/es6/{preview-react/side-panel → side-panel}/lib/SidePanelToggleButton.d.ts +0 -0
  398. /package/dist/es6/{preview-react/side-panel → side-panel}/lib/hooks.d.ts +0 -0
  399. /package/dist/es6/{preview-react/side-panel → side-panel}/lib/hooks.js +0 -0
  400. /package/dist/es6/{preview-react/status-indicator → status-indicator}/index.d.ts +0 -0
  401. /package/dist/es6/{preview-react/status-indicator → status-indicator}/index.js +0 -0
  402. /package/dist/es6/{preview-react/status-indicator → status-indicator}/lib/StatusIndicator.d.ts +0 -0
  403. /package/dist/es6/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorIcon.d.ts +0 -0
  404. /package/dist/es6/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorIcon.js +0 -0
  405. /package/dist/es6/{preview-react/status-indicator → status-indicator}/lib/StatusIndicatorLabel.d.ts +0 -0
  406. /package/dist/es6/{preview-react/switch → switch}/index.d.ts +0 -0
  407. /package/dist/es6/{preview-react/switch → switch}/index.js +0 -0
  408. /package/dist/es6/{preview-react/switch → switch}/lib/Switch.d.ts +0 -0
  409. /package/dist/es6/{preview-react/switch → switch}/lib/Switch.js +0 -0
  410. /package/dist/es6/{preview-react/switch → switch}/lib/SwitchBackground.d.ts +0 -0
  411. /package/dist/es6/{preview-react/switch → switch}/lib/SwitchCircle.d.ts +0 -0
  412. /package/dist/es6/{preview-react/switch → switch}/lib/SwitchContainer.d.ts +0 -0
  413. /package/dist/es6/{preview-react/switch → switch}/lib/SwitchIcon.d.ts +0 -0
  414. /package/dist/es6/{preview-react/switch → switch}/lib/SwitchInput.d.ts +0 -0
  415. /package/dist/es6/{preview-react/tabs → tabs}/index.d.ts +0 -0
  416. /package/dist/es6/{preview-react/tabs → tabs}/index.js +0 -0
  417. /package/dist/es6/{preview-react/tabs → tabs}/lib/Tabs.d.ts +0 -0
  418. /package/dist/es6/{preview-react/tabs → tabs}/lib/Tabs.js +0 -0
  419. /package/dist/es6/{preview-react/tabs → tabs}/lib/TabsItem.d.ts +0 -0
  420. /package/dist/es6/{preview-react/tabs → tabs}/lib/TabsList.d.ts +0 -0
  421. /package/dist/es6/{preview-react/tabs → tabs}/lib/TabsOverflowButton.d.ts +0 -0
  422. /package/dist/es6/{preview-react/tabs → tabs}/lib/TabsPanel.d.ts +0 -0
  423. /package/dist/es6/{preview-react/tabs → tabs}/lib/TabsPanel.js +0 -0
  424. /package/dist/es6/{preview-react/tabs → tabs}/lib/TabsPanels.d.ts +0 -0
  425. /package/dist/es6/{preview-react/tabs → tabs}/lib/TabsPanels.js +0 -0
  426. /package/dist/es6/{preview-react/tabs → tabs}/lib/useTabsModel.d.ts +0 -0
  427. /package/dist/es6/{preview-react/tabs → tabs}/lib/useTabsModel.js +0 -0
  428. /package/dist/es6/{preview-react/version → version}/index.d.ts +0 -0
  429. /package/dist/es6/{preview-react/version → version}/index.js +0 -0
  430. /package/dist/es6/{preview-react/version → version}/lib/version.d.ts +0 -0
@@ -1,1424 +0,0 @@
1
- import React from 'react';
2
- import { Generic } from '@workday/canvas-kit-react/common';
3
- import { Item } from './useBaseListModel';
4
- type NavigationInput = Pick<ReturnType<typeof useCursorListModel>, 'state'>;
5
- /**
6
- * The list and grid models accept a `navigation` config. If one is not provided, a default will be
7
- * chosen. It is possible to create a custom navigation manager to hand to the model if the default
8
- * doesn't work.
9
- */
10
- export interface NavigationManager {
11
- /** Get the first item in a collection. This will be called when the `Home` key is pressed for
12
- * Lists and `Ctrl+Home` for Grids. */
13
- getFirst: NavigationRequestor;
14
- /** Get the last item in a collection. This will be called when the `End` key is pressed for Lists
15
- * and `Ctrl+End` for Grids. */
16
- getLast: NavigationRequestor;
17
- /** Get an item with the provided `id`. */
18
- getItem: (id: string, model: NavigationInput) => Item<Generic> | undefined;
19
- /** Get the next item after the provided `id`. This will be called when the `Right` arrow key is
20
- * pressed for RTL languages and when the `Left` arrow is pressed for LTR languages. */
21
- getNext: NavigationRequestor;
22
- /** **For Grids:** Get the cell in the next row from the provided `id`. This will be called when
23
- * the `Down` arrow is pressed. */
24
- getNextRow: NavigationRequestor;
25
- /** Get the previous item before the provided `id`. This will be called when the `Left` arrow key
26
- * is pressed for RTL languages and when the `Right` arrow is pressed for LTR languages. */
27
- getPrevious: NavigationRequestor;
28
- /** **For Grids:** Get the cell in the previous row from the provided `id`. This will be called
29
- * when the `Up` arrow is pressed. */
30
- getPreviousRow: NavigationRequestor;
31
- /** **For Grids:** Get the first item in a row. This will be called when the `Home` key is
32
- * pressed. */
33
- getFirstOfRow: NavigationRequestor;
34
- /** **For Grids:** Get the last item in a row. This will be called when the `End` key is
35
- * pressed. */
36
- getLastOfRow: NavigationRequestor;
37
- /** Get the next "page". A "page" is application specific and usually means next visible screen.
38
- * If the viewport is scrollable, it would scroll so that the last item visible is now the first
39
- * item visible. This is called when the `PageDown` key is pressed */
40
- getNextPage: NavigationRequestor;
41
- /** Get the next "page". A "page" is application specific and usually means previous visible
42
- * screen. If the viewport is scrollable, it would scroll so that the first item visible is now
43
- * the last item visible. This is called when the `PageUp` key is pressed */
44
- getPreviousPage: NavigationRequestor;
45
- }
46
- /**
47
- * Factory function that does type checking to create navigation managers. Navigation managers
48
- * are expected to handle all methods of a grid. If your use-case isn't meant to handle a grid,
49
- * pick one of the existing navigation managers and override the methods you wish to implement.
50
- *
51
- * For example,
52
- * ```tsx
53
- * import {createNavigationManager, wrappingNavigationManager} from '@workday/canvas-kit-react/collection'
54
- *
55
- * const navigationManager = createNavigationManager({
56
- * ...wrappingNavigationManager,
57
- * getNext(id, {state}) {
58
- * //
59
- * }
60
- * })
61
- * ```
62
- */
63
- export declare const createNavigationManager: (manager: NavigationManager) => NavigationManager;
64
- /**
65
- * Given an id and a model, return an item from the collection
66
- */
67
- export type NavigationRequestor = (index: number, model: NavigationInput) => number;
68
- /**
69
- * Get the first item in a list regardless of column count
70
- */
71
- export declare const getFirst: NavigationRequestor;
72
- /**
73
- * Get the last item in a list regardless of column count
74
- */
75
- export declare const getLast: NavigationRequestor;
76
- /**
77
- * Get the first item in a row. If column count is 0, it will return the results of `getFirst`
78
- */
79
- export declare const getFirstOfRow: NavigationRequestor;
80
- /**
81
- * get the last item in a row - if column count is 0, it will return the results of `getLast`
82
- */
83
- export declare const getLastOfRow: NavigationRequestor;
84
- /**
85
- * get the item in the previous page. This can be author defined. By default it will return the
86
- * first item for a list, and the first item in the same column for a grid.
87
- */
88
- export declare const getPreviousPage: NavigationRequestor;
89
- /**
90
- * get the item in the next page. This can be author defined. By default, it will return the last
91
- * item for a list, and the last item in the same column for a grid.
92
- */
93
- export declare const getNextPage: NavigationRequestor;
94
- /**
95
- * Get the current cursor id of a Collection model's state.
96
- */
97
- export declare const getCursor: (state: NavigationInput['state']) => string;
98
- /**
99
- * Check if the provided id is the current cursor id of a Collection model's state.
100
- */
101
- export declare const isCursor: (state: NavigationInput['state'], id?: string) => boolean;
102
- export declare const getWrappingOffsetItem: (offset: number) => (index: number, { state }: NavigationInput, tries?: number) => number;
103
- export declare const getOffsetItem: (offset: number) => (index: number, { state }: NavigationInput, tries?: number) => number;
104
- /**
105
- * The default navigation manager of lists. This navigation manager will wrap around when the edge
106
- * is hit. For example, if the user is the the right-most item in a list or right-most item in a
107
- * row, the cursor will wrap around to the beginning or the next row.
108
- */
109
- export declare const wrappingNavigationManager: NavigationManager;
110
- /**
111
- * The default navigation of grids. This navigation manager will not wrap, but will stop when an
112
- * edge is detected. This could be the last item in a list or the last item of a row in a grid.
113
- */
114
- export declare const navigationManager: NavigationManager;
115
- /**
116
- * A `CursorModel` extends a `ListModel` and adds a "cursor" to the list. A cursor is a pointer to a
117
- * current position in the list. The most common use-case is keeping track of which item currently
118
- * has focus within the list. Many w3c list role types specify a single tab stop within the list.
119
- */
120
- export declare const useCursorListModel: (<TT_Special_Generic>(config?: (Partial<{
121
- /**
122
- * Initial cursor position. If not provided, the cursor will point to the first item in the list
123
- */
124
- initialCursorId: string | string[];
125
- /**
126
- * If this is set it will cause a wrapping of a list that will turn it into a grid
127
- * @default 0
128
- */
129
- columnCount: number;
130
- /**
131
- * Controls the state changes when the user sends navigation events to the model. For example,
132
- * when the user hits the "right" arrow, a behavior hook will determine directionality
133
- * (left-to-right or right-to-left) and call the correct navigation method. In our example, a
134
- * left-to-right language would send a `getNext`. The navigation manager may return the next item
135
- * in the list. Different managers can be created for slightly different use cases. The default
136
- * navigation manager will accept `orientation` and directionality to determine mapping.
137
- *
138
- * An example override might be a tab list with an overflow menu that is meant to be transparent
139
- * to screen reader users. This would require the overflow menu to accept both up/down keys as
140
- * well as left/right keys to give a more consistent experience to all users.
141
- */
142
- navigation: NavigationManager;
143
- /**
144
- * Controls how much a pageUp/pageDown navigation request will jump. If not provided, the size
145
- * of the list and number of items rendered will determine this value.
146
- */
147
- pageSize: number;
148
- id: string;
149
- getId: (item: any) => string;
150
- getTextValue: (item: any) => string;
151
- nonInteractiveIds: string[];
152
- orientation: import("./useBaseListModel").Orientation;
153
- defaultItemHeight: number;
154
- shouldVirtualize: boolean;
155
- items: any[];
156
- }> & {
157
- onGoTo?: ((data: {
158
- id: string;
159
- }, prevState: {
160
- /** The id of the list item the cursor is pointing to */
161
- cursorId: string | string[];
162
- /**
163
- * Any positive non-zero value treats the list like a grid with rows and columns
164
- * @default 0
165
- * @private Use useGridModel instead to make a grid instead of a list
166
- */
167
- columnCount: number;
168
- /**
169
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
170
- * based on the size of the list container and the number of items fitting within the container.
171
- */
172
- pageSizeRef: React.MutableRefObject<number>;
173
- /**
174
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
175
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
176
- * or the `items` change.
177
- *
178
- * @readonly
179
- */
180
- cursorIndexRef: {
181
- readonly current: number;
182
- };
183
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
184
- UNSTABLE_defaultItemHeight: number;
185
- containerRef: React.RefObject<HTMLDivElement>;
186
- id: string;
187
- orientation: "horizontal" | "vertical";
188
- indexRef: React.MutableRefObject<number>;
189
- nonInteractiveIds: string[];
190
- isVirtualized: boolean;
191
- items: Item<any>[];
192
- }) => void) | undefined;
193
- onGoToNext?: ((data: undefined, prevState: {
194
- /** The id of the list item the cursor is pointing to */
195
- cursorId: string | string[];
196
- /**
197
- * Any positive non-zero value treats the list like a grid with rows and columns
198
- * @default 0
199
- * @private Use useGridModel instead to make a grid instead of a list
200
- */
201
- columnCount: number;
202
- /**
203
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
204
- * based on the size of the list container and the number of items fitting within the container.
205
- */
206
- pageSizeRef: React.MutableRefObject<number>;
207
- /**
208
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
209
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
210
- * or the `items` change.
211
- *
212
- * @readonly
213
- */
214
- cursorIndexRef: {
215
- readonly current: number;
216
- };
217
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
218
- UNSTABLE_defaultItemHeight: number;
219
- containerRef: React.RefObject<HTMLDivElement>;
220
- id: string;
221
- orientation: "horizontal" | "vertical";
222
- indexRef: React.MutableRefObject<number>;
223
- nonInteractiveIds: string[];
224
- isVirtualized: boolean;
225
- items: Item<any>[];
226
- }) => void) | undefined;
227
- onGoToPrevious?: ((data: undefined, prevState: {
228
- /** The id of the list item the cursor is pointing to */
229
- cursorId: string | string[];
230
- /**
231
- * Any positive non-zero value treats the list like a grid with rows and columns
232
- * @default 0
233
- * @private Use useGridModel instead to make a grid instead of a list
234
- */
235
- columnCount: number;
236
- /**
237
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
238
- * based on the size of the list container and the number of items fitting within the container.
239
- */
240
- pageSizeRef: React.MutableRefObject<number>;
241
- /**
242
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
243
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
244
- * or the `items` change.
245
- *
246
- * @readonly
247
- */
248
- cursorIndexRef: {
249
- readonly current: number;
250
- };
251
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
252
- UNSTABLE_defaultItemHeight: number;
253
- containerRef: React.RefObject<HTMLDivElement>;
254
- id: string;
255
- orientation: "horizontal" | "vertical";
256
- indexRef: React.MutableRefObject<number>;
257
- nonInteractiveIds: string[];
258
- isVirtualized: boolean;
259
- items: Item<any>[];
260
- }) => void) | undefined;
261
- onGoToPreviousRow?: ((data: undefined, prevState: {
262
- /** The id of the list item the cursor is pointing to */
263
- cursorId: string | string[];
264
- /**
265
- * Any positive non-zero value treats the list like a grid with rows and columns
266
- * @default 0
267
- * @private Use useGridModel instead to make a grid instead of a list
268
- */
269
- columnCount: number;
270
- /**
271
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
272
- * based on the size of the list container and the number of items fitting within the container.
273
- */
274
- pageSizeRef: React.MutableRefObject<number>;
275
- /**
276
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
277
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
278
- * or the `items` change.
279
- *
280
- * @readonly
281
- */
282
- cursorIndexRef: {
283
- readonly current: number;
284
- };
285
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
286
- UNSTABLE_defaultItemHeight: number;
287
- containerRef: React.RefObject<HTMLDivElement>;
288
- id: string;
289
- orientation: "horizontal" | "vertical";
290
- indexRef: React.MutableRefObject<number>;
291
- nonInteractiveIds: string[];
292
- isVirtualized: boolean;
293
- items: Item<any>[];
294
- }) => void) | undefined;
295
- onGoToNextRow?: ((data: undefined, prevState: {
296
- /** The id of the list item the cursor is pointing to */
297
- cursorId: string | string[];
298
- /**
299
- * Any positive non-zero value treats the list like a grid with rows and columns
300
- * @default 0
301
- * @private Use useGridModel instead to make a grid instead of a list
302
- */
303
- columnCount: number;
304
- /**
305
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
306
- * based on the size of the list container and the number of items fitting within the container.
307
- */
308
- pageSizeRef: React.MutableRefObject<number>;
309
- /**
310
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
311
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
312
- * or the `items` change.
313
- *
314
- * @readonly
315
- */
316
- cursorIndexRef: {
317
- readonly current: number;
318
- };
319
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
320
- UNSTABLE_defaultItemHeight: number;
321
- containerRef: React.RefObject<HTMLDivElement>;
322
- id: string;
323
- orientation: "horizontal" | "vertical";
324
- indexRef: React.MutableRefObject<number>;
325
- nonInteractiveIds: string[];
326
- isVirtualized: boolean;
327
- items: Item<any>[];
328
- }) => void) | undefined;
329
- onGoToFirst?: ((data: undefined, prevState: {
330
- /** The id of the list item the cursor is pointing to */
331
- cursorId: string | string[];
332
- /**
333
- * Any positive non-zero value treats the list like a grid with rows and columns
334
- * @default 0
335
- * @private Use useGridModel instead to make a grid instead of a list
336
- */
337
- columnCount: number;
338
- /**
339
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
340
- * based on the size of the list container and the number of items fitting within the container.
341
- */
342
- pageSizeRef: React.MutableRefObject<number>;
343
- /**
344
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
345
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
346
- * or the `items` change.
347
- *
348
- * @readonly
349
- */
350
- cursorIndexRef: {
351
- readonly current: number;
352
- };
353
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
354
- UNSTABLE_defaultItemHeight: number;
355
- containerRef: React.RefObject<HTMLDivElement>;
356
- id: string;
357
- orientation: "horizontal" | "vertical";
358
- indexRef: React.MutableRefObject<number>;
359
- nonInteractiveIds: string[];
360
- isVirtualized: boolean;
361
- items: Item<any>[];
362
- }) => void) | undefined;
363
- onGoToLast?: ((data: undefined, prevState: {
364
- /** The id of the list item the cursor is pointing to */
365
- cursorId: string | string[];
366
- /**
367
- * Any positive non-zero value treats the list like a grid with rows and columns
368
- * @default 0
369
- * @private Use useGridModel instead to make a grid instead of a list
370
- */
371
- columnCount: number;
372
- /**
373
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
374
- * based on the size of the list container and the number of items fitting within the container.
375
- */
376
- pageSizeRef: React.MutableRefObject<number>;
377
- /**
378
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
379
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
380
- * or the `items` change.
381
- *
382
- * @readonly
383
- */
384
- cursorIndexRef: {
385
- readonly current: number;
386
- };
387
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
388
- UNSTABLE_defaultItemHeight: number;
389
- containerRef: React.RefObject<HTMLDivElement>;
390
- id: string;
391
- orientation: "horizontal" | "vertical";
392
- indexRef: React.MutableRefObject<number>;
393
- nonInteractiveIds: string[];
394
- isVirtualized: boolean;
395
- items: Item<any>[];
396
- }) => void) | undefined;
397
- onGoToFirstOfRow?: ((data: undefined, prevState: {
398
- /** The id of the list item the cursor is pointing to */
399
- cursorId: string | string[];
400
- /**
401
- * Any positive non-zero value treats the list like a grid with rows and columns
402
- * @default 0
403
- * @private Use useGridModel instead to make a grid instead of a list
404
- */
405
- columnCount: number;
406
- /**
407
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
408
- * based on the size of the list container and the number of items fitting within the container.
409
- */
410
- pageSizeRef: React.MutableRefObject<number>;
411
- /**
412
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
413
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
414
- * or the `items` change.
415
- *
416
- * @readonly
417
- */
418
- cursorIndexRef: {
419
- readonly current: number;
420
- };
421
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
422
- UNSTABLE_defaultItemHeight: number;
423
- containerRef: React.RefObject<HTMLDivElement>;
424
- id: string;
425
- orientation: "horizontal" | "vertical";
426
- indexRef: React.MutableRefObject<number>;
427
- nonInteractiveIds: string[];
428
- isVirtualized: boolean;
429
- items: Item<any>[];
430
- }) => void) | undefined;
431
- onGoToLastOfRow?: ((data: undefined, prevState: {
432
- /** The id of the list item the cursor is pointing to */
433
- cursorId: string | string[];
434
- /**
435
- * Any positive non-zero value treats the list like a grid with rows and columns
436
- * @default 0
437
- * @private Use useGridModel instead to make a grid instead of a list
438
- */
439
- columnCount: number;
440
- /**
441
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
442
- * based on the size of the list container and the number of items fitting within the container.
443
- */
444
- pageSizeRef: React.MutableRefObject<number>;
445
- /**
446
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
447
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
448
- * or the `items` change.
449
- *
450
- * @readonly
451
- */
452
- cursorIndexRef: {
453
- readonly current: number;
454
- };
455
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
456
- UNSTABLE_defaultItemHeight: number;
457
- containerRef: React.RefObject<HTMLDivElement>;
458
- id: string;
459
- orientation: "horizontal" | "vertical";
460
- indexRef: React.MutableRefObject<number>;
461
- nonInteractiveIds: string[];
462
- isVirtualized: boolean;
463
- items: Item<any>[];
464
- }) => void) | undefined;
465
- onGoToNextPage?: ((data: undefined, prevState: {
466
- /** The id of the list item the cursor is pointing to */
467
- cursorId: string | string[];
468
- /**
469
- * Any positive non-zero value treats the list like a grid with rows and columns
470
- * @default 0
471
- * @private Use useGridModel instead to make a grid instead of a list
472
- */
473
- columnCount: number;
474
- /**
475
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
476
- * based on the size of the list container and the number of items fitting within the container.
477
- */
478
- pageSizeRef: React.MutableRefObject<number>;
479
- /**
480
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
481
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
482
- * or the `items` change.
483
- *
484
- * @readonly
485
- */
486
- cursorIndexRef: {
487
- readonly current: number;
488
- };
489
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
490
- UNSTABLE_defaultItemHeight: number;
491
- containerRef: React.RefObject<HTMLDivElement>;
492
- id: string;
493
- orientation: "horizontal" | "vertical";
494
- indexRef: React.MutableRefObject<number>;
495
- nonInteractiveIds: string[];
496
- isVirtualized: boolean;
497
- items: Item<any>[];
498
- }) => void) | undefined;
499
- onGoToPreviousPage?: ((data: undefined, prevState: {
500
- /** The id of the list item the cursor is pointing to */
501
- cursorId: string | string[];
502
- /**
503
- * Any positive non-zero value treats the list like a grid with rows and columns
504
- * @default 0
505
- * @private Use useGridModel instead to make a grid instead of a list
506
- */
507
- columnCount: number;
508
- /**
509
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
510
- * based on the size of the list container and the number of items fitting within the container.
511
- */
512
- pageSizeRef: React.MutableRefObject<number>;
513
- /**
514
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
515
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
516
- * or the `items` change.
517
- *
518
- * @readonly
519
- */
520
- cursorIndexRef: {
521
- readonly current: number;
522
- };
523
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
524
- UNSTABLE_defaultItemHeight: number;
525
- containerRef: React.RefObject<HTMLDivElement>;
526
- id: string;
527
- orientation: "horizontal" | "vertical";
528
- indexRef: React.MutableRefObject<number>;
529
- nonInteractiveIds: string[];
530
- isVirtualized: boolean;
531
- items: Item<any>[];
532
- }) => void) | undefined;
533
- onRegisterItem?: ((data: {
534
- id: string;
535
- textValue: string;
536
- }, prevState: {
537
- /** The id of the list item the cursor is pointing to */
538
- cursorId: string | string[];
539
- /**
540
- * Any positive non-zero value treats the list like a grid with rows and columns
541
- * @default 0
542
- * @private Use useGridModel instead to make a grid instead of a list
543
- */
544
- columnCount: number;
545
- /**
546
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
547
- * based on the size of the list container and the number of items fitting within the container.
548
- */
549
- pageSizeRef: React.MutableRefObject<number>;
550
- /**
551
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
552
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
553
- * or the `items` change.
554
- *
555
- * @readonly
556
- */
557
- cursorIndexRef: {
558
- readonly current: number;
559
- };
560
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
561
- UNSTABLE_defaultItemHeight: number;
562
- containerRef: React.RefObject<HTMLDivElement>;
563
- id: string;
564
- orientation: "horizontal" | "vertical";
565
- indexRef: React.MutableRefObject<number>;
566
- nonInteractiveIds: string[];
567
- isVirtualized: boolean;
568
- items: Item<any>[];
569
- }) => void) | undefined;
570
- onUnregisterItem?: ((data: {
571
- id: string;
572
- }, prevState: {
573
- /** The id of the list item the cursor is pointing to */
574
- cursorId: string | string[];
575
- /**
576
- * Any positive non-zero value treats the list like a grid with rows and columns
577
- * @default 0
578
- * @private Use useGridModel instead to make a grid instead of a list
579
- */
580
- columnCount: number;
581
- /**
582
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
583
- * based on the size of the list container and the number of items fitting within the container.
584
- */
585
- pageSizeRef: React.MutableRefObject<number>;
586
- /**
587
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
588
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
589
- * or the `items` change.
590
- *
591
- * @readonly
592
- */
593
- cursorIndexRef: {
594
- readonly current: number;
595
- };
596
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
597
- UNSTABLE_defaultItemHeight: number;
598
- containerRef: React.RefObject<HTMLDivElement>;
599
- id: string;
600
- orientation: "horizontal" | "vertical";
601
- indexRef: React.MutableRefObject<number>;
602
- nonInteractiveIds: string[];
603
- isVirtualized: boolean;
604
- items: Item<any>[];
605
- }) => void) | undefined;
606
- onUpdateItemHeight?: ((data: {
607
- value: number;
608
- }, prevState: {
609
- /** The id of the list item the cursor is pointing to */
610
- cursorId: string | string[];
611
- /**
612
- * Any positive non-zero value treats the list like a grid with rows and columns
613
- * @default 0
614
- * @private Use useGridModel instead to make a grid instead of a list
615
- */
616
- columnCount: number;
617
- /**
618
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
619
- * based on the size of the list container and the number of items fitting within the container.
620
- */
621
- pageSizeRef: React.MutableRefObject<number>;
622
- /**
623
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
624
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
625
- * or the `items` change.
626
- *
627
- * @readonly
628
- */
629
- cursorIndexRef: {
630
- readonly current: number;
631
- };
632
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
633
- UNSTABLE_defaultItemHeight: number;
634
- containerRef: React.RefObject<HTMLDivElement>;
635
- id: string;
636
- orientation: "horizontal" | "vertical";
637
- indexRef: React.MutableRefObject<number>;
638
- nonInteractiveIds: string[];
639
- isVirtualized: boolean;
640
- items: Item<any>[];
641
- }) => void) | undefined;
642
- } & {
643
- shouldGoTo?: ((data: {
644
- id: string;
645
- }, state: {
646
- /** The id of the list item the cursor is pointing to */
647
- cursorId: string | string[];
648
- /**
649
- * Any positive non-zero value treats the list like a grid with rows and columns
650
- * @default 0
651
- * @private Use useGridModel instead to make a grid instead of a list
652
- */
653
- columnCount: number;
654
- /**
655
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
656
- * based on the size of the list container and the number of items fitting within the container.
657
- */
658
- pageSizeRef: React.MutableRefObject<number>;
659
- /**
660
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
661
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
662
- * or the `items` change.
663
- *
664
- * @readonly
665
- */
666
- cursorIndexRef: {
667
- readonly current: number;
668
- };
669
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
670
- UNSTABLE_defaultItemHeight: number;
671
- containerRef: React.RefObject<HTMLDivElement>;
672
- id: string;
673
- orientation: "horizontal" | "vertical";
674
- indexRef: React.MutableRefObject<number>;
675
- nonInteractiveIds: string[];
676
- isVirtualized: boolean;
677
- items: Item<any>[];
678
- }) => boolean) | undefined;
679
- shouldGoToNext?: ((data: undefined, state: {
680
- /** The id of the list item the cursor is pointing to */
681
- cursorId: string | string[];
682
- /**
683
- * Any positive non-zero value treats the list like a grid with rows and columns
684
- * @default 0
685
- * @private Use useGridModel instead to make a grid instead of a list
686
- */
687
- columnCount: number;
688
- /**
689
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
690
- * based on the size of the list container and the number of items fitting within the container.
691
- */
692
- pageSizeRef: React.MutableRefObject<number>;
693
- /**
694
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
695
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
696
- * or the `items` change.
697
- *
698
- * @readonly
699
- */
700
- cursorIndexRef: {
701
- readonly current: number;
702
- };
703
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
704
- UNSTABLE_defaultItemHeight: number;
705
- containerRef: React.RefObject<HTMLDivElement>;
706
- id: string;
707
- orientation: "horizontal" | "vertical";
708
- indexRef: React.MutableRefObject<number>;
709
- nonInteractiveIds: string[];
710
- isVirtualized: boolean;
711
- items: Item<any>[];
712
- }) => boolean) | undefined;
713
- shouldGoToPrevious?: ((data: undefined, state: {
714
- /** The id of the list item the cursor is pointing to */
715
- cursorId: string | string[];
716
- /**
717
- * Any positive non-zero value treats the list like a grid with rows and columns
718
- * @default 0
719
- * @private Use useGridModel instead to make a grid instead of a list
720
- */
721
- columnCount: number;
722
- /**
723
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
724
- * based on the size of the list container and the number of items fitting within the container.
725
- */
726
- pageSizeRef: React.MutableRefObject<number>;
727
- /**
728
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
729
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
730
- * or the `items` change.
731
- *
732
- * @readonly
733
- */
734
- cursorIndexRef: {
735
- readonly current: number;
736
- };
737
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
738
- UNSTABLE_defaultItemHeight: number;
739
- containerRef: React.RefObject<HTMLDivElement>;
740
- id: string;
741
- orientation: "horizontal" | "vertical";
742
- indexRef: React.MutableRefObject<number>;
743
- nonInteractiveIds: string[];
744
- isVirtualized: boolean;
745
- items: Item<any>[];
746
- }) => boolean) | undefined;
747
- shouldGoToPreviousRow?: ((data: undefined, state: {
748
- /** The id of the list item the cursor is pointing to */
749
- cursorId: string | string[];
750
- /**
751
- * Any positive non-zero value treats the list like a grid with rows and columns
752
- * @default 0
753
- * @private Use useGridModel instead to make a grid instead of a list
754
- */
755
- columnCount: number;
756
- /**
757
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
758
- * based on the size of the list container and the number of items fitting within the container.
759
- */
760
- pageSizeRef: React.MutableRefObject<number>;
761
- /**
762
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
763
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
764
- * or the `items` change.
765
- *
766
- * @readonly
767
- */
768
- cursorIndexRef: {
769
- readonly current: number;
770
- };
771
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
772
- UNSTABLE_defaultItemHeight: number;
773
- containerRef: React.RefObject<HTMLDivElement>;
774
- id: string;
775
- orientation: "horizontal" | "vertical";
776
- indexRef: React.MutableRefObject<number>;
777
- nonInteractiveIds: string[];
778
- isVirtualized: boolean;
779
- items: Item<any>[];
780
- }) => boolean) | undefined;
781
- shouldGoToNextRow?: ((data: undefined, state: {
782
- /** The id of the list item the cursor is pointing to */
783
- cursorId: string | string[];
784
- /**
785
- * Any positive non-zero value treats the list like a grid with rows and columns
786
- * @default 0
787
- * @private Use useGridModel instead to make a grid instead of a list
788
- */
789
- columnCount: number;
790
- /**
791
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
792
- * based on the size of the list container and the number of items fitting within the container.
793
- */
794
- pageSizeRef: React.MutableRefObject<number>;
795
- /**
796
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
797
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
798
- * or the `items` change.
799
- *
800
- * @readonly
801
- */
802
- cursorIndexRef: {
803
- readonly current: number;
804
- };
805
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
806
- UNSTABLE_defaultItemHeight: number;
807
- containerRef: React.RefObject<HTMLDivElement>;
808
- id: string;
809
- orientation: "horizontal" | "vertical";
810
- indexRef: React.MutableRefObject<number>;
811
- nonInteractiveIds: string[];
812
- isVirtualized: boolean;
813
- items: Item<any>[];
814
- }) => boolean) | undefined;
815
- shouldGoToFirst?: ((data: undefined, state: {
816
- /** The id of the list item the cursor is pointing to */
817
- cursorId: string | string[];
818
- /**
819
- * Any positive non-zero value treats the list like a grid with rows and columns
820
- * @default 0
821
- * @private Use useGridModel instead to make a grid instead of a list
822
- */
823
- columnCount: number;
824
- /**
825
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
826
- * based on the size of the list container and the number of items fitting within the container.
827
- */
828
- pageSizeRef: React.MutableRefObject<number>;
829
- /**
830
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
831
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
832
- * or the `items` change.
833
- *
834
- * @readonly
835
- */
836
- cursorIndexRef: {
837
- readonly current: number;
838
- };
839
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
840
- UNSTABLE_defaultItemHeight: number;
841
- containerRef: React.RefObject<HTMLDivElement>;
842
- id: string;
843
- orientation: "horizontal" | "vertical";
844
- indexRef: React.MutableRefObject<number>;
845
- nonInteractiveIds: string[];
846
- isVirtualized: boolean;
847
- items: Item<any>[];
848
- }) => boolean) | undefined;
849
- shouldGoToLast?: ((data: undefined, state: {
850
- /** The id of the list item the cursor is pointing to */
851
- cursorId: string | string[];
852
- /**
853
- * Any positive non-zero value treats the list like a grid with rows and columns
854
- * @default 0
855
- * @private Use useGridModel instead to make a grid instead of a list
856
- */
857
- columnCount: number;
858
- /**
859
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
860
- * based on the size of the list container and the number of items fitting within the container.
861
- */
862
- pageSizeRef: React.MutableRefObject<number>;
863
- /**
864
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
865
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
866
- * or the `items` change.
867
- *
868
- * @readonly
869
- */
870
- cursorIndexRef: {
871
- readonly current: number;
872
- };
873
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
874
- UNSTABLE_defaultItemHeight: number;
875
- containerRef: React.RefObject<HTMLDivElement>;
876
- id: string;
877
- orientation: "horizontal" | "vertical";
878
- indexRef: React.MutableRefObject<number>;
879
- nonInteractiveIds: string[];
880
- isVirtualized: boolean;
881
- items: Item<any>[];
882
- }) => boolean) | undefined;
883
- shouldGoToFirstOfRow?: ((data: undefined, state: {
884
- /** The id of the list item the cursor is pointing to */
885
- cursorId: string | string[];
886
- /**
887
- * Any positive non-zero value treats the list like a grid with rows and columns
888
- * @default 0
889
- * @private Use useGridModel instead to make a grid instead of a list
890
- */
891
- columnCount: number;
892
- /**
893
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
894
- * based on the size of the list container and the number of items fitting within the container.
895
- */
896
- pageSizeRef: React.MutableRefObject<number>;
897
- /**
898
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
899
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
900
- * or the `items` change.
901
- *
902
- * @readonly
903
- */
904
- cursorIndexRef: {
905
- readonly current: number;
906
- };
907
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
908
- UNSTABLE_defaultItemHeight: number;
909
- containerRef: React.RefObject<HTMLDivElement>;
910
- id: string;
911
- orientation: "horizontal" | "vertical";
912
- indexRef: React.MutableRefObject<number>;
913
- nonInteractiveIds: string[];
914
- isVirtualized: boolean;
915
- items: Item<any>[];
916
- }) => boolean) | undefined;
917
- shouldGoToLastOfRow?: ((data: undefined, state: {
918
- /** The id of the list item the cursor is pointing to */
919
- cursorId: string | string[];
920
- /**
921
- * Any positive non-zero value treats the list like a grid with rows and columns
922
- * @default 0
923
- * @private Use useGridModel instead to make a grid instead of a list
924
- */
925
- columnCount: number;
926
- /**
927
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
928
- * based on the size of the list container and the number of items fitting within the container.
929
- */
930
- pageSizeRef: React.MutableRefObject<number>;
931
- /**
932
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
933
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
934
- * or the `items` change.
935
- *
936
- * @readonly
937
- */
938
- cursorIndexRef: {
939
- readonly current: number;
940
- };
941
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
942
- UNSTABLE_defaultItemHeight: number;
943
- containerRef: React.RefObject<HTMLDivElement>;
944
- id: string;
945
- orientation: "horizontal" | "vertical";
946
- indexRef: React.MutableRefObject<number>;
947
- nonInteractiveIds: string[];
948
- isVirtualized: boolean;
949
- items: Item<any>[];
950
- }) => boolean) | undefined;
951
- shouldGoToNextPage?: ((data: undefined, state: {
952
- /** The id of the list item the cursor is pointing to */
953
- cursorId: string | string[];
954
- /**
955
- * Any positive non-zero value treats the list like a grid with rows and columns
956
- * @default 0
957
- * @private Use useGridModel instead to make a grid instead of a list
958
- */
959
- columnCount: number;
960
- /**
961
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
962
- * based on the size of the list container and the number of items fitting within the container.
963
- */
964
- pageSizeRef: React.MutableRefObject<number>;
965
- /**
966
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
967
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
968
- * or the `items` change.
969
- *
970
- * @readonly
971
- */
972
- cursorIndexRef: {
973
- readonly current: number;
974
- };
975
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
976
- UNSTABLE_defaultItemHeight: number;
977
- containerRef: React.RefObject<HTMLDivElement>;
978
- id: string;
979
- orientation: "horizontal" | "vertical";
980
- indexRef: React.MutableRefObject<number>;
981
- nonInteractiveIds: string[];
982
- isVirtualized: boolean;
983
- items: Item<any>[];
984
- }) => boolean) | undefined;
985
- shouldGoToPreviousPage?: ((data: undefined, state: {
986
- /** The id of the list item the cursor is pointing to */
987
- cursorId: string | string[];
988
- /**
989
- * Any positive non-zero value treats the list like a grid with rows and columns
990
- * @default 0
991
- * @private Use useGridModel instead to make a grid instead of a list
992
- */
993
- columnCount: number;
994
- /**
995
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
996
- * based on the size of the list container and the number of items fitting within the container.
997
- */
998
- pageSizeRef: React.MutableRefObject<number>;
999
- /**
1000
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
1001
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
1002
- * or the `items` change.
1003
- *
1004
- * @readonly
1005
- */
1006
- cursorIndexRef: {
1007
- readonly current: number;
1008
- };
1009
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
1010
- UNSTABLE_defaultItemHeight: number;
1011
- containerRef: React.RefObject<HTMLDivElement>;
1012
- id: string;
1013
- orientation: "horizontal" | "vertical";
1014
- indexRef: React.MutableRefObject<number>;
1015
- nonInteractiveIds: string[];
1016
- isVirtualized: boolean;
1017
- items: Item<any>[];
1018
- }) => boolean) | undefined;
1019
- shouldRegisterItem?: ((data: {
1020
- id: string;
1021
- textValue: string;
1022
- }, state: {
1023
- /** The id of the list item the cursor is pointing to */
1024
- cursorId: string | string[];
1025
- /**
1026
- * Any positive non-zero value treats the list like a grid with rows and columns
1027
- * @default 0
1028
- * @private Use useGridModel instead to make a grid instead of a list
1029
- */
1030
- columnCount: number;
1031
- /**
1032
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
1033
- * based on the size of the list container and the number of items fitting within the container.
1034
- */
1035
- pageSizeRef: React.MutableRefObject<number>;
1036
- /**
1037
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
1038
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
1039
- * or the `items` change.
1040
- *
1041
- * @readonly
1042
- */
1043
- cursorIndexRef: {
1044
- readonly current: number;
1045
- };
1046
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
1047
- UNSTABLE_defaultItemHeight: number;
1048
- containerRef: React.RefObject<HTMLDivElement>;
1049
- id: string;
1050
- orientation: "horizontal" | "vertical";
1051
- indexRef: React.MutableRefObject<number>;
1052
- nonInteractiveIds: string[];
1053
- isVirtualized: boolean;
1054
- items: Item<any>[];
1055
- }) => boolean) | undefined;
1056
- shouldUnregisterItem?: ((data: {
1057
- id: string;
1058
- }, state: {
1059
- /** The id of the list item the cursor is pointing to */
1060
- cursorId: string | string[];
1061
- /**
1062
- * Any positive non-zero value treats the list like a grid with rows and columns
1063
- * @default 0
1064
- * @private Use useGridModel instead to make a grid instead of a list
1065
- */
1066
- columnCount: number;
1067
- /**
1068
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
1069
- * based on the size of the list container and the number of items fitting within the container.
1070
- */
1071
- pageSizeRef: React.MutableRefObject<number>;
1072
- /**
1073
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
1074
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
1075
- * or the `items` change.
1076
- *
1077
- * @readonly
1078
- */
1079
- cursorIndexRef: {
1080
- readonly current: number;
1081
- };
1082
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
1083
- UNSTABLE_defaultItemHeight: number;
1084
- containerRef: React.RefObject<HTMLDivElement>;
1085
- id: string;
1086
- orientation: "horizontal" | "vertical";
1087
- indexRef: React.MutableRefObject<number>;
1088
- nonInteractiveIds: string[];
1089
- isVirtualized: boolean;
1090
- items: Item<any>[];
1091
- }) => boolean) | undefined;
1092
- shouldUpdateItemHeight?: ((data: {
1093
- value: number;
1094
- }, state: {
1095
- /** The id of the list item the cursor is pointing to */
1096
- cursorId: string | string[];
1097
- /**
1098
- * Any positive non-zero value treats the list like a grid with rows and columns
1099
- * @default 0
1100
- * @private Use useGridModel instead to make a grid instead of a list
1101
- */
1102
- columnCount: number;
1103
- /**
1104
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
1105
- * based on the size of the list container and the number of items fitting within the container.
1106
- */
1107
- pageSizeRef: React.MutableRefObject<number>;
1108
- /**
1109
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
1110
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
1111
- * or the `items` change.
1112
- *
1113
- * @readonly
1114
- */
1115
- cursorIndexRef: {
1116
- readonly current: number;
1117
- };
1118
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
1119
- UNSTABLE_defaultItemHeight: number;
1120
- containerRef: React.RefObject<HTMLDivElement>;
1121
- id: string;
1122
- orientation: "horizontal" | "vertical";
1123
- indexRef: React.MutableRefObject<number>;
1124
- nonInteractiveIds: string[];
1125
- isVirtualized: boolean;
1126
- items: Item<any>[];
1127
- }) => boolean) | undefined;
1128
- }) | undefined) => {
1129
- state: {
1130
- /** The id of the list item the cursor is pointing to */
1131
- cursorId: string | string[];
1132
- /**
1133
- * Any positive non-zero value treats the list like a grid with rows and columns
1134
- * @default 0
1135
- * @private Use useGridModel instead to make a grid instead of a list
1136
- */
1137
- columnCount: number;
1138
- /**
1139
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
1140
- * based on the size of the list container and the number of items fitting within the container.
1141
- */
1142
- pageSizeRef: React.MutableRefObject<number>;
1143
- /**
1144
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
1145
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
1146
- * or the `items` change.
1147
- *
1148
- * @readonly
1149
- */
1150
- cursorIndexRef: {
1151
- readonly current: number;
1152
- };
1153
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
1154
- UNSTABLE_defaultItemHeight: number;
1155
- containerRef: React.RefObject<HTMLDivElement>;
1156
- id: string;
1157
- orientation: "horizontal" | "vertical";
1158
- indexRef: React.MutableRefObject<number>;
1159
- nonInteractiveIds: string[];
1160
- isVirtualized: boolean;
1161
- items: Item<any>[];
1162
- };
1163
- events: {
1164
- /** Directly sets the cursor to the list item by its identifier. */
1165
- goTo(data: {
1166
- id: string;
1167
- }): void;
1168
- /**
1169
- * Set the cursor to the "next" item in the list. This event delegates to the `getNext` method of
1170
- * the navigation manager. For a list, the default navigation manager will wrap if cursor is
1171
- * currently on the last item. For a grid, the default navigation manager will stay on the last
1172
- * item in a row.
1173
- */
1174
- goToNext(): void;
1175
- /**
1176
- * Set the cursor to the "previous" item in the list. If the beginning of the list is detected,
1177
- * it will wrap to the last item
1178
- */
1179
- goToPrevious(): void;
1180
- /**
1181
- * Previous item perpendicular to the orientation of a list, or the previous row in a grid. For
1182
- * example, if a list is horizontal, the previous row would describe an up direction. This could
1183
- * be ignored by the navigation manager, or return the same result as `previous()`. In a grid,
1184
- * this would be the previous row (current position - column count).
1185
- */
1186
- goToPreviousRow(): void;
1187
- /**
1188
- * Next item perpendicular to the orientation of a list, or the next row in a grid. For example,
1189
- * if a list is horizontal, the next row would describe a down direction. This could be ignored by
1190
- * the navigation manager, or return the same result as `next()`. In a grid, this would be the
1191
- * next row (current position + column count).
1192
- */
1193
- goToNextRow(): void;
1194
- /** Set the cursor to the first item in the list */
1195
- goToFirst(): void;
1196
- /** Set the cursor to the last item in the list */
1197
- goToLast(): void;
1198
- goToFirstOfRow(): void;
1199
- goToLastOfRow(): void;
1200
- goToNextPage(): void;
1201
- goToPreviousPage(): void;
1202
- registerItem(data: {
1203
- id: string;
1204
- textValue: string;
1205
- }): void;
1206
- unregisterItem(data: {
1207
- id: string;
1208
- }): void;
1209
- updateItemHeight(data: {
1210
- value: number;
1211
- }): void;
1212
- };
1213
- navigation: NavigationManager;
1214
- getId: (item: any) => string;
1215
- getTextValue: (item: any) => string;
1216
- }) & import("@workday/canvas-kit-react/common").ModelExtras<{
1217
- /**
1218
- * Initial cursor position. If not provided, the cursor will point to the first item in the list
1219
- */
1220
- initialCursorId: string | string[];
1221
- /**
1222
- * If this is set it will cause a wrapping of a list that will turn it into a grid
1223
- * @default 0
1224
- */
1225
- columnCount: number;
1226
- /**
1227
- * Controls the state changes when the user sends navigation events to the model. For example,
1228
- * when the user hits the "right" arrow, a behavior hook will determine directionality
1229
- * (left-to-right or right-to-left) and call the correct navigation method. In our example, a
1230
- * left-to-right language would send a `getNext`. The navigation manager may return the next item
1231
- * in the list. Different managers can be created for slightly different use cases. The default
1232
- * navigation manager will accept `orientation` and directionality to determine mapping.
1233
- *
1234
- * An example override might be a tab list with an overflow menu that is meant to be transparent
1235
- * to screen reader users. This would require the overflow menu to accept both up/down keys as
1236
- * well as left/right keys to give a more consistent experience to all users.
1237
- */
1238
- navigation: NavigationManager;
1239
- /**
1240
- * Controls how much a pageUp/pageDown navigation request will jump. If not provided, the size
1241
- * of the list and number of items rendered will determine this value.
1242
- */
1243
- pageSize: number;
1244
- id: string;
1245
- getId: (item: any) => string;
1246
- getTextValue: (item: any) => string;
1247
- nonInteractiveIds: string[];
1248
- orientation: import("./useBaseListModel").Orientation;
1249
- defaultItemHeight: number;
1250
- shouldVirtualize: boolean;
1251
- items: any[];
1252
- }, {}, {
1253
- /** The id of the list item the cursor is pointing to */
1254
- cursorId: string | string[];
1255
- /**
1256
- * Any positive non-zero value treats the list like a grid with rows and columns
1257
- * @default 0
1258
- * @private Use useGridModel instead to make a grid instead of a list
1259
- */
1260
- columnCount: number;
1261
- /**
1262
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
1263
- * based on the size of the list container and the number of items fitting within the container.
1264
- */
1265
- pageSizeRef: React.MutableRefObject<number>;
1266
- /**
1267
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
1268
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
1269
- * or the `items` change.
1270
- *
1271
- * @readonly
1272
- */
1273
- cursorIndexRef: {
1274
- readonly current: number;
1275
- };
1276
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
1277
- UNSTABLE_defaultItemHeight: number;
1278
- containerRef: React.RefObject<HTMLDivElement>;
1279
- id: string;
1280
- orientation: "horizontal" | "vertical";
1281
- indexRef: React.MutableRefObject<number>;
1282
- nonInteractiveIds: string[];
1283
- isVirtualized: boolean;
1284
- items: Item<any>[];
1285
- }, {
1286
- /** Directly sets the cursor to the list item by its identifier. */
1287
- goTo(data: {
1288
- id: string;
1289
- }): void;
1290
- /**
1291
- * Set the cursor to the "next" item in the list. This event delegates to the `getNext` method of
1292
- * the navigation manager. For a list, the default navigation manager will wrap if cursor is
1293
- * currently on the last item. For a grid, the default navigation manager will stay on the last
1294
- * item in a row.
1295
- */
1296
- goToNext(): void;
1297
- /**
1298
- * Set the cursor to the "previous" item in the list. If the beginning of the list is detected,
1299
- * it will wrap to the last item
1300
- */
1301
- goToPrevious(): void;
1302
- /**
1303
- * Previous item perpendicular to the orientation of a list, or the previous row in a grid. For
1304
- * example, if a list is horizontal, the previous row would describe an up direction. This could
1305
- * be ignored by the navigation manager, or return the same result as `previous()`. In a grid,
1306
- * this would be the previous row (current position - column count).
1307
- */
1308
- goToPreviousRow(): void;
1309
- /**
1310
- * Next item perpendicular to the orientation of a list, or the next row in a grid. For example,
1311
- * if a list is horizontal, the next row would describe a down direction. This could be ignored by
1312
- * the navigation manager, or return the same result as `next()`. In a grid, this would be the
1313
- * next row (current position + column count).
1314
- */
1315
- goToNextRow(): void;
1316
- /** Set the cursor to the first item in the list */
1317
- goToFirst(): void;
1318
- /** Set the cursor to the last item in the list */
1319
- goToLast(): void;
1320
- goToFirstOfRow(): void;
1321
- goToLastOfRow(): void;
1322
- goToNextPage(): void;
1323
- goToPreviousPage(): void;
1324
- registerItem(data: {
1325
- id: string;
1326
- textValue: string;
1327
- }): void;
1328
- unregisterItem(data: {
1329
- id: string;
1330
- }): void;
1331
- updateItemHeight(data: {
1332
- value: number;
1333
- }): void;
1334
- }, {
1335
- state: {
1336
- /** The id of the list item the cursor is pointing to */
1337
- cursorId: string | string[];
1338
- /**
1339
- * Any positive non-zero value treats the list like a grid with rows and columns
1340
- * @default 0
1341
- * @private Use useGridModel instead to make a grid instead of a list
1342
- */
1343
- columnCount: number;
1344
- /**
1345
- * A React.Ref of the current page size. Either provided as config, or determined at runtime
1346
- * based on the size of the list container and the number of items fitting within the container.
1347
- */
1348
- pageSizeRef: React.MutableRefObject<number>;
1349
- /**
1350
- * A readonly [React.Ref](https://react.dev/learn/referencing-values-with-refs) that tracks the
1351
- * index of the `state.cursorId`. This value is automatically updated when the `state.cursorId`
1352
- * or the `items` change.
1353
- *
1354
- * @readonly
1355
- */
1356
- cursorIndexRef: {
1357
- readonly current: number;
1358
- };
1359
- UNSTABLE_virtual: import("@tanstack/virtual-core").Virtualizer<HTMLDivElement, Element>;
1360
- UNSTABLE_defaultItemHeight: number;
1361
- containerRef: React.RefObject<HTMLDivElement>;
1362
- id: string;
1363
- orientation: "horizontal" | "vertical";
1364
- indexRef: React.MutableRefObject<number>;
1365
- nonInteractiveIds: string[];
1366
- isVirtualized: boolean;
1367
- items: Item<any>[];
1368
- };
1369
- events: {
1370
- /** Directly sets the cursor to the list item by its identifier. */
1371
- goTo(data: {
1372
- id: string;
1373
- }): void;
1374
- /**
1375
- * Set the cursor to the "next" item in the list. This event delegates to the `getNext` method of
1376
- * the navigation manager. For a list, the default navigation manager will wrap if cursor is
1377
- * currently on the last item. For a grid, the default navigation manager will stay on the last
1378
- * item in a row.
1379
- */
1380
- goToNext(): void;
1381
- /**
1382
- * Set the cursor to the "previous" item in the list. If the beginning of the list is detected,
1383
- * it will wrap to the last item
1384
- */
1385
- goToPrevious(): void;
1386
- /**
1387
- * Previous item perpendicular to the orientation of a list, or the previous row in a grid. For
1388
- * example, if a list is horizontal, the previous row would describe an up direction. This could
1389
- * be ignored by the navigation manager, or return the same result as `previous()`. In a grid,
1390
- * this would be the previous row (current position - column count).
1391
- */
1392
- goToPreviousRow(): void;
1393
- /**
1394
- * Next item perpendicular to the orientation of a list, or the next row in a grid. For example,
1395
- * if a list is horizontal, the next row would describe a down direction. This could be ignored by
1396
- * the navigation manager, or return the same result as `next()`. In a grid, this would be the
1397
- * next row (current position + column count).
1398
- */
1399
- goToNextRow(): void;
1400
- /** Set the cursor to the first item in the list */
1401
- goToFirst(): void;
1402
- /** Set the cursor to the last item in the list */
1403
- goToLast(): void;
1404
- goToFirstOfRow(): void;
1405
- goToLastOfRow(): void;
1406
- goToNextPage(): void;
1407
- goToPreviousPage(): void;
1408
- registerItem(data: {
1409
- id: string;
1410
- textValue: string;
1411
- }): void;
1412
- unregisterItem(data: {
1413
- id: string;
1414
- }): void;
1415
- updateItemHeight(data: {
1416
- value: number;
1417
- }): void;
1418
- };
1419
- navigation: NavigationManager;
1420
- getId: (item: any) => string;
1421
- getTextValue: (item: any) => string;
1422
- }>;
1423
- export {};
1424
- //# sourceMappingURL=useCursorListModel.d.ts.map