Update App.js

This commit is contained in:
brausjonas
2023-07-07 14:36:33 +02:00
parent c88ee9456b
commit f0b477b5b4
+1 -2
View File
@@ -152,8 +152,7 @@ export default function App() {
context.lineWidth = strokeWidthSliderValue context.lineWidth = strokeWidthSliderValue
context.stroke() context.stroke()
} else if (selectedTool === "selector") { } else if (selectedTool === "selector") {
context.fillStyle = eraserColor context.clearRect(formAnchor.x, formAnchor.y, e.pageX - formAnchor.x, e.pageY - formAnchor.y)
context.fillRect(formAnchor.x, formAnchor.y, e.pageX - formAnchor.x, e.pageY - formAnchor.y)
} else if (selectedTool === "line") { } else if (selectedTool === "line") {
context.strokeStyle = colorValue context.strokeStyle = colorValue
context.beginPath() context.beginPath()