import { Timestamp } from 'firebase/firestore'; import * as i0 from "@angular/core"; export type DmCmpsDateTypes = Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number; export type DmCmpsDateFormats = 'dd/MM/yyyy' | 'yyyy/MM/dd' | 'dd/MM/yyyy HH:mm'; export type DmCmpsLangs = 'en' | 'he' | 'ar'; export declare const daysOfWeek: Record; declare global { interface Date { getWeekOfYear(): number; getWeekOfMonth(): number; getDayOfYear(): number; } } export declare class DmCmpsDateService { constructor(); getDate(date: Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number | null): Date | null; /** * * @param date the date to transform * @param format the format of the date * @param lang the language of the date * @returns the date as a string * * @example * The format can be any string that contains the following: * - 'dd' - the day of the month * - 'MM' - the month * - 'yyyy' - the year * - 'yy' - the year (2 digits) * - 'HH' - the hour * - 'mm' - the minute * - 'ss' - the second * - 'SSS' - the millisecond * - 'DM_a' - the AM/PM * - 'DM_E' - the day of the week * - 'DM_Z' - the time zone * - 'DM_z' - the time zone offset * - 'DM_yw' - the week of the year * - 'DM_mw' - the week of the month * - 'DM_yd' - the day of the year */ getDateString(date: Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number | null, format?: DmCmpsDateFormats | string, lang?: DmCmpsLangs): string; /** * * @param date the date to transform * @param format the format of the date * @param lang the language of the date * @returns the date as a string * * @example * The format can be any string that contains the following: * - 'dd' - the day of the month * - 'MM' - the month * - 'yyyy' - the year * - 'yy' - the year (2 digits) * - 'HH' - the hour * - 'mm' - the minute * - 'ss' - the second * - 'SSS' - the millisecond * - 'DM_a' - the AM/PM * - 'DM_E' - the day of the week * - 'DM_Z' - the time zone * - 'DM_z' - the time zone offset * - 'DM_yw' - the week of the year * - 'DM_mw' - the week of the month * - 'DM_yd' - the day of the year */ static getDateString(date: Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number | null, format?: DmCmpsDateFormats | string, lang?: DmCmpsLangs): string; static getDate(date: Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number | null): Date | null; static getTimeString(date: Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number | null): string; static now(): Date; now(): Date; getAge(date: Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number | null | null, fixed?: number | null, result?: 'string' | 'number'): number | string; static getAge(date: Timestamp | Date | string | { _seconds: number; _nanoseconds: number; } | { seconds: number; nanoseconds: number; } | number | null | null, fixed?: number | null, result?: 'string' | 'number'): number | string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }