Sticker Creator
This commit is contained in:

committed by
Scott Nonnenberg

parent
2df1ba6e61
commit
11d47a8eb9
20
sticker-creator/elements/LabeledInput.stories.tsx
Normal file
20
sticker-creator/elements/LabeledInput.stories.tsx
Normal file
@@ -0,0 +1,20 @@
|
||||
import * as React from 'react';
|
||||
import { StoryRow } from './StoryRow';
|
||||
import { LabeledInput } from './LabeledInput';
|
||||
|
||||
import { storiesOf } from '@storybook/react';
|
||||
import { text } from '@storybook/addon-knobs';
|
||||
|
||||
storiesOf('Sticker Creator/elements', module).add('LabeledInput', () => {
|
||||
const child = text('label', 'foo bar');
|
||||
const placeholder = text('placeholder', 'foo bar');
|
||||
const [value, setValue] = React.useState('');
|
||||
|
||||
return (
|
||||
<StoryRow>
|
||||
<LabeledInput value={value} onChange={setValue} placeholder={placeholder}>
|
||||
{child}
|
||||
</LabeledInput>
|
||||
</StoryRow>
|
||||
);
|
||||
});
|
Reference in New Issue
Block a user