at (269.333333,8) content-size 261.333333x17.46875 [BFC] children: inline
+ line 0 width: 9.46875, height: 17.46875, bottom: 17.46875, baseline: 13.53125
+ frag 0 from TextNode start: 0, length: 1, rect: [269.333333,8 9.46875x17.46875]
+ "b"
+ TextNode <#text>
+ BlockContainer
at (530.666666,8) content-size 261.333333x17.46875 [BFC] children: inline
+ line 0 width: 8.890625, height: 17.46875, bottom: 17.46875, baseline: 13.53125
+ frag 0 from TextNode start: 0, length: 1, rect: [530.666666,8 8.890625x17.46875]
+ "c"
+ TextNode <#text>
+ BlockContainer
at (8,25.46875) content-size 261.333333x17.46875 [BFC] children: inline
+ line 0 width: 7.859375, height: 17.46875, bottom: 17.46875, baseline: 13.53125
+ frag 0 from TextNode start: 0, length: 1, rect: [8,25.46875 7.859375x17.46875]
+ "d"
+ TextNode <#text>
diff --git a/Tests/LibWeb/Layout/input/grid/minmax-with-max-function-inside.html b/Tests/LibWeb/Layout/input/grid/minmax-with-max-function-inside.html
new file mode 100644
index 0000000000..6ecae650ec
--- /dev/null
+++ b/Tests/LibWeb/Layout/input/grid/minmax-with-max-function-inside.html
@@ -0,0 +1,6 @@
+
\ No newline at end of file
diff --git a/Userland/Libraries/LibWeb/CSS/Parser/Parser.cpp b/Userland/Libraries/LibWeb/CSS/Parser/Parser.cpp
index 4fc03f122e..bf230b31c9 100644
--- a/Userland/Libraries/LibWeb/CSS/Parser/Parser.cpp
+++ b/Userland/Libraries/LibWeb/CSS/Parser/Parser.cpp
@@ -7339,15 +7339,9 @@ ErrorOr
> Parser::parse_as_css_value(PropertyID property_id)
Optional Parser::parse_grid_size(ComponentValue const& component_value)
{
if (component_value.is_function()) {
- auto const& function = component_value.function();
- if (function.name().equals_ignoring_ascii_case("calc"sv)) {
- auto calculated_style_value = parse_calculated_value(function.values());
- if (calculated_style_value.is_error() || calculated_style_value.value().is_null()) {
- // FIXME: Propagate error
- return {};
- }
- return GridSize(LengthPercentage { *calculated_style_value.release_value() });
- }
+ if (auto maybe_dynamic = parse_dynamic_value(component_value); !maybe_dynamic.is_error() && maybe_dynamic.value())
+ return GridSize(LengthPercentage(maybe_dynamic.release_value()->as_calculated()));
+
return {};
}
auto token = component_value.token();