widget: ignore invalid properties (avoid recreating if matrix/clone child has an override for an invalid property)
This commit is contained in:
parent
6c2e500135
commit
c860bc1959
2 changed files with 7 additions and 1 deletions
|
|
@ -939,7 +939,12 @@ class Widget extends EventEmitter {
|
|||
|
||||
if (!this.isDynamicProp(propName)) {
|
||||
|
||||
if (widget && this.contains(widget)) {
|
||||
if (this.constructor._defaults[propName] === undefined) {
|
||||
|
||||
// ignore invalid properties
|
||||
continue
|
||||
|
||||
} else if (widget && this.contains(widget)) {
|
||||
|
||||
this.errorProp(propName, '@{}', `a container can't use its child's properties to define non-dynamic properties.`)
|
||||
continue
|
||||
|
|
|
|||
|
|
@ -69,5 +69,6 @@ module.exports.categories = {
|
|||
var defaults = {}
|
||||
for (var k in module.exports.widgets) {
|
||||
defaults[k] = module.exports.widgets[k].defaults()
|
||||
module.exports.widgets[k]._defaults = defaults
|
||||
}
|
||||
module.exports.defaults = defaults
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue