Skip to content

Commit 71ec46b

Browse files
committed
LibWeb: Don't treat calc() in used flex basis as definite for now
We'll eventually need some way to determine if a calc() value results in a definite size.
1 parent 7200b3a commit 71ec46b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Userland/Libraries/LibWeb/Layout/FlexFormattingContext.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -665,6 +665,10 @@ void FlexFormattingContext::determine_flex_base_size_and_hypothetical_main_size(
665665
return false;
666666
if (flex_basis.length_percentage->is_length())
667667
return true;
668+
if (flex_basis.length_percentage->is_calculated()) {
669+
// FIXME: Handle calc() in used flex basis.
670+
return false;
671+
}
668672
if (is_row_layout())
669673
return m_flex_container_state.has_definite_width();
670674
return m_flex_container_state.has_definite_height();

0 commit comments

Comments
 (0)