spellslots-modal.component.html 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. <div class="dimensions">
  2. @if (!isMonk) {
  3. <div class="title">{{ "magic.spellslots" | translate }}</div>
  4. <div class="content">{{ "magic.description" | translate }}</div>
  5. <mat-slide-toggle
  6. class="t-1"
  7. [checked]="showSpellslots"
  8. (change)="onSpellslotsSwitchChanged($event)"
  9. >
  10. {{ "magic.showSlots" | translate }}
  11. </mat-slide-toggle>
  12. <!-- Zauberplätze in der Übersicht anzeigen -->
  13. @if (showSpellslots) {
  14. <div class="t-1">
  15. @for (level of spellslots; let levelIndex = $index; track level) {
  16. <div class="t-05">
  17. {{ "general.level" | translate }} {{ levelIndex + 1 }}
  18. <select
  19. [(ngModel)]="spellslots[levelIndex].totalSlots"
  20. style="padding-left: 0.5rem"
  21. >
  22. @for (number of [1, 2, 3, 4]; track number) {
  23. <option [value]="number">
  24. {{ number }}
  25. </option>
  26. }
  27. </select>
  28. <icon-button
  29. style="display: inline; margin-left: 0.25rem"
  30. [icon]="'delete'"
  31. (click)="removeSpellLevel(levelIndex)"
  32. ></icon-button>
  33. </div>
  34. }
  35. </div>
  36. @if (spellslots.length < 9) {
  37. <icon-button [icon]="'add'" (click)="addSpellLevel()"></icon-button>
  38. }
  39. }
  40. } @else {
  41. <div class="title">{{ "magic.ki" | translate }}</div>
  42. <div class="content">{{ "magic.descriptioni" | translate }}</div>
  43. <mat-slide-toggle
  44. [checked]="kiPoints.showKiPoints"
  45. (change)="onKiPointsSwitchChanged($event)"
  46. >
  47. {{ "magic.showKi" | translate }}
  48. </mat-slide-toggle>
  49. @if (kiPoints.showKiPoints) {
  50. <div class="t-1">
  51. {{ "magic.availableKi" | translate }}
  52. <div class="t-05">
  53. <mat-form-field appearance="outline">
  54. <mat-select [(ngModel)]="kiPoints.totalPoints">
  55. @for (number of kiNumbersArray; track number) {
  56. <mat-option [value]="number">{{ number }}</mat-option>
  57. }
  58. </mat-select>
  59. </mat-form-field>
  60. </div>
  61. </div>
  62. }
  63. }
  64. <div class="horizontal-buttons">
  65. <ui-button
  66. [color]="'green'"
  67. [type]="'confirm'"
  68. style="width: 45%"
  69. (click)="update()"
  70. >
  71. </ui-button>
  72. <ui-button
  73. [color]="'red'"
  74. [type]="'cancel'"
  75. style="width: 45%"
  76. (click)="cancel()"
  77. >
  78. </ui-button>
  79. </div>
  80. </div>