Content, columns
Install
npx shadcn add @klarhimmel/content-columnsUsage
import { Theme } from '@/components/klarhimmel/theme/style';
import { BlockSurface } from '@/components/klarhimmel/blocks/surface';
import ContentColumns from '@/components/klarhimmel/blocks/content-columns';
export default function Section() {
return (
<Theme theme="brand">
<BlockSurface>
<ContentColumns props={{
"eyebrow": "Our view",
"title": "Small hotels deserve better software than big ones get",
"quote": "A booking tool should disappear into the evening, not fill it.",
"attribution": "Elin Sandberg, founder",
"paragraphs": [
"When we started talking to owners, almost every one of them described the same Sunday night: a laptop on the kitchen table, three tabs open, and a guest asking whether the room was still free.",
"The tools they used had been built for chains with a revenue team. Every setting assumed someone whose whole job was to configure it. Nobody in a fourteen-room guesthouse has that job.",
"So we started from the other end. What does the person at the front desk need to know at seven in the morning? Who arrives today, who leaves, what is not ready. Everything else can wait.",
"That one question shaped the product. Defaults that are right for most places, settings that are plain words, and a calendar that looks like the paper one it replaces.",
"It is not the most powerful tool on the market, and we are fine with that. It is the one people still open after a year."
]
}} />
</BlockSurface>
</Theme>
);
}Install
Import
import Block from '@/components/klarhimmel/blocks/content-columns';- content/columns
- Category
- Long-form text and timelines for about and policy pages.
Notes
When to use it
Long text set in two newspaper-style columns under a big headline, with an optional pull quote in between. Right for a manifesto or an essay on a wide page; for a single reading column use `content-prose`.
Writing for it
- Each paragraph holds up to 700 characters and the block needs two to eight of them. Keep paragraphs near the same length so the two columns end at about the same height. - The quote (220 characters) is pushed to the right half on wide containers, so choose a sentence that works as a line on its own. - The title can reach 140 characters and is set very large on wide containers, so state the argument in one line instead of using a label.
Watch out for
Paragraphs are never split between columns, so the browser balances whole paragraphs. One very long paragraph and several short ones will leave the columns uneven, and on narrow containers it all collapses to a single column.
Pairs well with
Usage
The block in a page, with its default content (long lists shortened). Every prop is in the table below.
import { Theme } from '@/components/klarhimmel/theme/style';
import { BlockSurface } from '@/components/klarhimmel/blocks/surface';
import ContentColumns from '@/components/klarhimmel/blocks/content-columns';
export default function Section() {
return (
<Theme theme="brand">
<BlockSurface>
<ContentColumns props={{
"eyebrow": "Our view",
"title": "Small hotels deserve better software than big ones get",
"quote": "A booking tool should disappear into the evening, not fill it.",
"attribution": "Elin Sandberg, founder",
"paragraphs": [
"When we started talking to owners, almost every one of them described the same Sunday night: a laptop on the kitchen table, three tabs open, and a guest asking whether the room was still free.",
"The tools they used had been built for chains with a revenue team. Every setting assumed someone whose whole job was to configure it. Nobody in a fourteen-room guesthouse has that job.",
"So we started from the other end. What does the person at the front desk need to know at seven in the morning? Who arrives today, who leaves, what is not ready. Everything else can wait.",
"That one question shaped the product. Defaults that are right for most places, settings that are plain words, and a calendar that looks like the paper one it replaces.",
"It is not the most powerful tool on the market, and we are fine with that. It is the one people still open after a year."
]
}} />
</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.
| Prop | Type | Default | Description |
|---|---|---|---|
eyebrow | string | 'Our view' | Text, up to 60 characters. |
title | string | 'Small hotels deserve better softwar…' | Text, up to 140 characters. |
quote | string | 'A booking tool should disappear int…' | Text, up to 220 characters. |
attribution | string | 'Elin Sandberg, founder' | Text, up to 80 characters. |
paragraphs | string[] | 5 items | List of 2 to 8. |
headingLevel | '1' | '2' | - | One of '1', '2'. Optional; empty is not rendered. |