Change default colors of *-warning, *-primary, *-secondary,


Topic: Change default colors of *-warning, *-primary, *-secondary, and so on to my own defined colors

AstroSign asked 4 years ago

Expected behavior I can gobally change the default colors used by MDB5 to my own defined colors

Actual behavior *-primary, *-secondary, and so on are already defined with default colors I can not use for my website

Resources (screenshots, code snippets etc.)


Arkadiusz Idzikowski staff answered 4 years ago

The easiest solution would be to use an MDB theme, but theming only modify the primary and secondary colors.

https://mdbootstrap.com/docs/standard/content-styles/theme/

Otherwise you would need to override the scss variables located in the free/variables.scss file.


AstroSign commented 4 years ago

Just what I searched for, Thank you


webshapers pro premium priority commented 4 years ago

In order to override them they would need the "!default"-flag set like this:// Theme colors$primary: #1266f1 !default;$secondary: #b23cfd !default;$success: #00b74a !default;$info: #39c0ed !default;$warning: #ffa900 !default;$danger: #f93154 !default;$light: $gray-50 !default;$dark: $gray-900 !default;


webshapers pro premium priority commented 4 years ago

Aaaand I believe this should be done for all the variables in free/variables.scss...


Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Resolved

Specification of the issue
  • User: Free
  • Premium support: No
  • Technology: MDB Standard
  • MDB Version: 2.2.1
  • Device: Laptop
  • Browser: Chrome
  • OS: Big Sur
  • Provided sample code: No
  • Provided link: No