StealThis .dev

Clinic — Locations & Hours

A locations and hours page with three site cards, each pairing a stylized CSS map, full address, on-site service tags and a phone number with a Monday-to-Sunday hours table. Vanilla JS highlights today's row, reads the device clock and computes a live Open now, Closes soon or Closed badge from each day's real opening times, plus Get directions and Call buttons that surface a toast.

In Lab öffnen
html css vanilla-js
Targets: JS HTML

Code

Locations & Hours

A calm, scannable directory for Northpoint Clinic’s three neighbourhood sites. Each card leads with a stylized, dependency-free CSS map — roads, a park or river, and a coral location pin — then sets out the full address, a Monday-to-Sunday hours table, a row of on-site service tags and a tappable phone number. The layout flows as a responsive grid that collapses to a single column on small screens.

The interactivity is genuinely live. Vanilla JS reads the device clock, highlights today’s row in each table and computes an Open now, Closes soon, Opens soon or Closed badge by comparing the current time against that day’s real opening and closing hours. When a site is shut, the badge looks ahead to the next open day and tells you when it reopens. A header line echoes the local day and time, and the status re-evaluates every thirty seconds so badges flip at opening and closing time without a reload.

Get directions and Call buttons confirm the chosen action through a small toast, keeping the copy empathetic and the page keyboard-friendly with clear focus states and AA-contrast colour throughout.

Illustrative UI only — not intended for real medical use.