From ccf832bb5fbc4e6d89ac214c47ab629fd5a40da8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Burak=20Boduro=C4=9Flu?= <80620802+burakboduroglu@users.noreply.github.com> Date: Tue, 15 Sep 2026 22:06:18 +0300 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=93=B1=20prevent=20mobile=20compos?= =?UTF-8?q?e=20header=20overflow?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../exams/bank-question-picker.test.tsx | 17 +++++++++++++++++ src/components/messages/gmail-compose-box.tsx | 4 ++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/src/components/exams/bank-question-picker.test.tsx b/src/components/exams/bank-question-picker.test.tsx index bf9e4de..fa4ac69 100644 --- a/src/components/exams/bank-question-picker.test.tsx +++ b/src/components/exams/bank-question-picker.test.tsx @@ -38,3 +38,20 @@ test("insert stays disabled until a target subject is explicitly picked", async await Promise.resolve(); expect(onInsert).toHaveBeenCalledWith("bq-1", "s-1"); }); + +test("cancel delegates to the owning panel", () => { + const onCancel = vi.fn(); + render(() => ( + + {}} + onCancel={onCancel} + /> + + )); + + fireEvent.click(screen.getByRole("button", { name: "Cancel" })); + + expect(onCancel).toHaveBeenCalledOnce(); +}); diff --git a/src/components/messages/gmail-compose-box.tsx b/src/components/messages/gmail-compose-box.tsx index 65bd5d0..25d0657 100644 --- a/src/components/messages/gmail-compose-box.tsx +++ b/src/components/messages/gmail-compose-box.tsx @@ -86,9 +86,9 @@ export function GmailComposeBox(props: GmailComposeBoxProps) { > {/* Gmail Header */}
-
+
-

+

{subject() ? subject() : t("messages.newMessage")}