Skip to main content

vtcode_ui/theme/
mod.rs

1#![allow(
2    clippy::cast_sign_loss,
3    reason = "Intentional compatibility, platform, or test-only suppression."
4)]
5//! Shared theme registry and runtime state for VT Code UI crates.
6
7mod color_math;
8pub(crate) use color_math::contrast_ratio;
9mod registry;
10mod runtime;
11mod scheme;
12mod syntax;
13#[cfg(test)]
14mod tests;
15mod types;
16
17pub use registry::{available_theme_suites, available_themes, theme_label, theme_suite_id, theme_suite_label};
18pub use runtime::{
19    active_styles, active_theme_id, active_theme_label, banner_color, banner_style, clear_preview_theme, ensure_theme,
20    get_minimum_contrast, has_preview_theme, is_bold_bright_mode, is_safe_colors_only, logo_accent_color,
21    rebuild_active_styles, resolve_theme, set_active_theme, set_color_accessibility_config, set_preview_theme,
22    style_contrast_ratio, validate_theme_contrast,
23};
24pub use scheme::{
25    is_light_theme, suggest_theme_for_terminal, theme_for_terminal_scheme_change, theme_matches_terminal_scheme,
26};
27pub use syntax::{get_active_syntax_theme, get_syntax_theme_for_ui_theme};
28pub use types::{
29    ColorAccessibilityConfig, DEFAULT_THEME_ID, ThemeDefinition, ThemePalette, ThemeStyles, ThemeSuite,
30    ThemeValidationResult,
31};