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