Closed
Bug 241513
Opened 20 years ago
Closed 20 years ago
multi-line code examples render as one long line
Categories
(www.mozilla.org :: General, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: info, Assigned: endico)
References
()
Details
User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7b) Gecko/20040316 Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7b) Gecko/20040316 On this URL ("Using the Mozilla JavaScript interface to XSL Transformations"), the second code example starting "var testTransform =..." and the later example starting "var ownerDocument =..." both appear as one long line, even though in HTML source they are on multiple lines. This happens in Mozilla 1.7b Mac, Safari 1.2 and Mac MSIE 5.2. I think it's because the code samples use <code> nested inside <pre> which confuses default.css Reproducible: Always Steps to Reproduce: 1. Surf to this URL http://www.mozilla.org/projects/xslt/js-interface.html 2. Note the big scrollbar and the long single-line first example. 3. View > Source Actual Results: All three of my Mac browsers render the code samples as one long line, yet in source it is <pre><code>var testTransform = document.implementation.createDocument("", "test", null); // just an example to get a transform into a script as a DOM ... {</code> </pre> Expected Results: Multi-line code examples in a <pre>-formatted block should appear on multiple lines. To fix: A. If I remove the link to ../../css/default.css the sample code wraps as expected. B. If I remove the <code> tag inside the <pre> tag the sample code wraps as expected. So you do B to fix the page, but there may be some issue with the site's default.css.
Comment 1•20 years ago
|
||
code { white-space: nowrap; } in www.mozilla.org/css/default.css causes this
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Updated•16 years ago
|
Product: mozilla.org → Websites
Updated•12 years ago
|
Component: www.mozilla.org → General
Product: Websites → www.mozilla.org
You need to log in
before you can comment on or make changes to this bug.
Description
•