mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-04 13:41:18 +08:00
53 lines
1.4 KiB
JSON
53 lines
1.4 KiB
JSON
{
|
|
"title": "Addons/Controls",
|
|
"parameters": {
|
|
"options": { "selectedPanel": "storybook/controls/panel" }
|
|
},
|
|
"stories": [
|
|
{
|
|
"name": "Simple",
|
|
"parameters": {
|
|
"server": { "id": "addons/controls/simple" }
|
|
},
|
|
"args": { "name": "John Doe", "age": 44 }
|
|
},
|
|
{
|
|
"name": "CSS transitions",
|
|
"parameters": {
|
|
"server": { "id": "addons/controls/css" }
|
|
},
|
|
"args": { "name": "John Doe", "color": "orangered" },
|
|
"argTypes": {
|
|
"color": { "control": { "type": "color"} }
|
|
}
|
|
},
|
|
{
|
|
"name": "All Controls",
|
|
"parameters": {
|
|
"server": { "id": "addons/controls/all" }
|
|
},
|
|
"args": {
|
|
"name": "Jane",
|
|
"stock": 20,
|
|
"fruit": "apples",
|
|
"price": 2.25,
|
|
"colour": "deeppink",
|
|
"today": "Jan 20 2017 GMT+0",
|
|
"items": ["Laptop", "Book", "Whiskey"],
|
|
"nice": true,
|
|
"other": {"hair": "brown", "eyes": "blue"}
|
|
},
|
|
"argTypes": {
|
|
"stock": { "control": { "type": "range", "min": 0, "max": 30, "step": 5} },
|
|
"fruit": { "control": { "type": "select", "options": {
|
|
"Apple": "apples",
|
|
"Banana": "bananas",
|
|
"Cherry": "cherries"
|
|
}} },
|
|
"colour": { "control": { "type": "color"} },
|
|
"today": { "control": { "type": "date"} }
|
|
}
|
|
}
|
|
]
|
|
}
|