diff --git a/bfos/ui_theme.py b/bfos/ui_theme.py index 153049b..b84560a 100644 --- a/bfos/ui_theme.py +++ b/bfos/ui_theme.py @@ -255,6 +255,9 @@ METRIC_TOKENS: Mapping[str, int] = { } #: Every mirrored value, by CSS token name (used by the parity test). +#: Lengths are stored WITHOUT their unit: the unit is the token's (px at +#: 96 dpi), and the console passes the number straight to Tk padding, which is +#: already in pixels. The parity test strips the CSS unit to compare. ALL_TOKENS: Mapping[str, str] = { **TOKENS, **{name: str(value) for name, value in SPACE_TOKENS.items()}, @@ -347,11 +350,6 @@ def data_font(size: int = SIZE_SM, weight: str = "normal") -> tuple: return (data_family(), point_size(size), weight) -def state_style(state: str) -> str: - """ttk style name for a state badge ("KURULDU" ...).""" - return f"State{state.capitalize()}.Badge.TLabel" - - #: State key -> badge style, built from STATE_WORDS so the word and the colour #: can never be paired up wrongly on one surface. STATE_BADGE_STYLE: Mapping[str, str] = { diff --git a/tests/test_web_static.py b/tests/test_web_static.py index aa4b459..710ce1c 100644 --- a/tests/test_web_static.py +++ b/tests/test_web_static.py @@ -904,7 +904,7 @@ class TestFleetPage(PanelCase): cells = re.findall(r"