New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

vis-graph3d

Package Overview
Dependencies
Maintainers
4
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vis-graph3d - npm Package Compare versions

Comparing version 5.7.1 to 5.7.2

2

examples/graph3d/playground/playground.js

@@ -408,2 +408,3 @@

showAnimationControls: (document.getElementById("showAnimationControls").checked != false),
showGrayBottom: (document.getElementById("showGrayBottom").checked != false),
showGrid: (document.getElementById("showGrid").checked != false),

@@ -416,2 +417,3 @@ showXAxis: (document.getElementById("showXAxis").checked != false),

showShadow: (document.getElementById("showShadow").checked != false),
showSurfaceGrid: (document.getElementById("showSurfaceGrid").checked != false),
keepAspectRatio: (document.getElementById("keepAspectRatio").checked != false),

@@ -418,0 +420,0 @@ verticalRatio: Number(document.getElementById("verticalRatio").value) || undefined,

4

lib/graph3d/options.js

@@ -34,3 +34,3 @@ /**

},
__type__ : { array, object },
__type__ : { boolean: bool, array, object },
};

@@ -83,2 +83,3 @@

showAnimationControls: { boolean: bool, 'undefined': 'undefined' },
showGrayBottom : { boolean: bool },
showGrid : { boolean: bool },

@@ -88,2 +89,3 @@ showLegend : { boolean: bool, 'undefined': 'undefined' },

showShadow : { boolean: bool },
showSurfaceGrid : { boolean: bool },
showXAxis : { boolean: bool },

@@ -90,0 +92,0 @@ showYAxis : { boolean: bool },

@@ -56,2 +56,23 @@ /**

/**
* Scale the provided point by a scalar, returns p*c
* @param {Point3d} p
* @param {number} c
* @return {Point3d} p*c
*/
Point3d.scalarProduct = function(p, c) {
return new Point3d(p.x * c, p.y * c, p.z * c);
};
/**
* Calculate the dot product of the two provided points, returns a.b
* Documentation: http://en.wikipedia.org/wiki/Dot_product
* @param {Point3d} a
* @param {Point3d} b
* @return {Point3d} dot product a.b
*/
Point3d.dotProduct = function(a, b) {
return a.x * b.x + a.y * b.y + a.z * b.z;
};
/**
* Calculate the cross product of the two provided points, returns axb

@@ -75,3 +96,3 @@ * Documentation: http://en.wikipedia.org/wiki/Cross_product

/**
* Rtrieve the length of the vector (or the distance from this point to the origin
* Retrieve the length of the vector (or the distance from this point to the origin
* @return {number} length

@@ -87,2 +108,12 @@ */

/**
* Return a normalized vector pointing in the same direction.
* @return {Point3d} normalized
*/
Point3d.prototype.normalize = function() {
return Point3d.scalarProduct(this, 1/this.length());
};
module.exports = Point3d;

@@ -60,5 +60,7 @@ ////////////////////////////////////////////////////////////////////////////////

'showZAxis',
'showGrayBottom',
'showGrid',
'showPerspective',
'showShadow',
'showSurfaceGrid',
'keepAspectRatio',

@@ -251,3 +253,2 @@ 'rotateAxisLabels',

dst.margin = 10; // px
dst.showGrayBottom = false; // TODO: this does not work correctly
dst.showTooltip = false;

@@ -485,5 +486,9 @@ dst.onclick_callback = null;

function setSurfaceColor(surfaceColors, dst) {
if(surfaceColors === undefined) {
if(surfaceColors === undefined || surfaceColors === true) {
return; // Nothing to do
}
if (surfaceColors === false) {
dst.surfaceColors = undefined;
return;
}

@@ -490,0 +495,0 @@ if (dst.surfaceColors === undefined) {

{
"name": "vis-graph3d",
"version": "5.7.1",
"version": "5.7.2",
"description": "Create interactive, animated 3d graphs. Surfaces, lines, dots and block styling out of the box.",

@@ -110,4 +110,4 @@ "main": "dist/vis-graph3d.min.js",

"Dan Turkenkopf <dturkenk@gmail.com>",
"Thomas G <t_glaessle@gmx.de>",
"Rene Heindl <Rene.Heindl@goeg.at>",
"Thomas G <t_glaessle@gmx.de>",
"Felix Hayashi <ninshinobi@msn.com>",

@@ -114,0 +114,0 @@ "Jos de Jong <jos@almende.org>",

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

Sorry, the diff of this file is not supported yet

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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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

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