-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscript.js
More file actions
33 lines (30 loc) · 1.07 KB
/
script.js
File metadata and controls
33 lines (30 loc) · 1.07 KB
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
var unit1 = document.querySelector(".unit12");
var unit2 = document.querySelector(".unit2");
var unit3 = document.querySelector(".unit3");
var check1 = document.querySelector(".check1");
var check2 = document.querySelector(".check2");
var check3 = document.querySelector(".check3");
function show1(){
unit1.classList.replace("unit1", "unit12");
check1.style.display = "block";
check2.style.display = "none";
check3.style.display = "none";
unit2.classList.replace("unit122", "unit2");
unit3.classList.replace("unit12", "unit3");
}
function show2(){
unit2.classList.replace("unit2", "unit122");
check1.style.display = "none";
check2.style.display = "block";
check3.style.display = "none";
unit3.classList.replace("unit12", "unit3");
unit1.classList.replace("unit12", "unit1");
}
function show3(){
unit3.classList.replace("unit3", "unit12");
check1.style.display = "none";
check2.style.display = "none";
check3.style.display = "block";
unit2.classList.replace("unit122", "unit2");
unit1.classList.replace("unit12", "unit1");
}