@progress/kendo-angular-pivotgrid
Version:
PivotGrid package for Angular
128 lines (127 loc) • 5.3 kB
TypeScript
/**-----------------------------------------------------------------------------------------
* Copyright © 2025 Progress Software Corporation. All rights reserved.
* Licensed under commercial license. See LICENSE.md in the project root for more information
*-------------------------------------------------------------------------------------------*/
import { ChangeDetectorRef, EventEmitter, NgZone, OnChanges, OnDestroy, OnInit, SimpleChanges } from '@angular/core';
import { AxisDescriptor, PivotGridField, PivotGridConfiguratorState, ConfiguratorNavigation } from '@progress/kendo-pivotgrid-common';
import { TreeItem, TreeViewComponent } from '@progress/kendo-angular-treeview';
import { PivotGridDataService } from '../data-binding/pivotgrid-data.service';
import { ConfiguratorService } from './configurator.service';
import { Observable } from 'rxjs';
import { LocalizationService } from '@progress/kendo-angular-l10n';
import { FilterDescriptor, SortDescriptor } from '@progress/kendo-data-query';
import { PivotGridConfiguratorOrientation } from '../models/configurator-orientation';
import { DropSectionType } from '../models/drop-section';
import { ChipListComponent, ChipRemoveEvent } from '@progress/kendo-angular-buttons';
import * as i0 from "@angular/core";
/**
* @hidden
* Represents the Kendo UI PivotGrid Configurator component for Angular.
*/
export declare class PivotGridConfiguratorComponent implements OnInit, OnChanges, OnDestroy {
private dataService;
private localization;
configuratorService: ConfiguratorService;
private cdr;
private zone;
hostClass: boolean;
hostAriaRole: string;
get headerTextId(): string;
orientation: PivotGridConfiguratorOrientation;
sort: Array<SortDescriptor>;
filter: FilterDescriptor[];
navigation: ConfiguratorNavigation;
close: EventEmitter<any>;
treeView: TreeViewComponent;
columnsList: ChipListComponent;
rowsList: ChipListComponent;
originalState: PivotGridConfiguratorState;
state: PivotGridConfiguratorState;
fields: PivotGridField[];
checked: any[];
get isHorizontal(): boolean;
private subs;
/**
* A function which determines if a specific node has child nodes.
*/
hasChildren: (node: any) => boolean;
constructor(dataService: PivotGridDataService, localization: LocalizationService, configuratorService: ConfiguratorService, cdr: ChangeDetectorRef, zone: NgZone);
ngOnInit(): void;
ngAfterViewInit(): void;
ngOnDestroy(): void;
ngOnChanges(changes: SimpleChanges): void;
getName(name: string[]): string;
contentLabelId(section: string): string;
setState(state: PivotGridConfiguratorState): void;
onReorder(ev: any, name: string, item: any): void;
/**
* Returns the localized message for a given token
*/
messageFor(localizationToken: string): string;
/**
* Retrieves the 'Columns' section item names
*/
get columnHierarchies(): unknown[];
/**
* Retrieves the 'Rows' section item names
*/
get rowHierarchies(): unknown[];
/**
* Retrieves the 'Value' section item names
*/
get measureHierarchies(): unknown[];
/**
* Updates the respective axis configuration of the current state
* when a chip is deleted from the UI
*/
onChipRemove(ev: ChipRemoveEvent, item: AxisDescriptor, section: DropSectionType): void;
/**
* Constructs an array with all selected fields.
* @param fields - used for when child nodes are loaded on demand.
* Child nodes are concatinated to the root level nodes.
*/
setChecked(fields?: any[]): void;
checkItemBy: (context: any) => any;
/**
* Determines if a checkbox should be rendered.
*/
isSelectable(node: any): boolean;
/**
* A function which provides the child nodes for a given parent node.
*/
children: (node: any) => Observable<any[]>;
/**
* Check if the newly loaded child nodes have checked items.
* (Only for OLAP data-binding directive)
*/
handleChildrenLoaded(event: {
children: TreeItem[];
item: TreeItem;
}): void;
handleCheckedChange(event: any): void;
onTreeViewSelect(ev: Event): void;
onTreeViewEscape(ev: KeyboardEvent): void;
handleSubmit(): void;
/**
* Reset the configurator to the last saved state
*/
handleReset(): void;
/**
* Flattens all available fields.
*/
private getFieldsFlatMap;
/**
* Creates an array containing only the field names, e.g. '[Date].[Calendar]' or 'Product'
*/
private extractDefaultFields;
/**
* Swaps chips within the same ChipList
*/
private swapChips;
/**
* Moves a chip from one ChipList to another
*/
private moveChip;
static ɵfac: i0.ɵɵFactoryDeclaration<PivotGridConfiguratorComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<PivotGridConfiguratorComponent, "kendo-pivotgrid-configurator", never, { "orientation": { "alias": "orientation"; "required": false; }; "sort": { "alias": "sort"; "required": false; }; "filter": { "alias": "filter"; "required": false; }; "navigation": { "alias": "navigation"; "required": false; }; }, { "close": "close"; }, never, never, true, never>;
}