WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
219280
REGRESSION (?): Presence of whitespace after a hidden inline element moves the baseline
https://bugs.webkit.org/show_bug.cgi?id=219280
Summary
REGRESSION (?): Presence of whitespace after a hidden inline element moves th...
Kit Grose
Reported
2020-11-24 14:54:50 PST
Created
attachment 414852
[details]
HTML file demonstrating the issue Relatively recently, a WebKit change introduced a change to the way the baseline is computed which visually broke the navigation on a website I work on. After much experimentation, the issue seems to be that the presence of any whitespace following an inline element styled with `display: none` moves the baseline for that item, such that the surrounding `inline-block` elements no longer visually align to the baseline. Making the inline element visible corrects the problem, as does trimming the whitespace that follows it. The obvious workaround is to set `vertical-align` to any value other than `baseline`, which does correct the issue in this case. I've been unable to get the WebKit Build Archives to run on my Mac to confirm if it affects the latest builds of WebKit, and the Safari Technology Preview no longer runs on Mojave, but I have been able to get a friend to confirm the issue affects Safari 10.14 in macOS 11 (Big Sur) too. I have confirmed that the issue does not affect Firefox nor Chrome. Please find a trivial reproduction example attached. Boxes A and B should be aligned.
Attachments
HTML file demonstrating the issue
(371 bytes, text/html)
2020-11-24 14:54 PST
,
Kit Grose
no flags
Details
Screenshot of the output of the HTML test case
(554 bytes, image/png)
2020-11-24 14:57 PST
,
Kit Grose
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Kit Grose
Comment 1
2020-11-24 14:57:13 PST
Created
attachment 414853
[details]
Screenshot of the output of the HTML test case I've attached a screenshot of the output of the test case.
Radar WebKit Bug Importer
Comment 2
2020-11-30 09:31:10 PST
<
rdar://problem/71808556
>
Simon Fraser (smfr)
Comment 3
2020-11-30 10:17:01 PST
I can reproduce this in STP 110 but not in more recent builds.
Simon Fraser (smfr)
Comment 4
2020-11-30 10:20:18 PST
Seem to be related to whether Next-gen line layout integration is enabled.
Simon Fraser (smfr)
Comment 5
2020-12-01 08:50:08 PST
This is behaving correctly in recent trunk builds. Please test in the next Safari Tech Preview.
alan
Comment 6
2020-12-01 16:15:23 PST
progressed at
r268821
(
http://trac.webkit.org/changeset/268821/webkit
)
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