import { JsonValue } from "../types/Json.js"; import { Optional } from "../types/Types.js"; import { Value } from "../types/Value.js"; import { Dayjs } from "dayjs"; //#region src/domain/DateTime.d.ts type Unit = 'year' | 'quarter' | 'month' | 'week' | 'day' | 'hour' | 'minute' | 'second' | 'millisecond'; export type DateTimeUnit = Unit; export type DurationUnit = Unit | `${Unit}s`; export type Duration = Partial>; export type DiffOptions = { rounding: 'floor' | 'ceil' | 'round'; }; export type DatetimeInput = string | number | Date | DateTime | null; export declare class DateTime extends Value> { protected readonly date: Dayjs; protected readonly zone: Zone; protected readonly fraction: number; constructor(value?: DatetimeInput); constructor(value?: string, format?: string); static get now(): DateTime; get isValid(): boolean; get fromNow(): string; get inAmsterdam(): DateTime; get inNewYork(): DateTime; get inLondon(): DateTime; get inWarsaw(): DateTime; private withDate; from(locale?: string): string; from(date?: DateTime, locale?: string): string; isAfter(dt: DateTime): boolean; isBefore(dt: DateTime): boolean; equals(dt: DateTime): boolean; add(n: number, unit?: DurationUnit): DateTime; add(duration: Duration): DateTime; subtract(n: number, unit?: DurationUnit): DateTime; subtract(duration: Duration): DateTime; diff(other: DateTime, unit?: DurationUnit, opts?: DiffOptions): number; startOf(unit?: DurationUnit): DateTime; endOf(unit?: DurationUnit): DateTime; isWeekend(): boolean; withZone(zone: string): DateTime; toString(): string; toJSON(): JsonValue; toFormat(format: string): string; toLocale(locale?: string, format?: string): string; toFull(locale?: string): string; toDate(): Optional; toEpoch(): number; ago(end?: DateTime): string; withClock(clock: DateTime): DateTime; } export declare const isDateTime: (dt?: unknown) => dt is DateTime; export declare const dt: (dt?: DatetimeInput) => DateTime; type Zone = { type: 'utc'; } | { type: 'offset'; minutes: number; } | { type: 'named'; name: string; }; //#endregion export {}; //# sourceMappingURL=DateTime.d.ts.map