import { ChangeDetectorRef, ElementRef, OnInit, QueryList } from '@angular/core'; import { DatoGridToolbarItemDirective } from './grid-toolbar-item.directive'; import { DatoGridComponent } from '../grid/grid.component'; import { ToolbarAction } from './grid-toolbar.types'; import { DatoTranslateService } from '../../services/translate.service'; import { GridToolbarService } from './grid-toolbar.service'; import { HashMap } from '@datorama/akita'; export declare class DatoGridToolbarComponent implements OnInit { private cdr; private translate; private gridToolbarService; private eventHandler; private areaActions; private api; private selectedRowsCount; private _actions; set actions(actions: ToolbarAction[]); get actions(): ToolbarAction[]; set grid(grid: DatoGridComponent); get leftAreaItems(): DatoGridToolbarItemDirective[]; get preservedAreaItems(): DatoGridToolbarItemDirective[]; get internalAreaItems(): DatoGridToolbarItemDirective[]; items: QueryList; actionItems: QueryList; container: ElementRef; open: boolean; /** * Contains the custom elements * @type {any[]} */ filteredItems: HashMap; get itemTemplates(): DatoGridToolbarItemDirective[]; constructor(cdr: ChangeDetectorRef, translate: DatoTranslateService, gridToolbarService: GridToolbarService); ngOnInit(): void; /** * Translate the actions */ translateActions(): void; /** * * @memberof DaGridToolbarComponent */ resize(): void; ngOnDestroy(): void; actionClick(action: ToolbarAction): void; private onGridReady; private rowSelectionChange; /** * Only rerender if we the rows count changed and we don't have a custom functions * @private * @param {number} rowsCount * @returns * @memberof DaGridToolbarComponent */ private _shouldNotRerender; /** * * @private * @returns * @memberof DaGridToolbarComponent */ private _hasCustomFunctions; /** * * @private * @param {boolean} init * @param {number} [rowsCount] * @param {*} [data] * @returns * @memberof DaGridToolbarComponent */ private _filterItems; /** * * @param condition * @returns {boolean} * @private */ private _showAlways; /** * * @private * @param {(string | showWhenFunc)} condition * @param {any[]} selectedRows * @returns * @memberof DaGridToolbarComponent */ private _handleCustomFunction; /** * Assert if only one row selected * @private * @param {(string | Function)} condition * @param {number} rowsCount * @returns * @memberof DaGridToolbarComponent */ private _isSingle; /** * Assert if no rows selected. * @param {string | showWhenFunc} condition * @param {number | undefined} rowsCount * @return {boolean} * @private */ private _isNone; /** * * @param {string | showWhenFunc} condition * @param {number} rowsCount * @returns {boolean} * @private */ private _isMultiple; /** * For the grid to be responsive * @private * @memberof DaGridToolbarComponent */ private fitGridSizeOnInit; }