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

docs: (v4) using daisyUI color variables with tailwind gradient color stops #3303

Closed
ebarooni opened this issue Dec 5, 2024 · 2 comments
Closed

Comments

@ebarooni
Copy link

ebarooni commented Dec 5, 2024

On which page do you see this issue?

https://daisyui.com/docs/colors/

Describe the issue

Im trying to use the daisyUI colors with the gradient color stops from tailwind. But im not sure if i understood the docs correctly.

I would like to give my element a color gradient and from what i understood the tailwind classes can be used with daisyUI color variables. Therefore the following snippet:

<div class="bg-gradient-to-t from-bg-base-300">...</div>

However this does not apply the color. The same snippet if i use any tailwind color variable, for example from-indigo-500, works as expected. Is there a possibility to make this combination work or my implementation is wrong? Tnx!

What browsers are you seeing the problem on?

All browsers

Copy link

github-actions bot commented Dec 5, 2024

Thank you @ebarooni for reporting issues. It helps daisyUI a lot 💚
I'll be working on issues one by one. I will help with this one as soon as a I find a solution.
In the meantime providing more details and reproduction links would be helpful.

@saadeghi
Copy link
Owner

saadeghi commented Dec 5, 2024

- <div class="bg-gradient-to-t from-bg-base-300">...</div>
+ <div class="bg-gradient-to-t from-base-300">...</div>

base-300 is color name. bg-*, from-*, etc are utility classes.

@saadeghi saadeghi closed this as completed Dec 5, 2024
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