Skip to content

Commit

Permalink
Storybook: Add knobs to ColorIndicator (#18015)
Browse files Browse the repository at this point in the history
* Add knobs to ColorIndicator

* Lint: new line
  • Loading branch information
mkaz authored and hypest committed Nov 4, 2019
1 parent 4ad540d commit c70f454
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions packages/components/src/color-indicator/stories/index.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,21 @@
/**
* External dependencies
*/
import { text } from '@storybook/addon-knobs';

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

export default {
title: 'Color Indicator',
title: 'ColorIndicator',
component: ColorIndicator,
};

export const _default = () => (
<ColorIndicator colorValue="#0073aa" />
);
export const _default = () => {
const color = text( 'Color', '#0073aa' );
return (
<ColorIndicator colorValue={ color } />
);
};

0 comments on commit c70f454

Please sign in to comment.