@bull-board/ui 6.3.3 → 6.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.ejs +2 -2
- package/dist/static/css/{main.3abb51c2.css → main.c61c9456.css} +1 -1
- package/dist/static/js/33563.2599da75.js +12 -0
- package/dist/static/js/async/13346.1513cc1d.js +56 -0
- package/dist/static/js/async/{23080.8c84a1ef.js → 23080.3015db34.js} +1 -1
- package/dist/static/js/async/{26335.24d897e6.js → 26335.a53c8597.js} +1 -1
- package/dist/static/js/async/{44067.bcfbd2a5.js → 44067.d8391376.js} +1 -1
- package/dist/static/js/async/{4670.08cf1776.js → 4670.0073175f.js} +1 -1
- package/dist/static/js/async/{60290.7637c675.js → 60290.850b01b0.js} +1 -1
- package/dist/static/js/async/{81191.06985ac9.js → 81191.cd6b0529.js} +1 -1
- package/dist/static/js/async/85093.e6beee20.js +1 -0
- package/dist/static/js/async/{87586.5c49a27b.js → 87586.db222558.js} +1 -1
- package/dist/static/js/async/97241.b7a68e55.js +1 -0
- package/dist/static/js/async/highlight-worker.7c03aa62.js +1 -0
- package/dist/static/js/{main.107861fd.js → main.570c71df.js} +2 -2
- package/package.json +3 -2
- package/dist/static/js/83544.ce1e4ea9.js +0 -2
- package/dist/static/js/async/20306.ce0432cb.js +0 -56
- package/dist/static/js/async/85093.c2351775.js +0 -1
- package/dist/static/js/async/97241.b8133980.js +0 -1
- package/dist/static/js/async/highlight-worker.e0105321.js +0 -1
- /package/dist/static/css/async/{23080.67780f94.css → 23080.aa9b41ef.css} +0 -0
- /package/dist/static/css/async/{26335.593132bd.css → 26335.b79fa8db.css} +0 -0
- /package/dist/static/css/async/{4670.812ee089.css → 4670.244365ec.css} +0 -0
- /package/dist/static/css/async/{70021.f7e7c024.css → 70021.27a7840f.css} +0 -0
- /package/dist/static/css/async/{97241.a605b410.css → 97241.4c91059a.css} +0 -0
- /package/dist/static/js/{83544.ce1e4ea9.js.LICENSE.txt → 33563.2599da75.js.LICENSE.txt} +0 -0
- /package/dist/static/js/async/{20306.ce0432cb.js.LICENSE.txt → 13346.1513cc1d.js.LICENSE.txt} +0 -0
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
/*! For license information please see 20306.ce0432cb.js.LICENSE.txt */
|
|
2
|
-
(self.webpackChunk_bull_board_ui=self.webpackChunk_bull_board_ui||[]).push([["20306"],{67142:function(e){var t,n;t="undefined"!=typeof self&&self,n=()=>(()=>{"use strict";var e={d:(t,n)=>{for(var r in n)e.o(n,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:n[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};function n(e){return"#"===e||""===e||Array.isArray(e)&&0===e.length||!1}e.r(t),e.d(t,{default:()=>A,get:()=>h,isRoot:()=>n,join:()=>w,remove:()=>g,removeUndefinedItems:()=>m,set:()=>d,split:()=>u,splitLast:()=>D});let r=/~1/g,i=/~0/g,s=/\/+/g,o=/(^[#/]*|\/+$)/g;function l(e){return e.replace(r,"/").replace(i,"~")}function a(e){return l(decodeURIComponent(e))}function u(e){if(null==e||"string"!=typeof e||n(e))return Array.isArray(e)?e:[];let t=e.indexOf("#")>=0?a:l,r=(e=(e=e.replace(s,"/")).replace(o,"")).split("/");for(let e=0,n=r.length;e<n;e+=1)r[e]=t(r[e]);return r}function h(e,t,r){if(null==t||null==e)return r;if(n(t))return e;let i=function e(t,n){let r=n.shift();if(void 0!==t)return void 0!==r?e(t[r],n):t}(e,u(t));return void 0===i?r:i}let c=/^\[.*\]$/,f=/^\[(.+)\]$/;function d(e,t,n){if(null==t)return e;let r=u(t);if(0===r.length)return e;null==e&&(e=c.test(r[0])?[]:{});let i,s,o=e;for(;r.length>1;){var l,a;i=r.shift(),s=c.test(r[0]),l=i,a=r,"__proto__"===l||"constructor"==l&&a.length>0&&"prototype"==a[0]||(o=function(e,t,n){if(null!=e[t])return e[t];let r=n?[]:{};return p(e,t,r),r}(o,i,s))}return p(o,i=r.pop(),n),e}function p(e,t,n){let r=t.match(f);"[]"===t&&Array.isArray(e)?e.push(n):r?e[r.pop()]=n:e[t]=n}function m(e){let t=0,n=0;for(;t+n<e.length;)void 0===e[t+n]&&(n+=1),e[t]=e[t+n],t+=1;return e.length=e.length-n,e}function g(e,t,n){let r=u(t),i=r.pop(),s=h(e,r);return s&&delete s[i],Array.isArray(s)&&!0!==n&&m(s),e}let y=/\/+/g,b=/~/g,v=/\//g;function k(e,t){if(0===e.length)return t?"#":"";for(let n=0,r=e.length;n<r;n+=1)e[n]=e[n].replace(b,"~0").replace(v,"~1"),t&&(e[n]=encodeURIComponent(e[n]));return((t?"#/":"/")+e.join("/")).replace(y,"/")}function w(e,...t){let n=[];if(Array.isArray(e))return k(e,!0===arguments[1]);let r=arguments[arguments.length-1],i="boolean"==typeof r?r:e&&"#"===e[0];for(let e=0,t=arguments.length;e<t;e+=1)n.push.apply(n,u(arguments[e]));let s=[];for(let e=0,t=n.length;e<t;e+=1)if(".."===n[e]){if(0===s.length)return i?"#":"";s.pop()}else s.push(n[e]);return k(s,i)}function D(e){let t=u(e);if(0===t.length)return"string"==typeof e&&"#"===e[0]?["#",t[0]]:["",void 0];if(1===t.length)return"#"===e[0]?["#",t[0]]:["",t[0]];let n=t.pop();return[w(t,"#"===e[0]),n]}let A={get:h,set:d,remove:g,join:w,split:u,splitLast:D,isRoot:n,removeUndefinedItems:m};return t})(),e.exports=n()},39714:function(e){"use strict";var t=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t||function(e){return e.$$typeof===n}(e)}(e)},n="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function r(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l(Array.isArray(e)?[]:{},e,t):e}function i(e,t,n){return e.concat(t).map(function(e){return r(e,n)})}function s(e){var t;return Object.keys(e).concat((t=e,Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter(function(e){return Object.propertyIsEnumerable.call(t,e)}):[]))}function o(e,t){try{return t in e}catch(e){return!1}}function l(e,n,a){(a=a||{}).arrayMerge=a.arrayMerge||i,a.isMergeableObject=a.isMergeableObject||t,a.cloneUnlessOtherwiseSpecified=r;var u,h,c,f,d=Array.isArray(n),p=Array.isArray(e);if(d!==p)return r(n,a);if(d)return a.arrayMerge(e,n,a);return u=e,h=n,f={},(c=a).isMergeableObject(u)&&s(u).forEach(function(e){f[e]=r(u[e],c)}),s(h).forEach(function(e){var t,n;if(!o(t=u,n=e)||!!(Object.hasOwnProperty.call(t,n)&&Object.propertyIsEnumerable.call(t,n)))o(u,e)&&c.isMergeableObject(h[e])?f[e]=(function(e,t){if(!t.customMerge)return l;var n=t.customMerge(e);return"function"==typeof n?n:l})(e,c)(u[e],h[e],c):f[e]=r(h[e],c)}),f}l.all=function(e,t){if(!Array.isArray(e))throw Error("first argument should be an array");return e.reduce(function(e,n){return l(e,n,t)},{})};e.exports=l},44091:function(e,t,n){"use strict";var r;let i=n(73961);!function(e){e.RULES=[{name:"Grammar",bnf:[["RULE_S*","%Atomic*","EOF"]]},{name:"%Atomic",bnf:[["Production","RULE_S*"]],fragment:!0},{name:"Production",bnf:[["NCName","RULE_S*",'"::="',"RULE_WHITESPACE*","Choice","RULE_WHITESPACE*","RULE_EOL+","RULE_S*"]]},{name:"NCName",bnf:[[/[a-zA-Z][a-zA-Z_0-9]*/]]},{name:"Choice",bnf:[["SequenceOrDifference","%_Choice_1*"]],fragment:!0},{name:"%_Choice_1",bnf:[["RULE_WHITESPACE*",'"|"',"RULE_WHITESPACE*","SequenceOrDifference"]],fragment:!0},{name:"SequenceOrDifference",bnf:[["Item","RULE_WHITESPACE*","%_Item_1?"]]},{name:"%_Item_1",bnf:[["Minus","Item"],["Item*"]],fragment:!0},{name:"Minus",bnf:[['"-"']]},{name:"Item",bnf:[["RULE_WHITESPACE*","%Primary","PrimaryDecoration?"]],fragment:!0},{name:"PrimaryDecoration",bnf:[['"?"'],['"*"'],['"+"']]},{name:"DecorationName",bnf:[['"ebnf://"',/[^\x5D#]+/]]},{name:"%Primary",bnf:[["NCName"],["StringLiteral"],["CharCode"],["CharClass"],["SubItem"]],fragment:!0},{name:"SubItem",bnf:[['"("',"RULE_WHITESPACE*","Choice","RULE_WHITESPACE*",'")"']]},{name:"StringLiteral",bnf:[["'\"'",/[^"]*/,"'\"'"],['"\'"',/[^']*/,'"\'"']],pinned:1},{name:"CharCode",bnf:[['"#x"',/[0-9a-zA-Z]+/]]},{name:"CharClass",bnf:[["'['","'^'?","%RULE_CharClass_1+",'"]"']]},{name:"%RULE_CharClass_1",bnf:[["CharCodeRange"],["CharRange"],["CharCode"],["RULE_Char"]],fragment:!0},{name:"RULE_Char",bnf:[[/\x09/],[/\x0A/],[/\x0D/],[/[\x20-\x5c]/],[/[\x5e-\uD7FF]/],[/[\uE000-\uFFFD]/]]},{name:"CharRange",bnf:[["RULE_Char",'"-"',"RULE_Char"]]},{name:"CharCodeRange",bnf:[["CharCode",'"-"',"CharCode"]]},{name:"RULE_WHITESPACE",bnf:[["%RULE_WHITESPACE_CHAR*"],["Comment","RULE_WHITESPACE*"]]},{name:"RULE_S",bnf:[["RULE_WHITESPACE","RULE_S*"],["RULE_EOL","RULE_S*"]]},{name:"%RULE_WHITESPACE_CHAR",bnf:[[/\x09/],[/\x20/]],fragment:!0},{name:"Comment",bnf:[['"/*"',"%RULE_Comment_Body*",'"*/"']]},{name:"%RULE_Comment_Body",bnf:[['!"*/"',/[^*]/]],fragment:!0},{name:"RULE_EOL",bnf:[[/\x0D/,/\x0A/],[/\x0A/],[/\x0D/]]},{name:"Link",bnf:[["'['","Url","']'"]]},{name:"Url",bnf:[[/[^\x5D:/?#]/,'"://"',/[^\x5D#]+/,"%Url1?"]]},{name:"%Url1",bnf:[['"#"',"NCName"]],fragment:!0}],e.defaultParser=new i.Parser(e.RULES,{debug:!1});let t=/^(!|&)/,n=/(\?|\+|\*)$/,r=/^%/;function s(e,o){let l=i.findRuleByName(e,o);return l?l.bnf.map(e=>{var l,a;return l=e,a=o,l.map(e=>(function(e,o){if("string"!=typeof e)return e.source.replace(/\\(?:x|u)([a-zA-Z0-9]+)/g,"#x$1").replace(/\[\\(?:x|u)([a-zA-Z0-9]+)-\\(?:x|u)([a-zA-Z0-9]+)\]/g,"[#x$1-#x$2]");if(t.test(e))return"";if(r.test(e)){let t=n.exec(e),r=t?t[0]+" ":"";return function(e,t){let n=i.findRuleByName(e,t);return n&&1==n.bnf.length&&1==n.bnf[0].length&&(n.bnf[0][0]instanceof RegExp||'"'==n.bnf[0][0][0]||"'"==n.bnf[0][0][0])}(e,o)?s(e,o)+r:"("+s(e,o)+")"+r}return e})(e,a)).join(" ")}).join(" | "):"RULE_NOT_FOUND {"+e+"}"}function o(e){let t=[];return e.grammarRules.forEach(n=>{if(!/^%/.test(n.name)){let r=n.recover?" /* { recoverUntil="+n.recover+" } */":"";t.push(n.name+" ::= "+s(n.name,e)+r)}}),t.join("\n")}e.emit=o;let l=0;function a(e){return new RegExp(e.replace(/#x([a-zA-Z0-9]{4})/g,"\\u$1").replace(/#x([a-zA-Z0-9]{3})/g,"\\u0$1").replace(/#x([a-zA-Z0-9]{2})/g,"\\x$1").replace(/#x([a-zA-Z0-9]{1})/g,"\\x0$1"))}function u(e,t,n){let r=t.children.filter(e=>"SequenceOrDifference"==e.type).map(t=>{var r,i,s;let o,h;return r=e,i=t,s=n,o=null,h=[],i.children.forEach((e,t)=>{"Minus"==e.type&&!function(e,t){throw console.log("reberia restar "+t+" a "+e),Error("Difference not supported yet")}(o,e);let n=i.children[t+1];n=n&&"PrimaryDecoration"==n.type&&n.text||"";switch(e.type){case"SubItem":let c="%"+(s+l++);u(r,e,c),h.push(""+c+n);break;case"NCName":case"StringLiteral":h.push(""+e.text+n);break;case"CharCode":case"CharClass":if(n){let t={name:"%"+(s+l++),bnf:[[a(e.text)]]};r.push(t),h.push(""+t.name+n)}else h.push(a(e.text));break;case"PrimaryDecoration":break;default:throw Error(" HOW SHOULD I PARSE THIS? "+e.type+" -> "+JSON.stringify(e.text))}o=e}),h}),i={name:n,bnf:r},s=null;r.forEach(e=>{s=s||e.recover,delete e.recover}),0==n.indexOf("%")&&(i.fragment=!0),s&&(i.recover=s),e.push(i)}function h(t,n=e.defaultParser){let r=n.getAST(t);if(!r)throw Error("Could not parse "+t);if(r.errors&&r.errors.length)throw r.errors[0];let i=[];return r.children.filter(e=>"Production"==e.type).map(e=>{let t=e.children.filter(e=>"NCName"==e.type)[0].text;u(i,e,t)}),i}e.getRules=h;e.Transform=function(t,n=e.defaultParser){return h(t.join(""),n)};class c extends i.Parser{constructor(t,n){super(h(t,n&&!0===n.debugRulesParser?new i.Parser(e.RULES,{debug:!0}):e.defaultParser),n)}emitSource(){return o(this)}}e.Parser=c}(r||(r={})),t.default=r},73961:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Parser=t.findRuleByName=t.parseRuleName=t.escapeRegExp=t.readToken=void 0;let r=/^[A-Z0-9_]+$/,i=/(\?|\+|\*)$/,s=/^(@|&|!)/,o=n(80707);function l(e,t){let n=t.exec(e);if(n&&0==n.index)return 0==n[0].length&&t.source.length>0?null:{type:null,text:n[0],rest:e.substr(n[0].length),start:0,end:n[0].length-1,fullText:n[0],errors:[],children:[],parent:null};return null}function a(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}t.readToken=l,t.escapeRegExp=a;function u(e){let t=i.exec(e),n=s.exec(e),r=t&&t[0]||"",o=n&&n[0]||"",l={raw:e,name:e.replace(i,"").replace(s,""),isOptional:"?"==r||"*"==r,allowRepetition:"+"==r||"*"==r,atLeastOne:"+"==r,lookupPositive:"&"==o,lookupNegative:"!"==o,pinned:"@"==o,lookup:!1,isLiteral:!1};return l.isLiteral="'"==l.name[0]||'"'==l.name[0],l.lookup=l.lookupNegative||l.lookupPositive,l}function h(e,t){let n=u(e);return t.cachedRules[n.name]||null}function c(e,t){if(e.children){let n=e.children.filter(e=>e.type&&t.test(e.type));for(let t=0;t<n.length;t++){let r=e.children.indexOf(n[t]);-1!=r&&e.children.splice(r,1)}e.children.forEach(e=>c(e,t))}}t.parseRuleName=u,t.findRuleByName=h;let f=["EOF"];class d{constructor(e,t){this.grammarRules=e,this.options=t,this.cachedRules={},this.debug=!!t&&!0===t.debug;let n=[],r=[];if(e.forEach(e=>{let t=u(e.name);if(t.name in this.cachedRules){n.push("Duplicated rule "+t.name);return}this.cachedRules[t.name]=e;if(e.bnf&&e.bnf.length)e.bnf.forEach(t=>{if("string"==typeof t[0]&&u(t[0]).name==e.name){let t="Left recursion is not allowed, rule: "+e.name;-1==n.indexOf(t)&&n.push(t)}t.forEach(e=>{if("string"==typeof e){let t=u(e);!t.isLiteral&&-1==r.indexOf(t.name)&&-1==f.indexOf(t.name)&&r.push(t.name)}})});else{let t="Missing rule content, rule: "+e.name;-1==n.indexOf(t)&&n.push(t)}"WS"==e.name&&(e.implicitWs=!1),e.implicitWs&&-1==r.indexOf("WS")&&r.push("WS"),e.recover&&-1==r.indexOf(e.recover)&&r.push(e.recover)}),r.forEach(e=>{!(e in this.cachedRules)&&n.push("Missing rule "+e)}),n.length)throw Error(n.join("\n"))}getAST(e,t){!t&&(t=this.grammarRules.filter(e=>!e.fragment&&0!=e.name.indexOf("%"))[0].name);let n=this.parse(e,t);if(n){!function e(t,n){n.errors&&n.errors.length&&n.errors.forEach(e=>t.push(e)),n.children&&n.children.forEach(n=>e(t,n))}(n.errors,n),!function e(t,n){t.start+=n,t.end+=n,t.children&&t.children.forEach(n=>e(n,t.start))}(n,0),c(n,/^%/),(!this.options||!this.options.keepUpperRules)&&c(n,r);let e=n.rest;e&&new o.TokenError("Unexpected end of input: \n"+e,n),!function e(t){t.rest="",t.children&&t.children.forEach(t=>e(t))}(n),n.rest=e}return n}emitSource(){return"CANNOT EMIT SOURCE FROM BASE Parser"}parse(e,t,n=0){let i,s=null,c=u(t),f=this.debug&&!r.test(c.name);f&&console.log(Array(n).join("│ ")+"Trying to get "+t+" from "+JSON.stringify(e.split("\n")[0]));let d=c.name,p=h(c.name,this);if("EOF"==c.name){if(e.length)return null;if(0==e.length)return{type:"EOF",text:"",rest:"",start:0,end:0,fullText:"",errors:[],children:[],parent:null}}try{if(!p&&c.isLiteral){let t=c.name.trim();if(t.startsWith('"')?t=JSON.parse(t):t.startsWith("'")&&(t=t.replace(/^'(.+)'$/,"$1").replace(/\\'/g,"'")),""===t)return{type:"%%EMPTY%%",text:"",rest:e,start:0,end:0,fullText:"",errors:[],children:[],parent:null};i=new RegExp(a(t)),d=null}}catch(e){return e instanceof ReferenceError&&console.error(e),null}if(i){let t=l(e,i);if(t)return t.type=d,t}else{let t=p.bnf;t instanceof Array&&t.forEach(t=>{if(s)return;let r=null,i={type:c.name,text:"",children:[],end:0,errors:[],fullText:"",parent:null,start:0,rest:e};p.fragment&&(i.fragment=!0);let a=e,h=0,d=t.length>0,m=!1;for(let e=0;e<t.length;e++)if("string"==typeof t[e]){let l,c=u(t[e]);d=d&&c.isOptional;let g=!1;do{if(l=null,p.implicitWs&&!(l=this.parse(a,c.name,n+1))){let e;do if(e=this.parse(a,"WS",n+1))i.text=i.text+e.text,i.end=i.text.length,e.parent=i,i.children.push(e),a=a.substr(e.text.length),h+=e.text.length;else break;while(e&&e.text.length)}if(l=l||this.parse(a,c.name,n+1),c.lookupNegative){if(l)return;break}if(c.lookupPositive&&!l)return;if(!l&&(c.isOptional||c.atLeastOne&&g))break;if(l&&p.pinned==e+1&&(r=l,f&&console.log(Array(n+1).join("│ ")+"└─ "+l.type+" PINNED")),!l&&(l=this.parseRecovery(p,a,n+1)),!l){if(!r)return;s=i,l={type:"SyntaxError",text:a,children:[],end:a.length,errors:[],fullText:"",parent:null,start:0,rest:""},a.length?new o.TokenError(`Unexpected end of input. Expecting ${c.name} Got: ${a}`,l):new o.TokenError(`Unexpected end of input. Missing ${c.name}`,l),f&&console.log(Array(n+1).join("│ ")+"└─ "+l.type+" "+JSON.stringify(l.text))}if(g=!0,m=!0,"%%EMPTY%%"==l.type)break;l.start+=h,l.end+=h,!c.lookupPositive&&l.type&&(l.fragment?l.children&&l.children.forEach(e=>{e.start+=h,e.end+=h,e.parent=i,i.children.push(e)}):(l.parent=i,i.children.push(l))),c.lookup&&(l.lookup=!0),f&&console.log(Array(n+1).join("│ ")+"└─ "+l.type+" "+JSON.stringify(l.text)),!c.lookup&&!l.lookup&&(i.text=i.text+l.text,i.end=i.text.length,a=a.substr(l.text.length),h+=l.text.length),i.rest=a}while(l&&c.allowRepetition&&a.length&&!l.lookup)}else{let r=l(a,t[e]);if(!r)return;f&&console.log(Array(n+1).join("│ ")+"└> "+JSON.stringify(r.text)+t[e].source),m=!0,r.start+=h,r.end+=h,i.text=i.text+r.text,i.end=i.text.length,a=a.substr(r.text.length),h+=r.text.length,i.rest=a}m&&(s=i,f&&console.log(Array(n).join("│ ")+"├<─┴< PUSHING "+s.type+" "+JSON.stringify(s.text)))}),s&&p.simplifyWhenOneChildren&&1==s.children.length&&(s=s.children[0])}return!s&&f&&console.log(t+" NOT RESOLVED FROM "+e),s}parseRecovery(e,t,n){if(e.recover&&t.length){let r,i=this.debug;i&&console.log(Array(n+1).join("│ ")+"Trying to recover until token "+e.recover+" from "+JSON.stringify(t.split("\n")[0]+t.split("\n")[1]));let s={type:"SyntaxError",text:"",children:[],end:0,errors:[],fullText:"",parent:null,start:0,rest:""};do{if(r=this.parse(t,e.recover,n+1)){new o.TokenError('Unexpected input: "'+s.text+`" Expecting: ${e.name}`,s);break}s.text=s.text+t[0],s.end=s.text.length,t=t.substr(1)}while(!r&&t.length>0);if(s.text.length>0&&r)return i&&console.log(Array(n+1).join("│ ")+"Recovered text: "+JSON.stringify(s.text)),s}return null}}t.Parser=d,t.default=d},80707:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TokenError=void 0;t.TokenError=class e extends Error{constructor(e,t){if(super(e),this.message=e,this.token=t,t&&t.errors)t.errors.push(this);else throw this}inspect(){return"SyntaxError: "+this.message}}},69378:function(e){"use strict";e.exports=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){if(t.constructor!==n.constructor)return!1;if(Array.isArray(t)){if((r=t.length)!=n.length)return!1;for(i=r;0!=i--;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if((r=(s=Object.keys(t)).length)!==Object.keys(n).length)return!1;for(i=r;0!=i--;)if(!Object.prototype.hasOwnProperty.call(n,s[i]))return!1;for(i=r;0!=i--;){var r,i,s,o=s[i];if(!e(t[o],n[o]))return!1}return!0}return t!=t&&n!=n}},96111:function(e){var t,n;t=0,n=function(){"use strict";function e(e,t){return e(t={exports:{}},t.exports),t.exports}var t,n,r,i,s,o,l,a,u,h,c,f,d,p,m,g=e(function(e){var t=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=t)}),y=e(function(e){var t=e.exports={version:"2.6.5"};"number"==typeof __e&&(__e=t)});y.version;var b=function(e){return"object"==typeof e?null!==e:"function"==typeof e},v=function(e){if(!b(e))throw TypeError(e+" is not an object!");return e},k=function(e){try{return!!e()}catch(e){return!0}},w=!k(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}),D=g.document,A=b(D)&&b(D.createElement),x=!w&&!k(function(){var e;return 7!=Object.defineProperty((e="div",A?D.createElement("div"):{}),"a",{get:function(){return 7}}).a}),C=function(e,t){var n,r;if(!b(e))return e;if(t&&"function"==typeof(n=e.toString)&&!b(r=n.call(e))||"function"==typeof(n=e.valueOf)&&!b(r=n.call(e))||!t&&"function"==typeof(n=e.toString)&&!b(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")},E=Object.defineProperty,S={f:w?Object.defineProperty:function(e,t,n){if(v(e),t=C(t,!0),v(n),x)try{return E(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},_=w?function(e,t,n){var r;return S.f(e,t,{enumerable:!1,configurable:!(2&(r=1)),writable:!(4&r),value:n})}:function(e,t,n){return e[t]=n,e},O={}.hasOwnProperty,F=function(e,t){return O.call(e,t)},P=0,T=Math.random(),N=e(function(e){var t="__core-js_shared__",n=g[t]||(g[t]={});(e.exports=function(e,t){return n[e]||(n[e]=void 0!==t?t:{})})("versions",[]).push({version:y.version,mode:"global",copyright:"\xa9 2019 Denis Pushkarev (zloirock.ru)"})})("native-function-to-string",Function.toString),B=e(function(e){var t,n=(t="src","Symbol(".concat(t,")_",(++P+T).toString(36))),r="toString",i=(""+N).split(r);y.inspectSource=function(e){return N.call(e)},(e.exports=function(e,t,r,s){var o="function"==typeof r;if(o&&(F(r,"name")||_(r,"name",t)),e[t]!==r)o&&(F(r,n)||_(r,n,e[t]?""+e[t]:i.join(String(t)))),e===g?e[t]=r:s?e[t]?e[t]=r:_(e,t,r):(delete e[t],_(e,t,r))})(Function.prototype,r,function(){return"function"==typeof this&&this[n]||N.call(this)})}),I=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e},M=function(e,t,n){if(I(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,i){return e.call(t,n,r,i)}}return function(){return e.apply(t,arguments)}},$="prototype",L=function(e,t,n){var r,i,s,o,l=e&L.F,a=e&L.G,u=e&L.S,h=e&L.P,c=e&L.B,f=a?g:u?g[t]||(g[t]={}):(g[t]||{})[$],d=a?y:y[t]||(y[t]={}),p=d[$]||(d[$]={});for(r in a&&(n=t),n)s=((i=!l&&f&&void 0!==f[r])?f:n)[r],o=c&&i?M(s,g):h&&"function"==typeof s?M(Function.call,s):s,f&&B(f,r,s,e&L.U),d[r]!=s&&_(d,r,o),h&&p[r]!=s&&(p[r]=s)};g.core=y,L.F=1,L.G=2,L.S=4,L.P=8,L.B=16,L.W=32,L.U=64,L.R=128;var R=Math.ceil,j=Math.floor,q=function(e){return isNaN(e=+e)?0:(e>0?j:R)(e)},V=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e};var z=(t=!1,function(e,n){var r,i,s=String(V(e)),o=q(n),l=s.length;return o<0||o>=l?t?"":void 0:(r=s.charCodeAt(o))<55296||r>56319||o+1===l||(i=s.charCodeAt(o+1))<56320||i>57343?t?s.charAt(o):r:t?s.slice(o,o+2):(r-55296<<10)+(i-56320)+65536});L(L.P,"String",{codePointAt:function(e){return z(this,e)}}),y.String.codePointAt;var U=Math.max,H=Math.min,W=String.fromCharCode,G=String.fromCodePoint;L(L.S+L.F*(!!G&&1!=G.length),"String",{fromCodePoint:function(e){for(var t,n,r,i=arguments,s=[],o=arguments.length,l=0;o>l;){;if(n=1114111,((t=q(t=r=+i[l++]))<0?U(t+1114111,0):H(t,n))!==r)throw RangeError(r+" is not a valid code point");s.push(r<65536?W(r):W(((r-=65536)>>10)+55296,r%1024+56320))}return s.join("")}}),y.String.fromCodePoint;var K={Space_Separator:/[\u1680\u2000-\u200A\u202F\u205F\u3000]/,ID_Start:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]/,ID_Continue:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u08D4-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF9\u1D00-\u1DF9\u1DFB-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE3E\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDE00-\uDE3E\uDE47\uDE50-\uDE83\uDE86-\uDE99\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4A\uDD50-\uDD59]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/},J={isSpaceSeparator:function(e){return"string"==typeof e&&K.Space_Separator.test(e)},isIdStartChar:function(e){return"string"==typeof e&&(e>="a"&&e<="z"||e>="A"&&e<="Z"||"$"===e||"_"===e||K.ID_Start.test(e))},isIdContinueChar:function(e){return"string"==typeof e&&(e>="a"&&e<="z"||e>="A"&&e<="Z"||e>="0"&&e<="9"||"$"===e||"_"===e||""===e||""===e||K.ID_Continue.test(e))},isDigit:function(e){return"string"==typeof e&&/[0-9]/.test(e)},isHexDigit:function(e){return"string"==typeof e&&/[0-9A-Fa-f]/.test(e)}};function Q(){if(n[s])return String.fromCodePoint(n.codePointAt(s))}function Y(){var e=Q();return"\n"===e?(o++,l=0):e?l+=e.length:l++,e&&(s+=e.length),e}var Z={default:function(){switch(m){case" ":case"\v":case"\f":case" ":case"\xa0":case"\uFEFF":case"\n":case"\r":case"\u2028":case"\u2029":Y();return;case"/":Y(),c="comment";return;case void 0:return Y(),X("eof")}if(J.isSpaceSeparator(m)){Y();return}return Z[r]()},comment:function(){switch(m){case"*":Y(),c="multiLineComment";return;case"/":Y(),c="singleLineComment";return}throw es(Y())},multiLineComment:function(){switch(m){case"*":Y(),c="multiLineCommentAsterisk";return;case void 0:throw es(Y())}Y()},multiLineCommentAsterisk:function(){switch(m){case"*":Y();return;case"/":Y(),c="default";return;case void 0:throw es(Y())}Y(),c="multiLineComment"},singleLineComment:function(){switch(m){case"\n":case"\r":case"\u2028":case"\u2029":Y(),c="default";return;case void 0:return Y(),X("eof")}Y()},value:function(){switch(m){case"{":case"[":return X("punctuator",Y());case"n":return Y(),ee("ull"),X("null",null);case"t":return Y(),ee("rue"),X("boolean",!0);case"f":return Y(),ee("alse"),X("boolean",!1);case"-":case"+":"-"===Y()&&(p=-1),c="sign";return;case".":f=Y(),c="decimalPointLeading";return;case"0":f=Y(),c="zero";return;case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":f=Y(),c="decimalInteger";return;case"I":return Y(),ee("nfinity"),X("numeric",1/0);case"N":return Y(),ee("aN"),X("numeric",NaN);case'"':case"'":d='"'===Y(),f="",c="string";return}throw es(Y())},identifierNameStartEscape:function(){if("u"!==m)throw es(Y());Y();var e=et();switch(e){case"$":case"_":break;default:if(!J.isIdStartChar(e))throw el()}f+=e,c="identifierName"},identifierName:function(){switch(m){case"$":case"_":case"":case"":f+=Y();return;case"\\":Y(),c="identifierNameEscape";return}if(J.isIdContinueChar(m)){f+=Y();return}return X("identifier",f)},identifierNameEscape:function(){if("u"!==m)throw es(Y());Y();var e=et();switch(e){case"$":case"_":case"":case"":break;default:if(!J.isIdContinueChar(e))throw el()}f+=e,c="identifierName"},sign:function(){switch(m){case".":f=Y(),c="decimalPointLeading";return;case"0":f=Y(),c="zero";return;case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":f=Y(),c="decimalInteger";return;case"I":return Y(),ee("nfinity"),X("numeric",1/0*p);case"N":return Y(),ee("aN"),X("numeric",NaN)}throw es(Y())},zero:function(){switch(m){case".":f+=Y(),c="decimalPoint";return;case"e":case"E":f+=Y(),c="decimalExponent";return;case"x":case"X":f+=Y(),c="hexadecimal";return}return X("numeric",0*p)},decimalInteger:function(){switch(m){case".":f+=Y(),c="decimalPoint";return;case"e":case"E":f+=Y(),c="decimalExponent";return}if(J.isDigit(m)){f+=Y();return}return X("numeric",p*Number(f))},decimalPointLeading:function(){if(J.isDigit(m)){f+=Y(),c="decimalFraction";return}throw es(Y())},decimalPoint:function(){switch(m){case"e":case"E":f+=Y(),c="decimalExponent";return}if(J.isDigit(m)){f+=Y(),c="decimalFraction";return}return X("numeric",p*Number(f))},decimalFraction:function(){switch(m){case"e":case"E":f+=Y(),c="decimalExponent";return}if(J.isDigit(m)){f+=Y();return}return X("numeric",p*Number(f))},decimalExponent:function(){switch(m){case"+":case"-":f+=Y(),c="decimalExponentSign";return}if(J.isDigit(m)){f+=Y(),c="decimalExponentInteger";return}throw es(Y())},decimalExponentSign:function(){if(J.isDigit(m)){f+=Y(),c="decimalExponentInteger";return}throw es(Y())},decimalExponentInteger:function(){if(J.isDigit(m)){f+=Y();return}return X("numeric",p*Number(f))},hexadecimal:function(){if(J.isHexDigit(m)){f+=Y(),c="hexadecimalInteger";return}throw es(Y())},hexadecimalInteger:function(){if(J.isHexDigit(m)){f+=Y();return}return X("numeric",p*Number(f))},string:function(){switch(m){case"\\":Y(),f+=function(){switch(Q()){case"b":return Y(),"\b";case"f":return Y(),"\f";case"n":return Y(),"\n";case"r":return Y(),"\r";case"t":return Y()," ";case"v":return Y(),"\v";case"0":if(Y(),J.isDigit(Q()))throw es(Y());return"\0";case"x":return Y(),function(){var e="",t=Q();if(!J.isHexDigit(t))throw es(Y());if(e+=Y(),t=Q(),!J.isHexDigit(t))throw es(Y());return String.fromCodePoint(parseInt(e+=Y(),16))}();case"u":return Y(),et();case"\n":case"\u2028":case"\u2029":return Y(),"";case"\r":return Y(),"\n"===Q()&&Y(),"";case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case void 0:throw es(Y())}return Y()}();return;case'"':if(d)return Y(),X("string",f);f+=Y();return;case"'":if(!d)return Y(),X("string",f);f+=Y();return;case"\n":case"\r":case void 0:throw es(Y());case"\u2028":case"\u2029":(function(e){console.warn("JSON5: '"+ea(e)+"' in strings is not valid ECMAScript; consider escaping")})(m)}f+=Y()},start:function(){switch(m){case"{":case"[":return X("punctuator",Y())}c="value"},beforePropertyName:function(){switch(m){case"$":case"_":f=Y(),c="identifierName";return;case"\\":Y(),c="identifierNameStartEscape";return;case"}":return X("punctuator",Y());case'"':case"'":d='"'===Y(),c="string";return}if(J.isIdStartChar(m)){f+=Y(),c="identifierName";return}throw es(Y())},afterPropertyName:function(){if(":"===m)return X("punctuator",Y());throw es(Y())},beforePropertyValue:function(){c="value"},afterPropertyValue:function(){switch(m){case",":case"}":return X("punctuator",Y())}throw es(Y())},beforeArrayValue:function(){if("]"===m)return X("punctuator",Y());c="value"},afterArrayValue:function(){switch(m){case",":case"]":return X("punctuator",Y())}throw es(Y())},end:function(){throw es(Y())}};function X(e,t){return{type:e,value:t,line:o,column:l}}function ee(e){for(var t=0;t<e.length;t+=1){var n=e[t];if(Q()!==n)throw es(Y());Y()}}function et(){for(var e="",t=4;t-- >0;){var n=Q();if(!J.isHexDigit(n))throw es(Y());e+=Y()}return String.fromCodePoint(parseInt(e,16))}var en={start:function(){if("eof"===a.type)throw eo();er()},beforePropertyName:function(){switch(a.type){case"identifier":case"string":u=a.value,r="afterPropertyName";return;case"punctuator":ei();return;case"eof":throw eo()}},afterPropertyName:function(){if("eof"===a.type)throw eo();r="beforePropertyValue"},beforePropertyValue:function(){if("eof"===a.type)throw eo();er()},beforeArrayValue:function(){if("eof"===a.type)throw eo();if("punctuator"===a.type&&"]"===a.value){ei();return}er()},afterPropertyValue:function(){if("eof"===a.type)throw eo();switch(a.value){case",":r="beforePropertyName";return;case"}":ei()}},afterArrayValue:function(){if("eof"===a.type)throw eo();switch(a.value){case",":r="beforeArrayValue";return;case"]":ei()}},end:function(){}};function er(){var e;switch(a.type){case"punctuator":switch(a.value){case"{":e={};break;case"[":e=[]}break;case"null":case"boolean":case"numeric":case"string":e=a.value}if(void 0===h)h=e;else{var t=i[i.length-1];Array.isArray(t)?t.push(e):Object.defineProperty(t,u,{value:e,writable:!0,enumerable:!0,configurable:!0})}if(null!==e&&"object"==typeof e)i.push(e),r=Array.isArray(e)?"beforeArrayValue":"beforePropertyName";else{var n=i[i.length-1];r=null==n?"end":Array.isArray(n)?"afterArrayValue":"afterPropertyValue"}}function ei(){i.pop();var e=i[i.length-1];r=null==e?"end":Array.isArray(e)?"afterArrayValue":"afterPropertyValue"}function es(e){return void 0===e?eu("JSON5: invalid end of input at "+o+":"+l):eu("JSON5: invalid character '"+ea(e)+"' at "+o+":"+l)}function eo(){return eu("JSON5: invalid end of input at "+o+":"+l)}function el(){return l-=5,eu("JSON5: invalid identifier character at "+o+":"+l)}function ea(e){var t={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r"," ":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"};if(t[e])return t[e];if(e<" "){var n=e.charCodeAt(0).toString(16);return"\\x"+("00"+n).substring(n.length)}return e}function eu(e){var t=SyntaxError(e);return t.lineNumber=o,t.columnNumber=l,t}return{parse:function(e,t){n=String(e),r="start",i=[],s=0,o=1,l=0,a=void 0,u=void 0,h=void 0;do a=function(){for(c="default",f="",d=!1,p=1;;){m=Q();var e=Z[c]();if(e)return e}}(),en[r]();while("eof"!==a.type);return"function"==typeof t?function e(t,n,r){var i=t[n];if(null!=i&&"object"==typeof i){if(Array.isArray(i))for(var s=0;s<i.length;s++){var o=String(s),l=e(i,o,r);void 0===l?delete i[o]:Object.defineProperty(i,o,{value:l,writable:!0,enumerable:!0,configurable:!0})}else for(var a in i){var u=e(i,a,r);void 0===u?delete i[a]:Object.defineProperty(i,a,{value:u,writable:!0,enumerable:!0,configurable:!0})}}return r.call(t,n,i)}({"":h},"",t):h},stringify:function(e,t,n){var r,i,s,o=[],l="",a="";if(null!=t&&"object"==typeof t&&!Array.isArray(t)&&(n=t.space,s=t.quote,t=t.replacer),"function"==typeof t)i=t;else if(Array.isArray(t)){r=[];for(var u=0,h=t;u<h.length;u+=1){var c=h[u],f=void 0;"string"==typeof c?f=c:("number"==typeof c||c instanceof String||c instanceof Number)&&(f=String(c)),void 0!==f&&0>r.indexOf(f)&&r.push(f)}}return n instanceof Number?n=Number(n):n instanceof String&&(n=String(n)),"number"==typeof n?n>0&&(n=Math.min(10,Math.floor(n)),a=" ".substr(0,n)):"string"==typeof n&&(a=n.substr(0,10)),d("",{"":e});function d(e,t){var n=t[e];switch(null!=n&&("function"==typeof n.toJSON5?n=n.toJSON5(e):"function"==typeof n.toJSON&&(n=n.toJSON(e))),i&&(n=i.call(t,e,n)),n instanceof Number?n=Number(n):n instanceof String?n=String(n):n instanceof Boolean&&(n=n.valueOf()),n){case null:return"null";case!0:return"true";case!1:return"false"}return"string"==typeof n?p(n,!1):"number"==typeof n?String(n):"object"==typeof n?Array.isArray(n)?function(e){if(o.indexOf(e)>=0)throw TypeError("Converting circular structure to JSON5");o.push(e);var t,n=l;l+=a;for(var r=[],i=0;i<e.length;i++){var s=d(String(i),e);r.push(void 0!==s?s:"null")}if(0===r.length)t="[]";else if(""===a)t="["+r.join(",")+"]";else{var u=",\n"+l,h=r.join(u);t="[\n"+l+h+",\n"+n+"]"}return o.pop(),l=n,t}(n):function(e){if(o.indexOf(e)>=0)throw TypeError("Converting circular structure to JSON5");o.push(e);var t,n,i=l;l+=a;for(var s=r||Object.keys(e),u=[],h=0;h<s.length;h+=1){var c=s[h],f=d(c,e);if(void 0!==f){var m=function(e){if(0===e.length)return p(e,!0);var t=String.fromCodePoint(e.codePointAt(0));if(!J.isIdStartChar(t))return p(e,!0);for(var n=t.length;n<e.length;n++)if(!J.isIdContinueChar(String.fromCodePoint(e.codePointAt(n))))return p(e,!0);return e}(c)+":";""!==a&&(m+=" "),m+=f,u.push(m)}}if(0===u.length)t="{}";else if(""===a)t="{"+(n=u.join(","))+"}";else{var g=",\n"+l;n=u.join(g),t="{\n"+l+n+",\n"+i+"}"}return o.pop(),l=i,t}(n):void 0}function p(e){for(var t={"'":.1,'"':.2},n={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r"," ":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"},r="",i=0;i<e.length;i++){var o=e[i];switch(o){case"'":case'"':t[o]++,r+=o;continue;case"\0":if(J.isDigit(e[i+1])){r+="\\x00";continue}}if(n[o]){r+=n[o];continue}if(o<" "){var l=o.charCodeAt(0).toString(16);r+="\\x"+("00"+l).substring(l.length);continue}r+=o}var a=s||Object.keys(t).reduce(function(e,n){return t[e]<t[n]?e:n});return r=r.replace(RegExp(a,"g"),n[a]),a+r+a}}}},e.exports=n()},43614:function(e){var t,n;t=this,n=function(){function e(t,n,r){return this.id=++e.highestId,this.name=t,this.symbols=n,this.postprocess=r,this}function t(e,t,n,r){this.rule=e,this.dot=t,this.reference=n,this.data=[],this.wantedBy=r,this.isComplete=this.dot===e.symbols.length}function n(e,t){this.grammar=e,this.index=t,this.states=[],this.wants={},this.scannable=[],this.completed={}}function r(e,t){this.rules=e,this.start=t||this.rules[0].name;var n=this.byName={};this.rules.forEach(function(e){!n.hasOwnProperty(e.name)&&(n[e.name]=[]),n[e.name].push(e)})}function i(){this.reset("")}function s(e,t,s){if(e instanceof r){var o=e,s=t}else var o=r.fromCompiled(e,t);for(var l in this.grammar=o,this.options={keepHistory:!1,lexer:o.lexer||new i},s||{})this.options[l]=s[l];this.lexer=this.options.lexer,this.lexerState=void 0;var a=new n(o,0);this.table=[a],a.wants[o.start]=[],a.predict(o.start),a.process(),this.current=0}e.highestId=0,e.prototype.toString=function(e){var t=void 0===e?this.symbols.map(o).join(" "):this.symbols.slice(0,e).map(o).join(" ")+" ● "+this.symbols.slice(e).map(o).join(" ");return this.name+" → "+t},t.prototype.toString=function(){return"{"+this.rule.toString(this.dot)+"}, from: "+(this.reference||0)},t.prototype.nextState=function(e){var n=new t(this.rule,this.dot+1,this.reference,this.wantedBy);return n.left=this,n.right=e,n.isComplete&&(n.data=n.build(),n.right=void 0),n},t.prototype.build=function(){var e=[],t=this;do e.push(t.right.data),t=t.left;while(t.left);return e.reverse(),e},t.prototype.finish=function(){this.rule.postprocess&&(this.data=this.rule.postprocess(this.data,this.reference,s.fail))},n.prototype.process=function(e){for(var t=this.states,n=this.wants,r=this.completed,i=0;i<t.length;i++){var o=t[i];if(o.isComplete){if(o.finish(),o.data!==s.fail){for(var l=o.wantedBy,a=l.length;a--;){var u=l[a];this.complete(u,o)}if(o.reference===this.index){var h=o.rule.name;(this.completed[h]=this.completed[h]||[]).push(o)}}}else{var h=o.rule.symbols[o.dot];if("string"!=typeof h){this.scannable.push(o);continue}if(n[h]){if(n[h].push(o),r.hasOwnProperty(h)){for(var c=r[h],a=0;a<c.length;a++){var f=c[a];this.complete(o,f)}}}else n[h]=[o],this.predict(h)}}},n.prototype.predict=function(e){for(var n=this.grammar.byName[e]||[],r=0;r<n.length;r++){var i=n[r],s=this.wants[e],o=new t(i,0,this.index,s);this.states.push(o)}},n.prototype.complete=function(e,t){var n=e.nextState(t);this.states.push(n)},r.fromCompiled=function(t,n){var i=t.Lexer;t.ParserStart&&(n=t.ParserStart,t=t.ParserRules);var t=t.map(function(t){return new e(t.name,t.symbols,t.postprocess)}),s=new r(t,n);return s.lexer=i,s},i.prototype.reset=function(e,t){this.buffer=e,this.index=0,this.line=t?t.line:1,this.lastLineBreak=t?-t.col:0},i.prototype.next=function(){if(this.index<this.buffer.length){var e=this.buffer[this.index++];return"\n"===e&&(this.line+=1,this.lastLineBreak=this.index),{value:e}}},i.prototype.save=function(){return{line:this.line,col:this.index-this.lastLineBreak}},i.prototype.formatError=function(e,t){var n=this.buffer;if("string"!=typeof n)return t+" at index "+(this.index-1);var r=n.split("\n").slice(Math.max(0,this.line-5),this.line),i=n.indexOf("\n",this.index);-1===i&&(i=n.length);var s=this.index-this.lastLineBreak,o=String(this.line).length;return t+=" at line "+this.line+" col "+s+":\n\n",t+=r.map(function(e,t){return l(this.line-r.length+t+1,o)+" "+e},this).join("\n"),t+="\n"+l("",o+s)+"^\n";function l(e,t){var n=String(e);return Array(t-n.length+1).join(" ")+n}},s.fail={},s.prototype.feed=function(e){var t,r=this.lexer;for(r.reset(e,this.lexerState);;){try{if(!(t=r.next()))break}catch(e){var s=new n(this.grammar,this.current+1);this.table.push(s);var o=Error(this.reportLexerError(e));throw o.offset=this.current,o.token=e.token,o}var l=this.table[this.current];!this.options.keepHistory&&delete this.table[this.current-1];var a=this.current+1,s=new n(this.grammar,a);this.table.push(s);for(var u=void 0!==t.text?t.text:t.value,h=r.constructor===i?t.value:t,c=l.scannable,f=c.length;f--;){var d=c[f],p=d.rule.symbols[d.dot];if(p.test?p.test(h):p.type?p.type===t.type:p.literal===u){var m=d.nextState({data:h,token:t,isToken:!0,reference:a-1});s.states.push(m)}}if(s.process(),0===s.states.length){var o=Error(this.reportError(t));throw o.offset=this.current,o.token=t,o}this.options.keepHistory&&(l.lexerState=r.save()),this.current++}return l&&(this.lexerState=r.save()),this.results=this.finish(),this},s.prototype.reportLexerError=function(e){var t,n,r=e.token;return r?(t="input "+JSON.stringify(r.text[0])+" (lexer error)",n=this.lexer.formatError(r,"Syntax error")):(t="input (lexer error)",n=e.message),this.reportErrorCommon(n,t)},s.prototype.reportError=function(e){var t=(e.type?e.type+" token: ":"")+JSON.stringify(void 0!==e.value?e.value:e),n=this.lexer.formatError(e,"Syntax error");return this.reportErrorCommon(n,t)},s.prototype.reportErrorCommon=function(e,t){var n=[];n.push(e);var r=this.table.length-2,i=this.table[r],s=i.states.filter(function(e){var t=e.rule.symbols[e.dot];return t&&"string"!=typeof t});return 0===s.length?(n.push("Unexpected "+t+". I did not expect any more input. Here is the state of my parse table:\n"),this.displayStateStack(i.states,n)):(n.push("Unexpected "+t+". Instead, I was expecting to see one of the following:\n"),s.map(function(e){return this.buildFirstStateStack(e,[])||[e]},this).forEach(function(e){var t=e[0],r=t.rule.symbols[t.dot],i=this.getSymbolDisplay(r);n.push("A "+i+" based on:"),this.displayStateStack(e,n)},this)),n.push(""),n.join("\n")},s.prototype.displayStateStack=function(e,t){for(var n,r=0,i=0;i<e.length;i++){var s=e[i],o=s.rule.toString(s.dot);o===n?r++:(r>0&&t.push(" ^ "+r+" more lines identical to this"),r=0,t.push(" "+o)),n=o}},s.prototype.getSymbolDisplay=function(e){return function(e){var t=typeof e;if("string"===t)return e;if("object"===t){if(e.literal)return JSON.stringify(e.literal);if(e instanceof RegExp)return"character matching "+e;else if(e.type)return e.type+" token";else if(e.test)return"token matching "+String(e.test);else throw Error("Unknown symbol type: "+e)}}(e)},s.prototype.buildFirstStateStack=function(e,t){if(-1!==t.indexOf(e))return null;if(0===e.wantedBy.length)return[e];var n=e.wantedBy[0],r=[e].concat(t),i=this.buildFirstStateStack(n,r);return null===i?null:[e].concat(i)},s.prototype.save=function(){var e=this.table[this.current];return e.lexerState=this.lexerState,e},s.prototype.restore=function(e){var t=e.index;this.current=t,this.table[t]=e,this.table.splice(t+1),this.lexerState=e.lexerState,this.results=this.finish()},s.prototype.rewind=function(e){if(!this.options.keepHistory)throw Error("set option `keepHistory` to enable rewinding");this.restore(this.table[e])},s.prototype.finish=function(){var e=[],t=this.grammar.start;return this.table[this.table.length-1].states.forEach(function(n){n.rule.name===t&&n.dot===n.rule.symbols.length&&0===n.reference&&n.data!==s.fail&&e.push(n)}),e.map(function(e){return e.data})};function o(e){var t=typeof e;if("string"===t)return e;if("object"===t){if(e.literal)return JSON.stringify(e.literal);if(e instanceof RegExp)return e.toString();else if(e.type)return"%"+e.type;else if(e.test)return"<"+String(e.test)+">";else throw Error("Unknown symbol type: "+e)}}return{Parser:s,Grammar:r,Rule:e}},e.exports?e.exports=n():t.nearley=n()},62935:function(e,t){"use strict";function n(e){return e[0]}Object.defineProperty(t,"__esModule",{value:!0});let r=e=>[].concat(...e.map(e=>Array.isArray(e)?r(e):e));function i(e){if(e)return Array.isArray(e)?r(e).join(""):e;return""}t.default={Lexer:void 0,ParserRules:[{name:"Reverse_path",symbols:["Path"]},{name:"Reverse_path$string$1",symbols:[{literal:"<"},{literal:">"}],postprocess:e=>e.join("")},{name:"Reverse_path",symbols:["Reverse_path$string$1"]},{name:"Forward_path$subexpression$1$subexpression$1",symbols:[{literal:"<"},/[pP]/,/[oO]/,/[sS]/,/[tT]/,/[mM]/,/[aA]/,/[sS]/,/[tT]/,/[eE]/,/[rR]/,{literal:"@"}],postprocess:function(e){return e.join("")}},{name:"Forward_path$subexpression$1",symbols:["Forward_path$subexpression$1$subexpression$1","Domain",{literal:">"}]},{name:"Forward_path",symbols:["Forward_path$subexpression$1"]},{name:"Forward_path$subexpression$2",symbols:[{literal:"<"},/[pP]/,/[oO]/,/[sS]/,/[tT]/,/[mM]/,/[aA]/,/[sS]/,/[tT]/,/[eE]/,/[rR]/,{literal:">"}],postprocess:function(e){return e.join("")}},{name:"Forward_path",symbols:["Forward_path$subexpression$2"]},{name:"Forward_path",symbols:["Path"]},{name:"Path$ebnf$1$subexpression$1",symbols:["A_d_l",{literal:":"}]},{name:"Path$ebnf$1",symbols:["Path$ebnf$1$subexpression$1"],postprocess:n},{name:"Path$ebnf$1",symbols:[],postprocess:()=>null},{name:"Path",symbols:[{literal:"<"},"Path$ebnf$1","Mailbox",{literal:">"}]},{name:"A_d_l$ebnf$1",symbols:[]},{name:"A_d_l$ebnf$1$subexpression$1",symbols:[{literal:","},"At_domain"]},{name:"A_d_l$ebnf$1",symbols:["A_d_l$ebnf$1","A_d_l$ebnf$1$subexpression$1"],postprocess:e=>e[0].concat([e[1]])},{name:"A_d_l",symbols:["At_domain","A_d_l$ebnf$1"]},{name:"At_domain",symbols:[{literal:"@"},"Domain"]},{name:"Domain$ebnf$1",symbols:[]},{name:"Domain$ebnf$1$subexpression$1",symbols:[{literal:"."},"sub_domain"]},{name:"Domain$ebnf$1",symbols:["Domain$ebnf$1","Domain$ebnf$1$subexpression$1"],postprocess:e=>e[0].concat([e[1]])},{name:"Domain",symbols:["sub_domain","Domain$ebnf$1"]},{name:"sub_domain",symbols:["U_label"]},{name:"Let_dig",symbols:["ALPHA_DIGIT"],postprocess:n},{name:"Ldh_str$ebnf$1",symbols:[]},{name:"Ldh_str$ebnf$1",symbols:["Ldh_str$ebnf$1","ALPHA_DIG_DASH"],postprocess:e=>e[0].concat([e[1]])},{name:"Ldh_str",symbols:["Ldh_str$ebnf$1","Let_dig"]},{name:"U_Let_dig",symbols:["ALPHA_DIGIT_U"],postprocess:n},{name:"U_Ldh_str$ebnf$1",symbols:[]},{name:"U_Ldh_str$ebnf$1",symbols:["U_Ldh_str$ebnf$1","ALPHA_DIG_DASH_U"],postprocess:e=>e[0].concat([e[1]])},{name:"U_Ldh_str",symbols:["U_Ldh_str$ebnf$1","U_Let_dig"]},{name:"U_label$ebnf$1$subexpression$1",symbols:["U_Ldh_str"]},{name:"U_label$ebnf$1",symbols:["U_label$ebnf$1$subexpression$1"],postprocess:n},{name:"U_label$ebnf$1",symbols:[],postprocess:()=>null},{name:"U_label",symbols:["U_Let_dig","U_label$ebnf$1"]},{name:"address_literal$subexpression$1",symbols:["IPv4_address_literal"]},{name:"address_literal$subexpression$1",symbols:["IPv6_address_literal"]},{name:"address_literal$subexpression$1",symbols:["General_address_literal"]},{name:"address_literal",symbols:[{literal:"["},"address_literal$subexpression$1",{literal:"]"}]},{name:"non_local_part",symbols:["Domain"],postprocess:function(e){return{DomainName:i(e[0])}}},{name:"non_local_part",symbols:["address_literal"],postprocess:function(e){return{AddressLiteral:i(e[0])}}},{name:"Mailbox",symbols:["Local_part",{literal:"@"},"non_local_part"],postprocess:function(e){return{localPart:i(e[0]),domainPart:i(e[2])}}},{name:"Local_part",symbols:["Dot_string"],postprocess:function(e){return{DotString:i(e[0])}}},{name:"Local_part",symbols:["Quoted_string"],postprocess:function(e){return{QuotedString:i(e[0])}}},{name:"Dot_string$ebnf$1",symbols:[]},{name:"Dot_string$ebnf$1$subexpression$1",symbols:[{literal:"."},"Atom"]},{name:"Dot_string$ebnf$1",symbols:["Dot_string$ebnf$1","Dot_string$ebnf$1$subexpression$1"],postprocess:e=>e[0].concat([e[1]])},{name:"Dot_string",symbols:["Atom","Dot_string$ebnf$1"]},{name:"Atom$ebnf$1",symbols:[/[0-9A-Za-z!#$%&'*+\-/=?^_`{|}~\u0080-\uFFFF/]/]},{name:"Atom$ebnf$1",symbols:["Atom$ebnf$1",/[0-9A-Za-z!#$%&'*+\-/=?^_`{|}~\u0080-\uFFFF/]/],postprocess:e=>e[0].concat([e[1]])},{name:"Atom",symbols:["Atom$ebnf$1"]},{name:"Quoted_string$ebnf$1",symbols:[]},{name:"Quoted_string$ebnf$1",symbols:["Quoted_string$ebnf$1","QcontentSMTP"],postprocess:e=>e[0].concat([e[1]])},{name:"Quoted_string",symbols:["DQUOTE","Quoted_string$ebnf$1","DQUOTE"]},{name:"QcontentSMTP",symbols:["qtextSMTP"]},{name:"QcontentSMTP",symbols:["quoted_pairSMTP"]},{name:"quoted_pairSMTP",symbols:[{literal:"\\"},/[\x20-\x7e]/]},{name:"qtextSMTP",symbols:[/[\x20-\x21\x23-\x5b\x5d-\x7e\u0080-\uFFFF]/],postprocess:n},{name:"IPv4_address_literal$macrocall$2",symbols:[{literal:"."},"Snum"]},{name:"IPv4_address_literal$macrocall$1",symbols:["IPv4_address_literal$macrocall$2","IPv4_address_literal$macrocall$2","IPv4_address_literal$macrocall$2"]},{name:"IPv4_address_literal",symbols:["Snum","IPv4_address_literal$macrocall$1"]},{name:"IPv6_address_literal$subexpression$1",symbols:[/[iI]/,/[pP]/,/[vV]/,{literal:"6"},{literal:":"}],postprocess:function(e){return e.join("")}},{name:"IPv6_address_literal",symbols:["IPv6_address_literal$subexpression$1","IPv6_addr"]},{name:"General_address_literal$ebnf$1",symbols:["dcontent"]},{name:"General_address_literal$ebnf$1",symbols:["General_address_literal$ebnf$1","dcontent"],postprocess:e=>e[0].concat([e[1]])},{name:"General_address_literal",symbols:["Standardized_tag",{literal:":"},"General_address_literal$ebnf$1"]},{name:"Standardized_tag",symbols:["Ldh_str"]},{name:"dcontent",symbols:[/[\x21-\x5a\x5e-\x7e]/],postprocess:n},{name:"Snum",symbols:["DIGIT"]},{name:"Snum$subexpression$1",symbols:[/[1-9]/,"DIGIT"]},{name:"Snum",symbols:["Snum$subexpression$1"]},{name:"Snum$subexpression$2",symbols:[{literal:"1"},"DIGIT","DIGIT"]},{name:"Snum",symbols:["Snum$subexpression$2"]},{name:"Snum$subexpression$3",symbols:[{literal:"2"},/[0-4]/,"DIGIT"]},{name:"Snum",symbols:["Snum$subexpression$3"]},{name:"Snum$subexpression$4",symbols:[{literal:"2"},{literal:"5"},/[0-5]/]},{name:"Snum",symbols:["Snum$subexpression$4"]},{name:"IPv6_addr",symbols:["IPv6_full"]},{name:"IPv6_addr",symbols:["IPv6_comp"]},{name:"IPv6_addr",symbols:["IPv6v4_full"]},{name:"IPv6_addr",symbols:["IPv6v4_comp"]},{name:"IPv6_hex",symbols:["HEXDIG"]},{name:"IPv6_hex$subexpression$1",symbols:["HEXDIG","HEXDIG"]},{name:"IPv6_hex",symbols:["IPv6_hex$subexpression$1"]},{name:"IPv6_hex$subexpression$2",symbols:["HEXDIG","HEXDIG","HEXDIG"]},{name:"IPv6_hex",symbols:["IPv6_hex$subexpression$2"]},{name:"IPv6_hex$subexpression$3",symbols:["HEXDIG","HEXDIG","HEXDIG","HEXDIG"]},{name:"IPv6_hex",symbols:["IPv6_hex$subexpression$3"]},{name:"IPv6_full$macrocall$2",symbols:[{literal:":"},"IPv6_hex"]},{name:"IPv6_full$macrocall$1",symbols:["IPv6_full$macrocall$2","IPv6_full$macrocall$2","IPv6_full$macrocall$2","IPv6_full$macrocall$2","IPv6_full$macrocall$2","IPv6_full$macrocall$2","IPv6_full$macrocall$2"]},{name:"IPv6_full",symbols:["IPv6_hex","IPv6_full$macrocall$1"]},{name:"IPv6_comp$ebnf$1$subexpression$1$macrocall$2",symbols:[{literal:":"},"IPv6_hex"]},{name:"IPv6_comp$ebnf$1$subexpression$1$macrocall$1",symbols:["IPv6_comp$ebnf$1$subexpression$1$macrocall$2","IPv6_comp$ebnf$1$subexpression$1$macrocall$2","IPv6_comp$ebnf$1$subexpression$1$macrocall$2","IPv6_comp$ebnf$1$subexpression$1$macrocall$2","IPv6_comp$ebnf$1$subexpression$1$macrocall$2"]},{name:"IPv6_comp$ebnf$1$subexpression$1",symbols:["IPv6_hex","IPv6_comp$ebnf$1$subexpression$1$macrocall$1"]},{name:"IPv6_comp$ebnf$1",symbols:["IPv6_comp$ebnf$1$subexpression$1"],postprocess:n},{name:"IPv6_comp$ebnf$1",symbols:[],postprocess:()=>null},{name:"IPv6_comp$string$1",symbols:[{literal:":"},{literal:":"}],postprocess:e=>e.join("")},{name:"IPv6_comp$ebnf$2$subexpression$1$macrocall$2",symbols:[{literal:":"},"IPv6_hex"]},{name:"IPv6_comp$ebnf$2$subexpression$1$macrocall$1",symbols:["IPv6_comp$ebnf$2$subexpression$1$macrocall$2","IPv6_comp$ebnf$2$subexpression$1$macrocall$2","IPv6_comp$ebnf$2$subexpression$1$macrocall$2","IPv6_comp$ebnf$2$subexpression$1$macrocall$2","IPv6_comp$ebnf$2$subexpression$1$macrocall$2"]},{name:"IPv6_comp$ebnf$2$subexpression$1",symbols:["IPv6_hex","IPv6_comp$ebnf$2$subexpression$1$macrocall$1"]},{name:"IPv6_comp$ebnf$2",symbols:["IPv6_comp$ebnf$2$subexpression$1"],postprocess:n},{name:"IPv6_comp$ebnf$2",symbols:[],postprocess:()=>null},{name:"IPv6_comp",symbols:["IPv6_comp$ebnf$1","IPv6_comp$string$1","IPv6_comp$ebnf$2"]},{name:"IPv6v4_full$macrocall$2",symbols:[{literal:":"},"IPv6_hex"]},{name:"IPv6v4_full$macrocall$1",symbols:["IPv6v4_full$macrocall$2","IPv6v4_full$macrocall$2","IPv6v4_full$macrocall$2","IPv6v4_full$macrocall$2","IPv6v4_full$macrocall$2"]},{name:"IPv6v4_full",symbols:["IPv6_hex","IPv6v4_full$macrocall$1",{literal:":"},"IPv4_address_literal"]},{name:"IPv6v4_comp$ebnf$1$subexpression$1$macrocall$2",symbols:[{literal:":"},"IPv6_hex"]},{name:"IPv6v4_comp$ebnf$1$subexpression$1$macrocall$1",symbols:["IPv6v4_comp$ebnf$1$subexpression$1$macrocall$2","IPv6v4_comp$ebnf$1$subexpression$1$macrocall$2","IPv6v4_comp$ebnf$1$subexpression$1$macrocall$2"]},{name:"IPv6v4_comp$ebnf$1$subexpression$1",symbols:["IPv6_hex","IPv6v4_comp$ebnf$1$subexpression$1$macrocall$1"]},{name:"IPv6v4_comp$ebnf$1",symbols:["IPv6v4_comp$ebnf$1$subexpression$1"],postprocess:n},{name:"IPv6v4_comp$ebnf$1",symbols:[],postprocess:()=>null},{name:"IPv6v4_comp$string$1",symbols:[{literal:":"},{literal:":"}],postprocess:e=>e.join("")},{name:"IPv6v4_comp$ebnf$2$subexpression$1$macrocall$2",symbols:[{literal:":"},"IPv6_hex"]},{name:"IPv6v4_comp$ebnf$2$subexpression$1$macrocall$1",symbols:["IPv6v4_comp$ebnf$2$subexpression$1$macrocall$2","IPv6v4_comp$ebnf$2$subexpression$1$macrocall$2","IPv6v4_comp$ebnf$2$subexpression$1$macrocall$2"]},{name:"IPv6v4_comp$ebnf$2$subexpression$1",symbols:["IPv6_hex","IPv6v4_comp$ebnf$2$subexpression$1$macrocall$1",{literal:":"}]},{name:"IPv6v4_comp$ebnf$2",symbols:["IPv6v4_comp$ebnf$2$subexpression$1"],postprocess:n},{name:"IPv6v4_comp$ebnf$2",symbols:[],postprocess:()=>null},{name:"IPv6v4_comp",symbols:["IPv6v4_comp$ebnf$1","IPv6v4_comp$string$1","IPv6v4_comp$ebnf$2","IPv4_address_literal"]},{name:"DIGIT",symbols:[/[0-9]/],postprocess:n},{name:"ALPHA_DIGIT_U",symbols:[/[0-9A-Za-z\u0080-\uFFFF]/],postprocess:n},{name:"ALPHA_DIGIT",symbols:[/[0-9A-Za-z]/],postprocess:n},{name:"ALPHA_DIG_DASH",symbols:[/[-0-9A-Za-z]/],postprocess:n},{name:"ALPHA_DIG_DASH_U",symbols:[/[-0-9A-Za-z\u0080-\uFFFF]/],postprocess:n},{name:"HEXDIG",symbols:[/[0-9A-Fa-f]/],postprocess:n},{name:"DQUOTE",symbols:[{literal:'"'}],postprocess:n}],ParserStart:"Reverse_path"}},21391:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.canonicalize=t.canonicalize_quoted_string=t.normalize=t.normalize_dot_string=t.parse=void 0;let i=n(43614),s=r(n(62935));s.default.ParserStart="Mailbox";let o=i.Grammar.fromCompiled(s.default);function l(e){let t=new i.Parser(o);if(t.feed(e),1!==t.results.length)throw Error("address parsing failed: ambiguous grammar");return t.results[0]}function a(e){return(function(){let t=e.indexOf("+");return -1===t?e:e.substr(0,t)})().replace(/\./g,"").toLowerCase()}t.parse=l,t.normalize_dot_string=a;function u(e){let t=e.substr(1).substr(0,e.length-2).replace(/(?:\\(.))/g,"$1").replace(/(?:(["\\]))/g,"\\$1");return`"${t}"`}t.normalize=function(e){var t,n;let r=l(e),i=null!==(t=r.domainPart.AddressLiteral)&&void 0!==t?t:r.domainPart.DomainName.toLowerCase(),s=null!==(n=r.localPart.QuotedString)&&void 0!==n?n:a(r.localPart.DotString);return`${s}@${i}`},t.canonicalize_quoted_string=u;t.canonicalize=function(e){var t;let n=l(e),r=null!==(t=n.domainPart.AddressLiteral)&&void 0!==t?t:n.domainPart.DomainName.toLowerCase(),i=n.localPart.QuotedString?u(n.localPart.QuotedString):n.localPart.DotString;return`${i}@${r}`}},1170:function(e,t,n){!function(e){"use strict";e.exports.is_uri=n,e.exports.is_http_uri=r,e.exports.is_https_uri=i,e.exports.is_web_uri=s,e.exports.isUri=n,e.exports.isHttpUri=r,e.exports.isHttpsUri=i,e.exports.isWebUri=s;var t=function(e){return e.match(/(?:([^:\/?#]+):)?(?:\/\/([^\/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?/)};function n(e){if(!e||/[^a-z0-9\:\/\?\#\[\]\@\!\$\&\'\(\)\*\+\,\;\=\.\-\_\~\%]/i.test(e)||/%[^0-9a-f]/i.test(e)||/%[0-9a-f](:?[^0-9a-f]|$)/i.test(e))return;var n=[],r="",i="",s="",o="",l="",a="";if(r=(n=t(e))[1],i=n[2],s=n[3],o=n[4],l=n[5],!!(r&&r.length&&s.length>=0)){if(i&&i.length){if(!(0===s.length||/^\//.test(s)))return}else if(/^\/\//.test(s))return;if(/^[a-z][a-z0-9\+\-\.]*$/.test(r.toLowerCase()))return a+=r+":",i&&i.length&&(a+="//"+i),a+=s,o&&o.length&&(a+="?"+o),l&&l.length&&(a+="#"+l),a}}function r(e,r){if(!!n(e)){var i=[],s="",o="",l="",a="",u="",h="",c="";if(s=(i=t(e))[1],o=i[2],l=i[3],u=i[4],h=i[5],s){if(r){if("https"!=s.toLowerCase())return}else if("http"!=s.toLowerCase())return;if(!o)return;return/:(\d+)$/.test(o)&&(a=o.match(/:(\d+)$/)[0],o=o.replace(/:\d+$/,"")),c+=s+":"+("//"+o),a&&(c+=a),c+=l,u&&u.length&&(c+="?"+u),h&&h.length&&(c+="#"+h),c}}}function i(e){return r(e,!0)}function s(e){return r(e)||i(e)}}(e=n.nmd(e))},66203:function(e,t,n){"use strict";n.d(t,{f$:function(){return T},m8:function(){return b},wQ:function(){return eS}});var r=n(8954),i=n(76621),s=n(85237),o=n(7888);function l(e,t){return({state:n,dispatch:r})=>{if(n.readOnly)return!1;let i=e(t,n);return!!i&&(r(n.update(i)),!0)}}let a=l(function(e,t,n=t.selection.ranges){let r=[],i=-1;for(let{from:e,to:s}of n){let n=r.length,o=1e9,l=c(t,e).line;if(l){for(let n=e;n<=s;){let a=t.doc.lineAt(n);if(a.from>i&&(e==s||s>a.from)){i=a.from;let e=/^\s*/.exec(a.text)[0].length,t=e==a.length,n=a.text.slice(e,e+l.length)==l?e:-1;e<a.text.length&&e<o&&(o=e),r.push({line:a,comment:n,token:l,indent:e,empty:t,single:!1})}n=a.to+1}if(o<1e9)for(let e=n;e<r.length;e++)r[e].indent<r[e].line.text.length&&(r[e].indent=o);r.length==n+1&&(r[n].single=!0)}}if(2!=e&&r.some(e=>e.comment<0&&(!e.empty||e.single))){let e=[];for(let{line:t,token:n,indent:i,empty:s,single:o}of r)(o||!s)&&e.push({from:t.from+i,insert:n+" "});let n=t.changes(e);return{changes:n,selection:t.selection.map(n,1)}}if(1!=e&&r.some(e=>e.comment>=0)){let e=[];for(let{line:t,comment:n,token:i}of r)if(n>=0){let r=t.from+n,s=r+i.length;" "==t.text[s-t.from]&&s++,e.push({from:r,to:s})}return{changes:e}}return null},0),u=l(f,0),h=l((e,t)=>f(e,t,function(e){let t=[];for(let n of e.selection.ranges){let r=e.doc.lineAt(n.from),i=n.to<=r.to?r:e.doc.lineAt(n.to),s=t.length-1;s>=0&&t[s].to>r.from?t[s].to=i.to:t.push({from:r.from+/^\s*/.exec(r.text)[0].length,to:i.to})}return t}(t)),0);function c(e,t){let n=e.languageDataAt("commentTokens",t);return n.length?n[0]:{}}function f(e,t,n=t.selection.ranges){let r=n.map(e=>c(t,e.from).block);if(!r.every(e=>e))return null;let i=n.map((e,n)=>(function(e,{open:t,close:n},r,i){let s,o,l=e.sliceDoc(r-50,r),a=e.sliceDoc(i,i+50),u=/\s*$/.exec(l)[0].length,h=/^\s*/.exec(a)[0].length,c=l.length-u;if(l.slice(c-t.length,c)==t&&a.slice(h,h+n.length)==n)return{open:{pos:r-u,margin:u&&1},close:{pos:i+h,margin:h&&1}};i-r<=100?s=o=e.sliceDoc(r,i):(s=e.sliceDoc(r,r+50),o=e.sliceDoc(i-50,i));let f=/^\s*/.exec(s)[0].length,d=/\s*$/.exec(o)[0].length,p=o.length-d-n.length;return s.slice(f,f+t.length)==t&&o.slice(p,p+n.length)==n?{open:{pos:r+f+t.length,margin:/\s/.test(s.charAt(f+t.length))?1:0},close:{pos:i-d-n.length,margin:/\s/.test(o.charAt(p-1))?1:0}}:null})(t,r[n],e.from,e.to));if(2!=e&&!i.every(e=>e))return{changes:t.changes(n.map((e,t)=>i[t]?[]:[{from:e.from,insert:r[t].open+" "},{from:e.to,insert:" "+r[t].close}]))};if(1!=e&&i.some(e=>e)){let e=[];for(let t=0,n;t<i.length;t++)if(n=i[t]){let i=r[t],{open:s,close:o}=n;e.push({from:s.pos-i.open.length,to:s.pos+s.margin},{from:o.pos-o.margin,to:o.pos+i.close.length})}return{changes:e}}return null}let d=r.q6.define(),p=r.q6.define(),m=r.r$.define(),g=r.r$.define({combine:e=>(0,r.BO)(e,{minDepth:100,newGroupDelay:500,joinToEvent:(e,t)=>t},{minDepth:Math.max,newGroupDelay:Math.min,joinToEvent:(e,t)=>(n,r)=>e(n,r)||t(n,r)})}),y=r.QQ.define({create:()=>P.empty,update(e,t){let n=t.state.facet(g),i=t.annotation(d);if(i){let r=x.fromTransaction(t,i.selection),s=i.side,o=0==s?e.undone:e.done;return o=r?C(o,o.length,n.minDepth,r):_(o,t.startState.selection),new P(0==s?i.rest:o,0==s?o:i.rest)}let s=t.annotation(p);if(("full"==s||"before"==s)&&(e=e.isolate()),!1===t.annotation(r.YW.addToHistory))return t.changes.empty?e:e.addMapping(t.changes.desc);let o=x.fromTransaction(t),l=t.annotation(r.YW.time),a=t.annotation(r.YW.userEvent);return o?e=e.addChanges(o,l,a,n,t):t.selection&&(e=e.addSelection(t.startState.selection,l,a,n.newGroupDelay)),("full"==s||"after"==s)&&(e=e.isolate()),e},toJSON:e=>({done:e.done.map(e=>e.toJSON()),undone:e.undone.map(e=>e.toJSON())}),fromJSON:e=>new P(e.done.map(x.fromJSON),e.undone.map(x.fromJSON))});function b(e={}){return[y,g.of(e),i.tk.domEventHandlers({beforeinput(e,t){let n="historyUndo"==e.inputType?k:"historyRedo"==e.inputType?w:null;return!!n&&(e.preventDefault(),n(t))}})]}function v(e,t){return function({state:n,dispatch:r}){if(!t&&n.readOnly)return!1;let i=n.field(y,!1);if(!i)return!1;let s=i.pop(e,n,t);return!!s&&(r(s),!0)}}let k=v(0,!1),w=v(1,!1),D=v(0,!0),A=v(1,!0);class x{constructor(e,t,n,r,i){this.changes=e,this.effects=t,this.mapped=n,this.startSelection=r,this.selectionsAfter=i}setSelAfter(e){return new x(this.changes,this.effects,this.mapped,this.startSelection,e)}toJSON(){var e,t,n;return{changes:null===(e=this.changes)||void 0===e?void 0:e.toJSON(),mapped:null===(t=this.mapped)||void 0===t?void 0:t.toJSON(),startSelection:null===(n=this.startSelection)||void 0===n?void 0:n.toJSON(),selectionsAfter:this.selectionsAfter.map(e=>e.toJSON())}}static fromJSON(e){return new x(e.changes&&r.as.fromJSON(e.changes),[],e.mapped&&r.n0.fromJSON(e.mapped),e.startSelection&&r.jT.fromJSON(e.startSelection),e.selectionsAfter.map(r.jT.fromJSON))}static fromTransaction(e,t){let n=S;for(let t of e.startState.facet(m)){let r=t(e);r.length&&(n=n.concat(r))}return!n.length&&e.changes.empty?null:new x(e.changes.invert(e.startState.doc),n,void 0,t||e.startState.selection,S)}static selection(e){return new x(void 0,S,void 0,void 0,e)}}function C(e,t,n,r){let i=e.slice(t+1>n+20?t-n-1:0,t);return i.push(r),i}function E(e,t){return e.length?t.length?e.concat(t):e:t}let S=[];function _(e,t){if(!e.length)return[x.selection([t])];{let n=e[e.length-1],r=n.selectionsAfter.slice(Math.max(0,n.selectionsAfter.length-200));return r.length&&r[r.length-1].eq(t)?e:(r.push(t),C(e,e.length-1,1e9,n.setSelAfter(r)))}}function O(e,t){if(!e.length)return e;let n=e.length,i=S;for(;n;){let s=function(e,t,n){let i=E(e.selectionsAfter.length?e.selectionsAfter.map(e=>e.map(t)):S,n);if(!e.changes)return x.selection(i);let s=e.changes.map(t),o=t.mapDesc(e.changes,!0),l=e.mapped?e.mapped.composeDesc(o):o;return new x(s,r.Py.mapEffects(e.effects,t),l,e.startSelection.map(o),i)}(e[n-1],t,i);if(s.changes&&!s.changes.empty||s.effects.length){let t=e.slice(0,n);return t[n-1]=s,t}t=s.mapped,n--,i=s.selectionsAfter}return i.length?[x.selection(i)]:S}let F=/^(input\.type|delete)($|\.)/;class P{constructor(e,t,n=0,r){this.done=e,this.undone=t,this.prevTime=n,this.prevUserEvent=r}isolate(){return this.prevTime?new P(this.done,this.undone):this}addChanges(e,t,n,r,i){var s,o;let l,a,u=this.done,h=u[u.length-1];if(h&&h.changes&&!h.changes.empty&&e.changes&&(!n||F.test(n))&&(!h.selectionsAfter.length&&t-this.prevTime<r.newGroupDelay&&r.joinToEvent(i,(s=h.changes,o=e.changes,l=[],a=!1,s.iterChangedRanges((e,t)=>l.push(e,t)),o.iterChangedRanges((e,t,n,r)=>{for(let e=0;e<l.length;){let t=l[e++],i=l[e++];r>=t&&n<=i&&(a=!0)}}),a))||"input.type.compose"==n))u=C(u,u.length-1,r.minDepth,new x(e.changes.compose(h.changes),E(e.effects,h.effects),h.mapped,h.startSelection,S));else u=C(u,u.length,r.minDepth,e);return new P(u,S,t,n)}addSelection(e,t,n,r){var i,s;let o=this.done.length?this.done[this.done.length-1].selectionsAfter:S;return o.length>0&&t-this.prevTime<r&&n==this.prevUserEvent&&n&&/^select($|\.)/.test(n)&&(i=o[o.length-1],s=e,i.ranges.length==s.ranges.length&&0===i.ranges.filter((e,t)=>e.empty!=s.ranges[t].empty).length)?this:new P(_(this.done,e),this.undone,t,n)}addMapping(e){return new P(O(this.done,e),O(this.undone,e),this.prevTime,this.prevUserEvent)}pop(e,t,n){let r=0==e?this.done:this.undone;if(0==r.length)return null;let i=r[r.length-1],s=i.selectionsAfter[0]||t.selection;if(n&&i.selectionsAfter.length){var o;let n,l;return t.update({selection:i.selectionsAfter[i.selectionsAfter.length-1],annotations:d.of({side:e,rest:(n=(o=r)[o.length-1],(l=o.slice())[o.length-1]=n.setSelAfter(n.selectionsAfter.slice(0,n.selectionsAfter.length-1)),l),selection:s}),userEvent:0==e?"select.undo":"select.redo",scrollIntoView:!0})}if(!i.changes)return null;{let n=1==r.length?S:r.slice(0,r.length-1);return i.mapped&&(n=O(n,i.mapped)),t.update({changes:i.changes,selection:i.startSelection,effects:i.effects,annotations:d.of({side:e,rest:n,selection:s}),filter:!1,userEvent:0==e?"undo":"redo",scrollIntoView:!0})}}}P.empty=new P(S,S);let T=[{key:"Mod-z",run:k,preventDefault:!0},{key:"Mod-y",mac:"Mod-Shift-z",run:w,preventDefault:!0},{linux:"Ctrl-Shift-z",run:w,preventDefault:!0},{key:"Mod-u",run:D,preventDefault:!0},{key:"Alt-u",mac:"Mod-Shift-u",run:A,preventDefault:!0}];function N(e,t){return r.jT.create(e.ranges.map(t),e.mainIndex)}function B(e,t){return e.update({selection:t,scrollIntoView:!0,userEvent:"select"})}function I({state:e,dispatch:t},n){let r=N(e.selection,n);return!r.eq(e.selection,!0)&&(t(B(e,r)),!0)}function M(e,t){return r.jT.cursor(t?e.to:e.from)}function $(e,t){return I(e,n=>n.empty?e.moveByChar(n,t):M(n,t))}function L(e){return e.textDirectionAt(e.state.selection.main.head)==i.Nm.LTR}let R=e=>$(e,!L(e)),j=e=>$(e,L(e));function q(e,t){return I(e,n=>n.empty?e.moveByGroup(n,t):M(n,t))}"undefined"!=typeof Intl&&Intl.Segmenter;function V(e,t,n){let i,l,a=(0,s.qz)(e).resolveInner(t.head),u=n?o.md.closedBy:o.md.openedBy;for(let r=t.head;;){let t=n?a.childAfter(r):a.childBefore(r);if(!t)break;(function(e,t,n){if(t.type.prop(n))return!0;let r=t.to-t.from;return r&&(r>2||/[^\s,.;:]/.test(e.sliceDoc(t.from,t.to)))||t.firstChild})(e,t,u)?a=t:r=n?t.to:t.from}return l=a.type.prop(u)&&(i=n?(0,s.Um)(e,a.from,1):(0,s.Um)(e,a.to,-1))&&i.matched?n?i.end.to:i.end.from:n?a.to:a.from,r.jT.cursor(l,n?-1:1)}function z(e,t){return I(e,n=>{if(!n.empty)return M(n,t);let r=e.moveVertically(n,t);return r.head!=n.head?r:e.moveToLineBoundary(n,t)})}let U=e=>z(e,!1),H=e=>z(e,!0);function W(e){let t=e.scrollDOM.clientHeight<e.scrollDOM.scrollHeight-2,n=0,r=0,s;if(t){for(let t of e.state.facet(i.tk.scrollMargins)){let i=t(e);(null==i?void 0:i.top)&&(n=Math.max(null==i?void 0:i.top,n)),(null==i?void 0:i.bottom)&&(r=Math.max(null==i?void 0:i.bottom,r))}s=e.scrollDOM.clientHeight-n-r}else s=(e.dom.ownerDocument.defaultView||window).innerHeight;return{marginTop:n,marginBottom:r,selfScroll:t,height:Math.max(e.defaultLineHeight,s-5)}}function G(e,t){let n,r=W(e),{state:s}=e,o=N(s.selection,n=>n.empty?e.moveVertically(n,t,r.height):M(n,t));if(o.eq(s.selection))return!1;if(r.selfScroll){let t=e.coordsAtPos(s.selection.main.head),l=e.scrollDOM.getBoundingClientRect(),a=l.top+r.marginTop,u=l.bottom-r.marginBottom;t&&t.top>a&&t.bottom<u&&(n=i.tk.scrollIntoView(o.main.head,{y:"start",yMargin:t.top-a}))}return e.dispatch(B(s,o),{effects:n}),!0}let K=e=>G(e,!1),J=e=>G(e,!0);function Q(e,t,n){let i=e.lineBlockAt(t.head),s=e.moveToLineBoundary(t,n);if(s.head==t.head&&s.head!=(n?i.to:i.from)&&(s=e.moveToLineBoundary(t,n,!1)),!n&&s.head==i.from&&i.length){let n=/^\s*/.exec(e.state.sliceDoc(i.from,Math.min(i.from+100,i.to)))[0].length;n&&t.head!=i.from+n&&(s=r.jT.cursor(i.from+n))}return s}function Y(e,t){let n=N(e.state.selection,e=>{let n=t(e);return r.jT.range(e.anchor,n.head,n.goalColumn,n.bidiLevel||void 0)});return!n.eq(e.state.selection)&&(e.dispatch(B(e.state,n)),!0)}function Z(e,t){return Y(e,n=>e.moveByChar(n,t))}let X=e=>Z(e,!L(e)),ee=e=>Z(e,L(e));function et(e,t){return Y(e,n=>e.moveByGroup(n,t))}function en(e,t){return Y(e,n=>e.moveVertically(n,t))}let er=e=>en(e,!1),ei=e=>en(e,!0);function es(e,t){return Y(e,n=>e.moveVertically(n,t,W(e).height))}let eo=e=>es(e,!1),el=e=>es(e,!0),ea=({state:e,dispatch:t})=>(t(B(e,{anchor:0})),!0),eu=({state:e,dispatch:t})=>(t(B(e,{anchor:e.doc.length})),!0),eh=({state:e,dispatch:t})=>(t(B(e,{anchor:e.selection.main.anchor,head:0})),!0),ec=({state:e,dispatch:t})=>(t(B(e,{anchor:e.selection.main.anchor,head:e.doc.length})),!0);function ef(e,t){if(e.state.readOnly)return!1;let n="delete.selection",{state:s}=e,o=s.changeByRange(i=>{let{from:s,to:o}=i;if(s==o){let r=t(i);r<s?(n="delete.backward",r=ed(e,r,!1)):r>s&&(n="delete.forward",r=ed(e,r,!0)),s=Math.min(s,r),o=Math.max(o,r)}else s=ed(e,s,!1),o=ed(e,o,!0);return s==o?{range:i}:{changes:{from:s,to:o},range:r.jT.cursor(s,s<i.head?-1:1)}});return!o.changes.empty&&(e.dispatch(s.update(o,{scrollIntoView:!0,userEvent:n,effects:"delete.selection"==n?i.tk.announce.of(s.phrase("Selection deleted")):void 0})),!0)}function ed(e,t,n){if(e instanceof i.tk)for(let r of e.state.facet(i.tk.atomicRanges).map(t=>t(e)))r.between(t,t,(e,r)=>{e<t&&r>t&&(t=n?r:e)});return t}let ep=(e,t,n)=>ef(e,i=>{let o=i.from,{state:l}=e,a=l.doc.lineAt(o),u,h;if(n&&!t&&o>a.from&&o<a.from+200&&!/[^ \t]/.test(u=a.text.slice(0,o-a.from))){if(" "==u[u.length-1])return o-1;let e=(0,r.IS)(u,l.tabSize)%(0,s.y1)(l)||(0,s.y1)(l);for(let t=0;t<e&&" "==u[u.length-1-t];t++)o--;h=o}else(h=(0,r.cp)(a.text,o-a.from,t,t)+a.from)==o&&a.number!=(t?l.doc.lines:1)?h+=t?1:-1:!t&&/[\ufe00-\ufe0f]/.test(a.text.slice(h-a.from,o-a.from))&&(h=(0,r.cp)(a.text,h-a.from,!1,!1)+a.from);return h}),em=e=>ep(e,!1,!0),eg=e=>ep(e,!0,!1),ey=(e,t)=>ef(e,n=>{let i=n.head,{state:s}=e,o=s.doc.lineAt(i),l=s.charCategorizer(i);for(let e=null;;){if(i==(t?o.to:o.from)){i==n.head&&o.number!=(t?s.doc.lines:1)&&(i+=t?1:-1);break}let a=(0,r.cp)(o.text,i-o.from,t)+o.from,u=o.text.slice(Math.min(i,a)-o.from,Math.max(i,a)-o.from),h=l(u);if(null!=e&&h!=e)break;(" "!=u||i!=n.head)&&(e=h),i=a}return i}),eb=e=>ey(e,!1);function ev(e){let t=[],n=-1;for(let r of e.selection.ranges){let i=e.doc.lineAt(r.from),s=e.doc.lineAt(r.to);if(!r.empty&&r.to==s.from&&(s=e.doc.lineAt(r.to-1)),n>=i.number){let e=t[t.length-1];e.to=s.to,e.ranges.push(r)}else t.push({from:i.from,to:s.to,ranges:[r]});n=s.number+1}return t}function ek(e,t,n){if(e.readOnly)return!1;let i=[],s=[];for(let t of ev(e)){if(n?t.to==e.doc.length:0==t.from)continue;let o=e.doc.lineAt(n?t.to+1:t.from-1),l=o.length+1;if(n)for(let n of(i.push({from:t.to,to:o.to},{from:t.from,insert:o.text+e.lineBreak}),t.ranges))s.push(r.jT.range(Math.min(e.doc.length,n.anchor+l),Math.min(e.doc.length,n.head+l)));else for(let n of(i.push({from:o.from,to:t.from},{from:t.to,insert:e.lineBreak+o.text}),t.ranges))s.push(r.jT.range(n.anchor-l,n.head-l))}return!!i.length&&(t(e.update({changes:i,scrollIntoView:!0,selection:r.jT.create(s,e.selection.mainIndex),userEvent:"move.line"})),!0)}function ew(e,t,n){if(e.readOnly)return!1;let r=[];for(let t of ev(e))n?r.push({from:t.from,insert:e.doc.slice(t.from,t.to)+e.lineBreak}):r.push({from:t.to,insert:e.lineBreak+e.doc.slice(t.from,t.to)});return t(e.update({changes:r,scrollIntoView:!0,userEvent:"input.copyline"})),!0}let eD=ex(!1),eA=ex(!0);function ex(e){return({state:t,dispatch:n})=>{if(t.readOnly)return!1;let i=t.changeByRange(n=>{let{from:i,to:l}=n,a=t.doc.lineAt(i),u=!e&&i==l&&function(e,t){if(/\(\)|\[\]|\{\}/.test(e.sliceDoc(t-1,t+1)))return{from:t,to:t};let n=(0,s.qz)(e).resolveInner(t),r=n.childBefore(t),i=n.childAfter(t),l;return r&&i&&r.to<=t&&i.from>=t&&(l=r.type.prop(o.md.closedBy))&&l.indexOf(i.name)>-1&&e.doc.lineAt(r.to).from==e.doc.lineAt(i.from).from&&!/\S/.test(e.sliceDoc(r.to,i.from))?{from:r.to,to:i.from}:null}(t,i);e&&(i=l=(l<=a.to?a:t.doc.lineAt(l)).to);let h=new s.Gn(t,{simulateBreak:i,simulateDoubleBreak:!!u}),c=(0,s.K0)(h,i);for(null==c&&(c=(0,r.IS)(/^\s*/.exec(t.doc.lineAt(i).text)[0],t.tabSize));l<a.to&&/\s/.test(a.text[l-a.from]);)l++;u?{from:i,to:l}=u:i>a.from&&i<a.from+100&&!/\S/.test(a.text.slice(0,i))&&(i=a.from);let f=["",(0,s.SS)(t,c)];return u&&f.push((0,s.SS)(t,h.lineIndent(a.from,-1))),{changes:{from:i,to:l,insert:r.xv.of(f)},range:r.jT.cursor(i+1+f[1].length)}});return n(t.update(i,{scrollIntoView:!0,userEvent:"input"})),!0}}function eC(e,t){let n=-1;return e.changeByRange(i=>{let s=[];for(let r=i.from;r<=i.to;){let o=e.doc.lineAt(r);o.number>n&&(i.empty||i.to>o.from)&&(t(o,s,i),n=o.number),r=o.to+1}let o=e.changes(s);return{changes:s,range:r.jT.range(o.mapPos(i.anchor,1),o.mapPos(i.head,1))}})}let eE=[{key:"Ctrl-b",run:R,shift:X,preventDefault:!0},{key:"Ctrl-f",run:j,shift:ee},{key:"Ctrl-p",run:U,shift:er},{key:"Ctrl-n",run:H,shift:ei},{key:"Ctrl-a",run:e=>I(e,t=>r.jT.cursor(e.lineBlockAt(t.head).from,1)),shift:e=>Y(e,t=>r.jT.cursor(e.lineBlockAt(t.head).from))},{key:"Ctrl-e",run:e=>I(e,t=>r.jT.cursor(e.lineBlockAt(t.head).to,-1)),shift:e=>Y(e,t=>r.jT.cursor(e.lineBlockAt(t.head).to))},{key:"Ctrl-d",run:eg},{key:"Ctrl-h",run:em},{key:"Ctrl-k",run:e=>ef(e,t=>{let n=e.lineBlockAt(t.head).to;return t.head<n?n:Math.min(e.state.doc.length,t.head+1)})},{key:"Ctrl-Alt-h",run:eb},{key:"Ctrl-o",run:({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=e.changeByRange(e=>({changes:{from:e.from,to:e.to,insert:r.xv.of(["",""])},range:r.jT.cursor(e.from)}));return t(e.update(n,{scrollIntoView:!0,userEvent:"input"})),!0}},{key:"Ctrl-t",run:({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=e.changeByRange(t=>{if(!t.empty||0==t.from||t.from==e.doc.length)return{range:t};let n=t.from,i=e.doc.lineAt(n),s=n==i.from?n-1:(0,r.cp)(i.text,n-i.from,!1)+i.from,o=n==i.to?n+1:(0,r.cp)(i.text,n-i.from,!0)+i.from;return{changes:{from:s,to:o,insert:e.doc.slice(n,o).append(e.doc.slice(s,n))},range:r.jT.cursor(o)}});return!n.changes.empty&&(t(e.update(n,{scrollIntoView:!0,userEvent:"move.character"})),!0)}},{key:"Ctrl-v",run:J}],eS=[{key:"Alt-ArrowLeft",mac:"Ctrl-ArrowLeft",run:e=>I(e,t=>V(e.state,t,!L(e))),shift:e=>Y(e,t=>V(e.state,t,!L(e)))},{key:"Alt-ArrowRight",mac:"Ctrl-ArrowRight",run:e=>I(e,t=>V(e.state,t,L(e))),shift:e=>Y(e,t=>V(e.state,t,L(e)))},{key:"Alt-ArrowUp",run:({state:e,dispatch:t})=>ek(e,t,!1)},{key:"Shift-Alt-ArrowUp",run:({state:e,dispatch:t})=>ew(e,t,!1)},{key:"Alt-ArrowDown",run:({state:e,dispatch:t})=>ek(e,t,!0)},{key:"Shift-Alt-ArrowDown",run:({state:e,dispatch:t})=>ew(e,t,!0)},{key:"Escape",run:({state:e,dispatch:t})=>{let n=e.selection,i=null;return n.ranges.length>1?i=r.jT.create([n.main]):!n.main.empty&&(i=r.jT.create([r.jT.cursor(n.main.head)])),!!i&&(t(B(e,i)),!0)}},{key:"Mod-Enter",run:eA},{key:"Alt-l",mac:"Ctrl-l",run:({state:e,dispatch:t})=>{let n=ev(e).map(({from:t,to:n})=>r.jT.range(t,Math.min(n+1,e.doc.length)));return t(e.update({selection:r.jT.create(n),userEvent:"select"})),!0}},{key:"Mod-i",run:({state:e,dispatch:t})=>{let n=N(e.selection,t=>{var n;let i=(0,s.qz)(e).resolveStack(t.from,1);for(let e=i;e;e=e.next){let{node:i}=e;if((i.from<t.from&&i.to>=t.to||i.to>t.to&&i.from<=t.from)&&(null===(n=i.parent)||void 0===n?void 0:n.parent))return r.jT.range(i.to,i.from)}return t});return t(B(e,n)),!0},preventDefault:!0},{key:"Mod-[",run:({state:e,dispatch:t})=>!e.readOnly&&(t(e.update(eC(e,(t,n)=>{let i=/^\s*/.exec(t.text)[0];if(!i)return;let o=(0,r.IS)(i,e.tabSize),l=0,a=(0,s.SS)(e,Math.max(0,o-(0,s.y1)(e)));for(;l<i.length&&l<a.length&&i.charCodeAt(l)==a.charCodeAt(l);)l++;n.push({from:t.from+l,to:t.from+i.length,insert:a.slice(l)})}),{userEvent:"delete.dedent"})),!0)},{key:"Mod-]",run:({state:e,dispatch:t})=>!e.readOnly&&(t(e.update(eC(e,(t,n)=>{n.push({from:t.from,insert:e.facet(s.c)})}),{userEvent:"input.indent"})),!0)},{key:"Mod-Alt-\\",run:({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=Object.create(null),r=new s.Gn(e,{overrideIndentation:e=>{let t=n[e];return null==t?-1:t}}),i=eC(e,(t,i,o)=>{let l=(0,s.K0)(r,t.from);if(null==l)return;!/\S/.test(t.text)&&(l=0);let a=/^\s*/.exec(t.text)[0],u=(0,s.SS)(e,l);(a!=u||o.from<t.from+a.length)&&(n[t.from]=l,i.push({from:t.from,to:t.from+a.length,insert:u}))});return!i.changes.empty&&t(e.update(i,{userEvent:"indent"})),!0}},{key:"Shift-Mod-k",run:e=>{if(e.state.readOnly)return!1;let{state:t}=e,n=t.changes(ev(t).map(({from:e,to:n})=>(e>0?e--:n<t.doc.length&&n++,{from:e,to:n}))),r=N(t.selection,t=>{let n;if(e.lineWrapping){let r=e.lineBlockAt(t.head),i=e.coordsAtPos(t.head,t.assoc||1);i&&(n=r.bottom+e.documentTop-i.bottom+e.defaultLineHeight/2)}return e.moveVertically(t,!0,n)}).map(n);return e.dispatch({changes:n,selection:r,scrollIntoView:!0,userEvent:"delete.line"}),!0}},{key:"Shift-Mod-\\",run:({state:e,dispatch:t})=>{var n,i,o;let l,a;return n=e,i=t,o=!1,l=!1,a=N(n.selection,e=>{let t=(0,s.Um)(n,e.head,-1)||(0,s.Um)(n,e.head,1)||e.head>0&&(0,s.Um)(n,e.head-1,1)||e.head<n.doc.length&&(0,s.Um)(n,e.head+1,-1);if(!t||!t.end)return e;l=!0;let i=t.start.from==e.head?t.end.to:t.end.from;return o?r.jT.range(e.anchor,i):r.jT.cursor(i)}),!!l&&(i(B(n,a)),!0)}},{key:"Mod-/",run:e=>{let{state:t}=e,n=t.doc.lineAt(t.selection.main.from),r=c(e.state,n.from);return r.line?a(e):!!r.block&&h(e)}},{key:"Alt-A",run:u}].concat([{key:"ArrowLeft",run:R,shift:X,preventDefault:!0},{key:"Mod-ArrowLeft",mac:"Alt-ArrowLeft",run:e=>q(e,!L(e)),shift:e=>et(e,!L(e)),preventDefault:!0},{mac:"Cmd-ArrowLeft",run:e=>I(e,t=>Q(e,t,!L(e))),shift:e=>Y(e,t=>Q(e,t,!L(e))),preventDefault:!0},{key:"ArrowRight",run:j,shift:ee,preventDefault:!0},{key:"Mod-ArrowRight",mac:"Alt-ArrowRight",run:e=>q(e,L(e)),shift:e=>et(e,L(e)),preventDefault:!0},{mac:"Cmd-ArrowRight",run:e=>I(e,t=>Q(e,t,L(e))),shift:e=>Y(e,t=>Q(e,t,L(e))),preventDefault:!0},{key:"ArrowUp",run:U,shift:er,preventDefault:!0},{mac:"Cmd-ArrowUp",run:ea,shift:eh},{mac:"Ctrl-ArrowUp",run:K,shift:eo},{key:"ArrowDown",run:H,shift:ei,preventDefault:!0},{mac:"Cmd-ArrowDown",run:eu,shift:ec},{mac:"Ctrl-ArrowDown",run:J,shift:el},{key:"PageUp",run:K,shift:eo},{key:"PageDown",run:J,shift:el},{key:"Home",run:e=>I(e,t=>Q(e,t,!1)),shift:e=>Y(e,t=>Q(e,t,!1)),preventDefault:!0},{key:"Mod-Home",run:ea,shift:eh},{key:"End",run:e=>I(e,t=>Q(e,t,!0)),shift:e=>Y(e,t=>Q(e,t,!0)),preventDefault:!0},{key:"Mod-End",run:eu,shift:ec},{key:"Enter",run:eD},{key:"Mod-a",run:({state:e,dispatch:t})=>(t(e.update({selection:{anchor:0,head:e.doc.length},userEvent:"select"})),!0)},{key:"Backspace",run:em,shift:em},{key:"Delete",run:eg},{key:"Mod-Backspace",mac:"Alt-Backspace",run:eb},{key:"Mod-Delete",mac:"Alt-Delete",run:e=>ey(e,!0)},{mac:"Mod-Backspace",run:e=>ef(e,t=>{let n=e.moveToLineBoundary(t,!1).head;return t.head>n?n:Math.max(0,t.head-1)})},{mac:"Mod-Delete",run:e=>ef(e,t=>{let n=e.moveToLineBoundary(t,!0).head;return t.head<n?n:Math.min(e.state.doc.length,t.head+1)})}].concat(eE.map(e=>({mac:e.key,run:e.run,shift:e.shift}))))},85237:function(e,t,n){"use strict";n.d(t,{Dv:function(){return R},Gn:function(){return F},K0:function(){return O},Qf:function(){return eo},SS:function(){return _},Um:function(){return eA},c:function(){return E},e7:function(){return J},mi:function(){return ei},n$:function(){return ev},nF:function(){return eh},nY:function(){return M},qp:function(){return d},qz:function(){return p},ri:function(){return x},tC:function(){return I},uj:function(){return P},x0:function(){return L},y1:function(){return S}});var r,i=n(7888),s=n(8954),o=n(76621),l=n(42367),a=n(81965);let u=new i.md,h=new i.md;class c{constructor(e,t,n=[],r=""){this.data=e,this.name=r,!s.yy.prototype.hasOwnProperty("tree")&&Object.defineProperty(s.yy.prototype,"tree",{get(){return p(this)}}),this.parser=t,this.extension=[A.of(this),s.yy.languageData.of((e,t,n)=>{let r=f(e,t,n),i=r.type.prop(u);if(!i)return[];let s=e.facet(i),o=r.type.prop(h);if(o){let i=r.resolve(t-r.from,n);for(let t of o)if(t.test(i,e)){let n=e.facet(t.facet);return"replace"==t.type?n:n.concat(s)}}return s})].concat(n)}isActiveAt(e,t,n=-1){return f(e,t,n).type.prop(u)==this.data}findRegions(e){let t=e.facet(A);if((null==t?void 0:t.data)==this.data)return[{from:0,to:e.doc.length}];if(!t||!t.allowsNesting)return[];let n=[],r=(e,t)=>{if(e.prop(u)==this.data){n.push({from:t,to:t+e.length});return}let s=e.prop(i.md.mounted);if(s){if(s.tree.prop(u)==this.data){if(s.overlay)for(let e of s.overlay)n.push({from:e.from+t,to:e.to+t});else n.push({from:t,to:t+e.length});return}if(s.overlay){let e=n.length;if(r(s.tree,s.overlay[0].from+t),n.length>e)return}}for(let n=0;n<e.children.length;n++){let s=e.children[n];s instanceof i.mp&&r(s,e.positions[n]+t)}};return r(p(e),0),n}get allowsNesting(){return!0}}function f(e,t,n){let r=e.facet(A),s=p(e).topNode;if(!r||r.allowsNesting)for(let e=s;e;e=e.enter(t,n,i.vj.ExcludeBuffers))e.type.isTop&&(s=e);return s}c.setState=s.Py.define();class d extends c{constructor(e,t,n){super(e,t,[],n),this.parser=t}static define(e){var t;let n=(t=e.languageData,s.r$.define({combine:t?e=>e.concat(t):void 0}));return new d(n,e.parser.configure({props:[u.add(e=>e.isTop?n:void 0)]}),e.name)}configure(e,t){return new d(this.data,this.parser.configure(e),t||this.name)}get allowsNesting(){return this.parser.hasWrappers()}}function p(e){let t=e.field(c.state,!1);return t?t.tree:i.mp.empty}class m{constructor(e){this.doc=e,this.cursorPos=0,this.string="",this.cursor=e.iter()}get length(){return this.doc.length}syncTo(e){return this.string=this.cursor.next(e-this.cursorPos).value,this.cursorPos=e+this.string.length,this.cursorPos-this.string.length}chunk(e){return this.syncTo(e),this.string}get lineChunks(){return!0}read(e,t){let n=this.cursorPos-this.string.length;return e<n||t>=this.cursorPos?this.doc.sliceString(e,t):this.string.slice(e-n,t-n)}}let g=null;class y{constructor(e,t,n=[],r,i,s,o,l){this.parser=e,this.state=t,this.fragments=n,this.tree=r,this.treeLen=i,this.viewport=s,this.skipped=o,this.scheduleOn=l,this.parse=null,this.tempSkipped=[]}static create(e,t,n){return new y(e,t,[],i.mp.empty,0,n,[],null)}startParse(){return this.parser.startParse(new m(this.state.doc),this.fragments)}work(e,t){return(null!=t&&t>=this.state.doc.length&&(t=void 0),this.tree!=i.mp.empty&&this.isDone(null!=t?t:this.state.doc.length))?(this.takeTree(),!0):this.withContext(()=>{var n;if("number"==typeof e){let t=Date.now()+e;e=()=>Date.now()>t}for(!this.parse&&(this.parse=this.startParse()),null!=t&&(null==this.parse.stoppedAt||this.parse.stoppedAt>t)&&t<this.state.doc.length&&this.parse.stopAt(t);;){let r=this.parse.advance();if(r){if(this.fragments=this.withoutTempSkipped(i.i9.addTree(r,this.fragments,null!=this.parse.stoppedAt)),this.treeLen=null!==(n=this.parse.stoppedAt)&&void 0!==n?n:this.state.doc.length,this.tree=r,this.parse=null,!(this.treeLen<(null!=t?t:this.state.doc.length)))return!0;this.parse=this.startParse()}if(e())return!1}})}takeTree(){let e,t;this.parse&&(e=this.parse.parsedPos)>=this.treeLen&&((null==this.parse.stoppedAt||this.parse.stoppedAt>e)&&this.parse.stopAt(e),this.withContext(()=>{for(;!(t=this.parse.advance()););}),this.treeLen=e,this.tree=t,this.fragments=this.withoutTempSkipped(i.i9.addTree(this.tree,this.fragments,!0)),this.parse=null)}withContext(e){let t=g;g=this;try{return e()}finally{g=t}}withoutTempSkipped(e){for(let t;t=this.tempSkipped.pop();)e=b(e,t.from,t.to);return e}changes(e,t){let{fragments:n,tree:r,treeLen:s,viewport:o,skipped:l}=this;if(this.takeTree(),!e.empty){let t=[];if(e.iterChangedRanges((e,n,r,i)=>t.push({fromA:e,toA:n,fromB:r,toB:i})),n=i.i9.applyChanges(n,t),r=i.mp.empty,s=0,o={from:e.mapPos(o.from,-1),to:e.mapPos(o.to,1)},this.skipped.length)for(let t of(l=[],this.skipped)){let n=e.mapPos(t.from,1),r=e.mapPos(t.to,-1);n<r&&l.push({from:n,to:r})}}return new y(this.parser,t,n,r,s,o,l,this.scheduleOn)}updateViewport(e){if(this.viewport.from==e.from&&this.viewport.to==e.to)return!1;this.viewport=e;let t=this.skipped.length;for(let t=0;t<this.skipped.length;t++){let{from:n,to:r}=this.skipped[t];n<e.to&&r>e.from&&(this.fragments=b(this.fragments,n,r),this.skipped.splice(t--,1))}return!(this.skipped.length>=t)&&(this.reset(),!0)}reset(){this.parse&&(this.takeTree(),this.parse=null)}skipUntilInView(e,t){this.skipped.push({from:e,to:t})}static getSkippingParser(e){return new class extends i._b{createParse(t,n,r){let s=r[0].from,o=r[r.length-1].to;return{parsedPos:s,advance(){let t=g;if(t){for(let e of r)t.tempSkipped.push(e);e&&(t.scheduleOn=t.scheduleOn?Promise.all([t.scheduleOn,e]):e)}return this.parsedPos=o,new i.mp(i.Jq.none,[],[],o-s)},stoppedAt:null,stopAt(){}}}}}isDone(e){e=Math.min(e,this.state.doc.length);let t=this.fragments;return this.treeLen>=e&&t.length&&0==t[0].from&&t[0].to>=e}static get(){return g}}function b(e,t,n){return i.i9.applyChanges(e,[{fromA:t,toA:n,fromB:t,toB:n}])}class v{constructor(e){this.context=e,this.tree=e.tree}apply(e){if(!e.docChanged&&this.tree==this.context.tree)return this;let t=this.context.changes(e.changes,e.state),n=this.context.treeLen==e.startState.doc.length?void 0:Math.max(e.changes.mapPos(this.context.treeLen),t.viewport.to);return!t.work(20,n)&&t.takeTree(),new v(t)}static init(e){let t=Math.min(3e3,e.doc.length),n=y.create(e.facet(A).parser,e,{from:0,to:t});return!n.work(20,t)&&n.takeTree(),new v(n)}}c.state=s.QQ.define({create:v.init,update(e,t){for(let e of t.effects)if(e.is(c.setState))return e.value;return t.startState.facet(A)!=t.state.facet(A)?v.init(t.state):e.apply(t)}});let k=e=>{let t=setTimeout(()=>e(),500);return()=>clearTimeout(t)};"undefined"!=typeof requestIdleCallback&&(k=e=>{let t=-1,n=setTimeout(()=>{t=requestIdleCallback(e,{timeout:400})},100);return()=>t<0?clearTimeout(n):cancelIdleCallback(t)});let w="undefined"!=typeof navigator&&(null===(r=navigator.scheduling)||void 0===r?void 0:r.isInputPending)?()=>navigator.scheduling.isInputPending():null,D=o.lg.fromClass(class{constructor(e){this.view=e,this.working=null,this.workScheduled=0,this.chunkEnd=-1,this.chunkBudget=-1,this.work=this.work.bind(this),this.scheduleWork()}update(e){let t=this.view.state.field(c.state).context;(t.updateViewport(e.view.viewport)||this.view.viewport.to>t.treeLen)&&this.scheduleWork(),(e.docChanged||e.selectionSet)&&(this.view.hasFocus&&(this.chunkBudget+=50),this.scheduleWork()),this.checkAsyncSchedule(t)}scheduleWork(){if(this.working)return;let{state:e}=this.view,t=e.field(c.state);(t.tree!=t.context.tree||!t.context.isDone(e.doc.length))&&(this.working=k(this.work))}work(e){this.working=null;let t=Date.now();if(this.chunkEnd<t&&(this.chunkEnd<0||this.view.hasFocus)&&(this.chunkEnd=t+3e4,this.chunkBudget=3e3),this.chunkBudget<=0)return;let{state:n,viewport:{to:r}}=this.view,i=n.field(c.state);if(i.tree==i.context.tree&&i.context.isDone(r+1e5))return;let s=Date.now()+Math.min(this.chunkBudget,100,e&&!w?Math.max(25,e.timeRemaining()-5):1e9),o=i.context.treeLen<r&&n.doc.length>r+1e3,l=i.context.work(()=>w&&w()||Date.now()>s,r+(o?0:1e5));this.chunkBudget-=Date.now()-t,(l||this.chunkBudget<=0)&&(i.context.takeTree(),this.view.dispatch({effects:c.setState.of(new v(i.context))})),this.chunkBudget>0&&!(l&&!o)&&this.scheduleWork(),this.checkAsyncSchedule(i.context)}checkAsyncSchedule(e){e.scheduleOn&&(this.workScheduled++,e.scheduleOn.then(()=>this.scheduleWork()).catch(e=>(0,o.OO)(this.view.state,e)).then(()=>this.workScheduled--),e.scheduleOn=null)}destroy(){this.working&&this.working()}isWorking(){return!!(this.working||this.workScheduled>0)}},{eventHandlers:{focus(){this.scheduleWork()}}}),A=s.r$.define({combine:e=>e.length?e[0]:null,enables:e=>[c.state,D,o.tk.contentAttributes.compute([e],t=>{let n=t.facet(e);return n&&n.name?{"data-language":n.name}:{}})]});class x{constructor(e,t=[]){this.language=e,this.support=t,this.extension=[e,t]}}let C=s.r$.define(),E=s.r$.define({combine:e=>{if(!e.length)return" ";let t=e[0];if(!t||/\S/.test(t)||Array.from(t).some(e=>e!=t[0]))throw Error("Invalid indent unit: "+JSON.stringify(e[0]));return t}});function S(e){let t=e.facet(E);return 9==t.charCodeAt(0)?e.tabSize*t.length:t.length}function _(e,t){let n="",r=e.tabSize,i=e.facet(E)[0];if(" "==i){for(;t>=r;)n+=" ",t-=r;i=" "}for(let e=0;e<t;e++)n+=i;return n}function O(e,t){for(let n of(e instanceof s.yy&&(e=new F(e)),e.state.facet(C))){let r=n(e,t);if(void 0!==r)return r}let n=p(e.state);return n.length>=t?function(e,t,n){let r=t.resolveStack(n),i=r.node.enterUnfinishedNodesBefore(n);if(i!=r.node){let e=[];for(let t=i;t!=r.node;t=t.parent)e.push(t);for(let t=e.length-1;t>=0;t--)r={node:e[t],next:r}}return T(r,e,n)}(e,n,t):null}class F{constructor(e,t={}){this.state=e,this.options=t,this.unit=S(e)}lineAt(e,t=1){let n=this.state.doc.lineAt(e),{simulateBreak:r,simulateDoubleBreak:i}=this.options;if(null!=r&&r>=n.from&&r<=n.to)return i&&r==e?{text:"",from:e}:(t<0?r<e:r<=e)?{text:n.text.slice(r-n.from),from:r}:{text:n.text.slice(0,r-n.from),from:n.from};return n}textAfterPos(e,t=1){if(this.options.simulateDoubleBreak&&e==this.options.simulateBreak)return"";let{text:n,from:r}=this.lineAt(e,t);return n.slice(e-r,Math.min(n.length,e+100-r))}column(e,t=1){let{text:n,from:r}=this.lineAt(e,t),i=this.countColumn(n,e-r),s=this.options.overrideIndentation?this.options.overrideIndentation(r):-1;return s>-1&&(i+=s-this.countColumn(n,n.search(/\S|$/))),i}countColumn(e,t=e.length){return(0,s.IS)(e,this.state.tabSize,t)}lineIndent(e,t=1){let{text:n,from:r}=this.lineAt(e,t),i=this.options.overrideIndentation;if(i){let e=i(r);if(e>-1)return e}return this.countColumn(n,n.search(/\S|$/))}get simulatedBreak(){return this.options.simulateBreak||null}}let P=new i.md;function T(e,t,n){for(let r=e;r;r=r.next){let e=function(e){let t=e.type.prop(P);if(t)return t;let n=e.firstChild,r;if(n&&(r=n.type.prop(i.md.closedBy))){let t=e.lastChild,n=t&&r.indexOf(t.name)>-1;return e=>{var r;return function(e,t,n,r,i){let s=e.textAfter,o=s.match(/^\s*/)[0].length,l=r&&s.slice(o,o+r.length)==r||i==e.pos+o,a=t?function(e){let t=e.node,n=t.childAfter(t.from),r=t.lastChild;if(!n)return null;let i=e.options.simulateBreak,s=e.state.doc.lineAt(n.from),o=null==i||i<=s.from?s.to:Math.min(s.to,i);for(let e=n.to;;){let i=t.childAfter(e);if(!i||i==r)return null;if(!i.type.isSkipped)return i.from<o?n:null;e=i.to}}(e):null;return a?l?e.column(a.from):e.column(a.to):e.baseIndent+(l?0:e.unit*n)}(e,!0,1,void 0,n&&!((r=e).pos==r.options.simulateBreak&&r.options.simulateDoubleBreak)?t.from:void 0)}}return null==e.parent?N:null}(r.node);if(e)return e(B.create(t,n,r))}return 0}function N(){return 0}class B extends F{constructor(e,t,n){super(e.state,e.options),this.base=e,this.pos=t,this.context=n}get node(){return this.context.node}static create(e,t,n){return new B(e,t,n)}get textAfter(){return this.textAfterPos(this.pos)}get baseIndent(){return this.baseIndentFor(this.node)}baseIndentFor(e){let t=this.state.doc.lineAt(e.from);for(;;){let n=e.resolve(t.from);for(;n.parent&&n.parent.from==n.from;)n=n.parent;if(function(e,t){for(let n=t;n;n=n.parent)if(e==n)return!0;return!1}(n,e))break;t=this.state.doc.lineAt(n.from)}return this.lineIndent(t.from)}continue(){return T(this.context.next,this.base,this.pos)}}function I({except:e,units:t=1}={}){return n=>{let r=e&&e.test(n.textAfter);return n.baseIndent+(r?0:t*n.unit)}}function M(){return s.yy.transactionFilter.of(e=>{if(!e.docChanged||!e.isUserEvent("input.type")&&!e.isUserEvent("input.complete"))return e;let t=e.startState.languageDataAt("indentOnInput",e.startState.selection.main.head);if(!t.length)return e;let n=e.newDoc,{head:r}=e.newSelection.main,i=n.lineAt(r);if(r>i.from+200)return e;let s=n.sliceString(i.from,r);if(!t.some(e=>e.test(s)))return e;let{state:o}=e,l=-1,a=[];for(let{head:e}of o.selection.ranges){let t=o.doc.lineAt(e);if(t.from==l)continue;l=t.from;let n=O(o,t.from);if(null==n)continue;let r=/^\s*/.exec(t.text)[0],i=_(o,n);r!=i&&a.push({from:t.from,to:t.from+r.length,insert:i})}return a.length?[e,{changes:a,sequential:!0}]:e})}let $=s.r$.define(),L=new i.md;function R(e){let t=e.firstChild,n=e.lastChild;return t&&t.to<n.from?{from:t.to,to:n.type.isError?e.to:n.from}:null}function j(e,t,n){for(let r of e.facet($)){let i=r(e,t,n);if(i)return i}return function(e,t,n){let r=p(e);if(r.length<n)return null;let i=r.resolveStack(n,1),s=null;for(let o=i;o;o=o.next){let i=o.node;if(i.to<=n||i.from>n)continue;if(s&&i.from<t)break;let l=i.type.prop(L);if(l&&(i.to<r.length-50||r.length==e.doc.length||!function(e){let t=e.lastChild;return t&&t.to==e.to&&t.type.isError}(i))){let r=l(i,e);r&&r.from<=n&&r.from>=t&&r.to>n&&(s=r)}}return s}(e,t,n)}function q(e,t){let n=t.mapPos(e.from,1),r=t.mapPos(e.to,-1);return n>=r?void 0:{from:n,to:r}}let V=s.Py.define({map:q}),z=s.Py.define({map:q});function U(e){let t=[];for(let{head:n}of e.state.selection.ranges)!t.some(e=>e.from<=n&&e.to>=n)&&t.push(e.lineBlockAt(n));return t}let H=s.QQ.define({create:()=>o.p.none,update(e,t){for(let n of(e=e.map(t.changes),t.effects))if(n.is(V)&&!function(e,t,n){let r=!1;return e.between(t,t,(e,i)=>{e==t&&i==n&&(r=!0)}),r}(e,n.value.from,n.value.to)){let{preparePlaceholder:r}=t.state.facet(Y),i=r?o.p.replace({widget:new et(r(t.state,n.value))}):ee;e=e.update({add:[i.range(n.value.from,n.value.to)]})}else n.is(z)&&(e=e.update({filter:(e,t)=>n.value.from!=e||n.value.to!=t,filterFrom:n.value.from,filterTo:n.value.to}));if(t.selection){let n=!1,{head:r}=t.selection.main;e.between(r,r,(e,t)=>{e<r&&t>r&&(n=!0)}),n&&(e=e.update({filterFrom:r,filterTo:r,filter:(e,t)=>t<=r||e>=r}))}return e},provide:e=>o.tk.decorations.from(e),toJSON(e,t){let n=[];return e.between(0,t.doc.length,(e,t)=>{n.push(e,t)}),n},fromJSON(e){if(!Array.isArray(e)||e.length%2)throw RangeError("Invalid JSON for fold state");let t=[];for(let n=0;n<e.length;){let r=e[n++],i=e[n++];if("number"!=typeof r||"number"!=typeof i)throw RangeError("Invalid JSON for fold state");t.push(ee.range(r,i))}return o.p.set(t,!0)}});function W(e,t,n){var r;let i=null;return null===(r=e.field(H,!1))||void 0===r||r.between(t,n,(e,t)=>{(!i||i.from>e)&&(i={from:e,to:t})}),i}function G(e,t){return e.field(H,!1)?t:t.concat(s.Py.appendConfig.of(Z()))}function K(e,t,n=!0){let r=e.state.doc.lineAt(t.from).number,i=e.state.doc.lineAt(t.to).number;return o.tk.announce.of(`${e.state.phrase(n?"Folded lines":"Unfolded lines")} ${r} ${e.state.phrase("to")} ${i}.`)}let J=[{key:"Ctrl-Shift-[",mac:"Cmd-Alt-[",run:e=>{for(let t of U(e)){let n=j(e.state,t.from,t.to);if(n)return e.dispatch({effects:G(e.state,[V.of(n),K(e,n)])}),!0}return!1}},{key:"Ctrl-Shift-]",mac:"Cmd-Alt-]",run:e=>{if(!e.state.field(H,!1))return!1;let t=[];for(let n of U(e)){let r=W(e.state,n.from,n.to);r&&t.push(z.of(r),K(e,r,!1))}return t.length&&e.dispatch({effects:t}),t.length>0}},{key:"Ctrl-Alt-[",run:e=>{let{state:t}=e,n=[];for(let r=0;r<t.doc.length;){let i=e.lineBlockAt(r),s=j(t,i.from,i.to);s&&n.push(V.of(s)),r=(s?e.lineBlockAt(s.to):i).to+1}return n.length&&e.dispatch({effects:G(e.state,n)}),!!n.length}},{key:"Ctrl-Alt-]",run:e=>{let t=e.state.field(H,!1);if(!t||!t.size)return!1;let n=[];return t.between(0,e.state.doc.length,(e,t)=>{n.push(z.of({from:e,to:t}))}),e.dispatch({effects:n}),!0}}],Q={placeholderDOM:null,preparePlaceholder:null,placeholderText:"…"},Y=s.r$.define({combine:e=>(0,s.BO)(e,Q)});function Z(e){let t=[H,es];return e&&t.push(Y.of(e)),t}function X(e,t){let{state:n}=e,r=n.facet(Y),i=t=>{let n=e.lineBlockAt(e.posAtDOM(t.target)),r=W(e.state,n.from,n.to);r&&e.dispatch({effects:z.of(r)}),t.preventDefault()};if(r.placeholderDOM)return r.placeholderDOM(e,i,t);let s=document.createElement("span");return s.textContent=r.placeholderText,s.setAttribute("aria-label",n.phrase("folded code")),s.title=n.phrase("unfold"),s.className="cm-foldPlaceholder",s.onclick=i,s}let ee=o.p.replace({widget:new class extends o.l9{toDOM(e){return X(e,null)}}});class et extends o.l9{constructor(e){super(),this.value=e}eq(e){return this.value==e.value}toDOM(e){return X(e,this.value)}}let en={openText:"⌄",closedText:"›",markerDOM:null,domEventHandlers:{},foldingChanged:()=>!1};class er extends o.SJ{constructor(e,t){super(),this.config=e,this.open=t}eq(e){return this.config==e.config&&this.open==e.open}toDOM(e){if(this.config.markerDOM)return this.config.markerDOM(this.open);let t=document.createElement("span");return t.textContent=this.open?this.config.openText:this.config.closedText,t.title=e.state.phrase(this.open?"Fold line":"Unfold line"),t}}function ei(e={}){let t=Object.assign(Object.assign({},en),e),n=new er(t,!0),r=new er(t,!1),i=o.lg.fromClass(class{constructor(e){this.from=e.viewport.from,this.markers=this.buildMarkers(e)}update(e){(e.docChanged||e.viewportChanged||e.startState.facet(A)!=e.state.facet(A)||e.startState.field(H,!1)!=e.state.field(H,!1)||p(e.startState)!=p(e.state)||t.foldingChanged(e))&&(this.markers=this.buildMarkers(e.view))}buildMarkers(e){let t=new s.f_;for(let i of e.viewportLineBlocks){let s=W(e.state,i.from,i.to)?r:j(e.state,i.from,i.to)?n:null;s&&t.add(i.from,i.from,s)}return t.finish()}}),{domEventHandlers:l}=t;return[i,(0,o.v5)({class:"cm-foldGutter",markers(e){var t;return(null===(t=e.plugin(i))||void 0===t?void 0:t.markers)||s.Xs.empty},initialSpacer:()=>new er(t,!1),domEventHandlers:Object.assign(Object.assign({},l),{click:(e,t,n)=>{if(l.click&&l.click(e,t,n))return!0;let r=W(e.state,t.from,t.to);if(r)return e.dispatch({effects:z.of(r)}),!0;let i=j(e.state,t.from,t.to);return!!i&&(e.dispatch({effects:V.of(i)}),!0)}})}),Z()]}let es=o.tk.baseTheme({".cm-foldPlaceholder":{backgroundColor:"#eee",border:"1px solid #ddd",color:"#888",borderRadius:".2em",margin:"0 1px",padding:"0 1px",cursor:"pointer"},".cm-foldGutter span":{padding:"0 1px",cursor:"pointer"}});class eo{constructor(e,t){let n;function r(e){let t=a.V.newName();return(n||(n=Object.create(null)))["."+t]=e,t}this.specs=e;let i="string"==typeof t.all?t.all:t.all?r(t.all):void 0,s=t.scope;this.scope=s instanceof c?e=>e.prop(u)==s.data:s?e=>e==s:void 0,this.style=(0,l.QR)(e.map(e=>({tag:e.tag,class:e.class||r(Object.assign({},e,{tag:null}))})),{all:i}).style,this.module=n?new a.V(n):null,this.themeType=t.themeType}static define(e,t){return new eo(e,t||{})}}let el=s.r$.define(),ea=s.r$.define({combine:e=>e.length?[e[0]]:null});function eu(e){let t=e.facet(el);return t.length?t:e.facet(ea)}function eh(e,t){let n=[ec],r;return e instanceof eo&&(e.module&&n.push(o.tk.styleModule.of(e.module)),r=e.themeType),(null==t?void 0:t.fallback)?n.push(ea.of(e)):r?n.push(el.computeN([o.tk.darkTheme],t=>t.facet(o.tk.darkTheme)==("dark"==r)?[e]:[])):n.push(el.of(e)),n}let ec=s.Wl.high(o.lg.fromClass(class e{constructor(e){this.markCache=Object.create(null),this.tree=p(e.state),this.decorations=this.buildDeco(e,eu(e.state)),this.decoratedTo=e.viewport.to}update(e){let t=p(e.state),n=eu(e.state),r=n!=eu(e.startState),{viewport:i}=e.view,s=e.changes.mapPos(this.decoratedTo,1);t.length<i.to&&!r&&t.type==this.tree.type&&s>=i.to?(this.decorations=this.decorations.map(e.changes),this.decoratedTo=s):(t!=this.tree||e.viewportChanged||r)&&(this.tree=t,this.decorations=this.buildDeco(e.view,n),this.decoratedTo=i.to)}buildDeco(e,t){if(!t||!this.tree.length)return o.p.none;let n=new s.f_;for(let{from:r,to:i}of e.visibleRanges)(0,l.bW)(this.tree,t,(e,t,r)=>{n.add(e,t,this.markCache[r]||(this.markCache[r]=o.p.mark({class:r})))},r,i);return n.finish()}},{decorations:e=>e.decorations}));l.pJ.meta,l.pJ.link,l.pJ.heading,l.pJ.emphasis,l.pJ.strong,l.pJ.strikethrough,l.pJ.keyword,l.pJ.atom,l.pJ.bool,l.pJ.url,l.pJ.contentSeparator,l.pJ.labelName,l.pJ.literal,l.pJ.inserted,l.pJ.string,l.pJ.deleted,l.pJ.regexp,l.pJ.escape,l.pJ.string,l.pJ.variableName,l.pJ.variableName,l.pJ.typeName,l.pJ.namespace,l.pJ.className,l.pJ.variableName,l.pJ.macroName,l.pJ.propertyName,l.pJ.comment,l.pJ.invalid;let ef=o.tk.baseTheme({"&.cm-focused .cm-matchingBracket":{backgroundColor:"#328c8252"},"&.cm-focused .cm-nonmatchingBracket":{backgroundColor:"#bb555544"}}),ed="()[]{}",ep=s.r$.define({combine:e=>(0,s.BO)(e,{afterCursor:!0,brackets:ed,maxScanDistance:1e4,renderMatch:ey})}),em=o.p.mark({class:"cm-matchingBracket"}),eg=o.p.mark({class:"cm-nonmatchingBracket"});function ey(e){let t=[],n=e.matched?em:eg;return t.push(n.range(e.start.from,e.start.to)),e.end&&t.push(n.range(e.end.from,e.end.to)),t}let eb=[s.QQ.define({create:()=>o.p.none,update(e,t){if(!t.docChanged&&!t.selection)return e;let n=[],r=t.state.facet(ep);for(let e of t.state.selection.ranges){if(!e.empty)continue;let i=eA(t.state,e.head,-1,r)||e.head>0&&eA(t.state,e.head-1,1,r)||r.afterCursor&&(eA(t.state,e.head,1,r)||e.head<t.state.doc.length&&eA(t.state,e.head+1,-1,r));i&&(n=n.concat(r.renderMatch(i,t.state)))}return o.p.set(n,!0)},provide:e=>o.tk.decorations.from(e)}),ef];function ev(e={}){return[ep.of(e),eb]}let ek=new i.md;function ew(e,t,n){let r=e.prop(t<0?i.md.openedBy:i.md.closedBy);if(r)return r;if(1==e.name.length){let r=n.indexOf(e.name);if(r>-1&&r%2==(t<0?1:0))return[n[r+t]]}return null}function eD(e){let t=e.type.prop(ek);return t?t(e.node):e}function eA(e,t,n,r={}){let i=r.maxScanDistance||1e4,s=r.brackets||ed,o=p(e),l=o.resolveInner(t,n);for(let r=l;r;r=r.parent){let i=ew(r.type,n,s);if(i&&r.from<r.to){let o=eD(r);if(o&&(n>0?t>=o.from&&t<o.to:t>o.from&&t<=o.to))return function(e,t,n,r,i,s,o){let l=r.parent,a={from:i.from,to:i.to},u=0,h=null==l?void 0:l.cursor();if(h&&(n<0?h.childBefore(r.from):h.childAfter(r.to)))do if(n<0?h.to<=r.from:h.from>=r.to){if(0==u&&s.indexOf(h.type.name)>-1&&h.from<h.to){let e=eD(h);return{start:a,end:e?{from:e.from,to:e.to}:void 0,matched:!0}}if(ew(h.type,n,o))u++;else if(ew(h.type,-n,o)){if(0==u){let e=eD(h);return{start:a,end:e&&e.from<e.to?{from:e.from,to:e.to}:void 0,matched:!1}}u--}}while(n<0?h.prevSibling():h.nextSibling());return{start:a,matched:!1}}(e,t,n,r,o,i,s)}}return function(e,t,n,r,i,s,o){let l=n<0?e.sliceDoc(t-1,t):e.sliceDoc(t,t+1),a=o.indexOf(l);if(a<0||a%2==0!=n>0)return null;let u={from:n<0?t-1:t,to:n>0?t+1:t},h=e.doc.iterRange(t,n>0?e.doc.length:0),c=0;for(let e=0;!h.next().done&&e<=s;){let s=h.value;n<0&&(e+=s.length);let l=t+e*n;for(let e=n>0?0:s.length-1,t=n>0?s.length:-1;e!=t;e+=n){let t=o.indexOf(s[e]);if(!(t<0)&&r.resolveInner(l+e,1).type==i){if(t%2==0==n>0)c++;else{if(1==c)return{start:u,end:{from:l+e,to:l+e+1},matched:t>>1==a>>1};c--}}}n>0&&(e+=s.length)}return h.done?{start:u,matched:!1}:null}(e,t,n,o,l.type,i,s)}let ex=Object.create(null),eC=[i.Jq.none],eE=[],eS=Object.create(null),e_=Object.create(null);for(let[e,t]of[["variable","variableName"],["variable-2","variableName.special"],["string-2","string.special"],["def","variableName.definition"],["tag","tagName"],["attribute","attributeName"],["type","typeName"],["builtin","variableName.standard"],["qualifier","modifier"],["error","invalid"],["header","heading"],["property","propertyName"]])e_[e]=eF(ex,t);function eO(e,t){!(eE.indexOf(e)>-1)&&(eE.push(e),console.warn(t))}function eF(e,t){let n=[];for(let r of t.split(" ")){let t=[];for(let n of r.split(".")){let r=e[n]||l.pJ[n];r?"function"==typeof r?t.length?t=t.map(r):eO(n,`Modifier ${n} used at start of tag`):t.length?eO(n,`Tag ${n} used as modifier`):t=Array.isArray(r)?r:[r]:eO(n,`Unknown highlighting tag ${n}`)}for(let e of t)n.push(e)}if(!n.length)return 0;let r=t.replace(/ /g,"_"),s=r+" "+n.map(e=>e.id),o=eS[s];if(o)return o.id;let a=eS[s]=i.Jq.define({id:eC.length,name:r,props:[(0,l.Gv)({[r]:n})]});return eC.push(a),a.id}function eP(e){return e.length<=4096&&/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/.test(e)}let eT={rtl:o.p.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"rtl"},bidiIsolate:o.Nm.RTL}),ltr:o.p.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"ltr"},bidiIsolate:o.Nm.LTR}),auto:o.p.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"auto"},bidiIsolate:null})}},77730:function(e,t,n){"use strict";n.d(t,{ir:()=>D,KS:()=>m,Q2:()=>j,Fv:()=>v});var r=n("76621"),i=n("8954");function s(){var e=arguments[0];"string"==typeof e&&(e=document.createElement(e));var t=1,n=arguments[1];if(n&&"object"==typeof n&&null==n.nodeType&&!Array.isArray(n)){for(var r in n)if(Object.prototype.hasOwnProperty.call(n,r)){var i=n[r];"string"==typeof i?e.setAttribute(r,i):null!=i&&(e[r]=i)}t++}for(;t<arguments.length;t++)(function e(t,n){if("string"==typeof n)t.appendChild(document.createTextNode(n));else if(null==n);else if(null!=n.nodeType)t.appendChild(n);else if(Array.isArray(n))for(var r=0;r<n.length;r++)e(t,n[r]);else throw RangeError("Unsupported child node: "+n)})(e,arguments[t]);return e}class o{constructor(e,t,n){this.from=e,this.to=t,this.diagnostic=n}}class l{constructor(e,t,n){this.diagnostics=e,this.panel=t,this.selected=n}static init(e,t,n){let i=e,s=n.facet(w).markerFilter;s&&(i=s(i,n));let o=r.p.set(i.map(e=>e.from==e.to||e.from==e.to-1&&n.doc.lineAt(e.from).to==e.from?r.p.widget({widget:new C(e),diagnostic:e}).range(e.from):r.p.mark({attributes:{class:"cm-lintRange cm-lintRange-"+e.severity+(e.markClass?" "+e.markClass:"")},diagnostic:e,inclusive:!0}).range(e.from,e.to)),!0);return new l(o,t,a(o))}}function a(e,t=null,n=0){let r=null;return e.between(n,1e9,(e,n,{spec:i})=>{if(!t||i.diagnostic==t)return r=new o(e,n,i.diagnostic),!1}),r}function u(e,t){let n=t.pos,r=t.end||n,i=e.state.facet(w).hideOn(e,n,r);if(null!=i)return i;let s=e.startState.doc.lineAt(t.pos);return!!(e.effects.some(e=>e.is(c))||e.changes.touchesRange(s.from,Math.max(s.to,r)))}function h(e,t){return e.field(p,!1)?t:t.concat(i.Py.appendConfig.of(L))}let c=i.Py.define(),f=i.Py.define(),d=i.Py.define(),p=i.QQ.define({create:()=>new l(r.p.none,null,null),update(e,t){if(t.docChanged){let n=e.diagnostics.map(t.changes),r=null;if(e.selected){let i=t.changes.mapPos(e.selected.from,1);r=a(n,e.selected.diagnostic,i)||a(n,null,i)}e=new l(n,e.panel,r)}for(let n of t.effects)n.is(c)?e=l.init(n.value,e.panel,t.state):n.is(f)?e=new l(e.diagnostics,n.value?S.open:null,e.selected):n.is(d)&&(e=new l(e.diagnostics,e.panel,n.value));return e},provide:e=>[r.mH.from(e,e=>e.panel),r.tk.decorations.from(e,e=>e.diagnostics)]});function m(e){let t=e.field(p,!1);return t?t.diagnostics.size:0}let g=r.p.mark({class:"cm-lintRange cm-lintRange-active",inclusive:!0});function y(e,t){return s("ul",{class:"cm-tooltip-lint"},t.map(t=>x(e,t,!1)))}let b=e=>{let t=e.state.field(p,!1);return!!t&&!!t.panel&&(e.dispatch({effects:f.of(!1)}),!0)},v=[{key:"Mod-Shift-m",run:e=>{let t=e.state.field(p,!1);(!t||!t.panel)&&e.dispatch({effects:h(e.state,[f.of(!0)])});let n=(0,r.Sd)(e,S.open);return n&&n.dom.querySelector(".cm-panel-lint ul").focus(),!0},preventDefault:!0},{key:"F8",run:e=>{let t=e.state.field(p,!1);if(!t)return!1;let n=e.state.selection.main,r=t.diagnostics.iter(n.to+1);return(!!r.value||!!(r=t.diagnostics.iter(0)).value&&(r.from!=n.from||r.to!=n.to))&&(e.dispatch({selection:{anchor:r.from,head:r.to},scrollIntoView:!0}),!0)}}],k=r.lg.fromClass(class{constructor(e){this.view=e,this.timeout=-1,this.set=!0;let{delay:t}=e.state.facet(w);this.lintTime=Date.now()+t,this.run=this.run.bind(this),this.timeout=setTimeout(this.run,t)}run(){clearTimeout(this.timeout);let e=Date.now();if(e<this.lintTime-10)this.timeout=setTimeout(this.run,this.lintTime-e);else{this.set=!1;let{state:e}=this.view,{sources:t}=e.facet(w);t.length&&Promise.all(t.map(e=>Promise.resolve(e(this.view)))).then(t=>{let n=t.reduce((e,t)=>e.concat(t));if(this.view.state.doc==e.doc){var r,i;this.view.dispatch((r=this.view.state,i=n,{effects:h(r,[c.of(i)])}))}},e=>{(0,r.OO)(this.view.state,e)})}}update(e){let t=e.state.facet(w);(e.docChanged||t!=e.startState.facet(w)||t.needsRefresh&&t.needsRefresh(e))&&(this.lintTime=Date.now()+t.delay,!this.set&&(this.set=!0,this.timeout=setTimeout(this.run,t.delay)))}force(){this.set&&(this.lintTime=Date.now(),this.run())}destroy(){clearTimeout(this.timeout)}}),w=i.r$.define({combine:e=>Object.assign({sources:e.map(e=>e.source).filter(e=>null!=e)},(0,i.BO)(e.map(e=>e.config),{delay:750,markerFilter:null,tooltipFilter:null,needsRefresh:null,hideOn:()=>null},{needsRefresh:(e,t)=>e?t?n=>e(n)||t(n):e:t}))});function D(e,t={}){return[w.of({source:e,config:t}),k,L]}function A(e){let t=[];if(e)e:for(let{name:n}of e){for(let e=0;e<n.length;e++){let r=n[e];if(/[a-zA-Z]/.test(r)&&!t.some(e=>e.toLowerCase()==r.toLowerCase())){t.push(r);continue e}}t.push("")}return t}function x(e,t,n){var r;let i=n?A(t.actions):[];return s("li",{class:"cm-diagnostic cm-diagnostic-"+t.severity},s("span",{class:"cm-diagnosticText"},t.renderMessage?t.renderMessage(e):t.message),null===(r=t.actions)||void 0===r?void 0:r.map((n,r)=>{let o=!1,l=r=>{if(r.preventDefault(),o)return;o=!0;let i=a(e.state.field(p).diagnostics,t);i&&n.apply(e,i.from,i.to)},{name:u}=n,h=i[r]?u.indexOf(i[r]):-1,c=h<0?u:[u.slice(0,h),s("u",u.slice(h,h+1)),u.slice(h+1)];return s("button",{type:"button",class:"cm-diagnosticAction",onclick:l,onmousedown:l,"aria-label":` Action: ${u}${h<0?"":` (access key "${i[r]})"`}.`},c)}),t.source&&s("div",{class:"cm-diagnosticSource"},t.source))}class C extends r.l9{constructor(e){super(),this.diagnostic=e}eq(e){return e.diagnostic==this.diagnostic}toDOM(){return s("span",{class:"cm-lintPoint cm-lintPoint-"+this.diagnostic.severity})}}class E{constructor(e,t){this.diagnostic=t,this.id="item_"+Math.floor(0xffffffff*Math.random()).toString(16),this.dom=x(e,t,!0),this.dom.id=this.id,this.dom.setAttribute("role","option")}}class S{constructor(e){this.view=e,this.items=[];this.list=s("ul",{tabIndex:0,role:"listbox","aria-label":this.view.state.phrase("Diagnostics"),onkeydown:t=>{if(27==t.keyCode)b(this.view),this.view.focus();else if(38==t.keyCode||33==t.keyCode)this.moveSelection((this.selectedIndex-1+this.items.length)%this.items.length);else if(40==t.keyCode||34==t.keyCode)this.moveSelection((this.selectedIndex+1)%this.items.length);else if(36==t.keyCode)this.moveSelection(0);else if(35==t.keyCode)this.moveSelection(this.items.length-1);else if(13==t.keyCode)this.view.focus();else{if(!(t.keyCode>=65)||!(t.keyCode<=90)||!(this.selectedIndex>=0))return;let{diagnostic:n}=this.items[this.selectedIndex],r=A(n.actions);for(let i=0;i<r.length;i++)if(r[i].toUpperCase().charCodeAt(0)==t.keyCode){let t=a(this.view.state.field(p).diagnostics,n);t&&n.actions[i].apply(e,t.from,t.to)}}t.preventDefault()},onclick:e=>{for(let t=0;t<this.items.length;t++)this.items[t].dom.contains(e.target)&&this.moveSelection(t)}}),this.dom=s("div",{class:"cm-panel-lint"},this.list,s("button",{type:"button",name:"close","aria-label":this.view.state.phrase("close"),onclick:()=>b(this.view)},"\xd7")),this.update()}get selectedIndex(){let e=this.view.state.field(p).selected;if(!e)return -1;for(let t=0;t<this.items.length;t++)if(this.items[t].diagnostic==e.diagnostic)return t;return -1}update(){let{diagnostics:e,selected:t}=this.view.state.field(p),n=0,r=!1,i=null;for(e.between(0,this.view.state.doc.length,(e,s,{spec:o})=>{let l=-1,a;for(let e=n;e<this.items.length;e++)if(this.items[e].diagnostic==o.diagnostic){l=e;break}l<0?(a=new E(this.view,o.diagnostic),this.items.splice(n,0,a),r=!0):(a=this.items[l],l>n&&(this.items.splice(n,l-n),r=!0)),t&&a.diagnostic==t.diagnostic?!a.dom.hasAttribute("aria-selected")&&(a.dom.setAttribute("aria-selected","true"),i=a):a.dom.hasAttribute("aria-selected")&&a.dom.removeAttribute("aria-selected"),n++});n<this.items.length&&!(1==this.items.length&&this.items[0].diagnostic.from<0);)r=!0,this.items.pop();0==this.items.length&&(this.items.push(new E(this.view,{from:-1,to:-1,severity:"info",message:this.view.state.phrase("No diagnostics")})),r=!0),i?(this.list.setAttribute("aria-activedescendant",i.id),this.view.requestMeasure({key:this,read:()=>({sel:i.dom.getBoundingClientRect(),panel:this.list.getBoundingClientRect()}),write:({sel:e,panel:t})=>{let n=t.height/this.list.offsetHeight;e.top<t.top?this.list.scrollTop-=(t.top-e.top)/n:e.bottom>t.bottom&&(this.list.scrollTop+=(e.bottom-t.bottom)/n)}})):this.selectedIndex<0&&this.list.removeAttribute("aria-activedescendant"),r&&this.sync()}sync(){let e=this.list.firstChild;function t(){let t=e;e=t.nextSibling,t.remove()}for(let n of this.items)if(n.dom.parentNode==this.list){for(;e!=n.dom;)t();e=n.dom.nextSibling}else this.list.insertBefore(n.dom,e);for(;e;)t()}moveSelection(e){if(this.selectedIndex<0)return;let t=a(this.view.state.field(p).diagnostics,this.items[e].diagnostic);t&&this.view.dispatch({selection:{anchor:t.from,head:t.to},scrollIntoView:!0,effects:d.of(t)})}static open(e){return new S(e)}}function _(e,t='viewBox="0 0 40 40"'){return`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" ${t}>${encodeURIComponent(e)}</svg>')`}function O(e){return _(`<path d="m0 2.5 l2 -1.5 l1 0 l2 1.5 l1 0" stroke="${e}" fill="none" stroke-width=".7"/>`,'width="6" height="3"')}let F=r.tk.baseTheme({".cm-diagnostic":{padding:"3px 6px 3px 8px",marginLeft:"-1px",display:"block",whiteSpace:"pre-wrap"},".cm-diagnostic-error":{borderLeft:"5px solid #d11"},".cm-diagnostic-warning":{borderLeft:"5px solid orange"},".cm-diagnostic-info":{borderLeft:"5px solid #999"},".cm-diagnostic-hint":{borderLeft:"5px solid #66d"},".cm-diagnosticAction":{font:"inherit",border:"none",padding:"2px 4px",backgroundColor:"#444",color:"white",borderRadius:"3px",marginLeft:"8px",cursor:"pointer"},".cm-diagnosticSource":{fontSize:"70%",opacity:.7},".cm-lintRange":{backgroundPosition:"left bottom",backgroundRepeat:"repeat-x",paddingBottom:"0.7px"},".cm-lintRange-error":{backgroundImage:O("#d11")},".cm-lintRange-warning":{backgroundImage:O("orange")},".cm-lintRange-info":{backgroundImage:O("#999")},".cm-lintRange-hint":{backgroundImage:O("#66d")},".cm-lintRange-active":{backgroundColor:"#ffdd9980"},".cm-tooltip-lint":{padding:0,margin:0},".cm-lintPoint":{position:"relative","&:after":{content:'""',position:"absolute",bottom:0,left:"-2px",borderLeft:"3px solid transparent",borderRight:"3px solid transparent",borderBottom:"4px solid #d11"}},".cm-lintPoint-warning":{"&:after":{borderBottomColor:"orange"}},".cm-lintPoint-info":{"&:after":{borderBottomColor:"#999"}},".cm-lintPoint-hint":{"&:after":{borderBottomColor:"#66d"}},".cm-panel.cm-panel-lint":{position:"relative","& ul":{maxHeight:"100px",overflowY:"auto","& [aria-selected]":{backgroundColor:"#ddd","& u":{textDecoration:"underline"}},"&:focus [aria-selected]":{background_fallback:"#bdf",backgroundColor:"Highlight",color_fallback:"white",color:"HighlightText"},"& u":{textDecoration:"none"},padding:0,margin:0},"& [name=close]":{position:"absolute",top:"0",right:"2px",background:"inherit",border:"none",font:"inherit",padding:0,margin:0}}});function P(e){return"error"==e?4:"warning"==e?3:"info"==e?2:1}class T extends r.SJ{constructor(e){super(),this.diagnostics=e,this.severity=e.reduce((e,t)=>P(e)<P(t.severity)?t.severity:e,"hint")}toDOM(e){let t=document.createElement("div");t.className="cm-lint-marker cm-lint-marker-"+this.severity;let n=this.diagnostics,r=e.state.facet(R).tooltipFilter;return r&&(n=r(n,e.state)),n.length&&(t.onmouseover=()=>(function(e,t,n){function r(){var r,i;let s,o=e.elementAtHeight(t.getBoundingClientRect().top+5-e.documentTop);e.coordsAtPos(o.from)&&e.dispatch({effects:I.of({pos:o.from,above:!1,create:()=>({dom:y(e,n),getCoords:()=>t.getBoundingClientRect()})})}),t.onmouseout=t.onmousemove=null;r=e,i=t,s=e=>{let t=i.getBoundingClientRect();if(!(e.clientX>t.left-10)||!(e.clientX<t.right+10)||!(e.clientY>t.top-10)||!(e.clientY<t.bottom+10)){for(let t=e.target;t;t=t.parentNode)if(1==t.nodeType&&t.classList.contains("cm-tooltip-lint"))return;window.removeEventListener("mousemove",s),r.state.field(M)&&r.dispatch({effects:I.of(null)})}},window.addEventListener("mousemove",s)}let{hoverTime:i}=e.state.facet(R),s=setTimeout(r,i);t.onmouseout=()=>{clearTimeout(s),t.onmouseout=t.onmousemove=null},t.onmousemove=()=>{clearTimeout(s),s=setTimeout(r,i)}})(e,t,n)),t}}let N=(0,r.v5)({class:"cm-gutter-lint",markers:e=>e.state.field(B)}),B=i.QQ.define({create:()=>i.Xs.empty,update(e,t){e=e.map(t.changes);let n=t.state.facet(R).markerFilter;for(let r of t.effects)if(r.is(c)){let s=r.value;n&&(s=n(s||[],t.state)),e=function(e,t){let n=Object.create(null);for(let r of t){let t=e.lineAt(r.from);(n[t.from]||(n[t.from]=[])).push(r)}let r=[];for(let e in n)r.push(new T(n[e]).range(+e));return i.Xs.of(r,!0)}(t.state.doc,s.slice(0))}return e}}),I=i.Py.define(),M=i.QQ.define({create:()=>null,update:(e,t)=>(e&&t.docChanged&&(e=u(t,e)?null:Object.assign(Object.assign({},e),{pos:t.changes.mapPos(e.pos)})),t.effects.reduce((e,t)=>t.is(I)?t.value:e,e)),provide:e=>r.hJ.from(e)}),$=r.tk.baseTheme({".cm-gutter-lint":{width:"1.4em","& .cm-gutterElement":{padding:".2em"}},".cm-lint-marker":{width:"1em",height:"1em"},".cm-lint-marker-info":{content:_('<path fill="#aaf" stroke="#77e" stroke-width="6" stroke-linejoin="round" d="M5 5L35 5L35 35L5 35Z"/>')},".cm-lint-marker-warning":{content:_('<path fill="#fe8" stroke="#fd7" stroke-width="6" stroke-linejoin="round" d="M20 6L37 35L3 35Z"/>')},".cm-lint-marker-error":{content:_('<circle cx="20" cy="20" r="15" fill="#f87" stroke="#f43" stroke-width="6"/>')}}),L=[p,r.tk.decorations.compute([p],e=>{let{selected:t,panel:n}=e.field(p);return t&&n&&t.from!=t.to?r.p.set([g.range(t.from,t.to)]):r.p.none}),(0,r.bF)(function(e,t,n){let{diagnostics:r}=e.state.field(p),i=[],s=2e8,o=0;r.between(t-(n<0?1:0),t+(n>0?1:0),(e,r,{spec:l})=>{t>=e&&t<=r&&(e==r||(t>e||n>0)&&(t<r||n<0))&&(i.push(l.diagnostic),s=Math.min(e,s),o=Math.max(r,o))});let l=e.state.facet(w).tooltipFilter;return(l&&(i=l(i,e.state)),i.length)?{pos:s,end:o,above:e.state.doc.lineAt(s).to<o,create:()=>({dom:y(e,i)})}:null},{hideOn:u}),F],R=i.r$.define({combine:e=>(0,i.BO)(e,{hoverTime:300,markerFilter:null,tooltipFilter:null})});function j(e={}){return[R.of(e),B,N,$,M]}},8954:function(e,t,n){"use strict";let r;n.d(t,{BO:function(){return ew},D0:function(){return eb},Gz:function(){return eR},IS:function(){return eL},Py:function(){return ec},QQ:function(){return H},Wl:function(){return K},Xs:function(){return eE},YW:function(){return ef},as:function(){return _},bg:function(){return w},cp:function(){return g},f_:function(){return eS},gc:function(){return E},gm:function(){return k},jT:function(){return M},n0:function(){return S},nZ:function(){return D},q6:function(){return ea},r$:function(){return R},uU:function(){return eD},xv:function(){return i},yy:function(){return ek}});class i{lineAt(e){if(e<0||e>this.length)throw RangeError(`Invalid position ${e} in document of length ${this.length}`);return this.lineInner(e,!1,1,0)}line(e){if(e<1||e>this.lines)throw RangeError(`Invalid line number ${e} in ${this.lines}-line document`);return this.lineInner(e,!0,1,0)}replace(e,t,n){[e,t]=d(this,e,t);let r=[];return this.decompose(0,e,r,2),n.length&&n.decompose(0,n.length,r,3),this.decompose(t,this.length,r,1),o.from(r,this.length-(t-e)+n.length)}append(e){return this.replace(this.length,this.length,e)}slice(e,t=this.length){[e,t]=d(this,e,t);let n=[];return this.decompose(e,t,n,0),o.from(n,t-e)}eq(e){if(e==this)return!0;if(e.length!=this.length||e.lines!=this.lines)return!1;let t=this.scanIdentical(e,1),n=this.length-this.scanIdentical(e,-1),r=new u(this),i=new u(e);for(let e=t,s=t;;){if(r.next(e),i.next(e),e=0,r.lineBreak!=i.lineBreak||r.done!=i.done||r.value!=i.value)return!1;if(s+=r.value.length,r.done||s>=n)return!0}}iter(e=1){return new u(this,e)}iterRange(e,t=this.length){return new h(this,e,t)}iterLines(e,t){let n;if(null==e)n=this.iter();else{null==t&&(t=this.lines+1);let r=this.line(e).from;n=this.iterRange(r,Math.max(r,t==this.lines+1?this.length:t<=1?0:this.line(t-1).to))}return new c(n)}toString(){return this.sliceString(0)}toJSON(){let e=[];return this.flatten(e),e}constructor(){}static of(e){if(0==e.length)throw RangeError("A document must have at least one line");return 1!=e.length||e[0]?e.length<=32?new s(e):o.from(s.split(e,[])):i.empty}}class s extends i{constructor(e,t=function(e){let t=-1;for(let n of e)t+=n.length+1;return t}(e)){super(),this.text=e,this.length=t}get lines(){return this.text.length}get children(){return null}lineInner(e,t,n,r){for(let i=0;;i++){let s=this.text[i],o=r+s.length;if((t?n:o)>=e)return new f(r,o,n,s);r=o+1,n++}}decompose(e,t,n,r){let i=e<=0&&t>=this.length?this:new s(function(e,t,n){return l(e,[""],t,n)}(this.text,e,t),Math.min(t,this.length)-Math.max(0,e));if(1&r){let e=n.pop(),t=l(i.text,e.text.slice(),0,i.length);if(t.length<=32)n.push(new s(t,e.length+i.length));else{let e=t.length>>1;n.push(new s(t.slice(0,e)),new s(t.slice(e)))}}else n.push(i)}replace(e,t,n){if(!(n instanceof s))return super.replace(e,t,n);[e,t]=d(this,e,t);let r=l(this.text,l(n.text,function(e,t,n){return l(e,[""],t,n)}(this.text,0,e)),t),i=this.length+n.length-(t-e);return r.length<=32?new s(r,i):o.from(s.split(r,[]),i)}sliceString(e,t=this.length,n="\n"){[e,t]=d(this,e,t);let r="";for(let i=0,s=0;i<=t&&s<this.text.length;s++){let o=this.text[s],l=i+o.length;i>e&&s&&(r+=n),e<l&&t>i&&(r+=o.slice(Math.max(0,e-i),t-i)),i=l+1}return r}flatten(e){for(let t of this.text)e.push(t)}scanIdentical(){return 0}static split(e,t){let n=[],r=-1;for(let i of e)n.push(i),r+=i.length+1,32==n.length&&(t.push(new s(n,r)),n=[],r=-1);return r>-1&&t.push(new s(n,r)),t}}class o extends i{constructor(e,t){for(let n of(super(),this.children=e,this.length=t,this.lines=0,e))this.lines+=n.lines}lineInner(e,t,n,r){for(let i=0;;i++){let s=this.children[i],o=r+s.length,l=n+s.lines-1;if((t?l:o)>=e)return s.lineInner(e,t,n,r);r=o+1,n=l+1}}decompose(e,t,n,r){for(let i=0,s=0;s<=t&&i<this.children.length;i++){let o=this.children[i],l=s+o.length;if(e<=l&&t>=s){let i=r&((s<=e?1:0)|(l>=t?2:0));s>=e&&l<=t&&!i?n.push(o):o.decompose(e-s,t-s,n,i)}s=l+1}}replace(e,t,n){if([e,t]=d(this,e,t),n.lines<this.lines)for(let r=0,i=0;r<this.children.length;r++){let s=this.children[r],l=i+s.length;if(e>=i&&t<=l){let a=s.replace(e-i,t-i,n),u=this.lines-s.lines+a.lines;if(a.lines<u>>4&&a.lines>u>>6){let i=this.children.slice();return i[r]=a,new o(i,this.length-(t-e)+n.length)}return super.replace(i,l,a)}i=l+1}return super.replace(e,t,n)}sliceString(e,t=this.length,n="\n"){[e,t]=d(this,e,t);let r="";for(let i=0,s=0;i<this.children.length&&s<=t;i++){let o=this.children[i],l=s+o.length;s>e&&i&&(r+=n),e<l&&t>s&&(r+=o.sliceString(e-s,t-s,n)),s=l+1}return r}flatten(e){for(let t of this.children)t.flatten(e)}scanIdentical(e,t){if(!(e instanceof o))return 0;let n=0,[r,i,s,l]=t>0?[0,0,this.children.length,e.children.length]:[this.children.length-1,e.children.length-1,-1,-1];for(;;r+=t,i+=t){if(r==s||i==l)return n;let o=this.children[r],a=e.children[i];if(o!=a)return n+o.scanIdentical(a,t);n+=o.length+1}}static from(e,t=e.reduce((e,t)=>e+t.length+1,-1)){let n=0;for(let t of e)n+=t.lines;if(n<32){let n=[];for(let t of e)t.flatten(n);return new s(n,t)}let r=Math.max(32,n>>5),i=r<<1,l=r>>1,a=[],u=0,h=-1,c=[];function f(){0!=u&&(a.push(1==c.length?c[0]:o.from(c,h)),h=-1,u=c.length=0)}for(let t of e)!function e(t){let n;if(t.lines>i&&t instanceof o)for(let n of t.children)e(n);else t.lines>l&&(u>l||!u)?(f(),a.push(t)):t instanceof s&&u&&(n=c[c.length-1])instanceof s&&t.lines+n.lines<=32?(u+=t.lines,h+=t.length+1,c[c.length-1]=new s(n.text.concat(t.text),n.length+1+t.length)):(u+t.lines>r&&f(),u+=t.lines,h+=t.length+1,c.push(t))}(t);return f(),1==a.length?a[0]:new o(a,t)}}i.empty=new s([""],0);function l(e,t,n=0,r=1e9){for(let i=0,s=0,o=!0;s<e.length&&i<=r;s++){let l=e[s],a=i+l.length;a>=n&&(a>r&&(l=l.slice(0,r-i)),i<n&&(l=l.slice(n-i)),o?(t[t.length-1]+=l,o=!1):t.push(l)),i=a+1}return t}function a(e,t,n){return l(e,[""],t,n)}class u{constructor(e,t=1){this.dir=t,this.done=!1,this.lineBreak=!1,this.value="",this.nodes=[e],this.offsets=[t>0?1:(e instanceof s?e.text.length:e.children.length)<<1]}nextInner(e,t){for(this.done=this.lineBreak=!1;;){let n=this.nodes.length-1,r=this.nodes[n],i=this.offsets[n],o=i>>1,l=r instanceof s?r.text.length:r.children.length;if(o==(t>0?l:0)){if(0==n)return this.done=!0,this.value="",this;t>0&&this.offsets[n-1]++,this.nodes.pop(),this.offsets.pop()}else if((1&i)==(t>0?0:1)){if(this.offsets[n]+=t,0==e)return this.lineBreak=!0,this.value="\n",this;e--}else if(r instanceof s){let i=r.text[o+(t<0?-1:0)];if(this.offsets[n]+=t,i.length>Math.max(0,e))return this.value=0==e?i:t>0?i.slice(e):i.slice(0,i.length-e),this;e-=i.length}else{let i=r.children[o+(t<0?-1:0)];e>i.length?(e-=i.length,this.offsets[n]+=t):(t<0&&this.offsets[n]--,this.nodes.push(i),this.offsets.push(t>0?1:(i instanceof s?i.text.length:i.children.length)<<1))}}}next(e=0){return e<0&&(this.nextInner(-e,-this.dir),e=this.value.length),this.nextInner(e,this.dir)}}class h{constructor(e,t,n){this.value="",this.done=!1,this.cursor=new u(e,t>n?-1:1),this.pos=t>n?e.length:0,this.from=Math.min(t,n),this.to=Math.max(t,n)}nextInner(e,t){if(t<0?this.pos<=this.from:this.pos>=this.to)return this.value="",this.done=!0,this;e+=Math.max(0,t<0?this.pos-this.to:this.from-this.pos);let n=t<0?this.pos-this.from:this.to-this.pos;e>n&&(e=n),n-=e;let{value:r}=this.cursor.next(e);return this.pos+=(r.length+e)*t,this.value=r.length<=n?r:t<0?r.slice(r.length-n):r.slice(0,n),this.done=!this.value,this}next(e=0){return e<0?e=Math.max(e,this.from-this.pos):e>0&&(e=Math.min(e,this.to-this.pos)),this.nextInner(e,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&""!=this.value}}class c{constructor(e){this.inner=e,this.afterBreak=!0,this.value="",this.done=!1}next(e=0){let{done:t,lineBreak:n,value:r}=this.inner.next(e);return t&&this.afterBreak?(this.value="",this.afterBreak=!1):t?(this.done=!0,this.value=""):n?this.afterBreak?this.value="":(this.afterBreak=!0,this.next()):(this.value=r,this.afterBreak=!1),this}get lineBreak(){return!1}}"undefined"!=typeof Symbol&&(i.prototype[Symbol.iterator]=function(){return this.iter()},u.prototype[Symbol.iterator]=h.prototype[Symbol.iterator]=c.prototype[Symbol.iterator]=function(){return this});class f{constructor(e,t,n,r){this.from=e,this.to=t,this.number=n,this.text=r}get length(){return this.to-this.from}}function d(e,t,n){return[t=Math.max(0,Math.min(e.length,t)),Math.max(t,Math.min(e.length,n))]}let p="lc,34,7n,7,7b,19,,,,2,,2,,,20,b,1c,l,g,,2t,7,2,6,2,2,,4,z,,u,r,2j,b,1m,9,9,,o,4,,9,,3,,5,17,3,3b,f,,w,1j,,,,4,8,4,,3,7,a,2,t,,1m,,,,2,4,8,,9,,a,2,q,,2,2,1l,,4,2,4,2,2,3,3,,u,2,3,,b,2,1l,,4,5,,2,4,,k,2,m,6,,,1m,,,2,,4,8,,7,3,a,2,u,,1n,,,,c,,9,,14,,3,,1l,3,5,3,,4,7,2,b,2,t,,1m,,2,,2,,3,,5,2,7,2,b,2,s,2,1l,2,,,2,4,8,,9,,a,2,t,,20,,4,,2,3,,,8,,29,,2,7,c,8,2q,,2,9,b,6,22,2,r,,,,,,1j,e,,5,,2,5,b,,10,9,,2u,4,,6,,2,2,2,p,2,4,3,g,4,d,,2,2,6,,f,,jj,3,qa,3,t,3,t,2,u,2,1s,2,,7,8,,2,b,9,,19,3,3b,2,y,,3a,3,4,2,9,,6,3,63,2,2,,1m,,,7,,,,,2,8,6,a,2,,1c,h,1r,4,1c,7,,,5,,14,9,c,2,w,4,2,2,,3,1k,,,2,3,,,3,1m,8,2,2,48,3,,d,,7,4,,6,,3,2,5i,1m,,5,ek,,5f,x,2da,3,3x,,2o,w,fe,6,2x,2,n9w,4,,a,w,2,28,2,7k,,3,,4,,p,2,5,,47,2,q,i,d,,12,8,p,b,1a,3,1c,,2,4,2,2,13,,1v,6,2,2,2,2,c,,8,,1b,,1f,,,3,2,2,5,2,,,16,2,8,,6m,,2,,4,,fn4,,kh,g,g,g,a6,2,gt,,6a,,45,5,1ae,3,,2,5,4,14,3,4,,4l,2,fx,4,ar,2,49,b,4w,,1i,f,1k,3,1d,4,2,2,1x,3,10,5,,8,1q,,c,2,1g,9,a,4,2,,2n,3,2,,,2,6,,4g,,3,8,l,2,1l,2,,,,,m,,e,7,3,5,5f,8,2,3,,,n,,29,,2,6,,,2,,,2,,2,6j,,2,4,6,2,,2,r,2,2d,8,2,,,2,2y,,,,2,6,,,2t,3,2,4,,5,77,9,,2,6t,,a,2,,,4,,40,4,2,2,4,,w,a,14,6,2,4,8,,9,6,2,3,1a,d,,2,ba,7,,6,,,2a,m,2,7,,2,,2,3e,6,3,,,2,,7,,,20,2,3,,,,9n,2,f0b,5,1n,7,t4,,1r,4,29,,f5k,2,43q,,,3,4,5,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,79,7,c5,4,15s,7,31,7,240,5,gx7k,2o,3k,6o".split(",").map(e=>e?parseInt(e,36):1);for(let e=1;e<p.length;e++)p[e]+=p[e-1];function m(e){return e>=127462&&e<=127487}function g(e,t,n=!0,r=!0){return(n?y:function(e,t,n){for(;t>0;){let r=y(e,t-2,n);if(r<t)return r;t--}return 0})(e,t,r)}function y(e,t,n){if(t==e.length)return t;t&&b(e.charCodeAt(t))&&v(e.charCodeAt(t-1))&&t--;let r=k(e,t);for(t+=D(r);t<e.length;){let i=k(e,t);if(8205==r||8205==i||n&&function(e){for(let t=1;t<p.length;t+=2)if(p[t]>e)return p[t-1]<=e;return!1}(i))t+=D(i),r=i;else if(m(i)){let n=0,r=t-2;for(;r>=0&&m(k(e,r));)n++,r-=2;if(n%2==0)break;t+=2}else break}return t}function b(e){return e>=56320&&e<57344}function v(e){return e>=55296&&e<56320}function k(e,t){let n=e.charCodeAt(t);if(!v(n)||t+1==e.length)return n;let r=e.charCodeAt(t+1);return b(r)?(n-55296<<10)+(r-56320)+65536:n}function w(e){return e<=65535?String.fromCharCode(e):String.fromCharCode(((e-=65536)>>10)+55296,(1023&e)+56320)}function D(e){return e<65536?1:2}let A=/\r\n?|\n/;var x,C,E=((x=E||(E={}))[x.Simple=0]="Simple",x[x.TrackDel=1]="TrackDel",x[x.TrackBefore=2]="TrackBefore",x[x.TrackAfter=3]="TrackAfter",x);class S{constructor(e){this.sections=e}get length(){let e=0;for(let t=0;t<this.sections.length;t+=2)e+=this.sections[t];return e}get newLength(){let e=0;for(let t=0;t<this.sections.length;t+=2){let n=this.sections[t+1];e+=n<0?this.sections[t]:n}return e}get empty(){return 0==this.sections.length||2==this.sections.length&&this.sections[1]<0}iterGaps(e){for(let t=0,n=0,r=0;t<this.sections.length;){let i=this.sections[t++],s=this.sections[t++];s<0?(e(n,r,i),r+=i):r+=s,n+=i}}iterChangedRanges(e,t=!1){P(this,e,t)}get invertedDesc(){let e=[];for(let t=0;t<this.sections.length;){let n=this.sections[t++],r=this.sections[t++];r<0?e.push(n,r):e.push(r,n)}return new S(e)}composeDesc(e){return this.empty?e:e.empty?this:N(this,e)}mapDesc(e,t=!1){return e.empty?this:T(this,e,t)}mapPos(e,t=-1,n=E.Simple){let r=0,i=0;for(let s=0;s<this.sections.length;){let o=this.sections[s++],l=this.sections[s++],a=r+o;if(l<0){if(a>e)return i+(e-r);i+=o}else{if(n!=E.Simple&&a>=e&&(n==E.TrackDel&&r<e&&a>e||n==E.TrackBefore&&r<e||n==E.TrackAfter&&a>e))return null;if(a>e||a==e&&t<0&&!o)return e==r||t<0?i:i+l;i+=l}r=a}if(e>r)throw RangeError(`Position ${e} is out of range for changeset of length ${r}`);return i}touchesRange(e,t=e){for(let n=0,r=0;n<this.sections.length&&r<=t;){let i=this.sections[n++],s=this.sections[n++],o=r+i;if(s>=0&&r<=t&&o>=e)return!(r<e)||!(o>t)||"cover";r=o}return!1}toString(){let e="";for(let t=0;t<this.sections.length;){let n=this.sections[t++],r=this.sections[t++];e+=(e?" ":"")+n+(r>=0?":"+r:"")}return e}toJSON(){return this.sections}static fromJSON(e){if(!Array.isArray(e)||e.length%2||e.some(e=>"number"!=typeof e))throw RangeError("Invalid JSON representation of ChangeDesc");return new S(e)}static create(e){return new S(e)}}class _ extends S{constructor(e,t){super(e),this.inserted=t}apply(e){if(this.length!=e.length)throw RangeError("Applying change set to a document with the wrong length");return P(this,(t,n,r,i,s)=>e=e.replace(r,r+(n-t),s),!1),e}mapDesc(e,t=!1){return T(this,e,t,!0)}invert(e){let t=this.sections.slice(),n=[];for(let r=0,s=0;r<t.length;r+=2){let o=t[r],l=t[r+1];if(l>=0){t[r]=l,t[r+1]=o;let a=r>>1;for(;n.length<a;)n.push(i.empty);n.push(o?e.slice(s,s+o):i.empty)}s+=o}return new _(t,n)}compose(e){return this.empty?e:e.empty?this:N(this,e,!0)}map(e,t=!1){return e.empty?this:T(this,e,t,!0)}iterChanges(e,t=!1){P(this,e,t)}get desc(){return S.create(this.sections)}filter(e){let t=[],n=[],r=[],i=new B(this);t:for(let s=0,o=0;;){let l=s==e.length?1e9:e[s++];for(;o<l||o==l&&0==i.len;){if(i.done)break t;let e=Math.min(i.len,l-o);O(r,e,-1);let s=-1==i.ins?-1:0==i.off?i.ins:0;O(t,e,s),s>0&&F(n,t,i.text),i.forward(e),o+=e}let a=e[s++];for(;o<a;){if(i.done)break t;let e=Math.min(i.len,a-o);O(t,e,-1),O(r,e,-1==i.ins?-1:0==i.off?i.ins:0),i.forward(e),o+=e}}return{changes:new _(t,n),filtered:S.create(r)}}toJSON(){let e=[];for(let t=0;t<this.sections.length;t+=2){let n=this.sections[t],r=this.sections[t+1];r<0?e.push(n):0==r?e.push([n]):e.push([n].concat(this.inserted[t>>1].toJSON()))}return e}static of(e,t,n){let r=[],s=[],o=0,l=null;function a(e=!1){if(!e&&!r.length)return;o<t&&O(r,t-o,-1);let n=new _(r,s);l=l?l.compose(n.map(l)):n,r=[],s=[],o=0}return!function e(u){if(Array.isArray(u))for(let t of u)e(t);else if(u instanceof _){if(u.length!=t)throw RangeError(`Mismatched change set length (got ${u.length}, expected ${t})`);a(),l=l?l.compose(u.map(l)):u}else{let{from:e,to:l=e,insert:h}=u;if(e>l||e<0||l>t)throw RangeError(`Invalid change range ${e} to ${l} (in doc of length ${t})`);let c=h?"string"==typeof h?i.of(h.split(n||A)):h:i.empty,f=c.length;if(e==l&&0==f)return;e<o&&a(),e>o&&O(r,e-o,-1),O(r,l-e,f),F(s,r,c),o=l}}(e),a(!l),l}static empty(e){return new _(e?[e,-1]:[],[])}static fromJSON(e){if(!Array.isArray(e))throw RangeError("Invalid JSON representation of ChangeSet");let t=[],n=[];for(let r=0;r<e.length;r++){let s=e[r];if("number"==typeof s)t.push(s,-1);else if(!Array.isArray(s)||"number"!=typeof s[0]||s.some((e,t)=>t&&"string"!=typeof e))throw RangeError("Invalid JSON representation of ChangeSet");else if(1==s.length)t.push(s[0],0);else{for(;n.length<r;)n.push(i.empty);n[r]=i.of(s.slice(1)),t.push(s[0],n[r].length)}}return new _(t,n)}static createSet(e,t){return new _(e,t)}}function O(e,t,n,r=!1){if(0==t&&n<=0)return;let i=e.length-2;i>=0&&n<=0&&n==e[i+1]?e[i]+=t:0==t&&0==e[i]?e[i+1]+=n:r?(e[i]+=t,e[i+1]+=n):e.push(t,n)}function F(e,t,n){if(0==n.length)return;let r=t.length-2>>1;if(r<e.length)e[e.length-1]=e[e.length-1].append(n);else{for(;e.length<r;)e.push(i.empty);e.push(n)}}function P(e,t,n){let r=e.inserted;for(let s=0,o=0,l=0;l<e.sections.length;){let a=e.sections[l++],u=e.sections[l++];if(u<0)s+=a,o+=a;else{let h=s,c=o,f=i.empty;for(;h+=a,c+=u,u&&r&&(f=f.append(r[l-2>>1])),!n&&l!=e.sections.length&&!(e.sections[l+1]<0);){;a=e.sections[l++],u=e.sections[l++]}t(s,h,o,c,f),s=h,o=c}}}function T(e,t,n,r=!1){let i=[],s=r?[]:null,o=new B(e),l=new B(t);for(let e=-1;;)if(-1==o.ins&&-1==l.ins){let e=Math.min(o.len,l.len);O(i,e,-1),o.forward(e),l.forward(e)}else if(l.ins>=0&&(o.ins<0||e==o.i||0==o.off&&(l.len<o.len||l.len==o.len&&!n))){let t=l.len;for(O(i,l.ins,-1);t;){let n=Math.min(o.len,t);o.ins>=0&&e<o.i&&o.len<=n&&(O(i,0,o.ins),s&&F(s,i,o.text),e=o.i),o.forward(n),t-=n}l.next()}else if(o.ins>=0){let t=0,n=o.len;for(;n;)if(-1==l.ins){let e=Math.min(n,l.len);t+=e,n-=e,l.forward(e)}else if(0==l.ins&&l.len<n)n-=l.len,l.next();else break;O(i,t,e<o.i?o.ins:0),s&&e<o.i&&F(s,i,o.text),e=o.i,o.forward(o.len-n)}else if(o.done&&l.done)return s?_.createSet(i,s):S.create(i);else throw Error("Mismatched change set lengths")}function N(e,t,n=!1){let r=[],i=n?[]:null,s=new B(e),o=new B(t);for(let e=!1;;){if(s.done&&o.done)return i?_.createSet(r,i):S.create(r);if(0==s.ins)O(r,s.len,0,e),s.next();else if(0!=o.len||o.done){if(s.done||o.done)throw Error("Mismatched change set lengths");else{let t=Math.min(s.len2,o.len),n=r.length;if(-1==s.ins){let n=-1==o.ins?-1:o.off?0:o.ins;O(r,t,n,e),i&&n&&F(i,r,o.text)}else -1==o.ins?(O(r,s.off?0:s.len,t,e),i&&F(i,r,s.textBit(t))):(O(r,s.off?0:s.len,o.off?0:o.ins,e),i&&!o.off&&F(i,r,o.text));e=(s.ins>t||o.ins>=0&&o.len>t)&&(e||r.length>n),s.forward2(t),o.forward(t)}}else O(r,0,o.ins,e),i&&F(i,r,o.text),o.next()}}class B{constructor(e){this.set=e,this.i=0,this.next()}next(){let{sections:e}=this.set;this.i<e.length?(this.len=e[this.i++],this.ins=e[this.i++]):(this.len=0,this.ins=-2),this.off=0}get done(){return -2==this.ins}get len2(){return this.ins<0?this.len:this.ins}get text(){let{inserted:e}=this.set,t=this.i-2>>1;return t>=e.length?i.empty:e[t]}textBit(e){let{inserted:t}=this.set,n=this.i-2>>1;return n>=t.length&&!e?i.empty:t[n].slice(this.off,null==e?void 0:this.off+e)}forward(e){e==this.len?this.next():(this.len-=e,this.off+=e)}forward2(e){-1==this.ins?this.forward(e):e==this.ins?this.next():(this.ins-=e,this.off+=e)}}class I{constructor(e,t,n){this.from=e,this.to=t,this.flags=n}get anchor(){return 32&this.flags?this.to:this.from}get head(){return 32&this.flags?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return 8&this.flags?-1:16&this.flags?1:0}get bidiLevel(){let e=7&this.flags;return 7==e?null:e}get goalColumn(){let e=this.flags>>6;return 0xffffff==e?void 0:e}map(e,t=-1){let n,r;return this.empty?n=r=e.mapPos(this.from,t):(n=e.mapPos(this.from,1),r=e.mapPos(this.to,-1)),n==this.from&&r==this.to?this:new I(n,r,this.flags)}extend(e,t=e){if(e<=this.anchor&&t>=this.anchor)return M.range(e,t);let n=Math.abs(e-this.anchor)>Math.abs(t-this.anchor)?e:t;return M.range(this.anchor,n)}eq(e,t=!1){return this.anchor==e.anchor&&this.head==e.head&&(!t||!this.empty||this.assoc==e.assoc)}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(e){if(!e||"number"!=typeof e.anchor||"number"!=typeof e.head)throw RangeError("Invalid JSON representation for SelectionRange");return M.range(e.anchor,e.head)}static create(e,t,n){return new I(e,t,n)}}class M{constructor(e,t){this.ranges=e,this.mainIndex=t}map(e,t=-1){return e.empty?this:M.create(this.ranges.map(n=>n.map(e,t)),this.mainIndex)}eq(e,t=!1){if(this.ranges.length!=e.ranges.length||this.mainIndex!=e.mainIndex)return!1;for(let n=0;n<this.ranges.length;n++)if(!this.ranges[n].eq(e.ranges[n],t))return!1;return!0}get main(){return this.ranges[this.mainIndex]}asSingle(){return 1==this.ranges.length?this:new M([this.main],0)}addRange(e,t=!0){return M.create([e].concat(this.ranges),t?0:this.mainIndex+1)}replaceRange(e,t=this.mainIndex){let n=this.ranges.slice();return n[t]=e,M.create(n,this.mainIndex)}toJSON(){return{ranges:this.ranges.map(e=>e.toJSON()),main:this.mainIndex}}static fromJSON(e){if(!e||!Array.isArray(e.ranges)||"number"!=typeof e.main||e.main>=e.ranges.length)throw RangeError("Invalid JSON representation for EditorSelection");return new M(e.ranges.map(e=>I.fromJSON(e)),e.main)}static single(e,t=e){return new M([M.range(e,t)],0)}static create(e,t=0){if(0==e.length)throw RangeError("A selection needs at least one range");for(let n=0,r=0;r<e.length;r++){let i=e[r];if(i.empty?i.from<=n:i.from<n)return M.normalized(e.slice(),t);n=i.to}return new M(e,t)}static cursor(e,t=0,n,r){return I.create(e,e,(0==t?0:t<0?8:16)|(null==n?7:Math.min(6,n))|(null!=r?r:0xffffff)<<6)}static range(e,t,n,r){let i=(null!=n?n:0xffffff)<<6|(null==r?7:Math.min(6,r));return t<e?I.create(t,e,48|i):I.create(e,t,(t>e?8:0)|i)}static normalized(e,t=0){let n=e[t];e.sort((e,t)=>e.from-t.from),t=e.indexOf(n);for(let n=1;n<e.length;n++){let r=e[n],i=e[n-1];if(r.empty?r.from<=i.to:r.from<i.to){let s=i.from,o=Math.max(r.to,i.to);n<=t&&t--,e.splice(--n,2,r.anchor>r.head?M.range(o,s):M.range(s,o))}}return new M(e,t)}}function $(e,t){for(let n of e.ranges)if(n.to>t)throw RangeError("Selection points outside of document")}let L=0;class R{constructor(e,t,n,r,i){this.combine=e,this.compareInput=t,this.compare=n,this.isStatic=r,this.id=L++,this.default=e([]),this.extensions="function"==typeof i?i(this):i}get reader(){return this}static define(e={}){return new R(e.combine||(e=>e),e.compareInput||((e,t)=>e===t),e.compare||(e.combine?(e,t)=>e===t:j),!!e.static,e.enables)}of(e){return new q([],this,0,e)}compute(e,t){if(this.isStatic)throw Error("Can't compute a static facet");return new q(e,this,1,t)}computeN(e,t){if(this.isStatic)throw Error("Can't compute a static facet");return new q(e,this,2,t)}from(e,t){return!t&&(t=e=>e),this.compute([e],n=>t(n.field(e)))}}function j(e,t){return e==t||e.length==t.length&&e.every((e,n)=>e===t[n])}class q{constructor(e,t,n,r){this.dependencies=e,this.facet=t,this.type=n,this.value=r,this.id=L++}dynamicSlot(e){var t;let n=this.value,r=this.facet.compareInput,i=this.id,s=e[i]>>1,o=2==this.type,l=!1,a=!1,u=[];for(let n of this.dependencies)"doc"==n?l=!0:"selection"==n?a=!0:((null!==(t=e[n.id])&&void 0!==t?t:1)&1)==0&&u.push(e[n.id]);return{create:e=>(e.values[s]=n(e),1),update(e,t){if(l&&t.docChanged||a&&(t.docChanged||t.selection)||z(e,u)){let t=n(e);if(o?!V(t,e.values[s],r):!r(t,e.values[s]))return e.values[s]=t,1}return 0},reconfigure:(e,t)=>{let l,a=t.config.address[i];if(null!=a){let i=ee(t,a);if(this.dependencies.every(n=>n instanceof R?t.facet(n)===e.facet(n):!(n instanceof H)||t.field(n,!1)==e.field(n,!1))||(o?V(l=n(e),i,r):r(l=n(e),i)))return e.values[s]=i,0}else l=n(e);return e.values[s]=l,1}}}}function V(e,t,n){if(e.length!=t.length)return!1;for(let r=0;r<e.length;r++)if(!n(e[r],t[r]))return!1;return!0}function z(e,t){let n=!1;for(let r of t)1&X(e,r)&&(n=!0);return n}let U=R.define({static:!0});class H{constructor(e,t,n,r,i){this.id=e,this.createF=t,this.updateF=n,this.compareF=r,this.spec=i,this.provides=void 0}static define(e){let t=new H(L++,e.create,e.update,e.compare||((e,t)=>e===t),e);return e.provide&&(t.provides=e.provide(t)),t}create(e){let t=e.facet(U).find(e=>e.field==this);return((null==t?void 0:t.create)||this.createF)(e)}slot(e){let t=e[this.id]>>1;return{create:e=>(e.values[t]=this.create(e),1),update:(e,n)=>{let r=e.values[t],i=this.updateF(r,n);return this.compareF(r,i)?0:(e.values[t]=i,1)},reconfigure:(e,n)=>null!=n.config.address[this.id]?(e.values[t]=n.field(this),0):(e.values[t]=this.create(e),1)}}init(e){return[this,U.of({field:this,create:e})]}get extension(){return this}}let W={lowest:4,low:3,default:2,high:1,highest:0};function G(e){return t=>new J(t,e)}let K={highest:G(W.highest),high:G(W.high),default:G(W.default),low:G(W.low),lowest:G(W.lowest)};class J{constructor(e,t){this.inner=e,this.prec=t}}class Q{of(e){return new Y(this,e)}reconfigure(e){return Q.reconfigure.of({compartment:this,extension:e})}get(e){return e.config.compartments.get(this)}}class Y{constructor(e,t){this.compartment=e,this.inner=t}}class Z{constructor(e,t,n,r,i,s){for(this.base=e,this.compartments=t,this.dynamicSlots=n,this.address=r,this.staticValues=i,this.facets=s,this.statusTemplate=[];this.statusTemplate.length<n.length;)this.statusTemplate.push(0)}staticFacet(e){let t=this.address[e.id];return null==t?e.default:this.staticValues[t>>1]}static resolve(e,t,n){let r=[],i=Object.create(null),s=new Map;for(let n of function(e,t,n){let r=[[],[],[],[],[]],i=new Map;return!function e(s,o){let l=i.get(s);if(null!=l){if(l<=o)return;let e=r[l].indexOf(s);e>-1&&r[l].splice(e,1),s instanceof Y&&n.delete(s.compartment)}if(i.set(s,o),Array.isArray(s))for(let t of s)e(t,o);else if(s instanceof Y){if(n.has(s.compartment))throw RangeError("Duplicate use of compartment in extensions");let r=t.get(s.compartment)||s.inner;n.set(s.compartment,r),e(r,o)}else if(s instanceof J)e(s.inner,s.prec);else if(s instanceof H)r[o].push(s),s.provides&&e(s.provides,o);else if(s instanceof q)r[o].push(s),s.facet.extensions&&e(s.facet.extensions,W.default);else{let t=s.extension;if(!t)throw Error(`Unrecognized extension value in extension set (${s}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);e(t,o)}}(e,W.default),r.reduce((e,t)=>e.concat(t))}(e,t,s))n instanceof H?r.push(n):(i[n.facet.id]||(i[n.facet.id]=[])).push(n);let o=Object.create(null),l=[],a=[];for(let e of r)o[e.id]=a.length<<1,a.push(t=>e.slot(t));let u=null==n?void 0:n.config.facets;for(let e in i){let t=i[e],r=t[0].facet,s=u&&u[e]||[];if(t.every(e=>0==e.type)){if(o[r.id]=l.length<<1|1,j(s,t))l.push(n.facet(r));else{let e=r.combine(t.map(e=>e.value));l.push(n&&r.compare(e,n.facet(r))?n.facet(r):e)}}else{for(let e of t)0==e.type?(o[e.id]=l.length<<1|1,l.push(e.value)):(o[e.id]=a.length<<1,a.push(t=>e.dynamicSlot(t)));o[r.id]=a.length<<1,a.push(e=>(function(e,t,n){let r=n.map(t=>e[t.id]),i=n.map(e=>e.type),s=r.filter(e=>!(1&e)),o=e[t.id]>>1;function l(e){let n=[];for(let t=0;t<r.length;t++){let s=ee(e,r[t]);if(2==i[t])for(let e of s)n.push(e);else n.push(s)}return t.combine(n)}return{create(e){for(let t of r)X(e,t);return e.values[o]=l(e),1},update(e,n){if(!z(e,s))return 0;let r=l(e);return t.compare(r,e.values[o])?0:(e.values[o]=r,1)},reconfigure(e,i){let s=z(e,r),a=i.config.facets[t.id],u=i.facet(t);if(a&&!s&&j(n,a))return e.values[o]=u,0;let h=l(e);return t.compare(h,u)?(e.values[o]=u,0):(e.values[o]=h,1)}}})(e,r,t))}}return new Z(e,s,a.map(e=>e(o)),o,l,i)}}function X(e,t){if(1&t)return 2;let n=t>>1,r=e.status[n];if(4==r)throw Error("Cyclic dependency between fields and/or facets");if(2&r)return r;e.status[n]=4;let i=e.computeSlot(e,e.config.dynamicSlots[n]);return e.status[n]=2|i}function ee(e,t){return 1&t?e.config.staticValues[t>>1]:e.values[t>>1]}let et=R.define(),en=R.define({combine:e=>e.some(e=>e),static:!0}),er=R.define({combine:e=>e.length?e[0]:void 0,static:!0}),ei=R.define(),es=R.define(),eo=R.define(),el=R.define({combine:e=>!!e.length&&e[0]});class ea{constructor(e,t){this.type=e,this.value=t}static define(){return new eu}}class eu{of(e){return new ea(this,e)}}class eh{constructor(e){this.map=e}of(e){return new ec(this,e)}}class ec{constructor(e,t){this.type=e,this.value=t}map(e){let t=this.type.map(this.value,e);return void 0===t?void 0:t==this.value?this:new ec(this.type,t)}is(e){return this.type==e}static define(e={}){return new eh(e.map||(e=>e))}static mapEffects(e,t){if(!e.length)return e;let n=[];for(let r of e){let e=r.map(t);e&&n.push(e)}return n}}ec.reconfigure=ec.define(),ec.appendConfig=ec.define();class ef{constructor(e,t,n,r,i,s){this.startState=e,this.changes=t,this.selection=n,this.effects=r,this.annotations=i,this.scrollIntoView=s,this._doc=null,this._state=null,n&&$(n,t.newLength),!i.some(e=>e.type==ef.time)&&(this.annotations=i.concat(ef.time.of(Date.now())))}static create(e,t,n,r,i,s){return new ef(e,t,n,r,i,s)}get newDoc(){return this._doc||(this._doc=this.changes.apply(this.startState.doc))}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return!this._state&&this.startState.applyTransaction(this),this._state}annotation(e){for(let t of this.annotations)if(t.type==e)return t.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(e){let t=this.annotation(ef.userEvent);return!!(t&&(t==e||t.length>e.length&&t.slice(0,e.length)==e&&"."==t[e.length]))}}ef.time=ea.define(),ef.userEvent=ea.define(),ef.addToHistory=ea.define(),ef.remote=ea.define();function ed(e,t,n){var r;let i,s,o;return n?(i=t.changes,s=_.empty(t.changes.length),o=e.changes.compose(t.changes)):(i=t.changes.map(e.changes),s=e.changes.mapDesc(t.changes,!0),o=e.changes.compose(i)),{changes:o,selection:t.selection?t.selection.map(s):null===(r=e.selection)||void 0===r?void 0:r.map(i),effects:ec.mapEffects(e.effects,i).concat(ec.mapEffects(t.effects,s)),annotations:e.annotations.length?e.annotations.concat(t.annotations):t.annotations,scrollIntoView:e.scrollIntoView||t.scrollIntoView}}function ep(e,t,n){let r=t.selection,i=ey(t.annotations);return t.userEvent&&(i=i.concat(ef.userEvent.of(t.userEvent))),{changes:t.changes instanceof _?t.changes:_.of(t.changes||[],n,e.facet(er)),selection:r&&(r instanceof M?r:M.single(r.anchor,r.head)),effects:ey(t.effects),annotations:i,scrollIntoView:!!t.scrollIntoView}}function em(e,t,n){let r=ep(e,t.length?t[0]:{},e.doc.length);t.length&&!1===t[0].filter&&(n=!1);for(let i=1;i<t.length;i++){!1===t[i].filter&&(n=!1);let s=!!t[i].sequential;r=ed(r,ep(e,t[i],s?r.changes.newLength:e.doc.length),s)}let i=ef.create(e,r.changes,r.selection,r.effects,r.annotations,r.scrollIntoView);return function(e){let t=e.startState,n=t.facet(eo),r=e;for(let i=n.length-1;i>=0;i--){let s=n[i](e);s&&Object.keys(s).length&&(r=ed(r,ep(t,s,e.changes.newLength),!0))}return r==e?e:ef.create(t,e.changes,e.selection,r.effects,r.annotations,r.scrollIntoView)}(n?function(e){let t=e.startState,n=!0;for(let r of t.facet(ei)){let t=r(e);if(!1===t){n=!1;break}Array.isArray(t)&&(n=!0===n?t:function(e,t){let n=[];for(let r=0,i=0;;){let s,o;if(r<e.length&&(i==t.length||t[i]>=e[r]))s=e[r++],o=e[r++];else{if(!(i<t.length))return n;s=t[i++],o=t[i++]}!n.length||n[n.length-1]<s?n.push(s,o):n[n.length-1]<o&&(n[n.length-1]=o)}}(n,t))}if(!0!==n){let r,i;if(!1===n)i=e.changes.invertedDesc,r=_.empty(t.doc.length);else{let t=e.changes.filter(n);r=t.changes,i=t.filtered.mapDesc(t.changes).invertedDesc}e=ef.create(t,r,e.selection&&e.selection.map(i),ec.mapEffects(e.effects,i),e.annotations,e.scrollIntoView)}let r=t.facet(es);for(let n=r.length-1;n>=0;n--){let i=r[n](e);e=i instanceof ef?i:Array.isArray(i)&&1==i.length&&i[0]instanceof ef?i[0]:em(t,ey(i),!1)}return e}(i):i)}let eg=[];function ey(e){return null==e?eg:Array.isArray(e)?e:[e]}var eb=((C=eb||(eb={}))[C.Word=0]="Word",C[C.Space=1]="Space",C[C.Other=2]="Other",C);let ev=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;try{r=RegExp("[\\p{Alphabetic}\\p{Number}_]","u")}catch(e){}class ek{constructor(e,t,n,r,i,s){this.config=e,this.doc=t,this.selection=n,this.values=r,this.status=e.statusTemplate.slice(),this.computeSlot=i,s&&(s._state=this);for(let e=0;e<this.config.dynamicSlots.length;e++)X(this,e<<1);this.computeSlot=null}field(e,t=!0){let n=this.config.address[e.id];if(null==n){if(t)throw RangeError("Field is not present in this state");return}return X(this,n),ee(this,n)}update(...e){return em(this,e,!0)}applyTransaction(e){let t,n=this.config,{base:r,compartments:i}=n;for(let t of e.effects)t.is(Q.reconfigure)?(n&&(i=new Map,n.compartments.forEach((e,t)=>i.set(t,e)),n=null),i.set(t.value.compartment,t.value.extension)):t.is(ec.reconfigure)?(n=null,r=t.value):t.is(ec.appendConfig)&&(n=null,r=ey(r).concat(t.value));t=n?e.startState.values.slice():new ek(n=Z.resolve(r,i,this),this.doc,this.selection,n.dynamicSlots.map(()=>null),(e,t)=>t.reconfigure(e,this),null).values;let s=e.startState.facet(en)?e.newSelection:e.newSelection.asSingle();new ek(n,e.newDoc,s,t,(t,n)=>n.update(t,e),e)}replaceSelection(e){return"string"==typeof e&&(e=this.toText(e)),this.changeByRange(t=>({changes:{from:t.from,to:t.to,insert:e},range:M.cursor(t.from+e.length)}))}changeByRange(e){let t=this.selection,n=e(t.ranges[0]),r=this.changes(n.changes),i=[n.range],s=ey(n.effects);for(let n=1;n<t.ranges.length;n++){let o=e(t.ranges[n]),l=this.changes(o.changes),a=l.map(r);for(let e=0;e<n;e++)i[e]=i[e].map(a);let u=r.mapDesc(l,!0);i.push(o.range.map(u)),r=r.compose(a),s=ec.mapEffects(s,a).concat(ec.mapEffects(ey(o.effects),u))}return{changes:r,selection:M.create(i,t.mainIndex),effects:s}}changes(e=[]){return e instanceof _?e:_.of(e,this.doc.length,this.facet(ek.lineSeparator))}toText(e){return i.of(e.split(this.facet(ek.lineSeparator)||A))}sliceDoc(e=0,t=this.doc.length){return this.doc.sliceString(e,t,this.lineBreak)}facet(e){let t=this.config.address[e.id];return null==t?e.default:(X(this,t),ee(this,t))}toJSON(e){let t={doc:this.sliceDoc(),selection:this.selection.toJSON()};if(e)for(let n in e){let r=e[n];r instanceof H&&null!=this.config.address[r.id]&&(t[n]=r.spec.toJSON(this.field(e[n]),this))}return t}static fromJSON(e,t={},n){if(!e||"string"!=typeof e.doc)throw RangeError("Invalid JSON representation for EditorState");let r=[];if(n){for(let t in n)if(Object.prototype.hasOwnProperty.call(e,t)){let i=n[t],s=e[t];r.push(i.init(e=>i.spec.fromJSON(s,e)))}}return ek.create({doc:e.doc,selection:M.fromJSON(e.selection),extensions:t.extensions?r.concat([t.extensions]):r})}static create(e={}){let t=Z.resolve(e.extensions||[],new Map),n=e.doc instanceof i?e.doc:i.of((e.doc||"").split(t.staticFacet(ek.lineSeparator)||A)),r=e.selection?e.selection instanceof M?e.selection:M.single(e.selection.anchor,e.selection.head):M.single(0);return $(r,n.length),!t.staticFacet(en)&&(r=r.asSingle()),new ek(t,n,r,t.dynamicSlots.map(()=>null),(e,t)=>t.create(e),null)}get tabSize(){return this.facet(ek.tabSize)}get lineBreak(){return this.facet(ek.lineSeparator)||"\n"}get readOnly(){return this.facet(el)}phrase(e,...t){for(let t of this.facet(ek.phrases))if(Object.prototype.hasOwnProperty.call(t,e)){e=t[e];break}return t.length&&(e=e.replace(/\$(\$|\d*)/g,(e,n)=>{if("$"==n)return"$";let r=+(n||1);return!r||r>t.length?e:t[r-1]})),e}languageDataAt(e,t,n=-1){let r=[];for(let i of this.facet(et))for(let s of i(this,t,n))Object.prototype.hasOwnProperty.call(s,e)&&r.push(s[e]);return r}charCategorizer(e){var t;return t=this.languageDataAt("wordChars",e).join(""),e=>{if(!/\S/.test(e))return eb.Space;if(function(e){if(r)return r.test(e);for(let t=0;t<e.length;t++){let n=e[t];if(/\w/.test(n)||n>"\x80"&&(n.toUpperCase()!=n.toLowerCase()||ev.test(n)))return!0}return!1}(e))return eb.Word;for(let n=0;n<t.length;n++)if(e.indexOf(t[n])>-1)return eb.Word;return eb.Other}}wordAt(e){let{text:t,from:n,length:r}=this.doc.lineAt(e),i=this.charCategorizer(e),s=e-n,o=e-n;for(;s>0;){let e=g(t,s,!1);if(i(t.slice(e,s))!=eb.Word)break;s=e}for(;o<r;){let e=g(t,o);if(i(t.slice(o,e))!=eb.Word)break;o=e}return s==o?null:M.range(s+n,o+n)}}function ew(e,t,n={}){let r={};for(let t of e)for(let e of Object.keys(t)){let i=t[e],s=r[e];if(void 0===s)r[e]=i;else if(s===i||void 0===i);else if(Object.hasOwnProperty.call(n,e))r[e]=n[e](s,i);else throw Error("Config merge conflict for field "+e)}for(let e in t)void 0===r[e]&&(r[e]=t[e]);return r}ek.allowMultipleSelections=en,ek.tabSize=R.define({combine:e=>e.length?e[0]:4}),ek.lineSeparator=er,ek.readOnly=el,ek.phrases=R.define({compare(e,t){let n=Object.keys(e),r=Object.keys(t);return n.length==r.length&&n.every(n=>e[n]==t[n])}}),ek.languageData=et,ek.changeFilter=ei,ek.transactionFilter=es,ek.transactionExtender=eo,Q.reconfigure=ec.define();class eD{eq(e){return this==e}range(e,t=e){return eA.create(e,t,this)}}eD.prototype.startSide=eD.prototype.endSide=0,eD.prototype.point=!1,eD.prototype.mapMode=E.TrackDel;class eA{constructor(e,t,n){this.from=e,this.to=t,this.value=n}static create(e,t,n){return new eA(e,t,n)}}function ex(e,t){return e.from-t.from||e.value.startSide-t.value.startSide}class eC{constructor(e,t,n,r){this.from=e,this.to=t,this.value=n,this.maxPoint=r}get length(){return this.to[this.to.length-1]}findIndex(e,t,n,r=0){let i=n?this.to:this.from;for(let s=r,o=i.length;;){if(s==o)return s;let r=s+o>>1,l=i[r]-e||(n?this.value[r].endSide:this.value[r].startSide)-t;if(r==s)return l>=0?s:o;l>=0?o=r:s=r+1}}between(e,t,n,r){for(let i=this.findIndex(t,-1e9,!0),s=this.findIndex(n,1e9,!1,i);i<s;i++)if(!1===r(this.from[i]+e,this.to[i]+e,this.value[i]))return!1}map(e,t){let n=[],r=[],i=[],s=-1,o=-1;for(let l=0;l<this.value.length;l++){let a=this.value[l],u=this.from[l]+e,h=this.to[l]+e,c,f;if(u==h){let e=t.mapPos(u,a.startSide,a.mapMode);if(null==e)continue;if(c=f=e,a.startSide!=a.endSide&&(f=t.mapPos(u,a.endSide))<c)continue}else if(c=t.mapPos(u,a.startSide),c>(f=t.mapPos(h,a.endSide))||c==f&&a.startSide>0&&a.endSide<=0)continue;!(0>(f-c||a.endSide-a.startSide))&&(s<0&&(s=c),a.point&&(o=Math.max(o,f-c)),n.push(a),r.push(c-s),i.push(f-s))}return{mapped:n.length?new eC(r,i,n,o):null,pos:s}}}class eE{constructor(e,t,n,r){this.chunkPos=e,this.chunk=t,this.nextLayer=n,this.maxPoint=r}static create(e,t,n,r){return new eE(e,t,n,r)}get length(){let e=this.chunk.length-1;return e<0?0:Math.max(this.chunkEnd(e),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let e=this.nextLayer.size;for(let t of this.chunk)e+=t.value.length;return e}chunkEnd(e){return this.chunkPos[e]+this.chunk[e].length}update(e){let{add:t=[],sort:n=!1,filterFrom:r=0,filterTo:i=this.length}=e,s=e.filter;if(0==t.length&&!s)return this;if(n&&(t=t.slice().sort(ex)),this.isEmpty)return t.length?eE.of(t):this;let o=new eO(this,null,-1).goto(0),l=0,a=[],u=new eS;for(;o.value||l<t.length;)if(l<t.length&&(o.from-t[l].from||o.startSide-t[l].value.startSide)>=0){let e=t[l++];!u.addInner(e.from,e.to,e.value)&&a.push(e)}else 1==o.rangeIndex&&o.chunkIndex<this.chunk.length&&(l==t.length||this.chunkEnd(o.chunkIndex)<t[l].from)&&(!s||r>this.chunkEnd(o.chunkIndex)||i<this.chunkPos[o.chunkIndex])&&u.addChunk(this.chunkPos[o.chunkIndex],this.chunk[o.chunkIndex])?o.nextChunk():((!s||r>o.to||i<o.from||s(o.from,o.to,o.value))&&!u.addInner(o.from,o.to,o.value)&&a.push(eA.create(o.from,o.to,o.value)),o.next());return u.finishInner(this.nextLayer.isEmpty&&!a.length?eE.empty:this.nextLayer.update({add:a,filter:s,filterFrom:r,filterTo:i}))}map(e){if(e.empty||this.isEmpty)return this;let t=[],n=[],r=-1;for(let i=0;i<this.chunk.length;i++){let s=this.chunkPos[i],o=this.chunk[i],l=e.touchesRange(s,s+o.length);if(!1===l)r=Math.max(r,o.maxPoint),t.push(o),n.push(e.mapPos(s));else if(!0===l){let{mapped:i,pos:l}=o.map(s,e);i&&(r=Math.max(r,i.maxPoint),t.push(i),n.push(l))}}let i=this.nextLayer.map(e);return 0==t.length?i:new eE(n,t,i||eE.empty,r)}between(e,t,n){if(!this.isEmpty){for(let r=0;r<this.chunk.length;r++){let i=this.chunkPos[r],s=this.chunk[r];if(t>=i&&e<=i+s.length&&!1===s.between(i,e-i,t-i,n))return}this.nextLayer.between(e,t,n)}}iter(e=0){return eF.from([this]).goto(e)}get isEmpty(){return this.nextLayer==this}static iter(e,t=0){return eF.from(e).goto(t)}static compare(e,t,n,r,i=-1){let s=e.filter(e=>e.maxPoint>0||!e.isEmpty&&e.maxPoint>=i),o=t.filter(e=>e.maxPoint>0||!e.isEmpty&&e.maxPoint>=i),l=e_(s,o,n),a=new eT(s,l,i),u=new eT(o,l,i);n.iterGaps((e,t,n)=>eN(a,e,u,t,n,r)),n.empty&&0==n.length&&eN(a,0,u,0,0,r)}static eq(e,t,n=0,r){null==r&&(r=0x3b9ac9ff);let i=e.filter(e=>!e.isEmpty&&0>t.indexOf(e)),s=t.filter(t=>!t.isEmpty&&0>e.indexOf(t));if(i.length!=s.length)return!1;if(!i.length)return!0;let o=e_(i,s),l=new eT(i,o,0).goto(n),a=new eT(s,o,0).goto(n);for(;;){if(l.to!=a.to||!eB(l.active,a.active)||l.point&&(!a.point||!l.point.eq(a.point)))return!1;if(l.to>r)return!0;l.next(),a.next()}}static spans(e,t,n,r,i=-1){let s=new eT(e,null,i).goto(t),o=t,l=s.openStart;for(;;){let e=Math.min(s.to,n);if(s.point){let n=s.activeForPoint(s.to),i=s.pointFrom<t?n.length+1:s.point.startSide<0?n.length:Math.min(n.length,l);r.point(o,e,s.point,n,i,s.pointRank),l=Math.min(s.openEnd(e),n.length)}else e>o&&(r.span(o,e,s.active,l),l=s.openEnd(e));if(s.to>n)return l+(s.point&&s.to>n?1:0);o=s.to,s.next()}}static of(e,t=!1){let n=new eS;for(let r of e instanceof eA?[e]:t?function(e){if(e.length>1)for(let t=e[0],n=1;n<e.length;n++){let r=e[n];if(ex(t,r)>0)return e.slice().sort(ex);t=r}return e}(e):e)n.add(r.from,r.to,r.value);return n.finish()}static join(e){if(!e.length)return eE.empty;let t=e[e.length-1];for(let n=e.length-2;n>=0;n--)for(let r=e[n];r!=eE.empty;r=r.nextLayer)t=new eE(r.chunkPos,r.chunk,t,Math.max(r.maxPoint,t.maxPoint));return t}}eE.empty=new eE([],[],null,-1);eE.empty.nextLayer=eE.empty;class eS{finishChunk(e){this.chunks.push(new eC(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,e&&(this.from=[],this.to=[],this.value=[])}constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}add(e,t,n){!this.addInner(e,t,n)&&(this.nextLayer||(this.nextLayer=new eS)).add(e,t,n)}addInner(e,t,n){let r=e-this.lastTo||n.startSide-this.last.endSide;if(r<=0&&0>(e-this.lastFrom||n.startSide-this.last.startSide))throw Error("Ranges must be added sorted by `from` position and `startSide`");return!(r<0)&&(250==this.from.length&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=e),this.from.push(e-this.chunkStart),this.to.push(t-this.chunkStart),this.last=n,this.lastFrom=e,this.lastTo=t,this.value.push(n),n.point&&(this.maxPoint=Math.max(this.maxPoint,t-e)),!0)}addChunk(e,t){if(0>(e-this.lastTo||t.value[0].startSide-this.last.endSide))return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,t.maxPoint),this.chunks.push(t),this.chunkPos.push(e);let n=t.value.length-1;return this.last=t.value[n],this.lastFrom=t.from[n]+e,this.lastTo=t.to[n]+e,!0}finish(){return this.finishInner(eE.empty)}finishInner(e){if(this.from.length&&this.finishChunk(!1),0==this.chunks.length)return e;let t=eE.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(e):e,this.setMaxPoint);return this.from=null,t}}function e_(e,t,n){let r=new Map;for(let t of e)for(let e=0;e<t.chunk.length;e++)t.chunk[e].maxPoint<=0&&r.set(t.chunk[e],t.chunkPos[e]);let i=new Set;for(let e of t)for(let t=0;t<e.chunk.length;t++){let s=r.get(e.chunk[t]);null!=s&&(n?n.mapPos(s):s)==e.chunkPos[t]&&!(null==n?void 0:n.touchesRange(s,s+e.chunk[t].length))&&i.add(e.chunk[t])}return i}class eO{constructor(e,t,n,r=0){this.layer=e,this.skip=t,this.minPoint=n,this.rank=r}get startSide(){return this.value?this.value.startSide:0}get endSide(){return this.value?this.value.endSide:0}goto(e,t=-1e9){return this.chunkIndex=this.rangeIndex=0,this.gotoInner(e,t,!1),this}gotoInner(e,t,n){for(;this.chunkIndex<this.layer.chunk.length;){let t=this.layer.chunk[this.chunkIndex];if(!(this.skip&&this.skip.has(t)||this.layer.chunkEnd(this.chunkIndex)<e||t.maxPoint<this.minPoint))break;this.chunkIndex++,n=!1}if(this.chunkIndex<this.layer.chunk.length){let r=this.layer.chunk[this.chunkIndex].findIndex(e-this.layer.chunkPos[this.chunkIndex],t,!0);(!n||this.rangeIndex<r)&&this.setRangeIndex(r)}this.next()}forward(e,t){0>(this.to-e||this.endSide-t)&&this.gotoInner(e,t,!0)}next(){for(;;){if(this.chunkIndex==this.layer.chunk.length){this.from=this.to=1e9,this.value=null;break}{let e=this.layer.chunkPos[this.chunkIndex],t=this.layer.chunk[this.chunkIndex],n=e+t.from[this.rangeIndex];if(this.from=n,this.to=e+t.to[this.rangeIndex],this.value=t.value[this.rangeIndex],this.setRangeIndex(this.rangeIndex+1),this.minPoint<0||this.value.point&&this.to-this.from>=this.minPoint)break}}}setRangeIndex(e){if(e==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)for(;this.chunkIndex<this.layer.chunk.length&&this.skip.has(this.layer.chunk[this.chunkIndex]);)this.chunkIndex++;this.rangeIndex=0}else this.rangeIndex=e}nextChunk(){this.chunkIndex++,this.rangeIndex=0,this.next()}compare(e){return this.from-e.from||this.startSide-e.startSide||this.rank-e.rank||this.to-e.to||this.endSide-e.endSide}}class eF{constructor(e){this.heap=e}static from(e,t=null,n=-1){let r=[];for(let i=0;i<e.length;i++)for(let s=e[i];!s.isEmpty;s=s.nextLayer)s.maxPoint>=n&&r.push(new eO(s,t,n,i));return 1==r.length?r[0]:new eF(r)}get startSide(){return this.value?this.value.startSide:0}goto(e,t=-1e9){for(let n of this.heap)n.goto(e,t);for(let e=this.heap.length>>1;e>=0;e--)eP(this.heap,e);return this.next(),this}forward(e,t){for(let n of this.heap)n.forward(e,t);for(let e=this.heap.length>>1;e>=0;e--)eP(this.heap,e);0>(this.to-e||this.value.endSide-t)&&this.next()}next(){if(0==this.heap.length)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let e=this.heap[0];this.from=e.from,this.to=e.to,this.value=e.value,this.rank=e.rank,e.value&&e.next(),eP(this.heap,0)}}}function eP(e,t){for(let n=e[t];;){let r=(t<<1)+1;if(r>=e.length)break;let i=e[r];if(r+1<e.length&&i.compare(e[r+1])>=0&&(i=e[r+1],r++),0>n.compare(i))break;e[r]=n,e[t]=i,t=r}}class eT{constructor(e,t,n){this.minPoint=n,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=eF.from(e,t,n)}goto(e,t=-1e9){return this.cursor.goto(e,t),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=e,this.endSide=t,this.openStart=-1,this.next(),this}forward(e,t){for(;this.minActive>-1&&0>(this.activeTo[this.minActive]-e||this.active[this.minActive].endSide-t);)this.removeActive(this.minActive);this.cursor.forward(e,t)}removeActive(e){eI(this.active,e),eI(this.activeTo,e),eI(this.activeRank,e),this.minActive=e$(this.active,this.activeTo)}addActive(e){let t=0,{value:n,to:r,rank:i}=this.cursor;for(;t<this.activeRank.length&&(i-this.activeRank[t]||r-this.activeTo[t])>0;)t++;eM(this.active,t,n),eM(this.activeTo,t,r),eM(this.activeRank,t,i),e&&eM(e,t,this.cursor.from),this.minActive=e$(this.active,this.activeTo)}next(){let e=this.to,t=this.point;this.point=null;let n=this.openStart<0?[]:null;for(;;){let r=this.minActive;if(r>-1&&0>(this.activeTo[r]-this.cursor.from||this.active[r].endSide-this.cursor.startSide)){if(this.activeTo[r]>e){this.to=this.activeTo[r],this.endSide=this.active[r].endSide;break}this.removeActive(r),n&&eI(n,r)}else if(this.cursor.value){if(this.cursor.from>e){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}else{let e=this.cursor.value;if(e.point){if(t&&this.cursor.to==this.to&&this.cursor.from<this.cursor.to)this.cursor.next();else{this.point=e,this.pointFrom=this.cursor.from,this.pointRank=this.cursor.rank,this.to=this.cursor.to,this.endSide=e.endSide,this.cursor.next(),this.forward(this.to,this.endSide);break}}else this.addActive(n),this.cursor.next()}}else{this.to=this.endSide=1e9;break}}if(n){this.openStart=0;for(let t=n.length-1;t>=0&&n[t]<e;t--)this.openStart++}}activeForPoint(e){if(!this.active.length)return this.active;let t=[];for(let n=this.active.length-1;n>=0&&!(this.activeRank[n]<this.pointRank);n--)(this.activeTo[n]>e||this.activeTo[n]==e&&this.active[n].endSide>=this.point.endSide)&&t.push(this.active[n]);return t.reverse()}openEnd(e){let t=0;for(let n=this.activeTo.length-1;n>=0&&this.activeTo[n]>e;n--)t++;return t}}function eN(e,t,n,r,i,s){e.goto(t),n.goto(r);let o=r+i,l=r,a=r-t;for(;;){let t=e.to+a-n.to||e.endSide-n.endSide,r=t<0?e.to+a:n.to,i=Math.min(r,o);if(e.point||n.point?!(e.point&&n.point&&(e.point==n.point||e.point.eq(n.point))&&eB(e.activeForPoint(e.to),n.activeForPoint(n.to)))&&s.comparePoint(l,i,e.point,n.point):i>l&&!eB(e.active,n.active)&&s.compareRange(l,i,e.active,n.active),r>o)break;l=r,t<=0&&e.next(),t>=0&&n.next()}}function eB(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!=t[n]&&!e[n].eq(t[n]))return!1;return!0}function eI(e,t){for(let n=t,r=e.length-1;n<r;n++)e[n]=e[n+1];e.pop()}function eM(e,t,n){for(let n=e.length-1;n>=t;n--)e[n+1]=e[n];e[t]=n}function e$(e,t){let n=-1,r=1e9;for(let i=0;i<t.length;i++)0>(t[i]-r||e[i].endSide-e[n].endSide)&&(n=i,r=t[i]);return n}function eL(e,t,n=e.length){let r=0;for(let i=0;i<n;)9==e.charCodeAt(i)?(r+=t-r%t,i++):(r++,i=g(e,i));return r}function eR(e,t,n,r){for(let r=0,i=0;;){if(i>=t)return r;if(r==e.length)break;i+=9==e.charCodeAt(r)?n-i%n:1,r=g(e,r)}return!0===r?-1:e.length}},76621:function(e,t,n){"use strict";let r;n.d(t,{v5:()=>ru,HQ:()=>rS,OO:()=>eQ,mH:()=>ri,hJ:()=>n1,p:()=>ep,bF:()=>n4,$f:()=>nS,Eu:()=>rA,SJ:()=>rs,lg:()=>e0,l9:()=>ef,Uw:()=>nL,Nm:()=>eA,tk:()=>nv,Sd:()=>re,gB:()=>n6});for(var i,s,o,l=n("8954"),a=n("81965"),u={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},h={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},c="undefined"!=typeof navigator&&/Mac/.test(navigator.platform),f="undefined"!=typeof navigator&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),d=0;d<10;d++)u[48+d]=u[96+d]=String(d);for(var d=1;d<=24;d++)u[d+111]="F"+d;for(var d=65;d<=90;d++)u[d]=String.fromCharCode(d+32),h[d]=String.fromCharCode(d);for(var p in u)!h.hasOwnProperty(p)&&(h[p]=u[p]);function m(e){let t;return(t=11==e.nodeType?e.getSelection?e:e.ownerDocument:e).getSelection()}function g(e,t){return!!t&&(e==t||e.contains(1!=t.nodeType?t.parentNode:t))}function y(e,t){if(!t.anchorNode)return!1;try{return g(e,t.anchorNode)}catch(e){return!1}}function b(e){return 3==e.nodeType?O(e,0,e.nodeValue.length).getClientRects():1==e.nodeType?e.getClientRects():[]}function v(e,t,n,r){return!!n&&(D(e,t,n,r,-1)||D(e,t,n,r,1))}function k(e){for(var t=0;;t++)if(!(e=e.previousSibling))return t}function w(e){return 1==e.nodeType&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(e.nodeName)}function D(e,t,n,r,i){for(;;){if(e==n&&t==r)return!0;if(t==(i<0?0:A(e))){if("DIV"==e.nodeName)return!1;let n=e.parentNode;if(!n||1!=n.nodeType)return!1;t=k(e)+(i<0?0:1),e=n}else{if(1!=e.nodeType)return!1;if(1==(e=e.childNodes[t+(i<0?-1:0)]).nodeType&&"false"==e.contentEditable)return!1;t=i<0?A(e):0}}}function A(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}function x(e,t){let n=t?e.left:e.right;return{left:n,right:n,top:e.top,bottom:e.bottom}}function C(e,t){let n=t.width/e.offsetWidth,r=t.height/e.offsetHeight;return(n>.995&&n<1.005||!isFinite(n)||1>Math.abs(t.width-e.offsetWidth))&&(n=1),(r>.995&&r<1.005||!isFinite(r)||1>Math.abs(t.height-e.offsetHeight))&&(r=1),{scaleX:n,scaleY:r}}class E{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}eq(e){return this.anchorNode==e.anchorNode&&this.anchorOffset==e.anchorOffset&&this.focusNode==e.focusNode&&this.focusOffset==e.focusOffset}setRange(e){let{anchorNode:t,focusNode:n}=e;this.set(t,Math.min(e.anchorOffset,t?A(t):0),n,Math.min(e.focusOffset,n?A(n):0))}set(e,t,n,r){this.anchorNode=e,this.anchorOffset=t,this.focusNode=n,this.focusOffset=r}}let S=null;function _(e){if(e.setActive)return e.setActive();if(S)return e.focus(S);let t=[];for(let n=e;n&&(t.push(n,n.scrollTop,n.scrollLeft),n!=n.ownerDocument);n=n.parentNode);if(e.focus(null==S?{get preventScroll(){return S={preventScroll:!0},!0}}:void 0),!S){S=!1;for(let e=0;e<t.length;){let n=t[e++],r=t[e++],i=t[e++];n.scrollTop!=r&&(n.scrollTop=r),n.scrollLeft!=i&&(n.scrollLeft=i)}}}function O(e,t,n=t){let i=r||(r=document.createRange());return i.setEnd(e,n),i.setStart(e,t),i}function F(e,t,n,r){let i={key:t,code:t,keyCode:n,which:n,cancelable:!0};r&&({altKey:i.altKey,ctrlKey:i.ctrlKey,shiftKey:i.shiftKey,metaKey:i.metaKey}=r);let s=new KeyboardEvent("keydown",i);s.synthetic=!0,e.dispatchEvent(s);let o=new KeyboardEvent("keyup",i);return o.synthetic=!0,e.dispatchEvent(o),s.defaultPrevented||o.defaultPrevented}function P(e){for(;e.attributes.length;)e.removeAttributeNode(e.attributes[0])}function T(e){return e.scrollTop>Math.max(1,e.scrollHeight-e.clientHeight-4)}function N(e,t){for(let n=e,r=t;;){if(3==n.nodeType&&r>0)return{node:n,offset:r};if(1==n.nodeType&&r>0){if("false"==n.contentEditable)return null;r=A(n=n.childNodes[r-1])}else{if(!n.parentNode||w(n))return null;r=k(n),n=n.parentNode}}}function B(e,t){for(let n=e,r=t;;){if(3==n.nodeType&&r<n.nodeValue.length)return{node:n,offset:r};if(1==n.nodeType&&r<n.childNodes.length){if("false"==n.contentEditable)return null;n=n.childNodes[r],r=0}else{if(!n.parentNode||w(n))return null;r=k(n)+1,n=n.parentNode}}}class I{constructor(e,t,n=!0){this.node=e,this.offset=t,this.precise=n}static before(e,t){return new I(e.parentNode,k(e),t)}static after(e,t){return new I(e.parentNode,k(e)+1,t)}}let M=[];class ${constructor(){this.parent=null,this.dom=null,this.flags=2}get overrideDOMText(){return null}get posAtStart(){return this.parent?this.parent.posBefore(this):0}get posAtEnd(){return this.posAtStart+this.length}posBefore(e){let t=this.posAtStart;for(let n of this.children){if(n==e)return t;t+=n.length+n.breakAfter}throw RangeError("Invalid child in posBefore")}posAfter(e){return this.posBefore(e)+e.length}sync(e,t){if(2&this.flags){let n=this.dom,r=null,i;for(let s of this.children){if(7&s.flags){if(!s.dom&&(i=r?r.nextSibling:n.firstChild)){let e=$.get(i);(!e||!e.parent&&e.canReuseDOM(s))&&s.reuseDOM(i)}s.sync(e,t),s.flags&=-8}if(i=r?r.nextSibling:n.firstChild,t&&!t.written&&t.node==n&&i!=s.dom&&(t.written=!0),s.dom.parentNode==n)for(;i&&i!=s.dom;)i=L(i);else n.insertBefore(s.dom,i);r=s.dom}for((i=r?r.nextSibling:n.firstChild)&&t&&t.node==n&&(t.written=!0);i;)i=L(i)}else if(1&this.flags)for(let n of this.children)7&n.flags&&(n.sync(e,t),n.flags&=-8)}reuseDOM(e){}localPosFromDOM(e,t){let n;if(e==this.dom)n=this.dom.childNodes[t];else{let r=0==A(e)?0:0==t?-1:1;for(;;){let t=e.parentNode;if(t==this.dom)break;0==r&&t.firstChild!=t.lastChild&&(r=e==t.firstChild?-1:1),e=t}n=r<0?e:e.nextSibling}if(n==this.dom.firstChild)return 0;for(;n&&!$.get(n);)n=n.nextSibling;if(!n)return this.length;for(let e=0,t=0;;e++){let r=this.children[e];if(r.dom==n)return t;t+=r.length+r.breakAfter}}domBoundsAround(e,t,n=0){let r=-1,i=-1,s=-1,o=-1;for(let l=0,a=n,u=n;l<this.children.length;l++){let n=this.children[l],h=a+n.length;if(a<e&&h>t)return n.domBoundsAround(e,t,a);if(h>=e&&-1==r&&(r=l,i=a),a>t&&n.dom.parentNode==this.dom){s=l,o=u;break}u=h,a=h+n.breakAfter}return{from:i,to:o<0?n+this.length:o,startDOM:(r?this.children[r-1].dom.nextSibling:null)||this.dom.firstChild,endDOM:s<this.children.length&&s>=0?this.children[s].dom:null}}markDirty(e=!1){this.flags|=2,this.markParentsDirty(e)}markParentsDirty(e){for(let t=this.parent;t;t=t.parent){if(e&&(t.flags|=2),1&t.flags)return;t.flags|=1,e=!1}}setParent(e){this.parent!=e&&(this.parent=e,7&this.flags&&this.markParentsDirty(!0))}setDOM(e){this.dom!=e&&(this.dom&&(this.dom.cmView=null),this.dom=e,e.cmView=this)}get rootView(){for(let e=this;;){let t=e.parent;if(!t)return e;e=t}}replaceChildren(e,t,n=M){this.markDirty();for(let r=e;r<t;r++){let e=this.children[r];e.parent==this&&0>n.indexOf(e)&&e.destroy()}this.children.splice(e,t-e,...n);for(let e=0;e<n.length;e++)n[e].setParent(this)}ignoreMutation(e){return!1}ignoreEvent(e){return!1}childCursor(e=this.length){return new R(this.children,e,this.children.length)}childPos(e,t=1){return this.childCursor().findPos(e,t)}toString(){let e=this.constructor.name.replace("View","");return e+(this.children.length?"("+this.children.join()+")":this.length?"["+("Text"==e?this.text:this.length)+"]":"")+(this.breakAfter?"#":"")}static get(e){return e.cmView}get isEditable(){return!0}get isWidget(){return!1}get isHidden(){return!1}merge(e,t,n,r,i,s){return!1}become(e){return!1}canReuseDOM(e){return e.constructor==this.constructor&&!((this.flags|e.flags)&8)}getSide(){return 0}destroy(){for(let e of this.children)e.parent==this&&e.destroy();this.parent=null}}function L(e){let t=e.nextSibling;return e.parentNode.removeChild(e),t}$.prototype.breakAfter=0;class R{constructor(e,t,n){this.children=e,this.pos=t,this.i=n,this.off=0}findPos(e,t=1){for(;;){if(e>this.pos||e==this.pos&&(t>0||0==this.i||this.children[this.i-1].breakAfter))return this.off=e-this.pos,this;let n=this.children[--this.i];this.pos-=n.length+n.breakAfter}}}function j(e,t,n,r,i,s,o,l,a){let{children:u}=e,h=u.length?u[t]:null,c=s.length?s[s.length-1]:null,f=c?c.breakAfter:o;if(!(t==r&&h&&!o&&!f&&s.length<2&&h.merge(n,i,s.length?c:null,0==n,l,a))){if(r<u.length){let e=u[r];e&&(i<e.length||e.breakAfter&&(null==c?void 0:c.breakAfter))?(t==r&&(e=e.split(i),i=0),!f&&c&&e.merge(0,i,c,!0,0,a)?s[s.length-1]=e:((i||e.children.length&&!e.children[0].length)&&e.merge(0,i,null,!1,0,a),s.push(e))):(null==e?void 0:e.breakAfter)&&(c?c.breakAfter=1:o=1),r++}for(h&&(h.breakAfter=o,n>0&&(!o&&s.length&&h.merge(n,h.length,s[0],!1,l,0)?h.breakAfter=s.shift().breakAfter:(n<h.length||h.children.length&&0==h.children[h.children.length-1].length)&&h.merge(n,h.length,null,!1,l,0),t++));t<r&&s.length;)if(u[r-1].become(s[s.length-1]))r--,s.pop(),a=s.length?0:l;else if(u[t].become(s[0]))t++,s.shift(),l=s.length?0:a;else break;!s.length&&t&&r<u.length&&!u[t-1].breakAfter&&u[r].merge(0,0,u[t-1],!1,l,a)&&t--,(t<r||s.length)&&e.replaceChildren(t,r,s)}}function q(e,t,n,r,i,s){let o=e.childCursor(),{i:l,off:a}=o.findPos(n,1),{i:u,off:h}=o.findPos(t,-1),c=t-n;for(let e of r)c+=e.length;e.length+=c,j(e,u,h,l,a,r,0,i,s)}let V="undefined"!=typeof navigator?navigator:{userAgent:"",vendor:"",platform:""},z="undefined"!=typeof document?document:{documentElement:{style:{}}},U=/Edge\/(\d+)/.exec(V.userAgent),H=/MSIE \d/.test(V.userAgent),W=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(V.userAgent),G=!!(H||W||U),K=!G&&/gecko\/(\d+)/i.test(V.userAgent),J=!G&&/Chrome\/(\d+)/.exec(V.userAgent),Q="webkitFontSmoothing"in z.documentElement.style,Y=!G&&/Apple Computer/.test(V.vendor),Z=Y&&(/Mobile\/\w+/.test(V.userAgent)||V.maxTouchPoints>2);var X={mac:Z||/Mac/.test(V.platform),windows:/Win/.test(V.platform),linux:/Linux|X11/.test(V.platform),ie:G,ie_version:H?z.documentMode||6:W?+W[1]:U?+U[1]:0,gecko:K,gecko_version:K?+(/Firefox\/(\d+)/.exec(V.userAgent)||[0,0])[1]:0,chrome:!!J,chrome_version:J?+J[1]:0,ios:Z,android:/Android\b/.test(V.userAgent),webkit:Q,safari:Y,webkit_version:Q?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0,tabSize:null!=z.documentElement.style.tabSize?"tab-size":"-moz-tab-size"};class ee extends ${constructor(e){super(),this.text=e}get length(){return this.text.length}createDOM(e){this.setDOM(e||document.createTextNode(this.text))}sync(e,t){!this.dom&&this.createDOM(),this.dom.nodeValue!=this.text&&(t&&t.node==this.dom&&(t.written=!0),this.dom.nodeValue=this.text)}reuseDOM(e){3==e.nodeType&&this.createDOM(e)}merge(e,t,n){return!(8&this.flags)&&(!n||n instanceof ee&&!(this.length-(t-e)+n.length>256)&&!(8&n.flags))&&(this.text=this.text.slice(0,e)+(n?n.text:"")+this.text.slice(t),this.markDirty(),!0)}split(e){let t=new ee(this.text.slice(e));return this.text=this.text.slice(0,e),this.markDirty(),t.flags|=8&this.flags,t}localPosFromDOM(e,t){return e==this.dom?t:t?this.text.length:0}domAtPos(e){return new I(this.dom,e)}domBoundsAround(e,t,n){return{from:n,to:n+this.length,startDOM:this.dom,endDOM:this.dom.nextSibling}}coordsAt(e,t){return function(e,t,n){let r=e.nodeValue.length;t>r&&(t=r);let i=t,s=t,o=0;0==t&&n<0||t==r&&n>=0?!(X.chrome||X.gecko)&&(t?(i--,o=1):s<r&&(s++,o=-1)):n<0?i--:s<r&&s++;let l=O(e,i,s).getClientRects();if(!l.length)return null;let a=l[(o?o<0:n>=0)?0:l.length-1];return X.safari&&!o&&0==a.width&&(a=Array.prototype.find.call(l,e=>e.width)||a),o?x(a,o<0):a||null}(this.dom,e,t)}}class et extends ${constructor(e,t=[],n=0){for(let r of(super(),this.mark=e,this.children=t,this.length=n,t))r.setParent(this)}setAttrs(e){if(P(e),this.mark.class&&(e.className=this.mark.class),this.mark.attrs)for(let t in this.mark.attrs)e.setAttribute(t,this.mark.attrs[t]);return e}canReuseDOM(e){return super.canReuseDOM(e)&&!((this.flags|e.flags)&8)}reuseDOM(e){e.nodeName==this.mark.tagName.toUpperCase()&&(this.setDOM(e),this.flags|=6)}sync(e,t){this.dom?4&this.flags&&this.setAttrs(this.dom):this.setDOM(this.setAttrs(document.createElement(this.mark.tagName))),super.sync(e,t)}merge(e,t,n,r,i,s){return(!n||!!(n instanceof et&&n.mark.eq(this.mark))&&(!e||!(i<=0))&&(!(t<this.length)||!(s<=0)))&&(q(this,e,t,n?n.children.slice():[],i-1,s-1),this.markDirty(),!0)}split(e){let t=[],n=0,r=-1,i=0;for(let s of this.children){let o=n+s.length;o>e&&t.push(n<e?s.split(e-n):s),r<0&&n>=e&&(r=i),n=o,i++}let s=this.length-e;return this.length=e,r>-1&&(this.children.length=r,this.markDirty()),new et(this.mark,t,s)}domAtPos(e){return ei(this,e)}coordsAt(e,t){return es(this,e,t)}}class en extends ${static create(e,t,n){return new en(e,t,n)}constructor(e,t,n){super(),this.widget=e,this.length=t,this.side=n,this.prevWidget=null}split(e){let t=en.create(this.widget,this.length-e,this.side);return this.length-=e,t}sync(e){(!this.dom||!this.widget.updateDOM(this.dom,e))&&(this.dom&&this.prevWidget&&this.prevWidget.destroy(this.dom),this.prevWidget=null,this.setDOM(this.widget.toDOM(e)),!this.widget.editable&&(this.dom.contentEditable="false"))}getSide(){return this.side}merge(e,t,n,r,i,s){return(!n||n instanceof en&&!!this.widget.compare(n.widget)&&(!(e>0)||!(i<=0))&&(!(t<this.length)||!(s<=0)))&&(this.length=e+(n?n.length:0)+(this.length-t),!0)}become(e){return e instanceof en&&e.side==this.side&&this.widget.constructor==e.widget.constructor&&(!this.widget.compare(e.widget)&&this.markDirty(!0),this.dom&&!this.prevWidget&&(this.prevWidget=this.widget),this.widget=e.widget,this.length=e.length,!0)}ignoreMutation(){return!0}ignoreEvent(e){return this.widget.ignoreEvent(e)}get overrideDOMText(){if(0==this.length)return l.xv.empty;let e=this;for(;e.parent;)e=e.parent;let{view:t}=e,n=t&&t.state.doc,r=this.posAtStart;return n?n.slice(r,r+this.length):l.xv.empty}domAtPos(e){return(this.length?0==e:this.side>0)?I.before(this.dom):I.after(this.dom,e==this.length)}domBoundsAround(){return null}coordsAt(e,t){let n=this.widget.coordsAt(this.dom,e,t);if(n)return n;let r=this.dom.getClientRects(),i=null;if(!r.length)return null;let s=this.side?this.side<0:e>0;for(let t=s?r.length-1:0;i=r[t],e>0?0!=t:t!=r.length-1&&!(i.top<i.bottom);t+=s?-1:1);return x(i,!s)}get isEditable(){return!1}get isWidget(){return!0}get isHidden(){return this.widget.isHidden}destroy(){super.destroy(),this.dom&&this.widget.destroy(this.dom)}}class er extends ${constructor(e){super(),this.side=e}get length(){return 0}merge(){return!1}become(e){return e instanceof er&&e.side==this.side}split(){return new er(this.side)}sync(){if(!this.dom){let e=document.createElement("img");e.className="cm-widgetBuffer",e.setAttribute("aria-hidden","true"),this.setDOM(e)}}getSide(){return this.side}domAtPos(e){return this.side>0?I.before(this.dom):I.after(this.dom)}localPosFromDOM(){return 0}domBoundsAround(){return null}coordsAt(e){return this.dom.getBoundingClientRect()}get overrideDOMText(){return l.xv.empty}get isHidden(){return!0}}function ei(e,t){let n=e.dom,{children:r}=e,i=0;for(let e=0;i<r.length;i++){let s=r[i],o=e+s.length;if(!(o==e&&0>=s.getSide())){if(t>e&&t<o&&s.dom.parentNode==n)return s.domAtPos(t-e);if(t<=e)break;e=o}}for(let e=i;e>0;e--){let t=r[e-1];if(t.dom.parentNode==n)return t.domAtPos(t.length)}for(let e=i;e<r.length;e++){let t=r[e];if(t.dom.parentNode==n)return t.domAtPos(0)}return new I(n,0)}ee.prototype.children=en.prototype.children=er.prototype.children=M;function es(e,t,n){let r=null,i=-1,s=null,o=-1;!function e(t,l){for(let a=0,u=0;a<t.children.length&&u<=l;a++){let h=t.children[a],c=u+h.length;c>=l&&(h.children.length?e(h,l-u):(!s||s.isHidden&&n>0)&&(c>l||u==c&&h.getSide()>0)?(s=h,o=l-u):(u<l||u==c&&0>h.getSide()&&!h.isHidden)&&(r=h,i=l-u)),u=c}}(e,t);let l=(n<0?r:s)||r||s;return l?l.coordsAt(Math.max(0,l==r?i:o),n):function(e){let t=e.dom.lastChild;if(!t)return e.dom.getBoundingClientRect();let n=b(t);return n[n.length-1]||null}(e)}function eo(e,t){for(let n in e)"class"==n&&t.class?t.class+=" "+e.class:"style"==n&&t.style?t.style+=";"+e.style:t[n]=e[n];return t}let el=Object.create(null);function ea(e,t,n){if(e==t)return!0;!e&&(e=el),!t&&(t=el);let r=Object.keys(e),i=Object.keys(t);if(r.length-(n&&r.indexOf(n)>-1?1:0)!=i.length-(n&&i.indexOf(n)>-1?1:0))return!1;for(let s of r)if(s!=n&&(-1==i.indexOf(s)||e[s]!==t[s]))return!1;return!0}function eu(e,t,n){let r=!1;if(t)for(let i in t)!(n&&i in n)&&(r=!0,"style"==i?e.style.cssText="":e.removeAttribute(i));if(n)for(let i in n)!(t&&t[i]==n[i])&&(r=!0,"style"==i?e.style.cssText=n[i]:e.setAttribute(i,n[i]));return r}class eh extends ${constructor(){super(...arguments),this.children=[],this.length=0,this.prevAttrs=void 0,this.attrs=null,this.breakAfter=0}merge(e,t,n,r,i,s){if(n){if(!(n instanceof eh))return!1;!this.dom&&n.transferDOM(this)}return r&&this.setDeco(n?n.attrs:null),q(this,e,t,n?n.children.slice():[],i,s),!0}split(e){let t=new eh;if(t.breakAfter=this.breakAfter,0==this.length)return t;let{i:n,off:r}=this.childPos(e);r&&(t.append(this.children[n].split(r),0),this.children[n].merge(r,this.children[n].length,null,!1,0,0),n++);for(let e=n;e<this.children.length;e++)t.append(this.children[e],0);for(;n>0&&0==this.children[n-1].length;)this.children[--n].destroy();return this.children.length=n,this.markDirty(),this.length=e,t}transferDOM(e){this.dom&&(this.markDirty(),e.setDOM(this.dom),e.prevAttrs=void 0===this.prevAttrs?this.attrs:this.prevAttrs,this.prevAttrs=void 0,this.dom=null)}setDeco(e){!ea(this.attrs,e)&&(this.dom&&(this.prevAttrs=this.attrs,this.markDirty()),this.attrs=e)}append(e,t){!function e(t,n,r){let i,{children:s}=t;r>0&&n instanceof et&&s.length&&(i=s[s.length-1])instanceof et&&i.mark.eq(n.mark)?e(i,n.children[0],r-1):(s.push(n),n.setParent(t)),t.length+=n.length}(this,e,t)}addLineDeco(e){let t=e.spec.attributes,n=e.spec.class;t&&(this.attrs=eo(t,this.attrs||{})),n&&(this.attrs=eo({class:n},this.attrs||{}))}domAtPos(e){return ei(this,e)}reuseDOM(e){"DIV"==e.nodeName&&(this.setDOM(e),this.flags|=6)}sync(e,t){var n;this.dom?4&this.flags&&(P(this.dom),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0):(this.setDOM(document.createElement("div")),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0),void 0!==this.prevAttrs&&(eu(this.dom,this.prevAttrs,this.attrs),this.dom.classList.add("cm-line"),this.prevAttrs=void 0),super.sync(e,t);let r=this.dom.lastChild;for(;r&&$.get(r) instanceof et;)r=r.lastChild;if(!r||!this.length||"BR"!=r.nodeName&&(null===(n=$.get(r))||void 0===n?void 0:n.isEditable)==!1&&(!X.ios||!this.children.some(e=>e instanceof ee))){let e=document.createElement("BR");e.cmIgnore=!0,this.dom.appendChild(e)}}measureTextSize(){if(0==this.children.length||this.length>20)return null;let e=0,t;for(let n of this.children){if(!(n instanceof ee)||/[^ -~]/.test(n.text))return null;let r=b(n.dom);if(1!=r.length)return null;e+=r[0].width,t=r[0].height}return e?{lineHeight:this.dom.getBoundingClientRect().height,charWidth:e/this.length,textHeight:t}:null}coordsAt(e,t){let n=es(this,e,t);if(!this.children.length&&n&&this.parent){let{heightOracle:e}=this.parent.view.viewState,t=n.bottom-n.top;if(2>Math.abs(t-e.lineHeight)&&e.textHeight<t){let r=(t-e.textHeight)/2;return{top:n.top+r,bottom:n.bottom-r,left:n.left,right:n.left}}}return n}become(e){return!1}covers(){return!0}static find(e,t){for(let n=0,r=0;n<e.children.length;n++){let i=e.children[n],s=r+i.length;if(s>=t){if(i instanceof eh)return i;if(s>t)break}r=s+i.breakAfter}return null}}class ec extends ${constructor(e,t,n){super(),this.widget=e,this.length=t,this.deco=n,this.breakAfter=0,this.prevWidget=null}merge(e,t,n,r,i,s){return(!n||n instanceof ec&&!!this.widget.compare(n.widget)&&(!(e>0)||!(i<=0))&&(!(t<this.length)||!(s<=0)))&&(this.length=e+(n?n.length:0)+(this.length-t),!0)}domAtPos(e){return 0==e?I.before(this.dom):I.after(this.dom,e==this.length)}split(e){let t=this.length-e;this.length=e;let n=new ec(this.widget,t,this.deco);return n.breakAfter=this.breakAfter,n}get children(){return M}sync(e){(!this.dom||!this.widget.updateDOM(this.dom,e))&&(this.dom&&this.prevWidget&&this.prevWidget.destroy(this.dom),this.prevWidget=null,this.setDOM(this.widget.toDOM(e)),!this.widget.editable&&(this.dom.contentEditable="false"))}get overrideDOMText(){return this.parent?this.parent.view.state.doc.slice(this.posAtStart,this.posAtEnd):l.xv.empty}domBoundsAround(){return null}become(e){return e instanceof ec&&e.widget.constructor==this.widget.constructor&&(!e.widget.compare(this.widget)&&this.markDirty(!0),this.dom&&!this.prevWidget&&(this.prevWidget=this.widget),this.widget=e.widget,this.length=e.length,this.deco=e.deco,this.breakAfter=e.breakAfter,!0)}ignoreMutation(){return!0}ignoreEvent(e){return this.widget.ignoreEvent(e)}get isEditable(){return!1}get isWidget(){return!0}coordsAt(e,t){return this.widget.coordsAt(this.dom,e,t)}destroy(){super.destroy(),this.dom&&this.widget.destroy(this.dom)}covers(e){let{startSide:t,endSide:n}=this.deco;return t!=n&&(e<0?t<0:n>0)}}class ef{eq(e){return!1}updateDOM(e,t){return!1}compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}get estimatedHeight(){return -1}get lineBreaks(){return 0}ignoreEvent(e){return!0}coordsAt(e,t,n){return null}get isHidden(){return!1}get editable(){return!1}destroy(e){}}var ed=((i=ed||(ed={}))[i.Text=0]="Text",i[i.WidgetBefore=1]="WidgetBefore",i[i.WidgetAfter=2]="WidgetAfter",i[i.WidgetRange=3]="WidgetRange",i);class ep extends l.uU{constructor(e,t,n,r){super(),this.startSide=e,this.endSide=t,this.widget=n,this.spec=r}get heightRelevant(){return!1}static mark(e){return new em(e)}static widget(e){let t=Math.max(-1e4,Math.min(1e4,e.side||0)),n=!!e.block;return t+=n&&!e.inlineOrder?t>0?3e8:-4e8:t>0?1e8:-1e8,new ey(e,t,t,n,e.widget||null,!1)}static replace(e){let t=!!e.block,n,r;if(e.isBlockGap)n=-5e8,r=4e8;else{let{start:i,end:s}=eb(e,t);n=(i?t?-3e8:-1:5e8)-1,r=(s?t?2e8:1:-6e8)+1}return new ey(e,n,r,t,e.widget||null,!0)}static line(e){return new eg(e)}static set(e,t=!1){return l.Xs.of(e,t)}hasHeight(){return!!this.widget&&this.widget.estimatedHeight>-1}}ep.none=l.Xs.empty;class em extends ep{constructor(e){let{start:t,end:n}=eb(e);super(t?-1:5e8,n?1:-6e8,null,e),this.tagName=e.tagName||"span",this.class=e.class||"",this.attrs=e.attributes||null}eq(e){var t,n;return this==e||e instanceof em&&this.tagName==e.tagName&&(this.class||(null===(t=this.attrs)||void 0===t?void 0:t.class))==(e.class||(null===(n=e.attrs)||void 0===n?void 0:n.class))&&ea(this.attrs,e.attrs,"class")}range(e,t=e){if(e>=t)throw RangeError("Mark decorations may not be empty");return super.range(e,t)}}em.prototype.point=!1;class eg extends ep{constructor(e){super(-2e8,-2e8,null,e)}eq(e){return e instanceof eg&&this.spec.class==e.spec.class&&ea(this.spec.attributes,e.spec.attributes)}range(e,t=e){if(t!=e)throw RangeError("Line decoration ranges must be zero-length");return super.range(e,t)}}eg.prototype.mapMode=l.gc.TrackBefore,eg.prototype.point=!0;class ey extends ep{constructor(e,t,n,r,i,s){super(t,n,i,e),this.block=r,this.isReplace=s,this.mapMode=r?t<=0?l.gc.TrackBefore:l.gc.TrackAfter:l.gc.TrackDel}get type(){return this.startSide!=this.endSide?ed.WidgetRange:this.startSide<=0?ed.WidgetBefore:ed.WidgetAfter}get heightRelevant(){return this.block||!!this.widget&&(this.widget.estimatedHeight>=5||this.widget.lineBreaks>0)}eq(e){return e instanceof ey&&function(e,t){return e==t||!!(e&&t&&e.compare(t))}(this.widget,e.widget)&&this.block==e.block&&this.startSide==e.startSide&&this.endSide==e.endSide}range(e,t=e){if(this.isReplace&&(e>t||e==t&&this.startSide>0&&this.endSide<=0))throw RangeError("Invalid range for replacement decoration");if(!this.isReplace&&t!=e)throw RangeError("Widget decorations can only have zero-length ranges");return super.range(e,t)}}function eb(e,t=!1){let{inclusiveStart:n,inclusiveEnd:r}=e;return null==n&&(n=e.inclusive),null==r&&(r=e.inclusive),{start:null!=n?n:t,end:null!=r?r:t}}ey.prototype.point=!0;function ev(e,t,n,r=0){let i=n.length-1;i>=0&&n[i]+r>=e?n[i]=Math.max(n[i],t):n.push(e,t)}class ek{constructor(e,t,n,r){this.doc=e,this.pos=t,this.end=n,this.disallowBlockEffectsFor=r,this.content=[],this.curLine=null,this.breakAtStart=0,this.pendingBuffer=0,this.bufferMarks=[],this.atCursorPos=!0,this.openStart=-1,this.openEnd=-1,this.text="",this.textOff=0,this.cursor=e.iter(),this.skip=t}posCovered(){if(0==this.content.length)return!this.breakAtStart&&this.doc.lineAt(this.pos).from!=this.pos;let e=this.content[this.content.length-1];return!(e.breakAfter||e instanceof ec&&e.deco.endSide<0)}getLine(){return!this.curLine&&(this.content.push(this.curLine=new eh),this.atCursorPos=!0),this.curLine}flushBuffer(e=this.bufferMarks){this.pendingBuffer&&(this.curLine.append(ew(new er(-1),e),e.length),this.pendingBuffer=0)}addBlockWidget(e){this.flushBuffer(),this.curLine=null,this.content.push(e)}finish(e){this.pendingBuffer&&e<=this.bufferMarks.length?this.flushBuffer():this.pendingBuffer=0,!this.posCovered()&&!(e&&this.content.length&&this.content[this.content.length-1]instanceof ec)&&this.getLine()}buildText(e,t,n){for(;e>0;){if(this.textOff==this.text.length){let{value:t,lineBreak:n,done:r}=this.cursor.next(this.skip);if(this.skip=0,r)throw Error("Ran out of text content when drawing inline views");if(n){!this.posCovered()&&this.getLine(),this.content.length?this.content[this.content.length-1].breakAfter=1:this.breakAtStart=1,this.flushBuffer(),this.curLine=null,this.atCursorPos=!0,e--;continue}this.text=t,this.textOff=0}let r=Math.min(this.text.length-this.textOff,e,512);this.flushBuffer(t.slice(t.length-n)),this.getLine().append(ew(new ee(this.text.slice(this.textOff,this.textOff+r)),t),n),this.atCursorPos=!0,this.textOff+=r,e-=r,n=0}}span(e,t,n,r){this.buildText(t-e,n,r),this.pos=t,this.openStart<0&&(this.openStart=r)}point(e,t,n,r,i,s){if(this.disallowBlockEffectsFor[s]&&n instanceof ey){if(n.block)throw RangeError("Block decorations may not be specified via plugins");if(t>this.doc.lineAt(this.pos).to)throw RangeError("Decorations that replace line breaks may not be specified via plugins")}let o=t-e;if(n instanceof ey){if(n.block)n.startSide>0&&!this.posCovered()&&this.getLine(),this.addBlockWidget(new ec(n.widget||eD.block,o,n));else{let s=en.create(n.widget||eD.inline,o,o?0:n.startSide),l=this.atCursorPos&&!s.isEditable&&i<=r.length&&(e<t||n.startSide>0),a=!s.isEditable&&(e<t||i>r.length||n.startSide<=0),u=this.getLine();2==this.pendingBuffer&&!l&&!s.isEditable&&(this.pendingBuffer=0),this.flushBuffer(r),l&&(u.append(ew(new er(1),r),i),i=r.length+Math.max(0,i-r.length)),u.append(ew(s,r),i),this.atCursorPos=a,this.pendingBuffer=a?e<t||i>r.length?1:2:0,this.pendingBuffer&&(this.bufferMarks=r.slice())}}else this.doc.lineAt(this.pos).from==this.pos&&this.getLine().addLineDeco(n);o&&(this.textOff+o<=this.text.length?this.textOff+=o:(this.skip+=o-(this.text.length-this.textOff),this.text="",this.textOff=0),this.pos=t),this.openStart<0&&(this.openStart=i)}static build(e,t,n,r,i){let s=new ek(e,t,n,i);return s.openEnd=l.Xs.spans(r,t,n,s),s.openStart<0&&(s.openStart=s.openEnd),s.finish(s.openEnd),s}}function ew(e,t){for(let n of t)e=new et(n,[e],e.length);return e}class eD extends ef{constructor(e){super(),this.tag=e}eq(e){return e.tag==this.tag}toDOM(){return document.createElement(this.tag)}updateDOM(e){return e.nodeName.toLowerCase()==this.tag}get isHidden(){return!0}}eD.inline=new eD("span"),eD.block=new eD("div");var eA=((s=eA||(eA={}))[s.LTR=0]="LTR",s[s.RTL=1]="RTL",s);let ex=eA.LTR,eC=eA.RTL;function eE(e){let t=[];for(let n=0;n<e.length;n++)t.push(1<<+e[n]);return t}let eS=eE("88888888888888888888888888888888888666888888787833333333337888888000000000000000000000000008888880000000000000000000000000088888888888888888888888888888888888887866668888088888663380888308888800000000000000000000000800000000000000000000000000000008"),e_=eE("4444448826627288999999999992222222222222222222222222222222222222222222222229999999999999999999994444444444644222822222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222999999949999999229989999223333333333"),eO=Object.create(null),eF=[];for(let e of["()","[]","{}"]){let t=e.charCodeAt(0),n=e.charCodeAt(1);eO[t]=n,eO[n]=-t}function eP(e){return e<=247?eS[e]:1424<=e&&e<=1524?2:1536<=e&&e<=1785?e_[e-1536]:1774<=e&&e<=2220?4:8192<=e&&e<=8204?256:64336<=e&&e<=65023?4:1}let eT=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/;class eN{get dir(){return this.level%2?eC:ex}constructor(e,t,n){this.from=e,this.to=t,this.level=n}side(e,t){return this.dir==t==e?this.to:this.from}forward(e,t){return e==(this.dir==t)}static find(e,t,n,r){let i=-1;for(let s=0;s<e.length;s++){let o=e[s];if(o.from<=t&&o.to>=t){if(o.level==n)return s;(i<0||(0!=r?r<0?o.from<t:o.to>t:e[i].level>o.level))&&(i=s)}}if(i<0)throw RangeError("Index out of range");return i}}let eB=[];function eI(e,t,n,r,i,s,o){let l=t%2?2:1;!function(e,t,n,r,i){for(let s=0;s<=r.length;s++){let o=s?r[s-1].to:t,l=s<r.length?r[s].from:n,a=s?256:i;for(let t=o,n=a,r=a;t<l;t++){let i=eP(e.charCodeAt(t));512==i?i=n:8==i&&4==r&&(i=16),eB[t]=4==i?2:i,7&i&&(r=i),n=i}for(let e=o,t=a,r=a;e<l;e++){let i=eB[e];if(128==i)e<l-1&&t==eB[e+1]&&24&t?i=eB[e]=t:eB[e]=256;else if(64==i){let i=e+1;for(;i<l&&64==eB[i];)i++;let s=e&&8==t||i<n&&8==eB[i]?1==r?1:8:256;for(let t=e;t<i;t++)eB[t]=s;e=i-1}else 8==i&&1==r&&(eB[e]=1);t=i,7&i&&(r=i)}}}(e,i,s,r,l),!function(e,t,n,r,i){let s=1==i?2:1;for(let o=0,l=0,a=0;o<=r.length;o++){let u=o?r[o-1].to:t,h=o<r.length?r[o].from:n;for(let t=u,n,r,o;t<h;t++)if(r=eO[n=e.charCodeAt(t)]){if(r<0){for(let e=l-3;e>=0;e-=3)if(eF[e+1]==-r){let n=eF[e+2],r=2&n?i:4&n?1&n?s:i:0;r&&(eB[t]=eB[eF[e]]=r),l=e;break}}else if(189==eF.length)break;else eF[l++]=t,eF[l++]=n,eF[l++]=a}else if(2==(o=eB[t])||1==o){let e=o==i;a=e?0:1;for(let t=l-3;t>=0;t-=3){let n=eF[t+2];if(2&n)break;if(e)eF[t+2]|=2;else{if(4&n)break;eF[t+2]|=4}}}}}(e,i,s,r,l),!function(e,t,n,r){for(let i=0,s=r;i<=n.length;i++){let o=i?n[i-1].to:e,l=i<n.length?n[i].from:t;for(let a=o;a<l;){let o=eB[a];if(256==o){let o=a+1;for(;;)if(o==l){if(i==n.length)break;o=n[i++].to,l=i<n.length?n[i].from:t}else if(256==eB[o])o++;else break;let u=1==s,h=u==((o<t?eB[o]:r)==1)?u?1:2:r;for(let t=o,r=i,s=r?n[r-1].to:e;t>a;)t==s&&(t=n[--r].from,s=r?n[r-1].to:e),eB[--t]=h;a=o}else s=o,a++}}}(i,s,r,l),!function e(t,n,r,i,s,o,l){let a=i%2?2:1;if(i%2==s%2)for(let u=n,h=0;u<r;){let n=!0,c=!1;if(h==o.length||u<o[h].from){let e=eB[u];e!=a&&(n=!1,c=16==e)}let f=n||1!=a?null:[],d=n?i:i+1,p=u;n:for(;;)if(h<o.length&&p==o[h].from){if(c)break;let e=o[h];if(!n)for(let t=e.to,n=h+1;;){if(t==r)break n;if(n<o.length&&o[n].from==t)t=o[n++].to;else if(eB[t]==a)break n;else break}h++,f?f.push(e):(e.from>u&&l.push(new eN(u,e.from,d)),eI(t,e.direction==ex!=!(d%2)?i+1:i,s,e.inner,e.from,e.to,l),u=e.to),p=e.to}else if(p==r||(n?eB[p]!=a:eB[p]==a))break;else p++;f?e(t,u,p,i+1,s,f,l):u<p&&l.push(new eN(u,p,d)),u=p}else for(let u=r,h=o.length;u>n;){let r=!0,c=!1;if(!h||u>o[h-1].to){let e=eB[u-1];e!=a&&(r=!1,c=16==e)}let f=r||1!=a?null:[],d=r?i:i+1,p=u;n:for(;;)if(h&&p==o[h-1].to){if(c)break;let e=o[--h];if(!r)for(let t=e.from,r=h;;){if(t==n)break n;if(r&&o[r-1].to==t)t=o[--r].from;else if(eB[t-1]==a)break n;else break}f?f.push(e):(e.to<u&&l.push(new eN(e.to,u,d)),eI(t,e.direction==ex!=!(d%2)?i+1:i,s,e.inner,e.from,e.to,l),u=e.from),p=e.from}else if(p==n||(r?eB[p-1]!=a:eB[p-1]==a))break;else p--;f?e(t,p,u,i+1,s,f,l):p<u&&l.push(new eN(p,u,d)),u=p}}(e,i,s,t,n,r,o)}function eM(e){return[new eN(0,e,0)]}let e$="",eL=l.r$.define(),eR=l.r$.define(),ej=l.r$.define(),eq=l.r$.define(),eV=l.r$.define(),ez=l.r$.define(),eU=l.r$.define(),eH=l.r$.define({combine:e=>e.some(e=>e)}),eW=l.r$.define({combine:e=>e.some(e=>e)}),eG=l.r$.define();class eK{constructor(e,t="nearest",n="nearest",r=5,i=5,s=!1){this.range=e,this.y=t,this.x=n,this.yMargin=r,this.xMargin=i,this.isSnapshot=s}map(e){return e.empty?this:new eK(this.range.map(e),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}clip(e){return this.range.to<=e.doc.length?this:new eK(l.jT.cursor(e.doc.length),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}}let eJ=l.Py.define({map:(e,t)=>e.map(t)});function eQ(e,t,n){let r=e.facet(eq);r.length?r[0](t):window.onerror?window.onerror(String(t),n,void 0,void 0,t):n?console.error(n+":",t):console.error(t)}let eY=l.r$.define({combine:e=>!e.length||e[0]}),eZ=0,eX=l.r$.define();class e0{constructor(e,t,n,r,i){this.id=e,this.create=t,this.domEventHandlers=n,this.domEventObservers=r,this.extension=i(this)}static define(e,t){let{eventHandlers:n,eventObservers:r,provide:i,decorations:s}=t||{};return new e0(eZ++,e,n,r,e=>{let t=[eX.of(e)];return s&&t.push(e5.of(t=>{let n=t.plugin(e);return n?s(n):ep.none})),i&&t.push(i(e)),t})}static fromClass(e,t){return e0.define(t=>new e(t),t)}}class e1{constructor(e){this.spec=e,this.mustUpdate=null,this.value=null}update(e){if(this.value){if(this.mustUpdate){let e=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(e)}catch(t){if(eQ(e.state,t,"CodeMirror plugin crashed"),this.value.destroy)try{this.value.destroy()}catch(e){}this.deactivate()}}}else if(this.spec)try{this.value=this.spec.create(e)}catch(t){eQ(e.state,t,"CodeMirror plugin crashed"),this.deactivate()}return this}destroy(e){var t;if(null===(t=this.value)||void 0===t?void 0:t.destroy)try{this.value.destroy()}catch(t){eQ(e.state,t,"CodeMirror plugin crashed")}}deactivate(){this.spec=this.value=null}}let e2=l.r$.define(),e3=l.r$.define(),e5=l.r$.define(),e8=l.r$.define(),e4=l.r$.define(),e6=l.r$.define();function e9(e,t){let n=e.state.facet(e6);if(!n.length)return n;let r=n.map(t=>t instanceof Function?t(e):t),i=[];return l.Xs.spans(r,t.from,t.to,{point(){},span(e,n,r,s){let o=e-t.from,l=n-t.from,a=i;for(let e=r.length-1;e>=0;e--,s--){let n=r[e].spec.bidiIsolate,i;if(null==n&&(n=function(e,t,n){for(let r=t;r<n;r++){let t=eP(e.charCodeAt(r));if(1==t)break;if(2==t||4==t)return eC}return ex}(t.text,o,l)),s>0&&a.length&&(i=a[a.length-1]).to==o&&i.direction==n)i.to=l,a=i.inner;else{let e={from:o,to:l,direction:n,inner:[]};a.push(e),a=e.inner}}}}),i}let e7=l.r$.define();function te(e){let t=0,n=0,r=0,i=0;for(let s of e.state.facet(e7)){let o=s(e);o&&(null!=o.left&&(t=Math.max(t,o.left)),null!=o.right&&(n=Math.max(n,o.right)),null!=o.top&&(r=Math.max(r,o.top)),null!=o.bottom&&(i=Math.max(i,o.bottom)))}return{left:t,right:n,top:r,bottom:i}}let tt=l.r$.define();class tn{constructor(e,t,n,r){this.fromA=e,this.toA=t,this.fromB=n,this.toB=r}join(e){return new tn(Math.min(this.fromA,e.fromA),Math.max(this.toA,e.toA),Math.min(this.fromB,e.fromB),Math.max(this.toB,e.toB))}addToSet(e){let t=e.length,n=this;for(;t>0;t--){let r=e[t-1];if(!(r.fromA>n.toA)){if(r.toA<n.fromA)break;n=n.join(r),e.splice(t-1,1)}}return e.splice(t,0,n),e}static extendWithRanges(e,t){if(0==t.length)return e;let n=[];for(let r=0,i=0,s=0,o=0;;r++){let l=r==e.length?null:e[r],a=s-o,u=l?l.fromB:1e9;for(;i<t.length&&t[i]<u;){let e=t[i],r=t[i+1],s=Math.max(o,e),l=Math.min(u,r);if(s<=l&&new tn(s+a,l+a,s,l).addToSet(n),r>u)break;i+=2}if(!l)return n;new tn(l.fromA,l.toA,l.fromB,l.toB).addToSet(n),s=l.toA,o=l.toB}}}class tr{constructor(e,t,n){for(let r of(this.view=e,this.state=t,this.transactions=n,this.flags=0,this.startState=e.state,this.changes=l.as.empty(this.startState.doc.length),n))this.changes=this.changes.compose(r.changes);let r=[];this.changes.iterChangedRanges((e,t,n,i)=>r.push(new tn(e,t,n,i))),this.changedRanges=r}static create(e,t,n){return new tr(e,t,n)}get viewportChanged(){return(4&this.flags)>0}get heightChanged(){return(2&this.flags)>0}get geometryChanged(){return this.docChanged||(10&this.flags)>0}get focusChanged(){return(1&this.flags)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(e=>e.selection)}get empty(){return 0==this.flags&&0==this.transactions.length}}class ti extends ${get length(){return this.view.state.doc.length}constructor(e){super(),this.view=e,this.decorations=[],this.dynamicDecorationMap=[],this.domChanged=null,this.hasComposition=null,this.markedForComposition=new Set,this.lastCompositionAfterCursor=!1,this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.setDOM(e.contentDOM),this.children=[new eh],this.children[0].setParent(this),this.updateDeco(),this.updateInner([new tn(0,0,0,e.state.doc.length)],0,null)}update(e){var t;let n=e.changedRanges;this.minWidth>0&&n.length&&(n.every(({fromA:e,toA:t})=>t<this.minWidthFrom||e>this.minWidthTo)?(this.minWidthFrom=e.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=e.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0);let r=-1;this.view.inputState.composing>=0&&((null===(t=this.domChanged)||void 0===t?void 0:t.newSel)?r=this.domChanged.newSel.head:!function(e,t){let n=!1;return t&&e.iterChangedRanges((e,r)=>{e<t.to&&r>t.from&&(n=!0)}),n}(e.changes,this.hasComposition)&&!e.selectionSet&&(r=e.state.selection.main.head));let i=r>-1?function(e,t,n){let r=to(e,n);if(!r)return null;let{node:i,from:s,to:o}=r,l=i.nodeValue;if(/[\n\r]/.test(l)||e.state.doc.sliceString(r.from,r.to)!=l)return null;let a=t.invertedDesc,u=new tn(a.mapPos(s),a.mapPos(o),s,o),h=[];for(let t=i.parentNode;;t=t.parentNode){let n=$.get(t);if(n instanceof et)h.push({node:t,deco:n.mark});else{if(n instanceof eh||"DIV"==t.nodeName&&t.parentNode==e.contentDOM)return{range:u,text:i,marks:h,line:t};if(t==e.contentDOM)return null;h.push({node:t,deco:new em({inclusive:!0,attributes:function(e){let t=Object.create(null);for(let n=0;n<e.attributes.length;n++){let r=e.attributes[n];t[r.name]=r.value}return t}(t),tagName:t.tagName.toLowerCase()})})}}}(this.view,e.changes,r):null;if(this.domChanged=null,this.hasComposition){this.markedForComposition.clear();let{from:t,to:r}=this.hasComposition;n=new tn(t,r,e.changes.mapPos(t,-1),e.changes.mapPos(r,1)).addToSet(n.slice())}this.hasComposition=i?{from:i.range.fromB,to:i.range.toB}:null,(X.ie||X.chrome)&&!i&&e&&e.state.doc.lines!=e.startState.doc.lines&&(this.forceSelection=!0);let s=function(e,t,n){let r=new tl;return l.Xs.compare(e,t,n,r),r.changes}(this.decorations,this.updateDeco(),e.changes);return n=tn.extendWithRanges(n,s),(!!(7&this.flags)||0!=n.length)&&(this.updateInner(n,e.startState.doc.length,i),e.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(e,t,n){this.view.viewState.mustMeasureContent=!0,this.updateChildren(e,t,n);let{observer:r}=this.view;r.ignore(()=>{this.dom.style.height=this.view.viewState.contentHeight/this.view.scaleY+"px",this.dom.style.flexBasis=this.minWidth?this.minWidth+"px":"";let e=X.chrome||X.ios?{node:r.selectionRange.focusNode,written:!1}:void 0;this.sync(this.view,e),this.flags&=-8,e&&(e.written||r.selectionRange.focusNode!=e.node)&&(this.forceSelection=!0),this.dom.style.height=""}),this.markedForComposition.forEach(e=>e.flags&=-9);let i=[];if(this.view.viewport.from||this.view.viewport.to<this.view.state.doc.length)for(let e of this.children)e instanceof ec&&e.widget instanceof ts&&i.push(e.dom);r.updateGaps(i)}updateChildren(e,t,n){let r=n?n.range.addToSet(e.slice()):e,i=this.childCursor(t);for(let e=r.length-1;;e--){let t=e>=0?r[e]:null;if(!t)break;let{fromA:s,toA:o,fromB:l,toB:a}=t,u,h,c,f;if(n&&n.range.fromB<a&&n.range.toB>l){let e=ek.build(this.view.state.doc,l,n.range.fromB,this.decorations,this.dynamicDecorationMap),t=ek.build(this.view.state.doc,n.range.toB,a,this.decorations,this.dynamicDecorationMap);h=e.breakAtStart,c=e.openStart,f=t.openEnd;let r=this.compositionView(n);t.breakAtStart?r.breakAfter=1:t.content.length&&r.merge(r.length,r.length,t.content[0],!1,t.openStart,0)&&(r.breakAfter=t.content[0].breakAfter,t.content.shift()),e.content.length&&r.merge(0,0,e.content[e.content.length-1],!0,0,e.openEnd)&&e.content.pop(),u=e.content.concat(r).concat(t.content)}else({content:u,breakAtStart:h,openStart:c,openEnd:f}=ek.build(this.view.state.doc,l,a,this.decorations,this.dynamicDecorationMap));let{i:d,off:p}=i.findPos(o,1),{i:m,off:g}=i.findPos(s,-1);j(this,m,g,d,p,u,h,c,f)}n&&this.fixCompositionDOM(n)}compositionView(e){let t=new ee(e.text.nodeValue);for(let{deco:n}of(t.flags|=8,e.marks))t=new et(n,[t],t.length);let n=new eh;return n.append(t,0),n}fixCompositionDOM(e){let t=(e,t)=>{t.flags|=8|(t.children.some(e=>7&e.flags)?1:0),this.markedForComposition.add(t);let n=$.get(e);n&&n!=t&&(n.dom=null),t.setDOM(e)},n=this.childPos(e.range.fromB,1),r=this.children[n.i];t(e.line,r);for(let i=e.marks.length-1;i>=-1;i--)n=r.childPos(n.off,1),r=r.children[n.i],t(i>=0?e.marks[i].node:e.text,r)}updateSelection(e=!1,t=!1){(e||!this.view.observer.selectionRange.focusNode)&&this.view.observer.readSelectionRange();let n=this.view.root.activeElement,r=n==this.dom,i=!r&&y(this.dom,this.view.observer.selectionRange)&&!(n&&this.dom.contains(n));if(!(r||t||i))return;let s=this.forceSelection;this.forceSelection=!1;let o=this.view.state.selection.main,l=this.moveToLine(this.domAtPos(o.anchor)),a=o.empty?l:this.moveToLine(this.domAtPos(o.head));if(X.gecko&&o.empty&&!this.hasComposition&&function(e){return 1==e.node.nodeType&&e.node.firstChild&&(0==e.offset||"false"==e.node.childNodes[e.offset-1].contentEditable)&&(e.offset==e.node.childNodes.length||"false"==e.node.childNodes[e.offset].contentEditable)}(l)){let e=document.createTextNode("");this.view.observer.ignore(()=>l.node.insertBefore(e,l.node.childNodes[l.offset]||null)),l=a=new I(e,0),s=!0}let u=this.view.observer.selectionRange;(s||!u.focusNode||(!v(l.node,l.offset,u.anchorNode,u.anchorOffset)||!v(a.node,a.offset,u.focusNode,u.focusOffset))&&!this.suppressWidgetCursorChange(u,o))&&(this.view.observer.ignore(()=>{X.android&&X.chrome&&this.dom.contains(u.focusNode)&&function(e,t){for(let n=e;n&&n!=t;n=n.assignedSlot||n.parentNode)if(1==n.nodeType&&"false"==n.contentEditable)return!0;return!1}(u.focusNode,this.dom)&&(this.dom.blur(),this.dom.focus({preventScroll:!0}));let e=m(this.view.root);if(e){if(o.empty){if(X.gecko){let e=function(e,t){return 1!=e.nodeType?0:(t&&"false"==e.childNodes[t-1].contentEditable?1:0)|(t<e.childNodes.length&&"false"==e.childNodes[t].contentEditable?2:0)}(l.node,l.offset);if(e&&3!=e){let t=(1==e?N:B)(l.node,l.offset);t&&(l=new I(t.node,t.offset))}}e.collapse(l.node,l.offset),null!=o.bidiLevel&&void 0!==e.caretBidiLevel&&(e.caretBidiLevel=o.bidiLevel)}else if(e.extend){e.collapse(l.node,l.offset);try{e.extend(a.node,a.offset)}catch(e){}}else{let t=document.createRange();o.anchor>o.head&&([l,a]=[a,l]),t.setEnd(a.node,a.offset),t.setStart(l.node,l.offset),e.removeAllRanges(),e.addRange(t)}}else;i&&this.view.root.activeElement==this.dom&&(this.dom.blur(),n&&n.focus())}),this.view.observer.setSelectionRange(l,a)),this.impreciseAnchor=l.precise?null:new I(u.anchorNode,u.anchorOffset),this.impreciseHead=a.precise?null:new I(u.focusNode,u.focusOffset)}suppressWidgetCursorChange(e,t){return this.hasComposition&&t.empty&&v(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)&&this.posFromDOM(e.focusNode,e.focusOffset)==t.head}enforceCursorAssoc(){if(this.hasComposition)return;let{view:e}=this,t=e.state.selection.main,n=m(e.root),{anchorNode:r,anchorOffset:i}=e.observer.selectionRange;if(!n||!t.empty||!t.assoc||!n.modify)return;let s=eh.find(this,t.head);if(!s)return;let o=s.posAtStart;if(t.head==o||t.head==o+s.length)return;let l=this.coordsAt(t.head,-1),a=this.coordsAt(t.head,1);if(!l||!a||l.bottom>a.top)return;let u=this.domAtPos(t.head+t.assoc);n.collapse(u.node,u.offset),n.modify("move",t.assoc<0?"forward":"backward","lineboundary"),e.observer.readSelectionRange();let h=e.observer.selectionRange;e.docView.posFromDOM(h.anchorNode,h.anchorOffset)!=t.from&&n.collapse(r,i)}moveToLine(e){let t=this.dom,n;if(e.node!=t)return e;for(let r=e.offset;!n&&r<t.childNodes.length;r++){let e=$.get(t.childNodes[r]);e instanceof eh&&(n=e.domAtPos(0))}for(let r=e.offset-1;!n&&r>=0;r--){let e=$.get(t.childNodes[r]);e instanceof eh&&(n=e.domAtPos(e.length))}return n?new I(n.node,n.offset,!0):e}nearest(e){for(let t=e;t;){let e=$.get(t);if(e&&e.rootView==this)return e;t=t.parentNode}return null}posFromDOM(e,t){let n=this.nearest(e);if(!n)throw RangeError("Trying to find position for a DOM position outside of the document");return n.localPosFromDOM(e,t)+n.posAtStart}domAtPos(e){let{i:t,off:n}=this.childCursor().findPos(e,-1);for(;t<this.children.length-1;){let e=this.children[t];if(n<e.length||e instanceof eh)break;t++,n=0}return this.children[t].domAtPos(n)}coordsAt(e,t){let n=null,r=0;for(let i=this.length,s=this.children.length-1;s>=0;s--){let o=this.children[s],l=i-o.breakAfter,a=l-o.length;if(l<e)break;a<=e&&(a<e||o.covers(-1))&&(l>e||o.covers(1))&&(!n||o instanceof eh&&!(n instanceof eh&&t>=0))&&(n=o,r=a),i=a}return n?n.coordsAt(e-r,t):null}coordsForChar(e){let{i:t,off:n}=this.childPos(e,1),r=this.children[t];if(!(r instanceof eh))return null;for(;r.children.length;){let{i:e,off:t}=r.childPos(n,1);for(;;e++){if(e==r.children.length)return null;if((r=r.children[e]).length)break}n=t}if(!(r instanceof ee))return null;let i=(0,l.cp)(r.text,n);if(i==n)return null;let s=O(r.dom,n,i).getClientRects();for(let e=0;e<s.length;e++){let t=s[e];if(e==s.length-1||t.top<t.bottom&&t.left<t.right)return t}return null}measureVisibleLineHeights(e){let t=[],{from:n,to:r}=e,i=this.view.contentDOM.clientWidth,s=i>Math.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,o=-1,l=this.view.textDirection==eA.LTR;for(let e=0,a=0;a<this.children.length;a++){let u=this.children[a],h=e+u.length;if(h>r)break;if(e>=n){let n=u.dom.getBoundingClientRect();if(t.push(n.height),s){let t=u.dom.lastChild,r=t?b(t):[];if(r.length){let t=r[r.length-1],s=l?t.right-n.left:n.right-t.left;s>o&&(o=s,this.minWidth=i,this.minWidthFrom=e,this.minWidthTo=h)}}}e=h+u.breakAfter}return t}textDirectionAt(e){let{i:t}=this.childPos(e,1);return"rtl"==getComputedStyle(this.children[t].dom).direction?eA.RTL:eA.LTR}measureTextSize(){for(let e of this.children)if(e instanceof eh){let t=e.measureTextSize();if(t)return t}let e=document.createElement("div"),t,n,r;return e.className="cm-line",e.style.width="99999px",e.style.position="absolute",e.textContent="abc def ghi jkl mno pqr stu",this.view.observer.ignore(()=>{this.dom.appendChild(e);let i=b(e.firstChild)[0];t=e.getBoundingClientRect().height,n=i?i.width/27:7,r=i?i.height:t,e.remove()}),{lineHeight:t,charWidth:n,textHeight:r}}childCursor(e=this.length){let t=this.children.length;return t&&(e-=this.children[--t].length),new R(this.children,e,t)}computeBlockGapDeco(){let e=[],t=this.view.viewState;for(let n=0,r=0;;r++){let i=r==t.viewports.length?null:t.viewports[r],s=i?i.from-1:this.length;if(s>n){let r=(t.lineBlockAt(s).bottom-t.lineBlockAt(n).top)/this.view.scaleY;e.push(ep.replace({widget:new ts(r),block:!0,inclusive:!0,isBlockGap:!0}).range(n,s))}if(!i)break;n=i.to+1}return ep.set(e)}updateDeco(){let e=0,t=this.view.state.facet(e5).map(t=>(this.dynamicDecorationMap[e++]="function"==typeof t)?t(this.view):t),n=!1,r=this.view.state.facet(e8).map((e,t)=>{let r="function"==typeof e;return r&&(n=!0),r?e(this.view):e});for(r.length&&(this.dynamicDecorationMap[e++]=n,t.push(l.Xs.join(r))),this.decorations=[...t,this.computeBlockGapDeco(),this.view.viewState.lineGapDeco];e<this.decorations.length;)this.dynamicDecorationMap[e++]=!1;return this.decorations}scrollIntoView(e){if(e.isSnapshot){let t=this.view.viewState.lineBlockAt(e.range.head);this.view.scrollDOM.scrollTop=t.top-e.yMargin,this.view.scrollDOM.scrollLeft=e.xMargin;return}for(let t of this.view.state.facet(eG))try{if(t(this.view,e.range,e))return!0}catch(e){eQ(this.view.state,e,"scroll handler")}let{range:t}=e,n=this.coordsAt(t.head,t.empty?t.assoc:t.head>t.anchor?-1:1),r;if(!n)return;!t.empty&&(r=this.coordsAt(t.anchor,t.anchor>t.head?-1:1))&&(n={left:Math.min(n.left,r.left),top:Math.min(n.top,r.top),right:Math.max(n.right,r.right),bottom:Math.max(n.bottom,r.bottom)});let i=te(this.view),s={left:n.left-i.left,top:n.top-i.top,right:n.right+i.right,bottom:n.bottom+i.bottom},{offsetWidth:o,offsetHeight:l}=this.view.scrollDOM;!function(e,t,n,r,i,s,o,l){let a=e.ownerDocument,u=a.defaultView||window;for(let h=e,c=!1;h&&!c;)if(1==h.nodeType){let e,f=h==a.body,d=1,p=1;if(f)e=function(e){let t=e.visualViewport;return t?{left:0,right:t.width,top:0,bottom:t.height}:{left:0,right:e.innerWidth,top:0,bottom:e.innerHeight}}(u);else{if(/^(fixed|sticky)$/.test(getComputedStyle(h).position)&&(c=!0),h.scrollHeight<=h.clientHeight&&h.scrollWidth<=h.clientWidth){h=h.assignedSlot||h.parentNode;continue}let t=h.getBoundingClientRect();({scaleX:d,scaleY:p}=C(h,t)),e={left:t.left,right:t.left+h.clientWidth*d,top:t.top,bottom:t.top+h.clientHeight*p}}let m=0,g=0;if("nearest"==i)t.top<e.top?(g=-(e.top-t.top+o),n>0&&t.bottom>e.bottom+g&&(g=t.bottom-e.bottom+g+o)):t.bottom>e.bottom&&(g=t.bottom-e.bottom+o,n<0&&t.top-g<e.top&&(g=-(e.top+g-t.top+o)));else{let r=t.bottom-t.top,s=e.bottom-e.top;g=("center"==i&&r<=s?t.top+r/2-s/2:"start"==i||"center"==i&&n<0?t.top-o:t.bottom-s+o)-e.top}if("nearest"==r?t.left<e.left?(m=-(e.left-t.left+s),n>0&&t.right>e.right+m&&(m=t.right-e.right+m+s)):t.right>e.right&&(m=t.right-e.right+s,n<0&&t.left<e.left+m&&(m=-(e.left+m-t.left+s))):m=("center"==r?t.left+(t.right-t.left)/2-(e.right-e.left)/2:"start"==r==l?t.left-s:t.right-(e.right-e.left)+s)-e.left,m||g){if(f)u.scrollBy(m,g);else{let e=0,n=0;if(g){let e=h.scrollTop;h.scrollTop+=g/p,n=(h.scrollTop-e)*p}if(m){let t=h.scrollLeft;h.scrollLeft+=m/d,e=(h.scrollLeft-t)*d}t={left:t.left-e,top:t.top-n,right:t.right-e,bottom:t.bottom-n},e&&1>Math.abs(e-m)&&(r="nearest"),n&&1>Math.abs(n-g)&&(i="nearest")}}if(f)break;h=h.assignedSlot||h.parentNode}else if(11==h.nodeType)h=h.host;else break}(this.view.scrollDOM,s,t.head<t.anchor?-1:1,e.x,e.y,Math.max(Math.min(e.xMargin,o),-o),Math.max(Math.min(e.yMargin,l),-l),this.view.textDirection==eA.LTR)}}class ts extends ef{constructor(e){super(),this.height=e}toDOM(){let e=document.createElement("div");return e.className="cm-gap",this.updateDOM(e),e}eq(e){return e.height==this.height}updateDOM(e){return e.style.height=this.height+"px",!0}get editable(){return!0}get estimatedHeight(){return this.height}ignoreEvent(){return!1}}function to(e,t){let n=e.observer.selectionRange;if(!n.focusNode)return null;let r=N(n.focusNode,n.focusOffset),i=B(n.focusNode,n.focusOffset),s=r||i;if(i&&r&&i.node!=r.node){let t=$.get(i.node);if(!t||t instanceof ee&&t.text!=i.node.nodeValue)s=i;else if(e.docView.lastCompositionAfterCursor){let e=$.get(r.node);!(!e||e instanceof ee&&e.text!=r.node.nodeValue)&&(s=i)}}if(e.docView.lastCompositionAfterCursor=s!=r,!s)return null;let o=t-s.offset;return{from:o,to:o+s.node.nodeValue.length,node:s.node}}let tl=class{constructor(){this.changes=[]}compareRange(e,t){ev(e,t,this.changes)}comparePoint(e,t){ev(e,t,this.changes)}};function ta(e,t){return e.top<t.bottom-1&&e.bottom>t.top+1}function tu(e,t){return t<e.top?{top:t,left:e.left,right:e.right,bottom:e.bottom}:e}function th(e,t){return t>e.bottom?{top:e.top,left:e.left,right:e.right,bottom:t}:e}function tc(e,t,n){let r=e.nodeValue.length,i=-1,s=1e9,o=0;for(let l=0;l<r;l++){let r=O(e,l,l+1).getClientRects();for(let a=0;a<r.length;a++){let u=r[a];if(u.top==u.bottom)continue;!o&&(o=t-u.left);let h=(u.top>n?u.top-n:n-u.bottom)-1;if(u.left-1<=t&&u.right+1>=t&&h<s){let n=t>=(u.left+u.right)/2,r=n;if((X.chrome||X.gecko)&&O(e,l).getBoundingClientRect().left==u.right&&(r=!n),h<=0)return{node:e,offset:l+(r?1:0)};i=l+(r?1:0),s=h}}}return{node:e,offset:i>-1?i:o>0?e.nodeValue.length:0}}function tf(e,t,n,r=-1){var i,s;let o=e.contentDOM.getBoundingClientRect(),l=o.top+e.viewState.paddingTop,a,{docHeight:u}=e.viewState,{x:h,y:c}=t,f=c-l;if(f<0)return 0;if(f>u)return e.state.doc.length;for(let t=e.viewState.heightOracle.textHeight/2,i=!1;(a=e.elementAtHeight(f)).type!=ed.Text;){;for(;!((f=r>0?a.bottom+t:a.top-t)>=0)||!(f<=u);){;if(i)return n?null:0;i=!0,r=-r}}c=l+f;let d=a.from;if(d<e.viewport.from)return 0==e.viewport.from?0:n?null:td(e,o,a,h,c);if(d>e.viewport.to)return e.viewport.to==e.state.doc.length?e.state.doc.length:n?null:td(e,o,a,h,c);let p=e.dom.ownerDocument,m=e.root.elementFromPoint?e.root:p,g=m.elementFromPoint(h,c);g&&!e.contentDOM.contains(g)&&(g=null),!g&&(h=Math.max(o.left+1,Math.min(o.right-1,h)),(g=m.elementFromPoint(h,c))&&!e.contentDOM.contains(g)&&(g=null));let y,v=-1;if(g&&(null===(i=e.docView.nearest(g))||void 0===i?void 0:i.isEditable)!=!1){if(p.caretPositionFromPoint){let e=p.caretPositionFromPoint(h,c);e&&({offsetNode:y,offset:v}=e)}else if(p.caretRangeFromPoint){let t=p.caretRangeFromPoint(h,c);t&&({startContainer:y,startOffset:v}=t,(!e.contentDOM.contains(y)||X.safari&&function(e,t,n){let r;if(3!=e.nodeType||t!=(r=e.nodeValue.length))return!1;for(let t=e.nextSibling;t;t=t.nextSibling)if(1!=t.nodeType||"BR"!=t.nodeName)return!1;return O(e,r-1,r).getBoundingClientRect().left>n}(y,v,h)||X.chrome&&function(e,t,n){if(0!=t)return!1;for(let t=e;;){let e=t.parentNode;if(!e||1!=e.nodeType||e.firstChild!=t)return!1;if(e.classList.contains("cm-line"))break;t=e}return n-(1==e.nodeType?e.getBoundingClientRect():O(e,0,Math.max(e.nodeValue.length,1)).getBoundingClientRect()).left>5}(y,v,h))&&(y=void 0))}}if(!y||!e.docView.dom.contains(y)){let t=eh.find(e.docView,d);if(!t)return f>a.top+a.height/2?a.to:a.from;({node:y,offset:v}=function e(t,n,r){let i,s,o,l,a,u,h,c,f=!1;for(let y=t.firstChild;y;y=y.nextSibling){let t=b(y);for(let b=0;b<t.length;b++){var d,p,m,g;let v=t[b];u&&ta(u,v)&&(v=tu(th(v,u.bottom),u.top));let k=(d=n,(p=v).left>d?p.left-d:Math.max(0,d-p.right)),w=(m=r,(g=v).top>m?g.top-m:Math.max(0,m-g.bottom));if(0==k&&0==w)return 3==y.nodeType?tc(y,n,r):e(y,n,r);if(!a||c>w||c==w&&h>k){a=y,u=v,h=k,c=w;let e=w?r<v.top?-1:1:k?n<v.left?-1:1:0;f=!e||(e>0?b<t.length-1:b>0)}0==k?r>v.bottom&&(!o||o.bottom<v.bottom)?(i=y,o=v):r<v.top&&(!l||l.top>v.top)&&(s=y,l=v):o&&ta(o,v)?o=th(o,v.bottom):l&&ta(l,v)&&(l=tu(l,v.top))}}if(o&&o.bottom>=r?(a=i,u=o):l&&l.top<=r&&(a=s,u=l),!a)return{node:t,offset:0};let y=Math.max(u.left,Math.min(u.right,n));if(3==a.nodeType)return tc(a,y,r);if(f&&"false"!=a.contentEditable)return e(a,y,r);let v=Array.prototype.indexOf.call(t.childNodes,a)+(n>=(u.left+u.right)/2?1:0);return{node:t,offset:v}}(t.dom,h,c))}let k=e.docView.nearest(y);if(!k)return null;if(!k.isWidget||(null===(s=k.dom)||void 0===s?void 0:s.nodeType)!=1)return k.localPosFromDOM(y,v)+k.posAtStart;{let e=k.dom.getBoundingClientRect();return t.y<e.top||t.y<=e.bottom&&t.x<=(e.left+e.right)/2?k.posAtStart:k.posAtEnd}}function td(e,t,n,r,i){let s=Math.round((r-t.left)*e.defaultCharacterWidth);if(e.lineWrapping&&n.height>1.5*e.defaultLineHeight){let t=e.viewState.heightOracle.textHeight;s+=Math.floor((i-n.top-(e.defaultLineHeight-t)*.5)/t)*e.viewState.heightOracle.lineLength}let o=e.state.sliceDoc(n.from,n.to);return n.from+(0,l.Gz)(o,s,e.state.tabSize)}function tp(e,t){let n=e.lineBlockAt(t);if(Array.isArray(n.type)){for(let e of n.type)if(e.to>t||e.to==t&&(e.to==n.to||e.type==ed.Text))return e}return n}function tm(e,t,n,r){let i=e.state.doc.lineAt(t.head),s=e.bidiSpans(i),o=e.textDirectionAt(i.from);for(let a=t,u=null;;){let t=function(e,t,n,r,i){var s;let o=r.head-e.from,a=eN.find(t,o,null!==(s=r.bidiLevel)&&void 0!==s?s:-1,r.assoc),u=t[a],h=u.side(i,n);if(o==h){let e=a+=i?1:-1;if(e<0||e>=t.length)return null;o=(u=t[a=e]).side(!i,n),h=u.side(i,n)}let c=(0,l.cp)(e.text,o,u.forward(i,n));(c<u.from||c>u.to)&&(c=h),e$=e.text.slice(Math.min(o,c),Math.max(o,c));let f=a==(i?t.length-1:0)?null:t[a+(i?1:-1)];return f&&c==h&&f.level+(i?0:1)<u.level?l.jT.cursor(f.side(!i,n)+e.from,f.forward(i,n)?1:-1,f.level):l.jT.cursor(c+e.from,u.forward(i,n)?-1:1,u.level)}(i,s,o,a,n),h=e$;if(!t){if(i.number==(n?e.state.doc.lines:1))return a;h="\n",i=e.state.doc.line(i.number+(n?1:-1)),s=e.bidiSpans(i),t=e.visualLineSide(i,!n)}if(u){if(!u(h))return a}else{if(!r)return t;u=r(h)}a=t}}function tg(e,t,n){for(;;){let r=0;for(let i of e)i.between(t-1,t+1,(e,i,s)=>{if(t>e&&t<i){let s=r||n||(t-e<i-t?-1:1);t=s<0?e:i,r=s}});if(!r)return t}}function ty(e,t,n){let r=tg(e.state.facet(e4).map(t=>t(e)),n.from,t.head>n.from?-1:1);return r==n.from?n:l.jT.cursor(r,r<n.from?1:-1)}class tb{setSelectionOrigin(e){this.lastSelectionOrigin=e,this.lastSelectionTime=Date.now()}constructor(e){this.view=e,this.lastKeyCode=0,this.lastKeyTime=0,this.lastTouchTime=0,this.lastFocusTime=0,this.lastScrollTop=0,this.lastScrollLeft=0,this.pendingIOSKey=void 0,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastEscPress=0,this.lastContextMenu=0,this.scrollHandlers=[],this.handlers=Object.create(null),this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.compositionPendingKey=!1,this.compositionPendingChange=!1,this.mouseSelection=null,this.draggedContent=null,this.handleEvent=this.handleEvent.bind(this),this.notifiedFocused=e.hasFocus,X.safari&&e.contentDOM.addEventListener("input",()=>null),X.gecko&&function(e){!tz.has(e)&&(tz.add(e),e.addEventListener("copy",()=>{}),e.addEventListener("cut",()=>{}))}(e.contentDOM.ownerDocument)}handleEvent(e){if(!(!function(e,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let n=t.target,r;n!=e.contentDOM;n=n.parentNode)if(!n||11==n.nodeType||(r=$.get(n))&&r.ignoreEvent(t))return!1;return!0}(this.view,e)||this.ignoreDuringComposition(e)))!("keydown"==e.type&&this.keydown(e))&&this.runHandlers(e.type,e)}runHandlers(e,t){let n=this.handlers[e];if(n){for(let e of n.observers)e(this.view,t);for(let e of n.handlers){if(t.defaultPrevented)break;if(e(this.view,t)){t.preventDefault();break}}}}ensureHandlers(e){let t=function(e){let t=Object.create(null);function n(e){return t[e]||(t[e]={observers:[],handlers:[]})}for(let t of e){let e=t.spec;if(e&&e.domEventHandlers)for(let r in e.domEventHandlers){let i=e.domEventHandlers[r];i&&n(r).handlers.push(tv(t.value,i))}if(e&&e.domEventObservers)for(let r in e.domEventObservers){let i=e.domEventObservers[r];i&&n(r).observers.push(tv(t.value,i))}}for(let e in tC)n(e).handlers.push(tC[e]);for(let e in tE)n(e).observers.push(tE[e]);return t}(e),n=this.handlers,r=this.view.contentDOM;for(let e in t)if("scroll"!=e){let i=!t[e].handlers.length,s=n[e];s&&!s.handlers.length!=i&&(r.removeEventListener(e,this.handleEvent),s=null),!s&&r.addEventListener(e,this.handleEvent,{passive:i})}for(let e in n)"scroll"!=e&&!t[e]&&r.removeEventListener(e,this.handleEvent);this.handlers=t}keydown(e){let t;return this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),!!(9==e.keyCode&&Date.now()<this.lastEscPress+2e3)||((27!=e.keyCode&&0>tD.indexOf(e.keyCode)&&(this.view.inputState.lastEscPress=0),X.android&&X.chrome&&!e.synthetic&&(13==e.keyCode||8==e.keyCode))?(this.view.observer.delayAndroidKey(e.key,e.keyCode),!0):X.ios&&!e.synthetic&&!e.altKey&&!e.metaKey&&((t=tk.find(t=>t.keyCode==e.keyCode))&&!e.ctrlKey||tw.indexOf(e.key)>-1&&e.ctrlKey&&!e.shiftKey)?(this.pendingIOSKey=t||e,setTimeout(()=>this.flushIOSKey(),250),!0):(229!=e.keyCode&&this.view.observer.forceFlush(),!1))}flushIOSKey(e){let t=this.pendingIOSKey;return!(!t||"Enter"==t.key&&e&&e.from<e.to&&/^\S+$/.test(e.insert.toString()))&&(this.pendingIOSKey=void 0,F(this.view.contentDOM,t.key,t.keyCode,t instanceof KeyboardEvent?t:void 0))}ignoreDuringComposition(e){return!!/^key/.test(e.type)&&(!!(this.composing>0)||!!(X.safari&&!X.ios&&this.compositionPendingKey&&Date.now()-this.compositionEndedAt<100)&&(this.compositionPendingKey=!1,!0))}startMouseSelection(e){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=e}update(e){this.mouseSelection&&this.mouseSelection.update(e),this.draggedContent&&e.docChanged&&(this.draggedContent=this.draggedContent.map(e.changes)),e.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}}function tv(e,t){return(n,r)=>{try{return t.call(e,r,n)}catch(e){eQ(n.state,e)}}}let tk=[{key:"Backspace",keyCode:8,inputType:"deleteContentBackward"},{key:"Enter",keyCode:13,inputType:"insertParagraph"},{key:"Enter",keyCode:13,inputType:"insertLineBreak"},{key:"Delete",keyCode:46,inputType:"deleteContentForward"}],tw="dthko",tD=[16,17,18,20,91,92,224,225];function tA(e){return .7*Math.max(0,e)+8}class tx{constructor(e,t,n,r){this.view=e,this.startEvent=t,this.style=n,this.mustSelect=r,this.scrollSpeed={x:0,y:0},this.scrolling=-1,this.lastEvent=t,this.scrollParent=function(e){let t=e.ownerDocument;for(let n=e.parentNode;n&&n!=t.body;){;if(1==n.nodeType){if(n.scrollHeight>n.clientHeight||n.scrollWidth>n.clientWidth)return n;n=n.assignedSlot||n.parentNode}else if(11==n.nodeType)n=n.host;else break}return null}(e.contentDOM),this.atoms=e.state.facet(e4).map(t=>t(e));let i=e.contentDOM.ownerDocument;i.addEventListener("mousemove",this.move=this.move.bind(this)),i.addEventListener("mouseup",this.up=this.up.bind(this)),this.extend=t.shiftKey,this.multiple=e.state.facet(l.yy.allowMultipleSelections)&&function(e,t){let n=e.state.facet(eL);return n.length?n[0](t):X.mac?t.metaKey:t.ctrlKey}(e,t),this.dragging=!!function(e,t){let{main:n}=e.state.selection;if(n.empty)return!1;let r=m(e.root);if(!r||0==r.rangeCount)return!0;let i=r.getRangeAt(0).getClientRects();for(let e=0;e<i.length;e++){let n=i[e];if(n.left<=t.clientX&&n.right>=t.clientX&&n.top<=t.clientY&&n.bottom>=t.clientY)return!0}return!1}(e,t)&&1==t$(t)&&null}start(e){!1===this.dragging&&this.select(e)}move(e){var t,n,r;if(0==e.buttons)return this.destroy();if(this.dragging||null==this.dragging&&10>(n=this.startEvent,r=e,Math.max(Math.abs(n.clientX-r.clientX),Math.abs(n.clientY-r.clientY))))return;this.select(this.lastEvent=e);let i=0,s=0,o=(null===(t=this.scrollParent)||void 0===t?void 0:t.getBoundingClientRect())||{left:0,top:0,right:this.view.win.innerWidth,bottom:this.view.win.innerHeight},l=te(this.view);e.clientX-l.left<=o.left+6?i=-tA(o.left-e.clientX):e.clientX+l.right>=o.right-6&&(i=tA(e.clientX-o.right)),e.clientY-l.top<=o.top+6?s=-tA(o.top-e.clientY):e.clientY+l.bottom>=o.bottom-6&&(s=tA(e.clientY-o.bottom)),this.setScrollSpeed(i,s)}up(e){null==this.dragging&&this.select(this.lastEvent),!this.dragging&&e.preventDefault(),this.destroy()}destroy(){this.setScrollSpeed(0,0);let e=this.view.contentDOM.ownerDocument;e.removeEventListener("mousemove",this.move),e.removeEventListener("mouseup",this.up),this.view.inputState.mouseSelection=this.view.inputState.draggedContent=null}setScrollSpeed(e,t){this.scrollSpeed={x:e,y:t},e||t?this.scrolling<0&&(this.scrolling=setInterval(()=>this.scroll(),50)):this.scrolling>-1&&(clearInterval(this.scrolling),this.scrolling=-1)}scroll(){this.scrollParent?(this.scrollParent.scrollLeft+=this.scrollSpeed.x,this.scrollParent.scrollTop+=this.scrollSpeed.y):this.view.win.scrollBy(this.scrollSpeed.x,this.scrollSpeed.y),!1===this.dragging&&this.select(this.lastEvent)}skipAtoms(e){let t=null;for(let n=0;n<e.ranges.length;n++){let r=e.ranges[n],i=null;if(r.empty){let e=tg(this.atoms,r.from,0);e!=r.from&&(i=l.jT.cursor(e,-1))}else{let e=tg(this.atoms,r.from,-1),t=tg(this.atoms,r.to,1);(e!=r.from||t!=r.to)&&(i=l.jT.range(r.from==r.anchor?e:t,r.from==r.head?e:t))}i&&(!t&&(t=e.ranges.slice()),t[n]=i)}return t?l.jT.create(t,e.mainIndex):e}select(e){let{view:t}=this,n=this.skipAtoms(this.style.get(e,this.extend,this.multiple));(this.mustSelect||!n.eq(t.state.selection,!1===this.dragging))&&this.view.dispatch({selection:n,userEvent:"select.pointer"}),this.mustSelect=!1}update(e){this.style.update(e)&&setTimeout(()=>this.select(this.lastEvent),20)}}let tC=Object.create(null),tE=Object.create(null),tS=X.ie&&X.ie_version<15||X.ios&&X.webkit_version<604;function t_(e,t){let{state:n}=e,r,i=1,s=n.toText(t),o=s.lines==n.selection.ranges.length;if(null!=tR&&n.selection.ranges.every(e=>e.empty)&&tR==s.toString()){let e=-1;r=n.changeByRange(r=>{let a=n.doc.lineAt(r.from);if(a.from==e)return{range:r};e=a.from;let u=n.toText((o?s.line(i++).text:t)+n.lineBreak);return{changes:{from:a.from,insert:u},range:l.jT.cursor(r.from+u.length)}})}else r=o?n.changeByRange(e=>{let t=s.line(i++);return{changes:{from:e.from,to:e.to,insert:t.text},range:l.jT.cursor(e.from+t.length)}}):n.replaceSelection(s);e.dispatch(r,{userEvent:"input.paste",scrollIntoView:!0})}function tO(e,t,n,r){if(1==r)return l.jT.cursor(t,n);if(2==r)return function(e,t,n=1){let r=e.charCategorizer(t),i=e.doc.lineAt(t),s=t-i.from;if(0==i.length)return l.jT.cursor(t);0==s?n=1:s==i.length&&(n=-1);let o=s,a=s;n<0?o=(0,l.cp)(i.text,s,!1):a=(0,l.cp)(i.text,s);let u=r(i.text.slice(o,a));for(;o>0;){let e=(0,l.cp)(i.text,o,!1);if(r(i.text.slice(e,o))!=u)break;o=e}for(;a<i.length;){let e=(0,l.cp)(i.text,a);if(r(i.text.slice(a,e))!=u)break;a=e}return l.jT.range(o+i.from,a+i.from)}(e.state,t,n);{let n=eh.find(e.docView,t),r=e.state.doc.lineAt(n?n.posAtEnd:t),i=n?n.posAtStart:r.from,s=n?n.posAtEnd:r.to;return s<e.state.doc.length&&s==r.to&&s++,l.jT.range(i,s)}}tE.scroll=e=>{e.inputState.lastScrollTop=e.scrollDOM.scrollTop,e.inputState.lastScrollLeft=e.scrollDOM.scrollLeft},tC.keydown=(e,t)=>(e.inputState.setSelectionOrigin("select"),27==t.keyCode&&(e.inputState.lastEscPress=Date.now()),!1),tE.touchstart=(e,t)=>{e.inputState.lastTouchTime=Date.now(),e.inputState.setSelectionOrigin("select.pointer")},tE.touchmove=e=>{e.inputState.setSelectionOrigin("select.pointer")},tC.mousedown=(e,t)=>{if(e.observer.flush(),e.inputState.lastTouchTime>Date.now()-2e3)return!1;let n=null;for(let r of e.state.facet(ej))if(n=r(e,t))break;if(!n&&0==t.button&&(n=function(e,t){let n=tT(e,t),r=t$(t),i=e.state.selection;return{update(e){e.docChanged&&(n.pos=e.changes.mapPos(n.pos),i=i.map(e.changes))},get(t,s,o){let a=tT(e,t),u,h=tO(e,a.pos,a.bias,r);if(n.pos!=a.pos&&!s){let t=tO(e,n.pos,n.bias,r),i=Math.min(t.from,h.from),s=Math.max(t.to,h.to);h=i<h.from?l.jT.range(i,s):l.jT.range(s,i)}if(s)return i.replaceRange(i.main.extend(h.from,h.to));if(o&&1==r&&i.ranges.length>1&&(u=function(e,t){for(let n=0;n<e.ranges.length;n++){let{from:r,to:i}=e.ranges[n];if(r<=t&&i>=t)return l.jT.create(e.ranges.slice(0,n).concat(e.ranges.slice(n+1)),e.mainIndex==n?0:e.mainIndex-(e.mainIndex>n?1:0))}return null}(i,a.pos)))return u;if(o)return i.addRange(h);else return l.jT.create([h])}}}(e,t)),n){let r=!e.hasFocus;e.inputState.startMouseSelection(new tx(e,t,n,r)),r&&e.observer.ignore(()=>_(e.contentDOM));let i=e.inputState.mouseSelection;if(i)return i.start(t),!1===i.dragging}return!1};let tF=(e,t)=>e>=t.top&&e<=t.bottom,tP=(e,t,n)=>tF(t,n)&&e>=n.left&&e<=n.right;function tT(e,t){let n=e.posAtCoords({x:t.clientX,y:t.clientY},!1);return{pos:n,bias:function(e,t,n,r){let i=eh.find(e.docView,t);if(!i)return 1;let s=t-i.posAtStart;if(0==s)return 1;if(s==i.length)return -1;let o=i.coordsAt(s,-1);if(o&&tP(n,r,o))return -1;let l=i.coordsAt(s,1);return l&&tP(n,r,l)?1:o&&tF(r,o)?-1:1}(e,n,t.clientX,t.clientY)}}let tN=X.ie&&X.ie_version<=11,tB=null,tI=0,tM=0;function t$(e){if(!tN)return e.detail;let t=tB,n=tM;return tB=e,tM=Date.now(),tI=!t||n>Date.now()-400&&2>Math.abs(t.clientX-e.clientX)&&2>Math.abs(t.clientY-e.clientY)?(tI+1)%3:1}function tL(e,t,n,r){var i,s;let o;if(!n)return;let l=e.posAtCoords({x:t.clientX,y:t.clientY},!1),{draggedContent:a}=e.inputState;let u=r&&a&&(i=e,s=t,(o=i.state.facet(eR)).length?o[0](s):X.mac?!s.altKey:!s.ctrlKey)?{from:a.from,to:a.to}:null,h={from:l,insert:n},c=e.state.changes(u?[u,h]:h);e.focus(),e.dispatch({changes:c,selection:{anchor:c.mapPos(l,-1),head:c.mapPos(l,1)},userEvent:u?"move.drop":"input.drop"}),e.inputState.draggedContent=null}tC.dragstart=(e,t)=>{let{selection:{main:n}}=e.state;if(t.target.draggable){let r=e.docView.nearest(t.target);if(r&&r.isWidget){let e=r.posAtStart,t=e+r.length;(e>=n.to||t<=n.from)&&(n=l.jT.range(e,t))}}let{inputState:r}=e;return r.mouseSelection&&(r.mouseSelection.dragging=!0),r.draggedContent=n,t.dataTransfer&&(t.dataTransfer.setData("Text",e.state.sliceDoc(n.from,n.to)),t.dataTransfer.effectAllowed="copyMove"),!1},tC.dragend=e=>(e.inputState.draggedContent=null,!1),tC.drop=(e,t)=>{if(!t.dataTransfer)return!1;if(e.state.readOnly)return!0;let n=t.dataTransfer.files;if(n&&n.length){let r=Array(n.length),i=0,s=()=>{++i==n.length&&tL(e,t,r.filter(e=>null!=e).join(e.state.lineBreak),!1)};for(let e=0;e<n.length;e++){let t=new FileReader;t.onerror=s,t.onload=()=>{!/[\x00-\x08\x0e-\x1f]{2}/.test(t.result)&&(r[e]=t.result),s()},t.readAsText(n[e])}return!0}{let n=t.dataTransfer.getData("Text");if(n)return tL(e,t,n,!0),!0}return!1},tC.paste=(e,t)=>{if(e.state.readOnly)return!0;e.observer.flush();let n=tS?null:t.clipboardData;return n?(t_(e,n.getData("text/plain")||n.getData("text/uri-list")),!0):(!function(e){let t=e.dom.parentNode;if(!t)return;let n=t.appendChild(document.createElement("textarea"));n.style.cssText="position: fixed; left: -10000px; top: 10px",n.focus(),setTimeout(()=>{e.focus(),n.remove(),t_(e,n.value)},50)}(e),!1)};let tR=null;tC.copy=tC.cut=(e,t)=>{let{text:n,ranges:r,linewise:i}=function(e){let t=[],n=[],r=!1;for(let r of e.selection.ranges)!r.empty&&(t.push(e.sliceDoc(r.from,r.to)),n.push(r));if(!t.length){let i=-1;for(let{from:r}of e.selection.ranges){let s=e.doc.lineAt(r);s.number>i&&(t.push(s.text),n.push({from:s.from,to:Math.min(e.doc.length,s.to+1)})),i=s.number}r=!0}return{text:t.join(e.lineBreak),ranges:n,linewise:r}}(e.state);if(!n&&!i)return!1;tR=i?n:null,"cut"==t.type&&!e.state.readOnly&&e.dispatch({changes:r,scrollIntoView:!0,userEvent:"delete.cut"});let s=tS?null:t.clipboardData;return s?(s.clearData(),s.setData("text/plain",n),!0):(!function(e,t){let n=e.dom.parentNode;if(!n)return;let r=n.appendChild(document.createElement("textarea"));r.style.cssText="position: fixed; left: -10000px; top: 10px",r.value=t,r.focus(),r.selectionEnd=t.length,r.selectionStart=0,setTimeout(()=>{r.remove(),e.focus()},50)}(e,n),!1)};let tj=l.q6.define();function tq(e,t){let n=[];for(let r of e.facet(eU)){let i=r(e,t);i&&n.push(i)}return n?e.update({effects:n,annotations:tj.of(!0)}):null}function tV(e){setTimeout(()=>{let t=e.hasFocus;if(t!=e.inputState.notifiedFocused){let n=tq(e.state,t);n?e.dispatch(n):e.update([])}},10)}tE.focus=e=>{e.inputState.lastFocusTime=Date.now(),!e.scrollDOM.scrollTop&&(e.inputState.lastScrollTop||e.inputState.lastScrollLeft)&&(e.scrollDOM.scrollTop=e.inputState.lastScrollTop,e.scrollDOM.scrollLeft=e.inputState.lastScrollLeft),tV(e)},tE.blur=e=>{e.observer.clearSelectionRange(),tV(e)},tE.compositionstart=tE.compositionupdate=e=>{null==e.inputState.compositionFirstChange&&(e.inputState.compositionFirstChange=!0),e.inputState.composing<0&&(e.inputState.composing=0)},tE.compositionend=e=>{e.inputState.composing=-1,e.inputState.compositionEndedAt=Date.now(),e.inputState.compositionPendingKey=!0,e.inputState.compositionPendingChange=e.observer.pendingRecords().length>0,e.inputState.compositionFirstChange=null,X.chrome&&X.android?e.observer.flushSoon():e.inputState.compositionPendingChange?Promise.resolve().then(()=>e.observer.flush()):setTimeout(()=>{e.inputState.composing<0&&e.docView.hasComposition&&e.update([])},50)},tE.contextmenu=e=>{e.inputState.lastContextMenu=Date.now()},tC.beforeinput=(e,t)=>{var n;let r;if(X.chrome&&X.android&&(r=tk.find(e=>e.inputType==t.inputType))&&(e.observer.delayAndroidKey(r.key,r.keyCode),"Backspace"==r.key||"Delete"==r.key)){let t=(null===(n=window.visualViewport)||void 0===n?void 0:n.height)||0;setTimeout(()=>{var n;((null===(n=window.visualViewport)||void 0===n?void 0:n.height)||0)>t+10&&e.hasFocus&&(e.contentDOM.blur(),e.focus())},100)}return X.ios&&"deleteContentForward"==t.inputType&&e.observer.flushSoon(),X.safari&&"insertText"==t.inputType&&e.inputState.composing>=0&&setTimeout(()=>tE.compositionend(e,t),20),!1};let tz=new Set,tU=["pre-wrap","normal","pre-line","break-spaces"];class tH{constructor(e){this.lineWrapping=e,this.doc=l.xv.empty,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.textHeight=14,this.lineLength=30,this.heightChanged=!1}heightForGap(e,t){let n=this.doc.lineAt(t).number-this.doc.lineAt(e).number+1;return this.lineWrapping&&(n+=Math.max(0,Math.ceil((t-e-n*this.lineLength*.5)/this.lineLength))),this.lineHeight*n}heightForLine(e){return this.lineWrapping?(1+Math.max(0,Math.ceil((e-this.lineLength)/(this.lineLength-5))))*this.lineHeight:this.lineHeight}setDoc(e){return this.doc=e,this}mustRefreshForWrapping(e){return tU.indexOf(e)>-1!=this.lineWrapping}mustRefreshForHeights(e){let t=!1;for(let n=0;n<e.length;n++){let r=e[n];r<0?n++:!this.heightSamples[Math.floor(10*r)]&&(t=!0,this.heightSamples[Math.floor(10*r)]=!0)}return t}refresh(e,t,n,r,i,s){let o=tU.indexOf(e)>-1,l=Math.round(t)!=Math.round(this.lineHeight)||this.lineWrapping!=o;if(this.lineWrapping=o,this.lineHeight=t,this.charWidth=n,this.textHeight=r,this.lineLength=i,l){this.heightSamples={};for(let e=0;e<s.length;e++){let t=s[e];t<0?e++:this.heightSamples[Math.floor(10*t)]=!0}}return l}}class tW{constructor(e,t){this.from=e,this.heights=t,this.index=0}get more(){return this.index<this.heights.length}}class tG{constructor(e,t,n,r,i){this.from=e,this.length=t,this.top=n,this.height=r,this._content=i}get type(){return"number"==typeof this._content?ed.Text:Array.isArray(this._content)?this._content:this._content.type}get to(){return this.from+this.length}get bottom(){return this.top+this.height}get widget(){return this._content instanceof ey?this._content.widget:null}get widgetLineBreaks(){return"number"==typeof this._content?this._content:0}join(e){let t=(Array.isArray(this._content)?this._content:[this]).concat(Array.isArray(e._content)?e._content:[e]);return new tG(this.from,this.length+e.length,this.top,this.height+e.height,t)}}var tK=((o=tK||(tK={}))[o.ByPos=0]="ByPos",o[o.ByHeight=1]="ByHeight",o[o.ByPosNoHeight=2]="ByPosNoHeight",o);class tJ{constructor(e,t,n=2){this.length=e,this.height=t,this.flags=n}get outdated(){return(2&this.flags)>0}set outdated(e){this.flags=(e?2:0)|-3&this.flags}setHeight(e,t){this.height!=t&&(Math.abs(this.height-t)>.001&&(e.heightChanged=!0),this.height=t)}replace(e,t,n){return tJ.of(n)}decomposeLeft(e,t){t.push(this)}decomposeRight(e,t){t.push(this)}applyChanges(e,t,n,r){let i=this,s=n.doc;for(let o=r.length-1;o>=0;o--){let{fromA:l,toA:a,fromB:u,toB:h}=r[o],c=i.lineAt(l,tK.ByPosNoHeight,n.setDoc(t),0,0),f=c.to>=a?c:i.lineAt(a,tK.ByPosNoHeight,n,0,0);for(h+=f.to-a,a=f.to;o>0&&c.from<=r[o-1].toA;)l=r[o-1].fromA,u=r[o-1].fromB,o--,l<c.from&&(c=i.lineAt(l,tK.ByPosNoHeight,n,0,0));u+=c.from-l,l=c.from;let d=t1.build(n.setDoc(s),e,u,h);i=i.replace(l,a,d)}return i.updateHeight(n,0)}static empty(){return new tY(0,0)}static of(e){if(1==e.length)return e[0];let t=0,n=e.length,r=0,i=0;for(;;)if(t==n){if(r>2*i){let i=e[t-1];i.break?e.splice(--t,1,i.left,null,i.right):e.splice(--t,1,i.left,i.right),n+=1+i.break,r-=i.size}else if(i>2*r){let t=e[n];t.break?e.splice(n,1,t.left,null,t.right):e.splice(n,1,t.left,t.right),n+=2+t.break,i-=t.size}else break}else if(r<i){let n=e[t++];n&&(r+=n.size)}else{let t=e[--n];t&&(i+=t.size)}let s=0;return null==e[t-1]?(s=1,t--):null==e[t]&&(s=1,n++),new tX(tJ.of(e.slice(0,t)),s,tJ.of(e.slice(n)))}}tJ.prototype.size=1;class tQ extends tJ{constructor(e,t,n){super(e,t),this.deco=n}blockAt(e,t,n,r){return new tG(r,this.length,n,this.height,this.deco||0)}lineAt(e,t,n,r,i){return this.blockAt(0,n,r,i)}forEachLine(e,t,n,r,i,s){e<=i+this.length&&t>=i&&s(this.blockAt(0,n,r,i))}updateHeight(e,t=0,n=!1,r){return r&&r.from<=t&&r.more&&this.setHeight(e,r.heights[r.index++]),this.outdated=!1,this}toString(){return`block(${this.length})`}}class tY extends tQ{constructor(e,t){super(e,t,null),this.collapsed=0,this.widgetHeight=0,this.breaks=0}blockAt(e,t,n,r){return new tG(r,this.length,n,this.height,this.breaks)}replace(e,t,n){let r=n[0];return 1==n.length&&(r instanceof tY||r instanceof tZ&&4&r.flags)&&10>Math.abs(this.length-r.length)?(r instanceof tZ?r=new tY(r.length,this.height):r.height=this.height,!this.outdated&&(r.outdated=!1),r):tJ.of(n)}updateHeight(e,t=0,n=!1,r){return r&&r.from<=t&&r.more?this.setHeight(e,r.heights[r.index++]):(n||this.outdated)&&this.setHeight(e,Math.max(this.widgetHeight,e.heightForLine(this.length-this.collapsed))+this.breaks*e.lineHeight),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:""}${this.widgetHeight?":"+this.widgetHeight:""})`}}class tZ extends tJ{constructor(e){super(e,0)}heightMetrics(e,t){let n=e.doc.lineAt(t).number,r=e.doc.lineAt(t+this.length).number,i=r-n+1,s,o=0;if(e.lineWrapping){let t=Math.min(this.height,e.lineHeight*i);s=t/i,this.length>i+1&&(o=(this.height-t)/(this.length-i-1))}else s=this.height/i;return{firstLine:n,lastLine:r,perLine:s,perChar:o}}blockAt(e,t,n,r){let{firstLine:i,lastLine:s,perLine:o,perChar:l}=this.heightMetrics(t,r);if(t.lineWrapping){let i=r+(e<t.lineHeight?0:Math.round(Math.max(0,Math.min(1,(e-n)/this.height))*this.length)),s=t.doc.lineAt(i),a=o+s.length*l,u=Math.max(n,e-a/2);return new tG(s.from,s.length,u,a,0)}{let r=Math.max(0,Math.min(s-i,Math.floor((e-n)/o))),{from:l,length:a}=t.doc.line(i+r);return new tG(l,a,n+o*r,o,0)}}lineAt(e,t,n,r,i){if(t==tK.ByHeight)return this.blockAt(e,n,r,i);if(t==tK.ByPosNoHeight){let{from:t,to:r}=n.doc.lineAt(e);return new tG(t,r-t,0,0,0)}let{firstLine:s,perLine:o,perChar:l}=this.heightMetrics(n,i),a=n.doc.lineAt(e),u=o+a.length*l,h=a.number-s,c=r+o*h+l*(a.from-i-h);return new tG(a.from,a.length,Math.max(r,Math.min(c,r+this.height-u)),u,0)}forEachLine(e,t,n,r,i,s){e=Math.max(e,i),t=Math.min(t,i+this.length);let{firstLine:o,perLine:l,perChar:a}=this.heightMetrics(n,i);for(let u=e,h=r;u<=t;){let t=n.doc.lineAt(u);if(u==e){let n=t.number-o;h+=l*n+a*(e-i-n)}let r=l+a*t.length;s(new tG(t.from,t.length,h,r,0)),h+=r,u=t.to+1}}replace(e,t,n){let r=this.length-t;if(r>0){let e=n[n.length-1];e instanceof tZ?n[n.length-1]=new tZ(e.length+r):n.push(null,new tZ(r-1))}if(e>0){let t=n[0];t instanceof tZ?n[0]=new tZ(e+t.length):n.unshift(new tZ(e-1),null)}return tJ.of(n)}decomposeLeft(e,t){t.push(new tZ(e-1),null)}decomposeRight(e,t){t.push(null,new tZ(this.length-e-1))}updateHeight(e,t=0,n=!1,r){let i=t+this.length;if(r&&r.from<=t+this.length&&r.more){let n=[],s=Math.max(t,r.from),o=-1;for(r.from>t&&n.push(new tZ(r.from-t-1).updateHeight(e,t));s<=i&&r.more;){let t=e.doc.lineAt(s).length;n.length&&n.push(null);let i=r.heights[r.index++];-1==o?o=i:Math.abs(i-o)>=.001&&(o=-2);let l=new tY(t,i);l.outdated=!1,n.push(l),s+=t+1}s<=i&&n.push(null,new tZ(i-s).updateHeight(e,s));let l=tJ.of(n);return(o<0||Math.abs(l.height-this.height)>=.001||Math.abs(o-this.heightMetrics(e,t).perLine)>=.001)&&(e.heightChanged=!0),l}return(n||this.outdated)&&(this.setHeight(e,e.heightForGap(t,t+this.length)),this.outdated=!1),this}toString(){return`gap(${this.length})`}}class tX extends tJ{constructor(e,t,n){super(e.length+t+n.length,e.height+n.height,t|(e.outdated||n.outdated?2:0)),this.left=e,this.right=n,this.size=e.size+n.size}get break(){return 1&this.flags}blockAt(e,t,n,r){let i=n+this.left.height;return e<i?this.left.blockAt(e,t,n,r):this.right.blockAt(e,t,i,r+this.left.length+this.break)}lineAt(e,t,n,r,i){let s=r+this.left.height,o=i+this.left.length+this.break,l=t==tK.ByHeight?e<s:e<o,a=l?this.left.lineAt(e,t,n,r,i):this.right.lineAt(e,t,n,s,o);if(this.break||(l?a.to<o:a.from>o))return a;let u=t==tK.ByPosNoHeight?tK.ByPosNoHeight:tK.ByPos;return l?a.join(this.right.lineAt(o,u,n,s,o)):this.left.lineAt(o,u,n,r,i).join(a)}forEachLine(e,t,n,r,i,s){let o=r+this.left.height,l=i+this.left.length+this.break;if(this.break)e<l&&this.left.forEachLine(e,t,n,r,i,s),t>=l&&this.right.forEachLine(e,t,n,o,l,s);else{let a=this.lineAt(l,tK.ByPos,n,r,i);e<a.from&&this.left.forEachLine(e,a.from-1,n,r,i,s),a.to>=e&&a.from<=t&&s(a),t>a.to&&this.right.forEachLine(a.to+1,t,n,o,l,s)}}replace(e,t,n){let r=this.left.length+this.break;if(t<r)return this.balanced(this.left.replace(e,t,n),this.right);if(e>this.left.length)return this.balanced(this.left,this.right.replace(e-r,t-r,n));let i=[];e>0&&this.decomposeLeft(e,i);let s=i.length;for(let e of n)i.push(e);if(e>0&&t0(i,s-1),t<this.length){let e=i.length;this.decomposeRight(t,i),t0(i,e)}return tJ.of(i)}decomposeLeft(e,t){let n=this.left.length;if(e<=n)return this.left.decomposeLeft(e,t);t.push(this.left),this.break&&e>=++n&&t.push(null),e>n&&this.right.decomposeLeft(e-n,t)}decomposeRight(e,t){let n=this.left.length,r=n+this.break;if(e>=r)return this.right.decomposeRight(e-r,t);e<n&&this.left.decomposeRight(e,t),this.break&&e<r&&t.push(null),t.push(this.right)}balanced(e,t){return e.size>2*t.size||t.size>2*e.size?tJ.of(this.break?[e,null,t]:[e,t]):(this.left=e,this.right=t,this.height=e.height+t.height,this.outdated=e.outdated||t.outdated,this.size=e.size+t.size,this.length=e.length+this.break+t.length,this)}updateHeight(e,t=0,n=!1,r){let{left:i,right:s}=this,o=t+i.length+this.break,l=null;return(r&&r.from<=t+i.length&&r.more?l=i=i.updateHeight(e,t,n,r):i.updateHeight(e,t,n),r&&r.from<=o+s.length&&r.more?l=s=s.updateHeight(e,o,n,r):s.updateHeight(e,o,n),l)?this.balanced(i,s):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?" ":"-")+this.right}}function t0(e,t){let n,r;null==e[t]&&(n=e[t-1])instanceof tZ&&(r=e[t+1])instanceof tZ&&e.splice(t-1,3,new tZ(n.length+1+r.length))}class t1{constructor(e,t){this.pos=e,this.oracle=t,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=e}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(e,t){if(this.lineStart>-1){let e=Math.min(t,this.lineEnd),n=this.nodes[this.nodes.length-1];n instanceof tY?n.length+=e-this.pos:(e>this.pos||!this.isCovered)&&this.nodes.push(new tY(e-this.pos,-1)),this.writtenTo=e,t>e&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=t}point(e,t,n){if(e<t||n.heightRelevant){let r=n.widget?n.widget.estimatedHeight:0,i=n.widget?n.widget.lineBreaks:0;r<0&&(r=this.oracle.lineHeight);let s=t-e;n.block?this.addBlock(new tQ(s,r,n)):(s||i||r>=5)&&this.addLineDeco(r,i,s)}else t>e&&this.span(e,t);this.lineEnd>-1&&this.lineEnd<this.pos&&(this.lineEnd=this.oracle.doc.lineAt(this.pos).to)}enterLine(){if(this.lineStart>-1)return;let{from:e,to:t}=this.oracle.doc.lineAt(this.pos);this.lineStart=e,this.lineEnd=t,this.writtenTo<e&&((this.writtenTo<e-1||null==this.nodes[this.nodes.length-1])&&this.nodes.push(this.blankContent(this.writtenTo,e-1)),this.nodes.push(null)),this.pos>e&&this.nodes.push(new tY(this.pos-e,-1)),this.writtenTo=this.pos}blankContent(e,t){let n=new tZ(t-e);return this.oracle.doc.lineAt(e).to==t&&(n.flags|=4),n}ensureLine(){this.enterLine();let e=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(e instanceof tY)return e;let t=new tY(0,-1);return this.nodes.push(t),t}addBlock(e){this.enterLine();let t=e.deco;t&&t.startSide>0&&!this.isCovered&&this.ensureLine(),this.nodes.push(e),this.writtenTo=this.pos=this.pos+e.length,t&&t.endSide>0&&(this.covering=e)}addLineDeco(e,t,n){let r=this.ensureLine();r.length+=n,r.collapsed+=n,r.widgetHeight=Math.max(r.widgetHeight,e),r.breaks+=t,this.writtenTo=this.pos=this.pos+n}finish(e){let t=0==this.nodes.length?null:this.nodes[this.nodes.length-1];!(this.lineStart>-1)||t instanceof tY||this.isCovered?(this.writtenTo<this.pos||null==t)&&this.nodes.push(this.blankContent(this.writtenTo,this.pos)):this.nodes.push(new tY(0,-1));let n=e;for(let e of this.nodes)e instanceof tY&&e.updateHeight(this.oracle,n),n+=e?e.length:1;return this.nodes}static build(e,t,n,r){let i=new t1(n,e);return l.Xs.spans(t,n,r,i,0),i.finish(n)}}class t2{constructor(){this.changes=[]}compareRange(){}comparePoint(e,t,n,r){(e<t||n&&n.heightRelevant||r&&r.heightRelevant)&&ev(e,t,this.changes,5)}}class t3{constructor(e,t,n){this.from=e,this.to=t,this.size=n}static same(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++){let r=e[n],i=t[n];if(r.from!=i.from||r.to!=i.to||r.size!=i.size)return!1}return!0}draw(e,t){return ep.replace({widget:new t5(this.size*(t?e.scaleY:e.scaleX),t)}).range(this.from,this.to)}}class t5 extends ef{constructor(e,t){super(),this.size=e,this.vertical=t}eq(e){return e.size==this.size&&e.vertical==this.vertical}toDOM(){let e=document.createElement("div");return this.vertical?e.style.height=this.size+"px":(e.style.width=this.size+"px",e.style.height="2px",e.style.display="inline-block"),e}get estimatedHeight(){return this.vertical?this.size:-1}}class t8{constructor(e){this.state=e,this.pixelViewport={left:0,right:window.innerWidth,top:0,bottom:0},this.inView=!0,this.paddingTop=0,this.paddingBottom=0,this.contentDOMWidth=0,this.contentDOMHeight=0,this.editorHeight=0,this.editorWidth=0,this.scrollTop=0,this.scrolledToBottom=!1,this.scaleX=1,this.scaleY=1,this.scrollAnchorPos=0,this.scrollAnchorHeight=-1,this.scaler=t7,this.scrollTarget=null,this.printing=!1,this.mustMeasureContent=!0,this.defaultTextDirection=eA.LTR,this.visibleRanges=[],this.mustEnforceCursorAssoc=!1;let t=e.facet(e3).some(e=>"function"!=typeof e&&"cm-lineWrapping"==e.class);this.heightOracle=new tH(t),this.stateDeco=e.facet(e5).filter(e=>"function"!=typeof e),this.heightMap=tJ.empty().applyChanges(this.stateDeco,l.xv.empty,this.heightOracle.setDoc(e.doc),[new tn(0,0,0,e.doc.length)]),this.viewport=this.getViewport(0,null),this.updateViewportLines(),this.updateForViewport(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=ep.set(this.lineGaps.map(e=>e.draw(this,!1))),this.computeVisibleRanges()}updateForViewport(){let e=[this.viewport],{main:t}=this.state.selection;for(let n=0;n<=1;n++){let r=n?t.head:t.anchor;if(!e.some(({from:e,to:t})=>r>=e&&r<=t)){let{from:t,to:n}=this.lineBlockAt(r);e.push(new t4(t,n))}}this.viewports=e.sort((e,t)=>e.from-t.from),this.scaler=this.heightMap.height<=7e6?t7:new ne(this.heightOracle,this.heightMap,this.viewports)}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.heightOracle.setDoc(this.state.doc),0,0,e=>{this.viewportLines.push(1==this.scaler.scale?e:nt(e,this.scaler))})}update(e,t=null){var n,r,i;let s;this.state=e.state;let o=this.stateDeco;this.stateDeco=this.state.facet(e5).filter(e=>"function"!=typeof e);let a=e.changedRanges;let u=tn.extendWithRanges(a,(n=o,r=this.stateDeco,i=e?e.changes:l.as.empty(this.state.doc.length),s=new t2,l.Xs.compare(n,r,i,s,0),s.changes)),h=this.heightMap.height,c=this.scrolledToBottom?null:this.scrollAnchorAt(this.scrollTop);this.heightMap=this.heightMap.applyChanges(this.stateDeco,e.startState.doc,this.heightOracle.setDoc(this.state.doc),u),this.heightMap.height!=h&&(e.flags|=2),c?(this.scrollAnchorPos=e.changes.mapPos(c.from,-1),this.scrollAnchorHeight=c.top):(this.scrollAnchorPos=-1,this.scrollAnchorHeight=this.heightMap.height);let f=u.length?this.mapViewport(this.viewport,e.changes):this.viewport;(t&&(t.range.head<f.from||t.range.head>f.to)||!this.viewportIsAppropriate(f))&&(f=this.getViewport(0,t));let d=!e.changes.empty||2&e.flags||f.from!=this.viewport.from||f.to!=this.viewport.to;this.viewport=f,this.updateForViewport(),d&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,e.changes))),e.flags|=this.computeVisibleRanges(),t&&(this.scrollTarget=t),!this.mustEnforceCursorAssoc&&e.selectionSet&&e.view.lineWrapping&&e.state.selection.main.empty&&e.state.selection.main.assoc&&!e.state.facet(eW)&&(this.mustEnforceCursorAssoc=!0)}measure(e){let t=e.contentDOM,n=window.getComputedStyle(t),r=this.heightOracle,i=n.whiteSpace;this.defaultTextDirection="rtl"==n.direction?eA.RTL:eA.LTR;let s=this.heightOracle.mustRefreshForWrapping(i),o=t.getBoundingClientRect(),a=s||this.mustMeasureContent||this.contentDOMHeight!=o.height;this.contentDOMHeight=o.height,this.mustMeasureContent=!1;let u=0,h=0;if(o.width&&o.height){let{scaleX:e,scaleY:n}=C(t,o);(e>.005&&Math.abs(this.scaleX-e)>.005||n>.005&&Math.abs(this.scaleY-n)>.005)&&(this.scaleX=e,this.scaleY=n,u|=8,s=a=!0)}let c=(parseInt(n.paddingTop)||0)*this.scaleY,f=(parseInt(n.paddingBottom)||0)*this.scaleY;(this.paddingTop!=c||this.paddingBottom!=f)&&(this.paddingTop=c,this.paddingBottom=f,u|=10),this.editorWidth!=e.scrollDOM.clientWidth&&(r.lineWrapping&&(a=!0),this.editorWidth=e.scrollDOM.clientWidth,u|=8);let d=e.scrollDOM.scrollTop*this.scaleY;this.scrollTop!=d&&(this.scrollAnchorHeight=-1,this.scrollTop=d),this.scrolledToBottom=T(e.scrollDOM);let p=(this.printing?function(e,t){let n=e.getBoundingClientRect();return{left:0,right:n.right-n.left,top:t,bottom:n.bottom-(n.top+t)}}:function(e,t){let n=e.getBoundingClientRect(),r=e.ownerDocument,i=r.defaultView||window,s=Math.max(0,n.left),o=Math.min(i.innerWidth,n.right),l=Math.max(0,n.top),a=Math.min(i.innerHeight,n.bottom);for(let t=e.parentNode;t&&t!=r.body;)if(1==t.nodeType){let n=t,r=window.getComputedStyle(n);if((n.scrollHeight>n.clientHeight||n.scrollWidth>n.clientWidth)&&"visible"!=r.overflow){let r=n.getBoundingClientRect();s=Math.max(s,r.left),o=Math.min(o,r.right),l=Math.max(l,r.top),a=t==e.parentNode?r.bottom:Math.min(a,r.bottom)}t="absolute"==r.position||"fixed"==r.position?n.offsetParent:n.parentNode}else if(11==t.nodeType)t=t.host;else break;return{left:s-n.left,right:Math.max(s,o)-n.left,top:l-(n.top+t),bottom:Math.max(l,a)-(n.top+t)}})(t,this.paddingTop),m=p.top-this.pixelViewport.top,g=p.bottom-this.pixelViewport.bottom;this.pixelViewport=p;let y=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(y!=this.inView&&(this.inView=y,y&&(a=!0)),!this.inView&&!this.scrollTarget)return 0;let b=o.width;if((this.contentDOMWidth!=b||this.editorHeight!=e.scrollDOM.clientHeight)&&(this.contentDOMWidth=o.width,this.editorHeight=e.scrollDOM.clientHeight,u|=8),a){let t=e.docView.measureVisibleLineHeights(this.viewport);if(r.mustRefreshForHeights(t)&&(s=!0),s||r.lineWrapping&&Math.abs(b-this.contentDOMWidth)>r.charWidth){let{lineHeight:n,charWidth:o,textHeight:l}=e.docView.measureTextSize();(s=n>0&&r.refresh(i,n,o,l,b/o,t))&&(e.docView.minWidth=0,u|=8)}for(let n of(m>0&&g>0?h=Math.max(m,g):m<0&&g<0&&(h=Math.min(m,g)),r.heightChanged=!1,this.viewports)){let i=n.from==this.viewport.from?t:e.docView.measureVisibleLineHeights(n);this.heightMap=(s?tJ.empty().applyChanges(this.stateDeco,l.xv.empty,this.heightOracle,[new tn(0,0,0,e.state.doc.length)]):this.heightMap).updateHeight(r,0,s,new tW(n.from,i))}r.heightChanged&&(u|=2)}let v=!this.viewportIsAppropriate(this.viewport,h)||this.scrollTarget&&(this.scrollTarget.range.head<this.viewport.from||this.scrollTarget.range.head>this.viewport.to);return v&&(this.viewport=this.getViewport(h,this.scrollTarget)),this.updateForViewport(),(2&u||v)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(s?[]:this.lineGaps,e)),u|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,e.docView.enforceCursorAssoc()),u}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(e,t){let n=.5-Math.max(-.5,Math.min(.5,e/1e3/2)),r=this.heightMap,i=this.heightOracle,{visibleTop:s,visibleBottom:o}=this,l=new t4(r.lineAt(s-1e3*n,tK.ByHeight,i,0,0).from,r.lineAt(o+(1-n)*1e3,tK.ByHeight,i,0,0).to);if(t){let{head:e}=t.range;if(e<l.from||e>l.to){let n=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),s=r.lineAt(e,tK.ByPos,i,0,0),o;o="center"==t.y?(s.top+s.bottom)/2-n/2:"start"==t.y||"nearest"==t.y&&e<l.from?s.top:s.bottom-n,l=new t4(r.lineAt(o-500,tK.ByHeight,i,0,0).from,r.lineAt(o+n+500,tK.ByHeight,i,0,0).to)}}return l}mapViewport(e,t){let n=t.mapPos(e.from,-1),r=t.mapPos(e.to,1);return new t4(this.heightMap.lineAt(n,tK.ByPos,this.heightOracle,0,0).from,this.heightMap.lineAt(r,tK.ByPos,this.heightOracle,0,0).to)}viewportIsAppropriate({from:e,to:t},n=0){if(!this.inView)return!0;let{top:r}=this.heightMap.lineAt(e,tK.ByPos,this.heightOracle,0,0),{bottom:i}=this.heightMap.lineAt(t,tK.ByPos,this.heightOracle,0,0),{visibleTop:s,visibleBottom:o}=this;return(0==e||r<=s-Math.max(10,Math.min(-n,250)))&&(t==this.state.doc.length||i>=o+Math.max(10,Math.min(n,250)))&&r>s-2e3&&i<o+2e3}mapLineGaps(e,t){if(!e.length||t.empty)return e;let n=[];for(let r of e)!t.touchesRange(r.from,r.to)&&n.push(new t3(t.mapPos(r.from),t.mapPos(r.to),r.size));return n}ensureLineGaps(e,t){let n=this.heightOracle.lineWrapping,r=n?1e4:2e3,i=r>>1,s=r<<1;if(this.defaultTextDirection!=eA.LTR&&!n)return[];let o=[],a=(r,s,u,h)=>{if(s-r<i)return;let c=this.state.selection.main,f=[c.from];for(let e of(!c.empty&&f.push(c.to),f))if(e>r&&e<s){a(r,e-10,u,h),a(e+10,s,u,h);return}let d=function(e,t){for(let n of e)if(t(n))return n}(e,e=>e.from>=u.from&&e.to<=u.to&&Math.abs(e.from-r)<i&&Math.abs(e.to-s)<i&&!f.some(t=>e.from<t&&e.to>t));if(!d){if(s<u.to&&t&&n&&t.visibleRanges.some(e=>e.from<=s&&e.to>=s)){let e=t.moveToLineBoundary(l.jT.cursor(s),!1,!0).head;e>r&&(s=e)}d=new t3(r,s,this.gapSize(u,r,s,h))}o.push(d)};for(let e of this.viewportLines){let t,i;if(e.length<s)continue;let o=function(e,t,n){let r=[],i=e,s=0;return l.Xs.spans(n,e,t,{span(){},point(e,t){e>i&&(r.push({from:i,to:e}),s+=e-i),i=t}},20),i<t&&(r.push({from:i,to:t}),s+=t-i),{total:s,ranges:r}}(e.from,e.to,this.stateDeco);if(o.total<s)continue;let u=this.scrollTarget?this.scrollTarget.range.head:null;if(n){let n,s,l=r/this.heightOracle.lineLength*this.heightOracle.lineHeight;if(null!=u){let t=t9(o,u),r=((this.visibleBottom-this.visibleTop)/2+l)/e.height;n=t-r,s=t+r}else n=(this.visibleTop-e.top-l)/e.height,s=(this.visibleBottom-e.top+l)/e.height;t=t6(o,n),i=t6(o,s)}else{let e,n,s=o.total*this.heightOracle.charWidth,l=r*this.heightOracle.charWidth;if(null!=u){let t=t9(o,u),r=((this.pixelViewport.right-this.pixelViewport.left)/2+l)/s;e=t-r,n=t+r}else e=(this.pixelViewport.left-l)/s,n=(this.pixelViewport.right+l)/s;t=t6(o,e),i=t6(o,n)}t>e.from&&a(e.from,t,e,o),i<e.to&&a(i,e.to,e,o)}return o}gapSize(e,t,n,r){let i=t9(r,n)-t9(r,t);return this.heightOracle.lineWrapping?e.height*i:r.total*this.heightOracle.charWidth*i}updateLineGaps(e){!t3.same(e,this.lineGaps)&&(this.lineGaps=e,this.lineGapDeco=ep.set(e.map(e=>e.draw(this,this.heightOracle.lineWrapping))))}computeVisibleRanges(){let e=this.stateDeco;this.lineGaps.length&&(e=e.concat(this.lineGapDeco));let t=[];l.Xs.spans(e,this.viewport.from,this.viewport.to,{span(e,n){t.push({from:e,to:n})},point(){}},20);let n=t.length!=this.visibleRanges.length||this.visibleRanges.some((e,n)=>e.from!=t[n].from||e.to!=t[n].to);return this.visibleRanges=t,n?4:0}lineBlockAt(e){return e>=this.viewport.from&&e<=this.viewport.to&&this.viewportLines.find(t=>t.from<=e&&t.to>=e)||nt(this.heightMap.lineAt(e,tK.ByPos,this.heightOracle,0,0),this.scaler)}lineBlockAtHeight(e){return nt(this.heightMap.lineAt(this.scaler.fromDOM(e),tK.ByHeight,this.heightOracle,0,0),this.scaler)}scrollAnchorAt(e){let t=this.lineBlockAtHeight(e+8);return t.from>=this.viewport.from||this.viewportLines[0].top-e>200?t:this.viewportLines[0]}elementAtHeight(e){return nt(this.heightMap.blockAt(this.scaler.fromDOM(e),this.heightOracle,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}}class t4{constructor(e,t){this.from=e,this.to=t}}function t6({total:e,ranges:t},n){if(n<=0)return t[0].from;if(n>=1)return t[t.length-1].to;let r=Math.floor(e*n);for(let e=0;;e++){let{from:n,to:i}=t[e],s=i-n;if(r<=s)return n+r;r-=s}}function t9(e,t){let n=0;for(let{from:r,to:i}of e.ranges){if(t<=i){n+=t-r;break}n+=i-r}return n/e.total}let t7={toDOM:e=>e,fromDOM:e=>e,scale:1};class ne{constructor(e,t,n){let r=0,i=0,s=0;for(let o of(this.viewports=n.map(({from:n,to:i})=>{let s=t.lineAt(n,tK.ByPos,e,0,0).top,o=t.lineAt(i,tK.ByPos,e,0,0).bottom;return r+=o-s,{from:n,to:i,top:s,bottom:o,domTop:0,domBottom:0}}),this.scale=(7e6-r)/(t.height-r),this.viewports))o.domTop=s+(o.top-i)*this.scale,s=o.domBottom=o.domTop+(o.bottom-o.top),i=o.bottom}toDOM(e){for(let t=0,n=0,r=0;;t++){let i=t<this.viewports.length?this.viewports[t]:null;if(!i||e<i.top)return r+(e-n)*this.scale;if(e<=i.bottom)return i.domTop+(e-i.top);n=i.bottom,r=i.domBottom}}fromDOM(e){for(let t=0,n=0,r=0;;t++){let i=t<this.viewports.length?this.viewports[t]:null;if(!i||e<i.domTop)return n+(e-r)/this.scale;if(e<=i.domBottom)return i.top+(e-i.domTop);n=i.bottom,r=i.domBottom}}}function nt(e,t){if(1==t.scale)return e;let n=t.toDOM(e.top),r=t.toDOM(e.bottom);return new tG(e.from,e.length,n,r-n,Array.isArray(e._content)?e._content.map(e=>nt(e,t)):e._content)}let nn=l.r$.define({combine:e=>e.join(" ")}),nr=l.r$.define({combine:e=>e.indexOf(!0)>-1}),ni=a.V.newName(),ns=a.V.newName(),no=a.V.newName(),nl={"&light":"."+ns,"&dark":"."+no};function na(e,t,n){return new a.V(t,{finish:t=>/&/.test(t)?t.replace(/&\w*/,t=>{if("&"==t)return e;if(!n||!n[t])throw RangeError(`Unsupported selector: ${t}`);return n[t]}):e+" "+t})}let nu=na("."+ni,{"&":{position:"relative !important",boxSizing:"border-box","&.cm-focused":{outline:"1px dotted #212121"},display:"flex !important",flexDirection:"column"},".cm-scroller":{display:"flex !important",alignItems:"flex-start !important",fontFamily:"monospace",lineHeight:1.4,height:"100%",overflowX:"auto",position:"relative",zIndex:0},".cm-content":{margin:0,flexGrow:2,flexShrink:0,display:"block",whiteSpace:"pre",wordWrap:"normal",boxSizing:"border-box",minHeight:"100%",padding:"4px 0",outline:"none","&[contenteditable=true]":{WebkitUserModify:"read-write-plaintext-only"}},".cm-lineWrapping":{whiteSpace_fallback:"pre-wrap",whiteSpace:"break-spaces",wordBreak:"break-word",overflowWrap:"anywhere",flexShrink:1},"&light .cm-content":{caretColor:"black"},"&dark .cm-content":{caretColor:"white"},".cm-line":{display:"block",padding:"0 2px 0 6px"},".cm-layer":{position:"absolute",left:0,top:0,contain:"size style","& > *":{position:"absolute"}},"&light .cm-selectionBackground":{background:"#d9d9d9"},"&dark .cm-selectionBackground":{background:"#222"},"&light.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#d7d4f0"},"&dark.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#233"},".cm-cursorLayer":{pointerEvents:"none"},"&.cm-focused > .cm-scroller > .cm-cursorLayer":{animation:"steps(1) cm-blink 1.2s infinite"},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{borderLeft:"1.2px solid black",marginLeft:"-0.6px",pointerEvents:"none"},".cm-cursor":{display:"none"},"&dark .cm-cursor":{borderLeftColor:"#444"},".cm-dropCursor":{position:"absolute"},"&.cm-focused > .cm-scroller > .cm-cursorLayer .cm-cursor":{display:"block"},".cm-iso":{unicodeBidi:"isolate"},".cm-announced":{position:"fixed",top:"-10000px"},"@media print":{".cm-announced":{display:"none"}},"&light .cm-activeLine":{backgroundColor:"#cceeff44"},"&dark .cm-activeLine":{backgroundColor:"#99eeff33"},"&light .cm-specialChar":{color:"red"},"&dark .cm-specialChar":{color:"#f78"},".cm-gutters":{flexShrink:0,display:"flex",height:"100%",boxSizing:"border-box",insetInlineStart:0,zIndex:200},"&light .cm-gutters":{backgroundColor:"#f5f5f5",color:"#6c6c6c",borderRight:"1px solid #ddd"},"&dark .cm-gutters":{backgroundColor:"#333338",color:"#ccc"},".cm-gutter":{display:"flex !important",flexDirection:"column",flexShrink:0,boxSizing:"border-box",minHeight:"100%",overflow:"hidden"},".cm-gutterElement":{boxSizing:"border-box"},".cm-lineNumbers .cm-gutterElement":{padding:"0 3px 0 5px",minWidth:"20px",textAlign:"right",whiteSpace:"nowrap"},"&light .cm-activeLineGutter":{backgroundColor:"#e2f2ff"},"&dark .cm-activeLineGutter":{backgroundColor:"#222227"},".cm-panels":{boxSizing:"border-box",position:"sticky",left:0,right:0},"&light .cm-panels":{backgroundColor:"#f5f5f5",color:"black"},"&light .cm-panels-top":{borderBottom:"1px solid #ddd"},"&light .cm-panels-bottom":{borderTop:"1px solid #ddd"},"&dark .cm-panels":{backgroundColor:"#333338",color:"white"},".cm-tab":{display:"inline-block",overflow:"hidden",verticalAlign:"bottom"},".cm-widgetBuffer":{verticalAlign:"text-top",height:"1em",width:0,display:"inline"},".cm-placeholder":{color:"#888",display:"inline-block",verticalAlign:"top"},".cm-highlightSpace:before":{content:"attr(data-display)",position:"absolute",pointerEvents:"none",color:"#888"},".cm-highlightTab":{backgroundImage:'url(\'data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="200" height="20"><path stroke="%23888" stroke-width="1" fill="none" d="M1 10H196L190 5M190 15L196 10M197 4L197 16"/></svg>\')',backgroundSize:"auto 100%",backgroundPosition:"right 90%",backgroundRepeat:"no-repeat"},".cm-trailingSpace":{backgroundColor:"#ff332255"},".cm-button":{verticalAlign:"middle",color:"inherit",fontSize:"70%",padding:".2em 1em",borderRadius:"1px"},"&light .cm-button":{backgroundImage:"linear-gradient(#eff1f5, #d9d9df)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#b4b4b4, #d0d3d6)"}},"&dark .cm-button":{backgroundImage:"linear-gradient(#393939, #111)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#111, #333)"}},".cm-textfield":{verticalAlign:"middle",color:"inherit",fontSize:"70%",border:"1px solid silver",padding:".2em .5em"},"&light .cm-textfield":{backgroundColor:"white"},"&dark .cm-textfield":{border:"1px solid #555",backgroundColor:"inherit"}},nl);class nh{constructor(e,t){this.points=e,this.text="",this.lineSeparator=t.facet(l.yy.lineSeparator)}append(e){this.text+=e}lineBreak(){this.text+=""}readRange(e,t){if(!e)return this;let n=e.parentNode;for(let r=e;;){this.findPointBefore(n,r);let e=this.text.length;this.readNode(r);let i=r.nextSibling;if(i==t)break;let s=$.get(r),o=$.get(i);(s&&o?s.breakAfter:(s?s.breakAfter:w(r))||w(i)&&("BR"!=r.nodeName||r.cmIgnore)&&this.text.length>e)&&this.lineBreak(),r=i}return this.findPointBefore(n,t),this}readTextNode(e){let t=e.nodeValue;for(let n of this.points)n.node==e&&(n.pos=this.text.length+Math.min(n.offset,t.length));for(let n=0,r=this.lineSeparator?null:/\r\n?|\n/g;;){let i=-1,s=1,o;if(this.lineSeparator?(i=t.indexOf(this.lineSeparator,n),s=this.lineSeparator.length):(o=r.exec(t))&&(i=o.index,s=o[0].length),this.append(t.slice(n,i<0?t.length:i)),i<0)break;if(this.lineBreak(),s>1)for(let t of this.points)t.node==e&&t.pos>this.text.length&&(t.pos-=s-1);n=i+s}}readNode(e){if(e.cmIgnore)return;let t=$.get(e),n=t&&t.overrideDOMText;if(null!=n){this.findPointInside(e,n.length);for(let e=n.iter();!e.next().done;)e.lineBreak?this.lineBreak():this.append(e.value)}else 3==e.nodeType?this.readTextNode(e):"BR"==e.nodeName?e.nextSibling&&this.lineBreak():1==e.nodeType&&this.readRange(e.firstChild,null)}findPointBefore(e,t){for(let n of this.points)n.node==e&&e.childNodes[n.offset]==t&&(n.pos=this.text.length)}findPointInside(e,t){for(let n of this.points)(3==e.nodeType?n.node==e:e.contains(n.node))&&(n.pos=this.text.length+(function(e,t,n){for(;;){if(!t||n<A(t))return!1;if(t==e)return!0;n=k(t)+1,t=t.parentNode}}(e,n.node,n.offset)?t:0))}}class nc{constructor(e,t){this.node=e,this.offset=t,this.pos=-1}}class nf{constructor(e,t,n,r){this.typeOver=r,this.bounds=null,this.text="";let{impreciseHead:i,impreciseAnchor:s}=e.docView;if(e.state.readOnly&&t>-1)this.newSel=null;else if(t>-1&&(this.bounds=e.docView.domBoundsAround(t,n,0))){let t=i||s?[]:function(e){let t=[];if(e.root.activeElement!=e.contentDOM)return t;let{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:s}=e.observer.selectionRange;return n&&(t.push(new nc(n,r)),(i!=n||s!=r)&&t.push(new nc(i,s))),t}(e),n=new nh(t,e.state);n.readRange(this.bounds.startDOM,this.bounds.endDOM),this.text=n.text,this.newSel=function(e,t){if(0==e.length)return null;let n=e[0].pos,r=2==e.length?e[1].pos:n;return n>-1&&r>-1?l.jT.single(n+t,r+t):null}(t,this.bounds.from)}else{let t=e.observer.selectionRange,n=i&&i.node==t.focusNode&&i.offset==t.focusOffset||!g(e.contentDOM,t.focusNode)?e.state.selection.main.head:e.docView.posFromDOM(t.focusNode,t.focusOffset),r=s&&s.node==t.anchorNode&&s.offset==t.anchorOffset||!g(e.contentDOM,t.anchorNode)?e.state.selection.main.anchor:e.docView.posFromDOM(t.anchorNode,t.anchorOffset),o=e.viewport;if((X.ios||X.chrome)&&e.state.selection.main.empty&&n!=r&&(o.from>0||o.to<e.state.doc.length)){let t=Math.min(n,r),i=Math.max(n,r),s=o.from-t,l=o.to-i;(0==s||1==s||0==t)&&(0==l||-1==l||i==e.state.doc.length)&&(n=0,r=e.state.doc.length)}this.newSel=l.jT.single(r,n)}}}function nd(e,t){let n;let{newSel:r}=t,i=e.state.selection.main,s=e.inputState.lastKeyTime>Date.now()-100?e.inputState.lastKeyCode:-1;if(t.bounds){let{from:r,to:o}=t.bounds,a=i.from,u=null;(8===s||X.android&&t.text.length<o-r)&&(a=i.to,u="end");let h=function(e,t,n,r){let i=Math.min(e.length,t.length),s=0;for(;s<i&&e.charCodeAt(s)==t.charCodeAt(s);)s++;if(s==i&&e.length==t.length)return null;let o=e.length,l=t.length;for(;o>0&&l>0&&e.charCodeAt(o-1)==t.charCodeAt(l-1);)o--,l--;if("end"==r){let e=Math.max(0,s-Math.min(o,l));n-=o+e-s}if(o<s&&e.length<t.length){let e=n<=s&&n>=o?s-n:0;s-=e,l=s+(l-o),o=s}else if(l<s){let e=n<=s&&n>=l?s-n:0;s-=e,o=s+(o-l),l=s}return{from:s,toA:o,toB:l}}(e.state.doc.sliceString(r,o,""),t.text,a-r,u);h&&(X.chrome&&13==s&&h.toB==h.from+2&&""==t.text.slice(h.from,h.toB)&&h.toB--,n={from:r+h.from,to:r+h.toA,insert:l.xv.of(t.text.slice(h.from,h.toB).split(""))})}else r&&(!e.hasFocus&&e.state.facet(eY)||r.main.eq(i))&&(r=null);if(!n&&!r)return!1;if(!n&&t.typeOver&&!i.empty&&r&&r.main.empty?n={from:i.from,to:i.to,insert:e.state.doc.slice(i.from,i.to)}:n&&n.from>=i.from&&n.to<=i.to&&(n.from!=i.from||n.to!=i.to)&&i.to-i.from-(n.to-n.from)<=4?n={from:i.from,to:i.to,insert:e.state.doc.slice(i.from,n.from).append(n.insert).append(e.state.doc.slice(n.to,i.to))}:(X.mac||X.android)&&n&&n.from==n.to&&n.from==i.head-1&&/^\. ?$/.test(n.insert.toString())&&"off"==e.contentDOM.getAttribute("autocorrect")?(r&&2==n.insert.length&&(r=l.jT.single(r.main.anchor-1,r.main.head-1)),n={from:i.from,to:i.to,insert:l.xv.of([" "])}):X.chrome&&n&&n.from==n.to&&n.from==i.head&&"\n "==n.insert.toString()&&e.lineWrapping&&(r&&(r=l.jT.single(r.main.anchor-1,r.main.head-1)),n={from:i.from,to:i.to,insert:l.xv.of([" "])}),n){let t;if(X.ios&&e.inputState.flushIOSKey(n)||X.android&&(n.to==i.to&&(n.from==i.from||n.from==i.from-1&&" "==e.state.sliceDoc(n.from,i.from))&&1==n.insert.length&&2==n.insert.lines&&F(e.contentDOM,"Enter",13)||(n.from==i.from-1&&n.to==i.to&&0==n.insert.length||8==s&&n.insert.length<n.to-n.from&&n.to>i.head)&&F(e.contentDOM,"Backspace",8)||n.from==i.from&&n.to==i.to+1&&0==n.insert.length&&F(e.contentDOM,"Delete",46)))return!0;let o=n.insert.toString();e.inputState.composing>=0&&e.inputState.composing++;let a=()=>t||(t=function(e,t,n){let r,i=e.state,s=i.selection.main;if(t.from>=s.from&&t.to<=s.to&&t.to-t.from>=(s.to-s.from)/3&&(!n||n.main.empty&&n.main.from==t.from+t.insert.length)&&e.inputState.composing<0){let n=s.from<t.from?i.sliceDoc(s.from,t.from):"",o=s.to>t.to?i.sliceDoc(t.to,s.to):"";r=i.replaceSelection(e.state.toText(n+t.insert.sliceString(0,void 0,e.state.lineBreak)+o))}else{let o=i.changes(t),a=n&&n.main.to<=o.newLength?n.main:void 0;if(i.selection.ranges.length>1&&e.inputState.composing>=0&&t.to<=s.to&&t.to>=s.to-10){let u=e.state.sliceDoc(t.from,t.to),h,c=n&&to(e,n.main.head);if(c){let e=t.insert.length-(t.to-t.from);h={from:c.from,to:c.to-e}}else h=e.state.doc.lineAt(s.head);let f=s.to-t.to,d=s.to-s.from;r=i.changeByRange(n=>{if(n.from==s.from&&n.to==s.to)return{changes:o,range:a||n.map(o)};let r=n.to-f,c=r-u.length;if(n.to-n.from!=d||e.state.sliceDoc(c,r)!=u||n.to>=h.from&&n.from<=h.to)return{range:n};let p=i.changes({from:c,to:r,insert:t.insert}),m=n.to-s.to;return{changes:p,range:a?l.jT.range(Math.max(0,a.anchor+m),Math.max(0,a.head+m)):n.map(p)}})}else r={changes:o,selection:a&&i.selection.replaceRange(a)}}let o="input.type";return(e.composing||e.inputState.compositionPendingChange&&e.inputState.compositionEndedAt>Date.now()-50)&&(e.inputState.compositionPendingChange=!1,o+=".compose",e.inputState.compositionFirstChange&&(o+=".start",e.inputState.compositionFirstChange=!1)),i.update(r,{userEvent:o,scrollIntoView:!0})}(e,n,r));return!e.state.facet(ez).some(t=>t(e,n.from,n.to,o,a))&&e.dispatch(a()),!0}if(!r||r.main.eq(i))return!1;{let t=!1,n="select";return e.inputState.lastSelectionTime>Date.now()-50&&("select"==e.inputState.lastSelectionOrigin&&(t=!0),n=e.inputState.lastSelectionOrigin),e.dispatch({selection:r,scrollIntoView:t,userEvent:n}),!0}}let np={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},nm=X.ie&&X.ie_version<=11;class ng{constructor(e){this.view=e,this.active=!1,this.selectionRange=new E,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.flushingAndroidKey=-1,this.lastChange=0,this.scrollTargets=[],this.intersection=null,this.resizeScroll=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.printQuery=null,this.parentCheck=-1,this.dom=e.contentDOM,this.observer=new MutationObserver(t=>{for(let e of t)this.queue.push(e);(X.ie&&X.ie_version<=11||X.ios&&e.composing)&&t.some(e=>"childList"==e.type&&e.removedNodes.length||"characterData"==e.type&&e.oldValue.length>e.target.nodeValue.length)?this.flushSoon():this.flush()}),nm&&(this.onCharData=e=>{this.queue.push({target:e.target,type:"characterData",oldValue:e.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.onResize=this.onResize.bind(this),this.onPrint=this.onPrint.bind(this),this.onScroll=this.onScroll.bind(this),window.matchMedia&&(this.printQuery=window.matchMedia("print")),"function"==typeof ResizeObserver&&(this.resizeScroll=new ResizeObserver(()=>{var e;(null===(e=this.view.docView)||void 0===e?void 0:e.lastUpdate)<Date.now()-75&&this.onResize()}),this.resizeScroll.observe(e.scrollDOM)),this.addWindowListeners(this.win=e.win),this.start(),"function"==typeof IntersectionObserver&&(this.intersection=new IntersectionObserver(e=>{this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),e.length>0&&e[e.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent("Event")))},{threshold:[0,.001]}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(e=>{e.length>0&&e[e.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent("Event"))},{})),this.listenForScroll(),this.readSelectionRange()}onScrollChanged(e){this.view.inputState.runHandlers("scroll",e),this.intersecting&&this.view.measure()}onScroll(e){this.intersecting&&this.flush(!1),this.onScrollChanged(e)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(e){("change"!=e.type||e.matches)&&(this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500))}updateGaps(e){if(this.gapIntersection&&(e.length!=this.gaps.length||this.gaps.some((t,n)=>t!=e[n]))){for(let t of(this.gapIntersection.disconnect(),e))this.gapIntersection.observe(t);this.gaps=e}}onSelectionChange(e){let t=this.selectionChanged;if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:n}=this,r=this.selectionRange;if(n.state.facet(eY)?n.root.activeElement!=this.dom:!y(n.dom,r))return;let i=r.anchorNode&&n.docView.nearest(r.anchorNode);if(i&&i.ignoreEvent(e)){!t&&(this.selectionChanged=!1);return}(X.ie&&X.ie_version<=11||X.android&&X.chrome)&&!n.state.selection.main.empty&&r.focusNode&&v(r.focusNode,r.focusOffset,r.anchorNode,r.anchorOffset)?this.flushSoon():this.flush(!1)}readSelectionRange(){let{view:e}=this,t=m(e.root);if(!t)return!1;let n=X.safari&&11==e.root.nodeType&&function(e){let t=e.activeElement;for(;t&&t.shadowRoot;)t=t.shadowRoot.activeElement;return t}(this.dom.ownerDocument)==this.dom&&function(e,t){if(t.getComposedRanges){let n=t.getComposedRanges(e.root)[0];if(n)return nb(e,n)}let n=null;function r(e){e.preventDefault(),e.stopImmediatePropagation(),n=e.getTargetRanges()[0]}return e.contentDOM.addEventListener("beforeinput",r,!0),e.dom.ownerDocument.execCommand("indent"),e.contentDOM.removeEventListener("beforeinput",r,!0),n?nb(e,n):null}(this.view,t)||t;if(!n||this.selectionRange.eq(n))return!1;let r=y(this.dom,n);return r&&!this.selectionChanged&&e.inputState.lastFocusTime>Date.now()-200&&e.inputState.lastTouchTime<Date.now()-300&&function(e,t){let n=t.focusNode,r=t.focusOffset;if(!n||t.anchorNode!=n||t.anchorOffset!=r)return!1;for(r=Math.min(r,A(n));;)if(r){if(1!=n.nodeType)return!1;let e=n.childNodes[r-1];"false"==e.contentEditable?r--:r=A(n=e)}else{if(n==e)return!0;r=k(n),n=n.parentNode}}(this.dom,n)?(this.view.inputState.lastFocusTime=0,e.docView.updateSelection(),!1):(this.selectionRange.setRange(n),r&&(this.selectionChanged=!0),!0)}setSelectionRange(e,t){this.selectionRange.set(e.node,e.offset,t.node,t.offset),this.selectionChanged=!1}clearSelectionRange(){this.selectionRange.set(null,0,null,0)}listenForScroll(){this.parentCheck=-1;let e=0,t=null;for(let n=this.dom;n;)if(1==n.nodeType)!t&&e<this.scrollTargets.length&&this.scrollTargets[e]==n?e++:!t&&(t=this.scrollTargets.slice(0,e)),t&&t.push(n),n=n.assignedSlot||n.parentNode;else if(11==n.nodeType)n=n.host;else break;if(e<this.scrollTargets.length&&!t&&(t=this.scrollTargets.slice(0,e)),t){for(let e of this.scrollTargets)e.removeEventListener("scroll",this.onScroll);for(let e of this.scrollTargets=t)e.addEventListener("scroll",this.onScroll)}}ignore(e){if(!this.active)return e();try{return this.stop(),e()}finally{this.start(),this.clear()}}start(){!this.active&&(this.observer.observe(this.dom,np),nm&&this.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.active=!0)}stop(){this.active&&(this.active=!1,this.observer.disconnect(),nm&&this.dom.removeEventListener("DOMCharacterDataModified",this.onCharData))}clear(){this.processRecords(),this.queue.length=0,this.selectionChanged=!1}delayAndroidKey(e,t){var n;!this.delayedAndroidKey&&(this.flushingAndroidKey=this.view.win.requestAnimationFrame(()=>{let e=this.delayedAndroidKey;e&&(this.clearDelayedAndroidKey(),this.view.inputState.lastKeyCode=e.keyCode,this.view.inputState.lastKeyTime=Date.now(),!this.flush()&&e.force&&F(this.dom,e.key,e.keyCode))})),(!this.delayedAndroidKey||"Enter"==e)&&(this.delayedAndroidKey={key:e,keyCode:t,force:this.lastChange<Date.now()-50||!!(null===(n=this.delayedAndroidKey)||void 0===n?void 0:n.force)})}clearDelayedAndroidKey(){this.win.cancelAnimationFrame(this.flushingAndroidKey),this.delayedAndroidKey=null,this.flushingAndroidKey=-1}flushSoon(){this.delayedFlush<0&&(this.delayedFlush=this.view.win.requestAnimationFrame(()=>{this.delayedFlush=-1,this.flush()}))}forceFlush(){this.delayedFlush>=0&&(this.view.win.cancelAnimationFrame(this.delayedFlush),this.delayedFlush=-1),this.flush()}pendingRecords(){for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}processRecords(){let e=this.pendingRecords();e.length&&(this.queue=[]);let t=-1,n=-1,r=!1;for(let i of e){let e=this.readMutation(i);e&&(e.typeOver&&(r=!0),-1==t?{from:t,to:n}=e:(t=Math.min(e.from,t),n=Math.max(e.to,n)))}return{from:t,to:n,typeOver:r}}readChange(){let{from:e,to:t,typeOver:n}=this.processRecords(),r=this.selectionChanged&&y(this.dom,this.selectionRange);if(e<0&&!r)return null;e>-1&&(this.lastChange=Date.now()),this.view.inputState.lastFocusTime=0,this.selectionChanged=!1;let i=new nf(this.view,e,t,n);return this.view.docView.domChanged={newSel:i.newSel?i.newSel.main:null},i}flush(e=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return!1;e&&this.readSelectionRange();let t=this.readChange();if(!t)return this.view.requestMeasure(),!1;let n=this.view.state,r=nd(this.view,t);return this.view.state==n&&this.view.update([]),r}readMutation(e){let t=this.view.docView.nearest(e.target);if(!t||t.ignoreMutation(e))return null;if(t.markDirty("attributes"==e.type),"attributes"==e.type&&(t.flags|=4),"childList"==e.type){let n=ny(t,e.previousSibling||e.target.previousSibling,-1),r=ny(t,e.nextSibling||e.target.nextSibling,1);return{from:n?t.posAfter(n):t.posAtStart,to:r?t.posBefore(r):t.posAtEnd,typeOver:!1}}if("characterData"==e.type)return{from:t.posAtStart,to:t.posAtEnd,typeOver:e.target.nodeValue==e.oldValue};return null}setWindow(e){e!=this.win&&(this.removeWindowListeners(this.win),this.win=e,this.addWindowListeners(this.win))}addWindowListeners(e){e.addEventListener("resize",this.onResize),this.printQuery?this.printQuery.addEventListener("change",this.onPrint):e.addEventListener("beforeprint",this.onPrint),e.addEventListener("scroll",this.onScroll),e.document.addEventListener("selectionchange",this.onSelectionChange)}removeWindowListeners(e){e.removeEventListener("scroll",this.onScroll),e.removeEventListener("resize",this.onResize),this.printQuery?this.printQuery.removeEventListener("change",this.onPrint):e.removeEventListener("beforeprint",this.onPrint),e.document.removeEventListener("selectionchange",this.onSelectionChange)}destroy(){var e,t,n;for(let r of(this.stop(),null===(e=this.intersection)||void 0===e||e.disconnect(),null===(t=this.gapIntersection)||void 0===t||t.disconnect(),null===(n=this.resizeScroll)||void 0===n||n.disconnect(),this.scrollTargets))r.removeEventListener("scroll",this.onScroll);this.removeWindowListeners(this.win),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout),this.win.cancelAnimationFrame(this.delayedFlush),this.win.cancelAnimationFrame(this.flushingAndroidKey)}}function ny(e,t,n){for(;t;){let r=$.get(t);if(r&&r.parent==e)return r;let i=t.parentNode;t=i!=e.dom?i:n>0?t.nextSibling:t.previousSibling}return null}function nb(e,t){let n=t.startContainer,r=t.startOffset,i=t.endContainer,s=t.endOffset,o=e.docView.domAtPos(e.state.selection.main.anchor);return v(o.node,o.offset,i,s)&&([n,r,i,s]=[i,s,n,r]),{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:s}}class nv{get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return this.inputState.composing>0}get compositionStarted(){return this.inputState.composing>=0}get root(){return this._root}get win(){return this.dom.ownerDocument.defaultView||window}constructor(e={}){this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.contentDOM=document.createElement("div"),this.scrollDOM=document.createElement("div"),this.scrollDOM.tabIndex=-1,this.scrollDOM.className="cm-scroller",this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement("div"),this.announceDOM.className="cm-announced",this.announceDOM.setAttribute("aria-live","polite"),this.dom=document.createElement("div"),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),e.parent&&e.parent.appendChild(this.dom);let{dispatch:t}=e;for(let n of(this.dispatchTransactions=e.dispatchTransactions||t&&(e=>e.forEach(e=>t(e,this)))||(e=>this.update(e)),this.dispatch=this.dispatch.bind(this),this._root=e.root||function(e){for(;e;){if(e&&(9==e.nodeType||11==e.nodeType&&e.host))return e;e=e.assignedSlot||e.parentNode}return null}(e.parent)||document,this.viewState=new t8(e.state||l.yy.create(e)),e.scrollTo&&e.scrollTo.is(eJ)&&(this.viewState.scrollTarget=e.scrollTo.value.clip(this.viewState.state)),this.plugins=this.state.facet(eX).map(e=>new e1(e)),this.plugins))n.update(this);this.observer=new ng(this),this.inputState=new tb(this),this.inputState.ensureHandlers(this.plugins),this.docView=new ti(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure()}dispatch(...e){let t=1==e.length&&e[0]instanceof l.YW?e:1==e.length&&Array.isArray(e[0])?e[0]:[this.state.update(...e)];this.dispatchTransactions(t,this)}update(e){if(0!=this.updateState)throw Error("Calls to EditorView.update are not allowed while an update is in progress");let t=!1,n=!1,r,i=this.state;for(let t of e){if(t.startState!=i)throw RangeError("Trying to update state with a transaction that doesn't start from the previous state.");i=t.state}if(this.destroyed){this.viewState.state=i;return}let s=this.hasFocus,o=0,a=null;e.some(e=>e.annotation(tj))?(this.inputState.notifiedFocused=s,o=1):s!=this.inputState.notifiedFocused&&(this.inputState.notifiedFocused=s,!(a=tq(i,s))&&(o=1));let u=this.observer.delayedAndroidKey,h=null;if(u?(this.observer.clearDelayedAndroidKey(),((h=this.observer.readChange())&&!this.state.doc.eq(i.doc)||!this.state.selection.eq(i.selection))&&(h=null)):this.observer.clear(),i.facet(l.yy.phrases)!=this.state.facet(l.yy.phrases))return this.setState(i);r=tr.create(this,i,e),r.flags|=o;let c=this.viewState.scrollTarget;try{for(let t of(this.updateState=2,e)){if(c&&(c=c.map(t.changes)),t.scrollIntoView){let{main:e}=t.state.selection;c=new eK(e.empty?e:l.jT.cursor(e.head,e.head>e.anchor?-1:1))}for(let e of t.effects)e.is(eJ)&&(c=e.value.clip(this.state))}this.viewState.update(r,c),this.bidiCache=nD.update(this.bidiCache,r.changes),!r.empty&&(this.updatePlugins(r),this.inputState.update(r)),t=this.docView.update(r),this.state.facet(tt)!=this.styleModules&&this.mountStyles(),n=this.updateAttrs(),this.showAnnouncements(e),this.docView.updateSelection(t,e.some(e=>e.isUserEvent("select.pointer")))}finally{this.updateState=0}if(r.startState.facet(nn)!=r.state.facet(nn)&&(this.viewState.mustMeasureContent=!0),(t||n||c||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),t&&this.docViewUpdate(),!r.empty)for(let e of this.state.facet(eV))try{e(r)}catch(e){eQ(this.state,e,"update listener")}(a||h)&&Promise.resolve().then(()=>{a&&this.state==a.startState&&this.dispatch(a),h&&!nd(this,h)&&u.force&&F(this.contentDOM,u.key,u.keyCode)})}setState(e){if(0!=this.updateState)throw Error("Calls to EditorView.setState are not allowed while an update is in progress");if(this.destroyed){this.viewState.state=e;return}this.updateState=2;let t=this.hasFocus;try{for(let e of this.plugins)e.destroy(this);for(let t of(this.viewState=new t8(e),this.plugins=e.facet(eX).map(e=>new e1(e)),this.pluginMap.clear(),this.plugins))t.update(this);this.docView.destroy(),this.docView=new ti(this),this.inputState.ensureHandlers(this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}t&&this.focus(),this.requestMeasure()}updatePlugins(e){let t=e.startState.facet(eX),n=e.state.facet(eX);if(t!=n){let r=[];for(let i of n){let n=t.indexOf(i);if(n<0)r.push(new e1(i));else{let t=this.plugins[n];t.mustUpdate=e,r.push(t)}}for(let t of this.plugins)t.mustUpdate!=e&&t.destroy(this);this.plugins=r,this.pluginMap.clear()}else for(let t of this.plugins)t.mustUpdate=e;for(let e=0;e<this.plugins.length;e++)this.plugins[e].update(this);t!=n&&this.inputState.ensureHandlers(this.plugins)}docViewUpdate(){for(let e of this.plugins){let t=e.value;if(t&&t.docViewUpdate)try{t.docViewUpdate(this)}catch(e){eQ(this.state,e,"doc view update listener")}}}measure(e=!0){if(this.destroyed)return;if(this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.observer.delayedAndroidKey){this.measureScheduled=-1,this.requestMeasure();return}this.measureScheduled=0,e&&this.observer.forceFlush();let t=null,n=this.scrollDOM,r=n.scrollTop*this.scaleY,{scrollAnchorPos:i,scrollAnchorHeight:s}=this.viewState;Math.abs(r-this.viewState.scrollTop)>1&&(s=-1),this.viewState.scrollAnchorHeight=-1;try{for(let e=0;;e++){if(s<0){if(T(n))i=-1,s=this.viewState.heightMap.height;else{let e=this.viewState.scrollAnchorAt(r);i=e.from,s=e.top}}this.updateState=1;let o=this.viewState.measure(this);if(!o&&!this.measureRequests.length&&null==this.viewState.scrollTarget)break;if(e>5){console.warn(this.measureRequests.length?"Measure loop restarted more than 5 times":"Viewport failed to stabilize");break}let l=[];!(4&o)&&([this.measureRequests,l]=[l,this.measureRequests]);let a=l.map(e=>{try{return e.read(this)}catch(e){return eQ(this.state,e),nw}}),u=tr.create(this,this.state,[]),h=!1;u.flags|=o,t?t.flags|=o:t=u,this.updateState=2,!u.empty&&(this.updatePlugins(u),this.inputState.update(u),this.updateAttrs(),(h=this.docView.update(u))&&this.docViewUpdate());for(let e=0;e<l.length;e++)if(a[e]!=nw)try{let t=l[e];t.write&&t.write(a[e],this)}catch(e){eQ(this.state,e)}if(h&&this.docView.updateSelection(!0),!u.viewportChanged&&0==this.measureRequests.length){if(this.viewState.editorHeight){if(this.viewState.scrollTarget){this.docView.scrollIntoView(this.viewState.scrollTarget),this.viewState.scrollTarget=null,s=-1;continue}{let e=(i<0?this.viewState.heightMap.height:this.viewState.lineBlockAt(i).top)-s;if(e>1||e<-1){r+=e,n.scrollTop=r/this.scaleY,s=-1;continue}}}break}}}finally{this.updateState=0,this.measureScheduled=-1}if(t&&!t.empty)for(let e of this.state.facet(eV))e(t)}get themeClasses(){return ni+" "+(this.state.facet(nr)?no:ns)+" "+this.state.facet(nn)}updateAttrs(){let e=nA(this,e2,{class:"cm-editor"+(this.hasFocus?" cm-focused ":" ")+this.themeClasses}),t={spellcheck:"false",autocorrect:"off",autocapitalize:"off",translate:"no",contenteditable:this.state.facet(eY)?"true":"false",class:"cm-content",style:`${X.tabSize}: ${this.state.tabSize}`,role:"textbox","aria-multiline":"true"};this.state.readOnly&&(t["aria-readonly"]="true"),nA(this,e3,t);let n=this.observer.ignore(()=>{let n=eu(this.contentDOM,this.contentAttrs,t),r=eu(this.dom,this.editorAttrs,e);return n||r});return this.editorAttrs=e,this.contentAttrs=t,n}showAnnouncements(e){let t=!0;for(let n of e)for(let e of n.effects)e.is(nv.announce)&&(t&&(this.announceDOM.textContent=""),t=!1,this.announceDOM.appendChild(document.createElement("div")).textContent=e.value)}mountStyles(){this.styleModules=this.state.facet(tt);let e=this.state.facet(nv.cspNonce);a.V.mount(this.root,this.styleModules.concat(nu).reverse(),e?{nonce:e}:void 0)}readMeasured(){if(2==this.updateState)throw Error("Reading the editor layout isn't allowed during an update");0==this.updateState&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(e){if(this.measureScheduled<0&&(this.measureScheduled=this.win.requestAnimationFrame(()=>this.measure())),e){if(!(this.measureRequests.indexOf(e)>-1)){if(null!=e.key){for(let t=0;t<this.measureRequests.length;t++)if(this.measureRequests[t].key===e.key){this.measureRequests[t]=e;return}}this.measureRequests.push(e)}}}plugin(e){let t=this.pluginMap.get(e);return(void 0===t||t&&t.spec!=e)&&this.pluginMap.set(e,t=this.plugins.find(t=>t.spec==e)||null),t&&t.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}get scaleX(){return this.viewState.scaleX}get scaleY(){return this.viewState.scaleY}elementAtHeight(e){return this.readMeasured(),this.viewState.elementAtHeight(e)}lineBlockAtHeight(e){return this.readMeasured(),this.viewState.lineBlockAtHeight(e)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(e){return this.viewState.lineBlockAt(e)}get contentHeight(){return this.viewState.contentHeight}moveByChar(e,t,n){return ty(this,e,tm(this,e,t,n))}moveByGroup(e,t){return ty(this,e,tm(this,e,t,t=>{var n,r,i;let s,o;return n=this,r=e.head,i=t,o=(s=n.state.charCategorizer(r))(i),e=>{let t=s(e);return o==l.D0.Space&&(o=t),o==t}}))}visualLineSide(e,t){let n=this.bidiSpans(e),r=this.textDirectionAt(e.from),i=n[t?n.length-1:0];return l.jT.cursor(i.side(t,r)+e.from,i.forward(!t,r)?1:-1)}moveToLineBoundary(e,t,n=!0){return function(e,t,n,r){let i=tp(e,t.head),s=r&&i.type==ed.Text&&(e.lineWrapping||i.widgetLineBreaks)?e.coordsAtPos(t.assoc<0&&t.head>i.from?t.head-1:t.head):null;if(s){let t=e.dom.getBoundingClientRect(),r=e.textDirectionAt(i.from),o=e.posAtCoords({x:n==(r==eA.LTR)?t.right-1:t.left+1,y:(s.top+s.bottom)/2});if(null!=o)return l.jT.cursor(o,n?-1:1)}return l.jT.cursor(n?i.to:i.from,n?-1:1)}(this,e,t,n)}moveVertically(e,t,n){return ty(this,e,function(e,t,n,r){let i=t.head,s=n?1:-1;if(i==(n?e.state.doc.length:0))return l.jT.cursor(i,t.assoc);let o=t.goalColumn,a,u=e.contentDOM.getBoundingClientRect(),h=e.coordsAtPos(i,t.assoc||-1),c=e.documentTop;if(h)null==o&&(o=h.left-u.left),a=s<0?h.top:h.bottom;else{let t=e.viewState.lineBlockAt(i);null==o&&(o=Math.min(u.right-u.left,e.defaultCharacterWidth*(i-t.from))),a=(s<0?t.top:t.bottom)+c}let f=u.left+o,d=null!=r?r:e.viewState.heightOracle.textHeight>>1;for(let t=0;;t+=10){let n=a+(d+t)*s,r=tf(e,{x:f,y:n},!1,s);if(n<u.top||n>u.bottom||(s<0?r<i:r>i)){let t=e.docView.coordsForChar(r),i=!t||n<t.top?-1:1;return l.jT.cursor(r,i,void 0,o)}}}(this,e,t,n))}domAtPos(e){return this.docView.domAtPos(e)}posAtDOM(e,t=0){return this.docView.posFromDOM(e,t)}posAtCoords(e,t=!0){return this.readMeasured(),tf(this,e,t)}coordsAtPos(e,t=1){this.readMeasured();let n=this.docView.coordsAt(e,t);if(!n||n.left==n.right)return n;let r=this.state.doc.lineAt(e),i=this.bidiSpans(r);return x(n,i[eN.find(i,e-r.from,-1,t)].dir==eA.LTR==t>0)}coordsForChar(e){return this.readMeasured(),this.docView.coordsForChar(e)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(e){return!this.state.facet(eH)||e<this.viewport.from||e>this.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(e))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(e){if(e.length>nk)return eM(e.length);let t=this.textDirectionAt(e.from),n;for(let r of this.bidiCache)if(r.from==e.from&&r.dir==t&&(r.fresh||function e(t,n){if(t.length!=n.length)return!1;for(let r=0;r<t.length;r++){let i=t[r],s=n[r];if(i.from!=s.from||i.to!=s.to||i.direction!=s.direction||!e(i.inner,s.inner))return!1}return!0}(r.isolates,n=e9(this,e))))return r.order;!n&&(n=e9(this,e));let r=function(e,t,n){if(!e)return[new eN(0,0,t==eC?1:0)];if(t==ex&&!n.length&&!eT.test(e))return eM(e.length);if(n.length)for(;e.length>eB.length;)eB[eB.length]=256;let r=[],i=t==ex?0:1;return eI(e,i,i,n,0,e.length,r),r}(e.text,t,n);return this.bidiCache.push(new nD(e.from,e.to,t,n,!0,r)),r}get hasFocus(){var e;return(this.dom.ownerDocument.hasFocus()||X.safari&&(null===(e=this.inputState)||void 0===e?void 0:e.lastContextMenu)>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{_(this.contentDOM),this.docView.updateSelection()})}setRoot(e){this._root!=e&&(this._root=e,this.observer.setWindow((9==e.nodeType?e:e.ownerDocument).defaultView||window),this.mountStyles())}destroy(){for(let e of this.plugins)e.destroy(this);this.plugins=[],this.inputState.destroy(),this.docView.destroy(),this.dom.remove(),this.observer.destroy(),this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(e,t={}){return eJ.of(new eK("number"==typeof e?l.jT.cursor(e):e,t.y,t.x,t.yMargin,t.xMargin))}scrollSnapshot(){let{scrollTop:e,scrollLeft:t}=this.scrollDOM,n=this.viewState.scrollAnchorAt(e);return eJ.of(new eK(l.jT.cursor(n.from),"start","start",n.top-e,t,!0))}static domEventHandlers(e){return e0.define(()=>({}),{eventHandlers:e})}static domEventObservers(e){return e0.define(()=>({}),{eventObservers:e})}static theme(e,t){let n=a.V.newName(),r=[nn.of(n),tt.of(na(`.${n}`,e))];return t&&t.dark&&r.push(nr.of(!0)),r}static baseTheme(e){return l.Wl.lowest(tt.of(na("."+ni,e,nl)))}static findFromDOM(e){var t;let n=e.querySelector(".cm-content"),r=n&&$.get(n)||$.get(e);return(null===(t=null==r?void 0:r.rootView)||void 0===t?void 0:t.view)||null}}nv.styleModule=tt,nv.inputHandler=ez,nv.scrollHandler=eG,nv.focusChangeEffect=eU,nv.perLineTextDirection=eH,nv.exceptionSink=eq,nv.updateListener=eV,nv.editable=eY,nv.mouseSelectionStyle=ej,nv.dragMovesSelection=eR,nv.clickAddsSelectionRange=eL,nv.decorations=e5,nv.outerDecorations=e8,nv.atomicRanges=e4,nv.bidiIsolatedRanges=e6,nv.scrollMargins=e7,nv.darkTheme=nr,nv.cspNonce=l.r$.define({combine:e=>e.length?e[0]:""}),nv.contentAttributes=e3,nv.editorAttributes=e2,nv.lineWrapping=nv.contentAttributes.of({class:"cm-lineWrapping"}),nv.announce=l.Py.define();let nk=4096,nw={};class nD{constructor(e,t,n,r,i,s){this.from=e,this.to=t,this.dir=n,this.isolates=r,this.fresh=i,this.order=s}static update(e,t){if(t.empty&&!e.some(e=>e.fresh))return e;let n=[],r=e.length?e[e.length-1].dir:eA.LTR;for(let i=Math.max(0,e.length-10);i<e.length;i++){let s=e[i];s.dir==r&&!t.touchesRange(s.from,s.to)&&n.push(new nD(t.mapPos(s.from,1),t.mapPos(s.to,-1),s.dir,s.isolates,!1,s.order))}return n}}function nA(e,t,n){for(let r=e.state.facet(t),i=r.length-1;i>=0;i--){let t=r[i],s="function"==typeof t?t(e):t;s&&eo(s,n)}return n}let nx=X.mac?"mac":X.windows?"win":X.linux?"linux":"key";function nC(e,t,n){return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),!1!==n&&t.shiftKey&&(e="Shift-"+e),e}let nE=l.Wl.default(nv.domEventHandlers({keydown:(e,t)=>(function(e,t,n,r){var i,s;let o=(i=t,"Esc"==(s=!(c&&i.metaKey&&i.shiftKey&&!i.ctrlKey&&!i.altKey||f&&i.shiftKey&&i.key&&1==i.key.length||"Unidentified"==i.key)&&i.key||(i.shiftKey?h:u)[i.keyCode]||i.key||"Unidentified")&&(s="Escape"),"Del"==s&&(s="Delete"),"Left"==s&&(s="ArrowLeft"),"Up"==s&&(s="ArrowUp"),"Right"==s&&(s="ArrowRight"),"Down"==s&&(s="ArrowDown"),s),a=(0,l.gm)(o,0),d=(0,l.nZ)(a)==o.length&&" "!=o,p="",m=!1,g=!1,y=!1;nO&&nO.view==n&&nO.scope==r&&(p=nO.prefix+" ",0>tD.indexOf(t.keyCode)&&(g=!0,nO=null));let b=new Set,v=e=>{if(e){for(let r of e.run)if(!b.has(r)&&(b.add(r),r(n,t)))return e.stopPropagation&&(y=!0),!0;e.preventDefault&&(e.stopPropagation&&(y=!0),g=!0)}return!1},k=e[r],w,D;return k&&(v(k[p+nC(o,t,!d)])?m=!0:d&&(t.altKey||t.metaKey||t.ctrlKey)&&!(X.windows&&t.ctrlKey&&t.altKey)&&(w=u[t.keyCode])&&w!=o?v(k[p+nC(w,t,!0)])?m=!0:t.shiftKey&&(D=h[t.keyCode])!=o&&D!=w&&v(k[p+nC(D,t,!1)])&&(m=!0):d&&t.shiftKey&&v(k[p+nC(o,t,!0)])&&(m=!0),!m&&v(k._any)&&(m=!0)),g&&(m=!0),m&&y&&t.stopPropagation(),m})(function(e){let t=e.facet(nS),n=n_.get(t);return!n&&n_.set(t,n=function(e,t=nx){let n=Object.create(null),r=Object.create(null),i=(e,t)=>{let n=r[e];if(null==n)r[e]=t;else if(n!=t)throw Error("Key binding "+e+" is used both as a regular binding and as a multi-stroke prefix")},s=(e,r,s,o,l)=>{var a,u;let h=n[e]||(n[e]=Object.create(null)),c=r.split(/ (?!$)/).map(e=>(function(e,t){let n,r,i,s;let o=e.split(/-(?!$)/),l=o[o.length-1];"Space"==l&&(l=" ");for(let e=0;e<o.length-1;++e){let l=o[e];if(/^(cmd|meta|m)$/i.test(l))s=!0;else if(/^a(lt)?$/i.test(l))n=!0;else if(/^(c|ctrl|control)$/i.test(l))r=!0;else if(/^s(hift)?$/i.test(l))i=!0;else if(/^mod$/i.test(l))"mac"==t?s=!0:r=!0;else throw Error("Unrecognized modifier name: "+l)}return n&&(l="Alt-"+l),r&&(l="Ctrl-"+l),s&&(l="Meta-"+l),i&&(l="Shift-"+l),l})(e,t));for(let t=1;t<c.length;t++){let n=c.slice(0,t).join(" ");i(n,!0),!h[n]&&(h[n]={preventDefault:!0,stopPropagation:!1,run:[t=>{let r=nO={view:t,prefix:n,scope:e};return setTimeout(()=>{nO==r&&(nO=null)},4e3),!0}]})}let f=c.join(" ");i(f,!1);let d=h[f]||(h[f]={preventDefault:!1,stopPropagation:!1,run:(null===(u=null===(a=h._any)||void 0===a?void 0:a.run)||void 0===u?void 0:u.slice())||[]});s&&d.run.push(s),o&&(d.preventDefault=!0),l&&(d.stopPropagation=!0)};for(let r of e){let e=r.scope?r.scope.split(" "):["editor"];if(r.any)for(let t of e){let e=n[t]||(n[t]=Object.create(null));for(let t in!e._any&&(e._any={preventDefault:!1,stopPropagation:!1,run:[]}),e)e[t].run.push(r.any)}let i=r[t]||r.key;if(i)for(let t of e)s(t,i,r.run,r.preventDefault,r.stopPropagation),r.shift&&s(t,"Shift-"+i,r.shift,r.preventDefault,r.stopPropagation)}return n}(t.reduce((e,t)=>e.concat(t),[]))),n}(t.state),e,t,"editor")})),nS=l.r$.define({enables:nE}),n_=new WeakMap,nO=null;class nF{constructor(e,t,n,r,i){this.className=e,this.left=t,this.top=n,this.width=r,this.height=i}draw(){let e=document.createElement("div");return e.className=this.className,this.adjust(e),e}update(e,t){return t.className==this.className&&(this.adjust(e),!0)}adjust(e){e.style.left=this.left+"px",e.style.top=this.top+"px",null!=this.width&&(e.style.width=this.width+"px"),e.style.height=this.height+"px"}eq(e){return this.left==e.left&&this.top==e.top&&this.width==e.width&&this.height==e.height&&this.className==e.className}static forRange(e,t,n){if(!n.empty)return function(e,t,n){if(n.to<=e.viewport.from||n.from>=e.viewport.to)return[];let r=Math.max(n.from,e.viewport.from),i=Math.min(n.to,e.viewport.to),s=e.textDirection==eA.LTR,o=e.contentDOM,l=o.getBoundingClientRect(),a=nP(e),u=o.querySelector(".cm-line"),h=u&&window.getComputedStyle(u),c=l.left+(h?parseInt(h.paddingLeft)+Math.min(0,parseInt(h.textIndent)):0),f=l.right-(h?parseInt(h.paddingRight):0),d=tp(e,r),p=tp(e,i),m=d.type==ed.Text?d:null,g=p.type==ed.Text?p:null;if(m&&(e.lineWrapping||d.widgetLineBreaks)&&(m=nT(e,r,m)),g&&(e.lineWrapping||p.widgetLineBreaks)&&(g=nT(e,i,g)),m&&g&&m.from==g.from)return b(v(n.from,n.to,m));{let t=m?v(n.from,null,m):k(d,!1),r=g?v(null,n.to,g):k(p,!0),i=[];return(m||d).to<(g||p).from-(m&&g?1:0)||d.widgetLineBreaks>1&&t.bottom+e.defaultLineHeight/2<r.top?i.push(y(c,t.bottom,f,r.top)):t.bottom<r.top&&e.elementAtHeight((t.bottom+r.top)/2).type==ed.Text&&(t.bottom=r.top=(t.bottom+r.top)/2),b(t).concat(i).concat(b(r))}function y(e,n,r,i){return new nF(t,e-a.left,n-a.top-.01,r-e,i-n+.01)}function b({top:e,bottom:t,horizontal:n}){let r=[];for(let i=0;i<n.length;i+=2)r.push(y(n[i],e,n[i+1],t));return r}function v(t,n,r){let i=1e9,o=-1e9,l=[];function a(t,n,a,u,h){let d=e.coordsAtPos(t,t==r.to?-2:2),p=e.coordsAtPos(a,a==r.from?2:-2);d&&p&&(i=Math.min(d.top,p.top,i),o=Math.max(d.bottom,p.bottom,o),h==eA.LTR?l.push(s&&n?c:d.left,s&&u?f:p.right):l.push(!s&&u?c:p.left,!s&&n?f:d.right))}let u=null!=t?t:r.from,h=null!=n?n:r.to;for(let r of e.visibleRanges)if(r.to>u&&r.from<h)for(let i=Math.max(r.from,u),s=Math.min(r.to,h);;){let r=e.state.doc.lineAt(i);for(let o of e.bidiSpans(r)){let e=o.from+r.from,l=o.to+r.from;if(e>=s)break;l>i&&a(Math.max(e,i),null==t&&e<=u,Math.min(l,s),null==n&&l>=h,o.dir)}if((i=r.to+1)>=s)break}return 0==l.length&&a(u,null==t,h,null==n,e.textDirection),{top:i,bottom:o,horizontal:l}}function k(e,t){let n=l.top+(t?e.top:e.bottom);return{top:n,bottom:n,horizontal:[]}}}(e,t,n);{let r=e.coordsAtPos(n.head,n.assoc||1);if(!r)return[];let i=nP(e);return[new nF(t,r.left-i.left,r.top-i.top,null,r.bottom-r.top)]}}}function nP(e){let t=e.scrollDOM.getBoundingClientRect();return{left:(e.textDirection==eA.LTR?t.left:t.right-e.scrollDOM.clientWidth*e.scaleX)-e.scrollDOM.scrollLeft*e.scaleX,top:t.top-e.scrollDOM.scrollTop*e.scaleY}}function nT(e,t,n){let r=l.jT.cursor(t);return{from:Math.max(n.from,e.moveToLineBoundary(r,!1,!0).from),to:Math.min(n.to,e.moveToLineBoundary(r,!0,!0).from),type:ed.Text}}class nN{constructor(e,t){this.view=e,this.layer=t,this.drawn=[],this.scaleX=1,this.scaleY=1,this.measureReq={read:this.measure.bind(this),write:this.draw.bind(this)},this.dom=e.scrollDOM.appendChild(document.createElement("div")),this.dom.classList.add("cm-layer"),t.above&&this.dom.classList.add("cm-layer-above"),t.class&&this.dom.classList.add(t.class),this.scale(),this.dom.setAttribute("aria-hidden","true"),this.setOrder(e.state),e.requestMeasure(this.measureReq),t.mount&&t.mount(this.dom,e)}update(e){e.startState.facet(nB)!=e.state.facet(nB)&&this.setOrder(e.state),(this.layer.update(e,this.dom)||e.geometryChanged)&&(this.scale(),e.view.requestMeasure(this.measureReq))}docViewUpdate(e){!1!==this.layer.updateOnDocViewUpdate&&e.requestMeasure(this.measureReq)}setOrder(e){let t=0,n=e.facet(nB);for(;t<n.length&&n[t]!=this.layer;)t++;this.dom.style.zIndex=String((this.layer.above?150:-1)-t)}measure(){return this.layer.markers(this.view)}scale(){let{scaleX:e,scaleY:t}=this.view;(e!=this.scaleX||t!=this.scaleY)&&(this.scaleX=e,this.scaleY=t,this.dom.style.transform=`scale(${1/e}, ${1/t})`)}draw(e){if(e.length!=this.drawn.length||e.some((e,t)=>{var n,r;return n=e,r=this.drawn[t],!(n.constructor==r.constructor&&n.eq(r))})){let t=this.dom.firstChild,n=0;for(let r of e)r.update&&t&&r.constructor&&this.drawn[n].constructor&&r.update(t,this.drawn[n])?(t=t.nextSibling,n++):this.dom.insertBefore(r.draw(),t);for(;t;){let e=t.nextSibling;t.remove(),t=e}this.drawn=e}}destroy(){this.layer.destroy&&this.layer.destroy(this.dom,this.view),this.dom.remove()}}let nB=l.r$.define();function nI(e){return[e0.define(t=>new nN(t,e)),nB.of(e)]}let nM=!X.ios,n$=l.r$.define({combine:e=>(0,l.BO)(e,{cursorBlinkRate:1200,drawRangeCursor:!0},{cursorBlinkRate:(e,t)=>Math.min(e,t),drawRangeCursor:(e,t)=>e||t})});function nL(e={}){return[n$.of(e),nj,nV,nU,eW.of(!0)]}function nR(e){return e.startState.facet(n$)!=e.state.facet(n$)}let nj=nI({above:!0,markers(e){let{state:t}=e,n=t.facet(n$),r=[];for(let i of t.selection.ranges){let s=i==t.selection.main;if(i.empty?!s||nM:n.drawRangeCursor){let t=s?"cm-cursor cm-cursor-primary":"cm-cursor cm-cursor-secondary",n=i.empty?i:l.jT.cursor(i.head,i.head>i.anchor?-1:1);for(let i of nF.forRange(e,t,n))r.push(i)}}return r},update(e,t){e.transactions.some(e=>e.selection)&&(t.style.animationName="cm-blink"==t.style.animationName?"cm-blink2":"cm-blink");let n=nR(e);return n&&nq(e.state,t),e.docChanged||e.selectionSet||n},mount(e,t){nq(t.state,e)},class:"cm-cursorLayer"});function nq(e,t){t.style.animationDuration=e.facet(n$).cursorBlinkRate+"ms"}let nV=nI({above:!1,markers:e=>e.state.selection.ranges.map(t=>t.empty?[]:nF.forRange(e,"cm-selectionBackground",t)).reduce((e,t)=>e.concat(t)),update:(e,t)=>e.docChanged||e.selectionSet||e.viewportChanged||nR(e),class:"cm-selectionLayer"}),nz={".cm-line":{"& ::selection":{backgroundColor:"transparent !important"},"&::selection":{backgroundColor:"transparent !important"}}};nM&&(nz[".cm-line"].caretColor="transparent !important",nz[".cm-content"]={caretColor:"transparent !important"});let nU=l.Wl.highest(nv.theme(nz));function nH(e,t,n,r,i){t.lastIndex=0;for(let s=e.iterRange(n,r),o=n,l;!s.next().done;o+=s.value.length)if(!s.lineBreak)for(;l=t.exec(s.value);)i(o+l.index,l)}null!=/x/.unicode?"gu":"g";let nW=null,nG="-10000px";class nK{constructor(e,t,n,r){this.facet=t,this.createTooltipView=n,this.removeTooltipView=r,this.input=e.state.facet(t),this.tooltips=this.input.filter(e=>e);let i=null;this.tooltipViews=this.tooltips.map(e=>i=n(e,i))}update(e,t){var n;let r=e.state.facet(this.facet),i=r.filter(e=>e);if(r===this.input){for(let t of this.tooltipViews)t.update&&t.update(e);return!1}let s=[],o=t?[]:null;for(let n=0;n<i.length;n++){let r=i[n],l=-1;if(r){for(let e=0;e<this.tooltips.length;e++){let t=this.tooltips[e];t&&t.create==r.create&&(l=e)}if(l<0)s[n]=this.createTooltipView(r,n?s[n-1]:null),o&&(o[n]=!!r.above);else{let r=s[n]=this.tooltipViews[l];o&&(o[n]=t[l]),r.update&&r.update(e)}}}for(let e of this.tooltipViews)0>s.indexOf(e)&&(this.removeTooltipView(e),null===(n=e.destroy)||void 0===n||n.call(e));return t&&(o.forEach((e,n)=>t[n]=e),t.length=o.length),this.input=r,this.tooltips=i,this.tooltipViews=s,!0}}function nJ(e){let{win:t}=e;return{top:0,left:0,bottom:t.innerHeight,right:t.innerWidth}}let nQ=l.r$.define({combine:e=>{var t,n,r;return{position:X.ios?"absolute":(null===(t=e.find(e=>e.position))||void 0===t?void 0:t.position)||"fixed",parent:(null===(n=e.find(e=>e.parent))||void 0===n?void 0:n.parent)||null,tooltipSpace:(null===(r=e.find(e=>e.tooltipSpace))||void 0===r?void 0:r.tooltipSpace)||nJ}}}),nY=new WeakMap,nZ=e0.fromClass(class{constructor(e){this.view=e,this.above=[],this.inView=!0,this.madeAbsolute=!1,this.lastTransaction=0,this.measureTimeout=-1;let t=e.state.facet(nQ);this.position=t.position,this.parent=t.parent,this.classes=e.themeClasses,this.createContainer(),this.measureReq={read:this.readMeasure.bind(this),write:this.writeMeasure.bind(this),key:this},this.resizeObserver="function"==typeof ResizeObserver?new ResizeObserver(()=>this.measureSoon()):null,this.manager=new nK(e,n1,(e,t)=>this.createTooltip(e,t),e=>{this.resizeObserver&&this.resizeObserver.unobserve(e.dom),e.dom.remove()}),this.above=this.manager.tooltips.map(e=>!!e.above),this.intersectionObserver="function"==typeof IntersectionObserver?new IntersectionObserver(e=>{Date.now()>this.lastTransaction-50&&e.length>0&&e[e.length-1].intersectionRatio<1&&this.measureSoon()},{threshold:[1]}):null,this.observeIntersection(),e.win.addEventListener("resize",this.measureSoon=this.measureSoon.bind(this)),this.maybeMeasure()}createContainer(){this.parent?(this.container=document.createElement("div"),this.container.style.position="relative",this.container.className=this.view.themeClasses,this.parent.appendChild(this.container)):this.container=this.view.dom}observeIntersection(){if(this.intersectionObserver)for(let e of(this.intersectionObserver.disconnect(),this.manager.tooltipViews))this.intersectionObserver.observe(e.dom)}measureSoon(){this.measureTimeout<0&&(this.measureTimeout=setTimeout(()=>{this.measureTimeout=-1,this.maybeMeasure()},50))}update(e){e.transactions.length&&(this.lastTransaction=Date.now());let t=this.manager.update(e,this.above);t&&this.observeIntersection();let n=t||e.geometryChanged,r=e.state.facet(nQ);if(r.position!=this.position&&!this.madeAbsolute){for(let e of(this.position=r.position,this.manager.tooltipViews))e.dom.style.position=this.position;n=!0}if(r.parent!=this.parent){for(let e of(this.parent&&this.container.remove(),this.parent=r.parent,this.createContainer(),this.manager.tooltipViews))this.container.appendChild(e.dom);n=!0}else this.parent&&this.view.themeClasses!=this.classes&&(this.classes=this.container.className=this.view.themeClasses);n&&this.maybeMeasure()}createTooltip(e,t){let n=e.create(this.view),r=t?t.dom:null;if(n.dom.classList.add("cm-tooltip"),e.arrow&&!n.dom.querySelector(".cm-tooltip > .cm-tooltip-arrow")){let e=document.createElement("div");e.className="cm-tooltip-arrow",n.dom.appendChild(e)}return n.dom.style.position=this.position,n.dom.style.top=nG,n.dom.style.left="0px",this.container.insertBefore(n.dom,r),n.mount&&n.mount(this.view),this.resizeObserver&&this.resizeObserver.observe(n.dom),n}destroy(){var e,t,n;for(let t of(this.view.win.removeEventListener("resize",this.measureSoon),this.manager.tooltipViews))t.dom.remove(),null===(e=t.destroy)||void 0===e||e.call(t);this.parent&&this.container.remove(),null===(t=this.resizeObserver)||void 0===t||t.disconnect(),null===(n=this.intersectionObserver)||void 0===n||n.disconnect(),clearTimeout(this.measureTimeout)}readMeasure(){let e=this.view.dom.getBoundingClientRect(),t=1,n=1,r=!1;if("fixed"==this.position&&this.manager.tooltipViews.length){let{dom:e}=this.manager.tooltipViews[0];if(X.gecko)r=e.offsetParent!=this.container.ownerDocument.body;else if(e.style.top==nG&&"0px"==e.style.left){let t=e.getBoundingClientRect();r=Math.abs(t.top+1e4)>1||Math.abs(t.left)>1}}if(r||"absolute"==this.position){if(this.parent){let e=this.parent.getBoundingClientRect();e.width&&e.height&&(t=e.width/this.parent.offsetWidth,n=e.height/this.parent.offsetHeight)}else({scaleX:t,scaleY:n}=this.view.viewState)}return{editor:e,parent:this.parent?this.container.getBoundingClientRect():e,pos:this.manager.tooltips.map((e,t)=>{let n=this.manager.tooltipViews[t];return n.getCoords?n.getCoords(e.pos):this.view.coordsAtPos(e.pos)}),size:this.manager.tooltipViews.map(({dom:e})=>e.getBoundingClientRect()),space:this.view.state.facet(nQ).tooltipSpace(this.view),scaleX:t,scaleY:n,makeAbsolute:r}}writeMeasure(e){var t;if(e.makeAbsolute)for(let e of(this.madeAbsolute=!0,this.position="absolute",this.manager.tooltipViews))e.dom.style.position="absolute";let{editor:n,space:r,scaleX:i,scaleY:s}=e,o=[];for(let l=0;l<this.manager.tooltips.length;l++){let a=this.manager.tooltips[l],u=this.manager.tooltipViews[l],{dom:h}=u,c=e.pos[l],f=e.size[l];if(!c||c.bottom<=Math.max(n.top,r.top)||c.top>=Math.min(n.bottom,r.bottom)||c.right<Math.max(n.left,r.left)-.1||c.left>Math.min(n.right,r.right)+.1){h.style.top=nG;continue}let d=a.arrow?u.dom.querySelector(".cm-tooltip-arrow"):null,p=d?7:0,m=f.right-f.left,g=null!==(t=nY.get(u))&&void 0!==t?t:f.bottom-f.top,y=u.offset||n0,b=this.view.textDirection==eA.LTR,v=f.width>r.right-r.left?b?r.left:r.right-f.width:b?Math.min(c.left-(d?14:0)+y.x,r.right-m):Math.max(r.left,c.left-m+(d?14:0)-y.x),k=this.above[l];!a.strictSide&&(k?c.top-(f.bottom-f.top)-y.y<r.top:c.bottom+(f.bottom-f.top)+y.y>r.bottom)&&k==r.bottom-c.bottom>c.top-r.top&&(k=this.above[l]=!k);let w=(k?c.top-r.top:r.bottom-c.bottom)-p;if(w<g&&!1!==u.resize){if(w<this.view.defaultLineHeight){h.style.top=nG;continue}nY.set(u,g),h.style.height=(g=w)/s+"px"}else h.style.height&&(h.style.height="");let D=k?c.top-g-p-y.y:c.bottom+p+y.y,A=v+m;if(!0!==u.overlap)for(let e of o)e.left<A&&e.right>v&&e.top<D+g&&e.bottom>D&&(D=k?e.top-g-2-p:e.bottom+p+2);if("absolute"==this.position?(h.style.top=(D-e.parent.top)/s+"px",h.style.left=(v-e.parent.left)/i+"px"):(h.style.top=D/s+"px",h.style.left=v/i+"px"),d){let e=c.left+(b?y.x:-y.x)-(v+14-7);d.style.left=e/i+"px"}!0!==u.overlap&&o.push({left:v,top:D,right:A,bottom:D+g}),h.classList.toggle("cm-tooltip-above",k),h.classList.toggle("cm-tooltip-below",!k),u.positioned&&u.positioned(e.space)}}maybeMeasure(){if(this.manager.tooltips.length&&(this.view.inView&&this.view.requestMeasure(this.measureReq),this.inView!=this.view.inView&&(this.inView=this.view.inView,!this.inView)))for(let e of this.manager.tooltipViews)e.dom.style.top=nG}},{eventObservers:{scroll(){this.maybeMeasure()}}}),nX=nv.baseTheme({".cm-tooltip":{zIndex:100,boxSizing:"border-box"},"&light .cm-tooltip":{border:"1px solid #bbb",backgroundColor:"#f5f5f5"},"&light .cm-tooltip-section:not(:first-child)":{borderTop:"1px solid #bbb"},"&dark .cm-tooltip":{backgroundColor:"#333338",color:"white"},".cm-tooltip-arrow":{height:"7px",width:"14px",position:"absolute",zIndex:-1,overflow:"hidden","&:before, &:after":{content:"''",position:"absolute",width:0,height:0,borderLeft:"7px solid transparent",borderRight:"7px solid transparent"},".cm-tooltip-above &":{bottom:"-7px","&:before":{borderTop:"7px solid #bbb"},"&:after":{borderTop:"7px solid #f5f5f5",bottom:"1px"}},".cm-tooltip-below &":{top:"-7px","&:before":{borderBottom:"7px solid #bbb"},"&:after":{borderBottom:"7px solid #f5f5f5",top:"1px"}}},"&dark .cm-tooltip .cm-tooltip-arrow":{"&:before":{borderTopColor:"#333338",borderBottomColor:"#333338"},"&:after":{borderTopColor:"transparent",borderBottomColor:"transparent"}}}),n0={x:0,y:0},n1=l.r$.define({enables:[nZ,nX]}),n2=l.r$.define({combine:e=>e.reduce((e,t)=>e.concat(t),[])});class n3{static create(e){return new n3(e)}constructor(e){this.view=e,this.mounted=!1,this.dom=document.createElement("div"),this.dom.classList.add("cm-tooltip-hover"),this.manager=new nK(e,n2,(e,t)=>this.createHostedView(e,t),e=>e.dom.remove())}createHostedView(e,t){let n=e.create(this.view);return n.dom.classList.add("cm-tooltip-section"),this.dom.insertBefore(n.dom,t?t.dom.nextSibling:this.dom.firstChild),this.mounted&&n.mount&&n.mount(this.view),n}mount(e){for(let t of this.manager.tooltipViews)t.mount&&t.mount(e);this.mounted=!0}positioned(e){for(let t of this.manager.tooltipViews)t.positioned&&t.positioned(e)}update(e){this.manager.update(e)}destroy(){var e;for(let t of this.manager.tooltipViews)null===(e=t.destroy)||void 0===e||e.call(t)}passProp(e){let t;for(let n of this.manager.tooltipViews){let r=n[e];if(void 0!==r){if(void 0===t)t=r;else if(t!==r)return}}return t}get offset(){return this.passProp("offset")}get getCoords(){return this.passProp("getCoords")}get overlap(){return this.passProp("overlap")}get resize(){return this.passProp("resize")}}let n5=n1.compute([n2],e=>{let t=e.facet(n2);return 0===t.length?null:{pos:Math.min(...t.map(e=>e.pos)),end:Math.max(...t.map(e=>{var t;return null!==(t=e.end)&&void 0!==t?t:e.pos})),create:n3.create,above:t[0].above,arrow:t.some(e=>e.arrow)}});class n8{constructor(e,t,n,r,i){this.view=e,this.source=t,this.field=n,this.setHover=r,this.hoverTime=i,this.hoverTimeout=-1,this.restartTimeout=-1,this.pending=null,this.lastMove={x:0,y:0,target:e.dom,time:0},this.checkHover=this.checkHover.bind(this),e.dom.addEventListener("mouseleave",this.mouseleave=this.mouseleave.bind(this)),e.dom.addEventListener("mousemove",this.mousemove=this.mousemove.bind(this))}update(){this.pending&&(this.pending=null,clearTimeout(this.restartTimeout),this.restartTimeout=setTimeout(()=>this.startHover(),20))}get active(){return this.view.state.field(this.field)}checkHover(){if(this.hoverTimeout=-1,this.active.length)return;let e=Date.now()-this.lastMove.time;e<this.hoverTime?this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime-e):this.startHover()}startHover(){clearTimeout(this.restartTimeout);let{view:e,lastMove:t}=this,n=e.docView.nearest(t.target);if(!n)return;let r,i=1;if(n instanceof en)r=n.posAtStart;else{if(null==(r=e.posAtCoords(t)))return;let n=e.coordsAtPos(r);if(!n||t.y<n.top||t.y>n.bottom||t.x<n.left-e.defaultCharacterWidth||t.x>n.right+e.defaultCharacterWidth)return;let s=e.bidiSpans(e.state.doc.lineAt(r)).find(e=>e.from<=r&&e.to>=r),o=s&&s.dir==eA.RTL?-1:1;i=t.x<n.left?-o:o}let s=this.source(e,r,i);if(null==s?void 0:s.then){let t=this.pending={pos:r};s.then(n=>{this.pending==t&&(this.pending=null,n&&!(Array.isArray(n)&&!n.length)&&e.dispatch({effects:this.setHover.of(Array.isArray(n)?n:[n])}))},t=>eQ(e.state,t,"hover tooltip"))}else s&&!(Array.isArray(s)&&!s.length)&&e.dispatch({effects:this.setHover.of(Array.isArray(s)?s:[s])})}get tooltip(){let e=this.view.plugin(nZ),t=e?e.manager.tooltips.findIndex(e=>e.create==n3.create):-1;return t>-1?e.manager.tooltipViews[t]:null}mousemove(e){var t,n;this.lastMove={x:e.clientX,y:e.clientY,target:e.target,time:Date.now()},this.hoverTimeout<0&&(this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime));let{active:r,tooltip:i}=this;if(r.length&&i&&!function(e,t){let n=e.getBoundingClientRect();return t.clientX>=n.left-4&&t.clientX<=n.right+4&&t.clientY>=n.top-4&&t.clientY<=n.bottom+4}(i.dom,e)||this.pending){let{pos:i}=r[0]||this.pending,s=null!==(n=null===(t=r[0])||void 0===t?void 0:t.end)&&void 0!==n?n:i;(i==s?this.view.posAtCoords(this.lastMove)!=i:!function(e,t,n,r,i,s){let o=e.scrollDOM.getBoundingClientRect(),l=e.documentTop+e.documentPadding.top+e.contentHeight;if(o.left>r||o.right<r||o.top>i||Math.min(o.bottom,l)<i)return!1;let a=e.posAtCoords({x:r,y:i},!1);return a>=t&&a<=n}(this.view,i,s,e.clientX,e.clientY))&&(this.view.dispatch({effects:this.setHover.of([])}),this.pending=null)}}mouseleave(e){clearTimeout(this.hoverTimeout),this.hoverTimeout=-1;let{active:t}=this;if(t.length){let{tooltip:t}=this;t&&t.dom.contains(e.relatedTarget)?this.watchTooltipLeave(t.dom):this.view.dispatch({effects:this.setHover.of([])})}}watchTooltipLeave(e){let t=n=>{e.removeEventListener("mouseleave",t),this.active.length&&!this.view.dom.contains(n.relatedTarget)&&this.view.dispatch({effects:this.setHover.of([])})};e.addEventListener("mouseleave",t)}destroy(){clearTimeout(this.hoverTimeout),this.view.dom.removeEventListener("mouseleave",this.mouseleave),this.view.dom.removeEventListener("mousemove",this.mousemove)}}function n4(e,t={}){let n=l.Py.define(),r=l.QQ.define({create:()=>[],update(e,r){if(e.length&&(t.hideOnChange&&(r.docChanged||r.selection)?e=[]:t.hideOn&&(e=e.filter(e=>!t.hideOn(r,e))),r.docChanged)){let t=[];for(let n of e){let e=r.changes.mapPos(n.pos,-1,l.gc.TrackDel);if(null!=e){let i=Object.assign(Object.create(null),n);i.pos=e,null!=i.end&&(i.end=r.changes.mapPos(i.end)),t.push(i)}}e=t}for(let t of r.effects)t.is(n)&&(e=t.value),t.is(n9)&&(e=[]);return e},provide:e=>n2.from(e)});return[r,e0.define(i=>new n8(i,e,r,n,t.hoverTime||300)),n5]}function n6(e,t){let n=e.plugin(nZ);if(!n)return null;let r=n.manager.tooltips.indexOf(t);return r<0?null:n.manager.tooltipViews[r]}let n9=l.Py.define(),n7=l.r$.define({combine(e){let t,n;for(let r of e)t=t||r.topContainer,n=n||r.bottomContainer;return{topContainer:t,bottomContainer:n}}});function re(e,t){let n=e.plugin(rt),r=n?n.specs.indexOf(t):-1;return r>-1?n.panels[r]:null}let rt=e0.fromClass(class{constructor(e){this.input=e.state.facet(ri),this.specs=this.input.filter(e=>e),this.panels=this.specs.map(t=>t(e));let t=e.state.facet(n7);for(let n of(this.top=new rn(e,!0,t.topContainer),this.bottom=new rn(e,!1,t.bottomContainer),this.top.sync(this.panels.filter(e=>e.top)),this.bottom.sync(this.panels.filter(e=>!e.top)),this.panels))n.dom.classList.add("cm-panel"),n.mount&&n.mount()}update(e){let t=e.state.facet(n7);this.top.container!=t.topContainer&&(this.top.sync([]),this.top=new rn(e.view,!0,t.topContainer)),this.bottom.container!=t.bottomContainer&&(this.bottom.sync([]),this.bottom=new rn(e.view,!1,t.bottomContainer)),this.top.syncClasses(),this.bottom.syncClasses();let n=e.state.facet(ri);if(n!=this.input){let t=n.filter(e=>e),r=[],i=[],s=[],o=[];for(let n of t){let t=this.specs.indexOf(n),l;t<0?(l=n(e.view),o.push(l)):(l=this.panels[t]).update&&l.update(e),r.push(l),(l.top?i:s).push(l)}for(let e of(this.specs=t,this.panels=r,this.top.sync(i),this.bottom.sync(s),o))e.dom.classList.add("cm-panel"),e.mount&&e.mount()}else for(let t of this.panels)t.update&&t.update(e)}destroy(){this.top.sync([]),this.bottom.sync([])}},{provide:e=>nv.scrollMargins.of(t=>{let n=t.plugin(e);return n&&{top:n.top.scrollMargin(),bottom:n.bottom.scrollMargin()}})});class rn{constructor(e,t,n){this.view=e,this.top=t,this.container=n,this.dom=void 0,this.classes="",this.panels=[],this.syncClasses()}sync(e){for(let t of this.panels)t.destroy&&0>e.indexOf(t)&&t.destroy();this.panels=e,this.syncDOM()}syncDOM(){if(0==this.panels.length){this.dom&&(this.dom.remove(),this.dom=void 0);return}if(!this.dom){this.dom=document.createElement("div"),this.dom.className=this.top?"cm-panels cm-panels-top":"cm-panels cm-panels-bottom",this.dom.style[this.top?"top":"bottom"]="0";let e=this.container||this.view.dom;e.insertBefore(this.dom,this.top?e.firstChild:null)}let e=this.dom.firstChild;for(let t of this.panels)if(t.dom.parentNode==this.dom){for(;e!=t.dom;)e=rr(e);e=e.nextSibling}else this.dom.insertBefore(t.dom,e);for(;e;)e=rr(e)}scrollMargin(){return!this.dom||this.container?0:Math.max(0,this.top?this.dom.getBoundingClientRect().bottom-Math.max(0,this.view.scrollDOM.getBoundingClientRect().top):Math.min(innerHeight,this.view.scrollDOM.getBoundingClientRect().bottom)-this.dom.getBoundingClientRect().top)}syncClasses(){if(this.container&&this.classes!=this.view.themeClasses){for(let e of this.classes.split(" "))e&&this.container.classList.remove(e);for(let e of(this.classes=this.view.themeClasses).split(" "))e&&this.container.classList.add(e)}}}function rr(e){let t=e.nextSibling;return e.remove(),t}let ri=l.r$.define({enables:rt});class rs extends l.uU{compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}eq(e){return!1}destroy(e){}}rs.prototype.elementClass="",rs.prototype.toDOM=void 0,rs.prototype.mapMode=l.gc.TrackBefore,rs.prototype.startSide=rs.prototype.endSide=-1,rs.prototype.point=!0;let ro=l.r$.define(),rl={class:"",renderEmptyElements:!1,elementStyle:"",markers:()=>l.Xs.empty,lineMarker:()=>null,widgetMarker:()=>null,lineMarkerChange:null,initialSpacer:null,updateSpacer:null,domEventHandlers:{}},ra=l.r$.define();function ru(e){return[rc(),ra.of(Object.assign(Object.assign({},rl),e))]}let rh=l.r$.define({combine:e=>e.some(e=>e)});function rc(e){let t=[rf];return e&&!1===e.fixed&&t.push(rh.of(!0)),t}let rf=e0.fromClass(class{constructor(e){for(let t of(this.view=e,this.prevViewport=e.viewport,this.dom=document.createElement("div"),this.dom.className="cm-gutters",this.dom.setAttribute("aria-hidden","true"),this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.gutters=e.state.facet(ra).map(t=>new rg(e,t)),this.gutters))this.dom.appendChild(t.dom);this.fixed=!e.state.facet(rh),this.fixed&&(this.dom.style.position="sticky"),this.syncGutters(!1),e.scrollDOM.insertBefore(this.dom,e.contentDOM)}update(e){if(this.updateGutters(e)){let t=this.prevViewport,n=e.view.viewport,r=Math.min(t.to,n.to)-Math.max(t.from,n.from);this.syncGutters(r<(n.to-n.from)*.8)}e.geometryChanged&&(this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px"),this.view.state.facet(rh)!=!this.fixed&&(this.fixed=!this.fixed,this.dom.style.position=this.fixed?"sticky":""),this.prevViewport=e.view.viewport}syncGutters(e){let t=this.dom.nextSibling;e&&this.dom.remove();let n=l.Xs.iter(this.view.state.facet(ro),this.view.viewport.from),r=[],i=this.gutters.map(e=>new rm(e,this.view.viewport,-this.view.documentPadding.top));for(let e of this.view.viewportLineBlocks)if(r.length&&(r=[]),Array.isArray(e.type)){let t=!0;for(let s of e.type)if(s.type==ed.Text&&t){for(let e of(rp(n,r,s.from),i))e.line(this.view,s,r);t=!1}else if(s.widget)for(let e of i)e.widget(this.view,s)}else if(e.type==ed.Text)for(let t of(rp(n,r,e.from),i))t.line(this.view,e,r);else if(e.widget)for(let t of i)t.widget(this.view,e);for(let e of i)e.finish();e&&this.view.scrollDOM.insertBefore(this.dom,t)}updateGutters(e){let t=e.startState.facet(ra),n=e.state.facet(ra),r=e.docChanged||e.heightChanged||e.viewportChanged||!l.Xs.eq(e.startState.facet(ro),e.state.facet(ro),e.view.viewport.from,e.view.viewport.to);if(t==n)for(let t of this.gutters)t.update(e)&&(r=!0);else{r=!0;let i=[];for(let r of n){let n=t.indexOf(r);n<0?i.push(new rg(this.view,r)):(this.gutters[n].update(e),i.push(this.gutters[n]))}for(let e of this.gutters)e.dom.remove(),0>i.indexOf(e)&&e.destroy();for(let e of i)this.dom.appendChild(e.dom);this.gutters=i}return r}destroy(){for(let e of this.gutters)e.destroy();this.dom.remove()}},{provide:e=>nv.scrollMargins.of(t=>{let n=t.plugin(e);return n&&0!=n.gutters.length&&n.fixed?t.textDirection==eA.LTR?{left:n.dom.offsetWidth*t.scaleX}:{right:n.dom.offsetWidth*t.scaleX}:null})});function rd(e){return Array.isArray(e)?e:[e]}function rp(e,t,n){for(;e.value&&e.from<=n;)e.from==n&&t.push(e.value),e.next()}class rm{constructor(e,t,n){this.gutter=e,this.height=n,this.i=0,this.cursor=l.Xs.iter(e.markers,t.from)}addElement(e,t,n){let{gutter:r}=this,i=(t.top-this.height)/e.scaleY,s=t.height/e.scaleY;if(this.i==r.elements.length){let t=new ry(e,s,i,n);r.elements.push(t),r.dom.appendChild(t.dom)}else r.elements[this.i].update(e,s,i,n);this.height=t.bottom,this.i++}line(e,t,n){let r=[];rp(this.cursor,r,t.from),n.length&&(r=r.concat(n));let i=this.gutter.config.lineMarker(e,t,r);i&&r.unshift(i);let s=this.gutter;(0!=r.length||s.config.renderEmptyElements)&&this.addElement(e,t,r)}widget(e,t){let n=this.gutter.config.widgetMarker(e,t.widget,t);n&&this.addElement(e,t,[n])}finish(){let e=this.gutter;for(;e.elements.length>this.i;){let t=e.elements.pop();e.dom.removeChild(t.dom),t.destroy()}}}class rg{constructor(e,t){for(let n in this.view=e,this.config=t,this.elements=[],this.spacer=null,this.dom=document.createElement("div"),this.dom.className="cm-gutter"+(this.config.class?" "+this.config.class:""),t.domEventHandlers)this.dom.addEventListener(n,r=>{let i=r.target,s;if(i!=this.dom&&this.dom.contains(i)){for(;i.parentNode!=this.dom;)i=i.parentNode;let e=i.getBoundingClientRect();s=(e.top+e.bottom)/2}else s=r.clientY;let o=e.lineBlockAtHeight(s-e.documentTop);t.domEventHandlers[n](e,o,r)&&r.preventDefault()});this.markers=rd(t.markers(e)),t.initialSpacer&&(this.spacer=new ry(e,0,0,[t.initialSpacer(e)]),this.dom.appendChild(this.spacer.dom),this.spacer.dom.style.cssText+="visibility: hidden; pointer-events: none")}update(e){let t=this.markers;if(this.markers=rd(this.config.markers(e.view)),this.spacer&&this.config.updateSpacer){let t=this.config.updateSpacer(this.spacer.markers[0],e);t!=this.spacer.markers[0]&&this.spacer.update(e.view,0,0,[t])}let n=e.view.viewport;return!l.Xs.eq(this.markers,t,n.from,n.to)||!!this.config.lineMarkerChange&&this.config.lineMarkerChange(e)}destroy(){for(let e of this.elements)e.destroy()}}class ry{constructor(e,t,n,r){this.height=-1,this.above=0,this.markers=[],this.dom=document.createElement("div"),this.dom.className="cm-gutterElement",this.update(e,t,n,r)}update(e,t,n,r){this.height!=t&&(this.height=t,this.dom.style.height=t+"px"),this.above!=n&&(this.dom.style.marginTop=(this.above=n)?n+"px":""),!function(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].compare(t[n]))return!1;return!0}(this.markers,r)&&this.setMarkers(e,r)}setMarkers(e,t){let n="cm-gutterElement",r=this.dom.firstChild;for(let i=0,s=0;;){let o=s,l=i<t.length?t[i++]:null,a=!1;if(l){let e=l.elementClass;e&&(n+=" "+e);for(let e=s;e<this.markers.length;e++)if(this.markers[e].compare(l)){o=e,a=!0;break}}else o=this.markers.length;for(;s<o;){let e=this.markers[s++];if(e.toDOM){e.destroy(r);let t=r.nextSibling;r.remove(),r=t}}if(!l)break;l.toDOM&&(a?r=r.nextSibling:this.dom.insertBefore(l.toDOM(e),r)),a&&s++}this.dom.className=n,this.markers=t}destroy(){this.setMarkers(null,[])}}let rb=l.r$.define(),rv=l.r$.define({combine:e=>(0,l.BO)(e,{formatNumber:String,domEventHandlers:{}},{domEventHandlers(e,t){let n=Object.assign({},e);for(let e in t){let r=n[e],i=t[e];n[e]=r?(e,t,n)=>r(e,t,n)||i(e,t,n):i}return n}})});class rk extends rs{constructor(e){super(),this.number=e}eq(e){return this.number==e.number}toDOM(){return document.createTextNode(this.number)}}function rw(e,t){return e.state.facet(rv).formatNumber(t,e.state)}let rD=ra.compute([rv],e=>({class:"cm-lineNumbers",renderEmptyElements:!1,markers:e=>e.state.facet(rb),lineMarker:(e,t,n)=>n.some(e=>e.toDOM)?null:new rk(rw(e,e.state.doc.lineAt(t.from).number)),widgetMarker:()=>null,lineMarkerChange:e=>e.startState.facet(rv)!=e.state.facet(rv),initialSpacer:e=>new rk(rw(e,rx(e.state.doc.lines))),updateSpacer(e,t){let n=rw(t.view,rx(t.view.state.doc.lines));return n==e.number?e:new rk(n)},domEventHandlers:e.facet(rv).domEventHandlers}));function rA(e={}){return[rv.of(e),rc(),rD]}function rx(e){let t=9;for(;t<e;)t=10*t+9;return t}let rC=new class extends rs{constructor(){super(...arguments),this.elementClass="cm-activeLineGutter"}},rE=ro.compute(["selection"],e=>{let t=[],n=-1;for(let r of e.selection.ranges){let i=e.doc.lineAt(r.head).from;i>n&&(n=i,t.push(rC.range(i)))}return l.Xs.of(t)});function rS(){return rE}let r_=new Map},7888:function(e,t,n){"use strict";var r,i;n.d(t,{Jq:function(){return c},L3:function(){return s},Lj:function(){return f},_b:function(){return B},i9:function(){return N},md:function(){return a},mp:function(){return m},vj:function(){return r}});let s=1024,o=0;class l{constructor(e,t){this.from=e,this.to=t}}class a{constructor(e={}){this.id=o++,this.perNode=!!e.perNode,this.deserialize=e.deserialize||(()=>{throw Error("This node type doesn't define a deserialize function")})}add(e){if(this.perNode)throw RangeError("Can't add per-node props to node types");return"function"!=typeof e&&(e=c.match(e)),t=>{let n=e(t);return void 0===n?null:[this,n]}}}a.closedBy=new a({deserialize:e=>e.split(" ")}),a.openedBy=new a({deserialize:e=>e.split(" ")}),a.group=new a({deserialize:e=>e.split(" ")}),a.isolate=new a({deserialize:e=>{if(e&&"rtl"!=e&&"ltr"!=e&&"auto"!=e)throw RangeError("Invalid value for isolate: "+e);return e||"auto"}}),a.contextHash=new a({perNode:!0}),a.lookAhead=new a({perNode:!0}),a.mounted=new a({perNode:!0});class u{constructor(e,t,n){this.tree=e,this.overlay=t,this.parser=n}static get(e){return e&&e.props&&e.props[a.mounted.id]}}let h=Object.create(null);class c{constructor(e,t,n,r=0){this.name=e,this.props=t,this.id=n,this.flags=r}static define(e){let t=e.props&&e.props.length?Object.create(null):h,n=(e.top?1:0)|(e.skipped?2:0)|(e.error?4:0)|(null==e.name?8:0),r=new c(e.name||"",t,e.id,n);if(e.props){for(let n of e.props)if(!Array.isArray(n)&&(n=n(r)),n){if(n[0].perNode)throw RangeError("Can't store a per-node prop on a node type");t[n[0].id]=n[1]}}return r}prop(e){return this.props[e.id]}get isTop(){return(1&this.flags)>0}get isSkipped(){return(2&this.flags)>0}get isError(){return(4&this.flags)>0}get isAnonymous(){return(8&this.flags)>0}is(e){if("string"==typeof e){if(this.name==e)return!0;let t=this.prop(a.group);return!!t&&t.indexOf(e)>-1}return this.id==e}static match(e){let t=Object.create(null);for(let n in e)for(let r of n.split(" "))t[r]=e[n];return e=>{for(let n=e.prop(a.group),r=-1;r<(n?n.length:0);r++){let i=t[r<0?e.name:n[r]];if(i)return i}}}}c.none=new c("",Object.create(null),0,8);class f{constructor(e){this.types=e;for(let t=0;t<e.length;t++)if(e[t].id!=t)throw RangeError("Node type ids should correspond to array positions when creating a node set")}extend(...e){let t=[];for(let n of this.types){let r=null;for(let t of e){let e=t(n);e&&(!r&&(r=Object.assign({},n.props)),r[e[0].id]=e[1])}t.push(r?new c(n.name,r,n.id,n.flags):n)}return new f(t)}}let d=new WeakMap,p=new WeakMap;(i=r||(r={}))[i.ExcludeBuffers=1]="ExcludeBuffers",i[i.IncludeAnonymous=2]="IncludeAnonymous",i[i.IgnoreMounts=4]="IgnoreMounts",i[i.IgnoreOverlays=8]="IgnoreOverlays";class m{constructor(e,t,n,r,i){if(this.type=e,this.children=t,this.positions=n,this.length=r,this.props=null,i&&i.length)for(let[e,t]of(this.props=Object.create(null),i))this.props["number"==typeof e?e:e.id]=t}toString(){let e=u.get(this);if(e&&!e.overlay)return e.tree.toString();let t="";for(let e of this.children){let n=e.toString();n&&(t&&(t+=","),t+=n)}return this.type.name?(/\W/.test(this.type.name)&&!this.type.isError?JSON.stringify(this.type.name):this.type.name)+(t.length?"("+t+")":""):t}cursor(e=0){return new _(this.topNode,e)}cursorAt(e,t=0,n=0){let r=new _(d.get(this)||this.topNode);return r.moveTo(e,t),d.set(this,r._tree),r}get topNode(){return new w(this,0,0,null)}resolve(e,t=0){let n=v(d.get(this)||this.topNode,e,t,!1);return d.set(this,n),n}resolveInner(e,t=0){let n=v(p.get(this)||this.topNode,e,t,!0);return p.set(this,n),n}resolveStack(e,t=0){return function(e,t,n){let r=e.resolveInner(t,n),i=null;for(let e=r instanceof w?r:r.context.parent;e;e=e.parent)if(e.index<0){let s=e.parent;(i||(i=[r])).push(s.resolve(t,n)),e=s}else{let s=u.get(e.tree);if(s&&s.overlay&&s.overlay[0].from<=t&&s.overlay[s.overlay.length-1].to>=t){let o=new w(s.tree,s.overlay[0].from+e.from,-1,e);(i||(i=[r])).push(v(o,t,n,!1))}}return i?E(i):r}(this,e,t)}iterate(e){let{enter:t,leave:n,from:i=0,to:s=this.length}=e,o=e.mode||0,l=(o&r.IncludeAnonymous)>0;for(let e=this.cursor(o|r.IncludeAnonymous);;){let r=!1;if(e.from<=s&&e.to>=i&&(!l&&e.type.isAnonymous||!1!==t(e))){if(e.firstChild())continue;r=!0}for(;r&&n&&(l||!e.type.isAnonymous)&&n(e),!e.nextSibling();){;if(!e.parent())return;r=!0}}}prop(e){return e.perNode?this.props?this.props[e.id]:void 0:this.type.prop(e)}get propValues(){let e=[];if(this.props)for(let t in this.props)e.push([+t,this.props[t]]);return e}balance(e={}){return this.children.length<=8?this:T(c.none,this.children,this.positions,0,this.children.length,0,this.length,(e,t,n)=>new m(this.type,e,t,n,this.propValues),e.makeTree||((e,t,n)=>new m(c.none,e,t,n)))}static build(e){return function(e){var t;let{buffer:n,nodeSet:r,maxBufferLength:i=s,reused:o=[],minRepeatType:l=r.types.length}=e,u=Array.isArray(n)?new g(n,n.length):n,h=r.types,c=0,f=0;function d(e,t,n,i,s,o,l,a){let u=[],h=[];for(;e.length>i;)u.push(e.pop()),h.push(t.pop()+n-s);e.push(p(r.types[l],u,h,o-s,a-o)),t.push(s-n)}function p(e,t,n,r,i=0,s){if(c){let e=[a.contextHash,c];s=s?[e].concat(s):[e]}if(i>25){let e=[a.lookAhead,i];s=s?[e].concat(s):[e]}return new m(e,t,n,r,s)}let b=[],v=[];for(;u.pos>0;)!function e(t,n,s,g,b,v){let{id:k,start:w,end:D,size:A}=u,x=f;for(;A<0;){if(u.next(),-1==A){let e=o[k];s.push(e),g.push(w-t);return}if(-3==A){c=k;return}else if(-4==A){f=k;return}else throw RangeError(`Unrecognized record size: ${A}`)}let C=h[k],E,S,_=w-t;if(D-w<=i&&(S=function(e,t){let n=u.fork(),r=0,s=0,o=0,a=n.end-i,h={size:0,start:0,skip:0};r:for(let i=n.pos-e;n.pos>i;){let e=n.size;if(n.id==t&&e>=0){h.size=r,h.start=s,h.skip=o,o+=4,r+=4,n.next();continue}let u=n.pos-e;if(e<0||u<i||n.start<a)break;let c=n.id>=l?4:0,f=n.start;for(n.next();n.pos>u;){if(n.size<0){if(-3==n.size)c+=4;else break r}else n.id>=l&&(c+=4);n.next()}s=f,r+=e,o+=c}return(t<0||r==e)&&(h.size=r,h.start=s,h.skip=o),h.size>4?h:void 0}(u.pos-n,b))){let e=new Uint16Array(S.size-S.skip),n=u.pos-S.size,i=e.length;for(;u.pos>n;)i=function e(t,n,r){let{id:i,start:s,end:o,size:a}=u;if(u.next(),a>=0&&i<l){let l=r;if(a>4){let i=u.pos-(a-4);for(;u.pos>i;)r=e(t,n,r)}n[--r]=l,n[--r]=o-t,n[--r]=s-t,n[--r]=i}else -3==a?c=i:-4==a&&(f=i);return r}(S.start,e,i);E=new y(e,D-S.start,r),_=S.start-t}else{let t=u.pos-A;u.next();let n=[],s=[],o=k>=l?k:-1,h=0,c=D;for(;u.pos>t;)o>=0&&u.id==o&&u.size>=0?(u.end<=c-i&&(d(n,s,w,h,u.end,c,o,x),h=n.length,c=u.end),u.next()):v>2500?function(e,t,n,s){let o=[],l=0,a=-1;for(;u.pos>t;){let{id:e,start:t,end:n,size:r}=u;if(r>4)u.next();else if(a>-1&&t<a)break;else a<0&&(a=n-i),o.push(e,t,n),l++,u.next()}if(l){let t=new Uint16Array(4*l),i=o[o.length-2];for(let e=o.length-3,n=0;e>=0;e-=3)t[n++]=o[e],t[n++]=o[e+1]-i,t[n++]=o[e+2]-i,t[n++]=n;n.push(new y(t,o[2]-i,r)),s.push(i-e)}}(w,t,n,s):e(w,t,n,s,o,v+1);if(o>=0&&h>0&&h<n.length&&d(n,s,w,h,w,c,o,x),n.reverse(),s.reverse(),o>-1&&h>0){let e=function(e){return(t,n,r)=>{let i=0,s=t.length-1,o,l;if(s>=0&&(o=t[s])instanceof m){if(!s&&o.type==e&&o.length==r)return o;(l=o.prop(a.lookAhead))&&(i=n[s]+o.length+l)}return p(e,t,n,r,i)}}(C);E=T(C,n,s,0,n.length,0,D-w,e,e)}else E=p(C,n,s,D-w,x-D)}s.push(E),g.push(_)}(e.start||0,e.bufferStart||0,b,v,-1,0);let k=null!==(t=e.length)&&void 0!==t?t:b.length?v[0]+b[0].length:0;return new m(h[e.topID],b.reverse(),v.reverse(),k)}(e)}}m.empty=new m(c.none,[],[],0);class g{constructor(e,t){this.buffer=e,this.index=t}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}get pos(){return this.index}next(){this.index-=4}fork(){return new g(this.buffer,this.index)}}class y{constructor(e,t,n){this.buffer=e,this.length=t,this.set=n}get type(){return c.none}toString(){let e=[];for(let t=0;t<this.buffer.length;)e.push(this.childString(t)),t=this.buffer[t+3];return e.join(",")}childString(e){let t=this.buffer[e],n=this.buffer[e+3],r=this.set.types[t],i=r.name;if(/\W/.test(i)&&!r.isError&&(i=JSON.stringify(i)),n==(e+=4))return i;let s=[];for(;e<n;)s.push(this.childString(e)),e=this.buffer[e+3];return i+"("+s.join(",")+")"}findChild(e,t,n,r,i){let{buffer:s}=this,o=-1;for(let l=e;l!=t&&(!b(i,r,s[l+1],s[l+2])||(o=l,!(n>0)));l=s[l+3]);return o}slice(e,t,n){let r=this.buffer,i=new Uint16Array(t-e),s=0;for(let o=e,l=0;o<t;){i[l++]=r[o++],i[l++]=r[o++]-n;let t=i[l++]=r[o++]-n;i[l++]=r[o++]-e,s=Math.max(s,t)}return new y(i,s,this.set)}}function b(e,t,n,r){switch(e){case -2:return n<t;case -1:return r>=t&&n<t;case 0:return n<t&&r>t;case 1:return n<=t&&r>t;case 2:return r>t;case 4:return!0}}function v(e,t,n,i){for(var s;e.from==e.to||(n<1?e.from>=t:e.from>t)||(n>-1?e.to<=t:e.to<t);){let t=!i&&e instanceof w&&e.index<0?null:e.parent;if(!t)return e;e=t}let o=i?0:r.IgnoreOverlays;if(i)for(let r=e,i=r.parent;i;i=(r=i).parent)r instanceof w&&r.index<0&&(null===(s=i.enter(t,n,o))||void 0===s?void 0:s.from)!=r.from&&(e=i);for(;;){let r=e.enter(t,n,o);if(!r)return e;e=r}}class k{cursor(e=0){return new _(this,e)}getChild(e,t=null,n=null){let r=D(this,e,t,n);return r.length?r[0]:null}getChildren(e,t=null,n=null){return D(this,e,t,n)}resolve(e,t=0){return v(this,e,t,!1)}resolveInner(e,t=0){return v(this,e,t,!0)}matchContext(e){return A(this,e)}enterUnfinishedNodesBefore(e){let t=this.childBefore(e),n=this;for(;t;){let e=t.lastChild;if(!e||e.to!=t.to)break;e.type.isError&&e.from==e.to?(n=t,t=e.prevSibling):t=e}return n}get node(){return this}get next(){return this.parent}}class w extends k{constructor(e,t,n,r){super(),this._tree=e,this.from=t,this.index=n,this._parent=r}get type(){return this._tree.type}get name(){return this._tree.type.name}get to(){return this.from+this._tree.length}nextChild(e,t,n,i,s=0){for(let o=this;;){for(let{children:l,positions:a}=o._tree,h=t>0?l.length:-1;e!=h;e+=t){let h=l[e],c=a[e]+o.from;if(b(i,n,c,c+h.length)){if(h instanceof y){if(s&r.ExcludeBuffers)continue;let l=h.findChild(0,h.buffer.length,t,n-c,i);if(l>-1)return new C(new x(o,h,e,c),null,l)}else if(s&r.IncludeAnonymous||!h.type.isAnonymous||O(h)){let l;if(!(s&r.IgnoreMounts)&&(l=u.get(h))&&!l.overlay)return new w(l.tree,c,e,o);let a=new w(h,c,e,o);return s&r.IncludeAnonymous||!a.type.isAnonymous?a:a.nextChild(t<0?h.children.length-1:0,t,n,i)}}}if(s&r.IncludeAnonymous||!o.type.isAnonymous)return null;if(e=o.index>=0?o.index+t:t<0?-1:o._parent._tree.children.length,!(o=o._parent))return null}}get firstChild(){return this.nextChild(0,1,0,4)}get lastChild(){return this.nextChild(this._tree.children.length-1,-1,0,4)}childAfter(e){return this.nextChild(0,1,e,2)}childBefore(e){return this.nextChild(this._tree.children.length-1,-1,e,-2)}enter(e,t,n=0){let i;if(!(n&r.IgnoreOverlays)&&(i=u.get(this._tree))&&i.overlay){let n=e-this.from;for(let{from:e,to:r}of i.overlay)if((t>0?e<=n:e<n)&&(t<0?r>=n:r>n))return new w(i.tree,i.overlay[0].from+this.from,-1,this)}return this.nextChild(0,1,e,t,n)}nextSignificantParent(){let e=this;for(;e.type.isAnonymous&&e._parent;)e=e._parent;return e}get parent(){return this._parent?this._parent.nextSignificantParent():null}get nextSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index+1,1,0,4):null}get prevSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index-1,-1,0,4):null}get tree(){return this._tree}toTree(){return this._tree}toString(){return this._tree.toString()}}function D(e,t,n,r){let i=e.cursor(),s=[];if(!i.firstChild())return s;if(null!=n){for(let e=!1;!e;)if(e=i.type.is(n),!i.nextSibling())return s}for(;;){if(null!=r&&i.type.is(r))return s;if(i.type.is(t)&&s.push(i.node),!i.nextSibling())return null==r?s:[]}}function A(e,t,n=t.length-1){for(let r=e.parent;n>=0;r=r.parent){if(!r)return!1;if(!r.type.isAnonymous){if(t[n]&&t[n]!=r.name)return!1;n--}}return!0}class x{constructor(e,t,n,r){this.parent=e,this.buffer=t,this.index=n,this.start=r}}class C extends k{get name(){return this.type.name}get from(){return this.context.start+this.context.buffer.buffer[this.index+1]}get to(){return this.context.start+this.context.buffer.buffer[this.index+2]}constructor(e,t,n){super(),this.context=e,this._parent=t,this.index=n,this.type=e.buffer.set.types[e.buffer.buffer[n]]}child(e,t,n){let{buffer:r}=this.context,i=r.findChild(this.index+4,r.buffer[this.index+3],e,t-this.context.start,n);return i<0?null:new C(this.context,this,i)}get firstChild(){return this.child(1,0,4)}get lastChild(){return this.child(-1,0,4)}childAfter(e){return this.child(1,e,2)}childBefore(e){return this.child(-1,e,-2)}enter(e,t,n=0){if(n&r.ExcludeBuffers)return null;let{buffer:i}=this.context,s=i.findChild(this.index+4,i.buffer[this.index+3],t>0?1:-1,e-this.context.start,t);return s<0?null:new C(this.context,this,s)}get parent(){return this._parent||this.context.parent.nextSignificantParent()}externalSibling(e){return this._parent?null:this.context.parent.nextChild(this.context.index+e,e,0,4)}get nextSibling(){let{buffer:e}=this.context,t=e.buffer[this.index+3];return t<(this._parent?e.buffer[this._parent.index+3]:e.buffer.length)?new C(this.context,this._parent,t):this.externalSibling(1)}get prevSibling(){let{buffer:e}=this.context,t=this._parent?this._parent.index+4:0;return this.index==t?this.externalSibling(-1):new C(this.context,this._parent,e.findChild(t,this.index,-1,0,4))}get tree(){return null}toTree(){let e=[],t=[],{buffer:n}=this.context,r=this.index+4,i=n.buffer[this.index+3];if(i>r){let s=n.buffer[this.index+1];e.push(n.slice(r,i,s)),t.push(0)}return new m(this.type,e,t,this.to-this.from)}toString(){return this.context.buffer.childString(this.index)}}function E(e){if(!e.length)return null;let t=0,n=e[0];for(let r=1;r<e.length;r++){let i=e[r];(i.from>n.from||i.to<n.to)&&(n=i,t=r)}let r=n instanceof w&&n.index<0?null:n.parent,i=e.slice();return r?i[t]=r:i.splice(t,1),new S(i,n)}class S{constructor(e,t){this.heads=e,this.node=t}get next(){return E(this.heads)}}class _{get name(){return this.type.name}constructor(e,t=0){if(this.mode=t,this.buffer=null,this.stack=[],this.index=0,this.bufferNode=null,e instanceof w)this.yieldNode(e);else{this._tree=e.context.parent,this.buffer=e.context;for(let t=e._parent;t;t=t._parent)this.stack.unshift(t.index);this.bufferNode=e,this.yieldBuf(e.index)}}yieldNode(e){return!!e&&(this._tree=e,this.type=e.type,this.from=e.from,this.to=e.to,!0)}yieldBuf(e,t){this.index=e;let{start:n,buffer:r}=this.buffer;return this.type=t||r.set.types[r.buffer[e]],this.from=n+r.buffer[e+1],this.to=n+r.buffer[e+2],!0}yield(e){return!!e&&(e instanceof w?(this.buffer=null,this.yieldNode(e)):(this.buffer=e.context,this.yieldBuf(e.index,e.type)))}toString(){return this.buffer?this.buffer.buffer.childString(this.index):this._tree.toString()}enterChild(e,t,n){if(!this.buffer)return this.yield(this._tree.nextChild(e<0?this._tree._tree.children.length-1:0,e,t,n,this.mode));let{buffer:r}=this.buffer,i=r.findChild(this.index+4,r.buffer[this.index+3],e,t-this.buffer.start,n);return!(i<0)&&(this.stack.push(this.index),this.yieldBuf(i))}firstChild(){return this.enterChild(1,0,4)}lastChild(){return this.enterChild(-1,0,4)}childAfter(e){return this.enterChild(1,e,2)}childBefore(e){return this.enterChild(-1,e,-2)}enter(e,t,n=this.mode){return this.buffer?!(n&r.ExcludeBuffers)&&this.enterChild(1,e,t):this.yield(this._tree.enter(e,t,n))}parent(){if(!this.buffer)return this.yieldNode(this.mode&r.IncludeAnonymous?this._tree._parent:this._tree.parent);if(this.stack.length)return this.yieldBuf(this.stack.pop());let e=this.mode&r.IncludeAnonymous?this.buffer.parent:this.buffer.parent.nextSignificantParent();return this.buffer=null,this.yieldNode(e)}sibling(e){if(!this.buffer)return!!this._tree._parent&&this.yield(this._tree.index<0?null:this._tree._parent.nextChild(this._tree.index+e,e,0,4,this.mode));let{buffer:t}=this.buffer,n=this.stack.length-1;if(e<0){let e=n<0?0:this.stack[n]+4;if(this.index!=e)return this.yieldBuf(t.findChild(e,this.index,-1,0,4))}else{let e=t.buffer[this.index+3];if(e<(n<0?t.buffer.length:t.buffer[this.stack[n]+3]))return this.yieldBuf(e)}return n<0&&this.yield(this.buffer.parent.nextChild(this.buffer.index+e,e,0,4,this.mode))}nextSibling(){return this.sibling(1)}prevSibling(){return this.sibling(-1)}atLastNode(e){let t,n,{buffer:i}=this;if(i){if(e>0){if(this.index<i.buffer.buffer.length)return!1}else for(let e=0;e<this.index;e++)if(i.buffer.buffer[e+3]<this.index)return!1;({index:t,parent:n}=i)}else({index:t,_parent:n}=this._tree);for(;n;{index:t,_parent:n}=n)if(t>-1)for(let i=t+e,s=e<0?-1:n._tree.children.length;i!=s;i+=e){let e=n._tree.children[i];if(this.mode&r.IncludeAnonymous||e instanceof y||!e.type.isAnonymous||O(e))return!1}return!0}move(e,t){if(t&&this.enterChild(e,0,4))return!0;for(;;){if(this.sibling(e))return!0;if(this.atLastNode(e)||!this.parent())return!1}}next(e=!0){return this.move(1,e)}prev(e=!0){return this.move(-1,e)}moveTo(e,t=0){for(;(this.from==this.to||(t<1?this.from>=e:this.from>e)||(t>-1?this.to<=e:this.to<e))&&this.parent(););for(;this.enterChild(1,e,t););return this}get node(){if(!this.buffer)return this._tree;let e=this.bufferNode,t=null,n=0;if(e&&e.context==this.buffer)r:for(let r=this.index,i=this.stack.length;i>=0;){for(let s=e;s;s=s._parent)if(s.index==r){if(r==this.index)return s;t=s,n=i+1;break r}r=this.stack[--i]}for(let e=n;e<this.stack.length;e++)t=new C(this.buffer,t,this.stack[e]);return this.bufferNode=new C(this.buffer,t,this.index)}get tree(){return this.buffer?null:this._tree._tree}iterate(e,t){for(let n=0;;){let r=!1;if(this.type.isAnonymous||!1!==e(this)){if(this.firstChild()){n++;continue}!this.type.isAnonymous&&(r=!0)}for(;r&&t&&t(this),r=this.type.isAnonymous,!this.nextSibling();){;if(!n)return;this.parent(),n--,r=!0}}}matchContext(e){if(!this.buffer)return A(this.node,e);let{buffer:t}=this.buffer,{types:n}=t.set;for(let r=e.length-1,i=this.stack.length-1;r>=0;i--){if(i<0)return A(this.node,e,r);let s=n[t.buffer[this.stack[i]]];if(!s.isAnonymous){if(e[r]&&e[r]!=s.name)return!1;r--}}return!0}}function O(e){return e.children.some(e=>e instanceof y||!e.type.isAnonymous||O(e))}let F=new WeakMap;function P(e,t){if(!e.isAnonymous||t instanceof y||t.type!=e)return 1;let n=F.get(t);if(null==n){for(let r of(n=1,t.children)){if(r.type!=e||!(r instanceof m)){n=1;break}n+=P(e,r)}F.set(t,n)}return n}function T(e,t,n,r,i,s,o,l,a){let u=0;for(let n=r;n<i;n++)u+=P(e,t[n]);let h=Math.ceil(1.5*u/8),c=[],f=[];return!function t(n,r,i,o,l){for(let u=i;u<o;){let i=u,d=r[u],p=P(e,n[u]);for(u++;u<o;u++){let t=P(e,n[u]);if(p+t>=h)break;p+=t}if(u==i+1){if(p>h){let e=n[i];t(e.children,e.positions,0,e.children.length,r[i]+l);continue}c.push(n[i])}else{let t=r[u-1]+n[u-1].length-d;c.push(T(e,n,r,i,u,d,t,null,a))}f.push(d+l-s)}}(t,n,r,i,0),(l||a)(c,f,o)}class N{constructor(e,t,n,r,i=!1,s=!1){this.from=e,this.to=t,this.tree=n,this.offset=r,this.open=(i?1:0)|(s?2:0)}get openStart(){return(1&this.open)>0}get openEnd(){return(2&this.open)>0}static addTree(e,t=[],n=!1){let r=[new N(0,e.length,e,0,!1,n)];for(let n of t)n.to>e.length&&r.push(n);return r}static applyChanges(e,t,n=128){if(!t.length)return e;let r=[],i=1,s=e.length?e[0]:null;for(let o=0,l=0,a=0;;o++){let u=o<t.length?t[o]:null,h=u?u.fromA:1e9;if(h-l>=n)for(;s&&s.from<h;){let t=s;if(l>=t.from||h<=t.to||a){let e=Math.max(t.from,l)-a,n=Math.min(t.to,h)-a;t=e>=n?null:new N(e,n,t.tree,t.offset+a,o>0,!!u)}if(t&&r.push(t),s.to>h)break;s=i<e.length?e[i++]:null}if(!u)break;l=u.toA,a=u.toA-u.toB}return r}}class B{startParse(e,t,n){return"string"==typeof e&&(e=new I(e)),n=n?n.length?n.map(e=>new l(e.from,e.to)):[new l(0,0)]:[new l(0,e.length)],this.createParse(e,t||[],n)}parse(e,t,n){let r=this.startParse(e,t,n);for(;;){let e=r.advance();if(e)return e}}}class I{constructor(e){this.string=e}get length(){return this.string.length}chunk(e){return this.string.slice(e)}get lineChunks(){return!1}read(e,t){return this.string.slice(e,t)}}new a({perNode:!0})},42367:function(e,t,n){"use strict";n.d(t,{Gv:function(){return a},QR:function(){return c},bW:function(){return f},pJ:function(){return O}});var r=n(7888);let i=0;class s{constructor(e,t,n){this.set=e,this.base=t,this.modified=n,this.id=i++}static define(e){if(null==e?void 0:e.base)throw Error("Can not derive from a modified tag");let t=new s([],null,[]);if(t.set.push(t),e)for(let n of e.set)t.set.push(n);return t}static defineModifier(){let e=new l;return t=>t.modified.indexOf(e)>-1?t:l.get(t.base||t,t.modified.concat(e).sort((e,t)=>e.id-t.id))}}let o=0;class l{constructor(){this.instances=[],this.id=o++}static get(e,t){if(!t.length)return e;let n=t[0].instances.find(n=>n.base==e&&function(e,t){return e.length==t.length&&e.every((e,n)=>e==t[n])}(t,n.modified));if(n)return n;let r=[],i=new s(r,e,t);for(let e of t)e.instances.push(i);let o=function(e){let t=[[]];for(let n=0;n<e.length;n++)for(let r=0,i=t.length;r<i;r++)t.push(t[r].concat(e[n]));return t.sort((e,t)=>t.length-e.length)}(t);for(let t of e.set)if(!t.modified.length)for(let e of o)r.push(l.get(t,e));return i}}function a(e){let t=Object.create(null);for(let n in e){let r=e[n];for(let e of(!Array.isArray(r)&&(r=[r]),n.split(" ")))if(e){let n=[],i=2,s=e;for(let t=0;;){if("..."==s&&t>0&&t+3==e.length){i=1;break}let r=/^"(?:[^"\\]|\\.)*?"|[^\/!]+/.exec(s);if(!r)throw RangeError("Invalid path: "+e);if(n.push("*"==r[0]?"":'"'==r[0][0]?JSON.parse(r[0]):r[0]),(t+=r[0].length)==e.length)break;let o=e[t++];if(t==e.length&&"!"==o){i=0;break}if("/"!=o)throw RangeError("Invalid path: "+e);s=e.slice(t)}let o=n.length-1,l=n[o];if(!l)throw RangeError("Invalid path: "+e);let a=new h(r,i,o>0?n.slice(0,o):null);t[l]=a.sort(t[l])}}return u.add(t)}let u=new r.md;class h{constructor(e,t,n,r){this.tags=e,this.mode=t,this.context=n,this.next=r}get opaque(){return 0==this.mode}get inherit(){return 1==this.mode}sort(e){return!e||e.depth<this.depth?(this.next=e,this):(e.next=this.sort(e.next),e)}get depth(){return this.context?this.context.length:0}}function c(e,t){let n=Object.create(null);for(let t of e)if(Array.isArray(t.tag))for(let e of t.tag)n[e.id]=t.class;else n[t.tag.id]=t.class;let{scope:r,all:i=null}=t||{};return{style:e=>{let t=i;for(let r of e)for(let e of r.set){let r=n[e.id];if(r){t=t?t+" "+r:r;break}}return t},scope:r}}h.empty=new h([],2,null);function f(e,t,n,r=0,i=e.length){let s=new d(r,Array.isArray(t)?t:[t],n);s.highlightRange(e.cursor(),r,i,"",s.highlighters),s.flush(i)}class d{constructor(e,t,n){this.at=e,this.highlighters=t,this.span=n,this.class=""}startSpan(e,t){t!=this.class&&(this.flush(e),e>this.at&&(this.at=e),this.class=t)}flush(e){e>this.at&&this.class&&this.span(this.at,e,this.class)}highlightRange(e,t,n,i,s){let{type:o,from:l,to:a}=e;if(l>=n||a<=t)return;o.isTop&&(s=this.highlighters.filter(e=>!e.scope||e.scope(o)));let c=i,f=function(e){let t=e.type.prop(u);for(;t&&t.context&&!e.matchContext(t.context);)t=t.next;return t||null}(e)||h.empty,d=function(e,t){let n=null;for(let r of e){let e=r.style(t);e&&(n=n?n+" "+e:e)}return n}(s,f.tags);if(d&&(c&&(c+=" "),c+=d,1==f.mode&&(i+=(i?" ":"")+d)),this.startSpan(Math.max(t,l),c),f.opaque)return;let p=e.tree&&e.tree.prop(r.md.mounted);if(p&&p.overlay){let r=e.node.enter(p.overlay[0].from+l,1),o=this.highlighters.filter(e=>!e.scope||e.scope(p.tree.type)),u=e.firstChild();for(let h=0,f=l;;h++){let d=h<p.overlay.length?p.overlay[h]:null,m=d?d.from+l:a,g=Math.max(t,f),y=Math.min(n,m);if(g<y&&u)for(;e.from<y&&(this.highlightRange(e,g,y,i,s),this.startSpan(Math.min(y,e.to),c),!(e.to>=m)&&e.nextSibling()););if(!d||m>n)break;(f=d.to+l)>t&&(this.highlightRange(r.cursor(),Math.max(t,d.from+l),Math.min(n,f),"",o),this.startSpan(Math.min(n,f),c))}u&&e.parent()}else if(e.firstChild()){p&&(i="");do{if(e.to<=t)continue;if(e.from>=n)break;this.highlightRange(e,t,n,i,s),this.startSpan(Math.min(n,e.to),c)}while(e.nextSibling());e.parent()}}}let p=s.define,m=p(),g=p(),y=p(g),b=p(g),v=p(),k=p(v),w=p(v),D=p(),A=p(D),x=p(),C=p(),E=p(),S=p(E),_=p(),O={comment:m,lineComment:p(m),blockComment:p(m),docComment:p(m),name:g,variableName:p(g),typeName:y,tagName:p(y),propertyName:b,attributeName:p(b),className:p(g),labelName:p(g),namespace:p(g),macroName:p(g),literal:v,string:k,docString:p(k),character:p(k),attributeValue:p(k),number:w,integer:p(w),float:p(w),bool:p(v),regexp:p(v),escape:p(v),color:p(v),url:p(v),keyword:x,self:p(x),null:p(x),atom:p(x),unit:p(x),modifier:p(x),operatorKeyword:p(x),controlKeyword:p(x),definitionKeyword:p(x),moduleKeyword:p(x),operator:C,derefOperator:p(C),arithmeticOperator:p(C),logicOperator:p(C),bitwiseOperator:p(C),compareOperator:p(C),updateOperator:p(C),definitionOperator:p(C),typeOperator:p(C),controlOperator:p(C),punctuation:E,separator:p(E),bracket:S,angleBracket:p(S),squareBracket:p(S),paren:p(S),brace:p(S),content:D,heading:A,heading1:p(A),heading2:p(A),heading3:p(A),heading4:p(A),heading5:p(A),heading6:p(A),contentSeparator:p(D),list:p(D),quote:p(D),emphasis:p(D),strong:p(D),link:p(D),monospace:p(D),strikethrough:p(D),inserted:p(),deleted:p(),changed:p(),invalid:p(),meta:_,documentMeta:p(_),annotation:p(_),processingInstruction:p(_),definition:s.defineModifier(),constant:s.defineModifier(),function:s.defineModifier(),standard:s.defineModifier(),local:s.defineModifier(),special:s.defineModifier()};c([{tag:O.link,class:"tok-link"},{tag:O.heading,class:"tok-heading"},{tag:O.emphasis,class:"tok-emphasis"},{tag:O.strong,class:"tok-strong"},{tag:O.keyword,class:"tok-keyword"},{tag:O.atom,class:"tok-atom"},{tag:O.bool,class:"tok-bool"},{tag:O.url,class:"tok-url"},{tag:O.labelName,class:"tok-labelName"},{tag:O.inserted,class:"tok-inserted"},{tag:O.deleted,class:"tok-deleted"},{tag:O.literal,class:"tok-literal"},{tag:O.string,class:"tok-string"},{tag:O.number,class:"tok-number"},{tag:[O.regexp,O.escape,O.special(O.string)],class:"tok-string2"},{tag:O.variableName,class:"tok-variableName"},{tag:O.local(O.variableName),class:"tok-variableName tok-local"},{tag:O.definition(O.variableName),class:"tok-variableName tok-definition"},{tag:O.special(O.variableName),class:"tok-variableName2"},{tag:O.definition(O.propertyName),class:"tok-propertyName tok-definition"},{tag:O.typeName,class:"tok-typeName"},{tag:O.namespace,class:"tok-namespace"},{tag:O.className,class:"tok-className"},{tag:O.macroName,class:"tok-macroName"},{tag:O.propertyName,class:"tok-propertyName"},{tag:O.operator,class:"tok-operator"},{tag:O.comment,class:"tok-comment"},{tag:O.meta,class:"tok-meta"},{tag:O.invalid,class:"tok-invalid"},{tag:O.punctuation,class:"tok-punctuation"}])},81965:function(e,t,n){"use strict";n.d(t,{V:function(){return o}});let r="undefined"==typeof Symbol?"__ͼ":Symbol.for("ͼ"),i="undefined"==typeof Symbol?"__styleSet"+Math.floor(1e8*Math.random()):Symbol("styleSet"),s="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:{};class o{constructor(e,t){this.rules=[];let{finish:n}=t||{};function r(e){return/^@/.test(e)?[e]:e.split(/,\s*/)}for(let t in e)!function e(t,i,s,o){let l=[],a=/^@(\w+)\b/.exec(t[0]),u=a&&"keyframes"==a[1];if(a&&null==i)return s.push(t[0]+";");for(let n in i){let o=i[n];if(/&/.test(n))e(n.split(/,\s*/).map(e=>t.map(t=>e.replace(/&/,t))).reduce((e,t)=>e.concat(t)),o,s);else if(o&&"object"==typeof o){if(!a)throw RangeError("The value of a property ("+n+") should be a primitive value.");e(r(n),o,l,u)}else null!=o&&l.push(n.replace(/_.*/,"").replace(/[A-Z]/g,e=>"-"+e.toLowerCase())+": "+o+";")}(l.length||u)&&s.push((!n||a||o?t:t.map(n)).join(", ")+" {"+l.join(" ")+"}")}(r(t),e[t],this.rules)}getRules(){return this.rules.join("\n")}static newName(){let e=s[r]||1;return s[r]=e+1,"ͼ"+e.toString(36)}static mount(e,t,n){let r=e[i],s=n&&n.nonce;r?s&&r.setNonce(s):r=new a(e,s),r.mount(Array.isArray(t)?t:[t],e)}}let l=new Map;class a{constructor(e,t){let n=e.ownerDocument||e,r=n.defaultView;if(!e.head&&e.adoptedStyleSheets&&r.CSSStyleSheet){let t=l.get(n);if(t)return e[i]=t;this.sheet=new r.CSSStyleSheet,l.set(n,this)}else this.styleTag=n.createElement("style"),t&&this.styleTag.setAttribute("nonce",t);this.modules=[],e[i]=this}mount(e,t){let n=this.sheet,r=0,i=0;for(let t=0;t<e.length;t++){let s=e[t],o=this.modules.indexOf(s);if(o<i&&o>-1&&(this.modules.splice(o,1),i--,o=-1),-1==o){if(this.modules.splice(i++,0,s),n)for(let e=0;e<s.rules.length;e++)n.insertRule(s.rules[e],r++)}else{for(;i<o;)r+=this.modules[i++].rules.length;r+=s.rules.length,i++}}if(n)0>t.adoptedStyleSheets.indexOf(this.sheet)&&(t.adoptedStyleSheets=[this.sheet,...t.adoptedStyleSheets]);else{let e="";for(let t=0;t<this.modules.length;t++)e+=this.modules[t].getRules()+"\n";this.styleTag.textContent=e;let n=t.head||t;this.styleTag.parentNode!=n&&n.insertBefore(this.styleTag,n.firstChild)}}setNonce(e){this.styleTag&&this.styleTag.getAttribute("nonce")!=e&&this.styleTag.setAttribute("nonce",e)}}},83582:function(e,t,n){"use strict";n.d(t,{B1:function(){return eE},GA:function(){return ek},Gn:function(){return ea},vQ:function(){return ep},ys:function(){return eC}});var r,i,s=n(8954),o=n(76621),l=n(85237);class a{constructor(e,t,n,r){this.state=e,this.pos=t,this.explicit=n,this.view=r,this.abortListeners=[],this.abortOnDocChange=!1}tokenBefore(e){let t=(0,l.qz)(this.state).resolveInner(this.pos,-1);for(;t&&0>e.indexOf(t.name);)t=t.parent;return t?{from:t.from,to:this.pos,text:this.state.sliceDoc(t.from,this.pos),type:t.type}:null}matchBefore(e){let t=this.state.doc.lineAt(this.pos),n=Math.max(t.from,this.pos-250),r=t.text.slice(n-t.from,this.pos-t.from),i=r.search(f(e,!1));return i<0?null:{from:n+i,to:this.pos,text:r.slice(i)}}get aborted(){return null==this.abortListeners}addEventListener(e,t,n){"abort"==e&&this.abortListeners&&(this.abortListeners.push(t),n&&n.onDocChange&&(this.abortOnDocChange=!0))}}function u(e){let t=Object.keys(e).join(""),n=/\w/.test(t);return n&&(t=t.replace(/\w/g,"")),`[${n?"\\w":""}${t.replace(/[^\w\s]/g,"\\$&")}]`}class h{constructor(e,t,n,r){this.completion=e,this.source=t,this.match=n,this.score=r}}function c(e){return e.selection.main.from}function f(e,t){var n;let{source:r}=e,i=t&&"^"!=r[0],s="$"!=r[r.length-1];return i||s?RegExp(`${i?"^":""}(?:${r})${s?"$":""}`,null!==(n=e.flags)&&void 0!==n?n:e.ignoreCase?"i":""):e}let d=s.q6.define(),p=new WeakMap;function m(e){if(!Array.isArray(e))return e;let t=p.get(e);return!t&&p.set(e,t=function(e){let t=e.map(e=>"string"==typeof e?{label:e}:e),[n,r]=t.every(e=>/^\w+$/.test(e.label))?[/\w*$/,/\w+$/]:function(e){let t=Object.create(null),n=Object.create(null);for(let{label:r}of e){t[r[0]]=!0;for(let e=1;e<r.length;e++)n[r[e]]=!0}let r=u(t)+u(n)+"*$";return[RegExp("^"+r),new RegExp(r)]}(t);return e=>{let i=e.matchBefore(r);return i||e.explicit?{from:i?i.from:e.pos,options:t,validFor:n}:null}}(e)),t}let g=s.Py.define(),y=s.Py.define();class b{constructor(e){this.pattern=e,this.chars=[],this.folded=[],this.any=[],this.precise=[],this.byWord=[],this.score=0,this.matched=[];for(let t=0;t<e.length;){let n=(0,s.gm)(e,t),r=(0,s.nZ)(n);this.chars.push(n);let i=e.slice(t,t+r),o=i.toUpperCase();this.folded.push((0,s.gm)(o==i?i.toLowerCase():o,0)),t+=r}this.astral=e.length!=this.chars.length}ret(e,t){return this.score=e,this.matched=t,this}match(e){if(0==this.pattern.length)return this.ret(-100,[]);if(e.length<this.pattern.length)return null;let{chars:t,folded:n,any:r,precise:i,byWord:o}=this;if(1==t.length){let r=(0,s.gm)(e,0),i=(0,s.nZ)(r),o=i==e.length?0:-100;if(r==t[0]);else{if(r!=n[0])return null;o+=-200}return this.ret(o,[0,i])}let l=e.indexOf(this.pattern);if(0==l)return this.ret(e.length==this.pattern.length?0:-100,[0,this.pattern.length]);let a=t.length,u=0;if(l<0){for(let i=0,o=Math.min(e.length,200);i<o&&u<a;){let o=(0,s.gm)(e,i);(o==t[u]||o==n[u])&&(r[u++]=i),i+=(0,s.nZ)(o)}if(u<a)return null}let h=0,c=0,f=!1,d=0,p=-1,m=-1,g=/[a-z]/.test(e),y=!0;for(let r=0,u=Math.min(e.length,200),b=0;r<u&&c<a;){let u=(0,s.gm)(e,r);l<0&&(h<a&&u==t[h]&&(i[h++]=r),d<a&&(u==t[d]||u==n[d]?(0==d&&(p=r),m=r+1,d++):d=0));let v,k=u<255?u>=48&&u<=57||u>=97&&u<=122?2:u>=65&&u<=90?1:0:(v=(0,s.bg)(u))!=v.toLowerCase()?1:v!=v.toUpperCase()?2:0;(!r||1==k&&g||0==b&&0!=k)&&(t[c]==u||n[c]==u&&(f=!0)?o[c++]=r:o.length&&(y=!1)),b=k,r+=(0,s.nZ)(u)}return c==a&&0==o[0]&&y?this.result(-100+(f?-200:0),o,e):d==a&&0==p?this.ret(-200-e.length+(m==e.length?0:-100),[0,m]):l>-1?this.ret(-700-e.length,[l,l+this.pattern.length]):d==a?this.ret(-900-e.length,[p,m]):c==a?this.result(-100+(f?-200:0)+-700+(y?0:-1100),o,e):2==t.length?null:this.result((r[0]?-700:0)+-200+-1100,r,e)}result(e,t,n){let r=[],i=0;for(let e of t){let t=e+(this.astral?(0,s.nZ)((0,s.gm)(n,e)):1);i&&r[i-1]==e?r[i-1]=t:(r[i++]=e,r[i++]=t)}return this.ret(e-n.length,r)}}class v{constructor(e){this.pattern=e,this.matched=[],this.score=0,this.folded=e.toLowerCase()}match(e){if(e.length<this.pattern.length)return null;let t=e.slice(0,this.pattern.length),n=t==this.pattern?0:t.toLowerCase()==this.folded?-200:null;return null==n?null:(this.matched=[0,t.length],this.score=n+(e.length==this.pattern.length?0:-100),this)}}let k=s.r$.define({combine:e=>(0,s.BO)(e,{activateOnTyping:!0,activateOnCompletion:()=>!1,activateOnTypingDelay:100,selectOnOpen:!0,override:null,closeOnBlur:!0,maxRenderedOptions:100,defaultKeymap:!0,tooltipClass:()=>"",optionClass:()=>"",aboveCursor:!1,icons:!0,addToOptions:[],positionInfo:D,filterStrict:!1,compareCompletions:(e,t)=>e.label.localeCompare(t.label),interactionDelay:75,updateSyncTime:100},{defaultKeymap:(e,t)=>e&&t,closeOnBlur:(e,t)=>e&&t,icons:(e,t)=>e&&t,tooltipClass:(e,t)=>n=>w(e(n),t(n)),optionClass:(e,t)=>n=>w(e(n),t(n)),addToOptions:(e,t)=>e.concat(t),filterStrict:(e,t)=>e||t})});function w(e,t){return e?t?e+" "+t:e:t}function D(e,t,n,r,i,s){let l=e.textDirection==o.Nm.RTL,a=l,u=!1,h="top",c,f,d=t.left-i.left,p=i.right-t.right,m=r.right-r.left,g=r.bottom-r.top;if(a&&d<Math.min(m,p)?a=!1:!a&&p<Math.min(m,d)&&(a=!0),m<=(a?d:p))c=Math.max(i.top,Math.min(n.top,i.bottom-g))-t.top,f=Math.min(400,a?d:p);else{u=!0,f=Math.min(400,(l?t.right:i.right-t.left)-30);let e=i.bottom-t.bottom;e>=g||e>t.top?c=n.bottom-t.top:(h="bottom",c=t.bottom-n.top)}let y=(t.bottom-t.top)/s.offsetHeight,b=(t.right-t.left)/s.offsetWidth;return{style:`${h}: ${c/y}px; max-width: ${f/b}px`,class:"cm-completionInfo-"+(u?l?"left-narrow":"right-narrow":a?"left":"right")}}function A(e,t,n){if(e<=n)return{from:0,to:e};if(t<0&&(t=0),t<=e>>1){let e=Math.floor(t/n);return{from:e*n,to:(e+1)*n}}let r=Math.floor((e-t)/n);return{from:e-(r+1)*n,to:e-r*n}}class x{constructor(e,t,n){var r;let i;this.view=e,this.stateField=t,this.applyCompletion=n,this.info=null,this.infoDestroy=null,this.placeInfoReq={read:()=>this.measureInfo(),write:e=>this.placeInfo(e),key:this},this.space=null,this.currentClass="";let s=e.state.field(t),{options:o,selected:l}=s.open,a=e.state.facet(k);this.optionContent=(i=(r=a).addToOptions.slice(),r.icons&&i.push({render(e){let t=document.createElement("div");return t.classList.add("cm-completionIcon"),e.type&&t.classList.add(...e.type.split(/\s+/g).map(e=>"cm-completionIcon-"+e)),t.setAttribute("aria-hidden","true"),t},position:20}),i.push({render(e,t,n,r){let i=document.createElement("span");i.className="cm-completionLabel";let s=e.displayLabel||e.label,o=0;for(let e=0;e<r.length;){let t=r[e++],n=r[e++];t>o&&i.appendChild(document.createTextNode(s.slice(o,t)));let l=i.appendChild(document.createElement("span"));l.appendChild(document.createTextNode(s.slice(t,n))),l.className="cm-completionMatchedText",o=n}return o<s.length&&i.appendChild(document.createTextNode(s.slice(o))),i},position:50},{render(e){if(!e.detail)return null;let t=document.createElement("span");return t.className="cm-completionDetail",t.textContent=e.detail,t},position:80}),i.sort((e,t)=>e.position-t.position).map(e=>e.render)),this.optionClass=a.optionClass,this.tooltipClass=a.tooltipClass,this.range=A(o.length,l,a.maxRenderedOptions),this.dom=document.createElement("div"),this.dom.className="cm-tooltip-autocomplete",this.updateTooltipClass(e.state),this.dom.addEventListener("mousedown",n=>{let{options:r}=e.state.field(t).open;for(let t=n.target,i;t&&t!=this.dom;t=t.parentNode)if("LI"==t.nodeName&&(i=/-(\d+)$/.exec(t.id))&&+i[1]<r.length){this.applyCompletion(e,r[+i[1]]),n.preventDefault();return}}),this.dom.addEventListener("focusout",t=>{let n=e.state.field(this.stateField,!1);n&&n.tooltip&&e.state.facet(k).closeOnBlur&&t.relatedTarget!=e.contentDOM&&e.dispatch({effects:y.of(null)})}),this.showOptions(o,s.id)}mount(){this.updateSel()}showOptions(e,t){this.list&&this.list.remove(),this.list=this.dom.appendChild(this.createListBox(e,t,this.range)),this.list.addEventListener("scroll",()=>{this.info&&this.view.requestMeasure(this.placeInfoReq)})}update(e){var t;let n=e.state.field(this.stateField),r=e.startState.field(this.stateField);if(this.updateTooltipClass(e.state),n!=r){let{options:i,selected:s,disabled:o}=n.open;(!r.open||r.open.options!=i)&&(this.range=A(i.length,s,e.state.facet(k).maxRenderedOptions),this.showOptions(i,n.id)),this.updateSel(),o!=(null===(t=r.open)||void 0===t?void 0:t.disabled)&&this.dom.classList.toggle("cm-tooltip-autocomplete-disabled",!!o)}}updateTooltipClass(e){let t=this.tooltipClass(e);if(t!=this.currentClass){for(let e of this.currentClass.split(" "))e&&this.dom.classList.remove(e);for(let e of t.split(" "))e&&this.dom.classList.add(e);this.currentClass=t}}positioned(e){this.space=e,this.info&&this.view.requestMeasure(this.placeInfoReq)}updateSel(){let e=this.view.state.field(this.stateField),t=e.open;if((t.selected>-1&&t.selected<this.range.from||t.selected>=this.range.to)&&(this.range=A(t.options.length,t.selected,this.view.state.facet(k).maxRenderedOptions),this.showOptions(t.options,e.id)),this.updateSelectedOption(t.selected)){this.destroyInfo();let{completion:n}=t.options[t.selected],{info:r}=n;if(!r)return;let i="string"==typeof r?document.createTextNode(r):r(n);if(!i)return;"then"in i?i.then(t=>{t&&this.view.state.field(this.stateField,!1)==e&&this.addInfoPane(t,n)}).catch(e=>(0,o.OO)(this.view.state,e,"completion info")):this.addInfoPane(i,n)}}addInfoPane(e,t){this.destroyInfo();let n=this.info=document.createElement("div");if(n.className="cm-tooltip cm-completionInfo",null!=e.nodeType)n.appendChild(e),this.infoDestroy=null;else{let{dom:t,destroy:r}=e;n.appendChild(t),this.infoDestroy=r||null}this.dom.appendChild(n),this.view.requestMeasure(this.placeInfoReq)}updateSelectedOption(e){let t=null;for(let n=this.list.firstChild,r=this.range.from;n;n=n.nextSibling,r++)"LI"==n.nodeName&&n.id?r==e?!n.hasAttribute("aria-selected")&&(n.setAttribute("aria-selected","true"),t=n):n.hasAttribute("aria-selected")&&n.removeAttribute("aria-selected"):r--;return t&&function(e,t){let n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),i=n.height/e.offsetHeight;r.top<n.top?e.scrollTop-=(n.top-r.top)/i:r.bottom>n.bottom&&(e.scrollTop+=(r.bottom-n.bottom)/i)}(this.list,t),t}measureInfo(){let e=this.dom.querySelector("[aria-selected]");if(!e||!this.info)return null;let t=this.dom.getBoundingClientRect(),n=this.info.getBoundingClientRect(),r=e.getBoundingClientRect(),i=this.space;if(!i){let e=this.dom.ownerDocument.defaultView||window;i={left:0,top:0,right:e.innerWidth,bottom:e.innerHeight}}return r.top>Math.min(i.bottom,t.bottom)-10||r.bottom<Math.max(i.top,t.top)+10?null:this.view.state.facet(k).positionInfo(this.view,t,r,n,i,this.dom)}placeInfo(e){this.info&&(e?(e.style&&(this.info.style.cssText=e.style),this.info.className="cm-tooltip cm-completionInfo "+(e.class||"")):this.info.style.cssText="top: -1e6px")}createListBox(e,t,n){let r=document.createElement("ul");r.id=t,r.setAttribute("role","listbox"),r.setAttribute("aria-expanded","true"),r.setAttribute("aria-label",this.view.state.phrase("Completions"));let i=null;for(let s=n.from;s<n.to;s++){let{completion:o,match:l}=e[s],{section:a}=o;if(a){let e="string"==typeof a?a:a.name;e!=i&&(s>n.from||0==n.from)&&(i=e,"string"!=typeof a&&a.header?r.appendChild(a.header(a)):r.appendChild(document.createElement("completion-section")).textContent=e)}let u=r.appendChild(document.createElement("li"));u.id=t+"-"+s,u.setAttribute("role","option");let h=this.optionClass(o);for(let e of(h&&(u.className=h),this.optionContent)){let t=e(o,this.view.state,this.view,l);t&&u.appendChild(t)}}return n.from&&r.classList.add("cm-completionListIncompleteTop"),n.to<e.length&&r.classList.add("cm-completionListIncompleteBottom"),r}destroyInfo(){this.info&&(this.infoDestroy&&this.infoDestroy(),this.info.remove(),this.info=null)}destroy(){this.destroyInfo()}}function C(e){return 100*(e.boost||0)+(e.apply?10:0)+(e.info?5:0)+(e.type?1:0)}class E{constructor(e,t,n,r,i,s){this.options=e,this.attrs=t,this.tooltip=n,this.timestamp=r,this.selected=i,this.disabled=s}setSelected(e,t){return e==this.selected||e>=this.options.length?this:new E(this.options,F(t,e),this.tooltip,this.timestamp,e,this.disabled)}static build(e,t,n,r,i){let s=function(e,t){let n=[],r=null,i=e=>{n.push(e);let{section:t}=e.completion;if(t){!r&&(r=[]);let e="string"==typeof t?t:t.name;!r.some(t=>t.name==e)&&r.push("string"==typeof t?{name:e}:t)}},s=t.facet(k);for(let r of e)if(r.hasResult()){let e=r.result.getMatch;if(!1===r.result.filter)for(let t of r.result.options)i(new h(t,r.source,e?e(t):[],1e9-n.length));else{let n=t.sliceDoc(r.from,r.to),o,l=s.filterStrict?new v(n):new b(n);for(let t of r.result.options)if(o=l.match(t.label)){let n=t.displayLabel?e?e(t,o.matched):[]:o.matched;i(new h(t,r.source,n,o.score+(t.boost||0)))}}}if(r){let e=Object.create(null),t=0;for(let n of r.sort((e,t)=>{var n,r;return(null!==(n=e.rank)&&void 0!==n?n:1e9)-(null!==(r=t.rank)&&void 0!==r?r:1e9)||(e.name<t.name?-1:1)}))t-=1e5,e[n.name]=t;for(let t of n){let{section:n}=t.completion;n&&(t.score+=e["string"==typeof n?n:n.name])}}let o=[],l=null,a=s.compareCompletions;for(let e of n.sort((e,t)=>t.score-e.score||a(e.completion,t.completion))){let t=e.completion;l&&l.label==t.label&&l.detail==t.detail&&(null==l.type||null==t.type||l.type==t.type)&&l.apply==t.apply&&l.boost==t.boost?C(e.completion)>C(l)&&(o[o.length-1]=e):o.push(e),l=e.completion}return o}(e,t);if(!s.length)return r&&e.some(e=>1==e.state)?new E(r.options,r.attrs,r.tooltip,r.timestamp,r.selected,!0):null;let o=t.facet(k).selectOnOpen?0:-1;if(r&&r.selected!=o&&-1!=r.selected){let e=r.options[r.selected].completion;for(let t=0;t<s.length;t++)if(s[t].completion==e){o=t;break}}return new E(s,F(n,o),{pos:e.reduce((e,t)=>t.hasResult()?Math.min(e,t.from):e,1e8),create:R,above:i.aboveCursor},r?r.timestamp:Date.now(),o,!1)}map(e){return new E(this.options,this.attrs,Object.assign(Object.assign({},this.tooltip),{pos:e.mapPos(this.tooltip.pos)}),this.timestamp,this.selected,this.disabled)}}class S{constructor(e,t,n){this.active=e,this.id=t,this.open=n}static start(){return new S(P,"cm-ac-"+Math.floor(2e6*Math.random()).toString(36),null)}update(e){let{state:t}=e,n=t.facet(k),r=(n.override||t.languageDataAt("autocomplete",c(t)).map(m)).map(t=>(this.active.find(e=>e.source==t)||new N(t,this.active.some(e=>0!=e.state)?1:0)).update(e,n));r.length==this.active.length&&r.every((e,t)=>e==this.active[t])&&(r=this.active);let i=this.open;for(let s of(i&&e.docChanged&&(i=i.map(e.changes)),e.selection||r.some(t=>t.hasResult()&&e.changes.touchesRange(t.from,t.to))||!function(e,t){if(e==t)return!0;for(let n=0,r=0;;){for(;n<e.length&&!e[n].hasResult;)n++;for(;r<t.length&&!t[r].hasResult;)r++;let i=n==e.length,s=r==t.length;if(i||s)return i==s;if(e[n++].result!=t[r++].result)return!1}}(r,this.active)?i=E.build(r,t,this.id,i,n):i&&i.disabled&&!r.some(e=>1==e.state)&&(i=null),!i&&r.every(e=>1!=e.state)&&r.some(e=>e.hasResult())&&(r=r.map(e=>e.hasResult()?new N(e.source,0):e)),e.effects))s.is(M)&&(i=i&&i.setSelected(s.value,this.id));return r==this.active&&i==this.open?this:new S(r,this.id,i)}get tooltip(){return this.open?this.open.tooltip:null}get attrs(){return this.open?this.open.attrs:this.active.length?_:O}}let _={"aria-autocomplete":"list"},O={};function F(e,t){let n={"aria-autocomplete":"list","aria-haspopup":"listbox","aria-controls":e};return t>-1&&(n["aria-activedescendant"]=e+"-"+t),n}let P=[];function T(e,t){if(e.isUserEvent("input.complete")){let n=e.annotation(d);if(n&&t.activateOnCompletion(n))return 12}let n=e.isUserEvent("input.type");return n&&t.activateOnTyping?5:n?1:e.isUserEvent("delete.backward")?2:e.selection?8:e.docChanged?16:0}class N{constructor(e,t,n=-1){this.source=e,this.state=t,this.explicitPos=n}hasResult(){return!1}update(e,t){let n=T(e,t),r=this;for(let t of((8&n||16&n&&this.touches(e))&&(r=new N(r.source,0)),4&n&&0==r.state&&(r=new N(this.source,1)),r=r.updateFor(e,n),e.effects))if(t.is(g))r=new N(r.source,1,t.value?c(e.state):-1);else if(t.is(y))r=new N(r.source,0);else if(t.is(I))for(let e of t.value)e.source==r.source&&(r=e);return r}updateFor(e,t){return this.map(e.changes)}map(e){return e.empty||this.explicitPos<0?this:new N(this.source,this.state,e.mapPos(this.explicitPos))}touches(e){return e.changes.touchesRange(c(e.state))}}class B extends N{constructor(e,t,n,r,i){super(e,2,t),this.result=n,this.from=r,this.to=i}hasResult(){return!0}updateFor(e,t){var n;if(!(3&t))return this.map(e.changes);let r=this.result;r.map&&!e.changes.empty&&(r=r.map(r,e.changes));let i=e.changes.mapPos(this.from),s=e.changes.mapPos(this.to,1),o=c(e.state);if((this.explicitPos<0?o<=i:o<this.from)||o>s||!r||2&t&&c(e.startState)==this.from)return new N(this.source,4&t?1:0);let l=this.explicitPos<0?-1:e.changes.mapPos(this.explicitPos);return function(e,t,n,r){if(!e)return!1;let i=t.sliceDoc(n,r);return"function"==typeof e?e(i,n,r,t):f(e,!0).test(i)}(r.validFor,e.state,i,s)?new B(this.source,l,r,i,s):r.update&&(r=r.update(r,i,s,new a(e.state,o,l>=0)))?new B(this.source,l,r,r.from,null!==(n=r.to)&&void 0!==n?n:c(e.state)):new N(this.source,1,l)}map(e){return e.empty?this:(this.result.map?this.result.map(this.result,e):this.result)?new B(this.source,this.explicitPos<0?-1:e.mapPos(this.explicitPos),this.result,e.mapPos(this.from),e.mapPos(this.to,1)):new N(this.source,0)}touches(e){return e.changes.touchesRange(this.from,this.to)}}let I=s.Py.define({map:(e,t)=>e.map(e=>e.map(t))}),M=s.Py.define(),$=s.QQ.define({create:()=>S.start(),update:(e,t)=>e.update(t),provide:e=>[o.hJ.from(e,e=>e.tooltip),o.tk.contentAttributes.from(e,e=>e.attrs)]});function L(e,t){let n=t.completion.apply||t.completion.label,r=e.state.field($).active.find(e=>e.source==t.source);return r instanceof B&&("string"==typeof n?e.dispatch(Object.assign(Object.assign({},function(e,t,n,r){let{main:i}=e.selection,o=n-i.from,l=r-i.from;return Object.assign(Object.assign({},e.changeByRange(a=>{if(a!=i&&n!=r&&e.sliceDoc(a.from+o,a.from+l)!=e.sliceDoc(n,r))return{range:a};let u=e.toText(t);return{changes:{from:a.from+o,to:r==i.from?a.to:a.from+l,insert:u},range:s.jT.cursor(a.from+o+u.length)}})),{scrollIntoView:!0,userEvent:"input.complete"})}(e.state,n,r.from,r.to)),{annotations:d.of(t.completion)})):n(e,t.completion,r.from,r.to),!0)}let R=(r=$,i=L,e=>new x(e,r,i));function j(e,t="option"){return n=>{let r=n.state.field($,!1);if(!r||!r.open||r.open.disabled||Date.now()-r.open.timestamp<n.state.facet(k).interactionDelay)return!1;let i=1,s;"page"==t&&(s=(0,o.gB)(n,r.open.tooltip))&&(i=Math.max(2,Math.floor(s.dom.offsetHeight/s.dom.querySelector("li").offsetHeight)-1));let{length:l}=r.open.options,a=r.open.selected>-1?r.open.selected+i*(e?1:-1):e?0:l-1;return a<0?a="page"==t?0:l-1:a>=l&&(a="page"==t?l-1:0),n.dispatch({effects:M.of(a)}),!0}}let q=e=>!!e.state.field($,!1)&&(e.dispatch({effects:g.of(!0)}),!0);class V{constructor(e,t){this.active=e,this.context=t,this.time=Date.now(),this.updates=[],this.done=void 0}}let z=o.lg.fromClass(class{constructor(e){for(let t of(this.view=e,this.debounceUpdate=-1,this.running=[],this.debounceAccept=-1,this.pendingStart=!1,this.composing=0,e.state.field($).active))1==t.state&&this.startQuery(t)}update(e){let t=e.state.field($),n=e.state.facet(k);if(!e.selectionSet&&!e.docChanged&&e.startState.field($)==t)return;let r=e.transactions.some(e=>{let t=T(e,n);return 8&t||(e.selection||e.docChanged)&&!(3&t)});for(let t=0;t<this.running.length;t++){let n=this.running[t];if(r||n.context.abortOnDocChange&&e.docChanged||n.updates.length+e.transactions.length>50&&Date.now()-n.time>1e3){for(let e of n.context.abortListeners)try{e()}catch(e){(0,o.OO)(this.view.state,e)}n.context.abortListeners=null,this.running.splice(t--,1)}else n.updates.push(...e.transactions)}this.debounceUpdate>-1&&clearTimeout(this.debounceUpdate),e.transactions.some(e=>e.effects.some(e=>e.is(g)))&&(this.pendingStart=!0);let i=this.pendingStart?50:n.activateOnTypingDelay;if(this.debounceUpdate=t.active.some(e=>1==e.state&&!this.running.some(t=>t.active.source==e.source))?setTimeout(()=>this.startUpdate(),i):-1,0!=this.composing)for(let t of e.transactions)t.isUserEvent("input.type")?this.composing=2:2==this.composing&&t.selection&&(this.composing=3)}startUpdate(){this.debounceUpdate=-1,this.pendingStart=!1;let{state:e}=this.view;for(let t of e.field($).active)1==t.state&&!this.running.some(e=>e.active.source==t.source)&&this.startQuery(t)}startQuery(e){let{state:t}=this.view,n=c(t),r=new a(t,n,e.explicitPos==n,this.view),i=new V(e,r);this.running.push(i),Promise.resolve(e.source(r)).then(e=>{!i.context.aborted&&(i.done=e||null,this.scheduleAccept())},e=>{this.view.dispatch({effects:y.of(null)}),(0,o.OO)(this.view.state,e)})}scheduleAccept(){this.running.every(e=>void 0!==e.done)?this.accept():this.debounceAccept<0&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(k).updateSyncTime))}accept(){var e;this.debounceAccept>-1&&clearTimeout(this.debounceAccept),this.debounceAccept=-1;let t=[],n=this.view.state.facet(k);for(let r=0;r<this.running.length;r++){let i=this.running[r];if(void 0===i.done)continue;if(this.running.splice(r--,1),i.done){let r=new B(i.active.source,i.active.explicitPos,i.done,i.done.from,null!==(e=i.done.to)&&void 0!==e?e:c(i.updates.length?i.updates[0].startState:this.view.state));for(let e of i.updates)r=r.update(e,n);if(r.hasResult()){t.push(r);continue}}let s=this.view.state.field($).active.find(e=>e.source==i.active.source);if(s&&1==s.state){if(null==i.done){let e=new N(i.active.source,0);for(let t of i.updates)e=e.update(t,n);1!=e.state&&t.push(e)}else this.startQuery(s)}}t.length&&this.view.dispatch({effects:I.of(t)})}},{eventHandlers:{blur(e){let t=this.view.state.field($,!1);if(t&&t.tooltip&&this.view.state.facet(k).closeOnBlur){let n=t.open&&(0,o.gB)(this.view,t.open.tooltip);(!n||!n.dom.contains(e.relatedTarget))&&setTimeout(()=>this.view.dispatch({effects:y.of(null)}),10)}},compositionstart(){this.composing=1},compositionend(){3==this.composing&&setTimeout(()=>this.view.dispatch({effects:g.of(!1)}),20),this.composing=0}}}),U="object"==typeof navigator&&/Win/.test(navigator.platform),H=s.Wl.highest(o.tk.domEventHandlers({keydown(e,t){let n=t.state.field($,!1);if(!n||!n.open||n.open.disabled||n.open.selected<0||e.key.length>1||e.ctrlKey&&!(U&&e.altKey)||e.metaKey)return!1;let r=n.open.options[n.open.selected],i=n.active.find(e=>e.source==r.source),s=r.completion.commitCharacters||i.result.commitCharacters;return s&&s.indexOf(e.key)>-1&&L(t,r),!1}})),W=o.tk.baseTheme({".cm-tooltip.cm-tooltip-autocomplete":{"& > ul":{fontFamily:"monospace",whiteSpace:"nowrap",overflow:"hidden auto",maxWidth_fallback:"700px",maxWidth:"min(700px, 95vw)",minWidth:"250px",maxHeight:"10em",height:"100%",listStyle:"none",margin:0,padding:0,"& > li, & > completion-section":{padding:"1px 3px",lineHeight:1.2},"& > li":{overflowX:"hidden",textOverflow:"ellipsis",cursor:"pointer"},"& > completion-section":{display:"list-item",borderBottom:"1px solid silver",paddingLeft:"0.5em",opacity:.7}}},"&light .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#17c",color:"white"},"&light .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#777"},"&dark .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#347",color:"white"},"&dark .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#444"},".cm-completionListIncompleteTop:before, .cm-completionListIncompleteBottom:after":{content:'"\xb7\xb7\xb7"',opacity:.5,display:"block",textAlign:"center"},".cm-tooltip.cm-completionInfo":{position:"absolute",padding:"3px 9px",width:"max-content",maxWidth:"400px",boxSizing:"border-box",whiteSpace:"pre-line"},".cm-completionInfo.cm-completionInfo-left":{right:"100%"},".cm-completionInfo.cm-completionInfo-right":{left:"100%"},".cm-completionInfo.cm-completionInfo-left-narrow":{right:"30px"},".cm-completionInfo.cm-completionInfo-right-narrow":{left:"30px"},"&light .cm-snippetField":{backgroundColor:"#00000022"},"&dark .cm-snippetField":{backgroundColor:"#ffffff22"},".cm-snippetFieldPosition":{verticalAlign:"text-top",width:0,height:"1.15em",display:"inline-block",margin:"0 -0.7px -.7em",borderLeft:"1.4px dotted #888"},".cm-completionMatchedText":{textDecoration:"underline"},".cm-completionDetail":{marginLeft:"0.5em",fontStyle:"italic"},".cm-completionIcon":{fontSize:"90%",width:".8em",display:"inline-block",textAlign:"center",paddingRight:".6em",opacity:"0.6",boxSizing:"content-box"},".cm-completionIcon-function, .cm-completionIcon-method":{"&:after":{content:"'ƒ'"}},".cm-completionIcon-class":{"&:after":{content:"'○'"}},".cm-completionIcon-interface":{"&:after":{content:"'◌'"}},".cm-completionIcon-variable":{"&:after":{content:"'\uD835\uDC65'"}},".cm-completionIcon-constant":{"&:after":{content:"'\uD835\uDC36'"}},".cm-completionIcon-type":{"&:after":{content:"'\uD835\uDC61'"}},".cm-completionIcon-enum":{"&:after":{content:"'∪'"}},".cm-completionIcon-property":{"&:after":{content:"'□'"}},".cm-completionIcon-keyword":{"&:after":{content:"'\uD83D\uDD11︎'"}},".cm-completionIcon-namespace":{"&:after":{content:"'▢'"}},".cm-completionIcon-text":{"&:after":{content:"'abc'",fontSize:"50%",verticalAlign:"middle"}}});class G{constructor(e,t,n,r){this.field=e,this.line=t,this.from=n,this.to=r}}class K{constructor(e,t,n){this.field=e,this.from=t,this.to=n}map(e){let t=e.mapPos(this.from,-1,s.gc.TrackDel),n=e.mapPos(this.to,1,s.gc.TrackDel);return null==t||null==n?null:new K(this.field,t,n)}}class J{constructor(e,t){this.lines=e,this.fieldPositions=t}instantiate(e,t){let n=[],r=[t],i=e.doc.lineAt(t),s=/^\s*/.exec(i.text)[0];for(let i of this.lines){if(n.length){let n=s,o=/^\t*/.exec(i)[0].length;for(let t=0;t<o;t++)n+=e.facet(l.c);r.push(t+n.length-o),i=n+i.slice(o)}n.push(i),t+=i.length+1}return{text:n,ranges:this.fieldPositions.map(e=>new K(e.field,r[e.line]+e.from,r[e.line]+e.to))}}static parse(e){let t=[],n=[],r=[],i;for(let s of e.split(/\r\n?|\n/)){for(;i=/[#$]\{(?:(\d+)(?::([^}]*))?|((?:\\[{}]|[^}])*))\}/.exec(s);){let e=i[1]?+i[1]:null,o=i[2]||i[3]||"",l=-1,a=o.replace(/\\[{}]/g,e=>e[1]);for(let n=0;n<t.length;n++)(null!=e?t[n].seq==e:!!a&&t[n].name==a)&&(l=n);if(l<0){let n=0;for(;n<t.length&&(null==e||null!=t[n].seq&&t[n].seq<e);)n++;for(let i of(t.splice(n,0,{seq:e,name:a}),l=n,r))i.field>=l&&i.field++}r.push(new G(l,n.length,i.index,i.index+a.length)),s=s.slice(0,i.index)+o+s.slice(i.index+i[0].length)}s=s.replace(/\\([{}])/g,(e,t,i)=>{for(let e of r)e.line==n.length&&e.from>i&&(e.from--,e.to--);return t}),n.push(s)}return new J(n,r)}}let Q=o.p.widget({widget:new class extends o.l9{toDOM(){let e=document.createElement("span");return e.className="cm-snippetFieldPosition",e}ignoreEvent(){return!1}}}),Y=o.p.mark({class:"cm-snippetField"});class Z{constructor(e,t){this.ranges=e,this.active=t,this.deco=o.p.set(e.map(e=>(e.from==e.to?Q:Y).range(e.from,e.to)))}map(e){let t=[];for(let n of this.ranges){let r=n.map(e);if(!r)return null;t.push(r)}return new Z(t,this.active)}selectionInsideField(e){return e.ranges.every(e=>this.ranges.some(t=>t.field==this.active&&t.from<=e.from&&t.to>=e.to))}}let X=s.Py.define({map:(e,t)=>e&&e.map(t)}),ee=s.Py.define(),et=s.QQ.define({create:()=>null,update(e,t){for(let n of t.effects){if(n.is(X))return n.value;if(n.is(ee)&&e)return new Z(e.ranges,n.value)}return e&&t.docChanged&&(e=e.map(t.changes)),e&&t.selection&&!e.selectionInsideField(t.selection)&&(e=null),e},provide:e=>o.tk.decorations.from(e,e=>e?e.deco:o.p.none)});function en(e,t){return s.jT.create(e.filter(e=>e.field==t).map(e=>s.jT.range(e.from,e.to)))}function er(e){return({state:t,dispatch:n})=>{let r=t.field(et,!1);if(!r||e<0&&0==r.active)return!1;let i=r.active+e,s=e>0&&!r.ranges.some(t=>t.field==i+e);return n(t.update({selection:en(r.ranges,i),effects:X.of(s?null:new Z(r.ranges,i)),scrollIntoView:!0})),!0}}let ei=er(1),es=[{key:"Tab",run:ei,shift:er(-1)},{key:"Escape",run:({state:e,dispatch:t})=>!!e.field(et,!1)&&(t(e.update({effects:X.of(null)})),!0)}],eo=s.r$.define({combine:e=>e.length?e[0]:es}),el=s.Wl.highest(o.$f.compute([eo],e=>e.facet(eo)));function ea(e,t){var n;let r;return Object.assign(Object.assign({},t),{apply:(n=e,r=J.parse(n),(e,t,n,i)=>{let{text:o,ranges:l}=r.instantiate(e.state,n),a={changes:{from:n,to:i,insert:s.xv.of(o)},scrollIntoView:!0,annotations:t?[d.of(t),s.YW.userEvent.of("input.complete")]:void 0};if(l.length&&(a.selection=en(l,0)),l.some(e=>e.field>0)){let t=new Z(l,0),n=a.effects=[X.of(t)];void 0===e.state.field(et,!1)&&n.push(s.Py.appendConfig.of([et,el,eu,W]))}e.dispatch(e.state.update(a))})})}let eu=o.tk.domEventHandlers({mousedown(e,t){let n=t.state.field(et,!1),r;if(!n||null==(r=t.posAtCoords({x:e.clientX,y:e.clientY})))return!1;let i=n.ranges.find(e=>e.from<=r&&e.to>=r);return!!i&&i.field!=n.active&&(t.dispatch({selection:en(n.ranges,i.field),effects:X.of(n.ranges.some(e=>e.field>i.field)?new Z(n.ranges,i.field):null),scrollIntoView:!0}),!0)}}),eh={brackets:["(","[","{","'",'"'],before:")]}:;>",stringPrefixes:[]},ec=s.Py.define({map(e,t){let n=t.mapPos(e,-1,s.gc.TrackAfter);return null==n?void 0:n}}),ef=new class extends s.uU{};ef.startSide=1,ef.endSide=-1;let ed=s.QQ.define({create:()=>s.Xs.empty,update(e,t){if(e=e.map(t.changes),t.selection){let n=t.state.doc.lineAt(t.selection.main.head);e=e.update({filter:e=>e>=n.from&&e<=n.to})}for(let n of t.effects)n.is(ec)&&(e=e.update({add:[ef.range(n.value,n.value+1)]}));return e}});function ep(){return[ev,ed]}let em="()[]{}<>";function eg(e){for(let t=0;t<em.length;t+=2)if(em.charCodeAt(t)==e)return em.charAt(t+1);return(0,s.bg)(e<128?e:e+1)}function ey(e,t){return e.languageDataAt("closeBrackets",t)[0]||eh}let eb="object"==typeof navigator&&/Android\b/.test(navigator.userAgent),ev=o.tk.inputHandler.of((e,t,n,r)=>{if((eb?e.composing:e.compositionStarted)||e.state.readOnly)return!1;let i=e.state.selection.main;if(r.length>2||2==r.length&&1==(0,s.nZ)((0,s.gm)(r,0))||t!=i.from||n!=i.to)return!1;let o=function(e,t){let n=ey(e,e.selection.main.head),r=n.brackets||eh.brackets;for(let i of r){let o=eg((0,s.gm)(i,0));if(t==i)return o==i?function(e,t,n,r){let i=r.stringPrefixes||eh.stringPrefixes,o=null,a=e.changeByRange(r=>{if(!r.empty)return{changes:[{insert:t,from:r.from},{insert:t,from:r.to}],effects:ec.of(r.to+t.length),range:s.jT.range(r.anchor+t.length,r.head+t.length)};let a=r.head,u=eD(e.doc,a),h;if(u==t){if(eA(e,a))return{changes:{insert:t+t,from:a},effects:ec.of(a+t.length),range:s.jT.cursor(a+t.length)};if(ew(e,a)){let r=n&&e.sliceDoc(a,a+3*t.length)==t+t+t?t+t+t:t;return{changes:{from:a,to:a+r.length,insert:r},range:s.jT.cursor(a+r.length)}}}else if(n&&e.sliceDoc(a-2*t.length,a)==t+t&&(h=ex(e,a-2*t.length,i))>-1&&eA(e,h))return{changes:{insert:t+t+t+t,from:a},effects:ec.of(a+t.length),range:s.jT.cursor(a+t.length)};else if(e.charCategorizer(a)(u)!=s.D0.Word&&ex(e,a,i)>-1&&!function(e,t,n,r){let i=(0,l.qz)(e).resolveInner(t,-1),s=r.reduce((e,t)=>Math.max(e,t.length),0);for(let o=0;o<5;o++){let o=e.sliceDoc(i.from,Math.min(i.to,i.from+n.length+s)),l=o.indexOf(n);if(!l||l>-1&&r.indexOf(o.slice(0,l))>-1){let t=i.firstChild;for(;t&&t.from==i.from&&t.to-t.from>n.length+l;){if(e.sliceDoc(t.to-n.length,t.to)==n)return!1;t=t.firstChild}return!0}let a=i.to==t&&i.parent;if(!a)break;i=a}return!1}(e,a,t,i))return{changes:{insert:t+t,from:a},effects:ec.of(a+t.length),range:s.jT.cursor(a+t.length)};return{range:o=r}});return o?null:e.update(a,{scrollIntoView:!0,userEvent:"input.type"})}(e,i,r.indexOf(i+i+i)>-1,n):function(e,t,n,r){let i=null,o=e.changeByRange(o=>{if(!o.empty)return{changes:[{insert:t,from:o.from},{insert:n,from:o.to}],effects:ec.of(o.to+t.length),range:s.jT.range(o.anchor+t.length,o.head+t.length)};let l=eD(e.doc,o.head);return!l||/\s/.test(l)||r.indexOf(l)>-1?{changes:{insert:t+n,from:o.head},effects:ec.of(o.head+t.length),range:s.jT.cursor(o.head+t.length)}:{range:i=o}});return i?null:e.update(o,{scrollIntoView:!0,userEvent:"input.type"})}(e,i,o,n.before||eh.before);if(t==o&&ew(e,e.selection.main.from))return function(e,t,n){let r=null,i=e.changeByRange(t=>t.empty&&eD(e.doc,t.head)==n?{changes:{from:t.head,to:t.head+n.length,insert:n},range:s.jT.cursor(t.head+n.length)}:r={range:t});return r?null:e.update(i,{scrollIntoView:!0,userEvent:"input.type"})}(e,i,o)}return null}(e.state,r);return!!o&&(e.dispatch(o),!0)}),ek=[{key:"Backspace",run:({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=ey(e,e.selection.main.head).brackets||eh.brackets,r=null,i=e.changeByRange(t=>{if(t.empty){let r=function(e,t){let n=e.sliceString(t-2,t);return(0,s.nZ)((0,s.gm)(n,0))==n.length?n:n.slice(1)}(e.doc,t.head);for(let i of n)if(i==r&&eD(e.doc,t.head)==eg((0,s.gm)(i,0)))return{changes:{from:t.head-i.length,to:t.head+i.length},range:s.jT.cursor(t.head-i.length)}}return{range:r=t}});return!r&&t(e.update(i,{scrollIntoView:!0,userEvent:"delete.backward"})),!r}}];function ew(e,t){let n=!1;return e.field(ed).between(0,e.doc.length,e=>{e==t&&(n=!0)}),n}function eD(e,t){let n=e.sliceString(t,t+2);return n.slice(0,(0,s.nZ)((0,s.gm)(n,0)))}function eA(e,t){let n=(0,l.qz)(e).resolveInner(t+1);return n.parent&&n.from==t}function ex(e,t,n){let r=e.charCategorizer(t);if(r(e.sliceDoc(t-1,t))!=s.D0.Word)return t;for(let i of n){let n=t-i.length;if(e.sliceDoc(n,t)==i&&r(e.sliceDoc(n-1,n))!=s.D0.Word)return n}return -1}function eC(e={}){return[H,$,k.of(e),z,eS,W]}let eE=[{key:"Ctrl-Space",run:q},{mac:"Alt-`",run:q},{key:"Escape",run:e=>{let t=e.state.field($,!1);return!!(t&&t.active.some(e=>0!=e.state))&&(e.dispatch({effects:y.of(null)}),!0)}},{key:"ArrowDown",run:j(!0)},{key:"ArrowUp",run:j(!1)},{key:"PageDown",run:j(!0,"page")},{key:"PageUp",run:j(!1,"page")},{key:"Enter",run:e=>{let t=e.state.field($,!1);return!(e.state.readOnly||!t||!t.open||t.open.selected<0||t.open.disabled||Date.now()-t.open.timestamp<e.state.facet(k).interactionDelay)&&L(e,t.open.options[t.open.selected])}}],eS=s.Wl.highest(o.$f.computeN([k],e=>e.facet(k).defaultKeymap?[eE]:[]))},65569:function(e,t,n){"use strict";let r,i,s,o,l,a,u,h;n.d(t,{fB:()=>fg,ov:()=>eg});var c,f,d,p,m,g,y,b,v,k,w,D,A,x,C,E,S,_,O,F,P,T={};n.r(T),n.d(T,{decode:()=>rt,encode:()=>ri,format:()=>rs,parse:()=>rg});var N={};n.r(N),n.d(N,{Any:()=>rv,Cc:()=>rk,Cf:()=>rw,P:()=>ry,S:()=>rb,Z:()=>rD});var B={};n.r(B),n.d(B,{arrayReplaceAt:()=>rL,assign:()=>r$,escapeHtml:()=>rQ,escapeRE:()=>rZ,fromCodePoint:()=>rj,has:()=>rM,isMdAsciiPunct:()=>r2,isPunctChar:()=>r1,isSpace:()=>rX,isString:()=>rB,isValidEntityCode:()=>rR,isWhiteSpace:()=>r0,lib:()=>r5,normalizeReference:()=>r3,unescapeAll:()=>rH,unescapeMd:()=>rU});var I={};n.r(I),n.d(I,{parseLinkDestination:()=>r4,parseLinkLabel:()=>r8,parseLinkTitle:()=>r6});var M={};n.r(M),n.d(M,{boolean:()=>oW,booleanish:()=>oG,commaOrSpaceSeparated:()=>oZ,commaSeparated:()=>oY,number:()=>oJ,overloadedBoolean:()=>oK,spaceSeparated:()=>oQ});var $={};n.r($),n.d($,{BOM:()=>cc,DOCUMENT:()=>cf,FLOW_END:()=>cd,SCALAR:()=>cp,createScalarToken:()=>ce,isCollection:()=>cm,isScalar:()=>cg,prettyToken:()=>cy,resolveAsScalar:()=>h7,setScalarValue:()=>ct,stringify:()=>ci,tokenType:()=>cb,visit:()=>ch});var L={};n.r(L),n.d(L,{Alias:()=>uy,CST:()=>$,Composer:()=>h9,Document:()=>h$,Lexer:()=>cC,LineCounter:()=>cE,Pair:()=>uW,Parser:()=>cN,Scalar:()=>uv,Schema:()=>hM,YAMLError:()=>hR,YAMLMap:()=>uZ,YAMLParseError:()=>hj,YAMLSeq:()=>u0,YAMLWarning:()=>hq,isAlias:()=>aX,isCollection:()=>a8,isDocument:()=>a0,isMap:()=>a1,isNode:()=>a4,isPair:()=>a2,isScalar:()=>a3,isSeq:()=>a5,parse:()=>c$,parseAllDocuments:()=>cI,parseDocument:()=>cM,stringify:()=>cL,visit:()=>ut,visitAsync:()=>ur});var R=n("83582"),j=n("85237");let q={log:(...e)=>{}},V={STRING:"String",NUMBER:"Number",TRUE:"True",FALSE:"False",NULL:"Null",OBJECT:"Object",ARRAY:"Array",PROPERTY:"Property",PROPERTY_NAME:"PropertyName",PROPERTY_COLON:"PropertyColon",ITEM:"Item",JSON_TEXT:"JsonText",INVALID:"⚠"},z={Pair:V.PROPERTY,Key:V.PROPERTY_NAME,BlockSequence:V.ARRAY,BlockMapping:V.OBJECT,FlowSequence:V.ARRAY,FlowMapping:V.OBJECT,QuotedLiteral:V.STRING,Literal:V.STRING,Stream:V.JSON_TEXT,Document:V.OBJECT},U={File:V.JSON_TEXT},H=[V.STRING,V.NUMBER,V.TRUE,V.FALSE,V.NULL],W=[V.OBJECT,V.ARRAY,V.ITEM],G={JSON5:"json5",JSON:"json4",YAML:"yaml"},K=(e,t)=>{var n,r;switch(t){case G.YAML:return null!==(n=z[e])&&void 0!==n?n:e;case G.JSON5:return null!==(r=U[e])&&void 0!==r?r:e;default:return e}};function J(e,t,n){let r=[];for(let i=t;null==i?void 0:i.parent;i=i.parent)switch(K(i.parent.name,n)){case V.PROPERTY:{let t=ea(i.parent,V.PROPERTY_NAME,n);t&&r.unshift(et(e,t).replace(/[/~]/g,e=>"~"===e?"~0":"~1"));break}case V.ARRAY:if(ei(i,n)){let e=ec(i.parent,i,n);r.unshift(`${e}`)}}return r.unshift(""),r.join("/")}let Q=(e,t,n=-1,r)=>J(e.doc,(0,j.qz)(e).resolve(t,n),r),Y=(e,t)=>{let n=(0,j.qz)(e),r=new Map;return n.iterate({enter:n=>{var i,s,o,l,a,u,h,c;if([V.PROPERTY_NAME,V.OBJECT].includes(K(n.name,t))){let f=J(e.doc,n.node,t),{from:d,to:p}=n.node;if(!(null===(s=null===(i=n.node)||void 0===i?void 0:i.nextSibling)||void 0===s?void 0:s.node))return r.set(f,{keyFrom:d,keyTo:p}),!0;let m=t===G.JSON?null===(l=null===(o=n.node)||void 0===o?void 0:o.nextSibling)||void 0===l?void 0:l.node:null===(c=null===(h=null===(u=null===(a=n.node)||void 0===a?void 0:a.nextSibling)||void 0===u?void 0:u.node)||void 0===h?void 0:h.nextSibling)||void 0===c?void 0:c.node;if(!m)return r.set(f,{keyFrom:d,keyTo:p}),!0;let{from:g,to:y}=m;return r.set(f,{keyFrom:d,keyTo:p,valueFrom:g,valueTo:y}),!0}}}),r},Z=(e,t,n=-1)=>(0,j.qz)(e).resolveInner(t,n),X=e=>e.replace(/^"(.*)"$/,"$1").replace(/^'(.*)'$/,"$1"),ee=e=>e.replace(/^"(.*)"$/,"'$1'"),et=(e,t,n=!0,r=!0)=>{let i=t?e.sliceString(t.from,t.to):"";return n?r?X(i):i.replace(/(^["'])|(["']$)/g,""):i},en=(e,t)=>{var n,r,i,s;return K(e.name,t)===V.INVALID&&(K(null!==(r=null===(n=e.prevSibling)||void 0===n?void 0:n.name)&&void 0!==r?r:"",t)===V.PROPERTY_NAME||K(null!==(s=null===(i=e.prevSibling)||void 0===i?void 0:i.name)&&void 0!==s?s:"",t)===V.PROPERTY_COLON)},er=(e,t)=>H.includes(K(e.name,t))||en(e,t),ei=(e,t)=>[...H,...W].includes(K(e.name,t))||en(e,t),es=(e,t)=>{var n,r,i,s,o,l;return K(e.name,t)===V.PROPERTY_NAME||K(e.name,t)===V.INVALID&&(K(null!==(r=null===(n=e.prevSibling)||void 0===n?void 0:n.name)&&void 0!==r?r:"",t)===V.PROPERTY||"{"===K(null!==(s=null===(i=e.prevSibling)||void 0===i?void 0:i.name)&&void 0!==s?s:"",t))||t===G.YAML&&K(null!==(l=null===(o=e.parent)||void 0===o?void 0:o.name)&&void 0!==l?l:"",t)===V.OBJECT},eo=e=>{let t=[],n=e.firstChild;for(;n;)n&&t.push(n),n=null==n?void 0:n.nextSibling;return t},el=(e,t,n)=>eo(e).filter(e=>K(e.name,n)===t),ea=(e,t,n)=>{var r;return null!==(r=eo(e).find(e=>K(e.name,n)===t))&&void 0!==r?r:null},eu=(e,t)=>eo(e).find(e=>er(e,t)),eh=(e,t)=>eo(e).filter(e=>H.includes(K(e.name,t))||W.includes(K(e.name,t))),ec=(e,t,n)=>eh(e,n).findIndex(e=>e.from===t.from&&e.to===t.to),ef=(e,t,n,r=1/0)=>{let i=e;for(;i&&r>0;){if(K(i.name,n)===t)return i;i=i.parent,r--}return null};var ed=n("8954");let ep=ed.Py.define(),em=ed.QQ.define({create(){},update(e,t){for(let e of t.effects)if(e.is(ep))return e.value;return e}}),eg=(e,t)=>{e.dispatch({effects:ep.of(t)})},ey=e=>e.field(em),eb=e=>[em.init(()=>e)],ev={AdditionalItemsError:"Array at `{{pointer}}` may not have an additional item `{{key}}`",AdditionalPropertiesError:"Additional property `{{property}}` on `{{pointer}}` does not match schema `{{schema}}`",AllOfError:"Value `{{value}}` at `{{pointer}}` does not match schema of `{{allOf}}`",AnyOfError:"Value `{{value}}` at `{{pointer}}` does not match any schema of `{{anyOf}}`",ConstError:"Expected value at `{{pointer}}` to be `{{expected}}`, but value given is `{{value}}`",containsAnyError:"The array at `{{pointer}}` must contain at least one item",ContainsArrayError:"The property at `{{pointer}}` must not be an array",ContainsError:"The array at `{{pointer}}` must contain an element that matches `{{schema}}`",EnumError:"Expected given value `{{value}}` in `{{pointer}}` to be one of `{{values}}`",ForbiddenPropertyError:"Property name `{{property}}` at `{{pointer}}` is not allowed",FormatDateError:"Value `{{value}}` at `{{pointer}}` is not a valid date",FormatDateTimeError:"Value `{{value}}` at `{{pointer}}` is not a valid date-time",FormatEmailError:"Value `{{value}}` at `{{pointer}}` is not a valid email",FormatHostnameError:"Value `{{value}}` at `{{pointer}}` is not a valid hostname",FormatIPV4Error:"Value `{{value}}` at `{{pointer}}` is not a valid IPv4 address",FormatIPV4LeadingZeroError:"IPv4 addresses starting with zero are invalid, since they are interpreted as octals",FormatIPV6Error:"Value `{{value}}` at `{{pointer}}` is not a valid IPv6 address",FormatIPV6LeadingZeroError:"IPv6 addresses starting with zero are invalid, since they are interpreted as octals",FormatJsonPointerError:"Value `{{value}}` at `{{pointer}}` is not a valid json-pointer",FormatRegExError:"Value `{{value}}` at `{{pointer}}` is not a valid regular expression",FormatTimeError:"Value `{{value}}` at `{{pointer}}` is not a valid time",FormatURIError:"Value `{{value}}` at `{{pointer}}` is not a valid uri",FormatURIReferenceError:"Value `{{value}}` at `{{pointer}}` is not a valid uri-reference",FormatURITemplateError:"Value `{{value}}` at `{{pointer}}` is not a valid uri-template",FormatURLError:"Value `{{value}}` at `{{pointer}}` is not a valid url",InvalidDataError:"No value may be specified in `{{pointer}}`",InvalidPropertyNameError:"Invalid property name `{{property}}` at `{{pointer}}`",MaximumError:"Value in `{{pointer}}` is `{{length}}`, but should be `{{maximum}}` at maximum",MaxItemsError:"Too many items in `{{pointer}}`, should be `{{maximum}}` at most, but got `{{length}}`",MaxLengthError:"Value `{{pointer}}` should have a maximum length of `{{maxLength}}`, but got `{{length}}`.",MaxPropertiesError:"Too many properties in `{{pointer}}`, should be `{{maximum}}` at most, but got `{{length}}`",MinimumError:"Value in `{{pointer}}` is `{{length}}`, but should be `{{minimum}}` at minimum",MinItemsError:"Too few items in `{{pointer}}`, should be at least `{{minItems}}`, but got `{{length}}`",MinItemsOneError:"At least one item is required in `{{pointer}}`",MinLengthError:"Value `{{pointer}}` should have a minimum length of `{{minLength}}`, but got `{{length}}`.",MinLengthOneError:"A value is required in `{{pointer}}`",MinPropertiesError:"Too few properties in `{{pointer}}`, should be at least `{{minimum}}`, but got `{{length}}`",MissingDependencyError:"The required propery '{{missingProperty}}' in `{{pointer}}` is missing",MissingOneOfPropertyError:"Value at `{{pointer}}` property: `{{property}}`",MultipleOfError:"Expected `{{value}}` in `{{pointer}}` to be multiple of `{{multipleOf}}`",MultipleOneOfError:"Value `{{value}}` should not match multiple schemas in oneOf `{{matches}}`",NoAdditionalPropertiesError:"Additional property `{{property}}` in `{{pointer}}` is not allowed",NotError:"Value `{{value}}` at pointer should not match schema `{{not}}`",OneOfError:"Value `{{value}}` in `{{pointer}}` does not match any given oneof schema",OneOfPropertyError:"Failed finding a matching oneOfProperty schema in `{{pointer}}` where `{{property}}` matches `{{value}}`",PatternError:"Value in `{{pointer}}` should match `{{description}}`, but received `{{received}}`",PatternPropertiesError:"Property `{{key}}` does not match any patterns in `{{pointer}}`. Valid patterns are: {{patterns}}",RequiredPropertyError:"The required property `{{key}}` is missing at `{{pointer}}`",SchemaWarning:"Failed retrieving a schema from '{{pointer}}' to key '{{key}}'",TypeError:"Expected `{{value}}` ({{received}}) in `{{pointer}}` to be of type `{{expected}}`",UndefinedValueError:"Value must not be undefined in `{{pointer}}`",UniqueItemsError:"Items in array must be unique. Value `{{value}}` in `{{pointer}}` is a duplicate of {{duplicatePointer}}.",UnknownPropertyError:"Could not find a valid schema for property `{{pointer}}` within object",ValueNotEmptyError:"A value for `{{property}}` is required at `{{pointer}}`"},ek=Object.prototype.toString;function ew(e){let t=ek.call(e).match(/\s([^\]]+)\]/).pop().toLowerCase();return"file"===t?"object":t}function eD(e,t){return{type:"error",name:e,code:e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),message:function(e,t,n=e){var r;return function(e,t={}){return e.replace(/\{\{\w+\}\}/g,e=>{let n=t[e.replace(/[{}]/g,"")],r=ew(n);return"object"===r||"array"===r?JSON.stringify(n):n})}(null!==(r=ev[e])&&void 0!==r?r:n,t)}(e,t),data:t}}function eA(e){return eD.bind(null,e)}function ex(e,t=[]){for(let n=0;n<e.length;n+=1){let r=e[n];Array.isArray(r)?ex(r,t):t.push(r)}return t}let eC={DECLARATOR_ONEOF:"oneOfProperty",GET_TEMPLATE_RECURSION_LIMIT:1,propertyBlacklist:["_id"],templateDefaultOptions:{addOptionalProps:!1,removeInvalidData:!1,extendDefaults:!0}};function eE(e,t,n){let r={...t};return Object.defineProperty(r,"getOneOfOrigin",{enumerable:!1,value:()=>({index:n,schema:e})}),r}function eS(e){return(null==e?void 0:e.type)==="error"}function e_(e){return eS(e)||e instanceof Promise}let{DECLARATOR_ONEOF:eO}=eC;function eF(e,t,n=e.rootSchema,r="#"){if(null!=t&&n[eO]){let i=[],s=n[eO],o=t[n[eO]];if(void 0===o)return e.errors.missingOneOfPropertyError({property:s,pointer:r,schema:n,value:t});for(let l=0;l<n.oneOf.length;l+=1){let a=e.resolveRef(n.oneOf[l]),u=e.step(s,a,t,r);if(eS(u))return u;let h=ex(e.validate(o,u,r));if(!((h=h.filter(e_)).length>0))return eE(n,a,l);i.push(...h)}return e.errors.oneOfPropertyError({property:s,value:o,pointer:r,schema:n,errors:i})}let i=[],s=[];for(let o=0;o<n.oneOf.length;o+=1){let l=e.resolveRef(n.oneOf[o]),a=ex(e.validate(t,l,r));(a=a.filter(e_)).length>0?s.push(...a):i.push({index:o,schema:l})}return 1===i.length?eE(n,i[0].schema,i[0].index):i.length>1?e.errors.multipleOneOfError({value:t,pointer:r,schema:n,matches:i}):e.errors.oneOfError({value:JSON.stringify(t),pointer:r,schema:n,oneOf:n.oneOf,errors:s})}function eP(e,t,n=e.rootSchema,r="#"){if(null!=t&&n[eO]){let i=[],s=n[eO],o=t[n[eO]];if(void 0===o)return e.errors.missingOneOfPropertyError({property:s,pointer:r,schema:n,value:t});for(let l=0;l<n.oneOf.length;l+=1){let a=e.resolveRef(n.oneOf[l]),u=e.step(s,a,t,r);if(eS(u))return u;let h=ex(e.validate(o,u,r));if(!((h=h.filter(e_)).length>0))return eE(n,a,l);i.push(...h)}return e.errors.oneOfPropertyError({property:s,value:o,pointer:r,schema:n,errors:i})}let i=[];for(let s=0;s<n.oneOf.length;s+=1){let o=e.resolveRef(n.oneOf[s]);e.isValid(t,o,r)&&i.push({schema:o,index:s})}if(1===i.length)return eE(n,i[0].schema,i[0].index);if("object"===ew(t)){let i;let s=-1,o=0;for(let r=0;r<n.oneOf.length;r+=1){let l=e.resolveRef(n.oneOf[r]),a=function(e,t,n,r){if(null==n||null==t.properties)return -1;let i=0,s=Object.keys(t.properties);for(let r=0;r<s.length;r+=1){let o=s[r];null!=n[o]&&e.isValid(n[o],t.properties[o],void 0)&&(i+=1)}return i}(e,l,t);o<a&&(o=a,i=n.oneOf[r],s=r)}return void 0===i?e.errors.oneOfError({value:JSON.stringify(t),pointer:r,schema:n,oneOf:n.oneOf}):eE(n,i,s)}return i.length>1?e.errors.multipleOneOfError({matches:i,pointer:r,schema:n,value:t}):e.errors.oneOfError({value:JSON.stringify(t),pointer:r,schema:n,oneOf:n.oneOf})}var eT=n("39714"),eN=n.n(eT);let eB=(e,t)=>t,eI=(e,t)=>eN()(e,t,{arrayMerge:eB}),eM=(e,t)=>{let n=e.concat(t);return n.filter((e,t)=>n.indexOf(e)===t)},e$=(e,t)=>eN()(e,t,{arrayMerge:eM});function eL(e,t){let n=ew(e);if(n!==ew(t))return e;let r=e$(e,t);return e.getOneOfOrigin?Object.defineProperty(r,"getOneOfOrigin",{enumerable:!1,value:e.getOneOfOrigin}):t.getOneOfOrigin&&Object.defineProperty(r,"getOneOfOrigin",{enumerable:!1,value:t.getOneOfOrigin}),r}function eR(e,...t){let n={};return Object.keys(e).forEach(r=>{!t.includes(r)&&(n[r]=e[r])}),e.getOneOfOrigin&&Object.defineProperty(n,"getOneOfOrigin",{enumerable:!1,value:e.getOneOfOrigin}),n}var ej=Function.prototype.toString,eq=Object.create,eV=Object.prototype.toString,ez=function(){function e(){this._keys=[],this._values=[]}return e.prototype.has=function(e){return!!~this._keys.indexOf(e)},e.prototype.get=function(e){return this._values[this._keys.indexOf(e)]},e.prototype.set=function(e,t){this._keys.push(e),this._values.push(t)},e}(),eU="undefined"!=typeof WeakMap?function(){return new WeakMap}:function(){return new ez};function eH(e){if(!e)return eq(null);var t=e.constructor;if(t===Object)return e===Object.prototype?{}:eq(e);if(t&&~ej.call(t).indexOf("[native code]"))try{return new t}catch(e){}return eq(e)}var eW="g"===/test/g.flags?function(e){return e.flags}:function(e){var t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t};function eG(e){var t=eV.call(e);return t.substring(8,t.length-1)}var eK="undefined"!=typeof Symbol?function(e){return e[Symbol.toStringTag]||eG(e)}:eG,eJ=Object.defineProperty,eQ=Object.getOwnPropertyDescriptor,eY=Object.getOwnPropertyNames,eZ=Object.getOwnPropertySymbols,eX=Object.prototype,e0=eX.hasOwnProperty,e1=eX.propertyIsEnumerable,e2="function"==typeof eZ,e3=e2?function(e){return eY(e).concat(eZ(e))}:eY;function e5(e,t,n){for(var r=e3(e),i=0,s=r.length,o=void 0,l=void 0;i<s;++i){if("callee"!==(o=r[i])&&"caller"!==o){if(!(l=eQ(e,o))){t[o]=n.copier(e[o],n);continue}!l.get&&!l.set&&(l.value=n.copier(l.value,n));try{eJ(t,o,l)}catch(e){t[o]=l.value}}}return t}function e8(e,t){return e.slice(0)}function e4(e,t){var n=new t.Constructor;return t.cache.set(e,n),e.forEach(function(e,r){n.set(r,t.copier(e,t))}),n}var e6=e2?function(e,t){var n=eH(t.prototype);for(var r in t.cache.set(e,n),e)e0.call(e,r)&&(n[r]=t.copier(e[r],t));for(var i=eZ(e),s=0,o=i.length,l=void 0;s<o;++s)l=i[s],e1.call(e,l)&&(n[l]=t.copier(e[l],t));return n}:function(e,t){var n=eH(t.prototype);for(var r in t.cache.set(e,n),e)e0.call(e,r)&&(n[r]=t.copier(e[r],t));return n};function e9(e,t){return new t.Constructor(e.valueOf())}function e7(e,t){return e}function te(e,t){var n=new t.Constructor;return t.cache.set(e,n),e.forEach(function(e){n.add(t.copier(e,t))}),n}var tt=Array.isArray,tn=Object.assign,tr=Object.getPrototypeOf||function(e){return e.__proto__},ti={array:function(e,t){var n=new t.Constructor;t.cache.set(e,n);for(var r=0,i=e.length;r<i;++r)n[r]=t.copier(e[r],t);return n},arrayBuffer:e8,blob:function(e,t){return e.slice(0,e.size,e.type)},dataView:function(e,t){return new t.Constructor(e8(e.buffer))},date:function(e,t){return new t.Constructor(e.getTime())},error:e7,map:e4,object:e6,regExp:function(e,t){var n=new t.Constructor(e.source,eW(e));return n.lastIndex=e.lastIndex,n},set:te},ts=tn({},ti,{array:function(e,t){var n=new t.Constructor;return t.cache.set(e,n),e5(e,n,t)},map:function(e,t){return e5(e,e4(e,t),t)},object:function(e,t){var n=eH(t.prototype);return t.cache.set(e,n),e5(e,n,t)},set:function(e,t){return e5(e,te(e,t),t)}});function to(e){var t,n={Arguments:(t=tn({},ti,e)).object,Array:t.array,ArrayBuffer:t.arrayBuffer,Blob:t.blob,Boolean:e9,DataView:t.dataView,Date:t.date,Error:t.error,Float32Array:t.arrayBuffer,Float64Array:t.arrayBuffer,Int8Array:t.arrayBuffer,Int16Array:t.arrayBuffer,Int32Array:t.arrayBuffer,Map:t.map,Number:e9,Object:t.object,Promise:e7,RegExp:t.regExp,Set:t.set,String:e9,WeakMap:e7,WeakSet:e7,Uint8Array:t.arrayBuffer,Uint8ClampedArray:t.arrayBuffer,Uint16Array:t.arrayBuffer,Uint32Array:t.arrayBuffer,Uint64Array:t.arrayBuffer},r=n.Array,i=n.Object;function s(e,t){if(t.prototype=t.Constructor=void 0,!e||"object"!=typeof e)return e;if(t.cache.has(e))return t.cache.get(e);if(t.prototype=tr(e),t.Constructor=t.prototype&&t.prototype.constructor,!t.Constructor||t.Constructor===Object)return i(e,t);if(tt(e))return r(e,t);var s=n[eK(e)];return s?s(e,t):"function"==typeof e.then?e:i(e,t)}return function(e){return s(e,{Constructor:void 0,cache:eU(),copier:s,prototype:void 0})}}to(tn({},ts,{}));var tl=to({});function ta(e,t,n){if(null!=t.if){if(!1===t.if)return t.else;if(t.if&&(t.then||t.else)){let r=e.validate(n,e.resolveRef(t.if));if(0===r.length&&t.then)return e.resolveRef(t.then);if(0!==r.length&&t.else)return e.resolveRef(t.else)}}}function tu(e,t,n){var r;let i={...null!==(r=e.resolveRef(t))&&void 0!==r?r:{}},s=ta(e,i,n);return s?s:eR(i,"if","then","else")}function th(e,t,n=e.rootSchema){let r=tl(n);for(let i=0;i<n.allOf.length;i+=1)r=eL(r,tu(e,n.allOf[i],t));return delete r.allOf,r}function tc(e,t){let{allOf:n}=t;if(!Array.isArray(n)||0===n.length)return;let r={};return n.forEach(t=>{r=eL(r,e.resolveRef(t))}),r}function tf(e){return"object"===ew(e)}function td(e,t,n){let{dependencies:r}=t;if(!tf(r)||!tf(n))return;let i=!1,s={required:[]};if(Object.keys(r).forEach(o=>{var l,a;if(null==n[o]&&!((null===(l=t.required)||void 0===l?void 0:l.includes(o))||(null===(a=s.required)||void 0===a?void 0:a.includes(o))))return;let u=r[o];if(Array.isArray(u)){i=!0,s.required.push(...u);return}if(tf(u)){i=!0,s=eL(s,e.resolveRef(u));return}}),i){var o;return s.required=(o=s.required).filter((e,t)=>o.indexOf(e)===t),s}}function tp(e,t,n){let r;if(!!Array.isArray(t.anyOf)&&0!==t.anyOf.length)return t.anyOf.forEach(t=>{t=e.resolveRef(t),e.isValid(n,t)&&(r=r?eL(r,t):t)}),r}function tm(e,t,n=e.rootSchema,r="#"){let{anyOf:i}=n;if(!Array.isArray(i)||0===i.length)return n;let s=tp(e,n,t);return null==s?e.errors.anyOfError({pointer:r,schema:n,value:t,anyOf:JSON.stringify(i)}):eR(eL(n,s),"anyOf")}let tg=["allOf","anyOf","oneOf","dependencies","if","then","else"],ty=["allOf","anyOf","oneOf","dependencies","if"],tb=["allOf","anyOf","oneOf","dependencies","if","then","else"];function tv(e,t,n,r){let i=function e(t,n,r,i){let s,o;if((n=t.resolveRef(n)).oneOf){let e=eP(t,r,n,i);eS(e)?o=e:e&&(s=eL(null!=s?s:{},e))}if(Array.isArray(n.allOf)){let o=n.allOf.map(n=>{if(function(e){let t=Object.keys(e);return -1!==ty.findIndex(e=>t.includes(e))}(n)){let s=e(t,n,r,i);return s?eR(s=eL(n,s),...tg):void 0}return n});o.length>0&&(s=eL(null!=s?s:{},tc(t,{allOf:o})))}let l=tp(t,n,r);l&&(s=eL(null!=s?s:{},l));let a=td(t,n,r);a&&(s=eL(null!=s?s:{},a));let u=ta(t,n,r);if(u&&(s=eL(null!=s?s:{},u)),null==s)return o;let h=e(t,s,r,i);return h&&(s=eL(s,h)),eR(s,...tg)}(e,t,n,r);return i?eR(i=eL(t,i),...tb):t}class tk{constructor(e,t){this.remotes={},this.errors={},this.typeKeywords={},this.validateKeyword={},this.validateType={},this.validateFormat={},this.config=e,this.typeKeywords=tl(e.typeKeywords),this.validateKeyword=Object.assign({},e.validateKeyword),this.validateType=Object.assign({},e.validateType),this.validateFormat=Object.assign({},e.validateFormat),this.errors=Object.assign({},e.errors),this.setSchema(t)}get rootSchema(){return this.__rootSchema}set rootSchema(e){if(null!=e)this.__rootSchema=this.config.compileSchema(this,e)}addRemoteSchema(e,t){this.config.addRemoteSchema(this,e,t)}compileSchema(e){var t;return this.config.compileSchema(this,e,null!==(t=this.rootSchema)&&void 0!==t?t:e)}createSchemaOf(e){return this.config.createSchemaOf(e)}each(e,t,n,r){return this.config.each(this,e,t,n,r)}eachSchema(e,t=this.rootSchema){return this.config.eachSchema(t,e)}getChildSchemaSelection(e,t){return this.config.getChildSchemaSelection(this,e,t)}getSchema(e){return this.config.getSchema(this,e)}getTemplate(e,t,n=this.config.templateDefaultOptions){return this.config.getTemplate(this,e,t,n)}isValid(e,t,n){return this.config.isValid(this,e,t,n)}resolveAnyOf(e,t,n){return this.config.resolveAnyOf(this,e,t,n)}resolveAllOf(e,t){return this.config.resolveAllOf(this,e,t)}resolveRef(e){return this.config.resolveRef(e,this.rootSchema)}resolveOneOf(e,t,n){return this.config.resolveOneOf(this,e,t,n)}setSchema(e){this.rootSchema=e}step(e,t,n,r){return this.config.step(this,e,t,n,r)}validate(e,t,n){return this.config.validate(this,e,t,n)}}function tw(e,t,n){n.id=n.id||t,e.remotes[t]=e.compileSchema(n)}var tD=n("67142"),tA=n.n(tD),tx=n("44091");let tC="[^?/{}*,()#]+",tE=`
|
|
3
|
-
root ::= ("#" recursion | recursion | (query | pattern) recursion* | "#" SEP? | SEP)
|
|
4
|
-
recursion ::= (SEP query | pattern)*
|
|
5
|
-
|
|
6
|
-
query ::= (ESC escaped ESC | property | all | any | regex) typecheck? lookahead?
|
|
7
|
-
property ::= ${tC}
|
|
8
|
-
regex ::= "{" [^}]+ "}"
|
|
9
|
-
SEP ::= "/"
|
|
10
|
-
all ::= "**"
|
|
11
|
-
any ::= "*"
|
|
12
|
-
|
|
13
|
-
typecheck ::= "?:" ("value" | "boolean" | "string" | "number" | "object" | "array")
|
|
14
|
-
lookahead ::= "?" expression ((andExpr | orExpr) expression)*
|
|
15
|
-
andExpr ::= S? "&&" S?
|
|
16
|
-
orExpr ::= S? "||" S?
|
|
17
|
-
|
|
18
|
-
expression ::= (exprProperty | ESC escaped ESC) ((isnot | is) (exprProperty | regex | ESC escaped ESC))*
|
|
19
|
-
exprProperty ::= [a-zA-Z0-9-_ $]+
|
|
20
|
-
escaped ::= [^"]+
|
|
21
|
-
is ::= ":"
|
|
22
|
-
isnot ::= ":!"
|
|
23
|
-
ESC ::= '"'
|
|
24
|
-
|
|
25
|
-
pattern ::= S? "(" (SEP query | pattern (orPattern? pattern)*)* ")" quantifier? S? lookahead?
|
|
26
|
-
quantifier ::= "+" | "*" | [0-9]+
|
|
27
|
-
orPattern ::= S? "," S?
|
|
28
|
-
|
|
29
|
-
S ::= [ ]*
|
|
30
|
-
`,tS=new tx.default.Parser(tE),t_=e=>tS.getAST(e),tO=(e,t)=>`${e}/${t}`,tF=Object.prototype.toString,tP=/Object|Array/,tT=e=>tP.test(tF.call(e)),tN=e=>tF.call(e).match(/\s([^\]]+)\]/).pop().toLowerCase();function tB(e){return new RegExp(e.text.replace(/(^{|}$)/g,""))}function tI(e){return Array.isArray(e)?e.map(function(e,t){return`${t}`}):"[object Object]"===Object.prototype.toString.call(e)?Object.keys(e):[]}let tM={mem:[],get(e,t){let n=e[0][t];if(!tM.mem.includes(n))return tT(n)&&tM.mem.push(n),[n,t,e[0],tO(e[3],t)]},reset(){tM.mem.length=0}},t$={any(e,t){let n=t[0];return tI(n).map(e=>[n[e],e,n,tO(t[3],e)])},all(e,t){var n,r;let i=[t];return n=t[0],r=(n,r)=>{let s=tM.get(t,r);s&&i.push(...t$.all(e,s))},Array.isArray(n)?n.forEach(r):"[object Object]"===Object.prototype.toString.call(n)&&Object.keys(n).forEach(function(e){r(n[e],e,n)}),i},regex(e,t){let n=tB(e),r=t[0];return tI(r).filter(e=>n.test(e)).map(e=>[r[e],e,r,tO(t[3],e)])}},tL={escaped:(e,t)=>tL.property(e,t),property:(e,t)=>{let n=e.text;if(t[0]&&void 0!==t[0][n])return[t[0][n],n,t[0],tO(t[3],n)]},typecheck:(e,t)=>{let n=e.text.replace(/^\?:/,"");return"value"===n?tT(t[0])?void 0:t:tN(t[0])===n?t:void 0},lookahead:(e,t)=>{let n=!0,r=!1;return e.children.forEach(e=>{if("expression"===e.type){let i=void 0!==tL.expression(e,t);n=!0===r?n||i:n&&i}else r="orExpr"===e.type}),n?t:void 0},expression:(e,t)=>{let n=e.children[0].text,r=e.children[1],i=e.children[2],s=t[0];if(!1!==tT(s))return function(e,t,n){let r;if(void 0===t)return void 0!==e;let i=`${e}`;return r="regex"===n.type?tB(n).test(i):i===n.text,"isnot"===t.type&&(r=!1===r&&void 0!==e),r}(s[n],r,i)?t:void 0}};function tR(e,t,n){var r,i,s,o,l,a;let u;if("query"===t.type){;let o;r=e,i=t,s=n,o=r,i.children.forEach(e=>{if(t$[e.type])o=function(e,t,n,r){let i=[];for(let s=0,o=t.length;s<o;s+=1)i.push(...e(n,t[s],n,r));return i}(t$[e.type],o,e,s);else if(tL[e.type])o=function(e,t,n,r){let i=[];for(let s=0,o=t.length;s<o;s+=1){let o=e(n,t[s],r);o&&i.push(o)}return i}(tL[e.type],o,e,s);else throw Error(`Unknown filter ${e.type}`)}),u=o}else if("pattern"===t.type)u=function(e,t,n){let r=[],i=t.children.find(e=>"quantifier"===e.type),s=function(e){if(null==e)return 1;if("*"===e||"+"===e)return 1/0;let t=parseInt(e);return isNaN(t)?1:t}(i&&i.text),o=e;i&&"*"===i.text&&r.push(...o);let l=0;for(;o.length>0&&l<s;)o=function(e,t,n){let r=[],i=e;return t.children.forEach(t=>{if("orPattern"===t.type){r.push(...i),i=e;return}i=tR(i,t,n)}),r.push(...i),r}(o,t,n),r.push(...o),l+=1;return r}(e,t,n);else{;let r;o=e,l=t,a=n,r=o,l.children.forEach(e=>r=tR(r,e,a)),u=r}return tM.reset(),tM.mem.push(e),u}let tj={value:e=>e.map(e=>e[0]),pointer:e=>e.map(e=>e[3]),all:e=>e,map:e=>{let t={};return e.forEach(e=>t[e[3]]=e[0]),t}};function tq(e,t,n=A.VALUE){var r,i;if(null==t)return[];""===(t=t.replace(/(\/$)/g,""))&&(t="#");let s=t_(t);if(null==s)throw Error(`empty ast for '${t}'`);if(""!==s.rest)throw Error(`Failed parsing queryString from: '${s.rest}'`);let o=(r=e,i=s,tM.reset(),tM.mem.push(r),tR([[r,null,null,"#"]],i));return"function"==typeof n?o.map(e=>n(...e)):tj[n]?tj[n](o):o}(c=A||(A={})).POINTER="pointer",c.VALUE="value",c.ALL="all",c.MAP="map",tq.POINTER=A.POINTER,tq.VALUE=A.VALUE,tq.ALL=A.ALL,tq.MAP=A.MAP;let tV=["root","recursion"],tz=e=>JSON.parse(JSON.stringify(e)),tU=Object.prototype.toString,tH=e=>tU.call(e).match(/\s([^\]]+)\]/).pop().toLowerCase(),tW=RegExp(`^("[^"]+"|${tC})$`),tG=["string","number","boolean","null"],tK=/^\[\d*\]$/,tJ=/^\[(\d+)\]$/,tQ=/^".+"$/,tY=/(^\[\d*\]$|^\d+$)/;function tZ(e){return parseInt(e.replace(/^(\[|\]$)/,""))}function tX(e){return tQ.test(e)?e.replace(/(^"|"$)/g,""):e}function t0(e,t,n,r){let i=e[0];if(/^\[\]$/.test(t)){i.push(n);let t=i.length-1;return[i[t],t,i,`${e[3]}/${t}}`]}if(null==r&&"object"===tH(i[t])&&"object"===tH(n))return Object.assign(i[t],n),[i[t],t,i,`${e[3]}/${t}}`];if(r===t1.INSERT_ITEMS||null==r&&tJ.test(t)){var s,o,l;let r=tZ(t);return s=i,o=r,l=n,s.length<=o?s[o]=l:s.splice(o,0,l),[i[r],r,i,`${e[3]}/${r}}`]}if(r===t1.REPLACE_ITEMS||null==r){let r=tZ(t);return i[r]=n,[i[r],r,i,`${e[3]}/${r}}`]}throw Error(`Unknown array index '${t}' with force-option '${r}'`)}function t1(e,t,n,r){var i;if(null==t)return tz(e);if(""===(t=t.replace(/(\/$)/g,"")))return tz(n);let s=tz(e),o=[[s,null,null,"#"]];let l=null==(i=t)||""===i?[]:function e(t,n=[]){return tV.includes(t.type)?(t.children.forEach(t=>e(t,n)),n):(n.push(t.text),n)}(t_(i)),a=l.pop(),u=tK.test(a)&&!1===tJ.test(a);if(!1===tW.test(a)||u)throw Error(`Unsupported query '${t}' ending with non-property`);return l.forEach((e,t)=>{var n,i,s,u;if("__proto__"===e||"prototyped"===e||"constructor"===e)return;if(!1===tW.test(e)){o=function(e,t){let n=[];return e.forEach(e=>n.push(...tq(e[0],t,A.ALL))),n}(o,e);return}let h=t>=l.length-1?a:l[t+1],c=tY.test(h);n=o,i=e,s=c,u=r,i=tX(i),o=n.filter(e=>!!(Array.isArray(e[0])&&tY.test(i))||!1===tG.includes(tH(e[0][i]))).map(e=>{let t=s?[]:{},n=e[0],r=tH(t),o=tH(n[i]);return Array.isArray(n)&&o!==r?t0(e,i,t,u):(n[i]=n[i]||t,[n[i],i,n,`${e[3]}/${i}`])})}),o.forEach(e=>{let t=n;"function"===tH(n)&&(t=n(e[3],a,e[0],`${e[3]}/${a}`));let i=e[0];if(Array.isArray(i))t0(e,a,t,r);else{let e=tX(a);if("__proto__"===e||"prototyped"===e||"constructor"===e)return;i[e]=t}}),s}(f=x||(x={})).REPLACE_ITEMS="replace",f.INSERT_ITEMS="insert",t1.REPLACE_ITEMS=x.REPLACE_ITEMS,t1.INSERT_ITEMS=x.INSERT_ITEMS;let t2={$ref:{type:!1},allOf:{type:!1,definitions:["allOf/*"]},anyOf:{type:!1,definitions:["anyOf/*"]},array:{type:!0,definitions:["allOf/*","anyOf/*","oneOf/*","not","items","items/*","additionalItems"],validationKeywords:["minItems","maxItems","uniqueItems"],keywords:["items","additionalItems","minItems","maxItems","uniqueItems"]},boolean:{type:!0},enum:{type:!1},integer:{type:!0,definitions:["allOf/*","anyOf/*","oneOf/*","not"],validationKeywords:["minimum","maximum","multipleOf"]},not:{type:!1,definitions:["not"]},number:{type:!0,definitions:["allOf/*","anyOf/*","oneOf/*","not"],validationKeywords:["minimum","maximum","multipleOf"]},null:{type:!0},object:{type:!0,definitions:["allOf/*","anyOf/*","oneOf/*","not","properties/*","additionalProperties","patternProperties/*","dependencies/*"],validationKeywords:["minProperties","maxProperties","required"],keywords:["properties","additionalProperties","patternProperties","dependencies","minProperties","maxProperties","required"]},oneOf:{type:!1,definitions:["oneOf/*"]},string:{type:!0,definitions:["allOf/*","anyOf/*","oneOf/*","not"],validationKeywords:["minLength","maxLength","pattern"]}},t3=Object.keys(t2).filter(e=>!1===t2[e].type),t5=Object.prototype.hasOwnProperty;function t8(e){if(!1===tf(e))return;if(e.enum)return"enum";let t=e.type;if(Array.isArray(t)||t2[t])return t;let n=t3.filter(t=>e[t]);if(1===n.length)return n[0];if(0===n.length){for(let t=0,n=t2.object.keywords.length;t<n;t+=1){let n=t2.object.keywords[t];if(t5.call(e,n))return"object"}for(let t=0,n=t2.array.keywords.length;t<n;t+=1){let n=t2.array.keywords[t];if(t5.call(e,n))return"array"}return}throw Error(`Mutiple typeIds [${n.join(", ")}] matched in ${JSON.stringify(e)}`)}function t4(e,t){if(!0!==this.callback(e,t))(function(e){let t;let n=[],r=t8(e);if(null==r)return n;if(Array.isArray(r)){t={};for(let e=0,n=r.length;e<n;e+=1)Object.assign(t,t2[r[e]])}else t=t2[r];return null==t.definitions?n:(t.definitions.forEach(t=>{tq(e,t,(e,t,r,i)=>{tf(e)&&t8(e)&&n.push({pointer:tA().join(tA().split(i),!1),def:e})})}),n)})(e).forEach(e=>this.nextTypeDefs(e.def,tA().join(t,e.pointer,!1)))}function t6(e,t,n,r="definitions"){let i=t[r];Object.keys(i).forEach(t=>{if(!1===i[t]||tf(i[t])){e.nextTypeDefs(i[t],tA().join(n,r,t,!1));return}})}function t9(e,t,n="#"){let r={callback:t,nextTypeDefs:t4};r.nextTypeDefs(e,n),null!=e.definitions&&(r.callback=(e,n)=>{t(e,n),null!=e.definitions&&t6(r,e,n)},t6(r,e,n)),null!=e.$defs&&(r.callback=(e,n)=>{t(e,n),null!=e.definitions&&t6(r,e,n)},t6(r,e,n,"$defs"))}let t7=/(#|\/)+$/,ne=/#$/,nt=/^[^:]+:\/\/[^/]+\//,nn=/\/[^/]*$/,nr=/#.*$/;function ni(e,t){return null==e&&null==t?"#":null==t?e.replace(ne,""):null==e?t.replace(ne,""):"#"===t[0]?`${e.replace(nr,"")}${t.replace(t7,"")}`:nt.test(t)?t.replace(ne,""):`${e.replace(nn,"")}/${t.replace(ne,"")}`}let ns=/(#|\/)+$/g,no=["",null,"#"],nl=/(#|\/)+$/g,na=e=>"object"===ew(e);function nu(e,t,n){let r;if(na(n)&&(n=n.__ref||n.$ref),null==n)return t;let i=n.replace(nl,"");if(e.remotes[i])return(r=e.remotes[i])&&r.$ref?nu(e,t,r.$ref):r;if(e.ids[n])return(r=(0,tD.get)(t,e.ids[n]))&&r.$ref?nu(e,t,r.$ref):r;let s=function(e){if(no.includes(e))return[];if(-1===(e=e.replace(ns,"")).indexOf("#")||0===e.indexOf("#"))return[e.replace(ns,"")];let t=e.split("#");return t[0]=t[0].replace(ns,""),t[1]=`#${t[1].replace(ns,"")}`,t}(n);if(0===s.length)return t;if(1===s.length){if(n=s[0],e.remotes[n])return r=e.remotes[n],nu(e,t,r.$ref);if(e.ids[n])return(r=(0,tD.get)(t,e.ids[n]))&&r.$ref?nu(e,t,r.$ref):r}if(2===s.length){let r=s[0];if(n=s[1],e.remotes[r])return e.remotes[r].getRef?e.remotes[r].getRef(n):nu(e,e.remotes[r],n);if(e.ids[r])return nu(e,(0,tD.get)(t,e.ids[r]),n)}return(r=(0,tD.get)(t,e.ids[n]||n))&&r.$ref?nu(e,t,r.$ref):r}let nh="__compiled",nc="__ref",nf=/(#|\/)+$/g;function nd(e,t,n,r=e.rootSchema,i="#"){n(r=e.resolveRef(r),t,i);let s=ew(t);"object"===s?Object.keys(t).forEach(s=>{let o=e.step(s,r,t,i),l=t[s];e.each(l,n,o,`${i}/${s}`)}):"array"===s&&t.forEach((s,o)=>{let l=e.step(o,r,t,i);e.each(s,n,l,`${i}/${o}`)})}let np={additionalItemsError:eA("AdditionalItemsError"),additionalPropertiesError:eA("AdditionalPropertiesError"),anyOfError:eA("AnyOfError"),allOfError:eA("AllOfError"),constError:eA("ConstError"),containsError:eA("ContainsError"),containsArrayError:eA("ContainsArrayError"),containsAnyError:eA("ContainsAnyError"),enumError:eA("EnumError"),forbiddenPropertyError:eA("ForbiddenPropertyError"),formatURLError:eA("FormatURLError"),formatURIError:eA("FormatURIError"),formatURIReferenceError:eA("FormatURIReferenceError"),formatURITemplateError:eA("FormatURITemplateError"),formatDateError:eA("FormatDateError"),formatDateTimeError:eA("FormatDateTimeError"),formatEmailError:eA("FormatEmailError"),formatHostnameError:eA("FormatHostnameError"),formatIPV4Error:eA("FormatIPV4Error"),formatIPV4LeadingZeroError:eA("FormatIPV4LeadingZeroError"),formatIPV6Error:eA("FormatIPV6Error"),formatIPV6LeadingZeroError:eA("FormatIPV6LeadingZeroError"),formatJsonPointerError:eA("FormatJsonPointerError"),formatRegExError:eA("FormatRegExError"),formatTimeError:eA("FormatTimeError"),invalidSchemaError:eA("InvalidSchemaError"),invalidDataError:eA("InvalidDataError"),invalidTypeError:eA("InvalidTypeError"),invalidPropertyNameError:eA("InvalidPropertyNameError"),maximumError:eA("MaximumError"),maxItemsError:eA("MaxItemsError"),maxLengthError:eA("MaxLengthError"),maxPropertiesError:eA("MaxPropertiesError"),minimumError:eA("MinimumError"),minItemsError:eA("MinItemsError"),minItemsOneError:eA("MinItemsOneError"),minLengthError:eA("MinLengthError"),minLengthOneError:eA("MinLengthOneError"),minPropertiesError:eA("MinPropertiesError"),missingDependencyError:eA("MissingDependencyError"),missingOneOfPropertyError:eA("MissingOneOfPropertyError"),multipleOfError:eA("MultipleOfError"),multipleOneOfError:eA("MultipleOneOfError"),noAdditionalPropertiesError:eA("NoAdditionalPropertiesError"),notError:eA("NotError"),oneOfError:eA("OneOfError"),oneOfPropertyError:eA("OneOfPropertyError"),patternError:eA("PatternError"),patternPropertiesError:eA("PatternPropertiesError"),requiredPropertyError:eA("RequiredPropertyError"),schemaWarning:eA("SchemaWarning"),typeError:eA("TypeError"),undefinedValueError:eA("UndefinedValueError"),uniqueItemsError:eA("UniqueItemsError"),unknownPropertyError:eA("UnknownPropertyError"),valueNotEmptyError:eA("ValueNotEmptyError")};var nm=n("1170"),ng=n.n(nm),ny=n("21391");let nb=RegExp("^([0-9]+)-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])[Tt]([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9]|60)(\\.[0-9]+)?(([Zz])|([\\+|\\-]([01][0-9]|2[0-3]):[0-5][0-9]))$"),nv=/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,nk=/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-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-f]{1,4}:){5}(((:[0-9a-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-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-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-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-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-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-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-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-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-f]{1,4}){1,7})|((:[0-9a-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}))|:)))$/i,nw=/^(?=.{1,255}$)[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?(?:\.[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?)*\.?$/,nD=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,nA=/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,nx=[0,31,28,31,30,31,30,31,31,30,31,30,31],nC=/^(?:\/(?:[^~/]|~0|~1)*)*$/,nE=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,nS=/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,n_=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,nO={date:(e,t,n,r)=>{if("string"!=typeof n||""===n)return;let i=n.match(nD);if(!i)return e.errors.formatDateTimeError({value:n,pointer:r,schema:t});let s=+i[1],o=+i[2],l=+i[3];if(!(o>=1)||!(o<=12)||!(l>=1)||!(l<=(2==o&&s%4==0&&(s%100!=0||s%400==0)?29:nx[o])))return e.errors.formatDateError({value:n,pointer:r,schema:t})},"date-time":(e,t,n,r)=>{if("string"==typeof n&&""!==n){if(""===n||nb.test(n))return"Invalid Date"===new Date(n).toString()?e.errors.formatDateTimeError({value:n,pointer:r,schema:t}):void 0;return e.errors.formatDateTimeError({value:n,pointer:r,schema:t})}},email:(e,t,n,r)=>{if("string"!=typeof n||""===n)return;if('"'===n[0])return e.errors.formatEmailError({value:n,pointer:r,schema:t});let[i,s,...o]=n.split("@");if(!i||!s||0!==o.length||i.length>64||s.length>253||"."===i[0]||i.endsWith(".")||i.includes("..")||!/^[a-z0-9.-]+$/i.test(s)||!/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+$/i.test(i)||!s.split(".").every(e=>/^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?$/i.test(e)))return e.errors.formatEmailError({value:n,pointer:r,schema:t})},"idn-email":(e,t,n,r)=>{if("string"==typeof n&&""!==n)try{(0,ny.parse)(n);return}catch(i){return e.errors.formatEmailError({value:n,pointer:r,schema:t})}},hostname:(e,t,n,r)=>{if(!("string"!=typeof n||""===n||nw.test(n)))return e.errors.formatHostnameError({value:n,pointer:r,schema:t})},ipv4:(e,t,n,r)=>{if("string"!=typeof n||""===n)return;if(n&&"0"===n[0])return e.errors.formatIPV4LeadingZeroError({value:n,pointer:r,schema:t});if(!(n.length<=15&&nv.test(n)))return e.errors.formatIPV4Error({value:n,pointer:r,schema:t})},ipv6:(e,t,n,r)=>{if("string"!=typeof n||""===n)return;if(n&&"0"===n[0])return e.errors.formatIPV6LeadingZeroError({value:n,pointer:r,schema:t});if(!(n.length<=45&&nk.test(n)))return e.errors.formatIPV6Error({value:n,pointer:r,schema:t})},"json-pointer":(e,t,n,r)=>{if(!("string"!=typeof n||""===n||nC.test(n)))return e.errors.formatJsonPointerError({value:n,pointer:r,schema:t})},"relative-json-pointer":(e,t,n,r)=>{if(!("string"!=typeof n||""===n||nE.test(n)))return e.errors.formatJsonPointerError({value:n,pointer:r,schema:t})},regex:(e,t,n,r)=>{if("string"==typeof n&&!1===/\\Z$/.test(n)){try{new RegExp(n);return}catch(e){}return e.errors.formatRegExError({value:n,pointer:r,schema:t})}if(!("object"==typeof n||"number"==typeof n||Array.isArray(n)))return e.errors.formatRegExError({value:n,pointer:r,schema:t})},time:(e,t,n,r)=>{if("string"==typeof n&&""!==n)return n.match(nA)?void 0:e.errors.formatDateTimeError({value:n,pointer:r,schema:t})},uri:(e,t,n,r)=>{if(!("string"!=typeof n||""===n||ng().isUri(n)))return e.errors.formatURIError({value:n,pointer:r,schema:t})},"uri-reference":(e,t,n,r)=>{if(!("string"!=typeof n||""===n||nS.test(n)))return e.errors.formatURIReferenceError({value:n,pointer:r,schema:t})},"uri-template":(e,t,n,r)=>{if(!("string"!=typeof n||""===n||n_.test(n)))return e.errors.formatURITemplateError({value:n,pointer:r,schema:t})},url:(e,t,n,r)=>{if(!(""===n||ng().isWebUri(n)))return e.errors.formatURLError({value:n,pointer:r,schema:t})}},nF={};function nP(e,t=nF){let{pointer:n="#",data:r,schema:i=e.rootSchema,withSchemaWarning:s=!1}=t,o=tA().split(n),l=function e(t,n,r,i,s=nF){if(0===r.length)return t.resolveRef(n);let o=r.shift();return eS(n=t.step(o,n,s,i))?n:(s=s[o],e(t,n,r,`${i}/${o}`,s))}(e,e.resolveRef(i),o,"#",r);if(!!s||(null==l?void 0:l.code)!=="schema-warning")return l}let nT=eC.templateDefaultOptions;function nN(e,t){let{$ref:n}=e;return null==n||(null==r[t]||null==r[t][n]?0:r[t][n])<eC.GET_TEMPLATE_RECURSION_LIMIT}function nB(e,t,n){let{$ref:i}=t;return null==i?t:(r[n]=r[n]||{},r[n][i]=r[n][i]||0,r[n][i]+=1,e.resolveRef(t))}function nI(e,t,n,r,i){if("object"!==ew(t))return Object.assign({pointer:r},t);if(!1===nN(t,r)&&null==n)return!1;let s=tl(nB(e,t,r));if(Array.isArray(t.anyOf)&&t.anyOf.length>0&&(nN(t.anyOf[0],`${r}/anyOf/0`)&&((s=eI(s,nB(e,t.anyOf[0],`${r}/anyOf/0`))).pointer=t.anyOf[0].$ref||s.pointer),delete s.anyOf),Array.isArray(t.allOf)&&t.allOf.map((e,t)=>nN(e,`${r}/allOf/${t}`)).reduceRight((e,t)=>e&&t,!0)){let o=[],l=tl(n);for(let n=0;n<t.allOf.length;n+=1)o.push(tu(e,t.allOf[n],l)),l=n$(e,l,{type:t.type,...o[n]},`${r}/allOf/${n}`,i);let a=tc(e,{allOf:o});a&&(s=eL(s,a))}return s.pointer=s.pointer||t.$ref||r,s}let nM=e=>e&&"object"==typeof e;function n$(e,t,n,r,i){var s;if(null==n)throw Error(`getTemplate: missing schema for data: ${JSON.stringify(t)}`);if(null==r)throw Error("Missing pointer");let o=nI(e,n,t,r,i);if(!nM(o))return;if(r=o.pointer,null==o?void 0:o.const)return o.const;if(Array.isArray(o.oneOf)){if(function(e){switch(ew(e)){case"string":case"array":return(null==e?void 0:e.length)===0;case"null":case"undefined":return!0;case"object":return 0===Object.keys(e).length;default:return!1}}(t)){let e=o.oneOf[0].type||o.type||o.const&&typeof o.const||ew(t);o={...o.oneOf[0],type:e}}else{let n=eP(e,t,o);if(eS(n)){if(null!=t&&!0!==i.removeInvalidData)return t;o=o.oneOf[0],t=void 0}else n.type=null!==(s=n.type)&&void 0!==s?s:o.type,o=n}}if(!nM(o)||null==o.type)return;if(t instanceof File)return t;let l=Array.isArray(o.type)?function(e,t,n){if(void 0==t){if(null!=n){let t=ew(n);if(e.includes(t))return t}return e[0]}let r=ew(t);return e.includes(r)?r:e[0]}(o.type,t,o.default):o.type,a=ew(t);if(null!=t&&a!==l&&!("number"===a&&"integer"===l)&&(t=function(e,t){if("string"===e)return JSON.stringify(t);if("string"!=typeof t)return null;try{if(typeof(t=JSON.parse(t))===e)return t}catch(e){}return null}(l,t)),null==nL[l]){if(i.removeInvalidData)return;return t}return nL[l](e,o,t,r,i)}let nL={null:(e,t,n)=>nR(t,n,null),string:(e,t,n)=>nR(t,n,""),number:(e,t,n)=>nR(t,n,0),integer:(e,t,n)=>nR(t,n,0),boolean:(e,t,n)=>nR(t,n,!1),object:(e,t,n,r,i)=>{var s;let o=void 0===t.default?{}:t.default,l={},a=!1===i.extendDefaults&&void 0!==t.default?[]:null!==(s=t.required)&&void 0!==s?s:[];t.properties&&Object.keys(t.properties).forEach(s=>{let u=null==n||null==n[s]?o[s]:n[s],h=a.includes(s);(null!=u||h||i.addOptionalProps)&&(l[s]=n$(e,u,t.properties[s],`${r}/properties/${s}`,i))});let u=td(e,t,l);u&&(u=eL(t,u),delete u.dependencies,Object.assign(l,n$(e,n,u,`${r}/dependencies`,i))),n&&(!0===i.removeInvalidData&&(!1===t.additionalProperties||"object"===ew(t.additionalProperties))?"object"===ew(t.additionalProperties)&&Object.keys(n).forEach(r=>{null==l[r]&&e.isValid(n[r],t.additionalProperties)&&(l[r]=n[r])}):Object.keys(n).forEach(e=>null==l[e]&&(l[e]=n[e])));let h=ta(e,t,l);if(h){let t=n$(e,l,{type:"object",...h},r,i);Object.assign(l,t)}return l},array:(e,t,n,r,i)=>{var s,o;if(null==t.items)return n||[];let l=void 0===t.default?[]:t.default,a=n||l,u=!1===i.extendDefaults&&void 0!==t.default?0:t.minItems||0;if(Array.isArray(t.items)){for(let n=0,h=Math.max(null!=u?u:0,null!==(o=null===(s=t.items)||void 0===s?void 0:s.length)&&void 0!==o?o:0);n<h;n+=1)a[n]=n$(e,null==a[n]?l[n]:a[n],t.items[n],`${r}/items/${n}`,i);return a}if("object"!==ew(t.items))return a;let h=nI(e,t.items,n,r,i);if(!1===h)return a;if(r=h.pointer||r,h.oneOf&&0===a.length){let t=h.oneOf[0];for(let n=0;n<u;n+=1)a[n]=n$(e,null==a[n]?l[n]:a[n],t,`${r}/oneOf/0`,i);return a}if(h.oneOf&&a.length>0){let t=Math.max(u,a.length);for(let n=0;n<t;n+=1){let t=null==a[n]?l[n]:a[n],s=eP(e,t,h);null==s||eS(s)?null!=t&&!0!==i.removeInvalidData?a[n]=t:(t=void 0,s=h.oneOf[0],a[n]=n$(e,t,s,`${r}/oneOf/${n}`,i)):a[n]=n$(e,t,s,`${r}/oneOf/${n}`,i)}return a}if(h.type)for(let t=0,n=Math.max(u,a.length);t<n;t+=1)a[t]=n$(e,null==a[t]?l[t]:a[t],h,`${r}/items`,i);return a}};function nR(e,t,n){if(null!=t)return t;if(e.const)return e.const;if(void 0===e.default&&Array.isArray(e.enum))return e.enum[0];else if(void 0===e.default)return n;return e.default}let nj=(e,t,n=e.rootSchema,i)=>(r={},i)?n$(e,t,n,"#",{...nT,...i}):n$(e,t,n,"#",nT);function nq(e,t,n=e.rootSchema,r="#"){return 0===e.validate(t,n,r).length}function nV(e){let t=[],n=0,r=e.length;for(;n<r;){let i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){let r=e.charCodeAt(n++);(64512&r)==56320?t.push(((1023&i)<<10)+(1023&r)+65536):(t.push(i),n--)}else t.push(i)}return t}function nz(e){let t=`${e}`,n=t.indexOf(".");return -1===n?0:t.length-(n+1)}var nU=n("69378"),nH=n.n(nU);let nW=Object.prototype.hasOwnProperty,nG=(e,t)=>!(void 0===e[t]||!nW.call(e,t)),nK={additionalProperties:(e,t,n,r)=>{if(!0===t.additionalProperties||null==t.additionalProperties||"object"===ew(t.patternProperties)&&!1===t.additionalProperties)return;let i=[],s=Object.keys(n).filter(e=>!1===eC.propertyBlacklist.includes(e)),o=Object.keys(t.properties||{});if("object"===ew(t.patternProperties)){let e=Object.keys(t.patternProperties).map(e=>new RegExp(e));s=s.filter(t=>{for(let n=0;n<e.length;n+=1)if(e[n].test(t))return!1;return!0})}for(let l=0,a=s.length;l<a;l+=1){let a=s[l];if(-1===o.indexOf(a)){let u=tf(t.additionalProperties);if(u&&Array.isArray(t.additionalProperties.oneOf)){let u=e.resolveOneOf(n[a],t.additionalProperties,`${r}/${a}`);eS(u)?i.push(e.errors.additionalPropertiesError({pointer:r,schema:t.additionalProperties,value:n,property:s[l],properties:o,errors:u.data.errors})):i.push(...e.validate(n[a],u,r))}else u?i.push(...e.validate(n[a],t.additionalProperties,`${r}/${a}`)):i.push(e.errors.noAdditionalPropertiesError({pointer:r,schema:t,value:n,property:s[l],properties:o}))}}return i},allOf:(e,t,n,r)=>{let{allOf:i}=t;if(!Array.isArray(i)||0===i.length)return;let s=[];return t.allOf.forEach(t=>{s.push(...e.validate(n,t,r))}),s},anyOf:(e,t,n,r)=>{if(!!Array.isArray(t.anyOf)&&0!==t.anyOf.length){for(let r=0;r<t.anyOf.length;r+=1)if(e.isValid(n,t.anyOf[r]))return;return e.errors.anyOfError({pointer:r,schema:t,value:n,anyOf:t.anyOf})}},dependencies:(e,t,n,r)=>{if("object"!==ew(t.dependencies))return;let i=[];return Object.keys(n).forEach(s=>{let o;if(void 0===t.dependencies[s]||!0===t.dependencies[s])return;if(!1===t.dependencies[s]){i.push(e.errors.missingDependencyError({pointer:r,schema:t,value:n}));return}let l=ew(t.dependencies[s]);if("array"===l)o=t.dependencies[s].filter(e=>void 0===n[e]).map(i=>e.errors.missingDependencyError({missingProperty:i,pointer:r,schema:t,value:n}));else if("object"===l)o=e.validate(n,t.dependencies[s],r);else throw Error(`Invalid dependency definition for ${r}/${s}. Must be string[] or schema`);i.push(...o)}),i.length>0?i:void 0},enum:(e,t,n,r)=>{let i=ew(n);if("object"===i||"array"===i){let e=JSON.stringify(n);for(let n=0;n<t.enum.length;n+=1)if(JSON.stringify(t.enum[n])===e)return}else if(t.enum.includes(n))return;return e.errors.enumError({pointer:r,schema:t,value:n,values:t.enum})},format:(e,t,n,r)=>{if(e.validateFormat[t.format])return e.validateFormat[t.format](e,t,n,r)},items:(e,t,n,r)=>{if(!1===t.items){if(Array.isArray(n)&&0===n.length)return;return e.errors.invalidDataError({pointer:r,value:n,schema:t})}let i=[];for(let s=0;s<n.length;s+=1){let o=n[s],l=e.step(s,t,n,r);if(eS(l))return[l];let a=e.validate(o,l,`${r}/${s}`);i.push(...a)}return i},maximum:(e,t,n,r)=>isNaN(t.maximum)?void 0:t.maximum&&t.maximum<n?e.errors.maximumError({maximum:t.maximum,length:n,value:n,pointer:r,schema:t}):t.maximum&&!0===t.exclusiveMaximum&&t.maximum===n?e.errors.maximumError({maximum:t.maximum,length:n,pointer:r,schema:t,value:n}):void 0,maxItems:(e,t,n,r)=>{if(!isNaN(t.maxItems)){if(t.maxItems<n.length)return e.errors.maxItemsError({maximum:t.maxItems,length:n.length,schema:t,value:n,pointer:r})}},maxLength:(e,t,n,r)=>{if(isNaN(t.maxLength))return;let i=nV(n).length;if(t.maxLength<i)return e.errors.maxLengthError({maxLength:t.maxLength,length:i,pointer:r,schema:t,value:n})},maxProperties:(e,t,n,r)=>{let i=Object.keys(n).length;if(!1===isNaN(t.maxProperties)&&t.maxProperties<i)return e.errors.maxPropertiesError({maxProperties:t.maxProperties,length:i,pointer:r,schema:t,value:n})},minLength:(e,t,n,r)=>{if(isNaN(t.minLength))return;let i=nV(n).length;if(t.minLength>i)return 1===t.minLength?e.errors.minLengthOneError({minLength:t.minLength,length:i,pointer:r,schema:t,value:n}):e.errors.minLengthError({minLength:t.minLength,length:i,pointer:r,schema:t,value:n})},minimum:(e,t,n,r)=>{if(!isNaN(t.minimum)){if(t.minimum>n||!0===t.exclusiveMinimum&&t.minimum===n)return e.errors.minimumError({minimum:t.minimum,length:n,pointer:r,schema:t,value:n})}},minItems:(e,t,n,r)=>{if(!isNaN(t.minItems)){if(t.minItems>n.length)return 1===t.minItems?e.errors.minItemsOneError({minItems:t.minItems,length:n.length,pointer:r,schema:t,value:n}):e.errors.minItemsError({minItems:t.minItems,length:n.length,pointer:r,schema:t,value:n})}},minProperties:(e,t,n,r)=>{if(isNaN(t.minProperties))return;let i=Object.keys(n).length;if(t.minProperties>i)return e.errors.minPropertiesError({minProperties:t.minProperties,length:i,pointer:r,schema:t,value:n})},multipleOf:(e,t,n,r)=>{if(isNaN(t.multipleOf)||"number"!=typeof n)return;let i=nz(n),s=nz(t.multipleOf);if(i>s)return e.errors.multipleOfError({multipleOf:t.multipleOf,value:n,pointer:r,schema:t});let o=Math.pow(10,s);if(Math.round(n*o)%Math.round(t.multipleOf*o)/o!=0)return e.errors.multipleOfError({multipleOf:t.multipleOf,value:n,pointer:r,schema:t})},not:(e,t,n,r)=>{let i=[];return 0===e.validate(n,t.not,r).length&&i.push(e.errors.notError({value:n,not:t.not,pointer:r,schema:t})),i},oneOf:(e,t,n,r)=>{if(Array.isArray(t.oneOf)){let i=e.resolveOneOf(n,t,r);if(eS(i))return i}},pattern:(e,t,n,r)=>{if(!1===RegExp(t.pattern,"u").test(n))return e.errors.patternError({pattern:t.pattern,description:t.patternExample||t.pattern,received:n,schema:t,value:n,pointer:r})},patternProperties:(e,t,n,r)=>{let i=t.properties||{},s=t.patternProperties;if("object"!==ew(s))return;let o=[],l=Object.keys(n),a=Object.keys(s).map(e=>({regex:new RegExp(e),patternSchema:s[e]}));return l.forEach(l=>{let u=!1;for(let t=0,i=a.length;t<i;t+=1)if(a[t].regex.test(l)){u=!0;let i=e.validate(n[l],a[t].patternSchema,`${r}/${l}`);i&&i.length>0&&o.push(...i)}if(!i[l])!1===u&&!1===t.additionalProperties&&o.push(e.errors.patternPropertiesError({key:l,pointer:r,schema:t,value:n,patterns:Object.keys(s).join(",")}))}),o},properties:(e,t,n,r)=>{let i=[],s=Object.keys(t.properties||{});for(let o=0;o<s.length;o+=1){let l=s[o];if(nG(n,l)){let s=e.step(l,t,n,r),o=e.validate(n[l],s,`${r}/${l}`);i.push(...o)}}return i},propertiesRequired:(e,t,n,r)=>{let i=[],s=Object.keys(t.properties||{});for(let o=0;o<s.length;o+=1){let l=s[o];if(void 0===n[l])i.push(e.errors.requiredPropertyError({key:l,pointer:r,schema:t,value:n}));else{let s=e.step(l,t,n,r),o=e.validate(n[l],s,`${r}/${l}`);i.push(...o)}}return i},required:(e,t,n,r)=>{if(!1!==Array.isArray(t.required))return t.required.map(i=>{if(!nG(n,i))return e.errors.requiredPropertyError({key:i,pointer:r,schema:t,value:n})})},requiredNotEmpty:(e,t,n,r)=>{if(!1!==Array.isArray(t.required))return t.required.map(i=>{if(null==n[i]||""===n[i])return e.errors.valueNotEmptyError({property:i,pointer:`${r}/${i}`,schema:t,value:n})})},uniqueItems:(e,t,n,r)=>{if(!1===(Array.isArray(n)&&t.uniqueItems))return;let i=[],s=[];return n.forEach((o,l)=>{for(let a=l+1;a<n.length;a+=1)nH()(o,n[a])&&!i.includes(a)&&(s.push(e.errors.uniqueItemsError({pointer:`${r}/${a}`,duplicatePointer:`${r}/${l}`,arrayPointer:r,value:JSON.stringify(o),schema:t})),i.push(a))}),s}};function nJ(e,t){return null==e||null==e.$ref?e:e.getRoot?e.getRoot().getRef(e):t.getRef(e)}function nQ(e){if(void 0===e)return;let t={type:ew(e)};return"object"===t.type&&tf(e)&&(t.properties={},Object.keys(e).forEach(n=>t.properties[n]=nQ(e[n]))),"array"===t.type&&Array.isArray(e)&&(1===e.length?t.items=nQ(e[0]):t.items=e.map(nQ)),t}let nY={array:(e,t,n,r,i)=>{let s=null==r?void 0:r[t],o=ew(n.items);if("object"===o)return tv(e,n.items,s,`${i}/${t}`)||e.resolveRef(n.items);if("array"===o){if(!0===n.items[t])return nQ(s);if(!1===n.items[t])return e.errors.invalidDataError({key:t,value:s,pointer:i,schema:n});if(n.items[t])return e.resolveRef(n.items[t]);if(!1===n.additionalItems)return e.errors.additionalItemsError({key:t,value:s,pointer:i,schema:n});if(!0===n.additionalItems||void 0===n.additionalItems)return nQ(s);if("object"===ew(n.additionalItems))return n.additionalItems;throw Error(`Invalid schema ${JSON.stringify(n,null,2)} for ${JSON.stringify(r,null,2)}`)}return!1!==n.additionalItems&&s?nQ(s):Error(`Invalid array schema for ${t} at ${i}`)},object:(e,t,n,r,i)=>{var s;let o=null===(s=null==(n=tv(e,n,r,i))?void 0:n.properties)||void 0===s?void 0:s[t];if(void 0!==o){if(!1===o)return e.errors.forbiddenPropertyError({property:t,value:r,pointer:i,schema:n});if(!0===o)return nQ(null==r?void 0:r[t]);let s=e.resolveRef(o);if(eS(s))return s;if(s&&Array.isArray(s.oneOf)){let n=e.resolveOneOf(r[t],s,`${i}/${t}`);for(let e in s)"oneOf"!==e&&void 0===n[e]&&(n[e]=s[e]);return n}if(s)return s}let{patternProperties:l}=n;if("object"===ew(l)){let e=Object.keys(l);for(let n=0,r=e.length;n<r;n+=1)if(new RegExp(e[n]).test(t))return l[e[n]]}let{additionalProperties:a}=n;return"object"===ew(a)?n.additionalProperties:r&&(void 0===a||!0===a)?nQ(r[t]):e.errors.unknownPropertyError({property:t,value:r,pointer:`${i}`,schema:n})}};function nZ(e,t,n,r,i="#"){var s;let o=ew(r),l=null!==(s=n.type)&&void 0!==s?s:o;if(Array.isArray(l)){if(!l.includes(o))return e.errors.typeError({value:r,pointer:i,expected:n.type,received:o,schema:n});l=o}let a=nY[l];if(a){let s=a(e,`${t}`,n,r,i);return void 0===s?e.errors.schemaWarning({pointer:i,value:r,schema:n,key:t}):s}return Error(`Unsupported schema type ${n.type} for key ${t}`)}function nX(e,t,n=e.rootSchema){var r;if(n.oneOf)return n.oneOf.map(t=>e.resolveRef(t));if(null===(r=n.items)||void 0===r?void 0:r.oneOf)return n.items.oneOf.map(t=>e.resolveRef(t));let i=e.step(t,n,{},"#");return eS(i)?i:[i]}function n0(e,t,n=e.rootSchema,r="#"){if("boolean"===ew(n=e.resolveRef(n)))return n?[]:[e.errors.invalidDataError({pointer:r,schema:n,value:t})];if(eS(n))return[n];if(void 0!==n.const)return nH()(n.const,t)?[]:[e.errors.constError({pointer:r,schema:n,value:t,expected:n.const})];let i=function(e,t){let n=ew(e);return"number"===n&&("integer"===t||Array.isArray(t)&&t.includes("integer"))?Number.isInteger(e)||isNaN(e)?"integer":"number":n}(t,n.type),s=n.type||i;return i===s||Array.isArray(s)&&s.includes(i)?null==e.validateType[i]?[e.errors.invalidTypeError({pointer:r,schema:n,value:t,receivedType:i})]:ex(e.validateType[i](e,n,t,r)).filter(e_):[e.errors.typeError({pointer:r,schema:n,value:t,received:i,expected:s})]}let n1={typeKeywords:{array:["allOf","anyOf","enum","items","maxItems","minItems","not","oneOf","uniqueItems"],boolean:["enum","not","allOf","anyOf","oneOf"],object:["additionalProperties","dependencies","enum","format","minProperties","maxProperties","patternProperties","properties","required","not","oneOf","allOf","anyOf"],string:["allOf","anyOf","enum","format","maxLength","minLength","not","oneOf","pattern"],number:["allOf","anyOf","enum","format","maximum","minimum","multipleOf","not","oneOf"],null:["allOf","anyOf","enum","format","not","oneOf"]},validateKeyword:nK,validateType:{array:(e,t,n,r)=>e.typeKeywords.array.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),object:(e,t,n,r)=>e.typeKeywords.object.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),string:(e,t,n,r)=>e.typeKeywords.string.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),integer:(e,t,n,r)=>e.typeKeywords.number.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),number:(e,t,n,r)=>e.typeKeywords.number.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),boolean:(e,t,n,r)=>e.typeKeywords.boolean.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),null:(e,t,n,r)=>e.typeKeywords.null.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r))},validateFormat:nO,errors:np,addRemoteSchema:tw,compileSchema:function(e,t,n=t,r=!1){if(!t||void 0!==t[nh])return t;let i={ids:{},remotes:e.remotes},s=JSON.stringify(t),o=JSON.parse(s);if(Object.defineProperty(o,nh,{enumerable:!1,value:!0}),Object.defineProperty(o,"getRef",{enumerable:!1,value:nu.bind(null,i,o)}),!1===r&&!1===s.includes("$ref"))return o;t!==n&&Object.defineProperty(o,"definitions",{enumerable:!1,value:Object.assign({},n.definitions,n.$defs,t.definitions,t.$defs)});let l={},a=()=>o;return t9(o,(e,t)=>{var n;if(e.id){if(e.id.startsWith("http")&&/(allOf|anyOf|oneOf)\/\d+$/.test(t)){let r=t.replace(/\/(allOf|anyOf|oneOf)\/\d+$/,""),i=(0,tD.get)(o,r);e.id=null!==(n=i.id)&&void 0!==n?n:e.id}i.ids[e.id.replace(nf,"")]=t}let r=(t=`#${t}`.replace(/##+/,"#")).replace(/\/[^/]+$/,""),s=t.replace(/\/[^/]+\/[^/]+$/,""),u=ni(l[r]||l[s],e.id);l[t]=u,null==i.ids[u]&&(i.ids[u]=t),e.$ref&&!e[nc]&&(Object.defineProperty(e,nc,{enumerable:!1,value:ni(u,e.$ref)}),Object.defineProperty(e,"getRoot",{enumerable:!1,value:a}))}),o},createSchemaOf:nQ,each:nd,eachSchema:t9,getChildSchemaSelection:nX,getSchema:nP,getTemplate:nj,isValid:nq,resolveAllOf:th,resolveAnyOf:tm,resolveOneOf:eF,resolveRef:nJ,step:nZ,validate:n0,templateDefaultOptions:eC.templateDefaultOptions};class n2 extends tk{constructor(e,t={}){super(eI(n1,t),e)}}let n3="__compiled",n5="__ref",n8=/(#|\/)+$/g,n4={...nK,contains:(e,t,n,r)=>{if(!1===t.contains)return e.errors.containsArrayError({pointer:r,value:n,schema:t});if(!0===t.contains)return Array.isArray(n)&&0===n.length?e.errors.containsAnyError({pointer:r,value:n,schema:t}):void 0;if("object"===ew(t.contains)){for(let r=0;r<n.length;r+=1)if(e.isValid(n[r],t.contains))return;return e.errors.containsError({pointer:r,schema:t,value:n})}},exclusiveMaximum:(e,t,n,r)=>{if(!isNaN(t.exclusiveMaximum)){if(t.exclusiveMaximum<=n)return e.errors.maximumError({maximum:t.exclusiveMaximum,length:n,pointer:r,schema:t,value:n})}},exclusiveMinimum:(e,t,n,r)=>{if(!isNaN(t.exclusiveMinimum)){if(t.exclusiveMinimum>=n)return e.errors.minimumError({minimum:t.exclusiveMinimum,length:n,pointer:r,schema:t,value:n})}},if:(e,t,n,r)=>{let i=ta(e,t,n);if(i)return e.validate(n,i,r)},maximum:(e,t,n,r)=>{if(!isNaN(t.maximum)){if(t.maximum&&t.maximum<n)return e.errors.maximumError({maximum:t.maximum,length:n,pointer:r,schema:t,value:n})}},minimum:(e,t,n,r)=>{if(!isNaN(t.minimum)){if(t.minimum>n)return e.errors.minimumError({minimum:t.minimum,length:n,pointer:r,schema:t,value:n})}},patternProperties:(e,t,n,r)=>{let i=t.properties||{},s=t.patternProperties;if("object"!==ew(s))return;let o=[],l=Object.keys(n),a=Object.keys(s).map(e=>({regex:new RegExp(e),patternSchema:s[e]}));return l.forEach(l=>{let u=!1;for(let i=0,h=a.length;i<h;i+=1)if(a[i].regex.test(l)){if(u=!0,!1===a[i].patternSchema){o.push(e.errors.patternPropertiesError({key:l,pointer:r,patterns:Object.keys(s).join(","),schema:t,value:n}));return}let h=e.validate(n[l],a[i].patternSchema,`${r}/${l}`);h&&h.length>0&&o.push(...h)}if(!i[l])!1===u&&!1===t.additionalProperties&&o.push(e.errors.patternPropertiesError({key:l,pointer:r,patterns:Object.keys(s).join(","),schema:t,value:n}))}),o},propertyNames:(e,t,n,r)=>{if(!1===t.propertyNames){if(0===Object.keys(n).length)return;return e.errors.invalidPropertyNameError({property:Object.keys(n),pointer:r,value:n,schema:t})}if(!0===t.propertyNames||"object"!==ew(t.propertyNames))return;let i=[],s=Object.keys(n),o={...t.propertyNames,type:"string"};return s.forEach(s=>{let l=e.validate(s,o,`${r}/${s}`);l.length>0&&i.push(e.errors.invalidPropertyNameError({property:s,pointer:r,validationError:l[0],value:n[s],schema:t}))}),i}};eC.templateDefaultOptions;let n6={typeKeywords:{array:["allOf","anyOf","contains","enum","if","items","maxItems","minItems","not","oneOf","uniqueItems"],boolean:["allOf","anyOf","enum","not","oneOf"],object:["additionalProperties","allOf","anyOf","dependencies","enum","format","if","maxProperties","minProperties","not","oneOf","patternProperties","properties","propertyNames","required"],string:["allOf","anyOf","enum","format","if","maxLength","minLength","not","oneOf","pattern"],number:["allOf","anyOf","enum","exclusiveMaximum","exclusiveMinimum","format","if","maximum","minimum","multipleOf","not","oneOf"],null:["allOf","anyOf","enum","format","not","oneOf"]},validateKeyword:n4,validateType:{array:(e,t,n,r)=>e.typeKeywords.array.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),object:(e,t,n,r)=>e.typeKeywords.object.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),string:(e,t,n,r)=>e.typeKeywords.string.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),integer:(e,t,n,r)=>e.typeKeywords.number.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),number:(e,t,n,r)=>e.typeKeywords.number.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),boolean:(e,t,n,r)=>e.typeKeywords.boolean.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r)),null:(e,t,n,r)=>e.typeKeywords.null.filter(e=>t&&null!=t[e]).map(i=>e.validateKeyword[i](e,t,n,r))},validateFormat:nO,errors:np,addRemoteSchema:tw,compileSchema:function(e,t,n=t,r=!1){if(!0===t||!1===t||void 0===t||void 0!==t[n3])return t;let i={ids:{},remotes:e.remotes},s=JSON.stringify(t),o=JSON.parse(s);if(Object.defineProperty(o,n3,{enumerable:!1,value:!0}),Object.defineProperty(o,"getRef",{enumerable:!1,value:nu.bind(null,i,o)}),!1===r&&!1===s.includes("$ref"))return o;o!==n&&Object.defineProperty(o,"$defs",{enumerable:!0,value:Object.assign({},n.definitions,n.$defs,o.definitions,o.$defs)});let l={},a=()=>o;return t9(o,(e,t)=>{var n;if(e.$id){if(e.$id.startsWith("http")&&/(allOf|anyOf|oneOf)\/\d+$/.test(t)){let r=t.replace(/\/(allOf|anyOf|oneOf)\/\d+$/,""),i=(0,tD.get)(o,r);e.$id=null!==(n=i.$id)&&void 0!==n?n:e.$id}i.ids[e.$id.replace(n8,"")]=t}let r=(t=`#${t}`.replace(/##+/,"#")).replace(/\/[^/]+$/,""),s=t.replace(/\/[^/]+\/[^/]+$/,""),u=ni(l[r]||l[s],e.$id);l[t]=u,null==i.ids[u]&&(i.ids[u]=t),e.$ref&&!e[n5]&&(Object.defineProperty(e,n5,{enumerable:!1,value:ni(u,e.$ref)}),Object.defineProperty(e,"getRoot",{enumerable:!1,value:a}))}),o},createSchemaOf:nQ,each:nd,eachSchema:t9,getChildSchemaSelection:nX,getSchema:nP,getTemplate:nj,isValid:nq,resolveAllOf:th,resolveAnyOf:tm,resolveOneOf:eF,resolveRef:nJ,step:nZ,validate:n0,templateDefaultOptions:eC.templateDefaultOptions};class n9 extends tk{constructor(e,t={}){super(eI(n6,t),e)}}({...n6});let n7={};function re(e,t){"string"!=typeof t&&(t=re.defaultChars);let n=function(e){let t=n7[e];if(t)return t;t=n7[e]=[];for(let e=0;e<128;e++){let n=String.fromCharCode(e);t.push(n)}for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t[r]="%"+("0"+r.toString(16).toUpperCase()).slice(-2)}return t}(t);return e.replace(/(%[a-f0-9]{2})+/gi,function(e){let t="";for(let r=0,i=e.length;r<i;r+=3){let s=parseInt(e.slice(r+1,r+3),16);if(s<128){t+=n[s];continue}if((224&s)==192&&r+3<i){let n=parseInt(e.slice(r+4,r+6),16);if((192&n)==128){let e=s<<6&1984|63&n;e<128?t+="��":t+=String.fromCharCode(e),r+=3;continue}}if((240&s)==224&&r+6<i){let n=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16);if((192&n)==128&&(192&i)==128){let e=s<<12&61440|n<<6&4032|63&i;e<2048||e>=55296&&e<=57343?t+="���":t+=String.fromCharCode(e),r+=6;continue}}if((248&s)==240&&r+9<i){let n=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16),o=parseInt(e.slice(r+10,r+12),16);if((192&n)==128&&(192&i)==128&&(192&o)==128){let e=s<<18&1835008|n<<12&258048|i<<6&4032|63&o;e<65536||e>1114111?t+="����":(e-=65536,t+=String.fromCharCode(55296+(e>>10),56320+(1023&e))),r+=9;continue}}t+="�"}return t})}re.defaultChars=";/?:@&=+$,#",re.componentChars="";let rt=re,rn={};function rr(e,t,n){"string"!=typeof t&&(n=t,t=rr.defaultChars),void 0===n&&(n=!0);let r=function(e){let t=rn[e];if(t)return t;t=rn[e]=[];for(let e=0;e<128;e++){let n=String.fromCharCode(e);/^[0-9a-z]$/i.test(n)?t.push(n):t.push("%"+("0"+e.toString(16).toUpperCase()).slice(-2))}for(let n=0;n<e.length;n++)t[e.charCodeAt(n)]=e[n];return t}(t),i="";for(let t=0,s=e.length;t<s;t++){let o=e.charCodeAt(t);if(n&&37===o&&t+2<s&&/^[0-9a-f]{2}$/i.test(e.slice(t+1,t+3))){i+=e.slice(t,t+3),t+=2;continue}if(o<128){i+=r[o];continue}if(o>=55296&&o<=57343){if(o>=55296&&o<=56319&&t+1<s){let n=e.charCodeAt(t+1);if(n>=56320&&n<=57343){i+=encodeURIComponent(e[t]+e[t+1]),t++;continue}}i+="%EF%BF%BD";continue}i+=encodeURIComponent(e[t])}return i}rr.defaultChars=";/?:@&=+$,-_.!~*'()#",rr.componentChars="-_.!~*'()";let ri=rr;function rs(e){let t="";return t+=e.protocol||"",t+=(e.slashes?"//":"")+(e.auth?e.auth+"@":""),e.hostname&&-1!==e.hostname.indexOf(":")?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||""}function ro(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}let rl=/^([a-z0-9.+-]+:)/i,ra=/:[0-9]*$/,ru=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,rh=["%","/","?",";","#"].concat(["'"].concat(["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n"," "]))),rc=["/","?","#"],rf=/^[+a-z0-9A-Z_-]{0,63}$/,rd=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,rp={javascript:!0,"javascript:":!0},rm={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};ro.prototype.parse=function(e,t){let n,r,i;let s=e;if(s=s.trim(),!t&&1===e.split("#").length){let e=ru.exec(s);if(e)return this.pathname=e[1],e[2]&&(this.search=e[2]),this}let o=rl.exec(s);if(o&&(n=(o=o[0]).toLowerCase(),this.protocol=o,s=s.substr(o.length)),(t||o||s.match(/^\/\/[^@\/]+@[^@\/]+/))&&(i="//"===s.substr(0,2))&&!(o&&rp[o])&&(s=s.substr(2),this.slashes=!0),!rp[o]&&(i||o&&!rm[o])){let e,t,n=-1;for(let e=0;e<rc.length;e++)-1!==(r=s.indexOf(rc[e]))&&(-1===n||r<n)&&(n=r);-1!==(t=-1===n?s.lastIndexOf("@"):s.lastIndexOf("@",n))&&(e=s.slice(0,t),s=s.slice(t+1),this.auth=e),n=-1;for(let e=0;e<rh.length;e++)-1!==(r=s.indexOf(rh[e]))&&(-1===n||r<n)&&(n=r);-1===n&&(n=s.length),":"===s[n-1]&&n--;let i=s.slice(0,n);s=s.slice(n),this.parseHost(i),this.hostname=this.hostname||"";let o="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!o){let e=this.hostname.split(/\./);for(let t=0,n=e.length;t<n;t++){let n=e[t];if(!!n){if(!n.match(rf)){let r="";for(let e=0,t=n.length;e<t;e++)n.charCodeAt(e)>127?r+="x":r+=n[e];if(!r.match(rf)){let r=e.slice(0,t),i=e.slice(t+1),o=n.match(rd);o&&(r.push(o[1]),i.unshift(o[2])),i.length&&(s=i.join(".")+s),this.hostname=r.join(".");break}}}}}this.hostname.length>255&&(this.hostname=""),o&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}let l=s.indexOf("#");-1!==l&&(this.hash=s.substr(l),s=s.slice(0,l));let a=s.indexOf("?");return -1!==a&&(this.search=s.substr(a),s=s.slice(0,a)),s&&(this.pathname=s),rm[n]&&this.hostname&&!this.pathname&&(this.pathname=""),this},ro.prototype.parseHost=function(e){let t=ra.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)};let rg=function(e,t){if(e&&e instanceof ro)return e;let n=new ro;return n.parse(e,t),n},ry=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/,rb=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/,rv=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,rk=/[\0-\x1F\x7F-\x9F]/,rw=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,rD=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,rA=new Uint16Array('ᵁ<\xd5ıʊҝջאٵ۞ޢߖࠏઑඡ༉༦ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms\x7f\x84\x8b\x90\x95\x98\xa6\xb3\xb9\xc8\xcflig耻\xc6䃆P耻&䀦cute耻\xc1䃁reve;䄂Āiyx}rc耻\xc2䃂;䐐r;쀀\ud835\udd04rave耻\xc0䃀pha;䎑acr;䄀d;橓Āgp\x9d\xa1on;䄄f;쀀\ud835\udd38plyFunction;恡ing耻\xc5䃅Ācs\xbe\xc3r;쀀\ud835\udc9cign;扔ilde耻\xc3䃃ml耻\xc4䃄Ѐaceforsu\xe5\xfb\xfeėĜĢħĪĀcr\xea\xf2kslash;或Ŷ\xf6\xf8;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀\ud835\udd05pf;쀀\ud835\udd39eve;䋘c\xf2ēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻\xa9䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻\xc7䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷\xf2ſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀\ud835\udc9epĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀\ud835\udd07Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀\ud835\udd3bƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲϏϢϸontourIntegra\xecȹoɴ\0\0ͻ\xbb͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔e\xe5ˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀\ud835\udc9frok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻\xd0䃐cute耻\xc9䃉ƀaiyӒӗӜron;䄚rc耻\xca䃊;䐭ot;䄖r;쀀\ud835\udd08rave耻\xc8䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀\ud835\udd3csilon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՚r;愰m;橳a;䎗ml耻\xcb䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲy;䐤r;쀀\ud835\udd09lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀\ud835\udd3dAll;戀riertrf;愱c\xf2JTabcdfgorstרׯؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀\ud835\udd0a;拙pf;쀀\ud835\udd3eeater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀\ud835\udca2;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅ\xf2کrok;䄦mpńېۘownHum\xf0įqual;扏܀EJOacdfgmnostuۺ۾܃܇ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻\xcd䃍Āiyܓܘrc耻\xce䃎;䐘ot;䄰r;愑rave耻\xcc䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lie\xf3ϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀\ud835\udd40a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻\xcf䃏ʀcfosuެ߂ߐĀiyޱrc;䄴;䐙r;쀀\ud835\udd0dpf;쀀\ud835\udd41ǣ߇\0ߌr;쀀\ud835\udca5rcy;䐈kcy;䐄HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶dil;䄶;䐚r;쀀\ud835\udd0epf;쀀\ud835\udd42cr;쀀\ud835\udca6րJTaceflmostࠥࠩࠬࡐࡣসে্ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४ĀnrࢃgleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ight\xe1Μs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀\ud835\udd0fĀ;eঽা拘ftarrow;懚idot;䄿ƀnpwਖਛgȀLRlr৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊight\xe1οight\xe1ϊf;쀀\ud835\udd43erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂ\xf2ࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼અઋp;椅y;䐜Ādl੯iumSpace;恟lintrf;愳r;쀀\ud835\udd10nusPlus;戓pf;쀀\ud835\udd44c\xf2੶;䎜ҀJacefostuણધભીଔଙඑඞcy;䐊cute;䅃ƀaeyહાron;䅇dil;䅅;䐝ƀgswે૰ativeƀMTV૨ediumSpace;怋hiĀcn૦\xeberyThi\xeetedĀGLଆreaterGreate\xf2ٳessLes\xf3ੈLine;䀊r;쀀\ud835\udd11ȀBnptଢନଷreak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater;EFGLSTஶஷ扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨setĀ;Eೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀\ud835\udca9ilde耻\xd1䃑;䎝܀Eacdfgmoprstuvලෂෛ෧ขภยา฿ไlig;䅒cute耻\xd3䃓Āiyීrc耻\xd4䃔;䐞blac;䅐r;쀀\ud835\udd12rave耻\xd2䃒ƀaei෮ෲcr;䅌ga;䎩cron;䎟pf;쀀\ud835\udd46enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀\ud835\udcaaash耻\xd8䃘iŬืde耻\xd5䃕es;樷ml耻\xd6䃖erĀBP๋Āar๐๓r;怾acĀek๚;揞et;掴arenthesis;揜ҀacfhilorsງຊຏຒດຝະrtialD;戂y;䐟r;쀀\ud835\udd13i;䎦;䎠usMinus;䂱Āipຢອncareplan\xe5ڝf;愙Ȁ;eio຺ູ檻cedesȀ;EST່້扺qual;檯lantEqual;扼ilde;找me;怳Ādpuct;戏ortionĀ;aȥl;戝Āci༁༆r;쀀\ud835\udcab;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀\ud835\udd14pf;愚cr;쀀\ud835\udcacBEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻\xae䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r\xbbཹo;䎡ghtЀACDFTUVa࿁ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL憒ar;懥eftArrow;懄eiling;按oǵ\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀\ud835\udd16ortȀDLRUᄪᄴᄾᅉownArrow\xbbОeftArrow\xbb࢚ightArrow\xbbpArrow;憑gma;䎣allCircle;战pf;쀀\ud835\udd4aɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀\ud835\udcaear;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Th\xe1ྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et\xbbሓրHRSacfhiorsሾቄቕቱቶኟዂወዑORN耻\xde䃞ADE;愢ĀHcቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀\ud835\udd17ĀeiቻDzኀ\0ኇefore;戴a;䎘ĀcnኘkSpace;쀀 Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀\ud835\udd4bipleDot;惛Āctዖዛr;쀀\ud835\udcafrok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0ᐄᐊᐐĀcrዻጁute耻\xda䃚rĀ;oጇገ憟cir;楉rǣጓ\0y;䐎ve;䅬Āiyጞጣrc耻\xdb䃛;䐣blac;䅰r;쀀\ud835\udd18rave耻\xd9䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻on;䅲f;쀀\ud835\udd4cЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥own\xe1ϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀\ud835\udcb0ilde;䅨ml耻\xdc䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀\ud835\udd19pf;쀀\ud835\udd4dcr;쀀\ud835\udcb1dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀\ud835\udd1apf;쀀\ud835\udd4ecr;쀀\ud835\udcb2Ȁfiosᓋᓐᓒᓘr;쀀\ud835\udd1b;䎞pf;쀀\ud835\udd4fcr;쀀\ud835\udcb3ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻\xdd䃝Āiyᔉᔍrc;䅶;䐫r;쀀\ud835\udd1cpf;쀀\ud835\udd50cr;쀀\ud835\udcb4ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidt\xe8a;䎖r;愨pf;愤cr;쀀\ud835\udcb5ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻\xe1䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻\xe2䃢te肻\xb4̆;䐰lig耻\xe6䃦Ā;r\xb2ᖺ;쀀\ud835\udd1erave耻\xe0䃠ĀepᗊᗖĀfpᗏᗔsym;愵\xe8ᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e\xbbᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢\xbb\xb9arr;捼Āgpᙣᙧon;䄅f;쀀\ud835\udd52;Eaeiopᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;eᚒ\xf1ᚃing耻\xe5䃥ƀctyᚡᚦᚨr;쀀\ud835\udcb6;䀪mpĀ;eᚯ\xf1ʈilde耻\xe3䃣ml耻\xe4䃤Āciᛂᛈonin\xf4ɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰᝃᝈ០៦ᠹᡐᜍ᥈ᥰot;櫭ĀcrᛶkȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e\xbbᜭrkĀ;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰s\xe9ᜌno\xf5ēƀahwᝯᝳ;䎲;愶een;扬r;쀀\ud835\udd1fgcostuvwឍឝឳេ៕៛ƀaiuបពរ\xf0ݠrc;旯p\xbb፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄e\xe5ᑄ\xe5ᒭarow;植ƀakoᠦᠵĀcn៲ᠣkƀlst֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀\ud835\udd53Ā;tᏋᡣom\xbbᏌtie;拈DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ;敛;敘;攘;攔;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģbar耻\xa6䂦Ȁceioᥑᥖᥚᥠr;쀀\ud835\udcb7mi;恏mĀ;elƀ;bhᥨᥩᥫ䁜;槅sub;柈ŬᥴlĀ;e怢t\xbbpƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭒\0᯽\0ᰌƀcprᦲute;䄇̀;abcdsᦿᧀᧄ᧕᧙戩nd;橄rcup;橉Āau᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁\xeeړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻\xe7䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻\xb8ƭptyv;榲t脀\xa2;eᨭᨮ䂢r\xe4Ʋr;쀀\ud835\udd20ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark\xbbᩈ;䏇r;Ecefms᩠ᩢᩫ᪤᪪旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖\xbbཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it\xbb᪼ˬ᫇\0ᬊonĀ;eᫍᫎ䀺Ā;q\xc7\xc6ɭ\0\0aĀ;t䀬;䁀ƀ;fl戁\xeeᅠeĀmxent\xbbe\xf3ɍǧ\0ᬇĀ;dኻᬂot;橭n\xf4Ɇƀfryᬐᬔᬗ;쀀\ud835\udd54o\xe4ɔ脀\xa9;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀\ud835\udcb8Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯delprvw᭠᭬᭷ᮂᮬᯔarrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;pᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒre\xe3᭳u\xe3᭵ee;拎edge;拏en耻\xa4䂤earrowĀlrᯮ᯳eft\xbbᮀight\xbbᮽe\xe4ᯝĀciᰁᰇonin\xf4Ƿnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰻᰿ᱝᱩᱵᲞᲬᲷᴍᵻᶑᶫᶻ᷆᷍r\xf2ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸\xf2ᄳhĀ;vᱚᱛ怐\xbbऊūᱡᱧarow;椏a\xe3̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻\xb0䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀\ud835\udd21arĀlrᲳᲵ\xbbࣜ\xbbသʀaegsv᳂᳖᳜᳠mƀ;oș᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀\xf7;o᳧ᳰntimes;拇n\xf8᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀\ud835\udd55ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedg\xe5\xfanƀadhᄮᵝᵧownarrow\xf3ᲃarpoonĀlrᵲᵶef\xf4Ჴigh\xf4ᲶŢᵿᶅkaro\xf7གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀\ud835\udcb9;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃r\xf2Щa\xf2ྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄĀDoḆᴴo\xf4ĀcsḎḔute耻\xe9䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻\xea䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀\ud835\udd22ƀ;rsṐṑṗ檚ave耻\xe8䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et\xbbẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀\ud835\udd56ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on\xbbớ;䏵ȀcsuvỪỳἋἣĀioữḱrc\xbbḮɩỹ\0\0ỻ\xedՈantĀglἂἆtr\xbbṝess\xbbṺƀaeiἒἚls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯o\xf4͒ĀahὉὋ;䎷耻\xf0䃰Āmrὓὗl耻\xeb䃫o;悬ƀcipὡὤὧl;䀡s\xf4ծĀeoὬὴctatio\xeeՙnential\xe5չৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotse\xf1Ṅy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀\ud835\udd23lig;耀filig;쀀fjƀaltῙῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀\ud835\udd57ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧\0耻\xbd䂽;慓耻\xbc䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻\xbe䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀\ud835\udcbbࢀEabcdefgijlnorstv₂₉₥₰₴⃰℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽ƀ;qsؾٌlan\xf4٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀\ud835\udd24Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox\xbbℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀\ud835\udd58Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqrⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0pro\xf8r;楸qĀlqؿ↖les\xf3₈i\xed٫Āen↣↭rtneqq;쀀≩︀\xc5↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽r\xf2ΠȀilmr⇐⇔⇗⇛rs\xf0ᒄf\xbb․il\xf4کĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it\xbb∊lip;怦con;抹r;쀀\ud835\udd25sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀\ud835\udd59bar;怕ƀclt≯≴≸r;쀀\ud835\udcbdas\xe8⇴rok;䄧Ābp⊂⊇ull;恃hen\xbbᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻\xed䃭ƀ;iyݱ⊰⊵rc耻\xee䃮;䐸Ācx⊼⊿y;䐵cl耻\xa1䂡ĀfrΟ⋉;쀀\ud835\udd26rave耻\xec䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓in\xe5ގar\xf4ܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝do\xf4⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙er\xf3ᕣ\xe3⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀\ud835\udd5aa;䎹uest耻\xbf䂿Āci⎊⎏r;쀀\ud835\udcbenʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻\xef䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀\ud835\udd27ath;䈷pf;쀀\ud835\udd5bǣ⏬\0⏱r;쀀\ud835\udcbfrcy;䑘kcy;䑔Ѐacfghjos␋␖␢ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀\ud835\udd28reen;䄸cy;䑅cy;䑜pf;쀀\ud835\udd5ccr;쀀\ud835\udcc0ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼r\xf2\xf2Εail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴ra\xeeࡌbda;䎻gƀ;dlࢎⓁⓃ;榑\xe5ࢎ;檅uo耻\xab䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝\xeb≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼\xecࢰ\xe2┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□a\xe9⓶arpoonĀdu▯▴own\xbbњp\xbb०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoon\xf3quigarro\xf7⇰hreetimes;拋ƀ;qs▋ও◺lan\xf4বʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋ppro\xf8Ⓠot;拖qĀgq♃♅\xf4উgt\xf2⒌\xf4ছi\xedলƀilr♕࣡♚sht;楼;쀀\ud835\udd29Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖r\xf2◁orne\xf2ᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che\xbb⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox\xbb⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽r\xebࣁgƀlmr⛿✍✔eftĀar০✇ight\xe1৲apsto;柼ight\xe1৽parrowĀlr✥✩ef\xf4⓭ight;憬ƀafl✶✹✽r;榅;쀀\ud835\udd5dus;樭imes;樴š❋❏st;戗\xe1ፎƀ;ef❗❘᠀旊nge\xbb❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇r\xf2ࢨorne\xf2ᶌarĀ;d➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀\ud835\udcc1mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹re\xe5◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀\xc5⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻\xaf䂯Āet⡗⡙;時Ā;e⡞⡟朠se\xbb⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻ow\xeeҌef\xf4ए\xf0Ꮡker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle\xbbᘦr;쀀\ud835\udd2ao;愧ƀcdn⢯⢴⣉ro耻\xb5䂵Ȁ;acdᑤ⢽⣀⣄s\xf4ᚧir;櫰ot肻\xb7Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛\xf2−\xf0ઁĀdp⣩⣮els;抧f;쀀\ud835\udd5eĀct⣸⣽r;쀀\ud835\udcc2pos\xbbᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la\xbb˞ute;䅄g;쀀∠⃒ʀ;Eiop⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉ro\xf8urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻\xa0ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸ui\xf6ୣĀei⩊⩎ar;椨\xedistĀ;sடr;쀀\ud835\udd2bȀEest⩦⩹⩼ƀ;qs⩭ƀ;qs⩴lan\xf4i\xed௪Ā;rஶ⪁\xbbஷƀAap⪊⪍⪑r\xf2⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚AEadest⪷⪺⪾⫂⫅⫶⫹r\xf2⥦;쀀≦̸rr;憚r;急Ȁ;fqs⫎⫣⫯tĀar⫔⫙rro\xf7⫁ightarro\xf7⪐ƀ;qs⪺⫪lan\xf4ౕĀ;sౕ⫴\xbbశi\xedౝĀ;rవ⫾iĀ;eచథi\xe4ඐĀpt⬌⬑f;쀀\ud835\udd5f膀\xac;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast⭕⭚⭟lle\xecl;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳u\xe5ಥĀ;cಘ⭸Ā;eಒ⭽\xf1ಘȀAait⮈⮋⮝⮧r\xf2⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow\xbb⮕riĀ;eೋೖchimpqu⮽⯍⯙⬄⯤⯯Ȁ;cerല⯆ഷ⯉u\xe5;쀀\ud835\udcc3ortɭ⬅\0\0⯖ar\xe1⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭\xe5\xe5ഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗ\xf1സȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇ\xecௗlde耻\xf1䃱\xe7ృiangleĀlrⱒⱜeftĀ;eచⱚ\xf1దightĀ;eೋⱥ\xf1Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻\xf3䃳ĀiyⴼⵅrĀ;cⵂ耻\xf4䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācrir;榿;쀀\ud835\udd2cͯ\0\0\0ⶂn;䋛ave耻\xf2䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕⶥⶨr\xf2᪀Āirⶠr;榾oss;榻n\xe5๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀\ud835\udd60ƀaelⷔǒr;榷rp;榹;adiosvⷪⷫⷮ⸈⸍⸐⸖戨r\xf2᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f\xbbⷿ耻\xaa䂪耻\xba䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧\xf2⸁ash耻\xf8䃸l;折iŬⸯ⸴de耻\xf5䃵esĀ;aǛ⸺s;樶ml耻\xf6䃶bar;挽ૡ\0\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ脀\xb6;l䂶le\xecЃɩ\0\0m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀\ud835\udd2dƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕ma\xf4੶ne;明ƀ;tv⺿⻀⻈䏀chfork\xbb´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎\xf6⇴sҀ;abcdemst⻳ᤈ⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻\xb1ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀\ud835\udd61nd耻\xa3䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷u\xe5໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾ppro\xf8⽃urlye\xf1໙\xf1໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨i\xedໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺\xf0⽵ƀdfp⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t⾴\xefrel;抰Āci⿀⿅r;쀀\ud835\udcc5;䏈ncsp;怈̀fiopsu⋢⿱r;쀀\ud835\udd2epf;쀀\ud835\udd62rime;恗cr;쀀\ud835\udcc6ƀaeo⿸〉〓tĀei々rnion\xf3ڰnt;樖stĀ;e【】䀿\xf1Ἑ\xf4༔ABHabcdefhilmnoprstuxけさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがr\xf2Ⴓ\xf2ϝail;検ar\xf2ᱥar;楤cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕i\xe3ᅮmptyv;榳gȀ;del࿑らるろ;榒;榥\xe5࿑uo耻\xbb䂻rր;abcfhlpstwガクシスゼゾダッデナp;極Ā;fゴs;椠;椳s;椞\xeb≝\xf0✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶al\xf3༞ƀabrョリヮr\xf2៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗\xec\xe2ヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜn\xe5Ⴛar\xf4ྩt;断ƀilrㅩဣㅮsht;楽;쀀\ud835\udd2fĀaoㅷㆆrĀduㅽㅿ\xbbѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘rrowĀ;tㆭa\xe9トarpoonĀduㆻㆿow\xeeㅾp\xbb႒eftĀah㇊㇐rrow\xf3arpoon\xf3Ցightarrows;應quigarro\xf7ニhreetimes;拌g;䋚ingdotse\xf1ἲƀahm㈍㈐㈓r\xf2a\xf2Ց;怏oustĀ;a㈞掱che\xbbmid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾r\xebဃƀafl㉇㉊㉎r;榆;쀀\ud835\udd63us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒ar\xf2㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀\ud835\udcc7Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠re\xe5ㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛qu\xef➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡u\xe5ᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓i\xedሄ;䑁otƀ;be㌴ᵇ㌵担;橦Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒\xeb∨Ā;oਸ਼t耻\xa7䂧i;䀻war;椩mĀin㍩\xf0nu\xf3\xf1t;朶rĀ;o㍶⁕쀀\ud835\udd30Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜i\xe4ᑤara\xec耻\xad䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;qኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲ar\xf2ᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetm\xe9㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀\ud835\udd64aĀdr㑍ЂesĀ;u㑔㑕晠it\xbb㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍\xf1ᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝\xf1ᆮƀ;afᅻ㒦ְrť㒫ֱ\xbbᅼar\xf2ᅈȀcemt㒹㒾㓂㓅r;쀀\ud835\udcc8tm\xee\xf1i\xec㐕ar\xe6ᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psilo\xeeỠh\xe9⺯s\xbb⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦ppro\xf8㋺urlye\xf1ᇾ\xf1ᇳƀaes㖂㖈㌛ppro\xf8㌚q\xf1㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻\xb9䂹耻\xb2䂲耻\xb3䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨\xeb∮Ā;oਫwar;椪lig耻\xdf䃟㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄r\xebƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀\ud835\udd31Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮ppro\xf8im\xbbኬs\xf0ኞĀas㚺㚮\xf0rn耻\xfe䃾Ǭ̟㛆⋧es膀\xd7;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀\xe1⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀\ud835\udd65rk;櫚\xe1㍢rime;怴ƀaip㜏㜒㝤d\xe5ቈadempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own\xbbᶻeftĀ;e⠀㜾\xf1म;扜ightĀ;e㊪㝋\xf1ၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀\ud835\udcc9;䑆cy;䑛rok;䅧Āio㞋㞎x\xf4headĀlr㞗㞠eftarro\xf7ࡏightarrow\xbbཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶r\xf2ϭar;楣Ācr㟜㟢ute耻\xfa䃺\xf2ᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻\xfb䃻;䑃ƀabh㠃㠆㠋r\xf2Ꭽlac;䅱a\xf2ᏃĀir㠓㠘sht;楾;쀀\ud835\udd32rave耻\xf9䃹š㠧㠱rĀlr㠬㠮\xbbॗ\xbbႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r\xbb㡆op;挏ri;旸Āal㡖㡚cr;䅫肻\xa8͉Āgp㡢㡦on;䅳f;쀀\ud835\udd66̀adhlsuᅋ㡸㡽፲㢑㢠own\xe1ᎳarpoonĀlr㢈㢌ef\xf4㠭igh\xf4㠯iƀ;hl㢙㢚㢜䏅\xbbᏺon\xbb㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r\xbb㢽op;挎ng;䅯ri;旹cr;쀀\ud835\udccaƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨\xbb᠓Āam㣯㣲r\xf2㢨l耻\xfc䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠r\xf2ϷarĀ;v㤦㤧櫨;櫩as\xe8ϡĀnr㤲㤷grt;榜eknprst㓣㥆㥋㥒㥝㥤㦖app\xe1␕othin\xe7ẖƀhir㓫⻈㥙op\xf4⾵Ā;hᎷ㥢\xefㆍĀiu㥩㥭gm\xe1㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟et\xe1㚜iangleĀlr㦪㦯eft\xbbथight\xbbၑy;䐲ash\xbbံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨa\xf2ᑩr;쀀\ud835\udd33tr\xe9㦮suĀbp㧯㧱\xbbജ\xbb൙pf;쀀\ud835\udd67ro\xf0tr\xe9㦴Ācu㨆㨋r;쀀\ud835\udccbĀbp㨐㨘nĀEe㦀㨖\xbb㥾nĀEe㦒㨞\xbb㦐igzag;榚cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀\ud835\udd34pf;쀀\ud835\udd68Ā;eᑹ㩦at\xe8ᑹcr;쀀\ud835\udcccૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜtr\xe9៑r;쀀\ud835\udd35ĀAa㪔㪗r\xf2σr\xf2৶;䎾ĀAa㪡㪤r\xf2θr\xf2৫a\xf0✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀\ud835\udd69im\xe5ឲĀAa㫇㫊r\xf2ώr\xf2ਁĀcq㫒ីr;쀀\ud835\udccdĀpt៖㫜r\xe9។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻\xfd䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻\xa5䂥r;쀀\ud835\udd36cy;䑗pf;쀀\ud835\udd6acr;쀀\ud835\udcceĀcm㬦㬩y;䑎l耻\xff䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡tr\xe6ᕟa;䎶r;쀀\ud835\udd37cy;䐶grarr;懝pf;쀀\ud835\udd6bcr;쀀\ud835\udccfĀjn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),rx=new Uint16Array("Ȁaglq \x15\x18\x1bɭ\x0f\0\0\x12p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0))),rC=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]),rE=null!==(C=String.fromCodePoint)&&void 0!==C?C:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e)};(d=E||(E={}))[d.NUM=35]="NUM",d[d.SEMI=59]="SEMI",d[d.EQUALS=61]="EQUALS",d[d.ZERO=48]="ZERO",d[d.NINE=57]="NINE",d[d.LOWER_A=97]="LOWER_A",d[d.LOWER_F=102]="LOWER_F",d[d.LOWER_X=120]="LOWER_X",d[d.LOWER_Z=122]="LOWER_Z",d[d.UPPER_A=65]="UPPER_A",d[d.UPPER_F=70]="UPPER_F",d[d.UPPER_Z=90]="UPPER_Z";function rS(e){return e>=E.ZERO&&e<=E.NINE}(p=S||(S={}))[p.VALUE_LENGTH=49152]="VALUE_LENGTH",p[p.BRANCH_LENGTH=16256]="BRANCH_LENGTH",p[p.JUMP_TABLE=127]="JUMP_TABLE";(m=_||(_={}))[m.EntityStart=0]="EntityStart",m[m.NumericStart=1]="NumericStart",m[m.NumericDecimal=2]="NumericDecimal",m[m.NumericHex=3]="NumericHex",m[m.NamedEntity=4]="NamedEntity",(g=O||(O={}))[g.Legacy=0]="Legacy",g[g.Strict=1]="Strict",g[g.Attribute=2]="Attribute";class r_{constructor(e,t,n){this.decodeTree=e,this.emitCodePoint=t,this.errors=n,this.state=_.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=O.Strict}startEntity(e){this.decodeMode=e,this.state=_.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(e,t){switch(this.state){case _.EntityStart:if(e.charCodeAt(t)===E.NUM)return this.state=_.NumericStart,this.consumed+=1,this.stateNumericStart(e,t+1);return this.state=_.NamedEntity,this.stateNamedEntity(e,t);case _.NumericStart:return this.stateNumericStart(e,t);case _.NumericDecimal:return this.stateNumericDecimal(e,t);case _.NumericHex:return this.stateNumericHex(e,t);case _.NamedEntity:return this.stateNamedEntity(e,t)}}stateNumericStart(e,t){return t>=e.length?-1:(32|e.charCodeAt(t))===E.LOWER_X?(this.state=_.NumericHex,this.consumed+=1,this.stateNumericHex(e,t+1)):(this.state=_.NumericDecimal,this.stateNumericDecimal(e,t))}addToNumericResult(e,t,n,r){if(t!==n){let i=n-t;this.result=this.result*Math.pow(r,i)+parseInt(e.substr(t,i),r),this.consumed+=i}}stateNumericHex(e,t){let n=t;for(;t<e.length;){var r;let i=e.charCodeAt(t);if(!rS(i)&&(!((r=i)>=E.UPPER_A)||!(r<=E.UPPER_F))&&(!(r>=E.LOWER_A)||!(r<=E.LOWER_F)))return this.addToNumericResult(e,n,t,16),this.emitNumericEntity(i,3);t+=1}return this.addToNumericResult(e,n,t,16),-1}stateNumericDecimal(e,t){let n=t;for(;t<e.length;){let r=e.charCodeAt(t);if(!rS(r))return this.addToNumericResult(e,n,t,10),this.emitNumericEntity(r,2);t+=1}return this.addToNumericResult(e,n,t,10),-1}emitNumericEntity(e,t){var n,r,i;if(this.consumed<=t)return null===(n=this.errors)||void 0===n||n.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(e===E.SEMI)this.consumed+=1;else if(this.decodeMode===O.Strict)return 0;return this.emitCodePoint((r=this.result)>=55296&&r<=57343||r>1114111?65533:null!==(i=rC.get(r))&&void 0!==i?i:r,this.consumed),this.errors&&(e!==E.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(e,t){let{decodeTree:n}=this,r=n[this.treeIndex],i=(r&S.VALUE_LENGTH)>>14;for(;t<e.length;t++,this.excess++){let s=e.charCodeAt(t);if(this.treeIndex=function(e,t,n,r){let i=(t&S.BRANCH_LENGTH)>>7,s=t&S.JUMP_TABLE;if(0===i)return 0!==s&&r===s?n:-1;if(s){let t=r-s;return t<0||t>=i?-1:e[n+t]-1}let o=n,l=o+i-1;for(;o<=l;){let t=o+l>>>1,n=e[t];if(n<r)o=t+1;else{if(!(n>r))return e[t+i];l=t-1}}return -1}(n,r,this.treeIndex+Math.max(1,i),s),this.treeIndex<0)return 0===this.result||this.decodeMode===O.Attribute&&(0===i||function(e){var t;return e===E.EQUALS||(t=e)>=E.UPPER_A&&t<=E.UPPER_Z||t>=E.LOWER_A&&t<=E.LOWER_Z||rS(t)}(s))?0:this.emitNotTerminatedNamedEntity();if(0!=(i=((r=n[this.treeIndex])&S.VALUE_LENGTH)>>14)){if(s===E.SEMI)return this.emitNamedEntityData(this.treeIndex,i,this.consumed+this.excess);this.decodeMode!==O.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return -1}emitNotTerminatedNamedEntity(){var e;let{result:t,decodeTree:n}=this,r=(n[t]&S.VALUE_LENGTH)>>14;return this.emitNamedEntityData(t,r,this.consumed),null===(e=this.errors)||void 0===e||e.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(e,t,n){let{decodeTree:r}=this;return this.emitCodePoint(1===t?r[e]&~S.VALUE_LENGTH:r[e+1],n),3===t&&this.emitCodePoint(r[e+2],n),n}end(){var e;switch(this.state){case _.NamedEntity:return 0!==this.result&&(this.decodeMode!==O.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case _.NumericDecimal:return this.emitNumericEntity(0,2);case _.NumericHex:return this.emitNumericEntity(0,3);case _.NumericStart:return null===(e=this.errors)||void 0===e||e.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case _.EntityStart:return 0}}}function rO(e){let t="",n=new r_(e,e=>t+=rE(e));return function(e,r){let i=0,s=0;for(;(s=e.indexOf("&",s))>=0;){t+=e.slice(i,s),n.startEntity(r);let o=n.write(e,s+1);if(o<0){i=s+n.end();break}i=s+o,s=0===o?i+1:i}let o=t+e.slice(i);return t="",o}}let rF=rO(rA);function rP(e,t=O.Legacy){return rF(e,t)}rO(rx);let rT=new Map([[34,"""],[38,"&"],[39,"'"],[60,"<"],[62,">"]]);function rN(e,t){return function(n){let r;let i=0,s="";for(;r=e.exec(n);)i!==r.index&&(s+=n.substring(i,r.index)),s+=t.get(r[0].charCodeAt(0)),i=r.index+1;return s+n.substring(i)}}null!=String.prototype.codePointAt||((e,t)=>(64512&e.charCodeAt(t))==55296?(e.charCodeAt(t)-55296)*1024+e.charCodeAt(t+1)-56320+65536:e.charCodeAt(t)),rN(/[&<>'"]/g,rT),rN(/["&\u00A0]/g,new Map([[34,"""],[38,"&"],[160," "]])),rN(/[&<>\u00A0]/g,new Map([[38,"&"],[60,"<"],[62,">"],[160," "]])),(y=F||(F={}))[y.XML=0]="XML",y[y.HTML=1]="HTML",(b=P||(P={}))[b.UTF8=0]="UTF8",b[b.ASCII=1]="ASCII",b[b.Extensive=2]="Extensive",b[b.Attribute=3]="Attribute",b[b.Text=4]="Text";function rB(e){var t;return"[object String]"===(t=e,Object.prototype.toString.call(t))}let rI=Object.prototype.hasOwnProperty;function rM(e,t){return rI.call(e,t)}function r$(e){let t=Array.prototype.slice.call(arguments,1);return t.forEach(function(t){if(!!t){if("object"!=typeof t)throw TypeError(t+"must be object");Object.keys(t).forEach(function(n){e[n]=t[n]})}}),e}function rL(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))}function rR(e){return(!(e>=55296)||!(e<=57343))&&(!(e>=64976)||!(e<=65007))&&(65535&e)!=65535&&(65535&e)!=65534&&(!(e>=0)||!(e<=8))&&11!==e&&(!(e>=14)||!(e<=31))&&(!(e>=127)||!(e<=159))&&!(e>1114111)&&!0}function rj(e){return e>65535?String.fromCharCode(55296+((e-=65536)>>10),56320+(1023&e)):String.fromCharCode(e)}let rq=/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,rV=RegExp(rq.source+"|"+/&([a-z#][a-z0-9]{1,31});/gi.source,"gi"),rz=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;function rU(e){return 0>e.indexOf("\\")?e:e.replace(rq,"$1")}function rH(e){return 0>e.indexOf("\\")&&0>e.indexOf("&")?e:e.replace(rV,function(e,t,n){return t?t:function(e,t){if(35===t.charCodeAt(0)&&rz.test(t)){let n="x"===t[1].toLowerCase()?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return rR(n)?rj(n):e}let n=rP(e);return n!==e?n:e}(e,n)})}let rW=/[&<>"]/,rG=/[&<>"]/g,rK={"&":"&","<":"<",">":">",'"':"""};function rJ(e){return rK[e]}function rQ(e){return rW.test(e)?e.replace(rG,rJ):e}let rY=/[.?*+^$[\]\\(){}|-]/g;function rZ(e){return e.replace(rY,"\\$&")}function rX(e){switch(e){case 9:case 32:return!0}return!1}function r0(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function r1(e){return ry.test(e)||rb.test(e)}function r2(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function r3(e){return e=e.trim().replace(/\s+/g," "),e.toLowerCase().toUpperCase()}let r5={mdurl:T,ucmicro:N};function r8(e,t,n){let r,i,s,o;let l=e.posMax,a=e.pos;for(e.pos=t+1,r=1;e.pos<l;){if(93===(s=e.src.charCodeAt(e.pos))&&0==--r){i=!0;break}if(o=e.pos,e.md.inline.skipToken(e),91===s){if(o===e.pos-1)r++;else if(n)return e.pos=a,-1}}let u=-1;return i&&(u=e.pos),e.pos=a,u}function r4(e,t,n){let r;let i=t,s={ok:!1,pos:0,str:""};if(60===e.charCodeAt(i)){for(i++;i<n&&10!==(r=e.charCodeAt(i))&&60!==r;){;if(62===r){s.pos=i+1,s.str=rH(e.slice(t+1,i)),s.ok=!0;break}if(92===r&&i+1<n){i+=2;continue}i++}return s}let o=0;for(;i<n&&32!==(r=e.charCodeAt(i))&&!(r<32)&&127!==r;){;if(92===r&&i+1<n){if(32===e.charCodeAt(i+1))break;i+=2;continue}if(40===r&&++o>32)return s;if(41===r){if(0===o)break;o--}i++}return t===i||0!==o?s:(s.str=rH(e.slice(t,i)),s.pos=i,s.ok=!0,s)}function r6(e,t,n,r){let i;let s=t,o={ok:!1,can_continue:!1,pos:0,str:"",marker:0};if(r)o.str=r.str,o.marker=r.marker;else{if(s>=n)return o;let r=e.charCodeAt(s);if(34!==r&&39!==r&&40!==r)return o;t++,s++,40===r&&(r=41),o.marker=r}for(;s<n;){if((i=e.charCodeAt(s))===o.marker)return o.pos=s+1,o.str+=rH(e.slice(t,s)),o.ok=!0,o;if(40===i&&41===o.marker)return o;else 92===i&&s+1<n&&s++;s++}return o.can_continue=!0,o.str+=rH(e.slice(t,s)),o}let r9={};function r7(){this.rules=r$({},r9)}r9.code_inline=function(e,t,n,r,i){let s=e[t];return"<code"+i.renderAttrs(s)+">"+rQ(s.content)+"</code>"},r9.code_block=function(e,t,n,r,i){let s=e[t];return"<pre"+i.renderAttrs(s)+"><code>"+rQ(e[t].content)+"</code></pre>\n"},r9.fence=function(e,t,n,r,i){let s;let o=e[t],l=o.info?rH(o.info).trim():"",a="",u="";if(l){let e=l.split(/(\s+)/g);a=e[0],u=e.slice(2).join("")}if(0===(s=n.highlight&&n.highlight(o.content,a,u)||rQ(o.content)).indexOf("<pre"))return s+"\n";if(l){let e=o.attrIndex("class"),t=o.attrs?o.attrs.slice():[];return e<0?t.push(["class",n.langPrefix+a]):(t[e]=t[e].slice(),t[e][1]+=" "+n.langPrefix+a),`<pre><code${i.renderAttrs({attrs:t})}>${s}</code></pre>
|
|
31
|
-
`}return`<pre><code${i.renderAttrs(o)}>${s}</code></pre>
|
|
32
|
-
`},r9.image=function(e,t,n,r,i){let s=e[t];return s.attrs[s.attrIndex("alt")][1]=i.renderInlineAsText(s.children,n,r),i.renderToken(e,t,n)},r9.hardbreak=function(e,t,n){return n.xhtmlOut?"<br />\n":"<br>\n"},r9.softbreak=function(e,t,n){return n.breaks?n.xhtmlOut?"<br />\n":"<br>\n":"\n"},r9.text=function(e,t){return rQ(e[t].content)},r9.html_block=function(e,t){return e[t].content},r9.html_inline=function(e,t){return e[t].content},r7.prototype.renderAttrs=function(e){let t,n,r;if(!e.attrs)return"";for(t=0,r="",n=e.attrs.length;t<n;t++)r+=" "+rQ(e.attrs[t][0])+'="'+rQ(e.attrs[t][1])+'"';return r},r7.prototype.renderToken=function(e,t,n){let r=e[t],i="";if(r.hidden)return"";r.block&&-1!==r.nesting&&t&&e[t-1].hidden&&(i+="\n"),i+=(-1===r.nesting?"</":"<")+r.tag,i+=this.renderAttrs(r),0===r.nesting&&n.xhtmlOut&&(i+=" /");let s=!1;if(r.block&&(s=!0,1===r.nesting&&t+1<e.length)){let n=e[t+1];"inline"===n.type||n.hidden?s=!1:-1===n.nesting&&n.tag===r.tag&&(s=!1)}return i+=s?">\n":">"},r7.prototype.renderInline=function(e,t,n){let r="",i=this.rules;for(let s=0,o=e.length;s<o;s++){let o=e[s].type;void 0!==i[o]?r+=i[o](e,s,t,n,this):r+=this.renderToken(e,s,t)}return r},r7.prototype.renderInlineAsText=function(e,t,n){let r="";for(let i=0,s=e.length;i<s;i++)switch(e[i].type){case"text":case"html_inline":case"html_block":r+=e[i].content;break;case"image":r+=this.renderInlineAsText(e[i].children,t,n);break;case"softbreak":case"hardbreak":r+="\n"}return r},r7.prototype.render=function(e,t,n){let r="",i=this.rules;for(let s=0,o=e.length;s<o;s++){let o=e[s].type;"inline"===o?r+=this.renderInline(e[s].children,t,n):void 0!==i[o]?r+=i[o](e,s,t,n,this):r+=this.renderToken(e,s,t,n)}return r};function ie(){this.__rules__=[],this.__cache__=null}ie.prototype.__find__=function(e){for(let t=0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t;return -1},ie.prototype.__compile__=function(){let e=this,t=[""];e.__rules__.forEach(function(e){if(!!e.enabled)e.alt.forEach(function(e){0>t.indexOf(e)&&t.push(e)})}),e.__cache__={},t.forEach(function(t){e.__cache__[t]=[],e.__rules__.forEach(function(n){if(!(!n.enabled||t&&0>n.alt.indexOf(t)))e.__cache__[t].push(n.fn)})})},ie.prototype.at=function(e,t,n){let r=this.__find__(e);if(-1===r)throw Error("Parser rule not found: "+e);this.__rules__[r].fn=t,this.__rules__[r].alt=(n||{}).alt||[],this.__cache__=null},ie.prototype.before=function(e,t,n,r){let i=this.__find__(e);if(-1===i)throw Error("Parser rule not found: "+e);this.__rules__.splice(i,0,{name:t,enabled:!0,fn:n,alt:(r||{}).alt||[]}),this.__cache__=null},ie.prototype.after=function(e,t,n,r){let i=this.__find__(e);if(-1===i)throw Error("Parser rule not found: "+e);this.__rules__.splice(i+1,0,{name:t,enabled:!0,fn:n,alt:(r||{}).alt||[]}),this.__cache__=null},ie.prototype.push=function(e,t,n){this.__rules__.push({name:e,enabled:!0,fn:t,alt:(n||{}).alt||[]}),this.__cache__=null},ie.prototype.enable=function(e,t){!Array.isArray(e)&&(e=[e]);let n=[];return e.forEach(function(e){let r=this.__find__(e);if(r<0){if(t)return;throw Error("Rules manager: invalid rule name "+e)}this.__rules__[r].enabled=!0,n.push(e)},this),this.__cache__=null,n},ie.prototype.enableOnly=function(e,t){!Array.isArray(e)&&(e=[e]),this.__rules__.forEach(function(e){e.enabled=!1}),this.enable(e,t)},ie.prototype.disable=function(e,t){!Array.isArray(e)&&(e=[e]);let n=[];return e.forEach(function(e){let r=this.__find__(e);if(r<0){if(t)return;throw Error("Rules manager: invalid rule name "+e)}this.__rules__[r].enabled=!1,n.push(e)},this),this.__cache__=null,n},ie.prototype.getRules=function(e){return null===this.__cache__&&this.__compile__(),this.__cache__[e]||[]};function it(e,t,n){this.type=e,this.tag=t,this.attrs=null,this.map=null,this.nesting=n,this.level=0,this.children=null,this.content="",this.markup="",this.info="",this.meta=null,this.block=!1,this.hidden=!1}it.prototype.attrIndex=function(e){if(!this.attrs)return -1;let t=this.attrs;for(let n=0,r=t.length;n<r;n++)if(t[n][0]===e)return n;return -1},it.prototype.attrPush=function(e){this.attrs?this.attrs.push(e):this.attrs=[e]},it.prototype.attrSet=function(e,t){let n=this.attrIndex(e),r=[e,t];n<0?this.attrPush(r):this.attrs[n]=r},it.prototype.attrGet=function(e){let t=this.attrIndex(e),n=null;return t>=0&&(n=this.attrs[t][1]),n},it.prototype.attrJoin=function(e,t){let n=this.attrIndex(e);n<0?this.attrPush([e,t]):this.attrs[n][1]=this.attrs[n][1]+" "+t};function ir(e,t,n){this.src=e,this.env=n,this.tokens=[],this.inlineMode=!1,this.md=t}ir.prototype.Token=it;let ii=/\r\n?|\n/g,is=/\0/g,io=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,il=/\((c|tm|r)\)/i,ia=/\((c|tm|r)\)/ig,iu={c:"\xa9",r:"\xae",tm:"™"};function ih(e,t){return iu[t.toLowerCase()]}let ic=/['"]/,id=/['"]/g;function ip(e,t,n){return e.slice(0,t)+n+e.slice(t+1)}let im=[["normalize",function(e){let t;t=(t=e.src.replace(ii,"\n")).replace(is,"�"),e.src=t}],["block",function(e){let t;e.inlineMode?((t=new e.Token("inline","",0)).content=e.src,t.map=[0,1],t.children=[],e.tokens.push(t)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}],["inline",function(e){let t=e.tokens;for(let n=0,r=t.length;n<r;n++){let r=t[n];"inline"===r.type&&e.md.inline.parse(r.content,e.md,e.env,r.children)}}],["linkify",function(e){let t=e.tokens;if(!!e.md.options.linkify)for(let i=0,s=t.length;i<s;i++){if("inline"!==t[i].type||!e.md.linkify.pretest(t[i].content))continue;let s=t[i].children,o=0;for(let l=s.length-1;l>=0;l--){let a=s[l];if("link_close"===a.type){for(l--;s[l].level!==a.level&&"link_open"!==s[l].type;)l--;continue}if("html_inline"===a.type){var n,r;if(n=a.content,/^<a[>\s]/i.test(n)&&o>0)o--;if(r=a.content,/^<\/a\s*>/i.test(r))o++}if(!(o>0)){if("text"===a.type&&e.md.linkify.test(a.content)){let n=a.content,r=e.md.linkify.match(n),o=[],u=a.level,h=0;r.length>0&&0===r[0].index&&l>0&&"text_special"===s[l-1].type&&(r=r.slice(1));for(let t=0;t<r.length;t++){let i=r[t].url,s=e.md.normalizeLink(i);if(!e.md.validateLink(s))continue;let l=r[t].text;l=r[t].schema?"mailto:"!==r[t].schema||/^mailto:/i.test(l)?e.md.normalizeLinkText(l):e.md.normalizeLinkText("mailto:"+l).replace(/^mailto:/,""):e.md.normalizeLinkText("http://"+l).replace(/^http:\/\//,"");let a=r[t].index;if(a>h){let t=new e.Token("text","",0);t.content=n.slice(h,a),t.level=u,o.push(t)}let c=new e.Token("link_open","a",1);c.attrs=[["href",s]],c.level=u++,c.markup="linkify",c.info="auto",o.push(c);let f=new e.Token("text","",0);f.content=l,f.level=u,o.push(f);let d=new e.Token("link_close","a",-1);d.level=--u,d.markup="linkify",d.info="auto",o.push(d),h=r[t].lastIndex}if(h<n.length){let t=new e.Token("text","",0);t.content=n.slice(h),t.level=u,o.push(t)}t[i].children=s=rL(s,l,o)}}}}}],["replacements",function(e){let t;if(!!e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--){if("inline"===e.tokens[t].type)il.test(e.tokens[t].content)&&!function(e){let t=0;for(let n=e.length-1;n>=0;n--){let r=e[n];"text"===r.type&&!t&&(r.content=r.content.replace(ia,ih)),"link_open"===r.type&&"auto"===r.info&&t--,"link_close"===r.type&&"auto"===r.info&&t++}}(e.tokens[t].children),io.test(e.tokens[t].content)&&!function(e){let t=0;for(let n=e.length-1;n>=0;n--){let r=e[n];"text"===r.type&&!t&&io.test(r.content)&&(r.content=r.content.replace(/\+-/g,"\xb1").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/mg,"$1—").replace(/(^|\s)--(?=\s|$)/mg,"$1–").replace(/(^|[^-\s])--(?=[^-\s]|$)/mg,"$1–")),"link_open"===r.type&&"auto"===r.info&&t--,"link_close"===r.type&&"auto"===r.info&&t++}}(e.tokens[t].children)}}],["smartquotes",function(e){if(!!e.md.options.typographer)for(let t=e.tokens.length-1;t>=0;t--){if("inline"===e.tokens[t].type&&!!ic.test(e.tokens[t].content))!function(e,t){let n;let r=[];for(let i=0;i<e.length;i++){let s=e[i],o=e[i].level;for(n=r.length-1;n>=0&&!(r[n].level<=o);n--);if(r.length=n+1,"text"!==s.type)continue;let l=s.content,a=0,u=l.length;i:for(;a<u;){id.lastIndex=a;let h=id.exec(l);if(!h)break;let c=!0,f=!0;a=h.index+1;let d="'"===h[0],p=32;if(h.index-1>=0)p=l.charCodeAt(h.index-1);else for(n=i-1;n>=0&&"softbreak"!==e[n].type&&"hardbreak"!==e[n].type;n--)if(e[n].content){p=e[n].content.charCodeAt(e[n].content.length-1);break}let m=32;if(a<u)m=l.charCodeAt(a);else for(n=i+1;n<e.length&&"softbreak"!==e[n].type&&"hardbreak"!==e[n].type;n++)if(e[n].content){m=e[n].content.charCodeAt(0);break}let g=r2(p)||r1(String.fromCharCode(p)),y=r2(m)||r1(String.fromCharCode(m)),b=r0(p),v=r0(m);if(v?c=!1:y&&!(b||g)&&(c=!1),b?f=!1:g&&!(v||y)&&(f=!1),34===m&&'"'===h[0]&&p>=48&&p<=57&&(f=c=!1),c&&f&&(c=g,f=y),!c&&!f){d&&(s.content=ip(s.content,h.index,"’"));continue}if(f)for(n=r.length-1;n>=0;n--){let c=r[n];if(r[n].level<o)break;if(c.single===d&&r[n].level===o){let o,f;c=r[n],d?(o=t.md.options.quotes[2],f=t.md.options.quotes[3]):(o=t.md.options.quotes[0],f=t.md.options.quotes[1]),s.content=ip(s.content,h.index,f),e[c.token].content=ip(e[c.token].content,c.pos,o),a+=f.length-1,c.token===i&&(a+=o.length-1),u=(l=s.content).length,r.length=n;continue i}}c?r.push({token:i,pos:h.index,single:d,level:o}):f&&d&&(s.content=ip(s.content,h.index,"’"))}}}(e.tokens[t].children,e)}}],["text_join",function(e){let t,n;let r=e.tokens,i=r.length;for(let e=0;e<i;e++){if("inline"!==r[e].type)continue;let i=r[e].children,s=i.length;for(t=0;t<s;t++)"text_special"===i[t].type&&(i[t].type="text");for(t=n=0;t<s;t++)"text"===i[t].type&&t+1<s&&"text"===i[t+1].type?i[t+1].content=i[t].content+i[t+1].content:(t!==n&&(i[n]=i[t]),n++);t!==n&&(i.length=n)}}]];function ig(){this.ruler=new ie;for(let e=0;e<im.length;e++)this.ruler.push(im[e][0],im[e][1])}ig.prototype.process=function(e){let t=this.ruler.getRules("");for(let n=0,r=t.length;n<r;n++)t[n](e)},ig.prototype.State=ir;function iy(e,t,n,r){this.src=e,this.md=t,this.env=n,this.tokens=r,this.bMarks=[],this.eMarks=[],this.tShift=[],this.sCount=[],this.bsCount=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.ddIndent=-1,this.listIndent=-1,this.parentType="root",this.level=0;let i=this.src;for(let e=0,t=0,n=0,r=0,s=i.length,o=!1;t<s;t++){let l=i.charCodeAt(t);if(!o){if(rX(l)){n++,9===l?r+=4-r%4:r++;continue}o=!0}(10===l||t===s-1)&&(10!==l&&t++,this.bMarks.push(e),this.eMarks.push(t),this.tShift.push(n),this.sCount.push(r),this.bsCount.push(0),o=!1,n=0,r=0,e=t+1)}this.bMarks.push(i.length),this.eMarks.push(i.length),this.tShift.push(0),this.sCount.push(0),this.bsCount.push(0),this.lineMax=this.bMarks.length-1}iy.prototype.push=function(e,t,n){let r=new it(e,t,n);return r.block=!0,n<0&&this.level--,r.level=this.level,n>0&&this.level++,this.tokens.push(r),r},iy.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},iy.prototype.skipEmptyLines=function(e){for(let t=this.lineMax;e<t&&!(this.bMarks[e]+this.tShift[e]<this.eMarks[e]);e++);return e},iy.prototype.skipSpaces=function(e){for(let t=this.src.length;e<t&&rX(this.src.charCodeAt(e));e++);return e},iy.prototype.skipSpacesBack=function(e,t){if(e<=t)return e;for(;e>t;)if(!rX(this.src.charCodeAt(--e)))return e+1;return e},iy.prototype.skipChars=function(e,t){for(let n=this.src.length;e<n&&this.src.charCodeAt(e)===t;e++);return e},iy.prototype.skipCharsBack=function(e,t,n){if(e<=n)return e;for(;e>n;)if(t!==this.src.charCodeAt(--e))return e+1;return e},iy.prototype.getLines=function(e,t,n,r){if(e>=t)return"";let i=Array(t-e);for(let s=0,o=e;o<t;o++,s++){let e,l=0,a=this.bMarks[o],u=a;for(e=o+1<t||r?this.eMarks[o]+1:this.eMarks[o];u<e&&l<n;){let e=this.src.charCodeAt(u);if(rX(e))9===e?l+=4-(l+this.bsCount[o])%4:l++;else if(u-a<this.tShift[o])l++;else break;u++}l>n?i[s]=Array(l-n+1).join(" ")+this.src.slice(u,e):i[s]=this.src.slice(u,e)}return i.join("")},iy.prototype.Token=it;function ib(e,t){let n=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];return e.src.slice(n,r)}function iv(e){let t=[],n=e.length,r=0,i=e.charCodeAt(r),s=!1,o=0,l="";for(;r<n;)124===i&&(s?(l+=e.substring(o,r-1),o=r):(t.push(l+e.substring(o,r)),l="",o=r+1)),s=92===i,r++,i=e.charCodeAt(r);return t.push(l+e.substring(o)),t}function ik(e,t){let n=e.eMarks[t],r=e.bMarks[t]+e.tShift[t],i=e.src.charCodeAt(r++);return 42!==i&&45!==i&&43!==i||r<n&&!rX(e.src.charCodeAt(r))?-1:r}function iw(e,t){let n=e.bMarks[t]+e.tShift[t],r=e.eMarks[t],i=n;if(i+1>=r)return -1;let s=e.src.charCodeAt(i++);if(s<48||s>57)return -1;for(;;){if(i>=r)return -1;if((s=e.src.charCodeAt(i++))>=48&&s<=57){if(i-n>=10)return -1;continue}if(41===s||46===s)break;return -1}return i<r&&!rX(s=e.src.charCodeAt(i))?-1:i}let iD="<[A-Za-z][A-Za-z0-9\\-]*(?:\\s+[a-zA-Z_:][a-zA-Z0-9:._-]*(?:\\s*=\\s*(?:[^\"'=<>`\\x00-\\x20]+|'[^']*'|\"[^\"]*\"))?)*\\s*\\/?>",iA="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",ix=RegExp("^(?:"+iD+"|"+iA+"|\x3c!---?>|\x3c!--(?:[^-]|-[^-]|--[^>])*--\x3e|<[?][\\s\\S]*?[?]>|<![A-Za-z][^>]*>|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>)"),iC=RegExp("^(?:"+iD+"|"+iA+")"),iE=[[/^<(script|pre|style|textarea)(?=(\s|>|$))/i,/<\/(script|pre|style|textarea)>/i,!0],[/^<!--/,/-->/,!0],[/^<\?/,/\?>/,!0],[/^<![A-Z]/,/>/,!0],[/^<!\[CDATA\[/,/\]\]>/,!0],[RegExp("^</?("+"address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h1|h2|h3|h4|h5|h6|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul)(?=(\\s|/?>|$))","i"),/^$/,!0],[RegExp(iC.source+"\\s*$"),/^$/,!1]],iS=[["table",function(e,t,n,r){let i;if(t+2>n)return!1;let s=t+1;if(e.sCount[s]<e.blkIndent||e.sCount[s]-e.blkIndent>=4)return!1;let o=e.bMarks[s]+e.tShift[s];if(o>=e.eMarks[s])return!1;let l=e.src.charCodeAt(o++);if(124!==l&&45!==l&&58!==l||o>=e.eMarks[s])return!1;let a=e.src.charCodeAt(o++);if(124!==a&&45!==a&&58!==a&&!rX(a)||45===l&&rX(a))return!1;for(;o<e.eMarks[s];){let t=e.src.charCodeAt(o);if(124!==t&&45!==t&&58!==t&&!rX(t))return!1;o++}let u=ib(e,t+1),h=u.split("|"),c=[];for(let e=0;e<h.length;e++){let t=h[e].trim();if(!t){if(0===e||e===h.length-1)continue;return!1}if(!/^:?-+:?$/.test(t))return!1;58===t.charCodeAt(t.length-1)?c.push(58===t.charCodeAt(0)?"center":"right"):58===t.charCodeAt(0)?c.push("left"):c.push("")}if(-1===(u=ib(e,t).trim()).indexOf("|")||e.sCount[t]-e.blkIndent>=4)return!1;(h=iv(u)).length&&""===h[0]&&h.shift(),h.length&&""===h[h.length-1]&&h.pop();let f=h.length;if(0===f||f!==c.length)return!1;if(r)return!0;let d=e.parentType;e.parentType="table";let p=e.md.block.ruler.getRules("blockquote"),m=e.push("table_open","table",1),g=[t,0];m.map=g,e.push("thead_open","thead",1).map=[t,t+1],e.push("tr_open","tr",1).map=[t,t+1];for(let t=0;t<h.length;t++){let n=e.push("th_open","th",1);c[t]&&(n.attrs=[["style","text-align:"+c[t]]]);let r=e.push("inline","",0);r.content=h[t].trim(),r.children=[],e.push("th_close","th",-1)}e.push("tr_close","tr",-1),e.push("thead_close","thead",-1);let y=0;for(s=t+2;s<n&&!(e.sCount[s]<e.blkIndent);s++){;let r=!1;for(let t=0,i=p.length;t<i;t++)if(p[t](e,s,n,!0)){r=!0;break}if(r||!(u=ib(e,s).trim())||e.sCount[s]-e.blkIndent>=4)break;if((h=iv(u)).length&&""===h[0]&&h.shift(),h.length&&""===h[h.length-1]&&h.pop(),(y+=f-h.length)>65536)break;s===t+2&&(e.push("tbody_open","tbody",1).map=i=[t+2,0]),e.push("tr_open","tr",1).map=[s,s+1];for(let t=0;t<f;t++){let n=e.push("td_open","td",1);c[t]&&(n.attrs=[["style","text-align:"+c[t]]]);let r=e.push("inline","",0);r.content=h[t]?h[t].trim():"",r.children=[],e.push("td_close","td",-1)}e.push("tr_close","tr",-1)}return i&&(e.push("tbody_close","tbody",-1),i[1]=s),e.push("table_close","table",-1),g[1]=s,e.parentType=d,e.line=s,!0},["paragraph","reference"]],["code",function(e,t,n){if(e.sCount[t]-e.blkIndent<4)return!1;let r=t+1,i=r;for(;r<n;){if(e.isEmpty(r)){r++;continue}if(e.sCount[r]-e.blkIndent>=4){i=++r;continue}break}e.line=i;let s=e.push("code_block","code",0);return s.content=e.getLines(t,i,4+e.blkIndent,!1)+"\n",s.map=[t,e.line],!0}],["fence",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||i+3>s)return!1;let o=e.src.charCodeAt(i);if(126!==o&&96!==o)return!1;let l=i,a=(i=e.skipChars(i,o))-l;if(a<3)return!1;let u=e.src.slice(l,i),h=e.src.slice(i,s);if(96===o&&h.indexOf(String.fromCharCode(o))>=0)return!1;if(r)return!0;let c=t,f=!1;for(;!(++c>=n);){;if(i=l=e.bMarks[c]+e.tShift[c],i<(s=e.eMarks[c])&&e.sCount[c]<e.blkIndent)break;if(!(e.src.charCodeAt(i)!==o||e.sCount[c]-e.blkIndent>=4||(i=e.skipChars(i,o))-l<a||(i=e.skipSpaces(i))<s)){f=!0;break}}a=e.sCount[t],e.line=c+(f?1:0);let d=e.push("fence","code",0);return d.info=h,d.content=e.getLines(t+1,c,a,!0),d.markup=u,d.map=[t,e.line],!0},["paragraph","reference","blockquote","list"]],["blockquote",function(e,t,n,r){let i,s=e.bMarks[t]+e.tShift[t],o=e.eMarks[t],l=e.lineMax;if(e.sCount[t]-e.blkIndent>=4||62!==e.src.charCodeAt(s))return!1;if(r)return!0;let a=[],u=[],h=[],c=[],f=e.md.block.ruler.getRules("blockquote"),d=e.parentType;e.parentType="blockquote";let p=!1;for(i=t;i<n;i++){let t=e.sCount[i]<e.blkIndent;if(s=e.bMarks[i]+e.tShift[i],s>=(o=e.eMarks[i]))break;if(62===e.src.charCodeAt(s++)&&!t){let t,n,r=e.sCount[i]+1;32===e.src.charCodeAt(s)?(s++,r++,n=!1,t=!0):9===e.src.charCodeAt(s)?(t=!0,(e.bsCount[i]+r)%4==3?(s++,r++,n=!1):n=!0):t=!1;let l=r;for(a.push(e.bMarks[i]),e.bMarks[i]=s;s<o;){let t=e.src.charCodeAt(s);if(rX(t))9===t?l+=4-(l+e.bsCount[i]+(n?1:0))%4:l++;else break;s++}p=s>=o,u.push(e.bsCount[i]),e.bsCount[i]=e.sCount[i]+1+(t?1:0),h.push(e.sCount[i]),e.sCount[i]=l-r,c.push(e.tShift[i]),e.tShift[i]=s-e.bMarks[i];continue}if(p)break;let r=!1;for(let t=0,s=f.length;t<s;t++)if(f[t](e,i,n,!0)){r=!0;break}if(r){e.lineMax=i,0!==e.blkIndent&&(a.push(e.bMarks[i]),u.push(e.bsCount[i]),c.push(e.tShift[i]),h.push(e.sCount[i]),e.sCount[i]-=e.blkIndent);break}a.push(e.bMarks[i]),u.push(e.bsCount[i]),c.push(e.tShift[i]),h.push(e.sCount[i]),e.sCount[i]=-1}let m=e.blkIndent;e.blkIndent=0;let g=e.push("blockquote_open","blockquote",1);g.markup=">";let y=[t,0];g.map=y,e.md.block.tokenize(e,t,i),e.push("blockquote_close","blockquote",-1).markup=">",e.lineMax=l,e.parentType=d,y[1]=e.line;for(let n=0;n<c.length;n++)e.bMarks[n+t]=a[n],e.tShift[n+t]=c[n],e.sCount[n+t]=h[n],e.bsCount[n+t]=u[n];return e.blkIndent=m,!0},["paragraph","reference","blockquote","list"]],["hr",function(e,t,n,r){let i=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let s=e.bMarks[t]+e.tShift[t],o=e.src.charCodeAt(s++);if(42!==o&&45!==o&&95!==o)return!1;let l=1;for(;s<i;){let t=e.src.charCodeAt(s++);if(t!==o&&!rX(t))return!1;t===o&&l++}if(l<3)return!1;if(r)return!0;e.line=t+1;let a=e.push("hr","hr",0);return a.map=[t,e.line],a.markup=Array(l+1).join(String.fromCharCode(o)),!0},["paragraph","reference","blockquote","list"]],["list",function(e,t,n,r){let i,s,o,l,a,u,h;let c=t,f=!0;if(e.sCount[c]-e.blkIndent>=4||e.listIndent>=0&&e.sCount[c]-e.listIndent>=4&&e.sCount[c]<e.blkIndent)return!1;let d=!1;if(r&&"paragraph"===e.parentType&&e.sCount[c]>=e.blkIndent&&(d=!0),(h=iw(e,c))>=0){if(a=!0,o=e.bMarks[c]+e.tShift[c],u=Number(e.src.slice(o,h-1)),d&&1!==u)return!1}else{if(!((h=ik(e,c))>=0))return!1;a=!1}if(d&&e.skipSpaces(h)>=e.eMarks[c])return!1;if(r)return!0;let p=e.src.charCodeAt(h-1),m=e.tokens.length;a?(l=e.push("ordered_list_open","ol",1),1!==u&&(l.attrs=[["start",u]])):l=e.push("bullet_list_open","ul",1);let g=[c,0];l.map=g,l.markup=String.fromCharCode(p);let y=!1,b=e.md.block.ruler.getRules("list"),v=e.parentType;for(e.parentType="list";c<n;){let t;s=h,i=e.eMarks[c];let r=e.sCount[c]+h-(e.bMarks[c]+e.tShift[c]),u=r;for(;s<i;){let t=e.src.charCodeAt(s);if(9===t)u+=4-(u+e.bsCount[c])%4;else if(32===t)u++;else break;s++}let d=s;(t=d>=i?1:u-r)>4&&(t=1);let m=r+t;(l=e.push("list_item_open","li",1)).markup=String.fromCharCode(p);let g=[c,0];l.map=g,a&&(l.info=e.src.slice(o,h-1));let v=e.tight,k=e.tShift[c],w=e.sCount[c],D=e.listIndent;if(e.listIndent=e.blkIndent,e.blkIndent=m,e.tight=!0,e.tShift[c]=d-e.bMarks[c],e.sCount[c]=u,d>=i&&e.isEmpty(c+1)?e.line=Math.min(e.line+2,n):e.md.block.tokenize(e,c,n,!0),(!e.tight||y)&&(f=!1),y=e.line-c>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=D,e.tShift[c]=k,e.sCount[c]=w,e.tight=v,(l=e.push("list_item_close","li",-1)).markup=String.fromCharCode(p),c=e.line,g[1]=c,c>=n||e.sCount[c]<e.blkIndent||e.sCount[c]-e.blkIndent>=4)break;let A=!1;for(let t=0,r=b.length;t<r;t++)if(b[t](e,c,n,!0)){A=!0;break}if(A)break;if(a){if((h=iw(e,c))<0)break;o=e.bMarks[c]+e.tShift[c]}else if((h=ik(e,c))<0)break;if(p!==e.src.charCodeAt(h-1))break}return(l=a?e.push("ordered_list_close","ol",-1):e.push("bullet_list_close","ul",-1)).markup=String.fromCharCode(p),g[1]=c,e.line=c,e.parentType=v,f&&!function(e,t){let n=e.level+2;for(let r=t+2,i=e.tokens.length-2;r<i;r++)e.tokens[r].level===n&&"paragraph_open"===e.tokens[r].type&&(e.tokens[r+2].hidden=!0,e.tokens[r].hidden=!0,r+=2)}(e,m),!0},["paragraph","reference","blockquote"]],["reference",function(e,t,n,r){let i,s=e.bMarks[t]+e.tShift[t],o=e.eMarks[t],l=t+1;if(e.sCount[t]-e.blkIndent>=4||91!==e.src.charCodeAt(s))return!1;function a(t){let n=e.lineMax;if(t>=n||e.isEmpty(t))return null;let r=!1;if(e.sCount[t]-e.blkIndent>3&&(r=!0),e.sCount[t]<0&&(r=!0),!r){let r=e.md.block.ruler.getRules("reference"),i=e.parentType;e.parentType="reference";let s=!1;for(let i=0,o=r.length;i<o;i++)if(r[i](e,t,n,!0)){s=!0;break}if(e.parentType=i,s)return null}let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];return e.src.slice(i,s+1)}let u=e.src.slice(s,o+1);o=u.length;let h=-1;for(s=1;s<o;s++){let e=u.charCodeAt(s);if(91===e)return!1;if(93===e){h=s;break}else if(10===e){let e=a(l);null!==e&&(u+=e,o=u.length,l++)}else if(92===e&&++s<o&&10===u.charCodeAt(s)){let e=a(l);null!==e&&(u+=e,o=u.length,l++)}}if(h<0||58!==u.charCodeAt(h+1))return!1;for(s=h+2;s<o;s++){let e=u.charCodeAt(s);if(10===e){let e=a(l);null!==e&&(u+=e,o=u.length,l++)}else if(rX(e));else break}let c=e.md.helpers.parseLinkDestination(u,s,o);if(!c.ok)return!1;let f=e.md.normalizeLink(c.str);if(!e.md.validateLink(f))return!1;let d=s=c.pos,p=l,m=s;for(;s<o;s++){let e=u.charCodeAt(s);if(10===e){let e=a(l);null!==e&&(u+=e,o=u.length,l++)}else if(rX(e));else break}let g=e.md.helpers.parseLinkTitle(u,s,o);for(;g.can_continue;){let t=a(l);if(null===t)break;u+=t,s=o,o=u.length,l++,g=e.md.helpers.parseLinkTitle(u,s,o,g)}for(s<o&&m!==s&&g.ok?(i=g.str,s=g.pos):(i="",s=d,l=p);s<o&&rX(u.charCodeAt(s));){;s++}if(s<o&&10!==u.charCodeAt(s)&&i)for(i="",s=d,l=p;s<o&&rX(u.charCodeAt(s));){;s++}if(s<o&&10!==u.charCodeAt(s))return!1;let y=r3(u.slice(1,h));return!!y&&(!!r||(void 0===e.env.references&&(e.env.references={}),void 0===e.env.references[y]&&(e.env.references[y]={title:i,href:f}),e.line=l,!0))}],["html_block",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||!e.md.options.html||60!==e.src.charCodeAt(i))return!1;let o=e.src.slice(i,s),l=0;for(;l<iE.length&&!iE[l][0].test(o);l++);if(l===iE.length)return!1;if(r)return iE[l][2];let a=t+1;if(!iE[l][1].test(o))for(;a<n&&!(e.sCount[a]<e.blkIndent);a++){;if(i=e.bMarks[a]+e.tShift[a],s=e.eMarks[a],o=e.src.slice(i,s),iE[l][1].test(o)){0!==o.length&&a++;break}}e.line=a;let u=e.push("html_block","",0);return u.map=[t,a],u.content=e.getLines(t,a,e.blkIndent,!0),!0},["paragraph","reference","blockquote"]],["heading",function(e,t,n,r){let i=e.bMarks[t]+e.tShift[t],s=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;let o=e.src.charCodeAt(i);if(35!==o||i>=s)return!1;let l=1;for(o=e.src.charCodeAt(++i);35===o&&i<s&&l<=6;)l++,o=e.src.charCodeAt(++i);if(l>6||i<s&&!rX(o))return!1;if(r)return!0;s=e.skipSpacesBack(s,i);let a=e.skipCharsBack(s,35,i);a>i&&rX(e.src.charCodeAt(a-1))&&(s=a),e.line=t+1;let u=e.push("heading_open","h"+String(l),1);u.markup="########".slice(0,l),u.map=[t,e.line];let h=e.push("inline","",0);return h.content=e.src.slice(i,s).trim(),h.map=[t,e.line],h.children=[],e.push("heading_close","h"+String(l),-1).markup="########".slice(0,l),!0},["paragraph","reference","blockquote"]],["lheading",function(e,t,n){let r;let i=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;let s=e.parentType;e.parentType="paragraph";let o=0,l=t+1;for(;l<n&&!e.isEmpty(l);l++){if(e.sCount[l]-e.blkIndent>3)continue;if(e.sCount[l]>=e.blkIndent){let t=e.bMarks[l]+e.tShift[l],n=e.eMarks[l];if(t<n&&(45===(r=e.src.charCodeAt(t))||61===r)&&(t=e.skipChars(t,r),(t=e.skipSpaces(t))>=n)){o=61===r?1:2;break}}if(e.sCount[l]<0)continue;let t=!1;for(let r=0,s=i.length;r<s;r++)if(i[r](e,l,n,!0)){t=!0;break}if(t)break}if(!o)return!1;let a=e.getLines(t,l,e.blkIndent,!1).trim();e.line=l+1;let u=e.push("heading_open","h"+String(o),1);u.markup=String.fromCharCode(r),u.map=[t,e.line];let h=e.push("inline","",0);return h.content=a,h.map=[t,e.line-1],h.children=[],e.push("heading_close","h"+String(o),-1).markup=String.fromCharCode(r),e.parentType=s,!0}],["paragraph",function(e,t,n){let r=e.md.block.ruler.getRules("paragraph"),i=e.parentType,s=t+1;for(e.parentType="paragraph";s<n&&!e.isEmpty(s);s++){if(e.sCount[s]-e.blkIndent>3||e.sCount[s]<0)continue;let t=!1;for(let i=0,o=r.length;i<o;i++)if(r[i](e,s,n,!0)){t=!0;break}if(t)break}let o=e.getLines(t,s,e.blkIndent,!1).trim();e.line=s,e.push("paragraph_open","p",1).map=[t,e.line];let l=e.push("inline","",0);return l.content=o,l.map=[t,e.line],l.children=[],e.push("paragraph_close","p",-1),e.parentType=i,!0}]];function i_(){this.ruler=new ie;for(let e=0;e<iS.length;e++)this.ruler.push(iS[e][0],iS[e][1],{alt:(iS[e][2]||[]).slice()})}i_.prototype.tokenize=function(e,t,n){let r=this.ruler.getRules(""),i=r.length,s=e.md.options.maxNesting,o=t,l=!1;for(;o<n&&(e.line=o=e.skipEmptyLines(o),!(o>=n)&&!(e.sCount[o]<e.blkIndent));){;if(e.level>=s){e.line=n;break}let t=e.line,a=!1;for(let s=0;s<i;s++)if(a=r[s](e,o,n,!1)){if(t>=e.line)throw Error("block rule didn't increment state.line");break}if(!a)throw Error("none of the block rules matched");e.tight=!l,e.isEmpty(e.line-1)&&(l=!0),(o=e.line)<n&&e.isEmpty(o)&&(l=!0,o++,e.line=o)}},i_.prototype.parse=function(e,t,n,r){if(!e)return;let i=new this.State(e,t,n,r);this.tokenize(i,i.line,i.lineMax)},i_.prototype.State=iy;function iO(e,t,n,r){this.src=e,this.env=n,this.md=t,this.tokens=r,this.tokens_meta=Array(r.length),this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache={},this.delimiters=[],this._prev_delimiters=[],this.backticks={},this.backticksScanned=!1,this.linkLevel=0}iO.prototype.pushPending=function(){let e=new it("text","",0);return e.content=this.pending,e.level=this.pendingLevel,this.tokens.push(e),this.pending="",e},iO.prototype.push=function(e,t,n){this.pending&&this.pushPending();let r=new it(e,t,n),i=null;return n<0&&(this.level--,this.delimiters=this._prev_delimiters.pop()),r.level=this.level,n>0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],i={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(r),this.tokens_meta.push(i),r},iO.prototype.scanDelims=function(e,t){let n=this.posMax,r=this.src.charCodeAt(e),i=e>0?this.src.charCodeAt(e-1):32,s=e;for(;s<n&&this.src.charCodeAt(s)===r;)s++;let o=s-e,l=s<n?this.src.charCodeAt(s):32,a=r2(i)||r1(String.fromCharCode(i)),u=r2(l)||r1(String.fromCharCode(l)),h=r0(i),c=r0(l),f=!c&&(!u||h||a),d=!h&&(!a||c||u);return{can_open:f&&(t||!d||a),can_close:d&&(t||!f||u),length:o}},iO.prototype.Token=it;let iF=/(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i,iP=[];for(let e=0;e<256;e++)iP.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(e){iP[e.charCodeAt(0)]=1});function iT(e,t){let n;let r=[],i=t.length;for(let s=0;s<i;s++){let i=t[s];if(126!==i.marker||-1===i.end)continue;let o=t[i.end];(n=e.tokens[i.token]).type="s_open",n.tag="s",n.nesting=1,n.markup="~~",n.content="",(n=e.tokens[o.token]).type="s_close",n.tag="s",n.nesting=-1,n.markup="~~",n.content="","text"===e.tokens[o.token-1].type&&"~"===e.tokens[o.token-1].content&&r.push(o.token-1)}for(;r.length;){let t=r.pop(),i=t+1;for(;i<e.tokens.length&&"s_close"===e.tokens[i].type;)i++;t!==--i&&(n=e.tokens[i],e.tokens[i]=e.tokens[t],e.tokens[t]=n)}}let iN=function(e,t){let n;let r=e.pos,i=e.src.charCodeAt(r);if(t||126!==i)return!1;let s=e.scanDelims(e.pos,!0),o=s.length,l=String.fromCharCode(i);if(o<2)return!1;o%2&&((n=e.push("text","",0)).content=l,o--);for(let t=0;t<o;t+=2)(n=e.push("text","",0)).content=l+l,e.delimiters.push({marker:i,length:0,token:e.tokens.length-1,end:-1,open:s.can_open,close:s.can_close});return e.pos+=s.length,!0},iB=function(e){let t=e.tokens_meta,n=e.tokens_meta.length;iT(e,e.delimiters);for(let r=0;r<n;r++)t[r]&&t[r].delimiters&&iT(e,t[r].delimiters)};function iI(e,t){let n=t.length;for(let r=n-1;r>=0;r--){let n=t[r];if(95!==n.marker&&42!==n.marker||-1===n.end)continue;let i=t[n.end],s=r>0&&t[r-1].end===n.end+1&&t[r-1].marker===n.marker&&t[r-1].token===n.token-1&&t[n.end+1].token===i.token+1,o=String.fromCharCode(n.marker),l=e.tokens[n.token];l.type=s?"strong_open":"em_open",l.tag=s?"strong":"em",l.nesting=1,l.markup=s?o+o:o,l.content="";let a=e.tokens[i.token];a.type=s?"strong_close":"em_close",a.tag=s?"strong":"em",a.nesting=-1,a.markup=s?o+o:o,a.content="",s&&(e.tokens[t[r-1].token].content="",e.tokens[t[n.end+1].token].content="",r--)}}let iM=function(e,t){let n=e.pos,r=e.src.charCodeAt(n);if(t||95!==r&&42!==r)return!1;let i=e.scanDelims(e.pos,42===r);for(let t=0;t<i.length;t++)e.push("text","",0).content=String.fromCharCode(r),e.delimiters.push({marker:r,length:i.length,token:e.tokens.length-1,end:-1,open:i.can_open,close:i.can_close});return e.pos+=i.length,!0},i$=function(e){let t=e.tokens_meta,n=e.tokens_meta.length;iI(e,e.delimiters);for(let r=0;r<n;r++)t[r]&&t[r].delimiters&&iI(e,t[r].delimiters)},iL=/^([a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)$/,iR=/^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\x00-\x20]*)$/,ij=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,iq=/^&([a-z][a-z0-9]{1,31});/i;function iV(e){let t={},n=e.length;if(!n)return;let r=0,i=-2,s=[];for(let o=0;o<n;o++){let n=e[o];if(s.push(0),(e[r].marker!==n.marker||i!==n.token-1)&&(r=o),i=n.token,n.length=n.length||0,!n.close)continue;!t.hasOwnProperty(n.marker)&&(t[n.marker]=[-1,-1,-1,-1,-1,-1]);let l=t[n.marker][(n.open?3:0)+n.length%3],a=r-s[r]-1,u=a;for(;a>l;a-=s[a]+1){let t=e[a];if(t.marker===n.marker&&t.open&&t.end<0){let r=!1;if((t.close||n.open)&&(t.length+n.length)%3==0&&(t.length%3!=0||n.length%3!=0)&&(r=!0),!r){let r=a>0&&!e[a-1].open?s[a-1]+1:0;s[o]=o-a+r,s[a]=r,n.open=!1,t.end=o,t.close=!1,u=-1,i=-2;break}}}-1!==u&&(t[n.marker][(n.open?3:0)+(n.length||0)%3]=u)}}let iz=[["text",function(e,t){let n=e.pos;for(;n<e.posMax&&!function(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}(e.src.charCodeAt(n));)n++;return n!==e.pos&&(!t&&(e.pending+=e.src.slice(e.pos,n)),e.pos=n,!0)}],["linkify",function(e,t){if(!e.md.options.linkify||e.linkLevel>0)return!1;let n=e.pos;if(n+3>e.posMax||58!==e.src.charCodeAt(n)||47!==e.src.charCodeAt(n+1)||47!==e.src.charCodeAt(n+2))return!1;let r=e.pending.match(iF);if(!r)return!1;let i=r[1],s=e.md.linkify.matchAtStart(e.src.slice(n-i.length));if(!s)return!1;let o=s.url;if(o.length<=i.length)return!1;o=o.replace(/\*+$/,"");let l=e.md.normalizeLink(o);if(!e.md.validateLink(l))return!1;if(!t){e.pending=e.pending.slice(0,-i.length);let t=e.push("link_open","a",1);t.attrs=[["href",l]],t.markup="linkify",t.info="auto",e.push("text","",0).content=e.md.normalizeLinkText(o);let n=e.push("link_close","a",-1);n.markup="linkify",n.info="auto"}return e.pos+=o.length-i.length,!0}],["newline",function(e,t){let n=e.pos;if(10!==e.src.charCodeAt(n))return!1;let r=e.pending.length-1,i=e.posMax;if(!t){if(r>=0&&32===e.pending.charCodeAt(r)){if(r>=1&&32===e.pending.charCodeAt(r-1)){let t=r-1;for(;t>=1&&32===e.pending.charCodeAt(t-1);)t--;e.pending=e.pending.slice(0,t),e.push("hardbreak","br",0)}else e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0)}else e.push("softbreak","br",0)}for(n++;n<i&&rX(e.src.charCodeAt(n));)n++;return e.pos=n,!0}],["escape",function(e,t){let n=e.pos,r=e.posMax;if(92!==e.src.charCodeAt(n)||++n>=r)return!1;let i=e.src.charCodeAt(n);if(10===i){for(!t&&e.push("hardbreak","br",0),n++;n<r&&rX(i=e.src.charCodeAt(n));){;n++}return e.pos=n,!0}let s=e.src[n];if(i>=55296&&i<=56319&&n+1<r){let t=e.src.charCodeAt(n+1);t>=56320&&t<=57343&&(s+=e.src[n+1],n++)}let o="\\"+s;if(!t){let t=e.push("text_special","",0);i<256&&0!==iP[i]?t.content=s:t.content=o,t.markup=o,t.info="escape"}return e.pos=n+1,!0}],["backticks",function(e,t){let n,r=e.pos;if(96!==e.src.charCodeAt(r))return!1;let i=r;r++;let s=e.posMax;for(;r<s&&96===e.src.charCodeAt(r);)r++;let o=e.src.slice(i,r),l=o.length;if(e.backticksScanned&&(e.backticks[l]||0)<=i)return!t&&(e.pending+=o),e.pos+=l,!0;let a=r;for(;-1!==(n=e.src.indexOf("`",a));){for(a=n+1;a<s&&96===e.src.charCodeAt(a);)a++;let i=a-n;if(i===l){if(!t){let t=e.push("code_inline","code",0);t.markup=o,t.content=e.src.slice(r,n).replace(/\n/g," ").replace(/^ (.+) $/,"$1")}return e.pos=a,!0}e.backticks[i]=n}return e.backticksScanned=!0,!t&&(e.pending+=o),e.pos+=l,!0}],["strikethrough",iN],["emphasis",iM],["link",function(e,t){let n,r,i,s;let o="",l="",a=e.pos,u=!0;if(91!==e.src.charCodeAt(e.pos))return!1;let h=e.pos,c=e.posMax,f=e.pos+1,d=e.md.helpers.parseLinkLabel(e,e.pos,!0);if(d<0)return!1;let p=d+1;if(p<c&&40===e.src.charCodeAt(p)){for(u=!1,p++;p<c&&(rX(n=e.src.charCodeAt(p))||10===n);p++);if(p>=c)return!1;if(a=p,(i=e.md.helpers.parseLinkDestination(e.src,p,e.posMax)).ok){for(o=e.md.normalizeLink(i.str),e.md.validateLink(o)?p=i.pos:o="",a=p;p<c&&(rX(n=e.src.charCodeAt(p))||10===n);p++);if(i=e.md.helpers.parseLinkTitle(e.src,p,e.posMax),p<c&&a!==p&&i.ok)for(l=i.str,p=i.pos;p<c&&(rX(n=e.src.charCodeAt(p))||10===n);p++);}(p>=c||41!==e.src.charCodeAt(p))&&(u=!0),p++}if(u){if(void 0===e.env.references)return!1;if(p<c&&91===e.src.charCodeAt(p)?(a=p+1,(p=e.md.helpers.parseLinkLabel(e,p))>=0?r=e.src.slice(a,p++):p=d+1):p=d+1,!r&&(r=e.src.slice(f,d)),!(s=e.env.references[r3(r)]))return e.pos=h,!1;o=s.href,l=s.title}if(!t){e.pos=f,e.posMax=d;let t=e.push("link_open","a",1),n=[["href",o]];t.attrs=n,l&&n.push(["title",l]),e.linkLevel++,e.md.inline.tokenize(e),e.linkLevel--,e.push("link_close","a",-1)}return e.pos=p,e.posMax=c,!0}],["image",function(e,t){let n,r,i,s,o,l,a,u;let h="",c=e.pos,f=e.posMax;if(33!==e.src.charCodeAt(e.pos)||91!==e.src.charCodeAt(e.pos+1))return!1;let d=e.pos+2,p=e.md.helpers.parseLinkLabel(e,e.pos+1,!1);if(p<0)return!1;if((s=p+1)<f&&40===e.src.charCodeAt(s)){for(s++;s<f&&(rX(n=e.src.charCodeAt(s))||10===n);s++);if(s>=f)return!1;for(u=s,(l=e.md.helpers.parseLinkDestination(e.src,s,e.posMax)).ok&&(h=e.md.normalizeLink(l.str),e.md.validateLink(h)?s=l.pos:h=""),u=s;s<f&&(rX(n=e.src.charCodeAt(s))||10===n);s++);if(l=e.md.helpers.parseLinkTitle(e.src,s,e.posMax),s<f&&u!==s&&l.ok)for(a=l.str,s=l.pos;s<f&&(rX(n=e.src.charCodeAt(s))||10===n);s++);else a="";if(s>=f||41!==e.src.charCodeAt(s))return e.pos=c,!1;s++}else{if(void 0===e.env.references)return!1;if(s<f&&91===e.src.charCodeAt(s)?(u=s+1,(s=e.md.helpers.parseLinkLabel(e,s))>=0?i=e.src.slice(u,s++):s=p+1):s=p+1,!i&&(i=e.src.slice(d,p)),!(o=e.env.references[r3(i)]))return e.pos=c,!1;h=o.href,a=o.title}if(!t){r=e.src.slice(d,p);let t=[];e.md.inline.parse(r,e.md,e.env,t);let n=e.push("image","img",0),i=[["src",h],["alt",""]];n.attrs=i,n.children=t,n.content=r,a&&i.push(["title",a])}return e.pos=s,e.posMax=f,!0}],["autolink",function(e,t){let n=e.pos;if(60!==e.src.charCodeAt(n))return!1;let r=e.pos,i=e.posMax;for(;;){if(++n>=i)return!1;let t=e.src.charCodeAt(n);if(60===t)return!1;if(62===t)break}let s=e.src.slice(r+1,n);if(iR.test(s)){let n=e.md.normalizeLink(s);if(!e.md.validateLink(n))return!1;if(!t){let t=e.push("link_open","a",1);t.attrs=[["href",n]],t.markup="autolink",t.info="auto",e.push("text","",0).content=e.md.normalizeLinkText(s);let r=e.push("link_close","a",-1);r.markup="autolink",r.info="auto"}return e.pos+=s.length+2,!0}if(iL.test(s)){let n=e.md.normalizeLink("mailto:"+s);if(!e.md.validateLink(n))return!1;if(!t){let t=e.push("link_open","a",1);t.attrs=[["href",n]],t.markup="autolink",t.info="auto",e.push("text","",0).content=e.md.normalizeLinkText(s);let r=e.push("link_close","a",-1);r.markup="autolink",r.info="auto"}return e.pos+=s.length+2,!0}return!1}],["html_inline",function(e,t){if(!e.md.options.html)return!1;let n=e.posMax,r=e.pos;if(60!==e.src.charCodeAt(r)||r+2>=n)return!1;let i=e.src.charCodeAt(r+1);if(33!==i&&63!==i&&47!==i&&!function(e){let t=32|e;return t>=97&&t<=122}(i))return!1;let s=e.src.slice(r).match(ix);if(!s)return!1;if(!t){var o,l;let t=e.push("html_inline","",0);if(t.content=s[0],o=t.content,/^<a[>\s]/i.test(o))e.linkLevel++;if(l=t.content,/^<\/a\s*>/i.test(l))e.linkLevel--}return e.pos+=s[0].length,!0}],["entity",function(e,t){let n=e.pos,r=e.posMax;if(38!==e.src.charCodeAt(n)||n+1>=r)return!1;if(35===e.src.charCodeAt(n+1)){let r=e.src.slice(n).match(ij);if(r){if(!t){let t="x"===r[1][0].toLowerCase()?parseInt(r[1].slice(1),16):parseInt(r[1],10),n=e.push("text_special","",0);n.content=rR(t)?rj(t):rj(65533),n.markup=r[0],n.info="entity"}return e.pos+=r[0].length,!0}}else{let r=e.src.slice(n).match(iq);if(r){let n=rP(r[0]);if(n!==r[0]){if(!t){let t=e.push("text_special","",0);t.content=n,t.markup=r[0],t.info="entity"}return e.pos+=r[0].length,!0}}}return!1}]],iU=[["balance_pairs",function(e){let t=e.tokens_meta,n=e.tokens_meta.length;iV(e.delimiters);for(let e=0;e<n;e++)t[e]&&t[e].delimiters&&iV(t[e].delimiters)}],["strikethrough",iB],["emphasis",i$],["fragments_join",function(e){let t,n;let r=0,i=e.tokens,s=e.tokens.length;for(t=n=0;t<s;t++)i[t].nesting<0&&r--,i[t].level=r,i[t].nesting>0&&r++,"text"===i[t].type&&t+1<s&&"text"===i[t+1].type?i[t+1].content=i[t].content+i[t+1].content:(t!==n&&(i[n]=i[t]),n++);t!==n&&(i.length=n)}]];function iH(){this.ruler=new ie;for(let e=0;e<iz.length;e++)this.ruler.push(iz[e][0],iz[e][1]);this.ruler2=new ie;for(let e=0;e<iU.length;e++)this.ruler2.push(iU[e][0],iU[e][1])}iH.prototype.skipToken=function(e){let t=e.pos,n=this.ruler.getRules(""),r=n.length,i=e.md.options.maxNesting,s=e.cache;if(void 0!==s[t]){e.pos=s[t];return}let o=!1;if(e.level<i){for(let i=0;i<r;i++)if(e.level++,o=n[i](e,!0),e.level--,o){if(t>=e.pos)throw Error("inline rule didn't increment state.pos");break}}else e.pos=e.posMax;!o&&e.pos++,s[t]=e.pos},iH.prototype.tokenize=function(e){let t=this.ruler.getRules(""),n=t.length,r=e.posMax,i=e.md.options.maxNesting;for(;e.pos<r;){let s=e.pos,o=!1;if(e.level<i){for(let r=0;r<n;r++)if(o=t[r](e,!1)){if(s>=e.pos)throw Error("inline rule didn't increment state.pos");break}}if(o){if(e.pos>=r)break;continue}e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},iH.prototype.parse=function(e,t,n,r){let i=new this.State(e,t,n,r);this.tokenize(i);let s=this.ruler2.getRules(""),o=s.length;for(let e=0;e<o;e++)s[e](i)},iH.prototype.State=iO;function iW(e){let t=Array.prototype.slice.call(arguments,1);return t.forEach(function(t){if(!!t)Object.keys(t).forEach(function(n){e[n]=t[n]})}),e}function iG(e){return Object.prototype.toString.call(e)}function iK(e){return"[object Function]"===iG(e)}function iJ(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}let iQ={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1},iY={"http:":{validate:function(e,t,n){let r=e.slice(t);return(!n.re.http&&(n.re.http=RegExp("^\\/\\/"+n.re.src_auth+n.re.src_host_port_strict+n.re.src_path,"i")),n.re.http.test(r))?r.match(n.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,t,n){let r=e.slice(t);if(!n.re.no_http&&(n.re.no_http=RegExp("^"+n.re.src_auth+"(?:localhost|(?:(?:"+n.re.src_domain+")\\.)+"+n.re.src_domain_root+")"+n.re.src_port+n.re.src_host_terminator+n.re.src_path,"i")),n.re.no_http.test(r))return t>=3&&":"===e[t-3]||t>=3&&"/"===e[t-3]?0:r.match(n.re.no_http)[0].length;return 0}},"mailto:":{validate:function(e,t,n){let r=e.slice(t);return(!n.re.mailto&&(n.re.mailto=RegExp("^"+n.re.src_email_name+"@"+n.re.src_host_strict,"i")),n.re.mailto.test(r))?r.match(n.re.mailto)[0].length:0}}},iZ="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");function iX(){return function(e,t){t.normalize(e)}}function i0(e){var t;let n=e.re=function(e){let t={};e=e||{},t.src_Any=rv.source,t.src_Cc=rk.source,t.src_Z=rD.source,t.src_P=ry.source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");let n="[><|]";return t.src_pseudo_letter="(?:(?!"+n+"|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|"+n+"|"+t.src_ZPCc+")(?!"+(e["---"]?"-(?!--)|":"-|")+"_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|"+n+"|[()[\\]{}.,\"'?!\\-;]).|\\[(?:(?!"+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+'|["]).)+\\"|\\\'(?:(?!'+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-])|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+t.src_ZCc+"|[.]|$)|"+(e["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+",(?!"+t.src_ZCc+"|$)|;(?!"+t.src_ZCc+"|$)|\\!+(?!"+t.src_ZCc+"|[!]|$)|\\?(?!"+t.src_ZCc+"|[?]|$))+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy="(^|"+n+'|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}(e.__opts__),r=e.__tlds__.slice();function i(e){return e.replace("%TLDS%",n.src_tlds)}e.onCompile(),!e.__tlds_replaced__&&r.push("a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]"),r.push(n.src_xn),n.src_tlds=r.join("|"),n.email_fuzzy=RegExp(i(n.tpl_email_fuzzy),"i"),n.link_fuzzy=RegExp(i(n.tpl_link_fuzzy),"i"),n.link_no_ip_fuzzy=RegExp(i(n.tpl_link_no_ip_fuzzy),"i"),n.host_fuzzy_test=RegExp(i(n.tpl_host_fuzzy_test),"i");let s=[];function o(e,t){throw Error('(LinkifyIt) Invalid schema "'+e+'": '+t)}e.__compiled__={},Object.keys(e.__schemas__).forEach(function(t){let n=e.__schemas__[t];if(null===n)return;let r={validate:null,link:null};if(e.__compiled__[t]=r,"[object Object]"===iG(n)){if("[object RegExp]"===iG(n.validate)){var i;r.validate=(i=n.validate,function(e,t){let n=e.slice(t);return i.test(n)?n.match(i)[0].length:0})}else iK(n.validate)?r.validate=n.validate:o(t,n);iK(n.normalize)?r.normalize=n.normalize:n.normalize?o(t,n):r.normalize=iX();return}if("[object String]"===iG(n)){s.push(t);return}o(t,n)}),s.forEach(function(t){if(!!e.__compiled__[e.__schemas__[t]])e.__compiled__[t].validate=e.__compiled__[e.__schemas__[t]].validate,e.__compiled__[t].normalize=e.__compiled__[e.__schemas__[t]].normalize}),e.__compiled__[""]={validate:null,normalize:iX()};let l=Object.keys(e.__compiled__).filter(function(t){return t.length>0&&e.__compiled__[t]}).map(iJ).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><|]|"+n.src_ZPCc+"))("+l+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><|]|"+n.src_ZPCc+"))("+l+")","ig"),e.re.schema_at_start=RegExp("^"+e.re.schema_search.source,"i"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),(t=e).__index__=-1,t.__text_cache__=""}function i1(e,t){let n=e.__index__,r=e.__last_index__,i=e.__text_cache__.slice(n,r);this.schema=e.__schema__.toLowerCase(),this.index=n+t,this.lastIndex=r+t,this.raw=i,this.text=i,this.url=i}function i2(e,t){let n=new i1(e,t);return e.__compiled__[n.schema].normalize(n,e),n}function i3(e,t){if(!(this instanceof i3))return new i3(e,t);if(!t){if(Object.keys(e||{}).reduce(function(e,t){return e||iQ.hasOwnProperty(t)},!1))t=e,e={}}this.__opts__=iW({},iQ,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=iW({},iY,e),this.__compiled__={},this.__tlds__=iZ,this.__tlds_replaced__=!1,this.re={},i0(this)}i3.prototype.add=function(e,t){return this.__schemas__[e]=t,i0(this),this},i3.prototype.set=function(e){return this.__opts__=iW(this.__opts__,e),this},i3.prototype.test=function(e){let t,n,r,i,s,o,l,a;if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;if(this.re.schema_test.test(e)){for((l=this.re.schema_search).lastIndex=0;null!==(t=l.exec(e));)if(i=this.testSchemaAt(e,t[2],l.lastIndex)){this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+i;break}}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(a=e.search(this.re.host_fuzzy_test))>=0&&(this.__index__<0||a<this.__index__)&&null!==(n=e.match(this.__opts__.fuzzyIP?this.re.link_fuzzy:this.re.link_no_ip_fuzzy))&&(s=n.index+n[1].length,(this.__index__<0||s<this.__index__)&&(this.__schema__="",this.__index__=s,this.__last_index__=n.index+n[0].length)),this.__opts__.fuzzyEmail&&this.__compiled__["mailto:"]&&e.indexOf("@")>=0&&null!==(r=e.match(this.re.email_fuzzy))&&(s=r.index+r[1].length,o=r.index+r[0].length,(this.__index__<0||s<this.__index__||s===this.__index__&&o>this.__last_index__)&&(this.__schema__="mailto:",this.__index__=s,this.__last_index__=o)),this.__index__>=0},i3.prototype.pretest=function(e){return this.re.pretest.test(e)},i3.prototype.testSchemaAt=function(e,t,n){return this.__compiled__[t.toLowerCase()]?this.__compiled__[t.toLowerCase()].validate(e,n,this):0},i3.prototype.match=function(e){let t=[],n=0;this.__index__>=0&&this.__text_cache__===e&&(t.push(i2(this,n)),n=this.__last_index__);let r=n?e.slice(n):e;for(;this.test(r);)t.push(i2(this,n)),r=r.slice(this.__last_index__),n+=this.__last_index__;return t.length?t:null},i3.prototype.matchAtStart=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return null;let t=this.re.schema_at_start.exec(e);if(!t)return null;let n=this.testSchemaAt(e,t[2],t[0].length);return n?(this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+n,i2(this,0)):null},i3.prototype.tlds=function(e,t){return(e=Array.isArray(e)?e:[e],t)?(this.__tlds__=this.__tlds__.concat(e).sort().filter(function(e,t,n){return e!==n[t-1]}).reverse(),i0(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,i0(this),this)},i3.prototype.normalize=function(e){!e.schema&&(e.url="http://"+e.url),"mailto:"===e.schema&&!/^mailto:/i.test(e.url)&&(e.url="mailto:"+e.url)},i3.prototype.onCompile=function(){};let i5=/^xn--/,i8=/[^\0-\x7F]/,i4=/[\x2E\u3002\uFF0E\uFF61]/g,i6={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},i9=35,i7=Math.floor,se=String.fromCharCode;function st(e){throw RangeError(i6[e])}function sn(e,t){let n=e.split("@"),r="";return n.length>1&&(r=n[0]+"@",e=n[1]),r+(function(e,t){let n=[],r=e.length;for(;r--;)n[r]=t(e[r]);return n})((e=e.replace(i4,".")).split("."),t).join(".")}function sr(e){let t=[],n=0,r=e.length;for(;n<r;){let i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){let r=e.charCodeAt(n++);(64512&r)==56320?t.push(((1023&i)<<10)+(1023&r)+65536):(t.push(i),n--)}else t.push(i)}return t}let si=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},ss=function(e,t,n){let r=0;for(e=n?i7(e/700):e>>1,e+=i7(e/t);e>26*i9>>1;r+=36)e=i7(e/i9);return i7(r+(i9+1)*e/(e+38))},so=function(e){let t=[],n=e.length,r=0,i=128,s=72,o=e.lastIndexOf("-");o<0&&(o=0);for(let n=0;n<o;++n)e.charCodeAt(n)>=128&&st("not-basic"),t.push(e.charCodeAt(n));for(let a=o>0?o+1:0;a<n;){let o=r;for(let t=1,i=36;;i+=36){var l;a>=n&&st("invalid-input");let o=(l=e.charCodeAt(a++))>=48&&l<58?26+(l-48):l>=65&&l<91?l-65:l>=97&&l<123?l-97:36;o>=36&&st("invalid-input"),o>i7((0x7fffffff-r)/t)&&st("overflow"),r+=o*t;let u=i<=s?1:i>=s+26?26:i-s;if(o<u)break;let h=36-u;t>i7(0x7fffffff/h)&&st("overflow"),t*=h}let u=t.length+1;s=ss(r-o,u,0==o),i7(r/u)>0x7fffffff-i&&st("overflow"),i+=i7(r/u),r%=u,t.splice(r++,0,i)}return String.fromCodePoint(...t)},sl=function(e){let t=[],n=(e=sr(e)).length,r=128,i=0,s=72;for(let n of e)n<128&&t.push(se(n));let o=t.length,l=o;for(o&&t.push("-");l<n;){let n=0x7fffffff;for(let t of e)t>=r&&t<n&&(n=t);let a=l+1;for(let u of(n-r>i7((0x7fffffff-i)/a)&&st("overflow"),i+=(n-r)*a,r=n,e))if(u<r&&++i>0x7fffffff&&st("overflow"),u===r){let e=i;for(let n=36;;n+=36){let r=n<=s?1:n>=s+26?26:n-s;if(e<r)break;let i=e-r,o=36-r;t.push(se(si(r+i%o,0))),e=i7(i/o)}t.push(se(si(e,0))),s=ss(i,a,l===o),i=0,++l}++i,++r}return t.join("")},sa={toASCII:function(e){return sn(e,function(e){return i8.test(e)?"xn--"+sl(e):e})},toUnicode:function(e){return sn(e,function(e){return i5.test(e)?so(e.slice(4).toLowerCase()):e})}},su={default:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}},zero:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","fragments_join"]}}},commonmark:{options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline","text_join"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","fragments_join"]}}}},sh=/^(vbscript|javascript|file|data):/,sc=/^data:image\/(gif|png|jpeg|webp);/;function sf(e){let t=e.trim().toLowerCase();return!sh.test(t)||sc.test(t)}let sd=["http:","https:","mailto:"];function sp(e){let t=rg(e,!0);if(t.hostname&&(!t.protocol||sd.indexOf(t.protocol)>=0))try{t.hostname=sa.toASCII(t.hostname)}catch(e){}return ri(rs(t))}function sm(e){let t=rg(e,!0);if(t.hostname&&(!t.protocol||sd.indexOf(t.protocol)>=0))try{t.hostname=sa.toUnicode(t.hostname)}catch(e){}return rt(rs(t),rt.defaultChars+"%")}function sg(e,t){if(!(this instanceof sg))return new sg(e,t);!t&&!rB(e)&&(t=e||{},e="default"),this.inline=new iH,this.block=new i_,this.core=new ig,this.renderer=new r7,this.linkify=new i3,this.validateLink=sf,this.normalizeLink=sp,this.normalizeLinkText=sm,this.utils=B,this.helpers=r$({},I),this.options={},this.configure(e),t&&this.set(t)}sg.prototype.set=function(e){return r$(this.options,e),this},sg.prototype.configure=function(e){let t=this;if(rB(e)){let t=e;if(!(e=su[t]))throw Error('Wrong `markdown-it` preset "'+t+'", check name')}if(!e)throw Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach(function(n){e.components[n].rules&&t[n].ruler.enableOnly(e.components[n].rules),e.components[n].rules2&&t[n].ruler2.enableOnly(e.components[n].rules2)}),this},sg.prototype.enable=function(e,t){let n=[];!Array.isArray(e)&&(e=[e]),["core","block","inline"].forEach(function(t){n=n.concat(this[t].ruler.enable(e,!0))},this),n=n.concat(this.inline.ruler2.enable(e,!0));let r=e.filter(function(e){return 0>n.indexOf(e)});if(r.length&&!t)throw Error("MarkdownIt. Failed to enable unknown rule(s): "+r);return this},sg.prototype.disable=function(e,t){let n=[];!Array.isArray(e)&&(e=[e]),["core","block","inline"].forEach(function(t){n=n.concat(this[t].ruler.disable(e,!0))},this),n=n.concat(this.inline.ruler2.disable(e,!0));let r=e.filter(function(e){return 0>n.indexOf(e)});if(r.length&&!t)throw Error("MarkdownIt. Failed to disable unknown rule(s): "+r);return this},sg.prototype.use=function(e){let t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},sg.prototype.parse=function(e,t){if("string"!=typeof e)throw Error("Input data should be a String");let n=new this.core.State(e,this,t);return this.core.process(n),n.tokens},sg.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},sg.prototype.parseInline=function(e,t){let n=new this.core.State(e,this,t);return n.inlineMode=!0,this.core.process(n),n.tokens},sg.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)};let sy=[{id:"abap",name:"ABAP",import:()=>n.e("83804").then(n.bind(n,8558))},{id:"actionscript-3",name:"ActionScript",import:()=>n.e("58153").then(n.bind(n,54546))},{id:"ada",name:"Ada",import:()=>n.e("41275").then(n.bind(n,21918))},{id:"angular-html",name:"Angular HTML",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("63671")]).then(n.bind(n,14210))},{id:"angular-ts",name:"Angular TypeScript",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("12291"),n.e("86548")]).then(n.bind(n,8338))},{id:"apache",name:"Apache Conf",import:()=>n.e("42967").then(n.bind(n,63434))},{id:"apex",name:"Apex",import:()=>n.e("38050").then(n.bind(n,63044))},{id:"apl",name:"APL",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("39124")]).then(n.bind(n,40973))},{id:"applescript",name:"AppleScript",import:()=>n.e("93809").then(n.bind(n,9509))},{id:"ara",name:"Ara",import:()=>n.e("64735").then(n.bind(n,23942))},{id:"asciidoc",name:"AsciiDoc",aliases:["adoc"],import:()=>n.e("16054").then(n.bind(n,72309))},{id:"asm",name:"Assembly",import:()=>n.e("18491").then(n.bind(n,58195))},{id:"astro",name:"Astro",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("50454"),n.e("76771")]).then(n.bind(n,75353))},{id:"awk",name:"AWK",import:()=>n.e("97653").then(n.bind(n,19003))},{id:"ballerina",name:"Ballerina",import:()=>n.e("45181").then(n.bind(n,46295))},{id:"bat",name:"Batch File",aliases:["batch"],import:()=>n.e("42856").then(n.bind(n,46362))},{id:"beancount",name:"Beancount",import:()=>n.e("2498").then(n.bind(n,59926))},{id:"berry",name:"Berry",aliases:["be"],import:()=>n.e("59796").then(n.bind(n,1599))},{id:"bibtex",name:"BibTeX",import:()=>n.e("96749").then(n.bind(n,99686))},{id:"bicep",name:"Bicep",import:()=>n.e("31475").then(n.bind(n,93868))},{id:"blade",name:"Blade",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("56341")]).then(n.bind(n,63426))},{id:"c",name:"C",import:()=>n.e("27428").then(n.bind(n,89168))},{id:"cadence",name:"Cadence",aliases:["cdc"],import:()=>n.e("92907").then(n.bind(n,27e3))},{id:"clarity",name:"Clarity",import:()=>n.e("81521").then(n.bind(n,39301))},{id:"clojure",name:"Clojure",aliases:["clj"],import:()=>n.e("51620").then(n.bind(n,60895))},{id:"cmake",name:"CMake",import:()=>n.e("92324").then(n.bind(n,17228))},{id:"cobol",name:"COBOL",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("43714")]).then(n.bind(n,91989))},{id:"codeowners",name:"CODEOWNERS",import:()=>n.e("52990").then(n.bind(n,82539))},{id:"codeql",name:"CodeQL",aliases:["ql"],import:()=>n.e("98556").then(n.bind(n,26869))},{id:"coffee",name:"CoffeeScript",aliases:["coffeescript"],import:()=>Promise.all([n.e("47592"),n.e("69120")]).then(n.bind(n,22825))},{id:"common-lisp",name:"Common Lisp",aliases:["lisp"],import:()=>n.e("76063").then(n.bind(n,80858))},{id:"coq",name:"Coq",import:()=>n.e("31447").then(n.bind(n,6206))},{id:"cpp",name:"C++",aliases:["c++"],import:()=>Promise.all([n.e("59638"),n.e("27428"),n.e("31832")]).then(n.bind(n,98546))},{id:"crystal",name:"Crystal",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("59638"),n.e("27428"),n.e("49081"),n.e("86831")]).then(n.bind(n,31452))},{id:"csharp",name:"C#",aliases:["c#","cs"],import:()=>n.e("74705").then(n.bind(n,59572))},{id:"css",name:"CSS",import:()=>n.e("40463").then(n.bind(n,18353))},{id:"csv",name:"CSV",import:()=>n.e("90957").then(n.bind(n,89257))},{id:"cue",name:"CUE",import:()=>n.e("42770").then(n.bind(n,19810))},{id:"cypher",name:"Cypher",aliases:["cql"],import:()=>n.e("88055").then(n.bind(n,14657))},{id:"d",name:"D",import:()=>n.e("7047").then(n.bind(n,89826))},{id:"dart",name:"Dart",import:()=>n.e("12673").then(n.bind(n,902))},{id:"dax",name:"DAX",import:()=>n.e("35793").then(n.bind(n,5467))},{id:"desktop",name:"Desktop",import:()=>n.e("87928").then(n.bind(n,26031))},{id:"diff",name:"Diff",import:()=>n.e("65736").then(n.bind(n,94198))},{id:"docker",name:"Dockerfile",aliases:["dockerfile"],import:()=>n.e("4798").then(n.bind(n,99204))},{id:"dotenv",name:"dotEnv",import:()=>n.e("32230").then(n.bind(n,21780))},{id:"dream-maker",name:"Dream Maker",import:()=>n.e("88830").then(n.bind(n,73555))},{id:"edge",name:"Edge",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("50454"),n.e("42108")]).then(n.bind(n,92616))},{id:"elixir",name:"Elixir",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("1766")]).then(n.bind(n,1103))},{id:"elm",name:"Elm",import:()=>Promise.all([n.e("27428"),n.e("88036")]).then(n.bind(n,5993))},{id:"emacs-lisp",name:"Emacs Lisp",aliases:["elisp"],import:()=>n.e("15641").then(n.bind(n,44672))},{id:"erb",name:"ERB",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("27428"),n.e("49081"),n.e("23501"),n.e("37981")]).then(n.bind(n,47865))},{id:"erlang",name:"Erlang",aliases:["erl"],import:()=>n.e("69202").then(n.bind(n,98931))},{id:"fennel",name:"Fennel",import:()=>n.e("4786").then(n.bind(n,62780))},{id:"fish",name:"Fish",import:()=>n.e("30969").then(n.bind(n,3190))},{id:"fluent",name:"Fluent",aliases:["ftl"],import:()=>n.e("17526").then(n.bind(n,51257))},{id:"fortran-fixed-form",name:"Fortran (Fixed Form)",aliases:["f","for","f77"],import:()=>Promise.all([n.e("50122"),n.e("15724")]).then(n.bind(n,32042))},{id:"fortran-free-form",name:"Fortran (Free Form)",aliases:["f90","f95","f03","f08","f18"],import:()=>n.e("50122").then(n.bind(n,75417))},{id:"fsharp",name:"F#",aliases:["f#","fs"],import:()=>Promise.all([n.e("24085"),n.e("51350")]).then(n.bind(n,34189))},{id:"gdresource",name:"GDResource",import:()=>Promise.all([n.e("33035"),n.e("8746")]).then(n.bind(n,59132))},{id:"gdscript",name:"GDScript",import:()=>n.e("33035").then(n.bind(n,76429))},{id:"gdshader",name:"GDShader",import:()=>n.e("1266").then(n.bind(n,75970))},{id:"genie",name:"Genie",import:()=>n.e("40118").then(n.bind(n,23258))},{id:"gherkin",name:"Gherkin",import:()=>n.e("26754").then(n.bind(n,62978))},{id:"git-commit",name:"Git Commit Message",import:()=>n.e("93745").then(n.bind(n,59448))},{id:"git-rebase",name:"Git Rebase Message",import:()=>Promise.all([n.e("49081"),n.e("8275")]).then(n.bind(n,66639))},{id:"gleam",name:"Gleam",import:()=>n.e("49429").then(n.bind(n,31282))},{id:"glimmer-js",name:"Glimmer JS",aliases:["gjs"],import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("50454"),n.e("53538")]).then(n.bind(n,21657))},{id:"glimmer-ts",name:"Glimmer TS",aliases:["gts"],import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("50454"),n.e("43810")]).then(n.bind(n,41760))},{id:"glsl",name:"GLSL",import:()=>Promise.all([n.e("27428"),n.e("71449")]).then(n.bind(n,53715))},{id:"gnuplot",name:"Gnuplot",import:()=>n.e("84546").then(n.bind(n,10635))},{id:"go",name:"Go",import:()=>n.e("59151").then(n.bind(n,40623))},{id:"graphql",name:"GraphQL",aliases:["gql"],import:()=>Promise.all([n.e("47592"),n.e("50454"),n.e("82183"),n.e("36805"),n.e("48396")]).then(n.bind(n,67405))},{id:"groovy",name:"Groovy",import:()=>n.e("58103").then(n.bind(n,50842))},{id:"hack",name:"Hack",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("59638"),n.e("71944")]).then(n.bind(n,80216))},{id:"haml",name:"Ruby Haml",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("30761")]).then(n.bind(n,99512))},{id:"handlebars",name:"Handlebars",aliases:["hbs"],import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("13523")]).then(n.bind(n,9290))},{id:"haskell",name:"Haskell",aliases:["hs"],import:()=>n.e("44381").then(n.bind(n,18155))},{id:"haxe",name:"Haxe",import:()=>n.e("20606").then(n.bind(n,6765))},{id:"hcl",name:"HashiCorp HCL",import:()=>n.e("26760").then(n.bind(n,24378))},{id:"hjson",name:"Hjson",import:()=>n.e("76495").then(n.bind(n,17015))},{id:"hlsl",name:"HLSL",import:()=>n.e("52535").then(n.bind(n,61679))},{id:"html",name:"HTML",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252")]).then(n.bind(n,90641))},{id:"html-derivative",name:"HTML (Derivative)",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("61281")]).then(n.bind(n,92973))},{id:"http",name:"HTTP",import:()=>Promise.all([n.e("47592"),n.e("22088"),n.e("50454"),n.e("49081"),n.e("82183"),n.e("36805"),n.e("48396"),n.e("87123")]).then(n.bind(n,65544))},{id:"hxml",name:"HXML",import:()=>Promise.all([n.e("20606"),n.e("99518")]).then(n.bind(n,30755))},{id:"hy",name:"Hy",import:()=>n.e("36113").then(n.bind(n,96928))},{id:"imba",name:"Imba",import:()=>Promise.all([n.e("50454"),n.e("83343")]).then(n.bind(n,45676))},{id:"ini",name:"INI",aliases:["properties"],import:()=>n.e("26846").then(n.bind(n,65818))},{id:"java",name:"Java",import:()=>n.e("22088").then(n.bind(n,2171))},{id:"javascript",name:"JavaScript",aliases:["js"],import:()=>n.e("47592").then(n.bind(n,29504))},{id:"jinja",name:"Jinja",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("61670")]).then(n.bind(n,7799))},{id:"jison",name:"Jison",import:()=>Promise.all([n.e("47592"),n.e("74522")]).then(n.bind(n,82870))},{id:"json",name:"JSON",import:()=>n.e("11634").then(n.bind(n,20094))},{id:"json5",name:"JSON5",import:()=>n.e("50522").then(n.bind(n,15211))},{id:"jsonc",name:"JSON with Comments",import:()=>n.e("86394").then(n.bind(n,2860))},{id:"jsonl",name:"JSON Lines",import:()=>n.e("89651").then(n.bind(n,52858))},{id:"jsonnet",name:"Jsonnet",import:()=>n.e("8274").then(n.bind(n,66905))},{id:"jssm",name:"JSSM",aliases:["fsl"],import:()=>n.e("61953").then(n.bind(n,57294))},{id:"jsx",name:"JSX",import:()=>n.e("82183").then(n.bind(n,63345))},{id:"julia",name:"Julia",aliases:["jl"],import:()=>Promise.all([n.e("47592"),n.e("59638"),n.e("27428"),n.e("55041"),n.e("19246"),n.e("31832"),n.e("17090")]).then(n.bind(n,75093))},{id:"kotlin",name:"Kotlin",aliases:["kt","kts"],import:()=>n.e("72591").then(n.bind(n,74036))},{id:"kusto",name:"Kusto",aliases:["kql"],import:()=>n.e("14957").then(n.bind(n,13460))},{id:"latex",name:"LaTeX",import:()=>Promise.all([n.e("19246"),n.e("98907")]).then(n.bind(n,15665))},{id:"lean",name:"Lean 4",aliases:["lean4"],import:()=>n.e("90317").then(n.bind(n,82650))},{id:"less",name:"Less",import:()=>n.e("52305").then(n.bind(n,70669))},{id:"liquid",name:"Liquid",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("53356")]).then(n.bind(n,80561))},{id:"log",name:"Log file",import:()=>n.e("27437").then(n.bind(n,55700))},{id:"logo",name:"Logo",import:()=>n.e("24469").then(n.bind(n,32025))},{id:"lua",name:"Lua",import:()=>Promise.all([n.e("27428"),n.e("63757")]).then(n.bind(n,5898))},{id:"luau",name:"Luau",import:()=>n.e("10807").then(n.bind(n,79254))},{id:"make",name:"Makefile",aliases:["makefile"],import:()=>n.e("32970").then(n.bind(n,67807))},{id:"markdown",name:"Markdown",aliases:["md"],import:()=>n.e("24085").then(n.bind(n,76093))},{id:"marko",name:"Marko",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("12291"),n.e("52305"),n.e("72056")]).then(n.bind(n,58015))},{id:"matlab",name:"MATLAB",import:()=>n.e("69963").then(n.bind(n,56163))},{id:"mdc",name:"MDC",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("24085"),n.e("40808")]).then(n.bind(n,86298))},{id:"mdx",name:"MDX",import:()=>n.e("96931").then(n.bind(n,24520))},{id:"mermaid",name:"Mermaid",aliases:["mmd"],import:()=>n.e("78136").then(n.bind(n,7601))},{id:"mipsasm",name:"MIPS Assembly",aliases:["mips"],import:()=>n.e("68463").then(n.bind(n,81553))},{id:"mojo",name:"Mojo",import:()=>n.e("8813").then(n.bind(n,81304))},{id:"move",name:"Move",import:()=>n.e("45245").then(n.bind(n,40704))},{id:"narrat",name:"Narrat Language",aliases:["nar"],import:()=>n.e("93357").then(n.bind(n,35430))},{id:"nextflow",name:"Nextflow",aliases:["nf"],import:()=>n.e("2354").then(n.bind(n,69386))},{id:"nginx",name:"Nginx",import:()=>Promise.all([n.e("27428"),n.e("62438")]).then(n.bind(n,24473))},{id:"nim",name:"Nim",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("27428"),n.e("24085"),n.e("69626")]).then(n.bind(n,90250))},{id:"nix",name:"Nix",import:()=>n.e("37554").then(n.bind(n,13789))},{id:"nushell",name:"nushell",aliases:["nu"],import:()=>n.e("25032").then(n.bind(n,94360))},{id:"objective-c",name:"Objective-C",aliases:["objc"],import:()=>n.e("71557").then(n.bind(n,93662))},{id:"objective-cpp",name:"Objective-C++",import:()=>n.e("72998").then(n.bind(n,32658))},{id:"ocaml",name:"OCaml",import:()=>n.e("90937").then(n.bind(n,20377))},{id:"pascal",name:"Pascal",import:()=>n.e("83006").then(n.bind(n,91975))},{id:"perl",name:"Perl",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("40517")]).then(n.bind(n,52237))},{id:"php",name:"PHP",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("73210"),n.e("69840")]).then(n.bind(n,60654))},{id:"plsql",name:"PL/SQL",import:()=>n.e("67457").then(n.bind(n,28414))},{id:"po",name:"Gettext PO",aliases:["pot","potx"],import:()=>n.e("8241").then(n.bind(n,68566))},{id:"postcss",name:"PostCSS",import:()=>n.e("9432").then(n.bind(n,68655))},{id:"powerquery",name:"PowerQuery",import:()=>n.e("16259").then(n.bind(n,31798))},{id:"powershell",name:"PowerShell",aliases:["ps","ps1"],import:()=>n.e("21184").then(n.bind(n,28194))},{id:"prisma",name:"Prisma",import:()=>n.e("28413").then(n.bind(n,26647))},{id:"prolog",name:"Prolog",import:()=>n.e("97364").then(n.bind(n,10402))},{id:"proto",name:"Protocol Buffer 3",aliases:["protobuf"],import:()=>n.e("98222").then(n.bind(n,97284))},{id:"pug",name:"Pug",aliases:["jade"],import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("68556")]).then(n.bind(n,42771))},{id:"puppet",name:"Puppet",import:()=>n.e("99471").then(n.bind(n,35178))},{id:"purescript",name:"PureScript",import:()=>n.e("845").then(n.bind(n,46933))},{id:"python",name:"Python",aliases:["py"],import:()=>n.e("55041").then(n.bind(n,69955))},{id:"qml",name:"QML",import:()=>Promise.all([n.e("47592"),n.e("40339")]).then(n.bind(n,38488))},{id:"qmldir",name:"QML Directory",import:()=>n.e("17032").then(n.bind(n,54679))},{id:"qss",name:"Qt Style Sheets",import:()=>n.e("88099").then(n.bind(n,35377))},{id:"r",name:"R",import:()=>n.e("19246").then(n.bind(n,51786))},{id:"racket",name:"Racket",import:()=>n.e("20562").then(n.bind(n,41513))},{id:"raku",name:"Raku",aliases:["perl6"],import:()=>n.e("97381").then(n.bind(n,29765))},{id:"razor",name:"ASP.NET Razor",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("74705"),n.e("14385")]).then(n.bind(n,96506))},{id:"reg",name:"Windows Registry Script",import:()=>n.e("7823").then(n.bind(n,89351))},{id:"regexp",name:"RegExp",aliases:["regex"],import:()=>n.e("77952").then(n.bind(n,79490))},{id:"rel",name:"Rel",import:()=>n.e("90785").then(n.bind(n,15764))},{id:"riscv",name:"RISC-V",import:()=>n.e("63298").then(n.bind(n,93410))},{id:"rst",name:"reStructuredText",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("27428"),n.e("49081"),n.e("55041"),n.e("23501"),n.e("31832"),n.e("24228")]).then(n.bind(n,69356))},{id:"ruby",name:"Ruby",aliases:["rb"],import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("27428"),n.e("49081"),n.e("23501")]).then(n.bind(n,54991))},{id:"rust",name:"Rust",aliases:["rs"],import:()=>n.e("5287").then(n.bind(n,6233))},{id:"sas",name:"SAS",import:()=>Promise.all([n.e("59638"),n.e("16691")]).then(n.bind(n,80182))},{id:"sass",name:"Sass",import:()=>n.e("58776").then(n.bind(n,93317))},{id:"scala",name:"Scala",import:()=>n.e("49352").then(n.bind(n,4891))},{id:"scheme",name:"Scheme",import:()=>n.e("47116").then(n.bind(n,20556))},{id:"scss",name:"SCSS",import:()=>Promise.all([n.e("40463"),n.e("12291")]).then(n.bind(n,1593))},{id:"shaderlab",name:"ShaderLab",aliases:["shader"],import:()=>n.e("7232").then(n.bind(n,50110))},{id:"shellscript",name:"Shell",aliases:["bash","sh","shell","zsh"],import:()=>n.e("49081").then(n.bind(n,72531))},{id:"shellsession",name:"Shell Session",aliases:["console"],import:()=>Promise.all([n.e("49081"),n.e("26975")]).then(n.bind(n,54750))},{id:"smalltalk",name:"Smalltalk",import:()=>n.e("9315").then(n.bind(n,40702))},{id:"solidity",name:"Solidity",import:()=>n.e("18942").then(n.bind(n,4200))},{id:"soy",name:"Closure Templates",aliases:["closure-templates"],import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("19577")]).then(n.bind(n,48682))},{id:"sparql",name:"SPARQL",import:()=>n.e("5203").then(n.bind(n,71931))},{id:"splunk",name:"Splunk Query Language",aliases:["spl"],import:()=>n.e("1550").then(n.bind(n,57714))},{id:"sql",name:"SQL",import:()=>n.e("59638").then(n.bind(n,99502))},{id:"ssh-config",name:"SSH Config",import:()=>n.e("5653").then(n.bind(n,53836))},{id:"stata",name:"Stata",import:()=>Promise.all([n.e("59638"),n.e("92803")]).then(n.bind(n,93149))},{id:"stylus",name:"Stylus",aliases:["styl"],import:()=>n.e("74366").then(n.bind(n,8126))},{id:"svelte",name:"Svelte",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("50454"),n.e("66894")]).then(n.bind(n,42434))},{id:"swift",name:"Swift",import:()=>n.e("92669").then(n.bind(n,19087))},{id:"system-verilog",name:"SystemVerilog",import:()=>n.e("37716").then(n.bind(n,88701))},{id:"systemd",name:"Systemd Units",import:()=>n.e("32495").then(n.bind(n,74358))},{id:"tasl",name:"Tasl",import:()=>n.e("491").then(n.bind(n,63364))},{id:"tcl",name:"Tcl",import:()=>n.e("34850").then(n.bind(n,74683))},{id:"templ",name:"Templ",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("59151"),n.e("38541")]).then(n.bind(n,95808))},{id:"terraform",name:"Terraform",aliases:["tf","tfvars"],import:()=>n.e("44980").then(n.bind(n,96366))},{id:"tex",name:"TeX",import:()=>Promise.all([n.e("19246"),n.e("5737")]).then(n.bind(n,69652))},{id:"toml",name:"TOML",import:()=>n.e("99537").then(n.bind(n,42865))},{id:"ts-tags",name:"TypeScript with Tags",aliases:["lit"],import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("27428"),n.e("50454"),n.e("33538")]).then(n.bind(n,84496))},{id:"tsv",name:"TSV",import:()=>n.e("32430").then(n.bind(n,82712))},{id:"tsx",name:"TSX",import:()=>n.e("36805").then(n.bind(n,96470))},{id:"turtle",name:"Turtle",import:()=>n.e("62179").then(n.bind(n,86447))},{id:"twig",name:"Twig",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("22088"),n.e("59638"),n.e("27428"),n.e("49081"),n.e("55041"),n.e("23501"),n.e("12291"),n.e("73210"),n.e("13883")]).then(n.bind(n,65304))},{id:"typescript",name:"TypeScript",aliases:["ts"],import:()=>n.e("50454").then(n.bind(n,55245))},{id:"typespec",name:"TypeSpec",aliases:["tsp"],import:()=>n.e("51953").then(n.bind(n,33529))},{id:"typst",name:"Typst",aliases:["typ"],import:()=>n.e("92802").then(n.bind(n,34478))},{id:"v",name:"V",import:()=>n.e("79228").then(n.bind(n,39307))},{id:"vala",name:"Vala",import:()=>n.e("77793").then(n.bind(n,32568))},{id:"vb",name:"Visual Basic",aliases:["cmd"],import:()=>n.e("47736").then(n.bind(n,25794))},{id:"verilog",name:"Verilog",import:()=>n.e("30474").then(n.bind(n,5685))},{id:"vhdl",name:"VHDL",import:()=>n.e("39614").then(n.bind(n,41847))},{id:"viml",name:"Vim Script",aliases:["vim","vimscript"],import:()=>n.e("49360").then(n.bind(n,49820))},{id:"vue",name:"Vue",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("50454"),n.e("1811")]).then(n.bind(n,74116))},{id:"vue-html",name:"Vue HTML",import:()=>Promise.all([n.e("47592"),n.e("40463"),n.e("73252"),n.e("50454"),n.e("1811"),n.e("17629")]).then(n.bind(n,78435))},{id:"vyper",name:"Vyper",aliases:["vy"],import:()=>n.e("53620").then(n.bind(n,4074))},{id:"wasm",name:"WebAssembly",import:()=>n.e("15934").then(n.bind(n,26385))},{id:"wenyan",name:"Wenyan",aliases:["文言"],import:()=>n.e("63032").then(n.bind(n,92673))},{id:"wgsl",name:"WGSL",import:()=>n.e("62336").then(n.bind(n,43221))},{id:"wikitext",name:"Wikitext",aliases:["mediawiki","wiki"],import:()=>n.e("84791").then(n.bind(n,41637))},{id:"wolfram",name:"Wolfram",aliases:["wl"],import:()=>n.e("12311").then(n.bind(n,49036))},{id:"xml",name:"XML",import:()=>Promise.all([n.e("22088"),n.e("80676")]).then(n.bind(n,44164))},{id:"xsl",name:"XSL",import:()=>Promise.all([n.e("22088"),n.e("93833")]).then(n.bind(n,17257))},{id:"yaml",name:"YAML",aliases:["yml"],import:()=>n.e("50561").then(n.bind(n,18156))},{id:"zenscript",name:"ZenScript",import:()=>n.e("79264").then(n.bind(n,57902))},{id:"zig",name:"Zig",import:()=>n.e("78970").then(n.bind(n,88617))}],sb=Object.fromEntries(sy.map(e=>[e.id,e.import])),sv=Object.fromEntries(sy.flatMap(e=>e.aliases?.map(t=>[t,e.import])||[])),sk={...sb,...sv},sw=Object.fromEntries([{id:"andromeeda",displayName:"Andromeeda",type:"dark",import:()=>n.e("44997").then(n.bind(n,42039))},{id:"aurora-x",displayName:"Aurora X",type:"dark",import:()=>n.e("34759").then(n.bind(n,21568))},{id:"ayu-dark",displayName:"Ayu Dark",type:"dark",import:()=>n.e("46437").then(n.bind(n,12209))},{id:"catppuccin-frappe",displayName:"Catppuccin Frapp\xe9",type:"dark",import:()=>n.e("27172").then(n.bind(n,22738))},{id:"catppuccin-latte",displayName:"Catppuccin Latte",type:"light",import:()=>n.e("5016").then(n.bind(n,69096))},{id:"catppuccin-macchiato",displayName:"Catppuccin Macchiato",type:"dark",import:()=>n.e("33635").then(n.bind(n,45344))},{id:"catppuccin-mocha",displayName:"Catppuccin Mocha",type:"dark",import:()=>n.e("99414").then(n.bind(n,85318))},{id:"dark-plus",displayName:"Dark Plus",type:"dark",import:()=>n.e("61398").then(n.bind(n,20958))},{id:"dracula",displayName:"Dracula Theme",type:"dark",import:()=>n.e("98147").then(n.bind(n,22926))},{id:"dracula-soft",displayName:"Dracula Theme Soft",type:"dark",import:()=>n.e("44369").then(n.bind(n,77234))},{id:"everforest-dark",displayName:"Everforest Dark",type:"dark",import:()=>n.e("50093").then(n.bind(n,38378))},{id:"everforest-light",displayName:"Everforest Light",type:"light",import:()=>n.e("29320").then(n.bind(n,25610))},{id:"github-dark",displayName:"GitHub Dark",type:"dark",import:()=>n.e("78617").then(n.bind(n,84413))},{id:"github-dark-default",displayName:"GitHub Dark Default",type:"dark",import:()=>n.e("5198").then(n.bind(n,95003))},{id:"github-dark-dimmed",displayName:"GitHub Dark Dimmed",type:"dark",import:()=>n.e("39325").then(n.bind(n,63155))},{id:"github-dark-high-contrast",displayName:"GitHub Dark High Contrast",type:"dark",import:()=>n.e("11600").then(n.bind(n,1813))},{id:"github-light",displayName:"GitHub Light",type:"light",import:()=>n.e("82320").then(n.bind(n,46711))},{id:"github-light-default",displayName:"GitHub Light Default",type:"light",import:()=>n.e("5567").then(n.bind(n,39704))},{id:"github-light-high-contrast",displayName:"GitHub Light High Contrast",type:"light",import:()=>n.e("56267").then(n.bind(n,71682))},{id:"houston",displayName:"Houston",type:"dark",import:()=>n.e("76455").then(n.bind(n,57745))},{id:"laserwave",displayName:"LaserWave",type:"dark",import:()=>n.e("33421").then(n.bind(n,44612))},{id:"light-plus",displayName:"Light Plus",type:"light",import:()=>n.e("11469").then(n.bind(n,29100))},{id:"material-theme",displayName:"Material Theme",type:"dark",import:()=>n.e("98223").then(n.bind(n,32043))},{id:"material-theme-darker",displayName:"Material Theme Darker",type:"dark",import:()=>n.e("78821").then(n.bind(n,96855))},{id:"material-theme-lighter",displayName:"Material Theme Lighter",type:"light",import:()=>n.e("41601").then(n.bind(n,6014))},{id:"material-theme-ocean",displayName:"Material Theme Ocean",type:"dark",import:()=>n.e("52854").then(n.bind(n,31295))},{id:"material-theme-palenight",displayName:"Material Theme Palenight",type:"dark",import:()=>n.e("85426").then(n.bind(n,21525))},{id:"min-dark",displayName:"Min Dark",type:"dark",import:()=>n.e("28853").then(n.bind(n,79531))},{id:"min-light",displayName:"Min Light",type:"light",import:()=>n.e("37001").then(n.bind(n,77867))},{id:"monokai",displayName:"Monokai",type:"dark",import:()=>n.e("22023").then(n.bind(n,37026))},{id:"night-owl",displayName:"Night Owl",type:"dark",import:()=>n.e("18164").then(n.bind(n,67774))},{id:"nord",displayName:"Nord",type:"dark",import:()=>n.e("73818").then(n.bind(n,19111))},{id:"one-dark-pro",displayName:"One Dark Pro",type:"dark",import:()=>n.e("12041").then(n.bind(n,42379))},{id:"one-light",displayName:"One Light",type:"light",import:()=>n.e("71725").then(n.bind(n,89628))},{id:"plastic",displayName:"Plastic",type:"dark",import:()=>n.e("2237").then(n.bind(n,64118))},{id:"poimandres",displayName:"Poimandres",type:"dark",import:()=>n.e("39307").then(n.bind(n,46324))},{id:"red",displayName:"Red",type:"dark",import:()=>n.e("89891").then(n.bind(n,44314))},{id:"rose-pine",displayName:"Ros\xe9 Pine",type:"dark",import:()=>n.e("69899").then(n.bind(n,38146))},{id:"rose-pine-dawn",displayName:"Ros\xe9 Pine Dawn",type:"light",import:()=>n.e("98667").then(n.bind(n,56269))},{id:"rose-pine-moon",displayName:"Ros\xe9 Pine Moon",type:"dark",import:()=>n.e("95929").then(n.bind(n,31228))},{id:"slack-dark",displayName:"Slack Dark",type:"dark",import:()=>n.e("66319").then(n.bind(n,9758))},{id:"slack-ochin",displayName:"Slack Ochin",type:"light",import:()=>n.e("67156").then(n.bind(n,79739))},{id:"snazzy-light",displayName:"Snazzy Light",type:"light",import:()=>n.e("90191").then(n.bind(n,11885))},{id:"solarized-dark",displayName:"Solarized Dark",type:"dark",import:()=>n.e("73455").then(n.bind(n,71144))},{id:"solarized-light",displayName:"Solarized Light",type:"light",import:()=>n.e("63197").then(n.bind(n,47824))},{id:"synthwave-84",displayName:"Synthwave '84",type:"dark",import:()=>n.e("4073").then(n.bind(n,45244))},{id:"tokyo-night",displayName:"Tokyo Night",type:"dark",import:()=>n.e("53349").then(n.bind(n,50572))},{id:"vesper",displayName:"Vesper",type:"dark",import:()=>n.e("94370").then(n.bind(n,67219))},{id:"vitesse-black",displayName:"Vitesse Black",type:"dark",import:()=>n.e("40109").then(n.bind(n,56942))},{id:"vitesse-dark",displayName:"Vitesse Dark",type:"dark",import:()=>n.e("97995").then(n.bind(n,53187))},{id:"vitesse-light",displayName:"Vitesse Light",type:"light",import:()=>n.e("71252").then(n.bind(n,43001))}].map(e=>[e.id,e.import]));class sD extends Error{constructor(e){super(e),this.name="ShikiError"}}class sA extends Error{constructor(e){super(e),this.name="ShikiError"}}function sx(){return"undefined"!=typeof performance?performance.now():Date.now()}let sC=(e,t)=>e+(t-e%t)%t;async function sE(e){let t,n;let r={};function i(e){n=e,r.HEAPU8=new Uint8Array(e),r.HEAPU32=new Uint32Array(e)}let s="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function o(e,t){return e?function(e,t,n=1024){let r=t+n,i=t;for(;e[i]&&!(i>=r);)++i;if(i-t>16&&e.buffer&&s)return s.decode(e.subarray(t,i));let o="";for(;t<i;){let n=e[t++];if(!(128&n)){o+=String.fromCharCode(n);continue}let r=63&e[t++];if((224&n)==192){o+=String.fromCharCode((31&n)<<6|r);continue}let i=63&e[t++];if((n=(240&n)==224?(15&n)<<12|r<<6|i:(7&n)<<18|r<<12|i<<6|63&e[t++])<65536)o+=String.fromCharCode(n);else{let e=n-65536;o+=String.fromCharCode(55296|e>>10,56320|1023&e)}}return o}(r.HEAPU8,e,t):""}let l={emscripten_get_now:sx,emscripten_memcpy_big:function(e,t,n){r.HEAPU8.copyWithin(e,t,t+n)},emscripten_resize_heap:function(e){let s=r.HEAPU8.length;e>>>=0;if(e>0x80000000)return!1;for(let r=1;r<=4;r*=2){let o=s*(1+.2/r);if(o=Math.min(o,e+0x6000000),function(e){try{return t.grow(e-n.byteLength+65535>>>16),i(t.buffer),1}catch{}}(Math.min(0x80000000,sC(Math.max(e,o),65536))))return!0}return!1},fd_write:()=>0};async function a(){let n=await e({env:l,wasi_snapshot_preview1:l});i((t=n.memory).buffer),Object.assign(r,n),r.UTF8ToString=o}return await a(),r}let sS=null;class s_{static _utf8ByteLength(e){let t=0;for(let n=0,r=e.length;n<r;n++){let i=e.charCodeAt(n),s=i,o=!1;if(i>=55296&&i<=56319&&n+1<r){let t=e.charCodeAt(n+1);t>=56320&&t<=57343&&(s=(i-55296<<10)+65536|t-56320,o=!0)}s<=127?t+=1:s<=2047?t+=2:s<=65535?t+=3:t+=4,o&&n++}return t}utf16Length;utf8Length;utf16Value;utf8Value;utf16OffsetToUtf8;utf8OffsetToUtf16;constructor(e){let t=e.length,n=s_._utf8ByteLength(e),r=n!==t,i=r?new Uint32Array(t+1):null;r&&(i[t]=n);let s=r?new Uint32Array(n+1):null;r&&(s[n]=t);let o=new Uint8Array(n),l=0;for(let n=0;n<t;n++){let a=e.charCodeAt(n),u=a,h=!1;if(a>=55296&&a<=56319&&n+1<t){let t=e.charCodeAt(n+1);t>=56320&&t<=57343&&(u=(a-55296<<10)+65536|t-56320,h=!0)}r&&(i[n]=l,h&&(i[n+1]=l),u<=127?s[l+0]=n:u<=2047?(s[l+0]=n,s[l+1]=n):u<=65535?(s[l+0]=n,s[l+1]=n,s[l+2]=n):(s[l+0]=n,s[l+1]=n,s[l+2]=n,s[l+3]=n)),u<=127?o[l++]=u:(u<=2047?o[l++]=192|(1984&u)>>>6:(u<=65535?o[l++]=224|(61440&u)>>>12:(o[l++]=240|(1835008&u)>>>18,o[l++]=128|(258048&u)>>>12),o[l++]=128|(4032&u)>>>6),o[l++]=128|(63&u)>>>0),h&&n++}this.utf16Length=t,this.utf8Length=n,this.utf16Value=e,this.utf8Value=o,this.utf16OffsetToUtf8=i,this.utf8OffsetToUtf16=s}createString(e){let t=e.omalloc(this.utf8Length);return e.HEAPU8.set(this.utf8Value,t),t}}class sO{static LAST_ID=0;static _sharedPtr=0;static _sharedPtrInUse=!1;id=++sO.LAST_ID;_onigBinding;content;utf16Length;utf8Length;utf16OffsetToUtf8;utf8OffsetToUtf16;ptr;constructor(e){if(!sS)throw new sA("Must invoke loadWasm first.");this._onigBinding=sS,this.content=e;let t=new s_(e);this.utf16Length=t.utf16Length,this.utf8Length=t.utf8Length,this.utf16OffsetToUtf8=t.utf16OffsetToUtf8,this.utf8OffsetToUtf16=t.utf8OffsetToUtf16,this.utf8Length<1e4&&!sO._sharedPtrInUse?(!sO._sharedPtr&&(sO._sharedPtr=sS.omalloc(1e4)),sO._sharedPtrInUse=!0,sS.HEAPU8.set(t.utf8Value,sO._sharedPtr),this.ptr=sO._sharedPtr):this.ptr=t.createString(sS)}convertUtf8OffsetToUtf16(e){if(this.utf8OffsetToUtf16)return e<0?0:e>this.utf8Length?this.utf16Length:this.utf8OffsetToUtf16[e];return e}convertUtf16OffsetToUtf8(e){if(this.utf16OffsetToUtf8)return e<0?0:e>this.utf16Length?this.utf8Length:this.utf16OffsetToUtf8[e];return e}dispose(){this.ptr===sO._sharedPtr?sO._sharedPtrInUse=!1:this._onigBinding.ofree(this.ptr)}}class sF{_onigBinding;_ptr;constructor(e){if(!sS)throw new sA("Must invoke loadWasm first.");let t=[],n=[];for(let r=0,i=e.length;r<i;r++){let i=new s_(e[r]);t[r]=i.createString(sS),n[r]=i.utf8Length}let r=sS.omalloc(4*e.length);sS.HEAPU32.set(t,r/4);let i=sS.omalloc(4*e.length);sS.HEAPU32.set(n,i/4);let s=sS.createOnigScanner(r,i,e.length);for(let n=0,r=e.length;n<r;n++)sS.ofree(t[n]);sS.ofree(i),sS.ofree(r),0===s&&!function(e){throw new sA(e.UTF8ToString(e.getLastOnigError()))}(sS),this._onigBinding=sS,this._ptr=s}dispose(){this._onigBinding.freeOnigScanner(this._ptr)}findNextMatchSync(e,t,n){let r=0;if("number"==typeof n&&(r=n),"string"==typeof e){e=new sO(e);let n=this._findNextMatchSync(e,t,!1,r);return e.dispose(),n}return this._findNextMatchSync(e,t,!1,r)}_findNextMatchSync(e,t,n,r){let i=this._onigBinding,s=i.findNextOnigScannerMatch(this._ptr,e.id,e.ptr,e.utf8Length,e.convertUtf16OffsetToUtf8(t),r);if(0===s)return null;let o=i.HEAPU32,l=s/4,a=o[l++],u=o[l++],h=[];for(let t=0;t<u;t++){let n=e.convertUtf8OffsetToUtf16(o[l++]),r=e.convertUtf8OffsetToUtf16(o[l++]);h[t]={start:n,end:r,length:r-n}}return{index:a,captureIndices:h}}}function sP(e){return t=>WebAssembly.instantiate(e,t)}async function sT(e){if(e){var t;await (t=e,i?i:i=async function e(){sS=await sE(async e=>{let n=t;if("function"==typeof(n=await n)&&(n=await n(e)),"function"==typeof n&&(n=await n(e)),"function"==typeof n.instantiator)n=await n.instantiator(e);else if("function"==typeof n.default)n=await n.default(e);else{var r,i;if(void 0!==n.data)n=n.data;if(r=n,"undefined"!=typeof Response&&r instanceof Response)"function"==typeof WebAssembly.instantiateStreaming?n=await (function(e){return t=>WebAssembly.instantiateStreaming(e,t)})(n)(e):n=await (function(e){return async t=>{let n=await e.arrayBuffer();return WebAssembly.instantiate(n,t)}})(n)(e);else{;if(i=n,"undefined"!=typeof ArrayBuffer&&(i instanceof ArrayBuffer||ArrayBuffer.isView(i))||"undefined"!=typeof Buffer&&Buffer.isBuffer?.(i)||"undefined"!=typeof SharedArrayBuffer&&i instanceof SharedArrayBuffer||"undefined"!=typeof Uint32Array&&i instanceof Uint32Array)n=await sP(n)(e);else n instanceof WebAssembly.Module?n=await sP(n)(e):"default"in n&&n.default instanceof WebAssembly.Module&&(n=await sP(n.default)(e))}}return"instance"in n&&(n=n.instance),"exports"in n&&(n=n.exports),n})}())}return{createScanner:e=>new sF(e),createString:e=>new sO(e)}}function sN(e){}function sB(e){return Array.isArray(e)?function(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=sB(e[n]);return t}(e):"object"==typeof e?function(e){let t={};for(let n in e)t[n]=sB(e[n]);return t}(e):e}function sI(e,...t){return t.forEach(t=>{for(let n in t)e[n]=t[n]}),e}var sM=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,s$=class{static hasCaptures(e){return null!==e&&(sM.lastIndex=0,sM.test(e))}static replaceCaptures(e,t,n){return e.replace(sM,(e,r,i,s)=>{let o=n[parseInt(r||i,10)];if(!o)return e;{let e=t.substring(o.start,o.end);for(;"."===e[0];)e=e.substring(1);switch(s){case"downcase":return e.toLowerCase();case"upcase":return e.toUpperCase();default:return e}}})}};function sL(e,t){return e<t?-1:e>t?1:0}function sR(e,t){if(null===e&&null===t)return 0;if(!e)return -1;if(!t)return 1;let n=e.length,r=t.length;if(n===r){for(let r=0;r<n;r++){let n=sL(e[r],t[r]);if(0!==n)return n}return 0}return n-r}function sj(e){return!!(/^#[0-9a-f]{6}$/i.test(e)||/^#[0-9a-f]{8}$/i.test(e)||/^#[0-9a-f]{3}$/i.test(e)||/^#[0-9a-f]{4}$/i.test(e))||!1}function sq(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&")}var sV=class{constructor(e){this.fn=e,this.cache=new Map}get(e){if(this.cache.has(e))return this.cache.get(e);let t=this.fn(e);return this.cache.set(e,t),t}},sz=class{constructor(e,t,n){this._colorMap=e,this._defaults=t,this._root=n,this._cachedMatchRoot=new sV(e=>this._root.match(e))}static createFromRawTheme(e,t){return this.createFromParsedTheme(function(e){if(!e||!e.settings||!Array.isArray(e.settings))return[];let t=e.settings,n=[],r=0;for(let e=0,i=t.length;e<i;e++){let i,s=t[e];if(!s.settings)continue;if("string"==typeof s.scope){let e=s.scope;i=(e=(e=e.replace(/^[,]+/,"")).replace(/[,]+$/,"")).split(",")}else i=Array.isArray(s.scope)?s.scope:[""];let o=-1;if("string"==typeof s.settings.fontStyle){o=0;let e=s.settings.fontStyle.split(" ");for(let t=0,n=e.length;t<n;t++)switch(e[t]){case"italic":o|=1;break;case"bold":o|=2;break;case"underline":o|=4;break;case"strikethrough":o|=8}}let l=null;"string"==typeof s.settings.foreground&&sj(s.settings.foreground)&&(l=s.settings.foreground);let a=null;"string"==typeof s.settings.background&&sj(s.settings.background)&&(a=s.settings.background);for(let t=0,s=i.length;t<s;t++){let s=i[t].trim().split(" "),u=s[s.length-1],h=null;s.length>1&&(h=s.slice(0,s.length-1)).reverse(),n[r++]=new sW(u,h,e,o,l,a)}}return n}(e),t)}static createFromParsedTheme(e,t){return function(e,t){e.sort((e,t)=>{let n=sL(e.scope,t.scope);return 0!==n||0!==(n=sR(e.parentScopes,t.parentScopes))?n:e.index-t.index});let n=0,r="#000000",i="#ffffff";for(;e.length>=1&&""===e[0].scope;){let t=e.shift();-1!==t.fontStyle&&(n=t.fontStyle),null!==t.foreground&&(r=t.foreground),null!==t.background&&(i=t.background)}let s=new sK(t),o=new sH(n,s.getId(r),s.getId(i)),l=new sY(new sQ(0,null,-1,0,0),[]);for(let t=0,n=e.length;t<n;t++){let n=e[t];l.insert(0,n.scope,n.parentScopes,n.fontStyle,s.getId(n.foreground),s.getId(n.background))}return new sz(s,o,l)}(e,t)}getColorMap(){return this._colorMap.getColorMap()}getDefaults(){return this._defaults}match(e){if(null===e)return this._defaults;let t=e.scopeName,n=this._cachedMatchRoot.get(t).find(t=>(function(e,t){if(0===t.length)return!0;for(let n=0;n<t.length;n++){let r=t[n],i=!1;if(">"===r){if(n===t.length-1)return!1;r=t[++n],i=!0}for(;e&&!function(e,t){return t===e||e.startsWith(t)&&"."===e[t.length]}(e.scopeName,r);){;if(i)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0})(e.parent,t.parentScopes));return n?new sH(n.fontStyle,n.foreground,n.background):null}},sU=class e{constructor(e,t){this.parent=e,this.scopeName=t}static push(t,n){for(let r of n)t=new e(t,r);return t}static from(...t){let n=null;for(let r=0;r<t.length;r++)n=new e(n,t[r]);return n}push(t){return new e(this,t)}getSegments(){let e=this,t=[];for(;e;)t.push(e.scopeName),e=e.parent;return t.reverse(),t}toString(){return this.getSegments().join(" ")}extends(e){return this===e||null!==this.parent&&this.parent.extends(e)}getExtensionIfDefined(e){let t=[],n=this;for(;n&&n!==e;)t.push(n.scopeName),n=n.parent;return n===e?t.reverse():void 0}},sH=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}},sW=class{constructor(e,t,n,r,i,s){this.scope=e,this.parentScopes=t,this.index=n,this.fontStyle=r,this.foreground=i,this.background=s}};var sG=((v=sG||{})[v.NotSet=-1]="NotSet",v[v.None=0]="None",v[v.Italic=1]="Italic",v[v.Bold=2]="Bold",v[v.Underline=4]="Underline",v[v.Strikethrough=8]="Strikethrough",v),sK=class{constructor(e){if(this._lastColorId=0,this._id2color=[],this._color2id=Object.create(null),Array.isArray(e)){this._isFrozen=!0;for(let t=0,n=e.length;t<n;t++)this._color2id[e[t]]=t,this._id2color[t]=e[t]}else this._isFrozen=!1}getId(e){if(null===e)return 0;e=e.toUpperCase();let t=this._color2id[e];if(t)return t;if(this._isFrozen)throw Error(`Missing color in color map - ${e}`);return t=++this._lastColorId,this._color2id[e]=t,this._id2color[t]=e,t}getColorMap(){return this._id2color.slice(0)}},sJ=Object.freeze([]),sQ=class e{constructor(e,t,n,r,i){this.scopeDepth=e,this.parentScopes=t||sJ,this.fontStyle=n,this.foreground=r,this.background=i}clone(){return new e(this.scopeDepth,this.parentScopes,this.fontStyle,this.foreground,this.background)}static cloneArr(e){let t=[];for(let n=0,r=e.length;n<r;n++)t[n]=e[n].clone();return t}acceptOverwrite(e,t,n,r){this.scopeDepth>e?console.log("how did this happen?"):this.scopeDepth=e,-1!==t&&(this.fontStyle=t),0!==n&&(this.foreground=n),0!==r&&(this.background=r)}},sY=class e{constructor(e,t=[],n={}){this._mainRule=e,this._children=n,this._rulesWithParentScopes=t}static _cmpBySpecificity(e,t){if(e.scopeDepth!==t.scopeDepth)return t.scopeDepth-e.scopeDepth;let n=0,r=0;for(;">"===e.parentScopes[n]&&n++,">"===t.parentScopes[r]&&r++,!(n>=e.parentScopes.length)&&!(r>=t.parentScopes.length);){;let i=t.parentScopes[r].length-e.parentScopes[n].length;if(0!==i)return i;n++,r++}return t.parentScopes.length-e.parentScopes.length}match(t){if(""!==t){let e,n,r=t.indexOf(".");if(-1===r?(e=t,n=""):(e=t.substring(0,r),n=t.substring(r+1)),this._children.hasOwnProperty(e))return this._children[e].match(n)}let n=this._rulesWithParentScopes.concat(this._mainRule);return n.sort(e._cmpBySpecificity),n}insert(t,n,r,i,s,o){let l,a,u;if(""===n){this._doInsertHere(t,r,i,s,o);return}let h=n.indexOf(".");-1===h?(l=n,a=""):(l=n.substring(0,h),a=n.substring(h+1)),this._children.hasOwnProperty(l)?u=this._children[l]:(u=new e(this._mainRule.clone(),sQ.cloneArr(this._rulesWithParentScopes)),this._children[l]=u),u.insert(t+1,a,r,i,s,o)}_doInsertHere(e,t,n,r,i){if(null===t){this._mainRule.acceptOverwrite(e,n,r,i);return}for(let s=0,o=this._rulesWithParentScopes.length;s<o;s++){let o=this._rulesWithParentScopes[s];if(0===sR(o.parentScopes,t)){o.acceptOverwrite(e,n,r,i);return}}-1===n&&(n=this._mainRule.fontStyle),0===r&&(r=this._mainRule.foreground),0===i&&(i=this._mainRule.background),this._rulesWithParentScopes.push(new sQ(e,t,n,r,i))}},sZ=class e{static toBinaryStr(e){return e.toString(2).padStart(32,"0")}static print(t){let n=e.getLanguageId(t),r=e.getTokenType(t),i=e.getFontStyle(t),s=e.getForeground(t);console.log({languageId:n,tokenType:r,fontStyle:i,foreground:s,background:e.getBackground(t)})}static getLanguageId(e){return(255&e)>>>0}static getTokenType(e){return(768&e)>>>8}static containsBalancedBrackets(e){return(1024&e)!=0}static getFontStyle(e){return(30720&e)>>>11}static getForeground(e){return(0xff8000&e)>>>15}static getBackground(e){return(0xff000000&e)>>>24}static set(t,n,r,i,s,o,l){let a=e.getLanguageId(t),u=e.getTokenType(t),h=e.containsBalancedBrackets(t)?1:0,c=e.getFontStyle(t),f=e.getForeground(t),d=e.getBackground(t);return 0!==n&&(a=n),8!==r&&(u=function(e){return e}(r)),null!==i&&(h=i?1:0),-1!==s&&(c=s),0!==o&&(f=o),0!==l&&(d=l),(a<<0|u<<8|h<<10|c<<11|f<<15|d<<24)>>>0}};function sX(e,t){let n=[],r=function(e){let t=/([LR]:|[\w\.:][\w\.:\-]*|[\,\|\-\(\)])/g,n=t.exec(e);return{next:()=>{if(!n)return null;let r=n[0];return n=t.exec(e),r}}}(e),i=r.next();for(;null!==i;){let e=0;if(2===i.length&&":"===i.charAt(1)){switch(i.charAt(0)){case"R":e=1;break;case"L":e=-1;break;default:console.log(`Unknown priority ${i} in scope selector`)}i=r.next()}let t=o();if(n.push({matcher:t,priority:e}),","!==i)break;i=r.next()}return n;function s(){if("-"===i){i=r.next();let e=s();return t=>!!e&&!e(t)}if("("===i){i=r.next();let e=function(){let e=[],t=o();for(;t&&(e.push(t),"|"===i||","===i);){do i=r.next();while("|"===i||","===i);t=o()}return t=>e.some(e=>e(t))}();return")"===i&&(i=r.next()),e}if(s0(i)){let e=[];do e.push(i),i=r.next();while(s0(i));return n=>t(e,n)}return null}function o(){let e=[],t=s();for(;t;)e.push(t),t=s();return t=>e.every(e=>e(t))}}function s0(e){return!!e&&!!e.match(/[\w\.:]+/)}function s1(e){"function"==typeof e.dispose&&e.dispose()}var s2=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},s3=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},s5=class{constructor(){this._references=[],this._seenReferenceKeys=new Set,this.visitedRule=new Set}get references(){return this._references}add(e){let t=e.toKey();if(!this._seenReferenceKeys.has(t))this._seenReferenceKeys.add(t),this._references.push(e)}},s8=class{constructor(e,t){this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests=new Set,this.seenPartialScopeRequests=new Set,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new s2(this.initialScopeName)]}processQueue(){let e=this.Q;this.Q=[];let t=new s5;for(let n of e)(function(e,t,n,r){let i=n.lookup(e.scopeName);if(!i){if(e.scopeName===t)throw Error(`No grammar provided for <${t}>`);return}let s=n.lookup(t);e instanceof s2?s6({baseGrammar:s,selfGrammar:i},r):s4(e.ruleName,{baseGrammar:s,selfGrammar:i,repository:i.repository},r);let o=n.injections(e.scopeName);if(o)for(let e of o)r.add(new s2(e))})(n,this.initialScopeName,this.repo,t);for(let e of t.references)if(e instanceof s2){if(this.seenFullScopeRequests.has(e.scopeName))continue;this.seenFullScopeRequests.add(e.scopeName),this.Q.push(e)}else{if(this.seenFullScopeRequests.has(e.scopeName)||this.seenPartialScopeRequests.has(e.toKey()))continue;this.seenPartialScopeRequests.add(e.toKey()),this.Q.push(e)}}};function s4(e,t,n){t.repository&&t.repository[e]&&s9([t.repository[e]],t,n)}function s6(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&s9(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},t),e.selfGrammar.injections&&s9(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},t)}function s9(e,t,n){for(let r of e){if(n.visitedRule.has(r))continue;n.visitedRule.add(r);let e=r.repository?sI({},t.repository,r.repository):t.repository;Array.isArray(r.patterns)&&s9(r.patterns,{...t,repository:e},n);let i=r.include;if(!i)continue;let s=oi(i);switch(s.kind){case 0:s6({...t,selfGrammar:t.baseGrammar},n);break;case 1:s6(t,n);break;case 2:s4(s.ruleName,{...t,repository:e},n);break;case 3:case 4:let o=s.scopeName===t.selfGrammar.scopeName?t.selfGrammar:s.scopeName===t.baseGrammar.scopeName?t.baseGrammar:void 0;if(o){let r={baseGrammar:t.baseGrammar,selfGrammar:o,repository:e};4===s.kind?s4(s.ruleName,r,n):s6(r,n)}else 4===s.kind?n.add(new s3(s.scopeName,s.ruleName)):n.add(new s2(s.scopeName))}}}var s7=class{constructor(){this.kind=0}},oe=class{constructor(){this.kind=1}},ot=class{constructor(e){this.ruleName=e,this.kind=2}},on=class{constructor(e){this.scopeName=e,this.kind=3}},or=class{constructor(e,t){this.scopeName=e,this.ruleName=t,this.kind=4}};function oi(e){if("$base"===e)return new s7;if("$self"===e)return new oe;let t=e.indexOf("#");if(-1===t)return new on(e);if(0===t)return new ot(e.substring(1));{let n=e.substring(0,t);return new or(n,e.substring(t+1))}}var os=/\\(\d+)/,oo=/\\(\d+)/g;Symbol("RuleId");function ol(e){return e}function oa(e){return e}var ou=class{constructor(e,t,n,r){this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=s$.hasCaptures(this._name),this._contentName=r||null,this._contentNameIsCapturing=s$.hasCaptures(this._contentName)}get debugName(){let e=this.$location?`${function e(t){let n=~t.lastIndexOf("/")||~t.lastIndexOf("\\");return 0===n?t:~n==t.length-1?e(t.substring(0,t.length-1)):t.substr(~n+1)}(this.$location.filename)}:${this.$location.line}`:"unknown";return`${this.constructor.name}#${this.id} @ ${e}`}getName(e,t){return this._nameIsCapturing&&null!==this._name&&null!==e&&null!==t?s$.replaceCaptures(this._name,e,t):this._name}getContentName(e,t){return this._contentNameIsCapturing&&null!==this._contentName?s$.replaceCaptures(this._contentName,e,t):this._contentName}},oh=class extends ou{constructor(e,t,n,r,i){super(e,t,n,r),this.retokenizeCapturedWithRuleId=i}dispose(){}collectPatterns(e,t){throw Error("Not supported!")}compile(e,t){throw Error("Not supported!")}compileAG(e,t,n,r){throw Error("Not supported!")}},oc=class extends ou{constructor(e,t,n,r,i){super(e,t,n,null),this._match=new og(r,this.id),this.captures=i,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugMatchRegExp(){return`${this._match.source}`}collectPatterns(e,t){t.push(this._match)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){return!this._cachedCompiledPatterns&&(this._cachedCompiledPatterns=new oy,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},of=class extends ou{constructor(e,t,n,r,i){super(e,t,n,r),this.patterns=i.patterns,this.hasMissingPatterns=i.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}collectPatterns(e,t){for(let n of this.patterns)e.getRule(n).collectPatterns(e,t)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){return!this._cachedCompiledPatterns&&(this._cachedCompiledPatterns=new oy,this.collectPatterns(e,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},od=class extends ou{constructor(e,t,n,r,i,s,o,l,a,u){super(e,t,n,r),this._begin=new og(i,this.id),this.beginCaptures=s,this._end=new og(o||"",-1),this.endHasBackReferences=this._end.hasBackReferences,this.endCaptures=l,this.applyEndPatternLast=a||!1,this.patterns=u.patterns,this.hasMissingPatterns=u.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugEndRegExp(){return`${this._end.source}`}getEndWithResolvedBackReferences(e,t){return this._end.resolveBackReferences(e,t)}collectPatterns(e,t){t.push(this._begin)}compile(e,t){return this._getCachedCompiledPatterns(e,t).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e,t).compileAG(e,n,r)}_getCachedCompiledPatterns(e,t){if(!this._cachedCompiledPatterns){for(let t of(this._cachedCompiledPatterns=new oy,this.patterns))e.getRule(t).collectPatterns(e,this._cachedCompiledPatterns);this.applyEndPatternLast?this._cachedCompiledPatterns.push(this._end.hasBackReferences?this._end.clone():this._end):this._cachedCompiledPatterns.unshift(this._end.hasBackReferences?this._end.clone():this._end)}return this._end.hasBackReferences&&(this.applyEndPatternLast?this._cachedCompiledPatterns.setSource(this._cachedCompiledPatterns.length()-1,t):this._cachedCompiledPatterns.setSource(0,t)),this._cachedCompiledPatterns}},op=class extends ou{constructor(e,t,n,r,i,s,o,l,a){super(e,t,n,r),this._begin=new og(i,this.id),this.beginCaptures=s,this.whileCaptures=l,this._while=new og(o,-2),this.whileHasBackReferences=this._while.hasBackReferences,this.patterns=a.patterns,this.hasMissingPatterns=a.hasMissingPatterns,this._cachedCompiledPatterns=null,this._cachedCompiledWhilePatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null),this._cachedCompiledWhilePatterns&&(this._cachedCompiledWhilePatterns.dispose(),this._cachedCompiledWhilePatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugWhileRegExp(){return`${this._while.source}`}getWhileWithResolvedBackReferences(e,t){return this._while.resolveBackReferences(e,t)}collectPatterns(e,t){t.push(this._begin)}compile(e,t){return this._getCachedCompiledPatterns(e).compile(e)}compileAG(e,t,n,r){return this._getCachedCompiledPatterns(e).compileAG(e,n,r)}_getCachedCompiledPatterns(e){if(!this._cachedCompiledPatterns)for(let t of(this._cachedCompiledPatterns=new oy,this.patterns))e.getRule(t).collectPatterns(e,this._cachedCompiledPatterns);return this._cachedCompiledPatterns}compileWhile(e,t){return this._getCachedCompiledWhilePatterns(e,t).compile(e)}compileWhileAG(e,t,n,r){return this._getCachedCompiledWhilePatterns(e,t).compileAG(e,n,r)}_getCachedCompiledWhilePatterns(e,t){return!this._cachedCompiledWhilePatterns&&(this._cachedCompiledWhilePatterns=new oy,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,t||""),this._cachedCompiledWhilePatterns}},om=class e{static createCaptureRule(e,t,n,r,i){return e.registerRule(e=>new oh(t,e,n,r,i))}static getCompiledRuleId(t,n,r){return!t.id&&n.registerRule(i=>{if(t.id=i,t.match)return new oc(t.$vscodeTextmateLocation,t.id,t.name,t.match,e._compileCaptures(t.captures,n,r));if(void 0===t.begin){t.repository&&(r=sI({},r,t.repository));let i=t.patterns;return void 0===i&&t.include&&(i=[{include:t.include}]),new of(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,e._compilePatterns(i,n,r))}return t.while?new op(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,e._compileCaptures(t.beginCaptures||t.captures,n,r),t.while,e._compileCaptures(t.whileCaptures||t.captures,n,r),e._compilePatterns(t.patterns,n,r)):new od(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,e._compileCaptures(t.beginCaptures||t.captures,n,r),t.end,e._compileCaptures(t.endCaptures||t.captures,n,r),t.applyEndPatternLast,e._compilePatterns(t.patterns,n,r))}),t.id}static _compileCaptures(t,n,r){let i=[];if(t){let s=0;for(let e in t){if("$vscodeTextmateLocation"===e)continue;let t=parseInt(e,10);t>s&&(s=t)}for(let e=0;e<=s;e++)i[e]=null;for(let s in t){if("$vscodeTextmateLocation"===s)continue;let o=parseInt(s,10),l=0;t[s].patterns&&(l=e.getCompiledRuleId(t[s],n,r)),i[o]=e.createCaptureRule(n,t[s].$vscodeTextmateLocation,t[s].name,t[s].contentName,l)}}return i}static _compilePatterns(t,n,r){let i=[];if(t)for(let s=0,o=t.length;s<o;s++){let o=t[s],l=-1;if(o.include){let t=oi(o.include);switch(t.kind){case 0:case 1:l=e.getCompiledRuleId(r[o.include],n,r);break;case 2:let i=r[t.ruleName];i&&(l=e.getCompiledRuleId(i,n,r));break;case 3:case 4:let s=t.scopeName,a=4===t.kind?t.ruleName:null,u=n.getExternalGrammar(s,r);if(u){if(a){let t=u.repository[a];t&&(l=e.getCompiledRuleId(t,n,u.repository))}else l=e.getCompiledRuleId(u.repository.$self,n,u.repository)}}}else l=e.getCompiledRuleId(o,n,r);if(-1!==l){let e=n.getRule(l),t=!1;if((e instanceof of||e instanceof od||e instanceof op)&&e.hasMissingPatterns&&0===e.patterns.length&&(t=!0),t)continue;i.push(l)}}return{patterns:i,hasMissingPatterns:(t?t.length:0)!==i.length}}},og=class e{constructor(e,t){if(e){let t=e.length,n=0,r=[],i=!1;for(let s=0;s<t;s++)if("\\"===e.charAt(s)&&s+1<t){let t=e.charAt(s+1);"z"===t?(r.push(e.substring(n,s)),r.push("$(?!\\n)(?<!\\n)"),n=s+2):("A"===t||"G"===t)&&(i=!0),s++}this.hasAnchor=i,0===n?this.source=e:(r.push(e.substring(n,t)),this.source=r.join(""))}else this.hasAnchor=!1,this.source=e;this.hasAnchor?this._anchorCache=this._buildAnchorCache():this._anchorCache=null,this.ruleId=t,this.hasBackReferences=os.test(this.source)}clone(){return new e(this.source,this.ruleId)}setSource(e){if(this.source!==e)this.source=e,this.hasAnchor&&(this._anchorCache=this._buildAnchorCache())}resolveBackReferences(e,t){let n=t.map(t=>e.substring(t.start,t.end));return oo.lastIndex=0,this.source.replace(oo,(e,t)=>sq(n[parseInt(t,10)]||""))}_buildAnchorCache(){let e,t,n,r,i=[],s=[],o=[],l=[];for(e=0,t=this.source.length;e<t;e++)n=this.source.charAt(e),i[e]=n,s[e]=n,o[e]=n,l[e]=n,"\\"===n&&e+1<t&&("A"===(r=this.source.charAt(e+1))?(i[e+1]="",s[e+1]="",o[e+1]="A",l[e+1]="A"):"G"===r?(i[e+1]="",s[e+1]="G",o[e+1]="",l[e+1]="G"):(i[e+1]=r,s[e+1]=r,o[e+1]=r,l[e+1]=r),e++);return{A0_G0:i.join(""),A0_G1:s.join(""),A1_G0:o.join(""),A1_G1:l.join("")}}resolveAnchors(e,t){if(!this.hasAnchor||!this._anchorCache)return this.source;if(e)return t?this._anchorCache.A1_G1:this._anchorCache.A1_G0;return t?this._anchorCache.A0_G1:this._anchorCache.A0_G0}},oy=class{constructor(){this._items=[],this._hasAnchors=!1,this._cached=null,this._anchorCache={A0_G0:null,A0_G1:null,A1_G0:null,A1_G1:null}}dispose(){this._disposeCaches()}_disposeCaches(){this._cached&&(this._cached.dispose(),this._cached=null),this._anchorCache.A0_G0&&(this._anchorCache.A0_G0.dispose(),this._anchorCache.A0_G0=null),this._anchorCache.A0_G1&&(this._anchorCache.A0_G1.dispose(),this._anchorCache.A0_G1=null),this._anchorCache.A1_G0&&(this._anchorCache.A1_G0.dispose(),this._anchorCache.A1_G0=null),this._anchorCache.A1_G1&&(this._anchorCache.A1_G1.dispose(),this._anchorCache.A1_G1=null)}push(e){this._items.push(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}unshift(e){this._items.unshift(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}length(){return this._items.length}setSource(e,t){this._items[e].source!==t&&(this._disposeCaches(),this._items[e].setSource(t))}compile(e){if(!this._cached){let t=this._items.map(e=>e.source);this._cached=new ob(e,t,this._items.map(e=>e.ruleId))}return this._cached}compileAG(e,t,n){if(!this._hasAnchors)return this.compile(e);if(t)return n?(!this._anchorCache.A1_G1&&(this._anchorCache.A1_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G1):(!this._anchorCache.A1_G0&&(this._anchorCache.A1_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G0);return n?(!this._anchorCache.A0_G1&&(this._anchorCache.A0_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G1):(!this._anchorCache.A0_G0&&(this._anchorCache.A0_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G0)}_resolveAnchors(e,t,n){return new ob(e,this._items.map(e=>e.resolveAnchors(t,n)),this._items.map(e=>e.ruleId))}},ob=class{constructor(e,t,n){this.regExps=t,this.rules=n,this.scanner=e.createOnigScanner(t)}dispose(){"function"==typeof this.scanner.dispose&&this.scanner.dispose()}toString(){let e=[];for(let t=0,n=this.rules.length;t<n;t++)e.push(" - "+this.rules[t]+": "+this.regExps[t]);return e.join("\n")}findNextMatchSync(e,t,n){let r=this.scanner.findNextMatchSync(e,t,n);return r?{ruleId:this.rules[r.index],captureIndices:r.captureIndices}:null}},ov=class{constructor(e,t){this.languageId=e,this.tokenType=t}},ok=class e{constructor(e,t){this._getBasicScopeAttributes=new sV(e=>{let t=this._scopeToLanguage(e);return new ov(t,this._toStandardTokenType(e))}),this._defaultAttributes=new ov(e,8),this._embeddedLanguagesMatcher=new ow(Object.entries(t||{}))}getDefaultAttributes(){return this._defaultAttributes}getBasicScopeAttributes(t){return null===t?e._NULL_SCOPE_METADATA:this._getBasicScopeAttributes.get(t)}_scopeToLanguage(e){return this._embeddedLanguagesMatcher.match(e)||0}_toStandardTokenType(t){let n=t.match(e.STANDARD_TOKEN_TYPE_REGEXP);if(!n)return 8;switch(n[1]){case"comment":return 1;case"string":return 2;case"regex":return 3;case"meta.embedded":return 0}throw Error("Unexpected match for standard token type!")}};ok._NULL_SCOPE_METADATA=new ov(0,0),ok.STANDARD_TOKEN_TYPE_REGEXP=/\b(comment|string|regex|meta\.embedded)\b/;var ow=class{constructor(e){if(0===e.length)this.values=null,this.scopesRegExp=null;else{this.values=new Map(e);let t=e.map(([e,t])=>sq(e));t.sort(),t.reverse(),this.scopesRegExp=RegExp(`^((${t.join(")|(")}))($|\\.)`,"")}}match(e){if(!this.scopesRegExp)return;let t=e.match(this.scopesRegExp);if(!!t)return this.values.get(t[1])}};"undefined"!=typeof process&&process.env.VSCODE_TEXTMATE_DEBUG;var oD=class{constructor(e,t){this.stack=e,this.stoppedEarly=t}};function oA(e,t,n,r,i,s,o,l){let a=t.content.length,u=!1,h=-1;if(o){let o=function(e,t,n,r,i,s){let o=i.beginRuleCapturedEOL?0:-1,l=[];for(let t=i;t;t=t.pop()){let n=t.getRule(e);n instanceof op&&l.push({rule:n,stack:t})}for(let a=l.pop();a;a=l.pop()){let{ruleScanner:l,findOptions:u}=function(e,t,n,r,i){return{ruleScanner:e.compileWhileAG(t,n,r,i),findOptions:0}}(a.rule,e,a.stack.endRule,n,r===o),h=l.findNextMatchSync(t,r,u);if(h){if(-2!==h.ruleId){i=a.stack.pop();break}h.captureIndices&&h.captureIndices.length&&(s.produce(a.stack,h.captureIndices[0].start),oE(e,t,n,a.stack,s,a.rule.whileCaptures,h.captureIndices),s.produce(a.stack,h.captureIndices[0].end),o=h.captureIndices[0].end,h.captureIndices[0].end>r&&(r=h.captureIndices[0].end,n=!1))}else{i=a.stack.pop();break}}return{stack:i,linePos:r,anchorPosition:o,isFirstLine:n}}(e,t,n,r,i,s);i=o.stack,r=o.linePos,n=o.isFirstLine,h=o.anchorPosition}let c=Date.now();for(;!u;){if(0!==l&&Date.now()-c>l)return new oD(i,!0);(function(){let o=function(e,t,n,r,i,s){let o=function(e,t,n,r,i,s){let{ruleScanner:o,findOptions:l}=ox(i.getRule(e),e,i.endRule,n,r===s),a=o.findNextMatchSync(t,r,l);return a?{captureIndices:a.captureIndices,matchedRuleId:a.ruleId}:null}(e,t,n,r,i,s),l=e.getInjections();if(0===l.length)return o;let a=function(e,t,n,r,i,s,o){let l,a=Number.MAX_VALUE,u=null,h=0,c=s.contentNameScopesList.getScopeNames();for(let s=0,f=e.length;s<f;s++){let f=e[s];if(!f.matcher(c))continue;let{ruleScanner:d,findOptions:p}=ox(t.getRule(f.ruleId),t,null,r,i===o),m=d.findNextMatchSync(n,i,p);if(!m)continue;let g=m.captureIndices[0].start;if(!(g>=a)){if(a=g,u=m.captureIndices,l=m.ruleId,h=f.priority,a===i)break}}return u?{priorityMatch:-1===h,captureIndices:u,matchedRuleId:l}:null}(l,e,t,n,r,i,s);if(!a)return o;if(!o)return a;let u=o.captureIndices[0].start,h=a.captureIndices[0].start;return h<u||a.priorityMatch&&h===u?a:o}(e,t,n,r,i,h);if(!o){s.produce(i,a),u=!0;return}let l=o.captureIndices,c=o.matchedRuleId,f=!!l&&l.length>0&&l[0].end>r;if(-1===c){let o=i.getRule(e);s.produce(i,l[0].start),i=i.withContentNameScopesList(i.nameScopesList),oE(e,t,n,i,s,o.endCaptures,l),s.produce(i,l[0].end);let c=i;if(i=i.parent,h=c.getAnchorPos(),!f&&c.getEnterPos()===r){i=c,s.produce(i,a),u=!0;return}}else{let o=e.getRule(c);s.produce(i,l[0].start);let d=i,p=o.getName(t.content,l),m=i.contentNameScopesList.pushAttributed(p,e);if(i=i.push(c,r,h,l[0].end===a,null,m,m),o instanceof od){oE(e,t,n,i,s,o.beginCaptures,l),s.produce(i,l[0].end),h=l[0].end;let r=o.getContentName(t.content,l),c=m.pushAttributed(r,e);if(i=i.withContentNameScopesList(c),o.endHasBackReferences&&(i=i.withEndRule(o.getEndWithResolvedBackReferences(t.content,l))),!f&&d.hasSameRuleAs(i)){i=i.pop(),s.produce(i,a),u=!0;return}}else if(o instanceof op){oE(e,t,n,i,s,o.beginCaptures,l),s.produce(i,l[0].end),h=l[0].end;let r=o.getContentName(t.content,l),c=m.pushAttributed(r,e);if(i=i.withContentNameScopesList(c),o.whileHasBackReferences&&(i=i.withEndRule(o.getWhileWithResolvedBackReferences(t.content,l))),!f&&d.hasSameRuleAs(i)){i=i.pop(),s.produce(i,a),u=!0;return}}else if(oE(e,t,n,i,s,o.captures,l),s.produce(i,l[0].end),i=i.pop(),!f){i=i.safePop(),s.produce(i,a),u=!0;return}}l[0].end>r&&(r=l[0].end,n=!1)})()}return new oD(i,!1)}function ox(e,t,n,r,i){return{ruleScanner:e.compileAG(t,n,r,i),findOptions:0}}function oC(e,t){let n=0;return!e&&(n|=1),!t&&(n|=4),n}function oE(e,t,n,r,i,s,o){if(0===s.length)return;let l=t.content,a=Math.min(s.length,o.length),u=[],h=o[0].end;for(let t=0;t<a;t++){let a=s[t];if(null===a)continue;let c=o[t];if(0===c.length)continue;if(c.start>h)break;for(;u.length>0&&u[u.length-1].endPos<=c.start;)i.produceFromScopes(u[u.length-1].scopes,u[u.length-1].endPos),u.pop();if(u.length>0?i.produceFromScopes(u[u.length-1].scopes,c.start):i.produce(r,c.start),a.retokenizeCapturedWithRuleId){let t=a.getName(l,o),s=r.contentNameScopesList.pushAttributed(t,e),u=a.getContentName(l,o),h=s.pushAttributed(u,e),f=r.push(a.retokenizeCapturedWithRuleId,c.start,-1,!1,null,s,h),d=e.createOnigString(l.substring(0,c.end));oA(e,d,n&&0===c.start,c.start,f,i,!1,0),s1(d);continue}let f=a.getName(l,o);if(null!==f){let t=(u.length>0?u[u.length-1].scopes:r.contentNameScopesList).pushAttributed(f,e);u.push(new oS(t,c.end))}}for(;u.length>0;)i.produceFromScopes(u[u.length-1].scopes,u[u.length-1].endPos),u.pop()}var oS=class{constructor(e,t){this.scopes=e,this.endPos=t}};function o_(e,t,n,r,i){let s=sX(t,oO),o=om.getCompiledRuleId(n,r,i.repository);for(let n of s)e.push({debugSelector:t,matcher:n.matcher,ruleId:o,grammar:i,priority:n.priority})}function oO(e,t){if(t.length<e.length)return!1;let n=0;return e.every(e=>{for(let r=n;r<t.length;r++)if(function(e,t){if(!e)return!1;if(e===t)return!0;let n=t.length;return e.length>n&&e.substr(0,n)===t&&"."===e[n]}(t[r],e))return n=r+1,!0;return!1})}var oF=class{constructor(e,t,n,r,i,s,o,l){if(this._rootScopeName=e,this.balancedBracketSelectors=s,this._onigLib=l,this._basicScopeAttributesProvider=new ok(n,r),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=o,this._grammar=oP(t,null),this._injections=null,this._tokenTypeMatchers=[],i)for(let e of Object.keys(i))for(let t of sX(e,oO))this._tokenTypeMatchers.push({matcher:t.matcher,type:i[e]})}get themeProvider(){return this._grammarRepository}dispose(){for(let e of this._ruleId2desc)e&&e.dispose()}createOnigScanner(e){return this._onigLib.createOnigScanner(e)}createOnigString(e){return this._onigLib.createOnigString(e)}getMetadataForScope(e){return this._basicScopeAttributesProvider.getBasicScopeAttributes(e)}_collectInjections(){let e=[],t=this._rootScopeName,n=({lookup:e=>e===this._rootScopeName?this._grammar:this.getExternalGrammar(e),injections:e=>this._grammarRepository.injections(e)}).lookup(t);if(n){let r=n.injections;if(r)for(let t in r)o_(e,t,r[t],this,n);let i=this._grammarRepository.injections(t);i&&i.forEach(t=>{let n=this.getExternalGrammar(t);if(n){let t=n.injectionSelector;t&&o_(e,t,n,this,n)}})}return e.sort((e,t)=>e.priority-t.priority),e}getInjections(){return null===this._injections&&(this._injections=this._collectInjections()),this._injections}registerRule(e){let t=++this._lastRuleId,n=e(t);return this._ruleId2desc[t]=n,n}getRule(e){return this._ruleId2desc[e]}getExternalGrammar(e,t){if(this._includedGrammars[e])return this._includedGrammars[e];if(this._grammarRepository){let n=this._grammarRepository.lookup(e);if(n)return this._includedGrammars[e]=oP(n,t&&t.$base),this._includedGrammars[e]}}tokenizeLine(e,t,n=0){let r=this._tokenize(e,t,!1,n);return{tokens:r.lineTokens.getResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}tokenizeLine2(e,t,n=0){let r=this._tokenize(e,t,!0,n);return{tokens:r.lineTokens.getBinaryResult(r.ruleStack,r.lineLength),ruleStack:r.ruleStack,stoppedEarly:r.stoppedEarly}}_tokenize(e,t,n,r){let i;if(-1===this._rootId&&(this._rootId=om.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections()),t&&t!==oB.NULL)i=!1,t.reset();else{let e;i=!0;let n=this._basicScopeAttributesProvider.getDefaultAttributes(),r=this.themeProvider.getDefaults(),s=sZ.set(0,n.languageId,n.tokenType,null,r.fontStyle,r.foregroundId,r.backgroundId),o=this.getRule(this._rootId).getName(null,null);e=o?oT.createRootAndLookUpScopeName(o,s,this):oT.createRoot("unknown",s),t=new oB(null,this._rootId,-1,-1,!1,null,e,e)}e+="\n";let s=this.createOnigString(e),o=s.content.length,l=new oM(n,e,this._tokenTypeMatchers,this.balancedBracketSelectors),a=oA(this,s,i,0,t,l,!0,r);return s1(s),{lineLength:o,lineTokens:l,ruleStack:a.stack,stoppedEarly:a.stoppedEarly}}};function oP(e,t){return(e=sB(e)).repository=e.repository||{},e.repository.$self={$vscodeTextmateLocation:e.$vscodeTextmateLocation,patterns:e.patterns,name:e.scopeName},e.repository.$base=t||e.repository.$self,e}var oT=class e{constructor(e,t,n){this.parent=e,this.scopePath=t,this.tokenAttributes=n}static fromExtension(t,n){let r=t,i=t?.scopePath??null;for(let t of n)r=new e(r,i=sU.push(i,t.scopeNames),t.encodedTokenAttributes);return r}static createRoot(t,n){return new e(null,new sU(null,t),n)}static createRootAndLookUpScopeName(t,n,r){let i=r.getMetadataForScope(t),s=new sU(null,t),o=r.themeProvider.themeMatch(s),l=e.mergeAttributes(n,i,o);return new e(null,s,l)}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(" ")}equals(t){return e.equals(this,t)}static equals(e,t){for(;;){if(e===t||!e&&!t)return!0;if(!e||!t||e.scopeName!==t.scopeName||e.tokenAttributes!==t.tokenAttributes)return!1;e=e.parent,t=t.parent}}static mergeAttributes(e,t,n){let r=-1,i=0,s=0;return null!==n&&(r=n.fontStyle,i=n.foregroundId,s=n.backgroundId),sZ.set(e,t.languageId,t.tokenType,null,r,i,s)}pushAttributed(t,n){if(null===t)return this;if(-1===t.indexOf(" "))return e._pushAttributed(this,t,n);let r=t.split(/ /g),i=this;for(let t of r)i=e._pushAttributed(i,t,n);return i}static _pushAttributed(t,n,r){let i=r.getMetadataForScope(n),s=t.scopePath.push(n),o=r.themeProvider.themeMatch(s),l=e.mergeAttributes(t.tokenAttributes,i,o);return new e(t,s,l)}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(e){let t=[],n=this;for(;n&&n!==e;)t.push({encodedTokenAttributes:n.tokenAttributes,scopeNames:n.scopePath.getExtensionIfDefined(n.parent?.scopePath??null)}),n=n.parent;return n===e?t.reverse():void 0}},oN=class e{constructor(e,t,n,r,i,s,o,l){this.parent=e,this.ruleId=t,this.beginRuleCapturedEOL=i,this.endRule=s,this.nameScopesList=o,this.contentNameScopesList=l,this._stackElementBrand=void 0,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=n,this._anchorPos=r}equals(t){return null!==t&&e._equals(this,t)}static _equals(e,t){return e===t||!!this._structuralEquals(e,t)&&oT.equals(e.contentNameScopesList,t.contentNameScopesList)}static _structuralEquals(e,t){for(;;){if(e===t||!e&&!t)return!0;if(!e||!t||e.depth!==t.depth||e.ruleId!==t.ruleId||e.endRule!==t.endRule)return!1;e=e.parent,t=t.parent}}clone(){return this}static _reset(e){for(;e;)e._enterPos=-1,e._anchorPos=-1,e=e.parent}reset(){e._reset(this)}pop(){return this.parent}safePop(){return this.parent?this.parent:this}push(t,n,r,i,s,o,l){return new e(this,t,n,r,i,s,o,l)}getEnterPos(){return this._enterPos}getAnchorPos(){return this._anchorPos}getRule(e){return e.getRule(this.ruleId)}toString(){let e=[];return this._writeString(e,0),"["+e.join(",")+"]"}_writeString(e,t){return this.parent&&(t=this.parent._writeString(e,t)),e[t++]=`(${this.ruleId}, ${this.nameScopesList?.toString()}, ${this.contentNameScopesList?.toString()})`,t}withContentNameScopesList(e){return this.contentNameScopesList===e?this:this.parent.push(this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,this.endRule,this.nameScopesList,e)}withEndRule(t){return this.endRule===t?this:new e(this.parent,this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,t,this.nameScopesList,this.contentNameScopesList)}hasSameRuleAs(e){let t=this;for(;t&&t._enterPos===e._enterPos;){if(t.ruleId===e.ruleId)return!0;t=t.parent}return!1}toStateStackFrame(){return{ruleId:this.ruleId,beginRuleCapturedEOL:this.beginRuleCapturedEOL,endRule:this.endRule,nameScopesList:this.nameScopesList?.getExtensionIfDefined(this.parent?.nameScopesList??null)??[],contentNameScopesList:this.contentNameScopesList?.getExtensionIfDefined(this.nameScopesList)??[]}}static pushFrame(t,n){let r=oT.fromExtension(t?.nameScopesList??null,n.nameScopesList);return new e(t,n.ruleId,n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,r,oT.fromExtension(r,n.contentNameScopesList))}};oN.NULL=new oN(null,0,0,0,!1,null,null,null);var oB=oN,oI=class{constructor(e,t){this.allowAny=!1,this.balancedBracketScopes=e.flatMap(e=>"*"===e?(this.allowAny=!0,[]):sX(e,oO).map(e=>e.matcher)),this.unbalancedBracketScopes=t.flatMap(e=>sX(e,oO).map(e=>e.matcher))}get matchesAlways(){return this.allowAny&&0===this.unbalancedBracketScopes.length}get matchesNever(){return 0===this.balancedBracketScopes.length&&!this.allowAny}match(e){for(let t of this.unbalancedBracketScopes)if(t(e))return!1;for(let t of this.balancedBracketScopes)if(t(e))return!0;return this.allowAny}},oM=class{constructor(e,t,n,r){this.balancedBracketSelectors=r,this._emitBinaryTokens=e,this._tokenTypeOverrides=n;this._lineText=null,this._tokens=[],this._binaryTokens=[],this._lastTokenEndIndex=0}produce(e,t){this.produceFromScopes(e.contentNameScopesList,t)}produceFromScopes(e,t){if(this._lastTokenEndIndex>=t)return;if(this._emitBinaryTokens){let n=e?.tokenAttributes??0,r=!1;if(this.balancedBracketSelectors?.matchesAlways&&(r=!0),this._tokenTypeOverrides.length>0||this.balancedBracketSelectors&&!this.balancedBracketSelectors.matchesAlways&&!this.balancedBracketSelectors.matchesNever){let t=e?.getScopeNames()??[];for(let e of this._tokenTypeOverrides)if(e.matcher(t))n=sZ.set(n,0,e.type,null,-1,0,0);this.balancedBracketSelectors&&(r=this.balancedBracketSelectors.match(t))}if(r&&(n=sZ.set(n,0,8,r,-1,0,0)),this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-1]===n){this._lastTokenEndIndex=t;return}this._binaryTokens.push(this._lastTokenEndIndex),this._binaryTokens.push(n),this._lastTokenEndIndex=t;return}let n=e?.getScopeNames()??[];this._tokens.push({startIndex:this._lastTokenEndIndex,endIndex:t,scopes:n}),this._lastTokenEndIndex=t}getResult(e,t){return this._tokens.length>0&&this._tokens[this._tokens.length-1].startIndex===t-1&&this._tokens.pop(),0===this._tokens.length&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._tokens[this._tokens.length-1].startIndex=0),this._tokens}getBinaryResult(e,t){this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-2]===t-1&&(this._binaryTokens.pop(),this._binaryTokens.pop()),0===this._binaryTokens.length&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._binaryTokens[this._binaryTokens.length-2]=0);let n=new Uint32Array(this._binaryTokens.length);for(let e=0,t=this._binaryTokens.length;e<t;e++)n[e]=this._binaryTokens[e];return n}},o$=class{constructor(e,t){this._onigLib=t,this._grammars=new Map,this._rawGrammars=new Map,this._injectionGrammars=new Map,this._theme=e}dispose(){for(let e of this._grammars.values())e.dispose()}setTheme(e){this._theme=e}getColorMap(){return this._theme.getColorMap()}addGrammar(e,t){this._rawGrammars.set(e.scopeName,e),t&&this._injectionGrammars.set(e.scopeName,t)}lookup(e){return this._rawGrammars.get(e)}injections(e){return this._injectionGrammars.get(e)}getDefaults(){return this._theme.getDefaults()}themeMatch(e){return this._theme.match(e)}grammarForScopeName(e,t,n,r,i){if(!this._grammars.has(e)){var s,o,l,a,u,h,c;let f=this._rawGrammars.get(e);if(!f)return null;this._grammars.set(e,(s=e,o=f,l=t,a=n,u=r,h=i,c=this,new oF(s,o,l,a,u,h,c,this._onigLib)))}return this._grammars.get(e)}},oL=class{constructor(e){this._options=e,this._syncRegistry=new o$(sz.createFromRawTheme(e.theme,e.colorMap),e.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(e,t){this._syncRegistry.setTheme(sz.createFromRawTheme(e,t))}getColorMap(){return this._syncRegistry.getColorMap()}loadGrammarWithEmbeddedLanguages(e,t,n){return this.loadGrammarWithConfiguration(e,t,{embeddedLanguages:n})}loadGrammarWithConfiguration(e,t,n){return this._loadGrammar(e,t,n.embeddedLanguages,n.tokenTypes,new oI(n.balancedBracketSelectors||[],n.unbalancedBracketSelectors||[]))}loadGrammar(e){return this._loadGrammar(e,0,null,null,null)}_loadGrammar(e,t,n,r,i){let s=new s8(this._syncRegistry,e);for(;s.Q.length>0;)s.Q.map(e=>this._loadSingleGrammar(e.scopeName)),s.processQueue();return this._grammarForScopeName(e,t,n,r,i)}_loadSingleGrammar(e){!this._ensureGrammarCache.has(e)&&(this._doLoadSingleGrammar(e),this._ensureGrammarCache.set(e,!0))}_doLoadSingleGrammar(e){let t=this._options.loadGrammar(e);if(t){let n="function"==typeof this._options.getInjections?this._options.getInjections(e):void 0;this._syncRegistry.addGrammar(t,n)}}addGrammar(e,t=[],n=0,r=null){return this._syncRegistry.addGrammar(e,t),this._grammarForScopeName(e.scopeName,n,r)}_grammarForScopeName(e,t=0,n=null,r=null,i=null){return this._syncRegistry.grammarForScopeName(e,t,n,r,i)}},oR=oB.NULL;let oj=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];class oq{constructor(e,t,n){this.property=e,this.normal=t,n&&(this.space=n)}}function oV(e,t){let n={},r={},i=-1;for(;++i<e.length;)Object.assign(n,e[i].property),Object.assign(r,e[i].normal);return new oq(n,r,t)}function oz(e){return e.toLowerCase()}oq.prototype.property={},oq.prototype.normal={},oq.prototype.space=null;class oU{constructor(e,t){this.property=e,this.attribute=t}}oU.prototype.space=null,oU.prototype.boolean=!1,oU.prototype.booleanish=!1,oU.prototype.overloadedBoolean=!1,oU.prototype.number=!1,oU.prototype.commaSeparated=!1,oU.prototype.spaceSeparated=!1,oU.prototype.commaOrSpaceSeparated=!1,oU.prototype.mustUseProperty=!1,oU.prototype.defined=!1;let oH=0,oW=oX(),oG=oX(),oK=oX(),oJ=oX(),oQ=oX(),oY=oX(),oZ=oX();function oX(){return 2**++oH}let o0=Object.keys(M);class o1 extends oU{constructor(e,t,n,r){let i=-1;if(super(e,t),function(e,t,n){n&&(e[t]=n)}(this,"space",r),"number"==typeof n)for(;++i<o0.length;){let e=o0[i];(function(e,t,n){n&&(e[t]=n)})(this,o0[i],(n&M[e])===M[e])}}}function o2(e,t,n){n&&(e[t]=n)}o1.prototype.defined=!0;let o3={}.hasOwnProperty;function o5(e){let t;let n={},r={};for(t in e.properties)if(o3.call(e.properties,t)){let i=e.properties[t],s=new o1(t,e.transform(e.attributes||{},t),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(t)&&(s.mustUseProperty=!0),n[t]=s,r[oz(t)]=t,r[oz(s.attribute)]=t}return new oq(n,r,e.space)}let o8=o5({space:"xlink",transform:(e,t)=>"xlink:"+t.slice(5).toLowerCase(),properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),o4=o5({space:"xml",transform:(e,t)=>"xml:"+t.slice(3).toLowerCase(),properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function o6(e,t){return t in e?e[t]:t}function o9(e,t){return o6(e,t.toLowerCase())}let o7=o5({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:o9,properties:{xmlns:null,xmlnsXLink:null}}),le=o5({transform:(e,t)=>"role"===t?t:"aria-"+t.slice(4).toLowerCase(),properties:{ariaActiveDescendant:null,ariaAtomic:oG,ariaAutoComplete:null,ariaBusy:oG,ariaChecked:oG,ariaColCount:oJ,ariaColIndex:oJ,ariaColSpan:oJ,ariaControls:oQ,ariaCurrent:null,ariaDescribedBy:oQ,ariaDetails:null,ariaDisabled:oG,ariaDropEffect:oQ,ariaErrorMessage:null,ariaExpanded:oG,ariaFlowTo:oQ,ariaGrabbed:oG,ariaHasPopup:null,ariaHidden:oG,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:oQ,ariaLevel:oJ,ariaLive:null,ariaModal:oG,ariaMultiLine:oG,ariaMultiSelectable:oG,ariaOrientation:null,ariaOwns:oQ,ariaPlaceholder:null,ariaPosInSet:oJ,ariaPressed:oG,ariaReadOnly:oG,ariaRelevant:null,ariaRequired:oG,ariaRoleDescription:oQ,ariaRowCount:oJ,ariaRowIndex:oJ,ariaRowSpan:oJ,ariaSelected:oG,ariaSetSize:oJ,ariaSort:null,ariaValueMax:oJ,ariaValueMin:oJ,ariaValueNow:oJ,ariaValueText:null,role:null}}),lt=o5({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:o9,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:oY,acceptCharset:oQ,accessKey:oQ,action:null,allow:null,allowFullScreen:oW,allowPaymentRequest:oW,allowUserMedia:oW,alt:null,as:null,async:oW,autoCapitalize:null,autoComplete:oQ,autoFocus:oW,autoPlay:oW,blocking:oQ,capture:null,charSet:null,checked:oW,cite:null,className:oQ,cols:oJ,colSpan:null,content:null,contentEditable:oG,controls:oW,controlsList:oQ,coords:oJ|oY,crossOrigin:null,data:null,dateTime:null,decoding:null,default:oW,defer:oW,dir:null,dirName:null,disabled:oW,download:oK,draggable:oG,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:oW,formTarget:null,headers:oQ,height:oJ,hidden:oW,high:oJ,href:null,hrefLang:null,htmlFor:oQ,httpEquiv:oQ,id:null,imageSizes:null,imageSrcSet:null,inert:oW,inputMode:null,integrity:null,is:null,isMap:oW,itemId:null,itemProp:oQ,itemRef:oQ,itemScope:oW,itemType:oQ,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:oW,low:oJ,manifest:null,max:null,maxLength:oJ,media:null,method:null,min:null,minLength:oJ,multiple:oW,muted:oW,name:null,nonce:null,noModule:oW,noValidate:oW,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:oW,optimum:oJ,pattern:null,ping:oQ,placeholder:null,playsInline:oW,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:oW,referrerPolicy:null,rel:oQ,required:oW,reversed:oW,rows:oJ,rowSpan:oJ,sandbox:oQ,scope:null,scoped:oW,seamless:oW,selected:oW,shadowRootClonable:oW,shadowRootDelegatesFocus:oW,shadowRootMode:null,shape:null,size:oJ,sizes:null,slot:null,span:oJ,spellCheck:oG,src:null,srcDoc:null,srcLang:null,srcSet:null,start:oJ,step:null,style:null,tabIndex:oJ,target:null,title:null,translate:null,type:null,typeMustMatch:oW,useMap:null,value:oG,width:oJ,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:oQ,axis:null,background:null,bgColor:null,border:oJ,borderColor:null,bottomMargin:oJ,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:oW,declare:oW,event:null,face:null,frame:null,frameBorder:null,hSpace:oJ,leftMargin:oJ,link:null,longDesc:null,lowSrc:null,marginHeight:oJ,marginWidth:oJ,noResize:oW,noHref:oW,noShade:oW,noWrap:oW,object:null,profile:null,prompt:null,rev:null,rightMargin:oJ,rules:null,scheme:null,scrolling:oG,standby:null,summary:null,text:null,topMargin:oJ,valueType:null,version:null,vAlign:null,vLink:null,vSpace:oJ,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:oW,disableRemotePlayback:oW,prefix:null,property:null,results:oJ,security:null,unselectable:null}}),ln=o5({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:o6,properties:{about:oZ,accentHeight:oJ,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:oJ,amplitude:oJ,arabicForm:null,ascent:oJ,attributeName:null,attributeType:null,azimuth:oJ,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:oJ,by:null,calcMode:null,capHeight:oJ,className:oQ,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:oJ,diffuseConstant:oJ,direction:null,display:null,dur:null,divisor:oJ,dominantBaseline:null,download:oW,dx:null,dy:null,edgeMode:null,editable:null,elevation:oJ,enableBackground:null,end:null,event:null,exponent:oJ,externalResourcesRequired:null,fill:null,fillOpacity:oJ,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:oY,g2:oY,glyphName:oY,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:oJ,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:oJ,horizOriginX:oJ,horizOriginY:oJ,id:null,ideographic:oJ,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:oJ,k:oJ,k1:oJ,k2:oJ,k3:oJ,k4:oJ,kernelMatrix:oZ,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:oJ,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:oJ,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:oJ,overlineThickness:oJ,paintOrder:null,panose1:null,path:null,pathLength:oJ,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:oQ,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:oJ,pointsAtY:oJ,pointsAtZ:oJ,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:oZ,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:oZ,rev:oZ,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:oZ,requiredFeatures:oZ,requiredFonts:oZ,requiredFormats:oZ,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:oJ,specularExponent:oJ,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:oJ,strikethroughThickness:oJ,string:null,stroke:null,strokeDashArray:oZ,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:oJ,strokeOpacity:oJ,strokeWidth:null,style:null,surfaceScale:oJ,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:oZ,tabIndex:oJ,tableValues:null,target:null,targetX:oJ,targetY:oJ,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:oZ,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:oJ,underlineThickness:oJ,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:oJ,values:null,vAlphabetic:oJ,vMathematical:oJ,vectorEffect:null,vHanging:oJ,vIdeographic:oJ,version:null,vertAdvY:oJ,vertOriginX:oJ,vertOriginY:oJ,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:oJ,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),lr=oV([o4,o8,o7,le,lt],"html"),li=oV([o4,o8,o7,le,ln],"svg"),ls={}.hasOwnProperty,lo=/["&'<>`]/g,ll=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,la=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,lu=/[|\\{}()[\]^$+*?.]/g,lh=new WeakMap,lc=/[\dA-Fa-f]/,lf=/\d/,ld=["AElig","AMP","Aacute","Acirc","Agrave","Aring","Atilde","Auml","COPY","Ccedil","ETH","Eacute","Ecirc","Egrave","Euml","GT","Iacute","Icirc","Igrave","Iuml","LT","Ntilde","Oacute","Ocirc","Ograve","Oslash","Otilde","Ouml","QUOT","REG","THORN","Uacute","Ucirc","Ugrave","Uuml","Yacute","aacute","acirc","acute","aelig","agrave","amp","aring","atilde","auml","brvbar","ccedil","cedil","cent","copy","curren","deg","divide","eacute","ecirc","egrave","eth","euml","frac12","frac14","frac34","gt","iacute","icirc","iexcl","igrave","iquest","iuml","laquo","lt","macr","micro","middot","nbsp","not","ntilde","oacute","ocirc","ograve","ordf","ordm","oslash","otilde","ouml","para","plusmn","pound","quot","raquo","reg","sect","shy","sup1","sup2","sup3","szlig","thorn","times","uacute","ucirc","ugrave","uml","uuml","yacute","yen","yuml"],lp={nbsp:"\xa0",iexcl:"\xa1",cent:"\xa2",pound:"\xa3",curren:"\xa4",yen:"\xa5",brvbar:"\xa6",sect:"\xa7",uml:"\xa8",copy:"\xa9",ordf:"\xaa",laquo:"\xab",not:"\xac",shy:"\xad",reg:"\xae",macr:"\xaf",deg:"\xb0",plusmn:"\xb1",sup2:"\xb2",sup3:"\xb3",acute:"\xb4",micro:"\xb5",para:"\xb6",middot:"\xb7",cedil:"\xb8",sup1:"\xb9",ordm:"\xba",raquo:"\xbb",frac14:"\xbc",frac12:"\xbd",frac34:"\xbe",iquest:"\xbf",Agrave:"\xc0",Aacute:"\xc1",Acirc:"\xc2",Atilde:"\xc3",Auml:"\xc4",Aring:"\xc5",AElig:"\xc6",Ccedil:"\xc7",Egrave:"\xc8",Eacute:"\xc9",Ecirc:"\xca",Euml:"\xcb",Igrave:"\xcc",Iacute:"\xcd",Icirc:"\xce",Iuml:"\xcf",ETH:"\xd0",Ntilde:"\xd1",Ograve:"\xd2",Oacute:"\xd3",Ocirc:"\xd4",Otilde:"\xd5",Ouml:"\xd6",times:"\xd7",Oslash:"\xd8",Ugrave:"\xd9",Uacute:"\xda",Ucirc:"\xdb",Uuml:"\xdc",Yacute:"\xdd",THORN:"\xde",szlig:"\xdf",agrave:"\xe0",aacute:"\xe1",acirc:"\xe2",atilde:"\xe3",auml:"\xe4",aring:"\xe5",aelig:"\xe6",ccedil:"\xe7",egrave:"\xe8",eacute:"\xe9",ecirc:"\xea",euml:"\xeb",igrave:"\xec",iacute:"\xed",icirc:"\xee",iuml:"\xef",eth:"\xf0",ntilde:"\xf1",ograve:"\xf2",oacute:"\xf3",ocirc:"\xf4",otilde:"\xf5",ouml:"\xf6",divide:"\xf7",oslash:"\xf8",ugrave:"\xf9",uacute:"\xfa",ucirc:"\xfb",uuml:"\xfc",yacute:"\xfd",thorn:"\xfe",yuml:"\xff",fnof:"ƒ",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",bull:"•",hellip:"…",prime:"′",Prime:"″",oline:"‾",frasl:"⁄",weierp:"℘",image:"ℑ",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",lang:"〈",rang:"〉",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦",quot:'"',amp:"&",lt:"<",gt:">",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",circ:"ˆ",tilde:"˜",ensp:" ",emsp:" ",thinsp:" ",zwnj:"",zwj:"",lrm:"",rlm:"",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",permil:"‰",lsaquo:"‹",rsaquo:"›",euro:"€"},lm=["cent","copy","divide","gt","lt","not","para","times"],lg={}.hasOwnProperty,ly={};for(o in lp)lg.call(lp,o)&&(ly[lp[o]]=o);let lb=/[^\dA-Za-z]/;function lv(e,t,n){let r,i=function(e,t,n){let r="&#x"+e.toString(16).toUpperCase();return n&&t&&!lc.test(String.fromCharCode(t))?r:r+";"}(e,t,n.omitOptionalSemicolons);if((n.useNamedReferences||n.useShortestReferences)&&(r=function(e,t,n,r){let i=String.fromCharCode(e);if(lg.call(ly,i)){let e=ly[i],s="&"+e;return n&&ld.includes(e)&&!lm.includes(e)&&(!r||t&&61!==t&&lb.test(String.fromCharCode(t)))?s:s+";"}return""}(e,t,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!r)&&n.useShortestReferences){let r=function(e,t,n){let r="&#"+String(e);return n&&t&&!lf.test(String.fromCharCode(t))?r:r+";"}(e,t,n.omitOptionalSemicolons);r.length<i.length&&(i=r)}return r&&(!n.useShortestReferences||r.length<i.length)?r:i}function lk(e,t){return function(e,t){if(e=e.replace(t.subset?function(e){let t=lh.get(e);return!t&&(t=function(e){let t=[],n=-1;for(;++n<e.length;)t.push(e[n].replace(lu,"\\$&"));return RegExp("(?:"+t.join("|")+")","g")}(e),lh.set(e,t)),t}(t.subset):lo,n),t.subset||t.escapeOnly)return e;return e.replace(ll,function(e,n,r){return t.format((e.charCodeAt(0)-55296)*1024+e.charCodeAt(1)-56320+65536,r.charCodeAt(n+2),t)}).replace(la,n);function n(e,n,r){return t.format(e.charCodeAt(0),r.charCodeAt(n+1),t)}}(e,Object.assign({format:lv},t))}let lw=/^>|^->|<!--|-->|--!>|<!-$/g,lD=[">"],lA=["<",">"];function lx(e,t){let n=String(e);if("string"!=typeof t)throw TypeError("Expected character");let r=0,i=n.indexOf(t);for(;-1!==i;)r++,i=n.indexOf(t,i+t.length);return r}let lC=/^data[-\w.:]+$/i,lE=/-[a-z]/g,lS=/[A-Z]/g;function l_(e){return"-"+e.toLowerCase()}function lO(e){return e.charAt(1).toUpperCase()}let lF=/[ \t\n\f\r]/g;function lP(e){return"object"==typeof e?"text"===e.type&&lT(e.value):lT(e)}function lT(e){return""===e.replace(lF,"")}let lN=lM(1),lB=lM(-1),lI=[];function lM(e){return function(t,n,r){let i=t?t.children:lI,s=(n||0)+e,o=i[s];if(!r)for(;o&&lP(o);)s+=e,o=i[s];return o}}let l$={}.hasOwnProperty;function lL(e){return function(t,n,r){return l$.call(e,t.tagName)&&e[t.tagName](t,n,r)}}let lR=lL({body:function(e,t,n){let r=lN(n,t);return!r||"comment"!==r.type},caption:lj,colgroup:lj,dd:function(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&("dt"===r.tagName||"dd"===r.tagName)},dt:function(e,t,n){let r=lN(n,t);return!!(r&&"element"===r.type&&("dt"===r.tagName||"dd"===r.tagName))},head:lj,html:function(e,t,n){let r=lN(n,t);return!r||"comment"!==r.type},li:function(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&"li"===r.tagName},optgroup:function(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&"optgroup"===r.tagName},option:function(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&("option"===r.tagName||"optgroup"===r.tagName)},p:function(e,t,n){let r=lN(n,t);return r?"element"===r.type&&("address"===r.tagName||"article"===r.tagName||"aside"===r.tagName||"blockquote"===r.tagName||"details"===r.tagName||"div"===r.tagName||"dl"===r.tagName||"fieldset"===r.tagName||"figcaption"===r.tagName||"figure"===r.tagName||"footer"===r.tagName||"form"===r.tagName||"h1"===r.tagName||"h2"===r.tagName||"h3"===r.tagName||"h4"===r.tagName||"h5"===r.tagName||"h6"===r.tagName||"header"===r.tagName||"hgroup"===r.tagName||"hr"===r.tagName||"main"===r.tagName||"menu"===r.tagName||"nav"===r.tagName||"ol"===r.tagName||"p"===r.tagName||"pre"===r.tagName||"section"===r.tagName||"table"===r.tagName||"ul"===r.tagName):!n||!("element"===n.type&&("a"===n.tagName||"audio"===n.tagName||"del"===n.tagName||"ins"===n.tagName||"map"===n.tagName||"noscript"===n.tagName||"video"===n.tagName))},rp:lq,rt:lq,tbody:function(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&("tbody"===r.tagName||"tfoot"===r.tagName)},td:lV,tfoot:function(e,t,n){return!lN(n,t)},th:lV,thead:function(e,t,n){let r=lN(n,t);return!!(r&&"element"===r.type&&("tbody"===r.tagName||"tfoot"===r.tagName))},tr:function(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&"tr"===r.tagName}});function lj(e,t,n){let r=lN(n,t,!0);return!r||"comment"!==r.type&&!("text"===r.type&&lP(r.value.charAt(0)))}function lq(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&("rp"===r.tagName||"rt"===r.tagName)}function lV(e,t,n){let r=lN(n,t);return!r||"element"===r.type&&("td"===r.tagName||"th"===r.tagName)}let lz=lL({body:function(e){let t=lN(e,-1,!0);return!t||"comment"!==t.type&&!("text"===t.type&&lP(t.value.charAt(0)))&&!("element"===t.type&&("meta"===t.tagName||"link"===t.tagName||"script"===t.tagName||"style"===t.tagName||"template"===t.tagName))},colgroup:function(e,t,n){let r=lB(n,t),i=lN(e,-1,!0);return!(n&&r&&"element"===r.type&&"colgroup"===r.tagName&&lR(r,n.children.indexOf(r),n))&&!!(i&&"element"===i.type&&"col"===i.tagName)},head:function(e){let t=new Set;for(let n of e.children)if("element"===n.type&&("base"===n.tagName||"title"===n.tagName)){if(t.has(n.tagName))return!1;t.add(n.tagName)}let n=e.children[0];return!n||"element"===n.type},html:function(e){let t=lN(e,-1);return!t||"comment"!==t.type},tbody:function(e,t,n){let r=lB(n,t),i=lN(e,-1);return!(n&&r&&"element"===r.type&&("thead"===r.tagName||"tbody"===r.tagName)&&lR(r,n.children.indexOf(r),n))&&!!(i&&"element"===i.type&&"tr"===i.tagName)}}),lU={name:[[" \n\f\r &/=>".split("")," \n\f\r \"&'/=>`".split("")],["\0 \n\f\r \"&'/<=>".split(""),"\0 \n\f\r \"&'/<=>`".split("")]],unquoted:[[" \n\f\r &>".split(""),"\0 \n\f\r \"&'<=>`".split("")],["\0 \n\f\r \"&'<=>`".split(""),"\0 \n\f\r \"&'<=>`".split("")]],single:[["&'".split(""),"\"&'`".split("")],["\0&'".split(""),"\0\"&'`".split("")]],double:[['"&'.split(""),"\"&'`".split("")],['\0"&'.split(""),"\0\"&'`".split("")]]},lH=["<","&"];function lW(e,t,n,r){return n&&"element"===n.type&&("script"===n.tagName||"style"===n.tagName)?e.value:lk(e.value,Object.assign({},r.settings.characterReferences,{subset:lH}))}let lG=function(e,t){let n=t||{};function r(t,...n){let i=r.invalid,s=r.handlers;if(t&&ls.call(t,e)){let n=String(t[e]);i=ls.call(s,n)?s[n]:r.unknown}if(i)return i.call(this,t,...n)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}("type",{invalid:function(e){throw Error("Expected node, not `"+e+"`")},unknown:function(e){throw Error("Cannot compile unknown node `"+e.type+"`")},handlers:{comment:function(e,t,n,r){return r.settings.bogusComments?"<?"+lk(e.value,Object.assign({},r.settings.characterReferences,{subset:lD}))+">":"\x3c!--"+e.value.replace(lw,function(e){return lk(e,Object.assign({},r.settings.characterReferences,{subset:lA}))})+"--\x3e"},doctype:function(e,t,n,r){return"<!"+(r.settings.upperDoctype?"DOCTYPE":"doctype")+(r.settings.tightDoctype?"":" ")+"html>"},element:function(e,t,n,r){let i;let s=r.schema,o="svg"!==s.space&&r.settings.omitOptionalTags,l="svg"===s.space?r.settings.closeEmptyElements:r.settings.voids.includes(e.tagName.toLowerCase()),a=[];"html"===s.space&&"svg"===e.tagName&&(r.schema=li);let u=function(e,t){let n;let r=[],i=-1;if(t){for(n in t)if(null!==t[n]&&void 0!==t[n]){let i=function(e,t,n){let r;let i=function(e,t){let n=oz(t),r=t,i=oU;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&"data"===n.slice(0,4)&&lC.test(t)){if("-"===t.charAt(4)){let e=t.slice(5).replace(lE,lO);r="data"+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!lE.test(e)){let n=e.replace(lS,l_);"-"!==n.charAt(0)&&(n="-"+n),t="data"+n}}i=o1}return new i(r,t)}(e.schema,t),s=e.settings.allowParseErrors&&"html"===e.schema.space?0:1,o=e.settings.allowDangerousCharacters?0:1,l=e.quote;if(i.overloadedBoolean&&(n===i.attribute||""===n)?n=!0:(i.boolean||i.overloadedBoolean&&"string"!=typeof n)&&(n=!!n),null==n||!1===n||"number"==typeof n&&Number.isNaN(n))return"";let a=lk(i.attribute,Object.assign({},e.settings.characterReferences,{subset:lU.name[s][o]}));return!0===n?a:(n=Array.isArray(n)?(i.commaSeparated?function(e,t){let n=t||{};return(""===e[e.length-1]?[...e,""]:e).join((n.padRight?" ":"")+","+(!1===n.padLeft?"":" ")).trim()}:function(e){return e.join(" ").trim()})(n,{padLeft:!e.settings.tightCommaSeparatedLists}):String(n),e.settings.collapseEmptyAttributes&&!n)?a:(e.settings.preferUnquoted&&(r=lk(n,Object.assign({},e.settings.characterReferences,{attribute:!0,subset:lU.unquoted[s][o]}))),r!==n&&(e.settings.quoteSmart&&lx(n,l)>lx(n,e.alternative)&&(l=e.alternative),r=l+lk(n,Object.assign({},e.settings.characterReferences,{subset:("'"===l?lU.single:lU.double)[s][o],attribute:!0}))+l),a+(r?"="+r:r))}(e,n,t[n]);i&&r.push(i)}}for(;++i<r.length;){let t=e.settings.tightAttributes?r[i].charAt(r[i].length-1):void 0;i!==r.length-1&&'"'!==t&&"'"!==t&&(r[i]+=" ")}return r.join("")}(r,e.properties),h=r.all("html"===s.space&&"template"===e.tagName?e.content:e);return r.schema=s,h&&(l=!1),(u||!o||!lz(e,t,n))&&(a.push("<",e.tagName,u?" "+u:""),l&&("svg"===s.space||r.settings.closeSelfClosing)&&(i=u.charAt(u.length-1),(!r.settings.tightSelfClosing||"/"===i||i&&'"'!==i&&"'"!==i)&&a.push(" "),a.push("/")),a.push(">")),a.push(h),!l&&(!o||!lR(e,t,n))&&a.push("</"+e.tagName+">"),a.join("")},raw:function(e,t,n,r){return r.settings.allowDangerousHtml?e.value:lW(e,t,n,r)},root:function(e,t,n,r){return r.all(e)},text:lW}}),lK={},lJ={},lQ=[];function lY(e,t,n){return lG(e,t,n,this)}function lZ(e){let t=[],n=e&&e.children||lQ,r=-1;for(;++r<n.length;)t[r]=this.one(n[r],r,e);return t.join("")}function lX(e,t=!1){let n=e.split(/(\r?\n)/g),r=0,i=[];for(let e=0;e<n.length;e+=2){let s=t?n[e]+(n[e+1]||""):n[e];i.push([s,r]),r+=n[e].length,r+=n[e+1]?.length||0}return i}function l0(e){return!e||["plaintext","txt","text","plain"].includes(e)}function l1(e){return"ansi"===e||l0(e)}function l2(e){return"none"===e}function l3(e){return l2(e)}function l5(e,t){var n;if(!t)return e;for(let r of(e.properties||(e.properties={}),(n=e.properties).class||(n.class=[]),"string"==typeof e.properties.class&&(e.properties.class=e.properties.class.split(/\s+/g)),!Array.isArray(e.properties.class)&&(e.properties.class=[]),Array.isArray(t)?t:t.split(/\s+/g)))r&&!e.properties.class.includes(r)&&e.properties.class.push(r);return e}async function l8(e){return Promise.resolve("function"==typeof e?e():e).then(e=>e.default||e)}function l4(e,t){let n="string"==typeof e?{}:{...e.colorReplacements},r="string"==typeof e?e:e.name;for(let[e,i]of Object.entries(t?.colorReplacements||{}))"string"==typeof i?n[e]=i:e===r&&Object.assign(n,i);return n}function l6(e,t){return e&&t?.[e?.toLowerCase()]||e}function l9(e){let t={};return e.color&&(t.color=e.color),e.bgColor&&(t["background-color"]=e.bgColor),e.fontStyle&&(e.fontStyle&sG.Italic&&(t["font-style"]="italic"),e.fontStyle&sG.Bold&&(t["font-weight"]="bold"),e.fontStyle&sG.Underline&&(t["text-decoration"]="underline")),t}class l7 extends Error{constructor(e){super(e),this.name="ShikiError"}}var ae=Object.defineProperty,at=(e,t,n)=>t in e?ae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,an=(e,t,n)=>(at(e,"symbol"!=typeof t?t+"":t,n),n);let ar=new WeakMap;function ai(e,t){ar.set(e,t)}function as(e){return ar.get(e)}class ao{constructor(...e){if(an(this,"_stacks",{}),an(this,"lang"),2===e.length){let[t,n]=e;this.lang=n,this._stacks=t}else{let[t,n,r]=e;this.lang=n,this._stacks={[r]:t}}}get themes(){return Object.keys(this._stacks)}get theme(){return this.themes[0]}get _stack(){return this._stacks[this.theme]}static initial(e,t){var n;return new ao(Object.fromEntries((Array.isArray(n=t)?n:[n]).map(e=>[e,oR])),e)}getInternalStack(e=this.theme){return this._stacks[e]}get scopes(){return al(this._stacks[this.theme])}getScopes(e=this.theme){return al(this._stacks[e])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.scopes}}}function al(e){let t=[],n=new Set;return!function e(r){if(n.has(r))return;n.add(r);let i=r?.nameScopesList?.scopeName;i&&t.push(i),r.parent&&e(r.parent)}(e),t}let aa=[function(){let e=new WeakMap;function t(t){if(!e.has(t.meta)){let n=function(e){if("number"==typeof e){if(e<0||e>t.source.length)throw new l7(`Invalid decoration offset: ${e}. Code length: ${t.source.length}`);return{...r.indexToPos(e),offset:e}}{let t=r.lines[e.line];if(void 0===t)throw new l7(`Invalid decoration position ${JSON.stringify(e)}. Lines length: ${r.lines.length}`);if(e.character<0||e.character>t.length)throw new l7(`Invalid decoration position ${JSON.stringify(e)}. Line ${e.line} length: ${t.length}`);return{...e,offset:r.posToIndex(e.line,e.character)}}},r=function(e){let t=lX(e,!0).map(([e])=>e);return{lines:t,indexToPos:function(n){if(n===e.length)return{line:t.length-1,character:t[t.length-1].length};let r=n,i=0;for(let e of t){if(r<e.length)break;r-=e.length,i++}return{line:i,character:r}},posToIndex:function(e,n){let r=0;for(let n=0;n<e;n++)r+=t[n].length;return r+=n}}}(t.source),i=(t.options.decorations||[]).map(e=>({...e,start:n(e.start),end:n(e.end)}));(function(e){for(let t=0;t<e.length;t++){let n=e[t];if(n.start.offset>n.end.offset)throw new l7(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let r=t+1;r<e.length;r++){let t=e[r],i=n.start.offset<t.start.offset&&t.start.offset<n.end.offset,s=n.start.offset<t.end.offset&&t.end.offset<n.end.offset,o=t.start.offset<n.start.offset&&n.start.offset<t.end.offset,l=t.start.offset<n.end.offset&&n.end.offset<t.end.offset;if(i||s||o||l){if(s&&s||o&&l)continue;throw new l7(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(t.start)} intersect.`)}}}})(i),e.set(t.meta,{decorations:i,converter:r,source:t.source})}return e.get(t.meta)}return{name:"shiki:decorations",tokens(e){if(!!this.options.decorations?.length)return function(e,t){let n=Array.from(t instanceof Set?t:new Set(t)).sort((e,t)=>e-t);return n.length?e.map(e=>e.flatMap(e=>{let t=n.filter(t=>e.offset<t&&t<e.offset+e.content.length).map(t=>t-e.offset).sort((e,t)=>e-t);return t.length?function(e,t){let n=0,r=[];for(let i of t)i>n&&r.push({...e,content:e.content.slice(n,i),offset:e.offset+n}),n=i;return n<e.content.length&&r.push({...e,content:e.content.slice(n),offset:e.offset+n}),r}(e,t):e})):e}(e,t(this).decorations.flatMap(e=>[e.start.offset,e.end.offset]))},code(e){if(!this.options.decorations?.length)return;let n=t(this),r=Array.from(e.children).filter(e=>"element"===e.type&&"span"===e.tagName);if(r.length!==n.converter.lines.length)throw new l7(`Number of lines in code element (${r.length}) does not match the number of lines in the source (${n.converter.lines.length}). Failed to apply decorations.`);function i(e,t,n,i){let o=r[e],l="",a=-1,u=-1;if(0===t&&(a=0),0===n&&(u=0),n===Number.POSITIVE_INFINITY&&(u=o.children.length),-1===a||-1===u)for(let e=0;e<o.children.length;e++)l+=function e(t){return"text"===t.type?t.value:"element"===t.type?t.children.map(e).join(""):""}(o.children[e]),-1===a&&l.length===t&&(a=e+1),-1===u&&l.length===n&&(u=e+1);if(-1===a)throw new l7(`Failed to find start index for decoration ${JSON.stringify(i.start)}`);if(-1===u)throw new l7(`Failed to find end index for decoration ${JSON.stringify(i.end)}`);let h=o.children.slice(a,u);if(i.alwaysWrap||h.length!==o.children.length){if(i.alwaysWrap||1!==h.length||"element"!==h[0].type){let e={type:"element",tagName:"span",properties:{},children:h};s(e,i,"wrapper"),o.children.splice(a,h.length,e)}else s(h[0],i,"token")}else s(o,i,"line")}function s(e,t,n){let r=t.properties||{},i=t.transform||(e=>e);return e.tagName=t.tagName||"span",e.properties={...e.properties,...r,class:e.properties.class},t.properties?.class&&l5(e,t.properties.class),e=i(e,n)||e}let o=[];for(let e of n.decorations.sort((e,t)=>t.start.offset-e.start.offset)){let{start:t,end:n}=e;if(t.line===n.line)i(t.line,t.character,n.character,e);else if(t.line<n.line){i(t.line,t.character,Number.POSITIVE_INFINITY,e);for(let i=t.line+1;i<n.line;i++)o.unshift(()=>{var t,n;return t=i,n=e,void(r[t]=s(r[t],n,"line"))});i(n.line,0,n.character,e)}}o.forEach(e=>e())}}}()];function au(e){return[...e.transformers||[],...aa]}var ah=["black","red","green","yellow","blue","magenta","cyan","white","brightBlack","brightRed","brightGreen","brightYellow","brightBlue","brightMagenta","brightCyan","brightWhite"],ac={1:"bold",2:"dim",3:"italic",4:"underline",7:"reverse",9:"strikethrough"};function af(e,t){let n,r=1,i=e[t+r++];if("2"===i){let i=[e[t+r++],e[t+r++],e[t+r]].map(e=>Number.parseInt(e));3===i.length&&!i.some(e=>Number.isNaN(e))&&(n={type:"rgb",rgb:i})}else if("5"===i){let i=Number.parseInt(e[t+r]);!Number.isNaN(i)&&(n={type:"table",index:Number(i)})}return[r,n]}var ad={black:"#000000",red:"#bb0000",green:"#00bb00",yellow:"#bbbb00",blue:"#0000bb",magenta:"#ff00ff",cyan:"#00bbbb",white:"#eeeeee",brightBlack:"#555555",brightRed:"#ff5555",brightGreen:"#00ff00",brightYellow:"#ffff55",brightBlue:"#5555ff",brightMagenta:"#ff55ff",brightCyan:"#55ffff",brightWhite:"#ffffff"};function ap(e,t,n={}){let{lang:r="text",theme:i=e.getLoadedThemes()[0]}=n;if(l0(r)||l2(i))return lX(t).map(e=>[{content:e[0],offset:e[1]}]);let{theme:s,colorMap:o}=e.setTheme(i);if("ansi"===r)return function(e,t,n){let r,i,s,o=l4(e,n),l=lX(t),a=function(e=ad){let t;function n(t){return e[t]}function r(e){return`#${e.map(e=>Math.max(0,Math.min(e,255)).toString(16).padStart(2,"0")).join("")}`}return{value:function(n){switch(n.type){case"named":return e[n.name];case"rgb":return r(n.rgb);case"table":var i;return i=n.index,function(){if(t)return t;t=[];for(let n=0;n<ah.length;n++)t.push(e[ah[n]]);let n=[0,95,135,175,215,255];for(let e=0;e<6;e++)for(let i=0;i<6;i++)for(let s=0;s<6;s++)t.push(r([n[e],n[i],n[s]]));let i=8;for(let e=0;e<24;e++,i+=10)t.push(r([i,i,i]));return t}()[i]}}}}(Object.fromEntries(ah.map(t=>[t,e.colors?.[`terminal.ansi${t[0].toUpperCase()}${t.substring(1)}`]])));let u=(r=null,i=null,s=new Set,{parse(e){let t=[],n=0;do{let o=function(e,t){let n=e.indexOf("\x1b[",t);if(-1!==n){let t=e.indexOf("m",n);return{sequence:e.substring(n+2,t).split(";"),startPosition:n,position:t+1}}return{position:e.length}}(e,n),l=o.sequence?e.substring(n,o.startPosition):e.substring(n);if(l.length>0&&t.push({value:l,foreground:r,background:i,decorations:new Set(s)}),o.sequence){let e=function(e){let t=[];for(let n=0;n<e.length;n++){let r=Number.parseInt(e[n]);if(!Number.isNaN(r)){if(0===r)t.push({type:"resetAll"});else if(r<=9)ac[r]&&t.push({type:"setDecoration",value:ac[r]});else if(r<=29){let e=ac[r-20];e&&t.push({type:"resetDecoration",value:e})}else if(r<=37)t.push({type:"setForegroundColor",value:{type:"named",name:ah[r-30]}});else if(38===r){let[r,i]=af(e,n);i&&t.push({type:"setForegroundColor",value:i}),n+=r}else if(39===r)t.push({type:"resetForegroundColor"});else if(r<=47)t.push({type:"setBackgroundColor",value:{type:"named",name:ah[r-40]}});else if(48===r){let[r,i]=af(e,n);i&&t.push({type:"setBackgroundColor",value:i}),n+=r}else 49===r?t.push({type:"resetBackgroundColor"}):r>=90&&r<=97?t.push({type:"setForegroundColor",value:{type:"named",name:ah[r-90+8]}}):r>=100&&r<=107&&t.push({type:"setBackgroundColor",value:{type:"named",name:ah[r-100+8]}})}}return t}(o.sequence);for(let t of e)"resetAll"===t.type?(r=null,i=null,s.clear()):"resetForegroundColor"===t.type?r=null:"resetBackgroundColor"===t.type?i=null:"resetDecoration"===t.type&&s.delete(t.value);for(let t of e)"setForegroundColor"===t.type?r=t.value:"setBackgroundColor"===t.type?i=t.value:"setDecoration"===t.type&&s.add(t.value)}n=o.position}while(n<e.length);return t}});return l.map(t=>u.parse(t[0]).map(n=>{let r,i;n.decorations.has("reverse")?(r=n.background?a.value(n.background):e.bg,i=n.foreground?a.value(n.foreground):e.fg):(r=n.foreground?a.value(n.foreground):e.fg,i=n.background?a.value(n.background):void 0),r=l6(r,o),i=l6(i,o),n.decorations.has("dim")&&(r=function(e){let t=e.match(/#([0-9a-f]{3})([0-9a-f]{3})?([0-9a-f]{2})?/);if(t){if(t[3]){let e=Math.round(Number.parseInt(t[3],16)/2).toString(16).padStart(2,"0");return`#${t[1]}${t[2]}${e}`}if(t[2])return`#${t[1]}${t[2]}80`;else return`#${Array.from(t[1]).map(e=>`${e}${e}`).join("")}80`}let n=e.match(/var\((--[\w-]+-ansi-[\w-]+)\)/);return n?`var(${n[1]}-dim)`:e}(r));let s=sG.None;return n.decorations.has("bold")&&(s|=sG.Bold),n.decorations.has("italic")&&(s|=sG.Italic),n.decorations.has("underline")&&(s|=sG.Underline),{content:n.value,offset:t[1],color:r,bgColor:i,fontStyle:s}}))}(s,t,n);let l=e.getLanguage(r);if(n.grammarState){if(n.grammarState.lang!==l.name)throw new sD(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${l.name}"`);if(!n.grammarState.themes.includes(s.name))throw new sD(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${s.name}"`)}return function(e,t,n,r,i){let s=am(e,t,n,r,i),o=new ao(am(e,t,n,r,i).stateStack,t.name,n.name);return ai(s.tokens,o),s.tokens}(t,l,s,o,n)}function am(e,t,n,r,i){let s=l4(n,i),{tokenizeMaxLineLength:o=0,tokenizeTimeLimit:l=500}=i,a=lX(e),u=i.grammarState?function(e,t){if(!(e instanceof ao))throw new l7("Invalid grammar state");return e.getInternalStack(t)}(i.grammarState,n.name)??oR:null!=i.grammarContextCode?am(i.grammarContextCode,t,n,r,{...i,grammarState:void 0,grammarContextCode:void 0}).stateStack:oR,h=[],c=[];for(let e=0,f=a.length;e<f;e++){let f,d;let[p,m]=a[e];if(""===p){h=[],c.push([]);continue}if(o>0&&p.length>=o){h=[],c.push([{content:p,offset:m,color:"",fontStyle:0}]);continue}i.includeExplanation&&(f=t.tokenizeLine(p,u).tokens,d=0);let g=t.tokenizeLine2(p,u,l),y=g.tokens.length/2;for(let e=0;e<y;e++){let t=g.tokens[2*e],o=e+1<y?g.tokens[2*e+2]:p.length;if(t===o)continue;let l=g.tokens[2*e+1],a=l6(r[sZ.getForeground(l)],s),u=sZ.getFontStyle(l),c={content:p.substring(t,o),offset:m+t,color:a,fontStyle:u};if(i.includeExplanation){let e=[];if("scopeName"!==i.includeExplanation)for(let t of n.settings){let n;switch(typeof t.scope){case"string":n=t.scope.split(/,/).map(e=>e.trim());break;case"object":n=t.scope;break;default:continue}e.push({settings:t,selectors:n.map(e=>e.split(/ /))})}c.explanation=[];let r=0;for(;t+r<o;){let t=f[d],n=p.substring(t.startIndex,t.endIndex);r+=n.length,c.explanation.push({content:n,scopes:"scopeName"===i.includeExplanation?function(e){return e.map(e=>({scopeName:e}))}(t.scopes):function(e,t){let n=[];for(let r=0,i=t.length;r<i;r++){let i=t[r];n[r]={scopeName:i,themeMatches:function(e,t,n){let r=[];for(let{selectors:i,settings:s}of e)for(let e of i)if(function(e,t,n){if(!ag(e[e.length-1],t))return!1;let r=e.length-2,i=n.length-1;for(;r>=0&&i>=0;)ag(e[r],n[i])&&(r-=1),i-=1;return -1===r||!1}(e,t,n)){r.push(s);break}return r}(e,i,t.slice(0,r))}}return n}(e,t.scopes)}),d+=1}}h.push(c)}c.push(h),h=[],u=g.ruleStack}return{tokens:c,stateStack:u}}function ag(e,t){return e===t||t.substring(0,e.length)===e&&"."===t[e.length]}function ay(e,t,n){let r=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})),i=r.map(r=>{let i=ap(e,t,{...n,theme:r.theme}),s=as(i);return{tokens:i,state:s,theme:"string"==typeof r.theme?r.theme:r.theme.name}}),s=function(...e){let t=e.map(()=>[]),n=e.length;for(let r=0;r<e[0].length;r++){let i=e.map(e=>e[r]),s=t.map(()=>[]);t.forEach((e,t)=>e.push(s[t]));let o=i.map(()=>0),l=i.map(e=>e[0]);for(;l.every(e=>e);){let e=Math.min(...l.map(e=>e.content.length));for(let t=0;t<n;t++){let n=l[t];n.content.length===e?(s[t].push(n),o[t]+=1,l[t]=i[t][o[t]]):(s[t].push({...n,content:n.content.slice(0,e)}),l[t]={...n,content:n.content.slice(e),offset:n.offset+e})}}}return t}(...i.map(e=>e.tokens)),o=s[0].map((e,t)=>e.map((e,i)=>{let o={content:e.content,variants:{},offset:e.offset};return"includeExplanation"in n&&n.includeExplanation&&(o.explanation=e.explanation),s.forEach((e,n)=>{let{content:s,explanation:l,offset:a,...u}=e[t][i];o.variants[r[n].color]=u}),o})),l=i[0].state?new ao(Object.fromEntries(i.map(e=>[e.theme,e.state?.getInternalStack(e.theme)])),i[0].state.lang):void 0;return l&&ai(o,l),o}function ab(e,t,n){let r,i,s,o,l,a;if("themes"in n){let{defaultColor:u="light",cssVariablePrefix:h="--shiki-"}=n,c=Object.entries(n.themes).filter(e=>e[1]).map(e=>({color:e[0],theme:e[1]})).sort((e,t)=>e.color===u?-1:t.color===u?1:0);if(0===c.length)throw new sD("`themes` option must not be empty");let f=ay(e,t,n);if(a=as(f),u&&!c.find(e=>e.color===u))throw new sD(`\`themes\` option must contain the defaultColor key \`${u}\``);let d=c.map(t=>e.getTheme(t.theme)),p=c.map(e=>e.color);s=f.map(e=>e.map(e=>(function(e,t,n,r){let i={content:e.content,explanation:e.explanation,offset:e.offset},s=t.map(t=>l9(e.variants[t])),o=new Set(s.flatMap(e=>Object.keys(e))),l={};return s.forEach((e,i)=>{for(let s of o){let o=e[s]||"inherit";if(0===i&&r)l[s]=o;else{let e="color"===s?"":"background-color"===s?"-bg":`-${s}`;l[n+t[i]+("color"===s?"":e)]=o}}}),i.htmlStyle=l,i})(e,p,h,u))),a&&ai(s,a);let m=c.map(e=>l4(e.theme,n));i=c.map((e,t)=>(0===t&&u?"":`${h+e.color}:`)+(l6(d[t].fg,m[t])||"inherit")).join(";"),r=c.map((e,t)=>(0===t&&u?"":`${h+e.color}-bg:`)+(l6(d[t].bg,m[t])||"inherit")).join(";"),o=`shiki-themes ${d.map(e=>e.name).join(" ")}`,l=u?void 0:[i,r].join(";")}else if("theme"in n){let l=l4(n.theme,n);s=ap(e,t,n);let u=e.getTheme(n.theme);r=l6(u.bg,l),i=l6(u.fg,l),o=u.name,a=as(s)}else throw new sD("Invalid options, either `theme` or `themes` must be provided");return{tokens:s,fg:i,bg:r,themeName:o,rootStyle:l,grammarState:a}}function av(e,t,n,r={meta:{},options:n,codeToHast:(t,n)=>av(e,t,n),codeToTokens:(t,n)=>ab(e,t,n)}){let i=t;for(let e of au(n))i=e.preprocess?.call(r,i,n)||i;let{tokens:s,fg:o,bg:l,themeName:a,rootStyle:u,grammarState:h}=ab(e,i,n),{mergeWhitespaces:c=!0}=n;!0===c?s=function(e){return e.map(e=>{let t=[],n="",r=0;return e.forEach((i,s)=>{let o=!(i.fontStyle&&i.fontStyle&sG.Underline);o&&i.content.match(/^\s+$/)&&e[s+1]?(!r&&(r=i.offset),n+=i.content):n?(o?t.push({...i,offset:r,content:n+i.content}):t.push({content:n,offset:r},i),r=0,n=""):t.push(i)}),t})}(s):"never"===c&&(s=function(e){return e.map(e=>e.flatMap(e=>{if(e.content.match(/^\s+$/))return e;let t=e.content.match(/^(\s*)(.*?)(\s*)$/);if(!t)return e;let[,n,r,i]=t;if(!n&&!i)return e;let s=[{...e,offset:e.offset+n.length,content:r}];return n&&s.unshift({content:n,offset:e.offset}),i&&s.push({content:i,offset:e.offset+n.length+r.length}),s}))}(s));let f={...r,get source(){return i}};for(let e of au(n))s=e.tokens?.call(f,s)||s;return function(e,t,n,r=as(e)){let i=au(t),s=[],o={type:"root",children:[]},{structure:l="classic",tabindex:a="0"}=t,u={type:"element",tagName:"pre",properties:{class:`shiki ${t.themeName||""}`,style:t.rootStyle||`background-color:${t.bg};color:${t.fg}`,...!1!==a&&null!=a?{tabindex:a.toString()}:{},...Object.fromEntries(Array.from(Object.entries(t.meta||{})).filter(([e])=>!e.startsWith("_")))},children:[]},h={type:"element",tagName:"code",properties:{},children:s},c=[],f={...n,structure:l,addClassToHast:l5,get source(){return n.source},get tokens(){return e},get options(){return t},get root(){return o},get pre(){return u},get code(){return h},get lines(){return c}};if(e.forEach((e,t)=>{t&&("inline"===l?o.children.push({type:"element",tagName:"br",properties:{},children:[]}):"classic"===l&&s.push({type:"text",value:"\n"}));let n={type:"element",tagName:"span",properties:{class:"line"},children:[]},r=0;for(let s of e){var a;let e={type:"element",tagName:"span",properties:{...s.htmlAttrs},children:[{type:"text",value:s.content}]};"string"==typeof s.htmlStyle&&sN("`htmlStyle` as a string is deprecated. Use an object instead.");let u="string"==typeof(a=s.htmlStyle||l9(s))?a:Object.entries(a).map(([e,t])=>`${e}:${t}`).join(";");for(let o of(u&&(e.properties.style=u),i))e=o?.span?.call(f,e,t+1,r,n,s)||e;"inline"===l?o.children.push(e):"classic"===l&&n.children.push(e),r+=s.content.length}if("classic"===l){for(let e of i)n=e?.line?.call(f,n,t+1)||n;c.push(n),s.push(n)}}),"classic"===l){for(let e of i)h=e?.code?.call(f,h)||h;for(let e of(u.children.push(h),i))u=e?.pre?.call(f,u)||u;o.children.push(u)}let d=o;for(let e of i)d=e?.root?.call(f,d)||d;return r&&ai(d,r),d}(s,{...n,fg:o,bg:l,themeName:a,rootStyle:u},f,h)}let ak={light:"#333333",dark:"#bbbbbb"},aw={light:"#fffffe",dark:"#1e1e1e"},aD="__shiki_resolved";function aA(e){if(e?.[aD])return e;let t={...e};t.tokenColors&&!t.settings&&(t.settings=t.tokenColors,delete t.tokenColors),t.type||(t.type="dark"),t.colorReplacements={...t.colorReplacements},t.settings||(t.settings=[]);let{bg:n,fg:r}=t;if(!n||!r){let e=t.settings?t.settings.find(e=>!e.name&&!e.scope):void 0;e?.settings?.foreground&&(r=e.settings.foreground),e?.settings?.background&&(n=e.settings.background),!r&&t?.colors?.["editor.foreground"]&&(r=t.colors["editor.foreground"]),!n&&t?.colors?.["editor.background"]&&(n=t.colors["editor.background"]),!r&&(r="light"===t.type?ak.light:ak.dark),!n&&(n="light"===t.type?aw.light:aw.dark),t.fg=r,t.bg=n}!(t.settings[0]&&t.settings[0].settings&&!t.settings[0].scope)&&t.settings.unshift({settings:{foreground:t.fg,background:t.bg}});let i=0,s=new Map;function o(e){if(s.has(e))return s.get(e);i+=1;let n=`#${i.toString(16).padStart(8,"0").toLowerCase()}`;return t.colorReplacements?.[`#${n}`]?o(e):(s.set(e,n),n)}for(let e of(t.settings=t.settings.map(e=>{let n=e.settings?.foreground&&!e.settings.foreground.startsWith("#"),r=e.settings?.background&&!e.settings.background.startsWith("#");if(!n&&!r)return e;let i={...e,settings:{...e.settings}};if(n){let n=o(e.settings.foreground);t.colorReplacements[n]=e.settings.foreground,i.settings.foreground=n}if(r){let n=o(e.settings.background);t.colorReplacements[n]=e.settings.background,i.settings.background=n}return i}),Object.keys(t.colors||{})))if(("editor.foreground"===e||"editor.background"===e||e.startsWith("terminal.ansi"))&&!t.colors[e]?.startsWith("#")){let n=o(t.colors[e]);t.colorReplacements[n]=t.colors[e],t.colors[e]=n}return Object.defineProperty(t,aD,{enumerable:!1,writable:!1,value:!0}),t}async function ax(e){return Array.from(new Set((await Promise.all(e.filter(e=>!l1(e)).map(async e=>await l8(e).then(e=>Array.isArray(e)?e:[e])))).flat()))}async function aC(e){return(await Promise.all(e.map(async e=>l2(e)?null:aA(await l8(e))))).filter(e=>!!e)}var aE=Object.defineProperty,aS=(e,t,n)=>t in e?aE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,a_=(e,t,n)=>(aS(e,"symbol"!=typeof t?t+"":t,n),n);class aO extends oL{constructor(e,t,n,r={}){super(e),this._resolver=e,this._themes=t,this._langs=n,this._alias=r,a_(this,"_resolvedThemes",new Map),a_(this,"_resolvedGrammars",new Map),a_(this,"_langMap",new Map),a_(this,"_langGraph",new Map),a_(this,"_textmateThemeCache",new WeakMap),a_(this,"_loadedThemesCache",null),a_(this,"_loadedLanguagesCache",null),this._themes.map(e=>this.loadTheme(e)),this.loadLanguages(this._langs)}getTheme(e){return"string"==typeof e?this._resolvedThemes.get(e):this.loadTheme(e)}loadTheme(e){let t=aA(e);return t.name&&(this._resolvedThemes.set(t.name,t),this._loadedThemesCache=null),t}getLoadedThemes(){return!this._loadedThemesCache&&(this._loadedThemesCache=[...this._resolvedThemes.keys()]),this._loadedThemesCache}setTheme(e){let t=this._textmateThemeCache.get(e);!t&&(t=sz.createFromRawTheme(e),this._textmateThemeCache.set(e,t)),this._syncRegistry.setTheme(t)}getGrammar(e){if(this._alias[e]){let t=new Set([e]);for(;this._alias[e];){if(e=this._alias[e],t.has(e))throw new l7(`Circular alias \`${Array.from(t).join(" -> ")} -> ${e}\``);t.add(e)}}return this._resolvedGrammars.get(e)}loadLanguage(e){if(this.getGrammar(e.name))return;let t=new Set([...this._langMap.values()].filter(t=>t.embeddedLangsLazy?.includes(e.name)));this._resolver.addLanguage(e);let n={balancedBracketSelectors:e.balancedBracketSelectors||["*"],unbalancedBracketSelectors:e.unbalancedBracketSelectors||[]};this._syncRegistry._rawGrammars.set(e.scopeName,e);let r=this.loadGrammarWithConfiguration(e.scopeName,1,n);if(r.name=e.name,this._resolvedGrammars.set(e.name,r),e.aliases&&e.aliases.forEach(t=>{this._alias[t]=e.name}),this._loadedLanguagesCache=null,t.size)for(let e of t)this._resolvedGrammars.delete(e.name),this._loadedLanguagesCache=null,this._syncRegistry?._injectionGrammars?.delete(e.scopeName),this._syncRegistry?._grammars?.delete(e.scopeName),this.loadLanguage(this._langMap.get(e.name))}dispose(){super.dispose(),this._resolvedThemes.clear(),this._resolvedGrammars.clear(),this._langMap.clear(),this._langGraph.clear(),this._loadedThemesCache=null}loadLanguages(e){for(let t of e)this.resolveEmbeddedLanguages(t);let t=Array.from(this._langGraph.entries()),n=t.filter(([e,t])=>!t);if(n.length){let e=t.filter(([e,t])=>t&&t.embeddedLangs?.some(e=>n.map(([e])=>e).includes(e))).filter(e=>!n.includes(e));throw new l7(`Missing languages ${n.map(([e])=>`\`${e}\``).join(", ")}, required by ${e.map(([e])=>`\`${e}\``).join(", ")}`)}for(let[e,n]of t)this._resolver.addLanguage(n);for(let[e,n]of t)this.loadLanguage(n)}getLoadedLanguages(){return!this._loadedLanguagesCache&&(this._loadedLanguagesCache=[...new Set([...this._resolvedGrammars.keys(),...Object.keys(this._alias)])]),this._loadedLanguagesCache}resolveEmbeddedLanguages(e){if(this._langMap.set(e.name,e),this._langGraph.set(e.name,e),e.embeddedLangs)for(let t of e.embeddedLangs)this._langGraph.set(t,this._langMap.get(t))}}var aF=Object.defineProperty,aP=(e,t,n)=>t in e?aF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,aT=(e,t,n)=>(aP(e,"symbol"!=typeof t?t+"":t,n),n);class aN{constructor(e,t){aT(this,"_langs",new Map),aT(this,"_scopeToLang",new Map),aT(this,"_injections",new Map),aT(this,"_onigLib"),this._onigLib={createOnigScanner:t=>e.createScanner(t),createOnigString:t=>e.createString(t)},t.forEach(e=>this.addLanguage(e))}get onigLib(){return this._onigLib}getLangRegistration(e){return this._langs.get(e)}loadGrammar(e){return this._scopeToLang.get(e)}addLanguage(e){this._langs.set(e.name,e),e.aliases&&e.aliases.forEach(t=>{this._langs.set(t,e)}),this._scopeToLang.set(e.scopeName,e),e.injectTo&&e.injectTo.forEach(t=>{!this._injections.get(t)&&this._injections.set(t,[]),this._injections.get(t).push(e.scopeName)})}getInjections(e){let t=e.split("."),n=[];for(let e=1;e<=t.length;e++){let r=t.slice(0,e).join(".");n=[...n,...this._injections.get(r)||[]]}return n}}let aB=0;async function aI(e={}){e.loadWasm&&sN("`loadWasm` option is deprecated. Use `engine: createOnigurumaEngine(loadWasm)` instead.");let[t,n,r]=await Promise.all([aC(e.themes||[]),ax(e.langs||[]),e.engine||sT(e.loadWasm||s)]);return function(e){let t;aB+=1,!1!==e.warnings&&aB>=10&&aB%10==0&&console.warn(`[Shiki] ${aB} instances have been created. Shiki is supposed to be used as a singleton, consider refactoring your code to cache your highlighter instance; Or call \`highlighter.dispose()\` to release unused instances.`);let n=!1;if(!e.engine)throw new l7("`engine` option is required for synchronous mode");let r=(e.langs||[]).flat(1),i=(e.themes||[]).flat(1).map(aA),s=new aO(new aN(e.engine,r),i,r,e.langAlias);function o(e){if("none"===e)return{bg:"",fg:"",name:"none",settings:[],type:"dark"};u();let t=s.getTheme(e);if(!t)throw new l7(`Theme \`${e}\` not found, you may need to load it first`);return t}function l(...e){u(),s.loadLanguages(e.flat(1))}function a(...e){for(let t of(u(),e.flat(1)))s.loadTheme(t)}function u(){if(n)throw new l7("Shiki instance has been disposed")}function h(){!n&&(n=!0,s.dispose(),aB-=1)}return{setTheme:function(e){u();let n=o(e);return t!==e&&(s.setTheme(n),t=e),{theme:n,colorMap:s.getColorMap()}},getTheme:o,getLanguage:function(e){u();let t=s.getGrammar("string"==typeof e?e:e.name);if(!t)throw new l7(`Language \`${e}\` not found, you may need to load it first`);return t},getLoadedThemes:function(){return u(),s.getLoadedThemes()},getLoadedLanguages:function(){return u(),s.getLoadedLanguages()},loadLanguage:async function e(...t){return l(await ax(t))},loadLanguageSync:l,loadTheme:async function e(...t){return u(),a(await aC(t))},loadThemeSync:a,dispose:h,[Symbol.dispose]:h}}({...e,loadWasm:void 0,themes:t,langs:n,engine:r})}async function aM(e={}){let t=await aI(e);return{getLastGrammarState:(...e)=>(function(...e){if(2===e.length)return as(e[1]);let[t,n,r={}]=e,{lang:i="text",theme:s=t.getLoadedThemes()[0]}=r;if(l0(i)||l2(s))throw new sD("Plain language does not have grammar state");if("ansi"===i)throw new sD("ANSI language does not have grammar state");let{theme:o,colorMap:l}=t.setTheme(s),a=t.getLanguage(i);return new ao(am(n,a,o,l,r).stateStack,a.name,o.name)})(t,...e),codeToTokensBase:(e,n)=>ap(t,e,n),codeToTokensWithThemes:(e,n)=>ay(t,e,n),codeToTokens:(e,n)=>ab(t,e,n),codeToHast:(e,n)=>av(t,e,n),codeToHtml:(e,n)=>(function(e,t,n){let r={meta:{},options:n,codeToHast:(t,n)=>av(e,t,n),codeToTokens:(t,n)=>ab(e,t,n)},i=function(e,t){let n=lK,r=n.quote||'"';if('"'!==r&&"'"!==r)throw Error("Invalid quote `"+r+"`, expected `'` or `\"`");return({one:lY,all:lZ,settings:{omitOptionalTags:n.omitOptionalTags||!1,allowParseErrors:n.allowParseErrors||!1,allowDangerousCharacters:n.allowDangerousCharacters||!1,quoteSmart:n.quoteSmart||!1,preferUnquoted:n.preferUnquoted||!1,tightAttributes:n.tightAttributes||!1,upperDoctype:n.upperDoctype||!1,tightDoctype:n.tightDoctype||!1,bogusComments:n.bogusComments||!1,tightCommaSeparatedLists:n.tightCommaSeparatedLists||!1,tightSelfClosing:n.tightSelfClosing||!1,collapseEmptyAttributes:n.collapseEmptyAttributes||!1,allowDangerousHtml:n.allowDangerousHtml||!1,voids:n.voids||oj,characterReferences:n.characterReferences||lJ,closeSelfClosing:n.closeSelfClosing||!1,closeEmptyElements:n.closeEmptyElements||!1},schema:"svg"===n.space?li:lr,quote:r,alternative:'"'===r?"'":'"'}).one(Array.isArray(e)?{type:"root",children:e}:e,void 0,void 0)}(av(e,t,n,r));for(let e of au(n))i=e.postprocess?.call(r,i,n)||i;return i})(t,e,n),...t,getInternalContext:()=>t}}let a$=(k={langs:sk,themes:sw,engine:()=>sT(n.e("29778").then(n.bind(n,50755)))},a=k.langs,u=k.themes,h=k.engine,async function e(e){function t(e){if("string"==typeof e){if(l1(e))return[];let t=a[e];if(!t)throw new sD(`Language \`${e}\` is not included in this bundle. You may want to load it from external source.`);return t}return e}function n(e){if(l2(e))return"none";if("string"==typeof e){let t=u[e];if(!t)throw new sD(`Theme \`${e}\` is not included in this bundle. You may want to load it from external source.`);return t}return e}let r=(e.themes??[]).map(e=>n(e)),i=(e.langs??[]).map(e=>t(e)),s=await aM({engine:h(),...e,themes:r,langs:i});return{...s,loadLanguage:(...e)=>s.loadLanguage(...e.map(t)),loadTheme:(...e)=>s.loadTheme(...e.map(n))}});async function aL(e){let t=("themes"in e?Object.values(e.themes):[e.theme]).filter(Boolean),n=await a$({themes:t,langs:e.langs||Object.keys(sk)});return function(t){!function(e,t,n){let{parseMetaString:r,trimEndingNewline:i=!0,defaultLanguage:s="text",fallbackLanguage:o}=n,l=t.getLoadedLanguages();e.options.highlight=(e,a="text",u)=>{""===a&&(a=s),o&&!l.includes(a)&&(a=o);let h=r?.(u,e,a)||{},c={...n,lang:a,meta:{...n.meta,...h,__raw:u}},f=[];return f.push({name:"@shikijs/markdown-it:block-class",code(e){e.properties.class=`language-${a}`}}),i&&e.endsWith("\n")&&(e=e.slice(0,-1)),t.codeToHtml(e,{...c,transformers:[...f,...c.transformers||[]]})}}(t,n,e)}}let aR=sg({linkify:!0,typographer:!0});function aj(e,t=!0){return t?aR.renderInline(e):aR.render(e)}(async()=>{let e=await aL({themes:{light:"vitesse-light",dark:"vitesse-dark"}});aR.use(e)})();class aq{constructor(){this.completions=new Map,this.reservedKeys=new Set}reserve(e){this.reservedKeys.add(e)}add(e){if(!this.reservedKeys.has(e.label))this.completions.set(e.label,e)}}class aV{constructor(e){var t;this.opts=e,this.schema=null,this.mode=G.JSON,this.mode=null!==(t=e.mode)&&void 0!==t?t:G.JSON}doComplete(e){var t,n,r;let i=ey(e.state);if(this.schema=null!==(t=this.expandSchemaProperty(i,i))&&void 0!==t?t:i,!this.schema)return[];let s={from:e.pos,to:e.pos,options:[],filter:!1},o=e.state.doc.sliceString(0),l=Z(e.state,e.pos),a=e.state.sliceDoc(l.from,e.pos).replace(/^(["'])/,"");if(q.log("xxx","node",l,"prefix",a,"ctx",e),!(er(l,this.mode)||es(l,this.mode))&&!e.explicit)return q.log("xxx","no completions for non-word/primitive",l),s;let u=et(e.state.doc,l),h=et(e.state.doc,l,!1);if(l&&(er(l,this.mode)||es(l,this.mode)))s.from=l.from,s.to=l.to;else{let t=e.matchBefore(/[A-Za-z0-9._]*/),r=e.pos-u.length;q.log("xxx","overwriteStart after",r,"ctx.pos",e.pos,"word",t,"currentWord",u,"=>",o[r-1],"..",o[r],"..",o),s.from=l.name===V.INVALID?null!==(n=null==t?void 0:t.from)&&void 0!==n?n:e.pos:r,s.to=e.pos}let c=new aq,f=!0,d=ef(l,V.PROPERTY_NAME,this.mode);if(d&&(q.log("xxx","closestPropertyNameNode",d,"node",l),l=d),es(l,this.mode)){q.log("xxx","isPropertyNameNode",l);let e=l.parent;if(e){let t=eu(e,this.mode);f=!t||t.name===V.INVALID&&t.from-t.to==0||!!t.parent&&eo(t.parent).length<=1,q.log("xxx","addValue",f,eu(e,this.mode),l),l=null!==(r=ef(e,V.OBJECT,this.mode))&&void 0!==r?r:null}}if(q.log("xxx",l,u,e,"node at pos",Z(e.state,e.pos)),l&&[V.OBJECT,V.JSON_TEXT].includes(K(l.name,this.mode))&&(es(Z(e.state,e.pos),this.mode)||d)){if(l.from===e.pos)return q.log("xxx","no completions for just before opening brace"),s;this.getPropertyCompletions(this.schema,e,l,c,f,h)}else{let t=this.getValueCompletions(this.schema,e,{},c);q.log("xxx","getValueCompletions res",t)}return s.options=Array.from(c.completions.values()).filter(e=>X(e.label).startsWith(a)),q.log("xxx","result",s,"prefix",a,"collector.completions",c.completions,"reservedKeys",c.reservedKeys),s}applySnippetCompletion(e){return(0,R.Gn)("string"!=typeof e.apply?e.label:e.apply,e)}getPropertyCompletions(e,t,n,r,i,s){let o=el(n,V.PROPERTY,this.mode);q.log("xxx","getPropertyCompletions",n,t,o),o.forEach(e=>{let n=et(t.state.doc,ea(e,V.PROPERTY_NAME,this.mode));r.reserve(X(n))});let l=this.getSchemas(e,t);q.log("xxx","propertyCompletion schemas",l),l.forEach(e=>{if("object"!=typeof e)return;let t=e.properties;t&&Object.entries(t).forEach(([e,t])=>{var n,o;if("object"==typeof t){let l=null!==(n=t.description)&&void 0!==n?n:"",a=null!==(o=t.type)&&void 0!==o?o:"",u=Array.isArray(a)?a.toString():a,h={label:e,apply:this.getInsertTextForProperty(e,i,s,t),type:"property",detail:u,info:aj(l)};r.add(this.applySnippetCompletion(h))}});let n=e.propertyNames;if("object"==typeof n&&(n.enum&&n.enum.forEach(e=>{let t=null==e?void 0:e.toString();if(t){let e={label:t,apply:this.getInsertTextForProperty(t,i,s),type:"property"};r.add(this.applySnippetCompletion(e))}}),n.const)){let e=n.const.toString(),t={label:e,apply:this.getInsertTextForProperty(e,i,s),type:"property"};r.add(this.applySnippetCompletion(t))}})}getInsertTextForProperty(e,t,n,r){let i;r=r?this.expandSchemaProperty(r,this.schema):r;let s=this.getInsertTextForPropertyName(e,n);if(!t)return s;s+=": ";let o=0;if("object"==typeof r){if(void 0!==r.default)!i&&(i=this.getInsertTextForGuessedValue(r.default,"")),o++;else if(r.enum&&(!i&&1===r.enum.length&&(i=this.getInsertTextForGuessedValue(r.enum[0],"")),o+=r.enum.length),void 0!==r.const&&(!i&&(i=this.getInsertTextForGuessedValue(r.const,"")),o++),Array.isArray(r.examples)&&r.examples.length&&(!i&&(i=this.getInsertTextForGuessedValue(r.examples[0],"")),o+=r.examples.length),void 0===i&&0===o){let e=Array.isArray(r.type)?r.type[0]:r.type;switch(!e&&(r.properties?e="object":r.items&&(e="array")),e){case"boolean":i="#{}";break;case"string":i=this.getInsertTextForString("");break;case"object":switch(this.mode){case G.JSON5:i="{#{}}";break;case G.YAML:i="#{}";break;default:i="{#{}}"}break;case"array":i="[#{}]";break;case"number":case"integer":i="#{0}";break;case"null":i="#{null}";break;default:i="#{}"}}}return(!i||o>1)&&(q.log("xxx","value",i,"nValueProposals",o,r),i="#{}"),s+i}getInsertTextForPropertyName(e,t){switch(this.mode){case G.JSON5:case G.YAML:if(t.startsWith('"'))return`"${e}"`;if(t.startsWith("'"))return`'${e}'`;return e;default:return`"${e}"`}}getInsertTextForString(e,t="#"){switch(this.mode){case G.JSON5:return`'${t}{${e}}'`;case G.YAML:return`${t}{${e}}`;default:return`"${t}{${e}}"`}}getInsertTextForGuessedValue(e,t=""){switch(typeof e){case"object":if(null===e)return"${null}"+t;break;case"string":{let n=JSON.stringify(e);return n=n.substr(1,n.length-2),n=this.getInsertTextForPlainText(n),this.getInsertTextForString(n,"$")+t}case"number":case"boolean":return"${"+JSON.stringify(e)+"}"+t}return this.getInsertTextForValue(e,t)}getInsertTextForPlainText(e){return e.replace(/[\\$}]/g,"\\$&")}getInsertTextForValue(e,t){let n=JSON.stringify(e,null," ");return"{}"===n?"{#{}}"+t:"[]"===n?"[#{}]"+t:this.getInsertTextForPlainText(n+t)}getValueCompletions(e,t,n,r){let i,s=(0,j.qz)(t.state).resolveInner(t.pos,-1),o=null;if(q.log("xxx","getValueCompletions",s,t),s&&er(s,this.mode)&&(o=s,s=s.parent),!s){this.addSchemaValueCompletions(e,n,r);return}if(K(s.name,this.mode)===V.PROPERTY){let e=ea(s,V.PROPERTY_NAME,this.mode);e&&(i=et(t.state.doc,e),s=s.parent)}if(q.log("xxx","node",s,"parentKey",i),s&&(void 0!==i||K(s.name,this.mode)===V.ARRAY))for(let l of this.getSchemas(e,t)){if("object"!=typeof l)return;if(K(s.name,this.mode)===V.ARRAY&&l.items){let e=r;if(l.uniqueItems&&(e=Object.assign(Object.assign({},e),{add(t){!e.completions.has(t.label)&&r.add(t)},reserve(e){r.reserve(e)}})),Array.isArray(l.items)){let t=0;if(o){let e=ec(s,o,this.mode);e>=0&&(t=e)}let r=l.items[t];r&&this.addSchemaValueCompletions(r,n,e)}else this.addSchemaValueCompletions(l.items,n,e)}if(void 0!==i){let e=!1;if(l.properties){let t=l.properties[i];t&&(e=!0,this.addSchemaValueCompletions(t,n,r))}if(l.patternProperties&&!e)for(let t of Object.keys(l.patternProperties)){let s=this.extendedRegExp(t);if(null==s?void 0:s.test(i)){e=!0;let i=l.patternProperties[t];i&&this.addSchemaValueCompletions(i,n,r)}}if(l.additionalProperties&&!e){let e=l.additionalProperties;this.addSchemaValueCompletions(e,n,r)}}n.boolean&&(this.addBooleanValueCompletion(!0,r),this.addBooleanValueCompletion(!1,r)),n.null&&this.addNullValueCompletion(r)}return{valuePrefix:o?et(t.state.doc,o,!0,!1):""}}addSchemaValueCompletions(e,t,n){"object"==typeof e&&(this.addEnumValueCompletions(e,n),this.addDefaultValueCompletions(e,n),this.collectTypes(e,t),Array.isArray(e.allOf)&&e.allOf.forEach(e=>this.addSchemaValueCompletions(e,t,n)),Array.isArray(e.anyOf)&&e.anyOf.forEach(e=>this.addSchemaValueCompletions(e,t,n)),Array.isArray(e.oneOf)&&e.oneOf.forEach(e=>this.addSchemaValueCompletions(e,t,n)))}addDefaultValueCompletions(e,t,n=0){let r=!1;if(void 0!==e.default){let i=e.type,s=e.default;for(let e=n;e>0;e--)s=[s],i="array";let o=Object.assign(Object.assign({type:null==i?void 0:i.toString()},this.getAppliedValue(s)),{detail:"Default value"});t.add(o),r=!0}Array.isArray(e.examples)&&e.examples.forEach(i=>{let s=e.type,o=i;for(let e=n;e>0;e--)o=[o],s="array";t.add(Object.assign({type:null==s?void 0:s.toString()},this.getAppliedValue(o))),r=!0}),!r&&"object"==typeof e.items&&!Array.isArray(e.items)&&n<5&&this.addDefaultValueCompletions(e.items,t,n+1)}addEnumValueCompletions(e,t){var n,r;if(void 0!==e.const&&t.add(Object.assign(Object.assign({type:null===(n=e.type)||void 0===n?void 0:n.toString()},this.getAppliedValue(e.const)),{info:e.description})),Array.isArray(e.enum))for(let n=0,i=e.enum.length;n<i;n++){let i=e.enum[n];t.add(Object.assign(Object.assign({type:null===(r=e.type)||void 0===r?void 0:r.toString()},this.getAppliedValue(i)),{info:e.description}))}}addBooleanValueCompletion(e,t){t.add({type:"boolean",label:e?"true":"false"})}addNullValueCompletion(e){e.add({type:"null",label:"null"})}collectTypes(e,t){if(Array.isArray(e.enum)||void 0!==e.const)return;let n=e.type;Array.isArray(n)?n.forEach(e=>t[e]=!0):n&&(t[n]=!0)}getSchemas(e,t){var n,r;let i=new n9(this.schema),s=Q(t.state,t.pos,-1,this.mode),o=i.getSchema({pointer:s});return(eS(o)&&(o=null===(n=o.data)||void 0===n?void 0:n.schema),(!o||"UnknownPropertyError"===o.name||o.enum||"undefined"===o.type)&&(s=s.replace(/\/[^/]*$/,"/"),o=i.getSchema({pointer:s})),q.log("xxx","pointer..",JSON.stringify(s)),(!s||"/"===s)&&(o=null!==(r=this.expandSchemaProperty(e,e))&&void 0!==r?r:e),q.log("xxx","subSchema..",o),o)?Array.isArray(o.allOf)?[o,...o.allOf.map(t=>this.expandSchemaProperty(t,e))]:Array.isArray(o.oneOf)?[o,...o.oneOf.map(t=>this.expandSchemaProperty(t,e))]:Array.isArray(o.anyOf)?[o,...o.anyOf.map(t=>this.expandSchemaProperty(t,e))]:[o]:[]}expandSchemaProperty(e,t){if("object"==typeof e&&e.$ref){let n=this.getReferenceSchema(t,e.$ref);if("object"==typeof n){let t=Object.assign(Object.assign({},e),n);return Reflect.deleteProperty(t,"$ref"),t}}return e}getReferenceSchema(e,t){let n=t.split("/"),r=e;return n.forEach(t=>{if(!!t){if("#"===t){r=e;return}"object"==typeof r&&(r=r[t])}}),r}getAppliedValue(e){let t=X(JSON.stringify(e));switch(this.mode){case G.JSON5:return{label:t,apply:ee(JSON.stringify(e))};case G.YAML:return{label:t,apply:t};default:return{label:t,apply:JSON.stringify(e)}}}getValueFromLabel(e){return JSON.parse(e)}extendedRegExp(e){let t="";e.startsWith("(?i)")&&(e=e.substring(4),t="i");try{return RegExp(e,t+"u")}catch(n){try{return new RegExp(e,t)}catch(e){return}}}}let az=(e,t)=>{let n=e.length>2,r=e.map((n,r)=>{let i="`"+(t?t(n):n)+"`";return r===e.length-1?"or "+i:i});return n?r.join(", "):r.join(" ")};function aU(e){let t=null;try{t=JSON.parse(e.doc.toString())}catch(e){}return{data:t,pointers:Y(e,G.JSON)}}function aH(e,t,n=[]){let r=document.createElement(e);return Object.entries(t).forEach(([e,t])=>{if("text"===e){r.innerText=t;return}if("inner"===e){r.innerHTML=t;return}r.setAttribute(e,t)}),n.forEach(e=>r.appendChild(e)),r}let aW=Symbol.for("yaml.alias"),aG=Symbol.for("yaml.document"),aK=Symbol.for("yaml.map"),aJ=Symbol.for("yaml.pair"),aQ=Symbol.for("yaml.scalar"),aY=Symbol.for("yaml.seq"),aZ=Symbol.for("yaml.node.type"),aX=e=>!!e&&"object"==typeof e&&e[aZ]===aW,a0=e=>!!e&&"object"==typeof e&&e[aZ]===aG,a1=e=>!!e&&"object"==typeof e&&e[aZ]===aK,a2=e=>!!e&&"object"==typeof e&&e[aZ]===aJ,a3=e=>!!e&&"object"==typeof e&&e[aZ]===aQ,a5=e=>!!e&&"object"==typeof e&&e[aZ]===aY;function a8(e){if(e&&"object"==typeof e)switch(e[aZ]){case aK:case aY:return!0}return!1}function a4(e){if(e&&"object"==typeof e)switch(e[aZ]){case aW:case aK:case aQ:case aY:return!0}return!1}let a6=e=>(a3(e)||a8(e))&&!!e.anchor,a9=Symbol("break visit"),a7=Symbol("skip children"),ue=Symbol("remove node");function ut(e,t){let n=us(t);a0(e)?un(null,e.contents,n,Object.freeze([e]))===ue&&(e.contents=null):un(null,e,n,Object.freeze([]))}function un(e,t,n,r){let i=uo(e,t,n,r);if(a4(i)||a2(i))return ul(e,r,i),un(e,i,n,r);if("symbol"!=typeof i){if(a8(t)){r=Object.freeze(r.concat(t));for(let e=0;e<t.items.length;++e){let i=un(e,t.items[e],n,r);if("number"==typeof i)e=i-1;else{if(i===a9)return a9;i===ue&&(t.items.splice(e,1),e-=1)}}}else if(a2(t)){r=Object.freeze(r.concat(t));let e=un("key",t.key,n,r);if(e===a9)return a9;e===ue&&(t.key=null);let i=un("value",t.value,n,r);if(i===a9)return a9;i===ue&&(t.value=null)}}return i}async function ur(e,t){let n=us(t);a0(e)?await ui(null,e.contents,n,Object.freeze([e]))===ue&&(e.contents=null):await ui(null,e,n,Object.freeze([]))}async function ui(e,t,n,r){let i=await uo(e,t,n,r);if(a4(i)||a2(i))return ul(e,r,i),ui(e,i,n,r);if("symbol"!=typeof i){if(a8(t)){r=Object.freeze(r.concat(t));for(let e=0;e<t.items.length;++e){let i=await ui(e,t.items[e],n,r);if("number"==typeof i)e=i-1;else{if(i===a9)return a9;i===ue&&(t.items.splice(e,1),e-=1)}}}else if(a2(t)){r=Object.freeze(r.concat(t));let e=await ui("key",t.key,n,r);if(e===a9)return a9;e===ue&&(t.key=null);let i=await ui("value",t.value,n,r);if(i===a9)return a9;i===ue&&(t.value=null)}}return i}function us(e){return"object"==typeof e&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function uo(e,t,n,r){return"function"==typeof n?n(e,t,r):a1(t)?n.Map?.(e,t,r):a5(t)?n.Seq?.(e,t,r):a2(t)?n.Pair?.(e,t,r):a3(t)?n.Scalar?.(e,t,r):aX(t)?n.Alias?.(e,t,r):void 0}function ul(e,t,n){let r=t[t.length-1];if(a8(r))r.items[e]=n;else if(a2(r))"key"===e?r.key=n:r.value=n;else if(a0(r))r.contents=n;else{let e=aX(r)?"alias":"scalar";throw Error(`Cannot replace node with ${e} parent`)}}ut.BREAK=a9,ut.SKIP=a7,ut.REMOVE=ue,ur.BREAK=a9,ur.SKIP=a7,ur.REMOVE=ue;let ua={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},uu=e=>e.replace(/[!,[\]{}]/g,e=>ua[e]);class uh{constructor(e,t){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},uh.defaultYaml,e),this.tags=Object.assign({},uh.defaultTags,t)}clone(){let e=new uh(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){let e=new uh(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:uh.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},uh.defaultTags)}return e}add(e,t){this.atNextDocument&&(this.yaml={explicit:uh.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},uh.defaultTags),this.atNextDocument=!1);let n=e.trim().split(/[ \t]+/),r=n.shift();switch(r){case"%TAG":{if(2!==n.length&&(t(0,"%TAG directive should contain exactly two parts"),n.length<2))return!1;let[e,r]=n;return this.tags[e]=r,!0}case"%YAML":{if(this.yaml.explicit=!0,1!==n.length)return t(0,"%YAML directive should contain exactly one part"),!1;let[e]=n;if("1.1"===e||"1.2"===e)return this.yaml.version=e,!0;{let n=/^\d+\.\d+$/.test(e);return t(6,`Unsupported YAML version ${e}`,n),!1}}default:return t(0,`Unknown directive ${r}`,!0),!1}}tagName(e,t){if("!"===e)return"!";if("!"!==e[0])return t(`Not a valid tag: ${e}`),null;if("<"===e[1]){let n=e.slice(2,-1);return"!"===n||"!!"===n?(t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(">"!==e[e.length-1]&&t("Verbatim tags must end with a >"),n)}let[,n,r]=e.match(/^(.*!)([^!]*)$/s);!r&&t(`The ${e} tag has no suffix`);let i=this.tags[n];if(i)try{return i+decodeURIComponent(r)}catch(e){return t(String(e)),null}return"!"===n?e:(t(`Could not resolve tag: ${e}`),null)}tagString(e){for(let[t,n]of Object.entries(this.tags))if(e.startsWith(n))return t+uu(e.substring(n.length));return"!"===e[0]?e:`!<${e}>`}toString(e){let t;let n=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],r=Object.entries(this.tags);if(e&&r.length>0&&a4(e.contents)){let n={};ut(e.contents,(e,t)=>{a4(t)&&t.tag&&(n[t.tag]=!0)}),t=Object.keys(n)}else t=[];for(let[i,s]of r)("!!"!==i||"tag:yaml.org,2002:"!==s)&&(!e||t.some(e=>e.startsWith(s)))&&n.push(`%TAG ${i} ${s}`);return n.join("\n")}}function uc(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let t=JSON.stringify(e);throw Error(`Anchor must not contain whitespace or control characters: ${t}`)}return!0}function uf(e){let t=new Set;return ut(e,{Value(e,n){n.anchor&&t.add(n.anchor)}}),t}function ud(e,t){for(let n=1;;++n){let r=`${e}${n}`;if(!t.has(r))return r}}uh.defaultYaml={explicit:!1,version:"1.2"},uh.defaultTags={"!!":"tag:yaml.org,2002:"};function up(e,t,n,r){if(r&&"object"==typeof r){if(Array.isArray(r))for(let t=0,n=r.length;t<n;++t){let n=r[t],i=up(e,r,String(t),n);void 0===i?delete r[t]:i!==n&&(r[t]=i)}else if(r instanceof Map)for(let t of Array.from(r.keys())){let n=r.get(t),i=up(e,r,t,n);void 0===i?r.delete(t):i!==n&&r.set(t,i)}else if(r instanceof Set)for(let t of Array.from(r)){let n=up(e,r,t,t);void 0===n?r.delete(t):n!==t&&(r.delete(t),r.add(n))}else for(let[t,n]of Object.entries(r)){let i=up(e,r,t,n);void 0===i?delete r[t]:i!==n&&(r[t]=i)}}return e.call(t,n,r)}function um(e,t,n){if(Array.isArray(e))return e.map((e,t)=>um(e,String(t),n));if(e&&"function"==typeof e.toJSON){if(!n||!a6(e))return e.toJSON(t,n);let r={aliasCount:0,count:1,res:void 0};n.anchors.set(e,r),n.onCreate=e=>{r.res=e,delete n.onCreate};let i=e.toJSON(t,n);return n.onCreate&&n.onCreate(i),i}return"bigint"!=typeof e||n?.keep?e:Number(e)}class ug{constructor(e){Object.defineProperty(this,aZ,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:t,maxAliasCount:n,onAnchor:r,reviver:i}={}){if(!a0(e))throw TypeError("A document argument is required");let s={anchors:new Map,doc:e,keep:!0,mapAsMap:!0===t,mapKeyWarned:!1,maxAliasCount:"number"==typeof n?n:100},o=um(this,"",s);if("function"==typeof r)for(let{count:e,res:t}of s.anchors.values())r(t,e);return"function"==typeof i?up(i,{"":o},"",o):o}}class uy extends ug{constructor(e){super(aW),this.source=e,Object.defineProperty(this,"tag",{set(){throw Error("Alias nodes cannot have tags")}})}resolve(e){let t;return ut(e,{Node:(e,n)=>{if(n===this)return ut.BREAK;n.anchor===this.source&&(t=n)}}),t}toJSON(e,t){if(!t)return{source:this.source};let{anchors:n,doc:r,maxAliasCount:i}=t,s=this.resolve(r);if(!s)throw ReferenceError(`Unresolved alias (the anchor must be set before the alias): ${this.source}`);let o=n.get(s);if(!o&&(um(s,null,t),o=n.get(s)),!o||void 0===o.res)throw ReferenceError("This should not happen: Alias anchor was not resolved?");if(i>=0&&(o.count+=1,0===o.aliasCount&&(o.aliasCount=function e(t,n,r){if(aX(n)){let e=n.resolve(t),i=r&&e&&r.get(e);return i?i.count*i.aliasCount:0}if(a8(n)){let i=0;for(let s of n.items){let n=e(t,s,r);n>i&&(i=n)}return i}if(a2(n)){let i=e(t,n.key,r);return Math.max(i,e(t,n.value,r))}return 1}(r,s,n)),o.count*o.aliasCount>i))throw ReferenceError("Excessive alias count indicates a resource exhaustion attack");return o.res}toString(e,t,n){let r=`*${this.source}`;if(e){if(uc(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source))throw Error(`Unresolved alias (the anchor must be set before the alias): ${this.source}`);if(e.implicitKey)return`${r} `}return r}}let ub=e=>!e||"function"!=typeof e&&"object"!=typeof e;class uv extends ug{constructor(e){super(aQ),this.value=e}toJSON(e,t){return t?.keep?this.value:um(this.value,e,t)}toString(){return String(this.value)}}uv.BLOCK_FOLDED="BLOCK_FOLDED",uv.BLOCK_LITERAL="BLOCK_LITERAL",uv.PLAIN="PLAIN",uv.QUOTE_DOUBLE="QUOTE_DOUBLE",uv.QUOTE_SINGLE="QUOTE_SINGLE";function uk(e,t,n){let r;if(a0(e)&&(e=e.contents),a4(e))return e;if(a2(e)){let t=n.schema[aK].createNode?.(n.schema,null,n);return t.items.push(e),t}(e instanceof String||e instanceof Number||e instanceof Boolean||"undefined"!=typeof BigInt&&e instanceof BigInt)&&(e=e.valueOf());let{aliasDuplicateObjects:i,onAnchor:s,onTagObj:o,schema:l,sourceObjects:a}=n;if(i&&e&&"object"==typeof e){if(r=a.get(e))return!r.anchor&&(r.anchor=s(e)),new uy(r.anchor);r={anchor:null,node:null},a.set(e,r)}t?.startsWith("!!")&&(t="tag:yaml.org,2002:"+t.slice(2));let u=function(e,t,n){if(t){let e=n.filter(e=>e.tag===t),r=e.find(e=>!e.format)??e[0];if(!r)throw Error(`Tag ${t} not found`);return r}return n.find(t=>t.identify?.(e)&&!t.format)}(e,t,l.tags);if(!u){if(e&&"function"==typeof e.toJSON&&(e=e.toJSON()),!e||"object"!=typeof e){let t=new uv(e);return r&&(r.node=t),t}u=e instanceof Map?l[aK]:Symbol.iterator in Object(e)?l[aY]:l[aK]}o&&(o(u),delete n.onTagObj);let h=u?.createNode?u.createNode(n.schema,e,n):"function"==typeof u?.nodeClass?.from?u.nodeClass.from(n.schema,e,n):new uv(e);return t?h.tag=t:!u.default&&(h.tag=u.tag),r&&(r.node=h),h}function uw(e,t,n){let r=n;for(let e=t.length-1;e>=0;--e){let n=t[e];if("number"==typeof n&&Number.isInteger(n)&&n>=0){let e=[];e[n]=r,r=e}else r=new Map([[n,r]])}return uk(r,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error("This should not happen, please report a bug.")},schema:e,sourceObjects:new Map})}let uD=e=>null==e||"object"==typeof e&&!!e[Symbol.iterator]().next().done;class uA extends ug{constructor(e,t){super(e),Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(t.schema=e),t.items=t.items.map(t=>a4(t)||a2(t)?t.clone(e):t),this.range&&(t.range=this.range.slice()),t}addIn(e,t){if(uD(e))this.add(t);else{let[n,...r]=e,i=this.get(n,!0);if(a8(i))i.addIn(r,t);else if(void 0===i&&this.schema)this.set(n,uw(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){let[t,...n]=e;if(0===n.length)return this.delete(t);let r=this.get(t,!0);if(a8(r))return r.deleteIn(n);throw Error(`Expected YAML collection at ${t}. Remaining path: ${n}`)}getIn(e,t){let[n,...r]=e,i=this.get(n,!0);return 0===r.length?!t&&a3(i)?i.value:i:a8(i)?i.getIn(r,t):void 0}hasAllNullValues(e){return this.items.every(t=>{if(!a2(t))return!1;let n=t.value;return null==n||e&&a3(n)&&null==n.value&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){let[t,...n]=e;if(0===n.length)return this.has(t);let r=this.get(t,!0);return!!a8(r)&&r.hasIn(n)}setIn(e,t){let[n,...r]=e;if(0===r.length)this.set(n,t);else{let e=this.get(n,!0);if(a8(e))e.setIn(r,t);else if(void 0===e&&this.schema)this.set(n,uw(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}}uA.maxFlowStringSingleLineLength=60;let ux=e=>e.replace(/^(?!$)(?: $)?/gm,"#");function uC(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}let uE=(e,t,n)=>e.endsWith("\n")?uC(n,t):n.includes("\n")?"\n"+uC(n,t):(e.endsWith(" ")?"":" ")+n,uS="flow",u_="block",uO="quoted";function uF(e,t,n="flow",{indentAtStart:r,lineWidth:i=80,minContentWidth:s=20,onFold:o,onOverflow:l}={}){let a,u,h;if(!i||i<0)return e;let c=Math.max(1+s,1+i-t.length);if(e.length<=c)return e;let f=[],d={},p=i-t.length;"number"==typeof r&&(r>i-Math.max(2,s)?f.push(0):p=i-r);let m=!1,g=-1,y=-1,b=-1;n===u_&&-1!==(g=uP(e,g,t.length))&&(p=g+c);for(;h=e[g+=1];){if(n===uO&&"\\"===h){switch(y=g,e[g+1]){case"x":g+=3;break;case"u":g+=5;break;case"U":g+=9;break;default:g+=1}b=g}if("\n"===h)n===u_&&(g=uP(e,g,t.length)),p=g+t.length+c,a=void 0;else{if(" "===h&&u&&" "!==u&&"\n"!==u&&" "!==u){let t=e[g+1];t&&" "!==t&&"\n"!==t&&" "!==t&&(a=g)}if(g>=p){if(a)f.push(a),p=a+c,a=void 0;else if(n===uO){for(;" "===u||" "===u;)u=h,h=e[g+=1],m=!0;let t=g>b+1?g-2:y-1;if(d[t])return e;f.push(t),d[t]=!0,p=t+c,a=void 0}else m=!0}}u=h}if(m&&l&&l(),0===f.length)return e;o&&o();let v=e.slice(0,f[0]);for(let r=0;r<f.length;++r){let i=f[r],s=f[r+1]||e.length;0===i?v=`
|
|
33
|
-
${t}${e.slice(0,s)}`:(n===uO&&d[i]&&(v+=`${e[i]}\\`),v+=`
|
|
34
|
-
${t}${e.slice(i+1,s)}`)}return v}function uP(e,t,n){let r=t,i=t+1,s=e[i];for(;" "===s||" "===s;)if(t<i+n)s=e[++t];else{do s=e[++t];while(s&&"\n"!==s);r=t,s=e[i=t+1]}return r}let uT=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),uN=e=>/^(%|---|\.\.\.)/m.test(e);function uB(e,t){let n=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return n;let{implicitKey:r}=t,i=t.options.doubleQuotedMinMultiLineLength,s=t.indent||(uN(e)?" ":""),o="",l=0;for(let e=0,t=n[e];t;t=n[++e])if(" "===t&&"\\"===n[e+1]&&"n"===n[e+2]&&(o+=n.slice(l,e)+"\\ ",e+=1,l=e,t="\\"),"\\"===t)switch(n[e+1]){case"u":{o+=n.slice(l,e);let t=n.substr(e+2,4);switch(t){case"0000":o+="\\0";break;case"0007":o+="\\a";break;case"000b":o+="\\v";break;case"001b":o+="\\e";break;case"0085":o+="\\N";break;case"00a0":o+="\\_";break;case"2028":o+="\\L";break;case"2029":o+="\\P";break;default:"00"===t.substr(0,2)?o+="\\x"+t.substr(2):o+=n.substr(e,6)}e+=5,l=e+1}break;case"n":if(r||'"'===n[e+2]||n.length<i)e+=1;else{for(o+=n.slice(l,e)+"\n\n";"\\"===n[e+2]&&"n"===n[e+3]&&'"'!==n[e+4];)o+="\n",e+=2;o+=s," "===n[e+2]&&(o+="\\"),e+=1,l=e+1}break;default:e+=1}return o=l?o+n.slice(l):n,r?o:uF(o,s,uO,uT(t,!1))}function uI(e,t){if(!1===t.options.singleQuote||t.implicitKey&&e.includes("\n")||/[ \t]\n|\n[ \t]/.test(e))return uB(e,t);let n=t.indent||(uN(e)?" ":""),r="'"+e.replace(/'/g,"''").replace(/\n+/g,`$&
|
|
35
|
-
${n}`)+"'";return t.implicitKey?r:uF(r,n,uS,uT(t,!1))}function uM(e,t){let n;let{singleQuote:r}=t.options;if(!1===r)n=uB;else{let t=e.includes('"'),i=e.includes("'");n=t&&!i?uI:i&&!t?uB:r?uI:uB}return n(e,t)}try{l=RegExp("(^|(?<!\n))\n+(?!\n|$)","g")}catch{l=/\n+(?!\n|$)/g}function u$({comment:e,type:t,value:n},r,i,s){let o,a,u;let{blockQuote:h,commentString:c,lineWidth:f}=r.options;if(!h||/\n[\t ]+$/.test(n)||/^\s*$/.test(n))return uM(n,r);let d=r.indent||(r.forceBlockIndent||uN(n)?" ":""),p="literal"===h||"folded"!==h&&t!==uv.BLOCK_FOLDED&&(t===uv.BLOCK_LITERAL||!function(e,t,n){if(!t||t<0)return!1;let r=t-n,i=e.length;if(i<=r)return!1;for(let t=0,n=0;t<i;++t)if("\n"===e[t]){if(t-n>r)return!0;if(i-(n=t+1)<=r)return!1}return!0}(n,f,d.length));if(!n)return p?"|\n":">\n";for(a=n.length;a>0;--a){let e=n[a-1];if("\n"!==e&&" "!==e&&" "!==e)break}let m=n.substring(a),g=m.indexOf("\n");-1===g?o="-":n===m||g!==m.length-1?(o="+",s&&s()):o="",m&&(n=n.slice(0,-m.length),"\n"===m[m.length-1]&&(m=m.slice(0,-1)),m=m.replace(l,`$&${d}`));let y=!1,b=-1;for(u=0;u<n.length;++u){let e=n[u];if(" "===e)y=!0;else if("\n"===e)b=u;else break}let v=n.substring(0,b<u?b+1:u);v&&(n=n.substring(v.length),v=v.replace(/\n+/g,`$&${d}`));let k=d?"2":"1",w=(p?"|":">")+(y?k:"")+o;if(e&&(w+=" "+c(e.replace(/ ?[\r\n]+/g," ")),i&&i()),p)return n=n.replace(/\n+/g,`$&${d}`),`${w}
|
|
36
|
-
${d}${v}${n}${m}`;n=n.replace(/\n+/g,"\n$&").replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${d}`);let D=uF(`${v}${n}${m}`,d,u_,uT(r,!0));return`${w}
|
|
37
|
-
${d}${D}`}function uL(e,t,n,r){let{implicitKey:i,inFlow:s}=t,o="string"==typeof e.value?e:Object.assign({},e,{value:String(e.value)}),{type:l}=e;l!==uv.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(l=uv.QUOTE_DOUBLE);let a=e=>{switch(e){case uv.BLOCK_FOLDED:case uv.BLOCK_LITERAL:return i||s?uM(o.value,t):u$(o,t,n,r);case uv.QUOTE_DOUBLE:return uB(o.value,t);case uv.QUOTE_SINGLE:return uI(o.value,t);case uv.PLAIN:return function(e,t,n,r){let{type:i,value:s}=e,{actualString:o,implicitKey:l,indent:a,indentStep:u,inFlow:h}=t;if(l&&s.includes("\n")||h&&/[[\]{},]/.test(s))return uM(s,t);if(!s||/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(s))return l||h||!s.includes("\n")?uM(s,t):u$(e,t,n,r);if(!l&&!h&&i!==uv.PLAIN&&s.includes("\n"))return u$(e,t,n,r);if(uN(s)){if(""===a)return t.forceBlockIndent=!0,u$(e,t,n,r);if(l&&a===u)return uM(s,t)}let c=s.replace(/\n+/g,`$&
|
|
38
|
-
${a}`);if(o){let e=e=>e.default&&"tag:yaml.org,2002:str"!==e.tag&&e.test?.test(c),{compat:n,tags:r}=t.doc.schema;if(r.some(e)||n?.some(e))return uM(s,t)}return l?c:uF(c,a,uS,uT(t,!1))}(o,t,n,r);default:return null}},u=a(l);if(null===u){let{defaultKeyType:e,defaultStringType:n}=t.options,r=i&&e||n;if(null===(u=a(r)))throw Error(`Unsupported default string type ${r}`)}return u}function uR(e,t){let n;let r=Object.assign({blockQuote:!0,commentString:ux,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},e.schema.toStringOptions,t);switch(r.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:e,flowCollectionPadding:r.flowCollectionPadding?" ":"",indent:"",indentStep:"number"==typeof r.indent?" ".repeat(r.indent):" ",inFlow:n,options:r}}function uj(e,t,n,r){let i;if(a2(e))return e.toString(t,n,r);if(aX(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw TypeError("Cannot stringify circular structure without alias nodes");t.resolvedAliases?t.resolvedAliases.add(e):t.resolvedAliases=new Set([e]),e=e.resolve(t.doc)}let s=a4(e)?e:t.doc.createNode(e,{onTagObj:e=>i=e});!i&&(i=function(e,t){let n,r;if(t.tag){let n=e.filter(e=>e.tag===t.tag);if(n.length>0)return n.find(e=>e.format===t.format)??n[0]}if(a3(t)){n=t.value;let i=e.filter(e=>e.identify?.(n));r=i.find(e=>e.format===t.format)??i.find(e=>!e.format)}else n=t,r=e.find(e=>e.nodeClass&&n instanceof e.nodeClass);if(!r){let e=n?.constructor?.name??typeof n;throw Error(`Tag not resolved for ${e} value`)}return r}(t.doc.schema.tags,s));let o=function(e,t,{anchors:n,doc:r}){if(!r.directives)return"";let i=[],s=(a3(e)||a8(e))&&e.anchor;s&&uc(s)&&(n.add(s),i.push(`&${s}`));let o=e.tag?e.tag:t.default?null:t.tag;return o&&i.push(r.directives.tagString(o)),i.join(" ")}(s,i,t);o.length>0&&(t.indentAtStart=(t.indentAtStart??0)+o.length+1);let l="function"==typeof i.stringify?i.stringify(s,t,n,r):a3(s)?uL(s,t,n,r):s.toString(t,n,r);return o?a3(s)||"{"===l[0]||"["===l[0]?`${o} ${l}`:`${o}
|
|
39
|
-
${t.indent}${l}`:l}function uq(e,t){("debug"===e||"warn"===e)&&("undefined"!=typeof process&&process.emitWarning?process.emitWarning(t):console.warn(t))}function uV(e,t,{key:n,value:r}){if(e?.doc.schema.merge&&uz(n)){if(a5(r=aX(r)?r.resolve(e.doc):r))for(let n of r.items)uU(e,t,n);else if(Array.isArray(r))for(let n of r)uU(e,t,n);else uU(e,t,r)}else{let i=um(n,"",e);if(t instanceof Map)t.set(i,um(r,i,e));else if(t instanceof Set)t.add(i);else{let s=function(e,t,n){if(null===t)return"";if("object"!=typeof t)return String(t);if(a4(e)&&n?.doc){let t=uR(n.doc,{});for(let e of(t.anchors=new Set,n.anchors.keys()))t.anchors.add(e.anchor);t.inFlow=!0,t.inStringifyKey=!0;let r=e.toString(t);if(!n.mapKeyWarned){let e=JSON.stringify(r);e.length>40&&(e=e.substring(0,36)+'..."'),uq(n.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${e}. Set mapAsMap: true to use object keys.`),n.mapKeyWarned=!0}return r}return JSON.stringify(t)}(n,i,e),o=um(r,s,e);s in t?Object.defineProperty(t,s,{value:o,writable:!0,enumerable:!0,configurable:!0}):t[s]=o}}return t}let uz=e=>"<<"===e||a3(e)&&"<<"===e.value&&(!e.type||e.type===uv.PLAIN);function uU(e,t,n){let r=e&&aX(n)?n.resolve(e.doc):n;if(!a1(r))throw Error("Merge sources must be maps or map aliases");for(let[n,i]of r.toJSON(null,e,Map))t instanceof Map?!t.has(n)&&t.set(n,i):t instanceof Set?t.add(n):!Object.prototype.hasOwnProperty.call(t,n)&&Object.defineProperty(t,n,{value:i,writable:!0,enumerable:!0,configurable:!0});return t}function uH(e,t,n){let r=uk(e,void 0,n);return new uW(r,uk(t,void 0,n))}class uW{constructor(e,t=null){Object.defineProperty(this,aZ,{value:aJ}),this.key=e,this.value=t}clone(e){let{key:t,value:n}=this;return a4(t)&&(t=t.clone(e)),a4(n)&&(n=n.clone(e)),new uW(t,n)}toJSON(e,t){let n=t?.mapAsMap?new Map:{};return uV(t,n,this)}toString(e,t,n){return e?.doc?function({key:e,value:t},n,r,i){let s,o,l;let{allNullValues:a,doc:u,indent:h,indentStep:c,options:{commentString:f,indentSeq:d,simpleKeys:p}}=n,m=a4(e)&&e.comment||null;if(p){if(m)throw Error("With simple keys, key nodes cannot have comments");if(a8(e))throw Error("With simple keys, collection cannot be used as a key value")}let g=!p&&(!e||m&&null==t&&!n.inFlow||a8(e)||(a3(e)?e.type===uv.BLOCK_FOLDED||e.type===uv.BLOCK_LITERAL:"object"==typeof e));n=Object.assign({},n,{allNullValues:!1,implicitKey:!g&&(p||!a),indent:h+c});let y=!1,b=!1,v=uj(e,n,()=>y=!0,()=>b=!0);if(!g&&!n.inFlow&&v.length>1024){if(p)throw Error("With simple keys, single line scalar must not span more than 1024 characters");g=!0}if(n.inFlow){if(a||null==t)return y&&r&&r(),""===v?"?":g?`? ${v}`:v}else if(a&&!p||null==t&&g)return v=`? ${v}`,m&&!y?v+=uE(v,n.indent,f(m)):b&&i&&i(),v;y&&(m=null),g?(m&&(v+=uE(v,n.indent,f(m))),v=`? ${v}
|
|
40
|
-
${h}:`):(v=`${v}:`,m&&(v+=uE(v,n.indent,f(m)))),a4(t)?(s=!!t.spaceBefore,o=t.commentBefore,l=t.comment):(s=!1,o=null,l=null,t&&"object"==typeof t&&(t=u.createNode(t))),n.implicitKey=!1,!g&&!m&&a3(t)&&(n.indentAtStart=v.length+1),b=!1,!d&&c.length>=2&&!n.inFlow&&!g&&a5(t)&&!t.flow&&!t.tag&&!t.anchor&&(n.indent=n.indent.substring(2));let k=!1,w=uj(t,n,()=>k=!0,()=>b=!0),D=" ";if(m||s||o){if(D=s?"\n":"",o){let e=f(o);D+=`
|
|
41
|
-
${uC(e,n.indent)}`}""!==w||n.inFlow?D+=`
|
|
42
|
-
${n.indent}`:"\n"===D&&(D="\n\n")}else if(!g&&a8(t)){let e=w[0],r=w.indexOf("\n"),i=-1!==r,s=n.inFlow??t.flow??0===t.items.length;if(i||!s){let t=!1;if(i&&("&"===e||"!"===e)){let n=w.indexOf(" ");"&"===e&&-1!==n&&n<r&&"!"===w[n+1]&&(n=w.indexOf(" ",n+1)),(-1===n||r<n)&&(t=!0)}!t&&(D=`
|
|
43
|
-
${n.indent}`)}}else(""===w||"\n"===w[0])&&(D="");return v+=D+w,n.inFlow?k&&r&&r():l&&!k?v+=uE(v,n.indent,f(l)):b&&i&&i(),v}(this,e,t,n):JSON.stringify(this)}}function uG(e,t,n){let r=t.inFlow??e.flow;return(r?uJ:uK)(e,t,n)}function uK({comment:e,items:t},n,{blockItemPrefix:r,flowChars:i,itemIndent:s,onChompKeep:o,onComment:l}){let a;let{indent:u,options:{commentString:h}}=n,c=Object.assign({},n,{indent:s,type:null}),f=!1,d=[];for(let e=0;e<t.length;++e){let i=t[e],o=null;if(a4(i))!f&&i.spaceBefore&&d.push(""),uQ(n,d,i.commentBefore,f),i.comment&&(o=i.comment);else if(a2(i)){let e=a4(i.key)?i.key:null;e&&(!f&&e.spaceBefore&&d.push(""),uQ(n,d,e.commentBefore,f))}f=!1;let l=uj(i,c,()=>o=null,()=>f=!0);o&&(l+=uE(l,s,h(o))),f&&o&&(f=!1),d.push(r+l)}if(0===d.length)a=i.start+i.end;else{a=d[0];for(let e=1;e<d.length;++e){let t=d[e];a+=t?`
|
|
44
|
-
${u}${t}`:"\n"}}return e?(a+="\n"+uC(h(e),u),l&&l()):f&&o&&o(),a}function uJ({items:e},t,{flowChars:n,itemIndent:r}){let{indent:i,indentStep:s,flowCollectionPadding:o,options:{commentString:l}}=t,a=Object.assign({},t,{indent:r+=s,inFlow:!0,type:null}),u=!1,h=0,c=[];for(let n=0;n<e.length;++n){let i=e[n],s=null;if(a4(i))i.spaceBefore&&c.push(""),uQ(t,c,i.commentBefore,!1),i.comment&&(s=i.comment);else if(a2(i)){let e=a4(i.key)?i.key:null;e&&(e.spaceBefore&&c.push(""),uQ(t,c,e.commentBefore,!1),e.comment&&(u=!0));let n=a4(i.value)?i.value:null;n?(n.comment&&(s=n.comment),n.commentBefore&&(u=!0)):null==i.value&&e?.comment&&(s=e.comment)}s&&(u=!0);let o=uj(i,a,()=>s=null);n<e.length-1&&(o+=","),s&&(o+=uE(o,r,l(s))),!u&&(c.length>h||o.includes("\n"))&&(u=!0),c.push(o),h=c.length}let{start:f,end:d}=n;if(0===c.length)return f+d;if(!u){let e=c.reduce((e,t)=>e+t.length+2,2);u=t.options.lineWidth>0&&e>t.options.lineWidth}if(!u)return`${f}${o}${c.join(" ")}${o}${d}`;{let e=f;for(let t of c)e+=t?`
|
|
45
|
-
${s}${i}${t}`:"\n";return`${e}
|
|
46
|
-
${i}${d}`}}function uQ({indent:e,options:{commentString:t}},n,r,i){if(r&&i&&(r=r.replace(/^\n+/,"")),r){let i=uC(t(r),e);n.push(i.trimStart())}}function uY(e,t){let n=a3(t)?t.value:t;for(let r of e)if(a2(r)&&(r.key===t||r.key===n||a3(r.key)&&r.key.value===n))return r}class uZ extends uA{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(aK,e),this.items=[]}static from(e,t,n){let{keepUndefined:r,replacer:i}=n,s=new this(e),o=(e,o)=>{if("function"==typeof i)o=i.call(t,e,o);else if(Array.isArray(i)&&!i.includes(e))return;(void 0!==o||r)&&s.items.push(uH(e,o,n))};if(t instanceof Map)for(let[e,n]of t)o(e,n);else if(t&&"object"==typeof t)for(let e of Object.keys(t))o(e,t[e]);return"function"==typeof e.sortMapEntries&&s.items.sort(e.sortMapEntries),s}add(e,t){let n;n=a2(e)?e:e&&"object"==typeof e&&"key"in e?new uW(e.key,e.value):new uW(e,e?.value);let r=uY(this.items,n.key),i=this.schema?.sortMapEntries;if(r){if(!t)throw Error(`Key ${n.key} already set`);a3(r.value)&&ub(n.value)?r.value.value=n.value:r.value=n.value}else if(i){let e=this.items.findIndex(e=>0>i(n,e));-1===e?this.items.push(n):this.items.splice(e,0,n)}else this.items.push(n)}delete(e){let t=uY(this.items,e);return!!t&&this.items.splice(this.items.indexOf(t),1).length>0}get(e,t){let n=uY(this.items,e),r=n?.value;return(!t&&a3(r)?r.value:r)??void 0}has(e){return!!uY(this.items,e)}set(e,t){this.add(new uW(e,t),!0)}toJSON(e,t,n){let r=n?new n:t?.mapAsMap?new Map:{};for(let e of(t?.onCreate&&t.onCreate(r),this.items))uV(t,r,e);return r}toString(e,t,n){if(!e)return JSON.stringify(this);for(let e of this.items)if(!a2(e))throw Error(`Map items must all be pairs; found ${JSON.stringify(e)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),uG(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:n,onComment:t})}}let uX={collection:"map",default:!0,nodeClass:uZ,tag:"tag:yaml.org,2002:map",resolve:(e,t)=>(!a1(e)&&t("Expected a mapping for this tag"),e),createNode:(e,t,n)=>uZ.from(e,t,n)};class u0 extends uA{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(aY,e),this.items=[]}add(e){this.items.push(e)}delete(e){let t=u1(e);return"number"==typeof t&&this.items.splice(t,1).length>0}get(e,t){let n=u1(e);if("number"!=typeof n)return;let r=this.items[n];return!t&&a3(r)?r.value:r}has(e){let t=u1(e);return"number"==typeof t&&t<this.items.length}set(e,t){let n=u1(e);if("number"!=typeof n)throw Error(`Expected a valid index, not ${e}.`);let r=this.items[n];a3(r)&&ub(t)?r.value=t:this.items[n]=t}toJSON(e,t){let n=[];t?.onCreate&&t.onCreate(n);let r=0;for(let e of this.items)n.push(um(e,String(r++),t));return n}toString(e,t,n){return e?uG(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:n,onComment:t}):JSON.stringify(this)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t)){let e=0;for(let s of t){if("function"==typeof r){let n=t instanceof Set?s:String(e++);s=r.call(t,n,s)}i.items.push(uk(s,void 0,n))}}return i}}function u1(e){let t=a3(e)?e.value:e;return t&&"string"==typeof t&&(t=Number(t)),"number"==typeof t&&Number.isInteger(t)&&t>=0?t:null}let u2={collection:"seq",default:!0,nodeClass:u0,tag:"tag:yaml.org,2002:seq",resolve:(e,t)=>(!a5(e)&&t("Expected a sequence for this tag"),e),createNode:(e,t,n)=>u0.from(e,t,n)},u3={identify:e=>"string"==typeof e,default:!0,tag:"tag:yaml.org,2002:str",resolve:e=>e,stringify:(e,t,n,r)=>uL(e,t=Object.assign({actualString:!0},t),n,r)},u5={identify:e=>null==e,createNode:()=>new uv(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new uv(null),stringify:({source:e},t)=>"string"==typeof e&&u5.test.test(e)?e:t.options.nullStr},u8={identify:e=>"boolean"==typeof e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:e=>new uv("t"===e[0]||"T"===e[0]),stringify:({source:e,value:t},n)=>e&&u8.test.test(e)&&t===("t"===e[0]||"T"===e[0])?e:t?n.options.trueStr:n.options.falseStr};function u4({format:e,minFractionDigits:t,tag:n,value:r}){if("bigint"==typeof r)return String(r);let i="number"==typeof r?r:Number(r);if(!isFinite(i))return isNaN(i)?".nan":i<0?"-.inf":".inf";let s=JSON.stringify(r);if(!e&&t&&(!n||"tag:yaml.org,2002:float"===n)&&/^\d/.test(s)){let e=s.indexOf(".");e<0&&(e=s.length,s+=".");let n=t-(s.length-e-1);for(;n-- >0;)s+="0"}return s}let u6={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF|nan|NaN|NAN))$/,resolve:e=>"nan"===e.slice(-3).toLowerCase()?NaN:"-"===e[0]?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:u4},u9={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():u4(e)}},u7={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){let t=new uv(parseFloat(e)),n=e.indexOf(".");return -1!==n&&"0"===e[e.length-1]&&(t.minFractionDigits=e.length-n-1),t},stringify:u4},he=e=>"bigint"==typeof e||Number.isInteger(e),ht=(e,t,n,{intAsBigInt:r})=>r?BigInt(e):parseInt(e.substring(t),n);function hn(e,t,n){let{value:r}=e;return he(r)&&r>=0?n+r.toString(t):u4(e)}let hr={identify:e=>he(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(e,t,n)=>ht(e,2,8,n),stringify:e=>hn(e,8,"0o")},hi={identify:he,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(e,t,n)=>ht(e,0,10,n),stringify:u4},hs={identify:e=>he(e)&&e>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,n)=>ht(e,2,16,n),stringify:e=>hn(e,16,"0x")},ho=[uX,u2,u3,u5,u8,hr,hi,hs,u6,u9,u7];function hl(e){return"bigint"==typeof e||Number.isInteger(e)}let ha=({value:e})=>JSON.stringify(e),hu=[{identify:e=>"string"==typeof e,default:!0,tag:"tag:yaml.org,2002:str",resolve:e=>e,stringify:ha},{identify:e=>null==e,createNode:()=>new uv(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:ha},{identify:e=>"boolean"==typeof e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^true|false$/,resolve:e=>"true"===e,stringify:ha},{identify:hl,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:n})=>n?BigInt(e):parseInt(e,10),stringify:({value:e})=>hl(e)?e.toString():JSON.stringify(e)},{identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:e=>parseFloat(e),stringify:ha}],hh=[uX,u2].concat(hu,{default:!0,tag:"",test:/^/,resolve:(e,t)=>(t(`Unresolved plain scalar ${JSON.stringify(e)}`),e)}),hc={identify:e=>e instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(e,t){if("function"==typeof Buffer)return Buffer.from(e,"base64");if("function"!=typeof atob)return t("This environment does not support reading binary tags; either Buffer or atob is required"),e;{let t=atob(e.replace(/[\n\r]/g,"")),n=new Uint8Array(t.length);for(let e=0;e<t.length;++e)n[e]=t.charCodeAt(e);return n}},stringify({comment:e,type:t,value:n},r,i,s){let o;if("function"==typeof Buffer)o=n instanceof Buffer?n.toString("base64"):Buffer.from(n.buffer).toString("base64");else if("function"==typeof btoa){let e="";for(let t=0;t<n.length;++t)e+=String.fromCharCode(n[t]);o=btoa(e)}else throw Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(!t&&(t=uv.BLOCK_LITERAL),t!==uv.QUOTE_DOUBLE){let e=Math.max(r.options.lineWidth-r.indent.length,r.options.minContentWidth),n=Math.ceil(o.length/e),i=Array(n);for(let t=0,r=0;t<n;++t,r+=e)i[t]=o.substr(r,e);o=i.join(t===uv.BLOCK_LITERAL?"\n":" ")}return uL({comment:e,type:t,value:o},r,i,s)}};function hf(e,t){if(a5(e))for(let n=0;n<e.items.length;++n){let r=e.items[n];if(!a2(r)){if(a1(r)){r.items.length>1&&t("Each pair must have its own sequence indicator");let e=r.items[0]||new uW(new uv(null));if(r.commentBefore&&(e.key.commentBefore=e.key.commentBefore?`${r.commentBefore}
|
|
47
|
-
${e.key.commentBefore}`:r.commentBefore),r.comment){let t=e.value??e.key;t.comment=t.comment?`${r.comment}
|
|
48
|
-
${t.comment}`:r.comment}r=e}e.items[n]=a2(r)?r:new uW(r)}}else t("Expected a sequence for this tag");return e}function hd(e,t,n){let{replacer:r}=n,i=new u0(e);i.tag="tag:yaml.org,2002:pairs";let s=0;if(t&&Symbol.iterator in Object(t))for(let e of t){let o,l;if("function"==typeof r&&(e=r.call(t,String(s++),e)),Array.isArray(e)){if(2===e.length)o=e[0],l=e[1];else throw TypeError(`Expected [key, value] tuple: ${e}`)}else if(e&&e instanceof Object){let t=Object.keys(e);if(1===t.length)l=e[o=t[0]];else throw TypeError(`Expected tuple with one key, not ${t.length} keys`)}else o=e;i.items.push(uH(o,l,n))}return i}let hp={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:hf,createNode:hd};class hm extends u0{constructor(){super(),this.add=uZ.prototype.add.bind(this),this.delete=uZ.prototype.delete.bind(this),this.get=uZ.prototype.get.bind(this),this.has=uZ.prototype.has.bind(this),this.set=uZ.prototype.set.bind(this),this.tag=hm.tag}toJSON(e,t){if(!t)return super.toJSON(e);let n=new Map;for(let e of(t?.onCreate&&t.onCreate(n),this.items)){let r,i;if(a2(e)?(r=um(e.key,"",t),i=um(e.value,r,t)):r=um(e,"",t),n.has(r))throw Error("Ordered maps must not include duplicate keys");n.set(r,i)}return n}static from(e,t,n){let r=hd(e,t,n),i=new this;return i.items=r.items,i}}hm.tag="tag:yaml.org,2002:omap";let hg={collection:"seq",identify:e=>e instanceof Map,nodeClass:hm,default:!1,tag:"tag:yaml.org,2002:omap",resolve(e,t){let n=hf(e,t),r=[];for(let{key:e}of n.items)a3(e)&&(r.includes(e.value)?t(`Ordered maps must not include duplicate keys: ${e.value}`):r.push(e.value));return Object.assign(new hm,n)},createNode:(e,t,n)=>hm.from(e,t,n)};function hy({value:e,source:t},n){let r=e?hb:hv;return t&&r.test.test(t)?t:e?n.options.trueStr:n.options.falseStr}let hb={identify:e=>!0===e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new uv(!0),stringify:hy},hv={identify:e=>!1===e,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new uv(!1),stringify:hy},hk=e=>"bigint"==typeof e||Number.isInteger(e);function hw(e,t,n,{intAsBigInt:r}){let i=e[0];if(("-"===i||"+"===i)&&(t+=1),e=e.substring(t).replace(/_/g,""),r){switch(n){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`}let t=BigInt(e);return"-"===i?BigInt(-1)*t:t}let s=parseInt(e,n);return"-"===i?-1*s:s}function hD(e,t,n){let{value:r}=e;if(hk(r)){let e=r.toString(t);return r<0?"-"+n+e.substr(1):n+e}return u4(e)}class hA extends uZ{constructor(e){super(e),this.tag=hA.tag}add(e){let t;t=a2(e)?e:e&&"object"==typeof e&&"key"in e&&"value"in e&&null===e.value?new uW(e.key,null):new uW(e,null),!uY(this.items,t.key)&&this.items.push(t)}get(e,t){let n=uY(this.items,e);return!t&&a2(n)?a3(n.key)?n.key.value:n.key:n}set(e,t){if("boolean"!=typeof t)throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);let n=uY(this.items,e);n&&!t?this.items.splice(this.items.indexOf(n),1):!n&&t&&this.items.push(new uW(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);throw Error("Set items must all have null values")}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t))for(let e of t)"function"==typeof r&&(e=r.call(t,e,e)),i.items.push(uH(e,null,n));return i}}hA.tag="tag:yaml.org,2002:set";let hx={collection:"map",identify:e=>e instanceof Set,nodeClass:hA,default:!1,tag:"tag:yaml.org,2002:set",createNode:(e,t,n)=>hA.from(e,t,n),resolve(e,t){if(a1(e)){if(e.hasAllNullValues(!0))return Object.assign(new hA,e);t("Set items must all have null values")}else t("Expected a mapping for this tag");return e}};function hC(e,t){let n=e[0],r="-"===n||"+"===n?e.substring(1):e,i=e=>t?BigInt(e):Number(e),s=r.replace(/_/g,"").split(":").reduce((e,t)=>e*i(60)+i(t),i(0));return"-"===n?i(-1)*s:s}function hE(e){let{value:t}=e,n=e=>e;if("bigint"==typeof t)n=e=>BigInt(e);else if(isNaN(t)||!isFinite(t))return u4(e);let r="";t<0&&(r="-",t*=n(-1));let i=n(60),s=[t%i];return t<60?s.unshift(0):(t=(t-s[0])/i,s.unshift(t%i),t>=60&&(t=(t-s[0])/i,s.unshift(t))),r+s.map(e=>String(e).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}let hS={identify:e=>"bigint"==typeof e||Number.isInteger(e),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:n})=>hC(e,n),stringify:hE},h_={identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:e=>hC(e,!1),stringify:hE},hO={identify:e=>e instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(e){let t=e.match(hO.test);if(!t)throw Error("!!timestamp expects a date, starting with yyyy-mm-dd");let[,n,r,i,s,o,l]=t.map(Number),a=Date.UTC(n,r-1,i,s||0,o||0,l||0,t[7]?Number((t[7]+"00").substr(1,3)):0),u=t[8];if(u&&"Z"!==u){let e=hC(u,!1);30>Math.abs(e)&&(e*=60),a-=6e4*e}return new Date(a)},stringify:({value:e})=>e.toISOString().replace(/((T00:00)?:00)?\.000Z$/,"")},hF=[uX,u2,u3,u5,hb,hv,{identify:hk,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,n)=>hw(e,2,2,n),stringify:e=>hD(e,2,"0b")},{identify:hk,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(e,t,n)=>hw(e,1,8,n),stringify:e=>hD(e,8,"0")},{identify:hk,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,n)=>hw(e,0,10,n),stringify:u4},{identify:hk,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,n)=>hw(e,2,16,n),stringify:e=>hD(e,16,"0x")},{identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?\.(?:inf|Inf|INF|nan|NaN|NAN)$/,resolve:e=>"nan"===e.slice(-3).toLowerCase()?NaN:"-"===e[0]?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:u4},{identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e.replace(/_/g,"")),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():u4(e)}},{identify:e=>"number"==typeof e,default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){let t=new uv(parseFloat(e.replace(/_/g,""))),n=e.indexOf(".");if(-1!==n){let r=e.substring(n+1).replace(/_/g,"");"0"===r[r.length-1]&&(t.minFractionDigits=r.length)}return t},stringify:u4},hc,hg,hp,hx,hS,h_,hO],hP=new Map([["core",ho],["failsafe",[uX,u2,u3]],["json",hh],["yaml11",hF],["yaml-1.1",hF]]),hT={binary:hc,bool:u8,float:u7,floatExp:u9,floatNaN:u6,floatTime:h_,int:hi,intHex:hs,intOct:hr,intTime:hS,map:uX,null:u5,omap:hg,pairs:hp,seq:u2,set:hx,timestamp:hO},hN={"tag:yaml.org,2002:binary":hc,"tag:yaml.org,2002:omap":hg,"tag:yaml.org,2002:pairs":hp,"tag:yaml.org,2002:set":hx,"tag:yaml.org,2002:timestamp":hO};function hB(e,t){let n=hP.get(t);if(!n){if(Array.isArray(e))n=[];else{let e=Array.from(hP.keys()).filter(e=>"yaml11"!==e).map(e=>JSON.stringify(e)).join(", ");throw Error(`Unknown schema "${t}"; use one of ${e} or define customTags array`)}}if(Array.isArray(e))for(let t of e)n=n.concat(t);else"function"==typeof e&&(n=e(n.slice()));return n.map(e=>{if("string"!=typeof e)return e;let t=hT[e];if(t)return t;let n=Object.keys(hT).map(e=>JSON.stringify(e)).join(", ");throw Error(`Unknown custom tag "${e}"; use one of ${n}`)})}let hI=(e,t)=>e.key<t.key?-1:e.key>t.key?1:0;class hM{constructor({compat:e,customTags:t,merge:n,resolveKnownTags:r,schema:i,sortMapEntries:s,toStringDefaults:o}){this.compat=Array.isArray(e)?hB(e,"compat"):e?hB(null,e):null,this.merge=!!n,this.name="string"==typeof i&&i||"core",this.knownTags=r?hN:{},this.tags=hB(t,this.name),this.toStringOptions=o??null,Object.defineProperty(this,aK,{value:uX}),Object.defineProperty(this,aQ,{value:u3}),Object.defineProperty(this,aY,{value:u2}),this.sortMapEntries="function"==typeof s?s:!0===s?hI:null}clone(){let e=Object.create(hM.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}class h${constructor(e,t,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,aZ,{value:aG});let r=null;"function"==typeof t||Array.isArray(t)?r=t:void 0===n&&t&&(n=t,t=void 0);let i=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,uniqueKeys:!0,version:"1.2"},n);this.options=i;let{version:s}=i;n?._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(s=this.directives.yaml.version)):this.directives=new uh({version:s}),this.setSchema(s,n),this.contents=void 0===e?null:this.createNode(e,r,n)}clone(){let e=Object.create(h$.prototype,{[aZ]:{value:aG}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=a4(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){hL(this.contents)&&this.contents.add(e)}addIn(e,t){hL(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){let n=uf(this);e.anchor=!t||n.has(t)?ud(t||"a",n):t}return new uy(e.anchor)}createNode(e,t,n){let r;if("function"==typeof t)e=t.call({"":e},"",e),r=t;else if(Array.isArray(t)){let e=t.filter(e=>"number"==typeof e||e instanceof String||e instanceof Number).map(String);e.length>0&&(t=t.concat(e)),r=t}else void 0===n&&t&&(n=t,t=void 0);let{aliasDuplicateObjects:i,anchorPrefix:s,flow:o,keepUndefined:l,onTagObj:a,tag:u}=n??{},{onAnchor:h,setAnchors:c,sourceObjects:f}=function(e,t){let n=[],r=new Map,i=null;return{onAnchor:r=>{n.push(r),!i&&(i=uf(e));let s=ud(t,i);return i.add(s),s},setAnchors:()=>{for(let e of n){let t=r.get(e);if("object"==typeof t&&t.anchor&&(a3(t.node)||a8(t.node)))t.node.anchor=t.anchor;else{let t=Error("Failed to resolve repeated object (this should not happen)");throw t.source=e,t}}},sourceObjects:r}}(this,s||"a"),d={aliasDuplicateObjects:i??!0,keepUndefined:l??!1,onAnchor:h,onTagObj:a,replacer:r,schema:this.schema,sourceObjects:f},p=uk(e,u,d);return o&&a8(p)&&(p.flow=!0),c(),p}createPair(e,t,n={}){let r=this.createNode(e,null,n);return new uW(r,this.createNode(t,null,n))}delete(e){return!!hL(this.contents)&&this.contents.delete(e)}deleteIn(e){if(uD(e))return null!=this.contents&&(this.contents=null,!0);return!!hL(this.contents)&&this.contents.deleteIn(e)}get(e,t){return a8(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return uD(e)?!t&&a3(this.contents)?this.contents.value:this.contents:a8(this.contents)?this.contents.getIn(e,t):void 0}has(e){return!!a8(this.contents)&&this.contents.has(e)}hasIn(e){return uD(e)?void 0!==this.contents:!!a8(this.contents)&&this.contents.hasIn(e)}set(e,t){null==this.contents?this.contents=uw(this.schema,[e],t):hL(this.contents)&&this.contents.set(e,t)}setIn(e,t){uD(e)?this.contents=t:null==this.contents?this.contents=uw(this.schema,Array.from(e),t):hL(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){let n;switch("number"==typeof e&&(e=String(e)),e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new uh({version:"1.1"}),n={merge:!0,resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new uh({version:e}),n={merge:!1,resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,n=null;break;default:{let t=JSON.stringify(e);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${t}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new hM(Object.assign(n,t));else throw Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:r,onAnchor:i,reviver:s}={}){let o={anchors:new Map,doc:this,keep:!e,mapAsMap:!0===n,mapKeyWarned:!1,maxAliasCount:"number"==typeof r?r:100},l=um(this.contents,t??"",o);if("function"==typeof i)for(let{count:e,res:t}of o.anchors.values())i(t,e);return"function"==typeof s?up(s,{"":l},"",l):l}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||0>=Number(e.indent))){let t=JSON.stringify(e.indent);throw Error(`"indent" option must be a positive integer, not ${t}`)}return function(e,t){let n=[],r=!0===t.directives;if(!1!==t.directives&&e.directives){let t=e.directives.toString(e);t?(n.push(t),r=!0):e.directives.docStart&&(r=!0)}r&&n.push("---");let i=uR(e,t),{commentString:s}=i.options;if(e.commentBefore){1!==n.length&&n.unshift("");let t=s(e.commentBefore);n.unshift(uC(t,""))}let o=!1,l=null;if(e.contents){if(a4(e.contents)){if(e.contents.spaceBefore&&r&&n.push(""),e.contents.commentBefore){let t=s(e.contents.commentBefore);n.push(uC(t,""))}i.forceBlockIndent=!!e.comment,l=e.contents.comment}let t=l?void 0:()=>o=!0,a=uj(e.contents,i,()=>l=null,t);l&&(a+=uE(a,"",s(l))),("|"===a[0]||">"===a[0])&&"---"===n[n.length-1]?n[n.length-1]=`--- ${a}`:n.push(a)}else n.push(uj(e.contents,i));if(e.directives?.docEnd){if(e.comment){let t=s(e.comment);t.includes("\n")?(n.push("..."),n.push(uC(t,""))):n.push(`... ${t}`)}else n.push("...")}else{let t=e.comment;t&&o&&(t=t.replace(/^\n+/,"")),t&&((!o||l)&&""!==n[n.length-1]&&n.push(""),n.push(uC(s(t),"")))}return n.join("\n")+"\n"}(this,e)}}function hL(e){if(a8(e))return!0;throw Error("Expected a YAML collection as document contents")}class hR extends Error{constructor(e,t,n,r){super(),this.name=e,this.code=n,this.message=r,this.pos=t}}class hj extends hR{constructor(e,t,n){super("YAMLParseError",e,t,n)}}class hq extends hR{constructor(e,t,n){super("YAMLWarning",e,t,n)}}let hV=(e,t)=>n=>{if(-1===n.pos[0])return;n.linePos=n.pos.map(e=>t.linePos(e));let{line:r,col:i}=n.linePos[0];n.message+=` at line ${r}, column ${i}`;let s=i-1,o=e.substring(t.lineStarts[r-1],t.lineStarts[r]).replace(/[\n\r]+$/,"");if(s>=60&&o.length>80){let e=Math.min(s-39,o.length-79);o="…"+o.substring(e),s-=e-1}if(o.length>80&&(o=o.substring(0,79)+"…"),r>1&&/^ *$/.test(o.substring(0,s))){let n=e.substring(t.lineStarts[r-2],t.lineStarts[r-1]);n.length>80&&(n=n.substring(0,79)+"…\n"),o=n+o}if(/[^ ]/.test(o)){let e=1,t=n.linePos[1];t&&t.line===r&&t.col>i&&(e=Math.max(1,Math.min(t.col-i,80-s)));let l=" ".repeat(s)+"^".repeat(e);n.message+=`:
|
|
49
|
-
|
|
50
|
-
${o}
|
|
51
|
-
${l}
|
|
52
|
-
`}};function hz(e,{flow:t,indicator:n,next:r,offset:i,onError:s,startOnNewline:o}){let l=!1,a=o,u=o,h="",c="",f=!1,d=!1,p=!1,m=null,g=null,y=null,b=null,v=null;for(let r of e)switch(p&&("space"!==r.type&&"newline"!==r.type&&"comma"!==r.type&&s(r.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),p=!1),r.type){case"space":!t&&a&&"doc-start"!==n&&" "===r.source[0]&&s(r,"TAB_AS_INDENT","Tabs are not allowed as indentation"),u=!0;break;case"comment":{!u&&s(r,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let e=r.source.substring(1)||" ";h?h+=c+e:h=e,c="",a=!1;break}case"newline":a?h?h+=r.source:l=!0:c+=r.source,a=!0,f=!0,(m||g)&&(d=!0),u=!0;break;case"anchor":m&&s(r,"MULTIPLE_ANCHORS","A node can have at most one anchor"),r.source.endsWith(":")&&s(r.offset+r.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),m=r,null===v&&(v=r.offset),a=!1,u=!1,p=!0;break;case"tag":g&&s(r,"MULTIPLE_TAGS","A node can have at most one tag"),g=r,null===v&&(v=r.offset),a=!1,u=!1,p=!0;break;case n:(m||g)&&s(r,"BAD_PROP_ORDER",`Anchors and tags must be after the ${r.source} indicator`),b&&s(r,"UNEXPECTED_TOKEN",`Unexpected ${r.source} in ${t??"collection"}`),b=r,a=!1,u=!1;break;case"comma":if(t){y&&s(r,"UNEXPECTED_TOKEN",`Unexpected , in ${t}`),y=r,a=!1,u=!1;break}default:s(r,"UNEXPECTED_TOKEN",`Unexpected ${r.type} token`),a=!1,u=!1}let k=e[e.length-1],w=k?k.offset+k.source.length:i;return p&&r&&"space"!==r.type&&"newline"!==r.type&&"comma"!==r.type&&("scalar"!==r.type||""!==r.source)&&s(r.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),{comma:y,found:b,spaceBefore:l,comment:h,hasNewline:f,hasNewlineAfterProp:d,anchor:m,tag:g,end:w,start:v??w}}function hU(e){if(!e)return null;switch(e.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(e.source.includes("\n"))return!0;if(e.end){for(let t of e.end)if("newline"===t.type)return!0}return!1;case"flow-collection":for(let t of e.items){for(let e of t.start)if("newline"===e.type)return!0;if(t.sep){for(let e of t.sep)if("newline"===e.type)return!0}if(hU(t.key)||hU(t.value))return!0}return!1;default:return!0}}function hH(e,t,n){if(t?.type==="flow-collection"){let r=t.end[0];r.indent===e&&("]"===r.source||"}"===r.source)&&hU(t)&&n(r,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}function hW(e,t,n){let{uniqueKeys:r}=e.options;if(!1===r)return!1;let i="function"==typeof r?r:(t,n)=>t===n||a3(t)&&a3(n)&&t.value===n.value&&!("<<"===t.value&&e.schema.merge);return t.some(e=>i(e.key,n))}let hG="All mapping items must start at the same column";function hK(e,t,n,r){let i="";if(e){let s=!1,o="";for(let l of e){let{source:e,type:a}=l;switch(a){case"space":s=!0;break;case"comment":{n&&!s&&r(l,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let t=e.substring(1)||" ";i?i+=o+t:i=t,o="";break}case"newline":i&&(o+=e),s=!0;break;default:r(l,"UNEXPECTED_TOKEN",`Unexpected ${a} at node end`)}t+=e.length}}return{comment:i,offset:t}}let hJ="Block collections are not allowed within flow collections",hQ=e=>e&&("block-map"===e.type||"block-seq"===e.type);function hY(e,t,n,r,i,s){let o="block-map"===n.type?function({composeNode:e,composeEmptyNode:t},n,r,i,s){let o=new(s?.nodeClass??uZ)(n.schema);n.atRoot&&(n.atRoot=!1);let l=r.offset,a=null;for(let s of r.items){let{start:u,key:h,sep:c,value:f}=s,d=hz(u,{indicator:"explicit-key-ind",next:h??c?.[0],offset:l,onError:i,startOnNewline:!0}),p=!d.found;if(p){if(h&&("block-seq"===h.type?i(l,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in h&&h.indent!==r.indent&&i(l,"BAD_INDENT",hG)),!d.anchor&&!d.tag&&!c){a=d.end,d.comment&&(o.comment?o.comment+="\n"+d.comment:o.comment=d.comment);continue}(d.hasNewlineAfterProp||hU(h))&&i(h??u[u.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else d.found?.indent!==r.indent&&i(l,"BAD_INDENT",hG);let m=d.end,g=h?e(n,h,d,i):t(n,m,u,null,d,i);n.schema.compat&&hH(r.indent,h,i),hW(n,o.items,g)&&i(m,"DUPLICATE_KEY","Map keys must be unique");let y=hz(c??[],{indicator:"map-value-ind",next:f,offset:g.range[2],onError:i,startOnNewline:!h||"block-scalar"===h.type});if(l=y.end,y.found){p&&(f?.type==="block-map"&&!y.hasNewline&&i(l,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),n.options.strict&&d.start<y.found.offset-1024&&i(g.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));let a=f?e(n,f,y,i):t(n,l,c,null,y,i);n.schema.compat&&hH(r.indent,f,i),l=a.range[2];let u=new uW(g,a);n.options.keepSourceTokens&&(u.srcToken=s),o.items.push(u)}else{p&&i(g.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),y.comment&&(g.comment?g.comment+="\n"+y.comment:g.comment=y.comment);let e=new uW(g);n.options.keepSourceTokens&&(e.srcToken=s),o.items.push(e)}}return a&&a<l&&i(a,"IMPOSSIBLE","Map comment with trailing content"),o.range=[r.offset,l,a??l],o}(e,t,n,r,s):"block-seq"===n.type?function({composeNode:e,composeEmptyNode:t},n,r,i,s){let o=new(s?.nodeClass??u0)(n.schema);n.atRoot&&(n.atRoot=!1);let l=r.offset,a=null;for(let{start:s,value:u}of r.items){let h=hz(s,{indicator:"seq-item-ind",next:u,offset:l,onError:i,startOnNewline:!0});if(!h.found){if(h.anchor||h.tag||u)u&&"block-seq"===u.type?i(h.end,"BAD_INDENT","All sequence items must start at the same column"):i(l,"MISSING_CHAR","Sequence item without - indicator");else{a=h.end,h.comment&&(o.comment=h.comment);continue}}let c=u?e(n,u,h,i):t(n,h.end,s,null,h,i);n.schema.compat&&hH(r.indent,u,i),l=c.range[2],o.items.push(c)}return o.range=[r.offset,l,a??l],o}(e,t,n,r,s):function({composeNode:e,composeEmptyNode:t},n,r,i,s){let o="{"===r.start.source,l=o?"flow map":"flow sequence",a=new(s?.nodeClass??(o?uZ:u0))(n.schema);a.flow=!0;let u=n.atRoot;u&&(n.atRoot=!1);let h=r.offset+r.start.source.length;for(let s=0;s<r.items.length;++s){let u=r.items[s],{start:c,key:f,sep:d,value:p}=u,m=hz(c,{flow:l,indicator:"explicit-key-ind",next:f??d?.[0],offset:h,onError:i,startOnNewline:!1});if(!m.found){if(!m.anchor&&!m.tag&&!d&&!p){0===s&&m.comma?i(m.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${l}`):s<r.items.length-1&&i(m.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${l}`),m.comment&&(a.comment?a.comment+="\n"+m.comment:a.comment=m.comment),h=m.end;continue}!o&&n.options.strict&&hU(f)&&i(f,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(0===s)m.comma&&i(m.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${l}`);else if(!m.comma&&i(m.start,"MISSING_CHAR",`Missing , between ${l} items`),m.comment){let e="";s:for(let t of c)switch(t.type){case"comma":case"space":break;case"comment":e=t.source.substring(1);break s;default:break s}if(e){let t=a.items[a.items.length-1];a2(t)&&(t=t.value??t.key),t.comment?t.comment+="\n"+e:t.comment=e,m.comment=m.comment.substring(e.length+1)}}if(o||d||m.found){let r=m.end,s=f?e(n,f,m,i):t(n,r,c,null,m,i);hQ(f)&&i(s.range,"BLOCK_IN_FLOW",hJ);let g=hz(d??[],{flow:l,indicator:"map-value-ind",next:p,offset:s.range[2],onError:i,startOnNewline:!1});if(g.found){if(!o&&!m.found&&n.options.strict){if(d)for(let e of d){if(e===g.found)break;if("newline"===e.type){i(e,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}m.start<g.found.offset-1024&&i(g.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else p&&("source"in p&&p.source&&":"===p.source[0]?i(p,"MISSING_CHAR",`Missing space after : in ${l}`):i(g.start,"MISSING_CHAR",`Missing , or : between ${l} items`));let y=p?e(n,p,g,i):g.found?t(n,g.end,d,null,g,i):null;y?hQ(p)&&i(y.range,"BLOCK_IN_FLOW",hJ):g.comment&&(s.comment?s.comment+="\n"+g.comment:s.comment=g.comment);let b=new uW(s,y);if(n.options.keepSourceTokens&&(b.srcToken=u),o)hW(n,a.items,s)&&i(r,"DUPLICATE_KEY","Map keys must be unique"),a.items.push(b);else{let e=new uZ(n.schema);e.flow=!0,e.items.push(b),a.items.push(e)}h=y?y.range[2]:g.end}else{let r=p?e(n,p,m,i):t(n,m.end,d,null,m,i);a.items.push(r),h=r.range[2],hQ(p)&&i(r.range,"BLOCK_IN_FLOW",hJ)}}let c=o?"}":"]",[f,...d]=r.end,p=h;if(f&&f.source===c)p=f.offset+f.source.length;else{let e=l[0].toUpperCase()+l.substring(1),t=u?`${e} must end with a ${c}`:`${e} in block collection must be sufficiently indented and end with a ${c}`;i(h,u?"MISSING_CHAR":"BAD_INDENT",t),f&&1!==f.source.length&&d.unshift(f)}if(d.length>0){let e=hK(d,p,n.options.strict,i);e.comment&&(a.comment?a.comment+="\n"+e.comment:a.comment=e.comment),a.range=[r.offset,p,e.offset]}else a.range=[r.offset,p,p];return a}(e,t,n,r,s),l=o.constructor;return"!"===i||i===l.tagName?(o.tag=l.tagName,o):(i&&(o.tag=i),o)}function hZ(e,t,n){let r=e.offset,i=function({offset:e,props:t},n,r){if("block-scalar-header"!==t[0].type)return r(t[0],"IMPOSSIBLE","Block scalar header not found"),null;let{source:i}=t[0],s=i[0],o=0,l="",a=-1;for(let t=1;t<i.length;++t){let n=i[t];if(l||"-"!==n&&"+"!==n){let r=Number(n);!o&&r?o=r:-1===a&&(a=e+t)}else l=n}-1!==a&&r(a,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${i}`);let u=!1,h="",c=i.length;for(let e=1;e<t.length;++e){let i=t[e];switch(i.type){case"space":u=!0;case"newline":c+=i.source.length;break;case"comment":n&&!u&&r(i,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),c+=i.source.length,h=i.source.substring(1);break;case"error":r(i,"UNEXPECTED_TOKEN",i.message),c+=i.source.length;break;default:{let e=`Unexpected token in block scalar header: ${i.type}`;r(i,"UNEXPECTED_TOKEN",e);let t=i.source;t&&"string"==typeof t&&(c+=t.length)}}}return{mode:s,indent:o,chomp:l,comment:h,length:c}}(e,t,n);if(!i)return{value:"",type:null,comment:"",range:[r,r,r]};let s=">"===i.mode?uv.BLOCK_FOLDED:uv.BLOCK_LITERAL,o=e.source?function(e){let t=e.split(/\n( *)/),n=t[0],r=n.match(/^( *)/),i=[r?.[1]?[r[1],n.slice(r[1].length)]:["",n]];for(let e=1;e<t.length;e+=2)i.push([t[e],t[e+1]]);return i}(e.source):[],l=o.length;for(let e=o.length-1;e>=0;--e){let t=o[e][1];if(""===t||"\r"===t)l=e;else break}if(0===l){let t="+"===i.chomp&&o.length>0?"\n".repeat(Math.max(1,o.length-1)):"",n=r+i.length;return e.source&&(n+=e.source.length),{value:t,type:s,comment:i.comment,range:[r,n,n]}}let a=e.indent+i.indent,u=e.offset+i.length,h=0;for(let e=0;e<l;++e){let[t,r]=o[e];if(""===r||"\r"===r)0===i.indent&&t.length>a&&(a=t.length);else{t.length<a&&n(u+t.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator"),0===i.indent&&(a=t.length),h=e;break}u+=t.length+r.length+1}for(let e=o.length-1;e>=l;--e)o[e][0].length>a&&(l=e+1);let c="",f="",d=!1;for(let e=0;e<h;++e)c+=o[e][0].slice(a)+"\n";for(let e=h;e<l;++e){let[t,r]=o[e];u+=t.length+r.length+1;let l="\r"===r[r.length-1];if(l&&(r=r.slice(0,-1)),r&&t.length<a){let e=i.indent?"explicit indentation indicator":"first line",s=`Block scalar lines must not be less indented than their ${e}`;n(u-r.length-(l?2:1),"BAD_INDENT",s),t=""}s===uv.BLOCK_LITERAL?(c+=f+t.slice(a)+r,f="\n"):t.length>a||" "===r[0]?(" "===f?f="\n":!d&&"\n"===f&&(f="\n\n"),c+=f+t.slice(a)+r,f="\n",d=!0):""===r?"\n"===f?c+="\n":f="\n":(c+=f+r,f=" ",d=!1)}switch(i.chomp){case"-":break;case"+":for(let e=l;e<o.length;++e)c+="\n"+o[e][0].slice(a);"\n"!==c[c.length-1]&&(c+="\n");break;default:c+="\n"}let p=r+i.length+e.source.length;return{value:c,type:s,comment:i.comment,range:[r,p,p]}}function hX(e,t,n){let r,i;let{offset:s,type:o,source:l,end:a}=e,u=(e,t,r)=>n(s+e,t,r);switch(o){case"scalar":r=uv.PLAIN,i=function(e,t){let n="";switch(e[0]){case" ":n="a tab character";break;case",":n="flow indicator character ,";break;case"%":n="directive indicator character %";break;case"|":case">":n=`block scalar indicator ${e[0]}`;break;case"@":case"`":n=`reserved character ${e[0]}`}return n&&t(0,"BAD_SCALAR_START",`Plain value cannot start with ${n}`),h0(e)}(l,u);break;case"single-quoted-scalar":r=uv.QUOTE_SINGLE,i=function(e,t){return("'"!==e[e.length-1]||1===e.length)&&t(e.length,"MISSING_CHAR","Missing closing 'quote"),h0(e.slice(1,-1)).replace(/''/g,"'")}(l,u);break;case"double-quoted-scalar":r=uv.QUOTE_DOUBLE,i=function(e,t){let n="";for(let r=1;r<e.length-1;++r){let i=e[r];if("\r"!==i||"\n"!==e[r+1]){if("\n"===i){let{fold:t,offset:i}=function(e,t){let n="",r=e[t+1];for(;(" "===r||" "===r||"\n"===r||"\r"===r)&&("\r"!==r||"\n"===e[t+2]);){;"\n"===r&&(n+="\n"),t+=1,r=e[t+1]}return!n&&(n=" "),{fold:n,offset:t}}(e,r);n+=t,r=i}else if("\\"===i){let i=e[++r],s=h1[i];if(s)n+=s;else if("\n"===i)for(i=e[r+1];" "===i||" "===i;)i=e[++r+1];else if("\r"===i&&"\n"===e[r+1])for(i=e[++r+1];" "===i||" "===i;)i=e[++r+1];else if("x"===i||"u"===i||"U"===i){let s={x:2,u:4,U:8}[i];n+=function(e,t,n,r){let i=e.substr(t,n),s=i.length===n&&/^[0-9a-fA-F]+$/.test(i)?parseInt(i,16):NaN;if(isNaN(s)){let i=e.substr(t-2,n+2);return r(t-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${i}`),i}return String.fromCodePoint(s)}(e,r+1,s,t),r+=s}else{let i=e.substr(r-1,2);t(r-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${i}`),n+=i}}else if(" "===i||" "===i){let t=r,s=e[r+1];for(;" "===s||" "===s;)s=e[++r+1];"\n"!==s&&!("\r"===s&&"\n"===e[r+2])&&(n+=r>t?e.slice(t,r+1):i)}else n+=i}}return('"'!==e[e.length-1]||1===e.length)&&t(e.length,"MISSING_CHAR",'Missing closing "quote'),n}(l,u);break;default:return n(e,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${o}`),{value:"",type:null,comment:"",range:[s,s+l.length,s+l.length]}}let h=s+l.length,c=hK(a,h,t,n);return{value:i,type:r,comment:c.comment,range:[s,h,c.offset]}}function h0(e){let t,n;try{t=RegExp("(.*?)(?<![ ])[ ]*\r?\n","sy"),n=RegExp("[ ]*(.*?)(?:(?<![ ])[ ]*)?\r?\n","sy")}catch(e){t=/(.*?)[ \t]*\r?\n/sy,n=/[ \t]*(.*?)[ \t]*\r?\n/sy}let r=t.exec(e);if(!r)return e;let i=r[1],s=" ",o=t.lastIndex;for(n.lastIndex=o;r=n.exec(e);)""===r[1]?"\n"===s?i+=s:s="\n":(i+=s+r[1],s=" "),o=n.lastIndex;let l=/[ \t]*(.*)/sy;return l.lastIndex=o,r=l.exec(e),i+s+(r?.[1]??"")}let h1={0:"\0",a:"\x07",b:"\b",e:"\x1b",f:"\f",n:"\n",r:"\r",t:" ",v:"\v",N:"\x85",_:"\xa0",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\"," ":" "};function h2(e,t,n,r){let i;let{value:s,type:o,comment:l,range:a}="block-scalar"===t.type?hZ(t,e.options.strict,r):hX(t,e.options.strict,r),u=n?e.directives.tagName(n.source,e=>r(n,"TAG_RESOLVE_FAILED",e)):null,h=n&&u?function(e,t,n,r,i){if("!"===n)return e[aQ];let s=[];for(let t of e.tags)if(!t.collection&&t.tag===n){if(!t.default||!t.test)return t;s.push(t)}for(let e of s)if(e.test?.test(t))return e;let o=e.knownTags[n];return o&&!o.collection?(e.tags.push(Object.assign({},o,{default:!1,test:void 0})),o):(i(r,"TAG_RESOLVE_FAILED",`Unresolved tag: ${n}`,"tag:yaml.org,2002:str"!==n),e[aQ])}(e.schema,s,u,n,r):"scalar"===t.type?function({directives:e,schema:t},n,r,i){let s=t.tags.find(e=>e.default&&e.test?.test(n))||t[aQ];if(t.compat){let o=t.compat.find(e=>e.default&&e.test?.test(n))??t[aQ];if(s.tag!==o.tag){let t=e.tagString(s.tag),n=e.tagString(o.tag);i(r,"TAG_RESOLVE_FAILED",`Value may be parsed as either ${t} or ${n}`,!0)}}return s}(e,s,t,r):e.schema[aQ];try{let o=h.resolve(s,e=>r(n??t,"TAG_RESOLVE_FAILED",e),e.options);i=a3(o)?o:new uv(o)}catch(e){r(n??t,"TAG_RESOLVE_FAILED",e instanceof Error?e.message:String(e)),i=new uv(s)}return i.range=a,i.source=s,o&&(i.type=o),u&&(i.tag=u),h.format&&(i.format=h.format),l&&(i.comment=l),i}let h3={composeNode:h5,composeEmptyNode:h8};function h5(e,t,n,r){let i;let{spaceBefore:s,comment:o,anchor:l,tag:a}=n,u=!0;switch(t.type){case"alias":i=function({options:e},{offset:t,source:n,end:r},i){let s=new uy(n.substring(1));""===s.source&&i(t,"BAD_ALIAS","Alias cannot be an empty string"),s.source.endsWith(":")&&i(t+n.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let o=t+n.length,l=hK(r,o,e.strict,i);return s.range=[t,o,l.offset],l.comment&&(s.comment=l.comment),s}(e,t,r),(l||a)&&r(t,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":i=h2(e,t,a,r),l&&(i.anchor=l.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":i=function(e,t,n,r,i){let s=r?t.directives.tagName(r.source,e=>i(r,"TAG_RESOLVE_FAILED",e)):null,o="block-map"===n.type?"map":"block-seq"===n.type?"seq":"{"===n.start.source?"map":"seq";if(!r||!s||"!"===s||s===uZ.tagName&&"map"===o||s===u0.tagName&&"seq"===o||!o)return hY(e,t,n,i,s);let l=t.schema.tags.find(e=>e.tag===s&&e.collection===o);if(!l){let a=t.schema.knownTags[s];if(!a||a.collection!==o)return a?.collection?i(r,"BAD_COLLECTION_TYPE",`${a.tag} used for ${o} collection, but expects ${a.collection}`,!0):i(r,"TAG_RESOLVE_FAILED",`Unresolved tag: ${s}`,!0),hY(e,t,n,i,s);t.schema.tags.push(Object.assign({},a,{default:!1})),l=a}let a=hY(e,t,n,i,s,l),u=l.resolve?.(a,e=>i(r,"TAG_RESOLVE_FAILED",e),t.options)??a,h=a4(u)?u:new uv(u);return h.range=a.range,h.tag=s,l?.format&&(h.format=l.format),h}(h3,e,t,a,r),l&&(i.anchor=l.source.substring(1));break;default:{let s="error"===t.type?t.message:`Unsupported token (type: ${t.type})`;r(t,"UNEXPECTED_TOKEN",s),i=h8(e,t.offset,void 0,null,n,r),u=!1}}return l&&""===i.anchor&&r(l,"BAD_ALIAS","Anchor cannot be an empty string"),s&&(i.spaceBefore=!0),o&&("scalar"===t.type&&""===t.source?i.comment=o:i.commentBefore=o),e.options.keepSourceTokens&&u&&(i.srcToken=t),i}function h8(e,t,n,r,{spaceBefore:i,comment:s,anchor:o,tag:l,end:a},u){let h=h2(e,{type:"scalar",offset:function(e,t,n){if(t){null===n&&(n=t.length);for(let r=n-1;r>=0;--r){let n=t[r];switch(n.type){case"space":case"comment":case"newline":e-=n.source.length;continue}for(n=t[++r];n?.type==="space";)e+=n.source.length,n=t[++r];break}}return e}(t,n,r),indent:-1,source:""},l,u);return o&&(h.anchor=o.source.substring(1),""===h.anchor&&u(o,"BAD_ALIAS","Anchor cannot be an empty string")),i&&(h.spaceBefore=!0),s&&(h.comment=s,h.range[2]=a),h}function h4(e){if("number"==typeof e)return[e,e+1];if(Array.isArray(e))return 2===e.length?e:[e[0],e[1]];let{offset:t,source:n}=e;return[t,t+("string"==typeof n?n.length:1)]}function h6(e){let t="",n=!1,r=!1;for(let i=0;i<e.length;++i){let s=e[i];switch(s[0]){case"#":t+=(""===t?"":r?"\n\n":"\n")+(s.substring(1)||" "),n=!0,r=!1;break;case"%":e[i+1]?.[0]!=="#"&&(i+=1),n=!1;break;default:!n&&(r=!0),n=!1}}return{comment:t,afterEmptyLine:r}}class h9{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(e,t,n,r)=>{let i=h4(e);r?this.warnings.push(new hq(i,t,n)):this.errors.push(new hj(i,t,n))},this.directives=new uh({version:e.version||"1.2"}),this.options=e}decorate(e,t){let{comment:n,afterEmptyLine:r}=h6(this.prelude);if(n){let i=e.contents;if(t)e.comment=e.comment?`${e.comment}
|
|
53
|
-
${n}`:n;else if(r||e.directives.docStart||!i)e.commentBefore=n;else if(a8(i)&&!i.flow&&i.items.length>0){let e=i.items[0];a2(e)&&(e=e.key);let t=e.commentBefore;e.commentBefore=t?`${n}
|
|
54
|
-
${t}`:n}else{let e=i.commentBefore;i.commentBefore=e?`${n}
|
|
55
|
-
${e}`:n}}t?(Array.prototype.push.apply(e.errors,this.errors),Array.prototype.push.apply(e.warnings,this.warnings)):(e.errors=this.errors,e.warnings=this.warnings),this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:h6(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,t=!1,n=-1){for(let t of e)yield*this.next(t);yield*this.end(t,n)}*next(e){switch(e.type){case"directive":this.directives.add(e.source,(t,n,r)=>{let i=h4(e);i[0]+=t,this.onError(i,"BAD_DIRECTIVE",n,r)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{let t=function(e,t,{offset:n,start:r,value:i,end:s},o){let l=new h$(void 0,Object.assign({_directives:t},e)),a={atRoot:!0,directives:l.directives,options:l.options,schema:l.schema},u=hz(r,{indicator:"doc-start",next:i??s?.[0],offset:n,onError:o,startOnNewline:!0});u.found&&(l.directives.docStart=!0,i&&("block-map"===i.type||"block-seq"===i.type)&&!u.hasNewline&&o(u.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),l.contents=i?h5(a,i,u,o):h8(a,u.end,r,null,u,o);let h=l.contents.range[2],c=hK(s,h,!1,o);return c.comment&&(l.comment=c.comment),l.range=[n,h,c.offset],l}(this.options,this.directives,e,this.onError);this.atDirectives&&!t.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(t,!1),this.doc&&(yield this.doc),this.doc=t,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{let t=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new hj(h4(e),"UNEXPECTED_TOKEN",t);this.atDirectives||!this.doc?this.errors.push(n):this.doc.errors.push(n);break}case"doc-end":{if(!this.doc){this.errors.push(new hj(h4(e),"UNEXPECTED_TOKEN","Unexpected doc-end without preceding document"));break}this.doc.directives.docEnd=!0;let t=hK(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),t.comment){let e=this.doc.comment;this.doc.comment=e?`${e}
|
|
56
|
-
${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new hj(h4(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let e=new h$(void 0,Object.assign({_directives:this.directives},this.options));this.atDirectives&&this.onError(t,"MISSING_CHAR","Missing directives-end indicator line"),e.range=[0,t,t],this.decorate(e,!1),yield e}}}function h7(e,t=!0,n){if(e){let r=(e,t,r)=>{let i="number"==typeof e?e:Array.isArray(e)?e[0]:e.offset;if(n)n(i,t,r);else throw new hj([i,i+1],t,r)};switch(e.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return hX(e,t,r);case"block-scalar":return hZ(e,t,r)}}return null}function ce(e,t){let{implicitKey:n=!1,indent:r,inFlow:i=!1,offset:s=-1,type:o="PLAIN"}=t,l=uL({type:o,value:e},{implicitKey:n,indent:r>0?" ".repeat(r):"",inFlow:i,options:{blockQuote:!0,lineWidth:-1}}),a=t.end??[{type:"newline",offset:-1,indent:r,source:"\n"}];switch(l[0]){case"|":case">":{let e=l.indexOf("\n"),t=l.substring(0,e),n=l.substring(e+1)+"\n",i=[{type:"block-scalar-header",offset:s,indent:r,source:t}];return!cn(i,a)&&i.push({type:"newline",offset:-1,indent:r,source:"\n"}),{type:"block-scalar",offset:s,indent:r,props:i,source:n}}case'"':return{type:"double-quoted-scalar",offset:s,indent:r,source:l,end:a};case"'":return{type:"single-quoted-scalar",offset:s,indent:r,source:l,end:a};default:return{type:"scalar",offset:s,indent:r,source:l,end:a}}}function ct(e,t,n={}){let{afterKey:r=!1,implicitKey:i=!1,inFlow:s=!1,type:o}=n,l="indent"in e?e.indent:null;if(r&&"number"==typeof l&&(l+=2),!o)switch(e.type){case"single-quoted-scalar":o="QUOTE_SINGLE";break;case"double-quoted-scalar":o="QUOTE_DOUBLE";break;case"block-scalar":{let t=e.props[0];if("block-scalar-header"!==t.type)throw Error("Invalid block scalar header");o=">"===t.source[0]?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:o="PLAIN"}let a=uL({type:o,value:t},{implicitKey:i||null===l,indent:null!==l&&l>0?" ".repeat(l):"",inFlow:s,options:{blockQuote:!0,lineWidth:-1}});switch(a[0]){case"|":case">":(function(e,t){let n=t.indexOf("\n"),r=t.substring(0,n),i=t.substring(n+1)+"\n";if("block-scalar"===e.type){let t=e.props[0];if("block-scalar-header"!==t.type)throw Error("Invalid block scalar header");t.source=r,e.source=i}else{let{offset:t}=e,n="indent"in e?e.indent:-1,s=[{type:"block-scalar-header",offset:t,indent:n,source:r}];for(let t of(!cn(s,"end"in e?e.end:void 0)&&s.push({type:"newline",offset:-1,indent:n,source:"\n"}),Object.keys(e)))"type"!==t&&"offset"!==t&&delete e[t];Object.assign(e,{type:"block-scalar",indent:n,props:s,source:i})}})(e,a);break;case'"':cr(e,a,"double-quoted-scalar");break;case"'":cr(e,a,"single-quoted-scalar");break;default:cr(e,a,"scalar")}}function cn(e,t){if(t)for(let n of t)switch(n.type){case"space":case"comment":e.push(n);break;case"newline":return e.push(n),!0}return!1}function cr(e,t,n){switch(e.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":e.type=n,e.source=t;break;case"block-scalar":{let r=e.props.slice(1),i=t.length;for(let t of("block-scalar-header"===e.props[0].type&&(i-=e.props[0].source.length),r))t.offset+=i;delete e.props,Object.assign(e,{type:n,source:t,end:r});break}case"block-map":case"block-seq":{let r={type:"newline",offset:e.offset+t.length,indent:e.indent,source:"\n"};delete e.items,Object.assign(e,{type:n,source:t,end:[r]});break}default:{let r="indent"in e?e.indent:-1,i="end"in e&&Array.isArray(e.end)?e.end.filter(e=>"space"===e.type||"comment"===e.type||"newline"===e.type):[];for(let t of Object.keys(e))"type"!==t&&"offset"!==t&&delete e[t];Object.assign(e,{type:n,indent:r,source:t,end:i})}}}let ci=e=>"type"in e?cs(e):co(e);function cs(e){switch(e.type){case"block-scalar":{let t="";for(let n of e.props)t+=cs(n);return t+e.source}case"block-map":case"block-seq":{let t="";for(let n of e.items)t+=co(n);return t}case"flow-collection":{let t=e.start.source;for(let n of e.items)t+=co(n);for(let n of e.end)t+=n.source;return t}case"document":{let t=co(e);if(e.end)for(let n of e.end)t+=n.source;return t}default:{let t=e.source;if("end"in e&&e.end)for(let n of e.end)t+=n.source;return t}}}function co({start:e,key:t,sep:n,value:r}){let i="";for(let t of e)i+=t.source;if(t&&(i+=cs(t)),n)for(let e of n)i+=e.source;return r&&(i+=cs(r)),i}let cl=Symbol("break visit"),ca=Symbol("skip children"),cu=Symbol("remove item");function ch(e,t){"type"in e&&"document"===e.type&&(e={start:e.start,value:e.value}),function e(t,n,r){let i=r(n,t);if("symbol"==typeof i)return i;for(let s of["key","value"]){let o=n[s];if(o&&"items"in o){for(let n=0;n<o.items.length;++n){let i=e(Object.freeze(t.concat([[s,n]])),o.items[n],r);if("number"==typeof i)n=i-1;else{if(i===cl)return cl;i===cu&&(o.items.splice(n,1),n-=1)}}"function"==typeof i&&"key"===s&&(i=i(n,t))}}return"function"==typeof i?i(n,t):i}(Object.freeze([]),e,t)}ch.BREAK=cl,ch.SKIP=ca,ch.REMOVE=cu,ch.itemAtPath=(e,t)=>{let n=e;for(let[e,r]of t){let t=n?.[e];if(!t||!("items"in t))return;n=t.items[r]}return n},ch.parentCollection=(e,t)=>{let n=ch.itemAtPath(e,t.slice(0,-1)),r=t[t.length-1][0],i=n?.[r];if(i&&"items"in i)return i;throw Error("Parent collection not found")};let cc="\uFEFF",cf="\x02",cd="\x18",cp="\x1f",cm=e=>!!e&&"items"in e,cg=e=>!!e&&("scalar"===e.type||"single-quoted-scalar"===e.type||"double-quoted-scalar"===e.type||"block-scalar"===e.type);function cy(e){switch(e){case cc:return"<BOM>";case cf:return"<DOC>";case cd:return"<FLOW_END>";case cp:return"<SCALAR>";default:return JSON.stringify(e)}}function cb(e){switch(e){case cc:return"byte-order-mark";case cf:return"doc-mode";case cd:return"flow-error-end";case cp:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case"\n":case"\r\n":return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(e[0]){case" ":case" ":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}function cv(e){switch(e){case void 0:case" ":case"\n":case"\r":case" ":return!0;default:return!1}}let ck="0123456789ABCDEFabcdef".split(""),cw="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()".split(""),cD=",[]{}".split(""),cA=" ,[]{}\n\r ".split(""),cx=e=>!e||cA.includes(e);class cC{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,t=!1){e&&(this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null),this.atEnd=!t;let n=this.next??"stream";for(;n&&(t||this.hasChars(1));)n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,t=this.buffer[e];for(;" "===t||" "===t;)t=this.buffer[++e];return!t||"#"===t||"\n"===t||"\r"===t&&"\n"===this.buffer[e+1]}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let t=this.buffer[e];if(this.indentNext>0){let n=0;for(;" "===t;)t=this.buffer[++n+e];if("\r"===t){let t=this.buffer[n+e+1];if("\n"===t||!t&&!this.atEnd)return e+n+1}return"\n"!==t&&!(n>=this.indentNext)&&(t||this.atEnd)?-1:e+n}if("-"===t||"."===t){let t=this.buffer.substr(e,3);if(("---"===t||"..."===t)&&cv(this.buffer[e+3]))return -1}return e}getLine(){let e=this.lineEndPos;return(("number"!=typeof e||-1!==e&&e<this.pos)&&(e=this.buffer.indexOf("\n",this.pos),this.lineEndPos=e),-1===e)?this.atEnd?this.buffer.substring(this.pos):null:("\r"===this.buffer[e-1]&&(e-=1),this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(null===e)return this.setNext("stream");if(e[0]===cc&&(yield*this.pushCount(1),e=e.substring(1)),"%"===e[0]){let t=e.length,n=e.indexOf("#");if(-1!==n){let r=e[n-1];(" "===r||" "===r)&&(t=n-1)}for(;;){let n=e[t-1];if(" "===n||" "===n)t-=1;else break}let r=(yield*this.pushCount(t))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-r),this.pushNewline(),"stream"}if(this.atLineEnd()){let t=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-t),yield*this.pushNewline(),"stream"}return yield cf,yield*this.parseLineStart()}*parseLineStart(){let e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext("line-start");if("-"===e||"."===e){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");let e=this.peek(3);if("---"===e&&cv(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,"doc";if("..."===e&&cv(this.charAt(3)))return yield*this.pushCount(3),"stream"}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!cv(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){let[e,t]=this.peek(2);if(!t&&!this.atEnd)return this.setNext("block-start");if(("-"===e||"?"===e||":"===e)&&cv(t)){let e=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=e,yield*this.parseBlockStart()}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);let e=this.getLine();if(null===e)return this.setNext("doc");let t=yield*this.pushIndicators();switch(e[t]){case"#":yield*this.pushCount(e.length-t);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(cx),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return t+=yield*this.parseBlockScalarHeader(),t+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-t),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,t;let n=-1;do(e=yield*this.pushNewline())>0?(t=yield*this.pushSpaces(!1),this.indentValue=n=t):t=0,t+=yield*this.pushSpaces(!0);while(e+t>0);let r=this.getLine();if(null===r)return this.setNext("flow");if((-1!==n&&n<this.indentNext&&"#"!==r[0]||0===n&&(r.startsWith("---")||r.startsWith("..."))&&cv(r[3]))&&!(n===this.indentNext-1&&1===this.flowLevel&&("]"===r[0]||"}"===r[0])))return this.flowLevel=0,yield cd,yield*this.parseLineStart();let i=0;for(;","===r[i];)i+=yield*this.pushCount(1),i+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(r[i+=yield*this.pushIndicators()]){case void 0:return"flow";case"#":return yield*this.pushCount(r.length-i),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(cx),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{let e=this.charAt(1);if(this.flowKey||cv(e)||","===e)return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let e=this.charAt(0),t=this.buffer.indexOf(e,this.pos+1);if("'"===e)for(;-1!==t&&"'"===this.buffer[t+1];)t=this.buffer.indexOf("'",t+2);else for(;-1!==t;){let e=0;for(;"\\"===this.buffer[t-1-e];)e+=1;if(e%2==0)break;t=this.buffer.indexOf('"',t+1)}let n=this.buffer.substring(0,t),r=n.indexOf("\n",this.pos);if(-1!==r){for(;-1!==r;){let e=this.continueScalar(r+1);if(-1===e)break;r=n.indexOf("\n",e)}-1!==r&&(t=r-("\r"===n[r-1]?2:1))}if(-1===t){if(!this.atEnd)return this.setNext("quoted-scalar");t=this.buffer.length}return yield*this.pushToIndex(t+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){let t=this.buffer[++e];if("+"===t)this.blockScalarKeep=!0;else if(t>"0"&&t<="9")this.blockScalarIndent=Number(t)-1;else if("-"!==t)break}return yield*this.pushUntil(e=>cv(e)||"#"===e)}*parseBlockScalar(){let e,t=this.pos-1,n=0;s:for(let r=this.pos;e=this.buffer[r];++r)switch(e){case" ":n+=1;break;case"\n":t=r,n=0;break;case"\r":{let e=this.buffer[r+1];if(!e&&!this.atEnd)return this.setNext("block-scalar");if("\n"===e)break}default:break s}if(!e&&!this.atEnd)return this.setNext("block-scalar");if(n>=this.indentNext){-1===this.blockScalarIndent?this.indentNext=n:this.indentNext+=this.blockScalarIndent;do{let e=this.continueScalar(t+1);if(-1===e)break;t=this.buffer.indexOf("\n",e)}while(-1!==t);if(-1===t){if(!this.atEnd)return this.setNext("block-scalar");t=this.buffer.length}}if(!this.blockScalarKeep)for(;;){let e=t-1,r=this.buffer[e];"\r"===r&&(r=this.buffer[--e]);let i=e;for(;" "===r||" "===r;)r=this.buffer[--e];if("\n"===r&&e>=this.pos&&e+1+n>i)t=e;else break}return yield cp,yield*this.pushToIndex(t+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let e;let t=this.flowLevel>0,n=this.pos-1,r=this.pos-1;for(;e=this.buffer[++r];)if(":"===e){let e=this.buffer[r+1];if(cv(e)||t&&","===e)break;n=r}else if(cv(e)){let i=this.buffer[r+1];if("\r"===e&&("\n"===i?(r+=1,e="\n",i=this.buffer[r+1]):n=r),"#"===i||t&&cD.includes(i))break;if("\n"===e){let e=this.continueScalar(r+1);if(-1===e)break;r=Math.max(r,e-2)}}else{if(t&&cD.includes(e))break;n=r}return e||this.atEnd?(yield cp,yield*this.pushToIndex(n+1,!0),t?"flow":"doc"):this.setNext("plain-scalar")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,t){let n=this.buffer.slice(this.pos,e);return n?(yield n,this.pos+=n.length,n.length):(t&&(yield""),0)}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(cx))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{let e=this.flowLevel>0,t=this.charAt(1);if(cv(t)||e&&cD.includes(t))return e?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}return 0}*pushTag(){if("<"===this.charAt(1)){let e=this.pos+2,t=this.buffer[e];for(;!cv(t)&&">"!==t;)t=this.buffer[++e];return yield*this.pushToIndex(">"===t?e+1:e,!1)}{let e=this.pos+1,t=this.buffer[e];for(;t;)if(cw.includes(t))t=this.buffer[++e];else if("%"===t&&ck.includes(this.buffer[e+1])&&ck.includes(this.buffer[e+2]))t=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];return"\n"===e?yield*this.pushCount(1):"\r"===e&&"\n"===this.charAt(1)?yield*this.pushCount(2):0}*pushSpaces(e){let t,n=this.pos-1;do t=this.buffer[++n];while(" "===t||e&&" "===t);let r=n-this.pos;return r>0&&(yield this.buffer.substr(this.pos,r),this.pos=n),r}*pushUntil(e){let t=this.pos,n=this.buffer[t];for(;!e(n);)n=this.buffer[++t];return yield*this.pushToIndex(t,!1)}}class cE{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let t=0,n=this.lineStarts.length;for(;t<n;){let r=t+n>>1;this.lineStarts[r]<e?t=r+1:n=r}if(this.lineStarts[t]===e)return{line:t+1,col:1};if(0===t)return{line:0,col:e};let r=this.lineStarts[t-1];return{line:t,col:e-r+1}}}}function cS(e,t){for(let n=0;n<e.length;++n)if(e[n].type===t)return!0;return!1}function c_(e){for(let t=0;t<e.length;++t)switch(e[t].type){case"space":case"comment":case"newline":break;default:return t}return -1}function cO(e){switch(e?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function cF(e){switch(e.type){case"document":return e.start;case"block-map":{let t=e.items[e.items.length-1];return t.sep??t.start}case"block-seq":return e.items[e.items.length-1].start;default:return[]}}function cP(e){if(0===e.length)return[];let t=e.length;s:for(;--t>=0;)switch(e[t].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break s}for(;e[++t]?.type==="space";);return e.splice(t,e.length)}function cT(e){if("flow-seq-start"===e.start.type)for(let t of e.items)t.sep&&!t.value&&!cS(t.start,"explicit-key-ind")&&!cS(t.sep,"map-value-ind")&&(t.key&&(t.value=t.key),delete t.key,cO(t.value)?t.value.end?Array.prototype.push.apply(t.value.end,t.sep):t.value.end=t.sep:Array.prototype.push.apply(t.start,t.sep),delete t.sep)}class cN{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new cC,this.onNewLine=e}*parse(e,t=!1){for(let n of(this.onNewLine&&0===this.offset&&this.onNewLine(0),this.lexer.lex(e,t)))yield*this.next(n);!t&&(yield*this.end())}*next(e){if(this.source=e,this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}let t=cb(e);if(t){if("scalar"===t)this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=t,yield*this.step(),t){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&" "===e[0]&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}}else{let t=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:t,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if("doc-end"===this.type&&(!e||"doc-end"!==e.type)){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){let t=e??this.stack.pop();if(t){if(0===this.stack.length)yield t;else{let e=this.peek(1);switch("block-scalar"===t.type?t.indent="indent"in e?e.indent:0:"flow-collection"===t.type&&"document"===e.type&&(t.indent=0),"flow-collection"===t.type&&cT(t),e.type){case"document":e.value=t;break;case"block-scalar":e.props.push(t);break;case"block-map":{let n=e.items[e.items.length-1];if(n.value){e.items.push({start:[],key:t,sep:[]}),this.onKeyLine=!0;return}if(n.sep)n.value=t;else{Object.assign(n,{key:t,sep:[]}),this.onKeyLine=!cS(n.start,"explicit-key-ind");return}break}case"block-seq":{let n=e.items[e.items.length-1];n.value?e.items.push({start:[],value:t}):n.value=t;break}case"flow-collection":{let n=e.items[e.items.length-1];!n||n.value?e.items.push({start:[],key:t,sep:[]}):n.sep?n.value=t:Object.assign(n,{key:t,sep:[]});return}default:yield*this.pop(),yield*this.pop(t)}if(("document"===e.type||"block-map"===e.type||"block-seq"===e.type)&&("block-map"===t.type||"block-seq"===t.type)){let n=t.items[t.items.length-1];n&&!n.sep&&!n.value&&n.start.length>0&&-1===c_(n.start)&&(0===t.indent||n.start.every(e=>"comment"!==e.type||e.indent<t.indent))&&("document"===e.type?e.end=n.start:e.items.push({start:n.start}),t.items.splice(-1,1))}}}else yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"}}*stream(){switch(this.type){case"directive-line":yield{type:"directive",offset:this.offset,source:this.source};return;case"byte-order-mark":case"space":case"comment":case"newline":yield this.sourceToken;return;case"doc-mode":case"doc-start":{let e={type:"document",offset:this.offset,start:[]};"doc-start"===this.type&&e.start.push(this.sourceToken),this.stack.push(e);return}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case"doc-start":-1!==c_(e.start)?(yield*this.pop(),yield*this.step()):e.start.push(this.sourceToken);return;case"anchor":case"tag":case"space":case"comment":case"newline":e.start.push(this.sourceToken);return}let t=this.startBlockValue(e);t?this.stack.push(t):yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if("map-value-ind"===this.type){let t;let n=cP(cF(this.peek(2)));e.end?((t=e.end).push(this.sourceToken),delete e.end):t=[this.sourceToken];let r={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:n,key:e,sep:t}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=r}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case"space":case"comment":case"newline":e.props.push(this.sourceToken);return;case"scalar":if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let e=this.source.indexOf("\n")+1;for(;0!==e;)this.onNewLine(this.offset+e),e=this.source.indexOf("\n",e)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let t=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,t.value){let n="end"in t.value?t.value.end:void 0,r=Array.isArray(n)?n[n.length-1]:void 0;r?.type==="comment"?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2],r=n?.value?.end;if(Array.isArray(r)){Array.prototype.push.apply(r,t.start),r.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let n=!this.onKeyLine&&this.indent===e.indent&&t.sep&&"seq-item-ind"!==this.type,r=[];if(n&&t.sep&&!t.value){let n=[];for(let r=0;r<t.sep.length;++r){let i=t.sep[r];switch(i.type){case"newline":n.push(r);break;case"space":break;case"comment":i.indent>e.indent&&(n.length=0);break;default:n.length=0}}n.length>=2&&(r=t.sep.splice(n[1]))}switch(this.type){case"anchor":case"tag":n||t.value?(r.push(this.sourceToken),e.items.push({start:r}),this.onKeyLine=!0):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case"explicit-key-ind":t.sep||cS(t.start,"explicit-key-ind")?n||t.value?(r.push(this.sourceToken),e.items.push({start:r})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]}):t.start.push(this.sourceToken),this.onKeyLine=!0;return;case"map-value-ind":if(cS(t.start,"explicit-key-ind")){if(t.sep){if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(cS(t.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:r,key:null,sep:[this.sourceToken]}]});else if(cO(t.key)&&!cS(t.sep,"newline")){let e=cP(t.start),n=t.key,r=t.sep;r.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:e,key:n,sep:r}]})}else r.length>0?t.sep=t.sep.concat(r,this.sourceToken):t.sep.push(this.sourceToken)}else if(cS(t.start,"newline"))Object.assign(t,{key:null,sep:[this.sourceToken]});else{let e=cP(t.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:e,key:null,sep:[this.sourceToken]}]})}}else t.sep?t.value||n?e.items.push({start:r,key:null,sep:[this.sourceToken]}):cS(t.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let i=this.flowScalar(this.type);n||t.value?(e.items.push({start:r,key:i,sep:[]}),this.onKeyLine=!0):t.sep?this.stack.push(i):(Object.assign(t,{key:i,sep:[]}),this.onKeyLine=!0);return}default:{let i=this.startBlockValue(e);if(i){n&&"block-seq"!==i.type&&cS(t.start,"explicit-key-ind")&&e.items.push({start:r}),this.stack.push(i);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let t=e.items[e.items.length-1];switch(this.type){case"newline":if(t.value){let n="end"in t.value?t.value.end:void 0,r=Array.isArray(n)?n[n.length-1]:void 0;r?.type==="comment"?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case"space":case"comment":if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2],r=n?.value?.end;if(Array.isArray(r)){Array.prototype.push.apply(r,t.start),r.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return;case"anchor":case"tag":if(t.value||this.indent<=e.indent)break;t.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;t.value||cS(t.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return}if(this.indent>e.indent){let t=this.startBlockValue(e);if(t){this.stack.push(t);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let t=e.items[e.items.length-1];if("flow-error-end"===this.type){let e;do yield*this.pop(),e=this.peek(1);while(e&&"flow-collection"===e.type)}else if(0===e.end.length){switch(this.type){case"comma":case"explicit-key-ind":!t||t.sep?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return;case"map-value-ind":!t||t.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":!t||t.value?e.items.push({start:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let n=this.flowScalar(this.type);!t||t.value?e.items.push({start:[],key:n,sep:[]}):t.sep?this.stack.push(n):Object.assign(t,{key:n,sep:[]});return}case"flow-map-end":case"flow-seq-end":e.end.push(this.sourceToken);return}let n=this.startBlockValue(e);n?this.stack.push(n):(yield*this.pop(),yield*this.step())}else{let t=this.peek(2);if("block-map"!==t.type||("map-value-ind"!==this.type||t.indent!==e.indent)&&("newline"!==this.type||t.items[t.items.length-1].sep)){if("map-value-ind"===this.type&&"flow-collection"!==t.type){let n=cP(cF(t));cT(e);let r=e.end.splice(1,e.end.length);r.push(this.sourceToken);let i={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:n,key:e,sep:r}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=i}else yield*this.lineEnd(e)}else yield*this.pop(),yield*this.step()}}flowScalar(e){if(this.onNewLine){let e=this.source.indexOf("\n")+1;for(;0!==e;)this.onNewLine(this.offset+e),e=this.source.indexOf("\n",e)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let t=cP(cF(e));return t.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t}]}}case"map-value-ind":{this.onKeyLine=!0;let t=cP(cF(e));return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){return"comment"===this.type&&!(this.indent<=t)&&e.every(e=>"newline"===e.type||"space"===e.type)}*documentEnd(e){"doc-mode"!==this.type&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],"newline"===this.type&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],"newline"===this.type&&(yield*this.pop())}}}function cB(e){let t=!1!==e.prettyErrors;return{lineCounter:e.lineCounter||t&&new cE||null,prettyErrors:t}}function cI(e,t={}){let{lineCounter:n,prettyErrors:r}=cB(t),i=new cN(n?.addNewLine),s=new h9(t),o=Array.from(s.compose(i.parse(e)));if(r&&n)for(let t of o)t.errors.forEach(hV(e,n)),t.warnings.forEach(hV(e,n));return o.length>0?o:Object.assign([],{empty:!0},s.streamInfo())}function cM(e,t={}){let{lineCounter:n,prettyErrors:r}=cB(t),i=new cN(n?.addNewLine),s=new h9(t),o=null;for(let t of s.compose(i.parse(e),!0,e.length))if(o){if("silent"!==o.options.logLevel){o.errors.push(new hj(t.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}}else o=t;return r&&n&&(o.errors.forEach(hV(e,n)),o.warnings.forEach(hV(e,n))),o}function c$(e,t,n){let r;"function"==typeof t?r=t:void 0===n&&t&&"object"==typeof t&&(n=t);let i=cM(e,n);if(!i)return null;if(i.warnings.forEach(e=>uq(i.options.logLevel,e)),i.errors.length>0){if("silent"!==i.options.logLevel)throw i.errors[0];i.errors=[]}return i.toJS(Object.assign({reviver:r},n))}function cL(e,t,n){let r=null;if("function"==typeof t||Array.isArray(t)?r=t:void 0===n&&t&&(n=t),"string"==typeof n&&(n=n.length),"number"==typeof n){let e=Math.round(n);n=e<1?void 0:e>8?{indent:8}:{indent:e}}if(void 0===e){let{keepUndefined:e}=n??t??{};if(!e)return}return new h$(e,r,n).toString(n)}function cR(e){let t=null;try{t=L.parse(e.doc.toString())}catch(e){}return{data:t,pointers:Y(e,G.YAML)}}var cj=n("96111");function cq(e){let t=null;try{t=cj.parse(e.doc.toString())}catch(e){}return{data:t,pointers:Y(e,G.JSON5)}}let cV=e=>{switch(e){case G.JSON:return aU;case G.JSON5:return cq;case G.YAML:return cR}},cz=e=>{var t,n,r;return(null===(t=null==e?void 0:e.data)||void 0===t?void 0:t.pointer)&&(null===(n=null==e?void 0:e.data)||void 0===n?void 0:n.pointer)!=="#"?e.data.pointer.slice(1):(null===(r=null==e?void 0:e.data)||void 0===r?void 0:r.property)?`/${e.data.property}`:""},cU=e=>e.startState.field(em)!==e.state.field(em),cH=["NoAdditionalPropertiesError","RequiredPropertyError","InvalidPropertyNameError","ForbiddenPropertyError","UndefinedValueError"];class cW{constructor(e){var t,n,r,i;this.options=e,this.schema=null,this.mode=G.JSON,this.parser=aU,this.rewriteError=e=>{var t,n,r,i,s;let o=null==e?void 0:e.data,l=null==o?void 0:o.errors;return"one-of-error"===e.code&&(null==l?void 0:l.length)?`Expected one of ${az(l,e=>e.data.expected)}`:"type-error"===e.code?`Expected \`${(null===(t=null==e?void 0:e.data)||void 0===t?void 0:t.expected)&&Array.isArray(null===(n=null==e?void 0:e.data)||void 0===n?void 0:n.expected)?az(null===(r=null==e?void 0:e.data)||void 0===r?void 0:r.expected):null===(i=null==e?void 0:e.data)||void 0===i?void 0:i.expected}\` but received \`${null===(s=null==e?void 0:e.data)||void 0===s?void 0:s.received}\``:e.message.replaceAll("in `#` ","").replaceAll("at `#`","").replaceAll("/",".").replaceAll("#.","")},this.mode=null!==(n=null===(t=this.options)||void 0===t?void 0:t.mode)&&void 0!==n?n:G.JSON,this.parser=null!==(i=null===(r=this.options)||void 0===r?void 0:r.jsonParser)&&void 0!==i?i:cV(this.mode)}get schemaTitle(){var e,t,n;return null!==(n=null===(t=null===(e=this.schema)||void 0===e?void 0:e.getSchema())||void 0===t?void 0:t.title)&&void 0!==n?n:"json-schema"}doValidation(e){let t=ey(e.state);if(!t)return[];if(this.schema=new n2(t),!this.schema)return[];let n=e.state.doc.toString();if(!(null==n?void 0:n.length))return[];let r=this.parser(e.state),i=[];try{i=this.schema.validate(r.data)}catch(e){}return(q.log("xxx","validation errors",i,r.data),i.length)?i.reduce((e,t)=>{let n=()=>{let n=this.rewriteError(t);e.push({from:0,to:0,message:n,severity:"error",source:this.schemaTitle,renderMessage:()=>{let e=aH("div",{});return e.innerHTML=aj(n),e}})},i=cz(t),s=r.pointers.get(i);if("MaxPropertiesError"===t.name||"MinPropertiesError"===t.name)n();else if(s){let n=cH.includes(t.name),r=this.rewriteError(t),i=n?s.keyFrom:s.valueFrom,o=n?s.keyTo:s.valueTo;void 0!==o&&void 0!==i&&e.push({from:i,to:o,message:r,renderMessage:()=>{let e=aH("div",{});return e.innerHTML=aj(r),e},severity:"error",source:this.schemaTitle})}else n();return e},[]):[]}}function cG(e){if(e.type)return e.$ref?`${e.$ref} (${e.type})`:e.type;if(e.$ref)return`${e.$ref}`}function cK(e,t,n){return`${t}: ${az(e[t].map(e=>{try{let{data:t}=n.resolveRef({data:e,pointer:e.$ref});if(t)return cG(t);return cG(e)}catch(t){return e.type}}))}`}class cJ{constructor(e){var t,n;this.opts=e,this.schema=null,this.mode=G.JSON,this.opts=Object.assign({parser:JSON.parse},this.opts),this.mode=null!==(n=null===(t=this.opts)||void 0===t?void 0:t.mode)&&void 0!==n?n:G.JSON}getDataForCursor(e,t,n){let r,i=ey(e.state);if(!i)return null;this.schema=new n2(i);let s=Q(e.state,t,n,this.mode);try{r=this.opts.parser(e.state.doc.toString())}catch(e){}if(!s)return null;let o=this.schema.getSchema({pointer:s,data:r,withSchemaWarning:!0});return eS(o)&&(o=(null==o?void 0:o.data.schema.$ref)?this.schema.resolveRef(o):null==o?void 0:o.data.schema),{schema:o,pointer:s}}formatMessage(e){let{message:t,typeInfo:n}=e;return t?aH("div",{class:"cm6-json-schema-hover"},[aH("div",{class:"cm6-json-schema-hover--description",inner:aj(t,!1)}),aH("div",{class:"cm6-json-schema-hover--code-wrapper"},[aH("div",{class:"cm6-json-schema-hover--code",inner:aj(n,!1)})])]):aH("div",{class:"cm6-json-schema-hover"},[aH("div",{class:"cm6-json-schema-hover--code-wrapper"},[aH("code",{class:"cm6-json-schema-hover--code",inner:aj(n,!1)})])])}getHoverTexts(e,t){let n="",r=null,{schema:i}=e;return i.oneOf&&(n=cK(i,"oneOf",t)),i.anyOf&&(n=cK(i,"anyOf",t)),i.allOf&&(n=cK(i,"allOf",t)),i.type&&(n=Array.isArray(i.type)?az(i.type):i.type),i.$ref&&(n=` Reference: ${i.$ref}`),i.enum&&(n=`\`enum\`: ${az(i.enum)}`),i.format&&(n+=`\`format\`: ${i.format}`),i.pattern&&(n+=`\`pattern\`: ${i.pattern}`),i.description&&(r=i.description),{message:r,typeInfo:n}}async doHover(e,t,n){var r,i,s,o;try{let l=this.getDataForCursor(e,t,n);if(q.log("cursorData",l),!(null==l?void 0:l.schema))return null;let a=(null!==(i=null===(r=this.opts)||void 0===r?void 0:r.getHoverTexts)&&void 0!==i?i:this.getHoverTexts)(l,this.schema),u=(null!==(o=null===(s=this.opts)||void 0===s?void 0:s.formatHover)&&void 0!==o?o:this.formatMessage)(a);return{pos:t,end:t,arrow:!0,above:!0,create:e=>({dom:u})}}catch(e){return q.log(e),null}}}var cQ=n("7888");class cY{constructor(e,t,n,r,i,s,o,l,a,u=0,h){this.p=e,this.stack=t,this.state=n,this.reducePos=r,this.pos=i,this.score=s,this.buffer=o,this.bufferBase=l,this.curContext=a,this.lookAhead=u,this.parent=h}toString(){return`[${this.stack.filter((e,t)=>t%3==0).concat(this.state)}]@${this.pos}${this.score?"!"+this.score:""}`}static start(e,t,n=0){let r=e.parser.context;return new cY(e,[],t,n,n,0,[],0,r?new cZ(r,r.start):null,0,null)}get context(){return this.curContext?this.curContext.context:null}pushState(e,t){this.stack.push(this.state,t,this.bufferBase+this.buffer.length),this.state=e}reduce(e){var t;let n=e>>19,r=65535&e,{parser:i}=this.p,s=i.dynamicPrecedence(r);if(s&&(this.score+=s),0==n){this.pushState(i.getGoto(this.state,r,!0),this.reducePos),r<i.minRepeatTerm&&this.storeNode(r,this.reducePos,this.reducePos,4,!0),this.reduceContext(r,this.reducePos);return}let o=this.stack.length-(n-1)*3-(262144&e?6:0),l=o?this.stack[o-2]:this.p.ranges[0].from,a=this.reducePos-l;a>=2e3&&!(null===(t=this.p.parser.nodeSet.types[r])||void 0===t?void 0:t.isAnonymous)&&(l==this.p.lastBigReductionStart?(this.p.bigReductionCount++,this.p.lastBigReductionSize=a):this.p.lastBigReductionSize<a&&(this.p.bigReductionCount=1,this.p.lastBigReductionStart=l,this.p.lastBigReductionSize=a));let u=o?this.stack[o-1]:0,h=this.bufferBase+this.buffer.length-u;if(r<i.minRepeatTerm||131072&e){let e=i.stateFlag(this.state,1)?this.pos:this.reducePos;this.storeNode(r,l,e,h+4,!0)}if(262144&e)this.state=this.stack[o];else{let e=this.stack[o-3];this.state=i.getGoto(e,r,!0)}for(;this.stack.length>o;)this.stack.pop();this.reduceContext(r,l)}storeNode(e,t,n,r=4,i=!1){if(0==e&&(!this.stack.length||this.stack[this.stack.length-1]<this.buffer.length+this.bufferBase)){let e=this,r=this.buffer.length;if(0==r&&e.parent&&(r=e.bufferBase-e.parent.bufferBase,e=e.parent),r>0&&0==e.buffer[r-4]&&e.buffer[r-1]>-1){if(t==n)return;if(e.buffer[r-2]>=t){e.buffer[r-2]=n;return}}}if(i&&this.pos!=n){let i=this.buffer.length;if(i>0&&0!=this.buffer[i-4])for(;i>0&&this.buffer[i-2]>n;)this.buffer[i]=this.buffer[i-4],this.buffer[i+1]=this.buffer[i-3],this.buffer[i+2]=this.buffer[i-2],this.buffer[i+3]=this.buffer[i-1],i-=4,r>4&&(r-=4);this.buffer[i]=e,this.buffer[i+1]=t,this.buffer[i+2]=n,this.buffer[i+3]=r}else this.buffer.push(e,t,n,r)}shift(e,t,n,r){if(131072&e)this.pushState(65535&e,this.pos);else if((262144&e)==0){let{parser:i}=this.p;(r>this.pos||t<=i.maxNode)&&(this.pos=r,!i.stateFlag(e,1)&&(this.reducePos=r)),this.pushState(e,n),this.shiftContext(t,n),t<=i.maxNode&&this.buffer.push(t,n,r,4)}else this.pos=r,this.shiftContext(t,n),t<=this.p.parser.maxNode&&this.buffer.push(t,n,r,4)}apply(e,t,n,r){65536&e?this.reduce(e):this.shift(e,t,n,r)}useNode(e,t){let n=this.p.reused.length-1;(n<0||this.p.reused[n]!=e)&&(this.p.reused.push(e),n++);let r=this.pos;this.reducePos=this.pos=r+e.length,this.pushState(t,r),this.buffer.push(n,r,this.reducePos,-1),this.curContext&&this.updateContext(this.curContext.tracker.reuse(this.curContext.context,e,this,this.p.stream.reset(this.pos-e.length)))}split(){let e=this,t=e.buffer.length;for(;t>0&&e.buffer[t-2]>e.reducePos;)t-=4;let n=e.buffer.slice(t),r=e.bufferBase+t;for(;e&&r==e.bufferBase;)e=e.parent;return new cY(this.p,this.stack.slice(),this.state,this.reducePos,this.pos,this.score,n,r,this.curContext,this.lookAhead,e)}recoverByDelete(e,t){let n=e<=this.p.parser.maxNode;n&&this.storeNode(e,this.pos,t,4),this.storeNode(0,this.pos,t,n?8:4),this.pos=this.reducePos=t,this.score-=190}canShift(e){for(let t=new cX(this);;){let n=this.p.parser.stateSlot(t.state,4)||this.p.parser.hasAction(t.state,e);if(0==n)return!1;if((65536&n)==0)return!0;t.reduce(n)}}recoverByInsert(e){if(this.stack.length>=300)return[];let t=this.p.parser.nextStates(this.state);if(t.length>8||this.stack.length>=120){let n=[];for(let r=0,i;r<t.length;r+=2)(i=t[r+1])!=this.state&&this.p.parser.hasAction(i,e)&&n.push(t[r],i);if(this.stack.length<120)for(let e=0;n.length<8&&e<t.length;e+=2){let r=t[e+1];!n.some((e,t)=>1&t&&e==r)&&n.push(t[e],r)}t=n}let n=[];for(let e=0;e<t.length&&n.length<4;e+=2){let r=t[e+1];if(r==this.state)continue;let i=this.split();i.pushState(r,this.pos),i.storeNode(0,i.pos,i.pos,4,!0),i.shiftContext(t[e],this.pos),i.reducePos=this.pos,i.score-=200,n.push(i)}return n}forceReduce(){let{parser:e}=this.p,t=e.stateSlot(this.state,5);if((65536&t)==0)return!1;if(!e.validAction(this.state,t)){let n=t>>19,r=65535&t,i=this.stack.length-3*n;if(i<0||0>e.getGoto(this.stack[i],r,!1)){let e=this.findForcedReduction();if(null==e)return!1;t=e}this.storeNode(0,this.pos,this.pos,4,!0),this.score-=100}return this.reducePos=this.pos,this.reduce(t),!0}findForcedReduction(){let{parser:e}=this.p,t=[],n=(r,i)=>{if(!t.includes(r))return t.push(r),e.allActions(r,t=>{if(393216&t);else if(65536&t){let n=(t>>19)-i;if(n>1){let r=65535&t,i=this.stack.length-3*n;if(i>=0&&e.getGoto(this.stack[i],r,!1)>=0)return n<<19|65536|r}}else{let e=n(t,i+1);if(null!=e)return e}})};return n(this.state,0)}forceAll(){for(;!this.p.parser.stateFlag(this.state,2);)if(!this.forceReduce()){this.storeNode(0,this.pos,this.pos,4,!0);break}return this}get deadEnd(){if(3!=this.stack.length)return!1;let{parser:e}=this.p;return 65535==e.data[e.stateSlot(this.state,1)]&&!e.stateSlot(this.state,4)}restart(){this.storeNode(0,this.pos,this.pos,4,!0),this.state=this.stack[0],this.stack.length=0}sameState(e){if(this.state!=e.state||this.stack.length!=e.stack.length)return!1;for(let t=0;t<this.stack.length;t+=3)if(this.stack[t]!=e.stack[t])return!1;return!0}get parser(){return this.p.parser}dialectEnabled(e){return this.p.parser.dialect.flags[e]}shiftContext(e,t){this.curContext&&this.updateContext(this.curContext.tracker.shift(this.curContext.context,e,this,this.p.stream.reset(t)))}reduceContext(e,t){this.curContext&&this.updateContext(this.curContext.tracker.reduce(this.curContext.context,e,this,this.p.stream.reset(t)))}emitContext(){let e=this.buffer.length-1;(e<0||-3!=this.buffer[e])&&this.buffer.push(this.curContext.hash,this.pos,this.pos,-3)}emitLookAhead(){let e=this.buffer.length-1;(e<0||-4!=this.buffer[e])&&this.buffer.push(this.lookAhead,this.pos,this.pos,-4)}updateContext(e){if(e!=this.curContext.context){let t=new cZ(this.curContext.tracker,e);t.hash!=this.curContext.hash&&this.emitContext(),this.curContext=t}}setLookAhead(e){e>this.lookAhead&&(this.emitLookAhead(),this.lookAhead=e)}close(){this.curContext&&this.curContext.tracker.strict&&this.emitContext(),this.lookAhead>0&&this.emitLookAhead()}}class cZ{constructor(e,t){this.tracker=e,this.context=t,this.hash=e.strict?e.hash(t):0}}class cX{constructor(e){this.start=e,this.state=e.state,this.stack=e.stack,this.base=this.stack.length}reduce(e){let t=e>>19;0==t?(this.stack==this.start.stack&&(this.stack=this.stack.slice()),this.stack.push(this.state,0,0),this.base+=3):this.base-=(t-1)*3;let n=this.start.p.parser.getGoto(this.stack[this.base-3],65535&e,!0);this.state=n}}class c0{constructor(e,t,n){this.stack=e,this.pos=t,this.index=n,this.buffer=e.buffer,0==this.index&&this.maybeNext()}static create(e,t=e.bufferBase+e.buffer.length){return new c0(e,t,t-e.bufferBase)}maybeNext(){let e=this.stack.parent;null!=e&&(this.index=this.stack.bufferBase-e.bufferBase,this.stack=e,this.buffer=e.buffer)}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}next(){this.index-=4,this.pos-=4,0==this.index&&this.maybeNext()}fork(){return new c0(this.stack,this.pos,this.index)}}function c1(e,t=Uint16Array){if("string"!=typeof e)return e;let n=null;for(let r=0,i=0;r<e.length;){let s=0;for(;;){let t=e.charCodeAt(r++),n=!1;if(126==t){s=65535;break}t>=92&&t--,t>=34&&t--;let i=t-32;if(i>=46&&(i-=46,n=!0),s+=i,n)break;s*=46}n?n[i++]=s:n=new t(s)}return n}class c2{constructor(){this.start=-1,this.value=-1,this.end=-1,this.extended=-1,this.lookAhead=0,this.mask=0,this.context=0}}let c3=new c2;class c5{constructor(e,t){this.input=e,this.ranges=t,this.chunk="",this.chunkOff=0,this.chunk2="",this.chunk2Pos=0,this.next=-1,this.token=c3,this.rangeIndex=0,this.pos=this.chunkPos=t[0].from,this.range=t[0],this.end=t[t.length-1].to,this.readNext()}resolveOffset(e,t){let n=this.range,r=this.rangeIndex,i=this.pos+e;for(;i<n.from;){if(!r)return null;let e=this.ranges[--r];i-=n.from-e.to,n=e}for(;t<0?i>n.to:i>=n.to;){if(r==this.ranges.length-1)return null;let e=this.ranges[++r];i+=e.from-n.to,n=e}return i}clipPos(e){if(e>=this.range.from&&e<this.range.to)return e;for(let t of this.ranges)if(t.to>e)return Math.max(e,t.from);return this.end}peek(e){let t=this.chunkOff+e,n,r;if(t>=0&&t<this.chunk.length)n=this.pos+e,r=this.chunk.charCodeAt(t);else{let t=this.resolveOffset(e,1);if(null==t)return -1;if((n=t)>=this.chunk2Pos&&n<this.chunk2Pos+this.chunk2.length)r=this.chunk2.charCodeAt(n-this.chunk2Pos);else{let e=this.rangeIndex,t=this.range;for(;t.to<=n;)t=this.ranges[++e];this.chunk2=this.input.chunk(this.chunk2Pos=n),n+this.chunk2.length>t.to&&(this.chunk2=this.chunk2.slice(0,t.to-n)),r=this.chunk2.charCodeAt(0)}}return n>=this.token.lookAhead&&(this.token.lookAhead=n+1),r}acceptToken(e,t=0){let n=t?this.resolveOffset(t,-1):this.pos;if(null==n||n<this.token.start)throw RangeError("Token end out of bounds");this.token.value=e,this.token.end=n}acceptTokenTo(e,t){this.token.value=e,this.token.end=t}getChunk(){if(this.pos>=this.chunk2Pos&&this.pos<this.chunk2Pos+this.chunk2.length){let{chunk:e,chunkPos:t}=this;this.chunk=this.chunk2,this.chunkPos=this.chunk2Pos,this.chunk2=e,this.chunk2Pos=t,this.chunkOff=this.pos-this.chunkPos}else{this.chunk2=this.chunk,this.chunk2Pos=this.chunkPos;let e=this.input.chunk(this.pos),t=this.pos+e.length;this.chunk=t>this.range.to?e.slice(0,this.range.to-this.pos):e,this.chunkPos=this.pos,this.chunkOff=0}}readNext(){return this.chunkOff>=this.chunk.length&&(this.getChunk(),this.chunkOff==this.chunk.length)?this.next=-1:this.next=this.chunk.charCodeAt(this.chunkOff)}advance(e=1){for(this.chunkOff+=e;this.pos+e>=this.range.to;){if(this.rangeIndex==this.ranges.length-1)return this.setDone();e-=this.range.to-this.pos,this.range=this.ranges[++this.rangeIndex],this.pos=this.range.from}return this.pos+=e,this.pos>=this.token.lookAhead&&(this.token.lookAhead=this.pos+1),this.readNext()}setDone(){return this.pos=this.chunkPos=this.end,this.range=this.ranges[this.rangeIndex=this.ranges.length-1],this.chunk="",this.next=-1}reset(e,t){if(t?(this.token=t,t.start=e,t.lookAhead=e+1,t.value=t.extended=-1):this.token=c3,this.pos!=e){if(this.pos=e,e==this.end)return this.setDone(),this;for(;e<this.range.from;)this.range=this.ranges[--this.rangeIndex];for(;e>=this.range.to;)this.range=this.ranges[++this.rangeIndex];e>=this.chunkPos&&e<this.chunkPos+this.chunk.length?this.chunkOff=e-this.chunkPos:(this.chunk="",this.chunkOff=0),this.readNext()}return this}read(e,t){if(e>=this.chunkPos&&t<=this.chunkPos+this.chunk.length)return this.chunk.slice(e-this.chunkPos,t-this.chunkPos);if(e>=this.chunk2Pos&&t<=this.chunk2Pos+this.chunk2.length)return this.chunk2.slice(e-this.chunk2Pos,t-this.chunk2Pos);if(e>=this.range.from&&t<=this.range.to)return this.input.read(e,t);let n="";for(let r of this.ranges){if(r.from>=t)break;r.to>e&&(n+=this.input.read(Math.max(r.from,e),Math.min(r.to,t)))}return n}}class c8{constructor(e,t){this.data=e,this.id=t}token(e,t){let{parser:n}=t.p;c4(this.data,e,t,this.id,n.data,n.tokenPrecTable)}}c8.prototype.contextual=c8.prototype.fallback=c8.prototype.extend=!1;function c4(e,t,n,r,i,s){let o=0,l=1<<r,{dialect:a}=n.p.parser;r:for(;(l&e[o])!=0;){let n=e[o+1];for(let r=o+3;r<n;r+=2)if((e[r+1]&l)>0){let n=e[r];if(a.allows(n)&&(-1==t.token.value||t.token.value==n||function(e,t,n,r){let i=c6(n,r,t);return i<0||c6(n,r,e)<i}(n,t.token.value,i,s))){t.acceptToken(n);break}}let r=t.next,u=0,h=e[o+2];if(t.next<0&&h>u&&65535==e[n+3*h-3]){o=e[n+3*h-1];continue}for(;u<h;){let i=u+h>>1,s=n+i+(i<<1),l=e[s],a=e[s+1]||65536;if(r<l)h=i;else if(r>=a)u=i+1;else{o=e[s+2],t.advance();continue r}}break}}function c6(e,t,n){for(let r=t,i;65535!=(i=e[r]);r++)if(i==n)return r-t;return -1}(class e{constructor(e,t,n){this.precTable=t,this.elseToken=n,this.data="string"==typeof e?c1(e):e}token(e,t){let n=e.pos,r=0;for(;;){let n=e.next<0,i=e.resolveOffset(1,1);if(c4(this.data,e,t,0,this.data,this.precTable),e.token.value>-1)break;if(null==this.elseToken)return;if(!n&&r++,null==i)break;e.reset(i,e.token)}r&&(e.reset(n,e.token),e.acceptToken(this.elseToken,r))}}).prototype.contextual=c8.prototype.fallback=c8.prototype.extend=!1;let c9="undefined"!=typeof process&&process.env&&/\bparse\b/.test(process.env.LOG),c7=null;function fe(e,t,n){let r=e.cursor(cQ.vj.IncludeAnonymous);for(r.moveTo(t);;)if(!(n<0?r.childBefore(t):r.childAfter(t)))for(;;){if((n<0?r.to<t:r.from>t)&&!r.type.isError)return n<0?Math.max(0,Math.min(r.to-1,t-25)):Math.min(e.length,Math.max(r.from+1,t+25));if(n<0?r.prevSibling():r.nextSibling())break;if(!r.parent())return n<0?0:e.length}}class ft{constructor(e,t){this.fragments=e,this.nodeSet=t,this.i=0,this.fragment=null,this.safeFrom=-1,this.safeTo=-1,this.trees=[],this.start=[],this.index=[],this.nextFragment()}nextFragment(){let e=this.fragment=this.i==this.fragments.length?null:this.fragments[this.i++];if(e){for(this.safeFrom=e.openStart?fe(e.tree,e.from+e.offset,1)-e.offset:e.from,this.safeTo=e.openEnd?fe(e.tree,e.to+e.offset,-1)-e.offset:e.to;this.trees.length;)this.trees.pop(),this.start.pop(),this.index.pop();this.trees.push(e.tree),this.start.push(-e.offset),this.index.push(0),this.nextStart=this.safeFrom}else this.nextStart=1e9}nodeAt(e){if(e<this.nextStart)return null;for(;this.fragment&&this.safeTo<=e;)this.nextFragment();if(!this.fragment)return null;for(;;){let t=this.trees.length-1;if(t<0)return this.nextFragment(),null;let n=this.trees[t],r=this.index[t];if(r==n.children.length){this.trees.pop(),this.start.pop(),this.index.pop();continue}let i=n.children[r],s=this.start[t]+n.positions[r];if(s>e)return this.nextStart=s,null;if(i instanceof cQ.mp){if(s==e){if(s<this.safeFrom)return null;let e=s+i.length;if(e<=this.safeTo){let t=i.prop(cQ.md.lookAhead);if(!t||e+t<this.fragment.to)return i}}this.index[t]++,s+i.length>=Math.max(this.safeFrom,e)&&(this.trees.push(i),this.start.push(s),this.index.push(0))}else this.index[t]++,this.nextStart=s+i.length}}}class fn{constructor(e,t){this.stream=t,this.tokens=[],this.mainToken=null,this.actions=[],this.tokens=e.tokenizers.map(e=>new c2)}getActions(e){let t=0,n=null,{parser:r}=e.p,{tokenizers:i}=r,s=r.stateSlot(e.state,3),o=e.curContext?e.curContext.hash:0,l=0;for(let r=0;r<i.length;r++){if((1<<r&s)==0)continue;let a=i[r],u=this.tokens[r];if((!n||a.fallback)&&((a.contextual||u.start!=e.pos||u.mask!=s||u.context!=o)&&(this.updateCachedToken(u,a,e),u.mask=s,u.context=o),u.lookAhead>u.end+25&&(l=Math.max(u.lookAhead,l)),0!=u.value)){let r=t;if(u.extended>-1&&(t=this.addActions(e,u.extended,u.end,t)),t=this.addActions(e,u.value,u.end,t),!a.extend&&(n=u,t>r))break}}for(;this.actions.length>t;)this.actions.pop();return l&&e.setLookAhead(l),!n&&e.pos==this.stream.end&&((n=new c2).value=e.p.parser.eofTerm,n.start=n.end=e.pos,t=this.addActions(e,n.value,n.end,t)),this.mainToken=n,this.actions}getMainToken(e){if(this.mainToken)return this.mainToken;let t=new c2,{pos:n,p:r}=e;return t.start=n,t.end=Math.min(n+1,r.stream.end),t.value=n==r.stream.end?r.parser.eofTerm:0,t}updateCachedToken(e,t,n){let r=this.stream.clipPos(n.pos);if(t.token(this.stream.reset(r,e),n),e.value>-1){let{parser:t}=n.p;for(let r=0;r<t.specialized.length;r++)if(t.specialized[r]==e.value){let i=t.specializers[r](this.stream.read(e.start,e.end),n);if(i>=0&&n.p.parser.dialect.allows(i>>1)){(1&i)==0?e.value=i>>1:e.extended=i>>1;break}}}else e.value=0,e.end=this.stream.clipPos(r+1)}putAction(e,t,n,r){for(let t=0;t<r;t+=3)if(this.actions[t]==e)return r;return this.actions[r++]=e,this.actions[r++]=t,this.actions[r++]=n,r}addActions(e,t,n,r){let{state:i}=e,{parser:s}=e.p,{data:o}=s;for(let e=0;e<2;e++)for(let l=s.stateSlot(i,e?2:1);;l+=3){if(65535==o[l]){if(1==o[l+1])l=fl(o,l+2);else{0==r&&2==o[l+1]&&(r=this.putAction(fl(o,l+2),t,n,r));break}}o[l]==t&&(r=this.putAction(fl(o,l+1),t,n,r))}return r}}class fr{constructor(e,t,n,r){this.parser=e,this.input=t,this.ranges=r,this.recovering=0,this.nextStackID=9812,this.minStackPos=0,this.reused=[],this.stoppedAt=null,this.lastBigReductionStart=-1,this.lastBigReductionSize=0,this.bigReductionCount=0,this.stream=new c5(t,r),this.tokens=new fn(e,this.stream),this.topTerm=e.top[1];let{from:i}=r[0];this.stacks=[cY.start(this,e.top[0],i)],this.fragments=n.length&&this.stream.end-i>4*e.bufferLength?new ft(n,e.nodeSet):null}get parsedPos(){return this.minStackPos}advance(){let e,t,n=this.stacks,r=this.minStackPos,i=this.stacks=[];if(this.bigReductionCount>300&&1==n.length){let[e]=n;for(;e.forceReduce()&&e.stack.length&&e.stack[e.stack.length-2]>=this.lastBigReductionStart;);this.bigReductionCount=this.lastBigReductionSize=0}for(let s=0;s<n.length;s++){let o=n[s];for(;;){if(this.tokens.mainToken=null,o.pos>r)i.push(o);else{if(this.advanceStack(o,i,n))continue;!e&&(e=[],t=[]),e.push(o);let r=this.tokens.getMainToken(o);t.push(r.value,r.end)}break}}if(!i.length){let t=e&&function(e){let t=null;for(let n of e){let e=n.p.stoppedAt;(n.pos==n.p.stream.end||null!=e&&n.pos>e)&&n.p.parser.stateFlag(n.state,2)&&(!t||t.score<n.score)&&(t=n)}return t}(e);if(t)return c9&&console.log("Finish with "+this.stackID(t)),this.stackToTree(t);if(this.parser.strict)throw c9&&e&&console.log("Stuck with token "+(this.tokens.mainToken?this.parser.getName(this.tokens.mainToken.value):"none")),SyntaxError("No parse at "+r);!this.recovering&&(this.recovering=5)}if(this.recovering&&e){let n=null!=this.stoppedAt&&e[0].pos>this.stoppedAt?e[0]:this.runRecovery(e,t,i);if(n)return c9&&console.log("Force-finish "+this.stackID(n)),this.stackToTree(n.forceAll())}if(this.recovering){let e=1==this.recovering?1:3*this.recovering;if(i.length>e)for(i.sort((e,t)=>t.score-e.score);i.length>e;)i.pop();i.some(e=>e.reducePos>r)&&this.recovering--}else if(i.length>1){o:for(let e=0;e<i.length-1;e++){let t=i[e];for(let n=e+1;n<i.length;n++){let r=i[n];if(t.sameState(r)||t.buffer.length>500&&r.buffer.length>500){if((t.score-r.score||t.buffer.length-r.buffer.length)>0)i.splice(n--,1);else{i.splice(e--,1);continue o}}}}i.length>12&&i.splice(12,i.length-12)}this.minStackPos=i[0].pos;for(let e=1;e<i.length;e++)i[e].pos<this.minStackPos&&(this.minStackPos=i[e].pos);return null}stopAt(e){if(null!=this.stoppedAt&&this.stoppedAt<e)throw RangeError("Can't move stoppedAt forward");this.stoppedAt=e}advanceStack(e,t,n){let r=e.pos,{parser:i}=this,s=c9?this.stackID(e)+" -> ":"";if(null!=this.stoppedAt&&r>this.stoppedAt)return e.forceReduce()?e:null;if(this.fragments){let t=e.curContext&&e.curContext.tracker.strict,n=t?e.curContext.hash:0;for(let o=this.fragments.nodeAt(r);o;){let r=this.parser.nodeSet.types[o.type.id]==o.type?i.getGoto(e.state,o.type.id):-1;if(r>-1&&o.length&&(!t||(o.prop(cQ.md.contextHash)||0)==n))return e.useNode(o,r),c9&&console.log(s+this.stackID(e)+` (via reuse of ${i.getName(o.type.id)})`),!0;if(!(o instanceof cQ.mp)||0==o.children.length||o.positions[0]>0)break;let l=o.children[0];if(l instanceof cQ.mp&&0==o.positions[0])o=l;else break}}let o=i.stateSlot(e.state,4);if(o>0)return e.reduce(o),c9&&console.log(s+this.stackID(e)+` (via always-reduce ${i.getName(65535&o)})`),!0;if(e.stack.length>=8400)for(;e.stack.length>6e3&&e.forceReduce(););let l=this.tokens.getActions(e);for(let o=0;o<l.length;){let a=l[o++],u=l[o++],h=l[o++],c=o==l.length||!n,f=c?e:e.split(),d=this.tokens.mainToken;if(f.apply(a,u,d?d.start:f.pos,h),c9&&console.log(s+this.stackID(f)+` (via ${(65536&a)==0?"shift":`reduce of ${i.getName(65535&a)}`} for ${i.getName(u)} @ ${r}${f==e?"":", split"})`),c)return!0;f.pos>r?t.push(f):n.push(f)}return!1}advanceFully(e,t){let n=e.pos;for(;;){if(!this.advanceStack(e,null,null))return!1;if(e.pos>n)return fi(e,t),!0}}runRecovery(e,t,n){let r=null,i=!1;for(let s=0;s<e.length;s++){let o=e[s],l=t[s<<1],a=t[(s<<1)+1],u=c9?this.stackID(o)+" -> ":"";if(o.deadEnd){if(i)continue;if(i=!0,o.restart(),c9&&console.log(u+this.stackID(o)+" (restarted)"),this.advanceFully(o,n))continue}let h=o.split(),c=u;for(let e=0;h.forceReduce()&&e<10&&(c9&&console.log(c+this.stackID(h)+" (via force-reduce)"),!this.advanceFully(h,n));e++){;c9&&(c=this.stackID(h)+" -> ")}for(let e of o.recoverByInsert(l))c9&&console.log(u+this.stackID(e)+" (via recover-insert)"),this.advanceFully(e,n);this.stream.end>o.pos?(a==o.pos&&(a++,l=0),o.recoverByDelete(l,a),c9&&console.log(u+this.stackID(o)+` (via recover-delete ${this.parser.getName(l)})`),fi(o,n)):(!r||r.score<o.score)&&(r=o)}return r}stackToTree(e){return e.close(),cQ.mp.build({buffer:c0.create(e),nodeSet:this.parser.nodeSet,topID:this.topTerm,maxBufferLength:this.parser.bufferLength,reused:this.reused,start:this.ranges[0].from,length:e.pos-this.ranges[0].from,minRepeatType:this.parser.minRepeatTerm})}stackID(e){let t=(c7||(c7=new WeakMap)).get(e);return!t&&c7.set(e,t=String.fromCodePoint(this.nextStackID++)),t+e}}function fi(e,t){for(let n=0;n<t.length;n++){let r=t[n];if(r.pos==e.pos&&r.sameState(e)){t[n].score<e.score&&(t[n]=e);return}}t.push(e)}class fs{constructor(e,t,n){this.source=e,this.flags=t,this.disabled=n}allows(e){return!this.disabled||0==this.disabled[e]}}class fo extends cQ._b{constructor(e){if(super(),this.wrappers=[],14!=e.version)throw RangeError(`Parser version (${e.version}) doesn't match runtime version (14)`);let t=e.nodeNames.split(" ");this.minRepeatTerm=t.length;for(let n=0;n<e.repeatNodeCount;n++)t.push("");let n=Object.keys(e.topRules).map(t=>e.topRules[t][1]),r=[];for(let e=0;e<t.length;e++)r.push([]);function i(e,t,n){r[e].push([t,t.deserialize(String(n))])}if(e.nodeProps)for(let t of e.nodeProps){let e=t[0];"string"==typeof e&&(e=cQ.md[e]);for(let n=1;n<t.length;){let r=t[n++];if(r>=0)i(r,e,t[n++]);else{let s=t[n+-r];for(let o=-r;o>0;o--)i(t[n++],e,s);n++}}}this.nodeSet=new cQ.Lj(t.map((t,i)=>cQ.Jq.define({name:i>=this.minRepeatTerm?void 0:t,id:i,props:r[i],top:n.indexOf(i)>-1,error:0==i,skipped:e.skippedNodes&&e.skippedNodes.indexOf(i)>-1}))),e.propSources&&(this.nodeSet=this.nodeSet.extend(...e.propSources)),this.strict=!1,this.bufferLength=cQ.L3;let s=c1(e.tokenData);this.context=e.context,this.specializerSpecs=e.specialized||[],this.specialized=new Uint16Array(this.specializerSpecs.length);for(let e=0;e<this.specializerSpecs.length;e++)this.specialized[e]=this.specializerSpecs[e].term;this.specializers=this.specializerSpecs.map(fa),this.states=c1(e.states,Uint32Array),this.data=c1(e.stateData),this.goto=c1(e.goto),this.maxTerm=e.maxTerm,this.tokenizers=e.tokenizers.map(e=>"number"==typeof e?new c8(s,e):e),this.topRules=e.topRules,this.dialects=e.dialects||{},this.dynamicPrecedences=e.dynamicPrecedences||null,this.tokenPrecTable=e.tokenPrec,this.termNames=e.termNames||null,this.maxNode=this.nodeSet.types.length-1,this.dialect=this.parseDialect(),this.top=this.topRules[Object.keys(this.topRules)[0]]}createParse(e,t,n){let r=new fr(this,e,t,n);for(let i of this.wrappers)r=i(r,e,t,n);return r}getGoto(e,t,n=!1){let r=this.goto;if(t>=r[0])return -1;for(let i=r[t+1];;){let t=r[i++],s=1&t,o=r[i++];if(s&&n)return o;for(let n=i+(t>>1);i<n;i++)if(r[i]==e)return o;if(s)return -1}}hasAction(e,t){let n=this.data;for(let r=0;r<2;r++)for(let i=this.stateSlot(e,r?2:1),s;;i+=3){if(65535==(s=n[i])){if(1==n[i+1])s=n[i=fl(n,i+2)];else if(2==n[i+1])return fl(n,i+2);else break}if(s==t||0==s)return fl(n,i+1)}return 0}stateSlot(e,t){return this.states[6*e+t]}stateFlag(e,t){return(this.stateSlot(e,0)&t)>0}validAction(e,t){return!!this.allActions(e,e=>e==t||null)}allActions(e,t){let n=this.stateSlot(e,4),r=n?t(n):void 0;for(let n=this.stateSlot(e,1);null==r;n+=3){if(65535==this.data[n]){if(1==this.data[n+1])n=fl(this.data,n+2);else break}r=t(fl(this.data,n+1))}return r}nextStates(e){let t=[];for(let n=this.stateSlot(e,1);;n+=3){if(65535==this.data[n]){if(1==this.data[n+1])n=fl(this.data,n+2);else break}if((1&this.data[n+2])==0){let e=this.data[n+1];!t.some((t,n)=>1&n&&t==e)&&t.push(this.data[n],e)}}return t}configure(e){let t=Object.assign(Object.create(fo.prototype),this);if(e.props&&(t.nodeSet=this.nodeSet.extend(...e.props)),e.top){let n=this.topRules[e.top];if(!n)throw RangeError(`Invalid top rule name ${e.top}`);t.top=n}return e.tokenizers&&(t.tokenizers=this.tokenizers.map(t=>{let n=e.tokenizers.find(e=>e.from==t);return n?n.to:t})),e.specializers&&(t.specializers=this.specializers.slice(),t.specializerSpecs=this.specializerSpecs.map((n,r)=>{let i=e.specializers.find(e=>e.from==n.external);if(!i)return n;let s=Object.assign(Object.assign({},n),{external:i.to});return t.specializers[r]=fa(s),s})),e.contextTracker&&(t.context=e.contextTracker),e.dialect&&(t.dialect=this.parseDialect(e.dialect)),null!=e.strict&&(t.strict=e.strict),e.wrap&&(t.wrappers=t.wrappers.concat(e.wrap)),null!=e.bufferLength&&(t.bufferLength=e.bufferLength),t}hasWrappers(){return this.wrappers.length>0}getName(e){return this.termNames?this.termNames[e]:String(e<=this.maxNode&&this.nodeSet.types[e].name||e)}get eofTerm(){return this.maxNode+1}get topNode(){return this.nodeSet.types[this.top[1]]}dynamicPrecedence(e){let t=this.dynamicPrecedences;return null==t?0:t[e]||0}parseDialect(e){let t=Object.keys(this.dialects),n=t.map(()=>!1);if(e)for(let r of e.split(" ")){let e=t.indexOf(r);e>=0&&(n[e]=!0)}let r=null;for(let e=0;e<t.length;e++)if(!n[e])for(let n=this.dialects[t[e]],i;65535!=(i=this.data[n++]);)(r||(r=new Uint8Array(this.maxTerm+1)))[i]=1;return new fs(e,n,r)}static deserialize(e){return new fo(e)}}function fl(e,t){return e[t]|e[t+1]<<16}function fa(e){if(e.external){let t=e.extend?1:0;return(n,r)=>e.external(n,r)<<1|t}return e.get}var fu=n("42367");let fh=(0,fu.Gv)({String:fu.pJ.string,Number:fu.pJ.number,"True False":fu.pJ.bool,PropertyName:fu.pJ.propertyName,Null:fu.pJ.null,",":fu.pJ.separator,"[ ]":fu.pJ.squareBracket,"{ }":fu.pJ.brace}),fc=fo.deserialize({version:14,states:"$bOVQPOOOOQO'#Cb'#CbOnQPO'#CeOvQPO'#CjOOQO'#Cp'#CpQOQPOOOOQO'#Cg'#CgO}QPO'#CfO!SQPO'#CrOOQO,59P,59PO![QPO,59PO!aQPO'#CuOOQO,59U,59UO!iQPO,59UOVQPO,59QOqQPO'#CkO!nQPO,59^OOQO1G.k1G.kOVQPO'#ClO!vQPO,59aOOQO1G.p1G.pOOQO1G.l1G.lOOQO,59V,59VOOQO-E6i-E6iOOQO,59W,59WOOQO-E6j-E6j",stateData:"#O~OcOS~OQSORSOSSOTSOWQO]ROePO~OVXOeUO~O[[O~PVOg^O~Oh_OVfX~OVaO~OhbO[iX~O[dO~Oh_OVfa~OhbO[ia~O",goto:"!kjPPPPPPkPPkqwPPk{!RPPP!XP!ePP!hXSOR^bQWQRf_TVQ_Q`WRg`QcZRicQTOQZRQe^RhbRYQR]R",nodeNames:"⚠ JsonText True False Null Number String } { Object Property PropertyName ] [ Array",maxTerm:25,nodeProps:[["isolate",-2,6,11,""],["openedBy",7,"{",12,"["],["closedBy",8,"}",13,"]"]],propSources:[fh],skippedNodes:[0],repeatNodeCount:2,tokenData:"(|~RaXY!WYZ!W]^!Wpq!Wrs!]|}$u}!O$z!Q!R%T!R![&c![!]&t!}#O&y#P#Q'O#Y#Z'T#b#c'r#h#i(Z#o#p(r#q#r(w~!]Oc~~!`Wpq!]qr!]rs!xs#O!]#O#P!}#P;'S!];'S;=`$o<%lO!]~!}Oe~~#QXrs!]!P!Q!]#O#P!]#U#V!]#Y#Z!]#b#c!]#f#g!]#h#i!]#i#j#m~#pR!Q![#y!c!i#y#T#Z#y~#|R!Q![$V!c!i$V#T#Z$V~$YR!Q![$c!c!i$c#T#Z$c~$fR!Q![!]!c!i!]#T#Z!]~$rP;=`<%l!]~$zOh~~$}Q!Q!R%T!R![&c~%YRT~!O!P%c!g!h%w#X#Y%w~%fP!Q![%i~%nRT~!Q![%i!g!h%w#X#Y%w~%zR{|&T}!O&T!Q![&Z~&WP!Q![&Z~&`PT~!Q![&Z~&hST~!O!P%c!Q![&c!g!h%w#X#Y%w~&yOg~~'OO]~~'TO[~~'WP#T#U'Z~'^P#`#a'a~'dP#g#h'g~'jP#X#Y'm~'rOR~~'uP#i#j'x~'{P#`#a(O~(RP#`#a(U~(ZOS~~(^P#f#g(a~(dP#i#j(g~(jP#X#Y(m~(rOQ~~(wOW~~(|OV~",tokenizers:[0],topRules:{JsonText:[0,1]},tokenPrec:0}),ff=()=>e=>{try{JSON.parse(e.state.doc.toString())}catch(n){if(!(n instanceof SyntaxError))throw n;let t=function(e,t){let n;return(n=e.message.match(/at position (\d+)/))?Math.min(+n[1],t.length):(n=e.message.match(/at line (\d+) column (\d+)/))?Math.min(t.line(+n[1]).from+ +n[2]-1,t.length):0}(n,e.state.doc);return[{from:t,message:n.message,severity:"error",to:t}]}return[]},fd=j.qp.define({name:"json",parser:fc.configure({props:[j.uj.add({Object:(0,j.tC)({except:/^\s*\}/}),Array:(0,j.tC)({except:/^\s*\]/})}),j.x0.add({"Object Array":j.Dv})]}),languageData:{closeBrackets:{brackets:["[","{",'"']},indentOnInput:/^\s*[\}\]]$/}});var fp=n("76621"),fm=n("77730");function fg(e){return[new j.ri(fd),(0,fm.ir)(ff()),(0,fm.ir)(function(e){let t=new cW(void 0);return e=>t.doValidation(e)}(),{needsRefresh:cU}),fd.data.of({autocomplete:function(e={}){let t=new aV(e);return function(e){return t.doComplete(e)}}()}),(0,fp.bF)(function(e){let t=new cJ(void 0);return async function(e,n,r){return t.doHover(e,n,r)}}()),eb(e)]}}}]);
|