Skip to content

Commit aae77fe

Browse files
committed
describe layering in revealjs and for brand
1 parent bc8b204 commit aae77fe

File tree

1 file changed

+48
-1
lines changed

1 file changed

+48
-1
lines changed

docs/output-formats/html-themes-more.qmd

Lines changed: 48 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ From time to time, as the Bootswatch themes are updated, we will update these me
4444

4545
## Bootstrap / Bootswatch Layering
4646

47-
When using the Quarto HTML format, we allow the user to specify theme information in the document front matter (or project YAML). The theme information consists of a list of one or more of
47+
When using the Quarto `html` and `dashboard` formats, we allow the user to specify theme information in the document front matter (or project YAML). The theme information consists of a list of one or more of
4848

4949
- A valid built in Bootswatch theme name
5050

@@ -106,3 +106,50 @@ We order the themes according to the order that they are specified in the YAML,
106106
Bootstrap
107107
cosmo /*-- scss:rules --*/
108108
custom.scss /*-- scss:rules --*/
109+
110+
## `revealjs` Layering
111+
112+
The same system applies for `revealjs` and its themes.
113+
`revealjs` themes shipped with Quarto do not have a uniform variable naming convention, and so different SCSS files are likely to be needed to make effective changes to different themes.
114+
115+
Nevertheless, the following examples illustrate what's possible:
116+
117+
``` yaml
118+
# In this configuration, `custom.scss` takes precedence
119+
format:
120+
revealjs:
121+
theme:
122+
- blood
123+
- custom.scss
124+
# In this configuration, the `blood` theme takes precedence
125+
format:
126+
revealjs:
127+
theme:
128+
- custom.scss
129+
- blood
130+
```
131+
132+
## `_brand.yml` Layering
133+
134+
Quarto 1.6 and later ship with [**brand.yml**](https://posit-dev.github.io/brand-yml/brand/defaults.html) support, see the [guide](/docs/authoring/brand.qmd) for more.
135+
By default, styling information in `_brand.yml` takes the lowest precedence.
136+
To change this, use the `"brand"` string in your theme configuration in YAML:
137+
138+
``` yaml
139+
# In this configuration, the `blood` theme takes precedence
140+
# over `custom.scss` *and* the information in `_brand.yml`
141+
format:
142+
revealjs:
143+
theme:
144+
- custom.scss
145+
- blood
146+
# In this configuration, the information in `_brand.yml` takes
147+
# precedence over the `blood` theme and `custom.scss`, in that
148+
# order
149+
format:
150+
revealjs:
151+
theme:
152+
- blood
153+
- custom.scss
154+
- brand
155+
```

0 commit comments

Comments
 (0)