@nu-grid/nuxt 0.1.1

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 (348) hide show
  1. package/LICENSE.md +21 -0
  2. package/README.md +261 -0
  3. package/dist/module.d.mts +13 -0
  4. package/dist/module.json +9 -0
  5. package/dist/module.mjs +52 -0
  6. package/dist/runtime/cell-types/action-menu/ActionMenuRenderer.d.vue.ts +12 -0
  7. package/dist/runtime/cell-types/action-menu/ActionMenuRenderer.vue +123 -0
  8. package/dist/runtime/cell-types/action-menu/ActionMenuRenderer.vue.d.ts +12 -0
  9. package/dist/runtime/cell-types/action-menu/index.d.ts +8 -0
  10. package/dist/runtime/cell-types/action-menu/index.js +28 -0
  11. package/dist/runtime/cell-types/boolean/BooleanEditor.d.vue.ts +15 -0
  12. package/dist/runtime/cell-types/boolean/BooleanEditor.vue +32 -0
  13. package/dist/runtime/cell-types/boolean/BooleanEditor.vue.d.ts +15 -0
  14. package/dist/runtime/cell-types/boolean/BooleanFilter.d.vue.ts +7 -0
  15. package/dist/runtime/cell-types/boolean/BooleanFilter.vue +42 -0
  16. package/dist/runtime/cell-types/boolean/BooleanFilter.vue.d.ts +7 -0
  17. package/dist/runtime/cell-types/boolean/BooleanRenderer.d.vue.ts +13 -0
  18. package/dist/runtime/cell-types/boolean/BooleanRenderer.vue +23 -0
  19. package/dist/runtime/cell-types/boolean/BooleanRenderer.vue.d.ts +13 -0
  20. package/dist/runtime/cell-types/boolean/index.d.ts +8 -0
  21. package/dist/runtime/cell-types/boolean/index.js +31 -0
  22. package/dist/runtime/cell-types/currency/CurrencyEditor.d.vue.ts +15 -0
  23. package/dist/runtime/cell-types/currency/CurrencyEditor.vue +40 -0
  24. package/dist/runtime/cell-types/currency/CurrencyEditor.vue.d.ts +15 -0
  25. package/dist/runtime/cell-types/currency/CurrencyFilter.d.vue.ts +7 -0
  26. package/dist/runtime/cell-types/currency/CurrencyFilter.vue +76 -0
  27. package/dist/runtime/cell-types/currency/CurrencyFilter.vue.d.ts +7 -0
  28. package/dist/runtime/cell-types/currency/index.d.ts +6 -0
  29. package/dist/runtime/cell-types/currency/index.js +42 -0
  30. package/dist/runtime/cell-types/date/DateEditor.d.vue.ts +15 -0
  31. package/dist/runtime/cell-types/date/DateEditor.vue +42 -0
  32. package/dist/runtime/cell-types/date/DateEditor.vue.d.ts +15 -0
  33. package/dist/runtime/cell-types/date/DateFilter.d.vue.ts +7 -0
  34. package/dist/runtime/cell-types/date/DateFilter.vue +58 -0
  35. package/dist/runtime/cell-types/date/DateFilter.vue.d.ts +7 -0
  36. package/dist/runtime/cell-types/date/index.d.ts +6 -0
  37. package/dist/runtime/cell-types/date/index.js +13 -0
  38. package/dist/runtime/cell-types/index.d.ts +17 -0
  39. package/dist/runtime/cell-types/index.js +34 -0
  40. package/dist/runtime/cell-types/lookup/LookupEditor.d.vue.ts +15 -0
  41. package/dist/runtime/cell-types/lookup/LookupEditor.vue +291 -0
  42. package/dist/runtime/cell-types/lookup/LookupEditor.vue.d.ts +15 -0
  43. package/dist/runtime/cell-types/lookup/LookupRenderer.d.vue.ts +8 -0
  44. package/dist/runtime/cell-types/lookup/LookupRenderer.vue +43 -0
  45. package/dist/runtime/cell-types/lookup/LookupRenderer.vue.d.ts +8 -0
  46. package/dist/runtime/cell-types/lookup/index.d.ts +36 -0
  47. package/dist/runtime/cell-types/lookup/index.js +50 -0
  48. package/dist/runtime/cell-types/number/NumberEditor.d.vue.ts +15 -0
  49. package/dist/runtime/cell-types/number/NumberEditor.vue +34 -0
  50. package/dist/runtime/cell-types/number/NumberEditor.vue.d.ts +15 -0
  51. package/dist/runtime/cell-types/number/NumberFilter.d.vue.ts +7 -0
  52. package/dist/runtime/cell-types/number/NumberFilter.vue +66 -0
  53. package/dist/runtime/cell-types/number/NumberFilter.vue.d.ts +7 -0
  54. package/dist/runtime/cell-types/number/index.d.ts +6 -0
  55. package/dist/runtime/cell-types/number/index.js +13 -0
  56. package/dist/runtime/cell-types/rating/RatingEditor.d.vue.ts +15 -0
  57. package/dist/runtime/cell-types/rating/RatingEditor.vue +219 -0
  58. package/dist/runtime/cell-types/rating/RatingEditor.vue.d.ts +15 -0
  59. package/dist/runtime/cell-types/rating/RatingFilter.d.vue.ts +7 -0
  60. package/dist/runtime/cell-types/rating/RatingFilter.vue +74 -0
  61. package/dist/runtime/cell-types/rating/RatingFilter.vue.d.ts +7 -0
  62. package/dist/runtime/cell-types/rating/RatingRenderer.d.vue.ts +10 -0
  63. package/dist/runtime/cell-types/rating/RatingRenderer.vue +75 -0
  64. package/dist/runtime/cell-types/rating/RatingRenderer.vue.d.ts +10 -0
  65. package/dist/runtime/cell-types/rating/index.d.ts +6 -0
  66. package/dist/runtime/cell-types/rating/index.js +67 -0
  67. package/dist/runtime/cell-types/selection/SelectionEditor.d.vue.ts +15 -0
  68. package/dist/runtime/cell-types/selection/SelectionEditor.vue +42 -0
  69. package/dist/runtime/cell-types/selection/SelectionEditor.vue.d.ts +15 -0
  70. package/dist/runtime/cell-types/selection/SelectionRenderer.d.vue.ts +14 -0
  71. package/dist/runtime/cell-types/selection/SelectionRenderer.vue +25 -0
  72. package/dist/runtime/cell-types/selection/SelectionRenderer.vue.d.ts +14 -0
  73. package/dist/runtime/cell-types/selection/index.d.ts +8 -0
  74. package/dist/runtime/cell-types/selection/index.js +36 -0
  75. package/dist/runtime/cell-types/text/TextEditor.d.vue.ts +15 -0
  76. package/dist/runtime/cell-types/text/TextEditor.vue +70 -0
  77. package/dist/runtime/cell-types/text/TextEditor.vue.d.ts +15 -0
  78. package/dist/runtime/cell-types/text/TextFilter.d.vue.ts +7 -0
  79. package/dist/runtime/cell-types/text/TextFilter.vue +50 -0
  80. package/dist/runtime/cell-types/text/TextFilter.vue.d.ts +7 -0
  81. package/dist/runtime/cell-types/text/TextareaEditor.d.vue.ts +15 -0
  82. package/dist/runtime/cell-types/text/TextareaEditor.vue +100 -0
  83. package/dist/runtime/cell-types/text/TextareaEditor.vue.d.ts +15 -0
  84. package/dist/runtime/cell-types/text/index.d.ts +10 -0
  85. package/dist/runtime/cell-types/text/index.js +16 -0
  86. package/dist/runtime/cell-types/text/textarea.d.ts +13 -0
  87. package/dist/runtime/cell-types/text/textarea.js +13 -0
  88. package/dist/runtime/components/NuGrid.d.vue.ts +96 -0
  89. package/dist/runtime/components/NuGrid.vue +651 -0
  90. package/dist/runtime/components/NuGrid.vue.d.ts +96 -0
  91. package/dist/runtime/components/NuGridCellCheckbox.d.vue.ts +24 -0
  92. package/dist/runtime/components/NuGridCellCheckbox.vue +105 -0
  93. package/dist/runtime/components/NuGridCellCheckbox.vue.d.ts +24 -0
  94. package/dist/runtime/components/NuGridGroup.d.vue.ts +20 -0
  95. package/dist/runtime/components/NuGridGroup.vue +650 -0
  96. package/dist/runtime/components/NuGridGroup.vue.d.ts +20 -0
  97. package/dist/runtime/components/NuGridLazyCell.d.vue.ts +62 -0
  98. package/dist/runtime/components/NuGridLazyCell.vue +133 -0
  99. package/dist/runtime/components/NuGridLazyCell.vue.d.ts +62 -0
  100. package/dist/runtime/components/_internal/NuGridAddRow.d.vue.ts +36 -0
  101. package/dist/runtime/components/_internal/NuGridAddRow.vue +144 -0
  102. package/dist/runtime/components/_internal/NuGridAddRow.vue.d.ts +36 -0
  103. package/dist/runtime/components/_internal/NuGridBase.d.vue.ts +20 -0
  104. package/dist/runtime/components/_internal/NuGridBase.vue +1172 -0
  105. package/dist/runtime/components/_internal/NuGridBase.vue.d.ts +20 -0
  106. package/dist/runtime/components/_internal/NuGridCellContent.d.vue.ts +9 -0
  107. package/dist/runtime/components/_internal/NuGridCellContent.vue +202 -0
  108. package/dist/runtime/components/_internal/NuGridCellContent.vue.d.ts +9 -0
  109. package/dist/runtime/components/_internal/NuGridColumnMenu.d.vue.ts +25 -0
  110. package/dist/runtime/components/_internal/NuGridColumnMenu.vue +391 -0
  111. package/dist/runtime/components/_internal/NuGridColumnMenu.vue.d.ts +25 -0
  112. package/dist/runtime/components/_internal/NuGridGroup.d.vue.ts +20 -0
  113. package/dist/runtime/components/_internal/NuGridGroup.vue +650 -0
  114. package/dist/runtime/components/_internal/NuGridGroup.vue.d.ts +20 -0
  115. package/dist/runtime/components/_internal/NuGridGroupCheckbox.d.vue.ts +22 -0
  116. package/dist/runtime/components/_internal/NuGridGroupCheckbox.vue +132 -0
  117. package/dist/runtime/components/_internal/NuGridGroupCheckbox.vue.d.ts +22 -0
  118. package/dist/runtime/components/_internal/NuGridHeaderSortButton.d.vue.ts +31 -0
  119. package/dist/runtime/components/_internal/NuGridHeaderSortButton.vue +61 -0
  120. package/dist/runtime/components/_internal/NuGridHeaderSortButton.vue.d.ts +31 -0
  121. package/dist/runtime/components/_internal/NuGridPaging.d.vue.ts +3 -0
  122. package/dist/runtime/components/_internal/NuGridPaging.vue +65 -0
  123. package/dist/runtime/components/_internal/NuGridPaging.vue.d.ts +3 -0
  124. package/dist/runtime/components/_internal/NuGridRow.d.vue.ts +40 -0
  125. package/dist/runtime/components/_internal/NuGridRow.vue +645 -0
  126. package/dist/runtime/components/_internal/NuGridRow.vue.d.ts +40 -0
  127. package/dist/runtime/components/_internal/NuGridSplitGroup.d.vue.ts +20 -0
  128. package/dist/runtime/components/_internal/NuGridSplitGroup.vue +735 -0
  129. package/dist/runtime/components/_internal/NuGridSplitGroup.vue.d.ts +20 -0
  130. package/dist/runtime/components/_internal/NuGridTooltip.d.vue.ts +3 -0
  131. package/dist/runtime/components/_internal/NuGridTooltip.vue +36 -0
  132. package/dist/runtime/components/_internal/NuGridTooltip.vue.d.ts +3 -0
  133. package/dist/runtime/composables/_internal/index.d.ts +31 -0
  134. package/dist/runtime/composables/_internal/index.js +28 -0
  135. package/dist/runtime/composables/_internal/keyboard-handlers/index.d.ts +5 -0
  136. package/dist/runtime/composables/_internal/keyboard-handlers/index.js +9 -0
  137. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardCellTypeDispatch.d.ts +18 -0
  138. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardCellTypeDispatch.js +53 -0
  139. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardEditingTriggers.d.ts +12 -0
  140. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardEditingTriggers.js +53 -0
  141. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardNavigation.d.ts +9 -0
  142. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardNavigation.js +35 -0
  143. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardSetup.d.ts +33 -0
  144. package/dist/runtime/composables/_internal/keyboard-handlers/useKeyboardSetup.js +111 -0
  145. package/dist/runtime/composables/_internal/keyboard-handlers/usePagingKeyboard.d.ts +11 -0
  146. package/dist/runtime/composables/_internal/keyboard-handlers/usePagingKeyboard.js +67 -0
  147. package/dist/runtime/composables/_internal/useNuGridActionMenu.d.ts +15 -0
  148. package/dist/runtime/composables/_internal/useNuGridActionMenu.js +137 -0
  149. package/dist/runtime/composables/_internal/useNuGridAddRow.d.ts +39 -0
  150. package/dist/runtime/composables/_internal/useNuGridAddRow.js +735 -0
  151. package/dist/runtime/composables/_internal/useNuGridAnimation.d.ts +33 -0
  152. package/dist/runtime/composables/_internal/useNuGridAnimation.js +178 -0
  153. package/dist/runtime/composables/_internal/useNuGridAutosize.d.ts +14 -0
  154. package/dist/runtime/composables/_internal/useNuGridAutosize.js +161 -0
  155. package/dist/runtime/composables/_internal/useNuGridCellEditing.d.ts +15 -0
  156. package/dist/runtime/composables/_internal/useNuGridCellEditing.js +1243 -0
  157. package/dist/runtime/composables/_internal/useNuGridColumnDragDrop.d.ts +8 -0
  158. package/dist/runtime/composables/_internal/useNuGridColumnDragDrop.js +148 -0
  159. package/dist/runtime/composables/_internal/useNuGridColumnPinning.d.ts +15 -0
  160. package/dist/runtime/composables/_internal/useNuGridColumnPinning.js +44 -0
  161. package/dist/runtime/composables/_internal/useNuGridColumnResize.d.ts +22 -0
  162. package/dist/runtime/composables/_internal/useNuGridColumnResize.js +427 -0
  163. package/dist/runtime/composables/_internal/useNuGridCore.d.ts +62 -0
  164. package/dist/runtime/composables/_internal/useNuGridCore.js +359 -0
  165. package/dist/runtime/composables/_internal/useNuGridExcel.d.ts +60 -0
  166. package/dist/runtime/composables/_internal/useNuGridExcel.js +35 -0
  167. package/dist/runtime/composables/_internal/useNuGridFocus.d.ts +15 -0
  168. package/dist/runtime/composables/_internal/useNuGridFocus.js +1378 -0
  169. package/dist/runtime/composables/_internal/useNuGridGroupSelection.d.ts +13 -0
  170. package/dist/runtime/composables/_internal/useNuGridGroupSelection.js +38 -0
  171. package/dist/runtime/composables/_internal/useNuGridGrouping.d.ts +28 -0
  172. package/dist/runtime/composables/_internal/useNuGridGrouping.js +211 -0
  173. package/dist/runtime/composables/_internal/useNuGridInteractionRouter.d.ts +9 -0
  174. package/dist/runtime/composables/_internal/useNuGridInteractionRouter.js +441 -0
  175. package/dist/runtime/composables/_internal/useNuGridInteractions.d.ts +10 -0
  176. package/dist/runtime/composables/_internal/useNuGridInteractions.js +36 -0
  177. package/dist/runtime/composables/_internal/useNuGridKeyboardNavigation.d.ts +54 -0
  178. package/dist/runtime/composables/_internal/useNuGridKeyboardNavigation.js +407 -0
  179. package/dist/runtime/composables/_internal/useNuGridPaging.d.ts +76 -0
  180. package/dist/runtime/composables/_internal/useNuGridPaging.js +147 -0
  181. package/dist/runtime/composables/_internal/useNuGridRowDragDrop.d.ts +68 -0
  182. package/dist/runtime/composables/_internal/useNuGridRowDragDrop.js +295 -0
  183. package/dist/runtime/composables/_internal/useNuGridRowSelection.d.ts +14 -0
  184. package/dist/runtime/composables/_internal/useNuGridRowSelection.js +214 -0
  185. package/dist/runtime/composables/_internal/useNuGridScroll.d.ts +110 -0
  186. package/dist/runtime/composables/_internal/useNuGridScroll.js +463 -0
  187. package/dist/runtime/composables/_internal/useNuGridScrollState.d.ts +32 -0
  188. package/dist/runtime/composables/_internal/useNuGridScrollState.js +60 -0
  189. package/dist/runtime/composables/_internal/useNuGridScrollbars.d.ts +24 -0
  190. package/dist/runtime/composables/_internal/useNuGridScrollbars.js +69 -0
  191. package/dist/runtime/composables/_internal/useNuGridStatePersistence.d.ts +27 -0
  192. package/dist/runtime/composables/_internal/useNuGridStatePersistence.js +243 -0
  193. package/dist/runtime/composables/_internal/useNuGridTooltip.d.ts +41 -0
  194. package/dist/runtime/composables/_internal/useNuGridTooltip.js +304 -0
  195. package/dist/runtime/composables/_internal/useNuGridUI.d.ts +3283 -0
  196. package/dist/runtime/composables/_internal/useNuGridUI.js +58 -0
  197. package/dist/runtime/composables/_internal/useNuGridVirtualization.d.ts +75 -0
  198. package/dist/runtime/composables/_internal/useNuGridVirtualization.js +534 -0
  199. package/dist/runtime/composables/_internal/useNuGridWheelSmoothing.d.ts +25 -0
  200. package/dist/runtime/composables/_internal/useNuGridWheelSmoothing.js +157 -0
  201. package/dist/runtime/composables/index.d.ts +3 -0
  202. package/dist/runtime/composables/index.js +2 -0
  203. package/dist/runtime/composables/useNuGridCellEditor.d.ts +91 -0
  204. package/dist/runtime/composables/useNuGridCellEditor.js +82 -0
  205. package/dist/runtime/composables/useNuGridCellTypeRegistry.d.ts +85 -0
  206. package/dist/runtime/composables/useNuGridCellTypeRegistry.js +202 -0
  207. package/dist/runtime/config/_internal/index.d.ts +5 -0
  208. package/dist/runtime/config/_internal/index.js +2 -0
  209. package/dist/runtime/config/_internal/options-defaults.d.ts +121 -0
  210. package/dist/runtime/config/_internal/options-defaults.js +121 -0
  211. package/dist/runtime/config/_internal/prop-utils.d.ts +54 -0
  212. package/dist/runtime/config/_internal/prop-utils.js +21 -0
  213. package/dist/runtime/config/config.d.ts +44 -0
  214. package/dist/runtime/config/config.js +18 -0
  215. package/dist/runtime/config/index.d.ts +2 -0
  216. package/dist/runtime/config/index.js +2 -0
  217. package/dist/runtime/config/presets.d.ts +15 -0
  218. package/dist/runtime/config/presets.js +58 -0
  219. package/dist/runtime/index.css +1 -0
  220. package/dist/runtime/index.d.ts +1 -0
  221. package/dist/runtime/index.js +1 -0
  222. package/dist/runtime/plugin.d.ts +5 -0
  223. package/dist/runtime/plugin.js +10 -0
  224. package/dist/runtime/themes/index.d.ts +56 -0
  225. package/dist/runtime/themes/index.js +68 -0
  226. package/dist/runtime/themes/nuGridTheme.d.ts +329 -0
  227. package/dist/runtime/themes/nuGridTheme.js +236 -0
  228. package/dist/runtime/themes/nuGridThemeCompact.d.ts +331 -0
  229. package/dist/runtime/themes/nuGridThemeCompact.js +236 -0
  230. package/dist/runtime/types/_internal/action-menu.d.ts +55 -0
  231. package/dist/runtime/types/_internal/action-menu.js +0 -0
  232. package/dist/runtime/types/_internal/cell-editing.d.ts +75 -0
  233. package/dist/runtime/types/_internal/cell-editing.js +0 -0
  234. package/dist/runtime/types/_internal/composable-returns.d.ts +52 -0
  235. package/dist/runtime/types/_internal/composable-returns.js +0 -0
  236. package/dist/runtime/types/_internal/config.d.ts +16 -0
  237. package/dist/runtime/types/_internal/config.js +0 -0
  238. package/dist/runtime/types/_internal/contexts/add-row.d.ts +25 -0
  239. package/dist/runtime/types/_internal/contexts/add-row.js +0 -0
  240. package/dist/runtime/types/_internal/contexts/animation.d.ts +24 -0
  241. package/dist/runtime/types/_internal/contexts/animation.js +0 -0
  242. package/dist/runtime/types/_internal/contexts/core.d.ts +24 -0
  243. package/dist/runtime/types/_internal/contexts/core.js +0 -0
  244. package/dist/runtime/types/_internal/contexts/drag.d.ts +13 -0
  245. package/dist/runtime/types/_internal/contexts/drag.js +0 -0
  246. package/dist/runtime/types/_internal/contexts/focus.d.ts +11 -0
  247. package/dist/runtime/types/_internal/contexts/focus.js +0 -0
  248. package/dist/runtime/types/_internal/contexts/grouping.d.ts +9 -0
  249. package/dist/runtime/types/_internal/contexts/grouping.js +0 -0
  250. package/dist/runtime/types/_internal/contexts/index.d.ts +15 -0
  251. package/dist/runtime/types/_internal/contexts/index.js +0 -0
  252. package/dist/runtime/types/_internal/contexts/interaction-router.d.ts +5 -0
  253. package/dist/runtime/types/_internal/contexts/interaction-router.js +0 -0
  254. package/dist/runtime/types/_internal/contexts/multi-row.d.ts +40 -0
  255. package/dist/runtime/types/_internal/contexts/multi-row.js +0 -0
  256. package/dist/runtime/types/_internal/contexts/paging.d.ts +39 -0
  257. package/dist/runtime/types/_internal/contexts/paging.js +0 -0
  258. package/dist/runtime/types/_internal/contexts/performance.d.ts +15 -0
  259. package/dist/runtime/types/_internal/contexts/performance.js +0 -0
  260. package/dist/runtime/types/_internal/contexts/resize.d.ts +12 -0
  261. package/dist/runtime/types/_internal/contexts/resize.js +0 -0
  262. package/dist/runtime/types/_internal/contexts/row-interactions.d.ts +12 -0
  263. package/dist/runtime/types/_internal/contexts/row-interactions.js +0 -0
  264. package/dist/runtime/types/_internal/contexts/scroll-state.d.ts +21 -0
  265. package/dist/runtime/types/_internal/contexts/scroll-state.js +0 -0
  266. package/dist/runtime/types/_internal/contexts/ui-config.d.ts +21 -0
  267. package/dist/runtime/types/_internal/contexts/ui-config.js +0 -0
  268. package/dist/runtime/types/_internal/contexts/virtualization.d.ts +16 -0
  269. package/dist/runtime/types/_internal/contexts/virtualization.js +0 -0
  270. package/dist/runtime/types/_internal/drag-drop.d.ts +48 -0
  271. package/dist/runtime/types/_internal/drag-drop.js +0 -0
  272. package/dist/runtime/types/_internal/focus.d.ts +68 -0
  273. package/dist/runtime/types/_internal/focus.js +0 -0
  274. package/dist/runtime/types/_internal/grouping.d.ts +48 -0
  275. package/dist/runtime/types/_internal/grouping.js +0 -0
  276. package/dist/runtime/types/_internal/index.d.ts +37 -0
  277. package/dist/runtime/types/_internal/index.js +2 -0
  278. package/dist/runtime/types/_internal/interaction-router.d.ts +176 -0
  279. package/dist/runtime/types/_internal/interaction-router.js +39 -0
  280. package/dist/runtime/types/_internal/props.d.ts +28 -0
  281. package/dist/runtime/types/_internal/props.js +0 -0
  282. package/dist/runtime/types/_internal/resize.d.ts +37 -0
  283. package/dist/runtime/types/_internal/resize.js +0 -0
  284. package/dist/runtime/types/_internal/row-interactions.d.ts +15 -0
  285. package/dist/runtime/types/_internal/row-interactions.js +0 -0
  286. package/dist/runtime/types/_internal/row-selection.d.ts +27 -0
  287. package/dist/runtime/types/_internal/row-selection.js +0 -0
  288. package/dist/runtime/types/_internal/states.d.ts +24 -0
  289. package/dist/runtime/types/_internal/states.js +0 -0
  290. package/dist/runtime/types/_internal/sticky-headers.d.ts +10 -0
  291. package/dist/runtime/types/_internal/sticky-headers.js +0 -0
  292. package/dist/runtime/types/_internal/validation.d.ts +54 -0
  293. package/dist/runtime/types/_internal/validation.js +0 -0
  294. package/dist/runtime/types/_internal/virtualization.d.ts +114 -0
  295. package/dist/runtime/types/_internal/virtualization.js +0 -0
  296. package/dist/runtime/types/action-menu.d.ts +62 -0
  297. package/dist/runtime/types/action-menu.js +0 -0
  298. package/dist/runtime/types/autosize.d.ts +8 -0
  299. package/dist/runtime/types/autosize.js +0 -0
  300. package/dist/runtime/types/cells.d.ts +292 -0
  301. package/dist/runtime/types/cells.js +5 -0
  302. package/dist/runtime/types/column.d.ts +248 -0
  303. package/dist/runtime/types/column.js +0 -0
  304. package/dist/runtime/types/config.d.ts +35 -0
  305. package/dist/runtime/types/config.js +0 -0
  306. package/dist/runtime/types/drag-drop.d.ts +92 -0
  307. package/dist/runtime/types/drag-drop.js +0 -0
  308. package/dist/runtime/types/events.d.ts +164 -0
  309. package/dist/runtime/types/events.js +1 -0
  310. package/dist/runtime/types/focus.d.ts +50 -0
  311. package/dist/runtime/types/focus.js +0 -0
  312. package/dist/runtime/types/grouping.d.ts +7 -0
  313. package/dist/runtime/types/grouping.js +0 -0
  314. package/dist/runtime/types/index.d.ts +15 -0
  315. package/dist/runtime/types/index.js +0 -0
  316. package/dist/runtime/types/option-groups.d.ts +624 -0
  317. package/dist/runtime/types/option-groups.js +0 -0
  318. package/dist/runtime/types/props.d.ts +418 -0
  319. package/dist/runtime/types/props.js +0 -0
  320. package/dist/runtime/types/resize.d.ts +14 -0
  321. package/dist/runtime/types/resize.js +0 -0
  322. package/dist/runtime/types/row-interactions.d.ts +11 -0
  323. package/dist/runtime/types/row-interactions.js +0 -0
  324. package/dist/runtime/types/row-selection.d.ts +48 -0
  325. package/dist/runtime/types/row-selection.js +0 -0
  326. package/dist/runtime/types/row.d.ts +7 -0
  327. package/dist/runtime/types/row.js +0 -0
  328. package/dist/runtime/types/sort-icon.d.ts +35 -0
  329. package/dist/runtime/types/sort-icon.js +0 -0
  330. package/dist/runtime/types/states.d.ts +17 -0
  331. package/dist/runtime/types/states.js +0 -0
  332. package/dist/runtime/types/sticky-headers.d.ts +6 -0
  333. package/dist/runtime/types/sticky-headers.js +0 -0
  334. package/dist/runtime/types/tanstack-table.d.ts +126 -0
  335. package/dist/runtime/types/theme.d.ts +22 -0
  336. package/dist/runtime/types/theme.js +0 -0
  337. package/dist/runtime/types/validation.d.ts +94 -0
  338. package/dist/runtime/types/validation.js +0 -0
  339. package/dist/runtime/utils/columnHelper.d.ts +208 -0
  340. package/dist/runtime/utils/columnHelper.js +23 -0
  341. package/dist/runtime/utils/excelExport.d.ts +63 -0
  342. package/dist/runtime/utils/excelExport.js +297 -0
  343. package/dist/runtime/utils/index.d.ts +2 -0
  344. package/dist/runtime/utils/index.js +2 -0
  345. package/dist/runtime/utils/standardSchema.d.ts +77 -0
  346. package/dist/runtime/utils/standardSchema.js +141 -0
  347. package/dist/types.d.mts +3 -0
  348. package/package.json +117 -0
@@ -0,0 +1,441 @@
1
+ import { ref } from "vue";
2
+ function compareHandlers(a, b) {
3
+ if (a.priority !== b.priority) {
4
+ return a.priority - b.priority;
5
+ }
6
+ return a.id.localeCompare(b.id);
7
+ }
8
+ function insertHandler(handlers, newHandler) {
9
+ let left = 0;
10
+ let right = handlers.length;
11
+ while (left < right) {
12
+ const mid = Math.floor((left + right) / 2);
13
+ const comparison = compareHandlers(handlers[mid], newHandler);
14
+ if (comparison < 0) {
15
+ left = mid + 1;
16
+ } else {
17
+ right = mid;
18
+ }
19
+ }
20
+ handlers.splice(left, 0, newHandler);
21
+ }
22
+ function dispatchHandlers(handlers, context, debug = false) {
23
+ if (debug && handlers.length > 0) {
24
+ console.log(
25
+ `[Router] \u{1F4CB} Dispatching ${context.event.type} to ${handlers.length} handler(s):`,
26
+ handlers.map((h) => `${h.id}(p:${h.priority})`).join(", ")
27
+ );
28
+ }
29
+ for (const handler of handlers) {
30
+ if (handler.when && !handler.when(context)) {
31
+ if (debug) console.log(`[Router] \u23ED\uFE0F Skipped: ${handler.id} (when returned false)`);
32
+ continue;
33
+ }
34
+ if (debug) console.log(`[Router] \u25B6\uFE0F Executing: ${handler.id}`);
35
+ const result = handler.handle(context) || {};
36
+ if (result.preventDefault) {
37
+ context.event.preventDefault();
38
+ if (debug) console.log(`[Router] \u{1F6D1} ${handler.id} called preventDefault()`);
39
+ }
40
+ if (result.stopPropagation) {
41
+ context.event.stopPropagation();
42
+ if (debug) console.log(`[Router] \u{1F6D1} ${handler.id} called stopPropagation()`);
43
+ }
44
+ const shouldStop = Boolean(
45
+ result.stop || result.handled || context.event.defaultPrevented || context.event.cancelBubble
46
+ );
47
+ if (shouldStop) {
48
+ if (debug) {
49
+ const reason = result.stop ? "stop: true" : result.handled ? "handled: true" : context.event.defaultPrevented ? "defaultPrevented" : "cancelBubble";
50
+ console.log(`[Router] \u270B Claimed by: ${handler.id} (${reason})`);
51
+ }
52
+ return { handlerId: handler.id, stopped: true };
53
+ }
54
+ }
55
+ if (debug) console.log("[Router] \u2139\uFE0F Event unclaimed - passed through all handlers");
56
+ return { handlerId: null, stopped: false };
57
+ }
58
+ export function useNuGridInteractionRouter(options = {}) {
59
+ const { debug = false, eventEmitter } = options;
60
+ const cellClickHandlers = ref([]);
61
+ const cellDoubleClickHandlers = ref([]);
62
+ const contextMenuHandlers = ref([]);
63
+ const wheelHandlers = ref([]);
64
+ const globalPointerHandlers = ref([]);
65
+ const hoverHandlers = ref([]);
66
+ const keyboardHandlers = ref([]);
67
+ const registeredIds = /* @__PURE__ */ new Set();
68
+ let removePointerListener = null;
69
+ let removeHoverListeners = null;
70
+ let removeKeyboardListener = null;
71
+ let removeKeyupListener = null;
72
+ let removeDocumentKeyboardListener = null;
73
+ const documentLevelHandlerIds = /* @__PURE__ */ new Set();
74
+ let keyboardConfig = null;
75
+ let gridRoot = null;
76
+ function registerCellClickHandler(handler) {
77
+ if (registeredIds.has(handler.id)) {
78
+ throw new Error(`[Router] Handler with id "${handler.id}" already registered`);
79
+ }
80
+ registeredIds.add(handler.id);
81
+ insertHandler(cellClickHandlers.value, handler);
82
+ return () => {
83
+ registeredIds.delete(handler.id);
84
+ const index = cellClickHandlers.value.findIndex((item) => item.id === handler.id);
85
+ if (index !== -1) {
86
+ cellClickHandlers.value.splice(index, 1);
87
+ }
88
+ };
89
+ }
90
+ function routeCellClick(context) {
91
+ dispatchHandlers(cellClickHandlers.value, context, debug);
92
+ if (eventEmitter?.cellClicked) {
93
+ const { row, cell, event } = context;
94
+ eventEmitter.cellClicked({ row, column: cell.column, cell, value: cell.getValue(), event });
95
+ }
96
+ if (eventEmitter?.rowClicked) {
97
+ const { row, event } = context;
98
+ eventEmitter.rowClicked({ row, event });
99
+ }
100
+ }
101
+ function registerCellDoubleClickHandler(handler) {
102
+ if (registeredIds.has(handler.id)) {
103
+ throw new Error(`[Router] Handler with id "${handler.id}" already registered`);
104
+ }
105
+ registeredIds.add(handler.id);
106
+ insertHandler(cellDoubleClickHandlers.value, handler);
107
+ return () => {
108
+ registeredIds.delete(handler.id);
109
+ const index = cellDoubleClickHandlers.value.findIndex((item) => item.id === handler.id);
110
+ if (index !== -1) {
111
+ cellDoubleClickHandlers.value.splice(index, 1);
112
+ }
113
+ };
114
+ }
115
+ function routeCellDoubleClick(context) {
116
+ dispatchHandlers(cellDoubleClickHandlers.value, context, debug);
117
+ if (eventEmitter?.cellDoubleClicked) {
118
+ const { row, cell, event } = context;
119
+ eventEmitter.cellDoubleClicked({
120
+ row,
121
+ column: cell.column,
122
+ cell,
123
+ value: cell.getValue(),
124
+ event
125
+ });
126
+ }
127
+ if (eventEmitter?.rowDoubleClicked) {
128
+ const { row, event } = context;
129
+ eventEmitter.rowDoubleClicked({ row, event });
130
+ }
131
+ }
132
+ function registerContextMenuHandler(handler) {
133
+ if (registeredIds.has(handler.id)) {
134
+ throw new Error(`[Router] Handler with id "${handler.id}" already registered`);
135
+ }
136
+ registeredIds.add(handler.id);
137
+ insertHandler(contextMenuHandlers.value, handler);
138
+ return () => {
139
+ registeredIds.delete(handler.id);
140
+ const index = contextMenuHandlers.value.findIndex((item) => item.id === handler.id);
141
+ if (index !== -1) {
142
+ contextMenuHandlers.value.splice(index, 1);
143
+ }
144
+ };
145
+ }
146
+ function routeContextMenu(context) {
147
+ dispatchHandlers(contextMenuHandlers.value, context, debug);
148
+ }
149
+ function registerWheelHandler(handler) {
150
+ if (registeredIds.has(handler.id)) {
151
+ throw new Error(`[Router] Handler with id "${handler.id}" already registered`);
152
+ }
153
+ registeredIds.add(handler.id);
154
+ insertHandler(wheelHandlers.value, handler);
155
+ return () => {
156
+ registeredIds.delete(handler.id);
157
+ const index = wheelHandlers.value.findIndex((item) => item.id === handler.id);
158
+ if (index !== -1) {
159
+ wheelHandlers.value.splice(index, 1);
160
+ }
161
+ };
162
+ }
163
+ function routeWheel(context) {
164
+ dispatchHandlers(wheelHandlers.value, context, debug);
165
+ }
166
+ function ensurePointerListener() {
167
+ if (removePointerListener || typeof document === "undefined") {
168
+ return;
169
+ }
170
+ const listener = (event) => {
171
+ if (!globalPointerHandlers.value.length) {
172
+ return;
173
+ }
174
+ dispatchHandlers(globalPointerHandlers.value, { event }, debug);
175
+ };
176
+ document.addEventListener("pointerdown", listener, true);
177
+ removePointerListener = () => {
178
+ document.removeEventListener("pointerdown", listener, true);
179
+ removePointerListener = null;
180
+ };
181
+ }
182
+ function registerGlobalPointerHandler(handler) {
183
+ if (registeredIds.has(handler.id)) {
184
+ throw new Error(`[Router] Handler with id "${handler.id}" already registered`);
185
+ }
186
+ registeredIds.add(handler.id);
187
+ insertHandler(globalPointerHandlers.value, handler);
188
+ ensurePointerListener();
189
+ return () => {
190
+ registeredIds.delete(handler.id);
191
+ const index = globalPointerHandlers.value.findIndex((item) => item.id === handler.id);
192
+ if (index !== -1) {
193
+ globalPointerHandlers.value.splice(index, 1);
194
+ }
195
+ if (!globalPointerHandlers.value.length && removePointerListener) {
196
+ removePointerListener();
197
+ }
198
+ };
199
+ }
200
+ function handleMouseOver(event) {
201
+ if (!hoverHandlers.value.length) return;
202
+ const target = event.target;
203
+ dispatchHandlers(
204
+ hoverHandlers.value,
205
+ { event, target, type: "enter" },
206
+ debug
207
+ );
208
+ }
209
+ function handleMouseOut(event) {
210
+ if (!hoverHandlers.value.length) return;
211
+ const target = event.target;
212
+ dispatchHandlers(
213
+ hoverHandlers.value,
214
+ { event, target, type: "leave" },
215
+ debug
216
+ );
217
+ }
218
+ let pendingMoveEvent = null;
219
+ let moveRafId = null;
220
+ function handleMouseMove(event) {
221
+ if (!hoverHandlers.value.length) return;
222
+ pendingMoveEvent = event;
223
+ if (moveRafId === null) {
224
+ moveRafId = requestAnimationFrame(() => {
225
+ if (pendingMoveEvent) {
226
+ const target = pendingMoveEvent.target;
227
+ dispatchHandlers(
228
+ hoverHandlers.value,
229
+ { event: pendingMoveEvent, target, type: "move" },
230
+ debug
231
+ );
232
+ pendingMoveEvent = null;
233
+ }
234
+ moveRafId = null;
235
+ });
236
+ }
237
+ }
238
+ function ensureHoverListeners() {
239
+ if (removeHoverListeners || !gridRoot) return;
240
+ gridRoot.addEventListener("mouseover", handleMouseOver);
241
+ gridRoot.addEventListener("mouseout", handleMouseOut);
242
+ gridRoot.addEventListener("mousemove", handleMouseMove, { passive: true });
243
+ removeHoverListeners = () => {
244
+ if (gridRoot) {
245
+ gridRoot.removeEventListener("mouseover", handleMouseOver);
246
+ gridRoot.removeEventListener("mouseout", handleMouseOut);
247
+ gridRoot.removeEventListener("mousemove", handleMouseMove);
248
+ }
249
+ if (moveRafId !== null) {
250
+ cancelAnimationFrame(moveRafId);
251
+ moveRafId = null;
252
+ }
253
+ pendingMoveEvent = null;
254
+ removeHoverListeners = null;
255
+ };
256
+ }
257
+ function setGridRoot(el) {
258
+ if (removeHoverListeners) {
259
+ removeHoverListeners();
260
+ }
261
+ if (removeKeyboardListener) {
262
+ removeKeyboardListener();
263
+ }
264
+ if (removeDocumentKeyboardListener) {
265
+ removeDocumentKeyboardListener();
266
+ }
267
+ gridRoot = el;
268
+ if (gridRoot && hoverHandlers.value.length) {
269
+ ensureHoverListeners();
270
+ }
271
+ if (gridRoot && keyboardHandlers.value.length && keyboardConfig) {
272
+ ensureKeyboardListener();
273
+ }
274
+ if (gridRoot && documentLevelHandlerIds.size > 0 && keyboardConfig) {
275
+ ensureDocumentKeyboardListener();
276
+ }
277
+ }
278
+ function registerHoverHandler(handler) {
279
+ if (registeredIds.has(handler.id)) {
280
+ throw new Error(`[Router] Handler with id "${handler.id}" already registered`);
281
+ }
282
+ registeredIds.add(handler.id);
283
+ insertHandler(hoverHandlers.value, handler);
284
+ if (gridRoot) {
285
+ ensureHoverListeners();
286
+ }
287
+ return () => {
288
+ registeredIds.delete(handler.id);
289
+ const index = hoverHandlers.value.findIndex((item) => item.id === handler.id);
290
+ if (index !== -1) {
291
+ hoverHandlers.value.splice(index, 1);
292
+ }
293
+ if (!hoverHandlers.value.length && removeHoverListeners) {
294
+ removeHoverListeners();
295
+ }
296
+ };
297
+ }
298
+ let cachedDocumentLevelHandlers = [];
299
+ function updateDocumentLevelHandlersCache() {
300
+ cachedDocumentLevelHandlers = keyboardHandlers.value.filter((h) => h.documentLevel);
301
+ }
302
+ function handleDocumentKeyDown(event) {
303
+ if (!keyboardConfig || cachedDocumentLevelHandlers.length === 0) {
304
+ return;
305
+ }
306
+ const context = keyboardConfig.buildContext(event);
307
+ if (!context) return;
308
+ dispatchHandlers(cachedDocumentLevelHandlers, context, debug);
309
+ }
310
+ function ensureDocumentKeyboardListener() {
311
+ if (removeDocumentKeyboardListener || !keyboardConfig || typeof document === "undefined") {
312
+ return;
313
+ }
314
+ const listener = handleDocumentKeyDown;
315
+ document.addEventListener("keydown", listener, true);
316
+ removeDocumentKeyboardListener = () => {
317
+ document.removeEventListener("keydown", listener, true);
318
+ removeDocumentKeyboardListener = null;
319
+ };
320
+ }
321
+ function registerKeyboardHandler(handler) {
322
+ if (registeredIds.has(handler.id)) {
323
+ throw new Error(`[Router] Handler with id "${handler.id}" already registered`);
324
+ }
325
+ registeredIds.add(handler.id);
326
+ insertHandler(keyboardHandlers.value, handler);
327
+ if (handler.documentLevel) {
328
+ documentLevelHandlerIds.add(handler.id);
329
+ updateDocumentLevelHandlersCache();
330
+ ensureDocumentKeyboardListener();
331
+ } else {
332
+ updateNonDocumentHandlersCache();
333
+ }
334
+ ensureKeyboardListener();
335
+ return () => {
336
+ registeredIds.delete(handler.id);
337
+ const index = keyboardHandlers.value.findIndex((item) => item.id === handler.id);
338
+ if (index !== -1) {
339
+ keyboardHandlers.value.splice(index, 1);
340
+ }
341
+ if (handler.documentLevel) {
342
+ documentLevelHandlerIds.delete(handler.id);
343
+ updateDocumentLevelHandlersCache();
344
+ if (documentLevelHandlerIds.size === 0 && removeDocumentKeyboardListener) {
345
+ removeDocumentKeyboardListener();
346
+ }
347
+ } else {
348
+ updateNonDocumentHandlersCache();
349
+ }
350
+ if (!keyboardHandlers.value.length && removeKeyboardListener) {
351
+ removeKeyboardListener();
352
+ }
353
+ };
354
+ }
355
+ function routeKeyboard(context) {
356
+ dispatchHandlers(keyboardHandlers.value, context, debug);
357
+ }
358
+ let cachedNonDocumentHandlers = [];
359
+ function updateNonDocumentHandlersCache() {
360
+ cachedNonDocumentHandlers = keyboardHandlers.value.filter((h) => !h.documentLevel);
361
+ }
362
+ function handleKeyDown(event) {
363
+ if (!keyboardConfig) {
364
+ return;
365
+ }
366
+ if (cachedNonDocumentHandlers.length === 0) {
367
+ return;
368
+ }
369
+ const context = keyboardConfig.buildContext(event);
370
+ if (!context) {
371
+ return;
372
+ }
373
+ dispatchHandlers(cachedNonDocumentHandlers, context, debug);
374
+ }
375
+ function ensureKeyboardListener() {
376
+ if (removeKeyboardListener || !keyboardConfig || !gridRoot) {
377
+ return;
378
+ }
379
+ const target = keyboardConfig.retainFocus ? document : gridRoot;
380
+ const listener = handleKeyDown;
381
+ target.addEventListener("keydown", listener, true);
382
+ removeKeyboardListener = () => {
383
+ target.removeEventListener("keydown", listener, true);
384
+ removeKeyboardListener = null;
385
+ };
386
+ }
387
+ function handleKeyUp(event) {
388
+ const context = keyboardConfig?.buildContext(event);
389
+ if (!context) {
390
+ return;
391
+ }
392
+ context.focusFns.onCellKeyUp(event);
393
+ }
394
+ function ensureKeyupListener() {
395
+ if (removeKeyupListener || !keyboardConfig || !gridRoot) {
396
+ return;
397
+ }
398
+ const target = keyboardConfig.retainFocus ? document : gridRoot;
399
+ const listener = handleKeyUp;
400
+ target.addEventListener("keyup", listener, true);
401
+ removeKeyupListener = () => {
402
+ target.removeEventListener("keyup", listener, true);
403
+ removeKeyupListener = null;
404
+ };
405
+ }
406
+ function setKeyboardConfig(config) {
407
+ if (removeKeyboardListener) {
408
+ removeKeyboardListener();
409
+ }
410
+ if (removeKeyupListener) {
411
+ removeKeyupListener();
412
+ }
413
+ if (removeDocumentKeyboardListener) {
414
+ removeDocumentKeyboardListener();
415
+ }
416
+ keyboardConfig = config;
417
+ if (keyboardConfig && gridRoot && keyboardHandlers.value.length) {
418
+ ensureKeyboardListener();
419
+ ensureKeyupListener();
420
+ }
421
+ if (keyboardConfig && documentLevelHandlerIds.size > 0) {
422
+ ensureDocumentKeyboardListener();
423
+ }
424
+ }
425
+ return {
426
+ registerCellClickHandler,
427
+ routeCellClick,
428
+ registerCellDoubleClickHandler,
429
+ routeCellDoubleClick,
430
+ registerContextMenuHandler,
431
+ routeContextMenu,
432
+ registerWheelHandler,
433
+ routeWheel,
434
+ registerGlobalPointerHandler,
435
+ registerHoverHandler,
436
+ registerKeyboardHandler,
437
+ routeKeyboard,
438
+ setKeyboardConfig,
439
+ setGridRoot
440
+ };
441
+ }
@@ -0,0 +1,10 @@
1
+ import type { TableData, TableRow } from '@nuxt/ui';
2
+ import type { NuGridProps } from '../../types/index.js';
3
+ /**
4
+ * Shared row interaction handlers
5
+ */
6
+ export declare function useNuGridRowInteractions<T extends TableData>(props: NuGridProps<T>): {
7
+ onRowSelect: (e: Event, row: TableRow<T>) => void;
8
+ onRowHover: (e: Event, row: TableRow<T> | null) => void;
9
+ onRowContextmenu: (e: Event, row: TableRow<T>) => void;
10
+ };
@@ -0,0 +1,36 @@
1
+ export function useNuGridRowInteractions(props) {
2
+ function onRowSelect(e, row) {
3
+ if (!props.onSelect) {
4
+ return;
5
+ }
6
+ const target = e.target;
7
+ const isInteractive = target.closest("button") || target.closest("a");
8
+ if (isInteractive) {
9
+ return;
10
+ }
11
+ e.preventDefault();
12
+ e.stopPropagation();
13
+ props.onSelect(e, row);
14
+ }
15
+ function onRowHover(e, row) {
16
+ if (!props.onHover) {
17
+ return;
18
+ }
19
+ props.onHover(e, row);
20
+ }
21
+ function onRowContextmenu(e, row) {
22
+ if (!props.onContextmenu) {
23
+ return;
24
+ }
25
+ if (Array.isArray(props.onContextmenu)) {
26
+ props.onContextmenu.forEach((fn) => fn(e, row));
27
+ } else {
28
+ props.onContextmenu(e, row);
29
+ }
30
+ }
31
+ return {
32
+ onRowSelect,
33
+ onRowHover,
34
+ onRowContextmenu
35
+ };
36
+ }
@@ -0,0 +1,54 @@
1
+ import type { TableData } from '@nuxt/ui';
2
+ import type { Row, Table } from '@tanstack/vue-table';
3
+ import type { NuGridProps } from '../../types/index.js';
4
+ /**
5
+ * Navigation result containing target row and column indices
6
+ */
7
+ export interface NavigationTarget {
8
+ rowIndex: number;
9
+ columnIndex: number;
10
+ }
11
+ /**
12
+ * Predicate function to determine if a cell is a valid navigation target
13
+ * Parameters: (columnIndex, row) to match existing isColumnFocusable/isCellEditable signatures
14
+ */
15
+ export type IsValidTargetFn<T> = (columnIndex: number, row: Row<T>) => boolean;
16
+ /**
17
+ * Shared keyboard navigation logic for NuGrid
18
+ * Used by both focus and editing systems to navigate between cells
19
+ *
20
+ * @example
21
+ * ```typescript
22
+ * const nav = useNuGridKeyboardNavigation(props, tableApi)
23
+ *
24
+ * // Navigate with custom validity check
25
+ * const target = nav.navigateVertical('down', rowIndex, colIndex, rows, (row, col) => {
26
+ * return isCellEditable(row, cells[col])
27
+ * })
28
+ * if (target) {
29
+ * startEditing(rows[target.rowIndex], cells[target.columnIndex])
30
+ * }
31
+ * ```
32
+ */
33
+ export declare function useNuGridKeyboardNavigation<T extends TableData>(props: NuGridProps<T>, tableApi: Table<T>): {
34
+ multiRowEnabled: import("vue").ComputedRef<boolean>;
35
+ multiRowCount: import("vue").ComputedRef<number>;
36
+ alignColumns: import("vue").ComputedRef<boolean>;
37
+ visibleColumns: import("vue").ComputedRef<import("@tanstack/table-core").Column<T, unknown>[]>;
38
+ getVisualRowForColumn: (columnIndex: number) => number;
39
+ getColumnsInVisualRow: (visualRow: number) => number[];
40
+ getNonPinnedColumnsInVisualRow: (visualRow: number) => number[];
41
+ findColumnInVisualRow: (currentColumnIndex: number, targetVisualRow: number, _row: Row<T>) => number;
42
+ findFirstInVisualRow: (visualRow: number, row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number | null;
43
+ findLastInVisualRow: (visualRow: number, row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number | null;
44
+ findNextInVisualRow: (startIndex: number, visualRow: number, row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number | null;
45
+ findPreviousInVisualRow: (startIndex: number, visualRow: number, row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number | null;
46
+ findFirstColumn: (row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number;
47
+ findLastColumn: (row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number;
48
+ findNextColumn: (currentIndex: number, row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number;
49
+ findPreviousColumn: (currentIndex: number, row: Row<T>, isValidTarget?: IsValidTargetFn<T>) => number;
50
+ navigateVertical: (direction: "up" | "down", currentRowIndex: number, currentColumnIndex: number, rows: Row<T>[], isValidTarget?: IsValidTargetFn<T>) => NavigationTarget | null;
51
+ navigateHorizontal: (direction: "left" | "right", currentRowIndex: number, currentColumnIndex: number, rows: Row<T>[], isValidTarget?: IsValidTargetFn<T>) => NavigationTarget | null;
52
+ navigateTab: (direction: "next" | "previous", currentRowIndex: number, currentColumnIndex: number, rows: Row<T>[], isValidTarget?: IsValidTargetFn<T>) => NavigationTarget | null;
53
+ navigateToEdge: (edge: "first" | "last", currentRowIndex: number, rows: Row<T>[], isValidTarget?: IsValidTargetFn<T>) => NavigationTarget | null;
54
+ };