Sha256: 12edfd208a79cdbd452c9bf2eb925f0905632d6646eb7c45c01eec95f290c384
Contents?: true
Size: 636 Bytes
Versions: 15
Compression:
Stored size: 636 Bytes
Contents
//= depend_on_asset "ZeroClipboard.swf" jQuery -> ZeroClipboard.config({ swfPath: '<%= image_path "ZeroClipboard.swf" %>' }); setup_copy_links = -> ($ 'body').on "click", ".copy-to-clipboard", (e) -> e.preventDefault() $('.copy-to-clipboard').each -> $link = ($ this) clip = new ZeroClipboard( this ) clip.on "copy", (e) -> clip.setText($link.data('clipboard-text')) saved_text = $link.text() $link.text 'Copied!' setTimeout -> $link.text(saved_text) , 2000 setup_copy_links() $(document).on 'updateCopyLinks', -> setup_copy_links()
Version data entries
15 entries across 15 versions & 1 rubygems