forked from storybookjs/storybook
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.d.ts
32 lines (27 loc) · 881 Bytes
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
import { NgModuleMetadata, ICollection } from './dist/client/preview/angular/types';
export interface IStorybookStory {
name: string;
render: () => any;
}
export interface IStoribookSection {
kind: string;
stories: IStorybookStory[];
}
export type IGetStory = () => {
props?: ICollection;
moduleMetadata?: Partial<NgModuleMetadata>;
component?: any;
template?: string;
};
export interface IApi {
kind: string;
addDecorator: (decorator: any) => IApi;
add: (storyName: string, getStory: IGetStory) => IApi;
}
declare module '@storybook/angular' {
export function storiesOf(kind: string, module: NodeModule): IApi;
export function setAddon(addon: any): void;
export function addDecorator(decorator: any): IApi;
export function configure(loaders: () => NodeRequire, module: NodeModule): void;
export function getStorybook(): IStoribookSection[];
}