Ask Natuna

Ask about the design system

Hi, I am Natuna.

Ask me about the design system: components, tokens, statuses, and how to use them.

Natuna can be wrong. The docs are the source of truth.

Skip to content
  • IntroductionPage
  • Ask NatunaAsk about the design systemPage
  • FoundationColor, type, number, effectPage
  • Components overviewPage
  • ThemesLight and dark modePage
  • NamingProperty and page namesPage
  • Privacy statementPage
  • Text-safe stepsFirst AA and AAA step per color rampSection
  • AccessibilityWCAG 2.2 AAA rulesSection
  • Dark modeThemesSection
  • Using it todayFigma file and React codeSection
  • Component statusDesign status and In ReactSection

Arrow keys to move, Enter to open, Esc to close.

Comment

A single message in a discussion, with author, time, and text.

Status
ReadyBuild day 5 of 21
Code
In React
Role
Display

Usage

This demo is live, and the code below it is the same code, imports included. The component lives in src/ui of this repository and is not published to npm yet.

Siti Nur AisyahApprover2 hours ago
Payslip documents check out. Moving on to collateral verification.

Pastes as editable layers. Shadows are not exported.

import { useState } from "react";
import { Comment, type CommentState } from "@/ui";

export default function CommentDemo() {
  const [resolved, setResolved] = useState<boolean>(false);
  const state: CommentState = resolved ? "resolved" : "default";

  return (
    <Comment
      author="Siti Nur Aisyah"
      role="Approver"
      timestamp="2 hours ago"
      state={state}
      onReply={() => {}}
      onToggleResolved={() => setResolved(!resolved)}
    >
      Payslip documents check out. Moving on to collateral verification.
    </Comment>
  );
}

Variants and states

Every specimen is the real component from src/ui, held in one state.

type threaddefault, highlight, resolved
Siti Nur AisyahApprover2 hours ago
Payslip documents check out. Moving on to collateral verification.
Siti Nur AisyahApprover2 hours ago
Payslip documents check out. Moving on to collateral verification.
Siti Nur AisyahApprover2 hours ago
Payslip documents check out. Moving on to collateral verification.
type annotationdefault, highlight, resolved
Siti Nur AisyahApprover2 hours ago
Payslip documents check out. Moving on to collateral verification.
Siti Nur AisyahApprover2 hours ago
Payslip documents check out. Moving on to collateral verification.
Siti Nur AisyahApprover2 hours ago
Payslip documents check out. Moving on to collateral verification.

Pastes as editable layers. Shadows are not exported.

Props

author
string · default none
Required. The name. It also makes the avatar initials.
role
string · default none
A tag next to the name, such as Approver.
timestamp
string · default none
Required. Pass the formatted time.
type
"thread" | "annotation" · default "thread"
Thread has actions. Annotation has a 3px warning accent and no actions.
state
"default" | "highlight" | "resolved" · default "default"
Highlight is brand colored. Resolved is muted.
onReply
() => void · default none
Shows Reply. Thread only.
onToggleResolved
() => void · default none
Shows Resolve, or Reopen when the state is resolved. Thread only.
children
ReactNode · default none
The comment text.

Figma to code

Figma properties by their exact names from Naming, and the React prop that carries each one. The table covers the shared properties that bear on this component; the Figma file decides which of them its component exposes. None means there is no prop for it yet.

🧰 Type
type
thread or annotation.
🎯 State
state
default, highlight, or resolved.
Title, Label, Timestamp
author, role, timestamp
Name, tag, and time.
Description
children
The text.
Show Actions, Button Value
onReply, onToggleResolved
Pass the handlers to show the actions.
Show Image
None
No prop. The avatar always shows initials.

Accessibility

What the code in src/ui does today, and what it leaves to you.

Keyboard

  • Reply and Resolve are native buttons: Tab focuses them and Enter or Space activates them.

Screen readers

  • An article labeled Comment by the author.
  • The avatar is named by the author, so the name is read twice. Pass the avatar name only when it adds something.

What you still need to do

  • Do not rely on the highlight or the accent color alone to say a comment is new or resolved. Say it in text.
  • The more-options menu in the design is not in code yet.

When to use

Review notes, support threads, and activity on a record.

Do and don't

Do

  • Show when the comment was posted.
  • Use initials when there is no profile photo.

Don't

  • Truncate a comment without a way to read the rest.
  • Show edit actions to people who cannot edit.

4 of 16 other atoms, same role and ready ones first.

See all components

Status reflects the component tracker snapshot of 29 October 2026.