mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 07:58:11 +00:00
LibWeb: Parse calc() function in grid sizes
Adds missing part of grid size parsing function to handle calc().
This commit is contained in:
parent
7fee05e18c
commit
c2f6ba8f5f
4 changed files with 42 additions and 2 deletions
|
@ -48,6 +48,9 @@ Size GridSize::css_size() const
|
|||
return CSS::Size::make_auto();
|
||||
if (m_length_percentage.is_length())
|
||||
return CSS::Size::make_length(m_length_percentage.length());
|
||||
if (m_length_percentage.is_calculated()) {
|
||||
return CSS::Size::make_calculated(m_length_percentage.calculated());
|
||||
}
|
||||
return CSS::Size::make_percentage(m_length_percentage.percentage());
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue