import type { DataType, SocketType } from '../../plugins/typed-sockets'; import { type ControlOfSocket, type InputControl, type InputControlType, type InputControlValueType, type Socket, type SocketDatastructure, type SocketValueType, type SocketValueWithDatastructure as WithDatastructure } from '../../socket'; import type { HTMLInputAttributes } from 'svelte/elements'; import { Node, type NodeParams, type SocketsValues } from '../Node.svelte'; export type InputControlNodeParams = NodeParams & { controlType: T; datastructure?: D; initial?: InputControlValueType; socketType?: S; props?: HTMLInputAttributes; }; export declare class InputControlNode extends Node<{}, { value: Socket; }, { value: InputControl>; }, { type: SocketType; controlType: InputControlType; }> { inputControl: InputControl>; outSocket: Socket; constructor(params: InputControlNodeParams>); changeType(type: S): void; data(inputs?: {} | undefined): { [K in 'value']: SocketValueType<{ value: Socket; }[K]['type']>; }; } type SocketConverter = (v: WithDatastructure, D>) => WithDatastructure, D>; /** * Base class for converter nodes. * * Converter nodes are used to convert data from one type to another type. * @template S Source type. * @template T Target type. */ export declare class ConverterNode extends Node<{ value: Socket; }, { value: Socket; }> { convert?: SocketConverter; constructor(params?: NodeParams & { source?: S; target?: T; convert?: SocketConverter; }); data(inputs?: SocketsValues<{ value: Socket; }> | undefined): SocketsValues<{ value: Socket; }>; } export {};