UNPKG

@metadev/lux

Version:

Lux: Library with User Interface components for Angular.

70 lines (69 loc) 2.97 kB
import { EventEmitter, OnInit, ElementRef } from '@angular/core'; import { ControlValueAccessor, AbstractControl, ValidationErrors, Validator } from '@angular/forms'; import * as i0 from "@angular/core"; export declare class DatetimeComponent implements OnInit, ControlValueAccessor, Validator { static idCounter: number; dateInput: ElementRef; timeInput: ElementRef; touched: boolean; dirty: boolean; lastErrors: ValidationErrors | null; private _disabled; private _required; private _value; dateValue?: string; timeValue?: string; userErrors: { en: { required: string; min: string; max: string; }; es: { required: string; min: string; max: string; }; }; min?: string; max?: string; includeSeconds: boolean; localTime: boolean; get className(): string; lang: string; inlineErrors: boolean; inputId: string; ariaLabel: string; readonly: boolean | null; set disabled(v: string | boolean); get disabled(): string | boolean; set required(v: boolean); get required(): boolean; set value(v: string); get value(): string; valueChange: EventEmitter<any>; keyPress: EventEmitter<KeyboardEvent>; onChange: (_value: any) => void; onTouched: () => void; constructor(); writeValue(value: any): void; registerOnChange(onChange: any): void; registerOnTouched(onTouched: any): void; markAsTouched(): void; setDisabledState(disabled: boolean): void; private setDateInControl; private setTimeInControl; private setValueInControl; clear(): void; isClearable(): boolean; registerOnValidatorChange(): void; validate(control: AbstractControl): ValidationErrors | null; ngOnInit(): void; onLostFocus(): void; onKeyPress(event: KeyboardEvent): void; onEventDatetime(newDate: string, newTime: string): void; checkClassName(): string; setPatterns(): void; static ɵfac: i0.ɵɵFactoryDeclaration<DatetimeComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<DatetimeComponent, "lux-datetime", never, { "min": { "alias": "min"; "required": false; }; "max": { "alias": "max"; "required": false; }; "includeSeconds": { "alias": "includeSeconds"; "required": false; }; "localTime": { "alias": "localTime"; "required": false; }; "lang": { "alias": "lang"; "required": false; }; "inlineErrors": { "alias": "inlineErrors"; "required": false; }; "inputId": { "alias": "inputId"; "required": false; }; "ariaLabel": { "alias": "aria-label"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "required": { "alias": "required"; "required": false; }; "value": { "alias": "value"; "required": false; }; }, { "valueChange": "valueChange"; "keyPress": "keyPress"; }, never, never, false, never>; }