From 581eafbf361e8460d4b97148f876401bea448a68 Mon Sep 17 00:00:00 2001 From: Manohar Gupta Date: Thu, 28 May 2026 15:28:29 +0530 Subject: [PATCH] feat(web): display Wind 8760 profile in generation sheet - Added windProfileAvg to Year level display (similar to solarProfileAvg) - Added windProfileMo to Month level display - Added windProfileDay to Day level display - Added hourProfileW (raw wind profile) to Hour level display - This makes Wind profile display consistent with Solar profile display --- packages/web/components/WorkbookView.tsx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/packages/web/components/WorkbookView.tsx b/packages/web/components/WorkbookView.tsx index 7ec58f3..4fb00f0 100644 --- a/packages/web/components/WorkbookView.tsx +++ b/packages/web/components/WorkbookView.tsx @@ -805,6 +805,7 @@ function HourlyGenerationSheet({ hourly, codYear, solarDCMW, windMW }: { hourly: const loadYr = hasLoad ? computeYearTotalNew(year, hourly_load) : 0; // Solar 8760: average profile value (0-1), DC MW: capacity (placeholder), Solar MW: sum output const solarProfileAvg = hasSolarProfile ? computeYearAvgProfile(year, hourly_solar_profile) : 0; + const windProfileAvg = hasWindProfile ? computeYearAvgProfile(year, hourly_wind_profile) : 0; const fyLabel = getFyLabel(i); return ( @@ -820,7 +821,7 @@ function HourlyGenerationSheet({ hourly, codYear, solarDCMW, windMW }: { hourly: {hasSolar && {solarDCMW || '-'}} {hasSolar && {Math.round(solarYr).toLocaleString()}} {/* Wind 8760, MW, Wind MW */} - {hasWind && -} + {hasWind && {(windProfileAvg * 100).toFixed(1)}%} {hasWind && {windMW || '-'}} {hasWind && {Math.round(windYr).toLocaleString()}} {hasTotalRe && {Math.round(totalReYr).toLocaleString()}} @@ -857,7 +858,7 @@ function HourlyGenerationSheet({ hourly, codYear, solarDCMW, windMW }: { hourly: {hasSolar && {(solarProfileMo * 100).toFixed(1)}%} {hasSolar && {solarDCMW || '-'}} {hasSolar && {Math.round(solarMo).toLocaleString()}} - {hasWind && -} + {hasWind && {(windProfileMo * 100).toFixed(1)}%} {hasWind && {windMW || '-'}} {hasWind && {Math.round(windMo).toLocaleString()}} {hasTotalRe && {Math.round(totalReMo).toLocaleString()}} @@ -891,7 +892,7 @@ function HourlyGenerationSheet({ hourly, codYear, solarDCMW, windMW }: { hourly: {hasSolar && {(solarProfileDay * 100).toFixed(1)}%} {hasSolar && {solarDCMW || '-'}} {hasSolar && {Math.round(solarDy)}} - {hasWind && -} + {hasWind && {(windProfileDay * 100).toFixed(1)}%} {hasWind && {windMW || '-'}} {hasWind && {Math.round(windDy)}} {hasTotalRe && {Math.round(totalReDy)}} @@ -927,7 +928,7 @@ function HourlyGenerationSheet({ hourly, codYear, solarDCMW, windMW }: { hourly: {hasSolar && {solarDCMW || '-'}} {hasSolar && {Math.round(solarHr)}} {/* Wind 8760, MW, Wind MW */} - {hasWind && -} + {hasWind && {(hourProfileW * 100).toFixed(1)}%} {hasWind && {windMW || '-'}} {hasWind && {Math.round(windHr)}} {/* Total RE, Client End, Load */}