brand_sass_fonts: Generate Sass variables and CSS rules for brand fonts

View source: R/sass.R

brand_sass_fontsR Documentation

Generate Sass variables and CSS rules for brand fonts

Description

Creates Sass variables and CSS rules for fonts defined in the brand object. Supports Google fonts, Bunny fonts, and file-based fonts.

Usage

brand_sass_fonts(brand)

Arguments

brand

A list or string of YAML representing the brand, or a path to a brand.yml file.

Value

A list with two components:

  • defaults: Sass variables for font definitions

  • rules: CSS rules for applying fonts via classes

See Also

Other brand.yml Sass helpers: brand_sass_color(), brand_sass_color_palette(), brand_sass_defaults_bootstrap(), brand_sass_typography()

Examples


brand <- list(
  typography = list(
    fonts = list(
      list(
        family = "Roboto",
        source = "google",
        weight = c(400, 700),
        style = "normal"
      )
    )
  )
)

brand_sass_fonts(brand)


brand.yml documentation built on Nov. 6, 2025, 5:06 p.m.