Re: [csswg-drafts] [css-shadow-parts] Should `::part():lang()` and `::part():dir()` be valid? (#9795)

The CSS Working Group just discussed ``[css-shadow-parts] Should `::part():lang()` and `::part():dir()` be valid?``, and agreed to the following:

* `RESOLVED: :lang()/:dir() do apply to ::part`

<details><summary>The full IRC log of that discussion</summary>
&lt;fantasai> scribenick: fantasai<br>
&lt;fantasai> TabAtkins: Question is whether :lang() and :dir() should work on ::part pseudo-elements<br>
&lt;fantasai> TabAtkins: I think from specs they do, because ::part() allows all pseudo-classes to work except those that expose internal structure<br>
&lt;fantasai> TabAtkins: we want authors to be able to rearrange their shadow DOM with minimal disruption to authors<br>
&lt;fantasai> TabAtkins: The question was whether :lang()/:dir() expose structural information<br>
&lt;fantasai> TabAtkins: I believe the spirit of the restricitons aren't violated by these<br>
&lt;fantasai> TabAtkins: and use cases are reasonable to justify<br>
&lt;fantasai> emilio: could go either way, but it exposes potentially values of attributes in the shadow tree<br>
&lt;fantasai> emilio: could argue that you don't know where the info comes from<br>
&lt;fantasai> emilio: before discussing I had slight pref for not allowing, now could go either way<br>
&lt;TabAtkins> fantasai: with my i18n hat on<br>
&lt;dholbert> fantasai (IRC): with my i18n hat on<br>
&lt;TabAtkins> fantasai: i think if you're allowed to style these, you shoudl be allowed to use :lang() and :dir() to control that<br>
&lt;TabAtkins> fantasai: lots of styling that's lang or direction dependent, and if we're gonna allow it in the first place we shoudl allow it to be done proeprtly<br>
&lt;TabAtkins> fantasai: if you're exposing these parts, they'll probably contain things you've passed to the shadow, so you need to style them<br>
&lt;TabAtkins> emilio: lang and dir don't propagate to the stuff you've put in<br>
&lt;fantasai> fantasai: if you're allowing styling, you should allow selecting against lang/dir<br>
&lt;fantasai> TabAtkins: Are there objections to allowing :lang()/:dir() to match ::parts?<br>
&lt;fantasai> [tense silence]<br>
&lt;fantasai> TabAtkins: OK, then. I already have WPT for this<br>
&lt;fantasai> RESOLVED: :lang()/:dir() do apply to ::part<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9795#issuecomment-1944843994 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 14 February 2024 22:31:32 UTC