/** Canonical OOXML built-in number formats — verbatim from openpyxl. */ export declare const BUILTIN_FORMATS: Readonly>; /** First numFmtId Excel reserves for user-defined formats. */ export declare const BUILTIN_FORMATS_MAX_SIZE = 164; export declare const FORMAT_GENERAL = "General"; export declare const FORMAT_TEXT = "@"; export declare const FORMAT_NUMBER = "0"; export declare const FORMAT_NUMBER_00 = "0.00"; export declare const FORMAT_PERCENTAGE = "0%"; export declare const FORMAT_PERCENTAGE_00 = "0.00%"; export declare const FORMAT_DATE_DATETIME = "yyyy-mm-dd h:mm:ss"; export declare const FORMAT_DATE_TIMEDELTA = "[hh]:mm:ss"; export declare const FORMAT_DATE_YYYYMMDD2 = "yyyy-mm-dd"; /** Look up the format code for a given numFmtId, or `undefined` if unknown. */ export declare function builtinFormatCode(id: number): string | undefined; /** Look up the numFmtId for a given format code, or `undefined` if not built-in. */ export declare function builtinFormatId(code: string): number | undefined; /** True iff `code` is one of the OOXML built-in format strings. */ export declare function isBuiltinFormat(code: string): boolean; /** * Heuristic: does the format string imply a date / time interpretation? * Looks at only the first format section (positive-value branch); strips * literals, colour codes and locale modifiers before scanning for date * tokens (d/m/h/y/s, case-insensitive) that aren't escaped. */ export declare function isDateFormat(code: string | undefined | null): boolean; /** Heuristic: does the format string indicate a duration ([h]:mm:ss etc.)? */ export declare function isTimedeltaFormat(code: string | undefined | null): boolean; /** Categorise a date format as 'date', 'time', 'datetime' or undefined. */ export declare function classifyDateFormat(code: string | undefined | null): 'date' | 'time' | 'datetime' | undefined; export interface NumberFormat { /** Stylesheet-relative numFmtId. */ readonly numFmtId: number; readonly formatCode: string; } export declare function makeNumberFormat(opts: { numFmtId: number; formatCode: string; }): NumberFormat;