diff --git a/packages/studio/src/components/ui/Menu.test.tsx b/packages/studio/src/components/ui/Menu.test.tsx index 6929b5605b..3322657f5a 100644 --- a/packages/studio/src/components/ui/Menu.test.tsx +++ b/packages/studio/src/components/ui/Menu.test.tsx @@ -434,4 +434,12 @@ describe("open motion", () => { /\.duration-open \{[\s\S]*?prefers-reduced-motion: reduce[\s\S]*?transition-duration: 0ms/, ); }); + + it("rounds a row's highlight more than the panel that holds it", async () => { + await openActionMenu(); + + const rowRadius = [...items()[0]!.classList].find((c) => c.startsWith("rounded-"))!; + expect([...popup()!.classList]).toContain("rounded-lg"); + expect(compileStudioCss([rowRadius])).toMatch(/calc\(var\(--radius-lg\) \+ 6px\)/); + }); }); diff --git a/packages/studio/src/components/ui/Menu.tsx b/packages/studio/src/components/ui/Menu.tsx index 6ad219f3ec..ebefc3f04b 100644 --- a/packages/studio/src/components/ui/Menu.tsx +++ b/packages/studio/src/components/ui/Menu.tsx @@ -72,7 +72,7 @@ const menuPopup = cn(popupSurface, "min-w-36 p-1 shadow-menu"); /** One row. `data-highlighted` is set by keyboard and pointer alike, so the seen row is the Enter row. */ const itemBase = cn( - "flex cursor-default select-none items-center justify-between gap-6 rounded-sm px-2 py-1.5", + "flex cursor-default select-none items-center justify-between gap-6 rounded-[calc(var(--radius-lg)+6px)] px-2 py-1.5", "text-step-11 whitespace-nowrap text-text-1", "outline-hidden transition-colors ease-out-quint duration-hover", "data-[highlighted]:bg-hover data-[highlighted]:text-text-0",