From cc62c04e6faa79c7610fb50719f8e73b5b0f2025 Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Mon, 20 Nov 2023 12:20:23 +1100 Subject: [PATCH] fix: Increase contrast for icons --- sites/website.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/sites/website.py b/sites/website.py index b033c16..781e272 100644 --- a/sites/website.py +++ b/sites/website.py @@ -59,8 +59,6 @@ def render(data,db_object): hns_icon_invert = "assets/img/HNS.png" btc_icon_invert = "assets/img/BTC.png" eth_icon_invert = "assets/img/ETH.png" - location_icon = "assets/img/mapw.png" - email_icon = "assets/img/emailw.png" else: hns_icon = "assets/img/HNS.png" btc_icon = "assets/img/BTC.png" @@ -68,8 +66,16 @@ def render(data,db_object): hns_icon_invert = "assets/img/HNSW.png" btc_icon_invert = "assets/img/BTCW.png" eth_icon_invert = "assets/img/ETHW.png" + + if (rgb_to_hex(generate_foreground_color(fg_colour)) == "#000000"): + hns_chat_icon = "assets/img/HNS.png" location_icon = "assets/img/map.png" email_icon = "assets/img/email.png" + else: + hns_chat_icon = "assets/img/HNSW.png" + location_icon = "assets/img/mapw.png" + email_icon = "assets/img/emailw.png" + hns_address = hns btc_address = btc eth_address = eth @@ -92,7 +98,7 @@ def render(data,db_object): hide_addresses = True if hnschat != "": - hnschat = "" + hnschat + "/" + hnschat = "" + hnschat + "/" if location != "": location = "" + location if email != "":