Skip to content

Commit 7fd37f0

Browse files
fix(web): approval buttons keep even corners
The banner gave its last action button a larger top-right radius to nest inside its own corner. The approval banner's spacious padding already makes the default radius nest, so Approve came out lopsided once Claude dropped the "…" menu. Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent fc73375 commit 7fd37f0

1 file changed

Lines changed: 11 additions & 6 deletions

File tree

‎apps/web/src/components/chat/ComposerBanner.tsx‎

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -160,13 +160,18 @@ function Root({
160160
density === "comfortable" && "[--composer-banner-padding-block:--spacing(1.25)]",
161161
density === "spacious" && "px-3 [--composer-banner-padding-block:--spacing(3)]",
162162
width === "content" ? "w-fit max-w-full flex-none" : "@container",
163-
"[&>[data-composer-banner-row]:first-child>[data-slot=composer-banner-actions]>[data-slot=button]:last-child]:rounded-se-xl",
164-
"[&>[data-composer-banner-row]:first-child>[data-slot=composer-banner-actions]>:last-child>[data-slot=button]:last-of-type]:rounded-se-xl",
165-
"[&>:first-child>[data-composer-banner-row]:first-child>[data-slot=composer-banner-actions]>[data-slot=button]:last-child]:rounded-se-xl",
166-
placement === "floating" && [
167-
"[&>[data-composer-banner-row]:only-child>[data-slot=composer-banner-actions]>[data-slot=button]:last-child]:rounded-ee-xl",
168-
"[&>[data-composer-banner-row]:only-child>[data-slot=composer-banner-actions]>:last-child>[data-slot=button]:last-of-type]:rounded-ee-xl",
163+
// A corner button nests inside the banner's radius only when the padding
164+
// is tight; spacious padding already leaves the default radius concentric.
165+
density !== "spacious" && [
166+
"[&>[data-composer-banner-row]:first-child>[data-slot=composer-banner-actions]>[data-slot=button]:last-child]:rounded-se-xl",
167+
"[&>[data-composer-banner-row]:first-child>[data-slot=composer-banner-actions]>:last-child>[data-slot=button]:last-of-type]:rounded-se-xl",
168+
"[&>:first-child>[data-composer-banner-row]:first-child>[data-slot=composer-banner-actions]>[data-slot=button]:last-child]:rounded-se-xl",
169169
],
170+
placement === "floating" &&
171+
density !== "spacious" && [
172+
"[&>[data-composer-banner-row]:only-child>[data-slot=composer-banner-actions]>[data-slot=button]:last-child]:rounded-ee-xl",
173+
"[&>[data-composer-banner-row]:only-child>[data-slot=composer-banner-actions]>:last-child>[data-slot=button]:last-of-type]:rounded-ee-xl",
174+
],
170175
className,
171176
)}
172177
data-slot="composer-banner"

0 commit comments

Comments
 (0)