# Rows, picture and text

- **[Sections](/blocks/)**
- **[Features](/blocks/features/)**
- **Rows, picture and text**

A centred heading and line, then one row per place or offer: a wide picture on one side, its name, a small line, a short text and a button on the other.

## Import

- **CLI**

  ```
  npx shadcn add https://ui.klarhimmel.com/r/rows-alternating.json
  ```
- **Import**

  ```
  import Block from '@/components/klarhimmel/blocks/rows-alternating';
  ```

Also called

- **About**: A centred heading and line, then one row per place or offer: a wide picture on one side, its name, a small line, a short text and a button on the other. The picture swaps sides row by row; on a phone each row stacks picture first.
- **Category**: What it does, as a grid, a list, tabs or alternating rows. New project? Set it up once: /get-started/installation.

## Notes

- **When to use it**: A centred heading and line, then one row per place or offer: a wide picture on one side and a name, a small line, a short text and a button on the other, swapping sides row by row. Use `features-split` for one pair.
- **Writing for it**: - Write each row as one place or one offer, with the name first and a small line for its type or price.
- Use the light first word and bold second part of the heading to split the idea in two.
- Give each row its own button label, such as the name of the place, so the links are not all the same word.
- **Watch out for**: Pictures swap sides only where there is room, and on a phone each row stacks with the picture first. Rows of very different text length make the zigzag uneven, so aim for similar lengths.

## Pairs well with

- **[Hero, header row](/blocks/hero/header-row)**
- **[Testimonials, grid](/blocks/testimonials/grid)**
- **[Call to action, band](/blocks/cta/banner)**

## 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 RowsAlternating from '@/components/klarhimmel/blocks/rows-alternating';

export default function Section() {
  return (
    <Theme theme="brand">
      <BlockSurface>
        <RowsAlternating props={{
          "title": "Our",
          "titleAccent": "Name them",
          "description": "Say in a line or two where they are or what they share, and what the reader can choose between below.",
          "items": [
            {
              "title": "Name the place",
              "detail": "Its address or its kind",
              "description": "Say what it is like and who it suits best, in a sentence or two.",
              "media": {
                "src": "/pictures/photo-lily1.avif",
                "alt": "A white lily in soft light"
              },
              "link": {
                "label": "Show this place",
                "href": "#place-one"
              }
            },
            {
              "title": "Name the second place",
              "detail": "Its address or its kind",
              "description": "Say what it is like and who it suits best, in a sentence or two.",
              "media": {
                "src": "/pictures/photo-optic1.avif",
                "alt": "Silver-framed glasses on a white table"
              },
              "link": {
                "label": "Show this place",
                "href": "#place-two"
              }
            }
          ]
        }} />
      </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.

- **title**: Text, up to 24 characters.
- **titleAccent**: Text, up to 24 characters.
- **description**: Text, up to 300 characters.
- **items**: List of 1 to 6. Each item: title, detail, description, media, link.
- **headingLevel**: One of '1', '2'. Optional; empty is not rendered.

[Previous](/blocks/features/terminal)

[Next](/blocks/steps/horizontal)
