Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: set user-select none on canvas #591

Merged
merged 3 commits into from
Jan 21, 2022
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/signature_pad.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,8 @@ export default class SignaturePad extends SignatureEventTarget {

this.clear();

this.canvas.style.userSelect = 'none';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be in the on function with the other style adjustments. Also remove this style in the off function.


// Enable mouse and touch event handlers
this.on();
}
Expand Down