eru-grid 0.0.21 → 0.0.22-a
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/fesm2022/eru-grid.mjs +165 -63
- package/fesm2022/eru-grid.mjs.map +1 -1
- package/package.json +3 -3
- package/{index.d.ts → types/eru-grid.d.ts} +40 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eru-grid",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.22-a",
|
|
4
4
|
"peerDependencies": {
|
|
5
5
|
"@angular/common": "^20.1.3",
|
|
6
6
|
"@angular/core": "^20.1.3"
|
|
@@ -10,13 +10,13 @@
|
|
|
10
10
|
},
|
|
11
11
|
"sideEffects": false,
|
|
12
12
|
"module": "fesm2022/eru-grid.mjs",
|
|
13
|
-
"typings": "
|
|
13
|
+
"typings": "types/eru-grid.d.ts",
|
|
14
14
|
"exports": {
|
|
15
15
|
"./package.json": {
|
|
16
16
|
"default": "./package.json"
|
|
17
17
|
},
|
|
18
18
|
".": {
|
|
19
|
-
"types": "./
|
|
19
|
+
"types": "./types/eru-grid.d.ts",
|
|
20
20
|
"default": "./fesm2022/eru-grid.mjs"
|
|
21
21
|
}
|
|
22
22
|
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as eru_grid from 'eru-grid';
|
|
2
2
|
import * as _angular_core from '@angular/core';
|
|
3
|
-
import { OnInit, AfterViewInit, OnDestroy, ElementRef, ChangeDetectorRef } from '@angular/core';
|
|
3
|
+
import { OnInit, AfterViewInit, OnDestroy, ElementRef, ChangeDetectorRef, Provider } from '@angular/core';
|
|
4
4
|
import { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
|
|
5
|
+
import { MatCommonModule } from '@angular/material/core';
|
|
5
6
|
|
|
6
7
|
interface Row {
|
|
7
8
|
entity_id: string;
|
|
@@ -57,6 +58,9 @@ interface GridFeatures {
|
|
|
57
58
|
replaceZeroValue?: string;
|
|
58
59
|
gridHeight?: number;
|
|
59
60
|
allowSelection?: boolean;
|
|
61
|
+
actionColumn?: boolean;
|
|
62
|
+
actionColumnPosition?: 'before' | 'after';
|
|
63
|
+
actions?: string[];
|
|
60
64
|
}
|
|
61
65
|
interface GridStyles {
|
|
62
66
|
subTotalStyle?: 'bold' | 'italic' | 'highlighted';
|
|
@@ -184,6 +188,11 @@ interface RowDataResponse {
|
|
|
184
188
|
hasMore: boolean;
|
|
185
189
|
totalCount?: number;
|
|
186
190
|
}
|
|
191
|
+
interface ActionClick {
|
|
192
|
+
rowId: string;
|
|
193
|
+
rowData?: any;
|
|
194
|
+
actionName?: string;
|
|
195
|
+
}
|
|
187
196
|
|
|
188
197
|
declare class PivotTransformService {
|
|
189
198
|
private columnGroupState;
|
|
@@ -464,6 +473,7 @@ declare class EruGridStore {
|
|
|
464
473
|
private readonly _pivotConfiguration;
|
|
465
474
|
private readonly _pivotResult;
|
|
466
475
|
private readonly _drilldown;
|
|
476
|
+
private readonly _actionClick;
|
|
467
477
|
private readonly _dataRequest;
|
|
468
478
|
readonly columns: _angular_core.Signal<Field[]>;
|
|
469
479
|
readonly groups: _angular_core.Signal<RowGroup[]>;
|
|
@@ -473,6 +483,7 @@ declare class EruGridStore {
|
|
|
473
483
|
readonly isLoading: _angular_core.Signal<boolean>;
|
|
474
484
|
readonly error: _angular_core.Signal<string | null>;
|
|
475
485
|
readonly activeCell: _angular_core.Signal<any>;
|
|
486
|
+
readonly actionClick: _angular_core.Signal<ActionClick | null>;
|
|
476
487
|
readonly pivotConfiguration: _angular_core.Signal<PivotConfiguration | null>;
|
|
477
488
|
readonly pivotResult: _angular_core.Signal<PivotResult | null>;
|
|
478
489
|
readonly drilldown: _angular_core.Signal<Drilldown | null>;
|
|
@@ -576,6 +587,7 @@ declare class EruGridStore {
|
|
|
576
587
|
isFreezeGrandTotalEnabled(): boolean;
|
|
577
588
|
setDrilldown(drilldown: Drilldown, columnValues: string): void;
|
|
578
589
|
clearPivotDrilldown(): void;
|
|
590
|
+
setActionClick(actionClick: ActionClick): void;
|
|
579
591
|
/**
|
|
580
592
|
* Emit a data request signal (called by grid component)
|
|
581
593
|
*/
|
|
@@ -803,6 +815,22 @@ declare class EruGridComponent implements OnInit, AfterViewInit, OnDestroy {
|
|
|
803
815
|
private initializeColumnWidths;
|
|
804
816
|
toggleRowSelection(event: Event, row: any): void;
|
|
805
817
|
toggleGroupSelection(event: Event, groupId: string): void;
|
|
818
|
+
onActionClick(event: Event, row: any, actionName?: string): void;
|
|
819
|
+
/**
|
|
820
|
+
* Get actions from configuration
|
|
821
|
+
*/
|
|
822
|
+
gridActions: _angular_core.Signal<string[]>;
|
|
823
|
+
/**
|
|
824
|
+
* Check if action column is enabled
|
|
825
|
+
* @returns true if actionColumn is enabled, false otherwise (default: false)
|
|
826
|
+
*/
|
|
827
|
+
isActionColumnEnabled: _angular_core.Signal<boolean>;
|
|
828
|
+
/**
|
|
829
|
+
* Get action column position
|
|
830
|
+
* @returns 'before' | 'after' (default: 'after')
|
|
831
|
+
*/
|
|
832
|
+
getActionColumnPosition: _angular_core.Signal<"before" | "after">;
|
|
833
|
+
shouldShowActionColumn(position: 'before' | 'after'): boolean;
|
|
806
834
|
toggleAllGroups(event: Event): void;
|
|
807
835
|
isRowSelected(rowId?: string): boolean;
|
|
808
836
|
isGroupSelected(groupId: string): boolean;
|
|
@@ -913,5 +941,14 @@ declare class ThemeToggleComponent {
|
|
|
913
941
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ThemeToggleComponent, "eru-theme-toggle", never, {}, {}, never, never, true, never>;
|
|
914
942
|
}
|
|
915
943
|
|
|
916
|
-
|
|
917
|
-
|
|
944
|
+
declare class HelloWorldComponent {
|
|
945
|
+
constructor();
|
|
946
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<HelloWorldComponent, never>;
|
|
947
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<HelloWorldComponent, "eru-hello-world", never, {}, {}, never, never, true, never>;
|
|
948
|
+
}
|
|
949
|
+
|
|
950
|
+
declare const MATERIAL_PROVIDERS: Provider[];
|
|
951
|
+
declare const MATERIAL_MODULES: (typeof MatCommonModule)[];
|
|
952
|
+
|
|
953
|
+
export { ColumnConstraintsService, EruGridComponent, EruGridService, EruGridStore, HelloWorldComponent, MATERIAL_MODULES, MATERIAL_PROVIDERS, ThemeService, ThemeToggleComponent };
|
|
954
|
+
export type { ActionClick, AggregationFunction, ColumnWidthConstraints, DataTypes, Drilldown, Field, GridConfiguration, GridFeatures, GridMode, GridStyles, GridTokens, GroupItem$1 as GroupItem, PivotColumnGroupState, PivotColumnHeader, PivotConfiguration, PivotHeaderStructure, PivotMetadata, PivotResult, PivotRow, Row, RowDataRequest, RowDataResponse, RowGroup, Theme };
|