Re: [csswg-drafts] [css-pseudo-5] ::text / ::text-node pseudoelement (#2208)

Having `::text` (as a real node) would also be supremely useful when doing something seemingly simple like hiding text next to an icon. Consider (using Font Awesome):
```
<a href="#"><i class="fa fa-gear"></i> Edit</a>
```
Currently, one must do tricks with `overflow: hidden` and `width` (or several varieties of this hack) to show just the icon. It would be wonderful to just have a rule `a ::text { display: none; }` (or better yet: `i.fa + ::text { display: none; }`

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


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

Received on Thursday, 11 January 2024 21:26:35 UTC