CommentView
Display a comment with its author, timestamp, replies, and actions.
CommentView displays one comment and its nested replies. Pass onReply and onReact to handle reader interactions.
Import
import { CommentView } from "@solarius/onset";Props
| Prop | Type | Default | Description |
|---|---|---|---|
comment | Comment | — | The comment to render. |
depth | number | 0 | Nesting depth for indentation. |
maxDepth | number | 3 | Maximum nesting for the Reply button. |
onReply | (parentId: string, body: string) => void | — | Reply handler. |
onReact | (commentId: string, emoji: string) => void | — | Reaction handler. |
renderActions | (comment: Comment) => ReactNode | — | Header action controls. |