mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-29 00:51:29 +08:00
Added definitions for dateDisabled and cuscomClass options. (#19694)
This commit is contained in:
committed by
Mohamed Hegazy
parent
5d6648e218
commit
487f822f05
27
types/angular-ui-bootstrap/index.d.ts
vendored
27
types/angular-ui-bootstrap/index.d.ts
vendored
@@ -62,6 +62,15 @@ declare module 'angular' {
|
||||
timezone?: string;
|
||||
}
|
||||
|
||||
type DatepickerCallback<T> = (args: IDatepickerCellArgs) => T;
|
||||
|
||||
type DatepickerMode = "day" | "month" | "year";
|
||||
|
||||
interface IDatepickerCellArgs {
|
||||
date: Date;
|
||||
mode: DatepickerMode;
|
||||
}
|
||||
|
||||
interface IDatepickerConfig {
|
||||
/**
|
||||
* Format of day in month.
|
||||
@@ -110,7 +119,7 @@ declare module 'angular' {
|
||||
*
|
||||
* @default 'day'
|
||||
*/
|
||||
datepickerMode?: string;
|
||||
datepickerMode?: DatepickerMode;
|
||||
|
||||
/**
|
||||
* Set a lower limit for mode.
|
||||
@@ -201,7 +210,21 @@ declare module 'angular' {
|
||||
*
|
||||
* @default {}
|
||||
*/
|
||||
ngModelOptions?: IDropdownConfigNgOptions
|
||||
ngModelOptions?: IDropdownConfigNgOptions;
|
||||
|
||||
/**
|
||||
* Defines an optional expression to disable visible options based on passing an object with date and current mode properties.
|
||||
*
|
||||
* @default null
|
||||
*/
|
||||
dateDisabled?: DatepickerCallback<boolean>;
|
||||
|
||||
/**
|
||||
* Defines an optional expression to add classes based on passing an object with date and current mode properties.
|
||||
*
|
||||
* @default null
|
||||
*/
|
||||
customClass?: DatepickerCallback<string>;
|
||||
}
|
||||
|
||||
interface IDatepickerPopupConfig {
|
||||
|
||||
Reference in New Issue
Block a user