I'm trying to get something similar to this SASS code to work;
.alert-danger {
@include alert-variant($alert-danger-bg, $alert-danger-border, $alert-danger-text);
@include transition(ease-in-out, 95ms, all);
@if data-interaction == true {
&:hover,
&:focus {
@include alert-variant-interactive($alert-danger-bg, $alert-danger-border, $alert-danger-text);
}
}
}
I can't find a good way to check "if" some attribute or class exists within .alert-danger, though. I would really like to keep the hover nested, instead of having to write extra blocks.
Right now I am using data-interaction="true" on the .alert-danger element.
Thanks in advance!