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

Native knobs: Knobs disappear when using group ids #126

Closed
har0ld-scl opened this issue Oct 30, 2020 · 2 comments
Closed

Native knobs: Knobs disappear when using group ids #126

har0ld-scl opened this issue Oct 30, 2020 · 2 comments
Labels
bug Something isn't working merged

Comments

@har0ld-scl
Copy link

Describe the bug

Using knobs with different group ids between stories causes the knobs of the other stories to not load or display properly.

To Reproduce
Steps to reproduce the behavior:

  1. Create a pair of stories (story A and story B).
  2. Add some knobs to both stories.
  3. Set different groupId names on those knobs.
  4. Open story A and click on one tab (group) that doesn't exists in story B.
  5. Open story B.
  6. The knobs of story B disappear.

Expected behavior

Using different group ids on the knobs should not interfere with the loading of the knobs from other stories.

Screenshots

storybook-knobs-disappear

Code snippets

storiesOf('First component', module)
  .add('First example', () => (
    <View>
      <Text>{text('message', 'Hello first example!', 'Click me')}</Text>
    </View>
  ))
  .add('Second example', () => (
    <View>
      <Text>{text('message', 'Hello second example!', 'Missing tab')}</Text>
    </View>
  ));

System:
Environment Info:

  System:
    OS: macOS 10.15.7
    CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
  Binaries:
    Node: 14.5.0 - /usr/local/bin/node
    npm: 6.14.5 - /usr/local/bin/npm
  Browsers:
    Chrome: 86.0.4240.111
    Safari: 14.0
  npmPackages:
    @storybook/addon-actions: 6.0.27 => 6.0.27
    @storybook/addon-knobs: 6.0.27 => 6.0.27
    @storybook/addon-ondevice-actions: 5.3.23 => 5.3.23
    @storybook/addon-ondevice-knobs: 5.3.23 => 5.3.23
    @storybook/react-native: 5.3.23 => 5.3.23
    @storybook/react-native-server: 5.3.23 => 5.3.23

Additional context

The groupId tab that doesn't exists in the other stories must be active to reproduce the issue.

This occurs both on android and ios either both dev and release mode.

@dannyhw dannyhw added bug Something isn't working good first issue Good for newcomers labels Nov 3, 2020
@dannyhw
Copy link
Member

dannyhw commented Nov 3, 2020

Thats a strange issue, thanks for reporting this, will look into it when I can.

@dannyhw
Copy link
Member

dannyhw commented Nov 22, 2020

Published:

  • @storybook/addon-ondevice-knobs@5.3.24-alpha.0
  • @storybook/react-native@5.3.24-alpha.0

Bug Fixes

Your change is live now in 5.3.24-alpha.0

@dannyhw dannyhw closed this as completed Nov 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working merged
Projects
None yet
Development

No branches or pull requests

2 participants