From 1e26d3d02d0787a80dfa5e6eecb335d749c536f7 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Thu, 6 Oct 2022 12:19:33 +0200 Subject: [PATCH] LibWeb: Make the initial containing block style have `display:block` We always create a Layout::InitialContainingBlock for the ICB, but in a future where we always honor the CSS::Display everywhere, we need to make sure everyone has the right display values. --- Userland/Libraries/LibWeb/CSS/StyleComputer.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp b/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp index dcd3d6b8a4..36691a0f3b 100644 --- a/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp +++ b/Userland/Libraries/LibWeb/CSS/StyleComputer.cpp @@ -1212,6 +1212,7 @@ NonnullRefPtr StyleComputer::create_document_style() const absolutize_values(style, nullptr, {}); style->set_property(CSS::PropertyID::Width, CSS::LengthStyleValue::create(CSS::Length::make_px(viewport_rect().width()))); style->set_property(CSS::PropertyID::Height, CSS::LengthStyleValue::create(CSS::Length::make_px(viewport_rect().height()))); + style->set_property(CSS::PropertyID::Display, CSS::IdentifierStyleValue::create(CSS::ValueID::Block)); return style; }