@neo4j-nvl/interaction-handlers
Advanced tools
Comparing version 0.2.28 to 0.2.29
@@ -1,2 +0,2 @@ | ||
import { NVL } from '@neo4j-nvl/core'; | ||
import type { NVL } from '@neo4j-nvl/core'; | ||
/** | ||
@@ -3,0 +3,0 @@ * Base class for all interactions. |
@@ -1,2 +0,2 @@ | ||
import { NVL, Node, Relationship } from '@neo4j-nvl/core'; | ||
import type { NVL, Node, Relationship } from '@neo4j-nvl/core'; | ||
import { BaseInteraction } from './base'; | ||
@@ -3,0 +3,0 @@ /** |
@@ -110,4 +110,3 @@ import { NODE_EDGE_WIDTH } from '../constants'; | ||
}; | ||
let x = pos.x; | ||
let y = pos.y; | ||
let { x, y } = pos; | ||
let size = 25; | ||
@@ -114,0 +113,0 @@ if (hitNode) { |
@@ -1,2 +0,2 @@ | ||
import { NVL } from '@neo4j-nvl/core'; | ||
import type { NVL } from '@neo4j-nvl/core'; | ||
import { BaseInteraction } from './base'; | ||
@@ -62,3 +62,3 @@ /** | ||
*/ | ||
updateTargets: (targets: Array<'node' | 'relationship'>, excludeNodeMargin: boolean) => void; | ||
updateTargets: (targets: ('node' | 'relationship')[], excludeNodeMargin: boolean) => void; | ||
private handleMouseDown; | ||
@@ -65,0 +65,0 @@ private handleMouseMove; |
@@ -1,2 +0,2 @@ | ||
import { NVL } from '@neo4j-nvl/core'; | ||
import type { NVL } from '@neo4j-nvl/core'; | ||
import { BaseInteraction } from './base'; | ||
@@ -3,0 +3,0 @@ /** |
@@ -52,4 +52,4 @@ import { drawCircleBand } from '@neo4j-nvl/core'; | ||
const rect = parent.getBoundingClientRect(); | ||
const width = rect.width; | ||
const height = rect.height; | ||
const { width } = rect; | ||
const { height } = rect; | ||
const devicePixelRatio = window.devicePixelRatio || 1; | ||
@@ -79,4 +79,5 @@ canvas.width = width * devicePixelRatio; | ||
const localEndY = (endY - rect.top) * devicePixelRatio; | ||
if (!this._ctx) | ||
if (!this._ctx) { | ||
return; | ||
} | ||
this._ctx.beginPath(); | ||
@@ -105,4 +106,5 @@ this._ctx.rect(localStartX, localStartY, localEndX - localStartX, localEndY - localStartY); | ||
const devicePixelRatio = window.devicePixelRatio || 1; | ||
if (!this._ctx) | ||
if (!this._ctx) { | ||
return; | ||
} | ||
this._ctx.clearRect(0, 0, rect.width * devicePixelRatio, rect.height * devicePixelRatio); | ||
@@ -109,0 +111,0 @@ } |
{ | ||
"name": "@neo4j-nvl/interaction-handlers", | ||
"version": "0.2.28", | ||
"version": "0.2.29", | ||
"license": "SEE LICENSE IN 'Neo4j Early Access Agreement - Visualization Library.pdf'", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
271161
1859