UNPKG

@retailmenot/anchor

Version:

A React UI Library by RetailMeNot

34 lines 1.3 kB
// REACT import * as React from 'react'; // STORYBOOK import { storiesOf } from '@storybook/react'; // VENDOR import { text } from '@storybook/addon-knobs'; import styled, { ThemeProvider } from '@xstyled/styled-components'; // COMPONENTS import { Avatar } from './Avatar.component'; import { Typography } from '../Typography'; // README import * as README from './README.md'; // THEME import { RootTheme } from '../theme'; const StyledStory = styled('div') ` padding: 2rem 5rem; background-color: primary.base; color: white; `; storiesOf('Components/Avatar', module) .addParameters({ readme: { sidebar: README, }, }) .add('Default', () => (React.createElement(ThemeProvider, { theme: RootTheme }, React.createElement(StyledStory, null, React.createElement(Typography, { as: "h1" }, "Avatar"), React.createElement(Avatar, null), React.createElement(Typography, { as: "h1" }, "Avatar With Initials"), React.createElement(Avatar, { label: text('Avatar Initials', 'CC') }), React.createElement(Typography, { as: "h1" }, "Avatar With Picture"), React.createElement(Avatar, { src: text('Avatar Url', 'https://avatars3.githubusercontent.com/u/24923730?s=460&v=4') }))))); //# sourceMappingURL=Avatar.stories.js.map