import { DEFAULT_TERMINAL_THEME, getTerminalTheme, normalizeTerminalThemeName, } from "../../services/theme/themeCatalog.js";
let activeTerminalTheme = normalizeTerminalThemeName(process.env.DEEPSEEKCODE_THEME)
    ?? DEFAULT_TERMINAL_THEME;
export function setActiveTerminalTheme(name) {
    activeTerminalTheme = normalizeTerminalThemeName(name) ?? DEFAULT_TERMINAL_THEME;
    return getTerminalTheme(activeTerminalTheme);
}
export function getActiveTerminalTheme() {
    const envTheme = normalizeTerminalThemeName(process.env.DEEPSEEKCODE_THEME);
    return getTerminalTheme(envTheme ?? activeTerminalTheme);
}
export function toneColor(tone) {
    const selected = getActiveTerminalTheme();
    return selected.colors[tone ?? "default"];
}
export function statusTone(value, warning = false) {
    if (warning)
        return "warning";
    return value ? "success" : "error";
}
