Update ttN.js
This commit is contained in:
@@ -617,14 +617,19 @@ class TinyTerra extends EventTarget {
|
||||
this.downKeys["^" + e.key.toLocaleUpperCase()] = false
|
||||
}
|
||||
injectTtnCss() {
|
||||
const folders = ['ComfyUI_tinyterraNodes','comfyui_tinyterranodes']
|
||||
folders.forEach((folder) => {
|
||||
let link = document.createElement("link");
|
||||
link.rel = "stylesheet";
|
||||
link.type = "text/css";
|
||||
link.href = `extensions/${folder}/ttN.css`;
|
||||
document.head.appendChild(link);
|
||||
})
|
||||
const link = document.createElement("link");
|
||||
link.rel = "stylesheet";
|
||||
link.type = "text/css";
|
||||
link.href = "extensions/ComfyUI_tinyterraNodes/ttN.css";
|
||||
|
||||
link.onerror = function () {
|
||||
if (this.href.includes("comfyui_tinyterranodes")) {
|
||||
console.error("tinyterraNodes: Failed to load CSS file. Please check nodepack folder name.");
|
||||
return;
|
||||
}
|
||||
this.href = "extensions/comfyui_tinyterranodes/ttN.css"
|
||||
}
|
||||
document.head.appendChild(link);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user