Skip to content

Internal ID software / Surfaces

CardHeader

The top of a card: what it is, and at most one thing to do with it.

Not drawn in Figma: built only from the tokens, for internal ID software. In code: components/software/card.tsx. From the old system: CardHeader in @id-identity-as/ui.

Example

Brugere

Eksempeldata

Se alle

Indholdet af kortet.

Brugere

Eksempeldata

Se alle

Indholdet af kortet.

import { Card, CardHeader } from '@/components/software/card';

<CardHeader title="Brugere" hint="12 aktive" action={<Link variant="block" href="/brugere">Se alle</Link>} />

Props

PropTypeDefaultWhat it does
title (required)stringThe name of what the card holds.
level2 | 3 | 43The heading level of the title in the outline of the page.
eyebrowstringA short line above the title, such as "Ordre 41028".
hintstringA short line under the title, such as who and when.
actionReactNodeOne control at the end of the header, such as a link or a button.

Do

  • Keep the title to a few words. Heading names things.
  • Set level so the title fits the outline around the card.

Do not

  • Do not put two actions in the header. The second belongs in the card.
  • Do not write the eyebrow in capitals.

Accessibility

  • The title is a real heading, so the card lands in the outline of the page.

Tokens it uses

  • type.heading.md
  • type.body.sm
  • color.software.muted
  • space.inline.1
  • space.inline.3
  • space.inline.4