jekyll-bootstrap-theme icon indicating copy to clipboard operation
jekyll-bootstrap-theme copied to clipboard

Can't change the bootstrap primary color

Open ricardogsilva opened this issue 4 years ago • 1 comments

I have created a _sass/_custom-variables.scss file with the following contents:

$primary: #9949f5;

Then in my _includes/header.html I have:

<header>
  <nav class="navbar navbar-expand-lg navbar-dark bg-primary">
    <!-- rest of my navbar omitted for brevity -->
  </nav>
</header>

Since I have overriden bootstrap's $primary variable and since I am assigning the bg-primary class to my navbar, I would expect my navbar's background color to be set to #9949f5, which is a purplish color. However, when I build my jekyll site, I still the stock bootstrap blue as the background.

It is not clear to me whether this is a bug with this jekyll theme or if I am doing something wrong.

ricardogsilva avatar Sep 13 '21 22:09 ricardogsilva

In case you're still looking for a solution, I had the same issue and here's what I did:

Copy this file into /assets/css/bootstrap-theme.scss

Delete everything except the last 3 line:

@import "custom-variables";
@import "bootstrap/bootstrap";
@import "custom-styles";

atestu avatar May 24 '22 22:05 atestu