@revolist/revogrid 4.21.8 → 4.21.9
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/dist/collection/components/data/revogr-data.js +3 -3
- package/dist/collection/components/editors/revogr-edit.js +3 -3
- package/dist/collection/components/header/revogr-header.js +4 -4
- package/dist/collection/components/order/revogr-order-editor.js +2 -2
- package/dist/collection/components/overlay/revogr-overlay-selection.js +6 -6
- package/dist/collection/components/revoGrid/revo-grid.js +33 -21
- package/dist/collection/components/selectionFocus/revogr-focus.js +2 -2
- package/dist/types/components/data/revogr-data.d.ts +1 -1
- package/dist/types/services/column.data.provider.d.ts +1 -1
- package/dist/types/types/interfaces.d.ts +40 -18
- package/dist/types/types/selection.d.ts +12 -8
- package/package.json +1 -1
|
@@ -395,7 +395,7 @@ export class RevogrData {
|
|
|
395
395
|
"mutable": false,
|
|
396
396
|
"complexType": {
|
|
397
397
|
"original": "Observable<DSourceState<ColumnRegular, DimensionCols>>",
|
|
398
|
-
"resolved": "\"colPinEnd\" | \"colPinStart\" | \"rgCol\" | ColumnRegular<ColumnProp
|
|
398
|
+
"resolved": "\"colPinEnd\" | \"colPinStart\" | \"rgCol\" | ColumnRegular<ColumnProp, DataType<any, ColumnProp>>",
|
|
399
399
|
"references": {
|
|
400
400
|
"Observable": {
|
|
401
401
|
"location": "import",
|
|
@@ -613,7 +613,7 @@ export class RevogrData {
|
|
|
613
613
|
},
|
|
614
614
|
"complexType": {
|
|
615
615
|
"original": "BeforeCellRenderEvent<CellTemplateProp>",
|
|
616
|
-
"resolved": "BeforeCellRenderEvent<CellTemplateProp<DataType<any, ColumnProp>, ColumnRegular<ColumnProp
|
|
616
|
+
"resolved": "BeforeCellRenderEvent<CellTemplateProp<DataType<any, ColumnProp>, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>, ColumnProp>>",
|
|
617
617
|
"references": {
|
|
618
618
|
"BeforeCellRenderEvent": {
|
|
619
619
|
"location": "import",
|
|
@@ -663,7 +663,7 @@ export class RevogrData {
|
|
|
663
663
|
},
|
|
664
664
|
"complexType": {
|
|
665
665
|
"original": "DragStartEvent",
|
|
666
|
-
"resolved": "DragStartEvent<DataType<any, ColumnProp>, ColumnRegular<ColumnProp
|
|
666
|
+
"resolved": "DragStartEvent<DataType<any, ColumnProp>, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
667
667
|
"references": {
|
|
668
668
|
"DragStartEvent": {
|
|
669
669
|
"location": "import",
|
|
@@ -156,7 +156,7 @@ export class RevoEdit {
|
|
|
156
156
|
"mutable": false,
|
|
157
157
|
"complexType": {
|
|
158
158
|
"original": "EditCell",
|
|
159
|
-
"resolved": "EditCellStore & BeforeSaveDataDetails",
|
|
159
|
+
"resolved": "EditCellStore & BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
160
160
|
"references": {
|
|
161
161
|
"EditCell": {
|
|
162
162
|
"location": "import",
|
|
@@ -180,7 +180,7 @@ export class RevoEdit {
|
|
|
180
180
|
"mutable": false,
|
|
181
181
|
"complexType": {
|
|
182
182
|
"original": "ColumnDataSchemaModel | null",
|
|
183
|
-
"resolved": "ColumnDataSchemaModel<DataType<any, ColumnProp>, ColumnRegular<ColumnProp
|
|
183
|
+
"resolved": "ColumnDataSchemaModel<DataType<any, ColumnProp>, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>, ColumnProp> | null",
|
|
184
184
|
"references": {
|
|
185
185
|
"ColumnDataSchemaModel": {
|
|
186
186
|
"location": "import",
|
|
@@ -204,7 +204,7 @@ export class RevoEdit {
|
|
|
204
204
|
"mutable": false,
|
|
205
205
|
"complexType": {
|
|
206
206
|
"original": "EditorCtr | null",
|
|
207
|
-
"resolved": "((column: ColumnDataSchemaModel<DataType<any, ColumnProp>, ColumnRegular<ColumnProp
|
|
207
|
+
"resolved": "((column: ColumnDataSchemaModel<DataType<any, ColumnProp>, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>, ColumnProp>, save: (value?: any, preventFocus?: boolean | undefined) => void, close: (focusNext?: boolean | undefined) => void) => EditorBase) | EditorCtrConstructible | null",
|
|
208
208
|
"references": {
|
|
209
209
|
"EditorCtr": {
|
|
210
210
|
"location": "import",
|
|
@@ -336,7 +336,7 @@ export class RevogrHeaderComponent {
|
|
|
336
336
|
"mutable": false,
|
|
337
337
|
"complexType": {
|
|
338
338
|
"original": "ColumnRegular[]",
|
|
339
|
-
"resolved": "ColumnRegular<ColumnProp
|
|
339
|
+
"resolved": "ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]",
|
|
340
340
|
"references": {
|
|
341
341
|
"ColumnRegular": {
|
|
342
342
|
"location": "import",
|
|
@@ -435,7 +435,7 @@ export class RevogrHeaderComponent {
|
|
|
435
435
|
},
|
|
436
436
|
"complexType": {
|
|
437
437
|
"original": "InitialHeaderClick",
|
|
438
|
-
"resolved": "{ index: number; originalEvent: MouseEvent; column: ColumnRegular<ColumnProp
|
|
438
|
+
"resolved": "{ index: number; originalEvent: MouseEvent; column: ColumnRegular<ColumnProp, DataType<any, ColumnProp>>; providers: ProvidersColumns<DimensionCols | \"rowHeaders\">; }",
|
|
439
439
|
"references": {
|
|
440
440
|
"InitialHeaderClick": {
|
|
441
441
|
"location": "import",
|
|
@@ -479,7 +479,7 @@ export class RevogrHeaderComponent {
|
|
|
479
479
|
},
|
|
480
480
|
"complexType": {
|
|
481
481
|
"original": "ColumnRegular[]",
|
|
482
|
-
"resolved": "ColumnRegular<ColumnProp
|
|
482
|
+
"resolved": "ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]",
|
|
483
483
|
"references": {
|
|
484
484
|
"ColumnRegular": {
|
|
485
485
|
"location": "import",
|
|
@@ -501,7 +501,7 @@ export class RevogrHeaderComponent {
|
|
|
501
501
|
},
|
|
502
502
|
"complexType": {
|
|
503
503
|
"original": "InitialHeaderClick",
|
|
504
|
-
"resolved": "{ index: number; originalEvent: MouseEvent; column: ColumnRegular<ColumnProp
|
|
504
|
+
"resolved": "{ index: number; originalEvent: MouseEvent; column: ColumnRegular<ColumnProp, DataType<any, ColumnProp>>; providers: ProvidersColumns<DimensionCols | \"rowHeaders\">; }",
|
|
505
505
|
"references": {
|
|
506
506
|
"InitialHeaderClick": {
|
|
507
507
|
"location": "import",
|
|
@@ -260,7 +260,7 @@ export class OrderEditor {
|
|
|
260
260
|
},
|
|
261
261
|
"complexType": {
|
|
262
262
|
"original": "RowDragStartDetails",
|
|
263
|
-
"resolved": "
|
|
263
|
+
"resolved": "TModel",
|
|
264
264
|
"references": {
|
|
265
265
|
"RowDragStartDetails": {
|
|
266
266
|
"location": "import",
|
|
@@ -401,7 +401,7 @@ export class OrderEditor {
|
|
|
401
401
|
"signature": "(e: DragStartEvent) => Promise<void>",
|
|
402
402
|
"parameters": [{
|
|
403
403
|
"name": "e",
|
|
404
|
-
"type": "DragStartEvent<DataType<any, ColumnProp>, ColumnRegular<ColumnProp
|
|
404
|
+
"type": "DragStartEvent<DataType<any, ColumnProp>, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
405
405
|
"docs": ""
|
|
406
406
|
}],
|
|
407
407
|
"references": {
|
|
@@ -717,7 +717,7 @@ export class OverlaySelection {
|
|
|
717
717
|
"mutable": false,
|
|
718
718
|
"complexType": {
|
|
719
719
|
"original": "Observable<DSourceState<ColumnRegular, DimensionCols>>",
|
|
720
|
-
"resolved": "\"colPinEnd\" | \"colPinStart\" | \"rgCol\" | ColumnRegular<ColumnProp
|
|
720
|
+
"resolved": "\"colPinEnd\" | \"colPinStart\" | \"rgCol\" | ColumnRegular<ColumnProp, DataType<any, ColumnProp>>",
|
|
721
721
|
"references": {
|
|
722
722
|
"Observable": {
|
|
723
723
|
"location": "import",
|
|
@@ -905,7 +905,7 @@ export class OverlaySelection {
|
|
|
905
905
|
},
|
|
906
906
|
"complexType": {
|
|
907
907
|
"original": "BeforeSaveDataDetails",
|
|
908
|
-
"resolved": "BeforeSaveDataDetails",
|
|
908
|
+
"resolved": "BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
909
909
|
"references": {
|
|
910
910
|
"BeforeSaveDataDetails": {
|
|
911
911
|
"location": "import",
|
|
@@ -927,7 +927,7 @@ export class OverlaySelection {
|
|
|
927
927
|
},
|
|
928
928
|
"complexType": {
|
|
929
929
|
"original": "BeforeSaveDataDetails",
|
|
930
|
-
"resolved": "BeforeSaveDataDetails",
|
|
930
|
+
"resolved": "BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
931
931
|
"references": {
|
|
932
932
|
"BeforeSaveDataDetails": {
|
|
933
933
|
"location": "import",
|
|
@@ -971,7 +971,7 @@ export class OverlaySelection {
|
|
|
971
971
|
},
|
|
972
972
|
"complexType": {
|
|
973
973
|
"original": "BeforeEdit",
|
|
974
|
-
"resolved": "BeforeSaveDataDetails",
|
|
974
|
+
"resolved": "BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
975
975
|
"references": {
|
|
976
976
|
"BeforeEdit": {
|
|
977
977
|
"location": "import",
|
|
@@ -1294,7 +1294,7 @@ export class OverlaySelection {
|
|
|
1294
1294
|
},
|
|
1295
1295
|
"complexType": {
|
|
1296
1296
|
"original": "BeforeRangeSaveDataDetails",
|
|
1297
|
-
"resolved": "
|
|
1297
|
+
"resolved": "TModel",
|
|
1298
1298
|
"references": {
|
|
1299
1299
|
"BeforeRangeSaveDataDetails": {
|
|
1300
1300
|
"location": "import",
|
|
@@ -1338,7 +1338,7 @@ export class OverlaySelection {
|
|
|
1338
1338
|
},
|
|
1339
1339
|
"complexType": {
|
|
1340
1340
|
"original": "RangeClipboardPasteEvent",
|
|
1341
|
-
"resolved": "RangeClipboardPasteEvent",
|
|
1341
|
+
"resolved": "RangeClipboardPasteEvent<DataType<any, ColumnProp>>",
|
|
1342
1342
|
"references": {
|
|
1343
1343
|
"RangeClipboardPasteEvent": {
|
|
1344
1344
|
"location": "import",
|
|
@@ -1251,7 +1251,7 @@ export class RevoGridComponent {
|
|
|
1251
1251
|
"mutable": false,
|
|
1252
1252
|
"complexType": {
|
|
1253
1253
|
"original": "(ColumnRegular | ColumnGrouping)[]",
|
|
1254
|
-
"resolved": "(ColumnRegular<ColumnProp
|
|
1254
|
+
"resolved": "(ColumnRegular<ColumnProp, DataType<any, ColumnProp>> | ColumnGrouping<any>)[]",
|
|
1255
1255
|
"references": {
|
|
1256
1256
|
"ColumnRegular": {
|
|
1257
1257
|
"location": "import",
|
|
@@ -1452,7 +1452,7 @@ export class RevoGridComponent {
|
|
|
1452
1452
|
"mutable": false,
|
|
1453
1453
|
"complexType": {
|
|
1454
1454
|
"original": "{ [name: string]: ColumnType }",
|
|
1455
|
-
"resolved": "{ [name: string]: ColumnType
|
|
1455
|
+
"resolved": "{ [name: string]: ColumnType<DataType<any, ColumnProp>>; }",
|
|
1456
1456
|
"references": {
|
|
1457
1457
|
"ColumnType": {
|
|
1458
1458
|
"location": "import",
|
|
@@ -1970,7 +1970,7 @@ export class RevoGridComponent {
|
|
|
1970
1970
|
},
|
|
1971
1971
|
"complexType": {
|
|
1972
1972
|
"original": "BeforeSaveDataDetails",
|
|
1973
|
-
"resolved": "BeforeSaveDataDetails",
|
|
1973
|
+
"resolved": "BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
1974
1974
|
"references": {
|
|
1975
1975
|
"BeforeSaveDataDetails": {
|
|
1976
1976
|
"location": "import",
|
|
@@ -1992,7 +1992,7 @@ export class RevoGridComponent {
|
|
|
1992
1992
|
},
|
|
1993
1993
|
"complexType": {
|
|
1994
1994
|
"original": "BeforeRangeSaveDataDetails",
|
|
1995
|
-
"resolved": "
|
|
1995
|
+
"resolved": "TModel",
|
|
1996
1996
|
"references": {
|
|
1997
1997
|
"BeforeRangeSaveDataDetails": {
|
|
1998
1998
|
"location": "import",
|
|
@@ -2014,7 +2014,7 @@ export class RevoGridComponent {
|
|
|
2014
2014
|
},
|
|
2015
2015
|
"complexType": {
|
|
2016
2016
|
"original": "AfterEditEvent",
|
|
2017
|
-
"resolved": "BeforeSaveDataDetails
|
|
2017
|
+
"resolved": "BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>> | D | K",
|
|
2018
2018
|
"references": {
|
|
2019
2019
|
"AfterEditEvent": {
|
|
2020
2020
|
"location": "import",
|
|
@@ -2080,7 +2080,7 @@ export class RevoGridComponent {
|
|
|
2080
2080
|
},
|
|
2081
2081
|
"complexType": {
|
|
2082
2082
|
"original": "FocusAfterRenderEvent",
|
|
2083
|
-
"resolved": "FocusAfterRenderEvent",
|
|
2083
|
+
"resolved": "FocusAfterRenderEvent<DataType<any, ColumnProp>>",
|
|
2084
2084
|
"references": {
|
|
2085
2085
|
"FocusAfterRenderEvent": {
|
|
2086
2086
|
"location": "import",
|
|
@@ -2117,7 +2117,7 @@ export class RevoGridComponent {
|
|
|
2117
2117
|
},
|
|
2118
2118
|
"complexType": {
|
|
2119
2119
|
"original": "{\n column: ColumnRegular;\n order: 'desc' | 'asc';\n additive: boolean;\n }",
|
|
2120
|
-
"resolved": "{ column: ColumnRegular<ColumnProp
|
|
2120
|
+
"resolved": "{ column: ColumnRegular<ColumnProp, DataType<any, ColumnProp>>; order: \"asc\" | \"desc\"; additive: boolean; }",
|
|
2121
2121
|
"references": {
|
|
2122
2122
|
"ColumnRegular": {
|
|
2123
2123
|
"location": "import",
|
|
@@ -2167,7 +2167,7 @@ export class RevoGridComponent {
|
|
|
2167
2167
|
},
|
|
2168
2168
|
"complexType": {
|
|
2169
2169
|
"original": "{\n column: ColumnRegular;\n order: 'desc' | 'asc';\n additive: boolean;\n }",
|
|
2170
|
-
"resolved": "{ column: ColumnRegular<ColumnProp
|
|
2170
|
+
"resolved": "{ column: ColumnRegular<ColumnProp, DataType<any, ColumnProp>>; order: \"asc\" | \"desc\"; additive: boolean; }",
|
|
2171
2171
|
"references": {
|
|
2172
2172
|
"ColumnRegular": {
|
|
2173
2173
|
"location": "import",
|
|
@@ -2189,7 +2189,7 @@ export class RevoGridComponent {
|
|
|
2189
2189
|
},
|
|
2190
2190
|
"complexType": {
|
|
2191
2191
|
"original": "RowDragStartDetails",
|
|
2192
|
-
"resolved": "
|
|
2192
|
+
"resolved": "TModel",
|
|
2193
2193
|
"references": {
|
|
2194
2194
|
"RowDragStartDetails": {
|
|
2195
2195
|
"location": "import",
|
|
@@ -2211,7 +2211,7 @@ export class RevoGridComponent {
|
|
|
2211
2211
|
},
|
|
2212
2212
|
"complexType": {
|
|
2213
2213
|
"original": "ColumnRegular",
|
|
2214
|
-
"resolved": "ColumnRegular<ColumnProp
|
|
2214
|
+
"resolved": "ColumnRegular<ColumnProp, DataType<any, ColumnProp>>",
|
|
2215
2215
|
"references": {
|
|
2216
2216
|
"ColumnRegular": {
|
|
2217
2217
|
"location": "import",
|
|
@@ -2233,7 +2233,7 @@ export class RevoGridComponent {
|
|
|
2233
2233
|
},
|
|
2234
2234
|
"complexType": {
|
|
2235
2235
|
"original": "BeforeSaveDataDetails",
|
|
2236
|
-
"resolved": "BeforeSaveDataDetails",
|
|
2236
|
+
"resolved": "BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
2237
2237
|
"references": {
|
|
2238
2238
|
"BeforeSaveDataDetails": {
|
|
2239
2239
|
"location": "import",
|
|
@@ -2255,7 +2255,7 @@ export class RevoGridComponent {
|
|
|
2255
2255
|
},
|
|
2256
2256
|
"complexType": {
|
|
2257
2257
|
"original": "FocusedData | null",
|
|
2258
|
-
"resolved": "null | { model: any; cell: Cell; colType: DimensionCols; rowType: DimensionRows; column?: ColumnRegular<ColumnProp
|
|
2258
|
+
"resolved": "null | { model: any; cell: Cell; colType: DimensionCols; rowType: DimensionRows; column?: ColumnRegular<ColumnProp, DataType<any, ColumnProp>> | undefined; }",
|
|
2259
2259
|
"references": {
|
|
2260
2260
|
"FocusedData": {
|
|
2261
2261
|
"location": "import",
|
|
@@ -2389,7 +2389,7 @@ export class RevoGridComponent {
|
|
|
2389
2389
|
},
|
|
2390
2390
|
"complexType": {
|
|
2391
2391
|
"original": "{\n columns: (ColumnGrouping | ColumnRegular)[];\n }",
|
|
2392
|
-
"resolved": "{ columns: (ColumnRegular<ColumnProp
|
|
2392
|
+
"resolved": "{ columns: (ColumnRegular<ColumnProp, DataType<any, ColumnProp>> | ColumnGrouping<any>)[]; }",
|
|
2393
2393
|
"references": {
|
|
2394
2394
|
"ColumnGrouping": {
|
|
2395
2395
|
"location": "import",
|
|
@@ -2417,7 +2417,7 @@ export class RevoGridComponent {
|
|
|
2417
2417
|
},
|
|
2418
2418
|
"complexType": {
|
|
2419
2419
|
"original": "ColumnCollection",
|
|
2420
|
-
"resolved": "{ columns: Record<DimensionCols, ColumnRegular<ColumnProp
|
|
2420
|
+
"resolved": "{ columns: Record<DimensionCols, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]>; columnByProp: Record<ColumnProp, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]>; columnGrouping: ColumnGroupingCollection; maxLevel: number; sort: Record<ColumnProp, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>; }",
|
|
2421
2421
|
"references": {
|
|
2422
2422
|
"ColumnCollection": {
|
|
2423
2423
|
"location": "import",
|
|
@@ -2439,7 +2439,7 @@ export class RevoGridComponent {
|
|
|
2439
2439
|
},
|
|
2440
2440
|
"complexType": {
|
|
2441
2441
|
"original": "ColumnCollection",
|
|
2442
|
-
"resolved": "{ columns: Record<DimensionCols, ColumnRegular<ColumnProp
|
|
2442
|
+
"resolved": "{ columns: Record<DimensionCols, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]>; columnByProp: Record<ColumnProp, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]>; columnGrouping: ColumnGroupingCollection; maxLevel: number; sort: Record<ColumnProp, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>; }",
|
|
2443
2443
|
"references": {
|
|
2444
2444
|
"ColumnCollection": {
|
|
2445
2445
|
"location": "import",
|
|
@@ -2632,7 +2632,7 @@ export class RevoGridComponent {
|
|
|
2632
2632
|
},
|
|
2633
2633
|
"complexType": {
|
|
2634
2634
|
"original": "BeforeSaveDataDetails",
|
|
2635
|
-
"resolved": "BeforeSaveDataDetails",
|
|
2635
|
+
"resolved": "BeforeSaveDataDetails<DataType, ColumnRegular<ColumnProp, DataType<any, ColumnProp>>>",
|
|
2636
2636
|
"references": {
|
|
2637
2637
|
"BeforeSaveDataDetails": {
|
|
2638
2638
|
"location": "import",
|
|
@@ -2654,7 +2654,7 @@ export class RevoGridComponent {
|
|
|
2654
2654
|
},
|
|
2655
2655
|
"complexType": {
|
|
2656
2656
|
"original": "{\n [index: number]: ColumnRegular;\n }",
|
|
2657
|
-
"resolved": "{ [index: number]: ColumnRegular<ColumnProp
|
|
2657
|
+
"resolved": "{ [index: number]: ColumnRegular<ColumnProp, DataType<any, ColumnProp>>; }",
|
|
2658
2658
|
"references": {
|
|
2659
2659
|
"ColumnRegular": {
|
|
2660
2660
|
"location": "import",
|
|
@@ -2977,7 +2977,7 @@ export class RevoGridComponent {
|
|
|
2977
2977
|
"signature": "(cols: ColumnRegular[]) => Promise<void>",
|
|
2978
2978
|
"parameters": [{
|
|
2979
2979
|
"name": "cols",
|
|
2980
|
-
"type": "ColumnRegular<ColumnProp
|
|
2980
|
+
"type": "ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]",
|
|
2981
2981
|
"docs": ""
|
|
2982
2982
|
}],
|
|
2983
2983
|
"references": {
|
|
@@ -3306,9 +3306,15 @@ export class RevoGridComponent {
|
|
|
3306
3306
|
"path": "@type",
|
|
3307
3307
|
"id": "src/types/index.ts::ColumnProp",
|
|
3308
3308
|
"referenceLocation": "ColumnProp"
|
|
3309
|
+
},
|
|
3310
|
+
"DataType": {
|
|
3311
|
+
"location": "import",
|
|
3312
|
+
"path": "@type",
|
|
3313
|
+
"id": "src/types/index.ts::DataType",
|
|
3314
|
+
"referenceLocation": "DataType"
|
|
3309
3315
|
}
|
|
3310
3316
|
},
|
|
3311
|
-
"return": "Promise<Observable<DSourceState<ColumnRegular<ColumnProp
|
|
3317
|
+
"return": "Promise<Observable<DSourceState<ColumnRegular<ColumnProp, DataType<any, ColumnProp>>, DimensionCols>>>"
|
|
3312
3318
|
},
|
|
3313
3319
|
"docs": {
|
|
3314
3320
|
"text": "Provides access to column internal store observer\nCan be used for plugin support",
|
|
@@ -3323,7 +3329,7 @@ export class RevoGridComponent {
|
|
|
3323
3329
|
"signature": "(column: Pick<ColumnRegular, \"prop\" | \"cellCompare\">, order: \"asc\" | \"desc\" | undefined, additive: boolean) => Promise<void>",
|
|
3324
3330
|
"parameters": [{
|
|
3325
3331
|
"name": "column",
|
|
3326
|
-
"type": "{ prop: ColumnProp; cellCompare?: CellCompareFunc | undefined; }",
|
|
3332
|
+
"type": "{ prop: ColumnProp; cellCompare?: CellCompareFunc<DataType<any, ColumnProp>> | undefined; }",
|
|
3327
3333
|
"docs": "- column prop and cellCompare"
|
|
3328
3334
|
}, {
|
|
3329
3335
|
"name": "order",
|
|
@@ -3403,9 +3409,15 @@ export class RevoGridComponent {
|
|
|
3403
3409
|
"path": "@type",
|
|
3404
3410
|
"id": "src/types/index.ts::ColumnProp",
|
|
3405
3411
|
"referenceLocation": "ColumnProp"
|
|
3412
|
+
},
|
|
3413
|
+
"DataType": {
|
|
3414
|
+
"location": "import",
|
|
3415
|
+
"path": "@type",
|
|
3416
|
+
"id": "src/types/index.ts::DataType",
|
|
3417
|
+
"referenceLocation": "DataType"
|
|
3406
3418
|
}
|
|
3407
3419
|
},
|
|
3408
|
-
"return": "Promise<ColumnRegular<ColumnProp
|
|
3420
|
+
"return": "Promise<ColumnRegular<ColumnProp, DataType<any, ColumnProp>>[]>"
|
|
3409
3421
|
},
|
|
3410
3422
|
"docs": {
|
|
3411
3423
|
"text": "Receive all columns in data source",
|
|
@@ -277,7 +277,7 @@ export class RevogrFocus {
|
|
|
277
277
|
"mutable": false,
|
|
278
278
|
"complexType": {
|
|
279
279
|
"original": "Observable<DSourceState<ColumnRegular, DimensionCols>>",
|
|
280
|
-
"resolved": "\"colPinEnd\" | \"colPinStart\" | \"rgCol\" | ColumnRegular<ColumnProp
|
|
280
|
+
"resolved": "\"colPinEnd\" | \"colPinStart\" | \"rgCol\" | ColumnRegular<ColumnProp, DataType<any, ColumnProp>>",
|
|
281
281
|
"references": {
|
|
282
282
|
"Observable": {
|
|
283
283
|
"location": "import",
|
|
@@ -396,7 +396,7 @@ export class RevogrFocus {
|
|
|
396
396
|
},
|
|
397
397
|
"complexType": {
|
|
398
398
|
"original": "FocusAfterRenderEvent",
|
|
399
|
-
"resolved": "FocusAfterRenderEvent",
|
|
399
|
+
"resolved": "FocusAfterRenderEvent<DataType<any, ColumnProp>>",
|
|
400
400
|
"references": {
|
|
401
401
|
"FocusAfterRenderEvent": {
|
|
402
402
|
"location": "import",
|
|
@@ -103,5 +103,5 @@ export declare class RevogrData {
|
|
|
103
103
|
componentWillRender(): Promise<any[]>;
|
|
104
104
|
componentDidRender(): void;
|
|
105
105
|
render(): any;
|
|
106
|
-
triggerBeforeCellRender(model: CellTemplateProp, row: VirtualPositionItem, column: VirtualPositionItem): CustomEvent<BeforeCellRenderEvent<CellTemplateProp<DataType<any, import("@type").ColumnProp>, ColumnRegular<import("@type").ColumnProp
|
|
106
|
+
triggerBeforeCellRender(model: CellTemplateProp, row: VirtualPositionItem, column: VirtualPositionItem): CustomEvent<BeforeCellRenderEvent<CellTemplateProp<DataType<any, import("@type").ColumnProp>, ColumnRegular<import("@type").ColumnProp, DataType<any, import("@type").ColumnProp>>, import("@type").ColumnProp>>>;
|
|
107
107
|
}
|
|
@@ -12,7 +12,7 @@ export default class ColumnDataProvider {
|
|
|
12
12
|
getRawColumns(): Record<DimensionCols, ColumnRegular[]>;
|
|
13
13
|
getColumns(type?: DimensionCols | 'all'): ColumnRegular[];
|
|
14
14
|
getColumnIndexByProp(prop: ColumnProp, type: DimensionCols): number;
|
|
15
|
-
getColumnByProp(prop: ColumnProp): ColumnRegular<ColumnProp
|
|
15
|
+
getColumnByProp(prop: ColumnProp): ColumnRegular<ColumnProp, import("@type").DataType<any, ColumnProp>>[] | undefined;
|
|
16
16
|
refreshByType(type: DimensionCols): void;
|
|
17
17
|
/**
|
|
18
18
|
* Main method to set columns
|
|
@@ -112,20 +112,20 @@ export type ColumnTypes = {
|
|
|
112
112
|
/**
|
|
113
113
|
* Interface for custom cell renderer.
|
|
114
114
|
*/
|
|
115
|
-
export interface CellTemplate {
|
|
116
|
-
(createElement: HyperFunc<VNode>, props: CellTemplateProp
|
|
115
|
+
export interface CellTemplate<TModel extends DataType = DataType> {
|
|
116
|
+
(createElement: HyperFunc<VNode>, props: CellTemplateProp<TModel>, additionalData?: any): any;
|
|
117
117
|
}
|
|
118
118
|
/**
|
|
119
119
|
* Interface for regular column definition.
|
|
120
120
|
* Regular column can be any column that is not a grouping column.
|
|
121
121
|
*/
|
|
122
|
-
export interface ColumnType extends ColumnProperties {
|
|
122
|
+
export interface ColumnType<TModel extends DataType = DataType> extends ColumnProperties {
|
|
123
123
|
/**
|
|
124
124
|
* Represents whether the column or cell is read-only.
|
|
125
125
|
* Can be a boolean or a function that returns a boolean.
|
|
126
126
|
* The function receives column data as a parameter.
|
|
127
127
|
*/
|
|
128
|
-
readonly?: ReadOnlyFormat
|
|
128
|
+
readonly?: ReadOnlyFormat<TModel>;
|
|
129
129
|
/**
|
|
130
130
|
* Represents the default column size.
|
|
131
131
|
*/
|
|
@@ -148,20 +148,20 @@ export interface ColumnType extends ColumnProperties {
|
|
|
148
148
|
/**
|
|
149
149
|
* Represents cell properties for custom styling, classes, and events.
|
|
150
150
|
*/
|
|
151
|
-
cellProperties?: PropertiesFunc
|
|
151
|
+
cellProperties?: PropertiesFunc<TModel>;
|
|
152
152
|
/**
|
|
153
153
|
* Represents the cell template for custom rendering.
|
|
154
154
|
*/
|
|
155
|
-
cellTemplate?: CellTemplate
|
|
155
|
+
cellTemplate?: CellTemplate<TModel>;
|
|
156
156
|
/**
|
|
157
157
|
* Represents the cell compare function for custom sorting.
|
|
158
158
|
*/
|
|
159
|
-
cellCompare?: CellCompareFunc
|
|
159
|
+
cellCompare?: CellCompareFunc<TModel>;
|
|
160
160
|
/**
|
|
161
161
|
* Represents the cell value parse function for custom parsing.
|
|
162
162
|
* Currently only used for filtering.
|
|
163
163
|
*/
|
|
164
|
-
cellParser?: (model:
|
|
164
|
+
cellParser?: (model: TModel, column: ColumnRegular<ColumnProp, TModel>) => any;
|
|
165
165
|
}
|
|
166
166
|
export type Order = 'asc' | 'desc' | undefined;
|
|
167
167
|
/**
|
|
@@ -173,7 +173,7 @@ export type Order = 'asc' | 'desc' | undefined;
|
|
|
173
173
|
* ColumnRegular interface represents regular column definition.
|
|
174
174
|
* Regular column can be any column that is not a grouping column.
|
|
175
175
|
*/
|
|
176
|
-
export interface ColumnRegular<P extends ColumnProp = ColumnProp> extends ColumnType {
|
|
176
|
+
export interface ColumnRegular<P extends ColumnProp = ColumnProp, TModel extends DataType = DataType> extends ColumnType<TModel> {
|
|
177
177
|
/**
|
|
178
178
|
* Column prop used for mapping value to cell from data source model/row, used for indexing.
|
|
179
179
|
*/
|
|
@@ -205,7 +205,7 @@ export interface ColumnRegular<P extends ColumnProp = ColumnProp> extends Column
|
|
|
205
205
|
/**
|
|
206
206
|
* Is cell in column or individual can be dragged.
|
|
207
207
|
*/
|
|
208
|
-
rowDrag?: RowDrag
|
|
208
|
+
rowDrag?: RowDrag<TModel>;
|
|
209
209
|
/**
|
|
210
210
|
* Represents type defined in columnTypes property through grid config.
|
|
211
211
|
*/
|
|
@@ -213,7 +213,7 @@ export interface ColumnRegular<P extends ColumnProp = ColumnProp> extends Column
|
|
|
213
213
|
/**
|
|
214
214
|
* Function called before column applied to the store.
|
|
215
215
|
*/
|
|
216
|
-
beforeSetup?(rgCol: ColumnRegular): void;
|
|
216
|
+
beforeSetup?(rgCol: ColumnRegular<P, TModel>): void;
|
|
217
217
|
/**
|
|
218
218
|
* Additional properties can be added to the column definition.
|
|
219
219
|
*/
|
|
@@ -370,10 +370,28 @@ export type FocusTemplateFunc = (createElement: HyperFunc<VNode>, detail: FocusR
|
|
|
370
370
|
* the data of the first cell, and the data of the second cell. It returns a
|
|
371
371
|
* number indicating the relative order of the two cells.
|
|
372
372
|
*/
|
|
373
|
-
export type CellCompareFunc = (prop: ColumnProp, a:
|
|
373
|
+
export type CellCompareFunc<TModel extends DataType = DataType> = (prop: ColumnProp, a: TModel, b: TModel) => number;
|
|
374
374
|
export type ColumnTemplateFunc = (createElement: HyperFunc<VNode>, props: ColumnTemplateProp, additionalData?: any) => any;
|
|
375
|
-
export type PropertiesFunc = (props: CellTemplateProp) => CellProps | void | undefined;
|
|
375
|
+
export type PropertiesFunc<TModel extends DataType = DataType> = (props: CellTemplateProp<TModel>) => CellProps | void | undefined;
|
|
376
376
|
export type ColPropertiesFunc = (props: ColumnPropProp) => CellProps | void | undefined;
|
|
377
|
+
/**
|
|
378
|
+
* Represents a generic row data object used internally by the grid.
|
|
379
|
+
*
|
|
380
|
+
* @typeParam D - Value type for all properties (defaults to `any`).
|
|
381
|
+
* @typeParam K - Column property keys (defaults to `ColumnProp`).
|
|
382
|
+
*
|
|
383
|
+
* For type-safe usage, define your own row interface and pass it
|
|
384
|
+
* directly as the data source. Use `ColumnRegular` generics to
|
|
385
|
+
* bind column definitions to your row type:
|
|
386
|
+
* ```ts
|
|
387
|
+
* type MyRow = { id: number; name: string };
|
|
388
|
+
* const source: MyRow[] = [{ id: 1, name: 'Alice' }];
|
|
389
|
+
* const columns: ColumnRegular<keyof MyRow, MyRow>[] = [
|
|
390
|
+
* { prop: 'id', name: 'ID' },
|
|
391
|
+
* { prop: 'name', name: 'Name' },
|
|
392
|
+
* ];
|
|
393
|
+
* ```
|
|
394
|
+
*/
|
|
377
395
|
export type DataType<D = any, K extends ColumnProp = ColumnProp> = {
|
|
378
396
|
[T in K]: DataFormat<D>;
|
|
379
397
|
};
|
|
@@ -714,8 +732,8 @@ export interface FocusRenderEvent extends AllDimensionType {
|
|
|
714
732
|
*/
|
|
715
733
|
next?: Partial<Cell>;
|
|
716
734
|
}
|
|
717
|
-
export interface FocusAfterRenderEvent extends AllDimensionType {
|
|
718
|
-
model?:
|
|
735
|
+
export interface FocusAfterRenderEvent<TModel extends DataType = DataType> extends AllDimensionType {
|
|
736
|
+
model?: TModel;
|
|
719
737
|
column?: ColumnRegular;
|
|
720
738
|
/**
|
|
721
739
|
* Virtual index of the row in the viewport
|
|
@@ -744,9 +762,13 @@ export type ScrollCoordinateEvent = {
|
|
|
744
762
|
coordinate: number;
|
|
745
763
|
};
|
|
746
764
|
/** Range paste. */
|
|
747
|
-
export interface RangeClipboardPasteEvent extends AllDimensionType {
|
|
748
|
-
data:
|
|
749
|
-
|
|
765
|
+
export interface RangeClipboardPasteEvent<TModel extends DataType = DataType> extends AllDimensionType {
|
|
766
|
+
data: {
|
|
767
|
+
[rowIndex: number]: TModel;
|
|
768
|
+
};
|
|
769
|
+
models: {
|
|
770
|
+
[rowIndex: number]: TModel | undefined;
|
|
771
|
+
};
|
|
750
772
|
range: RangeArea | null;
|
|
751
773
|
}
|
|
752
774
|
/** Range copy. */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type VNode } from '../stencil-public-runtime';
|
|
2
2
|
import type { DimensionRows, DimensionCols } from './dimension';
|
|
3
|
-
import type { ColumnProp,
|
|
3
|
+
import type { ColumnProp, ColumnRegular, DataType, HyperFunc, ColumnDataSchemaModel, PositionItem } from './interfaces';
|
|
4
4
|
export type RowIndex = number;
|
|
5
5
|
export type ColIndex = number;
|
|
6
6
|
/**
|
|
@@ -91,28 +91,32 @@ export type SaveDataDetails = {
|
|
|
91
91
|
preventFocus?: boolean;
|
|
92
92
|
};
|
|
93
93
|
export type BeforeEdit = BeforeSaveDataDetails;
|
|
94
|
-
export type RowDragStartDetails = {
|
|
94
|
+
export type RowDragStartDetails<TModel extends DataType = DataType> = {
|
|
95
95
|
cell: Cell;
|
|
96
96
|
text: string;
|
|
97
97
|
pos: PositionItem;
|
|
98
98
|
event: MouseEvent;
|
|
99
99
|
rowType: DimensionRows;
|
|
100
|
-
model:
|
|
100
|
+
model: TModel;
|
|
101
101
|
};
|
|
102
|
-
export interface BeforeSaveDataDetails extends ColumnDataSchemaModel {
|
|
102
|
+
export interface BeforeSaveDataDetails<TModel extends DataType = DataType, TColumn extends ColumnRegular = ColumnRegular> extends ColumnDataSchemaModel<TModel, TColumn> {
|
|
103
103
|
/**
|
|
104
104
|
* Value from editor to save, not part of the model value yet
|
|
105
105
|
*/
|
|
106
106
|
val?: any;
|
|
107
107
|
}
|
|
108
|
-
export type BeforeRangeSaveDataDetails = {
|
|
109
|
-
data:
|
|
110
|
-
|
|
108
|
+
export type BeforeRangeSaveDataDetails<TModel extends DataType = DataType> = {
|
|
109
|
+
data: {
|
|
110
|
+
[rowIndex: number]: TModel;
|
|
111
|
+
};
|
|
112
|
+
models: {
|
|
113
|
+
[rowIndex: number]: TModel | undefined;
|
|
114
|
+
};
|
|
111
115
|
type: DimensionRows;
|
|
112
116
|
newRange: RangeArea | null;
|
|
113
117
|
oldRange: RangeArea | null;
|
|
114
118
|
};
|
|
115
|
-
export type AfterEditEvent = BeforeRangeSaveDataDetails | BeforeSaveDataDetails
|
|
119
|
+
export type AfterEditEvent<TModel extends DataType = DataType> = BeforeRangeSaveDataDetails<TModel> | BeforeSaveDataDetails<TModel>;
|
|
116
120
|
/**
|
|
117
121
|
* Edit cell info for store
|
|
118
122
|
*/
|