From 0975cd5cf260bd06c797ac7582675ac624a47ebc Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 5 Jun 2018 16:31:52 +0200 Subject: Translate tab heads --- .../edit-custom-config.component.html | 6 ++-- client/src/app/+admin/follows/follows.component.ts | 38 +++++++++++++--------- 2 files changed, 25 insertions(+), 19 deletions(-) (limited to 'client/src/app/+admin') diff --git a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html index a0bd01e5e..4a6c631fb 100644 --- a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html +++ b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html @@ -2,7 +2,7 @@ - +
Instance
@@ -133,7 +133,7 @@
- +
Twitter
@@ -167,7 +167,7 @@ Check this checkbox, save the configuration and test with a video URL of your in
- +
Transcoding
diff --git a/client/src/app/+admin/follows/follows.component.ts b/client/src/app/+admin/follows/follows.component.ts index f29ad384f..f7af9826c 100644 --- a/client/src/app/+admin/follows/follows.component.ts +++ b/client/src/app/+admin/follows/follows.component.ts @@ -1,6 +1,7 @@ import { AfterViewInit, Component, OnInit, ViewChild } from '@angular/core' import { NavigationEnd, Router } from '@angular/router' import { TabsetComponent } from 'ngx-bootstrap/tabs' +import { I18n } from '@ngx-translate/i18n-polyfill' @Component({ templateUrl: './follows.component.html', @@ -9,22 +10,27 @@ import { TabsetComponent } from 'ngx-bootstrap/tabs' export class FollowsComponent implements OnInit, AfterViewInit { @ViewChild('followsMenuTabs') followsMenuTabs: TabsetComponent - links = [ - { - path: 'following-list', - title: 'Following' - }, - { - path: 'following-add', - title: 'Follow' - }, - { - path: 'followers-list', - title: 'Followers' - } - ] - - constructor (private router: Router) {} + links: { path: string, title: string }[] = [] + + constructor ( + private i18n: I18n, + private router: Router + ) { + this.links = [ + { + path: 'following-list', + title: this.i18n('Following') + }, + { + path: 'following-add', + title: this.i18n('Follow') + }, + { + path: 'followers-list', + title: this.i18n('Followers') + } + ] + } ngOnInit () { this.router.events.subscribe( -- cgit v1.2.3