persian-data-grid 0.5.0 → 0.6.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.
- package/OFL.txt +93 -0
- package/README.md +179 -22
- package/dist/ERPTableGroupRow-J5Z2LRC5.cjs +131 -0
- package/dist/ERPTableGroupRow-J5Z2LRC5.cjs.map +1 -0
- package/dist/ERPTableGroupRow-PSAPAHGL.js +125 -0
- package/dist/ERPTableGroupRow-PSAPAHGL.js.map +1 -0
- package/dist/GridPlugin-CJCaYnlw.d.ts +57 -0
- package/dist/GridPlugin-oxhq8AsM.d.cts +57 -0
- package/dist/GridPresenceService-GEH6535Q.js +3 -0
- package/dist/GridPresenceService-GEH6535Q.js.map +1 -0
- package/dist/GridPresenceService-RDN5FXHQ.cjs +12 -0
- package/dist/GridPresenceService-RDN5FXHQ.cjs.map +1 -0
- package/dist/GridSession-B-9lLcoB.d.cts +2492 -0
- package/dist/GridSession-Bc7UIawO.d.ts +2492 -0
- package/dist/GridSyncService-KTLB4KP3.js +3 -0
- package/dist/GridSyncService-KTLB4KP3.js.map +1 -0
- package/dist/GridSyncService-TAPAHABV.cjs +12 -0
- package/dist/GridSyncService-TAPAHABV.cjs.map +1 -0
- package/dist/PdfRenderer-1HFh6UeR.d.ts +22 -0
- package/dist/PdfRenderer-CBg7hWNS.d.cts +22 -0
- package/dist/RemoteApi-CCQxiSf1.d.cts +28 -0
- package/dist/RemoteApi-CCQxiSf1.d.ts +28 -0
- package/dist/SelectImpl-NM4O4IGW.js +447 -0
- package/dist/SelectImpl-NM4O4IGW.js.map +1 -0
- package/dist/SelectImpl-W2EI4T7O.cjs +453 -0
- package/dist/SelectImpl-W2EI4T7O.cjs.map +1 -0
- package/dist/UITableController-Cuwq481K.d.cts +632 -0
- package/dist/UITableController-DU8RopUM.d.ts +632 -0
- package/dist/VazirmatnPdfRenderer-BCMpC1zy.d.cts +96 -0
- package/dist/VazirmatnPdfRenderer-Dz_G-m3c.d.ts +96 -0
- package/dist/adapters/arian-erp.cjs +77 -0
- package/dist/adapters/arian-erp.cjs.map +1 -0
- package/dist/adapters/arian-erp.d.cts +60 -0
- package/dist/adapters/arian-erp.d.ts +60 -0
- package/dist/adapters/arian-erp.js +71 -0
- package/dist/adapters/arian-erp.js.map +1 -0
- package/dist/appendAtEnd-RHIQRG2W.cjs +35 -0
- package/dist/appendAtEnd-RHIQRG2W.cjs.map +1 -0
- package/dist/appendAtEnd-TJEABLGD.js +33 -0
- package/dist/appendAtEnd-TJEABLGD.js.map +1 -0
- package/dist/applyImportedRows-BO6yxoAN.d.cts +135 -0
- package/dist/applyImportedRows-D4zVY8uD.d.ts +135 -0
- package/dist/applyRowVisibilityHandler-KS6TMCBN.js +83 -0
- package/dist/applyRowVisibilityHandler-KS6TMCBN.js.map +1 -0
- package/dist/applyRowVisibilityHandler-LXCOGESZ.cjs +85 -0
- package/dist/applyRowVisibilityHandler-LXCOGESZ.cjs.map +1 -0
- package/dist/broadcastChannelTransport-FHUMV76O.cjs +12 -0
- package/dist/broadcastChannelTransport-FHUMV76O.cjs.map +1 -0
- package/dist/broadcastChannelTransport-MIH53VNZ.js +3 -0
- package/dist/broadcastChannelTransport-MIH53VNZ.js.map +1 -0
- package/dist/callbackRemoteApi-BlXO5NJz.d.ts +30 -0
- package/dist/callbackRemoteApi-DgnXH-i0.d.cts +30 -0
- package/dist/cellRenderContext-DB7V_mlu.d.ts +42 -0
- package/dist/cellRenderContext-DG5BOlxK.d.cts +42 -0
- package/dist/chunk-2BJCRYOS.cjs +936 -0
- package/dist/chunk-2BJCRYOS.cjs.map +1 -0
- package/dist/chunk-3Y3KKGEC.js +3 -0
- package/dist/chunk-3Y3KKGEC.js.map +1 -0
- package/dist/chunk-5ALMNLUR.cjs +1408 -0
- package/dist/chunk-5ALMNLUR.cjs.map +1 -0
- package/dist/chunk-5HKVMPBD.js +937 -0
- package/dist/chunk-5HKVMPBD.js.map +1 -0
- package/dist/chunk-633KP74Z.js +189 -0
- package/dist/chunk-633KP74Z.js.map +1 -0
- package/dist/chunk-6XBXZPBW.js +298 -0
- package/dist/chunk-6XBXZPBW.js.map +1 -0
- package/dist/chunk-77UXAJII.js +112 -0
- package/dist/chunk-77UXAJII.js.map +1 -0
- package/dist/chunk-ASPTRYRD.cjs +21 -0
- package/dist/chunk-ASPTRYRD.cjs.map +1 -0
- package/dist/chunk-AU3RDJYQ.js +243 -0
- package/dist/chunk-AU3RDJYQ.js.map +1 -0
- package/dist/chunk-BHDRUZH5.cjs +33 -0
- package/dist/chunk-BHDRUZH5.cjs.map +1 -0
- package/dist/chunk-BLYVOV3G.cjs +191 -0
- package/dist/chunk-BLYVOV3G.cjs.map +1 -0
- package/dist/chunk-CILNIWYW.cjs +100 -0
- package/dist/chunk-CILNIWYW.cjs.map +1 -0
- package/dist/chunk-DFFP7SJ6.cjs +257 -0
- package/dist/chunk-DFFP7SJ6.cjs.map +1 -0
- package/dist/chunk-DXRCYW42.cjs +568 -0
- package/dist/chunk-DXRCYW42.cjs.map +1 -0
- package/dist/chunk-EBV6HGZB.cjs +33 -0
- package/dist/chunk-EBV6HGZB.cjs.map +1 -0
- package/dist/chunk-EHHHC5JV.js +832 -0
- package/dist/chunk-EHHHC5JV.js.map +1 -0
- package/dist/chunk-F4PYOYHR.js +112 -0
- package/dist/chunk-F4PYOYHR.js.map +1 -0
- package/dist/chunk-GQEDLUMB.js +168 -0
- package/dist/chunk-GQEDLUMB.js.map +1 -0
- package/dist/chunk-H2LESGMX.cjs +319 -0
- package/dist/chunk-H2LESGMX.cjs.map +1 -0
- package/dist/chunk-HTNJT2QU.js +11674 -0
- package/dist/chunk-HTNJT2QU.js.map +1 -0
- package/dist/chunk-IIISFUW4.cjs +11786 -0
- package/dist/chunk-IIISFUW4.cjs.map +1 -0
- package/dist/chunk-IMPCRWYP.cjs +251 -0
- package/dist/chunk-IMPCRWYP.cjs.map +1 -0
- package/dist/chunk-IPPIXOVQ.js +317 -0
- package/dist/chunk-IPPIXOVQ.js.map +1 -0
- package/dist/chunk-J4XJ4UBC.js +1404 -0
- package/dist/chunk-J4XJ4UBC.js.map +1 -0
- package/dist/chunk-J7CPPFXT.cjs +89 -0
- package/dist/chunk-J7CPPFXT.cjs.map +1 -0
- package/dist/chunk-JOICD47Q.cjs +41 -0
- package/dist/chunk-JOICD47Q.cjs.map +1 -0
- package/dist/chunk-KHMG6EI2.js +13 -0
- package/dist/chunk-KHMG6EI2.js.map +1 -0
- package/dist/chunk-KMRURD5J.cjs +15 -0
- package/dist/chunk-KMRURD5J.cjs.map +1 -0
- package/dist/chunk-KRJG3KMP.cjs +174 -0
- package/dist/chunk-KRJG3KMP.cjs.map +1 -0
- package/dist/chunk-KUBVDIF7.cjs +653 -0
- package/dist/chunk-KUBVDIF7.cjs.map +1 -0
- package/dist/chunk-KYAOSBQN.js +31 -0
- package/dist/chunk-KYAOSBQN.js.map +1 -0
- package/dist/chunk-LJ7LMEXO.js +36 -0
- package/dist/chunk-LJ7LMEXO.js.map +1 -0
- package/dist/chunk-MT3KLB2Q.cjs +944 -0
- package/dist/chunk-MT3KLB2Q.cjs.map +1 -0
- package/dist/chunk-MU3RY46O.js +932 -0
- package/dist/chunk-MU3RY46O.js.map +1 -0
- package/dist/chunk-MUQQKPWR.js +84 -0
- package/dist/chunk-MUQQKPWR.js.map +1 -0
- package/dist/chunk-N7SJTINL.cjs +4 -0
- package/dist/chunk-N7SJTINL.cjs.map +1 -0
- package/dist/chunk-NTV2UUAJ.cjs +149 -0
- package/dist/chunk-NTV2UUAJ.cjs.map +1 -0
- package/dist/chunk-PJQWHF6T.js +31 -0
- package/dist/chunk-PJQWHF6T.js.map +1 -0
- package/dist/chunk-PQY54EL5.js +248 -0
- package/dist/chunk-PQY54EL5.js.map +1 -0
- package/dist/chunk-PXCHPZTP.cjs +839 -0
- package/dist/chunk-PXCHPZTP.cjs.map +1 -0
- package/dist/chunk-Q7TBBUTX.cjs +110 -0
- package/dist/chunk-Q7TBBUTX.cjs.map +1 -0
- package/dist/chunk-QQMU44KJ.js +612 -0
- package/dist/chunk-QQMU44KJ.js.map +1 -0
- package/dist/chunk-QZN7R2WP.cjs +114 -0
- package/dist/chunk-QZN7R2WP.cjs.map +1 -0
- package/dist/chunk-RKVSJU46.js +35 -0
- package/dist/chunk-RKVSJU46.js.map +1 -0
- package/dist/chunk-RM6ZWNT3.js +561 -0
- package/dist/chunk-RM6ZWNT3.js.map +1 -0
- package/dist/chunk-SX4VQXAA.cjs +114 -0
- package/dist/chunk-SX4VQXAA.cjs.map +1 -0
- package/dist/chunk-SZ7BLAY3.js +92 -0
- package/dist/chunk-SZ7BLAY3.js.map +1 -0
- package/dist/chunk-TN4MG6FY.js +112 -0
- package/dist/chunk-TN4MG6FY.js.map +1 -0
- package/dist/chunk-UC7PHDM6.cjs +331 -0
- package/dist/chunk-UC7PHDM6.cjs.map +1 -0
- package/dist/chunk-UXVLYUUW.js +108 -0
- package/dist/chunk-UXVLYUUW.js.map +1 -0
- package/dist/chunk-VVGYRZ7S.cjs +38 -0
- package/dist/chunk-VVGYRZ7S.cjs.map +1 -0
- package/dist/chunk-W5256BJ4.js +56 -0
- package/dist/chunk-W5256BJ4.js.map +1 -0
- package/dist/chunk-WUMOSOEK.cjs +62 -0
- package/dist/chunk-WUMOSOEK.cjs.map +1 -0
- package/dist/chunk-XLRE2J25.js +140 -0
- package/dist/chunk-XLRE2J25.js.map +1 -0
- package/dist/chunk-Y6W5V2CI.js +19 -0
- package/dist/chunk-Y6W5V2CI.js.map +1 -0
- package/dist/chunk-Z4QPZ3Z3.cjs +114 -0
- package/dist/chunk-Z4QPZ3Z3.cjs.map +1 -0
- package/dist/createEngineGridQuery-Dmq3i5v3.d.cts +884 -0
- package/dist/createEngineGridQuery-Mt1hc33m.d.ts +884 -0
- package/dist/date-picker-jalali.cjs +263 -0
- package/dist/date-picker-jalali.cjs.map +1 -0
- package/dist/date-picker-jalali.d.cts +62 -0
- package/dist/date-picker-jalali.d.ts +62 -0
- package/dist/date-picker-jalali.js +256 -0
- package/dist/date-picker-jalali.js.map +1 -0
- package/dist/finance.cjs +205 -0
- package/dist/finance.cjs.map +1 -0
- package/dist/finance.d.cts +90 -0
- package/dist/finance.d.ts +90 -0
- package/dist/finance.js +157 -0
- package/dist/finance.js.map +1 -0
- package/dist/foldedColumn-IHDT4ARZ.cjs +66 -0
- package/dist/foldedColumn-IHDT4ARZ.cjs.map +1 -0
- package/dist/foldedColumn-TFURUKFG.js +64 -0
- package/dist/foldedColumn-TFURUKFG.js.map +1 -0
- package/dist/headless.cjs +729 -0
- package/dist/headless.cjs.map +1 -0
- package/dist/headless.d.cts +504 -0
- package/dist/headless.d.ts +504 -0
- package/dist/headless.js +226 -0
- package/dist/headless.js.map +1 -0
- package/dist/index-DN8M8Jkq.d.cts +14 -0
- package/dist/index-DmzL-F_o.d.ts +14 -0
- package/dist/index.cjs +8002 -11409
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +437 -2305
- package/dist/index.d.ts +437 -2305
- package/dist/index.js +7244 -11083
- package/dist/index.js.map +1 -1
- package/dist/locales/ar.cjs +12 -0
- package/dist/locales/ar.cjs.map +1 -0
- package/dist/locales/ar.d.cts +6 -0
- package/dist/locales/ar.d.ts +6 -0
- package/dist/locales/ar.js +3 -0
- package/dist/locales/ar.js.map +1 -0
- package/dist/locales/en.cjs +12 -0
- package/dist/locales/en.cjs.map +1 -0
- package/dist/locales/en.d.cts +6 -0
- package/dist/locales/en.d.ts +6 -0
- package/dist/locales/en.js +3 -0
- package/dist/locales/en.js.map +1 -0
- package/dist/locales/fa.cjs +12 -0
- package/dist/locales/fa.cjs.map +1 -0
- package/dist/locales/fa.d.cts +6 -0
- package/dist/locales/fa.d.ts +6 -0
- package/dist/locales/fa.js +3 -0
- package/dist/locales/fa.js.map +1 -0
- package/dist/locales/index.cjs +51 -0
- package/dist/locales/index.cjs.map +1 -0
- package/dist/locales/index.d.cts +5 -0
- package/dist/locales/index.d.ts +5 -0
- package/dist/locales/index.js +6 -0
- package/dist/locales/index.js.map +1 -0
- package/dist/memoryRecords-AWDKUJ2F.cjs +50 -0
- package/dist/memoryRecords-AWDKUJ2F.cjs.map +1 -0
- package/dist/memoryRecords-OJTGXLRH.js +47 -0
- package/dist/memoryRecords-OJTGXLRH.js.map +1 -0
- package/dist/pagedFooterTotals-DXCGDO6F.cjs +27 -0
- package/dist/pagedFooterTotals-DXCGDO6F.cjs.map +1 -0
- package/dist/pagedFooterTotals-ORWKUNE7.js +25 -0
- package/dist/pagedFooterTotals-ORWKUNE7.js.map +1 -0
- package/dist/pagedKit-MFGAJFSK.cjs +134 -0
- package/dist/pagedKit-MFGAJFSK.cjs.map +1 -0
- package/dist/pagedKit-WYWY4LRV.js +127 -0
- package/dist/pagedKit-WYWY4LRV.js.map +1 -0
- package/dist/pagedSearch-HCPJW7VM.js +38 -0
- package/dist/pagedSearch-HCPJW7VM.js.map +1 -0
- package/dist/pagedSearch-U3WCG4GN.cjs +42 -0
- package/dist/pagedSearch-U3WCG4GN.cjs.map +1 -0
- package/dist/plugins/csv.cjs +124 -0
- package/dist/plugins/csv.cjs.map +1 -0
- package/dist/plugins/csv.d.cts +44 -0
- package/dist/plugins/csv.d.ts +44 -0
- package/dist/plugins/csv.js +120 -0
- package/dist/plugins/csv.js.map +1 -0
- package/dist/plugins/excel.cjs +52 -0
- package/dist/plugins/excel.cjs.map +1 -0
- package/dist/plugins/excel.d.cts +14 -0
- package/dist/plugins/excel.d.ts +14 -0
- package/dist/plugins/excel.js +7 -0
- package/dist/plugins/excel.js.map +1 -0
- package/dist/plugins/pdf/fonts/vazirmatn.cjs +50 -0
- package/dist/plugins/pdf/fonts/vazirmatn.cjs.map +1 -0
- package/dist/plugins/pdf/fonts/vazirmatn.d.cts +24 -0
- package/dist/plugins/pdf/fonts/vazirmatn.d.ts +24 -0
- package/dist/plugins/pdf/fonts/vazirmatn.js +39 -0
- package/dist/plugins/pdf/fonts/vazirmatn.js.map +1 -0
- package/dist/plugins/pdf.cjs +24 -0
- package/dist/plugins/pdf.cjs.map +1 -0
- package/dist/plugins/pdf.d.cts +21 -0
- package/dist/plugins/pdf.d.ts +21 -0
- package/dist/plugins/pdf.js +7 -0
- package/dist/plugins/pdf.js.map +1 -0
- package/dist/presence.cjs +56 -0
- package/dist/presence.cjs.map +1 -0
- package/dist/presence.d.cts +17 -0
- package/dist/presence.d.ts +17 -0
- package/dist/presence.js +54 -0
- package/dist/presence.js.map +1 -0
- package/dist/rebuildRowVisibility-66EAZ356.cjs +21 -0
- package/dist/rebuildRowVisibility-66EAZ356.cjs.map +1 -0
- package/dist/rebuildRowVisibility-6TYM5BP2.js +19 -0
- package/dist/rebuildRowVisibility-6TYM5BP2.js.map +1 -0
- package/dist/styles.css +1440 -0
- package/dist/sync.cjs +148 -0
- package/dist/sync.cjs.map +1 -0
- package/dist/sync.d.cts +17 -0
- package/dist/sync.d.ts +17 -0
- package/dist/sync.js +146 -0
- package/dist/sync.js.map +1 -0
- package/dist/types-D__47BKv.d.cts +23 -0
- package/dist/types-D__47BKv.d.ts +23 -0
- package/package.json +184 -28
|
@@ -0,0 +1,632 @@
|
|
|
1
|
+
import { d as CellRange, e as TableEngine, G as GridEvent, a as Unsubscribe, E as EventStore, f as Table, g as TableActions, h as GridSearchState, F as FilterModel, i as ChangelogProjection, H as HistoryPanelViewModel, j as CellUndoStack, b as GridSession, k as TableViewState, l as ColumnDef, m as GetRowId, M as MobileTableViewState, U as UIRow, R as Row, A as AggFunc, c as CollectionScope, T as TableSnapShot, n as Cell, o as ChangelogQuery, p as ChangelogEntry, q as HistoryQuery, r as HistoryItem, s as ActiveCell, t as CellEditValue, u as MobileEditorState, v as ValidationCallbackResult, V as ValidCell } from './GridSession-Bc7UIawO.js';
|
|
2
|
+
import { A as AuditLogger, R as RemoteApi } from './RemoteApi-CCQxiSf1.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Pure clipboard payload builder (PR-106).
|
|
6
|
+
* No DOM — keyboard/UI wiring writes via infrastructure.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
type ClipboardCellSnapshot = {
|
|
10
|
+
value: unknown;
|
|
11
|
+
display: string;
|
|
12
|
+
};
|
|
13
|
+
type ClipboardRowSnapshot = {
|
|
14
|
+
id: number;
|
|
15
|
+
cells: Record<string, ClipboardCellSnapshot | undefined>;
|
|
16
|
+
/** Infinite/server placeholder row — skipped in clipboard output. */
|
|
17
|
+
loading?: boolean;
|
|
18
|
+
};
|
|
19
|
+
type ClipboardColumnMeta = {
|
|
20
|
+
id: string;
|
|
21
|
+
header: string;
|
|
22
|
+
};
|
|
23
|
+
type ProcessCellForClipboardParams = {
|
|
24
|
+
value: unknown;
|
|
25
|
+
display: string;
|
|
26
|
+
colId: string;
|
|
27
|
+
rowIndex: number;
|
|
28
|
+
rowId: number;
|
|
29
|
+
};
|
|
30
|
+
type ClipboardCopyBuildOptions = {
|
|
31
|
+
/** When true, use formatted display strings (valueFormatter output). Default false. */
|
|
32
|
+
copyFormattedValue?: boolean;
|
|
33
|
+
/** Prepend a header row with column captions. Default false. */
|
|
34
|
+
copyHeadersToClipboard?: boolean;
|
|
35
|
+
/** Eastern digits → ASCII for Excel. Default true. */
|
|
36
|
+
copyDigitsAsLatin?: boolean;
|
|
37
|
+
processCellForClipboard?: (params: ProcessCellForClipboardParams) => string;
|
|
38
|
+
};
|
|
39
|
+
type ClipboardPayload = {
|
|
40
|
+
plainText: string;
|
|
41
|
+
html: string;
|
|
42
|
+
ranges: readonly CellRange[];
|
|
43
|
+
};
|
|
44
|
+
declare function resolveCopyRanges(ranges: readonly CellRange[], activeCell: {
|
|
45
|
+
rowIndex: number;
|
|
46
|
+
colId: string;
|
|
47
|
+
} | null | undefined): CellRange[];
|
|
48
|
+
declare function buildClipboardPayload(input: {
|
|
49
|
+
ranges: readonly CellRange[];
|
|
50
|
+
rows: readonly ClipboardRowSnapshot[];
|
|
51
|
+
columns: readonly ClipboardColumnMeta[];
|
|
52
|
+
activeCell?: {
|
|
53
|
+
rowIndex: number;
|
|
54
|
+
colId: string;
|
|
55
|
+
} | null;
|
|
56
|
+
options?: ClipboardCopyBuildOptions;
|
|
57
|
+
}): ClipboardPayload | null;
|
|
58
|
+
|
|
59
|
+
type ClipboardCopyEvent = {
|
|
60
|
+
plainText: string;
|
|
61
|
+
html: string;
|
|
62
|
+
ranges: readonly CellRange[];
|
|
63
|
+
};
|
|
64
|
+
type ClipboardPasteEvent = {
|
|
65
|
+
text: string;
|
|
66
|
+
applied: number;
|
|
67
|
+
skipped: number;
|
|
68
|
+
rowsAdded: number;
|
|
69
|
+
};
|
|
70
|
+
type GridPasteRuntimeOptions = {
|
|
71
|
+
/** When true (default), paste past the last row adds empty rows. */
|
|
72
|
+
pasteAddsRows?: boolean;
|
|
73
|
+
onClipboardPaste?: (event: ClipboardPasteEvent) => boolean | void;
|
|
74
|
+
};
|
|
75
|
+
type GridClipboardRuntimeOptions = ClipboardCopyBuildOptions & GridPasteRuntimeOptions & {
|
|
76
|
+
onClipboardCopy?: (event: ClipboardCopyEvent) => boolean | void;
|
|
77
|
+
};
|
|
78
|
+
type PasteGridResult = {
|
|
79
|
+
applied: number;
|
|
80
|
+
skipped: number;
|
|
81
|
+
rowsAdded: number;
|
|
82
|
+
};
|
|
83
|
+
declare function writeSystemClipboard(payload: Pick<ClipboardPayload, 'plainText' | 'html'>): Promise<void>;
|
|
84
|
+
declare function copyGridSelectionToClipboard(engine: TableEngine, options?: GridClipboardRuntimeOptions): Promise<boolean>;
|
|
85
|
+
declare function cutGridSelectionToClipboard(engine: TableEngine, store: string, tableKey: string, options?: GridClipboardRuntimeOptions): Promise<boolean>;
|
|
86
|
+
declare function readSystemClipboardText(): Promise<string>;
|
|
87
|
+
declare function pasteGridFromClipboard(engine: TableEngine, store: string, tableKey: string, options?: GridClipboardRuntimeOptions): Promise<PasteGridResult>;
|
|
88
|
+
|
|
89
|
+
/** Conflict resolution policy (PR-138). */
|
|
90
|
+
type SyncConflictPolicy = 'lastWriteWins' | 'serverWins' | 'manual';
|
|
91
|
+
type SyncCellKey = {
|
|
92
|
+
readonly rowId: number;
|
|
93
|
+
readonly columnId: string;
|
|
94
|
+
};
|
|
95
|
+
/** One side of a cell conflict (local or remote). */
|
|
96
|
+
type SyncConflictSide = {
|
|
97
|
+
readonly eventId: string;
|
|
98
|
+
readonly value: unknown;
|
|
99
|
+
readonly occurredAt: number;
|
|
100
|
+
readonly version: number;
|
|
101
|
+
};
|
|
102
|
+
type SyncConflict = {
|
|
103
|
+
readonly id: string;
|
|
104
|
+
readonly key: SyncCellKey;
|
|
105
|
+
readonly local: SyncConflictSide;
|
|
106
|
+
readonly remote: SyncConflictSide;
|
|
107
|
+
};
|
|
108
|
+
type ManualResolution = 'local' | 'remote';
|
|
109
|
+
type SyncTransport = {
|
|
110
|
+
/** Push local events to the remote log. Returns accepted event ids. */
|
|
111
|
+
push(events: readonly GridEvent[]): Promise<{
|
|
112
|
+
acceptedIds: readonly string[];
|
|
113
|
+
}>;
|
|
114
|
+
/** Pull remote events after `since` cursor. */
|
|
115
|
+
pull(since: number): Promise<{
|
|
116
|
+
events: readonly GridEvent[];
|
|
117
|
+
cursor: number;
|
|
118
|
+
}>;
|
|
119
|
+
};
|
|
120
|
+
type SyncResult = {
|
|
121
|
+
readonly pushed: number;
|
|
122
|
+
readonly pulled: number;
|
|
123
|
+
readonly applied: number;
|
|
124
|
+
readonly conflicts: readonly SyncConflict[];
|
|
125
|
+
};
|
|
126
|
+
/**
|
|
127
|
+
* SyncPort: push local pending events, pull remote, resolve cell conflicts.
|
|
128
|
+
* OCC on EventStore remains the local concurrency gate; this port is
|
|
129
|
+
* cross-client merge (PR-138).
|
|
130
|
+
*/
|
|
131
|
+
type SyncPort = {
|
|
132
|
+
getPolicy(): SyncConflictPolicy;
|
|
133
|
+
setPolicy(policy: SyncConflictPolicy): void;
|
|
134
|
+
getOpenConflicts(): readonly SyncConflict[];
|
|
135
|
+
/** Push + pull + apply policy. */
|
|
136
|
+
sync(): Promise<SyncResult>;
|
|
137
|
+
/**
|
|
138
|
+
* Resolve one manual conflict. `choice: 'local'` keeps local value;
|
|
139
|
+
* `'remote'` applies the server value.
|
|
140
|
+
*/
|
|
141
|
+
resolveConflict(conflictId: string, choice: ManualResolution): Promise<void>;
|
|
142
|
+
subscribeConflicts(listener: (conflicts: readonly SyncConflict[]) => void): () => void;
|
|
143
|
+
};
|
|
144
|
+
|
|
145
|
+
/** Peer presence snapshot (PR-139). */
|
|
146
|
+
type PresencePeer = {
|
|
147
|
+
readonly peerId: string;
|
|
148
|
+
readonly actorId: string;
|
|
149
|
+
readonly label: string;
|
|
150
|
+
readonly color: string;
|
|
151
|
+
/** Active cell, if any. */
|
|
152
|
+
readonly rowId: number | null;
|
|
153
|
+
readonly columnId: string | null;
|
|
154
|
+
readonly updatedAt: number;
|
|
155
|
+
};
|
|
156
|
+
type PresenceLocalState = {
|
|
157
|
+
readonly peerId: string;
|
|
158
|
+
readonly actorId: string;
|
|
159
|
+
readonly label: string;
|
|
160
|
+
readonly color: string;
|
|
161
|
+
rowId: number | null;
|
|
162
|
+
columnId: string | null;
|
|
163
|
+
};
|
|
164
|
+
type PresenceMessage = {
|
|
165
|
+
readonly kind: 'presence';
|
|
166
|
+
readonly peer: PresencePeer;
|
|
167
|
+
} | {
|
|
168
|
+
readonly kind: 'leave';
|
|
169
|
+
readonly peerId: string;
|
|
170
|
+
};
|
|
171
|
+
type PresenceTransport = {
|
|
172
|
+
publish(message: PresenceMessage): void;
|
|
173
|
+
subscribe(listener: (message: PresenceMessage) => void): () => void;
|
|
174
|
+
};
|
|
175
|
+
type PresencePort = {
|
|
176
|
+
getLocal(): PresenceLocalState;
|
|
177
|
+
getPeers(): readonly PresencePeer[];
|
|
178
|
+
/** Update local cursor / focus cell and broadcast. */
|
|
179
|
+
setActiveCell(rowId: number | null, columnId: string | null): void;
|
|
180
|
+
/** Announce leave and stop. */
|
|
181
|
+
dispose(): void;
|
|
182
|
+
subscribe(listener: (peers: readonly PresencePeer[]) => void): () => void;
|
|
183
|
+
};
|
|
184
|
+
|
|
185
|
+
/** Host / test seam for online detection (no DOM in application/). */
|
|
186
|
+
type ConnectivitySource = {
|
|
187
|
+
getOnline(): boolean;
|
|
188
|
+
subscribe(listener: (online: boolean) => void): Unsubscribe;
|
|
189
|
+
};
|
|
190
|
+
/** Optional durable set of synced event ids (host/infra; not DOM here). */
|
|
191
|
+
type SyncWatermarkStore = {
|
|
192
|
+
load(): readonly string[];
|
|
193
|
+
save(ids: readonly string[]): void;
|
|
194
|
+
};
|
|
195
|
+
type Connectivity = 'online' | 'offline';
|
|
196
|
+
type PendingChange = {
|
|
197
|
+
readonly eventId: string;
|
|
198
|
+
readonly type: string;
|
|
199
|
+
readonly occurredAt: number;
|
|
200
|
+
readonly summary: string;
|
|
201
|
+
/** Full event for SyncPort push (PR-138). */
|
|
202
|
+
readonly event: GridEvent;
|
|
203
|
+
};
|
|
204
|
+
type OfflineStatusOptions = {
|
|
205
|
+
readonly tableId: string;
|
|
206
|
+
readonly connectivity: ConnectivitySource;
|
|
207
|
+
readonly watermark?: SyncWatermarkStore;
|
|
208
|
+
};
|
|
209
|
+
/**
|
|
210
|
+
* Product offline session (PR-137): connectivity + pending local data mutations
|
|
211
|
+
* not yet marked synced (SyncPort in PR-138 will call `markSynced`).
|
|
212
|
+
*/
|
|
213
|
+
declare class OfflineStatus {
|
|
214
|
+
private readonly options;
|
|
215
|
+
private online;
|
|
216
|
+
private pending;
|
|
217
|
+
private syncedIds;
|
|
218
|
+
private connectivityUnsub;
|
|
219
|
+
private storeUnsub;
|
|
220
|
+
private readonly connectivityListeners;
|
|
221
|
+
private readonly pendingListeners;
|
|
222
|
+
constructor(options: OfflineStatusOptions);
|
|
223
|
+
start(eventStore: EventStore): Promise<void>;
|
|
224
|
+
stop(): void;
|
|
225
|
+
getConnectivity(): Connectivity;
|
|
226
|
+
getPendingChanges(): readonly PendingChange[];
|
|
227
|
+
getPendingCount(): number;
|
|
228
|
+
/** Mark pending mutations as synced (clears queue / advances watermark). */
|
|
229
|
+
markSynced(eventIds?: readonly string[]): void;
|
|
230
|
+
subscribeConnectivity(listener: (state: Connectivity) => void): Unsubscribe;
|
|
231
|
+
subscribePending(listener: (items: readonly PendingChange[]) => void): Unsubscribe;
|
|
232
|
+
private consider;
|
|
233
|
+
private emitConnectivity;
|
|
234
|
+
private emitPending;
|
|
235
|
+
private loadWatermark;
|
|
236
|
+
private persistWatermark;
|
|
237
|
+
}
|
|
238
|
+
/** Always-online source for Node tests / SSR. */
|
|
239
|
+
declare const alwaysOnlineConnectivity: ConnectivitySource;
|
|
240
|
+
|
|
241
|
+
interface UICommandBase {
|
|
242
|
+
readonly type: string;
|
|
243
|
+
}
|
|
244
|
+
interface UICellChangeEvent extends UICommandBase {
|
|
245
|
+
readonly type: 'UI_CELL_CHANGE';
|
|
246
|
+
readonly rowId: number;
|
|
247
|
+
readonly columnId: string;
|
|
248
|
+
readonly value: unknown;
|
|
249
|
+
}
|
|
250
|
+
interface UIDescriptionSaveEvent extends UICommandBase {
|
|
251
|
+
readonly type: 'UI_DESCRIPTION_SAVE';
|
|
252
|
+
readonly rowId: number;
|
|
253
|
+
readonly flag: boolean;
|
|
254
|
+
}
|
|
255
|
+
interface UICellChangeDisplayEvent extends UICommandBase {
|
|
256
|
+
readonly type: 'UI_CELL_CHANGE_DISPLAY';
|
|
257
|
+
readonly rowId: number;
|
|
258
|
+
readonly columnId: string;
|
|
259
|
+
readonly value: string;
|
|
260
|
+
}
|
|
261
|
+
interface UIMoveActiveCellEvent extends UICommandBase {
|
|
262
|
+
readonly type: 'UI_MOVE_ACTIVE_CELL';
|
|
263
|
+
readonly rowId: number;
|
|
264
|
+
readonly columnId: string;
|
|
265
|
+
readonly direction: "next" | "prev";
|
|
266
|
+
}
|
|
267
|
+
interface UIMoveActiveVerticalCellEvent extends UICommandBase {
|
|
268
|
+
readonly type: 'UI_MOVE_ACTIVE_CELL_VERTICAL';
|
|
269
|
+
readonly rowId: number;
|
|
270
|
+
readonly columnId: string;
|
|
271
|
+
readonly direction: 'up' | 'down';
|
|
272
|
+
}
|
|
273
|
+
interface UIActiveFirstCellEvent extends UICommandBase {
|
|
274
|
+
readonly type: 'UI_ACTIVE_FIRST_CELL';
|
|
275
|
+
readonly rowId: number;
|
|
276
|
+
}
|
|
277
|
+
interface UIActiveCellEvent extends UICommandBase {
|
|
278
|
+
readonly type: 'UI_ACTIVE_CELL';
|
|
279
|
+
readonly rowId: number;
|
|
280
|
+
readonly columnId: string;
|
|
281
|
+
readonly shiftKey?: boolean;
|
|
282
|
+
readonly ctrlKey?: boolean;
|
|
283
|
+
}
|
|
284
|
+
interface ChangePageSizeUiCommand extends UICommandBase {
|
|
285
|
+
readonly type: 'CHANGE_PAGE_SIZE';
|
|
286
|
+
readonly pageSize: number;
|
|
287
|
+
}
|
|
288
|
+
interface ChangePageUiCommand extends UICommandBase {
|
|
289
|
+
readonly type: 'CHANGE_PAGE';
|
|
290
|
+
readonly page: number;
|
|
291
|
+
}
|
|
292
|
+
interface ActiveRowUiCommand extends UICommandBase {
|
|
293
|
+
readonly type: 'UI_ACTIVE_ROW';
|
|
294
|
+
readonly rowId: number;
|
|
295
|
+
}
|
|
296
|
+
interface AddEmptyRowUiCommand extends UICommandBase {
|
|
297
|
+
readonly type: 'ADD_EMPTY_ROW';
|
|
298
|
+
}
|
|
299
|
+
interface AddNewRowsUiCommand extends UICommandBase {
|
|
300
|
+
readonly type: 'ADD_NEW_ROWS';
|
|
301
|
+
readonly detailFieldKey: string;
|
|
302
|
+
readonly rows: {
|
|
303
|
+
key: string;
|
|
304
|
+
value: unknown;
|
|
305
|
+
display: unknown;
|
|
306
|
+
}[][];
|
|
307
|
+
}
|
|
308
|
+
interface DuplicateRowUiCommand extends UICommandBase {
|
|
309
|
+
readonly type: 'DUPLICATE_ROW';
|
|
310
|
+
readonly rowId: number;
|
|
311
|
+
}
|
|
312
|
+
interface DeleteRowUiCommand extends UICommandBase {
|
|
313
|
+
readonly type: 'ROW_DELETED';
|
|
314
|
+
readonly rowId: number;
|
|
315
|
+
}
|
|
316
|
+
interface DeleteSelectedRowsUiCommand extends UICommandBase {
|
|
317
|
+
readonly type: 'UI_DELETE_SELECTED_ROW';
|
|
318
|
+
}
|
|
319
|
+
interface DeleteTableUiCommand extends UICommandBase {
|
|
320
|
+
readonly type: 'TABLE_DELETED';
|
|
321
|
+
}
|
|
322
|
+
interface RegisterTableUiCommand extends UICommandBase {
|
|
323
|
+
readonly type: 'TABLE_REGISTERED';
|
|
324
|
+
readonly storeName: string;
|
|
325
|
+
readonly table: Table;
|
|
326
|
+
}
|
|
327
|
+
interface ToggleRowExpandedUiCommand extends UICommandBase {
|
|
328
|
+
readonly type: 'TOGGLE_ROW_EXPANDED';
|
|
329
|
+
readonly rowId: number;
|
|
330
|
+
}
|
|
331
|
+
interface ReorderRowUiCommand extends UICommandBase {
|
|
332
|
+
readonly type: 'ROW_REORDERED';
|
|
333
|
+
readonly draggedRowId: number;
|
|
334
|
+
readonly droppedRowId: number;
|
|
335
|
+
readonly position: 'before' | 'after';
|
|
336
|
+
}
|
|
337
|
+
interface ReorderColumnUiCommand extends UICommandBase {
|
|
338
|
+
readonly type: 'COLUMN_REORDERED';
|
|
339
|
+
readonly sourceIndex: number;
|
|
340
|
+
readonly destIndex: number;
|
|
341
|
+
}
|
|
342
|
+
interface ToggleRowSelectedUiCommand extends UICommandBase {
|
|
343
|
+
readonly type: 'TOGGLE_ROW_SELECTED';
|
|
344
|
+
}
|
|
345
|
+
interface TogglePageRowSelectedUiCommand extends UICommandBase {
|
|
346
|
+
readonly type: 'TOGGLE_PAGE_ROW_SELECTED';
|
|
347
|
+
}
|
|
348
|
+
interface ClearRowSelectionUiCommand extends UICommandBase {
|
|
349
|
+
readonly type: 'CLEAR_ROW_SELECTION';
|
|
350
|
+
}
|
|
351
|
+
interface RowSelectedUiCommand extends UICommandBase {
|
|
352
|
+
readonly type: 'ROW_SELECTED';
|
|
353
|
+
readonly rowId: number;
|
|
354
|
+
}
|
|
355
|
+
interface ActionTableUiCommand extends UICommandBase {
|
|
356
|
+
readonly type: 'UI_ACTION_TABLE';
|
|
357
|
+
readonly action: TableActions;
|
|
358
|
+
}
|
|
359
|
+
interface ActiveCollectionUiCommand extends UICommandBase {
|
|
360
|
+
readonly type: 'UI_CHANGE_ACTIVE_COLLECTION';
|
|
361
|
+
readonly activeCollection: string;
|
|
362
|
+
}
|
|
363
|
+
interface KeyDownUiCommand extends UICommandBase {
|
|
364
|
+
readonly type: 'KEY_DOWN';
|
|
365
|
+
readonly event: KeyboardEvent;
|
|
366
|
+
readonly ctx: {
|
|
367
|
+
tableKey: string;
|
|
368
|
+
activeRowId: number | null;
|
|
369
|
+
activeColumnId: string | null;
|
|
370
|
+
};
|
|
371
|
+
}
|
|
372
|
+
interface SetGridSearchUiCommand extends UICommandBase {
|
|
373
|
+
readonly type: 'UI_SET_GRID_SEARCH';
|
|
374
|
+
readonly search: GridSearchState;
|
|
375
|
+
}
|
|
376
|
+
interface ClearGridSearchUiCommand extends UICommandBase {
|
|
377
|
+
readonly type: 'UI_CLEAR_GRID_SEARCH';
|
|
378
|
+
}
|
|
379
|
+
interface OpenMobileAddUiCommand extends UICommandBase {
|
|
380
|
+
readonly type: 'UI_OPEN_MOBILE_ADD';
|
|
381
|
+
}
|
|
382
|
+
interface OpenMobileEditUiCommand extends UICommandBase {
|
|
383
|
+
readonly type: 'UI_OPEN_MOBILE_EDIT';
|
|
384
|
+
readonly rowId: number;
|
|
385
|
+
}
|
|
386
|
+
interface CloseMobileEditorUiCommand extends UICommandBase {
|
|
387
|
+
readonly type: 'UI_CLOSE_MOBILE_EDITOR';
|
|
388
|
+
}
|
|
389
|
+
interface ResizeColumnUiCommand extends UICommandBase {
|
|
390
|
+
readonly type: 'UI_RESIZE_COLUMN';
|
|
391
|
+
readonly columnId: string;
|
|
392
|
+
readonly width: number;
|
|
393
|
+
}
|
|
394
|
+
interface SetColumnVisibleUiCommand extends UICommandBase {
|
|
395
|
+
readonly type: 'UI_SET_COLUMN_VISIBLE';
|
|
396
|
+
readonly columnId: string;
|
|
397
|
+
readonly visible: boolean;
|
|
398
|
+
}
|
|
399
|
+
interface SetSortModelUiCommand {
|
|
400
|
+
readonly type: 'UI_SET_SORT_MODEL';
|
|
401
|
+
readonly sortModel: readonly {
|
|
402
|
+
readonly colId: string;
|
|
403
|
+
readonly sort: 'asc' | 'desc';
|
|
404
|
+
}[];
|
|
405
|
+
}
|
|
406
|
+
interface SetQuickFilterTextUiCommand {
|
|
407
|
+
readonly type: 'UI_SET_QUICK_FILTER_TEXT';
|
|
408
|
+
readonly quickFilterText: string;
|
|
409
|
+
}
|
|
410
|
+
interface SetFilterModelUiCommand {
|
|
411
|
+
readonly type: 'UI_SET_FILTER_MODEL';
|
|
412
|
+
readonly filterModel: FilterModel;
|
|
413
|
+
}
|
|
414
|
+
interface SetRowGroupColumnsUiCommand {
|
|
415
|
+
readonly type: 'UI_SET_ROW_GROUP_COLUMNS';
|
|
416
|
+
readonly columns: readonly string[];
|
|
417
|
+
}
|
|
418
|
+
interface SetGroupDefaultExpandedUiCommand {
|
|
419
|
+
readonly type: 'UI_SET_GROUP_DEFAULT_EXPANDED';
|
|
420
|
+
readonly expanded: boolean;
|
|
421
|
+
}
|
|
422
|
+
interface ToggleRowGroupUiCommand {
|
|
423
|
+
readonly type: 'UI_TOGGLE_ROW_GROUP';
|
|
424
|
+
readonly groupKey: string;
|
|
425
|
+
}
|
|
426
|
+
type UITableCommand = ActiveRowUiCommand | ToggleRowSelectedUiCommand | TogglePageRowSelectedUiCommand | ClearRowSelectionUiCommand | RowSelectedUiCommand | UIMoveActiveVerticalCellEvent | UIMoveActiveCellEvent | UIActiveCellEvent | UIActiveFirstCellEvent | UICellChangeEvent | UIDescriptionSaveEvent | UICellChangeDisplayEvent | ChangePageSizeUiCommand | ChangePageUiCommand | AddEmptyRowUiCommand | AddNewRowsUiCommand | DuplicateRowUiCommand | DeleteRowUiCommand | DeleteTableUiCommand | RegisterTableUiCommand | ToggleRowExpandedUiCommand | ReorderRowUiCommand | ReorderColumnUiCommand | ActionTableUiCommand | ActiveCollectionUiCommand | DeleteSelectedRowsUiCommand | KeyDownUiCommand | SetGridSearchUiCommand | ClearGridSearchUiCommand | OpenMobileAddUiCommand | OpenMobileEditUiCommand | CloseMobileEditorUiCommand | ResizeColumnUiCommand | SetColumnVisibleUiCommand | SetSortModelUiCommand | SetQuickFilterTextUiCommand | SetFilterModelUiCommand | SetRowGroupColumnsUiCommand | SetGroupDefaultExpandedUiCommand | ToggleRowGroupUiCommand;
|
|
427
|
+
|
|
428
|
+
declare class UITableController {
|
|
429
|
+
private readonly engine;
|
|
430
|
+
private readonly store;
|
|
431
|
+
private readonly tableKey;
|
|
432
|
+
private readonly audit;
|
|
433
|
+
private readonly changelogProjection?;
|
|
434
|
+
private readonly historyPanelViewModel?;
|
|
435
|
+
private readonly cellUndoStack?;
|
|
436
|
+
private readonly session?;
|
|
437
|
+
private readonly remoteApi?;
|
|
438
|
+
private readonly offlineStatus?;
|
|
439
|
+
private disposed;
|
|
440
|
+
private layoutViewportWidth;
|
|
441
|
+
private clipboardOptions;
|
|
442
|
+
private syncPort?;
|
|
443
|
+
private presencePort?;
|
|
444
|
+
constructor(engine: TableEngine, store: string, tableKey: string, audit: AuditLogger, changelogProjection?: ChangelogProjection | undefined, historyPanelViewModel?: HistoryPanelViewModel | undefined, cellUndoStack?: CellUndoStack | undefined, session?: GridSession | undefined, remoteApi?: RemoteApi | undefined, offlineStatus?: OfflineStatus | undefined);
|
|
445
|
+
getRemoteApi(): RemoteApi | undefined;
|
|
446
|
+
getOfflineStatus(): OfflineStatus | undefined;
|
|
447
|
+
getSyncPort(): SyncPort | undefined;
|
|
448
|
+
setSyncPort(port: SyncPort | undefined): void;
|
|
449
|
+
getPresencePort(): PresencePort | undefined;
|
|
450
|
+
setPresencePort(port: PresencePort | undefined): void;
|
|
451
|
+
getPresencePeers(): readonly PresencePeer[];
|
|
452
|
+
subscribePresencePeers(cb: (peers: readonly PresencePeer[]) => void): () => void;
|
|
453
|
+
/** Broadcast local active cell to peers (no-op without presence). */
|
|
454
|
+
publishPresenceCell(rowId: number | null, columnId: string | null): void;
|
|
455
|
+
getConnectivity(): Connectivity;
|
|
456
|
+
getPendingChangeCount(): number;
|
|
457
|
+
getPendingChanges(): readonly PendingChange[];
|
|
458
|
+
markPendingSynced(eventIds?: readonly string[]): void;
|
|
459
|
+
subscribeConnectivity(cb: (state: Connectivity) => void): () => void;
|
|
460
|
+
subscribePendingChanges(cb: (items: readonly PendingChange[]) => void): () => void;
|
|
461
|
+
getSyncPolicy(): SyncConflictPolicy | undefined;
|
|
462
|
+
setSyncPolicy(policy: SyncConflictPolicy): void;
|
|
463
|
+
getOpenSyncConflicts(): readonly SyncConflict[];
|
|
464
|
+
subscribeSyncConflicts(cb: (conflicts: readonly SyncConflict[]) => void): () => void;
|
|
465
|
+
syncNow(): Promise<SyncResult | null>;
|
|
466
|
+
resolveSyncConflict(conflictId: string, choice: ManualResolution): Promise<void>;
|
|
467
|
+
/** Apply a remote cell value (used by SyncPort; dual-writes via engine). */
|
|
468
|
+
applySyncedCellValue(rowId: number, columnId: string, value: unknown): Promise<void>;
|
|
469
|
+
configureClipboard(options: Partial<GridClipboardRuntimeOptions>): void;
|
|
470
|
+
getClipboardOptions(): GridClipboardRuntimeOptions;
|
|
471
|
+
applyFillHandleDrag(extendTo: {
|
|
472
|
+
rowIndex: number;
|
|
473
|
+
colIndex: number;
|
|
474
|
+
}, copyOnly: boolean): Promise<PasteGridResult>;
|
|
475
|
+
private safe;
|
|
476
|
+
private changePageSize;
|
|
477
|
+
private changePage;
|
|
478
|
+
private onCellChange;
|
|
479
|
+
private onDescriptionSave;
|
|
480
|
+
private onCellDisplayChange;
|
|
481
|
+
private setActiveCell;
|
|
482
|
+
private setActiveRow;
|
|
483
|
+
private moveActiveCellVertical;
|
|
484
|
+
private reorderRow;
|
|
485
|
+
private reorderColumns;
|
|
486
|
+
private addEmptyRow;
|
|
487
|
+
private openMobileAddEditor;
|
|
488
|
+
private addNewRows;
|
|
489
|
+
private duplicateRow;
|
|
490
|
+
private deleteRow;
|
|
491
|
+
private deleteRows;
|
|
492
|
+
private deleteTable;
|
|
493
|
+
private registerTable;
|
|
494
|
+
private toggleRowExpanded;
|
|
495
|
+
private toggleRowSelect;
|
|
496
|
+
private togglePageRowSelect;
|
|
497
|
+
private clearRowSelection;
|
|
498
|
+
private selectFromActiveToLast;
|
|
499
|
+
private activateFirstEditableCell;
|
|
500
|
+
private moveToNextCell;
|
|
501
|
+
private setTableAction;
|
|
502
|
+
private setActiveCollection;
|
|
503
|
+
private setGridSearch;
|
|
504
|
+
private setMobileEditor;
|
|
505
|
+
private resizeColumn;
|
|
506
|
+
setColumnVisible(columnId: string, visible: boolean): void;
|
|
507
|
+
setLayoutViewportWidth(width: number): void;
|
|
508
|
+
getLayoutViewportWidth(): number;
|
|
509
|
+
/** Measure header + cell text off-DOM and resize columns (PR-112). */
|
|
510
|
+
autoSizeColumns(colIds?: string[]): void;
|
|
511
|
+
setColumnPinned(columnId: string, pinned: 'start' | 'end' | null): void;
|
|
512
|
+
toggleColumnGroup(groupId: string): void;
|
|
513
|
+
/** Scale column widths to fit the last known scrollport width (PR-112). */
|
|
514
|
+
sizeColumnsToFit(containerWidth?: number): void;
|
|
515
|
+
/** Session-only sort (PR-90). Empty model restores document `index` order. */
|
|
516
|
+
setSortModel(sortModel: readonly {
|
|
517
|
+
colId: string;
|
|
518
|
+
sort: 'asc' | 'desc';
|
|
519
|
+
}[]): void;
|
|
520
|
+
/** Session-only quick filter (PR-93). Empty string shows all rows. */
|
|
521
|
+
setQuickFilterText(quickFilterText: string): void;
|
|
522
|
+
getQuickFilterText(): string;
|
|
523
|
+
/** Session-only column filter model (PR-94). */
|
|
524
|
+
setFilterModel(filterModel: FilterModel): void;
|
|
525
|
+
/** Session-only row grouping (PR-120). Only the first column is active. */
|
|
526
|
+
setRowGroupColumns(columns: readonly string[]): void;
|
|
527
|
+
getRowGroupColumns(): string[];
|
|
528
|
+
setGroupDefaultExpanded(expanded: boolean): void;
|
|
529
|
+
toggleRowGroup(groupKey: string): void;
|
|
530
|
+
getFilterModel(): FilterModel;
|
|
531
|
+
getViewState(): TableViewState | null | undefined;
|
|
532
|
+
applyHostRowData<TRow>(rowData: readonly TRow[], columnDefs?: ColumnDef<TRow>[], getRowId?: GetRowId<TRow>): void;
|
|
533
|
+
getMobileViewState(): MobileTableViewState | null | undefined;
|
|
534
|
+
getRowView(rowId: number): UIRow | null;
|
|
535
|
+
getAllRows(): Row[] | null;
|
|
536
|
+
getAllUIRows(): UIRow[] | null;
|
|
537
|
+
getUiRowAbsoluteIndex(rowId: number): number;
|
|
538
|
+
findColumnSearchMatches(columnId: string, query: string): {
|
|
539
|
+
rowId: number;
|
|
540
|
+
columnId: string;
|
|
541
|
+
}[];
|
|
542
|
+
getColumnTotals(): Record<string, number>;
|
|
543
|
+
getColumnAggs(): Record<string, unknown>;
|
|
544
|
+
getColumnAggValue(columnId: string, overrideAgg?: AggFunc): unknown;
|
|
545
|
+
subscribeColumnTotals(cb: (totals: Record<string, number>) => void): (() => void) | null;
|
|
546
|
+
subscribeColumnAggs(cb: (aggs: Record<string, unknown>) => void): (() => void) | null;
|
|
547
|
+
getSnapShot(collectionScope?: CollectionScope): TableSnapShot | null;
|
|
548
|
+
/** True in persistence 'paged-idb' mode (RAM holds one page window). */
|
|
549
|
+
isPagedWindow(): boolean;
|
|
550
|
+
/** Full IndexedDB snapshot for server save / export. */
|
|
551
|
+
getFullSnapShot(collectionScope?: CollectionScope): Promise<TableSnapShot | null>;
|
|
552
|
+
/**
|
|
553
|
+
* Stream serialized row records from IndexedDB in bounded batches (no full
|
|
554
|
+
* load). Heap holds one batch at a time. Return false from onBatch to stop.
|
|
555
|
+
*/
|
|
556
|
+
iterateRowsFromDb(collectionScope: CollectionScope, onBatch: (records: {
|
|
557
|
+
rowId: number;
|
|
558
|
+
collection: string;
|
|
559
|
+
sortIndex: number;
|
|
560
|
+
rowState: string;
|
|
561
|
+
cells: Record<string, {
|
|
562
|
+
value: unknown;
|
|
563
|
+
originalValue: unknown;
|
|
564
|
+
display: unknown;
|
|
565
|
+
}>;
|
|
566
|
+
}[], ordinalBase: number) => Promise<boolean | void>, batchSize?: number): Promise<void>;
|
|
567
|
+
getCell(rowId: number, columnId: string): Cell | null | undefined;
|
|
568
|
+
getChangelog(filter?: Omit<ChangelogQuery, 'tableId'>): ChangelogEntry[];
|
|
569
|
+
getChangelogCount(filter?: Omit<ChangelogQuery, 'tableId'>): number;
|
|
570
|
+
subscribeChangelog(cb: (entries: ChangelogEntry[]) => void, filter?: Omit<ChangelogQuery, 'tableId'>): () => void;
|
|
571
|
+
getHistoryItems(filter?: Omit<HistoryQuery, 'tableId'>): HistoryItem[];
|
|
572
|
+
getHistoryItemCount(filter?: Omit<HistoryQuery, 'tableId'>): number;
|
|
573
|
+
subscribeHistoryItems(cb: (items: HistoryItem[]) => void, filter?: Omit<HistoryQuery, 'tableId'>): () => void;
|
|
574
|
+
canUndo(): boolean;
|
|
575
|
+
canRedo(): boolean;
|
|
576
|
+
undo(): Promise<boolean>;
|
|
577
|
+
redo(): Promise<boolean>;
|
|
578
|
+
getActiveRow(): number | null;
|
|
579
|
+
getSelectedRows(): Record<number, boolean> | null | undefined;
|
|
580
|
+
getActiveCell(): ActiveCell | undefined;
|
|
581
|
+
refreshView(): void;
|
|
582
|
+
clearActiveCell(cancel?: boolean): Promise<void>;
|
|
583
|
+
startCellEdit(rowId: number, columnId: string): void;
|
|
584
|
+
cancelCellEdit(): void;
|
|
585
|
+
commitCellEdit(): Promise<number>;
|
|
586
|
+
getEditDraft(rowId: number, columnId: string): CellEditValue | null;
|
|
587
|
+
isEditingCell(rowId: number, columnId: string): boolean;
|
|
588
|
+
getMobileEditor(): MobileEditorState | undefined;
|
|
589
|
+
resetMobileVisibleRows(size?: number): void;
|
|
590
|
+
loadMoreMobileRows(step?: number): void;
|
|
591
|
+
revealAllMobileRows(minSize?: number): void;
|
|
592
|
+
isActiveCell(rowId: number, columnId: string): boolean | null;
|
|
593
|
+
isActiveRow(rowId: number): boolean | null;
|
|
594
|
+
isSelectedRow(rowId: number): boolean | null;
|
|
595
|
+
isCutRow(rowId: number): boolean | null;
|
|
596
|
+
subscribe(cb: () => void): (() => void) | null;
|
|
597
|
+
subscribeSelected<TSelected>(selector: () => TSelected, listener: (selected: TSelected) => void, isEqual?: (a: TSelected, b: TSelected) => boolean): () => void;
|
|
598
|
+
getSession(): GridSession | undefined;
|
|
599
|
+
getTableKey(): string;
|
|
600
|
+
/**
|
|
601
|
+
* Streamed column subscription (Memory Iron Rule compliant): every row's
|
|
602
|
+
* {id, rowNum, value} is folded into via (heap = one batch,
|
|
603
|
+
* never the full dataset); fires only when the column data changed.
|
|
604
|
+
*
|
|
605
|
+
* Legacy form (cb receives the
|
|
606
|
+
* item array) is still supported.
|
|
607
|
+
*/
|
|
608
|
+
subscribeColumn<T>(columnId: string, collections: CollectionScope, reducer: (acc: T, item: {
|
|
609
|
+
id: number;
|
|
610
|
+
rowNum: unknown;
|
|
611
|
+
value: unknown;
|
|
612
|
+
}) => T, seed: T, cb: (acc: T) => void): (() => void) | null;
|
|
613
|
+
subscribeColumn<T>(columnId: string, collections: CollectionScope, cb: (values: Array<{
|
|
614
|
+
id: number;
|
|
615
|
+
rowNum: unknown;
|
|
616
|
+
value: T;
|
|
617
|
+
}>) => void): (() => void) | null;
|
|
618
|
+
validation: () => (callback: (result: ValidationCallbackResult) => void) => void;
|
|
619
|
+
isValidCell(rowId: number, columnId: string): ValidCell | null;
|
|
620
|
+
onRowClick(rowId: number, modifiers: {
|
|
621
|
+
ctrlKey: boolean;
|
|
622
|
+
shiftKey: boolean;
|
|
623
|
+
}): void;
|
|
624
|
+
onRowSelect(rowId: number): void;
|
|
625
|
+
getCellRanges(): readonly CellRange[];
|
|
626
|
+
addCellRange(range: CellRange): void;
|
|
627
|
+
dispose(): void;
|
|
628
|
+
dispatch(command: UITableCommand): Promise<void>;
|
|
629
|
+
private dispatchInternal;
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
export { type SyncWatermarkStore as A, type Connectivity as B, type ClipboardCellSnapshot as C, type PendingChange as D, alwaysOnlineConnectivity as E, type GridClipboardRuntimeOptions as G, type ManualResolution as M, OfflineStatus as O, type PresenceLocalState as P, type SyncConflict as S, UITableController as U, type PresenceMessage as a, type PresencePeer as b, type PresencePort as c, type PresenceTransport as d, type SyncConflictPolicy as e, type SyncConflictSide as f, type SyncPort as g, type SyncResult as h, type SyncTransport as i, type PasteGridResult as j, type ClipboardColumnMeta as k, type ClipboardCopyBuildOptions as l, type ClipboardCopyEvent as m, type ClipboardPasteEvent as n, type ClipboardPayload as o, type ClipboardRowSnapshot as p, type GridPasteRuntimeOptions as q, type ProcessCellForClipboardParams as r, buildClipboardPayload as s, copyGridSelectionToClipboard as t, cutGridSelectionToClipboard as u, pasteGridFromClipboard as v, readSystemClipboardText as w, resolveCopyRanges as x, writeSystemClipboard as y, type ConnectivitySource as z };
|