Title
0.2.6
Title-komponenten är en atom som används flitigt i våra List- och Card-komponenter.
Namn | Typ | Beskrivning |
---|---|---|
alignItems | "start" |
"end" | The flex layout align items. |
badge | ReactElement | Badge to display in the title. |
customAttribute | { attribute: string; value: string |
number } | Used for tests. Clickable and requested subcomponents will be suffixed with "-[ComponentName]". |
id | string | ID for the title element. |
isLoading | boolean | If true, a loading skeleton will be rendered instead of the component. |
subtitle | ReactNode | Subtitle displayed below the title. A string is preferred, but React.ReactNode can be used for special cases, like combining text with icons. |
title * | ReactNode | The main title text. A string is preferred, but React.ReactNode can be used in special cases, such as combining text and icons. |
titleComponent | ElementType | Change the component of the Title element. Use this to separate styling from semantics, for instance if you need an H2 heading to look like an H3. |
alignItems | "start" |
"end" | The flex layout align items. |
badge | ReactElement | Badge to display in the title. |
customAttribute | { attribute: string; value: string |
number } | Used for tests. Clickable and requested subcomponents will be suffixed with "-[ComponentName]". |
id | string | ID for the title element. |
isLoading | boolean | If true, a loading skeleton will be rendered instead of the component. |
subtitle | ReactNode | Subtitle displayed below the title. A string is preferred, but React.ReactNode can be used for special cases, like combining text with icons. |
title * | ReactNode | The main title text. A string is preferred, but React.ReactNode can be used in special cases, such as combining text and icons. |
titleComponent | ElementType | Change the component of the Title element. Use this to separate styling from semantics, for instance if you need an H2 heading to look like an H3. |
npm install @sj-ab/component-library.ui.title
Title presenteras som ett eller flera textelement (paragraf eller rubrik).
Just nu går det inte att ändra den semantiska rubriknivån på Title. Detta är en känd brist som ska åtgärdas.
Importer av Title
Repos med Title
Senaste installerade version av Title
Äldsta installerade version av Title