Summary: | [css-grid] Recalculate grid's auto repeat columns when grid's relative width to its containing block width changes | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | zsun | ||||||||||||
Component: | CSS | Assignee: | zsun | ||||||||||||
Status: | NEW --- | ||||||||||||||
Severity: | Normal | CC: | changseok, esprehn+autocc, ews-watchlist, glenn, jfernandez, kondapallykalyan, pdr, rbuis, rego, svillar, webkit-bug-importer | ||||||||||||
Priority: | P2 | Keywords: | InRadar | ||||||||||||
Version: | WebKit Nightly Build | ||||||||||||||
Hardware: | Unspecified | ||||||||||||||
OS: | Unspecified | ||||||||||||||
Attachments: |
|
Description
zsun
2021-10-05 04:13:46 PDT
Created attachment 440196 [details]
Patch
Created attachment 440205 [details]
Patch
Created attachment 440599 [details]
Patch
Comment on attachment 440599 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=440599&action=review > Source/WebCore/rendering/RenderBox.cpp:1099 > + return style().paddingStart().isPercentOrCalculated() || style().paddingEnd().isPercentOrCalculated() || (isRenderGrid() && hasRelativeLogicalWidth()) || (style().hasAspectRatio() && (hasRelativeLogicalHeight() || (isFlexItem() && hasStretchedLogicalHeight()))); If you make a RenderGrid::needsPreferredWidthsRecalculation you can get rid of the isRenderGrid check and keep this simpler. Created attachment 440770 [details]
Patch
Comment on attachment 440770 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=440770&action=review > Source/WebCore/rendering/RenderGrid.h:209 > + bool needsPreferredWidthsRecalculation() const final; Nit: in WebKit we keep the member vars and methods separate. In this case the method should go directly below aspectRatioPrefersInline. Created attachment 440775 [details]
Patch
I recall that we had an internal discussion with Javier on this patch and the solution here was not ideal. Make the patch as obselete. |