- From: Bramus via GitHub <sysbot+gh@w3.org>
- Date: Mon, 14 Oct 2024 21:01:37 +0000
- To: public-css-archive@w3.org
@LeaVerou Yes, that is the direction this issue headed into: white-space separated parts + only use an `ident()` function. Trying to pour the current direction into a CSS syntax, it’s this: ``` <ident-fn> = ident(<ident-args>); <ident-args> = [<string> | <attr()> | <var()> | <ident-fn>]+ ``` > _([#](https://github.com/w3c/csswg-drafts/issues/9141#issuecomment-2344375005))_ Tacking onto what @tabatkins [mentioned in the call](https://github.com/w3c/csswg-drafts/issues/8320#issuecomment-2344208387) about comma separated values: `ident()` could be crafted in such as way that you can pass in multiple options. The first option that returns something would determine the used value. > > Something like `ident(attr(id), attr(data-id), unique-id)` where it would first try to grab the `[id]` attribute, then the `[data-id]` attribute, and to finally fall back to an internally generated `unique-id`. In https://github.com/w3c/csswg-drafts/issues/10995#issuecomment-2395562334 I suggested something like a `first-non-empty(…)` for this. An alternative might be to define `<ident-fn>` as `ident(<ident-args>#)`. -- GitHub Notification of comment by bramus Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/9141#issuecomment-2412338261 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 14 October 2024 21:01:38 UTC