mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-23 07:09:20 +01:00
Reflect properties into DOM attributes, it's faster
This commit is contained in:
parent
5bdf12f1b9
commit
0f45aed876
@ -50,20 +50,23 @@ export class Et2Description extends Et2Widget(LitElement) implements et2_IDetach
|
||||
* Goes with href. If provided, that's the target for opening the link.
|
||||
*/
|
||||
extra_link_target: {
|
||||
type: String
|
||||
type: String,
|
||||
reflect: true
|
||||
},
|
||||
/**
|
||||
* widthxheight, if popup should be used, eg. 640x480
|
||||
*/
|
||||
extra_link_popup: {
|
||||
type: String
|
||||
type: String,
|
||||
reflect: true
|
||||
},
|
||||
/**
|
||||
* Link URL
|
||||
* If provided, will be clickable and open this URL
|
||||
*/
|
||||
href: {
|
||||
type: String
|
||||
type: String,
|
||||
reflect: true
|
||||
},
|
||||
value: String,
|
||||
}
|
||||
|
@ -178,15 +178,19 @@ export class et2_nextmatch_rowProvider
|
||||
data[set.attribute] = mgrs["content"].expandName(set.expression);
|
||||
}
|
||||
// WebComponent IS the node, and we've already cloned it
|
||||
// N.B. it's missing its unreflected (internal) properties
|
||||
if(typeof window.customElements.get(widget.localName) != "undefined")
|
||||
{
|
||||
// Use the clone, not the original
|
||||
/*
|
||||
// N.B. cloneNode widget is missing its unreflected properties and we need to use widget.clone()
|
||||
// instead to get them. This slows things down.
|
||||
let c = widget.clone();
|
||||
let partial = entry.nodeFuncs[0](row);
|
||||
partial.parentNode.insertBefore(c, partial);
|
||||
partial.parentNode.removeChild(partial);
|
||||
widget = c;
|
||||
*/
|
||||
// Use the clone, not the original
|
||||
widget = entry.nodeFuncs[0](row);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user