Staaarter

Numbered List

A single-column list where each item has a small circular numbered badge before the question, with the answer in body text underneath. Every answer is always visible, well suited for onboarding steps or priority-ordered FAQs.

By Staaarter Team
FAQ
Docs
Live preview

Docs

Installation

A real shadcn registry command, not a copy-paste stand-in: it fetches this block plus its dependencies and any missing npm packages, and installs them straight into your project.

npx shadcn add https://staaarter.com/r/numbered-list.json

Prefer not to use the CLI? Copy the source from the Code toggle above into src/components/blocks/faq/faq16.tsx instead.

Usage

The file also exports faq16Demo, the exact props behind the preview above. Spread it to get a working section in one line, then replace it with your own data.

import { Faq16, faq16Demo } from "@/components/blocks/faq/faq16";

export default function Page() {
  return <Faq16 {...faq16Demo} />;
}

Props

PropTypeDefaultDescription
headingstring"Frequently asked questions"Section heading.
descriptionstring"The most common questions..."Supporting copy under the heading.
itemsFaqItem[]noneQuestion and answer pairs, numbered in the order given.
classNamestringnoneExtra classes for the outer section element.

Types

interface FaqItem {
  question: string;
  answer: string;
}

Behavior notes

  • Always-open, static list, there's no expand/collapse, both question and answer render together for every item.
  • Numbers are derived from each item's index in the `items` array plus one, not stored per item, so reordering the array reorders the numbering automatically.