diff --git a/src/components/MobileOffsetOrder.tsx b/src/components/MobileOffsetOrder.tsx index 00e922c..b7f4e67 100644 --- a/src/components/MobileOffsetOrder.tsx +++ b/src/components/MobileOffsetOrder.tsx @@ -100,9 +100,9 @@ export function MobileOffsetOrder({ tons, monetaryAmount, onBack }: Props) { useEffect(() => { setFormData(prev => ({ ...prev, - message: `I would like to offset ${formatTons(actualOffsetTons)} tons of CO2 (${offsetPercentage}% of ${formatTons(tons)} tons) from my yacht's emissions.` + message: `I would like to offset ${formatTons(actualOffsetTons)} tons of CO2 (${offsetPercentage}% of ${formatTons(baseTons)} tons) from my yacht's emissions.` })); - }, [offsetPercentage, actualOffsetTons, tons]); + }, [offsetPercentage, actualOffsetTons, baseTons]); // Save offset percentage and portfolio ID to localStorage useEffect(() => { @@ -385,7 +385,7 @@ export function MobileOffsetOrder({ tons, monetaryAmount, onBack }: Props) {
- {offsetPercentage}% of {formatTons(tons)} tons total emissions + {offsetPercentage}% of {formatTons(baseTons)} tons total emissions
diff --git a/src/components/OffsetOrder.tsx b/src/components/OffsetOrder.tsx index b2e9670..f1fa364 100644 --- a/src/components/OffsetOrder.tsx +++ b/src/components/OffsetOrder.tsx @@ -226,7 +226,7 @@ export function OffsetOrder({ tons, monetaryAmount, onBack, calculatorType }: Pr Offset Your Impact

- You're about to offset {formatTons(tons)} tons of CO₂ + You're about to offset {formatTons(actualOffsetTons)} tons of CO₂