I themed my bootstrap 5.1.3 using Sass to add new colors to the panel.
I found that Bootstrap 5.1.3 can't be customized as Boostrap4 so I updated my scss file and it now looks like this :
@import "node_modules/bootstrap/scss/_functions";
@import "node_modules/bootstrap/scss/_variables";
@import "node_modules/bootstrap/scss/_mixins";
$custom-theme-colors:map-merge($theme-colors, (
"lightcornflowerblue": #8ECAE6,
"bluegreen" : #219EBC,
"prussianblue": #023047,
"selectiveyellow": #FFB703,
"tangerine": #FB8500,
));
$theme-colors: map-merge($theme-colors, $custom-theme-colors);
$theme-colors-rgb: map-loop($theme-colors, to-rgb, "$value");
$utilities-colors: map-merge($utilities-colors, $theme-colors-rgb);
$utilities-text-colors: map-loop($utilities-colors, rgba-css-var, "$key", "text");
$utilities-bg-colors: map-loop($utilities-colors, rgba-css-var, "$key", "bg");
$utilities-table-colors: map-loop($utilities-colors, rgba-css-var, "$key", "table");
@import "node_modules/bootstrap/scss/bootstrap";
I checked and I can see this in the final css file :
.table-danger {
--bs-table-bg: #f8d7da;
--bs-table-striped-bg: #eccccf;
--bs-table-striped-color: #000;
--bs-table-active-bg: #dfc2c4;
--bs-table-active-color: #000;
--bs-table-hover-bg: #e5c7ca;
--bs-table-hover-color: #000;
color: #000;
border-color: #dfc2c4; }
But the class "table-danger" doesn't have any effect ! And none of my custom color work for table colors... Do you guys know what I missed in the process ? It was way easier in Bootstrap4 to have custom colors
I uploaded the .map file Modified my scss to merge colors and all as it is now because my old bootstrap 4 scss wasn't working for most of the classes, now some of them work but table colors for example are not working.