New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define whether fieldset's legend should mask border-image #3930

Closed
zcorpan opened this Issue Aug 16, 2018 · 2 comments

Comments

2 participants
@zcorpan
Member

zcorpan commented Aug 16, 2018

See https://bugzilla.mozilla.org/show_bug.cgi?id=1279185

WebKit/Chromium doesn't mask the border-image. Gecko does (at the legend's border edge). EdgeHTML doesn't render border-image at all on fieldset.

cc @MatsPalmgren

@MatsPalmgren

This comment has been minimized.

Show comment
Hide comment
@MatsPalmgren

MatsPalmgren Aug 16, 2018

I don't see a reason for border-image borders to behave differently from other type of borders. But yes, we should specify somewhere how fieldset borders should be rendered in general.
I have a attached a few more testcases on the bug you referenced above where Firefox renders it differently than Chrome. It appears that Chrome clips the border entirely in the block-axis whereas Firefox only clips it to the extent of the legend's border box (i.e. if the border is thicker than the legend's block-size then the border renders above/below it.)
It actually looks like both UAs handles its image borders and ordinary borders consistently.

MatsPalmgren commented Aug 16, 2018

I don't see a reason for border-image borders to behave differently from other type of borders. But yes, we should specify somewhere how fieldset borders should be rendered in general.
I have a attached a few more testcases on the bug you referenced above where Firefox renders it differently than Chrome. It appears that Chrome clips the border entirely in the block-axis whereas Firefox only clips it to the extent of the legend's border box (i.e. if the border is thicker than the legend's block-size then the border renders above/below it.)
It actually looks like both UAs handles its image borders and ordinary borders consistently.

@zcorpan

This comment has been minimized.

Show comment
Hide comment
@zcorpan

zcorpan Aug 17, 2018

Member

Indeed there is a difference between browsers with normal borders:

http://software.hixie.ch/utilities/js/live-dom-viewer/saved/6115

WebKit/Chromium/EdgeHTML have the same behavior, so I think I'll specify that.

Member

zcorpan commented Aug 17, 2018

Indeed there is a difference between browsers with normal borders:

http://software.hixie.ch/utilities/js/live-dom-viewer/saved/6115

WebKit/Chromium/EdgeHTML have the same behavior, so I think I'll specify that.

zcorpan added a commit that referenced this issue Sep 19, 2018

Revamp how fieldset and legend rendering is defined
Properly define the rendering of the fieldset and legend elements.

The layout model used is most similar to Gecko, which uses an anonymous box to hold the fieldset's contents.

Fixes #3955, fixes #3930, fixes #3929, fixes #3928, fixes #3927, fixes #3915, fixes #3913, fixes #3660, fixes #3331, fixes #2756, fixes #4013.

Tests:
https://github.com/web-platform-tests/wpt/tree/master/html/rendering/non-replaced-elements/the-fieldset-and-legend-elements
https://github.com/web-platform-tests/wpt/tree/master/html/semantics/forms/the-fieldset-element
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment