mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-08 11:11:53 +08:00
Fix controls annotation typo
This commit is contained in:
parent
b205f31183
commit
1ce56a4ed8
@ -337,8 +337,7 @@ export default {
|
||||
component: Widget,
|
||||
argTypes: {
|
||||
loadingState: {
|
||||
type: 'inline-radio',
|
||||
options: ['loading', 'error', 'ready'],
|
||||
control: { type: 'inline-radio', options: ['loading', 'error', 'ready'] },
|
||||
},
|
||||
},
|
||||
};
|
||||
@ -351,7 +350,9 @@ export default {
|
||||
title: 'Gizmo',
|
||||
component: Gizmo,
|
||||
argTypes: {
|
||||
width: { type: 'range', min: 400, max: 1200, step: 50 };
|
||||
width: {
|
||||
control: { type: 'range', min: 400, max: 1200, step: 50 },
|
||||
},
|
||||
},
|
||||
};
|
||||
```
|
||||
@ -473,7 +474,9 @@ export const Reflow = ({ count, label, ...args }) => (
|
||||
<>{range(count).map((i) => <Button label={`${label} ${i}` {...args}} />)}</>
|
||||
);
|
||||
Reflow.args = { count: 3, label: 'reflow' };
|
||||
Reflow.argTypes = { count: { control: { type: 'range', min: 0, max: 20 } } };
|
||||
Reflow.argTypes = {
|
||||
count: { control: { type: 'range', min: 0, max: 20 } }
|
||||
};
|
||||
```
|
||||
|
||||
### My controls aren't being auto-generated. What should I do?
|
||||
|
Loading…
x
Reference in New Issue
Block a user