ember-cli-zero-clipboard
ember-cli-zero-clipboard copied to clipboard
"Error: An invalid exception was thrown." when mousing over
Hi, In my production environment I am experiencing exactly this issue.
Is there any particular aspect to consider for deployment? this is how I am using it:
{{#my-zero-clipboard text=model.sharingViewUrl errorAction="ackFlashUnavailable" afterCopyAction="alertAfterCopy" tagName='button' classNames="btn btn-warning"}}
{{t 'ledger.share.view_link'}}
{{/my-zero-clipboard}}
{{#if model.sharingAdminUrl}}
<br><br>
{{#my-zero-clipboard text=model.sharingAdminUrl errorAction="ackFlashUnavailable" afterCopyAction="alertAfterCopy" tagName='button' classNames="btn btn-danger" }}
{{t 'ledger.share.admin_link'}}
{{/my-zero-clipboard}}
{{/if}}
and this is the component:
import Ember from 'ember';
import ZeroClipboard from 'ember-cli-zero-clipboard/components/zero-clipboard';
export default ZeroClipboard.extend({
// title: null,
actions: {
afterCopy(){
this.sendAction('afterCopyAction');
},
error(argument) {
console.warn(argument.name);
this.sendAction('errorAction');
}
}
});
I am also running into the infamous hand cursor issue using 2.2. Here I am on an http webpage,
<script src="//cdnjs.cloudflare.com/ajax/libs/zeroclipboard/2.2.0/ZeroClipboard.js"></script>
and
ZeroClipboard.config({ swfPath: "//cdnjs.cloudflare.com/ajax/libs/zeroclipboard/2.2.0/ZeroClipboard.swf" });
As soon as I mouse over the button, it throws the error.
I am also getting the same thing as @tofutim, same links as well.