Native variant for custom states #13093
lukewarlow
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
See https://developer.mozilla.org/en-US/docs/Web/API/CustomStateSet
There's an API for web components to create their own pseudo classes, the syntax is
:state(<name>)
and this is supported in Safari 17.4 (https://webkit.org/blog/15063/webkit-features-in-safari-17-4/#:~:text=styled%20using%20the-,%3Astate(),-pseudo%2Dclass%20by), flagged support in Firefox 121 and Chromium has an old version of this feature (syntax:<name>
) but is shipping the new syntax atm.A variant for this in tailwind would be nice.
Beta Was this translation helpful? Give feedback.
All reactions