aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/shared
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app/shared')
-rw-r--r--client/src/app/shared/buttons/delete-button.component.html2
-rw-r--r--client/src/app/shared/buttons/delete-button.component.ts7
-rw-r--r--client/src/app/shared/buttons/edit-button.component.html2
3 files changed, 9 insertions, 2 deletions
diff --git a/client/src/app/shared/buttons/delete-button.component.html b/client/src/app/shared/buttons/delete-button.component.html
index 792490219..6c55d8104 100644
--- a/client/src/app/shared/buttons/delete-button.component.html
+++ b/client/src/app/shared/buttons/delete-button.component.html
@@ -1,4 +1,4 @@
1<span class="action-button action-button-delete" [title]="label" role="button"> 1<span class="action-button action-button-delete" [title]="getTitle()" role="button">
2 <span class="icon icon-delete-grey"></span> 2 <span class="icon icon-delete-grey"></span>
3 3
4 <span class="button-label" *ngIf="label">{{ label }}</span> 4 <span class="button-label" *ngIf="label">{{ label }}</span>
diff --git a/client/src/app/shared/buttons/delete-button.component.ts b/client/src/app/shared/buttons/delete-button.component.ts
index cd2bcccdf..8e285d982 100644
--- a/client/src/app/shared/buttons/delete-button.component.ts
+++ b/client/src/app/shared/buttons/delete-button.component.ts
@@ -1,4 +1,5 @@
1import { Component, Input } from '@angular/core' 1import { Component, Input } from '@angular/core'
2import { I18n } from '@ngx-translate/i18n-polyfill'
2 3
3@Component({ 4@Component({
4 selector: 'my-delete-button', 5 selector: 'my-delete-button',
@@ -8,4 +9,10 @@ import { Component, Input } from '@angular/core'
8 9
9export class DeleteButtonComponent { 10export class DeleteButtonComponent {
10 @Input() label: string 11 @Input() label: string
12
13 constructor (private i18n: I18n) { }
14
15 getTitle () {
16 return this.label || this.i18n('Delete')
17 }
11} 18}
diff --git a/client/src/app/shared/buttons/edit-button.component.html b/client/src/app/shared/buttons/edit-button.component.html
index 7efc54ce7..cecb780f3 100644
--- a/client/src/app/shared/buttons/edit-button.component.html
+++ b/client/src/app/shared/buttons/edit-button.component.html
@@ -1,4 +1,4 @@
1<a class="action-button action-button-edit" [routerLink]="routerLink" title="Edit"> 1<a class="action-button action-button-edit" [routerLink]="routerLink" i18n-title title="Edit">
2 <span class="icon icon-edit"></span> 2 <span class="icon icon-edit"></span>
3 3
4 <span class="button-label" *ngIf="label">{{ label }}</span> 4 <span class="button-label" *ngIf="label">{{ label }}</span>