Toastflow
Playground
Global

Styling

Customize Toastflow with CSS variables, theme classes, and headless rendering.

Toastflow is CSS-first. Start with variables, use theme classes for reusable variants, and keep inline css for one-off toasts.

Most apps only need CSS variables. You do not need a design-system wrapper just to make Toastflow match your brand.

The Three Levels

Use this for the default app-wide look.

toast.ts
toast.info({
  title: "Global variables",
  description: "Font, radius, and color tokens from :root.",
});
app.css
:root {
  --tf-toast-font-family:
    "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  --tf-toast-border-radius: 4px;
  --tf-toast-padding: 18px;
  --tf-toast-bg: #fff7ed;
  --tf-toast-color: #431407;
  --tf-toast-title-color: #431407;
  --tf-toast-description-color: #7c2d12;
  --tf-toast-border-color: #fb923c;
  --tf-toast-icon-color: #ea580c;
  --tf-toast-progress-bg: color-mix(in srgb, #ea580c 18%, transparent);
  --tf-toast-progress-bar-bg: #ea580c;
}

The live preview below mirrors all three tabs. It scopes the global variables around a local preview container, so Theme class and Inline override inherit the global font, radius, and spacing while overriding only their own color tokens.

Try this example

Buttons mirror the global variables, theme class, and inline css examples above.

Copyright © 2026