Permalink
Browse files

tourneys status

  • Loading branch information...
Manuel-777 committed Jan 20, 2019
1 parent 8ae9a52 commit c0ad2382466ce75e25b0a84aae96e9d1a6c74995
Binary file not shown.
BIN -48 Bytes (99%) images/status_green.png
Binary file not shown.
BIN -47 Bytes (99%) images/status_red.png
Binary file not shown.
BIN -43 Bytes (99%) images/status_yellow.png
Binary file not shown.
@@ -42,6 +42,10 @@ span i {
background-image: url(../images/status_red.png);
}

.status_black {
background-image: url(../images/status_black.png);
}

.top_logo_about {
cursor: pointer;
align-self: center;
@@ -83,6 +83,11 @@ function open_tournaments_tab(arg, opentab = true) {
div.classList.add("tou_container");
div.id = tou._id;

let stat = document.createElement("div");
stat.classList.add("top_status");
if (tou.state == -1) stat.classList.add("status_red");
else if (tou.state == 4) stat.classList.add("status_black");
else stat.classList.add("status_green");

let sd = tou.signupDuration;
let rd = tou.roundDuration;
@@ -154,6 +159,7 @@ function open_tournaments_tab(arg, opentab = true) {
pln.style.width = "200px";
pln.innerHTML = stateb;

div.appendChild(stat);
div.appendChild(nam);
div.appendChild(fo);
div.appendChild(st);
@@ -627,6 +633,9 @@ function generateChecks(state, game, seat) {
else {
ch = $(`<div title="${ss == seat ? 'You' : tou.current_opponent.slice(0, -6)}" class="tou_check black_bright_bg"></div>`);
}
if (ss == 1) {
ch.css("margin-right", "16px");
}
ch.appendTo(checks);
});

0 comments on commit c0ad238

Please sign in to comment.