UNPKG

@progress/kendo-angular-dropdowns

Version:

A wide variety of native Angular dropdown components including AutoComplete, ComboBox, DropDownList, DropDownTree, MultiColumnComboBox, MultiSelect, and MultiSelectTree

54 lines (53 loc) 2.64 kB
/**----------------------------------------------------------------------------------------- * Copyright © 2025 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the project root for more information *-------------------------------------------------------------------------------------------*/ import { EventEmitter, OnDestroy, OnChanges, SimpleChanges } from '@angular/core'; import { TreeViewComponent } from '@progress/kendo-angular-treeview'; import { CheckedItem } from './checked-item'; import { MultiSelectTreeCheckableSettings } from './checkable-settings'; import { BaseCheckDirective } from './base-check.directive'; import * as i0 from "@angular/core"; /** * @hidden * * A directive which manages the in-memory checked state of the MultiSelectTree nodes. */ export declare class CheckDirective extends BaseCheckDirective implements OnChanges, OnDestroy { private treeView; /** * Specifies whether items are checked on click and if checking a node also checks its children. * The `checkChildren` property also controls parent item checking (checking all child items automatically checks the parent). */ checkable: MultiSelectTreeCheckableSettings; /** * Sets the item key or keys to compare data items. */ valueField: string | string[]; /** * Sets the collection that stores all checked items. */ checkedItems: CheckedItem[]; /** * Fires when the `checkedItems` collection updates. */ checkedItemsChange: EventEmitter<CheckedItem[]>; /** * Holds a `Set` with only the checked item keys. Updates this set each time the `checkedItems` value or content changes and uses it for fast look-up to check if an item is checked. */ checkedKeys: Set<any>; private subscriptions; private clickSubscription; constructor(treeView: TreeViewComponent); ngOnChanges(changes: SimpleChanges): void; ngOnDestroy(): void; private getCheckedState; private handleCheckedChange; private toggleCheckOnClick; private unsubscribeClick; private checkNode; private checkParents; private isItemIndeterminate; static ɵfac: i0.ɵɵFactoryDeclaration<CheckDirective, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<CheckDirective, "[kendoMultiSelectTreeCheckable]", never, { "checkable": { "alias": "checkable"; "required": false; }; "valueField": { "alias": "valueField"; "required": false; }; "checkedItems": { "alias": "checkedItems"; "required": false; }; }, { "checkedItemsChange": "checkedItemsChange"; }, never, never, true, never>; }