Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cli: webpack react stories homogenization #10709

Merged
merged 1 commit into from
May 11, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react';

import { action } from '@storybook/addon-actions';
import { linkTo } from '@storybook/addon-links';
import { Button } from '@storybook/react/demo';

export default {
Expand All @@ -19,5 +19,30 @@ export const Emoji = () => (
);

Emoji.story = {
name: 'with emoji',
parameters: { notes: 'My notes on a button with emojis' },
};

export const WithSomeEmojiAndAction = () => (
<Button onClick={action('This was clicked')}>
<span role="img" aria-label="so cool">
😀 😎 👍 💯
</span>
</Button>
);

WithSomeEmojiAndAction.story = {
name: 'with some emoji and action',
parameters: { notes: 'My notes on a button with emojis' },
};

export const ButtonWithLinkToAnotherStory = () => (
<Button onClick={linkTo('Welcome')}>
<span role="img" aria-label="so cool">
Go to Welcome Story
</span>
</Button>
);

ButtonWithLinkToAnotherStory.story = {
name: 'button with link to another story',
};