@rowsncolumns/rnc-engine 0.10.132

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 (37) hide show
  1. package/LICENSE.md +100 -0
  2. package/README.md +83 -0
  3. package/dist/esm/command-handlers.d.ts +169 -0
  4. package/dist/esm/command-handlers.d.ts.map +1 -0
  5. package/dist/esm/command-handlers.js +404 -0
  6. package/dist/esm/fold.d.ts +140 -0
  7. package/dist/esm/fold.d.ts.map +1 -0
  8. package/dist/esm/fold.js +539 -0
  9. package/dist/esm/index.d.ts +620 -0
  10. package/dist/esm/index.d.ts.map +1 -0
  11. package/dist/esm/index.js +425 -0
  12. package/dist/esm/io.d.ts +119 -0
  13. package/dist/esm/io.d.ts.map +1 -0
  14. package/dist/esm/io.js +318 -0
  15. package/dist/esm/keys.d.ts +20 -0
  16. package/dist/esm/keys.d.ts.map +1 -0
  17. package/dist/esm/keys.js +41 -0
  18. package/dist/esm/move-rescope.d.ts +18 -0
  19. package/dist/esm/move-rescope.d.ts.map +1 -0
  20. package/dist/esm/move-rescope.js +38 -0
  21. package/dist/esm/use-engine-core.d.ts +293 -0
  22. package/dist/esm/use-engine-core.d.ts.map +1 -0
  23. package/dist/esm/use-engine-core.js +2279 -0
  24. package/dist/esm/use-engine-pivot-editor.d.ts +78 -0
  25. package/dist/esm/use-engine-pivot-editor.d.ts.map +1 -0
  26. package/dist/esm/use-engine-pivot-editor.js +252 -0
  27. package/dist/esm/use-spreadsheet-engine.d.ts +7 -0
  28. package/dist/esm/use-spreadsheet-engine.d.ts.map +1 -0
  29. package/dist/esm/use-spreadsheet-engine.js +23 -0
  30. package/dist/esm/use-spreadsheet-ui.d.ts +39 -0
  31. package/dist/esm/use-spreadsheet-ui.d.ts.map +1 -0
  32. package/dist/esm/use-spreadsheet-ui.js +78 -0
  33. package/dist/esm/wasm/rnc_wasm.d.ts +394 -0
  34. package/dist/esm/wasm/rnc_wasm.js +1455 -0
  35. package/dist/esm/wasm/rnc_wasm_bg.wasm +0 -0
  36. package/dist/esm/wasm/rnc_wasm_bg.wasm.d.ts +81 -0
  37. package/package.json +51 -0
package/LICENSE.md ADDED
@@ -0,0 +1,100 @@
1
+ # Rows n' Columns Commercial License Agreement
2
+
3
+ This Rows n' Columns Commercial License Agreement (the "Agreement") governs
4
+ the use of the Rows n' Columns software packages published under the
5
+ `@rowsncolumns` npm scope, including associated JavaScript, WebAssembly
6
+ binaries, stylesheets, type definitions and documentation (the "Software").
7
+
8
+ The Software is **not** open source. Downloading or installing the Software
9
+ from a public package registry does not grant any right to use it beyond the
10
+ evaluation use described below.
11
+
12
+ ## 1. Definitions
13
+
14
+ - **"Licensor"** means Rows n' Columns (rowsncolumns.app).
15
+ - **"Licensee"** means the individual or legal entity identified in an Order.
16
+ - **"Order"** means a purchase of a license for the Software from Licensor,
17
+ identified by an order ID and associated with a License Key.
18
+ - **"License Key"** means the signed key issued by Licensor that identifies
19
+ the Licensee, license tier, and Update Window.
20
+ - **"Update Window"** means the period stated in the Order during which
21
+ Software versions released by Licensor are covered by the License Key.
22
+
23
+ ## 2. License Grant
24
+
25
+ Subject to payment of the applicable fees and compliance with this Agreement,
26
+ Licensor grants Licensee a non-exclusive, non-transferable, worldwide license
27
+ to use, and to distribute in compiled form as an embedded component of
28
+ Licensee's own applications, any version of the Software released during the
29
+ Update Window, in accordance with the license tier stated in the Order.
30
+
31
+ This grant is perpetual for versions released during the Update Window:
32
+ Licensee may continue to use those versions after the Update Window ends.
33
+ Versions released after the Update Window ends require a new or renewed
34
+ Order.
35
+
36
+ ## 3. Evaluation Use
37
+
38
+ The Software may be used without a License Key solely for internal
39
+ evaluation and development purposes. Evaluation use in production, or
40
+ removal or suppression of evaluation notices, is not permitted.
41
+
42
+ ## 4. Restrictions
43
+
44
+ Except as expressly permitted by this Agreement or by applicable law that
45
+ cannot be contractually waived, Licensee shall not:
46
+
47
+ 1. redistribute, resell, sublicense, or otherwise make the Software
48
+ available as a standalone product, library, or development component;
49
+ 2. use the Software to build a product that competes with the Software;
50
+ 3. remove, alter, or circumvent License Key validation, evaluation notices,
51
+ watermarks, or copyright notices in the Software;
52
+ 4. share License Keys with any third party, or use a License Key outside
53
+ the scope of the tier stated in the Order;
54
+ 5. reverse engineer, decompile, or disassemble the Software except to the
55
+ extent permitted by applicable law.
56
+
57
+ ## 5. Ownership
58
+
59
+ The Software is licensed, not sold. Licensor and its licensors retain all
60
+ right, title, and interest in and to the Software, including all
61
+ intellectual property rights.
62
+
63
+ ## 6. Third-Party Components
64
+
65
+ The Software may include third-party open-source components. Those
66
+ components remain governed by their own license terms, which are included
67
+ with the applicable component and are not limited by this Agreement.
68
+
69
+ ## 7. Termination
70
+
71
+ This Agreement terminates automatically upon material breach by Licensee
72
+ that remains uncured 30 days after written notice. Upon termination,
73
+ Licensee must cease use and distribution of the Software, except that
74
+ end-user copies of Licensee applications already distributed in compliance
75
+ with this Agreement are unaffected.
76
+
77
+ ## 8. Warranty Disclaimer
78
+
79
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
80
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
81
+ FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
82
+
83
+ ## 9. Limitation of Liability
84
+
85
+ TO THE MAXIMUM EXTENT PERMITTED BY LAW, IN NO EVENT SHALL LICENSOR BE LIABLE
86
+ FOR ANY INDIRECT, INCIDENTAL, SPECIAL, CONSEQUENTIAL, OR PUNITIVE DAMAGES,
87
+ OR ANY LOSS OF PROFITS, DATA, OR GOODWILL, ARISING OUT OF OR RELATED TO THIS
88
+ AGREEMENT, AND LICENSOR'S AGGREGATE LIABILITY SHALL NOT EXCEED THE FEES PAID
89
+ BY LICENSEE IN THE TWELVE MONTHS PRECEDING THE CLAIM.
90
+
91
+ ## 10. General
92
+
93
+ This Agreement constitutes the entire agreement between the parties
94
+ concerning the Software and supersedes any prior agreements. If any
95
+ provision is held unenforceable, the remainder remains in effect. Failure to
96
+ enforce a provision is not a waiver.
97
+
98
+ For licensing inquiries, visit <https://www.rowsncolumns.app/pricing>.
99
+
100
+ Copyright © Rows n' Columns. All rights reserved.
package/README.md ADDED
@@ -0,0 +1,83 @@
1
+ # @rowsncolumns/rnc-engine
2
+
3
+ Typed JS/TS interop for the Rust→WASM spreadsheet calc engine (`rust/crates/rnc-wasm`).
4
+
5
+ The low-level binding is **generated** by wasm-bindgen (`rnc-wasm` package: `rnc_wasm.js` + `.d.ts` +
6
+ `_bg.wasm`). This package is the thin, idiomatic layer on top: it parses/serializes the JSON the wasm
7
+ surface speaks and gives you typed methods using the exact `rnc-model` / `commands.ts` shapes.
8
+
9
+ ## Prerequisite — build the wasm package
10
+
11
+ ```sh
12
+ cd rust
13
+ wasm-pack build crates/rnc-wasm --target web --out-dir pkg
14
+ ```
15
+
16
+ `@rowsncolumns/rnc-engine` depends on that output via `"rnc-wasm": "file:../../rust/crates/rnc-wasm/pkg"`,
17
+ so build it before `yarn install` (or rebuild + reinstall after engine changes).
18
+
19
+ ## Usage
20
+
21
+ ```ts
22
+ import { RncEngine } from "@rowsncolumns/rnc-engine";
23
+ import type { Command } from "@rowsncolumns/spreadsheet-state";
24
+
25
+ const engine = await RncEngine.create([{ sheetId: 1, title: "Sheet1" }]);
26
+
27
+ // Subscribe for results — the engine streams a complete change-set (computed formula results AND
28
+ // their dependents, structural shifts, cleared cells) for every command.
29
+ const unsubscribe = engine.onChanges((commit) => {
30
+ for (const c of commit.changes) {
31
+ // c.sheetId / c.rowIndex / c.columnIndex / c.formatted / c.number / c.removed
32
+ }
33
+ });
34
+
35
+ // Just send commands — results arrive via the subscriber above.
36
+ engine.applyCommand({
37
+ command: "set-value",
38
+ sheetId: 1,
39
+ coords: { rowIndex: 1, columnIndex: 1 },
40
+ value: "=SUM(A2:A10)",
41
+ } as Command);
42
+ // (applyCommand also returns the same CommitResult inline, for callers that prefer pull.)
43
+
44
+ // Read a windowed rectangle for lazy/virtualized rendering.
45
+ const win = engine.readWindow(1, 1, 1, 50, 26);
46
+ const styleMap = RncEngine.toStyleMap(win.styles); // Map<"1!A1", CellFormat>
47
+ ```
48
+
49
+ Wire it behind `useSpreadsheetState`: `onCommand` sends each command into the engine, and an
50
+ `onChanges` subscriber streams computed values back into the grid — see
51
+ `libs/storybook/stories/spreadsheet-rust-wasm.stories.tsx`. The UI does nothing but **send + subscribe**.
52
+
53
+ ### Why the subscriber lives in TS, not as a wasm callback
54
+
55
+ In-thread, Rust has no event loop — every entry is JS-initiated — and you can't safely invoke a JS
56
+ callback from inside a `&mut self` wasm method (it re-enters mid-borrow → "recursive use / unsafe
57
+ aliasing"). So `applyCommand` returns first (releasing the borrow), *then* `RncEngine` notifies
58
+ subscribers, who may safely call back into `readWindow`. The same `onChanges` API is the seam for
59
+ out-of-band changes later (volatile recalc ticks, or Worker `postMessage` when calc moves off the
60
+ main thread) — without the UI's subscribe code changing.
61
+
62
+ ## API
63
+
64
+ | Member | Returns | Notes |
65
+ |---|---|---|
66
+ | `RncEngine.create(sheets?)` | `Promise<RncEngine>` | Initializes wasm (idempotent) + registers sheets. |
67
+ | `engine.addSheet(id, name)` | `void` | Register a sheet. |
68
+ | `engine.applyCommand(command)` | `CommitResult` | Sends a command; notifies `onChanges` subscribers. Also returns `{ changes, styleChanges, fullResyncSheets }` inline. |
69
+ | `engine.onChanges(listener)` | `() => void` | Subscribe to change-sets; returns an unsubscribe fn. |
70
+ | `engine.readWindow(sheetId, sr, sc, er, ec)` | `WindowSnapshot` | 1-indexed, inclusive. `{ cells, styles }`. |
71
+ | `engine.sheetIds()` | `number[]` | Registered sheet ids, in order. |
72
+ | `RncEngine.toStyleMap(styles)` | `Map<string, CellFormat>` | Folds `StyleEntry[]` into `"sheetId!A1"` keys. |
73
+ | `cellKey(sheetId, row, col)` / `columnLabel(col)` | `string` | A1 helpers. |
74
+
75
+ All shapes (`CommitResult`, `CellChange`, `WindowSnapshot`, `WindowCell`, `StyleEntry`) mirror the
76
+ `rnc-store` Rust structs exactly and **reuse the canonical contract types** — coordinates are
77
+ `CellInterface` (`rowIndex`/`columnIndex`), windows are `SheetRange`, sheet-scoped cells are
78
+ `SheetCoordinate`. So the JSON is `{ rowIndex, columnIndex, sheetId, startRowIndex, … }`, never
79
+ ad-hoc `row`/`col`/`startRow` keys. On the Rust side these are `#[serde(flatten)]`-embedded.
80
+
81
+ > Publishing note: `main`/`module` point at `./src` for zero-build consumption inside the monorepo
82
+ > (Vite/esbuild compile the TS source). To publish standalone, run `yarn build`, vendor the `rnc-wasm`
83
+ > output into the package, and point `main`/`module`/`types` at `./dist`.
@@ -0,0 +1,169 @@
1
+ /**
2
+ * The full command-emitting handler surface for {@link useEngineCore} — a 1:1 mirror of the
3
+ * `on*` handlers `useSpreadsheetState` exposes (same names, same signatures), so the Option-B hook is
4
+ * a drop-in. Every handler is a thin emitter: it builds the matching `commands.ts` command and
5
+ * forwards it through `onCommand` to the engine (which owns ALL execution). The convention
6
+ * (commands.ts): a handler's args ARE the command payload + a `command` discriminator.
7
+ *
8
+ * Kept React-free (and split out of the hook) so the handler→command mapping is unit-testable without
9
+ * a renderer — see `__tests__/command-handlers.spec.ts`.
10
+ */
11
+ import type { CellInterface, Color, Direction, GridRange, SelectionArea, SheetRange, SortOrder } from "@rowsncolumns/common-types";
12
+ import type { AXIS, BandedDefinition, BandedRange, BorderLocation, BorderStyle, ColorFilterCriteria, ConditionType, ConditionValue, IconFilterCriteria, EmbeddedChart, EmbeddedObject, FilterView, NamedRange, PivotTable, ProtectedRange, SelectionAttributes, Sheet, Slicer, SpreadsheetTheme, TableTheme, TableView, TextFormatRun } from "@rowsncolumns/spreadsheet";
13
+ import type { useSpreadsheetState } from "@rowsncolumns/spreadsheet-state";
14
+ import type { Command, CommandOf } from "./index";
15
+ /** The reference hook's return type — used to borrow exact signatures (e.g. `onFillRange`) so the
16
+ * engine handlers are drop-in for what CanvasGrid passes. Type-only; erased at runtime. */
17
+ type SS = ReturnType<typeof useSpreadsheetState>;
18
+ /** A SelectionArea carrying the grid's selection attributes (the shape every range-scoped command
19
+ * and handler uses). */
20
+ type Selections = SelectionArea<SelectionAttributes>[];
21
+ export interface EngineSpreadsheetHandlers {
22
+ onChange: (sheetId: number, coords: CellInterface, value: string, textFormatRuns: TextFormatRun[] | undefined | null) => void;
23
+ onChangeBatch: (sheetId: number, ranges: CommandOf<"change-batch">["ranges"], values: CommandOf<"change-batch">["values"], formatting?: CommandOf<"change-batch">["formatting"], citations?: CommandOf<"change-batch">["citations"], options?: CommandOf<"change-batch">["options"]) => void;
24
+ onDelete: (sheetId: number, activeCell: CellInterface, selections: Selections, clearType?: CommandOf<"delete-cells">["clearType"]) => void;
25
+ onFill: SS["onFill"];
26
+ onFillRange: SS["onFillRange"];
27
+ onSplitTextToColumns: SS["onSplitTextToColumns"];
28
+ onRemoveDuplicates: SS["onRemoveDuplicates"];
29
+ onFindReplace: (ranges: SheetRange[], find: string, replace: string, matchCase?: boolean, wholeWord?: boolean, useRegex?: boolean) => void;
30
+ onChangeFormatting: SS["onChangeFormatting"];
31
+ onChangeBorder: (sheetId: number, activeCell: CellInterface, selections: Selections, location: BorderLocation, color: Color | undefined, style: BorderStyle | undefined) => void;
32
+ onClearFormatting: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
33
+ onChangeDecimals: (sheetId: number, activeCell: CellInterface, selections: Selections, type: "increment" | "decrement") => void;
34
+ onIncreaseIndent: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
35
+ onDecreaseIndent: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
36
+ onChangeIndent: (sheetId: number, activeCell: CellInterface, selections: Selections, shouldIncrease: boolean) => void;
37
+ onInsertDate: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
38
+ onInsertTime: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
39
+ onInsertDateTime: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
40
+ onInsertAutoSum: (sheetId: number, activeCell: CellInterface, functionName?: "SUM" | "AVERAGE" | "COUNT" | "MAX" | "MIN") => void;
41
+ onMergeCells: (sheetId: number, activeCell: CellInterface, selections: Selections, direction?: Direction) => void;
42
+ onUnMergeCells: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
43
+ onInsertRow: (sheetId: number, referenceRowIndex: number, numRows?: number) => void;
44
+ onInsertColumn: (sheetId: number, referenceColumnIndex: number, numColumns?: number) => void;
45
+ onDeleteRow: (sheetId: number, rowIndexes: number[]) => void;
46
+ onDeleteColumn: (sheetId: number, columnIndexes: number[]) => void;
47
+ onMoveRows: (sheetId: number, rows: number[], referenceRowIndex: number) => void;
48
+ onMoveColumns: (sheetId: number, columns: number[], referenceColumnIndex: number) => void;
49
+ onMoveSelection: (sheetId: number, from: SelectionArea<SelectionAttributes>, to: SelectionArea<SelectionAttributes>) => void;
50
+ onHideRow: (sheetId: number, rowIndexes: number[]) => void;
51
+ onShowRow: (sheetId: number, rowIndexes: number[]) => void;
52
+ onHideColumn: (sheetId: number, columnIndexes: number[]) => void;
53
+ onShowColumn: (sheetId: number, columnIndexes: number[]) => void;
54
+ onGroupRows: (sheetId: number, rowIndexes: number[]) => void;
55
+ onUngroupRows: (sheetId: number, rowIndexes: number[]) => void;
56
+ onCollapseRowGroup: (sheetId: number, summaryRowIndex: number) => void;
57
+ onExpandRowGroup: (sheetId: number, summaryRowIndex: number) => void;
58
+ onGroupColumns: (sheetId: number, columnIndexes: number[]) => void;
59
+ onUngroupColumns: (sheetId: number, columnIndexes: number[]) => void;
60
+ onCollapseColumnGroup: (sheetId: number, summaryColumnIndex: number) => void;
61
+ onExpandColumnGroup: (sheetId: number, summaryColumnIndex: number) => void;
62
+ onSetOutlineDepth: (sheetId: number, axis: "row" | "column", depth: number) => void;
63
+ onResize: (sheetId: number, indexes: number[], dimension: number, axis: AXIS, autoFit?: boolean) => void;
64
+ onAutoResize: (sheetId: number, indexes: number[], axis: AXIS, sizes?: number[]) => void;
65
+ onFreezeRow: (sheetId: number, rowIndex: number) => void;
66
+ onFreezeColumn: (sheetId: number, columnIndex: number) => void;
67
+ onInsertCellsShiftDown: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
68
+ onInsertCellsShiftRight: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
69
+ onDeleteCellsShiftUp: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
70
+ onDeleteCellsShiftLeft: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
71
+ onCreateNewSheet: (sheetSpec?: Partial<Sheet>) => Sheet | undefined;
72
+ onDeleteSheet: (sheetId: number) => void;
73
+ onRenameSheet: (sheetId: number, name: string, oldName: string) => void;
74
+ onMoveSheet: (sheetId: number, currentPosition: number, newPosition: number) => void;
75
+ onDuplicateSheet: (sheetId: number) => void;
76
+ onHideSheet: (sheetId: number) => void;
77
+ onShowSheet: (sheetId: number) => void;
78
+ onChangeSheetTabColor: (sheetId: number, color: Color | undefined) => void;
79
+ onSortColumn: (sheetId: number, sortedColumnIndex: number, sortOrder: SortOrder) => void;
80
+ onSortRange: (sheetId: number, selections: Selections, sortOrder: SortOrder) => void;
81
+ onSortTable: (sheetId: number, filter: TableView | FilterView, dimensionIndex: number, sortOrder: SortOrder) => void;
82
+ onFilterTable: (sheetId: number, filter: TableView | FilterView, columnIndex: number, conditionType: ConditionType | undefined, conditionValue: ConditionValue[] | undefined, visibleValues: string[] | undefined | null,
83
+ /** Color / icon criteria — same extras contract as `createFilterSpecs` (absent = carry
84
+ * forward, `null` = clear). The filter-box passes these on every submit. */
85
+ extras?: {
86
+ colorFilter?: ColorFilterCriteria | null;
87
+ iconFilter?: IconFilterCriteria | null;
88
+ }) => void;
89
+ onDeleteFilter: (sheetId: number, filter: TableView | FilterView, columnIndex: number) => void;
90
+ onCreateBasicFilter: (sheetId: number, activeCell: CellInterface, selections: Selections, basicFilterSpec?: Partial<FilterView>) => void;
91
+ onCreateTable: (sheetId: number, activeCell: CellInterface, selections: Selections, tableSpec?: Partial<TableView>, theme?: TableTheme, bandedRange?: BandedDefinition) => void;
92
+ onRemoveTable: (tableView: TableView) => void;
93
+ onUpdateTable: (sheetId: number, tableId: TableView["id"], updatedTable: Partial<TableView>) => void;
94
+ onResizeTable: (sheetId: number, table: TableView, range: GridRange) => void;
95
+ onInsertTableRow: (tableView: TableView, relativeRowIndex?: number, rowData?: CommandOf<"insert-table-row">["rowData"]) => void;
96
+ onDeleteTableRow: (tableView: TableView, rowIndexes: number[]) => void;
97
+ onInsertTableColumn: (tableView: TableView, dimensionIndex: number, direction: CommandOf<"insert-table-column">["direction"]) => void;
98
+ onDeleteTableColumn: (tableView: TableView, dimensionIndex: number) => void;
99
+ onMoveTableColumns: (sheetId: number, tableId: TableView["id"], columns: number[], referenceColumnIndex: number) => void;
100
+ onChangeTableColumn: (sheetId: number, tableId: TableView["id"], columnIndex: number, name: string) => void;
101
+ onCalculatedColumn: (sheetId: number, tableId: TableView["id"], columnIndex: number, formula: string, fromRowIndex: number) => void;
102
+ onCreateNamedRange: (sheetId: number, namedRange: NamedRange) => void;
103
+ onUpdateNamedRange: (sheetId: number, namedRange: NamedRange, previousNamedRange: NamedRange) => void;
104
+ onDeleteNamedRange: (namedRangeId: NamedRange["namedRangeId"]) => void;
105
+ onUpdateNote: (sheetId: number, activeCell: CellInterface, note?: string) => void;
106
+ onInsertLink: (sheetId: number, activeCell: CellInterface, selections: Selections | undefined, url: string, title?: string) => void;
107
+ onRemoveLink: (sheetId: number, activeCell: CellInterface, selections?: Selections) => void;
108
+ onInsertImage: (sheetId: number, activeCell: CellInterface, imageUrl: string, width: number, height: number, insertOverCells?: boolean, embedId?: string | number) => void;
109
+ onInsertCheckbox: (sheetId: number, activeCell: CellInterface, selections: Selections) => void;
110
+ onInsertComment: SS["onInsertComment"];
111
+ onRemoveComment: SS["onRemoveComment"];
112
+ onCreateCitation: SS["onCreateCitation"];
113
+ onUpdateCitation: SS["onUpdateCitation"];
114
+ onDeleteCitation: SS["onDeleteCitation"];
115
+ onRemoveCitationFromCell: SS["onRemoveCitationFromCell"];
116
+ onUpdateConditionalFormattingRule: SS["onUpdateConditionalFormattingRule"];
117
+ onDeleteConditionalFormattingRule: SS["onDeleteConditionalFormattingRule"];
118
+ /** Live, non-committing CF preview — overlays the candidate rule in the engine (evaluated + in
119
+ * facets) without persisting or recording undo. The grid renders it until commit or clear. */
120
+ onPreviewConditionalFormattingRule: SS["onPreviewConditionalFormattingRule"];
121
+ onCreateDataValidationRule: SS["onCreateDataValidationRule"];
122
+ onUpdateDataValidationRule: SS["onUpdateDataValidationRule"];
123
+ onDeleteDataValidationRule: SS["onDeleteDataValidationRule"];
124
+ onAddBandedRange: (sheetId: number, bandedRange: BandedRange) => void;
125
+ onRemoveBandedRange: (sheetId: number, bandedRange: BandedRange) => void;
126
+ onProtectRange: (sheetId: number, activeCell: CellInterface, selections: Selections | undefined) => void;
127
+ onUnProtectRange: (sheetId: number, protectedRangeId: ProtectedRange["protectedRangeId"]) => void;
128
+ onProtectSheet: (sheetId: number) => void;
129
+ onUnProtectSheet: (sheetId: number) => void;
130
+ onCreateEmbed: (spec: EmbeddedObject) => void;
131
+ onUpdateEmbed: (embed: EmbeddedObject) => void;
132
+ onMoveEmbed: (embedId: EmbeddedObject["embedId"], sheetId: number, anchorCell: CellInterface, offsetXPixels: number, offsetYPixels: number) => void;
133
+ onResizeEmbed: (embedId: EmbeddedObject["embedId"], sheetId: number, anchorCell: CellInterface, offsetXPixels: number, offsetYPixels: number, width: number, height: number) => void;
134
+ onDeleteEmbed: (embedId: EmbeddedObject["embedId"]) => void;
135
+ onCreateSlicer: (slicer: Slicer) => void;
136
+ onUpdateSlicer: (slicer: Slicer) => void;
137
+ onMoveSlicer: (slicerId: Slicer["slicerId"], sheetId: number, anchorCell: CellInterface, offsetXPixels: number, offsetYPixels: number) => void;
138
+ onResizeSlicer: (slicerId: Slicer["slicerId"], sheetId: number, anchorCell: CellInterface, offsetXPixels: number, offsetYPixels: number, width: number, height: number) => void;
139
+ onDeleteSlicer: (slicerId: Slicer["slicerId"]) => void;
140
+ onCreateChart: (spec: EmbeddedChart) => void;
141
+ onUpdateChart: (chart: EmbeddedChart) => void;
142
+ onDeleteChart: (chartId: EmbeddedChart["chartId"]) => void;
143
+ onCreatePivotTable: (pivotTable: PivotTable) => void;
144
+ onUpdatePivotTable: (pivotId: PivotTable["pivotId"], pivotTable: PivotTable) => void;
145
+ onDeletePivotTable: (pivotId: PivotTable["pivotId"]) => void;
146
+ onRefreshPivot: (pivotId: PivotTable["pivotId"]) => void;
147
+ onExpandPivotRow: (pivotId: PivotTable["pivotId"], groupKeys: string[]) => void;
148
+ onCollapsePivotRow: (pivotId: PivotTable["pivotId"], groupKeys: string[]) => void;
149
+ onExpandPivotColumn: (pivotId: PivotTable["pivotId"], path: (string | number | boolean | null)[]) => void;
150
+ onCollapsePivotColumn: (pivotId: PivotTable["pivotId"], path: (string | number | boolean | null)[]) => void;
151
+ onDrillDownPivot: (pivotId: PivotTable["pivotId"], filters?: Record<string, string | number | null | undefined>,
152
+ /** The clicked output cell — the ENGINE resolves the filters from its own
153
+ * computed layout when given (preferred over UI-resolved `filters`). */
154
+ cell?: {
155
+ rowIndex: number;
156
+ columnIndex: number;
157
+ }) => void;
158
+ onChangeSpreadsheetTheme: (theme: SpreadsheetTheme) => void;
159
+ /** `previousLocale` is accepted for drop-in compat but never forwarded — the engine re-derives the
160
+ * outgoing locale from its own current state, so the command only carries the new locale. */
161
+ onChangeLocale: (locale: string, previousLocale?: string) => void;
162
+ }
163
+ /**
164
+ * Build the {@link EngineSpreadsheetHandlers} over a single `onCommand` sink. Pure (no React) —
165
+ * `useEngineCore` wraps this in a `useMemo([onCommand])`.
166
+ */
167
+ export declare function createCommandHandlers(onCommand: (command: Command) => void): EngineSpreadsheetHandlers;
168
+ export {};
169
+ //# sourceMappingURL=command-handlers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"command-handlers.d.ts","sourceRoot":"","sources":["../../src/command-handlers.ts"],"names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