-
Notifications
You must be signed in to change notification settings - Fork 711
[css-lists][css-pseudo] the 'content' property should apply to ::marker #3499
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
Comments
WFM. And then we just define that the |
FWIW there's a precedent for |
As an author, I'd expect |
In all current major browsers, string It’s the fallback value and typed |
Hmm... I was thinking of https://bugzilla.mozilla.org/show_bug.cgi?id=1481150, where |
The current spec for ::marker was intentionally limited to make it easier to implement and to not be dependent on fully defining marker layout. We do intend that it will eventually apply. However the Lists and Generated Content modules are in a pretty rough state at the moment. |
@MatsPalmgren If you have this implemented, I'm happy to add it to the spec. But let me know if you think it'll add a hard dependency on defining marker layout? In which case maybe I'd suggest adding it as a note of future expectations for when we actually have a definition of marker layout... |
@fantasai we've implemented it by following the same code path as for If I don't think you need to block this on layout details for |
@MatsPalmgren Yeah, |
@MatsPalmgren - Tab and I cleaned up the Lists spec last week and defined the content interaction more precisely in https://drafts.csswg.org/css-lists-3/#content-property so I think this should be pretty straightforward to add now. Agenda+ to confirm incorporating it into that section and adding it to the list of properties in css-pseudo-4. |
The CSS Working Group just discussed
The full IRC log of that discussion<dael> Topic: the 'content' property should apply to ::marker<dael> github: https://github.com//issues/3499 <dael> fantasai: Moz has impl of this. TabAtkins and I cleaned up lists spec so what it needs to do with content interaction should be well defined. Proposal is to add the conten property back into pseudo elements applying to ::marker <dael> AmeliaBR: Content still set auto based on list prop? <dael> fantasai: Yes. Initial value is normal and thattakes content from list style prop <dael> AmeliaBR: So an author wouldn't have ot set content prop for marker to be rendered but could override it if want to do something special <dael> fantasai: Yes <dael> AmeliaBR: Makes sense to me <dael> fantasai: Any objections? <dael> plinss: Objections? <dael> gregwhitworth: Curious about use case. If they're in disc mode they'd replace with a new disc type? <dael> fantasai: background and display don't apply to markers. Case is I have an <ol> and I might want to change to include the chapter number or I might decide I want outside list marker styling and turn my headers into list items. You could do those kind of things <dael> gregwhitworth: How different then increment stuff? <dael> fantasai: You can say I want to use this piece of text. May or may not include a counter. More flexibility in terms of what you want in terms of things like punct <dael> AmeliaBR: Lots of use cases <ol> 20-1 but 3 2 1 are bronze/silver/gold <dael> fantasai: multipart listing is one of the biggest use cases. We should put an example in spec <dael> plinss: Objections? <dael> RESOLVED: the 'content' property should apply to ::marker |
Was also noted that we should definitely add some examples to the spec for common cases like 2.4.7 list numbering. |
The spec for the
content
property says that it applies to tree-abiding pseudo-elements.::marker
is a tree-abiding pseudo-element, however it explicitly excludes thecontent
property.I think this is a mistake, the
::marker
pseudo would be much more useful ifcontent
could be used on it. Making::marker
more like::before/::after
would also make it easier to understand, to specify and implement, since it wouldn't need to be treated specially. I think this would benefit all stake holders:content
in list-style-image and list-style-type and instead share more spec text for::marker/::before/::after
.::before/::after
to also handle::marker
. This means less code to write and maintain.content
property would make::marker
significantly more powerful.The text was updated successfully, but these errors were encountered: