Re: [csswg-drafts] Add a `::interest-hint` pseudo element to interest invokers (#12437)

> > Is this a good idea?
> 
> Sounds reasonable to me.

😄 

> > What should the pseudo element be called?
> 
> ::interest-hint sounds fine

I also thought of `::interest-button` which might be easier to understand?

> > It should be a tree-abiding pseudo element, correct?
> 
> Yes. Actually a fully styleable pseudo-element, probably.

Ahh right - I forgot about [that subset](https://drafts.csswg.org/css-pseudo/#fully-styleable). I agree.


> > Where does it live in the layout tree, relative to e.g. ::after and others?
> 
> I'm neutral on whether it comes before or after the ::after. Mildly inclined to say it's before, closer to the content, as ::after is often used for purposes that separate the element from other elements, and this needs to stay close to it.

Actually, given your logic, I think the conclusion might be that this pseudo belongs *after* the `::after`. E.g. this pseudo should feel like it's a button placed as a sibling to the element, in which case these separations should be between the element and the pseudo button. But that's just a very weak opinion.


> > Should there be a way to put it before the originating element also?
> 
> I wouldn't object, but I don't think it's strictly necessary. I suppose hints on headings are more likely to want to be in front, while hints on body text are more likely to want to be after?

I thought more about this, and I think [`::picker-icon`](https://drafts.csswg.org/css-forms-1/#picker-icon) might be the best precedent/comparison for this new pseudo. That one comes *after* the `::after`, and has no way to put it before the element. If the author wants to move it before, they can do that e.g. with flex properties or other positioning. WDYT?

> > Should hovering, focusing, or long-pressing the pseudo element also show interest in the originating element? (Seems a bit confusing to me, but maybe?)
> 
> It'll be a child of the originating element anyway, so hovering will work by default. I think they should all consistently work, then.

Ahh good point - you're right. And I think that seems fine.


-- 
GitHub Notification of comment by mfreed7
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12437#issuecomment-3137010281 using your GitHub account


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

Received on Wednesday, 30 July 2025 16:20:37 UTC