/** * Adds a font specification to an element. * Uses a single "font" property if possible, otherwise uses separate font-family, font-size, * font-weight and line-height properties. * * @param {number/string} [$font-weight=null] * The font-weight * * @param {number/string} [$font-size=null] * The font-size * * @param {number/string} [$line-height=null] * The line-height * * @param {string} [$font-family=null] * The font-family * * @member Global_CSS * @private */@mixin font( $font-weight: null, $font-size: null, $line-height: null, $font-family: null) { @if $font-family == null or $font-size == null { // if font-family or font-size is null we cannot use a single "font" declaration font-weight: $font-weight; font-size: $font-size; line-height: $line-height; font-family: $font-family; } @else if $line-height == null { font: $font-weight $font-size $font-family; } @else { font: $font-weight #{$font-size}/#{$line-height} $font-family; }}