diff --git a/packages/playwright-ct-svelte/index.d.ts b/packages/playwright-ct-svelte/index.d.ts index c2eab38902..868251730a 100644 --- a/packages/playwright-ct-svelte/index.d.ts +++ b/packages/playwright-ct-svelte/index.d.ts @@ -34,23 +34,20 @@ export type PlaywrightTestConfig = Omit & { } }; +export interface MountOptions> { + props?: Props, + slots?: Record, + on?: Record, + hooksConfig?: any, +} + interface MountResult extends Locator { unmount(): Promise; } interface ComponentFixtures { - mount(component: any, options?: { - props?: { [key: string]: any }, - slots?: { [key: string]: any }, - on?: { [key: string]: Function }, - hooksConfig?: any, - }): Promise; - mount(component: any, options: { - props: Props, - slots?: { [key: string]: any }, - on?: { [key: string]: Function }, - hooksConfig?: any, - }): Promise; + mount(component: any, options?: MountOptions): Promise; + mount(component: any, options: MountOptions>): Promise; } export const test: TestType<