Skip to content
This repository was archived by the owner on Jun 30, 2024. It is now read-only.

Commit cf48141

Browse files
committed
Add Style
1 parent 5f5b142 commit cf48141

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

static/js/admin.js

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,15 +31,25 @@ function gradeIndividualItem() {
3131

3232
$(rightSideDiv)[0].style.visibility = "visible";
3333
rightSideDiv.html(""); //empty it out
34-
rightSideDiv.html("<input id='filterto0' type=checkbox unchecked/>Click to only show questions with a grade of 0 or not graded<br/>")
34+
rightSideDiv.html(`<div id='filterqs'
35+
style="
36+
width: 60%;
37+
margin-left: auto;
38+
margin-right: auto;
39+
border: solid blue;
40+
border-radius: 5px;
41+
padding: 5px;">
42+
<input id='filterto0' type=checkbox unchecked/>Click to only show questions with a grade of 0 or not graded</div>`);
3543
let rsd = document.querySelector("#filterto0");
3644
rsd.addEventListener('change',
3745
function () {
3846
let gPanels = document.querySelectorAll(".loading");
3947
for (let panel of gPanels) {
4048
let v = panel.querySelector("#gradingform").querySelector("#input-grade").value;
4149
if (rsd.checked) {
42-
if (v != 0 || v != "") {
50+
if (v == 0 || v == "") {
51+
panel.style.display = "block";
52+
} else {
4353
panel.style.display = "none";
4454
}
4555
} else {

0 commit comments

Comments
 (0)