[webkit-changes] [WebKit/WebKit] 809b95: [margin-trim][block layout] Nested self-collapsing...

Sammy Gill noreply at github.com
Wed Apr 26 15:36:29 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 809b95bb1a78dc940c38c22f885c4e16925b9945
      https://github.com/WebKit/WebKit/commit/809b95bb1a78dc940c38c22f885c4e16925b9945
  Author: Sammy Gill <sammy.gill at apple.com>
  Date:   2023-04-26 (Wed, 26 Apr 2023)

  Changed paths:
    M LayoutTests/imported/w3c/web-platform-tests/css/css-box/margin-trim/computed-margin-values/block-container-block-end-nested-child-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/css/css-box/margin-trim/computed-margin-values/block-container-block-end-with-self-collapsing-children-expected.txt
    M Source/WebCore/rendering/RenderBlockFlow.cpp

  Log Message:
  -----------
  [margin-trim][block layout] Nested self-collapsing children at block-end should also be trimmed.
https://bugs.webkit.org/show_bug.cgi?id=255736
rdar://108327029

Reviewed by Alan Baradlay.

When walking back up the block container for the purposes of block-end
margin trimming we may run into a self collapsing child that needs to
have both of its margins trimmed and its position adjusted. However, it
is also possible that these self-collapsing children may also have other
self-collapsing children nested arbitrarily within. If that is the case,
we need to also trim the margins of all of its descendants.

* LayoutTests/imported/w3c/web-platform-tests/css/css-box/margin-trim/computed-margin-values/block-container-block-end-nested-child-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/css/css-box/margin-trim/computed-margin-values/block-container-block-end-with-self-collapsing-children-expected.txt:
* Source/WebCore/rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::trimBlockEndChildrenMargins):

Canonical link: https://commits.webkit.org/263439@main




More information about the webkit-changes mailing list