-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Container option #368
Container option #368
Conversation
@zenorocha any progress on this? This would also solve an issue when using with Happy to help make improvements to get it moving. |
new Clipboard('.btn', { | ||
container: document.getElementById('#modal') | ||
}); | ||
``` |
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.
This issue isn't exclusive to bootstrap — you get the same issue with react-modal2
or any other library that changes the focus.
Might be worth clarifying this?
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.
@iest updated the text
Any chance this might get merged anytime soon? :) |
I would like to see this also. I need to refer to |
+1 for getting this resolved and merged |
Thanks for merging this I had run into an issue with jQuery Mobile popups. I suspect this library with this PR will fix this. If only I knew about the issues I would see when I decided to use SO to come up with a copy script rather then use your library. Then maybe I wouldn't have spent 5 hours debugging. well, Still probably would have, but would have found the container option faster. https://stackoverflow.com/questions/44303217/why-does-copying-stop-working-from-the-context-menu |
Implements the container option from clipboard.js (zenorocha/clipboard.js#368)
Same issue as in 902e484. In some browser (eg. firefox) the container parameter of ClipboardJS is needed if the focus is inside the modal so the copy work. See information on: zenorocha/clipboard.js#368 opw-1902040 closes odoo#28117
Same issue as in 902e484. In some browser (eg. firefox) the container parameter of ClipboardJS is needed if the focus is inside the modal so the copy work. See information on: zenorocha/clipboard.js#368 opw-1902040 closes #28117
* Allow container option to fix bugs related to bootstrap modals etc. * Updated readme to reflect addition of container option * Name link * Removed test log * Remove unwanted whitespace * Refactored description
This reverts commit 57c3e72.
This reverts commit 88678d7.
PR based on code changes/idea by @alexalexalex-s #155 (comment)
Fixes issues with using clipboard in bootstrap modals etc.