mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-25 17:25:08 +02:00
LibWeb/Layout: Make transform-style: preserve-3d establish APCBs
This commit is contained in:
Notes:
github-actions[bot]
2026-01-06 15:56:36 +00:00
Author: https://github.com/AtkinsSJ Commit: https://github.com/LadybirdBrowser/ladybird/commit/cc3e4274982 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/7158
@@ -122,6 +122,17 @@ bool Node::establishes_an_absolute_positioning_containing_block() const
|
||||
if (has_layout_containment() || has_paint_containment() || will_change_property(CSS::PropertyID::Contain))
|
||||
return true;
|
||||
|
||||
// https://drafts.csswg.org/css-transforms-2/#transform-style-property
|
||||
// A computed value of 'preserve-3d' for 'transform-style' on a transformable element establishes both a
|
||||
// stacking context and a containing block for all descendants.
|
||||
// FIXME: Check that the element is a transformable element.
|
||||
if (computed_values.transform_style() == CSS::TransformStyle::Preserve3d || will_change_property(CSS::PropertyID::TransformStyle))
|
||||
return true;
|
||||
|
||||
// https://drafts.csswg.org/css-view-transitions-1/#snapshot-containing-block-concept
|
||||
// FIXME: The snapshot containing block is considered to be an absolute positioning containing block and a fixed
|
||||
// positioning containing block for ::view-transition and its descendants.
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user