Expand description
§ICSS — a CSS-like theme engine for iced
ICSS lets you style an iced application the way you’d style a web app:
write a .icss file with classes, variables, and pseudo-states, then
attach class lists to your widgets.
ⓘ
let theme = icss::Theme::load(include_str!("theme.icss"))?;
button("Connect").style(theme.button(&["button", "primary"]));The crate is organised into three modules:
theme— parses.icssand resolves widget styles for iced.engine— generates a complete.icsstheme from a handful of base variables (OKLCH tonal palettes, dimensional tokens, semantic mapping).widgets— theme-aware iced widgets that don’t ship with iced core (DataTable,TileGrid,ButtonGroup,StickySection, …).
Re-exports§
pub use engine::ThemeInputs;pub use engine::ThemeOutput;pub use engine::generate;pub use theme::ParseError;pub use theme::Stylesheet;pub use theme::Theme;pub use theme::parse_stylesheet;