import type { AnnotatedStoryFn, Args, PlayFunction, PlayFunctionContext, Store_CSFExports, StoryAnnotations } from '@storybook/types'; import type { ReactRenderer } from '@storybook/react'; export declare type TestingStory = StoryAnnotations; export declare type StoryFile = Store_CSFExports; export declare type TestingStoryPlayContext = Partial> & Pick; export declare type StoryFn = AnnotatedStoryFn & { play: PlayFunction; }; /** * T represents the whole es module of a stories file. K of T means named exports (basically the Story type) * 1. pick the keys K of T that have properties that are Story * 2. infer the actual prop type for each Story * 3. reconstruct Story with Partial. Story -> Story> */ export declare type StoriesWithPartialProps = { [K in keyof T]: T[K] extends StoryAnnotations ? StoryFn> : number; };