Comparing version 1.0.0 to 1.0.1
@@ -104,7 +104,21 @@ 'use strict'; | ||
if (didChange) { | ||
this.setState({ | ||
targetIds: targetIds | ||
}, dirtyHandlerIds); | ||
if (!didChange) { | ||
return; | ||
} | ||
var prevInnermostTargetId = prevTargetIds[prevTargetIds.length - 1]; | ||
var innermostTargetId = targetIds[targetIds.length - 1]; | ||
if (prevInnermostTargetId !== innermostTargetId) { | ||
if (prevInnermostTargetId) { | ||
dirtyHandlerIds.push(prevInnermostTargetId); | ||
} | ||
if (innermostTargetId) { | ||
dirtyHandlerIds.push(innermostTargetId); | ||
} | ||
} | ||
this.setState({ | ||
targetIds: targetIds | ||
}, dirtyHandlerIds); | ||
}; | ||
@@ -111,0 +125,0 @@ |
{ | ||
"name": "dnd-core", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Drag and drop sans the GUI", | ||
@@ -5,0 +5,0 @@ "main": "modules/index.js", |
@@ -25,3 +25,3 @@ # dnd-core [![npm package](https://img.shields.io/npm/v/dnd-core.svg?style=flat-square)](https://www.npmjs.org/package/dnd-core) [![Build Status](https://travis-ci.org/gaearon/dnd-core.svg?branch=master)](https://travis-ci.org/gaearon/dnd-core) [![Test Coverage](https://codeclimate.com/github/gaearon/dnd-core/badges/coverage.svg)](https://codeclimate.com/github/gaearon/dnd-core) [![Join the chat at https://gitter.im/gaearon/dnd-core](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/gaearon/dnd-core?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) | ||
All of this should be easy to implement in React DnD (and any other library using dnd-core) once dnd-core matures. | ||
Turns out, these problems are much easier to solve when DOM is thrown out of the window. | ||
@@ -28,0 +28,0 @@ ## What's the API like? |
Sorry, the diff of this file is too big to display
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
496908
3528
0