Socket
Socket
Sign inDemoInstall

canvas-heatmap

Package Overview
Dependencies
37
Maintainers
1
Versions
58
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.1.5 to 1.2.0

4

package.json
{
"name": "canvas-heatmap",
"version": "1.1.5",
"version": "1.2.0",
"description": "Interactive heatmap, capable of displaying 1,000,000+ data points using canvas and d3. ",

@@ -39,3 +39,3 @@ "main": "src/index.js",

"@rollup/plugin-commonjs": "^19.0.0",
"@rollup/plugin-node-resolve": "^11.2.0",
"@rollup/plugin-node-resolve": "^11.2.1",
"rollup": "^2.39.1",

@@ -42,0 +42,0 @@ "rollup-plugin-terser": "^7.0.2",

@@ -5,7 +5,7 @@ # Canvas Heatmap

Visualise large datasets with a responsive heatmap.
Interactive heatmap, capable of displaying 1,000,000+ data points using canvas and d3.
![Image of Canvas Heatmap](https://canvas-heatmap.s3.eu-central-1.amazonaws.com/heatmap.png)
Uses [d3](https://d3js.org/)/ for rendering the axis.
Uses [d3](https://d3js.org/) for rendering the axis.

@@ -19,9 +19,15 @@ Check out the examples:

```
import heatmap from 'canvas-heatmap';
import { plot } from 'canvas-heatmap';
```
then
```
plot(div, data, options={});
```
or
```
<script type="module" src="https://unpkg.com/canvas-heatmap"></script>
<script type="text/javascript" src="https://unpkg.com/canvas-heatmap"></script>
```

@@ -32,3 +38,3 @@

```
heatmap(div, data, options={});
canvasheatmap.plot(div, data, options={});
```

@@ -38,8 +44,2 @@

### Initialisation
```
heatmap(div, data, options={});
```
### div

@@ -46,0 +46,0 @@

@@ -21,3 +21,3 @@ import * as d3 from "d3";

export const heatmap = (div, data, options = {}) => {
export const plot = (div, data, options = {}) => {
if (!Array.isArray(data)) data = [data];

@@ -128,3 +128,3 @@ try {

{ name: "fontSize", default: 12, verify: verifyNumber },
{ name: "contour", default: true, verify: verifyBool },
{ name: "contour", default: false, verify: verifyBool },
{ name: "yReverse", default: false, verify: verifyBool },

@@ -520,3 +520,3 @@ { name: "xReverse", default: false, verify: verifyBool },

.attr("id", "tooltip_" + div)
.attr("class", "graphtooltip");
.attr("class", "tooltip");

@@ -584,3 +584,3 @@ // Add axis locators

"<table><tbody>" +
`<tr><td>y:</td><td>${xval} ${xu}</td></tr>` +
`<tr><td>x:</td><td>${xval} ${xu}</td></tr>` +
`<tr><td>y:</td><td>${yval} ${yu}</td></tr>` +

@@ -587,0 +587,0 @@ `<tr><td>z:</td><td>${formatNumber(zval)} ${zu}</td></tr>` +

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

import { heatmap } from "./canvas-heatmap.js";
export default heatmap;
module.exports = heatmap;
export { plot } from "./canvas-heatmap.js";

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

SocketSocket SOC 2 Logo

Product

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

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc