diff options
-rw-r--r-- | play.css | 5 | ||||
-rw-r--r-- | play.js | 8 |
2 files changed, 8 insertions, 5 deletions
@@ -107,10 +107,11 @@ body.shift #tooltip.focus { display: block; } .role { position: relative; + cursor: pointer; } -.role_name { - cursor: pointer; +.role.active span { + text-decoration: underline; } .role_rupees_icon, @@ -598,7 +598,7 @@ function on_update() { ce.classList.remove("card_back"); } - if (p == player_index[player]) { + if (p === player_index[player]) { ui.player[p].gift_2.classList.toggle('action', is_place_gift_action(2)); ui.player[p].gift_4.classList.toggle('action', is_place_gift_action(4)); ui.player[p].gift_6.classList.toggle('action', is_place_gift_action(6)); @@ -623,14 +623,14 @@ function on_update() { me.appendChild(ce); } - if (view.players[p].coins == 0) { + if (view.players[p].coins === 0) { ui.player[p].coin.classList.add("hide"); } else { ui.player[p].coin.classList.remove("hide"); ui.player[p].coin.textContent = view.players[p].coins; } - if (view.players[p].prizes == 0) { + if (view.players[p].prizes === 0) { ui.player[p].prize.classList.add("hide"); } else { ui.player[p].prize.classList.remove("hide"); @@ -640,6 +640,8 @@ function on_update() { ui.player[p].prize.textContent = view.players[p].prizes + " prizes"; } + ui.player[p].role.classList.toggle("active", p === player_index[view.active]) + ui.player[p].dial.className = "player_dial " + view.players[p].loyalty + " p" + p; ui.player[p].role_loy_icon.className = "role_loyalty_icon " + view.players[p].loyalty; |