impact-nova 2.5.16 → 2.6.0-alpha.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 (254) hide show
  1. package/README.md +27 -25
  2. package/dist/components/data/ag-grid-react/ag-grid.types.d.ts +28 -1
  3. package/dist/components/data/ag-grid-react/cell-renderers/date-display-renderer.d.ts +0 -3
  4. package/dist/components/data/ag-grid-react/cell-renderers/date-display-renderer.js +31 -38
  5. package/dist/components/data/ag-grid-react/cell-renderers/input-display-renderer.d.ts +1 -1
  6. package/dist/components/data/ag-grid-react/chat/chat-capabilities.d.ts +9 -0
  7. package/dist/components/data/ag-grid-react/chat/chat-capabilities.js +22 -0
  8. package/dist/components/data/ag-grid-react/chat/chat-column.d.ts +20 -0
  9. package/dist/components/data/ag-grid-react/chat/chat-column.js +81 -0
  10. package/dist/components/data/ag-grid-react/chat/chat-composer.d.ts +10 -0
  11. package/dist/components/data/ag-grid-react/chat/chat-composer.js +352 -0
  12. package/dist/components/data/ag-grid-react/chat/chat-constants.d.ts +17 -0
  13. package/dist/components/data/ag-grid-react/chat/chat-constants.js +22 -0
  14. package/dist/components/data/ag-grid-react/chat/chat-format.d.ts +41 -0
  15. package/dist/components/data/ag-grid-react/chat/chat-format.js +94 -0
  16. package/dist/components/data/ag-grid-react/chat/chat-host.d.ts +10 -0
  17. package/dist/components/data/ag-grid-react/chat/chat-host.js +651 -0
  18. package/dist/components/data/ag-grid-react/chat/chat-host.types.d.ts +13 -0
  19. package/dist/components/data/ag-grid-react/chat/chat-html.d.ts +2 -0
  20. package/dist/components/data/ag-grid-react/chat/chat-html.js +40 -0
  21. package/dist/components/data/ag-grid-react/chat/chat-identity.d.ts +13 -0
  22. package/dist/components/data/ag-grid-react/chat/chat-identity.js +24 -0
  23. package/dist/components/data/ag-grid-react/chat/chat-menu.d.ts +13 -0
  24. package/dist/components/data/ag-grid-react/chat/chat-menu.js +15 -0
  25. package/dist/components/data/ag-grid-react/chat/chat-notify.d.ts +17 -0
  26. package/dist/components/data/ag-grid-react/chat/chat-notify.js +124 -0
  27. package/dist/components/data/ag-grid-react/chat/chat-persist.d.ts +13 -0
  28. package/dist/components/data/ag-grid-react/chat/chat-persist.js +34 -0
  29. package/dist/components/data/ag-grid-react/chat/chat-priority.d.ts +13 -0
  30. package/dist/components/data/ag-grid-react/chat/chat-priority.js +79 -0
  31. package/dist/components/data/ag-grid-react/chat/chat-summaries.d.ts +2 -0
  32. package/dist/components/data/ag-grid-react/chat/chat-summaries.js +24 -0
  33. package/dist/components/data/ag-grid-react/chat/chat-thread-ui.d.ts +72 -0
  34. package/dist/components/data/ag-grid-react/chat/chat-thread-ui.js +713 -0
  35. package/dist/components/data/ag-grid-react/chat/chat-toggle.d.ts +6 -0
  36. package/dist/components/data/ag-grid-react/chat/chat-toggle.js +25 -0
  37. package/dist/components/data/ag-grid-react/chat/chat-ui-actions.d.ts +13 -0
  38. package/dist/components/data/ag-grid-react/chat/chat-ui-actions.js +26 -0
  39. package/dist/components/data/ag-grid-react/chat/chat-window.d.ts +14 -0
  40. package/dist/components/data/ag-grid-react/chat/chat-window.js +82 -0
  41. package/dist/components/data/ag-grid-react/chat/chat-workspace.d.ts +91 -0
  42. package/dist/components/data/ag-grid-react/chat/chat-workspace.js +555 -0
  43. package/dist/components/data/ag-grid-react/chat/chat.types.d.ts +319 -0
  44. package/dist/components/data/ag-grid-react/chat/index.d.ts +6 -0
  45. package/dist/components/data/ag-grid-react/chat/index.js +24 -0
  46. package/dist/components/data/ag-grid-react/chat.story-data.d.ts +34 -0
  47. package/dist/components/data/ag-grid-react/chat.story-sources.d.ts +4 -0
  48. package/dist/components/data/ag-grid-react/comments/assets/comments-no-results.png.js +4 -0
  49. package/dist/components/data/ag-grid-react/comments/comment-mode-toggle.d.ts +6 -0
  50. package/dist/components/data/ag-grid-react/comments/comment-mode-toggle.js +29 -0
  51. package/dist/components/data/ag-grid-react/comments/comments-actions-menu.d.ts +8 -0
  52. package/dist/components/data/ag-grid-react/comments/comments-actions-menu.js +18 -0
  53. package/dist/components/data/ag-grid-react/comments/comments-ag-grid-presence.d.ts +18 -0
  54. package/dist/components/data/ag-grid-react/comments/comments-ag-grid-presence.js +16 -0
  55. package/dist/components/data/ag-grid-react/comments/comments-capabilities.d.ts +11 -0
  56. package/dist/components/data/ag-grid-react/comments/comments-capabilities.js +26 -0
  57. package/dist/components/data/ag-grid-react/comments/comments-constants.d.ts +12 -0
  58. package/dist/components/data/ag-grid-react/comments/comments-constants.js +21 -0
  59. package/dist/components/data/ag-grid-react/comments/comments-format.d.ts +20 -0
  60. package/dist/components/data/ag-grid-react/comments/comments-format.js +49 -0
  61. package/dist/components/data/ag-grid-react/comments/comments-generation.d.ts +14 -0
  62. package/dist/components/data/ag-grid-react/comments/comments-generation.js +18 -0
  63. package/dist/components/data/ag-grid-react/comments/comments-host.d.ts +10 -0
  64. package/dist/components/data/ag-grid-react/comments/comments-host.js +343 -0
  65. package/dist/components/data/ag-grid-react/comments/comments-host.types.d.ts +18 -0
  66. package/dist/components/data/ag-grid-react/comments/comments-identity.d.ts +7 -0
  67. package/dist/components/data/ag-grid-react/comments/comments-identity.js +20 -0
  68. package/dist/components/data/ag-grid-react/comments/comments-menu.d.ts +29 -0
  69. package/dist/components/data/ag-grid-react/comments/comments-menu.js +35 -0
  70. package/dist/components/data/ag-grid-react/comments/comments-overlay-anchor.d.ts +22 -0
  71. package/dist/components/data/ag-grid-react/comments/comments-overlay-anchor.js +98 -0
  72. package/dist/components/data/ag-grid-react/comments/comments-overlay.d.ts +21 -0
  73. package/dist/components/data/ag-grid-react/comments/comments-overlay.js +406 -0
  74. package/dist/components/data/ag-grid-react/comments/comments-panel.d.ts +9 -0
  75. package/dist/components/data/ag-grid-react/comments/comments-panel.js +272 -0
  76. package/dist/components/data/ag-grid-react/comments/comments-persist.d.ts +11 -0
  77. package/dist/components/data/ag-grid-react/comments/comments-persist.js +19 -0
  78. package/dist/components/data/ag-grid-react/comments/comments-reveal.d.ts +11 -0
  79. package/dist/components/data/ag-grid-react/comments/comments-reveal.js +31 -0
  80. package/dist/components/data/ag-grid-react/comments/comments-ui-actions.d.ts +18 -0
  81. package/dist/components/data/ag-grid-react/comments/comments-ui-actions.js +22 -0
  82. package/dist/components/data/ag-grid-react/comments/comments-window.d.ts +10 -0
  83. package/dist/components/data/ag-grid-react/comments/comments-window.js +62 -0
  84. package/dist/components/data/ag-grid-react/comments/comments.types.d.ts +178 -0
  85. package/dist/components/data/ag-grid-react/comments/index.d.ts +5 -0
  86. package/dist/components/data/ag-grid-react/comments/index.js +15 -0
  87. package/dist/components/data/ag-grid-react/comments-cell-renderers-showcase.d.ts +25 -0
  88. package/dist/components/data/ag-grid-react/comments.story-data.d.ts +37 -0
  89. package/dist/components/data/ag-grid-react/comments.story-sources.d.ts +11 -0
  90. package/dist/components/data/ag-grid-react/grid-cell-address.d.ts +21 -0
  91. package/dist/components/data/ag-grid-react/grid-cell-address.js +21 -0
  92. package/dist/components/data/ag-grid-react/grid-row-reveal.d.ts +34 -0
  93. package/dist/components/data/ag-grid-react/grid-row-reveal.js +33 -0
  94. package/dist/components/data/ag-grid-react/headers/advanced-filter/advanced-filter-dialog.js +75 -65
  95. package/dist/components/data/ag-grid-react/headers/advanced-filter/column-filter-section.d.ts +1 -1
  96. package/dist/components/data/ag-grid-react/headers/advanced-filter/column-filter-section.js +54 -54
  97. package/dist/components/data/ag-grid-react/headers/components/date-filter-picker.d.ts +1 -1
  98. package/dist/components/data/ag-grid-react/headers/header-search-input.js +122 -119
  99. package/dist/components/data/ag-grid-react/headers/utils/date-utils.d.ts +2 -1
  100. package/dist/components/data/ag-grid-react/headers/utils/date-utils.js +25 -20
  101. package/dist/components/data/ag-grid-react/headers/utils/filter-utils.d.ts +1 -1
  102. package/dist/components/data/ag-grid-react/index.d.ts +1 -1
  103. package/dist/components/data/ag-grid-react/index.js +481 -254
  104. package/dist/components/data/ag-grid-react/notes/index.d.ts +2 -0
  105. package/dist/components/data/ag-grid-react/notes/index.js +1 -0
  106. package/dist/components/data/ag-grid-react/notes/notes-ag-grid-adapter.d.ts +25 -0
  107. package/dist/components/data/ag-grid-react/notes/notes-ag-grid-adapter.js +32 -0
  108. package/dist/components/data/ag-grid-react/notes/notes-constants.d.ts +2 -0
  109. package/dist/components/data/ag-grid-react/notes/notes-constants.js +4 -0
  110. package/dist/components/data/ag-grid-react/notes/notes.types.d.ts +12 -0
  111. package/dist/components/data/ag-grid-react/notes.story-sources.d.ts +7 -0
  112. package/dist/components/data/ag-grid-react/nova-system-column.d.ts +7 -0
  113. package/dist/components/data/ag-grid-react/nova-system-column.js +18 -0
  114. package/dist/components/data/ag-grid-react/theme.js +6 -2
  115. package/dist/components/data/ag-grid-react/value-formatter.types.d.ts +4 -0
  116. package/dist/components/data/ag-grid-react/value-formatters.d.ts +0 -19
  117. package/dist/components/data/ag-grid-react/value-formatters.js +88 -90
  118. package/dist/components/data/data-table/build-column-tree-from-grid.d.ts +0 -1
  119. package/dist/components/data/data-table/build-column-tree-from-grid.js +49 -53
  120. package/dist/components/data/data-table/data-table-column-apply.d.ts +0 -2
  121. package/dist/components/data/data-table/data-table-column-apply.js +73 -84
  122. package/dist/components/data/data-table/data-table-column-def-pin.js +34 -31
  123. package/dist/components/data/data-table/data-table-column-list.js +64 -94
  124. package/dist/components/data/data-table/data-table-column-tree-cache.d.ts +6 -12
  125. package/dist/components/data/data-table/data-table-column-tree-cache.js +131 -250
  126. package/dist/components/data/data-table/data-table-context.js +5 -5
  127. package/dist/components/data/data-table/data-table-sheet-context.js +1 -1
  128. package/dist/components/data/data-table/data-table-sheet.js +2 -1
  129. package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.d.ts +0 -5
  130. package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.js +11 -28
  131. package/dist/components/data/data-table/use-data-table-column-list-sync.d.ts +0 -10
  132. package/dist/components/data/data-table/use-data-table-column-list-sync.js +196 -250
  133. package/dist/components/data/nested-list/components/NestedListContent.d.ts +2 -10
  134. package/dist/components/data/nested-list/components/NestedListContent.js +138 -253
  135. package/dist/components/data/nested-list/components/SortableItem.d.ts +1 -2
  136. package/dist/components/data/nested-list/components/SortableItem.js +60 -62
  137. package/dist/components/data/nested-list/hooks/useNestedListDragDrop.d.ts +20 -10
  138. package/dist/components/data/nested-list/hooks/useNestedListDragDrop.js +233 -44
  139. package/dist/components/data/nested-list/nested-list-constants.d.ts +1 -4
  140. package/dist/components/data/nested-list/nested-list-constants.js +4 -10
  141. package/dist/components/data/nested-list/nested-list.js +336 -322
  142. package/dist/components/data/nested-list/nested-list.types.d.ts +0 -17
  143. package/dist/components/data-display/calendar/calendar-config.js +22 -21
  144. package/dist/components/data-display/calendar/calendar-day-button.js +21 -21
  145. package/dist/components/data-display/calendar/calendar-day-picker-view.js +36 -35
  146. package/dist/components/data-display/calendar/calendar-fiscal-labels.d.ts +3 -3
  147. package/dist/components/data-display/calendar/calendar-fiscal-labels.js +50 -62
  148. package/dist/components/data-display/calendar/calendar.js +138 -137
  149. package/dist/components/data-display/calendar/fiscal-period-caption-select.js +23 -22
  150. package/dist/components/data-display/calendar/use-calendar-i18n.d.ts +1 -0
  151. package/dist/components/data-display/calendar/use-calendar-i18n.js +10 -9
  152. package/dist/components/data-display/chart/chart.js +72 -72
  153. package/dist/components/data-display/chart/chart.utils.d.ts +1 -1
  154. package/dist/components/data-display/chart/chart.utils.js +40 -31
  155. package/dist/components/feedback/sheet/sheet.js +1 -1
  156. package/dist/components/feedback/toast/toast.d.ts +1 -1
  157. package/dist/components/feedback/toast/toast.variants.d.ts +1 -1
  158. package/dist/components/flows/filter-panel/filter-panel.d.ts +1 -1
  159. package/dist/components/flows/filter-panel/filter-panel.js +65 -64
  160. package/dist/components/flows/filter-panel/filter-panel.types.d.ts +1 -0
  161. package/dist/components/forms/date-picker/date-picker.js +125 -126
  162. package/dist/components/forms/date-picker/date-range-picker.js +191 -192
  163. package/dist/components/forms/date-picker/multi-date-picker.js +66 -67
  164. package/dist/components/forms/date-picker/multi-week-picker.js +82 -83
  165. package/dist/components/forms/date-picker/use-picker-i18n.d.ts +6 -0
  166. package/dist/components/forms/date-picker/use-picker-i18n.js +11 -0
  167. package/dist/components/forms/date-picker/week-picker.js +146 -147
  168. package/dist/components/forms/date-picker/week-range-picker.js +158 -159
  169. package/dist/components/ui/local-raster-icons/message3d.webp.js +4 -0
  170. package/dist/components/ui/local-raster-icons/rasterIcons.d.ts +1 -0
  171. package/dist/components/ui/local-raster-icons/rasterIcons.js +27 -25
  172. package/dist/form-react/Fields/WeekRangePicker.js +16 -16
  173. package/dist/i18n/defaultMessages.d.ts +144 -0
  174. package/dist/i18n/defaultMessages.js +161 -19
  175. package/dist/i18n/format/collator.d.ts +1 -0
  176. package/dist/i18n/format/collator.js +7 -0
  177. package/dist/i18n/format/date-pattern.d.ts +5 -0
  178. package/dist/i18n/format/date-pattern.js +20 -0
  179. package/dist/i18n/format/format-date.d.ts +9 -0
  180. package/dist/i18n/format/format-date.js +56 -0
  181. package/dist/i18n/format/format-number.d.ts +20 -0
  182. package/dist/i18n/format/format-number.js +68 -0
  183. package/dist/i18n/format/formatter-cache.d.ts +9 -0
  184. package/dist/i18n/format/formatter-cache.js +66 -0
  185. package/dist/i18n/format/index.d.ts +6 -0
  186. package/dist/i18n/format/parse-number.d.ts +6 -0
  187. package/dist/i18n/format/parse-number.js +53 -0
  188. package/dist/i18n/getDateFnsLocale.d.ts +5 -4
  189. package/dist/i18n/getDateFnsLocale.js +46 -16
  190. package/dist/i18n/i18n.types.d.ts +13 -0
  191. package/dist/i18n/impact-nova-i18n-context.d.ts +1 -1
  192. package/dist/i18n/impact-nova-i18n-context.js +33 -25
  193. package/dist/i18n/impact-nova-i18n-defaults.js +8 -6
  194. package/dist/i18n/index.d.ts +4 -1
  195. package/dist/i18n/index.js +41 -16
  196. package/dist/i18n/locale-config.d.ts +28 -0
  197. package/dist/i18n/locale-config.js +32 -0
  198. package/dist/i18n/locales/de.js +142 -0
  199. package/dist/i18n/locales/es.js +142 -0
  200. package/dist/i18n/locales/hi.js +142 -0
  201. package/dist/i18n/locales/kn.js +142 -0
  202. package/dist/i18n/week-start.d.ts +6 -0
  203. package/dist/i18n/week-start.js +30 -0
  204. package/dist/impact-nova-components.css +249 -0
  205. package/dist/impact-nova-tokens.scss +6 -0
  206. package/dist/impact-nova.css +1 -1
  207. package/dist/index.d.ts +1 -1
  208. package/dist/index.js +624 -601
  209. package/dist/llms/index.js +26 -2
  210. package/dist/llms/rules/ag-grid.js +1 -1
  211. package/dist/llms/rules/best-practices.js +1 -1
  212. package/dist/llms/rules/data-table-chat.js +1 -0
  213. package/dist/llms/rules/data-table-comments.js +1 -0
  214. package/dist/llms/rules/data-table-notes.js +1 -0
  215. package/dist/llms/rules/installation.js +1 -1
  216. package/dist/llms/rules/migration.js +1 -1
  217. package/dist/llms/rules/real-world-patterns.js +1 -1
  218. package/dist/llms/rules/requirements.js +1 -1
  219. package/dist/llms/rules/troubleshooting.js +1 -1
  220. package/dist/providers/app-providers.d.ts +3 -1
  221. package/dist/providers/app-providers.js +22 -11
  222. package/package.json +13 -1
  223. package/dist/components/data/data-table/column-picker-authority.d.ts +0 -34
  224. package/dist/components/data/data-table/column-picker-authority.js +0 -116
  225. package/dist/components/data/data-table/column-picker-drop-validation.d.ts +0 -7
  226. package/dist/components/data/data-table/column-picker-drop-validation.js +0 -37
  227. package/dist/components/data/data-table/data-table-column-list-tree-apply.d.ts +0 -10
  228. package/dist/components/data/data-table/data-table-column-list-tree-apply.js +0 -79
  229. package/dist/components/data/data-table/data-table-flat-column-virtual-rows.d.ts +0 -26
  230. package/dist/components/data/data-table/data-table-flat-column-virtual-rows.js +0 -195
  231. package/dist/components/data/data-table/data-table-picker-column-eligibility.d.ts +0 -1
  232. package/dist/components/data/data-table/data-table-picker-column-eligibility.js +0 -7
  233. package/dist/components/data/data-table/reconcile-column-tree-from-grid.d.ts +0 -12
  234. package/dist/components/data/data-table/reconcile-column-tree-from-grid.js +0 -12
  235. package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.d.ts +0 -24
  236. package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.js +0 -128
  237. package/dist/components/data/nested-list/nested-list-display-utils.d.ts +0 -11
  238. package/dist/components/data/nested-list/nested-list-display-utils.js +0 -74
  239. package/dist/components/data/nested-list/nested-list-drop-engine.d.ts +0 -31
  240. package/dist/components/data/nested-list/nested-list-drop-engine.js +0 -209
  241. package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.d.ts +0 -26
  242. package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.js +0 -67
  243. package/dist/components/data/nested-list/nested-list-item-tree-mutations.d.ts +0 -4
  244. package/dist/components/data/nested-list/nested-list-item-tree-mutations.js +0 -43
  245. package/dist/components/data/nested-list/nested-list-lazy-flat-rows.d.ts +0 -3
  246. package/dist/components/data/nested-list/nested-list-lazy-flat-rows.js +0 -34
  247. package/dist/components/data/nested-list/nested-list-row-estimates.d.ts +0 -9
  248. package/dist/components/data/nested-list/nested-list-row-estimates.js +0 -14
  249. package/dist/components/data/nested-list/nested-list-scroll-anchor.d.ts +0 -36
  250. package/dist/components/data/nested-list/nested-list-scroll-anchor.js +0 -47
  251. package/dist/components/data/nested-list/nested-list-virtual-drop.d.ts +0 -59
  252. package/dist/components/data/nested-list/nested-list-virtual-drop.js +0 -341
  253. package/dist/lib/hash/fnv1a128.d.ts +0 -16
  254. package/dist/lib/hash/fnv1a128.js +0 -21
@@ -1,36 +0,0 @@
1
- import { VirtualDropRowGeometry } from './nested-list-virtual-drop';
2
- export interface NestedListScrollAnchorCapture {
3
- anchorItemId: string;
4
- anchorRowIndex: number;
5
- anchorTopInViewport: number;
6
- }
7
- export declare function findNestedListRowIndexByItemId(options: {
8
- rowCount: number;
9
- getRowAtIndex: (index: number) => {
10
- item: {
11
- id: string;
12
- };
13
- } | undefined;
14
- anchorItemId: string;
15
- }): number;
16
- export declare function resolveNestedListRowOffset(options: {
17
- virtualizer: VirtualDropRowGeometry;
18
- rowIndex: number;
19
- estimateRowSize: (index: number) => number;
20
- }): number;
21
- export declare function captureNestedListScrollAnchor(options: {
22
- scrollElement: HTMLElement;
23
- anchorItemId: string;
24
- anchorRowIndex: number;
25
- rowOffset: number;
26
- }): NestedListScrollAnchorCapture | null;
27
- export declare function computeAnchoredScrollTop(options: {
28
- newRowOffset: number;
29
- anchorTopInViewport: number;
30
- }): number;
31
- export declare function restoreNestedListScrollAnchor(options: {
32
- scrollElement: HTMLElement;
33
- capture: NestedListScrollAnchorCapture;
34
- virtualizer: VirtualDropRowGeometry;
35
- estimateRowSize: (index: number) => number;
36
- }): void;
@@ -1,47 +0,0 @@
1
- function u(e) {
2
- for (let r = 0; r < e.rowCount; r += 1)
3
- if (e.getRowAtIndex(r)?.item.id === e.anchorItemId)
4
- return r;
5
- return -1;
6
- }
7
- function c(e) {
8
- if (e.rowIndex <= 0)
9
- return 0;
10
- const r = e.virtualizer.measurementsCache[e.rowIndex]?.start;
11
- if (r !== void 0)
12
- return r;
13
- let n = 0;
14
- for (let t = 0; t < e.rowIndex; t += 1) {
15
- const o = e.virtualizer.measurementsCache[t]?.size;
16
- n += o && o > 0 ? o : e.estimateRowSize(t);
17
- }
18
- return n;
19
- }
20
- function l(e) {
21
- return e.anchorRowIndex < 0 ? null : {
22
- anchorItemId: e.anchorItemId,
23
- anchorRowIndex: e.anchorRowIndex,
24
- anchorTopInViewport: e.rowOffset - e.scrollElement.scrollTop
25
- };
26
- }
27
- function a(e) {
28
- return Math.max(0, e.newRowOffset - e.anchorTopInViewport);
29
- }
30
- function w(e) {
31
- const r = c({
32
- virtualizer: e.virtualizer,
33
- rowIndex: e.capture.anchorRowIndex,
34
- estimateRowSize: e.estimateRowSize
35
- });
36
- e.scrollElement.scrollTop = a({
37
- newRowOffset: r,
38
- anchorTopInViewport: e.capture.anchorTopInViewport
39
- });
40
- }
41
- export {
42
- l as captureNestedListScrollAnchor,
43
- a as computeAnchoredScrollTop,
44
- u as findNestedListRowIndexByItemId,
45
- c as resolveNestedListRowOffset,
46
- w as restoreNestedListScrollAnchor
47
- };
@@ -1,59 +0,0 @@
1
- import { NestedListItem } from './nested-list.types';
2
- export type FlatNestedListRow = {
3
- item: NestedListItem;
4
- level: number;
5
- indentLevel: number;
6
- };
7
- export type VirtualDropTarget = {
8
- overId: string;
9
- insertAfter: boolean;
10
- flatIndex: number;
11
- };
12
- export declare function resolveSectionHeaderDropTarget(items: FlatNestedListRow[], sectionId: string): {
13
- overId: string;
14
- insertAfter: boolean;
15
- } | null;
16
- /**
17
- * Maps group-header pointer targets to commit-safe drop targets.
18
- * insertAfter on a group header (gap before first child) must target the first
19
- * child leaf so cross-group moves pass column-picker validation.
20
- */
21
- export declare function resolveGroupHeaderDropTarget(items: FlatNestedListRow[], groupId: string, insertAfter: boolean, collapsedItems?: Record<string, boolean>): {
22
- overId: string;
23
- insertAfter: boolean;
24
- };
25
- export declare function resolveSectionDroppableFromDomHit(clientX: number, clientY: number, scrollElement: HTMLElement): string | null;
26
- export interface VirtualDropRowGeometry {
27
- measurementsCache: Array<{
28
- start: number;
29
- size: number;
30
- }>;
31
- getTotalSize: () => number;
32
- }
33
- export interface ResolveVirtualDropTargetOptions {
34
- clientX: number;
35
- clientY: number;
36
- scrollElement: HTMLElement;
37
- items: FlatNestedListRow[];
38
- virtualizer: VirtualDropRowGeometry;
39
- estimateRowSize: (index: number) => number;
40
- offsetCacheHolder?: {
41
- current: VirtualDropRowOffsetCache | null;
42
- };
43
- collapsedItems?: Record<string, boolean>;
44
- }
45
- export interface VirtualDropRowOffsetCache {
46
- rowCount: number;
47
- measurementFingerprint: number;
48
- offsets: number[];
49
- sizes: number[];
50
- }
51
- export declare function resolveVirtualDropTarget(options: ResolveVirtualDropTargetOptions): VirtualDropTarget | null;
52
- export declare function insertGapIndexFromDropTarget(items: FlatNestedListRow[], target: Pick<VirtualDropTarget, 'overId' | 'insertAfter'>): number | null;
53
- export declare function getInsertGapOffsetY(insertGapIndex: number, virtualizer: VirtualDropRowGeometry, estimateRowSize: (index: number) => number, rowCount: number): number;
54
- export declare function isInsertGapVisibleOnMountedRows(insertGapIndex: number, mountedRowIndices: number[], rowCount: number): boolean;
55
- export declare function clampPointerToScrollBounds(clientX: number, clientY: number, scrollRect: DOMRect): {
56
- pointerX: number;
57
- pointerY: number;
58
- isInsideScrollContainer: boolean;
59
- };
@@ -1,341 +0,0 @@
1
- import { getSectionIdFromDroppable as w } from "./nested-list-drop-engine.js";
2
- import { NESTED_LIST_SECTION_IDS as p } from "./nested-list-constants.js";
3
- function z(t, e) {
4
- for (let n = e + 1; n < t.length; n += 1) {
5
- const r = t[n];
6
- if (p.has(r.item.id))
7
- return !1;
8
- if (r.item.category !== "structure")
9
- return !0;
10
- }
11
- return !1;
12
- }
13
- function A(t, e) {
14
- const n = t.findIndex((o) => o.item.id === e);
15
- if (n === -1)
16
- return null;
17
- if (!z(t, n))
18
- return { overId: `droppable-${e}`, insertAfter: !1 };
19
- for (let o = n + 1; o < t.length; o += 1) {
20
- const i = t[o];
21
- if (p.has(i.item.id))
22
- break;
23
- if (i.item.category !== "structure")
24
- return { overId: i.item.id, insertAfter: !1 };
25
- }
26
- const r = t.slice(0, n).filter(
27
- (o) => !p.has(o.item.id)
28
- );
29
- return r.length > 0 ? {
30
- overId: r[r.length - 1].item.id,
31
- insertAfter: !0
32
- } : null;
33
- }
34
- function M(t, e) {
35
- const n = t[e].level;
36
- for (let r = e + 1; r < t.length; r += 1) {
37
- const o = t[r];
38
- if (o.level <= n)
39
- return !1;
40
- if (o.item.category !== "structure")
41
- return !0;
42
- }
43
- return !1;
44
- }
45
- function R(t, e, n, r = {}) {
46
- if (!n)
47
- return { overId: e, insertAfter: n };
48
- if (r[e] === !0)
49
- return { overId: e, insertAfter: !0 };
50
- const o = t.findIndex((s) => s.item.id === e);
51
- if (o === -1 || !M(t, o))
52
- return { overId: e, insertAfter: n };
53
- const i = t[o].level;
54
- for (let s = o + 1; s < t.length; s += 1) {
55
- const l = t[s];
56
- if (l.level <= i)
57
- break;
58
- if (l.item.category !== "structure")
59
- return { overId: l.item.id, insertAfter: !1 };
60
- }
61
- return { overId: e, insertAfter: !0 };
62
- }
63
- function y(t, e, n) {
64
- const r = document.elementFromPoint(t, e);
65
- if (!r || !n.contains(r))
66
- return null;
67
- const o = r.closest("[data-section-droppable]");
68
- if (!(o instanceof HTMLElement) || !n.contains(o))
69
- return null;
70
- const i = o.getAttribute("data-section-droppable");
71
- return !i || !p.has(i) ? null : `droppable-${i}`;
72
- }
73
- function D(t, e, n, r) {
74
- if (e <= 0)
75
- return 0;
76
- let o = 0, i = e - 1;
77
- for (; o < i; ) {
78
- const s = Math.floor((o + i) / 2), l = n(s), u = Math.max(r(s), 1), f = l + u;
79
- if (t < l)
80
- i = s - 1;
81
- else if (t >= f)
82
- o = s + 1;
83
- else
84
- return s;
85
- }
86
- return Math.max(0, Math.min(o, e - 1));
87
- }
88
- function E(t, e, n, r, o, i) {
89
- const s = e.querySelector(`[data-index="${r}"]`);
90
- if (s instanceof HTMLElement) {
91
- const c = s.getBoundingClientRect(), d = c.top + c.height / 2;
92
- return t >= d;
93
- }
94
- const l = e.querySelector(`[data-item-id="${n}"]`);
95
- if (l instanceof HTMLElement) {
96
- const c = l.getBoundingClientRect(), d = c.top + c.height / 2;
97
- return t >= d;
98
- }
99
- const f = e.getBoundingClientRect().top + o(r) - e.scrollTop, h = i(r), a = f + h / 2;
100
- return t >= a;
101
- }
102
- function O(t) {
103
- let e = 0;
104
- for (let n = 0; n < t.measurementsCache.length; n += 1)
105
- e = e * 31 + t.measurementsCache[n].size | 0;
106
- return e;
107
- }
108
- function H(t, e, n, r) {
109
- const o = e.measurementsCache.some(
110
- (u) => u.size > 0
111
- ), i = O(e), s = r?.current;
112
- if (s && s.rowCount === t && s.measurementFingerprint === i)
113
- return {
114
- offsets: s.offsets,
115
- sizes: s.sizes
116
- };
117
- const l = o ? L(e, t, n) : C(t, n);
118
- return r && (r.current = {
119
- rowCount: t,
120
- measurementFingerprint: i,
121
- offsets: l.offsets,
122
- sizes: l.sizes
123
- }), l;
124
- }
125
- function C(t, e) {
126
- const n = new Array(t), r = new Array(t);
127
- let o = 0;
128
- for (let i = 0; i < t; i += 1) {
129
- const s = e(i);
130
- n[i] = o, r[i] = s, o += s;
131
- }
132
- return { offsets: n, sizes: r };
133
- }
134
- function L(t, e, n) {
135
- const r = t.measurementsCache, o = new Array(e), i = new Array(e);
136
- let s = 0;
137
- for (let l = 0; l < e; l += 1) {
138
- const u = r[l]?.size, f = u && u > 0 ? u : n(l);
139
- o[l] = s, i[l] = f, s += f;
140
- }
141
- return { offsets: o, sizes: i };
142
- }
143
- function B(t) {
144
- for (let e = t.length - 1; e >= 0; e -= 1) {
145
- const n = t[e];
146
- if (!(!n || p.has(n.item.id)) && n.item.category !== "structure")
147
- return e;
148
- }
149
- return Math.max(0, t.length - 1);
150
- }
151
- function V(t, e, n) {
152
- const r = document.elementFromPoint(t, e);
153
- if (!r || !n.contains(r) || r.closest('[data-slot="drag-drop-tail"]'))
154
- return null;
155
- const o = r.closest("[data-index]");
156
- if (!(o instanceof HTMLElement) || !n.contains(o))
157
- return null;
158
- const i = Number(o.getAttribute("data-index"));
159
- return Number.isFinite(i) ? i : null;
160
- }
161
- function P(t, e, n, r) {
162
- const o = r.getTotalSize();
163
- if (o > 0)
164
- return o;
165
- if (t <= 0)
166
- return 0;
167
- const i = t - 1;
168
- return e(i) + n(i);
169
- }
170
- function N(t, e, n, r) {
171
- if (document.elementFromPoint(t, e)?.closest('[data-slot="drag-drop-tail"]'))
172
- return !0;
173
- const i = n.getBoundingClientRect();
174
- return e - i.top + n.scrollTop >= r;
175
- }
176
- function v(t) {
177
- const {
178
- clientY: e,
179
- scrollElement: n,
180
- items: r,
181
- flatIndex: o,
182
- getRowOffset: i,
183
- getRowSize: s,
184
- forceInsertAfter: l = !1,
185
- collapsedItems: u = {}
186
- } = t, f = Math.max(0, Math.min(o, r.length - 1)), h = r[f];
187
- if (!h)
188
- return null;
189
- let a = h.item.id, c = l || E(
190
- e,
191
- n,
192
- a,
193
- f,
194
- i,
195
- s
196
- ), d = f;
197
- if (p.has(a)) {
198
- const g = A(r, a);
199
- if (!g)
200
- return null;
201
- a = g.overId, c = g.insertAfter;
202
- const I = r.findIndex((x) => x.item.id === a);
203
- d = I === -1 ? f : I;
204
- } else if (h.item.category === "group") {
205
- const g = R(
206
- r,
207
- a,
208
- c,
209
- u
210
- );
211
- a = g.overId, c = g.insertAfter;
212
- const I = r.findIndex((x) => x.item.id === a);
213
- d = I === -1 ? f : I;
214
- }
215
- return {
216
- overId: a,
217
- insertAfter: c,
218
- flatIndex: d
219
- };
220
- }
221
- function _(t) {
222
- const {
223
- clientX: e,
224
- clientY: n,
225
- scrollElement: r,
226
- items: o,
227
- virtualizer: i,
228
- estimateRowSize: s,
229
- offsetCacheHolder: l,
230
- collapsedItems: u = {}
231
- } = t;
232
- if (o.length === 0)
233
- return null;
234
- const f = y(
235
- e,
236
- n,
237
- r
238
- );
239
- if (f) {
240
- const m = w(f), S = m ? o.findIndex((b) => b.item.id === m) : -1;
241
- return {
242
- overId: f,
243
- insertAfter: !1,
244
- flatIndex: S === -1 ? 0 : S
245
- };
246
- }
247
- const { offsets: h, sizes: a } = H(
248
- o.length,
249
- i,
250
- s,
251
- l
252
- ), c = (m) => h[m] ?? 0, d = (m) => a[m] ?? s(m), g = P(
253
- o.length,
254
- c,
255
- d,
256
- i
257
- );
258
- if (N(e, n, r, g)) {
259
- const m = B(o);
260
- return v({
261
- clientY: n,
262
- scrollElement: r,
263
- items: o,
264
- flatIndex: m,
265
- getRowOffset: c,
266
- getRowSize: d,
267
- forceInsertAfter: !0,
268
- collapsedItems: u
269
- });
270
- }
271
- const I = V(e, n, r);
272
- if (I !== null)
273
- return v({
274
- clientY: n,
275
- scrollElement: r,
276
- items: o,
277
- flatIndex: I,
278
- getRowOffset: c,
279
- getRowSize: d,
280
- collapsedItems: u
281
- });
282
- const x = r.getBoundingClientRect(), F = n - x.top + r.scrollTop, T = D(
283
- F,
284
- o.length,
285
- c,
286
- d
287
- );
288
- return v({
289
- clientY: n,
290
- scrollElement: r,
291
- items: o,
292
- flatIndex: T,
293
- getRowOffset: c,
294
- getRowSize: d,
295
- collapsedItems: u
296
- });
297
- }
298
- function k(t, e) {
299
- const n = w(e.overId);
300
- if (n) {
301
- const o = t.findIndex((i) => i.item.id === n);
302
- return o === -1 ? null : e.insertAfter ? o + 1 : o;
303
- }
304
- const r = t.findIndex((o) => o.item.id === e.overId);
305
- return r === -1 ? null : e.insertAfter ? r + 1 : r;
306
- }
307
- function q(t, e, n, r) {
308
- if (t <= 0)
309
- return 0;
310
- if (t >= r)
311
- return e.getTotalSize();
312
- const o = e.measurementsCache[t]?.start;
313
- if (o !== void 0)
314
- return o;
315
- let i = 0;
316
- for (let s = 0; s < t; s += 1) {
317
- const l = e.measurementsCache[s]?.size;
318
- i += l && l > 0 ? l : n(s);
319
- }
320
- return i;
321
- }
322
- function G(t, e, n) {
323
- return t < n ? e.includes(t) : t === n ? e.includes(n - 1) : !1;
324
- }
325
- function Z(t, e, n) {
326
- return t >= n.left && t <= n.right && e >= n.top && e <= n.bottom ? { pointerX: t, pointerY: e, isInsideScrollContainer: !0 } : {
327
- pointerX: Math.min(Math.max(t, n.left + 12), n.right - 12),
328
- pointerY: Math.min(Math.max(e, n.top + 12), n.bottom - 12),
329
- isInsideScrollContainer: !1
330
- };
331
- }
332
- export {
333
- Z as clampPointerToScrollBounds,
334
- q as getInsertGapOffsetY,
335
- k as insertGapIndexFromDropTarget,
336
- G as isInsertGapVisibleOnMountedRows,
337
- R as resolveGroupHeaderDropTarget,
338
- y as resolveSectionDroppableFromDomHit,
339
- A as resolveSectionHeaderDropTarget,
340
- _ as resolveVirtualDropTarget
341
- };
@@ -1,16 +0,0 @@
1
- /**
2
- * FNV-1a 128-bit hash implemented as two independent 64-bit halves.
3
- * Produces a 32-char hex string deterministically from a stream of string tokens.
4
- *
5
- * Used for column-tree fingerprints where O(N) CPU is acceptable but multi-MB
6
- * string allocations are not. The 128-bit width makes collision probability
7
- * negligible (~1 in 2^128) while keeping output fixed at 32 bytes.
8
- */
9
- export declare class Fnv1a128Hasher {
10
- private high;
11
- private low;
12
- update(input: string): this;
13
- digest(): string;
14
- reset(): this;
15
- }
16
- export declare function fnv1a128(input: string): string;
@@ -1,21 +0,0 @@
1
- const s = BigInt("0x6c62272e07bb0142"), n = BigInt("0x62b821756295c58d"), o = BigInt("0x0000000001000000"), r = BigInt("0x000000000000013b"), f = BigInt("0xffffffffffffffff");
2
- class g {
3
- high = s;
4
- low = n;
5
- update(h) {
6
- for (let t = 0; t < h.length; t++) {
7
- const i = BigInt(h.charCodeAt(t) & 255);
8
- this.high = (this.high ^ i) * o & f, this.low = (this.low ^ i) * r & f;
9
- }
10
- return this;
11
- }
12
- digest() {
13
- return this.high.toString(16).padStart(16, "0") + this.low.toString(16).padStart(16, "0");
14
- }
15
- reset() {
16
- return this.high = s, this.low = n, this;
17
- }
18
- }
19
- export {
20
- g as Fnv1a128Hasher
21
- };