@svgrid/grid 3.0.4 → 3.0.6
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.
- package/README.md +32 -11
- package/dist/GridMenus.svelte +34 -4
- package/dist/SvGrid.controller.svelte.d.ts +33 -5
- package/dist/SvGrid.controller.svelte.js +397 -58
- package/dist/SvGrid.css +200 -2
- package/dist/SvGrid.svelte +350 -40
- package/dist/SvGrid.types.d.ts +433 -7
- package/dist/SvGridDropdown.svelte +20 -0
- package/dist/SvGridDropdown.svelte.d.ts +12 -0
- package/dist/SvModal.svelte +22 -0
- package/dist/SvModal.svelte.d.ts +7 -0
- package/dist/a11y/dismissable.d.ts +10 -0
- package/dist/a11y/dismissable.js +24 -2
- package/dist/build-api.js +92 -37
- package/dist/cdn/{GridMenus-BL7ZgQvU.js → GridMenus-C-NtjlrJ.js} +155 -146
- package/dist/cdn/GridMenus-TssHej3q.js +644 -0
- package/dist/cdn/{SvChartMenu-FBSMINA6.js → SvChartMenu-BFSTpvB-.js} +1 -1
- package/dist/cdn/{SvChartMenu-Bl6PBbkT.js → SvChartMenu-BZ1Iwv0y.js} +1 -1
- package/dist/cdn/{SvDateTimePicker-DQwt4UAs.js → SvDateTimePicker-D9u_cOf8.js} +1 -1
- package/dist/cdn/{SvDateTimePicker-vNU6bZ-q.js → SvDateTimePicker-s_6IUpI7.js} +1 -1
- package/dist/cdn/{SvGridCellEditor-B1p-vCK5.js → SvGridCellEditor-BlyCSp0q.js} +1 -1
- package/dist/cdn/{SvGridCellEditor-D_0q4xAu.js → SvGridCellEditor-ClRRA9lW.js} +1 -1
- package/dist/cdn/{SvGridChart-DzLkSwCH.js → SvGridChart-B4EV8U6t.js} +4 -4
- package/dist/cdn/{SvGridChart-C3EWAZaM.js → SvGridChart-DsmwTyZF.js} +4 -4
- package/dist/cdn/{SvGridChartBuilder-CfII62sZ.js → SvGridChartBuilder-cHloHobN.js} +4 -4
- package/dist/cdn/{SvGridChartBuilder-BE2T1ykB.js → SvGridChartBuilder-vOl7C0Za.js} +4 -4
- package/dist/cdn/{SvGridChartPanel-xf4sWVTo.js → SvGridChartPanel-AcqF-Ll5.js} +5 -5
- package/dist/cdn/{SvGridChartPanel-CCX5_Wgd.js → SvGridChartPanel-biMtSBPA.js} +5 -5
- package/dist/cdn/{SvGridChartView-DYwabQWj.js → SvGridChartView-Dx_GmZuL.js} +2 -2
- package/dist/cdn/{SvGridChartView-CfuXmY5I.js → SvGridChartView-I3rDHXAq.js} +2 -2
- package/dist/cdn/{SvGridDropdown-D0VdjeR8.js → SvGridDropdown-BWeM3lMe.js} +46 -46
- package/dist/cdn/{SvGridDropdown-D13MtJ2j.js → SvGridDropdown-CJ6QqTxu.js} +67 -67
- package/dist/cdn/{SvModal-CIZWCcad.js → SvModal-ClxGmpAc.js} +187 -186
- package/dist/cdn/{SvModal-BAE-pjZX.js → SvModal-DhB_VMFR.js} +148 -147
- package/dist/cdn/{cell-formatting-C2Hf5gqd.js → cell-formatting-DVVKOSI9.js} +1 -1
- package/dist/cdn/{chart-Dz7SqMXH.js → chart-DEZxwC0i.js} +1 -1
- package/dist/cdn/{chart-panel-messages-CUbf2R4i.js → chart-panel-messages-D12XcTZJ.js} +1 -1
- package/dist/cdn/{chart-panel-messages-CmNrMdsr.js → chart-panel-messages-DguS7gC5.js} +1 -1
- package/dist/cdn/{chart-summary-BJW_tg_X.js → chart-summary-CMAXBGY-.js} +1 -1
- package/dist/cdn/{chart-trend-CaN9mDEV.js → chart-trend-BkEp61Gj.js} +1 -1
- package/dist/cdn/{dismissable-DAHetSNk.js → dismissable-Brc4EZU1.js} +5 -1
- package/dist/cdn/{export-format-CUDLy2yn.js → export-format-YzdwBww2.js} +1 -1
- package/dist/cdn/{row-resize-niQCp040.js → row-resize-DtOS1KG6.js} +41 -32
- package/dist/cdn/server-block-cache-DIqb3VZn.js +241 -0
- package/dist/cdn/{src-V1uu8iE9.js → src-CgoeSM8k.js} +5339 -4753
- package/dist/cdn/{src-BKhZ6eXd.js → src-DfwxB1TH.js} +9817 -9231
- package/dist/cdn/svgrid.js +28 -27
- package/dist/cdn/svgrid.svelte-external.js +28 -27
- package/dist/cdn/validate-AZoD8BoR.js +80 -0
- package/dist/cell-formatting.js +18 -1
- package/dist/cell-render.js +25 -6
- package/dist/clipboard.d.ts +2 -2
- package/dist/clipboard.js +72 -23
- package/dist/columns.js +7 -2
- package/dist/conditional-formatting.d.ts +2 -0
- package/dist/conditional-formatting.js +2 -0
- package/dist/core.d.ts +22 -6
- package/dist/core.js +401 -38
- package/dist/editing.js +34 -0
- package/dist/gantt-view.svelte.d.ts +24 -0
- package/dist/gantt-view.svelte.js +13 -0
- package/dist/grid-icons.d.ts +2 -2
- package/dist/grid-icons.js +2 -2
- package/dist/grid-messages.d.ts +10 -0
- package/dist/grid-messages.js +9 -0
- package/dist/headless.d.ts +5 -0
- package/dist/headless.js +12 -0
- package/dist/history.d.ts +21 -0
- package/dist/history.js +34 -4
- package/dist/index.d.ts +5 -4
- package/dist/index.js +3 -3
- package/dist/keyboard-handlers.js +24 -1
- package/dist/keyboard.js +4 -0
- package/dist/row-drag-touch.d.ts +1 -1
- package/dist/row-drag.js +35 -1
- package/dist/row-model.d.ts +139 -0
- package/dist/row-model.js +16 -0
- package/dist/row-resize.js +22 -1
- package/dist/selection.d.ts +2 -1
- package/dist/selection.js +31 -3
- package/dist/server-block-cache.d.ts +219 -0
- package/dist/server-block-cache.js +539 -0
- package/dist/server-data-source.d.ts +274 -8
- package/dist/server-data-source.js +229 -20
- package/dist/server.d.ts +13 -0
- package/dist/server.js +13 -0
- package/dist/sparkline.js +7 -5
- package/dist/svgrid-wrapper.types.d.ts +33 -0
- package/dist/validate.d.ts +4 -0
- package/dist/validate.js +29 -3
- package/package.json +11 -1
- package/src/GridMenus.svelte +34 -4
- package/src/SvGrid.controller.svelte.ts +397 -61
- package/src/SvGrid.css +200 -2
- package/src/SvGrid.svelte +350 -40
- package/src/SvGrid.types.ts +453 -7
- package/src/SvGridDropdown.svelte +20 -0
- package/src/SvModal.svelte +22 -0
- package/src/SvModal.test.ts +30 -1
- package/src/a11y/dismissable.test.ts +10 -1
- package/src/a11y/dismissable.ts +22 -2
- package/src/build-api.ts +96 -31
- package/src/cell-formatting.test.ts +17 -0
- package/src/cell-formatting.ts +18 -1
- package/src/cell-render.test.ts +24 -2
- package/src/cell-render.ts +24 -8
- package/src/clipboard.test.ts +107 -0
- package/src/clipboard.ts +62 -23
- package/src/columns.test.ts +4 -4
- package/src/columns.ts +7 -2
- package/src/conditional-formatting.test.ts +8 -0
- package/src/conditional-formatting.ts +3 -0
- package/src/core.rowmodel-cache.test.ts +51 -0
- package/src/core.tick-repair.test.ts +287 -0
- package/src/core.ts +407 -38
- package/src/editing.test.ts +52 -0
- package/src/editing.ts +33 -0
- package/src/gantt-stub.test.svelte +38 -0
- package/src/gantt-view.svelte.ts +35 -0
- package/src/grid-icons.ts +2 -2
- package/src/grid-messages.test.ts +7 -0
- package/src/grid-messages.ts +22 -0
- package/src/headless.ts +24 -0
- package/src/history.test.ts +49 -1
- package/src/history.ts +48 -2
- package/src/icon-seam.test.ts +2 -4
- package/src/index.ts +38 -10
- package/src/keyboard-handlers.coverage.test.ts +65 -0
- package/src/keyboard-handlers.ts +26 -1
- package/src/keyboard.ts +3 -0
- package/src/row-drag-touch.ts +2 -2
- package/src/row-drag.test.ts +51 -0
- package/src/row-drag.ts +35 -2
- package/src/row-model.ts +152 -0
- package/src/row-resize.ts +24 -1
- package/src/selection.test.ts +3 -0
- package/src/selection.ts +33 -3
- package/src/server-block-cache.test.ts +672 -0
- package/src/server-block-cache.ts +690 -0
- package/src/server-data-source.infinite.test.ts +405 -0
- package/src/server-data-source.test.ts +19 -0
- package/src/server-data-source.ts +496 -29
- package/src/server.ts +49 -0
- package/src/sparkline.test.ts +7 -0
- package/src/sparkline.ts +6 -4
- package/src/svgrid-wrapper.types.ts +32 -0
- package/src/svgrid.api.test.ts +21 -0
- package/src/svgrid.charting.test.ts +12 -4
- package/src/svgrid.context-menu.test.ts +12 -0
- package/src/svgrid.detail-rows.svelte.test.ts +187 -0
- package/src/svgrid.filter-menu-scroll.test.ts +9 -0
- package/src/svgrid.gantt-seam.test.ts +199 -0
- package/src/svgrid.live-update-paths.svelte.test.ts +184 -0
- package/src/svgrid.menu-scroll-close.test.ts +10 -0
- package/src/svgrid.row-model-prop.svelte.test.ts +352 -0
- package/src/svgrid.row-model-seam.svelte.test.ts +305 -0
- package/src/svgrid.row-pinning.test.ts +15 -1
- package/src/svgrid.selection-bar-seam.test.ts +1 -1
- package/src/svgrid.sticky-groups.svelte.test.ts +145 -0
- package/src/svgrid.upsell-license.test.ts +8 -5
- package/src/test-setup.ts +12 -0
- package/src/transaction.test.ts +58 -0
- package/src/validate.test.ts +29 -0
- package/src/validate.ts +34 -3
- package/dist/SvGroupCell.svelte +0 -141
- package/dist/SvGroupCell.svelte.d.ts +0 -49
- package/dist/SvRowGroupPanel.svelte +0 -186
- package/dist/SvRowGroupPanel.svelte.d.ts +0 -25
- package/dist/cdn/GridMenus-7kbpnnBW.js +0 -635
- package/dist/cdn/validate-_CDJzgIo.js +0 -75
- package/dist/server-group-model.d.ts +0 -98
- package/dist/server-group-model.js +0 -263
- package/src/SvGroupCell.svelte +0 -141
- package/src/SvRowGroupPanel.svelte +0 -186
- package/src/server-group-model.test.ts +0 -294
- package/src/server-group-model.ts +0 -370
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
<p align="center">
|
|
18
18
|
<a href="https://svgrid.com">Website</a> ·
|
|
19
19
|
<a href="https://svgrid.com/docs/">Docs</a> ·
|
|
20
|
-
<a href="https://svgrid.com/demos/">
|
|
20
|
+
<a href="https://svgrid.com/demos/">400+ Demos</a> ·
|
|
21
21
|
<a href="https://svgrid.com/pricing/">Pricing</a> ·
|
|
22
22
|
<a href="https://svgrid.com/roadmap/">Roadmap</a>
|
|
23
23
|
</p>
|
|
@@ -78,7 +78,7 @@ all wire up the moment you turn on the matching prop.
|
|
|
78
78
|
|---|---|
|
|
79
79
|
| **License** | MIT, free for commercial use |
|
|
80
80
|
| **Requires** | `svelte@^5` (peer dependency), Node 16+ |
|
|
81
|
-
| **Bundle (gzip)** | ~2 KB headless core, ~
|
|
81
|
+
| **Bundle (gzip)** | ~2.7 KB headless core, ~98 KB full `<SvGrid>` + ~10 KB CSS; charts, date pickers, menus and export load as separate chunks on first use |
|
|
82
82
|
| **Types** | Bundled, no `@types/` package needed |
|
|
83
83
|
| **Module format** | ESM, plus a CDN build at `@svgrid/grid/cdn` |
|
|
84
84
|
| **SSR** | Works under SvelteKit SSR and static builds |
|
|
@@ -90,9 +90,12 @@ all wire up the moment you turn on the matching prop.
|
|
|
90
90
|
- **Filtering** - Excel-style filter menu, inline filter row, set / value-list filter, locale-aware matching, between operators.
|
|
91
91
|
- **Editing** - 15 built-in `editorType`s (text, number, date, datetime, time, select, rich-select with typeahead, autocomplete, textarea, color, checkbox, list, chips, rating, password), plus `date-native` / `datetime-native` / `time-native` to opt out of the rich pickers, and a `cellEditor` snippet slot for anything custom.
|
|
92
92
|
- **Selection** - cell-range click+drag and Shift+arrows, copy/paste as TSV, Excel-style fill handle, row selection.
|
|
93
|
-
- **Views** - row grouping with aggregation, tree data, master/detail, full-width detail rows,
|
|
93
|
+
- **Views** - row grouping with aggregation, tree data, master/detail, full-width detail rows, and a
|
|
94
|
+
spreadsheet layout mode (merged cells, per-cell borders). Formula cells here go through an adapter
|
|
95
|
+
seam you point at your own `hyperformula` install; the built-in formula engine and `<SvSheet>` are
|
|
96
|
+
in the Suite edition of `@svgrid/enterprise`.
|
|
94
97
|
- **Layout** - row + column pinning, sticky header + first column, header drag-to-reorder, autosize, keyboard-accessible column sizing, zebra rows, responsive mode.
|
|
95
|
-
- **Data operations** - find in grid (Ctrl+F), undo / redo, transaction API, optimistic updates, server-side
|
|
98
|
+
- **Data operations** - find in grid (Ctrl+F), undo / redo, transaction API, optimistic updates, server-side data with sort / filter / paging / infinite-scroll pushdown (lazy grouping, tree, pivot and transactions on the server are in `@svgrid/enterprise`).
|
|
96
99
|
- **AI helpers, free** - natural-language filter, smart fill, summarize, classify, anomaly detection, and "chart this". Model-agnostic: register one provider, nothing is bundled.
|
|
97
100
|
- **UI components** - a Svelte 5 component suite ships in the package (inputs, selection, date/time, overlays, layout, feedback), standalone or as grid cell editors.
|
|
98
101
|
- **Accessibility** - WAI-ARIA grid roles, full keyboard navigation, RTL, high-contrast theme.
|
|
@@ -131,7 +134,7 @@ import {
|
|
|
131
134
|
```
|
|
132
135
|
|
|
133
136
|
- **Headless** - drive `createSvGrid` and the row-model factories, render your own markup.
|
|
134
|
-
`getGrid*A11yProps` helpers keep custom markup accessible. About 2 KB gzipped.
|
|
137
|
+
`getGrid*A11yProps` helpers keep custom markup accessible. About 2.7 KB gzipped.
|
|
135
138
|
- **Render-ready** - `<SvGrid />` is a complete, accessible, themeable grid you configure with props.
|
|
136
139
|
|
|
137
140
|
Compatibility aliases are provided for the framework-neutral names: `createGrid`, `createGridState`,
|
|
@@ -141,7 +144,7 @@ Compatibility aliases are provided for the framework-neutral names: `createGrid`
|
|
|
141
144
|
|
|
142
145
|
SvGrid publishes an [MCP server](https://www.npmjs.com/package/@svgrid/mcp) plus
|
|
143
146
|
[llms.txt](https://svgrid.com/llms.txt) and [llms-full.txt](https://svgrid.com/llms-full.txt), so Claude,
|
|
144
|
-
Cursor, and Zed answer with accurate, version-pinned APIs and all
|
|
147
|
+
Cursor, and Zed answer with accurate, version-pinned APIs and all 400+ demo sources as context rather
|
|
145
148
|
than hallucinated methods.
|
|
146
149
|
|
|
147
150
|
```bash
|
|
@@ -154,16 +157,34 @@ See [Use sv-grid docs as LLM context](https://svgrid.com/docs/help/llm-grounding
|
|
|
154
157
|
## Enterprise features
|
|
155
158
|
|
|
156
159
|
The MIT core is free for any use, including commercial, with **no feature gating**. Sorting, filtering,
|
|
157
|
-
editing, virtualization,
|
|
158
|
-
package. The optional [`@svgrid/enterprise`](https://www.npmjs.com/package/@svgrid/enterprise) pack layers
|
|
160
|
+
editing, virtualization, **server-side data** (paging, infinite block scroll, sort, filter, CRUD) and the
|
|
161
|
+
**AI helpers** all ship in the free package. The optional [`@svgrid/enterprise`](https://www.npmjs.com/package/@svgrid/enterprise) pack layers
|
|
159
162
|
on the export- and analytics-heavy features teams tend to need last:
|
|
160
163
|
|
|
164
|
+
The pack sells in two editions, both covering unlimited production apps.
|
|
165
|
+
|
|
166
|
+
**Grid edition:**
|
|
167
|
+
|
|
161
168
|
- **Excel / PDF / CSV / TSV / HTML export** plus paginated print.
|
|
162
169
|
- **Excel / CSV / TSV / JSON import** with auto-mapping and per-row validation.
|
|
163
170
|
- **Pivot tables** with a drag-and-drop pivot Designer.
|
|
164
|
-
- **Kanban board
|
|
171
|
+
- **Kanban board, scheduler / calendar and Gantt renderers** for the `board`, `scheduler` and `gantt` props.
|
|
172
|
+
- **Server-side row model** for lazy grouping, tree, pivot and transactions.
|
|
173
|
+
|
|
174
|
+
**Suite edition** adds everything above plus:
|
|
175
|
+
|
|
176
|
+
- **A real spreadsheet.** `<SvSheet>` and the `<sv-sheet>` element over a built-in formula engine
|
|
177
|
+
with cross-sheet references, named ranges, dynamic arrays and spill, iterative calculation, and
|
|
178
|
+
dependency-graph recalculation. No `hyperformula` needed, and no runtime dependency.
|
|
179
|
+
- **Spreadsheet file formats.** Read and write `.xlsx`, `.xls`, `.ods` and `.csv`, with formulas,
|
|
180
|
+
merges, frozen panes, named ranges and charts surviving the round trip.
|
|
181
|
+
- **SvGrid Studio.** The designer, the code generator and the SQL data sources.
|
|
182
|
+
|
|
183
|
+
Both editions come with a 30-day evaluation period: every feature runs without a key, and under a
|
|
184
|
+
key that does not cover it, with a watermark and a console message about the Enterprise package. `licenseCovers('spreadsheet')` tells you which
|
|
185
|
+
side of the line the current key is on, if you would rather hide an entry point than let it nudge.
|
|
165
186
|
|
|
166
|
-
OSS projects receive
|
|
187
|
+
OSS projects receive a Suite key free. See [Pricing](https://svgrid.com/pricing/).
|
|
167
188
|
|
|
168
189
|
## Also in the box
|
|
169
190
|
|
|
@@ -203,7 +224,7 @@ Full detail: [SvGrid vs AG Grid vs TanStack Table](https://svgrid.com/docs/help/
|
|
|
203
224
|
## Documentation
|
|
204
225
|
|
|
205
226
|
- [Getting started](https://svgrid.com/docs/getting-started/) - end-to-end walkthrough.
|
|
206
|
-
- [
|
|
227
|
+
- [400+ live demos](https://svgrid.com/demos/) - copy-paste recipes for every feature.
|
|
207
228
|
- [Why headless?](https://svgrid.com/docs/why-headless/) - when to compose vs. drop in.
|
|
208
229
|
- [Theming and Tailwind](https://svgrid.com/docs/help/tailwind/) - re-skin via `--sg-*` tokens and dark mode.
|
|
209
230
|
- [Accessibility](https://svgrid.com/docs/help/accessibility/) - the WAI-ARIA grid pattern as implemented.
|
package/dist/GridMenus.svelte
CHANGED
|
@@ -214,6 +214,19 @@
|
|
|
214
214
|
});
|
|
215
215
|
}
|
|
216
216
|
|
|
217
|
+
/**
|
|
218
|
+
* Whether a column's active filter operator is one of the set operators,
|
|
219
|
+
* read at event time from component state: the condition input's focus
|
|
220
|
+
* and blur handlers cannot depend on a template `@const`, because blur
|
|
221
|
+
* also fires while the popover is being torn down, after that const's
|
|
222
|
+
* effect is gone.
|
|
223
|
+
*/
|
|
224
|
+
function isSetOperatorFor(colId: string): boolean {
|
|
225
|
+
const column = allColumns.find((c) => c.id === colId);
|
|
226
|
+
const op = filterMenuValues[colId]?.operator ?? defaultOperatorFor(column);
|
|
227
|
+
return op === "in" || op === "notIn";
|
|
228
|
+
}
|
|
229
|
+
|
|
217
230
|
/** Enter anywhere in the panel means "done" - filtering is already live. */
|
|
218
231
|
function onFilterPanelKeydown(event: KeyboardEvent) {
|
|
219
232
|
if (event.key !== "Enter" || event.shiftKey) return;
|
|
@@ -286,8 +299,23 @@
|
|
|
286
299
|
const saveComment = $derived(ctrl.saveComment);
|
|
287
300
|
const removeComment = $derived(ctrl.removeComment);
|
|
288
301
|
const closeCommentEditor = $derived(ctrl.closeCommentEditor);
|
|
302
|
+
|
|
303
|
+
function onContextMenuKeydown(event: KeyboardEvent) {
|
|
304
|
+
// Escape closes the context menu, the way every spreadsheet and desktop
|
|
305
|
+
// app does. The backdrop closes it on a click, but a keyboard user who
|
|
306
|
+
// opened it (Shift+F10, the Menu key) otherwise has no way out, and the
|
|
307
|
+
// menu sits over the sheet swallowing every other key. Handled at the
|
|
308
|
+
// window so it works whatever holds focus while the menu is open.
|
|
309
|
+
if (contextMenuFor && (event.key === "Escape" || event.key === "Esc")) {
|
|
310
|
+
event.preventDefault();
|
|
311
|
+
event.stopPropagation();
|
|
312
|
+
closeContextMenu();
|
|
313
|
+
}
|
|
314
|
+
}
|
|
289
315
|
</script>
|
|
290
316
|
|
|
317
|
+
<svelte:window onkeydown={onContextMenuKeydown} />
|
|
318
|
+
|
|
291
319
|
{#if tooltip}
|
|
292
320
|
<!-- Custom hover tooltip. Floats above the grid; positioned by
|
|
293
321
|
showTooltipFor(). Notes and column tooltips both surface here. -->
|
|
@@ -396,10 +424,12 @@
|
|
|
396
424
|
: menuActiveOperator === "regex"
|
|
397
425
|
? "Pattern..."
|
|
398
426
|
: "Filter value..."}
|
|
399
|
-
onfocus={
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
onblur={
|
|
427
|
+
onfocus={(event) => {
|
|
428
|
+
if (isSetOperatorFor(colId)) onSetOpFilterFocus(event.currentTarget as HTMLInputElement, colId);
|
|
429
|
+
}}
|
|
430
|
+
onblur={() => {
|
|
431
|
+
if (isSetOperatorFor(colId)) closeInSuggest();
|
|
432
|
+
}}
|
|
403
433
|
oninput={(event) => {
|
|
404
434
|
const input = event.currentTarget as HTMLInputElement;
|
|
405
435
|
updateFilterMenuValue(colId, input.value);
|
|
@@ -78,6 +78,7 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
78
78
|
history: SharedHistoryStep[];
|
|
79
79
|
historyPtr: number;
|
|
80
80
|
historyGroupId: string | undefined;
|
|
81
|
+
historyTag: unknown;
|
|
81
82
|
historyVersion: number;
|
|
82
83
|
tooltip: {
|
|
83
84
|
text: string;
|
|
@@ -116,6 +117,14 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
116
117
|
columnVirtualizerVersion: number;
|
|
117
118
|
gridStateVersion: number;
|
|
118
119
|
readonly selectionColumnWidth: number;
|
|
120
|
+
readonly detailToggleColumnWidth: number;
|
|
121
|
+
readonly detailToggleColumnLeft: number;
|
|
122
|
+
readonly showDetailToggleEffective: boolean;
|
|
123
|
+
readonly systemColumnsWidth: number;
|
|
124
|
+
readonly detailToggleOf: (row: Row<TData>, rowIndex: number) => {
|
|
125
|
+
open: boolean;
|
|
126
|
+
toggle: () => void;
|
|
127
|
+
} | null;
|
|
119
128
|
readonly rowNumberColumnWidth: number;
|
|
120
129
|
readonly showRowNumbersEffective: boolean;
|
|
121
130
|
readonly filterOperatorOptions: import("./SvGrid.types.js").FilterOption[];
|
|
@@ -241,7 +250,7 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
241
250
|
colDropSide: "before" | "after" | null;
|
|
242
251
|
rowDragActive: boolean;
|
|
243
252
|
rowDropIndex: number | null;
|
|
244
|
-
rowDropSide: "before" | "after" | null;
|
|
253
|
+
rowDropSide: "before" | "after" | "into" | null;
|
|
245
254
|
readonly onRowDragStart: (e: DragEvent, rowIndex: number) => void;
|
|
246
255
|
readonly onRowDragOver: (e: DragEvent, rowIndex: number) => void;
|
|
247
256
|
readonly onRowDragLeave: (rowIndex: number) => void;
|
|
@@ -297,6 +306,8 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
297
306
|
rows: TData[];
|
|
298
307
|
ids: string[];
|
|
299
308
|
};
|
|
309
|
+
readonly selectionBarCount: number;
|
|
310
|
+
readonly selectionBarVisible: boolean;
|
|
300
311
|
lastSelectionSerialized: string;
|
|
301
312
|
lastCellRangeSerialized: string;
|
|
302
313
|
readonly statusBarEnabled: boolean;
|
|
@@ -523,6 +534,13 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
523
534
|
readonly frozenRowList: Row<TData>[];
|
|
524
535
|
readonly frozenBandHeight: number;
|
|
525
536
|
readonly frozenRowTop: (i: number) => number;
|
|
537
|
+
readonly stickyGroupRows: {
|
|
538
|
+
row: Row<TData>;
|
|
539
|
+
rowIndex: number;
|
|
540
|
+
top: number;
|
|
541
|
+
size: number;
|
|
542
|
+
}[];
|
|
543
|
+
readonly stickyTopOfRow: (rowIndex: number) => number | undefined;
|
|
526
544
|
/** Record the height the user dragged a row to. */
|
|
527
545
|
readonly setRowResizeHeight: (index: number, height: number | null) => void;
|
|
528
546
|
readonly isRowCollapsed: (index: number) => boolean;
|
|
@@ -532,6 +550,8 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
532
550
|
readonly autosizeColumnByUser: (columnId: string) => void;
|
|
533
551
|
/** A row's dragged height, or undefined when it has not been resized. */
|
|
534
552
|
readonly rowResizeHeightPx: (index: number) => number | undefined;
|
|
553
|
+
/** The height row i is drawn at: dragged, measured, detail, declared or default. */
|
|
554
|
+
readonly rowSizePxOf: (i: number) => number;
|
|
535
555
|
readonly virtualRowTotalSize: number;
|
|
536
556
|
readonly virtualRowStart: number;
|
|
537
557
|
readonly virtualRowEnd: number;
|
|
@@ -598,10 +618,18 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
598
618
|
readonly getPinnedCellValue: typeof getPinnedCellValue;
|
|
599
619
|
readonly formatPinnedValue: (column: Column<TData>, value: unknown) => string;
|
|
600
620
|
readonly computePinnedCellClass: (rowData: TData, column: Column<TData>) => string;
|
|
601
|
-
readonly isRowSelected: (rowId: string) =>
|
|
621
|
+
readonly isRowSelected: (rowId: string) => any;
|
|
602
622
|
readonly toggleRowSelectionById: (rowId: string) => void;
|
|
603
|
-
readonly headerSelectionState: "
|
|
623
|
+
readonly headerSelectionState: "some" | "none" | "all";
|
|
624
|
+
readonly visibleRowRange: {
|
|
625
|
+
startIndex: number;
|
|
626
|
+
endIndex: number;
|
|
627
|
+
};
|
|
628
|
+
placeholderStateOf: (row: Row<TData>) => "loading" | "failed" | null;
|
|
629
|
+
/** Retry a failed placeholder row. No-op without `onRetryRow`. */
|
|
630
|
+
retryRow(row: Row<TData>): void;
|
|
604
631
|
readonly toggleSelectAllRows: () => void;
|
|
632
|
+
readonly setSelectAllRows: (select: boolean) => void;
|
|
605
633
|
userHasActivatedCell: boolean;
|
|
606
634
|
tabRunOrigin: number | null;
|
|
607
635
|
readonly setActiveCell: (rowIndex: number, colIndex: number) => void;
|
|
@@ -662,11 +690,11 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
662
690
|
columnResizable(columnId: string): boolean;
|
|
663
691
|
readonly readCellRaw: (rowIndex: number, columnId: string) => unknown;
|
|
664
692
|
readonly writeCellRaw: (rowIndex: number, columnId: string, value: unknown) => void;
|
|
665
|
-
readonly applyFillPattern: () => void;
|
|
693
|
+
readonly applyFillPattern: (toggled?: boolean) => void;
|
|
666
694
|
readonly clearSelectedCellValues: () => void;
|
|
667
695
|
readonly startFillDrag: (event: PointerEvent, rowIndex: number, colIndex: number) => void;
|
|
668
696
|
readonly onFillPointerMove: (event: PointerEvent) => void;
|
|
669
|
-
readonly onFillPointerUp: () => void;
|
|
697
|
+
readonly onFillPointerUp: (event?: PointerEvent) => void;
|
|
670
698
|
readonly fillDownToNeighbour: () => void;
|
|
671
699
|
readonly isOnMoveGrabStrip: (cell: HTMLElement, rowIndex: number, colIndex: number, clientX: number, clientY: number) => boolean;
|
|
672
700
|
readonly startMoveDrag: (event: PointerEvent, rowIndex: number, colIndex: number) => boolean;
|