Comparing version 1.6.0 to 1.6.1
@@ -7,3 +7,11 @@ # Change Log | ||
## [1.6.1][2017-04-25] | ||
### Fixed | ||
- Fix pointer position detection | ||
### Changed | ||
- moved `globalCompositeOperation` property to `Konva.Node` | ||
## [1.6.0][2017-04-21] | ||
@@ -10,0 +18,0 @@ |
{ | ||
"name": "konva", | ||
"version": "1.6.0", | ||
"version": "1.6.1", | ||
"author": "Anton Lavrenov", | ||
@@ -30,9 +30,9 @@ "files": [ | ||
"gulp-jsdoc": "^0.1.5", | ||
"gulp-mocha-phantomjs": "^0.12.0", | ||
"gulp-mocha-phantomjs": "^0.12.1", | ||
"gulp-rename": "^1.2.2", | ||
"gulp-replace": "^0.5.4", | ||
"gulp-uglify": "^2.0.0", | ||
"gulp-util": "^3.0.7", | ||
"mocha": "3.2.0", | ||
"prettier": "^0.19.0" | ||
"gulp-uglify": "^2.1.2", | ||
"gulp-util": "^3.0.8", | ||
"mocha": "3.3.0", | ||
"prettier": "^1.2.2" | ||
}, | ||
@@ -39,0 +39,0 @@ "keywords": [ |
@@ -23,3 +23,3 @@ ![Konva logo](https://raw.githubusercontent.com/konvajs/konvajs.github.io/master/apple-touch-icon-180x180.png) | ||
```html | ||
<script src="https://cdn.rawgit.com/konvajs/konva/1.6.0/konva.min.js"></script> | ||
<script src="https://cdn.rawgit.com/konvajs/konva/1.6.1/konva.min.js"></script> | ||
<div id="container"></div> | ||
@@ -69,6 +69,6 @@ <script> | ||
```html | ||
<script src="https://cdn.rawgit.com/konvajs/konva/1.6.0/konva.min.js"></script> | ||
<script src="https://cdn.rawgit.com/konvajs/konva/1.6.1/konva.min.js"></script> | ||
``` | ||
You can use CDN: [https://cdn.rawgit.com/konvajs/konva/1.6.0/konva.min.js](https://cdn.rawgit.com/konvajs/konva/1.6.0/konva.min.js) | ||
You can use CDN: [https://cdn.rawgit.com/konvajs/konva/1.6.1/konva.min.js](https://cdn.rawgit.com/konvajs/konva/1.6.1/konva.min.js) | ||
@@ -75,0 +75,0 @@ ### 2 Load via AMD (requirejs): |
@@ -789,23 +789,2 @@ (function(Konva) { | ||
Konva.Factory.addGetterSetter( | ||
Konva.Shape, | ||
'globalCompositeOperation', | ||
'source-over' | ||
); | ||
/** | ||
* get/set globalCompositeOperation of a shape | ||
* @name globalCompositeOperation | ||
* @method | ||
* @memberof Konva.Shape.prototype | ||
* @param {Number} blur | ||
* @returns {Number} | ||
* @example | ||
* // get shadow blur | ||
* var globalCompositeOperation = shape.globalCompositeOperation(); | ||
* | ||
* // set shadow blur | ||
* shape.globalCompositeOperation('source-in'); | ||
*/ | ||
Konva.Factory.addGetterSetter(Konva.Shape, 'shadowBlur'); | ||
@@ -812,0 +791,0 @@ |
@@ -699,3 +699,3 @@ (function() { | ||
_setPointerPosition: function(evt) { | ||
var x = null, y = null; | ||
var contentPosition = this._getContentPosition(), x = null, y = null; | ||
evt = evt ? evt : window.event; | ||
@@ -709,9 +709,17 @@ | ||
// get the information for finger #1 | ||
x = touch.offsetX; | ||
y = touch.offsetY; | ||
x = touch.offsetX !== undefined | ||
? touch.offsetX | ||
: touch.clientX - contentPosition.left; | ||
y = touch.offsetY !== undefined | ||
? touch.offsetY | ||
: touch.clientY - contentPosition.top; | ||
} | ||
} else { | ||
// mouse events | ||
x = evt.offsetX; | ||
y = evt.offsetY; | ||
x = evt.offsetX !== undefined | ||
? evt.offsetX | ||
: evt.clientX - contentPosition.left; | ||
y = evt.offsetY !== undefined | ||
? evt.offsetY | ||
: evt.clientY - contentPosition.top; | ||
} | ||
@@ -718,0 +726,0 @@ if (x !== null && y !== null) { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
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
1189991
33783