diff --git a/CHANGELOG.md b/CHANGELOG.md index f99c393b0a..a5e7a65c69 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Simplified the portfolio summary by hiding the currency on mobile - Improved the language localization for Catalan (`ca`) ### Fixed diff --git a/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.html b/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.html index ea408c17d8..8846c14a7c 100644 --- a/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.html +++ b/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.html @@ -48,7 +48,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.totalBuy" /> @@ -62,7 +62,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.totalSell" /> @@ -79,7 +79,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.totalInvestmentValueWithCurrencyEffect" /> @@ -93,7 +93,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.grossPerformanceWithCurrencyEffect" /> @@ -110,7 +110,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.fees" /> @@ -127,7 +127,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.netPerformanceWithCurrencyEffect" /> @@ -171,7 +171,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.totalAssetsInBaseCurrency" /> @@ -217,7 +217,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="holdingsInBaseCurrency" /> @@ -233,7 +233,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="investmentsInBaseCurrency" /> @@ -248,7 +248,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.emergencyFund?.assets" /> @@ -295,7 +295,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.totalCashInBaseCurrency" /> @@ -311,7 +311,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.cash" /> @@ -326,7 +326,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.emergencyFund?.cash" /> @@ -356,7 +356,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.excludedAccountsAndActivities" /> @@ -379,7 +379,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.liabilitiesInBaseCurrency" /> @@ -396,7 +396,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.totalValueInBaseCurrency" /> @@ -469,7 +469,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.emergencyFund?.total" /> @@ -483,7 +483,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.interestInBaseCurrency" /> @@ -497,7 +497,7 @@ [isLoading]="isLoading" [locale]="locale" [precision]="precision" - [unit]="baseCurrency" + [unit]="displayedCurrency" [value]="summary?.dividendInBaseCurrency" /> diff --git a/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.ts b/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.ts index ea68713189..dec65ddad9 100644 --- a/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.ts +++ b/apps/client/src/app/components/portfolio-summary/portfolio-summary.component.ts @@ -79,6 +79,10 @@ export class GfPortfolioSummaryComponent implements OnChanges { : 0; } + protected get displayedCurrency() { + return this.deviceType === 'mobile' ? undefined : this.baseCurrency; + } + protected get emergencyFundPercentage() { return this.summary?.totalValueInBaseCurrency ? (this.summary.emergencyFund?.total || 0) /