From 0455687e9f43e3de2eadd16b081f526d7e295637 Mon Sep 17 00:00:00 2001 From: nbintertech Date: Fri, 22 Mar 2024 06:36:20 -0500 Subject: [PATCH] Adapt messaging for carryover, leave out results --- src/components/YearRecap.tsx | 32 +++++++++++++++++++++----------- 1 file changed, 21 insertions(+), 11 deletions(-) diff --git a/src/components/YearRecap.tsx b/src/components/YearRecap.tsx index f43ce48..b807e80 100644 --- a/src/components/YearRecap.tsx +++ b/src/components/YearRecap.tsx @@ -103,7 +103,6 @@ export class YearRecap extends React.Component { let mutableStats: TrackedStats = { ...initialCurrentYearStats }; let mutableCapitalFundingState: CapitalFundingState = { ...this.props.capitalFundingState }; let recapResults: YearRecapResults = this.buildRecapCardsAndResults(this.props, initialCurrentYearStats, mutableStats, mutableCapitalFundingState); - const gameSettings: GameSettings = JSON.parse(localStorage.getItem('gameSettings')); const noDecimalsFormatter = Intl.NumberFormat('en-US', { minimumFractionDigits: 0, maximumFractionDigits: 0, @@ -176,20 +175,31 @@ export class YearRecap extends React.Component { } /> - {gameSettings.allowBudgetCarryover === 'yes' ? + {this.props.allowBudgetCarryover === 'yes' ? - - This will be added to your budget for the next period, as well as the{' '} - ${unspentBudgetFormatted} of your budget - that was not yet spent. - - } - /> + + {this.props.costSavingsCarryoverYears == 'oneYear' && + + You will receive half the energy cost savings from any implemented Energy Efficiency projects, as well as + all cost savings from any implemented renewable projects. + + } + /> + } + {this.props.costSavingsCarryoverYears == 'never' && + + You will receive cost savings from any implemented renewable projects + + } + /> + } :