leptos_css/
global_keyword.rs1use std::fmt;
2
3use crate::checked_value::impl_checked_value;
4use crate::serialization::CssWriteTo;
5
6#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)]
8#[non_exhaustive]
9pub enum GlobalKeyword {
10 Inherit,
12 Initial,
14 Unset,
16 Revert,
18 RevertLayer,
20}
21
22impl CssWriteTo for GlobalKeyword {
23 fn css_fmt<W: fmt::Write>(&self, w: &mut W) -> fmt::Result {
24 w.write_str(match self {
25 Self::Inherit => "inherit",
26 Self::Initial => "initial",
27 Self::Unset => "unset",
28 Self::Revert => "revert",
29 Self::RevertLayer => "revert-layer",
30 })
31 }
32}
33
34impl_checked_value!(GlobalKeyword);