[ci] format

This commit is contained in:
matthewp 2023-08-11 17:57:40 +00:00 committed by astrobot-houston
parent 4a145c4c7d
commit 06fa76cec6
2 changed files with 5 additions and 4 deletions

View file

@ -265,8 +265,7 @@ const { fallback = 'animate' } = Astro.props as Props;
link.origin === location.origin &&
!(
// Same page means same path and same query params
location.pathname === link.pathname &&
location.search === link.search
(location.pathname === link.pathname && location.search === link.search)
) &&
ev.button === 0 && // left clicks only
!ev.metaKey && // new tab (mac)

View file

@ -295,7 +295,10 @@ test.describe('View Transitions', () => {
await expect(meta).toHaveAttribute('content', '0');
});
test('Navigating to the same path but with different query params should result in transition', async ({ page, astro }) => {
test('Navigating to the same path but with different query params should result in transition', async ({
page,
astro,
}) => {
const loads = [];
page.addListener('load', (p) => {
loads.push(p.title());
@ -311,7 +314,6 @@ test.describe('View Transitions', () => {
p = page.locator('#query-page');
await expect(p, 'should have content').toHaveText('Page 2');
await expect(loads.length, 'There should only be 1 page load').toEqual(1);
});
});