Skip to main content
Clever Ops

Emergency Bar

A 24/7 emergency strip, a lamp that pulses once, the phone number set huge for wet thumbs, and an average-callout stat that counts up. Urgency without panic, dependable at 2am.

Preview & code

Loading Emergency Bar preview

Installation

pnpm dlx shadcn@latest add @cleverui/trade-emergency-bar

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

Usage

tsx
import { TradeEmergencyBar } from '@/components/blocks/trade-emergency-bar'
Exampletsx
import { TradeEmergencyBar } from '@/components/blocks/trade-emergency-bar'

export default function TradeEmergencyBarDemo() {
  return (
    <div className="mx-auto max-w-6xl px-0 py-8 sm:px-0">
      <TradeEmergencyBar
        label="24/7 emergency"
        phone="1300 882 441"
        message="Burst pipe? Sparking switchboard? We're awake."
        stat={{ value: 38, suffix: 'min', label: 'average callout' }}
        tone="emergency"
      />
    </div>
  )
}

API reference

TradeEmergencyBar accepts the following props.

PropTypeDefaultDescription
labelstring'24/7 emergency'
phone*stringrendered huge as a tel: link, the whole strip exists for this tap
messagestring"Burst pipe? Sparking switchboard? We're awake."one plain line of triage copy
statTradeEmergencyStat{ value: 38, suffix: 'min', label: 'average callout' }honest urgency stat, counts up once in view
tone'emergency' | 'primary''emergency'emergency uses destructive for lamp + keyline; primary for softer after-hours

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

Referenced types

Typestsx
export interface TradeEmergencyStat {
  value: number
  suffix?: string
  label: string
}

Frequently asked questions

How do I install the Emergency Bar component?

Register the @cleverui registry in your components.json ("@cleverui": "https://cleverops.com.au/r/{name}.json"), then run `npx shadcn@latest add @cleverui/trade-emergency-bar`. 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 Emergency Bar require?

Emergency Bar 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 Emergency Bar 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