Accent-color not working in tailwind 3.0.23

Viewed 385

I just updated Tailwind to 3.0.22 in my Angular 11 project

Everything was okay but I would try the accent-color classes. But it didn't works, like this class didn't exists...

Here is my tailwind config file :

module.exports = {
    important: true,
    prefix: '',
    content: [
        '**/*.{html,ts}'
    ],
    darkMode: 'media', // or 'media' or 'class'
    theme: {
        backgroundSize: {
            'auto': 'auto',
            'cover': 'cover',
            'contain': 'contain',
            '50': '50%',
            '60': '60%',
            '70': '70%',
            '90': '90%',
            '100': '100%',
        },
        extend: {
            backgroundImage: () => ({
                'verifier': "url('../assets/imgs/Open-Capture_Verifier.svg')",
                'splitter': "url('../assets/imgs/Open-Capture_Splitter.svg')",
            }),
            width: {
                '30': '30%'
            },
            colors: {
                green: {
                    400: '#97BF3D'
                },
                gray: {
                    900: '#4C4C4E',
                    600: '#A7A8AA'
                }
            }
        },
    },
    plugins: [],
};

Any idea ?

Thanks

1 Answers

you should install the tailwind-accent-color module and add it to the plugins array of your Tailwind config.

Install using yarn

yarn add -D tailwind-accent-color

tailwind.config.js

plugins: [
  require('tailwind-accent-color')(),
]
Related