terra vidhal

Support Inbox

Component 1

About

A two-pane support inbox with a searchable queue, status filters driven by a keyboard radio group, unread tracking, an animated conversation thread, status and priority controls, inline canned replies, a keyboard send shortcut and a timed undo after resolving a conversation.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Support Inbox to your project and fits it to your theme.

Code

How Support Inbox is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

/**
 * PrequelUI Animate — MIT — https://prequeluianimate.terravidhal.me
 */

import { SupportInbox, type SupportConversation } from "@/components/ui/support-inbox";

const CONVERSATIONS: SupportConversation[] = [
  {
    id: "billing-portal",
    subject: "Billing portal shows the old invoice total",
    customer: {
      name: "Mara Ellison",
      email: "mara.ellison@example.com",
      company: "Juniper Studio",
      plan: "Team plan",
    },
    status: "open",
    priority: "urgent",
    tags: ["billing", "invoices"],
    unread: true,
    updatedAt: "4m",
    messages: [
      {
        id: "billing-1",
        author: "customer",
        time: "9:42",
        body: "Hi — I updated the seat count yesterday but the portal still shows the previous invoice total. The renewal is due tomorrow and finance needs the correct number.",
      },
      {
        id: "billing-2",
        author: "agent",
        time: "9:48",
        body: "Thanks for flagging this. I can see the seat change on the account and I am checking why the invoice has not recalculated.",
      },
      {
        id: "billing-3",
        author: "customer",
        time: "9:51",
        body: "Appreciated. If it helps, the change was made from the workspace settings, not from the billing tab.",
      },
    ],
  },
  {
    id: "csv-import",
    subject: "CSV import stops at the mapping step",
    customer: {
      name: "Theo Nakamura",
      email: "theo.nakamura@example.com",
      company: "Field Notes Lab",
      plan: "Growth plan",
    },
    status: "pending",
    priority: "high",
    tags: ["import", "data"],
    unread: true,
    updatedAt: "22m",
    messages: [
      {
        id: "csv-1",
        author: "customer",
        time: "8:10",
        body: "Every time I upload a CSV the mapping preview stays empty. The file has 1,200 rows and opens fine in a spreadsheet.",
      },
      {
        id: "csv-2",
        author: "agent",
        time: "8:26",
        body: "Could you confirm whether the first row contains column names? I will also test the same file shape on my side.",
      },
    ],
  },
  {
    id: "sso-review",
    subject: "Single sign-on review for the security team",
    customer: {
      name: "Priya Raman",
      email: "priya.raman@example.com",
      company: "Cobalt Works",
      plan: "Business plan",
    },
    status: "open",
    priority: "normal",
    tags: ["security", "access"],
    unread: false,
    updatedAt: "1h",
    messages: [
      {
        id: "sso-1",
        author: "customer",
        time: "7:35",
        body: "Our security team is reviewing the sign-on configuration next week. Is there a short checklist we should follow before the review?",
      },
      {
        id: "sso-2",
        author: "agent",
        time: "7:58",
        body: "There is. I will send over the checklist and the current configuration summary so your team has everything in one place.",
      },
    ],
  },
  {
    id: "export-delay",
    subject: "Workspace export has been queued for an hour",
    customer: {
      name: "Jonas Weber",
      email: "jonas.weber@example.com",
      company: "Harbor Analytics",
      plan: "Team plan",
    },
    status: "pending",
    priority: "normal",
    tags: ["export", "performance"],
    unread: false,
    updatedAt: "3h",
    messages: [
      {
        id: "export-1",
        author: "customer",
        time: "5:05",
        body: "The export of our activity history has been queued for an hour. The progress bar has not moved.",
      },
      {
        id: "export-2",
        author: "agent",
        time: "5:30",
        body: "The queue is busier than usual. I have bumped your export to the front and will confirm when the download is ready.",
      },
    ],
  },
  {
    id: "webhook-retry",
    subject: "Webhook retries stopped after the last update",
    customer: {
      name: "Elena Fischer",
      email: "elena.fischer@example.com",
      company: "Ridge Software",
      plan: "Growth plan",
    },
    status: "resolved",
    priority: "high",
    tags: ["webhooks", "api"],
    unread: false,
    updatedAt: "Yesterday",
    messages: [
      {
        id: "webhook-1",
        author: "customer",
        time: "16:12",
        body: "Our delivery endpoint was down for about ten minutes this morning, but the failed webhooks were never retried.",
      },
      {
        id: "webhook-2",
        author: "agent",
        time: "16:30",
        body: "I found the retry window was narrower than intended. It is widened now and the missed deliveries are replaying in order.",
      },
      {
        id: "webhook-3",
        author: "customer",
        time: "17:02",
        body: "All of them arrived. Thank you for the quick turnaround.",
      },
    ],
  },
];

export default function SupportInboxDemo() {
  return (
    <main className="flex min-h-screen w-full items-center justify-center bg-background px-4 py-12 sm:px-6">
      <SupportInbox
        conversations={CONVERSATIONS}
        title="Customer support"
        description="One queue for billing, data and security requests. Open a conversation to see the full context and reply."
      />
    </main>
  );
}

Dependencies

More by terra vidhal

View all
  • Gravity Stars Background

    Gravity Stars Background

    16
  • Audio Waveform

    Audio Waveform

    13
  • Topographic Lines

    Topographic Lines

    12
  • Notification Center

    Notification Center

    11
  • Booking Calendar

    Booking Calendar

    11
  • Spotlight Card

    Spotlight Card

    11
  • Command Palette

    Command Palette

    9
  • Kpi Counter

    Kpi Counter

    9

Explore more

Part of PrequelUI Animate — browse the full library on 21st.dev.