Topic: How to correctly build a custom theme?
Laudick pro asked 6 years ago
My Code: <mdb-tabset #staticTabs [buttonClass]="'nav-tabs tabs-primary'" [contentClass]="'card'">.tabs-primary overwrites the default color with #4285F4 instead of using the one declared in the theme. What is the best way to create my own skin? I just want to set a primary color that's applied to all '*-primary' classes
Laudick pro answered 6 years ago
Where can I find the whole sass code from one of your skins? I only found the variables set in _variables-pro.scss and _skins.scss where the skin gets generated.
And there is still the bug (if it’s a bug) that ‘.tabs-primary’ overwrites the skins primary color with #4285F4 instead of using the one declared in the theme, I tested it with ‘.white-skin’ applied to the body of my page.
Currently I am using .white-skin and copy the code that white-skin apllies from the browser developer tools to my own my-skin.scss to overwrite it but that doesn’t seem like the best solution.
Best Regards
Damian Gemza staff commented 6 years ago
You have to copy _skins.scss code and variables which you want to modify from _variables.scss and overwrite it. In future we'll write an tutorial, how to create custom skin. Best Regards, Damiananuragd7 free commented 5 years ago
where can i find the _skins.scss file please?
Arkadiusz Idzikowski staff commented 5 years ago
Please take a look at our skins documentation. You can find there all information you need to use our skins or create new custom skin: https://mdbootstrap.com/docs/angular/css/skins/
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Resolved
- ForumUser: Pro
- Premium support: No
- Technology: MDB Angular
- MDB Version: -
- Device: -
- Browser: -
- OS: -
- Provided sample code: Yes
- Provided link: No
Damian Gemza staff commented 6 years ago
Dear Laudick, The best way to create your custom skin is to copy whole code from one of our skins, create a new file called theme.scss or something else, paste there our code, and modify it with your styles. This probably is the best way to create your custom theme for our MDB Angular. Best Regards, Damian