Skip to content

feat: add bidirectional linking to Typst code annotations#100

Merged
mcanouil merged 1 commit intomainfrom
feat/typst-code-annotation-linking
Mar 23, 2026
Merged

feat: add bidirectional linking to Typst code annotations#100
mcanouil merged 1 commit intomainfrom
feat/typst-code-annotation-linking

Conversation

@mcanouil
Copy link
Copy Markdown
Owner

Add cell-id generation to the Typst code annotation Lua filter so each annotated code block gets a unique identifier.
The Typst functions (circled-number, annotated-code, annotation-item) now accept a cell-id parameter and use Typst labels and links to enable bidirectional navigation between annotation markers in code and their descriptions below.

Add upstream-compatible Quarto functions (quarto-circled-number, quarto-annote-color, quarto-code-filename, quarto-code-annotation, quarto-annotation-item) to the extension's definitions.typ partial.
These match the signatures from quarto-dev/quarto-cli#14170 so the extension does not break when upstream starts emitting calls to them.

Add cell-id generation and Typst label/link support so that clicking
a circled annotation number in code jumps to its description and vice
versa.

Add upstream-compatible Quarto functions (quarto-circled-number,
quarto-annote-color, quarto-code-filename, quarto-code-annotation,
quarto-annotation-item) to definitions.typ for forward compatibility
with quarto-dev/quarto-cli#14170.
@mcanouil mcanouil added the Type: Enhancement 💡 Issues related to enhancements, improvements, new features, or new analyses label Mar 23, 2026
@mcanouil mcanouil self-assigned this Mar 23, 2026
@mcanouil mcanouil merged commit 50104bd into main Mar 23, 2026
@mcanouil mcanouil deleted the feat/typst-code-annotation-linking branch March 23, 2026 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Type: Enhancement 💡 Issues related to enhancements, improvements, new features, or new analyses

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant