diff --git a/src/renderer/src/components/tab-bar/TabStripTooltipProvider.test.tsx b/src/renderer/src/components/tab-bar/TabStripTooltipProvider.test.tsx index 798d144f541..afb35a2dde6 100644 --- a/src/renderer/src/components/tab-bar/TabStripTooltipProvider.test.tsx +++ b/src/renderer/src/components/tab-bar/TabStripTooltipProvider.test.tsx @@ -39,9 +39,9 @@ describe('TabStripTooltipProvider', () => { vi.useRealTimers() }) - it('holds the first preview until an 800 ms hover', () => { + it('holds the first preview until a 500 ms hover', () => { hover('first tab') - advance(799) + advance(499) expect(screen.queryByText('Build')).toBeNull() advance(1) expect(screen.getAllByText('Build').length).toBeGreaterThan(0) diff --git a/src/renderer/src/components/tab-bar/TabStripTooltipProvider.tsx b/src/renderer/src/components/tab-bar/TabStripTooltipProvider.tsx index 4d33ac67d00..a6ef31c64ed 100644 --- a/src/renderer/src/components/tab-bar/TabStripTooltipProvider.tsx +++ b/src/renderer/src/components/tab-bar/TabStripTooltipProvider.tsx @@ -1,7 +1,7 @@ import type { ReactNode } from 'react' import { TooltipProvider } from '@/components/ui/tooltip' -export const TAB_TOOLTIP_DELAY_MS = 800 +export const TAB_TOOLTIP_DELAY_MS = 500 export function TabStripTooltipProvider({ children }: { children: ReactNode }): React.JSX.Element { return ( diff --git a/tests/e2e/tab-hover-card.spec.ts b/tests/e2e/tab-hover-card.spec.ts index 0e2c560ea38..7070993bc1a 100644 --- a/tests/e2e/tab-hover-card.spec.ts +++ b/tests/e2e/tab-hover-card.spec.ts @@ -40,7 +40,7 @@ test('whole-tab hover cards wait independently on every hover', async ({ // The left padding and icon used to sit outside the terminal title's trigger. await orcaPage.mouse.move(firstBox.x + 3, firstBox.y + firstBox.height / 2) - await orcaPage.waitForTimeout(600) + await orcaPage.waitForTimeout(300) await expect(card).toHaveCount(0) await expect(cardTitle).toHaveText('Build and test the hover cards') const program = card.locator('[data-tab-hover-card-program]') @@ -50,7 +50,7 @@ test('whole-tab hover cards wait independently on every hover', async ({ const programBox = await program.boundingBox() expect(programBox?.y).toBeGreaterThan((titleBox?.y ?? 0) + (titleBox?.height ?? 0)) await orcaPage.mouse.move(secondBox.x + 3, secondBox.y + secondBox.height / 2) - await orcaPage.waitForTimeout(600) + await orcaPage.waitForTimeout(300) await expect(card).toHaveCount(0) await expect(cardTitle).toHaveText('Review changes') @@ -64,7 +64,7 @@ test('whole-tab hover cards wait independently on every hover', async ({ await expect(card).toHaveCount(0) await orcaPage.mouse.move(firstBox.x + 3, firstBox.y + firstBox.height / 2) - await orcaPage.waitForTimeout(600) + await orcaPage.waitForTimeout(300) await expect(card).toHaveCount(0) await expect(cardTitle).toHaveText('Build and test the hover cards') @@ -72,7 +72,7 @@ test('whole-tab hover cards wait independently on every hover', async ({ await orcaPage.mouse.move(firstBox.x + 3, firstBox.y + firstBox.height + 100) await expect(card).toHaveCount(0) await orcaPage.mouse.move(firstBox.x + 3, firstBox.y + firstBox.height / 2) - await orcaPage.waitForTimeout(600) + await orcaPage.waitForTimeout(300) await expect(card).toHaveCount(0) await expect(cardTitle).toHaveText('Build and test the hover cards')