diff options
Diffstat (limited to 'play.js')
-rw-r--r-- | play.js | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -476,7 +476,7 @@ function sub_card_name(match, p1) { function sub_power_card_name(match, p1) { let x = p1 | 0 - return `<span class="card_name">${power_cards[x].name}</span>` + return `<span class="card_name" onmouseenter="on_focus_power_card_tip(${x})" onmouseleave="on_blur_power_card_tip()">${power_cards[x].name}</span>` } function sub_power_card_value(match, p1) { @@ -513,6 +513,14 @@ function on_blur_card_tip() { document.getElementById("tooltip").classList = "card hide" } +function on_focus_power_card_tip(card_number) { + document.getElementById("tooltip").className = "card power_" + card_number +} + +function on_blur_power_card_tip() { + document.getElementById("tooltip").classList = "card hide" +} + function on_focus_space_tip(id) { ui.spaces[id].classList.add("tip") } |