Custom Theme Stylesheet
Description
Load a CSS file of your own as an htmltools::htmlDependency(). Prefer the theme argument of bc_deps(), which loads it after the style pack for you.
Usage
bc_theme(path)
Arguments
| Argument | Description |
|---|---|
path |
String. Path to a .css file defining Basecoat's tokens. |
Value
An htmltools::htmlDependency().
Details
Place it after bc_deps() on the page. The file needs only the tokens it changes, in :root and .dark.
A tweakcn export works as is. Load any web fonts it names yourself.
See Also
Examples
css <- tempfile(fileext = ".css")
writeLines(":root { --primary: oklch(0.54 0.16 320); }", css)
bc_theme(css)