@toolbox-web/grid-vue 0.2.0 → 0.3.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.
@@ -1 +1 @@
1
- {"version":3,"file":"selection.js","sources":["../../../../libs/grid-vue/src/features/selection.ts"],"sourcesContent":["/**\n * Selection feature for @toolbox-web/grid-vue\n *\n * Import this module to enable the `selection` prop on TbwGrid.\n *\n * @example\n * ```vue\n * <script setup>\n * import '@toolbox-web/grid-vue/features/selection';\n * </script>\n *\n * <template>\n * <TbwGrid selection=\"range\" />\n * </template>\n * ```\n *\n * @packageDocumentation\n */\n\nimport { SelectionPlugin } from '@toolbox-web/grid/plugins/selection';\nimport { registerFeature } from '../lib/feature-registry';\n\nregisterFeature('selection', (config) => {\n // Handle shorthand: 'cell', 'row', 'range'\n if (config === 'cell' || config === 'row' || config === 'range') {\n return new SelectionPlugin({ mode: config });\n }\n // Full config object\n return new SelectionPlugin(config ?? undefined);\n});\n"],"names":["registerFeature","config","SelectionPlugin"],"mappings":";;AAsBAA,EAAgB,aAAa,CAACC,MAExBA,MAAW,UAAUA,MAAW,SAASA,MAAW,UAC/C,IAAIC,EAAgB,EAAE,MAAMD,GAAQ,IAGtC,IAAIC,EAAgBD,KAAU,MAAS,CAC/C;"}
1
+ {"version":3,"file":"selection.js","sources":["../../../../libs/grid-vue/src/features/selection.ts"],"sourcesContent":["/**\n * Selection feature for @toolbox-web/grid-vue\n *\n * Import this module to enable the `selection` prop on TbwGrid.\n * Also exports `useGridSelection()` composable for programmatic selection control.\n *\n * @example\n * ```vue\n * <script setup>\n * import '@toolbox-web/grid-vue/features/selection';\n * </script>\n *\n * <template>\n * <TbwGrid selection=\"range\" />\n * </template>\n * ```\n *\n * @example Using the composable\n * ```vue\n * <script setup>\n * import { useGridSelection } from '@toolbox-web/grid-vue/features/selection';\n *\n * const { selectAll, clearSelection, getSelection } = useGridSelection();\n *\n * function handleSelectAll() {\n * selectAll();\n * }\n * </script>\n * ```\n *\n * @packageDocumentation\n */\n\nimport type { DataGridElement } from '@toolbox-web/grid';\nimport { SelectionPlugin, type CellRange, type SelectionResult } from '@toolbox-web/grid/plugins/selection';\nimport { inject, ref } from 'vue';\nimport { registerFeature } from '../lib/feature-registry';\nimport { GRID_ELEMENT_KEY } from '../lib/use-grid';\n\nregisterFeature('selection', (config) => {\n // Handle shorthand: 'cell', 'row', 'range'\n if (config === 'cell' || config === 'row' || config === 'range') {\n return new SelectionPlugin({ mode: config });\n }\n // Full config object\n return new SelectionPlugin(config ?? undefined);\n});\n\n/**\n * Selection methods returned from useGridSelection.\n *\n * Uses the injected grid element from TbwGrid's provide/inject.\n * Methods work immediately when grid is available.\n */\nexport interface SelectionMethods {\n /**\n * Select all rows (row mode) or all cells (range mode).\n */\n selectAll: () => void;\n\n /**\n * Clear all selection.\n */\n clearSelection: () => void;\n\n /**\n * Get the current selection state.\n * Use this to derive selected rows, indices, etc.\n */\n getSelection: () => SelectionResult | null;\n\n /**\n * Check if a specific cell is selected.\n */\n isCellSelected: (row: number, col: number) => boolean;\n\n /**\n * Set selection ranges programmatically.\n */\n setRanges: (ranges: CellRange[]) => void;\n}\n\n/**\n * Composable for programmatic selection control.\n *\n * Must be used within a component that contains a TbwGrid with the selection feature enabled.\n * Uses Vue's provide/inject, so it works reliably regardless of when the grid renders.\n *\n * @example\n * ```vue\n * <script setup>\n * import { useGridSelection } from '@toolbox-web/grid-vue/features/selection';\n *\n * const { selectAll, clearSelection, getSelection } = useGridSelection();\n *\n * function exportSelected() {\n * const selection = getSelection();\n * if (!selection) return;\n * // Derive rows from selection.ranges and grid.rows\n * }\n * </script>\n * ```\n */\nexport function useGridSelection<TRow = unknown>(): SelectionMethods {\n const gridElement = inject(GRID_ELEMENT_KEY, ref(null));\n\n const getPlugin = (): SelectionPlugin | undefined => {\n const grid = gridElement.value as DataGridElement<TRow> | null;\n return grid?.getPlugin(SelectionPlugin);\n };\n\n return {\n selectAll: () => {\n const plugin = getPlugin();\n if (!plugin) {\n console.warn(\n `[tbw-grid:selection] SelectionPlugin not found.\\n\\n` +\n ` → Enable selection on the grid:\\n` +\n ` <TbwGrid selection=\"range\" />`,\n );\n return;\n }\n const grid = gridElement.value as DataGridElement<TRow> | null;\n // Cast to any to access protected config\n const mode = (plugin as any).config?.mode;\n\n if (mode === 'row') {\n const rowCount = grid?.rows?.length ?? 0;\n const allIndices = new Set<number>();\n for (let i = 0; i < rowCount; i++) allIndices.add(i);\n (plugin as any).selected = allIndices;\n (plugin as any).requestAfterRender?.();\n } else if (mode === 'range') {\n const rowCount = grid?.rows?.length ?? 0;\n const colCount = (grid as any)?._columns?.length ?? 0;\n if (rowCount > 0 && colCount > 0) {\n plugin.setRanges([{ from: { row: 0, col: 0 }, to: { row: rowCount - 1, col: colCount - 1 } }]);\n }\n }\n },\n\n clearSelection: () => {\n getPlugin()?.clearSelection();\n },\n\n getSelection: () => {\n return getPlugin()?.getSelection() ?? null;\n },\n\n isCellSelected: (row: number, col: number) => {\n return getPlugin()?.isCellSelected(row, col) ?? false;\n },\n\n setRanges: (ranges: CellRange[]) => {\n getPlugin()?.setRanges(ranges);\n },\n };\n}\n"],"names":["registerFeature","config","SelectionPlugin","useGridSelection","gridElement","inject","GRID_ELEMENT_KEY","ref","getPlugin","plugin","grid","mode","rowCount","allIndices","colCount","row","col","ranges"],"mappings":";;;;AAuCAA,EAAgB,aAAa,CAACC,MAExBA,MAAW,UAAUA,MAAW,SAASA,MAAW,UAC/C,IAAIC,EAAgB,EAAE,MAAMD,GAAQ,IAGtC,IAAIC,EAAgBD,KAAU,MAAS,CAC/C;AAyDM,SAASE,IAAqD;AACnE,QAAMC,IAAcC,EAAOC,GAAkBC,EAAI,IAAI,CAAC,GAEhDC,IAAY,MACHJ,EAAY,OACZ,UAAUF,CAAe;AAGxC,SAAO;AAAA,IACL,WAAW,MAAM;AACf,YAAMO,IAASD,EAAA;AACf,UAAI,CAACC,GAAQ;AACX,gBAAQ;AAAA,UACN;AAAA;AAAA;AAAA;AAAA,QAAA;AAIF;AAAA,MACF;AACA,YAAMC,IAAON,EAAY,OAEnBO,IAAQF,EAAe,QAAQ;AAErC,UAAIE,MAAS,OAAO;AAClB,cAAMC,IAAWF,GAAM,MAAM,UAAU,GACjCG,wBAAiB,IAAA;AACvB,iBAAS,IAAI,GAAG,IAAID,GAAU,IAAK,CAAAC,EAAW,IAAI,CAAC;AAClD,QAAAJ,EAAe,WAAWI,GAC1BJ,EAAe,qBAAA;AAAA,MAClB,WAAWE,MAAS,SAAS;AAC3B,cAAMC,IAAWF,GAAM,MAAM,UAAU,GACjCI,IAAYJ,GAAc,UAAU,UAAU;AACpD,QAAIE,IAAW,KAAKE,IAAW,KAC7BL,EAAO,UAAU,CAAC,EAAE,MAAM,EAAE,KAAK,GAAG,KAAK,EAAA,GAAK,IAAI,EAAE,KAAKG,IAAW,GAAG,KAAKE,IAAW,EAAA,EAAE,CAAG,CAAC;AAAA,MAEjG;AAAA,IACF;AAAA,IAEA,gBAAgB,MAAM;AACpB,MAAAN,EAAA,GAAa,eAAA;AAAA,IACf;AAAA,IAEA,cAAc,MACLA,EAAA,GAAa,aAAA,KAAkB;AAAA,IAGxC,gBAAgB,CAACO,GAAaC,MACrBR,EAAA,GAAa,eAAeO,GAAKC,CAAG,KAAK;AAAA,IAGlD,WAAW,CAACC,MAAwB;AAClC,MAAAT,EAAA,GAAa,UAAUS,CAAM;AAAA,IAC/B;AAAA,EAAA;AAEJ;"}
@@ -1,20 +1,60 @@
1
+ import { EditAction } from '@toolbox-web/grid/plugins/undo-redo';
1
2
  /**
2
- * Undo/Redo feature for @toolbox-web/grid-vue
3
+ * Undo/Redo methods returned from useGridUndoRedo.
4
+ */
5
+ export interface UndoRedoMethods {
6
+ /**
7
+ * Undo the last edit action.
8
+ * @returns The undone action, or null if nothing to undo
9
+ */
10
+ undo: () => EditAction | null;
11
+ /**
12
+ * Redo the last undone action.
13
+ * @returns The redone action, or null if nothing to redo
14
+ */
15
+ redo: () => EditAction | null;
16
+ /**
17
+ * Check if there are any actions that can be undone.
18
+ */
19
+ canUndo: () => boolean;
20
+ /**
21
+ * Check if there are any actions that can be redone.
22
+ */
23
+ canRedo: () => boolean;
24
+ /**
25
+ * Clear all undo/redo history.
26
+ */
27
+ clearHistory: () => void;
28
+ /**
29
+ * Get a copy of the current undo stack.
30
+ */
31
+ getUndoStack: () => EditAction[];
32
+ /**
33
+ * Get a copy of the current redo stack.
34
+ */
35
+ getRedoStack: () => EditAction[];
36
+ }
37
+ /**
38
+ * Composable for programmatic undo/redo control.
3
39
  *
4
- * Import this module to enable the `undoRedo` prop on TbwGrid.
40
+ * Must be used within a component that contains a TbwGrid with undoRedo and editing enabled.
5
41
  *
6
42
  * @example
7
43
  * ```vue
8
44
  * <script setup>
9
- * import '@toolbox-web/grid-vue/features/undo-redo';
45
+ * import { useGridUndoRedo } from '@toolbox-web/grid-vue/features/undo-redo';
46
+ *
47
+ * const { undo, redo, canUndo, canRedo, clearHistory } = useGridUndoRedo();
10
48
  * </script>
11
49
  *
12
50
  * <template>
13
- * <TbwGrid editing="dblclick" undoRedo />
51
+ * <div class="toolbar">
52
+ * <button @click="undo" :disabled="!canUndo()">Undo</button>
53
+ * <button @click="redo" :disabled="!canRedo()">Redo</button>
54
+ * <button @click="clearHistory">Clear History</button>
55
+ * </div>
14
56
  * </template>
15
57
  * ```
16
- *
17
- * @packageDocumentation
18
58
  */
19
- export {};
59
+ export declare function useGridUndoRedo(): UndoRedoMethods;
20
60
  //# sourceMappingURL=undo-redo.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"undo-redo.d.ts","sourceRoot":"","sources":["../../../../libs/grid-vue/src/features/undo-redo.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG"}
1
+ {"version":3,"file":"undo-redo.d.ts","sourceRoot":"","sources":["../../../../libs/grid-vue/src/features/undo-redo.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAGH,OAAO,EAAkB,KAAK,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAYtF;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B;;;OAGG;IACH,IAAI,EAAE,MAAM,UAAU,GAAG,IAAI,CAAC;IAE9B;;;OAGG;IACH,IAAI,EAAE,MAAM,UAAU,GAAG,IAAI,CAAC;IAE9B;;OAEG;IACH,OAAO,EAAE,MAAM,OAAO,CAAC;IAEvB;;OAEG;IACH,OAAO,EAAE,MAAM,OAAO,CAAC;IAEvB;;OAEG;IACH,YAAY,EAAE,MAAM,IAAI,CAAC;IAEzB;;OAEG;IACH,YAAY,EAAE,MAAM,UAAU,EAAE,CAAC;IAEjC;;OAEG;IACH,YAAY,EAAE,MAAM,UAAU,EAAE,CAAC;CAClC;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,eAAe,IAAI,eAAe,CAwDjD"}
@@ -1,4 +1,49 @@
1
- import { UndoRedoPlugin as e } from "@toolbox-web/grid/plugins/undo-redo";
2
- import { r as o } from "../chunks/feature-registry-BgEOysSJ.js";
3
- o("undoRedo", (r) => r === !0 ? new e() : new e(r ?? void 0));
1
+ import { UndoRedoPlugin as d } from "@toolbox-web/grid/plugins/undo-redo";
2
+ import { inject as r, ref as t } from "vue";
3
+ import { r as i } from "../chunks/feature-registry-BgEOysSJ.js";
4
+ import { G as u } from "../chunks/use-grid-DwjXrO19.js";
5
+ i("undoRedo", (e) => e === !0 ? new d() : new d(e ?? void 0));
6
+ function s() {
7
+ const e = r(u, t(null)), o = () => e.value?.getPlugin(d);
8
+ return {
9
+ undo: () => {
10
+ const n = o();
11
+ return n ? n.undo() : (console.warn(
12
+ `[tbw-grid:undoRedo] UndoRedoPlugin not found.
13
+
14
+ → Enable undo/redo on the grid:
15
+ <TbwGrid editing="dblclick" undoRedo />`
16
+ ), null);
17
+ },
18
+ redo: () => {
19
+ const n = o();
20
+ return n ? n.redo() : (console.warn(
21
+ `[tbw-grid:undoRedo] UndoRedoPlugin not found.
22
+
23
+ → Enable undo/redo on the grid:
24
+ <TbwGrid editing="dblclick" undoRedo />`
25
+ ), null);
26
+ },
27
+ canUndo: () => o()?.canUndo() ?? !1,
28
+ canRedo: () => o()?.canRedo() ?? !1,
29
+ clearHistory: () => {
30
+ const n = o();
31
+ if (!n) {
32
+ console.warn(
33
+ `[tbw-grid:undoRedo] UndoRedoPlugin not found.
34
+
35
+ → Enable undo/redo on the grid:
36
+ <TbwGrid editing="dblclick" undoRedo />`
37
+ );
38
+ return;
39
+ }
40
+ n.clearHistory();
41
+ },
42
+ getUndoStack: () => o()?.getUndoStack() ?? [],
43
+ getRedoStack: () => o()?.getRedoStack() ?? []
44
+ };
45
+ }
46
+ export {
47
+ s as useGridUndoRedo
48
+ };
4
49
  //# sourceMappingURL=undo-redo.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"undo-redo.js","sources":["../../../../libs/grid-vue/src/features/undo-redo.ts"],"sourcesContent":["/**\n * Undo/Redo feature for @toolbox-web/grid-vue\n *\n * Import this module to enable the `undoRedo` prop on TbwGrid.\n *\n * @example\n * ```vue\n * <script setup>\n * import '@toolbox-web/grid-vue/features/undo-redo';\n * </script>\n *\n * <template>\n * <TbwGrid editing=\"dblclick\" undoRedo />\n * </template>\n * ```\n *\n * @packageDocumentation\n */\n\nimport { UndoRedoPlugin } from '@toolbox-web/grid/plugins/undo-redo';\nimport { registerFeature } from '../lib/feature-registry';\n\nregisterFeature('undoRedo', (config) => {\n if (config === true) {\n return new UndoRedoPlugin();\n }\n return new UndoRedoPlugin(config ?? undefined);\n});\n"],"names":["registerFeature","config","UndoRedoPlugin"],"mappings":";;AAsBAA,EAAgB,YAAY,CAACC,MACvBA,MAAW,KACN,IAAIC,EAAA,IAEN,IAAIA,EAAeD,KAAU,MAAS,CAC9C;"}
1
+ {"version":3,"file":"undo-redo.js","sources":["../../../../libs/grid-vue/src/features/undo-redo.ts"],"sourcesContent":["/**\n * Undo/Redo feature for @toolbox-web/grid-vue\n *\n * Import this module to enable the `undoRedo` prop on TbwGrid.\n * Also exports `useGridUndoRedo()` composable for programmatic undo/redo control.\n *\n * @example\n * ```vue\n * <script setup>\n * import '@toolbox-web/grid-vue/features/undo-redo';\n * </script>\n *\n * <template>\n * <TbwGrid editing=\"dblclick\" undoRedo />\n * </template>\n * ```\n *\n * @example Using the composable\n * ```vue\n * <script setup>\n * import { useGridUndoRedo } from '@toolbox-web/grid-vue/features/undo-redo';\n *\n * const { undo, redo, canUndo, canRedo } = useGridUndoRedo();\n * </script>\n *\n * <template>\n * <button @click=\"undo\" :disabled=\"!canUndo()\">Undo</button>\n * <button @click=\"redo\" :disabled=\"!canRedo()\">Redo</button>\n * </template>\n * ```\n *\n * @packageDocumentation\n */\n\nimport type { DataGridElement } from '@toolbox-web/grid';\nimport { UndoRedoPlugin, type EditAction } from '@toolbox-web/grid/plugins/undo-redo';\nimport { inject, ref } from 'vue';\nimport { registerFeature } from '../lib/feature-registry';\nimport { GRID_ELEMENT_KEY } from '../lib/use-grid';\n\nregisterFeature('undoRedo', (config) => {\n if (config === true) {\n return new UndoRedoPlugin();\n }\n return new UndoRedoPlugin(config ?? undefined);\n});\n\n/**\n * Undo/Redo methods returned from useGridUndoRedo.\n */\nexport interface UndoRedoMethods {\n /**\n * Undo the last edit action.\n * @returns The undone action, or null if nothing to undo\n */\n undo: () => EditAction | null;\n\n /**\n * Redo the last undone action.\n * @returns The redone action, or null if nothing to redo\n */\n redo: () => EditAction | null;\n\n /**\n * Check if there are any actions that can be undone.\n */\n canUndo: () => boolean;\n\n /**\n * Check if there are any actions that can be redone.\n */\n canRedo: () => boolean;\n\n /**\n * Clear all undo/redo history.\n */\n clearHistory: () => void;\n\n /**\n * Get a copy of the current undo stack.\n */\n getUndoStack: () => EditAction[];\n\n /**\n * Get a copy of the current redo stack.\n */\n getRedoStack: () => EditAction[];\n}\n\n/**\n * Composable for programmatic undo/redo control.\n *\n * Must be used within a component that contains a TbwGrid with undoRedo and editing enabled.\n *\n * @example\n * ```vue\n * <script setup>\n * import { useGridUndoRedo } from '@toolbox-web/grid-vue/features/undo-redo';\n *\n * const { undo, redo, canUndo, canRedo, clearHistory } = useGridUndoRedo();\n * </script>\n *\n * <template>\n * <div class=\"toolbar\">\n * <button @click=\"undo\" :disabled=\"!canUndo()\">Undo</button>\n * <button @click=\"redo\" :disabled=\"!canRedo()\">Redo</button>\n * <button @click=\"clearHistory\">Clear History</button>\n * </div>\n * </template>\n * ```\n */\nexport function useGridUndoRedo(): UndoRedoMethods {\n const gridElement = inject(GRID_ELEMENT_KEY, ref(null));\n\n const getPlugin = (): UndoRedoPlugin | undefined => {\n const grid = gridElement.value as DataGridElement | null;\n return grid?.getPlugin(UndoRedoPlugin);\n };\n\n return {\n undo: () => {\n const plugin = getPlugin();\n if (!plugin) {\n console.warn(\n `[tbw-grid:undoRedo] UndoRedoPlugin not found.\\n\\n` +\n ` → Enable undo/redo on the grid:\\n` +\n ` <TbwGrid editing=\"dblclick\" undoRedo />`,\n );\n return null;\n }\n return plugin.undo();\n },\n\n redo: () => {\n const plugin = getPlugin();\n if (!plugin) {\n console.warn(\n `[tbw-grid:undoRedo] UndoRedoPlugin not found.\\n\\n` +\n ` → Enable undo/redo on the grid:\\n` +\n ` <TbwGrid editing=\"dblclick\" undoRedo />`,\n );\n return null;\n }\n return plugin.redo();\n },\n\n canUndo: () => getPlugin()?.canUndo() ?? false,\n\n canRedo: () => getPlugin()?.canRedo() ?? false,\n\n clearHistory: () => {\n const plugin = getPlugin();\n if (!plugin) {\n console.warn(\n `[tbw-grid:undoRedo] UndoRedoPlugin not found.\\n\\n` +\n ` → Enable undo/redo on the grid:\\n` +\n ` <TbwGrid editing=\"dblclick\" undoRedo />`,\n );\n return;\n }\n plugin.clearHistory();\n },\n\n getUndoStack: () => getPlugin()?.getUndoStack() ?? [],\n\n getRedoStack: () => getPlugin()?.getRedoStack() ?? [],\n };\n}\n"],"names":["registerFeature","config","UndoRedoPlugin","useGridUndoRedo","gridElement","inject","GRID_ELEMENT_KEY","ref","getPlugin","plugin"],"mappings":";;;;AAwCAA,EAAgB,YAAY,CAACC,MACvBA,MAAW,KACN,IAAIC,EAAA,IAEN,IAAIA,EAAeD,KAAU,MAAS,CAC9C;AAkEM,SAASE,IAAmC;AACjD,QAAMC,IAAcC,EAAOC,GAAkBC,EAAI,IAAI,CAAC,GAEhDC,IAAY,MACHJ,EAAY,OACZ,UAAUF,CAAc;AAGvC,SAAO;AAAA,IACL,MAAM,MAAM;AACV,YAAMO,IAASD,EAAA;AACf,aAAKC,IAQEA,EAAO,KAAA,KAPZ,QAAQ;AAAA,QACN;AAAA;AAAA;AAAA;AAAA,MAAA,GAIK;AAAA,IAGX;AAAA,IAEA,MAAM,MAAM;AACV,YAAMA,IAASD,EAAA;AACf,aAAKC,IAQEA,EAAO,KAAA,KAPZ,QAAQ;AAAA,QACN;AAAA;AAAA;AAAA;AAAA,MAAA,GAIK;AAAA,IAGX;AAAA,IAEA,SAAS,MAAMD,KAAa,aAAa;AAAA,IAEzC,SAAS,MAAMA,KAAa,aAAa;AAAA,IAEzC,cAAc,MAAM;AAClB,YAAMC,IAASD,EAAA;AACf,UAAI,CAACC,GAAQ;AACX,gBAAQ;AAAA,UACN;AAAA;AAAA;AAAA;AAAA,QAAA;AAIF;AAAA,MACF;AACA,MAAAA,EAAO,aAAA;AAAA,IACT;AAAA,IAEA,cAAc,MAAMD,KAAa,aAAA,KAAkB,CAAA;AAAA,IAEnD,cAAc,MAAMA,KAAa,kBAAkB,CAAA;AAAA,EAAC;AAExD;"}
package/index.d.ts CHANGED
@@ -49,17 +49,29 @@ export type { DetailPanelContext } from './lib/detail-panel-registry';
49
49
  export type { ResponsiveCardContext } from './lib/responsive-card-registry';
50
50
  export type { CellSlotProps, EditorSlotProps } from './lib/slot-types';
51
51
  export type { ToolPanelContext } from './lib/tool-panel-registry';
52
+ export { GridAdapter } from './lib/vue-grid-adapter';
53
+ /** @deprecated Use `GridAdapter` instead */
52
54
  export { VueGridAdapter } from './lib/vue-grid-adapter';
53
55
  export { GRID_ELEMENT_KEY, useGrid } from './lib/use-grid';
54
56
  export type { UseGridReturn } from './lib/use-grid';
55
57
  export { useGridEvent } from './lib/use-grid-event';
56
58
  export type { GridEventMap } from './lib/use-grid-event';
57
- export type { VueCellEditor, VueCellRenderer, VueColumnConfig, VueGridConfig } from './lib/vue-column-config';
59
+ export type { CellEditor, CellRenderer, ColumnConfig, GridConfig,
60
+ /** @deprecated Use `CellEditor` instead */
61
+ VueCellEditor,
62
+ /** @deprecated Use `CellRenderer` instead */
63
+ VueCellRenderer,
64
+ /** @deprecated Use `ColumnConfig` instead */
65
+ VueColumnConfig,
66
+ /** @deprecated Use `GridConfig` instead */
67
+ VueGridConfig, } from './lib/vue-column-config';
58
68
  export type { AllFeatureProps, FeatureProps } from './lib/feature-props';
59
69
  export { clearFeatureRegistry, createPluginFromFeature, getFeatureFactory, getRegisteredFeatures, isFeatureRegistered, registerFeature, } from './lib/feature-registry';
60
70
  export type { FeatureName, PluginFactory } from './lib/feature-registry';
61
71
  export { GRID_TYPE_DEFAULTS, GridTypeProvider, useGridTypeDefaults, useTypeDefault } from './lib/grid-type-registry';
62
- export type { GridTypeProviderProps, TypeDefaultsMap, VueTypeDefault } from './lib/grid-type-registry';
72
+ export type { GridTypeProviderProps, TypeDefault, TypeDefaultsMap,
73
+ /** @deprecated Use `TypeDefault` instead */
74
+ VueTypeDefault, } from './lib/grid-type-registry';
63
75
  export { GRID_ICONS, GridIconProvider, useGridIcons } from './lib/grid-icon-registry';
64
76
  export type { GridIconProviderProps } from './lib/grid-icon-registry';
65
77
  export { GridProvider } from './lib/grid-provider';
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../libs/grid-vue/src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAGH,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MA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