Comparing version 0.1.5 to 0.1.6
@@ -91,3 +91,3 @@ 'use strict'; | ||
*/ | ||
values: props.values || {} | ||
values: props.defaultValues || {} | ||
}; | ||
@@ -235,7 +235,11 @@ _this.handleFieldChange = _this.handleFieldChange.bind(_this); | ||
value: function handleFieldChange(name, value, event) { | ||
var _props4 = this.props, | ||
onChange = _props4.onChange, | ||
defaultValues = _props4.defaultValues; | ||
var onChange = this.props.onChange; | ||
var values = Object.assign({}, this.state.values, defaultValues, _defineProperty({}, name, value)); | ||
var values = this.getValues(); | ||
var nextValues = Object.assign({}, values, _defineProperty({}, name, value)); | ||
this.setState({ | ||
values: nextValues | ||
}); | ||
onChange && onChange(values, event); | ||
@@ -246,7 +250,7 @@ } | ||
value: function render() { | ||
var _props5 = this.props, | ||
horizontal = _props5.horizontal, | ||
inline = _props5.inline, | ||
className = _props5.className, | ||
props = _objectWithoutProperties(_props5, ['horizontal', 'inline', 'className']); | ||
var _props4 = this.props, | ||
horizontal = _props4.horizontal, | ||
inline = _props4.inline, | ||
className = _props4.className, | ||
props = _objectWithoutProperties(_props4, ['horizontal', 'inline', 'className']); | ||
@@ -253,0 +257,0 @@ var clesses = (0, _classnames2.default)('form', { |
{ | ||
"name": "form-lib", | ||
"version": "0.1.5", | ||
"version": "0.1.6", | ||
"description": "Form component for React", | ||
@@ -32,2 +32,3 @@ "main": "lib/index.js", | ||
"CHANGELOG.md", | ||
"src", | ||
"lib" | ||
@@ -34,0 +35,0 @@ ], |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
43133
14
944