diff --git a/README.md b/README.md index 8e8c4fa..c9b22a1 100644 --- a/README.md +++ b/README.md @@ -1,25 +1,15 @@ -# HighlightJs Copy Code Badge Component +# HighlightJs Copy Code Badge-JS (extension) Component This small JavaScript library complements the [highlightJs Syntax Highligher](https://highlightjs.org/) by providing a badge in the top right corner of highlightJs code snippets. * Shows active Syntax for the code block * Allows copying the code block to Clipboard -You can install it [from NPM](https://www.npmjs.com/package/highlightjs-badge): +You can install it [from NPM](https://www.npmjs.com/package/highlightjs-badgejs): ```ps -npm install highlightjs-badge +npm install highlightjs-badgejs ``` - -* [Codepen Example](https://codepen.io/rstrahl/pen/RwNZGBE) -* [HighlightJs-Badge Blog Post](https://weblog.west-wind.com/posts/2019/Dec/30/A-HighlightJs-Copy-Code-Badge-Component) - -Here's what the code badge looks like attached to several highlightjs code blocks: - - - -This small, single JavaScript file component can be loaded after highlightJS has been loaded. It's fully self-contained. Add the script, call the `window.highlightJsBadge()`, and you're up and running without any other configuration or dependencies. - ### Usage To use this library is very simple - you add a script file and call `highlightJsBadge()` after highlightJS has been applied. @@ -31,7 +21,7 @@ The following is a typical configuration for both highlightJs and highlightJs-Ba - + ``` +#### Options + +Some other options added from the original: + +* title : allow to set a different title on hover +* label : allow to set a prefix on badge name +* clickableBadge : if set "true" allow to have pointer and click event on badge in addition to icon click +* hasLineNumber : if set "true" indicates that content as line number plugin activated +* xmlBeautifier : if set "true" indicates that content (if xml) has been copied as beautif, otherwirse as original content + + ### Styling The default script includes default styling that should work great with dark themed syntax, and fairly well with light themed syntax. @@ -130,8 +131,8 @@ Alternately you can completely replace the template and styling. If you look at
` tag **via code**. Unfortunately this style feature is not directly settable via CSS so the relative style gets hardcoded when the badge is added to the page. +* **Added new options** + * title : allow to set a different title on hover + * label : allow to set a prefix on badge name + * clickableBadge (true/false default : false) : if set "true" allow to have pointer and click event on badge in addition to icon click + * hasLineNumber (true/false default : false) : if set "true" indicates that content as line number plugin activated +* **Fixed bugs** + * Options not correctly initialized diff --git a/highlight.pack.js b/highlight.pack.js new file mode 100644 index 0000000..e479316 --- /dev/null +++ b/highlight.pack.js @@ -0,0 +1,2 @@ +/*! highlight.js v9.15.8 | BSD3 License | git.io/hljslicense */ +!function(e){var t="object"==typeof window&&window||"object"==typeof self&&self;"undefined"!=typeof exports?e(exports):t&&(t.hljs=e({}),"function"==typeof define&&define.amd&&define([],function(){return t.hljs}))}(function(o){var u=[],c=Object.keys,S={},E={},t=/^(no-?highlight|plain|text)$/i,_=/\blang(?:uage)?-([\w-]+)\b/i,r=/((^(<[^>]+>|\t|)+|(?:\n)))/gm,a={case_insensitive:"cI",lexemes:"l",contains:"c",keywords:"k",subLanguage:"sL",className:"cN",begin:"b",beginKeywords:"bK",end:"e",endsWithParent:"eW",illegal:"i",excludeBegin:"eB",excludeEnd:"eE",returnBegin:"rB",returnEnd:"rE",relevance:"r",variants:"v",IDENT_RE:"IR",UNDERSCORE_IDENT_RE:"UIR",NUMBER_RE:"NR",C_NUMBER_RE:"CNR",BINARY_NUMBER_RE:"BNR",RE_STARTERS_RE:"RSR",BACKSLASH_ESCAPE:"BE",APOS_STRING_MODE:"ASM",QUOTE_STRING_MODE:"QSM",PHRASAL_WORDS_MODE:"PWM",C_LINE_COMMENT_MODE:"CLCM",C_BLOCK_COMMENT_MODE:"CBCM",HASH_COMMENT_MODE:"HCM",NUMBER_MODE:"NM",C_NUMBER_MODE:"CNM",BINARY_NUMBER_MODE:"BNM",CSS_NUMBER_MODE:"CSSNM",REGEXP_MODE:"RM",TITLE_MODE:"TM",UNDERSCORE_TITLE_MODE:"UTM",COMMENT:"C",beginRe:"bR",endRe:"eR",illegalRe:"iR",lexemesRe:"lR",terminators:"t",terminator_end:"tE"},A="",b={classPrefix:"hljs-",tabReplace:null,useBR:!1,languages:void 0};function T(e){return e.replace(/&/g,"&").replace(//g,">")}function p(e){return e.nodeName.toLowerCase()}function I(e,t){var r=e&&e.exec(t);return r&&0===r.index}function R(e){return t.test(e)}function N(e){var t,r={},a=Array.prototype.slice.call(arguments,1);for(t in e)r[t]=e[t];return a.forEach(function(e){for(t in e)r[t]=e[t]}),r}function m(e){var o=[];return function e(t,r){for(var a=t.firstChild;a;a=a.nextSibling)3===a.nodeType?r+=a.nodeValue.length:1===a.nodeType&&(o.push({event:"start",offset:r,node:a}),r=e(a,r),p(a).match(/br|hr|img|input/)||o.push({event:"stop",offset:r,node:a}));return r}(e,0),o}function i(e){if(a&&!e.langApiRestored){for(var t in e.langApiRestored=!0,a)e[t]&&(e[a[t]]=e[t]);(e.c||[]).concat(e.v||[]).forEach(i)}}function C(n){function l(e){return e&&e.source||e}function s(e,t){return new RegExp(l(e),"m"+(n.cI?"i":"")+(t?"g":""))}!function t(r,e){if(!r.compiled){if(r.compiled=!0,r.k=r.k||r.bK,r.k){var a={},o=function(r,e){n.cI&&(e=e.toLowerCase()),e.split(" ").forEach(function(e){var t=e.split("|");a[t[0]]=[r,t[1]?Number(t[1]):1]})};"string"==typeof r.k?o("keyword",r.k):c(r.k).forEach(function(e){o(e,r.k[e])}),r.k=a}r.lR=s(r.l||/\w+/,!0),e&&(r.bK&&(r.b="\\b("+r.bK.split(" ").join("|")+")\\b"),r.b||(r.b=/\B|\b/),r.bR=s(r.b),r.endSameAsBegin&&(r.e=r.b),r.e||r.eW||(r.e=/\B|\b/),r.e&&(r.eR=s(r.e)),r.tE=l(r.e)||"",r.eW&&e.tE&&(r.tE+=(r.e?"|":"")+e.tE)),r.i&&(r.iR=s(r.i)),null==r.r&&(r.r=1),r.c||(r.c=[]),r.c=Array.prototype.concat.apply([],r.c.map(function(e){return(t="self"===e?r:e).v&&!t.cached_variants&&(t.cached_variants=t.v.map(function(e){return N(t,{v:null},e)})),t.cached_variants||t.eW&&[N(t)]||[t];var t})),r.c.forEach(function(e){t(e,r)}),r.starts&&t(r.starts,e);var i=r.c.map(function(e){return e.bK?"\\.?(?:"+e.b+")\\.?":e.b}).concat([r.tE,r.i]).map(l).filter(Boolean);r.t=i.length?s(function(e,t){for(var r=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./,a=0,o="",i=0;i')+t+(r?"":A):t}function l(){E+=null!=u.sL?function(){var e="string"==typeof u.sL;if(e&&!S[u.sL])return T(_);var t=e?g(u.sL,_,!0,i[u.sL]):f(_,u.sL.length?u.sL:void 0);return 0 ")+'"');return _+=t,t.length||1}var d=v(e);if(!d)throw new Error('Unknown language: "'+e+'"');C(d);var o,u=r||d,i={},E="";for(o=u;o!==d;o=o.parent)o.cN&&(E=c(o.cN,"",!0)+E);var _="",p=0;try{for(var n,R,m=0;u.t.lastIndex=m,n=u.t.exec(t);)R=a(t.substring(m,n.index),n[0]),m=n.index+R;for(a(t.substr(m)),o=u;o.parent;o=o.parent)o.cN&&(E+=A);return{r:p,value:E,language:e,top:u}}catch(e){if(e.message&&-1!==e.message.indexOf("Illegal"))return{r:0,value:T(t)};throw e}}function f(r,e){e=e||b.languages||c(S);var a={r:0,value:T(r)},o=a;return e.filter(v).filter(l).forEach(function(e){var t=g(e,r,!1);t.language=e,t.r>o.r&&(o=t),t.r>a.r&&(o=a,a=t)}),o.language&&(a.second_best=o),a}function O(e){return b.tabReplace||b.useBR?e.replace(r,function(e,t){return b.useBR&&"\n"===e?"
":b.tabReplace?t.replace(/\t/g,b.tabReplace):""}):e}function n(e){var t,r,a,o,i,n,s,c,l,N,d=function(e){var t,r,a,o,i=e.className+" ";if(i+=e.parentNode?e.parentNode.className:"",r=_.exec(i))return v(r[1])?r[1]:"no-highlight";for(t=0,a=(i=i.split(/\s+/)).length;t/g,"\n"):t=e,i=t.textContent,a=d?g(d,i,!0):f(i),(r=m(t)).length&&((o=document.createElementNS("http://www.w3.org/1999/xhtml","div")).innerHTML=a.value,a.value=function(e,t,r){var a=0,o="",i=[];function n(){return e.length&&t.length?e[0].offset!==t[0].offset?e[0].offset"}function c(e){o+=""+p(e)+">"}function l(e){("start"===e.event?s:c)(e.node)}for(;e.length||t.length;){var N=n();if(o+=T(r.substring(a,N[0].offset)),a=N[0].offset,N===e){for(i.reverse().forEach(c);l(N.splice(0,1)[0]),(N=n())===e&&N.length&&N[0].offset===a;);i.reverse().forEach(s)}else"start"===N[0].event?i.push(N[0].node):i.pop(),l(N.splice(0,1)[0])}return o+T(r.substr(a))}(r,m(o),i)),a.value=O(a.value),e.innerHTML=a.value,e.className=(n=e.className,s=d,c=a.language,l=s?E[s]:c,N=[n.trim()],n.match(/\bhljs\b/)||N.push("hljs"),-1===n.indexOf(l)&&N.push(l),N.join(" ").trim()),e.result={language:a.language,re:a.r},a.second_best&&(e.second_best={language:a.second_best.language,re:a.second_best.r}))}function s(){if(!s.called){s.called=!0;var e=document.querySelectorAll("pre code");u.forEach.call(e,n)}}function v(e){return e=(e||"").toLowerCase(),S[e]||S[E[e]]}function l(e){var t=v(e);return t&&!t.disableAutodetect}return o.highlight=g,o.highlightAuto=f,o.fixMarkup=O,o.highlightBlock=n,o.configure=function(e){b=N(b,e)},o.initHighlighting=s,o.initHighlightingOnLoad=function(){addEventListener("DOMContentLoaded",s,!1),addEventListener("load",s,!1)},o.registerLanguage=function(t,e){var r=S[t]=e(o);i(r),r.aliases&&r.aliases.forEach(function(e){E[e]=t})},o.listLanguages=function(){return c(S)},o.getLanguage=v,o.autoDetection=l,o.inherit=N,o.IR=o.IDENT_RE="[a-zA-Z]\\w*",o.UIR=o.UNDERSCORE_IDENT_RE="[a-zA-Z_]\\w*",o.NR=o.NUMBER_RE="\\b\\d+(\\.\\d+)?",o.CNR=o.C_NUMBER_RE="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",o.BNR=o.BINARY_NUMBER_RE="\\b(0b[01]+)",o.RSR=o.RE_STARTERS_RE="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",o.BE=o.BACKSLASH_ESCAPE={b:"\\\\[\\s\\S]",r:0},o.ASM=o.APOS_STRING_MODE={cN:"string",b:"'",e:"'",i:"\\n",c:[o.BE]},o.QSM=o.QUOTE_STRING_MODE={cN:"string",b:'"',e:'"',i:"\\n",c:[o.BE]},o.PWM=o.PHRASAL_WORDS_MODE={b:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},o.C=o.COMMENT=function(e,t,r){var a=o.inherit({cN:"comment",b:e,e:t,c:[]},r||{});return a.c.push(o.PWM),a.c.push({cN:"doctag",b:"(?:TODO|FIXME|NOTE|BUG|XXX):",r:0}),a},o.CLCM=o.C_LINE_COMMENT_MODE=o.C("//","$"),o.CBCM=o.C_BLOCK_COMMENT_MODE=o.C("/\\*","\\*/"),o.HCM=o.HASH_COMMENT_MODE=o.C("#","$"),o.NM=o.NUMBER_MODE={cN:"number",b:o.NR,r:0},o.CNM=o.C_NUMBER_MODE={cN:"number",b:o.CNR,r:0},o.BNM=o.BINARY_NUMBER_MODE={cN:"number",b:o.BNR,r:0},o.CSSNM=o.CSS_NUMBER_MODE={cN:"number",b:o.NR+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",r:0},o.RM=o.REGEXP_MODE={cN:"regexp",b:/\//,e:/\/[gimuy]*/,i:/\n/,c:[o.BE,{b:/\[/,e:/\]/,r:0,c:[o.BE]}]},o.TM=o.TITLE_MODE={cN:"title",b:o.IR,r:0},o.UTM=o.UNDERSCORE_TITLE_MODE={cN:"title",b:o.UIR,r:0},o.METHOD_GUARD={b:"\\.\\s*"+o.UIR,r:0},o.registerLanguage("apache",function(e){var t={cN:"number",b:"[\\$%]\\d+"};return{aliases:["apacheconf"],cI:!0,c:[e.HCM,{cN:"section",b:"?",e:">"},{cN:"attribute",b:/\w+/,r:0,k:{nomarkup:"order deny allow setenv rewriterule rewriteengine rewritecond documentroot sethandler errordocument loadmodule options header listen serverroot servername"},starts:{e:/$/,r:0,k:{literal:"on off all"},c:[{cN:"meta",b:"\\s\\[",e:"\\]$"},{cN:"variable",b:"[\\$%]\\{",e:"\\}",c:["self",t]},t,e.QSM]}}],i:/\S/}}),o.registerLanguage("bash",function(e){var t={cN:"variable",v:[{b:/\$[\w\d#@][\w\d_]*/},{b:/\$\{(.*?)}/}]},r={cN:"string",b:/"/,e:/"/,c:[e.BE,t,{cN:"variable",b:/\$\(/,e:/\)/,c:[e.BE]}]};return{aliases:["sh","zsh"],l:/\b-?[a-z\._]+\b/,k:{keyword:"if then else elif fi for while in do done case esac function",literal:"true false",built_in:"break cd continue eval exec exit export getopts hash pwd readonly return shift test times trap umask unset alias bind builtin caller command declare echo enable help let local logout mapfile printf read readarray source type typeset ulimit unalias set shopt autoload bg bindkey bye cap chdir clone comparguments compcall compctl compdescribe compfiles compgroups compquote comptags comptry compvalues dirs disable disown echotc echoti emulate fc fg float functions getcap getln history integer jobs kill limit log noglob popd print pushd pushln rehash sched setcap setopt stat suspend ttyctl unfunction unhash unlimit unsetopt vared wait whence where which zcompile zformat zftp zle zmodload zparseopts zprof zpty zregexparse zsocket zstyle ztcp",_:"-ne -eq -lt -gt -f -d -e -s -l -a"},c:[{cN:"meta",b:/^#![^\n]+sh\s*$/,r:10},{cN:"function",b:/\w[\w\d_]*\s*\(\s*\)\s*\{/,rB:!0,c:[e.inherit(e.TM,{b:/\w[\w\d_]*/})],r:0},e.HCM,r,{cN:"",b:/\\"/},{cN:"string",b:/'/,e:/'/},t]}}),o.registerLanguage("cpp",function(e){var t={cN:"keyword",b:"\\b[a-z\\d_]*_t\\b"},r={cN:"string",v:[{b:'(u8?|U|L)?"',e:'"',i:"\\n",c:[e.BE]},{b:/(?:u8?|U|L)?R"([^()\\ ]{0,16})\((?:.|\n)*?\)\1"/},{b:"'\\\\?.",e:"'",i:"."}]},a={cN:"number",v:[{b:"\\b(0b[01']+)"},{b:"(-?)\\b([\\d']+(\\.[\\d']*)?|\\.[\\d']+)(u|U|l|L|ul|UL|f|F|b|B)"},{b:"(-?)(\\b0[xX][a-fA-F0-9']+|(\\b[\\d']+(\\.[\\d']*)?|\\.[\\d']+)([eE][-+]?[\\d']+)?)"}],r:0},o={cN:"meta",b:/#\s*[a-z]+\b/,e:/$/,k:{"meta-keyword":"if else elif endif define undef warning error line pragma ifdef ifndef include"},c:[{b:/\\\n/,r:0},e.inherit(r,{cN:"meta-string"}),{cN:"meta-string",b:/<[^\n>]*>/,e:/$/,i:"\\n"},e.CLCM,e.CBCM]},i=e.IR+"\\s*\\(",n={keyword:"int float while private char catch import module export virtual operator sizeof dynamic_cast|10 typedef const_cast|10 const for static_cast|10 union namespace unsigned long volatile static protected bool template mutable if public friend do goto auto void enum else break extern using asm case typeid short reinterpret_cast|10 default double register explicit signed typename try this switch continue inline delete alignof constexpr decltype noexcept static_assert thread_local restrict _Bool complex _Complex _Imaginary atomic_bool atomic_char atomic_schar atomic_uchar atomic_short atomic_ushort atomic_int atomic_uint atomic_long atomic_ulong atomic_llong atomic_ullong new throw return and or not",built_in:"std string cin cout cerr clog stdin stdout stderr stringstream istringstream ostringstream auto_ptr deque list queue stack vector map set bitset multiset multimap unordered_set unordered_map unordered_multiset unordered_multimap array shared_ptr abort abs acos asin atan2 atan calloc ceil cosh cos exit exp fabs floor fmod fprintf fputs free frexp fscanf isalnum isalpha iscntrl isdigit isgraph islower isprint ispunct isspace isupper isxdigit tolower toupper labs ldexp log10 log malloc realloc memchr memcmp memcpy memset modf pow printf putchar puts scanf sinh sin snprintf sprintf sqrt sscanf strcat strchr strcmp strcpy strcspn strlen strncat strncmp strncpy strpbrk strrchr strspn strstr tanh tan vfprintf vprintf vsprintf endl initializer_list unique_ptr",literal:"true false nullptr NULL"},s=[t,e.CLCM,e.CBCM,a,r];return{aliases:["c","cc","h","c++","h++","hpp","hh","hxx","cxx"],k:n,i:"",c:s.concat([o,{b:"\\b(deque|list|queue|stack|vector|map|set|bitset|multiset|multimap|unordered_map|unordered_set|unordered_multiset|unordered_multimap|array)\\s*<",e:">",k:n,c:["self",t]},{b:e.IR+"::",k:n},{v:[{b:/=/,e:/;/},{b:/\(/,e:/\)/},{bK:"new throw return else",e:/;/}],k:n,c:s.concat([{b:/\(/,e:/\)/,k:n,c:s.concat(["self"]),r:0}]),r:0},{cN:"function",b:"("+e.IR+"[\\*&\\s]+)+"+i,rB:!0,e:/[{;=]/,eE:!0,k:n,i:/[^\w\s\*&]/,c:[{b:i,rB:!0,c:[e.TM],r:0},{cN:"params",b:/\(/,e:/\)/,k:n,r:0,c:[e.CLCM,e.CBCM,r,a,t,{b:/\(/,e:/\)/,k:n,r:0,c:["self",e.CLCM,e.CBCM,r,a,t]}]},e.CLCM,e.CBCM,o]},{cN:"class",bK:"class struct",e:/[{;:]/,c:[{b:/,e:/>/,c:["self"]},e.TM]}]),exports:{preprocessor:o,strings:r,k:n}}}),o.registerLanguage("cs",function(e){var t={keyword:"abstract as base bool break byte case catch char checked const continue decimal default delegate do double enum event explicit extern finally fixed float for foreach goto if implicit in int interface internal is lock long nameof object operator out override params private protected public readonly ref sbyte sealed short sizeof stackalloc static string struct switch this try typeof uint ulong unchecked unsafe ushort using virtual void volatile while add alias ascending async await by descending dynamic equals from get global group into join let on orderby partial remove select set value var where yield",literal:"null false true"},r={cN:"number",v:[{b:"\\b(0b[01']+)"},{b:"(-?)\\b([\\d']+(\\.[\\d']*)?|\\.[\\d']+)(u|U|l|L|ul|UL|f|F|b|B)"},{b:"(-?)(\\b0[xX][a-fA-F0-9']+|(\\b[\\d']+(\\.[\\d']*)?|\\.[\\d']+)([eE][-+]?[\\d']+)?)"}],r:0},a={cN:"string",b:'@"',e:'"',c:[{b:'""'}]},o=e.inherit(a,{i:/\n/}),i={cN:"subst",b:"{",e:"}",k:t},n=e.inherit(i,{i:/\n/}),s={cN:"string",b:/\$"/,e:'"',i:/\n/,c:[{b:"{{"},{b:"}}"},e.BE,n]},c={cN:"string",b:/\$@"/,e:'"',c:[{b:"{{"},{b:"}}"},{b:'""'},i]},l=e.inherit(c,{i:/\n/,c:[{b:"{{"},{b:"}}"},{b:'""'},n]});i.c=[c,s,a,e.ASM,e.QSM,r,e.CBCM],n.c=[l,s,o,e.ASM,e.QSM,r,e.inherit(e.CBCM,{i:/\n/})];var N={v:[c,s,a,e.ASM,e.QSM]},d=e.IR+"(<"+e.IR+"(\\s*,\\s*"+e.IR+")*>)?(\\[\\])?";return{aliases:["csharp","c#"],k:t,i:/::/,c:[e.C("///","$",{rB:!0,c:[{cN:"doctag",v:[{b:"///",r:0},{b:"\x3c!--|--\x3e"},{b:"?",e:">"}]}]}),e.CLCM,e.CBCM,{cN:"meta",b:"#",e:"$",k:{"meta-keyword":"if else elif endif define undef warning error line region endregion pragma checksum"}},N,r,{bK:"class interface",e:/[{;=]/,i:/[^\s:,]/,c:[e.TM,e.CLCM,e.CBCM]},{bK:"namespace",e:/[{;=]/,i:/[^\s:]/,c:[e.inherit(e.TM,{b:"[a-zA-Z](\\.?\\w)*"}),e.CLCM,e.CBCM]},{cN:"meta",b:"^\\s*\\[",eB:!0,e:"\\]",eE:!0,c:[{cN:"meta-string",b:/"/,e:/"/}]},{bK:"new return throw await else",r:0},{cN:"function",b:"("+d+"\\s+)+"+e.IR+"\\s*\\(",rB:!0,e:/\s*[{;=]/,eE:!0,k:t,c:[{b:e.IR+"\\s*\\(",rB:!0,c:[e.TM],r:0},{cN:"params",b:/\(/,e:/\)/,eB:!0,eE:!0,k:t,r:0,c:[N,r,e.CBCM]},e.CLCM,e.CBCM]}]}}),o.registerLanguage("css",function(e){var t={b:/[A-Z\_\.\-]+\s*:/,rB:!0,e:";",eW:!0,c:[{cN:"attribute",b:/\S/,e:":",eE:!0,starts:{eW:!0,eE:!0,c:[{b:/[\w-]+\(/,rB:!0,c:[{cN:"built_in",b:/[\w-]+/},{b:/\(/,e:/\)/,c:[e.ASM,e.QSM]}]},e.CSSNM,e.QSM,e.ASM,e.CBCM,{cN:"number",b:"#[0-9A-Fa-f]+"},{cN:"meta",b:"!important"}]}}]};return{cI:!0,i:/[=\/|'\$]/,c:[e.CBCM,{cN:"selector-id",b:/#[A-Za-z0-9_-]+/},{cN:"selector-class",b:/\.[A-Za-z0-9_-]+/},{cN:"selector-attr",b:/\[/,e:/\]/,i:"$"},{cN:"selector-pseudo",b:/:(:)?[a-zA-Z0-9\_\-\+\(\)"'.]+/},{b:"@(font-face|page)",l:"[a-z-]+",k:"font-face page"},{b:"@",e:"[{;]",i:/:/,c:[{cN:"keyword",b:/\w+/},{b:/\s/,eW:!0,eE:!0,r:0,c:[e.ASM,e.QSM,e.CSSNM]}]},{cN:"selector-tag",b:"[a-zA-Z-][a-zA-Z0-9_-]*",r:0},{b:"{",e:"}",i:/\S/,c:[e.CBCM,t]}]}}),o.registerLanguage("markdown",function(e){return{aliases:["md","mkdown","mkd"],c:[{cN:"section",v:[{b:"^#{1,6}",e:"$"},{b:"^.+?\\n[=-]{2,}$"}]},{b:"<",e:">",sL:"xml",r:0},{cN:"bullet",b:"^\\s*([*+-]|(\\d+\\.))\\s+"},{cN:"strong",b:"[*_]{2}.+?[*_]{2}"},{cN:"emphasis",v:[{b:"\\*.+?\\*"},{b:"_.+?_",r:0}]},{cN:"quote",b:"^>\\s+",e:"$"},{cN:"code",v:[{b:"^```w*s*$",e:"^```s*$"},{b:"`.+?`"},{b:"^( {4}|\t)",e:"$",r:0}]},{b:"^[-\\*]{3,}",e:"$"},{b:"\\[.+?\\][\\(\\[].*?[\\)\\]]",rB:!0,c:[{cN:"string",b:"\\[",e:"\\]",eB:!0,rE:!0,r:0},{cN:"link",b:"\\]\\(",e:"\\)",eB:!0,eE:!0},{cN:"symbol",b:"\\]\\[",e:"\\]",eB:!0,eE:!0}],r:10},{b:/^\[[^\n]+\]:/,rB:!0,c:[{cN:"symbol",b:/\[/,e:/\]/,eB:!0,eE:!0},{cN:"link",b:/:\s*/,e:/$/,eB:!0}]}]}}),o.registerLanguage("dart",function(e){var t={cN:"subst",v:[{b:"\\$[A-Za-z0-9_]+"}]},r={cN:"subst",v:[{b:"\\${",e:"}"}],k:"true false null this is new super"},a={cN:"string",v:[{b:"r'''",e:"'''"},{b:'r"""',e:'"""'},{b:"r'",e:"'",i:"\\n"},{b:'r"',e:'"',i:"\\n"},{b:"'''",e:"'''",c:[e.BE,t,r]},{b:'"""',e:'"""',c:[e.BE,t,r]},{b:"'",e:"'",i:"\\n",c:[e.BE,t,r]},{b:'"',e:'"',i:"\\n",c:[e.BE,t,r]}]};r.c=[e.CNM,a];return{k:{keyword:"assert async await break case catch class const continue default do else enum extends false final finally for if in is new null rethrow return super switch sync this throw true try var void while with yield abstract as dynamic export external factory get implements import library operator part set static typedef",built_in:"print Comparable DateTime Duration Function Iterable Iterator List Map Match Null Object Pattern RegExp Set Stopwatch String StringBuffer StringSink Symbol Type Uri bool double int num document window querySelector querySelectorAll Element ElementList"},c:[a,e.C("/\\*\\*","\\*/",{sL:"markdown"}),e.C("///","$",{sL:"markdown"}),e.CLCM,e.CBCM,{cN:"class",bK:"class interface",e:"{",eE:!0,c:[{bK:"extends implements"},e.UTM]},e.CNM,{cN:"meta",b:"@[A-Za-z]+"},{b:"=>"}]}}),o.registerLanguage("diff",function(e){return{aliases:["patch"],c:[{cN:"meta",r:10,v:[{b:/^@@ +\-\d+,\d+ +\+\d+,\d+ +@@$/},{b:/^\*\*\* +\d+,\d+ +\*\*\*\*$/},{b:/^\-\-\- +\d+,\d+ +\-\-\-\-$/}]},{cN:"comment",v:[{b:/Index: /,e:/$/},{b:/={3,}/,e:/$/},{b:/^\-{3}/,e:/$/},{b:/^\*{3} /,e:/$/},{b:/^\+{3}/,e:/$/},{b:/\*{5}/,e:/\*{5}$/}]},{cN:"addition",b:"^\\+",e:"$"},{cN:"deletion",b:"^\\-",e:"$"},{cN:"addition",b:"^\\!",e:"$"}]}}),o.registerLanguage("dns",function(e){return{aliases:["bind","zone"],k:{keyword:"IN A AAAA AFSDB APL CAA CDNSKEY CDS CERT CNAME DHCID DLV DNAME DNSKEY DS HIP IPSECKEY KEY KX LOC MX NAPTR NS NSEC NSEC3 NSEC3PARAM PTR RRSIG RP SIG SOA SRV SSHFP TA TKEY TLSA TSIG TXT"},c:[e.C(";","$",{r:0}),{cN:"meta",b:/^\$(TTL|GENERATE|INCLUDE|ORIGIN)\b/},{cN:"number",b:"((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))\\b"},{cN:"number",b:"((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]).){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\\b"},e.inherit(e.NM,{b:/\b\d+[dhwm]?/})]}}),o.registerLanguage("dockerfile",function(e){return{aliases:["docker"],cI:!0,k:"from maintainer expose env arg user onbuild stopsignal",c:[e.HCM,e.ASM,e.QSM,e.NM,{bK:"run cmd entrypoint volume add copy workdir label healthcheck shell",starts:{e:/[^\\]$/,sL:"bash"}}],i:""}}),o.registerLanguage("dos",function(e){var t=e.C(/^\s*@?rem\b/,/$/,{r:10});return{aliases:["bat","cmd"],cI:!0,i:/\/\*/,k:{keyword:"if else goto for in do call exit not exist errorlevel defined equ neq lss leq gtr geq",built_in:"prn nul lpt3 lpt2 lpt1 con com4 com3 com2 com1 aux shift cd dir echo setlocal endlocal set pause copy append assoc at attrib break cacls cd chcp chdir chkdsk chkntfs cls cmd color comp compact convert date dir diskcomp diskcopy doskey erase fs find findstr format ftype graftabl help keyb label md mkdir mode more move path pause print popd pushd promt rd recover rem rename replace restore rmdir shiftsort start subst time title tree type ver verify vol ping net ipconfig taskkill xcopy ren del"},c:[{cN:"variable",b:/%%[^ ]|%[^ ]+?%|![^ ]+?!/},{cN:"function",b:"^\\s*[A-Za-z._?][A-Za-z0-9_$#@~.?]*(:|\\s+label)",e:"goto:eof",c:[e.inherit(e.TM,{b:"([_a-zA-Z]\\w*\\.)*([_a-zA-Z]\\w*:)?[_a-zA-Z]\\w*"}),t]},{cN:"number",b:"\\b\\d+",r:0},t]}}),o.registerLanguage("foxpro",function(e){return{aliases:["foxpro","vfp","fox"],cI:!0,k:{keyword:"additive by case catch cursor custom declare define do else endcase enddefine enddo endfor endfunc endif endprintjob endproc endscan endtext endtry endwith error exit finally for from function func hidden if local lparameter lparameters next noshow otherwise parameters printjob procedure proc protected public|scan text then throw to try while with activate add alter alternate ansi app append array assert asserts assist autoincerror autosave average bar begin bell blank blocksize border box browse browseime brstatus build calculate call cancel carry catch cd century change chdir class classlib clear clock close collate color compatible compile confirm connection connections console continue copy count coverage cpcompile cpdialog create currency cursor cursor database datasession date deactivate debug debugout decimals declare default define delete deleted delimiters development device dimension dir directory display dll dlls dock doevents dohistory drop echo edit eject end enginebehavior erase error escape eventlist events eventtracking exact exclusive exe export extended external fdow fields file files filter finally find fixed flush form format free from fullpath function fweek gather general get getexpr gets go goto headings help hide hours id import in index indexes input insert intensity into join key keyboard keycomp label library list load local locate lock logerrors loop lparameters mackey macro macros margin mark md memo memory memowidth menu menus message mkdir modify mouse move mtdll multilocks near nocptrans note notify nulldisplay nowshow object objects odometer of off oleobject on open optimize order pack pad page palette parameters path pdsetup play point pop popup popups printer private procedure procedures project public push query quitrd read readborder readerror recall refresh reindex relation release remove rename replace report reprocess resource restore resume retry return rmdir rollback run safety save scan scatter scheme screen scroll seconds seek select selection separator set show shutdown size skip skip sort space sql status step store strictdate structure sum suspend sysformats sysmenu table tables tablevalidate tag talk textmerge this throw to topic total transaction trbetween trigger try type typeahead udfparms unbindevents unique unlock update use validate view views wait where window windows windows win32api zap zoom",built_in:"abs aclass acopy acos adatabases adbobjects addbs addproperty adel adir adlls adockstate aelement aerror aevents afields afont agetclass agetfileversion ains ainstance alanguage alen alias alines alltrim amembers amouseobj anetresources aprinters aprocinfo asc ascan aselobj asessions asin asort astackinfo asubscript at at_c ataginfo atan atc atcc atcline atline atn2 aused avcxclasses bar barcount barprompt between bindevent bintoc bitand bitclear bitlshift bitnot bitor bitrshift bitset bittest bitxor bof candidate capslock cdow cdx ceiling chr chrsaw chrtran chrtranc cmonth cntbar cntpad col com comarray comclassinfo compobj comprop comreturnerror cos cpconvert cpcurrent cpdbf createbinary createobject createobjectex createoffline ctobin ctod ctot curdir cursorgetprop cursorsetprop cursortoxml curval date datetime day dbc dbf dbgetprop dbsetprop dbused ddeaborttrans ddeadvise ddeenabled ddeexecute ddeinitiate ddelasterror ddepoke dderequest ddesetoption ddesetservice ddesettopic ddeterminate defaultext deleted descending difference directory diskspace displaypath dmy dodefault doevents dow drivetype dropoffline dtoc dtor dtos dtot editsource empty eof error evaluate eventhandler evl execscript exp fchsize fclose fcount fcreate fdate feof ferror fflush fgets field file filetostr filter fklabel fkmax fldlist flock floor fontmetric fopen forceext forcepath found fputs fread fseek fsize ftime fullpath function command fv fwrite getbar getcolor getcp getdir getenv getfile getfldstate getfont getinterface getnextmodified getobject getpad getpem getpict getprinter getwordcount getwordnum getcursoradapter gomonth header home hour idxcollate iif imestatus indbc indexseek inkey inlist inputbox insmode int integer isalpha isblank iscolor isdigit isexclusive isflocked isleadbyte islower ismouse isnull isreadonly isrlocked isupper justdrive justext justfname justpath juststem key keymatch lastkey left leftc len lenc like likec lineno loadpicture locfile lock log log10 lookup lower ltrim lupdate max mcol mdown mdx mdy memlines memory menu message messagebox min minute mline mod month mrkbar mrkpad mrow mton mwindow ndx newobject normalize nowait noshow ntom numlock nvl objnum objtoclient objvar occurs oemtoansi oldval on order os pad padl padr padc parameters payment pcol pcount pemstatus pi popup primary printstatus prmbar prmpad program prompt proper prow prtinfo putfile pv quarter raiseevent rand rat ratc ratline rdlevel readkey reccount recno recsize refresh relation replicate requery rgb rgbscheme right rightc rlock round row rtod rtrim savepicture scheme scols sec seconds seek set setfldstate sign sin skpbar skppad soundex space sqlcancel sqlcolumns sqlcommit sqlconnect sqldisconnect sqlexec sqlgetprop sqlmoreresults sqlprepare sqlrollback sqlsetprop sqlstringconnect sqltables sqrt srows str strconv strextract strtofile strtran stuff stuffc substr substrc syss overview sysmetric tablerevert tableupdate tag tagcount tagno tan target textmerge time transform trim ttoc ttod txnlevel txtwidth type unbindevents unique updated upper used val varread vartype version wborder wchild wcols wdockable week wexist wfont wlast wlcol wlrow wmaximum wminimum wontop woutput wparent wread wrows wtitle wvisible xmltocursor xmlupdategram year_alignment _asciicols _asciirows _assist _beautify _box _browser _builder _calcmem _calcvalue _cliptext _converter _coverage _coverage _curobj _dblclick _diarydate _dos _foxdoc _foxgraph _gallery _gengraph _genhtml _genmenu _genpd _genscrn _genxtab _getexpr _include _indent _lmargin _mac _mda_appnd _mda_avg _mda_brow _mda_calc _mda_copy _mda_count _mda_label _mda_pack _mda_reprt _mda_rindx _mda_setup _mda_sort _mda_sp100 _mda_sp200 _mda_sp300 _mda_sum _mda_total _mdata _mdiary _med_clear _med_copy _med_cut _med_cvtst _med_find _med_finda _med_goto _med_insob _med_link _med_obj _med_paste _med_pref _med_pstlk _med_redo _med_repl _med_repla _med_slcta _med_sp100 _med_sp200 _med_sp300 _med_sp400 _med_sp500 _med_undo _medit _mfi_clall _mfi_close _mfi_export _mfi_import _mfi_new _mfi_open _mfi_pgset _mfi_prevu _mfi_print _mfi_quit _mfi_revrt _mfi_savas _mfi_save _mfi_send _mfi_setup _mfi_sp100 _mfi_sp200 _mfi_sp300 _mfi_sp400 _mfile _mfiler _mfirst _mlabel _mlast _mline _mmacro _mmbldr _mpr_beaut _mpr_cancl _mpr_compl _mpr_do _mpr_docum _mpr_formwz _mpr_gener _mpr_graph _mpr_resum _mpr_sp100 _mpr_sp200 _mpr_sp300 _mpr_suspend _mprog _mproj _mrc_appnd _mrc_chnge _mrc_cont _mrc_delet _mrc_goto _mrc_locat _mrc_recal _mrc_repl _mrc_seek _mrc_sp100 _mrc_sp200 _mrecord _mreport _mrqbe _mscreen _msm_data _msm_edit _msm_file _msm_format _msm_prog _msm_recrd _msm_systm _msm_text _msm_tools _msm_view _msm_windo _mst_about _mst_ascii _mst_calcu _mst_captr _mst_dbase _mst_diary _mst_filer _mst_help _mst_hphow _mst_hpsch _mst_macro _mst_office _mst_puzzl _mst_sp100 _mst_sp200 _mst_sp300 _mst_specl _msysmenu _msystem _mtable _mtb_appnd _mtb_cpart _mtb_delet _mtb_delrc _mtb_goto _mtb_link _mtb_mvfld _mtb_mvprt _mtb_props _mtb_recal _mtb_sp100 _mtb_sp200 _mtb_sp300 _mtb_sp400 _mtb_szfld _mwi_arran _mwi_clear _mwi_cmd _mwi_color _mwi_debug _mwi_hide _mwi_hidea _mwi_min _mwi_move _mwi_rotat _mwi_showa _mwi_size _mwi_sp100 _mwi_sp200 _mwi_toolb _mwi_trace _mwi_view _mwi_zoom _mwindow _mwizards _mwz_all _mwz_form _mwz_foxdoc _mwz_import _mwz_label _mwz_mail _mwz_pivot _mwz_query _mwz_reprt _mwz_setup _mwz_table _mwz_upsizing _netware _oracle _padvance _pageno _pbpage _pcolno _pcopies _pdparms _pdriver _pdsetup _pecode _peject _pepage _pform _plength _plineno _ploffset _ppitch _pquality _pretext _pscode _pspacing _pwait _rmargin _runactivedoc _samples _screen _shell _spellchk _sqlserver _startup _tabs _tally _text _throttle _transport _triggerlevel _unix _webdevonly _webmenu _webmsfthomepage _webvfphomepage _webvfponlinesupport _windows _wizard _wrap _scctext _vfp",literal:"\\.t\\. \\.f\\. null"},i:"//",c:[{cN:"string",b:"'",e:"'"},{cN:"string",b:'"',e:'"'},{cN:"string",b:"\\[",e:"\\]"},{cN:"meta",b:"#",e:"$",k:{"meta-keyword":"#if #elseif #endif #define #undefine"}},e.C(/(^\s*\*)|(\&\&)/,/$/,{r:0}),e.CNM]}}),o.registerLanguage("fsharp",function(e){var t={b:"<",e:">",c:[e.inherit(e.TM,{b:/'[a-zA-Z0-9_]+/})]};return{aliases:["fs"],k:"abstract and as assert base begin class default delegate do done downcast downto elif else end exception extern false finally for fun function global if in inherit inline interface internal lazy let match member module mutable namespace new null of open or override private public rec return sig static struct then to true try type upcast use val void when while with yield",i:/\/\*/,c:[{cN:"keyword",b:/\b(yield|return|let|do)!/},{cN:"string",b:'@"',e:'"',c:[{b:'""'}]},{cN:"string",b:'"""',e:'"""'},e.C("\\(\\*","\\*\\)"),{cN:"class",bK:"type",e:"\\(|=|$",eE:!0,c:[e.UTM,t]},{cN:"meta",b:"\\[<",e:">\\]",r:10},{cN:"symbol",b:"\\B('[A-Za-z])\\b",c:[e.BE]},e.CLCM,e.inherit(e.QSM,{i:null}),e.CNM]}}),o.registerLanguage("go",function(e){var t={keyword:"break default func interface select case map struct chan else goto package switch const fallthrough if range type continue for import return var go defer bool byte complex64 complex128 float32 float64 int8 int16 int32 int64 string uint8 uint16 uint32 uint64 int uint uintptr rune",literal:"true false iota nil",built_in:"append cap close complex copy imag len make new panic print println real recover delete"};return{aliases:["golang"],k:t,i:"",c:[e.CLCM,e.CBCM,{cN:"string",v:[e.QSM,{b:"'",e:"[^\\\\]'"},{b:"`",e:"`"}]},{cN:"number",v:[{b:e.CNR+"[i]",r:1},e.CNM]},{b:/:=/},{cN:"function",bK:"func",e:/\s*\{/,eE:!0,c:[e.TM,{cN:"params",b:/\(/,e:/\)/,k:t,i:/["']/}]}]}}),o.registerLanguage("http",function(e){var t="HTTP/[0-9\\.]+";return{aliases:["https"],i:"\\S",c:[{b:"^"+t,e:"$",c:[{cN:"number",b:"\\b\\d{3}\\b"}]},{b:"^[A-Z]+ (.*?) "+t+"$",rB:!0,e:"$",c:[{cN:"string",b:" ",e:" ",eB:!0,eE:!0},{b:t},{cN:"keyword",b:"[A-Z]+"}]},{cN:"attribute",b:"^\\w",e:": ",eE:!0,i:"\\n|\\s|=",starts:{e:"$",r:0}},{b:"\\n\\n",starts:{sL:[],eW:!0}}]}}),o.registerLanguage("ini",function(e){var t={cN:"string",c:[e.BE],v:[{b:"'''",e:"'''",r:10},{b:'"""',e:'"""',r:10},{b:'"',e:'"'},{b:"'",e:"'"}]};return{aliases:["toml"],cI:!0,i:/\S/,c:[e.C(";","$"),e.HCM,{cN:"section",b:/^\s*\[+/,e:/\]+/},{b:/^[a-z0-9\[\]_\.-]+\s*=\s*/,e:"$",rB:!0,c:[{cN:"attr",b:/[a-z0-9\[\]_\.-]+/},{b:/=/,eW:!0,r:0,c:[e.C(";","$"),e.HCM,{cN:"literal",b:/\bon|off|true|false|yes|no\b/},{cN:"variable",v:[{b:/\$[\w\d"][\w\d_]*/},{b:/\$\{(.*?)}/}]},t,{cN:"number",b:/([\+\-]+)?[\d]+_[\d_]+/},e.NM]}]}]}}),o.registerLanguage("java",function(e){var t="false synchronized int abstract float private char boolean var static null if const for true while long strictfp finally protected import native final void enum else break transient catch instanceof byte super volatile case assert short package default double public try this switch continue throws protected public private module requires exports do",r={cN:"number",b:"\\b(0[bB]([01]+[01_]+[01]+|[01]+)|0[xX]([a-fA-F0-9]+[a-fA-F0-9_]+[a-fA-F0-9]+|[a-fA-F0-9]+)|(([\\d]+[\\d_]+[\\d]+|[\\d]+)(\\.([\\d]+[\\d_]+[\\d]+|[\\d]+))?|\\.([\\d]+[\\d_]+[\\d]+|[\\d]+))([eE][-+]?\\d+)?)[lLfF]?",r:0};return{aliases:["jsp"],k:t,i:/<\/|#/,c:[e.C("/\\*\\*","\\*/",{r:0,c:[{b:/\w+@/,r:0},{cN:"doctag",b:"@[A-Za-z]+"}]}),e.CLCM,e.CBCM,e.ASM,e.QSM,{cN:"class",bK:"class interface",e:/[{;=]/,eE:!0,k:"class interface",i:/[:"\[\]]/,c:[{bK:"extends implements"},e.UTM]},{bK:"new throw return else",r:0},{cN:"function",b:"([À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*(<[À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*(\\s*,\\s*[À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*)*>)?\\s+)+"+e.UIR+"\\s*\\(",rB:!0,e:/[{;=]/,eE:!0,k:t,c:[{b:e.UIR+"\\s*\\(",rB:!0,r:0,c:[e.UTM]},{cN:"params",b:/\(/,e:/\)/,k:t,r:0,c:[e.ASM,e.QSM,e.CNM,e.CBCM]},e.CLCM,e.CBCM]},r,{cN:"meta",b:"@[A-Za-z]+"}]}}),o.registerLanguage("javascript",function(e){var t="[A-Za-z$_][0-9A-Za-z$_]*",r={keyword:"in of if for while finally var new function do return void else break catch instanceof with throw case default try this switch continue typeof delete let yield const export super debugger as async await static import from as",literal:"true false null undefined NaN Infinity",built_in:"eval isFinite isNaN parseFloat parseInt decodeURI decodeURIComponent encodeURI encodeURIComponent escape unescape Object Function Boolean Error EvalError InternalError RangeError ReferenceError StopIteration SyntaxError TypeError URIError Number Math Date String RegExp Array Float32Array Float64Array Int16Array Int32Array Int8Array Uint16Array Uint32Array Uint8Array Uint8ClampedArray ArrayBuffer DataView JSON Intl arguments require module console window document Symbol Set Map WeakSet WeakMap Proxy Reflect Promise"},a={cN:"number",v:[{b:"\\b(0[bB][01]+)"},{b:"\\b(0[oO][0-7]+)"},{b:e.CNR}],r:0},o={cN:"subst",b:"\\$\\{",e:"\\}",k:r,c:[]},i={cN:"string",b:"`",e:"`",c:[e.BE,o]};o.c=[e.ASM,e.QSM,i,a,e.RM];var n=o.c.concat([e.CBCM,e.CLCM]);return{aliases:["js","jsx"],k:r,c:[{cN:"meta",r:10,b:/^\s*['"]use (strict|asm)['"]/},{cN:"meta",b:/^#!/,e:/$/},e.ASM,e.QSM,i,e.CLCM,e.CBCM,a,{b:/[{,]\s*/,r:0,c:[{b:t+"\\s*:",rB:!0,r:0,c:[{cN:"attr",b:t,r:0}]}]},{b:"("+e.RSR+"|\\b(case|return|throw)\\b)\\s*",k:"return throw case",c:[e.CLCM,e.CBCM,e.RM,{cN:"function",b:"(\\(.*?\\)|"+t+")\\s*=>",rB:!0,e:"\\s*=>",c:[{cN:"params",v:[{b:t},{b:/\(\s*\)/},{b:/\(/,e:/\)/,eB:!0,eE:!0,k:r,c:n}]}]},{cN:"",b:/\s/,e:/\s*/,skip:!0},{b:/,e:/(\/[A-Za-z0-9\\._:-]+|[A-Za-z0-9\\._:-]+\/)>/,sL:"xml",c:[{b:/<[A-Za-z0-9\\._:-]+\s*\/>/,skip:!0},{b:/<[A-Za-z0-9\\._:-]+/,e:/(\/[A-Za-z0-9\\._:-]+|[A-Za-z0-9\\._:-]+\/)>/,skip:!0,c:[{b:/<[A-Za-z0-9\\._:-]+\s*\/>/,skip:!0},"self"]}]}],r:0},{cN:"function",bK:"function",e:/\{/,eE:!0,c:[e.inherit(e.TM,{b:t}),{cN:"params",b:/\(/,e:/\)/,eB:!0,eE:!0,c:n}],i:/\[|%/},{b:/\$[(.]/},e.METHOD_GUARD,{cN:"class",bK:"class",e:/[{;=]/,eE:!0,i:/[:"\[\]]/,c:[{bK:"extends"},e.UTM]},{bK:"constructor get set",e:/\{/,eE:!0}],i:/#(?!!)/}}),o.registerLanguage("json",function(e){var t={literal:"true false null"},r=[e.QSM,e.CNM],a={e:",",eW:!0,eE:!0,c:r,k:t},o={b:"{",e:"}",c:[{cN:"attr",b:/"/,e:/"/,c:[e.BE],i:"\\n"},e.inherit(a,{b:/:/})],i:"\\S"},i={b:"\\[",e:"\\]",c:[e.inherit(a)],i:"\\S"};return r.splice(r.length,0,o,i),{c:r,k:t,i:"\\S"}}),o.registerLanguage("kotlin",function(e){var t={keyword:"abstract as val var vararg get set class object open private protected public noinline crossinline dynamic final enum if else do while for when throw try catch finally import package is in fun override companion reified inline lateinit init interface annotation data sealed internal infix operator out by constructor super tailrec where const inner suspend typealias external expect actual trait volatile transient native default",built_in:"Byte Short Char Int Long Boolean Float Double Void Unit Nothing",literal:"true false null"},r={cN:"symbol",b:e.UIR+"@"},a={cN:"subst",b:"\\${",e:"}",c:[e.ASM,e.CNM]},o={cN:"variable",b:"\\$"+e.UIR},i={cN:"string",v:[{b:'"""',e:'"""',c:[o,a]},{b:"'",e:"'",i:/\n/,c:[e.BE]},{b:'"',e:'"',i:/\n/,c:[e.BE,o,a]}]},n={cN:"meta",b:"@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\s*:(?:\\s*"+e.UIR+")?"},s={cN:"meta",b:"@"+e.UIR,c:[{b:/\(/,e:/\)/,c:[e.inherit(i,{cN:"meta-string"})]}]},c={cN:"number",b:"\\b(0[bB]([01]+[01_]+[01]+|[01]+)|0[xX]([a-fA-F0-9]+[a-fA-F0-9_]+[a-fA-F0-9]+|[a-fA-F0-9]+)|(([\\d]+[\\d_]+[\\d]+|[\\d]+)(\\.([\\d]+[\\d_]+[\\d]+|[\\d]+))?|\\.([\\d]+[\\d_]+[\\d]+|[\\d]+))([eE][-+]?\\d+)?)[lLfF]?",r:0};return{aliases:["kt"],k:t,c:[e.C("/\\*\\*","\\*/",{r:0,c:[{cN:"doctag",b:"@[A-Za-z]+"}]}),e.CLCM,e.CBCM,{cN:"keyword",b:/\b(break|continue|return|this)\b/,starts:{c:[{cN:"symbol",b:/@\w+/}]}},r,n,s,{cN:"function",bK:"fun",e:"[(]|$",rB:!0,eE:!0,k:t,i:/fun\s+(<.*>)?[^\s\(]+(\s+[^\s\(]+)\s*=/,r:5,c:[{b:e.UIR+"\\s*\\(",rB:!0,r:0,c:[e.UTM]},{cN:"type",b:/,e:/>/,k:"reified",r:0},{cN:"params",b:/\(/,e:/\)/,endsParent:!0,k:t,r:0,c:[{b:/:/,e:/[=,\/]/,eW:!0,c:[{cN:"type",b:e.UIR},e.CLCM,e.CBCM],r:0},e.CLCM,e.CBCM,n,s,i,e.CNM]},e.CBCM]},{cN:"class",bK:"class interface trait",e:/[:\{(]|$/,eE:!0,i:"extends implements",c:[{bK:"public protected internal private constructor"},e.UTM,{cN:"type",b:/,e:/>/,eB:!0,eE:!0,r:0},{cN:"type",b:/[,:]\s*/,e:/[<\(,]|$/,eB:!0,rE:!0},n,s]},i,{cN:"meta",b:"^#!/usr/bin/env",e:"$",i:"\n"},c]}}),o.registerLanguage("less",function(e){var t="[\\w-]+",r="("+t+"|@{"+t+"})",a=[],o=[],i=function(e){return{cN:"string",b:"~?"+e+".*?"+e}},n=function(e,t,r){return{cN:e,b:t,r:r}},s={b:"\\(",e:"\\)",c:o,r:0};o.push(e.CLCM,e.CBCM,i("'"),i('"'),e.CSSNM,{b:"(url|data-uri)\\(",starts:{cN:"string",e:"[\\)\\n]",eE:!0}},n("number","#[0-9A-Fa-f]+\\b"),s,n("variable","@@?"+t,10),n("variable","@{"+t+"}"),n("built_in","~?`[^`]*?`"),{cN:"attribute",b:t+"\\s*:",e:":",rB:!0,eE:!0},{cN:"meta",b:"!important"});var c=o.concat({b:"{",e:"}",c:a}),l={bK:"when",eW:!0,c:[{bK:"and not"}].concat(o)},N={b:r+"\\s*:",rB:!0,e:"[;}]",r:0,c:[{cN:"attribute",b:r,e:":",eE:!0,starts:{eW:!0,i:"[<=$]",r:0,c:o}}]},d={cN:"keyword",b:"@(import|media|charset|font-face|(-[a-z]+-)?keyframes|supports|document|namespace|page|viewport|host)\\b",starts:{e:"[;{}]",rE:!0,c:o,r:0}},u={cN:"variable",v:[{b:"@"+t+"\\s*:",r:15},{b:"@"+t}],starts:{e:"[;}]",rE:!0,c:c}},E={v:[{b:"[\\.#:&\\[>]",e:"[;{}]"},{b:r,e:"{"}],rB:!0,rE:!0,i:"[<='$\"]",r:0,c:[e.CLCM,e.CBCM,l,n("keyword","all\\b"),n("variable","@{"+t+"}"),n("selector-tag",r+"%?",0),n("selector-id","#"+r),n("selector-class","\\."+r,0),n("selector-tag","&",0),{cN:"selector-attr",b:"\\[",e:"\\]"},{cN:"selector-pseudo",b:/:(:)?[a-zA-Z0-9\_\-\+\(\)"'.]+/},{b:"\\(",e:"\\)",c:c},{b:"!important"}]};return a.push(e.CLCM,e.CBCM,d,u,N,E),{cI:!0,i:"[=>'/<($\"]",c:a}}),o.registerLanguage("makefile",function(e){var t={cN:"variable",v:[{b:"\\$\\("+e.UIR+"\\)",c:[e.BE]},{b:/\$[@%\^\+\*]/}]},r={cN:"string",b:/"/,e:/"/,c:[e.BE,t]},a={cN:"variable",b:/\$\([\w-]+\s/,e:/\)/,k:{built_in:"subst patsubst strip findstring filter filter-out sort word wordlist firstword lastword dir notdir suffix basename addsuffix addprefix join wildcard realpath abspath error warning shell origin flavor foreach if or and call eval file value"},c:[t]},o={b:"^"+e.UIR+"\\s*[:+?]?=",i:"\\n",rB:!0,c:[{b:"^"+e.UIR,e:"[:+?]?=",eE:!0}]},i={cN:"section",b:/^[^\s]+:/,e:/$/,c:[t]};return{aliases:["mk","mak"],k:"define endef undefine ifdef ifndef ifeq ifneq else endif include -include sinclude override export unexport private vpath",l:/[\w-]+/,c:[e.HCM,t,r,a,o,{cN:"meta",b:/^\.PHONY:/,e:/$/,k:{"meta-keyword":".PHONY"},l:/[\.\w]+/},i]}}),o.registerLanguage("xml",function(e){var t={eW:!0,i:/,r:0,c:[{cN:"attr",b:"[A-Za-z0-9\\._:-]+",r:0},{b:/=\s*/,r:0,c:[{cN:"string",endsParent:!0,v:[{b:/"/,e:/"/},{b:/'/,e:/'/},{b:/[^\s"'=<>`]+/}]}]}]};return{aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist"],cI:!0,c:[{cN:"meta",b:"",r:10,c:[{b:"\\[",e:"\\]"}]},e.C("\x3c!--","--\x3e",{r:10}),{b:"<\\!\\[CDATA\\[",e:"\\]\\]>",r:10},{cN:"meta",b:/<\?xml/,e:/\?>/,r:10},{b:/<\?(php)?/,e:/\?>/,sL:"php",c:[{b:"/\\*",e:"\\*/",skip:!0},{b:'b"',e:'"',skip:!0},{b:"b'",e:"'",skip:!0},e.inherit(e.ASM,{i:null,cN:null,c:null,skip:!0}),e.inherit(e.QSM,{i:null,cN:null,c:null,skip:!0})]},{cN:"tag",b:"",rE:!0,sL:["css","xml"]}},{cN:"tag",b:"