typst update 0.11

This commit is contained in:
anarsec 2024-04-07 19:08:11 +00:00
parent 23e65d2563
commit 3660b0a2ec
No known key found for this signature in database
2 changed files with 8 additions and 9 deletions

Binary file not shown.

View file

@ -91,24 +91,24 @@
text[ (#emph()[Recommendations])] text[ (#emph()[Recommendations])]
} }
else if it.dest.starts-with("/recommendations#") or it.dest.starts-with("/recommendations/#") { else if it.dest.starts-with("/recommendations#") or it.dest.starts-with("/recommendations/#") {
locate(location => { context {
let elements = query(label(it.dest.trim("/recommendations#", at: start).trim("/recommendations/#", at: start)), location) let elements = query(label(it.dest.trim("/recommendations#", at: start).trim("/recommendations/#", at: start)))
text[ (#emph()[Recommendations:] #emph(elements.first().body))] text[ (#emph()[Recommendations:] #emph(elements.first().body))]
}) }
} }
else if it.dest.starts-with("https://") or it.dest.starts-with("http://") { else if it.dest.starts-with("https://") or it.dest.starts-with("http://") {
footnote[#it.dest.trim("https://", at: start).trim("http://", at: start)] footnote[#it.dest.trim("https://", at: start).trim("http://", at: start)]
} }
else if it.dest.starts-with("/glossary#") or it.dest.starts-with("/glossary/#") { else if it.dest.starts-with("/glossary#") or it.dest.starts-with("/glossary/#") {
locate(location => { context {
let elements = query(heading.where(label: label(it.dest.trim("/glossary#", at: start).trim("/glossary/#", at: start)), level: 2), location) let elements = query(heading.where(label: label(it.dest.trim("/glossary#", at: start).trim("/glossary/#", at: start)), level: 2))
if elements.len() != 0 { if elements.len() != 0 {
text[#super[]] text[#super[]]
} }
else { else {
footnote[anarsec.guide/glossary] footnote[anarsec.guide/glossary]
} }
}) }
} }
else if it.dest.starts-with("/") { else if it.dest.starts-with("/") {
footnote({text[anarsec.guide] + it.dest}) footnote({text[anarsec.guide] + it.dest})
@ -174,4 +174,3 @@
] ]
] ]