One of the buttons in my project looks like this:
<button type="button" class="btn btn-link btn-link-dark">
<i class="material-icons">help</i>
</button>
By default, when I hover over it, the button turns blue. However, I want to change this behavior.
The following CSS code achieves the desired effect:
.btn-link:hover {
color: white;
}
My challenge is that I only want this color change to occur when the btn-link-dark
class is present.
I've tried these approaches separately, but they did not work as expected:
.btn-link-dark .btn-link:hover {
color: white;
}
.btn-link-dark:hover .btn-link:hover {
color: white;
}
I am trying to avoid adding a third class to solve this issue.