Skip to content
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

Can toolbar addons appear on DocsPage Previews? #10366

Closed
benedfit opened this issue Apr 9, 2020 · 8 comments
Closed

Can toolbar addons appear on DocsPage Previews? #10366

benedfit opened this issue Apr 9, 2020 · 8 comments

Comments

@benedfit
Copy link

benedfit commented Apr 9, 2020

Is your feature request related to a problem? Please describe.
I'd like to be able to use toolbar addons, such as @storybook/addon-backgrounds, in conjunction with DocsPage as per the image shown here: https://github.com/storybookjs/storybook/blob/next/addons/docs/docs/media/hero.png

<Preview withToolbar> currently only renders the default buttons for zooming and opening in a new window.

Describe the solution you'd like
An example of how to configure the docs addon to display the @storybook/addon-backgrounds button

Are you able to assist bring the feature to reality?
yes, I'd be happy to collaborate with someone to make this a reality

@benedfit
Copy link
Author

benedfit commented Apr 9, 2020

Looks like this is related to #6700. I assume there will be some refactoring required before it all works together?

@shilman
Copy link
Member

shilman commented Apr 11, 2020

Also related: #8521

@stale stale bot added the inactive label May 2, 2020
@shilman shilman added this to the 6.0 docs milestone May 17, 2020
@stale stale bot removed the inactive label May 17, 2020
@shilman
Copy link
Member

shilman commented May 17, 2020

gonna close this as dupe to #8521

@shilman shilman closed this as completed May 17, 2020
@shilman shilman reopened this May 17, 2020
@shilman
Copy link
Member

shilman commented May 17, 2020

Sorry this is a different issue. 🙈 reopening

@stale
Copy link

stale bot commented Jun 7, 2020

Hi everyone! Seems like there hasn't been much going on in this issue lately. If there are still questions, comments, or bugs, please feel free to continue the discussion. Unfortunately, we don't have time to get to every issue. We are always open to contributions so please send us a pull request if you would like to help. Inactive issues will be closed after 30 days. Thanks!

@stale stale bot added the inactive label Jun 7, 2020
@storybookjs storybookjs deleted a comment from stale bot Jun 7, 2020
@stale stale bot removed the inactive label Jun 7, 2020
@shilman
Copy link
Member

shilman commented Jun 7, 2020

Each addon registers toolbars for the viewModes that it supports. Most addons only support story mode (AKA "Canvas" in the UI), but some addons can support docs mode as well. For example, I enabled this for the Toolbars addon here: #10810

Closing this. LMK if you think there's more to be done!

@benedfit
Copy link
Author

@shilman thanks. Are there any plans to change some of the other official addons to be available in docs too?

@shilman
Copy link
Member

shilman commented Jul 29, 2020

@benedfit see #6700, hopefully in 6.x

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants