-
Bug
-
Resolution: Fixed
-
Minor
-
3.2.5, 3.3, 3.4
-
MOODLE_32_STABLE, MOODLE_33_STABLE, MOODLE_34_STABLE
-
MOODLE_33_STABLE, MOODLE_34_STABLE
-
MDL-60547-master -
Hi,
when clicking on the "Mark all as read" icon within the notifications popover the page in the background jumps to the top.
This is not the case with the "Mark all as read" icon in the messages popover...
Steps to reproduce
- Login as a user
- Scroll down the page a little bit
- Click on the "notifications" icon in the navbar
- In the popover header click on the "Mark all as read" icon
- => See that the page in the background jumps to the top
- Try the same steps with the messages
- => See that the page in the background stays at it's position the user scrolled to
Thoughts
I've had a look at the code and compared the HTML structure and also the Code behind it.
The methods notification_popover_controller.js and message_popover_controller.js differ in the method "markAllAsRead"
- https://github.com/moodle/moodle/blob/master/message/output/popup/amd/src/notification_popover_controller.js#L311
- https://github.com/moodle/moodle/blob/master/message/output/popup/amd/src/message_popover_controller.js#L244).
I've tried to complete the method from the notification_popover_conroller.js with the code from the message_popover_controller.js but it did not solve this problem.
So I really don't know why both buttons behave differently.... But it would be great if both buttons would behave equally.
Best, Kathrin