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

Fix addons panel when using preact #3882

Merged
merged 6 commits into from
Jul 18, 2018
Merged

Fix addons panel when using preact #3882

merged 6 commits into from
Jul 18, 2018

Conversation

sanpoChew
Copy link
Contributor

@sanpoChew sanpoChew commented Jul 13, 2018

Issue:

Addons such as knobs were no longer rendering in the addon panel after installing the latest alpha, stemming from the changes in this merge request: #3628. This is due to children in preact always being an Array.

What I did

use Array.isArray to to check if content is an array, pull out the first value if it is.

How to test

Is this testable with Jest or Chromatic screenshots?

Nope.

Does this need a new example in the kitchen sink apps?

Nope.

Does this need an update to the documentation?

Nope.

@ndelangen
Copy link
Member

Useful thanks!

Do you think you could resolve the minor lint issue?

@codecov
Copy link

codecov bot commented Jul 16, 2018

Codecov Report

Merging #3882 into master will increase coverage by 0.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3882      +/-   ##
==========================================
+ Coverage   41.44%   41.45%   +0.01%     
==========================================
  Files         455      455              
  Lines        5193     5194       +1     
  Branches      903      904       +1     
==========================================
+ Hits         2152     2153       +1     
  Misses       2496     2496              
  Partials      545      545
Impacted Files Coverage Δ
lib/components/src/tabs/tabs.js 97.29% <100%> (+0.07%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a588f4d...5a7a6ec. Read the comment docs.

@sanpoChew
Copy link
Contributor Author

@ndelangen done 👍

@ndelangen ndelangen added the patch:yes Bugfix & documentation PR that need to be picked to main branch label Jul 16, 2018
@ndelangen ndelangen merged commit 9211dcb into storybookjs:master Jul 18, 2018
@ndelangen
Copy link
Member

Great work @sanpoChew! Thank you so much!

@Hypnosphi Hypnosphi removed the patch:yes Bugfix & documentation PR that need to be picked to main branch label Aug 2, 2018
@Hypnosphi
Copy link
Member

@ndelangen please only add patch label to bugs reproduced in stable version

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.

None yet

5 participants