Skip to content
This repository has been archived by the owner on May 4, 2023. It is now read-only.

Commit

Permalink
fix: enable show code button
Browse files Browse the repository at this point in the history
  • Loading branch information
virtuoushub committed Apr 1, 2022
1 parent 96473fb commit a404666
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 22 deletions.
4 changes: 2 additions & 2 deletions web/src/components/Article/Article.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ export default {
},
}

export const full = () => {
return <Article {...standard()} />
export const full = (ars) => {
return <Article {...{ ...ars, ...standard() }} />
}

export const summary = ({ summary = true }) => {
Expand Down
16 changes: 8 additions & 8 deletions web/src/components/ArticleCell/ArticleCell.stories.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
import { Loading, Empty, Failure, Success } from './ArticleCell'
import { standard } from './ArticleCell.mock'

export const loading = () => {
return Loading ? <Loading /> : null
export const loading = (args) => {
return Loading ? <Loading {...args} /> : null
}

export const empty = () => {
return Empty ? <Empty /> : null
export const empty = (args) => {
return Empty ? <Empty {...args} /> : null
}

export const failure = () => {
return Failure ? <Failure error={new Error('Oh no')} /> : null
export const failure = (args) => {
return Failure ? <Failure {...args} error={new Error('Oh no')} /> : null
}

export const success = () => {
return Success ? <Success {...standard()} /> : null
export const success = (args) => {
return Success ? <Success {...args} {...standard()} /> : null
}

export default { title: 'Cells/ArticleCell' }
16 changes: 8 additions & 8 deletions web/src/components/ArticlesCell/ArticlesCell.stories.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
import { Loading, Empty, Failure, Success } from './ArticlesCell'
import { standard } from './ArticlesCell.mock'

export const loading = () => {
return Loading ? <Loading /> : null
export const loading = (args) => {
return Loading ? <Loading {...args} /> : null
}

export const empty = () => {
return Empty ? <Empty /> : null
export const empty = (args) => {
return Empty ? <Empty {...args} /> : null
}

export const failure = () => {
return Failure ? <Failure error={new Error('Oh no')} /> : null
export const failure = (args) => {
return Failure ? <Failure error={new Error('Oh no')} {...args} /> : null
}

export const success = () => {
return Success ? <Success {...standard()} /> : null
export const success = (args) => {
return Success ? <Success {...standard()} {...args} /> : null
}

export default { title: 'Cells/ArticlesCell' }
4 changes: 2 additions & 2 deletions web/src/layouts/BlogLayout/BlogLayout.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ import { within } from '@storybook/testing-library'
import { expect } from '@storybook/jest'
import BlogLayout from './BlogLayout'

export const generated = () => {
export const generated = (args) => {
return (
<BlogLayout>
<BlogLayout {...args}>
<></>
</BlogLayout>
)
Expand Down
4 changes: 2 additions & 2 deletions web/src/pages/ArticlePage/ArticlePage.stories.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import ArticlePage from './ArticlePage'

export const generated = () => {
return <ArticlePage />
export const generated = (arg) => {
return <ArticlePage {...arg} />
}

export default { title: 'Pages/ArticlePage' }

0 comments on commit a404666

Please sign in to comment.