Skip to content

Commit

Permalink
(BlockPicker): fixes blockpicker input not working (#616)
Browse files Browse the repository at this point in the history
setUpdatedValue on EditableInput had a check that checked props.label not being null
in BlockPicker case label was undefined which caused the onChange to be called with
and object instead of hex string.
  • Loading branch information
erkkaha authored and casesandberg committed May 10, 2019
1 parent 266b192 commit 0657c78
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/common/EditableInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export class EditableInput extends (PureComponent || Component) {
}

setUpdatedValue(value, e) {
const onChangeValue = this.props.label !== null ? this.getValueObjectWithLabel(value) : value
const onChangeValue = this.props.label ? this.getValueObjectWithLabel(value) : value
this.props.onChange && this.props.onChange(onChangeValue, e)

const isPercentage = getIsPercentage(e.target.value)
Expand Down

0 comments on commit 0657c78

Please sign in to comment.