::marker with non-normal content not displayed if ::before or ::after is a list item
Categories
(Core :: Layout, defect)
Tracking
()
Tracking | Status | |
---|---|---|
firefox68 | --- | fixed |
People
(Reporter: Oriol, Assigned: MatsPalmgren_bugz)
References
Details
(Keywords: testcase)
Attachments
(3 files)
.before > li::before {
content: 'before';
display: list-item;
list-style-position: inside;
}
.content > li::marker {
content: '1)';
}
<ol class="content"><li></li></ol>
<ol class="before"><li></li></ol>
<ol class="before content"><li></li></ol>
When ::marker wasn't implemented, this was displayed as
1.
1. 2. before
1. 2. before
Now it's displayed as
1)
1. 2. before
2. before
In the 3rd case, the marker of the element is not displayed! It should be
1)
1. 2. before
1) 2. before
This seems to happen when the ::marker has a non-normal
content
, and the element has a ::before or ::after pseudo-element which is a list item.
Comment 1•5 years ago
|
||
The content is there, it's just mispositioned. Mats, thoughts?
Assignee | ||
Comment 2•5 years ago
|
||
The bug occurs when we have a block child in the list item.
In that case, we position the marker box here:
https://searchfox.org/mozilla-central/rev/1b2636e8517aa48422ed516affe4d28cb7fa220a/layout/generic/nsBlockFrame.cpp#1287
with reflowOutput.BlockStartAscent() == 1073741823 (ASK_FOR_BASELINE)
because we never assigned it.
In the legacy code path we explicitly set it here:
https://searchfox.org/mozilla-central/rev/1b2636e8517aa48422ed516affe4d28cb7fa220a/layout/generic/nsBulletFrame.cpp#966
(so it's 15px once we get there, and so is position.mBaseline, so we set BStart = 0 there)
Assignee | ||
Comment 3•5 years ago
|
||
Assignee | ||
Updated•5 years ago
|
Pushed by mpalmgren@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/d37377e818b4 Add missing baseline alignment for non-legacy ::marker boxes when aligning to a "block line". r=emilio
Comment 5•5 years ago
|
||
bugherder |
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/16499 for changes under testing/web-platform/tests
Upstream PR merged
Description
•