-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Configure actions to transition to a different story? #50
Labels
Comments
Wow. Thats a cool feature. |
We can do it like this: import { linkTo } from @kadira/storybook
storiesOf('Toggle', module)
.add('on', () => {
return <Toggle value={true} onChange={linkTo('Toggle', 'off')} />
})
.add('off', () => {
return <Toggle value={false} onChange={linkTo('Toggle', 'on')} />
}); I think this API looks great. |
ndelangen
pushed a commit
that referenced
this issue
Apr 5, 2017
Set NODE_ENV environment variable to development if its not set.
ndelangen
pushed a commit
that referenced
this issue
Apr 23, 2017
Adds new prop primary. It defines which Pane will keep its size.
thani-sh
pushed a commit
that referenced
this issue
May 24, 2017
Update docs for addonAPI.addPanel()
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It would be nice if an action could trigger a transition to a different story to simulate interactivity, similar to how you can create simple prototypes with Invision, Framer.js, etc.
For example, say you have a "Toggle" widget with two states, "on" and "off", it would be nice if you could set up the actions for each story to switch to another story to simulate the toggle actually occurring:
The text was updated successfully, but these errors were encountered: