export type TDateFormat = 'd/m/yy' | 'm/d/yy' | 'd/mm/yy' | 'dd/mm/yy' | 'dd/mm/yyyy' | 'dd M yy' | 'dd M yyyy' | 'dd MM yy' | 'dd MM yyyy' | 'D dd M yy' | 'D dd M yyyy' | 'DD dd MM yy' | 'DD dd MM yyyy' | 'D, dd M yy' | 'D, dd M yyyy' | 'DD, dd MM yy' | 'DD, dd MM yyyy'; export type GoDateLayout = '02/01/06' | '_2/_1/06' | '_1/_2/06' | '02 Jan 06' | 'Mon, 02 Jan 06' | 'Mon, 02 Jan 2006'; export type TTimeFormat = 'HH:mm' | 'HH:mm a' | 'HH:mm:ss' | 'HH:mm:ss a'; export type GoTimeLayout = '15:04' | '03:04 PM' | '15:04:05' | '03:04:05 PM'; export type CustomDateTimeFormatOptions = Omit & { timezone?: string; locale?: string; }; export type DateOptions = { locale?: string; dateFormat?: TDateFormat | GoDateLayout; timeFormat?: TTimeFormat | GoTimeLayout; timezone?: string; /** * Show the time in the formatted date. * * @default true - when `timeFormat` is provided */ showTime?: boolean; /** * Show the date in the formatted date. * * @default true */ showDate?: boolean; /** * This is old format (general settings), if configuration still using old settings then this option parameter can be used */ formatPreset?: CustomDateTimeFormatOptions; }; export declare const formatDate: (date: Date, options?: DateOptions) => string; export declare const formatISODate: (date: string | Date) => string; /** * Formats a date to human readable form (timeago / relative time from now). * * @param date - The date to be displayed. Can be a Date object or a string in a recognized date format. * @param maxSeconds - Max value of seconds difference. Use it for formats a date according to the user's general settings. * @returns The formatted date string. */ export declare const formatDateReadable: (date: Date, maxSeconds?: number) => string; export declare const getRemainingTime: (deadline: string) => { seconds: number; days: number; hours: number; minutes: number; };