mirror of
https://git.datalinker.icu/ltdrdata/ComfyUI-Manager
synced 2025-12-09 06:04:31 +08:00
code formatting
update db
This commit is contained in:
parent
75b9be5507
commit
58a2494715
@ -4244,6 +4244,16 @@
|
||||
"install_type": "git-clone",
|
||||
"description": "Nodes:abyz22_Padding Image, abyz22_ImpactWildcardEncode, abyz22_setimageinfo, abyz22_SaveImage, abyz22_ImpactWildcardEncode_GetPrompt, abyz22_SetQueue, abyz22_drawmask, abyz22_FirstNonNull, abyz22_blendimages, abyz22_blend_onecolor"
|
||||
},
|
||||
{
|
||||
"author": "HAL41",
|
||||
"title": "ComfyUI aichemy nodes",
|
||||
"reference": "https://github.com/HAL41/ComfyUI-aichemy-nodes",
|
||||
"files": [
|
||||
"https://github.com/HAL41/ComfyUI-aichemy-nodes"
|
||||
],
|
||||
"install_type": "git-clone",
|
||||
"description": "Simple node to handle scaling of YOLOv8 segmentation masks"
|
||||
},
|
||||
|
||||
|
||||
{
|
||||
|
||||
@ -131,6 +131,7 @@
|
||||
"VideoCut-badger",
|
||||
"deleteDir-badger",
|
||||
"findCenterOfMask-badger",
|
||||
"frameToVideo-badger",
|
||||
"getImageSide-badger",
|
||||
"getParentDir-badger",
|
||||
"mkdir-badger"
|
||||
@ -840,6 +841,14 @@
|
||||
"title_aux": "ReActor Node for ComfyUI"
|
||||
}
|
||||
],
|
||||
"https://github.com/HAL41/ComfyUI-aichemy-nodes": [
|
||||
[
|
||||
"aichemyYOLOv8Segmentation"
|
||||
],
|
||||
{
|
||||
"title_aux": "ComfyUI aichemy nodes"
|
||||
}
|
||||
],
|
||||
"https://github.com/Hangover3832/ComfyUI-Hangover-Nodes": [
|
||||
[
|
||||
"Image Scale Bounding Box",
|
||||
|
||||
@ -15,7 +15,7 @@ import { CustomNodesInstaller } from "./custom-nodes-downloader.js";
|
||||
import { AlternativesInstaller } from "./a1111-alter-downloader.js";
|
||||
import { SnapshotManager } from "./snapshot.js";
|
||||
import { ModelInstaller } from "./model-downloader.js";
|
||||
import { manager_instance, setManagerInstance, install_via_git_url, install_pip, rebootAPI, free_models } from "./common.js";
|
||||
import { manager_instance, setManagerInstance, install_via_git_url, install_pip, rebootAPI, free_models } from "./common.js";
|
||||
import { load_components, save_as_component } from "./components-manager.js";
|
||||
|
||||
var docStyle = document.createElement('style');
|
||||
@ -925,12 +925,12 @@ class ManagerMenuDialog extends ComfyDialog {
|
||||
]),
|
||||
|
||||
$el("button", {
|
||||
id: 'workflowgallery-button',
|
||||
type: "button",
|
||||
id: 'workflowgallery-button',
|
||||
type: "button",
|
||||
style: {
|
||||
...(localStorage.getItem("wg_last_visited") ? {height: '50px'} : {})
|
||||
...(localStorage.getItem("wg_last_visited") ? {height: '50px'} : {})
|
||||
},
|
||||
onclick: (e) => {
|
||||
onclick: (e) => {
|
||||
const last_visited_site = localStorage.getItem("wg_last_visited")
|
||||
if (!!last_visited_site) {
|
||||
window.open(last_visited_site, "comfyui-workflow-gallery");
|
||||
@ -940,15 +940,15 @@ class ManagerMenuDialog extends ComfyDialog {
|
||||
},
|
||||
}, [
|
||||
$el("p", {
|
||||
textContent: 'Workflow Gallery',
|
||||
style: {
|
||||
'text-align': 'center',
|
||||
'color': 'white',
|
||||
'font-size': '18px',
|
||||
'margin': 0,
|
||||
'padding': 0,
|
||||
}
|
||||
}, [
|
||||
textContent: 'Workflow Gallery',
|
||||
style: {
|
||||
'text-align': 'center',
|
||||
'color': 'white',
|
||||
'font-size': '18px',
|
||||
'margin': 0,
|
||||
'padding': 0,
|
||||
}
|
||||
}, [
|
||||
$el("p", {
|
||||
id: 'workflowgallery-button-last-visited-label',
|
||||
textContent: `(${localStorage.getItem("wg_last_visited") ? localStorage.getItem("wg_last_visited").split('/')[2] : ''})`,
|
||||
@ -961,10 +961,10 @@ class ManagerMenuDialog extends ComfyDialog {
|
||||
}
|
||||
})
|
||||
]),
|
||||
$el("div.pysssss-workflow-arrow-2", {
|
||||
id: `comfyworkflows-button-arrow`,
|
||||
onclick: this.handleWorkflowGalleryButtonClick
|
||||
})
|
||||
$el("div.pysssss-workflow-arrow-2", {
|
||||
id: `comfyworkflows-button-arrow`,
|
||||
onclick: this.handleWorkflowGalleryButtonClick
|
||||
})
|
||||
]),
|
||||
|
||||
$el("button.cm-button", {
|
||||
@ -1019,10 +1019,10 @@ class ManagerMenuDialog extends ComfyDialog {
|
||||
this.element.style.display = "block";
|
||||
}
|
||||
|
||||
handleWorkflowGalleryButtonClick(e) {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
LiteGraph.closeAllContextMenus();
|
||||
handleWorkflowGalleryButtonClick(e) {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
LiteGraph.closeAllContextMenus();
|
||||
|
||||
// Modify the style of the button so that the UI can indicate the last
|
||||
// visited site right away.
|
||||
@ -1033,72 +1033,72 @@ class ManagerMenuDialog extends ComfyDialog {
|
||||
lastVisitedLabel.textContent = `(${url.split('/')[2]})`;
|
||||
}
|
||||
|
||||
const menu = new LiteGraph.ContextMenu(
|
||||
[
|
||||
{
|
||||
title: "Share your art",
|
||||
callback: () => {
|
||||
if (share_option === 'openart') {
|
||||
showOpenArtShareDialog();
|
||||
return;
|
||||
} else if (share_option === 'matrix' || share_option === 'comfyworkflows') {
|
||||
showShareDialog(share_option);
|
||||
return;
|
||||
} else if (share_option === 'youml') {
|
||||
showYouMLShareDialog();
|
||||
return;
|
||||
}
|
||||
const menu = new LiteGraph.ContextMenu(
|
||||
[
|
||||
{
|
||||
title: "Share your art",
|
||||
callback: () => {
|
||||
if (share_option === 'openart') {
|
||||
showOpenArtShareDialog();
|
||||
return;
|
||||
} else if (share_option === 'matrix' || share_option === 'comfyworkflows') {
|
||||
showShareDialog(share_option);
|
||||
return;
|
||||
} else if (share_option === 'youml') {
|
||||
showYouMLShareDialog();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!ShareDialogChooser.instance) {
|
||||
ShareDialogChooser.instance = new ShareDialogChooser();
|
||||
}
|
||||
ShareDialogChooser.instance.show();
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "Open 'openart.ai'",
|
||||
if (!ShareDialogChooser.instance) {
|
||||
ShareDialogChooser.instance = new ShareDialogChooser();
|
||||
}
|
||||
ShareDialogChooser.instance.show();
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "Open 'openart.ai'",
|
||||
callback: () => {
|
||||
const url = "https://openart.ai/workflows/dev";
|
||||
localStorage.setItem("wg_last_visited", url);
|
||||
window.open(url, "comfyui-workflow-gallery");
|
||||
modifyButtonStyle(url);
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "Open 'youml.com'",
|
||||
callback: () => {
|
||||
const url = "https://youml.com/?from=comfyui-share";
|
||||
localStorage.setItem("wg_last_visited", url);
|
||||
window.open(url, "comfyui-workflow-gallery");
|
||||
modifyButtonStyle(url);
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "Open 'comfyworkflows.com'",
|
||||
callback: () => {
|
||||
},
|
||||
{
|
||||
title: "Open 'youml.com'",
|
||||
callback: () => {
|
||||
const url = "https://youml.com/?from=comfyui-share";
|
||||
localStorage.setItem("wg_last_visited", url);
|
||||
window.open(url, "comfyui-workflow-gallery");
|
||||
modifyButtonStyle(url);
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "Open 'comfyworkflows.com'",
|
||||
callback: () => {
|
||||
const url = "https://comfyworkflows.com/";
|
||||
localStorage.setItem("wg_last_visited", url);
|
||||
window.open(url, "comfyui-workflow-gallery");
|
||||
window.open(url, "comfyui-workflow-gallery");
|
||||
modifyButtonStyle(url);
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "Close",
|
||||
callback: () => {
|
||||
LiteGraph.closeAllContextMenus();
|
||||
},
|
||||
}
|
||||
],
|
||||
{
|
||||
event: e,
|
||||
scale: 1.3,
|
||||
},
|
||||
window
|
||||
);
|
||||
// set the id so that we can override the context menu's z-index to be above the comfyui manager menu
|
||||
menu.root.id = "workflowgallery-button-menu";
|
||||
menu.root.classList.add("pysssss-workflow-popup-2");
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
title: "Close",
|
||||
callback: () => {
|
||||
LiteGraph.closeAllContextMenus();
|
||||
},
|
||||
}
|
||||
],
|
||||
{
|
||||
event: e,
|
||||
scale: 1.3,
|
||||
},
|
||||
window
|
||||
);
|
||||
// set the id so that we can override the context menu's z-index to be above the comfyui manager menu
|
||||
menu.root.id = "workflowgallery-button-menu";
|
||||
menu.root.classList.add("pysssss-workflow-popup-2");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -15,10 +15,6 @@ export async function load_components() {
|
||||
let data = await api.fetchApi('/manager/component/loads', {method: "POST"});
|
||||
let components = await data.json();
|
||||
|
||||
// while(!app.graph) {
|
||||
// await sleep(100);
|
||||
// }
|
||||
|
||||
let start_time = Date.now();
|
||||
let failed = [];
|
||||
let failed2 = [];
|
||||
@ -251,3 +247,5 @@ function handlePaste(e) {
|
||||
}
|
||||
|
||||
document.addEventListener("paste", handlePaste);
|
||||
|
||||
|
||||
|
||||
@ -6,7 +6,7 @@ import { manager_instance, rebootAPI } from "./common.js";
|
||||
|
||||
async function restore_snapshot(target) {
|
||||
if(SnapshotManager.instance) {
|
||||
try {
|
||||
try {
|
||||
const response = await api.fetchApi(`/snapshot/restore?target=${target}`, { cache: "no-store" });
|
||||
if(response.status == 400) {
|
||||
app.ui.dialog.show(`Restore snapshot failed: ${target.title} / ${exception}`);
|
||||
@ -30,7 +30,7 @@ async function restore_snapshot(target) {
|
||||
|
||||
async function remove_snapshot(target) {
|
||||
if(SnapshotManager.instance) {
|
||||
try {
|
||||
try {
|
||||
const response = await api.fetchApi(`/snapshot/remove?target=${target}`, { cache: "no-store" });
|
||||
if(response.status == 400) {
|
||||
app.ui.dialog.show(`Remove snapshot failed: ${target.title} / ${exception}`);
|
||||
@ -52,20 +52,20 @@ async function remove_snapshot(target) {
|
||||
}
|
||||
|
||||
async function save_current_snapshot() {
|
||||
try {
|
||||
const response = await api.fetchApi('/snapshot/save', { cache: "no-store" });
|
||||
app.ui.dialog.close();
|
||||
return true;
|
||||
}
|
||||
catch(exception) {
|
||||
app.ui.dialog.show(`Backup snapshot failed: ${exception}`);
|
||||
app.ui.dialog.element.style.zIndex = 10010;
|
||||
return false;
|
||||
}
|
||||
finally {
|
||||
await SnapshotManager.instance.invalidateControl();
|
||||
SnapshotManager.instance.updateMessage("<BR>Current snapshot saved.");
|
||||
}
|
||||
try {
|
||||
const response = await api.fetchApi('/snapshot/save', { cache: "no-store" });
|
||||
app.ui.dialog.close();
|
||||
return true;
|
||||
}
|
||||
catch(exception) {
|
||||
app.ui.dialog.show(`Backup snapshot failed: ${exception}`);
|
||||
app.ui.dialog.element.style.zIndex = 10010;
|
||||
return false;
|
||||
}
|
||||
finally {
|
||||
await SnapshotManager.instance.invalidateControl();
|
||||
SnapshotManager.instance.updateMessage("<BR>Current snapshot saved.");
|
||||
}
|
||||
}
|
||||
|
||||
async function getSnapshotList() {
|
||||
@ -97,7 +97,7 @@ export class SnapshotManager extends ComfyDialog {
|
||||
async remove_item() {
|
||||
caller.disableButtons();
|
||||
|
||||
await caller.invalidateControl();
|
||||
await caller.invalidateControl();
|
||||
}
|
||||
|
||||
createControls() {
|
||||
@ -151,14 +151,14 @@ export class SnapshotManager extends ComfyDialog {
|
||||
var grid = document.createElement('table');
|
||||
grid.setAttribute('id', 'snapshot-list-grid');
|
||||
|
||||
var thead = document.createElement('thead');
|
||||
var tbody = document.createElement('tbody');
|
||||
var thead = document.createElement('thead');
|
||||
var tbody = document.createElement('tbody');
|
||||
|
||||
var headerRow = document.createElement('tr');
|
||||
thead.style.position = "sticky";
|
||||
thead.style.top = "0px";
|
||||
thead.style.borderCollapse = "collapse";
|
||||
thead.style.tableLayout = "fixed";
|
||||
thead.style.borderCollapse = "collapse";
|
||||
thead.style.tableLayout = "fixed";
|
||||
|
||||
var header1 = document.createElement('th');
|
||||
header1.innerHTML = ' ID ';
|
||||
@ -170,7 +170,7 @@ export class SnapshotManager extends ComfyDialog {
|
||||
header_button.innerHTML = 'Action';
|
||||
header_button.style.width = "100px";
|
||||
|
||||
thead.appendChild(headerRow);
|
||||
thead.appendChild(headerRow);
|
||||
headerRow.appendChild(header1);
|
||||
headerRow.appendChild(header2);
|
||||
headerRow.appendChild(header_button);
|
||||
@ -231,17 +231,17 @@ export class SnapshotManager extends ComfyDialog {
|
||||
this.grid_rows[i] = {data:data, control:dataRow};
|
||||
}
|
||||
|
||||
let self = this;
|
||||
let self = this;
|
||||
const panel = document.createElement('div');
|
||||
panel.style.width = "100%";
|
||||
panel.style.width = "100%";
|
||||
panel.appendChild(grid);
|
||||
|
||||
function handleResize() {
|
||||
const parentHeight = self.element.clientHeight;
|
||||
const gridHeight = parentHeight - 200;
|
||||
function handleResize() {
|
||||
const parentHeight = self.element.clientHeight;
|
||||
const gridHeight = parentHeight - 200;
|
||||
|
||||
grid.style.height = gridHeight + "px";
|
||||
}
|
||||
grid.style.height = gridHeight + "px";
|
||||
}
|
||||
window.addEventListener("resize", handleResize);
|
||||
|
||||
grid.style.position = "relative";
|
||||
@ -253,7 +253,7 @@ export class SnapshotManager extends ComfyDialog {
|
||||
this.element.style.width = "80%";
|
||||
this.element.appendChild(panel);
|
||||
|
||||
handleResize();
|
||||
handleResize();
|
||||
}
|
||||
|
||||
async createBottomControls() {
|
||||
|
||||
@ -10,6 +10,16 @@
|
||||
},
|
||||
|
||||
|
||||
{
|
||||
"author": "ZHO-ZHO-ZHO",
|
||||
"title": "ComfyUI PhotoMaker (WIP)",
|
||||
"reference": "https://github.com/ZHO-ZHO-ZHO/ComfyUI-PhotoMaker",
|
||||
"files": [
|
||||
"https://github.com/ZHO-ZHO-ZHO/ComfyUI-PhotoMaker"
|
||||
],
|
||||
"install_type": "git-clone",
|
||||
"description": "Unofficial implementation of [a/PhotoMaker](https://github.com/TencentARC/PhotoMaker) for ComfyUI(WIP) Testing……"
|
||||
},
|
||||
{
|
||||
"author": "poisenbery",
|
||||
"title": "NudeNet-Detector-Provider [WIP]",
|
||||
|
||||
@ -10,6 +10,16 @@
|
||||
},
|
||||
|
||||
|
||||
{
|
||||
"author": "HAL41",
|
||||
"title": "ComfyUI aichemy nodes",
|
||||
"reference": "https://github.com/HAL41/ComfyUI-aichemy-nodes",
|
||||
"files": [
|
||||
"https://github.com/HAL41/ComfyUI-aichemy-nodes"
|
||||
],
|
||||
"install_type": "git-clone",
|
||||
"description": "Simple node to handle scaling of YOLOv8 segmentation masks"
|
||||
},
|
||||
{
|
||||
"author": "abyz22",
|
||||
"title": "image_control",
|
||||
|
||||
@ -131,6 +131,7 @@
|
||||
"VideoCut-badger",
|
||||
"deleteDir-badger",
|
||||
"findCenterOfMask-badger",
|
||||
"frameToVideo-badger",
|
||||
"getImageSide-badger",
|
||||
"getParentDir-badger",
|
||||
"mkdir-badger"
|
||||
@ -840,6 +841,14 @@
|
||||
"title_aux": "ReActor Node for ComfyUI"
|
||||
}
|
||||
],
|
||||
"https://github.com/HAL41/ComfyUI-aichemy-nodes": [
|
||||
[
|
||||
"aichemyYOLOv8Segmentation"
|
||||
],
|
||||
{
|
||||
"title_aux": "ComfyUI aichemy nodes"
|
||||
}
|
||||
],
|
||||
"https://github.com/Hangover3832/ComfyUI-Hangover-Nodes": [
|
||||
[
|
||||
"Image Scale Bounding Box",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user