nowthis / sankeymatic

Make Beautiful Flow Diagrams
http://sankeymatic.com/build/
ISC License
841 stars 122 forks source link

Error: node with value 0 disappears #38

Closed Nemecsek closed 2 years ago

Nemecsek commented 6 years ago

Setting Node1 [0] Node2, Node1 goes to the rightmost position and Node2 is missing. It is possibly a mistake because it SHOULD accept 0, leaving Node2 tag (and perhaps with a very thin flow line, even if it should theoretically be invisible).

nowthis commented 2 years ago

As of b71790624ded40a2026e9f8001af5cacb8daf1b3 (2022-03-27), 0-value nodes are now always placed in the first column instead of outside the diagram.

It is possible to end up with a 0-value node by declaring it on its own line (with a color) and then never referencing it in a flow.

(There still has to be at least 1 real flow in the diagram for anything to be rendered, though. And it is still true that Flows can't have a value of 0 -- something has to be flowing for there to be anything to draw.)

This input produces a diagram which demonstrates the new handling of 0-value nodes:

:node1 #333
node2 [1] node3