mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
* ci/announce/highlight - add bot announcement section for "highlights" showing off important diffs + storybook highlights * ci/announce/highlight - fix announcement message * Update index.js * xxx tmp xxx * ci/announce/highlight - fix dirty file calculation * ci/announce/highlight - try/catch wrap highlight generation for build stability * ui - put fox emojis in the mascot component * ci/announce/highlight - start storybook permalinks * ci/announce/highlight - fix storybook permalink util * ci/announce/highlight - fix storybook permalink util * ci/announce/highlight - small styling fix * storybook - use any easily predictable story id * ci/announce/highlight - revert sample commit * ci/announce/highlight - minimal documentation
70 lines
1.3 KiB
JavaScript
70 lines
1.3 KiB
JavaScript
import React from 'react';
|
|
import { action } from '@storybook/addon-actions';
|
|
import { text, boolean } from '@storybook/addon-knobs';
|
|
import Button from '.';
|
|
|
|
export default {
|
|
title: 'Button',
|
|
id: __filename,
|
|
};
|
|
|
|
export const primaryType = () => (
|
|
<Button
|
|
onClick={action('clicked')}
|
|
type="primary"
|
|
disabled={boolean('disabled', false)}
|
|
>
|
|
{text('text', 'Click me')}
|
|
</Button>
|
|
);
|
|
|
|
export const secondaryType = () => (
|
|
<Button
|
|
onClick={action('clicked')}
|
|
type="secondary"
|
|
disabled={boolean('disabled', false)}
|
|
>
|
|
{text('text', 'Click me')}
|
|
</Button>
|
|
);
|
|
|
|
export const defaultType = () => (
|
|
<Button
|
|
onClick={action('clicked')}
|
|
type="default"
|
|
disabled={boolean('disabled', false)}
|
|
>
|
|
{text('text', 'Click me')}
|
|
</Button>
|
|
);
|
|
|
|
export const warningType = () => (
|
|
<Button
|
|
onClick={action('clicked')}
|
|
type="warning"
|
|
disabled={boolean('disabled', false)}
|
|
>
|
|
{text('text', 'Click me')}
|
|
</Button>
|
|
);
|
|
|
|
export const dangerType = () => (
|
|
<Button
|
|
onClick={action('clicked')}
|
|
type="danger"
|
|
disabled={boolean('disabled', false)}
|
|
>
|
|
{text('text', 'Click me')}
|
|
</Button>
|
|
);
|
|
|
|
export const dangerPrimaryType = () => (
|
|
<Button
|
|
onClick={action('clicked')}
|
|
type="danger-primary"
|
|
disabled={boolean('disabled', false)}
|
|
>
|
|
{text('text', 'Click me')}
|
|
</Button>
|
|
);
|