Skip to content

Commit 236ffc2

Browse files
juliusmarmingecodex
andcommitted
fix(web): match paired composer action sizes
Co-authored-by: codex <[email protected]>
1 parent f32dbd7 commit 236ffc2

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

‎apps/web/src/components/chat/ComposerPrimaryActions.test.tsx‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,7 @@ describe("ComposerPrimaryActions", () => {
251251
expect(markup).toContain('aria-label="Stop generation"');
252252
expect(markup).toContain('aria-label="Send message"');
253253
expect(markup).toContain('type="submit"');
254+
expect(markup).toContain("size-9 sm:size-8");
254255
});
255256

256257
it("keeps stop as the only action while running with an empty composer", () => {

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

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,11 @@ export const ComposerPrimaryActions = memo(function ComposerPrimaryActions({
9090
type="button"
9191
className={cn(
9292
"flex cursor-pointer items-center justify-center rounded-full bg-destructive/90 text-white shadow-xs shadow-destructive/24 inset-shadow-[0_1px_--theme(--color-white/16%)] transition-all duration-150 hover:bg-destructive hover:scale-105 active:inset-shadow-[0_1px_--theme(--color-black/8%)] active:shadow-none",
93-
insidePendingAction ? "size-8 sm:size-7" : "size-8 sm:h-8 sm:w-8",
93+
insidePendingAction
94+
? "size-8 sm:size-7"
95+
: showSendWhileRunning && hasSendableContent
96+
? "size-9 sm:size-8"
97+
: "size-8 sm:h-8 sm:w-8",
9498
)}
9599
{...pointerFocusProps}
96100
onClick={onInterrupt}

0 commit comments

Comments
 (0)