source: src/Clients/Angular/finki-chattery/src/app/shared-app/components/question/question-preview/question-preview.component.html@ 48f727d

dev
Last change on this file since 48f727d was 48f727d, checked in by Стојков Марко <mst@…>, 3 years ago

Answer question

  • Property mode set to 100644
File size: 2.5 KB
Line 
1<div *ngIf="!working">
2 <div class="margin-bottom-xl">
3 <app-preview-question-full [question]="question"></app-preview-question-full>
4 </div>
5
6 <h1 class="mat-headline">{{ 'question-answers' | translate: { answerCount: question.answers.length } }}</h1>
7 <mat-button-toggle-group>
8 <mat-button-toggle>{{ 'answer-sort-oldest' | translate }}</mat-button-toggle>
9 <mat-button-toggle>{{ 'answer-sort-votes' | translate }}</mat-button-toggle>
10 </mat-button-toggle-group>
11
12 <ng-container *ngFor="let answer of question.answers">
13 <mat-card appHoverElevation class="margin-x-md">
14 <mat-card-content>
15 <div fxLayout="row wrap" fxLayoutAlign="space-around none">
16 <app-vote
17 [canSetCorrectAnswer]="canSetCorrectAnswer | async"
18 [voteCount]="answer.votesCount"
19 [correct]="answer.correctAnswer"
20 (voteClicked)="answerVoted($event, answer.uid, question.uid)"
21 (setCorrectAnswer)="setCorrectAnswer(question.uid, answer.uid)"
22 fxFlex="6%"
23 ></app-vote>
24 <div fxFlex="92%">
25 <app-text-editor
26 [text]="answer.text"
27 [configuration]="{
28 menubar: false,
29 plugins: ['autoresize'],
30 toolbar: ''
31 }"
32 [readonly]="true"
33 ></app-text-editor>
34 <div class="align-right">
35 <app-student-card
36 [indexNumber]="answer.student.index"
37 [imageUrl]="answer.student.imageUrl"
38 [uid]="answer.student.uid"
39 [reputation]="answer.student.reputation"
40 [subtitle]="'question-answered-by-subtitle' | translate: { date: answer.createdOn | momentDate: 'LL' }"
41 ></app-student-card>
42 </div>
43
44 <hr />
45 <div *ngFor="let answerResponse of answer.answerResponses">
46 {{ answerResponse.text }}
47 <mat-chip class="cursor">{{ answerResponse.student.index }}</mat-chip> -
48 {{ answerResponse.createdOn | momentDate: 'LL' }}
49 <hr />
50 </div>
51 </div>
52 </div>
53 </mat-card-content>
54 <mat-card-actions>
55 <app-button (action)="openRespondToAnswerDialog(answer.uid)" [buttonType]="ButtonType.Basic">{{
56 'question-preview-respond-to-answer-button' | translate
57 }}</app-button>
58 </mat-card-actions>
59 </mat-card>
60 </ng-container>
61 <app-answer-question></app-answer-question>
62</div>
Note: See TracBrowser for help on using the repository browser.