/**----------------------------------------------------------------------------------------- * Copyright © 2025 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the project root for more information *-------------------------------------------------------------------------------------------*/ import { EventEmitter, ChangeDetectorRef, SimpleChanges } from '@angular/core'; import { Subscription } from "rxjs"; import { RowArgs } from "../rendering/common/row-args"; import { SelectionEvent, CellSelectionItem } from "./types"; import { ColumnComponent } from '../columns/column.component'; import { PairSet } from './pair-set'; import { ContextService } from '../common/provider.service'; import * as i0 from "@angular/core"; /** * @hidden */ export declare class Selection { protected ctx: ContextService; protected cd: ChangeDetectorRef; /** * Stores the selected item keys. * @default [] */ selectedKeys: any[]; /** * Sets the starting row index for `Shift`+click range selection. * * @default 0 */ rangeSelectionStartRow: RowArgs; /** * Sets the starting column index for `Shift`+click range selection when cell selection is on. * * @default 0 */ rangeSelectionStartColumnIndex: number; /** * Sets the item key to store in `selectedKeys`. * [See example](slug:grid_selection_persistence#by-a-custom-key). */ selectionKey: string | ((context: RowArgs) => any); /** * Sets a function to get the column key for a data cell. * * The function must return a unique value for each column. * The Grid uses the column index as the default column key. */ columnKey: string | ((column: any, columnIndex: number) => any); /** * Emits when the `selectedKeys` collection changes. */ selectedKeysChange: EventEmitter; rowSelectionState: Set; cellSelectionState: PairSet; /** * @hidden */ get isCellSelectionMode(): boolean; protected lastSelectionState: any[]; protected selectionChangeSubscription: Subscription; constructor(ctx: ContextService, cd: ChangeDetectorRef); ngOnChanges(changes: SimpleChanges): void; protected init(): void; /** * @hidden */ destroy(): void; /** * @hidden */ reset(): void; /** * @hidden */ getItemKey(row: RowArgs): any; /** * @hidden */ stateToArray(): any[]; protected getSelectionItem(row: RowArgs, col: ColumnComponent, colIndex: number): CellSelectionItem; protected onSelectionChange(selection: SelectionEvent): void; private notifyChange; private setState; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵdir: i0.ɵɵDirectiveDeclaration; }