- From: CSS Meeting Bot via GitHub <sysbot+gh@w3.org>
- Date: Fri, 27 Sep 2024 01:03:40 +0000
- To: public-css-archive@w3.org
The CSS Working Group just discussed `[selectors] Pseudo-class to indicate when a slot has content`. <details><summary>The full IRC log of that discussion</summary> <lea> q+<br> <khush> keithamus: has slotted is a pseudo class. it is the opposite of definition of default slotted<br> <khush> has slotted means that it has been slotted<br> <astearns> ack astearns<br> <khush> we resolved on the issue to just have the ... pseudo-class<br> <lea> s/... pseudo-/:has-slotted pseudo-/<br> <khush> a bare pseudo class. not functional one<br> <khush> i want a functional one which takes a compound selector<br> <khush> lea has raised a PR of non-functional pseudo-class<br> <khush> could we resolve on both<br> <khush> lea: there are distinct use-cases for both<br> <khush> the non-functional version is not an alias for :has with *<br> <khush> have chatted with implementors, bare version is easier<br> <khush> i want it to move fwd<br> <khush> there is confusion with has(slotted)<br> <dbaron> s/with */with *, because the non-functional version also matches text nodes/<br> <khush> we don't have slotted pseudo-class, only pseudo element<br> <khush> there is potential confusion in terms of authors not understanding<br> <khush> but functionality is clear<br> <khush> i'm not sure if i would be in favour of fallback based naming<br> <khush> since we want it for other use-cases<br> <emilio> q+<br> <khush> but just mentionning<br> <astearns> ack lea<br> <khush> emilio: the bare version is very straightforward<br> <dbaron> s/i'm not sure if/we could name it something related to fallback, but I'm not sure if/<br> <astearns> ack emilio<br> <khush> the functional version feels hard to implement. naming suggests we're looking at descendants. what's supported would be confusing<br> <lea> q+ to also mention :has-slotted variant that excludes whitespace-only slotted nodes<br> <TabAtkins> I don't think it would be that confusing. It would be interpreted basically identically to ::slotted()<br> <khush> keithamus: there is confusion around what combinators would do<br> <dbaron> s/for other use-cases/even if there's no fallback content/<br> <khush> should only match the slotted element<br> <TabAtkins> If ::slotted(.foo) would match an element, :has-slotted(.foo) will match<br> <fserb> q+<br> <khush> emilio: it might be worth naming it after nth-child perhaps<br> <khush> has it been considered?<br> <astearns> zakim, close queue<br> <Zakim> ok, astearns, the speaker queue is closed<br> <khush> the naming is off and confusing, otherwise it's fine<br> <khush> the bare version is extremely simple to implement<br> <khush> emilio: you mentioned you wanted it to also match fallback content.<br> <khush> lea: if we wanna change the naming to not confuse with has, it could be fallback-show<br> <khush> the matching would be the same logic<br> <khush> q?<br> <astearns> ack lea<br> <Zakim> lea, you wanted to also mention :has-slotted variant that excludes whitespace-only slotted nodes<br> <khush> lea: since this has to reflect the behaviour of existing js api<br> <khush> even if only slotted is blank white space node it still has to match<br> <khush> we want a bare slotted version which includes just whitespace<br> <khush> is that easy to implement><br> <khush> ?<br> <astearns> ack fserb<br> <khush> fserb: maybe the name would be better as revered<br> <khush> has-fallback-content for example<br> <lea> :fallback-shown is also nicely analogous to :placeholder-shown. What happens with that pseudo-class if there is no placeholder on the input?<br> <khush> keithamus: i like the symmetry between the 2. renaming would make them asymetrical and cause confusion<br> </details> -- GitHub Notification of comment by css-meeting-bot Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6867#issuecomment-2378207271 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Friday, 27 September 2024 01:03:41 UTC