omit Addon prefix from addon stories

This commit is contained in:
MJ Meinders 2017-12-09 13:21:04 +01:00
parent 94e8da1527
commit 748b26e0e9
7 changed files with 16 additions and 16 deletions

View File

@ -5,7 +5,7 @@ import { Button } from '@storybook/react/demo';
const pickFirst = decorateAction([args => args.slice(0, 1)]);
storiesOf('Addons|Addon Actions', module)
storiesOf('Addons|Actions', module)
.add('Hello World', () => <Button onClick={action('hello-world')}>Hello World</Button>)
.add('Decorated Action', () => <Button onClick={pickFirst('decorated')}>First Argument</Button>)
.add('Circular Payload', () => {

View File

@ -6,7 +6,7 @@ import BaseButton from '../components/BaseButton';
const text = 'Testing the a11y addon';
storiesOf('Addons|Addon a11y', module)
storiesOf('Addons|a11y', module)
.addDecorator(checkA11y)
.add('Default', () => <BaseButton label="" />)
.add('Label', () => <BaseButton label={text} />)

View File

@ -4,7 +4,7 @@ import { storiesOf } from '@storybook/react';
import backgrounds from '@storybook/addon-backgrounds';
import BaseButton from '../components/BaseButton';
storiesOf('Addons|Addon Backgrounds', module)
storiesOf('Addons|Backgrounds', module)
.addDecorator(
backgrounds([
{ name: 'twitter', value: '#00aced' },

View File

@ -8,7 +8,7 @@ import FlowTypeButton from '../components/FlowTypeButton';
import BaseButton from '../components/BaseButton';
import TableComponent from '../components/TableComponent';
storiesOf('Addons|Addon Info.React Docgen', module)
storiesOf('Addons|Info.React Docgen', module)
.add(
'Comments from PropType declarations',
withInfo(
@ -39,12 +39,12 @@ const Button = () => <button />;
Maybe include a [link](http://storybook.js.org) to your project as well.
`;
storiesOf('Addons|Addon Info.Markdown', module).add(
storiesOf('Addons|Info.Markdown', module).add(
'Displays Markdown in description',
withInfo(markdownDescription)(() => <BaseButton onClick={action('clicked')} label="Button" />)
);
storiesOf('Addons|Addon Info.Options.inline', module).add(
storiesOf('Addons|Info.Options.inline', module).add(
'Inlines component inside story',
withInfo({
text: 'Component should be inlined between description and PropType table',
@ -52,7 +52,7 @@ storiesOf('Addons|Addon Info.Options.inline', module).add(
})(() => <BaseButton label="Button" />)
);
storiesOf('Addons|Addon Info.Options.header', module).add(
storiesOf('Addons|Info.Options.header', module).add(
'Shows or hides Info Addon header',
withInfo({
text: 'The Info Addon header should be hidden',
@ -60,7 +60,7 @@ storiesOf('Addons|Addon Info.Options.header', module).add(
})(() => <BaseButton label="Button" />)
);
storiesOf('Addons|Addon Info.Options.source', module).add(
storiesOf('Addons|Info.Options.source', module).add(
'Shows or hides Info Addon source',
withInfo({
text: 'The Info Addon source section should be hidden',
@ -68,7 +68,7 @@ storiesOf('Addons|Addon Info.Options.source', module).add(
})(() => <BaseButton label="Button" />)
);
storiesOf('Addons|Addon Info.Options.propTables', module).add(
storiesOf('Addons|Info.Options.propTables', module).add(
'Shows additional component prop tables',
withInfo({
text: 'There should be a prop table added for a component not included in the story',
@ -76,7 +76,7 @@ storiesOf('Addons|Addon Info.Options.propTables', module).add(
})(() => <BaseButton label="Button" />)
);
storiesOf('Addons|Addon Info.Options.propTablesExclude', module).add(
storiesOf('Addons|Info.Options.propTablesExclude', module).add(
'Exclude component from prop tables',
withInfo({
text: 'This can exclude extraneous components from being displayed in prop tables.',
@ -123,7 +123,7 @@ storiesOf('Addons|Info.Options.styles', module)
})(() => <BaseButton label="Button" />)
);
storiesOf('Addons|Addon Info.Options.TableComponent', module).add(
storiesOf('Addons|Info.Options.TableComponent', module).add(
'Use a custom component for the table',
withInfo({
TableComponent,
@ -142,7 +142,7 @@ const Input = hoc(() => <input type="text" />);
const TextArea = hoc(({ children }) => <textarea>{children}</textarea>);
storiesOf('Addons|Addon Info.GitHub issues', module).add(
storiesOf('Addons|Info.GitHub issues', module).add(
'#1814',
withInfo('Allow Duplicate DisplayNames for HOC #1814')(() => (
<div>

View File

@ -8,7 +8,7 @@ const withTestsFiles = withTests({
results,
});
storiesOf('Addons|Addon jest', module)
storiesOf('Addons|jest', module)
.addDecorator(withTestsFiles('addon-jest'))
.add('withTests', () => (
<div>

View File

@ -45,7 +45,7 @@ class AsyncItemLoader extends React.Component {
}
}
storiesOf('Addons|Addon Knobs.withKnobs', module)
storiesOf('Addons|Knobs.withKnobs', module)
.addDecorator(withKnobs)
.add('tweaks static values', () => {
const name = text('Name', 'Storyteller');
@ -97,7 +97,7 @@ storiesOf('Addons|Addon Knobs.withKnobs', module)
</div>
));
storiesOf('Addons|Addon Knobs.withKnobsOptions', module)
storiesOf('Addons|Knobs.withKnobsOptions', module)
.addDecorator(
withKnobsOptions({
debounce: { wait: 100, leading: boolean }, // Same as lodash debounce.

View File

@ -6,7 +6,7 @@ import { action } from '@storybook/addon-actions';
import BaseButton from '../components/BaseButton';
import markdownNotes from './notes/notes.md';
storiesOf('Addons|Addon Notes', module)
storiesOf('Addons|Notes', module)
.add(
'withNotes',
withNotes(