mirror of
https://github.com/Comfy-Org/ComfyUI-Manager.git
synced 2026-05-10 09:02:30 +08:00
Fix deprecated ui.js import in model-manager.js
This commit is contained in:
parent
439aeaed3b
commit
edb0918fb8
@ -1,5 +1,4 @@
|
||||
import { app } from "../../scripts/app.js";
|
||||
import { $el } from "../../scripts/ui.js";
|
||||
import {
|
||||
manager_instance, rebootAPI,
|
||||
fetchData, md5, icons, show_message, customAlert, infoToast, showTerminal,
|
||||
@ -11,6 +10,14 @@ import { api } from "../../scripts/api.js";
|
||||
import TG from "./turbogrid.esm.js";
|
||||
import { buildGuiFrameCustomHeader, createSettingsCombo } from "./comfyui-gui-builder.js";
|
||||
|
||||
// === SHIM FOR NEW COMFYUI (removes ui.js warning) ===
|
||||
let $el;
|
||||
if (window?.comfyAPI?.ui) {
|
||||
({ $el } = window.comfyAPI.ui);
|
||||
} else {
|
||||
({ $el } = await import("../../scripts/ui.js"));
|
||||
}
|
||||
|
||||
loadCss("./model-manager.css");
|
||||
|
||||
const gridId = "model";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user