RESOLVED FIXED 221210
[css-flexbox] Do not use margins when computing aspect ratio cross sizes
https://bugs.webkit.org/show_bug.cgi?id=221210
Summary [css-flexbox] Do not use margins when computing aspect ratio cross sizes
Sergio Villar Senin
Reported 2021-02-01 08:31:50 PST
[css-flexbox] Do not use margins when computing aspect ratio cross sizes
Attachments
Patch (6.93 KB, patch)
2021-02-01 08:44 PST, Sergio Villar Senin
no flags
Patch (9.66 KB, patch)
2021-05-12 04:57 PDT, Sergio Villar Senin
jfernandez: review+
ews-feeder: commit-queue-
Sergio Villar Senin
Comment 1 2021-02-01 08:44:05 PST
Radar WebKit Bug Importer
Comment 2 2021-02-08 08:32:14 PST
Javier Fernandez
Comment 3 2021-03-04 06:54:15 PST
Comment on attachment 418880 [details] Patch View in context: https://b.webkit.org/attachment.cgi?id=418880&action=review > Source/WebCore/rendering/RenderFlexibleBox.cpp:789 > + crossSize = adjustForBoxSizing(*this, containerCrossSizeLength) - crossAxisMarginExtentForChild(child); What should we do if the box-sizing is 0 ? Do we have tests for that case ?
Sergio Villar Senin
Comment 4 2021-04-13 02:26:09 PDT
Comment on attachment 418880 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=418880&action=review >> Source/WebCore/rendering/RenderFlexibleBox.cpp:789 >> + crossSize = adjustForBoxSizing(*this, containerCrossSizeLength) - crossAxisMarginExtentForChild(child); > > What should we do if the box-sizing is 0 ? Do we have tests for that case ? You mean when the difference is negative? Perhaps we should clamp it indeed
Sergio Villar Senin
Comment 5 2021-05-12 04:57:21 PDT
Sergio Villar Senin
Comment 6 2021-05-12 04:58:29 PDT
Comment on attachment 418880 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=418880&action=review >>> Source/WebCore/rendering/RenderFlexibleBox.cpp:789 >>> + crossSize = adjustForBoxSizing(*this, containerCrossSizeLength) - crossAxisMarginExtentForChild(child); >> >> What should we do if the box-sizing is 0 ? Do we have tests for that case ? > > You mean when the difference is negative? Perhaps we should clamp it indeed I've added clamping in the last version of the patch along with a couple of extra test cases imported from WPT to increase coverage of the cases you mentioned.
EWS Watchlist
Comment 7 2021-05-12 04:58:48 PDT
This patch modifies the imported WPT tests. Please ensure that any changes on the tests (not coming from a WPT import) are exported to WPT. Please see https://trac.webkit.org/wiki/WPTExportProcess
Javier Fernandez
Comment 8 2021-05-12 05:44:26 PDT
Comment on attachment 428368 [details] Patch r=me
Sergio Villar Senin
Comment 9 2021-05-12 08:59:59 PDT
Note You need to log in before you can comment on or make changes to this bug.