mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 13:28:11 +00:00
LibWeb: Use none as initial value for grid-template-column/rows
This fixes the issue that currently we use "auto" as initial value for grid-template-column and grid-template-rows although spec says it should be "none". This makes a lot of difference for these properties because currently we represent "auto" as a list with one auto-sized track which means initial value for grid-template-column defines one "explicit" track while it should define none of them. This change makes grid-auto-columns/rows be applied to the correct tracks when initial values is used for grid-template-column/rows.
This commit is contained in:
parent
675cf43937
commit
3b3ade0b8d
9 changed files with 73 additions and 6 deletions
|
@ -6856,6 +6856,13 @@ Optional<CSS::ExplicitGridTrack> Parser::parse_track_sizing_function(ComponentVa
|
|||
|
||||
ErrorOr<RefPtr<StyleValue>> Parser::parse_grid_track_size_list(Vector<ComponentValue> const& component_values, bool allow_separate_line_name_blocks)
|
||||
{
|
||||
if (component_values.size() == 1 && component_values.first().is(Token::Type::Ident)) {
|
||||
auto ident = TRY(parse_identifier_value(component_values.first()));
|
||||
if (ident && ident->to_identifier() == ValueID::None) {
|
||||
return GridTrackSizeListStyleValue::make_none();
|
||||
}
|
||||
}
|
||||
|
||||
Vector<CSS::ExplicitGridTrack> track_list;
|
||||
Vector<Vector<String>> line_names_list;
|
||||
auto last_object_was_line_names = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue