Skip to main content

ConsentBanner

ConsentBanner — Prism component.

Signature
Density
Viewport
Theme follows the navbar ☀/☾ toggle
Live demo
Open ↗

When to use

ConsentBanner — Prism component.

Accessibility

Masked values stay obscured to assistive tech until revealed; the reveal toggle is a labelled button. Audit entries are an ordered list.

Import

const { ConsentBanner } = window.PrismDesignSystem_39d121;

Props

PropTypeRequiredDescription
titleReact.ReactNode
descriptionReact.ReactNode
acceptLabelReact.ReactNode
rejectLabelReact.ReactNode
manageLabelReact.ReactNode
onAcceptAll() => voidAccept all optional cookies.
onReject() => voidReject non-essential cookies.
onManage() => voidOpen granular preferences. When omitted, the Manage button is hidden.
policyHrefstringLink to the full privacy policy.
policyLabelReact.ReactNode
position"inline" | "fixed""inline" (in flow) or "fixed" (pinned to the bottom of the viewport).
iconReact.ReactNodeOverride the leading icon (SVG path nodes).
classNamestring