registration
This commit is contained in:
36
frontend/style/node_modules/date-fns/eachWeekendOfInterval.d.ts
generated
vendored
36
frontend/style/node_modules/date-fns/eachWeekendOfInterval.d.ts
generated
vendored
@@ -1,4 +1,24 @@
|
||||
import type { Interval } from "./types.js";
|
||||
import type { ContextOptions, Interval } from "./types.js";
|
||||
/**
|
||||
* The {@link eachWeekendOfInterval} function options.
|
||||
*/
|
||||
export interface EachWeekendOfIntervalOptions<DateType extends Date = Date>
|
||||
extends ContextOptions<DateType> {}
|
||||
/**
|
||||
* The {@link eachWeekendOfInterval} function result type.
|
||||
*/
|
||||
export type EachWeekendOfIntervalResult<
|
||||
IntervalType extends Interval,
|
||||
Options extends EachWeekendOfIntervalOptions | undefined,
|
||||
> = Array<
|
||||
Options extends EachWeekendOfIntervalOptions<infer DateType>
|
||||
? DateType
|
||||
: IntervalType["start"] extends Date
|
||||
? IntervalType["start"]
|
||||
: IntervalType["end"] extends Date
|
||||
? IntervalType["end"]
|
||||
: Date
|
||||
>;
|
||||
/**
|
||||
* @name eachWeekendOfInterval
|
||||
* @category Interval Helpers
|
||||
@@ -7,9 +27,11 @@ import type { Interval } from "./types.js";
|
||||
* @description
|
||||
* Get all the Saturdays and Sundays in the given date interval.
|
||||
*
|
||||
* @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).
|
||||
* @typeParam IntervalType - Interval type.
|
||||
* @typeParam Options - Options type.
|
||||
*
|
||||
* @param interval - The given interval
|
||||
* @param options - An object with options
|
||||
*
|
||||
* @returns An array containing all the Saturdays and Sundays
|
||||
*
|
||||
@@ -26,6 +48,10 @@ import type { Interval } from "./types.js";
|
||||
* // Sun Sep 30 2018 00:00:00
|
||||
* // ]
|
||||
*/
|
||||
export declare function eachWeekendOfInterval<DateType extends Date>(
|
||||
interval: Interval<DateType>,
|
||||
): DateType[];
|
||||
export declare function eachWeekendOfInterval<
|
||||
IntervalType extends Interval,
|
||||
Options extends EachWeekendOfIntervalOptions | undefined = undefined,
|
||||
>(
|
||||
interval: IntervalType,
|
||||
options?: Options,
|
||||
): EachWeekendOfIntervalResult<IntervalType, Options>;
|
||||
|
||||
Reference in New Issue
Block a user