diff --git a/code/renderers/react/src/public-types.test.tsx b/code/renderers/react/src/public-types.test.tsx index 51b0eb6e37e4..1711434494b2 100644 --- a/code/renderers/react/src/public-types.test.tsx +++ b/code/renderers/react/src/public-types.test.tsx @@ -79,7 +79,7 @@ describe('Args can be provided in multiple ways', () => { }); test('Component can be used as generic parameter for StoryObj', () => { - type Expected = ReactStory; + type Expected = ReactStory>; expectTypeOf>().toEqualTypeOf(); }); }); diff --git a/code/renderers/react/src/public-types.ts b/code/renderers/react/src/public-types.ts index 811ca5ed5bff..6a7350fd10ef 100644 --- a/code/renderers/react/src/public-types.ts +++ b/code/renderers/react/src/public-types.ts @@ -53,11 +53,7 @@ export type StoryObj = TMetaOrCmpOrArgs extends { > : never : TMetaOrCmpOrArgs extends ComponentType - ? StoryAnnotations< - ReactFramework, - ComponentProps, - ComponentProps - > + ? StoryAnnotations> : StoryAnnotations; type ActionArgs = { diff --git a/code/renderers/svelte/src/public-types.test.ts b/code/renderers/svelte/src/public-types.test.ts index 79663ebd8e1e..a0edd3d36151 100644 --- a/code/renderers/svelte/src/public-types.test.ts +++ b/code/renderers/svelte/src/public-types.test.ts @@ -141,7 +141,7 @@ describe('StoryObj', () => { SvelteStory< Button, { disabled: boolean; label: string }, - { disabled: boolean; label: string } + { disabled?: boolean; label?: string } > >(); }); diff --git a/code/renderers/svelte/src/public-types.ts b/code/renderers/svelte/src/public-types.ts index 2e3d7a9443cf..4040033a7f57 100644 --- a/code/renderers/svelte/src/public-types.ts +++ b/code/renderers/svelte/src/public-types.ts @@ -49,11 +49,7 @@ export type StoryObj = MetaOrCmpOrArgs extends { > : never : MetaOrCmpOrArgs extends SvelteComponentTyped - ? StoryAnnotations< - SvelteFramework, - ComponentProps, - ComponentProps - > + ? StoryAnnotations, ComponentProps> : StoryAnnotations; export type DecoratorFn = DecoratorFunction;