Banner (Ankündigungsleiste) — component.banner
Seitenbreite Ankündigungsleiste mit Ton-Varianten, optionalem Link und Schließen-Knopf — geschlossen bleibt sie pro Sitzung zu (storageKey). 1.1.0: feste Texte mehrsprachig (invisible_i18n). 1.2.0 (16.10.2026, opt-in): actionLabel = Knopf neben dem Text statt eines Links (data-banner-action, Ereigni
Beispiele
Ankündigung (accent, mit Link + schließbar)
Warnung (nicht schließbar)
Neutral ohne Icon
Unsicherer Link → nur Text
Eigenschaften
| Prop | Typ | Default |
|---|---|---|
text * | string | — |
tone | string: accent | neutral | info | success | warning | danger | "accent" |
linkText | string | "" |
linkHref | string | "" |
actionLabel | string | "" |
dismissible | boolean | true |
storageKey | string | "" |
icon | string | "megaphone" |
padding | string: standard | none | sm | md | lg | xl | "standard" |
margin | string: standard | none | sm | md | lg | xl | "standard" |
border | string: standard | none | hairline | strong | "standard" |
radius | string: standard | none | control | surface | pill | "standard" |
textColor | string | "" |
backgroundColor | string | "" |
shadow | string: standard | none | sm | md | lg | "standard" |
width | string: standard | full | "standard" |
alignSelf | string: standard | start | center | end | "standard" |
anchor | string | "" |
Events & Slots
Events: dismiss
Stellschrauben (Komponenten-Tokens)
| Token | Default |
|---|---|
--banner-bg | var(--color-action-primary) |
--banner-fg | var(--color-text-inverse) |
--banner-padding-y | var(--size-2) |
Genutzte Design-Tokens
color.action.primary color.status.danger color.status.danger-surface color.status.info color.status.info-surface color.status.success color.status.success-surface color.status.warning color.status.warning-surface color.surface.sunken color.text.default color.text.inverse duration.fast easing.standard focus.ring-width font.family.default radius.full size.2 size.3 size.4 size.6 text.sm weight.semibold