File size: 543 Bytes
baac5bb
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import type {ComfyApp, IStringWidget, IComboWidget, IWidget, LGraphNode} from "@comfyorg/frontend";

type ComfyWidgetFn<WidgetType extends IWidget> = (
  node: LGraphNode,
  inputName: string,
  inputData: any,
  app: ComfyApp,
) => {widget: WidgetType};

/**
 * A dummy ComfyWidgets that we can import from our code, which we'll rewrite later to the comfyui
 * hosted widgets.js
 */
export declare const ComfyWidgets: {
  COMBO: ComfyWidgetFn<IComboWidget>;
  STRING: ComfyWidgetFn<IStringWidget>;
  [key: string]: ComfyWidgetFn<IWidget>;
};