-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Fixed paste key in IE11 #334
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
Conversation
src/handlers/Clipboard.js
Outdated
| if (ev.clipboardData) { | ||
| var text = ev.clipboardData.getData('text/plain'); | ||
|
|
||
| var paste = function() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Please add a
textargument to the function. - I would prefer it if the function was renamed to something more semantic like
dispatchPaste
src/handlers/Clipboard.js
Outdated
| if (userAgent.match(/msie|MSIE/) || userAgent.match(/(T|t)rident/)) { | ||
| if (window.clipboardData) { | ||
| var text = window.clipboardData.getData('Text'); | ||
| paste(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please call this as paste(text).
src/handlers/Clipboard.js
Outdated
| } else { | ||
| if (ev.clipboardData) { | ||
| var text = ev.clipboardData.getData('text/plain'); | ||
| paste(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please call this as paste(text).
|
Thanks for this @hiro-su! Just a few code comments to be fixed and I think it's good to go. |
20e7b92 to
77ca154
Compare
|
@parisk Thank you for review. I made some changes to pr. Can you be able to check them? |
|
Great @hiro-su, thanks! |
|
@hiro-su just letting you know that we mentioned you for this contribution (along with #339 and #345), in the 2.1 announcement. Thank you! |
hello, i always use this project.
can't get data
ev.clipboardDatain IE11.this pr will fix it, so please check.