euv_core/style/sheet/trait.rs
1use super::*;
2
3/// Type-directed property application trait enabling concise enum/value shorthand inside `style! { AlignItems::Center; Overflow::Hidden; }`.
4pub trait StyleApply {
5 /// Applies this strongly-typed style property directly onto `style`.
6 ///
7 /// # Arguments
8 ///
9 /// - `Self` - Typed style property value.
10 /// - `Style` - Target style accumulator.
11 ///
12 /// # Returns
13 ///
14 /// - `Style` - Updated style with the property applied.
15 #[must_use]
16 fn apply_to(self, style: Style) -> Style;
17}