Fix nextmatch header did not get initial values

This commit is contained in:
nathan 2025-01-17 10:24:44 -07:00
parent d86d26cc24
commit a2197f209a

View File

@ -2418,7 +2418,11 @@ export class et2_nextmatch extends et2_DOMWidget implements et2_IResizeable, et2
*/ */
set_template(template_name : string) set_template(template_name : string)
{ {
const template = <Et2Template>loadWebComponent("et2-template", {"id": template_name, class: "hideme"}, this); const template = <Et2Template>loadWebComponent("et2-template", {
"id": template_name,
class: "hideme",
content: "rows"
}, this);
if(this.template) if(this.template)
{ {
// Stop early to prevent unneeded processing, and prevent infinite // Stop early to prevent unneeded processing, and prevent infinite
@ -2565,7 +2569,6 @@ export class et2_nextmatch extends et2_DOMWidget implements et2_IResizeable, et2
// Explictly add template to DOM since it won't happen otherwise, and webComponents need to be in the DOM // Explictly add template to DOM since it won't happen otherwise, and webComponents need to be in the DOM
// to complete // to complete
this.div.append(template); this.div.append(template);
template.load();
return this.template_promise; return this.template_promise;
} }