saadeghi / daisyui

๐ŸŒผ ๐ŸŒผ ๐ŸŒผ ๐ŸŒผ ๐ŸŒผ โ€ƒThe most popular, free and open-source Tailwind CSS component library
https://daisyui.com
MIT License
34.14k stars 1.3k forks source link

bug: 'themeRoot' does not exist in type 'DaisyUIConfig'. #3094

Closed flexchar closed 4 months ago

flexchar commented 5 months ago

What version of daisyUI are you using?

4.12.2

Which browsers are you seeing the problem on?

No response

Reproduction URL

-

Describe your issue

I am using types in my tailwind file and seems like theme root is forgotten, even though it works. :)

import daisyui, { type Config as DConfig } from 'daisyui';

/** @type {import('tailwindcss').Config} */
export default {
    content: [
        //
        './src/**/*.{tsx,ts,html}',
    ],
    plugins: [
        //
        daisyui,
    ],
    // https://daisyui.com/docs/config/
    // daisyUI config (optional - here are the default values)
    daisyui: {
        themes: ['light', 'dark'], // false: only light + dark | true: all themes | array: specific themes like this ["light", "dark", "cupcake"]
        darkTheme: 'dark', // name of one of the included themes for dark mode
        base: false, // applies background color and foreground color for root element by default
        styled: true, // include daisyUI colors and design decisions for all components
        utils: true, // adds responsive and modifier utility classes
        prefix: '', // prefix for daisyUI classnames (components, modifiers and responsive class names. Not colors)
        logs: false, // Shows info about daisyUI version and used config in the console when building your CSS
        themeRoot: '#container', // The element that receives theme color CSS variables
    } satisfies DConfig,
};
github-actions[bot] commented 5 months ago

Thank you @flexchar 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.