w3ctag / design-reviews

W3C specs and API reviews
Creative Commons Zero v1.0 Universal
318 stars 55 forks source link

improvements to <details> styling (widget structure) #965

Closed dbaron closed 2 weeks ago

dbaron commented 4 weeks ago

こんにちは TAG-さん!

I'm requesting a TAG review of improvements to <details> styling that address styling of the widget structure.

This is a set of changes to make the <details> and <summary> elements more stylable, with the overall goal of making issues with styleability no longer be an obstacle that prevents the use of HTML's built-in elements for this type of widget.

Further details:

LeaVerou commented 2 weeks ago

+1 from me, this solves a longstanding author pain point. The spec should clarify what pseudo-classes and pseudo-elements can be used on ::details-content (apologies if it's there, I didn't see it). See ::part() for an example of wording.

dbaron commented 2 weeks ago

The definition of ::details-content refers to the definition of a new part-like pseudo-element term, which is intended to make the rules for that equivalent to ::part(). Two of the things I'm hoping to do in the next few weeks are (1) implement that equivalence in the Chrome implementation and, while doing so, (2) verify that the spec actually makes the concepts match correctly.

martinthomson commented 2 weeks ago

@matatk, @plinss, and I discussed this one. Like @LeaVerou, we're enthusiastic about these changes.