Loading preview
Analog Clock
Data displayA station clock whose needle waits at twelve; drag the minute hand to set it by hand.
Real analog clocks for several cities with smooth second hands and day and night faces.
npx shadcn@latest add @venusui/world-clockRun this in a project set up with shadcn. If you haven’t set it up yet, run npx shadcn@latest init first.
Paths use the default shadcn aliases. The CLI follows the aliases in your components.json.
@/components/ui/world-clock.tsxThe code behind the preview above.
world-clock-demo.tsx
import { WorldClock } from "@/components/ui/world-clock"
export default function WorldClockDemo() {
return (
<WorldClock
zones={[
{ city: "San Francisco", timeZone: "America/Los_Angeles" },
{ city: "London", timeZone: "Europe/London" },
{ city: "Bengaluru", timeZone: "Asia/Kolkata" },
{ city: "Tokyo", timeZone: "Asia/Tokyo" },
]}
/>
)
}
| Prop | Type | Default | Description |
|---|---|---|---|
| zones | { city: string; timeZone: string }[] | — | Cities and their IANA time zones, e.g. Asia/Tokyo. |
All <ul> props.
Intl.DateTimeFormat; no time-zone library needed.night in the file.Unknown registry "@venusui"npx shadcn@latest), install by URL, or register it with its address: npx shadcn@latest registry add @venusui=https://venusui.com/r/{name}.json.No components.json foundnpx shadcn@latest init in your project first.A station clock whose needle waits at twelve; drag the minute hand to set it by hand.
Overlapping avatars with a +N counter that spread apart on hover.
Books on a wooden shelf whose spines lift on hover and pull out when selected, with a matching cover.