Skip to content

Commit

Permalink
Add storybook story for DropdownMenu component
Browse files Browse the repository at this point in the history
  • Loading branch information
brentswisher committed Apr 17, 2020
1 parent 4f12cf3 commit 06b33eb
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions packages/components/src/dropdown-menu/stories/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
/**
* External dependencies
*/
import { text, object } from '@storybook/addon-knobs';

/**
* Internal dependencies
*/
import DropdownMenu from '../';

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

export const _default = () => {
const label = text( 'Label', 'Select a direction.' );
const icon = text( 'Icon', 'ellipsis' );
const controls = object( 'Controls', [
{
title: 'Up',
icon: 'arrow-up',
},
{
title: 'Down',
icon: 'arrow-down',
},
] );
return <DropdownMenu icon={ icon } label={ label } controls={ controls } />;
};

0 comments on commit 06b33eb

Please sign in to comment.