Socket
Socket
Sign inDemoInstall

dagre

Package Overview
Dependencies
Maintainers
1
Versions
47
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dagre - npm Package Compare versions

Comparing version 0.5.0 to 0.5.1

13

CHANGELOG.md

@@ -0,1 +1,10 @@

v0.5.1
======
Bug fixes and minor improvements:
1. Add version property to the library
2. Set graph dimensions on the input graph
3. Export graphlib as a property of the dagre global
v0.5.0

@@ -10,2 +19,6 @@ ======

Note: this version has dropped support for rank constraints. They may be added
back at some point, but my priority is improving speed and working out any
issues with clustering for the moment.
v0.4.6

@@ -12,0 +25,0 @@ ======

3

index.js

@@ -29,3 +29,4 @@ /*

notime: require("./lib/util").notime
}
},
version: require("./lib/version")
};

@@ -48,2 +48,3 @@ "use strict";

time(" positionSelfEdges", function() { positionSelfEdges(g); });
time(" setGraphDimensions", function() { setGraphDimensions(g); });
time(" removeBorderNodes", function() { removeBorderNodes(g); });

@@ -88,2 +89,5 @@ time(" normalize.undo", function() { normalize.undo(g); });

});
inputGraph.graph().width = layoutGraph.graph().width;
inputGraph.graph().height = layoutGraph.graph().height;
}

@@ -181,2 +185,15 @@

function setGraphDimensions(g) {
var width = 0,
height = 0,
graph = g.graph();
_.each(g.nodes(), function(v) {
var node = g.node(v);
width = Math.max(width, node.x + node.width / 2);
height = Math.max(height, node.y + node.height / 2);
});
graph.width = width;
graph.height = height;
}
function assignNodeIntersects(g) {

@@ -183,0 +200,0 @@ _.each(g.edges(), function(e) {

@@ -1,1 +0,1 @@

module.exports = "0.5.0";
module.exports = "0.5.1";
{
"name": "dagre",
"version": "0.5.0",
"version": "0.5.1",
"description": "Graph layout for JavaScript",

@@ -23,3 +23,2 @@ "author": "Chris Pettitt <cpettitt@gmail.com>",

"jshint-stylish": "^0.4.0",
"lodash": "^2.4.1",
"mocha": "^1.21.4",

@@ -26,0 +25,0 @@ "semver": "^3.0.1",

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