From 412b758107063c0f334d6f95428f9c36f987eb40 Mon Sep 17 00:00:00 2001 From: Sam Atkins Date: Thu, 6 Feb 2025 11:10:36 +0000 Subject: [PATCH] LibWeb/CSS: Support nested shorthands in CSSStyleDeclaration Without this, getting a property's value from `element.style.foo` would fail if `foo` is a shorthand property which has a longhand that is also a shorthand. For example, `border` expands to `border-width` which expands to `border-top-width`. This is because we used `property()` to get a longhand's value, but this returns nothing if the property is a shorthand. This commit solves that by moving most of get_property_value() into a separate method that returns a StyleProperty instead of a String, and which calls itself recursively for shorthands. Also move the manual shorthand construction out of ResolvedCSSStyleDeclaration so that all CSSStyleDeclarations can use it. --- Libraries/LibWeb/CSS/CSSStyleDeclaration.cpp | 146 ++++++++++++-- Libraries/LibWeb/CSS/CSSStyleDeclaration.h | 1 + .../CSS/ResolvedCSSStyleDeclaration.cpp | 81 +------- ...upported-properties-and-default-values.txt | 16 +- .../css/set-style-declaration-shorthand.txt | 8 +- .../css/css-fonts/parsing/font-valid.txt | 185 +++++++++--------- .../cssom/border-shorthand-serialization.txt | 7 +- 7 files changed, 237 insertions(+), 207 deletions(-) diff --git a/Libraries/LibWeb/CSS/CSSStyleDeclaration.cpp b/Libraries/LibWeb/CSS/CSSStyleDeclaration.cpp index fa199042c24..6da75f69707 100644 --- a/Libraries/LibWeb/CSS/CSSStyleDeclaration.cpp +++ b/Libraries/LibWeb/CSS/CSSStyleDeclaration.cpp @@ -1,6 +1,6 @@ /* * Copyright (c) 2018-2024, Andreas Kling - * Copyright (c) 2023-2024, Sam Atkins + * Copyright (c) 2023-2025, Sam Atkins * * SPDX-License-Identifier: BSD-2-Clause */ @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include @@ -261,34 +262,115 @@ bool PropertyOwningCSSStyleDeclaration::set_a_css_declaration(PropertyID propert return true; } -// https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-getpropertyvalue -String CSSStyleDeclaration::get_property_value(StringView property_name) const +static Optional style_property_for_sided_shorthand(PropertyID property_id, Optional const& top, Optional const& right, Optional const& bottom, Optional const& left) { - auto property_id = property_id_from_string(property_name); - if (!property_id.has_value()) + if (!top.has_value() || !right.has_value() || !bottom.has_value() || !left.has_value()) return {}; - if (property_id.value() == PropertyID::Custom) { - auto maybe_custom_property = custom_property(FlyString::from_utf8_without_validation(property_name.bytes())); - if (maybe_custom_property.has_value()) { - return maybe_custom_property.value().value->to_string( - computed_flag() ? Web::CSS::CSSStyleValue::SerializationMode::ResolvedValue - : Web::CSS::CSSStyleValue::SerializationMode::Normal); - } + if (top->important != right->important || top->important != bottom->important || top->important != left->important) return {}; + + ValueComparingNonnullRefPtr const top_value { top->value }; + ValueComparingNonnullRefPtr const right_value { right->value }; + ValueComparingNonnullRefPtr const bottom_value { bottom->value }; + ValueComparingNonnullRefPtr const left_value { left->value }; + + bool const top_and_bottom_same = top_value == bottom_value; + bool const left_and_right_same = left_value == right_value; + + RefPtr value; + + if (top_and_bottom_same && left_and_right_same && top_value == left_value) { + value = top_value; + } else if (top_and_bottom_same && left_and_right_same) { + value = StyleValueList::create(StyleValueVector { top_value, right_value }, StyleValueList::Separator::Space); + } else if (left_and_right_same) { + value = StyleValueList::create(StyleValueVector { top_value, right_value, bottom_value }, StyleValueList::Separator::Space); + } else { + value = StyleValueList::create(StyleValueVector { top_value, right_value, bottom_value, left_value }, StyleValueList::Separator::Space); } + return StyleProperty { + .important = top->important, + .property_id = property_id, + .value = value.release_nonnull(), + }; +} + +// https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-getpropertyvalue +Optional CSSStyleDeclaration::get_property_internal(PropertyID property_id) const +{ // 2. If property is a shorthand property, then follow these substeps: - if (property_is_shorthand(property_id.value())) { + if (property_is_shorthand(property_id)) { + + // AD-HOC: Handle shorthands that require manual construction. + switch (property_id) { + case PropertyID::Border: { + auto width = get_property_internal(PropertyID::BorderWidth); + auto style = get_property_internal(PropertyID::BorderStyle); + auto color = get_property_internal(PropertyID::BorderColor); + // `border` only has a reasonable value if all four sides are the same. + if (!width.has_value() || width->value->is_value_list() || !style.has_value() || style->value->is_value_list() || !color.has_value() || color->value->is_value_list()) + return {}; + if (width->important != style->important || width->important != color->important) + return {}; + return StyleProperty { + .important = width->important, + .property_id = property_id, + .value = ShorthandStyleValue::create(property_id, + { PropertyID::BorderWidth, PropertyID::BorderStyle, PropertyID::BorderColor }, + { width->value, style->value, color->value }) + }; + } + case PropertyID::BorderColor: { + auto top = get_property_internal(PropertyID::BorderTopColor); + auto right = get_property_internal(PropertyID::BorderRightColor); + auto bottom = get_property_internal(PropertyID::BorderBottomColor); + auto left = get_property_internal(PropertyID::BorderLeftColor); + return style_property_for_sided_shorthand(property_id, top, right, bottom, left); + } + case PropertyID::BorderStyle: { + auto top = get_property_internal(PropertyID::BorderTopStyle); + auto right = get_property_internal(PropertyID::BorderRightStyle); + auto bottom = get_property_internal(PropertyID::BorderBottomStyle); + auto left = get_property_internal(PropertyID::BorderLeftStyle); + return style_property_for_sided_shorthand(property_id, top, right, bottom, left); + } + case PropertyID::BorderWidth: { + auto top = get_property_internal(PropertyID::BorderTopWidth); + auto right = get_property_internal(PropertyID::BorderRightWidth); + auto bottom = get_property_internal(PropertyID::BorderBottomWidth); + auto left = get_property_internal(PropertyID::BorderLeftWidth); + return style_property_for_sided_shorthand(property_id, top, right, bottom, left); + } + case PropertyID::Margin: { + auto top = get_property_internal(PropertyID::MarginTop); + auto right = get_property_internal(PropertyID::MarginRight); + auto bottom = get_property_internal(PropertyID::MarginBottom); + auto left = get_property_internal(PropertyID::MarginLeft); + return style_property_for_sided_shorthand(property_id, top, right, bottom, left); + } + case PropertyID::Padding: { + auto top = get_property_internal(PropertyID::PaddingTop); + auto right = get_property_internal(PropertyID::PaddingRight); + auto bottom = get_property_internal(PropertyID::PaddingBottom); + auto left = get_property_internal(PropertyID::PaddingLeft); + return style_property_for_sided_shorthand(property_id, top, right, bottom, left); + } + default: + break; + } + // 1. Let list be a new empty array. Vector> list; Optional last_important_flag; // 2. For each longhand property longhand that property maps to, in canonical order, follow these substeps: - Vector longhand_ids = longhands_for_shorthand(property_id.value()); + Vector longhand_ids = longhands_for_shorthand(property_id); for (auto longhand_property_id : longhand_ids) { - // 1. If longhand is a case-sensitive match for a property name of a CSS declaration in the declarations, let declaration be that CSS declaration, or null otherwise. - auto declaration = property(longhand_property_id); + // 1. If longhand is a case-sensitive match for a property name of a CSS declaration in the declarations, + // let declaration be that CSS declaration, or null otherwise. + auto declaration = get_property_internal(longhand_property_id); // 2. If declaration is null, then return the empty string. if (!declaration.has_value()) @@ -304,18 +386,42 @@ String CSSStyleDeclaration::get_property_value(StringView property_name) const // 3. If important flags of all declarations in list are same, then return the serialization of list. // NOTE: Currently we implement property-specific shorthand serialization in ShorthandStyleValue::to_string(). - return ShorthandStyleValue::create(property_id.value(), longhand_ids, list)->to_string(computed_flag() ? CSSStyleValue::SerializationMode::ResolvedValue : CSSStyleValue::SerializationMode::Normal); + return StyleProperty { + .important = last_important_flag.value(), + .property_id = property_id, + .value = ShorthandStyleValue::create(property_id, longhand_ids, list), + }; // 4. Return the empty string. // NOTE: This is handled by the loop. } - auto maybe_property = property(property_id.value()); + return property(property_id); +} + +// https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-getpropertyvalue +String CSSStyleDeclaration::get_property_value(StringView property_name) const +{ + auto property_id = property_id_from_string(property_name); + if (!property_id.has_value()) + return {}; + + if (property_id.value() == PropertyID::Custom) { + auto maybe_custom_property = custom_property(FlyString::from_utf8_without_validation(property_name.bytes())); + if (maybe_custom_property.has_value()) { + return maybe_custom_property.value().value->to_string( + computed_flag() ? CSSStyleValue::SerializationMode::ResolvedValue + : CSSStyleValue::SerializationMode::Normal); + } + return {}; + } + + auto maybe_property = get_property_internal(property_id.value()); if (!maybe_property.has_value()) return {}; return maybe_property->value->to_string( - computed_flag() ? Web::CSS::CSSStyleValue::SerializationMode::ResolvedValue - : Web::CSS::CSSStyleValue::SerializationMode::Normal); + computed_flag() ? CSSStyleValue::SerializationMode::ResolvedValue + : CSSStyleValue::SerializationMode::Normal); } // https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-getpropertypriority diff --git a/Libraries/LibWeb/CSS/CSSStyleDeclaration.h b/Libraries/LibWeb/CSS/CSSStyleDeclaration.h index 251f2a4263c..e93db085ead 100644 --- a/Libraries/LibWeb/CSS/CSSStyleDeclaration.h +++ b/Libraries/LibWeb/CSS/CSSStyleDeclaration.h @@ -61,6 +61,7 @@ protected: private: // ^PlatformObject virtual Optional item_value(size_t index) const override; + Optional get_property_internal(PropertyID) const; }; class PropertyOwningCSSStyleDeclaration : public CSSStyleDeclaration { diff --git a/Libraries/LibWeb/CSS/ResolvedCSSStyleDeclaration.cpp b/Libraries/LibWeb/CSS/ResolvedCSSStyleDeclaration.cpp index d84a491087b..0e7b5f6badd 100644 --- a/Libraries/LibWeb/CSS/ResolvedCSSStyleDeclaration.cpp +++ b/Libraries/LibWeb/CSS/ResolvedCSSStyleDeclaration.cpp @@ -1,7 +1,7 @@ /* * Copyright (c) 2021-2023, Andreas Kling * Copyright (c) 2021, Tobias Christiansen - * Copyright (c) 2022-2023, Sam Atkins + * Copyright (c) 2022-2025, Sam Atkins * * SPDX-License-Identifier: BSD-2-Clause */ @@ -9,37 +9,23 @@ #include #include #include -#include #include #include #include #include -#include #include #include -#include -#include -#include -#include -#include #include #include #include -#include -#include -#include #include #include #include -#include #include -#include #include #include -#include #include #include -#include namespace Web::CSS { @@ -115,23 +101,6 @@ static NonnullRefPtr style_value_for_size(Size const& size) TODO(); } -static NonnullRefPtr style_value_for_sided_shorthand(ValueComparingNonnullRefPtr top, ValueComparingNonnullRefPtr right, ValueComparingNonnullRefPtr bottom, ValueComparingNonnullRefPtr left) -{ - bool top_and_bottom_same = top == bottom; - bool left_and_right_same = left == right; - - if (top_and_bottom_same && left_and_right_same && top == left) - return top; - - if (top_and_bottom_same && left_and_right_same) - return StyleValueList::create(StyleValueVector { move(top), move(right) }, StyleValueList::Separator::Space); - - if (left_and_right_same) - return StyleValueList::create(StyleValueVector { move(top), move(right), move(bottom) }, StyleValueList::Separator::Space); - - return StyleValueList::create(StyleValueVector { move(top), move(right), move(bottom), move(left) }, StyleValueList::Separator::Space); -} - enum class LogicalSide { BlockStart, BlockEnd, @@ -437,54 +406,6 @@ RefPtr ResolvedCSSStyleDeclaration::style_value_for_propert // -> Any other property // The resolved value is the computed value. // NOTE: This is handled inside the `default` case. - - // NOTE: Everything below is a shorthand that requires some manual construction. - case PropertyID::Border: { - auto width = style_value_for_property(layout_node, PropertyID::BorderWidth); - auto style = style_value_for_property(layout_node, PropertyID::BorderStyle); - auto color = style_value_for_property(layout_node, PropertyID::BorderColor); - // `border` only has a reasonable value if all four sides are the same. - if (width->is_value_list() || style->is_value_list() || color->is_value_list()) - return nullptr; - return ShorthandStyleValue::create(property_id, - { PropertyID::BorderWidth, PropertyID::BorderStyle, PropertyID::BorderColor }, - { width.release_nonnull(), style.release_nonnull(), color.release_nonnull() }); - } - case PropertyID::BorderColor: { - auto top = style_value_for_property(layout_node, PropertyID::BorderTopColor); - auto right = style_value_for_property(layout_node, PropertyID::BorderRightColor); - auto bottom = style_value_for_property(layout_node, PropertyID::BorderBottomColor); - auto left = style_value_for_property(layout_node, PropertyID::BorderLeftColor); - return style_value_for_sided_shorthand(top.release_nonnull(), right.release_nonnull(), bottom.release_nonnull(), left.release_nonnull()); - } - case PropertyID::BorderStyle: { - auto top = style_value_for_property(layout_node, PropertyID::BorderTopStyle); - auto right = style_value_for_property(layout_node, PropertyID::BorderRightStyle); - auto bottom = style_value_for_property(layout_node, PropertyID::BorderBottomStyle); - auto left = style_value_for_property(layout_node, PropertyID::BorderLeftStyle); - return style_value_for_sided_shorthand(top.release_nonnull(), right.release_nonnull(), bottom.release_nonnull(), left.release_nonnull()); - } - case PropertyID::BorderWidth: { - auto top = style_value_for_property(layout_node, PropertyID::BorderTopWidth); - auto right = style_value_for_property(layout_node, PropertyID::BorderRightWidth); - auto bottom = style_value_for_property(layout_node, PropertyID::BorderBottomWidth); - auto left = style_value_for_property(layout_node, PropertyID::BorderLeftWidth); - return style_value_for_sided_shorthand(top.release_nonnull(), right.release_nonnull(), bottom.release_nonnull(), left.release_nonnull()); - } - case PropertyID::Margin: { - auto top = style_value_for_property(layout_node, PropertyID::MarginTop); - auto right = style_value_for_property(layout_node, PropertyID::MarginRight); - auto bottom = style_value_for_property(layout_node, PropertyID::MarginBottom); - auto left = style_value_for_property(layout_node, PropertyID::MarginLeft); - return style_value_for_sided_shorthand(top.release_nonnull(), right.release_nonnull(), bottom.release_nonnull(), left.release_nonnull()); - } - case PropertyID::Padding: { - auto top = style_value_for_property(layout_node, PropertyID::PaddingTop); - auto right = style_value_for_property(layout_node, PropertyID::PaddingRight); - auto bottom = style_value_for_property(layout_node, PropertyID::PaddingBottom); - auto left = style_value_for_property(layout_node, PropertyID::PaddingLeft); - return style_value_for_sided_shorthand(top.release_nonnull(), right.release_nonnull(), bottom.release_nonnull(), left.release_nonnull()); - } case PropertyID::WebkitTextFillColor: return CSSColorValue::create_from_color(layout_node.computed_values().webkit_text_fill_color()); case PropertyID::Invalid: diff --git a/Tests/LibWeb/Text/expected/css/CSSStyleDeclaration-all-supported-properties-and-default-values.txt b/Tests/LibWeb/Text/expected/css/CSSStyleDeclaration-all-supported-properties-and-default-values.txt index 5d74f02f925..38eaa889eaf 100644 --- a/Tests/LibWeb/Text/expected/css/CSSStyleDeclaration-all-supported-properties-and-default-values.txt +++ b/Tests/LibWeb/Text/expected/css/CSSStyleDeclaration-all-supported-properties-and-default-values.txt @@ -200,8 +200,8 @@ All supported properties and their default values exposed from CSSStyleDeclarati 'border-bottom-width': 'medium' 'borderCollapse': 'separate' 'border-collapse': 'separate' -'borderColor': 'rgb(0, 0, 0) rgb(0, 0, 0) rgb(0, 0, 0) rgb(0, 0, 0)' -'border-color': 'rgb(0, 0, 0) rgb(0, 0, 0) rgb(0, 0, 0) rgb(0, 0, 0)' +'borderColor': 'rgb(0, 0, 0)' +'border-color': 'rgb(0, 0, 0)' 'borderLeft': 'medium none rgb(0, 0, 0)' 'border-left': 'medium none rgb(0, 0, 0)' 'borderLeftColor': 'rgb(0, 0, 0)' @@ -222,8 +222,8 @@ All supported properties and their default values exposed from CSSStyleDeclarati 'border-right-width': 'medium' 'borderSpacing': '0px' 'border-spacing': '0px' -'borderStyle': 'none none none none' -'border-style': 'none none none none' +'borderStyle': 'none' +'border-style': 'none' 'borderTop': 'medium none rgb(0, 0, 0)' 'border-top': 'medium none rgb(0, 0, 0)' 'borderTopColor': 'rgb(0, 0, 0)' @@ -236,8 +236,8 @@ All supported properties and their default values exposed from CSSStyleDeclarati 'border-top-style': 'none' 'borderTopWidth': 'medium' 'border-top-width': 'medium' -'borderWidth': 'medium medium medium medium' -'border-width': 'medium medium medium medium' +'borderWidth': 'medium' +'border-width': 'medium' 'bottom': 'auto' 'boxShadow': 'none' 'box-shadow': 'none' @@ -407,7 +407,7 @@ All supported properties and their default values exposed from CSSStyleDeclarati 'list-style-position': 'outside' 'listStyleType': 'disc' 'list-style-type': 'disc' -'margin': '8px 8px 8px 8px' +'margin': '8px' 'marginBlock': '8px 8px 8px 8px' 'margin-block': '8px 8px 8px 8px' 'marginBlockEnd': '8px' @@ -477,7 +477,7 @@ All supported properties and their default values exposed from CSSStyleDeclarati 'overflow-x': 'visible' 'overflowY': 'visible' 'overflow-y': 'visible' -'padding': '0px 0px 0px 0px' +'padding': '0px' 'paddingBlock': '0px 0px 0px 0px' 'padding-block': '0px 0px 0px 0px' 'paddingBlockEnd': '0px' diff --git a/Tests/LibWeb/Text/expected/css/set-style-declaration-shorthand.txt b/Tests/LibWeb/Text/expected/css/set-style-declaration-shorthand.txt index decee2c3ab3..fdd46993ce3 100644 --- a/Tests/LibWeb/Text/expected/css/set-style-declaration-shorthand.txt +++ b/Tests/LibWeb/Text/expected/css/set-style-declaration-shorthand.txt @@ -26,10 +26,10 @@ Setting flex: ''; becomes... e.style.length: 0 Setting border: '1px solid red'; becomes... - border-width: '1px 1px 1px 1px' - border-style: 'solid solid solid solid' - border-color: 'red red red red' - border: '' + border-width: '1px' + border-style: 'solid' + border-color: 'red' + border: '1px solid red' e.style.length: 12 > [0] border-top-width > [1] border-right-width diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-fonts/parsing/font-valid.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-fonts/parsing/font-valid.txt index 90fd7509e0c..9b71a9b50e4 100644 --- a/Tests/LibWeb/Text/expected/wpt-import/css/css-fonts/parsing/font-valid.txt +++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-fonts/parsing/font-valid.txt @@ -2,48 +2,49 @@ Harness status: OK Found 315 tests -315 Fail -Fail caption should be a supported system font. -Fail icon should be a supported system font. -Fail menu should be a supported system font. -Fail message-box should be a supported system font. -Fail small-caption should be a supported system font. -Fail status-bar should be a supported system font. -Fail e.style['font'] = "xx-small serif" should set the property value -Fail e.style['font'] = "normal medium/normal sans-serif" should set the property value -Fail e.style['font'] = "normal normal xx-large/1.2 cursive" should set the property value +91 Pass +224 Fail +Pass caption should be a supported system font. +Pass icon should be a supported system font. +Pass menu should be a supported system font. +Pass message-box should be a supported system font. +Pass small-caption should be a supported system font. +Pass status-bar should be a supported system font. +Pass e.style['font'] = "xx-small serif" should set the property value +Pass e.style['font'] = "normal medium/normal sans-serif" should set the property value +Pass e.style['font'] = "normal normal xx-large/1.2 cursive" should set the property value Fail e.style['font'] = "normal normal normal larger/calc(120% + 1.2em) fantasy" should set the property value -Fail e.style['font'] = "normal normal normal normal smaller monospace" should set the property value -Fail e.style['font'] = "normal normal normal italic 10px/normal Menu" should set the property value +Pass e.style['font'] = "normal normal normal normal smaller monospace" should set the property value +Pass e.style['font'] = "normal normal normal italic 10px/normal Menu" should set the property value Fail e.style['font'] = "normal normal normal small-caps 20%/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "normal normal normal bold calc(30% - 40px)/calc(120% + 1.2em) serif" should set the property value -Fail e.style['font'] = "normal normal normal ultra-condensed xx-small sans-serif" should set the property value -Fail e.style['font'] = "normal normal oblique medium/normal cursive" should set the property value -Fail e.style['font'] = "normal normal italic normal xx-large/1.2 fantasy" should set the property value +Pass e.style['font'] = "normal normal normal ultra-condensed xx-small sans-serif" should set the property value +Pass e.style['font'] = "normal normal oblique medium/normal cursive" should set the property value +Pass e.style['font'] = "normal normal italic normal xx-large/1.2 fantasy" should set the property value Fail e.style['font'] = "normal normal oblique small-caps larger/calc(120% + 1.2em) monospace" should set the property value -Fail e.style['font'] = "normal normal italic bolder smaller Menu" should set the property value -Fail e.style['font'] = "normal normal oblique extra-condensed 10px/normal \"FB Armada\"" should set the property value +Pass e.style['font'] = "normal normal italic bolder smaller Menu" should set the property value +Pass e.style['font'] = "normal normal oblique extra-condensed 10px/normal \"FB Armada\"" should set the property value Fail e.style['font'] = "normal normal small-caps 20%/1.2 serif" should set the property value Fail e.style['font'] = "normal normal small-caps normal calc(30% - 40px)/calc(120% + 1.2em) sans-serif" should set the property value Fail e.style['font'] = "normal normal small-caps italic xx-small cursive" should set the property value Fail e.style['font'] = "normal normal small-caps lighter medium/normal fantasy" should set the property value Fail e.style['font'] = "normal normal small-caps condensed xx-large/1.2 monospace" should set the property value Fail e.style['font'] = "normal normal 100 larger/calc(120% + 1.2em) Menu" should set the property value -Fail e.style['font'] = "normal normal 900 normal smaller \"FB Armada\"" should set the property value -Fail e.style['font'] = "normal normal bold oblique 10px/normal serif" should set the property value +Pass e.style['font'] = "normal normal 900 normal smaller \"FB Armada\"" should set the property value +Pass e.style['font'] = "normal normal bold oblique 10px/normal serif" should set the property value Fail e.style['font'] = "normal normal bolder small-caps 20%/1.2 sans-serif" should set the property value Fail e.style['font'] = "normal normal lighter semi-condensed calc(30% - 40px)/calc(120% + 1.2em) cursive" should set the property value -Fail e.style['font'] = "normal normal semi-expanded xx-small fantasy" should set the property value -Fail e.style['font'] = "normal normal expanded normal medium/normal monospace" should set the property value -Fail e.style['font'] = "normal normal extra-expanded italic xx-large/1.2 Menu" should set the property value +Pass e.style['font'] = "normal normal semi-expanded xx-small fantasy" should set the property value +Pass e.style['font'] = "normal normal expanded normal medium/normal monospace" should set the property value +Pass e.style['font'] = "normal normal extra-expanded italic xx-large/1.2 Menu" should set the property value Fail e.style['font'] = "normal normal ultra-expanded small-caps larger/calc(120% + 1.2em) \"FB Armada\"" should set the property value -Fail e.style['font'] = "normal normal ultra-condensed 100 smaller serif" should set the property value -Fail e.style['font'] = "normal oblique 10px/normal sans-serif" should set the property value -Fail e.style['font'] = "normal italic normal 20%/1.2 cursive" should set the property value +Pass e.style['font'] = "normal normal ultra-condensed 100 smaller serif" should set the property value +Pass e.style['font'] = "normal oblique 10px/normal sans-serif" should set the property value +Pass e.style['font'] = "normal italic normal 20%/1.2 cursive" should set the property value Fail e.style['font'] = "normal oblique normal normal calc(30% - 40px)/calc(120% + 1.2em) fantasy" should set the property value Fail e.style['font'] = "normal italic normal small-caps xx-small monospace" should set the property value -Fail e.style['font'] = "normal oblique normal 900 medium/normal Menu" should set the property value -Fail e.style['font'] = "normal italic normal extra-condensed xx-large/1.2 \"FB Armada\"" should set the property value +Pass e.style['font'] = "normal oblique normal 900 medium/normal Menu" should set the property value +Pass e.style['font'] = "normal italic normal extra-condensed xx-large/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "normal oblique small-caps larger/calc(120% + 1.2em) serif" should set the property value Fail e.style['font'] = "normal italic small-caps normal smaller sans-serif" should set the property value Fail e.style['font'] = "normal oblique small-caps bold 10px/normal cursive" should set the property value @@ -51,11 +52,11 @@ Fail e.style['font'] = "normal italic small-caps condensed 20%/1.2 fantasy" shou Fail e.style['font'] = "normal oblique bolder calc(30% - 40px)/calc(120% + 1.2em) monospace" should set the property value Fail e.style['font'] = "normal italic lighter normal xx-small Menu" should set the property value Fail e.style['font'] = "normal oblique 100 small-caps medium/normal \"FB Armada\"" should set the property value -Fail e.style['font'] = "normal italic 900 semi-condensed xx-large/1.2 serif" should set the property value +Pass e.style['font'] = "normal italic 900 semi-condensed xx-large/1.2 serif" should set the property value Fail e.style['font'] = "normal oblique semi-expanded larger/calc(120% + 1.2em) sans-serif" should set the property value -Fail e.style['font'] = "normal italic expanded normal smaller cursive" should set the property value +Pass e.style['font'] = "normal italic expanded normal smaller cursive" should set the property value Fail e.style['font'] = "normal oblique extra-expanded small-caps 10px/normal fantasy" should set the property value -Fail e.style['font'] = "normal italic ultra-expanded bold 20%/1.2 monospace" should set the property value +Pass e.style['font'] = "normal italic ultra-expanded bold 20%/1.2 monospace" should set the property value Fail e.style['font'] = "normal small-caps calc(30% - 40px)/calc(120% + 1.2em) Menu" should set the property value Fail e.style['font'] = "normal small-caps normal xx-small \"FB Armada\"" should set the property value Fail e.style['font'] = "normal small-caps normal normal medium/normal serif" should set the property value @@ -74,14 +75,14 @@ Fail e.style['font'] = "normal small-caps semi-condensed 10px/normal Menu" shoul Fail e.style['font'] = "normal small-caps semi-expanded normal 20%/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "normal small-caps expanded oblique calc(30% - 40px)/calc(120% + 1.2em) serif" should set the property value Fail e.style['font'] = "normal small-caps extra-expanded lighter xx-small sans-serif" should set the property value -Fail e.style['font'] = "normal 100 medium/normal cursive" should set the property value -Fail e.style['font'] = "normal 900 normal xx-large/1.2 fantasy" should set the property value +Pass e.style['font'] = "normal 100 medium/normal cursive" should set the property value +Pass e.style['font'] = "normal 900 normal xx-large/1.2 fantasy" should set the property value Fail e.style['font'] = "normal bold normal normal larger/calc(120% + 1.2em) monospace" should set the property value -Fail e.style['font'] = "normal bolder normal italic smaller Menu" should set the property value +Pass e.style['font'] = "normal bolder normal italic smaller Menu" should set the property value Fail e.style['font'] = "normal lighter normal small-caps 10px/normal \"FB Armada\"" should set the property value -Fail e.style['font'] = "normal 100 normal ultra-expanded 20%/1.2 serif" should set the property value +Pass e.style['font'] = "normal 100 normal ultra-expanded 20%/1.2 serif" should set the property value Fail e.style['font'] = "normal 900 oblique calc(30% - 40px)/calc(120% + 1.2em) sans-serif" should set the property value -Fail e.style['font'] = "normal bold italic normal xx-small cursive" should set the property value +Pass e.style['font'] = "normal bold italic normal xx-small cursive" should set the property value Fail e.style['font'] = "normal bolder oblique small-caps medium/normal fantasy" should set the property value Fail e.style['font'] = "normal lighter italic ultra-condensed xx-large/1.2 monospace" should set the property value Fail e.style['font'] = "normal 100 small-caps larger/calc(120% + 1.2em) Menu" should set the property value @@ -89,44 +90,44 @@ Fail e.style['font'] = "normal 900 small-caps normal smaller \"FB Armada\"" shou Fail e.style['font'] = "normal bold small-caps oblique 10px/normal serif" should set the property value Fail e.style['font'] = "normal bolder small-caps extra-condensed 20%/1.2 sans-serif" should set the property value Fail e.style['font'] = "normal lighter condensed calc(30% - 40px)/calc(120% + 1.2em) cursive" should set the property value -Fail e.style['font'] = "normal 100 semi-condensed normal xx-small fantasy" should set the property value -Fail e.style['font'] = "normal 900 semi-expanded italic medium/normal monospace" should set the property value +Pass e.style['font'] = "normal 100 semi-condensed normal xx-small fantasy" should set the property value +Pass e.style['font'] = "normal 900 semi-expanded italic medium/normal monospace" should set the property value Fail e.style['font'] = "normal bold expanded small-caps xx-large/1.2 Menu" should set the property value Fail e.style['font'] = "normal extra-expanded larger/calc(120% + 1.2em) \"FB Armada\"" should set the property value -Fail e.style['font'] = "normal ultra-expanded normal smaller serif" should set the property value -Fail e.style['font'] = "normal ultra-condensed normal normal 10px/normal sans-serif" should set the property value -Fail e.style['font'] = "normal extra-condensed normal oblique 20%/1.2 cursive" should set the property value +Pass e.style['font'] = "normal ultra-expanded normal smaller serif" should set the property value +Pass e.style['font'] = "normal ultra-condensed normal normal 10px/normal sans-serif" should set the property value +Pass e.style['font'] = "normal extra-condensed normal oblique 20%/1.2 cursive" should set the property value Fail e.style['font'] = "normal condensed normal small-caps calc(30% - 40px)/calc(120% + 1.2em) fantasy" should set the property value -Fail e.style['font'] = "normal semi-condensed normal bolder xx-small monospace" should set the property value -Fail e.style['font'] = "normal semi-expanded italic medium/normal Menu" should set the property value -Fail e.style['font'] = "normal expanded oblique normal xx-large/1.2 \"FB Armada\"" should set the property value +Pass e.style['font'] = "normal semi-condensed normal bolder xx-small monospace" should set the property value +Pass e.style['font'] = "normal semi-expanded italic medium/normal Menu" should set the property value +Pass e.style['font'] = "normal expanded oblique normal xx-large/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "normal extra-expanded italic small-caps larger/calc(120% + 1.2em) serif" should set the property value Fail e.style['font'] = "normal ultra-expanded oblique lighter smaller sans-serif" should set the property value Fail e.style['font'] = "normal ultra-condensed small-caps 10px/normal cursive" should set the property value Fail e.style['font'] = "normal extra-condensed small-caps normal 20%/1.2 fantasy" should set the property value Fail e.style['font'] = "normal condensed small-caps italic calc(30% - 40px)/calc(120% + 1.2em) monospace" should set the property value Fail e.style['font'] = "normal semi-condensed small-caps 100 xx-small Menu" should set the property value -Fail e.style['font'] = "normal semi-expanded 900 medium/normal \"FB Armada\"" should set the property value -Fail e.style['font'] = "normal expanded bold normal xx-large/1.2 serif" should set the property value +Pass e.style['font'] = "normal semi-expanded 900 medium/normal \"FB Armada\"" should set the property value +Pass e.style['font'] = "normal expanded bold normal xx-large/1.2 serif" should set the property value Fail e.style['font'] = "normal extra-expanded bolder oblique larger/calc(120% + 1.2em) sans-serif" should set the property value Fail e.style['font'] = "normal ultra-expanded lighter small-caps smaller cursive" should set the property value -Fail e.style['font'] = "italic 10px/normal fantasy" should set the property value -Fail e.style['font'] = "oblique normal 20%/1.2 monospace" should set the property value +Pass e.style['font'] = "italic 10px/normal fantasy" should set the property value +Pass e.style['font'] = "oblique normal 20%/1.2 monospace" should set the property value Fail e.style['font'] = "italic normal normal calc(30% - 40px)/calc(120% + 1.2em) Menu" should set the property value -Fail e.style['font'] = "oblique normal normal normal xx-small \"FB Armada\"" should set the property value +Pass e.style['font'] = "oblique normal normal normal xx-small \"FB Armada\"" should set the property value Fail e.style['font'] = "italic normal normal small-caps medium/normal serif" should set the property value -Fail e.style['font'] = "oblique normal normal 100 xx-large/1.2 sans-serif" should set the property value +Pass e.style['font'] = "oblique normal normal 100 xx-large/1.2 sans-serif" should set the property value Fail e.style['font'] = "italic normal normal ultra-condensed larger/calc(120% + 1.2em) cursive" should set the property value Fail e.style['font'] = "oblique normal small-caps smaller fantasy" should set the property value Fail e.style['font'] = "italic normal small-caps normal 10px/normal monospace" should set the property value Fail e.style['font'] = "oblique normal small-caps 900 20%/1.2 Menu" should set the property value Fail e.style['font'] = "italic normal small-caps extra-condensed calc(30% - 40px)/calc(120% + 1.2em) \"FB Armada\"" should set the property value -Fail e.style['font'] = "oblique normal bold xx-small serif" should set the property value -Fail e.style['font'] = "italic normal bolder normal medium/normal sans-serif" should set the property value +Pass e.style['font'] = "oblique normal bold xx-small serif" should set the property value +Pass e.style['font'] = "italic normal bolder normal medium/normal sans-serif" should set the property value Fail e.style['font'] = "oblique normal lighter small-caps xx-large/1.2 cursive" should set the property value Fail e.style['font'] = "italic normal 100 condensed larger/calc(120% + 1.2em) fantasy" should set the property value -Fail e.style['font'] = "oblique normal semi-condensed smaller monospace" should set the property value -Fail e.style['font'] = "italic normal semi-expanded normal 10px/normal Menu" should set the property value +Pass e.style['font'] = "oblique normal semi-condensed smaller monospace" should set the property value +Pass e.style['font'] = "italic normal semi-expanded normal 10px/normal Menu" should set the property value Fail e.style['font'] = "oblique normal expanded small-caps 20%/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "italic normal extra-expanded 900 calc(30% - 40px)/calc(120% + 1.2em) serif" should set the property value Fail e.style['font'] = "oblique small-caps xx-small sans-serif" should set the property value @@ -141,7 +142,7 @@ Fail e.style['font'] = "oblique small-caps extra-condensed xx-small cursive" sho Fail e.style['font'] = "italic small-caps condensed normal medium/normal fantasy" should set the property value Fail e.style['font'] = "oblique small-caps semi-condensed 900 xx-large/1.2 monospace" should set the property value Fail e.style['font'] = "italic bold larger/calc(120% + 1.2em) Menu" should set the property value -Fail e.style['font'] = "oblique bolder normal smaller \"FB Armada\"" should set the property value +Pass e.style['font'] = "oblique bolder normal smaller \"FB Armada\"" should set the property value Fail e.style['font'] = "italic lighter normal normal 10px/normal serif" should set the property value Fail e.style['font'] = "oblique 100 normal small-caps 20%/1.2 sans-serif" should set the property value Fail e.style['font'] = "italic 900 normal semi-expanded calc(30% - 40px)/calc(120% + 1.2em) cursive" should set the property value @@ -149,17 +150,17 @@ Fail e.style['font'] = "oblique bold small-caps xx-small fantasy" should set the Fail e.style['font'] = "italic bolder small-caps normal medium/normal monospace" should set the property value Fail e.style['font'] = "oblique lighter small-caps expanded xx-large/1.2 Menu" should set the property value Fail e.style['font'] = "italic 100 extra-expanded larger/calc(120% + 1.2em) \"FB Armada\"" should set the property value -Fail e.style['font'] = "oblique 900 ultra-expanded normal smaller serif" should set the property value +Pass e.style['font'] = "oblique 900 ultra-expanded normal smaller serif" should set the property value Fail e.style['font'] = "italic bold ultra-condensed small-caps 10px/normal sans-serif" should set the property value -Fail e.style['font'] = "oblique extra-condensed 20%/1.2 cursive" should set the property value +Pass e.style['font'] = "oblique extra-condensed 20%/1.2 cursive" should set the property value Fail e.style['font'] = "italic condensed normal calc(30% - 40px)/calc(120% + 1.2em) fantasy" should set the property value -Fail e.style['font'] = "oblique semi-condensed normal normal xx-small monospace" should set the property value +Pass e.style['font'] = "oblique semi-condensed normal normal xx-small monospace" should set the property value Fail e.style['font'] = "italic semi-expanded normal small-caps medium/normal Menu" should set the property value -Fail e.style['font'] = "oblique expanded normal bolder xx-large/1.2 \"FB Armada\"" should set the property value +Pass e.style['font'] = "oblique expanded normal bolder xx-large/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "italic extra-expanded small-caps larger/calc(120% + 1.2em) serif" should set the property value Fail e.style['font'] = "oblique ultra-expanded small-caps normal smaller sans-serif" should set the property value Fail e.style['font'] = "italic ultra-condensed small-caps lighter 10px/normal cursive" should set the property value -Fail e.style['font'] = "oblique extra-condensed 100 20%/1.2 fantasy" should set the property value +Pass e.style['font'] = "oblique extra-condensed 100 20%/1.2 fantasy" should set the property value Fail e.style['font'] = "italic condensed 900 normal calc(30% - 40px)/calc(120% + 1.2em) monospace" should set the property value Fail e.style['font'] = "oblique semi-condensed bold small-caps xx-small Menu" should set the property value Fail e.style['font'] = "small-caps medium/normal \"FB Armada\"" should set the property value @@ -214,14 +215,14 @@ Fail e.style['font'] = "small-caps semi-expanded italic bold medium/normal Menu" Fail e.style['font'] = "small-caps expanded bolder xx-large/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "small-caps extra-expanded lighter normal larger/calc(120% + 1.2em) serif" should set the property value Fail e.style['font'] = "small-caps ultra-expanded 100 oblique smaller sans-serif" should set the property value -Fail e.style['font'] = "900 10px/normal cursive" should set the property value -Fail e.style['font'] = "bold normal 20%/1.2 fantasy" should set the property value +Pass e.style['font'] = "900 10px/normal cursive" should set the property value +Pass e.style['font'] = "bold normal 20%/1.2 fantasy" should set the property value Fail e.style['font'] = "bolder normal normal calc(30% - 40px)/calc(120% + 1.2em) monospace" should set the property value Fail e.style['font'] = "lighter normal normal normal xx-small Menu" should set the property value -Fail e.style['font'] = "100 normal normal italic medium/normal \"FB Armada\"" should set the property value +Pass e.style['font'] = "100 normal normal italic medium/normal \"FB Armada\"" should set the property value Fail e.style['font'] = "900 normal normal small-caps xx-large/1.2 serif" should set the property value Fail e.style['font'] = "bold normal normal ultra-condensed larger/calc(120% + 1.2em) sans-serif" should set the property value -Fail e.style['font'] = "bolder normal oblique smaller cursive" should set the property value +Pass e.style['font'] = "bolder normal oblique smaller cursive" should set the property value Fail e.style['font'] = "lighter normal italic normal 10px/normal fantasy" should set the property value Fail e.style['font'] = "100 normal oblique small-caps 20%/1.2 monospace" should set the property value Fail e.style['font'] = "900 normal italic extra-condensed calc(30% - 40px)/calc(120% + 1.2em) Menu" should set the property value @@ -229,19 +230,19 @@ Fail e.style['font'] = "bold normal small-caps xx-small \"FB Armada\"" should se Fail e.style['font'] = "bolder normal small-caps normal medium/normal serif" should set the property value Fail e.style['font'] = "lighter normal small-caps oblique xx-large/1.2 sans-serif" should set the property value Fail e.style['font'] = "100 normal small-caps condensed larger/calc(120% + 1.2em) cursive" should set the property value -Fail e.style['font'] = "900 normal semi-condensed smaller fantasy" should set the property value -Fail e.style['font'] = "bold normal semi-expanded normal 10px/normal monospace" should set the property value -Fail e.style['font'] = "bolder normal expanded italic 20%/1.2 Menu" should set the property value +Pass e.style['font'] = "900 normal semi-condensed smaller fantasy" should set the property value +Pass e.style['font'] = "bold normal semi-expanded normal 10px/normal monospace" should set the property value +Pass e.style['font'] = "bolder normal expanded italic 20%/1.2 Menu" should set the property value Fail e.style['font'] = "lighter normal extra-expanded small-caps calc(30% - 40px)/calc(120% + 1.2em) \"FB Armada\"" should set the property value -Fail e.style['font'] = "100 oblique xx-small serif" should set the property value -Fail e.style['font'] = "900 italic normal medium/normal sans-serif" should set the property value -Fail e.style['font'] = "bold oblique normal normal xx-large/1.2 cursive" should set the property value +Pass e.style['font'] = "100 oblique xx-small serif" should set the property value +Pass e.style['font'] = "900 italic normal medium/normal sans-serif" should set the property value +Pass e.style['font'] = "bold oblique normal normal xx-large/1.2 cursive" should set the property value Fail e.style['font'] = "bolder italic normal small-caps larger/calc(120% + 1.2em) fantasy" should set the property value Fail e.style['font'] = "lighter oblique normal ultra-expanded smaller monospace" should set the property value Fail e.style['font'] = "100 italic small-caps 10px/normal Menu" should set the property value Fail e.style['font'] = "900 oblique small-caps normal 20%/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "bold italic small-caps ultra-condensed calc(30% - 40px)/calc(120% + 1.2em) serif" should set the property value -Fail e.style['font'] = "bolder oblique extra-condensed xx-small sans-serif" should set the property value +Pass e.style['font'] = "bolder oblique extra-condensed xx-small sans-serif" should set the property value Fail e.style['font'] = "lighter italic condensed normal medium/normal cursive" should set the property value Fail e.style['font'] = "100 oblique semi-condensed small-caps xx-large/1.2 fantasy" should set the property value Fail e.style['font'] = "900 small-caps larger/calc(120% + 1.2em) monospace" should set the property value @@ -255,46 +256,46 @@ Fail e.style['font'] = "bolder small-caps oblique expanded xx-large/1.2 monospac Fail e.style['font'] = "lighter small-caps extra-expanded larger/calc(120% + 1.2em) Menu" should set the property value Fail e.style['font'] = "100 small-caps ultra-expanded normal smaller \"FB Armada\"" should set the property value Fail e.style['font'] = "900 small-caps ultra-condensed italic 10px/normal serif" should set the property value -Fail e.style['font'] = "bold extra-condensed 20%/1.2 sans-serif" should set the property value +Pass e.style['font'] = "bold extra-condensed 20%/1.2 sans-serif" should set the property value Fail e.style['font'] = "bolder condensed normal calc(30% - 40px)/calc(120% + 1.2em) cursive" should set the property value Fail e.style['font'] = "lighter semi-condensed normal normal xx-small fantasy" should set the property value -Fail e.style['font'] = "100 semi-expanded normal oblique medium/normal monospace" should set the property value +Pass e.style['font'] = "100 semi-expanded normal oblique medium/normal monospace" should set the property value Fail e.style['font'] = "900 expanded normal small-caps xx-large/1.2 Menu" should set the property value Fail e.style['font'] = "bold extra-expanded italic larger/calc(120% + 1.2em) \"FB Armada\"" should set the property value -Fail e.style['font'] = "bolder ultra-expanded oblique normal smaller serif" should set the property value +Pass e.style['font'] = "bolder ultra-expanded oblique normal smaller serif" should set the property value Fail e.style['font'] = "lighter ultra-condensed italic small-caps 10px/normal sans-serif" should set the property value Fail e.style['font'] = "100 extra-condensed small-caps 20%/1.2 cursive" should set the property value Fail e.style['font'] = "900 condensed small-caps normal calc(30% - 40px)/calc(120% + 1.2em) fantasy" should set the property value Fail e.style['font'] = "bold semi-condensed small-caps oblique xx-small monospace" should set the property value -Fail e.style['font'] = "semi-expanded medium/normal Menu" should set the property value -Fail e.style['font'] = "expanded normal xx-large/1.2 \"FB Armada\"" should set the property value +Pass e.style['font'] = "semi-expanded medium/normal Menu" should set the property value +Pass e.style['font'] = "expanded normal xx-large/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "extra-expanded normal normal larger/calc(120% + 1.2em) serif" should set the property value -Fail e.style['font'] = "ultra-expanded normal normal normal smaller sans-serif" should set the property value -Fail e.style['font'] = "ultra-condensed normal normal italic 10px/normal cursive" should set the property value +Pass e.style['font'] = "ultra-expanded normal normal normal smaller sans-serif" should set the property value +Pass e.style['font'] = "ultra-condensed normal normal italic 10px/normal cursive" should set the property value Fail e.style['font'] = "extra-condensed normal normal small-caps 20%/1.2 fantasy" should set the property value Fail e.style['font'] = "condensed normal normal bolder calc(30% - 40px)/calc(120% + 1.2em) monospace" should set the property value -Fail e.style['font'] = "semi-condensed normal oblique xx-small Menu" should set the property value -Fail e.style['font'] = "semi-expanded normal italic normal medium/normal \"FB Armada\"" should set the property value +Pass e.style['font'] = "semi-condensed normal oblique xx-small Menu" should set the property value +Pass e.style['font'] = "semi-expanded normal italic normal medium/normal \"FB Armada\"" should set the property value Fail e.style['font'] = "expanded normal oblique small-caps xx-large/1.2 serif" should set the property value Fail e.style['font'] = "extra-expanded normal italic lighter larger/calc(120% + 1.2em) sans-serif" should set the property value Fail e.style['font'] = "ultra-expanded normal small-caps smaller cursive" should set the property value Fail e.style['font'] = "ultra-condensed normal small-caps normal 10px/normal fantasy" should set the property value Fail e.style['font'] = "extra-condensed normal small-caps oblique 20%/1.2 monospace" should set the property value Fail e.style['font'] = "condensed normal small-caps 100 calc(30% - 40px)/calc(120% + 1.2em) Menu" should set the property value -Fail e.style['font'] = "semi-condensed normal 900 xx-small \"FB Armada\"" should set the property value -Fail e.style['font'] = "semi-expanded normal bold normal medium/normal serif" should set the property value -Fail e.style['font'] = "expanded normal bolder italic xx-large/1.2 sans-serif" should set the property value +Pass e.style['font'] = "semi-condensed normal 900 xx-small \"FB Armada\"" should set the property value +Pass e.style['font'] = "semi-expanded normal bold normal medium/normal serif" should set the property value +Pass e.style['font'] = "expanded normal bolder italic xx-large/1.2 sans-serif" should set the property value Fail e.style['font'] = "extra-expanded normal lighter small-caps larger/calc(120% + 1.2em) cursive" should set the property value -Fail e.style['font'] = "ultra-expanded oblique smaller fantasy" should set the property value -Fail e.style['font'] = "ultra-condensed italic normal 10px/normal monospace" should set the property value -Fail e.style['font'] = "extra-condensed oblique normal normal 20%/1.2 Menu" should set the property value +Pass e.style['font'] = "ultra-expanded oblique smaller fantasy" should set the property value +Pass e.style['font'] = "ultra-condensed italic normal 10px/normal monospace" should set the property value +Pass e.style['font'] = "extra-condensed oblique normal normal 20%/1.2 Menu" should set the property value Fail e.style['font'] = "condensed italic normal small-caps calc(30% - 40px)/calc(120% + 1.2em) \"FB Armada\"" should set the property value -Fail e.style['font'] = "semi-condensed oblique normal 100 xx-small serif" should set the property value +Pass e.style['font'] = "semi-condensed oblique normal 100 xx-small serif" should set the property value Fail e.style['font'] = "semi-expanded italic small-caps medium/normal sans-serif" should set the property value Fail e.style['font'] = "expanded oblique small-caps normal xx-large/1.2 cursive" should set the property value Fail e.style['font'] = "extra-expanded italic small-caps 900 larger/calc(120% + 1.2em) fantasy" should set the property value -Fail e.style['font'] = "ultra-expanded oblique bold smaller monospace" should set the property value -Fail e.style['font'] = "ultra-condensed italic bolder normal 10px/normal Menu" should set the property value +Pass e.style['font'] = "ultra-expanded oblique bold smaller monospace" should set the property value +Pass e.style['font'] = "ultra-condensed italic bolder normal 10px/normal Menu" should set the property value Fail e.style['font'] = "extra-condensed oblique lighter small-caps 20%/1.2 \"FB Armada\"" should set the property value Fail e.style['font'] = "condensed small-caps calc(30% - 40px)/calc(120% + 1.2em) serif" should set the property value Fail e.style['font'] = "semi-condensed small-caps normal xx-small sans-serif" should set the property value @@ -307,13 +308,13 @@ Fail e.style['font'] = "extra-condensed small-caps oblique 900 20%/1.2 serif" sh Fail e.style['font'] = "condensed small-caps bold calc(30% - 40px)/calc(120% + 1.2em) sans-serif" should set the property value Fail e.style['font'] = "semi-condensed small-caps bolder normal xx-small cursive" should set the property value Fail e.style['font'] = "semi-expanded small-caps lighter italic medium/normal fantasy" should set the property value -Fail e.style['font'] = "expanded 100 xx-large/1.2 monospace" should set the property value +Pass e.style['font'] = "expanded 100 xx-large/1.2 monospace" should set the property value Fail e.style['font'] = "extra-expanded 900 normal larger/calc(120% + 1.2em) Menu" should set the property value -Fail e.style['font'] = "ultra-expanded bold normal normal smaller \"FB Armada\"" should set the property value -Fail e.style['font'] = "ultra-condensed bolder normal oblique 10px/normal serif" should set the property value +Pass e.style['font'] = "ultra-expanded bold normal normal smaller \"FB Armada\"" should set the property value +Pass e.style['font'] = "ultra-condensed bolder normal oblique 10px/normal serif" should set the property value Fail e.style['font'] = "extra-condensed lighter normal small-caps 20%/1.2 sans-serif" should set the property value Fail e.style['font'] = "condensed 100 italic calc(30% - 40px)/calc(120% + 1.2em) cursive" should set the property value -Fail e.style['font'] = "semi-condensed 900 oblique normal xx-small fantasy" should set the property value +Pass e.style['font'] = "semi-condensed 900 oblique normal xx-small fantasy" should set the property value Fail e.style['font'] = "semi-expanded bold italic small-caps medium/normal monospace" should set the property value Fail e.style['font'] = "expanded bolder small-caps xx-large/1.2 Menu" should set the property value Fail e.style['font'] = "extra-expanded lighter small-caps normal larger/calc(120% + 1.2em) \"FB Armada\"" should set the property value diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/cssom/border-shorthand-serialization.txt b/Tests/LibWeb/Text/expected/wpt-import/css/cssom/border-shorthand-serialization.txt index a91e5debfc2..079b8f7bb94 100644 --- a/Tests/LibWeb/Text/expected/wpt-import/css/cssom/border-shorthand-serialization.txt +++ b/Tests/LibWeb/Text/expected/wpt-import/css/cssom/border-shorthand-serialization.txt @@ -2,7 +2,8 @@ Harness status: OK Found 3 tests -3 Fail -Fail Declaration with border longhands is not serialized to a border shorthand declaration. -Fail Declaration with border longhands and border-image is not serialized to a border shorthand declaration. +2 Pass +1 Fail +Pass Declaration with border longhands is not serialized to a border shorthand declaration. +Pass Declaration with border longhands and border-image is not serialized to a border shorthand declaration. Fail Border shorthand is serialized correctly if all border-image-* are set to their initial specified values. \ No newline at end of file