aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/shared/shared-main/buttons/button.component.html
blob: 3e558bbb8dd8f809d858f2e8f38620e85c968789 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<span *ngIf="!routerLink" class="action-button" [ngClass]="getClasses()" [ngbTooltip]="title" tabindex="0">
  <ng-container *ngTemplateOutlet="content"></ng-container>
</span>

<a *ngIf="routerLink" class="action-button" [ngClass]="getClasses()" [ngbTooltip]="title" [routerLink]="routerLink">
  <ng-container *ngTemplateOutlet="content"></ng-container>
</a>

<ng-template #content>
  <my-loader size="sm" [loading]="loading"></my-loader>
  <my-global-icon *ngIf="icon && !loading" [iconName]="icon"></my-global-icon>

  <span *ngIf="label" class="button-label">{{ label }}</span>

  <ng-content></ng-content>
</ng-template>