# code-block-pro/1.1.0/build/front/front.js

Code Block Pro – Beautiful Syntax Highlighting, version 1.1.0. 1 lines.

- Page: https://pluginprobe.com/plugins/code-block-pro/1.1.0/code/build/front/front.js
- Raw: https://pluginprobe.com/plugins/code-block-pro/1.1.0/raw/build/front/front.js
- Modified: 2022-08-22T22:25:46+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/code-block-pro/1.1.0/code/build/front/front.js#L10-L20`.

```javascript
(()=>{var e={640:(e,t,o)=>{"use strict";var a=o(742),r={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,t){var o,n,c,l,s,i,d=!1;t||(t={}),o=t.debug||!1;try{if(c=a(),l=document.createRange(),s=document.getSelection(),(i=document.createElement("span")).textContent=e,i.ariaHidden="true",i.style.all="unset",i.style.position="fixed",i.style.top=0,i.style.clip="rect(0, 0, 0, 0)",i.style.whiteSpace="pre",i.style.webkitUserSelect="text",i.style.MozUserSelect="text",i.style.msUserSelect="text",i.style.userSelect="text",i.addEventListener("copy",(function(a){if(a.stopPropagation(),t.format)if(a.preventDefault(),void 0===a.clipboardData){o&&console.warn("unable to use e.clipboardData"),o&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var n=r[t.format]||r.default;window.clipboardData.setData(n,e)}else a.clipboardData.clearData(),a.clipboardData.setData(t.format,e);t.onCopy&&(a.preventDefault(),t.onCopy(a.clipboardData))})),document.body.appendChild(i),l.selectNodeContents(i),s.addRange(l),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");d=!0}catch(a){o&&console.error("unable to copy using execCommand: ",a),o&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),d=!0}catch(a){o&&console.error("unable to copy using clipboardData: ",a),o&&console.error("falling back to prompt"),n=function(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}("message"in t?t.message:"Copy to clipboard: #{key}, Enter"),window.prompt(n,e)}}finally{s&&("function"==typeof s.removeRange?s.removeRange(l):s.removeAllRanges()),i&&document.body.removeChild(i),c()}return d}},742:e=>{e.exports=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,o=[],a=0;a<e.rangeCount;a++)o.push(e.getRangeAt(a));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null}return e.removeAllRanges(),function(){"Caret"===e.type&&e.removeAllRanges(),e.rangeCount||o.forEach((function(t){e.addRange(t)})),t&&t.focus()}}}},t={};function o(a){var r=t[a];if(void 0!==r)return r.exports;var n=t[a]={exports:{}};return e[a](n,n.exports,o),n.exports}o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},o.d=(e,t)=>{for(var a in t)o.o(t,a)&&!o.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";var e=o(640),t=o.n(e);addEventListener("DOMContentLoaded",(()=>{Array.from(document.querySelectorAll(".code-block-pro-copy-button")).forEach((e=>{e.style.display="block",e.addEventListener("click",(e=>{var o,a,r;const n=null===(o=e.target)||void 0===o?void 0:o.closest("span");t()(null!==(a=null==n||null===(r=n.dataset)||void 0===r?void 0:r.code)&&void 0!==a?a:"",{format:"text/plain"}),n.classList.add("copying"),setTimeout((()=>{n.classList.remove("copying")}),1e3)}))}))}))})()})();
```
