mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-01-11 10:25:16 +00:00
Slot colors by type
This commit is contained in:
parent
a30526aec1
commit
070b5749b3
@ -486,6 +486,27 @@ class ComfyApp {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Setup slot colors for types
|
||||||
|
*/
|
||||||
|
setupSlotColors() {
|
||||||
|
let colors = {
|
||||||
|
"CLIP": "#556B2F", // Olive green
|
||||||
|
"CLIP_VISION": "#4B0082", // Dark purple
|
||||||
|
"CLIP_VISION_OUTPUT": "#006400", // Dark green
|
||||||
|
"CONDITIONING": "#FF1493", // Deep pink
|
||||||
|
"CONTROL_NET": "#8B4513", // Dark brown
|
||||||
|
"IMAGE": "#8B0000", // Dark red
|
||||||
|
"LATENT": "#00008B", // Dark blue
|
||||||
|
"MASK": "#2F4F4F", // Dark gray
|
||||||
|
"MODEL": "#FF8C00", // Dark orange
|
||||||
|
"STYLE_MODEL": "#004A4A", // Dark teal
|
||||||
|
"VAE": "#4F394F", // Dark plum
|
||||||
|
};
|
||||||
|
|
||||||
|
Object.assign(this.canvas.default_connection_color_byType, colors);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set up the app on the page
|
* Set up the app on the page
|
||||||
*/
|
*/
|
||||||
@ -501,6 +522,8 @@ class ComfyApp {
|
|||||||
const canvas = (this.canvas = new LGraphCanvas(canvasEl, this.graph));
|
const canvas = (this.canvas = new LGraphCanvas(canvasEl, this.graph));
|
||||||
this.ctx = canvasEl.getContext("2d");
|
this.ctx = canvasEl.getContext("2d");
|
||||||
|
|
||||||
|
this.setupSlotColors();
|
||||||
|
|
||||||
this.graph.start();
|
this.graph.start();
|
||||||
|
|
||||||
function resizeCanvas() {
|
function resizeCanvas() {
|
||||||
|
Loading…
Reference in New Issue
Block a user