Closed shyakadavis closed 7 months ago
I tried to reproduce this and was unable to. Could you share the full source code in that file so I can try?
Hi, @mskelton
I prepared a repro; https://github.com/shyakadavis/twv-issue-repro
I got a better understanding of the issue, and the README should elaborate that.
Basically, intellisense fails for the lines below the one using the complex variant; anything before that works fine.
The file to look at is this; https://github.com/shyakadavis/twv-issue-repro/blob/main/src/lib/components/ui/button/index.ts
Let me know if you require anything else. 🙂
I don't know much about this, Had the same issue, I used the regex from cva https://cva.style/docs/getting-started/installation#intellisense, but just replaced with tv
and it seems to be working fine so far.
{
"tailwindCSS.experimental.classRegex": [
["tv\\(([^)]*)\\)", "[\"'`]([^\"'`]*).*?[\"'`]"]
]
}
Hey;
What do you mean, @opswiz? I have the same regex, and I even tried replacing it with that one from CVA, but it doesn't work.
Do you mind sharing a snippet of your final regex that works?
My bad, I assumed your regex was from the documentation. Its the same, but it seems to work for me. Let me check again. I have both cva and tv, I am making transitioning from cva -> tv. I could have messed up too.
Yes, its not working, I had a simple one directly inlined in jsx under classname hence it was working, when I moved it outside.
With the regex from the website, its forever loading and with the above regex its nothing.
hi any solution to this?
and thanks for this awesome module
I have the same issue
I'm closing this issue as the regex in the docs handles arbitrary variants properly. There is a related issue regarding the performance of the regex, but that's being tracked in #127
Describe the bug Hi.
When using Tailwind CSS arbitrary values, the intellisense stops working, loosing all autocomplete and Tailwind colours previews.
To Reproduce
shadow-[4px_4px_0px_rgba(0,0,0,1)]
Expected behavior Intellisense should still work regardless of me using arbitrary values or not.
Screenshots Before:
After using arbitrary values; notice how all previews disappear.
Desktop (please complete the following information):
Smartphone (please complete the following information):
N/A
Additional context I'm using this:
and also tried using this https://github.com/nextui-org/tailwind-variants/issues/127#issuecomment-1823185653
But it didn't help.