diff --git a/Pages/Quizes/tests/button-1/index.html b/Pages/Quizes/tests/button-1/index.html index e30be2cf9..7e0081393 100644 --- a/Pages/Quizes/tests/button-1/index.html +++ b/Pages/Quizes/tests/button-1/index.html @@ -45,6 +45,9 @@

P Block

+
+
+
diff --git a/Pages/Quizes/tests/button-1/script.js b/Pages/Quizes/tests/button-1/script.js index 483aa1dfd..4c33cf54d 100644 --- a/Pages/Quizes/tests/button-1/script.js +++ b/Pages/Quizes/tests/button-1/script.js @@ -112,11 +112,28 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] - + let currentQuiz = 0; let score = 0; const weak_topics=[]; + const loadScore=()=>{ + const score= localStorage.getItem('btn-1-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-1-max'); + if (score>maxscore){ + localStorage.setItem('btn-1-max',score) + } + } const deselectAnswers = () => { answerElements.forEach((answer) => (answer.checked = false)); @@ -132,6 +149,7 @@ const quizData = [ const loadQuiz = () => { deselectAnswers(); + const currentQuizData = quizData[currentQuiz]; questionElement.innerText = currentQuizData.question; a_text.innerText = currentQuizData.a; @@ -143,7 +161,7 @@ const quizData = [ }; loadQuiz(); - + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); if (answer) { @@ -161,6 +179,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { diff --git a/Pages/Quizes/tests/button-1/style.css b/Pages/Quizes/tests/button-1/style.css index bf21138f3..8ad5028c1 100644 --- a/Pages/Quizes/tests/button-1/style.css +++ b/Pages/Quizes/tests/button-1/style.css @@ -334,6 +334,23 @@ ul { margin-left: 1.5vw; } /* footer */ +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} diff --git a/Pages/Quizes/tests/button-2/index.html b/Pages/Quizes/tests/button-2/index.html index f07dda308..d91278676 100644 --- a/Pages/Quizes/tests/button-2/index.html +++ b/Pages/Quizes/tests/button-2/index.html @@ -45,7 +45,9 @@

Scalars & Vectors

- +
+
+
diff --git a/Pages/Quizes/tests/button-2/script.js b/Pages/Quizes/tests/button-2/script.js index 699fd77fc..bd20e4e39 100644 --- a/Pages/Quizes/tests/button-2/script.js +++ b/Pages/Quizes/tests/button-2/script.js @@ -111,6 +111,24 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName('max-wrapper')[0]; + + const loadScore=()=>{ + const score= localStorage.getItem('btn-2-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-2-max'); + if (score>maxscore){ + localStorage.setItem('btn-2-max',score) + } + } let currentQuiz = 0; @@ -142,6 +160,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -160,6 +179,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { if(i===0){ diff --git a/Pages/Quizes/tests/button-2/style.css b/Pages/Quizes/tests/button-2/style.css index 3d7850bd9..176a9458b 100644 --- a/Pages/Quizes/tests/button-2/style.css +++ b/Pages/Quizes/tests/button-2/style.css @@ -333,9 +333,27 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */ + footer{ bottom: 0; diff --git a/Pages/Quizes/tests/button-3/index.html b/Pages/Quizes/tests/button-3/index.html index 2bcc7ef90..46b504bc4 100644 --- a/Pages/Quizes/tests/button-3/index.html +++ b/Pages/Quizes/tests/button-3/index.html @@ -45,6 +45,9 @@

Respiration In Plants

+
+
+
diff --git a/Pages/Quizes/tests/button-3/script.js b/Pages/Quizes/tests/button-3/script.js index 2a5809c46..5c1ebc53d 100644 --- a/Pages/Quizes/tests/button-3/script.js +++ b/Pages/Quizes/tests/button-3/script.js @@ -111,11 +111,28 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] let currentQuiz = 0; let score = 0; const weak_topics=[]; + const loadScore=()=>{ + const score= localStorage.getItem('btn-3-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-3-max'); + if (score>maxscore){ + localStorage.setItem('btn-3-max',score) + } + } const deselectAnswers = () => { answerElements.forEach((answer) => (answer.checked = false)); @@ -128,6 +145,7 @@ const quizData = [ }); return answer; }; + const loadQuiz = () => { deselectAnswers(); @@ -142,6 +160,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -160,6 +179,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { if(i===0){ diff --git a/Pages/Quizes/tests/button-3/style.css b/Pages/Quizes/tests/button-3/style.css index 48c07205c..bcf6e5104 100644 --- a/Pages/Quizes/tests/button-3/style.css +++ b/Pages/Quizes/tests/button-3/style.css @@ -334,6 +334,23 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */ footer{ diff --git a/Pages/Quizes/tests/button-4/index.html b/Pages/Quizes/tests/button-4/index.html index 11fc43ae2..66f9acbd5 100644 --- a/Pages/Quizes/tests/button-4/index.html +++ b/Pages/Quizes/tests/button-4/index.html @@ -45,6 +45,9 @@

Newton Laws of Motion

+
+
+
diff --git a/Pages/Quizes/tests/button-4/script.js b/Pages/Quizes/tests/button-4/script.js index 6635d87fc..7a01ddb68 100644 --- a/Pages/Quizes/tests/button-4/script.js +++ b/Pages/Quizes/tests/button-4/script.js @@ -111,11 +111,28 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] let currentQuiz = 0; let score = 0; const weak_topics=[]; + const loadScore=()=>{ + const score= localStorage.getItem('btn-4-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-4-max'); + if (score>maxscore){ + localStorage.setItem('btn-4-max',score) + } + } const deselectAnswers = () => { answerElements.forEach((answer) => (answer.checked = false)); @@ -142,6 +159,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -160,6 +178,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { if(i===0){ diff --git a/Pages/Quizes/tests/button-4/style.css b/Pages/Quizes/tests/button-4/style.css index 48c07205c..bcf6e5104 100644 --- a/Pages/Quizes/tests/button-4/style.css +++ b/Pages/Quizes/tests/button-4/style.css @@ -334,6 +334,23 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */ footer{ diff --git a/Pages/Quizes/tests/button-5/index.html b/Pages/Quizes/tests/button-5/index.html index c0c594092..40a33da90 100644 --- a/Pages/Quizes/tests/button-5/index.html +++ b/Pages/Quizes/tests/button-5/index.html @@ -45,6 +45,9 @@

Thermodynamics

+
+
+
diff --git a/Pages/Quizes/tests/button-5/script.js b/Pages/Quizes/tests/button-5/script.js index 00b597bd6..a158b5930 100644 --- a/Pages/Quizes/tests/button-5/script.js +++ b/Pages/Quizes/tests/button-5/script.js @@ -111,6 +111,23 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] +const loadScore=()=>{ + const score= localStorage.getItem('btn-5-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-5-max'); + if (score>maxscore){ + localStorage.setItem('btn-5-max',score) + } + } let currentQuiz = 0; @@ -142,6 +159,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -160,6 +178,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { if(i===0){ diff --git a/Pages/Quizes/tests/button-5/style.css b/Pages/Quizes/tests/button-5/style.css index 744de12ac..4830a51ea 100644 --- a/Pages/Quizes/tests/button-5/style.css +++ b/Pages/Quizes/tests/button-5/style.css @@ -316,6 +316,23 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */ footer{ diff --git a/Pages/Quizes/tests/button-6/index.html b/Pages/Quizes/tests/button-6/index.html index 3ec49c4b6..842a26a81 100644 --- a/Pages/Quizes/tests/button-6/index.html +++ b/Pages/Quizes/tests/button-6/index.html @@ -45,6 +45,9 @@

Periodic Table & Periodicity

+
+
+
diff --git a/Pages/Quizes/tests/button-6/script.js b/Pages/Quizes/tests/button-6/script.js index 91a1f1778..340ec826b 100644 --- a/Pages/Quizes/tests/button-6/script.js +++ b/Pages/Quizes/tests/button-6/script.js @@ -112,6 +112,23 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] +const loadScore=()=>{ + const score= localStorage.getItem('btn-6-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-6-max'); + if (score>maxscore){ + localStorage.setItem('btn-6-max',score) + } + } let currentQuiz = 0; @@ -143,6 +160,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -161,6 +179,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { diff --git a/Pages/Quizes/tests/button-6/style.css b/Pages/Quizes/tests/button-6/style.css index 744de12ac..4830a51ea 100644 --- a/Pages/Quizes/tests/button-6/style.css +++ b/Pages/Quizes/tests/button-6/style.css @@ -316,6 +316,23 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */ footer{ diff --git a/Pages/Quizes/tests/button-7/index.html b/Pages/Quizes/tests/button-7/index.html index b640055dd..c1d5f07d8 100644 --- a/Pages/Quizes/tests/button-7/index.html +++ b/Pages/Quizes/tests/button-7/index.html @@ -45,6 +45,9 @@

3-D geometry

+
+
+
diff --git a/Pages/Quizes/tests/button-7/script.js b/Pages/Quizes/tests/button-7/script.js index 3c72fe5b3..3b0d8e567 100644 --- a/Pages/Quizes/tests/button-7/script.js +++ b/Pages/Quizes/tests/button-7/script.js @@ -112,6 +112,23 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] +const loadScore=()=>{ + const score= localStorage.getItem('btn-7-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-7-max'); + if (score>maxscore){ + localStorage.setItem('btn-7-max',score) + } + } let currentQuiz = 0; let score = 0; @@ -142,6 +159,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -160,6 +178,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { diff --git a/Pages/Quizes/tests/button-7/style.css b/Pages/Quizes/tests/button-7/style.css index 1c905f2b8..42a5bb95d 100644 --- a/Pages/Quizes/tests/button-7/style.css +++ b/Pages/Quizes/tests/button-7/style.css @@ -335,6 +335,23 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */ diff --git a/Pages/Quizes/tests/button-8/index.html b/Pages/Quizes/tests/button-8/index.html index b26698fce..fee55e902 100644 --- a/Pages/Quizes/tests/button-8/index.html +++ b/Pages/Quizes/tests/button-8/index.html @@ -45,6 +45,9 @@

Chemical Bonding

+
+
+
diff --git a/Pages/Quizes/tests/button-8/script.js b/Pages/Quizes/tests/button-8/script.js index c819781a9..78a4ad9c3 100644 --- a/Pages/Quizes/tests/button-8/script.js +++ b/Pages/Quizes/tests/button-8/script.js @@ -112,6 +112,23 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] +const loadScore=()=>{ + const score= localStorage.getItem('btn-8-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-8-max'); + if (score>maxscore){ + localStorage.setItem('btn-8-max',score) + } + } let currentQuiz = 0; @@ -143,6 +160,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -161,7 +179,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` - + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { if(i===0){ diff --git a/Pages/Quizes/tests/button-8/style.css b/Pages/Quizes/tests/button-8/style.css index 744de12ac..4830a51ea 100644 --- a/Pages/Quizes/tests/button-8/style.css +++ b/Pages/Quizes/tests/button-8/style.css @@ -316,6 +316,23 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */ footer{ diff --git a/Pages/Quizes/tests/button-9/index.html b/Pages/Quizes/tests/button-9/index.html index 714b55c19..74c05e913 100644 --- a/Pages/Quizes/tests/button-9/index.html +++ b/Pages/Quizes/tests/button-9/index.html @@ -45,6 +45,9 @@

Sequence & Series

+
+
+
diff --git a/Pages/Quizes/tests/button-9/script.js b/Pages/Quizes/tests/button-9/script.js index 0737a9d7c..c2d7ddf87 100644 --- a/Pages/Quizes/tests/button-9/script.js +++ b/Pages/Quizes/tests/button-9/script.js @@ -112,6 +112,23 @@ const quizData = [ const submitButton = document.getElementById("submit"); const difficulty = document.getElementById("difficulty"); const quizcount = document.getElementById("quizcount"); + const prev_score= document.getElementById("max-score"); + const max_wrapper= document.getElementsByClassName("max-wrapper")[0] +const loadScore=()=>{ + const score= localStorage.getItem('btn-9-max'); + if(score){ + prev_score.innerHTML=`Max score
${score}`; + }else{ + max_wrapper.style.display='none' + } + + } + const storeMax=(score)=>{ + const maxscore = localStorage.getItem('btn-9-max'); + if (score>maxscore){ + localStorage.setItem('btn-9-max',score) + } + } let currentQuiz = 0; let score = 0; @@ -142,6 +159,7 @@ const quizData = [ }; loadQuiz(); + loadScore(); submitButton.addEventListener("click", () => { const answer = getSelected(); @@ -160,6 +178,8 @@ const quizData = [

You answered ${score}/${quizData.length} questions correctly

` + storeMax(score); + loadScore(); var temp; for (i = 0; i < weak_topics.length; i++) { diff --git a/Pages/Quizes/tests/button-9/style.css b/Pages/Quizes/tests/button-9/style.css index 7f63a24b6..e12bcdfb6 100644 --- a/Pages/Quizes/tests/button-9/style.css +++ b/Pages/Quizes/tests/button-9/style.css @@ -335,6 +335,23 @@ ul { .recommendations h3{ margin-left: 1.5vw; } +.max-wrapper{ + background-color:#F0F1FF; + border-radius: 50%; + width:100px; + height:100px; + display: flex; + justify-content:center; + align-items: center; + border : 7px solid #242969; + margin-bottom: 20px; + padding: 5px; +} +#max-score{ + font-family: 'Poppins', sans-serif; + font-weight: bold; + text-align: center; +} /* footer */