From 65fbf883c0fb41f9fa9bbfbf60d48c059bfa5ce8 Mon Sep 17 00:00:00 2001 From: Thomas Kaul <4159106+dtslvr@users.noreply.github.com> Date: Sat, 7 Mar 2026 17:42:38 +0100 Subject: [PATCH] Refactoring --- .../src/lib/fire-calculator/fire-calculator.component.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/libs/ui/src/lib/fire-calculator/fire-calculator.component.ts b/libs/ui/src/lib/fire-calculator/fire-calculator.component.ts index 8a8e0a4ec..7a62564c6 100644 --- a/libs/ui/src/lib/fire-calculator/fire-calculator.component.ts +++ b/libs/ui/src/lib/fire-calculator/fire-calculator.component.ts @@ -97,25 +97,30 @@ export class GfFireCalculatorComponent implements OnChanges, OnDestroy { projectedTotalAmount: new FormControl(null), retirementDate: new FormControl(null) }); + public chart: Chart<'bar'>; public isLoading = true; public minDate = addDays(new Date(), 1); public periodsToRetire = 0; protected readonly annualInterestRateChanged = output(); + protected readonly calculationCompleted = output(); + protected readonly projectedTotalAmountChanged = output(); protected readonly retirementDateChanged = output(); protected readonly savingsRateChanged = output(); - private readonly chartCanvas = - viewChild.required>('chartCanvas'); private readonly CONTRIBUTION_PERIOD = 12; + private readonly DEFAULT_RETIREMENT_DATE = startOfMonth( addYears(new Date(), 10) ); + private readonly chartCanvas = + viewChild.required>('chartCanvas'); + public constructor( private changeDetectorRef: ChangeDetectorRef, private fireCalculatorService: FireCalculatorService,