wix-style-react
Version:
wix-style-react
41 lines (39 loc) • 1.58 kB
JavaScript
import React from 'react';
import { storiesOf } from '@storybook/react';
import Markdown from 'wix-storybook-utils/Markdown';
import TabbedView from 'wix-storybook-utils/TabbedView';
import CodeExample from 'wix-storybook-utils/CodeExample';
import InputExample, { InputValidationErrorExample, InputWithCustomErrorExample, InputWithCustomStyleExample } from './InputExample';
import InputExampleRaw from '!raw-loader!./InputExample';
import WixStyleDecorator from '../decorators/WixStyleDecorator';
import Readme from '../../../src/TPA/Input/README.md';
import ReadmeTestKit from '../../../src/TPA/FloatingTabs/README.TESTKIT.md';
storiesOf('TPA', module).addDecorator(WixStyleDecorator).add('Input', function () {
return React.createElement(
TabbedView,
{ tabs: ['API', 'TestKits'] },
React.createElement(
'div',
null,
React.createElement(Markdown, { source: Readme }),
React.createElement(
'h1',
null,
'Example'
),
React.createElement(
CodeExample,
{ title: 'Default Input', code: InputExampleRaw },
React.createElement('br', null),
React.createElement(InputExample, null),
React.createElement('br', null),
React.createElement(InputValidationErrorExample, null),
React.createElement('br', null),
React.createElement(InputWithCustomStyleExample, null),
React.createElement('br', null),
React.createElement(InputWithCustomErrorExample, null)
)
),
React.createElement(Markdown, { source: ReadmeTestKit })
);
});