Re: [csswg-drafts] [css-values-3] Restrict none/auto/normal from <custom-ident> (#7431)

The CSS Working Group just discussed `[css-values-3] Restrict none/auto/normal from <custom-ident>`.

<details><summary>The full IRC log of that discussion</summary>
&lt;fantasai> Topic: [css-values-3] Restrict none/auto/normal from &lt;custom-ident><br>
&lt;fantasai> github: [css-values-3] Restrict none/auto/normal from &lt;custom-ident><br>
&lt;fantasai> github: https://github.com/w3c/csswg-drafts/issues/7431#issuecomment-1178237576<br>
&lt;fantasai> TabAtkins: In the definition for &lt;custom-ident> in Values and Units<br>
&lt;fantasai> TabAtkins: can be any keyword, except CSS-wide keywords<br>
&lt;fantasai> TabAtkins: can't name an animation "initial"<br>
&lt;fantasai> TabAtkins: any other keywords that need to be xcluded for grammatical ambiguity reasons, you need to specify that explicitly<br>
&lt;fantasai> TabAtkins: however, there's a handful of keywords that are used so often in properties, and seem so not-very-useful for naming things<br>
&lt;fantasai> TabAtkins: that it might make sense to restrict them as well<br>
&lt;fantasai> TabAtkins: specifically: auto, none, normal<br>
&lt;fantasai> TabAtkins: these are used in a lot of properties, and are not good names for animations/counter-styles/etc.<br>
&lt;fantasai> TabAtkins: First question is, are sites using these ?<br>
&lt;fantasai> TabAtkins: dbaron did an initial analysis, and while they are used in a few places<br>
&lt;fantasai> TabAtkins: they appear to be invalid in those places anywhere<br>
&lt;fantasai> TabAtkins: e.g. 'none' as a line name in Grid, but [missed example]<br>
&lt;fantasai> TabAtkins: so makes sense to treat as invalid anyway<br>
&lt;fantasai> TabAtkins: I believe compat impact will be minimal to none<br>
&lt;fantasai> TabAtkins: all uses we saw were already invalid<br>
&lt;plinss> q+<br>
&lt;fantasai> TabAtkins: and this should make custom idents safer to use in general, without us having to remember to explicitly cut out these common keywords<br>
&lt;andreubotella> s/[missed example]/no 'none' line<br>
&lt;fantasai> TabAtkins: so that's the proposal -- restrict none/auto/normal from &lt;custom-ident><br>
&lt;fantasai> plinss: If using 'none' as a line name now, would that invalidate the line name or the whole declaration<br>
&lt;fantasai> TabAtkins: invalidate the whole declaration<br>
&lt;fantasai> plinss: That's more breakage than making valid but matching nothing<br>
&lt;fantasai> plinss: That said, I'm not too concerned<br>
&lt;dbaron> One other example I've seen is the use of `auto` as a named toggle state in https://toggles.oddbird.net/#named-modes<br>
&lt;fantasai> plinss: probably too late to do anything, allowing custom-idents without prefixing was risky in the first place<br>
&lt;Rossen_> ack plinss<br>
&lt;fantasai> TabAtkins: definitely it's a problem we should avoid<br>
&lt;fantasai> plinss: Should we require that, and not repeat this mistake that allows potentially conflicting &lt;custom-ident><br>
&lt;fantasai> TabAtkins: Could do that, make these legacy<br>
&lt;fantasai> fantasai: I would prefer to stay consistent with existing practice<br>
&lt;fantasai> fantasai: Anyway that's outside the scope of the issue<br>
&lt;fantasai> dbaron: There are probably some uses of &lt;custom-ident> that could be &lt;ident> because don't conflict with other stuff<br>
&lt;fantasai> dbaron: not sure if that's one of them<br>
&lt;fantasai> TabAtkins: names, toggle-state, and line names won't<br>
&lt;fantasai> TabAtkins: problems are things like animation-name, which we screwed up on, and don't want to repeat that<br>
&lt;fantasai> plinss: original sin here was unquoted font names, all kinds of problems from day 1<br>
&lt;fantasai> fantasai: Back to original issue, do we exclude these keywords? I propose to accept<br>
&lt;fantasai> TabAtkins: I'm now less convinced that we should<br>
&lt;fantasai> TabAtkins: maybe revisit grammar, and require only using in unambiguous contexts like line names<br>
&lt;fantasai> TabAtkins: Let's not screw it up again<br>
&lt;fantasai> fantasai: I still think it's worth excluding these keywords<br>
&lt;fantasai> TabAtkins: I say take it back to issue<br>
</details>


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


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

Received on Wednesday, 12 October 2022 16:42:45 UTC