/** * @file Console footer/summary formatting utilities. Provides consistent footer * and summary formatting for CLI applications. */ export interface FooterOptions { /** * Text shown above the border. Omit for a bare rule. */ message?: string | undefined; /** * Width of the footer border in characters. * * @default 80 */ width?: number | undefined; /** * Character to use for the border line. * * @default '=' */ borderChar?: string | undefined; /** * Include ISO timestamp in footer. * * @default false */ showTimestamp?: boolean | undefined; /** * Show duration since start time. * * @default false */ showDuration?: boolean | undefined; /** * Start time in milliseconds (from Date.now()). Required when `showDuration` * is true. */ startTime?: number | undefined; /** * Color to apply to the footer message. * * @default 'gray' */ color?: 'cyan' | 'green' | 'yellow' | 'blue' | 'magenta' | 'red' | 'gray' | undefined; } export interface SummaryStats { /** * Total number of items processed. */ total?: number | undefined; /** * Number of successful items. */ success?: number | undefined; /** * Number of failed items. */ failed?: number | undefined; /** * Number of skipped items. */ skipped?: number | undefined; /** * Number of warnings. */ warnings?: number | undefined; /** * Number of errors. */ errors?: number | undefined; /** * Duration in milliseconds, given as a timestamp value rather than * elapsed time. */ duration?: number | undefined; } /** * Create a formatted footer with optional message, timestamp, and duration. * Useful for marking the end of CLI output or showing completion status. * * @example * ;```ts * const startTime = Date.now() * // ... do work * console.log( * createFooter('Build complete', { * width: 60, * color: 'green', * showDuration: true, * startTime, * }), * ) * ``` * * @param message - Optional message to display in footer. * @param options - Footer formatting options. * * @returns Formatted footer string with border and optional info */ export declare function createFooter(options?: FooterOptions | undefined): string; /** * Create a summary footer with statistics and colored status indicators. * Automatically formats success/failure/warning counts with appropriate colors. * Useful for test results, build summaries, or batch operation reports. * * @example * ;```ts * console.log( * createSummaryFooter({ * total: 150, * success: 145, * failed: 3, * skipped: 2, * warnings: 5, * }), * ) * // Output: Total: 150 | ✓ 145 passed | ✗ 3 failed | ○ 2 skipped | ⚠ 5 warnings * // ======================================== * ``` * * @param stats - Statistics to display in the summary. * @param options - Footer formatting options. * * @returns Formatted summary footer string with colored indicators */ export declare function createSummaryFooter(stats: SummaryStats, options?: FooterOptions | undefined): string; /** * Print a footer with optional success message. Uses `─` border character for a * lighter appearance. Fixed width of 55 characters to match `printHeader()`. * * @example * ;```ts * printFooter('Analysis complete') * // Output: * // ─────────────────────────────────────────────────── * // Analysis complete (in green) * ``` * * @param message - Optional message to display in green. */ export declare function printFooter(message?: string | undefined): void;