Coloring links between groups

Hi,
Suppose that i have two groups, each group has 2 nodes which are interconnected with the nodes of the other group, constructing total 2 links in the diagram
If the groups are expanded, i see 2 links.
If the groups are collapsed, i see 1 “thick” link.
The links colors, differs, one is red, the second is green.
In such case, when the groups are collapsed i need to see one “thick” red link.
Do i have to program the grouped link color, or it is native GOJS feature ?
Regards,
Tany

No, those kinds of decisions are necessarily application-specific, so you need to program something.

Might it work if you just make sure the red link is in front of the green link?
You might want to explicitly hide the green link at the same time that you make the red link thicker. I’m trying to find an existing example of how to do this, but I haven’t found it…

OK,
Should i use zOrder for the link ?

I suppose you could do that.

But it might be better to implement a Group.subGraphExpandedChanged event handler and iterate through the Group.findExternalLinksConnected collection to decide which links to show and which ones to make transparent (set GraphObject.opacity to 0.0).

Is there any fast way to find all links between two particular groups ?

You’ll need to iterate over the Group.findExternalLinksConnected collection and see if each Link connects with a Node that either is or is an (indirect?) member of the Group that you are interested in. Call Part | GoJS API.