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

CSS Themes: Override base colours #44

Open
CharlRitterDev opened this issue Dec 13, 2023 · 1 comment
Open

CSS Themes: Override base colours #44

CharlRitterDev opened this issue Dec 13, 2023 · 1 comment

Comments

@CharlRitterDev
Copy link

Describe the bug
I have imported primereact/resources/themes/bootstrap4-light-blue/theme.css as a base theme for a project. I can override the base primary, secondary, etc. colours in the root, however, that isn't used in the theme itself, rather the colours are hardcoded.

Thus it seems that the only way to replace all the hardcoded colours (in this theme's case all the versions of bootstrap's blue), is to manually find all CSS classes and override them individually to change the colours to our project's colours.

Is there a better way of doing this, because changing these hardcoded instances to use the root-defined vars seems like it would make overriding much more straightforward?

PrimeReact version
10.2.1

React version
18.x

Language
TypeScript

Build / Runtime
Create React App (CRA)

@CharlRitterDev
Copy link
Author

This is possibly the same issue as experienced here

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

1 participant