Comparing version 8.0.4 to 8.1.0
@@ -6,2 +6,6 @@ # Change Log | ||
## 8.1.0 | ||
- New property `useSingleNodeRotation` for `Konva.Transformer`. | ||
## 8.0.4 | ||
@@ -53,3 +57,3 @@ | ||
- **`konva-node` is merged into `konva` npm package. One package works for both environments.** | ||
- Full event system rewrite. Much better `pointer` evens support. | ||
- Full event system rewrite. Much better `pointer` events support. | ||
- Fix `TextPath` recalculations on `fontSize` change | ||
@@ -56,0 +60,0 @@ - Better typescript support. Now every module has its own `*.d.ts` file. |
@@ -16,3 +16,3 @@ var PI_OVER_180 = Math.PI / 180; | ||
_global: glob, | ||
version: '8.0.4', | ||
version: '8.1.0', | ||
isBrowser: detectBrowser(), | ||
@@ -19,0 +19,0 @@ isUnminified: /param/.test(function (param) { }.toString()), |
@@ -33,2 +33,3 @@ // the purpose of that file is very stupid | ||
export let pixelRatio: number; | ||
export let autoDrawEnabled: boolean; | ||
export let dragDistance: number; | ||
@@ -35,0 +36,0 @@ export let angleDeg: boolean; |
@@ -63,7 +63,7 @@ import { Konva } from './Global.js'; | ||
getContext() { | ||
Util.warn('shape.getContext() method is deprecated. Please don not use it.'); | ||
Util.warn('shape.getContext() method is deprecated. Please do not use it.'); | ||
return this.getLayer().getContext(); | ||
} | ||
getCanvas() { | ||
Util.warn('shape.getCanvas() method is deprecated. Please don not use it.'); | ||
Util.warn('shape.getCanvas() method is deprecated. Please do not use it.'); | ||
return this.getLayer().getCanvas(); | ||
@@ -70,0 +70,0 @@ } |
@@ -32,2 +32,4 @@ import { Transform } from '../Util'; | ||
boundBoxFunc?: (oldBox: Box, newBox: Box) => Box; | ||
useSingleNodeRotation?: boolean; | ||
shouldOverdrawWholeArea?: boolean; | ||
} | ||
@@ -110,2 +112,3 @@ export declare class Transformer extends Group { | ||
shouldOverdrawWholeArea: GetSet<boolean, this>; | ||
useSingleNodeRotation: GetSet<boolean, this>; | ||
} |
@@ -167,3 +167,3 @@ import { Util, Transform } from '../Util.js'; | ||
this._nodes = nodes; | ||
if (nodes.length === 1) { | ||
if (nodes.length === 1 && this.useSingleNodeRotation()) { | ||
this.rotation(nodes[0].getAbsoluteRotation()); | ||
@@ -179,3 +179,3 @@ } | ||
const onChange = () => { | ||
if (this.nodes().length === 1) { | ||
if (this.nodes().length === 1 && this.useSingleNodeRotation()) { | ||
this.rotation(this.nodes()[0].getAbsoluteRotation()); | ||
@@ -938,2 +938,3 @@ } | ||
Factory.addGetterSetter(Transformer, 'shouldOverdrawWholeArea', false); | ||
Factory.addGetterSetter(Transformer, 'useSingleNodeRotation', true); | ||
Factory.backCompat(Transformer, { | ||
@@ -940,0 +941,0 @@ lineEnabled: 'borderEnabled', |
{ | ||
"name": "konva", | ||
"version": "8.0.4", | ||
"version": "8.1.0", | ||
"author": "Anton Lavrenov", | ||
@@ -5,0 +5,0 @@ "files": [ |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
1313922
30835