Browse Source

redundant lines of code have been removed

miskson 2 năm trước cách đây
mục cha
commit
ad12f2010f
1 tập tin đã thay đổi với 0 bổ sung4 xóa
  1. 0 4
      spin-btns/scripts.js

+ 0 - 4
spin-btns/scripts.js

@@ -47,13 +47,10 @@ function Control(el, { value = 0,
     }
 
     img.onclick = e => {
-        console.log(e, img.width)
-
         const { layerX } = e
         const { width } = img
         
         layerX > width / 2? this.setValue(value + step) : this.setValue(value - step)
-        console.log(value)
     }
 
     const toDeg = rad => ((rad * 180) / Math.PI + 360 + 90) % 360
@@ -69,7 +66,6 @@ function Control(el, { value = 0,
 
     img.onmousemove = e => {
         if (prevMouseAngle === null) return
-        console.log(value)
         const y = e.layerY - img.height / 2
         const x = e.layerX - img.width / 2
         let currentAngle = toDeg(Math.atan2(y, x))