From a1cf8f143a999bc8e9525c9466b3e0bbc49416e7 Mon Sep 17 00:00:00 2001 From: Shamim Rezaie Date: Mon, 24 Jul 2023 14:23:16 +1000 Subject: [PATCH] MDL-78082 gradereport_grader: Enter should submit the form Problem: Previously, when users pressed the Enter key while interacting with the grader report, instead of submitting the form, a table column was inadvertently expanded or collapsed. This behaviour occurred due to the expand/collapse buttons lacking an explicit 'type' attribute within the form. As a result, these buttons were mistakenly treated as submit buttons. Solution: In this commit, we have addressed the issue by ensuring that the expand/collapse buttons now have the correct 'type' attribute set, explicitly identifying them as non-submit buttons. This adjustment prevents them from interfering with form submission unintentionally. Explanation: By making this fix, we improve the user experience in the grade book, allowing users to navigate and interact with the interface more smoothly. Pressing the Enter key will now trigger the form submission as expected, rather than inadvertently activating expand/collapse actions. --- grade/report/grader/templates/collapse/icon.mustache | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/grade/report/grader/templates/collapse/icon.mustache b/grade/report/grader/templates/collapse/icon.mustache index c465330d657..46e444f21a5 100644 --- a/grade/report/grader/templates/collapse/icon.mustache +++ b/grade/report/grader/templates/collapse/icon.mustache @@ -23,7 +23,7 @@ "name": "Meaning of life" } }} -