Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
initCrop() {
return new Konva.Circle({
x: this.halfWidth,
y: this.halfHeight,
radius: this.cropRadius,
fillPatternImage: this.image,
fillPatternOffset: {
x: this.halfWidth / this.scale,
y: this.halfHeight / this.scale
},
fillPatternScale: {
x: this.scale,
y: this.scale
},
opacity: 1,
draggable: true,
dashEnabled: true,
dash: [10, 5]
initCropStroke() {
return new Konva.Circle({
x: this.halfWidth,
y: this.halfHeight,
radius: this.cropRadius,
stroke: this.cropColor,
strokeWidth: this.lineWidth,
strokeScaleEnabled: true,
dashEnabled: true,
dash: [10, 5]
})
}