add error component
Signed-off-by: Tobias Erbshäußer <tobias@tesoft.dev>
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import {TesoftComponent} from "../scripts/main.ts";
|
||||
|
||||
export class TesoftError extends TesoftComponent {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
const template = document.getElementById("tesoft-error-template") as HTMLTemplateElement;
|
||||
const templateContent = template.content;
|
||||
|
||||
const shadowRoot = this.attachShadow({mode: "open"});
|
||||
shadowRoot.appendChild(templateContent.cloneNode(true));
|
||||
}
|
||||
}
|
||||
|
||||
customElements.define("tesoft-error", TesoftError);
|
||||
Reference in New Issue
Block a user