Merge pull request #3513 from dpalou/MOBILE-4081

Mobile 4081
main
Alfonso Salces 2022-12-16 15:07:24 +01:00 committed by GitHub
commit 9cb4819874
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 25 additions and 22 deletions

View File

@ -52,7 +52,7 @@
<div *ngIf="question.status || question.readableMark" slot="end"
class="ion-text-wrap ion-margin-horizontal addon-mod_quiz-question-note">
<p *ngIf="question.status" class="block">{{question.status}}</p>
<p *ngIf="question.readableMark">{{ question.readableMark }}</p>
<p *ngIf="question.readableMark" [innerHTML]="question.readableMark"></p>
</div>
</ion-item-divider>
@ -149,19 +149,20 @@
</ion-button>
</ion-card>
<div collapsible-footer appearOnBottom *ngIf="!quizAborted && showSummary && summaryQuestions.length && loaded" slot="fixed"
class="list-item-limited-width">
<ion-button *ngIf="preventSubmitMessages.length" expand="block" class="ion-margin ion-text-wrap" [href]="moduleUrl" core-link
[showBrowserWarning]="false">
{{ 'core.openinbrowser' | translate }}
<ion-icon name="fas-external-link-alt" slot="end" aria-hidden="true"></ion-icon>
</ion-button>
<div collapsible-footer appearOnBottom *ngIf="!quizAborted && showSummary && summaryQuestions.length && loaded" slot="fixed">
<div class="list-item-limited-width">
<ion-button *ngIf="preventSubmitMessages.length" expand="block" class="ion-margin ion-text-wrap" [href]="moduleUrl"
core-link [showBrowserWarning]="false">
{{ 'core.openinbrowser' | translate }}
<ion-icon name="fas-external-link-alt" slot="end" aria-hidden="true"></ion-icon>
</ion-button>
<!-- Button to submit the quiz. -->
<ion-button *ngIf="!attempt!.finishedOffline && !preventSubmitMessages.length" expand="block" class="ion-margin ion-text-wrap"
(click)="finishAttempt(true)">
{{ 'addon.mod_quiz.submitallandfinish' | translate }}
</ion-button>
<!-- Button to submit the quiz. -->
<ion-button *ngIf="!attempt!.finishedOffline && !preventSubmitMessages.length" expand="block"
class="ion-margin ion-text-wrap" (click)="finishAttempt(true)">
{{ 'addon.mod_quiz.submitallandfinish' | translate }}
</ion-button>
</div>
</div>
</core-loading>
</ion-content>

View File

@ -13,15 +13,17 @@ $quiz-timer-iterations: 15 !default;
border-bottom: 1px solid var(--stroke);
}
core-timer .core-timer {
// Make the timer go red when it's reaching 0.
@for $i from 0 through $quiz-timer-iterations {
&.core-timer-timeleft-#{$i} {
background-color: rgba($quiz-timer-warn-color, 1 - ($i / $quiz-timer-iterations)) !important;
core-timer ::ng-deep {
.core-timer {
// Make the timer go red when it's reaching 0.
@for $i from 0 through $quiz-timer-iterations {
&.core-timer-timeleft-#{$i} {
background-color: rgba($quiz-timer-warn-color, 1 - ($i / $quiz-timer-iterations)) !important;
@if $i <= $quiz-timer-iterations / 2 {
label, span, ion-icon {
color: var(--white);
@if $i <= $quiz-timer-iterations / 2 {
label, span, ion-icon {
color: var(--white);
}
}
}
}

View File

@ -92,7 +92,7 @@
<div class="ion-text-wrap ion-margin-horizontal addon-mod_quiz-question-note" slot="end"
*ngIf="question.status || question.readableMark">
<p *ngIf="question.status">{{question.status}}</p>
<p *ngIf="question.readableMark">{{question.readableMark}}</p>
<p *ngIf="question.readableMark" [innerHTML]="question.readableMark"></p>
</div>
</ion-item-divider>