From 4d98df43d7e5ea1c2db4b25521f6bbaf60a0e189 Mon Sep 17 00:00:00 2001 From: fraxle Date: Fri, 26 Jun 2026 12:46:54 +0100 Subject: [PATCH] 3.0.3.1 Added air temps to day tabs. Changed cabin sensitivity. --- assets/js/components/DayTabs.js | 23 +++++++++++++++++------ assets/js/compute.js | 2 +- data/tracking.json | 8 ++++---- 3 files changed, 22 insertions(+), 11 deletions(-) diff --git a/assets/js/components/DayTabs.js b/assets/js/components/DayTabs.js index 61b2e0f..f4cccc7 100644 --- a/assets/js/components/DayTabs.js +++ b/assets/js/components/DayTabs.js @@ -313,6 +313,9 @@ export function DayTabs({ const utcipVals = d.rows.map(r => r.utciAdj).filter(v => isFinite(v)); const dayHi = utcipVals.length ? Math.round(Math.max(...utcipVals)) : null; const dayLo = utcipVals.length ? Math.round(Math.min(...utcipVals)) : null; + const airVals = d.rows.map(r => r.Ta).filter(v => isFinite(v)); + const airHi = airVals.length ? Math.round(Math.max(...airVals)) : null; + const airLo = airVals.length ? Math.round(Math.min(...airVals)) : null; // Day-tab weather icon - use core daylight rows (elev > 10°) where // available, falling back to any above-horizon rows, then all rows. @@ -399,18 +402,26 @@ export function DayTabs({ ${dayHi !== null && html` - ${dayHi}° - / - ${dayLo}° + + ${dayHi}° + ${airHi !== null && html`${airHi}°`} + + + + ${dayLo}° + ${airLo !== null && html`${airLo}°`} + `} `; })} diff --git a/assets/js/compute.js b/assets/js/compute.js index 8178356..2ad3bc4 100644 --- a/assets/js/compute.js +++ b/assets/js/compute.js @@ -521,7 +521,7 @@ export function computeGlanceSummary(todayRows, profile, variant, skinType, cols icon: '🌡', label: 'Peak cabin temp', value: peakCabin ? `${Math.round(peakCabin.vehicleT)}° at ${hhmm(peakCabin.iso)}` : '-', - alert: !!(peakCabin && peakCabin.vehicleT >= 35), + alert: !!(peakCabin && peakCabin.vehicleT > 31.5), }, { icon: '🧒', label: 'Children/pets in car', diff --git a/data/tracking.json b/data/tracking.json index 5a9efbb..a6fcb4b 100644 --- a/data/tracking.json +++ b/data/tracking.json @@ -98,14 +98,14 @@ "profiles": [] }, "2026-06-26": { - "visits": 7, + "visits": 13, "profiles": { "showall": 10, "custom": 8, - "vehicle": 3, + "vehicle": 14, "alltemps": 1, - "home": 1, - "basic": 3, + "home": 23, + "basic": 16, "farming": 2 } }