Merge pull request #4047 from dpalou/MOBILE-4550

Mobile 4550
main
Pau Ferrer Ocaña 2024-05-15 13:32:18 +02:00 committed by GitHub
commit b83f900690
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 12 additions and 10 deletions

View File

@ -49,7 +49,7 @@ export class AddonModQuizAttemptInfoComponent implements OnChanges {
if (changes.additionalData) {
this.additionalData?.forEach((data) => {
// Remove help links from additional data.
data.content = CoreDomUtils.removeElementFromHtml(data.content, '.helptooltip');
data.content = CoreDomUtils.removeElementFromHtml(data.content, '.helptooltip, [data-toggle="popover"]');
});
}

View File

@ -10,6 +10,9 @@
.addon-mod_quiz-grade-result {
margin-top: var(--mdl-spacing-2);
ion-label {
@include margin-horizontal(0px, 0px);
}
.addon-mod_quiz-grade-overridden-notice {
margin-top: var(--mdl-spacing-2);

View File

@ -30,7 +30,6 @@ import {
import { CoreQuestionDelegate } from '@features/question/services/question-delegate';
import { CoreSites, CoreSitesCommonWSOptions, CoreSitesReadingStrategy } from '@services/sites';
import { CoreDomUtils } from '@services/utils/dom';
import { CoreTextUtils } from '@services/utils/text';
import { CoreTimeUtils } from '@services/utils/time';
import { CoreUtils } from '@services/utils/utils';
import { CoreStatusWithWarningsWSResponse, CoreWSExternalFile, CoreWSExternalWarning } from '@services/ws';
@ -96,7 +95,7 @@ export class AddonModQuizProvider {
return Translate.instant('addon.mod_quiz.notyetgraded');
}
return CoreUtils.formatFloat(CoreTextUtils.roundToDecimals(grade, decimals));
return CoreUtils.formatFloat(grade.toFixed(decimals ?? 2));
}
/**

View File

@ -33,8 +33,8 @@ Feature: View list of attempts in the app
Given I entered the quiz activity "Quiz 1" on course "Course 1" as "student1" in the app
Then I should find "In progress" within "Attempt 2" "ion-item" in the app
And I should find "Finished" within "Attempt 1" "ion-item" in the app
And I should find "100 / 100" within "Attempt 1" "ion-item" in the app
But I should not find "100" within "Attempt 2" "ion-item" in the app
And I should find "100.00 / 100.00" within "Attempt 1" "ion-item" in the app
But I should not find "100.00" within "Attempt 2" "ion-item" in the app
And I should not find "Started" within "Your attempts" "ion-card" in the app
And I should not find "Completed" within "Your attempts" "ion-card" in the app
And I should not find "Marks" within "Your attempts" "ion-card" in the app
@ -43,7 +43,7 @@ Feature: View list of attempts in the app
When I press "Attempt 1" in the app
Then I should find "Started" within "Your attempts" "ion-card" in the app
And I should find "Completed" in the app
And I should find "1/1" within "Marks" "ion-item" in the app
And I should find "1.00/1.00" within "Marks" "ion-item" in the app
And I should be able to press "Review" in the app
@lms_from4.2
@ -51,7 +51,7 @@ Feature: View list of attempts in the app
Given the attempt at "Quiz 1" by "student1" was never submitted
And I entered the quiz activity "Quiz 1" on course "Course 1" as "student1" in the app
Then I should find "Never submitted" within "Attempt 2" "ion-item" in the app
But I should not find "100" within "Attempt 2" "ion-item" in the app
But I should not find "100.00" within "Attempt 2" "ion-item" in the app
When I press "Attempt 2" in the app
Then I should find "Started" within "Your attempts" "ion-card" in the app

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 37 KiB

View File

@ -38,10 +38,10 @@
.specificfeedback, .rightanswer, .im-feedback, .feedback, .generalfeedback {
margin: 0 0 .5em;
}
p {
--color: var(--core-question-feedback-color);
p {
--color: var(--core-question-feedback-color);
}
}
.correctness {