bootstrap
bootstrap copied to clipboard
Make use of the link decoration CSS variables
Prerequisites
- [x] I have searched for duplicate or closed feature requests
- [x] I have read the contributing guidelines
Proposal
Is there a reason why links don't use the CSS variables defined for link decoration?
# _reboot.scss, line 244
a {
color: rgba(var(--#{$prefix}link-color-rgb), var(--#{$prefix}link-opacity, 1));
text-decoration: $link-decoration;
&:hover {
--#{$prefix}link-color-rgb: var(--#{$prefix}link-hover-color-rgb);
text-decoration: $link-hover-decoration;
}
}
CSS variables for link decoration and link hover decoration are defined in _root.scss, but they seem to be used nowhere.
Motivation and context
Using the CSS variables instead of the SCSS variables would make it easier to override link decorations in custom classes, and to reset them with the original state (based on the SCSS variable) if needed.
This is already happening in v6. I imagine we could also do v5 though.