diff options
author | Chocobozzz <me@florianbigard.com> | 2020-08-12 10:40:04 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-08-14 10:28:30 +0200 |
commit | 66357162f8e1227495f09bd4f68446aad7071c6d (patch) | |
tree | 7d4429506deb512b2fe1d0267f38a28cda20af55 /client/src/app/+video-channels/video-channel-about/video-channel-about.component.ts | |
parent | 8c360747995e17eb5520e22fc3d7bd4c3d26eeee (diff) | |
download | PeerTube-66357162f8e1227495f09bd4f68446aad7071c6d.tar.gz PeerTube-66357162f8e1227495f09bd4f68446aad7071c6d.tar.zst PeerTube-66357162f8e1227495f09bd4f68446aad7071c6d.zip |
Migrate to $localize
* Remove i18n polyfill to translate things in components
* Reduce bundle sizes
* Improve runtime perf
* Reduce a lot the time to make a full client build
* Reduce client build complexity
* We don't need a service to translate things anymore (so we will be able to translate title pages etc)
Unfortunately we may loose some translations in the migration process.
I'll put a message on weblate to notify translators
Diffstat (limited to 'client/src/app/+video-channels/video-channel-about/video-channel-about.component.ts')
-rw-r--r-- | client/src/app/+video-channels/video-channel-about/video-channel-about.component.ts | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/client/src/app/+video-channels/video-channel-about/video-channel-about.component.ts b/client/src/app/+video-channels/video-channel-about/video-channel-about.component.ts index 19e4bc1f4..537c7d08e 100644 --- a/client/src/app/+video-channels/video-channel-about/video-channel-about.component.ts +++ b/client/src/app/+video-channels/video-channel-about/video-channel-about.component.ts | |||
@@ -2,7 +2,6 @@ import { Subscription } from 'rxjs' | |||
2 | import { Component, OnDestroy, OnInit } from '@angular/core' | 2 | import { Component, OnDestroy, OnInit } from '@angular/core' |
3 | import { MarkdownService } from '@app/core' | 3 | import { MarkdownService } from '@app/core' |
4 | import { VideoChannel, VideoChannelService } from '@app/shared/shared-main' | 4 | import { VideoChannel, VideoChannelService } from '@app/shared/shared-main' |
5 | import { I18n } from '@ngx-translate/i18n-polyfill' | ||
6 | 5 | ||
7 | @Component({ | 6 | @Component({ |
8 | selector: 'my-video-channel-about', | 7 | selector: 'my-video-channel-about', |
@@ -17,7 +16,6 @@ export class VideoChannelAboutComponent implements OnInit, OnDestroy { | |||
17 | private videoChannelSub: Subscription | 16 | private videoChannelSub: Subscription |
18 | 17 | ||
19 | constructor ( | 18 | constructor ( |
20 | private i18n: I18n, | ||
21 | private videoChannelService: VideoChannelService, | 19 | private videoChannelService: VideoChannelService, |
22 | private markdownService: MarkdownService | 20 | private markdownService: MarkdownService |
23 | ) { } | 21 | ) { } |
@@ -40,6 +38,6 @@ export class VideoChannelAboutComponent implements OnInit, OnDestroy { | |||
40 | getVideoChannelDescription () { | 38 | getVideoChannelDescription () { |
41 | if (this.descriptionHTML) return this.descriptionHTML | 39 | if (this.descriptionHTML) return this.descriptionHTML |
42 | 40 | ||
43 | return this.i18n('No description') | 41 | return $localize`No description` |
44 | } | 42 | } |
45 | } | 43 | } |