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

Addon-actions: Normalize args #13624

Merged

Conversation

guilhermewaess
Copy link
Contributor

@guilhermewaess guilhermewaess commented Jan 12, 2021

Issue: #7764

addon-action now will show results out of an array when it's not an array.

What I did

I added treatment for the args received on addon-actions. Before, it was sending the args forward. Now, when it is only one argument, it will send the argument outside of an array.

Before:

image

After:

image

How to test

  • Is this testable with Jest or Chromatic screenshots?
    I did update the tests
  • Does this need a new example in the kitchen sink apps?
    No
  • Does this need an update to the documentation?
    I don't think so.

If your answer is yes to any of these, please make sure to include it in your PR.

Thanks @yannbf for the guidance :D

addon-action now will now show results out of an array when its not an array.
@shilman shilman changed the title refactor: addon-actions normalized args Addon-actions: Normalized args Jan 13, 2021
@shilman shilman changed the title Addon-actions: Normalized args Addon-actions: Normalize args Jan 13, 2021
@gaetanmaisse
Copy link
Member

LGTM 💪🏻 , I will let @shilman make a double-check.

Copy link
Member

@shilman shilman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking great! 🚀 Thanks @guilhermewaess 🙏

@shilman shilman merged commit 1dd8337 into storybookjs:next Jan 14, 2021
@shilman shilman added this to the 6.2 essentials milestone Jan 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants