Comparing version 0.15.0 to 0.15.1
@@ -75,10 +75,14 @@ 'use strict'; | ||
}, | ||
onChange: function onChange(name, action, event) { | ||
onChange: function onChange(name, action) { | ||
var fieldMeta = this.getFieldMeta(name); | ||
var validate = fieldMeta.validate; | ||
for (var _len = arguments.length, args = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { | ||
args[_key - 2] = arguments[_key]; | ||
} | ||
if (fieldMeta[action]) { | ||
fieldMeta[action](event); | ||
fieldMeta[action].apply(fieldMeta, args); | ||
} | ||
var value = fieldMeta.getValueFromEvent ? fieldMeta.getValueFromEvent(event) : (0, _utils.getValueFromEvent)(event); | ||
var value = fieldMeta.getValueFromEvent ? fieldMeta.getValueFromEvent.apply(fieldMeta, args) : _utils.getValueFromEvent.apply(undefined, args); | ||
var field = this.getField(name, true); | ||
@@ -90,8 +94,13 @@ this.setFields(_defineProperty({}, name, _extends({}, field, { | ||
}, | ||
onChangeValidate: function onChangeValidate(name, action, event) { | ||
onChangeValidate: function onChangeValidate(name, action) { | ||
var fieldMeta = this.getFieldMeta(name); | ||
for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { | ||
args[_key2 - 2] = arguments[_key2]; | ||
} | ||
if (fieldMeta[action]) { | ||
fieldMeta[action](event); | ||
fieldMeta[action].apply(fieldMeta, args); | ||
} | ||
var value = fieldMeta.getValueFromEvent ? fieldMeta.getValueFromEvent(event) : (0, _utils.getValueFromEvent)(event); | ||
var value = fieldMeta.getValueFromEvent ? fieldMeta.getValueFromEvent.apply(fieldMeta, args) : _utils.getValueFromEvent.apply(undefined, args); | ||
var field = this.getField(name, true); | ||
@@ -98,0 +107,0 @@ field.value = value; |
{ | ||
"name": "rc-form", | ||
"version": "0.15.0", | ||
"version": "0.15.1", | ||
"description": "React High Order Form Component", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
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
260706
4918