mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-07 21:31:48 +08:00
34 lines
518 B
Plaintext
34 lines
518 B
Plaintext
```js
|
|
// Button.stories.js
|
|
|
|
import Button from './Button.svelte';
|
|
|
|
export default {
|
|
component: Button,
|
|
title:'Components/Button'
|
|
}
|
|
|
|
export const Primary = () => ({
|
|
Component: Button,
|
|
props: {
|
|
background: '#ff0',
|
|
label: 'Button',
|
|
},
|
|
});
|
|
|
|
export const Secondary = () => ({
|
|
Component: Button,
|
|
props: {
|
|
background: '#ff0',
|
|
label: '😄👍😍💯',
|
|
},
|
|
});
|
|
|
|
export const Tertiary = () => ({
|
|
Component: Button,
|
|
props: {
|
|
background: '#ff0',
|
|
label: '📚📕📈🤓',
|
|
},
|
|
});
|
|
``` |