replaced type Coordinates by existing type Vector2d

This commit is contained in:
Thomas Röggla 2017-09-28 14:30:23 +01:00
parent b6687d54a9
commit 93e21434bc

11
konva.d.ts vendored
View File

@ -6,11 +6,6 @@ declare module Konva {
var isDragReady: () => boolean; var isDragReady: () => boolean;
var DD: any; var DD: any;
interface Coordinates {
x: number;
y: number;
}
export class Util { export class Util {
static getRandomColor(): string; static getRandomColor(): string;
static getRGB(color: string): string; static getRGB(color: string): string;
@ -90,7 +85,7 @@ declare module Konva {
offsetY?: number; offsetY?: number;
draggable?: boolean; draggable?: boolean;
dragDistance?: number; dragDistance?: number;
dragBoundFunc?: (pos: Coordinates) => Coordinates; dragBoundFunc?: (pos: Vector2d) => Vector2d;
} }
interface SizeConfig { interface SizeConfig {
@ -129,8 +124,8 @@ declare module Konva {
clone(attrs?: NodeConfig): Node; clone(attrs?: NodeConfig): Node;
destroy(): void; destroy(): void;
dragBoundFunc(): (pos: Coordinates) => Coordinates; dragBoundFunc(): (pos: Vector2d) => Vector2d;
dragBoundFunc(dragBoundFunc: (pos: Coordinates) => Coordinates): Node; dragBoundFunc(dragBoundFunc: (pos: Vector2d) => Vector2d): Node;
draggable(): boolean; draggable(): boolean;
draggable(draggable: boolean): Node; draggable(draggable: boolean): Node;
draw(): Node; draw(): Node;