diff --git a/web/src/components/PlaybackRouteBadges.tsx b/web/src/components/PlaybackRouteBadges.tsx index c9ad2733e2..af9413c7c5 100644 --- a/web/src/components/PlaybackRouteBadges.tsx +++ b/web/src/components/PlaybackRouteBadges.tsx @@ -6,6 +6,14 @@ import { getSessionRouteNodes, type ActivityRouteNode } from "@/pages/adminActiv /** Decorative separator between values; not text, so not translated. */ const SEPARATOR = "ยท"; +/** + * The label before a badge's value. 75% foreground blends with the tint + * under it, so it reads on any accent; high contrast lightens the surfaces, + * so there it takes the boosted muted color instead. + */ +const LABEL_CLASS = + "text-foreground/75 [html[data-high-contrast=true]_&]:text-muted-foreground font-(--font-weight-ui)"; + const BADGE_COLORS: Record = { transcode: "border-warning/25 bg-warning/10 text-warning", proxy: "border-info/25 bg-info/10 text-info", @@ -30,9 +38,7 @@ function NetworkBadge({ name, title }: { name: string; title: string }) { aria-label={t("web.player.routeBadge.networkAria", { name })} className="border-primary/20 bg-primary/10 text-primary inline-flex max-w-full items-center gap-1 rounded border px-1.5 py-0.5 text-[9px] font-semibold" > - - {t("web.player.routeBadge.network")} - + {t("web.player.routeBadge.network")} {name} @@ -104,7 +110,7 @@ export function PlaybackRouteBadges({ > {node.kind === "transcode" || node.kind === "proxy" ? ( <> - {node.label} + {node.label} ) : null} diff --git a/web/src/pages/admin-downloads/PreparationTab.tsx b/web/src/pages/admin-downloads/PreparationTab.tsx index 1c13b09e79..f441f5104d 100644 --- a/web/src/pages/admin-downloads/PreparationTab.tsx +++ b/web/src/pages/admin-downloads/PreparationTab.tsx @@ -722,7 +722,10 @@ function WorkerBadge({ prep }: { prep: AdminDownloadPreparation }) { } return ( - {worker.label} + {/* Same label treatment as the playback route badges (PlaybackRouteBadges). */} + + {worker.label} + {worker.name} );