Topic: mdbPopover custom class option
<button type="button" mdbBtn color="primary"
mdbPopover="Vivamus sagittis lacus vel augue laoreet rutrum faucibus."
mdbPopoverHeader="Popover on hover"
triggers="hover">
Popover example
</button>
Damian Gemza staff answered 6 years ago
nick23 commented 6 years ago
Hi Damian, thanks for the answer. I want to customize some specific default popover without changing style of the all popovers in the page/project. How can I do it?
Thanks
nick23 answered 6 years ago
Damian Gemza staff answered 6 years ago
japan pro premium priority commented 5 years ago
Dear @Damian Gemza, I agree with @nick23. I find that custom class idea useful, because I have a specific popover in a project and need to change just that one and avoid changing css for all popovers across the project. To be more specific - my popover is being displayed inside a container and in order to put it on top of the container (not to hide it behind the edges of the container), I need to specify container="body". I discovered that for this case I need to change the default .popover class to decrease the max-width of the popover. If I don't, the popover is not displayed in a situation when the container is too narrow for the default max-width (it shouldn't be a problem since it's being bound to , but unfortunately it doesn't work as expected). It's a specific case and obviously a bug, however this could be easily solved if I could pass my custom style to this popover instance. Hope this makes sense. Best regards. Jarda
Bartosz Termena staff commented 5 years ago
Dear @japan
We will take closer look at that and try to add such an option in the future.
Best Regards, Bartosz.
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Resolved
- User: Free
- Premium support: No
- Technology: MDB Angular
- MDB Version: 6.2.3
- Device: desktop
- Browser: chrome
- OS: win10
- Provided sample code: No
- Provided link: No