The default bug view has changed. See this FAQ.

overflow not implemented for legend elements inside fieldset

RESOLVED FIXED in mozilla14

Status

()

Core
Layout
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: lifescholar, Assigned: mats)

Tracking

({testcase})

Trunk
mozilla14
testcase
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Reporter)

Description

5 years ago
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20120329 Firefox/14.0a1
Build ID: 20120329031156

Steps to reproduce:

Navigate to page http://forms.enfield.gov.uk/swiftlg/apas/run/wphappcriteria.display


Actual results:

Text box labels display incorrectly in Nightly 14 Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20120329 Firefox/14.0a1 ID:20120329031156

The "correct" text box labels seem to be overlayed with an incorrect set of labels that obscure the correct ones and should not be displayed.


Expected results:

Text box labels appear fine in IE 9.

Comment 1

5 years ago
What happens is the page tries to hide legend content through setting overflow: hidden and width/height: 0;

Firefox doesn't apply overflow on legend elements and as far as i can tell never have (not sure about the standards).

The obvious solution would be for the page to use display: none; in its .hidden class instead.

Comment 2

5 years ago
Created attachment 611299 [details]
sample html

Firefox shows the text of legend.
Opera and Chrome does not show the text of legend.

Updated

5 years ago
Component: Untriaged → Layout
Product: Firefox → Core
QA Contact: untriaged → layout
Version: 14 Branch → Trunk
The standards don't define the behavior of <legend> at all.

We could pretty easily convert overflow:hidden on <legend> into a cliprect.  Actually supporting scrolling on it would take more work, but might be a good idea...

Comment 4

5 years ago
(In reply to Cork from comment #1)
> Firefox doesn't apply overflow on legend elements and as far as i can tell
> never have (not sure about the standards).

I was aware that this bug exists for fieldset (bug 261037 and bug 504622) and table-caption (partly, bug 553977), but I didn't know that the legend element is affected as well.

> The obvious solution would be for the page to use display: none; in its
> .hidden class instead.

The website tries to hide the labels in an accessible manner using absolute positioning, but that doesn't work, because 'absolute' is misspelled 'adsolute'.
That's all what's needed to fix the website.

(In reply to Boris Zbarsky (:bz) from comment #3)
> The standards don't define the behavior of <legend> at all.

Apparently a short text has been added to HTML5's list of expectations not long ago:
http://www.w3.org/TR/html5/rendering.html#rendered-legend

But that's still no real definition.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: testcase
OS: Windows 7 → All
Hardware: x86_64 → All
Summary: Text box labelling incorrect in web page → overflow not implemented for legend elements inside fieldset
(Assignee)

Updated

5 years ago
Assignee: nobody → matspal
(Assignee)

Comment 5

5 years ago
Created attachment 613093 [details] [diff] [review]
fix+test

https://tbpl.mozilla.org/?usebuildbot=1&tree=Try&rev=b45df8f3f8a7
Attachment #613093 - Flags: review?(bzbarsky)
Comment on attachment 613093 [details] [diff] [review]
fix+test

r=me
Attachment #613093 - Flags: review?(bzbarsky) → review+
(Assignee)

Comment 7

5 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/843a8a7b54c5
Flags: in-testsuite+
Target Milestone: --- → mozilla14
https://hg.mozilla.org/mozilla-central/rev/843a8a7b54c5
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
(Reporter)

Comment 9

5 years ago
Now fixed and tested OK in today's nightly build on original page showing problem.

Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20120415 Firefox/14.0a1 ID:20120415030725
You need to log in before you can comment on or make changes to this bug.