Open Bug 1971791 Opened 8 days ago Updated 18 hours ago

[wpt-sync] Sync PR 53021 - [layout] Fix AddChildBeforeDescendant for LayoutBlock.

Categories

(Core :: Layout: Grid, task, P4)

task

Tracking

()

People

(Reporter: wpt-sync, Unassigned)

References

(Depends on 1 open bug, )

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 53021 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/53021
Details from upstream follow.

Ian Kilpatrick <ikilpatrick@chromium.org> wrote:

[layout] Fix AddChildBeforeDescendant for LayoutBlock.

LayoutBlock handles the adding/removing children for
grid/flex/table-parts/etc.

AddChildBeforeDescendant previously was called from
LayoutBlockFlow::AddChild and LayoutBlock::AddChild, however there are
subtly different rules for both of them.

For grid/flex/etc, when inserting an OOF-positioned element, it should
split any anonymous blocks, and add the OOF-positioned at the top level.
We weren't previously doing this - instead we were adding it directly to
the anonymous block-flow.

As the rules are slightly different, split AddChildBeforeDescendant into
two private methods on each.

Bug: 40560663
Change-Id: I5fffe9597314c9d98dc499ab46b24ecd5a55aad2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6626458
Reviewed-by: David Grogan \<dgrogan@chromium.org>
Reviewed-by: Morten Stenshorne \<mstensho@chromium.org>
Commit-Queue: Ian Kilpatrick \<ikilpatrick@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1471901}

Component: web-platform-tests → Layout: Grid
Product: Testing → Core

CI Results

Ran 7 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 1 tests

Status Summary

Firefox

PASS: 1

Chrome

FAIL: 1

Safari

FAIL: 1

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

You need to log in before you can comment on or make changes to this bug.