pub struct Theme {Show 69 fields
pub name: String,
pub primary_color: PrimaryColor,
pub radius_scale: RadiusScale,
pub glow_mode: GlowMode,
pub surface_0: String,
pub surface_1: String,
pub surface_2: String,
pub surface_3: String,
pub root: String,
pub header: String,
pub sidebar: String,
pub sidebar_link: String,
pub sidebar_link_active: String,
pub content: String,
pub surface: String,
pub panel: String,
pub banner: String,
pub border: String,
pub border_subtle: String,
pub border_accent: String,
pub text_accent: String,
pub text_accent_bright: String,
pub glow: String,
pub glow_button: String,
pub glow_card: String,
pub glow_input: String,
pub glow_badge: String,
pub glow_modal: String,
pub glow_alert: String,
pub glow_dropdown: String,
pub glow_notification: String,
pub glow_switch: String,
pub glow_checkbox: String,
pub button_primary: String,
pub button_secondary: String,
pub button_outline: String,
pub button_ghost: String,
pub button_danger: String,
pub button_success: String,
pub card_base: String,
pub card_header: String,
pub card_footer: String,
pub card_shadow_none: String,
pub card_shadow_sm: String,
pub card_shadow_md: String,
pub card_shadow_lg: String,
pub card_shadow_xl: String,
pub input_base: String,
pub input_normal_border: String,
pub input_error_border: String,
pub badge_default: String,
pub badge_primary: String,
pub badge_success: String,
pub badge_warning: String,
pub badge_danger: String,
pub badge_outline: String,
pub navbar_base: String,
pub modal_backdrop: String,
pub modal_dialog: String,
pub modal_header: String,
pub modal_close: String,
pub alert_info: String,
pub alert_success: String,
pub alert_warning: String,
pub alert_danger: String,
pub alert_title_info: String,
pub alert_title_success: String,
pub alert_title_warning: String,
pub alert_title_danger: String,
}Expand description
Struttura centrale del tema per Shadow Design ispirata a Mantine / Craft UI.
Fields§
§name: String§primary_color: PrimaryColor§radius_scale: RadiusScale§glow_mode: GlowMode§surface_0: String§surface_1: String§surface_2: String§surface_3: String§root: String§header: String§content: String§surface: String§panel: String§border: String§border_subtle: String§border_accent: String§text_accent: String§text_accent_bright: String§glow: String§glow_card: String§glow_input: String§glow_badge: String§glow_modal: String§glow_alert: String§glow_dropdown: String§glow_notification: String§glow_switch: String§glow_checkbox: String§card_base: String§card_header: String§card_shadow_none: String§card_shadow_sm: String§card_shadow_md: String§card_shadow_lg: String§card_shadow_xl: String§input_base: String§input_normal_border: String§input_error_border: String§badge_default: String§badge_primary: String§badge_success: String§badge_warning: String§badge_danger: String§badge_outline: String§modal_backdrop: String§modal_dialog: String§modal_header: String§modal_close: String§alert_info: String§alert_success: String§alert_warning: String§alert_danger: String§alert_title_info: String§alert_title_success: String§alert_title_warning: String§alert_title_danger: StringImplementations§
Source§impl Theme
impl Theme
Sourcepub fn shadow() -> Self
pub fn shadow() -> Self
Tema di default Shadow Design (Ultraviolet Obsidian: Nero profondo con accenti viola e specular highlights).
Sourcepub fn obsidian() -> Self
pub fn obsidian() -> Self
Preset Obsidian Titanium (Monocromatico rigoroso con accenti grafite e metallo).
Sourcepub fn cyan() -> Self
pub fn cyan() -> Self
Preset Cyber Cyan (Nero profondo con accenti ciano elettrico ad alto contrasto).
Sourcepub fn emerald() -> Self
pub fn emerald() -> Self
Preset Emerald Matrix (Nero profondo con verde smeraldo ad altissima nitidezza).
Sourcepub fn apply_primary_color(&mut self, color: PrimaryColor)
pub fn apply_primary_color(&mut self, color: PrimaryColor)
Applica un colore primario aggiornando tutti i token cromatici associati.
Sourcepub fn apply_radius_scale(&mut self, radius: RadiusScale)
pub fn apply_radius_scale(&mut self, radius: RadiusScale)
Applica una scala globale del raggio di curvatura.
Sourcepub fn apply_glow_mode(&mut self, glow: GlowMode)
pub fn apply_glow_mode(&mut self, glow: GlowMode)
Applica una modalità di intensità per il micro-glow, ricalcolando tutti i componenti.
Sourcepub fn component_glow(&self, component: &str) -> &str
pub fn component_glow(&self, component: &str) -> &str
Restituisce la classe di glow configurata per un dato componente.
Sourcepub fn is_component_glow_enabled(
&self,
component: &str,
override_glow: Option<bool>,
) -> bool
pub fn is_component_glow_enabled( &self, component: &str, override_glow: Option<bool>, ) -> bool
Risolve se il glow è attivo per un componente tenendo conto dell’override opzionale.