fix(app): restore tabs without layout flicker

This commit is contained in:
Mohamed Boudra
2026-08-18 00:21:51 +02:00
parent ed8371d083
commit 2538dd1e7b
18 changed files with 86 additions and 59 deletions
@@ -58,7 +58,7 @@ function inFlightTurn(page: Page) {
async function openForkMenu(page: Page, trigger: ReturnType<Page["getByRole"]>): Promise<void> {
await trigger.click();
await expect(page.getByRole("button", { name: "Fork in a new tab" })).toBeVisible({
await expect(page.getByRole("menuitem", { name: "Fork in a new tab" })).toBeVisible({
timeout: 10_000,
});
}
@@ -80,7 +80,7 @@ export async function openMostRecentAssistantForkMenu(page: Page): Promise<void>
export async function forkMostRecentAssistantTurnToNewTab(page: Page): Promise<void> {
await openMostRecentAssistantForkMenu(page);
await page.getByRole("button", { name: "Fork in a new tab" }).click();
await page.getByRole("menuitem", { name: "Fork in a new tab" }).click();
}
export async function expectInFlightForkAvailable(page: Page): Promise<void> {
@@ -92,12 +92,12 @@ export async function expectInFlightForkAvailable(page: Page): Promise<void> {
export async function forkInFlightTurnToNewTab(page: Page): Promise<void> {
const trigger = inFlightTurn(page).getByRole("button", { name: "Fork chat" });
await openForkMenu(page, trigger);
await page.getByRole("button", { name: "Fork in a new tab" }).click();
await page.getByRole("menuitem", { name: "Fork in a new tab" }).click();
}
export async function forkMostRecentAssistantTurnToNewWorkspace(page: Page): Promise<void> {
await openMostRecentAssistantForkMenu(page);
await page.getByRole("button", { name: "Fork in a new workspace" }).click();
await page.getByRole("menuitem", { name: "Fork in a new workspace" }).click();
}
export async function expectChatHistoryAttachment(page: Page): Promise<void> {