Fix the problem that the CSS reference address may be wrong.

This commit is contained in:
hayden
2024-09-18 15:20:13 +08:00
parent 5dea0bae98
commit 6f61688bd8

View File

@@ -1426,9 +1426,9 @@ class DirectoryDropdown {
const selection = options[iSelection];
if (selection !== undefined && selection !== null) {
DirectoryDropdown.selectionToInput(
input,
selection,
modelData.searchSeparator,
input,
selection,
modelData.searchSeparator,
DROPDOWN_DIRECTORY_SELECTION_KEY_CLASS
);
const path = this.#updateOptions();
@@ -5514,10 +5514,12 @@ app.registerExtension({
name: 'Comfy.ModelManager',
init() {},
async setup() {
const cssFileUrl = new URL(import.meta.url).pathname.replace('.js', '.css');
$el('link', {
parent: document.head,
rel: 'stylesheet',
href: './extensions/ComfyUI-Model-Manager/model-manager.css',
href: cssFileUrl,
});
app.ui?.menuContainer?.appendChild(