diff --git a/components/style/properties.mako.rs b/components/style/properties.mako.rs index 3f66a733358..93b95a60e80 100644 --- a/components/style/properties.mako.rs +++ b/components/style/properties.mako.rs @@ -5732,6 +5732,12 @@ pub fn cascade(viewport_size: Size2D, box_.display = box_.display.to_computed_value(&context); } + // The initial value of outline width may be changed at computed value time. + if !context.outline_style_present { + let outline = unsafe { style_outline.make_unique() }; + outline.outline_width = Au(0); + } + if is_root_element { context.root_font_size = context.font_size; } @@ -5779,6 +5785,11 @@ pub fn cascade_anonymous(parent_style: &ComputedValues) -> ComputedValues { border.border_${side}_width = Au(0); % endfor } + { + // Initial value of outline-style is always none for anonymous box. + let outline = unsafe { result.outline.make_unique() }; + outline.outline_width = Au(0); + } // None of the teaks on 'display' apply here. result } diff --git a/tests/wpt/metadata-css/css21_dev/html4/abspos-containing-block-001.htm.ini b/tests/wpt/metadata-css/css21_dev/html4/abspos-containing-block-001.htm.ini deleted file mode 100644 index 6a628438496..00000000000 --- a/tests/wpt/metadata-css/css21_dev/html4/abspos-containing-block-001.htm.ini +++ /dev/null @@ -1,3 +0,0 @@ -[abspos-containing-block-001.htm] - type: reftest - expected: FAIL diff --git a/tests/wpt/metadata-css/css21_dev/html4/abspos-containing-block-003.htm.ini b/tests/wpt/metadata-css/css21_dev/html4/abspos-containing-block-003.htm.ini deleted file mode 100644 index 53001ffedae..00000000000 --- a/tests/wpt/metadata-css/css21_dev/html4/abspos-containing-block-003.htm.ini +++ /dev/null @@ -1,3 +0,0 @@ -[abspos-containing-block-003.htm] - type: reftest - expected: FAIL