Socket
Socket
Sign inDemoInstall

react-rnd

Package Overview
Dependencies
3
Maintainers
1
Versions
93
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 9.0.1 to 9.0.2

4

lib/index.es5.js

@@ -345,3 +345,3 @@ 'use strict';

var _this = this;
var _a = this.props, disableDragging = _a.disableDragging, style = _a.style, dragHandleClassName = _a.dragHandleClassName, position = _a.position, onMouseDown = _a.onMouseDown, dragAxis = _a.dragAxis, dragGrid = _a.dragGrid, bounds = _a.bounds, enableUserSelectHack = _a.enableUserSelectHack, cancel = _a.cancel, children = _a.children, onResizeStart = _a.onResizeStart, onResize = _a.onResize, onResizeStop = _a.onResizeStop, onDragStart = _a.onDragStart, onDrag = _a.onDrag, onDragStop = _a.onDragStop, resizeHandleStyles = _a.resizeHandleStyles, resizeHandleClasses = _a.resizeHandleClasses, enableResizing = _a.enableResizing, resizeGrid = _a.resizeGrid, resizableProps = __rest(_a, ["disableDragging", "style", "dragHandleClassName", "position", "onMouseDown", "dragAxis", "dragGrid", "bounds", "enableUserSelectHack", "cancel", "children", "onResizeStart", "onResize", "onResizeStop", "onDragStart", "onDrag", "onDragStop", "resizeHandleStyles", "resizeHandleClasses", "enableResizing", "resizeGrid"]);
var _a = this.props, disableDragging = _a.disableDragging, style = _a.style, dragHandleClassName = _a.dragHandleClassName, position = _a.position, onMouseDown = _a.onMouseDown, dragAxis = _a.dragAxis, dragGrid = _a.dragGrid, bounds = _a.bounds, enableUserSelectHack = _a.enableUserSelectHack, cancel = _a.cancel, children = _a.children, onResizeStart = _a.onResizeStart, onResize = _a.onResize, onResizeStop = _a.onResizeStop, onDragStart = _a.onDragStart, onDrag = _a.onDrag, onDragStop = _a.onDragStop, resizeHandleStyles = _a.resizeHandleStyles, resizeHandleClasses = _a.resizeHandleClasses, enableResizing = _a.enableResizing, resizeGrid = _a.resizeGrid, resizeHandleWrapperClass = _a.resizeHandleWrapperClass, resizeHandleWrapperStyle = _a.resizeHandleWrapperStyle, resizableProps = __rest(_a, ["disableDragging", "style", "dragHandleClassName", "position", "onMouseDown", "dragAxis", "dragGrid", "bounds", "enableUserSelectHack", "cancel", "children", "onResizeStart", "onResize", "onResizeStop", "onDragStart", "onDrag", "onDragStop", "resizeHandleStyles", "resizeHandleClasses", "enableResizing", "resizeGrid", "resizeHandleWrapperClass", "resizeHandleWrapperStyle"]);
var defaultValue = this.props.default ? __assign({}, this.props.default) : undefined;

@@ -369,3 +369,3 @@ // Remove unknown props, see also https://reactjs.org/warnings/unknown-prop.html

}
}, defaultSize: defaultValue, size: this.props.size, enable: enableResizing, onResizeStart: this.onResizeStart, onResize: this.onResize, onResizeStop: this.onResizeStop, style: innerStyle, minWidth: this.props.minWidth, minHeight: this.props.minHeight, maxWidth: this.isResizing ? this.state.maxWidth : this.props.maxWidth, maxHeight: this.isResizing ? this.state.maxHeight : this.props.maxHeight, grid: resizeGrid, handleWrapperClass: this.props.resizeHandleWrapperClass, handleWrapperStyle: this.props.resizeHandleWrapperStyle, lockAspectRatio: this.props.lockAspectRatio, lockAspectRatioExtraWidth: this.props.lockAspectRatioExtraWidth, lockAspectRatioExtraHeight: this.props.lockAspectRatioExtraHeight, handleStyles: resizeHandleStyles, handleClasses: resizeHandleClasses }), children)));
}, defaultSize: defaultValue, size: this.props.size, enable: enableResizing, onResizeStart: this.onResizeStart, onResize: this.onResize, onResizeStop: this.onResizeStop, style: innerStyle, minWidth: this.props.minWidth, minHeight: this.props.minHeight, maxWidth: this.isResizing ? this.state.maxWidth : this.props.maxWidth, maxHeight: this.isResizing ? this.state.maxHeight : this.props.maxHeight, grid: resizeGrid, handleWrapperClass: resizeHandleWrapperClass, handleWrapperStyle: resizeHandleWrapperStyle, lockAspectRatio: this.props.lockAspectRatio, lockAspectRatioExtraWidth: this.props.lockAspectRatioExtraWidth, lockAspectRatioExtraHeight: this.props.lockAspectRatioExtraHeight, handleStyles: resizeHandleStyles, handleClasses: resizeHandleClasses }), children)));
};

@@ -372,0 +372,0 @@ Rnd.defaultProps = {

@@ -339,3 +339,3 @@ import { createElement, Component } from 'react';

var _this = this;
var _a = this.props, disableDragging = _a.disableDragging, style = _a.style, dragHandleClassName = _a.dragHandleClassName, position = _a.position, onMouseDown = _a.onMouseDown, dragAxis = _a.dragAxis, dragGrid = _a.dragGrid, bounds = _a.bounds, enableUserSelectHack = _a.enableUserSelectHack, cancel = _a.cancel, children = _a.children, onResizeStart = _a.onResizeStart, onResize = _a.onResize, onResizeStop = _a.onResizeStop, onDragStart = _a.onDragStart, onDrag = _a.onDrag, onDragStop = _a.onDragStop, resizeHandleStyles = _a.resizeHandleStyles, resizeHandleClasses = _a.resizeHandleClasses, enableResizing = _a.enableResizing, resizeGrid = _a.resizeGrid, resizableProps = __rest(_a, ["disableDragging", "style", "dragHandleClassName", "position", "onMouseDown", "dragAxis", "dragGrid", "bounds", "enableUserSelectHack", "cancel", "children", "onResizeStart", "onResize", "onResizeStop", "onDragStart", "onDrag", "onDragStop", "resizeHandleStyles", "resizeHandleClasses", "enableResizing", "resizeGrid"]);
var _a = this.props, disableDragging = _a.disableDragging, style = _a.style, dragHandleClassName = _a.dragHandleClassName, position = _a.position, onMouseDown = _a.onMouseDown, dragAxis = _a.dragAxis, dragGrid = _a.dragGrid, bounds = _a.bounds, enableUserSelectHack = _a.enableUserSelectHack, cancel = _a.cancel, children = _a.children, onResizeStart = _a.onResizeStart, onResize = _a.onResize, onResizeStop = _a.onResizeStop, onDragStart = _a.onDragStart, onDrag = _a.onDrag, onDragStop = _a.onDragStop, resizeHandleStyles = _a.resizeHandleStyles, resizeHandleClasses = _a.resizeHandleClasses, enableResizing = _a.enableResizing, resizeGrid = _a.resizeGrid, resizeHandleWrapperClass = _a.resizeHandleWrapperClass, resizeHandleWrapperStyle = _a.resizeHandleWrapperStyle, resizableProps = __rest(_a, ["disableDragging", "style", "dragHandleClassName", "position", "onMouseDown", "dragAxis", "dragGrid", "bounds", "enableUserSelectHack", "cancel", "children", "onResizeStart", "onResize", "onResizeStop", "onDragStart", "onDrag", "onDragStop", "resizeHandleStyles", "resizeHandleClasses", "enableResizing", "resizeGrid", "resizeHandleWrapperClass", "resizeHandleWrapperStyle"]);
var defaultValue = this.props.default ? __assign({}, this.props.default) : undefined;

@@ -363,3 +363,3 @@ // Remove unknown props, see also https://reactjs.org/warnings/unknown-prop.html

}
}, defaultSize: defaultValue, size: this.props.size, enable: enableResizing, onResizeStart: this.onResizeStart, onResize: this.onResize, onResizeStop: this.onResizeStop, style: innerStyle, minWidth: this.props.minWidth, minHeight: this.props.minHeight, maxWidth: this.isResizing ? this.state.maxWidth : this.props.maxWidth, maxHeight: this.isResizing ? this.state.maxHeight : this.props.maxHeight, grid: resizeGrid, handleWrapperClass: this.props.resizeHandleWrapperClass, handleWrapperStyle: this.props.resizeHandleWrapperStyle, lockAspectRatio: this.props.lockAspectRatio, lockAspectRatioExtraWidth: this.props.lockAspectRatioExtraWidth, lockAspectRatioExtraHeight: this.props.lockAspectRatioExtraHeight, handleStyles: resizeHandleStyles, handleClasses: resizeHandleClasses }), children)));
}, defaultSize: defaultValue, size: this.props.size, enable: enableResizing, onResizeStart: this.onResizeStart, onResize: this.onResize, onResizeStop: this.onResizeStop, style: innerStyle, minWidth: this.props.minWidth, minHeight: this.props.minHeight, maxWidth: this.isResizing ? this.state.maxWidth : this.props.maxWidth, maxHeight: this.isResizing ? this.state.maxHeight : this.props.maxHeight, grid: resizeGrid, handleWrapperClass: resizeHandleWrapperClass, handleWrapperStyle: resizeHandleWrapperStyle, lockAspectRatio: this.props.lockAspectRatio, lockAspectRatioExtraWidth: this.props.lockAspectRatioExtraWidth, lockAspectRatioExtraHeight: this.props.lockAspectRatioExtraHeight, handleStyles: resizeHandleStyles, handleClasses: resizeHandleClasses }), children)));
};

@@ -366,0 +366,0 @@ Rnd.defaultProps = {

{
"name": "react-rnd",
"version": "9.0.1",
"version": "9.0.2",
"description": "",

@@ -43,16 +43,16 @@ "title": "react-rnd",

"devDependencies": {
"@storybook/addon-actions": "3.4.8",
"@storybook/addon-links": "3.4.8",
"@storybook/react": "3.4.8",
"@types/enzyme": "3.1.12",
"@types/enzyme-adapter-react-16": "1.0.2",
"@storybook/addon-actions": "3.4.10",
"@storybook/addon-links": "3.4.10",
"@storybook/react": "3.4.10",
"@types/enzyme": "3.1.13",
"@types/enzyme-adapter-react-16": "1.0.3",
"@types/react": "16.4.1",
"@types/react-dom": "16.0.6",
"@types/react-dom": "16.0.7",
"@types/sinon": "5.0.1",
"@types/storybook__addon-actions": "3.0.3",
"@types/storybook__react": "3.0.8",
"@types/storybook__addon-actions": "3.4.1",
"@types/storybook__react": "3.0.9",
"avaron": "0.2.0",
"cpy-cli": "2.0.0",
"enzyme": "3.3.0",
"enzyme-adapter-react-16": "1.1.1",
"enzyme": "3.4.4",
"enzyme-adapter-react-16": "1.2.0",
"gh-pages": "1.2.0",

@@ -62,8 +62,8 @@ "light-ts-loader": "1.1.2",

"prettier": "1.13.7",
"react": "16.4.1",
"react-dom": "16.4.1",
"react-test-renderer": "16.4.1",
"react": "16.4.2",
"react-dom": "16.4.2",
"react-test-renderer": "16.4.2",
"rollup": "0.61.1",
"rollup-plugin-babel": "3.0.5",
"rollup-plugin-commonjs": "9.1.3",
"rollup-plugin-commonjs": "9.1.5",
"rollup-plugin-node-globals": "1.2.1",

@@ -74,8 +74,8 @@ "rollup-plugin-node-resolve": "3.3.0",

"rollup-watch": "4.3.1",
"sinon": "6.1.4",
"sinon": "6.1.5",
"tslint": "5.11.0",
"tslint-eslint-rules": "5.3.1",
"tslint-eslint-rules": "5.4.0",
"tslint-plugin-prettier": "1.3.0",
"tslint-react": "3.6.0",
"typescript": "2.9.2"
"typescript": "3.0.1"
},

@@ -89,3 +89,3 @@ "files": [

"dependencies": {
"re-resizable": "4.7.1",
"re-resizable": "4.8.0",
"react-draggable": "3.0.5",

@@ -92,0 +92,0 @@ "tslib": "1.9.3"

@@ -27,4 +27,4 @@ <p align="center"><img src ="https://github.com/bokuweb/react-rnd/blob/master/logo.png?raw=true" /></p>

* [Instance API](#instance-api)
* 🚫 Depreacted [updateSize(size: { width: number | string, height: number | string }): void](#updateSize-void)
* 🚫 Depreacted [updatePosition({ x: number, y: number }): void](#updatePosition-void)
* [updateSize(size: { width: number | string, height: number | string }): void](#updateSize-void)
* [updatePosition({ x: number, y: number }): void](#updatePosition-void)
* [Test](#test)

@@ -52,4 +52,6 @@ * [Related](#related)

[![Edit y3997qply9](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/y3997qply9)
[CodeSandbox(with default)](https://codesandbox.io/s/y3997qply9)
[CodeSandbox(with size and position)](https://codesandbox.io/s/my4kjly94x)
[CodeSandbox(with typescript)](https://codesandbox.io/s/j1vvkpo9wv)

@@ -410,3 +412,3 @@

#### [🚫 Depreacted ] `updateSize(size: { width: string | number, height: string | number })`
#### `updateSize(size: { width: string | number, height: string | number })`

@@ -438,3 +440,3 @@ Update component size.

#### [🚫 Depreacted ] `updatePosition({ x: number, y: number }): void`
#### `updatePosition({ x: number, y: number }): void`

@@ -481,2 +483,6 @@ Update component position.

#### v9.0.1
- fix: Allow additional props in typescript.
#### v9.0.0

@@ -483,0 +489,0 @@

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