mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-30 11:11:53 +00:00
@@ -28,6 +28,7 @@ export interface Bounds {
|
|||||||
|
|
||||||
// ID types for type safety
|
// ID types for type safety
|
||||||
export type NodeId = string
|
export type NodeId = string
|
||||||
|
export type SlotId = string
|
||||||
export type ConnectionId = string
|
export type ConnectionId = string
|
||||||
|
|
||||||
// Layout data structures
|
// Layout data structures
|
||||||
@@ -41,12 +42,18 @@ export interface NodeLayout {
|
|||||||
bounds: Bounds
|
bounds: Bounds
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface SlotLayout {
|
||||||
|
id: SlotId
|
||||||
|
nodeId: NodeId
|
||||||
|
position: Point // Relative to node
|
||||||
|
type: 'input' | 'output'
|
||||||
|
index: number
|
||||||
|
}
|
||||||
|
|
||||||
export interface ConnectionLayout {
|
export interface ConnectionLayout {
|
||||||
id: ConnectionId
|
id: ConnectionId
|
||||||
sourceNodeId: NodeId
|
sourceSlot: SlotId
|
||||||
sourceSlotIndex: number
|
targetSlot: SlotId
|
||||||
targetNodeId: NodeId
|
|
||||||
targetSlotIndex: number
|
|
||||||
// Control points for curved connections
|
// Control points for curved connections
|
||||||
controlPoints?: Point[]
|
controlPoints?: Point[]
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user