I would like to cite a source in parentheses, similarly to biblatex
’s \parencite
, eg
It has been shown that the 2+2 is 4 (Authorname 2000).
Is this possible in Typst? In the docs linked above, I could not find a form
parameter for this.
I would like to cite a source in parentheses, similarly to biblatex
’s \parencite
, eg
It has been shown that the 2+2 is 4 (Authorname 2000).
Is this possible in Typst? In the docs linked above, I could not find a form
parameter for this.
The form
parameter is for different ways of citing, but the style of the citations is governed by the style
parameter. In principle you’re supposed to choose a CSL style that uses parentheses if that’s what you want.
Hey @Tamas_K_Papp, I’ve changed your question post’s title to better fit our guidelines: How to post in the Questions category
For future posts, make sure your title is a question you’d ask to a friend about Typst.
You can use e.g. #set cite(style: "chicago-author-date")
to change to a style using the author date format, which can display as (John Doe 2025)
for example.
Hi @Tamas_K_Papp, did my answer solve your question? If so, please mark it as a solution with the button. If not, let me know if you still need help. Thanks
Thanks for the suggestion. Just to clarify, I want to be able to keep using both forms, the Author (date)
as default and the (Author date)
as an option.
Currently I do it like this (MWE):
example.bib
@Article{doe25:_title,
author = {John Doe},
title = {Title},
journaltitle = {Journal},
date = 2025,
}
example.typ
#set cite(form: "prose")
#let pcite(key) = { cite(key, form: "normal") }
This is the default citation format I want: @doe25:_title.
But I want to be able to access the parenthesis form on demand #pcite(<doe25:_title>)
#bibliography("example.bib", style: "chicago-author-date")
which renders as
This kind of works, but I am wondering if there is a better way.
This answer isn’t really helpful, keeping it here for posterity.
In that case, don’t use #set cite(style: "chicago-author-date")
which will change the style for all cites, but rather #let pcite = cite.with(style: "chicago-author-date")
, then #pcite(<abc>)
.
Apologies, I should mention that your solution is actually the correct solution for most styles. Cite with prose
should remove the parentheses. (Did you upload an outdated image, or is it not working?)
I’m not aware of a way to reverse the two (normal and prose).