diff --git a/components/style/properties/gecko.mako.rs b/components/style/properties/gecko.mako.rs index 448acd56e27..8c9fef0c8f6 100644 --- a/components/style/properties/gecko.mako.rs +++ b/components/style/properties/gecko.mako.rs @@ -1127,7 +1127,7 @@ fn static_assert() { ${impl_copy_animation_value(ident, gecko_ffi_name)} -<% skip_box_longhands= """display clear""" %> +<% skip_box_longhands= """display""" %> <%self:impl_trait style_struct_name="Box" skip_longhands="${skip_box_longhands}"> #[inline] pub fn set_display(&mut self, v: longhands::display::computed_value::T) { @@ -1159,13 +1159,6 @@ fn static_assert() { pub fn clone_display(&self) -> longhands::display::computed_value::T { self.gecko.mDisplay } - - <% clear_keyword = Keyword( - "clear", - "Left Right None Both", - gecko_enum_prefix="StyleClear", - ) %> - ${impl_keyword('clear', 'mBreakType', clear_keyword)} <%def name="simple_image_array_property(name, shorthand, field_name)"> diff --git a/components/style/properties/longhands/box.mako.rs b/components/style/properties/longhands/box.mako.rs index 8578df21bc2..ddf618cfba8 100644 --- a/components/style/properties/longhands/box.mako.rs +++ b/components/style/properties/longhands/box.mako.rs @@ -80,7 +80,7 @@ ${helpers.predefined_type( engines="gecko servo", animation_value_type="discrete", gecko_ffi_name="mBreakType", - spec="https://drafts.csswg.org/css-box/#propdef-clear", + spec="https://drafts.csswg.org/css2/#propdef-clear", servo_restyle_damage="rebuild_and_reflow", )} diff --git a/components/style/values/computed/box.rs b/components/style/values/computed/box.rs index 67b06ac5614..a390d69a029 100644 --- a/components/style/values/computed/box.rs +++ b/components/style/values/computed/box.rs @@ -152,6 +152,7 @@ impl ToComputedValue for SpecifiedFloat { ToResolvedValue, )] /// A computed value for the `clear` property. +#[repr(u8)] pub enum Clear { None, Left, diff --git a/components/style/values/specified/box.rs b/components/style/values/specified/box.rs index bc0bd777bda..c0e2756c54e 100644 --- a/components/style/values/specified/box.rs +++ b/components/style/values/specified/box.rs @@ -1684,7 +1684,7 @@ pub enum Float { #[derive( Clone, Copy, Debug, Eq, Hash, MallocSizeOf, Parse, PartialEq, SpecifiedValueInfo, ToCss, ToShmem, )] -/// https://drafts.csswg.org/css-box/#propdef-clear +/// https://drafts.csswg.org/css2/#propdef-clear pub enum Clear { None, Left,