Skip to content

Commit 31f4ee3

Browse files
huchenleigithub-actions
andauthored
Fix bypass display issue (#144)
* Fix bypass display issue * nit * Update test expectations [skip ci] --------- Co-authored-by: github-actions <[email protected]>
1 parent 6b2acc1 commit 31f4ee3

File tree

6 files changed

+10
-10
lines changed

6 files changed

+10
-10
lines changed

browser_tests/rightClickMenu.spec.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,7 @@ test.describe('Node Right Click Menu', () => {
5858
await expect(comfyPage.canvas).toHaveScreenshot('right-click-node-collapsed.png');
5959
});
6060

61-
// See https://github.com/Comfy-Org/ComfyUI_frontend/pull/57
62-
// Bypass produces different output on Windows VS Linux.
63-
test.skip('Can bypass', async ({ comfyPage }) => {
61+
test('Can bypass', async ({ comfyPage }) => {
6462
await comfyPage.rightClickEmptyLatentNode();
6563
await expect(comfyPage.canvas).toHaveScreenshot('right-click-node.png');
6664
await comfyPage.page.getByText('Bypass').click();
Binary file not shown.
695 Bytes
Loading
2.1 KB
Loading

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/scripts/app.ts

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1547,11 +1547,13 @@ export class ComfyApp {
15471547
this.editor_alpha = 0.4;
15481548
}
15491549

1550-
// Mode never equals 4 by ts check.
1551-
// if (node.mode === 4) { // never
1552-
// node.bgcolor = "#FF00FF";
1553-
// this.editor_alpha = 0.2;
1554-
// }
1550+
// ComfyUI's custom node mode enum value 4 => bypass/never.
1551+
// @ts-ignore
1552+
if (node.mode === 4) {
1553+
// never
1554+
node.bgcolor = "#FF00FF";
1555+
this.editor_alpha = 0.2;
1556+
}
15551557

15561558
const adjustColor = (color?: string) => {
15571559
return color ? lightenColor(color, 0.5) : color;

0 commit comments

Comments
 (0)