Override mdb component styles for each angular component sep


Topic: Override mdb component styles for each angular component separatly

rhaouari asked 5 years ago

Hi I would like to override css styles of mdb components , like carousel component or any other component, but i don't wont to be applied globally , for example i have two angular components cmp1 and cmp2 with their distinct scss files, that both uses carousel. i want for example to override the height of the caroussel to set it differently for cmp1 and cmp2 . if i add it to styles.scss or app.component.scss it will be applied globally

Best regards.


Konrad Stępień staff commented 5 years ago

Hi @rhaouari,

Unfortunately, this can be problematic because the MDB styles are imported globally and it's hard to overwrite them inside other components.

I think you just have to do global styles with unique ids


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 Angular
  • MDB Version: 8.8.1
  • Device: PC
  • Browser: Chrome
  • OS: osx
  • Provided sample code: No
  • Provided link: No
Tags