2019-12-31 12:01:43 +08:00
|
|
|
// import { Button } from '@storybook/react/demo';
|
|
|
|
import { storiesOf } from '@storybook/react';
|
|
|
|
import React from 'react';
|
2020-02-14 10:10:54 +08:00
|
|
|
import DefaultShape from './component/default-shape';
|
2020-03-05 18:24:40 +08:00
|
|
|
import Image from './component/image';
|
2020-02-26 23:17:48 +08:00
|
|
|
import CustomNode from './component/custom-node';
|
2020-03-20 17:24:20 +08:00
|
|
|
import Polyline from './component/polyline';
|
2020-03-30 15:02:01 +08:00
|
|
|
import Image2 from './component/image2';
|
2020-04-15 20:02:25 +08:00
|
|
|
import Quadratic from './component/quadratic';
|
2020-04-27 20:28:33 +08:00
|
|
|
import HideItem from './component/hide-item';
|
2020-05-11 11:15:55 +08:00
|
|
|
import Arc from './component/arc';
|
2019-12-31 12:01:43 +08:00
|
|
|
|
|
|
|
export default { title: 'Shape' };
|
|
|
|
|
|
|
|
storiesOf('Shape', module)
|
2020-04-27 20:28:33 +08:00
|
|
|
.add('default node', () => (
|
|
|
|
// 一个 add 表示添加一个 story
|
|
|
|
<DefaultShape />
|
|
|
|
))
|
|
|
|
.add('image node', () => (
|
|
|
|
// 一个 add 表示添加一个 story
|
|
|
|
<Image />
|
|
|
|
))
|
|
|
|
.add('image node 2', () => (
|
|
|
|
// 一个 add 表示添加一个 story
|
|
|
|
<Image2 />
|
|
|
|
))
|
|
|
|
.add('custom node', () => (
|
|
|
|
<CustomNode />
|
|
|
|
))
|
|
|
|
.add('polyline', () => (
|
|
|
|
<Polyline />
|
|
|
|
))
|
|
|
|
.add('quadratic', () => (
|
|
|
|
<Quadratic />
|
|
|
|
))
|
2020-05-11 11:15:55 +08:00
|
|
|
.add('arc', () => (
|
|
|
|
<Arc />
|
|
|
|
))
|
2020-04-27 20:28:33 +08:00
|
|
|
.add('hide item', () => (
|
|
|
|
<HideItem />
|
|
|
|
));
|