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

isToolsShown parameter doesn't disable toolbar on initial load when set to false (on mdx Meta tag) #11924

Closed
Gideon28 opened this issue Aug 12, 2020 · 4 comments

Comments

@Gideon28
Copy link

Gideon28 commented Aug 12, 2020

When updating from Storybook 5.3 to 6, our setting on the introduction page to hide the toolbar doesn't work. Navigating to other documentation pages and returning correctly removes it, but a refresh confirms that this isn't the case on first load.

To Reproduce
Steps to reproduce the behavior:

  1. In preview.js we have added a parameter with options: isToolsShown: true (so that the toolbar re-appears unless otherwise disabled).
import { addParameters } from "@storybook/react";

addParameters({
  ...
  options: {
    ...
    // Toggle toolbar on by default - override per story if unwanted
    isToolshown: true,
  }
});
  1. Our intro.story.mdx sets this parameter to false on the Meta tag from addon-docs, i.e.
import { Meta } from "@storybook/addon-docs/blocks";

<Meta
 title="Documentation/Introduction"
 parameters={{ options: { isToolshown: false } }}
/>
  1. The introduction page loads initially with the toolbar visible, until navigating around produces the expected behaviour.

System:

  • React 16.13
  • Storybook 6.0.3
  • Addon-docs 6.0.3
@stale
Copy link

stale bot commented Sep 2, 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 Sep 2, 2020
@shilman shilman closed this as completed in 82db9c2 Sep 2, 2020
@shilman
Copy link
Member

shilman commented Sep 3, 2020

w00t!! I just released https://github.com/storybookjs/storybook/releases/tag/v6.1.0-alpha.3 containing PR #11938 that references this issue. Upgrade today to try it out!

You can find this prerelease on the @next NPM tag.

@shilman
Copy link
Member

shilman commented Sep 26, 2020

Yay!! I just released https://github.com/storybookjs/storybook/releases/tag/v6.0.22 containing PR #11938 that references this issue. Upgrade today to try it out!

@dimitrieh
Copy link

@shilman do you know if this is truly fixed? I still seem to be getting this issue, though subsequent load it is gone? Preview.js features:

options: {
    isToolshown: false,

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

4 participants