Closed thecrypticace closed 5 months ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
headlessui-react | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Apr 24, 2024 1:29pm |
headlessui-vue | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Apr 24, 2024 1:29pm |
@thecrypticace if I'm not mistaken we run all tests for the Combobox against a virtual and non-virtual version. So if you add a test where you explicitly test that data-disabled is present then that should cover this. Undoing your change should then result in a failing test.
We run all the "interaction" tests but not rendering tests. But this is simple enough to add a test for — will do!
Test added
When using a combobox disabled options get a
data-disabled
attribute that can be used for styling. However, when the combobox was virtualized we were not. This happened because we were only looking at the disabled prop on the option itself but a virtual combobox uses a disabled function in thevirtual
options to determine whether or not an option is enabled.This fixes that 👍
@RobinMalfait you have an idea on how this should be tested?