Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cytoscape-edge-bend-editing

Package Overview
Dependencies
Maintainers
1
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cytoscape-edge-bend-editing - npm Package Compare versions

Comparing version 1.3.1 to 1.3.2

2

package.json
{
"name": "cytoscape-edge-bend-editing",
"version": "1.3.1",
"version": "1.3.2",
"description": "A Cytoscape.js extension enables editing edge bend points",

@@ -5,0 +5,0 @@ "main": "cytoscape-edge-bend-editing.js",

@@ -192,6 +192,14 @@ var bendPointUtilities = {

var d1 = this.calculateDistance(srcPoint, tgtPoint);
var d2 = this.calculateDistance(srcPoint, intersectionPoint);
var weight = d2 / d1;
var weight;
if( intersectX != srcPoint.x ) {
weight = (intersectX - srcPoint.x) / (tgtPoint.x - srcPoint.x);
}
else if( intersectY != srcPoint.y ) {
weight = (intersectY - srcPoint.y) / (tgtPoint.y - srcPoint.y);
}
else {
weight = 0;
}
var distance = Math.sqrt(Math.pow((intersectY - bendPoint.y), 2)

@@ -198,0 +206,0 @@ + Math.pow((intersectX - bendPoint.x), 2));

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc