Mikey S.
Mikey S.

Reputation: 3331

Rails Twitter bootstrap SASS - Adding my own custom font before $baseFontFamily

I have my own custom font which I use for the website, and I would like it to be declared as the $baseFontFamily the only problem is that since it's a custom font, I want older browsers to fall back to the default twitter bootstrap font family. Is there any way I can do that?

My main .scss file looks like that:

@font-face
{
  font-family: Bartley;
  src: url('/Bartley.ttf');
}

$baseFontFamily: Bartley, $sansFontFamily;

@import "bootstrap";

body { 
  padding-top: 60px;
}

@import "bootstrap-responsive";

Thanks!

Upvotes: 0

Views: 1271

Answers (1)

Rockbot
Rockbot

Reputation: 973

There is no "default bootstrap font" but it should work like this:

$baseFontFamily: 'Bartley', Helvetica, Arial, sans-serif !default;

and then you could do ...

$sansFontFamily: $baseFontFamily; // Set "SansFontFamily" with value from "baseFontFamily"

Upvotes: 4

Related Questions