# Hero, card cover

- **[Sections](/blocks/)**
- **[Hero](/blocks/hero/)**
- **Hero, card cover**

A full-width picture with one centred card over it holding a small label, the heading, one line and two actions.

## Import

- **CLI**

  ```
  npx shadcn add https://ui.klarhimmel.com/r/hero-card-cover.json
  ```
- **Import**

  ```
  import Block from '@/components/klarhimmel/blocks/hero-card-cover';
  ```

Also called

- hero/card-cover

- **About**: A full-width picture with one centred card over it holding a small label, the heading, one line and two actions. The card keeps its width on a phone and the actions stack.
- **Category**: The first screen: what it is, who it is for, what to do next. New project? Set it up once: /get-started/installation.

## Notes

- **When to use it**: A full-width picture with one centred card over it that holds a label, the heading, a line and two actions. Pick `hero-split` when the picture should sit beside the text and stay fully visible.
- **Writing for it**: - Choose a picture that stays calm behind a pale card, because the card hides the middle of it and the edges carry the mood.
- Write the label as two or three words naming the topic, the heading as the one promise, and use the two actions for the main step and a softer one.
- Set the alignment to center for a short, formal opener and to start when the heading runs to two lines.
- **Watch out for**: When the band is set to fill the screen height, a busy photograph can pull attention away from the card. Without it the band is only as tall as the card plus padding, which suits a quieter page.

## Pairs well with

- **[Navbar, simple](/blocks/navigation/simple)**
- **[Logos strip](/blocks/logo-cloud/row)**
- **[Features, grid](/blocks/features/grid)**

## 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 HeroCardCover from '@/components/klarhimmel/blocks/hero-card-cover';

export default function Section() {
  return (
    <Theme theme="brand">
      <BlockSurface>
        <HeroCardCover props={{
          "media": {
            "src": "/pictures/photo-tree1.avif",
            "alt": "An oak canopy seen from below"
          },
          "eyebrow": "Name the topic in two or three words",
          "title": "Say what this page offers, in plain words",
          "description": "Give the reader a short reason to keep going: who it is for and what they get.",
          "primary": {
            "label": "Name the main action",
            "href": "#primary"
          },
          "secondary": {
            "label": "Name the other action",
            "href": "#secondary"
          },
          "fullHeight": true,
          "align": "start"
        }} />
      </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.

- **media**: See the type.
- **eyebrow**: Text, up to 40 characters.
- **title**: Text, up to 80 characters.
- **description**: Text, up to 200 characters.
- **primary**: See the type.
- **secondary**: Optional; empty is not rendered.
- **fullHeight**: See the type.
- **align**: One of 'start', 'center'.
- **headingLevel**: One of '1', '2'. Optional; empty is not rendered.

[Previous](/blocks/banner/floating-actions)

[Next](/blocks/hero/centered)
