From 8df2a6708058819ba82679b8ac42cc099b8014b0 Mon Sep 17 00:00:00 2001 From: Thomas Kaul <4159106+dtslvr@users.noreply.github.com> Date: Sat, 10 Oct 2026 18:08:13 +0200 Subject: [PATCH] Hide currency on mobile --- .../home-overview/home-overview.component.ts | 10 ++++++---- .../portfolio-performance.component.ts | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/apps/client/src/app/components/home-overview/home-overview.component.ts b/apps/client/src/app/components/home-overview/home-overview.component.ts index 3cecc5e5de..c7b880efce 100644 --- a/apps/client/src/app/components/home-overview/home-overview.component.ts +++ b/apps/client/src/app/components/home-overview/home-overview.component.ts @@ -106,11 +106,13 @@ export class GfHomeOverviewComponent implements OnInit { }); protected readonly unit = computed(() => { - const user = this.user(); + if (!this.showDetails()) { + return '%'; + } - return this.showDetails() - ? (user?.settings?.baseCurrency ?? DEFAULT_CURRENCY) - : '%'; + return this.deviceType() === 'mobile' + ? undefined + : (this.user()?.settings?.baseCurrency ?? DEFAULT_CURRENCY); }); private readonly dataService = inject(DataService); diff --git a/apps/client/src/app/components/portfolio-performance/portfolio-performance.component.ts b/apps/client/src/app/components/portfolio-performance/portfolio-performance.component.ts index aade357b78..9ae445ab52 100644 --- a/apps/client/src/app/components/portfolio-performance/portfolio-performance.component.ts +++ b/apps/client/src/app/components/portfolio-performance/portfolio-performance.component.ts @@ -44,7 +44,7 @@ export class GfPortfolioPerformanceComponent { } }); public readonly showDetails = input(false); - public readonly unit = input.required(); + public readonly unit = input(); private readonly value = viewChild.required>('value');