import React from 'react'; import uuid from 'uuid/v4'; import { Input } from '@meetfranz/forms'; import { storiesOf } from '../stores/stories'; const defaultProps = () => { const id = uuid(); return { label: 'Label', id: `test-${id}`, name: `test-${id}`, onChange: (e: React.ChangeEvent) => console.log('changed event', e), }; }; const defaultPasswordProps = () => { const id = uuid(); return { label: 'Password', id: `test-${id}`, name: `test-${id}`, type: 'password', onChange: (e: React.ChangeEvent) => console.log('changed event', e), }; }; storiesOf('Input') .add('Basic', () => ( )) .add('Without Label', () => ( )) .add('Disabled', () => ( )) .add('With prefix', () => ( )) .add('With suffix', () => ( )) .add('With pre-suffix', () => ( )) .add('With error', () => ( )) .add('Type number with min & max', () => ( )); storiesOf('Password') .add('Basic', () => ( )) .add('Show password toggle', () => ( )) .add('Score password', () => ( )) .add('Score password with error', () => ( ));