fix: popup message zindex

This commit is contained in:
dr.lt.data 2023-11-07 15:22:29 +09:00
parent 5dd9848017
commit 6d0d838629
2 changed files with 13 additions and 13 deletions

View File

@ -11,7 +11,7 @@ import subprocess # don't remove this
from tqdm.auto import tqdm from tqdm.auto import tqdm
import concurrent import concurrent
version = "V0.40" version = "V0.40.1"
print(f"### Loading: ComfyUI-Manager ({version})") print(f"### Loading: ComfyUI-Manager ({version})")

View File

@ -84,24 +84,24 @@ async function updateComfyUI() {
if(response.status == 400) { if(response.status == 400) {
app.ui.dialog.show('Failed to update ComfyUI.'); app.ui.dialog.show('Failed to update ComfyUI.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
return false; return false;
} }
if(response.status == 201) { if(response.status == 201) {
app.ui.dialog.show('ComfyUI has been successfully updated.'); app.ui.dialog.show('ComfyUI has been successfully updated.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
} }
else { else {
app.ui.dialog.show('ComfyUI is already up to date with the latest version.'); app.ui.dialog.show('ComfyUI is already up to date with the latest version.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
} }
return true; return true;
} }
catch(exception) { catch(exception) {
app.ui.dialog.show(`Failed to update ComfyUI / ${exception}`); app.ui.dialog.show(`Failed to update ComfyUI / ${exception}`);
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
return false; return false;
} }
finally { finally {
@ -126,25 +126,25 @@ async function fetchUpdates(update_check_checkbox) {
if(response.status != 200 && response.status != 201) { if(response.status != 200 && response.status != 201) {
app.ui.dialog.show('Failed to fetch updates.'); app.ui.dialog.show('Failed to fetch updates.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
return false; return false;
} }
if(response.status == 201) { if(response.status == 201) {
app.ui.dialog.show('There is an updated extension available.'); app.ui.dialog.show('There is an updated extension available.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
update_check_checkbox.checked = false; update_check_checkbox.checked = false;
} }
else { else {
app.ui.dialog.show('All extensions are already up-to-date with the latest versions.'); app.ui.dialog.show('All extensions are already up-to-date with the latest versions.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
} }
return true; return true;
} }
catch(exception) { catch(exception) {
app.ui.dialog.show(`Failed to update custom nodes / ${exception}`); app.ui.dialog.show(`Failed to update custom nodes / ${exception}`);
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
return false; return false;
} }
finally { finally {
@ -171,23 +171,23 @@ async function updateAll(update_check_checkbox) {
if(response1.status != 200 && response2.status != 201) { if(response1.status != 200 && response2.status != 201) {
app.ui.dialog.show('Failed to update ComfyUI or several extensions.<BR><BR>See terminal log.<BR>'); app.ui.dialog.show('Failed to update ComfyUI or several extensions.<BR><BR>See terminal log.<BR>');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
return false; return false;
} }
if(response1.status == 201 || response2.status == 201) { if(response1.status == 201 || response2.status == 201) {
app.ui.dialog.show('ComfyUI and all extensions have been updated to the latest version.'); app.ui.dialog.show('ComfyUI and all extensions have been updated to the latest version.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
} }
else { else {
app.ui.dialog.show('ComfyUI and all extensions are already up-to-date with the latest versions.'); app.ui.dialog.show('ComfyUI and all extensions are already up-to-date with the latest versions.');
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
} }
return true; return true;
} }
catch(exception) { catch(exception) {
app.ui.dialog.show(`Failed to update ComfyUI or several extensions / ${exception}`); app.ui.dialog.show(`Failed to update ComfyUI or several extensions / ${exception}`);
app.ui.dialog.element.style.zIndex = 9999; app.ui.dialog.element.style.zIndex = 10010;
return false; return false;
} }
finally { finally {