defuss-shadcn / Website / website-comments
Comments
Blocks for a discussion under an article or a product: the header with the count and sort order, the form for a new comment, and the comments with their nested replies. Every block is CSS-only and built from the library's components and tokens.
On this page (3)
§The template
The Comments blocks composed into one page - the source is the page.
§A discussion
Comment Header, Comment Form and a thread of Comment Items with nested replies and a reply form - the Comments blocks composed. Click a timestamp: :target highlights that comment.
§The blocks
Comment Header
Introduces a discussion with its comment count and sorting options - a native Select, or sort links in a segmented row.
Comment Item
Displays one comment with its author, timestamp, and reply action - nested replies on a thread line, permalinks that highlight, compact and deleted states.
Comment Form
Collects a new comment or reply - a growing Textarea beside the avatar, guest name and email fields, native validation, a compact reply form.
Comments, ideas or improvements? Edit this page's source on GitHub