Citations
v0.64.0, changelogBetaThe sources a model's answer cites: numbered markers linked both ways to a numbered source list, each highlighting the other on hover or focus; [1] and [^1] in Markdown become markers.
API reference
Generated from the types. Every part also takes className.
Citations
- sourcesrequired
readonly CitationSource[]The sources in the order the text numbers them: [1] is the first.- labels
Partial<CitationsLabels>- onActiveChange
(n: number | null) => voidThe source highlighted from a marker or an entry under the pointer or keyboard (1-based), or null.- childrenrequired
ReactNode
CitationMarker
- nrequired
numberThe source's number, 1-based.
CitationSources
- title
ReactNode | nullThe list's title;labels.sources("Sources") by default, null for none (name it yourself then).- as
"h2" | "h3" | "h4" = "h3"The title's heading level, so the page's outline skips none.