Closed Bug 1831863 Opened 1 year ago Closed 1 year ago

We map the <dir type> attribute but other engines don't seem to

Categories

(Core :: DOM: Core & HTML, defect)

defect

Tracking

()

RESOLVED FIXED
115 Branch
Tracking Status
firefox115 --- fixed

People

(Reporter: emilio, Assigned: emilio)

Details

Attachments

(2 files)

data:text/html,<dir type="square"><li>Foo

Shows a square in Firefox, but a circle in WebKit and Blink. We have zero tests for this (this comes from a link that Marco sent me about areas of the code with no test coverage).

The spec says:

User agents must treat dir elements in a manner equivalent to ul elements in terms of semantics and for purposes of rendering.

Unclear whether that includes attribute mapping...

Given this needs a bit of special code, I'd propose to drop the attribute mapping (matching WebKit and Blink) and adding a WPT test to test it doesn't work. Alternatively we should file a spec bug to be explicit, and file WebKit and Blink bugs...

Simon, do you have any strong opinions here?

Flags: needinfo?(zcorpan)

The quoted text is indeed a bit unclear but the rendering part is, I think, more for UAs that don't fall into the https://html.spec.whatwg.org/multipage/infrastructure.html#renderingUA conformance class. The Rendering section is more precise for what the expected rendering is, and it only says type is a preshint for ul, ol, li: https://html.spec.whatwg.org/multipage/rendering.html#lists

I think I've discussed changing this at some point, but dir being obsolete and type is also obsolete on ul, it's not worth making it work. The shortest path to interop currently is to change Gecko.

Flags: needinfo?(zcorpan)

We also parsed the start attribute, but we actually don't use it.

Mapping of start broke in bug 288704, where it was migrated to map to
counter-reset, instead of being looked up by layout directly.

Assignee: nobody → emilio
Status: NEW → ASSIGNED

While I'm around let's remove redundant virtual keywords.

Depends on D177624

Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/ec98807a25aa Stop mapping <dir type> to list-style-type. r=zcorpan,smaug https://hg.mozilla.org/integration/autoland/rev/ffee8e3a7870 Drive by clean-ups to HTMLSharedElement. r=smaug
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/39928 for changes under testing/web-platform/tests
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 115 Branch
Upstream PR merged by moz-wptsync-bot
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: