WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED CONFIGURATION CHANGED
182595
WebKit mistakenly adds "margin-top" to intrinsic *width* calculation for floats
https://bugs.webkit.org/show_bug.cgi?id=182595
Summary
WebKit mistakenly adds "margin-top" to intrinsic *width* calculation for floats
Daniel Holbert
Reported
2018-02-07 19:18:46 PST
What steps will reproduce the problem? (1) Visit
https://jsfiddle.net/5rwq3m0o/
What is the expected result? Each teal div should have the same width. What happens instead? Each teal div is wider than the last. Please use labels and text to provide additional information. The only difference between the divs are "margin-top" values on their children. Apparently WebKit is mistakenly factoring this vertical margin into the width calculation, when accounting for the writing-mode difference between parent & child. Note: - Edge 16 gives "Expected results", with the teal divs all being just wide enough to fit the text. - Firefox Nightly 60 gives a less pretty version of "expected results", with the divs all being 4px wide (not doing layout on the text -- only wide enough for the borders) - Safari 11 and Chrome give the results that I'm reporting as buggy here, with the divs being wider if there's a larger 'margin-top' value on the child. Chrome version of this bug:
https://bugs.chromium.org/p/chromium/issues/detail?id=810231
Attachments
STP165 matches Firefox Nightly 113 but differ from Chrome Canary 113
(501.13 KB, image/png)
2023-03-20 17:03 PDT
,
Ahmad Saleem
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2018-02-08 16:38:11 PST
<
rdar://problem/37371418
>
Gérard Talbot (no longer involved)
Comment 2
2018-03-06 11:12:52 PST
Test on other shrink-to-fit width code scenarios:
http://www.gtalbot.org/BrowserBugsSection/CSS3WritingModes/Issue810231-margin-top-added-to-width-001.html
Ahmad Saleem
Comment 3
2023-03-20 17:03:46 PDT
Created
attachment 465530
[details]
STP165 matches Firefox Nightly 113 but differ from Chrome Canary 113 Just wanted to share updated test result. Thanks!
zalan
Comment 4
2023-03-23 15:45:16 PDT
Looks to be fixed.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug