Codebase intelligence for AI and humans: code health scores, auto-generated docs, git analytics, dead code detection, and architectural decisions via MCP.
Python aicode-complexitycode-healthcode-intelligencecode-qualitydead-codedeveloper-toolsdocumentationgit-analyticsmcpopen-sourcepythonrefactoringstatic-analysistechnical-debt
fix(ui): let taps through the hidden conversation row toolbar (#3764)
Yaniscbcf75924dbb
diff --git a/packages/ui/__tests__/chat/conversation-history.test.tsx b/packages/ui/__tests__/chat/conversation-history.test.tsxindex 378ea6427..140659fb8 100644--- a/packages/ui/__tests__/chat/conversation-history.test.tsx+++ b/packages/ui/__tests__/chat/conversation-history.test.tsx@@ -156,4 +156,15 @@ describe("ConversationHistory shell", () => {expect(screen.getByRole("complementary", { name: "Conversation history" })).toHaveAttribute("data-collapsed", "false");expect(window.localStorage.getItem(preferenceKey)).toBe("expanded");});++ it("lets clicks through the hidden row toolbar from sm up", () => {+ render(<ConversationHistory conversations={CONVERSATIONS} onSelect={vi.fn()} onDelete={vi.fn()} onNew={vi.fn()} />);+ fireEvent.click(screen.getByRole("button", { name: /history/i }));+ const toolbar = screen.getAllByRole("button", { name: /delete conversation/i })[0]!.parentElement;+ expect(toolbar).toHaveClass(+ "sm:pointer-events-none",+ "sm:group-hover:pointer-events-auto",+ "sm:group-focus-within:pointer-events-auto",+ );+ });});diff --git a/packages/ui/src/chat/conversation-history.tsx b/packages/ui/src/chat/conversation-history.tsxindex 1509c3f76..2f652a579 100644--- a/packages/ui/src/chat/conversation-history.tsx+++ b/packages/ui/src/chat/conversation-history.tsx@@ -105,7 +105,7 @@ export function ConversationHistory({) : (<button type="button" onClick={() => { onSelect(conversation.id); closePopover(); }} className="w-full py-2 pl-2 pr-[7.5rem] text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-accent-primary)] sm:pr-2"><span className="block text-xs leading-4 text-[var(--color-text-primary)] [overflow-wrap:anywhere]">{conversation.title}</span><span className="mt-0.5 block truncate font-mono text-[10px] tabular-nums text-[var(--color-text-tertiary)]">{formatRelativeTime(conversation.updated_at)} · {conversation.message_count} msgs</span></button>)}- <div className="absolute right-1 top-1 flex items-center justify-end gap-0.5 opacity-70 sm:rounded sm:opacity-0 sm:group-hover:bg-[var(--color-bg-overlay)] sm:group-hover:opacity-100 sm:group-focus-within:bg-[var(--color-bg-overlay)] sm:group-focus-within:opacity-100">+ <div className="absolute right-1 top-1 flex items-center justify-end gap-0.5 opacity-70 sm:rounded sm:opacity-0 sm:group-hover:bg-[var(--color-bg-overlay)] sm:group-hover:opacity-100 sm:group-focus-within:bg-[var(--color-bg-overlay)] sm:group-focus-within:opacity-100 sm:pointer-events-none sm:group-hover:pointer-events-auto sm:group-focus-within:pointer-events-auto">{onRename && <button type="button" onClick={() => setEditing({ id: conversation.id, title: conversation.title })} aria-label="Rename conversation" className="flex h-7 w-7 items-center justify-center rounded text-[var(--color-text-tertiary)] hover:bg-[var(--color-bg-overlay)] hover:text-[var(--color-text-primary)]"><Pencil className="h-3.5 w-3.5" /></button>}{onPin && <button type="button" onClick={() => void onPin(conversation.id, !conversation.pinned)} aria-label={conversation.pinned ? "Unpin conversation" : "Pin conversation"} className="flex h-7 w-7 items-center justify-center rounded text-[var(--color-text-tertiary)] hover:bg-[var(--color-bg-overlay)] hover:text-[var(--color-text-primary)]"><Pin className="h-3.5 w-3.5" /></button>}{onFork && <button type="button" onClick={() => void onFork(conversation.id)} aria-label="Fork conversation" className="flex h-7 w-7 items-center justify-center rounded text-[var(--color-text-tertiary)] hover:bg-[var(--color-bg-overlay)] hover:text-[var(--color-text-primary)]"><GitFork className="h-3.5 w-3.5" /></button>}