fix(webui): reuse touch targets for composer mentions

This commit is contained in:
Xubin Ren committed 2026-10-04 20:05:12 +08:00
1 parent 5c5027ac0b
commit 2e334b2250
3 files changed
+6 -2

No files matched your search

@@ -3111,7 +3111,7 @@ function CliAppMentionPalette({
}}
className={cn(
floatingItemClassName,
"flex min-h-10 w-full items-center gap-2.5 px-2.5 py-1.5 text-left transition-colors",
"touch-target flex min-h-10 w-full items-center gap-2.5 px-2.5 py-1.5 text-left transition-colors",
selected
? "bg-foreground/[0.055] text-foreground"
: "text-foreground/90 hover:bg-foreground/[0.04]",
+3
View File
@@ -2436,6 +2436,9 @@ describe("ThreadComposer", () => {
expect(screen.queryByText("MCP servers")).not.toBeInTheDocument();
const gimp = screen.getByRole("option", { name: /GIMP @gimp .* CLI/i });
const browserbase = screen.getByRole("option", { name: /Browserbase @browserbase .* MCP/i });
// Reuse the app's 44px coarse-pointer targets without changing desktop density.
expect(gimp).toHaveClass("touch-target");
expect(browserbase).toHaveClass("touch-target");
expect(within(gimp).getByText("CLI")).toBeInTheDocument();
expect(within(browserbase).getByText("MCP")).toBeInTheDocument();
expect(within(gimp).getByText("@gimp")).toBeInTheDocument();