igniteui-angular
Version:
Ignite UI for Angular is a dependency-free Angular toolkit for building modern web apps
78 lines (77 loc) • 2.05 kB
TypeScript
import { ElementRef } from '@angular/core';
import * as i0 from "@angular/core";
export declare class IgxTextSelectionDirective {
private element;
/**
* Determines whether the input element could be selected through the directive.
*
* ```html
* <!--set-->
* <input
* type="text"
* id="firstName"
* [igxTextSelection]="true">
* </input>
*
* <input
* type="text"
* id="lastName"
* igxTextSelection
* [selected]="true">
* </input>
* ```
*/
selected: boolean;
/**
* Returns the nativeElement of the element where the directive was applied.
*
* ```html
* <input
* type="text"
* id="firstName"
* igxTextSelection>
* </input>
* ```
*
* ```typescript
* @ViewChild('firstName',
* {read: IgxTextSelectionDirective})
* public inputElement: IgxTextSelectionDirective;
*
* public getNativeElement() {
* return this.inputElement.nativeElement;
* }
* ```
*/
get nativeElement(): any;
constructor(element: ElementRef);
/**
* @hidden
*/
onFocus(): void;
/**
* Triggers the selection of the element if it is marked as selectable.
*
* ```html
* <input
* type="text"
* id="firstName"
* igxTextSelection>
* </input>
* ```
*
* ```typescript
* @ViewChild('firstName',
* {read: IgxTextSelectionDirective})
* public inputElement: IgxTextSelectionDirective;
*
* public triggerElementSelection() {
* this.inputElement.trigger();
* }
* ```
*/
trigger(): void;
static ɵfac: i0.ɵɵFactoryDeclaration<IgxTextSelectionDirective, never>;
static ɵdir: i0.ɵɵDirectiveDeclaration<IgxTextSelectionDirective, "[igxTextSelection]", ["igxTextSelection"], { "selected": { "alias": "igxTextSelection"; "required": false; }; }, {}, never, never, true, never>;
static ngAcceptInputType_selected: unknown;
}