diff --git a/css/main.css b/css/main.css
index e699fe8..c76ecaa 100644
--- a/css/main.css
+++ b/css/main.css
@@ -1347,4 +1347,17 @@ h2:has(+ #exam-list:empty), h2:has(+ #packet-list:empty){
display: flex;
align-items: center;
gap: 15px;
+}
+
+.exit-exam-mode {
+ position: fixed;
+ bottom: 20px;
+ right: 20px;
+ background-color: #b71c1c;
+ color: white;
+ border: none;
+ padding: 10px 15px;
+ border-radius: 5px;
+ cursor: pointer;
+ z-index: 10000;
}
\ No newline at end of file
diff --git a/js/main.js b/js/main.js
index 440ff1f..a775752 100644
--- a/js/main.js
+++ b/js/main.js
@@ -66,6 +66,20 @@ let url_exam_mode = false;
if (examParam !== null) {
if (examParam === "1" || String(examParam).toLowerCase() === "true") {
url_exam_mode = true;
+ let el = $("#load-exam-packet-instructions")
+ el.html("You are in exam mode.");
+
+ let button = $("");
+
+ button.click(() => {
+ // Remove exam_mode param from URL and reload page
+ params.delete("exam_mode");
+ const newUrl = `${window.location.pathname}?${params.toString()}`;
+ window.location.href = newUrl;
+ })
+ el.append(button);
+ el.append("
Click on exam below to load it.");
+
log.debug("URL parameter enabled exam mode");
}
}