@dxos/react-ui-list 0.9.0 → 0.9.1-main.c7dcc2e112

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 (110) hide show
  1. package/dist/lib/browser/index.mjs +993 -521
  2. package/dist/lib/browser/index.mjs.map +4 -4
  3. package/dist/lib/browser/meta.json +1 -1
  4. package/dist/lib/node-esm/index.mjs +993 -521
  5. package/dist/lib/node-esm/index.mjs.map +4 -4
  6. package/dist/lib/node-esm/meta.json +1 -1
  7. package/dist/types/src/aspects/index.d.ts +6 -0
  8. package/dist/types/src/aspects/index.d.ts.map +1 -0
  9. package/dist/types/src/aspects/useListDisclosure.d.ts +60 -0
  10. package/dist/types/src/aspects/useListDisclosure.d.ts.map +1 -0
  11. package/dist/types/src/aspects/useListDisclosure.test.d.ts +2 -0
  12. package/dist/types/src/aspects/useListDisclosure.test.d.ts.map +1 -0
  13. package/dist/types/src/aspects/useListGrid.d.ts +30 -0
  14. package/dist/types/src/aspects/useListGrid.d.ts.map +1 -0
  15. package/dist/types/src/aspects/useListGrid.test.d.ts +2 -0
  16. package/dist/types/src/aspects/useListGrid.test.d.ts.map +1 -0
  17. package/dist/types/src/aspects/useListNavigation.d.ts +68 -0
  18. package/dist/types/src/aspects/useListNavigation.d.ts.map +1 -0
  19. package/dist/types/src/aspects/useListNavigation.test.d.ts +2 -0
  20. package/dist/types/src/aspects/useListNavigation.test.d.ts.map +1 -0
  21. package/dist/types/src/aspects/useListSelection.d.ts +48 -0
  22. package/dist/types/src/aspects/useListSelection.d.ts.map +1 -0
  23. package/dist/types/src/aspects/useListSelection.test.d.ts +2 -0
  24. package/dist/types/src/aspects/useListSelection.test.d.ts.map +1 -0
  25. package/dist/types/src/aspects/useReorder.d.ts +103 -0
  26. package/dist/types/src/aspects/useReorder.d.ts.map +1 -0
  27. package/dist/types/src/components/Accordion/Accordion.d.ts +1 -1
  28. package/dist/types/src/components/Accordion/AccordionItem.d.ts +5 -3
  29. package/dist/types/src/components/Accordion/AccordionItem.d.ts.map +1 -1
  30. package/dist/types/src/components/Accordion/AccordionRoot.d.ts +1 -1
  31. package/dist/types/src/components/Accordion/AccordionRoot.d.ts.map +1 -1
  32. package/dist/types/src/components/Listbox/Listbox.d.ts +60 -20
  33. package/dist/types/src/components/Listbox/Listbox.d.ts.map +1 -1
  34. package/dist/types/src/components/Listbox/Listbox.stories.d.ts +27 -3
  35. package/dist/types/src/components/Listbox/Listbox.stories.d.ts.map +1 -1
  36. package/dist/types/src/components/OrderedList/OrderedList.d.ts +49 -0
  37. package/dist/types/src/components/OrderedList/OrderedList.d.ts.map +1 -0
  38. package/dist/types/src/components/OrderedList/OrderedList.stories.d.ts +11 -0
  39. package/dist/types/src/components/OrderedList/OrderedList.stories.d.ts.map +1 -0
  40. package/dist/types/src/components/OrderedList/OrderedList.test.d.ts +2 -0
  41. package/dist/types/src/components/OrderedList/OrderedList.test.d.ts.map +1 -0
  42. package/dist/types/src/components/OrderedList/OrderedListItem.d.ts +94 -0
  43. package/dist/types/src/components/OrderedList/OrderedListItem.d.ts.map +1 -0
  44. package/dist/types/src/components/OrderedList/OrderedListRoot.d.ts +73 -0
  45. package/dist/types/src/components/OrderedList/OrderedListRoot.d.ts.map +1 -0
  46. package/dist/types/src/components/OrderedList/index.d.ts +2 -0
  47. package/dist/types/src/components/OrderedList/index.d.ts.map +1 -0
  48. package/dist/types/src/components/Tree/TreeItem.d.ts.map +1 -1
  49. package/dist/types/src/components/Tree/TreeItemHeading.d.ts.map +1 -1
  50. package/dist/types/src/components/index.d.ts +1 -2
  51. package/dist/types/src/components/index.d.ts.map +1 -1
  52. package/dist/types/src/index.d.ts +1 -0
  53. package/dist/types/src/index.d.ts.map +1 -1
  54. package/dist/types/src/vitest-setup.d.ts +2 -0
  55. package/dist/types/src/vitest-setup.d.ts.map +1 -0
  56. package/dist/types/tsconfig.tsbuildinfo +1 -1
  57. package/package.json +18 -15
  58. package/src/aspects/index.ts +9 -0
  59. package/src/aspects/useListDisclosure.test.ts +72 -0
  60. package/src/aspects/useListDisclosure.ts +160 -0
  61. package/src/aspects/useListGrid.test.ts +41 -0
  62. package/src/aspects/useListGrid.ts +61 -0
  63. package/src/aspects/useListNavigation.test.ts +44 -0
  64. package/src/aspects/useListNavigation.ts +160 -0
  65. package/src/aspects/useListSelection.test.ts +101 -0
  66. package/src/aspects/useListSelection.ts +162 -0
  67. package/src/aspects/useReorder.ts +370 -0
  68. package/src/components/Accordion/Accordion.stories.tsx +1 -1
  69. package/src/components/Accordion/AccordionItem.tsx +11 -6
  70. package/src/components/Accordion/AccordionRoot.tsx +4 -1
  71. package/src/components/Listbox/Listbox.stories.tsx +171 -21
  72. package/src/components/Listbox/Listbox.tsx +302 -145
  73. package/src/components/OrderedList/OrderedList.stories.tsx +379 -0
  74. package/src/components/OrderedList/OrderedList.test.tsx +59 -0
  75. package/src/components/OrderedList/OrderedList.tsx +63 -0
  76. package/src/components/OrderedList/OrderedListItem.tsx +348 -0
  77. package/src/components/OrderedList/OrderedListRoot.tsx +173 -0
  78. package/src/components/OrderedList/index.ts +5 -0
  79. package/src/components/Tree/TreeItem.tsx +2 -0
  80. package/src/components/Tree/TreeItemHeading.tsx +1 -2
  81. package/src/components/index.ts +1 -2
  82. package/src/index.ts +1 -0
  83. package/src/vitest-setup.ts +11 -0
  84. package/dist/types/src/components/List/List.d.ts +0 -40
  85. package/dist/types/src/components/List/List.d.ts.map +0 -1
  86. package/dist/types/src/components/List/List.stories.d.ts +0 -18
  87. package/dist/types/src/components/List/List.stories.d.ts.map +0 -1
  88. package/dist/types/src/components/List/ListItem.d.ts +0 -49
  89. package/dist/types/src/components/List/ListItem.d.ts.map +0 -1
  90. package/dist/types/src/components/List/ListRoot.d.ts +0 -29
  91. package/dist/types/src/components/List/ListRoot.d.ts.map +0 -1
  92. package/dist/types/src/components/List/index.d.ts +0 -2
  93. package/dist/types/src/components/List/index.d.ts.map +0 -1
  94. package/dist/types/src/components/List/testing.d.ts +0 -15
  95. package/dist/types/src/components/List/testing.d.ts.map +0 -1
  96. package/dist/types/src/components/RowList/RowList.d.ts +0 -61
  97. package/dist/types/src/components/RowList/RowList.d.ts.map +0 -1
  98. package/dist/types/src/components/RowList/RowList.stories.d.ts +0 -35
  99. package/dist/types/src/components/RowList/RowList.stories.d.ts.map +0 -1
  100. package/dist/types/src/components/RowList/index.d.ts +0 -3
  101. package/dist/types/src/components/RowList/index.d.ts.map +0 -1
  102. package/src/components/List/List.stories.tsx +0 -129
  103. package/src/components/List/List.tsx +0 -47
  104. package/src/components/List/ListItem.tsx +0 -287
  105. package/src/components/List/ListRoot.tsx +0 -106
  106. package/src/components/List/index.ts +0 -5
  107. package/src/components/List/testing.ts +0 -31
  108. package/src/components/RowList/RowList.stories.tsx +0 -163
  109. package/src/components/RowList/RowList.tsx +0 -350
  110. package/src/components/RowList/index.ts +0 -6
@@ -1 +1 @@
1
- {"inputs":{"src/components/Accordion/AccordionRoot.tsx":{"bytes":4328,"imports":[{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/components/Accordion/AccordionItem.tsx":{"bytes":7039,"imports":[{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Accordion/AccordionRoot.tsx","kind":"import-statement","original":"./AccordionRoot"}],"format":"esm"},"src/components/Accordion/Accordion.tsx":{"bytes":1825,"imports":[{"path":"src/components/Accordion/AccordionItem.tsx","kind":"import-statement","original":"./AccordionItem"},{"path":"src/components/Accordion/AccordionRoot.tsx","kind":"import-statement","original":"./AccordionRoot"}],"format":"esm"},"src/components/Accordion/index.ts":{"bytes":377,"imports":[{"path":"src/components/Accordion/Accordion.tsx","kind":"import-statement","original":"./Accordion"}],"format":"esm"},"src/components/Picker/context.ts":{"bytes":3388,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true}],"format":"esm"},"src/components/Picker/Picker.tsx":{"bytes":35992,"imports":[{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Picker/context.ts","kind":"import-statement","original":"./context"},{"path":"src/components/Picker/context.ts","kind":"import-statement","original":"./context"}],"format":"esm"},"src/components/Picker/index.ts":{"bytes":732,"imports":[{"path":"src/components/Picker/Picker.tsx","kind":"import-statement","original":"./Picker"}],"format":"esm"},"src/components/Combobox/Combobox.tsx":{"bytes":28470,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-use-controllable-state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Picker/index.ts","kind":"import-statement","original":"../Picker"}],"format":"esm"},"src/components/Combobox/index.ts":{"bytes":376,"imports":[{"path":"src/components/Combobox/Combobox.tsx","kind":"import-statement","original":"./Combobox"}],"format":"esm"},"src/components/List/ListRoot.tsx":{"bytes":10678,"imports":[{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/closest-edge","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/util/get-reorder-destination-index","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"src/components/List/ListItem.tsx","kind":"import-statement","original":"./ListItem"}],"format":"esm"},"src/components/List/ListItem.tsx":{"bytes":26828,"imports":[{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/closest-edge","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/set-custom-native-drag-preview","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/List/ListRoot.tsx","kind":"import-statement","original":"./ListRoot"}],"format":"esm"},"src/components/List/List.tsx":{"bytes":4225,"imports":[{"path":"src/components/List/ListItem.tsx","kind":"import-statement","original":"./ListItem"},{"path":"src/components/List/ListRoot.tsx","kind":"import-statement","original":"./ListRoot"}],"format":"esm"},"src/components/List/index.ts":{"bytes":368,"imports":[{"path":"src/components/List/List.tsx","kind":"import-statement","original":"./List"}],"format":"esm"},"src/components/RowList/RowList.tsx":{"bytes":34627,"imports":[{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-use-controllable-state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-list","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"format":"esm"},"src/components/RowList/index.ts":{"bytes":787,"imports":[{"path":"src/components/RowList/RowList.tsx","kind":"import-statement","original":"./RowList"}],"format":"esm"},"src/components/Listbox/Listbox.tsx":{"bytes":17900,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/RowList/index.ts","kind":"import-statement","original":"../RowList"}],"format":"esm"},"src/components/Listbox/index.ts":{"bytes":375,"imports":[{"path":"src/components/Listbox/Listbox.tsx","kind":"import-statement","original":"./Listbox"}],"format":"esm"},"src/components/Tree/TreeContext.tsx":{"bytes":3370,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true}],"format":"esm"},"src/components/Tree/helpers.ts":{"bytes":1072,"imports":[],"format":"esm"},"src/components/Tree/TreeItemHeading.tsx":{"bytes":10658,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-text-tooltip","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/components/Tree/TreeItemToggle.tsx":{"bytes":3702,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"format":"esm"},"src/components/Tree/TreeItem.tsx":{"bytes":40141,"imports":[{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/tree-item","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Schema","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Tree/helpers.ts","kind":"import-statement","original":"./helpers"},{"path":"src/components/Tree/TreeContext.tsx","kind":"import-statement","original":"./TreeContext"},{"path":"src/components/Tree/TreeItemHeading.tsx","kind":"import-statement","original":"./TreeItemHeading"},{"path":"src/components/Tree/TreeItemToggle.tsx","kind":"import-statement","original":"./TreeItemToggle"}],"format":"esm"},"src/components/Tree/Tree.tsx":{"bytes":5746,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"src/components/Tree/TreeContext.tsx","kind":"import-statement","original":"./TreeContext"},{"path":"src/components/Tree/TreeItem.tsx","kind":"import-statement","original":"./TreeItem"}],"format":"esm"},"src/components/Tree/index.ts":{"bytes":744,"imports":[{"path":"src/components/Tree/Tree.tsx","kind":"import-statement","original":"./Tree"},{"path":"src/components/Tree/TreeContext.tsx","kind":"import-statement","original":"./TreeContext"},{"path":"src/components/Tree/TreeItem.tsx","kind":"import-statement","original":"./TreeItem"},{"path":"src/components/Tree/TreeItemToggle.tsx","kind":"import-statement","original":"./TreeItemToggle"},{"path":"src/components/Tree/helpers.ts","kind":"import-statement","original":"./helpers"}],"format":"esm"},"src/components/index.ts":{"bytes":877,"imports":[{"path":"src/components/Accordion/index.ts","kind":"import-statement","original":"./Accordion"},{"path":"src/components/Combobox/index.ts","kind":"import-statement","original":"./Combobox"},{"path":"src/components/List/index.ts","kind":"import-statement","original":"./List"},{"path":"src/components/Listbox/index.ts","kind":"import-statement","original":"./Listbox"},{"path":"src/components/Picker/index.ts","kind":"import-statement","original":"./Picker"},{"path":"src/components/RowList/index.ts","kind":"import-statement","original":"./RowList"},{"path":"src/components/Tree/index.ts","kind":"import-statement","original":"./Tree"}],"format":"esm"},"src/util/path.ts":{"bytes":3321,"imports":[],"format":"esm"},"src/util/index.ts":{"bytes":368,"imports":[{"path":"src/util/path.ts","kind":"import-statement","original":"./path"}],"format":"esm"},"src/index.ts":{"bytes":458,"imports":[{"path":"src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"src/util/index.ts","kind":"import-statement","original":"./util"}],"format":"esm"}},"outputs":{"dist/lib/node-esm/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":125529},"dist/lib/node-esm/index.mjs":{"imports":[{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-use-controllable-state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/closest-edge","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/set-custom-native-drag-preview","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react-dom","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/closest-edge","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/util/get-reorder-destination-index","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-use-controllable-state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-list","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/tree-item","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Schema","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-text-tooltip","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"exports":["Accordion","Combobox","DEFAULT_INDENTATION","List","Listbox","Path","Picker","Row","RowList","Tree","TreeDataSchema","TreeItem","TreeItemById","TreeItemToggle","TreeProvider","createListboxScope","createRowListScope","isTreeData","paddingIndentation","usePickerInputContext","usePickerItemContext","useRowListSelection","useTree"],"entryPoint":"src/index.ts","inputs":{"src/components/Accordion/AccordionItem.tsx":{"bytesInOutput":1655},"src/components/Accordion/AccordionRoot.tsx":{"bytesInOutput":750},"src/components/Accordion/Accordion.tsx":{"bytesInOutput":132},"src/components/Accordion/index.ts":{"bytesInOutput":0},"src/components/index.ts":{"bytesInOutput":0},"src/components/Combobox/Combobox.tsx":{"bytesInOutput":6383},"src/components/Picker/Picker.tsx":{"bytesInOutput":7914},"src/components/Picker/context.ts":{"bytesInOutput":250},"src/components/Picker/index.ts":{"bytesInOutput":0},"src/components/Combobox/index.ts":{"bytesInOutput":0},"src/components/List/ListItem.tsx":{"bytesInOutput":7010},"src/components/List/ListRoot.tsx":{"bytesInOutput":2247},"src/components/List/List.tsx":{"bytesInOutput":269},"src/components/List/index.ts":{"bytesInOutput":0},"src/components/Listbox/Listbox.tsx":{"bytesInOutput":3064},"src/components/RowList/RowList.tsx":{"bytesInOutput":4393},"src/components/RowList/index.ts":{"bytesInOutput":0},"src/components/Listbox/index.ts":{"bytesInOutput":0},"src/components/Tree/Tree.tsx":{"bytesInOutput":1213},"src/components/Tree/TreeContext.tsx":{"bytesInOutput":293},"src/components/Tree/TreeItem.tsx":{"bytesInOutput":10189},"src/components/Tree/helpers.ts":{"bytesInOutput":162},"src/components/Tree/TreeItemHeading.tsx":{"bytesInOutput":2583},"src/components/Tree/TreeItemToggle.tsx":{"bytesInOutput":885},"src/components/Tree/index.ts":{"bytesInOutput":0},"src/index.ts":{"bytesInOutput":0},"src/util/path.ts":{"bytesInOutput":678},"src/util/index.ts":{"bytesInOutput":0}},"bytes":51523}}}
1
+ {"inputs":{"src/aspects/useListDisclosure.ts":{"bytes":15027,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"src/aspects/useListGrid.ts":{"bytes":5509,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"src/aspects/useListNavigation.ts":{"bytes":14216,"imports":[{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"src/aspects/useListSelection.ts":{"bytes":16169,"imports":[{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"src/aspects/useReorder.ts":{"bytes":41843,"imports":[{"path":"@atlaskit/pragmatic-drag-and-drop-auto-scroll/element","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/closest-edge","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/util/get-reorder-destination-index","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/set-custom-native-drag-preview","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"src/aspects/index.ts":{"bytes":811,"imports":[{"path":"src/aspects/useListDisclosure.ts","kind":"import-statement","original":"./useListDisclosure"},{"path":"src/aspects/useListGrid.ts","kind":"import-statement","original":"./useListGrid"},{"path":"src/aspects/useListNavigation.ts","kind":"import-statement","original":"./useListNavigation"},{"path":"src/aspects/useListSelection.ts","kind":"import-statement","original":"./useListSelection"},{"path":"src/aspects/useReorder.ts","kind":"import-statement","original":"./useReorder"}],"format":"esm"},"src/components/Accordion/AccordionRoot.tsx":{"bytes":4624,"imports":[{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/components/Accordion/AccordionItem.tsx":{"bytes":8023,"imports":[{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Accordion/AccordionRoot.tsx","kind":"import-statement","original":"./AccordionRoot"}],"format":"esm"},"src/components/Accordion/Accordion.tsx":{"bytes":1825,"imports":[{"path":"src/components/Accordion/AccordionItem.tsx","kind":"import-statement","original":"./AccordionItem"},{"path":"src/components/Accordion/AccordionRoot.tsx","kind":"import-statement","original":"./AccordionRoot"}],"format":"esm"},"src/components/Accordion/index.ts":{"bytes":377,"imports":[{"path":"src/components/Accordion/Accordion.tsx","kind":"import-statement","original":"./Accordion"}],"format":"esm"},"src/components/Picker/context.ts":{"bytes":3388,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true}],"format":"esm"},"src/components/Picker/Picker.tsx":{"bytes":35992,"imports":[{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Picker/context.ts","kind":"import-statement","original":"./context"},{"path":"src/components/Picker/context.ts","kind":"import-statement","original":"./context"}],"format":"esm"},"src/components/Picker/index.ts":{"bytes":732,"imports":[{"path":"src/components/Picker/Picker.tsx","kind":"import-statement","original":"./Picker"}],"format":"esm"},"src/components/Combobox/Combobox.tsx":{"bytes":28470,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-use-controllable-state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Picker/index.ts","kind":"import-statement","original":"../Picker"}],"format":"esm"},"src/components/Combobox/index.ts":{"bytes":376,"imports":[{"path":"src/components/Combobox/Combobox.tsx","kind":"import-statement","original":"./Combobox"}],"format":"esm"},"src/components/Listbox/Listbox.tsx":{"bytes":32498,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-list","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/aspects/index.ts","kind":"import-statement","original":"../../aspects"}],"format":"esm"},"src/components/Listbox/index.ts":{"bytes":375,"imports":[{"path":"src/components/Listbox/Listbox.tsx","kind":"import-statement","original":"./Listbox"}],"format":"esm"},"src/components/OrderedList/OrderedListRoot.tsx":{"bytes":14576,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/aspects/index.ts","kind":"import-statement","original":"../../aspects"}],"format":"esm"},"src/components/OrderedList/OrderedListItem.tsx":{"bytes":31854,"imports":[{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/aspects/index.ts","kind":"import-statement","original":"../../aspects"},{"path":"src/components/OrderedList/OrderedListRoot.tsx","kind":"import-statement","original":"./OrderedListRoot"}],"format":"esm"},"src/components/OrderedList/OrderedList.tsx":{"bytes":5420,"imports":[{"path":"src/components/OrderedList/OrderedListItem.tsx","kind":"import-statement","original":"./OrderedListItem"},{"path":"src/components/OrderedList/OrderedListRoot.tsx","kind":"import-statement","original":"./OrderedListRoot"}],"format":"esm"},"src/components/OrderedList/index.ts":{"bytes":387,"imports":[{"path":"src/components/OrderedList/OrderedList.tsx","kind":"import-statement","original":"./OrderedList"}],"format":"esm"},"src/components/Tree/TreeContext.tsx":{"bytes":3370,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true}],"format":"esm"},"src/components/Tree/helpers.ts":{"bytes":1072,"imports":[],"format":"esm"},"src/components/Tree/TreeItemHeading.tsx":{"bytes":10524,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/components/Tree/TreeItemToggle.tsx":{"bytes":3702,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"format":"esm"},"src/components/Tree/TreeItem.tsx":{"bytes":40530,"imports":[{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/tree-item","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Schema","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/components/Tree/helpers.ts","kind":"import-statement","original":"./helpers"},{"path":"src/components/Tree/TreeContext.tsx","kind":"import-statement","original":"./TreeContext"},{"path":"src/components/Tree/TreeItemHeading.tsx","kind":"import-statement","original":"./TreeItemHeading"},{"path":"src/components/Tree/TreeItemToggle.tsx","kind":"import-statement","original":"./TreeItemToggle"}],"format":"esm"},"src/components/Tree/Tree.tsx":{"bytes":5746,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"src/components/Tree/TreeContext.tsx","kind":"import-statement","original":"./TreeContext"},{"path":"src/components/Tree/TreeItem.tsx","kind":"import-statement","original":"./TreeItem"}],"format":"esm"},"src/components/Tree/index.ts":{"bytes":744,"imports":[{"path":"src/components/Tree/Tree.tsx","kind":"import-statement","original":"./Tree"},{"path":"src/components/Tree/TreeContext.tsx","kind":"import-statement","original":"./TreeContext"},{"path":"src/components/Tree/TreeItem.tsx","kind":"import-statement","original":"./TreeItem"},{"path":"src/components/Tree/TreeItemToggle.tsx","kind":"import-statement","original":"./TreeItemToggle"},{"path":"src/components/Tree/helpers.ts","kind":"import-statement","original":"./helpers"}],"format":"esm"},"src/components/index.ts":{"bytes":813,"imports":[{"path":"src/components/Accordion/index.ts","kind":"import-statement","original":"./Accordion"},{"path":"src/components/Combobox/index.ts","kind":"import-statement","original":"./Combobox"},{"path":"src/components/Listbox/index.ts","kind":"import-statement","original":"./Listbox"},{"path":"src/components/OrderedList/index.ts","kind":"import-statement","original":"./OrderedList"},{"path":"src/components/Picker/index.ts","kind":"import-statement","original":"./Picker"},{"path":"src/components/Tree/index.ts","kind":"import-statement","original":"./Tree"}],"format":"esm"},"src/util/path.ts":{"bytes":3321,"imports":[],"format":"esm"},"src/util/index.ts":{"bytes":368,"imports":[{"path":"src/util/path.ts","kind":"import-statement","original":"./path"}],"format":"esm"},"src/index.ts":{"bytes":545,"imports":[{"path":"src/aspects/index.ts","kind":"import-statement","original":"./aspects"},{"path":"src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"src/util/index.ts","kind":"import-statement","original":"./util"}],"format":"esm"}},"outputs":{"dist/lib/node-esm/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":171471},"dist/lib/node-esm/index.mjs":{"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-auto-scroll/element","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/closest-edge","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/util/get-reorder-destination-index","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/set-custom-native-drag-preview","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-accordion","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-use-controllable-state","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-list","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@radix-ui/react-context","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/debug","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop-hitbox/tree-item","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/combine","kind":"import-statement","external":true},{"path":"@atlaskit/pragmatic-drag-and-drop/element/adapter","kind":"import-statement","external":true},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Schema","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true}],"exports":["Accordion","Combobox","DEFAULT_INDENTATION","Listbox","OrderedList","Path","Picker","Tree","TreeDataSchema","TreeItem","TreeItemById","TreeItemToggle","TreeProvider","isTreeData","paddingIndentation","useListDisclosure","useListGrid","useListNavigation","useListSelection","useListboxSelection","usePickerInputContext","usePickerItemContext","useReorderAutoScroll","useReorderItem","useReorderList","useTree"],"entryPoint":"src/index.ts","inputs":{"src/aspects/useListDisclosure.ts":{"bytesInOutput":2237},"src/aspects/index.ts":{"bytesInOutput":0},"src/aspects/useListGrid.ts":{"bytesInOutput":701},"src/aspects/useListNavigation.ts":{"bytesInOutput":1803},"src/aspects/useListSelection.ts":{"bytesInOutput":2749},"src/aspects/useReorder.ts":{"bytesInOutput":8249},"src/index.ts":{"bytesInOutput":0},"src/components/Accordion/AccordionItem.tsx":{"bytesInOutput":1867},"src/components/Accordion/AccordionRoot.tsx":{"bytesInOutput":750},"src/components/Accordion/Accordion.tsx":{"bytesInOutput":132},"src/components/Accordion/index.ts":{"bytesInOutput":0},"src/components/index.ts":{"bytesInOutput":0},"src/components/Combobox/Combobox.tsx":{"bytesInOutput":6394},"src/components/Picker/Picker.tsx":{"bytesInOutput":7997},"src/components/Picker/context.ts":{"bytesInOutput":250},"src/components/Picker/index.ts":{"bytesInOutput":0},"src/components/Combobox/index.ts":{"bytesInOutput":0},"src/components/Listbox/Listbox.tsx":{"bytesInOutput":4694},"src/components/Listbox/index.ts":{"bytesInOutput":0},"src/components/OrderedList/OrderedListItem.tsx":{"bytesInOutput":6106},"src/components/OrderedList/OrderedListRoot.tsx":{"bytesInOutput":2175},"src/components/OrderedList/OrderedList.tsx":{"bytesInOutput":354},"src/components/OrderedList/index.ts":{"bytesInOutput":0},"src/components/Tree/Tree.tsx":{"bytesInOutput":1213},"src/components/Tree/TreeContext.tsx":{"bytesInOutput":293},"src/components/Tree/TreeItem.tsx":{"bytesInOutput":10386},"src/components/Tree/helpers.ts":{"bytesInOutput":162},"src/components/Tree/TreeItemHeading.tsx":{"bytesInOutput":2537},"src/components/Tree/TreeItemToggle.tsx":{"bytesInOutput":883},"src/components/Tree/index.ts":{"bytesInOutput":0},"src/util/path.ts":{"bytesInOutput":678},"src/util/index.ts":{"bytesInOutput":0}},"bytes":64294}}}
@@ -0,0 +1,6 @@
1
+ export * from './useListDisclosure';
2
+ export * from './useListGrid';
3
+ export * from './useListNavigation';
4
+ export * from './useListSelection';
5
+ export * from './useReorder';
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/aspects/index.ts"],"names":[],"mappings":"AAIA,cAAc,qBAAqB,CAAC;AACpC,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,cAAc,CAAC"}
@@ -0,0 +1,60 @@
1
+ import { type MouseEvent } from 'react';
2
+ export type ListDisclosureMode = 'single' | 'multi';
3
+ type SingleValue = string | undefined;
4
+ type MultiValue = ReadonlySet<string>;
5
+ type ValueFor<M extends ListDisclosureMode> = M extends 'single' ? SingleValue : MultiValue;
6
+ export type UseListDisclosureOptions<M extends ListDisclosureMode = ListDisclosureMode> = {
7
+ mode: M;
8
+ /** Controlled value: a single id (single mode) or a set of ids (multi mode). */
9
+ value?: ValueFor<M>;
10
+ defaultValue?: ValueFor<M>;
11
+ /** Called whenever the disclosure value changes. */
12
+ onValueChange?: (next: ValueFor<M>) => void;
13
+ };
14
+ export type DisclosureItemBinding = {
15
+ expanded: boolean;
16
+ toggle: () => void;
17
+ /** Stable id on the disclosure trigger; the controlled panel references it via aria-labelledby. */
18
+ triggerId: string;
19
+ /** Stable id on the controlled panel; the trigger references it via aria-controls. */
20
+ panelId: string;
21
+ /** Spread onto the trigger element (button, title row, …). */
22
+ triggerProps: {
23
+ id: string;
24
+ 'aria-expanded': boolean;
25
+ 'aria-controls': string;
26
+ onClick: (event: MouseEvent) => void;
27
+ };
28
+ /** Spread onto the disclosed panel; carries role=region for SR navigation. */
29
+ panelProps: {
30
+ id: string;
31
+ role: 'region';
32
+ 'aria-labelledby': string;
33
+ };
34
+ };
35
+ export type UseListDisclosureReturn = {
36
+ /** Return the disclosure binding for a single item by id. */
37
+ bind: (id: string) => DisclosureItemBinding;
38
+ };
39
+ /**
40
+ * Disclosure (open/close) aspect for list items. Owns single- or multi-expand state and
41
+ * generates the trigger/panel ids needed for `aria-controls` / `aria-labelledby`. Pairs
42
+ * with `useListGrid`'s expand-caret slot.
43
+ *
44
+ * `single` mode tracks one expanded id; expanding another collapses the previous (matches
45
+ * the existing `OrderedList` behaviour).
46
+ *
47
+ * `multi` mode tracks a `Set<string>` of expanded ids; intended for `Tree` and other
48
+ * multi-branch disclosure surfaces.
49
+ *
50
+ * Controlled-ness keys on `onValueChange` rather than on the value's presence so that
51
+ * `undefined` (single mode) and the empty set (multi mode) remain valid "nothing expanded"
52
+ * values. Radix's `useControllableState` (1.1.0) flips to uncontrolled when a controlled
53
+ * value clears to `undefined`, then re-reads the stale internal state and fails to collapse —
54
+ * a hand-rolled controller is the only correct option here.
55
+ */
56
+ export declare const useListDisclosure: {
57
+ <M extends ListDisclosureMode>(opts: UseListDisclosureOptions<M>): UseListDisclosureReturn;
58
+ };
59
+ export {};
60
+ //# sourceMappingURL=useListDisclosure.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListDisclosure.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListDisclosure.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,UAAU,EAAmD,MAAM,OAAO,CAAC;AAEzF,MAAM,MAAM,kBAAkB,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEpD,KAAK,WAAW,GAAG,MAAM,GAAG,SAAS,CAAC;AACtC,KAAK,UAAU,GAAG,WAAW,CAAC,MAAM,CAAC,CAAC;AAEtC,KAAK,QAAQ,CAAC,CAAC,SAAS,kBAAkB,IAAI,CAAC,SAAS,QAAQ,GAAG,WAAW,GAAG,UAAU,CAAC;AAE5F,MAAM,MAAM,wBAAwB,CAAC,CAAC,SAAS,kBAAkB,GAAG,kBAAkB,IAAI;IACxF,IAAI,EAAE,CAAC,CAAC;IACR,gFAAgF;IAChF,KAAK,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;IACpB,YAAY,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;IAC3B,oDAAoD;IACpD,aAAa,CAAC,EAAE,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC;CAC7C,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG;IAClC,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,mGAAmG;IACnG,SAAS,EAAE,MAAM,CAAC;IAClB,sFAAsF;IACtF,OAAO,EAAE,MAAM,CAAC;IAChB,8DAA8D;IAC9D,YAAY,EAAE;QACZ,EAAE,EAAE,MAAM,CAAC;QACX,eAAe,EAAE,OAAO,CAAC;QACzB,eAAe,EAAE,MAAM,CAAC;QACxB,OAAO,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;KACtC,CAAC;IACF,8EAA8E;IAC9E,UAAU,EAAE;QACV,EAAE,EAAE,MAAM,CAAC;QACX,IAAI,EAAE,QAAQ,CAAC;QACf,iBAAiB,EAAE,MAAM,CAAC;KAC3B,CAAC;CACH,CAAC;AAEF,MAAM,MAAM,uBAAuB,GAAG;IACpC,6DAA6D;IAC7D,IAAI,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,qBAAqB,CAAC;CAC7C,CAAC;AAIF;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,iBAAiB,EAAE;IAC9B,CAAC,CAAC,SAAS,kBAAkB,EAAE,IAAI,EAAE,wBAAwB,CAAC,CAAC,CAAC,GAAG,uBAAuB,CAAC;CA0F5F,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=useListDisclosure.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListDisclosure.test.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListDisclosure.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,30 @@
1
+ import { type CSSProperties } from 'react';
2
+ export type UseListGridOptions = {
3
+ /**
4
+ * Number of inline action slots between title and expand caret. Each slot is sized to
5
+ * `var(--dx-rail-item)` so an `IconButton` lands on the same baseline as the trailing icon.
6
+ */
7
+ actionSlots?: number;
8
+ /** Reserve an expand-caret slot at the end of the title row. */
9
+ expandable?: boolean;
10
+ /** Reserve a trailing-action slot outside the row's card (e.g. delete). */
11
+ trailing?: boolean;
12
+ };
13
+ export type UseListGridReturn = {
14
+ /** Spread onto the outer row element to apply the grid template. */
15
+ rowProps: {
16
+ className: string;
17
+ style: CSSProperties;
18
+ };
19
+ };
20
+ /**
21
+ * Row layout aspect. Generates the CSS grid template that keeps drag handle, title,
22
+ * inline actions, expand caret, and trailing icon co-aligned on the same line —
23
+ * independent of whether the row body is expanded.
24
+ *
25
+ * Width tracks are `var(--dx-rail-item)` for icon-button slots and `1fr` for the
26
+ * title, so every icon-shaped slot is the same width as `IconBlock` / `IconButton iconOnly`
27
+ * and the line aligns without per-pixel adjustments.
28
+ */
29
+ export declare const useListGrid: ({ actionSlots, expandable, trailing, }?: UseListGridOptions) => UseListGridReturn;
30
+ //# sourceMappingURL=useListGrid.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListGrid.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListGrid.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,aAAa,EAAW,MAAM,OAAO,CAAC;AAEpD,MAAM,MAAM,kBAAkB,GAAG;IAC/B;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,gEAAgE;IAChE,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,2EAA2E;IAC3E,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,oEAAoE;IACpE,QAAQ,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,aAAa,CAAA;KAAE,CAAC;CACvD,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,WAAW,4CAIrB,kBAAkB,KAAQ,iBAwB5B,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=useListGrid.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListGrid.test.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListGrid.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,68 @@
1
+ import { type TabsterDOMAttribute } from '@fluentui/react-tabster';
2
+ import { type FocusEvent } from 'react';
3
+ export type ListNavigationMode = 'list' | 'listbox' | 'grid';
4
+ export type UseListNavigationOptions = {
5
+ /**
6
+ * Determines the bundled ARIA role + keyboard wiring.
7
+ *
8
+ * - `list` — `role='list'` items are `role='listitem'`. Arrow keys move focus among
9
+ * interactive descendants of the row (handles, buttons). No selection semantics.
10
+ * - `listbox` — `role='listbox'` items are `role='option'`. Arrow keys move focus
11
+ * between options; `memorizeCurrent` keeps the last-focused option when re-entering.
12
+ * - `grid` — `role='grid'` items are `role='row'`. Two-axis arrow navigation.
13
+ */
14
+ mode: ListNavigationMode;
15
+ /**
16
+ * Override default axis. `list` and `listbox` default to `'vertical'`; `grid`
17
+ * defaults to `'grid'` (two-axis). Set explicitly when a horizontal list is needed.
18
+ */
19
+ axis?: 'vertical' | 'horizontal' | 'grid' | 'grid-linear' | 'both';
20
+ /**
21
+ * Remember the last-focused item when re-entering the group. Defaults to `true`.
22
+ * Only meaningful for `listbox` mode.
23
+ */
24
+ memorizeCurrent?: boolean;
25
+ };
26
+ type ContainerRole = 'list' | 'listbox' | 'grid';
27
+ type ItemRole = 'listitem' | 'option' | 'row';
28
+ export type UseListNavigationReturn = {
29
+ /**
30
+ * Spread onto the container element to apply role + ARIA + Tabster attributes.
31
+ * Also wires a focus-on-entry handler that redirects to the selected or first
32
+ * focusable item — Tabster doesn't cover initial focus, only traversal.
33
+ *
34
+ * The shape is intentionally open — Tabster's `useArrowNavigationGroup` returns
35
+ * `TabsterDOMAttribute` (one or more `data-tabster*` attributes that may be undefined
36
+ * when the runtime is disabled), and the precise key set isn't part of Tabster's
37
+ * stable contract.
38
+ */
39
+ containerProps: TabsterDOMAttribute & {
40
+ role: ContainerRole;
41
+ 'aria-orientation'?: 'vertical' | 'horizontal';
42
+ onFocus: (event: FocusEvent<HTMLElement>) => void;
43
+ };
44
+ /**
45
+ * Apply to each item. Returns role, tabIndex, and aria-disabled. Disabled options remain
46
+ * focusable so screen readers can announce them, per WAI-ARIA listbox guidance.
47
+ */
48
+ itemProps: (opts?: {
49
+ disabled?: boolean;
50
+ }) => {
51
+ role: ItemRole;
52
+ tabIndex: number;
53
+ 'aria-disabled'?: true;
54
+ };
55
+ };
56
+ /**
57
+ * Keyboard navigation + ARIA role aspect for list-shaped surfaces. Wraps Tabster's
58
+ * `useArrowNavigationGroup` with a `mode` that selects the appropriate role bundle
59
+ * and adds a focus-on-entry redirect (Tabster handles traversal once focus is on a
60
+ * child; first-entry is the consumer's responsibility).
61
+ *
62
+ * Canonical for all list-shaped surfaces (List, OrderedList, RowList, Tree,
63
+ * Combobox.List, Mosaic.Stack). Non-list focus zones — e.g. Composer's multi-pane
64
+ * chrome — should keep their own Tabster wiring (Focus.Group).
65
+ */
66
+ export declare const useListNavigation: ({ mode, axis, memorizeCurrent, }: UseListNavigationOptions) => UseListNavigationReturn;
67
+ export {};
68
+ //# sourceMappingURL=useListNavigation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListNavigation.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListNavigation.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,mBAAmB,EAA2B,MAAM,yBAAyB,CAAC;AAC5F,OAAO,EAAE,KAAK,UAAU,EAAwB,MAAM,OAAO,CAAC;AAE9D,MAAM,MAAM,kBAAkB,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,CAAC;AAE7D,MAAM,MAAM,wBAAwB,GAAG;IACrC;;;;;;;;OAQG;IACH,IAAI,EAAE,kBAAkB,CAAC;IACzB;;;OAGG;IACH,IAAI,CAAC,EAAE,UAAU,GAAG,YAAY,GAAG,MAAM,GAAG,aAAa,GAAG,MAAM,CAAC;IACnE;;;OAGG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B,CAAC;AAEF,KAAK,aAAa,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,CAAC;AACjD,KAAK,QAAQ,GAAG,UAAU,GAAG,QAAQ,GAAG,KAAK,CAAC;AAE9C,MAAM,MAAM,uBAAuB,GAAG;IACpC;;;;;;;;;OASG;IACH,cAAc,EAAE,mBAAmB,GAAG;QACpC,IAAI,EAAE,aAAa,CAAC;QACpB,kBAAkB,CAAC,EAAE,UAAU,GAAG,YAAY,CAAC;QAC/C,OAAO,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,WAAW,CAAC,KAAK,IAAI,CAAC;KACnD,CAAC;IACF;;;OAGG;IACH,SAAS,EAAE,CAAC,IAAI,CAAC,EAAE;QAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;KAAE,KAAK;QAC5C,IAAI,EAAE,QAAQ,CAAC;QACf,QAAQ,EAAE,MAAM,CAAC;QACjB,eAAe,CAAC,EAAE,IAAI,CAAC;KACxB,CAAC;CACH,CAAC;AAgCF;;;;;;;;;GASG;AACH,eAAO,MAAM,iBAAiB,qCAI3B,wBAAwB,KAAG,uBAqD7B,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=useListNavigation.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListNavigation.test.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListNavigation.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,48 @@
1
+ import { type FocusEvent, type MouseEvent } from 'react';
2
+ export type ListSelectionMode = 'single' | 'multi';
3
+ type SingleValue = string | undefined;
4
+ type MultiValue = ReadonlySet<string>;
5
+ type ValueFor<M extends ListSelectionMode> = M extends 'single' ? SingleValue : MultiValue;
6
+ export type UseListSelectionOptions<M extends ListSelectionMode = ListSelectionMode> = {
7
+ mode: M;
8
+ /** Controlled selected id (single mode) or set of ids (multi mode). */
9
+ value?: ValueFor<M>;
10
+ defaultValue?: ValueFor<M>;
11
+ onValueChange?: (next: ValueFor<M>) => void;
12
+ /**
13
+ * Selection follows focus. Defaults to `true` for single-select (matches the WAI-ARIA
14
+ * listbox pattern) and `false` for multi-select (focus and toggle are separate gestures).
15
+ */
16
+ followsFocus?: boolean;
17
+ };
18
+ export type SelectionItemBinding = {
19
+ selected: boolean;
20
+ toggle: () => void;
21
+ /** Spread onto the row element to bind click + focus + ARIA. */
22
+ rowProps: {
23
+ 'aria-selected': boolean;
24
+ onClick: (event: MouseEvent) => void;
25
+ onFocus?: (event: FocusEvent) => void;
26
+ };
27
+ };
28
+ export type UseListSelectionReturn = {
29
+ bind: (id: string, opts?: {
30
+ disabled?: boolean;
31
+ }) => SelectionItemBinding;
32
+ };
33
+ /**
34
+ * Selection aspect for list-shaped surfaces. Owns single- or multi-select state with
35
+ * controllable value semantics; emits `aria-selected` + click/focus handlers per row.
36
+ *
37
+ * `single` mode: at most one selected id, selection follows focus by default. Matches the
38
+ * existing `RowList` behaviour and the WAI-ARIA listbox single-select pattern.
39
+ *
40
+ * `multi` mode: tracks a `Set<string>`. Selection does NOT follow focus by default — multi
41
+ * select usually pairs with an explicit toggle affordance (checkbox or keyboard Space) rather
42
+ * than implicit focus-tracking.
43
+ */
44
+ export declare const useListSelection: {
45
+ <M extends ListSelectionMode>(opts: UseListSelectionOptions<M>): UseListSelectionReturn;
46
+ };
47
+ export {};
48
+ //# sourceMappingURL=useListSelection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListSelection.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListSelection.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,UAAU,EAA4C,MAAM,OAAO,CAAC;AAEnG,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEnD,KAAK,WAAW,GAAG,MAAM,GAAG,SAAS,CAAC;AACtC,KAAK,UAAU,GAAG,WAAW,CAAC,MAAM,CAAC,CAAC;AAEtC,KAAK,QAAQ,CAAC,CAAC,SAAS,iBAAiB,IAAI,CAAC,SAAS,QAAQ,GAAG,WAAW,GAAG,UAAU,CAAC;AAE3F,MAAM,MAAM,uBAAuB,CAAC,CAAC,SAAS,iBAAiB,GAAG,iBAAiB,IAAI;IACrF,IAAI,EAAE,CAAC,CAAC;IACR,uEAAuE;IACvE,KAAK,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;IACpB,YAAY,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC;IAC3B,aAAa,CAAC,EAAE,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC;IAC5C;;;OAGG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,gEAAgE;IAChE,QAAQ,EAAE;QACR,eAAe,EAAE,OAAO,CAAC;QACzB,OAAO,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;QACrC,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,KAAK,IAAI,CAAC;KACvC,CAAC;CACH,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAAG;IACnC,IAAI,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE;QAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;KAAE,KAAK,oBAAoB,CAAC;CAC3E,CAAC;AAIF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gBAAgB,EAAE;IAC7B,CAAC,CAAC,SAAS,iBAAiB,EAAE,IAAI,EAAE,uBAAuB,CAAC,CAAC,CAAC,GAAG,sBAAsB,CAAC;CA0GzF,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=useListSelection.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useListSelection.test.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useListSelection.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,103 @@
1
+ import { type Edge } from '@atlaskit/pragmatic-drag-and-drop-hitbox/closest-edge';
2
+ import { type ElementDragPayload } from '@atlaskit/pragmatic-drag-and-drop/element/adapter';
3
+ import { type ReactNode, type RefCallback } from 'react';
4
+ export type ReorderAxis = 'vertical' | 'horizontal';
5
+ export type ReorderItemState = {
6
+ type: 'idle';
7
+ } | {
8
+ type: 'preview';
9
+ container: HTMLElement;
10
+ } | {
11
+ type: 'dragging';
12
+ } | {
13
+ type: 'dragging-over';
14
+ closestEdge: Edge | null;
15
+ };
16
+ export type UseReorderListOptions<T> = {
17
+ /** Authoritative item list. Read on each drop to compute the new index. */
18
+ items: readonly T[];
19
+ /** Stable identifier per item. The monitor uses this to find source/target indices. */
20
+ getId: (item: T) => string;
21
+ /** Called with `(fromIndex, toIndex)` when a drop completes inside this list. */
22
+ onMove: (fromIndex: number, toIndex: number) => void;
23
+ /** Drop axis. Defaults to `'vertical'`. */
24
+ axis?: ReorderAxis;
25
+ /** When true, drag handles report as disabled. Defaults to false. */
26
+ readonly?: boolean;
27
+ /** Forwarded to pragmatic-dnd's `getInitialData` on each draggable. */
28
+ getInitialData?: (item: T, index: number) => Record<string, unknown>;
29
+ /** Overrides the default `canDrop` (which matches payloads tagged with this list's id). */
30
+ canDrop?: (args: {
31
+ source: ElementDragPayload;
32
+ }) => boolean;
33
+ /** Renderer for a custom native drag preview. */
34
+ getDragPreview?: (item: T) => ReactNode;
35
+ };
36
+ export type ReorderActive<T> = {
37
+ id: string;
38
+ item: T;
39
+ container: HTMLElement;
40
+ } | null;
41
+ /**
42
+ * Stable controller created by `useReorderList`. Item components consume it via
43
+ * `useReorderItem(controller, id)`. The controller is reference-stable across renders.
44
+ */
45
+ export type ReorderListController<T> = {
46
+ /** Internal: list id; payload tagged with this is the only data the monitor accepts by default. */
47
+ listId: string;
48
+ /** Look up an item by id. Used by the item hook to bind pragmatic-dnd at register time. */
49
+ getItem: (id: string) => {
50
+ item: T;
51
+ index: number;
52
+ } | null;
53
+ /** Bind a row's pragmatic-dnd primitives. Idempotent; returns a cleanup function. */
54
+ bindItem: (id: string, refs: {
55
+ row: HTMLElement;
56
+ handle: HTMLElement;
57
+ }, onItemState: (state: ReorderItemState) => void) => () => void;
58
+ };
59
+ export type UseReorderListReturn<T> = {
60
+ controller: ReorderListController<T>;
61
+ /** The currently-dragging item, or null. Used by global drag preview portals. */
62
+ active: ReorderActive<T>;
63
+ /** Same as `controller.listId`. Exposed for diagnostics. */
64
+ listId: string;
65
+ };
66
+ /**
67
+ * List-level reorder aspect. Spins up pragmatic-dnd's `monitorForElements` and produces a
68
+ * stable controller that per-row hooks consume. Item registration + the per-item draggable /
69
+ * drop-target wiring lives in `useReorderItem` so each row owns its own React state without
70
+ * re-rendering siblings on hover.
71
+ */
72
+ export declare const useReorderList: <T>({ items, getId, onMove, axis, readonly, getInitialData, canDrop, getDragPreview, }: UseReorderListOptions<T>) => UseReorderListReturn<T>;
73
+ export type ReorderItemBinding = {
74
+ rowRef: RefCallback<HTMLElement>;
75
+ handleRef: RefCallback<HTMLElement>;
76
+ state: ReorderItemState;
77
+ isDragging: boolean;
78
+ closestEdge: Edge | null;
79
+ };
80
+ /**
81
+ * Per-row reorder hook. Owns the row's local state and registers the row's DOM elements
82
+ * with the list controller once both `rowRef` and `handleRef` are attached. Unmounting (or
83
+ * detaching either ref) tears down the registration.
84
+ *
85
+ * Called inside the item component, not in the parent's render loop — this is what keeps
86
+ * us inside the rules of hooks.
87
+ */
88
+ export declare const useReorderItem: <T>(controller: ReorderListController<T>, id: string) => ReorderItemBinding;
89
+ /**
90
+ * Wire pragmatic-dnd's auto-scroll on a scrollable container. While any pragmatic-dnd drag
91
+ * is in flight, hovering near the edges of the registered element scrolls the container
92
+ * automatically. Pair with `OrderedList.Viewport` (or any caller-owned ScrollArea) so long
93
+ * lists can be reordered without manually scrolling first.
94
+ *
95
+ * `autoScrollForElements` is global — it activates on every drag regardless of which list
96
+ * started it — so it's safe to register one element per scroll surface.
97
+ *
98
+ * Returns a callback ref so the registration fires as soon as the element attaches and the
99
+ * cleanup fires when it detaches; React doesn't re-run effects on mutable `ref.current`
100
+ * changes, so a plain `useEffect` on a `useRef` would miss late-mounting elements entirely.
101
+ */
102
+ export declare const useReorderAutoScroll: () => RefCallback<HTMLElement>;
103
+ //# sourceMappingURL=useReorder.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useReorder.d.ts","sourceRoot":"","sources":["../../../../src/aspects/useReorder.ts"],"names":[],"mappings":"AAKA,OAAO,EACL,KAAK,IAAI,EAGV,MAAM,uDAAuD,CAAC;AAG/D,OAAO,EACL,KAAK,kBAAkB,EAIxB,MAAM,mDAAmD,CAAC;AAE3D,OAAO,EAAE,KAAK,SAAS,EAAE,KAAK,WAAW,EAAqD,MAAM,OAAO,CAAC;AAW5G,MAAM,MAAM,WAAW,GAAG,UAAU,GAAG,YAAY,CAAC;AAEpD,MAAM,MAAM,gBAAgB,GACxB;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,GAChB;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,SAAS,EAAE,WAAW,CAAA;CAAE,GAC3C;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,GACpB;IAAE,IAAI,EAAE,eAAe,CAAC;IAAC,WAAW,EAAE,IAAI,GAAG,IAAI,CAAA;CAAE,CAAC;AAIxD,MAAM,MAAM,qBAAqB,CAAC,CAAC,IAAI;IACrC,2EAA2E;IAC3E,KAAK,EAAE,SAAS,CAAC,EAAE,CAAC;IACpB,uFAAuF;IACvF,KAAK,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,MAAM,CAAC;IAC3B,iFAAiF;IACjF,MAAM,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACrD,2CAA2C;IAC3C,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB,qEAAqE;IACrE,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,uEAAuE;IACvE,cAAc,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACrE,2FAA2F;IAC3F,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE;QAAE,MAAM,EAAE,kBAAkB,CAAA;KAAE,KAAK,OAAO,CAAC;IAC5D,iDAAiD;IACjD,cAAc,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,SAAS,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,aAAa,CAAC,CAAC,IAAI;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,CAAC,CAAC;IAAC,SAAS,EAAE,WAAW,CAAA;CAAE,GAAG,IAAI,CAAC;AAEtF;;;GAGG;AACH,MAAM,MAAM,qBAAqB,CAAC,CAAC,IAAI;IACrC,mGAAmG;IACnG,MAAM,EAAE,MAAM,CAAC;IACf,2FAA2F;IAC3F,OAAO,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK;QAAE,IAAI,EAAE,CAAC,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;IAC3D,qFAAqF;IACrF,QAAQ,EAAE,CACR,EAAE,EAAE,MAAM,EACV,IAAI,EAAE;QAAE,GAAG,EAAE,WAAW,CAAC;QAAC,MAAM,EAAE,WAAW,CAAA;KAAE,EAC/C,WAAW,EAAE,CAAC,KAAK,EAAE,gBAAgB,KAAK,IAAI,KAC3C,MAAM,IAAI,CAAC;CACjB,CAAC;AAEF,MAAM,MAAM,oBAAoB,CAAC,CAAC,IAAI;IACpC,UAAU,EAAE,qBAAqB,CAAC,CAAC,CAAC,CAAC;IACrC,iFAAiF;IACjF,MAAM,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;IACzB,4DAA4D;IAC5D,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,cAAc,GAAI,CAAC,sFAS7B,qBAAqB,CAAC,CAAC,CAAC,KAAG,oBAAoB,CAAC,CAAC,CAsKnD,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,MAAM,EAAE,WAAW,CAAC,WAAW,CAAC,CAAC;IACjC,SAAS,EAAE,WAAW,CAAC,WAAW,CAAC,CAAC;IACpC,KAAK,EAAE,gBAAgB,CAAC;IACxB,UAAU,EAAE,OAAO,CAAC;IACpB,WAAW,EAAE,IAAI,GAAG,IAAI,CAAC;CAC1B,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,cAAc,GAAI,CAAC,cAAc,qBAAqB,CAAC,CAAC,CAAC,MAAM,MAAM,KAAG,kBA+DpF,CAAC;AAEF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,oBAAoB,QAAO,WAAW,CAAC,WAAW,CAM9D,CAAC"}
@@ -1,7 +1,7 @@
1
1
  export declare const Accordion: {
2
2
  Root: <T extends unknown>({ classNames, items, getId, children, value, defaultValue, onValueChange, }: import("./AccordionRoot").AccordionRootProps<T> & Pick<import("@radix-ui/react-accordion").AccordionMultipleProps, 'value' | 'defaultValue' | 'onValueChange'>) => import("react").JSX.Element;
3
3
  Item: <T extends unknown>({ children, classNames, item }: import("./AccordionItem").AccordionItemProps<T>) => import("react").JSX.Element;
4
- ItemHeader: ({ classNames, children, ...props }: import("./AccordionItem").AccordionItemHeaderProps) => import("react").JSX.Element;
4
+ ItemHeader: ({ classNames, children, icon, ...props }: import("./AccordionItem").AccordionItemHeaderProps) => import("react").JSX.Element;
5
5
  ItemBody: ({ children, classNames }: import("./AccordionItem").AccordionItemBodyProps) => import("react").JSX.Element;
6
6
  };
7
7
  //# sourceMappingURL=Accordion.d.ts.map
@@ -1,7 +1,7 @@
1
1
  import * as AccordionPrimitive from '@radix-ui/react-accordion';
2
2
  import React, { type PropsWithChildren } from 'react';
3
3
  import { type ThemedClassName } from '@dxos/react-ui';
4
- import { type ListItemRecord } from '../List';
4
+ type ListItemRecord = any;
5
5
  type AccordionItemContext<T extends ListItemRecord> = {
6
6
  item: T;
7
7
  };
@@ -12,8 +12,10 @@ export type AccordionItemProps<T extends ListItemRecord> = ThemedClassName<Props
12
12
  item: T;
13
13
  }>>;
14
14
  export declare const AccordionItem: <T extends ListItemRecord>({ children, classNames, item }: AccordionItemProps<T>) => React.JSX.Element;
15
- export type AccordionItemHeaderProps = ThemedClassName<AccordionPrimitive.AccordionHeaderProps>;
16
- export declare const AccordionItemHeader: ({ classNames, children, ...props }: AccordionItemHeaderProps) => React.JSX.Element;
15
+ export type AccordionItemHeaderProps = ThemedClassName<AccordionPrimitive.AccordionHeaderProps & {
16
+ icon?: string;
17
+ }>;
18
+ export declare const AccordionItemHeader: ({ classNames, children, icon, ...props }: AccordionItemHeaderProps) => React.JSX.Element;
17
19
  export type AccordionItemBodyProps = ThemedClassName<PropsWithChildren>;
18
20
  export declare const AccordionItemBody: ({ children, classNames }: AccordionItemBodyProps) => React.JSX.Element;
19
21
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"AccordionItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/Accordion/AccordionItem.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAC;AAEhE,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAEtD,OAAO,EAAQ,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAG5D,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,SAAS,CAAC;AAK9C,KAAK,oBAAoB,CAAC,CAAC,SAAS,cAAc,IAAI;IACpD,IAAI,EAAE,CAAC,CAAC;CACT,CAAC;AAIF,eAAO,MAAO,qBAAqB;;IAAE,yBAAyB,qDACC,CAAC;AAEhE,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,cAAc,IAAI,eAAe,CAAC,iBAAiB,CAAC;IAAE,IAAI,EAAE,CAAC,CAAA;CAAE,CAAC,CAAC,CAAC;AAE3G,eAAO,MAAM,aAAa,GAAI,CAAC,SAAS,cAAc,kCAAkC,kBAAkB,CAAC,CAAC,CAAC,sBAU5G,CAAC;AAEF,MAAM,MAAM,wBAAwB,GAAG,eAAe,CAAC,kBAAkB,CAAC,oBAAoB,CAAC,CAAC;AAEhG,eAAO,MAAM,mBAAmB,uCAAwC,wBAAwB,sBAa/F,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAAG,eAAe,CAAC,iBAAiB,CAAC,CAAC;AAExE,eAAO,MAAM,iBAAiB,6BAA8B,sBAAsB,sBAMjF,CAAC"}
1
+ {"version":3,"file":"AccordionItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/Accordion/AccordionItem.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAC;AAEhE,OAAO,KAAK,EAAE,EAAE,KAAK,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAEtD,OAAO,EAAQ,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAI5D,KAAK,cAAc,GAAG,GAAG,CAAC;AAK1B,KAAK,oBAAoB,CAAC,CAAC,SAAS,cAAc,IAAI;IACpD,IAAI,EAAE,CAAC,CAAC;CACT,CAAC;AAIF,eAAO,MAAO,qBAAqB;;IAAE,yBAAyB,qDACC,CAAC;AAEhE,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,cAAc,IAAI,eAAe,CAAC,iBAAiB,CAAC;IAAE,IAAI,EAAE,CAAC,CAAA;CAAE,CAAC,CAAC,CAAC;AAE3G,eAAO,MAAM,aAAa,GAAI,CAAC,SAAS,cAAc,kCAAkC,kBAAkB,CAAC,CAAC,CAAC,sBAU5G,CAAC;AAEF,MAAM,MAAM,wBAAwB,GAAG,eAAe,CAAC,kBAAkB,CAAC,oBAAoB,GAAG;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAEpH,eAAO,MAAM,mBAAmB,6CAA8C,wBAAwB,sBAiBrG,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAAG,eAAe,CAAC,iBAAiB,CAAC,CAAC;AAExE,eAAO,MAAM,iBAAiB,6BAA8B,sBAAsB,sBAMjF,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import * as AccordionPrimitive from '@radix-ui/react-accordion';
2
2
  import React, { type ReactNode } from 'react';
3
3
  import { type ThemedClassName } from '@dxos/react-ui';
4
- import { type ListItemRecord } from '../List';
4
+ type ListItemRecord = any;
5
5
  type AccordionContext<T extends ListItemRecord> = {
6
6
  getId: (item: T) => string;
7
7
  };
@@ -1 +1 @@
1
- {"version":3,"file":"AccordionRoot.d.ts","sourceRoot":"","sources":["../../../../../src/components/Accordion/AccordionRoot.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAC;AAEhE,OAAO,KAAK,EAAE,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAE9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAGtD,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9C,KAAK,gBAAgB,CAAC,CAAC,SAAS,cAAc,IAAI;IAChD,KAAK,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,MAAM,CAAC;CAC5B,CAAC;AAIF,eAAO,MAAO,iBAAiB;;IAAE,mBAAmB,iDAAwD,CAAC;AAE7G,MAAM,MAAM,sBAAsB,CAAC,CAAC,SAAS,cAAc,IAAI;IAC7D,KAAK,EAAE,CAAC,EAAE,CAAC;CACZ,CAAC;AAIF,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,cAAc,IAAI,eAAe,CACxE;IACE,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,sBAAsB,CAAC,CAAC,CAAC,KAAK,SAAS,CAAC;IAC3D,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC;CACb,GAAG,OAAO,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAChD,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,CAAC,SAAS,cAAc,+EAQnD,kBAAkB,CAAC,CAAC,CAAC,GACtB,IAAI,CAAC,kBAAkB,CAAC,sBAAsB,EAAE,OAAO,GAAG,cAAc,GAAG,eAAe,CAAC,sBAc5F,CAAC"}
1
+ {"version":3,"file":"AccordionRoot.d.ts","sourceRoot":"","sources":["../../../../../src/components/Accordion/AccordionRoot.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAC;AAEhE,OAAO,KAAK,EAAE,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAE9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAMtD,KAAK,cAAc,GAAG,GAAG,CAAC;AAE1B,KAAK,gBAAgB,CAAC,CAAC,SAAS,cAAc,IAAI;IAChD,KAAK,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,MAAM,CAAC;CAC5B,CAAC;AAIF,eAAO,MAAO,iBAAiB;;IAAE,mBAAmB,iDAAwD,CAAC;AAE7G,MAAM,MAAM,sBAAsB,CAAC,CAAC,SAAS,cAAc,IAAI;IAC7D,KAAK,EAAE,CAAC,EAAE,CAAC;CACZ,CAAC;AAIF,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,cAAc,IAAI,eAAe,CACxE;IACE,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,sBAAsB,CAAC,CAAC,CAAC,KAAK,SAAS,CAAC;IAC3D,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC;CACb,GAAG,OAAO,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAChD,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,CAAC,SAAS,cAAc,+EAQnD,kBAAkB,CAAC,CAAC,CAAC,GACtB,IAAI,CAAC,kBAAkB,CAAC,sBAAsB,EAAE,OAAO,GAAG,cAAc,GAAG,eAAe,CAAC,sBAc5F,CAAC"}