Closed
Bug 1457304
Opened 8 years ago
Closed 4 years ago
Empty text node generates text run in empty element with white-space:pre
Categories
(Core :: Layout: Block and Inline, defect, P3)
Core
Layout: Block and Inline
Tracking
()
RESOLVED
DUPLICATE
of bug 1731120
People
(Reporter: Oriol, Unassigned)
Details
Attachments
(1 file)
|
261 bytes,
text/html
|
Details |
Run this code:
<style>
div {
white-space: pre;
background: red;
}
</style>
There should be no red: <div></div>
<script>
document.querySelector("div").appendChild(document.createTextNode(""));
</script>
Result: the element contains a red text line
Expected: no text line because empty text nodes do not generate text runs. Chrome and Edge behave properly.
https://drafts.csswg.org/css-display-3/#intro
> If the sequence contains no text, however, it does not generate a text run.
Updated•8 years ago
|
Priority: -- → P3
| Reporter | ||
Comment 1•4 years ago
|
||
Fixed in bug 1731120
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•