1.5.5 - Fix concrete values

This commit is contained in:
fraxle
2026-05-18 21:59:29 +01:00
parent bd89d07dcb
commit 20fc105207
+6 -1
View File
@@ -55,7 +55,12 @@ export function buildHourlyRows({ forecast, airQuality, location, vehicleType, v
const soilT0 = h.soil_temperature_0cm ? h.soil_temperature_0cm[i] : null; const soilT0 = h.soil_temperature_0cm ? h.soil_temperature_0cm[i] : null;
const soilT6 = h.soil_temperature_6cm ? h.soil_temperature_6cm[i] : null; const soilT6 = h.soil_temperature_6cm ? h.soil_temperature_6cm[i] : null;
const soilM = h.soil_moisture_0_to_1cm ? h.soil_moisture_0_to_1cm[i] : null; const soilM = h.soil_moisture_0_to_1cm ? h.soil_moisture_0_to_1cm[i] : null;
const concreteT = calcConcreteTemp(Ta, glob, va); // Scale radiation by cloud cover before passing to concrete calc.
// shortwave_radiation and cloud_cover are separate forecast fields that
// don't always agree — this prevents hot concrete values on cloudy days.
// 100% cloud -> 85% reduction, 0% cloud -> full radiation.
const effectiveRad = glob * (1 - (cc / 100) * 0.85);
const concreteT = calcConcreteTemp(Ta, effectiveRad, va);
// iso is a local wall-clock string e.g. "2026-05-13T14:00" (no Z). // iso is a local wall-clock string e.g. "2026-05-13T14:00" (no Z).
// For display we slice the string directly — no Date object needed. // For display we slice the string directly — no Date object needed.
// For solarElevationDeg (which uses .getUTC* internally) we need the // For solarElevationDeg (which uses .getUTC* internally) we need the