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

flot-plugins

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

flot-plugins - npm Package Compare versions

Comparing version 3.3.0 to 3.4.0

dist/examples/NationalInstruments/scatter-graph/hover/index.html

42

dist/source/NationalInstruments/jquery.flot.scattergraph.js

@@ -105,2 +105,3 @@ /* The MIT License

var x, y;
sDatapoints.points = [];
for (var j = 0; j < sData.length; j++) {

@@ -170,2 +171,3 @@ for (var i = 0; i < dataLen; i++) {

plot.hooks.processRawData.push(processRawData);
plot.hooks.findNearbyItems.push(findNearbyItems);

@@ -520,2 +522,42 @@ opt = options;

};
function findNearbyItems (plot, canvasX, canvasY, series, seriesIndex, radius, computeDistance, items) {
var ps = series[seriesIndex].datapoints.pointsize;
for (var j = 0; j < series[seriesIndex].data.length; j++) {
for (var i = 0; i < dataLen; i++) {
var x, y;
if (isArrayOfObject) {
x = series[seriesIndex].data[j][i].x;
y = series[seriesIndex].data[j][i].y;
} else if (isObjectOfArray) {
x = series[seriesIndex].data[j].x[i];
y = series[seriesIndex].data[j].y[i];
} else if (isArrayOfArray) {
x = series[seriesIndex].data[j][i][0];
y = series[seriesIndex].data[j][i][1];
}
var px = series[seriesIndex].xaxis.p2c(x);
var deltaX = px - canvasX;
var py = series[seriesIndex].yaxis.p2c(y);
var deltaY = py - canvasY;
var distance;
if (computeDistance) {
distance = computeDistance(deltaX, deltaY);
} else {
distance = Math.sqrt(deltaX * deltaX + deltaY * deltaY);
}
if (distance < radius) {
items.push({
datapoint: series[seriesIndex].datapoints.points.slice(i * ps, (i + 1) * ps),
dataIndex: i,
series: series[seriesIndex],
seriesIndex: seriesIndex,
distance: distance
});
}
}
}
};
};

@@ -522,0 +564,0 @@ };

4

package.json
{
"name": "flot-plugins",
"version": "3.3.0",
"version": "3.4.0",
"description": "A collection of plug-ins for flot charts",

@@ -57,3 +57,3 @@ "main": "index.js",

"dependencies": {
"flot": "^3.2.9",
"flot": "^4.1.0",
"jquery": "^3.1.0",

@@ -60,0 +60,0 @@ "ni-data-types": "^1.0.5"

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

Sorry, the diff of this file is not supported yet

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