UNPKG

ngx-select2-ex

Version:

Angular(2+) version of the popular alternative to select inputs, Select2. Select2 classes are used in the template, so you can use any pre-existing styles for Select2 and it will look the same as the original.

25 lines (24 loc) 1.05 kB
import { ElementRef, OnInit, OnDestroy, Renderer2 } from '@angular/core'; import { NgxSelect2ExService } from '../services/ngx-select2-ex.service'; import { NgxSelect2ExDropdownInjectionService } from '../services/ngx-select2-ex-dropdown-injection.service'; import { WindowRef } from '../services/window-ref.service'; export declare class NgxSelect2ExDirective implements OnInit, OnDestroy { private el; private renderer; private ngxSelect2ExDropdownInjectionService; private winRef; service: NgxSelect2ExService; private compRef; private subscriptions; constructor(el: ElementRef, renderer: Renderer2, ngxSelect2ExDropdownInjectionService: NgxSelect2ExDropdownInjectionService, winRef: WindowRef); ngOnInit(): void; ngOnDestroy(): void; onClick(targetElement: any): void; resize(): void; private openDropdown(); private closeDropdown(); private setFocusForSearchField(targetElement); private subscribeToSearchChanges(); private updateDropdownPosition(); private unsubscribe(); }