Bug 264303 - [css-flex] Flex layout incorrectly dirties preferred width bits towards the end of layout
Summary: [css-flex] Flex layout incorrectly dirties preferred width bits towards the e...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sammy Gill
URL:
Keywords: InRadar
: 266601 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-11-06 15:57 PST by Sammy Gill
Modified: 2023-12-20 10:33 PST (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sammy Gill 2023-11-06 15:57:35 PST
RenderFlexibleBox::layoutAndPlaceChildren will sometimes incorrectly dirty the preferred widths bit of flex items with a call to updateBlockChildDirtyBitsBeforeLayout. This is incorrect since this is down towards the end of layout and we never compute the preferred widths for flex items after this point. This dirtying should happen if the content of the flex item changes, since that is what the intrinsic sizes is based off of, or if there is some other related style change on the flexbox that could impact it (e.g. items with an aspect-ratio for the content based minimum size: https://drafts.csswg.org/css-flexbox-1/#content-based-minimum-size)
Comment 1 Sammy Gill 2023-11-06 15:58:44 PST
rdar://117181858
Comment 2 Sammy Gill 2023-11-06 17:10:34 PST
Pull request: https://github.com/WebKit/WebKit/pull/19807
Comment 3 EWS 2023-12-13 11:26:37 PST
Committed 271995@main (efb0cb853cc0): <https://commits.webkit.org/271995@main>

Reviewed commits have been landed. Closing PR #19807 and removing active labels.
Comment 4 Sammy Gill 2023-12-13 12:32:52 PST
Submitted web-platform-tests pull request: https://github.com/web-platform-tests/wpt/pull/43652
Comment 5 Sammy Gill 2023-12-20 09:23:35 PST
*** Bug 266601 has been marked as a duplicate of this bug. ***
Comment 6 Sammy Gill 2023-12-20 10:33:58 PST
For future context: The effects of this bug was first reported on https://www.amazon.com/stores/Jellycat/page/92DE52A7-85AC-40F4-A3A5-08B62869740E?ref_=ast_bln