import type { SourceLocation } from '../../../../types.js'; import type { RillValue } from '../../../core/types/structures.js'; export declare function maxDayInMonth(year: number, month: number): number; /** * Build a unix ms timestamp from calendar components using setUTCFullYear, * which avoids Date.UTC's legacy two-digit-year rule (years 0-99 mapped to * 1900-1999). Halts with #INVALID_INPUT if the resulting timestamp is NaN. */ export declare function componentsToUnix(year: number, month: number, day: number, hour: number, minute: number, second: number, ms: number, location?: SourceLocation): number; /** * Construct a RillDatetime from parsed args. * Handles ISO string, named components, and unix ms forms. */ export declare function constructDatetime(args: Record, location?: SourceLocation): RillValue; /** * Construct a RillDuration from parsed args. * Collapses calendar units to months field and fixed units to ms field. */ export declare function constructDuration(args: Record, location?: SourceLocation): RillValue; /** * Validate a UTC offset intended for ISO 8601 suffix formatting. The * suffix is a fixed `+HH:MM`/`-HH:MM` shape whose hour field must fit * 00-23; an offset of 24 hours or more (or non-finite) would otherwise * silently produce a malformed suffix like `+30:00` instead of halting. */ export declare function validateIsoOffset(offsetHours: number, location?: SourceLocation, fn?: string): number; /** Format as full ISO 8601 string with timezone indicator */ export declare function formatIso(utcMs: number, offsetHours: number): string; /** Format as "YYYY-MM-DD" */ export declare function formatDate(utcMs: number, offsetHours: number): string; /** Format as "HH:MM:SS" */ export declare function formatTime(utcMs: number, offsetHours: number): string;