Bootstrap 5 - How to use custom variables for button?

Viewed 153

What is the best way to use custom variables for button in Bootstrap 5?

#custom.scss

$primary: #1678E5;

@import '../node_modules/bootstrap/scss/bootstrap.scss';

Here, I'm able to change the primary color to #1678E5 across my template. The only thing it fails to do is the link color for button (as it is no longer #ffffff in color for btn-primary)

I know I'm missing something here. So if there is anyone who could point me in the right direction I'd very much appreciate it.

Edit:

Apparently, Bootstrap uses dark text color on lighter color for contrast. So all I did is to change the lower contrast ratio.

$min-contrast-ratio: 3;
0 Answers
Related