question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Failed prop type: Invalid prop `progressBar` supplied to `Rheostat`

See original GitHub issue

I get this warning messages in console when using rheostat Warning: Failed prop type: Invalid prop progressBar supplied to Rheostat. Warning: Failed prop type: Invalid prop progressBar supplied to withStyles(Rheostat).

Can somebody explain me why I receive this warnings ?

I’m using a custom progressBar element and I had to use register a custom theme in order to have rheostat and react-calendar to work together

ThemedStyleSheet.registerTheme({
  rheostat: {
    ...RheostatDefaultTheme.rheostat,
    color: {
      ...RheostatDefaultTheme.rheostat.color,
      progressBar: 'red',
    },
  },
  reactDates: {
    ...ReactDatesDefaultTheme.reactDates,
  },
});

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
jchapellecommented, Jan 22, 2019

Thanks a lot, by defining my component like below, I have no more warnings.

const SliderHandleStyledComponent = styled.div`
    left: 0%;
    margin-left: -15px;
    position: absolute;
    width: 32px !important;
    height: 32px !important;
    border-width: 1px !important;
    border-style: solid !important;
    border-color: #008489 !important;
    background-color: #ffffff !important;
    border-radius: 32px !important;
    outline: none !important;
    z-index: 2 !important;
    box-shadow: 0 2px 2px rgba(72, 72, 72, 0.3) !important;
    top: -15px !important;
    &:hover{
      cursor: pointer;
    }
}
`;

const SliderHandle = ({ className, children }) => (
  <SliderHandleStyledComponent className={className}>
    {children}
  </SliderHandleStyledComponent>
);
0reactions
jchapellecommented, Jan 23, 2019

Well it’s strange because the (left) position is set by the “style” props but for a reason I don’t know, the function is not receiving the updated “style” props on drag and drop event

On Wed, Jan 23, 2019 at 6:06 PM Jordan Harband notifications@github.com wrote:

Your handle isn’t using all the props it’s getting.

I’d recommend starting with the default handle, get everything working, and worry about styling it later.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/airbnb/rheostat/issues/208#issuecomment-456884743, or mute the thread https://github.com/notifications/unsubscribe-auth/AF4GXQJYeMO9hp8vY86lxcL65goyB11Pks5vGJaTgaJpZM4aM0Ol .

– Jean Chapelle

Read more comments on GitHub >

github_iconTop Results From Across the Web

Failed propType: Invalid prop `component` supplied to `Route ...
I'm trying new react-router 1.0.0 and I'm getting strange warnings I can't explain: Warning: Failed propType: Invalid prop `component` supplied to `Route ...
Read more >
rheostat | Yarn - Package Manager
Fast, reliable, and secure dependency management.
Read more >
Rheostat PropType Errors and Context API Legacy Error
Describe the bug . I'm currently working with React Instantsearch. While using the RangeSlider widget using Rheostat with React, ...
Read more >
invalid prop `rows` of type `object` supplied to `forwardref ...
failed prop type : invalid prop `rows` of type `object` supplied to `forwardref(datagrid)`, expected `array`. Clear input field icon. Search query.
Read more >
Rheostat - Airbnb Engineering & Data Science
Custom class name that will be applied to the root of Rheostat. className: PropTypes.string. Custom React component overrides for both the handles, and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found