From 12791266b25156d94cc5736f44dd8e303e45a803 Mon Sep 17 00:00:00 2001 From: Kevin Jilissen Date: Wed, 10 Sep 2025 19:38:22 +0200 Subject: [PATCH 1/2] Change diff mode selection to radio button Visually, this is more in line with the rest of the design. It also clears some vertical space which can be used by the monaco editor. --- webapp/src/Twig/TwigExtension.php | 16 +++++++--------- .../jury/partials/submission_diff.html.twig | 10 +++++++++- 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/webapp/src/Twig/TwigExtension.php b/webapp/src/Twig/TwigExtension.php index aed9adf2ae..f619dc1d09 100644 --- a/webapp/src/Twig/TwigExtension.php +++ b/webapp/src/Twig/TwigExtension.php @@ -940,10 +940,6 @@ protected function parseSourceDiff(string $difftext): string public function showDiff(string $id, SubmissionFile $newFile, SubmissionFile $oldFile): string { $editor = << - - -
diff --git a/webapp/templates/jury/partials/submission_diff.html.twig b/webapp/templates/jury/partials/submission_diff.html.twig index 7cb1886bd3..c991494b33 100644 --- a/webapp/templates/jury/partials/submission_diff.html.twig +++ b/webapp/templates/jury/partials/submission_diff.html.twig @@ -57,10 +57,10 @@ {% endif %}
- - - - + {%- for mode_id, mode in diff_modes %} + + + {%- endfor %}
{{ showDiff(diff_id, filePair.0, filePair.1) }}