AnnotationSurface
Controlled annotation UI. Storage and source navigation belong to its host.
Import
Section titled “Import”import { AnnotationSurface } from "@flanksource/clicky-ui/comments";The props table documents the component-specific surface. Standard DOM attributes inherited from React, such as className, event handlers, and accessibility attributes, may also be accepted when the component’s prop type extends a native element.
| Prop | Type | Default | Description |
|---|---|---|---|
captures* |
Record<string, AnnotationCapture> |
— | — |
comments* |
Comment[] |
— | — |
documentKey* |
string |
— | — |
error |
string |
— | — |
onAcknowledge |
(…) => void | Promise<void> |
— | Claim an unassigned active root for the current user or agent. |
onAssign |
(…) => void | Promise<void> |
— | Hand an active root to `assignee`, or return it to unassigned with `null`. |
onChecklistToggle |
(…) => void | Promise<void> |
— | — |
onClose |
(…) => void | Promise<void> |
— | Human-only transition from active or resolved to closed. |
onCreate* |
(…) => Promise<...> |
— | — |
onDelete |
(…) => void | Promise<void> |
— | — |
onMention |
(…) => void |
— | Fired when a posted comment references a mentionable. |
onPrepareCapture |
(…) => Promise<AnnotationCapture> |
— | — |
onReply |
(…) => void | Promise<void> |
— | — |
onSelectCapture |
(…) => void |
— | — |
onSelectionHandled |
(…) => void |
— | — |
onUpdateRating |
(…) => void | Promise<void> |
— | — |
onUpdateStatus |
(…) => void | Promise<void> |
— | — |
selection |
AnnotationCapture | null |
— | — |
view* |
enum |
— | — |