-
Hi, I had a hard time figuring out how to use a custom theme when using only the Tailwind Standalone CLI. I followed the Rails + Bundle File instructions, which worked great. All the theme references in the documentation use I finally got it working by following the same format used in CDN theme files, such as daisyui@5/theme/light.css: @import "tailwindcss";
@plugin "./daisyui.js";
:root, :root:has(input.theme-controller[value=light]:checked), [data-theme="mytheme"] {
name: "mytheme";
default: true;
prefersdark: true;
color-scheme: "dark";
--color-base-100: oklch(12% 0.042 264.695);
...
} And it works! So, here’s my question/comment:
Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hey. To use custom themes with standalone file, ownload daisyui-theme.js as well:
Instead of
(replace Let me know if you have any questions |
Beta Was this translation helpful? Give feedback.
Hey.
It's not documented but I will add it to docs soon.
To use custom themes with standalone file, ownload daisyui-theme.js as well:
Instead of
@plugin "daisyui/theme" { ... }
, use it like(replace
path/to/
to address where the file is)Let me know if you have any questions