A collection of analog clocks showing the current time in different international airports and major cities around the world. Built with React and D3.js, this application displays real-time clocks for multiple time zones with smooth animations and customizable styling.
index.html
- Main HTML file with import map and basic
layoutindex.jsx
- Entry point rendering the main App componentcomponents/ClockContainer.jsx
- Renders all labeled
clockscomponents/LabeledClock.jsx
- Wraps a clock with its
location labelclock/Clock.jsx
- React wrapper for individual clock SVGclock/clockRenderer.js
- D3 rendering logic for clock
elementsclock/timeUtils.js
- Time calculation utilitiesclock/clockConfig.js
- Default style configuration for
clocksdata/timeZones.js
- Time zone data for displayed
locationsYou can customize the appearance of all clocks by modifying
values in clock/clockConfig.js
. Each property is defined
as a fraction of the clock's total diameter:
To add or modify time zones, update data/timeZones.js
:
label
- Display name for the locationtimeZoneOffset
- UTC offset in hours (decimals allowed,
e.g. 5.5 for India)daylightSavings
- Boolean to apply automatic DST
adjustment (optional)This is a static site that can be deployed to any web server or CDN such as:
Simply upload all files to your hosting provider and serve
the index.html
file.
MIT