@svgrid/grid 3.0.6 → 3.0.8
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 +1 -1
- package/dist/SvGrid.controller.svelte.d.ts +2 -0
- package/dist/SvGrid.controller.svelte.js +46 -9
- package/dist/SvGrid.css +16 -5
- package/dist/SvGrid.helpers.js +2 -4
- package/dist/SvGrid.svelte +4 -1
- package/dist/cdn/{GridMenus-C-NtjlrJ.js → GridMenus-B8-Gbfq2.js} +2 -2
- package/dist/cdn/{GridMenus-TssHej3q.js → GridMenus-D15bhpX5.js} +2 -2
- package/dist/cdn/{SvGridCellEditor-BlyCSp0q.js → SvGridCellEditor-9yz-SbdZ.js} +1 -1
- package/dist/cdn/{SvGridCellEditor-ClRRA9lW.js → SvGridCellEditor-D7-ql1Hd.js} +1 -1
- package/dist/cdn/{SvGridChart-DsmwTyZF.js → SvGridChart-DMUOFxOe.js} +3 -3
- package/dist/cdn/{SvGridChart-B4EV8U6t.js → SvGridChart-N7ik0oWy.js} +3 -3
- package/dist/cdn/{SvGridChartBuilder-cHloHobN.js → SvGridChartBuilder-CB_Jnm2k.js} +3 -3
- package/dist/cdn/{SvGridChartBuilder-vOl7C0Za.js → SvGridChartBuilder-Ca7gF8ZK.js} +3 -3
- package/dist/cdn/{SvGridChartPanel-AcqF-Ll5.js → SvGridChartPanel-9GOJRHP7.js} +5 -5
- package/dist/cdn/{SvGridChartPanel-biMtSBPA.js → SvGridChartPanel-Dl-FujN8.js} +5 -5
- package/dist/cdn/{SvGridChartView-I3rDHXAq.js → SvGridChartView-B1LFgoPP.js} +2 -2
- package/dist/cdn/{SvGridChartView-Dx_GmZuL.js → SvGridChartView-By3n7DGZ.js} +2 -2
- package/dist/cdn/{cell-formatting-DVVKOSI9.js → cell-formatting-Mnv84zoE.js} +27 -5
- package/dist/cdn/{chart-DEZxwC0i.js → chart-By7h2Guv.js} +1 -1
- package/dist/cdn/{chart-panel-messages-D12XcTZJ.js → chart-panel-messages-BC-tOgFY.js} +1 -1
- package/dist/cdn/{chart-panel-messages-DguS7gC5.js → chart-panel-messages-DUaXr-sb.js} +1 -1
- package/dist/cdn/{chart-summary-CMAXBGY-.js → chart-summary-BDtrNEiA.js} +1 -1
- package/dist/cdn/{chart-trend-BkEp61Gj.js → chart-trend-C1aOAPBZ.js} +1 -1
- package/dist/cdn/{editor-registry-BhgE3S84.js → editor-registry-BVeHvlZR.js} +49 -50
- package/dist/cdn/{export-format-YzdwBww2.js → export-format-y1wdyCcv.js} +93 -97
- package/dist/cdn/{src-CgoeSM8k.js → src-CleI0g9l.js} +3256 -3198
- package/dist/cdn/{src-DfwxB1TH.js → src-Dz625Fhx.js} +3184 -3126
- package/dist/cdn/svgrid.js +11 -11
- package/dist/cdn/svgrid.svelte-external.js +11 -11
- package/dist/cdn/validate-GEs4ZPSW.js +80 -0
- package/dist/cell-formatting.d.ts +9 -0
- package/dist/cell-formatting.js +34 -0
- package/dist/core.js +124 -21
- package/dist/export-format.d.ts +8 -0
- package/dist/export-format.js +23 -16
- package/dist/headless.d.ts +1 -1
- package/dist/headless.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/keyboard-handlers.js +5 -1
- package/dist/selection.js +14 -4
- package/dist/{subscribe.js → subscribe.svelte.js} +5 -1
- package/dist/validate.js +10 -3
- package/dist/virtualization/column-virtualizer.d.ts +1 -0
- package/dist/virtualization/svelte-virtualizer.svelte.d.ts +1 -0
- package/dist/virtualization/svelte-virtualizer.svelte.js +1 -0
- package/dist/virtualization/virtualizer.d.ts +3 -0
- package/dist/virtualization/virtualizer.js +14 -1
- package/package.json +1 -1
- package/src/SvGrid.controller.svelte.ts +45 -13
- package/src/SvGrid.css +16 -5
- package/src/SvGrid.helpers.ts +2 -4
- package/src/SvGrid.svelte +4 -1
- package/src/cell-formatting.ts +31 -0
- package/src/core.sort.test.ts +86 -0
- package/src/core.ts +114 -21
- package/src/export-dates.test.ts +114 -0
- package/src/export-format.ts +26 -14
- package/src/headless.reactivity.svelte.test.ts +89 -0
- package/src/headless.ts +1 -1
- package/src/index.ts +1 -1
- package/src/keyboard-handlers.ts +5 -1
- package/src/selection.test.ts +37 -0
- package/src/selection.ts +16 -6
- package/src/{subscribe.test.ts → subscribe.svelte.test.ts} +1 -1
- package/src/{subscribe.ts → subscribe.svelte.ts} +5 -1
- package/src/svgrid.behavior.test.ts +29 -0
- package/src/svgrid.data-push.svelte.test.ts +94 -0
- package/src/svgrid.live-update-paths.svelte.test.ts +4 -2
- package/src/validate.test.ts +16 -0
- package/src/validate.ts +10 -2
- package/src/virtualization/svelte-virtualizer.svelte.ts +1 -0
- package/src/virtualization/virtualizer.test.ts +44 -0
- package/src/virtualization/virtualizer.ts +13 -1
- package/dist/cdn/validate-AZoD8BoR.js +0 -80
- /package/dist/{subscribe.d.ts → subscribe.svelte.d.ts} +0 -0
package/README.md
CHANGED
|
@@ -180,7 +180,7 @@ The pack sells in two editions, both covering unlimited production apps.
|
|
|
180
180
|
merges, frozen panes, named ranges and charts surviving the round trip.
|
|
181
181
|
- **SvGrid Studio.** The designer, the code generator and the SQL data sources.
|
|
182
182
|
|
|
183
|
-
|
|
183
|
+
You can evaluate both editions without asking for a key: every feature runs without one, and under a
|
|
184
184
|
key that does not cover it, with a watermark and a console message about the Enterprise package. `licenseCovers('spreadsheet')` tells you which
|
|
185
185
|
side of the line the current key is on, if you would rather hide an entry point than let it nudge.
|
|
186
186
|
|
|
@@ -493,6 +493,7 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
493
493
|
readonly virtualizer: {
|
|
494
494
|
readonly version: number;
|
|
495
495
|
setOptions: (next: Partial<import("./index.js").VirtualizerOptions>) => void;
|
|
496
|
+
measure: () => void;
|
|
496
497
|
setScrollOffset: (scrollOffset: number) => void;
|
|
497
498
|
setViewportHeight: (viewportHeight: number) => void;
|
|
498
499
|
scrollToIndex: (index: number) => void;
|
|
@@ -506,6 +507,7 @@ export declare function createSvGridController<TFeatures extends TableFeatures =
|
|
|
506
507
|
setViewportWidth(viewportWidth: number): void;
|
|
507
508
|
setHorizontalOffset(scrollOffset: number): void;
|
|
508
509
|
setOptions(next: Partial<import("./index.js").VirtualizerOptions>): void;
|
|
510
|
+
measure(): void;
|
|
509
511
|
setScrollOffset(scrollOffset: number): void;
|
|
510
512
|
setViewportHeight(viewportHeight: number): void;
|
|
511
513
|
scrollToIndex(index: number): void;
|
|
@@ -625,7 +625,16 @@ export function createSvGridController(rawProps, domIdBase) {
|
|
|
625
625
|
// `data` is optional on the type (a `rowModel` may supply the rows
|
|
626
626
|
// instead), so every read falls back to empty rather than to undefined.
|
|
627
627
|
const EMPTY_DATA = [];
|
|
628
|
-
|
|
628
|
+
// Seeded as a copy, for the same reason the sync effect below makes one: the
|
|
629
|
+
// row model tells data apart by array identity, so the grid has to own an
|
|
630
|
+
// array the consumer cannot grow behind its back.
|
|
631
|
+
let internalData = $state.raw(props.data?.length ? props.data.slice() : EMPTY_DATA);
|
|
632
|
+
// What the last sync saw, so the effect can tell a replacement (drop the
|
|
633
|
+
// cell edits) from a push or splice (keep them) and skip a no-op run.
|
|
634
|
+
// svelte-ignore state_referenced_locally
|
|
635
|
+
let lastData = props.data ?? EMPTY_DATA;
|
|
636
|
+
// svelte-ignore state_referenced_locally
|
|
637
|
+
let lastDataLength = props.data?.length ?? 0;
|
|
629
638
|
// Resolve `cellDataType` / `inferColumnTypes` into concrete editorType +
|
|
630
639
|
// format defaults once, up front, so every downstream reader sees a normal
|
|
631
640
|
// column. Explicit fields on the ColumnDef always win.
|
|
@@ -666,12 +675,29 @@ export function createSvGridController(rawProps, domIdBase) {
|
|
|
666
675
|
return collapsedColumnGroups.has(groupId);
|
|
667
676
|
}
|
|
668
677
|
$effect(() => {
|
|
678
|
+
const next = props.data ?? EMPTY_DATA;
|
|
679
|
+
// Reading `length` is what subscribes this effect to a `$state` array's own
|
|
680
|
+
// length signal, so `rows.push(...)` and `rows.splice(...)` re-run it.
|
|
681
|
+
// Without this read nothing in the grid tracks the row count at all:
|
|
682
|
+
// `getRowModel` reads `.length` only inside its cache miss, and the miss is
|
|
683
|
+
// keyed on the array reference, which a mutation does not change.
|
|
684
|
+
const length = next.length;
|
|
685
|
+
const replaced = next !== lastData;
|
|
686
|
+
if (!replaced && length === lastDataLength)
|
|
687
|
+
return;
|
|
688
|
+
lastData = next;
|
|
689
|
+
lastDataLength = length;
|
|
690
|
+
// A fresh array object, because `getRowModel` memoises on identity. The
|
|
691
|
+
// elements are the same objects, so a row that did not move keeps its row
|
|
692
|
+
// object and a field write still reaches its cell through the proxy.
|
|
693
|
+
internalData = length === 0 ? EMPTY_DATA : next.slice();
|
|
669
694
|
// When the consumer replaces `data` (e.g. a "Reset" button), drop any
|
|
670
695
|
// accumulated cell-edit overrides - otherwise `getCellDisplayValue`
|
|
671
696
|
// would keep returning the old edited values from `editedCellValues`
|
|
672
|
-
// even though the underlying data has been replaced.
|
|
673
|
-
|
|
674
|
-
|
|
697
|
+
// even though the underlying data has been replaced. Growing or shrinking
|
|
698
|
+
// the array is not a reset, so it keeps them.
|
|
699
|
+
if (replaced)
|
|
700
|
+
editedCellValues = {};
|
|
675
701
|
});
|
|
676
702
|
$effect(() => {
|
|
677
703
|
internalColumns = resolveCols(props.columns);
|
|
@@ -1360,11 +1386,22 @@ export function createSvGridController(rawProps, domIdBase) {
|
|
|
1360
1386
|
return rawRows;
|
|
1361
1387
|
let rows = rawRows;
|
|
1362
1388
|
if (globalFilter.trim()) {
|
|
1363
|
-
const
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1389
|
+
const locale = props.filterLocale ?? props.localization?.locale;
|
|
1390
|
+
const needle = normalizeForFilter(globalFilter, locale);
|
|
1391
|
+
// Read the values, not the cells. `getAllCells()` built a cell object
|
|
1392
|
+
// with two closures per column on EVERY row and kept them on the row:
|
|
1393
|
+
// ten million objects for one keystroke over a million rows, and a
|
|
1394
|
+
// search that froze the page for seconds. `cell.getValue()` and
|
|
1395
|
+
// `getCellValueByColumnId` read the same per-row values array, so the
|
|
1396
|
+
// answer is the same. The columns are the ones the rows were built with.
|
|
1397
|
+
const columnIds = grid.getAllColumns().map((c) => c.id);
|
|
1398
|
+
rows = rows.filter((row) => {
|
|
1399
|
+
for (const id of columnIds) {
|
|
1400
|
+
if (normalizeForFilter(String(row.getCellValueByColumnId(id) ?? ""), locale).includes(needle))
|
|
1401
|
+
return true;
|
|
1402
|
+
}
|
|
1403
|
+
return false;
|
|
1404
|
+
});
|
|
1368
1405
|
}
|
|
1369
1406
|
rows = applyColumnFilters(rows);
|
|
1370
1407
|
// --- Advanced filter (Pro) ---------------------------------------------
|
package/dist/SvGrid.css
CHANGED
|
@@ -1387,9 +1387,6 @@ select.sv-grid-fr-editor {
|
|
|
1387
1387
|
.sv-grid-cell-active,
|
|
1388
1388
|
.sv-grid-cell-editing {
|
|
1389
1389
|
position: relative;
|
|
1390
|
-
/* High enough to sit above pinned-column stacking contexts (z=4) so the
|
|
1391
|
-
list/chips popover overlays adjacent cells instead of being clipped. */
|
|
1392
|
-
z-index: 20;
|
|
1393
1390
|
/* `box-shadow: inset` is bound to the cell's own box, so the ring
|
|
1394
1391
|
clips cleanly with the cell when it's partially scrolled out of
|
|
1395
1392
|
view (and shows up consistently at the right edge of a virtualized
|
|
@@ -1399,10 +1396,24 @@ select.sv-grid-fr-editor {
|
|
|
1399
1396
|
inconsistent at scroll boundaries. */
|
|
1400
1397
|
box-shadow: inset 0 0 0 2px var(--sg-accent, #0b63f3);
|
|
1401
1398
|
outline: none;
|
|
1402
|
-
|
|
1403
|
-
|
|
1399
|
+
}
|
|
1400
|
+
/* Only the EDITING cell escapes its own box and outranks the pinned-column
|
|
1401
|
+
stacking contexts (z=4), so its list/chips popout overlays the neighbours
|
|
1402
|
+
instead of being clipped. The merely-ACTIVE cell used to get the same
|
|
1403
|
+
treatment, and on a grid scrolled sideways that made it paint straight over
|
|
1404
|
+
the sticky selection / row-number column: the checkbox disappeared and the
|
|
1405
|
+
cell's text - unclipped, because overflow was visible - spilled across it.
|
|
1406
|
+
A grid seeds its active cell at (0,0), so this hit the FIRST row of any
|
|
1407
|
+
horizontally scrolled grid with `showRowSelection`, untouched by the user. */
|
|
1408
|
+
.sv-grid-cell-editing {
|
|
1409
|
+
z-index: 20;
|
|
1404
1410
|
overflow: visible;
|
|
1405
1411
|
}
|
|
1412
|
+
/* Above ordinary cells so the ring is not overdrawn by a neighbour, below the
|
|
1413
|
+
sticky columns (z=4) so those keep covering it as they should. */
|
|
1414
|
+
.sv-grid-cell-active:not(.sv-grid-cell-editing) {
|
|
1415
|
+
z-index: 3;
|
|
1416
|
+
}
|
|
1406
1417
|
/* The active cell a grid mounts with is seeded at (0,0), not chosen: no
|
|
1407
1418
|
ring until a click, an arrow key or the api activates a cell (the same
|
|
1408
1419
|
gate the fill handle has always had). Once activated it stays through a
|
package/dist/SvGrid.helpers.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { parseDateValue } from "./cell-formatting.js";
|
|
1
2
|
export function cfTextStyle(cf) {
|
|
2
3
|
let s = "";
|
|
3
4
|
if (cf.color)
|
|
@@ -233,10 +234,7 @@ export function getEditorClass(editorType) {
|
|
|
233
234
|
return "sv-grid-cell-editor";
|
|
234
235
|
}
|
|
235
236
|
export function asDate(value) {
|
|
236
|
-
|
|
237
|
-
return null;
|
|
238
|
-
const parsed = value instanceof Date ? value : new Date(value);
|
|
239
|
-
return Number.isNaN(parsed.getTime()) ? null : parsed;
|
|
237
|
+
return parseDateValue(value);
|
|
240
238
|
}
|
|
241
239
|
export function clampMenuX(x, width) {
|
|
242
240
|
return Math.max(8, Math.min(x, window.innerWidth - width - 8));
|
package/dist/SvGrid.svelte
CHANGED
|
@@ -1212,7 +1212,10 @@
|
|
|
1212
1212
|
column: Column<TData>,
|
|
1213
1213
|
cellValue: unknown,
|
|
1214
1214
|
)}
|
|
1215
|
-
|
|
1215
|
+
<!-- A column's own `cell` renderer wins over every built-in display, the
|
|
1216
|
+
checkbox included: a boolean field drawn as a flag button or a status
|
|
1217
|
+
pill used to come out as a read-only checkbox, with `cell` never called. -->
|
|
1218
|
+
{#if (column.columnDef.editorType === "checkbox" || typeof cellValue === "boolean") && column.columnDef.cell == null}
|
|
1216
1219
|
<div
|
|
1217
1220
|
class="sv-grid-checkbox sv-grid-checkbox-readonly"
|
|
1218
1221
|
role="checkbox"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { $a as e, Fn as t, Qa as n } from "./src-
|
|
2
|
-
import { S as r, _ as i, j as a, k as o } from "./editor-registry-
|
|
1
|
+
import { $a as e, Fn as t, Qa as n } from "./src-Dz625Fhx.js";
|
|
2
|
+
import { S as r, _ as i, j as a, k as o } from "./editor-registry-BVeHvlZR.js";
|
|
3
3
|
import { r as s } from "./dismissable-Brc4EZU1.js";
|
|
4
4
|
import * as c from "svelte/internal/client";
|
|
5
5
|
import "svelte/internal/disclose-version";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { $a as e, Fn as t, Qa as n } from "./src-
|
|
1
|
+
import { $a as e, Fn as t, Qa as n } from "./src-CleI0g9l.js";
|
|
2
2
|
import { $ as r, D as i, E as a, F as o, G as s, H as c, I as l, L as u, N as d, Q as f, R as p, U as m, V as h, X as g, Y as _, Z as v, _ as y, at as b, b as x, d as S, et as C, f as w, ft as T, g as E, h as D, it as O, j as k, k as A, lt as ee, m as j, mt as te, nt as M, o as ne, pt as N, st as P, t as re, tt as F, u as I, ut as L, v as R, w as ie } from "./disclose-version-Dr7rEVv-.js";
|
|
3
|
-
import { S as ae, _ as oe, j as se, k as ce } from "./editor-registry-
|
|
3
|
+
import { S as ae, _ as oe, j as se, k as ce } from "./editor-registry-BVeHvlZR.js";
|
|
4
4
|
import { r as le } from "./dismissable-Brc4EZU1.js";
|
|
5
5
|
//#region src/GridMenus.svelte
|
|
6
6
|
var ue = u("<option> </option>"), de = u("<input class=\"sv-grid-menu-condition-value\" placeholder=\"To\"/>"), fe = u("<input class=\"sv-grid-menu-condition-value\"/> <!>", 1), pe = u("<option> </option>"), me = u("<input class=\"sv-grid-menu-condition-value\" placeholder=\"To\"/>"), he = u("<input class=\"sv-grid-menu-condition-value\"/> <!>", 1), ge = u("<div class=\"sv-grid-menu-join\" role=\"radiogroup\" aria-label=\"Combine conditions\"><button type=\"button\">AND</button> <button type=\"button\">OR</button> <button type=\"button\" class=\"sv-grid-menu-join-x\" title=\"Remove second condition\" aria-label=\"Remove second condition\"><!></button></div> <select class=\"sv-grid-menu-operator-select\" aria-label=\"Second filter condition\"></select> <!>", 1), _e = u("<button type=\"button\" class=\"sv-grid-menu-add-cond\">+ Add condition</button>"), ve = u("<!> <!>", 1), ye = u("<span class=\"sv-grid-menu-head-note\">and the condition above</span>"), be = u("<span class=\"sv-grid-menu-head-note\"> </span>"), xe = u("<div class=\"sv-grid-facet-empty\">No values</div>"), Se = u("<div class=\"sv-grid-facet-note\"> </div>"), Ce = u("<div class=\"sv-grid-menu-filter\"><div class=\"sv-grid-menu-filter-head\"><span class=\"sv-grid-header-icon\"><!></span> Filter\n condition</div> <select class=\"sv-grid-menu-operator-select\" aria-label=\"Filter condition\"></select> <!> <div class=\"sv-grid-menu-sep\"></div> <div class=\"sv-grid-menu-filter-head\">Values <!></div> <span class=\"sv-grid-menu-search-wrap\"><!> <input class=\"sv-grid-menu-search\" placeholder=\"Search values...\"/></span> <label class=\"sv-grid-facet sv-grid-facet-all\"><input type=\"checkbox\"/> <span class=\"sv-grid-facet-label\"> </span></label> <!> <!> <div class=\"sv-grid-menu-actions\"><button type=\"button\" class=\"sv-grid-menu-btn\">Clear filter</button> <button type=\"button\" class=\"sv-grid-menu-btn sv-grid-menu-btn-primary\">Done</button></div></div>"), we = u("<div role=\"tooltip\"> </div>"), Te = u("<div class=\"sv-grid-menu-backdrop\" role=\"presentation\"></div>"), Ee = u("<button type=\"button\" role=\"tab\">Filter</button>"), De = u("<div class=\"sv-grid-menu-tabs\" role=\"tablist\"><button type=\"button\" role=\"tab\">General</button> <!> <button type=\"button\" role=\"tab\">Columns</button></div>"), Oe = u("<div class=\"sv-grid-menu-filter-head\">Visible columns</div> <!>", 1), ke = u("<button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Sort\n ascending</button> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Sort\n descending</button> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Remove sort</button>", 1), Ae = u("<div class=\"sv-grid-menu-sep\"></div> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Pin to left</button> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Pin to right</button> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Unpin column</button>", 1), je = u("<button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Autosize\n this column</button>"), Me = u("<div class=\"sv-grid-menu-sep\"></div> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Group\n by this column</button> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Remove grouping</button>", 1), z = u("<button type=\"button\" role=\"menuitem\" aria-haspopup=\"menu\"><span class=\"sv-grid-header-icon\"><!></span> Choose columns <span class=\"sv-grid-header-icon sv-grid-menu-item-chevron\"><!></span></button>"), B = u("<!> <!> <div class=\"sv-grid-menu-sep\"></div> <!> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Autosize\n all columns</button> <!> <div class=\"sv-grid-menu-sep\"></div> <!> <button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><span class=\"sv-grid-header-icon\"><!></span> Reset columns</button>", 1), Ne = u("<div class=\"sv-grid-menu sv-grid-column-menu\" role=\"menu\"><!> <!></div>"), Pe = u("<div class=\"sv-grid-menu sv-grid-filter-menu\" role=\"menu\" tabindex=\"-1\"><!></div>"), Fe = u("<div class=\"sv-grid-menu sv-grid-choose-columns-menu\" role=\"menu\"><div class=\"sv-grid-menu-filter-head\">Visible columns</div> <!></div>"), Ie = u("<button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitemradio\"><span class=\"sv-grid-header-icon\"><!></span> </button>"), Le = u("<div class=\"sv-grid-menu sv-grid-operator-menu\" role=\"menu\"></div>"), Re = u("<div class=\"sv-grid-facet-empty\">No values</div>"), ze = u("<div class=\"sv-grid-menu sv-grid-in-suggest\"><!></div>"), Be = u("<div class=\"sv-grid-menu-sep\"></div>"), V = p("<path></path>"), Ve = p("<svg class=\"sv-grid-menu-icon-own\" width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.4\" stroke-linecap=\"round\" stroke-linejoin=\"round\" focusable=\"false\"></svg>"), He = u("<span class=\"sv-grid-menu-icon\" aria-hidden=\"true\"><!></span>"), Ue = u("<button type=\"button\" class=\"sv-grid-menu-item\" role=\"menuitem\"><!><span class=\"sv-grid-menu-label\"> </span></button>"), We = u("<div class=\"sv-grid-menu-backdrop\" role=\"presentation\"></div> <div class=\"sv-grid-menu sv-grid-context-menu\" role=\"menu\"></div>", 1), Ge = u("<div class=\"sv-grid-menu-backdrop\" role=\"presentation\"></div> <div class=\"sv-grid-menu sv-grid-comment-editor\" role=\"dialog\" aria-label=\"Edit comment\"><textarea class=\"sv-grid-comment-textarea\" rows=\"3\" placeholder=\"Add a comment…\"></textarea> <div class=\"sv-grid-comment-actions\"><button type=\"button\" class=\"sv-grid-comment-remove\">Remove</button> <span class=\"sv-grid-comment-spacer\"></span> <button type=\"button\" class=\"sv-grid-comment-cancel\">Cancel</button> <button type=\"button\" class=\"sv-grid-comment-save\">Save</button></div></div>", 1), Ke = u("<!> <!> <!> <!> <!> <!> <!> <!> <!>", 1);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as e, O as t, S as n, T as r, b as i, n as a, o, p as s, r as c, v as l, x as u } from "./editor-registry-
|
|
1
|
+
import { A as e, O as t, S as n, T as r, b as i, n as a, o, p as s, r as c, v as l, x as u } from "./editor-registry-BVeHvlZR.js";
|
|
2
2
|
import * as d from "svelte/internal/client";
|
|
3
3
|
import "svelte/internal/disclose-version";
|
|
4
4
|
//#region src/SvGridCellEditor.svelte
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { E as e, F as t, G as n, H as r, I as i, L as a, N as o, Q as s, U as c, V as l, X as u, Y as d, at as f, b as p, d as m, et as h, f as g, g as _, h as v, it as y, j as b, k as x, lt as ee, m as S, mt as C, nt as w, pt as T, r as te, st as E, t as D, tt as O, u as k, ut as ne, v as A, w as j, y as re } from "./disclose-version-Dr7rEVv-.js";
|
|
2
|
-
import { A as ie, O as ae, S as oe, T as se, b as ce, n as le, o as ue, p as de, r as fe, v as M, x as N } from "./editor-registry-
|
|
2
|
+
import { A as ie, O as ae, S as oe, T as se, b as ce, n as le, o as ue, p as de, r as fe, v as M, x as N } from "./editor-registry-BVeHvlZR.js";
|
|
3
3
|
//#region src/SvGridCellEditor.svelte
|
|
4
4
|
var P = a("<span class=\"sv-grid-chip sv-grid-chip-removable\"> <button type=\"button\" class=\"sv-grid-chip-remove\">×</button></span>"), F = a("<button type=\"button\" class=\"sv-grid-chip-commit\" aria-label=\"Commit chip selection\">Done</button>"), I = a("<div class=\"sv-grid-cell-editor sv-grid-cell-editor-chips\" role=\"group\"><div class=\"sv-grid-chips-row\"><!> <input class=\"sv-grid-chip-input\" type=\"text\"/> <!></div></div>"), L = a("<input type=\"checkbox\" class=\"sv-grid-fr-editor sv-grid-fr-checkbox\"/>"), R = a("<option> </option>"), z = a("<select class=\"sv-grid-cell-editor sv-grid-fr-editor\"></select>"), B = a("<input class=\"sv-grid-cell-editor sv-grid-fr-editor\"/>"), pe = a("<button type=\"button\" class=\"sv-grid-checkbox\" role=\"checkbox\" aria-label=\"Edit checkbox value\"></button>"), me = a("<button type=\"button\" role=\"radio\">★</button>"), he = a("<span class=\"sv-grid-rating-editor\" role=\"radiogroup\" aria-label=\"Rating\"><!> <button type=\"button\" aria-label=\"Clear rating\" class=\"sv-grid-rating-clear\">×</button></span>"), ge = a("<textarea class=\"sv-grid-cell-editor sv-grid-cell-editor-textarea\" rows=\"4\"></textarea>"), _e = a("<button type=\"button\" class=\"sv-grid-autocomplete-option\" role=\"option\"> </button>"), ve = a("<div class=\"sv-grid-autocomplete-list\" role=\"listbox\"></div>"), ye = a("<div class=\"sv-grid-autocomplete\"><input class=\"sv-grid-cell-editor sv-grid-cell-editor-autocomplete\" type=\"text\"/> <!></div>"), be = a("<input type=\"color\"/>"), xe = a("<textarea class=\"sv-grid-cell-editor sv-grid-cell-editor-text sv-grid-cell-editor-multiline\"></textarea>"), Se = a("<input/>");
|
|
5
5
|
function V(a, l) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { a as e } from "./editor-contract-LXgQJAgd.js";
|
|
2
|
-
import { i as t } from "./chart-trend-
|
|
3
|
-
import { C as n, D as r, E as i, H as a, O as o, T as s, X as c, c as l, et as u, g as d, gt as f, ht as ee, i as te, mt as ne, o as re, r as ie, w as ae } from "./chart-
|
|
2
|
+
import { i as t } from "./chart-trend-C1aOAPBZ.js";
|
|
3
|
+
import { C as n, D as r, E as i, H as a, O as o, T as s, X as c, c as l, et as u, g as d, gt as f, ht as ee, i as te, mt as ne, o as re, r as ie, w as ae } from "./chart-By7h2Guv.js";
|
|
4
4
|
import { a as oe, t as se } from "./chart-export-BXqueeWJ.js";
|
|
5
5
|
import * as p from "svelte/internal/client";
|
|
6
6
|
import "svelte/internal/disclose-version";
|
|
@@ -326,7 +326,7 @@ function Ar(e, i) {
|
|
|
326
326
|
return;
|
|
327
327
|
}
|
|
328
328
|
let e = p.get(I), t = !0;
|
|
329
|
-
return import("./chart-summary-
|
|
329
|
+
return import("./chart-summary-BDtrNEiA.js").then((e) => e.n).then(({ chartSummary: n }) => {
|
|
330
330
|
t && p.set(zr, n(e), !0);
|
|
331
331
|
}), () => {
|
|
332
332
|
t = !1;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { B as e, D as t, E as n, F as r, G as i, H as a, I as o, J as s, K as c, L as l, N as u, R as d, U as f, V as p, X as m, Y as h, _ as g, a as _, at as v, b as ee, d as y, et as b, ft as te, i as ne, it as x, j as re, k as S, lt as ie, nt as C, o as ae, pt as w, q as oe, rt as se, st as T, t as E, tt as D, u as ce, ut as le, v as O, w as ue, x as de } from "./disclose-version-Dr7rEVv-.js";
|
|
2
2
|
import { a as fe } from "./editor-contract-LXgQJAgd.js";
|
|
3
|
-
import { i as pe } from "./chart-trend-
|
|
4
|
-
import { C as me, D as he, E as ge, H as _e, O as ve, T as ye, X as be, c as xe, et as Se, g as Ce, gt as we, ht as Te, i as Ee, mt as De, o as Oe, r as ke, w as Ae } from "./chart-
|
|
3
|
+
import { i as pe } from "./chart-trend-C1aOAPBZ.js";
|
|
4
|
+
import { C as me, D as he, E as ge, H as _e, O as ve, T as ye, X as be, c as xe, et as Se, g as Ce, gt as we, ht as Te, i as Ee, mt as De, o as Oe, r as ke, w as Ae } from "./chart-By7h2Guv.js";
|
|
5
5
|
import { a as je, t as Me } from "./chart-export-BXqueeWJ.js";
|
|
6
6
|
//#region src/chart-zoom.ts
|
|
7
7
|
function Ne(e, t, n) {
|
|
@@ -324,7 +324,7 @@ function ti(l, d) {
|
|
|
324
324
|
return;
|
|
325
325
|
}
|
|
326
326
|
let e = i(V), t = !0;
|
|
327
|
-
return import("./chart-summary-
|
|
327
|
+
return import("./chart-summary-BDtrNEiA.js").then((e) => e.n).then(({ chartSummary: n }) => {
|
|
328
328
|
t && x(si, n(e), !0);
|
|
329
329
|
}), () => {
|
|
330
330
|
t = !1;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { n as e, t } from "./SvModal-ClxGmpAc.js";
|
|
2
|
-
import { _ as n, h as r, l as i, m as a, p as o, u as s, v as c, y as l } from "./chart-
|
|
3
|
-
import { t as u } from "./SvGridChart-
|
|
4
|
-
import { i as d, t as f } from "./chart-panel-messages-
|
|
2
|
+
import { _ as n, h as r, l as i, m as a, p as o, u as s, v as c, y as l } from "./chart-By7h2Guv.js";
|
|
3
|
+
import { t as u } from "./SvGridChart-DMUOFxOe.js";
|
|
4
|
+
import { i as d, t as f } from "./chart-panel-messages-DUaXr-sb.js";
|
|
5
5
|
import * as p from "svelte/internal/client";
|
|
6
6
|
import "svelte/internal/disclose-version";
|
|
7
7
|
//#region src/chart-samples.ts
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { E as e, F as t, G as n, H as r, I as i, L as a, N as o, V as s, Y as c, at as l, d as u, et as d, f, g as p, h as m, it as h, k as g, lt as _, m as v, mt as y, nt as b, pt as x, st as S, t as C, tt as w, u as T, ut as E, v as D, x as O } from "./disclose-version-Dr7rEVv-.js";
|
|
2
2
|
import { n as k, t as A } from "./SvModal-DhB_VMFR.js";
|
|
3
|
-
import { _ as j, h as M, l as N, m as P, p as F, u as I, v as L, y as R } from "./chart-
|
|
4
|
-
import { t as z } from "./SvGridChart-
|
|
5
|
-
import { i as B, t as V } from "./chart-panel-messages-
|
|
3
|
+
import { _ as j, h as M, l as N, m as P, p as F, u as I, v as L, y as R } from "./chart-By7h2Guv.js";
|
|
4
|
+
import { t as z } from "./SvGridChart-N7ik0oWy.js";
|
|
5
|
+
import { i as B, t as V } from "./chart-panel-messages-BC-tOgFY.js";
|
|
6
6
|
//#region src/chart-samples.ts
|
|
7
7
|
var H = null;
|
|
8
8
|
function U() {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
|
|
2
2
|
import { B as t, C as n, E as r, F as i, G as a, H as o, I as s, L as c, N as l, R as u, U as d, V as f, X as p, Y as m, _ as h, a as g, at as _, d as v, et as y, i as b, it as x, k as S, lt as ee, n as C, nt as w, o as T, pt as E, r as D, st as O, t as k, tt as A, u as te, ut as j, v as M, w as ne, x as N } from "./disclose-version-Dr7rEVv-.js";
|
|
3
|
-
import { z as P } from "./chart-
|
|
4
|
-
import { t as re } from "./SvGridChart-
|
|
3
|
+
import { z as P } from "./chart-By7h2Guv.js";
|
|
4
|
+
import { t as re } from "./SvGridChart-N7ik0oWy.js";
|
|
5
5
|
import { a as ie, o as ae, r as oe, s as se, t as ce } from "./chart-export-BXqueeWJ.js";
|
|
6
|
-
import { a as le, i as ue, r as de, t as fe } from "./chart-panel-messages-
|
|
6
|
+
import { a as le, i as ue, r as de, t as fe } from "./chart-panel-messages-BC-tOgFY.js";
|
|
7
7
|
//#region ../../node_modules/.pnpm/svelte@5.55.9_@typescript-eslint+types@8.67.0/node_modules/svelte/src/transition/index.js
|
|
8
8
|
function pe(e) {
|
|
9
9
|
let t = e - 1;
|
|
@@ -159,7 +159,7 @@ function L(e, c) {
|
|
|
159
159
|
x(f, !0);
|
|
160
160
|
return;
|
|
161
161
|
}
|
|
162
|
-
import("./SvGridChartBuilder-
|
|
162
|
+
import("./SvGridChartBuilder-Ca7gF8ZK.js").then((e) => {
|
|
163
163
|
x(u, e.default, !0), x(f, !0);
|
|
164
164
|
});
|
|
165
165
|
}
|
|
@@ -278,7 +278,7 @@ function L(e, c) {
|
|
|
278
278
|
});
|
|
279
279
|
async function _t() {
|
|
280
280
|
if (x(H, !1), !a(L)) return;
|
|
281
|
-
let { chartSummary: e } = await import("./chart-summary-
|
|
281
|
+
let { chartSummary: e } = await import("./chart-summary-BDtrNEiA.js").then((e) => e.n), t = e(a(L));
|
|
282
282
|
try {
|
|
283
283
|
await navigator.clipboard?.writeText(t);
|
|
284
284
|
} catch {}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
|
|
2
|
-
import { z as t } from "./chart-
|
|
3
|
-
import { t as n } from "./SvGridChart-
|
|
2
|
+
import { z as t } from "./chart-By7h2Guv.js";
|
|
3
|
+
import { t as n } from "./SvGridChart-DMUOFxOe.js";
|
|
4
4
|
import { a as r, o as i, r as a, s as o, t as s } from "./chart-export-BXqueeWJ.js";
|
|
5
|
-
import { a as c, i as l, r as u, t as d } from "./chart-panel-messages-
|
|
5
|
+
import { a as c, i as l, r as u, t as d } from "./chart-panel-messages-DUaXr-sb.js";
|
|
6
6
|
import * as f from "svelte/internal/client";
|
|
7
7
|
import "svelte/internal/disclose-version";
|
|
8
8
|
import { fly as p } from "svelte/transition";
|
|
@@ -135,7 +135,7 @@ function y(e, t) {
|
|
|
135
135
|
f.set(g, !0);
|
|
136
136
|
return;
|
|
137
137
|
}
|
|
138
|
-
import("./SvGridChartBuilder-
|
|
138
|
+
import("./SvGridChartBuilder-CB_Jnm2k.js").then((e) => {
|
|
139
139
|
f.set(h, e.default, !0), f.set(g, !0);
|
|
140
140
|
});
|
|
141
141
|
}
|
|
@@ -254,7 +254,7 @@ function y(e, t) {
|
|
|
254
254
|
});
|
|
255
255
|
async function Je() {
|
|
256
256
|
if (f.set(N, !1), !f.get(T)) return;
|
|
257
|
-
let { chartSummary: e } = await import("./chart-summary-
|
|
257
|
+
let { chartSummary: e } = await import("./chart-summary-BDtrNEiA.js").then((e) => e.n), t = e(f.get(T));
|
|
258
258
|
try {
|
|
259
259
|
await navigator.clipboard?.writeText(t);
|
|
260
260
|
} catch {}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { u as e } from "./chart-
|
|
2
|
-
import { t } from "./SvGridChart-
|
|
1
|
+
import { u as e } from "./chart-By7h2Guv.js";
|
|
2
|
+
import { t } from "./SvGridChart-DMUOFxOe.js";
|
|
3
3
|
import * as n from "svelte/internal/client";
|
|
4
4
|
import "svelte/internal/disclose-version";
|
|
5
5
|
//#region src/SvGridChartView.svelte
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { F as e, G as t, L as n, et as r, lt as i, pt as a, st as o, ut as s, x as c } from "./disclose-version-Dr7rEVv-.js";
|
|
2
|
-
import { u as l } from "./chart-
|
|
3
|
-
import { t as u } from "./SvGridChart-
|
|
2
|
+
import { u as l } from "./chart-By7h2Guv.js";
|
|
3
|
+
import { t as u } from "./SvGridChart-N7ik0oWy.js";
|
|
4
4
|
//#region src/SvGridChartView.svelte
|
|
5
5
|
var d = n("<div class=\"sv-grid-chart-view svelte-10run6t\"><!></div>"), f = {
|
|
6
6
|
hash: "svelte-10run6t",
|
|
@@ -57,12 +57,34 @@ function n(e, n) {
|
|
|
57
57
|
let r = (Array.isArray(e) ? e.join(",") : e ?? "") + "|" + (n.style ?? "") + "|" + (n.currency ?? "") + "|" + (n.minimumFractionDigits ?? "") + "|" + (n.maximumFractionDigits ?? "") + "|" + (n.useGrouping ?? "") + "|" + (n.currencyDisplay ?? "") + "|" + (n.notation ?? "") + "|" + (n.signDisplay ?? "") + "|" + (n.minimumIntegerDigits ?? "") + "|" + (n.compactDisplay ?? "") + "|" + (n.unit ?? "") + "|" + (n.unitDisplay ?? "") + "|" + (n.minimumSignificantDigits ?? "") + "|" + (n.maximumSignificantDigits ?? ""), i = t.get(r);
|
|
58
58
|
return i || (i = new Intl.NumberFormat(e, n), t.set(r, i)), i;
|
|
59
59
|
}
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
60
|
+
function r(e) {
|
|
61
|
+
if (e instanceof Date) return Number.isNaN(e.getTime()) ? null : e;
|
|
62
|
+
if (typeof e == "number") {
|
|
63
|
+
if (!Number.isFinite(e)) return null;
|
|
64
|
+
let t = new Date(e);
|
|
65
|
+
return Number.isNaN(t.getTime()) ? null : t;
|
|
66
|
+
}
|
|
67
|
+
if (typeof e != "string") return null;
|
|
68
|
+
let t = e.trim();
|
|
69
|
+
if (t === "") return null;
|
|
70
|
+
let n = /^(\d{4})-(\d{2})-(\d{2})$/.exec(t);
|
|
71
|
+
if (n) {
|
|
72
|
+
let [e, t, r] = [
|
|
73
|
+
Number(n[1]),
|
|
74
|
+
Number(n[2]) - 1,
|
|
75
|
+
Number(n[3])
|
|
76
|
+
], i = /* @__PURE__ */ new Date(0);
|
|
77
|
+
return i.setFullYear(e, t, r), i.setHours(0, 0, 0, 0), i.getMonth() === t && i.getDate() === r ? i : null;
|
|
78
|
+
}
|
|
79
|
+
let r = new Date(t);
|
|
80
|
+
return Number.isNaN(r.getTime()) ? null : r;
|
|
64
81
|
}
|
|
82
|
+
var i = /* @__PURE__ */ new Map();
|
|
65
83
|
function a(e, t) {
|
|
84
|
+
let n = (Array.isArray(e) ? e.join(",") : e ?? "") + "|" + (t.dateStyle ?? "") + "|" + (t.timeStyle ?? "") + "|" + (t.year ?? "") + "|" + (t.month ?? "") + "|" + (t.day ?? "") + "|" + (t.hour ?? "") + "|" + (t.minute ?? "") + "|" + (t.second ?? "") + "|" + (t.weekday ?? "") + "|" + (t.hour12 ?? ""), r = i.get(n);
|
|
85
|
+
return r || (r = new Intl.DateTimeFormat(e, t), i.set(n, r)), r;
|
|
86
|
+
}
|
|
87
|
+
function o(e, t) {
|
|
66
88
|
let r = typeof e == "number" ? e : Number(e);
|
|
67
89
|
if (!Number.isFinite(r)) return String(e ?? "");
|
|
68
90
|
let i = t.locales;
|
|
@@ -83,4 +105,4 @@ function a(e, t) {
|
|
|
83
105
|
return n(i, t.options ?? {}).format(r);
|
|
84
106
|
}
|
|
85
107
|
//#endregion
|
|
86
|
-
export { e as
|
|
108
|
+
export { e as a, r as i, a as n, n as r, o as t };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { E as e, F as t, G as n, H as r, L as i, N as a, V as o, Y as s, d as c, et as l, f as u, g as d, h as f, k as p, lt as m, m as h, nt as g, pt as _, st as v, t as y, tt as b, u as x, ut as S, v as ee } from "./disclose-version-Dr7rEVv-.js";
|
|
2
2
|
import { a as C } from "./editor-contract-LXgQJAgd.js";
|
|
3
|
-
import { b as te } from "./chart-
|
|
3
|
+
import { b as te } from "./chart-By7h2Guv.js";
|
|
4
4
|
//#region src/SvGridChartPickers.svelte
|
|
5
5
|
var w = [
|
|
6
6
|
{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as e } from "./editor-contract-LXgQJAgd.js";
|
|
2
|
-
import { b as t } from "./chart-
|
|
2
|
+
import { b as t } from "./chart-By7h2Guv.js";
|
|
3
3
|
import * as n from "svelte/internal/client";
|
|
4
4
|
import "svelte/internal/disclose-version";
|
|
5
5
|
//#region src/SvGridChartPickers.svelte
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
|
|
2
|
-
import { i as t, n, t as r } from "./chart-trend-
|
|
2
|
+
import { i as t, n, t as r } from "./chart-trend-C1aOAPBZ.js";
|
|
3
3
|
//#region src/chart-summary.ts
|
|
4
4
|
var i = /* @__PURE__ */ e({ chartSummary: () => d }), a = (e) => typeof e == "number" && Number.isFinite(e);
|
|
5
5
|
function o(e) {
|