@c10t/nice-component-library
Version:
nice-component-library
76 lines (75 loc) • 4.38 kB
TypeScript
import { EventEmitter, Injector, OnChanges, OnInit, SimpleChanges } from '@angular/core';
import { AbstractControl, ControlValueAccessor, NgControl } from '@angular/forms';
import { SelectModel } from '../models/components/select.model';
import { MatCheckboxChange } from '@angular/material/checkbox';
import { MatSelectChange } from '@angular/material/select';
import { TranslateService } from '@ngx-translate/core';
import { ValidatorService } from '../services/validator.service';
import { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
import { MatOptionSelectionChange } from '@angular/material/core';
import { NiceComponentLibraryConfig } from '../models/nice-component-library.config';
import { CvaFormControl } from './cva-form-control';
import * as i0 from "@angular/core";
export declare class CvaMultiSelectAutocomplete implements ControlValueAccessor, CvaFormControl, OnInit, OnChanges {
private translateService;
private injector;
placeholder: string;
label: string;
hint: string;
value: any[] | any;
options: SelectModel[];
disabled: boolean;
errorMessages: Map<string, (e?: any) => string>;
multiple: boolean;
required: boolean | (() => boolean);
isTree: boolean;
treeSymbol: string;
sizeOfItemsInListByPixels: number;
isLabelOutside: boolean;
isFloatLabel: boolean;
percentOfLabelOutside: number;
selectionChange: EventEmitter<any>;
selectedOptionDataChange: EventEmitter<SelectModel[]>;
valueOptionRef: SelectModel[];
isFormControl: boolean;
searchInputRef: any;
formControl: AbstractControl | null;
filteredOptions: SelectModel[];
selectAllChecked: boolean;
labelCount: number;
cdkVirtualScrollViewPort: CdkVirtualScrollViewport | undefined;
config: NiceComponentLibraryConfig;
constructor(translateService: TranslateService, injector: Injector, ngControl: NgControl);
_displayString: string;
get displayString(): string;
_titleString: string;
get titleString(): string;
get NsValidator(): typeof ValidatorService;
get selectedValue(): any[] | any;
set selectedValue(val: any[] | any);
getFormControl(): AbstractControl | null;
ngOnInit(): void;
getRequired(): boolean;
callValidator(): void;
propagateChange: (_: any) => void;
writeValue(obj: any[] | any): void;
registerOnChange(fn: any): void;
registerOnTouched(): void;
ngOnChanges(simpleChanges: SimpleChanges): void;
toggleSelectAll(val: MatCheckboxChange): void;
filterItem(value: string): void;
onDisplayString(): {
_displayString: string;
_titleString: string;
};
matSelectionChange(val: MatSelectChange): void;
onSelectionChange(change: MatOptionSelectionChange): void;
updateSelectAll(): void;
onDisplayTreeData(displayValue: string, isFirstLine: boolean): string;
openChange($event: boolean): void;
getItemSize(): number;
getViewPortHeight(): number;
isShowControl(): boolean;
static ɵfac: i0.ɵɵFactoryDeclaration<CvaMultiSelectAutocomplete, [null, null, { optional: true; self: true; }]>;
static ɵcmp: i0.ɵɵComponentDeclaration<CvaMultiSelectAutocomplete, "cva-multi-select-autocomplete", never, { "placeholder": { "alias": "placeholder"; "required": false; }; "label": { "alias": "label"; "required": false; }; "hint": { "alias": "hint"; "required": false; }; "value": { "alias": "value"; "required": false; }; "options": { "alias": "options"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "errorMessages": { "alias": "errorMessages"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "required": { "alias": "required"; "required": false; }; "isTree": { "alias": "isTree"; "required": false; }; "treeSymbol": { "alias": "treeSymbol"; "required": false; }; "sizeOfItemsInListByPixels": { "alias": "sizeOfItemsInListByPixels"; "required": false; }; "isLabelOutside": { "alias": "isLabelOutside"; "required": false; }; "isFloatLabel": { "alias": "isFloatLabel"; "required": false; }; "percentOfLabelOutside": { "alias": "percentOfLabelOutside"; "required": false; }; "isFormControl": { "alias": "isFormControl"; "required": false; }; }, { "selectionChange": "selectionChange"; "selectedOptionDataChange": "selectedOptionDataChange"; }, never, never, false, never>;
}