]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/shared/shared-main/buttons/edit-button.component.ts
Migrate to $localize
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-main / buttons / edit-button.component.ts
index d8ae39b84c58c290a206aa7a97bb54bd9a60c6bb..4b76551ca93c84b73aeafdf9669b7713fcd1eb60 100644 (file)
@@ -1,5 +1,4 @@
 import { Component, Input, OnInit } from '@angular/core'
-import { I18n } from '@ngx-translate/i18n-polyfill'
 
 @Component({
   selector: 'my-edit-button',
@@ -12,17 +11,15 @@ export class EditButtonComponent implements OnInit {
   @Input() title: string
   @Input() routerLink: string[] | string = []
 
-  constructor (private i18n: I18n) { }
-
   ngOnInit () {
     // <my-edit-button /> No label
     if (this.label === undefined && !this.title) {
-      this.title = this.i18n('Update')
+      this.title = $localize`Update`
     }
 
     // <my-edit-button label /> Use default label
     if (this.label === '') {
-      this.label = this.i18n('Update')
+      this.label = $localize`Update`
 
       if (!this.title) {
         this.title = this.label