Search code examples
javascriptjointjs

Link highlighting using jointjs


Problem with the link highlighting like on the picture: enter image description here

Have you any idea how to solve it?


Solution

  • The highlight method takes two parameters, the second of which allows you to specify the type of highlight. This is documented here. One of the 'types' allowed is where you can specify a css class. You can define a class, and specify it here.

    If that isn't enough, another option would be to extend linkView, and implement your own 'highlight' methods on that. Then provide this new linkView to the paper constructor as a template.