Skip to content
This repository has been archived by the owner on Apr 1, 2024. It is now read-only.

Can't change the bootstrap primary color #7

Open
ricardogsilva opened this issue Sep 13, 2021 · 1 comment
Open

Can't change the bootstrap primary color #7

ricardogsilva opened this issue Sep 13, 2021 · 1 comment

Comments

@ricardogsilva
Copy link

ricardogsilva commented Sep 13, 2021

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.

@atestu
Copy link

atestu commented May 24, 2022

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";

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants