Skip to content

[css-lists] Should list-item counter reset rule be in a UA stylesheet? #4244

@emilio

Description

@emilio

Or should it be browser-engine magic like the increment?

The TLDR is this. Gecko implements the counter reset as suggested in the appendix:

https://drafts.csswg.org/css-lists/#ua-stylesheet

Which is something like:

/* Set up ol and ul so that they scope the list-item counter */
ol, ul {
  counter-reset: list-item;
}

So the issue with doing it at the UA stylesheet level is that pages can override it.

We've received two reports of broken lists, the first of them is fixed, the second of them is from today. So arguably not a lot of breakage, but still worth discussing, I think.

cc @MatsPalmgren @tabatkins

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions