ZeroClipboard.min.min.js 19 KB

123456789
  1. /*!
  2. * ZeroClipboard
  3. * The ZeroClipboard library provides an easy way to copy text to the clipboard using an invisible Adobe Flash movie and a JavaScript interface.
  4. * Copyright (c) 2014 Jon Rohan, James M. Greene
  5. * Licensed MIT
  6. * http://zeroclipboard.org/
  7. * v2.0.0-beta.5
  8. */
  9. ;!function(a0){var aZ,aY={bridge:null,version:"0.0.0",pluginType:"unknown",disabled:null,outdated:null,unavailable:null,deactivated:null,overdue:null,ready:null},aX={},aW=null,aV=0,aU={},aT=0,aS={},aR=function(){var h,g,l,k,j="ZeroClipboard.swf";if(!document.currentScript||!(k=document.currentScript.src)){var i=document.getElementsByTagName("script");if("readyState" in i[0]){for(h=i.length;h--&&("interactive"!==i[h].readyState||!(k=i[h].src));){}}else{if("loading"===document.readyState){k=i[i.length-1].src}else{for(h=i.length;h--;){if(l=i[h].src,!l){g=null;break}if(l=l.split("#")[0].split("?")[0],l=l.slice(0,l.lastIndexOf("/")+1),null==g){g=l}else{if(g!==l){g=null;break}}}null!==g&&(k=g)}}}return k&&(k=k.split("#")[0].split("?")[0],j=k.slice(0,k.lastIndexOf("/")+1)+j),j}(),aQ=function(){var d=/\-([a-z])/g,c=function(f,e){return e.toUpperCase()};return function(a){return a.replace(d,c)}}(),aP=function(a,j){var i,h,g;return a0.getComputedStyle?i=a0.getComputedStyle(a,null).getPropertyValue(j):(h=aQ(j),i=a.currentStyle?a.currentStyle[h]:a.style[h]),"cursor"!==j||i&&"auto"!==i||(g=a.tagName.toLowerCase(),"a"!==g)?i:"pointer"},aO=function(a){a||(a=a0.event);var d;this!==a0?d=this:a.target?d=a.target:a.srcElement&&(d=a.srcElement),ao.activate(d)},aN=function(e,d,f){e&&1===e.nodeType&&(e.addEventListener?e.addEventListener(d,f,!1):e.attachEvent&&e.attachEvent("on"+d,f))},aM=function(e,d,f){e&&1===e.nodeType&&(e.removeEventListener?e.removeEventListener(d,f,!1):e.detachEvent&&e.detachEvent("on"+d,f))},aL=function(i,h){if(!i||1!==i.nodeType){return i}if(i.classList){return i.classList.contains(h)||i.classList.add(h),i}if(h&&"string"==typeof h){var n=(h||"").split(/\s+/);if(1===i.nodeType){if(i.className){for(var m=" "+i.className+" ",l=i.className,k=0,j=n.length;j>k;k++){m.indexOf(" "+n[k]+" ")<0&&(l+=" "+n[k])}i.className=l.replace(/^\s+|\s+$/g,"")}else{i.className=h}}}return i},aK=function(h,g){if(!h||1!==h.nodeType){return h}if(h.classList){return h.classList.contains(g)&&h.classList.remove(g),h}if(g&&"string"==typeof g||void 0===g){var l=(g||"").split(/\s+/);if(1===h.nodeType&&h.className){if(g){for(var k=(" "+h.className+" ").replace(/[\n\t]/g," "),j=0,i=l.length;i>j;j++){k=k.replace(" "+l[j]+" "," ")}h.className=k.replace(/^\s+|\s+$/g,"")}else{h.className=""}}}return h},aJ=function(){var f,e,h,g=1;return"function"==typeof document.body.getBoundingClientRect&&(f=document.body.getBoundingClientRect(),e=f.right-f.left,h=document.body.offsetWidth,g=Math.round(e/h*100)/100),g},aI=function(r,q){var p={left:0,top:0,width:0,height:0,zIndex:aC(q)-1};if(r.getBoundingClientRect){var o,n,m,l=r.getBoundingClientRect();"pageXOffset" in a0&&"pageYOffset" in a0?(o=a0.pageXOffset,n=a0.pageYOffset):(m=aJ(),o=Math.round(document.documentElement.scrollLeft/m),n=Math.round(document.documentElement.scrollTop/m));var k=document.documentElement.clientLeft||0,a=document.documentElement.clientTop||0;p.left=l.left+o-k,p.top=l.top+n-a,p.width="width" in l?l.width:l.right-l.left,p.height="height" in l?l.height:l.bottom-l.top}return p},aH=function(e,d){var f=null==d||d&&d.cacheBust===!0;return f?(-1===e.indexOf("?")?"?":"&")+"noCache="+(new Date).getTime():""},aG=function(a){var n,m,l,k,j="",i=[];if(a.trustedDomains&&("string"==typeof a.trustedDomains?k=[a.trustedDomains]:"object"==typeof a.trustedDomains&&"length" in a.trustedDomains&&(k=a.trustedDomains)),k&&k.length){for(n=0,m=k.length;m>n;n++){if(k.hasOwnProperty(n)&&k[n]&&"string"==typeof k[n]){if(l=aA(k[n]),!l){continue}if("*"===l){i=[l];break}i.push.apply(i,[l,"//"+l,a0.location.protocol+"//"+l])}}}return i.length&&(j+="trustedOrigins="+encodeURIComponent(i.join(","))),a.forceEnhancedClipboard===!0&&(j+=(j?"&":"")+"forceEnhancedClipboard=true"),j},aF=function(g,f,j){if("function"==typeof f.indexOf){return f.indexOf(g,j)}var i,h=f.length;for("undefined"==typeof j?j=0:0>j&&(j=h+j),i=j;h>i;i++){if(f.hasOwnProperty(i)&&f[i]===g){return i}}return -1},aE=function(b){if("string"==typeof b){throw new TypeError("ZeroClipboard doesn't accept query strings.")}return"number"!=typeof b.length?[b]:b},aD=function(a,h,g,f){f?a0.setTimeout(function(){a.apply(h,g)},0):a.apply(h,g)},aC=function(e){var d,f;return e&&("number"==typeof e&&e>0?d=e:"string"==typeof e&&(f=parseInt(e,10))&&!isNaN(f)&&f>0&&(d=f)),d||("number"==typeof al.zIndex&&al.zIndex>0?d=al.zIndex:"string"==typeof al.zIndex&&(f=parseInt(al.zIndex,10))&&!isNaN(f)&&f>0&&(d=f)),d||0},aB=function(){var i,h,n,m,l,k,j=arguments[0]||{};for(i=1,h=arguments.length;h>i;i++){if(null!=(n=arguments[i])){for(m in n){if(n.hasOwnProperty(m)){if(l=j[m],k=n[m],j===k){continue}void 0!==k&&(j[m]=k)}}}}return j},aA=function(e){if(null==e||""===e){return null}if(e=e.replace(/^\s+|\s+$/g,""),""===e){return null}var d=e.indexOf("//");e=-1===d?e:e.slice(d+2);var f=e.indexOf("/");return e=-1===f?e:-1===d||0===f?null:e.slice(0,f),e&&".swf"===e.slice(-4).toLowerCase()?null:e||null},az=function(){var b=function(g,f){var j,i,h;if(null!=g&&"*"!==f[0]&&("string"==typeof g&&(g=[g]),"object"==typeof g&&"number"==typeof g.length)){for(j=0,i=g.length;i>j;j++){if(g.hasOwnProperty(j)&&(h=aA(g[j]))){if("*"===h){f.length=0,f.push("*");break}-1===aF(h,f)&&f.push(h)}}}};return function(a,j){var i=aA(j.swfPath);null===i&&(i=a);var h=[];b(j.trustedOrigins,h),b(j.trustedDomains,h);var g=h.length;if(g>0){if(1===g&&"*"===h[0]){return"always"}if(-1!==aF(a,h)){return 1===g&&a===i?"sameDomain":"always"}}return"never"}}(),ay=function(e){if(null==e){return[]}if(Object.keys){return Object.keys(e)}var d=[];for(var f in e){e.hasOwnProperty(f)&&d.push(f)}return d},ax=function(d){if(d){for(var c in d){d.hasOwnProperty(c)&&delete d[c]}}return d},aw=function(){try{return document.activeElement}catch(b){}return null},av=function(g,f){for(var j={},i=0,h=f.length;h>i;i++){f[i] in g&&(j[f[i]]=g[f[i]])}return j},au=function(f,e){var h={};for(var g in f){-1===aF(g,e)&&(h[g]=f[g])}return h},at=function(f){var e={},h={};if("object"==typeof f&&f){for(var g in f){if(g&&f.hasOwnProperty(g)&&"string"==typeof f[g]&&f[g]){switch(g.toLowerCase()){case"text/plain":case"text":case"air:text":case"flash:text":e.text=f[g],h.text=g;break;case"text/html":case"html":case"air:html":case"flash:html":e.html=f[g],h.html=g;break;case"application/rtf":case"text/rtf":case"rtf":case"richtext":case"air:rtf":case"flash:rtf":e.rtf=f[g],h.rtf=g}}}return{data:e,formatMap:h}}},ar=function(h,g){if("object"!=typeof h||!h||"object"!=typeof g||!g){return h}var l={};for(var k in h){if(h.hasOwnProperty(k)){if("success"!==k&&"data"!==k){l[k]=h[k];continue}l[k]={};var j=h[k];for(var i in j){i&&j.hasOwnProperty(i)&&g.hasOwnProperty(i)&&(l[k][g[i]]=j[i])}}}return l},aq=function(b){return function(a){return b.call(a,0)}}(a0.Array.prototype.slice),ap=function(){function z(e){var d=e.match(/[\d]+/g);return d.length=3,d.join(".")}function y(b){return !!b&&(b=b.toLowerCase())&&(/^(pepflashplayer\.dll|libpepflashplayer\.so|pepperflashplayer\.plugin)$/.test(b)||"chrome.plugin"===b.slice(-13))}function x(a){a&&(t=!0,a.version&&(q=z(a.version)),!q&&a.description&&(q=z(a.description)),a.filename&&(r=y(a.filename)))}var w,v,u,t=!1,s=!1,r=!1,q="";if(navigator.plugins&&navigator.plugins.length){w=navigator.plugins["Shockwave Flash"],x(w),navigator.plugins["Shockwave Flash 2.0"]&&(t=!0,q="2.0.0.11")}else{if(navigator.mimeTypes&&navigator.mimeTypes.length){u=navigator.mimeTypes["application/x-shockwave-flash"],w=u&&u.enabledPlugin,x(w)}else{if("undefined"!=typeof ActiveXObject){s=!0;try{v=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7"),t=!0,q=z(v.GetVariable("$version"))}catch(p){try{v=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"),t=!0,q="6.0.21"}catch(o){try{v=new ActiveXObject("ShockwaveFlash.ShockwaveFlash"),t=!0,q=z(v.GetVariable("$version"))}catch(c){s=!1}}}}}}aY.disabled=t!==!0,aY.outdated=q&&parseFloat(q)<11,aY.version=q||"0.0.0",aY.pluginType=r?"pepper":s?"activex":t?"netscape":"unknown"};ap();var ao=function(e){if(!(this instanceof ao)){return new ao(e)}if(this.id=""+aV++,aU[this.id]={instance:this,elements:[],handlers:{}},e&&this.clip(e),"boolean"!=typeof aY.ready&&(aY.ready=!1),!ao.isFlashUnusable()&&null===aY.bridge){var c=this,f=al.flashLoadTimeout;"number"==typeof f&&f>=0&&setTimeout(function(){"boolean"!=typeof aY.deactivated&&(aY.deactivated=!0),aY.deactivated===!0&&ao.emit({type:"error",name:"flash-deactivated",client:c})},f),aY.overdue=!1,ak()}};ao.prototype.setText=function(b){return ao.setData("text/plain",b),this},ao.prototype.setHtml=function(b){return ao.setData("text/html",b),this},ao.prototype.setRichText=function(b){return ao.setData("application/rtf",b),this},ao.prototype.setData=function(){return ao.setData.apply(ao,aq(arguments)),this},ao.prototype.clearData=function(){return ao.clearData.apply(ao,aq(arguments)),this},ao.prototype.setSize=function(d,c){return ag(d,c),this};var an=function(b){aY.ready===!0&&aY.bridge&&"function"==typeof aY.bridge.setHandCursor?aY.bridge.setHandCursor(b):aY.ready=!1};ao.prototype.destroy=function(){this.unclip(),this.off(),delete aU[this.id]};var am=function(){var g,f,j,i=[],h=ay(aU);for(g=0,f=h.length;f>g;g++){j=aU[h[g]].instance,j&&j instanceof ao&&i.push(j)}return i};ao.version="2.0.0-beta.5";var al={swfPath:aR,trustedDomains:a0.location.host?[a0.location.host]:[],cacheBust:!0,forceHandCursor:!1,forceEnhancedClipboard:!1,zIndex:999999999,debug:!1,title:null,autoActivate:!0,flashLoadTimeout:30000};ao.isFlashUnusable=function(){return !!(aY.disabled||aY.outdated||aY.unavailable||aY.deactivated)},ao.config=function(e){"object"==typeof e&&null!==e&&aB(al,e);if("string"!=typeof e||!e){var d={};for(var f in al){al.hasOwnProperty(f)&&(d[f]="object"==typeof al[f]&&null!==al[f]?"length" in al[f]?al[f].slice(0):aB({},al[f]):al[f])}return d}if(al.hasOwnProperty(e)){return al[e]}},ao.destroy=function(){ao.deactivate();for(var g in aU){if(aU.hasOwnProperty(g)&&aU[g]){var c=aU[g].instance;c&&"function"==typeof c.destroy&&c.destroy()}}var j=aY.bridge;if(j){var i=ai(j);i&&("activex"===aY.pluginType&&"readyState" in j?(j.style.display="none",function h(){if(4===j.readyState){for(var b in j){"function"==typeof j[b]&&(j[b]=null)}j.parentNode.removeChild(j),i.parentNode&&i.parentNode.removeChild(i)}else{setTimeout(h,10)}}()):(j.parentNode.removeChild(j),i.parentNode&&i.parentNode.removeChild(i))),aY.ready=null,aY.bridge=null,aY.deactivated=null}ao.clearData()},ao.activate=function(b){aZ&&(aK(aZ,al.hoverClass),aK(aZ,al.activeClass)),aZ=b,aL(b,al.hoverClass),ah();var h=al.title||b.getAttribute("title");if(h){var g=ai(aY.bridge);g&&g.setAttribute("title",h)}var c=al.forceHandCursor===!0||"pointer"===aP(b,"cursor");an(c)},ao.deactivate=function(){var b=ai(aY.bridge);b&&(b.removeAttribute("title"),b.style.left="0px",b.style.top="-9999px",ag(1,1)),aZ&&(aK(aZ,al.hoverClass),aK(aZ,al.activeClass),aZ=null)},ao.state=function(){return{browser:av(a0.navigator,["userAgent","platform","appName"]),flash:au(aY,["bridge"]),zeroclipboard:{version:ao.version,config:ao.config()}}},ao.setData=function(f,d){var h;if("object"==typeof f&&f&&"undefined"==typeof d){h=f,ao.clearData()}else{if("string"!=typeof f||!f){return}h={},h[f]=d}for(var g in h){g&&h.hasOwnProperty(g)&&"string"==typeof h[g]&&h[g]&&(aX[g]=h[g])}},ao.clearData=function(b){"undefined"==typeof b?(ax(aX),aW=null):"string"==typeof b&&aX.hasOwnProperty(b)&&delete aX[b]};var ak=function(){var t,s,r=document.getElementById("global-zeroclipboard-html-bridge");if(!r){var q=az(a0.location.host,al),p="never"===q?"none":"all",o=aG(al),n=al.swfPath+aH(al.swfPath,al);r=aj();var m=document.createElement("div");r.appendChild(m),document.body.appendChild(r);var c=document.createElement("div"),a="activex"===aY.pluginType;c.innerHTML='<object id="global-zeroclipboard-flash-bridge" name="global-zeroclipboard-flash-bridge" width="100%" height="100%" '+(a?'classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"':'type="application/x-shockwave-flash" data="'+n+'"')+">"+(a?'<param name="movie" value="'+n+'"/>':"")+'<param name="allowScriptAccess" value="'+q+'"/><param name="allowNetworking" value="'+p+'"/><param name="menu" value="false"/><param name="wmode" value="transparent"/><param name="flashvars" value="'+o+'"/></object>',t=c.firstChild,c=null,t.ZeroClipboard=ao,r.replaceChild(t,m)}t||(t=document["global-zeroclipboard-flash-bridge"],t&&(s=t.length)&&(t=t[s-1]),t||(t=r.firstChild)),aY.bridge=t||null},aj=function(){var b=document.createElement("div");return b.id="global-zeroclipboard-html-bridge",b.className="global-zeroclipboard-container",b.style.position="absolute",b.style.left="0px",b.style.top="-9999px",b.style.width="1px",b.style.height="1px",b.style.zIndex=""+aC(al.zIndex),b},ai=function(d){for(var c=d&&d.parentNode;c&&"OBJECT"===c.nodeName&&c.parentNode;){c=c.parentNode}return c||null},ah=function(){if(aZ){var b=aI(aZ,al.zIndex),c=ai(aY.bridge);c&&(c.style.top=b.top+"px",c.style.left=b.left+"px",c.style.width=b.width+"px",c.style.height=b.height+"px",c.style.zIndex=b.zIndex+1),ag(b.width,b.height)}},ag=function(e,c){var f=ai(aY.bridge);f&&(f.style.width=e+"px",f.style.height=c+"px")};ao.emit=function(t){var s,r,q,p,o,e,d,c,a;if("string"==typeof t&&t&&(s=t),"object"==typeof t&&t&&"string"==typeof t.type&&t.type&&(s=t.type,r=t),s){if(t=ad(s,r),ab(t),"ready"===t.type&&aY.overdue===!0){return ao.emit({type:"error",name:"flash-overdue"})}if(q=!/^(before)?copy$/.test(t.type),t.client){af.call(t.client,t,q)}else{for(p=t.target&&t.target!==a0&&al.autoActivate===!0?aa(t.target):am(),o=0,e=p.length;e>o;o++){d=aB({},t,{client:p[o]}),af.call(p[o],d,q)}}return"copy"===t.type&&(a=at(aX),c=a.data,aW=a.formatMap),c}};var af=function(a,p){var o=aU[this.id]&&aU[this.id].handlers[a.type];if(o&&o.length){var n,m,l,k,g=this;for(n=0,m=o.length;m>n;n++){l=o[n],k=g,"string"==typeof l&&"function"==typeof a0[l]&&(l=a0[l]),"object"==typeof l&&l&&"function"==typeof l.handleEvent&&(k=l,l=l.handleEvent),"function"==typeof l&&aD(l,k,[a],p)}}return this},ae={ready:"Flash communication is established",error:{"flash-disabled":"Flash is disabled or not installed","flash-outdated":"Flash is too outdated to support ZeroClipboard","flash-unavailable":"Flash is unable to communicate bidirectionally with JavaScript","flash-deactivated":"Flash is too outdated for your browser and/or is configured as click-to-activate","flash-overdue":"Flash communication was established but NOT within the acceptable time limit"}},ad=function(b,e){if(b||e&&e.type){e=e||{},b=(b||e.type).toLowerCase(),aB(e,{type:b,target:e.target||aZ||null,relatedTarget:e.relatedTarget||null,currentTarget:aY&&aY.bridge||null});var c=ae[e.type];return"error"===e.type&&e.name&&c&&(c=c[e.name]),c&&(e.message=c),"ready"===e.type&&aB(e,{target:null,version:aY.version}),"error"===e.type&&(e.target=null,/^flash-(outdated|unavailable|deactivated|overdue)$/.test(e.name)&&aB(e,{version:aY.version,minimumVersion:"11.0.0"})),"copy"===e.type&&(e.clipboardData={setData:ao.setData,clearData:ao.clearData}),"aftercopy"===e.type&&(e=ar(e,aW)),e.target&&!e.relatedTarget&&(e.relatedTarget=ac(e.target)),e}},ac=function(d){var c=d&&d.getAttribute&&d.getAttribute("data-clipboard-target");return c?document.getElementById(c):null},ab=function(b){var l=b.target||aZ;switch(b.type){case"error":aF(b.name,["flash-disabled","flash-outdated","flash-deactivated","flash-overdue"])&&aB(aY,{disabled:"flash-disabled"===b.name,outdated:"flash-outdated"===b.name,unavailable:"flash-unavailable"===b.name,deactivated:"flash-deactivated"===b.name,overdue:"flash-overdue"===b.name,ready:!1});break;case"ready":var k=aY.deactivated===!0;aB(aY,{disabled:!1,outdated:!1,unavailable:!1,deactivated:!1,overdue:k,ready:!k});break;case"copy":var j,d,c=b.relatedTarget;!aX["text/html"]&&!aX["text/plain"]&&c&&(d=c.value||c.outerHTML||c.innerHTML)&&(j=c.value||c.textContent||c.innerText)?(b.clipboardData.clearData(),b.clipboardData.setData("text/plain",j),d!==j&&b.clipboardData.setData("text/html",d)):!aX["text/plain"]&&b.target&&(j=b.target.getAttribute("data-clipboard-text"))&&(b.clipboardData.clearData(),b.clipboardData.setData("text/plain",j));break;case"aftercopy":ao.clearData(),l&&l!==aw()&&l.focus&&l.focus();break;case"mouseover":aL(l,al.hoverClass);break;case"mouseout":al.autoActivate===!0&&ao.deactivate();break;case"mousedown":aL(l,al.activeClass);break;case"mouseup":aK(l,al.activeClass)}};ao.prototype.on=function(g,c){var p,o,n,m={},l=aU[this.id]&&aU[this.id].handlers;if("string"==typeof g&&g){n=g.toLowerCase().split(/\s+/)}else{if("object"==typeof g&&g&&"undefined"==typeof c){for(p in g){g.hasOwnProperty(p)&&"string"==typeof p&&p&&"function"==typeof g[p]&&this.on(p,g[p])}}}if(n&&n.length){for(p=0,o=n.length;o>p;p++){g=n[p].replace(/^on/,""),m[g]=!0,l[g]||(l[g]=[]),l[g].push(c)}if(m.ready&&aY.ready&&ao.emit({type:"ready",client:this}),m.error){var k=["disabled","outdated","unavailable","deactivated","overdue"];for(p=0,o=k.length;o>p;p++){if(aY[k[p]]){ao.emit({type:"error",name:"flash-"+k[p],client:this});break}}}}return this},ao.prototype.off=function(j,g){var p,o,n,m,l,k=aU[this.id]&&aU[this.id].handlers;if(0===arguments.length){m=ay(k)}else{if("string"==typeof j&&j){m=j.split(/\s+/)}else{if("object"==typeof j&&j&&"undefined"==typeof g){for(p in j){j.hasOwnProperty(p)&&"string"==typeof p&&p&&"function"==typeof j[p]&&this.off(p,j[p])}}}}if(m&&m.length){for(p=0,o=m.length;o>p;p++){if(j=m[p].toLowerCase().replace(/^on/,""),l=k[j],l&&l.length){if(g){for(n=aF(g,l);-1!==n;){l.splice(n,1),n=aF(g,l,n)}}else{k[j].length=0}}}}return this},ao.prototype.handlers=function(f){var e,h=null,g=aU[this.id]&&aU[this.id].handlers;if(g){if("string"==typeof f&&f){return g[f]?g[f].slice(0):null}h={};for(e in g){g.hasOwnProperty(e)&&g[e]&&(h[e]=g[e].slice(0))}}return h},ao.prototype.clip=function(e){e=aE(e);for(var d=0;d<e.length;d++){if(e.hasOwnProperty(d)&&e[d]&&1===e[d].nodeType){e[d].zcClippingId?-1===aF(this.id,aS[e[d].zcClippingId])&&aS[e[d].zcClippingId].push(this.id):(e[d].zcClippingId="zcClippingId_"+aT++,aS[e[d].zcClippingId]=[this.id],al.autoActivate===!0&&aN(e[d],"mouseover",aO));var f=aU[this.id].elements;-1===aF(e[d],f)&&f.push(e[d])}}return this},ao.prototype.unclip=function(h){var g=aU[this.id];if(!g){return this}var l,k=g.elements;h="undefined"==typeof h?k.slice(0):aE(h);for(var j=h.length;j--;){if(h.hasOwnProperty(j)&&h[j]&&1===h[j].nodeType){for(l=0;-1!==(l=aF(h[j],k,l));){k.splice(l,1)}var i=aS[h[j].zcClippingId];if(i){for(l=0;-1!==(l=aF(this.id,i,l));){i.splice(l,1)}0===i.length&&(al.autoActivate===!0&&aM(h[j],"mouseover",aO),delete h[j].zcClippingId)}}}return this},ao.prototype.elements=function(){var b=aU[this.id];return b&&b.elements?b.elements.slice(0):[]};var aa=function(i){var g,n,m,l,k,j=[];if(i&&1===i.nodeType&&(g=i.zcClippingId)&&aS.hasOwnProperty(g)&&(n=aS[g],n&&n.length)){for(m=0,l=n.length;l>m;m++){k=aU[n[m]].instance,k&&k instanceof ao&&j.push(k)}}return j};al.hoverClass="zeroclipboard-is-hover",al.activeClass="zeroclipboard-is-active","function"==typeof define&&define.amd?define(function(){return ao}):"object"==typeof module&&module&&"object"==typeof module.exports&&module.exports?module.exports=ao:a0.ZeroClipboard=ao}(function(){return this}());