adobe / react-spectrum

A collection of libraries and tools that help you build adaptive, accessible, and robust user experiences.
https://react-spectrum.adobe.com
Apache License 2.0
12.75k stars 1.09k forks source link

`tailwindcss-react-aria-components` missing `enabled:` modifier #6650

Open somebody1234 opened 3 months ago

somebody1234 commented 3 months ago

Provide a general summary of the feature here

enabled: is provided by tailwind as the opposite of disabled:. tailwindcss-react-aria-components overrides disabled: but not enabled:

๐Ÿค” Expected Behavior?

enabled: modifier works with RAC

๐Ÿ˜ฏ Current Behavior

enabled: modifier does not work with RAC

๐Ÿ’ Possible Solution

No response

๐Ÿ”ฆ Context

I want to style a Tab differently only when it is not disabled:

๐Ÿ’ป Examples

No response

๐Ÿงข Your Company/Team

No response

๐Ÿ•ท Tracking Issue

No response

reidbarber commented 3 months ago

Currently, all states in the plugin map to specific render props, and we don't have one for enabled. I think [&:not([data-disabled])]: should work for this case though. We could add an enabled to the plugin that maps to that if we are ok diverging from 1:1 mappings to render props though.