From: Jeremy Thomas Date: Fri, 17 May 2019 13:02:12 +0000 (+0100) Subject: Fix #349 X-Git-Tag: 0.7.5~21 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=86b7baa2ff17394a327b356a3a45ff0139e8a741;p=thirdparty%2Fbulma.git Fix #349 --- diff --git a/CHANGELOG.md b/CHANGELOG.md index 8b1eefeff..afbd19a18 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,14 @@ ### New features +You can now specify a different `font-family` for the `.title`, `.subtitle` and `.button` by using the variables `$title-family`, `$subtitle-family` and `$button-family` respectively. + +Simply set a value when importing Bulma: + +```scss +$title-family: "Georgia", serif; +``` + * #2375 Add `.is-relative` helper * #2321 Make `.navbar` focus behave like hover for the navigation * #2290 Fix #1186 -> Reset the offset on columns diff --git a/sass/elements/button.sass b/sass/elements/button.sass index 1f34141c3..f92f158b1 100644 --- a/sass/elements/button.sass +++ b/sass/elements/button.sass @@ -1,5 +1,6 @@ $button-color: $grey-darker !default $button-background-color: $white !default +$button-family: false !default $button-border-color: $grey-lighter !default $button-border-width: $control-border-width !default @@ -50,6 +51,8 @@ $button-static-border-color: $grey-lighter !default border-width: $button-border-width color: $button-color cursor: pointer + @if $button-family + font-family: $button-family justify-content: center padding-bottom: $button-padding-vertical padding-left: $button-padding-horizontal diff --git a/sass/elements/title.sass b/sass/elements/title.sass index febe2fc50..a3db14258 100644 --- a/sass/elements/title.sass +++ b/sass/elements/title.sass @@ -1,4 +1,5 @@ $title-color: $grey-darker !default +$title-family: false !default $title-size: $size-3 !default $title-weight: $weight-semibold !default $title-line-height: 1.125 !default @@ -8,6 +9,7 @@ $title-sub-size: 0.75em !default $title-sup-size: 0.75em !default $subtitle-color: $grey-dark !default +$subtitle-family: false !default $subtitle-size: $size-5 !default $subtitle-weight: $weight-normal !default $subtitle-line-height: 1.25 !default @@ -31,6 +33,8 @@ $subtitle-negative-margin: -1.25rem !default .title color: $title-color + @if $title-family + font-family: $title-family font-size: $title-size font-weight: $title-weight line-height: $title-line-height @@ -49,6 +53,8 @@ $subtitle-negative-margin: -1.25rem !default .subtitle color: $subtitle-color + @if $subtitle-family + font-family: $subtitle-family font-size: $subtitle-size font-weight: $subtitle-weight line-height: $subtitle-line-height