mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Auto merge of #20211 - servo:derive-all-the-things, r=emilio
Improve #[derive(ToCss)] <!-- Reviewable:start --> This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/20211) <!-- Reviewable:end -->
This commit is contained in:
commit
785b7c7775
10 changed files with 146 additions and 111 deletions
|
@ -369,9 +369,9 @@ pub enum OverflowClipBox {
|
|||
pub enum WillChange {
|
||||
/// Expresses no particular intent
|
||||
Auto,
|
||||
#[css(comma, iterable)]
|
||||
/// <custom-ident>
|
||||
AnimateableFeatures(Box<[CustomIdent]>),
|
||||
#[css(comma)]
|
||||
AnimateableFeatures(#[css(iterable)] Box<[CustomIdent]>),
|
||||
}
|
||||
|
||||
impl WillChange {
|
||||
|
|
|
@ -92,8 +92,7 @@ pub enum Content {
|
|||
#[cfg(feature = "gecko")]
|
||||
MozAltContent,
|
||||
/// Content items.
|
||||
#[css(iterable)]
|
||||
Items(Box<[ContentItem]>),
|
||||
Items(#[css(iterable)] Box<[ContentItem]>),
|
||||
}
|
||||
|
||||
/// Items for the `content` property.
|
||||
|
|
|
@ -152,8 +152,8 @@ impl From<LengthOrPercentage> for FontSize {
|
|||
#[derive(Clone, Debug, Eq, Hash, PartialEq, ToCss)]
|
||||
pub enum FontFamily {
|
||||
/// List of `font-family`
|
||||
#[css(iterable, comma)]
|
||||
Values(FontFamilyList),
|
||||
#[css(comma)]
|
||||
Values(#[css(iterable)] FontFamilyList),
|
||||
/// System font
|
||||
System(SystemFont),
|
||||
}
|
||||
|
@ -718,11 +718,11 @@ pub enum VariantAlternates {
|
|||
#[css(function)]
|
||||
Stylistic(CustomIdent),
|
||||
/// Enables display with stylistic sets
|
||||
#[css(comma, function, iterable)]
|
||||
Styleset(Box<[CustomIdent]>),
|
||||
#[css(comma, function)]
|
||||
Styleset(#[css(iterable)] Box<[CustomIdent]>),
|
||||
/// Enables display of specific character variants
|
||||
#[css(comma, function, iterable)]
|
||||
CharacterVariant(Box<[CustomIdent]>),
|
||||
#[css(comma, function)]
|
||||
CharacterVariant(#[css(iterable)] Box<[CustomIdent]>),
|
||||
/// Enables display of swash glyphs
|
||||
#[css(function)]
|
||||
Swash(CustomIdent),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue