Components › Display

Citation

A numbered source mark for AI answers that previews the source on hover.

Installation

npx plankui@latest add citation

Usage

import { Citation } from "@/components/ui/citation";

<Citation index={1} title="React v19" href="https://react.dev/blog/2024/12/05/react-19" snippet="Actions handle pending states." />

API reference

PropTypeDefaultDescription
indexnumberrequiredThe source's number in the answer.
title / hrefstringrequiredThe source and its link.
snippetReactNodeA quote shown in the preview.

View the source on GitHub