lone-format 0.9.0 → 0.9.6

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.
@@ -1,25 +1,55 @@
1
- (function(Ye,s){typeof exports=="object"&&typeof module<"u"?s(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],s):(Ye=typeof globalThis<"u"?globalThis:Ye||self,s(Ye.LoneFormat={},Ye.Vue))})(this,function(Ye,s){"use strict";class rr{add(t,r,u){if(typeof arguments[0]!="string")for(let i in arguments[0])this.add(i,arguments[0][i],arguments[1]);else(Array.isArray(t)?t:[t]).forEach(function(i){this[i]=this[i]||[],r&&this[i][u?"unshift":"push"](r)},this)}run(t,r){this[t]=this[t]||[],this[t].forEach(function(u){u.call(r&&r.context?r.context:r,r)})}}class nr{constructor(t){this.jsep=t,this.registered={}}register(){for(var t=arguments.length,r=new Array(t),u=0;u<t;u++)r[u]=arguments[u];r.forEach(i=>{if(typeof i!="object"||!i.name||!i.init)throw new Error("Invalid JSEP plugin format");this.registered[i.name]||(i.init(this.jsep),this.registered[i.name]=i)})}}class O{static get version(){return"1.4.0"}static toString(){return"JavaScript Expression Parser (JSEP) v"+O.version}static addUnaryOp(t){return O.max_unop_len=Math.max(t.length,O.max_unop_len),O.unary_ops[t]=1,O}static addBinaryOp(t,r,u){return O.max_binop_len=Math.max(t.length,O.max_binop_len),O.binary_ops[t]=r,u?O.right_associative.add(t):O.right_associative.delete(t),O}static addIdentifierChar(t){return O.additional_identifier_chars.add(t),O}static addLiteral(t,r){return O.literals[t]=r,O}static removeUnaryOp(t){return delete O.unary_ops[t],t.length===O.max_unop_len&&(O.max_unop_len=O.getMaxKeyLen(O.unary_ops)),O}static removeAllUnaryOps(){return O.unary_ops={},O.max_unop_len=0,O}static removeIdentifierChar(t){return O.additional_identifier_chars.delete(t),O}static removeBinaryOp(t){return delete O.binary_ops[t],t.length===O.max_binop_len&&(O.max_binop_len=O.getMaxKeyLen(O.binary_ops)),O.right_associative.delete(t),O}static removeAllBinaryOps(){return O.binary_ops={},O.max_binop_len=0,O}static removeLiteral(t){return delete O.literals[t],O}static removeAllLiterals(){return O.literals={},O}get char(){return this.expr.charAt(this.index)}get code(){return this.expr.charCodeAt(this.index)}constructor(t){this.expr=t,this.index=0}static parse(t){return new O(t).parse()}static getMaxKeyLen(t){return Math.max(0,...Object.keys(t).map(r=>r.length))}static isDecimalDigit(t){return t>=48&&t<=57}static binaryPrecedence(t){return O.binary_ops[t]||0}static isIdentifierStart(t){return t>=65&&t<=90||t>=97&&t<=122||t>=128&&!O.binary_ops[String.fromCharCode(t)]||O.additional_identifier_chars.has(String.fromCharCode(t))}static isIdentifierPart(t){return O.isIdentifierStart(t)||O.isDecimalDigit(t)}throwError(t){const r=new Error(t+" at character "+this.index);throw r.index=this.index,r.description=t,r}runHook(t,r){if(O.hooks[t]){const u={context:this,node:r};return O.hooks.run(t,u),u.node}return r}searchHook(t){if(O.hooks[t]){const r={context:this};return O.hooks[t].find(function(u){return u.call(r.context,r),r.node}),r.node}}gobbleSpaces(){let t=this.code;for(;t===O.SPACE_CODE||t===O.TAB_CODE||t===O.LF_CODE||t===O.CR_CODE;)t=this.expr.charCodeAt(++this.index);this.runHook("gobble-spaces")}parse(){this.runHook("before-all");const t=this.gobbleExpressions(),r=t.length===1?t[0]:{type:O.COMPOUND,body:t};return this.runHook("after-all",r)}gobbleExpressions(t){let r=[],u,i;for(;this.index<this.expr.length;)if(u=this.code,u===O.SEMCOL_CODE||u===O.COMMA_CODE)this.index++;else if(i=this.gobbleExpression())r.push(i);else if(this.index<this.expr.length){if(u===t)break;this.throwError('Unexpected "'+this.char+'"')}return r}gobbleExpression(){const t=this.searchHook("gobble-expression")||this.gobbleBinaryExpression();return this.gobbleSpaces(),this.runHook("after-expression",t)}gobbleBinaryOp(){this.gobbleSpaces();let t=this.expr.substr(this.index,O.max_binop_len),r=t.length;for(;r>0;){if(O.binary_ops.hasOwnProperty(t)&&(!O.isIdentifierStart(this.code)||this.index+t.length<this.expr.length&&!O.isIdentifierPart(this.expr.charCodeAt(this.index+t.length))))return this.index+=r,t;t=t.substr(0,--r)}return!1}gobbleBinaryExpression(){let t,r,u,i,l,p,N,h,m;if(p=this.gobbleToken(),!p||(r=this.gobbleBinaryOp(),!r))return p;for(l={value:r,prec:O.binaryPrecedence(r),right_a:O.right_associative.has(r)},N=this.gobbleToken(),N||this.throwError("Expected expression after "+r),i=[p,l,N];r=this.gobbleBinaryOp();){if(u=O.binaryPrecedence(r),u===0){this.index-=r.length;break}l={value:r,prec:u,right_a:O.right_associative.has(r)},m=r;const B=T=>l.right_a&&T.right_a?u>T.prec:u<=T.prec;for(;i.length>2&&B(i[i.length-2]);)N=i.pop(),r=i.pop().value,p=i.pop(),t={type:O.BINARY_EXP,operator:r,left:p,right:N},i.push(t);t=this.gobbleToken(),t||this.throwError("Expected expression after "+m),i.push(l,t)}for(h=i.length-1,t=i[h];h>1;)t={type:O.BINARY_EXP,operator:i[h-1].value,left:i[h-2],right:t},h-=2;return t}gobbleToken(){let t,r,u,i;if(this.gobbleSpaces(),i=this.searchHook("gobble-token"),i)return this.runHook("after-token",i);if(t=this.code,O.isDecimalDigit(t)||t===O.PERIOD_CODE)return this.gobbleNumericLiteral();if(t===O.SQUOTE_CODE||t===O.DQUOTE_CODE)i=this.gobbleStringLiteral();else if(t===O.OBRACK_CODE)i=this.gobbleArray();else{for(r=this.expr.substr(this.index,O.max_unop_len),u=r.length;u>0;){if(O.unary_ops.hasOwnProperty(r)&&(!O.isIdentifierStart(this.code)||this.index+r.length<this.expr.length&&!O.isIdentifierPart(this.expr.charCodeAt(this.index+r.length)))){this.index+=u;const l=this.gobbleToken();return l||this.throwError("missing unaryOp argument"),this.runHook("after-token",{type:O.UNARY_EXP,operator:r,argument:l,prefix:!0})}r=r.substr(0,--u)}O.isIdentifierStart(t)?(i=this.gobbleIdentifier(),O.literals.hasOwnProperty(i.name)?i={type:O.LITERAL,value:O.literals[i.name],raw:i.name}:i.name===O.this_str&&(i={type:O.THIS_EXP})):t===O.OPAREN_CODE&&(i=this.gobbleGroup())}return i?(i=this.gobbleTokenProperty(i),this.runHook("after-token",i)):this.runHook("after-token",!1)}gobbleTokenProperty(t){this.gobbleSpaces();let r=this.code;for(;r===O.PERIOD_CODE||r===O.OBRACK_CODE||r===O.OPAREN_CODE||r===O.QUMARK_CODE;){let u;if(r===O.QUMARK_CODE){if(this.expr.charCodeAt(this.index+1)!==O.PERIOD_CODE)break;u=!0,this.index+=2,this.gobbleSpaces(),r=this.code}this.index++,r===O.OBRACK_CODE?(t={type:O.MEMBER_EXP,computed:!0,object:t,property:this.gobbleExpression()},t.property||this.throwError('Unexpected "'+this.char+'"'),this.gobbleSpaces(),r=this.code,r!==O.CBRACK_CODE&&this.throwError("Unclosed ["),this.index++):r===O.OPAREN_CODE?t={type:O.CALL_EXP,arguments:this.gobbleArguments(O.CPAREN_CODE),callee:t}:(r===O.PERIOD_CODE||u)&&(u&&this.index--,this.gobbleSpaces(),t={type:O.MEMBER_EXP,computed:!1,object:t,property:this.gobbleIdentifier()}),u&&(t.optional=!0),this.gobbleSpaces(),r=this.code}return t}gobbleNumericLiteral(){let t="",r,u;for(;O.isDecimalDigit(this.code);)t+=this.expr.charAt(this.index++);if(this.code===O.PERIOD_CODE)for(t+=this.expr.charAt(this.index++);O.isDecimalDigit(this.code);)t+=this.expr.charAt(this.index++);if(r=this.char,r==="e"||r==="E"){for(t+=this.expr.charAt(this.index++),r=this.char,(r==="+"||r==="-")&&(t+=this.expr.charAt(this.index++));O.isDecimalDigit(this.code);)t+=this.expr.charAt(this.index++);O.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+t+this.char+")")}return u=this.code,O.isIdentifierStart(u)?this.throwError("Variable names cannot start with a number ("+t+this.char+")"):(u===O.PERIOD_CODE||t.length===1&&t.charCodeAt(0)===O.PERIOD_CODE)&&this.throwError("Unexpected period"),{type:O.LITERAL,value:parseFloat(t),raw:t}}gobbleStringLiteral(){let t="";const r=this.index,u=this.expr.charAt(this.index++);let i=!1;for(;this.index<this.expr.length;){let l=this.expr.charAt(this.index++);if(l===u){i=!0;break}else if(l==="\\")switch(l=this.expr.charAt(this.index++),l){case"n":t+=`
2
- `;break;case"r":t+="\r";break;case"t":t+=" ";break;case"b":t+="\b";break;case"f":t+="\f";break;case"v":t+="\v";break;default:t+=l}else t+=l}return i||this.throwError('Unclosed quote after "'+t+'"'),{type:O.LITERAL,value:t,raw:this.expr.substring(r,this.index)}}gobbleIdentifier(){let t=this.code,r=this.index;for(O.isIdentifierStart(t)?this.index++:this.throwError("Unexpected "+this.char);this.index<this.expr.length&&(t=this.code,O.isIdentifierPart(t));)this.index++;return{type:O.IDENTIFIER,name:this.expr.slice(r,this.index)}}gobbleArguments(t){const r=[];let u=!1,i=0;for(;this.index<this.expr.length;){this.gobbleSpaces();let l=this.code;if(l===t){u=!0,this.index++,t===O.CPAREN_CODE&&i&&i>=r.length&&this.throwError("Unexpected token "+String.fromCharCode(t));break}else if(l===O.COMMA_CODE){if(this.index++,i++,i!==r.length){if(t===O.CPAREN_CODE)this.throwError("Unexpected token ,");else if(t===O.CBRACK_CODE)for(let p=r.length;p<i;p++)r.push(null)}}else if(r.length!==i&&i!==0)this.throwError("Expected comma");else{const p=this.gobbleExpression();(!p||p.type===O.COMPOUND)&&this.throwError("Expected comma"),r.push(p)}}return u||this.throwError("Expected "+String.fromCharCode(t)),r}gobbleGroup(){this.index++;let t=this.gobbleExpressions(O.CPAREN_CODE);if(this.code===O.CPAREN_CODE)return this.index++,t.length===1?t[0]:t.length?{type:O.SEQUENCE_EXP,expressions:t}:!1;this.throwError("Unclosed (")}gobbleArray(){return this.index++,{type:O.ARRAY_EXP,elements:this.gobbleArguments(O.CBRACK_CODE)}}}const or=new rr;Object.assign(O,{hooks:or,plugins:new nr(O),COMPOUND:"Compound",SEQUENCE_EXP:"SequenceExpression",IDENTIFIER:"Identifier",MEMBER_EXP:"MemberExpression",LITERAL:"Literal",THIS_EXP:"ThisExpression",CALL_EXP:"CallExpression",UNARY_EXP:"UnaryExpression",BINARY_EXP:"BinaryExpression",ARRAY_EXP:"ArrayExpression",TAB_CODE:9,LF_CODE:10,CR_CODE:13,SPACE_CODE:32,PERIOD_CODE:46,COMMA_CODE:44,SQUOTE_CODE:39,DQUOTE_CODE:34,OPAREN_CODE:40,CPAREN_CODE:41,OBRACK_CODE:91,CBRACK_CODE:93,QUMARK_CODE:63,SEMCOL_CODE:59,COLON_CODE:58,unary_ops:{"-":1,"!":1,"~":1,"+":1},binary_ops:{"||":1,"??":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10,"**":11},right_associative:new Set(["**"]),additional_identifier_chars:new Set(["$","_"]),literals:{true:!0,false:!1,null:null},this_str:"this"}),O.max_unop_len=O.getMaxKeyLen(O.unary_ops),O.max_binop_len=O.getMaxKeyLen(O.binary_ops);const We=n=>new O(n).parse(),sr=Object.getOwnPropertyNames(class{});Object.getOwnPropertyNames(O).filter(n=>!sr.includes(n)&&We[n]===void 0).forEach(n=>{We[n]=O[n]}),We.Jsep=O;const ir="ConditionalExpression";var ur={name:"ternary",init(n){n.hooks.add("after-expression",function(r){if(r.node&&this.code===n.QUMARK_CODE){this.index++;const u=r.node,i=this.gobbleExpression();if(i||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===n.COLON_CODE){this.index++;const l=this.gobbleExpression();if(l||this.throwError("Expected expression"),r.node={type:ir,test:u,consequent:i,alternate:l},u.operator&&n.binary_ops[u.operator]<=.9){let p=u;for(;p.right.operator&&n.binary_ops[p.right.operator]<=.9;)p=p.right;r.node.test=p.right,p.right=r.node,r.node=u}}else this.throwError("Expected :")}})}};We.plugins.register(ur);const Ot=47,ar=92;var lr={name:"regex",init(n){n.hooks.add("gobble-token",function(r){if(this.code===Ot){const u=++this.index;let i=!1;for(;this.index<this.expr.length;){if(this.code===Ot&&!i){const l=this.expr.slice(u,this.index);let p="";for(;++this.index<this.expr.length;){const h=this.code;if(h>=97&&h<=122||h>=65&&h<=90||h>=48&&h<=57)p+=this.char;else break}let N;try{N=new RegExp(l,p)}catch(h){this.throwError(h.message)}return r.node={type:n.LITERAL,value:N,raw:this.expr.slice(u-1,this.index)},r.node=this.gobbleTokenProperty(r.node),r.node}this.code===n.OBRACK_CODE?i=!0:i&&this.code===n.CBRACK_CODE&&(i=!1),this.index+=this.code===ar?2:1}this.throwError("Unclosed Regex")}})}};const Nt=43,ct={name:"assignment",assignmentOperators:new Set(["=","*=","**=","/=","%=","+=","-=","<<=",">>=",">>>=","&=","^=","|=","||=","&&=","??="]),updateOperators:[Nt,45],assignmentPrecedence:.9,init(n){const t=[n.IDENTIFIER,n.MEMBER_EXP];ct.assignmentOperators.forEach(u=>n.addBinaryOp(u,ct.assignmentPrecedence,!0)),n.hooks.add("gobble-token",function(i){const l=this.code;ct.updateOperators.some(p=>p===l&&p===this.expr.charCodeAt(this.index+1))&&(this.index+=2,i.node={type:"UpdateExpression",operator:l===Nt?"++":"--",argument:this.gobbleTokenProperty(this.gobbleIdentifier()),prefix:!0},(!i.node.argument||!t.includes(i.node.argument.type))&&this.throwError(`Unexpected ${i.node.operator}`))}),n.hooks.add("after-token",function(i){if(i.node){const l=this.code;ct.updateOperators.some(p=>p===l&&p===this.expr.charCodeAt(this.index+1))&&(t.includes(i.node.type)||this.throwError(`Unexpected ${i.node.operator}`),this.index+=2,i.node={type:"UpdateExpression",operator:l===Nt?"++":"--",argument:i.node,prefix:!1})}}),n.hooks.add("after-expression",function(i){i.node&&r(i.node)});function r(u){ct.assignmentOperators.has(u.operator)?(u.type="AssignmentExpression",r(u.left),r(u.right)):u.operator||Object.values(u).forEach(i=>{i&&typeof i=="object"&&r(i)})}}};We.plugins.register(lr,ct),We.addUnaryOp("typeof"),We.addLiteral("null",null),We.addLiteral("undefined",void 0);const cr=new Set(["constructor","__proto__","__defineGetter__","__defineSetter__"]),Be={evalAst(n,t){switch(n.type){case"BinaryExpression":case"LogicalExpression":return Be.evalBinaryExpression(n,t);case"Compound":return Be.evalCompound(n,t);case"ConditionalExpression":return Be.evalConditionalExpression(n,t);case"Identifier":return Be.evalIdentifier(n,t);case"Literal":return Be.evalLiteral(n,t);case"MemberExpression":return Be.evalMemberExpression(n,t);case"UnaryExpression":return Be.evalUnaryExpression(n,t);case"ArrayExpression":return Be.evalArrayExpression(n,t);case"CallExpression":return Be.evalCallExpression(n,t);case"AssignmentExpression":return Be.evalAssignmentExpression(n,t);default:throw SyntaxError("Unexpected expression",n)}},evalBinaryExpression(n,t){return{"||":(u,i)=>u||i(),"&&":(u,i)=>u&&i(),"|":(u,i)=>u|i(),"^":(u,i)=>u^i(),"&":(u,i)=>u&i(),"==":(u,i)=>u==i(),"!=":(u,i)=>u!=i(),"===":(u,i)=>u===i(),"!==":(u,i)=>u!==i(),"<":(u,i)=>u<i(),">":(u,i)=>u>i(),"<=":(u,i)=>u<=i(),">=":(u,i)=>u>=i(),"<<":(u,i)=>u<<i(),">>":(u,i)=>u>>i(),">>>":(u,i)=>u>>>i(),"+":(u,i)=>u+i(),"-":(u,i)=>u-i(),"*":(u,i)=>u*i(),"/":(u,i)=>u/i(),"%":(u,i)=>u%i()}[n.operator](Be.evalAst(n.left,t),()=>Be.evalAst(n.right,t))},evalCompound(n,t){let r;for(let u=0;u<n.body.length;u++){n.body[u].type==="Identifier"&&["var","let","const"].includes(n.body[u].name)&&n.body[u+1]&&n.body[u+1].type==="AssignmentExpression"&&(u+=1);const i=n.body[u];r=Be.evalAst(i,t)}return r},evalConditionalExpression(n,t){return Be.evalAst(n.test,t)?Be.evalAst(n.consequent,t):Be.evalAst(n.alternate,t)},evalIdentifier(n,t){if(Object.hasOwn(t,n.name))return t[n.name];throw ReferenceError(`${n.name} is not defined`)},evalLiteral(n){return n.value},evalMemberExpression(n,t){const r=String(n.computed?Be.evalAst(n.property):n.property.name),u=Be.evalAst(n.object,t);if(u==null)throw TypeError(`Cannot read properties of ${u} (reading '${r}')`);if(!Object.hasOwn(u,r)&&cr.has(r))throw TypeError(`Cannot read properties of ${u} (reading '${r}')`);const i=u[r];return typeof i=="function"?i.bind(u):i},evalUnaryExpression(n,t){return{"-":u=>-Be.evalAst(u,t),"!":u=>!Be.evalAst(u,t),"~":u=>~Be.evalAst(u,t),"+":u=>+Be.evalAst(u,t),typeof:u=>typeof Be.evalAst(u,t)}[n.operator](n.argument)},evalArrayExpression(n,t){return n.elements.map(r=>Be.evalAst(r,t))},evalCallExpression(n,t){const r=n.arguments.map(i=>Be.evalAst(i,t));return Be.evalAst(n.callee,t)(...r)},evalAssignmentExpression(n,t){if(n.left.type!=="Identifier")throw SyntaxError("Invalid left-hand side in assignment");const r=n.left.name,u=Be.evalAst(n.right,t);return t[r]=u,t[r]}};class fr{constructor(t){this.code=t,this.ast=We(this.code)}runInNewContext(t){const r=Object.assign(Object.create(null),t);return Be.evalAst(this.ast,r)}}function et(n,t){return n=n.slice(),n.push(t),n}function Dt(n,t){return t=t.slice(),t.unshift(n),t}class pr extends Error{constructor(t){super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'),this.avoidNew=!0,this.value=t,this.name="NewError"}}function we(n,t,r,u,i){if(!(this instanceof we))try{return new we(n,t,r,u,i)}catch(p){if(!p.avoidNew)throw p;return p.value}typeof n=="string"&&(i=u,u=r,r=t,t=n,n=null);const l=n&&typeof n=="object";if(n=n||{},this.json=n.json||r,this.path=n.path||t,this.resultType=n.resultType||"value",this.flatten=n.flatten||!1,this.wrap=Object.hasOwn(n,"wrap")?n.wrap:!0,this.sandbox=n.sandbox||{},this.eval=n.eval===void 0?"safe":n.eval,this.ignoreEvalErrors=typeof n.ignoreEvalErrors>"u"?!1:n.ignoreEvalErrors,this.parent=n.parent||null,this.parentProperty=n.parentProperty||null,this.callback=n.callback||u||null,this.otherTypeCallback=n.otherTypeCallback||i||function(){throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator.")},n.autostart!==!1){const p={path:l?n.path:t};l?"json"in n&&(p.json=n.json):p.json=r;const N=this.evaluate(p);if(!N||typeof N!="object")throw new pr(N);return N}}we.prototype.evaluate=function(n,t,r,u){let i=this.parent,l=this.parentProperty,{flatten:p,wrap:N}=this;if(this.currResultType=this.resultType,this.currEval=this.eval,this.currSandbox=this.sandbox,r=r||this.callback,this.currOtherTypeCallback=u||this.otherTypeCallback,t=t||this.json,n=n||this.path,n&&typeof n=="object"&&!Array.isArray(n)){if(!n.path&&n.path!=="")throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().');if(!Object.hasOwn(n,"json"))throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().');({json:t}=n),p=Object.hasOwn(n,"flatten")?n.flatten:p,this.currResultType=Object.hasOwn(n,"resultType")?n.resultType:this.currResultType,this.currSandbox=Object.hasOwn(n,"sandbox")?n.sandbox:this.currSandbox,N=Object.hasOwn(n,"wrap")?n.wrap:N,this.currEval=Object.hasOwn(n,"eval")?n.eval:this.currEval,r=Object.hasOwn(n,"callback")?n.callback:r,this.currOtherTypeCallback=Object.hasOwn(n,"otherTypeCallback")?n.otherTypeCallback:this.currOtherTypeCallback,i=Object.hasOwn(n,"parent")?n.parent:i,l=Object.hasOwn(n,"parentProperty")?n.parentProperty:l,n=n.path}if(i=i||null,l=l||null,Array.isArray(n)&&(n=we.toPathString(n)),!n&&n!==""||!t)return;const h=we.toPathArray(n);h[0]==="$"&&h.length>1&&h.shift(),this._hasParentSelector=null;const m=this._trace(h,t,["$"],i,l,r).filter(function(B){return B&&!B.isParentSelector});return m.length?!N&&m.length===1&&!m[0].hasArrExpr?this._getPreferredOutput(m[0]):m.reduce((B,T)=>{const U=this._getPreferredOutput(T);return p&&Array.isArray(U)?B=B.concat(U):B.push(U),B},[]):N?[]:void 0},we.prototype._getPreferredOutput=function(n){const t=this.currResultType;switch(t){case"all":{const r=Array.isArray(n.path)?n.path:we.toPathArray(n.path);return n.pointer=we.toPointer(r),n.path=typeof n.path=="string"?n.path:we.toPathString(n.path),n}case"value":case"parent":case"parentProperty":return n[t];case"path":return we.toPathString(n[t]);case"pointer":return we.toPointer(n.path);default:throw new TypeError("Unknown result type")}},we.prototype._handleCallback=function(n,t,r){if(t){const u=this._getPreferredOutput(n);n.path=typeof n.path=="string"?n.path:we.toPathString(n.path),t(u,r,n)}},we.prototype._trace=function(n,t,r,u,i,l,p,N){let h;if(!n.length)return h={path:r,value:t,parent:u,parentProperty:i,hasArrExpr:p},this._handleCallback(h,l,"value"),h;const m=n[0],B=n.slice(1),T=[];function U(V){Array.isArray(V)?V.forEach(ae=>{T.push(ae)}):T.push(V)}if((typeof m!="string"||N)&&t&&Object.hasOwn(t,m))U(this._trace(B,t[m],et(r,m),t,m,l,p));else if(m==="*")this._walk(t,V=>{U(this._trace(B,t[V],et(r,V),t,V,l,!0,!0))});else if(m==="..")U(this._trace(B,t,r,u,i,l,p)),this._walk(t,V=>{typeof t[V]=="object"&&U(this._trace(n.slice(),t[V],et(r,V),t,V,l,!0))});else{if(m==="^")return this._hasParentSelector=!0,{path:r.slice(0,-1),expr:B,isParentSelector:!0};if(m==="~")return h={path:et(r,m),value:i,parent:u,parentProperty:null},this._handleCallback(h,l,"property"),h;if(m==="$")U(this._trace(B,t,r,null,null,l,p));else if(/^(-?\d*):(-?\d*):?(\d*)$/u.test(m))U(this._slice(m,B,t,r,u,i,l));else if(m.indexOf("?(")===0){if(this.currEval===!1)throw new Error("Eval [?(expr)] prevented in JSONPath expression.");const V=m.replace(/^\?\((.*?)\)$/u,"$1"),ae=/@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(V);ae?this._walk(t,le=>{const _=[ae[2]],oe=ae[1]?t[le][ae[1]]:t[le];this._trace(_,oe,r,u,i,l,!0).length>0&&U(this._trace(B,t[le],et(r,le),t,le,l,!0))}):this._walk(t,le=>{this._eval(V,t[le],le,r,u,i)&&U(this._trace(B,t[le],et(r,le),t,le,l,!0))})}else if(m[0]==="("){if(this.currEval===!1)throw new Error("Eval [(expr)] prevented in JSONPath expression.");U(this._trace(Dt(this._eval(m,t,r.at(-1),r.slice(0,-1),u,i),B),t,r,u,i,l,p))}else if(m[0]==="@"){let V=!1;const ae=m.slice(1,-2);switch(ae){case"scalar":(!t||!["object","function"].includes(typeof t))&&(V=!0);break;case"boolean":case"string":case"undefined":case"function":typeof t===ae&&(V=!0);break;case"integer":Number.isFinite(t)&&!(t%1)&&(V=!0);break;case"number":Number.isFinite(t)&&(V=!0);break;case"nonFinite":typeof t=="number"&&!Number.isFinite(t)&&(V=!0);break;case"object":t&&typeof t===ae&&(V=!0);break;case"array":Array.isArray(t)&&(V=!0);break;case"other":V=this.currOtherTypeCallback(t,r,u,i);break;case"null":t===null&&(V=!0);break;default:throw new TypeError("Unknown value type "+ae)}if(V)return h={path:r,value:t,parent:u,parentProperty:i},this._handleCallback(h,l,"value"),h}else if(m[0]==="`"&&t&&Object.hasOwn(t,m.slice(1))){const V=m.slice(1);U(this._trace(B,t[V],et(r,V),t,V,l,p,!0))}else if(m.includes(",")){const V=m.split(",");for(const ae of V)U(this._trace(Dt(ae,B),t,r,u,i,l,!0))}else!N&&t&&Object.hasOwn(t,m)&&U(this._trace(B,t[m],et(r,m),t,m,l,p,!0))}if(this._hasParentSelector)for(let V=0;V<T.length;V++){const ae=T[V];if(ae&&ae.isParentSelector){const le=this._trace(ae.expr,t,ae.path,u,i,l,p);if(Array.isArray(le)){T[V]=le[0];const _=le.length;for(let oe=1;oe<_;oe++)V++,T.splice(V,0,le[oe])}else T[V]=le}}return T},we.prototype._walk=function(n,t){if(Array.isArray(n)){const r=n.length;for(let u=0;u<r;u++)t(u)}else n&&typeof n=="object"&&Object.keys(n).forEach(r=>{t(r)})},we.prototype._slice=function(n,t,r,u,i,l,p){if(!Array.isArray(r))return;const N=r.length,h=n.split(":"),m=h[2]&&Number.parseInt(h[2])||1;let B=h[0]&&Number.parseInt(h[0])||0,T=h[1]&&Number.parseInt(h[1])||N;B=B<0?Math.max(0,B+N):Math.min(N,B),T=T<0?Math.max(0,T+N):Math.min(N,T);const U=[];for(let V=B;V<T;V+=m)this._trace(Dt(V,t),r,u,i,l,p,!0).forEach(le=>{U.push(le)});return U},we.prototype._eval=function(n,t,r,u,i,l){this.currSandbox._$_parentProperty=l,this.currSandbox._$_parent=i,this.currSandbox._$_property=r,this.currSandbox._$_root=this.json,this.currSandbox._$_v=t;const p=n.includes("@path");p&&(this.currSandbox._$_path=we.toPathString(u.concat([r])));const N=this.currEval+"Script:"+n;if(!we.cache[N]){let h=n.replaceAll("@parentProperty","_$_parentProperty").replaceAll("@parent","_$_parent").replaceAll("@property","_$_property").replaceAll("@root","_$_root").replaceAll(/@([.\s)[])/gu,"_$_v$1");if(p&&(h=h.replaceAll("@path","_$_path")),this.currEval==="safe"||this.currEval===!0||this.currEval===void 0)we.cache[N]=new this.safeVm.Script(h);else if(this.currEval==="native")we.cache[N]=new this.vm.Script(h);else if(typeof this.currEval=="function"&&this.currEval.prototype&&Object.hasOwn(this.currEval.prototype,"runInNewContext")){const m=this.currEval;we.cache[N]=new m(h)}else if(typeof this.currEval=="function")we.cache[N]={runInNewContext:m=>this.currEval(h,m)};else throw new TypeError(`Unknown "eval" property "${this.currEval}"`)}try{return we.cache[N].runInNewContext(this.currSandbox)}catch(h){if(this.ignoreEvalErrors)return!1;throw new Error("jsonPath: "+h.message+": "+n)}},we.cache={},we.toPathString=function(n){const t=n,r=t.length;let u="$";for(let i=1;i<r;i++)/^(~|\^|@.*?\(\))$/u.test(t[i])||(u+=/^[0-9*]+$/u.test(t[i])?"["+t[i]+"]":"['"+t[i]+"']");return u},we.toPointer=function(n){const t=n,r=t.length;let u="";for(let i=1;i<r;i++)/^(~|\^|@.*?\(\))$/u.test(t[i])||(u+="/"+t[i].toString().replaceAll("~","~0").replaceAll("/","~1"));return u},we.toPathArray=function(n){const{cache:t}=we;if(t[n])return t[n].concat();const r=[],i=n.replaceAll(/@(?:null|boolean|number|string|integer|undefined|nonFinite|scalar|array|object|function|other)\(\)/gu,";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu,function(l,p){return"[#"+(r.push(p)-1)+"]"}).replaceAll(/\[['"]([^'\]]*)['"]\]/gu,function(l,p){return"['"+p.replaceAll(".","%@%").replaceAll("~","%%@@%%")+"']"}).replaceAll("~",";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu,";").replaceAll("%@%",".").replaceAll("%%@@%%","~").replaceAll(/(?:;)?(\^+)(?:;)?/gu,function(l,p){return";"+p.split("").join(";")+";"}).replaceAll(/;;;|;;/gu,";..;").replaceAll(/;$|'?\]|'$/gu,"").split(";").map(function(l){const p=l.match(/#(\d+)/u);return!p||!p[1]?l:r[p[1]]});return t[n]=i,t[n].concat()},we.prototype.safeVm={Script:fr};const dr=function(n,t,r){const u=n.length;for(let i=0;i<u;i++){const l=n[i];r(l)&&t.push(n.splice(i--,1)[0])}};class hr{constructor(t){this.code=t}runInNewContext(t){let r=this.code;const u=Object.keys(t),i=[];dr(u,i,m=>typeof t[m]=="function");const l=u.map(m=>t[m]);r=i.reduce((m,B)=>{let T=t[B].toString();return/function/u.test(T)||(T="function "+T),"var "+B+"="+T+";"+m},"")+r,!/(['"])use strict\1/u.test(r)&&!u.includes("arguments")&&(r="var arguments = undefined;"+r),r=r.replace(/;\s*$/u,"");const N=r.lastIndexOf(";"),h=N!==-1?r.slice(0,N+1)+" return "+r.slice(N+1):" return "+r;return new Function(...u,h)(...l)}}we.prototype.vm={Script:hr};const mr={class:"json-node"},gr={key:0,class:"json-node__container"},Er={class:"json-node__line"},yr=["contenteditable","onKeydown"],Ar={key:1,class:"json-node__colon"},br=["title"],xr=["title"],Nr={key:4,class:"json-node__comma"},Dr={key:0,class:"json-node__children"},vr={class:"json-node__children-content"},Cr={class:"json-node__line json-node__closing-bracket"},wr={class:"json-node__bracket"},Tr={key:0,class:"json-node__comma"},_r={key:1,class:"json-node__primitive"},Br=["contenteditable","onKeydown"],Sr={key:1,class:"json-node__colon"},Or=["title"],kr=["contenteditable","onKeydown"],Rr={key:0,class:"json-node__comma"},Fr=s.defineComponent({name:"JsonNode",__name:"JsonNode",props:{value:{},keyName:{},level:{},path:{default:""},expanded:{},isLast:{type:Boolean,default:!1},theme:{}},emits:["update:value","toggle-expand","copy","update:key"],setup(n,{emit:t}){s.useCssVars(x=>({"2a18b018":x.level,"58a14b93":x.theme.colors.syntaxKey,"46fe1b3e":x.theme.colors.hoverBackground,fbe2c048:x.theme.colors.syntaxBracket,"4bd524bb":x.theme.colors.collapsedText,"3308d23c":x.theme.colors.collapsedBackground,"36380c60":x.theme.colors.collapsedBackgroundHover,"0892365d":x.theme.colors.syntaxString,"0015b195":x.theme.colors.syntaxNumber,"7db95f5c":x.theme.colors.syntaxBoolean,"88ec825a":x.theme.colors.syntaxNull,"537157f7":x.theme.colors.background,"3cee3331":x.theme.colors.selectionBackground,"81323cee":x.theme.colors.indentLine}));const r=n,u=t,i=s.ref(!1),l=s.ref(!1),p=s.ref(""),N=s.ref(""),h=s.ref("string"),m=s.ref(null),B=s.ref(null),T=x=>x!==null&&typeof x=="object"&&!Array.isArray(x)&&"__protected_number__"in x&&Object.keys(x).length===1,U=x=>T(x)?x.__protected_number__:"",V=s.computed(()=>T(r.value)?!1:r.value!==null&&typeof r.value=="object"),ae=s.computed(()=>Array.isArray(r.value)),le=s.computed(()=>r.path?r.path:r.keyName?r.keyName:"root"),_=s.computed(()=>r.expanded.has(le.value)),oe=s.computed(()=>r.keyName),ge=s.computed(()=>ae.value?"[":"{"),re=s.computed(()=>ae.value?"]":"}"),De=s.computed(()=>{if(!r.value)return"";const S=Object.keys(r.value).length;return ae.value?S>0?` ${S} items `:" ":S>0?` ${S} keys `:" "}),Ae=s.computed(()=>{const x=typeof r.value;return r.value===null?"json-node__value--null":x==="boolean"?"json-node__value--boolean":x==="number"||T(r.value)?"json-node__value--number":x==="string"?"json-node__value--string":""}),H=s.computed(()=>r.value===null?"null":typeof r.value=="boolean"||typeof r.value=="number"?String(r.value):T(r.value)?U(r.value):typeof r.value=="string"?`"${r.value}"`:String(r.value)),A=s.computed(()=>"Double-click to edit"),de=x=>r.level===0?x:le.value?`${le.value}.${x}`:x,k=x=>{const S=Object.keys(r.value);return S.indexOf(x)===S.length-1},I=()=>{u("toggle-expand",le.value)},ee=()=>{r.level!==0&&(i.value=!0,p.value=r.keyName,s.nextTick(()=>{if(m.value){m.value.focus();const x=document.createRange();x.selectNodeContents(m.value);const S=window.getSelection();S?.removeAllRanges(),S?.addRange(x)}}))},K=()=>{V.value||(l.value=!0,r.value===null?h.value="null":T(r.value)?h.value="protected-number":typeof r.value=="string"?h.value="string":typeof r.value=="number"?h.value="number":typeof r.value=="boolean"&&(h.value="boolean"),T(r.value)?N.value=U(r.value):typeof r.value=="string"?N.value=r.value:N.value=String(r.value),s.nextTick(()=>{if(B.value){B.value.focus();const x=document.createRange();x.selectNodeContents(B.value);const S=window.getSelection();S?.removeAllRanges(),S?.addRange(x)}}))},q=()=>{if(r.level===0||!i.value)return;const x=m.value?.innerText.trim()||"";if(!x){he();return}if(x===r.keyName){i.value=!1;return}i.value=!1,u("update:key",le.value,x)},pe=()=>{if(l.value)try{let x;const S=B.value?.innerText.trim()||"";if(h.value==="string")S==="null"?x=null:S==="true"||S==="false"?x=S==="true":x=S;else if(h.value==="protected-number")x={__protected_number__:S};else if(S==="null")x=null;else if(S==="true"||S==="false")x=S==="true";else if(!isNaN(Number(S))&&S!==""){const R=Number(S);!Number.isSafeInteger(R)||S.length>15?x={__protected_number__:S}:x=R}else x=S;u("update:value",le.value,x),l.value=!1}catch(x){console.error("Failed to parse value:",x),l.value=!1}},he=()=>{i.value=!1,p.value=r.keyName},F=()=>{l.value=!1,T(r.value)?N.value=U(r.value):typeof r.value=="string"?N.value=r.value:N.value=String(r.value)};return(x,S)=>{const R=s.resolveComponent("JsonNode",!0);return s.openBlock(),s.createElementBlock("div",mr,[V.value?(s.openBlock(),s.createElementBlock("div",gr,[s.createElementVNode("div",Er,[x.keyName?(s.openBlock(),s.createElementBlock("span",{key:0,class:"json-node__key",contenteditable:i.value,onDblclick:ee,onKeydown:[s.withKeys(s.withModifiers(q,["prevent"]),["enter"]),s.withKeys(he,["escape"])],onBlur:q,ref_key:"keyRef",ref:m,title:"Double-click to edit key"},s.toDisplayString(i.value?p.value:`"${oe.value}"`),41,yr)):s.createCommentVNode("",!0),x.keyName?(s.openBlock(),s.createElementBlock("span",Ar,": ")):s.createCommentVNode("",!0),s.createElementVNode("span",{class:"json-node__bracket json-node__bracket--clickable",onClick:I,title:_.value?"Click to collapse":"Click to expand"},s.toDisplayString(ge.value),9,br),_.value?s.createCommentVNode("",!0):(s.openBlock(),s.createElementBlock("span",{key:2,class:"json-node__collapsed-info",onClick:I,title:`Click to expand ${De.value.trim()}`},s.toDisplayString(De.value),9,xr)),_.value?s.createCommentVNode("",!0):(s.openBlock(),s.createElementBlock("span",{key:3,class:"json-node__bracket json-node__bracket--clickable",onClick:I,title:"Click to expand"},s.toDisplayString(re.value),1)),!_.value&&!x.isLast?(s.openBlock(),s.createElementBlock("span",Nr,",")):s.createCommentVNode("",!0)]),_.value?(s.openBlock(),s.createElementBlock("div",Dr,[s.createElementVNode("div",vr,[(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(x.value,(j,M)=>(s.openBlock(),s.createElementBlock("div",{key:M,class:"json-node__child"},[s.createVNode(R,{value:j,"key-name":ae.value?"":String(M),level:x.level+1,path:de(String(M)),expanded:x.expanded,theme:x.theme,"onUpdate:value":S[0]||(S[0]=(J,D)=>x.$emit("update:value",J,D)),onToggleExpand:S[1]||(S[1]=J=>x.$emit("toggle-expand",J)),onCopy:S[2]||(S[2]=J=>x.$emit("copy",J)),"onUpdate:key":S[3]||(S[3]=(J,D)=>x.$emit("update:key",J,D)),"is-last":k(String(M))},null,8,["value","key-name","level","path","expanded","theme","is-last"])]))),128))]),s.createElementVNode("div",Cr,[s.createElementVNode("span",wr,s.toDisplayString(re.value),1),x.isLast?s.createCommentVNode("",!0):(s.openBlock(),s.createElementBlock("span",Tr,","))])])):s.createCommentVNode("",!0)])):(s.openBlock(),s.createElementBlock("div",_r,[x.keyName?(s.openBlock(),s.createElementBlock("span",{key:0,class:"json-node__key",contenteditable:i.value,onDblclick:ee,onKeydown:[s.withKeys(s.withModifiers(q,["prevent"]),["enter"]),s.withKeys(he,["escape"])],onBlur:q,ref_key:"keyRef",ref:m,title:"Double-click to edit key"},s.toDisplayString(i.value?p.value:`"${oe.value}"`),41,Br)):s.createCommentVNode("",!0),x.keyName?(s.openBlock(),s.createElementBlock("span",Sr,": ")):s.createCommentVNode("",!0),s.createElementVNode("span",{class:s.normalizeClass(["json-node__value-wrapper",Ae.value]),onDblclick:K,title:A.value},[s.createElementVNode("span",{class:"json-node__value",contenteditable:l.value,onKeydown:[s.withKeys(s.withModifiers(pe,["prevent"]),["enter"]),s.withKeys(F,["escape"])],onBlur:pe,ref_key:"valueRef",ref:B},s.toDisplayString(l.value?N.value:H.value),41,kr),x.isLast?s.createCommentVNode("",!0):(s.openBlock(),s.createElementBlock("span",Rr,","))],42,Or)]))])}}}),Et=(n,t)=>{const r=n.__vccOpts||n;for(const[u,i]of t)r[u]=i;return r},Ir=Et(Fr,[["__scopeId","data-v-1472a8af"]]),kt={name:"github-light",colors:{background:"#ffffff",surfaceBackground:"#f6f8fa",border:"#d0d7de",text:"#24292f",textSecondary:"#656d76",buttonBackground:"#f6f8fa",buttonBackgroundHover:"#f3f4f6",buttonBorder:"#d0d7de",buttonText:"#24292f",buttonPrimary:"#2da44e",buttonPrimaryHover:"#2c974b",success:"#1a7f37",successBackground:"#dafbe1",error:"#cf222e",errorBackground:"#ffebe9",syntaxString:"#0a3069",syntaxNumber:"#0969da",syntaxBoolean:"#8250df",syntaxNull:"#656d76",syntaxKey:"#0969da",syntaxBracket:"#24292f",hoverBackground:"#f6f8fa",selectionBackground:"rgba(9, 105, 218, 0.2)",collapsedBackground:"#ddf4ff",collapsedBackgroundHover:"#b6e3ff",collapsedText:"#0969da",indentLine:"#d0d7de"}},Pr={"github-light":kt,"github-dark":{name:"github-dark",colors:{background:"#0d1117",surfaceBackground:"#161b22",border:"#30363d",text:"#e6edf3",textSecondary:"#7d8590",buttonBackground:"#21262d",buttonBackgroundHover:"#30363d",buttonBorder:"#30363d",buttonText:"#e6edf3",buttonPrimary:"#238636",buttonPrimaryHover:"#2ea043",success:"#3fb950",successBackground:"#0f2419",error:"#f85149",errorBackground:"#381921",syntaxString:"#a5d6ff",syntaxNumber:"#79c0ff",syntaxBoolean:"#d2a8ff",syntaxNull:"#7d8590",syntaxKey:"#79c0ff",syntaxBracket:"#e6edf3",hoverBackground:"#161b22",selectionBackground:"rgba(121, 192, 255, 0.2)",collapsedBackground:"#1c2128",collapsedBackgroundHover:"#2d333b",collapsedText:"#79c0ff",indentLine:"#30363d"}},"min-light":{name:"min-light",colors:{background:"#ffffff",surfaceBackground:"#fafafa",border:"#e5e5e5",text:"#333333",textSecondary:"#888888",buttonBackground:"#f8f8f8",buttonBackgroundHover:"#eeeeee",buttonBorder:"#e0e0e0",buttonText:"#333333",buttonPrimary:"#007acc",buttonPrimaryHover:"#005a9e",success:"#22c55e",successBackground:"#f0fdf4",error:"#ef4444",errorBackground:"#fef2f2",syntaxString:"#22c55e",syntaxNumber:"#3b82f6",syntaxBoolean:"#8b5cf6",syntaxNull:"#6b7280",syntaxKey:"#1f2937",syntaxBracket:"#374151",hoverBackground:"#f9f9f9",selectionBackground:"rgba(59, 130, 246, 0.2)",collapsedBackground:"#e0f2fe",collapsedBackgroundHover:"#bae6fd",collapsedText:"#0284c7",indentLine:"#e5e7eb"}},"slack-ochin":{name:"slack-ochin",colors:{background:"#fefbf6",surfaceBackground:"#faf6f0",border:"#e8d5b7",text:"#4a3b2a",textSecondary:"#8b7355",buttonBackground:"#f4ede4",buttonBackgroundHover:"#efe5d8",buttonBorder:"#e8d5b7",buttonText:"#4a3b2a",buttonPrimary:"#ff6b35",buttonPrimaryHover:"#e55a2b",success:"#ff9500",successBackground:"#fff8f0",error:"#d73502",errorBackground:"#ffeee8",syntaxString:"#d73502",syntaxNumber:"#ff6b35",syntaxBoolean:"#b7472a",syntaxNull:"#8b7355",syntaxKey:"#4a3b2a",syntaxBracket:"#6b5444",hoverBackground:"#f8f2eb",selectionBackground:"rgba(255, 107, 53, 0.2)",collapsedBackground:"#ffe8d6",collapsedBackgroundHover:"#ffd4b0",collapsedText:"#d73502",indentLine:"#e8d5b7"}}};function Lr(n="github-light"){return Pr[n]||kt}const Vr={key:0,class:"json-format__toolbar"},Mr={class:"json-format__actions"},Ur=["disabled"],qr=["disabled"],$r=["disabled"],jr=["disabled"],Xr={class:"json-format__info"},Hr={key:0,class:"json-format__status json-format__status--success"},Gr={key:1,class:"json-format__status json-format__status--error"},Kr={class:"json-format__content"},zr={key:0,class:"json-format__error"},Yr={key:1,class:"json-format__error"},Wr={key:2,class:"json-format__viewer"},Rt=Et(s.defineComponent({name:"JsonFormat",__name:"index",props:{modelValue:{default:""},readonly:{type:Boolean,default:!1},maxDepth:{default:10},showToolbar:{type:Boolean,default:!0},theme:{default:"github-light"}},emits:["update:modelValue","copy-success","copy-error","expand-all","collapse-all","compress"],setup(n,{expose:t,emit:r}){s.useCssVars(D=>({"0e2b28fa":U.value.colors.border,f3d81a08:U.value.colors.background,"0af7d57b":U.value.colors.text,"5ee5c82d":U.value.colors.surfaceBackground,ff458768:U.value.colors.buttonBorder,c0efe564:U.value.colors.buttonBackground,"2a4ad566":U.value.colors.buttonText,e48626e4:U.value.colors.buttonBackgroundHover,"748549e2":U.value.colors.buttonPrimary,a39b270c:U.value.colors.buttonPrimaryHover,"61cd2ffa":U.value.colors.successBackground,"43ed24f5":U.value.colors.success,"9c8a2770":U.value.colors.errorBackground,"53354b7a":U.value.colors.error}));const u=n,i=r,l=s.ref(null),p=s.ref(""),N=s.ref(new Set),h=s.ref(null),m=s.ref(""),B=s.ref(!1),T=s.computed(()=>p.value===""),U=s.computed(()=>Lr(u.theme)),V=D=>{if(D==null)return D;if(Array.isArray(D))return D.map(w=>V(w));if(typeof D=="object"){const w={},P=Object.keys(D).sort();for(const L of P)w[L]=V(D[L]);return w}return D},ae=s.computed(()=>{const D=h.value!==null?h.value:l.value;return!D||!B.value?D:V(D)}),le=s.computed(()=>m.value?null:ae.value),_=D=>{if(!D.trim()){l.value=null,p.value="",h.value=null,m.value="";return}try{let w=D;const P=/(:\s*|,\s*|\[\s*)-?\d{16,}/.test(w),L=/(:\s*|,\s*|\[\s*)-?\d+\.\d*0+\s*[,}\]\s]*/.test(w);if(!P&&!L)try{l.value=JSON.parse(w),p.value="",h.value=null,m.value="",s.nextTick(()=>{le.value!==null&&K()});return}catch{}w=(C=>{let ne="",Ee=!1,be=!1,Te=0;for(;Te<C.length;){const ke=C[Te];if(Ee)be?be=!1:ke==="\\"?be=!0:ke==='"'&&(Ee=!1),ne+=ke,Te++;else if(ke==='"')Ee=!0,ne+=ke,Te++;else{const ve=C.slice(Te);let g=ve.match(/^([:,\[\s]*)(-?\d{16,})(\s*[,\}\]\s]|$)/);if(g){ne+=g[1]+'{"__protected_number__":"'+g[2]+'"}'+g[3],Te+=g[0].length;continue}if(g=ve.match(/^([:,\[\s]*)(-?\d+\.\d*0+)(\s*[,\}\]\s]|$)/),g){ne+=g[1]+'{"__protected_number__":"'+g[2]+'"}'+g[3],Te+=g[0].length;continue}ne+=ke,Te++}}return ne})(w),l.value=JSON.parse(w),p.value="",h.value=null,m.value="",s.nextTick(()=>{le.value!==null&&K()})}catch(w){p.value=w instanceof Error?w.message:"Unknown parsing error",l.value=null,h.value=null,m.value=""}},oe=D=>{if(!D||!D.expression.trim()){Ae();return}if(!l.value){m.value="No valid JSON data to filter";return}try{let w;if(D.type==="jsonpath")w=we({path:D.expression,json:l.value}),w.length===1&&D.expression.includes("$[")===!1&&!D.expression.endsWith("[*]")?h.value=w[0]:h.value=w;else if(D.type==="js"){const{proxyData:P,indexMap:L}=ge(l.value),C=new Function("$",`
1
+ (function(ze,o){typeof exports=="object"&&typeof module<"u"?o(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],o):(ze=typeof globalThis<"u"?globalThis:ze||self,o(ze.LoneFormat={},ze.Vue))})(this,function(ze,o){"use strict";class ir{add(t,r,a){if(typeof arguments[0]!="string")for(let i in arguments[0])this.add(i,arguments[0][i],arguments[1]);else(Array.isArray(t)?t:[t]).forEach(function(i){this[i]=this[i]||[],r&&this[i][a?"unshift":"push"](r)},this)}run(t,r){this[t]=this[t]||[],this[t].forEach(function(a){a.call(r&&r.context?r.context:r,r)})}}class ar{constructor(t){this.jsep=t,this.registered={}}register(){for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];r.forEach(i=>{if(typeof i!="object"||!i.name||!i.init)throw new Error("Invalid JSEP plugin format");this.registered[i.name]||(i.init(this.jsep),this.registered[i.name]=i)})}}class I{static get version(){return"1.4.0"}static toString(){return"JavaScript Expression Parser (JSEP) v"+I.version}static addUnaryOp(t){return I.max_unop_len=Math.max(t.length,I.max_unop_len),I.unary_ops[t]=1,I}static addBinaryOp(t,r,a){return I.max_binop_len=Math.max(t.length,I.max_binop_len),I.binary_ops[t]=r,a?I.right_associative.add(t):I.right_associative.delete(t),I}static addIdentifierChar(t){return I.additional_identifier_chars.add(t),I}static addLiteral(t,r){return I.literals[t]=r,I}static removeUnaryOp(t){return delete I.unary_ops[t],t.length===I.max_unop_len&&(I.max_unop_len=I.getMaxKeyLen(I.unary_ops)),I}static removeAllUnaryOps(){return I.unary_ops={},I.max_unop_len=0,I}static removeIdentifierChar(t){return I.additional_identifier_chars.delete(t),I}static removeBinaryOp(t){return delete I.binary_ops[t],t.length===I.max_binop_len&&(I.max_binop_len=I.getMaxKeyLen(I.binary_ops)),I.right_associative.delete(t),I}static removeAllBinaryOps(){return I.binary_ops={},I.max_binop_len=0,I}static removeLiteral(t){return delete I.literals[t],I}static removeAllLiterals(){return I.literals={},I}get char(){return this.expr.charAt(this.index)}get code(){return this.expr.charCodeAt(this.index)}constructor(t){this.expr=t,this.index=0}static parse(t){return new I(t).parse()}static getMaxKeyLen(t){return Math.max(0,...Object.keys(t).map(r=>r.length))}static isDecimalDigit(t){return t>=48&&t<=57}static binaryPrecedence(t){return I.binary_ops[t]||0}static isIdentifierStart(t){return t>=65&&t<=90||t>=97&&t<=122||t>=128&&!I.binary_ops[String.fromCharCode(t)]||I.additional_identifier_chars.has(String.fromCharCode(t))}static isIdentifierPart(t){return I.isIdentifierStart(t)||I.isDecimalDigit(t)}throwError(t){const r=new Error(t+" at character "+this.index);throw r.index=this.index,r.description=t,r}runHook(t,r){if(I.hooks[t]){const a={context:this,node:r};return I.hooks.run(t,a),a.node}return r}searchHook(t){if(I.hooks[t]){const r={context:this};return I.hooks[t].find(function(a){return a.call(r.context,r),r.node}),r.node}}gobbleSpaces(){let t=this.code;for(;t===I.SPACE_CODE||t===I.TAB_CODE||t===I.LF_CODE||t===I.CR_CODE;)t=this.expr.charCodeAt(++this.index);this.runHook("gobble-spaces")}parse(){this.runHook("before-all");const t=this.gobbleExpressions(),r=t.length===1?t[0]:{type:I.COMPOUND,body:t};return this.runHook("after-all",r)}gobbleExpressions(t){let r=[],a,i;for(;this.index<this.expr.length;)if(a=this.code,a===I.SEMCOL_CODE||a===I.COMMA_CODE)this.index++;else if(i=this.gobbleExpression())r.push(i);else if(this.index<this.expr.length){if(a===t)break;this.throwError('Unexpected "'+this.char+'"')}return r}gobbleExpression(){const t=this.searchHook("gobble-expression")||this.gobbleBinaryExpression();return this.gobbleSpaces(),this.runHook("after-expression",t)}gobbleBinaryOp(){this.gobbleSpaces();let t=this.expr.substr(this.index,I.max_binop_len),r=t.length;for(;r>0;){if(I.binary_ops.hasOwnProperty(t)&&(!I.isIdentifierStart(this.code)||this.index+t.length<this.expr.length&&!I.isIdentifierPart(this.expr.charCodeAt(this.index+t.length))))return this.index+=r,t;t=t.substr(0,--r)}return!1}gobbleBinaryExpression(){let t,r,a,i,u,c,b,p,m;if(c=this.gobbleToken(),!c||(r=this.gobbleBinaryOp(),!r))return c;for(u={value:r,prec:I.binaryPrecedence(r),right_a:I.right_associative.has(r)},b=this.gobbleToken(),b||this.throwError("Expected expression after "+r),i=[c,u,b];r=this.gobbleBinaryOp();){if(a=I.binaryPrecedence(r),a===0){this.index-=r.length;break}u={value:r,prec:a,right_a:I.right_associative.has(r)},m=r;const _=D=>u.right_a&&D.right_a?a>D.prec:a<=D.prec;for(;i.length>2&&_(i[i.length-2]);)b=i.pop(),r=i.pop().value,c=i.pop(),t={type:I.BINARY_EXP,operator:r,left:c,right:b},i.push(t);t=this.gobbleToken(),t||this.throwError("Expected expression after "+m),i.push(u,t)}for(p=i.length-1,t=i[p];p>1;)t={type:I.BINARY_EXP,operator:i[p-1].value,left:i[p-2],right:t},p-=2;return t}gobbleToken(){let t,r,a,i;if(this.gobbleSpaces(),i=this.searchHook("gobble-token"),i)return this.runHook("after-token",i);if(t=this.code,I.isDecimalDigit(t)||t===I.PERIOD_CODE)return this.gobbleNumericLiteral();if(t===I.SQUOTE_CODE||t===I.DQUOTE_CODE)i=this.gobbleStringLiteral();else if(t===I.OBRACK_CODE)i=this.gobbleArray();else{for(r=this.expr.substr(this.index,I.max_unop_len),a=r.length;a>0;){if(I.unary_ops.hasOwnProperty(r)&&(!I.isIdentifierStart(this.code)||this.index+r.length<this.expr.length&&!I.isIdentifierPart(this.expr.charCodeAt(this.index+r.length)))){this.index+=a;const u=this.gobbleToken();return u||this.throwError("missing unaryOp argument"),this.runHook("after-token",{type:I.UNARY_EXP,operator:r,argument:u,prefix:!0})}r=r.substr(0,--a)}I.isIdentifierStart(t)?(i=this.gobbleIdentifier(),I.literals.hasOwnProperty(i.name)?i={type:I.LITERAL,value:I.literals[i.name],raw:i.name}:i.name===I.this_str&&(i={type:I.THIS_EXP})):t===I.OPAREN_CODE&&(i=this.gobbleGroup())}return i?(i=this.gobbleTokenProperty(i),this.runHook("after-token",i)):this.runHook("after-token",!1)}gobbleTokenProperty(t){this.gobbleSpaces();let r=this.code;for(;r===I.PERIOD_CODE||r===I.OBRACK_CODE||r===I.OPAREN_CODE||r===I.QUMARK_CODE;){let a;if(r===I.QUMARK_CODE){if(this.expr.charCodeAt(this.index+1)!==I.PERIOD_CODE)break;a=!0,this.index+=2,this.gobbleSpaces(),r=this.code}this.index++,r===I.OBRACK_CODE?(t={type:I.MEMBER_EXP,computed:!0,object:t,property:this.gobbleExpression()},t.property||this.throwError('Unexpected "'+this.char+'"'),this.gobbleSpaces(),r=this.code,r!==I.CBRACK_CODE&&this.throwError("Unclosed ["),this.index++):r===I.OPAREN_CODE?t={type:I.CALL_EXP,arguments:this.gobbleArguments(I.CPAREN_CODE),callee:t}:(r===I.PERIOD_CODE||a)&&(a&&this.index--,this.gobbleSpaces(),t={type:I.MEMBER_EXP,computed:!1,object:t,property:this.gobbleIdentifier()}),a&&(t.optional=!0),this.gobbleSpaces(),r=this.code}return t}gobbleNumericLiteral(){let t="",r,a;for(;I.isDecimalDigit(this.code);)t+=this.expr.charAt(this.index++);if(this.code===I.PERIOD_CODE)for(t+=this.expr.charAt(this.index++);I.isDecimalDigit(this.code);)t+=this.expr.charAt(this.index++);if(r=this.char,r==="e"||r==="E"){for(t+=this.expr.charAt(this.index++),r=this.char,(r==="+"||r==="-")&&(t+=this.expr.charAt(this.index++));I.isDecimalDigit(this.code);)t+=this.expr.charAt(this.index++);I.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+t+this.char+")")}return a=this.code,I.isIdentifierStart(a)?this.throwError("Variable names cannot start with a number ("+t+this.char+")"):(a===I.PERIOD_CODE||t.length===1&&t.charCodeAt(0)===I.PERIOD_CODE)&&this.throwError("Unexpected period"),{type:I.LITERAL,value:parseFloat(t),raw:t}}gobbleStringLiteral(){let t="";const r=this.index,a=this.expr.charAt(this.index++);let i=!1;for(;this.index<this.expr.length;){let u=this.expr.charAt(this.index++);if(u===a){i=!0;break}else if(u==="\\")switch(u=this.expr.charAt(this.index++),u){case"n":t+=`
2
+ `;break;case"r":t+="\r";break;case"t":t+=" ";break;case"b":t+="\b";break;case"f":t+="\f";break;case"v":t+="\v";break;default:t+=u}else t+=u}return i||this.throwError('Unclosed quote after "'+t+'"'),{type:I.LITERAL,value:t,raw:this.expr.substring(r,this.index)}}gobbleIdentifier(){let t=this.code,r=this.index;for(I.isIdentifierStart(t)?this.index++:this.throwError("Unexpected "+this.char);this.index<this.expr.length&&(t=this.code,I.isIdentifierPart(t));)this.index++;return{type:I.IDENTIFIER,name:this.expr.slice(r,this.index)}}gobbleArguments(t){const r=[];let a=!1,i=0;for(;this.index<this.expr.length;){this.gobbleSpaces();let u=this.code;if(u===t){a=!0,this.index++,t===I.CPAREN_CODE&&i&&i>=r.length&&this.throwError("Unexpected token "+String.fromCharCode(t));break}else if(u===I.COMMA_CODE){if(this.index++,i++,i!==r.length){if(t===I.CPAREN_CODE)this.throwError("Unexpected token ,");else if(t===I.CBRACK_CODE)for(let c=r.length;c<i;c++)r.push(null)}}else if(r.length!==i&&i!==0)this.throwError("Expected comma");else{const c=this.gobbleExpression();(!c||c.type===I.COMPOUND)&&this.throwError("Expected comma"),r.push(c)}}return a||this.throwError("Expected "+String.fromCharCode(t)),r}gobbleGroup(){this.index++;let t=this.gobbleExpressions(I.CPAREN_CODE);if(this.code===I.CPAREN_CODE)return this.index++,t.length===1?t[0]:t.length?{type:I.SEQUENCE_EXP,expressions:t}:!1;this.throwError("Unclosed (")}gobbleArray(){return this.index++,{type:I.ARRAY_EXP,elements:this.gobbleArguments(I.CBRACK_CODE)}}}const ur=new ir;Object.assign(I,{hooks:ur,plugins:new ar(I),COMPOUND:"Compound",SEQUENCE_EXP:"SequenceExpression",IDENTIFIER:"Identifier",MEMBER_EXP:"MemberExpression",LITERAL:"Literal",THIS_EXP:"ThisExpression",CALL_EXP:"CallExpression",UNARY_EXP:"UnaryExpression",BINARY_EXP:"BinaryExpression",ARRAY_EXP:"ArrayExpression",TAB_CODE:9,LF_CODE:10,CR_CODE:13,SPACE_CODE:32,PERIOD_CODE:46,COMMA_CODE:44,SQUOTE_CODE:39,DQUOTE_CODE:34,OPAREN_CODE:40,CPAREN_CODE:41,OBRACK_CODE:91,CBRACK_CODE:93,QUMARK_CODE:63,SEMCOL_CODE:59,COLON_CODE:58,unary_ops:{"-":1,"!":1,"~":1,"+":1},binary_ops:{"||":1,"??":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10,"**":11},right_associative:new Set(["**"]),additional_identifier_chars:new Set(["$","_"]),literals:{true:!0,false:!1,null:null},this_str:"this"}),I.max_unop_len=I.getMaxKeyLen(I.unary_ops),I.max_binop_len=I.getMaxKeyLen(I.binary_ops);const Ze=n=>new I(n).parse(),lr=Object.getOwnPropertyNames(class{});Object.getOwnPropertyNames(I).filter(n=>!lr.includes(n)&&Ze[n]===void 0).forEach(n=>{Ze[n]=I[n]}),Ze.Jsep=I;const cr="ConditionalExpression";var fr={name:"ternary",init(n){n.hooks.add("after-expression",function(r){if(r.node&&this.code===n.QUMARK_CODE){this.index++;const a=r.node,i=this.gobbleExpression();if(i||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===n.COLON_CODE){this.index++;const u=this.gobbleExpression();if(u||this.throwError("Expected expression"),r.node={type:cr,test:a,consequent:i,alternate:u},a.operator&&n.binary_ops[a.operator]<=.9){let c=a;for(;c.right.operator&&n.binary_ops[c.right.operator]<=.9;)c=c.right;r.node.test=c.right,c.right=r.node,r.node=a}}else this.throwError("Expected :")}})}};Ze.plugins.register(fr);const kt=47,dr=92;var pr={name:"regex",init(n){n.hooks.add("gobble-token",function(r){if(this.code===kt){const a=++this.index;let i=!1;for(;this.index<this.expr.length;){if(this.code===kt&&!i){const u=this.expr.slice(a,this.index);let c="";for(;++this.index<this.expr.length;){const p=this.code;if(p>=97&&p<=122||p>=65&&p<=90||p>=48&&p<=57)c+=this.char;else break}let b;try{b=new RegExp(u,c)}catch(p){this.throwError(p.message)}return r.node={type:n.LITERAL,value:b,raw:this.expr.slice(a-1,this.index)},r.node=this.gobbleTokenProperty(r.node),r.node}this.code===n.OBRACK_CODE?i=!0:i&&this.code===n.CBRACK_CODE&&(i=!1),this.index+=this.code===dr?2:1}this.throwError("Unclosed Regex")}})}};const Ct=43,ct={name:"assignment",assignmentOperators:new Set(["=","*=","**=","/=","%=","+=","-=","<<=",">>=",">>>=","&=","^=","|=","||=","&&=","??="]),updateOperators:[Ct,45],assignmentPrecedence:.9,init(n){const t=[n.IDENTIFIER,n.MEMBER_EXP];ct.assignmentOperators.forEach(a=>n.addBinaryOp(a,ct.assignmentPrecedence,!0)),n.hooks.add("gobble-token",function(i){const u=this.code;ct.updateOperators.some(c=>c===u&&c===this.expr.charCodeAt(this.index+1))&&(this.index+=2,i.node={type:"UpdateExpression",operator:u===Ct?"++":"--",argument:this.gobbleTokenProperty(this.gobbleIdentifier()),prefix:!0},(!i.node.argument||!t.includes(i.node.argument.type))&&this.throwError(`Unexpected ${i.node.operator}`))}),n.hooks.add("after-token",function(i){if(i.node){const u=this.code;ct.updateOperators.some(c=>c===u&&c===this.expr.charCodeAt(this.index+1))&&(t.includes(i.node.type)||this.throwError(`Unexpected ${i.node.operator}`),this.index+=2,i.node={type:"UpdateExpression",operator:u===Ct?"++":"--",argument:i.node,prefix:!1})}}),n.hooks.add("after-expression",function(i){i.node&&r(i.node)});function r(a){ct.assignmentOperators.has(a.operator)?(a.type="AssignmentExpression",r(a.left),r(a.right)):a.operator||Object.values(a).forEach(i=>{i&&typeof i=="object"&&r(i)})}}};Ze.plugins.register(pr,ct),Ze.addUnaryOp("typeof"),Ze.addLiteral("null",null),Ze.addLiteral("undefined",void 0);const hr=new Set(["constructor","__proto__","__defineGetter__","__defineSetter__"]),Te={evalAst(n,t){switch(n.type){case"BinaryExpression":case"LogicalExpression":return Te.evalBinaryExpression(n,t);case"Compound":return Te.evalCompound(n,t);case"ConditionalExpression":return Te.evalConditionalExpression(n,t);case"Identifier":return Te.evalIdentifier(n,t);case"Literal":return Te.evalLiteral(n,t);case"MemberExpression":return Te.evalMemberExpression(n,t);case"UnaryExpression":return Te.evalUnaryExpression(n,t);case"ArrayExpression":return Te.evalArrayExpression(n,t);case"CallExpression":return Te.evalCallExpression(n,t);case"AssignmentExpression":return Te.evalAssignmentExpression(n,t);default:throw SyntaxError("Unexpected expression",n)}},evalBinaryExpression(n,t){return{"||":(a,i)=>a||i(),"&&":(a,i)=>a&&i(),"|":(a,i)=>a|i(),"^":(a,i)=>a^i(),"&":(a,i)=>a&i(),"==":(a,i)=>a==i(),"!=":(a,i)=>a!=i(),"===":(a,i)=>a===i(),"!==":(a,i)=>a!==i(),"<":(a,i)=>a<i(),">":(a,i)=>a>i(),"<=":(a,i)=>a<=i(),">=":(a,i)=>a>=i(),"<<":(a,i)=>a<<i(),">>":(a,i)=>a>>i(),">>>":(a,i)=>a>>>i(),"+":(a,i)=>a+i(),"-":(a,i)=>a-i(),"*":(a,i)=>a*i(),"/":(a,i)=>a/i(),"%":(a,i)=>a%i()}[n.operator](Te.evalAst(n.left,t),()=>Te.evalAst(n.right,t))},evalCompound(n,t){let r;for(let a=0;a<n.body.length;a++){n.body[a].type==="Identifier"&&["var","let","const"].includes(n.body[a].name)&&n.body[a+1]&&n.body[a+1].type==="AssignmentExpression"&&(a+=1);const i=n.body[a];r=Te.evalAst(i,t)}return r},evalConditionalExpression(n,t){return Te.evalAst(n.test,t)?Te.evalAst(n.consequent,t):Te.evalAst(n.alternate,t)},evalIdentifier(n,t){if(Object.hasOwn(t,n.name))return t[n.name];throw ReferenceError(`${n.name} is not defined`)},evalLiteral(n){return n.value},evalMemberExpression(n,t){const r=String(n.computed?Te.evalAst(n.property):n.property.name),a=Te.evalAst(n.object,t);if(a==null)throw TypeError(`Cannot read properties of ${a} (reading '${r}')`);if(!Object.hasOwn(a,r)&&hr.has(r))throw TypeError(`Cannot read properties of ${a} (reading '${r}')`);const i=a[r];return typeof i=="function"?i.bind(a):i},evalUnaryExpression(n,t){return{"-":a=>-Te.evalAst(a,t),"!":a=>!Te.evalAst(a,t),"~":a=>~Te.evalAst(a,t),"+":a=>+Te.evalAst(a,t),typeof:a=>typeof Te.evalAst(a,t)}[n.operator](n.argument)},evalArrayExpression(n,t){return n.elements.map(r=>Te.evalAst(r,t))},evalCallExpression(n,t){const r=n.arguments.map(i=>Te.evalAst(i,t));return Te.evalAst(n.callee,t)(...r)},evalAssignmentExpression(n,t){if(n.left.type!=="Identifier")throw SyntaxError("Invalid left-hand side in assignment");const r=n.left.name,a=Te.evalAst(n.right,t);return t[r]=a,t[r]}};class mr{constructor(t){this.code=t,this.ast=Ze(this.code)}runInNewContext(t){const r=Object.assign(Object.create(null),t);return Te.evalAst(this.ast,r)}}function rt(n,t){return n=n.slice(),n.push(t),n}function Dt(n,t){return t=t.slice(),t.unshift(n),t}class gr extends Error{constructor(t){super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'),this.avoidNew=!0,this.value=t,this.name="NewError"}}function we(n,t,r,a,i){if(!(this instanceof we))try{return new we(n,t,r,a,i)}catch(c){if(!c.avoidNew)throw c;return c.value}typeof n=="string"&&(i=a,a=r,r=t,t=n,n=null);const u=n&&typeof n=="object";if(n=n||{},this.json=n.json||r,this.path=n.path||t,this.resultType=n.resultType||"value",this.flatten=n.flatten||!1,this.wrap=Object.hasOwn(n,"wrap")?n.wrap:!0,this.sandbox=n.sandbox||{},this.eval=n.eval===void 0?"safe":n.eval,this.ignoreEvalErrors=typeof n.ignoreEvalErrors>"u"?!1:n.ignoreEvalErrors,this.parent=n.parent||null,this.parentProperty=n.parentProperty||null,this.callback=n.callback||a||null,this.otherTypeCallback=n.otherTypeCallback||i||function(){throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator.")},n.autostart!==!1){const c={path:u?n.path:t};u?"json"in n&&(c.json=n.json):c.json=r;const b=this.evaluate(c);if(!b||typeof b!="object")throw new gr(b);return b}}we.prototype.evaluate=function(n,t,r,a){let i=this.parent,u=this.parentProperty,{flatten:c,wrap:b}=this;if(this.currResultType=this.resultType,this.currEval=this.eval,this.currSandbox=this.sandbox,r=r||this.callback,this.currOtherTypeCallback=a||this.otherTypeCallback,t=t||this.json,n=n||this.path,n&&typeof n=="object"&&!Array.isArray(n)){if(!n.path&&n.path!=="")throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().');if(!Object.hasOwn(n,"json"))throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().');({json:t}=n),c=Object.hasOwn(n,"flatten")?n.flatten:c,this.currResultType=Object.hasOwn(n,"resultType")?n.resultType:this.currResultType,this.currSandbox=Object.hasOwn(n,"sandbox")?n.sandbox:this.currSandbox,b=Object.hasOwn(n,"wrap")?n.wrap:b,this.currEval=Object.hasOwn(n,"eval")?n.eval:this.currEval,r=Object.hasOwn(n,"callback")?n.callback:r,this.currOtherTypeCallback=Object.hasOwn(n,"otherTypeCallback")?n.otherTypeCallback:this.currOtherTypeCallback,i=Object.hasOwn(n,"parent")?n.parent:i,u=Object.hasOwn(n,"parentProperty")?n.parentProperty:u,n=n.path}if(i=i||null,u=u||null,Array.isArray(n)&&(n=we.toPathString(n)),!n&&n!==""||!t)return;const p=we.toPathArray(n);p[0]==="$"&&p.length>1&&p.shift(),this._hasParentSelector=null;const m=this._trace(p,t,["$"],i,u,r).filter(function(_){return _&&!_.isParentSelector});return m.length?!b&&m.length===1&&!m[0].hasArrExpr?this._getPreferredOutput(m[0]):m.reduce((_,D)=>{const V=this._getPreferredOutput(D);return c&&Array.isArray(V)?_=_.concat(V):_.push(V),_},[]):b?[]:void 0},we.prototype._getPreferredOutput=function(n){const t=this.currResultType;switch(t){case"all":{const r=Array.isArray(n.path)?n.path:we.toPathArray(n.path);return n.pointer=we.toPointer(r),n.path=typeof n.path=="string"?n.path:we.toPathString(n.path),n}case"value":case"parent":case"parentProperty":return n[t];case"path":return we.toPathString(n[t]);case"pointer":return we.toPointer(n.path);default:throw new TypeError("Unknown result type")}},we.prototype._handleCallback=function(n,t,r){if(t){const a=this._getPreferredOutput(n);n.path=typeof n.path=="string"?n.path:we.toPathString(n.path),t(a,r,n)}},we.prototype._trace=function(n,t,r,a,i,u,c,b){let p;if(!n.length)return p={path:r,value:t,parent:a,parentProperty:i,hasArrExpr:c},this._handleCallback(p,u,"value"),p;const m=n[0],_=n.slice(1),D=[];function V(j){Array.isArray(j)?j.forEach(Y=>{D.push(Y)}):D.push(j)}if((typeof m!="string"||b)&&t&&Object.hasOwn(t,m))V(this._trace(_,t[m],rt(r,m),t,m,u,c));else if(m==="*")this._walk(t,j=>{V(this._trace(_,t[j],rt(r,j),t,j,u,!0,!0))});else if(m==="..")V(this._trace(_,t,r,a,i,u,c)),this._walk(t,j=>{typeof t[j]=="object"&&V(this._trace(n.slice(),t[j],rt(r,j),t,j,u,!0))});else{if(m==="^")return this._hasParentSelector=!0,{path:r.slice(0,-1),expr:_,isParentSelector:!0};if(m==="~")return p={path:rt(r,m),value:i,parent:a,parentProperty:null},this._handleCallback(p,u,"property"),p;if(m==="$")V(this._trace(_,t,r,null,null,u,c));else if(/^(-?\d*):(-?\d*):?(\d*)$/u.test(m))V(this._slice(m,_,t,r,a,i,u));else if(m.indexOf("?(")===0){if(this.currEval===!1)throw new Error("Eval [?(expr)] prevented in JSONPath expression.");const j=m.replace(/^\?\((.*?)\)$/u,"$1"),Y=/@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(j);Y?this._walk(t,ie=>{const v=[Y[2]],H=Y[1]?t[ie][Y[1]]:t[ie];this._trace(v,H,r,a,i,u,!0).length>0&&V(this._trace(_,t[ie],rt(r,ie),t,ie,u,!0))}):this._walk(t,ie=>{this._eval(j,t[ie],ie,r,a,i)&&V(this._trace(_,t[ie],rt(r,ie),t,ie,u,!0))})}else if(m[0]==="("){if(this.currEval===!1)throw new Error("Eval [(expr)] prevented in JSONPath expression.");V(this._trace(Dt(this._eval(m,t,r.at(-1),r.slice(0,-1),a,i),_),t,r,a,i,u,c))}else if(m[0]==="@"){let j=!1;const Y=m.slice(1,-2);switch(Y){case"scalar":(!t||!["object","function"].includes(typeof t))&&(j=!0);break;case"boolean":case"string":case"undefined":case"function":typeof t===Y&&(j=!0);break;case"integer":Number.isFinite(t)&&!(t%1)&&(j=!0);break;case"number":Number.isFinite(t)&&(j=!0);break;case"nonFinite":typeof t=="number"&&!Number.isFinite(t)&&(j=!0);break;case"object":t&&typeof t===Y&&(j=!0);break;case"array":Array.isArray(t)&&(j=!0);break;case"other":j=this.currOtherTypeCallback(t,r,a,i);break;case"null":t===null&&(j=!0);break;default:throw new TypeError("Unknown value type "+Y)}if(j)return p={path:r,value:t,parent:a,parentProperty:i},this._handleCallback(p,u,"value"),p}else if(m[0]==="`"&&t&&Object.hasOwn(t,m.slice(1))){const j=m.slice(1);V(this._trace(_,t[j],rt(r,j),t,j,u,c,!0))}else if(m.includes(",")){const j=m.split(",");for(const Y of j)V(this._trace(Dt(Y,_),t,r,a,i,u,!0))}else!b&&t&&Object.hasOwn(t,m)&&V(this._trace(_,t[m],rt(r,m),t,m,u,c,!0))}if(this._hasParentSelector)for(let j=0;j<D.length;j++){const Y=D[j];if(Y&&Y.isParentSelector){const ie=this._trace(Y.expr,t,Y.path,a,i,u,c);if(Array.isArray(ie)){D[j]=ie[0];const v=ie.length;for(let H=1;H<v;H++)j++,D.splice(j,0,ie[H])}else D[j]=ie}}return D},we.prototype._walk=function(n,t){if(Array.isArray(n)){const r=n.length;for(let a=0;a<r;a++)t(a)}else n&&typeof n=="object"&&Object.keys(n).forEach(r=>{t(r)})},we.prototype._slice=function(n,t,r,a,i,u,c){if(!Array.isArray(r))return;const b=r.length,p=n.split(":"),m=p[2]&&Number.parseInt(p[2])||1;let _=p[0]&&Number.parseInt(p[0])||0,D=p[1]&&Number.parseInt(p[1])||b;_=_<0?Math.max(0,_+b):Math.min(b,_),D=D<0?Math.max(0,D+b):Math.min(b,D);const V=[];for(let j=_;j<D;j+=m)this._trace(Dt(j,t),r,a,i,u,c,!0).forEach(ie=>{V.push(ie)});return V},we.prototype._eval=function(n,t,r,a,i,u){this.currSandbox._$_parentProperty=u,this.currSandbox._$_parent=i,this.currSandbox._$_property=r,this.currSandbox._$_root=this.json,this.currSandbox._$_v=t;const c=n.includes("@path");c&&(this.currSandbox._$_path=we.toPathString(a.concat([r])));const b=this.currEval+"Script:"+n;if(!we.cache[b]){let p=n.replaceAll("@parentProperty","_$_parentProperty").replaceAll("@parent","_$_parent").replaceAll("@property","_$_property").replaceAll("@root","_$_root").replaceAll(/@([.\s)[])/gu,"_$_v$1");if(c&&(p=p.replaceAll("@path","_$_path")),this.currEval==="safe"||this.currEval===!0||this.currEval===void 0)we.cache[b]=new this.safeVm.Script(p);else if(this.currEval==="native")we.cache[b]=new this.vm.Script(p);else if(typeof this.currEval=="function"&&this.currEval.prototype&&Object.hasOwn(this.currEval.prototype,"runInNewContext")){const m=this.currEval;we.cache[b]=new m(p)}else if(typeof this.currEval=="function")we.cache[b]={runInNewContext:m=>this.currEval(p,m)};else throw new TypeError(`Unknown "eval" property "${this.currEval}"`)}try{return we.cache[b].runInNewContext(this.currSandbox)}catch(p){if(this.ignoreEvalErrors)return!1;throw new Error("jsonPath: "+p.message+": "+n)}},we.cache={},we.toPathString=function(n){const t=n,r=t.length;let a="$";for(let i=1;i<r;i++)/^(~|\^|@.*?\(\))$/u.test(t[i])||(a+=/^[0-9*]+$/u.test(t[i])?"["+t[i]+"]":"['"+t[i]+"']");return a},we.toPointer=function(n){const t=n,r=t.length;let a="";for(let i=1;i<r;i++)/^(~|\^|@.*?\(\))$/u.test(t[i])||(a+="/"+t[i].toString().replaceAll("~","~0").replaceAll("/","~1"));return a},we.toPathArray=function(n){const{cache:t}=we;if(t[n])return t[n].concat();const r=[],i=n.replaceAll(/@(?:null|boolean|number|string|integer|undefined|nonFinite|scalar|array|object|function|other)\(\)/gu,";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu,function(u,c){return"[#"+(r.push(c)-1)+"]"}).replaceAll(/\[['"]([^'\]]*)['"]\]/gu,function(u,c){return"['"+c.replaceAll(".","%@%").replaceAll("~","%%@@%%")+"']"}).replaceAll("~",";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu,";").replaceAll("%@%",".").replaceAll("%%@@%%","~").replaceAll(/(?:;)?(\^+)(?:;)?/gu,function(u,c){return";"+c.split("").join(";")+";"}).replaceAll(/;;;|;;/gu,";..;").replaceAll(/;$|'?\]|'$/gu,"").split(";").map(function(u){const c=u.match(/#(\d+)/u);return!c||!c[1]?u:r[c[1]]});return t[n]=i,t[n].concat()},we.prototype.safeVm={Script:mr};const Er=function(n,t,r){const a=n.length;for(let i=0;i<a;i++){const u=n[i];r(u)&&t.push(n.splice(i--,1)[0])}};class yr{constructor(t){this.code=t}runInNewContext(t){let r=this.code;const a=Object.keys(t),i=[];Er(a,i,m=>typeof t[m]=="function");const u=a.map(m=>t[m]);r=i.reduce((m,_)=>{let D=t[_].toString();return/function/u.test(D)||(D="function "+D),"var "+_+"="+D+";"+m},"")+r,!/(['"])use strict\1/u.test(r)&&!a.includes("arguments")&&(r="var arguments = undefined;"+r),r=r.replace(/;\s*$/u,"");const b=r.lastIndexOf(";"),p=b!==-1?r.slice(0,b+1)+" return "+r.slice(b+1):" return "+r;return new Function(...a,p)(...u)}}we.prototype.vm={Script:yr};const br={class:"json-node"},Ar={key:0,class:"json-node__container"},xr={class:"json-node__line"},Nr=["contenteditable","onKeydown"],Cr={key:1,class:"json-node__colon"},Dr=["title"],vr=["title"],wr={key:4,class:"json-node__comma"},_r={key:0,class:"json-node__children"},Tr={class:"json-node__children-content"},Br={class:"json-node__line json-node__closing-bracket"},Sr={class:"json-node__bracket"},Or={key:0,class:"json-node__comma"},kr={key:1,class:"json-node__primitive"},Rr=["contenteditable","onKeydown"],Ir={key:1,class:"json-node__colon"},Fr=["title"],Pr=["contenteditable","onKeydown"],Lr={key:0,class:"json-node__comma"},Vr=o.defineComponent({name:"JsonNode",__name:"JsonNode",props:{value:{},keyName:{},level:{},path:{default:""},expanded:{},isLast:{type:Boolean,default:!1},theme:{}},emits:["update:value","toggle-expand","copy","update:key"],setup(n,{emit:t}){o.useCssVars(x=>({"2a18b018":x.level,"58a14b93":x.theme.colors.syntaxKey,"46fe1b3e":x.theme.colors.hoverBackground,fbe2c048:x.theme.colors.syntaxBracket,"4bd524bb":x.theme.colors.collapsedText,"3308d23c":x.theme.colors.collapsedBackground,"36380c60":x.theme.colors.collapsedBackgroundHover,"0892365d":x.theme.colors.syntaxString,"0015b195":x.theme.colors.syntaxNumber,"7db95f5c":x.theme.colors.syntaxBoolean,"88ec825a":x.theme.colors.syntaxNull,"537157f7":x.theme.colors.background,"3cee3331":x.theme.colors.selectionBackground,"81323cee":x.theme.colors.indentLine}));const r=n,a=t,i=o.ref(!1),u=o.ref(!1),c=o.ref(""),b=o.ref(""),p=o.ref("string"),m=o.ref(null),_=o.ref(null),D=x=>x!==null&&typeof x=="object"&&!Array.isArray(x)&&"__protected_number__"in x&&Object.keys(x).length===1,V=x=>D(x)?x.__protected_number__:"",j=o.computed(()=>D(r.value)?!1:r.value!==null&&typeof r.value=="object"),Y=o.computed(()=>Array.isArray(r.value)),ie=o.computed(()=>r.path?r.path:r.keyName?r.keyName:"root"),v=o.computed(()=>r.expanded.has(ie.value)),H=o.computed(()=>r.keyName),K=o.computed(()=>Y.value?"[":"{"),$=o.computed(()=>Y.value?"]":"}"),ae=o.computed(()=>{if(!r.value)return"";const B=Object.keys(r.value).length;return Y.value?B>0?` ${B} items `:" ":B>0?` ${B} keys `:" "}),ee=o.computed(()=>{const x=typeof r.value;return r.value===null?"json-node__value--null":x==="boolean"?"json-node__value--boolean":x==="number"||D(r.value)?"json-node__value--number":x==="string"?"json-node__value--string":""}),U=o.computed(()=>r.value===null?"null":typeof r.value=="boolean"||typeof r.value=="number"?String(r.value):D(r.value)?V(r.value):typeof r.value=="string"?`"${r.value}"`:String(r.value)),A=o.computed(()=>"Double-click to edit"),te=x=>r.level===0?x:ie.value?`${ie.value}.${x}`:x,N=x=>{const B=Object.keys(r.value);return B.indexOf(x)===B.length-1},T=()=>{a("toggle-expand",ie.value)},q=()=>{r.level!==0&&(i.value=!0,c.value=r.keyName,o.nextTick(()=>{if(m.value){m.value.focus();const x=document.createRange();x.selectNodeContents(m.value);const B=window.getSelection();B?.removeAllRanges(),B?.addRange(x)}}))},W=()=>{j.value||(u.value=!0,r.value===null?p.value="null":D(r.value)?p.value="protected-number":typeof r.value=="string"?p.value="string":typeof r.value=="number"?p.value="number":typeof r.value=="boolean"&&(p.value="boolean"),D(r.value)?b.value=V(r.value):typeof r.value=="string"?b.value=r.value:b.value=String(r.value),o.nextTick(()=>{if(_.value){_.value.focus();const x=document.createRange();x.selectNodeContents(_.value);const B=window.getSelection();B?.removeAllRanges(),B?.addRange(x)}}))},M=()=>{if(r.level===0||!i.value)return;const x=m.value?.innerText.trim()||"";if(!x){he();return}if(x===r.keyName){i.value=!1;return}i.value=!1,a("update:key",ie.value,x)},de=()=>{if(u.value)try{let x;const B=_.value?.innerText.trim()||"";if(p.value==="string")B==="null"?x=null:B==="true"||B==="false"?x=B==="true":x=B;else if(p.value==="protected-number")x={__protected_number__:B};else if(B==="null")x=null;else if(B==="true"||B==="false")x=B==="true";else if(!isNaN(Number(B))&&B!==""){const X=Number(B);!Number.isSafeInteger(X)||B.length>15?x={__protected_number__:B}:x=X}else x=B;a("update:value",ie.value,x),u.value=!1}catch(x){console.error("Failed to parse value:",x),u.value=!1}},he=()=>{i.value=!1,c.value=r.keyName},ye=()=>{u.value=!1,D(r.value)?b.value=V(r.value):typeof r.value=="string"?b.value=r.value:b.value=String(r.value)};return(x,B)=>{const X=o.resolveComponent("JsonNode",!0);return o.openBlock(),o.createElementBlock("div",br,[j.value?(o.openBlock(),o.createElementBlock("div",Ar,[o.createElementVNode("div",xr,[x.keyName?(o.openBlock(),o.createElementBlock("span",{key:0,class:"json-node__key",contenteditable:i.value,onDblclick:q,onKeydown:[o.withKeys(o.withModifiers(M,["prevent"]),["enter"]),o.withKeys(he,["escape"])],onBlur:M,ref_key:"keyRef",ref:m,title:"Double-click to edit key"},o.toDisplayString(i.value?c.value:`"${H.value}"`),41,Nr)):o.createCommentVNode("",!0),x.keyName?(o.openBlock(),o.createElementBlock("span",Cr,": ")):o.createCommentVNode("",!0),o.createElementVNode("span",{class:"json-node__bracket json-node__bracket--clickable",onClick:T,title:v.value?"Click to collapse":"Click to expand"},o.toDisplayString(K.value),9,Dr),v.value?o.createCommentVNode("",!0):(o.openBlock(),o.createElementBlock("span",{key:2,class:"json-node__collapsed-info",onClick:T,title:`Click to expand ${ae.value.trim()}`},o.toDisplayString(ae.value),9,vr)),v.value?o.createCommentVNode("",!0):(o.openBlock(),o.createElementBlock("span",{key:3,class:"json-node__bracket json-node__bracket--clickable",onClick:T,title:"Click to expand"},o.toDisplayString($.value),1)),!v.value&&!x.isLast?(o.openBlock(),o.createElementBlock("span",wr,",")):o.createCommentVNode("",!0)]),v.value?(o.openBlock(),o.createElementBlock("div",_r,[o.createElementVNode("div",Tr,[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(x.value,(Z,F)=>(o.openBlock(),o.createElementBlock("div",{key:F,class:"json-node__child"},[o.createVNode(X,{value:Z,"key-name":Y.value?"":String(F),level:x.level+1,path:te(String(F)),expanded:x.expanded,theme:x.theme,"onUpdate:value":B[0]||(B[0]=(le,w)=>x.$emit("update:value",le,w)),onToggleExpand:B[1]||(B[1]=le=>x.$emit("toggle-expand",le)),onCopy:B[2]||(B[2]=le=>x.$emit("copy",le)),"onUpdate:key":B[3]||(B[3]=(le,w)=>x.$emit("update:key",le,w)),"is-last":N(String(F))},null,8,["value","key-name","level","path","expanded","theme","is-last"])]))),128))]),o.createElementVNode("div",Br,[o.createElementVNode("span",Sr,o.toDisplayString($.value),1),x.isLast?o.createCommentVNode("",!0):(o.openBlock(),o.createElementBlock("span",Or,","))])])):o.createCommentVNode("",!0)])):(o.openBlock(),o.createElementBlock("div",kr,[x.keyName?(o.openBlock(),o.createElementBlock("span",{key:0,class:"json-node__key",contenteditable:i.value,onDblclick:q,onKeydown:[o.withKeys(o.withModifiers(M,["prevent"]),["enter"]),o.withKeys(he,["escape"])],onBlur:M,ref_key:"keyRef",ref:m,title:"Double-click to edit key"},o.toDisplayString(i.value?c.value:`"${H.value}"`),41,Rr)):o.createCommentVNode("",!0),x.keyName?(o.openBlock(),o.createElementBlock("span",Ir,": ")):o.createCommentVNode("",!0),o.createElementVNode("span",{class:o.normalizeClass(["json-node__value-wrapper",ee.value]),onDblclick:W,title:A.value},[o.createElementVNode("span",{class:"json-node__value",contenteditable:u.value,onKeydown:[o.withKeys(o.withModifiers(de,["prevent"]),["enter"]),o.withKeys(ye,["escape"])],onBlur:de,ref_key:"valueRef",ref:_},o.toDisplayString(u.value?b.value:U.value),41,Pr),x.isLast?o.createCommentVNode("",!0):(o.openBlock(),o.createElementBlock("span",Lr,","))],42,Fr)]))])}}}),ft=(n,t)=>{const r=n.__vccOpts||n;for(const[a,i]of t)r[a]=i;return r},$r=ft(Vr,[["__scopeId","data-v-1472a8af"]]),Rt={name:"github-light",colors:{background:"#ffffff",surfaceBackground:"#f6f8fa",border:"#d0d7de",text:"#24292f",textSecondary:"#656d76",buttonBackground:"#f6f8fa",buttonBackgroundHover:"#f3f4f6",buttonBorder:"#d0d7de",buttonText:"#24292f",buttonPrimary:"#2da44e",buttonPrimaryHover:"#2c974b",success:"#1a7f37",successBackground:"#dafbe1",error:"#cf222e",errorBackground:"#ffebe9",syntaxString:"#0a3069",syntaxNumber:"#0969da",syntaxBoolean:"#8250df",syntaxNull:"#656d76",syntaxKey:"#0969da",syntaxBracket:"#24292f",hoverBackground:"#f6f8fa",selectionBackground:"rgba(9, 105, 218, 0.2)",collapsedBackground:"#ddf4ff",collapsedBackgroundHover:"#b6e3ff",collapsedText:"#0969da",indentLine:"#d0d7de"}},Mr={"github-light":Rt,"github-dark":{name:"github-dark",colors:{background:"#0d1117",surfaceBackground:"#161b22",border:"#30363d",text:"#e6edf3",textSecondary:"#7d8590",buttonBackground:"#21262d",buttonBackgroundHover:"#30363d",buttonBorder:"#30363d",buttonText:"#e6edf3",buttonPrimary:"#238636",buttonPrimaryHover:"#2ea043",success:"#3fb950",successBackground:"#0f2419",error:"#f85149",errorBackground:"#381921",syntaxString:"#a5d6ff",syntaxNumber:"#79c0ff",syntaxBoolean:"#d2a8ff",syntaxNull:"#7d8590",syntaxKey:"#79c0ff",syntaxBracket:"#e6edf3",hoverBackground:"#161b22",selectionBackground:"rgba(121, 192, 255, 0.2)",collapsedBackground:"#1c2128",collapsedBackgroundHover:"#2d333b",collapsedText:"#79c0ff",indentLine:"#30363d"}},"min-light":{name:"min-light",colors:{background:"#ffffff",surfaceBackground:"#fafafa",border:"#e5e5e5",text:"#333333",textSecondary:"#888888",buttonBackground:"#f8f8f8",buttonBackgroundHover:"#eeeeee",buttonBorder:"#e0e0e0",buttonText:"#333333",buttonPrimary:"#007acc",buttonPrimaryHover:"#005a9e",success:"#22c55e",successBackground:"#f0fdf4",error:"#ef4444",errorBackground:"#fef2f2",syntaxString:"#22c55e",syntaxNumber:"#3b82f6",syntaxBoolean:"#8b5cf6",syntaxNull:"#6b7280",syntaxKey:"#1f2937",syntaxBracket:"#374151",hoverBackground:"#f9f9f9",selectionBackground:"rgba(59, 130, 246, 0.2)",collapsedBackground:"#e0f2fe",collapsedBackgroundHover:"#bae6fd",collapsedText:"#0284c7",indentLine:"#e5e7eb"}},"slack-ochin":{name:"slack-ochin",colors:{background:"#fefbf6",surfaceBackground:"#faf6f0",border:"#e8d5b7",text:"#4a3b2a",textSecondary:"#8b7355",buttonBackground:"#f4ede4",buttonBackgroundHover:"#efe5d8",buttonBorder:"#e8d5b7",buttonText:"#4a3b2a",buttonPrimary:"#ff6b35",buttonPrimaryHover:"#e55a2b",success:"#ff9500",successBackground:"#fff8f0",error:"#d73502",errorBackground:"#ffeee8",syntaxString:"#d73502",syntaxNumber:"#ff6b35",syntaxBoolean:"#b7472a",syntaxNull:"#8b7355",syntaxKey:"#4a3b2a",syntaxBracket:"#6b5444",hoverBackground:"#f8f2eb",selectionBackground:"rgba(255, 107, 53, 0.2)",collapsedBackground:"#ffe8d6",collapsedBackgroundHover:"#ffd4b0",collapsedText:"#d73502",indentLine:"#e8d5b7"}}};function Ur(n="github-light"){return Mr[n]||Rt}const qr={key:0,class:"json-format__toolbar"},Hr={class:"json-format__actions"},jr=["disabled"],Kr=["disabled"],Gr=["disabled"],Xr=["disabled"],zr={class:"json-format__info"},Wr={key:0,class:"json-format__status json-format__status--success"},Yr={key:1,class:"json-format__status json-format__status--error"},Qr={class:"json-format__content"},Zr={key:0,class:"json-format__error"},Jr={key:1,class:"json-format__error"},en={key:2,class:"json-format__viewer"},It=ft(o.defineComponent({name:"JsonFormat",__name:"index",props:{modelValue:{default:""},readonly:{type:Boolean,default:!1},maxDepth:{default:10},showToolbar:{type:Boolean,default:!0},theme:{default:"github-light"}},emits:["update:modelValue","copy-success","copy-error","expand-all","collapse-all","compress"],setup(n,{expose:t,emit:r}){o.useCssVars(w=>({"0e2b28fa":V.value.colors.border,f3d81a08:V.value.colors.background,"0af7d57b":V.value.colors.text,"5ee5c82d":V.value.colors.surfaceBackground,ff458768:V.value.colors.buttonBorder,c0efe564:V.value.colors.buttonBackground,"2a4ad566":V.value.colors.buttonText,e48626e4:V.value.colors.buttonBackgroundHover,"748549e2":V.value.colors.buttonPrimary,a39b270c:V.value.colors.buttonPrimaryHover,"61cd2ffa":V.value.colors.successBackground,"43ed24f5":V.value.colors.success,"9c8a2770":V.value.colors.errorBackground,"53354b7a":V.value.colors.error}));const a=n,i=r,u=o.ref(null),c=o.ref(""),b=o.ref(new Set),p=o.ref(null),m=o.ref(""),_=o.ref(!1),D=o.computed(()=>c.value===""),V=o.computed(()=>Ur(a.theme)),j=w=>{if(w==null)return w;if(Array.isArray(w))return w.map(k=>j(k));if(typeof w=="object"){const k={},L=Object.keys(w).sort();for(const G of L)k[G]=j(w[G]);return k}return w},Y=o.computed(()=>{const w=p.value!==null?p.value:u.value;return!w||!_.value?w:j(w)}),ie=o.computed(()=>m.value?null:Y.value),v=w=>{if(!w.trim()){u.value=null,c.value="",p.value=null,m.value="";return}try{let k=w;const L=/(:\s*|,\s*|\[\s*)-?\d{16,}/.test(k),G=/(:\s*|,\s*|\[\s*)-?\d+\.\d*0+\s*[,}\]\s]*/.test(k);if(!L&&!G)try{u.value=JSON.parse(k),c.value="",p.value=null,m.value="",o.nextTick(()=>{ie.value!==null&&W()});return}catch{}k=(R=>{let J="",ge=!1,Ee=!1,_e=0;for(;_e<R.length;){const ke=R[_e];if(ge)Ee?Ee=!1:ke==="\\"?Ee=!0:ke==='"'&&(ge=!1),J+=ke,_e++;else if(ke==='"')ge=!0,J+=ke,_e++;else{const De=R.slice(_e);let z=De.match(/^([:,\[\s]*)(-?\d{16,})(\s*[,\}\]\s]|$)/);if(z){J+=z[1]+'{"__protected_number__":"'+z[2]+'"}'+z[3],_e+=z[0].length;continue}if(z=De.match(/^([:,\[\s]*)(-?\d+\.\d*0+)(\s*[,\}\]\s]|$)/),z){J+=z[1]+'{"__protected_number__":"'+z[2]+'"}'+z[3],_e+=z[0].length;continue}J+=ke,_e++}}return J})(k),u.value=JSON.parse(k),c.value="",p.value=null,m.value="",o.nextTick(()=>{ie.value!==null&&W()})}catch(k){c.value=k instanceof Error?k.message:"Unknown parsing error",u.value=null,p.value=null,m.value=""}},H=w=>{if(!w||!w.expression.trim()){ee();return}if(!u.value){m.value="No valid JSON data to filter";return}try{let k;if(w.type==="jsonpath")k=we({path:w.expression,json:u.value}),k.length===1&&w.expression.includes("$[")===!1&&!w.expression.endsWith("[*]")?p.value=k[0]:p.value=k;else if(w.type==="js"){const{proxyData:L,indexMap:G}=K(u.value),R=new Function("$",`
3
3
  try {
4
- return ${D.expression};
4
+ return ${w.expression};
5
5
  } catch (error) {
6
6
  throw new Error('JavaScript expression error: ' + error.message);
7
7
  }
8
- `)(P);w=re(l.value,C,L),h.value=w}else throw new Error(`Unsupported filter type: ${D.type}`);m.value="",s.nextTick(()=>{K()})}catch(w){m.value=w instanceof Error?w.message:"Filter execution error",h.value=null}},ge=(D,w="root")=>{const P=new Map,L=(C,ne)=>{if(C==null)return C;if(typeof C=="object"&&C.__protected_number__!==void 0){const Ee=parseFloat(C.__protected_number__);return P.set(Ee,ne),Ee}if(Array.isArray(C)){const Ee=C.map((be,Te)=>{const ke=`${ne}[${Te}]`,ve=L(be,ke);return P.set(ve,ke),ve});return P.set(Ee,ne),Ee}if(typeof C=="object"){const Ee={};for(const be in C)if(Object.prototype.hasOwnProperty.call(C,be)){const Te=ne==="root"?be:`${ne}.${be}`;Ee[be]=L(C[be],Te)}return P.set(Ee,ne),Ee}return C};return{proxyData:L(D,w),indexMap:P}},re=(D,w,P)=>{if(w===null||typeof w!="object")return w;if(Array.isArray(w))return w.map(C=>{const ne=P.get(C);if(ne){const Ee=De(D,ne);if(Ee!==void 0)return Ee}return re(D,C,P)});const L=P.get(w);if(L){const C=De(D,L);if(C!==void 0)return C}const W={};for(const C in w)Object.prototype.hasOwnProperty.call(w,C)&&(W[C]=re(D,w[C],P));return W},De=(D,w)=>{if(w==="root")return D;const P=[];let L=w.replace(/^root\.?/,"");const W=/([^\[\].]+)|\[(\d+)\]/g;let C;for(;(C=W.exec(L))!==null;)C[1]?P.push(C[1]):C[2]!==void 0&&P.push(parseInt(C[2]));let ne=D;for(const Ee of P){if(ne==null)return;ne=ne[Ee]}return ne},Ae=()=>{h.value=null,m.value=""},H=()=>{B.value=!0},A=()=>{B.value=!1};s.watch(()=>u.modelValue,D=>{_(D)},{immediate:!0});const de=(D,w,P)=>{const L=ne=>{if(ne===null||typeof ne!="object")return ne;if(!Array.isArray(ne)&&"__protected_number__"in ne&&Object.keys(ne).length===1)return`__PROTECTED_NUMBER_${ne.__protected_number__}_PROTECTED_NUMBER__`;if(Array.isArray(ne))return ne.map(be=>L(be));const Ee={};for(const[be,Te]of Object.entries(ne))Ee[be]=L(Te);return Ee},W=L(D);return JSON.stringify(W,w,P).replace(/"__PROTECTED_NUMBER_(.+?)_PROTECTED_NUMBER__"/g,"$1")},k=(D,w)=>{if(!u.readonly)try{const P=I(l.value,D,w),L=de(P,null,2);i("update:modelValue",L)}catch(P){console.error("Failed to update JSON:",P)}},I=(D,w,P)=>{if(!w||w==="root")return P;const L=w.split("."),W=R(D,L.slice(0,-1));let C=W;for(let Ee=0;Ee<L.length-1;Ee++){const be=L[Ee];be!=="root"&&(Array.isArray(C)?C=C[parseInt(be)]:C=C[be])}const ne=L[L.length-1];return ne==="root"?P:(Array.isArray(C)?C[parseInt(ne)]=P:C[ne]=P,W)},ee=D=>{N.value.has(D)?N.value.delete(D):N.value.add(D)},K=()=>{const D=new Set,w=(P,L="")=>{P!==null&&typeof P=="object"&&(D.add(L||"root"),Array.isArray(P)?P.forEach((W,C)=>{const ne=L?`${L}.${C}`:`${C}`;w(W,ne)}):Object.keys(P).forEach(W=>{const C=L?`${L}.${W}`:W;w(P[W],C)}))};w(le.value),N.value=D,i("expand-all")},q=()=>{N.value=new Set(["root"]),i("collapse-all")},pe=async()=>{if(T.value)try{const D=le.value,w=de(D,null,2);await navigator.clipboard.writeText(w),i("copy-success",w)}catch(D){console.error("Failed to copy JSON:",D),i("copy-error",D instanceof Error?D:new Error("Failed to copy JSON"))}},he=()=>{if(T.value)try{const D=le.value,w=de(D);i("update:modelValue",w),i("compress",w)}catch(D){console.error("Failed to compress JSON:",D)}},F=async D=>{try{let w;typeof D=="object"&&D!==null&&!Array.isArray(D)&&"__protected_number__"in D&&Object.keys(D).length===1?w=D.__protected_number__:typeof D=="string"?w=`"${D}"`:w=JSON.stringify(D),await navigator.clipboard.writeText(w)}catch(w){console.error("Failed to copy value:",w)}},x=(D,w)=>{if(!u.readonly)try{const P=S(l.value,D,w),L=de(P,null,2);i("update:modelValue",L),J(D,w)}catch(P){console.error("Failed to rename key:",P)}},S=(D,w,P)=>{if(!w||w==="root")return D;const L=w.split("."),W=R(D,L.slice(0,-1));if(L.length===1){const Ee=L[0];return W&&typeof W=="object"&&!Array.isArray(W)?j(W,Ee,P):W}let C=W;for(let Ee=0;Ee<L.length-1;Ee++){const be=L[Ee];Array.isArray(C)?C=C[parseInt(be)]:C=C[be]}const ne=L[L.length-1];if(!Array.isArray(C)&&C&&typeof C=="object"){const Ee=j(C,ne,P),be=L.slice(0,-1);be.length>0&&M(W,be,Ee)}return W},R=(D,w)=>{if(w.length===0)return D;if(Array.isArray(D)){const P=[...D],L=w[0],W=parseInt(L);return w.length===1||(P[W]=R(D[W],w.slice(1))),P}else if(D&&typeof D=="object"){const P={...D},L=w[0];return w.length===1||(P[L]=R(D[L],w.slice(1))),P}return D},j=(D,w,P)=>{if(!D||typeof D!="object"||Array.isArray(D))return D;const L=Object.keys(D),W={};for(const C of L)C===w?W[P]=D[C]:W[C]=D[C];return W},M=(D,w,P)=>{let L=D;for(let C=0;C<w.length-1;C++){const ne=w[C];Array.isArray(L)?L=L[parseInt(ne)]:L=L[ne]}const W=w[w.length-1];Array.isArray(L)?L[parseInt(W)]=P:L[W]=P},J=(D,w)=>{const P=new Set;N.value.forEach(L=>{if(L===D){const W=D.split(".");W[W.length-1]=w,P.add(W.join("."))}else if(L.startsWith(D+".")){const W=D.split(".");W[W.length-1]=w;const C=W.join("."),ne=L.substring(D.length);P.add(C+ne)}else P.add(L)}),N.value=P};return t({copyJson:pe,compressSource:he,expandAll:K,collapseAll:q,toggleExpand:ee,updateValue:k,updateKey:x,filter:oe,clearFilter:Ae,sortKeys:H,clearSortKeys:A,isSorted:()=>B.value,isValidJson:()=>T.value,getParsedJson:()=>l.value,getFilteredJson:()=>h.value,getExpandedNodes:()=>N.value,getParseError:()=>p.value,getFilterError:()=>m.value,parseJson:D=>_(D),copyValue:D=>F(D)}),(D,w)=>(s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass(["json-format",`json-format--${U.value.name}`])},[D.showToolbar?(s.openBlock(),s.createElementBlock("div",Vr,[s.createElementVNode("div",Mr,[s.createElementVNode("button",{class:"json-format__btn json-format__btn--primary",onClick:pe,disabled:!T.value,title:"Copy JSON"}," 📋 Copy ",8,Ur),s.createElementVNode("button",{class:"json-format__btn json-format__btn--secondary",onClick:K,disabled:!T.value,title:"Expand All"}," ⬇️ Expand All ",8,qr),s.createElementVNode("button",{class:"json-format__btn json-format__btn--secondary",onClick:q,disabled:!T.value,title:"Collapse All"}," ➡️ Collapse All ",8,$r),s.createElementVNode("button",{class:"json-format__btn json-format__btn--secondary",onClick:he,disabled:!T.value,title:"Compress JSON"}," 📦 Compress ",8,jr)]),s.createElementVNode("div",Xr,[T.value?(s.openBlock(),s.createElementBlock("span",Hr," ✅ Valid JSON ")):(s.openBlock(),s.createElementBlock("span",Gr," ❌ Invalid JSON "))])])):s.createCommentVNode("",!0),s.createElementVNode("div",Kr,[T.value?m.value?(s.openBlock(),s.createElementBlock("div",Yr,[w[1]||(w[1]=s.createElementVNode("h4",null,"Filter Error:",-1)),s.createElementVNode("pre",null,s.toDisplayString(m.value),1)])):(s.openBlock(),s.createElementBlock("div",Wr,[s.createVNode(Ir,{value:le.value,"key-name":"",level:0,expanded:N.value,"is-last":!0,theme:U.value,"onUpdate:value":k,onToggleExpand:ee,onCopy:F,"onUpdate:key":x},null,8,["value","expanded","theme"])])):(s.openBlock(),s.createElementBlock("div",zr,[w[0]||(w[0]=s.createElementVNode("h4",null,"JSON Parse Error:",-1)),s.createElementVNode("pre",null,s.toDisplayString(p.value),1)]))])],2))}}),[["__scopeId","data-v-94157be3"]]);function Qr(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var vt={},Ft;function Zr(){return Ft||(Ft=1,function(n){var t=n;(function(r){var u="__namespace",i=function(e){return e==null},l=function(e){return e===u||Number.isInteger(e)&&e>=1&&e<=11},p=function(e){return e&&l(e.nodeType)&&typeof e.nodeName=="string"};function N(e){var o=Array.prototype.slice,f=e.length,y=function(b,Q){return function(){return Q.apply(this,b.concat(o.call(arguments)))}},d=function(){var b=o.call(arguments);return b.length<f?y(b,d):e.apply(this,o.apply(arguments,[0,f]))};return d}var h=function(e,o){for(var f=0;f<o.length;f+=1)e(o[f],f,o)},m=function(e,o,f){var y=o;return h(function(d,b){y=e(y,d,b)},f),y},B=function(e,o){var f=new Array(o.length);return h(function(y,d){f[d]=e(y)},o),f},T=function(e,o){var f=[];return h(function(y,d){e(y,d)&&f.push(y)},o),f},U=function(e,o){for(var f=0;f<e.length;f+=1)if(e[f]===o)return!0;return!1};function V(e){return function(){return e}}function ae(e){return e.toString()}var le=function(e,o){return o.join(e)},_=function(e,o,f){return e+f+o},oe=Array.prototype.concat,ge=function(e,o){var f=new te;f.addArray(e);var y=f.toArray();return o?y.reverse():y},re=32767;function De(e){for(var o=[],f=0;f<e.length;f+=re){var y=e.slice(f,f+re);o=oe.apply(o,y)}return o}function Ae(e,o){for(var f=Object(e),y=1;y<arguments.length;y++){var d=arguments[y];if(d!=null)for(var b in d)Object.prototype.hasOwnProperty.call(d,b)&&(f[b]=d[b])}return f}var H={ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NAMESPACE_NODE:u};A.prototype=new Object,A.prototype.constructor=A,A.superclass=Object.prototype;function A(){this.init()}A.prototype.init=function(){this.reduceActions=[],this.reduceActions[3]=function(e){return new pe(e[0],e[2])},this.reduceActions[5]=function(e){return new he(e[0],e[2])},this.reduceActions[7]=function(e){return new F(e[0],e[2])},this.reduceActions[8]=function(e){return new x(e[0],e[2])},this.reduceActions[10]=function(e){return new S(e[0],e[2])},this.reduceActions[11]=function(e){return new R(e[0],e[2])},this.reduceActions[12]=function(e){return new j(e[0],e[2])},this.reduceActions[13]=function(e){return new M(e[0],e[2])},this.reduceActions[15]=function(e){return new J(e[0],e[2])},this.reduceActions[16]=function(e){return new D(e[0],e[2])},this.reduceActions[18]=function(e){return new w(e[0],e[2])},this.reduceActions[19]=function(e){return new P(e[0],e[2])},this.reduceActions[20]=function(e){return new L(e[0],e[2])},this.reduceActions[22]=function(e){return new K(e[1])},this.reduceActions[24]=function(e){return new W(e[0],e[2])},this.reduceActions[25]=function(e){return new C(void 0,void 0,e[0])},this.reduceActions[27]=function(e){return e[0].locationPath=e[2],e[0]},this.reduceActions[28]=function(e){return e[0].locationPath=e[2],e[0].locationPath.steps.unshift(new g(g.DESCENDANTORSELF,$.nodeTest,[])),e[0]},this.reduceActions[29]=function(e){return new C(e[0],[],void 0)},this.reduceActions[30]=function(e){return ue.instance_of(e[0],C)?(e[0].filterPredicates==null&&(e[0].filterPredicates=[]),e[0].filterPredicates.push(e[1]),e[0]):new C(e[0],[e[1]],void 0)},this.reduceActions[32]=function(e){return e[1]},this.reduceActions[33]=function(e){return new X(e[0])},this.reduceActions[34]=function(e){return new z(e[0])},this.reduceActions[36]=function(e){return new ce(e[0],[])},this.reduceActions[37]=function(e){return new ce(e[0],e[2])},this.reduceActions[38]=function(e){return[e[0]]},this.reduceActions[39]=function(e){return e[2].unshift(e[0]),e[2]},this.reduceActions[43]=function(e){return new ve(!0,[])},this.reduceActions[44]=function(e){return e[1].absolute=!0,e[1]},this.reduceActions[46]=function(e){return new ve(!1,[e[0]])},this.reduceActions[47]=function(e){return e[0].steps.push(e[2]),e[0]},this.reduceActions[49]=function(e){return new g(e[0],e[1],[])},this.reduceActions[50]=function(e){return new g(g.CHILD,e[0],[])},this.reduceActions[51]=function(e){return new g(e[0],e[1],e[2])},this.reduceActions[52]=function(e){return new g(g.CHILD,e[0],e[1])},this.reduceActions[54]=function(e){return[e[0]]},this.reduceActions[55]=function(e){return e[1].unshift(e[0]),e[1]},this.reduceActions[56]=function(e){return e[0]=="ancestor"?g.ANCESTOR:e[0]=="ancestor-or-self"?g.ANCESTORORSELF:e[0]=="attribute"?g.ATTRIBUTE:e[0]=="child"?g.CHILD:e[0]=="descendant"?g.DESCENDANT:e[0]=="descendant-or-self"?g.DESCENDANTORSELF:e[0]=="following"?g.FOLLOWING:e[0]=="following-sibling"?g.FOLLOWINGSIBLING:e[0]=="namespace"?g.NAMESPACE:e[0]=="parent"?g.PARENT:e[0]=="preceding"?g.PRECEDING:e[0]=="preceding-sibling"?g.PRECEDINGSIBLING:e[0]=="self"?g.SELF:-1},this.reduceActions[57]=function(e){return g.ATTRIBUTE},this.reduceActions[59]=function(e){return e[0]=="comment"?$.commentTest:e[0]=="text"?$.textTest:e[0]=="processing-instruction"?$.anyPiTest:e[0]=="node"?$.nodeTest:new $(-1,void 0)},this.reduceActions[60]=function(e){return new $.PITest(e[2])},this.reduceActions[61]=function(e){return e[1]},this.reduceActions[63]=function(e){return e[1].absolute=!0,e[1].steps.unshift(new g(g.DESCENDANTORSELF,$.nodeTest,[])),e[1]},this.reduceActions[64]=function(e){return e[0].steps.push(new g(g.DESCENDANTORSELF,$.nodeTest,[])),e[0].steps.push(e[2]),e[0]},this.reduceActions[65]=function(e){return new g(g.SELF,$.nodeTest,[])},this.reduceActions[66]=function(e){return new g(g.PARENT,$.nodeTest,[])},this.reduceActions[67]=function(e){return new _e(e[1])},this.reduceActions[68]=function(e){return $.nameTestAny},this.reduceActions[69]=function(e){return new $.NameTestPrefixAny(e[0].split(":")[0])},this.reduceActions[70]=function(e){return new $.NameTestQName(e[0])}},A.actionTable=[" s s sssssssss s ss s ss"," s ","r rrrrrrrrr rrrrrrr rr r "," rrrrr "," s s sssssssss s ss s ss","rs rrrrrrrr s sssssrrrrrr rrs rs "," s s sssssssss s ss s ss"," s "," s ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," s "," s "," s s sssss s s ","r rrrrrrrrr rrrrrrr rr r ","a ","r s rr r ","r sr rr r ","r s rr s rr r ","r rssrr rss rr r ","r rrrrr rrrss rr r ","r rrrrrsss rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrrs rr r ","r rrrrrrrr rrrrrr rr r ","r rrrrrrrr rrrrrr rr r ","r srrrrrrrr rrrrrrs rr sr ","r srrrrrrrr rrrrrrs rr r ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrr rrrrrr rr r ","r rrrrrrrr rrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r "," sssss ","r rrrrrrrrr rrrrrrr rr sr ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," s ","r srrrrrrrr rrrrrrs rr r ","r rrrrrrrr rrrrr rr r "," s "," s "," rrrrr "," s s sssssssss s sss s ss","r srrrrrrrr rrrrrrs rr r "," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss ss s ss"," s s sssssssss s ss s ss"," s s sssss s s "," s s sssss s s ","r rrrrrrrrr rrrrrrr rr rr "," s s sssss s s "," s s sssss s s ","r rrrrrrrrr rrrrrrr rr sr ","r rrrrrrrrr rrrrrrr rr sr ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr rr "," s ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," rr "," s "," rs ","r sr rr r ","r s rr s rr r ","r rssrr rss rr r ","r rssrr rss rr r ","r rrrrr rrrss rr r ","r rrrrr rrrss rr r ","r rrrrr rrrss rr r ","r rrrrr rrrss rr r ","r rrrrrsss rrrrr rr r ","r rrrrrsss rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrrr rr r "," r "," s ","r srrrrrrrr rrrrrrs rr r ","r srrrrrrrr rrrrrrs rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," s s sssssssss s ss s ss","r rrrrrrrrr rrrrrrr rr rr "," r "],A.actionTableNumber=[` 1 0 /.-,+*)(' & %$ # "!`," J ","a aaaaaaaaa aaaaaaa aa a "," YYYYY ",` 1 0 /.-,+*)(' & %$ # "!`,`K1 KKKKKKKK . +*)('KKKKKK KK# K" `,` 1 0 /.-,+*)(' & %$ # "!`," N "," O ","e eeeeeeeee eeeeeee ee ee ","f fffffffff fffffff ff ff ","d ddddddddd ddddddd dd dd ","B BBBBBBBBB BBBBBBB BB BB ","A AAAAAAAAA AAAAAAA AA AA "," P "," Q ",` 1 . +*)(' # " `,"b bbbbbbbbb bbbbbbb bb b "," ","! S !! ! ",'" T" "" " ',"$ V $$ U $$ $ ","& &ZY&& &XW && & ",") ))))) )))\\[ )) ) ",". ....._^] ..... .. . ","1 11111111 11111 11 1 ","5 55555555 55555` 55 5 ","7 77777777 777777 77 7 ","9 99999999 999999 99 9 ",": c:::::::: ::::::b :: a: ","I fIIIIIIII IIIIIIe II I ","= ========= ======= == == ","? ????????? ??????? ?? ?? ","C CCCCCCCCC CCCCCCC CC CC ","J JJJJJJJJ JJJJJJ JJ J ","M MMMMMMMM MMMMMM MM M ","N NNNNNNNNN NNNNNNN NN N ","P PPPPPPPPP PPPPPPP PP P "," +*)(' ","R RRRRRRRRR RRRRRRR RR aR ","U UUUUUUUUU UUUUUUU UU U ","Z ZZZZZZZZZ ZZZZZZZ ZZ ZZ ","c ccccccccc ccccccc cc cc "," j ","L fLLLLLLLL LLLLLLe LL L ","6 66666666 66666 66 6 "," k "," l "," XXXXX ",` 1 0 /.-,+*)(' & %$m # "!`,"_ f________ ______e __ _ ",` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 . +*)(' # " `,` 1 . +*)(' # " `,"> >>>>>>>>> >>>>>>> >> >> ",` 1 . +*)(' # " `,` 1 . +*)(' # " `,"Q QQQQQQQQQ QQQQQQQ QQ aQ ","V VVVVVVVVV VVVVVVV VV aV ","T TTTTTTTTT TTTTTTT TT T ","@ @@@@@@@@@ @@@@@@@ @@ @@ "," ‡ ","[ [[[[[[[[[ [[[[[[[ [[ [[ ","D DDDDDDDDD DDDDDDD DD DD "," HH "," ˆ "," F‰ ","# T# ## # ","% V %% U %% % ","' 'ZY'' 'XW '' ' ","( (ZY(( (XW (( ( ","+ +++++ +++\\[ ++ + ","* ***** ***\\[ ** * ","- ----- ---\\[ -- - ",", ,,,,, ,,,\\[ ,, , ","0 00000_^] 00000 00 0 ","/ /////_^] ///// // / ","2 22222222 22222 22 2 ","3 33333333 33333 33 3 ","4 44444444 44444 44 4 ","8 88888888 888888 88 8 "," ^ "," Š ","; f;;;;;;;; ;;;;;;e ;; ; ","< f<<<<<<<< <<<<<<e << < ","O OOOOOOOOO OOOOOOO OO O ","` ````````` ``````` `` ` ","S SSSSSSSSS SSSSSSS SS S ","W WWWWWWWWW WWWWWWW WW W ","\\ \\\\\\\\\\\\\\\\\\ \\\\\\\\\\\\\\ \\\\ \\\\ ","E EEEEEEEEE EEEEEEE EE EE ",` 1 0 /.-,+*)(' & %$ # "!`,"] ]]]]]]]]] ]]]]]]] ]] ]] "," G "],A.gotoTable=["3456789:;<=>?@ AB CDEFGH IJ "," "," "," ","L456789:;<=>?@ AB CDEFGH IJ "," M EFGH IJ "," N;<=>?@ AB CDEFGH IJ "," "," "," "," "," "," "," "," "," "," S EFGH IJ "," "," "," "," "," "," "," "," "," "," "," "," "," e "," "," "," "," "," "," "," "," "," h J "," i j "," "," "," "," "," "," "," "," "," ","o456789:;<=>?@ ABpqCDEFGH IJ "," "," r6789:;<=>?@ AB CDEFGH IJ "," s789:;<=>?@ AB CDEFGH IJ "," t89:;<=>?@ AB CDEFGH IJ "," u89:;<=>?@ AB CDEFGH IJ "," v9:;<=>?@ AB CDEFGH IJ "," w9:;<=>?@ AB CDEFGH IJ "," x9:;<=>?@ AB CDEFGH IJ "," y9:;<=>?@ AB CDEFGH IJ "," z:;<=>?@ AB CDEFGH IJ "," {:;<=>?@ AB CDEFGH IJ "," |;<=>?@ AB CDEFGH IJ "," };<=>?@ AB CDEFGH IJ "," ~;<=>?@ AB CDEFGH IJ "," =>?@ AB CDEFGH IJ ","€456789:;<=>?@ AB CDEFGH IJ"," ‚ EFGH IJ "," ƒ EFGH IJ "," "," „ GH IJ "," … GH IJ "," i † "," i ‡ "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," ","o456789:;<=>?@ ABŒqCDEFGH IJ "," "," "],A.productions=[[1,1,2],[2,1,3],[3,1,4],[3,3,3,-9,4],[4,1,5],[4,3,4,-8,5],[5,1,6],[5,3,5,-22,6],[5,3,5,-5,6],[6,1,7],[6,3,6,-23,7],[6,3,6,-24,7],[6,3,6,-6,7],[6,3,6,-7,7],[7,1,8],[7,3,7,-25,8],[7,3,7,-26,8],[8,1,9],[8,3,8,-12,9],[8,3,8,-11,9],[8,3,8,-10,9],[9,1,10],[9,2,-26,9],[10,1,11],[10,3,10,-27,11],[11,1,12],[11,1,13],[11,3,13,-28,14],[11,3,13,-4,14],[13,1,15],[13,2,13,16],[15,1,17],[15,3,-29,2,-30],[15,1,-15],[15,1,-16],[15,1,18],[18,3,-13,-29,-30],[18,4,-13,-29,19,-30],[19,1,20],[19,3,20,-31,19],[20,1,2],[12,1,14],[12,1,21],[21,1,-28],[21,2,-28,14],[21,1,22],[14,1,23],[14,3,14,-28,23],[14,1,24],[23,2,25,26],[23,1,26],[23,3,25,26,27],[23,2,26,27],[23,1,28],[27,1,16],[27,2,16,27],[25,2,-14,-3],[25,1,-32],[26,1,29],[26,3,-20,-29,-30],[26,4,-21,-29,-15,-30],[16,3,-33,30,-34],[30,1,2],[22,2,-4,14],[24,3,14,-4,23],[28,1,-35],[28,1,-2],[17,2,-36,-18],[29,1,-17],[29,1,-19],[29,1,-18]],A.DOUBLEDOT=2,A.DOUBLECOLON=3,A.DOUBLESLASH=4,A.NOTEQUAL=5,A.LESSTHANOREQUAL=6,A.GREATERTHANOREQUAL=7,A.AND=8,A.OR=9,A.MOD=10,A.DIV=11,A.MULTIPLYOPERATOR=12,A.FUNCTIONNAME=13,A.AXISNAME=14,A.LITERAL=15,A.NUMBER=16,A.ASTERISKNAMETEST=17,A.QNAME=18,A.NCNAMECOLONASTERISK=19,A.NODETYPE=20,A.PROCESSINGINSTRUCTIONWITHLITERAL=21,A.EQUALS=22,A.LESSTHAN=23,A.GREATERTHAN=24,A.PLUS=25,A.MINUS=26,A.BAR=27,A.SLASH=28,A.LEFTPARENTHESIS=29,A.RIGHTPARENTHESIS=30,A.COMMA=31,A.AT=32,A.LEFTBRACKET=33,A.RIGHTBRACKET=34,A.DOT=35,A.DOLLAR=36,A.prototype.tokenize=function(e){for(var o=[],f=[],y=e+"\0",d=0,b=y.charAt(d++);;){for(;b==" "||b==" "||b=="\r"||b==`
9
- `;)b=y.charAt(d++);if(b=="\0"||d>=y.length)break;if(b=="("){o.push(A.LEFTPARENTHESIS),f.push(b),b=y.charAt(d++);continue}if(b==")"){o.push(A.RIGHTPARENTHESIS),f.push(b),b=y.charAt(d++);continue}if(b=="["){o.push(A.LEFTBRACKET),f.push(b),b=y.charAt(d++);continue}if(b=="]"){o.push(A.RIGHTBRACKET),f.push(b),b=y.charAt(d++);continue}if(b=="@"){o.push(A.AT),f.push(b),b=y.charAt(d++);continue}if(b==","){o.push(A.COMMA),f.push(b),b=y.charAt(d++);continue}if(b=="|"){o.push(A.BAR),f.push(b),b=y.charAt(d++);continue}if(b=="+"){o.push(A.PLUS),f.push(b),b=y.charAt(d++);continue}if(b=="-"){o.push(A.MINUS),f.push(b),b=y.charAt(d++);continue}if(b=="="){o.push(A.EQUALS),f.push(b),b=y.charAt(d++);continue}if(b=="$"){o.push(A.DOLLAR),f.push(b),b=y.charAt(d++);continue}if(b=="."){if(b=y.charAt(d++),b=="."){o.push(A.DOUBLEDOT),f.push(".."),b=y.charAt(d++);continue}if(b>="0"&&b<="9"){var Q="."+b;for(b=y.charAt(d++);b>="0"&&b<="9";)Q+=b,b=y.charAt(d++);o.push(A.NUMBER),f.push(Q);continue}o.push(A.DOT),f.push(".");continue}if(b=="'"||b=='"'){for(var xe=b,Ne="";d<y.length&&(b=y.charAt(d))!==xe;)Ne+=b,d+=1;if(b!==xe)throw Me.fromMessage("Unterminated string literal: "+xe+Ne);d+=1,o.push(A.LITERAL),f.push(Ne),b=y.charAt(d++);continue}if(b>="0"&&b<="9"){var Q=b;for(b=y.charAt(d++);b>="0"&&b<="9";)Q+=b,b=y.charAt(d++);if(b=="."&&y.charAt(d)>="0"&&y.charAt(d)<="9")for(Q+=b,Q+=y.charAt(d++),b=y.charAt(d++);b>="0"&&b<="9";)Q+=b,b=y.charAt(d++);o.push(A.NUMBER),f.push(Q);continue}if(b=="*"){if(o.length>0){var Z=o[o.length-1];if(Z!=A.AT&&Z!=A.DOUBLECOLON&&Z!=A.LEFTPARENTHESIS&&Z!=A.LEFTBRACKET&&Z!=A.AND&&Z!=A.OR&&Z!=A.MOD&&Z!=A.DIV&&Z!=A.MULTIPLYOPERATOR&&Z!=A.SLASH&&Z!=A.DOUBLESLASH&&Z!=A.BAR&&Z!=A.PLUS&&Z!=A.MINUS&&Z!=A.EQUALS&&Z!=A.NOTEQUAL&&Z!=A.LESSTHAN&&Z!=A.LESSTHANOREQUAL&&Z!=A.GREATERTHAN&&Z!=A.GREATERTHANOREQUAL){o.push(A.MULTIPLYOPERATOR),f.push(b),b=y.charAt(d++);continue}}o.push(A.ASTERISKNAMETEST),f.push(b),b=y.charAt(d++);continue}if(b==":"&&y.charAt(d)==":"){o.push(A.DOUBLECOLON),f.push("::"),d++,b=y.charAt(d++);continue}if(b=="/"){if(b=y.charAt(d++),b=="/"){o.push(A.DOUBLESLASH),f.push("//"),b=y.charAt(d++);continue}o.push(A.SLASH),f.push("/");continue}if(b=="!"&&y.charAt(d)=="="){o.push(A.NOTEQUAL),f.push("!="),d++,b=y.charAt(d++);continue}if(b=="<"){if(y.charAt(d)=="="){o.push(A.LESSTHANOREQUAL),f.push("<="),d++,b=y.charAt(d++);continue}o.push(A.LESSTHAN),f.push("<"),b=y.charAt(d++);continue}if(b==">"){if(y.charAt(d)=="="){o.push(A.GREATERTHANOREQUAL),f.push(">="),d++,b=y.charAt(d++);continue}o.push(A.GREATERTHAN),f.push(">"),b=y.charAt(d++);continue}if(b=="_"||ue.isLetter(b.charCodeAt(0))){var ie=b;for(b=y.charAt(d++);ue.isNCNameChar(b.charCodeAt(0));)ie+=b,b=y.charAt(d++);if(o.length>0){var Z=o[o.length-1];if(Z!=A.AT&&Z!=A.DOUBLECOLON&&Z!=A.LEFTPARENTHESIS&&Z!=A.LEFTBRACKET&&Z!=A.AND&&Z!=A.OR&&Z!=A.MOD&&Z!=A.DIV&&Z!=A.MULTIPLYOPERATOR&&Z!=A.SLASH&&Z!=A.DOUBLESLASH&&Z!=A.BAR&&Z!=A.PLUS&&Z!=A.MINUS&&Z!=A.EQUALS&&Z!=A.NOTEQUAL&&Z!=A.LESSTHAN&&Z!=A.LESSTHANOREQUAL&&Z!=A.GREATERTHAN&&Z!=A.GREATERTHANOREQUAL){if(ie=="and"){o.push(A.AND),f.push(ie);continue}if(ie=="or"){o.push(A.OR),f.push(ie);continue}if(ie=="mod"){o.push(A.MOD),f.push(ie);continue}if(ie=="div"){o.push(A.DIV),f.push(ie);continue}}}if(b==":"){if(y.charAt(d)=="*"){o.push(A.NCNAMECOLONASTERISK),f.push(ie+":*"),d++,b=y.charAt(d++);continue}if(y.charAt(d)=="_"||ue.isLetter(y.charCodeAt(d))){for(ie+=":",b=y.charAt(d++);ue.isNCNameChar(b.charCodeAt(0));)ie+=b,b=y.charAt(d++);if(b=="("){o.push(A.FUNCTIONNAME),f.push(ie);continue}o.push(A.QNAME),f.push(ie);continue}if(y.charAt(d)==":"){o.push(A.AXISNAME),f.push(ie);continue}}if(b=="("){if(ie=="comment"||ie=="text"||ie=="node"){o.push(A.NODETYPE),f.push(ie);continue}if(ie=="processing-instruction"){y.charAt(d)==")"?o.push(A.NODETYPE):o.push(A.PROCESSINGINSTRUCTIONWITHLITERAL),f.push(ie);continue}o.push(A.FUNCTIONNAME),f.push(ie);continue}o.push(A.QNAME),f.push(ie);continue}throw new Error("Unexpected character "+b)}return o.push(1),f.push("[EOF]"),[o,f]},A.SHIFT="s",A.REDUCE="r",A.ACCEPT="a",A.prototype.parse=function(Ne){if(!Ne)throw new Error("XPath expression unspecified.");if(typeof Ne!="string")throw new Error("XPath expression must be a string.");var o,f,y=this.tokenize(Ne);if(y!=null){o=y[0],f=y[1];var d=0,b=[],Q=[],xe=[],Ne,Z,ie;for(b.push(0),Q.push(1),xe.push("_S"),Z=o[d],ie=f[d++];;)switch(Ne=b[b.length-1],A.actionTable[Ne].charAt(Z-1)){case A.SHIFT:Q.push(-Z),xe.push(ie),b.push(A.actionTableNumber[Ne].charCodeAt(Z-1)-32),Z=o[d],ie=f[d++];break;case A.REDUCE:for(var Pe=A.productions[A.actionTableNumber[Ne].charCodeAt(Z-1)-32][1],je=[],Se=0;Se<Pe;Se++)Q.pop(),je.unshift(xe.pop()),b.pop();var ze=b[b.length-1];Q.push(A.productions[A.actionTableNumber[Ne].charCodeAt(Z-1)-32][0]),this.reduceActions[A.actionTableNumber[Ne].charCodeAt(Z-1)-32]==null?xe.push(je[0]):xe.push(this.reduceActions[A.actionTableNumber[Ne].charCodeAt(Z-1)-32](je)),b.push(A.gotoTable[ze].charCodeAt(A.productions[A.actionTableNumber[Ne].charCodeAt(Z-1)-32][0]-2)-33);break;case A.ACCEPT:return new de(xe.pop());default:throw new Error("XPath parse error")}}},de.prototype=new Object,de.prototype.constructor=de,de.superclass=Object.prototype;function de(e){this.expression=e}de.prototype.toString=function(){return this.expression.toString()};function k(e,o,f){o in e||(e[o]=f)}de.prototype.evaluate=function(e){var o=e.expressionContextNode;if(!(i(o)||p(o)))throw new Error("Context node does not appear to be a valid DOM node.");return e.contextNode=e.expressionContextNode,e.contextSize=1,e.contextPosition=1,e.isHtml&&(k(e,"caseInsensitive",!0),k(e,"allowAnyNamespaceForNoPrefix",!0)),k(e,"caseInsensitive",!1),this.expression.evaluate(e)},de.XML_NAMESPACE_URI="http://www.w3.org/XML/1998/namespace",de.XMLNS_NAMESPACE_URI="http://www.w3.org/2000/xmlns/",I.prototype=new Object,I.prototype.constructor=I,I.superclass=Object.prototype;function I(){}I.prototype.init=function(){},I.prototype.toString=function(){return"<Expression>"},I.prototype.evaluate=function(e){throw new Error("Could not evaluate expression.")},ee.prototype=new I,ee.prototype.constructor=ee,ee.superclass=I.prototype;function ee(e){arguments.length>0&&this.init(e)}ee.prototype.init=function(e){this.rhs=e},K.prototype=new ee,K.prototype.constructor=K,K.superclass=ee.prototype;function K(e){arguments.length>0&&this.init(e)}K.prototype.init=function(e){K.superclass.init.call(this,e)},K.prototype.evaluate=function(e){return this.rhs.evaluate(e).number().negate()},K.prototype.toString=function(){return"-"+this.rhs.toString()},q.prototype=new I,q.prototype.constructor=q,q.superclass=I.prototype;function q(e,o){arguments.length>0&&this.init(e,o)}q.prototype.init=function(e,o){this.lhs=e,this.rhs=o},pe.prototype=new q,pe.prototype.constructor=pe,pe.superclass=q.prototype;function pe(e,o){arguments.length>0&&this.init(e,o)}pe.prototype.init=function(e,o){pe.superclass.init.call(this,e,o)},pe.prototype.toString=function(){return"("+this.lhs.toString()+" or "+this.rhs.toString()+")"},pe.prototype.evaluate=function(e){var o=this.lhs.evaluate(e).bool();return o.booleanValue()?o:this.rhs.evaluate(e).bool()},he.prototype=new q,he.prototype.constructor=he,he.superclass=q.prototype;function he(e,o){arguments.length>0&&this.init(e,o)}he.prototype.init=function(e,o){he.superclass.init.call(this,e,o)},he.prototype.toString=function(){return"("+this.lhs.toString()+" and "+this.rhs.toString()+")"},he.prototype.evaluate=function(e){var o=this.lhs.evaluate(e).bool();return o.booleanValue()?this.rhs.evaluate(e).bool():o},F.prototype=new q,F.prototype.constructor=F,F.superclass=q.prototype;function F(e,o){arguments.length>0&&this.init(e,o)}F.prototype.init=function(e,o){F.superclass.init.call(this,e,o)},F.prototype.toString=function(){return"("+this.lhs.toString()+" = "+this.rhs.toString()+")"},F.prototype.evaluate=function(e){return this.lhs.evaluate(e).equals(this.rhs.evaluate(e))},x.prototype=new q,x.prototype.constructor=x,x.superclass=q.prototype;function x(e,o){arguments.length>0&&this.init(e,o)}x.prototype.init=function(e,o){x.superclass.init.call(this,e,o)},x.prototype.toString=function(){return"("+this.lhs.toString()+" != "+this.rhs.toString()+")"},x.prototype.evaluate=function(e){return this.lhs.evaluate(e).notequal(this.rhs.evaluate(e))},S.prototype=new q,S.prototype.constructor=S,S.superclass=q.prototype;function S(e,o){arguments.length>0&&this.init(e,o)}S.prototype.init=function(e,o){S.superclass.init.call(this,e,o)},S.prototype.evaluate=function(e){return this.lhs.evaluate(e).lessthan(this.rhs.evaluate(e))},S.prototype.toString=function(){return"("+this.lhs.toString()+" < "+this.rhs.toString()+")"},R.prototype=new q,R.prototype.constructor=R,R.superclass=q.prototype;function R(e,o){arguments.length>0&&this.init(e,o)}R.prototype.init=function(e,o){R.superclass.init.call(this,e,o)},R.prototype.evaluate=function(e){return this.lhs.evaluate(e).greaterthan(this.rhs.evaluate(e))},R.prototype.toString=function(){return"("+this.lhs.toString()+" > "+this.rhs.toString()+")"},j.prototype=new q,j.prototype.constructor=j,j.superclass=q.prototype;function j(e,o){arguments.length>0&&this.init(e,o)}j.prototype.init=function(e,o){j.superclass.init.call(this,e,o)},j.prototype.evaluate=function(e){return this.lhs.evaluate(e).lessthanorequal(this.rhs.evaluate(e))},j.prototype.toString=function(){return"("+this.lhs.toString()+" <= "+this.rhs.toString()+")"},M.prototype=new q,M.prototype.constructor=M,M.superclass=q.prototype;function M(e,o){arguments.length>0&&this.init(e,o)}M.prototype.init=function(e,o){M.superclass.init.call(this,e,o)},M.prototype.evaluate=function(e){return this.lhs.evaluate(e).greaterthanorequal(this.rhs.evaluate(e))},M.prototype.toString=function(){return"("+this.lhs.toString()+" >= "+this.rhs.toString()+")"},J.prototype=new q,J.prototype.constructor=J,J.superclass=q.prototype;function J(e,o){arguments.length>0&&this.init(e,o)}J.prototype.init=function(e,o){J.superclass.init.call(this,e,o)},J.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().plus(this.rhs.evaluate(e).number())},J.prototype.toString=function(){return"("+this.lhs.toString()+" + "+this.rhs.toString()+")"},D.prototype=new q,D.prototype.constructor=D,D.superclass=q.prototype;function D(e,o){arguments.length>0&&this.init(e,o)}D.prototype.init=function(e,o){D.superclass.init.call(this,e,o)},D.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().minus(this.rhs.evaluate(e).number())},D.prototype.toString=function(){return"("+this.lhs.toString()+" - "+this.rhs.toString()+")"},w.prototype=new q,w.prototype.constructor=w,w.superclass=q.prototype;function w(e,o){arguments.length>0&&this.init(e,o)}w.prototype.init=function(e,o){w.superclass.init.call(this,e,o)},w.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().multiply(this.rhs.evaluate(e).number())},w.prototype.toString=function(){return"("+this.lhs.toString()+" * "+this.rhs.toString()+")"},P.prototype=new q,P.prototype.constructor=P,P.superclass=q.prototype;function P(e,o){arguments.length>0&&this.init(e,o)}P.prototype.init=function(e,o){P.superclass.init.call(this,e,o)},P.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().div(this.rhs.evaluate(e).number())},P.prototype.toString=function(){return"("+this.lhs.toString()+" div "+this.rhs.toString()+")"},L.prototype=new q,L.prototype.constructor=L,L.superclass=q.prototype;function L(e,o){arguments.length>0&&this.init(e,o)}L.prototype.init=function(e,o){L.superclass.init.call(this,e,o)},L.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().mod(this.rhs.evaluate(e).number())},L.prototype.toString=function(){return"("+this.lhs.toString()+" mod "+this.rhs.toString()+")"},W.prototype=new q,W.prototype.constructor=W,W.superclass=q.prototype;function W(e,o){arguments.length>0&&this.init(e,o)}W.prototype.init=function(e,o){W.superclass.init.call(this,e,o)},W.prototype.evaluate=function(e){return this.lhs.evaluate(e).nodeset().union(this.rhs.evaluate(e).nodeset())},W.prototype.toString=function(){return B(ae,[this.lhs,this.rhs]).join(" | ")},C.prototype=new I,C.prototype.constructor=C,C.superclass=I.prototype;function C(e,o,f){arguments.length>0&&this.init(e,o,f)}C.prototype.init=function(e,o,f){C.superclass.init.call(this),this.filter=e,this.filterPredicates=o,this.locationPath=f};function ne(e){for(;e&&e.parentNode;)e=e.parentNode;return e}var Ee=function(e,o,f,y){if(e.length===0)return f;var d=o.extend({});return m(function(b,Q){return d.contextSize=b.length,T(function(xe,Ne){return d.contextNode=xe,d.contextPosition=Ne+1,C.predicateMatches(Q,d)},b)},ge(f,y),e)};C.getRoot=function(e,o){var f=o[0];if(f&&f.nodeType===H.DOCUMENT_NODE)return f;if(e.virtualRoot)return e.virtualRoot;if(!f)throw new Error("Context node not found when determining document root.");var y=f.ownerDocument;if(y)return y;for(var d=f;d.parentNode!=null;)d=d.parentNode;return d};var be=function(e){var o=String(e.name);return o==="xmlns"?"":o.substring(0,6)==="xmlns:"?o.substring(6,o.length):null};C.applyStep=function(e,o,f){if(!f)throw new Error("Context node not found when evaluating XPath step: "+e);var y=[];switch(o.contextNode=f,e.axis){case g.ANCESTOR:if(o.contextNode===o.virtualRoot)break;var d;for(o.contextNode.nodeType==H.ATTRIBUTE_NODE?d=C.getOwnerElement(o.contextNode):d=o.contextNode.parentNode;d!=null&&(e.nodeTest.matches(d,o)&&y.push(d),d!==o.virtualRoot);)d=d.parentNode;break;case g.ANCESTORORSELF:for(var d=o.contextNode;d!=null&&(e.nodeTest.matches(d,o)&&y.push(d),d!==o.virtualRoot);d=d.nodeType==H.ATTRIBUTE_NODE?C.getOwnerElement(d):d.parentNode);break;case g.ATTRIBUTE:var b=o.contextNode.attributes;if(b!=null)for(var Q=0;Q<b.length;Q++){var d=b.item(Q);e.nodeTest.matches(d,o)&&y.push(d)}break;case g.CHILD:for(var d=o.contextNode.firstChild;d!=null;d=d.nextSibling)e.nodeTest.matches(d,o)&&y.push(d);break;case g.DESCENDANT:for(var ie=[o.contextNode.firstChild];ie.length>0;)for(var d=ie.pop();d!=null;)e.nodeTest.matches(d,o)&&y.push(d),d.firstChild!=null?(ie.push(d.nextSibling),d=d.firstChild):d=d.nextSibling;break;case g.DESCENDANTORSELF:e.nodeTest.matches(o.contextNode,o)&&y.push(o.contextNode);for(var ie=[o.contextNode.firstChild];ie.length>0;)for(var d=ie.pop();d!=null;)e.nodeTest.matches(d,o)&&y.push(d),d.firstChild!=null?(ie.push(d.nextSibling),d=d.firstChild):d=d.nextSibling;break;case g.FOLLOWING:if(o.contextNode===o.virtualRoot)break;var ie=[];o.contextNode.firstChild!=null?ie.unshift(o.contextNode.firstChild):ie.unshift(o.contextNode.nextSibling);for(var d=o.contextNode.parentNode;d!=null&&d.nodeType!=H.DOCUMENT_NODE&&d!==o.virtualRoot;d=d.parentNode)ie.unshift(d.nextSibling);do for(var d=ie.pop();d!=null;)e.nodeTest.matches(d,o)&&y.push(d),d.firstChild!=null?(ie.push(d.nextSibling),d=d.firstChild):d=d.nextSibling;while(ie.length>0);break;case g.FOLLOWINGSIBLING:if(o.contextNode===o.virtualRoot)break;for(var d=o.contextNode.nextSibling;d!=null;d=d.nextSibling)e.nodeTest.matches(d,o)&&y.push(d);break;case g.NAMESPACE:var xe={};if(o.contextNode.nodeType==H.ELEMENT_NODE){xe.xml=new Ge("xml",null,de.XML_NAMESPACE_URI,o.contextNode);for(var d=o.contextNode;d!=null&&d.nodeType==H.ELEMENT_NODE;d=d.parentNode)for(var Q=0;Q<d.attributes.length;Q++){var Ne=d.attributes.item(Q),Z=be(Ne);Z!=null&&xe[Z]==null&&(xe[Z]=new Ge(Z,Ne,Ne.value,o.contextNode))}for(var Z in xe){var f=xe[Z];e.nodeTest.matches(f,o)&&y.push(f)}}break;case g.PARENT:d=null,o.contextNode!==o.virtualRoot&&(o.contextNode.nodeType==H.ATTRIBUTE_NODE?d=C.getOwnerElement(o.contextNode):d=o.contextNode.parentNode),d!=null&&e.nodeTest.matches(d,o)&&y.push(d);break;case g.PRECEDING:var ie;o.virtualRoot!=null?ie=[o.virtualRoot]:ie=[ne(o.contextNode)];e:for(;ie.length>0;)for(var d=ie.pop();d!=null;){if(d==o.contextNode)break e;e.nodeTest.matches(d,o)&&y.unshift(d),d.firstChild!=null?(ie.push(d.nextSibling),d=d.firstChild):d=d.nextSibling}break;case g.PRECEDINGSIBLING:if(o.contextNode===o.virtualRoot)break;for(var d=o.contextNode.previousSibling;d!=null;d=d.previousSibling)e.nodeTest.matches(d,o)&&y.push(d);break;case g.SELF:e.nodeTest.matches(o.contextNode,o)&&y.push(o.contextNode);break}return y};function Te(e,o,f){return Ee(e.predicates,o,C.applyStep(e,o,f),U(G,e.axis))}function ke(e,o,f){return De(B(Te.bind(null,f,e),o))}C.applySteps=function(e,o,f){return m(ke.bind(null,o),f,e)},C.prototype.applyFilter=function(e,o){if(!this.filter)return{nodes:[e.contextNode]};var f=this.filter.evaluate(e);if(!ue.instance_of(f,te)){if(this.filterPredicates!=null&&this.filterPredicates.length>0||this.locationPath!=null)throw new Error("Path expression filter must evaluate to a nodeset if predicates or location path are used");return{nonNodes:f}}return{nodes:Ee(this.filterPredicates||[],o,f.toUnsortedArray(),!1)}},C.applyLocationPath=function(e,o,f){if(!e)return f;var y=e.absolute?[C.getRoot(o,f)]:f;return C.applySteps(e.steps,o,y)},C.prototype.evaluate=function(e){var o=Ae(new qe,e),f=this.applyFilter(e,o);if("nonNodes"in f)return f.nonNodes;var y=new te;return y.addArray(C.applyLocationPath(this.locationPath,o,f.nodes)),y},C.predicateMatches=function(e,o){var f=e.evaluate(o);return ue.instance_of(f,z)?o.contextPosition===f.numberValue():f.booleanValue()},C.predicateString=function(e){return _("[","]",e.toString())},C.predicatesString=function(e){return le("",B(C.predicateString,e))},C.prototype.toString=function(){if(this.filter!=null){var e=ae(this.filter);return ue.instance_of(this.filter,X)?_("'","'",e):this.filterPredicates!=null&&this.filterPredicates.length?_("(",")",e)+C.predicatesString(this.filterPredicates):this.locationPath!=null?e+(this.locationPath.absolute?"":"/")+ae(this.locationPath):e}return ae(this.locationPath)},C.getOwnerElement=function(e){if(e.ownerElement)return e.ownerElement;try{if(e.selectSingleNode)return e.selectSingleNode("..")}catch{}for(var o=e.nodeType==H.DOCUMENT_NODE?e:e.ownerDocument,f=o.getElementsByTagName("*"),y=0;y<f.length;y++)for(var d=f.item(y),b=d.attributes,Q=0;Q<b.length;Q++){var xe=b.item(Q);if(xe===e)return d}return null},ve.prototype=new Object,ve.prototype.constructor=ve,ve.superclass=Object.prototype;function ve(e,o){arguments.length>0&&this.init(e,o)}ve.prototype.init=function(e,o){this.absolute=e,this.steps=o},ve.prototype.toString=function(){return(this.absolute?"/":"")+B(ae,this.steps).join("/")},g.prototype=new Object,g.prototype.constructor=g,g.superclass=Object.prototype;function g(e,o,f){arguments.length>0&&this.init(e,o,f)}g.prototype.init=function(e,o,f){this.axis=e,this.nodeTest=o,this.predicates=f},g.prototype.toString=function(){return g.STEPNAMES[this.axis]+"::"+this.nodeTest.toString()+C.predicatesString(this.predicates)},g.ANCESTOR=0,g.ANCESTORORSELF=1,g.ATTRIBUTE=2,g.CHILD=3,g.DESCENDANT=4,g.DESCENDANTORSELF=5,g.FOLLOWING=6,g.FOLLOWINGSIBLING=7,g.NAMESPACE=8,g.PARENT=9,g.PRECEDING=10,g.PRECEDINGSIBLING=11,g.SELF=12,g.STEPNAMES=m(function(e,o){return e[o[0]]=o[1],e},{},[[g.ANCESTOR,"ancestor"],[g.ANCESTORORSELF,"ancestor-or-self"],[g.ATTRIBUTE,"attribute"],[g.CHILD,"child"],[g.DESCENDANT,"descendant"],[g.DESCENDANTORSELF,"descendant-or-self"],[g.FOLLOWING,"following"],[g.FOLLOWINGSIBLING,"following-sibling"],[g.NAMESPACE,"namespace"],[g.PARENT,"parent"],[g.PRECEDING,"preceding"],[g.PRECEDINGSIBLING,"preceding-sibling"],[g.SELF,"self"]]);var G=[g.ANCESTOR,g.ANCESTORORSELF,g.PARENT,g.PRECEDING,g.PRECEDINGSIBLING];$.prototype=new Object,$.prototype.constructor=$,$.superclass=Object.prototype;function $(e,o){arguments.length>0&&this.init(e,o)}$.prototype.init=function(e,o){this.type=e,this.value=o},$.prototype.toString=function(){return"<unknown nodetest type>"},$.prototype.matches=function(e,o){console.warn("unknown node test type")},$.NAMETESTANY=0,$.NAMETESTPREFIXANY=1,$.NAMETESTQNAME=2,$.COMMENT=3,$.TEXT=4,$.PI=5,$.NODE=6,$.isNodeType=function(e){return function(o){return U(e,o.nodeType)}},$.makeNodeTestType=function(e,o,f){var y=f||function(){};return y.prototype=new $(e),y.prototype.constructor=y,Ae(y.prototype,o),y},$.makeNodeTypeTest=function(e,o,f){return new($.makeNodeTestType(e,{matches:$.isNodeType(o),toString:V(f)}))},$.hasPrefix=function(e){return e.prefix||(e.nodeName||e.tagName).indexOf(":")!==-1},$.isElementOrAttribute=$.isNodeType([1,2]),$.nameSpaceMatches=function(e,o,f){var y=f.namespaceURI||"";if(!e)return!y||o.allowAnyNamespaceForNoPrefix&&!$.hasPrefix(f);var d=o.namespaceResolver.getNamespace(e,o.expressionContextNode);if(d==null)throw new Error("Cannot resolve QName "+e);return d===y},$.localNameMatches=function(e,o,f){var y=f.localName||f.nodeName;return o.caseInsensitive?e.toLowerCase()===y.toLowerCase():e===y},$.NameTestPrefixAny=$.makeNodeTestType($.NAMETESTPREFIXANY,{matches:function(e,o){return $.isElementOrAttribute(e)&&$.nameSpaceMatches(this.prefix,o,e)},toString:function(){return this.prefix+":*"}},function(o){this.prefix=o}),$.NameTestQName=$.makeNodeTestType($.NAMETESTQNAME,{matches:function(e,o){return $.isNodeType([H.ELEMENT_NODE,H.ATTRIBUTE_NODE,H.NAMESPACE_NODE])(e)&&$.nameSpaceMatches(this.prefix,o,e)&&$.localNameMatches(this.localName,o,e)},toString:function(){return this.name}},function(o){var f=o.split(":");this.name=o,this.prefix=f.length>1?f[0]:null,this.localName=f[f.length>1?1:0]}),$.PITest=$.makeNodeTestType($.PI,{matches:function(e,o){return $.isNodeType([H.PROCESSING_INSTRUCTION_NODE])(e)&&(e.target||e.nodeName)===this.name},toString:function(){return _('processing-instruction("','")',this.name)}},function(e){this.name=e}),$.nameTestAny=$.makeNodeTypeTest($.NAMETESTANY,[H.ELEMENT_NODE,H.ATTRIBUTE_NODE,H.NAMESPACE_NODE],"*"),$.textTest=$.makeNodeTypeTest($.TEXT,[H.TEXT_NODE,H.CDATA_SECTION_NODE],"text()"),$.commentTest=$.makeNodeTypeTest($.COMMENT,[H.COMMENT_NODE],"comment()"),$.nodeTest=$.makeNodeTypeTest($.NODE,[H.ELEMENT_NODE,H.ATTRIBUTE_NODE,H.TEXT_NODE,H.CDATA_SECTION_NODE,H.PROCESSING_INSTRUCTION_NODE,H.COMMENT_NODE,H.DOCUMENT_NODE],"node()"),$.anyPiTest=$.makeNodeTypeTest($.PI,[H.PROCESSING_INSTRUCTION_NODE],"processing-instruction()"),_e.prototype=new I,_e.prototype.constructor=_e,_e.superclass=I.prototype;function _e(e){arguments.length>0&&this.init(e)}_e.prototype.init=function(e){this.variable=e},_e.prototype.toString=function(){return"$"+this.variable},_e.prototype.evaluate=function(e){var o=ue.resolveQName(this.variable,e.namespaceResolver,e.contextNode,!1);if(o[0]==null)throw new Error("Cannot resolve QName "+fn);var f=e.variableResolver.getVariable(o[1],o[0]);if(!f)throw Me.fromMessage("Undeclared variable: "+this.toString());return f},ce.prototype=new I,ce.prototype.constructor=ce,ce.superclass=I.prototype;function ce(e,o){arguments.length>0&&this.init(e,o)}ce.prototype.init=function(e,o){this.functionName=e,this.arguments=o},ce.prototype.toString=function(){for(var e=this.functionName+"(",o=0;o<this.arguments.length;o++)o>0&&(e+=", "),e+=this.arguments[o].toString();return e+")"},ce.prototype.evaluate=function(e){var o=Ie.getFunctionFromContext(this.functionName,e);if(!o)throw new Error("Unknown function "+this.functionName);var f=[e].concat(this.arguments);return o.apply(e.functionResolver.thisArg,f)};var se=new Object;se.equals=function(e,o){return e.equals(o)},se.notequal=function(e,o){return e.notequal(o)},se.lessthan=function(e,o){return e.lessthan(o)},se.greaterthan=function(e,o){return e.greaterthan(o)},se.lessthanorequal=function(e,o){return e.lessthanorequal(o)},se.greaterthanorequal=function(e,o){return e.greaterthanorequal(o)},X.prototype=new I,X.prototype.constructor=X,X.superclass=I.prototype;function X(e){arguments.length>0&&this.init(e)}X.prototype.init=function(e){this.str=String(e)},X.prototype.toString=function(){return this.str},X.prototype.evaluate=function(e){return this},X.prototype.string=function(){return this},X.prototype.number=function(){return new z(this.str)},X.prototype.bool=function(){return new fe(this.str)},X.prototype.nodeset=function(){throw new Error("Cannot convert string to nodeset")},X.prototype.stringValue=function(){return this.str},X.prototype.numberValue=function(){return this.number().numberValue()},X.prototype.booleanValue=function(){return this.bool().booleanValue()},X.prototype.equals=function(e){return ue.instance_of(e,fe)?this.bool().equals(e):ue.instance_of(e,z)?this.number().equals(e):ue.instance_of(e,te)?e.compareWithString(this,se.equals):new fe(this.str==e.str)},X.prototype.notequal=function(e){return ue.instance_of(e,fe)?this.bool().notequal(e):ue.instance_of(e,z)?this.number().notequal(e):ue.instance_of(e,te)?e.compareWithString(this,se.notequal):new fe(this.str!=e.str)},X.prototype.lessthan=function(e){return this.number().lessthan(e)},X.prototype.greaterthan=function(e){return this.number().greaterthan(e)},X.prototype.lessthanorequal=function(e){return this.number().lessthanorequal(e)},X.prototype.greaterthanorequal=function(e){return this.number().greaterthanorequal(e)},z.prototype=new I,z.prototype.constructor=z,z.superclass=I.prototype;function z(e){arguments.length>0&&this.init(e)}z.prototype.init=function(e){this.num=typeof e=="string"?this.parse(e):Number(e)},z.prototype.numberFormat=/^\s*-?[0-9]*\.?[0-9]+\s*$/,z.prototype.parse=function(e){return this.numberFormat.test(e)?parseFloat(e):Number.NaN};function rt(e){for(var o=e.split("e-"),f=o[0].replace(".",""),y=Number(o[1]),d=0;d<y-1;d+=1)f="0"+f;return"0."+f}function lt(e){for(var o=e.split("e"),f=o[0].replace(".",""),y=Number(o[1]),d=y+1-f.length,b=0;b<d;b+=1)f+="0";return f}z.prototype.toString=function(){var e=this.num.toString();return e.indexOf("e-")!==-1?rt(e):e.indexOf("e")!==-1?lt(e):e},z.prototype.evaluate=function(e){return this},z.prototype.string=function(){return new X(this.toString())},z.prototype.number=function(){return this},z.prototype.bool=function(){return new fe(this.num)},z.prototype.nodeset=function(){throw new Error("Cannot convert number to nodeset")},z.prototype.stringValue=function(){return this.string().stringValue()},z.prototype.numberValue=function(){return this.num},z.prototype.booleanValue=function(){return this.bool().booleanValue()},z.prototype.negate=function(){return new z(-this.num)},z.prototype.equals=function(e){return ue.instance_of(e,fe)?this.bool().equals(e):ue.instance_of(e,X)?this.equals(e.number()):ue.instance_of(e,te)?e.compareWithNumber(this,se.equals):new fe(this.num==e.num)},z.prototype.notequal=function(e){return ue.instance_of(e,fe)?this.bool().notequal(e):ue.instance_of(e,X)?this.notequal(e.number()):ue.instance_of(e,te)?e.compareWithNumber(this,se.notequal):new fe(this.num!=e.num)},z.prototype.lessthan=function(e){return ue.instance_of(e,te)?e.compareWithNumber(this,se.greaterthan):ue.instance_of(e,fe)||ue.instance_of(e,X)?this.lessthan(e.number()):new fe(this.num<e.num)},z.prototype.greaterthan=function(e){return ue.instance_of(e,te)?e.compareWithNumber(this,se.lessthan):ue.instance_of(e,fe)||ue.instance_of(e,X)?this.greaterthan(e.number()):new fe(this.num>e.num)},z.prototype.lessthanorequal=function(e){return ue.instance_of(e,te)?e.compareWithNumber(this,se.greaterthanorequal):ue.instance_of(e,fe)||ue.instance_of(e,X)?this.lessthanorequal(e.number()):new fe(this.num<=e.num)},z.prototype.greaterthanorequal=function(e){return ue.instance_of(e,te)?e.compareWithNumber(this,se.lessthanorequal):ue.instance_of(e,fe)||ue.instance_of(e,X)?this.greaterthanorequal(e.number()):new fe(this.num>=e.num)},z.prototype.plus=function(e){return new z(this.num+e.num)},z.prototype.minus=function(e){return new z(this.num-e.num)},z.prototype.multiply=function(e){return new z(this.num*e.num)},z.prototype.div=function(e){return new z(this.num/e.num)},z.prototype.mod=function(e){return new z(this.num%e.num)},fe.prototype=new I,fe.prototype.constructor=fe,fe.superclass=I.prototype;function fe(e){arguments.length>0&&this.init(e)}fe.prototype.init=function(e){this.b=!!e},fe.prototype.toString=function(){return this.b.toString()},fe.prototype.evaluate=function(e){return this},fe.prototype.string=function(){return new X(this.b)},fe.prototype.number=function(){return new z(this.b)},fe.prototype.bool=function(){return this},fe.prototype.nodeset=function(){throw new Error("Cannot convert boolean to nodeset")},fe.prototype.stringValue=function(){return this.string().stringValue()},fe.prototype.numberValue=function(){return this.number().numberValue()},fe.prototype.booleanValue=function(){return this.b},fe.prototype.not=function(){return new fe(!this.b)},fe.prototype.equals=function(e){return ue.instance_of(e,X)||ue.instance_of(e,z)?this.equals(e.bool()):ue.instance_of(e,te)?e.compareWithBoolean(this,se.equals):new fe(this.b==e.b)},fe.prototype.notequal=function(e){return ue.instance_of(e,X)||ue.instance_of(e,z)?this.notequal(e.bool()):ue.instance_of(e,te)?e.compareWithBoolean(this,se.notequal):new fe(this.b!=e.b)},fe.prototype.lessthan=function(e){return this.number().lessthan(e)},fe.prototype.greaterthan=function(e){return this.number().greaterthan(e)},fe.prototype.lessthanorequal=function(e){return this.number().lessthanorequal(e)},fe.prototype.greaterthanorequal=function(e){return this.number().greaterthanorequal(e)},fe.true_=new fe(!0),fe.false_=new fe(!1),Re.prototype=new Object,Re.prototype.constructor=Re,Re.superclass=Object.prototype;function Re(e){this.init(e)}Re.prototype.init=function(e){this.left=null,this.right=null,this.node=e,this.depth=1},Re.prototype.balance=function(){var e=this.left==null?0:this.left.depth,o=this.right==null?0:this.right.depth;if(e>o+1){var f=this.left.left==null?0:this.left.left.depth,y=this.left.right==null?0:this.left.right.depth;f<y&&this.left.rotateRR(),this.rotateLL()}else if(e+1<o){var d=this.right.right==null?0:this.right.right.depth,b=this.right.left==null?0:this.right.left.depth;b>d&&this.right.rotateLL(),this.rotateRR()}},Re.prototype.rotateLL=function(){var e=this.node,o=this.right;this.node=this.left.node,this.right=this.left,this.left=this.left.left,this.right.left=this.right.right,this.right.right=o,this.right.node=e,this.right.updateInNewLocation(),this.updateInNewLocation()},Re.prototype.rotateRR=function(){var e=this.node,o=this.left;this.node=this.right.node,this.left=this.right,this.right=this.right.right,this.left.right=this.left.left,this.left.left=o,this.left.node=e,this.left.updateInNewLocation(),this.updateInNewLocation()},Re.prototype.updateInNewLocation=function(){this.getDepthFromChildren()},Re.prototype.getDepthFromChildren=function(){this.depth=this.node==null?0:1,this.left!=null&&(this.depth=this.left.depth+1),this.right!=null&&this.depth<=this.right.depth&&(this.depth=this.right.depth+1)};function mt(e,o){if(e===o)return 0;if(e.compareDocumentPosition){var f=e.compareDocumentPosition(o);return f&1||f&10?1:f&20?-1:0}for(var y=0,d=0,b=e;b!=null;b=b.parentNode||b.ownerElement)y++;for(var Q=o;Q!=null;Q=Q.parentNode||Q.ownerElement)d++;if(y>d){for(;y>d;)e=e.parentNode||e.ownerElement,y--;if(e===o)return 1}else if(d>y){for(;d>y;)o=o.parentNode||o.ownerElement,d--;if(e===o)return-1}for(var xe=e.parentNode||e.ownerElement,Ne=o.parentNode||o.ownerElement;xe!==Ne;)e=xe,o=Ne,xe=e.parentNode||e.ownerElement,Ne=o.parentNode||o.ownerElement;var Z=gt(e),ie=gt(o);if(Z&&!ie)return-1;if(!Z&&ie)return 1;if(e.isXPathNamespace){if(e.nodeValue===de.XML_NAMESPACE_URI||!o.isXPathNamespace)return-1;if(o.nodeValue===de.XML_NAMESPACE_URI)return 1}else if(o.isXPathNamespace)return 1;if(xe)for(var Pe=Z?xe.attributes:xe.childNodes,je=Pe.length,Se=e.baseNode||e,ze=o.baseNode||o,He=0;He<je;He+=1){var nt=Pe[He];if(nt===Se)return-1;if(nt===ze)return 1}throw new Error("Unexpected: could not determine node order")}Re.prototype.add=function(e){if(e===this.node)return!1;var o=mt(e,this.node),f=!1;return o==-1?this.left==null?(this.left=new Re(e),f=!0):(f=this.left.add(e),f&&this.balance()):o==1&&(this.right==null?(this.right=new Re(e),f=!0):(f=this.right.add(e),f&&this.balance())),f&&this.getDepthFromChildren(),f},te.prototype=new I,te.prototype.constructor=te,te.superclass=I.prototype;function te(){this.init()}te.prototype.init=function(){this.tree=null,this.nodes=[],this.size=0},te.prototype.toString=function(){var e=this.first();return e==null?"":this.stringForNode(e)},te.prototype.evaluate=function(e){return this},te.prototype.string=function(){return new X(this.toString())},te.prototype.stringValue=function(){return this.toString()},te.prototype.number=function(){return new z(this.string())},te.prototype.numberValue=function(){return Number(this.string())},te.prototype.bool=function(){return new fe(this.booleanValue())},te.prototype.booleanValue=function(){return!!this.size},te.prototype.nodeset=function(){return this},te.prototype.stringForNode=function(e){return e.nodeType==H.DOCUMENT_NODE||e.nodeType==H.ELEMENT_NODE||e.nodeType===H.DOCUMENT_FRAGMENT_NODE?this.stringForContainerNode(e):e.nodeType===H.ATTRIBUTE_NODE?e.value||e.nodeValue:e.isNamespaceNode?e.namespace:e.nodeValue},te.prototype.stringForContainerNode=function(e){for(var o="",f=e.firstChild;f!=null;f=f.nextSibling){var y=f.nodeType;(y===1||y===3||y===4||y===9||y===11)&&(o+=this.stringForNode(f))}return o},te.prototype.buildTree=function(){if(!this.tree&&this.nodes.length){this.tree=new Re(this.nodes[0]);for(var e=1;e<this.nodes.length;e+=1)this.tree.add(this.nodes[e])}return this.tree},te.prototype.first=function(){var e=this.buildTree();if(e==null)return null;for(;e.left!=null;)e=e.left;return e.node},te.prototype.add=function(e){for(var o=0;o<this.nodes.length;o+=1)if(e===this.nodes[o])return;this.tree=null,this.nodes.push(e),this.size+=1},te.prototype.addArray=function(e){var o=this;h(function(f){o.add(f)},e)},te.prototype.toArray=function(){var e=[];return this.toArrayRec(this.buildTree(),e),e},te.prototype.toArrayRec=function(e,o){e!=null&&(this.toArrayRec(e.left,o),o.push(e.node),this.toArrayRec(e.right,o))},te.prototype.toUnsortedArray=function(){return this.nodes.slice()},te.prototype.compareWithString=function(e,o){for(var f=this.toUnsortedArray(),y=0;y<f.length;y++){var d=f[y],b=new X(this.stringForNode(d)),Q=o(b,e);if(Q.booleanValue())return Q}return new fe(!1)},te.prototype.compareWithNumber=function(e,o){for(var f=this.toUnsortedArray(),y=0;y<f.length;y++){var d=f[y],b=new z(this.stringForNode(d)),Q=o(b,e);if(Q.booleanValue())return Q}return new fe(!1)},te.prototype.compareWithBoolean=function(e,o){return o(this.bool(),e)},te.prototype.compareWithNodeSet=function(e,o){for(var f=this.toUnsortedArray(),y=function(xe,Ne){return o(Ne,xe)},d=0;d<f.length;d++){var b=new X(this.stringForNode(f[d])),Q=e.compareWithString(b,y);if(Q.booleanValue())return Q}return new fe(!1)},te.compareWith=N(function(e,o){return ue.instance_of(o,X)?this.compareWithString(o,e):ue.instance_of(o,z)?this.compareWithNumber(o,e):ue.instance_of(o,fe)?this.compareWithBoolean(o,e):this.compareWithNodeSet(o,e)}),te.prototype.equals=te.compareWith(se.equals),te.prototype.notequal=te.compareWith(se.notequal),te.prototype.lessthan=te.compareWith(se.lessthan),te.prototype.greaterthan=te.compareWith(se.greaterthan),te.prototype.lessthanorequal=te.compareWith(se.lessthanorequal),te.prototype.greaterthanorequal=te.compareWith(se.greaterthanorequal),te.prototype.union=function(e){var o=new te;return o.addArray(this.toUnsortedArray()),o.addArray(e.toUnsortedArray()),o},Ge.prototype=new Object,Ge.prototype.constructor=Ge,Ge.superclass=Object.prototype;function Ge(e,o,f,y){this.isXPathNamespace=!0,this.baseNode=o,this.ownerDocument=y.ownerDocument,this.nodeName=e,this.prefix=e,this.localName=e,this.namespaceURI=null,this.nodeValue=f,this.ownerElement=y,this.nodeType=H.NAMESPACE_NODE}Ge.prototype.toString=function(){return'{ "'+this.prefix+'", "'+this.namespaceURI+'" }'},qe.prototype=new Object,qe.prototype.constructor=qe,qe.superclass=Object.prototype;function qe(e,o,f){this.variableResolver=e??new Xe,this.namespaceResolver=o??new $e,this.functionResolver=f??new Ie}qe.prototype.extend=function(e){return Ae(new qe,this,e)},Xe.prototype=new Object,Xe.prototype.constructor=Xe,Xe.superclass=Object.prototype;function Xe(){}Xe.prototype.getVariable=function(e,o){return null},Ie.prototype=new Object,Ie.prototype.constructor=Ie,Ie.superclass=Object.prototype;function Ie(e){this.thisArg=e??me,this.functions=new Object,this.addStandardFunctions()}Ie.prototype.addStandardFunctions=function(){this.functions["{}last"]=me.last,this.functions["{}position"]=me.position,this.functions["{}count"]=me.count,this.functions["{}id"]=me.id,this.functions["{}local-name"]=me.localName,this.functions["{}namespace-uri"]=me.namespaceURI,this.functions["{}name"]=me.name,this.functions["{}string"]=me.string,this.functions["{}concat"]=me.concat,this.functions["{}starts-with"]=me.startsWith,this.functions["{}contains"]=me.contains,this.functions["{}substring-before"]=me.substringBefore,this.functions["{}substring-after"]=me.substringAfter,this.functions["{}substring"]=me.substring,this.functions["{}string-length"]=me.stringLength,this.functions["{}normalize-space"]=me.normalizeSpace,this.functions["{}translate"]=me.translate,this.functions["{}boolean"]=me.boolean_,this.functions["{}not"]=me.not,this.functions["{}true"]=me.true_,this.functions["{}false"]=me.false_,this.functions["{}lang"]=me.lang,this.functions["{}number"]=me.number,this.functions["{}sum"]=me.sum,this.functions["{}floor"]=me.floor,this.functions["{}ceiling"]=me.ceiling,this.functions["{}round"]=me.round},Ie.prototype.addFunction=function(e,o,f){this.functions["{"+e+"}"+o]=f},Ie.getFunctionFromContext=function(e,o){var f=ue.resolveQName(e,o.namespaceResolver,o.contextNode,!1);if(f[0]===null)throw new Error("Cannot resolve QName "+name);return o.functionResolver.getFunction(f[1],f[0])},Ie.prototype.getFunction=function(e,o){return this.functions["{"+o+"}"+e]},$e.prototype=new Object,$e.prototype.constructor=$e,$e.superclass=Object.prototype;function $e(){}$e.prototype.getNamespace=function(e,o){if(e=="xml")return de.XML_NAMESPACE_URI;if(e=="xmlns")return de.XMLNS_NAMESPACE_URI;for(o.nodeType==H.DOCUMENT_NODE?o=o.documentElement:o.nodeType==H.ATTRIBUTE_NODE?o=C.getOwnerElement(o):o.nodeType!=H.ELEMENT_NODE&&(o=o.parentNode);o!=null&&o.nodeType==H.ELEMENT_NODE;){for(var f=o.attributes,y=0;y<f.length;y++){var d=f.item(y),b=d.name||d.nodeName;if(b==="xmlns"&&e===""||b==="xmlns:"+e)return String(d.value||d.nodeValue)}o=o.parentNode}return null};var me=new Object;me.last=function(e){if(arguments.length!=1)throw new Error("Function last expects ()");return new z(e.contextSize)},me.position=function(e){if(arguments.length!=1)throw new Error("Function position expects ()");return new z(e.contextPosition)},me.count=function(){var e=arguments[0],o;if(arguments.length!=2||!ue.instance_of(o=arguments[1].evaluate(e),te))throw new Error("Function count expects (node-set)");return new z(o.size)},me.id=function(){var e=arguments[0],o;if(arguments.length!=2)throw new Error("Function id expects (object)");o=arguments[1].evaluate(e),ue.instance_of(o,te)?o=o.toArray().join(" "):o=o.stringValue();for(var f=o.split(/[\x0d\x0a\x09\x20]+/),y=new te,d=e.contextNode.nodeType==H.DOCUMENT_NODE?e.contextNode:e.contextNode.ownerDocument,b=0;b<f.length;b++){var Q;d.getElementById?Q=d.getElementById(f[b]):Q=ue.getElementById(d,f[b]),Q!=null&&y.add(Q)}return y},me.localName=function(e,o){var f;if(arguments.length==1)f=e.contextNode;else if(arguments.length==2)f=o.evaluate(e).first();else throw new Error("Function local-name expects (node-set?)");return f==null?new X(""):new X(f.localName||f.baseName||f.target||f.nodeName||"")},me.namespaceURI=function(){var e=arguments[0],o;if(arguments.length==1)o=e.contextNode;else if(arguments.length==2)o=arguments[1].evaluate(e).first();else throw new Error("Function namespace-uri expects (node-set?)");return o==null?new X(""):new X(o.namespaceURI||"")},me.name=function(){var e=arguments[0],o;if(arguments.length==1)o=e.contextNode;else if(arguments.length==2)o=arguments[1].evaluate(e).first();else throw new Error("Function name expects (node-set?)");return o==null?new X(""):o.nodeType==H.ELEMENT_NODE?new X(o.nodeName):o.nodeType==H.ATTRIBUTE_NODE?new X(o.name||o.nodeName):o.nodeType===H.PROCESSING_INSTRUCTION_NODE?new X(o.target||o.nodeName):o.localName==null?new X(""):new X(o.localName)},me.string=function(){var e=arguments[0];if(arguments.length==1)return new X(te.prototype.stringForNode(e.contextNode));if(arguments.length==2)return arguments[1].evaluate(e).string();throw new Error("Function string expects (object?)")},me.concat=function(e){if(arguments.length<3)throw new Error("Function concat expects (string, string[, string]*)");for(var o="",f=1;f<arguments.length;f++)o+=arguments[f].evaluate(e).stringValue();return new X(o)},me.startsWith=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function startsWith expects (string, string)");var o=arguments[1].evaluate(e).stringValue(),f=arguments[2].evaluate(e).stringValue();return new fe(o.substring(0,f.length)==f)},me.contains=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function contains expects (string, string)");var o=arguments[1].evaluate(e).stringValue(),f=arguments[2].evaluate(e).stringValue();return new fe(o.indexOf(f)!==-1)},me.substringBefore=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function substring-before expects (string, string)");var o=arguments[1].evaluate(e).stringValue(),f=arguments[2].evaluate(e).stringValue();return new X(o.substring(0,o.indexOf(f)))},me.substringAfter=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function substring-after expects (string, string)");var o=arguments[1].evaluate(e).stringValue(),f=arguments[2].evaluate(e).stringValue();if(f.length==0)return new X(o);var y=o.indexOf(f);return y==-1?new X(""):new X(o.substring(y+f.length))},me.substring=function(){var e=arguments[0];if(!(arguments.length==3||arguments.length==4))throw new Error("Function substring expects (string, number, number?)");var o=arguments[1].evaluate(e).stringValue(),f=Math.round(arguments[2].evaluate(e).numberValue())-1,y=arguments.length==4?f+Math.round(arguments[3].evaluate(e).numberValue()):void 0;return new X(o.substring(f,y))},me.stringLength=function(){var e=arguments[0],o;if(arguments.length==1)o=te.prototype.stringForNode(e.contextNode);else if(arguments.length==2)o=arguments[1].evaluate(e).stringValue();else throw new Error("Function string-length expects (string?)");return new z(o.length)},me.normalizeSpace=function(){var e=arguments[0],o;if(arguments.length==1)o=te.prototype.stringForNode(e.contextNode);else if(arguments.length==2)o=arguments[1].evaluate(e).stringValue();else throw new Error("Function normalize-space expects (string?)");for(var f=0,y=o.length-1;ue.isSpace(o.charCodeAt(y));)y--;for(var d="";f<=y&&ue.isSpace(o.charCodeAt(f));)f++;for(;f<=y;)if(ue.isSpace(o.charCodeAt(f)))for(d+=" ";f<=y&&ue.isSpace(o.charCodeAt(f));)f++;else d+=o.charAt(f),f++;return new X(d)},me.translate=function(e,o,f,y){if(arguments.length!=4)throw new Error("Function translate expects (string, string, string)");var d=o.evaluate(e).stringValue(),b=f.evaluate(e).stringValue(),Q=y.evaluate(e).stringValue(),xe=m(function(Z,ie,Pe){return ie in Z||(Z[ie]=Pe>Q.length?"":Q[Pe]),Z},{},b),Ne=le("",B(function(Z){return Z in xe?xe[Z]:Z},d));return new X(Ne)},me.boolean_=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function boolean expects (object)");return arguments[1].evaluate(e).bool()},me.not=function(e,o){if(arguments.length!=2)throw new Error("Function not expects (object)");return o.evaluate(e).bool().not()},me.true_=function(){if(arguments.length!=1)throw new Error("Function true expects ()");return fe.true_},me.false_=function(){if(arguments.length!=1)throw new Error("Function false expects ()");return fe.false_},me.lang=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function lang expects (string)");for(var o,f=e.contextNode;f!=null&&f.nodeType!=H.DOCUMENT_NODE;f=f.parentNode){var y=f.getAttributeNS(de.XML_NAMESPACE_URI,"lang");if(y!=null){o=String(y);break}}if(o==null)return fe.false_;var d=arguments[1].evaluate(e).stringValue();return new fe(o.substring(0,d.length)==d&&(o.length==d.length||o.charAt(d.length)=="-"))},me.number=function(){var e=arguments[0];if(!(arguments.length==1||arguments.length==2))throw new Error("Function number expects (object?)");return arguments.length==1?new z(te.prototype.stringForNode(e.contextNode)):arguments[1].evaluate(e).number()},me.sum=function(){var e=arguments[0],o;if(arguments.length!=2||!ue.instance_of(o=arguments[1].evaluate(e),te))throw new Error("Function sum expects (node-set)");o=o.toUnsortedArray();for(var f=0,y=0;y<o.length;y++)f+=new z(te.prototype.stringForNode(o[y])).numberValue();return new z(f)},me.floor=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function floor expects (number)");return new z(Math.floor(arguments[1].evaluate(e).numberValue()))},me.ceiling=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function ceiling expects (number)");return new z(Math.ceil(arguments[1].evaluate(e).numberValue()))},me.round=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function round expects (number)");return new z(Math.round(arguments[1].evaluate(e).numberValue()))};var ue=new Object,gt=function(e){return e&&(e.nodeType===H.ATTRIBUTE_NODE||e.ownerElement||e.isXPathNamespace)};ue.splitQName=function(e){var o=e.indexOf(":");return o==-1?[null,e]:[e.substring(0,o),e.substring(o+1)]},ue.resolveQName=function(e,o,f,y){var d=ue.splitQName(e);return d[0]!=null?d[0]=o.getNamespace(d[0],f):y?(d[0]=o.getNamespace("",f),d[0]==null&&(d[0]="")):d[0]="",d},ue.isSpace=function(e){return e==9||e==13||e==10||e==32},ue.isLetter=function(e){return e>=65&&e<=90||e>=97&&e<=122||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=255||e>=256&&e<=305||e>=308&&e<=318||e>=321&&e<=328||e>=330&&e<=382||e>=384&&e<=451||e>=461&&e<=496||e>=500&&e<=501||e>=506&&e<=535||e>=592&&e<=680||e>=699&&e<=705||e==902||e>=904&&e<=906||e==908||e>=910&&e<=929||e>=931&&e<=974||e>=976&&e<=982||e==986||e==988||e==990||e==992||e>=994&&e<=1011||e>=1025&&e<=1036||e>=1038&&e<=1103||e>=1105&&e<=1116||e>=1118&&e<=1153||e>=1168&&e<=1220||e>=1223&&e<=1224||e>=1227&&e<=1228||e>=1232&&e<=1259||e>=1262&&e<=1269||e>=1272&&e<=1273||e>=1329&&e<=1366||e==1369||e>=1377&&e<=1414||e>=1488&&e<=1514||e>=1520&&e<=1522||e>=1569&&e<=1594||e>=1601&&e<=1610||e>=1649&&e<=1719||e>=1722&&e<=1726||e>=1728&&e<=1742||e>=1744&&e<=1747||e==1749||e>=1765&&e<=1766||e>=2309&&e<=2361||e==2365||e>=2392&&e<=2401||e>=2437&&e<=2444||e>=2447&&e<=2448||e>=2451&&e<=2472||e>=2474&&e<=2480||e==2482||e>=2486&&e<=2489||e>=2524&&e<=2525||e>=2527&&e<=2529||e>=2544&&e<=2545||e>=2565&&e<=2570||e>=2575&&e<=2576||e>=2579&&e<=2600||e>=2602&&e<=2608||e>=2610&&e<=2611||e>=2613&&e<=2614||e>=2616&&e<=2617||e>=2649&&e<=2652||e==2654||e>=2674&&e<=2676||e>=2693&&e<=2699||e==2701||e>=2703&&e<=2705||e>=2707&&e<=2728||e>=2730&&e<=2736||e>=2738&&e<=2739||e>=2741&&e<=2745||e==2749||e==2784||e>=2821&&e<=2828||e>=2831&&e<=2832||e>=2835&&e<=2856||e>=2858&&e<=2864||e>=2866&&e<=2867||e>=2870&&e<=2873||e==2877||e>=2908&&e<=2909||e>=2911&&e<=2913||e>=2949&&e<=2954||e>=2958&&e<=2960||e>=2962&&e<=2965||e>=2969&&e<=2970||e==2972||e>=2974&&e<=2975||e>=2979&&e<=2980||e>=2984&&e<=2986||e>=2990&&e<=2997||e>=2999&&e<=3001||e>=3077&&e<=3084||e>=3086&&e<=3088||e>=3090&&e<=3112||e>=3114&&e<=3123||e>=3125&&e<=3129||e>=3168&&e<=3169||e>=3205&&e<=3212||e>=3214&&e<=3216||e>=3218&&e<=3240||e>=3242&&e<=3251||e>=3253&&e<=3257||e==3294||e>=3296&&e<=3297||e>=3333&&e<=3340||e>=3342&&e<=3344||e>=3346&&e<=3368||e>=3370&&e<=3385||e>=3424&&e<=3425||e>=3585&&e<=3630||e==3632||e>=3634&&e<=3635||e>=3648&&e<=3653||e>=3713&&e<=3714||e==3716||e>=3719&&e<=3720||e==3722||e==3725||e>=3732&&e<=3735||e>=3737&&e<=3743||e>=3745&&e<=3747||e==3749||e==3751||e>=3754&&e<=3755||e>=3757&&e<=3758||e==3760||e>=3762&&e<=3763||e==3773||e>=3776&&e<=3780||e>=3904&&e<=3911||e>=3913&&e<=3945||e>=4256&&e<=4293||e>=4304&&e<=4342||e==4352||e>=4354&&e<=4355||e>=4357&&e<=4359||e==4361||e>=4363&&e<=4364||e>=4366&&e<=4370||e==4412||e==4414||e==4416||e==4428||e==4430||e==4432||e>=4436&&e<=4437||e==4441||e>=4447&&e<=4449||e==4451||e==4453||e==4455||e==4457||e>=4461&&e<=4462||e>=4466&&e<=4467||e==4469||e==4510||e==4520||e==4523||e>=4526&&e<=4527||e>=4535&&e<=4536||e==4538||e>=4540&&e<=4546||e==4587||e==4592||e==4601||e>=7680&&e<=7835||e>=7840&&e<=7929||e>=7936&&e<=7957||e>=7960&&e<=7965||e>=7968&&e<=8005||e>=8008&&e<=8013||e>=8016&&e<=8023||e==8025||e==8027||e==8029||e>=8031&&e<=8061||e>=8064&&e<=8116||e>=8118&&e<=8124||e==8126||e>=8130&&e<=8132||e>=8134&&e<=8140||e>=8144&&e<=8147||e>=8150&&e<=8155||e>=8160&&e<=8172||e>=8178&&e<=8180||e>=8182&&e<=8188||e==8486||e>=8490&&e<=8491||e==8494||e>=8576&&e<=8578||e>=12353&&e<=12436||e>=12449&&e<=12538||e>=12549&&e<=12588||e>=44032&&e<=55203||e>=19968&&e<=40869||e==12295||e>=12321&&e<=12329},ue.isNCNameChar=function(e){return e>=48&&e<=57||e>=1632&&e<=1641||e>=1776&&e<=1785||e>=2406&&e<=2415||e>=2534&&e<=2543||e>=2662&&e<=2671||e>=2790&&e<=2799||e>=2918&&e<=2927||e>=3047&&e<=3055||e>=3174&&e<=3183||e>=3302&&e<=3311||e>=3430&&e<=3439||e>=3664&&e<=3673||e>=3792&&e<=3801||e>=3872&&e<=3881||e==46||e==45||e==95||ue.isLetter(e)||e>=768&&e<=837||e>=864&&e<=865||e>=1155&&e<=1158||e>=1425&&e<=1441||e>=1443&&e<=1465||e>=1467&&e<=1469||e==1471||e>=1473&&e<=1474||e==1476||e>=1611&&e<=1618||e==1648||e>=1750&&e<=1756||e>=1757&&e<=1759||e>=1760&&e<=1764||e>=1767&&e<=1768||e>=1770&&e<=1773||e>=2305&&e<=2307||e==2364||e>=2366&&e<=2380||e==2381||e>=2385&&e<=2388||e>=2402&&e<=2403||e>=2433&&e<=2435||e==2492||e==2494||e==2495||e>=2496&&e<=2500||e>=2503&&e<=2504||e>=2507&&e<=2509||e==2519||e>=2530&&e<=2531||e==2562||e==2620||e==2622||e==2623||e>=2624&&e<=2626||e>=2631&&e<=2632||e>=2635&&e<=2637||e>=2672&&e<=2673||e>=2689&&e<=2691||e==2748||e>=2750&&e<=2757||e>=2759&&e<=2761||e>=2763&&e<=2765||e>=2817&&e<=2819||e==2876||e>=2878&&e<=2883||e>=2887&&e<=2888||e>=2891&&e<=2893||e>=2902&&e<=2903||e>=2946&&e<=2947||e>=3006&&e<=3010||e>=3014&&e<=3016||e>=3018&&e<=3021||e==3031||e>=3073&&e<=3075||e>=3134&&e<=3140||e>=3142&&e<=3144||e>=3146&&e<=3149||e>=3157&&e<=3158||e>=3202&&e<=3203||e>=3262&&e<=3268||e>=3270&&e<=3272||e>=3274&&e<=3277||e>=3285&&e<=3286||e>=3330&&e<=3331||e>=3390&&e<=3395||e>=3398&&e<=3400||e>=3402&&e<=3405||e==3415||e==3633||e>=3636&&e<=3642||e>=3655&&e<=3662||e==3761||e>=3764&&e<=3769||e>=3771&&e<=3772||e>=3784&&e<=3789||e>=3864&&e<=3865||e==3893||e==3895||e==3897||e==3902||e==3903||e>=3953&&e<=3972||e>=3974&&e<=3979||e>=3984&&e<=3989||e==3991||e>=3993&&e<=4013||e>=4017&&e<=4023||e==4025||e>=8400&&e<=8412||e==8417||e>=12330&&e<=12335||e==12441||e==12442||e==183||e==720||e==721||e==903||e==1600||e==3654||e==3782||e==12293||e>=12337&&e<=12341||e>=12445&&e<=12446||e>=12540&&e<=12542},ue.coalesceText=function(e){for(var o=e.firstChild;o!=null;o=o.nextSibling)if(o.nodeType==H.TEXT_NODE||o.nodeType==H.CDATA_SECTION_NODE){var f=o.nodeValue,y=o;for(o=o.nextSibling;o!=null&&(o.nodeType==H.TEXT_NODE||o.nodeType==H.CDATA_SECTION_NODE);){f+=o.nodeValue;var d=o;o=o.nextSibling,d.parentNode.removeChild(d)}if(y.nodeType==H.CDATA_SECTION_NODE){var b=y.parentNode;if(y.nextSibling==null)b.removeChild(y),b.appendChild(b.ownerDocument.createTextNode(f));else{var Q=y.nextSibling;b.removeChild(y),b.insertBefore(b.ownerDocument.createTextNode(f),Q)}}else y.nodeValue=f;if(o==null)break}else o.nodeType==H.ELEMENT_NODE&&ue.coalesceText(o)},ue.instance_of=function(e,o){for(;e!=null;){if(e.constructor===o)return!0;if(e===Object)return!1;e=e.constructor.superclass}return!1},ue.getElementById=function(e,o){if(e.nodeType==H.ELEMENT_NODE&&(e.getAttribute("id")==o||e.getAttributeNS(null,"id")==o))return e;for(var f=e.firstChild;f!=null;f=f.nextSibling){var y=ue.getElementById(f,o);if(y!=null)return y}return null};var Me=function(){function e(f,y){var d=y?": "+y.toString():"";switch(f){case o.INVALID_EXPRESSION_ERR:return"Invalid expression"+d;case o.TYPE_ERR:return"Type error"+d}return null}function o(f,y,d){var b=Error.call(this,e(f,y)||d);return b.code=f,b.exception=y,b}return o.prototype=Object.create(Error.prototype),o.prototype.constructor=o,o.superclass=Error,o.prototype.toString=function(){return this.message},o.fromMessage=function(f,y){return new o(null,y,f)},o.INVALID_EXPRESSION_ERR=51,o.TYPE_ERR=52,o}();Fe.prototype={},Fe.prototype.constructor=Fe,Fe.superclass=Object.prototype;function Fe(e,o,f){this.xpath=f.parse(e),this.context=new qe,this.context.namespaceResolver=new Je(o)}Fe.getOwnerDocument=function(e){return e.nodeType===H.DOCUMENT_NODE?e:e.ownerDocument},Fe.detectHtmlDom=function(e){if(!e)return!1;var o=Fe.getOwnerDocument(e);try{return o.implementation.hasFeature("HTML","2.0")}catch{return!0}},Fe.prototype.evaluate=function(e,o,f){this.context.expressionContextNode=e,this.context.caseInsensitive=Fe.detectHtmlDom(e);var y=this.xpath.evaluate(this.context);return new ye(y,o)},Je.prototype={},Je.prototype.constructor=Je,Je.superclass=Object.prototype;function Je(e){this.xpathNSResolver=e}Je.prototype.getNamespace=function(e,o){return this.xpathNSResolver==null?null:this.xpathNSResolver.lookupNamespaceURI(e)},Ke.prototype={},Ke.prototype.constructor=Ke,Ke.superclass=Object.prototype;function Ke(e){this.node=e,this.namespaceResolver=new $e}Ke.prototype.lookupNamespaceURI=function(e){return this.namespaceResolver.getNamespace(e,this.node)},ye.prototype={},ye.prototype.constructor=ye,ye.superclass=Object.prototype;function ye(e,o){switch(o==ye.ANY_TYPE&&(e.constructor===X?o=ye.STRING_TYPE:e.constructor===z?o=ye.NUMBER_TYPE:e.constructor===fe?o=ye.BOOLEAN_TYPE:e.constructor===te&&(o=ye.UNORDERED_NODE_ITERATOR_TYPE)),this.resultType=o,o){case ye.NUMBER_TYPE:this.numberValue=e.numberValue();return;case ye.STRING_TYPE:this.stringValue=e.stringValue();return;case ye.BOOLEAN_TYPE:this.booleanValue=e.booleanValue();return;case ye.ANY_UNORDERED_NODE_TYPE:case ye.FIRST_ORDERED_NODE_TYPE:if(e.constructor===te){this.singleNodeValue=e.first();return}break;case ye.UNORDERED_NODE_ITERATOR_TYPE:case ye.ORDERED_NODE_ITERATOR_TYPE:if(e.constructor===te){this.invalidIteratorState=!1,this.nodes=e.toArray(),this.iteratorIndex=0;return}break;case ye.UNORDERED_NODE_SNAPSHOT_TYPE:case ye.ORDERED_NODE_SNAPSHOT_TYPE:if(e.constructor===te){this.nodes=e.toArray(),this.snapshotLength=this.nodes.length;return}break}throw new Me(Me.TYPE_ERR)}ye.prototype.iterateNext=function(){if(this.resultType!=ye.UNORDERED_NODE_ITERATOR_TYPE&&this.resultType!=ye.ORDERED_NODE_ITERATOR_TYPE)throw new Me(Me.TYPE_ERR);return this.nodes[this.iteratorIndex++]},ye.prototype.snapshotItem=function(e){if(this.resultType!=ye.UNORDERED_NODE_SNAPSHOT_TYPE&&this.resultType!=ye.ORDERED_NODE_SNAPSHOT_TYPE)throw new Me(Me.TYPE_ERR);return this.nodes[e]},ye.ANY_TYPE=0,ye.NUMBER_TYPE=1,ye.STRING_TYPE=2,ye.BOOLEAN_TYPE=3,ye.UNORDERED_NODE_ITERATOR_TYPE=4,ye.ORDERED_NODE_ITERATOR_TYPE=5,ye.UNORDERED_NODE_SNAPSHOT_TYPE=6,ye.ORDERED_NODE_SNAPSHOT_TYPE=7,ye.ANY_UNORDERED_NODE_TYPE=8,ye.FIRST_ORDERED_NODE_TYPE=9;function a(e,o){e.createExpression=function(f,y){try{return new Fe(f,y,o)}catch(d){throw new Me(Me.INVALID_EXPRESSION_ERR,d)}},e.createNSResolver=function(f){return new Ke(f)},e.evaluate=function(f,y,d,b,Q){if(b<0||b>9)throw{code:0,toString:function(){return"Request type not supported"}};return e.createExpression(f,d,o).evaluate(y,b,Q)}}try{var c=!0;try{document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("XPath",null)&&(c=!1)}catch{}c&&a(document,new A)}catch{}a(r,new A),function(){var e=new A,o=new $e,f=new Ie,y=new Xe;function d(Y){return{getNamespace:function(Ce,Ue){var ot=Y(Ce,Ue);return ot||o.getNamespace(Ce,Ue)}}}function b(Y){return d(Y.getNamespace.bind(Y))}function Q(Y){return d(function(Ce){return Y[Ce]})}function xe(Y){return Y&&typeof Y.getNamespace=="function"?b(Y):typeof Y=="function"?d(Y):typeof Y=="object"?Q(Y):o}function Ne(Y){if(Y===null||typeof Y>"u"||Y instanceof X||Y instanceof fe||Y instanceof z||Y instanceof te)return Y;switch(typeof Y){case"string":return new X(Y);case"boolean":return new fe(Y);case"number":return new z(Y)}var Ce=new te;return Ce.addArray([].concat(Y)),Ce}function Z(Y){return function(Ce){var Ue=Array.prototype.slice.call(arguments,1).map(function(cs){return cs.evaluate(Ce)}),ot=Y.apply(this,[].concat(Ce,Ue));return Ne(ot)}}function ie(Y){return{getFunction:function(Ce,Ue){var ot=Y(Ce,Ue);return ot?Z(ot):f.getFunction(Ce,Ue)}}}function Pe(Y){return ie(Y.getFunction.bind(Y))}function je(Y){return ie(function(Ce){return Y[Ce]})}function Se(Y){return Y&&typeof Y.getFunction=="function"?Pe(Y):typeof Y=="function"?ie(Y):typeof Y=="object"?je(Y):f}function ze(Y){return{getVariable:function(Ce,Ue){var ot=Y(Ce,Ue);return Ne(ot)}}}function He(Y){if(Y){if(typeof Y.getVariable=="function")return ze(Y.getVariable.bind(Y));if(typeof Y=="function")return ze(Y);if(typeof Y=="object")return ze(function(Ce){return Y[Ce]})}return y}function nt(Y,Ce,Ue){Y in Ue&&(Ce[Y]=Ue[Y])}function is(Y){var Ce=new qe;return Y?(Ce.namespaceResolver=xe(Y.namespaces),Ce.functionResolver=Se(Y.functions),Ce.variableResolver=He(Y.variables),Ce.expressionContextNode=Y.node,nt("allowAnyNamespaceForNoPrefix",Ce,Y),nt("isHtml",Ce,Y)):Ce.namespaceResolver=o,Ce}function us(Y,Ce){var Ue=is(Ce);return Y.evaluate(Ue)}var as={evaluate:function(Y){return us(this.expression,Y)},evaluateNumber:function(Y){return this.evaluate(Y).numberValue()},evaluateString:function(Y){return this.evaluate(Y).stringValue()},evaluateBoolean:function(Y){return this.evaluate(Y).booleanValue()},evaluateNodeSet:function(Y){return this.evaluate(Y).nodeset()},select:function(Y){return this.evaluateNodeSet(Y).toArray()},select1:function(Y){return this.select(Y)[0]}};function ls(Y){var Ce=e.parse(Y);return Object.create(as,{expression:{value:Ce}})}r.parse=ls}(),Ae(r,{XPath:de,XPathParser:A,XPathResult:ye,Step:g,PathExpr:C,NodeTest:$,LocationPath:ve,OrOperation:pe,AndOperation:he,BarOperation:W,EqualsOperation:F,NotEqualOperation:x,LessThanOperation:S,GreaterThanOperation:R,LessThanOrEqualOperation:j,GreaterThanOrEqualOperation:M,PlusOperation:J,MinusOperation:D,MultiplyOperation:w,DivOperation:P,ModOperation:L,UnaryMinusOperation:K,FunctionCall:ce,VariableReference:_e,XPathContext:qe,XNodeSet:te,XBoolean:fe,XString:X,XNumber:z,NamespaceResolver:$e,FunctionResolver:Ie,VariableResolver:Xe,Utilities:ue}),r.select=function(e,o,f){return r.selectWithResolver(e,o,null,f)},r.useNamespaces=function(e){var o={mappings:e||{},lookupNamespaceURI:function(f){return this.mappings[f]}};return function(f,y,d){return r.selectWithResolver(f,y,o,d)}},r.selectWithResolver=function(e,o,f,y){var d=new Fe(e,f,new A),b=ye.ANY_TYPE,Q=d.evaluate(o,b,null);return Q.resultType==ye.STRING_TYPE?Q=Q.stringValue:Q.resultType==ye.NUMBER_TYPE?Q=Q.numberValue:Q.resultType==ye.BOOLEAN_TYPE?Q=Q.booleanValue:(Q=Q.nodes,y&&(Q=Q[0])),Q},r.select1=function(e,o){return r.select(e,o,!0)};var E=function(e){return Array.isArray(e)&&e.every(p)},v=function(e){return function(o){return p(o)&&o.nodeType===e}};Ae(r,{isNodeLike:p,isArrayOfNodes:E,isElement:v(H.ELEMENT_NODE),isAttribute:v(H.ATTRIBUTE_NODE),isTextNode:v(H.TEXT_NODE),isCDATASection:v(H.CDATA_SECTION_NODE),isProcessingInstruction:v(H.PROCESSING_INSTRUCTION_NODE),isComment:v(H.COMMENT_NODE),isDocumentNode:v(H.DOCUMENT_NODE),isDocumentTypeNode:v(H.DOCUMENT_TYPE_NODE),isDocumentFragment:v(H.DOCUMENT_FRAGMENT_NODE)})})(t)}(vt)),vt}var Jr=Zr();const en=Qr(Jr);var ft={},Qe={},st={},It;function yt(){if(It)return st;It=1;function n(l,p,N){if(N===void 0&&(N=Array.prototype),l&&typeof N.find=="function")return N.find.call(l,p);for(var h=0;h<l.length;h++)if(Object.prototype.hasOwnProperty.call(l,h)){var m=l[h];if(p.call(void 0,m,h,l))return m}}function t(l,p){return p===void 0&&(p=Object),p&&typeof p.freeze=="function"?p.freeze(l):l}function r(l,p){if(l===null||typeof l!="object")throw new TypeError("target is not an object");for(var N in p)Object.prototype.hasOwnProperty.call(p,N)&&(l[N]=p[N]);return l}var u=t({HTML:"text/html",isHTML:function(l){return l===u.HTML},XML_APPLICATION:"application/xml",XML_TEXT:"text/xml",XML_XHTML_APPLICATION:"application/xhtml+xml",XML_SVG_IMAGE:"image/svg+xml"}),i=t({HTML:"http://www.w3.org/1999/xhtml",isHTML:function(l){return l===i.HTML},SVG:"http://www.w3.org/2000/svg",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/"});return st.assign=r,st.find=n,st.freeze=t,st.MIME_TYPE=u,st.NAMESPACE=i,st}var Pt;function Lt(){if(Pt)return Qe;Pt=1;var n=yt(),t=n.find,r=n.NAMESPACE;function u(a){return a!==""}function i(a){return a?a.split(/[\t\n\f\r ]+/).filter(u):[]}function l(a,c){return a.hasOwnProperty(c)||(a[c]=!0),a}function p(a){if(!a)return[];var c=i(a);return Object.keys(c.reduce(l,{}))}function N(a){return function(c){return a&&a.indexOf(c)!==-1}}function h(a,c){for(var E in a)Object.prototype.hasOwnProperty.call(a,E)&&(c[E]=a[E])}function m(a,c){var E=a.prototype;if(!(E instanceof c)){let v=function(){};v.prototype=c.prototype,v=new v,h(E,v),a.prototype=E=v}E.constructor!=a&&(typeof a!="function"&&console.error("unknown Class:"+a),E.constructor=a)}var B={},T=B.ELEMENT_NODE=1,U=B.ATTRIBUTE_NODE=2,V=B.TEXT_NODE=3,ae=B.CDATA_SECTION_NODE=4,le=B.ENTITY_REFERENCE_NODE=5,_=B.ENTITY_NODE=6,oe=B.PROCESSING_INSTRUCTION_NODE=7,ge=B.COMMENT_NODE=8,re=B.DOCUMENT_NODE=9,De=B.DOCUMENT_TYPE_NODE=10,Ae=B.DOCUMENT_FRAGMENT_NODE=11,H=B.NOTATION_NODE=12,A={},de={};A.INDEX_SIZE_ERR=(de[1]="Index size error",1),A.DOMSTRING_SIZE_ERR=(de[2]="DOMString size error",2);var k=A.HIERARCHY_REQUEST_ERR=(de[3]="Hierarchy request error",3);A.WRONG_DOCUMENT_ERR=(de[4]="Wrong document",4),A.INVALID_CHARACTER_ERR=(de[5]="Invalid character",5),A.NO_DATA_ALLOWED_ERR=(de[6]="No data allowed",6),A.NO_MODIFICATION_ALLOWED_ERR=(de[7]="No modification allowed",7);var I=A.NOT_FOUND_ERR=(de[8]="Not found",8);A.NOT_SUPPORTED_ERR=(de[9]="Not supported",9);var ee=A.INUSE_ATTRIBUTE_ERR=(de[10]="Attribute in use",10);A.INVALID_STATE_ERR=(de[11]="Invalid state",11),A.SYNTAX_ERR=(de[12]="Syntax error",12),A.INVALID_MODIFICATION_ERR=(de[13]="Invalid modification",13),A.NAMESPACE_ERR=(de[14]="Invalid namespace",14),A.INVALID_ACCESS_ERR=(de[15]="Invalid access",15);function K(a,c){if(c instanceof Error)var E=c;else E=this,Error.call(this,de[a]),this.message=de[a],Error.captureStackTrace&&Error.captureStackTrace(this,K);return E.code=a,c&&(this.message=this.message+": "+c),E}K.prototype=Error.prototype,h(A,K);function q(){}q.prototype={length:0,item:function(a){return a>=0&&a<this.length?this[a]:null},toString:function(a,c){for(var E=[],v=0;v<this.length;v++)Fe(this[v],E,a,c);return E.join("")},filter:function(a){return Array.prototype.filter.call(this,a)},indexOf:function(a){return Array.prototype.indexOf.call(this,a)}};function pe(a,c){this._node=a,this._refresh=c,he(this)}function he(a){var c=a._node._inc||a._node.ownerDocument._inc;if(a._inc!==c){var E=a._refresh(a._node);if(ye(a,"length",E.length),!a.$$length||E.length<a.$$length)for(var v=E.length;v in a;v++)Object.prototype.hasOwnProperty.call(a,v)&&delete a[v];h(E,a),a._inc=c}}pe.prototype.item=function(a){return he(this),this[a]||null},m(pe,q);function F(){}function x(a,c){for(var E=a.length;E--;)if(a[E]===c)return E}function S(a,c,E,v){if(v?c[x(c,v)]=E:c[c.length++]=E,a){E.ownerElement=a;var e=a.ownerDocument;e&&(v&&L(e,a,v),P(e,a,E))}}function R(a,c,E){var v=x(c,E);if(v>=0){for(var e=c.length-1;v<e;)c[v]=c[++v];if(c.length=e,a){var o=a.ownerDocument;o&&(L(o,a,E),E.ownerElement=null)}}else throw new K(I,new Error(a.tagName+"@"+E))}F.prototype={length:0,item:q.prototype.item,getNamedItem:function(a){for(var c=this.length;c--;){var E=this[c];if(E.nodeName==a)return E}},setNamedItem:function(a){var c=a.ownerElement;if(c&&c!=this._ownerElement)throw new K(ee);var E=this.getNamedItem(a.nodeName);return S(this._ownerElement,this,a,E),E},setNamedItemNS:function(a){var c=a.ownerElement,E;if(c&&c!=this._ownerElement)throw new K(ee);return E=this.getNamedItemNS(a.namespaceURI,a.localName),S(this._ownerElement,this,a,E),E},removeNamedItem:function(a){var c=this.getNamedItem(a);return R(this._ownerElement,this,c),c},removeNamedItemNS:function(a,c){var E=this.getNamedItemNS(a,c);return R(this._ownerElement,this,E),E},getNamedItemNS:function(a,c){for(var E=this.length;E--;){var v=this[E];if(v.localName==c&&v.namespaceURI==a)return v}return null}};function j(){}j.prototype={hasFeature:function(a,c){return!0},createDocument:function(a,c,E){var v=new w;if(v.implementation=this,v.childNodes=new q,v.doctype=E||null,E&&v.appendChild(E),c){var e=v.createElementNS(a,c);v.appendChild(e)}return v},createDocumentType:function(a,c,E){var v=new te;return v.name=a,v.nodeName=a,v.publicId=c||"",v.systemId=E||"",v}};function M(){}M.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(a,c){return ce(this,a,c)},replaceChild:function(a,c){ce(this,a,c,_e),c&&this.removeChild(c)},removeChild:function(a){return C(this,a)},appendChild:function(a){return this.insertBefore(a,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(a){return Ke(this.ownerDocument||this,this,a)},normalize:function(){for(var a=this.firstChild;a;){var c=a.nextSibling;c&&c.nodeType==V&&a.nodeType==V?(this.removeChild(c),a.appendData(c.data)):(a.normalize(),a=c)}},isSupported:function(a,c){return this.ownerDocument.implementation.hasFeature(a,c)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(a){for(var c=this;c;){var E=c._nsMap;if(E){for(var v in E)if(Object.prototype.hasOwnProperty.call(E,v)&&E[v]===a)return v}c=c.nodeType==U?c.ownerDocument:c.parentNode}return null},lookupNamespaceURI:function(a){for(var c=this;c;){var E=c._nsMap;if(E&&Object.prototype.hasOwnProperty.call(E,a))return E[a];c=c.nodeType==U?c.ownerDocument:c.parentNode}return null},isDefaultNamespace:function(a){var c=this.lookupPrefix(a);return c==null}};function J(a){return a=="<"&&"&lt;"||a==">"&&"&gt;"||a=="&"&&"&amp;"||a=='"'&&"&quot;"||"&#"+a.charCodeAt()+";"}h(B,M),h(B,M.prototype);function D(a,c){if(c(a))return!0;if(a=a.firstChild)do if(D(a,c))return!0;while(a=a.nextSibling)}function w(){this.ownerDocument=this}function P(a,c,E){a&&a._inc++;var v=E.namespaceURI;v===r.XMLNS&&(c._nsMap[E.prefix?E.localName:""]=E.value)}function L(a,c,E,v){a&&a._inc++;var e=E.namespaceURI;e===r.XMLNS&&delete c._nsMap[E.prefix?E.localName:""]}function W(a,c,E){if(a&&a._inc){a._inc++;var v=c.childNodes;if(E)v[v.length++]=E;else{for(var e=c.firstChild,o=0;e;)v[o++]=e,e=e.nextSibling;v.length=o,delete v[v.length]}}}function C(a,c){var E=c.previousSibling,v=c.nextSibling;return E?E.nextSibling=v:a.firstChild=v,v?v.previousSibling=E:a.lastChild=E,c.parentNode=null,c.previousSibling=null,c.nextSibling=null,W(a.ownerDocument,a),c}function ne(a){return a&&(a.nodeType===M.DOCUMENT_NODE||a.nodeType===M.DOCUMENT_FRAGMENT_NODE||a.nodeType===M.ELEMENT_NODE)}function Ee(a){return a&&(Te(a)||ke(a)||be(a)||a.nodeType===M.DOCUMENT_FRAGMENT_NODE||a.nodeType===M.COMMENT_NODE||a.nodeType===M.PROCESSING_INSTRUCTION_NODE)}function be(a){return a&&a.nodeType===M.DOCUMENT_TYPE_NODE}function Te(a){return a&&a.nodeType===M.ELEMENT_NODE}function ke(a){return a&&a.nodeType===M.TEXT_NODE}function ve(a,c){var E=a.childNodes||[];if(t(E,Te)||be(c))return!1;var v=t(E,be);return!(c&&v&&E.indexOf(v)>E.indexOf(c))}function g(a,c){var E=a.childNodes||[];function v(o){return Te(o)&&o!==c}if(t(E,v))return!1;var e=t(E,be);return!(c&&e&&E.indexOf(e)>E.indexOf(c))}function G(a,c,E){if(!ne(a))throw new K(k,"Unexpected parent node type "+a.nodeType);if(E&&E.parentNode!==a)throw new K(I,"child not in parent");if(!Ee(c)||be(c)&&a.nodeType!==M.DOCUMENT_NODE)throw new K(k,"Unexpected node type "+c.nodeType+" for parent node type "+a.nodeType)}function $(a,c,E){var v=a.childNodes||[],e=c.childNodes||[];if(c.nodeType===M.DOCUMENT_FRAGMENT_NODE){var o=e.filter(Te);if(o.length>1||t(e,ke))throw new K(k,"More than one element or text in fragment");if(o.length===1&&!ve(a,E))throw new K(k,"Element in fragment can not be inserted before doctype")}if(Te(c)&&!ve(a,E))throw new K(k,"Only one element can be added and only after doctype");if(be(c)){if(t(v,be))throw new K(k,"Only one doctype is allowed");var f=t(v,Te);if(E&&v.indexOf(f)<v.indexOf(E))throw new K(k,"Doctype can only be inserted before an element");if(!E&&f)throw new K(k,"Doctype can not be appended since element is present")}}function _e(a,c,E){var v=a.childNodes||[],e=c.childNodes||[];if(c.nodeType===M.DOCUMENT_FRAGMENT_NODE){var o=e.filter(Te);if(o.length>1||t(e,ke))throw new K(k,"More than one element or text in fragment");if(o.length===1&&!g(a,E))throw new K(k,"Element in fragment can not be inserted before doctype")}if(Te(c)&&!g(a,E))throw new K(k,"Only one element can be added and only after doctype");if(be(c)){if(t(v,function(d){return be(d)&&d!==E}))throw new K(k,"Only one doctype is allowed");var f=t(v,Te);if(E&&v.indexOf(f)<v.indexOf(E))throw new K(k,"Doctype can only be inserted before an element")}}function ce(a,c,E,v){G(a,c,E),a.nodeType===M.DOCUMENT_NODE&&(v||$)(a,c,E);var e=c.parentNode;if(e&&e.removeChild(c),c.nodeType===Ae){var o=c.firstChild;if(o==null)return c;var f=c.lastChild}else o=f=c;var y=E?E.previousSibling:a.lastChild;o.previousSibling=y,f.nextSibling=E,y?y.nextSibling=o:a.firstChild=o,E==null?a.lastChild=f:E.previousSibling=f;do{o.parentNode=a;var d=a.ownerDocument||a;se(o,d)}while(o!==f&&(o=o.nextSibling));return W(a.ownerDocument||a,a),c.nodeType==Ae&&(c.firstChild=c.lastChild=null),c}function se(a,c){if(a.ownerDocument!==c){if(a.ownerDocument=c,a.nodeType===T&&a.attributes)for(var E=0;E<a.attributes.length;E++){var v=a.attributes.item(E);v&&(v.ownerDocument=c)}for(var e=a.firstChild;e;)se(e,c),e=e.nextSibling}}function X(a,c){c.parentNode&&c.parentNode.removeChild(c),c.parentNode=a,c.previousSibling=a.lastChild,c.nextSibling=null,c.previousSibling?c.previousSibling.nextSibling=c:a.firstChild=c,a.lastChild=c,W(a.ownerDocument,a,c);var E=a.ownerDocument||a;return se(c,E),c}w.prototype={nodeName:"#document",nodeType:re,doctype:null,documentElement:null,_inc:1,insertBefore:function(a,c){if(a.nodeType==Ae){for(var E=a.firstChild;E;){var v=E.nextSibling;this.insertBefore(E,c),E=v}return a}return ce(this,a,c),se(a,this),this.documentElement===null&&a.nodeType===T&&(this.documentElement=a),a},removeChild:function(a){return this.documentElement==a&&(this.documentElement=null),C(this,a)},replaceChild:function(a,c){ce(this,a,c,_e),se(a,this),c&&this.removeChild(c),Te(a)&&(this.documentElement=a)},importNode:function(a,c){return Je(this,a,c)},getElementById:function(a){var c=null;return D(this.documentElement,function(E){if(E.nodeType==T&&E.getAttribute("id")==a)return c=E,!0}),c},getElementsByClassName:function(a){var c=p(a);return new pe(this,function(E){var v=[];return c.length>0&&D(E.documentElement,function(e){if(e!==E&&e.nodeType===T){var o=e.getAttribute("class");if(o){var f=a===o;if(!f){var y=p(o);f=c.every(N(y))}f&&v.push(e)}}}),v})},createElement:function(a){var c=new z;c.ownerDocument=this,c.nodeName=a,c.tagName=a,c.localName=a,c.childNodes=new q;var E=c.attributes=new F;return E._ownerElement=c,c},createDocumentFragment:function(){var a=new Ie;return a.ownerDocument=this,a.childNodes=new q,a},createTextNode:function(a){var c=new fe;return c.ownerDocument=this,c.appendData(a),c},createComment:function(a){var c=new Re;return c.ownerDocument=this,c.appendData(a),c},createCDATASection:function(a){var c=new mt;return c.ownerDocument=this,c.appendData(a),c},createProcessingInstruction:function(a,c){var E=new $e;return E.ownerDocument=this,E.tagName=E.nodeName=E.target=a,E.nodeValue=E.data=c,E},createAttribute:function(a){var c=new rt;return c.ownerDocument=this,c.name=a,c.nodeName=a,c.localName=a,c.specified=!0,c},createEntityReference:function(a){var c=new Xe;return c.ownerDocument=this,c.nodeName=a,c},createElementNS:function(a,c){var E=new z,v=c.split(":"),e=E.attributes=new F;return E.childNodes=new q,E.ownerDocument=this,E.nodeName=c,E.tagName=c,E.namespaceURI=a,v.length==2?(E.prefix=v[0],E.localName=v[1]):E.localName=c,e._ownerElement=E,E},createAttributeNS:function(a,c){var E=new rt,v=c.split(":");return E.ownerDocument=this,E.nodeName=c,E.name=c,E.namespaceURI=a,E.specified=!0,v.length==2?(E.prefix=v[0],E.localName=v[1]):E.localName=c,E}},m(w,M);function z(){this._nsMap={}}z.prototype={nodeType:T,hasAttribute:function(a){return this.getAttributeNode(a)!=null},getAttribute:function(a){var c=this.getAttributeNode(a);return c&&c.value||""},getAttributeNode:function(a){return this.attributes.getNamedItem(a)},setAttribute:function(a,c){var E=this.ownerDocument.createAttribute(a);E.value=E.nodeValue=""+c,this.setAttributeNode(E)},removeAttribute:function(a){var c=this.getAttributeNode(a);c&&this.removeAttributeNode(c)},appendChild:function(a){return a.nodeType===Ae?this.insertBefore(a,null):X(this,a)},setAttributeNode:function(a){return this.attributes.setNamedItem(a)},setAttributeNodeNS:function(a){return this.attributes.setNamedItemNS(a)},removeAttributeNode:function(a){return this.attributes.removeNamedItem(a.nodeName)},removeAttributeNS:function(a,c){var E=this.getAttributeNodeNS(a,c);E&&this.removeAttributeNode(E)},hasAttributeNS:function(a,c){return this.getAttributeNodeNS(a,c)!=null},getAttributeNS:function(a,c){var E=this.getAttributeNodeNS(a,c);return E&&E.value||""},setAttributeNS:function(a,c,E){var v=this.ownerDocument.createAttributeNS(a,c);v.value=v.nodeValue=""+E,this.setAttributeNode(v)},getAttributeNodeNS:function(a,c){return this.attributes.getNamedItemNS(a,c)},getElementsByTagName:function(a){return new pe(this,function(c){var E=[];return D(c,function(v){v!==c&&v.nodeType==T&&(a==="*"||v.tagName==a)&&E.push(v)}),E})},getElementsByTagNameNS:function(a,c){return new pe(this,function(E){var v=[];return D(E,function(e){e!==E&&e.nodeType===T&&(a==="*"||e.namespaceURI===a)&&(c==="*"||e.localName==c)&&v.push(e)}),v})}},w.prototype.getElementsByTagName=z.prototype.getElementsByTagName,w.prototype.getElementsByTagNameNS=z.prototype.getElementsByTagNameNS,m(z,M);function rt(){}rt.prototype.nodeType=U,m(rt,M);function lt(){}lt.prototype={data:"",substringData:function(a,c){return this.data.substring(a,a+c)},appendData:function(a){a=this.data+a,this.nodeValue=this.data=a,this.length=a.length},insertData:function(a,c){this.replaceData(a,0,c)},appendChild:function(a){throw new Error(de[k])},deleteData:function(a,c){this.replaceData(a,c,"")},replaceData:function(a,c,E){var v=this.data.substring(0,a),e=this.data.substring(a+c);E=v+E+e,this.nodeValue=this.data=E,this.length=E.length}},m(lt,M);function fe(){}fe.prototype={nodeName:"#text",nodeType:V,splitText:function(a){var c=this.data,E=c.substring(a);c=c.substring(0,a),this.data=this.nodeValue=c,this.length=c.length;var v=this.ownerDocument.createTextNode(E);return this.parentNode&&this.parentNode.insertBefore(v,this.nextSibling),v}},m(fe,lt);function Re(){}Re.prototype={nodeName:"#comment",nodeType:ge},m(Re,lt);function mt(){}mt.prototype={nodeName:"#cdata-section",nodeType:ae},m(mt,lt);function te(){}te.prototype.nodeType=De,m(te,M);function Ge(){}Ge.prototype.nodeType=H,m(Ge,M);function qe(){}qe.prototype.nodeType=_,m(qe,M);function Xe(){}Xe.prototype.nodeType=le,m(Xe,M);function Ie(){}Ie.prototype.nodeName="#document-fragment",Ie.prototype.nodeType=Ae,m(Ie,M);function $e(){}$e.prototype.nodeType=oe,m($e,M);function me(){}me.prototype.serializeToString=function(a,c,E){return ue.call(a,c,E)},M.prototype.toString=ue;function ue(a,c){var E=[],v=this.nodeType==9&&this.documentElement||this,e=v.prefix,o=v.namespaceURI;if(o&&e==null){var e=v.lookupPrefix(o);if(e==null)var f=[{namespace:o,prefix:null}]}return Fe(this,E,a,c,f),E.join("")}function gt(a,c,E){var v=a.prefix||"",e=a.namespaceURI;if(!e||v==="xml"&&e===r.XML||e===r.XMLNS)return!1;for(var o=E.length;o--;){var f=E[o];if(f.prefix===v)return f.namespace!==e}return!0}function Me(a,c,E){a.push(" ",c,'="',E.replace(/[<>&"\t\n\r]/g,J),'"')}function Fe(a,c,E,v,e){if(e||(e=[]),v)if(a=v(a),a){if(typeof a=="string"){c.push(a);return}}else return;switch(a.nodeType){case T:var o=a.attributes,f=o.length,Se=a.firstChild,y=a.tagName;E=r.isHTML(a.namespaceURI)||E;var d=y;if(!E&&!a.prefix&&a.namespaceURI){for(var b,Q=0;Q<o.length;Q++)if(o.item(Q).name==="xmlns"){b=o.item(Q).value;break}if(!b)for(var xe=e.length-1;xe>=0;xe--){var Ne=e[xe];if(Ne.prefix===""&&Ne.namespace===a.namespaceURI){b=Ne.namespace;break}}if(b!==a.namespaceURI)for(var xe=e.length-1;xe>=0;xe--){var Ne=e[xe];if(Ne.namespace===a.namespaceURI){Ne.prefix&&(d=Ne.prefix+":"+y);break}}}c.push("<",d);for(var Z=0;Z<f;Z++){var ie=o.item(Z);ie.prefix=="xmlns"?e.push({prefix:ie.localName,namespace:ie.value}):ie.nodeName=="xmlns"&&e.push({prefix:"",namespace:ie.value})}for(var Z=0;Z<f;Z++){var ie=o.item(Z);if(gt(ie,E,e)){var Pe=ie.prefix||"",je=ie.namespaceURI;Me(c,Pe?"xmlns:"+Pe:"xmlns",je),e.push({prefix:Pe,namespace:je})}Fe(ie,c,E,v,e)}if(y===d&&gt(a,E,e)){var Pe=a.prefix||"",je=a.namespaceURI;Me(c,Pe?"xmlns:"+Pe:"xmlns",je),e.push({prefix:Pe,namespace:je})}if(Se||E&&!/^(?:meta|link|img|br|hr|input)$/i.test(y)){if(c.push(">"),E&&/^script$/i.test(y))for(;Se;)Se.data?c.push(Se.data):Fe(Se,c,E,v,e.slice()),Se=Se.nextSibling;else for(;Se;)Fe(Se,c,E,v,e.slice()),Se=Se.nextSibling;c.push("</",d,">")}else c.push("/>");return;case re:case Ae:for(var Se=a.firstChild;Se;)Fe(Se,c,E,v,e.slice()),Se=Se.nextSibling;return;case U:return Me(c,a.name,a.value);case V:return c.push(a.data.replace(/[<&>]/g,J));case ae:return c.push("<![CDATA[",a.data,"]]>");case ge:return c.push("<!--",a.data,"-->");case De:var ze=a.publicId,He=a.systemId;if(c.push("<!DOCTYPE ",a.name),ze)c.push(" PUBLIC ",ze),He&&He!="."&&c.push(" ",He),c.push(">");else if(He&&He!=".")c.push(" SYSTEM ",He,">");else{var nt=a.internalSubset;nt&&c.push(" [",nt,"]"),c.push(">")}return;case oe:return c.push("<?",a.target," ",a.data,"?>");case le:return c.push("&",a.nodeName,";");default:c.push("??",a.nodeName)}}function Je(a,c,E){var v;switch(c.nodeType){case T:v=c.cloneNode(!1),v.ownerDocument=a;case Ae:break;case U:E=!0;break}if(v||(v=c.cloneNode(!1)),v.ownerDocument=a,v.parentNode=null,E)for(var e=c.firstChild;e;)v.appendChild(Je(a,e,E)),e=e.nextSibling;return v}function Ke(a,c,E){var v=new c.constructor;for(var e in c)if(Object.prototype.hasOwnProperty.call(c,e)){var o=c[e];typeof o!="object"&&o!=v[e]&&(v[e]=o)}switch(c.childNodes&&(v.childNodes=new q),v.ownerDocument=a,v.nodeType){case T:var f=c.attributes,y=v.attributes=new F,d=f.length;y._ownerElement=v;for(var b=0;b<d;b++)v.setAttributeNode(Ke(a,f.item(b),!0));break;case U:E=!0}if(E)for(var Q=c.firstChild;Q;)v.appendChild(Ke(a,Q,E)),Q=Q.nextSibling;return v}function ye(a,c,E){a[c]=E}try{if(Object.defineProperty){let a=function(c){switch(c.nodeType){case T:case Ae:var E=[];for(c=c.firstChild;c;)c.nodeType!==7&&c.nodeType!==8&&E.push(a(c)),c=c.nextSibling;return E.join("");default:return c.nodeValue}};Object.defineProperty(pe.prototype,"length",{get:function(){return he(this),this.$$length}}),Object.defineProperty(M.prototype,"textContent",{get:function(){return a(this)},set:function(c){switch(this.nodeType){case T:case Ae:for(;this.firstChild;)this.removeChild(this.firstChild);(c||String(c))&&this.appendChild(this.ownerDocument.createTextNode(c));break;default:this.data=c,this.value=c,this.nodeValue=c}}}),ye=function(c,E,v){c["$$"+E]=v}}}catch{}return Qe.DocumentType=te,Qe.DOMException=K,Qe.DOMImplementation=j,Qe.Element=z,Qe.Node=M,Qe.NodeList=q,Qe.XMLSerializer=me,Qe}var pt={},Ct={},Vt;function tn(){return Vt||(Vt=1,function(n){var t=yt().freeze;n.XML_ENTITIES=t({amp:"&",apos:"'",gt:">",lt:"<",quot:'"'}),n.HTML_ENTITIES=t({Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"⁡",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",AMP:"&",amp:"&",And:"⩓",and:"∧",andand:"⩕",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsd:"∡",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",ap:"≈",apacir:"⩯",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",Barwed:"⌆",barwed:"⌅",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",Because:"∵",because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxDL:"╗",boxDl:"╖",boxdL:"╕",boxdl:"┐",boxDR:"╔",boxDr:"╓",boxdR:"╒",boxdr:"┌",boxH:"═",boxh:"─",boxHD:"╦",boxHd:"╤",boxhD:"╥",boxhd:"┬",boxHU:"╩",boxHu:"╧",boxhU:"╨",boxhu:"┴",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxUL:"╝",boxUl:"╜",boxuL:"╛",boxul:"┘",boxUR:"╚",boxUr:"╙",boxuR:"╘",boxur:"└",boxV:"║",boxv:"│",boxVH:"╬",boxVh:"╫",boxvH:"╪",boxvh:"┼",boxVL:"╣",boxVl:"╢",boxvL:"╡",boxvl:"┤",boxVR:"╠",boxVr:"╟",boxvR:"╞",boxvr:"├",bprime:"‵",Breve:"˘",breve:"˘",brvbar:"¦",Bscr:"ℬ",bscr:"𝒷",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsol:"\\",bsolb:"⧅",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",Cap:"⋒",cap:"∩",capand:"⩄",capbrcup:"⩉",capcap:"⩋",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",CenterDot:"·",centerdot:"·",Cfr:"ℭ",cfr:"𝔠",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",cir:"○",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",Colon:"∷",colon:":",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",Conint:"∯",conint:"∮",ContourIntegral:"∮",Copf:"ℂ",copf:"𝕔",coprod:"∐",Coproduct:"∐",COPY:"©",copy:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",Cross:"⨯",cross:"✗",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",Cup:"⋓",cup:"∪",cupbrcap:"⩈",CupCap:"≍",cupcap:"⩆",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",Dagger:"‡",dagger:"†",daleth:"ℸ",Darr:"↡",dArr:"⇓",darr:"↓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",DD:"ⅅ",dd:"ⅆ",ddagger:"‡",ddarr:"⇊",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",Diamond:"⋄",diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrow:"↓",Downarrow:"⇓",downarrow:"↓",DownArrowBar:"⤓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVector:"↽",DownLeftVectorBar:"⥖",DownRightTeeVector:"⥟",DownRightVector:"⇁",DownRightVectorBar:"⥗",DownTee:"⊤",DownTeeArrow:"↧",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",ecir:"≖",Ecirc:"Ê",ecirc:"ê",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",eDot:"≑",edot:"ė",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp:" ",emsp13:" ",emsp14:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",Escr:"ℰ",escr:"ℯ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",ExponentialE:"ⅇ",exponentiale:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",ForAll:"∀",forall:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",Fscr:"ℱ",fscr:"𝒻",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",gE:"≧",ge:"≥",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",ges:"⩾",gescc:"⪩",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",Gg:"⋙",gg:"≫",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gl:"≷",gla:"⪥",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gnE:"≩",gne:"⪈",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",Gt:"≫",GT:">",gt:">",gtcc:"⪧",gtcir:"⩺",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",hArr:"⇔",harr:"↔",harrcir:"⥈",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",Hfr:"ℌ",hfr:"𝔥",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",Hopf:"ℍ",hopf:"𝕙",horbar:"―",HorizontalLine:"─",Hscr:"ℋ",hscr:"𝒽",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"⁣",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",Ifr:"ℑ",ifr:"𝔦",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Im:"ℑ",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",imof:"⊷",imped:"Ƶ",Implies:"⇒",in:"∈",incare:"℅",infin:"∞",infintie:"⧝",inodot:"ı",Int:"∬",int:"∫",intcal:"⊺",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",Iscr:"ℐ",iscr:"𝒾",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",Lang:"⟪",lang:"⟨",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",Larr:"↞",lArr:"⇐",larr:"←",larrb:"⇤",larrbfs:"⤟",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",lat:"⪫",lAtail:"⤛",latail:"⤙",late:"⪭",lates:"⪭︀",lBarr:"⤎",lbarr:"⤌",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",lE:"≦",le:"≤",LeftAngleBracket:"⟨",LeftArrow:"←",Leftarrow:"⇐",leftarrow:"←",LeftArrowBar:"⇤",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVector:"⇃",LeftDownVectorBar:"⥙",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrow:"↔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTee:"⊣",LeftTeeArrow:"↤",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangle:"⊲",LeftTriangleBar:"⧏",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVector:"↿",LeftUpVectorBar:"⥘",LeftVector:"↼",LeftVectorBar:"⥒",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",les:"⩽",lescc:"⪨",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",Ll:"⋘",ll:"≪",llarr:"⇇",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoust:"⎰",lmoustache:"⎰",lnap:"⪉",lnapprox:"⪉",lnE:"≨",lne:"⪇",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftarrow:"⟵",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longleftrightarrow:"⟷",longmapsto:"⟼",LongRightArrow:"⟶",Longrightarrow:"⟹",longrightarrow:"⟶",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",Lscr:"ℒ",lscr:"𝓁",Lsh:"↰",lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",Lt:"≪",LT:"<",lt:"<",ltcc:"⪦",ltcir:"⩹",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",mid:"∣",midast:"*",midcir:"⫰",middot:"·",minus:"−",minusb:"⊟",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",Mscr:"ℳ",mscr:"𝓂",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natur:"♮",natural:"♮",naturals:"ℕ",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",ne:"≠",nearhk:"⤤",neArr:"⇗",nearr:"↗",nearrow:"↗",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:`
10
- `,nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nhArr:"⇎",nharr:"↮",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlArr:"⇍",nlarr:"↚",nldr:"‥",nlE:"≦̸",nle:"≰",nLeftarrow:"⇍",nleftarrow:"↚",nLeftrightarrow:"⇎",nleftrightarrow:"↮",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",Nopf:"ℕ",nopf:"𝕟",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangle:"⋪",NotLeftTriangleBar:"⧏̸",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangle:"⋫",NotRightTriangleBar:"⧐̸",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",npar:"∦",nparallel:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",npre:"⪯̸",nprec:"⊀",npreceq:"⪯̸",nrArr:"⇏",nrarr:"↛",nrarrc:"⤳̸",nrarrw:"↝̸",nRightarrow:"⇏",nrightarrow:"↛",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nVDash:"⊯",nVdash:"⊮",nvDash:"⊭",nvdash:"⊬",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwArr:"⇖",nwarr:"↖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",ocir:"⊚",Ocirc:"Ô",ocirc:"ô",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",Or:"⩔",or:"∨",orarr:"↻",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",Otimes:"⨷",otimes:"⊗",otimesas:"⨶",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",par:"∥",para:"¶",parallel:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plus:"+",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",Popf:"ℙ",popf:"𝕡",pound:"£",Pr:"⪻",pr:"≺",prap:"⪷",prcue:"≼",prE:"⪳",pre:"⪯",prec:"≺",precapprox:"⪷",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",precsim:"≾",Prime:"″",prime:"′",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportion:"∷",Proportional:"∝",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",Qopf:"ℚ",qopf:"𝕢",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",QUOT:'"',quot:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",Rang:"⟫",rang:"⟩",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",Rarr:"↠",rArr:"⇒",rarr:"→",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",rAtail:"⤜",ratail:"⤚",ratio:"∶",rationals:"ℚ",RBarr:"⤐",rBarr:"⤏",rbarr:"⤍",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",Re:"ℜ",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",rect:"▭",REG:"®",reg:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",Rfr:"ℜ",rfr:"𝔯",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrow:"→",Rightarrow:"⇒",rightarrow:"→",RightArrowBar:"⇥",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVector:"⇂",RightDownVectorBar:"⥕",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTee:"⊢",RightTeeArrow:"↦",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangle:"⊳",RightTriangleBar:"⧐",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVector:"↾",RightUpVectorBar:"⥔",RightVector:"⇀",RightVectorBar:"⥓",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoust:"⎱",rmoustache:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",Ropf:"ℝ",ropf:"𝕣",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",Rscr:"ℛ",rscr:"𝓇",Rsh:"↱",rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",Sc:"⪼",sc:"≻",scap:"⪸",Scaron:"Š",scaron:"š",sccue:"≽",scE:"⪴",sce:"⪰",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdot:"⋅",sdotb:"⊡",sdote:"⩦",searhk:"⤥",seArr:"⇘",searr:"↘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",sol:"/",solb:"⧄",solbar:"⌿",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",squ:"□",Square:"□",square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",Sub:"⋐",sub:"⊂",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",Subset:"⋐",subset:"⊂",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succ:"≻",succapprox:"⪸",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",Sum:"∑",sum:"∑",sung:"♪",Sup:"⋑",sup:"⊃",sup1:"¹",sup2:"²",sup3:"³",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",Supset:"⋑",supset:"⊃",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swArr:"⇙",swarr:"↙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:" ",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",Therefore:"∴",therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",thinsp:" ",ThinSpace:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",Tilde:"∼",tilde:"˜",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",times:"×",timesb:"⊠",timesbar:"⨱",timesd:"⨰",tint:"∭",toea:"⤨",top:"⊤",topbot:"⌶",topcir:"⫱",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",TRADE:"™",trade:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",Uarr:"↟",uArr:"⇑",uarr:"↑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrow:"↑",Uparrow:"⇑",uparrow:"↑",UpArrowBar:"⤒",UpArrowDownArrow:"⇅",UpDownArrow:"↕",Updownarrow:"⇕",updownarrow:"↕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",Upsi:"ϒ",upsi:"υ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTee:"⊥",UpTeeArrow:"↥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",vArr:"⇕",varr:"↕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",Vbar:"⫫",vBar:"⫨",vBarv:"⫩",Vcy:"В",vcy:"в",VDash:"⊫",Vdash:"⊩",vDash:"⊨",vdash:"⊢",Vdashl:"⫦",Vee:"⋁",vee:"∨",veebar:"⊻",veeeq:"≚",vellip:"⋮",Verbar:"‖",verbar:"|",Vert:"‖",vert:"|",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",Wedge:"⋀",wedge:"∧",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xhArr:"⟺",xharr:"⟷",Xi:"Ξ",xi:"ξ",xlArr:"⟸",xlarr:"⟵",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrArr:"⟹",xrarr:"⟶",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",Yuml:"Ÿ",yuml:"ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"​",Zeta:"Ζ",zeta:"ζ",Zfr:"ℨ",zfr:"𝔷",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",Zopf:"ℤ",zopf:"𝕫",Zscr:"𝒵",zscr:"𝓏",zwj:"‍",zwnj:"‌"}),n.entityMap=n.HTML_ENTITIES}(Ct)),Ct}var At={},Mt;function rn(){if(Mt)return At;Mt=1;var n=yt().NAMESPACE,t=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,r=new RegExp("[\\-\\.0-9"+t.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),u=new RegExp("^"+t.source+r.source+"*(?::"+t.source+r.source+"*)?$"),i=0,l=1,p=2,N=3,h=4,m=5,B=6,T=7;function U(k,I){this.message=k,this.locator=I,Error.captureStackTrace&&Error.captureStackTrace(this,U)}U.prototype=new Error,U.prototype.name=U.name;function V(){}V.prototype={parse:function(k,I,ee){var K=this.domBuilder;K.startDocument(),De(I,I={}),ae(k,I,ee,K,this.errorHandler),K.endDocument()}};function ae(k,I,ee,K,q){function pe(X){if(X>65535){X-=65536;var z=55296+(X>>10),rt=56320+(X&1023);return String.fromCharCode(z,rt)}else return String.fromCharCode(X)}function he(X){var z=X.slice(1,-1);return Object.hasOwnProperty.call(ee,z)?ee[z]:z.charAt(0)==="#"?pe(parseInt(z.substr(1).replace("x","0x"))):(q.error("entity not found:"+X),X)}function F(X){if(X>w){var z=k.substring(w,X).replace(/&#?\w+;/g,he);M&&x(w),K.characters(z,0,X-w),w=X}}function x(X,z){for(;X>=R&&(z=j.exec(k));)S=z.index,R=S+z[0].length,M.lineNumber++;M.columnNumber=X-S+1}for(var S=0,R=0,j=/.*(?:\r\n?|\n)|.*$/g,M=K.locator,J=[{currentNSMap:I}],D={},w=0;;){try{var P=k.indexOf("<",w);if(P<0){if(!k.substr(w).match(/^\s*$/)){var L=K.doc,W=L.createTextNode(k.substr(w));L.appendChild(W),K.currentElement=W}return}switch(P>w&&F(P),k.charAt(P+1)){case"/":var G=k.indexOf(">",P+3),C=k.substring(P+2,G).replace(/[ \t\n\r]+$/g,""),ne=J.pop();G<0?(C=k.substring(P+2).replace(/[\s<].*/,""),q.error("end tag name: "+C+" is not complete:"+ne.tagName),G=P+1+C.length):C.match(/\s</)&&(C=C.replace(/[\s<].*/,""),q.error("end tag name: "+C+" maybe not complete"),G=P+1+C.length);var Ee=ne.localNSMap,be=ne.tagName==C,Te=be||ne.tagName&&ne.tagName.toLowerCase()==C.toLowerCase();if(Te){if(K.endElement(ne.uri,ne.localName,C),Ee)for(var ke in Ee)Object.prototype.hasOwnProperty.call(Ee,ke)&&K.endPrefixMapping(ke);be||q.fatalError("end tag name: "+C+" is not match the current start tagName:"+ne.tagName)}else J.push(ne);G++;break;case"?":M&&x(P),G=H(k,P,K);break;case"!":M&&x(P),G=Ae(k,P,K,q);break;default:M&&x(P);var ve=new A,g=J[J.length-1].currentNSMap,G=_(k,P,ve,g,he,q),$=ve.length;if(!ve.closed&&re(k,G,ve.tagName,D)&&(ve.closed=!0,ee.nbsp||q.warning("unclosed xml attribute")),M&&$){for(var _e=le(M,{}),ce=0;ce<$;ce++){var se=ve[ce];x(se.offset),se.locator=le(M,{})}K.locator=_e,oe(ve,K,g)&&J.push(ve),K.locator=M}else oe(ve,K,g)&&J.push(ve);n.isHTML(ve.uri)&&!ve.closed?G=ge(k,G,ve.tagName,he,K):G++}}catch(X){if(X instanceof U)throw X;q.error("element parse error: "+X),G=-1}G>w?w=G:F(Math.max(P,w)+1)}}function le(k,I){return I.lineNumber=k.lineNumber,I.columnNumber=k.columnNumber,I}function _(k,I,ee,K,q,pe){function he(M,J,D){ee.attributeNames.hasOwnProperty(M)&&pe.fatalError("Attribute "+M+" redefined"),ee.addValue(M,J.replace(/[\t\n\r]/g," ").replace(/&#?\w+;/g,q),D)}for(var F,x,S=++I,R=i;;){var j=k.charAt(S);switch(j){case"=":if(R===l)F=k.slice(I,S),R=N;else if(R===p)R=N;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(R===N||R===l)if(R===l&&(pe.warning('attribute value must after "="'),F=k.slice(I,S)),I=S+1,S=k.indexOf(j,I),S>0)x=k.slice(I,S),he(F,x,I-1),R=m;else throw new Error("attribute value no end '"+j+"' match");else if(R==h)x=k.slice(I,S),he(F,x,I),pe.warning('attribute "'+F+'" missed start quot('+j+")!!"),I=S+1,R=m;else throw new Error('attribute value must after "="');break;case"/":switch(R){case i:ee.setTagName(k.slice(I,S));case m:case B:case T:R=T,ee.closed=!0;case h:case l:break;case p:ee.closed=!0;break;default:throw new Error("attribute invalid close char('/')")}break;case"":return pe.error("unexpected end of input"),R==i&&ee.setTagName(k.slice(I,S)),S;case">":switch(R){case i:ee.setTagName(k.slice(I,S));case m:case B:case T:break;case h:case l:x=k.slice(I,S),x.slice(-1)==="/"&&(ee.closed=!0,x=x.slice(0,-1));case p:R===p&&(x=F),R==h?(pe.warning('attribute "'+x+'" missed quot(")!'),he(F,x,I)):((!n.isHTML(K[""])||!x.match(/^(?:disabled|checked|selected)$/i))&&pe.warning('attribute "'+x+'" missed value!! "'+x+'" instead!!'),he(x,x,I));break;case N:throw new Error("attribute value missed!!")}return S;case"€":j=" ";default:if(j<=" ")switch(R){case i:ee.setTagName(k.slice(I,S)),R=B;break;case l:F=k.slice(I,S),R=p;break;case h:var x=k.slice(I,S);pe.warning('attribute "'+x+'" missed quot(")!!'),he(F,x,I);case m:R=B;break}else switch(R){case p:ee.tagName,(!n.isHTML(K[""])||!F.match(/^(?:disabled|checked|selected)$/i))&&pe.warning('attribute "'+F+'" missed value!! "'+F+'" instead2!!'),he(F,F,I),I=S,R=l;break;case m:pe.warning('attribute space is required"'+F+'"!!');case B:R=l,I=S;break;case N:R=h,I=S;break;case T:throw new Error("elements closed character '/' and '>' must be connected to")}}S++}}function oe(k,I,ee){for(var K=k.tagName,q=null,j=k.length;j--;){var pe=k[j],he=pe.qName,F=pe.value,M=he.indexOf(":");if(M>0)var x=pe.prefix=he.slice(0,M),S=he.slice(M+1),R=x==="xmlns"&&S;else S=he,x=null,R=he==="xmlns"&&"";pe.localName=S,R!==!1&&(q==null&&(q={},De(ee,ee={})),ee[R]=q[R]=F,pe.uri=n.XMLNS,I.startPrefixMapping(R,F))}for(var j=k.length;j--;){pe=k[j];var x=pe.prefix;x&&(x==="xml"&&(pe.uri=n.XML),x!=="xmlns"&&(pe.uri=ee[x||""]))}var M=K.indexOf(":");M>0?(x=k.prefix=K.slice(0,M),S=k.localName=K.slice(M+1)):(x=null,S=k.localName=K);var J=k.uri=ee[x||""];if(I.startElement(J,S,K,k),k.closed){if(I.endElement(J,S,K),q)for(x in q)Object.prototype.hasOwnProperty.call(q,x)&&I.endPrefixMapping(x)}else return k.currentNSMap=ee,k.localNSMap=q,!0}function ge(k,I,ee,K,q){if(/^(?:script|textarea)$/i.test(ee)){var pe=k.indexOf("</"+ee+">",I),he=k.substring(I+1,pe);if(/[&<]/.test(he))return/^script$/i.test(ee)?(q.characters(he,0,he.length),pe):(he=he.replace(/&#?\w+;/g,K),q.characters(he,0,he.length),pe)}return I+1}function re(k,I,ee,K){var q=K[ee];return q==null&&(q=k.lastIndexOf("</"+ee+">"),q<I&&(q=k.lastIndexOf("</"+ee)),K[ee]=q),q<I}function De(k,I){for(var ee in k)Object.prototype.hasOwnProperty.call(k,ee)&&(I[ee]=k[ee])}function Ae(k,I,ee,K){var q=k.charAt(I+2);switch(q){case"-":if(k.charAt(I+3)==="-"){var pe=k.indexOf("-->",I+4);return pe>I?(ee.comment(k,I+4,pe-I-4),pe+3):(K.error("Unclosed comment"),-1)}else return-1;default:if(k.substr(I+3,6)=="CDATA["){var pe=k.indexOf("]]>",I+9);return ee.startCDATA(),ee.characters(k,I+9,pe-I-9),ee.endCDATA(),pe+3}var he=de(k,I),F=he.length;if(F>1&&/!doctype/i.test(he[0][0])){var x=he[1][0],S=!1,R=!1;F>3&&(/^public$/i.test(he[2][0])?(S=he[3][0],R=F>4&&he[4][0]):/^system$/i.test(he[2][0])&&(R=he[3][0]));var j=he[F-1];return ee.startDTD(x,S,R),ee.endDTD(),j.index+j[0].length}}return-1}function H(k,I,ee){var K=k.indexOf("?>",I);if(K){var q=k.substring(I,K).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);return q?(q[0].length,ee.processingInstruction(q[1],q[2]),K+2):-1}return-1}function A(){this.attributeNames={}}A.prototype={setTagName:function(k){if(!u.test(k))throw new Error("invalid tagName:"+k);this.tagName=k},addValue:function(k,I,ee){if(!u.test(k))throw new Error("invalid attribute:"+k);this.attributeNames[k]=this.length,this[this.length++]={qName:k,value:I,offset:ee}},length:0,getLocalName:function(k){return this[k].localName},getLocator:function(k){return this[k].locator},getQName:function(k){return this[k].qName},getURI:function(k){return this[k].uri},getValue:function(k){return this[k].value}};function de(k,I){var ee,K=[],q=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(q.lastIndex=I,q.exec(k);ee=q.exec(k);)if(K.push(ee),ee[1])return K}return At.XMLReader=V,At.ParseError=U,At}var Ut;function nn(){if(Ut)return pt;Ut=1;var n=yt(),t=Lt(),r=tn(),u=rn(),i=t.DOMImplementation,l=n.NAMESPACE,p=u.ParseError,N=u.XMLReader;function h(_){return _.replace(/\r[\n\u0085]/g,`
8
+ `)(L);k=$(u.value,R,G),p.value=k}else throw new Error(`Unsupported filter type: ${w.type}`);m.value="",o.nextTick(()=>{W()})}catch(k){m.value=k instanceof Error?k.message:"Filter execution error",p.value=null}},K=(w,k="root")=>{const L=new Map,G=(R,J)=>{if(R==null)return R;if(typeof R=="object"&&R.__protected_number__!==void 0){const ge=parseFloat(R.__protected_number__);return L.set(ge,J),ge}if(Array.isArray(R)){const ge=R.map((Ee,_e)=>{const ke=`${J}[${_e}]`,De=G(Ee,ke);return L.set(De,ke),De});return L.set(ge,J),ge}if(typeof R=="object"){const ge={};for(const Ee in R)if(Object.prototype.hasOwnProperty.call(R,Ee)){const _e=J==="root"?Ee:`${J}.${Ee}`;ge[Ee]=G(R[Ee],_e)}return L.set(ge,J),ge}return R};return{proxyData:G(w,k),indexMap:L}},$=(w,k,L)=>{if(k===null||typeof k!="object")return k;if(Array.isArray(k))return k.map(R=>{const J=L.get(R);if(J){const ge=ae(w,J);if(ge!==void 0)return ge}return $(w,R,L)});const G=L.get(k);if(G){const R=ae(w,G);if(R!==void 0)return R}const Q={};for(const R in k)Object.prototype.hasOwnProperty.call(k,R)&&(Q[R]=$(w,k[R],L));return Q},ae=(w,k)=>{if(k==="root")return w;const L=[];let G=k.replace(/^root\.?/,"");const Q=/([^\[\].]+)|\[(\d+)\]/g;let R;for(;(R=Q.exec(G))!==null;)R[1]?L.push(R[1]):R[2]!==void 0&&L.push(parseInt(R[2]));let J=w;for(const ge of L){if(J==null)return;J=J[ge]}return J},ee=()=>{p.value=null,m.value=""},U=()=>{_.value=!0},A=()=>{_.value=!1};o.watch(()=>a.modelValue,w=>{v(w)},{immediate:!0});const te=(w,k,L)=>{const G=J=>{if(J===null||typeof J!="object")return J;if(!Array.isArray(J)&&"__protected_number__"in J&&Object.keys(J).length===1)return`__PROTECTED_NUMBER_${J.__protected_number__}_PROTECTED_NUMBER__`;if(Array.isArray(J))return J.map(Ee=>G(Ee));const ge={};for(const[Ee,_e]of Object.entries(J))ge[Ee]=G(_e);return ge},Q=G(w);return JSON.stringify(Q,k,L).replace(/"__PROTECTED_NUMBER_(.+?)_PROTECTED_NUMBER__"/g,"$1")},N=(w,k)=>{if(!a.readonly)try{const L=T(u.value,w,k),G=te(L,null,2);i("update:modelValue",G)}catch(L){console.error("Failed to update JSON:",L)}},T=(w,k,L)=>{if(!k||k==="root")return L;const G=k.split("."),Q=X(w,G.slice(0,-1));let R=Q;for(let ge=0;ge<G.length-1;ge++){const Ee=G[ge];Ee!=="root"&&(Array.isArray(R)?R=R[parseInt(Ee)]:R=R[Ee])}const J=G[G.length-1];return J==="root"?L:(Array.isArray(R)?R[parseInt(J)]=L:R[J]=L,Q)},q=w=>{b.value.has(w)?b.value.delete(w):b.value.add(w)},W=()=>{const w=new Set,k=(L,G="")=>{L!==null&&typeof L=="object"&&(w.add(G||"root"),Array.isArray(L)?L.forEach((Q,R)=>{const J=G?`${G}.${R}`:`${R}`;k(Q,J)}):Object.keys(L).forEach(Q=>{const R=G?`${G}.${Q}`:Q;k(L[Q],R)}))};k(ie.value),b.value=w,i("expand-all")},M=()=>{b.value=new Set(["root"]),i("collapse-all")},de=async()=>{if(D.value)try{const w=ie.value,k=te(w,null,2);await navigator.clipboard.writeText(k),i("copy-success",k)}catch(w){console.error("Failed to copy JSON:",w),i("copy-error",w instanceof Error?w:new Error("Failed to copy JSON"))}},he=()=>{if(D.value)try{const w=ie.value,k=te(w);i("update:modelValue",k),i("compress",k)}catch(w){console.error("Failed to compress JSON:",w)}},ye=async w=>{try{let k;typeof w=="object"&&w!==null&&!Array.isArray(w)&&"__protected_number__"in w&&Object.keys(w).length===1?k=w.__protected_number__:typeof w=="string"?k=`"${w}"`:k=JSON.stringify(w),await navigator.clipboard.writeText(k)}catch(k){console.error("Failed to copy value:",k)}},x=(w,k)=>{if(!a.readonly)try{const L=B(u.value,w,k),G=te(L,null,2);i("update:modelValue",G),le(w,k)}catch(L){console.error("Failed to rename key:",L)}},B=(w,k,L)=>{if(!k||k==="root")return w;const G=k.split("."),Q=X(w,G.slice(0,-1));if(G.length===1){const ge=G[0];return Q&&typeof Q=="object"&&!Array.isArray(Q)?Z(Q,ge,L):Q}let R=Q;for(let ge=0;ge<G.length-1;ge++){const Ee=G[ge];Array.isArray(R)?R=R[parseInt(Ee)]:R=R[Ee]}const J=G[G.length-1];if(!Array.isArray(R)&&R&&typeof R=="object"){const ge=Z(R,J,L),Ee=G.slice(0,-1);Ee.length>0&&F(Q,Ee,ge)}return Q},X=(w,k)=>{if(k.length===0)return w;if(Array.isArray(w)){const L=[...w],G=k[0],Q=parseInt(G);return k.length===1||(L[Q]=X(w[Q],k.slice(1))),L}else if(w&&typeof w=="object"){const L={...w},G=k[0];return k.length===1||(L[G]=X(w[G],k.slice(1))),L}return w},Z=(w,k,L)=>{if(!w||typeof w!="object"||Array.isArray(w))return w;const G=Object.keys(w),Q={};for(const R of G)R===k?Q[L]=w[R]:Q[R]=w[R];return Q},F=(w,k,L)=>{let G=w;for(let R=0;R<k.length-1;R++){const J=k[R];Array.isArray(G)?G=G[parseInt(J)]:G=G[J]}const Q=k[k.length-1];Array.isArray(G)?G[parseInt(Q)]=L:G[Q]=L},le=(w,k)=>{const L=new Set;b.value.forEach(G=>{if(G===w){const Q=w.split(".");Q[Q.length-1]=k,L.add(Q.join("."))}else if(G.startsWith(w+".")){const Q=w.split(".");Q[Q.length-1]=k;const R=Q.join("."),J=G.substring(w.length);L.add(R+J)}else L.add(G)}),b.value=L};return t({copyJson:de,compressSource:he,expandAll:W,collapseAll:M,toggleExpand:q,updateValue:N,updateKey:x,filter:H,clearFilter:ee,sortKeys:U,clearSortKeys:A,isSorted:()=>_.value,isValidJson:()=>D.value,getParsedJson:()=>u.value,getFilteredJson:()=>p.value,getExpandedNodes:()=>b.value,getParseError:()=>c.value,getFilterError:()=>m.value,parseJson:w=>v(w),copyValue:w=>ye(w)}),(w,k)=>(o.openBlock(),o.createElementBlock("div",{class:o.normalizeClass(["json-format",`json-format--${V.value.name}`])},[w.showToolbar?(o.openBlock(),o.createElementBlock("div",qr,[o.createElementVNode("div",Hr,[o.createElementVNode("button",{class:"json-format__btn json-format__btn--primary",onClick:de,disabled:!D.value,title:"Copy JSON"}," 📋 Copy ",8,jr),o.createElementVNode("button",{class:"json-format__btn json-format__btn--secondary",onClick:W,disabled:!D.value,title:"Expand All"}," ⬇️ Expand All ",8,Kr),o.createElementVNode("button",{class:"json-format__btn json-format__btn--secondary",onClick:M,disabled:!D.value,title:"Collapse All"}," ➡️ Collapse All ",8,Gr),o.createElementVNode("button",{class:"json-format__btn json-format__btn--secondary",onClick:he,disabled:!D.value,title:"Compress JSON"}," 📦 Compress ",8,Xr)]),o.createElementVNode("div",zr,[D.value?(o.openBlock(),o.createElementBlock("span",Wr," ✅ Valid JSON ")):(o.openBlock(),o.createElementBlock("span",Yr," ❌ Invalid JSON "))])])):o.createCommentVNode("",!0),o.createElementVNode("div",Qr,[D.value?m.value?(o.openBlock(),o.createElementBlock("div",Jr,[k[1]||(k[1]=o.createElementVNode("h4",null,"Filter Error:",-1)),o.createElementVNode("pre",null,o.toDisplayString(m.value),1)])):(o.openBlock(),o.createElementBlock("div",en,[o.createVNode($r,{value:ie.value,"key-name":"",level:0,expanded:b.value,"is-last":!0,theme:V.value,"onUpdate:value":N,onToggleExpand:q,onCopy:ye,"onUpdate:key":x},null,8,["value","expanded","theme"])])):(o.openBlock(),o.createElementBlock("div",Zr,[k[0]||(k[0]=o.createElementVNode("h4",null,"JSON Parse Error:",-1)),o.createElementVNode("pre",null,o.toDisplayString(c.value),1)]))])],2))}}),[["__scopeId","data-v-94157be3"]]);function tn(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var vt={},Ft;function rn(){return Ft||(Ft=1,function(n){var t=n;(function(r){var a="__namespace",i=function(e){return e==null},u=function(e){return e===a||Number.isInteger(e)&&e>=1&&e<=11},c=function(e){return e&&u(e.nodeType)&&typeof e.nodeName=="string"};function b(e){var s=Array.prototype.slice,d=e.length,E=function(C,oe){return function(){return oe.apply(this,C.concat(s.call(arguments)))}},h=function(){var C=s.call(arguments);return C.length<d?E(C,h):e.apply(this,s.apply(arguments,[0,d]))};return h}var p=function(e,s){for(var d=0;d<s.length;d+=1)e(s[d],d,s)},m=function(e,s,d){var E=s;return p(function(h,C){E=e(E,h,C)},d),E},_=function(e,s){var d=new Array(s.length);return p(function(E,h){d[h]=e(E)},s),d},D=function(e,s){var d=[];return p(function(E,h){e(E,h)&&d.push(E)},s),d},V=function(e,s){for(var d=0;d<e.length;d+=1)if(e[d]===s)return!0;return!1};function j(e){return function(){return e}}function Y(e){return e.toString()}var ie=function(e,s){return s.join(e)},v=function(e,s,d){return e+d+s},H=Array.prototype.concat,K=function(e,s){var d=new ue;d.addArray(e);var E=d.toArray();return s?E.reverse():E},$=32767;function ae(e){for(var s=[],d=0;d<e.length;d+=$){var E=e.slice(d,d+$);s=H.apply(s,E)}return s}function ee(e,s){for(var d=Object(e),E=1;E<arguments.length;E++){var h=arguments[E];if(h!=null)for(var C in h)Object.prototype.hasOwnProperty.call(h,C)&&(d[C]=h[C])}return d}var U={ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NAMESPACE_NODE:a};A.prototype=new Object,A.prototype.constructor=A,A.superclass=Object.prototype;function A(){this.init()}A.prototype.init=function(){this.reduceActions=[],this.reduceActions[3]=function(e){return new de(e[0],e[2])},this.reduceActions[5]=function(e){return new he(e[0],e[2])},this.reduceActions[7]=function(e){return new ye(e[0],e[2])},this.reduceActions[8]=function(e){return new x(e[0],e[2])},this.reduceActions[10]=function(e){return new B(e[0],e[2])},this.reduceActions[11]=function(e){return new X(e[0],e[2])},this.reduceActions[12]=function(e){return new Z(e[0],e[2])},this.reduceActions[13]=function(e){return new F(e[0],e[2])},this.reduceActions[15]=function(e){return new le(e[0],e[2])},this.reduceActions[16]=function(e){return new w(e[0],e[2])},this.reduceActions[18]=function(e){return new k(e[0],e[2])},this.reduceActions[19]=function(e){return new L(e[0],e[2])},this.reduceActions[20]=function(e){return new G(e[0],e[2])},this.reduceActions[22]=function(e){return new W(e[1])},this.reduceActions[24]=function(e){return new Q(e[0],e[2])},this.reduceActions[25]=function(e){return new R(void 0,void 0,e[0])},this.reduceActions[27]=function(e){return e[0].locationPath=e[2],e[0]},this.reduceActions[28]=function(e){return e[0].locationPath=e[2],e[0].locationPath.steps.unshift(new z(z.DESCENDANTORSELF,y.nodeTest,[])),e[0]},this.reduceActions[29]=function(e){return new R(e[0],[],void 0)},this.reduceActions[30]=function(e){return fe.instance_of(e[0],R)?(e[0].filterPredicates==null&&(e[0].filterPredicates=[]),e[0].filterPredicates.push(e[1]),e[0]):new R(e[0],[e[1]],void 0)},this.reduceActions[32]=function(e){return e[1]},this.reduceActions[33]=function(e){return new O(e[0])},this.reduceActions[34]=function(e){return new P(e[0])},this.reduceActions[36]=function(e){return new Ce(e[0],[])},this.reduceActions[37]=function(e){return new Ce(e[0],e[2])},this.reduceActions[38]=function(e){return[e[0]]},this.reduceActions[39]=function(e){return e[2].unshift(e[0]),e[2]},this.reduceActions[43]=function(e){return new De(!0,[])},this.reduceActions[44]=function(e){return e[1].absolute=!0,e[1]},this.reduceActions[46]=function(e){return new De(!1,[e[0]])},this.reduceActions[47]=function(e){return e[0].steps.push(e[2]),e[0]},this.reduceActions[49]=function(e){return new z(e[0],e[1],[])},this.reduceActions[50]=function(e){return new z(z.CHILD,e[0],[])},this.reduceActions[51]=function(e){return new z(e[0],e[1],e[2])},this.reduceActions[52]=function(e){return new z(z.CHILD,e[0],e[1])},this.reduceActions[54]=function(e){return[e[0]]},this.reduceActions[55]=function(e){return e[1].unshift(e[0]),e[1]},this.reduceActions[56]=function(e){return e[0]=="ancestor"?z.ANCESTOR:e[0]=="ancestor-or-self"?z.ANCESTORORSELF:e[0]=="attribute"?z.ATTRIBUTE:e[0]=="child"?z.CHILD:e[0]=="descendant"?z.DESCENDANT:e[0]=="descendant-or-self"?z.DESCENDANTORSELF:e[0]=="following"?z.FOLLOWING:e[0]=="following-sibling"?z.FOLLOWINGSIBLING:e[0]=="namespace"?z.NAMESPACE:e[0]=="parent"?z.PARENT:e[0]=="preceding"?z.PRECEDING:e[0]=="preceding-sibling"?z.PRECEDINGSIBLING:e[0]=="self"?z.SELF:-1},this.reduceActions[57]=function(e){return z.ATTRIBUTE},this.reduceActions[59]=function(e){return e[0]=="comment"?y.commentTest:e[0]=="text"?y.textTest:e[0]=="processing-instruction"?y.anyPiTest:e[0]=="node"?y.nodeTest:new y(-1,void 0)},this.reduceActions[60]=function(e){return new y.PITest(e[2])},this.reduceActions[61]=function(e){return e[1]},this.reduceActions[63]=function(e){return e[1].absolute=!0,e[1].steps.unshift(new z(z.DESCENDANTORSELF,y.nodeTest,[])),e[1]},this.reduceActions[64]=function(e){return e[0].steps.push(new z(z.DESCENDANTORSELF,y.nodeTest,[])),e[0].steps.push(e[2]),e[0]},this.reduceActions[65]=function(e){return new z(z.SELF,y.nodeTest,[])},this.reduceActions[66]=function(e){return new z(z.PARENT,y.nodeTest,[])},this.reduceActions[67]=function(e){return new ne(e[1])},this.reduceActions[68]=function(e){return y.nameTestAny},this.reduceActions[69]=function(e){return new y.NameTestPrefixAny(e[0].split(":")[0])},this.reduceActions[70]=function(e){return new y.NameTestQName(e[0])}},A.actionTable=[" s s sssssssss s ss s ss"," s ","r rrrrrrrrr rrrrrrr rr r "," rrrrr "," s s sssssssss s ss s ss","rs rrrrrrrr s sssssrrrrrr rrs rs "," s s sssssssss s ss s ss"," s "," s ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," s "," s "," s s sssss s s ","r rrrrrrrrr rrrrrrr rr r ","a ","r s rr r ","r sr rr r ","r s rr s rr r ","r rssrr rss rr r ","r rrrrr rrrss rr r ","r rrrrrsss rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrrs rr r ","r rrrrrrrr rrrrrr rr r ","r rrrrrrrr rrrrrr rr r ","r srrrrrrrr rrrrrrs rr sr ","r srrrrrrrr rrrrrrs rr r ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrr rrrrrr rr r ","r rrrrrrrr rrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r "," sssss ","r rrrrrrrrr rrrrrrr rr sr ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," s ","r srrrrrrrr rrrrrrs rr r ","r rrrrrrrr rrrrr rr r "," s "," s "," rrrrr "," s s sssssssss s sss s ss","r srrrrrrrr rrrrrrs rr r "," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss s ss s ss"," s s sssssssss ss s ss"," s s sssssssss s ss s ss"," s s sssss s s "," s s sssss s s ","r rrrrrrrrr rrrrrrr rr rr "," s s sssss s s "," s s sssss s s ","r rrrrrrrrr rrrrrrr rr sr ","r rrrrrrrrr rrrrrrr rr sr ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr rr "," s ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," rr "," s "," rs ","r sr rr r ","r s rr s rr r ","r rssrr rss rr r ","r rssrr rss rr r ","r rrrrr rrrss rr r ","r rrrrr rrrss rr r ","r rrrrr rrrss rr r ","r rrrrr rrrss rr r ","r rrrrrsss rrrrr rr r ","r rrrrrsss rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrr rr r ","r rrrrrrrr rrrrrr rr r "," r "," s ","r srrrrrrrr rrrrrrs rr r ","r srrrrrrrr rrrrrrs rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr r ","r rrrrrrrrr rrrrrrr rr rr ","r rrrrrrrrr rrrrrrr rr rr "," s s sssssssss s ss s ss","r rrrrrrrrr rrrrrrr rr rr "," r "],A.actionTableNumber=[` 1 0 /.-,+*)(' & %$ # "!`," J ","a aaaaaaaaa aaaaaaa aa a "," YYYYY ",` 1 0 /.-,+*)(' & %$ # "!`,`K1 KKKKKKKK . +*)('KKKKKK KK# K" `,` 1 0 /.-,+*)(' & %$ # "!`," N "," O ","e eeeeeeeee eeeeeee ee ee ","f fffffffff fffffff ff ff ","d ddddddddd ddddddd dd dd ","B BBBBBBBBB BBBBBBB BB BB ","A AAAAAAAAA AAAAAAA AA AA "," P "," Q ",` 1 . +*)(' # " `,"b bbbbbbbbb bbbbbbb bb b "," ","! S !! ! ",'" T" "" " ',"$ V $$ U $$ $ ","& &ZY&& &XW && & ",") ))))) )))\\[ )) ) ",". ....._^] ..... .. . ","1 11111111 11111 11 1 ","5 55555555 55555` 55 5 ","7 77777777 777777 77 7 ","9 99999999 999999 99 9 ",": c:::::::: ::::::b :: a: ","I fIIIIIIII IIIIIIe II I ","= ========= ======= == == ","? ????????? ??????? ?? ?? ","C CCCCCCCCC CCCCCCC CC CC ","J JJJJJJJJ JJJJJJ JJ J ","M MMMMMMMM MMMMMM MM M ","N NNNNNNNNN NNNNNNN NN N ","P PPPPPPPPP PPPPPPP PP P "," +*)(' ","R RRRRRRRRR RRRRRRR RR aR ","U UUUUUUUUU UUUUUUU UU U ","Z ZZZZZZZZZ ZZZZZZZ ZZ ZZ ","c ccccccccc ccccccc cc cc "," j ","L fLLLLLLLL LLLLLLe LL L ","6 66666666 66666 66 6 "," k "," l "," XXXXX ",` 1 0 /.-,+*)(' & %$m # "!`,"_ f________ ______e __ _ ",` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 0 /.-,+*)(' %$ # "!`,` 1 0 /.-,+*)(' & %$ # "!`,` 1 . +*)(' # " `,` 1 . +*)(' # " `,"> >>>>>>>>> >>>>>>> >> >> ",` 1 . +*)(' # " `,` 1 . +*)(' # " `,"Q QQQQQQQQQ QQQQQQQ QQ aQ ","V VVVVVVVVV VVVVVVV VV aV ","T TTTTTTTTT TTTTTTT TT T ","@ @@@@@@@@@ @@@@@@@ @@ @@ "," ‡ ","[ [[[[[[[[[ [[[[[[[ [[ [[ ","D DDDDDDDDD DDDDDDD DD DD "," HH "," ˆ "," F‰ ","# T# ## # ","% V %% U %% % ","' 'ZY'' 'XW '' ' ","( (ZY(( (XW (( ( ","+ +++++ +++\\[ ++ + ","* ***** ***\\[ ** * ","- ----- ---\\[ -- - ",", ,,,,, ,,,\\[ ,, , ","0 00000_^] 00000 00 0 ","/ /////_^] ///// // / ","2 22222222 22222 22 2 ","3 33333333 33333 33 3 ","4 44444444 44444 44 4 ","8 88888888 888888 88 8 "," ^ "," Š ","; f;;;;;;;; ;;;;;;e ;; ; ","< f<<<<<<<< <<<<<<e << < ","O OOOOOOOOO OOOOOOO OO O ","` ````````` ``````` `` ` ","S SSSSSSSSS SSSSSSS SS S ","W WWWWWWWWW WWWWWWW WW W ","\\ \\\\\\\\\\\\\\\\\\ \\\\\\\\\\\\\\ \\\\ \\\\ ","E EEEEEEEEE EEEEEEE EE EE ",` 1 0 /.-,+*)(' & %$ # "!`,"] ]]]]]]]]] ]]]]]]] ]] ]] "," G "],A.gotoTable=["3456789:;<=>?@ AB CDEFGH IJ "," "," "," ","L456789:;<=>?@ AB CDEFGH IJ "," M EFGH IJ "," N;<=>?@ AB CDEFGH IJ "," "," "," "," "," "," "," "," "," "," S EFGH IJ "," "," "," "," "," "," "," "," "," "," "," "," "," e "," "," "," "," "," "," "," "," "," h J "," i j "," "," "," "," "," "," "," "," "," ","o456789:;<=>?@ ABpqCDEFGH IJ "," "," r6789:;<=>?@ AB CDEFGH IJ "," s789:;<=>?@ AB CDEFGH IJ "," t89:;<=>?@ AB CDEFGH IJ "," u89:;<=>?@ AB CDEFGH IJ "," v9:;<=>?@ AB CDEFGH IJ "," w9:;<=>?@ AB CDEFGH IJ "," x9:;<=>?@ AB CDEFGH IJ "," y9:;<=>?@ AB CDEFGH IJ "," z:;<=>?@ AB CDEFGH IJ "," {:;<=>?@ AB CDEFGH IJ "," |;<=>?@ AB CDEFGH IJ "," };<=>?@ AB CDEFGH IJ "," ~;<=>?@ AB CDEFGH IJ "," =>?@ AB CDEFGH IJ ","€456789:;<=>?@ AB CDEFGH IJ"," ‚ EFGH IJ "," ƒ EFGH IJ "," "," „ GH IJ "," … GH IJ "," i † "," i ‡ "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," "," ","o456789:;<=>?@ ABŒqCDEFGH IJ "," "," "],A.productions=[[1,1,2],[2,1,3],[3,1,4],[3,3,3,-9,4],[4,1,5],[4,3,4,-8,5],[5,1,6],[5,3,5,-22,6],[5,3,5,-5,6],[6,1,7],[6,3,6,-23,7],[6,3,6,-24,7],[6,3,6,-6,7],[6,3,6,-7,7],[7,1,8],[7,3,7,-25,8],[7,3,7,-26,8],[8,1,9],[8,3,8,-12,9],[8,3,8,-11,9],[8,3,8,-10,9],[9,1,10],[9,2,-26,9],[10,1,11],[10,3,10,-27,11],[11,1,12],[11,1,13],[11,3,13,-28,14],[11,3,13,-4,14],[13,1,15],[13,2,13,16],[15,1,17],[15,3,-29,2,-30],[15,1,-15],[15,1,-16],[15,1,18],[18,3,-13,-29,-30],[18,4,-13,-29,19,-30],[19,1,20],[19,3,20,-31,19],[20,1,2],[12,1,14],[12,1,21],[21,1,-28],[21,2,-28,14],[21,1,22],[14,1,23],[14,3,14,-28,23],[14,1,24],[23,2,25,26],[23,1,26],[23,3,25,26,27],[23,2,26,27],[23,1,28],[27,1,16],[27,2,16,27],[25,2,-14,-3],[25,1,-32],[26,1,29],[26,3,-20,-29,-30],[26,4,-21,-29,-15,-30],[16,3,-33,30,-34],[30,1,2],[22,2,-4,14],[24,3,14,-4,23],[28,1,-35],[28,1,-2],[17,2,-36,-18],[29,1,-17],[29,1,-19],[29,1,-18]],A.DOUBLEDOT=2,A.DOUBLECOLON=3,A.DOUBLESLASH=4,A.NOTEQUAL=5,A.LESSTHANOREQUAL=6,A.GREATERTHANOREQUAL=7,A.AND=8,A.OR=9,A.MOD=10,A.DIV=11,A.MULTIPLYOPERATOR=12,A.FUNCTIONNAME=13,A.AXISNAME=14,A.LITERAL=15,A.NUMBER=16,A.ASTERISKNAMETEST=17,A.QNAME=18,A.NCNAMECOLONASTERISK=19,A.NODETYPE=20,A.PROCESSINGINSTRUCTIONWITHLITERAL=21,A.EQUALS=22,A.LESSTHAN=23,A.GREATERTHAN=24,A.PLUS=25,A.MINUS=26,A.BAR=27,A.SLASH=28,A.LEFTPARENTHESIS=29,A.RIGHTPARENTHESIS=30,A.COMMA=31,A.AT=32,A.LEFTBRACKET=33,A.RIGHTBRACKET=34,A.DOT=35,A.DOLLAR=36,A.prototype.tokenize=function(e){for(var s=[],d=[],E=e+"\0",h=0,C=E.charAt(h++);;){for(;C==" "||C==" "||C=="\r"||C==`
9
+ `;)C=E.charAt(h++);if(C=="\0"||h>=E.length)break;if(C=="("){s.push(A.LEFTPARENTHESIS),d.push(C),C=E.charAt(h++);continue}if(C==")"){s.push(A.RIGHTPARENTHESIS),d.push(C),C=E.charAt(h++);continue}if(C=="["){s.push(A.LEFTBRACKET),d.push(C),C=E.charAt(h++);continue}if(C=="]"){s.push(A.RIGHTBRACKET),d.push(C),C=E.charAt(h++);continue}if(C=="@"){s.push(A.AT),d.push(C),C=E.charAt(h++);continue}if(C==","){s.push(A.COMMA),d.push(C),C=E.charAt(h++);continue}if(C=="|"){s.push(A.BAR),d.push(C),C=E.charAt(h++);continue}if(C=="+"){s.push(A.PLUS),d.push(C),C=E.charAt(h++);continue}if(C=="-"){s.push(A.MINUS),d.push(C),C=E.charAt(h++);continue}if(C=="="){s.push(A.EQUALS),d.push(C),C=E.charAt(h++);continue}if(C=="$"){s.push(A.DOLLAR),d.push(C),C=E.charAt(h++);continue}if(C=="."){if(C=E.charAt(h++),C=="."){s.push(A.DOUBLEDOT),d.push(".."),C=E.charAt(h++);continue}if(C>="0"&&C<="9"){var oe="."+C;for(C=E.charAt(h++);C>="0"&&C<="9";)oe+=C,C=E.charAt(h++);s.push(A.NUMBER),d.push(oe);continue}s.push(A.DOT),d.push(".");continue}if(C=="'"||C=='"'){for(var xe=C,Ne="";h<E.length&&(C=E.charAt(h))!==xe;)Ne+=C,h+=1;if(C!==xe)throw Me.fromMessage("Unterminated string literal: "+xe+Ne);h+=1,s.push(A.LITERAL),d.push(Ne),C=E.charAt(h++);continue}if(C>="0"&&C<="9"){var oe=C;for(C=E.charAt(h++);C>="0"&&C<="9";)oe+=C,C=E.charAt(h++);if(C=="."&&E.charAt(h)>="0"&&E.charAt(h)<="9")for(oe+=C,oe+=E.charAt(h++),C=E.charAt(h++);C>="0"&&C<="9";)oe+=C,C=E.charAt(h++);s.push(A.NUMBER),d.push(oe);continue}if(C=="*"){if(s.length>0){var se=s[s.length-1];if(se!=A.AT&&se!=A.DOUBLECOLON&&se!=A.LEFTPARENTHESIS&&se!=A.LEFTBRACKET&&se!=A.AND&&se!=A.OR&&se!=A.MOD&&se!=A.DIV&&se!=A.MULTIPLYOPERATOR&&se!=A.SLASH&&se!=A.DOUBLESLASH&&se!=A.BAR&&se!=A.PLUS&&se!=A.MINUS&&se!=A.EQUALS&&se!=A.NOTEQUAL&&se!=A.LESSTHAN&&se!=A.LESSTHANOREQUAL&&se!=A.GREATERTHAN&&se!=A.GREATERTHANOREQUAL){s.push(A.MULTIPLYOPERATOR),d.push(C),C=E.charAt(h++);continue}}s.push(A.ASTERISKNAMETEST),d.push(C),C=E.charAt(h++);continue}if(C==":"&&E.charAt(h)==":"){s.push(A.DOUBLECOLON),d.push("::"),h++,C=E.charAt(h++);continue}if(C=="/"){if(C=E.charAt(h++),C=="/"){s.push(A.DOUBLESLASH),d.push("//"),C=E.charAt(h++);continue}s.push(A.SLASH),d.push("/");continue}if(C=="!"&&E.charAt(h)=="="){s.push(A.NOTEQUAL),d.push("!="),h++,C=E.charAt(h++);continue}if(C=="<"){if(E.charAt(h)=="="){s.push(A.LESSTHANOREQUAL),d.push("<="),h++,C=E.charAt(h++);continue}s.push(A.LESSTHAN),d.push("<"),C=E.charAt(h++);continue}if(C==">"){if(E.charAt(h)=="="){s.push(A.GREATERTHANOREQUAL),d.push(">="),h++,C=E.charAt(h++);continue}s.push(A.GREATERTHAN),d.push(">"),C=E.charAt(h++);continue}if(C=="_"||fe.isLetter(C.charCodeAt(0))){var ce=C;for(C=E.charAt(h++);fe.isNCNameChar(C.charCodeAt(0));)ce+=C,C=E.charAt(h++);if(s.length>0){var se=s[s.length-1];if(se!=A.AT&&se!=A.DOUBLECOLON&&se!=A.LEFTPARENTHESIS&&se!=A.LEFTBRACKET&&se!=A.AND&&se!=A.OR&&se!=A.MOD&&se!=A.DIV&&se!=A.MULTIPLYOPERATOR&&se!=A.SLASH&&se!=A.DOUBLESLASH&&se!=A.BAR&&se!=A.PLUS&&se!=A.MINUS&&se!=A.EQUALS&&se!=A.NOTEQUAL&&se!=A.LESSTHAN&&se!=A.LESSTHANOREQUAL&&se!=A.GREATERTHAN&&se!=A.GREATERTHANOREQUAL){if(ce=="and"){s.push(A.AND),d.push(ce);continue}if(ce=="or"){s.push(A.OR),d.push(ce);continue}if(ce=="mod"){s.push(A.MOD),d.push(ce);continue}if(ce=="div"){s.push(A.DIV),d.push(ce);continue}}}if(C==":"){if(E.charAt(h)=="*"){s.push(A.NCNAMECOLONASTERISK),d.push(ce+":*"),h++,C=E.charAt(h++);continue}if(E.charAt(h)=="_"||fe.isLetter(E.charCodeAt(h))){for(ce+=":",C=E.charAt(h++);fe.isNCNameChar(C.charCodeAt(0));)ce+=C,C=E.charAt(h++);if(C=="("){s.push(A.FUNCTIONNAME),d.push(ce);continue}s.push(A.QNAME),d.push(ce);continue}if(E.charAt(h)==":"){s.push(A.AXISNAME),d.push(ce);continue}}if(C=="("){if(ce=="comment"||ce=="text"||ce=="node"){s.push(A.NODETYPE),d.push(ce);continue}if(ce=="processing-instruction"){E.charAt(h)==")"?s.push(A.NODETYPE):s.push(A.PROCESSINGINSTRUCTIONWITHLITERAL),d.push(ce);continue}s.push(A.FUNCTIONNAME),d.push(ce);continue}s.push(A.QNAME),d.push(ce);continue}throw new Error("Unexpected character "+C)}return s.push(1),d.push("[EOF]"),[s,d]},A.SHIFT="s",A.REDUCE="r",A.ACCEPT="a",A.prototype.parse=function(Ne){if(!Ne)throw new Error("XPath expression unspecified.");if(typeof Ne!="string")throw new Error("XPath expression must be a string.");var s,d,E=this.tokenize(Ne);if(E!=null){s=E[0],d=E[1];var h=0,C=[],oe=[],xe=[],Ne,se,ce;for(C.push(0),oe.push(1),xe.push("_S"),se=s[h],ce=d[h++];;)switch(Ne=C[C.length-1],A.actionTable[Ne].charAt(se-1)){case A.SHIFT:oe.push(-se),xe.push(ce),C.push(A.actionTableNumber[Ne].charCodeAt(se-1)-32),se=s[h],ce=d[h++];break;case A.REDUCE:for(var Le=A.productions[A.actionTableNumber[Ne].charCodeAt(se-1)-32][1],Ke=[],Se=0;Se<Le;Se++)oe.pop(),Ke.unshift(xe.pop()),C.pop();var Qe=C[C.length-1];oe.push(A.productions[A.actionTableNumber[Ne].charCodeAt(se-1)-32][0]),this.reduceActions[A.actionTableNumber[Ne].charCodeAt(se-1)-32]==null?xe.push(Ke[0]):xe.push(this.reduceActions[A.actionTableNumber[Ne].charCodeAt(se-1)-32](Ke)),C.push(A.gotoTable[Qe].charCodeAt(A.productions[A.actionTableNumber[Ne].charCodeAt(se-1)-32][0]-2)-33);break;case A.ACCEPT:return new te(xe.pop());default:throw new Error("XPath parse error")}}},te.prototype=new Object,te.prototype.constructor=te,te.superclass=Object.prototype;function te(e){this.expression=e}te.prototype.toString=function(){return this.expression.toString()};function N(e,s,d){s in e||(e[s]=d)}te.prototype.evaluate=function(e){var s=e.expressionContextNode;if(!(i(s)||c(s)))throw new Error("Context node does not appear to be a valid DOM node.");return e.contextNode=e.expressionContextNode,e.contextSize=1,e.contextPosition=1,e.isHtml&&(N(e,"caseInsensitive",!0),N(e,"allowAnyNamespaceForNoPrefix",!0)),N(e,"caseInsensitive",!1),this.expression.evaluate(e)},te.XML_NAMESPACE_URI="http://www.w3.org/XML/1998/namespace",te.XMLNS_NAMESPACE_URI="http://www.w3.org/2000/xmlns/",T.prototype=new Object,T.prototype.constructor=T,T.superclass=Object.prototype;function T(){}T.prototype.init=function(){},T.prototype.toString=function(){return"<Expression>"},T.prototype.evaluate=function(e){throw new Error("Could not evaluate expression.")},q.prototype=new T,q.prototype.constructor=q,q.superclass=T.prototype;function q(e){arguments.length>0&&this.init(e)}q.prototype.init=function(e){this.rhs=e},W.prototype=new q,W.prototype.constructor=W,W.superclass=q.prototype;function W(e){arguments.length>0&&this.init(e)}W.prototype.init=function(e){W.superclass.init.call(this,e)},W.prototype.evaluate=function(e){return this.rhs.evaluate(e).number().negate()},W.prototype.toString=function(){return"-"+this.rhs.toString()},M.prototype=new T,M.prototype.constructor=M,M.superclass=T.prototype;function M(e,s){arguments.length>0&&this.init(e,s)}M.prototype.init=function(e,s){this.lhs=e,this.rhs=s},de.prototype=new M,de.prototype.constructor=de,de.superclass=M.prototype;function de(e,s){arguments.length>0&&this.init(e,s)}de.prototype.init=function(e,s){de.superclass.init.call(this,e,s)},de.prototype.toString=function(){return"("+this.lhs.toString()+" or "+this.rhs.toString()+")"},de.prototype.evaluate=function(e){var s=this.lhs.evaluate(e).bool();return s.booleanValue()?s:this.rhs.evaluate(e).bool()},he.prototype=new M,he.prototype.constructor=he,he.superclass=M.prototype;function he(e,s){arguments.length>0&&this.init(e,s)}he.prototype.init=function(e,s){he.superclass.init.call(this,e,s)},he.prototype.toString=function(){return"("+this.lhs.toString()+" and "+this.rhs.toString()+")"},he.prototype.evaluate=function(e){var s=this.lhs.evaluate(e).bool();return s.booleanValue()?this.rhs.evaluate(e).bool():s},ye.prototype=new M,ye.prototype.constructor=ye,ye.superclass=M.prototype;function ye(e,s){arguments.length>0&&this.init(e,s)}ye.prototype.init=function(e,s){ye.superclass.init.call(this,e,s)},ye.prototype.toString=function(){return"("+this.lhs.toString()+" = "+this.rhs.toString()+")"},ye.prototype.evaluate=function(e){return this.lhs.evaluate(e).equals(this.rhs.evaluate(e))},x.prototype=new M,x.prototype.constructor=x,x.superclass=M.prototype;function x(e,s){arguments.length>0&&this.init(e,s)}x.prototype.init=function(e,s){x.superclass.init.call(this,e,s)},x.prototype.toString=function(){return"("+this.lhs.toString()+" != "+this.rhs.toString()+")"},x.prototype.evaluate=function(e){return this.lhs.evaluate(e).notequal(this.rhs.evaluate(e))},B.prototype=new M,B.prototype.constructor=B,B.superclass=M.prototype;function B(e,s){arguments.length>0&&this.init(e,s)}B.prototype.init=function(e,s){B.superclass.init.call(this,e,s)},B.prototype.evaluate=function(e){return this.lhs.evaluate(e).lessthan(this.rhs.evaluate(e))},B.prototype.toString=function(){return"("+this.lhs.toString()+" < "+this.rhs.toString()+")"},X.prototype=new M,X.prototype.constructor=X,X.superclass=M.prototype;function X(e,s){arguments.length>0&&this.init(e,s)}X.prototype.init=function(e,s){X.superclass.init.call(this,e,s)},X.prototype.evaluate=function(e){return this.lhs.evaluate(e).greaterthan(this.rhs.evaluate(e))},X.prototype.toString=function(){return"("+this.lhs.toString()+" > "+this.rhs.toString()+")"},Z.prototype=new M,Z.prototype.constructor=Z,Z.superclass=M.prototype;function Z(e,s){arguments.length>0&&this.init(e,s)}Z.prototype.init=function(e,s){Z.superclass.init.call(this,e,s)},Z.prototype.evaluate=function(e){return this.lhs.evaluate(e).lessthanorequal(this.rhs.evaluate(e))},Z.prototype.toString=function(){return"("+this.lhs.toString()+" <= "+this.rhs.toString()+")"},F.prototype=new M,F.prototype.constructor=F,F.superclass=M.prototype;function F(e,s){arguments.length>0&&this.init(e,s)}F.prototype.init=function(e,s){F.superclass.init.call(this,e,s)},F.prototype.evaluate=function(e){return this.lhs.evaluate(e).greaterthanorequal(this.rhs.evaluate(e))},F.prototype.toString=function(){return"("+this.lhs.toString()+" >= "+this.rhs.toString()+")"},le.prototype=new M,le.prototype.constructor=le,le.superclass=M.prototype;function le(e,s){arguments.length>0&&this.init(e,s)}le.prototype.init=function(e,s){le.superclass.init.call(this,e,s)},le.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().plus(this.rhs.evaluate(e).number())},le.prototype.toString=function(){return"("+this.lhs.toString()+" + "+this.rhs.toString()+")"},w.prototype=new M,w.prototype.constructor=w,w.superclass=M.prototype;function w(e,s){arguments.length>0&&this.init(e,s)}w.prototype.init=function(e,s){w.superclass.init.call(this,e,s)},w.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().minus(this.rhs.evaluate(e).number())},w.prototype.toString=function(){return"("+this.lhs.toString()+" - "+this.rhs.toString()+")"},k.prototype=new M,k.prototype.constructor=k,k.superclass=M.prototype;function k(e,s){arguments.length>0&&this.init(e,s)}k.prototype.init=function(e,s){k.superclass.init.call(this,e,s)},k.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().multiply(this.rhs.evaluate(e).number())},k.prototype.toString=function(){return"("+this.lhs.toString()+" * "+this.rhs.toString()+")"},L.prototype=new M,L.prototype.constructor=L,L.superclass=M.prototype;function L(e,s){arguments.length>0&&this.init(e,s)}L.prototype.init=function(e,s){L.superclass.init.call(this,e,s)},L.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().div(this.rhs.evaluate(e).number())},L.prototype.toString=function(){return"("+this.lhs.toString()+" div "+this.rhs.toString()+")"},G.prototype=new M,G.prototype.constructor=G,G.superclass=M.prototype;function G(e,s){arguments.length>0&&this.init(e,s)}G.prototype.init=function(e,s){G.superclass.init.call(this,e,s)},G.prototype.evaluate=function(e){return this.lhs.evaluate(e).number().mod(this.rhs.evaluate(e).number())},G.prototype.toString=function(){return"("+this.lhs.toString()+" mod "+this.rhs.toString()+")"},Q.prototype=new M,Q.prototype.constructor=Q,Q.superclass=M.prototype;function Q(e,s){arguments.length>0&&this.init(e,s)}Q.prototype.init=function(e,s){Q.superclass.init.call(this,e,s)},Q.prototype.evaluate=function(e){return this.lhs.evaluate(e).nodeset().union(this.rhs.evaluate(e).nodeset())},Q.prototype.toString=function(){return _(Y,[this.lhs,this.rhs]).join(" | ")},R.prototype=new T,R.prototype.constructor=R,R.superclass=T.prototype;function R(e,s,d){arguments.length>0&&this.init(e,s,d)}R.prototype.init=function(e,s,d){R.superclass.init.call(this),this.filter=e,this.filterPredicates=s,this.locationPath=d};function J(e){for(;e&&e.parentNode;)e=e.parentNode;return e}var ge=function(e,s,d,E){if(e.length===0)return d;var h=s.extend({});return m(function(C,oe){return h.contextSize=C.length,D(function(xe,Ne){return h.contextNode=xe,h.contextPosition=Ne+1,R.predicateMatches(oe,h)},C)},K(d,E),e)};R.getRoot=function(e,s){var d=s[0];if(d&&d.nodeType===U.DOCUMENT_NODE)return d;if(e.virtualRoot)return e.virtualRoot;if(!d)throw new Error("Context node not found when determining document root.");var E=d.ownerDocument;if(E)return E;for(var h=d;h.parentNode!=null;)h=h.parentNode;return h};var Ee=function(e){var s=String(e.name);return s==="xmlns"?"":s.substring(0,6)==="xmlns:"?s.substring(6,s.length):null};R.applyStep=function(e,s,d){if(!d)throw new Error("Context node not found when evaluating XPath step: "+e);var E=[];switch(s.contextNode=d,e.axis){case z.ANCESTOR:if(s.contextNode===s.virtualRoot)break;var h;for(s.contextNode.nodeType==U.ATTRIBUTE_NODE?h=R.getOwnerElement(s.contextNode):h=s.contextNode.parentNode;h!=null&&(e.nodeTest.matches(h,s)&&E.push(h),h!==s.virtualRoot);)h=h.parentNode;break;case z.ANCESTORORSELF:for(var h=s.contextNode;h!=null&&(e.nodeTest.matches(h,s)&&E.push(h),h!==s.virtualRoot);h=h.nodeType==U.ATTRIBUTE_NODE?R.getOwnerElement(h):h.parentNode);break;case z.ATTRIBUTE:var C=s.contextNode.attributes;if(C!=null)for(var oe=0;oe<C.length;oe++){var h=C.item(oe);e.nodeTest.matches(h,s)&&E.push(h)}break;case z.CHILD:for(var h=s.contextNode.firstChild;h!=null;h=h.nextSibling)e.nodeTest.matches(h,s)&&E.push(h);break;case z.DESCENDANT:for(var ce=[s.contextNode.firstChild];ce.length>0;)for(var h=ce.pop();h!=null;)e.nodeTest.matches(h,s)&&E.push(h),h.firstChild!=null?(ce.push(h.nextSibling),h=h.firstChild):h=h.nextSibling;break;case z.DESCENDANTORSELF:e.nodeTest.matches(s.contextNode,s)&&E.push(s.contextNode);for(var ce=[s.contextNode.firstChild];ce.length>0;)for(var h=ce.pop();h!=null;)e.nodeTest.matches(h,s)&&E.push(h),h.firstChild!=null?(ce.push(h.nextSibling),h=h.firstChild):h=h.nextSibling;break;case z.FOLLOWING:if(s.contextNode===s.virtualRoot)break;var ce=[];s.contextNode.firstChild!=null?ce.unshift(s.contextNode.firstChild):ce.unshift(s.contextNode.nextSibling);for(var h=s.contextNode.parentNode;h!=null&&h.nodeType!=U.DOCUMENT_NODE&&h!==s.virtualRoot;h=h.parentNode)ce.unshift(h.nextSibling);do for(var h=ce.pop();h!=null;)e.nodeTest.matches(h,s)&&E.push(h),h.firstChild!=null?(ce.push(h.nextSibling),h=h.firstChild):h=h.nextSibling;while(ce.length>0);break;case z.FOLLOWINGSIBLING:if(s.contextNode===s.virtualRoot)break;for(var h=s.contextNode.nextSibling;h!=null;h=h.nextSibling)e.nodeTest.matches(h,s)&&E.push(h);break;case z.NAMESPACE:var xe={};if(s.contextNode.nodeType==U.ELEMENT_NODE){xe.xml=new We("xml",null,te.XML_NAMESPACE_URI,s.contextNode);for(var h=s.contextNode;h!=null&&h.nodeType==U.ELEMENT_NODE;h=h.parentNode)for(var oe=0;oe<h.attributes.length;oe++){var Ne=h.attributes.item(oe),se=Ee(Ne);se!=null&&xe[se]==null&&(xe[se]=new We(se,Ne,Ne.value,s.contextNode))}for(var se in xe){var d=xe[se];e.nodeTest.matches(d,s)&&E.push(d)}}break;case z.PARENT:h=null,s.contextNode!==s.virtualRoot&&(s.contextNode.nodeType==U.ATTRIBUTE_NODE?h=R.getOwnerElement(s.contextNode):h=s.contextNode.parentNode),h!=null&&e.nodeTest.matches(h,s)&&E.push(h);break;case z.PRECEDING:var ce;s.virtualRoot!=null?ce=[s.virtualRoot]:ce=[J(s.contextNode)];e:for(;ce.length>0;)for(var h=ce.pop();h!=null;){if(h==s.contextNode)break e;e.nodeTest.matches(h,s)&&E.unshift(h),h.firstChild!=null?(ce.push(h.nextSibling),h=h.firstChild):h=h.nextSibling}break;case z.PRECEDINGSIBLING:if(s.contextNode===s.virtualRoot)break;for(var h=s.contextNode.previousSibling;h!=null;h=h.previousSibling)e.nodeTest.matches(h,s)&&E.push(h);break;case z.SELF:e.nodeTest.matches(s.contextNode,s)&&E.push(s.contextNode);break}return E};function _e(e,s,d){return ge(e.predicates,s,R.applyStep(e,s,d),V(Be,e.axis))}function ke(e,s,d){return ae(_(_e.bind(null,d,e),s))}R.applySteps=function(e,s,d){return m(ke.bind(null,s),d,e)},R.prototype.applyFilter=function(e,s){if(!this.filter)return{nodes:[e.contextNode]};var d=this.filter.evaluate(e);if(!fe.instance_of(d,ue)){if(this.filterPredicates!=null&&this.filterPredicates.length>0||this.locationPath!=null)throw new Error("Path expression filter must evaluate to a nodeset if predicates or location path are used");return{nonNodes:d}}return{nodes:ge(this.filterPredicates||[],s,d.toUnsortedArray(),!1)}},R.applyLocationPath=function(e,s,d){if(!e)return d;var E=e.absolute?[R.getRoot(s,d)]:d;return R.applySteps(e.steps,s,E)},R.prototype.evaluate=function(e){var s=ee(new He,e),d=this.applyFilter(e,s);if("nonNodes"in d)return d.nonNodes;var E=new ue;return E.addArray(R.applyLocationPath(this.locationPath,s,d.nodes)),E},R.predicateMatches=function(e,s){var d=e.evaluate(s);return fe.instance_of(d,P)?s.contextPosition===d.numberValue():d.booleanValue()},R.predicateString=function(e){return v("[","]",e.toString())},R.predicatesString=function(e){return ie("",_(R.predicateString,e))},R.prototype.toString=function(){if(this.filter!=null){var e=Y(this.filter);return fe.instance_of(this.filter,O)?v("'","'",e):this.filterPredicates!=null&&this.filterPredicates.length?v("(",")",e)+R.predicatesString(this.filterPredicates):this.locationPath!=null?e+(this.locationPath.absolute?"":"/")+Y(this.locationPath):e}return Y(this.locationPath)},R.getOwnerElement=function(e){if(e.ownerElement)return e.ownerElement;try{if(e.selectSingleNode)return e.selectSingleNode("..")}catch{}for(var s=e.nodeType==U.DOCUMENT_NODE?e:e.ownerDocument,d=s.getElementsByTagName("*"),E=0;E<d.length;E++)for(var h=d.item(E),C=h.attributes,oe=0;oe<C.length;oe++){var xe=C.item(oe);if(xe===e)return h}return null},De.prototype=new Object,De.prototype.constructor=De,De.superclass=Object.prototype;function De(e,s){arguments.length>0&&this.init(e,s)}De.prototype.init=function(e,s){this.absolute=e,this.steps=s},De.prototype.toString=function(){return(this.absolute?"/":"")+_(Y,this.steps).join("/")},z.prototype=new Object,z.prototype.constructor=z,z.superclass=Object.prototype;function z(e,s,d){arguments.length>0&&this.init(e,s,d)}z.prototype.init=function(e,s,d){this.axis=e,this.nodeTest=s,this.predicates=d},z.prototype.toString=function(){return z.STEPNAMES[this.axis]+"::"+this.nodeTest.toString()+R.predicatesString(this.predicates)},z.ANCESTOR=0,z.ANCESTORORSELF=1,z.ATTRIBUTE=2,z.CHILD=3,z.DESCENDANT=4,z.DESCENDANTORSELF=5,z.FOLLOWING=6,z.FOLLOWINGSIBLING=7,z.NAMESPACE=8,z.PARENT=9,z.PRECEDING=10,z.PRECEDINGSIBLING=11,z.SELF=12,z.STEPNAMES=m(function(e,s){return e[s[0]]=s[1],e},{},[[z.ANCESTOR,"ancestor"],[z.ANCESTORORSELF,"ancestor-or-self"],[z.ATTRIBUTE,"attribute"],[z.CHILD,"child"],[z.DESCENDANT,"descendant"],[z.DESCENDANTORSELF,"descendant-or-self"],[z.FOLLOWING,"following"],[z.FOLLOWINGSIBLING,"following-sibling"],[z.NAMESPACE,"namespace"],[z.PARENT,"parent"],[z.PRECEDING,"preceding"],[z.PRECEDINGSIBLING,"preceding-sibling"],[z.SELF,"self"]]);var Be=[z.ANCESTOR,z.ANCESTORORSELF,z.PARENT,z.PRECEDING,z.PRECEDINGSIBLING];y.prototype=new Object,y.prototype.constructor=y,y.superclass=Object.prototype;function y(e,s){arguments.length>0&&this.init(e,s)}y.prototype.init=function(e,s){this.type=e,this.value=s},y.prototype.toString=function(){return"<unknown nodetest type>"},y.prototype.matches=function(e,s){console.warn("unknown node test type")},y.NAMETESTANY=0,y.NAMETESTPREFIXANY=1,y.NAMETESTQNAME=2,y.COMMENT=3,y.TEXT=4,y.PI=5,y.NODE=6,y.isNodeType=function(e){return function(s){return V(e,s.nodeType)}},y.makeNodeTestType=function(e,s,d){var E=d||function(){};return E.prototype=new y(e),E.prototype.constructor=E,ee(E.prototype,s),E},y.makeNodeTypeTest=function(e,s,d){return new(y.makeNodeTestType(e,{matches:y.isNodeType(s),toString:j(d)}))},y.hasPrefix=function(e){return e.prefix||(e.nodeName||e.tagName).indexOf(":")!==-1},y.isElementOrAttribute=y.isNodeType([1,2]),y.nameSpaceMatches=function(e,s,d){var E=d.namespaceURI||"";if(!e)return!E||s.allowAnyNamespaceForNoPrefix&&!y.hasPrefix(d);var h=s.namespaceResolver.getNamespace(e,s.expressionContextNode);if(h==null)throw new Error("Cannot resolve QName "+e);return h===E},y.localNameMatches=function(e,s,d){var E=d.localName||d.nodeName;return s.caseInsensitive?e.toLowerCase()===E.toLowerCase():e===E},y.NameTestPrefixAny=y.makeNodeTestType(y.NAMETESTPREFIXANY,{matches:function(e,s){return y.isElementOrAttribute(e)&&y.nameSpaceMatches(this.prefix,s,e)},toString:function(){return this.prefix+":*"}},function(s){this.prefix=s}),y.NameTestQName=y.makeNodeTestType(y.NAMETESTQNAME,{matches:function(e,s){return y.isNodeType([U.ELEMENT_NODE,U.ATTRIBUTE_NODE,U.NAMESPACE_NODE])(e)&&y.nameSpaceMatches(this.prefix,s,e)&&y.localNameMatches(this.localName,s,e)},toString:function(){return this.name}},function(s){var d=s.split(":");this.name=s,this.prefix=d.length>1?d[0]:null,this.localName=d[d.length>1?1:0]}),y.PITest=y.makeNodeTestType(y.PI,{matches:function(e,s){return y.isNodeType([U.PROCESSING_INSTRUCTION_NODE])(e)&&(e.target||e.nodeName)===this.name},toString:function(){return v('processing-instruction("','")',this.name)}},function(e){this.name=e}),y.nameTestAny=y.makeNodeTypeTest(y.NAMETESTANY,[U.ELEMENT_NODE,U.ATTRIBUTE_NODE,U.NAMESPACE_NODE],"*"),y.textTest=y.makeNodeTypeTest(y.TEXT,[U.TEXT_NODE,U.CDATA_SECTION_NODE],"text()"),y.commentTest=y.makeNodeTypeTest(y.COMMENT,[U.COMMENT_NODE],"comment()"),y.nodeTest=y.makeNodeTypeTest(y.NODE,[U.ELEMENT_NODE,U.ATTRIBUTE_NODE,U.TEXT_NODE,U.CDATA_SECTION_NODE,U.PROCESSING_INSTRUCTION_NODE,U.COMMENT_NODE,U.DOCUMENT_NODE],"node()"),y.anyPiTest=y.makeNodeTypeTest(y.PI,[U.PROCESSING_INSTRUCTION_NODE],"processing-instruction()"),ne.prototype=new T,ne.prototype.constructor=ne,ne.superclass=T.prototype;function ne(e){arguments.length>0&&this.init(e)}ne.prototype.init=function(e){this.variable=e},ne.prototype.toString=function(){return"$"+this.variable},ne.prototype.evaluate=function(e){var s=fe.resolveQName(this.variable,e.namespaceResolver,e.contextNode,!1);if(s[0]==null)throw new Error("Cannot resolve QName "+fn);var d=e.variableResolver.getVariable(s[1],s[0]);if(!d)throw Me.fromMessage("Undeclared variable: "+this.toString());return d},Ce.prototype=new T,Ce.prototype.constructor=Ce,Ce.superclass=T.prototype;function Ce(e,s){arguments.length>0&&this.init(e,s)}Ce.prototype.init=function(e,s){this.functionName=e,this.arguments=s},Ce.prototype.toString=function(){for(var e=this.functionName+"(",s=0;s<this.arguments.length;s++)s>0&&(e+=", "),e+=this.arguments[s].toString();return e+")"},Ce.prototype.evaluate=function(e){var s=Pe.getFunctionFromContext(this.functionName,e);if(!s)throw new Error("Unknown function "+this.functionName);var d=[e].concat(this.arguments);return s.apply(e.functionResolver.thisArg,d)};var be=new Object;be.equals=function(e,s){return e.equals(s)},be.notequal=function(e,s){return e.notequal(s)},be.lessthan=function(e,s){return e.lessthan(s)},be.greaterthan=function(e,s){return e.greaterthan(s)},be.lessthanorequal=function(e,s){return e.lessthanorequal(s)},be.greaterthanorequal=function(e,s){return e.greaterthanorequal(s)},O.prototype=new T,O.prototype.constructor=O,O.superclass=T.prototype;function O(e){arguments.length>0&&this.init(e)}O.prototype.init=function(e){this.str=String(e)},O.prototype.toString=function(){return this.str},O.prototype.evaluate=function(e){return this},O.prototype.string=function(){return this},O.prototype.number=function(){return new P(this.str)},O.prototype.bool=function(){return new pe(this.str)},O.prototype.nodeset=function(){throw new Error("Cannot convert string to nodeset")},O.prototype.stringValue=function(){return this.str},O.prototype.numberValue=function(){return this.number().numberValue()},O.prototype.booleanValue=function(){return this.bool().booleanValue()},O.prototype.equals=function(e){return fe.instance_of(e,pe)?this.bool().equals(e):fe.instance_of(e,P)?this.number().equals(e):fe.instance_of(e,ue)?e.compareWithString(this,be.equals):new pe(this.str==e.str)},O.prototype.notequal=function(e){return fe.instance_of(e,pe)?this.bool().notequal(e):fe.instance_of(e,P)?this.number().notequal(e):fe.instance_of(e,ue)?e.compareWithString(this,be.notequal):new pe(this.str!=e.str)},O.prototype.lessthan=function(e){return this.number().lessthan(e)},O.prototype.greaterthan=function(e){return this.number().greaterthan(e)},O.prototype.lessthanorequal=function(e){return this.number().lessthanorequal(e)},O.prototype.greaterthanorequal=function(e){return this.number().greaterthanorequal(e)},P.prototype=new T,P.prototype.constructor=P,P.superclass=T.prototype;function P(e){arguments.length>0&&this.init(e)}P.prototype.init=function(e){this.num=typeof e=="string"?this.parse(e):Number(e)},P.prototype.numberFormat=/^\s*-?[0-9]*\.?[0-9]+\s*$/,P.prototype.parse=function(e){return this.numberFormat.test(e)?parseFloat(e):Number.NaN};function Re(e){for(var s=e.split("e-"),d=s[0].replace(".",""),E=Number(s[1]),h=0;h<E-1;h+=1)d="0"+d;return"0."+d}function qe(e){for(var s=e.split("e"),d=s[0].replace(".",""),E=Number(s[1]),h=E+1-d.length,C=0;C<h;C+=1)d+="0";return d}P.prototype.toString=function(){var e=this.num.toString();return e.indexOf("e-")!==-1?Re(e):e.indexOf("e")!==-1?qe(e):e},P.prototype.evaluate=function(e){return this},P.prototype.string=function(){return new O(this.toString())},P.prototype.number=function(){return this},P.prototype.bool=function(){return new pe(this.num)},P.prototype.nodeset=function(){throw new Error("Cannot convert number to nodeset")},P.prototype.stringValue=function(){return this.string().stringValue()},P.prototype.numberValue=function(){return this.num},P.prototype.booleanValue=function(){return this.bool().booleanValue()},P.prototype.negate=function(){return new P(-this.num)},P.prototype.equals=function(e){return fe.instance_of(e,pe)?this.bool().equals(e):fe.instance_of(e,O)?this.equals(e.number()):fe.instance_of(e,ue)?e.compareWithNumber(this,be.equals):new pe(this.num==e.num)},P.prototype.notequal=function(e){return fe.instance_of(e,pe)?this.bool().notequal(e):fe.instance_of(e,O)?this.notequal(e.number()):fe.instance_of(e,ue)?e.compareWithNumber(this,be.notequal):new pe(this.num!=e.num)},P.prototype.lessthan=function(e){return fe.instance_of(e,ue)?e.compareWithNumber(this,be.greaterthan):fe.instance_of(e,pe)||fe.instance_of(e,O)?this.lessthan(e.number()):new pe(this.num<e.num)},P.prototype.greaterthan=function(e){return fe.instance_of(e,ue)?e.compareWithNumber(this,be.lessthan):fe.instance_of(e,pe)||fe.instance_of(e,O)?this.greaterthan(e.number()):new pe(this.num>e.num)},P.prototype.lessthanorequal=function(e){return fe.instance_of(e,ue)?e.compareWithNumber(this,be.greaterthanorequal):fe.instance_of(e,pe)||fe.instance_of(e,O)?this.lessthanorequal(e.number()):new pe(this.num<=e.num)},P.prototype.greaterthanorequal=function(e){return fe.instance_of(e,ue)?e.compareWithNumber(this,be.lessthanorequal):fe.instance_of(e,pe)||fe.instance_of(e,O)?this.greaterthanorequal(e.number()):new pe(this.num>=e.num)},P.prototype.plus=function(e){return new P(this.num+e.num)},P.prototype.minus=function(e){return new P(this.num-e.num)},P.prototype.multiply=function(e){return new P(this.num*e.num)},P.prototype.div=function(e){return new P(this.num/e.num)},P.prototype.mod=function(e){return new P(this.num%e.num)},pe.prototype=new T,pe.prototype.constructor=pe,pe.superclass=T.prototype;function pe(e){arguments.length>0&&this.init(e)}pe.prototype.init=function(e){this.b=!!e},pe.prototype.toString=function(){return this.b.toString()},pe.prototype.evaluate=function(e){return this},pe.prototype.string=function(){return new O(this.b)},pe.prototype.number=function(){return new P(this.b)},pe.prototype.bool=function(){return this},pe.prototype.nodeset=function(){throw new Error("Cannot convert boolean to nodeset")},pe.prototype.stringValue=function(){return this.string().stringValue()},pe.prototype.numberValue=function(){return this.number().numberValue()},pe.prototype.booleanValue=function(){return this.b},pe.prototype.not=function(){return new pe(!this.b)},pe.prototype.equals=function(e){return fe.instance_of(e,O)||fe.instance_of(e,P)?this.equals(e.bool()):fe.instance_of(e,ue)?e.compareWithBoolean(this,be.equals):new pe(this.b==e.b)},pe.prototype.notequal=function(e){return fe.instance_of(e,O)||fe.instance_of(e,P)?this.notequal(e.bool()):fe.instance_of(e,ue)?e.compareWithBoolean(this,be.notequal):new pe(this.b!=e.b)},pe.prototype.lessthan=function(e){return this.number().lessthan(e)},pe.prototype.greaterthan=function(e){return this.number().greaterthan(e)},pe.prototype.lessthanorequal=function(e){return this.number().lessthanorequal(e)},pe.prototype.greaterthanorequal=function(e){return this.number().greaterthanorequal(e)},pe.true_=new pe(!0),pe.false_=new pe(!1),Ie.prototype=new Object,Ie.prototype.constructor=Ie,Ie.superclass=Object.prototype;function Ie(e){this.init(e)}Ie.prototype.init=function(e){this.left=null,this.right=null,this.node=e,this.depth=1},Ie.prototype.balance=function(){var e=this.left==null?0:this.left.depth,s=this.right==null?0:this.right.depth;if(e>s+1){var d=this.left.left==null?0:this.left.left.depth,E=this.left.right==null?0:this.left.right.depth;d<E&&this.left.rotateRR(),this.rotateLL()}else if(e+1<s){var h=this.right.right==null?0:this.right.right.depth,C=this.right.left==null?0:this.right.left.depth;C>h&&this.right.rotateLL(),this.rotateRR()}},Ie.prototype.rotateLL=function(){var e=this.node,s=this.right;this.node=this.left.node,this.right=this.left,this.left=this.left.left,this.right.left=this.right.right,this.right.right=s,this.right.node=e,this.right.updateInNewLocation(),this.updateInNewLocation()},Ie.prototype.rotateRR=function(){var e=this.node,s=this.left;this.node=this.right.node,this.left=this.right,this.right=this.right.right,this.left.right=this.left.left,this.left.left=s,this.left.node=e,this.left.updateInNewLocation(),this.updateInNewLocation()},Ie.prototype.updateInNewLocation=function(){this.getDepthFromChildren()},Ie.prototype.getDepthFromChildren=function(){this.depth=this.node==null?0:1,this.left!=null&&(this.depth=this.left.depth+1),this.right!=null&&this.depth<=this.right.depth&&(this.depth=this.right.depth+1)};function gt(e,s){if(e===s)return 0;if(e.compareDocumentPosition){var d=e.compareDocumentPosition(s);return d&1||d&10?1:d&20?-1:0}for(var E=0,h=0,C=e;C!=null;C=C.parentNode||C.ownerElement)E++;for(var oe=s;oe!=null;oe=oe.parentNode||oe.ownerElement)h++;if(E>h){for(;E>h;)e=e.parentNode||e.ownerElement,E--;if(e===s)return 1}else if(h>E){for(;h>E;)s=s.parentNode||s.ownerElement,h--;if(e===s)return-1}for(var xe=e.parentNode||e.ownerElement,Ne=s.parentNode||s.ownerElement;xe!==Ne;)e=xe,s=Ne,xe=e.parentNode||e.ownerElement,Ne=s.parentNode||s.ownerElement;var se=Et(e),ce=Et(s);if(se&&!ce)return-1;if(!se&&ce)return 1;if(e.isXPathNamespace){if(e.nodeValue===te.XML_NAMESPACE_URI||!s.isXPathNamespace)return-1;if(s.nodeValue===te.XML_NAMESPACE_URI)return 1}else if(s.isXPathNamespace)return 1;if(xe)for(var Le=se?xe.attributes:xe.childNodes,Ke=Le.length,Se=e.baseNode||e,Qe=s.baseNode||s,Xe=0;Xe<Ke;Xe+=1){var ot=Le[Xe];if(ot===Se)return-1;if(ot===Qe)return 1}throw new Error("Unexpected: could not determine node order")}Ie.prototype.add=function(e){if(e===this.node)return!1;var s=gt(e,this.node),d=!1;return s==-1?this.left==null?(this.left=new Ie(e),d=!0):(d=this.left.add(e),d&&this.balance()):s==1&&(this.right==null?(this.right=new Ie(e),d=!0):(d=this.right.add(e),d&&this.balance())),d&&this.getDepthFromChildren(),d},ue.prototype=new T,ue.prototype.constructor=ue,ue.superclass=T.prototype;function ue(){this.init()}ue.prototype.init=function(){this.tree=null,this.nodes=[],this.size=0},ue.prototype.toString=function(){var e=this.first();return e==null?"":this.stringForNode(e)},ue.prototype.evaluate=function(e){return this},ue.prototype.string=function(){return new O(this.toString())},ue.prototype.stringValue=function(){return this.toString()},ue.prototype.number=function(){return new P(this.string())},ue.prototype.numberValue=function(){return Number(this.string())},ue.prototype.bool=function(){return new pe(this.booleanValue())},ue.prototype.booleanValue=function(){return!!this.size},ue.prototype.nodeset=function(){return this},ue.prototype.stringForNode=function(e){return e.nodeType==U.DOCUMENT_NODE||e.nodeType==U.ELEMENT_NODE||e.nodeType===U.DOCUMENT_FRAGMENT_NODE?this.stringForContainerNode(e):e.nodeType===U.ATTRIBUTE_NODE?e.value||e.nodeValue:e.isNamespaceNode?e.namespace:e.nodeValue},ue.prototype.stringForContainerNode=function(e){for(var s="",d=e.firstChild;d!=null;d=d.nextSibling){var E=d.nodeType;(E===1||E===3||E===4||E===9||E===11)&&(s+=this.stringForNode(d))}return s},ue.prototype.buildTree=function(){if(!this.tree&&this.nodes.length){this.tree=new Ie(this.nodes[0]);for(var e=1;e<this.nodes.length;e+=1)this.tree.add(this.nodes[e])}return this.tree},ue.prototype.first=function(){var e=this.buildTree();if(e==null)return null;for(;e.left!=null;)e=e.left;return e.node},ue.prototype.add=function(e){for(var s=0;s<this.nodes.length;s+=1)if(e===this.nodes[s])return;this.tree=null,this.nodes.push(e),this.size+=1},ue.prototype.addArray=function(e){var s=this;p(function(d){s.add(d)},e)},ue.prototype.toArray=function(){var e=[];return this.toArrayRec(this.buildTree(),e),e},ue.prototype.toArrayRec=function(e,s){e!=null&&(this.toArrayRec(e.left,s),s.push(e.node),this.toArrayRec(e.right,s))},ue.prototype.toUnsortedArray=function(){return this.nodes.slice()},ue.prototype.compareWithString=function(e,s){for(var d=this.toUnsortedArray(),E=0;E<d.length;E++){var h=d[E],C=new O(this.stringForNode(h)),oe=s(C,e);if(oe.booleanValue())return oe}return new pe(!1)},ue.prototype.compareWithNumber=function(e,s){for(var d=this.toUnsortedArray(),E=0;E<d.length;E++){var h=d[E],C=new P(this.stringForNode(h)),oe=s(C,e);if(oe.booleanValue())return oe}return new pe(!1)},ue.prototype.compareWithBoolean=function(e,s){return s(this.bool(),e)},ue.prototype.compareWithNodeSet=function(e,s){for(var d=this.toUnsortedArray(),E=function(xe,Ne){return s(Ne,xe)},h=0;h<d.length;h++){var C=new O(this.stringForNode(d[h])),oe=e.compareWithString(C,E);if(oe.booleanValue())return oe}return new pe(!1)},ue.compareWith=b(function(e,s){return fe.instance_of(s,O)?this.compareWithString(s,e):fe.instance_of(s,P)?this.compareWithNumber(s,e):fe.instance_of(s,pe)?this.compareWithBoolean(s,e):this.compareWithNodeSet(s,e)}),ue.prototype.equals=ue.compareWith(be.equals),ue.prototype.notequal=ue.compareWith(be.notequal),ue.prototype.lessthan=ue.compareWith(be.lessthan),ue.prototype.greaterthan=ue.compareWith(be.greaterthan),ue.prototype.lessthanorequal=ue.compareWith(be.lessthanorequal),ue.prototype.greaterthanorequal=ue.compareWith(be.greaterthanorequal),ue.prototype.union=function(e){var s=new ue;return s.addArray(this.toUnsortedArray()),s.addArray(e.toUnsortedArray()),s},We.prototype=new Object,We.prototype.constructor=We,We.superclass=Object.prototype;function We(e,s,d,E){this.isXPathNamespace=!0,this.baseNode=s,this.ownerDocument=E.ownerDocument,this.nodeName=e,this.prefix=e,this.localName=e,this.namespaceURI=null,this.nodeValue=d,this.ownerElement=E,this.nodeType=U.NAMESPACE_NODE}We.prototype.toString=function(){return'{ "'+this.prefix+'", "'+this.namespaceURI+'" }'},He.prototype=new Object,He.prototype.constructor=He,He.superclass=Object.prototype;function He(e,s,d){this.variableResolver=e??new Ge,this.namespaceResolver=s??new je,this.functionResolver=d??new Pe}He.prototype.extend=function(e){return ee(new He,this,e)},Ge.prototype=new Object,Ge.prototype.constructor=Ge,Ge.superclass=Object.prototype;function Ge(){}Ge.prototype.getVariable=function(e,s){return null},Pe.prototype=new Object,Pe.prototype.constructor=Pe,Pe.superclass=Object.prototype;function Pe(e){this.thisArg=e??me,this.functions=new Object,this.addStandardFunctions()}Pe.prototype.addStandardFunctions=function(){this.functions["{}last"]=me.last,this.functions["{}position"]=me.position,this.functions["{}count"]=me.count,this.functions["{}id"]=me.id,this.functions["{}local-name"]=me.localName,this.functions["{}namespace-uri"]=me.namespaceURI,this.functions["{}name"]=me.name,this.functions["{}string"]=me.string,this.functions["{}concat"]=me.concat,this.functions["{}starts-with"]=me.startsWith,this.functions["{}contains"]=me.contains,this.functions["{}substring-before"]=me.substringBefore,this.functions["{}substring-after"]=me.substringAfter,this.functions["{}substring"]=me.substring,this.functions["{}string-length"]=me.stringLength,this.functions["{}normalize-space"]=me.normalizeSpace,this.functions["{}translate"]=me.translate,this.functions["{}boolean"]=me.boolean_,this.functions["{}not"]=me.not,this.functions["{}true"]=me.true_,this.functions["{}false"]=me.false_,this.functions["{}lang"]=me.lang,this.functions["{}number"]=me.number,this.functions["{}sum"]=me.sum,this.functions["{}floor"]=me.floor,this.functions["{}ceiling"]=me.ceiling,this.functions["{}round"]=me.round},Pe.prototype.addFunction=function(e,s,d){this.functions["{"+e+"}"+s]=d},Pe.getFunctionFromContext=function(e,s){var d=fe.resolveQName(e,s.namespaceResolver,s.contextNode,!1);if(d[0]===null)throw new Error("Cannot resolve QName "+name);return s.functionResolver.getFunction(d[1],d[0])},Pe.prototype.getFunction=function(e,s){return this.functions["{"+s+"}"+e]},je.prototype=new Object,je.prototype.constructor=je,je.superclass=Object.prototype;function je(){}je.prototype.getNamespace=function(e,s){if(e=="xml")return te.XML_NAMESPACE_URI;if(e=="xmlns")return te.XMLNS_NAMESPACE_URI;for(s.nodeType==U.DOCUMENT_NODE?s=s.documentElement:s.nodeType==U.ATTRIBUTE_NODE?s=R.getOwnerElement(s):s.nodeType!=U.ELEMENT_NODE&&(s=s.parentNode);s!=null&&s.nodeType==U.ELEMENT_NODE;){for(var d=s.attributes,E=0;E<d.length;E++){var h=d.item(E),C=h.name||h.nodeName;if(C==="xmlns"&&e===""||C==="xmlns:"+e)return String(h.value||h.nodeValue)}s=s.parentNode}return null};var me=new Object;me.last=function(e){if(arguments.length!=1)throw new Error("Function last expects ()");return new P(e.contextSize)},me.position=function(e){if(arguments.length!=1)throw new Error("Function position expects ()");return new P(e.contextPosition)},me.count=function(){var e=arguments[0],s;if(arguments.length!=2||!fe.instance_of(s=arguments[1].evaluate(e),ue))throw new Error("Function count expects (node-set)");return new P(s.size)},me.id=function(){var e=arguments[0],s;if(arguments.length!=2)throw new Error("Function id expects (object)");s=arguments[1].evaluate(e),fe.instance_of(s,ue)?s=s.toArray().join(" "):s=s.stringValue();for(var d=s.split(/[\x0d\x0a\x09\x20]+/),E=new ue,h=e.contextNode.nodeType==U.DOCUMENT_NODE?e.contextNode:e.contextNode.ownerDocument,C=0;C<d.length;C++){var oe;h.getElementById?oe=h.getElementById(d[C]):oe=fe.getElementById(h,d[C]),oe!=null&&E.add(oe)}return E},me.localName=function(e,s){var d;if(arguments.length==1)d=e.contextNode;else if(arguments.length==2)d=s.evaluate(e).first();else throw new Error("Function local-name expects (node-set?)");return d==null?new O(""):new O(d.localName||d.baseName||d.target||d.nodeName||"")},me.namespaceURI=function(){var e=arguments[0],s;if(arguments.length==1)s=e.contextNode;else if(arguments.length==2)s=arguments[1].evaluate(e).first();else throw new Error("Function namespace-uri expects (node-set?)");return s==null?new O(""):new O(s.namespaceURI||"")},me.name=function(){var e=arguments[0],s;if(arguments.length==1)s=e.contextNode;else if(arguments.length==2)s=arguments[1].evaluate(e).first();else throw new Error("Function name expects (node-set?)");return s==null?new O(""):s.nodeType==U.ELEMENT_NODE?new O(s.nodeName):s.nodeType==U.ATTRIBUTE_NODE?new O(s.name||s.nodeName):s.nodeType===U.PROCESSING_INSTRUCTION_NODE?new O(s.target||s.nodeName):s.localName==null?new O(""):new O(s.localName)},me.string=function(){var e=arguments[0];if(arguments.length==1)return new O(ue.prototype.stringForNode(e.contextNode));if(arguments.length==2)return arguments[1].evaluate(e).string();throw new Error("Function string expects (object?)")},me.concat=function(e){if(arguments.length<3)throw new Error("Function concat expects (string, string[, string]*)");for(var s="",d=1;d<arguments.length;d++)s+=arguments[d].evaluate(e).stringValue();return new O(s)},me.startsWith=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function startsWith expects (string, string)");var s=arguments[1].evaluate(e).stringValue(),d=arguments[2].evaluate(e).stringValue();return new pe(s.substring(0,d.length)==d)},me.contains=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function contains expects (string, string)");var s=arguments[1].evaluate(e).stringValue(),d=arguments[2].evaluate(e).stringValue();return new pe(s.indexOf(d)!==-1)},me.substringBefore=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function substring-before expects (string, string)");var s=arguments[1].evaluate(e).stringValue(),d=arguments[2].evaluate(e).stringValue();return new O(s.substring(0,s.indexOf(d)))},me.substringAfter=function(){var e=arguments[0];if(arguments.length!=3)throw new Error("Function substring-after expects (string, string)");var s=arguments[1].evaluate(e).stringValue(),d=arguments[2].evaluate(e).stringValue();if(d.length==0)return new O(s);var E=s.indexOf(d);return E==-1?new O(""):new O(s.substring(E+d.length))},me.substring=function(){var e=arguments[0];if(!(arguments.length==3||arguments.length==4))throw new Error("Function substring expects (string, number, number?)");var s=arguments[1].evaluate(e).stringValue(),d=Math.round(arguments[2].evaluate(e).numberValue())-1,E=arguments.length==4?d+Math.round(arguments[3].evaluate(e).numberValue()):void 0;return new O(s.substring(d,E))},me.stringLength=function(){var e=arguments[0],s;if(arguments.length==1)s=ue.prototype.stringForNode(e.contextNode);else if(arguments.length==2)s=arguments[1].evaluate(e).stringValue();else throw new Error("Function string-length expects (string?)");return new P(s.length)},me.normalizeSpace=function(){var e=arguments[0],s;if(arguments.length==1)s=ue.prototype.stringForNode(e.contextNode);else if(arguments.length==2)s=arguments[1].evaluate(e).stringValue();else throw new Error("Function normalize-space expects (string?)");for(var d=0,E=s.length-1;fe.isSpace(s.charCodeAt(E));)E--;for(var h="";d<=E&&fe.isSpace(s.charCodeAt(d));)d++;for(;d<=E;)if(fe.isSpace(s.charCodeAt(d)))for(h+=" ";d<=E&&fe.isSpace(s.charCodeAt(d));)d++;else h+=s.charAt(d),d++;return new O(h)},me.translate=function(e,s,d,E){if(arguments.length!=4)throw new Error("Function translate expects (string, string, string)");var h=s.evaluate(e).stringValue(),C=d.evaluate(e).stringValue(),oe=E.evaluate(e).stringValue(),xe=m(function(se,ce,Le){return ce in se||(se[ce]=Le>oe.length?"":oe[Le]),se},{},C),Ne=ie("",_(function(se){return se in xe?xe[se]:se},h));return new O(Ne)},me.boolean_=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function boolean expects (object)");return arguments[1].evaluate(e).bool()},me.not=function(e,s){if(arguments.length!=2)throw new Error("Function not expects (object)");return s.evaluate(e).bool().not()},me.true_=function(){if(arguments.length!=1)throw new Error("Function true expects ()");return pe.true_},me.false_=function(){if(arguments.length!=1)throw new Error("Function false expects ()");return pe.false_},me.lang=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function lang expects (string)");for(var s,d=e.contextNode;d!=null&&d.nodeType!=U.DOCUMENT_NODE;d=d.parentNode){var E=d.getAttributeNS(te.XML_NAMESPACE_URI,"lang");if(E!=null){s=String(E);break}}if(s==null)return pe.false_;var h=arguments[1].evaluate(e).stringValue();return new pe(s.substring(0,h.length)==h&&(s.length==h.length||s.charAt(h.length)=="-"))},me.number=function(){var e=arguments[0];if(!(arguments.length==1||arguments.length==2))throw new Error("Function number expects (object?)");return arguments.length==1?new P(ue.prototype.stringForNode(e.contextNode)):arguments[1].evaluate(e).number()},me.sum=function(){var e=arguments[0],s;if(arguments.length!=2||!fe.instance_of(s=arguments[1].evaluate(e),ue))throw new Error("Function sum expects (node-set)");s=s.toUnsortedArray();for(var d=0,E=0;E<s.length;E++)d+=new P(ue.prototype.stringForNode(s[E])).numberValue();return new P(d)},me.floor=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function floor expects (number)");return new P(Math.floor(arguments[1].evaluate(e).numberValue()))},me.ceiling=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function ceiling expects (number)");return new P(Math.ceil(arguments[1].evaluate(e).numberValue()))},me.round=function(){var e=arguments[0];if(arguments.length!=2)throw new Error("Function round expects (number)");return new P(Math.round(arguments[1].evaluate(e).numberValue()))};var fe=new Object,Et=function(e){return e&&(e.nodeType===U.ATTRIBUTE_NODE||e.ownerElement||e.isXPathNamespace)};fe.splitQName=function(e){var s=e.indexOf(":");return s==-1?[null,e]:[e.substring(0,s),e.substring(s+1)]},fe.resolveQName=function(e,s,d,E){var h=fe.splitQName(e);return h[0]!=null?h[0]=s.getNamespace(h[0],d):E?(h[0]=s.getNamespace("",d),h[0]==null&&(h[0]="")):h[0]="",h},fe.isSpace=function(e){return e==9||e==13||e==10||e==32},fe.isLetter=function(e){return e>=65&&e<=90||e>=97&&e<=122||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=255||e>=256&&e<=305||e>=308&&e<=318||e>=321&&e<=328||e>=330&&e<=382||e>=384&&e<=451||e>=461&&e<=496||e>=500&&e<=501||e>=506&&e<=535||e>=592&&e<=680||e>=699&&e<=705||e==902||e>=904&&e<=906||e==908||e>=910&&e<=929||e>=931&&e<=974||e>=976&&e<=982||e==986||e==988||e==990||e==992||e>=994&&e<=1011||e>=1025&&e<=1036||e>=1038&&e<=1103||e>=1105&&e<=1116||e>=1118&&e<=1153||e>=1168&&e<=1220||e>=1223&&e<=1224||e>=1227&&e<=1228||e>=1232&&e<=1259||e>=1262&&e<=1269||e>=1272&&e<=1273||e>=1329&&e<=1366||e==1369||e>=1377&&e<=1414||e>=1488&&e<=1514||e>=1520&&e<=1522||e>=1569&&e<=1594||e>=1601&&e<=1610||e>=1649&&e<=1719||e>=1722&&e<=1726||e>=1728&&e<=1742||e>=1744&&e<=1747||e==1749||e>=1765&&e<=1766||e>=2309&&e<=2361||e==2365||e>=2392&&e<=2401||e>=2437&&e<=2444||e>=2447&&e<=2448||e>=2451&&e<=2472||e>=2474&&e<=2480||e==2482||e>=2486&&e<=2489||e>=2524&&e<=2525||e>=2527&&e<=2529||e>=2544&&e<=2545||e>=2565&&e<=2570||e>=2575&&e<=2576||e>=2579&&e<=2600||e>=2602&&e<=2608||e>=2610&&e<=2611||e>=2613&&e<=2614||e>=2616&&e<=2617||e>=2649&&e<=2652||e==2654||e>=2674&&e<=2676||e>=2693&&e<=2699||e==2701||e>=2703&&e<=2705||e>=2707&&e<=2728||e>=2730&&e<=2736||e>=2738&&e<=2739||e>=2741&&e<=2745||e==2749||e==2784||e>=2821&&e<=2828||e>=2831&&e<=2832||e>=2835&&e<=2856||e>=2858&&e<=2864||e>=2866&&e<=2867||e>=2870&&e<=2873||e==2877||e>=2908&&e<=2909||e>=2911&&e<=2913||e>=2949&&e<=2954||e>=2958&&e<=2960||e>=2962&&e<=2965||e>=2969&&e<=2970||e==2972||e>=2974&&e<=2975||e>=2979&&e<=2980||e>=2984&&e<=2986||e>=2990&&e<=2997||e>=2999&&e<=3001||e>=3077&&e<=3084||e>=3086&&e<=3088||e>=3090&&e<=3112||e>=3114&&e<=3123||e>=3125&&e<=3129||e>=3168&&e<=3169||e>=3205&&e<=3212||e>=3214&&e<=3216||e>=3218&&e<=3240||e>=3242&&e<=3251||e>=3253&&e<=3257||e==3294||e>=3296&&e<=3297||e>=3333&&e<=3340||e>=3342&&e<=3344||e>=3346&&e<=3368||e>=3370&&e<=3385||e>=3424&&e<=3425||e>=3585&&e<=3630||e==3632||e>=3634&&e<=3635||e>=3648&&e<=3653||e>=3713&&e<=3714||e==3716||e>=3719&&e<=3720||e==3722||e==3725||e>=3732&&e<=3735||e>=3737&&e<=3743||e>=3745&&e<=3747||e==3749||e==3751||e>=3754&&e<=3755||e>=3757&&e<=3758||e==3760||e>=3762&&e<=3763||e==3773||e>=3776&&e<=3780||e>=3904&&e<=3911||e>=3913&&e<=3945||e>=4256&&e<=4293||e>=4304&&e<=4342||e==4352||e>=4354&&e<=4355||e>=4357&&e<=4359||e==4361||e>=4363&&e<=4364||e>=4366&&e<=4370||e==4412||e==4414||e==4416||e==4428||e==4430||e==4432||e>=4436&&e<=4437||e==4441||e>=4447&&e<=4449||e==4451||e==4453||e==4455||e==4457||e>=4461&&e<=4462||e>=4466&&e<=4467||e==4469||e==4510||e==4520||e==4523||e>=4526&&e<=4527||e>=4535&&e<=4536||e==4538||e>=4540&&e<=4546||e==4587||e==4592||e==4601||e>=7680&&e<=7835||e>=7840&&e<=7929||e>=7936&&e<=7957||e>=7960&&e<=7965||e>=7968&&e<=8005||e>=8008&&e<=8013||e>=8016&&e<=8023||e==8025||e==8027||e==8029||e>=8031&&e<=8061||e>=8064&&e<=8116||e>=8118&&e<=8124||e==8126||e>=8130&&e<=8132||e>=8134&&e<=8140||e>=8144&&e<=8147||e>=8150&&e<=8155||e>=8160&&e<=8172||e>=8178&&e<=8180||e>=8182&&e<=8188||e==8486||e>=8490&&e<=8491||e==8494||e>=8576&&e<=8578||e>=12353&&e<=12436||e>=12449&&e<=12538||e>=12549&&e<=12588||e>=44032&&e<=55203||e>=19968&&e<=40869||e==12295||e>=12321&&e<=12329},fe.isNCNameChar=function(e){return e>=48&&e<=57||e>=1632&&e<=1641||e>=1776&&e<=1785||e>=2406&&e<=2415||e>=2534&&e<=2543||e>=2662&&e<=2671||e>=2790&&e<=2799||e>=2918&&e<=2927||e>=3047&&e<=3055||e>=3174&&e<=3183||e>=3302&&e<=3311||e>=3430&&e<=3439||e>=3664&&e<=3673||e>=3792&&e<=3801||e>=3872&&e<=3881||e==46||e==45||e==95||fe.isLetter(e)||e>=768&&e<=837||e>=864&&e<=865||e>=1155&&e<=1158||e>=1425&&e<=1441||e>=1443&&e<=1465||e>=1467&&e<=1469||e==1471||e>=1473&&e<=1474||e==1476||e>=1611&&e<=1618||e==1648||e>=1750&&e<=1756||e>=1757&&e<=1759||e>=1760&&e<=1764||e>=1767&&e<=1768||e>=1770&&e<=1773||e>=2305&&e<=2307||e==2364||e>=2366&&e<=2380||e==2381||e>=2385&&e<=2388||e>=2402&&e<=2403||e>=2433&&e<=2435||e==2492||e==2494||e==2495||e>=2496&&e<=2500||e>=2503&&e<=2504||e>=2507&&e<=2509||e==2519||e>=2530&&e<=2531||e==2562||e==2620||e==2622||e==2623||e>=2624&&e<=2626||e>=2631&&e<=2632||e>=2635&&e<=2637||e>=2672&&e<=2673||e>=2689&&e<=2691||e==2748||e>=2750&&e<=2757||e>=2759&&e<=2761||e>=2763&&e<=2765||e>=2817&&e<=2819||e==2876||e>=2878&&e<=2883||e>=2887&&e<=2888||e>=2891&&e<=2893||e>=2902&&e<=2903||e>=2946&&e<=2947||e>=3006&&e<=3010||e>=3014&&e<=3016||e>=3018&&e<=3021||e==3031||e>=3073&&e<=3075||e>=3134&&e<=3140||e>=3142&&e<=3144||e>=3146&&e<=3149||e>=3157&&e<=3158||e>=3202&&e<=3203||e>=3262&&e<=3268||e>=3270&&e<=3272||e>=3274&&e<=3277||e>=3285&&e<=3286||e>=3330&&e<=3331||e>=3390&&e<=3395||e>=3398&&e<=3400||e>=3402&&e<=3405||e==3415||e==3633||e>=3636&&e<=3642||e>=3655&&e<=3662||e==3761||e>=3764&&e<=3769||e>=3771&&e<=3772||e>=3784&&e<=3789||e>=3864&&e<=3865||e==3893||e==3895||e==3897||e==3902||e==3903||e>=3953&&e<=3972||e>=3974&&e<=3979||e>=3984&&e<=3989||e==3991||e>=3993&&e<=4013||e>=4017&&e<=4023||e==4025||e>=8400&&e<=8412||e==8417||e>=12330&&e<=12335||e==12441||e==12442||e==183||e==720||e==721||e==903||e==1600||e==3654||e==3782||e==12293||e>=12337&&e<=12341||e>=12445&&e<=12446||e>=12540&&e<=12542},fe.coalesceText=function(e){for(var s=e.firstChild;s!=null;s=s.nextSibling)if(s.nodeType==U.TEXT_NODE||s.nodeType==U.CDATA_SECTION_NODE){var d=s.nodeValue,E=s;for(s=s.nextSibling;s!=null&&(s.nodeType==U.TEXT_NODE||s.nodeType==U.CDATA_SECTION_NODE);){d+=s.nodeValue;var h=s;s=s.nextSibling,h.parentNode.removeChild(h)}if(E.nodeType==U.CDATA_SECTION_NODE){var C=E.parentNode;if(E.nextSibling==null)C.removeChild(E),C.appendChild(C.ownerDocument.createTextNode(d));else{var oe=E.nextSibling;C.removeChild(E),C.insertBefore(C.ownerDocument.createTextNode(d),oe)}}else E.nodeValue=d;if(s==null)break}else s.nodeType==U.ELEMENT_NODE&&fe.coalesceText(s)},fe.instance_of=function(e,s){for(;e!=null;){if(e.constructor===s)return!0;if(e===Object)return!1;e=e.constructor.superclass}return!1},fe.getElementById=function(e,s){if(e.nodeType==U.ELEMENT_NODE&&(e.getAttribute("id")==s||e.getAttributeNS(null,"id")==s))return e;for(var d=e.firstChild;d!=null;d=d.nextSibling){var E=fe.getElementById(d,s);if(E!=null)return E}return null};var Me=function(){function e(d,E){var h=E?": "+E.toString():"";switch(d){case s.INVALID_EXPRESSION_ERR:return"Invalid expression"+h;case s.TYPE_ERR:return"Type error"+h}return null}function s(d,E,h){var C=Error.call(this,e(d,E)||h);return C.code=d,C.exception=E,C}return s.prototype=Object.create(Error.prototype),s.prototype.constructor=s,s.superclass=Error,s.prototype.toString=function(){return this.message},s.fromMessage=function(d,E){return new s(null,E,d)},s.INVALID_EXPRESSION_ERR=51,s.TYPE_ERR=52,s}();Fe.prototype={},Fe.prototype.constructor=Fe,Fe.superclass=Object.prototype;function Fe(e,s,d){this.xpath=d.parse(e),this.context=new He,this.context.namespaceResolver=new tt(s)}Fe.getOwnerDocument=function(e){return e.nodeType===U.DOCUMENT_NODE?e:e.ownerDocument},Fe.detectHtmlDom=function(e){if(!e)return!1;var s=Fe.getOwnerDocument(e);try{return s.implementation.hasFeature("HTML","2.0")}catch{return!0}},Fe.prototype.evaluate=function(e,s,d){this.context.expressionContextNode=e,this.context.caseInsensitive=Fe.detectHtmlDom(e);var E=this.xpath.evaluate(this.context);return new Ae(E,s)},tt.prototype={},tt.prototype.constructor=tt,tt.superclass=Object.prototype;function tt(e){this.xpathNSResolver=e}tt.prototype.getNamespace=function(e,s){return this.xpathNSResolver==null?null:this.xpathNSResolver.lookupNamespaceURI(e)},Ye.prototype={},Ye.prototype.constructor=Ye,Ye.superclass=Object.prototype;function Ye(e){this.node=e,this.namespaceResolver=new je}Ye.prototype.lookupNamespaceURI=function(e){return this.namespaceResolver.getNamespace(e,this.node)},Ae.prototype={},Ae.prototype.constructor=Ae,Ae.superclass=Object.prototype;function Ae(e,s){switch(s==Ae.ANY_TYPE&&(e.constructor===O?s=Ae.STRING_TYPE:e.constructor===P?s=Ae.NUMBER_TYPE:e.constructor===pe?s=Ae.BOOLEAN_TYPE:e.constructor===ue&&(s=Ae.UNORDERED_NODE_ITERATOR_TYPE)),this.resultType=s,s){case Ae.NUMBER_TYPE:this.numberValue=e.numberValue();return;case Ae.STRING_TYPE:this.stringValue=e.stringValue();return;case Ae.BOOLEAN_TYPE:this.booleanValue=e.booleanValue();return;case Ae.ANY_UNORDERED_NODE_TYPE:case Ae.FIRST_ORDERED_NODE_TYPE:if(e.constructor===ue){this.singleNodeValue=e.first();return}break;case Ae.UNORDERED_NODE_ITERATOR_TYPE:case Ae.ORDERED_NODE_ITERATOR_TYPE:if(e.constructor===ue){this.invalidIteratorState=!1,this.nodes=e.toArray(),this.iteratorIndex=0;return}break;case Ae.UNORDERED_NODE_SNAPSHOT_TYPE:case Ae.ORDERED_NODE_SNAPSHOT_TYPE:if(e.constructor===ue){this.nodes=e.toArray(),this.snapshotLength=this.nodes.length;return}break}throw new Me(Me.TYPE_ERR)}Ae.prototype.iterateNext=function(){if(this.resultType!=Ae.UNORDERED_NODE_ITERATOR_TYPE&&this.resultType!=Ae.ORDERED_NODE_ITERATOR_TYPE)throw new Me(Me.TYPE_ERR);return this.nodes[this.iteratorIndex++]},Ae.prototype.snapshotItem=function(e){if(this.resultType!=Ae.UNORDERED_NODE_SNAPSHOT_TYPE&&this.resultType!=Ae.ORDERED_NODE_SNAPSHOT_TYPE)throw new Me(Me.TYPE_ERR);return this.nodes[e]},Ae.ANY_TYPE=0,Ae.NUMBER_TYPE=1,Ae.STRING_TYPE=2,Ae.BOOLEAN_TYPE=3,Ae.UNORDERED_NODE_ITERATOR_TYPE=4,Ae.ORDERED_NODE_ITERATOR_TYPE=5,Ae.UNORDERED_NODE_SNAPSHOT_TYPE=6,Ae.ORDERED_NODE_SNAPSHOT_TYPE=7,Ae.ANY_UNORDERED_NODE_TYPE=8,Ae.FIRST_ORDERED_NODE_TYPE=9;function l(e,s){e.createExpression=function(d,E){try{return new Fe(d,E,s)}catch(h){throw new Me(Me.INVALID_EXPRESSION_ERR,h)}},e.createNSResolver=function(d){return new Ye(d)},e.evaluate=function(d,E,h,C,oe){if(C<0||C>9)throw{code:0,toString:function(){return"Request type not supported"}};return e.createExpression(d,h,s).evaluate(E,C,oe)}}try{var f=!0;try{document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("XPath",null)&&(f=!1)}catch{}f&&l(document,new A)}catch{}l(r,new A),function(){var e=new A,s=new je,d=new Pe,E=new Ge;function h(re){return{getNamespace:function(ve,Ue){var st=re(ve,Ue);return st||s.getNamespace(ve,Ue)}}}function C(re){return h(re.getNamespace.bind(re))}function oe(re){return h(function(ve){return re[ve]})}function xe(re){return re&&typeof re.getNamespace=="function"?C(re):typeof re=="function"?h(re):typeof re=="object"?oe(re):s}function Ne(re){if(re===null||typeof re>"u"||re instanceof O||re instanceof pe||re instanceof P||re instanceof ue)return re;switch(typeof re){case"string":return new O(re);case"boolean":return new pe(re);case"number":return new P(re)}var ve=new ue;return ve.addArray([].concat(re)),ve}function se(re){return function(ve){var Ue=Array.prototype.slice.call(arguments,1).map(function(ti){return ti.evaluate(ve)}),st=re.apply(this,[].concat(ve,Ue));return Ne(st)}}function ce(re){return{getFunction:function(ve,Ue){var st=re(ve,Ue);return st?se(st):d.getFunction(ve,Ue)}}}function Le(re){return ce(re.getFunction.bind(re))}function Ke(re){return ce(function(ve){return re[ve]})}function Se(re){return re&&typeof re.getFunction=="function"?Le(re):typeof re=="function"?ce(re):typeof re=="object"?Ke(re):d}function Qe(re){return{getVariable:function(ve,Ue){var st=re(ve,Ue);return Ne(st)}}}function Xe(re){if(re){if(typeof re.getVariable=="function")return Qe(re.getVariable.bind(re));if(typeof re=="function")return Qe(re);if(typeof re=="object")return Qe(function(ve){return re[ve]})}return E}function ot(re,ve,Ue){re in Ue&&(ve[re]=Ue[re])}function Qs(re){var ve=new He;return re?(ve.namespaceResolver=xe(re.namespaces),ve.functionResolver=Se(re.functions),ve.variableResolver=Xe(re.variables),ve.expressionContextNode=re.node,ot("allowAnyNamespaceForNoPrefix",ve,re),ot("isHtml",ve,re)):ve.namespaceResolver=s,ve}function Zs(re,ve){var Ue=Qs(ve);return re.evaluate(Ue)}var Js={evaluate:function(re){return Zs(this.expression,re)},evaluateNumber:function(re){return this.evaluate(re).numberValue()},evaluateString:function(re){return this.evaluate(re).stringValue()},evaluateBoolean:function(re){return this.evaluate(re).booleanValue()},evaluateNodeSet:function(re){return this.evaluate(re).nodeset()},select:function(re){return this.evaluateNodeSet(re).toArray()},select1:function(re){return this.select(re)[0]}};function ei(re){var ve=e.parse(re);return Object.create(Js,{expression:{value:ve}})}r.parse=ei}(),ee(r,{XPath:te,XPathParser:A,XPathResult:Ae,Step:z,PathExpr:R,NodeTest:y,LocationPath:De,OrOperation:de,AndOperation:he,BarOperation:Q,EqualsOperation:ye,NotEqualOperation:x,LessThanOperation:B,GreaterThanOperation:X,LessThanOrEqualOperation:Z,GreaterThanOrEqualOperation:F,PlusOperation:le,MinusOperation:w,MultiplyOperation:k,DivOperation:L,ModOperation:G,UnaryMinusOperation:W,FunctionCall:Ce,VariableReference:ne,XPathContext:He,XNodeSet:ue,XBoolean:pe,XString:O,XNumber:P,NamespaceResolver:je,FunctionResolver:Pe,VariableResolver:Ge,Utilities:fe}),r.select=function(e,s,d){return r.selectWithResolver(e,s,null,d)},r.useNamespaces=function(e){var s={mappings:e||{},lookupNamespaceURI:function(d){return this.mappings[d]}};return function(d,E,h){return r.selectWithResolver(d,E,s,h)}},r.selectWithResolver=function(e,s,d,E){var h=new Fe(e,d,new A),C=Ae.ANY_TYPE,oe=h.evaluate(s,C,null);return oe.resultType==Ae.STRING_TYPE?oe=oe.stringValue:oe.resultType==Ae.NUMBER_TYPE?oe=oe.numberValue:oe.resultType==Ae.BOOLEAN_TYPE?oe=oe.booleanValue:(oe=oe.nodes,E&&(oe=oe[0])),oe},r.select1=function(e,s){return r.select(e,s,!0)};var g=function(e){return Array.isArray(e)&&e.every(c)},S=function(e){return function(s){return c(s)&&s.nodeType===e}};ee(r,{isNodeLike:c,isArrayOfNodes:g,isElement:S(U.ELEMENT_NODE),isAttribute:S(U.ATTRIBUTE_NODE),isTextNode:S(U.TEXT_NODE),isCDATASection:S(U.CDATA_SECTION_NODE),isProcessingInstruction:S(U.PROCESSING_INSTRUCTION_NODE),isComment:S(U.COMMENT_NODE),isDocumentNode:S(U.DOCUMENT_NODE),isDocumentTypeNode:S(U.DOCUMENT_TYPE_NODE),isDocumentFragment:S(U.DOCUMENT_FRAGMENT_NODE)})})(t)}(vt)),vt}var nn=rn();const on=tn(nn);var dt={},Je={},it={},Pt;function yt(){if(Pt)return it;Pt=1;function n(u,c,b){if(b===void 0&&(b=Array.prototype),u&&typeof b.find=="function")return b.find.call(u,c);for(var p=0;p<u.length;p++)if(Object.prototype.hasOwnProperty.call(u,p)){var m=u[p];if(c.call(void 0,m,p,u))return m}}function t(u,c){return c===void 0&&(c=Object),c&&typeof c.freeze=="function"?c.freeze(u):u}function r(u,c){if(u===null||typeof u!="object")throw new TypeError("target is not an object");for(var b in c)Object.prototype.hasOwnProperty.call(c,b)&&(u[b]=c[b]);return u}var a=t({HTML:"text/html",isHTML:function(u){return u===a.HTML},XML_APPLICATION:"application/xml",XML_TEXT:"text/xml",XML_XHTML_APPLICATION:"application/xhtml+xml",XML_SVG_IMAGE:"image/svg+xml"}),i=t({HTML:"http://www.w3.org/1999/xhtml",isHTML:function(u){return u===i.HTML},SVG:"http://www.w3.org/2000/svg",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/"});return it.assign=r,it.find=n,it.freeze=t,it.MIME_TYPE=a,it.NAMESPACE=i,it}var Lt;function Vt(){if(Lt)return Je;Lt=1;var n=yt(),t=n.find,r=n.NAMESPACE;function a(l){return l!==""}function i(l){return l?l.split(/[\t\n\f\r ]+/).filter(a):[]}function u(l,f){return l.hasOwnProperty(f)||(l[f]=!0),l}function c(l){if(!l)return[];var f=i(l);return Object.keys(f.reduce(u,{}))}function b(l){return function(f){return l&&l.indexOf(f)!==-1}}function p(l,f){for(var g in l)Object.prototype.hasOwnProperty.call(l,g)&&(f[g]=l[g])}function m(l,f){var g=l.prototype;if(!(g instanceof f)){let S=function(){};S.prototype=f.prototype,S=new S,p(g,S),l.prototype=g=S}g.constructor!=l&&(typeof l!="function"&&console.error("unknown Class:"+l),g.constructor=l)}var _={},D=_.ELEMENT_NODE=1,V=_.ATTRIBUTE_NODE=2,j=_.TEXT_NODE=3,Y=_.CDATA_SECTION_NODE=4,ie=_.ENTITY_REFERENCE_NODE=5,v=_.ENTITY_NODE=6,H=_.PROCESSING_INSTRUCTION_NODE=7,K=_.COMMENT_NODE=8,$=_.DOCUMENT_NODE=9,ae=_.DOCUMENT_TYPE_NODE=10,ee=_.DOCUMENT_FRAGMENT_NODE=11,U=_.NOTATION_NODE=12,A={},te={};A.INDEX_SIZE_ERR=(te[1]="Index size error",1),A.DOMSTRING_SIZE_ERR=(te[2]="DOMString size error",2);var N=A.HIERARCHY_REQUEST_ERR=(te[3]="Hierarchy request error",3);A.WRONG_DOCUMENT_ERR=(te[4]="Wrong document",4),A.INVALID_CHARACTER_ERR=(te[5]="Invalid character",5),A.NO_DATA_ALLOWED_ERR=(te[6]="No data allowed",6),A.NO_MODIFICATION_ALLOWED_ERR=(te[7]="No modification allowed",7);var T=A.NOT_FOUND_ERR=(te[8]="Not found",8);A.NOT_SUPPORTED_ERR=(te[9]="Not supported",9);var q=A.INUSE_ATTRIBUTE_ERR=(te[10]="Attribute in use",10);A.INVALID_STATE_ERR=(te[11]="Invalid state",11),A.SYNTAX_ERR=(te[12]="Syntax error",12),A.INVALID_MODIFICATION_ERR=(te[13]="Invalid modification",13),A.NAMESPACE_ERR=(te[14]="Invalid namespace",14),A.INVALID_ACCESS_ERR=(te[15]="Invalid access",15);function W(l,f){if(f instanceof Error)var g=f;else g=this,Error.call(this,te[l]),this.message=te[l],Error.captureStackTrace&&Error.captureStackTrace(this,W);return g.code=l,f&&(this.message=this.message+": "+f),g}W.prototype=Error.prototype,p(A,W);function M(){}M.prototype={length:0,item:function(l){return l>=0&&l<this.length?this[l]:null},toString:function(l,f){for(var g=[],S=0;S<this.length;S++)Fe(this[S],g,l,f);return g.join("")},filter:function(l){return Array.prototype.filter.call(this,l)},indexOf:function(l){return Array.prototype.indexOf.call(this,l)}};function de(l,f){this._node=l,this._refresh=f,he(this)}function he(l){var f=l._node._inc||l._node.ownerDocument._inc;if(l._inc!==f){var g=l._refresh(l._node);if(Ae(l,"length",g.length),!l.$$length||g.length<l.$$length)for(var S=g.length;S in l;S++)Object.prototype.hasOwnProperty.call(l,S)&&delete l[S];p(g,l),l._inc=f}}de.prototype.item=function(l){return he(this),this[l]||null},m(de,M);function ye(){}function x(l,f){for(var g=l.length;g--;)if(l[g]===f)return g}function B(l,f,g,S){if(S?f[x(f,S)]=g:f[f.length++]=g,l){g.ownerElement=l;var e=l.ownerDocument;e&&(S&&G(e,l,S),L(e,l,g))}}function X(l,f,g){var S=x(f,g);if(S>=0){for(var e=f.length-1;S<e;)f[S]=f[++S];if(f.length=e,l){var s=l.ownerDocument;s&&(G(s,l,g),g.ownerElement=null)}}else throw new W(T,new Error(l.tagName+"@"+g))}ye.prototype={length:0,item:M.prototype.item,getNamedItem:function(l){for(var f=this.length;f--;){var g=this[f];if(g.nodeName==l)return g}},setNamedItem:function(l){var f=l.ownerElement;if(f&&f!=this._ownerElement)throw new W(q);var g=this.getNamedItem(l.nodeName);return B(this._ownerElement,this,l,g),g},setNamedItemNS:function(l){var f=l.ownerElement,g;if(f&&f!=this._ownerElement)throw new W(q);return g=this.getNamedItemNS(l.namespaceURI,l.localName),B(this._ownerElement,this,l,g),g},removeNamedItem:function(l){var f=this.getNamedItem(l);return X(this._ownerElement,this,f),f},removeNamedItemNS:function(l,f){var g=this.getNamedItemNS(l,f);return X(this._ownerElement,this,g),g},getNamedItemNS:function(l,f){for(var g=this.length;g--;){var S=this[g];if(S.localName==f&&S.namespaceURI==l)return S}return null}};function Z(){}Z.prototype={hasFeature:function(l,f){return!0},createDocument:function(l,f,g){var S=new k;if(S.implementation=this,S.childNodes=new M,S.doctype=g||null,g&&S.appendChild(g),f){var e=S.createElementNS(l,f);S.appendChild(e)}return S},createDocumentType:function(l,f,g){var S=new ue;return S.name=l,S.nodeName=l,S.publicId=f||"",S.systemId=g||"",S}};function F(){}F.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(l,f){return Ce(this,l,f)},replaceChild:function(l,f){Ce(this,l,f,ne),f&&this.removeChild(f)},removeChild:function(l){return R(this,l)},appendChild:function(l){return this.insertBefore(l,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(l){return Ye(this.ownerDocument||this,this,l)},normalize:function(){for(var l=this.firstChild;l;){var f=l.nextSibling;f&&f.nodeType==j&&l.nodeType==j?(this.removeChild(f),l.appendData(f.data)):(l.normalize(),l=f)}},isSupported:function(l,f){return this.ownerDocument.implementation.hasFeature(l,f)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(l){for(var f=this;f;){var g=f._nsMap;if(g){for(var S in g)if(Object.prototype.hasOwnProperty.call(g,S)&&g[S]===l)return S}f=f.nodeType==V?f.ownerDocument:f.parentNode}return null},lookupNamespaceURI:function(l){for(var f=this;f;){var g=f._nsMap;if(g&&Object.prototype.hasOwnProperty.call(g,l))return g[l];f=f.nodeType==V?f.ownerDocument:f.parentNode}return null},isDefaultNamespace:function(l){var f=this.lookupPrefix(l);return f==null}};function le(l){return l=="<"&&"&lt;"||l==">"&&"&gt;"||l=="&"&&"&amp;"||l=='"'&&"&quot;"||"&#"+l.charCodeAt()+";"}p(_,F),p(_,F.prototype);function w(l,f){if(f(l))return!0;if(l=l.firstChild)do if(w(l,f))return!0;while(l=l.nextSibling)}function k(){this.ownerDocument=this}function L(l,f,g){l&&l._inc++;var S=g.namespaceURI;S===r.XMLNS&&(f._nsMap[g.prefix?g.localName:""]=g.value)}function G(l,f,g,S){l&&l._inc++;var e=g.namespaceURI;e===r.XMLNS&&delete f._nsMap[g.prefix?g.localName:""]}function Q(l,f,g){if(l&&l._inc){l._inc++;var S=f.childNodes;if(g)S[S.length++]=g;else{for(var e=f.firstChild,s=0;e;)S[s++]=e,e=e.nextSibling;S.length=s,delete S[S.length]}}}function R(l,f){var g=f.previousSibling,S=f.nextSibling;return g?g.nextSibling=S:l.firstChild=S,S?S.previousSibling=g:l.lastChild=g,f.parentNode=null,f.previousSibling=null,f.nextSibling=null,Q(l.ownerDocument,l),f}function J(l){return l&&(l.nodeType===F.DOCUMENT_NODE||l.nodeType===F.DOCUMENT_FRAGMENT_NODE||l.nodeType===F.ELEMENT_NODE)}function ge(l){return l&&(_e(l)||ke(l)||Ee(l)||l.nodeType===F.DOCUMENT_FRAGMENT_NODE||l.nodeType===F.COMMENT_NODE||l.nodeType===F.PROCESSING_INSTRUCTION_NODE)}function Ee(l){return l&&l.nodeType===F.DOCUMENT_TYPE_NODE}function _e(l){return l&&l.nodeType===F.ELEMENT_NODE}function ke(l){return l&&l.nodeType===F.TEXT_NODE}function De(l,f){var g=l.childNodes||[];if(t(g,_e)||Ee(f))return!1;var S=t(g,Ee);return!(f&&S&&g.indexOf(S)>g.indexOf(f))}function z(l,f){var g=l.childNodes||[];function S(s){return _e(s)&&s!==f}if(t(g,S))return!1;var e=t(g,Ee);return!(f&&e&&g.indexOf(e)>g.indexOf(f))}function Be(l,f,g){if(!J(l))throw new W(N,"Unexpected parent node type "+l.nodeType);if(g&&g.parentNode!==l)throw new W(T,"child not in parent");if(!ge(f)||Ee(f)&&l.nodeType!==F.DOCUMENT_NODE)throw new W(N,"Unexpected node type "+f.nodeType+" for parent node type "+l.nodeType)}function y(l,f,g){var S=l.childNodes||[],e=f.childNodes||[];if(f.nodeType===F.DOCUMENT_FRAGMENT_NODE){var s=e.filter(_e);if(s.length>1||t(e,ke))throw new W(N,"More than one element or text in fragment");if(s.length===1&&!De(l,g))throw new W(N,"Element in fragment can not be inserted before doctype")}if(_e(f)&&!De(l,g))throw new W(N,"Only one element can be added and only after doctype");if(Ee(f)){if(t(S,Ee))throw new W(N,"Only one doctype is allowed");var d=t(S,_e);if(g&&S.indexOf(d)<S.indexOf(g))throw new W(N,"Doctype can only be inserted before an element");if(!g&&d)throw new W(N,"Doctype can not be appended since element is present")}}function ne(l,f,g){var S=l.childNodes||[],e=f.childNodes||[];if(f.nodeType===F.DOCUMENT_FRAGMENT_NODE){var s=e.filter(_e);if(s.length>1||t(e,ke))throw new W(N,"More than one element or text in fragment");if(s.length===1&&!z(l,g))throw new W(N,"Element in fragment can not be inserted before doctype")}if(_e(f)&&!z(l,g))throw new W(N,"Only one element can be added and only after doctype");if(Ee(f)){if(t(S,function(h){return Ee(h)&&h!==g}))throw new W(N,"Only one doctype is allowed");var d=t(S,_e);if(g&&S.indexOf(d)<S.indexOf(g))throw new W(N,"Doctype can only be inserted before an element")}}function Ce(l,f,g,S){Be(l,f,g),l.nodeType===F.DOCUMENT_NODE&&(S||y)(l,f,g);var e=f.parentNode;if(e&&e.removeChild(f),f.nodeType===ee){var s=f.firstChild;if(s==null)return f;var d=f.lastChild}else s=d=f;var E=g?g.previousSibling:l.lastChild;s.previousSibling=E,d.nextSibling=g,E?E.nextSibling=s:l.firstChild=s,g==null?l.lastChild=d:g.previousSibling=d;do{s.parentNode=l;var h=l.ownerDocument||l;be(s,h)}while(s!==d&&(s=s.nextSibling));return Q(l.ownerDocument||l,l),f.nodeType==ee&&(f.firstChild=f.lastChild=null),f}function be(l,f){if(l.ownerDocument!==f){if(l.ownerDocument=f,l.nodeType===D&&l.attributes)for(var g=0;g<l.attributes.length;g++){var S=l.attributes.item(g);S&&(S.ownerDocument=f)}for(var e=l.firstChild;e;)be(e,f),e=e.nextSibling}}function O(l,f){f.parentNode&&f.parentNode.removeChild(f),f.parentNode=l,f.previousSibling=l.lastChild,f.nextSibling=null,f.previousSibling?f.previousSibling.nextSibling=f:l.firstChild=f,l.lastChild=f,Q(l.ownerDocument,l,f);var g=l.ownerDocument||l;return be(f,g),f}k.prototype={nodeName:"#document",nodeType:$,doctype:null,documentElement:null,_inc:1,insertBefore:function(l,f){if(l.nodeType==ee){for(var g=l.firstChild;g;){var S=g.nextSibling;this.insertBefore(g,f),g=S}return l}return Ce(this,l,f),be(l,this),this.documentElement===null&&l.nodeType===D&&(this.documentElement=l),l},removeChild:function(l){return this.documentElement==l&&(this.documentElement=null),R(this,l)},replaceChild:function(l,f){Ce(this,l,f,ne),be(l,this),f&&this.removeChild(f),_e(l)&&(this.documentElement=l)},importNode:function(l,f){return tt(this,l,f)},getElementById:function(l){var f=null;return w(this.documentElement,function(g){if(g.nodeType==D&&g.getAttribute("id")==l)return f=g,!0}),f},getElementsByClassName:function(l){var f=c(l);return new de(this,function(g){var S=[];return f.length>0&&w(g.documentElement,function(e){if(e!==g&&e.nodeType===D){var s=e.getAttribute("class");if(s){var d=l===s;if(!d){var E=c(s);d=f.every(b(E))}d&&S.push(e)}}}),S})},createElement:function(l){var f=new P;f.ownerDocument=this,f.nodeName=l,f.tagName=l,f.localName=l,f.childNodes=new M;var g=f.attributes=new ye;return g._ownerElement=f,f},createDocumentFragment:function(){var l=new Pe;return l.ownerDocument=this,l.childNodes=new M,l},createTextNode:function(l){var f=new pe;return f.ownerDocument=this,f.appendData(l),f},createComment:function(l){var f=new Ie;return f.ownerDocument=this,f.appendData(l),f},createCDATASection:function(l){var f=new gt;return f.ownerDocument=this,f.appendData(l),f},createProcessingInstruction:function(l,f){var g=new je;return g.ownerDocument=this,g.tagName=g.nodeName=g.target=l,g.nodeValue=g.data=f,g},createAttribute:function(l){var f=new Re;return f.ownerDocument=this,f.name=l,f.nodeName=l,f.localName=l,f.specified=!0,f},createEntityReference:function(l){var f=new Ge;return f.ownerDocument=this,f.nodeName=l,f},createElementNS:function(l,f){var g=new P,S=f.split(":"),e=g.attributes=new ye;return g.childNodes=new M,g.ownerDocument=this,g.nodeName=f,g.tagName=f,g.namespaceURI=l,S.length==2?(g.prefix=S[0],g.localName=S[1]):g.localName=f,e._ownerElement=g,g},createAttributeNS:function(l,f){var g=new Re,S=f.split(":");return g.ownerDocument=this,g.nodeName=f,g.name=f,g.namespaceURI=l,g.specified=!0,S.length==2?(g.prefix=S[0],g.localName=S[1]):g.localName=f,g}},m(k,F);function P(){this._nsMap={}}P.prototype={nodeType:D,hasAttribute:function(l){return this.getAttributeNode(l)!=null},getAttribute:function(l){var f=this.getAttributeNode(l);return f&&f.value||""},getAttributeNode:function(l){return this.attributes.getNamedItem(l)},setAttribute:function(l,f){var g=this.ownerDocument.createAttribute(l);g.value=g.nodeValue=""+f,this.setAttributeNode(g)},removeAttribute:function(l){var f=this.getAttributeNode(l);f&&this.removeAttributeNode(f)},appendChild:function(l){return l.nodeType===ee?this.insertBefore(l,null):O(this,l)},setAttributeNode:function(l){return this.attributes.setNamedItem(l)},setAttributeNodeNS:function(l){return this.attributes.setNamedItemNS(l)},removeAttributeNode:function(l){return this.attributes.removeNamedItem(l.nodeName)},removeAttributeNS:function(l,f){var g=this.getAttributeNodeNS(l,f);g&&this.removeAttributeNode(g)},hasAttributeNS:function(l,f){return this.getAttributeNodeNS(l,f)!=null},getAttributeNS:function(l,f){var g=this.getAttributeNodeNS(l,f);return g&&g.value||""},setAttributeNS:function(l,f,g){var S=this.ownerDocument.createAttributeNS(l,f);S.value=S.nodeValue=""+g,this.setAttributeNode(S)},getAttributeNodeNS:function(l,f){return this.attributes.getNamedItemNS(l,f)},getElementsByTagName:function(l){return new de(this,function(f){var g=[];return w(f,function(S){S!==f&&S.nodeType==D&&(l==="*"||S.tagName==l)&&g.push(S)}),g})},getElementsByTagNameNS:function(l,f){return new de(this,function(g){var S=[];return w(g,function(e){e!==g&&e.nodeType===D&&(l==="*"||e.namespaceURI===l)&&(f==="*"||e.localName==f)&&S.push(e)}),S})}},k.prototype.getElementsByTagName=P.prototype.getElementsByTagName,k.prototype.getElementsByTagNameNS=P.prototype.getElementsByTagNameNS,m(P,F);function Re(){}Re.prototype.nodeType=V,m(Re,F);function qe(){}qe.prototype={data:"",substringData:function(l,f){return this.data.substring(l,l+f)},appendData:function(l){l=this.data+l,this.nodeValue=this.data=l,this.length=l.length},insertData:function(l,f){this.replaceData(l,0,f)},appendChild:function(l){throw new Error(te[N])},deleteData:function(l,f){this.replaceData(l,f,"")},replaceData:function(l,f,g){var S=this.data.substring(0,l),e=this.data.substring(l+f);g=S+g+e,this.nodeValue=this.data=g,this.length=g.length}},m(qe,F);function pe(){}pe.prototype={nodeName:"#text",nodeType:j,splitText:function(l){var f=this.data,g=f.substring(l);f=f.substring(0,l),this.data=this.nodeValue=f,this.length=f.length;var S=this.ownerDocument.createTextNode(g);return this.parentNode&&this.parentNode.insertBefore(S,this.nextSibling),S}},m(pe,qe);function Ie(){}Ie.prototype={nodeName:"#comment",nodeType:K},m(Ie,qe);function gt(){}gt.prototype={nodeName:"#cdata-section",nodeType:Y},m(gt,qe);function ue(){}ue.prototype.nodeType=ae,m(ue,F);function We(){}We.prototype.nodeType=U,m(We,F);function He(){}He.prototype.nodeType=v,m(He,F);function Ge(){}Ge.prototype.nodeType=ie,m(Ge,F);function Pe(){}Pe.prototype.nodeName="#document-fragment",Pe.prototype.nodeType=ee,m(Pe,F);function je(){}je.prototype.nodeType=H,m(je,F);function me(){}me.prototype.serializeToString=function(l,f,g){return fe.call(l,f,g)},F.prototype.toString=fe;function fe(l,f){var g=[],S=this.nodeType==9&&this.documentElement||this,e=S.prefix,s=S.namespaceURI;if(s&&e==null){var e=S.lookupPrefix(s);if(e==null)var d=[{namespace:s,prefix:null}]}return Fe(this,g,l,f,d),g.join("")}function Et(l,f,g){var S=l.prefix||"",e=l.namespaceURI;if(!e||S==="xml"&&e===r.XML||e===r.XMLNS)return!1;for(var s=g.length;s--;){var d=g[s];if(d.prefix===S)return d.namespace!==e}return!0}function Me(l,f,g){l.push(" ",f,'="',g.replace(/[<>&"\t\n\r]/g,le),'"')}function Fe(l,f,g,S,e){if(e||(e=[]),S)if(l=S(l),l){if(typeof l=="string"){f.push(l);return}}else return;switch(l.nodeType){case D:var s=l.attributes,d=s.length,Se=l.firstChild,E=l.tagName;g=r.isHTML(l.namespaceURI)||g;var h=E;if(!g&&!l.prefix&&l.namespaceURI){for(var C,oe=0;oe<s.length;oe++)if(s.item(oe).name==="xmlns"){C=s.item(oe).value;break}if(!C)for(var xe=e.length-1;xe>=0;xe--){var Ne=e[xe];if(Ne.prefix===""&&Ne.namespace===l.namespaceURI){C=Ne.namespace;break}}if(C!==l.namespaceURI)for(var xe=e.length-1;xe>=0;xe--){var Ne=e[xe];if(Ne.namespace===l.namespaceURI){Ne.prefix&&(h=Ne.prefix+":"+E);break}}}f.push("<",h);for(var se=0;se<d;se++){var ce=s.item(se);ce.prefix=="xmlns"?e.push({prefix:ce.localName,namespace:ce.value}):ce.nodeName=="xmlns"&&e.push({prefix:"",namespace:ce.value})}for(var se=0;se<d;se++){var ce=s.item(se);if(Et(ce,g,e)){var Le=ce.prefix||"",Ke=ce.namespaceURI;Me(f,Le?"xmlns:"+Le:"xmlns",Ke),e.push({prefix:Le,namespace:Ke})}Fe(ce,f,g,S,e)}if(E===h&&Et(l,g,e)){var Le=l.prefix||"",Ke=l.namespaceURI;Me(f,Le?"xmlns:"+Le:"xmlns",Ke),e.push({prefix:Le,namespace:Ke})}if(Se||g&&!/^(?:meta|link|img|br|hr|input)$/i.test(E)){if(f.push(">"),g&&/^script$/i.test(E))for(;Se;)Se.data?f.push(Se.data):Fe(Se,f,g,S,e.slice()),Se=Se.nextSibling;else for(;Se;)Fe(Se,f,g,S,e.slice()),Se=Se.nextSibling;f.push("</",h,">")}else f.push("/>");return;case $:case ee:for(var Se=l.firstChild;Se;)Fe(Se,f,g,S,e.slice()),Se=Se.nextSibling;return;case V:return Me(f,l.name,l.value);case j:return f.push(l.data.replace(/[<&>]/g,le));case Y:return f.push("<![CDATA[",l.data,"]]>");case K:return f.push("<!--",l.data,"-->");case ae:var Qe=l.publicId,Xe=l.systemId;if(f.push("<!DOCTYPE ",l.name),Qe)f.push(" PUBLIC ",Qe),Xe&&Xe!="."&&f.push(" ",Xe),f.push(">");else if(Xe&&Xe!=".")f.push(" SYSTEM ",Xe,">");else{var ot=l.internalSubset;ot&&f.push(" [",ot,"]"),f.push(">")}return;case H:return f.push("<?",l.target," ",l.data,"?>");case ie:return f.push("&",l.nodeName,";");default:f.push("??",l.nodeName)}}function tt(l,f,g){var S;switch(f.nodeType){case D:S=f.cloneNode(!1),S.ownerDocument=l;case ee:break;case V:g=!0;break}if(S||(S=f.cloneNode(!1)),S.ownerDocument=l,S.parentNode=null,g)for(var e=f.firstChild;e;)S.appendChild(tt(l,e,g)),e=e.nextSibling;return S}function Ye(l,f,g){var S=new f.constructor;for(var e in f)if(Object.prototype.hasOwnProperty.call(f,e)){var s=f[e];typeof s!="object"&&s!=S[e]&&(S[e]=s)}switch(f.childNodes&&(S.childNodes=new M),S.ownerDocument=l,S.nodeType){case D:var d=f.attributes,E=S.attributes=new ye,h=d.length;E._ownerElement=S;for(var C=0;C<h;C++)S.setAttributeNode(Ye(l,d.item(C),!0));break;case V:g=!0}if(g)for(var oe=f.firstChild;oe;)S.appendChild(Ye(l,oe,g)),oe=oe.nextSibling;return S}function Ae(l,f,g){l[f]=g}try{if(Object.defineProperty){let l=function(f){switch(f.nodeType){case D:case ee:var g=[];for(f=f.firstChild;f;)f.nodeType!==7&&f.nodeType!==8&&g.push(l(f)),f=f.nextSibling;return g.join("");default:return f.nodeValue}};Object.defineProperty(de.prototype,"length",{get:function(){return he(this),this.$$length}}),Object.defineProperty(F.prototype,"textContent",{get:function(){return l(this)},set:function(f){switch(this.nodeType){case D:case ee:for(;this.firstChild;)this.removeChild(this.firstChild);(f||String(f))&&this.appendChild(this.ownerDocument.createTextNode(f));break;default:this.data=f,this.value=f,this.nodeValue=f}}}),Ae=function(f,g,S){f["$$"+g]=S}}}catch{}return Je.DocumentType=ue,Je.DOMException=W,Je.DOMImplementation=Z,Je.Element=P,Je.Node=F,Je.NodeList=M,Je.XMLSerializer=me,Je}var pt={},wt={},$t;function sn(){return $t||($t=1,function(n){var t=yt().freeze;n.XML_ENTITIES=t({amp:"&",apos:"'",gt:">",lt:"<",quot:'"'}),n.HTML_ENTITIES=t({Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"⁡",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",AMP:"&",amp:"&",And:"⩓",and:"∧",andand:"⩕",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsd:"∡",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",ap:"≈",apacir:"⩯",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",Barwed:"⌆",barwed:"⌅",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",Because:"∵",because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxDL:"╗",boxDl:"╖",boxdL:"╕",boxdl:"┐",boxDR:"╔",boxDr:"╓",boxdR:"╒",boxdr:"┌",boxH:"═",boxh:"─",boxHD:"╦",boxHd:"╤",boxhD:"╥",boxhd:"┬",boxHU:"╩",boxHu:"╧",boxhU:"╨",boxhu:"┴",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxUL:"╝",boxUl:"╜",boxuL:"╛",boxul:"┘",boxUR:"╚",boxUr:"╙",boxuR:"╘",boxur:"└",boxV:"║",boxv:"│",boxVH:"╬",boxVh:"╫",boxvH:"╪",boxvh:"┼",boxVL:"╣",boxVl:"╢",boxvL:"╡",boxvl:"┤",boxVR:"╠",boxVr:"╟",boxvR:"╞",boxvr:"├",bprime:"‵",Breve:"˘",breve:"˘",brvbar:"¦",Bscr:"ℬ",bscr:"𝒷",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsol:"\\",bsolb:"⧅",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",Cap:"⋒",cap:"∩",capand:"⩄",capbrcup:"⩉",capcap:"⩋",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",CenterDot:"·",centerdot:"·",Cfr:"ℭ",cfr:"𝔠",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",cir:"○",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",Colon:"∷",colon:":",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",Conint:"∯",conint:"∮",ContourIntegral:"∮",Copf:"ℂ",copf:"𝕔",coprod:"∐",Coproduct:"∐",COPY:"©",copy:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",Cross:"⨯",cross:"✗",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",Cup:"⋓",cup:"∪",cupbrcap:"⩈",CupCap:"≍",cupcap:"⩆",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",Dagger:"‡",dagger:"†",daleth:"ℸ",Darr:"↡",dArr:"⇓",darr:"↓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",DD:"ⅅ",dd:"ⅆ",ddagger:"‡",ddarr:"⇊",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",Diamond:"⋄",diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrow:"↓",Downarrow:"⇓",downarrow:"↓",DownArrowBar:"⤓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVector:"↽",DownLeftVectorBar:"⥖",DownRightTeeVector:"⥟",DownRightVector:"⇁",DownRightVectorBar:"⥗",DownTee:"⊤",DownTeeArrow:"↧",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",ecir:"≖",Ecirc:"Ê",ecirc:"ê",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",eDot:"≑",edot:"ė",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp:" ",emsp13:" ",emsp14:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",Escr:"ℰ",escr:"ℯ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",ExponentialE:"ⅇ",exponentiale:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",ForAll:"∀",forall:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",Fscr:"ℱ",fscr:"𝒻",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",gE:"≧",ge:"≥",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",ges:"⩾",gescc:"⪩",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",Gg:"⋙",gg:"≫",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gl:"≷",gla:"⪥",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gnE:"≩",gne:"⪈",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",Gt:"≫",GT:">",gt:">",gtcc:"⪧",gtcir:"⩺",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",hArr:"⇔",harr:"↔",harrcir:"⥈",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",Hfr:"ℌ",hfr:"𝔥",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",Hopf:"ℍ",hopf:"𝕙",horbar:"―",HorizontalLine:"─",Hscr:"ℋ",hscr:"𝒽",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"⁣",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",Ifr:"ℑ",ifr:"𝔦",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Im:"ℑ",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",imof:"⊷",imped:"Ƶ",Implies:"⇒",in:"∈",incare:"℅",infin:"∞",infintie:"⧝",inodot:"ı",Int:"∬",int:"∫",intcal:"⊺",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",Iscr:"ℐ",iscr:"𝒾",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",Lang:"⟪",lang:"⟨",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",Larr:"↞",lArr:"⇐",larr:"←",larrb:"⇤",larrbfs:"⤟",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",lat:"⪫",lAtail:"⤛",latail:"⤙",late:"⪭",lates:"⪭︀",lBarr:"⤎",lbarr:"⤌",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",lE:"≦",le:"≤",LeftAngleBracket:"⟨",LeftArrow:"←",Leftarrow:"⇐",leftarrow:"←",LeftArrowBar:"⇤",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVector:"⇃",LeftDownVectorBar:"⥙",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrow:"↔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTee:"⊣",LeftTeeArrow:"↤",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangle:"⊲",LeftTriangleBar:"⧏",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVector:"↿",LeftUpVectorBar:"⥘",LeftVector:"↼",LeftVectorBar:"⥒",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",les:"⩽",lescc:"⪨",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",Ll:"⋘",ll:"≪",llarr:"⇇",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoust:"⎰",lmoustache:"⎰",lnap:"⪉",lnapprox:"⪉",lnE:"≨",lne:"⪇",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftarrow:"⟵",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longleftrightarrow:"⟷",longmapsto:"⟼",LongRightArrow:"⟶",Longrightarrow:"⟹",longrightarrow:"⟶",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",Lscr:"ℒ",lscr:"𝓁",Lsh:"↰",lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",Lt:"≪",LT:"<",lt:"<",ltcc:"⪦",ltcir:"⩹",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",mid:"∣",midast:"*",midcir:"⫰",middot:"·",minus:"−",minusb:"⊟",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",Mscr:"ℳ",mscr:"𝓂",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natur:"♮",natural:"♮",naturals:"ℕ",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",ne:"≠",nearhk:"⤤",neArr:"⇗",nearr:"↗",nearrow:"↗",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:`
10
+ `,nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nhArr:"⇎",nharr:"↮",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlArr:"⇍",nlarr:"↚",nldr:"‥",nlE:"≦̸",nle:"≰",nLeftarrow:"⇍",nleftarrow:"↚",nLeftrightarrow:"⇎",nleftrightarrow:"↮",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",Nopf:"ℕ",nopf:"𝕟",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangle:"⋪",NotLeftTriangleBar:"⧏̸",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangle:"⋫",NotRightTriangleBar:"⧐̸",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",npar:"∦",nparallel:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",npre:"⪯̸",nprec:"⊀",npreceq:"⪯̸",nrArr:"⇏",nrarr:"↛",nrarrc:"⤳̸",nrarrw:"↝̸",nRightarrow:"⇏",nrightarrow:"↛",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nVDash:"⊯",nVdash:"⊮",nvDash:"⊭",nvdash:"⊬",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwArr:"⇖",nwarr:"↖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",ocir:"⊚",Ocirc:"Ô",ocirc:"ô",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",Or:"⩔",or:"∨",orarr:"↻",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",Otimes:"⨷",otimes:"⊗",otimesas:"⨶",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",par:"∥",para:"¶",parallel:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plus:"+",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",Popf:"ℙ",popf:"𝕡",pound:"£",Pr:"⪻",pr:"≺",prap:"⪷",prcue:"≼",prE:"⪳",pre:"⪯",prec:"≺",precapprox:"⪷",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",precsim:"≾",Prime:"″",prime:"′",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportion:"∷",Proportional:"∝",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",Qopf:"ℚ",qopf:"𝕢",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",QUOT:'"',quot:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",Rang:"⟫",rang:"⟩",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",Rarr:"↠",rArr:"⇒",rarr:"→",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",rAtail:"⤜",ratail:"⤚",ratio:"∶",rationals:"ℚ",RBarr:"⤐",rBarr:"⤏",rbarr:"⤍",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",Re:"ℜ",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",rect:"▭",REG:"®",reg:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",Rfr:"ℜ",rfr:"𝔯",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrow:"→",Rightarrow:"⇒",rightarrow:"→",RightArrowBar:"⇥",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVector:"⇂",RightDownVectorBar:"⥕",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTee:"⊢",RightTeeArrow:"↦",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangle:"⊳",RightTriangleBar:"⧐",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVector:"↾",RightUpVectorBar:"⥔",RightVector:"⇀",RightVectorBar:"⥓",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoust:"⎱",rmoustache:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",Ropf:"ℝ",ropf:"𝕣",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",Rscr:"ℛ",rscr:"𝓇",Rsh:"↱",rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",Sc:"⪼",sc:"≻",scap:"⪸",Scaron:"Š",scaron:"š",sccue:"≽",scE:"⪴",sce:"⪰",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdot:"⋅",sdotb:"⊡",sdote:"⩦",searhk:"⤥",seArr:"⇘",searr:"↘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",sol:"/",solb:"⧄",solbar:"⌿",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",squ:"□",Square:"□",square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",Sub:"⋐",sub:"⊂",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",Subset:"⋐",subset:"⊂",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succ:"≻",succapprox:"⪸",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",Sum:"∑",sum:"∑",sung:"♪",Sup:"⋑",sup:"⊃",sup1:"¹",sup2:"²",sup3:"³",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",Supset:"⋑",supset:"⊃",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swArr:"⇙",swarr:"↙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:" ",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",Therefore:"∴",therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",thinsp:" ",ThinSpace:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",Tilde:"∼",tilde:"˜",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",times:"×",timesb:"⊠",timesbar:"⨱",timesd:"⨰",tint:"∭",toea:"⤨",top:"⊤",topbot:"⌶",topcir:"⫱",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",TRADE:"™",trade:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",Uarr:"↟",uArr:"⇑",uarr:"↑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrow:"↑",Uparrow:"⇑",uparrow:"↑",UpArrowBar:"⤒",UpArrowDownArrow:"⇅",UpDownArrow:"↕",Updownarrow:"⇕",updownarrow:"↕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",Upsi:"ϒ",upsi:"υ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTee:"⊥",UpTeeArrow:"↥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",vArr:"⇕",varr:"↕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",Vbar:"⫫",vBar:"⫨",vBarv:"⫩",Vcy:"В",vcy:"в",VDash:"⊫",Vdash:"⊩",vDash:"⊨",vdash:"⊢",Vdashl:"⫦",Vee:"⋁",vee:"∨",veebar:"⊻",veeeq:"≚",vellip:"⋮",Verbar:"‖",verbar:"|",Vert:"‖",vert:"|",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",Wedge:"⋀",wedge:"∧",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xhArr:"⟺",xharr:"⟷",Xi:"Ξ",xi:"ξ",xlArr:"⟸",xlarr:"⟵",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrArr:"⟹",xrarr:"⟶",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",Yuml:"Ÿ",yuml:"ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"​",Zeta:"Ζ",zeta:"ζ",Zfr:"ℨ",zfr:"𝔷",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",Zopf:"ℤ",zopf:"𝕫",Zscr:"𝒵",zscr:"𝓏",zwj:"‍",zwnj:"‌"}),n.entityMap=n.HTML_ENTITIES}(wt)),wt}var bt={},Mt;function an(){if(Mt)return bt;Mt=1;var n=yt().NAMESPACE,t=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,r=new RegExp("[\\-\\.0-9"+t.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),a=new RegExp("^"+t.source+r.source+"*(?::"+t.source+r.source+"*)?$"),i=0,u=1,c=2,b=3,p=4,m=5,_=6,D=7;function V(N,T){this.message=N,this.locator=T,Error.captureStackTrace&&Error.captureStackTrace(this,V)}V.prototype=new Error,V.prototype.name=V.name;function j(){}j.prototype={parse:function(N,T,q){var W=this.domBuilder;W.startDocument(),ae(T,T={}),Y(N,T,q,W,this.errorHandler),W.endDocument()}};function Y(N,T,q,W,M){function de(O){if(O>65535){O-=65536;var P=55296+(O>>10),Re=56320+(O&1023);return String.fromCharCode(P,Re)}else return String.fromCharCode(O)}function he(O){var P=O.slice(1,-1);return Object.hasOwnProperty.call(q,P)?q[P]:P.charAt(0)==="#"?de(parseInt(P.substr(1).replace("x","0x"))):(M.error("entity not found:"+O),O)}function ye(O){if(O>k){var P=N.substring(k,O).replace(/&#?\w+;/g,he);F&&x(k),W.characters(P,0,O-k),k=O}}function x(O,P){for(;O>=X&&(P=Z.exec(N));)B=P.index,X=B+P[0].length,F.lineNumber++;F.columnNumber=O-B+1}for(var B=0,X=0,Z=/.*(?:\r\n?|\n)|.*$/g,F=W.locator,le=[{currentNSMap:T}],w={},k=0;;){try{var L=N.indexOf("<",k);if(L<0){if(!N.substr(k).match(/^\s*$/)){var G=W.doc,Q=G.createTextNode(N.substr(k));G.appendChild(Q),W.currentElement=Q}return}switch(L>k&&ye(L),N.charAt(L+1)){case"/":var Be=N.indexOf(">",L+3),R=N.substring(L+2,Be).replace(/[ \t\n\r]+$/g,""),J=le.pop();Be<0?(R=N.substring(L+2).replace(/[\s<].*/,""),M.error("end tag name: "+R+" is not complete:"+J.tagName),Be=L+1+R.length):R.match(/\s</)&&(R=R.replace(/[\s<].*/,""),M.error("end tag name: "+R+" maybe not complete"),Be=L+1+R.length);var ge=J.localNSMap,Ee=J.tagName==R,_e=Ee||J.tagName&&J.tagName.toLowerCase()==R.toLowerCase();if(_e){if(W.endElement(J.uri,J.localName,R),ge)for(var ke in ge)Object.prototype.hasOwnProperty.call(ge,ke)&&W.endPrefixMapping(ke);Ee||M.fatalError("end tag name: "+R+" is not match the current start tagName:"+J.tagName)}else le.push(J);Be++;break;case"?":F&&x(L),Be=U(N,L,W);break;case"!":F&&x(L),Be=ee(N,L,W,M);break;default:F&&x(L);var De=new A,z=le[le.length-1].currentNSMap,Be=v(N,L,De,z,he,M),y=De.length;if(!De.closed&&$(N,Be,De.tagName,w)&&(De.closed=!0,q.nbsp||M.warning("unclosed xml attribute")),F&&y){for(var ne=ie(F,{}),Ce=0;Ce<y;Ce++){var be=De[Ce];x(be.offset),be.locator=ie(F,{})}W.locator=ne,H(De,W,z)&&le.push(De),W.locator=F}else H(De,W,z)&&le.push(De);n.isHTML(De.uri)&&!De.closed?Be=K(N,Be,De.tagName,he,W):Be++}}catch(O){if(O instanceof V)throw O;M.error("element parse error: "+O),Be=-1}Be>k?k=Be:ye(Math.max(L,k)+1)}}function ie(N,T){return T.lineNumber=N.lineNumber,T.columnNumber=N.columnNumber,T}function v(N,T,q,W,M,de){function he(F,le,w){q.attributeNames.hasOwnProperty(F)&&de.fatalError("Attribute "+F+" redefined"),q.addValue(F,le.replace(/[\t\n\r]/g," ").replace(/&#?\w+;/g,M),w)}for(var ye,x,B=++T,X=i;;){var Z=N.charAt(B);switch(Z){case"=":if(X===u)ye=N.slice(T,B),X=b;else if(X===c)X=b;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(X===b||X===u)if(X===u&&(de.warning('attribute value must after "="'),ye=N.slice(T,B)),T=B+1,B=N.indexOf(Z,T),B>0)x=N.slice(T,B),he(ye,x,T-1),X=m;else throw new Error("attribute value no end '"+Z+"' match");else if(X==p)x=N.slice(T,B),he(ye,x,T),de.warning('attribute "'+ye+'" missed start quot('+Z+")!!"),T=B+1,X=m;else throw new Error('attribute value must after "="');break;case"/":switch(X){case i:q.setTagName(N.slice(T,B));case m:case _:case D:X=D,q.closed=!0;case p:case u:break;case c:q.closed=!0;break;default:throw new Error("attribute invalid close char('/')")}break;case"":return de.error("unexpected end of input"),X==i&&q.setTagName(N.slice(T,B)),B;case">":switch(X){case i:q.setTagName(N.slice(T,B));case m:case _:case D:break;case p:case u:x=N.slice(T,B),x.slice(-1)==="/"&&(q.closed=!0,x=x.slice(0,-1));case c:X===c&&(x=ye),X==p?(de.warning('attribute "'+x+'" missed quot(")!'),he(ye,x,T)):((!n.isHTML(W[""])||!x.match(/^(?:disabled|checked|selected)$/i))&&de.warning('attribute "'+x+'" missed value!! "'+x+'" instead!!'),he(x,x,T));break;case b:throw new Error("attribute value missed!!")}return B;case"€":Z=" ";default:if(Z<=" ")switch(X){case i:q.setTagName(N.slice(T,B)),X=_;break;case u:ye=N.slice(T,B),X=c;break;case p:var x=N.slice(T,B);de.warning('attribute "'+x+'" missed quot(")!!'),he(ye,x,T);case m:X=_;break}else switch(X){case c:q.tagName,(!n.isHTML(W[""])||!ye.match(/^(?:disabled|checked|selected)$/i))&&de.warning('attribute "'+ye+'" missed value!! "'+ye+'" instead2!!'),he(ye,ye,T),T=B,X=u;break;case m:de.warning('attribute space is required"'+ye+'"!!');case _:X=u,T=B;break;case b:X=p,T=B;break;case D:throw new Error("elements closed character '/' and '>' must be connected to")}}B++}}function H(N,T,q){for(var W=N.tagName,M=null,Z=N.length;Z--;){var de=N[Z],he=de.qName,ye=de.value,F=he.indexOf(":");if(F>0)var x=de.prefix=he.slice(0,F),B=he.slice(F+1),X=x==="xmlns"&&B;else B=he,x=null,X=he==="xmlns"&&"";de.localName=B,X!==!1&&(M==null&&(M={},ae(q,q={})),q[X]=M[X]=ye,de.uri=n.XMLNS,T.startPrefixMapping(X,ye))}for(var Z=N.length;Z--;){de=N[Z];var x=de.prefix;x&&(x==="xml"&&(de.uri=n.XML),x!=="xmlns"&&(de.uri=q[x||""]))}var F=W.indexOf(":");F>0?(x=N.prefix=W.slice(0,F),B=N.localName=W.slice(F+1)):(x=null,B=N.localName=W);var le=N.uri=q[x||""];if(T.startElement(le,B,W,N),N.closed){if(T.endElement(le,B,W),M)for(x in M)Object.prototype.hasOwnProperty.call(M,x)&&T.endPrefixMapping(x)}else return N.currentNSMap=q,N.localNSMap=M,!0}function K(N,T,q,W,M){if(/^(?:script|textarea)$/i.test(q)){var de=N.indexOf("</"+q+">",T),he=N.substring(T+1,de);if(/[&<]/.test(he))return/^script$/i.test(q)?(M.characters(he,0,he.length),de):(he=he.replace(/&#?\w+;/g,W),M.characters(he,0,he.length),de)}return T+1}function $(N,T,q,W){var M=W[q];return M==null&&(M=N.lastIndexOf("</"+q+">"),M<T&&(M=N.lastIndexOf("</"+q)),W[q]=M),M<T}function ae(N,T){for(var q in N)Object.prototype.hasOwnProperty.call(N,q)&&(T[q]=N[q])}function ee(N,T,q,W){var M=N.charAt(T+2);switch(M){case"-":if(N.charAt(T+3)==="-"){var de=N.indexOf("-->",T+4);return de>T?(q.comment(N,T+4,de-T-4),de+3):(W.error("Unclosed comment"),-1)}else return-1;default:if(N.substr(T+3,6)=="CDATA["){var de=N.indexOf("]]>",T+9);return q.startCDATA(),q.characters(N,T+9,de-T-9),q.endCDATA(),de+3}var he=te(N,T),ye=he.length;if(ye>1&&/!doctype/i.test(he[0][0])){var x=he[1][0],B=!1,X=!1;ye>3&&(/^public$/i.test(he[2][0])?(B=he[3][0],X=ye>4&&he[4][0]):/^system$/i.test(he[2][0])&&(X=he[3][0]));var Z=he[ye-1];return q.startDTD(x,B,X),q.endDTD(),Z.index+Z[0].length}}return-1}function U(N,T,q){var W=N.indexOf("?>",T);if(W){var M=N.substring(T,W).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);return M?(M[0].length,q.processingInstruction(M[1],M[2]),W+2):-1}return-1}function A(){this.attributeNames={}}A.prototype={setTagName:function(N){if(!a.test(N))throw new Error("invalid tagName:"+N);this.tagName=N},addValue:function(N,T,q){if(!a.test(N))throw new Error("invalid attribute:"+N);this.attributeNames[N]=this.length,this[this.length++]={qName:N,value:T,offset:q}},length:0,getLocalName:function(N){return this[N].localName},getLocator:function(N){return this[N].locator},getQName:function(N){return this[N].qName},getURI:function(N){return this[N].uri},getValue:function(N){return this[N].value}};function te(N,T){var q,W=[],M=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(M.lastIndex=T,M.exec(N);q=M.exec(N);)if(W.push(q),q[1])return W}return bt.XMLReader=j,bt.ParseError=V,bt}var Ut;function un(){if(Ut)return pt;Ut=1;var n=yt(),t=Vt(),r=sn(),a=an(),i=t.DOMImplementation,u=n.NAMESPACE,c=a.ParseError,b=a.XMLReader;function p(v){return v.replace(/\r[\n\u0085]/g,`
11
11
  `).replace(/[\r\u0085\u2028]/g,`
12
- `)}function m(_){this.options=_||{locator:{}}}m.prototype.parseFromString=function(_,oe){var ge=this.options,re=new N,De=ge.domBuilder||new T,Ae=ge.errorHandler,H=ge.locator,A=ge.xmlns||{},de=/\/x?html?$/.test(oe),k=de?r.HTML_ENTITIES:r.XML_ENTITIES;H&&De.setDocumentLocator(H),re.errorHandler=B(Ae,De,H),re.domBuilder=ge.domBuilder||De,de&&(A[""]=l.HTML),A.xml=A.xml||l.XML;var I=ge.normalizeLineEndings||h;return _&&typeof _=="string"?re.parse(I(_),A,k):re.errorHandler.error("invalid doc source"),De.doc};function B(_,oe,ge){if(!_){if(oe instanceof T)return oe;_=oe}var re={},De=_ instanceof Function;ge=ge||{};function Ae(H){var A=_[H];!A&&De&&(A=_.length==2?function(de){_(H,de)}:_),re[H]=A&&function(de){A("[xmldom "+H+"] "+de+V(ge))}||function(){}}return Ae("warning"),Ae("error"),Ae("fatalError"),re}function T(){this.cdata=!1}function U(_,oe){oe.lineNumber=_.lineNumber,oe.columnNumber=_.columnNumber}T.prototype={startDocument:function(){this.doc=new i().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(_,oe,ge,re){var De=this.doc,Ae=De.createElementNS(_,ge||oe),H=re.length;le(this,Ae),this.currentElement=Ae,this.locator&&U(this.locator,Ae);for(var A=0;A<H;A++){var _=re.getURI(A),de=re.getValue(A),ge=re.getQName(A),k=De.createAttributeNS(_,ge);this.locator&&U(re.getLocator(A),k),k.value=k.nodeValue=de,Ae.setAttributeNode(k)}},endElement:function(_,oe,ge){var re=this.currentElement;re.tagName,this.currentElement=re.parentNode},startPrefixMapping:function(_,oe){},endPrefixMapping:function(_){},processingInstruction:function(_,oe){var ge=this.doc.createProcessingInstruction(_,oe);this.locator&&U(this.locator,ge),le(this,ge)},ignorableWhitespace:function(_,oe,ge){},characters:function(_,oe,ge){if(_=ae.apply(this,arguments),_){if(this.cdata)var re=this.doc.createCDATASection(_);else var re=this.doc.createTextNode(_);this.currentElement?this.currentElement.appendChild(re):/^\s*$/.test(_)&&this.doc.appendChild(re),this.locator&&U(this.locator,re)}},skippedEntity:function(_){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(_){(this.locator=_)&&(_.lineNumber=0)},comment:function(_,oe,ge){_=ae.apply(this,arguments);var re=this.doc.createComment(_);this.locator&&U(this.locator,re),le(this,re)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(_,oe,ge){var re=this.doc.implementation;if(re&&re.createDocumentType){var De=re.createDocumentType(_,oe,ge);this.locator&&U(this.locator,De),le(this,De),this.doc.doctype=De}},warning:function(_){console.warn("[xmldom warning] "+_,V(this.locator))},error:function(_){console.error("[xmldom error] "+_,V(this.locator))},fatalError:function(_){throw new p(_,this.locator)}};function V(_){if(_)return`
13
- @`+(_.systemId||"")+"#[line:"+_.lineNumber+",col:"+_.columnNumber+"]"}function ae(_,oe,ge){return typeof _=="string"?_.substr(oe,ge):_.length>=oe+ge||oe?new java.lang.String(_,oe,ge)+"":_}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(_){T.prototype[_]=function(){return null}});function le(_,oe){_.currentElement?_.currentElement.appendChild(oe):_.doc.appendChild(oe)}return pt.__DOMHandler=T,pt.normalizeLineEndings=h,pt.DOMParser=m,pt}var qt;function on(){if(qt)return ft;qt=1;var n=Lt();return ft.DOMImplementation=n.DOMImplementation,ft.XMLSerializer=n.XMLSerializer,ft.DOMParser=nn().DOMParser,ft}var $t=on();const sn={key:0,class:"xml-node__comment"},un={key:1,class:"xml-node__cdata"},an={key:2,class:"xml-node__element"},ln={key:0,class:"xml-node__line"},cn=["contenteditable","onKeydown"],pn=["contenteditable","onDblclick","onKeydown"],dn=["contenteditable","onDblclick","onKeydown"],hn=["contenteditable","onKeydown"],mn={key:1,class:"xml-node__line"},gn=["contenteditable","onKeydown"],En=["contenteditable","onDblclick","onKeydown"],yn=["contenteditable","onDblclick","onKeydown"],An=["contenteditable","onKeydown"],bn={key:2},xn={key:0,class:"xml-node__line"},Nn=["contenteditable","onKeydown"],Dn=["contenteditable","onDblclick","onKeydown"],vn=["contenteditable","onDblclick","onKeydown"],Cn=["title"],wn={class:"xml-node__line"},Tn=["title"],_n=["contenteditable","onKeydown"],Bn={key:1},Sn=["contenteditable","onKeydown"],On=["contenteditable","onDblclick","onKeydown"],kn=["contenteditable","onDblclick","onKeydown"],Rn=["title"],Fn={key:0,class:"xml-node__children"},In={key:0,class:"xml-node__text"},Pn=["contenteditable","onKeydown"],Ln={key:1,class:"xml-node__line"},Vn=Et(s.defineComponent({__name:"XmlNode",props:{node:{},index:{},level:{default:0},parentPath:{default:""},expanded:{},theme:{}},emits:["toggle-expand","copy","update:tagName","update:attributeName","update:attributeValue","update:textContent","update:cdataContent"],setup(n,{emit:t}){s.useCssVars(g=>({"623698b5":g.theme.colors.indentLine}));const r=n,u=t,i=s.ref(!1),l=s.ref(null),p=s.ref(null),N=s.ref(!1),h=s.ref(!1),m=s.ref(""),B=s.ref(""),T=s.ref(""),U=s.ref(""),V=s.ref(""),ae=s.ref(null),le=s.ref(null),_=s.ref(null),oe=s.ref(null),ge=s.ref(null),re=s.computed(()=>Object.keys(r.node).find(G=>!G.startsWith(":")&&!G.startsWith("#"))||""),De=s.computed(()=>re.value?r.parentPath?`${r.parentPath}.${re.value}[${r.index}]`:`${re.value}[${r.index}]`:""),Ae=s.computed(()=>r.expanded.has(De.value)),H=s.computed(()=>r.node["#comment"]?"comment":r.node.__cdata?"cdata":re.value?"element":"unknown"),A=s.computed(()=>{const g=r.node[":@"]||{},G={};return Object.keys(g).forEach($=>{$.startsWith("@_")&&(G[$.substring(2)]=g[$])}),G}),de=s.computed(()=>{if(H.value!=="element"||!re.value)return[];const g=r.node[re.value];return Array.isArray(g)?g:[]}),k=s.computed(()=>de.value.some(g=>g.__cdata)),I=s.computed(()=>{if(!k.value)return"";const g=de.value.find(G=>G.__cdata);if(g&&Array.isArray(g.__cdata)){const G=g.__cdata;if(G.length>0&&G[0]["#text"])return G[0]["#text"]}return""}),ee=s.computed(()=>{if(H.value!=="element"||!re.value||k.value)return"";const g=r.node[re.value];if(!Array.isArray(g))return"";const G=g.find($=>$["#text"]);return G?G["#text"]:""}),K=s.computed(()=>{if(H.value!=="comment")return"";const g=r.node["#comment"];return Array.isArray(g)&&g.length>0&&g[0]["#text"]||""}),q=s.computed(()=>de.value.some(g=>Object.keys(g).some($=>!$.startsWith("#")&&!$.startsWith(":")))),pe=s.computed(()=>q.value?de.value.filter(g=>Object.keys(g).some($=>!$.startsWith("#")&&!$.startsWith(":"))).length:0),he=s.computed(()=>H.value==="element"&&!q.value&&ee.value.trim()!==""),F=()=>{q.value&&u("toggle-expand",De.value)},x=(g,G)=>`${De.value}-child-${G}`,S=()=>`${De.value}.${re.value}`,R=()=>{i.value=!0,m.value=re.value,s.nextTick(()=>{if(ae.value){ae.value.focus();const g=document.createRange();g.selectNodeContents(ae.value);const G=window.getSelection();G?.removeAllRanges(),G?.addRange(g)}})},j=g=>{l.value=g,B.value=g,s.nextTick(()=>{if(le.value){le.value.focus();const G=document.createRange();G.selectNodeContents(le.value);const $=window.getSelection();$?.removeAllRanges(),$?.addRange(G)}})},M=g=>{p.value=g,T.value=A.value[g]||"",s.nextTick(()=>{if(_.value){_.value.focus();const G=document.createRange();G.selectNodeContents(_.value);const $=window.getSelection();$?.removeAllRanges(),$?.addRange(G)}})},J=()=>{N.value=!0,U.value=ee.value,s.nextTick(()=>{if(oe.value){oe.value.focus();const g=document.createRange();g.selectNodeContents(oe.value);const G=window.getSelection();G?.removeAllRanges(),G?.addRange(g)}})},D=()=>{if(!i.value)return;const g=ae.value?.innerText.trim()||"";if(!g||g===re.value){i.value=!1;return}i.value=!1,u("update:tagName",De.value,re.value,g)},w=()=>{if(!l.value)return;const g=l.value,G=le.value?.innerText.trim()||"";if(!G||G===g){l.value=null;return}l.value=null,u("update:attributeName",De.value,g,G)},P=()=>{if(!p.value)return;const g=p.value,G=_.value?.innerText.trim()||"";p.value=null,u("update:attributeValue",De.value,g,G)},L=()=>{if(!N.value)return;const g=oe.value?.innerText||"";if(g===ee.value){N.value=!1;return}N.value=!1,u("update:textContent",De.value,g)},W=()=>{i.value=!1,m.value=re.value},C=()=>{l.value&&(B.value=l.value,l.value=null)},ne=()=>{p.value&&(T.value=A.value[p.value]||"",p.value=null)},Ee=()=>{N.value=!1,U.value=ee.value},be=()=>{h.value=!0,V.value=I.value,s.nextTick(()=>{if(ge.value){ge.value.focus();const g=document.createRange();g.selectNodeContents(ge.value);const G=window.getSelection();G?.removeAllRanges(),G?.addRange(g)}})},Te=()=>{if(!h.value)return;const g=ge.value?.innerText||"";if(g===I.value){h.value=!1;return}h.value=!1,u("update:cdataContent",De.value,g)},ke=()=>{h.value=!1,V.value=I.value},ve=g=>{q.value&&(g.preventDefault(),R())};return(g,G)=>{const $=s.resolveComponent("XmlNode",!0);return s.openBlock(),s.createElementBlock("div",{class:"xml-node",style:s.normalizeStyle({paddingLeft:g.level>0?"16px":"0"})},[H.value==="comment"?(s.openBlock(),s.createElementBlock("div",sn,[s.createElementVNode("span",{style:s.normalizeStyle({color:g.theme.colors.xmlComment})}," <!-- "+s.toDisplayString(K.value)+" --> ",5)])):H.value==="cdata"?(s.openBlock(),s.createElementBlock("div",un,[s.createElementVNode("span",{style:s.normalizeStyle({color:g.theme.colors.xmlCdata})}," <![CDATA["+s.toDisplayString(g.node.__cdata)+"]]> ",5)])):H.value==="element"?(s.openBlock(),s.createElementBlock("div",an,[k.value?(s.openBlock(),s.createElementBlock("div",ln,[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"<",4),s.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:s.normalizeStyle({color:g.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:R,onContextmenu:ve,onKeydown:[s.withKeys(s.withModifiers(D,["prevent"]),["enter"]),s.withKeys(W,["escape"])],onBlur:D,ref_key:"tagNameRef",ref:ae,title:"Double-click to edit tag name"},s.toDisplayString(i.value?m.value:re.value),45,cn),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(A.value,(_e,ce)=>(s.openBlock(),s.createElementBlock("span",{key:ce,class:"xml-node__attribute"},[s.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttribute}),contenteditable:l.value===ce,onDblclick:se=>j(ce),onKeydown:[s.withKeys(s.withModifiers(w,["prevent"]),["enter"]),s.withKeys(C,["escape"])],onBlur:w,ref_for:!0,ref:se=>{l.value===ce&&(le.value=se)},title:"Double-click to edit attribute name"},s.toDisplayString(l.value===ce?B.value:ce),45,pn),s.createElementVNode("span",{class:"xml-node__equals",style:s.normalizeStyle({color:g.theme.colors.xmlEquals})},"=",4),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4),s.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttributeValue}),contenteditable:p.value===ce,onDblclick:se=>M(ce),onKeydown:[s.withKeys(s.withModifiers(P,["prevent"]),["enter"]),s.withKeys(ne,["escape"])],onBlur:P,ref_for:!0,ref:se=>{p.value===ce&&(_.value=se)},title:"Double-click to edit attribute value"},s.toDisplayString(p.value===ce?T.value:_e),45,dn),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4)]))),128)),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4),s.createElementVNode("span",{class:"xml-node__cdata",style:s.normalizeStyle({color:g.theme.colors.xmlCdata})},"<![CDATA[",4),s.createElementVNode("span",{class:"xml-node__cdata-content xml-node__cdata-content--editable",style:s.normalizeStyle({color:g.theme.colors.xmlCdata}),contenteditable:h.value,onDblclick:be,onKeydown:[s.withKeys(s.withModifiers(Te,["prevent"]),["enter"]),s.withKeys(ke,["escape"])],onBlur:Te,ref_key:"cdataContentRef",ref:ge,title:"Double-click to edit CDATA content"},s.toDisplayString(h.value?V.value:I.value),45,hn),s.createElementVNode("span",{class:"xml-node__cdata",style:s.normalizeStyle({color:g.theme.colors.xmlCdata})},"]]>",4),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"</",4),s.createElementVNode("span",{class:"xml-node__tag",style:s.normalizeStyle({color:g.theme.colors.xmlTag})},s.toDisplayString(i.value?m.value:re.value),5),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4)])):he.value?(s.openBlock(),s.createElementBlock("div",mn,[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"<",4),s.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:s.normalizeStyle({color:g.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:R,onContextmenu:ve,onKeydown:[s.withKeys(s.withModifiers(D,["prevent"]),["enter"]),s.withKeys(W,["escape"])],onBlur:D,ref_key:"tagNameRef",ref:ae,title:"Double-click to edit tag name"},s.toDisplayString(i.value?m.value:re.value),45,gn),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(A.value,(_e,ce)=>(s.openBlock(),s.createElementBlock("span",{key:ce,class:"xml-node__attribute"},[s.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttribute}),contenteditable:l.value===ce,onDblclick:se=>j(ce),onKeydown:[s.withKeys(s.withModifiers(w,["prevent"]),["enter"]),s.withKeys(C,["escape"])],onBlur:w,ref_for:!0,ref:se=>{l.value===ce&&(le.value=se)},title:"Double-click to edit attribute name"},s.toDisplayString(l.value===ce?B.value:ce),45,En),s.createElementVNode("span",{class:"xml-node__equals",style:s.normalizeStyle({color:g.theme.colors.xmlEquals})},"=",4),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4),s.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttributeValue}),contenteditable:p.value===ce,onDblclick:se=>M(ce),onKeydown:[s.withKeys(s.withModifiers(P,["prevent"]),["enter"]),s.withKeys(ne,["escape"])],onBlur:P,ref_for:!0,ref:se=>{p.value===ce&&(_.value=se)},title:"Double-click to edit attribute value"},s.toDisplayString(p.value===ce?T.value:_e),45,yn),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4)]))),128)),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4),s.createElementVNode("span",{class:"xml-node__text-content xml-node__text-content--editable",style:s.normalizeStyle({color:g.theme.colors.xmlText}),contenteditable:N.value,onDblclick:J,onKeydown:[s.withKeys(s.withModifiers(L,["prevent"]),["enter"]),s.withKeys(Ee,["escape"])],onBlur:L,ref_key:"textContentRef",ref:oe,title:"Double-click to edit text content"},s.toDisplayString(N.value?U.value:ee.value),45,An),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"</",4),s.createElementVNode("span",{class:"xml-node__tag",style:s.normalizeStyle({color:g.theme.colors.xmlTag})},s.toDisplayString(i.value?m.value:re.value),5),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4)])):(s.openBlock(),s.createElementBlock("div",bn,[!Ae.value&&q.value?(s.openBlock(),s.createElementBlock("div",xn,[s.createElementVNode("span",{class:"xml-node__clickable-part",onClick:G[0]||(G[0]=_e=>F()),title:"Click to expand"},[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"<",4),s.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:s.normalizeStyle({color:g.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:s.withModifiers(R,["stop"]),onContextmenu:ve,onKeydown:[s.withKeys(s.withModifiers(D,["prevent"]),["enter"]),s.withKeys(W,["escape"])],onBlur:D,ref_key:"tagNameRef",ref:ae,title:"Double-click or right-click to edit tag name"},s.toDisplayString(i.value?m.value:re.value),45,Nn)]),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(A.value,(_e,ce)=>(s.openBlock(),s.createElementBlock("span",{key:ce,class:"xml-node__attribute"},[s.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttribute}),contenteditable:l.value===ce,onDblclick:se=>j(ce),onKeydown:[s.withKeys(s.withModifiers(w,["prevent"]),["enter"]),s.withKeys(C,["escape"])],onBlur:w,ref_for:!0,ref:se=>{l.value===ce&&(le.value=se)},title:"Double-click to edit attribute name"},s.toDisplayString(l.value===ce?B.value:ce),45,Dn),s.createElementVNode("span",{class:"xml-node__equals",style:s.normalizeStyle({color:g.theme.colors.xmlEquals})},"=",4),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4),s.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttributeValue}),contenteditable:p.value===ce,onDblclick:se=>M(ce),onKeydown:[s.withKeys(s.withModifiers(P,["prevent"]),["enter"]),s.withKeys(ne,["escape"])],onBlur:P,ref_for:!0,ref:se=>{p.value===ce&&(_.value=se)},title:"Double-click to edit attribute value"},s.toDisplayString(p.value===ce?T.value:_e),45,vn),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4)]))),128)),s.createElementVNode("span",{class:"xml-node__clickable-part",onClick:G[1]||(G[1]=_e=>F()),title:"Click to expand"},[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4)]),s.createElementVNode("span",{class:"xml-node__collapsed-badge",style:s.normalizeStyle({backgroundColor:g.theme.colors.collapsedBackground,color:g.theme.colors.collapsedText}),onClick:G[2]||(G[2]=_e=>F()),title:`Click to expand ${pe.value} child element${pe.value>1?"s":""}`},s.toDisplayString(pe.value)+" child"+s.toDisplayString(pe.value>1?"ren":""),13,Cn),s.createElementVNode("span",{class:"xml-node__clickable-part",onClick:G[3]||(G[3]=_e=>F()),title:"Click to expand"},[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"</",4),s.createElementVNode("span",{class:"xml-node__tag",style:s.normalizeStyle({color:g.theme.colors.xmlTag})},s.toDisplayString(i.value?m.value:re.value),5),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4)])])):(s.openBlock(),s.createElementBlock(s.Fragment,{key:1},[s.createElementVNode("div",wn,[q.value?(s.openBlock(),s.createElementBlock("span",{key:0,class:"xml-node__clickable-part",onClick:G[4]||(G[4]=_e=>F()),title:Ae.value?"Click to collapse":"Click to expand"},[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"<",4),s.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:s.normalizeStyle({color:g.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:s.withModifiers(R,["stop"]),onContextmenu:ve,onKeydown:[s.withKeys(s.withModifiers(D,["prevent"]),["enter"]),s.withKeys(W,["escape"])],onBlur:D,ref_key:"tagNameRef",ref:ae,title:"Double-click or right-click to edit tag name"},s.toDisplayString(i.value?m.value:re.value),45,_n)],8,Tn)):(s.openBlock(),s.createElementBlock("span",Bn,[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"<",4),s.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:s.normalizeStyle({color:g.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:R,onKeydown:[s.withKeys(s.withModifiers(D,["prevent"]),["enter"]),s.withKeys(W,["escape"])],onBlur:D,ref_key:"tagNameRef",ref:ae,title:"Double-click to edit tag name"},s.toDisplayString(i.value?m.value:re.value),45,Sn)])),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(A.value,(_e,ce)=>(s.openBlock(),s.createElementBlock("span",{key:ce,class:"xml-node__attribute"},[s.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttribute}),contenteditable:l.value===ce,onDblclick:se=>j(ce),onKeydown:[s.withKeys(s.withModifiers(w,["prevent"]),["enter"]),s.withKeys(C,["escape"])],onBlur:w,ref_for:!0,ref:se=>{l.value===ce&&(le.value=se)},title:"Double-click to edit attribute name"},s.toDisplayString(l.value===ce?B.value:ce),45,On),s.createElementVNode("span",{class:"xml-node__equals",style:s.normalizeStyle({color:g.theme.colors.xmlEquals})},"=",4),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4),s.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:s.normalizeStyle({color:g.theme.colors.xmlAttributeValue}),contenteditable:p.value===ce,onDblclick:se=>M(ce),onKeydown:[s.withKeys(s.withModifiers(P,["prevent"]),["enter"]),s.withKeys(ne,["escape"])],onBlur:P,ref_for:!0,ref:se=>{p.value===ce&&(_.value=se)},title:"Double-click to edit attribute value"},s.toDisplayString(p.value===ce?T.value:_e),45,kn),s.createElementVNode("span",{class:"xml-node__quote",style:s.normalizeStyle({color:g.theme.colors.xmlQuote})},'"',4)]))),128)),q.value?(s.openBlock(),s.createElementBlock("span",{key:2,class:"xml-node__clickable-part",onClick:G[5]||(G[5]=_e=>F()),title:Ae.value?"Click to collapse":"Click to expand"},[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4)],8,Rn)):(s.openBlock(),s.createElementBlock("span",{key:3,class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},s.toDisplayString(q.value?">":"/>"),5))]),Ae.value&&q.value?(s.openBlock(),s.createElementBlock("div",Fn,[de.value.length===0&&ee.value.trim()?(s.openBlock(),s.createElementBlock("div",In,[s.createElementVNode("span",{class:"xml-node__text-content xml-node__text-content--editable",style:s.normalizeStyle({color:g.theme.colors.xmlText}),contenteditable:N.value,onDblclick:J,onKeydown:[s.withKeys(s.withModifiers(L,["prevent"]),["enter"]),s.withKeys(Ee,["escape"])],onBlur:L,ref_key:"textContentRef",ref:oe,title:"Double-click to edit text content"},s.toDisplayString(N.value?U.value:ee.value),45,Pn)])):s.createCommentVNode("",!0),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(de.value,(_e,ce)=>(s.openBlock(),s.createBlock($,{key:x(_e,ce),node:_e,index:ce,level:g.level+1,"parent-path":S(),expanded:g.expanded,theme:g.theme,onToggleExpand:G[6]||(G[6]=se=>g.$emit("toggle-expand",se)),onCopy:G[7]||(G[7]=se=>g.$emit("copy",se)),"onUpdate:tagName":G[8]||(G[8]=(se,X,z)=>g.$emit("update:tagName",se,X,z)),"onUpdate:attributeName":G[9]||(G[9]=(se,X,z)=>g.$emit("update:attributeName",se,X,z)),"onUpdate:attributeValue":G[10]||(G[10]=(se,X,z)=>g.$emit("update:attributeValue",se,X,z)),"onUpdate:textContent":G[11]||(G[11]=(se,X)=>g.$emit("update:textContent",se,X)),"onUpdate:cdataContent":G[12]||(G[12]=(se,X)=>g.$emit("update:cdataContent",se,X))},null,8,["node","index","level","parent-path","expanded","theme"]))),128))])):s.createCommentVNode("",!0),Ae.value&&q.value?(s.openBlock(),s.createElementBlock("div",Ln,[s.createElementVNode("span",{class:"xml-node__clickable-part",onClick:G[13]||(G[13]=_e=>F()),title:"Click to collapse"},[s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},"</",4),s.createElementVNode("span",{class:"xml-node__tag",style:s.normalizeStyle({color:g.theme.colors.xmlTag})},s.toDisplayString(i.value?m.value:re.value),5),s.createElementVNode("span",{class:"xml-node__bracket",style:s.normalizeStyle({color:g.theme.colors.xmlBracket})},">",4)])])):s.createCommentVNode("",!0)],64))]))])):s.createCommentVNode("",!0)],4)}}}),[["__scopeId","data-v-44ac0d91"]]),jt={"github-light":{name:"github-light",colors:{background:"#ffffff",surfaceBackground:"#f6f8fa",border:"#d0d7de",text:"#24292f",textSecondary:"#57606a",buttonBackground:"#f6f8fa",buttonBackgroundHover:"#f3f4f6",buttonBorder:"#d0d7de",buttonText:"#24292f",buttonPrimary:"#1f883d",buttonPrimaryHover:"#1a7f37",success:"#1f883d",successBackground:"#dafbe1",error:"#cf222e",errorBackground:"#ffebe9",xmlTag:"#116329",xmlAttribute:"#0550ae",xmlAttributeValue:"#0a3069",xmlText:"#24292f",xmlComment:"#6e7781",xmlCdata:"#8250df",xmlDeclaration:"#953800",xmlBracket:"#6e7781",xmlEquals:"#6e7781",xmlQuote:"#0550ae",collapsedBackground:"#ddf4ff",collapsedText:"#0969da",indentLine:"#d0d7de"}},"github-dark":{name:"github-dark",colors:{background:"#0d1117",surfaceBackground:"#161b22",border:"#30363d",text:"#c9d1d9",textSecondary:"#8b949e",buttonBackground:"#21262d",buttonBackgroundHover:"#30363d",buttonBorder:"#30363d",buttonText:"#c9d1d9",buttonPrimary:"#238636",buttonPrimaryHover:"#2ea043",success:"#3fb950",successBackground:"#0f2e1c",error:"#f85149",errorBackground:"#3d1319",xmlTag:"#7ee787",xmlAttribute:"#79c0ff",xmlAttributeValue:"#a5d6ff",xmlText:"#c9d1d9",xmlComment:"#8b949e",xmlCdata:"#d2a8ff",xmlDeclaration:"#ffa657",xmlBracket:"#8b949e",xmlEquals:"#8b949e",xmlQuote:"#79c0ff",collapsedBackground:"#1c2d41",collapsedText:"#58a6ff",indentLine:"#30363d"}},"min-light":{name:"min-light",colors:{background:"#ffffff",surfaceBackground:"#fafafa",border:"#e5e5e5",text:"#171717",textSecondary:"#737373",buttonBackground:"#fafafa",buttonBackgroundHover:"#f5f5f5",buttonBorder:"#e5e5e5",buttonText:"#171717",buttonPrimary:"#22c55e",buttonPrimaryHover:"#16a34a",success:"#22c55e",successBackground:"#dcfce7",error:"#ef4444",errorBackground:"#fee2e2",xmlTag:"#16a34a",xmlAttribute:"#2563eb",xmlAttributeValue:"#1e40af",xmlText:"#171717",xmlComment:"#737373",xmlCdata:"#9333ea",xmlDeclaration:"#ea580c",xmlBracket:"#737373",xmlEquals:"#737373",xmlQuote:"#2563eb",collapsedBackground:"#dbeafe",collapsedText:"#1d4ed8",indentLine:"#e5e7eb"}},"slack-ochin":{name:"slack-ochin",colors:{background:"#fef5ed",surfaceBackground:"#fef9f3",border:"#e9dcc9",text:"#3d3c40",textSecondary:"#616061",buttonBackground:"#fef9f3",buttonBackgroundHover:"#f9f0e5",buttonBorder:"#e9dcc9",buttonText:"#3d3c40",buttonPrimary:"#007a5a",buttonPrimaryHover:"#006644",success:"#007a5a",successBackground:"#d1f4e0",error:"#e01e5a",errorBackground:"#ffdbea",xmlTag:"#007a5a",xmlAttribute:"#1264a3",xmlAttributeValue:"#0b4c8c",xmlText:"#3d3c40",xmlComment:"#616061",xmlCdata:"#8b2eff",xmlDeclaration:"#e8912d",xmlBracket:"#616061",xmlEquals:"#616061",xmlQuote:"#1264a3",collapsedBackground:"#d8eaf5",collapsedText:"#0b4c8c",indentLine:"#e8d5b7"}}},Mn=n=>jt[n]||jt["github-light"],Xt=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",Un=Xt+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",qn="["+Xt+"]["+Un+"]*",$n=new RegExp("^"+qn+"$");function Ht(n,t){const r=[];let u=t.exec(n);for(;u;){const i=[];i.startIndex=t.lastIndex-u[0].length;const l=u.length;for(let p=0;p<l;p++)i.push(u[p]);r.push(i),u=t.exec(n)}return r}const bt=function(n){const t=$n.exec(n);return!(t===null||typeof t>"u")};function jn(n){return typeof n<"u"}const Xn={allowBooleanAttributes:!1,unpairedTags:[]};function Gt(n,t){t=Object.assign({},Xn,t);const r=[];let u=!1,i=!1;n[0]==="\uFEFF"&&(n=n.substr(1));for(let l=0;l<n.length;l++)if(n[l]==="<"&&n[l+1]==="?"){if(l+=2,l=zt(n,l),l.err)return l}else if(n[l]==="<"){let p=l;if(l++,n[l]==="!"){l=Yt(n,l);continue}else{let N=!1;n[l]==="/"&&(N=!0,l++);let h="";for(;l<n.length&&n[l]!==">"&&n[l]!==" "&&n[l]!==" "&&n[l]!==`
14
- `&&n[l]!=="\r";l++)h+=n[l];if(h=h.trim(),h[h.length-1]==="/"&&(h=h.substring(0,h.length-1),l--),!Zn(h)){let T;return h.trim().length===0?T="Invalid space after '<'.":T="Tag '"+h+"' is an invalid name.",Oe("InvalidTag",T,Le(n,l))}const m=Kn(n,l);if(m===!1)return Oe("InvalidAttr","Attributes for '"+h+"' have open quote.",Le(n,l));let B=m.value;if(l=m.index,B[B.length-1]==="/"){const T=l-B.length;B=B.substring(0,B.length-1);const U=Wt(B,t);if(U===!0)u=!0;else return Oe(U.err.code,U.err.msg,Le(n,T+U.err.line))}else if(N)if(m.tagClosed){if(B.trim().length>0)return Oe("InvalidTag","Closing tag '"+h+"' can't have attributes or invalid starting.",Le(n,p));if(r.length===0)return Oe("InvalidTag","Closing tag '"+h+"' has not been opened.",Le(n,p));{const T=r.pop();if(h!==T.tagName){let U=Le(n,T.tagStartPos);return Oe("InvalidTag","Expected closing tag '"+T.tagName+"' (opened in line "+U.line+", col "+U.col+") instead of closing tag '"+h+"'.",Le(n,p))}r.length==0&&(i=!0)}}else return Oe("InvalidTag","Closing tag '"+h+"' doesn't have proper closing.",Le(n,l));else{const T=Wt(B,t);if(T!==!0)return Oe(T.err.code,T.err.msg,Le(n,l-B.length+T.err.line));if(i===!0)return Oe("InvalidXml","Multiple possible root nodes found.",Le(n,l));t.unpairedTags.indexOf(h)!==-1||r.push({tagName:h,tagStartPos:p}),u=!0}for(l++;l<n.length;l++)if(n[l]==="<")if(n[l+1]==="!"){l++,l=Yt(n,l);continue}else if(n[l+1]==="?"){if(l=zt(n,++l),l.err)return l}else break;else if(n[l]==="&"){const T=Wn(n,l);if(T==-1)return Oe("InvalidChar","char '&' is not expected.",Le(n,l));l=T}else if(i===!0&&!Kt(n[l]))return Oe("InvalidXml","Extra text at the end",Le(n,l));n[l]==="<"&&l--}}else{if(Kt(n[l]))continue;return Oe("InvalidChar","char '"+n[l]+"' is not expected.",Le(n,l))}if(u){if(r.length==1)return Oe("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",Le(n,r[0].tagStartPos));if(r.length>0)return Oe("InvalidXml","Invalid '"+JSON.stringify(r.map(l=>l.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return Oe("InvalidXml","Start tag expected.",1);return!0}function Kt(n){return n===" "||n===" "||n===`
15
- `||n==="\r"}function zt(n,t){const r=t;for(;t<n.length;t++)if(n[t]=="?"||n[t]==" "){const u=n.substr(r,t-r);if(t>5&&u==="xml")return Oe("InvalidXml","XML declaration allowed only at the start of the document.",Le(n,t));if(n[t]=="?"&&n[t+1]==">"){t++;break}else continue}return t}function Yt(n,t){if(n.length>t+5&&n[t+1]==="-"&&n[t+2]==="-"){for(t+=3;t<n.length;t++)if(n[t]==="-"&&n[t+1]==="-"&&n[t+2]===">"){t+=2;break}}else if(n.length>t+8&&n[t+1]==="D"&&n[t+2]==="O"&&n[t+3]==="C"&&n[t+4]==="T"&&n[t+5]==="Y"&&n[t+6]==="P"&&n[t+7]==="E"){let r=1;for(t+=8;t<n.length;t++)if(n[t]==="<")r++;else if(n[t]===">"&&(r--,r===0))break}else if(n.length>t+9&&n[t+1]==="["&&n[t+2]==="C"&&n[t+3]==="D"&&n[t+4]==="A"&&n[t+5]==="T"&&n[t+6]==="A"&&n[t+7]==="["){for(t+=8;t<n.length;t++)if(n[t]==="]"&&n[t+1]==="]"&&n[t+2]===">"){t+=2;break}}return t}const Hn='"',Gn="'";function Kn(n,t){let r="",u="",i=!1;for(;t<n.length;t++){if(n[t]===Hn||n[t]===Gn)u===""?u=n[t]:u!==n[t]||(u="");else if(n[t]===">"&&u===""){i=!0;break}r+=n[t]}return u!==""?!1:{value:r,index:t,tagClosed:i}}const zn=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function Wt(n,t){const r=Ht(n,zn),u={};for(let i=0;i<r.length;i++){if(r[i][1].length===0)return Oe("InvalidAttr","Attribute '"+r[i][2]+"' has no space in starting.",dt(r[i]));if(r[i][3]!==void 0&&r[i][4]===void 0)return Oe("InvalidAttr","Attribute '"+r[i][2]+"' is without value.",dt(r[i]));if(r[i][3]===void 0&&!t.allowBooleanAttributes)return Oe("InvalidAttr","boolean attribute '"+r[i][2]+"' is not allowed.",dt(r[i]));const l=r[i][2];if(!Qn(l))return Oe("InvalidAttr","Attribute '"+l+"' is an invalid name.",dt(r[i]));if(!u.hasOwnProperty(l))u[l]=1;else return Oe("InvalidAttr","Attribute '"+l+"' is repeated.",dt(r[i]))}return!0}function Yn(n,t){let r=/\d/;for(n[t]==="x"&&(t++,r=/[\da-fA-F]/);t<n.length;t++){if(n[t]===";")return t;if(!n[t].match(r))break}return-1}function Wn(n,t){if(t++,n[t]===";")return-1;if(n[t]==="#")return t++,Yn(n,t);let r=0;for(;t<n.length;t++,r++)if(!(n[t].match(/\w/)&&r<20)){if(n[t]===";")break;return-1}return t}function Oe(n,t,r){return{err:{code:n,msg:t,line:r.line||r,col:r.col}}}function Qn(n){return bt(n)}function Zn(n){return bt(n)}function Le(n,t){const r=n.substring(0,t).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}function dt(n){return n.startIndex+n[1].length}const Jn={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(n,t){return t},attributeValueProcessor:function(n,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(n,t,r){return n},captureMetaData:!1},eo=function(n){return Object.assign({},Jn,n)};let xt;typeof Symbol!="function"?xt="@@xmlMetadata":xt=Symbol("XML Node Metadata");class it{constructor(t){this.tagname=t,this.child=[],this[":@"]={}}add(t,r){t==="__proto__"&&(t="#__proto__"),this.child.push({[t]:r})}addChild(t,r){t.tagname==="__proto__"&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push({[t.tagname]:t.child,":@":t[":@"]}):this.child.push({[t.tagname]:t.child}),r!==void 0&&(this.child[this.child.length-1][xt]={startIndex:r})}static getMetaDataSymbol(){return xt}}class to{constructor(t){this.suppressValidationErr=!t}readDocType(t,r){const u={};if(t[r+3]==="O"&&t[r+4]==="C"&&t[r+5]==="T"&&t[r+6]==="Y"&&t[r+7]==="P"&&t[r+8]==="E"){r=r+9;let i=1,l=!1,p=!1,N="";for(;r<t.length;r++)if(t[r]==="<"&&!p){if(l&&ut(t,"!ENTITY",r)){r+=7;let h,m;[h,m,r]=this.readEntityExp(t,r+1,this.suppressValidationErr),m.indexOf("&")===-1&&(u[h]={regx:RegExp(`&${h};`,"g"),val:m})}else if(l&&ut(t,"!ELEMENT",r)){r+=8;const{index:h}=this.readElementExp(t,r+1);r=h}else if(l&&ut(t,"!ATTLIST",r))r+=8;else if(l&&ut(t,"!NOTATION",r)){r+=9;const{index:h}=this.readNotationExp(t,r+1,this.suppressValidationErr);r=h}else if(ut(t,"!--",r))p=!0;else throw new Error("Invalid DOCTYPE");i++,N=""}else if(t[r]===">"){if(p?t[r-1]==="-"&&t[r-2]==="-"&&(p=!1,i--):i--,i===0)break}else t[r]==="["?l=!0:N+=t[r];if(i!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:u,i:r}}readEntityExp(t,r){r=Ve(t,r);let u="";for(;r<t.length&&!/\s/.test(t[r])&&t[r]!=='"'&&t[r]!=="'";)u+=t[r],r++;if(ht(u),r=Ve(t,r),!this.suppressValidationErr){if(t.substring(r,r+6).toUpperCase()==="SYSTEM")throw new Error("External entities are not supported");if(t[r]==="%")throw new Error("Parameter entities are not supported")}let i="";return[r,i]=this.readIdentifierVal(t,r,"entity"),r--,[u,i,r]}readNotationExp(t,r){r=Ve(t,r);let u="";for(;r<t.length&&!/\s/.test(t[r]);)u+=t[r],r++;!this.suppressValidationErr&&ht(u),r=Ve(t,r);const i=t.substring(r,r+6).toUpperCase();if(!this.suppressValidationErr&&i!=="SYSTEM"&&i!=="PUBLIC")throw new Error(`Expected SYSTEM or PUBLIC, found "${i}"`);r+=i.length,r=Ve(t,r);let l=null,p=null;if(i==="PUBLIC")[r,l]=this.readIdentifierVal(t,r,"publicIdentifier"),r=Ve(t,r),(t[r]==='"'||t[r]==="'")&&([r,p]=this.readIdentifierVal(t,r,"systemIdentifier"));else if(i==="SYSTEM"&&([r,p]=this.readIdentifierVal(t,r,"systemIdentifier"),!this.suppressValidationErr&&!p))throw new Error("Missing mandatory system identifier for SYSTEM notation");return{notationName:u,publicIdentifier:l,systemIdentifier:p,index:--r}}readIdentifierVal(t,r,u){let i="";const l=t[r];if(l!=='"'&&l!=="'")throw new Error(`Expected quoted string, found "${l}"`);for(r++;r<t.length&&t[r]!==l;)i+=t[r],r++;if(t[r]!==l)throw new Error(`Unterminated ${u} value`);return r++,[r,i]}readElementExp(t,r){r=Ve(t,r);let u="";for(;r<t.length&&!/\s/.test(t[r]);)u+=t[r],r++;if(!this.suppressValidationErr&&!bt(u))throw new Error(`Invalid element name: "${u}"`);r=Ve(t,r);let i="";if(t[r]==="E"&&ut(t,"MPTY",r))r+=4;else if(t[r]==="A"&&ut(t,"NY",r))r+=2;else if(t[r]==="("){for(r++;r<t.length&&t[r]!==")";)i+=t[r],r++;if(t[r]!==")")throw new Error("Unterminated content model")}else if(!this.suppressValidationErr)throw new Error(`Invalid Element Expression, found "${t[r]}"`);return{elementName:u,contentModel:i.trim(),index:r}}readAttlistExp(t,r){r=Ve(t,r);let u="";for(;r<t.length&&!/\s/.test(t[r]);)u+=t[r],r++;ht(u),r=Ve(t,r);let i="";for(;r<t.length&&!/\s/.test(t[r]);)i+=t[r],r++;if(!ht(i))throw new Error(`Invalid attribute name: "${i}"`);r=Ve(t,r);let l="";if(t.substring(r,r+8).toUpperCase()==="NOTATION"){if(l="NOTATION",r+=8,r=Ve(t,r),t[r]!=="(")throw new Error(`Expected '(', found "${t[r]}"`);r++;let N=[];for(;r<t.length&&t[r]!==")";){let h="";for(;r<t.length&&t[r]!=="|"&&t[r]!==")";)h+=t[r],r++;if(h=h.trim(),!ht(h))throw new Error(`Invalid notation name: "${h}"`);N.push(h),t[r]==="|"&&(r++,r=Ve(t,r))}if(t[r]!==")")throw new Error("Unterminated list of notations");r++,l+=" ("+N.join("|")+")"}else{for(;r<t.length&&!/\s/.test(t[r]);)l+=t[r],r++;const N=["CDATA","ID","IDREF","IDREFS","ENTITY","ENTITIES","NMTOKEN","NMTOKENS"];if(!this.suppressValidationErr&&!N.includes(l.toUpperCase()))throw new Error(`Invalid attribute type: "${l}"`)}r=Ve(t,r);let p="";return t.substring(r,r+8).toUpperCase()==="#REQUIRED"?(p="#REQUIRED",r+=8):t.substring(r,r+7).toUpperCase()==="#IMPLIED"?(p="#IMPLIED",r+=7):[r,p]=this.readIdentifierVal(t,r,"ATTLIST"),{elementName:u,attributeName:i,attributeType:l,defaultValue:p,index:r}}}const Ve=(n,t)=>{for(;t<n.length&&/\s/.test(n[t]);)t++;return t};function ut(n,t,r){for(let u=0;u<t.length;u++)if(t[u]!==n[r+u+1])return!1;return!0}function ht(n){if(bt(n))return n;throw new Error(`Invalid entity name ${n}`)}const ro=/^[-+]?0x[a-fA-F0-9]+$/,no=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,oo={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};function so(n,t={}){if(t=Object.assign({},oo,t),!n||typeof n!="string")return n;let r=n.trim();if(t.skipLike!==void 0&&t.skipLike.test(r))return n;if(n==="0")return 0;if(t.hex&&ro.test(r))return lo(r,16);if(r.search(/.+[eE].+/)!==-1)return uo(n,r,t);{const u=no.exec(r);if(u){const i=u[1]||"",l=u[2];let p=ao(u[3]);const N=i?n[l.length+1]===".":n[l.length]===".";if(!t.leadingZeros&&(l.length>1||l.length===1&&!N))return n;{const h=Number(r),m=String(h);if(h===0)return h;if(m.search(/[eE]/)!==-1)return t.eNotation?h:n;if(r.indexOf(".")!==-1)return m==="0"||m===p||m===`${i}${p}`?h:n;let B=l?p:r;return l?B===m||i+B===m?h:n:B===m||B===i+m?h:n}}else return n}}const io=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function uo(n,t,r){if(!r.eNotation)return n;const u=t.match(io);if(u){let i=u[1]||"";const l=u[3].indexOf("e")===-1?"E":"e",p=u[2],N=i?n[p.length+1]===l:n[p.length]===l;return p.length>1&&N?n:p.length===1&&(u[3].startsWith(`.${l}`)||u[3][0]===l)?Number(t):r.leadingZeros&&!N?(t=(u[1]||"")+u[3],Number(t)):n}else return n}function ao(n){return n&&n.indexOf(".")!==-1&&(n=n.replace(/0+$/,""),n==="."?n="0":n[0]==="."?n="0"+n:n[n.length-1]==="."&&(n=n.substring(0,n.length-1))),n}function lo(n,t){if(parseInt)return parseInt(n,t);if(Number.parseInt)return Number.parseInt(n,t);if(window&&window.parseInt)return window.parseInt(n,t);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")}function Qt(n){return typeof n=="function"?n:Array.isArray(n)?t=>{for(const r of n)if(typeof r=="string"&&t===r||r instanceof RegExp&&r.test(t))return!0}:()=>!1}class co{constructor(t){this.options=t,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(r,u)=>String.fromCodePoint(Number.parseInt(u,10))},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(r,u)=>String.fromCodePoint(Number.parseInt(u,16))}},this.addExternalEntities=fo,this.parseXml=Eo,this.parseTextData=po,this.resolveNameSpace=ho,this.buildAttributesMap=go,this.isItStopNode=xo,this.replaceEntitiesValue=Ao,this.readStopNodeData=Do,this.saveTextToParentTag=bo,this.addChild=yo,this.ignoreAttributesFn=Qt(this.options.ignoreAttributes)}}function fo(n){const t=Object.keys(n);for(let r=0;r<t.length;r++){const u=t[r];this.lastEntities[u]={regex:new RegExp("&"+u+";","g"),val:n[u]}}}function po(n,t,r,u,i,l,p){if(n!==void 0&&(this.options.trimValues&&!u&&(n=n.trim()),n.length>0)){p||(n=this.replaceEntitiesValue(n));const N=this.options.tagValueProcessor(t,n,r,i,l);return N==null?n:typeof N!=typeof n||N!==n?N:this.options.trimValues?Tt(n,this.options.parseTagValue,this.options.numberParseOptions):n.trim()===n?Tt(n,this.options.parseTagValue,this.options.numberParseOptions):n}}function ho(n){if(this.options.removeNSPrefix){const t=n.split(":"),r=n.charAt(0)==="/"?"/":"";if(t[0]==="xmlns")return"";t.length===2&&(n=r+t[1])}return n}const mo=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function go(n,t,r){if(this.options.ignoreAttributes!==!0&&typeof n=="string"){const u=Ht(n,mo),i=u.length,l={};for(let p=0;p<i;p++){const N=this.resolveNameSpace(u[p][1]);if(this.ignoreAttributesFn(N,t))continue;let h=u[p][4],m=this.options.attributeNamePrefix+N;if(N.length)if(this.options.transformAttributeName&&(m=this.options.transformAttributeName(m)),m==="__proto__"&&(m="#__proto__"),h!==void 0){this.options.trimValues&&(h=h.trim()),h=this.replaceEntitiesValue(h);const B=this.options.attributeValueProcessor(N,h,t);B==null?l[m]=h:typeof B!=typeof h||B!==h?l[m]=B:l[m]=Tt(h,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(l[m]=!0)}if(!Object.keys(l).length)return;if(this.options.attributesGroupName){const p={};return p[this.options.attributesGroupName]=l,p}return l}}const Eo=function(n){n=n.replace(/\r\n?/g,`
16
- `);const t=new it("!xml");let r=t,u="",i="";const l=new to(this.options.processEntities);for(let p=0;p<n.length;p++)if(n[p]==="<")if(n[p+1]==="/"){const h=at(n,">",p,"Closing Tag is not closed.");let m=n.substring(p+2,h).trim();if(this.options.removeNSPrefix){const U=m.indexOf(":");U!==-1&&(m=m.substr(U+1))}this.options.transformTagName&&(m=this.options.transformTagName(m)),r&&(u=this.saveTextToParentTag(u,r,i));const B=i.substring(i.lastIndexOf(".")+1);if(m&&this.options.unpairedTags.indexOf(m)!==-1)throw new Error(`Unpaired tag can not be used as closing tag: </${m}>`);let T=0;B&&this.options.unpairedTags.indexOf(B)!==-1?(T=i.lastIndexOf(".",i.lastIndexOf(".")-1),this.tagsNodeStack.pop()):T=i.lastIndexOf("."),i=i.substring(0,T),r=this.tagsNodeStack.pop(),u="",p=h}else if(n[p+1]==="?"){let h=wt(n,p,!1,"?>");if(!h)throw new Error("Pi Tag is not closed.");if(u=this.saveTextToParentTag(u,r,i),!(this.options.ignoreDeclaration&&h.tagName==="?xml"||this.options.ignorePiTags)){const m=new it(h.tagName);m.add(this.options.textNodeName,""),h.tagName!==h.tagExp&&h.attrExpPresent&&(m[":@"]=this.buildAttributesMap(h.tagExp,i,h.tagName)),this.addChild(r,m,i,p)}p=h.closeIndex+1}else if(n.substr(p+1,3)==="!--"){const h=at(n,"-->",p+4,"Comment is not closed.");if(this.options.commentPropName){const m=n.substring(p+4,h-2);u=this.saveTextToParentTag(u,r,i),r.add(this.options.commentPropName,[{[this.options.textNodeName]:m}])}p=h}else if(n.substr(p+1,2)==="!D"){const h=l.readDocType(n,p);this.docTypeEntities=h.entities,p=h.i}else if(n.substr(p+1,2)==="!["){const h=at(n,"]]>",p,"CDATA is not closed.")-2,m=n.substring(p+9,h);u=this.saveTextToParentTag(u,r,i);let B=this.parseTextData(m,r.tagname,i,!0,!1,!0,!0);B==null&&(B=""),this.options.cdataPropName?r.add(this.options.cdataPropName,[{[this.options.textNodeName]:m}]):r.add(this.options.textNodeName,B),p=h+2}else{let h=wt(n,p,this.options.removeNSPrefix),m=h.tagName;const B=h.rawTagName;let T=h.tagExp,U=h.attrExpPresent,V=h.closeIndex;this.options.transformTagName&&(m=this.options.transformTagName(m)),r&&u&&r.tagname!=="!xml"&&(u=this.saveTextToParentTag(u,r,i,!1));const ae=r;ae&&this.options.unpairedTags.indexOf(ae.tagname)!==-1&&(r=this.tagsNodeStack.pop(),i=i.substring(0,i.lastIndexOf("."))),m!==t.tagname&&(i+=i?"."+m:m);const le=p;if(this.isItStopNode(this.options.stopNodes,i,m)){let _="";if(T.length>0&&T.lastIndexOf("/")===T.length-1)m[m.length-1]==="/"?(m=m.substr(0,m.length-1),i=i.substr(0,i.length-1),T=m):T=T.substr(0,T.length-1),p=h.closeIndex;else if(this.options.unpairedTags.indexOf(m)!==-1)p=h.closeIndex;else{const ge=this.readStopNodeData(n,B,V+1);if(!ge)throw new Error(`Unexpected end of ${B}`);p=ge.i,_=ge.tagContent}const oe=new it(m);m!==T&&U&&(oe[":@"]=this.buildAttributesMap(T,i,m)),_&&(_=this.parseTextData(_,m,i,!0,U,!0,!0)),i=i.substr(0,i.lastIndexOf(".")),oe.add(this.options.textNodeName,_),this.addChild(r,oe,i,le)}else{if(T.length>0&&T.lastIndexOf("/")===T.length-1){m[m.length-1]==="/"?(m=m.substr(0,m.length-1),i=i.substr(0,i.length-1),T=m):T=T.substr(0,T.length-1),this.options.transformTagName&&(m=this.options.transformTagName(m));const _=new it(m);m!==T&&U&&(_[":@"]=this.buildAttributesMap(T,i,m)),this.addChild(r,_,i,le),i=i.substr(0,i.lastIndexOf("."))}else{const _=new it(m);this.tagsNodeStack.push(r),m!==T&&U&&(_[":@"]=this.buildAttributesMap(T,i,m)),this.addChild(r,_,i,le),r=_}u="",p=V}}else u+=n[p];return t.child};function yo(n,t,r,u){this.options.captureMetaData||(u=void 0);const i=this.options.updateTag(t.tagname,r,t[":@"]);i===!1||(typeof i=="string"&&(t.tagname=i),n.addChild(t,u))}const Ao=function(n){if(this.options.processEntities){for(let t in this.docTypeEntities){const r=this.docTypeEntities[t];n=n.replace(r.regx,r.val)}for(let t in this.lastEntities){const r=this.lastEntities[t];n=n.replace(r.regex,r.val)}if(this.options.htmlEntities)for(let t in this.htmlEntities){const r=this.htmlEntities[t];n=n.replace(r.regex,r.val)}n=n.replace(this.ampEntity.regex,this.ampEntity.val)}return n};function bo(n,t,r,u){return n&&(u===void 0&&(u=t.child.length===0),n=this.parseTextData(n,t.tagname,r,!1,t[":@"]?Object.keys(t[":@"]).length!==0:!1,u),n!==void 0&&n!==""&&t.add(this.options.textNodeName,n),n=""),n}function xo(n,t,r){const u="*."+r;for(const i in n){const l=n[i];if(u===l||t===l)return!0}return!1}function No(n,t,r=">"){let u,i="";for(let l=t;l<n.length;l++){let p=n[l];if(u)p===u&&(u="");else if(p==='"'||p==="'")u=p;else if(p===r[0])if(r[1]){if(n[l+1]===r[1])return{data:i,index:l}}else return{data:i,index:l};else p===" "&&(p=" ");i+=p}}function at(n,t,r,u){const i=n.indexOf(t,r);if(i===-1)throw new Error(u);return i+t.length-1}function wt(n,t,r,u=">"){const i=No(n,t+1,u);if(!i)return;let l=i.data;const p=i.index,N=l.search(/\s/);let h=l,m=!0;N!==-1&&(h=l.substring(0,N),l=l.substring(N+1).trimStart());const B=h;if(r){const T=h.indexOf(":");T!==-1&&(h=h.substr(T+1),m=h!==i.data.substr(T+1))}return{tagName:h,tagExp:l,closeIndex:p,attrExpPresent:m,rawTagName:B}}function Do(n,t,r){const u=r;let i=1;for(;r<n.length;r++)if(n[r]==="<")if(n[r+1]==="/"){const l=at(n,">",r,`${t} is not closed`);if(n.substring(r+2,l).trim()===t&&(i--,i===0))return{tagContent:n.substring(u,r),i:l};r=l}else if(n[r+1]==="?")r=at(n,"?>",r+1,"StopNode is not closed.");else if(n.substr(r+1,3)==="!--")r=at(n,"-->",r+3,"StopNode is not closed.");else if(n.substr(r+1,2)==="![")r=at(n,"]]>",r,"StopNode is not closed.")-2;else{const l=wt(n,r,">");l&&((l&&l.tagName)===t&&l.tagExp[l.tagExp.length-1]!=="/"&&i++,r=l.closeIndex)}}function Tt(n,t,r){if(t&&typeof n=="string"){const u=n.trim();return u==="true"?!0:u==="false"?!1:so(n,r)}else return jn(n)?n:""}const _t=it.getMetaDataSymbol();function vo(n,t){return Zt(n,t)}function Zt(n,t,r){let u;const i={};for(let l=0;l<n.length;l++){const p=n[l],N=Co(p);let h="";if(r===void 0?h=N:h=r+"."+N,N===t.textNodeName)u===void 0?u=p[N]:u+=""+p[N];else{if(N===void 0)continue;if(p[N]){let m=Zt(p[N],t,h);const B=To(m,t);p[_t]!==void 0&&(m[_t]=p[_t]),p[":@"]?wo(m,p[":@"],h,t):Object.keys(m).length===1&&m[t.textNodeName]!==void 0&&!t.alwaysCreateTextNode?m=m[t.textNodeName]:Object.keys(m).length===0&&(t.alwaysCreateTextNode?m[t.textNodeName]="":m=""),i[N]!==void 0&&i.hasOwnProperty(N)?(Array.isArray(i[N])||(i[N]=[i[N]]),i[N].push(m)):t.isArray(N,h,B)?i[N]=[m]:i[N]=m}}}return typeof u=="string"?u.length>0&&(i[t.textNodeName]=u):u!==void 0&&(i[t.textNodeName]=u),i}function Co(n){const t=Object.keys(n);for(let r=0;r<t.length;r++){const u=t[r];if(u!==":@")return u}}function wo(n,t,r,u){if(t){const i=Object.keys(t),l=i.length;for(let p=0;p<l;p++){const N=i[p];u.isArray(N,r+"."+N,!0,!0)?n[N]=[t[N]]:n[N]=t[N]}}}function To(n,t){const{textNodeName:r}=t,u=Object.keys(n).length;return!!(u===0||u===1&&(n[r]||typeof n[r]=="boolean"||n[r]===0))}class _o{constructor(t){this.externalEntities={},this.options=eo(t)}parse(t,r){if(typeof t!="string"&&t.toString)t=t.toString();else if(typeof t!="string")throw new Error("XML data is accepted in String or Bytes[] form.");if(r){r===!0&&(r={});const l=Gt(t,r);if(l!==!0)throw Error(`${l.err.msg}:${l.err.line}:${l.err.col}`)}const u=new co(this.options);u.addExternalEntities(this.externalEntities);const i=u.parseXml(t);return this.options.preserveOrder||i===void 0?i:vo(i,this.options)}addEntity(t,r){if(r.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(t.indexOf("&")!==-1||t.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '&#xD;'");if(r==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[t]=r}static getMetaDataSymbol(){return it.getMetaDataSymbol()}}const Bo=`
17
- `;function So(n,t){let r="";return t.format&&t.indentBy.length>0&&(r=Bo),Jt(n,t,"",r)}function Jt(n,t,r,u){let i="",l=!1;for(let p=0;p<n.length;p++){const N=n[p],h=Oo(N);if(h===void 0)continue;let m="";if(r.length===0?m=h:m=`${r}.${h}`,h===t.textNodeName){let ae=N[h];ko(m,t)||(ae=t.tagValueProcessor(h,ae),ae=tr(ae,t)),l&&(i+=u),i+=ae,l=!1;continue}else if(h===t.cdataPropName){l&&(i+=u),i+=`<![CDATA[${N[h][0][t.textNodeName]}]]>`,l=!1;continue}else if(h===t.commentPropName){i+=u+`<!--${N[h][0][t.textNodeName]}-->`,l=!0;continue}else if(h[0]==="?"){const ae=er(N[":@"],t),le=h==="?xml"?"":u;let _=N[h][0][t.textNodeName];_=_.length!==0?" "+_:"",i+=le+`<${h}${_}${ae}?>`,l=!0;continue}let B=u;B!==""&&(B+=t.indentBy);const T=er(N[":@"],t),U=u+`<${h}${T}`,V=Jt(N[h],t,m,B);t.unpairedTags.indexOf(h)!==-1?t.suppressUnpairedNode?i+=U+">":i+=U+"/>":(!V||V.length===0)&&t.suppressEmptyNode?i+=U+"/>":V&&V.endsWith(">")?i+=U+`>${V}${u}</${h}>`:(i+=U+">",V&&u!==""&&(V.includes("/>")||V.includes("</"))?i+=u+t.indentBy+V+u:i+=V,i+=`</${h}>`),l=!0}return i}function Oo(n){const t=Object.keys(n);for(let r=0;r<t.length;r++){const u=t[r];if(n.hasOwnProperty(u)&&u!==":@")return u}}function er(n,t){let r="";if(n&&!t.ignoreAttributes)for(let u in n){if(!n.hasOwnProperty(u))continue;let i=t.attributeValueProcessor(u,n[u]);i=tr(i,t),i===!0&&t.suppressBooleanAttributes?r+=` ${u.substr(t.attributeNamePrefix.length)}`:r+=` ${u.substr(t.attributeNamePrefix.length)}="${i}"`}return r}function ko(n,t){n=n.substr(0,n.length-t.textNodeName.length-1);let r=n.substr(n.lastIndexOf(".")+1);for(let u in t.stopNodes)if(t.stopNodes[u]===n||t.stopNodes[u]==="*."+r)return!0;return!1}function tr(n,t){if(n&&n.length>0&&t.processEntities)for(let r=0;r<t.entities.length;r++){const u=t.entities[r];n=n.replace(u.regex,u.val)}return n}const Ro={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(n,t){return t},attributeValueProcessor:function(n,t){return t},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1};function tt(n){this.options=Object.assign({},Ro,n),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=Qt(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=Po),this.processTextOrObjNode=Fo,this.options.format?(this.indentate=Io,this.tagEndChar=`>
12
+ `)}function m(v){this.options=v||{locator:{}}}m.prototype.parseFromString=function(v,H){var K=this.options,$=new b,ae=K.domBuilder||new D,ee=K.errorHandler,U=K.locator,A=K.xmlns||{},te=/\/x?html?$/.test(H),N=te?r.HTML_ENTITIES:r.XML_ENTITIES;U&&ae.setDocumentLocator(U),$.errorHandler=_(ee,ae,U),$.domBuilder=K.domBuilder||ae,te&&(A[""]=u.HTML),A.xml=A.xml||u.XML;var T=K.normalizeLineEndings||p;return v&&typeof v=="string"?$.parse(T(v),A,N):$.errorHandler.error("invalid doc source"),ae.doc};function _(v,H,K){if(!v){if(H instanceof D)return H;v=H}var $={},ae=v instanceof Function;K=K||{};function ee(U){var A=v[U];!A&&ae&&(A=v.length==2?function(te){v(U,te)}:v),$[U]=A&&function(te){A("[xmldom "+U+"] "+te+j(K))}||function(){}}return ee("warning"),ee("error"),ee("fatalError"),$}function D(){this.cdata=!1}function V(v,H){H.lineNumber=v.lineNumber,H.columnNumber=v.columnNumber}D.prototype={startDocument:function(){this.doc=new i().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(v,H,K,$){var ae=this.doc,ee=ae.createElementNS(v,K||H),U=$.length;ie(this,ee),this.currentElement=ee,this.locator&&V(this.locator,ee);for(var A=0;A<U;A++){var v=$.getURI(A),te=$.getValue(A),K=$.getQName(A),N=ae.createAttributeNS(v,K);this.locator&&V($.getLocator(A),N),N.value=N.nodeValue=te,ee.setAttributeNode(N)}},endElement:function(v,H,K){var $=this.currentElement;$.tagName,this.currentElement=$.parentNode},startPrefixMapping:function(v,H){},endPrefixMapping:function(v){},processingInstruction:function(v,H){var K=this.doc.createProcessingInstruction(v,H);this.locator&&V(this.locator,K),ie(this,K)},ignorableWhitespace:function(v,H,K){},characters:function(v,H,K){if(v=Y.apply(this,arguments),v){if(this.cdata)var $=this.doc.createCDATASection(v);else var $=this.doc.createTextNode(v);this.currentElement?this.currentElement.appendChild($):/^\s*$/.test(v)&&this.doc.appendChild($),this.locator&&V(this.locator,$)}},skippedEntity:function(v){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(v){(this.locator=v)&&(v.lineNumber=0)},comment:function(v,H,K){v=Y.apply(this,arguments);var $=this.doc.createComment(v);this.locator&&V(this.locator,$),ie(this,$)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(v,H,K){var $=this.doc.implementation;if($&&$.createDocumentType){var ae=$.createDocumentType(v,H,K);this.locator&&V(this.locator,ae),ie(this,ae),this.doc.doctype=ae}},warning:function(v){console.warn("[xmldom warning] "+v,j(this.locator))},error:function(v){console.error("[xmldom error] "+v,j(this.locator))},fatalError:function(v){throw new c(v,this.locator)}};function j(v){if(v)return`
13
+ @`+(v.systemId||"")+"#[line:"+v.lineNumber+",col:"+v.columnNumber+"]"}function Y(v,H,K){return typeof v=="string"?v.substr(H,K):v.length>=H+K||H?new java.lang.String(v,H,K)+"":v}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(v){D.prototype[v]=function(){return null}});function ie(v,H){v.currentElement?v.currentElement.appendChild(H):v.doc.appendChild(H)}return pt.__DOMHandler=D,pt.normalizeLineEndings=p,pt.DOMParser=m,pt}var qt;function ln(){if(qt)return dt;qt=1;var n=Vt();return dt.DOMImplementation=n.DOMImplementation,dt.XMLSerializer=n.XMLSerializer,dt.DOMParser=un().DOMParser,dt}var Ht=ln();const cn={key:0,class:"xml-node__comment"},dn={key:1,class:"xml-node__cdata"},pn={key:2,class:"xml-node__element"},hn={key:0,class:"xml-node__line"},mn=["contenteditable","onKeydown"],gn=["contenteditable","onDblclick","onKeydown"],En=["contenteditable","onDblclick","onKeydown"],yn=["contenteditable","onKeydown"],bn={key:1,class:"xml-node__line"},An=["contenteditable","onKeydown"],xn=["contenteditable","onDblclick","onKeydown"],Nn=["contenteditable","onDblclick","onKeydown"],Cn=["contenteditable","onKeydown"],Dn={key:2,class:"xml-node__line"},vn=["contenteditable","onKeydown"],wn=["contenteditable","onDblclick","onKeydown"],_n=["contenteditable","onDblclick","onKeydown"],Tn={key:3,class:"xml-node__line"},Bn=["contenteditable","onKeydown"],Sn=["contenteditable","onDblclick","onKeydown"],On=["contenteditable","onDblclick","onKeydown"],kn={key:4},Rn={key:0,class:"xml-node__line"},In=["contenteditable","onKeydown"],Fn=["contenteditable","onDblclick","onKeydown"],Pn=["contenteditable","onDblclick","onKeydown"],Ln=["title"],Vn={class:"xml-node__line"},$n=["title"],Mn=["contenteditable","onKeydown"],Un={key:1},qn=["contenteditable","onKeydown"],Hn=["contenteditable","onDblclick","onKeydown"],jn=["contenteditable","onDblclick","onKeydown"],Kn=["title"],Gn={key:0,class:"xml-node__children"},Xn={key:0,class:"xml-node__text"},zn=["contenteditable","onKeydown"],Wn={key:1,class:"xml-node__line"},Yn=ft(o.defineComponent({__name:"XmlNode",props:{node:{},index:{},level:{default:0},parentPath:{default:""},expanded:{},theme:{},selfClosingTags:{default:()=>new Set}},emits:["toggle-expand","copy","update:tagName","update:attributeName","update:attributeValue","update:textContent","update:cdataContent"],setup(n,{emit:t}){o.useCssVars(y=>({a71f898c:y.theme.colors.indentLine}));const r=n,a=t,i=o.ref(!1),u=o.ref(null),c=o.ref(null),b=o.ref(!1),p=o.ref(!1),m=o.ref(""),_=o.ref(""),D=o.ref(""),V=o.ref(""),j=o.ref(""),Y=o.ref(null),ie=o.ref(null),v=o.ref(null),H=o.ref(null),K=o.ref(null),$=o.computed(()=>Object.keys(r.node).find(ne=>!ne.startsWith(":")&&!ne.startsWith("#"))||""),ae=o.computed(()=>$.value?r.parentPath?`${r.parentPath}.${$.value}[${r.index}]`:`${$.value}[${r.index}]`:""),ee=o.computed(()=>r.expanded.has(ae.value)),U=o.computed(()=>r.node["#comment"]?"comment":r.node.__cdata?"cdata":$.value?"element":"unknown"),A=o.computed(()=>{const y=r.node[":@"]||{},ne={};return Object.keys(y).forEach(Ce=>{Ce.startsWith("@_")&&(ne[Ce.substring(2)]=y[Ce])}),ne}),te=o.computed(()=>{if(U.value!=="element"||!$.value)return[];const y=r.node[$.value];return Array.isArray(y)?y:[]}),N=o.computed(()=>te.value.some(y=>y.__cdata)),T=o.computed(()=>{if(!N.value)return"";const y=te.value.find(ne=>ne.__cdata);if(y&&Array.isArray(y.__cdata)){const ne=y.__cdata;if(ne.length>0&&ne[0]["#text"])return ne[0]["#text"]}return""}),q=o.computed(()=>{if(U.value!=="element"||!$.value||N.value)return"";const y=r.node[$.value];if(!Array.isArray(y))return"";const ne=y.find(Ce=>Ce["#text"]);return ne?ne["#text"]:""}),W=o.computed(()=>{if(U.value!=="comment")return"";const y=r.node["#comment"];return Array.isArray(y)&&y.length>0&&y[0]["#text"]||""}),M=o.computed(()=>te.value.some(y=>Object.keys(y).some(Ce=>!Ce.startsWith("#")&&!Ce.startsWith(":")))),de=o.computed(()=>M.value?te.value.filter(y=>Object.keys(y).some(Ce=>!Ce.startsWith("#")&&!Ce.startsWith(":"))).length:0),he=o.computed(()=>U.value==="element"&&!M.value&&q.value!==""),ye=o.computed(()=>U.value==="element"&&!M.value&&q.value===""),x=o.computed(()=>ye.value&&r.selfClosingTags?.has($.value)||!1),B=()=>{M.value&&a("toggle-expand",ae.value)},X=(y,ne)=>`${ae.value}-child-${ne}`,Z=()=>`${ae.value}.${$.value}`,F=()=>{i.value=!0,m.value=$.value,o.nextTick(()=>{if(Y.value){Y.value.focus();const y=document.createRange();y.selectNodeContents(Y.value);const ne=window.getSelection();ne?.removeAllRanges(),ne?.addRange(y)}})},le=y=>{u.value=y,_.value=y,o.nextTick(()=>{if(ie.value){ie.value.focus();const ne=document.createRange();ne.selectNodeContents(ie.value);const Ce=window.getSelection();Ce?.removeAllRanges(),Ce?.addRange(ne)}})},w=y=>{c.value=y,D.value=A.value[y]||"",o.nextTick(()=>{if(v.value){v.value.focus();const ne=document.createRange();ne.selectNodeContents(v.value);const Ce=window.getSelection();Ce?.removeAllRanges(),Ce?.addRange(ne)}})},k=()=>{b.value=!0,V.value=q.value,o.nextTick(()=>{if(H.value){H.value.focus();const y=document.createRange();y.selectNodeContents(H.value);const ne=window.getSelection();ne?.removeAllRanges(),ne?.addRange(y)}})},L=()=>{if(!i.value)return;const y=Y.value?.innerText.trim()||"";if(!y||y===$.value){i.value=!1;return}i.value=!1,a("update:tagName",ae.value,$.value,y)},G=()=>{if(!u.value)return;const y=u.value,ne=ie.value?.innerText.trim()||"";if(!ne||ne===y){u.value=null;return}u.value=null,a("update:attributeName",ae.value,y,ne)},Q=()=>{if(!c.value)return;const y=c.value,ne=v.value?.innerText.trim()||"";c.value=null,a("update:attributeValue",ae.value,y,ne)},R=()=>{if(!b.value)return;const y=H.value?.innerText||"";if(y===q.value){b.value=!1;return}b.value=!1,a("update:textContent",ae.value,y)},J=()=>{i.value=!1,m.value=$.value},ge=()=>{u.value&&(_.value=u.value,u.value=null)},Ee=()=>{c.value&&(D.value=A.value[c.value]||"",c.value=null)},_e=()=>{b.value=!1,V.value=q.value},ke=()=>{p.value=!0,j.value=T.value,o.nextTick(()=>{if(K.value){K.value.focus();const y=document.createRange();y.selectNodeContents(K.value);const ne=window.getSelection();ne?.removeAllRanges(),ne?.addRange(y)}})},De=()=>{if(!p.value)return;const y=K.value?.innerText||"";if(y===T.value){p.value=!1;return}p.value=!1,a("update:cdataContent",ae.value,y)},z=()=>{p.value=!1,j.value=T.value},Be=y=>{M.value&&(y.preventDefault(),F())};return(y,ne)=>{const Ce=o.resolveComponent("XmlNode",!0);return o.openBlock(),o.createElementBlock("div",{class:"xml-node",style:o.normalizeStyle({paddingLeft:y.level>0?"16px":"0"})},[U.value==="comment"?(o.openBlock(),o.createElementBlock("div",cn,[o.createElementVNode("span",{style:o.normalizeStyle({color:y.theme.colors.xmlComment})}," <!-- "+o.toDisplayString(W.value)+" --> ",5)])):U.value==="cdata"?(o.openBlock(),o.createElementBlock("div",dn,[o.createElementVNode("span",{style:o.normalizeStyle({color:y.theme.colors.xmlCdata})}," <![CDATA["+o.toDisplayString(y.node.__cdata)+"]]> ",5)])):U.value==="element"?(o.openBlock(),o.createElementBlock("div",pn,[N.value?(o.openBlock(),o.createElementBlock("div",hn,[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"<",4),o.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:o.normalizeStyle({color:y.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:F,onContextmenu:Be,onKeydown:[o.withKeys(o.withModifiers(L,["prevent"]),["enter"]),o.withKeys(J,["escape"])],onBlur:L,ref_key:"tagNameRef",ref:Y,title:"Double-click to edit tag name"},o.toDisplayString(i.value?m.value:$.value),45,mn),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(A.value,(be,O)=>(o.openBlock(),o.createElementBlock("span",{key:O,class:"xml-node__attribute"},[o.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttribute}),contenteditable:u.value===O,onDblclick:P=>le(O),onKeydown:[o.withKeys(o.withModifiers(G,["prevent"]),["enter"]),o.withKeys(ge,["escape"])],onBlur:G,ref_for:!0,ref:P=>{u.value===O&&(ie.value=P)},title:"Double-click to edit attribute name"},o.toDisplayString(u.value===O?_.value:O),45,gn),o.createElementVNode("span",{class:"xml-node__equals",style:o.normalizeStyle({color:y.theme.colors.xmlEquals})},"=",4),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4),o.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttributeValue}),contenteditable:c.value===O,onDblclick:P=>w(O),onKeydown:[o.withKeys(o.withModifiers(Q,["prevent"]),["enter"]),o.withKeys(Ee,["escape"])],onBlur:Q,ref_for:!0,ref:P=>{c.value===O&&(v.value=P)},title:"Double-click to edit attribute value"},o.toDisplayString(c.value===O?D.value:be),45,En),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4)]))),128)),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4),o.createElementVNode("span",{class:"xml-node__cdata",style:o.normalizeStyle({color:y.theme.colors.xmlCdata})},"<![CDATA[",4),o.createElementVNode("span",{class:"xml-node__cdata-content xml-node__cdata-content--editable",style:o.normalizeStyle({color:y.theme.colors.xmlCdata}),contenteditable:p.value,onDblclick:ke,onKeydown:[o.withKeys(o.withModifiers(De,["prevent"]),["enter"]),o.withKeys(z,["escape"])],onBlur:De,ref_key:"cdataContentRef",ref:K,title:"Double-click to edit CDATA content"},o.toDisplayString(p.value?j.value:T.value),45,yn),o.createElementVNode("span",{class:"xml-node__cdata",style:o.normalizeStyle({color:y.theme.colors.xmlCdata})},"]]>",4),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"</",4),o.createElementVNode("span",{class:"xml-node__tag",style:o.normalizeStyle({color:y.theme.colors.xmlTag})},o.toDisplayString(i.value?m.value:$.value),5),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4)])):he.value?(o.openBlock(),o.createElementBlock("div",bn,[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"<",4),o.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:o.normalizeStyle({color:y.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:F,onContextmenu:Be,onKeydown:[o.withKeys(o.withModifiers(L,["prevent"]),["enter"]),o.withKeys(J,["escape"])],onBlur:L,ref_key:"tagNameRef",ref:Y,title:"Double-click to edit tag name"},o.toDisplayString(i.value?m.value:$.value),45,An),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(A.value,(be,O)=>(o.openBlock(),o.createElementBlock("span",{key:O,class:"xml-node__attribute"},[o.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttribute}),contenteditable:u.value===O,onDblclick:P=>le(O),onKeydown:[o.withKeys(o.withModifiers(G,["prevent"]),["enter"]),o.withKeys(ge,["escape"])],onBlur:G,ref_for:!0,ref:P=>{u.value===O&&(ie.value=P)},title:"Double-click to edit attribute name"},o.toDisplayString(u.value===O?_.value:O),45,xn),o.createElementVNode("span",{class:"xml-node__equals",style:o.normalizeStyle({color:y.theme.colors.xmlEquals})},"=",4),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4),o.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttributeValue}),contenteditable:c.value===O,onDblclick:P=>w(O),onKeydown:[o.withKeys(o.withModifiers(Q,["prevent"]),["enter"]),o.withKeys(Ee,["escape"])],onBlur:Q,ref_for:!0,ref:P=>{c.value===O&&(v.value=P)},title:"Double-click to edit attribute value"},o.toDisplayString(c.value===O?D.value:be),45,Nn),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4)]))),128)),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4),o.createElementVNode("span",{class:"xml-node__text-content xml-node__text-content--editable",style:o.normalizeStyle({color:y.theme.colors.xmlText}),contenteditable:b.value,onDblclick:k,onKeydown:[o.withKeys(o.withModifiers(R,["prevent"]),["enter"]),o.withKeys(_e,["escape"])],onBlur:R,ref_key:"textContentRef",ref:H,title:"Double-click to edit text content"},o.toDisplayString(b.value?V.value:q.value),45,Cn),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"</",4),o.createElementVNode("span",{class:"xml-node__tag",style:o.normalizeStyle({color:y.theme.colors.xmlTag})},o.toDisplayString(i.value?m.value:$.value),5),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4)])):ye.value&&x.value?(o.openBlock(),o.createElementBlock("div",Dn,[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"<",4),o.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:o.normalizeStyle({color:y.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:F,onContextmenu:Be,onKeydown:[o.withKeys(o.withModifiers(L,["prevent"]),["enter"]),o.withKeys(J,["escape"])],onBlur:L,ref_key:"tagNameRef",ref:Y,title:"Double-click to edit tag name"},o.toDisplayString(i.value?m.value:$.value),45,vn),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(A.value,(be,O)=>(o.openBlock(),o.createElementBlock("span",{key:O,class:"xml-node__attribute"},[o.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttribute}),contenteditable:u.value===O,onDblclick:P=>le(O),onKeydown:[o.withKeys(o.withModifiers(G,["prevent"]),["enter"]),o.withKeys(ge,["escape"])],onBlur:G,ref_for:!0,ref:P=>{u.value===O&&(ie.value=P)},title:"Double-click to edit attribute name"},o.toDisplayString(u.value===O?_.value:O),45,wn),o.createElementVNode("span",{class:"xml-node__equals",style:o.normalizeStyle({color:y.theme.colors.xmlEquals})},"=",4),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4),o.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttributeValue}),contenteditable:c.value===O,onDblclick:P=>w(O),onKeydown:[o.withKeys(o.withModifiers(Q,["prevent"]),["enter"]),o.withKeys(Ee,["escape"])],onBlur:Q,ref_for:!0,ref:P=>{c.value===O&&(v.value=P)},title:"Double-click to edit attribute value"},o.toDisplayString(c.value===O?D.value:be),45,_n),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4)]))),128)),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})}," />",4)])):ye.value?(o.openBlock(),o.createElementBlock("div",Tn,[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"<",4),o.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:o.normalizeStyle({color:y.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:F,onContextmenu:Be,onKeydown:[o.withKeys(o.withModifiers(L,["prevent"]),["enter"]),o.withKeys(J,["escape"])],onBlur:L,ref_key:"tagNameRef",ref:Y,title:"Double-click to edit tag name"},o.toDisplayString(i.value?m.value:$.value),45,Bn),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(A.value,(be,O)=>(o.openBlock(),o.createElementBlock("span",{key:O,class:"xml-node__attribute"},[o.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttribute}),contenteditable:u.value===O,onDblclick:P=>le(O),onKeydown:[o.withKeys(o.withModifiers(G,["prevent"]),["enter"]),o.withKeys(ge,["escape"])],onBlur:G,ref_for:!0,ref:P=>{u.value===O&&(ie.value=P)},title:"Double-click to edit attribute name"},o.toDisplayString(u.value===O?_.value:O),45,Sn),o.createElementVNode("span",{class:"xml-node__equals",style:o.normalizeStyle({color:y.theme.colors.xmlEquals})},"=",4),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4),o.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttributeValue}),contenteditable:c.value===O,onDblclick:P=>w(O),onKeydown:[o.withKeys(o.withModifiers(Q,["prevent"]),["enter"]),o.withKeys(Ee,["escape"])],onBlur:Q,ref_for:!0,ref:P=>{c.value===O&&(v.value=P)},title:"Double-click to edit attribute value"},o.toDisplayString(c.value===O?D.value:be),45,On),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4)]))),128)),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"></",4),o.createElementVNode("span",{class:"xml-node__tag",style:o.normalizeStyle({color:y.theme.colors.xmlTag})},o.toDisplayString(i.value?m.value:$.value),5),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4)])):(o.openBlock(),o.createElementBlock("div",kn,[!ee.value&&M.value?(o.openBlock(),o.createElementBlock("div",Rn,[o.createElementVNode("span",{class:"xml-node__clickable-part",onClick:ne[0]||(ne[0]=be=>B()),title:"Click to expand"},[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"<",4),o.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:o.normalizeStyle({color:y.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:o.withModifiers(F,["stop"]),onContextmenu:Be,onKeydown:[o.withKeys(o.withModifiers(L,["prevent"]),["enter"]),o.withKeys(J,["escape"])],onBlur:L,ref_key:"tagNameRef",ref:Y,title:"Double-click or right-click to edit tag name"},o.toDisplayString(i.value?m.value:$.value),45,In)]),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(A.value,(be,O)=>(o.openBlock(),o.createElementBlock("span",{key:O,class:"xml-node__attribute"},[o.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttribute}),contenteditable:u.value===O,onDblclick:P=>le(O),onKeydown:[o.withKeys(o.withModifiers(G,["prevent"]),["enter"]),o.withKeys(ge,["escape"])],onBlur:G,ref_for:!0,ref:P=>{u.value===O&&(ie.value=P)},title:"Double-click to edit attribute name"},o.toDisplayString(u.value===O?_.value:O),45,Fn),o.createElementVNode("span",{class:"xml-node__equals",style:o.normalizeStyle({color:y.theme.colors.xmlEquals})},"=",4),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4),o.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttributeValue}),contenteditable:c.value===O,onDblclick:P=>w(O),onKeydown:[o.withKeys(o.withModifiers(Q,["prevent"]),["enter"]),o.withKeys(Ee,["escape"])],onBlur:Q,ref_for:!0,ref:P=>{c.value===O&&(v.value=P)},title:"Double-click to edit attribute value"},o.toDisplayString(c.value===O?D.value:be),45,Pn),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4)]))),128)),o.createElementVNode("span",{class:"xml-node__clickable-part",onClick:ne[1]||(ne[1]=be=>B()),title:"Click to expand"},[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4)]),o.createElementVNode("span",{class:"xml-node__collapsed-badge",style:o.normalizeStyle({backgroundColor:y.theme.colors.collapsedBackground,color:y.theme.colors.collapsedText}),onClick:ne[2]||(ne[2]=be=>B()),title:`Click to expand ${de.value} child element${de.value>1?"s":""}`},o.toDisplayString(de.value)+" child"+o.toDisplayString(de.value>1?"ren":""),13,Ln),o.createElementVNode("span",{class:"xml-node__clickable-part",onClick:ne[3]||(ne[3]=be=>B()),title:"Click to expand"},[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"</",4),o.createElementVNode("span",{class:"xml-node__tag",style:o.normalizeStyle({color:y.theme.colors.xmlTag})},o.toDisplayString(i.value?m.value:$.value),5),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4)])])):(o.openBlock(),o.createElementBlock(o.Fragment,{key:1},[o.createElementVNode("div",Vn,[M.value?(o.openBlock(),o.createElementBlock("span",{key:0,class:"xml-node__clickable-part",onClick:ne[4]||(ne[4]=be=>B()),title:ee.value?"Click to collapse":"Click to expand"},[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"<",4),o.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:o.normalizeStyle({color:y.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:o.withModifiers(F,["stop"]),onContextmenu:Be,onKeydown:[o.withKeys(o.withModifiers(L,["prevent"]),["enter"]),o.withKeys(J,["escape"])],onBlur:L,ref_key:"tagNameRef",ref:Y,title:"Double-click or right-click to edit tag name"},o.toDisplayString(i.value?m.value:$.value),45,Mn)],8,$n)):(o.openBlock(),o.createElementBlock("span",Un,[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"<",4),o.createElementVNode("span",{class:"xml-node__tag xml-node__tag--editable",style:o.normalizeStyle({color:y.theme.colors.xmlTag}),contenteditable:i.value,onDblclick:F,onKeydown:[o.withKeys(o.withModifiers(L,["prevent"]),["enter"]),o.withKeys(J,["escape"])],onBlur:L,ref_key:"tagNameRef",ref:Y,title:"Double-click to edit tag name"},o.toDisplayString(i.value?m.value:$.value),45,qn)])),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(A.value,(be,O)=>(o.openBlock(),o.createElementBlock("span",{key:O,class:"xml-node__attribute"},[o.createElementVNode("span",{class:"xml-node__attr-name xml-node__attr-name--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttribute}),contenteditable:u.value===O,onDblclick:P=>le(O),onKeydown:[o.withKeys(o.withModifiers(G,["prevent"]),["enter"]),o.withKeys(ge,["escape"])],onBlur:G,ref_for:!0,ref:P=>{u.value===O&&(ie.value=P)},title:"Double-click to edit attribute name"},o.toDisplayString(u.value===O?_.value:O),45,Hn),o.createElementVNode("span",{class:"xml-node__equals",style:o.normalizeStyle({color:y.theme.colors.xmlEquals})},"=",4),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4),o.createElementVNode("span",{class:"xml-node__attr-value xml-node__attr-value--editable",style:o.normalizeStyle({color:y.theme.colors.xmlAttributeValue}),contenteditable:c.value===O,onDblclick:P=>w(O),onKeydown:[o.withKeys(o.withModifiers(Q,["prevent"]),["enter"]),o.withKeys(Ee,["escape"])],onBlur:Q,ref_for:!0,ref:P=>{c.value===O&&(v.value=P)},title:"Double-click to edit attribute value"},o.toDisplayString(c.value===O?D.value:be),45,jn),o.createElementVNode("span",{class:"xml-node__quote",style:o.normalizeStyle({color:y.theme.colors.xmlQuote})},'"',4)]))),128)),M.value?(o.openBlock(),o.createElementBlock("span",{key:2,class:"xml-node__clickable-part",onClick:ne[5]||(ne[5]=be=>B()),title:ee.value?"Click to collapse":"Click to expand"},[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4)],8,Kn)):(o.openBlock(),o.createElementBlock("span",{key:3,class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},o.toDisplayString(M.value?">":"/>"),5))]),ee.value&&M.value?(o.openBlock(),o.createElementBlock("div",Gn,[te.value.length===0&&q.value.trim()?(o.openBlock(),o.createElementBlock("div",Xn,[o.createElementVNode("span",{class:"xml-node__text-content xml-node__text-content--editable",style:o.normalizeStyle({color:y.theme.colors.xmlText}),contenteditable:b.value,onDblclick:k,onKeydown:[o.withKeys(o.withModifiers(R,["prevent"]),["enter"]),o.withKeys(_e,["escape"])],onBlur:R,ref_key:"textContentRef",ref:H,title:"Double-click to edit text content"},o.toDisplayString(b.value?V.value:q.value),45,zn)])):o.createCommentVNode("",!0),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(te.value,(be,O)=>(o.openBlock(),o.createBlock(Ce,{key:X(be,O),node:be,index:O,level:y.level+1,"parent-path":Z(),expanded:y.expanded,theme:y.theme,selfClosingTags:y.selfClosingTags,onToggleExpand:ne[6]||(ne[6]=P=>y.$emit("toggle-expand",P)),onCopy:ne[7]||(ne[7]=P=>y.$emit("copy",P)),"onUpdate:tagName":ne[8]||(ne[8]=(P,Re,qe)=>y.$emit("update:tagName",P,Re,qe)),"onUpdate:attributeName":ne[9]||(ne[9]=(P,Re,qe)=>y.$emit("update:attributeName",P,Re,qe)),"onUpdate:attributeValue":ne[10]||(ne[10]=(P,Re,qe)=>y.$emit("update:attributeValue",P,Re,qe)),"onUpdate:textContent":ne[11]||(ne[11]=(P,Re)=>y.$emit("update:textContent",P,Re)),"onUpdate:cdataContent":ne[12]||(ne[12]=(P,Re)=>y.$emit("update:cdataContent",P,Re))},null,8,["node","index","level","parent-path","expanded","theme","selfClosingTags"]))),128))])):o.createCommentVNode("",!0),ee.value&&M.value?(o.openBlock(),o.createElementBlock("div",Wn,[o.createElementVNode("span",{class:"xml-node__clickable-part",onClick:ne[13]||(ne[13]=be=>B()),title:"Click to collapse"},[o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},"</",4),o.createElementVNode("span",{class:"xml-node__tag",style:o.normalizeStyle({color:y.theme.colors.xmlTag})},o.toDisplayString(i.value?m.value:$.value),5),o.createElementVNode("span",{class:"xml-node__bracket",style:o.normalizeStyle({color:y.theme.colors.xmlBracket})},">",4)])])):o.createCommentVNode("",!0)],64))]))])):o.createCommentVNode("",!0)],4)}}}),[["__scopeId","data-v-acda96f3"]]),jt={"github-light":{name:"github-light",colors:{background:"#ffffff",surfaceBackground:"#f6f8fa",border:"#d0d7de",text:"#24292f",textSecondary:"#57606a",buttonBackground:"#f6f8fa",buttonBackgroundHover:"#f3f4f6",buttonBorder:"#d0d7de",buttonText:"#24292f",buttonPrimary:"#1f883d",buttonPrimaryHover:"#1a7f37",success:"#1f883d",successBackground:"#dafbe1",error:"#cf222e",errorBackground:"#ffebe9",xmlTag:"#116329",xmlAttribute:"#0550ae",xmlAttributeValue:"#0a3069",xmlText:"#24292f",xmlComment:"#6e7781",xmlCdata:"#8250df",xmlDeclaration:"#953800",xmlBracket:"#6e7781",xmlEquals:"#6e7781",xmlQuote:"#0550ae",collapsedBackground:"#ddf4ff",collapsedText:"#0969da",indentLine:"#d0d7de"}},"github-dark":{name:"github-dark",colors:{background:"#0d1117",surfaceBackground:"#161b22",border:"#30363d",text:"#c9d1d9",textSecondary:"#8b949e",buttonBackground:"#21262d",buttonBackgroundHover:"#30363d",buttonBorder:"#30363d",buttonText:"#c9d1d9",buttonPrimary:"#238636",buttonPrimaryHover:"#2ea043",success:"#3fb950",successBackground:"#0f2e1c",error:"#f85149",errorBackground:"#3d1319",xmlTag:"#7ee787",xmlAttribute:"#79c0ff",xmlAttributeValue:"#a5d6ff",xmlText:"#c9d1d9",xmlComment:"#8b949e",xmlCdata:"#d2a8ff",xmlDeclaration:"#ffa657",xmlBracket:"#8b949e",xmlEquals:"#8b949e",xmlQuote:"#79c0ff",collapsedBackground:"#1c2d41",collapsedText:"#58a6ff",indentLine:"#30363d"}},"min-light":{name:"min-light",colors:{background:"#ffffff",surfaceBackground:"#fafafa",border:"#e5e5e5",text:"#171717",textSecondary:"#737373",buttonBackground:"#fafafa",buttonBackgroundHover:"#f5f5f5",buttonBorder:"#e5e5e5",buttonText:"#171717",buttonPrimary:"#22c55e",buttonPrimaryHover:"#16a34a",success:"#22c55e",successBackground:"#dcfce7",error:"#ef4444",errorBackground:"#fee2e2",xmlTag:"#16a34a",xmlAttribute:"#2563eb",xmlAttributeValue:"#1e40af",xmlText:"#171717",xmlComment:"#737373",xmlCdata:"#9333ea",xmlDeclaration:"#ea580c",xmlBracket:"#737373",xmlEquals:"#737373",xmlQuote:"#2563eb",collapsedBackground:"#dbeafe",collapsedText:"#1d4ed8",indentLine:"#e5e7eb"}},"slack-ochin":{name:"slack-ochin",colors:{background:"#fef5ed",surfaceBackground:"#fef9f3",border:"#e9dcc9",text:"#3d3c40",textSecondary:"#616061",buttonBackground:"#fef9f3",buttonBackgroundHover:"#f9f0e5",buttonBorder:"#e9dcc9",buttonText:"#3d3c40",buttonPrimary:"#007a5a",buttonPrimaryHover:"#006644",success:"#007a5a",successBackground:"#d1f4e0",error:"#e01e5a",errorBackground:"#ffdbea",xmlTag:"#007a5a",xmlAttribute:"#1264a3",xmlAttributeValue:"#0b4c8c",xmlText:"#3d3c40",xmlComment:"#616061",xmlCdata:"#8b2eff",xmlDeclaration:"#e8912d",xmlBracket:"#616061",xmlEquals:"#616061",xmlQuote:"#1264a3",collapsedBackground:"#d8eaf5",collapsedText:"#0b4c8c",indentLine:"#e8d5b7"}}},Qn=n=>jt[n]||jt["github-light"],Kt=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",Zn=Kt+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",Jn="["+Kt+"]["+Zn+"]*",eo=new RegExp("^"+Jn+"$");function Gt(n,t){const r=[];let a=t.exec(n);for(;a;){const i=[];i.startIndex=t.lastIndex-a[0].length;const u=a.length;for(let c=0;c<u;c++)i.push(a[c]);r.push(i),a=t.exec(n)}return r}const At=function(n){const t=eo.exec(n);return!(t===null||typeof t>"u")};function to(n){return typeof n<"u"}const ro={allowBooleanAttributes:!1,unpairedTags:[]};function Xt(n,t){t=Object.assign({},ro,t);const r=[];let a=!1,i=!1;n[0]==="\uFEFF"&&(n=n.substr(1));for(let u=0;u<n.length;u++)if(n[u]==="<"&&n[u+1]==="?"){if(u+=2,u=Wt(n,u),u.err)return u}else if(n[u]==="<"){let c=u;if(u++,n[u]==="!"){u=Yt(n,u);continue}else{let b=!1;n[u]==="/"&&(b=!0,u++);let p="";for(;u<n.length&&n[u]!==">"&&n[u]!==" "&&n[u]!==" "&&n[u]!==`
14
+ `&&n[u]!=="\r";u++)p+=n[u];if(p=p.trim(),p[p.length-1]==="/"&&(p=p.substring(0,p.length-1),u--),!co(p)){let D;return p.trim().length===0?D="Invalid space after '<'.":D="Tag '"+p+"' is an invalid name.",Oe("InvalidTag",D,Ve(n,u))}const m=so(n,u);if(m===!1)return Oe("InvalidAttr","Attributes for '"+p+"' have open quote.",Ve(n,u));let _=m.value;if(u=m.index,_[_.length-1]==="/"){const D=u-_.length;_=_.substring(0,_.length-1);const V=Qt(_,t);if(V===!0)a=!0;else return Oe(V.err.code,V.err.msg,Ve(n,D+V.err.line))}else if(b)if(m.tagClosed){if(_.trim().length>0)return Oe("InvalidTag","Closing tag '"+p+"' can't have attributes or invalid starting.",Ve(n,c));if(r.length===0)return Oe("InvalidTag","Closing tag '"+p+"' has not been opened.",Ve(n,c));{const D=r.pop();if(p!==D.tagName){let V=Ve(n,D.tagStartPos);return Oe("InvalidTag","Expected closing tag '"+D.tagName+"' (opened in line "+V.line+", col "+V.col+") instead of closing tag '"+p+"'.",Ve(n,c))}r.length==0&&(i=!0)}}else return Oe("InvalidTag","Closing tag '"+p+"' doesn't have proper closing.",Ve(n,u));else{const D=Qt(_,t);if(D!==!0)return Oe(D.err.code,D.err.msg,Ve(n,u-_.length+D.err.line));if(i===!0)return Oe("InvalidXml","Multiple possible root nodes found.",Ve(n,u));t.unpairedTags.indexOf(p)!==-1||r.push({tagName:p,tagStartPos:c}),a=!0}for(u++;u<n.length;u++)if(n[u]==="<")if(n[u+1]==="!"){u++,u=Yt(n,u);continue}else if(n[u+1]==="?"){if(u=Wt(n,++u),u.err)return u}else break;else if(n[u]==="&"){const D=uo(n,u);if(D==-1)return Oe("InvalidChar","char '&' is not expected.",Ve(n,u));u=D}else if(i===!0&&!zt(n[u]))return Oe("InvalidXml","Extra text at the end",Ve(n,u));n[u]==="<"&&u--}}else{if(zt(n[u]))continue;return Oe("InvalidChar","char '"+n[u]+"' is not expected.",Ve(n,u))}if(a){if(r.length==1)return Oe("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",Ve(n,r[0].tagStartPos));if(r.length>0)return Oe("InvalidXml","Invalid '"+JSON.stringify(r.map(u=>u.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return Oe("InvalidXml","Start tag expected.",1);return!0}function zt(n){return n===" "||n===" "||n===`
15
+ `||n==="\r"}function Wt(n,t){const r=t;for(;t<n.length;t++)if(n[t]=="?"||n[t]==" "){const a=n.substr(r,t-r);if(t>5&&a==="xml")return Oe("InvalidXml","XML declaration allowed only at the start of the document.",Ve(n,t));if(n[t]=="?"&&n[t+1]==">"){t++;break}else continue}return t}function Yt(n,t){if(n.length>t+5&&n[t+1]==="-"&&n[t+2]==="-"){for(t+=3;t<n.length;t++)if(n[t]==="-"&&n[t+1]==="-"&&n[t+2]===">"){t+=2;break}}else if(n.length>t+8&&n[t+1]==="D"&&n[t+2]==="O"&&n[t+3]==="C"&&n[t+4]==="T"&&n[t+5]==="Y"&&n[t+6]==="P"&&n[t+7]==="E"){let r=1;for(t+=8;t<n.length;t++)if(n[t]==="<")r++;else if(n[t]===">"&&(r--,r===0))break}else if(n.length>t+9&&n[t+1]==="["&&n[t+2]==="C"&&n[t+3]==="D"&&n[t+4]==="A"&&n[t+5]==="T"&&n[t+6]==="A"&&n[t+7]==="["){for(t+=8;t<n.length;t++)if(n[t]==="]"&&n[t+1]==="]"&&n[t+2]===">"){t+=2;break}}return t}const no='"',oo="'";function so(n,t){let r="",a="",i=!1;for(;t<n.length;t++){if(n[t]===no||n[t]===oo)a===""?a=n[t]:a!==n[t]||(a="");else if(n[t]===">"&&a===""){i=!0;break}r+=n[t]}return a!==""?!1:{value:r,index:t,tagClosed:i}}const io=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function Qt(n,t){const r=Gt(n,io),a={};for(let i=0;i<r.length;i++){if(r[i][1].length===0)return Oe("InvalidAttr","Attribute '"+r[i][2]+"' has no space in starting.",ht(r[i]));if(r[i][3]!==void 0&&r[i][4]===void 0)return Oe("InvalidAttr","Attribute '"+r[i][2]+"' is without value.",ht(r[i]));if(r[i][3]===void 0&&!t.allowBooleanAttributes)return Oe("InvalidAttr","boolean attribute '"+r[i][2]+"' is not allowed.",ht(r[i]));const u=r[i][2];if(!lo(u))return Oe("InvalidAttr","Attribute '"+u+"' is an invalid name.",ht(r[i]));if(!a.hasOwnProperty(u))a[u]=1;else return Oe("InvalidAttr","Attribute '"+u+"' is repeated.",ht(r[i]))}return!0}function ao(n,t){let r=/\d/;for(n[t]==="x"&&(t++,r=/[\da-fA-F]/);t<n.length;t++){if(n[t]===";")return t;if(!n[t].match(r))break}return-1}function uo(n,t){if(t++,n[t]===";")return-1;if(n[t]==="#")return t++,ao(n,t);let r=0;for(;t<n.length;t++,r++)if(!(n[t].match(/\w/)&&r<20)){if(n[t]===";")break;return-1}return t}function Oe(n,t,r){return{err:{code:n,msg:t,line:r.line||r,col:r.col}}}function lo(n){return At(n)}function co(n){return At(n)}function Ve(n,t){const r=n.substring(0,t).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}function ht(n){return n.startIndex+n[1].length}const fo={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(n,t){return t},attributeValueProcessor:function(n,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(n,t,r){return n},captureMetaData:!1},po=function(n){return Object.assign({},fo,n)};let xt;typeof Symbol!="function"?xt="@@xmlMetadata":xt=Symbol("XML Node Metadata");class at{constructor(t){this.tagname=t,this.child=[],this[":@"]={}}add(t,r){t==="__proto__"&&(t="#__proto__"),this.child.push({[t]:r})}addChild(t,r){t.tagname==="__proto__"&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push({[t.tagname]:t.child,":@":t[":@"]}):this.child.push({[t.tagname]:t.child}),r!==void 0&&(this.child[this.child.length-1][xt]={startIndex:r})}static getMetaDataSymbol(){return xt}}class ho{constructor(t){this.suppressValidationErr=!t}readDocType(t,r){const a={};if(t[r+3]==="O"&&t[r+4]==="C"&&t[r+5]==="T"&&t[r+6]==="Y"&&t[r+7]==="P"&&t[r+8]==="E"){r=r+9;let i=1,u=!1,c=!1,b="";for(;r<t.length;r++)if(t[r]==="<"&&!c){if(u&&ut(t,"!ENTITY",r)){r+=7;let p,m;[p,m,r]=this.readEntityExp(t,r+1,this.suppressValidationErr),m.indexOf("&")===-1&&(a[p]={regx:RegExp(`&${p};`,"g"),val:m})}else if(u&&ut(t,"!ELEMENT",r)){r+=8;const{index:p}=this.readElementExp(t,r+1);r=p}else if(u&&ut(t,"!ATTLIST",r))r+=8;else if(u&&ut(t,"!NOTATION",r)){r+=9;const{index:p}=this.readNotationExp(t,r+1,this.suppressValidationErr);r=p}else if(ut(t,"!--",r))c=!0;else throw new Error("Invalid DOCTYPE");i++,b=""}else if(t[r]===">"){if(c?t[r-1]==="-"&&t[r-2]==="-"&&(c=!1,i--):i--,i===0)break}else t[r]==="["?u=!0:b+=t[r];if(i!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:a,i:r}}readEntityExp(t,r){r=$e(t,r);let a="";for(;r<t.length&&!/\s/.test(t[r])&&t[r]!=='"'&&t[r]!=="'";)a+=t[r],r++;if(mt(a),r=$e(t,r),!this.suppressValidationErr){if(t.substring(r,r+6).toUpperCase()==="SYSTEM")throw new Error("External entities are not supported");if(t[r]==="%")throw new Error("Parameter entities are not supported")}let i="";return[r,i]=this.readIdentifierVal(t,r,"entity"),r--,[a,i,r]}readNotationExp(t,r){r=$e(t,r);let a="";for(;r<t.length&&!/\s/.test(t[r]);)a+=t[r],r++;!this.suppressValidationErr&&mt(a),r=$e(t,r);const i=t.substring(r,r+6).toUpperCase();if(!this.suppressValidationErr&&i!=="SYSTEM"&&i!=="PUBLIC")throw new Error(`Expected SYSTEM or PUBLIC, found "${i}"`);r+=i.length,r=$e(t,r);let u=null,c=null;if(i==="PUBLIC")[r,u]=this.readIdentifierVal(t,r,"publicIdentifier"),r=$e(t,r),(t[r]==='"'||t[r]==="'")&&([r,c]=this.readIdentifierVal(t,r,"systemIdentifier"));else if(i==="SYSTEM"&&([r,c]=this.readIdentifierVal(t,r,"systemIdentifier"),!this.suppressValidationErr&&!c))throw new Error("Missing mandatory system identifier for SYSTEM notation");return{notationName:a,publicIdentifier:u,systemIdentifier:c,index:--r}}readIdentifierVal(t,r,a){let i="";const u=t[r];if(u!=='"'&&u!=="'")throw new Error(`Expected quoted string, found "${u}"`);for(r++;r<t.length&&t[r]!==u;)i+=t[r],r++;if(t[r]!==u)throw new Error(`Unterminated ${a} value`);return r++,[r,i]}readElementExp(t,r){r=$e(t,r);let a="";for(;r<t.length&&!/\s/.test(t[r]);)a+=t[r],r++;if(!this.suppressValidationErr&&!At(a))throw new Error(`Invalid element name: "${a}"`);r=$e(t,r);let i="";if(t[r]==="E"&&ut(t,"MPTY",r))r+=4;else if(t[r]==="A"&&ut(t,"NY",r))r+=2;else if(t[r]==="("){for(r++;r<t.length&&t[r]!==")";)i+=t[r],r++;if(t[r]!==")")throw new Error("Unterminated content model")}else if(!this.suppressValidationErr)throw new Error(`Invalid Element Expression, found "${t[r]}"`);return{elementName:a,contentModel:i.trim(),index:r}}readAttlistExp(t,r){r=$e(t,r);let a="";for(;r<t.length&&!/\s/.test(t[r]);)a+=t[r],r++;mt(a),r=$e(t,r);let i="";for(;r<t.length&&!/\s/.test(t[r]);)i+=t[r],r++;if(!mt(i))throw new Error(`Invalid attribute name: "${i}"`);r=$e(t,r);let u="";if(t.substring(r,r+8).toUpperCase()==="NOTATION"){if(u="NOTATION",r+=8,r=$e(t,r),t[r]!=="(")throw new Error(`Expected '(', found "${t[r]}"`);r++;let b=[];for(;r<t.length&&t[r]!==")";){let p="";for(;r<t.length&&t[r]!=="|"&&t[r]!==")";)p+=t[r],r++;if(p=p.trim(),!mt(p))throw new Error(`Invalid notation name: "${p}"`);b.push(p),t[r]==="|"&&(r++,r=$e(t,r))}if(t[r]!==")")throw new Error("Unterminated list of notations");r++,u+=" ("+b.join("|")+")"}else{for(;r<t.length&&!/\s/.test(t[r]);)u+=t[r],r++;const b=["CDATA","ID","IDREF","IDREFS","ENTITY","ENTITIES","NMTOKEN","NMTOKENS"];if(!this.suppressValidationErr&&!b.includes(u.toUpperCase()))throw new Error(`Invalid attribute type: "${u}"`)}r=$e(t,r);let c="";return t.substring(r,r+8).toUpperCase()==="#REQUIRED"?(c="#REQUIRED",r+=8):t.substring(r,r+7).toUpperCase()==="#IMPLIED"?(c="#IMPLIED",r+=7):[r,c]=this.readIdentifierVal(t,r,"ATTLIST"),{elementName:a,attributeName:i,attributeType:u,defaultValue:c,index:r}}}const $e=(n,t)=>{for(;t<n.length&&/\s/.test(n[t]);)t++;return t};function ut(n,t,r){for(let a=0;a<t.length;a++)if(t[a]!==n[r+a+1])return!1;return!0}function mt(n){if(At(n))return n;throw new Error(`Invalid entity name ${n}`)}const mo=/^[-+]?0x[a-fA-F0-9]+$/,go=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,Eo={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};function yo(n,t={}){if(t=Object.assign({},Eo,t),!n||typeof n!="string")return n;let r=n.trim();if(t.skipLike!==void 0&&t.skipLike.test(r))return n;if(n==="0")return 0;if(t.hex&&mo.test(r))return No(r,16);if(r.search(/.+[eE].+/)!==-1)return Ao(n,r,t);{const a=go.exec(r);if(a){const i=a[1]||"",u=a[2];let c=xo(a[3]);const b=i?n[u.length+1]===".":n[u.length]===".";if(!t.leadingZeros&&(u.length>1||u.length===1&&!b))return n;{const p=Number(r),m=String(p);if(p===0)return p;if(m.search(/[eE]/)!==-1)return t.eNotation?p:n;if(r.indexOf(".")!==-1)return m==="0"||m===c||m===`${i}${c}`?p:n;let _=u?c:r;return u?_===m||i+_===m?p:n:_===m||_===i+m?p:n}}else return n}}const bo=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function Ao(n,t,r){if(!r.eNotation)return n;const a=t.match(bo);if(a){let i=a[1]||"";const u=a[3].indexOf("e")===-1?"E":"e",c=a[2],b=i?n[c.length+1]===u:n[c.length]===u;return c.length>1&&b?n:c.length===1&&(a[3].startsWith(`.${u}`)||a[3][0]===u)?Number(t):r.leadingZeros&&!b?(t=(a[1]||"")+a[3],Number(t)):n}else return n}function xo(n){return n&&n.indexOf(".")!==-1&&(n=n.replace(/0+$/,""),n==="."?n="0":n[0]==="."?n="0"+n:n[n.length-1]==="."&&(n=n.substring(0,n.length-1))),n}function No(n,t){if(parseInt)return parseInt(n,t);if(Number.parseInt)return Number.parseInt(n,t);if(window&&window.parseInt)return window.parseInt(n,t);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")}function Zt(n){return typeof n=="function"?n:Array.isArray(n)?t=>{for(const r of n)if(typeof r=="string"&&t===r||r instanceof RegExp&&r.test(t))return!0}:()=>!1}class Co{constructor(t){this.options=t,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(r,a)=>String.fromCodePoint(Number.parseInt(a,10))},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(r,a)=>String.fromCodePoint(Number.parseInt(a,16))}},this.addExternalEntities=Do,this.parseXml=Bo,this.parseTextData=vo,this.resolveNameSpace=wo,this.buildAttributesMap=To,this.isItStopNode=Ro,this.replaceEntitiesValue=Oo,this.readStopNodeData=Fo,this.saveTextToParentTag=ko,this.addChild=So,this.ignoreAttributesFn=Zt(this.options.ignoreAttributes)}}function Do(n){const t=Object.keys(n);for(let r=0;r<t.length;r++){const a=t[r];this.lastEntities[a]={regex:new RegExp("&"+a+";","g"),val:n[a]}}}function vo(n,t,r,a,i,u,c){if(n!==void 0&&(this.options.trimValues&&!a&&(n=n.trim()),n.length>0)){c||(n=this.replaceEntitiesValue(n));const b=this.options.tagValueProcessor(t,n,r,i,u);return b==null?n:typeof b!=typeof n||b!==n?b:this.options.trimValues?Tt(n,this.options.parseTagValue,this.options.numberParseOptions):n.trim()===n?Tt(n,this.options.parseTagValue,this.options.numberParseOptions):n}}function wo(n){if(this.options.removeNSPrefix){const t=n.split(":"),r=n.charAt(0)==="/"?"/":"";if(t[0]==="xmlns")return"";t.length===2&&(n=r+t[1])}return n}const _o=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function To(n,t,r){if(this.options.ignoreAttributes!==!0&&typeof n=="string"){const a=Gt(n,_o),i=a.length,u={};for(let c=0;c<i;c++){const b=this.resolveNameSpace(a[c][1]);if(this.ignoreAttributesFn(b,t))continue;let p=a[c][4],m=this.options.attributeNamePrefix+b;if(b.length)if(this.options.transformAttributeName&&(m=this.options.transformAttributeName(m)),m==="__proto__"&&(m="#__proto__"),p!==void 0){this.options.trimValues&&(p=p.trim()),p=this.replaceEntitiesValue(p);const _=this.options.attributeValueProcessor(b,p,t);_==null?u[m]=p:typeof _!=typeof p||_!==p?u[m]=_:u[m]=Tt(p,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(u[m]=!0)}if(!Object.keys(u).length)return;if(this.options.attributesGroupName){const c={};return c[this.options.attributesGroupName]=u,c}return u}}const Bo=function(n){n=n.replace(/\r\n?/g,`
16
+ `);const t=new at("!xml");let r=t,a="",i="";const u=new ho(this.options.processEntities);for(let c=0;c<n.length;c++)if(n[c]==="<")if(n[c+1]==="/"){const p=lt(n,">",c,"Closing Tag is not closed.");let m=n.substring(c+2,p).trim();if(this.options.removeNSPrefix){const V=m.indexOf(":");V!==-1&&(m=m.substr(V+1))}this.options.transformTagName&&(m=this.options.transformTagName(m)),r&&(a=this.saveTextToParentTag(a,r,i));const _=i.substring(i.lastIndexOf(".")+1);if(m&&this.options.unpairedTags.indexOf(m)!==-1)throw new Error(`Unpaired tag can not be used as closing tag: </${m}>`);let D=0;_&&this.options.unpairedTags.indexOf(_)!==-1?(D=i.lastIndexOf(".",i.lastIndexOf(".")-1),this.tagsNodeStack.pop()):D=i.lastIndexOf("."),i=i.substring(0,D),r=this.tagsNodeStack.pop(),a="",c=p}else if(n[c+1]==="?"){let p=_t(n,c,!1,"?>");if(!p)throw new Error("Pi Tag is not closed.");if(a=this.saveTextToParentTag(a,r,i),!(this.options.ignoreDeclaration&&p.tagName==="?xml"||this.options.ignorePiTags)){const m=new at(p.tagName);m.add(this.options.textNodeName,""),p.tagName!==p.tagExp&&p.attrExpPresent&&(m[":@"]=this.buildAttributesMap(p.tagExp,i,p.tagName)),this.addChild(r,m,i,c)}c=p.closeIndex+1}else if(n.substr(c+1,3)==="!--"){const p=lt(n,"-->",c+4,"Comment is not closed.");if(this.options.commentPropName){const m=n.substring(c+4,p-2);a=this.saveTextToParentTag(a,r,i),r.add(this.options.commentPropName,[{[this.options.textNodeName]:m}])}c=p}else if(n.substr(c+1,2)==="!D"){const p=u.readDocType(n,c);this.docTypeEntities=p.entities,c=p.i}else if(n.substr(c+1,2)==="!["){const p=lt(n,"]]>",c,"CDATA is not closed.")-2,m=n.substring(c+9,p);a=this.saveTextToParentTag(a,r,i);let _=this.parseTextData(m,r.tagname,i,!0,!1,!0,!0);_==null&&(_=""),this.options.cdataPropName?r.add(this.options.cdataPropName,[{[this.options.textNodeName]:m}]):r.add(this.options.textNodeName,_),c=p+2}else{let p=_t(n,c,this.options.removeNSPrefix),m=p.tagName;const _=p.rawTagName;let D=p.tagExp,V=p.attrExpPresent,j=p.closeIndex;this.options.transformTagName&&(m=this.options.transformTagName(m)),r&&a&&r.tagname!=="!xml"&&(a=this.saveTextToParentTag(a,r,i,!1));const Y=r;Y&&this.options.unpairedTags.indexOf(Y.tagname)!==-1&&(r=this.tagsNodeStack.pop(),i=i.substring(0,i.lastIndexOf("."))),m!==t.tagname&&(i+=i?"."+m:m);const ie=c;if(this.isItStopNode(this.options.stopNodes,i,m)){let v="";if(D.length>0&&D.lastIndexOf("/")===D.length-1)m[m.length-1]==="/"?(m=m.substr(0,m.length-1),i=i.substr(0,i.length-1),D=m):D=D.substr(0,D.length-1),c=p.closeIndex;else if(this.options.unpairedTags.indexOf(m)!==-1)c=p.closeIndex;else{const K=this.readStopNodeData(n,_,j+1);if(!K)throw new Error(`Unexpected end of ${_}`);c=K.i,v=K.tagContent}const H=new at(m);m!==D&&V&&(H[":@"]=this.buildAttributesMap(D,i,m)),v&&(v=this.parseTextData(v,m,i,!0,V,!0,!0)),i=i.substr(0,i.lastIndexOf(".")),H.add(this.options.textNodeName,v),this.addChild(r,H,i,ie)}else{if(D.length>0&&D.lastIndexOf("/")===D.length-1){m[m.length-1]==="/"?(m=m.substr(0,m.length-1),i=i.substr(0,i.length-1),D=m):D=D.substr(0,D.length-1),this.options.transformTagName&&(m=this.options.transformTagName(m));const v=new at(m);m!==D&&V&&(v[":@"]=this.buildAttributesMap(D,i,m)),this.addChild(r,v,i,ie),i=i.substr(0,i.lastIndexOf("."))}else{const v=new at(m);this.tagsNodeStack.push(r),m!==D&&V&&(v[":@"]=this.buildAttributesMap(D,i,m)),this.addChild(r,v,i,ie),r=v}a="",c=j}}else a+=n[c];return t.child};function So(n,t,r,a){this.options.captureMetaData||(a=void 0);const i=this.options.updateTag(t.tagname,r,t[":@"]);i===!1||(typeof i=="string"&&(t.tagname=i),n.addChild(t,a))}const Oo=function(n){if(this.options.processEntities){for(let t in this.docTypeEntities){const r=this.docTypeEntities[t];n=n.replace(r.regx,r.val)}for(let t in this.lastEntities){const r=this.lastEntities[t];n=n.replace(r.regex,r.val)}if(this.options.htmlEntities)for(let t in this.htmlEntities){const r=this.htmlEntities[t];n=n.replace(r.regex,r.val)}n=n.replace(this.ampEntity.regex,this.ampEntity.val)}return n};function ko(n,t,r,a){return n&&(a===void 0&&(a=t.child.length===0),n=this.parseTextData(n,t.tagname,r,!1,t[":@"]?Object.keys(t[":@"]).length!==0:!1,a),n!==void 0&&n!==""&&t.add(this.options.textNodeName,n),n=""),n}function Ro(n,t,r){const a="*."+r;for(const i in n){const u=n[i];if(a===u||t===u)return!0}return!1}function Io(n,t,r=">"){let a,i="";for(let u=t;u<n.length;u++){let c=n[u];if(a)c===a&&(a="");else if(c==='"'||c==="'")a=c;else if(c===r[0])if(r[1]){if(n[u+1]===r[1])return{data:i,index:u}}else return{data:i,index:u};else c===" "&&(c=" ");i+=c}}function lt(n,t,r,a){const i=n.indexOf(t,r);if(i===-1)throw new Error(a);return i+t.length-1}function _t(n,t,r,a=">"){const i=Io(n,t+1,a);if(!i)return;let u=i.data;const c=i.index,b=u.search(/\s/);let p=u,m=!0;b!==-1&&(p=u.substring(0,b),u=u.substring(b+1).trimStart());const _=p;if(r){const D=p.indexOf(":");D!==-1&&(p=p.substr(D+1),m=p!==i.data.substr(D+1))}return{tagName:p,tagExp:u,closeIndex:c,attrExpPresent:m,rawTagName:_}}function Fo(n,t,r){const a=r;let i=1;for(;r<n.length;r++)if(n[r]==="<")if(n[r+1]==="/"){const u=lt(n,">",r,`${t} is not closed`);if(n.substring(r+2,u).trim()===t&&(i--,i===0))return{tagContent:n.substring(a,r),i:u};r=u}else if(n[r+1]==="?")r=lt(n,"?>",r+1,"StopNode is not closed.");else if(n.substr(r+1,3)==="!--")r=lt(n,"-->",r+3,"StopNode is not closed.");else if(n.substr(r+1,2)==="![")r=lt(n,"]]>",r,"StopNode is not closed.")-2;else{const u=_t(n,r,">");u&&((u&&u.tagName)===t&&u.tagExp[u.tagExp.length-1]!=="/"&&i++,r=u.closeIndex)}}function Tt(n,t,r){if(t&&typeof n=="string"){const a=n.trim();return a==="true"?!0:a==="false"?!1:yo(n,r)}else return to(n)?n:""}const Bt=at.getMetaDataSymbol();function Po(n,t){return Jt(n,t)}function Jt(n,t,r){let a;const i={};for(let u=0;u<n.length;u++){const c=n[u],b=Lo(c);let p="";if(r===void 0?p=b:p=r+"."+b,b===t.textNodeName)a===void 0?a=c[b]:a+=""+c[b];else{if(b===void 0)continue;if(c[b]){let m=Jt(c[b],t,p);const _=$o(m,t);c[Bt]!==void 0&&(m[Bt]=c[Bt]),c[":@"]?Vo(m,c[":@"],p,t):Object.keys(m).length===1&&m[t.textNodeName]!==void 0&&!t.alwaysCreateTextNode?m=m[t.textNodeName]:Object.keys(m).length===0&&(t.alwaysCreateTextNode?m[t.textNodeName]="":m=""),i[b]!==void 0&&i.hasOwnProperty(b)?(Array.isArray(i[b])||(i[b]=[i[b]]),i[b].push(m)):t.isArray(b,p,_)?i[b]=[m]:i[b]=m}}}return typeof a=="string"?a.length>0&&(i[t.textNodeName]=a):a!==void 0&&(i[t.textNodeName]=a),i}function Lo(n){const t=Object.keys(n);for(let r=0;r<t.length;r++){const a=t[r];if(a!==":@")return a}}function Vo(n,t,r,a){if(t){const i=Object.keys(t),u=i.length;for(let c=0;c<u;c++){const b=i[c];a.isArray(b,r+"."+b,!0,!0)?n[b]=[t[b]]:n[b]=t[b]}}}function $o(n,t){const{textNodeName:r}=t,a=Object.keys(n).length;return!!(a===0||a===1&&(n[r]||typeof n[r]=="boolean"||n[r]===0))}class Mo{constructor(t){this.externalEntities={},this.options=po(t)}parse(t,r){if(typeof t!="string"&&t.toString)t=t.toString();else if(typeof t!="string")throw new Error("XML data is accepted in String or Bytes[] form.");if(r){r===!0&&(r={});const u=Xt(t,r);if(u!==!0)throw Error(`${u.err.msg}:${u.err.line}:${u.err.col}`)}const a=new Co(this.options);a.addExternalEntities(this.externalEntities);const i=a.parseXml(t);return this.options.preserveOrder||i===void 0?i:Po(i,this.options)}addEntity(t,r){if(r.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(t.indexOf("&")!==-1||t.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '&#xD;'");if(r==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[t]=r}static getMetaDataSymbol(){return at.getMetaDataSymbol()}}const Uo=`
17
+ `;function qo(n,t){let r="";return t.format&&t.indentBy.length>0&&(r=Uo),er(n,t,"",r)}function er(n,t,r,a){let i="",u=!1;for(let c=0;c<n.length;c++){const b=n[c],p=Ho(b);if(p===void 0)continue;let m="";if(r.length===0?m=p:m=`${r}.${p}`,p===t.textNodeName){let Y=b[p];jo(m,t)||(Y=t.tagValueProcessor(p,Y),Y=rr(Y,t)),u&&(i+=a),i+=Y,u=!1;continue}else if(p===t.cdataPropName){u&&(i+=a),i+=`<![CDATA[${b[p][0][t.textNodeName]}]]>`,u=!1;continue}else if(p===t.commentPropName){i+=a+`<!--${b[p][0][t.textNodeName]}-->`,u=!0;continue}else if(p[0]==="?"){const Y=tr(b[":@"],t),ie=p==="?xml"?"":a;let v=b[p][0][t.textNodeName];v=v.length!==0?" "+v:"",i+=ie+`<${p}${v}${Y}?>`,u=!0;continue}let _=a;_!==""&&(_+=t.indentBy);const D=tr(b[":@"],t),V=a+`<${p}${D}`,j=er(b[p],t,m,_);t.unpairedTags.indexOf(p)!==-1?t.suppressUnpairedNode?i+=V+">":i+=V+"/>":(!j||j.length===0)&&t.suppressEmptyNode?i+=V+"/>":j&&j.endsWith(">")?i+=V+`>${j}${a}</${p}>`:(i+=V+">",j&&a!==""&&(j.includes("/>")||j.includes("</"))?i+=a+t.indentBy+j+a:i+=j,i+=`</${p}>`),u=!0}return i}function Ho(n){const t=Object.keys(n);for(let r=0;r<t.length;r++){const a=t[r];if(n.hasOwnProperty(a)&&a!==":@")return a}}function tr(n,t){let r="";if(n&&!t.ignoreAttributes)for(let a in n){if(!n.hasOwnProperty(a))continue;let i=t.attributeValueProcessor(a,n[a]);i=rr(i,t),i===!0&&t.suppressBooleanAttributes?r+=` ${a.substr(t.attributeNamePrefix.length)}`:r+=` ${a.substr(t.attributeNamePrefix.length)}="${i}"`}return r}function jo(n,t){n=n.substr(0,n.length-t.textNodeName.length-1);let r=n.substr(n.lastIndexOf(".")+1);for(let a in t.stopNodes)if(t.stopNodes[a]===n||t.stopNodes[a]==="*."+r)return!0;return!1}function rr(n,t){if(n&&n.length>0&&t.processEntities)for(let r=0;r<t.entities.length;r++){const a=t.entities[r];n=n.replace(a.regex,a.val)}return n}const Ko={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(n,t){return t},attributeValueProcessor:function(n,t){return t},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1};function nt(n){this.options=Object.assign({},Ko,n),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=Zt(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=zo),this.processTextOrObjNode=Go,this.options.format?(this.indentate=Xo,this.tagEndChar=`>
18
18
  `,this.newLine=`
19
- `):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}tt.prototype.build=function(n){return this.options.preserveOrder?So(n,this.options):(Array.isArray(n)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(n={[this.options.arrayNodeName]:n}),this.j2x(n,0,[]).val)},tt.prototype.j2x=function(n,t,r){let u="",i="";const l=r.join(".");for(let p in n)if(Object.prototype.hasOwnProperty.call(n,p))if(typeof n[p]>"u")this.isAttribute(p)&&(i+="");else if(n[p]===null)this.isAttribute(p)||p===this.options.cdataPropName?i+="":p[0]==="?"?i+=this.indentate(t)+"<"+p+"?"+this.tagEndChar:i+=this.indentate(t)+"<"+p+"/"+this.tagEndChar;else if(n[p]instanceof Date)i+=this.buildTextValNode(n[p],p,"",t);else if(typeof n[p]!="object"){const N=this.isAttribute(p);if(N&&!this.ignoreAttributesFn(N,l))u+=this.buildAttrPairStr(N,""+n[p]);else if(!N)if(p===this.options.textNodeName){let h=this.options.tagValueProcessor(p,""+n[p]);i+=this.replaceEntitiesValue(h)}else i+=this.buildTextValNode(n[p],p,"",t)}else if(Array.isArray(n[p])){const N=n[p].length;let h="",m="";for(let B=0;B<N;B++){const T=n[p][B];if(!(typeof T>"u"))if(T===null)p[0]==="?"?i+=this.indentate(t)+"<"+p+"?"+this.tagEndChar:i+=this.indentate(t)+"<"+p+"/"+this.tagEndChar;else if(typeof T=="object")if(this.options.oneListGroup){const U=this.j2x(T,t+1,r.concat(p));h+=U.val,this.options.attributesGroupName&&T.hasOwnProperty(this.options.attributesGroupName)&&(m+=U.attrStr)}else h+=this.processTextOrObjNode(T,p,t,r);else if(this.options.oneListGroup){let U=this.options.tagValueProcessor(p,T);U=this.replaceEntitiesValue(U),h+=U}else h+=this.buildTextValNode(T,p,"",t)}this.options.oneListGroup&&(h=this.buildObjectNode(h,p,m,t)),i+=h}else if(this.options.attributesGroupName&&p===this.options.attributesGroupName){const N=Object.keys(n[p]),h=N.length;for(let m=0;m<h;m++)u+=this.buildAttrPairStr(N[m],""+n[p][N[m]])}else i+=this.processTextOrObjNode(n[p],p,t,r);return{attrStr:u,val:i}},tt.prototype.buildAttrPairStr=function(n,t){return t=this.options.attributeValueProcessor(n,""+t),t=this.replaceEntitiesValue(t),this.options.suppressBooleanAttributes&&t==="true"?" "+n:" "+n+'="'+t+'"'};function Fo(n,t,r,u){const i=this.j2x(n,r+1,u.concat(t));return n[this.options.textNodeName]!==void 0&&Object.keys(n).length===1?this.buildTextValNode(n[this.options.textNodeName],t,i.attrStr,r):this.buildObjectNode(i.val,t,i.attrStr,r)}tt.prototype.buildObjectNode=function(n,t,r,u){if(n==="")return t[0]==="?"?this.indentate(u)+"<"+t+r+"?"+this.tagEndChar:this.indentate(u)+"<"+t+r+this.closeTag(t)+this.tagEndChar;{let i="</"+t+this.tagEndChar,l="";return t[0]==="?"&&(l="?",i=""),(r||r==="")&&n.indexOf("<")===-1?this.indentate(u)+"<"+t+r+l+">"+n+i:this.options.commentPropName!==!1&&t===this.options.commentPropName&&l.length===0?this.indentate(u)+`<!--${n}-->`+this.newLine:this.indentate(u)+"<"+t+r+l+this.tagEndChar+n+this.indentate(u)+i}},tt.prototype.closeTag=function(n){let t="";return this.options.unpairedTags.indexOf(n)!==-1?this.options.suppressUnpairedNode||(t="/"):this.options.suppressEmptyNode?t="/":t=`></${n}`,t},tt.prototype.buildTextValNode=function(n,t,r,u){if(this.options.cdataPropName!==!1&&t===this.options.cdataPropName)return this.indentate(u)+`<![CDATA[${n}]]>`+this.newLine;if(this.options.commentPropName!==!1&&t===this.options.commentPropName)return this.indentate(u)+`<!--${n}-->`+this.newLine;if(t[0]==="?")return this.indentate(u)+"<"+t+r+"?"+this.tagEndChar;{let i=this.options.tagValueProcessor(t,n);return i=this.replaceEntitiesValue(i),i===""?this.indentate(u)+"<"+t+r+this.closeTag(t)+this.tagEndChar:this.indentate(u)+"<"+t+r+">"+i+"</"+t+this.tagEndChar}},tt.prototype.replaceEntitiesValue=function(n){if(n&&n.length>0&&this.options.processEntities)for(let t=0;t<this.options.entities.length;t++){const r=this.options.entities[t];n=n.replace(r.regex,r.val)}return n};function Io(n){return this.options.indentBy.repeat(n)}function Po(n){return n.startsWith(this.options.attributeNamePrefix)&&n!==this.options.textNodeName?n.substr(this.attrPrefixLen):!1}const Lo={validate:Gt},Vo={ignoreAttributes:!1,attributeNamePrefix:"@_",textNodeName:"#text",ignoreDeclaration:!1,commentPropName:"#comment",cdataPropName:"__cdata",preserveOrder:!0,parseAttributeValue:!1,trimValues:!0,parseTagValue:!1,processEntities:!0,htmlEntities:!1,ignoreNameSpace:!1,allowBooleanAttributes:!0,unpairedTags:[],stopNodes:[],alwaysCreateTextNode:!1},Mo={ignoreAttributes:!1,attributeNamePrefix:"@_",textNodeName:"#text",format:!0,indentBy:" ",suppressEmptyNode:!1,suppressBooleanAttributes:!1,suppressUnpairedNode:!1},Uo=n=>{try{const t=Lo.validate(n,{allowBooleanAttributes:!0});return t===!0?{valid:!0}:{valid:!1,error:`Line ${t.err.line}: ${t.err.msg}`}}catch(t){return{valid:!1,error:t instanceof Error?t.message:"Unknown validation error"}}},Bt=(n,t)=>{try{return new _o({...Vo,...t}).parse(n)}catch(r){throw new Error(`XML 解析失败: ${r instanceof Error?r.message:"Unknown error"}`)}},St=(n,t)=>{try{let u=new tt({...Mo,format:t?.format??!0,indentBy:t?.indentBy??" "}).build(n);return t?.showDeclaration!==!1&&!u.startsWith("<?xml")&&(u=`<?xml version="1.0" encoding="UTF-8"?>
20
- `+u),u}catch(r){throw new Error(`XML 构建失败: ${r instanceof Error?r.message:"Unknown error"}`)}},qo=n=>Array.isArray(n)?Ze(n,{format:!1}):St(n,{format:!1,showDeclaration:!1}),$o=(n,t)=>{const r=Bt(n);return Array.isArray(r)?Ze(r,{indent:t?.indentBy}):St(r,t)},Ze=(n,t={})=>{const r=t.indent!==void 0?t.indent:" ",u=t.level||0,i=t.format!==!1,l=i?r.repeat(u):"",p=i?`
21
- `:"";let N="";for(const h of n){if(h["?xml"]){const _=h[":@"]||{},oe=Object.entries(_).map(([ge,re])=>`${ge.startsWith("@_")?ge.substring(2):ge}="${re}"`).join(" ");N+=`<?xml ${oe}?>${p}`;continue}if(h["#comment"]){const _=h["#comment"];if(Array.isArray(_)&&_.length>0){const oe=_[0]["#text"]||_[0];N+=`${l}<!--${oe}-->${p}`}continue}const m=Object.keys(h).find(_=>!_.startsWith(":")&&!_.startsWith("#")&&!_.startsWith("__"));if(!m)continue;const B=h[m],T=h[":@"]||{},U=Object.entries(T).map(([_,oe])=>`${_.startsWith("@_")?_.substring(2):_}="${oe}"`).join(" "),V=U?" "+U:"";if(!Array.isArray(B)||B.length===0){N+=`${l}<${m}${V}/>${p}`;continue}const ae=B.length===1&&B[0]["#text"]!==void 0;if(B.some(_=>_.__cdata)){const _=B.find(oe=>oe.__cdata);if(_){const oe=_.__cdata[0]["#text"]||"";N+=`${l}<${m}${V}><![CDATA[${oe}]]></${m}>${p}`}}else if(ae){const _=B[0]["#text"];N+=`${l}<${m}${V}>${_}</${m}>${p}`}else N+=`${l}<${m}${V}>${p}`,N+=Ze(B,{indent:r,level:u+1,format:i}),N+=`${l}</${m}>${p}`}return N},jo={key:0,class:"xml-format__toolbar"},Xo={class:"xml-format__actions"},Ho=["disabled"],Go=["disabled"],Ko=["disabled"],zo=["disabled"],Yo=["disabled"],Wo={class:"xml-format__info"},Qo={key:0,class:"xml-format__status xml-format__status--success"},Zo={key:1,class:"xml-format__status xml-format__status--error"},Jo={class:"xml-format__content"},es={key:0,class:"xml-format__error"},ts={key:1,class:"xml-format__error"},rs={key:2,class:"xml-format__viewer"},ns=Et(s.defineComponent({__name:"index",props:{modelValue:{default:""},readonly:{type:Boolean,default:!1},maxDepth:{default:10},showToolbar:{type:Boolean,default:!0},theme:{default:"github-light"},showComments:{type:Boolean,default:!0},showCdata:{type:Boolean,default:!0},preserveWhitespace:{type:Boolean,default:!1}},emits:["update:modelValue","copy-success","copy-error","expand-all","collapse-all","compress","format"],setup(n,{expose:t,emit:r}){s.useCssVars(F=>({"0fcb236c":V.value.colors.border,"696d646e":V.value.colors.background,"04d7c46d":V.value.colors.text,"5c81327b":V.value.colors.surfaceBackground,"19bfcd84":V.value.colors.buttonBorder,"0acf2140":V.value.colors.buttonBackground,"6397f282":V.value.colors.buttonText,"1fde7fdc":V.value.colors.buttonBackgroundHover,"5a1e0b30":V.value.colors.buttonPrimary,"64044bec":V.value.colors.buttonPrimaryHover,"764c78c3":V.value.colors.success,"66965b5e":V.value.colors.successBackground,d5598a70:V.value.colors.error,d7aedbd4:V.value.colors.errorBackground}));const u=n,i=r,l=s.ref(null),p=s.ref(""),N=s.ref(new Set),h=s.ref(null),m=s.ref(""),B=s.ref(""),T=s.computed(()=>p.value===""),U=s.computed(()=>m.value?null:h.value!==null?h.value:l.value),V=s.computed(()=>Mn(u.theme)),ae=s.computed(()=>{const F=U.value;return!F||!Array.isArray(F)?[]:F.map((x,S)=>({node:x,originalIndex:S})).filter(x=>!x.node["?xml"])}),le=s.computed(()=>{const F=U.value;if(!F||!Array.isArray(F))return null;const x=F.find(j=>j["?xml"]);if(!x||!x[":@"])return null;const S=x[":@"],R=[];return S["@_version"]&&R.push(`version="${S["@_version"]}"`),S["@_encoding"]&&R.push(`encoding="${S["@_encoding"]}"`),S["@_standalone"]&&R.push(`standalone="${S["@_standalone"]}"`),R.length>0?`<?xml ${R.join(" ")}?>`:null}),_=s.computed(()=>ae.value),oe=F=>{if(!F||!F.trim()){p.value="",l.value=null,B.value="",h.value=null,m.value="";return}try{const x=Uo(F);if(!x.valid){p.value=x.error||"Invalid XML",l.value=null,B.value="";return}B.value=F,l.value=Bt(F),p.value="",h.value=null,m.value="",s.nextTick(()=>{re()})}catch(x){p.value=x instanceof Error?x.message:"Unknown parse error",l.value=null,B.value="",h.value=null,m.value=""}},ge=F=>{N.value.has(F)?N.value.delete(F):N.value.add(F)},re=()=>{const F=new Set,x=(S,R="")=>{Array.isArray(S)&&S.forEach((j,M)=>{const J=Object.keys(j).find(P=>!P.startsWith(":")&&!P.startsWith("#"));if(!J)return;const D=R?`${R}.${J}[${M}]`:`${J}[${M}]`;F.add(D);const w=j[J];Array.isArray(w)&&x(w,D+"."+J)})};ae.value.forEach(({node:S,originalIndex:R})=>{const j=Object.keys(S).find(M=>!M.startsWith(":")&&!M.startsWith("#"));if(j){const M=`${j}[${R}]`;F.add(M);const J=S[j];Array.isArray(J)&&x(J,M+"."+j)}}),N.value=F,i("expand-all")},De=()=>{N.value.clear(),i("collapse-all")},Ae=async()=>{if(!(!T.value||!l.value))try{const F=Array.isArray(l.value)?Ze(l.value,{indent:" "}):St(l.value,{format:!0,indentBy:" "});await navigator.clipboard.writeText(F),i("copy-success",F)}catch(F){const x=F instanceof Error?F:new Error("Copy failed");i("copy-error",x),console.error("Failed to copy XML:",F)}},H=()=>{if(!(!T.value||!l.value))try{const F=qo(l.value);i("update:modelValue",F),i("compress",F)}catch(F){console.error("Failed to compress XML:",F)}},A=()=>{if(T.value)try{const F=$o(u.modelValue,{format:!0,indentBy:" "});i("update:modelValue",F),i("format",F)}catch(F){console.error("Failed to format XML:",F)}},de=F=>{if(!F||!F.expression.trim()){k();return}if(!l.value||!B.value){m.value="No valid XML data to filter";return}try{const S=new $t.DOMParser().parseFromString(B.value,"text/xml"),R=en.select(F.expression,S);if(!R||Array.isArray(R)&&R.length===0){h.value=[],m.value="";return}const j=new $t.XMLSerializer;let M="";Array.isArray(R)?(M=`<result>
22
- `,R.forEach(J=>{J.nodeType===1?M+=" "+j.serializeToString(J)+`
23
- `:J.nodeType===2?M+=` <attribute name="${J.name}" value="${J.value}"/>
24
- `:J.nodeType===3&&(M+=` <text>${J.nodeValue}</text>
25
- `)}),M+="</result>"):M=j.serializeToString(R),h.value=Bt(M),m.value="",s.nextTick(()=>{re()})}catch(x){m.value=x instanceof Error?x.message:"Filter execution error",h.value=null}},k=()=>{h.value=null,m.value="",s.nextTick(()=>{re()})},I=async F=>{try{const x=typeof F=="string"?F:JSON.stringify(F,null,2);await navigator.clipboard.writeText(x),i("copy-success",x)}catch(x){const S=x instanceof Error?x:new Error("Copy failed");i("copy-error",S),console.error("Failed to copy value:",x)}},ee=(F,x,S)=>{if(!(!l.value||!Array.isArray(l.value)))try{const R=F.split(/\./).filter(Boolean);let j=l.value;for(let J=0;J<R.length;J++){const D=R[J],w=D.match(/^(.+?)\[(\d+)\]$/);if(w){const P=w[1],L=parseInt(w[2]);if(J===R.length-1){if(Array.isArray(j)&&j[L]){const W=j[L];if(W[x]){const C=W[x];delete W[x],W[S]=C}}}else Array.isArray(j)&&j[L]&&(j=j[L])}else j[D]&&(j=j[D])}const M=Ze(l.value,{indent:" "});i("update:modelValue",M)}catch(R){console.error("Failed to update tag name:",R)}},K=(F,x,S)=>{if(!(!l.value||!Array.isArray(l.value)))try{const R=F.split(/\./).filter(Boolean);let j=l.value;for(let J=0;J<R.length;J++){const D=R[J],w=D.match(/^(.+?)\[(\d+)\]$/);if(w){const P=w[1],L=parseInt(w[2]);if(J===R.length-1){if(Array.isArray(j)&&j[L]){const C=j[L][":@"];if(C&&C[`@_${x}`]!==void 0){const ne=C[`@_${x}`];delete C[`@_${x}`],C[`@_${S}`]=ne}}}else Array.isArray(j)&&j[L]&&(j=j[L])}else j[D]&&(j=j[D])}const M=Ze(l.value,{indent:" "});i("update:modelValue",M)}catch(R){console.error("Failed to update attribute name:",R)}},q=(F,x,S)=>{if(!(!l.value||!Array.isArray(l.value)))try{const R=F.split(/\./).filter(Boolean);let j=l.value;for(let J=0;J<R.length;J++){const D=R[J],w=D.match(/^(.+?)\[(\d+)\]$/);if(w){const P=w[1],L=parseInt(w[2]);if(J===R.length-1){if(Array.isArray(j)&&j[L]){const C=j[L][":@"];C&&C[`@_${x}`]!==void 0&&(C[`@_${x}`]=S)}}else Array.isArray(j)&&j[L]&&(j=j[L])}else j[D]&&(j=j[D])}const M=Ze(l.value,{indent:" "});i("update:modelValue",M)}catch(R){console.error("Failed to update attribute value:",R)}},pe=(F,x)=>{if(!(!l.value||!Array.isArray(l.value)))try{const S=F.split(/\./).filter(Boolean);let R=l.value,j="";for(let J=0;J<S.length;J++){const D=S[J],w=D.match(/^(.+?)\[(\d+)\]$/);if(w){const P=w[1],L=parseInt(w[2]);if(J===S.length-1){if(Array.isArray(R)&&R[L]){const W=R[L];if(j=Object.keys(W).find(C=>!C.startsWith(":")&&!C.startsWith("#"))||"",j&&Array.isArray(W[j])){const C=W[j],ne=C.findIndex(Ee=>Ee["#text"]!==void 0);ne!==-1?C[ne]["#text"]=x:C.push({"#text":x})}}}else Array.isArray(R)&&R[L]&&(R=R[L])}else R[D]&&(R=R[D])}const M=Ze(l.value,{indent:" "});i("update:modelValue",M)}catch(S){console.error("Failed to update text content:",S)}},he=(F,x)=>{if(!(!l.value||!Array.isArray(l.value)))try{const S=F.split(/\./).filter(Boolean);let R=l.value;for(let M=0;M<S.length;M++){const J=S[M],D=J.match(/^(.+?)\[(\d+)\]$/);if(D){const w=D[1],P=parseInt(D[2]);if(M===S.length-1){if(Array.isArray(R)&&R[P]){const L=R[P],W=Object.keys(L).find(C=>!C.startsWith(":")&&!C.startsWith("#"));if(W&&Array.isArray(L[W])){const C=L[W],ne=C.findIndex(Ee=>Ee.__cdata!==void 0);if(ne!==-1){const Ee=C[ne];Array.isArray(Ee.__cdata)&&Ee.__cdata[0]&&(Ee.__cdata[0]["#text"]=x)}else C.push({__cdata:[{"#text":x}]})}}}else Array.isArray(R)&&R[P]&&(R=R[P])}else R[J]&&(R=R[J])}const j=Ze(l.value,{indent:" "});i("update:modelValue",j)}catch(S){console.error("Failed to update CDATA content:",S)}};return s.watch(()=>u.modelValue,F=>{oe(F)},{immediate:!0}),t({copyXml:Ae,compressSource:H,formatSource:A,expandAll:re,collapseAll:De,toggleExpand:ge,filter:de,clearFilter:k,isValidXml:()=>T.value,getParsedXml:()=>l.value,getFilteredXml:()=>h.value,getExpandedNodes:()=>N.value,getParseError:()=>p.value,getFilterError:()=>m.value,parseXmlString:F=>oe(F),copyValue:F=>I(F)}),(F,x)=>(s.openBlock(),s.createElementBlock("div",{class:s.normalizeClass(["xml-format",`xml-format--${V.value.name}`])},[F.showToolbar?(s.openBlock(),s.createElementBlock("div",jo,[s.createElementVNode("div",Xo,[s.createElementVNode("button",{class:"xml-format__btn xml-format__btn--primary",onClick:Ae,disabled:!T.value,title:"Copy XML"}," 📋 Copy ",8,Ho),s.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:re,disabled:!T.value,title:"Expand All"}," ⬇️ Expand All ",8,Go),s.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:De,disabled:!T.value,title:"Collapse All"}," ➡️ Collapse All ",8,Ko),s.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:H,disabled:!T.value,title:"Compress XML"}," 📦 Compress ",8,zo),s.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:A,disabled:!T.value,title:"Format XML"}," ✨ Format ",8,Yo)]),s.createElementVNode("div",Wo,[T.value?(s.openBlock(),s.createElementBlock("span",Qo," ✅ Valid XML ")):(s.openBlock(),s.createElementBlock("span",Zo," ❌ Invalid XML "))])])):s.createCommentVNode("",!0),s.createElementVNode("div",Jo,[T.value?m.value?(s.openBlock(),s.createElementBlock("div",ts,[x[1]||(x[1]=s.createElementVNode("h4",null,"Filter Error:",-1)),s.createElementVNode("pre",null,s.toDisplayString(m.value),1)])):(s.openBlock(),s.createElementBlock("div",rs,[le.value?(s.openBlock(),s.createElementBlock("div",{key:0,class:"xml-declaration",style:s.normalizeStyle({color:V.value.colors.xmlDeclaration})},s.toDisplayString(le.value),5)):s.createCommentVNode("",!0),(s.openBlock(!0),s.createElementBlock(s.Fragment,null,s.renderList(_.value,(S,R)=>(s.openBlock(),s.createBlock(Vn,{key:R,node:S.node,index:S.originalIndex,level:0,expanded:N.value,theme:V.value,onToggleExpand:ge,onCopy:I,"onUpdate:tagName":ee,"onUpdate:attributeName":K,"onUpdate:attributeValue":q,"onUpdate:textContent":pe,"onUpdate:cdataContent":he},null,8,["node","index","expanded","theme"]))),128))])):(s.openBlock(),s.createElementBlock("div",es,[x[0]||(x[0]=s.createElementVNode("h4",null,"XML Parse Error:",-1)),s.createElementVNode("pre",null,s.toDisplayString(p.value),1)]))])],2))}}),[["__scopeId","data-v-b32c0437"]]),os=[Rt],ss={install:n=>{os.forEach(t=>{const r=t.name||t.__name||"UnknownComponent";n.component(r,t)})}};Ye.JsonFormat=Rt,Ye.XmlFormat=ns,Ye.default=ss,Object.defineProperties(Ye,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
19
+ `):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}nt.prototype.build=function(n){return this.options.preserveOrder?qo(n,this.options):(Array.isArray(n)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(n={[this.options.arrayNodeName]:n}),this.j2x(n,0,[]).val)},nt.prototype.j2x=function(n,t,r){let a="",i="";const u=r.join(".");for(let c in n)if(Object.prototype.hasOwnProperty.call(n,c))if(typeof n[c]>"u")this.isAttribute(c)&&(i+="");else if(n[c]===null)this.isAttribute(c)||c===this.options.cdataPropName?i+="":c[0]==="?"?i+=this.indentate(t)+"<"+c+"?"+this.tagEndChar:i+=this.indentate(t)+"<"+c+"/"+this.tagEndChar;else if(n[c]instanceof Date)i+=this.buildTextValNode(n[c],c,"",t);else if(typeof n[c]!="object"){const b=this.isAttribute(c);if(b&&!this.ignoreAttributesFn(b,u))a+=this.buildAttrPairStr(b,""+n[c]);else if(!b)if(c===this.options.textNodeName){let p=this.options.tagValueProcessor(c,""+n[c]);i+=this.replaceEntitiesValue(p)}else i+=this.buildTextValNode(n[c],c,"",t)}else if(Array.isArray(n[c])){const b=n[c].length;let p="",m="";for(let _=0;_<b;_++){const D=n[c][_];if(!(typeof D>"u"))if(D===null)c[0]==="?"?i+=this.indentate(t)+"<"+c+"?"+this.tagEndChar:i+=this.indentate(t)+"<"+c+"/"+this.tagEndChar;else if(typeof D=="object")if(this.options.oneListGroup){const V=this.j2x(D,t+1,r.concat(c));p+=V.val,this.options.attributesGroupName&&D.hasOwnProperty(this.options.attributesGroupName)&&(m+=V.attrStr)}else p+=this.processTextOrObjNode(D,c,t,r);else if(this.options.oneListGroup){let V=this.options.tagValueProcessor(c,D);V=this.replaceEntitiesValue(V),p+=V}else p+=this.buildTextValNode(D,c,"",t)}this.options.oneListGroup&&(p=this.buildObjectNode(p,c,m,t)),i+=p}else if(this.options.attributesGroupName&&c===this.options.attributesGroupName){const b=Object.keys(n[c]),p=b.length;for(let m=0;m<p;m++)a+=this.buildAttrPairStr(b[m],""+n[c][b[m]])}else i+=this.processTextOrObjNode(n[c],c,t,r);return{attrStr:a,val:i}},nt.prototype.buildAttrPairStr=function(n,t){return t=this.options.attributeValueProcessor(n,""+t),t=this.replaceEntitiesValue(t),this.options.suppressBooleanAttributes&&t==="true"?" "+n:" "+n+'="'+t+'"'};function Go(n,t,r,a){const i=this.j2x(n,r+1,a.concat(t));return n[this.options.textNodeName]!==void 0&&Object.keys(n).length===1?this.buildTextValNode(n[this.options.textNodeName],t,i.attrStr,r):this.buildObjectNode(i.val,t,i.attrStr,r)}nt.prototype.buildObjectNode=function(n,t,r,a){if(n==="")return t[0]==="?"?this.indentate(a)+"<"+t+r+"?"+this.tagEndChar:this.indentate(a)+"<"+t+r+this.closeTag(t)+this.tagEndChar;{let i="</"+t+this.tagEndChar,u="";return t[0]==="?"&&(u="?",i=""),(r||r==="")&&n.indexOf("<")===-1?this.indentate(a)+"<"+t+r+u+">"+n+i:this.options.commentPropName!==!1&&t===this.options.commentPropName&&u.length===0?this.indentate(a)+`<!--${n}-->`+this.newLine:this.indentate(a)+"<"+t+r+u+this.tagEndChar+n+this.indentate(a)+i}},nt.prototype.closeTag=function(n){let t="";return this.options.unpairedTags.indexOf(n)!==-1?this.options.suppressUnpairedNode||(t="/"):this.options.suppressEmptyNode?t="/":t=`></${n}`,t},nt.prototype.buildTextValNode=function(n,t,r,a){if(this.options.cdataPropName!==!1&&t===this.options.cdataPropName)return this.indentate(a)+`<![CDATA[${n}]]>`+this.newLine;if(this.options.commentPropName!==!1&&t===this.options.commentPropName)return this.indentate(a)+`<!--${n}-->`+this.newLine;if(t[0]==="?")return this.indentate(a)+"<"+t+r+"?"+this.tagEndChar;{let i=this.options.tagValueProcessor(t,n);return i=this.replaceEntitiesValue(i),i===""?this.indentate(a)+"<"+t+r+this.closeTag(t)+this.tagEndChar:this.indentate(a)+"<"+t+r+">"+i+"</"+t+this.tagEndChar}},nt.prototype.replaceEntitiesValue=function(n){if(n&&n.length>0&&this.options.processEntities)for(let t=0;t<this.options.entities.length;t++){const r=this.options.entities[t];n=n.replace(r.regex,r.val)}return n};function Xo(n){return this.options.indentBy.repeat(n)}function zo(n){return n.startsWith(this.options.attributeNamePrefix)&&n!==this.options.textNodeName?n.substr(this.attrPrefixLen):!1}const Wo={validate:Xt},Yo={ignoreAttributes:!1,attributeNamePrefix:"@_",textNodeName:"#text",ignoreDeclaration:!1,commentPropName:"#comment",cdataPropName:"__cdata",preserveOrder:!0,parseAttributeValue:!1,trimValues:!1,parseTagValue:!1,processEntities:!1,htmlEntities:!1,ignoreNameSpace:!1,allowBooleanAttributes:!0,unpairedTags:[],stopNodes:[],alwaysCreateTextNode:!1},Qo={ignoreAttributes:!1,attributeNamePrefix:"@_",textNodeName:"#text",format:!0,indentBy:" ",suppressEmptyNode:!1,suppressBooleanAttributes:!1,suppressUnpairedNode:!1},Zo=n=>{const t=/&([a-zA-Z0-9#]+);/g,r=["lt","gt","amp","quot","apos"];let a,i=1,u=0;for(;(a=t.exec(n))!==null;){const c=a[1],b=a.index,p=n.substring(u,b);if(i+=(p.match(/\n/g)||[]).length,u=b,c.startsWith("#")){const m=c.substring(1);if(m.startsWith("x")||m.startsWith("X")){const _=m.substring(1);if(!/^[0-9a-fA-F]+$/.test(_))return{valid:!1,error:`Line ${i}: Invalid hexadecimal character reference '&${c};'`}}else if(!/^[0-9]+$/.test(m))return{valid:!1,error:`Line ${i}: Invalid numeric character reference '&${c};'`};continue}if(!r.includes(c))return{valid:!1,error:`Line ${i}: Invalid entity reference '&${c};'. Valid predefined entities are: &lt; &gt; &amp; &quot; &apos;`}}return{valid:!0}},Jo=n=>{try{const t=Wo.validate(n,{allowBooleanAttributes:!0});if(t!==!0)return{valid:!1,error:`Line ${t.err.line}: ${t.err.msg}`};const r=Zo(n);return r.valid?{valid:!0}:r}catch(t){return{valid:!1,error:t instanceof Error?t.message:"Unknown validation error"}}},St=(n,t)=>{try{return new Mo({...Yo,...t}).parse(n)}catch(r){throw new Error(`XML 解析失败: ${r instanceof Error?r.message:"Unknown error"}`)}},Ot=(n,t)=>{try{let a=new nt({...Qo,format:t?.format??!0,indentBy:t?.indentBy??" "}).build(n);return t?.showDeclaration!==!1&&!a.startsWith("<?xml")&&(a=`<?xml version="1.0" encoding="UTF-8"?>
20
+ `+a),a}catch(r){throw new Error(`XML 构建失败: ${r instanceof Error?r.message:"Unknown error"}`)}},es=(n,t)=>Array.isArray(n)?et(n,{format:!1,originalXml:t}):Ot(n,{format:!1,showDeclaration:!1}),ts=(n,t)=>{const r=St(n);return Array.isArray(r)?et(r,{indent:t?.indentBy,originalXml:n}):Ot(r,t)},nr=n=>{const t=new Set,r=/<([a-zA-Z0-9_-]+)(?:\s[^>]*)?\s*\/>/g;let a;for(;(a=r.exec(n))!==null;)t.add(a[1]);return t},et=(n,t={})=>{const r=t.indent!==void 0?t.indent:" ",a=t.level||0,i=t.format!==!1,u=i?r.repeat(a):"",c=i?`
21
+ `:"";let b=t.selfClosingTags;!b&&t.originalXml&&a===0&&(b=nr(t.originalXml));let p="";for(const m of n){if(m["?xml"]){const $=m[":@"]||{},ae=Object.entries($).map(([ee,U])=>`${ee.startsWith("@_")?ee.substring(2):ee}="${U}"`).join(" ");p+=`<?xml ${ae}?>${c}`;continue}if(m["#comment"]){const $=m["#comment"];if(Array.isArray($)&&$.length>0){const ae=$[0]["#text"]||$[0];p+=`${u}<!--${ae}-->${c}`}continue}const _=Object.keys(m).find($=>!$.startsWith(":")&&!$.startsWith("#")&&!$.startsWith("__"));if(!_)continue;const D=m[_],V=m[":@"]||{},j=Object.entries(V).map(([$,ae])=>`${$.startsWith("@_")?$.substring(2):$}="${ae}"`).join(" "),Y=j?" "+j:"";if(!Array.isArray(D)||D.length===0){b&&b.has(_)?p+=`${u}<${_}${Y}/>${c}`:p+=`${u}<${_}${Y}></${_}>${c}`;continue}const ie=D.length===1&&D[0]["#text"]!==void 0,v=ie?D[0]["#text"]:"",H=D.some($=>$.__cdata),K=ie&&v==="";if(H){const $=D.find(ae=>ae.__cdata);if($){const ae=$.__cdata[0]["#text"]||"";p+=`${u}<${_}${Y}><![CDATA[${ae}]]></${_}>${c}`}}else K?p+=`${u}<${_}${Y}></${_}>${c}`:ie?p+=`${u}<${_}${Y}>${v}</${_}>${c}`:(p+=`${u}<${_}${Y}>${c}`,p+=et(D,{indent:r,level:a+1,format:i,selfClosingTags:b}),p+=`${u}</${_}>${c}`)}return p},rs={key:0,class:"xml-format__toolbar"},ns={class:"xml-format__actions"},os=["disabled"],ss=["disabled"],is=["disabled"],as=["disabled"],us=["disabled"],ls={class:"xml-format__info"},cs={key:0,class:"xml-format__status xml-format__status--success"},fs={key:1,class:"xml-format__status xml-format__status--error"},ds={class:"xml-format__content"},ps={key:0,class:"xml-format__error"},hs={key:1,class:"xml-format__error"},ms={key:2,class:"xml-format__viewer"},gs=ft(o.defineComponent({__name:"index",props:{modelValue:{default:""},readonly:{type:Boolean,default:!1},maxDepth:{default:10},showToolbar:{type:Boolean,default:!0},theme:{default:"github-light"},showComments:{type:Boolean,default:!0},showCdata:{type:Boolean,default:!0},preserveWhitespace:{type:Boolean,default:!1}},emits:["update:modelValue","copy-success","copy-error","expand-all","collapse-all","compress","format"],setup(n,{expose:t,emit:r}){o.useCssVars(x=>({"0182b876":Y.value.colors.border,78071047:Y.value.colors.background,"43b18706":Y.value.colors.text,"52bf9efc":Y.value.colors.surfaceBackground,"7c039a52":Y.value.colors.buttonBorder,b936734e:Y.value.colors.buttonBackground,"46649ad0":Y.value.colors.buttonText,"56b12263":Y.value.colors.buttonBackgroundHover,"670324b7":Y.value.colors.buttonPrimary,"2dc50ec5":Y.value.colors.buttonPrimaryHover,"7549038a":Y.value.colors.success,"46d3d058":Y.value.colors.successBackground,"31b1cb4f":Y.value.colors.error,"07a53446":Y.value.colors.errorBackground}));const a=n,i=r,u=o.ref(null),c=o.ref(""),b=o.ref(new Set),p=o.ref(null),m=o.ref(""),_=o.ref(""),D=o.ref(new Set),V=o.computed(()=>c.value===""),j=o.computed(()=>m.value?null:p.value!==null?p.value:u.value),Y=o.computed(()=>Qn(a.theme)),ie=o.computed(()=>{const x=j.value;return!x||!Array.isArray(x)?[]:x.map((B,X)=>({node:B,originalIndex:X})).filter(B=>!B.node["?xml"])}),v=o.computed(()=>{const x=j.value;if(!x||!Array.isArray(x))return null;const B=x.find(F=>F["?xml"]);if(!B||!B[":@"])return null;const X=B[":@"],Z=[];return X["@_version"]&&Z.push(`version="${X["@_version"]}"`),X["@_encoding"]&&Z.push(`encoding="${X["@_encoding"]}"`),X["@_standalone"]&&Z.push(`standalone="${X["@_standalone"]}"`),Z.length>0?`<?xml ${Z.join(" ")}?>`:null}),H=o.computed(()=>ie.value),K=x=>{if(!x||!x.trim()){c.value="",u.value=null,_.value="",p.value=null,m.value="";return}try{const B=Jo(x);if(!B.valid){c.value=B.error||"Invalid XML",u.value=null,_.value="",D.value=new Set;return}_.value=x,D.value=nr(x),u.value=St(x),c.value="",p.value=null,m.value="",o.nextTick(()=>{ae()})}catch(B){c.value=B instanceof Error?B.message:"Unknown parse error",u.value=null,_.value="",p.value=null,m.value=""}},$=x=>{b.value.has(x)?b.value.delete(x):b.value.add(x)},ae=()=>{const x=new Set,B=(X,Z="")=>{Array.isArray(X)&&X.forEach((F,le)=>{const w=Object.keys(F).find(G=>!G.startsWith(":")&&!G.startsWith("#"));if(!w)return;const k=Z?`${Z}.${w}[${le}]`:`${w}[${le}]`;x.add(k);const L=F[w];Array.isArray(L)&&B(L,k+"."+w)})};ie.value.forEach(({node:X,originalIndex:Z})=>{const F=Object.keys(X).find(le=>!le.startsWith(":")&&!le.startsWith("#"));if(F){const le=`${F}[${Z}]`;x.add(le);const w=X[F];Array.isArray(w)&&B(w,le+"."+F)}}),b.value=x,i("expand-all")},ee=()=>{b.value.clear(),i("collapse-all")},U=async()=>{if(V.value)try{const x=j.value||u.value;if(!x)return;const B=Array.isArray(x)?et(x,{indent:" ",selfClosingTags:D.value}):Ot(x,{format:!0,indentBy:" "});await navigator.clipboard.writeText(B),i("copy-success",B)}catch(x){const B=x instanceof Error?x:new Error("Copy failed");i("copy-error",B),console.error("Failed to copy XML:",x)}},A=()=>{if(!(!V.value||!u.value))try{const x=es(u.value,a.modelValue);i("update:modelValue",x),i("compress",x)}catch(x){console.error("Failed to compress XML:",x)}},te=()=>{if(V.value)try{const x=ts(a.modelValue,{format:!0,indentBy:" "});i("update:modelValue",x),i("format",x)}catch(x){console.error("Failed to format XML:",x)}},N=x=>{if(!x||!x.expression.trim()){T();return}if(!u.value||!_.value){m.value="No valid XML data to filter";return}try{const X=new Ht.DOMParser().parseFromString(_.value,"text/xml"),Z=on.select(x.expression,X);if(!Z||Array.isArray(Z)&&Z.length===0){p.value=[],m.value="";return}const F=new Ht.XMLSerializer;let le="";Array.isArray(Z)?(le=`<result>
22
+ `,Z.forEach(w=>{w.nodeType===1?le+=" "+F.serializeToString(w)+`
23
+ `:w.nodeType===2?le+=` <attribute name="${w.name}" value="${w.value}"/>
24
+ `:w.nodeType===3&&(le+=` <text>${w.nodeValue}</text>
25
+ `)}),le+="</result>"):le=F.serializeToString(Z),p.value=St(le),m.value="",o.nextTick(()=>{ae()})}catch(B){m.value=B instanceof Error?B.message:"Filter execution error",p.value=null}},T=()=>{p.value=null,m.value="",o.nextTick(()=>{ae()})},q=async x=>{try{const B=typeof x=="string"?x:JSON.stringify(x,null,2);await navigator.clipboard.writeText(B),i("copy-success",B)}catch(B){const X=B instanceof Error?B:new Error("Copy failed");i("copy-error",X),console.error("Failed to copy value:",B)}},W=(x,B,X)=>{if(!(!u.value||!Array.isArray(u.value)))try{const Z=x.split(/\./).filter(Boolean);let F=u.value;for(let w=0;w<Z.length;w++){const k=Z[w],L=k.match(/^(.+?)\[(\d+)\]$/);if(L){const G=L[1],Q=parseInt(L[2]);if(w===Z.length-1){if(Array.isArray(F)&&F[Q]){const R=F[Q];if(R[B]){const J=R[B];delete R[B],R[X]=J,D.value.has(B)&&(D.value.delete(B),D.value.add(X))}}}else Array.isArray(F)&&F[Q]&&(F=F[Q])}else F[k]&&(F=F[k])}const le=et(u.value,{indent:" ",selfClosingTags:D.value});i("update:modelValue",le)}catch(Z){console.error("Failed to update tag name:",Z)}},M=(x,B,X)=>{if(!(!u.value||!Array.isArray(u.value)))try{const Z=x.split(/\./).filter(Boolean);let F=u.value;for(let w=0;w<Z.length;w++){const k=Z[w],L=k.match(/^(.+?)\[(\d+)\]$/);if(L){const G=L[1],Q=parseInt(L[2]);if(w===Z.length-1){if(Array.isArray(F)&&F[Q]){const J=F[Q][":@"];if(J&&J[`@_${B}`]!==void 0){const ge=J[`@_${B}`];delete J[`@_${B}`],J[`@_${X}`]=ge}}}else Array.isArray(F)&&F[Q]&&(F=F[Q])}else F[k]&&(F=F[k])}const le=et(u.value,{indent:" ",selfClosingTags:D.value});i("update:modelValue",le)}catch(Z){console.error("Failed to update attribute name:",Z)}},de=(x,B,X)=>{if(!(!u.value||!Array.isArray(u.value)))try{const Z=x.split(/\./).filter(Boolean);let F=u.value;for(let w=0;w<Z.length;w++){const k=Z[w],L=k.match(/^(.+?)\[(\d+)\]$/);if(L){const G=L[1],Q=parseInt(L[2]);if(w===Z.length-1){if(Array.isArray(F)&&F[Q]){const J=F[Q][":@"];J&&J[`@_${B}`]!==void 0&&(J[`@_${B}`]=X)}}else Array.isArray(F)&&F[Q]&&(F=F[Q])}else F[k]&&(F=F[k])}const le=et(u.value,{indent:" ",selfClosingTags:D.value});i("update:modelValue",le)}catch(Z){console.error("Failed to update attribute value:",Z)}},he=(x,B)=>{if(!(!u.value||!Array.isArray(u.value)))try{const X=x.split(/\./).filter(Boolean);let Z=u.value,F="";for(let w=0;w<X.length;w++){const k=X[w],L=k.match(/^(.+?)\[(\d+)\]$/);if(L){const G=L[1],Q=parseInt(L[2]);if(w===X.length-1){if(Array.isArray(Z)&&Z[Q]){const R=Z[Q];if(F=Object.keys(R).find(J=>!J.startsWith(":")&&!J.startsWith("#"))||"",F&&Array.isArray(R[F])){const J=R[F],ge=J.findIndex(Ee=>Ee["#text"]!==void 0);ge!==-1?J[ge]["#text"]=B:J.push({"#text":B})}}}else Array.isArray(Z)&&Z[Q]&&(Z=Z[Q])}else Z[k]&&(Z=Z[k])}const le=et(u.value,{indent:" ",selfClosingTags:D.value});i("update:modelValue",le)}catch(X){console.error("Failed to update text content:",X)}},ye=(x,B)=>{if(!(!u.value||!Array.isArray(u.value)))try{const X=x.split(/\./).filter(Boolean);let Z=u.value;for(let le=0;le<X.length;le++){const w=X[le],k=w.match(/^(.+?)\[(\d+)\]$/);if(k){const L=k[1],G=parseInt(k[2]);if(le===X.length-1){if(Array.isArray(Z)&&Z[G]){const Q=Z[G],R=Object.keys(Q).find(J=>!J.startsWith(":")&&!J.startsWith("#"));if(R&&Array.isArray(Q[R])){const J=Q[R],ge=J.findIndex(Ee=>Ee.__cdata!==void 0);if(ge!==-1){const Ee=J[ge];Array.isArray(Ee.__cdata)&&Ee.__cdata[0]&&(Ee.__cdata[0]["#text"]=B)}else J.push({__cdata:[{"#text":B}]})}}}else Array.isArray(Z)&&Z[G]&&(Z=Z[G])}else Z[w]&&(Z=Z[w])}const F=et(u.value,{indent:" ",selfClosingTags:D.value});i("update:modelValue",F)}catch(X){console.error("Failed to update CDATA content:",X)}};return o.watch(()=>a.modelValue,x=>{K(x)},{immediate:!0}),t({copyXml:U,compressSource:A,formatSource:te,expandAll:ae,collapseAll:ee,toggleExpand:$,filter:N,clearFilter:T,isValidXml:()=>V.value,getParsedXml:()=>u.value,getFilteredXml:()=>p.value,getExpandedNodes:()=>b.value,getParseError:()=>c.value,getFilterError:()=>m.value,parseXmlString:x=>K(x),copyValue:x=>q(x)}),(x,B)=>(o.openBlock(),o.createElementBlock("div",{class:o.normalizeClass(["xml-format",`xml-format--${Y.value.name}`])},[x.showToolbar?(o.openBlock(),o.createElementBlock("div",rs,[o.createElementVNode("div",ns,[o.createElementVNode("button",{class:"xml-format__btn xml-format__btn--primary",onClick:U,disabled:!V.value,title:"Copy XML"}," 📋 Copy ",8,os),o.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:ae,disabled:!V.value,title:"Expand All"}," ⬇️ Expand All ",8,ss),o.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:ee,disabled:!V.value,title:"Collapse All"}," ➡️ Collapse All ",8,is),o.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:A,disabled:!V.value,title:"Compress XML"}," 📦 Compress ",8,as),o.createElementVNode("button",{class:"xml-format__btn xml-format__btn--secondary",onClick:te,disabled:!V.value,title:"Format XML"}," ✨ Format ",8,us)]),o.createElementVNode("div",ls,[V.value?(o.openBlock(),o.createElementBlock("span",cs," ✅ Valid XML ")):(o.openBlock(),o.createElementBlock("span",fs," ❌ Invalid XML "))])])):o.createCommentVNode("",!0),o.createElementVNode("div",ds,[V.value?m.value?(o.openBlock(),o.createElementBlock("div",hs,[B[1]||(B[1]=o.createElementVNode("h4",null,"Filter Error:",-1)),o.createElementVNode("pre",null,o.toDisplayString(m.value),1)])):(o.openBlock(),o.createElementBlock("div",ms,[v.value?(o.openBlock(),o.createElementBlock("div",{key:0,class:"xml-declaration",style:o.normalizeStyle({color:Y.value.colors.xmlDeclaration})},o.toDisplayString(v.value),5)):o.createCommentVNode("",!0),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(H.value,(X,Z)=>(o.openBlock(),o.createBlock(Yn,{key:Z,node:X.node,index:X.originalIndex,level:0,expanded:b.value,theme:Y.value,selfClosingTags:D.value,onToggleExpand:$,onCopy:q,"onUpdate:tagName":W,"onUpdate:attributeName":M,"onUpdate:attributeValue":de,"onUpdate:textContent":he,"onUpdate:cdataContent":ye},null,8,["node","index","expanded","theme","selfClosingTags"]))),128))])):(o.openBlock(),o.createElementBlock("div",ps,[B[0]||(B[0]=o.createElementVNode("h4",null,"XML Parse Error:",-1)),o.createElementVNode("pre",null,o.toDisplayString(c.value),1)]))])],2))}}),[["__scopeId","data-v-c6e64630"]]),or={"github-light":{name:"github-light",colors:{background:"#ffffff",surfaceBackground:"#f6f8fa",hoverBackground:"#f3f4f6",border:"#d0d7de",text:"#24292f",textSecondary:"#57606a",buttonBackground:"#f6f8fa",buttonBackgroundHover:"#f3f4f6",buttonBorder:"#d0d7de",buttonText:"#24292f",buttonPrimary:"#1f883d",buttonPrimaryHover:"#1a7f37",success:"#1f883d",successBackground:"#dafbe1",error:"#cf222e",errorBackground:"#ffebe9",sqlKeyword:"#cf222e",sqlFunction:"#8250df",sqlString:"#0a3069",sqlNumber:"#0550ae",sqlComment:"#6e7781",sqlOperator:"#cf222e",sqlIdentifier:"#24292f",sqlPunctuation:"#24292f",collapsedBackground:"#ddf4ff",collapsedText:"#0969da",indentLine:"#d0d7de"}},"github-dark":{name:"github-dark",colors:{background:"#0d1117",surfaceBackground:"#161b22",hoverBackground:"#30363d",border:"#30363d",text:"#c9d1d9",textSecondary:"#8b949e",buttonBackground:"#21262d",buttonBackgroundHover:"#30363d",buttonBorder:"#30363d",buttonText:"#c9d1d9",buttonPrimary:"#238636",buttonPrimaryHover:"#2ea043",success:"#3fb950",successBackground:"#0f2e1c",error:"#f85149",errorBackground:"#3d1319",sqlKeyword:"#ff7b72",sqlFunction:"#d2a8ff",sqlString:"#a5d6ff",sqlNumber:"#79c0ff",sqlComment:"#8b949e",sqlOperator:"#ff7b72",sqlIdentifier:"#c9d1d9",sqlPunctuation:"#c9d1d9",collapsedBackground:"#1c2d41",collapsedText:"#58a6ff",indentLine:"#30363d"}},"min-light":{name:"min-light",colors:{background:"#ffffff",surfaceBackground:"#fafafa",hoverBackground:"#f5f5f5",border:"#e5e5e5",text:"#171717",textSecondary:"#737373",buttonBackground:"#fafafa",buttonBackgroundHover:"#f5f5f5",buttonBorder:"#e5e5e5",buttonText:"#171717",buttonPrimary:"#22c55e",buttonPrimaryHover:"#16a34a",success:"#22c55e",successBackground:"#dcfce7",error:"#ef4444",errorBackground:"#fee2e2",sqlKeyword:"#dc2626",sqlFunction:"#9333ea",sqlString:"#1e40af",sqlNumber:"#2563eb",sqlComment:"#737373",sqlOperator:"#dc2626",sqlIdentifier:"#171717",sqlPunctuation:"#171717",collapsedBackground:"#dbeafe",collapsedText:"#1d4ed8",indentLine:"#e0e0e0"}},"slack-ochin":{name:"slack-ochin",colors:{background:"#fef5ed",surfaceBackground:"#fef9f3",hoverBackground:"#f9f0e5",border:"#e9dcc9",text:"#3d3c40",textSecondary:"#616061",buttonBackground:"#fef9f3",buttonBackgroundHover:"#f9f0e5",buttonBorder:"#e9dcc9",buttonText:"#3d3c40",buttonPrimary:"#007a5a",buttonPrimaryHover:"#006644",success:"#007a5a",successBackground:"#d1f4e0",error:"#e01e5a",errorBackground:"#ffdbea",sqlKeyword:"#e01e5a",sqlFunction:"#8b2eff",sqlString:"#0b4c8c",sqlNumber:"#1264a3",sqlComment:"#616061",sqlOperator:"#e01e5a",sqlIdentifier:"#3d3c40",sqlPunctuation:"#3d3c40",collapsedBackground:"#d8eaf5",collapsedText:"#0b4c8c",indentLine:"#3e4348"}}},Es=n=>or[n]||or["github-light"],Nt=["SELECT","FROM","WHERE","JOIN","INNER","LEFT","RIGHT","FULL","OUTER","ON","GROUP","BY","HAVING","ORDER","LIMIT","OFFSET","INSERT","INTO","VALUES","UPDATE","SET","DELETE","CREATE","ALTER","DROP","TABLE","DATABASE","INDEX","VIEW","AND","OR","NOT","IN","BETWEEN","LIKE","IS","NULL","AS","DISTINCT","UNION","ALL","EXISTS","CASE","WHEN","THEN","ELSE","END"],ys=["WITH","SELECT","FROM","WHERE","GROUP BY","HAVING","ORDER BY","LIMIT","INSERT","UPDATE","DELETE","CREATE","ALTER","DROP","JOIN","INNER JOIN","LEFT JOIN","RIGHT JOIN","FULL JOIN","OUTER JOIN"],bs=n=>{try{if(!n||!n.trim())return{valid:!1,error:"SQL string is empty"};const t=n.toUpperCase();if(!Nt.some(b=>new RegExp(`\\b${b}\\b`).test(t)))return{valid:!1,error:"No valid SQL keywords found"};let a=0;for(const b of n)if(b==="("&&a++,b===")"&&a--,a<0)return{valid:!1,error:"Mismatched parentheses"};if(a!==0)return{valid:!1,error:"Mismatched parentheses"};let i=0,u=0,c=!1;for(let b=0;b<n.length;b++){const p=n[b];if(c){c=!1;continue}if(p==="\\"){c=!0;continue}p==="'"&&i++,p==='"'&&u++}return i%2!==0?{valid:!1,error:"Mismatched single quotes"}:u%2!==0?{valid:!1,error:"Mismatched double quotes"}:{valid:!0}}catch(t){return{valid:!1,error:t instanceof Error?t.message:"Unknown validation error"}}},sr=(n,t)=>{try{const r=t?.tabWidth||2,a=t?.keywordCase||"upper",i=" ".repeat(r);let u=n.trim();const c=[];u=u.replace(/(["'])(?:(?=(\\?))\2.)*?\1/g,v=>(c.push({type:"string",value:v}),`__PROTECTED_${c.length-1}__`)),u=u.replace(/--[^\n]*/g,v=>(c.push({type:"comment",value:v}),`__PROTECTED_${c.length-1}__`)),u=u.replace(/\/\*[\s\S]*?\*\//g,v=>(c.push({type:"comment",value:v}),`__PROTECTED_${c.length-1}__`)),u=u.replace(/,(?!\s)/g,", ").replace(/\s*\bAS\b\s*/gi," AS ").replace(/\s*\bOVER\b\s*/gi," OVER ").replace(/\s*\b(DESC|ASC)\b\s*/gi," $1 ").replace(/\s*([<>=!]+)\s*/g," $1 ").replace(/\s*\bON\b\s*/gi," ON ").replace(/\)([A-Z])/gi,") $1").replace(/[ \t]+/g," ").replace(/ +$/gm,"").replace(/^ +/gm,""),a==="upper"?Nt.forEach(v=>{const H=new RegExp(`\\b${v}\\b`,"gi");u=u.replace(H,v.toUpperCase())}):a==="lower"&&Nt.forEach(v=>{const H=new RegExp(`\\b${v}\\b`,"gi");u=u.replace(H,v.toLowerCase())});const b=["WITH","SELECT","FROM","WHERE","GROUP BY","HAVING","ORDER BY","LIMIT","OFFSET","INNER JOIN","LEFT JOIN","RIGHT JOIN","FULL JOIN","CROSS JOIN","OUTER JOIN","JOIN","UNION","UNION ALL","INTERSECT","EXCEPT","INSERT INTO","UPDATE","DELETE FROM","CREATE","ALTER","DROP"];b.sort((v,H)=>H.length-v.length);const p=[];b.forEach((v,H)=>{if(v.includes(" ")){const K=a==="upper"?v:v.toLowerCase(),$=new RegExp(`\\b${v}\\b`,"gi"),ae=`__KEYWORD_${H}__`;u=u.replace($,ae),p.push({placeholder:ae,original:K})}}),b.forEach(v=>{if(!v.includes(" ")){const H=a==="upper"?v:v.toLowerCase(),K=new RegExp(`\\b${v}\\b`,"gi");u=u.replace(K,`
26
+ ${H}`)}}),p.forEach(({placeholder:v,original:H})=>{u=u.replace(new RegExp(v,"g"),`
27
+ ${H}`)}),u=u.replace(/\b((?:INNER\s+|LEFT\s+|RIGHT\s+|FULL\s+|CROSS\s+|OUTER\s+)?JOIN\s+[^\n]+?)\s+ON\s+(.+?)(?=\n|$)/gi,(v,H,K)=>`${H}
28
+ ${i}${a==="upper"?"ON":"on"} ${K.trim()}`),u=u.replace(/\b(WHERE)\s+([^\n]+?)(?=\s+AND\b|\s+OR\b|\n|$)/gis,(v,H,K)=>{const $=a==="upper"?"WHERE":"where",ae=K.trim();return`${$}
29
+ ${i}${ae}`}),u=u.replace(/\b(HAVING)\s+(?!\n)(.+?)(?=\n|$)/gis,(v,H,K)=>`${a==="upper"?"HAVING":"having"}
30
+ ${i}${K.trim()}`),u=u.replace(/\b(ORDER BY)\s+(?!\n)([^,\n]+?)(?=\n|$|;)/gis,(v,H,K)=>{const $=a==="upper"?"ORDER BY":"order by";return K.includes(",")?v:`${$}
31
+ ${i}${K.trim()}`}),u=u.replace(/\b(INSERT\s+INTO)\s+(\w+)\s*\(([^)]+)\)\s*(VALUES)/gis,(v,H,K,$,ae)=>{const ee=a==="upper"?"INSERT INTO":"insert into",U=a==="upper"?"VALUES":"values",A=$.split(",").map(N=>N.trim());let te=`${ee} ${K}
32
+ (`;return te+=A.join(`,
33
+ `),te+=`)
34
+ ${U}`,te}),u=u.replace(/\b(VALUES)\s*\n?\s*\(([^)]+)\)/gis,(v,H,K)=>{const $=a==="upper"?"VALUES":"values",ae=K.split(/,\s*(?=(?:[^']*'[^']*')*[^']*$)/).map(U=>U.trim());let ee=`${$}
35
+ (`;return ee+=ae.join(`,
36
+ `),ee+=")",ee}),u=u.replace(/\b(UPDATE\s+)(\w+)\s+(SET)\s+([^\n]+?)(?=\n(?:WHERE)|$|;)/gis,(v,H,K,$,ae)=>{const ee=a==="upper"?"UPDATE":"update",U=a==="upper"?"SET":"set",A=ae.split(/,\s*(?![^()]*\))/).map(N=>N.trim());let te=`${ee} ${K}
37
+ ${U}`;return A.forEach((N,T)=>{te+=`
38
+ ${i}${N}`,T<A.length-1&&(te+=",")}),te}),["AND","OR"].forEach(v=>{const H=a==="upper"?v:v.toLowerCase(),K=new RegExp(`\\b${v}\\b`,"gi");u=u.replace(K,`
39
+ ${i}${H}`)});const _=u.split(`
40
+ `),D=[],V=v=>{const H=[];let K="",$=0;for(let ae=0;ae<v.length;ae++){const ee=v[ae];ee==="("?($++,K+=ee):ee===")"?($--,K+=ee):ee===","&&$===0?(H.push(K.trim()),K=""):K+=ee}return K.trim()&&H.push(K.trim()),H},j=v=>{if(!/\bCASE\b/i.test(v))return[v];const H=[],K=[];let $=v.replace(/(["'])(?:(?=(\\?))\2.)*?\1/g,te=>{const N=K.length;return K.push(te),`__STRING_${N}__`});const ae=/\b(CASE)\b([\s\S]*?)\b(END)\b/gi;let ee=0,U;for(;(U=ae.exec($))!==null;){if(U.index>ee){const T=$.substring(ee,U.index).trim();T&&H.push(T)}H.push("CASE");const N=U[2].split(/\b(WHEN|ELSE)\b/gi);for(let T=0;T<N.length;T++){const q=N[T].trim();if(q){if(/^WHEN$/i.test(q)){const W=N[++T]?.trim()||"",M=W.match(/^(.*?)\s+THEN\s+(.*)$/i);M?H.push(i+"WHEN "+M[1].trim()+" THEN "+M[2].trim()):H.push(i+"WHEN "+W)}else if(/^ELSE$/i.test(q)){const W=N[++T]?.trim()||"";H.push(i+"ELSE "+W)}}}H.push("END"),ee=ae.lastIndex}if(ee<$.length){const te=$.substring(ee).trim();te&&(H[H.length-1]+=" "+te)}return H.map(te=>te.replace(/__STRING_(\d+)__/g,(N,T)=>K[parseInt(T)]))};for(let v=0;v<_.length;v++){const H=_[v].trim();if(/^SELECT\b/i.test(H)){const K=H.match(/^(SELECT\s+(?:DISTINCT\s+)?)(.*)/i);if(K){const $=K[1].trim(),ae=K[2],ee=V(ae);D.push($),ee.forEach((U,A)=>{const te=A===ee.length-1;if(/\bCASE\b/i.test(U)){const N=j(U);N.forEach((T,q)=>{q===0?D.push(i+T):q===N.length-1?D.push(i+T+(te?"":",")):D.push(T)})}else te?D.push(i+U):D.push(i+U+",")})}else D.push(H)}else if(/^GROUP BY\b/i.test(H)){const K=H.match(/^(GROUP BY\s+)(.*)/i);if(K){const $=K[1].trim(),ae=K[2],ee=V(ae);ee.length>1?(D.push($),ee.forEach((U,A)=>{A===ee.length-1?D.push(i+U):D.push(i+U+",")})):D.push(H)}else D.push(H)}else if(/^ORDER BY\b/i.test(H)){const K=H.match(/^(ORDER BY\s+)(.*)/i);if(K){const $=K[1].trim(),ae=K[2],ee=V(ae);ee.length>1?(D.push($),ee.forEach((U,A)=>{A===ee.length-1?D.push(i+U):D.push(i+U+",")})):D.push(H)}else D.push(H)}else D.push(H)}u=D.join(`
41
+ `),u=u.split(`
42
+ `).filter(v=>v.trim().length>0).join(`
43
+ `),c.forEach((v,H)=>{u=u.replace(`__PROTECTED_${H}__`,v.value)});const Y=u.split(`
44
+ `),ie=[];for(let v=0;v<Y.length;v++){const H=Y[v],K=H.trim();if(H.startsWith(" ")||H.startsWith(" ")){ie.push(H);continue}if(b.some(U=>new RegExp(`^${U}\\b`,"i").test(K))){ie.push(K);continue}let ee="";for(let U=v-1;U>=0;U--){const A=Y[U].trim(),te=b.find(N=>new RegExp(`^${N}\\b`,"i").test(A));if(te){ee=te;break}}/^(AND|OR)\b/i.test(K)?ie.push(K):ee.match(/^(WHERE|HAVING)$/i)||ee.match(/JOIN$/i)||ee.match(/^ORDER BY$/i)?ie.push(i+K):ie.push(K)}return ie.join(`
45
+ `)}catch(r){throw new Error(`SQL 格式化失败: ${r instanceof Error?r.message:"Unknown error"}`)}},As=n=>{try{let t=n.replace(/--[^\n]*/g,"").replace(/\/\*[\s\S]*?\*\//g,"");const r=[];return t=t.replace(/(["'])(?:(?=(\\?))\2.)*?\1/g,a=>(r.push(a),`__STRING_${r.length-1}__`)),t=t.replace(/\s+/g," ").replace(/\s*([(),;])\s*/g,"$1").trim(),r.forEach((a,i)=>{t=t.replace(`__STRING_${i}__`,a)}),t}catch(t){throw new Error(`SQL 压缩失败: ${t instanceof Error?t.message:"Unknown error"}`)}},xs=n=>{const t=[];try{const a=sr(n,{keywordCase:"upper"}).split(`
46
+ `);let i=null,u=[],c=[];for(const b of a){const p=b.trim();if(!p){i&&u.push(b);continue}if(p.startsWith("--")||p.startsWith("/*")){i?u.push(b):c.push(b);continue}let _=!1,D="UNKNOWN";for(const V of ys)if(new RegExp(`^${V}\\b`,"i").test(p)){_=!0,D=V.replace(/ /g," ");break}_?(i&&u.length>0&&(i.content=u.join(`
47
+ `),i.raw=u.join(`
48
+ `),t.push(i)),u=[...c,b],c=[],i={type:D,content:"",raw:"",collapsible:!0,path:`clause-${t.length}`}):i?u.push(b):(u=[...c,b],c=[],i={type:"UNKNOWN",content:"",raw:"",collapsible:!1,path:`clause-${t.length}`})}return i&&u.length>0&&(i.content=u.join(`
49
+ `),i.raw=u.join(`
50
+ `),t.push(i)),c.length>0&&t.push({type:"UNKNOWN",content:c.join(`
51
+ `),raw:c.join(`
52
+ `),collapsible:!1,path:`clause-${t.length}`}),{clauses:t,raw:n}}catch{return{clauses:[{type:"UNKNOWN",content:n,raw:n,collapsible:!1,path:"clause-0"}],raw:n}}},Ns=n=>{const t=[];let r=n;const a=["COUNT","SUM","AVG","MAX","MIN","UPPER","LOWER","SUBSTRING","CONCAT","LENGTH","TRIM","NOW","DATE","YEAR","MONTH","DAY","COALESCE","CAST","CONVERT","ROUND","ABS","FLOOR","CEIL"],i=["=","!=","<>","<",">","<=",">=","+","-","*","/","%","||"],u=["(",")",",",";","."];for(;r.length>0;){let c=!1;const b=r.match(/^(\s+)/);if(b){t.push({type:"whitespace",value:b[1]}),r=r.slice(b[1].length);continue}const p=r.match(/^(--[^\n]*)/);if(p){t.push({type:"comment",value:p[1]}),r=r.slice(p[1].length);continue}const m=r.match(/^(\/\*[\s\S]*?\*\/)/);if(m){t.push({type:"comment",value:m[1]}),r=r.slice(m[1].length);continue}const _=r.match(/^(["'])(?:(?=(\\?))\2.)*?\1/);if(_){t.push({type:"string",value:_[0]}),r=r.slice(_[0].length);continue}const D=r.match(/^(\d+\.?\d*|\.\d+)/);if(D){t.push({type:"number",value:D[1]}),r=r.slice(D[1].length);continue}for(const j of i)if(r.startsWith(j)){t.push({type:"operator",value:j}),r=r.slice(j.length),c=!0;break}if(c)continue;for(const j of u)if(r.startsWith(j)){t.push({type:"punctuation",value:j}),r=r.slice(j.length),c=!0;break}if(c)continue;const V=r.match(/^([a-zA-Z_][a-zA-Z0-9_]*)/);if(V){const j=V[1],Y=j.toUpperCase();Nt.includes(Y)?t.push({type:"keyword",value:j}):a.includes(Y)?t.push({type:"function",value:j}):t.push({type:"identifier",value:j}),r=r.slice(j.length);continue}t.push({type:"punctuation",value:r[0]}),r=r.slice(1)}return t},Cs={key:0,class:"sql-format__toolbar"},Ds={class:"sql-format__actions"},vs=["disabled"],ws=["disabled"],_s=["disabled"],Ts=["disabled"],Bs=["disabled"],Ss={class:"sql-format__info"},Os={key:0,class:"sql-format__status sql-format__status--success"},ks={key:1,class:"sql-format__status sql-format__status--error"},Rs={class:"sql-format__content"},Is={key:0,class:"sql-format__error"},Fs={key:1,class:"sql-format__viewer"},Ps={key:0,class:"sql-format__clauses"},Ls=["onClick"],Vs=["onClick","title"],$s={key:1,class:"sql-format__toggle-spacer"},Ms={class:"sql-format__clause-keyword"},Us={class:"sql-format__clause-code"},qs=["innerHTML"],Hs={key:0,class:"sql-format__clause-content"},js={class:"sql-format__clause-code"},Ks=["innerHTML"],Gs={key:1,class:"sql-format__code"},Xs=["innerHTML"],zs=ft(o.defineComponent({__name:"index",props:{modelValue:{default:""},readonly:{type:Boolean,default:!1},showToolbar:{type:Boolean,default:!0},theme:{default:"github-light"},dialect:{default:"sql"},tabWidth:{default:2}},emits:["update:modelValue","copy-success","copy-error","expand-all","collapse-all","compress","format"],setup(n,{expose:t,emit:r}){o.useCssVars(N=>({"64cbdf35":_.value.colors.background,"1c3fa074":_.value.colors.text,"26a7cc9a":_.value.colors.border,ea614c58:_.value.colors.surfaceBackground,de6a0376:_.value.colors.buttonBorder,"5ee22ac7":_.value.colors.buttonBackground,"6cdafcf4":_.value.colors.buttonText,bcb15a96:_.value.colors.buttonBackgroundHover,"71cfc709":_.value.colors.buttonPrimary,"0109e09a":_.value.colors.buttonPrimaryHover,"09fa0cac":_.value.colors.successBackground,"358a4b5c":_.value.colors.success,f34a88a2:_.value.colors.errorBackground,"6ae6dfa1":_.value.colors.error,19523360:_.value.colors.textSecondary}));const a=n,i=r,u=o.ref(""),c=o.ref(a.dialect),b=o.ref([]),p=o.ref(new Set),m=o.computed(()=>u.value===""),_=o.computed(()=>Es(a.theme)),D=N=>{if(!N||!N.trim()){u.value="",b.value=[],p.value.clear();return}try{const T=bs(N);if(!T.valid){u.value=T.error||"Invalid SQL",b.value=[];return}const q=xs(N);b.value=q.clauses,p.value=new Set(q.clauses.map(W=>W.path||"")),u.value=""}catch(T){u.value=T instanceof Error?T.message:"Unknown parse error",b.value=[]}},V=N=>{const T=Ns(N),q=_.value.colors;return T.map(W=>{let M=q.text;switch(W.type){case"keyword":M=q.sqlKeyword;break;case"function":M=q.sqlFunction;break;case"string":M=q.sqlString;break;case"number":M=q.sqlNumber;break;case"comment":M=q.sqlComment;break;case"operator":M=q.sqlOperator;break;case"identifier":M=q.sqlIdentifier;break;case"punctuation":M=q.sqlPunctuation;break;case"whitespace":return W.value}const de=W.value.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;");return`<span style="color: ${M}">${de}</span>`}).join("")},j=N=>{p.value.has(N)?p.value.delete(N):p.value.add(N),p.value=new Set(p.value)},Y=N=>p.value.has(N),ie=N=>{const T=N.content.split(`
53
+ `);if(T.length===0)return"";for(const q of T)if(q.trim())return q;return""},v=N=>{const T=ie(N),q=Y(N.path||""),W=!!H(N);return N.collapsible&&!q&&W?`${V(T)}<span style="color: ${_.value.colors.textSecondary}; opacity: 0.6; font-style: italic; margin-left: 4px;"> ...</span>`:V(T)},H=N=>{const T=N.content.split(`
54
+ `);if(T.length<=1)return"";let q=0;for(let M=0;M<T.length;M++)if(T[M].trim()){q=M;break}return T.slice(q+1).join(`
55
+ `)},K=()=>{p.value=new Set(b.value.map(N=>N.path||"")),i("expand-all")},$=()=>{p.value=new Set,i("collapse-all")},ae=async()=>{if(m.value)try{await navigator.clipboard.writeText(a.modelValue),i("copy-success",a.modelValue)}catch(N){const T=N instanceof Error?N:new Error("Failed to copy");i("copy-error",T)}},ee=()=>{if(m.value)try{const N=sr(a.modelValue,{dialect:c.value,tabWidth:a.tabWidth});i("update:modelValue",N),i("format",N)}catch(N){console.error("Format error:",N)}},U=()=>{if(m.value)try{const N=As(a.modelValue);i("update:modelValue",N),i("compress",N)}catch(N){console.error("Compress error:",N)}},A=()=>null,te=()=>u.value;return o.watch(()=>a.modelValue,N=>{D(N)},{immediate:!0}),o.watch(()=>a.dialect,N=>{c.value=N}),t({copySql:ae,formatSource:ee,compressSource:U,expandAll:K,collapseAll:$,toggleExpand:j,isValidSql:()=>m.value,getParsedSql:A,getParseError:te}),(N,T)=>(o.openBlock(),o.createElementBlock("div",{class:o.normalizeClass(["sql-format",`sql-format--${_.value.name}`])},[N.showToolbar?(o.openBlock(),o.createElementBlock("div",Cs,[o.createElementVNode("div",Ds,[o.createElementVNode("button",{class:"sql-format__btn sql-format__btn--primary",onClick:ae,disabled:!m.value,title:"Copy SQL"}," 📋 Copy ",8,vs),o.createElementVNode("button",{class:"sql-format__btn sql-format__btn--secondary",onClick:ee,disabled:!m.value,title:"Format SQL"}," ✨ Format ",8,ws),o.createElementVNode("button",{class:"sql-format__btn sql-format__btn--secondary",onClick:U,disabled:!m.value,title:"Compress SQL"}," 📦 Compress ",8,_s),o.createElementVNode("button",{class:"sql-format__btn sql-format__btn--secondary",onClick:K,disabled:!m.value||b.value.length===0,title:"Expand All Clauses"}," ⬇️ Expand All ",8,Ts),o.createElementVNode("button",{class:"sql-format__btn sql-format__btn--secondary",onClick:$,disabled:!m.value||b.value.length===0,title:"Collapse All Clauses"}," ⬆️ Collapse All ",8,Bs),o.withDirectives(o.createElementVNode("select",{"onUpdate:modelValue":T[0]||(T[0]=q=>c.value=q),class:"sql-format__dialect-select",title:"SQL Dialect"},T[1]||(T[1]=[o.createStaticVNode('<option value="sql" data-v-64a81173>SQL</option><option value="mysql" data-v-64a81173>MySQL</option><option value="postgresql" data-v-64a81173>PostgreSQL</option><option value="sqlite" data-v-64a81173>SQLite</option><option value="plsql" data-v-64a81173>PL/SQL</option><option value="tsql" data-v-64a81173>T-SQL</option>',6)]),512),[[o.vModelSelect,c.value]])]),o.createElementVNode("div",Ss,[m.value?(o.openBlock(),o.createElementBlock("span",Os," ✅ Valid SQL ")):(o.openBlock(),o.createElementBlock("span",ks," ❌ Invalid SQL "))])])):o.createCommentVNode("",!0),o.createElementVNode("div",Rs,[m.value?(o.openBlock(),o.createElementBlock("div",Fs,[b.value.length>0?(o.openBlock(),o.createElementBlock("div",Ps,[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(b.value,q=>(o.openBlock(),o.createElementBlock("div",{key:q.path,class:"sql-format__clause"},[o.createElementVNode("div",{class:"sql-format__clause-header",onClick:W=>q.collapsible&&j(q.path||"")},[q.collapsible?(o.openBlock(),o.createElementBlock("button",{key:0,class:"sql-format__toggle-btn",onClick:o.withModifiers(W=>j(q.path||""),["stop"]),title:Y(q.path||"")?"Collapse":"Expand"},[o.createElementVNode("span",{class:o.normalizeClass(["sql-format__toggle-icon",{"sql-format__toggle-icon--expanded":Y(q.path||"")}])},"▶",2)],8,Vs)):(o.openBlock(),o.createElementBlock("span",$s)),o.createElementVNode("div",Ms,[o.createElementVNode("pre",Us,[o.createElementVNode("code",{innerHTML:v(q)},null,8,qs)])])],8,Ls),Y(q.path||"")&&H(q)?(o.openBlock(),o.createElementBlock("div",Hs,[o.createElementVNode("pre",js,[o.createElementVNode("code",{innerHTML:V(H(q))},null,8,Ks)])])):o.createCommentVNode("",!0)]))),128))])):(o.openBlock(),o.createElementBlock("pre",Gs,[o.createElementVNode("code",{innerHTML:V(a.modelValue)},null,8,Xs)]))])):(o.openBlock(),o.createElementBlock("div",Is,[T[2]||(T[2]=o.createElementVNode("h4",null,"SQL Parse Error:",-1)),o.createElementVNode("pre",null,o.toDisplayString(u.value),1)]))])],2))}}),[["__scopeId","data-v-64a81173"]]),Ws=[It],Ys={install:n=>{Ws.forEach(t=>{const r=t.name||t.__name||"UnknownComponent";n.component(r,t)})}};ze.JsonFormat=It,ze.SqlFormat=zs,ze.XmlFormat=gs,ze.default=Ys,Object.defineProperties(ze,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});