소스 검색

redundant lines of code have been removed

miskson 3 년 전
부모
커밋
ad12f2010f
1개의 변경된 파일0개의 추가작업 그리고 4개의 파일을 삭제
  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))