Skip to content
Klarhimmel UI

FAQ, columns

FAQ, columns previewFAQ, columns preview

Install

npx shadcn add @klarhimmel/faq-columns
DetailsAbout, usage, props and more

Up to eight questions with their answers always open, laid out in two columns.

Import

Import

import Block from '@/components/klarhimmel/blocks/faq-columns';
Also called
  • faq/columns
Category
The questions people ask before they buy. New project? Set it up once: /get-started/installation.

Notes

When to use it

Up to eight questions with every answer already open, in two columns, for readers who scan rather than click. For a longer list that should fold away, use faq-list; for a printable single-column table, faq-rows.

Writing for it

- Questions hold 120 characters and answers 400, the tightest limits among the FAQ blocks, so write each answer as two sentences at most. - Because nothing is hidden, every item competes for attention; cut the questions nobody has actually asked before you reach the cap of eight. - Aim for an even number of items. With an odd count the second column ends one card short and the grid looks unfinished.

Watch out for

The columns only appear on wide containers (@3xl); on narrow ones the items stack in a single run, so item order is the reading order and not a left column followed by a right column. The title is optional here, unlike in several sibling blocks.

Usage

The block in a page, with its default content (long lists shortened). Every prop is in the table below.

section.tsx
import { Theme } from '@/components/klarhimmel/theme/style';
import { BlockSurface } from '@/components/klarhimmel/blocks/surface';
import FaqColumns from '@/components/klarhimmel/blocks/faq-columns';

export default function Section() {
  return (
    <Theme theme="brand">
      <BlockSurface>
        <FaqColumns props={{
          "eyebrow": "Section name",
          "title": "Say what the answers cover",
          "description": "Say in a sentence or two what to do if the answer is not here, and how soon someone replies.",
          "items": [
            {
              "question": "Ask a question customers have",
              "answer": "Answer in one or two plain sentences, with the key fact first, then what to do or where to go next."
            },
            {
              "question": "Ask a question a customer would ask",
              "answer": "Answer in one or two plain sentences, with the key fact first, then what to do or where to go next."
            },
            {
              "question": "Ask a question a customer would ask",
              "answer": "Answer in one or two plain sentences, with the key fact first, then what to do or where to go next."
            }
          ]
        }} />
      </BlockSurface>
    </Theme>
  );
}

Props

The type, default and text limit of every prop. On a real page, over-limit text is kept and checkSections flags it (Installation, Check a page before you ship); this live preview shows the default until it fits. The panel above edits all props.

PropTypeDefaultDescription
eyebrowstring'Section name'Text, up to 60 characters.
titlestring'Say what the answers cover'Text, up to 120 characters.
descriptionstring'Say in a sentence or two what to do…'Text, up to 300 characters.
align'start' | 'center'-One of 'start', 'center'. Optional; empty is not rendered.
collapsibleboolean-Optional; empty is not rendered.
primaryActionLink-Optional; empty is not rendered.
secondaryActionLink-Optional; empty is not rendered.
items{ question, answer }[]6 itemsList of 2 to 8. Each item: question, answer.
headingLevel'1' | '2'-One of '1', '2'. Optional; empty is not rendered.