mirror of
https://github.com/konvajs/konva.git
synced 2025-08-20 09:59:34 +08:00
changed const to var
This commit is contained in:
parent
089766c7ae
commit
1adf506a93
@ -213,8 +213,9 @@ describe('RegularPolygon', function () {
|
|||||||
it('limit corner radius', function () {
|
it('limit corner radius', function () {
|
||||||
var stage = addStage();
|
var stage = addStage();
|
||||||
var layer = new Konva.Layer();
|
var layer = new Konva.Layer();
|
||||||
const sides = 5,
|
var sides = 5;
|
||||||
radius = 50;
|
var radius = 50;
|
||||||
|
|
||||||
var poly = new Konva.RegularPolygon({
|
var poly = new Konva.RegularPolygon({
|
||||||
x: 100,
|
x: 100,
|
||||||
y: 100,
|
y: 100,
|
||||||
@ -223,7 +224,7 @@ describe('RegularPolygon', function () {
|
|||||||
fill: 'black',
|
fill: 'black',
|
||||||
cornerRadius: 25,
|
cornerRadius: 25,
|
||||||
});
|
});
|
||||||
const resultCircleRadius = radius * Math.cos(Math.PI / sides);
|
var resultCircleRadius = radius * Math.cos(Math.PI / sides);
|
||||||
|
|
||||||
layer.add(poly);
|
layer.add(poly);
|
||||||
stage.add(layer);
|
stage.add(layer);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user