Skip to content

Commit 1bedc95

Browse files
authored
fix(pivot-grid): align IPivotAggregator aggregator type with PivotAggregation 21.2.x (#17272)
1 parent fc7584a commit 1bedc95

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

projects/igniteui-angular/grids/core/src/pivot-grid.interface.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,10 @@ export interface IPivotDimensionStrategy {
5050

5151
/**
5252
* Interface describing a PivotAggregation function.
53-
* Accepts an array of extracted data members and a array of the original data records.
53+
* Accepts an array of extracted data members and an optional array of the original data records,
54+
* which can be omitted or undefined.
5455
*/
55-
export type PivotAggregation = (members: any[], data: any[]) => any;
56+
export type PivotAggregation = (members: any[], data?: any[]) => any;
5657

5758
/* marshalByValue */
5859
/**
@@ -76,7 +77,7 @@ export interface IPivotAggregator {
7677
* Aggregator function can be a custom implementation of `PivotAggregation`, or
7778
* use predefined ones from `IgxPivotAggregate` and its variants.
7879
*/
79-
aggregator?: (members: any[], data?: any[]) => any;
80+
aggregator?: PivotAggregation;
8081
}
8182

8283
/* marshalByValue */

0 commit comments

Comments
 (0)