/** * @license * Copyright 2025 Steven Roussey * SPDX-License-Identifier: Apache-2.0 */ export type CliTheme = { readonly level: "basic"; } | { readonly level: "advanced"; readonly fg: string; readonly bg: string; readonly medium: string; /** * One step further from the page than {@link CliTheme.medium}, for the * few marks that outrank their neighbours — the run's own progress bar * against the per-task ones. Close enough to still read as the same * family of chrome; the difference is meant to be noticed, not announced. */ readonly strong: string; }; export declare const DEFAULT_CLI_THEME: CliTheme; export declare function setCliTheme(theme: CliTheme): void; export declare function getCliTheme(): CliTheme; export interface TerminalRgb { readonly r: number; readonly g: number; readonly b: number; } /** * When both stdin and stdout are TTYs, queries the emulator for default fg/bg via OSC 4 (-1/-2), * falling back to OSC 10/11. Returns a theme with semantic palette only when detection succeeds. */ export declare function detectCliTheme(): Promise; /** * The palette every mark in the UI is drawn from, mixed out of the terminal's * own two colors so chrome sits on the page rather than on top of it. * * Both greys are stated as a distance from the background, which is what makes * them work in either direction: on a dark terminal they come out brighter than * the page, on a light one darker, without either being special-cased. */ export declare function cliPaletteFromRgb(fg: TerminalRgb, bg: TerminalRgb): CliTheme;