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/shared/shared-main/account/actor-avatar-info.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/shared/shared-main/account/actor-avatar-info.component.ts')
-rw-r--r-- | client/src/app/shared/shared-main/account/actor-avatar-info.component.ts | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/client/src/app/shared/shared-main/account/actor-avatar-info.component.ts b/client/src/app/shared/shared-main/account/actor-avatar-info.component.ts index 1389218cc..3a86e5b21 100644 --- a/client/src/app/shared/shared-main/account/actor-avatar-info.component.ts +++ b/client/src/app/shared/shared-main/account/actor-avatar-info.component.ts | |||
@@ -1,7 +1,6 @@ | |||
1 | import { Component, ElementRef, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core' | 1 | import { Component, ElementRef, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core' |
2 | import { Notifier, ServerService } from '@app/core' | 2 | import { Notifier, ServerService } from '@app/core' |
3 | import { Account, BytesPipe, VideoChannel } from '@app/shared/shared-main' | 3 | import { Account, BytesPipe, VideoChannel } from '@app/shared/shared-main' |
4 | import { I18n } from '@ngx-translate/i18n-polyfill' | ||
5 | import { ServerConfig } from '@shared/models' | 4 | import { ServerConfig } from '@shared/models' |
6 | 5 | ||
7 | @Component({ | 6 | @Component({ |
@@ -23,11 +22,10 @@ export class ActorAvatarInfoComponent implements OnInit { | |||
23 | 22 | ||
24 | constructor ( | 23 | constructor ( |
25 | private serverService: ServerService, | 24 | private serverService: ServerService, |
26 | private notifier: Notifier, | 25 | private notifier: Notifier |
27 | private i18n: I18n | ||
28 | ) { | 26 | ) { |
29 | this.bytesPipe = new BytesPipe() | 27 | this.bytesPipe = new BytesPipe() |
30 | this.maxSizeText = this.i18n('max size') | 28 | this.maxSizeText = $localize`max size` |
31 | } | 29 | } |
32 | 30 | ||
33 | ngOnInit (): void { | 31 | ngOnInit (): void { |