@uform/core
Advanced tools
Comparing version 0.4.0 to 0.4.1-beta.0
@@ -226,4 +226,10 @@ "use strict"; | ||
this.props = utils_1.clone(props, filterSchema); | ||
this.editable = this.getEditableFromProps(this.props); | ||
this.rules = this.getRulesFromProps(this.props); | ||
var editable = this.getEditableFromProps(this.props); | ||
if (!utils_1.isEmpty(editable)) { | ||
this.editable = this.getEditableFromProps(this.props); | ||
} | ||
var rules = this.getRulesFromProps(this.props); | ||
if (!utils_1.isEmpty(rules)) { | ||
this.rules = rules; | ||
} | ||
this.dirty = true; | ||
@@ -428,2 +434,6 @@ this.notify(); | ||
} | ||
if (this.editable === false) { | ||
this.errors = []; | ||
this.effectErrors = []; | ||
} | ||
}; | ||
@@ -430,0 +440,0 @@ Field.prototype.updateState = function (reducer) { |
@@ -425,9 +425,4 @@ "use strict"; | ||
if (field.dirty) { | ||
utils_1.raf(function () { | ||
if (_this.destructed) { | ||
return; | ||
} | ||
field.pristine = true; | ||
field.notify(); | ||
}); | ||
field.notify(); | ||
_this.formNotify(field.publishState()); | ||
} | ||
@@ -434,0 +429,0 @@ }); |
{ | ||
"name": "@uform/core", | ||
"version": "0.4.0", | ||
"version": "0.4.1-beta.0", | ||
"license": "MIT", | ||
@@ -29,5 +29,5 @@ "main": "lib", | ||
"dependencies": { | ||
"@uform/types": "^0.4.0", | ||
"@uform/utils": "^0.4.0", | ||
"@uform/validator": "^0.4.0", | ||
"@uform/types": "^0.4.1-beta.0", | ||
"@uform/utils": "^0.4.1-beta.0", | ||
"@uform/validator": "^0.4.1-beta.0", | ||
"dot-match": "^0.1.18", | ||
@@ -39,3 +39,3 @@ "rxjs": "^6.3.3" | ||
}, | ||
"gitHead": "fafb5ca84d28ea4d80073b6dd6005f100452efe0" | ||
"gitHead": "f47a189dd118318a814b6038ba178e08ec6c4a3c" | ||
} |
@@ -323,4 +323,10 @@ import { | ||
this.props = clone(props, filterSchema) | ||
this.editable = this.getEditableFromProps(this.props) | ||
this.rules = this.getRulesFromProps(this.props) | ||
const editable = this.getEditableFromProps(this.props) | ||
if (!isEmpty(editable)) { | ||
this.editable = this.getEditableFromProps(this.props) | ||
} | ||
const rules = this.getRulesFromProps(this.props) | ||
if (!isEmpty(rules)) { | ||
this.rules = rules | ||
} | ||
this.dirty = true | ||
@@ -533,2 +539,6 @@ this.notify() | ||
} | ||
if (this.editable === false) { | ||
this.errors = [] | ||
this.effectErrors = [] | ||
} | ||
} | ||
@@ -535,0 +545,0 @@ |
@@ -485,9 +485,4 @@ import { | ||
if (field.dirty) { | ||
raf(() => { | ||
if (this.destructed) { | ||
return | ||
} | ||
field.pristine = true | ||
field.notify() | ||
}) | ||
field.notify() | ||
this.formNotify(field.publishState()) | ||
} | ||
@@ -494,0 +489,0 @@ }) |
113031
3374
Updated@uform/types@^0.4.1-beta.0
Updated@uform/utils@^0.4.1-beta.0