From 826c488c9dd5562c19837d7dbc4b1dbc2b41c566 Mon Sep 17 00:00:00 2001 From: Thomas <4159106+dtslvr@users.noreply.github.com> Date: Mon, 22 Aug 2022 18:06:59 +0200 Subject: [PATCH] Improve i18n --- .../investment-chart/investment-chart.component.ts | 2 +- .../portfolio/allocations/allocations-page.component.ts | 4 ++-- .../pages/portfolio/analysis/analysis-page.component.ts | 4 ++-- .../src/app/pages/portfolio/analysis/analysis-page.html | 4 ++-- apps/client/src/locales/messages.de.xlf | 8 ++++++++ apps/client/src/locales/messages.xlf | 7 +++++++ .../lib/fire-calculator/fire-calculator.component.html | 5 +++-- .../src/lib/fire-calculator/fire-calculator.component.ts | 6 +++--- 8 files changed, 28 insertions(+), 12 deletions(-) diff --git a/apps/client/src/app/components/investment-chart/investment-chart.component.ts b/apps/client/src/app/components/investment-chart/investment-chart.component.ts index 3aa112c7d..2c09f1e2d 100644 --- a/apps/client/src/app/components/investment-chart/investment-chart.component.ts +++ b/apps/client/src/app/components/investment-chart/investment-chart.component.ts @@ -122,7 +122,7 @@ export class InvestmentChartComponent implements OnChanges, OnDestroy { data: this.investments.map((position) => { return position.investment; }), - label: 'Investment', + label: $localize`Investment`, segment: { borderColor: (context: unknown) => this.isInFuture( diff --git a/apps/client/src/app/pages/portfolio/allocations/allocations-page.component.ts b/apps/client/src/app/pages/portfolio/allocations/allocations-page.component.ts index 9c60b4e13..d230331e9 100644 --- a/apps/client/src/app/pages/portfolio/allocations/allocations-page.component.ts +++ b/apps/client/src/app/pages/portfolio/allocations/allocations-page.component.ts @@ -54,8 +54,8 @@ export class AllocationsPageComponent implements OnDestroy, OnInit { }; public period = 'current'; public periodOptions: ToggleOption[] = [ - { label: 'Initial', value: 'original' }, - { label: 'Current', value: 'current' } + { label: $localize`Initial`, value: 'original' }, + { label: $localize`Current`, value: 'current' } ]; public placeholder = ''; public portfolioDetails: PortfolioDetails; diff --git a/apps/client/src/app/pages/portfolio/analysis/analysis-page.component.ts b/apps/client/src/app/pages/portfolio/analysis/analysis-page.component.ts index 1f52c8c84..36bab3523 100644 --- a/apps/client/src/app/pages/portfolio/analysis/analysis-page.component.ts +++ b/apps/client/src/app/pages/portfolio/analysis/analysis-page.component.ts @@ -26,8 +26,8 @@ export class AnalysisPageComponent implements OnDestroy, OnInit { public investmentsByMonth: InvestmentItem[]; public mode: GroupBy; public modeOptions: ToggleOption[] = [ - { label: 'Monthly', value: 'month' }, - { label: 'Accumulating', value: undefined } + { label: $localize`Monthly`, value: 'month' }, + { label: $localize`Accumulating`, value: undefined } ]; public top3: Position[]; public user: User; diff --git a/apps/client/src/app/pages/portfolio/analysis/analysis-page.html b/apps/client/src/app/pages/portfolio/analysis/analysis-page.html index 159cd5678..cad0f1179 100644 --- a/apps/client/src/app/pages/portfolio/analysis/analysis-page.html +++ b/apps/client/src/app/pages/portfolio/analysis/analysis-page.html @@ -52,7 +52,7 @@ Top 3Top @@ -88,7 +88,7 @@ Bottom 3Bottom diff --git a/apps/client/src/locales/messages.de.xlf b/apps/client/src/locales/messages.de.xlf index 7d4e1983c..bf7e16b73 100644 --- a/apps/client/src/locales/messages.de.xlf +++ b/apps/client/src/locales/messages.de.xlf @@ -2493,6 +2493,14 @@ 171 + + Projected Total Amount + Geschätzter Gesamtbetrag + + libs/ui/src/lib/fire-calculator/fire-calculator.component.html + 44 + + diff --git a/apps/client/src/locales/messages.xlf b/apps/client/src/locales/messages.xlf index 5aee9c4e6..cf977c765 100644 --- a/apps/client/src/locales/messages.xlf +++ b/apps/client/src/locales/messages.xlf @@ -2227,6 +2227,13 @@ 145 + + Projected Total Amount + + libs/ui/src/lib/fire-calculator/fire-calculator.component.html + 44 + + \ No newline at end of file diff --git a/libs/ui/src/lib/fire-calculator/fire-calculator.component.html b/libs/ui/src/lib/fire-calculator/fire-calculator.component.html index f992a9299..499f437e1 100644 --- a/libs/ui/src/lib/fire-calculator/fire-calculator.component.html +++ b/libs/ui/src/lib/fire-calculator/fire-calculator.component.html @@ -35,13 +35,14 @@ + >Projected Total Amount
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 5bcd4a98b..b437f6b61 100644 --- a/libs/ui/src/lib/fire-calculator/fire-calculator.component.ts +++ b/libs/ui/src/lib/fire-calculator/fire-calculator.component.ts @@ -273,7 +273,7 @@ export class FireCalculatorComponent const datasetDeposit = { backgroundColor: `rgb(${primaryColorRgb.r}, ${primaryColorRgb.g}, ${primaryColorRgb.b})`, data: [], - label: 'Deposit' + label: $localize`Deposit` }; const datasetInterest = { @@ -283,7 +283,7 @@ export class FireCalculatorComponent .lighten(0.5) .hex(), data: [], - label: 'Interest' + label: $localize`Interest` }; const datasetSavings = { @@ -293,7 +293,7 @@ export class FireCalculatorComponent .lighten(0.25) .hex(), data: [], - label: 'Savings' + label: $localize`Savings` }; for (let period = 1; period <= t; period++) {