Repository navigation
Expand file tree
/
Copy pathcodelight.min.js
More file actions
20 lines (20 loc) · 46.5 KB
/
Copy pathcodelight.min.js
File metadata and controls
20 lines (20 loc) · 46.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/*! codelight.js 1.6.1 | MIT License | https://github.com/codelightjs/codelight.js */
"use strict";var codelight=(()=>{var I=Object.defineProperty;var qt=Object.getOwnPropertyDescriptor;var Pt=Object.getOwnPropertyNames;var Ft=Object.prototype.hasOwnProperty;var Bt=(e,t,s)=>t in e?I(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var Ht=(e,t)=>{for(var s in t)I(e,s,{get:t[s],enumerable:!0})},Wt=(e,t,s,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of Pt(t))!Ft.call(e,a)&&a!==s&&I(e,a,{get:()=>t[a],enumerable:!(n=qt(t,a))||n.enumerable});return e};var Gt=e=>Wt(I({},"__esModule",{value:!0}),e);var Ae=(e,t,s)=>Bt(e,typeof t!="symbol"?t+"":t,s);var An={};Ht(An,{addCopyButton:()=>D,addLanguage:()=>V,createMarkup:()=>M,createStream:()=>j,default:()=>_n,defineLanguage:()=>o,detectLanguage:()=>_,escapeHtml:()=>Z,getLanguage:()=>T,highlight:()=>R,highlightAll:()=>be,highlightAuto:()=>ge,highlightElement:()=>we,injectTheme:()=>Le,languages:()=>Y,lightUp:()=>K,listLanguages:()=>me,mount:()=>xe,registerLanguage:()=>pe,renderLine:()=>O,setDetector:()=>fe,splitFences:()=>ke,themeCss:()=>ee,tokenize:()=>J});async function Qt(e,t=document){try{await t.defaultView.navigator.clipboard.writeText(e)}catch{let s=t.createElement("textarea");s.value=e,s.setAttribute("readonly",""),s.style.cssText="position:fixed;top:-1000px;opacity:0",t.body.append(s),s.select(),t.execCommand("copy"),s.remove()}}function D(e,t={}){let s=e.parentElement;if(!s||[...s.children].some(l=>l.classList.contains("cl-copy")))return null;let n=e.ownerDocument,a=t.label??"Copy",r=n.createElement("button");r.type="button",r.className="cl-copy",r.textContent=a,r.setAttribute("aria-label","Copy code");let p;return r.addEventListener("click",async()=>{await Qt(e.textContent??"",n),r.textContent=t.copiedLabel??"Copied",clearTimeout(p),p=setTimeout(()=>r.textContent=a,1500)}),s.classList.add("cl-has-copy"),s.append(r),r}var S=class{constructor(){Ae(this,"tokens",[])}add(t,s){if(!s)return;let n=this.tokens[this.tokens.length-1];n&&n.type===t?n.text+=s:this.tokens.push(t?{type:t,text:s}:{text:s})}},$=(e,t)=>new Set((e??"").split(/\s+/).filter(Boolean).map(s=>t?s.toLowerCase():s)),Se=e=>new RegExp(e.source,e.flags.replace(/[gy]/g,"")+"y"),Ce=/(?:0[xX][\da-fA-F_]+|0[bB][01_]+|0[oO][0-7_]+|(?:\d[\d_]*(?:\.\d[\d_]*)?|\.\d[\d_]*)(?:[eE][+-]?\d+)?)\w*/y,Vt=/[A-Za-z_$][\w$]*/,Te=/\s+/y,Oe=/[+\-*/%=<>!&|^~?:]+/y,Ne=/\s*\(/y,ze=/<<(-?)\s*(['"]?)([A-Za-z_]\w*)\2/y,Yt="()[]{},;.",Xt={"}":"{",")":"(","]":"["};function o(e){let t=e.caseInsensitive??!1,s=$(e.keywords,t),n=$(e.constants,t),a=$(e.types,t),r=$(e.variables,t),p=$(e.builtins,t),l=(e.rules??[]).map(i=>({match:Se(i.match),type:i.type})),h=[...e.strings??[]].sort((i,k)=>k.open.length-i.open.length).map(i=>({open:i.open,close:i.close??i.open,escape:i.escape??!0,multiline:i.multiline??!1,type:i.type??"string",interpolate:i.interpolate})),x=Se(e.identifier??Vt),v=e.calls??!0,L=e.numbers??!0,A=e.operators??!0;function E(i,k,c){let f=t?i.toLowerCase():i;if(s.has(f))return"keyword";if(n.has(f))return"constant";if(a.has(f))return"type";if(r.has(f))return"variable";if(p.has(f)||v&&(Ne.lastIndex=c,Ne.test(k)))return"function";if(e.classNames&&/^[A-Z]/.test(i)&&/[a-z]/.test(i))return"type"}return{tokenizeLine(i,k){let c=new S,f=k?[...k]:[],C=()=>f[f.length-1],N,m=0,g,te=C();if(te?.t==="heredoc")return(te.dash?i.replace(/^\t+/,""):i)===te.end?(c.add("meta",i),f.pop()):c.add("string",i),{tokens:c.tokens,state:f.length?f:null};e:for(;m<i.length;){let b=C();if(b?.t==="comment"){let u=i.indexOf(b.close,m);if(u<0){c.add("comment",i.slice(m));break}c.add("comment",i.slice(m,u+b.close.length)),m=u+b.close.length,f.pop();continue}if(b?.t==="string"){let u=b.s;for(let w=m;w<i.length;w++){if(u.interpolate&&i.startsWith(u.interpolate[0],w)){if(u.interpolate[0]==="{"&&i[w+1]==="{"){w++;continue}c.add(u.type,i.slice(m,w)),c.add("punctuation",u.interpolate[0]),m=w+u.interpolate[0].length;let _e=u.interpolate[1];f.push({t:"code",close:_e,open:Xt[_e]??"",depth:0});continue e}if(u.escape&&i[w]==="\\"){w++;continue}if(i.startsWith(u.close,w)){c.add(u.type,i.slice(m,w+u.close.length)),m=w+u.close.length,f.pop();continue e}}c.add(u.type,i.slice(m));break}if(b?.t==="code"){if(b.depth===0&&i.startsWith(b.close,m)){c.add("punctuation",b.close),m+=b.close.length,f.pop();continue}let u=i[m];if(u===b.open||b.depth>0&&u===b.close){f[f.length-1]={...b,depth:b.depth+(u===b.open?1:-1)},c.add("punctuation",u),m++;continue}}for(let u of l){u.match.lastIndex=m;let w=u.match.exec(i);if(w&&w[0]){c.add(u.type,w[0]),m+=w[0].length;continue e}}for(let[u,w]of e.blockComment??[])if(i.startsWith(u,m)){c.add("comment",u),m+=u.length,f.push({t:"comment",close:w});continue e}for(let u of e.lineComment??[])if(i.startsWith(u,m)){c.add("comment",i.slice(m));break e}for(let u of h)if(i.startsWith(u.open,m)){c.add(u.type,u.open),m+=u.open.length,f.push({t:"string",s:u});continue e}if(e.heredoc&&(g=(ze.lastIndex=m,ze.exec(i)))){c.add("operator",`<<${g[1]}`),c.add("meta",g[0].slice(2+g[1].length)),N={t:"heredoc",end:g[3],dash:!!g[1]},m+=g[0].length;continue}if(Ce.lastIndex=m,L&&(g=Ce.exec(i))){c.add("number",g[0]),m+=g[0].length;continue}if(x.lastIndex=m,(g=x.exec(i))&&g[0]){c.add(E(g[0],i,m+g[0].length),g[0]),m+=g[0].length;continue}if(Te.lastIndex=m,g=Te.exec(i)){c.add(void 0,g[0]),m+=g[0].length;continue}if(Oe.lastIndex=m,g=Oe.exec(i)){c.add(A?"operator":void 0,g[0]),m+=g[0].length;continue}let Ee=i[m];c.add(Yt.includes(Ee)?"punctuation":void 0,Ee),m++}let ve=f.findIndex(b=>b.t==="string"&&!b.s.multiline);return ve>=0&&(f.length=ve),N&&f.push(N),{tokens:c.tokens,state:f.length?f:null}}}}var U={tokenizeLine:e=>({tokens:e?[{text:e}]:[],state:null})};var q=o({strings:[{open:'"',multiline:!0},{open:"'",escape:!1,multiline:!0}],keywords:"if then else elif fi for while until do done case esac in function select return exit break continue local export readonly declare unset source alias time",builtins:"echo cd printf read set shift test eval exec trap pwd ls cat grep sed awk find mkdir rm cp mv chmod chown touch curl wget tar sudo git npm npx pnpm yarn bun node deno python python3 pip pip3 docker kubectl ssh make brew apt apt-get",rules:[{match:/(?<=^|\s)#.*/,type:"comment"},{match:/\$(?:\{[^}]*\}|[A-Za-z_]\w*|[\d@#?$!*-])/,type:"variable"},{match:/(?<=^\s*(?:(?:export|local|declare|readonly)\s+)?)[A-Za-z_]\w*(?==)/,type:"variable"},{match:/(?<=\s)--?[A-Za-z][\w-]*/,type:"attr"}],identifier:/[A-Za-z_][\w-]*/,calls:!1,heredoc:!0});var d={lineComment:["//"],blockComment:[["/*","*/"]]},y=[{open:'"'},{open:"'"}];var ne="auto break case const continue default do else enum extern for goto if inline register restrict return sizeof static struct switch typedef union volatile while",re="char double float int long short signed unsigned void bool size_t ssize_t int8_t int16_t int32_t int64_t uint8_t uint16_t uint32_t uint64_t FILE",oe=[{match:/(?<=^\s*#\s*include\s*)<[^>]*>/,type:"string"},{match:/(?<=^\s*)#\s*[A-Za-z]+/,type:"meta"}],Re=o({...d,strings:y,keywords:ne,types:re,constants:"NULL true false",rules:oe});var De=o({...d,strings:y,keywords:ne+" class namespace template typename public private protected virtual override final new delete this try catch throw using operator friend explicit constexpr consteval noexcept auto decltype static_cast dynamic_cast reinterpret_cast const_cast co_await co_return co_yield concept requires mutable",types:re+" string vector map unordered_map set array unique_ptr shared_ptr optional",constants:"nullptr NULL true false",rules:oe,classNames:!0});var se=["{","}"],$e=o({...d,strings:[{open:'$@"',close:'"',escape:!1,multiline:!0,interpolate:se},{open:'@$"',close:'"',escape:!1,multiline:!0,interpolate:se},{open:'@"',close:'"',escape:!1,multiline:!0},{open:'$"',close:'"',interpolate:se},...y],keywords:"abstract as base break case catch checked class const continue default delegate do else enum event explicit extern finally fixed for foreach goto if implicit in interface internal is lock namespace new operator out override params private protected public readonly ref return sealed sizeof stackalloc static struct switch this throw try typeof unchecked unsafe using virtual volatile while async await var record get set init yield where when",types:"bool byte char decimal double float int long object sbyte short string uint ulong ushort void dynamic",constants:"true false null",rules:[{match:/(?<=^\s*)\[[A-Z]\w*(?:\([^)]*\))?\]/,type:"meta"}],classNames:!0});var P=o({blockComment:[["/*","*/"]],strings:y,rules:[{match:/@[\w-]+/,type:"keyword"},{match:/#[\da-fA-F]{3,8}(?![\w-])/,type:"number"},{match:/(?:--|-?[A-Za-z])[\w-]*(?=\s*:(?!:)[^{};]*(?:[;})]|$))/,type:"property"},{match:/[.#][A-Za-z_-][\w-]*/,type:"type"},{match:/::?[A-Za-z-]+/,type:"attr"},{match:/!\s*important/,type:"keyword"}],identifier:/-?[A-Za-z_][\w-]*/});var Jt={tokenizeLine(e){if(!e)return{tokens:[],state:null};let t=e.startsWith("+++")||e.startsWith("---")||e.startsWith("@@")||e.startsWith("diff ")||e.startsWith("index ")?"meta":e[0]==="+"?"inserted":e[0]==="-"?"deleted":void 0;return{tokens:[t?{type:t,text:e}:{text:e}],state:null}}},Me=Jt;var Kt="FROM|RUN|CMD|LABEL|EXPOSE|ENV|ADD|COPY|ENTRYPOINT|VOLUME|USER|WORKDIR|ARG|ONBUILD|STOPSIGNAL|HEALTHCHECK|SHELL|MAINTAINER",Ze=o({strings:[{open:'"'},{open:"'",escape:!1}],rules:[{match:/(?<=^\s*)#.*/,type:"comment"},{match:new RegExp(`(?<=^\\s*)(?:${Kt})\\b`,"i"),type:"keyword"},{match:/(?<=^\s*FROM\s.*\s)AS(?=\s)/i,type:"keyword"},{match:/\$(?:\{[^}]*\}|[A-Za-z_]\w*)/,type:"variable"},{match:/(?<=\s)--[A-Za-z][\w-]*/,type:"attr"}],identifier:/[A-Za-z_][\w.-]*/,calls:!1});var je=o({...d,strings:[{open:'"'},{open:"'"},{open:"`",escape:!1,multiline:!0}],keywords:"break case chan const continue default defer else fallthrough for func go goto if import interface map package range return select struct switch type var",constants:"true false nil iota",types:"string int int8 int16 int32 int64 uint uint8 uint16 uint32 uint64 uintptr float32 float64 complex64 complex128 bool byte rune error any",builtins:"append cap close copy delete len make new panic print println recover"});var Ie=o({lineComment:["#"],strings:[{open:'"""',multiline:!0},{open:'"'}],keywords:"query mutation subscription fragment on type interface union enum input scalar schema extend directive implements repeatable",constants:"true false null",types:"Int Float String Boolean ID",rules:[{match:/\$[A-Za-z_]\w*/,type:"variable"},{match:/@[A-Za-z_]\w*/,type:"meta"},{match:/\.\.\./,type:"operator"},{match:/[A-Za-z_]\w*(?=\s*:)/,type:"property"}],classNames:!0});var Ue=o({lineComment:["#","//"],blockComment:[["/*","*/"]],strings:[{open:'"',interpolate:["${","}"]}],constants:"true false null",types:"string number bool list map set object tuple any",rules:[{match:/(?<=^\s*)(?:resource|data|variable|output|module|provider|locals|terraform|moved|import|check)\b/,type:"keyword"},{match:/\b(?:for|in|if|for_each|count|depends_on|lifecycle|dynamic|content)\b(?!\s*=)/,type:"keyword"},{match:/(?<=^\s*)[A-Za-z_][\w-]*(?=\s*=(?!=))/,type:"property"}],identifier:/[A-Za-z_][\w-]*/,heredoc:!0});var qe=o({...d,strings:[{open:'"""',multiline:!0},...y],keywords:"abstract assert break case catch class const continue default do else enum extends final finally for goto if implements import instanceof interface native new package private protected public return static strictfp super switch synchronized this throw throws transient try volatile while var record sealed permits yield",types:"boolean byte char double float int long short void",constants:"true false null",rules:[{match:/@[A-Za-z_]\w*/,type:"meta"}],classNames:!0});var ae="break case catch class const continue debugger default delete do else export extends finally for function if import in instanceof let new return super switch this throw try typeof var void while with yield async await of static get set from as",ie="true false null undefined NaN Infinity",le={open:"`",multiline:!0,interpolate:["${","}"]},ce={match:/(?<=(?:^|[(=?:,&|{}[>;]|\breturn)\s*)<\/?[A-Za-z][\w.:-]*(?=[\s/>]|$)/,type:"tag"},F={match:/(?<=(?:^|[(,=:[!&|?{;]|\breturn|\btypeof|\bcase)\s*)\/(?![*/\s>])(?:\\.|\[(?:\\.|[^\]\\])*\]|[^\\/[])+\/[dgimsuvy]*/,type:"regex"},B={match:/@[A-Za-z_$][\w$.]*/,type:"meta"},H=o({...d,strings:[...y,le],keywords:ae,constants:ie,rules:[ce,F,B],classNames:!0});var W=o({...d,strings:[{open:'"'}],constants:"true false null",rules:[{match:/"(?:[^"\\]|\\.)*"(?=\s*:)/,type:"property"}],calls:!1});var Pe=["${","}"],Fe=o({...d,strings:[{open:'"""',multiline:!0,escape:!1,interpolate:Pe},{open:'"',interpolate:Pe},{open:"'"}],keywords:"package import class interface object fun val var if else when for while do return break continue throw try catch finally is in as typealias this super data sealed enum open abstract override private protected public internal companion lateinit suspend inline reified by init get set where out vararg const operator infix annotation",constants:"true false null",types:"Int Long Short Byte Double Float Boolean Char String Unit Any Nothing List Map Set",rules:[{match:/@[A-Za-z_]\w*(?::\w+)?/,type:"meta"}],classNames:!0});var Be=o({blockComment:[["<!--","-->"]],rules:[{match:/^#{1,6}\s.*/,type:"keyword"},{match:/^ {0,3}(?:`{3,}|~{3,}).*/,type:"meta"},{match:/^\s*>.*/,type:"comment"},{match:/^\s*(?:[-*+]|\d+[.)])(?=\s)/,type:"punctuation"},{match:/^\s*(?:-{3,}|\*{3,}|_{3,})\s*$/,type:"punctuation"},{match:/`[^`]+`/,type:"string"},{match:/!?\[[^\]]*\]\([^)\s]*(?:\s+"[^"]*")?\)/,type:"function"},{match:/\*\*[^*]+\*\*|__[^_]+__/,type:"type"},{match:/(?<![\w*])\*[^*\s][^*]*\*(?!\*)|(?<!\w)_[^_\s][^_]*_(?!\w)/,type:"attr"},{match:/<\/?[A-Za-z][^>]*>/,type:"tag"}],identifier:/[A-Za-z_][\w'-]*/,calls:!1,numbers:!1,operators:!1});var He=o({lineComment:["//","#"],blockComment:[["/*","*/"]],strings:[{open:'"',multiline:!0},{open:"'",multiline:!0}],keywords:"abstract and array as break callable case catch class clone const continue declare default do echo else elseif empty enddeclare endfor endforeach endif endswitch endwhile enum extends final finally fn for foreach function global goto if implements include include_once instanceof insteadof interface isset list match namespace new or print private protected public readonly require require_once return static switch throw trait try unset use var while xor yield",constants:"true false null TRUE FALSE NULL",types:"int float string bool void mixed never object iterable",rules:[{match:/<\?(?:php|=)?|\?>/,type:"meta"},{match:/\$[A-Za-z_]\w*/,type:"variable"}],classNames:!0});var We=o({lineComment:["#"],blockComment:[["<#","#>"]],strings:[{open:'@"',close:'"@',escape:!1,multiline:!0,interpolate:["$(",")"]},{open:"@'",close:"'@",escape:!1,multiline:!0},{open:'"',escape:!1,multiline:!0,interpolate:["$(",")"]},{open:"'",escape:!1,multiline:!0}],keywords:"if else elseif switch foreach for while do until break continue return function filter param begin process end try catch finally throw trap in exit class enum using",caseInsensitive:!0,rules:[{match:/\$(?:true|false|null)\b/i,type:"constant"},{match:/\$(?:\{[^}]+\}|[\w:]+)/,type:"variable"},{match:/-(?:eq|ne|gt|ge|lt|le|like|notlike|match|notmatch|contains|notcontains|in|notin|and|or|not|xor|replace|split|join|is|isnot|as)\b/i,type:"operator"},{match:/\[[A-Za-z][\w.]*(?:\[\])?\]/,type:"type"},{match:/\b[A-Z][a-z]+-[A-Z]\w+/,type:"function"},{match:/(?<=\s)-[A-Za-z]\w*/,type:"attr"}],identifier:/[A-Za-z_][\w-]*/});var en=["f","F","rf","rF","Rf","RF","fr","fR","Fr","FR"].flatMap(e=>['"""',"'''",'"',"'"].map(t=>({open:e+t,close:t,escape:!/r/i.test(e),multiline:t.length===3,interpolate:["{","}"]}))),Ge=o({lineComment:["#"],strings:[...en,{open:'"""',multiline:!0},{open:"'''",multiline:!0},...y],keywords:"and as assert async await break class continue def del elif else except finally for from global if import in is lambda nonlocal not or pass raise return try while with yield match case",constants:"True False None",variables:"self cls",types:"int float str bool list dict set tuple bytes object Exception",rules:[{match:/(?<=^\s*)@[\w.]+/,type:"meta"},{match:/[rRbBuU]{1,2}(?=["'])/,type:"string"}],classNames:!0});var Qe=o({lineComment:["#"],strings:[{open:'"',multiline:!0},{open:"'",multiline:!0}],keywords:"alias and begin break case class def defined? do else elsif end ensure for if in module next not or redo rescue retry return self super then undef unless until when while yield require require_relative include extend attr_accessor attr_reader attr_writer private protected public lambda proc",builtins:"puts print p raise",constants:"true false nil",rules:[{match:/@{1,2}[A-Za-z_]\w*|\$[A-Za-z_]\w*/,type:"variable"},{match:/(?<![:\w]):[A-Za-z_]\w*[?!]?/,type:"constant"}],identifier:/[A-Za-z_]\w*[?!]?/,classNames:!0});var Ve=o({...d,strings:[{open:'"',multiline:!0},{open:"'"}],keywords:"as async await break const continue crate dyn else enum extern fn for if impl in let loop match mod move mut pub ref return self Self static struct super trait type unsafe use where while",constants:"true false None",types:"i8 i16 i32 i64 i128 isize u8 u16 u32 u64 u128 usize f32 f64 bool char str",rules:[{match:/#!?\[[^\]]*\]/,type:"meta"},{match:/'[A-Za-z_]\w*(?!')/,type:"keyword"},{match:/[A-Za-z_]\w*!(?=\s*[([{])/,type:"function"}],classNames:!0});var Ye=o({lineComment:["--"],blockComment:[["/*","*/"]],strings:[{open:"'",escape:!1},{open:'"',escape:!1,type:"property"},{open:"`",escape:!1,type:"property"}],keywords:"select from where and or not insert into values update set delete create table alter drop index primary key foreign references join left right inner outer full cross on as group by order having limit offset union all distinct case when then else end is in like ilike between exists default constraint unique check view begin commit rollback transaction returning with recursive if desc asc add column grant revoke cascade truncate database schema explain using natural over partition window",constants:"null true false",types:"int integer bigint smallint serial bigserial varchar char text boolean bool date time timestamp timestamptz interval decimal numeric float real double precision uuid json jsonb blob bytea",caseInsensitive:!0});var Xe=["\\(",")"],Je=o({...d,strings:[{open:'"""',multiline:!0,interpolate:Xe},{open:'"',interpolate:Xe}],keywords:"import let var func class struct enum protocol extension if else guard switch case default for in while repeat return break continue fallthrough throw throws rethrows try catch do defer as is init deinit self Self super static private fileprivate internal public open final override mutating nonmutating weak unowned lazy inout where async await some any typealias associatedtype subscript convenience required",constants:"true false nil",types:"Int Double Float String Bool Character Array Dictionary Set Void Optional Result Error",rules:[{match:/@[A-Za-z_]\w*/,type:"meta"},{match:/#(?:available|if|else|elseif|endif|selector|keyPath|warning|error)\b/,type:"meta"}],classNames:!0});var Ke=o({lineComment:["#"],strings:[{open:'"""',multiline:!0},{open:"'''",multiline:!0,escape:!1},{open:'"'},{open:"'",escape:!1}],constants:"true false inf nan",rules:[{match:/(?<=^\s*)\[\[?[^\]]*\]\]?/,type:"tag"},{match:/(?<=^\s*)[\w.\-"' ]+?(?=\s*=)/,type:"property"},{match:/\d{4}-\d{2}-\d{2}(?:[T ]\d{2}:\d{2}(?::\d{2}(?:\.\d+)?)?(?:Z|[+-]\d{2}:\d{2})?)?/,type:"number"}],identifier:/[A-Za-z_][\w-]*/,calls:!1});var tn=" interface type enum implements namespace declare abstract readonly private protected public keyof infer is satisfies asserts module override unique",et=e=>({...d,strings:[...y,le],keywords:ae+tn,types:"string number boolean any unknown never void object symbol bigint",constants:ie,rules:e?[ce,F,B]:[F,B],classNames:!0}),tt=o(et(!1)),nt=o(et(!0));var nn=/<(\/?)([A-Za-z][\w:.-]*)/y,rn=/&(?:#\d+|#[xX][\da-fA-F]+|\w+);/y,on=/[^<&]+/y,sn=/[^\s=/>"']+/y,an=/[^\s>"']+/y,ln=/\s+/y,z=(e,t,s)=>(e.lastIndex=s,e.exec(t));function M(e={}){return{tokenizeLine(t,s){let n=new S,a=s,r=0,p;for(;r<t.length;){if(!a){if(t.startsWith("<!--",r)){let l=t.indexOf("-->",r+4);if(l<0){n.add("comment",t.slice(r)),a={m:"comment"};break}n.add("comment",t.slice(r,l+3)),r=l+3}else if(t.startsWith("<!",r)||t.startsWith("<?",r)){let l=t.indexOf(">",r);if(l<0){n.add("meta",t.slice(r)),a={m:"meta"};break}n.add("meta",t.slice(r,l+1)),r=l+1}else(p=z(nn,t,r))?(n.add("punctuation",p[1]?"</":"<"),n.add("tag",p[2]),a={m:"tag",name:p[2].toLowerCase(),closing:!!p[1]},r+=p[0].length):(p=z(rn,t,r))?(n.add("constant",p[0]),r+=p[0].length):(p=z(on,t,r))?(n.add(void 0,p[0]),r+=p[0].length):(n.add(void 0,t[r]),r++);continue}if(a.m==="comment"||a.m==="meta"){let l=a.m==="comment"?"-->":">",h=a.m==="comment"?"comment":"meta",x=t.indexOf(l,r);if(x<0){n.add(h,t.slice(r));break}n.add(h,t.slice(r,x+l.length)),r=x+l.length,a=null;continue}if(a.m==="embed"){let l=t.toLowerCase().indexOf(a.end,r),h=l<0?t.slice(r):t.slice(r,l),x=a.lang.tokenizeLine(h,a.inner);for(let v of x.tokens)n.add(v.type,v.text);if(l<0){a={...a,inner:x.state};break}a=null,r=l;continue}if(a.quote){let l=t.indexOf(a.quote,r);if(l<0){n.add("string",t.slice(r));break}n.add("string",t.slice(r,l+1)),r=l+1,a={...a,quote:void 0,eq:!1}}else if(p=z(ln,t,r))n.add(void 0,p[0]),r+=p[0].length;else if(t.startsWith("/>",r)||t[r]===">"){let l=t[r]===">"?1:2;n.add("punctuation",t.slice(r,r+l)),r+=l;let h=l===1&&!a.closing?e[a.name]:void 0;a=h?{m:"embed",end:`</${a.name}`,lang:h,inner:null}:null}else if(t[r]==="=")n.add("operator","="),r++,a={...a,eq:!0};else if(t[r]==='"'||t[r]==="'"){let l=t[r],h=t.indexOf(l,r+1);if(h<0){n.add("string",t.slice(r)),a={...a,quote:l};break}n.add("string",t.slice(r,h+1)),r=h+1,a={...a,eq:!1}}else a.eq&&(p=z(an,t,r))?(n.add("string",p[0]),r+=p[0].length,a={...a,eq:!1}):(p=z(sn,t,r))?(n.add("attr",p[0]),r+=p[0].length):(n.add(void 0,t[r]),r++)}return{tokens:n.tokens,state:a}}}}var rt=M({script:H,style:P});var ot=o({strings:[{open:'"'},{open:"'",escape:!1}],constants:"true false null yes no on off ~",caseInsensitive:!0,rules:[{match:/(?<=^|\s)#.*/,type:"comment"},{match:/^(?:---|\.\.\.)(?=\s*$)/,type:"meta"},{match:/[^\s#:'"[\]{},-][^#:]*?(?=:(?:\s|$))|(?<=^\s*-\s+)[^\s#:'"[\]{},][^#:]*?(?=:(?:\s|$))/,type:"property"},{match:/[&*][\w-]+/,type:"variable"},{match:/!!?[\w-]+/,type:"type"}],identifier:/[A-Za-z_][\w-]*/,calls:!1});var cn=/^(?:\([\w.-]+\)\s+)?(?:[\w.-]+@[\w.-]+(?::[^\s$#%>]*)?\s?)?[$#%❯>]\s|^PS [^>]*>\s/,pn={tokenizeLine(e,t){let s=t,n=s?.continues?"":cn.exec(e)?.[0];if(n===void 0)return{tokens:e?[{text:e}]:[],state:null};let a=new S;a.add("meta",n);let r=q.tokenizeLine(e.slice(n.length),s?.bash??null);for(let l of r.tokens)a.add(l.type,l.text);let p=/\\$/.test(e)||r.state!==null;return{tokens:a.tokens,state:p?{bash:r.state,continues:!0}:null}}},st=pn;var mn=/^(GET|POST|PUT|PATCH|DELETE|HEAD|OPTIONS|CONNECT|TRACE)(\s+)(\S+)(?:(\s+)(HTTP\/[\d.]+))?\s*$/,un=/^(HTTP\/[\d.]+)(\s+)(\d{3})(.*)$/,fn=/^([!#$%&'*+.^_`|~\w-]+)(:)(\s*)(.*)$/,dn={tokenizeLine(e,t){let s=t??{body:!1,inner:null},n=new S;if(/^###/.test(e))return n.add("comment",e),{tokens:n.tokens,state:null};if(s.body){let r=W.tokenizeLine(e,s.inner);return{tokens:r.tokens,state:{body:!0,inner:r.state}}}if(!e.trim())return{tokens:[],state:{body:!0,inner:null}};let a;return(a=mn.exec(e))?(n.add("keyword",a[1]),n.add(void 0,a[2]),n.add("string",a[3]),a[5]&&(n.add(void 0,a[4]),n.add("meta",a[5]))):(a=un.exec(e))?(n.add("meta",a[1]),n.add(void 0,a[2]),n.add("number",a[3]),n.add("string",a[4])):(a=fn.exec(e))?(n.add("property",a[1]),n.add("punctuation",a[2]),n.add(void 0,a[3]),n.add("string",a[4])):/^\s*#/.test(e)?n.add("comment",e):n.add(void 0,e),{tokens:n.tokens,state:s.inner===null&&!s.body?null:s}}},at=dn;var it=o({lineComment:["//"],blockComment:[["/*","*/"]],strings:y,rules:[{match:/(?<=url\()[^)'"]*(?=\))/,type:"string"},{match:/\$[\w-]+|#\{[^}]*\}/,type:"variable"},{match:/@[\w-]+/,type:"keyword"},{match:/#[\da-fA-F]{3,8}(?![\w-])/,type:"number"},{match:/(?:--|-?[A-Za-z])[\w-]*(?=\s*:(?!:)(?:[^{};#]|#\{[^}]*\}|#(?!\{))*(?:[;})]|$))/,type:"property"},{match:/[.#%][A-Za-z_-][\w-]*/,type:"type"},{match:/&/,type:"operator"},{match:/::?[A-Za-z-]+/,type:"attr"},{match:/!\s*(?:important|default|global)/,type:"keyword"}],identifier:/-?[A-Za-z_][\w-]*/});var lt=o({lineComment:["%%"],strings:[{open:'"'}],keywords:"graph flowchart sequenceDiagram classDiagram stateDiagram erDiagram gantt pie journey gitGraph mindmap timeline quadrantChart requirementDiagram C4Context participant actor note Note over loop alt else opt par and critical break end activate deactivate rect autonumber title section class subgraph direction style classDef linkStyle click accTitle accDescr dateFormat axisFormat commit branch checkout merge state",constants:"TD TB BT RL LR",rules:[{match:/\b(?:stateDiagram-v2|sankey-beta|xychart-beta|block-beta|packet-beta)\b/,type:"keyword"},{match:/<?(?:-{2,}|={2,}|-\.+-?|-)(?:>>?|x|o|\))?(?![\w-])|<<-+/,type:"operator"},{match:/(?<=\w)(?:\[\[|\[\(|\(\(|\[|\(|\{\{|\{|>)[^\]\)\}\n]*?(?:\]\]|\)\]|\)\)|\]|\)|\}\}|\})/,type:"string"},{match:/\|[^|\n]*\|/,type:"string"},{match:/(?<=:\s*)[^:;\n]+$/,type:"string"}],calls:!1});var ct=o({lineComment:["%"],strings:[{open:"$$",multiline:!0,escape:!1},{open:"\\[",close:"\\]",multiline:!0,escape:!1},{open:"\\(",close:"\\)",escape:!1},{open:"$",escape:!1}],rules:[{match:/\\[$%&#_{}]/,type:"constant"},{match:/(?<=\\(?:begin|end)\{)[^}]*/,type:"type"},{match:/\\[A-Za-z@]+\*?/,type:"keyword"},{match:/\\\\/,type:"operator"},{match:/&/,type:"operator"}],calls:!1,numbers:!1,operators:!1});var pt=o({lineComment:["'"],strings:[{open:'"',escape:!1}],keywords:"sub function end if then else elseif for each next do loop while wend until dim as set let private public const option explicit with select case exit call byval byref optional new is not and or xor mod to step resume on error goto property get class module type enum imports namespace inherits implements return try catch finally throw using redim preserve static friend shared overrides overridable handles of in andalso orelse like debug",types:"integer long longlong string boolean double single date variant object byte currency decimal char short range worksheet workbook collection dictionary",constants:"true false nothing null empty vbnullstring vbcrlf vblf vbtab vbnewline vbyes vbno vbokonly",builtins:"msgbox inputbox format len left right mid trim ltrim rtrim ucase lcase replace split join instr cstr cint clng cdbl cbool cdate val isempty isnumeric isnull isarray isobject now date time dateadd datediff year month day ubound lbound array createobject",caseInsensitive:!0,rules:[{match:/(?<=^\s*|:\s*)Rem\b.*/i,type:"comment"},{match:/#\d{1,2}\/\d{1,2}\/\d{2,4}#/,type:"number"},{match:/(?<=^\s*)#(?:If|Else|ElseIf|End If|Const)\b.*/i,type:"meta"},{match:/(?<=^\s*)Attribute\b.*/i,type:"meta"},{match:/\s_$/,type:"operator"}]});var mt=o({lineComment:["--"],blockComment:[["--[[","]]"]],strings:[{open:"[[",close:"]]",escape:!1,multiline:!0},{open:'"'},{open:"'"}],keywords:"and break do else elseif end for function goto if in local not or repeat return then until while",constants:"true false nil",builtins:"print pairs ipairs require type tostring tonumber assert error pcall setmetatable getmetatable select next"});var G=["${","}"],ut=o({...d,strings:[{open:"r'''",close:"'''",escape:!1,multiline:!0},{open:'r"""',close:'"""',escape:!1,multiline:!0},{open:"'''",multiline:!0,interpolate:G},{open:'"""',multiline:!0,interpolate:G},{open:"r'",close:"'",escape:!1},{open:'r"',close:'"',escape:!1},{open:"'",interpolate:G},{open:'"',interpolate:G}],keywords:"abstract as assert async await base break case catch class const continue covariant default deferred do dynamic else enum export extends extension external factory final finally for get hide if implements import in interface is late library mixin new on operator part required rethrow return sealed set show static super switch sync this throw try typedef var when while with yield",constants:"true false null",types:"int double num bool String List Map Set Future Stream void Object Never Iterable Function",rules:[{match:/@[A-Za-z_]\w*/,type:"meta"}],classNames:!0});var ft=["#{","}"],dt=o({lineComment:["#"],strings:[{open:'"""',multiline:!0,interpolate:ft},{open:'"',interpolate:ft},{open:"'"}],keywords:"def defp defmodule defmacro defmacrop defstruct defprotocol defimpl defdelegate defguard do end fn case cond with when if else unless import alias use require quote unquote receive after try catch rescue raise and or not in for",constants:"true false nil",rules:[{match:/@[a-z_]\w*/,type:"meta"},{match:/(?<![:\w]):[A-Za-z_]\w*[?!]?/,type:"constant"},{match:/\b[a-z_]\w*[?!]?:(?=\s)/,type:"constant"},{match:/~[a-zA-Z](?:"[^"]*"|\/[^/]*\/|\([^)]*\)|\[[^\]]*\]|\{[^}]*\})[a-z]*/,type:"regex"}],identifier:/[A-Za-z_]\w*[?!]?/,classNames:!0});var gt=o({lineComment:["#"],strings:[...y,{open:"`",escape:!1,type:"variable"}],keywords:"function if else for while repeat in next break return",constants:"TRUE FALSE NULL NA NA_integer_ NA_real_ NA_character_ Inf NaN T F",rules:[{match:/<<-|->>|<-|->|%[^%\s]*%|\|>/,type:"operator"}],identifier:/[A-Za-z_.][\w.]*/});var ht=o({lineComment:["//"],strings:[{open:'"'},{open:"'"}],keywords:"const var fn pub return if else while for switch struct enum union opaque error try catch defer errdefer comptime inline export extern test and or orelse unreachable break continue noreturn align packed threadlocal usingnamespace async await suspend resume nosuspend asm volatile allowzero callconv linksection noalias",constants:"true false null undefined",types:"i8 i16 i32 i64 i128 isize u8 u16 u32 u64 u128 usize f16 f32 f64 f128 bool void anyerror anytype anyopaque type comptime_int comptime_float c_int c_uint",rules:[{match:/\\\\.*/,type:"string"},{match:/@[A-Za-z_]\w*/,type:"function"}],classNames:!0});var yt=["${","}"],gn=["s","f","raw"].flatMap(e=>[{open:`${e}"""`,close:'"""',multiline:!0,escape:!1,interpolate:yt},{open:`${e}"`,close:'"',escape:e!=="raw",interpolate:yt}]),bt=o({...d,strings:[...gn,{open:'"""',multiline:!0,escape:!1},{open:'"'},{open:"'"}],keywords:"abstract case catch class def do else enum export extends final finally for forSome given if implicit import lazy match new object override package private protected return sealed super then this throw trait try type using val var while with yield end",constants:"true false null",types:"Int Long Double Float Boolean String Unit Any AnyRef Nothing Option Some None List Map Seq Vector Future",rules:[{match:/@[A-Za-z_]\w*/,type:"meta"}],classNames:!0});var wt=o({lineComment:["--"],blockComment:[["{-","-}"]],strings:[{open:'"'}],keywords:"module where import qualified as hiding data type newtype class instance deriving let in case of if then else do forall infixl infixr infix family default",constants:"True False Nothing Just Left Right",rules:[{match:/'(?:[^'\\]|\\.)'/,type:"string"},{match:/(?<=^)[a-z_][\w']*(?=\s*::)/,type:"function"}],identifier:/[A-Za-z_][\w']*/,calls:!1,classNames:!0});var xt=["$(",")"],kt=o({lineComment:["#"],blockComment:[["#=","=#"]],strings:[{open:'"""',multiline:!0,interpolate:xt},{open:'"',interpolate:xt},{open:"`",type:"string"}],keywords:"function end if elseif else for while return module baremodule using import export struct mutable abstract primitive type begin let do try catch finally macro quote local global const where in isa break continue",constants:"true false nothing missing NaN Inf pi",types:"Int Int8 Int16 Int32 Int64 UInt8 Float32 Float64 Bool String Char Vector Matrix Array Dict Tuple Any Nothing",rules:[{match:/@[A-Za-z_]\w*/,type:"meta"},{match:/'(?:[^'\\]|\\.)'/,type:"string"}],identifier:/[A-Za-z_]\w*!?/,classNames:!0});var Lt=o({lineComment:["#"],strings:[{open:'"'},{open:"'"}],constants:"on off",rules:[{match:/(?<=^\s*)(?:http|server|location|upstream|events|stream|map|if|include|types|geo|split_clients|limit_except)\b/,type:"keyword"},{match:/\$[A-Za-z_]\w*/,type:"variable"},{match:/(?<=^\s*)(?!(?:http|server|location|upstream|events|stream|map|if|include|types|geo|split_clients|limit_except)\b)[a-z_]\w*(?=\s)(?!\s*\{)/,type:"property"},{match:/(?<=location\s+)(?:[=~^*]+\s*)?[^\s{]+/,type:"string"}],identifier:/[A-Za-z_][\w.-]*/,calls:!1});var vt=o({strings:[{open:'"'},{open:"'",escape:!1}],keywords:"include ifeq ifneq ifdef ifndef else endif define endef export unexport override vpath",rules:[{match:/(?<=^|\s)#.*/,type:"comment"},{match:/\$[({][^)}]*[)}]|\$[@<^?*%+]/,type:"variable"},{match:/^(?:\.PHONY|[\w./%${}()-]+(?:\s+[\w./%${}()-]+)*)(?=\s*::?(?!=))/,type:"function"},{match:/^[A-Za-z_][\w.-]*(?=\s*(?:[:?+!]?=))/,type:"property"}],identifier:/[A-Za-z_][\w-]*/,calls:!1});var Et=o({strings:[{open:'"'},{open:"'",escape:!1}],constants:"true false yes no on off",caseInsensitive:!0,rules:[{match:/(?<=^\s*)[;#].*/,type:"comment"},{match:/(?<=^\s*)\[[^\]]*\]/,type:"tag"},{match:/(?<=^\s*)(?:export\s+)?[^\s=:;#[][^=:]*?(?=\s*[=:])/,type:"property"},{match:/\$\{[^}]*\}|\$[A-Za-z_]\w*/,type:"variable"}],identifier:/[A-Za-z_][\w.-]*/,calls:!1});var _t=o({...d,strings:y,keywords:"syntax edition package import public weak message enum service rpc returns option repeated optional required oneof map reserved extensions extend stream to max",types:"double float int32 int64 uint32 uint64 sint32 sint64 fixed32 fixed64 sfixed32 sfixed64 bool string bytes",constants:"true false",calls:!1,classNames:!0});var At=o({...d,strings:y,keywords:"pragma solidity contract interface library abstract function modifier event emit error returns return if else for while do break continue public private internal external view pure payable memory storage calldata constant immutable override virtual mapping struct enum require revert assert using import is new delete try catch unchecked constructor fallback receive anonymous indexed",types:"address bool string bytes byte int uint uint8 uint16 uint32 uint64 uint128 uint256 int8 int16 int32 int64 int128 int256 bytes1 bytes4 bytes8 bytes16 bytes32",constants:"true false wei gwei ether seconds minutes hours days weeks",rules:[{match:/\b(?:msg|block|tx|abi)\.\w+/,type:"variable"}],classNames:!0});var St=["${","}"],Ct=o({...d,strings:[{open:'"""',multiline:!0,interpolate:St},{open:"'''",multiline:!0},{open:'"',interpolate:St},{open:"'"}],keywords:"def var class interface enum trait import package return if else for while do switch case default break continue new in as instanceof try catch finally throw throws static final abstract private protected public assert extends implements this super",constants:"true false null",types:"int long double float boolean char byte short void String Object List Map",rules:[{match:/@[A-Za-z_]\w*/,type:"meta"}],classNames:!0});var Tt=["${","}"],Ot=o({lineComment:["#"],blockComment:[["/*","*/"]],strings:[{open:"''",multiline:!0,escape:!1,interpolate:Tt},{open:'"',multiline:!0,interpolate:Tt}],keywords:"let in with rec inherit if then else assert or",constants:"true false null",builtins:"import builtins derivation fetchurl fetchTarball fetchGit toString map throw abort",rules:[{match:/[A-Za-z_][\w'-]*(?:\.[A-Za-z_][\w'-]*)*(?=\s*=(?!=))/,type:"property"},{match:/(?:\.{0,2}\/|~\/)[\w./-]+|<[\w./-]+>/,type:"string"}],identifier:/[A-Za-z_][\w'-]*/,calls:!1});var Nt=o({lineComment:["#"],blockComment:[["#[[","]]"]],strings:[{open:'"',multiline:!0}],keywords:"if elseif else endif foreach endforeach while endwhile function endfunction macro endmacro return break continue",caseInsensitive:!0,rules:[{match:/\$\{[^}]*\}|\$ENV\{[^}]*\}/,type:"variable"},{match:/\b[A-Z][A-Z0-9_]{1,}\b/,type:"constant"}]});var zt=o({lineComment:["//"],strings:[{open:'"'}],keywords:"model enum datasource generator type view",types:"String Int BigInt Float Decimal Boolean DateTime Json Bytes Unsupported",constants:"true false null",rules:[{match:/@@?[A-Za-z_][\w.]*/,type:"meta"},{match:/(?<=^\s*)(?!(?:model|enum|datasource|generator|type|view)\b)[a-z_]\w*(?=\s+[A-Za-z])/,type:"property"},{match:/(?<=^\s*)[a-z_]\w*(?=\s*=)/,type:"property"}],classNames:!0});var Rt={javascript:H,typescript:tt,tsx:nt,json:W,python:Ge,bash:q,ruby:Qe,php:He,go:je,rust:Ve,java:qe,c:Re,cpp:De,csharp:$e,sql:Ye,css:P,yaml:ot,xml:rt,diff:Me,kotlin:Fe,swift:Je,dockerfile:Ze,toml:Ke,markdown:Be,graphql:Ie,powershell:We,hcl:Ue,lua:mt,dart:ut,elixir:dt,r:gt,zig:ht,scala:bt,haskell:wt,julia:kt,nginx:Lt,makefile:vt,ini:Et,protobuf:_t,solidity:At,groovy:Ct,nix:Ot,cmake:Nt,prisma:zt,shellsession:st,http:at,scss:it,mermaid:lt,latex:ct,vba:pt,plaintext:U};var Q=new Map(Object.entries(Rt)),Dt=new Map(Object.entries({js:"javascript",jsx:"javascript",mjs:"javascript",cjs:"javascript",node:"javascript",ts:"typescript",mts:"typescript",cts:"typescript",jsonc:"json",json5:"json",py:"python",python3:"python",sh:"bash",shell:"bash",zsh:"bash",shellscript:"bash",rb:"ruby",golang:"go",rs:"rust",h:"c","c++":"cpp",cc:"cpp",cxx:"cpp",hpp:"cpp",cs:"csharp","c#":"csharp",postgres:"sql",postgresql:"sql",mysql:"sql",sqlite:"sql",plsql:"sql",yml:"yaml",html:"xml",xhtml:"xml",svg:"xml",vue:"xml",svelte:"xml",patch:"diff",kt:"kotlin",kts:"kotlin",docker:"dockerfile",containerfile:"dockerfile",md:"markdown",mdx:"markdown",gql:"graphql",ps1:"powershell",pwsh:"powershell",ps:"powershell",terraform:"hcl",tf:"hcl",tfvars:"hcl",opentofu:"hcl",luau:"lua",ex:"elixir",exs:"elixir",heex:"elixir",rscript:"r",jl:"julia",sc:"scala",hs:"haskell",lhs:"haskell","nginx.conf":"nginx",make:"makefile",mk:"makefile",mak:"makefile",gnumakefile:"makefile",cfg:"ini",properties:"ini",env:"ini",dotenv:"ini",editorconfig:"ini",gitconfig:"ini",proto:"protobuf",proto3:"protobuf",sol:"solidity",gradle:"groovy",gvy:"groovy",jenkinsfile:"groovy",cmakelists:"cmake","cmakelists.txt":"cmake",console:"shellsession",terminal:"shellsession","shell-session":"shellsession","sh-session":"shellsession",pwshsession:"shellsession",https:"http",rest:"http","rest-client":"http",sass:"scss",less:"scss",mmd:"mermaid",tex:"latex",context:"latex",vb:"vba",vbnet:"vba","vb.net":"vba",vbscript:"vba",vbs:"vba","visual-basic":"vba",visualbasic:"vba",text:"plaintext",txt:"plaintext",plain:"plaintext","":"plaintext"}));function T(e){let t=(e??"").trim().toLowerCase();return Q.get(t)??Q.get(Dt.get(t)??"")}function V(e,t,s=[]){Q.set(e.toLowerCase(),t);for(let n of s)Dt.set(n.toLowerCase(),e.toLowerCase())}function Y(){return[...Q.keys()]}var pe=V,me=Y;var ue;function fe(e){ue=e}function _(e,t={}){return ue?ue(e,t,T):{lang:"plaintext",confidence:0}}function X(e){let t=new Set;if(e==null)return t;if(typeof e=="number")return t.add(e);if(Array.isArray(e))return new Set(e);for(let s of e.split(/[\s,]+/)){let n=/^(\d+)(?:-(\d+))?$/.exec(s);if(!n)continue;let a=Number(n[1]),r=Number(n[2]??n[1]);for(let p=Math.min(a,r);p<=Math.max(a,r)&&p-a<1e5;p++)t.add(p)}return t}var $t=e=>!!e&&(!!e.lineNumbers||e.highlightLines!=null);function de(e,t,s){return"cl-line"+(t?" cl-ln":"")+(s.has(e)?" cl-mark":"")}function Mt(e,t,s,n){return`<span class="${de(t,s,n)}" data-line="${t}">${e}</span>`}var Zt=e=>typeof e=="object"?e:T(e)??U,hn={"&":"&","<":"<",">":">",'"':"""};function Z(e){return e.replace(/[&<>"]/g,t=>hn[t])}function O(e){let t="";for(let s of e)t+=s.type?`<span class="cl-${s.type}">${Z(s.text)}</span>`:Z(s.text);return t}var yn=e=>typeof e=="string"&&e.trim().toLowerCase()==="auto";function J(e,t){let s=Zt(yn(t)?_(e).lang:t),n=null;return e.split(`
`).map(a=>{let r=s.tokenizeLine(a.replace(/\r$/,""),n);return n=r.state,r.tokens})}function ge(e,t={}){let{lang:s,confidence:n}=_(e,t);return{lang:s,html:R(e,s,t),confidence:n}}function R(e,t,s){let n=J(e,t).map(O);if(!$t(s))return n.join(`
`);let a=X(s.highlightLines);return n.map((r,p)=>Mt(r,p+1,!!s.lineNumbers,a)).join(`
`)}function j(e){let t=Zt(e),s=null,n="",a="";return{get text(){return a},push(r){a+=r,n+=r;let p=[],l;for(;(l=n.indexOf(`
`))>=0;){let h=t.tokenizeLine(n.slice(0,l).replace(/\r$/,""),s);p.push(h.tokens),s=h.state,n=n.slice(l+1)}return{lines:p,tail:t.tokenizeLine(n.replace(/\r$/,""),s).tokens}}}}var jt=/(?:^|\s)lang(?:uage)?-(\S+)/,It=/(?:^|\s)(?:no-?highlight|lang(?:uage)?-none)(?:\s|$)/,he=(e,t)=>e.getAttribute(t)??e.parentElement?.getAttribute(t)??null,bn=e=>he(e,"data-lang")??jt.exec(e.className)?.[1]??jt.exec(e.parentElement?.className??"")?.[1]??"",wn=e=>It.test(e.className)||It.test(e.parentElement?.className??"");function ye(e,t){if(wn(e))return;let s=e.textContent??"",n=t.lang??bn(e);(n.toLowerCase()==="auto"||!n&&t.detect!==!1)&&(n=_(s).lang,n==="plaintext"&&(n=""));let a=t.lineNumbers??he(e,"data-line-numbers")!=null,r=t.highlightLines??he(e,"data-highlight-lines")??void 0;e.innerHTML=R(s,n,{lineNumbers:a,highlightLines:r}),e.classList.add("cl"),e.setAttribute("data-cl",n),t.copyButton&&D(e)}var xn=e=>!!e&&typeof e.querySelectorAll=="function";function K(e,t={}){let s=xn(e)?e:void 0,n=s?t:{...e,...t};if(s&&s.tagName==="CODE")return ye(s,n);if(!s&&typeof document>"u")return;let a=()=>{for(let r of(s??document).querySelectorAll("pre > code:not([data-cl])"))ye(r,n)};!s&&document.readyState==="loading"?document.addEventListener("DOMContentLoaded",a,{once:!0}):a()}function be(e,t){K(e,t)}function we(e,t,s={}){ye(e,t===void 0?s:{...s,lang:t})}var kn=20,Ln=2e3;function xe(e,t={}){let s=e.ownerDocument,n=!!t.lineNumbers,a=X(t.highlightLines),r,p=!1,l,h,x,v=0,L=(c,f)=>{c.className=de(f,n,a),(n||a.size)&&c.setAttribute("data-line",String(f))},A=()=>{e.setAttribute("data-cl",l??""),h=j(l),v=0,x=s.createElement("span"),L(x,1),e.replaceChildren(x)},E=c=>{r=c,p=c?.trim().toLowerCase()==="auto",l=p?"plaintext":c,A()},i=()=>{let c=h.text,f=v,C=_(c).lang;C==="plaintext"&&f<kn&&c.length<Ln||(p=!1,C!=="plaintext"&&(l=C,A(),k.write(c)))};e.classList.add("cl"),E(t.lang);let k={get text(){return h.text},get lang(){return l},write(c){if(!c)return;let{lines:f,tail:C}=h.push(c);if(f.length){let N=s.createDocumentFragment();for(let m of f){let g=s.createElement("span");L(g,++v),g.innerHTML=O(m),N.append(g,`
`)}e.insertBefore(N,x),L(x,v+1)}x.innerHTML=O(C),p&&f.length&&i()},set(c){let f=h.text;if(c!==f){if(c.startsWith(f))return k.write(c.slice(f.length));E(r),k.write(c)}},reset(c){E(c===void 0?r:c)}};return k}var vn=/^ {0,3}(`{3,}|~{3,})(.*)$/,Ut=/^ {0,3}(?:`{1,2}|~{1,2})$/;function ke(e){let t=e.split(`
`),s=[],n=[],a=()=>{n.length&&s.push({type:"text",text:n.join(`
`)}),n=[]},r=0;for(;r<t.length;){let p=t[r].replace(/\r$/,""),l=vn.exec(p);if(!l||l[1][0]==="`"&&l[2].includes("`")){n.push(p),r++;continue}a();let h=l[1],x=r<t.length-1,v=new RegExp(`^ {0,3}${h[0]==="`"?"`":"~"}{${h.length},}\\s*$`),L=[],A=!1,E=r+1;for(;E<t.length;E++){let k=t[E].replace(/\r$/,"");if(v.test(k)){A=!0;break}L.push(k)}let i;A?i=L.map(k=>k+`
`).join(""):(L.length&&Ut.test(L[L.length-1])&&(L[L.length-1]=""),i=L.join(`
`)),s.push({type:"code",lang:x?l[2].trim().split(/\s+/)[0]??"":"",code:i,closed:A}),r=A?E+1:E}return n.length&&Ut.test(n[n.length-1])&&n.pop(),a(),s}var ee=`/*!
codelight.js theme: default
Light or dark to match the system. To force one, put a cl-light or cl-dark class
(or light / dark, or data-theme="light" / "dark") on the code or any parent.
*/.cl,.cl-copy{--cl-fg: #1e2430;--cl-bg: #f7f7f9;--cl-keyword: #b4235a;--cl-string: #1d6b45;--cl-regex: #0b6477;--cl-comment: #656c79;--cl-number: #a35200;--cl-function: #3a52c4;--cl-type: #8a3ab9;--cl-constant: #a35200;--cl-variable: #9a3f0c;--cl-property: #1f6f9a;--cl-operator: #b4235a;--cl-punctuation: #4b5563;--cl-tag: #2459a8;--cl-attr: #8a3ab9;--cl-meta: #6b4fbb;--cl-inserted: #166534;--cl-inserted-bg: #dcfce7;--cl-deleted: #9f1239;--cl-deleted-bg: #ffe4e6;--cl-line-number: #656c79;--cl-mark-bg: #fdf6e1;--cl-border: #d5d9e0}.cl{color:var(--cl-fg);background:var(--cl-bg)}@media(prefers-color-scheme:dark){.cl,.cl-copy{--cl-fg: #e4e7ee;--cl-bg: #11141a;--cl-keyword: #ff7aa8;--cl-string: #8fdba8;--cl-regex: #67e3f2;--cl-comment: #8a93a3;--cl-number: #ffb86b;--cl-function: #8fb4ff;--cl-type: #d0a3ff;--cl-constant: #ffb86b;--cl-variable: #ffa070;--cl-property: #7fd0f0;--cl-operator: #ff7aa8;--cl-punctuation: #aab1bd;--cl-tag: #8fb4ff;--cl-attr: #d0a3ff;--cl-meta: #b49cff;--cl-inserted: #a7f3c0;--cl-inserted-bg: #0f3a24;--cl-deleted: #fecdd3;--cl-deleted-bg: #4c1020;--cl-line-number: #8a93a3;--cl-mark-bg: #262116;--cl-border: #2e3440}}.cl-dark .cl,.cl.cl-dark,.dark .cl,[data-theme=dark] .cl,.cl-dark .cl-copy,.dark .cl-copy,[data-theme=dark] .cl-copy{--cl-fg: #e4e7ee;--cl-bg: #11141a;--cl-keyword: #ff7aa8;--cl-string: #8fdba8;--cl-regex: #67e3f2;--cl-comment: #8a93a3;--cl-number: #ffb86b;--cl-function: #8fb4ff;--cl-type: #d0a3ff;--cl-constant: #ffb86b;--cl-variable: #ffa070;--cl-property: #7fd0f0;--cl-operator: #ff7aa8;--cl-punctuation: #aab1bd;--cl-tag: #8fb4ff;--cl-attr: #d0a3ff;--cl-meta: #b49cff;--cl-inserted: #a7f3c0;--cl-inserted-bg: #0f3a24;--cl-deleted: #fecdd3;--cl-deleted-bg: #4c1020;--cl-line-number: #8a93a3;--cl-mark-bg: #262116;--cl-border: #2e3440}.cl-light .cl,.cl.cl-light,.light .cl,[data-theme=light] .cl,.cl-light .cl-copy,.light .cl-copy,[data-theme=light] .cl-copy{--cl-fg: #1e2430;--cl-bg: #f7f7f9;--cl-keyword: #b4235a;--cl-string: #1d6b45;--cl-regex: #0b6477;--cl-comment: #656c79;--cl-number: #a35200;--cl-function: #3a52c4;--cl-type: #8a3ab9;--cl-constant: #a35200;--cl-variable: #9a3f0c;--cl-property: #1f6f9a;--cl-operator: #b4235a;--cl-punctuation: #4b5563;--cl-tag: #2459a8;--cl-attr: #8a3ab9;--cl-meta: #6b4fbb;--cl-inserted: #166534;--cl-inserted-bg: #dcfce7;--cl-deleted: #9f1239;--cl-deleted-bg: #ffe4e6;--cl-line-number: #656c79;--cl-mark-bg: #fdf6e1;--cl-border: #d5d9e0}pre>code.cl{display:block;padding:1rem 1.25rem;overflow:auto}.cl-keyword{color:var(--cl-keyword)}.cl-string{color:var(--cl-string)}.cl-regex{color:var(--cl-regex)}.cl-comment{color:var(--cl-comment)}.cl-number{color:var(--cl-number)}.cl-function{color:var(--cl-function)}.cl-type{color:var(--cl-type)}.cl-constant{color:var(--cl-constant)}.cl-variable{color:var(--cl-variable)}.cl-property{color:var(--cl-property)}.cl-operator{color:var(--cl-operator)}.cl-punctuation{color:var(--cl-punctuation)}.cl-tag{color:var(--cl-tag)}.cl-attr{color:var(--cl-attr)}.cl-meta{color:var(--cl-meta)}.cl-comment{font-style:italic}.cl-inserted{color:var(--cl-inserted);background:var(--cl-inserted-bg)}.cl-deleted{color:var(--cl-deleted);background:var(--cl-deleted-bg)}.cl-ln:before{content:attr(data-line);display:inline-block;min-width:var(--cl-gutter, 2.5ch);margin-right:1.25em;text-align:right;color:var(--cl-line-number);font-style:normal;user-select:none;-webkit-user-select:none}.cl-mark{display:inline-block;min-width:100%;min-height:1lh;background:var(--cl-mark-bg)}.cl-has-copy{position:relative}.cl-copy{position:absolute;top:.5rem;right:.5rem;padding:.2rem .65rem;font:500 12px/1.5 system-ui,-apple-system,Segoe UI,sans-serif;color:var(--cl-fg);background:var(--cl-bg);border:1px solid var(--cl-border);border-radius:6px;cursor:pointer;opacity:.8}.cl-copy:hover,.cl-copy:focus-visible{opacity:1}
`;function Le(e=document){if(e.getElementById("codelight-theme"))return;let t=e.createElement("style");t.id="codelight-theme",t.textContent=ee,e.head.append(t)}var En={addCopyButton:D,addLanguage:V,createMarkup:M,createStream:j,defineLanguage:o,detectLanguage:_,setDetector:fe,escapeHtml:Z,getLanguage:T,highlight:R,injectTheme:Le,languages:Y,lightUp:K,mount:xe,renderLine:O,splitFences:ke,themeCss:ee,tokenize:J,highlightAll:be,highlightAuto:ge,highlightElement:we,listLanguages:me,registerLanguage:pe},_n=En;return Gt(An);})();
/*!
codelight.js — syntax highlighting that keeps up with live code.
MIT License · https://github.com/codelightjs/codelight.js
*/