From 0975cd5cf260bd06c797ac7582675ac624a47ebc Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 5 Jun 2018 16:31:52 +0200 Subject: [PATCH] Translate tab heads --- .../edit-custom-config.component.html | 6 +- .../app/+admin/follows/follows.component.ts | 38 +++--- .../forms/markdown-textarea.component.html | 6 +- client/src/app/shared/misc/help.component.ts | 17 ++- client/src/app/signup/signup.component.ts | 1 - .../shared/video-edit.component.html | 4 +- client/src/locale/source/messages_en_US.xml | 107 +++++++++++++++ client/src/locale/target/messages_fr.xml | 124 +++++++++++++++++- 8 files changed, 265 insertions(+), 38 deletions(-) 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( diff --git a/client/src/app/shared/forms/markdown-textarea.component.html b/client/src/app/shared/forms/markdown-textarea.component.html index 6effda5b8..802562dd7 100644 --- a/client/src/app/shared/forms/markdown-textarea.component.html +++ b/client/src/app/shared/forms/markdown-textarea.component.html @@ -1,8 +1,8 @@
diff --git a/client/src/app/shared/misc/help.component.ts b/client/src/app/shared/misc/help.component.ts index 0373a63de..e7af61b4a 100644 --- a/client/src/app/shared/misc/help.component.ts +++ b/client/src/app/shared/misc/help.component.ts @@ -1,5 +1,6 @@ import { Component, Input, OnChanges, OnInit } from '@angular/core' import { MarkdownService } from '@app/videos/shared' +import { I18n } from '@ngx-translate/i18n-polyfill' @Component({ selector: 'my-help', @@ -16,6 +17,8 @@ export class HelpComponent implements OnInit, OnChanges { mainHtml = '' + constructor (private i18n: I18n) { } + ngOnInit () { this.init() } @@ -42,18 +45,18 @@ export class HelpComponent implements OnInit, OnChanges { } private formatMarkdownSupport (rules: string[]) { - return 'Markdown ' + - 'compatible that supports:' + + // tslint:disable:max-line-length + return this.i18n('Markdown compatible that supports:') + this.createMarkdownList(rules) } private createMarkdownList (rules: string[]) { const rulesToText = { - 'emphasis': 'Emphasis', - 'link': 'Links', - 'newline': 'New lines', - 'list': 'Lists', - 'image': 'Images' + 'emphasis': this.i18n('Emphasis'), + 'link': this.i18n('Links'), + 'newline': this.i18n('New lines'), + 'list': this.i18n('Lists'), + 'image': this.i18n('Images') } const bullets = rules.map(r => rulesToText[r]) diff --git a/client/src/app/signup/signup.component.ts b/client/src/app/signup/signup.component.ts index 55ebb573e..53d144572 100644 --- a/client/src/app/signup/signup.component.ts +++ b/client/src/app/signup/signup.component.ts @@ -75,7 +75,6 @@ export class SignupComponent extends FormReactive implements OnInit { return this.i18n('~ {{minutes}} {minutes, plural, =1 {minute} other {minutes}}', { minutes }) } - private buildQuotaHelpIndication () { if (this.initialUserVideoQuota === -1) return diff --git a/client/src/app/videos/+video-edit/shared/video-edit.component.html b/client/src/app/videos/+video-edit/shared/video-edit.component.html index bd9f69362..c8cd0d679 100644 --- a/client/src/app/videos/+video-edit/shared/video-edit.component.html +++ b/client/src/app/videos/+video-edit/shared/video-edit.component.html @@ -1,7 +1,7 @@
- +
@@ -112,7 +112,7 @@
- +
app/+admin/config/edit-custom-config/edit-custom-config.component.ts 122 + + Basic configuration + + app/+admin/config/edit-custom-config/edit-custom-config.component.ts + 5 + Twitter @@ -709,6 +715,12 @@ Check this checkbox, save the configuration and test with a video URL of your in app/+admin/config/edit-custom-config/edit-custom-config.component.ts 162 + + Services + + app/+admin/config/edit-custom-config/edit-custom-config.component.ts + 136 + Transcoding @@ -789,6 +801,12 @@ Check this checkbox, save the configuration and test with a video URL of your in app/+admin/config/edit-custom-config/edit-custom-config.component.ts 247 + + Advanced configuration + + app/+admin/config/edit-custom-config/edit-custom-config.component.ts + 170 + Update configuration @@ -1440,6 +1458,12 @@ When you will upload a video in this channel, the video support field will be au app/videos/+video-edit/shared/video-edit.component.ts 109 + + Basic info + + app/videos/+video-edit/shared/video-edit.component.ts + 4 + Upload thumbnail @@ -1472,6 +1496,12 @@ When you will upload a video in this channel, the video support field will be au app/videos/+video-edit/shared/video-edit.component.ts 133 + + Advanced settings + + app/videos/+video-edit/shared/video-edit.component.ts + 115 + (extensions: <x id="INTERPOLATION" equiv-text="{{ videoImageExtensions }}"/>, max size: <x id="INTERPOLATION_1" equiv-text="{{ maxVideoImageSize | bytes }}"/>) @@ -2209,6 +2239,27 @@ When you will upload a video in this channel, the video support field will be au 1 + + Following + + src/app/+admin/follows/follows.component.ts + 1 + + + + Follow + + src/app/+admin/follows/follows.component.ts + 1 + + + + Followers + + src/app/+admin/follows/follows.component.ts + 1 + + User <x id="INTERPOLATION" equiv-text="{{username}}"/> created. @@ -2878,6 +2929,48 @@ When you will upload a video in this channel, the video support field will be au 1 + + <x id="START_LINK" ctype="x-a" equiv-text="<a>"/>Markdown<x id="CLOSE_LINK" ctype="x-a" equiv-text="</a>"/> compatible that supports: + + src/app/shared/misc/help.component.ts + 1 + + + + Emphasis + + src/app/shared/misc/help.component.ts + 1 + + + + Links + + src/app/shared/misc/help.component.ts + 1 + + + + New lines + + src/app/shared/misc/help.component.ts + 1 + + + + Lists + + src/app/shared/misc/help.component.ts + 1 + + + + Images + + src/app/shared/misc/help.component.ts + 1 + + Request is too large for the server. Please contact you administrator if you want to increase the limit size. @@ -2913,6 +3006,20 @@ When you will upload a video in this channel, the video support field will be au 1 + + ~ <x id="INTERPOLATION" equiv-text="{{minutes}}"/> <x id="ICU" equiv-text="{minutes, plural, =1 {...} other {...}}"/> + + src/app/signup/signup.component.ts + 1 + + + + {VAR_PLURAL, plural, =1 {minute} other {minutes} } + + src/app/signup/signup.component.ts + 1 + + <x id="INTERPOLATION" equiv-text="{{seconds}}"/> of full HD videos diff --git a/client/src/locale/target/messages_fr.xml b/client/src/locale/target/messages_fr.xml index e3c052446..c095adf0b 100644 --- a/client/src/locale/target/messages_fr.xml +++ b/client/src/locale/target/messages_fr.xml @@ -556,6 +556,13 @@ 122 + + Basic configuration + Configuration basique + + 5 + + Twitter Twitter @@ -595,6 +602,13 @@ Cochez cette case, sauvegardez la configuration et testez avec l'URL d'une vidé 162 + + Services + Services + + 136 + + Transcoding Encodage @@ -700,6 +714,13 @@ Cochez cette case, sauvegardez la configuration et testez avec l'URL d'une vidé 247 + + Advanced configuration + Configuration avancée + + 170 + + Update configuration Mettre à jour la configuration @@ -1336,6 +1357,13 @@ Quand vous mettrez en ligne une vidéo sur cette chaîne, la vidéo affichera au 109 + + Basic info + Informations basiques + + 4 + + Upload thumbnail Mettre en ligne une vignette @@ -1352,18 +1380,25 @@ Quand vous mettrez en ligne une vidéo sur cette chaîne, la vidéo affichera au Support - Supporter + Soutenir 53 Short text to tell people how they can support you (membership platform...). - Courte description des moyens qu'on les utilisateurs de vous aider (financement participatif, etc.). + Courte description des moyens qu'ont les utilisateurs de vous soutenir (financement participatif, etc.). 133 + + Advanced settings + Paramétrage avancé + + 115 + + (extensions: , max size: ) (extensions: , max size: ) @@ -1919,6 +1954,27 @@ Quand vous mettrez en ligne une vidéo sur cette chaîne, la vidéo affichera au 1 + + Following + Abonnements + + 1 + + + + Follow + S'abonner + + 1 + + + + Followers + Abonnés + + 1 + + User created. Utilisateur créé. @@ -2364,14 +2420,14 @@ Quand vous mettrez en ligne une vidéo sur cette chaîne, la vidéo affichera au Support text must be at least 3 characters long. - Le texte de support doit être composé d'au moins 3 caractères. + Le texte de soutien doit être composé d'au moins 3 caractères. 1 Support text cannot be more than 500 characters long. - Le texte du support ne peut pas faire plus de 500 caractères. + Le texte de soutien ne peut pas faire plus de 500 caractères. 1 @@ -2462,14 +2518,14 @@ Quand vous mettrez en ligne une vidéo sur cette chaîne, la vidéo affichera au Video support must be at least 3 characters long. - Le texte de support de la vidéo doit faire au moins 3 caractères. + Le texte de soutien de la vidéo doit faire au moins 3 caractères. 1 Video support cannot be more than 500 characters long. - Le texte de support de la vidéo ne peut pas faire plus de 500 caractères. + Le texte de soutien de la vidéo ne peut pas faire plus de 500 caractères. 1 @@ -2565,6 +2621,48 @@ Quand vous mettrez en ligne une vidéo sur cette chaîne, la vidéo affichera au 1 + + Markdown compatible that supports: + Compatible Markdown supportant : + + 1 + + + + Emphasis + L'emphase + + 1 + + + + Links + Les liens + + 1 + + + + New lines + Les retours à la ligne + + 1 + + + + Lists + Les listes + + 1 + + + + Images + Les images + + 1 + + Request is too large for the server. Please contact you administrator if you want to increase the limit size. La requête est trop volumineuse pour le serveur. Merci de contacter un administrateur afin d'augmenter la taille limite accepté par celui-ci. @@ -2600,6 +2698,20 @@ Quand vous mettrez en ligne une vidéo sur cette chaîne, la vidéo affichera au 1 + + ~ + ~ + + 1 + + + + {VAR_PLURAL, plural, =1 {minute} other {minutes} } + {VAR_PLURAL, plural, =1 {minute} other {minutes} } + + 1 + + of full HD videos de vidéos full HD -- 2.41.0