-
Notifications
You must be signed in to change notification settings - Fork 197
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update footer styles in multi page quiz #7268
Conversation
Having only "Next" as the button text does not look good to me for some reason, should we change this to "Next Questions" or "Next Page" or something like that? In the context of Lessons, we use "Next Lesson" as button text |
WordPress Dependencies ReportThe No changes detected in the current commit. But the comment was left so it is possible to check for the edit history. This comment was automatically generated by the |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## trunk #7268 +/- ##
=========================================
Coverage 50.74% 50.74%
Complexity 11051 11051
=========================================
Files 610 610
Lines 46649 46649
Branches 402 402
=========================================
Hits 23671 23671
Misses 22651 22651
Partials 327 327
Continue to review full report in Codecov by Sentry.
|
If we use "Next Lesson" for lessons, then "Next Question" makes the most sense here. 👍🏻 |
Thank you, I've updated the Next and Previous buttons here 8a9a0e9, now they say "Previous Question" and "Next Question" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, in general. Tested it when the quiz was not submitted and when it was submitted: both looks good.
I found an edge case, which is a bit broken. I don't know if we want to address it here (or at all). For this reason I don't approve the PR, let me know if we're fine to merge it as is and I approve it.
Now, to the edge case. It happens when the student completed the lesson, then the teacher adds a quiz to that lesson. When I open the quiz as a student I see it like that (pagination links are smaller, the "Next Question" button is in a different place):
At the same time, we don't need pagination here: all questions are here.
Hi @merkushin 👋 Thanks for taking a look.
I've investigated the issue to find the root cause, found the cause after deep investigation, I'm sharing it in details because I felt a bit concerned about it as it's happening due to some changes related to HPPS and you may need to look for and handle potential similar issues in other places as well if they exist. In learning mode, when viewing a quiz, we use the lesson or the quiz template conditionally. If the quiz is not taken by the student, we load the quiz template, and if the quiz is in awaiting-grade or any later status, we use the lesson template. you can find the logic here. The problem is, for HPPS, I see that a change was introduced here and many other places recently to read quiz/lesson status from https://github.com/Automattic/sensei/pull/7185/files quiz repository instead. Previously, when a quiz was not taken by a student but the lesson was marked as completed, the status we got in comment was 'completed', but quiz repository is returning "passed" in that case, which is not correct because the student did not actually pass the quiz. I reverted the repository change temporarily to check if it works as expected, and it did. So I think we should handle the status issue in the HPPS project. I think it probably is an important issue because it is impacting not only the multi page quizzes, but other normal quizzes too and apart from the LM template loading, it can have impact in other places as well.
Updated here for Next and Previous Questions f71c93a 👍 |
Thanks for investigation @Imran92! Just to inform I want to notice, that we can't return 'completed' status for a quiz progress as it breaks the logic ('completed' is not a quiz progress status, that's a lesson progress status) and will break compatibility between comments-based and tables-based versions. Also I addressed this issue there:
It wasn't related to HPPS project, but highlights the problem of unified progress for a lesson and a quiz. |
Hi @merkushin 👋 Thanks for the review!
Yap, fully agreed. The problem was it was returning "Passed" which is a quiz-specific one. We just needed it to be something other than these 4 quiz-specific ones
Sure I will, thanks! I'm not merging this PR yet as it depends on this PR #7256. |
Hi @merkushin 👋 Sorry the review got dismissed after the base branch was merged to trunk, can you kindly do it again? Thanks!! |
Resolves #7243
Proposed Changes
Testing Instructions
Course theme
Astra
Pre-Merge Checklist