Commit Graph
23 Commits
Author SHA1 Message Date
Nate EmmertandClaude Sonnet 5.5 fd61e35b56 Redesign main app: slim top bar, dynamic sky hero, nowcast, scrub chart, unified palette
- One slate/blue palette across the app, dashboard, account/login pages (data colours
  stay orange = warm, blue = cool on the dashboard)
- Slim sticky top bar with location chip, gear (settings) and ? (learn); 4-tab nav
  (Now, Station, Map, Alerts) with a thumb-reach bottom bar on phones
- Hero sky gradient by condition/time with rain, storm, snow and star effects
  (respects reduced motion); keeps the searched city and badges when temps come from your station
- One-line summary, 'Next 2 hours' bars and rain countdown from 15-minute precipitation,
  rain/cold-aware 'Bring' chips; yesterday + 'vs usual' context from the station
- Scrubbable hourly chart (temp, rain chance, wind), 7-day range bars, AQI gauge,
  details tiles instead of drawers, taller radar with location marker + alert polygons
- Skeleton loading instead of a full-screen spinner, sticky section headers, safe areas
- Server: minutely_15 precipitation, public /api/station/summary

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-15 12:56:18 -04:00
Nate EmmertandClaude Sonnet 5.5 1830fb2e2b Merge /conditions into the app as a Station tab
- New Station tab (top tabs, bottom nav, swipe order) carrying the old /conditions look:
  radar-ring hero, condition pill, wind compass, atmosphere/precip/solar cards, indoor
- Scoped sl-* styles and station-live.js; units follow the app's metric/imperial setting
- Empty/error states when no station is connected
- /conditions now 301-redirects to /?tab=station; removed conditions.html,
  /api/conditions/public and the old My Station drawer
- /api/ambient-config also returns the station name
- Dashboard and settings links updated; SW cache v8; manifest shortcut for Station
- Drops an indoor-temp block in applyStationOverlay that referenced an out-of-scope helper

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-15 12:45:47 -04:00
Nate EmmertandClaude Sonnet 4.6 fc93079109 Fix hurricane overlay ordering and map-load guard
Publish Container / publish (push) Successful in 2m52s
- Move renderHurricaneOverlay call to after track layers so position
  circles render on top of the track line and dots
- Add map.loaded() guard to avoid overlay being silently skipped
  if the map style hasn't finished initializing

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-09-02 10:19:18 -04:00
Nate EmmertandClaude Sonnet 4.6 3af4c1df4b Add NHC forecast track to hurricane click-to-map
Publish Container / publish (push) Successful in 2m6s
- Parse NHC forecast advisory text (FORECAST VALID / OUTLOOK VALID lines)
  to extract real forecast positions at 9–117h intervals with wind speeds
- Render forecast track as dashed line + clickable dots (wind on click)
- Auto-fit map bounds to show the full 5-day track after loading
- Fix buildStyle to use OpenFreeMap vector tile URLs without API key

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-09-02 10:11:22 -04:00
Nate EmmertandClaude Sonnet 4.6 8b9d3639af Fix map basemap tiles and add hurricane click-to-map feature
Publish Container / publish (push) Successful in 2m18s
- Replace CARTO basemap tiles (now require API key) with OpenFreeMap
  vector tiles (positron for light, liberty for dark) — no key needed
- Add click handlers on hurricane panel cards to fly to storm on map
- Add flyToHurricane(): switches to map tab, enables hurricane overlay,
  flies to storm coords, shows popup with storm details
- Add /api/hurricanes/track proxy to fetch NHC GIS 5-day forecast track
  line and render it as a dashed overlay on the map

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-09-02 09:52:35 -04:00
Nate EmmertandClaude Sonnet 4.6 0d00c7f6ab Restore indoor sensor display and restructure dashboard layout
- Restore tempinf/humidityin tiles from PWS data on index.html (removed
  with thermostat cleanup but still available from Ambient station)
- Dashboard: replace two flat secondary-stat grids with labeled section
  cards — Wind, Precipitation, Climate, Indoor — for clearer visual
  hierarchy and category separation
- Indoor section card includes Ecobee portal link; appears only when
  station reports indoor sensor data

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-08-24 10:07:17 -04:00
Nate EmmertandClaude Sonnet 4.6 e133781760 Remove thermostat/indoor sensor integration
Ecobee API is closed to new developer registrations and iOS sub-daily
automations are no longer available, making the HomeKit push approach
unworkable. Removes all related code:

- server.js: HomeKit push endpoints, token management, data files
- dashboard.html: thermostat section card, indoor stat tiles, indoor
  charts, HomeKit settings panel, HVAC badge CSS, all related JS
- index.html: Indoor Temp stat card
- app.js: indoor sensor display logic

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-08-24 09:19:21 -04:00
Nate EmmertandClaude Sonnet 4.6 9620c1b0cd Add Ambient station primary source toggle; swap location name to station
When configured, a new "Use as primary source" toggle appears in Settings
under Ambient Weather Station (defaults on). When on, the location header
shows the station name and "Ambient Weather Station" subtitle instead of the
city; the hero badge is hidden as redundant. Toggling off restores the city
name immediately and re-shows the hero badge.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-08-19 12:13:00 -04:00
Claude 0005698264 Use station data for current conditions; persist keys server-side
Station overlay:
- When Ambient Weather station data is present and fresh (<15 min),
  its readings replace the model's current conditions: temp, feels-like,
  humidity, dewpoint, wind speed/direction, gusts, pressure (inHg→hPa),
  UV index, rain today, wind peek summary, and data-panel readouts
- A small "📡 My Station" badge appears in the hero when active
- applyStationOverlay() is called at the end of renderWeather (instant
  if station data already loaded) and again whenever station data
  refreshes (so the display stays live every 60 s)
- Hourly/daily forecasts continue to use Open-Meteo

Server-side key persistence:
- POST /api/ambient-config saves keys to data/ambient-config.json
  (same persistent volume as VAPID and subscriptions)
- GET /api/ambient-config returns {configured: bool} without exposing keys
- /api/ambient checks query params → saved config → env vars in order
- Settings Save button posts keys to server after a successful test;
  confirms "saved for all devices" in the status line
- On page load, if no localStorage keys but server is configured,
  the station loads automatically on any device
2026-08-19 15:53:10 +00:00
nmemmertandClaude b9e2b463f5 Add Ambient Weather personal station integration
* Add Ambient Weather personal station integration

Fetches live data from the user's Ambient Weather station via their
REST API and displays it as a "My Station" card in the conditions tab.

- server.js: add /api/ambient endpoint with 60s cache using
  AMBIENT_API_KEY and AMBIENT_APP_KEY env vars
- docker-compose.yml: expose AMBIENT_API_KEY/AMBIENT_APP_KEY env vars
- index.html: add collapsible "My Station" drawer to conditions tab
  showing temp, humidity, wind, gusts, daily rain, pressure, UV,
  solar radiation, and indoor readings
- app.js: add fetchAmbientStation() and renderAmbientStation(),
  auto-refresh every 60s, peek text summary in drawer header
- style.css: station drawer styles
- .gitignore: add .env so API keys stay off git

Co-Authored-By: Claude <noreply@anthropic.com>

* Move Ambient Weather keys to Settings panel

Users can now enter their API Key and Application Key directly in the
Settings tab under "Ambient Weather Station". Keys are saved to
localStorage and sent per-request to the server proxy.

- index.html: add API Key + Application Key inputs with Save button
- app.js: persist keys in localStorage, populate inputs on load,
  wire Save button (validates by testing the connection), pass keys
  as query params in fetchAmbientStation and its auto-refresh loop
- server.js: accept apiKey/appKey from query params with env var
  fallback; cache keyed per-user so multiple callers don't collide

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-08-19 11:35:16 -04:00
Nate EmmertandClaude Sonnet 4.6 b9e6cad190 Add CSS-based fullscreen for Map tab; fix state desync bug
- Add fullscreen toggle button (⛶/✕) to Map tab controls row
- CSS class `map-fs` hides header/nav and expands map to fill screen
- Drop unreliable requestFullscreen() API (blocked on iOS/PWA) in favor of pure CSS approach
- Fix button state desync: syncBtn() runs on init so stale ✕ state can't persist across reloads
- Shrink embedded radar height on mobile (220px) and tune dvh calculations for safe-area insets

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-08-17 09:44:33 -04:00
Claude 4d92739df4 Fix alert dedup across reloads, add radar fullscreen, fix swipe conflicts
- Persist alertIdsSeen to localStorage so already-seen alerts don't
  re-notify every time the PWA is opened; cap stored IDs at 200 entries
- Use serviceWorker.showNotification() for alert notifications so they
  work when the app is backgrounded, with fallback to new Notification()
- Add ⛶ fullscreen button to radar embed; uses Fullscreen API and
  resizes the MapLibre canvas after toggle
- Fix swipe-to-change-tab: block gesture when touch starts on a map,
  hourly scroll row, or radar timeline; also require the gesture to be
  more horizontal than vertical (dx > dy*1.5) to avoid conflict with
  vertical scrolling
2026-08-17 01:10:09 +00:00
Nate EmmertandClaude Sonnet 4.6 a25864d9ed Upgrade maps to MapLibre GL JS; compact header; move search to settings
- Replace Leaflet with MapLibre GL JS v4.7.1 across all map instances
- CARTO dark/light and Esri satellite raster basemaps (no API key)
- All overlays (hurricane, wildfire, SPC, wind arrows) ported to GeoJSON sources/layers
- AQI, alert, temp, sun/moon markers via maplibregl.Marker with custom HTML
- Radar animation pre-loads all frames on load for smoother playback
- Compact loc-header: tighter padding and font sizes, all info preserved
- Search bar moved from header to Settings tab under Location section
- Service worker bumped to weather-v7

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-08-14 11:04:32 -04:00
Nate Emmert 1863f6784b Fix XSS, validation, and CSS regressions; refactor proxy retry logic
- Sanitize geocode suggestion rendering to prevent XSS
- Add lat/lon validation and cache eviction to weather proxy endpoints
- Extract shared fetchWithRetry helper, dedupe retry/timeout logic
- Stop leaking upstream error details to clients
- Fix radar provider metadata and drop dead nowcast field
- Fix missing --surface-radius-sm var and duplicate/conflicting CSS rules
2026-06-15 08:51:18 -04:00
Nate Emmert 950e2708ab Enhance mobile UX: learn guide, alerts actions, and shareable weather cards 2026-03-17 14:21:32 -04:00
Nate Emmert 8f9a2d1c02 Unify map tab with feature toggles and shared radar overlay 2026-03-17 12:30:18 -04:00
Nate Emmert 98c45bb26f WIP: Begin unified map refactor - HTML structure, storage, CSS, state updates 2026-03-17 12:25:40 -04:00
Nate Emmert f4505b5650 Increase maps height to match radar and improve wind arrow visibility 2026-03-17 12:04:15 -04:00
Nate Emmert 6c7e2f7235 Increase RainViewer max zoom to 17 for better detail 2026-03-17 12:01:59 -04:00
Nate Emmert 14995987ae Stabilize SW and cache headers to match backup behavior 2026-03-17 11:36:12 -04:00
Nate Emmert b242232e0c Fix geolocation and map rendering 2026-03-16 12:37:33 -04:00
Nate e4c631f9a8 Add lightning strikes and wind overlay toggles to Maps tab 2026-03-16 11:56:03 -04:00
Nate e397f11285 Initial commit 2026-03-16 09:40:48 -04:00