Closed
Bug 297383
Opened 20 years ago
Closed 20 years ago
CSS bg color not rendered in certain case with div inside span
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
RESOLVED
INVALID
People
(Reporter: jma26, Assigned: dbaron)
References
()
Details
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.8) Gecko/20050511 Firefox/1.0.4 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.8) Gecko/20050511 Firefox/1.0.4 (with CSS class "bg" as a background color, and "txt" as a foreground color): The HTML <span class="bg"><div class="txt">(TEXT)</div></span> does not display the background color specified by CSS rule span.bg. But div.txt works correctly However, the following code does work correctly: <span class="txt"><div class="bg">(TEXT)</div></span> See the URL for more combinations Reproducible: Always Steps to Reproduce: 1. Display the HTML at the URL. 2. 3.
Updated•20 years ago
|
Assignee: nobody → dbaron
Component: General → Style System (CSS)
Product: Firefox → Core
QA Contact: general → ian
Version: unspecified → Trunk
Comment 1•20 years ago
|
||
That is invalid html, inline elements (span in your case) cannot contain block elemetns (the div) --> invalid
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → INVALID
Comment 2•19 years ago
|
||
José, we do allow span to contain div, actually. This bug is still invalid, but because of the way the CSS spec specifies rendering of a block-display child of an inline-display child...
You need to log in
before you can comment on or make changes to this bug.
Description
•