| 12345678910111213141516171819202122 |
- <button
- [type]="type()"
- [class]="classes()"
- [disabled]="disabled() || loading()"
- [attr.aria-busy]="loading() || null"
- [attr.aria-label]="ariaLabel() || null"
- >
- @if (loading()) {
- <i class="fa-solid fa-spinner animate-spin" aria-hidden="true"></i>
- @if (loadingText()) {
- <span>{{ loadingText() }}</span>
- }
- } @else {
- @if (icon()) {
- <i [class]="icon()" aria-hidden="true"></i>
- }
- <ng-content />
- @if (iconRight()) {
- <i [class]="iconRight()" aria-hidden="true"></i>
- }
- }
- </button>
|