@hxui/angular
Version:
An Angular library based on the [HXUI design system](https://hxui.io).
51 lines (50 loc) • 2.05 kB
TypeScript
import { EventEmitter, OnChanges, OnInit, SimpleChanges } from '@angular/core';
import { BehaviorSubject } from 'rxjs';
import { Visibility } from '../enums';
import { DatepickerViewModeEnum } from './datepicker.model';
import * as i0 from "@angular/core";
export declare class DatepickerComponent implements OnInit, OnChanges {
get classes(): string;
selectedDate: Date;
validators: Array<(date: Date) => boolean>;
update: EventEmitter<Date>;
viewMode$: BehaviorSubject<DatepickerViewModeEnum>;
DatepickerViewModeEnum: typeof DatepickerViewModeEnum;
visibilityEnum: typeof Visibility;
visibility: Visibility;
viewDate: Date;
days: Array<Date>;
week: Array<string>;
months: Array<string>;
years: Array<number>;
private presentDate;
private cellCount;
private yearCellCount;
ngOnInit(): void;
ngOnChanges(changes: SimpleChanges): void;
/** update and emit selected date */
setSelectedDate(date: Date): void;
renderCalendar(): void;
next(): void;
previous(): void;
previousMonth(): void;
nextMonth(): void;
isCurrentMonth(inputDate: Date): boolean;
isCurrentDay(inputDate: Date): boolean;
isSelectedDay(inputDate: Date): boolean;
isInvalidDay(inputDate: Date): boolean;
isCurrentYear(year: number): boolean;
isSelectedYear(year: number): boolean;
isInvalidYear(year: number): boolean;
isCurrentMonthByIndex(month: number): boolean;
isSelectedMonthByIndex(month: number): boolean;
isInvalidMonthByIndex(month: number): boolean;
previousYear(): void;
nextYear(): void;
setYear(year: any): void;
setMonth(month: any): void;
toggleYear(): void;
private getYearCollection;
static ɵfac: i0.ɵɵFactoryDeclaration<DatepickerComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<DatepickerComponent, "hxa-datepicker", never, { "selectedDate": "selectedDate"; "validators": "validators"; }, { "update": "update"; }, never, never>;
}