1 | import * as React from 'react';
|
2 | import { storiesOf } from '@storybook/react';
|
3 | import styled from 'styled-components';
|
4 |
|
5 | import { Accordion } from '../src';
|
6 |
|
7 | const Label = styled.p``;
|
8 |
|
9 |
|
10 | storiesOf('Accordion', module)
|
11 | .add('Default', () => (
|
12 | <Accordion
|
13 | items={[
|
14 | { header: 'header', content: 'conteudo' },
|
15 | {
|
16 | header: 'header',
|
17 | content: <React.Fragment><p>fasdfsdf</p><p>asdfsdfsd</p></React.Fragment>,
|
18 | labels: <Label>Novo</Label>
|
19 | },
|
20 | { header: 'header 3', content: 'conteudoas'}
|
21 | ]}
|
22 | />
|
23 | ))
|
24 | .add('automatic', () => (
|
25 | <Accordion
|
26 | automatic
|
27 | items={[
|
28 | { header: <h1>Header</h1>, content: 'conteudo' },
|
29 | { header: <h2>Header 2</h2>, content: <React.Fragment><p>fasdfsdf</p><p>asdfsdfsd</p></React.Fragment>},
|
30 | { header: 'header 3', content: 'conteudoas'}
|
31 | ]}
|
32 | />
|
33 | )); |
\ | No newline at end of file |