Fix hiding price input when free is checked on publish form

This commit is contained in:
6ea86b96 2017-07-18 13:45:00 +07:00
parent c5c7dbbdee
commit 95c5ddbfda
No known key found for this signature in database
GPG key ID: B282D183E4931E8F

View file

@ -42,6 +42,7 @@ class PublishForm extends React.PureComponent {
submitting: false,
creatingChannel: false,
modal: null,
isFee: false,
};
}
@ -635,11 +636,8 @@ class PublishForm extends React.PureComponent {
label={__("Free")}
type="radio"
name="isFree"
value="1"
onChange={() => {
this.handleFeePrefChange(false);
}}
defaultChecked={!this.state.isFee}
onChange={() => this.handleFeePrefChange(false)}
checked={!this.state.isFee}
/>
<FormField
type="radio"
@ -648,7 +646,7 @@ class PublishForm extends React.PureComponent {
onChange={() => {
this.handleFeePrefChange(true);
}}
defaultChecked={this.state.isFee}
checked={this.state.isFee}
/>
<span className={!this.state.isFee ? "hidden" : ""}>
<FormField