Added cleanup concept to the template

This commit is contained in:
barsdeveloper
2022-04-14 22:17:38 +02:00
parent 9b0f344dcc
commit d6aa7b22d2
19 changed files with 136 additions and 69 deletions

View File

@@ -11,6 +11,7 @@ import SelectorElement from "../element/SelectorElement"
* @typedef {import("../element/PinElement").default} PinElement
* @typedef {import("../entity/PinReferenceEntity").default} PinReferenceEntity
*/
export default class BlueprintTemplate extends ITemplate {
/**
@@ -69,8 +70,8 @@ export default class BlueprintTemplate extends ITemplate {
* Applies the style to the element.
* @param {Blueprint} blueprint The blueprint element
*/
apply(blueprint) {
super.apply(blueprint)
setup(blueprint) {
super.setup(blueprint)
blueprint.classList.add("ueb", `ueb-zoom-${blueprint.zoom}`)
Object.entries({
"--ueb-font-size": sanitizeText(Configuration.fontSize),