Skip to content

Commit

Permalink
Add storybook story to the Tooltip component
Browse files Browse the repository at this point in the history
  • Loading branch information
brentswisher committed Feb 21, 2020
1 parent bd82bd4 commit 9fbd6b7
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions packages/components/src/tooltip/stories/index.js
@@ -0,0 +1,24 @@
/**
* External dependencies
*/
import { text } from '@storybook/addon-knobs';

/**
* Internal dependencies
*/
import Tooltip from '../';
import Button from '../../button';

export default {
title: 'Components/ToolTip',
component: Tooltip,
};

export const _default = () => {
const tooltipText = text( 'Text', 'More information' );
return (
<Tooltip text={ tooltipText }>
<Button isSecondary>Hover for more information</Button>
</Tooltip>
);
};

0 comments on commit 9fbd6b7

Please sign in to comment.