Skip to content

Mountain Weather on mobile: no sideways scroll, pinned tabs; matched temps and wind - #1495

Merged
rchlfryn merged 14 commits into
mainfrom
feat/nwac-weather-temp-wind-tables
Nov 9, 2026
Merged

rchlfryn merged 14 commits into
mainfrom
feat/nwac-weather-temp-wind-tables

Conversation

@rchlfryn

@rchlfryn rchlfryn commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator

Description

Makes the Mountain Weather page work on a phone and tightens up its tables. On a phone, nothing scrolls sideways any more: tables use a date toggle, the section tabs stay pinned under the header, and the page drops its card padding to give the tables room. On desktop, temperatures and wind sit level, wind strength is shown by shading, and the Extended section uses the same columns as temperatures and wind.

Related Issues

Feedback

Key Changes

Mobile fixes

  • No sideways scrolling. Every table except temperatures shows one date at a time behind a date toggle. Precipitation's Total is its own option. Temperatures show every date in one table.
  • Pinned section tabs. The section tabs stay pinned under the site header, edge to edge, with the current section's tab kept in view.
  • More room for tables. The issuance card drops its border and padding on a phone.
  • Zone page header fill. The zone page's weather table header had no fill: a Tailwind opacity modifier (bg-muted/50) rendered nothing, because the color variable holds a whole hsl() value. It now has a solid fill.
  • Keys and toggles fit. The snow and wind keys wrap instead of scrolling. The section tabs and weather summary's zones no longer scroll vertically. The 12h/24h toggle sits under the table, across from the snow key.

Temperature and wind tables

  • The two tables line up at xl and above, with rules between dates. Rows are 37px, matching the other tables.
  • Wind cells are shaded by strength, with a key under the table. The wording stays as screen-reader text, and zone tables keep it visible.
  • Lows are no longer bold. Wind direction is full size and every speed is bold. These two changes also apply to the zone tables, which share the cells.
  • The Extended section uses the same 1:2 columns as temperatures and wind.

Precipitation without snow amounts

  • Older forecasts never computed snow amounts. These now show water equivalent alone in one full-width 24-hour table, with no snow columns, key or 12h/24h toggle, and the title reads Precipitation.
  • A total or zone snow amount is unknown when any precipitation in it has no snow amount.

How to test

  1. On a phone (or below 768px), open /weather/forecast. Nothing should scroll sideways, every table except temperatures should have a date toggle.
  2. On a phone, scroll down the page. The section tabs should stay pinned under the header. Tap each tab: the page should jump to that section, with its tab highlighted and in view.
  3. Switch precipitation between 12h and 24h with the toggle under the table, and try Total.
  4. At 1280px or wider, temperatures and wind should start and end level, and Extended should line up with them.
  5. Open a forecast with no snow amounts. It should show one full-width 24-hour table with no toggle.
  6. Check a zone's forecast page, which shares the wind and temperature cells.
  7. Check that printing shows the full tables, not the toggles.

Screenshots / Demo video

Change dates to toggle for mobile view

Precip Wind
Screenshot 2026-11-09 at 10 55 52 Screenshot 2026-11-09 at 10 55 36

Align bottom tables on desktop & add wind gradient
Screenshot 2026-11-09 at 10 50 32

Migration Explanation

No migrations.

Future enhancements / Questions

  • With announcement banners open, the pinned header and tabs together take a large share of a phone screen.
  • Each table's date toggle works on its own.
  • The WidgetZoneWeather tests get a 15s timeout. Each renders the whole issuance, desktop and phone tables both, and they ran past 5s locally when the whole suite ran in parallel. Each takes under a second on its own.
  • Tested in the browser at 375px and 1400px with mock data, which tops out at Strong wind. The precipitation-only table was checked with a local fixture with snow ratios blanked.
  • The precipitation zone heading rows on a phone use the same bg-muted/50 and still render without a fill. They're unchanged here.
  • Not checked yet: the Playwright e2e suite, print, and the zone page in a browser (including its header fill).

@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

rchlfryn and others added 6 commits November 6, 2026 16:49
…cally

The snow keys wrap instead of scrolling sideways. The section tabs and the
weather summary's zones hang 1px below their row, which made both scroll
vertically; they still swipe sideways.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Temps and wind share rows at xl, so they start and end level whatever their
descriptions' lengths, with stripes and rules by date. On a phone every table
shows one date at a time behind a toggle instead of scrolling sideways, and
the issuance card drops its padding for the room.

Wind cells read as the design has them: direction at full size, every speed
bold, Calm bold after its direction. Lows are no longer bold. fmtWind had no
callers left.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The temperature table always has room for its dates, so it skips the date
switch the wider tables need.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rows

The wording under each wind value set the row height of both paired tables.
It moves to a shaded cell with a key, and stays as text for screen readers, so
rows drop from 68px to 48px. The zone tables keep their wording.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With the wording gone the two tables no longer need taller rows, so they drop
to the 37px every other table uses, and lose their alternating colors. The wind
key sits on one line that wraps on a phone, like the snow level key.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ggle under the table

A forecast with no snow amounts shows one stretched 24-hour table instead of a
small one behind a toggle. Elsewhere the 12h/24h toggle moves under the table,
across from the snow key, and shrinks to fit that row.

The wind key leads with the arrow and VAR notes, centered with the bar.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rows filled

The section tabs pin below the mobile header, edge to edge, and keep the
current tab scrolled into view; the current section is measured below them.
Zone heading rows over the stations get a solid fill: bg-muted/50 rendered
nothing, since the color variable holds a whole hsl() value.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@rchlfryn rchlfryn changed the title Mountain Weather tables: matched temps and wind, date toggles on phones Mountain Weather on mobile: no sideways scroll, pinned tabs; matched temps and wind Nov 9, 2026
rchlfryn and others added 2 commits November 9, 2026 11:27
bg-muted/50 rendered nothing, since the color variable holds a whole hsl()
value, so the header of the zone page's 6-hour blocks gets a solid fill.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The replace test renders a whole issuance twice and ran past Jest's 5s default
when the pre-commit suite shared the machine; alone it takes under a second.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The gray fill blended into the table header, so the zone rows over the stations
take the theme's primary color with its foreground text.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The test before this was not the only one: each renders the whole issuance,
desktop and phone tables both, and another ran past 5s under the full suite.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ywhere

The dark band was too heavy, so zone rows become quiet uppercase labels. Desktop
uses them too, in place of the separate Zone column, which goes with its code.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… plain headings

Reverts the small-caps rows, the dark band and the solid fill on the phone's zone
rows, with the desktop Zone column and its code restored.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@rchlfryn
rchlfryn marked this pull request as ready for review November 9, 2026 21:07
@rchlfryn
rchlfryn added this pull request to the merge queue Nov 9, 2026
@rchlfryn rchlfryn self-assigned this Nov 9, 2026
Merged via the queue into main with commit 06b5f2b Nov 9, 2026
19 checks passed
@rchlfryn
rchlfryn deleted the feat/nwac-weather-temp-wind-tables branch November 9, 2026 21:14
@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown
Contributor

🚀 This is included in version v1.27.0

This branch was successfully deployed

1 active deployment
Preview — aaa4795a Deployed Nov 9, 2026 by rchlfryn via build #3290
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant