open-consul/website/build/javascripts/prettify-b9b477f7.js

1 line
14 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

!function(){var t=null;window.PR_SHOULD_USE_CONTINUATION=!0,function(){function e(t){function e(t){var e=t.charCodeAt(0);if(92!==e)return e;var n=t.charAt(1);return(e=h[n])?e:n>="0"&&"7">=n?parseInt(t.substring(1),8):"u"===n||"x"===n?parseInt(t.substring(2),16):t.charCodeAt(1)}function n(t){return 32>t?(16>t?"\\x0":"\\x")+t.toString(16):(t=String.fromCharCode(t),"\\"===t||"-"===t||"]"===t||"^"===t?"\\"+t:t)}function r(t){var r=t.substring(1,t.length-1).match(/\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\[0-3][0-7]{0,2}|\\[0-7]{1,2}|\\[\S\s]|[^\\]/g),t=[],i="^"===r[0],o=["["];i&&o.push("^");for(var i=i?1:0,s=r.length;s>i;++i){var a=r[i];if(/\\[bdsw]/i.test(a))o.push(a);else{var l,a=e(a);s>i+2&&"-"===r[i+1]?(l=e(r[i+2]),i+=2):l=a,t.push([a,l]),65>l||a>122||(65>l||a>90||t.push([32|Math.max(65,a),32|Math.min(l,90)]),97>l||a>122||t.push([-33&Math.max(97,a),-33&Math.min(l,122)]))}}for(t.sort(function(t,e){return t[0]-e[0]||e[1]-t[1]}),r=[],s=[],i=0;i<t.length;++i)a=t[i],a[0]<=s[1]+1?s[1]=Math.max(s[1],a[1]):r.push(s=a);for(i=0;i<r.length;++i)a=r[i],o.push(n(a[0])),a[1]>a[0]&&(a[1]+1>a[0]&&o.push("-"),o.push(n(a[1])));return o.push("]"),o.join("")}function i(t){for(var e=t.source.match(/\[(?:[^\\\]]|\\[\S\s])*]|\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\\d+|\\[^\dux]|\(\?[!:=]|[()^]|[^()[\\^]+/g),i=e.length,a=[],l=0,u=0;i>l;++l){var c=e[l];"("===c?++u:"\\"===c.charAt(0)&&(c=+c.substring(1))&&(u>=c?a[c]=-1:e[l]=n(c))}for(l=1;l<a.length;++l)-1===a[l]&&(a[l]=++o);for(u=l=0;i>l;++l)c=e[l],"("===c?(++u,a[u]||(e[l]="(?:")):"\\"===c.charAt(0)&&(c=+c.substring(1))&&u>=c&&(e[l]="\\"+a[c]);for(l=0;i>l;++l)"^"===e[l]&&"^"!==e[l+1]&&(e[l]="");if(t.ignoreCase&&s)for(l=0;i>l;++l)c=e[l],t=c.charAt(0),c.length>=2&&"["===t?e[l]=r(c):"\\"!==t&&(e[l]=c.replace(/[A-Za-z]/g,function(t){return t=t.charCodeAt(0),"["+String.fromCharCode(-33&t,32|t)+"]"}));return e.join("")}for(var o=0,s=!1,a=!1,l=0,u=t.length;u>l;++l){var c=t[l];if(c.ignoreCase)a=!0;else if(/[a-z]/i.test(c.source.replace(/\\u[\da-f]{4}|\\x[\da-f]{2}|\\[^UXux]/gi,""))){s=!0,a=!1;break}}for(var h={b:8,t:9,n:10,v:11,f:12,r:13},f=[],l=0,u=t.length;u>l;++l){if(c=t[l],c.global||c.multiline)throw Error(""+c);f.push("(?:"+i(c)+")")}return RegExp(f.join("|"),a?"gi":"g")}function n(t,e){function n(t){var l=t.nodeType;if(1==l){if(!r.test(t.className)){for(l=t.firstChild;l;l=l.nextSibling)n(l);l=t.nodeName.toLowerCase(),("br"===l||"li"===l)&&(i[a]="\n",s[a<<1]=o++,s[1|a++<<1]=t)}}else(3==l||4==l)&&(l=t.nodeValue,l.length&&(l=e?l.replace(/\r\n?/g,"\n"):l.replace(/[\t\n\r ]+/g," "),i[a]=l,s[a<<1]=o,o+=l.length,s[1|a++<<1]=t))}var r=/(?:^|\s)nocode(?:\s|$)/,i=[],o=0,s=[],a=0;return n(t),{a:i.join("").replace(/\n$/,""),d:s}}function r(t,e,n,r){e&&(t={a:e,e:t},n(t),r.push.apply(r,t.g))}function i(t){for(var e=void 0,n=t.firstChild;n;n=n.nextSibling)var r=n.nodeType,e=1===r?e?t:n:3===r?w.test(n.nodeValue)?t:e:e;return e===t?void 0:e}function o(n,i){function o(t){for(var e=t.e,n=[e,"pln"],c=0,h=t.a.match(s)||[],f={},p=0,d=h.length;d>p;++p){var g,m=h[p],v=f[m],y=void 0;if("string"==typeof v)g=!1;else{var x=a[m.charAt(0)];if(x)y=m.match(x[1]),v=x[0];else{for(g=0;l>g;++g)if(x=i[g],y=m.match(x[1])){v=x[0];break}y||(v="pln")}!(g=v.length>=5&&"lang-"===v.substring(0,5))||y&&"string"==typeof y[1]||(g=!1,v="src"),g||(f[m]=v)}if(x=c,c+=m.length,g){g=y[1];var b=m.indexOf(g),w=b+g.length;y[2]&&(w=m.length-y[2].length,b=w-g.length),v=v.substring(5),r(e+x,m.substring(0,b),o,n),r(e+x+b,g,u(v,g),n),r(e+x+w,m.substring(w),o,n)}else n.push(e+x,v)}t.g=n}var s,a={};!function(){for(var r=n.concat(i),o=[],l={},u=0,c=r.length;c>u;++u){var h=r[u],f=h[3];if(f)for(var p=f.length;--p>=0;)a[f.charAt(p)]=h;h=h[1],f=""+h,l.hasOwnProperty(f)||(o.push(h),l[f]=t)}o.push(/[\S\s]/),s=e(o)}();var l=i.length;return o}function s(e){var n=[],r=[];e.tripleQuotedStrings?n.push(["str",/^(?:'''(?:[^'\\]|\\[\S\s]|''?(?=[^']))*(?:'''|$)|"""(?:[^"\\]|\\[\S\s]|""?(?=[^"]))*(?:"""|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$))/,t,"'\""]):e.multiLineStrings?n.push(["str",/^(?:'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$)|`(?:[^\\`]|\\[\S\s])*(?:`|$))/,t,"'\"`"]):n.push(["str",/^(?:'(?:[^\n\r'\\]|\\.)*(?:'|$)|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,t,"\"'"]),e.verbatimStrings&&r.push(["str",/^@"(?:[^"]|"")*(?:"|$)/,t]);var i=e.hashComments;if(i&&(e.cStyleComments?(i>1?n.push(["com",/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,t,"#"]):n.push(["com",/^#(?:(?:define|e(?:l|nd)if|else|error|ifn?def|include|line|pragma|undef|warning)\b|[^\n\r]*)/,t,"#"]),r.push(["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h(?:h|pp|\+\+)?|[a-z]\w*)>/,t])):n.push(["com",/^#[^\n\r]*/,t,"#"])),e.cStyleComments&&(r.push(["com",/^\/\/[^\n\r]*/,t]),r.push(["com",/^\/\*[\S\s]*?(?:\*\/|$)/,t])),i=e.regexLiterals){var s=(i=i>1?"":"\n\r")?".":"[\\S\\s]";r.push(["lang-regex",RegExp("^(?:^^\\.?|[+-]|[!=]=?=?|\\#|%=?|&&?=?|\\(|\\*=?|[+\\-]=|->|\\/=?|::?|<<?=?|>>?>?=?|,|;|\\?|@|\\[|~|{|\\^\\^?=?|\\|\\|?=?|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*("+("/(?=[^/*"+i+"])(?:[^/\\x5B\\x5C"+i+"]|\\x5C"+s+"|\\x5B(?:[^\\x5C\\x5D"+i+"]|\\x5C"+s+")*(?:\\x5D|$))+/")+")")])}return(i=e.types)&&r.push(["typ",i]),i=(""+e.keywords).replace(/^ | $/g,""),i.length&&r.push(["kwd",RegExp("^(?:"+i.replace(/[\s,]+/g,"|")+")\\b"),t]),n.push(["pln",/^\s+/,t," \r\n  "]),i="^.[^\\s\\w.$@'\"`/\\\\]*",e.regexLiterals&&(i+="(?!s*/)"),r.push(["lit",/^@[$_a-z][\w$@]*/i,t],["typ",/^(?:[@_]?[A-Z]+[a-z][\w$@]*|\w+_t\b)/,t],["pln",/^[$_a-z][\w$@]*/i,t],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,t,"0123456789"],["pln",/^\\[\S\s]?/,t],["pun",RegExp(i),t]),o(n,r)}function a(t,e,n){function r(t){var e=t.nodeType;if(1!=e||o.test(t.className)){if((3==e||4==e)&&n){var l=t.nodeValue,u=l.match(s);u&&(e=l.substring(0,u.index),t.nodeValue=e,(l=l.substring(u.index+u[0].length))&&t.parentNode.insertBefore(a.createTextNode(l),t.nextSibling),i(t),e||t.parentNode.removeChild(t))}}else if("br"===t.nodeName)i(t),t.parentNode&&t.parentNode.removeChild(t);else for(t=t.firstChild;t;t=t.nextSibling)r(t)}function i(t){function e(t,n){var r=n?t.cloneNode(!1):t,i=t.parentNode;if(i){var i=e(i,1),o=t.nextSibling;i.appendChild(r);for(var s=o;s;s=o)o=s.nextSibling,i.appendChild(s)}return r}for(;!t.nextSibling;)if(t=t.parentNode,!t)return;for(var n,t=e(t.nextSibling,0);(n=t.parentNode)&&1===n.nodeType;)t=n;u.push(t)}for(var o=/(?:^|\s)nocode(?:\s|$)/,s=/\r\n?|\n/,a=t.ownerDocument,l=a.createElement("li");t.firstChild;)l.appendChild(t.firstChild);for(var u=[l],c=0;c<u.length;++c)r(u[c]);e===(0|e)&&u[0].setAttribute("value",e);var h=a.createElement("ol");h.className="linenums";for(var e=Math.max(0,0|e-1)||0,c=0,f=u.length;f>c;++c)l=u[c],l.className="L"+(c+e)%10,l.firstChild||l.appendChild(a.createTextNode(" ")),h.appendChild(l);t.appendChild(h)}function l(t,e){for(var n=e.length;--n>=0;){var r=e[n];S.hasOwnProperty(r)?h.console&&console.warn("cannot override language handler %s",r):S[r]=t}}function u(t,e){return t&&S.hasOwnProperty(t)||(t=/^\s*</.test(e)?"default-markup":"default-code"),S[t]}function c(t){var e=t.h;try{var r=n(t.c,t.i),i=r.a;t.a=i,t.d=r.d,t.e=0,u(e,i)(t);var o=/\bMSIE\s(\d+)/.exec(navigator.userAgent),o=o&&+o[1]<=8,e=/\n/g,s=t.a,a=s.length,r=0,l=t.d,c=l.length,i=0,f=t.g,p=f.length,d=0;f[p]=a;var g,m;for(m=g=0;p>m;)f[m]!==f[m+2]?(f[g++]=f[m++],f[g++]=f[m++]):m+=2;for(p=g,m=g=0;p>m;){for(var v=f[m],y=f[m+1],x=m+2;p>=x+2&&f[x+1]===y;)x+=2;f[g++]=v,f[g++]=y,m=x}f.length=g;var b,w=t.c;w&&(b=w.style.display,w.style.display="none");try{for(;c>i;){var k,S=l[i+2]||a,M=f[d+2]||a,x=Math.min(S,M),C=l[i+1];if(1!==C.nodeType&&(k=s.substring(r,x))){o&&(k=k.replace(e,"\r")),C.nodeValue=k;var T=C.ownerDocument,A=T.createElement("span");A.className=f[d+1];var _=C.parentNode;_.replaceChild(A,C),A.appendChild(C),S>r&&(l[i+1]=C=T.createTextNode(s.substring(x,S)),_.insertBefore(C,A.nextSibling))}r=x,r>=S&&(i+=2),r>=M&&(d+=2)}}finally{w&&(w.style.display=b)}}catch(L){h.console&&console.log(L&&L.stack||L)}}var h=window,f=["break,continue,do,else,for,if,return,while"],p=[[f,"auto,case,char,const,default,double,enum,extern,float,goto,inline,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],d=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,delegate,dynamic_cast,explicit,export,friend,generic,late_check,mutable,namespace,nullptr,property,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],g=[p,"abstract,assert,boolean,byte,extends,final,finally,implements,import,instanceof,interface,null,native,package,strictfp,super,synchronized,throws,transient"],m=[g,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,internal,into,is,let,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var,virtual,where"],p=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"],v=[f,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],y=[f,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],x=[f,"as,assert,const,copy,drop,enum,extern,fail,false,fn,impl,let,log,loop,match,mod,move,mut,priv,pub,pure,ref,self,static,struct,true,trait,type,unsafe,use"],f=[f,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],b=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)\b/,w=/\S/,k=s({keywords:[d,m,p,"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",v,y,f],hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0}),S={};l(k,["default-code"]),l(o([],[["pln",/^[^<?]+/],["dec",/^<!\w[^>]*(?:>|$)/],["com",/^<\!--[\S\s]*?(?:--\>|$)/],["lang-",/^<\?([\S\s]+?)(?:\?>|$)/],["lang-",/^<%([\S\s]+?)(?:%>|$)/],["pun",/^(?:<[%?]|[%?]>)/],["lang-",/^<xmp\b[^>]*>([\S\s]+?)<\/xmp\b[^>]*>/i],["lang-js",/^<script\b[^>]*>([\S\s]*?)(<\/script\b[^>]*>)/i],["lang-css",/^<style\b[^>]*>([\S\s]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]),l(o([["pln",/^\s+/,t," \r\n"],["atv",/^(?:"[^"]*"?|'[^']*'?)/,t,"\"'"]],[["tag",/^^<\/?[a-z](?:[\w-.:]*\w)?|\/?>$/i],["atn",/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^\s"'>]*(?:[^\s"'/>]|\/(?=\s)))/],["pun",/^[/<->]+/],["lang-js",/^on\w+\s*=\s*"([^"]+)"/i],["lang-js",/^on\w+\s*=\s*'([^']+)'/i],["lang-js",/^on\w+\s*=\s*([^\s"'>]+)/i],["lang-css",/^style\s*=\s*"([^"]+)"/i],["lang-css",/^style\s*=\s*'([^']+)'/i],["lang-css",/^style\s*=\s*([^\s"'>]+)/i]]),["in.tag"]),l(o([],[["atv",/^[\S\s]+/]]),["uq.val"]),l(s({keywords:d,hashComments:!0,cStyleComments:!0,types:b}),["c","cc","cpp","cxx","cyc","m"]),l(s({keywords:"null,true,false"}),["json"]),l(s({keywords:m,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:b}),["cs"]),l(s({keywords:g,cStyleComments:!0}),["java"]),l(s({keywords:f,hashComments:!0,multiLineStrings:!0}),["bash","bsh","csh","sh"]),l(s({keywords:v,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),["cv","py","python"]),l(s({keywords:"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",hashComments:!0,multiLineStrings:!0,regexLiterals:2}),["perl","pl","pm"]),l(s({keywords:y,hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb","ruby"]),l(s({keywords:p,cStyleComments:!0,regexLiterals:!0}),["javascript","js"]),l(s({keywords:"all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,throw,true,try,unless,until,when,while,yes",hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]),l(s({keywords:x,cStyleComments:!0,multilineStrings:!0}),["rc","rs","rust"]),l(o([],[["str",/^[\S\s]+/]]),["regex"]);var M=h.PR={createSimpleLexer:o,registerLangHandler:l,sourceDecorator:s,PR_ATTRIB_NAME:"atn",PR_ATTRIB_VALUE:"atv",PR_COMMENT:"com",PR_DECLARATION:"dec",PR_KEYWORD:"kwd",PR_LITERAL:"lit",PR_NOCODE:"nocode",PR_PLAIN:"pln",PR_PUNCTUATION:"pun",PR_SOURCE:"src",PR_STRING:"str",PR_TAG:"tag",PR_TYPE:"typ",prettyPrintOne:h.prettyPrintOne=function(t,e,n){var r=document.createElement("div");return r.innerHTML="<pre>"+t+"</pre>",r=r.firstChild,n&&a(r,n,!0),c({h:e,j:n,c:r,i:1}),r.innerHTML},prettyPrint:h.prettyPrint=function(e,n){function r(){for(var n=h.PR_SHOULD_USE_CONTINUATION?d.now()+250:1/0;m<l.length&&d.now()<n;m++){for(var o=l[m],u=S,f=o;f=f.previousSibling;){var p=f.nodeType,M=(7===p||8===p)&&f.nodeValue;if(M?!/^\??prettify\b/.test(M):3!==p||/\S/.test(f.nodeValue))break;if(M){u={},M.replace(/\b(\w+)=([\w%+\-.:]+)/g,function(t,e,n){u[e]=n});break}}if(f=o.className,(u!==S||y.test(f))&&!x.test(f)){for(p=!1,M=o.parentNode;M;M=M.parentNode)if(k.test(M.tagName)&&M.className&&y.test(M.className)){p=!0;break}if(!p){if(o.className+=" prettyprinted",p=u.lang,!p){var C,p=f.match(v);!p&&(C=i(o))&&w.test(C.tagName)&&(p=C.className.match(v)),p&&(p=p[1])}if(b.test(o.tagName))M=1;else var M=o.currentStyle,T=s.defaultView,M=(M=M?M.whiteSpace:T&&T.getComputedStyle?T.getComputedStyle(o,t).getPropertyValue("white-space"):0)&&"pre"===M.substring(0,3);T=u.linenums,(T="true"===T||+T)||(T=(T=f.match(/\blinenums\b(?::(\d+))?/))?T[1]&&T[1].length?+T[1]:!0:!1),T&&a(o,T,M),g={h:p,c:o,j:T,i:M},c(g)}}}m<l.length?setTimeout(r,250):"function"==typeof e&&e()}for(var o=n||document.body,s=o.ownerDocument||document,o=[o.getElementsByTagName("pre"),o.getElementsByTagName("code"),o.getElementsByTagName("xmp")],l=[],u=0;u<o.length;++u)for(var f=0,p=o[u].length;p>f;++f)l.push(o[u][f]);var o=t,d=Date;d.now||(d={now:function(){return+new Date}});var g,m=0,v=/\blang(?:uage)?-([\w.]+)(?!\S)/,y=/\bprettyprint\b/,x=/\bprettyprinted\b/,b=/pre|xmp/i,w=/^code$/i,k=/^(?:pre|code|xmp)$/i,S={};r()}};"function"==typeof define&&define.amd&&define("google-code-prettify",[],function(){return M})}()}();