How can I override a CSS file from a module?
It is not possible to override CSS files from modules simply by creating a file with the same name in a theme.
Instead, the excludeDirs
directive has to be used in the theme's web/tailwind/postcss.config.js
file.
The steps to override a modules CSS in a theme are:
- Add the module directory to the
excludeDirs
directive as described in Module tailwind-source.css merging. - Copy the CSS files from the module to your themes
web/tailwind/theme
directory. - Import the new files in your themes
web/tailwind/tailwind-source.css
file. - Customize the CSS files from the module as required.