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

Radio Button is broken with RHL #1368

Closed
olegstepura opened this issue Mar 28, 2017 · 5 comments
Closed

Radio Button is broken with RHL #1368

olegstepura opened this issue Mar 28, 2017 · 5 comments

Comments

@olegstepura
Copy link
Contributor

I'm experiencing an issue with RadioGroup and react-hot-loader together.

ezgif-1-4805f840af

isComponentOfType is overwritten in my case. If I remove RHL, it works.

this is caused by the fact, that isComponentOfType in RadioGroup is loaded from utils/react instead of utils/is-component-of-type and is not overwritable.

@holzfelix
Copy link

Hi,
I added the actual beta.8 from repo to my app ... but the problem is stell actual ...

@olegstepura
Copy link
Contributor Author

I updated to beta.8 and for me it looks ok with RHL 3

@holzfelix
Copy link

you are able to check the radios?

@holzfelix
Copy link

code cools like this:

import { RadioGroup, RadioButton } from 'react-toolbox/lib/radio';

 <RadioGroup name='steptype' value={this.state.value} onChange={this.handleChange}>
     <RadioButton label={I18n.t('processes.new.processStepTypeDuty')} value='duty'/>
      <RadioButton label={I18n.t('processes.new.processStepTypeVariable')} value='variable'/>
      <RadioButton label={I18n.t('processes.new.processStepTypeOptioanal')} value='optional'/>
 </RadioGroup>

tiagomapmarques pushed a commit to tiagomapmarques/react-seed that referenced this issue May 11, 2017
This was done due to the bugs on the onChange events.
See react-toolbox/react-toolbox#1368 and react-toolbox/react-toolbox#1417 for more details.
tiagomapmarques added a commit to tiagomapmarques/react-seed that referenced this issue May 11, 2017
* Downgraded react packages due to toolbox dependencies

* Replaced custom components with toolbox components

* Minor text edit

* Renamed component ScientistAdd to ScientistForm

* Fixed dependencies issues for react-toolbox

* Bypass react-toolbox RadioButton and RadioGroup

This was done due to the bugs on the onChange events.
See react-toolbox/react-toolbox#1368 and react-toolbox/react-toolbox#1417 for more details.

* Updated example app functionality
@acthp
Copy link

acthp commented Mar 11, 2018

Having this issue with beta.12 and rhl 4.0.0. Is there any solution?

edit: actually, it's unrelated to rhl. Radio groups fail even w/o rhl. RadioButton and child.type are both ThemedRadioButton, but they compare not equal, so props are not propagated to the child.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants