aboutsummaryrefslogblamecommitdiffhomepage
path: root/client/src/app/shared/shared-main/buttons/button.component.html
blob: 20c982744a57fbf4ca86cc3887f0218282b5e896 (plain) (tree)
1
2
3
4
5
6
7
8
9
                                                                                           
                                                           
         
 
                                                                                                               



                                                           
                                                                                          
                                                                              
 
                                                             

                           
              
<button *ngIf="!routerLink" class="action-button" [ngClass]="classes" [ngbTooltip]="title">
  <ng-container *ngTemplateOutlet="content"></ng-container>
</button>

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

<ng-template #content>
  <my-loader size="sm" [ngClass]="{ displayed: loading }" [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>