modify title and rm disclaimer
All checks were successful
Build Typst document / build_typst_documents (push) Successful in 18s
All checks were successful
Build Typst document / build_typst_documents (push) Successful in 18s
This commit is contained in:
35
lib/jkutemplate/template/utils.typ
Normal file
35
lib/jkutemplate/template/utils.typ
Normal file
@ -0,0 +1,35 @@
|
||||
#let inwriting = true
|
||||
#let draft = true
|
||||
|
||||
#assert(not(inwriting and not(draft)), message: "If inwriting is true, draft should be true as well.")
|
||||
|
||||
#let todo(it) = [
|
||||
#if inwriting [
|
||||
#text(size: 0.8em)[#emoji.pencil] #text(it, fill: red, weight: 600)
|
||||
]
|
||||
]
|
||||
|
||||
#let silentheading(level, body) = [
|
||||
#heading(outlined: false, level: level, numbering: none, bookmarked: true)[#body]
|
||||
]
|
||||
|
||||
#let in-outline = state("in-outline", false)
|
||||
|
||||
#let flex-caption-styles = rest => {
|
||||
show outline: it => {
|
||||
in-outline.update(true)
|
||||
it
|
||||
in-outline.update(false)
|
||||
}
|
||||
rest
|
||||
}
|
||||
|
||||
#let flex-caption(long, short) = (
|
||||
context (
|
||||
if in-outline.get() {
|
||||
short
|
||||
} else {
|
||||
long
|
||||
}
|
||||
)
|
||||
)
|
Reference in New Issue
Block a user