!function(){if("undefined"!=typeofself&&self.Prism&&self.document)if(Prism.plugins.toolbar){vari=window.ClipboardJS||void0;i||"function"!=typeofrequire||(i=require("clipboard"));varc=[];if(!i){varo=document.createElement("script"),t=document.querySelector("head");o.onload=function(){if(i=window.ClipboardJS)for(;c.length;)c.pop()()},o.src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.0/clipboard.min.js",t.appendChild(o)}Prism.plugins.toolbar.registerButton("copy-to-clipboard",function(o){vart=document.createElement("button");t.textContent="Copy";vare=o.element;returni?n():c.push(n),t;functionn(){varo=newi(t,{text:function(){returne.textContent}});o.on("success",function(){t.textContent="Copied!",r()}),o.on("error",function(){t.textContent="Press Ctrl+C to copy",r()})}functionr(){setTimeout(function(){t.textContent="Copy"},5e3)}})}elseconsole.warn("Copy to Clipboard plugin loaded before Toolbar plugin.")}();