funky-framadate-front/src/app/shared/components/choice-item/choice-button.component.html

13 lines
521 B
HTML
Raw Normal View History

2021-04-28 14:07:33 +02:00
<button
2021-05-20 12:51:25 +02:00
class="choice-button is-white"
2021-04-28 14:07:33 +02:00
[ngClass]="{ 'is-primary': storageService.choiceHasAnswerOfValue(choice.id, answerEnum[answerKind]) }"
(click)="storageService.toggleAnswer(choice.id, answerEnum[answerKind])"
*ngIf="poll.allowed_answers.indexOf(answerEnum[answerKind]) !== -1"
>
<img class="image is-24x24" src="../../../assets/img/icon_voter_{{ answerKind }}.svg" />
<span class="counter" *ngIf="choice[answerEnum[answerKind]].count * 1 > 0">
{{ choice[answerEnum[answerKind]].count }}
</span>
</button>