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 broken colorpicker for knobs #4222

Merged
merged 1 commit into from
Sep 27, 2018
Merged

Conversation

EloB
Copy link
Contributor

@EloB EloB commented Sep 24, 2018

Right now this error triggers when trying to open colorpicker but with this fix it least works but we get a warning.

knobs-color-broken

Current issue

Uncaught TypeError: Cannot read property 'contains' of undefined
    at HTMLDocument.<anonymous> (velocity.js:13)

After this fix issue

Warning: Can't call setState (or forceUpdate) on an unmounted component. This is a no-op, but it indicates a memory leak in your application. To fix, cancel all subscriptions and asynchronous tasks in the componentWillUnmount method.
    in ColorPicker (created by ColorType)
    in div (created by Context.Consumer)
    in Styled(div) (created by ForwardRef)

@storybook-safe-bot
Copy link
Contributor

Fails
🚫

PR is not labeled with one of: ["cleanup","BREAKING CHANGE","feature request","bug","documentation","maintenance","dependencies:update","dependencies","other"]

Generated by 🚫 dangerJS

@codecov
Copy link

codecov bot commented Sep 24, 2018

Codecov Report

Merging #4222 into master will decrease coverage by <.01%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #4222      +/-   ##
==========================================
- Coverage   40.79%   40.78%   -0.01%     
==========================================
  Files         493      493              
  Lines        5851     5852       +1     
  Branches      782      783       +1     
==========================================
  Hits         2387     2387              
  Misses       3088     3088              
- Partials      376      377       +1
Impacted Files Coverage Δ
addons/knobs/src/components/types/Color.js 24% <0%> (-1%) ⬇️

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 dd1953c...ccfb1f1. Read the comment docs.

@EloB EloB changed the title Fix that colorpicker shows up on click Fix broken colorpicker for knobs Sep 24, 2018
Copy link
Contributor

@Keraito Keraito left a comment

Choose a reason for hiding this comment

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

Looks good to me, at least it works now. Any idea if we could get rid of the new warning as well?

@EloB
Copy link
Contributor Author

EloB commented Sep 24, 2018

@Keraito I didn't find that issue... It might be inside that colorpicker library... :(

@EloB
Copy link
Contributor Author

EloB commented Sep 25, 2018

@Keraito I found the issue inside the react-color library.

casesandberg/react-color#542

@EloB
Copy link
Contributor Author

EloB commented Sep 26, 2018

Can we release this one? I'm using this for theming and is totally broken right now.

@ndelangen ndelangen merged commit 1717f9f into storybookjs:master Sep 27, 2018
@EloB EloB deleted the patch-1 branch October 27, 2020 13:52
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