Details
-
Bug
-
Status: Waiting for peer review
-
Minor
-
Resolution: Unresolved
-
3.11
-
None
Description
User tours do not respond well to changes in screen size while the tour is up. This happens most commonly on mobile devices if you rotate the screen, but you can also reproduce the problem by resizing the browser:
1 Go to Moodle sandbox and configure user tours https://sandbox.moodledemo.net/admin/tool/usertours/configure.php
2 Turn on the Messaging tour
3 Go to a course page https://sandbox.moodledemo.net/course/view.php?id=2
4 Click 'Reset user tour' so it actually displays
Observe that the tour box appears in the middle of the screen.
5 Resize the window to make it narrower or wider
Observe that the tour box stays where it was, which may now be inappropriate. If the tour box is pointing to something specific, it may also now be in the wrong place.
However, if you press 'Next' to go to the next step then it appears correctly.
I suggest this problem should be fixed by detecting window resize while a step is open, and closing the step and reopening it in that case. We need to be a bit careful that this doesn't cause unexpected problems, for example on mobile if you scroll the page and the URL bar disappears, does that count as a resize sometimes - maybe it should only act if the width changes, not just height.
Note: we'll assign this to an OU developer to work on.