From 0892b1f363f15b328dc61ca5ce4791b7c24f4ce1 Mon Sep 17 00:00:00 2001 From: Charlie Brown Date: Thu, 16 Nov 2023 08:32:01 -0500 Subject: [PATCH] Ensure selected row color takes precedence (#185) --- .changeset/clean-beds-pull.md | 5 +++++ packages/webui/src/components/ui/TraceListRow.tsx | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 .changeset/clean-beds-pull.md diff --git a/.changeset/clean-beds-pull.md b/.changeset/clean-beds-pull.md new file mode 100644 index 0000000..ce714d2 --- /dev/null +++ b/.changeset/clean-beds-pull.md @@ -0,0 +1,5 @@ +--- +'@envyjs/webui': patch +--- + +Ensure selected row color takes precendence diff --git a/packages/webui/src/components/ui/TraceListRow.tsx b/packages/webui/src/components/ui/TraceListRow.tsx index 5b0ef7c..f70b3a9 100644 --- a/packages/webui/src/components/ui/TraceListRow.tsx +++ b/packages/webui/src/components/ui/TraceListRow.tsx @@ -18,9 +18,9 @@ export default function TraceListRow({ trace }: { trace: Trace }) { key={trace.id} onClick={() => setSelectedTrace(trace.id)} className={tw( - 'table-row h-11 hover:bg-apple-200 hover:cursor-pointer hover:text-apple-900 even:bg-manatee-200 text-manatee-800', + 'table-row h-11 hover:bg-apple-200 hover:cursor-pointer hover:text-apple-900 text-manatee-800', trace.http?.state === HttpRequestState.Sent && 'text-manatee-500', - trace.id === selectedTraceId && 'bg-manatee-400 text-manatee-950', + trace.id === selectedTraceId ? 'bg-manatee-400 text-manatee-950' : 'even:bg-manatee-200', )} >