Skip to content

Commit

Permalink
prevent clicks from being recorded as path
Browse files Browse the repository at this point in the history
  • Loading branch information
bleeptrack committed Sep 25, 2024
1 parent f5b5ebf commit 1c5d704
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions static/PaperCanvas.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,12 @@ export class PaperCanvas extends HTMLElement {
}

tool.onMouseUp = () => {
path.simplify()
this.processLine(path)
if(path.segments.length > 1){
path.simplify()
this.processLine(path)
}else{
path.remove()
}
}
}

Expand Down

0 comments on commit 1c5d704

Please sign in to comment.