!function(e,t){"object"==typeofexports&&"undefined"!=typeofmodule?module.exports=t():"function"==typeofdefine&&define.amd?define(t):(e="undefined"!=typeofglobalThis?globalThis:e||self).RevealHighlight=t()}(this,(function(){"use strict";vare={exports:{}};functiont(e){returneinstanceofMap?e.clear=e.delete=e.set=function(){thrownewError("map is read-only")}:einstanceofSet&&(e.add=e.clear=e.delete=function(){thrownewError("set is read-only")}),Object.freeze(e),Object.getOwnPropertyNames(e).forEach((function(a){varn=e[a];"object"!=typeofn||Object.isFrozen(n)||t(n)})),e}e.exports=t,e.exports.default=t;classa{constructor(e){void0===e.data&&(e.data={}),this.data=e.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}functionn(e){returne.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}functionr(e,...t){consta=Object.create(null);for(consttine)a[t]=e[t];returnt.forEach((function(e){for(consttine)a[t]=e[t]})),a}consti=e=>!!e.scope||e.sublanguage&&e.language;classo{constructor(e,t){this.buffer="",this.classPrefix=t.classPrefix,e.walk(this)}addText(e){this.buffer+=n(e)}openNode(e){if(!i(e))return;lett="";t=e.sublanguage?`language-${e.language}`:((e,{prefix:t})=>{if(e.includes(".")){consta=e.split(".");return[`${t}${a.shift()}`,...a.map(((e,t)=>`${e}${"_".repeat(t+1)}`))].join(" ")}return`${t}${e}`})(e.scope,{prefix:this.classPrefix}),this.span(t)}closeNode(e){i(e)&&(this.buffer+="</span>")}value(){returnthis.buffer}span(e){this.buffer+=`<span class="${e}">`}}consts=(e={})=>{constt={children:[]};returnObject.assign(t,e),t};classl{constructor(){this.rootNode=s(),this.stack=[this.rootNode]}gettop(){returnthis.stack[this.stack.length-1]}getroot(){returnthis.rootNode}add(e){this.top.children.push(e)}openNode(e){constt=s({scope:e});this.add(t),this.stack.push(t)}closeNode(){if(this.stack.length>1)returnthis.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){returnJSON.stringify(this.rootNode,null,4)}walk(e){returnthis.constructor._walk(e,this.rootNode)}static_walk(e,t){return"string"==typeoft?e.addText(t):t.children&&(e.openNode(t),t.children.forEach((t=>this._walk(e,t))),e.closeNode(t)),e}static_collapse(e){"string"!=typeofe&&e.children&&(e.children.every((e=>"string"==typeofe))?e.children=[e.children.join("")]:e.children.forEach((e=>{l._collapse(e)})))}}classcextendsl{constructor(e){super(),this.options=e}addKeyword(e,t){""!==e&&(this.openNode(t),this.addText(e),this.closeNode())}addText(e){""!==e&&this.add(e)}addSublanguage(e,t){consta=e.root;a.sublanguage=!0,a.language=t,this.add(a)}toHTML(){returnnewo(this,this.options).value()}finalize(){return!0}}function_(e){returne?"string"==typeofe?e:e.source:null}functiond(e){returnu("(?=",e,")")}functionm(e){returnu("(?:",e,")*")}functionp(e){returnu("(?:",e,")?")}functionu(...e){returne.map((e=>_(e))).join("")}functiong(...e){constt=function(e){constt=e[e.length-1];return"object"==typeoft&&t.constructor===Object?(e.splice(e.length-1,1),t):{}}(e);return"("+(t.capture?"":"?:")+e.map((e=>_(e))).join("|")+")"}functionE(e){returnnewRegExp(e.toString()+"|").exec("").length-1}constS=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;functionb(e,{joinWith:t}){leta=0;returne.map((e=>{a+=1;constt=a;letn=_(e),r="";for(;n.length>0;){conste=S.exec(n);if(!e){r+=n;break}r+=n.substring(0,e.index),n=n.substring(e.index+e[0].length),"\\"===e[0][0]&&e[1]?r+="\\"+String(Number(e[1])+t):(r+=e[0],"("===e[0]&&a++)}returnr})).map((e=>`(${e})`)).join(t)}constT="[a-zA-Z]\\w*",f="[a-zA-Z_]\\w*",C="\\b\\d+(\\.\\d+)?",N="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",R="\\b(0b[01]+)",O={begin:"\\\\[\\s\\S]",relevance:0},h={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[O]},v={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[O]},I=function(e,t,a={}){constn=r({scope:"comment",begin:e,end:t,contains:[]},a);n.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE