@comfyorg/comfyui-frontend-types 1.29.2 → 1.30.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +24 -0
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -1277,6 +1277,10 @@ export declare class ComfyApp {
|
|
|
1277
1277
|
* Badges to add to the about page
|
|
1278
1278
|
*/
|
|
1279
1279
|
aboutPageBadges?: AboutPageBadge[];
|
|
1280
|
+
/**
|
|
1281
|
+
* Badges to add to the top bar
|
|
1282
|
+
*/
|
|
1283
|
+
topbarBadges?: TopbarBadge[];
|
|
1280
1284
|
/**
|
|
1281
1285
|
* Allows any initialisation, e.g. loading resources. Called after the canvas is created but before nodes are added
|
|
1282
1286
|
* @param app The ComfyUI app instance
|
|
@@ -2310,6 +2314,13 @@ export declare class ComfyApp {
|
|
|
2310
2314
|
* @param lowQuality Whether to draw the widget in low quality.
|
|
2311
2315
|
*/
|
|
2312
2316
|
draw?(ctx: CanvasRenderingContext2D, node: LGraphNode, widget_width: number, y: number, H: number, lowQuality?: boolean): void;
|
|
2317
|
+
/**
|
|
2318
|
+
* Compatibility method for widgets implementing the draw
|
|
2319
|
+
* method when displayed in non-canvas renderers.
|
|
2320
|
+
* Set by the current renderer implementation.
|
|
2321
|
+
* When called, performs a draw operation.
|
|
2322
|
+
*/
|
|
2323
|
+
triggerDraw?: () => void;
|
|
2313
2324
|
/**
|
|
2314
2325
|
* Compute the size of the widget. Overrides {@link IBaseWidget.computeSize}.
|
|
2315
2326
|
* @param width The width of the widget.
|
|
@@ -3479,6 +3490,10 @@ export declare class ComfyApp {
|
|
|
3479
3490
|
state: LGraphCanvasState;
|
|
3480
3491
|
get subgraph(): Subgraph | undefined;
|
|
3481
3492
|
set subgraph(value: Subgraph | undefined);
|
|
3493
|
+
/**
|
|
3494
|
+
* The location of the fps info widget. Leaving an element unset will use the default position for that element.
|
|
3495
|
+
*/
|
|
3496
|
+
fpsInfoLocation: [x: number | null | undefined, y: number | null | undefined] | null | undefined;
|
|
3482
3497
|
/** Dispatches a custom event on the canvas. */
|
|
3483
3498
|
dispatch<T extends keyof NeverNever<LGraphCanvasEventMap>>(type: T, detail: LGraphCanvasEventMap[T]): boolean;
|
|
3484
3499
|
dispatch<T extends keyof PickNevers<LGraphCanvasEventMap>>(type: T): boolean;
|
|
@@ -3841,6 +3856,7 @@ export declare class ComfyApp {
|
|
|
3841
3856
|
*/
|
|
3842
3857
|
updateMouseOverNodes(node: LGraphNode | null, e: CanvasPointerEvent): void;
|
|
3843
3858
|
processMouseDown(e: PointerEvent): void;
|
|
3859
|
+
processWidgetClick(e: CanvasPointerEvent, node: LGraphNode, widget: IBaseWidget, pointer?: CanvasPointer): void;
|
|
3844
3860
|
/**
|
|
3845
3861
|
* Called when a mouse move event has to be processed
|
|
3846
3862
|
*/
|
|
@@ -7657,6 +7673,14 @@ export declare class ComfyApp {
|
|
|
7657
7673
|
connectToRerouteInput(): void;
|
|
7658
7674
|
}
|
|
7659
7675
|
|
|
7676
|
+
declare interface TopbarBadge {
|
|
7677
|
+
text: string;
|
|
7678
|
+
/**
|
|
7679
|
+
* Optional badge label (e.g., "BETA", "ALPHA", "NEW")
|
|
7680
|
+
*/
|
|
7681
|
+
label?: string;
|
|
7682
|
+
}
|
|
7683
|
+
|
|
7660
7684
|
/**
|
|
7661
7685
|
* Widget for hierarchical tree selection
|
|
7662
7686
|
* This is a widget that only has a Vue widgets implementation
|