mirror of
https://github.com/barsdeveloper/ueblueprint.git
synced 2026-02-18 12:24:51 +08:00
Some minor fixes and refactoring
This commit is contained in:
@@ -57,17 +57,13 @@ export default class NodeTemplate extends ISelectableDraggableTemplate {
|
||||
super.initialize(element)
|
||||
this.#subtitle = nodeSubtitle(element.entity)
|
||||
this.element.classList.add(.../** @type {typeof NodeTemplate} */(this.constructor).nodeStyleClasses)
|
||||
this.element.style.setProperty("--ueb-node-color", this.getColor().cssText)
|
||||
this.element.style.setProperty("--ueb-node-color", this.element.entity.nodeColor().cssText)
|
||||
this.pinInserter = this.element.entity.additionalPinInserter()
|
||||
if (this.pinInserter) {
|
||||
this.element.classList.add("ueb-node-is-variadic")
|
||||
}
|
||||
}
|
||||
|
||||
getColor() {
|
||||
return this.element.entity.nodeColor()
|
||||
}
|
||||
|
||||
render() {
|
||||
return html`
|
||||
<div class="ueb-node-border">
|
||||
|
||||
Reference in New Issue
Block a user