diff options
author | iainp5 <iain.pearce.ip@gmail.com> | 2025-01-10 15:44:50 +0000 |
---|---|---|
committer | iainp5 <iain.pearce.ip@gmail.com> | 2025-01-10 15:44:50 +0000 |
commit | 207c877d9b6461ff3d02ee18f27a675b3ab8008c (patch) | |
tree | 14734c513820926d6bff96be43832538c5cebbdb /play.js | |
parent | 9925fbde2385f345c2ea0a48675f84b1dd492d32 (diff) | |
parent | d7d13411aed277b7e1aad5053f9d5d0df4f308bd (diff) | |
download | 1989-dawn-of-freedom-207c877d9b6461ff3d02ee18f27a675b3ab8008c.tar.gz |
Merge branch 'main' of https://github.com/iainp5/1989-Dawn-of-Freedom
Diffstat (limited to 'play.js')
-rw-r--r-- | play.js | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -553,7 +553,7 @@ function layout_turn_marker() { function layout_round_marker() { let x = 709 + 24 + (view.round - 1) * 53 - let y = 142 + 24 + let y = 141 + 24 ui.round.style.left = x - 25 + "px" ui.round.style.top = y - 25 + "px" if (view.round_player === "Democrat") @@ -880,7 +880,7 @@ function on_update() { if (view.discard) document.getElementById("discard_panel").classList.remove("hide") else - document.getElementById("discard_panel").classList.add("hide") + document.getElementById("discard_panel").classList.toggle("hide", discard_toggle) ui.removed.replaceChildren() for (let c of view.strategy_removed) @@ -1187,8 +1187,10 @@ function on_click_space_tip(id) { scroll_into_view(ui.spaces[id]) } +let discard_toggle = document.getElementById("discard_panel").classList.contains("hide") function toggle_discard() { - document.getElementById("discard_panel").classList.toggle("hide") + discard_toggle = !discard_toggle + document.getElementById("discard_panel").classList.toggle("hide", discard_toggle) } function toggle_removed() { |