Private
Public Access
0
0

feat(theme): fix table row backgrounds and hub text contrast

This commit is contained in:
2026-06-05 00:52:28 -04:00
parent e3f8a2b517
commit 98acc12811
10 changed files with 23 additions and 8 deletions
+6
View File
@@ -139,6 +139,11 @@ def set_child_transparency(val: float) -> None:
_child_transparency = val
apply(_current_palette)
def get_table_color(is_alt: bool = False, alpha: float = 1.0) -> imgui.ImVec4:
"""Returns a tone-mapped table row background color."""
key = "table_row_bg_alt" if is_alt else "table_row_bg"
return get_color(key, alpha=alpha)
def get_color(name: str, alpha: float = 1.0) -> imgui.ImVec4:
"""Return a tone-mapped semantic color from the current palette."""
palette_name = _current_palette
@@ -165,6 +170,7 @@ def get_color(name: str, alpha: float = 1.0) -> imgui.ImVec4:
"diff_added": (51, 230, 51),
"diff_removed": (230, 51, 51),
"diff_header": (77, 178, 255),
"table_header_text": (255, 255, 255),
}
if name in fallbacks:
rgb = fallbacks[name]