import { DatePart, DateTimePartValues } from './types'; export interface LocaleMeta { datePartsOrder: DatePart[]; dateSeparator: string; timeSeparator: string; is24HourFormat: boolean; } /** * Parse a given string into a JS Date instance with timezone information (Amsterdam). The datetime * is expected to be in ISO-8601 YYYY-MM-DDTHH:MM:SS format (optionally including milliseconds and * a timezone), or formatted according to the locale if the meta was passed. * * If the meta was passed, single digit months or days are zero-padded automatically, and seconds * are can be missing, e.g. '1-10-2025 15:22' (Dutch format). * * If no date could be parsed (either because it's incomplete, wrong format or just nonsensical), * returns `null`. */ export declare const parseDateTime: (value: string, meta?: LocaleMeta) => Date | null; /** * Format date and time parts into an (unvalidated) ISO-8601 string. */ export declare const partsToUnvalidatedISO8601: (parts: DateTimePartValues) => string; /** * Given a locale, figure out the order of date parts and what the separator used is. * * This uses a dummy date to format it with the provided locale using the native Intl * APIs and extracts the order from the formatted date. */ export declare const getDateLocaleMeta: (locale: string) => LocaleMeta; /** * Determine the "best" initial date for the date picker. * * Given the (optional) minimum and maximum bounds, pick the bound that should lead * to the least amount of clicks for the user to get to a valid date. There are a * number of cases to consider here that prevent use from using date-fns `min` helper: * * - for a max date in the past, use the max date so the user doesn't have to skip over * all days between the past max date & now * - for a min date in the future, a similar case applies * - when both min and max date are specified and today falls within the interval - * don't use any of the bounds, as the date picker defaults to the current date */ export declare const getBestInitialDate: (minDate: Date | undefined, maxDate: Date | undefined) => Date | undefined;