Skip to main content
Clever Ops

Challenge Countdown Panel

A gym challenge block that starts the clock, bold condensed challenge name, an SSR-safe rolling countdown to a prop-driven start date, stakes line and spots left. React and Tailwind.

Preview & code

Loading Challenge Countdown Panel preview

Installation

pnpm dlx shadcn@latest add @cleverui/challenge-countdown-panel

Requires the @cleverui registry in your components.json, a one-off, two-line setup.

Usage

tsx
import { ChallengeCountdownPanel } from '@/components/blocks/challenge-countdown-panel'
Exampletsx
'use client'

import { ChallengeCountdownPanel } from '@/components/blocks/challenge-countdown-panel'

export default function ChallengeCountdownPanelDemo() {
  return (
    <ChallengeCountdownPanel
      eyebrow="Commit or don't"
      challengeName="The Six Week Reset"
      startsAt="2026-08-04T06:00:00"
      startsAtLabel="Starts Monday 4 Aug, 6am"
      now="2026-07-28T09:00:00"
      stakes="$50 buy-in. Finish all 18 sessions and it comes back."
      spotsLeft={6}
      spotsThreshold={10}
      ctaLabel="Take the challenge"
      onJoin={() => {}}
    />
  )
}

API reference

ChallengeCountdownPanel accepts the following props.

PropTypeDefaultDescription
challengeName*stringthe panel hero, rendered uppercase, e.g. The Six Week Reset
eyebrowstringcoach-voice kicker, e.g. COMMIT OR DON'T
startsAt*Date | stringcountdown target datetime (ISO string ok)
startsAtLabel*stringPREFORMATTED visible start line, e.g. Starts Monday 4 Aug, 6am, the only date text ever rendered server-side
nowDate | stringreference time for deterministic SSR/demos; live clients omit and resolve post-mount
stakesstringthe deal in plain words, e.g. $50 buy-in. Finish all 18 sessions and it comes back.
spotsLeftnumberrenders the spots line when provided; 0 renders FULL and disables the CTA
spotsThresholdnumber10spotsLeft at or under this renders the bold urgent state
ctaLabelstring'Take the challenge'
hrefstringCTA renders as an anchor when set
onJoin() => voidCTA renders as a button when set and href is absent

…plus everything from React.HTMLAttributes<HTMLElement>: className, event handlers, aria attributes and the rest pass straight through.

Frequently asked questions

How do I install the Challenge Countdown Panel component?

Register the @cleverui registry in your components.json ("@cleverui": "https://cleverops.com.au/r/{name}.json"), then run `npx shadcn@latest add @cleverui/challenge-countdown-panel`. The shadcn CLI copies the source into your project, you own the code from that point. You can also copy the source directly from this page.

What dependencies does Challenge Countdown Panel require?

Challenge Countdown Panel uses motion on top of React and Tailwind CSS. You don't need to install it manually, the shadcn CLI resolves and installs npm dependencies automatically when you add the component.

Can I theme Challenge Countdown Panel to match my brand?

Yes. The component is styled entirely with Tailwind utilities over standard design tokens (primary, background, muted, border), so it inherits your existing shadcn/ui theme automatically. Change your CSS variables and the component follows, no source edits needed for palette, radius, or fonts.

Want this built for you?

CleverUI is built by the Clever Ops web team. If you'd rather ship a hand-coded, fast, custom website than assemble one, we build them for Australian businesses every week.

Explore web development services