mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-03 20:09:27 +01:00
Api: Make sure parent properties and @property properties are included in clone
This commit is contained in:
parent
68cd3479fd
commit
926c3f9260
@ -1196,11 +1196,11 @@ const Et2WidgetMixin = <T extends Constructor>(superClass : T) =>
|
|||||||
}
|
}
|
||||||
|
|
||||||
let widget_class = window.customElements.get(this.localName);
|
let widget_class = window.customElements.get(this.localName);
|
||||||
let properties = widget_class ? widget_class.properties : [];
|
let properties = widget_class ? widget_class.elementProperties : [];
|
||||||
for(let key in properties)
|
properties.forEach((v, key) =>
|
||||||
{
|
{
|
||||||
copy[key] = this[key];
|
copy[key] = this[key];
|
||||||
}
|
});
|
||||||
|
|
||||||
// Keep the deferred properties
|
// Keep the deferred properties
|
||||||
copy._deferred_properties = this._deferred_properties;
|
copy._deferred_properties = this._deferred_properties;
|
||||||
|
@ -296,11 +296,11 @@ export class et2_nextmatch_rowProvider
|
|||||||
|
|
||||||
// N.B. cloneNode widget is missing its unreflected properties and we need to get them from original
|
// N.B. cloneNode widget is missing its unreflected properties and we need to get them from original
|
||||||
let widget_class = window.customElements.get(widget.localName);
|
let widget_class = window.customElements.get(widget.localName);
|
||||||
let properties = widget_class ? widget_class.properties : [];
|
let properties = widget_class ? widget_class.elementProperties : [];
|
||||||
for(let key in properties)
|
properties.forEach((v, key) =>
|
||||||
{
|
{
|
||||||
widget[key] = original[key];
|
widget[key] = original[key];
|
||||||
}
|
});
|
||||||
|
|
||||||
if(!widget || widget.localName !== entry.widget.localName)
|
if(!widget || widget.localName !== entry.widget.localName)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user