ms-data-grid 0.0.42 → 0.0.44
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/esm2022/lib/data-grid/data-grid.component.mjs +1056 -1910
- package/esm2022/lib/data-grid/statuses.mjs +2 -3
- package/esm2022/lib/data-grid.module.mjs +9 -9
- package/esm2022/lib/data-grid.service.mjs +14 -0
- package/esm2022/lib/directives/draggable-header.directive.mjs +148 -0
- package/esm2022/lib/pipes/filter.pipe.mjs +4 -4
- package/esm2022/lib/services/common.service.mjs +18 -48
- package/esm2022/lib/services/copy-service.service.mjs +10 -11
- package/esm2022/lib/services/split-columns.service.mjs +4 -4
- package/esm2022/lib/services/swap-columns.service.mjs +118 -0
- package/esm2022/public-api.mjs +3 -1
- package/fesm2022/ms-data-grid.mjs +1356 -2115
- package/fesm2022/ms-data-grid.mjs.map +1 -1
- package/lib/data-grid/data-grid.component.d.ts +39 -99
- package/lib/data-grid.module.d.ts +7 -6
- package/lib/data-grid.service.d.ts +6 -0
- package/lib/directives/draggable-header.directive.d.ts +31 -0
- package/lib/services/swap-columns.service.d.ts +19 -0
- package/package.json +2 -8
- package/public-api.d.ts +2 -0
- package/esm2022/lib/services/export.service.mjs +0 -149
- package/lib/services/export.service.d.ts +0 -24
|
@@ -1,23 +1,20 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { OnChanges, SimpleChanges, ElementRef, AfterViewInit, ChangeDetectorRef, EventEmitter, NgZone } from '@angular/core';
|
|
2
2
|
import { SplitColumnsService } from '../services/split-columns.service';
|
|
3
3
|
import { CommonService } from '../services/common.service';
|
|
4
|
+
import { SwapColumnsService } from '../services/swap-columns.service';
|
|
4
5
|
import { CdkDrag, CdkDragDrop, CdkDragEnter, CdkDragExit, CdkDragMove, CdkDragSortEvent } from '@angular/cdk/drag-drop';
|
|
5
6
|
import { CdkDropList } from '@angular/cdk/drag-drop';
|
|
6
7
|
import { CopyServiceService } from '../services/copy-service.service';
|
|
7
|
-
import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
|
|
8
|
-
import { ExportService } from '../services/export.service';
|
|
9
8
|
import * as i0 from "@angular/core";
|
|
10
9
|
export declare const sortingAnimation: import("@angular/animations").AnimationTriggerMetadata;
|
|
11
|
-
export declare class DataGridComponent implements OnChanges, AfterViewInit
|
|
10
|
+
export declare class DataGridComponent implements OnChanges, AfterViewInit {
|
|
12
11
|
private columnService;
|
|
13
12
|
cdr: ChangeDetectorRef;
|
|
14
13
|
commonSevice: CommonService;
|
|
14
|
+
private swapColumnService;
|
|
15
15
|
private elementRef;
|
|
16
16
|
private ngZone;
|
|
17
17
|
private copyService;
|
|
18
|
-
private renderer;
|
|
19
|
-
private sanitizer;
|
|
20
|
-
private exportService;
|
|
21
18
|
paginationConfig: any;
|
|
22
19
|
dataSet: any[];
|
|
23
20
|
columns: any[];
|
|
@@ -36,14 +33,12 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
36
33
|
sidemenuBackgroundColor: string | undefined;
|
|
37
34
|
bodyTextColor: string | undefined;
|
|
38
35
|
headerTextColor: string | undefined;
|
|
39
|
-
checkboxesColor: string | undefined;
|
|
40
36
|
headerTextFontsSize: number | undefined;
|
|
41
37
|
bodyTextFontsSize: number | undefined;
|
|
42
38
|
headerFontWeight: number | undefined;
|
|
43
39
|
bodyFontWeight: number | undefined;
|
|
44
40
|
checkedRowBackgroundColor: string | undefined;
|
|
45
41
|
dropdownsBackgroundColor: string | undefined;
|
|
46
|
-
footerRowBackgroundColor: string | undefined;
|
|
47
42
|
footerRowHeight: number;
|
|
48
43
|
topGroupedBadgesBackgroundColor: string | undefined;
|
|
49
44
|
showRowsGrouping: boolean | undefined;
|
|
@@ -92,31 +87,19 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
92
87
|
leftPinnedBoxshadow: string;
|
|
93
88
|
rightPinnedBoxshadow: string;
|
|
94
89
|
selectedRowsBackgroundColor: string;
|
|
95
|
-
|
|
96
|
-
nestedTableRowBackgroundColor: string;
|
|
90
|
+
nestedTableHeaderBAckgroundColor: string;
|
|
97
91
|
tableView: any[];
|
|
98
|
-
buttons: {
|
|
99
|
-
name: string;
|
|
100
|
-
is_showIcon: boolean;
|
|
101
|
-
icon: string;
|
|
102
|
-
}[];
|
|
103
92
|
keepMultipleExpandedDetails: boolean;
|
|
104
93
|
showTotalAmountRow: boolean;
|
|
105
|
-
enableGlobalSearch: boolean;
|
|
106
94
|
tableType: string;
|
|
107
|
-
|
|
108
|
-
enableCut: boolean;
|
|
109
|
-
tabs: string[];
|
|
110
|
-
resetAllFilters: {
|
|
111
|
-
resetAll: boolean;
|
|
112
|
-
};
|
|
95
|
+
widgets: any[];
|
|
113
96
|
columnThreedotsMunuConfig: {
|
|
114
97
|
showPinleft: boolean;
|
|
115
98
|
showPinright: boolean;
|
|
116
99
|
showAscending: boolean;
|
|
117
100
|
showDescending: boolean;
|
|
118
101
|
showFilter: boolean;
|
|
119
|
-
showRowsGrouping: boolean
|
|
102
|
+
showRowsGrouping: boolean;
|
|
120
103
|
showAutosizeAllColumns: boolean;
|
|
121
104
|
showAutosizeThisColumn: boolean;
|
|
122
105
|
showChoseColumns: boolean;
|
|
@@ -128,7 +111,6 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
128
111
|
tablePresetConfig: EventEmitter<any>;
|
|
129
112
|
sortingOrderOptions: EventEmitter<any>;
|
|
130
113
|
createUpdateConfigListing: EventEmitter<any>;
|
|
131
|
-
activeTab: string | null;
|
|
132
114
|
groupedColumns: any[];
|
|
133
115
|
activeCol: any;
|
|
134
116
|
activeFilterCell: any;
|
|
@@ -144,29 +126,22 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
144
126
|
filterColumnsList: any[];
|
|
145
127
|
groupBoxPadding: number;
|
|
146
128
|
presetName: string;
|
|
147
|
-
presetFilter:
|
|
129
|
+
presetFilter: any;
|
|
148
130
|
searchTextPresetTable: string;
|
|
149
131
|
addFilterColumnInput: string;
|
|
150
132
|
searchInDropdown: string;
|
|
151
133
|
addFilterDropdownSearch: string;
|
|
152
134
|
topShowHideColumns: string;
|
|
153
135
|
choseColumnsSearch: string;
|
|
154
|
-
sideNestedFilterSearch: string;
|
|
155
136
|
editinDropdownSearch: string;
|
|
156
137
|
isThreeDotsFilterOpen: boolean;
|
|
157
138
|
confirmDelete: boolean;
|
|
158
139
|
fontFamilies: string[];
|
|
159
140
|
fontSizes: string[];
|
|
160
|
-
|
|
161
|
-
constructor(columnService: SplitColumnsService, cdr: ChangeDetectorRef, commonSevice: CommonService, elementRef: ElementRef, ngZone: NgZone, copyService: CopyServiceService, renderer: Renderer2, sanitizer: DomSanitizer, exportService: ExportService);
|
|
141
|
+
constructor(columnService: SplitColumnsService, cdr: ChangeDetectorRef, commonSevice: CommonService, swapColumnService: SwapColumnsService, elementRef: ElementRef, ngZone: NgZone, copyService: CopyServiceService);
|
|
162
142
|
cellText: ElementRef;
|
|
163
|
-
|
|
164
|
-
ngAfterViewInit(): void;
|
|
165
|
-
ngAfterViewChecked(): void;
|
|
166
|
-
ngOnInit(): void;
|
|
143
|
+
ngAfterViewInit(): Promise<void>;
|
|
167
144
|
ngOnChanges(changes: SimpleChanges): Promise<void>;
|
|
168
|
-
applyRowsSelectionState(): void;
|
|
169
|
-
clearSelectionState(tableType: string): void;
|
|
170
145
|
applyFilteroptionList(): Promise<void>;
|
|
171
146
|
leftPinnedColumns: any[];
|
|
172
147
|
centerColumns: any[];
|
|
@@ -175,8 +150,6 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
175
150
|
previewCenterColumns: any[];
|
|
176
151
|
previewRightPinnedColumns: any[];
|
|
177
152
|
dataGridContainer: ElementRef<HTMLDivElement>;
|
|
178
|
-
taskManagementContainer: ElementRef<HTMLDivElement>;
|
|
179
|
-
nestedTableContainer: ElementRef<HTMLDivElement>;
|
|
180
153
|
leftPinnedBody: ElementRef<HTMLDivElement>;
|
|
181
154
|
centerPinnedBody: ElementRef<HTMLDivElement>;
|
|
182
155
|
rightPinnedBody: ElementRef<HTMLDivElement>;
|
|
@@ -189,15 +162,16 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
189
162
|
refreshPreviewColumns(columns?: any): Promise<void>;
|
|
190
163
|
SetColumnsDefaultWidth(): Promise<void>;
|
|
191
164
|
setSectionsWidth(): void;
|
|
165
|
+
onLeftBodyScroll(): void;
|
|
166
|
+
onRightBodyScroll(): void;
|
|
192
167
|
fakeScrollbarScrollLeft: number;
|
|
168
|
+
onFakeScroll(event: Event): void;
|
|
193
169
|
getNestedValue(obj: any, field: string): any;
|
|
194
170
|
isNestedValueArray(obj: any, field: string): boolean;
|
|
195
171
|
onResizeGroup(event: MouseEvent, col: any, isRightPinned?: boolean): void;
|
|
196
172
|
private updateColumnWidthInSourceByField;
|
|
197
|
-
cleanColumns(columns: any[]): any[];
|
|
198
173
|
onResizeColumn(event: MouseEvent, col: any): void;
|
|
199
174
|
onResizeGroupBox(event: MouseEvent): void;
|
|
200
|
-
onPasteInFilterRowSearch(event: ClipboardEvent, col: any): void;
|
|
201
175
|
onFilterChange(col: any): void;
|
|
202
176
|
get bodyWrapperHeight(): string;
|
|
203
177
|
hoveredRowId: string | number | null;
|
|
@@ -208,11 +182,11 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
208
182
|
closeFilterDropdowns(event: MouseEvent): void;
|
|
209
183
|
private hasParentWithClass;
|
|
210
184
|
isMenueHidden: boolean;
|
|
211
|
-
openThreeDotsMenu(event: MouseEvent, child: any
|
|
185
|
+
openThreeDotsMenu(event: MouseEvent, child: any): void;
|
|
212
186
|
sortAsc(col: any): void;
|
|
213
187
|
sortDesc(col: any): void;
|
|
214
188
|
resetSort(col: any): void;
|
|
215
|
-
updateColumnPinInSourceByField(column: any, pinned: 'left' | 'right' | null
|
|
189
|
+
updateColumnPinInSourceByField(column: any, pinned: 'left' | 'right' | null): Promise<void>;
|
|
216
190
|
autosizeColumn(cols: any | any[]): void;
|
|
217
191
|
getGroupWidth(group: any): number;
|
|
218
192
|
autosizeAllColumns(): void;
|
|
@@ -282,10 +256,10 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
282
256
|
private fakeScrollRaf;
|
|
283
257
|
translateY: number;
|
|
284
258
|
lastScrollTop: number;
|
|
285
|
-
pendingAnimationFrame: number | null;
|
|
286
259
|
onMainScroll(event: Event): void;
|
|
287
260
|
get isScrollbarVisible(): boolean;
|
|
288
261
|
toggleExpand(row: any): void;
|
|
262
|
+
onMainFakeScroll(event: Event): void;
|
|
289
263
|
viewportRows: number;
|
|
290
264
|
firstIndex: number;
|
|
291
265
|
renderStart: number;
|
|
@@ -294,17 +268,19 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
294
268
|
mainScroll: ElementRef<HTMLDivElement>;
|
|
295
269
|
fakeScroll: ElementRef<HTMLDivElement>;
|
|
296
270
|
horizintalFakeScroll: ElementRef<HTMLDivElement>;
|
|
297
|
-
centerScrollableBody: ElementRef<
|
|
271
|
+
centerScrollableBody: ElementRef<any>;
|
|
298
272
|
private overscan;
|
|
299
273
|
computeViewportRows(): void;
|
|
300
|
-
|
|
274
|
+
onHorizintalFakeScroll(event: Event): void;
|
|
301
275
|
onCenterBodyScroll(event: Event): void;
|
|
302
276
|
onCenterHeaderScroll(event: Event): void;
|
|
303
277
|
draggingColumn: any;
|
|
304
278
|
dragStartIndex: any;
|
|
305
279
|
canEnterToRowsGrouping: (drag: CdkDrag<any>, drop: CdkDropList<any>) => any;
|
|
280
|
+
onDragMoved(event: CdkDragMove<any>): void;
|
|
306
281
|
enterToTopRowGrouping(dropList: CdkDragEnter<any>): void;
|
|
307
282
|
onDropListEnter(dropList: CdkDragEnter<any>, section: 'left' | 'center' | 'right'): void;
|
|
283
|
+
enterToTopGroupingRow(dropList: CdkDragEnter<any>): void;
|
|
308
284
|
exitedFromTheTopRow(dropList: CdkDragExit<any>): void;
|
|
309
285
|
shouldDisableDroplistSorting: boolean;
|
|
310
286
|
isDisableColumnGrouping: boolean;
|
|
@@ -314,9 +290,11 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
314
290
|
onSortGroup: (event: CdkDragSortEvent<any>, section: string) => Promise<void>;
|
|
315
291
|
onDropGroup(): void;
|
|
316
292
|
onDropTopGroup(event: CdkDragDrop<any>): Promise<void>;
|
|
317
|
-
onGroupReorder(event: CdkDragDrop<any[]>): Promise<void>;
|
|
318
293
|
ungroupColumn(column: any): Promise<void>;
|
|
319
294
|
shouldTheGroupHeaderShow(group: any): any;
|
|
295
|
+
onChildDragStart(): void;
|
|
296
|
+
dropListIds: string[];
|
|
297
|
+
generateDropListIds(): void;
|
|
320
298
|
onChildDroplistSorted: (event: CdkDragSortEvent<any>, section: string) => Promise<void>;
|
|
321
299
|
onChildDroplistDroped(cdkDragDropevent: CdkDragDrop<any>): void;
|
|
322
300
|
groupData(data: any[], groupFields: string[]): any[];
|
|
@@ -342,12 +320,11 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
342
320
|
isFilterOpen: boolean;
|
|
343
321
|
selectedColumnForFilter: any;
|
|
344
322
|
showFilters: boolean;
|
|
345
|
-
openFilterFromDisabledSearchedInput(col: any): void;
|
|
346
323
|
openFilter(col: any): void;
|
|
347
324
|
firstValue: any;
|
|
348
325
|
firstCondition: string;
|
|
349
326
|
secondValue: any;
|
|
350
|
-
secondCondition:
|
|
327
|
+
secondCondition: string;
|
|
351
328
|
condition: string;
|
|
352
329
|
resetTextFilterChanges(): void;
|
|
353
330
|
toggleAllValusSelectionInDropdownFilter(column: any): void;
|
|
@@ -362,9 +339,7 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
362
339
|
onOptionToggle(col: any, option: any): void;
|
|
363
340
|
resetSideFilter(col: any): void;
|
|
364
341
|
clearAllFilters(): void;
|
|
365
|
-
applySideFilter(
|
|
366
|
-
removeSideFilter(column: any): void;
|
|
367
|
-
collapseAllExpandedCells(): void;
|
|
342
|
+
applySideFilter(): void;
|
|
368
343
|
trackByField(index: number, col: any): string;
|
|
369
344
|
get activeFilteredColumns(): any[];
|
|
370
345
|
toggleOpenFilter(): void;
|
|
@@ -372,7 +347,6 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
372
347
|
activeCell: string | null;
|
|
373
348
|
setActiveCell(row: any, column: any): void;
|
|
374
349
|
isActiveCell(row: any, col: any): boolean;
|
|
375
|
-
textAreadInput: ElementRef<HTMLTextAreaElement>;
|
|
376
350
|
enableEdit(row: any, column: any, clickedFromDetailsBox?: boolean, cellContainer?: HTMLElement): void;
|
|
377
351
|
disableEdit(row: any, column: any, control?: any): void;
|
|
378
352
|
emailRegex: RegExp;
|
|
@@ -384,14 +358,9 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
384
358
|
goToPage(page: any): void;
|
|
385
359
|
onPageSizeChange(): void;
|
|
386
360
|
actionPreset(data: any, type: any): void;
|
|
387
|
-
|
|
388
|
-
curretaTablePresetForUpdate: any;
|
|
389
|
-
temp_state: {
|
|
390
|
-
id: string;
|
|
391
|
-
is_temp: boolean;
|
|
392
|
-
};
|
|
393
|
-
selectFilter(data: any): Promise<void>;
|
|
361
|
+
selectFilter(data: any): void;
|
|
394
362
|
savePreset(control?: any): void;
|
|
363
|
+
getFilterHeaders(filters: any[], columns: any[]): string;
|
|
395
364
|
toggleRowShading(): void;
|
|
396
365
|
trackByTable(index: number): number;
|
|
397
366
|
activeRow: any;
|
|
@@ -399,9 +368,10 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
399
368
|
getCellKey(row: any, col: any): string;
|
|
400
369
|
expandedCells: Map<string, number>;
|
|
401
370
|
private zCounter;
|
|
402
|
-
showDetailsBox: boolean;
|
|
403
371
|
toggleExpandOfLongCellText(row: any, col: any, columns: any[], expandWholeRow?: boolean): void;
|
|
372
|
+
showDetailsBox: boolean;
|
|
404
373
|
isOpenToTop(row: any, col: any): boolean;
|
|
374
|
+
collapseAllExpandedCells(): void;
|
|
405
375
|
isExpanded(row: any, col: any): boolean;
|
|
406
376
|
getZIndex(row: any, col: any): number;
|
|
407
377
|
isOverflowing(element: HTMLElement | null): boolean;
|
|
@@ -421,11 +391,10 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
421
391
|
getCellClasses(column: any, value: any): string;
|
|
422
392
|
removeColumnFilterFromColumn(column: any): void;
|
|
423
393
|
onSideMenuColumnsVisibilityChange(): void;
|
|
424
|
-
|
|
425
|
-
downloadCsv(type: 'csv' | 'xlsx'): void;
|
|
394
|
+
downloadCsv(): void;
|
|
426
395
|
onFontChange(): void;
|
|
427
396
|
onGlobalSearch(): void;
|
|
428
|
-
|
|
397
|
+
onInputChange(event: any): void;
|
|
429
398
|
checkFilterChangesEffect(): any;
|
|
430
399
|
selectedCells: any[];
|
|
431
400
|
selectedKeys: Set<string>;
|
|
@@ -480,10 +449,10 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
480
449
|
performCut(selectedData: any[][]): void;
|
|
481
450
|
getSelectedDataForCopy(): any[][];
|
|
482
451
|
onKeyDown(event: KeyboardEvent): void;
|
|
483
|
-
selectAllCells(): void;
|
|
484
452
|
undo(): void;
|
|
485
453
|
redo(): void;
|
|
486
|
-
onPaste
|
|
454
|
+
onPaste(event: ClipboardEvent): Promise<void>;
|
|
455
|
+
showConfirmationModal(message: string): Promise<boolean>;
|
|
487
456
|
isDate(value: any): boolean;
|
|
488
457
|
expandededDetailRows: (string | number)[] | string | number;
|
|
489
458
|
toggleDetailRowExpand(row: any): void;
|
|
@@ -493,45 +462,16 @@ export declare class DataGridComponent implements OnChanges, AfterViewInit, OnIn
|
|
|
493
462
|
toggleMenu(i: number, event?: MouseEvent): void;
|
|
494
463
|
nestedTable: ElementRef<HTMLDivElement>;
|
|
495
464
|
get hasVerticalScroll(): boolean;
|
|
496
|
-
|
|
497
|
-
getTotalAmount(column: any): string | undefined;
|
|
465
|
+
getTotalAmount(column: any): string;
|
|
498
466
|
dropColumn(event: CdkDragDrop<any[]>, row: any): void;
|
|
499
467
|
currentSubSortColumn: string | null;
|
|
500
468
|
currentSortDirection: 'asc' | 'desc';
|
|
501
|
-
sortNestedCol(col: any,
|
|
469
|
+
sortNestedCol(col: any, dataSet?: any[]): void;
|
|
502
470
|
getColumnWidthPx(row: any, col: any): string;
|
|
503
471
|
fullscreenImage: string | null;
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
getStickyLeft(columns: any[], index: number): string;
|
|
508
|
-
previewNestedCols: any[];
|
|
509
|
-
onNestedColSort(event: CdkDragSortEvent<any[]>, columns: any[]): void;
|
|
510
|
-
saveSelection(selectedIds: string[], tableType: string): void;
|
|
511
|
-
restoreSelection(tableType: string): Set<string>;
|
|
512
|
-
isOutsideContainer: boolean;
|
|
513
|
-
private containerRect;
|
|
514
|
-
onDragStarted(col: any): void;
|
|
515
|
-
onDragMoved(event: CdkDragMove): void;
|
|
516
|
-
onDragEnded(): void;
|
|
517
|
-
getStartIndex(): number;
|
|
518
|
-
hasAnyDefaultView(): boolean;
|
|
519
|
-
get isTablePresetNotChanged(): any;
|
|
520
|
-
onActionButtonClick(button: string): void;
|
|
521
|
-
setActiveTab(tab: string): void;
|
|
522
|
-
getBackgroundColor(row: any, isEven: boolean, section: 'left' | 'center' | 'right'): string | undefined;
|
|
523
|
-
hasHorizontalScrollbar(): boolean;
|
|
524
|
-
getSafeComment(description: string): SafeHtml;
|
|
525
|
-
cleanEditorContent(content: string): SafeHtml;
|
|
526
|
-
getExtention(url: string | string[] | null | undefined): string | undefined;
|
|
527
|
-
downloadAttchment(url: any, file?: any): void;
|
|
528
|
-
fullImageSrc: string | null;
|
|
529
|
-
openFullImage(event: Event): void;
|
|
530
|
-
addStylesToImages(): void;
|
|
531
|
-
onImageClick(src: string): void;
|
|
532
|
-
fullscreenImageTemplate: TemplateRef<any>;
|
|
533
|
-
private fullscreenViewRef;
|
|
534
|
-
iconMap: Record<string, (row: any, col: any) => string>;
|
|
472
|
+
openFullScreenImage(src: string): void;
|
|
473
|
+
getVisibleColumnCount(columns: any[]): number;
|
|
474
|
+
clearSelection(): void;
|
|
535
475
|
static ɵfac: i0.ɵɵFactoryDeclaration<DataGridComponent, never>;
|
|
536
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<DataGridComponent, "data-grid", never, { "paginationConfig": { "alias": "paginationConfig"; "required": false; }; "dataSet": { "alias": "dataSet"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "headerRowHeight": { "alias": "headerRowHeight"; "required": false; }; "showVerticalBorder": { "alias": "showVerticalBorder"; "required": false; }; "evenRowsBackgroundColor": { "alias": "evenRowsBackgroundColor"; "required": false; }; "oddRowsBackgroundColor": { "alias": "oddRowsBackgroundColor"; "required": false; }; "headerBackgroundColor": { "alias": "headerBackgroundColor"; "required": false; }; "checkboxesBackgroundColor": { "alias": "checkboxesBackgroundColor"; "required": false; }; "showColumnsGrouping": { "alias": "showColumnsGrouping"; "required": false; }; "rowHoverColor": { "alias": "rowHoverColor"; "required": false; }; "leftPinnedBackgroundColor": { "alias": "leftPinnedBackgroundColor"; "required": false; }; "bodyBackgroundColor": { "alias": "bodyBackgroundColor"; "required": false; }; "rightPinnedBackgroundColor": { "alias": "rightPinnedBackgroundColor"; "required": false; }; "sidemenuBackgroundColor": { "alias": "sidemenuBackgroundColor"; "required": false; }; "bodyTextColor": { "alias": "bodyTextColor"; "required": false; }; "headerTextColor": { "alias": "headerTextColor"; "required": false; }; "
|
|
476
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DataGridComponent, "data-grid", never, { "paginationConfig": { "alias": "paginationConfig"; "required": false; }; "dataSet": { "alias": "dataSet"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "headerRowHeight": { "alias": "headerRowHeight"; "required": false; }; "showVerticalBorder": { "alias": "showVerticalBorder"; "required": false; }; "evenRowsBackgroundColor": { "alias": "evenRowsBackgroundColor"; "required": false; }; "oddRowsBackgroundColor": { "alias": "oddRowsBackgroundColor"; "required": false; }; "headerBackgroundColor": { "alias": "headerBackgroundColor"; "required": false; }; "checkboxesBackgroundColor": { "alias": "checkboxesBackgroundColor"; "required": false; }; "showColumnsGrouping": { "alias": "showColumnsGrouping"; "required": false; }; "rowHoverColor": { "alias": "rowHoverColor"; "required": false; }; "leftPinnedBackgroundColor": { "alias": "leftPinnedBackgroundColor"; "required": false; }; "bodyBackgroundColor": { "alias": "bodyBackgroundColor"; "required": false; }; "rightPinnedBackgroundColor": { "alias": "rightPinnedBackgroundColor"; "required": false; }; "sidemenuBackgroundColor": { "alias": "sidemenuBackgroundColor"; "required": false; }; "bodyTextColor": { "alias": "bodyTextColor"; "required": false; }; "headerTextColor": { "alias": "headerTextColor"; "required": false; }; "headerTextFontsSize": { "alias": "headerTextFontsSize"; "required": false; }; "bodyTextFontsSize": { "alias": "bodyTextFontsSize"; "required": false; }; "headerFontWeight": { "alias": "headerFontWeight"; "required": false; }; "bodyFontWeight": { "alias": "bodyFontWeight"; "required": false; }; "checkedRowBackgroundColor": { "alias": "checkedRowBackgroundColor"; "required": false; }; "dropdownsBackgroundColor": { "alias": "dropdownsBackgroundColor"; "required": false; }; "footerRowHeight": { "alias": "footerRowHeight"; "required": false; }; "topGroupedBadgesBackgroundColor": { "alias": "topGroupedBadgesBackgroundColor"; "required": false; }; "showRowsGrouping": { "alias": "showRowsGrouping"; "required": false; }; "showFilterRow": { "alias": "showFilterRow"; "required": false; }; "fontFaimly": { "alias": "fontFaimly"; "required": false; }; "showSideMenu": { "alias": "showSideMenu"; "required": false; }; "footerPadding": { "alias": "footerPadding"; "required": false; }; "topFilterRowHeight": { "alias": "topFilterRowHeight"; "required": false; }; "rowShadingEnabled": { "alias": "rowShadingEnabled"; "required": false; }; "showSerialNumber": { "alias": "showSerialNumber"; "required": false; }; "singleSpaAssetsPath": { "alias": "singleSpaAssetsPath"; "required": false; }; "filtersConfig": { "alias": "filtersConfig"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "verticalScrollbarWidth": { "alias": "verticalScrollbarWidth"; "required": false; }; "horizintalScrollbarWidth": { "alias": "horizintalScrollbarWidth"; "required": false; }; "showCellDetailsBox": { "alias": "showCellDetailsBox"; "required": false; }; "dateFormat": { "alias": "dateFormat"; "required": false; }; "tableSearch": { "alias": "tableSearch"; "required": false; }; "actions": { "alias": "actions"; "required": false; }; "config": { "alias": "config"; "required": false; }; "showTaskbar": { "alias": "showTaskbar"; "required": false; }; "tableName": { "alias": "tableName"; "required": false; }; "listingType": { "alias": "listingType"; "required": false; }; "checkboxState": { "alias": "checkboxState"; "required": false; }; "taskbarActions": { "alias": "taskbarActions"; "required": false; }; "sortingConfig": { "alias": "sortingConfig"; "required": false; }; "tableFilterViewId": { "alias": "tableFilterViewId"; "required": false; }; "selectedTableLayout": { "alias": "selectedTableLayout"; "required": false; }; "closeDropdown": { "alias": "closeDropdown"; "required": false; }; "globalSearchText": { "alias": "globalSearchText"; "required": false; }; "nestedTablerowFontsize": { "alias": "nestedTablerowFontsize"; "required": false; }; "nestedTableHeaderRowHeight": { "alias": "nestedTableHeaderRowHeight"; "required": false; }; "nestedTablerowHeight": { "alias": "nestedTablerowHeight"; "required": false; }; "gridType": { "alias": "gridType"; "required": false; }; "currencySymbol": { "alias": "currencySymbol"; "required": false; }; "leftPinnedBoxshadow": { "alias": "leftPinnedBoxshadow"; "required": false; }; "rightPinnedBoxshadow": { "alias": "rightPinnedBoxshadow"; "required": false; }; "selectedRowsBackgroundColor": { "alias": "selectedRowsBackgroundColor"; "required": false; }; "nestedTableHeaderBAckgroundColor": { "alias": "nestedTableHeaderBAckgroundColor"; "required": false; }; "tableView": { "alias": "tableView"; "required": false; }; "keepMultipleExpandedDetails": { "alias": "keepMultipleExpandedDetails"; "required": false; }; "showTotalAmountRow": { "alias": "showTotalAmountRow"; "required": false; }; "tableType": { "alias": "tableType"; "required": false; }; "widgets": { "alias": "widgets"; "required": false; }; "columnThreedotsMunuConfig": { "alias": "columnThreedotsMunuConfig"; "required": false; }; }, { "changeLayout": "changeLayout"; "filterOptions": "filterOptions"; "genericEvent": "genericEvent"; "tablePresetConfig": "tablePresetConfig"; "sortingOrderOptions": "sortingOrderOptions"; "createUpdateConfigListing": "createUpdateConfigListing"; }, never, never, false, never>;
|
|
537
477
|
}
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
import * as i1 from "./data-grid/data-grid.component";
|
|
3
3
|
import * as i2 from "./pipes/filter.pipe";
|
|
4
|
-
import * as i3 from "
|
|
5
|
-
import * as i4 from "@angular/
|
|
6
|
-
import * as i5 from "@angular/
|
|
7
|
-
import * as i6 from "
|
|
8
|
-
import * as i7 from "
|
|
4
|
+
import * as i3 from "./directives/draggable-header.directive";
|
|
5
|
+
import * as i4 from "@angular/common";
|
|
6
|
+
import * as i5 from "@angular/forms";
|
|
7
|
+
import * as i6 from "@angular/cdk/drag-drop";
|
|
8
|
+
import * as i7 from "ng-inline-svg";
|
|
9
|
+
import * as i8 from "@angular/cdk/scrolling";
|
|
9
10
|
export declare class DataGridModule {
|
|
10
11
|
static ɵfac: i0.ɵɵFactoryDeclaration<DataGridModule, never>;
|
|
11
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<DataGridModule, [typeof i1.DataGridComponent, typeof i2.FilterPipe], [typeof
|
|
12
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<DataGridModule, [typeof i1.DataGridComponent, typeof i2.FilterPipe, typeof i3.DraggableHeaderDirective], [typeof i4.CommonModule, typeof i5.FormsModule, typeof i6.DragDropModule, typeof i7.InlineSVGModule, typeof i8.ScrollingModule], [typeof i1.DataGridComponent, typeof i3.DraggableHeaderDirective, typeof i7.InlineSVGModule]>;
|
|
12
13
|
static ɵinj: i0.ɵɵInjectorDeclaration<DataGridModule>;
|
|
13
14
|
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { ElementRef, EventEmitter, Renderer2 } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export interface DragMoveEvent {
|
|
4
|
+
event: MouseEvent;
|
|
5
|
+
data: any;
|
|
6
|
+
}
|
|
7
|
+
export declare class DraggableHeaderDirective {
|
|
8
|
+
private el;
|
|
9
|
+
private renderer;
|
|
10
|
+
column: any;
|
|
11
|
+
headerName: string;
|
|
12
|
+
dragStart: EventEmitter<any>;
|
|
13
|
+
dragMove: EventEmitter<any>;
|
|
14
|
+
dragEnd: EventEmitter<any>;
|
|
15
|
+
private isDragging;
|
|
16
|
+
private placeholderEl;
|
|
17
|
+
private previewEl;
|
|
18
|
+
constructor(el: ElementRef, renderer: Renderer2);
|
|
19
|
+
startX: number;
|
|
20
|
+
startY: number;
|
|
21
|
+
onMouseDown(event: MouseEvent): void;
|
|
22
|
+
onMouseMove: (event: MouseEvent) => void;
|
|
23
|
+
onMouseUp: (event: MouseEvent) => void;
|
|
24
|
+
private originalCursor;
|
|
25
|
+
private setCursor;
|
|
26
|
+
private resetCursor;
|
|
27
|
+
private startDragging;
|
|
28
|
+
overrideCursor(style: string): void;
|
|
29
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DraggableHeaderDirective, never>;
|
|
30
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<DraggableHeaderDirective, "[appDraggableHeader]", never, { "column": { "alias": "column"; "required": false; }; "headerName": { "alias": "headerName"; "required": false; }; }, { "dragStart": "dragStart"; "dragMove": "dragMove"; "dragEnd": "dragEnd"; }, never, never, false, never>;
|
|
31
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class SwapColumnsService {
|
|
3
|
+
constructor();
|
|
4
|
+
deepClone(obj: any): any;
|
|
5
|
+
flattenColumnsWithPaths(columns: any[]): {
|
|
6
|
+
col: any;
|
|
7
|
+
path: number[];
|
|
8
|
+
}[];
|
|
9
|
+
findColumnByIndex(columns: any[], index: number, flat: any[], _path?: number[][], currentPath?: number[]): {
|
|
10
|
+
column: any;
|
|
11
|
+
parent: any[];
|
|
12
|
+
path: number[];
|
|
13
|
+
} | null;
|
|
14
|
+
insertAtPath(columns: any[], path: number[], newColumn: any): any[];
|
|
15
|
+
removeAtPath(columns: any[], path: number[]): any[];
|
|
16
|
+
swapColumnsInTree(currentColumn: any, columns: any[], fromIndex: number, toIndex: number): any[];
|
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SwapColumnsService, never>;
|
|
18
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<SwapColumnsService>;
|
|
19
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ms-data-grid",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.44",
|
|
4
4
|
"description": "A powerful, customizable Angular data grid component with advanced features like sorting, filtering, pagination, column pinning, and taskbar actions. Perfect for enterprise applications.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|
|
@@ -26,13 +26,7 @@
|
|
|
26
26
|
"@angular/core": "^16.2.0"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"
|
|
30
|
-
"ng-inline-svg": "^13.1.1",
|
|
31
|
-
"ngx-bootstrap": "^20.0.0",
|
|
32
|
-
"bootstrap": "^5.3.7",
|
|
33
|
-
"tslib": "^2.3.0",
|
|
34
|
-
"file-saver": "^2.0.5",
|
|
35
|
-
"zone.js": "~0.13.0"
|
|
29
|
+
"tslib": "^2.3.0"
|
|
36
30
|
},
|
|
37
31
|
"sideEffects": false,
|
|
38
32
|
"module": "fesm2022/ms-data-grid.mjs",
|
package/public-api.d.ts
CHANGED