Tapas UI
Esc
  • IntroductionGetting startedWhat Tapas UI is and where to start.
  • InstallationGetting startedSet up shadcn/ui and add your first section.
  • CLI & AI agentsGetting startedThe shadcn CLI, the @tapas namespace, the MCP server and AI prompts.
  • TemplatesGetting startedWhole pages built from sections, installed with one command.
  • Demo sitesGetting startedThree fictional sites built only from Tapas sections.
  • ThemingCustomizationHow sections pick up your colors and radius.
  • ColorsCustomizationEvery CSS variable sections read, what it is for and where it is used.
  • Dark modeCustomizationSections follow your .dark variables.
  • MotionCustomizationPlain and motion versions, reduced motion and pause controls.
  • AccessibilityCustomizationWhat every section guarantees.
  • Waitlist formsGuidesPost signups to your own API route and store them.
  • Checkout linksGuidesPoint pricing buttons at Stripe payment links or any URL.
Menu
Browse the docs

DocsHeroes

Hero: theme cycle

Hero whose accent word wears your primary color.

Preview

Version
Preview theme color
More themes

The whole hero re-colors through a set of themes. It stops on hover, on focus and with the visible pause button. With reduced motion turned on, it renders the plain layout.

Themeable

Your theme, not ours

The accent word, badge and buttons follow --primary. Sample copy.

Themeable

Your theme, not ours

The accent word, badge and buttons follow --primary. Sample copy.

Installation

Run this in a project that already uses shadcn/ui. It adds the component and anything it needs; the motion version also adds the plain one and the motion package.

Usage

import { HeroThemeCycle } from "@/components/custom/hero-theme-cycle";

<HeroThemeCycle
  title="Your theme, not ours"
  accentWord="theme"
  primaryAction={{ label: "Get started", href: "/signup" }}
/>
import { HeroThemeCycleMotion } from "@/components/custom/hero-theme-cycle/hero-theme-cycle-motion";

<HeroThemeCycleMotion title="Your theme, not ours" accentWord="theme" interval={3000} />

Props

PropTypeDefaultDescription
title* (required)string–The headline, rendered as the page's h1.
eyebrowstring–Small badge above the title.
descriptionstring–Supporting line under the title.
primaryAction{ label: string; href: string }–Filled button.
secondaryAction{ label: string; href: string }–Outline button.
accentWord* (required)string–Word in the title to color; ignored if the title doesn't contain it.
themes{ name; primary; primaryForeground }[]5 shadcn colorsThemes the motion version cycles through.
intervalnumber2500Milliseconds between themes (motion version).
...propsReact.ComponentProps<"section">–Any other section attribute (id, aria-*, data-*, ref) goes to the root element.
PropTypeDefaultDescription
title* (required)string–The headline, rendered as the page's h1.
eyebrowstring–Small badge above the title.
descriptionstring–Supporting line under the title.
primaryAction{ label: string; href: string }–Filled button.
secondaryAction{ label: string; href: string }–Outline button.
accentWord* (required)string–Word in the title to color; ignored if the title doesn't contain it.
themes{ name; primary; primaryForeground }[]5 shadcn colorsThemes the motion version cycles through.
intervalnumber2500Milliseconds between themes (motion version).
...propsReact.ComponentProps<"section">–Any other section attribute (id, aria-*, data-*, ref) goes to the root element.

Accessibility

  • The accent is color plus position, never color alone: the word is still part of the heading text.
  • The motion version follows the visitor's reduced-motion setting and never hides content before it animates.