Flow canvas: mark streaming edges with a marching dash

A port with `stream` set publishes repeatedly during one execution, and
until now nothing on the canvas said so. `deriveEdges` carries the flag
from the producing `MessageSpec` onto the edge, `LiveEdge` turns it into
an `edge-stream` class, and the class draws a dashed stroke whose offset
marches toward the target. The pulse still lands on top: both animations
share one declaration when a value arrives on a streaming edge.
This commit is contained in:
2026-08-20 09:14:44 +02:00
parent 7c8dcac7f0
commit d342d923c6
3 changed files with 37 additions and 5 deletions
+2 -2
View File
@@ -34,7 +34,7 @@ function LiveEdgeComponent({
data,
selected,
}: EdgeProps) {
const { message, producerId } = (data ?? {}) as FlowEdgeData
const { message, producerId, stream } = (data ?? {}) as FlowEdgeData
const live = useLiveValue(message)
const zoom = useStore((state) => state.transform[2])
const [pulsing, setPulsing] = useState(false)
@@ -69,7 +69,7 @@ function LiveEdgeComponent({
<BaseEdge
id={id}
path={path}
className={cn(pulsing && "edge-live")}
className={cn(pulsing && "edge-live", stream && "edge-stream")}
style={selected ? { stroke: "var(--primary)" } : undefined}
/>
{live !== undefined && zoom >= CHIP_MIN_ZOOM ? (