Skip to content

CommentItem

One comment in a thread, with avatar, author, a badge, time, edited mark and actions. Put the comments of a thread in an ordered list.

  • CommentItem

PreviewLink to the section Preview

Live in all three themes. Everything here is interactive.

Light theme, CommentItem

  1. Anna NowakAuthor· edited

    The fix works on Firefox and Safari.

  2. Claude CodeAgent

    Work summary\n\nUpdated the workflow to Node 26. All checks pass.

  3. Piotr Wiśniewski

    Can we ship this on Friday?

Dark theme, CommentItem

  1. Anna NowakAuthor· edited

    The fix works on Firefox and Safari.

  2. Claude CodeAgent

    Work summary\n\nUpdated the workflow to Node 26. All checks pass.

  3. Piotr Wiśniewski

    Can we ship this on Friday?

High contrast theme, CommentItem

  1. Anna NowakAuthor· edited

    The fix works on Firefox and Safari.

  2. Claude CodeAgent

    Work summary\n\nUpdated the workflow to Node 26. All checks pass.

  3. Piotr Wiśniewski

    Can we ship this on Friday?

UsageLink to the section Usage

tsx
import { CommentItem } from '@skribly/ui/conversation'
tsx
<ol>
  <li>
    <CommentItem id="comment-12" author="Anna Nowak" authorBadge="Author" time={iso} timeLabel="2 hours ago">
      <Markdown text={body} headingOffset={3} />
    </CommentItem>
  </li>
</ol>

Every label is a prop, so the app passes its own words in its own language. See no built-in text.

AccessibilityLink to the section Accessibility

  • Each comment is an article named by its author.
  • The avatar is decorative, because the name is in the text.
  • A link to the comment highlights it with a border and a fill, not only colour.
  • Failed states are read out at once.

This demo runs through axe in all three themes on every test run. See what the tests check.

Search this site

Arrows move through the results, Enter opens one, Esc closes. Ctrl K /