diff --git a/src/addons/messages/tests/behat/snapshots/test-basic-usage-of-messages-in-app-view-recent-conversations-and-contacts_30.png b/src/addons/messages/tests/behat/snapshots/test-basic-usage-of-messages-in-app-view-recent-conversations-and-contacts_30.png index bf3305d8b..418759cbf 100644 Binary files a/src/addons/messages/tests/behat/snapshots/test-basic-usage-of-messages-in-app-view-recent-conversations-and-contacts_30.png and b/src/addons/messages/tests/behat/snapshots/test-basic-usage-of-messages-in-app-view-recent-conversations-and-contacts_30.png differ diff --git a/src/addons/mod/forum/tests/behat/snapshots/test-basic-usage-of-forum-activity-in-app-reply-a-post_14.png b/src/addons/mod/forum/tests/behat/snapshots/test-basic-usage-of-forum-activity-in-app-reply-a-post_14.png index 2ce99523a..58354f3df 100644 Binary files a/src/addons/mod/forum/tests/behat/snapshots/test-basic-usage-of-forum-activity-in-app-reply-a-post_14.png and b/src/addons/mod/forum/tests/behat/snapshots/test-basic-usage-of-forum-activity-in-app-reply-a-post_14.png differ diff --git a/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html b/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html index 08856265c..3af0aef3f 100644 --- a/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html +++ b/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html @@ -15,7 +15,8 @@ + [disabled]="!isReview && isSequential && currentPage !== question.page" (click)="loadPage(question.page, question.slot)" + [detail]="false"> diff --git a/src/addons/mod/quiz/components/navigation-modal/navigation-modal.ts b/src/addons/mod/quiz/components/navigation-modal/navigation-modal.ts index 044d4d0e8..614572a59 100644 --- a/src/addons/mod/quiz/components/navigation-modal/navigation-modal.ts +++ b/src/addons/mod/quiz/components/navigation-modal/navigation-modal.ts @@ -30,6 +30,7 @@ export class AddonModQuizNavigationModalComponent { @Input() summaryShown?: boolean; // Whether summary is currently being shown. @Input() currentPage?: number; // Current page. @Input() isReview?: boolean; // Whether the user is reviewing the attempt. + @Input() isSequential?: boolean; // Whether quiz navigation is sequential. /** * Close modal. diff --git a/src/addons/mod/quiz/pages/player/player.ts b/src/addons/mod/quiz/pages/player/player.ts index 6d4aa1aa1..2fdc9e1b4 100644 --- a/src/addons/mod/quiz/pages/player/player.ts +++ b/src/addons/mod/quiz/pages/player/player.ts @@ -559,8 +559,6 @@ export class AddonModQuizPlayerPage implements OnInit, OnDestroy, CanLeave { return; } - // @todo MOBILE-4350: This is called before getting the attempt data in sequential quizzes as a workaround for a bug - // in the LMS. Once the bug has been fixed, this should be reverted. if (this.isSequential) { await this.logViewPage(page); } @@ -594,7 +592,6 @@ export class AddonModQuizPlayerPage implements OnInit, OnDestroy, CanLeave { // Mark the page as viewed. if (!this.isSequential) { - // @todo MOBILE-4350: Undo workaround. await this.logViewPage(page); } @@ -734,6 +731,7 @@ export class AddonModQuizPlayerPage implements OnInit, OnDestroy, CanLeave { summaryShown: this.showSummary, currentPage: this.attempt?.currentpage, isReview: false, + isSequential: this.isSequential, }, }); diff --git a/src/addons/mod/quiz/pages/review/review.ts b/src/addons/mod/quiz/pages/review/review.ts index d24d5068b..70f512c18 100644 --- a/src/addons/mod/quiz/pages/review/review.ts +++ b/src/addons/mod/quiz/pages/review/review.ts @@ -345,6 +345,7 @@ export class AddonModQuizReviewPage implements OnInit { summaryShown: false, currentPage: this.attempt?.currentpage, isReview: true, + isSequential: this.quiz && AddonModQuiz.isNavigationSequential(this.quiz), }, }); diff --git a/src/addons/mod/quiz/tests/behat/quiz_navigation.feature b/src/addons/mod/quiz/tests/behat/quiz_navigation.feature index 8107f7176..215885128 100644 --- a/src/addons/mod/quiz/tests/behat/quiz_navigation.feature +++ b/src/addons/mod/quiz/tests/behat/quiz_navigation.feature @@ -83,55 +83,58 @@ Feature: Navigate through a quiz in the app And I should find "Text of the first question" in the app And I should find "Text of the second question" in the app - # @todo MOBILE-4350 uncomment and update this test. -# Scenario: Sequential navigation -# Given I entered the quiz activity "Quiz 2" on course "Course 1" as "student1" in the app -# And I press "Attempt quiz now" in the app -# Then I should find "Text of the first question" in the app -# But I should not find "Text of the second question" in the app -# And I should not find "Text of the third question" in the app + Scenario: Sequential navigation + Given I entered the quiz activity "Quiz 2" on course "Course 1" as "student1" in the app + And I press "Attempt quiz now" in the app + Then I should find "Text of the first question" in the app + But I should not find "Text of the second question" in the app + And I should not find "Text of the third question" in the app -# When I press "Open navigation popover" in the app -# Then I should find "Question 1" in the app -# But I should not find "Question 2" in the app -# And I should not find "Question 3" in the app + When I press "Open navigation popover" in the app + Then I should find "Question 1" in the app + And I should find "Question 2" in the app + And I should find "Question 3" in the app + But I should not be able to press "Question 2" in the app + And I should not be able to press "Question 3" in the app -# When I press "Close" in the app -# And I press "Next" in the app -# Then I should find "Text of the second question" in the app -# But I should not find "Text of the first question" in the app -# And I should not find "Text of the third question" in the app -# And I should not find "Previous" in the app + When I press "Close" in the app + And I press "Next" in the app + Then I should find "Text of the second question" in the app + But I should not find "Text of the first question" in the app + And I should not find "Text of the third question" in the app + And I should not find "Previous" in the app -# When I press "Open navigation popover" in the app -# Then I should find "Question 2" in the app -# But I should not find "Question 1" in the app -# And I should not find "Question 3" in the app + When I press "Open navigation popover" in the app + Then I should find "Question 1" in the app + And I should find "Question 2" in the app + And I should find "Question 3" in the app + But I should not be able to press "Question 1" in the app + And I should not be able to press "Question 3" in the app -# When I press "Close" in the app -# And I press "Next" in the app -# Then I should find "Text of the third question" in the app -# But I should not find "Text of the first question" in the app -# And I should not find "Text of the second question" in the app -# And I should not find "Previous" in the app + When I press "Close" in the app + And I press "Next" in the app + Then I should find "Text of the third question" in the app + But I should not find "Text of the first question" in the app + And I should not find "Text of the second question" in the app + And I should not find "Previous" in the app -# When I press "Open navigation popover" in the app -# Then I should find "Question 3" in the app -# But I should not find "Question 1" in the app -# And I should not find "Question 2" in the app + When I press "Open navigation popover" in the app + Then I should find "Question 1" in the app + And I should find "Question 2" in the app + And I should find "Question 3" in the app + But I should not be able to press "Question 1" in the app + And I should not be able to press "Question 2" in the app -# When I press "Close" in the app -# And I press "Submit" in the app -# Then I should find "Summary of attempt" in the app -# # @todo MOBILE-4350: Uncomment these. -# # And I should find "Not yet answered" within "1" "ion-item" in the app -# # And I should find "Not yet answered" within "2" "ion-item" in the app -# # And I should find "Not yet answered" within "3" "ion-item" in the app + When I press "Close" in the app + And I press "Submit" in the app + Then I should find "Summary of attempt" in the app + And I should find "Not yet answered" within "1" "ion-item" in the app + And I should find "Not yet answered" within "2" "ion-item" in the app + And I should find "Not yet answered" within "3" "ion-item" in the app -# When I press "Submit all and finish" in the app -# And I press "Submit" near "Once you submit" in the app -# Then I should find "Review" in the app -# # @todo MOBILE-4350: Uncomment these. -# # And I should find "Text of the first question" in the app -# # And I should find "Text of the second question" in the app -# # And I should find "Text of the third question" in the app + When I press "Submit all and finish" in the app + And I press "Submit" near "Once you submit" in the app + Then I should find "Review" in the app + And I should find "Text of the first question" in the app + And I should find "Text of the second question" in the app + And I should find "Text of the third question" in the app diff --git a/src/addons/mod/quiz/tests/behat/snapshots/attempt-a-quiz-in-app-submit-a-quiz--review-a-quiz-attempt_26.png b/src/addons/mod/quiz/tests/behat/snapshots/attempt-a-quiz-in-app-submit-a-quiz--review-a-quiz-attempt_26.png index ff55aec20..68ea3d383 100644 Binary files a/src/addons/mod/quiz/tests/behat/snapshots/attempt-a-quiz-in-app-submit-a-quiz--review-a-quiz-attempt_26.png and b/src/addons/mod/quiz/tests/behat/snapshots/attempt-a-quiz-in-app-submit-a-quiz--review-a-quiz-attempt_26.png differ diff --git a/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_13.png b/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_13.png index b01129576..93eddfc50 100644 Binary files a/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_13.png and b/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_13.png differ diff --git a/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_9.png b/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_9.png index 9268fab1a..aab5f3f83 100644 Binary files a/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_9.png and b/src/core/features/login/tests/behat/snapshots/test-basic-usage-of-login-in-app-add-a-new-account-in-the-app--site-name-in-displayed-when-adding-a-new-account_9.png differ diff --git a/src/core/tests/behat/navigation_splitview.feature b/src/core/tests/behat/navigation_splitview.feature index 588ab27b6..faa71cc08 100644 --- a/src/core/tests/behat/navigation_splitview.feature +++ b/src/core/tests/behat/navigation_splitview.feature @@ -85,7 +85,9 @@ Feature: It navigates properly in pages with a split-view component. And I should find "Course 1" in the app And I should find "Course 2" in the app And I should find "Grade category C1" in the app - And the UI should match the snapshot + + When I replace "/.*/" within "core-user-avatar .userinitials" with "M" + Then the UI should match the snapshot # Open C1 course grades When I press "Grade item C1" in the app diff --git a/src/core/tests/behat/snapshots/it-navigates-properly-in-pages-with-a-split-view-component-navigate-in-grades-tab-on-tablet_14.png b/src/core/tests/behat/snapshots/it-navigates-properly-in-pages-with-a-split-view-component-navigate-in-grades-tab-on-tablet_14.png deleted file mode 100644 index 2b13adfb6..000000000 Binary files a/src/core/tests/behat/snapshots/it-navigates-properly-in-pages-with-a-split-view-component-navigate-in-grades-tab-on-tablet_14.png and /dev/null differ diff --git a/src/core/tests/behat/snapshots/it-navigates-properly-in-pages-with-a-split-view-component-navigate-in-grades-tab-on-tablet_15.png b/src/core/tests/behat/snapshots/it-navigates-properly-in-pages-with-a-split-view-component-navigate-in-grades-tab-on-tablet_15.png new file mode 100644 index 000000000..90b3a3920 Binary files /dev/null and b/src/core/tests/behat/snapshots/it-navigates-properly-in-pages-with-a-split-view-component-navigate-in-grades-tab-on-tablet_15.png differ diff --git a/src/theme/theme.base.scss b/src/theme/theme.base.scss index c6eed8e06..2611bf271 100644 --- a/src/theme/theme.base.scss +++ b/src/theme/theme.base.scss @@ -1522,9 +1522,10 @@ html.ios div.fake-ion-item { // Disabled items. ion-item.item-disabled, +ion-button.button-disabled, ion-item.item-interactive-disabled:not(.item-multiple-inputs) ion-label, ion-datetime.datetime-disabled { - opacity: .8 !important; + opacity: .65 !important; } // Hide details on items to align badges.