Customization
Banner designs
Pick a design
Each design below is a real c15t banner. The screenshots and the code come from the same Storybook stories, which CI runs to check that each design renders and that Accept and Reject record a choice.
| Design | Customization level | Frameworks |
|---|---|---|
| Bottom bar | Props | React, Vue, Astro, Svelte |
| Branded card | Theme tokens | React |
| Choice wall | Props | React |
| Slim bar | Compound parts or slots | React, Vue, Svelte |
| Headless bar | Headless | React, Vue, Svelte, HTML |
Next.js and TanStack Start apps use the React code, with the same components
imported from c15t/next or c15t/tanstack-start. Nuxt uses the Vue code and
SvelteKit uses the Svelte code. Customization
explains when to use each level.
Every design keeps the policy in charge. The policy decides which buttons a visitor gets, and none of these designs records consent until the visitor clicks a button.
Bottom bar

The stock banner becomes a full-width bar along the bottom edge with one prop,
variant="bar". The title and copy sit on the left and the buttons on the
right.
Render CookieBanner in place of ConsentBanner, inside your
ConsentProvider and next to ConsentDialog.
The HTML script tag takes the same shape through presentation.prompt. See
customize the script tag.
Branded card

Theme tokens change the colors, type and radius of the stock card without touching its markup. This theme sets a green primary color, an off-white surface, a serif font and four-pixel corners, and fills the actions the policy marks as primary. Here the policy marks both Reject All and Accept All as primary, so neither choice stands out.
ConsentTheme renders the tokens as a <style> element. In a server-rendered
app, render it from a Server Component or the root layout so the tokens arrive
with the HTML. The provider's theme option reads only consentActions and
slot styles, so pass the same object there for the filled buttons:
The preferences dialog reads the same tokens:

Vue, Svelte, Astro and the script tag set the same tokens their own way. See customize for Vue, Svelte, Astro or HTML, and theme tokens for every token.
Choice wall

variant="wall" centers the stock banner over a backdrop, locks scrolling and
traps focus until the visitor chooses. Use it only where a policy requires a
choice before the page is usable.
A choice wall always blocks. A notice never blocks, so a wall requested for a notice falls back to the floating card.
Slim bar

The slim bar puts the title, the copy and the buttons on one row, so it is
shorter than the stock bar. React builds it from the
ConsentBanner compound parts. Vue and Svelte have no compound banner parts,
so they add classes to the stock bar's card and header through slots. All
three use the same stylesheet, and all three keep the buttons the policy
requires.
ConsentBanner.PolicyActions renders the policy's buttons, so a required
Reject button stays. Render CookieBanner inside your ConsentProvider,
next to ConsentDialog.
Headless bar

The headless bar is your own markup and CSS, driven by c15t's headless API. It shows the same design in every framework. The policy still decides which buttons appear and in what order, the Preferences button is always there, and a choice is recorded only when the visitor clicks.
useHeadlessConsentUI() from c15t/react/headless returns the banner
state and performAction. Render CookieBar in place of
ConsentBanner, and keep ConsentDialog, which Preferences opens.
React, Vue and Svelte import the same stylesheet, cookie-bar.css. The HTML
block contains it inline.
On a 375-pixel screen the copy takes the full width, Preferences sits on its own line, and Reject all and Accept all share a row at equal width:

In the HTML version, Preferences opens the switches inside the bar:

A headless UI owns its focus handling and labels. Test it with a keyboard and a screen reader. The headless pages for React, Vue and Svelte cover notices and custom preference forms.
Check a design
Run these checks after you adopt a design:
- Clear site data and reload. The banner appears and no optional vendor request appears in DevTools Network.
- Click Reject all, reload, and confirm the banner stays closed and the vendors stay blocked.
- Open preferences from your footer link, allow one category, save, and confirm only that category's vendors load.
- Test a 375-pixel viewport with your longest translation, and tab through every button.
Verify consent has the full list.
Run the designs
The source repository renders each design in its Storybook under
Docs / Banner designs: apps/storybook-react, apps/storybook-vue,
apps/storybook-svelte and apps/storybook-astro. Each story uses an
in-memory policy and loads no analytics. The HTML headless bar runs at
/consent-example/headless in internals/fixtures/script-tag, which the example
acceptance tests cover.