@microsoft/windows-admin-center-sdk
Version:
Microsoft - Windows Admin Center Shell
80 lines (79 loc) • 3.19 kB
TypeScript
import { Injector, OnInit } from '@angular/core';
import { FormControl } from '@angular/forms';
import { DateLike } from '@microsoft/windows-admin-center-sdk/core/base/date/date-like';
import { DropdownComponent } from '../../../dropdown/dropdown.component';
import { ValidationAlerts } from '../../validation-alert/validation-alert';
import { CalendarFormFieldComponent } from '../calendar/calendar-form-field.component';
import { ClockFormFieldComponent } from '../clock/clock-form-field.component';
import { DateLikeFormFieldComponent } from '../date-like/date-like-form-field.component';
import * as i0 from "@angular/core";
/**
* DateTime Form Field Component
*/
export declare class DateTimeFormFieldComponent extends DateLikeFormFieldComponent implements OnInit {
/**
* The source name to use for logging
*/
protected get logSourceName(): string;
dropDown: DropdownComponent;
calendar: CalendarFormFieldComponent;
clock: ClockFormFieldComponent;
/**
* The current editable display value of this field
*/
displayValue: string;
/**
* indicates if the display value is valid
*/
displayValueValid: boolean;
/**
* indicates if a value change is expected
*/
expectValueChange: boolean;
/**
* An intermediate store for drop down values
*/
interMediateValue: Date;
/**
* Initializes a new instance of the @see DateTimeFormFieldComponent class.
* @param injector The angular injection service. required by @see SmeInjectableBase decorator in the @see BaseComponent class
*/
constructor(injector: Injector);
/**
* Handles toggled state changes
*/
onDropdownToggled(expanded: boolean): void;
/**
* Handles keydown events on the dropdown toggle
*/
onToggleKeydown(event: KeyboardEvent): void;
/**
* Handles value changes from the date input
*/
commitDisplayValue(): void;
/**
* Occurs every time the value of the control changes, in the UI or programmatically.
* @param value the value of the form control
*/
protected onValueChanged(value: DateLike): void;
/**
* Called on ng model changes, prevents dropdown changes from going to form model.
*/
onNgModelChange(value: DateLike, dateChanged?: boolean): void;
/**
* Called when users commits drop down changes, they are saved to model
*/
commitDropDownValue(event: Event): void;
/**
* Performs validation that is internal to this control
* @param c The form control attached to this instance
*/
protected validate(c: FormControl): ValidationAlerts;
/**
* Creates the idBag used by this component to store unique element ids.
* id values will be assigned be the @see BaseComponent super class.
*/
protected createIdBag(): MsftSme.StringMap<string>;
static ɵfac: i0.ɵɵFactoryDeclaration<DateTimeFormFieldComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<DateTimeFormFieldComponent, "sme-form-field[type=\"datetime\"]", never, {}, {}, never, never, false, never>;
}