Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tailwind css variables not working #2

Open
3 tasks done
AhmedTirhmert opened this issue Nov 20, 2024 · 1 comment
Open
3 tasks done

Tailwind css variables not working #2

AhmedTirhmert opened this issue Nov 20, 2024 · 1 comment

Comments

@AhmedTirhmert
Copy link

AhmedTirhmert commented Nov 20, 2024

As shown in the setup below after following the docs for customizing the template

image

  • created the globals.css file for custom variables/colors
  • updated components.json path to the globals.css that contains the variables
  • extended the tailwind CSS colors to include the added color

But when using the warning color in the index.vue file it doesn't work

PS: I also tried to extend the tailwind config without using variables and yet it still doesn't work

image

@AhmedTirhmert AhmedTirhmert closed this as not planned Won't fix, can't repro, duplicate, stale Nov 21, 2024
@AhmedTirhmert AhmedTirhmert reopened this Nov 21, 2024
@dianprata
Copy link
Owner

i am use unocss, so you have to custom your colors in uno.config.ts.
add this code to uno.config.ts, but in unocss for custom colors in dark and light mode, you have to add new preset.
theme: { colors: { 'warning': 'hsl(38 92% 50%)', 'warning-foreground': 'hsl(48 96% 89%)', }, },

ref: unocss/unocss#1390

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants