mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-11 11:50:54 +08:00
remove IDayOfWeekMonth in favor of a tuple of [number, number] with refactor
This commit is contained in:
Vendored
+3
-11
@@ -3,14 +3,6 @@
|
||||
// Definitions by: Luzian Zagadinow <https://github.com/luzianz>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
interface IDayOfWeekMonth extends Array<number> {
|
||||
/** dayOfMonth */
|
||||
0: number;
|
||||
|
||||
/** dayOfWeek */
|
||||
1: number;
|
||||
}
|
||||
|
||||
interface IWeekRow<T> extends Array<T> {
|
||||
[dayIndex: number]: T;
|
||||
}
|
||||
@@ -183,7 +175,7 @@ declare module 'node-calendar' {
|
||||
* @param {number} month
|
||||
* Month for which the calendar should be generated.
|
||||
*/
|
||||
itermonthdays2(year: number, month: number): IDayOfWeekMonth[];
|
||||
itermonthdays2(year: number, month: number): [number, number][];
|
||||
|
||||
/**
|
||||
* A matrix (array of array) representing a month's calendar.
|
||||
@@ -217,7 +209,7 @@ declare module 'node-calendar' {
|
||||
* @param {number} month
|
||||
* Month for which the calendar should be generated.
|
||||
*/
|
||||
monthdays2calendar(year: number, month: number): IMonthGrid<IDayOfWeekMonth>;
|
||||
monthdays2calendar(year: number, month: number): IMonthGrid<[number, number]>;
|
||||
|
||||
/**
|
||||
* The specified year ready for formatting. The return value is an array
|
||||
@@ -254,7 +246,7 @@ declare module 'node-calendar' {
|
||||
* @param {number} width
|
||||
* The number of months to include in each row. Default: 3
|
||||
*/
|
||||
yeardays2calendar(year: number, width?: number): IYearGrid<IDayOfWeekMonth>;
|
||||
yeardays2calendar(year: number, width?: number): IYearGrid<[number, number]>;
|
||||
}
|
||||
|
||||
// Undocumented
|
||||
|
||||
Reference in New Issue
Block a user