Docs

Search documentation

Shared docs and current release

Loading search…

日本語

@shumoku/core · 0.4.2 · function

removePort

Source

Remove a port and redistribute remaining ports on the same node. Also removes any links that reference this port. Returns updated nodes, ports, and links.

removePort(portId: string, nodes: Map<string, Node>, ports: Map<string, ResolvedPort>, links: Link[]): { links: Link[]; nodes: Map<string, Node>; ports: Map<string, ResolvedPort> } | null

Parameters

Parameter Type Description Default
portId string No additional description. —
nodes Map<string, Node> No additional description. —
ports Map<string, ResolvedPort> No additional description. —
links Link[] No additional description. —

Returns

{ links: Link[]; nodes: Map<string, Node>; ports: Map<string, ResolvedPort> } | null

libs/@shumoku/core/src/libs/@shumoku/core/src/layout/interaction.ts:826