#
cargo/util/
style.rs

    1use anstyle::*;
    2
    3pub const NOP: Style = Style::new();
    4pub const HEADER: Style = AnsiColor::BrightGreen.on_default().effects(Effects::BOLD);
    5pub const USAGE: Style = AnsiColor::BrightGreen.on_default().effects(Effects::BOLD);
    6pub const LITERAL: Style = AnsiColor::BrightCyan.on_default().effects(Effects::BOLD);
    7pub const PLACEHOLDER: Style = AnsiColor::Cyan.on_default();
    8pub const ERROR: Style = annotate_snippets::renderer::DEFAULT_ERROR_STYLE;
    9pub const WARN: Style = annotate_snippets::renderer::DEFAULT_WARNING_STYLE;
    10pub const NOTE: Style = annotate_snippets::renderer::DEFAULT_NOTE_STYLE;
    11pub const GOOD: Style = AnsiColor::BrightGreen.on_default().effects(Effects::BOLD);
    12pub const VALID: Style = AnsiColor::BrightCyan.on_default().effects(Effects::BOLD);
    13pub const INVALID: Style = annotate_snippets::renderer::DEFAULT_WARNING_STYLE;
    14pub const TRANSIENT: Style = annotate_snippets::renderer::DEFAULT_HELP_STYLE;
    15pub const CONTEXT: Style = annotate_snippets::renderer::DEFAULT_CONTEXT_STYLE;
    16
    17pub const UPDATE_ADDED: Style = NOTE;
    18pub const UPDATE_REMOVED: Style = ERROR;
    19pub const UPDATE_UPGRADED: Style = GOOD;
    20pub const UPDATE_DOWNGRADED: Style = WARN;
    21pub const UPDATE_UNCHANGED: Style = anstyle::Style::new().bold();
    22
    23pub const DEP_NORMAL: Style = anstyle::Style::new().effects(anstyle::Effects::DIMMED);
    24pub const DEP_BUILD: Style = anstyle::AnsiColor::Blue
    25    .on_default()
    26    .effects(anstyle::Effects::BOLD);
    27pub const DEP_DEV: Style = anstyle::AnsiColor::Cyan
    28    .on_default()
    29    .effects(anstyle::Effects::BOLD);
    30pub const DEP_FEATURE: Style = anstyle::AnsiColor::Magenta
    31    .on_default()
    32    .effects(anstyle::Effects::DIMMED);