1 | import { Addon_ClientStoryApi, Addon_Loadable, Args, ComponentAnnotations, AnnotatedStoryFn, ArgsStoryFn, StoryAnnotations, ArgsFromMeta, StrictArgs, DecoratorFunction, LoaderFunction, StoryContext as StoryContext$1, ProjectAnnotations } from '@storybook/types';
|
2 | export { ArgTypes, Args, Parameters, StrictArgs } from '@storybook/types';
|
3 | import { V as VueRenderer } from './types-317e5359.js';
|
4 | import { Simplify, SetOptional } from 'type-fest';
|
5 | import { Component } from 'vue';
|
6 | import { ExtendedVue } from 'vue/types/vue';
|
7 |
|
8 | interface ClientApi extends Addon_ClientStoryApi<VueRenderer['storyResult']> {
|
9 | configure(loader: Addon_Loadable, module: NodeModule): void;
|
10 | forceReRender(): void;
|
11 | raw: () => any;
|
12 | load: (...args: any[]) => void;
|
13 | }
|
14 | declare const storiesOf: ClientApi['storiesOf'];
|
15 | declare const configure: ClientApi['configure'];
|
16 | declare const forceReRender: ClientApi['forceReRender'];
|
17 | declare const raw: ClientApi['raw'];
|
18 |
|
19 | /**
|
20 | * Metadata to configure the stories for a component.
|
21 | *
|
22 | * @see [Default export](https://storybook.js.org/docs/formats/component-story-format/#default-export)
|
23 | */
|
24 | type Meta<TCmpOrArgs = Args> = ComponentAnnotations<VueRenderer, ComponentPropsOrProps<TCmpOrArgs>>;
|
25 | /**
|
26 | * Story function that represents a CSFv2 component example.
|
27 | *
|
28 | * @see [Named Story exports](https://storybook.js.org/docs/formats/component-story-format/#named-story-exports)
|
29 | */
|
30 | type StoryFn<TCmpOrArgs = Args> = AnnotatedStoryFn<VueRenderer, ComponentPropsOrProps<TCmpOrArgs>>;
|
31 | /**
|
32 | * Story function that represents a CSFv3 component example.
|
33 | *
|
34 | * @see [Named Story exports](https://storybook.js.org/docs/formats/component-story-format/#named-story-exports)
|
35 | */
|
36 | type StoryObj<TMetaOrCmpOrArgs = Args> = TMetaOrCmpOrArgs extends {
|
37 | render?: ArgsStoryFn<VueRenderer, any>;
|
38 | component?: infer C;
|
39 | args?: infer DefaultArgs;
|
40 | } ? TMetaOrCmpOrArgs extends Component<any> ? StoryAnnotations<VueRenderer, ComponentPropsOrProps<TMetaOrCmpOrArgs>> : Simplify<ComponentProps<C> & ArgsFromMeta<VueRenderer, TMetaOrCmpOrArgs>> extends infer TArgs ? StoryAnnotations<VueRenderer, TArgs, SetOptional<TArgs, Extract<keyof TArgs, keyof DefaultArgs>>> : never : StoryAnnotations<VueRenderer, ComponentPropsOrProps<TMetaOrCmpOrArgs>>;
|
41 | type ComponentProps<C> = C extends ExtendedVue<any, any, any, any, infer P> ? P : C extends Component<any, any, any, infer P> ? P : unknown;
|
42 | type ComponentPropsOrProps<TCmpOrArgs> = TCmpOrArgs extends Component<any> ? unknown extends ComponentProps<TCmpOrArgs> ? TCmpOrArgs : ComponentProps<TCmpOrArgs> : TCmpOrArgs;
|
43 |
|
44 |
|
45 |
|
46 |
|
47 |
|
48 |
|
49 |
|
50 |
|
51 |
|
52 | type Story<TArgs = Args> = StoryFn<TArgs>;
|
53 | type Decorator<TArgs = StrictArgs> = DecoratorFunction<VueRenderer, TArgs>;
|
54 | type Loader<TArgs = StrictArgs> = LoaderFunction<VueRenderer, TArgs>;
|
55 | type StoryContext<TArgs = StrictArgs> = StoryContext$1<VueRenderer, TArgs>;
|
56 | type Preview = ProjectAnnotations<VueRenderer>;
|
57 |
|
58 | export { Decorator, Loader, Meta, Preview, Story, StoryContext, StoryFn, StoryObj, VueRenderer, configure, forceReRender, raw, storiesOf };
|