From 0da45c31bfab31ea98d00e88f2536850653680f4 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Mon, 28 Oct 2024 00:32:36 +0100 Subject: Use icons for power action buttons --- play.js | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'play.js') diff --git a/play.js b/play.js index 0e35b5d..5838520 100644 --- a/play.js +++ b/play.js @@ -613,6 +613,15 @@ function make_badge(power) { return e } +const power_image = [ + 'France', + 'Prussia', + 'Pragmatic Army', + 'Austria', + 'Bavaria', + 'Saxony', +] + const power_badge = [ make_badge("france"), make_badge("prussia"), @@ -1401,10 +1410,10 @@ function on_update() { action_button_with_argument("value", v, v) for (let p = 0; p < 20; ++p) - action_button_with_argument("supreme", p, power_name[piece_power[p]]) + action_button_with_argument("supreme", p, power_image[piece_power[p]]) for (let pow of all_powers) - action_button_with_argument("power", pow, power_name[pow]) + action_button_with_argument("power", pow, power_image[pow]) action_button("subsidy", "Subsidy") action_button("cancel", "Cancel") -- cgit v1.2.3