Skip to content

Commit ba633c8

Browse files
also populate brand.typography.headings for title if there is any base
since we can't default to 'do nothing', we must implement full inheritance in every case for brand.typography.headings
1 parent 9286ded commit ba633c8

File tree

2 files changed

+28
-1
lines changed

2 files changed

+28
-1
lines changed

src/resources/filters/quarto-post/typst-brand-yaml.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ function render_typst_brand_yaml()
307307

308308
local headings = _quarto.modules.brand.get_typography('headings')
309309
local foregroundColor = _quarto.modules.brand.get_color('foreground')
310-
if headings and next(headings) or foregroundColor then
310+
if headings and next(headings) or base and next(base) or foregroundColor then
311311
base = base or {}
312312
headings = headings or {}
313313
local color = headings.color or foregroundColor
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
title: "Untitled"
3+
format:
4+
html: default
5+
typst:
6+
keep-typ: true
7+
revealjs:
8+
output-file: base-reveal.html
9+
brand:
10+
typography:
11+
fonts:
12+
- family: Tiny5
13+
source: google
14+
base: Tiny5
15+
_quarto:
16+
tests:
17+
typst:
18+
ensureTypstFileRegexMatches:
19+
-
20+
- 'font: \("Tiny5",\),'
21+
- 'heading-family: \("Tiny5",\)'
22+
23+
---
24+
25+
## Section
26+
27+
{{< lipsum 1 >}}

0 commit comments

Comments
 (0)