From 0eb62560bc0326f1790017bcd6e5bad9a3654fd1 Mon Sep 17 00:00:00 2001 From: Emily Venezia Date: Wed, 11 Sep 2024 19:55:40 -0400 Subject: [PATCH] underline hint statuses to indicate clickability --- kvui.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/kvui.py b/kvui.py index ae2689b951d5..a5ce35806260 100644 --- a/kvui.py +++ b/kvui.py @@ -787,6 +787,9 @@ def refresh_hints(self, hints): for hint in hints: if not hint.get("status"): # Allows connecting to old servers hint["status"] = HintStatus.HINT_FOUND if hint["found"] else HintStatus.HINT_UNSPECIFIED + hint_status_node = self.parser.handle_node({"type": "color", + "color": status_colors.get(hint["status"], "red"), + "text": status_names.get(hint["status"], "Unknown")}) data.append({ "receiving": {"text": self.parser.handle_node({"type": "player_id", "text": hint["receiving_player"]})}, "item": {"text": self.parser.handle_node({ @@ -805,8 +808,7 @@ def refresh_hints(self, hints): "color": "blue", "text": hint["entrance"] if hint["entrance"] else "Vanilla"})}, "status": { - "text": self.parser.handle_node({"type": "color", "color": status_colors.get(hint["status"], "red"), - "text": status_names.get(hint["status"], "Unknown")}), + "text": f"[u]{hint_status_node}[/u]", "hint": hint, }, })