-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscript.js
More file actions
35 lines (31 loc) · 974 Bytes
/
script.js
File metadata and controls
35 lines (31 loc) · 974 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
function nextSlide(url) {
window.location.href = url;
}
function nextSlide(url) {
window.location.href = url;
}
function prevSlide(url) {
window.location.href = url;
}
// Function to open the modal with the clicked image
function openModal(img) {
const modal = document.getElementById("imageModal");
const modalImg = document.getElementById("modalImg");
modal.style.display = "block";
modalImg.src = img.src;
}
// Function to close the modal
function closeModal() {
const modal = document.getElementById("imageModal");
modal.style.display = "none";
}
// Function to show more samples
function showMore(type) {
if (type === "bad") {
const extraBadSample = document.getElementById("bad-sample-extra");
extraBadSample.classList.toggle("hidden");
} else if (type === "good") {
const extraGoodSample = document.getElementById("good-sample-extra");
extraGoodSample.classList.toggle("hidden");
}
}