ng-file-upload icon indicating copy to clipboard operation
ng-file-upload copied to clipboard

Can not disable paste.

Open gbbr opened this issue 7 years ago • 2 comments

This is a bit of an issue on one of the projects I've been working on. I can't find a way to disable paste. If this is possible, please enlighten me and I'll close the issue.

Otherwise, let me know if this is something you'd like and I can pick up a PR and do it.

gbbr avatar Jun 08 '17 11:06 gbbr

@gbbr a workaround for this is to add an extra parameter $event for the action at ngf-drop and then within the action check if the event.type is paste. Then just cancel and/or end any further processing.

simalexan avatar May 09 '18 16:05 simalexan

@simalexan How should I cancel/end any further processing? These doesn't work:

event.preventDefault();
event.stopPropagation();
return false;

I want to add a caption input within the drop area, and the users would like to paste text into the caption field, I can't solve this. Any idea?

Thank you!

csimpi avatar Mar 12 '19 21:03 csimpi