-
Notifications
You must be signed in to change notification settings - Fork 669
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[css-lists][css-counter-styles] Define which symbols are not affected by font-family, and how exactly #6201
Comments
OK, I missed this text in https://drafts.csswg.org/css-counter-styles-3/#simple-symbolic
So browsers can do that to avoid changing the symbol depending on the font. But I guess we still need to decide what should happen if browser use actual text from the |
If there's a compat reason to restrict these keywords to browser images or browser-chosen fonts, we can do that. If there isn't, then maybe it's fine as-is? |
Yes, it seems there are compat reasons for using either browser images or browser-chosen fonts, at least in common cases. @MatsPalmgren is working on replacing the browser images with actual text in Firefox, and seemingly this will require using a And in #6200 (comment), @faceless2 said:
|
@MatsPalmgren @faceless2 Can you look over @Loirooriol's questions and clarify what you think we should spec here? It seems there are several options:
|
OK, so per resolutions in #3584 (comment),
I guess we can infer from 2 that things like these don't magically obtain the special rendering of @counter-style my-circle { system: cyclic; symbols: "◦"; suffix: " "; }
list-style-type: my-circle;
list-style-type: "◦ ";
list-style-type: symbols(cyclic "◦");
::marker { content: "◦ " } A remaining case is |
I don't understand what you mean by this example, there's nothing about it that invokes
Sounds right, tho that case should already work today, right? |
Yes, Chromium and Firefox don't use the special rendering when using |
Are you trying to imply that any counter style resembling the predefined symbolic's definition would get the same magic exception allowing for special drawing? I'm not sure where you'd infer that from. |
Right, that'll be an edit on Lists tho. |
Okay, explicit exception put in for the predefined symbolics, extending the existing "you can use an image" to be "or a UA-chosen font, if you're actually rendering text". The behavior of extending the predefined symbolics was handled in #3584; the behavior of any other counter style using the same characters doesn't need any tweaking or clarification because nothing implies they're special at all. |
Also restricted such special rendering to 'list-style-type'. |
The opposite, I'm saying that we can discard that possibility. |
If you have this code:
Then the font displays both
1.
of the ::marker and text node as blank.But in the 2nd item, we still see the
◦
of the ::marker, only the text node is blank.This was kinda explained in CSS2 https://www.w3.org/TR/CSS22/generate.html#list-style
However, according to https://drafts.csswg.org/css-counter-styles-3/#simple-symbolic,
circle
is just supposed to produce a U+25E6◦
, and CSS Lists doesn't say that ::marker should change the font-family or something.So reading the specs I would guess that the
◦
should disappear too, but that's probably bad for compat.So I think the specs should define what exactly happens. Implementations haven't been much consistent in the details:
list-style-type
set todisc
,circle
,square
,disclosure-open
,disclosure-close
? What if their definition is changed using@counter-style
?@counter-style
likelist-style-type: "◦ "
or::marker { content: "◦ " }
?::after { content: counter(c, circle) }
?The text was updated successfully, but these errors were encountered: