react-zoom-pan-pinch
Advanced tools
Comparing version 3.2.0 to 3.3.0
@@ -168,2 +168,5 @@ import React from 'react'; | ||
lockAxisY?: boolean; | ||
allowLeftClickPan?: boolean; | ||
allowMiddleClickPan?: boolean; | ||
allowRightClickPan?: boolean; | ||
activationKeys?: string[]; | ||
@@ -170,0 +173,0 @@ excluded?: string[]; |
@@ -65,2 +65,5 @@ import React from "react"; | ||
lockAxisY?: boolean; | ||
allowLeftClickPan?: boolean; | ||
allowMiddleClickPan?: boolean; | ||
allowRightClickPan?: boolean; | ||
activationKeys?: string[]; | ||
@@ -67,0 +70,0 @@ excluded?: string[]; |
{ | ||
"name": "react-zoom-pan-pinch", | ||
"version": "3.2.0", | ||
"version": "3.3.0", | ||
"description": "Zoom and pan html elements in easy way", | ||
@@ -5,0 +5,0 @@ "author": "prc5", |
@@ -37,2 +37,5 @@ import { LibrarySetup, ReactZoomPanPinchState } from "../models/context.model"; | ||
lockAxisY: false, | ||
allowLeftClickPan: true, | ||
allowMiddleClickPan: true, | ||
allowRightClickPan: true, | ||
activationKeys: [], | ||
@@ -39,0 +42,0 @@ excluded: [], |
@@ -173,15 +173,4 @@ /* eslint-disable no-param-reassign */ | ||
const rubberbandX = rubberbandIfOutOfBounds( | ||
const x = boundLimiter( | ||
positionX, | ||
minPositionX, | ||
maxPositionX, | ||
); | ||
const rubberbandY = rubberbandIfOutOfBounds( | ||
positionY, | ||
minPositionY, | ||
maxPositionY, | ||
); | ||
const x = boundLimiter( | ||
rubberbandX, | ||
minPositionX - paddingX, | ||
@@ -193,3 +182,3 @@ maxPositionX + paddingX, | ||
const y = boundLimiter( | ||
rubberbandY, | ||
positionY, | ||
minPositionY - paddingY, | ||
@@ -196,0 +185,0 @@ maxPositionY + paddingY, |
@@ -211,2 +211,6 @@ import { | ||
if (event.button === 0 && !this.setup.panning.allowLeftClickPan) return; | ||
if (event.button === 1 && !this.setup.panning.allowMiddleClickPan) return; | ||
if (event.button === 2 && !this.setup.panning.allowRightClickPan) return; | ||
event.preventDefault(); | ||
@@ -213,0 +217,0 @@ event.stopPropagation(); |
@@ -84,2 +84,5 @@ import React from "react"; | ||
lockAxisY?: boolean; | ||
allowLeftClickPan?: boolean; | ||
allowMiddleClickPan?: boolean; | ||
allowRightClickPan?: boolean; | ||
activationKeys?: string[]; | ||
@@ -86,0 +89,0 @@ excluded?: string[]; |
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
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
3401709
9863