Skip to content
NewService Map: 30 components for hosts, ports and routes
<hf-status>Custom elementFeedbackFree

Uptime

Uptime chart of daily bars coloured by incidents, with today pulsing; hover or use the arrow keys to read a day's figures.

View as Markdown
<hf-status>

Tryhover the red bar.

Playground

Change a prop and the component updates. Props marked live animate to the new value; the others rebuild the element.

Loading <hf-status>
Props
nameremounts
incidentsremounts
stateremounts
<HfStatus name="API" incidents="3:down,17:deg,41:deg" />

Installation

pnpm dlx shadcn@latest add @lumesec/hf-status
First timeRegister the @lumesec registry once, or install by URL+

Adds @lumesec to your components.json:

pnpm dlx shadcn@latest registry add @lumesec=https://elements.lumesec.ai/r/{name}.json

Or skip the setup and install by URL:

npx shadcn@latest add https://elements.lumesec.ai/r/hf-status.json

Usage

import { HfStatus } from "@/components/lumesec/hf-status";

export function Example() {
  return (
    <HfStatus name="API" incidents="3:down,17:deg,41:deg" />
  );
}

Behaviour

Daily bars that rise in from the left, coloured by incidents, with today pulsing. Hover or use the arrow keys for the day’s numbers; the number of days adapts to the width.

API reference

Attributes

nameReact propnameTypestringDefaultAPI

Service name in the header. Also seeds the generated history.

incidentsReact propincidentsTypestring

Comma-separated daysAgo:kind entries that force a day's status. kind is down for a partial outage; any other value means degraded. 0 is today.

stateReact propstateTypeoperational | degraded | outage

Overrides the status pill. Defaults to today's status.

Keyboard

KeysAction
ArrowLeft / ArrowRightSelect the previous or next day, starting from today.
Home / EndSelect the first or last day.

Accessibility

  • The canvas has role="img", tabindex="0" and an aria-label with the average uptime, the number of days with incidents and a hint to use the arrow keys.
  • The day tooltip has role="status", so the selected date and figures are announced.
  • Leaving the canvas or moving focus away clears the selection.
  • Reduced motion: the bars appear without rising in, today's bar does not pulse and the status dot ping is off.

Theming

The element reads your shadcn theme tokens through its shadow root, so light and dark follow your theme. The accent comes from --lumesec. See Theming.

This component reads --border, --foreground, --lumesec, --lumesec-success, --muted and --muted-foreground.

To restyle only LumeSec elements, set the matching --ui-* overrides: --ui-accent, --ui-border, --ui-fg, --ui-mono, --ui-muted, --ui-ok and --ui-raised.

Notes

  • History is generated demo data: each day's status and uptime come from a hash of name. Only incidents and state override it; there is no attribute for real data.
  • The day count adapts to the width: one bar per 6px, between 20 and 90 days. Attributes are read when the element lays out (on connect and resize), not when they change.

Was this page helpful?