-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(react): clickable story updated csf2 to csf3
- Loading branch information
Showing
1 changed file
with
11 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,20 @@ | ||
import { action } from '@storybook/addon-actions' | ||
import Clickable from '.' | ||
import { StoryObj } from '@storybook/react' | ||
|
||
export default { | ||
title: 'Clickable', | ||
component: Clickable, | ||
} | ||
|
||
export const Button = () => ( | ||
<Clickable onClick={action('click')}>button</Clickable> | ||
) | ||
export const Button: StoryObj = { | ||
render: () => <Clickable onClick={action('click')}>button</Clickable>, | ||
} | ||
|
||
export const Link = () => ( | ||
<Clickable to="#" onClick={action('click')}> | ||
link | ||
</Clickable> | ||
) | ||
export const Link: StoryObj = { | ||
render: () => ( | ||
<Clickable to="#" onClick={action('click')}> | ||
link | ||
</Clickable> | ||
), | ||
} |