Skip to content

Commit

Permalink
LibWeb: User_scrollable now ignores overflow-hidden
Browse files Browse the repository at this point in the history
  • Loading branch information
NguyenH-T committed Apr 22, 2024
1 parent 511e411 commit 8a19d8a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Userland/Libraries/LibWeb/Layout/Box.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ bool Box::is_scroll_container() const
bool Box::is_user_scrollable() const
{
// FIXME: Support horizontal scroll as well (overflow-x)
if (computed_values().overflow_y() == CSS::Overflow::Hidden || computed_values().overflow_x() == CSS::Overflow::Hidden)
return false;

return computed_values().overflow_y() == CSS::Overflow::Scroll || computed_values().overflow_y() == CSS::Overflow::Auto;
}

Expand Down

0 comments on commit 8a19d8a

Please sign in to comment.