From 4c294b010d158237b329bcebfa65670b80dc5b6a Mon Sep 17 00:00:00 2001 From: hunicus <93150691+hunicus@users.noreply.github.com> Date: Wed, 15 Mar 2023 06:08:57 -0400 Subject: [PATCH] Make subtitles default to current locale --- .../src/app/components/about/about.component.html | 6 +++--- frontend/src/app/components/about/about.component.ts | 11 ++++++++++- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/frontend/src/app/components/about/about.component.html b/frontend/src/app/components/about/about.component.html index a0ea005dd..6e459cbac 100644 --- a/frontend/src/app/components/about/about.component.html +++ b/frontend/src/app/components/about/about.component.html @@ -14,9 +14,9 @@
diff --git a/frontend/src/app/components/about/about.component.ts b/frontend/src/app/components/about/about.component.ts index 0f71645d6..4bf70e435 100644 --- a/frontend/src/app/components/about/about.component.ts +++ b/frontend/src/app/components/about/about.component.ts @@ -68,7 +68,7 @@ export class AboutComponent implements OnInit { tap(() => this.goToAnchor()) ); } - + ngAfterViewInit() { this.goToAnchor(); } @@ -90,4 +90,13 @@ export class AboutComponent implements OnInit { this.showNavigateToSponsor = true; } } + + showSubtitles(language) { + console.log(this.locale); + if( this.locale.startsWith( language ) ) { + return true; + } else { + return false; + } + } }