- From: Lea Verou <lea@verou.me>
- Date: Wed, 4 May 2016 16:00:02 -0400
- To: "Tab Atkins Jr." <jackalmage@gmail.com>
- Cc: www-style list <www-style@w3.org>
> On 21Apr, 2016, at 14:24, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
>
> I propose a simple solution: rather than having "display:list-item"
> cause the ::marker to be generated, as is specced today, we make
> ::marker *always* exist, identical to ::before. For normal elements
> you have to explicitly give it a 'content' value, just like ::before.
> "display:list-item" then just makes the ::marker pay attention to the
> list-style-* properties.
>
> This would let us swap the <summary> UA style back to just:
>
> summary {
> display: block;
> }
> summary::marker {
> content: disclosure-closed;
> }
> details[open] > summary::marker {
> content: disclosure-open;
> }
>
> (We'd also redefine disclosure-open/closed from being counter styles
> to just being 'content' keywords with the same effect.)
Love this! Much cleaner than hijacking display: list-item, and avoids all the other problems. Not sure if implementors will think it's feasible, but I'm pretty sure that authors will love it. And it pushes toward more ::marker implementations as a side effect, which is great.
> fantasai offers an alternate proposal: leave <summary> as is, leave
> the hack for the first problem, but make the list-style-* properties
> actually only apply to the ::marker pseudo, rather than to list items.
> Inheritance ensures that we maintain today's behavior, but HTML can
> then set list-style-position:inside directly on the summary::marker,
> and avoid the second problem entirely.
>
> Thoughts?
Why? Your proposal above is fantastic, why go down this hacky path again?
~Lea
Received on Wednesday, 4 May 2016 20:02:36 UTC