mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
style: Make @font-face and @counter-style serialization closer other browsers and style rules.
Style rules serialize on one line and so should @font-face blocks. Part of https://github.com/w3c/csswg-drafts/issues/4828. Differential Revision: https://phabricator.services.mozilla.com/D89302
This commit is contained in:
parent
74c449c04c
commit
cd7619dbf6
2 changed files with 11 additions and 8 deletions
|
@ -232,12 +232,12 @@ macro_rules! counter_style_descriptors {
|
|||
fn to_css(&self, _guard: &SharedRwLockReadGuard, dest: &mut CssStringWriter) -> fmt::Result {
|
||||
dest.write_str("@counter-style ")?;
|
||||
self.name.to_css(&mut CssWriter::new(dest))?;
|
||||
dest.write_str(" {\n")?;
|
||||
dest.write_str(" { ")?;
|
||||
$(
|
||||
if let Some(ref value) = self.$ident {
|
||||
dest.write_str(concat!(" ", $name, ": "))?;
|
||||
dest.write_str(concat!($name, ": "))?;
|
||||
ToCss::to_css(value, &mut CssWriter::new(dest))?;
|
||||
dest.write_str(";\n")?;
|
||||
dest.write_str("; ")?;
|
||||
}
|
||||
)+
|
||||
dest.write_str("}")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue