lewp_css/domain/at_rules/font_face/
font_stretch.rs1use {
5 crate::{
6 parsers::{Parse, ParserContext},
7 CustomParseError,
8 },
9 cssparser::{ParseError, Parser},
10};
11
12define_css_keyword_enum! {
13 FontStretch:
14 "normal" => normal,
15 "ultra-condensed" => ultra_condensed,
16 "extra-condensed" => extra_condensed,
17 "condensed" => condensed,
18 "semi-condensed" => semi_condensed,
19 "semi-expanded" => semi_expanded,
20 "expanded" => expanded,
21 "extra-expanded" => extra_expanded,
22 "ultra-expanded" => ultra_expanded,
23}
24
25impl Parse for FontStretch {
26 fn parse<'i, 't>(
27 _: &ParserContext,
28 input: &mut Parser<'i, 't>,
29 ) -> Result<Self, ParseError<'i, CustomParseError<'i>>> {
30 FontStretch::parse(input)
31 }
32}