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

react-prismazoom

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-prismazoom - npm Package Compare versions

Comparing version 2.0.2 to 2.0.3

4

CHANGELOG.md
# Changelog
## [2.0.3] - 2021-07-06
- Prevent error when component is unmounted but still moving
- Fix double-tap bug on Safari iOS
## [2.0.2] - 2021-06-23

@@ -4,0 +8,0 @@ - Includes React 17 as peer dependencies

33

dist/index.js

@@ -130,2 +130,3 @@ "use strict";

var transitionDuration = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
if (!_this.ref.current) return;
var _this$state = _this.state,

@@ -237,2 +238,3 @@ posX = _this$state.posX,

event.preventDefault();
console.log('a');

@@ -574,13 +576,24 @@ if (_this.state.zoom === _this.props.minZoom) {

style: style,
className: className,
onDoubleClick: this.handleDoubleClick,
onMouseDown: this.handleMouseStart,
onMouseMove: this.handleMouseMove,
onMouseUp: this.handleMouseStop,
onMouseLeave: this.handleMouseStop,
onTouchStart: this.handleTouchStart,
onTouchMove: this.handleTouchMove,
onTouchEnd: this.handleTouchStop,
onTouchCancel: this.handleTouchStop
className: className
};
if (window.matchMedia("(pointer: fine)").matches) {
// Apply mouse events only to devices which include an accurate pointing device
attr = _objectSpread(_objectSpread({}, attr), {}, {
onDoubleClick: this.handleDoubleClick,
onMouseDown: this.handleMouseStart,
onMouseMove: this.handleMouseMove,
onMouseUp: this.handleMouseStop,
onMouseLeave: this.handleMouseStop
});
} else {
// Apply touch events to all other devices
attr = _objectSpread(_objectSpread({}, attr), {}, {
onTouchStart: this.handleTouchStart,
onTouchMove: this.handleTouchMove,
onTouchEnd: this.handleTouchStop,
onTouchCancel: this.handleTouchStop
});
}
return /*#__PURE__*/_react.default.createElement("div", attr, children);

@@ -587,0 +600,0 @@ }

{
"name": "react-prismazoom",
"version": "2.0.2",
"version": "2.0.3",
"description": "A pan and zoom component for React, using CSS transformations.",

@@ -5,0 +5,0 @@ "author": "Sylvain DUBUS <svn.dbs@gmail.com>",

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