The frontend formats dates in six places, three different ways:
Where
Zone
Labelled
Format
lib/format.tswhen(): swap, pool-swap and block tables
viewer's local
no
fixed en-GB
ShareChart, PriceChart, StatBar axes and tooltips
viewer's local
no
browser locale (12h or 24h)
NetworkPanel daily table (d.day.slice(0, 10))
UTC
no
2026-10-05
FlowChartdayLabel (wormhole page)
local, applied to UTC days
no
Oct 5
VestingPanel
local
no
browser locale
NodePanel start-time tooltip
UTC (ISO)
implicitly
ISO 8601
No zone anywhere. A screenshot or a copied time is ambiguous: the same problem as the "17:00" on the launch announcement, which only made sense once we assumed the poster's timezone.
Off by one day west of UTC. Daily buckets from the API are UTC days (2026-10-05T00:00:00Z, from date_trunc('day', …)). FlowChart formats them in local time, so in any negative-offset zone every bar is labelled the previous day, while NetworkPanel prints the UTC date. The two pages disagree for a viewer in the Americas.
Two formats side by side. A chart axis reads "05:40 PM" next to a table reading "17:40".
What
One formatter per kind in lib/format.ts, used everywhere: the same lesson as Field and isStandings, since copies drift.
instant(iso): the viewer's local time with its zone, e.g. 06 Oct 2026, 09:04 EEST (timeZoneName: 'short'). Its title carries the UTC ISO time.
clock(ms, span): chart axis labels, local, 24h, with the zone said once in the chart's tooltip.
utcDay(iso): a day bucket, always formatted with timeZone: 'UTC'. Charts and tables of daily figures say "UTC days".
One locale decision:en-GB-style 24h everywhere. It is what the tables already use and it does not vary by viewer.
A test that a UTC-midnight bucket formats as its own date in a negative-offset zone, the case that is wrong today.
## Why
The frontend formats dates in six places, three different ways:
| Where | Zone | Labelled | Format |
|---|---|---|---|
| `lib/format.ts` `when()`: swap, pool-swap and block tables | viewer's local | no | fixed `en-GB` |
| `ShareChart`, `PriceChart`, `StatBar` axes and tooltips | viewer's local | no | browser locale (12h or 24h) |
| `NetworkPanel` daily table (`d.day.slice(0, 10)`) | UTC | no | `2026-10-05` |
| `FlowChart` `dayLabel` (wormhole page) | **local, applied to UTC days** | no | `Oct 5` |
| `VestingPanel` | local | no | browser locale |
| `NodePanel` start-time tooltip | UTC (ISO) | implicitly | ISO 8601 |
1. **No zone anywhere.** A screenshot or a copied time is ambiguous: the same problem as the "17:00" on the launch announcement, which only made sense once we assumed the poster's timezone.
2. **Off by one day west of UTC.** Daily buckets from the API are UTC days (`2026-10-05T00:00:00Z`, from `date_trunc('day', …)`). `FlowChart` formats them in local time, so in any negative-offset zone every bar is labelled the previous day, while `NetworkPanel` prints the UTC date. The two pages disagree for a viewer in the Americas.
3. **Two formats side by side.** A chart axis reads "05:40 PM" next to a table reading "17:40".
## What
- **One formatter per kind** in `lib/format.ts`, used everywhere: the same lesson as `Field` and `isStandings`, since copies drift.
- `instant(iso)`: the viewer's local time **with its zone**, e.g. `06 Oct 2026, 09:04 EEST` (`timeZoneName: 'short'`). Its `title` carries the UTC ISO time.
- `clock(ms, span)`: chart axis labels, local, 24h, with the zone said once in the chart's tooltip.
- `utcDay(iso)`: a day bucket, always formatted with `timeZone: 'UTC'`. Charts and tables of daily figures say "UTC days".
- **One locale decision:** `en-GB`-style 24h everywhere. It is what the tables already use and it does not vary by viewer.
- **A test** that a UTC-midnight bucket formats as its own date in a negative-offset zone, the case that is wrong today.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Why
The frontend formats dates in six places, three different ways:
lib/format.tswhen(): swap, pool-swap and block tablesen-GBShareChart,PriceChart,StatBaraxes and tooltipsNetworkPaneldaily table (d.day.slice(0, 10))2026-10-05FlowChartdayLabel(wormhole page)Oct 5VestingPanelNodePanelstart-time tooltip2026-10-05T00:00:00Z, fromdate_trunc('day', …)).FlowChartformats them in local time, so in any negative-offset zone every bar is labelled the previous day, whileNetworkPanelprints the UTC date. The two pages disagree for a viewer in the Americas.What
lib/format.ts, used everywhere: the same lesson asFieldandisStandings, since copies drift.instant(iso): the viewer's local time with its zone, e.g.06 Oct 2026, 09:04 EEST(timeZoneName: 'short'). Itstitlecarries the UTC ISO time.clock(ms, span): chart axis labels, local, 24h, with the zone said once in the chart's tooltip.utcDay(iso): a day bucket, always formatted withtimeZone: 'UTC'. Charts and tables of daily figures say "UTC days".en-GB-style 24h everywhere. It is what the tables already use and it does not vary by viewer.