@opencloud-eu/web-pkg 6.2.0 → 7.0.0

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.
Files changed (92) hide show
  1. package/dist/assets/{worker-Bv-mZ-VL.js → worker-B8V6K8WY.js} +5 -5
  2. package/dist/assets/{worker-nUcRt7qV.js → worker-BjLAp2qA.js} +5 -5
  3. package/dist/assets/{worker-Dx2ttEp-.js → worker-Cz7k4ET0.js} +5 -5
  4. package/dist/{composables-CAlEpA5b.js → components-DGm07xAo.js} +8056 -10595
  5. package/dist/src/components/Avatars/AvatarUpload.vue.d.ts +0 -1
  6. package/dist/src/components/ContextActions/ContextMenuQuickAction.vue.d.ts +15 -9
  7. package/dist/src/components/CreateShortcutModal.vue.d.ts +15 -9
  8. package/dist/src/components/ImageCropper.vue.d.ts +12 -0
  9. package/dist/src/components/Spaces/SpaceImageModal.vue.d.ts +0 -1
  10. package/dist/src/components/index.d.ts +0 -1
  11. package/dist/src/composables/actions/files/index.d.ts +0 -21
  12. package/dist/src/composables/actions/spaces/index.d.ts +0 -12
  13. package/dist/src/composables/actions/types.d.ts +8 -7
  14. package/dist/src/composables/breadcrumbs/useBreadcrumbsFromPath.d.ts +1 -3
  15. package/dist/src/composables/driveResolver/useDriveResolver.d.ts +0 -1
  16. package/dist/src/composables/keyboardActions/useCropperKeyboardActions.d.ts +2 -1
  17. package/dist/src/composables/piniaStores/auth.d.ts +24 -2
  18. package/dist/src/composables/piniaStores/config/config.d.ts +1 -91
  19. package/dist/src/composables/piniaStores/config/types.d.ts +0 -20
  20. package/dist/src/composables/piniaStores/extensionRegistry/extensionRegistry.d.ts +4 -1
  21. package/dist/src/composables/piniaStores/messages.d.ts +12 -12
  22. package/dist/src/composables/piniaStores/spaces.d.ts +1 -3
  23. package/dist/src/composables/piniaStores/theme.d.ts +1 -1
  24. package/dist/src/composables/router/useFileRouteReplace.d.ts +0 -2
  25. package/dist/src/composables/spaces/useGetMatchingSpace.d.ts +0 -4
  26. package/dist/src/editor/components/SlashCommandMenu.vue.d.ts +9 -0
  27. package/dist/src/editor/components/TextEditorContent.vue.d.ts +7 -0
  28. package/dist/src/editor/components/TextEditorProvider.vue.d.ts +17 -0
  29. package/dist/src/editor/components/TextEditorToolbar.vue.d.ts +3 -0
  30. package/dist/src/editor/composables/index.d.ts +3 -0
  31. package/dist/src/editor/composables/strategies/html.d.ts +3 -0
  32. package/dist/src/editor/composables/strategies/index.d.ts +5 -0
  33. package/dist/src/editor/composables/strategies/markdown.d.ts +3 -0
  34. package/dist/src/editor/composables/strategies/plainText.d.ts +3 -0
  35. package/dist/src/editor/composables/strategies/tiptapJson.d.ts +3 -0
  36. package/dist/src/editor/composables/strategies/types.d.ts +10 -0
  37. package/dist/src/editor/composables/useContentStrategy.d.ts +5 -0
  38. package/dist/src/editor/composables/useEditorActions.d.ts +75 -0
  39. package/dist/src/editor/composables/useTextEditor.d.ts +2 -0
  40. package/dist/src/editor/extensions/index.d.ts +1 -0
  41. package/dist/src/editor/extensions/slashCommands.d.ts +16 -0
  42. package/dist/src/editor/index.d.ts +5 -0
  43. package/dist/src/editor/types.d.ts +29 -0
  44. package/dist/src/helpers/groupwareResponse.d.ts +1 -0
  45. package/dist/src/helpers/index.d.ts +2 -0
  46. package/dist/src/helpers/router/routeOptions.d.ts +1 -7
  47. package/dist/src/helpers/virtualCursorElement.d.ts +1 -0
  48. package/dist/src/router/index.d.ts +2 -1
  49. package/dist/src/router/utils.d.ts +1 -6
  50. package/dist/src/types.d.ts +1 -0
  51. package/dist/src/utils/dummyGettext.d.ts +6 -0
  52. package/dist/src/utils/index.d.ts +1 -0
  53. package/dist/web-pkg/editor.js +1360 -0
  54. package/dist/web-pkg.js +2845 -1480
  55. package/package.json +25 -8
  56. package/dist/TextEditor-CTRIgoeG.js +0 -819
  57. package/dist/src/components/TextEditor/TextEditor.vue.d.ts +0 -18
  58. package/dist/src/components/TextEditor/index.d.ts +0 -17
  59. package/dist/src/components/TextEditor/l18n.d.ts +0 -3
  60. package/dist/src/composables/actions/files/useFileActionsCopy.d.ts +0 -4
  61. package/dist/src/composables/actions/files/useFileActionsCopyPermanentLink.d.ts +0 -4
  62. package/dist/src/composables/actions/files/useFileActionsCreateLink.d.ts +0 -6
  63. package/dist/src/composables/actions/files/useFileActionsCreateNewFile.d.ts +0 -10
  64. package/dist/src/composables/actions/files/useFileActionsCreateNewFolder.d.ts +0 -9
  65. package/dist/src/composables/actions/files/useFileActionsCreateNewShortcut.d.ts +0 -8
  66. package/dist/src/composables/actions/files/useFileActionsCreateSpaceFromResource.d.ts +0 -4
  67. package/dist/src/composables/actions/files/useFileActionsDisableSync.d.ts +0 -5
  68. package/dist/src/composables/actions/files/useFileActionsDownloadArchive.d.ts +0 -4
  69. package/dist/src/composables/actions/files/useFileActionsEmptyTrashBin.d.ts +0 -8
  70. package/dist/src/composables/actions/files/useFileActionsEnableSync.d.ts +0 -5
  71. package/dist/src/composables/actions/files/useFileActionsFavorite.d.ts +0 -4
  72. package/dist/src/composables/actions/files/useFileActionsMove.d.ts +0 -4
  73. package/dist/src/composables/actions/files/useFileActionsOpenShortcut.d.ts +0 -5
  74. package/dist/src/composables/actions/files/useFileActionsPaste.d.ts +0 -4
  75. package/dist/src/composables/actions/files/useFileActionsRename.d.ts +0 -6
  76. package/dist/src/composables/actions/files/useFileActionsSetImage.d.ts +0 -4
  77. package/dist/src/composables/actions/files/useFileActionsShowActions.d.ts +0 -4
  78. package/dist/src/composables/actions/files/useFileActionsShowDetails.d.ts +0 -4
  79. package/dist/src/composables/actions/files/useFileActionsShowShares.d.ts +0 -5
  80. package/dist/src/composables/actions/files/useFileActionsToggleHideShare.d.ts +0 -5
  81. package/dist/src/composables/actions/spaces/useSpaceActionsDelete.d.ts +0 -6
  82. package/dist/src/composables/actions/spaces/useSpaceActionsDeleteImage.d.ts +0 -8
  83. package/dist/src/composables/actions/spaces/useSpaceActionsDisable.d.ts +0 -6
  84. package/dist/src/composables/actions/spaces/useSpaceActionsDuplicate.d.ts +0 -6
  85. package/dist/src/composables/actions/spaces/useSpaceActionsEditDescription.d.ts +0 -6
  86. package/dist/src/composables/actions/spaces/useSpaceActionsEditQuota.d.ts +0 -4
  87. package/dist/src/composables/actions/spaces/useSpaceActionsEditReadmeContent.d.ts +0 -4
  88. package/dist/src/composables/actions/spaces/useSpaceActionsNavigateToTrash.d.ts +0 -4
  89. package/dist/src/composables/actions/spaces/useSpaceActionsRename.d.ts +0 -6
  90. package/dist/src/composables/actions/spaces/useSpaceActionsRestore.d.ts +0 -6
  91. package/dist/src/composables/actions/spaces/useSpaceActionsSetIcon.d.ts +0 -6
  92. package/dist/src/composables/actions/spaces/useSpaceActionsShowMembers.d.ts +0 -4
@@ -1,15 +1,15 @@
1
- (function(){var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,a)=>(a=n==null?{}:e(i(n)),c(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),u=l(o(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=`~`;function i(){}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1));function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,n,i,o){if(typeof n!=`function`)throw TypeError(`The listener must be a function`);var s=new a(n,i||e,o),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],s]:e._events[c].push(s):(e._events[c]=s,e._eventsCount++),e}function s(e,t){--e._eventsCount===0?e._events=new i:delete e._events[t]}function c(){this._events=new i,this._eventsCount=0}c.prototype.eventNames=function(){var e=[],t,i;if(this._eventsCount===0)return e;for(i in t=this._events)n.call(t,i)&&e.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(t)):e},c.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,o=Array(a);i<a;i++)o[i]=n[i].fn;return o},c.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},c.prototype.emit=function(e,t,n,i,a,o){var s=r?r+e:e;if(!this._events[s])return!1;var c=this._events[s],l=arguments.length,u,d;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),l){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,a),!0;case 6:return c.fn.call(c.context,t,n,i,a,o),!0}for(d=1,u=Array(l-1);d<l;d++)u[d-1]=arguments[d];c.fn.apply(c.context,u)}else{var f=c.length,p;for(d=0;d<f;d++)switch(c[d].once&&this.removeListener(e,c[d].fn,void 0,!0),l){case 1:c[d].fn.call(c[d].context);break;case 2:c[d].fn.call(c[d].context,t);break;case 3:c[d].fn.call(c[d].context,t,n);break;case 4:c[d].fn.call(c[d].context,t,n,i);break;default:if(!u)for(p=1,u=Array(l-1);p<l;p++)u[p-1]=arguments[p];c[d].fn.apply(c[d].context,u)}}return!0},c.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},c.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},c.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return s(this,a),this;var o=this._events[a];if(o.fn)o.fn===t&&(!i||o.once)&&(!n||o.context===n)&&s(this,a);else{for(var c=0,l=[],u=o.length;c<u;c++)(o[c].fn!==t||i&&!o[c].once||n&&o[c].context!==n)&&l.push(o[c]);l.length?this._events[a]=l.length===1?l[0]:l:s(this,a)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&s(this,t)):(this._events=new i,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,t!==void 0&&(t.exports=c)}))(),1),d=class e extends Error{name=`TimeoutError`;constructor(t,n){super(t,n),Error.captureStackTrace?.(this,e)}};let f=e=>e.reason??new DOMException(`This operation was aborted.`,`AbortError`);function p(e,t){let{milliseconds:n,fallback:r,message:i,customTimers:a={setTimeout,clearTimeout},signal:o}=t,s,c,l=new Promise((t,l)=>{if(typeof n!=`number`||Math.sign(n)!==1)throw TypeError(`Expected \`milliseconds\` to be a positive number, got \`${n}\``);if(o?.aborted){l(f(o));return}if(o&&(c=()=>{l(f(o))},o.addEventListener(`abort`,c,{once:!0})),e.then(t,l),n===1/0)return;let u=new d;s=a.setTimeout.call(void 0,()=>{if(r){try{t(r())}catch(e){l(e)}return}typeof e.cancel==`function`&&e.cancel(),i===!1?t():i instanceof Error?l(i):(u.message=i??`Promise timed out after ${n} milliseconds`,l(u))},n)}).finally(()=>{l.clear(),c&&o&&o.removeEventListener(`abort`,c)});return l.clear=()=>{a.clearTimeout.call(void 0,s),s=void 0},l}function m(e,t,n){let r=0,i=e.length;for(;i>0;){let a=Math.trunc(i/2),o=r+a;n(e[o],t)<=0?(r=++o,i-=a+1):i=a}return r}var h=class{#e=[];enqueue(e,t){let{priority:n=0,id:r}=t??{},i={priority:n,id:r,run:e};if(this.size===0||this.#e[this.size-1].priority>=n){this.#e.push(i);return}let a=m(this.#e,i,(e,t)=>t.priority-e.priority);this.#e.splice(a,0,i)}setPriority(e,t){let n=this.#e.findIndex(t=>t.id===e);if(n===-1)throw ReferenceError(`No promise function with the id "${e}" exists in the queue.`);let[r]=this.#e.splice(n,1);this.enqueue(r.run,{priority:t,id:e})}remove(e){let t=this.#e.findIndex(t=>typeof e==`string`?t.id===e:t.run===e);t!==-1&&this.#e.splice(t,1)}dequeue(){return this.#e.shift()?.run}filter(e){return this.#e.filter(t=>t.priority===e.priority).map(e=>e.run)}get size(){return this.#e.length}},g=class extends u.default{#e;#t;#n=0;#r;#i=!1;#a=!1;#o;#s=0;#c=0;#l;#u;#d;#f=[];#p=0;#m;#h;#g=0;#_;#v;#y=1n;#b=new Map;#x=new Set;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:h,strict:!1,...e},!(typeof e.intervalCap==`number`&&e.intervalCap>=1))throw TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??``}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??``}\` (${typeof e.interval})`);if(e.strict&&e.interval===0)throw TypeError("The `strict` option requires a non-zero `interval`");if(e.strict&&e.intervalCap===1/0)throw TypeError("The `strict` option requires a finite `intervalCap`");if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#t=e.intervalCap===1/0||e.interval===0,this.#r=e.intervalCap,this.#o=e.interval,this.#d=e.strict,this.#m=new e.queueClass,this.#h=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#v=e.autoStart===!1,this.#z()}#S(e){for(;this.#p<this.#f.length;){let t=this.#f[this.#p];if(t!==void 0&&e-t>=this.#o)this.#p++;else break}(this.#p>100&&this.#p>this.#f.length/2||this.#p===this.#f.length)&&(this.#f=this.#f.slice(this.#p),this.#p=0)}#C(e){this.#d?this.#f.push(e):this.#n++}#w(){this.#d?this.#f.length>this.#p&&this.#f.pop():this.#n>0&&this.#n--}#T(){return this.#f.length-this.#p}get#E(){return this.#t?!0:this.#d?this.#T()<this.#r:this.#n<this.#r}get#D(){return this.#g<this.#_}#O(){this.#g--,this.#g===0&&this.emit(`pendingZero`),this.#P(),this.emit(`next`)}#k(){this.#u=void 0,this.#I(),this.#F()}#A(e){if(this.#d){if(this.#S(e),this.#T()>=this.#r){let t=this.#f[this.#p],n=this.#o-(e-t);return this.#j(n),!0}return!1}if(this.#l===void 0){let t=this.#s-e;if(t<0){if(this.#c>0){let t=e-this.#c;if(t<this.#o)return this.#j(this.#o-t),!0}this.#n=this.#e?this.#g:0}else return this.#j(t),!0}return!1}#j(e){this.#u===void 0&&(this.#u=setTimeout(()=>{this.#k()},e))}#M(){this.#l&&=(clearInterval(this.#l),void 0)}#N(){this.#u&&=(clearTimeout(this.#u),void 0)}#P(){if(this.#m.size===0){if(this.#M(),this.emit(`empty`),this.#g===0){if(this.#N(),this.#d&&this.#p>0){let e=Date.now();this.#S(e)}this.emit(`idle`)}return!1}let e=!1;if(!this.#v){let t=Date.now(),n=!this.#A(t);if(this.#E&&this.#D){let r=this.#m.dequeue();this.#t||(this.#C(t),this.#B()),this.emit(`active`),r(),n&&this.#F(),e=!0}}return e}#F(){this.#t||this.#l!==void 0||this.#d||(this.#l=setInterval(()=>{this.#I()},this.#o),this.#s=Date.now()+this.#o)}#I(){this.#d||(this.#n===0&&this.#g===0&&this.#l&&this.#M(),this.#n=this.#e?this.#g:0),this.#L(),this.#B()}#L(){for(;this.#P(););}get concurrency(){return this.#_}set concurrency(e){if(!(typeof e==`number`&&e>=1))throw TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#_=e,this.#L()}setPriority(e,t){if(typeof t!=`number`||!Number.isFinite(t))throw TypeError(`Expected \`priority\` to be a finite number, got \`${t}\` (${typeof t})`);this.#m.setPriority(e,t)}async add(e,t={}){return t={timeout:this.timeout,...t,id:t.id??(this.#y++).toString()},new Promise((n,r)=>{let i=Symbol(`task-${t.id}`),a=()=>void 0,o=async()=>{a(),this.#g++,this.#b.set(i,{id:t.id,priority:t.priority??0,startTime:Date.now(),timeout:t.timeout});let o;try{try{t.signal?.throwIfAborted()}catch(e){throw this.#V(),this.#b.delete(i),e}this.#c=Date.now();let r=e({signal:t.signal});if(t.timeout&&(r=p(Promise.resolve(r),{milliseconds:t.timeout,message:`Task timed out after ${t.timeout}ms (queue has ${this.#g} running, ${this.#m.size} waiting)`})),t.signal){let{signal:e}=t;r=Promise.race([r,new Promise((t,n)=>{o=()=>{n(e.reason)},e.addEventListener(`abort`,o,{once:!0})})])}let a=await r;n(a),this.emit(`completed`,a)}catch(e){r(e),this.emit(`error`,e)}finally{o&&t.signal?.removeEventListener(`abort`,o),this.#b.delete(i),queueMicrotask(()=>{this.#O()})}};this.#m.enqueue(o,t);let s=()=>{if(this.#m instanceof h){this.#m.remove(o);return}this.#m.remove?.(t.id)};if(t.signal){let{signal:e}=t,n=()=>{a(),s(),r(e.reason),this.#P(),this.emit(`next`)};if(a=()=>{e.removeEventListener(`abort`,n),this.#x.delete(a)},e.aborted){n();return}e.addEventListener(`abort`,n,{once:!0}),this.#x.add(a)}this.emit(`add`),this.#P()})}async addAll(e,t){return Promise.all(e.map(async e=>this.add(e,t)))}start(){return this.#v?(this.#v=!1,this.#L(),this):this}pause(){this.#v=!0}clear(){for(let e of this.#x)e();this.#m=new this.#h,this.#M(),this.#H(),this.emit(`empty`),this.#g===0&&(this.#N(),this.emit(`idle`)),this.emit(`next`)}async onEmpty(){this.#m.size!==0&&await this.#R(`empty`)}async onSizeLessThan(e){this.#m.size<e||await this.#R(`next`,()=>this.#m.size<e)}async onIdle(){this.#g===0&&this.#m.size===0||await this.#R(`idle`)}async onPendingZero(){this.#g!==0&&await this.#R(`pendingZero`)}async onRateLimit(){this.isRateLimited||await this.#R(`rateLimit`)}async onRateLimitCleared(){this.isRateLimited&&await this.#R(`rateLimitCleared`)}onError(){return new Promise((e,t)=>{let n=e=>{this.off(`error`,n),t(e)};this.on(`error`,n)})}async#R(e,t){return new Promise(n=>{let r=()=>{t&&!t()||(this.off(e,r),n())};this.on(e,r)})}get size(){return this.#m.size}sizeBy(e){return this.#m.filter(e).length}get pending(){return this.#g}get isPaused(){return this.#v}#z(){this.#t||(this.on(`add`,()=>{this.#m.size>0&&this.#B()}),this.on(`next`,()=>{this.#B()}))}#B(){this.#t||this.#a||(this.#a=!0,queueMicrotask(()=>{this.#a=!1,this.#H()}))}#V(){this.#t||(this.#w(),this.#B())}#H(){let e=this.#i;if(this.#t||this.#m.size===0){e&&(this.#i=!1,this.emit(`rateLimitCleared`));return}let t;if(this.#d){let e=Date.now();this.#S(e),t=this.#T()}else t=this.#n;let n=t>=this.#r;n!==e&&(this.#i=n,this.emit(n?`rateLimit`:`rateLimitCleared`))}get isRateLimited(){return this.#i}get isSaturated(){return this.#g===this.#_&&this.#m.size>0||this.isRateLimited&&this.#m.size>0}get runningTasks(){return[...this.#b.values()].map(e=>({...e}))}},_=o(((e,t)=>{function n(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}function r(e,t){for(var n=``,r=0,i=-1,a=0,o,s=0;s<=e.length;++s){if(s<e.length)o=e.charCodeAt(s);else if(o===47)break;else o=47;if(o===47){if(!(i===s-1||a===1))if(i!==s-1&&a===2){if(n.length<2||r!==2||n.charCodeAt(n.length-1)!==46||n.charCodeAt(n.length-2)!==46){if(n.length>2){var c=n.lastIndexOf(`/`);if(c!==n.length-1){c===-1?(n=``,r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf(`/`)),i=s,a=0;continue}}else if(n.length===2||n.length===1){n=``,r=0,i=s,a=0;continue}}t&&(n.length>0?n+=`/..`:n=`..`,r=2)}else n.length>0?n+=`/`+e.slice(i+1,s):n=e.slice(i+1,s),r=s-i-1;i=s,a=0}else o===46&&a!==-1?++a:a=-1}return n}function i(e,t){var n=t.dir||t.root,r=t.base||(t.name||``)+(t.ext||``);return n?n===t.root?n+r:n+e+r:r}var a={resolve:function(){for(var e=``,t=!1,i,a=arguments.length-1;a>=-1&&!t;a--){var o;a>=0?o=arguments[a]:(i===void 0&&(i=process.cwd()),o=i),n(o),o.length!==0&&(e=o+`/`+e,t=o.charCodeAt(0)===47)}return e=r(e,!t),t?e.length>0?`/`+e:`/`:e.length>0?e:`.`},normalize:function(e){if(n(e),e.length===0)return`.`;var t=e.charCodeAt(0)===47,i=e.charCodeAt(e.length-1)===47;return e=r(e,!t),e.length===0&&!t&&(e=`.`),e.length>0&&i&&(e+=`/`),t?`/`+e:e},isAbsolute:function(e){return n(e),e.length>0&&e.charCodeAt(0)===47},join:function(){if(arguments.length===0)return`.`;for(var e,t=0;t<arguments.length;++t){var r=arguments[t];n(r),r.length>0&&(e===void 0?e=r:e+=`/`+r)}return e===void 0?`.`:a.normalize(e)},relative:function(e,t){if(n(e),n(t),e===t||(e=a.resolve(e),t=a.resolve(t),e===t))return``;for(var r=1;r<e.length&&e.charCodeAt(r)===47;++r);for(var i=e.length,o=i-r,s=1;s<t.length&&t.charCodeAt(s)===47;++s);for(var c=t.length-s,l=o<c?o:c,u=-1,d=0;d<=l;++d){if(d===l){if(c>l){if(t.charCodeAt(s+d)===47)return t.slice(s+d+1);if(d===0)return t.slice(s+d)}else o>l&&(e.charCodeAt(r+d)===47?u=d:d===0&&(u=0));break}var f=e.charCodeAt(r+d);if(f!==t.charCodeAt(s+d))break;f===47&&(u=d)}var p=``;for(d=r+u+1;d<=i;++d)(d===i||e.charCodeAt(d)===47)&&(p.length===0?p+=`..`:p+=`/..`);return p.length>0?p+t.slice(s+u):(s+=u,t.charCodeAt(s)===47&&++s,t.slice(s))},_makeLong:function(e){return e},dirname:function(e){if(n(e),e.length===0)return`.`;for(var t=e.charCodeAt(0),r=t===47,i=-1,a=!0,o=e.length-1;o>=1;--o)if(t=e.charCodeAt(o),t===47){if(!a){i=o;break}}else a=!1;return i===-1?r?`/`:`.`:r&&i===1?`//`:e.slice(0,i)},basename:function(e,t){if(t!==void 0&&typeof t!=`string`)throw TypeError(`"ext" argument must be a string`);n(e);var r=0,i=-1,a=!0,o;if(t!==void 0&&t.length>0&&t.length<=e.length){if(t.length===e.length&&t===e)return``;var s=t.length-1,c=-1;for(o=e.length-1;o>=0;--o){var l=e.charCodeAt(o);if(l===47){if(!a){r=o+1;break}}else c===-1&&(a=!1,c=o+1),s>=0&&(l===t.charCodeAt(s)?--s===-1&&(i=o):(s=-1,i=c))}return r===i?i=c:i===-1&&(i=e.length),e.slice(r,i)}else{for(o=e.length-1;o>=0;--o)if(e.charCodeAt(o)===47){if(!a){r=o+1;break}}else i===-1&&(a=!1,i=o+1);return i===-1?``:e.slice(r,i)}},extname:function(e){n(e);for(var t=-1,r=0,i=-1,a=!0,o=0,s=e.length-1;s>=0;--s){var c=e.charCodeAt(s);if(c===47){if(!a){r=s+1;break}continue}i===-1&&(a=!1,i=s+1),c===46?t===-1?t=s:o!==1&&(o=1):t!==-1&&(o=-1)}return t===-1||i===-1||o===0||o===1&&t===i-1&&t===r+1?``:e.slice(t,i)},format:function(e){if(typeof e!=`object`||!e)throw TypeError(`The "pathObject" argument must be of type Object. Received type `+typeof e);return i(`/`,e)},parse:function(e){n(e);var t={root:``,dir:``,base:``,ext:``,name:``};if(e.length===0)return t;var r=e.charCodeAt(0),i=r===47,a;i?(t.root=`/`,a=1):a=0;for(var o=-1,s=0,c=-1,l=!0,u=e.length-1,d=0;u>=a;--u){if(r=e.charCodeAt(u),r===47){if(!l){s=u+1;break}continue}c===-1&&(l=!1,c=u+1),r===46?o===-1?o=u:d!==1&&(d=1):o!==-1&&(d=-1)}return o===-1||c===-1||d===0||d===1&&o===c-1&&o===s+1?c!==-1&&(s===0&&i?t.base=t.name=e.slice(1,c):t.base=t.name=e.slice(s,c)):(s===0&&i?(t.name=e.slice(1,o),t.base=e.slice(1,c)):(t.name=e.slice(s,o),t.base=e.slice(s,c)),t.ext=e.slice(o,c)),s>0?t.dir=e.slice(0,s-1):i&&(t.dir=`/`),t},sep:`/`,delimiter:`:`,win32:null,posix:null};a.posix=a,t.exports=a}));function v(e,t){return function(){return e.apply(t,arguments)}}let{toString:y}=Object.prototype,{getPrototypeOf:b}=Object,{iterator:x,toStringTag:S}=Symbol,C=(e=>t=>{let n=y.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),w=e=>(e=e.toLowerCase(),t=>C(t)===e),ee=e=>t=>typeof t===e,{isArray:te}=Array,ne=ee(`undefined`);function re(e){return e!==null&&!ne(e)&&e.constructor!==null&&!ne(e.constructor)&&T(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}let ie=w(`ArrayBuffer`);function ae(e){let t;return t=typeof ArrayBuffer<`u`&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&ie(e.buffer),t}let oe=ee(`string`),T=ee(`function`),se=ee(`number`),ce=e=>typeof e==`object`&&!!e,le=e=>e===!0||e===!1,ue=e=>{if(C(e)!==`object`)return!1;let t=b(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(S in e)&&!(x in e)},de=e=>{if(!ce(e)||re(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},fe=w(`Date`),pe=w(`File`),me=e=>!!(e&&e.uri!==void 0),he=e=>e&&e.getParts!==void 0,ge=w(`Blob`),_e=w(`FileList`),ve=e=>ce(e)&&T(e.pipe);function ye(){return typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{}}let be=ye(),xe=be.FormData===void 0?void 0:be.FormData,Se=e=>{if(!e)return!1;if(xe&&e instanceof xe)return!0;let t=b(e);if(!t||t===Object.prototype||!T(e.append))return!1;let n=C(e);return n===`formdata`||n===`object`&&T(e.toString)&&e.toString()===`[object FormData]`},Ce=w(`URLSearchParams`),[we,Te,Ee,De]=[`ReadableStream`,`Request`,`Response`,`Headers`].map(w),Oe=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``);function ke(e,t,{allOwnKeys:n=!1}={}){if(e==null)return;let r,i;if(typeof e!=`object`&&(e=[e]),te(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{if(re(e))return;let i=n?Object.getOwnPropertyNames(e):Object.keys(e),a=i.length,o;for(r=0;r<a;r++)o=i[r],t.call(null,e[o],o,e)}}function Ae(e,t){if(re(e))return null;t=t.toLowerCase();let n=Object.keys(e),r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}let je=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:global,Me=e=>!ne(e)&&e!==je;function Ne(){let{caseless:e,skipUndefined:t}=Me(this)&&this||{},n={},r=(r,i)=>{if(i===`__proto__`||i===`constructor`||i===`prototype`)return;let a=e&&Ae(n,i)||i;ue(n[a])&&ue(r)?n[a]=Ne(n[a],r):ue(r)?n[a]=Ne({},r):te(r)?n[a]=r.slice():(!t||!ne(r))&&(n[a]=r)};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&ke(arguments[e],r);return n}let Pe=(e,t,n,{allOwnKeys:r}={})=>(ke(t,(t,r)=>{n&&T(t)?Object.defineProperty(e,r,{value:v(t,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,r,{value:t,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),Fe=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Ie=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,`constructor`,{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,`super`,{value:t.prototype}),n&&Object.assign(e.prototype,n)},Le=(e,t,n,r)=>{let i,a,o,s={};if(t||={},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),a=i.length;a-- >0;)o=i[a],(!r||r(o,e,t))&&!s[o]&&(t[o]=e[o],s[o]=!0);e=n!==!1&&b(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},Re=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;let r=e.indexOf(t,n);return r!==-1&&r===n},ze=e=>{if(!e)return null;if(te(e))return e;let t=e.length;if(!se(t))return null;let n=Array(t);for(;t-- >0;)n[t]=e[t];return n},Be=(e=>t=>e&&t instanceof e)(typeof Uint8Array<`u`&&b(Uint8Array)),Ve=(e,t)=>{let n=(e&&e[x]).call(e),r;for(;(r=n.next())&&!r.done;){let n=r.value;t.call(e,n[0],n[1])}},He=(e,t)=>{let n,r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},Ue=w(`HTMLFormElement`),We=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,n){return t.toUpperCase()+n}),Ge=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Ke=w(`RegExp`),qe=(e,t)=>{let n=Object.getOwnPropertyDescriptors(e),r={};ke(n,(n,i)=>{let a;(a=t(n,i,e))!==!1&&(r[i]=a||n)}),Object.defineProperties(e,r)},Je=e=>{qe(e,(t,n)=>{if(T(e)&&[`arguments`,`caller`,`callee`].indexOf(n)!==-1)return!1;let r=e[n];if(T(r)){if(t.enumerable=!1,`writable`in t){t.writable=!1;return}t.set||=()=>{throw Error(`Can not rewrite read-only method '`+n+`'`)}}})},Ye=(e,t)=>{let n={},r=e=>{e.forEach(e=>{n[e]=!0})};return te(e)?r(e):r(String(e).split(t)),n},Xe=()=>{},Ze=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function Qe(e){return!!(e&&T(e.append)&&e[S]===`FormData`&&e[x])}let $e=e=>{let t=Array(10),n=(e,r)=>{if(ce(e)){if(t.indexOf(e)>=0)return;if(re(e))return e;if(!(`toJSON`in e)){t[r]=e;let i=te(e)?[]:{};return ke(e,(e,t)=>{let a=n(e,r+1);!ne(a)&&(i[t]=a)}),t[r]=void 0,i}}return e};return n(e,0)},et=w(`AsyncFunction`),tt=e=>e&&(ce(e)||T(e))&&T(e.then)&&T(e.catch),nt=((e,t)=>e?setImmediate:t?((e,t)=>(je.addEventListener(`message`,({source:n,data:r})=>{n===je&&r===e&&t.length&&t.shift()()},!1),n=>{t.push(n),je.postMessage(e,`*`)}))(`axios@${Math.random()}`,[]):e=>setTimeout(e))(typeof setImmediate==`function`,T(je.postMessage));var E={isArray:te,isArrayBuffer:ie,isBuffer:re,isFormData:Se,isArrayBufferView:ae,isString:oe,isNumber:se,isBoolean:le,isObject:ce,isPlainObject:ue,isEmptyObject:de,isReadableStream:we,isRequest:Te,isResponse:Ee,isHeaders:De,isUndefined:ne,isDate:fe,isFile:pe,isReactNativeBlob:me,isReactNative:he,isBlob:ge,isRegExp:Ke,isFunction:T,isStream:ve,isURLSearchParams:Ce,isTypedArray:Be,isFileList:_e,forEach:ke,merge:Ne,extend:Pe,trim:Oe,stripBOM:Fe,inherits:Ie,toFlatObject:Le,kindOf:C,kindOfTest:w,endsWith:Re,toArray:ze,forEachEntry:Ve,matchAll:He,isHTMLForm:Ue,hasOwnProperty:Ge,hasOwnProp:Ge,reduceDescriptors:qe,freezeMethods:Je,toObjectSet:Ye,toCamelCase:We,noop:Xe,toFiniteNumber:Ze,findKey:Ae,global:je,isContextDefined:Me,isSpecCompliantForm:Qe,toJSONObject:$e,isAsyncFn:et,isThenable:tt,setImmediate:nt,asap:typeof queueMicrotask<`u`?queueMicrotask.bind(je):typeof process<`u`&&process.nextTick||nt,isIterable:e=>e!=null&&T(e[x])},D=class e extends Error{static from(t,n,r,i,a,o){let s=new e(t.message,n||t.code,r,i,a);return s.cause=t,s.name=t.name,t.status!=null&&s.status==null&&(s.status=t.status),o&&Object.assign(s,o),s}constructor(e,t,n,r,i){super(e),Object.defineProperty(this,`message`,{value:e,enumerable:!0,writable:!0,configurable:!0}),this.name=`AxiosError`,this.isAxiosError=!0,t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i,this.status=i.status)}toJSON(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:E.toJSONObject(this.config),code:this.code,status:this.status}}};D.ERR_BAD_OPTION_VALUE=`ERR_BAD_OPTION_VALUE`,D.ERR_BAD_OPTION=`ERR_BAD_OPTION`,D.ECONNABORTED=`ECONNABORTED`,D.ETIMEDOUT=`ETIMEDOUT`,D.ERR_NETWORK=`ERR_NETWORK`,D.ERR_FR_TOO_MANY_REDIRECTS=`ERR_FR_TOO_MANY_REDIRECTS`,D.ERR_DEPRECATED=`ERR_DEPRECATED`,D.ERR_BAD_RESPONSE=`ERR_BAD_RESPONSE`,D.ERR_BAD_REQUEST=`ERR_BAD_REQUEST`,D.ERR_CANCELED=`ERR_CANCELED`,D.ERR_NOT_SUPPORT=`ERR_NOT_SUPPORT`,D.ERR_INVALID_URL=`ERR_INVALID_URL`,D.ERR_FORM_DATA_DEPTH_EXCEEDED=`ERR_FORM_DATA_DEPTH_EXCEEDED`;function rt(e){return E.isPlainObject(e)||E.isArray(e)}function it(e){return E.endsWith(e,`[]`)?e.slice(0,-2):e}function at(e,t,n){return e?e.concat(t).map(function(e,t){return e=it(e),!n&&t?`[`+e+`]`:e}).join(n?`.`:``):t}function ot(e){return E.isArray(e)&&!e.some(rt)}let st=E.toFlatObject(E,{},null,function(e){return/^is[A-Z]/.test(e)});function ct(e,t,n){if(!E.isObject(e))throw TypeError(`target must be an object`);t||=new FormData,n=E.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!E.isUndefined(t[e])});let r=n.metaTokens,i=n.visitor||d,a=n.dots,o=n.indexes,s=n.Blob||typeof Blob<`u`&&Blob,c=n.maxDepth===void 0?100:n.maxDepth,l=s&&E.isSpecCompliantForm(t);if(!E.isFunction(i))throw TypeError(`visitor must be a function`);function u(e){if(e===null)return``;if(E.isDate(e))return e.toISOString();if(E.isBoolean(e))return e.toString();if(!l&&E.isBlob(e))throw new D(`Blob is not supported. Use a Buffer instead.`);return E.isArrayBuffer(e)||E.isTypedArray(e)?l&&typeof Blob==`function`?new Blob([e]):Buffer.from(e):e}function d(e,n,i){let s=e;if(E.isReactNative(t)&&E.isReactNativeBlob(e))return t.append(at(i,n,a),u(e)),!1;if(e&&!i&&typeof e==`object`){if(E.endsWith(n,`{}`))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(E.isArray(e)&&ot(e)||(E.isFileList(e)||E.endsWith(n,`[]`))&&(s=E.toArray(e)))return n=it(n),s.forEach(function(e,r){!(E.isUndefined(e)||e===null)&&t.append(o===!0?at([n],r,a):o===null?n:n+`[]`,u(e))}),!1}return rt(e)?!0:(t.append(at(i,n,a),u(e)),!1)}let f=[],p=Object.assign(st,{defaultVisitor:d,convertValue:u,isVisitable:rt});function m(e,n,r=0){if(!E.isUndefined(e)){if(r>c)throw new D(`Object is too deeply nested (`+r+` levels). Max depth: `+c,D.ERR_FORM_DATA_DEPTH_EXCEEDED);if(f.indexOf(e)!==-1)throw Error(`Circular reference detected in `+n.join(`.`));f.push(e),E.forEach(e,function(e,a){(!(E.isUndefined(e)||e===null)&&i.call(t,e,E.isString(a)?a.trim():a,n,p))===!0&&m(e,n?n.concat(a):[a],r+1)}),f.pop()}}if(!E.isObject(e))throw TypeError(`data must be an object`);return m(e),t}function lt(e){let t={"!":`%21`,"'":`%27`,"(":`%28`,")":`%29`,"~":`%7E`,"%20":`+`};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(e){return t[e]})}function ut(e,t){this._pairs=[],e&&ct(e,this,t)}let dt=ut.prototype;dt.append=function(e,t){this._pairs.push([e,t])},dt.toString=function(e){let t=e?function(t){return e.call(this,t,lt)}:lt;return this._pairs.map(function(e){return t(e[0])+`=`+t(e[1])},``).join(`&`)};function ft(e){return encodeURIComponent(e).replace(/%3A/gi,`:`).replace(/%24/g,`$`).replace(/%2C/gi,`,`).replace(/%20/g,`+`)}function pt(e,t,n){if(!t)return e;let r=n&&n.encode||ft,i=E.isFunction(n)?{serialize:n}:n,a=i&&i.serialize,o;if(o=a?a(t,i):E.isURLSearchParams(t)?t.toString():new ut(t,i).toString(r),o){let t=e.indexOf(`#`);t!==-1&&(e=e.slice(0,t)),e+=(e.indexOf(`?`)===-1?`?`:`&`)+o}return e}var mt=class{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&=[]}forEach(e){E.forEach(this.handlers,function(t){t!==null&&e(t)})}},ht={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},gt={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<`u`?URLSearchParams:ut,FormData:typeof FormData<`u`?FormData:null,Blob:typeof Blob<`u`?Blob:null},protocols:[`http`,`https`,`file`,`blob`,`url`,`data`]},_t=s({hasBrowserEnv:()=>vt,hasStandardBrowserEnv:()=>bt,hasStandardBrowserWebWorkerEnv:()=>xt,navigator:()=>yt,origin:()=>St});let vt=typeof window<`u`&&typeof document<`u`,yt=typeof navigator==`object`&&navigator||void 0,bt=vt&&(!yt||[`ReactNative`,`NativeScript`,`NS`].indexOf(yt.product)<0),xt=typeof WorkerGlobalScope<`u`&&self instanceof WorkerGlobalScope&&typeof self.importScripts==`function`,St=vt&&window.location.href||`http://localhost`;var O={..._t,...gt};function Ct(e,t){return ct(e,new O.classes.URLSearchParams,{visitor:function(e,t,n,r){return O.isNode&&E.isBuffer(e)?(this.append(t,e.toString(`base64`)),!1):r.defaultVisitor.apply(this,arguments)},...t})}function wt(e){return E.matchAll(/\w+|\[(\w*)]/g,e).map(e=>e[0]===`[]`?``:e[1]||e[0])}function Tt(e){let t={},n=Object.keys(e),r,i=n.length,a;for(r=0;r<i;r++)a=n[r],t[a]=e[a];return t}function Et(e){function t(e,n,r,i){let a=e[i++];if(a===`__proto__`)return!0;let o=Number.isFinite(+a),s=i>=e.length;return a=!a&&E.isArray(r)?r.length:a,s?(E.hasOwnProp(r,a)?r[a]=E.isArray(r[a])?r[a].concat(n):[r[a],n]:r[a]=n,!o):((!r[a]||!E.isObject(r[a]))&&(r[a]=[]),t(e,n,r[a],i)&&E.isArray(r[a])&&(r[a]=Tt(r[a])),!o)}if(E.isFormData(e)&&E.isFunction(e.entries)){let n={};return E.forEachEntry(e,(e,r)=>{t(wt(e),r,n,0)}),n}return null}let Dt=(e,t)=>e!=null&&E.hasOwnProp(e,t)?e[t]:void 0;function Ot(e,t,n){if(E.isString(e))try{return(t||JSON.parse)(e),E.trim(e)}catch(e){if(e.name!==`SyntaxError`)throw e}return(n||JSON.stringify)(e)}let kt={transitional:ht,adapter:[`xhr`,`http`,`fetch`],transformRequest:[function(e,t){let n=t.getContentType()||``,r=n.indexOf(`application/json`)>-1,i=E.isObject(e);if(i&&E.isHTMLForm(e)&&(e=new FormData(e)),E.isFormData(e))return r?JSON.stringify(Et(e)):e;if(E.isArrayBuffer(e)||E.isBuffer(e)||E.isStream(e)||E.isFile(e)||E.isBlob(e)||E.isReadableStream(e))return e;if(E.isArrayBufferView(e))return e.buffer;if(E.isURLSearchParams(e))return t.setContentType(`application/x-www-form-urlencoded;charset=utf-8`,!1),e.toString();let a;if(i){let t=Dt(this,`formSerializer`);if(n.indexOf(`application/x-www-form-urlencoded`)>-1)return Ct(e,t).toString();if((a=E.isFileList(e))||n.indexOf(`multipart/form-data`)>-1){let n=Dt(this,`env`),r=n&&n.FormData;return ct(a?{"files[]":e}:e,r&&new r,t)}}return i||r?(t.setContentType(`application/json`,!1),Ot(e)):e}],transformResponse:[function(e){let t=Dt(this,`transitional`)||kt.transitional,n=t&&t.forcedJSONParsing,r=Dt(this,`responseType`),i=r===`json`;if(E.isResponse(e)||E.isReadableStream(e))return e;if(e&&E.isString(e)&&(n&&!r||i)){let n=!(t&&t.silentJSONParsing)&&i;try{return JSON.parse(e,Dt(this,`parseReviver`))}catch(e){if(n)throw e.name===`SyntaxError`?D.from(e,D.ERR_BAD_RESPONSE,this,null,Dt(this,`response`)):e}}return e}],timeout:0,xsrfCookieName:`XSRF-TOKEN`,xsrfHeaderName:`X-XSRF-TOKEN`,maxContentLength:-1,maxBodyLength:-1,env:{FormData:O.classes.FormData,Blob:O.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:`application/json, text/plain, */*`,"Content-Type":void 0}}};E.forEach([`delete`,`get`,`head`,`post`,`put`,`patch`],e=>{kt.headers[e]={}});let At=E.toObjectSet([`age`,`authorization`,`content-length`,`content-type`,`etag`,`expires`,`from`,`host`,`if-modified-since`,`if-unmodified-since`,`last-modified`,`location`,`max-forwards`,`proxy-authorization`,`referer`,`retry-after`,`user-agent`]);var jt=e=>{let t={},n,r,i;return e&&e.split(`
1
+ (function(){var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,a)=>(a=n==null?{}:e(i(n)),c(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),u=l(o(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=`~`;function i(){}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1));function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,n,i,o){if(typeof n!=`function`)throw TypeError(`The listener must be a function`);var s=new a(n,i||e,o),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],s]:e._events[c].push(s):(e._events[c]=s,e._eventsCount++),e}function s(e,t){--e._eventsCount===0?e._events=new i:delete e._events[t]}function c(){this._events=new i,this._eventsCount=0}c.prototype.eventNames=function(){var e=[],t,i;if(this._eventsCount===0)return e;for(i in t=this._events)n.call(t,i)&&e.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(t)):e},c.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,o=Array(a);i<a;i++)o[i]=n[i].fn;return o},c.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},c.prototype.emit=function(e,t,n,i,a,o){var s=r?r+e:e;if(!this._events[s])return!1;var c=this._events[s],l=arguments.length,u,d;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),l){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,a),!0;case 6:return c.fn.call(c.context,t,n,i,a,o),!0}for(d=1,u=Array(l-1);d<l;d++)u[d-1]=arguments[d];c.fn.apply(c.context,u)}else{var f=c.length,p;for(d=0;d<f;d++)switch(c[d].once&&this.removeListener(e,c[d].fn,void 0,!0),l){case 1:c[d].fn.call(c[d].context);break;case 2:c[d].fn.call(c[d].context,t);break;case 3:c[d].fn.call(c[d].context,t,n);break;case 4:c[d].fn.call(c[d].context,t,n,i);break;default:if(!u)for(p=1,u=Array(l-1);p<l;p++)u[p-1]=arguments[p];c[d].fn.apply(c[d].context,u)}}return!0},c.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},c.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},c.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return s(this,a),this;var o=this._events[a];if(o.fn)o.fn===t&&(!i||o.once)&&(!n||o.context===n)&&s(this,a);else{for(var c=0,l=[],u=o.length;c<u;c++)(o[c].fn!==t||i&&!o[c].once||n&&o[c].context!==n)&&l.push(o[c]);l.length?this._events[a]=l.length===1?l[0]:l:s(this,a)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&s(this,t)):(this._events=new i,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,t!==void 0&&(t.exports=c)}))(),1),d=class e extends Error{name=`TimeoutError`;constructor(t,n){super(t,n),Error.captureStackTrace?.(this,e)}};let f=e=>e.reason??new DOMException(`This operation was aborted.`,`AbortError`);function p(e,t){let{milliseconds:n,fallback:r,message:i,customTimers:a={setTimeout,clearTimeout},signal:o}=t,s,c,l=new Promise((t,l)=>{if(typeof n!=`number`||Math.sign(n)!==1)throw TypeError(`Expected \`milliseconds\` to be a positive number, got \`${n}\``);if(o?.aborted){l(f(o));return}if(o&&(c=()=>{l(f(o))},o.addEventListener(`abort`,c,{once:!0})),e.then(t,l),n===1/0)return;let u=new d;s=a.setTimeout.call(void 0,()=>{if(r){try{t(r())}catch(e){l(e)}return}typeof e.cancel==`function`&&e.cancel(),i===!1?t():i instanceof Error?l(i):(u.message=i??`Promise timed out after ${n} milliseconds`,l(u))},n)}).finally(()=>{l.clear(),c&&o&&o.removeEventListener(`abort`,c)});return l.clear=()=>{a.clearTimeout.call(void 0,s),s=void 0},l}function m(e,t,n){let r=0,i=e.length;for(;i>0;){let a=Math.trunc(i/2),o=r+a;n(e[o],t)<=0?(r=++o,i-=a+1):i=a}return r}var h=class{#e=[];#t=0;enqueue(e,t){let{priority:n=0,id:r}=t??{},{size:i}=this,a={priority:n,id:r,run:e};if(i===0){this.#e.length=0,this.#t=0,this.#e.push(a);return}if(this.#e.at(-1).priority>=n){this.#e.push(a);return}this.#n();let o=m(this.#e,a,(e,t)=>t.priority-e.priority);this.#e.splice(o,0,a)}setPriority(e,t){let n=this.#e.findIndex((t,n)=>n>=this.#t&&t.id===e);if(n===-1)throw ReferenceError(`No promise function with the id "${e}" exists in the queue.`);let[r]=this.#e.splice(n,1);this.enqueue(r.run,{priority:t,id:e})}remove(e){let t=this.#e.findIndex((t,n)=>n<this.#t?!1:typeof e==`string`?t.id===e:t.run===e);t!==-1&&this.#e.splice(t,1)}dequeue(){if(this.#t===this.#e.length)return;let e=this.#e[this.#t];return this.#t++,this.#t===this.#e.length?(this.#e.length=0,this.#t=0):this.#t>100&&this.#t>this.#e.length/2&&this.#n(),e?.run}filter(e){let t=[];for(let n=this.#t;n<this.#e.length;n++){let r=this.#e[n];r.priority===e.priority&&t.push(r.run)}return t}get size(){return this.#e.length-this.#t}#n(){this.#t!==0&&(this.#e.splice(0,this.#t),this.#t=0)}},g=class extends u.default{#e;#t;#n=0;#r;#i=!1;#a=!1;#o;#s=0;#c=0;#l;#u;#d;#f=[];#p=0;#m;#h;#g=0;#_;#v;#y=1n;#b=new Map;#x=new Set;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:h,strict:!1,...e},!(typeof e.intervalCap==`number`&&e.intervalCap>=1))throw TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??``}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??``}\` (${typeof e.interval})`);if(e.strict&&e.interval===0)throw TypeError("The `strict` option requires a non-zero `interval`");if(e.strict&&e.intervalCap===1/0)throw TypeError("The `strict` option requires a finite `intervalCap`");if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#t=e.intervalCap===1/0||e.interval===0,this.#r=e.intervalCap,this.#o=e.interval,this.#d=e.strict,this.#m=new e.queueClass,this.#h=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#v=e.autoStart===!1,this.#z()}#S(e){for(;this.#p<this.#f.length;){let t=this.#f[this.#p];if(t!==void 0&&e-t>=this.#o)this.#p++;else break}(this.#p>100&&this.#p>this.#f.length/2||this.#p===this.#f.length)&&(this.#f=this.#f.slice(this.#p),this.#p=0)}#C(e){this.#d?this.#f.push(e):this.#n++}#w(){this.#d?this.#f.length>this.#p&&this.#f.pop():this.#n>0&&this.#n--}#T(){return this.#f.length-this.#p}get#E(){return this.#t?!0:this.#d?this.#T()<this.#r:this.#n<this.#r}get#D(){return this.#g<this.#_}#O(){this.#g--,this.#g===0&&this.emit(`pendingZero`),this.#P(),this.emit(`next`)}#k(){this.#u=void 0,this.#I(),this.#F()}#A(e){if(this.#d){if(this.#S(e),this.#T()>=this.#r){let t=this.#f[this.#p],n=this.#o-(e-t);return this.#j(n),!0}return!1}if(this.#l===void 0){let t=this.#s-e;if(t<0){if(this.#c>0){let t=e-this.#c;if(t<this.#o)return this.#j(this.#o-t),!0}this.#n=this.#e?this.#g:0}else return this.#j(t),!0}return!1}#j(e){this.#u===void 0&&(this.#u=setTimeout(()=>{this.#k()},e))}#M(){this.#l&&=(clearInterval(this.#l),void 0)}#N(){this.#u&&=(clearTimeout(this.#u),void 0)}#P(){if(this.#m.size===0){if(this.#M(),this.emit(`empty`),this.#g===0){if(this.#N(),this.#d&&this.#p>0){let e=Date.now();this.#S(e)}this.emit(`idle`)}return!1}let e=!1;if(!this.#v){let t=Date.now(),n=!this.#A(t);if(this.#E&&this.#D){let r=this.#m.dequeue();this.#t||(this.#C(t),this.#B()),this.emit(`active`),r(),n&&this.#F(),e=!0}}return e}#F(){this.#t||this.#l!==void 0||this.#d||(this.#l=setInterval(()=>{this.#I()},this.#o),this.#s=Date.now()+this.#o)}#I(){this.#d||(this.#n===0&&this.#g===0&&this.#l&&this.#M(),this.#n=this.#e?this.#g:0),this.#L(),this.#B()}#L(){for(;this.#P(););}get concurrency(){return this.#_}set concurrency(e){if(!(typeof e==`number`&&e>=1))throw TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#_=e,this.#L()}setPriority(e,t){if(typeof t!=`number`||!Number.isFinite(t))throw TypeError(`Expected \`priority\` to be a finite number, got \`${t}\` (${typeof t})`);this.#m.setPriority(e,t)}async add(e,t={}){return t={timeout:this.timeout,...t,id:t.id??(this.#y++).toString()},new Promise((n,r)=>{let i=Symbol(`task-${t.id}`),a=()=>void 0,o=async()=>{a(),this.#g++,this.#b.set(i,{id:t.id,priority:t.priority??0,startTime:Date.now(),timeout:t.timeout});let o;try{try{t.signal?.throwIfAborted()}catch(e){throw this.#V(),this.#b.delete(i),e}this.#c=Date.now();let r=e({signal:t.signal});if(t.timeout&&(r=p(Promise.resolve(r),{milliseconds:t.timeout,message:`Task timed out after ${t.timeout}ms (queue has ${this.#g} running, ${this.#m.size} waiting)`})),t.signal){let{signal:e}=t;r=Promise.race([r,new Promise((t,n)=>{o=()=>{n(e.reason)},e.addEventListener(`abort`,o,{once:!0})})])}let a=await r;n(a),this.emit(`completed`,a)}catch(e){r(e),this.emit(`error`,e)}finally{o&&t.signal?.removeEventListener(`abort`,o),this.#b.delete(i),queueMicrotask(()=>{this.#O()})}};this.#m.enqueue(o,t);let s=()=>{if(this.#m instanceof h){this.#m.remove(o);return}this.#m.remove?.(t.id)};if(t.signal){let{signal:e}=t,n=()=>{a(),s(),r(e.reason),this.#P(),this.emit(`next`)};if(a=()=>{e.removeEventListener(`abort`,n),this.#x.delete(a)},e.aborted){n();return}e.addEventListener(`abort`,n,{once:!0}),this.#x.add(a)}this.emit(`add`),this.#P()})}async addAll(e,t){return Promise.all(e.map(async e=>this.add(e,t)))}start(){return this.#v?(this.#v=!1,this.#L(),this):this}pause(){this.#v=!0}clear(){for(let e of this.#x)e();this.#m=new this.#h,this.#M(),this.#H(),this.emit(`empty`),this.#g===0&&(this.#N(),this.emit(`idle`)),this.emit(`next`)}async onEmpty(){this.#m.size!==0&&await this.#R(`empty`)}async onSizeLessThan(e){this.#m.size<e||await this.#R(`next`,()=>this.#m.size<e)}async onIdle(){this.#g===0&&this.#m.size===0||await this.#R(`idle`)}async onPendingZero(){this.#g!==0&&await this.#R(`pendingZero`)}async onRateLimit(){this.isRateLimited||await this.#R(`rateLimit`)}async onRateLimitCleared(){this.isRateLimited&&await this.#R(`rateLimitCleared`)}onError(){return new Promise((e,t)=>{let n=e=>{this.off(`error`,n),t(e)};this.on(`error`,n)})}async#R(e,t){return new Promise(n=>{let r=()=>{t&&!t()||(this.off(e,r),n())};this.on(e,r)})}get size(){return this.#m.size}sizeBy(e){return this.#m.filter(e).length}get pending(){return this.#g}get isPaused(){return this.#v}#z(){this.#t||(this.on(`add`,()=>{this.#m.size>0&&this.#B()}),this.on(`next`,()=>{this.#B()}))}#B(){this.#t||this.#a||(this.#a=!0,queueMicrotask(()=>{this.#a=!1,this.#H()}))}#V(){this.#t||(this.#w(),this.#B())}#H(){let e=this.#i;if(this.#t||this.#m.size===0){e&&(this.#i=!1,this.emit(`rateLimitCleared`));return}let t;if(this.#d){let e=Date.now();this.#S(e),t=this.#T()}else t=this.#n;let n=t>=this.#r;n!==e&&(this.#i=n,this.emit(n?`rateLimit`:`rateLimitCleared`))}get isRateLimited(){return this.#i}get isSaturated(){return this.#g===this.#_&&this.#m.size>0||this.isRateLimited&&this.#m.size>0}get runningTasks(){return[...this.#b.values()].map(e=>({...e}))}},_=o(((e,t)=>{function n(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}function r(e,t){for(var n=``,r=0,i=-1,a=0,o,s=0;s<=e.length;++s){if(s<e.length)o=e.charCodeAt(s);else if(o===47)break;else o=47;if(o===47){if(!(i===s-1||a===1))if(i!==s-1&&a===2){if(n.length<2||r!==2||n.charCodeAt(n.length-1)!==46||n.charCodeAt(n.length-2)!==46){if(n.length>2){var c=n.lastIndexOf(`/`);if(c!==n.length-1){c===-1?(n=``,r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf(`/`)),i=s,a=0;continue}}else if(n.length===2||n.length===1){n=``,r=0,i=s,a=0;continue}}t&&(n.length>0?n+=`/..`:n=`..`,r=2)}else n.length>0?n+=`/`+e.slice(i+1,s):n=e.slice(i+1,s),r=s-i-1;i=s,a=0}else o===46&&a!==-1?++a:a=-1}return n}function i(e,t){var n=t.dir||t.root,r=t.base||(t.name||``)+(t.ext||``);return n?n===t.root?n+r:n+e+r:r}var a={resolve:function(){for(var e=``,t=!1,i,a=arguments.length-1;a>=-1&&!t;a--){var o;a>=0?o=arguments[a]:(i===void 0&&(i=process.cwd()),o=i),n(o),o.length!==0&&(e=o+`/`+e,t=o.charCodeAt(0)===47)}return e=r(e,!t),t?e.length>0?`/`+e:`/`:e.length>0?e:`.`},normalize:function(e){if(n(e),e.length===0)return`.`;var t=e.charCodeAt(0)===47,i=e.charCodeAt(e.length-1)===47;return e=r(e,!t),e.length===0&&!t&&(e=`.`),e.length>0&&i&&(e+=`/`),t?`/`+e:e},isAbsolute:function(e){return n(e),e.length>0&&e.charCodeAt(0)===47},join:function(){if(arguments.length===0)return`.`;for(var e,t=0;t<arguments.length;++t){var r=arguments[t];n(r),r.length>0&&(e===void 0?e=r:e+=`/`+r)}return e===void 0?`.`:a.normalize(e)},relative:function(e,t){if(n(e),n(t),e===t||(e=a.resolve(e),t=a.resolve(t),e===t))return``;for(var r=1;r<e.length&&e.charCodeAt(r)===47;++r);for(var i=e.length,o=i-r,s=1;s<t.length&&t.charCodeAt(s)===47;++s);for(var c=t.length-s,l=o<c?o:c,u=-1,d=0;d<=l;++d){if(d===l){if(c>l){if(t.charCodeAt(s+d)===47)return t.slice(s+d+1);if(d===0)return t.slice(s+d)}else o>l&&(e.charCodeAt(r+d)===47?u=d:d===0&&(u=0));break}var f=e.charCodeAt(r+d);if(f!==t.charCodeAt(s+d))break;f===47&&(u=d)}var p=``;for(d=r+u+1;d<=i;++d)(d===i||e.charCodeAt(d)===47)&&(p.length===0?p+=`..`:p+=`/..`);return p.length>0?p+t.slice(s+u):(s+=u,t.charCodeAt(s)===47&&++s,t.slice(s))},_makeLong:function(e){return e},dirname:function(e){if(n(e),e.length===0)return`.`;for(var t=e.charCodeAt(0),r=t===47,i=-1,a=!0,o=e.length-1;o>=1;--o)if(t=e.charCodeAt(o),t===47){if(!a){i=o;break}}else a=!1;return i===-1?r?`/`:`.`:r&&i===1?`//`:e.slice(0,i)},basename:function(e,t){if(t!==void 0&&typeof t!=`string`)throw TypeError(`"ext" argument must be a string`);n(e);var r=0,i=-1,a=!0,o;if(t!==void 0&&t.length>0&&t.length<=e.length){if(t.length===e.length&&t===e)return``;var s=t.length-1,c=-1;for(o=e.length-1;o>=0;--o){var l=e.charCodeAt(o);if(l===47){if(!a){r=o+1;break}}else c===-1&&(a=!1,c=o+1),s>=0&&(l===t.charCodeAt(s)?--s===-1&&(i=o):(s=-1,i=c))}return r===i?i=c:i===-1&&(i=e.length),e.slice(r,i)}else{for(o=e.length-1;o>=0;--o)if(e.charCodeAt(o)===47){if(!a){r=o+1;break}}else i===-1&&(a=!1,i=o+1);return i===-1?``:e.slice(r,i)}},extname:function(e){n(e);for(var t=-1,r=0,i=-1,a=!0,o=0,s=e.length-1;s>=0;--s){var c=e.charCodeAt(s);if(c===47){if(!a){r=s+1;break}continue}i===-1&&(a=!1,i=s+1),c===46?t===-1?t=s:o!==1&&(o=1):t!==-1&&(o=-1)}return t===-1||i===-1||o===0||o===1&&t===i-1&&t===r+1?``:e.slice(t,i)},format:function(e){if(typeof e!=`object`||!e)throw TypeError(`The "pathObject" argument must be of type Object. Received type `+typeof e);return i(`/`,e)},parse:function(e){n(e);var t={root:``,dir:``,base:``,ext:``,name:``};if(e.length===0)return t;var r=e.charCodeAt(0),i=r===47,a;i?(t.root=`/`,a=1):a=0;for(var o=-1,s=0,c=-1,l=!0,u=e.length-1,d=0;u>=a;--u){if(r=e.charCodeAt(u),r===47){if(!l){s=u+1;break}continue}c===-1&&(l=!1,c=u+1),r===46?o===-1?o=u:d!==1&&(d=1):o!==-1&&(d=-1)}return o===-1||c===-1||d===0||d===1&&o===c-1&&o===s+1?c!==-1&&(s===0&&i?t.base=t.name=e.slice(1,c):t.base=t.name=e.slice(s,c)):(s===0&&i?(t.name=e.slice(1,o),t.base=e.slice(1,c)):(t.name=e.slice(s,o),t.base=e.slice(s,c)),t.ext=e.slice(o,c)),s>0?t.dir=e.slice(0,s-1):i&&(t.dir=`/`),t},sep:`/`,delimiter:`:`,win32:null,posix:null};a.posix=a,t.exports=a}));function v(e,t){return function(){return e.apply(t,arguments)}}let{toString:y}=Object.prototype,{getPrototypeOf:b}=Object,{iterator:x,toStringTag:S}=Symbol,C=(e=>t=>{let n=y.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),w=e=>(e=e.toLowerCase(),t=>C(t)===e),ee=e=>t=>typeof t===e,{isArray:te}=Array,ne=ee(`undefined`);function re(e){return e!==null&&!ne(e)&&e.constructor!==null&&!ne(e.constructor)&&T(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}let ie=w(`ArrayBuffer`);function ae(e){let t;return t=typeof ArrayBuffer<`u`&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&ie(e.buffer),t}let oe=ee(`string`),T=ee(`function`),se=ee(`number`),ce=e=>typeof e==`object`&&!!e,le=e=>e===!0||e===!1,ue=e=>{if(C(e)!==`object`)return!1;let t=b(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(S in e)&&!(x in e)},de=e=>{if(!ce(e)||re(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},fe=w(`Date`),pe=w(`File`),me=e=>!!(e&&e.uri!==void 0),he=e=>e&&e.getParts!==void 0,ge=w(`Blob`),_e=w(`FileList`),ve=e=>ce(e)&&T(e.pipe);function ye(){return typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{}}let be=ye(),xe=be.FormData===void 0?void 0:be.FormData,Se=e=>{if(!e)return!1;if(xe&&e instanceof xe)return!0;let t=b(e);if(!t||t===Object.prototype||!T(e.append))return!1;let n=C(e);return n===`formdata`||n===`object`&&T(e.toString)&&e.toString()===`[object FormData]`},Ce=w(`URLSearchParams`),[we,Te,Ee,De]=[`ReadableStream`,`Request`,`Response`,`Headers`].map(w),Oe=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``);function ke(e,t,{allOwnKeys:n=!1}={}){if(e==null)return;let r,i;if(typeof e!=`object`&&(e=[e]),te(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{if(re(e))return;let i=n?Object.getOwnPropertyNames(e):Object.keys(e),a=i.length,o;for(r=0;r<a;r++)o=i[r],t.call(null,e[o],o,e)}}function Ae(e,t){if(re(e))return null;t=t.toLowerCase();let n=Object.keys(e),r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}let je=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:global,Me=e=>!ne(e)&&e!==je;function Ne(){let{caseless:e,skipUndefined:t}=Me(this)&&this||{},n={},r=(r,i)=>{if(i===`__proto__`||i===`constructor`||i===`prototype`)return;let a=e&&Ae(n,i)||i;ue(n[a])&&ue(r)?n[a]=Ne(n[a],r):ue(r)?n[a]=Ne({},r):te(r)?n[a]=r.slice():(!t||!ne(r))&&(n[a]=r)};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&ke(arguments[e],r);return n}let Pe=(e,t,n,{allOwnKeys:r}={})=>(ke(t,(t,r)=>{n&&T(t)?Object.defineProperty(e,r,{value:v(t,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,r,{value:t,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),Fe=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Ie=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,`constructor`,{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,`super`,{value:t.prototype}),n&&Object.assign(e.prototype,n)},Le=(e,t,n,r)=>{let i,a,o,s={};if(t||={},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),a=i.length;a-- >0;)o=i[a],(!r||r(o,e,t))&&!s[o]&&(t[o]=e[o],s[o]=!0);e=n!==!1&&b(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},Re=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;let r=e.indexOf(t,n);return r!==-1&&r===n},ze=e=>{if(!e)return null;if(te(e))return e;let t=e.length;if(!se(t))return null;let n=Array(t);for(;t-- >0;)n[t]=e[t];return n},Be=(e=>t=>e&&t instanceof e)(typeof Uint8Array<`u`&&b(Uint8Array)),Ve=(e,t)=>{let n=(e&&e[x]).call(e),r;for(;(r=n.next())&&!r.done;){let n=r.value;t.call(e,n[0],n[1])}},He=(e,t)=>{let n,r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},Ue=w(`HTMLFormElement`),We=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,n){return t.toUpperCase()+n}),Ge=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Ke=w(`RegExp`),qe=(e,t)=>{let n=Object.getOwnPropertyDescriptors(e),r={};ke(n,(n,i)=>{let a;(a=t(n,i,e))!==!1&&(r[i]=a||n)}),Object.defineProperties(e,r)},Je=e=>{qe(e,(t,n)=>{if(T(e)&&[`arguments`,`caller`,`callee`].indexOf(n)!==-1)return!1;let r=e[n];if(T(r)){if(t.enumerable=!1,`writable`in t){t.writable=!1;return}t.set||=()=>{throw Error(`Can not rewrite read-only method '`+n+`'`)}}})},Ye=(e,t)=>{let n={},r=e=>{e.forEach(e=>{n[e]=!0})};return te(e)?r(e):r(String(e).split(t)),n},Xe=()=>{},Ze=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function Qe(e){return!!(e&&T(e.append)&&e[S]===`FormData`&&e[x])}let $e=e=>{let t=Array(10),n=(e,r)=>{if(ce(e)){if(t.indexOf(e)>=0)return;if(re(e))return e;if(!(`toJSON`in e)){t[r]=e;let i=te(e)?[]:{};return ke(e,(e,t)=>{let a=n(e,r+1);!ne(a)&&(i[t]=a)}),t[r]=void 0,i}}return e};return n(e,0)},et=w(`AsyncFunction`),tt=e=>e&&(ce(e)||T(e))&&T(e.then)&&T(e.catch),nt=((e,t)=>e?setImmediate:t?((e,t)=>(je.addEventListener(`message`,({source:n,data:r})=>{n===je&&r===e&&t.length&&t.shift()()},!1),n=>{t.push(n),je.postMessage(e,`*`)}))(`axios@${Math.random()}`,[]):e=>setTimeout(e))(typeof setImmediate==`function`,T(je.postMessage));var E={isArray:te,isArrayBuffer:ie,isBuffer:re,isFormData:Se,isArrayBufferView:ae,isString:oe,isNumber:se,isBoolean:le,isObject:ce,isPlainObject:ue,isEmptyObject:de,isReadableStream:we,isRequest:Te,isResponse:Ee,isHeaders:De,isUndefined:ne,isDate:fe,isFile:pe,isReactNativeBlob:me,isReactNative:he,isBlob:ge,isRegExp:Ke,isFunction:T,isStream:ve,isURLSearchParams:Ce,isTypedArray:Be,isFileList:_e,forEach:ke,merge:Ne,extend:Pe,trim:Oe,stripBOM:Fe,inherits:Ie,toFlatObject:Le,kindOf:C,kindOfTest:w,endsWith:Re,toArray:ze,forEachEntry:Ve,matchAll:He,isHTMLForm:Ue,hasOwnProperty:Ge,hasOwnProp:Ge,reduceDescriptors:qe,freezeMethods:Je,toObjectSet:Ye,toCamelCase:We,noop:Xe,toFiniteNumber:Ze,findKey:Ae,global:je,isContextDefined:Me,isSpecCompliantForm:Qe,toJSONObject:$e,isAsyncFn:et,isThenable:tt,setImmediate:nt,asap:typeof queueMicrotask<`u`?queueMicrotask.bind(je):typeof process<`u`&&process.nextTick||nt,isIterable:e=>e!=null&&T(e[x])},D=class e extends Error{static from(t,n,r,i,a,o){let s=new e(t.message,n||t.code,r,i,a);return s.cause=t,s.name=t.name,t.status!=null&&s.status==null&&(s.status=t.status),o&&Object.assign(s,o),s}constructor(e,t,n,r,i){super(e),Object.defineProperty(this,`message`,{value:e,enumerable:!0,writable:!0,configurable:!0}),this.name=`AxiosError`,this.isAxiosError=!0,t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i,this.status=i.status)}toJSON(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:E.toJSONObject(this.config),code:this.code,status:this.status}}};D.ERR_BAD_OPTION_VALUE=`ERR_BAD_OPTION_VALUE`,D.ERR_BAD_OPTION=`ERR_BAD_OPTION`,D.ECONNABORTED=`ECONNABORTED`,D.ETIMEDOUT=`ETIMEDOUT`,D.ERR_NETWORK=`ERR_NETWORK`,D.ERR_FR_TOO_MANY_REDIRECTS=`ERR_FR_TOO_MANY_REDIRECTS`,D.ERR_DEPRECATED=`ERR_DEPRECATED`,D.ERR_BAD_RESPONSE=`ERR_BAD_RESPONSE`,D.ERR_BAD_REQUEST=`ERR_BAD_REQUEST`,D.ERR_CANCELED=`ERR_CANCELED`,D.ERR_NOT_SUPPORT=`ERR_NOT_SUPPORT`,D.ERR_INVALID_URL=`ERR_INVALID_URL`,D.ERR_FORM_DATA_DEPTH_EXCEEDED=`ERR_FORM_DATA_DEPTH_EXCEEDED`;function rt(e){return E.isPlainObject(e)||E.isArray(e)}function it(e){return E.endsWith(e,`[]`)?e.slice(0,-2):e}function at(e,t,n){return e?e.concat(t).map(function(e,t){return e=it(e),!n&&t?`[`+e+`]`:e}).join(n?`.`:``):t}function ot(e){return E.isArray(e)&&!e.some(rt)}let st=E.toFlatObject(E,{},null,function(e){return/^is[A-Z]/.test(e)});function ct(e,t,n){if(!E.isObject(e))throw TypeError(`target must be an object`);t||=new FormData,n=E.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!E.isUndefined(t[e])});let r=n.metaTokens,i=n.visitor||d,a=n.dots,o=n.indexes,s=n.Blob||typeof Blob<`u`&&Blob,c=n.maxDepth===void 0?100:n.maxDepth,l=s&&E.isSpecCompliantForm(t);if(!E.isFunction(i))throw TypeError(`visitor must be a function`);function u(e){if(e===null)return``;if(E.isDate(e))return e.toISOString();if(E.isBoolean(e))return e.toString();if(!l&&E.isBlob(e))throw new D(`Blob is not supported. Use a Buffer instead.`);return E.isArrayBuffer(e)||E.isTypedArray(e)?l&&typeof Blob==`function`?new Blob([e]):Buffer.from(e):e}function d(e,n,i){let s=e;if(E.isReactNative(t)&&E.isReactNativeBlob(e))return t.append(at(i,n,a),u(e)),!1;if(e&&!i&&typeof e==`object`){if(E.endsWith(n,`{}`))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(E.isArray(e)&&ot(e)||(E.isFileList(e)||E.endsWith(n,`[]`))&&(s=E.toArray(e)))return n=it(n),s.forEach(function(e,r){!(E.isUndefined(e)||e===null)&&t.append(o===!0?at([n],r,a):o===null?n:n+`[]`,u(e))}),!1}return rt(e)?!0:(t.append(at(i,n,a),u(e)),!1)}let f=[],p=Object.assign(st,{defaultVisitor:d,convertValue:u,isVisitable:rt});function m(e,n,r=0){if(!E.isUndefined(e)){if(r>c)throw new D(`Object is too deeply nested (`+r+` levels). Max depth: `+c,D.ERR_FORM_DATA_DEPTH_EXCEEDED);if(f.indexOf(e)!==-1)throw Error(`Circular reference detected in `+n.join(`.`));f.push(e),E.forEach(e,function(e,a){(!(E.isUndefined(e)||e===null)&&i.call(t,e,E.isString(a)?a.trim():a,n,p))===!0&&m(e,n?n.concat(a):[a],r+1)}),f.pop()}}if(!E.isObject(e))throw TypeError(`data must be an object`);return m(e),t}function lt(e){let t={"!":`%21`,"'":`%27`,"(":`%28`,")":`%29`,"~":`%7E`,"%20":`+`};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(e){return t[e]})}function ut(e,t){this._pairs=[],e&&ct(e,this,t)}let dt=ut.prototype;dt.append=function(e,t){this._pairs.push([e,t])},dt.toString=function(e){let t=e?function(t){return e.call(this,t,lt)}:lt;return this._pairs.map(function(e){return t(e[0])+`=`+t(e[1])},``).join(`&`)};function ft(e){return encodeURIComponent(e).replace(/%3A/gi,`:`).replace(/%24/g,`$`).replace(/%2C/gi,`,`).replace(/%20/g,`+`)}function pt(e,t,n){if(!t)return e;let r=n&&n.encode||ft,i=E.isFunction(n)?{serialize:n}:n,a=i&&i.serialize,o;if(o=a?a(t,i):E.isURLSearchParams(t)?t.toString():new ut(t,i).toString(r),o){let t=e.indexOf(`#`);t!==-1&&(e=e.slice(0,t)),e+=(e.indexOf(`?`)===-1?`?`:`&`)+o}return e}var mt=class{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&=[]}forEach(e){E.forEach(this.handlers,function(t){t!==null&&e(t)})}},ht={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},gt={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<`u`?URLSearchParams:ut,FormData:typeof FormData<`u`?FormData:null,Blob:typeof Blob<`u`?Blob:null},protocols:[`http`,`https`,`file`,`blob`,`url`,`data`]},_t=s({hasBrowserEnv:()=>vt,hasStandardBrowserEnv:()=>bt,hasStandardBrowserWebWorkerEnv:()=>xt,navigator:()=>yt,origin:()=>St});let vt=typeof window<`u`&&typeof document<`u`,yt=typeof navigator==`object`&&navigator||void 0,bt=vt&&(!yt||[`ReactNative`,`NativeScript`,`NS`].indexOf(yt.product)<0),xt=typeof WorkerGlobalScope<`u`&&self instanceof WorkerGlobalScope&&typeof self.importScripts==`function`,St=vt&&window.location.href||`http://localhost`;var O={..._t,...gt};function Ct(e,t){return ct(e,new O.classes.URLSearchParams,{visitor:function(e,t,n,r){return O.isNode&&E.isBuffer(e)?(this.append(t,e.toString(`base64`)),!1):r.defaultVisitor.apply(this,arguments)},...t})}function wt(e){return E.matchAll(/\w+|\[(\w*)]/g,e).map(e=>e[0]===`[]`?``:e[1]||e[0])}function Tt(e){let t={},n=Object.keys(e),r,i=n.length,a;for(r=0;r<i;r++)a=n[r],t[a]=e[a];return t}function Et(e){function t(e,n,r,i){let a=e[i++];if(a===`__proto__`)return!0;let o=Number.isFinite(+a),s=i>=e.length;return a=!a&&E.isArray(r)?r.length:a,s?(E.hasOwnProp(r,a)?r[a]=E.isArray(r[a])?r[a].concat(n):[r[a],n]:r[a]=n,!o):((!r[a]||!E.isObject(r[a]))&&(r[a]=[]),t(e,n,r[a],i)&&E.isArray(r[a])&&(r[a]=Tt(r[a])),!o)}if(E.isFormData(e)&&E.isFunction(e.entries)){let n={};return E.forEachEntry(e,(e,r)=>{t(wt(e),r,n,0)}),n}return null}let Dt=(e,t)=>e!=null&&E.hasOwnProp(e,t)?e[t]:void 0;function Ot(e,t,n){if(E.isString(e))try{return(t||JSON.parse)(e),E.trim(e)}catch(e){if(e.name!==`SyntaxError`)throw e}return(n||JSON.stringify)(e)}let kt={transitional:ht,adapter:[`xhr`,`http`,`fetch`],transformRequest:[function(e,t){let n=t.getContentType()||``,r=n.indexOf(`application/json`)>-1,i=E.isObject(e);if(i&&E.isHTMLForm(e)&&(e=new FormData(e)),E.isFormData(e))return r?JSON.stringify(Et(e)):e;if(E.isArrayBuffer(e)||E.isBuffer(e)||E.isStream(e)||E.isFile(e)||E.isBlob(e)||E.isReadableStream(e))return e;if(E.isArrayBufferView(e))return e.buffer;if(E.isURLSearchParams(e))return t.setContentType(`application/x-www-form-urlencoded;charset=utf-8`,!1),e.toString();let a;if(i){let t=Dt(this,`formSerializer`);if(n.indexOf(`application/x-www-form-urlencoded`)>-1)return Ct(e,t).toString();if((a=E.isFileList(e))||n.indexOf(`multipart/form-data`)>-1){let n=Dt(this,`env`),r=n&&n.FormData;return ct(a?{"files[]":e}:e,r&&new r,t)}}return i||r?(t.setContentType(`application/json`,!1),Ot(e)):e}],transformResponse:[function(e){let t=Dt(this,`transitional`)||kt.transitional,n=t&&t.forcedJSONParsing,r=Dt(this,`responseType`),i=r===`json`;if(E.isResponse(e)||E.isReadableStream(e))return e;if(e&&E.isString(e)&&(n&&!r||i)){let n=!(t&&t.silentJSONParsing)&&i;try{return JSON.parse(e,Dt(this,`parseReviver`))}catch(e){if(n)throw e.name===`SyntaxError`?D.from(e,D.ERR_BAD_RESPONSE,this,null,Dt(this,`response`)):e}}return e}],timeout:0,xsrfCookieName:`XSRF-TOKEN`,xsrfHeaderName:`X-XSRF-TOKEN`,maxContentLength:-1,maxBodyLength:-1,env:{FormData:O.classes.FormData,Blob:O.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:`application/json, text/plain, */*`,"Content-Type":void 0}}};E.forEach([`delete`,`get`,`head`,`post`,`put`,`patch`],e=>{kt.headers[e]={}});let At=E.toObjectSet([`age`,`authorization`,`content-length`,`content-type`,`etag`,`expires`,`from`,`host`,`if-modified-since`,`if-unmodified-since`,`last-modified`,`location`,`max-forwards`,`proxy-authorization`,`referer`,`retry-after`,`user-agent`]);var jt=e=>{let t={},n,r,i;return e&&e.split(`
2
2
  `).forEach(function(e){i=e.indexOf(`:`),n=e.substring(0,i).trim().toLowerCase(),r=e.substring(i+1).trim(),!(!n||t[n]&&At[n])&&(n===`set-cookie`?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+`, `+r:r)}),t};let Mt=Symbol(`internals`),Nt=/[^\x09\x20-\x7E\x80-\xFF]/g;function Pt(e){let t=0,n=e.length;for(;t<n;){let n=e.charCodeAt(t);if(n!==9&&n!==32)break;t+=1}for(;n>t;){let t=e.charCodeAt(n-1);if(t!==9&&t!==32)break;--n}return t===0&&n===e.length?e:e.slice(t,n)}function Ft(e){return e&&String(e).trim().toLowerCase()}function It(e){return Pt(e.replace(Nt,``))}function Lt(e){return e===!1||e==null?e:E.isArray(e)?e.map(Lt):It(String(e))}function Rt(e){let t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}let zt=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Bt(e,t,n,r,i){if(E.isFunction(r))return r.call(this,t,n);if(i&&(t=n),E.isString(t)){if(E.isString(r))return t.indexOf(r)!==-1;if(E.isRegExp(r))return r.test(t)}}function Vt(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,n)=>t.toUpperCase()+n)}function Ht(e,t){let n=E.toCamelCase(` `+t);[`get`,`set`,`has`].forEach(r=>{Object.defineProperty(e,r+n,{value:function(e,n,i){return this[r].call(this,t,e,n,i)},configurable:!0})})}var k=class{constructor(e){e&&this.set(e)}set(e,t,n){let r=this;function i(e,t,n){let i=Ft(t);if(!i)throw Error(`header name must be a non-empty string`);let a=E.findKey(r,i);(!a||r[a]===void 0||n===!0||n===void 0&&r[a]!==!1)&&(r[a||t]=Lt(e))}let a=(e,t)=>E.forEach(e,(e,n)=>i(e,n,t));if(E.isPlainObject(e)||e instanceof this.constructor)a(e,t);else if(E.isString(e)&&(e=e.trim())&&!zt(e))a(jt(e),t);else if(E.isObject(e)&&E.isIterable(e)){let n={},r,i;for(let t of e){if(!E.isArray(t))throw TypeError(`Object iterator must return a key-value pair`);n[i=t[0]]=(r=n[i])?E.isArray(r)?[...r,t[1]]:[r,t[1]]:t[1]}a(n,t)}else e!=null&&i(t,e,n);return this}get(e,t){if(e=Ft(e),e){let n=E.findKey(this,e);if(n){let e=this[n];if(!t)return e;if(t===!0)return Rt(e);if(E.isFunction(t))return t.call(this,e,n);if(E.isRegExp(t))return t.exec(e);throw TypeError(`parser must be boolean|regexp|function`)}}}has(e,t){if(e=Ft(e),e){let n=E.findKey(this,e);return!!(n&&this[n]!==void 0&&(!t||Bt(this,this[n],n,t)))}return!1}delete(e,t){let n=this,r=!1;function i(e){if(e=Ft(e),e){let i=E.findKey(n,e);i&&(!t||Bt(n,n[i],i,t))&&(delete n[i],r=!0)}}return E.isArray(e)?e.forEach(i):i(e),r}clear(e){let t=Object.keys(this),n=t.length,r=!1;for(;n--;){let i=t[n];(!e||Bt(this,this[i],i,e,!0))&&(delete this[i],r=!0)}return r}normalize(e){let t=this,n={};return E.forEach(this,(r,i)=>{let a=E.findKey(n,i);if(a){t[a]=Lt(r),delete t[i];return}let o=e?Vt(i):String(i).trim();o!==i&&delete t[i],t[o]=Lt(r),n[o]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){let t=Object.create(null);return E.forEach(this,(n,r)=>{n!=null&&n!==!1&&(t[r]=e&&E.isArray(n)?n.join(`, `):n)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+`: `+t).join(`
3
- `)}getSetCookie(){return this.get(`set-cookie`)||[]}get[Symbol.toStringTag](){return`AxiosHeaders`}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){let n=new this(e);return t.forEach(e=>n.set(e)),n}static accessor(e){let t=(this[Mt]=this[Mt]={accessors:{}}).accessors,n=this.prototype;function r(e){let r=Ft(e);t[r]||(Ht(n,e),t[r]=!0)}return E.isArray(e)?e.forEach(r):r(e),this}};k.accessor([`Content-Type`,`Content-Length`,`Accept`,`Accept-Encoding`,`User-Agent`,`Authorization`]),E.reduceDescriptors(k.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}}),E.freezeMethods(k);function Ut(e,t){let n=this||kt,r=t||n,i=k.from(r.headers),a=r.data;return E.forEach(e,function(e){a=e.call(n,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function Wt(e){return!!(e&&e.__CANCEL__)}var Gt=class extends D{constructor(e,t,n){super(e??`canceled`,D.ERR_CANCELED,t,n),this.name=`CanceledError`,this.__CANCEL__=!0}};function Kt(e,t,n){let r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new D(`Request failed with status code `+n.status,[D.ERR_BAD_REQUEST,D.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function qt(e){let t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||``}function Jt(e,t){e||=10;let n=Array(e),r=Array(e),i=0,a=0,o;return t=t===void 0?1e3:t,function(s){let c=Date.now(),l=r[a];o||=c,n[i]=s,r[i]=c;let u=a,d=0;for(;u!==i;)d+=n[u++],u%=e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),c-o<t)return;let f=l&&c-l;return f?Math.round(d*1e3/f):void 0}}function Yt(e,t){let n=0,r=1e3/t,i,a,o=(t,r=Date.now())=>{n=r,i=null,a&&=(clearTimeout(a),null),e(...t)};return[(...e)=>{let t=Date.now(),s=t-n;s>=r?o(e,t):(i=e,a||=setTimeout(()=>{a=null,o(i)},r-s))},()=>i&&o(i)]}let Xt=(e,t,n=3)=>{let r=0,i=Jt(50,250);return Yt(n=>{let a=n.loaded,o=n.lengthComputable?n.total:void 0,s=o==null?a:Math.min(a,o),c=Math.max(0,s-r),l=i(c);r=Math.max(r,s),e({loaded:s,total:o,progress:o?s/o:void 0,bytes:c,rate:l||void 0,estimated:l&&o?(o-s)/l:void 0,event:n,lengthComputable:o!=null,[t?`download`:`upload`]:!0})},n)},Zt=(e,t)=>{let n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Qt=e=>(...t)=>E.asap(()=>e(...t));var $t=O.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,O.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(O.origin),O.navigator&&/(msie|trident)/i.test(O.navigator.userAgent)):()=>!0,en=O.hasStandardBrowserEnv?{write(e,t,n,r,i,a,o){if(typeof document>`u`)return;let s=[`${e}=${encodeURIComponent(t)}`];E.isNumber(n)&&s.push(`expires=${new Date(n).toUTCString()}`),E.isString(r)&&s.push(`path=${r}`),E.isString(i)&&s.push(`domain=${i}`),a===!0&&s.push(`secure`),E.isString(o)&&s.push(`SameSite=${o}`),document.cookie=s.join(`; `)},read(e){if(typeof document>`u`)return null;let t=document.cookie.match(RegExp(`(?:^|; )`+e+`=([^;]*)`));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,``,Date.now()-864e5,`/`)}}:{write(){},read(){return null},remove(){}};function tn(e){return typeof e==`string`?/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e):!1}function nn(e,t){return t?e.replace(/\/?\/$/,``)+`/`+t.replace(/^\/+/,``):e}function rn(e,t,n){let r=!tn(t);return e&&(r||n===!1)?nn(e,t):t}let an=e=>e instanceof k?{...e}:e;function on(e,t){t||={};let n={};function r(e,t,n,r){return E.isPlainObject(e)&&E.isPlainObject(t)?E.merge.call({caseless:r},e,t):E.isPlainObject(t)?E.merge({},t):E.isArray(t)?t.slice():t}function i(e,t,n,i){if(!E.isUndefined(t))return r(e,t,n,i);if(!E.isUndefined(e))return r(void 0,e,n,i)}function a(e,t){if(!E.isUndefined(t))return r(void 0,t)}function o(e,t){if(!E.isUndefined(t))return r(void 0,t);if(!E.isUndefined(e))return r(void 0,e)}function s(n,i,a){if(E.hasOwnProp(t,a))return r(n,i);if(E.hasOwnProp(e,a))return r(void 0,n)}let c={url:a,method:a,data:a,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:s,headers:(e,t,n)=>i(an(e),an(t),n,!0)};return E.forEach(Object.keys({...e,...t}),function(r){if(r===`__proto__`||r===`constructor`||r===`prototype`)return;let a=E.hasOwnProp(c,r)?c[r]:i,o=a(E.hasOwnProp(e,r)?e[r]:void 0,E.hasOwnProp(t,r)?t[r]:void 0,r);E.isUndefined(o)&&a!==s||(n[r]=o)}),n}var sn=e=>{let t=on({},e),{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:a,headers:o,auth:s}=t;if(t.headers=o=k.from(o),t.url=pt(rn(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),s&&o.set(`Authorization`,`Basic `+btoa((s.username||``)+`:`+(s.password?unescape(encodeURIComponent(s.password)):``))),E.isFormData(n)){if(O.hasStandardBrowserEnv||O.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(E.isFunction(n.getHeaders)){let e=n.getHeaders(),t=[`content-type`,`content-length`];Object.entries(e).forEach(([e,n])=>{t.includes(e.toLowerCase())&&o.set(e,n)})}}if(O.hasStandardBrowserEnv&&(E.isFunction(r)&&(r=r(t)),r===!0||r==null&&$t(t.url))){let e=i&&a&&en.read(a);e&&o.set(i,e)}return t},cn=typeof XMLHttpRequest<`u`&&function(e){return new Promise(function(t,n){let r=sn(e),i=r.data,a=k.from(r.headers).normalize(),{responseType:o,onUploadProgress:s,onDownloadProgress:c}=r,l,u,d,f,p;function m(){f&&f(),p&&p(),r.cancelToken&&r.cancelToken.unsubscribe(l),r.signal&&r.signal.removeEventListener(`abort`,l)}let h=new XMLHttpRequest;h.open(r.method.toUpperCase(),r.url,!0),h.timeout=r.timeout;function g(){if(!h)return;let r=k.from(`getAllResponseHeaders`in h&&h.getAllResponseHeaders());Kt(function(e){t(e),m()},function(e){n(e),m()},{data:!o||o===`text`||o===`json`?h.responseText:h.response,status:h.status,statusText:h.statusText,headers:r,config:e,request:h}),h=null}`onloadend`in h?h.onloadend=g:h.onreadystatechange=function(){!h||h.readyState!==4||h.status===0&&!(h.responseURL&&h.responseURL.indexOf(`file:`)===0)||setTimeout(g)},h.onabort=function(){h&&=(n(new D(`Request aborted`,D.ECONNABORTED,e,h)),null)},h.onerror=function(t){let r=new D(t&&t.message?t.message:`Network Error`,D.ERR_NETWORK,e,h);r.event=t||null,n(r),h=null},h.ontimeout=function(){let t=r.timeout?`timeout of `+r.timeout+`ms exceeded`:`timeout exceeded`,i=r.transitional||ht;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),n(new D(t,i.clarifyTimeoutError?D.ETIMEDOUT:D.ECONNABORTED,e,h)),h=null},i===void 0&&a.setContentType(null),`setRequestHeader`in h&&E.forEach(a.toJSON(),function(e,t){h.setRequestHeader(t,e)}),E.isUndefined(r.withCredentials)||(h.withCredentials=!!r.withCredentials),o&&o!==`json`&&(h.responseType=r.responseType),c&&([d,p]=Xt(c,!0),h.addEventListener(`progress`,d)),s&&h.upload&&([u,f]=Xt(s),h.upload.addEventListener(`progress`,u),h.upload.addEventListener(`loadend`,f)),(r.cancelToken||r.signal)&&(l=t=>{h&&=(n(!t||t.type?new Gt(null,e,h):t),h.abort(),null)},r.cancelToken&&r.cancelToken.subscribe(l),r.signal&&(r.signal.aborted?l():r.signal.addEventListener(`abort`,l)));let _=qt(r.url);if(_&&O.protocols.indexOf(_)===-1){n(new D(`Unsupported protocol `+_+`:`,D.ERR_BAD_REQUEST,e));return}h.send(i||null)})};let ln=(e,t)=>{let{length:n}=e=e?e.filter(Boolean):[];if(t||n){let n=new AbortController,r,i=function(e){if(!r){r=!0,o();let t=e instanceof Error?e:this.reason;n.abort(t instanceof D?t:new Gt(t instanceof Error?t.message:t))}},a=t&&setTimeout(()=>{a=null,i(new D(`timeout of ${t}ms exceeded`,D.ETIMEDOUT))},t),o=()=>{e&&=(a&&clearTimeout(a),a=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(i):e.removeEventListener(`abort`,i)}),null)};e.forEach(e=>e.addEventListener(`abort`,i));let{signal:s}=n;return s.unsubscribe=()=>E.asap(o),s}},un=function*(e,t){let n=e.byteLength;if(!t||n<t){yield e;return}let r=0,i;for(;r<n;)i=r+t,yield e.slice(r,i),r=i},dn=async function*(e,t){for await(let n of fn(e))yield*un(n,t)},fn=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}let t=e.getReader();try{for(;;){let{done:e,value:n}=await t.read();if(e)break;yield n}}finally{await t.cancel()}},pn=(e,t,n,r)=>{let i=dn(e,t),a=0,o,s=e=>{o||(o=!0,r&&r(e))};return new ReadableStream({async pull(e){try{let{done:t,value:r}=await i.next();if(t){s(),e.close();return}let o=r.byteLength;n&&n(a+=o),e.enqueue(new Uint8Array(r))}catch(e){throw s(e),e}},cancel(e){return s(e),i.return()}},{highWaterMark:2})},mn=64*1024,{isFunction:hn}=E,gn=(({Request:e,Response:t})=>({Request:e,Response:t}))(E.global),{ReadableStream:_n,TextEncoder:vn}=E.global,yn=(e,...t)=>{try{return!!e(...t)}catch{return!1}},bn=e=>{e=E.merge.call({skipUndefined:!0},gn,e);let{fetch:t,Request:n,Response:r}=e,i=t?hn(t):typeof fetch==`function`,a=hn(n),o=hn(r);if(!i)return!1;let s=i&&hn(_n),c=i&&(typeof vn==`function`?(e=>t=>e.encode(t))(new vn):async e=>new Uint8Array(await new n(e).arrayBuffer())),l=a&&s&&yn(()=>{let e=!1,t=new n(O.origin,{body:new _n,method:`POST`,get duplex(){return e=!0,`half`}}),r=t.headers.has(`Content-Type`);return t.body!=null&&t.body.cancel(),e&&!r}),u=o&&s&&yn(()=>E.isReadableStream(new r(``).body)),d={stream:u&&(e=>e.body)};i&&[`text`,`arrayBuffer`,`blob`,`formData`,`stream`].forEach(e=>{!d[e]&&(d[e]=(t,n)=>{let r=t&&t[e];if(r)return r.call(t);throw new D(`Response type '${e}' is not supported`,D.ERR_NOT_SUPPORT,n)})});let f=async e=>{if(e==null)return 0;if(E.isBlob(e))return e.size;if(E.isSpecCompliantForm(e))return(await new n(O.origin,{method:`POST`,body:e}).arrayBuffer()).byteLength;if(E.isArrayBufferView(e)||E.isArrayBuffer(e))return e.byteLength;if(E.isURLSearchParams(e)&&(e+=``),E.isString(e))return(await c(e)).byteLength},p=async(e,t)=>E.toFiniteNumber(e.getContentLength())??f(t);return async e=>{let{url:i,method:o,data:s,signal:c,cancelToken:f,timeout:m,onDownloadProgress:h,onUploadProgress:g,responseType:_,headers:v,withCredentials:y=`same-origin`,fetchOptions:b}=sn(e),x=t||fetch;_=_?(_+``).toLowerCase():`text`;let S=ln([c,f&&f.toAbortSignal()],m),C=null,w=S&&S.unsubscribe&&(()=>{S.unsubscribe()}),ee;try{if(g&&l&&o!==`get`&&o!==`head`&&(ee=await p(v,s))!==0){let e=new n(i,{method:`POST`,body:s,duplex:`half`}),t;if(E.isFormData(s)&&(t=e.headers.get(`content-type`))&&v.setContentType(t),e.body){let[t,n]=Zt(ee,Xt(Qt(g)));s=pn(e.body,mn,t,n)}}E.isString(y)||(y=y?`include`:`omit`);let t=a&&`credentials`in n.prototype;if(E.isFormData(s)){let e=v.getContentType();e&&/^multipart\/form-data/i.test(e)&&!/boundary=/i.test(e)&&v.delete(`content-type`)}let c={...b,signal:S,method:o.toUpperCase(),headers:v.normalize().toJSON(),body:s,duplex:`half`,credentials:t?y:void 0};C=a&&new n(i,c);let f=await(a?x(C,b):x(i,c)),m=u&&(_===`stream`||_===`response`);if(u&&(h||m&&w)){let e={};[`status`,`statusText`,`headers`].forEach(t=>{e[t]=f[t]});let t=E.toFiniteNumber(f.headers.get(`content-length`)),[n,i]=h&&Zt(t,Xt(Qt(h),!0))||[];f=new r(pn(f.body,mn,n,()=>{i&&i(),w&&w()}),e)}_||=`text`;let te=await d[E.findKey(d,_)||`text`](f,e);return!m&&w&&w(),await new Promise((t,n)=>{Kt(t,n,{data:te,headers:k.from(f.headers),status:f.status,statusText:f.statusText,config:e,request:C})})}catch(t){throw w&&w(),t&&t.name===`TypeError`&&/Load failed|fetch/i.test(t.message)?Object.assign(new D(`Network Error`,D.ERR_NETWORK,e,C,t&&t.response),{cause:t.cause||t}):D.from(t,t&&t.code,e,C,t&&t.response)}}},xn=new Map,Sn=e=>{let t=e&&e.env||{},{fetch:n,Request:r,Response:i}=t,a=[r,i,n],o=a.length,s,c,l=xn;for(;o--;)s=a[o],c=l.get(s),c===void 0&&l.set(s,c=o?new Map:bn(t)),l=c;return c};Sn();let Cn={http:null,xhr:cn,fetch:{get:Sn}};E.forEach(Cn,(e,t)=>{if(e){try{Object.defineProperty(e,`name`,{value:t})}catch{}Object.defineProperty(e,`adapterName`,{value:t})}});let wn=e=>`- ${e}`,Tn=e=>E.isFunction(e)||e===null||e===!1;function En(e,t){e=E.isArray(e)?e:[e];let{length:n}=e,r,i,a={};for(let o=0;o<n;o++){r=e[o];let n;if(i=r,!Tn(r)&&(i=Cn[(n=String(r)).toLowerCase()],i===void 0))throw new D(`Unknown adapter '${n}'`);if(i&&(E.isFunction(i)||(i=i.get(t))))break;a[n||`#`+o]=i}if(!i){let e=Object.entries(a).map(([e,t])=>`adapter ${e} `+(t===!1?`is not supported by the environment`:`is not available in the build`));throw new D(`There is no suitable adapter to dispatch the request `+(n?e.length>1?`since :
3
+ `)}getSetCookie(){return this.get(`set-cookie`)||[]}get[Symbol.toStringTag](){return`AxiosHeaders`}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){let n=new this(e);return t.forEach(e=>n.set(e)),n}static accessor(e){let t=(this[Mt]=this[Mt]={accessors:{}}).accessors,n=this.prototype;function r(e){let r=Ft(e);t[r]||(Ht(n,e),t[r]=!0)}return E.isArray(e)?e.forEach(r):r(e),this}};k.accessor([`Content-Type`,`Content-Length`,`Accept`,`Accept-Encoding`,`User-Agent`,`Authorization`]),E.reduceDescriptors(k.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}}),E.freezeMethods(k);function Ut(e,t){let n=this||kt,r=t||n,i=k.from(r.headers),a=r.data;return E.forEach(e,function(e){a=e.call(n,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function Wt(e){return!!(e&&e.__CANCEL__)}var Gt=class extends D{constructor(e,t,n){super(e??`canceled`,D.ERR_CANCELED,t,n),this.name=`CanceledError`,this.__CANCEL__=!0}};function Kt(e,t,n){let r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new D(`Request failed with status code `+n.status,[D.ERR_BAD_REQUEST,D.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function qt(e){let t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||``}function Jt(e,t){e||=10;let n=Array(e),r=Array(e),i=0,a=0,o;return t=t===void 0?1e3:t,function(s){let c=Date.now(),l=r[a];o||=c,n[i]=s,r[i]=c;let u=a,d=0;for(;u!==i;)d+=n[u++],u%=e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),c-o<t)return;let f=l&&c-l;return f?Math.round(d*1e3/f):void 0}}function Yt(e,t){let n=0,r=1e3/t,i,a,o=(t,r=Date.now())=>{n=r,i=null,a&&=(clearTimeout(a),null),e(...t)};return[(...e)=>{let t=Date.now(),s=t-n;s>=r?o(e,t):(i=e,a||=setTimeout(()=>{a=null,o(i)},r-s))},()=>i&&o(i)]}let Xt=(e,t,n=3)=>{let r=0,i=Jt(50,250);return Yt(n=>{let a=n.loaded,o=n.lengthComputable?n.total:void 0,s=o==null?a:Math.min(a,o),c=Math.max(0,s-r),l=i(c);r=Math.max(r,s),e({loaded:s,total:o,progress:o?s/o:void 0,bytes:c,rate:l||void 0,estimated:l&&o?(o-s)/l:void 0,event:n,lengthComputable:o!=null,[t?`download`:`upload`]:!0})},n)},Zt=(e,t)=>{let n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},Qt=e=>(...t)=>E.asap(()=>e(...t));var $t=O.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,O.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(O.origin),O.navigator&&/(msie|trident)/i.test(O.navigator.userAgent)):()=>!0,en=O.hasStandardBrowserEnv?{write(e,t,n,r,i,a,o){if(typeof document>`u`)return;let s=[`${e}=${encodeURIComponent(t)}`];E.isNumber(n)&&s.push(`expires=${new Date(n).toUTCString()}`),E.isString(r)&&s.push(`path=${r}`),E.isString(i)&&s.push(`domain=${i}`),a===!0&&s.push(`secure`),E.isString(o)&&s.push(`SameSite=${o}`),document.cookie=s.join(`; `)},read(e){if(typeof document>`u`)return null;let t=document.cookie.match(RegExp(`(?:^|; )`+e+`=([^;]*)`));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,``,Date.now()-864e5,`/`)}}:{write(){},read(){return null},remove(){}};function tn(e){return typeof e==`string`?/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e):!1}function nn(e,t){return t?e.replace(/\/?\/$/,``)+`/`+t.replace(/^\/+/,``):e}function rn(e,t,n){let r=!tn(t);return e&&(r||n===!1)?nn(e,t):t}let an=e=>e instanceof k?{...e}:e;function on(e,t){t||={};let n=Object.create(null);Object.defineProperty(n,`hasOwnProperty`,{value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function r(e,t,n,r){return E.isPlainObject(e)&&E.isPlainObject(t)?E.merge.call({caseless:r},e,t):E.isPlainObject(t)?E.merge({},t):E.isArray(t)?t.slice():t}function i(e,t,n,i){if(!E.isUndefined(t))return r(e,t,n,i);if(!E.isUndefined(e))return r(void 0,e,n,i)}function a(e,t){if(!E.isUndefined(t))return r(void 0,t)}function o(e,t){if(!E.isUndefined(t))return r(void 0,t);if(!E.isUndefined(e))return r(void 0,e)}function s(n,i,a){if(E.hasOwnProp(t,a))return r(n,i);if(E.hasOwnProp(e,a))return r(void 0,n)}let c={url:a,method:a,data:a,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,allowedSocketPaths:o,responseEncoding:o,validateStatus:s,headers:(e,t,n)=>i(an(e),an(t),n,!0)};return E.forEach(Object.keys({...e,...t}),function(r){if(r===`__proto__`||r===`constructor`||r===`prototype`)return;let a=E.hasOwnProp(c,r)?c[r]:i,o=a(E.hasOwnProp(e,r)?e[r]:void 0,E.hasOwnProp(t,r)?t[r]:void 0,r);E.isUndefined(o)&&a!==s||(n[r]=o)}),n}var sn=e=>{let t=on({},e),n=e=>E.hasOwnProp(t,e)?t[e]:void 0,r=n(`data`),i=n(`withXSRFToken`),a=n(`xsrfHeaderName`),o=n(`xsrfCookieName`),s=n(`headers`),c=n(`auth`),l=n(`baseURL`),u=n(`allowAbsoluteUrls`),d=n(`url`);if(t.headers=s=k.from(s),t.url=pt(rn(l,d,u),e.params,e.paramsSerializer),c&&s.set(`Authorization`,`Basic `+btoa((c.username||``)+`:`+(c.password?unescape(encodeURIComponent(c.password)):``))),E.isFormData(r)){if(O.hasStandardBrowserEnv||O.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if(E.isFunction(r.getHeaders)){let e=r.getHeaders(),t=[`content-type`,`content-length`];Object.entries(e).forEach(([e,n])=>{t.includes(e.toLowerCase())&&s.set(e,n)})}}if(O.hasStandardBrowserEnv&&(E.isFunction(i)&&(i=i(t)),i===!0||i==null&&$t(t.url))){let e=a&&o&&en.read(o);e&&s.set(a,e)}return t},cn=typeof XMLHttpRequest<`u`&&function(e){return new Promise(function(t,n){let r=sn(e),i=r.data,a=k.from(r.headers).normalize(),{responseType:o,onUploadProgress:s,onDownloadProgress:c}=r,l,u,d,f,p;function m(){f&&f(),p&&p(),r.cancelToken&&r.cancelToken.unsubscribe(l),r.signal&&r.signal.removeEventListener(`abort`,l)}let h=new XMLHttpRequest;h.open(r.method.toUpperCase(),r.url,!0),h.timeout=r.timeout;function g(){if(!h)return;let r=k.from(`getAllResponseHeaders`in h&&h.getAllResponseHeaders());Kt(function(e){t(e),m()},function(e){n(e),m()},{data:!o||o===`text`||o===`json`?h.responseText:h.response,status:h.status,statusText:h.statusText,headers:r,config:e,request:h}),h=null}`onloadend`in h?h.onloadend=g:h.onreadystatechange=function(){!h||h.readyState!==4||h.status===0&&!(h.responseURL&&h.responseURL.indexOf(`file:`)===0)||setTimeout(g)},h.onabort=function(){h&&=(n(new D(`Request aborted`,D.ECONNABORTED,e,h)),null)},h.onerror=function(t){let r=new D(t&&t.message?t.message:`Network Error`,D.ERR_NETWORK,e,h);r.event=t||null,n(r),h=null},h.ontimeout=function(){let t=r.timeout?`timeout of `+r.timeout+`ms exceeded`:`timeout exceeded`,i=r.transitional||ht;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),n(new D(t,i.clarifyTimeoutError?D.ETIMEDOUT:D.ECONNABORTED,e,h)),h=null},i===void 0&&a.setContentType(null),`setRequestHeader`in h&&E.forEach(a.toJSON(),function(e,t){h.setRequestHeader(t,e)}),E.isUndefined(r.withCredentials)||(h.withCredentials=!!r.withCredentials),o&&o!==`json`&&(h.responseType=r.responseType),c&&([d,p]=Xt(c,!0),h.addEventListener(`progress`,d)),s&&h.upload&&([u,f]=Xt(s),h.upload.addEventListener(`progress`,u),h.upload.addEventListener(`loadend`,f)),(r.cancelToken||r.signal)&&(l=t=>{h&&=(n(!t||t.type?new Gt(null,e,h):t),h.abort(),null)},r.cancelToken&&r.cancelToken.subscribe(l),r.signal&&(r.signal.aborted?l():r.signal.addEventListener(`abort`,l)));let _=qt(r.url);if(_&&O.protocols.indexOf(_)===-1){n(new D(`Unsupported protocol `+_+`:`,D.ERR_BAD_REQUEST,e));return}h.send(i||null)})};let ln=(e,t)=>{let{length:n}=e=e?e.filter(Boolean):[];if(t||n){let n=new AbortController,r,i=function(e){if(!r){r=!0,o();let t=e instanceof Error?e:this.reason;n.abort(t instanceof D?t:new Gt(t instanceof Error?t.message:t))}},a=t&&setTimeout(()=>{a=null,i(new D(`timeout of ${t}ms exceeded`,D.ETIMEDOUT))},t),o=()=>{e&&=(a&&clearTimeout(a),a=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(i):e.removeEventListener(`abort`,i)}),null)};e.forEach(e=>e.addEventListener(`abort`,i));let{signal:s}=n;return s.unsubscribe=()=>E.asap(o),s}},un=function*(e,t){let n=e.byteLength;if(!t||n<t){yield e;return}let r=0,i;for(;r<n;)i=r+t,yield e.slice(r,i),r=i},dn=async function*(e,t){for await(let n of fn(e))yield*un(n,t)},fn=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}let t=e.getReader();try{for(;;){let{done:e,value:n}=await t.read();if(e)break;yield n}}finally{await t.cancel()}},pn=(e,t,n,r)=>{let i=dn(e,t),a=0,o,s=e=>{o||(o=!0,r&&r(e))};return new ReadableStream({async pull(e){try{let{done:t,value:r}=await i.next();if(t){s(),e.close();return}let o=r.byteLength;n&&n(a+=o),e.enqueue(new Uint8Array(r))}catch(e){throw s(e),e}},cancel(e){return s(e),i.return()}},{highWaterMark:2})},mn=64*1024,{isFunction:hn}=E,gn=(({Request:e,Response:t})=>({Request:e,Response:t}))(E.global),{ReadableStream:_n,TextEncoder:vn}=E.global,yn=(e,...t)=>{try{return!!e(...t)}catch{return!1}},bn=e=>{e=E.merge.call({skipUndefined:!0},gn,e);let{fetch:t,Request:n,Response:r}=e,i=t?hn(t):typeof fetch==`function`,a=hn(n),o=hn(r);if(!i)return!1;let s=i&&hn(_n),c=i&&(typeof vn==`function`?(e=>t=>e.encode(t))(new vn):async e=>new Uint8Array(await new n(e).arrayBuffer())),l=a&&s&&yn(()=>{let e=!1,t=new n(O.origin,{body:new _n,method:`POST`,get duplex(){return e=!0,`half`}}),r=t.headers.has(`Content-Type`);return t.body!=null&&t.body.cancel(),e&&!r}),u=o&&s&&yn(()=>E.isReadableStream(new r(``).body)),d={stream:u&&(e=>e.body)};i&&[`text`,`arrayBuffer`,`blob`,`formData`,`stream`].forEach(e=>{!d[e]&&(d[e]=(t,n)=>{let r=t&&t[e];if(r)return r.call(t);throw new D(`Response type '${e}' is not supported`,D.ERR_NOT_SUPPORT,n)})});let f=async e=>{if(e==null)return 0;if(E.isBlob(e))return e.size;if(E.isSpecCompliantForm(e))return(await new n(O.origin,{method:`POST`,body:e}).arrayBuffer()).byteLength;if(E.isArrayBufferView(e)||E.isArrayBuffer(e))return e.byteLength;if(E.isURLSearchParams(e)&&(e+=``),E.isString(e))return(await c(e)).byteLength},p=async(e,t)=>E.toFiniteNumber(e.getContentLength())??f(t);return async e=>{let{url:i,method:o,data:s,signal:c,cancelToken:f,timeout:m,onDownloadProgress:h,onUploadProgress:g,responseType:_,headers:v,withCredentials:y=`same-origin`,fetchOptions:b}=sn(e),x=t||fetch;_=_?(_+``).toLowerCase():`text`;let S=ln([c,f&&f.toAbortSignal()],m),C=null,w=S&&S.unsubscribe&&(()=>{S.unsubscribe()}),ee;try{if(g&&l&&o!==`get`&&o!==`head`&&(ee=await p(v,s))!==0){let e=new n(i,{method:`POST`,body:s,duplex:`half`}),t;if(E.isFormData(s)&&(t=e.headers.get(`content-type`))&&v.setContentType(t),e.body){let[t,n]=Zt(ee,Xt(Qt(g)));s=pn(e.body,mn,t,n)}}E.isString(y)||(y=y?`include`:`omit`);let t=a&&`credentials`in n.prototype;if(E.isFormData(s)){let e=v.getContentType();e&&/^multipart\/form-data/i.test(e)&&!/boundary=/i.test(e)&&v.delete(`content-type`)}let c={...b,signal:S,method:o.toUpperCase(),headers:v.normalize().toJSON(),body:s,duplex:`half`,credentials:t?y:void 0};C=a&&new n(i,c);let f=await(a?x(C,b):x(i,c)),m=u&&(_===`stream`||_===`response`);if(u&&(h||m&&w)){let e={};[`status`,`statusText`,`headers`].forEach(t=>{e[t]=f[t]});let t=E.toFiniteNumber(f.headers.get(`content-length`)),[n,i]=h&&Zt(t,Xt(Qt(h),!0))||[];f=new r(pn(f.body,mn,n,()=>{i&&i(),w&&w()}),e)}_||=`text`;let te=await d[E.findKey(d,_)||`text`](f,e);return!m&&w&&w(),await new Promise((t,n)=>{Kt(t,n,{data:te,headers:k.from(f.headers),status:f.status,statusText:f.statusText,config:e,request:C})})}catch(t){throw w&&w(),t&&t.name===`TypeError`&&/Load failed|fetch/i.test(t.message)?Object.assign(new D(`Network Error`,D.ERR_NETWORK,e,C,t&&t.response),{cause:t.cause||t}):D.from(t,t&&t.code,e,C,t&&t.response)}}},xn=new Map,Sn=e=>{let t=e&&e.env||{},{fetch:n,Request:r,Response:i}=t,a=[r,i,n],o=a.length,s,c,l=xn;for(;o--;)s=a[o],c=l.get(s),c===void 0&&l.set(s,c=o?new Map:bn(t)),l=c;return c};Sn();let Cn={http:null,xhr:cn,fetch:{get:Sn}};E.forEach(Cn,(e,t)=>{if(e){try{Object.defineProperty(e,`name`,{value:t})}catch{}Object.defineProperty(e,`adapterName`,{value:t})}});let wn=e=>`- ${e}`,Tn=e=>E.isFunction(e)||e===null||e===!1;function En(e,t){e=E.isArray(e)?e:[e];let{length:n}=e,r,i,a={};for(let o=0;o<n;o++){r=e[o];let n;if(i=r,!Tn(r)&&(i=Cn[(n=String(r)).toLowerCase()],i===void 0))throw new D(`Unknown adapter '${n}'`);if(i&&(E.isFunction(i)||(i=i.get(t))))break;a[n||`#`+o]=i}if(!i){let e=Object.entries(a).map(([e,t])=>`adapter ${e} `+(t===!1?`is not supported by the environment`:`is not available in the build`));throw new D(`There is no suitable adapter to dispatch the request `+(n?e.length>1?`since :
4
4
  `+e.map(wn).join(`
5
- `):` `+wn(e[0]):`as no adapter specified`),`ERR_NOT_SUPPORT`)}return i}var Dn={getAdapter:En,adapters:Cn};function On(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Gt(null,e)}function kn(e){return On(e),e.headers=k.from(e.headers),e.data=Ut.call(e,e.transformRequest),[`post`,`put`,`patch`].indexOf(e.method)!==-1&&e.headers.setContentType(`application/x-www-form-urlencoded`,!1),Dn.getAdapter(e.adapter||kt.adapter,e)(e).then(function(t){return On(e),t.data=Ut.call(e,e.transformResponse,t),t.headers=k.from(t.headers),t},function(t){return Wt(t)||(On(e),t&&t.response&&(t.response.data=Ut.call(e,e.transformResponse,t.response),t.response.headers=k.from(t.response.headers))),Promise.reject(t)})}let An=`1.15.1`,jn={};[`object`,`boolean`,`number`,`function`,`string`,`symbol`].forEach((e,t)=>{jn[e]=function(n){return typeof n===e||`a`+(t<1?`n `:` `)+e}});let Mn={};jn.transitional=function(e,t,n){function r(e,t){return`[Axios v`+An+`] Transitional option '`+e+`'`+t+(n?`. `+n:``)}return(n,i,a)=>{if(e===!1)throw new D(r(i,` has been removed`+(t?` in `+t:``)),D.ERR_DEPRECATED);return t&&!Mn[i]&&(Mn[i]=!0,console.warn(r(i,` has been deprecated since v`+t+` and will be removed in the near future`))),e?e(n,i,a):!0}},jn.spelling=function(e){return(t,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};function Nn(e,t,n){if(typeof e!=`object`)throw new D(`options must be an object`,D.ERR_BAD_OPTION_VALUE);let r=Object.keys(e),i=r.length;for(;i-- >0;){let a=r[i],o=t[a];if(o){let t=e[a],n=t===void 0||o(t,a,e);if(n!==!0)throw new D(`option `+a+` must be `+n,D.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new D(`Unknown option `+a,D.ERR_BAD_OPTION)}}var Pn={assertOptions:Nn,validators:jn};let Fn=Pn.validators;var In=class{constructor(e){this.defaults=e||{},this.interceptors={request:new mt,response:new mt}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=Error();let n=(()=>{if(!t.stack)return``;let e=t.stack.indexOf(`
5
+ `):` `+wn(e[0]):`as no adapter specified`),`ERR_NOT_SUPPORT`)}return i}var Dn={getAdapter:En,adapters:Cn};function On(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Gt(null,e)}function kn(e){return On(e),e.headers=k.from(e.headers),e.data=Ut.call(e,e.transformRequest),[`post`,`put`,`patch`].indexOf(e.method)!==-1&&e.headers.setContentType(`application/x-www-form-urlencoded`,!1),Dn.getAdapter(e.adapter||kt.adapter,e)(e).then(function(t){return On(e),t.data=Ut.call(e,e.transformResponse,t),t.headers=k.from(t.headers),t},function(t){return Wt(t)||(On(e),t&&t.response&&(t.response.data=Ut.call(e,e.transformResponse,t.response),t.response.headers=k.from(t.response.headers))),Promise.reject(t)})}let An=`1.15.2`,jn={};[`object`,`boolean`,`number`,`function`,`string`,`symbol`].forEach((e,t)=>{jn[e]=function(n){return typeof n===e||`a`+(t<1?`n `:` `)+e}});let Mn={};jn.transitional=function(e,t,n){function r(e,t){return`[Axios v`+An+`] Transitional option '`+e+`'`+t+(n?`. `+n:``)}return(n,i,a)=>{if(e===!1)throw new D(r(i,` has been removed`+(t?` in `+t:``)),D.ERR_DEPRECATED);return t&&!Mn[i]&&(Mn[i]=!0,console.warn(r(i,` has been deprecated since v`+t+` and will be removed in the near future`))),e?e(n,i,a):!0}},jn.spelling=function(e){return(t,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};function Nn(e,t,n){if(typeof e!=`object`)throw new D(`options must be an object`,D.ERR_BAD_OPTION_VALUE);let r=Object.keys(e),i=r.length;for(;i-- >0;){let a=r[i],o=Object.prototype.hasOwnProperty.call(t,a)?t[a]:void 0;if(o){let t=e[a],n=t===void 0||o(t,a,e);if(n!==!0)throw new D(`option `+a+` must be `+n,D.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new D(`Unknown option `+a,D.ERR_BAD_OPTION)}}var Pn={assertOptions:Nn,validators:jn};let Fn=Pn.validators;var In=class{constructor(e){this.defaults=e||{},this.interceptors={request:new mt,response:new mt}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=Error();let n=(()=>{if(!t.stack)return``;let e=t.stack.indexOf(`
6
6
  `);return e===-1?``:t.stack.slice(e+1)})();try{if(!e.stack)e.stack=n;else if(n){let t=n.indexOf(`
7
7
  `),r=t===-1?-1:n.indexOf(`
8
8
  `,t+1),i=r===-1?``:n.slice(r+1);String(e.stack).endsWith(i)||(e.stack+=`
9
9
  `+n)}}catch{}}throw e}}_request(e,t){typeof e==`string`?(t||={},t.url=e):t=e||{},t=on(this.defaults,t);let{transitional:n,paramsSerializer:r,headers:i}=t;n!==void 0&&Pn.assertOptions(n,{silentJSONParsing:Fn.transitional(Fn.boolean),forcedJSONParsing:Fn.transitional(Fn.boolean),clarifyTimeoutError:Fn.transitional(Fn.boolean),legacyInterceptorReqResOrdering:Fn.transitional(Fn.boolean)},!1),r!=null&&(E.isFunction(r)?t.paramsSerializer={serialize:r}:Pn.assertOptions(r,{encode:Fn.function,serialize:Fn.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls===void 0?t.allowAbsoluteUrls=!0:t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls),Pn.assertOptions(t,{baseUrl:Fn.spelling(`baseURL`),withXsrfToken:Fn.spelling(`withXSRFToken`)},!0),t.method=(t.method||this.defaults.method||`get`).toLowerCase();let a=i&&E.merge(i.common,i[t.method]);i&&E.forEach([`delete`,`get`,`head`,`post`,`put`,`patch`,`common`],e=>{delete i[e]}),t.headers=k.concat(a,i);let o=[],s=!0;this.interceptors.request.forEach(function(e){if(typeof e.runWhen==`function`&&e.runWhen(t)===!1)return;s&&=e.synchronous;let n=t.transitional||ht;n&&n.legacyInterceptorReqResOrdering?o.unshift(e.fulfilled,e.rejected):o.push(e.fulfilled,e.rejected)});let c=[];this.interceptors.response.forEach(function(e){c.push(e.fulfilled,e.rejected)});let l,u=0,d;if(!s){let e=[kn.bind(this),void 0];for(e.unshift(...o),e.push(...c),d=e.length,l=Promise.resolve(t);u<d;)l=l.then(e[u++],e[u++]);return l}d=o.length;let f=t;for(;u<d;){let e=o[u++],t=o[u++];try{f=e(f)}catch(e){t.call(this,e);break}}try{l=kn.call(this,f)}catch(e){return Promise.reject(e)}for(u=0,d=c.length;u<d;)l=l.then(c[u++],c[u++]);return l}getUri(e){return e=on(this.defaults,e),pt(rn(e.baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}};E.forEach([`delete`,`get`,`head`,`options`],function(e){In.prototype[e]=function(t,n){return this.request(on(n||{},{method:e,url:t,data:(n||{}).data}))}}),E.forEach([`post`,`put`,`patch`],function(e){function t(t){return function(n,r,i){return this.request(on(i||{},{method:e,headers:t?{"Content-Type":`multipart/form-data`}:{},url:n,data:r}))}}In.prototype[e]=t(),In.prototype[e+`Form`]=t(!0)});var Ln=class e{constructor(e){if(typeof e!=`function`)throw TypeError(`executor must be a function.`);let t;this.promise=new Promise(function(e){t=e});let n=this;this.promise.then(e=>{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null}),this.promise.then=e=>{let t,r=new Promise(e=>{n.subscribe(e),t=e}).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e(function(e,r,i){n.reason||(n.reason=new Gt(e,r,i),t(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;let t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){let e=new AbortController,t=t=>{e.abort(t)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let t;return{token:new e(function(e){t=e}),cancel:t}}};function Rn(e){return function(t){return e.apply(null,t)}}function zn(e){return E.isObject(e)&&e.isAxiosError===!0}let Bn={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Bn).forEach(([e,t])=>{Bn[t]=e});function Vn(e){let t=new In(e),n=v(In.prototype.request,t);return E.extend(n,In.prototype,t,{allOwnKeys:!0}),E.extend(n,t,null,{allOwnKeys:!0}),n.create=function(t){return Vn(on(e,t))},n}let A=Vn(kt);A.Axios=In,A.CanceledError=Gt,A.CancelToken=Ln,A.isCancel=Wt,A.VERSION=An,A.toFormData=ct,A.AxiosError=D,A.Cancel=A.CanceledError,A.all=function(e){return Promise.all(e)},A.spread=Rn,A.isAxiosError=zn,A.mergeConfig=on,A.AxiosHeaders=k,A.formToJSON=e=>Et(E.isHTMLForm(e)?new FormData(e):e),A.getAdapter=Dn.getAdapter,A.HttpStatusCode=Bn,A.default=A;var Hn=l(_(),1);`https://localhost:9200/graph`.replace(/\/+$/,``);let Un=e=>encodeURIComponent(e).split(`%2F`).join(`/`),Wn=/^(\w+:\/\/[^/?]+)?(.*?)$/,Gn=e=>e.filter(e=>typeof e==`string`||typeof e==`number`).map(e=>`${e}`).filter(e=>e),Kn=e=>{let[,t=``,n=``]=e.join(`/`).match(Wn)||[];return{prefix:t,pathname:{parts:n.split(`/`).filter(e=>e!==``),hasLeading:/^\/+/.test(n),hasTrailing:/\/+$/.test(n)}}},qn=(e,t)=>{let{prefix:n,pathname:r}=e,{parts:i,hasLeading:a,hasTrailing:o}=r,{leadingSlash:s,trailingSlash:c}=t,l=s===!0||s===`keep`&&a,u=c===!0||c===`keep`&&o,d=n;return i.length>0&&((d||l)&&(d+=`/`),d+=i.join(`/`)),u&&(d+=`/`),!d&&l&&(d+=`/`),d},j=(...e)=>{let t=e[e.length-1],n;return t&&typeof t==`object`&&(n=t,e=e.slice(0,-1)),n={leadingSlash:!0,trailingSlash:!1,...n},e=Gn(e),qn(Kn(e),n)};var Jn=class extends Error{response;statusCode;constructor(e,t,n=null){super(e),this.response=t,this.statusCode=n}},Yn=class extends Jn{errorCode;constructor(e,t,n,r=null){super(e,n,r),this.errorCode=t}};function Xn(e,t=``){return`/public-files/${e}/${t}`.split(`/`).filter(Boolean).join(`/`)}function Zn(e,t=``){return`/ocm/${e}/${t}`.split(`/`).filter(Boolean).join(`/`)}var Qn=class{static Shared=`S`;static Shareable=`R`;static Mounted=`M`;static Deletable=`D`;static Renameable=`N`;static Moveable=`V`;static Updateable=`NV`;static FileUpdateable=`W`;static FolderCreateable=`CK`;static Deny=`Z`;static SecureView=`X`};let $n=function(e){return e.copy=`COPY`,e.delete=`DELETE`,e.lock=`LOCK`,e.mkcol=`MKCOL`,e.move=`MOVE`,e.propfind=`PROPFIND`,e.proppatch=`PROPPATCH`,e.put=`PUT`,e.report=`REPORT`,e.unlock=`UNLOCK`,e}({}),er=e=>({value:e,type:null}),tr=e=>er(e),M=e=>er(e),nr=e=>er(e),rr={Permissions:M(`permissions`),IsFavorite:nr(`favorite`),FileId:M(`fileid`),FileParent:M(`file-parent`),Name:M(`name`),OwnerId:M(`owner-id`),OwnerDisplayName:M(`owner-display-name`),PrivateLink:M(`privatelink`),ContentLength:nr(`getcontentlength`),ContentSize:nr(`size`),LastModifiedDate:M(`getlastmodified`),Tags:tr(`tags`),Audio:{value:`audio`,type:null},Location:{value:`location`,type:null},Image:{value:`image`,type:null},Photo:{value:`photo`,type:null},ETag:M(`getetag`),MimeType:M(`getcontenttype`),ResourceType:(e=>er(e))(`resourcetype`),LockDiscovery:{value:`lockdiscovery`,type:null},LockOwner:M(`owner`),LockTime:M(`locktime`),ActiveLock:{value:`activelock`,type:null},DownloadURL:M(`downloadURL`),Highlights:M(`highlights`),MetaPathForUser:M(`meta-path-for-user`),RemoteItemId:M(`remote-item-id`),HasPreview:nr(`has-preview`),ShareId:M(`shareid`),ShareRoot:M(`shareroot`),ShareTypes:{value:`share-types`,type:null},SharePermissions:M(`share-permissions`),TrashbinOriginalFilename:M(`trashbin-original-filename`),TrashbinOriginalLocation:M(`trashbin-original-location`),TrashbinDeletedDate:M(`trashbin-delete-datetime`),PublicLinkItemType:M(`public-link-item-type`),PublicLinkPermission:M(`public-link-permission`),PublicLinkExpiration:M(`public-link-expiration`),PublicLinkShareDate:M(`public-link-share-datetime`),PublicLinkShareOwner:M(`public-link-share-owner`)},N=Object.fromEntries(Object.entries(rr).map(([e,t])=>[e,t.value]));var ir=class e{static Default=[N.Permissions,N.IsFavorite,N.FileId,N.FileParent,N.Name,N.LockDiscovery,N.ActiveLock,N.OwnerId,N.OwnerDisplayName,N.RemoteItemId,N.ShareRoot,N.ShareTypes,N.PrivateLink,N.ContentLength,N.ContentSize,N.LastModifiedDate,N.ETag,N.MimeType,N.ResourceType,N.Tags,N.Audio,N.Location,N.Image,N.Photo,N.HasPreview];static PublicLink=e.Default.concat([N.PublicLinkItemType,N.PublicLinkPermission,N.PublicLinkExpiration,N.PublicLinkShareDate,N.PublicLinkShareOwner]);static Trashbin=[N.ContentLength,N.ResourceType,N.TrashbinOriginalLocation,N.TrashbinOriginalFilename,N.TrashbinDeletedDate,N.Permissions,N.FileParent];static DavNamespace=[N.ContentLength,N.LastModifiedDate,N.ETag,N.MimeType,N.ResourceType,N.LockDiscovery,N.ActiveLock]},ar=typeof global==`object`&&global&&global.Object===Object&&global,or=typeof self==`object`&&self&&self.Object===Object&&self,sr=ar||or||Function(`return this`)(),cr=sr.Symbol,lr=Object.prototype,ur=lr.hasOwnProperty,dr=lr.toString,fr=cr?cr.toStringTag:void 0;function pr(e){var t=ur.call(e,fr),n=e[fr];try{e[fr]=void 0;var r=!0}catch{}var i=dr.call(e);return r&&(t?e[fr]=n:delete e[fr]),i}var mr=Object.prototype.toString;function hr(e){return mr.call(e)}var gr=`[object Null]`,_r=`[object Undefined]`,vr=cr?cr.toStringTag:void 0;function yr(e){return e==null?e===void 0?_r:gr:vr&&vr in Object(e)?pr(e):hr(e)}function br(e){return typeof e==`object`&&!!e}var xr=`[object Symbol]`;function Sr(e){return typeof e==`symbol`||br(e)&&yr(e)==xr}function Cr(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var wr=Array.isArray,Tr=1/0,Er=cr?cr.prototype:void 0,Dr=Er?Er.toString:void 0;function Or(e){if(typeof e==`string`)return e;if(wr(e))return Cr(e,Or)+``;if(Sr(e))return Dr?Dr.call(e):``;var t=e+``;return t==`0`&&1/e==-Tr?`-0`:t}function kr(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}function Ar(e){return e}var jr=`[object AsyncFunction]`,Mr=`[object Function]`,Nr=`[object GeneratorFunction]`,Pr=`[object Proxy]`;function Fr(e){if(!kr(e))return!1;var t=yr(e);return t==Mr||t==Nr||t==jr||t==Pr}var Ir=sr[`__core-js_shared__`],Lr=function(){var e=/[^.]+$/.exec(Ir&&Ir.keys&&Ir.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}();function Rr(e){return!!Lr&&Lr in e}var zr=Function.prototype.toString;function Br(e){if(e!=null){try{return zr.call(e)}catch{}try{return e+``}catch{}}return``}var Vr=/[\\^$.*+?()[\]{}|]/g,Hr=/^\[object .+?Constructor\]$/,Ur=Function.prototype,Wr=Object.prototype,Gr=Ur.toString,Kr=Wr.hasOwnProperty,qr=RegExp(`^`+Gr.call(Kr).replace(Vr,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function Jr(e){return!kr(e)||Rr(e)?!1:(Fr(e)?qr:Hr).test(Br(e))}function Yr(e,t){return e?.[t]}function Xr(e,t){var n=Yr(e,t);return Jr(n)?n:void 0}function Zr(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var Qr=800,$r=16,ei=Date.now;function ti(e){var t=0,n=0;return function(){var r=ei(),i=$r-(r-n);if(n=r,i>0){if(++t>=Qr)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function ni(e){return function(){return e}}var ri=function(){try{var e=Xr(Object,`defineProperty`);return e({},``,{}),e}catch{}}(),ii=ti(ri?function(e,t){return ri(e,`toString`,{configurable:!0,enumerable:!1,value:ni(t),writable:!0})}:Ar);function ai(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}function oi(e){return e!==e}function si(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function ci(e,t,n){return t===t?si(e,t,n):ai(e,oi,n)}function li(e,t){return!!(e!=null&&e.length)&&ci(e,t,0)>-1}function ui(e,t){return e===t||e!==e&&t!==t}var di=Math.max;function fi(e,t,n){return t=di(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,a=di(r.length-t,0),o=Array(a);++i<a;)o[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(o),Zr(e,this,s)}}function pi(e,t){return ii(fi(e,t,Ar),e+``)}var mi=9007199254740991;function hi(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=mi}function gi(e){return e!=null&&hi(e.length)&&!Fr(e)}function _i(e){return function(t){return e(t)}}var vi=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,yi=/^\w*$/;function bi(e,t){if(wr(e))return!1;var n=typeof e;return n==`number`||n==`symbol`||n==`boolean`||e==null||Sr(e)?!0:yi.test(e)||!vi.test(e)||t!=null&&e in Object(t)}var xi=Xr(Object,`create`);function Si(){this.__data__=xi?xi(null):{},this.size=0}function Ci(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}var wi=`__lodash_hash_undefined__`,Ti=Object.prototype.hasOwnProperty;function Ei(e){var t=this.__data__;if(xi){var n=t[e];return n===wi?void 0:n}return Ti.call(t,e)?t[e]:void 0}var Di=Object.prototype.hasOwnProperty;function Oi(e){var t=this.__data__;return xi?t[e]!==void 0:Di.call(t,e)}var ki=`__lodash_hash_undefined__`;function Ai(e,t){var n=this.__data__;return this.size+=+!this.has(e),n[e]=xi&&t===void 0?ki:t,this}function ji(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}ji.prototype.clear=Si,ji.prototype.delete=Ci,ji.prototype.get=Ei,ji.prototype.has=Oi,ji.prototype.set=Ai;function Mi(){this.__data__=[],this.size=0}function Ni(e,t){for(var n=e.length;n--;)if(ui(e[n][0],t))return n;return-1}var Pi=Array.prototype.splice;function Fi(e){var t=this.__data__,n=Ni(t,e);return n<0?!1:(n==t.length-1?t.pop():Pi.call(t,n,1),--this.size,!0)}function Ii(e){var t=this.__data__,n=Ni(t,e);return n<0?void 0:t[n][1]}function Li(e){return Ni(this.__data__,e)>-1}function Ri(e,t){var n=this.__data__,r=Ni(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function zi(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}zi.prototype.clear=Mi,zi.prototype.delete=Fi,zi.prototype.get=Ii,zi.prototype.has=Li,zi.prototype.set=Ri;var Bi=Xr(sr,`Map`);function Vi(){this.size=0,this.__data__={hash:new ji,map:new(Bi||zi),string:new ji}}function Hi(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}function Ui(e,t){var n=e.__data__;return Hi(t)?n[typeof t==`string`?`string`:`hash`]:n.map}function Wi(e){var t=Ui(this,e).delete(e);return this.size-=+!!t,t}function Gi(e){return Ui(this,e).get(e)}function Ki(e){return Ui(this,e).has(e)}function qi(e,t){var n=Ui(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function Ji(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Ji.prototype.clear=Vi,Ji.prototype.delete=Wi,Ji.prototype.get=Gi,Ji.prototype.has=Ki,Ji.prototype.set=qi;var Yi=`Expected a function`;function Xi(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(Yi);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(Xi.Cache||Ji),n}Xi.Cache=Ji;var Zi=500;function Qi(e){var t=Xi(e,function(e){return n.size===Zi&&n.clear(),e}),n=t.cache;return t}var $i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ea=/\\(\\)?/g,ta=Qi(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace($i,function(e,n,r,i){t.push(r?i.replace(ea,`$1`):n||e)}),t});function na(e){return e==null?``:Or(e)}function ra(e,t){return wr(e)?e:bi(e,t)?[e]:ta(na(e))}var ia=1/0;function aa(e){if(typeof e==`string`||Sr(e))return e;var t=e+``;return t==`0`&&1/e==-ia?`-0`:t}function oa(e,t){t=ra(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[aa(t[n++])];return n&&n==r?e:void 0}function sa(e,t,n){var r=e==null?void 0:oa(e,t);return r===void 0?n:r}function ca(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++r<i;)a[r]=e[r+t];return a}function la(e,t,n){var r=e.length;return n=n===void 0?r:n,!t&&n>=r?e:ca(e,t,n)}var ua=RegExp(`[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]`);function da(e){return ua.test(e)}function fa(e){return e.split(``)}var pa=`\\ud800-\\udfff`,ma=`\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff`,ha=`\\ufe0e\\ufe0f`,ga=`[`+pa+`]`,_a=`[`+ma+`]`,va=`\\ud83c[\\udffb-\\udfff]`,ya=`(?:`+_a+`|`+va+`)`,ba=`[^`+pa+`]`,xa=`(?:\\ud83c[\\udde6-\\uddff]){2}`,Sa=`[\\ud800-\\udbff][\\udc00-\\udfff]`,Ca=`\\u200d`,wa=ya+`?`,Ta=`[`+ha+`]?`,Ea=`(?:`+Ca+`(?:`+[ba,xa,Sa].join(`|`)+`)`+Ta+wa+`)*`,Da=Ta+wa+Ea,Oa=`(?:`+[ba+_a+`?`,_a,xa,Sa,ga].join(`|`)+`)`,ka=RegExp(va+`(?=`+va+`)|`+Oa+Da,`g`);function Aa(e){return e.match(ka)||[]}function ja(e){return da(e)?Aa(e):fa(e)}function Ma(e){return function(t){t=na(t);var n=da(t)?ja(t):void 0,r=n?n[0]:t.charAt(0),i=n?la(n,1).join(``):t.slice(1);return r[e]()+i}}var Na=Ma(`toUpperCase`);function Pa(e){return Na(na(e).toLowerCase())}function Fa(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}function Ia(e){return function(t){return e?.[t]}}var La=Ia({À:`A`,Á:`A`,Â:`A`,Ã:`A`,Ä:`A`,Å:`A`,à:`a`,á:`a`,â:`a`,ã:`a`,ä:`a`,å:`a`,Ç:`C`,ç:`c`,Ð:`D`,ð:`d`,È:`E`,É:`E`,Ê:`E`,Ë:`E`,è:`e`,é:`e`,ê:`e`,ë:`e`,Ì:`I`,Í:`I`,Î:`I`,Ï:`I`,ì:`i`,í:`i`,î:`i`,ï:`i`,Ñ:`N`,ñ:`n`,Ò:`O`,Ó:`O`,Ô:`O`,Õ:`O`,Ö:`O`,Ø:`O`,ò:`o`,ó:`o`,ô:`o`,õ:`o`,ö:`o`,ø:`o`,Ù:`U`,Ú:`U`,Û:`U`,Ü:`U`,ù:`u`,ú:`u`,û:`u`,ü:`u`,Ý:`Y`,ý:`y`,ÿ:`y`,Æ:`Ae`,æ:`ae`,Þ:`Th`,þ:`th`,ß:`ss`,Ā:`A`,Ă:`A`,Ą:`A`,ā:`a`,ă:`a`,ą:`a`,Ć:`C`,Ĉ:`C`,Ċ:`C`,Č:`C`,ć:`c`,ĉ:`c`,ċ:`c`,č:`c`,Ď:`D`,Đ:`D`,ď:`d`,đ:`d`,Ē:`E`,Ĕ:`E`,Ė:`E`,Ę:`E`,Ě:`E`,ē:`e`,ĕ:`e`,ė:`e`,ę:`e`,ě:`e`,Ĝ:`G`,Ğ:`G`,Ġ:`G`,Ģ:`G`,ĝ:`g`,ğ:`g`,ġ:`g`,ģ:`g`,Ĥ:`H`,Ħ:`H`,ĥ:`h`,ħ:`h`,Ĩ:`I`,Ī:`I`,Ĭ:`I`,Į:`I`,İ:`I`,ĩ:`i`,ī:`i`,ĭ:`i`,į:`i`,ı:`i`,Ĵ:`J`,ĵ:`j`,Ķ:`K`,ķ:`k`,ĸ:`k`,Ĺ:`L`,Ļ:`L`,Ľ:`L`,Ŀ:`L`,Ł:`L`,ĺ:`l`,ļ:`l`,ľ:`l`,ŀ:`l`,ł:`l`,Ń:`N`,Ņ:`N`,Ň:`N`,Ŋ:`N`,ń:`n`,ņ:`n`,ň:`n`,ŋ:`n`,Ō:`O`,Ŏ:`O`,Ő:`O`,ō:`o`,ŏ:`o`,ő:`o`,Ŕ:`R`,Ŗ:`R`,Ř:`R`,ŕ:`r`,ŗ:`r`,ř:`r`,Ś:`S`,Ŝ:`S`,Ş:`S`,Š:`S`,ś:`s`,ŝ:`s`,ş:`s`,š:`s`,Ţ:`T`,Ť:`T`,Ŧ:`T`,ţ:`t`,ť:`t`,ŧ:`t`,Ũ:`U`,Ū:`U`,Ŭ:`U`,Ů:`U`,Ű:`U`,Ų:`U`,ũ:`u`,ū:`u`,ŭ:`u`,ů:`u`,ű:`u`,ų:`u`,Ŵ:`W`,ŵ:`w`,Ŷ:`Y`,ŷ:`y`,Ÿ:`Y`,Ź:`Z`,Ż:`Z`,Ž:`Z`,ź:`z`,ż:`z`,ž:`z`,IJ:`IJ`,ij:`ij`,Œ:`Oe`,œ:`oe`,ʼn:`'n`,ſ:`s`}),Ra=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,za=RegExp(`[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]`,`g`);function Ba(e){return e=na(e),e&&e.replace(Ra,La).replace(za,``)}var Va=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function Ha(e){return e.match(Va)||[]}var Ua=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function Wa(e){return Ua.test(e)}var Ga=`\\ud800-\\udfff`,Ka=`\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff`,qa=`\\u2700-\\u27bf`,Ja=`a-z\\xdf-\\xf6\\xf8-\\xff`,Ya=`\\xac\\xb1\\xd7\\xf7`,Xa=`\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf`,Za=`\\u2000-\\u206f`,Qa=` \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000`,$a=`A-Z\\xc0-\\xd6\\xd8-\\xde`,eo=`\\ufe0e\\ufe0f`,to=Ya+Xa+Za+Qa,no=`['’]`,ro=`[`+to+`]`,io=`[`+Ka+`]`,ao=`\\d+`,oo=`[`+qa+`]`,so=`[`+Ja+`]`,co=`[^`+Ga+to+ao+qa+Ja+$a+`]`,lo=`(?:`+io+`|\\ud83c[\\udffb-\\udfff])`,uo=`[^`+Ga+`]`,fo=`(?:\\ud83c[\\udde6-\\uddff]){2}`,po=`[\\ud800-\\udbff][\\udc00-\\udfff]`,mo=`[`+$a+`]`,ho=`\\u200d`,go=`(?:`+so+`|`+co+`)`,_o=`(?:`+mo+`|`+co+`)`,vo=`(?:`+no+`(?:d|ll|m|re|s|t|ve))?`,yo=`(?:`+no+`(?:D|LL|M|RE|S|T|VE))?`,bo=lo+`?`,xo=`[`+eo+`]?`,So=`(?:`+ho+`(?:`+[uo,fo,po].join(`|`)+`)`+xo+bo+`)*`,Co=`\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])`,wo=`\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])`,To=xo+bo+So,Eo=`(?:`+[oo,fo,po].join(`|`)+`)`+To,Do=RegExp([mo+`?`+so+`+`+vo+`(?=`+[ro,mo,`$`].join(`|`)+`)`,_o+`+`+yo+`(?=`+[ro,mo+go,`$`].join(`|`)+`)`,mo+`?`+go+`+`+vo,mo+`+`+yo,wo,Co,ao,Eo].join(`|`),`g`);function Oo(e){return e.match(Do)||[]}function ko(e,t,n){return e=na(e),t=n?void 0:t,t===void 0?Wa(e)?Oo(e):Ha(e):e.match(t)||[]}var Ao=RegExp(`['’]`,`g`);function jo(e){return function(t){return Fa(ko(Ba(t).replace(Ao,``)),e,``)}}var Mo=jo(function(e,t,n){return t=t.toLowerCase(),e+(n?Pa(t):t)}),No=`__lodash_hash_undefined__`;function Po(e){return this.__data__.set(e,No),this}function Fo(e){return this.__data__.has(e)}function Io(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new Ji;++t<n;)this.add(e[t])}Io.prototype.add=Io.prototype.push=Po,Io.prototype.has=Fo;function Lo(e,t){return e.has(t)}function Ro(e){return br(e)&&gi(e)}function zo(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}var Bo=Math.min;function Vo(e,t,n){for(var r=n?zo:li,i=e[0].length,a=e.length,o=a,s=Array(a),c=1/0,l=[];o--;){var u=e[o];o&&t&&(u=Cr(u,_i(t))),c=Bo(u.length,c),s[o]=!n&&(t||i>=120&&u.length>=120)?new Io(o&&u):void 0}u=e[0];var d=-1,f=s[0];outer:for(;++d<i&&l.length<c;){var p=u[d],m=t?t(p):p;if(p=n||p!==0?p:0,!(f?Lo(f,m):r(l,m,n))){for(o=a;--o;){var h=s[o];if(!(h?Lo(h,m):r(e[o],m,n)))continue outer}f&&f.push(m),l.push(p)}}return l}function Ho(e){return Ro(e)?e:[]}var Uo=pi(function(e){var t=Cr(e,Ho);return t.length&&t[0]===e[0]?Vo(t):[]});let Wo={complex:[`tar.bz2`,`tar.gz`,`tar.xz`]},Go=e=>e.replace(/[^A-Za-z0-9\-_]/g,``),Ko=(e,t)=>!e||typeof e!=`string`?``:e.indexOf(`!`)>=0?e.split(`!`)[t]:``,qo=e=>Ko(e,0),Jo=e=>Ko(e,1),Yo=e=>{let t=e.name.split(`.`);if(t.length>2)for(let e=0;e<t.length;e++){let n=t.slice(e,t.length).join(`.`);if(Wo.complex.includes(n))return n}return t.length<2?``:t[t.length-1]},Xo=e=>{if(!e)return e;let t={};return Object.keys(e).forEach(n=>{t[Mo(n)]=e[n]}),t};function Zo(e,t=[]){let n=e.props[N.Name]?.toString()||(0,Hn.basename)(e.filename),r=e.props[N.FileId],i=e.type===`directory`,a;a=e.filename.startsWith(`/files`)||e.filename.startsWith(`/space`)?e.filename.split(`/`).slice(3).join(`/`):e.filename,a.startsWith(`/`)||(a=`/${a}`);let o=Yo({...e,id:r,name:n,path:a}),s=e.props[N.LockDiscovery],c,l,u;s&&(c=s[N.ActiveLock],l=c[N.LockOwner],u=c[N.LockTime]);let d=[];e.props[N.ShareTypes]&&(d=e.props[N.ShareTypes][`share-type`],Array.isArray(d)||(d=[d]));let f={};for(let n of t||[]){let t=n.split(`:`).pop();e.props[t]&&(f[n]=e.props[t])}let p={id:r,fileId:r,storageId:qo(r),parentFolderId:e.props[N.FileParent],mimeType:e.props[N.MimeType],name:n,extension:o,path:a,webDavPath:e.filename,type:i?`folder`:e.type,isFolder:i,locked:!!c,lockOwner:l,lockTime:u,processing:e.processing||!1,mdate:e.props[N.LastModifiedDate],size:i?e.props[N.ContentSize]?.toString()||`0`:e.props[N.ContentLength]?.toString()||`0`,permissions:e.props[N.Permissions]||``,starred:e.props[N.IsFavorite]===1,etag:e.props[N.ETag],shareTypes:d,privateLink:e.props[N.PrivateLink],downloadURL:e.props[N.DownloadURL],remoteItemId:e.props[N.RemoteItemId],remoteItemPath:e.props[N.ShareRoot],owner:{id:e.props[N.OwnerId],displayName:e.props[N.OwnerDisplayName]},tags:(e.props[N.Tags]||``).toString().split(`,`).filter(Boolean),audio:Xo(e.props[N.Audio]),location:Xo(e.props[N.Location]),image:Xo(e.props[N.Image]),photo:Xo(e.props[N.Photo]),extraProps:f,hasPreview:()=>e.props[N.HasPreview]===1,canUpload:function(){return this.permissions.indexOf(Qn.FolderCreateable)>=0},canDownload:function(){return this.permissions.indexOf(Qn.SecureView)===-1},canBeDeleted:function(){return this.permissions.indexOf(Qn.Deletable)>=0},canRename:function(){return this.permissions.indexOf(Qn.Renameable)>=0},canShare:function({ability:e}){return e.can(`create-all`,`Share`)&&this.permissions.indexOf(Qn.Shareable)>=0},canCreate:function(){return this.permissions.indexOf(Qn.FolderCreateable)>=0},canEditTags:function(){return this.permissions.indexOf(Qn.Updateable)>=0||this.permissions.indexOf(Qn.FileUpdateable)>=0||this.permissions.indexOf(Qn.FolderCreateable)>=0},isMounted:function(){return this.permissions.indexOf(Qn.Mounted)>=0},isReceivedShare:function(){return this.permissions.indexOf(Qn.Shared)>=0},isShareRoot(){return e.props[N.ShareRoot]?e.filename.split(`/`).length===3:!1},getDomSelector:()=>Go(r)};return Object.defineProperty(p,`nodeId`,{get(){return Jo(this.id)}}),p}function Qo(e){let t=e.type===`directory`,n=e.props[N.TrashbinOriginalFilename]?.toString(),r=Yo({name:n,type:e.type}),i=Hn.default.basename(e.filename);return{type:t?`folder`:e.type,isFolder:t,ddate:e.props[N.TrashbinDeletedDate],name:Hn.default.basename(n),extension:r,path:j(e.props[N.TrashbinOriginalLocation],{leadingSlash:!0}),id:i,parentFolderId:e.props[N.FileParent],webDavPath:``,canUpload:()=>!1,canDownload:()=>!1,canBeDeleted:()=>!0,canBeRestored:function(){return!0},canRename:()=>!1,canShare:()=>!1,canCreate:()=>!1,isMounted:()=>!1,isReceivedShare:()=>!1,hasPreview:()=>!1,isShareRoot:()=>!1,getDomSelector:()=>Go(i)}}let P=function(e){return e.createUpload=`libre.graph/driveItem/upload/create`,e.createPermissions=`libre.graph/driveItem/permissions/create`,e.createChildren=`libre.graph/driveItem/children/create`,e.readBasic=`libre.graph/driveItem/basic/read`,e.readPath=`libre.graph/driveItem/path/read`,e.readQuota=`libre.graph/driveItem/quota/read`,e.readContent=`libre.graph/driveItem/content/read`,e.readChildren=`libre.graph/driveItem/children/read`,e.readDeleted=`libre.graph/driveItem/deleted/read`,e.readPermissions=`libre.graph/driveItem/permissions/read`,e.readVersions=`libre.graph/driveItem/versions/read`,e.updatePath=`libre.graph/driveItem/path/update`,e.updateDeleted=`libre.graph/driveItem/deleted/update`,e.updatePermissions=`libre.graph/driveItem/permissions/update`,e.updateVersions=`libre.graph/driveItem/versions/update`,e.deleteStandard=`libre.graph/driveItem/standard/delete`,e.deleteDeleted=`libre.graph/driveItem/deleted/delete`,e.deletePermissions=`libre.graph/driveItem/permissions/delete`,e}({}),$o=e=>e;var es=class{_key;_value;_label;_icon;constructor(e,t,n,r){this._key=e,this._value=t,this._label=n,this._icon=r}get key(){return this._key}get value(){return this._value}get label(){return this._label}get icon(){return this._icon}};(class{static user=new es(`user`,0,$o(`User`),`user`);static group=new es(`group`,1,$o(`Group`),`group`);static link=new es(`link`,3,$o(`Link`),`link`);static guest=new es(`guest`,4,$o(`Guest`),`global`);static remote=new es(`remote`,6,$o(`External`),`earth`);static individuals=[this.user,this.guest,this.remote];static collectives=[this.group];static unauthenticated=[this.link];static authenticated=[this.user,this.group,this.guest,this.remote];static all=[this.user,this.group,this.link,this.guest,this.remote];static isIndividual(e){return this.individuals.includes(e)}static isCollective(e){return this.collectives.includes(e)}static isUnauthenticated(e){return this.unauthenticated.includes(e)}static isAuthenticated(e){return this.authenticated.includes(e)}static getByValue(e){return this.all.find(t=>t.value===e)}static getByValues(e){return e.map(e=>this.getByValue(e))}static getByKeys(e){return e.map(e=>this.all.find(t=>t.key===e))}static getValues(e){return e.map(e=>e.value)}static containsAnyValue(e,t){return Uo(this.getValues(e),t).length>0}});let ts=e=>e?.driveType===`personal`,ns=e=>e?.driveType===`public`;function rs(e,t){return j(`spaces`,e,t,{leadingSlash:!0})}function is(e,t=``){return j(`spaces`,`trash-bin`,e,t,{leadingSlash:!0})}function as(e){let t=e.publicLinkPassword,n=e.props?.[N.FileId],r=e.props?.[N.PublicLinkItemType],i=e.props?.[N.PublicLinkPermission],a=e.props?.[N.PublicLinkExpiration],o=e.props?.[N.PublicLinkShareDate],s=e.props?.[N.PublicLinkShareOwner],c=e.publicLinkType,l,u;return c===`ocm`?(l=`ocm/${e.id}`,u=Zn(e.id)):(l=`public/${e.id}`,u=Xn(e.id)),Object.assign(os({...e,driveType:`public`,driveAlias:l,webDavPath:u}),{...n&&{fileId:n},...t&&{publicLinkPassword:t},...r&&{publicLinkItemType:r},...i&&{publicLinkPermission:parseInt(i)},...a&&{publicLinkExpiration:a},...o&&{publicLinkShareDate:o},...s&&{publicLinkShareOwner:s},publicLinkType:c})}function os(e){let t,n;e.special&&(t=e.special.find(e=>e.specialFolder.name===`image`),n=e.special.find(e=>e.specialFolder.name===`readme`),t&&(t.webDavUrl=decodeURI(t.webDavUrl)),n&&(n.webDavUrl=decodeURI(n.webDavUrl)));let r=e.root?.deleted?.state===`trashed`,i=j(e.webDavPath||rs(e.id),{leadingSlash:!0}),a=j(e.serverUrl,`remote.php/dav`,i),o=j(e.webDavTrashPath||is(e.id),{leadingSlash:!0}),s=j(e.serverUrl,`remote.php/dav`,o),c={id:e.id,fileId:e.id,storageId:e.id,mimeType:``,name:e.name,description:e.description,extension:``,path:`/`,webDavPath:i,webDavTrashPath:o,driveAlias:e.driveAlias,driveType:e.driveType,type:`space`,isFolder:!0,mdate:e.lastModifiedDateTime,size:e.quota?.used||0,tags:[],permissions:``,starred:!1,etag:``,shareTypes:[],privateLink:e.webUrl,downloadURL:``,owner:e.owner?.user,disabled:r,root:e.root,spaceQuota:e.quota,spaceImageData:t,spaceReadmeData:n,hasTrashedItems:e[`@libre.graph.hasTrashedItems`]||!1,graphPermissions:void 0,canUpload:function({user:e}={}){return ts(this)&&this.isOwner(e)?!0:this.graphPermissions?.includes(P.createUpload)},canDownload:function(){return!0},canBeDeleted:function({ability:e}={}){return this.disabled?e?.can(`delete-all`,`Drive`)?!0:this.graphPermissions?.includes(P.deletePermissions):!1},canRename:function({ability:e}={}){return e?.can(`update-all`,`Drive`)?!0:this.graphPermissions?.includes(P.deletePermissions)},canEditDescription:function({ability:e}={}){return e?.can(`update-all`,`Drive`)?!0:this.graphPermissions?.includes(P.deletePermissions)},canRestore:function({ability:e}={}){return this.disabled?e?.can(`update-all`,`Drive`)?!0:this.graphPermissions?.includes(P.deletePermissions):!1},canDisable:function({ability:e}={}){return this.disabled?!1:e?.can(`delete-all`,`Drive`)?!0:this.graphPermissions?.includes(P.deletePermissions)},canShare:function(){return this.graphPermissions?.includes(P.createPermissions)},canEditImage:function(){return this.disabled?!1:this.graphPermissions?.includes(P.deletePermissions)},canEditReadme:function(){return this.disabled?!1:this.graphPermissions?.includes(P.deletePermissions)},canRestoreFromTrashbin:function(){return this.graphPermissions?.includes(P.updateDeleted)},canDeleteFromTrashBin:function({user:e}={}){return ts(this)&&this.isOwner(e)?!0:this.graphPermissions?.includes(P.deletePermissions)},canListVersions:function({user:e}={}){return ts(this)&&this.isOwner(e)?!0:this.graphPermissions?.includes(P.readVersions)},canCreate:function(){return!0},canEditTags:function(){return!1},isMounted:function(){return!0},isReceivedShare:function(){return!1},isShareRoot:function(){return[`share`,`mountpoint`,`public`].includes(e.driveType)},getDomSelector:()=>Go(e.id),getDriveAliasAndItem({path:e}){return j(this.driveAlias,e,{leadingSlash:!1})},getWebDavUrl({path:e}){return j(a,e)},getWebDavTrashUrl({path:e}){return j(s,e)},isOwner(e){return e?.id===this.owner?.id}};return Object.defineProperty(c,`nodeId`,{get(){return Jo(this.id)}}),c}let ss=(e,t)=>{let n=new URL(e);n.pathname=[...n.pathname.split(`/`),`cloud`,`capabilities`].filter(Boolean).join(`/`),n.searchParams.append(`format`,`json`);let r=n.href;return{async getCapabilities(){return sa(await t.get(r),`data.ocs.data`,{capabilities:null,version:null})}}};function cs(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name===`Uint8Array`&&`BYTES_PER_ELEMENT`in e&&e.BYTES_PER_ELEMENT===1}function ls(e,t=``){if(typeof e!=`number`){let n=t&&`"${t}" `;throw TypeError(`${n}expected number, got ${typeof e}`)}if(!Number.isSafeInteger(e)||e<0){let n=t&&`"${t}" `;throw RangeError(`${n}expected integer >= 0, got ${e}`)}}function us(e,t,n=``){let r=cs(e),i=e?.length,a=t!==void 0;if(!r||a&&i!==t){let o=n&&`"${n}" `,s=a?` of length ${t}`:``,c=r?`length=${i}`:`type=${typeof e}`,l=o+`expected Uint8Array`+s+`, got `+c;throw r?RangeError(l):TypeError(l)}return e}function ds(e){if(typeof e!=`function`||typeof e.create!=`function`)throw TypeError(`Hash must wrapped by utils.createHasher`);if(ls(e.outputLen),ls(e.blockLen),e.outputLen<1)throw Error(`"outputLen" must be >= 1`);if(e.blockLen<1)throw Error(`"blockLen" must be >= 1`)}function fs(e,t=!0){if(e.destroyed)throw Error(`Hash instance has been destroyed`);if(t&&e.finished)throw Error(`Hash#digest() has already been called`)}function ps(e,t){us(e,void 0,`digestInto() output`);let n=t.outputLen;if(e.length<n)throw RangeError(`"digestInto() output" expected to be of length >=`+n)}function ms(...e){for(let t=0;t<e.length;t++)e[t].fill(0)}function hs(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}new Uint8Array(new Uint32Array([287454020]).buffer)[0],typeof Uint8Array.from([]).toHex==`function`&&Uint8Array.fromHex;function gs(e){if(typeof e!=`string`)throw TypeError(`string expected`);return new Uint8Array(new TextEncoder().encode(e))}function _s(e,t=``){return typeof e==`string`?gs(e):us(e,void 0,t)}function vs(e,t){if(t!==void 0&&{}.toString.call(t)!==`[object Object]`)throw TypeError(`options must be object or undefined`);return Object.assign(e,t)}function ys(e,t={}){let n=(t,n)=>e(n).update(t).digest(),r=e(void 0);return n.outputLen=r.outputLen,n.blockLen=r.blockLen,n.canXOF=r.canXOF,n.create=t=>e(t),Object.assign(n,t),Object.freeze(n)}let bs=e=>({oid:Uint8Array.from([6,9,96,134,72,1,101,3,4,2,e])});var xs=class{oHash;iHash;blockLen;outputLen;canXOF=!1;finished=!1;destroyed=!1;constructor(e,t){if(ds(e),us(t,void 0,`key`),this.iHash=e.create(),typeof this.iHash.update!=`function`)throw Error(`Expected instance of class which extends utils.Hash`);this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;let n=this.blockLen,r=new Uint8Array(n);r.set(t.length>n?e.create().update(t).digest():t);for(let e=0;e<r.length;e++)r[e]^=54;this.iHash.update(r),this.oHash=e.create();for(let e=0;e<r.length;e++)r[e]^=106;this.oHash.update(r),ms(r)}update(e){return fs(this),this.iHash.update(e),this}digestInto(e){fs(this),ps(e,this),this.finished=!0;let t=e.subarray(0,this.outputLen);this.iHash.digestInto(t),this.oHash.update(t),this.oHash.digestInto(t),this.destroy()}digest(){let e=new Uint8Array(this.oHash.outputLen);return this.digestInto(e),e}_cloneInto(e){e||=Object.create(Object.getPrototypeOf(this),{});let{oHash:t,iHash:n,finished:r,destroyed:i,blockLen:a,outputLen:o}=this;return e=e,e.finished=r,e.destroyed=i,e.blockLen=a,e.outputLen=o,e.oHash=t._cloneInto(e.oHash),e.iHash=n._cloneInto(e.iHash),e}clone(){return this._cloneInto()}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}};let Ss=(()=>{let e=((e,t,n)=>new xs(e,t).update(n).digest());return e.create=(e,t)=>new xs(e,t),e})();function Cs(e,t,n,r){ds(e);let{c:i,dkLen:a,asyncTick:o}=vs({dkLen:32,asyncTick:10},r);if(ls(i,`c`),ls(a,`dkLen`),ls(o,`asyncTick`),i<1)throw Error(`iterations (c) must be >= 1`);if(a<1)throw Error(`"dkLen" must be >= 1`);if(a>(2**32-1)*e.outputLen)throw Error(`derived key too long`);let s=_s(t,`password`),c=_s(n,`salt`),l=new Uint8Array(a),u=Ss.create(e,s);return{c:i,dkLen:a,asyncTick:o,DK:l,PRF:u,PRFSalt:u._cloneInto().update(c)}}function ws(e,t,n,r,i){return e.destroy(),t.destroy(),r&&r.destroy(),ms(i),n}function Ts(e,t,n,r){let{c:i,dkLen:a,DK:o,PRF:s,PRFSalt:c}=Cs(e,t,n,r),l,u=new Uint8Array(4),d=hs(u),f=new Uint8Array(s.outputLen);for(let e=1,t=0;t<a;e++,t+=s.outputLen){let n=o.subarray(t,t+s.outputLen);d.setInt32(0,e,!1),(l=c._cloneInto(l)).update(u).digestInto(f),n.set(f.subarray(0,n.length));for(let e=1;e<i;e++){s._cloneInto(l).update(f).digestInto(f);for(let e=0;e<n.length;e++)n[e]^=f[e]}}return ws(s,c,o,l,f)}var Es=class{blockLen;outputLen;canXOF=!1;padOffset;isLE;buffer;view;finished=!1;length=0;pos=0;destroyed=!1;constructor(e,t,n,r){this.blockLen=e,this.outputLen=t,this.padOffset=n,this.isLE=r,this.buffer=new Uint8Array(e),this.view=hs(this.buffer)}update(e){fs(this),us(e);let{view:t,buffer:n,blockLen:r}=this,i=e.length;for(let a=0;a<i;){let o=Math.min(r-this.pos,i-a);if(o===r){let t=hs(e);for(;r<=i-a;a+=r)this.process(t,a);continue}n.set(e.subarray(a,a+o),this.pos),this.pos+=o,a+=o,this.pos===r&&(this.process(t,0),this.pos=0)}return this.length+=e.length,this.roundClean(),this}digestInto(e){fs(this),ps(e,this),this.finished=!0;let{buffer:t,view:n,blockLen:r,isLE:i}=this,{pos:a}=this;t[a++]=128,ms(this.buffer.subarray(a)),this.padOffset>r-a&&(this.process(n,0),a=0);for(let e=a;e<r;e++)t[e]=0;n.setBigUint64(r-8,BigInt(this.length*8),i),this.process(n,0);let o=hs(e),s=this.outputLen;if(s%4)throw Error(`_sha2: outputLen must be aligned to 32bit`);let c=s/4,l=this.get();if(c>l.length)throw Error(`_sha2: outputLen bigger than state`);for(let e=0;e<c;e++)o.setUint32(4*e,l[e],i)}digest(){let{buffer:e,outputLen:t}=this;this.digestInto(e);let n=e.slice(0,t);return this.destroy(),n}_cloneInto(e){e||=new this.constructor,e.set(...this.get());let{blockLen:t,buffer:n,length:r,finished:i,destroyed:a,pos:o}=this;return e.destroyed=a,e.finished=i,e.length=r,e.pos=o,r%t&&e.buffer.set(n),e}clone(){return this._cloneInto()}};let F=Uint32Array.from([1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209]),Ds=BigInt(2**32-1),Os=BigInt(32);function ks(e,t=!1){return t?{h:Number(e&Ds),l:Number(e>>Os&Ds)}:{h:Number(e>>Os&Ds)|0,l:Number(e&Ds)|0}}function As(e,t=!1){let n=e.length,r=new Uint32Array(n),i=new Uint32Array(n);for(let a=0;a<n;a++){let{h:n,l:o}=ks(e[a],t);[r[a],i[a]]=[n,o]}return[r,i]}let js=(e,t,n)=>e>>>n,Ms=(e,t,n)=>e<<32-n|t>>>n,Ns=(e,t,n)=>e>>>n|t<<32-n,Ps=(e,t,n)=>e<<32-n|t>>>n,Fs=(e,t,n)=>e<<64-n|t>>>n-32,Is=(e,t,n)=>e>>>n-32|t<<64-n;function Ls(e,t,n,r){let i=(t>>>0)+(r>>>0);return{h:e+n+(i/2**32|0)|0,l:i|0}}let Rs=(e,t,n)=>(e>>>0)+(t>>>0)+(n>>>0),zs=(e,t,n,r)=>t+n+r+(e/2**32|0)|0,Bs=(e,t,n,r)=>(e>>>0)+(t>>>0)+(n>>>0)+(r>>>0),Vs=(e,t,n,r,i)=>t+n+r+i+(e/2**32|0)|0,Hs=(e,t,n,r,i)=>(e>>>0)+(t>>>0)+(n>>>0)+(r>>>0)+(i>>>0),Us=(e,t,n,r,i,a)=>t+n+r+i+a+(e/2**32|0)|0,Ws=As(`0x428a2f98d728ae22.0x7137449123ef65cd.0xb5c0fbcfec4d3b2f.0xe9b5dba58189dbbc.0x3956c25bf348b538.0x59f111f1b605d019.0x923f82a4af194f9b.0xab1c5ed5da6d8118.0xd807aa98a3030242.0x12835b0145706fbe.0x243185be4ee4b28c.0x550c7dc3d5ffb4e2.0x72be5d74f27b896f.0x80deb1fe3b1696b1.0x9bdc06a725c71235.0xc19bf174cf692694.0xe49b69c19ef14ad2.0xefbe4786384f25e3.0x0fc19dc68b8cd5b5.0x240ca1cc77ac9c65.0x2de92c6f592b0275.0x4a7484aa6ea6e483.0x5cb0a9dcbd41fbd4.0x76f988da831153b5.0x983e5152ee66dfab.0xa831c66d2db43210.0xb00327c898fb213f.0xbf597fc7beef0ee4.0xc6e00bf33da88fc2.0xd5a79147930aa725.0x06ca6351e003826f.0x142929670a0e6e70.0x27b70a8546d22ffc.0x2e1b21385c26c926.0x4d2c6dfc5ac42aed.0x53380d139d95b3df.0x650a73548baf63de.0x766a0abb3c77b2a8.0x81c2c92e47edaee6.0x92722c851482353b.0xa2bfe8a14cf10364.0xa81a664bbc423001.0xc24b8b70d0f89791.0xc76c51a30654be30.0xd192e819d6ef5218.0xd69906245565a910.0xf40e35855771202a.0x106aa07032bbd1b8.0x19a4c116b8d2d0c8.0x1e376c085141ab53.0x2748774cdf8eeb99.0x34b0bcb5e19b48a8.0x391c0cb3c5c95a63.0x4ed8aa4ae3418acb.0x5b9cca4f7763e373.0x682e6ff3d6b2b8a3.0x748f82ee5defb2fc.0x78a5636f43172f60.0x84c87814a1f0ab72.0x8cc702081a6439ec.0x90befffa23631e28.0xa4506cebde82bde9.0xbef9a3f7b2c67915.0xc67178f2e372532b.0xca273eceea26619c.0xd186b8c721c0c207.0xeada7dd6cde0eb1e.0xf57d4f7fee6ed178.0x06f067aa72176fba.0x0a637dc5a2c898a6.0x113f9804bef90dae.0x1b710b35131c471b.0x28db77f523047d84.0x32caab7b40c72493.0x3c9ebe0a15c9bebc.0x431d67c49c100d4c.0x4cc5d4becb3e42b6.0x597f299cfc657e2a.0x5fcb6fab3ad6faec.0x6c44198c4a475817`.split(`.`).map(e=>BigInt(e))),Gs=Ws[0],Ks=Ws[1],qs=new Uint32Array(80),Js=new Uint32Array(80);var Ys=class extends Es{constructor(e){super(128,e,16,!1)}get(){let{Ah:e,Al:t,Bh:n,Bl:r,Ch:i,Cl:a,Dh:o,Dl:s,Eh:c,El:l,Fh:u,Fl:d,Gh:f,Gl:p,Hh:m,Hl:h}=this;return[e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h]}set(e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h){this.Ah=e|0,this.Al=t|0,this.Bh=n|0,this.Bl=r|0,this.Ch=i|0,this.Cl=a|0,this.Dh=o|0,this.Dl=s|0,this.Eh=c|0,this.El=l|0,this.Fh=u|0,this.Fl=d|0,this.Gh=f|0,this.Gl=p|0,this.Hh=m|0,this.Hl=h|0}process(e,t){for(let n=0;n<16;n++,t+=4)qs[n]=e.getUint32(t),Js[n]=e.getUint32(t+=4);for(let e=16;e<80;e++){let t=qs[e-15]|0,n=Js[e-15]|0,r=Ns(t,n,1)^Ns(t,n,8)^js(t,n,7),i=Ps(t,n,1)^Ps(t,n,8)^Ms(t,n,7),a=qs[e-2]|0,o=Js[e-2]|0,s=Ns(a,o,19)^Fs(a,o,61)^js(a,o,6),c=Bs(i,Ps(a,o,19)^Is(a,o,61)^Ms(a,o,6),Js[e-7],Js[e-16]);qs[e]=Vs(c,r,s,qs[e-7],qs[e-16])|0,Js[e]=c|0}let{Ah:n,Al:r,Bh:i,Bl:a,Ch:o,Cl:s,Dh:c,Dl:l,Eh:u,El:d,Fh:f,Fl:p,Gh:m,Gl:h,Hh:g,Hl:_}=this;for(let e=0;e<80;e++){let t=Ns(u,d,14)^Ns(u,d,18)^Fs(u,d,41),v=Ps(u,d,14)^Ps(u,d,18)^Is(u,d,41),y=u&f^~u&m,b=d&p^~d&h,x=Hs(_,v,b,Ks[e],Js[e]),S=Us(x,g,t,y,Gs[e],qs[e]),C=x|0,w=Ns(n,r,28)^Fs(n,r,34)^Fs(n,r,39),ee=Ps(n,r,28)^Is(n,r,34)^Is(n,r,39),te=n&i^n&o^i&o,ne=r&a^r&s^a&s;g=m|0,_=h|0,m=f|0,h=p|0,f=u|0,p=d|0,{h:u,l:d}=Ls(c|0,l|0,S|0,C|0),c=o|0,l=s|0,o=i|0,s=a|0,i=n|0,a=r|0;let re=Rs(C,ee,ne);n=zs(re,S,w,te),r=re|0}({h:n,l:r}=Ls(this.Ah|0,this.Al|0,n|0,r|0)),{h:i,l:a}=Ls(this.Bh|0,this.Bl|0,i|0,a|0),{h:o,l:s}=Ls(this.Ch|0,this.Cl|0,o|0,s|0),{h:c,l}=Ls(this.Dh|0,this.Dl|0,c|0,l|0),{h:u,l:d}=Ls(this.Eh|0,this.El|0,u|0,d|0),{h:f,l:p}=Ls(this.Fh|0,this.Fl|0,f|0,p|0),{h:m,l:h}=Ls(this.Gh|0,this.Gl|0,m|0,h|0),{h:g,l:_}=Ls(this.Hh|0,this.Hl|0,g|0,_|0),this.set(n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_)}roundClean(){ms(qs,Js)}destroy(){this.destroyed=!0,ms(this.buffer),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}},Xs=class extends Ys{Ah=F[0]|0;Al=F[1]|0;Bh=F[2]|0;Bl=F[3]|0;Ch=F[4]|0;Cl=F[5]|0;Dh=F[6]|0;Dl=F[7]|0;Eh=F[8]|0;El=F[9]|0;Fh=F[10]|0;Fl=F[11]|0;Gh=F[12]|0;Gl=F[13]|0;Hh=F[14]|0;Hl=F[15]|0;constructor(){super(64)}};let Zs=ys(()=>new Xs,bs(3)),Qs=(e,t,n,r)=>Buffer.from(Ts(Zs,e,t,{c:n,dkLen:r})),$s=`: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`;$s+``,``+$s;let ec=RegExp(`^[: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][: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\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`);function tc(e,t){let n=[],r=t.exec(e);for(;r;){let i=[];i.startIndex=t.lastIndex-r[0].length;let a=r.length;for(let e=0;e<a;e++)i.push(r[e]);n.push(i),r=t.exec(e)}return n}let nc=function(e){return ec.exec(e)!=null};function rc(e){return e!==void 0}let ic=[`hasOwnProperty`,`toString`,`valueOf`,`__defineGetter__`,`__defineSetter__`,`__lookupGetter__`,`__lookupSetter__`],ac=[`__proto__`,`constructor`,`prototype`],oc={allowBooleanAttributes:!1,unpairedTags:[]};function sc(e,t){t=Object.assign({},oc,t);let n=[],r=!1,i=!1;e[0]===``&&(e=e.substr(1));for(let a=0;a<e.length;a++)if(e[a]===`<`&&e[a+1]===`?`){if(a+=2,a=lc(e,a),a.err)return a}else if(e[a]===`<`){let o=a;if(a++,e[a]===`!`){a=uc(e,a);continue}else{let s=!1;e[a]===`/`&&(s=!0,a++);let c=``;for(;a<e.length&&e[a]!==`>`&&e[a]!==` `&&e[a]!==` `&&e[a]!==`
10
10
  `&&e[a]!==`\r`;a++)c+=e[a];if(c=c.trim(),c[c.length-1]===`/`&&(c=c.substring(0,c.length-1),a--),!_c(c)){let t;return t=c.trim().length===0?`Invalid space after '<'.`:`Tag '`+c+`' is an invalid name.`,I(`InvalidTag`,t,L(e,a))}let l=dc(e,a);if(l===!1)return I(`InvalidAttr`,`Attributes for '`+c+`' have open quote.`,L(e,a));let u=l.value;if(a=l.index,u[u.length-1]===`/`){let n=a-u.length;u=u.substring(0,u.length-1);let i=pc(u,t);if(i===!0)r=!0;else return I(i.err.code,i.err.msg,L(e,n+i.err.line))}else if(s){if(!l.tagClosed)return I(`InvalidTag`,`Closing tag '`+c+`' doesn't have proper closing.`,L(e,a));if(u.trim().length>0)return I(`InvalidTag`,`Closing tag '`+c+`' can't have attributes or invalid starting.`,L(e,o));if(n.length===0)return I(`InvalidTag`,`Closing tag '`+c+`' has not been opened.`,L(e,o));{let t=n.pop();if(c!==t.tagName){let n=L(e,t.tagStartPos);return I(`InvalidTag`,`Expected closing tag '`+t.tagName+`' (opened in line `+n.line+`, col `+n.col+`) instead of closing tag '`+c+`'.`,L(e,o))}n.length==0&&(i=!0)}}else{let s=pc(u,t);if(s!==!0)return I(s.err.code,s.err.msg,L(e,a-u.length+s.err.line));if(i===!0)return I(`InvalidXml`,`Multiple possible root nodes found.`,L(e,a));t.unpairedTags.indexOf(c)!==-1||n.push({tagName:c,tagStartPos:o}),r=!0}for(a++;a<e.length;a++)if(e[a]===`<`)if(e[a+1]===`!`){a++,a=uc(e,a);continue}else if(e[a+1]===`?`){if(a=lc(e,++a),a.err)return a}else break;else if(e[a]===`&`){let t=hc(e,a);if(t==-1)return I(`InvalidChar`,`char '&' is not expected.`,L(e,a));a=t}else if(i===!0&&!cc(e[a]))return I(`InvalidXml`,`Extra text at the end`,L(e,a));e[a]===`<`&&a--}}else{if(cc(e[a]))continue;return I(`InvalidChar`,`char '`+e[a]+`' is not expected.`,L(e,a))}return r?n.length==1?I(`InvalidTag`,`Unclosed tag '`+n[0].tagName+`'.`,L(e,n[0].tagStartPos)):n.length>0?I(`InvalidXml`,`Invalid '`+JSON.stringify(n.map(e=>e.tagName),null,4).replace(/\r?\n/g,``)+`' found.`,{line:1,col:1}):!0:I(`InvalidXml`,`Start tag expected.`,1)}function cc(e){return e===` `||e===` `||e===`
11
- `||e===`\r`}function lc(e,t){let n=t;for(;t<e.length;t++)if(e[t]==`?`||e[t]==` `){let r=e.substr(n,t-n);if(t>5&&r===`xml`)return I(`InvalidXml`,`XML declaration allowed only at the start of the document.`,L(e,t));if(e[t]==`?`&&e[t+1]==`>`){t++;break}else continue}return t}function uc(e,t){if(e.length>t+5&&e[t+1]===`-`&&e[t+2]===`-`){for(t+=3;t<e.length;t++)if(e[t]===`-`&&e[t+1]===`-`&&e[t+2]===`>`){t+=2;break}}else if(e.length>t+8&&e[t+1]===`D`&&e[t+2]===`O`&&e[t+3]===`C`&&e[t+4]===`T`&&e[t+5]===`Y`&&e[t+6]===`P`&&e[t+7]===`E`){let n=1;for(t+=8;t<e.length;t++)if(e[t]===`<`)n++;else if(e[t]===`>`&&(n--,n===0))break}else if(e.length>t+9&&e[t+1]===`[`&&e[t+2]===`C`&&e[t+3]===`D`&&e[t+4]===`A`&&e[t+5]===`T`&&e[t+6]===`A`&&e[t+7]===`[`){for(t+=8;t<e.length;t++)if(e[t]===`]`&&e[t+1]===`]`&&e[t+2]===`>`){t+=2;break}}return t}function dc(e,t){let n=``,r=``,i=!1;for(;t<e.length;t++){if(e[t]===`"`||e[t]===`'`)r===``?r=e[t]:r!==e[t]||(r=``);else if(e[t]===`>`&&r===``){i=!0;break}n+=e[t]}return r===``?{value:n,index:t,tagClosed:i}:!1}let fc=RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,`g`);function pc(e,t){let n=tc(e,fc),r={};for(let e=0;e<n.length;e++){if(n[e][1].length===0)return I(`InvalidAttr`,`Attribute '`+n[e][2]+`' has no space in starting.`,vc(n[e]));if(n[e][3]!==void 0&&n[e][4]===void 0)return I(`InvalidAttr`,`Attribute '`+n[e][2]+`' is without value.`,vc(n[e]));if(n[e][3]===void 0&&!t.allowBooleanAttributes)return I(`InvalidAttr`,`boolean attribute '`+n[e][2]+`' is not allowed.`,vc(n[e]));let i=n[e][2];if(!gc(i))return I(`InvalidAttr`,`Attribute '`+i+`' is an invalid name.`,vc(n[e]));if(!Object.prototype.hasOwnProperty.call(r,i))r[i]=1;else return I(`InvalidAttr`,`Attribute '`+i+`' is repeated.`,vc(n[e]))}return!0}function mc(e,t){let n=/\d/;for(e[t]===`x`&&(t++,n=/[\da-fA-F]/);t<e.length;t++){if(e[t]===`;`)return t;if(!e[t].match(n))break}return-1}function hc(e,t){if(t++,e[t]===`;`)return-1;if(e[t]===`#`)return t++,mc(e,t);let n=0;for(;t<e.length;t++,n++)if(!(e[t].match(/\w/)&&n<20)){if(e[t]===`;`)break;return-1}return t}function I(e,t,n){return{err:{code:e,msg:t,line:n.line||n,col:n.col}}}function gc(e){return nc(e)}function _c(e){return nc(e)}function L(e,t){let n=e.substring(0,t).split(/\r?\n/);return{line:n.length,col:n[n.length-1].length+1}}function vc(e){return e.startIndex+e[1].length}let yc={amp:`&`,AMP:`&`,lt:`<`,LT:`<`,gt:`>`,GT:`>`,quot:`"`,QUOT:`"`,apos:`'`,lsquo:`‘`,rsquo:`’`,ldquo:`“`,rdquo:`”`,lsquor:`‚`,rsquor:`’`,ldquor:`„`,bdquo:`„`,comma:`,`,period:`.`,colon:`:`,semi:`;`,excl:`!`,quest:`?`,num:`#`,dollar:`$`,percent:`%`,amp:`&`,ast:`*`,commat:`@`,lowbar:`_`,verbar:`|`,vert:`|`,sol:`/`,bsol:`\\`,lbrace:`{`,rbrace:`}`,lbrack:`[`,rbrack:`]`,lpar:`(`,rpar:`)`,nbsp:`\xA0`,iexcl:`¡`,cent:`¢`,pound:`£`,curren:`¤`,yen:`¥`,brvbar:`¦`,sect:`§`,uml:`¨`,copy:`©`,COPY:`©`,ordf:`ª`,laquo:`«`,not:`¬`,shy:`­`,reg:`®`,REG:`®`,macr:`¯`,deg:`°`,plusmn:`±`,sup2:`²`,sup3:`³`,acute:`´`,micro:`µ`,para:`¶`,middot:`·`,cedil:`¸`,sup1:`¹`,ordm:`º`,raquo:`»`,frac14:`¼`,frac12:`½`,half:`½`,frac34:`¾`,iquest:`¿`,times:`×`,div:`÷`,divide:`÷`},bc={Agrave:`À`,agrave:`à`,Aacute:`Á`,aacute:`á`,Acirc:`Â`,acirc:`â`,Atilde:`Ã`,atilde:`ã`,Auml:`Ä`,auml:`ä`,Aring:`Å`,aring:`å`,AElig:`Æ`,aelig:`æ`,Ccedil:`Ç`,ccedil:`ç`,Egrave:`È`,egrave:`è`,Eacute:`É`,eacute:`é`,Ecirc:`Ê`,ecirc:`ê`,Euml:`Ë`,euml:`ë`,Igrave:`Ì`,igrave:`ì`,Iacute:`Í`,iacute:`í`,Icirc:`Î`,icirc:`î`,Iuml:`Ï`,iuml:`ï`,ETH:`Ð`,eth:`ð`,Ntilde:`Ñ`,ntilde:`ñ`,Ograve:`Ò`,ograve:`ò`,Oacute:`Ó`,oacute:`ó`,Ocirc:`Ô`,ocirc:`ô`,Otilde:`Õ`,otilde:`õ`,Ouml:`Ö`,ouml:`ö`,Oslash:`Ø`,oslash:`ø`,Ugrave:`Ù`,ugrave:`ù`,Uacute:`Ú`,uacute:`ú`,Ucirc:`Û`,ucirc:`û`,Uuml:`Ü`,uuml:`ü`,Yacute:`Ý`,yacute:`ý`,THORN:`Þ`,thorn:`þ`,szlig:`ß`,yuml:`ÿ`,Yuml:`Ÿ`},xc={Amacr:`Ā`,amacr:`ā`,Abreve:`Ă`,abreve:`ă`,Aogon:`Ą`,aogon:`ą`,Cacute:`Ć`,cacute:`ć`,Ccirc:`Ĉ`,ccirc:`ĉ`,Cdot:`Ċ`,cdot:`ċ`,Ccaron:`Č`,ccaron:`č`,Dcaron:`Ď`,dcaron:`ď`,Dstrok:`Đ`,dstrok:`đ`,Emacr:`Ē`,emacr:`ē`,Ecaron:`Ě`,ecaron:`ě`,Edot:`Ė`,edot:`ė`,Eogon:`Ę`,eogon:`ę`,Gcirc:`Ĝ`,gcirc:`ĝ`,Gbreve:`Ğ`,gbreve:`ğ`,Gdot:`Ġ`,gdot:`ġ`,Gcedil:`Ģ`,Hcirc:`Ĥ`,hcirc:`ĥ`,Hstrok:`Ħ`,hstrok:`ħ`,Itilde:`Ĩ`,itilde:`ĩ`,Imacr:`Ī`,imacr:`ī`,Iogon:`Į`,iogon:`į`,Idot:`İ`,IJlig:`IJ`,ijlig:`ij`,Jcirc:`Ĵ`,jcirc:`ĵ`,Kcedil:`Ķ`,kcedil:`ķ`,kgreen:`ĸ`,Lacute:`Ĺ`,lacute:`ĺ`,Lcedil:`Ļ`,lcedil:`ļ`,Lcaron:`Ľ`,lcaron:`ľ`,Lmidot:`Ŀ`,lmidot:`ŀ`,Lstrok:`Ł`,lstrok:`ł`,Nacute:`Ń`,nacute:`ń`,Ncaron:`Ň`,ncaron:`ň`,Ncedil:`Ņ`,ncedil:`ņ`,ENG:`Ŋ`,eng:`ŋ`,Omacr:`Ō`,omacr:`ō`,Odblac:`Ő`,odblac:`ő`,OElig:`Œ`,oelig:`œ`,Racute:`Ŕ`,racute:`ŕ`,Rcaron:`Ř`,rcaron:`ř`,Rcedil:`Ŗ`,rcedil:`ŗ`,Sacute:`Ś`,sacute:`ś`,Scirc:`Ŝ`,scirc:`ŝ`,Scedil:`Ş`,scedil:`ş`,Scaron:`Š`,scaron:`š`,Tcedil:`Ţ`,tcedil:`ţ`,Tcaron:`Ť`,tcaron:`ť`,Tstrok:`Ŧ`,tstrok:`ŧ`,Utilde:`Ũ`,utilde:`ũ`,Umacr:`Ū`,umacr:`ū`,Ubreve:`Ŭ`,ubreve:`ŭ`,Uring:`Ů`,uring:`ů`,Udblac:`Ű`,udblac:`ű`,Uogon:`Ų`,uogon:`ų`,Wcirc:`Ŵ`,wcirc:`ŵ`,Ycirc:`Ŷ`,ycirc:`ŷ`,Zacute:`Ź`,zacute:`ź`,Zdot:`Ż`,zdot:`ż`,Zcaron:`Ž`,zcaron:`ž`},Sc={Alpha:`Α`,alpha:`α`,Beta:`Β`,beta:`β`,Gamma:`Γ`,gamma:`γ`,Delta:`Δ`,delta:`δ`,Epsilon:`Ε`,epsilon:`ε`,epsiv:`ϵ`,varepsilon:`ϵ`,Zeta:`Ζ`,zeta:`ζ`,Eta:`Η`,eta:`η`,Theta:`Θ`,theta:`θ`,thetasym:`ϑ`,vartheta:`ϑ`,Iota:`Ι`,iota:`ι`,Kappa:`Κ`,kappa:`κ`,kappav:`ϰ`,varkappa:`ϰ`,Lambda:`Λ`,lambda:`λ`,Mu:`Μ`,mu:`μ`,Nu:`Ν`,nu:`ν`,Xi:`Ξ`,xi:`ξ`,Omicron:`Ο`,omicron:`ο`,Pi:`Π`,pi:`π`,piv:`ϖ`,varpi:`ϖ`,Rho:`Ρ`,rho:`ρ`,rhov:`ϱ`,varrho:`ϱ`,Sigma:`Σ`,sigma:`σ`,sigmaf:`ς`,sigmav:`ς`,varsigma:`ς`,Tau:`Τ`,tau:`τ`,Upsilon:`Υ`,upsilon:`υ`,upsi:`υ`,Upsi:`ϒ`,upsih:`ϒ`,Phi:`Φ`,phi:`φ`,phiv:`ϕ`,varphi:`ϕ`,Chi:`Χ`,chi:`χ`,Psi:`Ψ`,psi:`ψ`,Omega:`Ω`,omega:`ω`,ohm:`Ω`,Gammad:`Ϝ`,gammad:`ϝ`,digamma:`ϝ`},Cc={Afr:`𝔄`,afr:`𝔞`,Acy:`А`,acy:`а`,Bcy:`Б`,bcy:`б`,Vcy:`В`,vcy:`в`,Gcy:`Г`,gcy:`г`,Dcy:`Д`,dcy:`д`,IEcy:`Е`,iecy:`е`,IOcy:`Ё`,iocy:`ё`,ZHcy:`Ж`,zhcy:`ж`,Zcy:`З`,zcy:`з`,Icy:`И`,icy:`и`,Jcy:`Й`,jcy:`й`,Kcy:`К`,kcy:`к`,Lcy:`Л`,lcy:`л`,Mcy:`М`,mcy:`м`,Ncy:`Н`,ncy:`н`,Ocy:`О`,ocy:`о`,Pcy:`П`,pcy:`п`,Rcy:`Р`,rcy:`р`,Scy:`С`,scy:`с`,Tcy:`Т`,tcy:`т`,Ucy:`У`,ucy:`у`,Fcy:`Ф`,fcy:`ф`,KHcy:`Х`,khcy:`х`,TScy:`Ц`,tscy:`ц`,CHcy:`Ч`,chcy:`ч`,SHcy:`Ш`,shcy:`ш`,SHCHcy:`Щ`,shchcy:`щ`,HARDcy:`Ъ`,hardcy:`ъ`,Ycy:`Ы`,ycy:`ы`,SOFTcy:`Ь`,softcy:`ь`,Ecy:`Э`,ecy:`э`,YUcy:`Ю`,yucy:`ю`,YAcy:`Я`,yacy:`я`,DJcy:`Ђ`,djcy:`ђ`,GJcy:`Ѓ`,gjcy:`ѓ`,Jukcy:`Є`,jukcy:`є`,DScy:`Ѕ`,dscy:`ѕ`,Iukcy:`І`,iukcy:`і`,YIcy:`Ї`,yicy:`ї`,Jsercy:`Ј`,jsercy:`ј`,LJcy:`Љ`,ljcy:`љ`,NJcy:`Њ`,njcy:`њ`,TSHcy:`Ћ`,tshcy:`ћ`,KJcy:`Ќ`,kjcy:`ќ`,Ubrcy:`Ў`,ubrcy:`ў`,DZcy:`Џ`,dzcy:`џ`},wc={plus:`+`,minus:`−`,mnplus:`∓`,mp:`∓`,pm:`±`,times:`×`,div:`÷`,divide:`÷`,sdot:`⋅`,star:`☆`,starf:`★`,bigstar:`★`,lowast:`∗`,ast:`*`,midast:`*`,compfn:`∘`,smallcircle:`∘`,bullet:`•`,bull:`•`,nbsp:`\xA0`,hellip:`…`,mldr:`…`,prime:`′`,Prime:`″`,tprime:`‴`,bprime:`‵`,backprime:`‵`,minus:`−`,minusd:`∸`,dotminus:`∸`,plusdo:`∔`,dotplus:`∔`,plusmn:`±`,minusplus:`∓`,mnplus:`∓`,mp:`∓`,setminus:`∖`,smallsetminus:`∖`,Backslash:`∖`,setmn:`∖`,ssetmn:`∖`,lowbar:`_`,verbar:`|`,vert:`|`,VerticalLine:`|`,colon:`:`,Colon:`∷`,Proportion:`∷`,ratio:`∶`,equals:`=`,ne:`≠`,nequiv:`≢`,equiv:`≡`,Congruent:`≡`,sim:`∼`,thicksim:`∼`,thksim:`∼`,sime:`≃`,simeq:`≃`,TildeEqual:`≃`,asymp:`≈`,approx:`≈`,thickapprox:`≈`,thkap:`≈`,TildeTilde:`≈`,ncong:`≇`,cong:`≅`,TildeFullEqual:`≅`,asympeq:`≍`,CupCap:`≍`,bump:`≎`,Bumpeq:`≎`,HumpDownHump:`≎`,bumpe:`≏`,bumpeq:`≏`,HumpEqual:`≏`,dotminus:`∸`,minusd:`∸`,plusdo:`∔`,dotplus:`∔`,le:`≤`,LessEqual:`≤`,ge:`≥`,GreaterEqual:`≥`,lesseqgtr:`⋚`,lesseqqgtr:`⪋`,greater:`>`,less:`<`},Tc={alefsym:`ℵ`,aleph:`ℵ`,beth:`ℶ`,gimel:`ℷ`,daleth:`ℸ`,forall:`∀`,ForAll:`∀`,part:`∂`,PartialD:`∂`,exist:`∃`,Exists:`∃`,nexist:`∄`,nexists:`∄`,empty:`∅`,emptyset:`∅`,emptyv:`∅`,varnothing:`∅`,nabla:`∇`,Del:`∇`,isin:`∈`,isinv:`∈`,in:`∈`,Element:`∈`,notin:`∉`,notinva:`∉`,ni:`∋`,niv:`∋`,SuchThat:`∋`,ReverseElement:`∋`,notni:`∌`,notniva:`∌`,prod:`∏`,Product:`∏`,coprod:`∐`,Coproduct:`∐`,sum:`∑`,Sum:`∑`,minus:`−`,mp:`∓`,plusdo:`∔`,dotplus:`∔`,setminus:`∖`,lowast:`∗`,radic:`√`,Sqrt:`√`,prop:`∝`,propto:`∝`,Proportional:`∝`,varpropto:`∝`,infin:`∞`,infintie:`⧝`,ang:`∠`,angle:`∠`,angmsd:`∡`,measuredangle:`∡`,angsph:`∢`,mid:`∣`,VerticalBar:`∣`,nmid:`∤`,nsmid:`∤`,npar:`∦`,parallel:`∥`,spar:`∥`,nparallel:`∦`,nspar:`∦`,and:`∧`,wedge:`∧`,or:`∨`,vee:`∨`,cap:`∩`,cup:`∪`,int:`∫`,Integral:`∫`,conint:`∮`,ContourIntegral:`∮`,Conint:`∯`,DoubleContourIntegral:`∯`,Cconint:`∰`,there4:`∴`,therefore:`∴`,Therefore:`∴`,becaus:`∵`,because:`∵`,Because:`∵`,ratio:`∶`,Proportion:`∷`,minusd:`∸`,dotminus:`∸`,mDDot:`∺`,homtht:`∻`,sim:`∼`,bsimg:`∽`,backsim:`∽`,ac:`∾`,mstpos:`∾`,acd:`∿`,VerticalTilde:`≀`,wr:`≀`,wreath:`≀`,nsime:`≄`,nsimeq:`≄`,nsimeq:`≄`,ncong:`≇`,simne:`≆`,ncongdot:`⩭̸`,ngsim:`≵`,nsim:`≁`,napprox:`≉`,nap:`≉`,ngeq:`≱`,nge:`≱`,nleq:`≰`,nle:`≰`,ngtr:`≯`,ngt:`≯`,nless:`≮`,nlt:`≮`,nprec:`⊀`,npr:`⊀`,nsucc:`⊁`,nsc:`⊁`},Ec={larr:`←`,leftarrow:`←`,LeftArrow:`←`,uarr:`↑`,uparrow:`↑`,UpArrow:`↑`,rarr:`→`,rightarrow:`→`,RightArrow:`→`,darr:`↓`,downarrow:`↓`,DownArrow:`↓`,harr:`↔`,leftrightarrow:`↔`,LeftRightArrow:`↔`,varr:`↕`,updownarrow:`↕`,UpDownArrow:`↕`,nwarr:`↖`,nwarrow:`↖`,UpperLeftArrow:`↖`,nearr:`↗`,nearrow:`↗`,UpperRightArrow:`↗`,searr:`↘`,searrow:`↘`,LowerRightArrow:`↘`,swarr:`↙`,swarrow:`↙`,LowerLeftArrow:`↙`,lArr:`⇐`,Leftarrow:`⇐`,uArr:`⇑`,Uparrow:`⇑`,rArr:`⇒`,Rightarrow:`⇒`,dArr:`⇓`,Downarrow:`⇓`,hArr:`⇔`,Leftrightarrow:`⇔`,iff:`⇔`,vArr:`⇕`,Updownarrow:`⇕`,lAarr:`⇚`,Lleftarrow:`⇚`,rAarr:`⇛`,Rrightarrow:`⇛`,lrarr:`⇆`,leftrightarrows:`⇆`,rlarr:`⇄`,rightleftarrows:`⇄`,lrhar:`⇋`,leftrightharpoons:`⇋`,ReverseEquilibrium:`⇋`,rlhar:`⇌`,rightleftharpoons:`⇌`,Equilibrium:`⇌`,udarr:`⇅`,UpArrowDownArrow:`⇅`,duarr:`⇵`,DownArrowUpArrow:`⇵`,llarr:`⇇`,leftleftarrows:`⇇`,rrarr:`⇉`,rightrightarrows:`⇉`,ddarr:`⇊`,downdownarrows:`⇊`,har:`↽`,lhard:`↽`,leftharpoondown:`↽`,lharu:`↼`,leftharpoonup:`↼`,rhard:`⇁`,rightharpoondown:`⇁`,rharu:`⇀`,rightharpoonup:`⇀`,lsh:`↰`,Lsh:`↰`,rsh:`↱`,Rsh:`↱`,ldsh:`↲`,rdsh:`↳`,hookleftarrow:`↩`,hookrightarrow:`↪`,mapstoleft:`↤`,mapstoup:`↥`,map:`↦`,mapsto:`↦`,mapstodown:`↧`,crarr:`↵`,nwarrow:`↖`,nearrow:`↗`,searrow:`↘`,swarrow:`↙`,nleftarrow:`↚`,nleftrightarrow:`↮`,nrightarrow:`↛`,nrarr:`↛`,larrtl:`↢`,rarrtl:`↣`,leftarrowtail:`↢`,rightarrowtail:`↣`,twoheadleftarrow:`↞`,twoheadrightarrow:`↠`,Larr:`↞`,Rarr:`↠`,larrhk:`↩`,rarrhk:`↪`,larrlp:`↫`,looparrowleft:`↫`,rarrlp:`↬`,looparrowright:`↬`,harrw:`↭`,leftrightsquigarrow:`↭`,nrarrw:`↝̸`,rarrw:`↝`,rightsquigarrow:`↝`,larrbfs:`⤟`,rarrbfs:`⤠`,nvHarr:`⤄`,nvlArr:`⤂`,nvrArr:`⤃`,larrfs:`⤝`,rarrfs:`⤞`,Map:`⤅`,larrsim:`⥳`,rarrsim:`⥴`,harrcir:`⥈`,Uarrocir:`⥉`,lurdshar:`⥊`,ldrdhar:`⥧`,ldrushar:`⥋`,rdldhar:`⥩`,lrhard:`⥭`,rlhar:`⇌`,uharr:`↾`,uharl:`↿`,dharr:`⇂`,dharl:`⇃`,Uarr:`↟`,Darr:`↡`,zigrarr:`⇝`,nwArr:`⇖`,neArr:`⇗`,seArr:`⇘`,swArr:`⇙`,nharr:`↮`,nhArr:`⇎`,nlarr:`↚`,nlArr:`⇍`,nrarr:`↛`,nrArr:`⇏`,larrb:`⇤`,LeftArrowBar:`⇤`,rarrb:`⇥`,RightArrowBar:`⇥`},Dc={square:`□`,Square:`□`,squ:`□`,squf:`▪`,squarf:`▪`,blacksquar:`▪`,blacksquare:`▪`,FilledVerySmallSquare:`▪`,blk34:`▓`,blk12:`▒`,blk14:`░`,block:`█`,srect:`▭`,rect:`▭`,sdot:`⋅`,sdotb:`⊡`,dotsquare:`⊡`,triangle:`▵`,tri:`▵`,trine:`▵`,utri:`▵`,triangledown:`▿`,dtri:`▿`,tridown:`▿`,triangleleft:`◃`,ltri:`◃`,triangleright:`▹`,rtri:`▹`,blacktriangle:`▴`,utrif:`▴`,blacktriangledown:`▾`,dtrif:`▾`,blacktriangleleft:`◂`,ltrif:`◂`,blacktriangleright:`▸`,rtrif:`▸`,loz:`◊`,lozenge:`◊`,blacklozenge:`⧫`,lozf:`⧫`,bigcirc:`◯`,xcirc:`◯`,circ:`ˆ`,Circle:`○`,cir:`○`,o:`○`,bullet:`•`,bull:`•`,hellip:`…`,mldr:`…`,nldr:`‥`,boxh:`─`,HorizontalLine:`─`,boxv:`│`,boxdr:`┌`,boxdl:`┐`,boxur:`└`,boxul:`┘`,boxvr:`├`,boxvl:`┤`,boxhd:`┬`,boxhu:`┴`,boxvh:`┼`,boxH:`═`,boxV:`║`,boxdR:`╒`,boxDr:`╓`,boxDR:`╔`,boxDl:`╕`,boxdL:`╖`,boxDL:`╗`,boxuR:`╘`,boxUr:`╙`,boxUR:`╚`,boxUl:`╜`,boxuL:`╛`,boxUL:`╝`,boxvR:`╞`,boxVr:`╟`,boxVR:`╠`,boxVl:`╢`,boxvL:`╡`,boxVL:`╣`,boxHd:`╤`,boxhD:`╥`,boxHD:`╦`,boxHu:`╧`,boxhU:`╨`,boxHU:`╩`,boxvH:`╪`,boxVh:`╫`,boxVH:`╬`},Oc={excl:`!`,iexcl:`¡`,brvbar:`¦`,sect:`§`,uml:`¨`,copy:`©`,ordf:`ª`,laquo:`«`,not:`¬`,shy:`­`,reg:`®`,macr:`¯`,deg:`°`,plusmn:`±`,sup2:`²`,sup3:`³`,acute:`´`,micro:`µ`,para:`¶`,middot:`·`,cedil:`¸`,sup1:`¹`,ordm:`º`,raquo:`»`,frac14:`¼`,frac12:`½`,frac34:`¾`,iquest:`¿`,nbsp:`\xA0`,comma:`,`,period:`.`,colon:`:`,semi:`;`,vert:`|`,Verbar:`‖`,verbar:`|`,dblac:`˝`,circ:`ˆ`,caron:`ˇ`,breve:`˘`,dot:`˙`,ring:`˚`,ogon:`˛`,tilde:`˜`,DiacriticalGrave:"`",DiacriticalAcute:`´`,DiacriticalTilde:`˜`,DiacriticalDot:`˙`,DiacriticalDoubleAcute:`˝`,grave:"`",acute:`´`},kc={cent:`¢`,pound:`£`,curren:`¤`,yen:`¥`,euro:`€`,dollar:`$`,euro:`€`,fnof:`ƒ`,inr:`₹`,af:`؋`,birr:`ብር`,peso:`₱`,rub:`₽`,won:`₩`,yuan:`¥`,cedil:`¸`},Ac={frac12:`½`,half:`½`,frac13:`⅓`,frac14:`¼`,frac15:`⅕`,frac16:`⅙`,frac18:`⅛`,frac23:`⅔`,frac25:`⅖`,frac34:`¾`,frac35:`⅗`,frac38:`⅜`,frac45:`⅘`,frac56:`⅚`,frac58:`⅝`,frac78:`⅞`,frasl:`⁄`},jc={trade:`™`,TRADE:`™`,telrec:`⌕`,target:`⌖`,ulcorn:`⌜`,ulcorner:`⌜`,urcorn:`⌝`,urcorner:`⌝`,dlcorn:`⌞`,llcorner:`⌞`,drcorn:`⌟`,lrcorner:`⌟`,intercal:`⊺`,intcal:`⊺`,oplus:`⊕`,CirclePlus:`⊕`,ominus:`⊖`,CircleMinus:`⊖`,otimes:`⊗`,CircleTimes:`⊗`,osol:`⊘`,odot:`⊙`,CircleDot:`⊙`,oast:`⊛`,circledast:`⊛`,odash:`⊝`,circleddash:`⊝`,ocirc:`⊚`,circledcirc:`⊚`,boxplus:`⊞`,plusb:`⊞`,boxminus:`⊟`,minusb:`⊟`,boxtimes:`⊠`,timesb:`⊠`,boxdot:`⊡`,sdotb:`⊡`,veebar:`⊻`,vee:`∨`,barvee:`⊽`,and:`∧`,wedge:`∧`,Cap:`⋒`,Cup:`⋓`,Fork:`⋔`,pitchfork:`⋔`,epar:`⋕`,ltlarr:`⥶`,nvap:`≍⃒`,nvsim:`∼⃒`,nvge:`≥⃒`,nvle:`≤⃒`,nvlt:`<⃒`,nvgt:`>⃒`,nvltrie:`⊴⃒`,nvrtrie:`⊵⃒`,Vdash:`⊩`,dashv:`⊣`,vDash:`⊨`,Vdash:`⊩`,Vvdash:`⊪`,nvdash:`⊬`,nvDash:`⊭`,nVdash:`⊮`,nVDash:`⊯`};({...yc,...bc,...xc,...Sc,...Cc,...wc,...Tc,...Ec,...Dc,...Oc,...kc,...Ac,...jc});let Mc={amp:`&`,apos:`'`,gt:`>`,lt:`<`,quot:`"`},Nc={nbsp:`\xA0`,copy:`©`,reg:`®`,trade:`™`,mdash:`—`,ndash:`–`,hellip:`…`,laquo:`«`,raquo:`»`,lsquo:`‘`,rsquo:`’`,ldquo:`“`,rdquo:`”`,bull:`•`,para:`¶`,sect:`§`,deg:`°`,frac12:`½`,frac14:`¼`,frac34:`¾`},Pc=new Set(`!?\\\\/[]$%{}^&*()<>|+`);function Fc(e){if(e[0]===`#`)throw Error(`[EntityReplacer] Invalid character '#' in entity name: "${e}"`);for(let t of e)if(Pc.has(t))throw Error(`[EntityReplacer] Invalid character '${t}' in entity name: "${e}"`);return e}function Ic(...e){let t=Object.create(null);for(let n of e)if(n)for(let e of Object.keys(n)){let r=n[e];if(typeof r==`string`)t[e]=r;else if(r&&typeof r==`object`&&r.val!==void 0){let n=r.val;typeof n==`string`&&(t[e]=n)}}return t}let Lc=`external`,Rc=`base`;function zc(e){return!e||e===Lc?new Set([Lc]):e===`all`?new Set([`all`]):e===Rc?new Set([Rc]):Array.isArray(e)?new Set(e):new Set([Lc])}let R=Object.freeze({allow:0,leave:1,remove:2,throw:3}),Bc=new Set([9,10,13]);function Vc(e){if(!e)return{xmlVersion:1,onLevel:R.allow,nullLevel:R.remove};let t=e.xmlVersion===1.1?1.1:1,n=R[e.onNCR]??R.allow,r=R[e.nullNCR]??R.remove;return{xmlVersion:t,onLevel:n,nullLevel:Math.max(r,R.remove)}}var Hc=class{constructor(e={}){this._limit=e.limit||{},this._maxTotalExpansions=this._limit.maxTotalExpansions||0,this._maxExpandedLength=this._limit.maxExpandedLength||0,this._postCheck=typeof e.postCheck==`function`?e.postCheck:e=>e,this._limitTiers=zc(this._limit.applyLimitsTo??Lc),this._numericAllowed=e.numericAllowed??!0,this._baseMap=Ic(Mc,e.namedEntities||null),this._externalMap=Object.create(null),this._inputMap=Object.create(null),this._totalExpansions=0,this._expandedLength=0,this._removeSet=new Set(e.remove&&Array.isArray(e.remove)?e.remove:[]),this._leaveSet=new Set(e.leave&&Array.isArray(e.leave)?e.leave:[]);let t=Vc(e.ncr);this._ncrXmlVersion=t.xmlVersion,this._ncrOnLevel=t.onLevel,this._ncrNullLevel=t.nullLevel}setExternalEntities(e){if(e)for(let t of Object.keys(e))Fc(t);this._externalMap=Ic(e)}addExternalEntity(e,t){Fc(e),typeof t==`string`&&t.indexOf(`&`)===-1&&(this._externalMap[e]=t)}addInputEntities(e){this._totalExpansions=0,this._expandedLength=0,this._inputMap=Ic(e)}reset(){return this._inputMap=Object.create(null),this._totalExpansions=0,this._expandedLength=0,this}setXmlVersion(e){this._ncrXmlVersion=e===1.1?1.1:1}decode(e){if(typeof e!=`string`||e.length===0)return e;let t=e,n=[],r=e.length,i=0,a=0,o=this._maxTotalExpansions>0,s=this._maxExpandedLength>0,c=o||s;for(;a<r;){if(e.charCodeAt(a)!==38){a++;continue}let t=a+1;for(;t<r&&e.charCodeAt(t)!==59&&t-a<=32;)t++;if(t>=r||e.charCodeAt(t)!==59){a++;continue}let l=e.slice(a+1,t);if(l.length===0){a++;continue}let u,d;if(this._removeSet.has(l))u=``,d===void 0&&(d=Lc);else if(this._leaveSet.has(l)){a++;continue}else if(l.charCodeAt(0)===35){let e=this._resolveNCR(l);if(e===void 0){a++;continue}u=e,d=Rc}else{let e=this._resolveName(l);u=e?.value,d=e?.tier}if(u===void 0){a++;continue}if(a>i&&n.push(e.slice(i,a)),n.push(u),i=t+1,a=i,c&&this._tierCounts(d)){if(o&&(this._totalExpansions++,this._totalExpansions>this._maxTotalExpansions))throw Error(`[EntityReplacer] Entity expansion count limit exceeded: ${this._totalExpansions} > ${this._maxTotalExpansions}`);if(s){let e=u.length-(l.length+2);if(e>0&&(this._expandedLength+=e,this._expandedLength>this._maxExpandedLength))throw Error(`[EntityReplacer] Expanded content length limit exceeded: ${this._expandedLength} > ${this._maxExpandedLength}`)}}}i<r&&n.push(e.slice(i));let l=n.length===0?e:n.join(``);return this._postCheck(l,t)}_tierCounts(e){return this._limitTiers.has(`all`)?!0:this._limitTiers.has(e)}_resolveName(e){if(e in this._inputMap)return{value:this._inputMap[e],tier:Lc};if(e in this._externalMap)return{value:this._externalMap[e],tier:Lc};if(e in this._baseMap)return{value:this._baseMap[e],tier:Rc}}_classifyNCR(e){return e===0?this._ncrNullLevel:e>=55296&&e<=57343||this._ncrXmlVersion===1&&e>=1&&e<=31&&!Bc.has(e)?R.remove:-1}_applyNCRAction(e,t,n){switch(e){case R.allow:return String.fromCodePoint(n);case R.remove:return``;case R.leave:return;case R.throw:throw Error(`[EntityDecoder] Prohibited numeric character reference &${t}; (U+${n.toString(16).toUpperCase().padStart(4,`0`)})`);default:return String.fromCodePoint(n)}}_resolveNCR(e){let t=e.charCodeAt(1),n;if(n=t===120||t===88?parseInt(e.slice(2),16):parseInt(e.slice(1),10),Number.isNaN(n)||n<0||n>1114111)return;let r=this._classifyNCR(n);if(!this._numericAllowed&&r<R.remove)return;let i=r===-1?this._ncrOnLevel:Math.max(this._ncrOnLevel,r);return this._applyNCRAction(i,e,n)}};let Uc=e=>ic.includes(e)?`__`+e:e,Wc={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(e,t){return t},attributeValueProcessor:function(e,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,entityDecoder:null,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(e,t,n){return e},captureMetaData:!1,maxNestedTags:100,strictReservedNames:!0,jPath:!0,onDangerousProperty:Uc};function Gc(e,t){if(typeof e!=`string`)return;let n=e.toLowerCase();if(ic.some(e=>n===e.toLowerCase())||ac.some(e=>n===e.toLowerCase()))throw Error(`[SECURITY] Invalid ${t}: "${e}" is a reserved JavaScript keyword that could cause prototype pollution`)}function Kc(e,t){return typeof e==`boolean`?{enabled:e,maxEntitySize:1e4,maxExpansionDepth:1e4,maxTotalExpansions:1/0,maxExpandedLength:1e5,maxEntityCount:1e3,allowedTags:null,tagFilter:null,appliesTo:`all`}:typeof e==`object`&&e?{enabled:e.enabled!==!1,maxEntitySize:Math.max(1,e.maxEntitySize??1e4),maxExpansionDepth:Math.max(1,e.maxExpansionDepth??1e4),maxTotalExpansions:Math.max(1,e.maxTotalExpansions??1/0),maxExpandedLength:Math.max(1,e.maxExpandedLength??1e5),maxEntityCount:Math.max(1,e.maxEntityCount??1e3),allowedTags:e.allowedTags??null,tagFilter:e.tagFilter??null,appliesTo:e.appliesTo??`all`}:Kc(!0)}let qc=function(e){let t=Object.assign({},Wc,e),n=[{value:t.attributeNamePrefix,name:`attributeNamePrefix`},{value:t.attributesGroupName,name:`attributesGroupName`},{value:t.textNodeName,name:`textNodeName`},{value:t.cdataPropName,name:`cdataPropName`},{value:t.commentPropName,name:`commentPropName`}];for(let{value:e,name:t}of n)e&&Gc(e,t);return t.onDangerousProperty===null&&(t.onDangerousProperty=Uc),t.processEntities=Kc(t.processEntities,t.htmlEntities),t.unpairedTagsSet=new Set(t.unpairedTags),t.stopNodes&&Array.isArray(t.stopNodes)&&(t.stopNodes=t.stopNodes.map(e=>typeof e==`string`&&e.startsWith(`*.`)?`..`+e.substring(2):e)),t},Jc;Jc=typeof Symbol==`function`?Symbol(`XML Node Metadata`):`@@xmlMetadata`;var Yc=class{constructor(e){this.tagname=e,this.child=[],this[`:@`]=Object.create(null)}add(e,t){e===`__proto__`&&(e=`#__proto__`),this.child.push({[e]:t})}addChild(e,t){e.tagname===`__proto__`&&(e.tagname=`#__proto__`),e[`:@`]&&Object.keys(e[`:@`]).length>0?this.child.push({[e.tagname]:e.child,":@":e[`:@`]}):this.child.push({[e.tagname]:e.child}),t!==void 0&&(this.child[this.child.length-1][Jc]={startIndex:t})}static getMetaDataSymbol(){return Jc}},Xc=class{constructor(e){this.suppressValidationErr=!e,this.options=e}readDocType(e,t){let n=Object.create(null),r=0;if(e[t+3]===`O`&&e[t+4]===`C`&&e[t+5]===`T`&&e[t+6]===`Y`&&e[t+7]===`P`&&e[t+8]===`E`){t+=9;let i=1,a=!1,o=!1,s=``;for(;t<e.length;t++)if(e[t]===`<`&&!o){if(a&&Zc(e,`!ENTITY`,t)){t+=7;let i,a;if([i,a,t]=this.readEntityExp(e,t+1,this.suppressValidationErr),a.indexOf(`&`)===-1){if(this.options.enabled!==!1&&this.options.maxEntityCount!=null&&r>=this.options.maxEntityCount)throw Error(`Entity count (${r+1}) exceeds maximum allowed (${this.options.maxEntityCount})`);n[i]=a,r++}}else if(a&&Zc(e,`!ELEMENT`,t)){t+=8;let{index:n}=this.readElementExp(e,t+1);t=n}else if(a&&Zc(e,`!ATTLIST`,t))t+=8;else if(a&&Zc(e,`!NOTATION`,t)){t+=9;let{index:n}=this.readNotationExp(e,t+1,this.suppressValidationErr);t=n}else if(Zc(e,`!--`,t))o=!0;else throw Error(`Invalid DOCTYPE`);i++,s=``}else if(e[t]===`>`){if(o?e[t-1]===`-`&&e[t-2]===`-`&&(o=!1,i--):i--,i===0)break}else e[t]===`[`?a=!0:s+=e[t];if(i!==0)throw Error(`Unclosed DOCTYPE`)}else throw Error(`Invalid Tag instead of DOCTYPE`);return{entities:n,i:t}}readEntityExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t])&&e[t]!==`"`&&e[t]!==`'`;)t++;let r=e.substring(n,t);if(Qc(r),t=z(e,t),!this.suppressValidationErr){if(e.substring(t,t+6).toUpperCase()===`SYSTEM`)throw Error(`External entities are not supported`);if(e[t]===`%`)throw Error(`Parameter entities are not supported`)}let i=``;if([t,i]=this.readIdentifierVal(e,t,`entity`),this.options.enabled!==!1&&this.options.maxEntitySize!=null&&i.length>this.options.maxEntitySize)throw Error(`Entity "${r}" size (${i.length}) exceeds maximum allowed size (${this.options.maxEntitySize})`);return t--,[r,i,t]}readNotationExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;let r=e.substring(n,t);!this.suppressValidationErr&&Qc(r),t=z(e,t);let i=e.substring(t,t+6).toUpperCase();if(!this.suppressValidationErr&&i!==`SYSTEM`&&i!==`PUBLIC`)throw Error(`Expected SYSTEM or PUBLIC, found "${i}"`);t+=i.length,t=z(e,t);let a=null,o=null;if(i===`PUBLIC`)[t,a]=this.readIdentifierVal(e,t,`publicIdentifier`),t=z(e,t),(e[t]===`"`||e[t]===`'`)&&([t,o]=this.readIdentifierVal(e,t,`systemIdentifier`));else if(i===`SYSTEM`&&([t,o]=this.readIdentifierVal(e,t,`systemIdentifier`),!this.suppressValidationErr&&!o))throw Error(`Missing mandatory system identifier for SYSTEM notation`);return{notationName:r,publicIdentifier:a,systemIdentifier:o,index:--t}}readIdentifierVal(e,t,n){let r=``,i=e[t];if(i!==`"`&&i!==`'`)throw Error(`Expected quoted string, found "${i}"`);t++;let a=t;for(;t<e.length&&e[t]!==i;)t++;if(r=e.substring(a,t),e[t]!==i)throw Error(`Unterminated ${n} value`);return t++,[t,r]}readElementExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;let r=e.substring(n,t);if(!this.suppressValidationErr&&!nc(r))throw Error(`Invalid element name: "${r}"`);t=z(e,t);let i=``;if(e[t]===`E`&&Zc(e,`MPTY`,t))t+=4;else if(e[t]===`A`&&Zc(e,`NY`,t))t+=2;else if(e[t]===`(`){t++;let n=t;for(;t<e.length&&e[t]!==`)`;)t++;if(i=e.substring(n,t),e[t]!==`)`)throw Error(`Unterminated content model`)}else if(!this.suppressValidationErr)throw Error(`Invalid Element Expression, found "${e[t]}"`);return{elementName:r,contentModel:i.trim(),index:t}}readAttlistExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;let r=e.substring(n,t);for(Qc(r),t=z(e,t),n=t;t<e.length&&!/\s/.test(e[t]);)t++;let i=e.substring(n,t);if(!Qc(i))throw Error(`Invalid attribute name: "${i}"`);t=z(e,t);let a=``;if(e.substring(t,t+8).toUpperCase()===`NOTATION`){if(a=`NOTATION`,t+=8,t=z(e,t),e[t]!==`(`)throw Error(`Expected '(', found "${e[t]}"`);t++;let n=[];for(;t<e.length&&e[t]!==`)`;){let r=t;for(;t<e.length&&e[t]!==`|`&&e[t]!==`)`;)t++;let i=e.substring(r,t);if(i=i.trim(),!Qc(i))throw Error(`Invalid notation name: "${i}"`);n.push(i),e[t]===`|`&&(t++,t=z(e,t))}if(e[t]!==`)`)throw Error(`Unterminated list of notations`);t++,a+=` (`+n.join(`|`)+`)`}else{let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;if(a+=e.substring(n,t),!this.suppressValidationErr&&![`CDATA`,`ID`,`IDREF`,`IDREFS`,`ENTITY`,`ENTITIES`,`NMTOKEN`,`NMTOKENS`].includes(a.toUpperCase()))throw Error(`Invalid attribute type: "${a}"`)}t=z(e,t);let o=``;return e.substring(t,t+8).toUpperCase()===`#REQUIRED`?(o=`#REQUIRED`,t+=8):e.substring(t,t+7).toUpperCase()===`#IMPLIED`?(o=`#IMPLIED`,t+=7):[t,o]=this.readIdentifierVal(e,t,`ATTLIST`),{elementName:r,attributeName:i,attributeType:a,defaultValue:o,index:t}}};let z=(e,t)=>{for(;t<e.length&&/\s/.test(e[t]);)t++;return t};function Zc(e,t,n){for(let r=0;r<t.length;r++)if(t[r]!==e[n+r+1])return!1;return!0}function Qc(e){if(nc(e))return e;throw Error(`Invalid entity name ${e}`)}let $c=/^[-+]?0x[a-fA-F0-9]+$/,el=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,tl={hex:!0,leadingZeros:!0,decimalPoint:`.`,eNotation:!0,infinity:`original`};function nl(e,t={}){if(t=Object.assign({},tl,t),!e||typeof e!=`string`)return e;let n=e.trim();if(n.length===0||t.skipLike!==void 0&&t.skipLike.test(n))return e;if(n===`0`)return 0;if(t.hex&&$c.test(n))return ol(n,16);if(!isFinite(n))return sl(e,Number(n),t);if(n.includes(`e`)||n.includes(`E`))return il(e,n,t);{let r=el.exec(n);if(r){let i=r[1]||``,a=r[2],o=al(r[3]),s=i?e[a.length+1]===`.`:e[a.length]===`.`;if(!t.leadingZeros&&(a.length>1||a.length===1&&!s))return e;{let r=Number(n),s=String(r);if(r===0)return r;if(s.search(/[eE]/)!==-1)return t.eNotation?r:e;if(n.indexOf(`.`)!==-1)return s===`0`||s===o||s===`${i}${o}`?r:e;let c=a?o:n;return a?c===s||i+c===s?r:e:c===s||c===i+s?r:e}}else return e}}let rl=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function il(e,t,n){if(!n.eNotation)return e;let r=t.match(rl);if(r){let i=r[1]||``,a=r[3].indexOf(`e`)===-1?`E`:`e`,o=r[2],s=i?e[o.length+1]===a:e[o.length]===a;return o.length>1&&s?e:o.length===1&&(r[3].startsWith(`.${a}`)||r[3][0]===a)?Number(t):o.length>0?n.leadingZeros&&!s?(t=(r[1]||``)+r[3],Number(t)):e:Number(t)}else return e}function al(e){return e&&e.indexOf(`.`)!==-1?(e=e.replace(/0+$/,``),e===`.`?e=`0`:e[0]===`.`?e=`0`+e:e[e.length-1]===`.`&&(e=e.substring(0,e.length-1)),e):e}function ol(e,t){if(parseInt)return parseInt(e,t);if(Number.parseInt)return Number.parseInt(e,t);if(window&&window.parseInt)return window.parseInt(e,t);throw Error(`parseInt, Number.parseInt, window.parseInt are not supported`)}function sl(e,t,n){let r=t===1/0;switch(n.infinity.toLowerCase()){case`null`:return null;case`infinity`:return t;case`string`:return r?`Infinity`:`-Infinity`;default:return e}}function cl(e){return typeof e==`function`?e:Array.isArray(e)?t=>{for(let n of e)if(typeof n==`string`&&t===n||n instanceof RegExp&&n.test(t))return!0}:()=>!1}var ll=class{constructor(e,t={},n){this.pattern=e,this.separator=t.separator||`.`,this.segments=this._parse(e),this.data=n,this._hasDeepWildcard=this.segments.some(e=>e.type===`deep-wildcard`),this._hasAttributeCondition=this.segments.some(e=>e.attrName!==void 0),this._hasPositionSelector=this.segments.some(e=>e.position!==void 0)}_parse(e){let t=[],n=0,r=``;for(;n<e.length;)e[n]===this.separator?n+1<e.length&&e[n+1]===this.separator?(r.trim()&&(t.push(this._parseSegment(r.trim())),r=``),t.push({type:`deep-wildcard`}),n+=2):(r.trim()&&t.push(this._parseSegment(r.trim())),r=``,n++):(r+=e[n],n++);return r.trim()&&t.push(this._parseSegment(r.trim())),t}_parseSegment(e){let t={type:`tag`},n=null,r=e,i=e.match(/^([^\[]+)(\[[^\]]*\])(.*)$/);if(i&&(r=i[1]+i[3],i[2])){let e=i[2].slice(1,-1);e&&(n=e)}let a,o=r;if(r.includes(`::`)){let t=r.indexOf(`::`);if(a=r.substring(0,t).trim(),o=r.substring(t+2).trim(),!a)throw Error(`Invalid namespace in pattern: ${e}`)}let s,c=null;if(o.includes(`:`)){let e=o.lastIndexOf(`:`),t=o.substring(0,e).trim(),n=o.substring(e+1).trim();[`first`,`last`,`odd`,`even`].includes(n)||/^nth\(\d+\)$/.test(n)?(s=t,c=n):s=o}else s=o;if(!s)throw Error(`Invalid segment pattern: ${e}`);if(t.tag=s,a&&(t.namespace=a),n)if(n.includes(`=`)){let e=n.indexOf(`=`);t.attrName=n.substring(0,e).trim(),t.attrValue=n.substring(e+1).trim()}else t.attrName=n.trim();if(c){let e=c.match(/^nth\((\d+)\)$/);e?(t.position=`nth`,t.positionValue=parseInt(e[1],10)):t.position=c}return t}get length(){return this.segments.length}hasDeepWildcard(){return this._hasDeepWildcard}hasAttributeCondition(){return this._hasAttributeCondition}hasPositionSelector(){return this._hasPositionSelector}toString(){return this.pattern}},ul=class{constructor(){this._byDepthAndTag=new Map,this._wildcardByDepth=new Map,this._deepWildcards=[],this._patterns=new Set,this._sealed=!1}add(e){if(this._sealed)throw TypeError(`ExpressionSet is sealed. Create a new ExpressionSet to add more expressions.`);if(this._patterns.has(e.pattern))return this;if(this._patterns.add(e.pattern),e.hasDeepWildcard())return this._deepWildcards.push(e),this;let t=e.length,n=e.segments[e.segments.length-1]?.tag;if(!n||n===`*`)this._wildcardByDepth.has(t)||this._wildcardByDepth.set(t,[]),this._wildcardByDepth.get(t).push(e);else{let r=`${t}:${n}`;this._byDepthAndTag.has(r)||this._byDepthAndTag.set(r,[]),this._byDepthAndTag.get(r).push(e)}return this}addAll(e){for(let t of e)this.add(t);return this}has(e){return this._patterns.has(e.pattern)}get size(){return this._patterns.size}seal(){return this._sealed=!0,this}get isSealed(){return this._sealed}matchesAny(e){return this.findMatch(e)!==null}findMatch(e){let t=e.getDepth(),n=`${t}:${e.getCurrentTag()}`,r=this._byDepthAndTag.get(n);if(r){for(let t=0;t<r.length;t++)if(e.matches(r[t]))return r[t]}let i=this._wildcardByDepth.get(t);if(i){for(let t=0;t<i.length;t++)if(e.matches(i[t]))return i[t]}for(let t=0;t<this._deepWildcards.length;t++)if(e.matches(this._deepWildcards[t]))return this._deepWildcards[t];return null}},dl=class{constructor(e){this._matcher=e}get separator(){return this._matcher.separator}getCurrentTag(){let e=this._matcher.path;return e.length>0?e[e.length-1].tag:void 0}getCurrentNamespace(){let e=this._matcher.path;return e.length>0?e[e.length-1].namespace:void 0}getAttrValue(e){let t=this._matcher.path;if(t.length!==0)return t[t.length-1].values?.[e]}hasAttr(e){let t=this._matcher.path;if(t.length===0)return!1;let n=t[t.length-1];return n.values!==void 0&&e in n.values}getPosition(){let e=this._matcher.path;return e.length===0?-1:e[e.length-1].position??0}getCounter(){let e=this._matcher.path;return e.length===0?-1:e[e.length-1].counter??0}getIndex(){return this.getPosition()}getDepth(){return this._matcher.path.length}toString(e,t=!0){return this._matcher.toString(e,t)}toArray(){return this._matcher.path.map(e=>e.tag)}matches(e){return this._matcher.matches(e)}matchesAny(e){return e.matchesAny(this._matcher)}},fl=class{constructor(e={}){this.separator=e.separator||`.`,this.path=[],this.siblingStacks=[],this._pathStringCache=null,this._view=new dl(this)}push(e,t=null,n=null){this._pathStringCache=null,this.path.length>0&&(this.path[this.path.length-1].values=void 0);let r=this.path.length;this.siblingStacks[r]||(this.siblingStacks[r]=new Map);let i=this.siblingStacks[r],a=n?`${n}:${e}`:e,o=i.get(a)||0,s=0;for(let e of i.values())s+=e;i.set(a,o+1);let c={tag:e,position:s,counter:o};n!=null&&(c.namespace=n),t!=null&&(c.values=t),this.path.push(c)}pop(){if(this.path.length===0)return;this._pathStringCache=null;let e=this.path.pop();return this.siblingStacks.length>this.path.length+1&&(this.siblingStacks.length=this.path.length+1),e}updateCurrent(e){if(this.path.length>0){let t=this.path[this.path.length-1];e!=null&&(t.values=e)}}getCurrentTag(){return this.path.length>0?this.path[this.path.length-1].tag:void 0}getCurrentNamespace(){return this.path.length>0?this.path[this.path.length-1].namespace:void 0}getAttrValue(e){if(this.path.length!==0)return this.path[this.path.length-1].values?.[e]}hasAttr(e){if(this.path.length===0)return!1;let t=this.path[this.path.length-1];return t.values!==void 0&&e in t.values}getPosition(){return this.path.length===0?-1:this.path[this.path.length-1].position??0}getCounter(){return this.path.length===0?-1:this.path[this.path.length-1].counter??0}getIndex(){return this.getPosition()}getDepth(){return this.path.length}toString(e,t=!0){let n=e||this.separator;if(n===this.separator&&t===!0){if(this._pathStringCache!==null)return this._pathStringCache;let e=this.path.map(e=>e.namespace?`${e.namespace}:${e.tag}`:e.tag).join(n);return this._pathStringCache=e,e}return this.path.map(e=>t&&e.namespace?`${e.namespace}:${e.tag}`:e.tag).join(n)}toArray(){return this.path.map(e=>e.tag)}reset(){this._pathStringCache=null,this.path=[],this.siblingStacks=[]}matches(e){let t=e.segments;return t.length===0?!1:e.hasDeepWildcard()?this._matchWithDeepWildcard(t):this._matchSimple(t)}_matchSimple(e){if(this.path.length!==e.length)return!1;for(let t=0;t<e.length;t++)if(!this._matchSegment(e[t],this.path[t],t===this.path.length-1))return!1;return!0}_matchWithDeepWildcard(e){let t=this.path.length-1,n=e.length-1;for(;n>=0&&t>=0;){let r=e[n];if(r.type===`deep-wildcard`){if(n--,n<0)return!0;let r=e[n],i=!1;for(let e=t;e>=0;e--)if(this._matchSegment(r,this.path[e],e===this.path.length-1)){t=e-1,n--,i=!0;break}if(!i)return!1}else{if(!this._matchSegment(r,this.path[t],t===this.path.length-1))return!1;t--,n--}}return n<0}_matchSegment(e,t,n){if(e.tag!==`*`&&e.tag!==t.tag||e.namespace!==void 0&&e.namespace!==`*`&&e.namespace!==t.namespace||e.attrName!==void 0&&(!n||!t.values||!(e.attrName in t.values)||e.attrValue!==void 0&&String(t.values[e.attrName])!==String(e.attrValue)))return!1;if(e.position!==void 0){if(!n)return!1;let r=t.counter??0;if(e.position===`first`&&r!==0||e.position===`odd`&&r%2!=1||e.position===`even`&&r%2!=0||e.position===`nth`&&r!==e.positionValue)return!1}return!0}matchesAny(e){return e.matchesAny(this)}snapshot(){return{path:this.path.map(e=>({...e})),siblingStacks:this.siblingStacks.map(e=>new Map(e))}}restore(e){this._pathStringCache=null,this.path=e.path.map(e=>({...e})),this.siblingStacks=e.siblingStacks.map(e=>new Map(e))}readOnly(){return this._view}};function pl(e,t){if(!e)return{};let n=t.attributesGroupName?e[t.attributesGroupName]:e;if(!n)return{};let r={};for(let e in n)if(e.startsWith(t.attributeNamePrefix)){let i=e.substring(t.attributeNamePrefix.length);r[i]=n[e]}else r[e]=n[e];return r}function ml(e){if(!e||typeof e!=`string`)return;let t=e.indexOf(`:`);if(t!==-1&&t>0){let n=e.substring(0,t);if(n!==`xmlns`)return n}}var hl=class{constructor(e){this.options=e,this.currentNode=null,this.tagsNodeStack=[],this.parseXml=bl,this.parseTextData=gl,this.resolveNameSpace=_l,this.buildAttributesMap=yl,this.isItStopNode=wl,this.replaceEntitiesValue=Sl,this.readStopNodeData=kl,this.saveTextToParentTag=Cl,this.addChild=xl,this.ignoreAttributesFn=cl(this.options.ignoreAttributes),this.entityExpansionCount=0,this.currentExpandedLength=0;let t={...Mc};this.options.entityDecoder?this.entityDecoder=this.options.entityDecoder:(typeof this.options.htmlEntities==`object`?t=this.options.htmlEntities:this.options.htmlEntities===!0&&(t={...Nc,...kc}),this.entityDecoder=new Hc({namedEntities:t,numericAllowed:this.options.htmlEntities,limit:{maxTotalExpansions:this.options.processEntities.maxTotalExpansions,maxExpandedLength:this.options.processEntities.maxExpandedLength,applyLimitsTo:this.options.processEntities.appliesTo}})),this.matcher=new fl,this.readonlyMatcher=this.matcher.readOnly(),this.isCurrentNodeStopNode=!1,this.stopNodeExpressionsSet=new ul;let n=this.options.stopNodes;if(n&&n.length>0){for(let e=0;e<n.length;e++){let t=n[e];typeof t==`string`?this.stopNodeExpressionsSet.add(new ll(t)):t instanceof ll&&this.stopNodeExpressionsSet.add(t)}this.stopNodeExpressionsSet.seal()}}};function gl(e,t,n,r,i,a,o){let s=this.options;if(e!==void 0&&(s.trimValues&&!r&&(e=e.trim()),e.length>0)){o||(e=this.replaceEntitiesValue(e,t,n));let r=s.jPath?n.toString():n,c=s.tagValueProcessor(t,e,r,i,a);return c==null?e:typeof c!=typeof e||c!==e?c:s.trimValues||e.trim()===e?Al(e,s.parseTagValue,s.numberParseOptions):e}}function _l(e){if(this.options.removeNSPrefix){let t=e.split(`:`),n=e.charAt(0)===`/`?`/`:``;if(t[0]===`xmlns`)return``;t.length===2&&(e=n+t[1])}return e}let vl=RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,`gm`);function yl(e,t,n,r=!1){let i=this.options;if(r===!0||i.ignoreAttributes!==!0&&typeof e==`string`){let r=tc(e,vl),a=r.length,o={},s=Array(a),c=!1,l={};for(let e=0;e<a;e++){let t=this.resolveNameSpace(r[e][1]),a=r[e][4];if(t.length&&a!==void 0){let r=a;i.trimValues&&(r=r.trim()),r=this.replaceEntitiesValue(r,n,this.readonlyMatcher),s[e]=r,l[t]=r,c=!0}}c&&typeof t==`object`&&t.updateCurrent&&t.updateCurrent(l);let u=i.jPath?t.toString():this.readonlyMatcher,d=!1;for(let e=0;e<a;e++){let t=this.resolveNameSpace(r[e][1]);if(this.ignoreAttributesFn(t,u))continue;let n=i.attributeNamePrefix+t;if(t.length)if(i.transformAttributeName&&(n=i.transformAttributeName(n)),n=Ml(n,i),r[e][4]!==void 0){let r=s[e],a=i.attributeValueProcessor(t,r,u);a==null?o[n]=r:typeof a!=typeof r||a!==r?o[n]=a:o[n]=Al(r,i.parseAttributeValue,i.numberParseOptions),d=!0}else i.allowBooleanAttributes&&(o[n]=!0,d=!0)}if(!d)return;if(i.attributesGroupName){let e={};return e[i.attributesGroupName]=o,e}return o}}let bl=function(e){e=e.replace(/\r\n?/g,`
12
- `);let t=new Yc(`!xml`),n=t,r=``;this.matcher.reset(),this.entityDecoder.reset(),this.entityExpansionCount=0,this.currentExpandedLength=0;let i=this.options,a=new Xc(i.processEntities),o=e.length;for(let s=0;s<o;s++)if(e[s]===`<`){let c=e.charCodeAt(s+1);if(c===47){let t=El(e,`>`,s,`Closing Tag is not closed.`),a=e.substring(s+2,t).trim();if(i.removeNSPrefix){let e=a.indexOf(`:`);e!==-1&&(a=a.substr(e+1))}a=jl(i.transformTagName,a,``,i).tagName,n&&(r=this.saveTextToParentTag(r,n,this.readonlyMatcher));let o=this.matcher.getCurrentTag();if(a&&i.unpairedTagsSet.has(a))throw Error(`Unpaired tag can not be used as closing tag: </${a}>`);o&&i.unpairedTagsSet.has(o)&&(this.matcher.pop(),this.tagsNodeStack.pop()),this.matcher.pop(),this.isCurrentNodeStopNode=!1,n=this.tagsNodeStack.pop(),r=``,s=t}else if(c===63){let t=Ol(e,s,!1,`?>`);if(!t)throw Error(`Pi Tag is not closed.`);r=this.saveTextToParentTag(r,n,this.readonlyMatcher);let a=this.buildAttributesMap(t.tagExp,this.matcher,t.tagName,!0);if(a){let e=a[this.options.attributeNamePrefix+`version`];this.entityDecoder.setXmlVersion(Number(e)||1)}if(!(i.ignoreDeclaration&&t.tagName===`?xml`||i.ignorePiTags)){let e=new Yc(t.tagName);e.add(i.textNodeName,``),t.tagName!==t.tagExp&&t.attrExpPresent&&i.ignoreAttributes!==!0&&(e[`:@`]=a),this.addChild(n,e,this.readonlyMatcher,s)}s=t.closeIndex+1}else if(c===33&&e.charCodeAt(s+2)===45&&e.charCodeAt(s+3)===45){let t=El(e,`-->`,s+4,`Comment is not closed.`);if(i.commentPropName){let a=e.substring(s+4,t-2);r=this.saveTextToParentTag(r,n,this.readonlyMatcher),n.add(i.commentPropName,[{[i.textNodeName]:a}])}s=t}else if(c===33&&e.charCodeAt(s+2)===68){let t=a.readDocType(e,s);this.entityDecoder.addInputEntities(t.entities),s=t.i}else if(c===33&&e.charCodeAt(s+2)===91){let t=El(e,`]]>`,s,`CDATA is not closed.`)-2,a=e.substring(s+9,t);r=this.saveTextToParentTag(r,n,this.readonlyMatcher);let o=this.parseTextData(a,n.tagname,this.readonlyMatcher,!0,!1,!0,!0);o??=``,i.cdataPropName?n.add(i.cdataPropName,[{[i.textNodeName]:a}]):n.add(i.textNodeName,o),s=t+2}else{let a=Ol(e,s,i.removeNSPrefix);if(!a){let t=e.substring(Math.max(0,s-50),Math.min(o,s+50));throw Error(`readTagExp returned undefined at position ${s}. Context: "${t}"`)}let c=a.tagName,l=a.rawTagName,u=a.tagExp,d=a.attrExpPresent,f=a.closeIndex;if({tagName:c,tagExp:u}=jl(i.transformTagName,c,u,i),i.strictReservedNames&&(c===i.commentPropName||c===i.cdataPropName||c===i.textNodeName||c===i.attributesGroupName))throw Error(`Invalid tag name: ${c}`);n&&r&&n.tagname!==`!xml`&&(r=this.saveTextToParentTag(r,n,this.readonlyMatcher,!1));let p=n;p&&i.unpairedTagsSet.has(p.tagname)&&(n=this.tagsNodeStack.pop(),this.matcher.pop());let m=!1;u.length>0&&u.lastIndexOf(`/`)===u.length-1&&(m=!0,c[c.length-1]===`/`?(c=c.substr(0,c.length-1),u=c):u=u.substr(0,u.length-1),d=c!==u);let h=null,g;g=ml(l),c!==t.tagname&&this.matcher.push(c,{},g),c!==u&&d&&(h=this.buildAttributesMap(u,this.matcher,c),h&&pl(h,i)),c!==t.tagname&&(this.isCurrentNodeStopNode=this.isItStopNode());let _=s;if(this.isCurrentNodeStopNode){let t=``;if(m)s=a.closeIndex;else if(i.unpairedTagsSet.has(c))s=a.closeIndex;else{let n=this.readStopNodeData(e,l,f+1);if(!n)throw Error(`Unexpected end of ${l}`);s=n.i,t=n.tagContent}let r=new Yc(c);h&&(r[`:@`]=h),r.add(i.textNodeName,t),this.matcher.pop(),this.isCurrentNodeStopNode=!1,this.addChild(n,r,this.readonlyMatcher,_)}else{if(m){({tagName:c,tagExp:u}=jl(i.transformTagName,c,u,i));let e=new Yc(c);h&&(e[`:@`]=h),this.addChild(n,e,this.readonlyMatcher,_),this.matcher.pop(),this.isCurrentNodeStopNode=!1}else if(i.unpairedTagsSet.has(c)){let e=new Yc(c);h&&(e[`:@`]=h),this.addChild(n,e,this.readonlyMatcher,_),this.matcher.pop(),this.isCurrentNodeStopNode=!1,s=a.closeIndex;continue}else{let e=new Yc(c);if(this.tagsNodeStack.length>i.maxNestedTags)throw Error(`Maximum nested tags exceeded`);this.tagsNodeStack.push(n),h&&(e[`:@`]=h),this.addChild(n,e,this.readonlyMatcher,_),n=e}r=``,s=f}}}else r+=e[s];return t.child};function xl(e,t,n,r){this.options.captureMetaData||(r=void 0);let i=this.options.jPath?n.toString():n,a=this.options.updateTag(t.tagname,i,t[`:@`]);a===!1||(typeof a==`string`&&(t.tagname=a),e.addChild(t,r))}function Sl(e,t,n){let r=this.options.processEntities;if(!r||!r.enabled)return e;if(r.allowedTags){let i=this.options.jPath?n.toString():n;if(!(Array.isArray(r.allowedTags)?r.allowedTags.includes(t):r.allowedTags(t,i)))return e}if(r.tagFilter){let i=this.options.jPath?n.toString():n;if(!r.tagFilter(t,i))return e}return this.entityDecoder.decode(e)}function Cl(e,t,n,r){return e&&=(r===void 0&&(r=t.child.length===0),e=this.parseTextData(e,t.tagname,n,!1,t[`:@`]?Object.keys(t[`:@`]).length!==0:!1,r),e!==void 0&&e!==``&&t.add(this.options.textNodeName,e),``),e}function wl(){return this.stopNodeExpressionsSet.size===0?!1:this.matcher.matchesAny(this.stopNodeExpressionsSet)}function Tl(e,t,n=`>`){let r=0,i=[],a=e.length,o=n.charCodeAt(0),s=n.length>1?n.charCodeAt(1):-1;for(let n=t;n<a;n++){let t=e.charCodeAt(n);if(r)t===r&&(r=0);else if(t===34||t===39)r=t;else if(t===o)if(s!==-1){if(e.charCodeAt(n+1)===s)return{data:String.fromCharCode(...i),index:n}}else return{data:String.fromCharCode(...i),index:n};else if(t===9){i.push(32);continue}i.push(t)}}function El(e,t,n,r){let i=e.indexOf(t,n);if(i===-1)throw Error(r);return i+t.length-1}function Dl(e,t,n,r){let i=e.indexOf(t,n);if(i===-1)throw Error(r);return i}function Ol(e,t,n,r=`>`){let i=Tl(e,t+1,r);if(!i)return;let a=i.data,o=i.index,s=a.search(/\s/),c=a,l=!0;s!==-1&&(c=a.substring(0,s),a=a.substring(s+1).trimStart());let u=c;if(n){let e=c.indexOf(`:`);e!==-1&&(c=c.substr(e+1),l=c!==i.data.substr(e+1))}return{tagName:c,tagExp:a,closeIndex:o,attrExpPresent:l,rawTagName:u}}function kl(e,t,n){let r=n,i=1,a=e.length;for(;n<a;n++)if(e[n]===`<`){let a=e.charCodeAt(n+1);if(a===47){let a=Dl(e,`>`,n,`${t} is not closed`);if(e.substring(n+2,a).trim()===t&&(i--,i===0))return{tagContent:e.substring(r,n),i:a};n=a}else if(a===63)n=El(e,`?>`,n+1,`StopNode is not closed.`);else if(a===33&&e.charCodeAt(n+2)===45&&e.charCodeAt(n+3)===45)n=El(e,`-->`,n+3,`StopNode is not closed.`);else if(a===33&&e.charCodeAt(n+2)===91)n=El(e,`]]>`,n,`StopNode is not closed.`)-2;else{let r=Ol(e,n,`>`);r&&((r&&r.tagName)===t&&r.tagExp[r.tagExp.length-1]!==`/`&&i++,n=r.closeIndex)}}}function Al(e,t,n){if(t&&typeof e==`string`){let t=e.trim();return t===`true`?!0:t===`false`?!1:nl(e,n)}else if(rc(e))return e;else return``}function jl(e,t,n,r){if(e){let r=e(t);n===t&&(n=r),t=r}return t=Ml(t,r),{tagName:t,tagExp:n}}function Ml(e,t){if(ac.includes(e))throw Error(`[SECURITY] Invalid name: "${e}" is a reserved JavaScript keyword that could cause prototype pollution`);return ic.includes(e)?t.onDangerousProperty(e):e}let Nl=Yc.getMetaDataSymbol();function Pl(e,t){if(!e||typeof e!=`object`)return{};if(!t)return e;let n={};for(let r in e)if(r.startsWith(t)){let i=r.substring(t.length);n[i]=e[r]}else n[r]=e[r];return n}function Fl(e,t,n,r){return Il(e,t,n,r)}function Il(e,t,n,r){let i,a={};for(let o=0;o<e.length;o++){let s=e[o],c=Ll(s);if(c!==void 0&&c!==t.textNodeName){let e=Pl(s[`:@`]||{},t.attributeNamePrefix);n.push(c,e)}if(c===t.textNodeName)i===void 0?i=s[c]:i+=``+s[c];else if(c===void 0)continue;else if(s[c]){let e=Il(s[c],t,n,r),i=zl(e,t);if(s[`:@`]?Rl(e,s[`:@`],r,t):Object.keys(e).length===1&&e[t.textNodeName]!==void 0&&!t.alwaysCreateTextNode?e=e[t.textNodeName]:Object.keys(e).length===0&&(t.alwaysCreateTextNode?e[t.textNodeName]=``:e=``),s[Nl]!==void 0&&typeof e==`object`&&e&&(e[Nl]=s[Nl]),a[c]!==void 0&&Object.prototype.hasOwnProperty.call(a,c))Array.isArray(a[c])||(a[c]=[a[c]]),a[c].push(e);else{let n=t.jPath?r.toString():r;t.isArray(c,n,i)?a[c]=[e]:a[c]=e}c!==void 0&&c!==t.textNodeName&&n.pop()}}return typeof i==`string`?i.length>0&&(a[t.textNodeName]=i):i!==void 0&&(a[t.textNodeName]=i),a}function Ll(e){let t=Object.keys(e);for(let e=0;e<t.length;e++){let n=t[e];if(n!==`:@`)return n}}function Rl(e,t,n,r){if(t){let i=Object.keys(t),a=i.length;for(let o=0;o<a;o++){let a=i[o],s=a.startsWith(r.attributeNamePrefix)?a.substring(r.attributeNamePrefix.length):a,c=r.jPath?n.toString()+`.`+s:n;r.isArray(a,c,!0,!0)?e[a]=[t[a]]:e[a]=t[a]}}}function zl(e,t){let{textNodeName:n}=t,r=Object.keys(e).length;return!!(r===0||r===1&&(e[n]||typeof e[n]==`boolean`||e[n]===0))}var Bl=class{constructor(e){this.externalEntities={},this.options=qc(e)}parse(e,t){if(typeof e!=`string`&&e.toString)e=e.toString();else if(typeof e!=`string`)throw Error(`XML data is accepted in String or Bytes[] form.`);if(t){t===!0&&(t={});let n=sc(e,t);if(n!==!0)throw Error(`${n.err.msg}:${n.err.line}:${n.err.col}`)}let n=new hl(this.options);n.entityDecoder.setExternalEntities(this.externalEntities);let r=n.parseXml(e);return this.options.preserveOrder||r===void 0?r:Fl(r,this.options,n.matcher,n.readonlyMatcher)}addEntity(e,t){if(t.indexOf(`&`)!==-1)throw Error(`Entity value can't have '&'`);if(e.indexOf(`&`)!==-1||e.indexOf(`;`)!==-1)throw Error(`An entity must be set without '&' and ';'. Eg. use '#xD' for '&#xD;'`);if(t===`&`)throw Error(`An entity with value '&' is not permitted`);this.externalEntities[e]=t}static getMetaDataSymbol(){return Yc.getMetaDataSymbol()}};function Vl(e,t){let n=``;t.format&&t.indentBy.length>0&&(n=`
11
+ `||e===`\r`}function lc(e,t){let n=t;for(;t<e.length;t++)if(e[t]==`?`||e[t]==` `){let r=e.substr(n,t-n);if(t>5&&r===`xml`)return I(`InvalidXml`,`XML declaration allowed only at the start of the document.`,L(e,t));if(e[t]==`?`&&e[t+1]==`>`){t++;break}else continue}return t}function uc(e,t){if(e.length>t+5&&e[t+1]===`-`&&e[t+2]===`-`){for(t+=3;t<e.length;t++)if(e[t]===`-`&&e[t+1]===`-`&&e[t+2]===`>`){t+=2;break}}else if(e.length>t+8&&e[t+1]===`D`&&e[t+2]===`O`&&e[t+3]===`C`&&e[t+4]===`T`&&e[t+5]===`Y`&&e[t+6]===`P`&&e[t+7]===`E`){let n=1;for(t+=8;t<e.length;t++)if(e[t]===`<`)n++;else if(e[t]===`>`&&(n--,n===0))break}else if(e.length>t+9&&e[t+1]===`[`&&e[t+2]===`C`&&e[t+3]===`D`&&e[t+4]===`A`&&e[t+5]===`T`&&e[t+6]===`A`&&e[t+7]===`[`){for(t+=8;t<e.length;t++)if(e[t]===`]`&&e[t+1]===`]`&&e[t+2]===`>`){t+=2;break}}return t}function dc(e,t){let n=``,r=``,i=!1;for(;t<e.length;t++){if(e[t]===`"`||e[t]===`'`)r===``?r=e[t]:r!==e[t]||(r=``);else if(e[t]===`>`&&r===``){i=!0;break}n+=e[t]}return r===``?{value:n,index:t,tagClosed:i}:!1}let fc=RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,`g`);function pc(e,t){let n=tc(e,fc),r={};for(let e=0;e<n.length;e++){if(n[e][1].length===0)return I(`InvalidAttr`,`Attribute '`+n[e][2]+`' has no space in starting.`,vc(n[e]));if(n[e][3]!==void 0&&n[e][4]===void 0)return I(`InvalidAttr`,`Attribute '`+n[e][2]+`' is without value.`,vc(n[e]));if(n[e][3]===void 0&&!t.allowBooleanAttributes)return I(`InvalidAttr`,`boolean attribute '`+n[e][2]+`' is not allowed.`,vc(n[e]));let i=n[e][2];if(!gc(i))return I(`InvalidAttr`,`Attribute '`+i+`' is an invalid name.`,vc(n[e]));if(!Object.prototype.hasOwnProperty.call(r,i))r[i]=1;else return I(`InvalidAttr`,`Attribute '`+i+`' is repeated.`,vc(n[e]))}return!0}function mc(e,t){let n=/\d/;for(e[t]===`x`&&(t++,n=/[\da-fA-F]/);t<e.length;t++){if(e[t]===`;`)return t;if(!e[t].match(n))break}return-1}function hc(e,t){if(t++,e[t]===`;`)return-1;if(e[t]===`#`)return t++,mc(e,t);let n=0;for(;t<e.length;t++,n++)if(!(e[t].match(/\w/)&&n<20)){if(e[t]===`;`)break;return-1}return t}function I(e,t,n){return{err:{code:e,msg:t,line:n.line||n,col:n.col}}}function gc(e){return nc(e)}function _c(e){return nc(e)}function L(e,t){let n=e.substring(0,t).split(/\r?\n/);return{line:n.length,col:n[n.length-1].length+1}}function vc(e){return e.startIndex+e[1].length}let yc={amp:`&`,AMP:`&`,lt:`<`,LT:`<`,gt:`>`,GT:`>`,quot:`"`,QUOT:`"`,apos:`'`,lsquo:`‘`,rsquo:`’`,ldquo:`“`,rdquo:`”`,lsquor:`‚`,rsquor:`’`,ldquor:`„`,bdquo:`„`,comma:`,`,period:`.`,colon:`:`,semi:`;`,excl:`!`,quest:`?`,num:`#`,dollar:`$`,percent:`%`,amp:`&`,ast:`*`,commat:`@`,lowbar:`_`,verbar:`|`,vert:`|`,sol:`/`,bsol:`\\`,lbrace:`{`,rbrace:`}`,lbrack:`[`,rbrack:`]`,lpar:`(`,rpar:`)`,nbsp:`\xA0`,iexcl:`¡`,cent:`¢`,pound:`£`,curren:`¤`,yen:`¥`,brvbar:`¦`,sect:`§`,uml:`¨`,copy:`©`,COPY:`©`,ordf:`ª`,laquo:`«`,not:`¬`,shy:`­`,reg:`®`,REG:`®`,macr:`¯`,deg:`°`,plusmn:`±`,sup2:`²`,sup3:`³`,acute:`´`,micro:`µ`,para:`¶`,middot:`·`,cedil:`¸`,sup1:`¹`,ordm:`º`,raquo:`»`,frac14:`¼`,frac12:`½`,half:`½`,frac34:`¾`,iquest:`¿`,times:`×`,div:`÷`,divide:`÷`},bc={Agrave:`À`,agrave:`à`,Aacute:`Á`,aacute:`á`,Acirc:`Â`,acirc:`â`,Atilde:`Ã`,atilde:`ã`,Auml:`Ä`,auml:`ä`,Aring:`Å`,aring:`å`,AElig:`Æ`,aelig:`æ`,Ccedil:`Ç`,ccedil:`ç`,Egrave:`È`,egrave:`è`,Eacute:`É`,eacute:`é`,Ecirc:`Ê`,ecirc:`ê`,Euml:`Ë`,euml:`ë`,Igrave:`Ì`,igrave:`ì`,Iacute:`Í`,iacute:`í`,Icirc:`Î`,icirc:`î`,Iuml:`Ï`,iuml:`ï`,ETH:`Ð`,eth:`ð`,Ntilde:`Ñ`,ntilde:`ñ`,Ograve:`Ò`,ograve:`ò`,Oacute:`Ó`,oacute:`ó`,Ocirc:`Ô`,ocirc:`ô`,Otilde:`Õ`,otilde:`õ`,Ouml:`Ö`,ouml:`ö`,Oslash:`Ø`,oslash:`ø`,Ugrave:`Ù`,ugrave:`ù`,Uacute:`Ú`,uacute:`ú`,Ucirc:`Û`,ucirc:`û`,Uuml:`Ü`,uuml:`ü`,Yacute:`Ý`,yacute:`ý`,THORN:`Þ`,thorn:`þ`,szlig:`ß`,yuml:`ÿ`,Yuml:`Ÿ`},xc={Amacr:`Ā`,amacr:`ā`,Abreve:`Ă`,abreve:`ă`,Aogon:`Ą`,aogon:`ą`,Cacute:`Ć`,cacute:`ć`,Ccirc:`Ĉ`,ccirc:`ĉ`,Cdot:`Ċ`,cdot:`ċ`,Ccaron:`Č`,ccaron:`č`,Dcaron:`Ď`,dcaron:`ď`,Dstrok:`Đ`,dstrok:`đ`,Emacr:`Ē`,emacr:`ē`,Ecaron:`Ě`,ecaron:`ě`,Edot:`Ė`,edot:`ė`,Eogon:`Ę`,eogon:`ę`,Gcirc:`Ĝ`,gcirc:`ĝ`,Gbreve:`Ğ`,gbreve:`ğ`,Gdot:`Ġ`,gdot:`ġ`,Gcedil:`Ģ`,Hcirc:`Ĥ`,hcirc:`ĥ`,Hstrok:`Ħ`,hstrok:`ħ`,Itilde:`Ĩ`,itilde:`ĩ`,Imacr:`Ī`,imacr:`ī`,Iogon:`Į`,iogon:`į`,Idot:`İ`,IJlig:`IJ`,ijlig:`ij`,Jcirc:`Ĵ`,jcirc:`ĵ`,Kcedil:`Ķ`,kcedil:`ķ`,kgreen:`ĸ`,Lacute:`Ĺ`,lacute:`ĺ`,Lcedil:`Ļ`,lcedil:`ļ`,Lcaron:`Ľ`,lcaron:`ľ`,Lmidot:`Ŀ`,lmidot:`ŀ`,Lstrok:`Ł`,lstrok:`ł`,Nacute:`Ń`,nacute:`ń`,Ncaron:`Ň`,ncaron:`ň`,Ncedil:`Ņ`,ncedil:`ņ`,ENG:`Ŋ`,eng:`ŋ`,Omacr:`Ō`,omacr:`ō`,Odblac:`Ő`,odblac:`ő`,OElig:`Œ`,oelig:`œ`,Racute:`Ŕ`,racute:`ŕ`,Rcaron:`Ř`,rcaron:`ř`,Rcedil:`Ŗ`,rcedil:`ŗ`,Sacute:`Ś`,sacute:`ś`,Scirc:`Ŝ`,scirc:`ŝ`,Scedil:`Ş`,scedil:`ş`,Scaron:`Š`,scaron:`š`,Tcedil:`Ţ`,tcedil:`ţ`,Tcaron:`Ť`,tcaron:`ť`,Tstrok:`Ŧ`,tstrok:`ŧ`,Utilde:`Ũ`,utilde:`ũ`,Umacr:`Ū`,umacr:`ū`,Ubreve:`Ŭ`,ubreve:`ŭ`,Uring:`Ů`,uring:`ů`,Udblac:`Ű`,udblac:`ű`,Uogon:`Ų`,uogon:`ų`,Wcirc:`Ŵ`,wcirc:`ŵ`,Ycirc:`Ŷ`,ycirc:`ŷ`,Zacute:`Ź`,zacute:`ź`,Zdot:`Ż`,zdot:`ż`,Zcaron:`Ž`,zcaron:`ž`},Sc={Alpha:`Α`,alpha:`α`,Beta:`Β`,beta:`β`,Gamma:`Γ`,gamma:`γ`,Delta:`Δ`,delta:`δ`,Epsilon:`Ε`,epsilon:`ε`,epsiv:`ϵ`,varepsilon:`ϵ`,Zeta:`Ζ`,zeta:`ζ`,Eta:`Η`,eta:`η`,Theta:`Θ`,theta:`θ`,thetasym:`ϑ`,vartheta:`ϑ`,Iota:`Ι`,iota:`ι`,Kappa:`Κ`,kappa:`κ`,kappav:`ϰ`,varkappa:`ϰ`,Lambda:`Λ`,lambda:`λ`,Mu:`Μ`,mu:`μ`,Nu:`Ν`,nu:`ν`,Xi:`Ξ`,xi:`ξ`,Omicron:`Ο`,omicron:`ο`,Pi:`Π`,pi:`π`,piv:`ϖ`,varpi:`ϖ`,Rho:`Ρ`,rho:`ρ`,rhov:`ϱ`,varrho:`ϱ`,Sigma:`Σ`,sigma:`σ`,sigmaf:`ς`,sigmav:`ς`,varsigma:`ς`,Tau:`Τ`,tau:`τ`,Upsilon:`Υ`,upsilon:`υ`,upsi:`υ`,Upsi:`ϒ`,upsih:`ϒ`,Phi:`Φ`,phi:`φ`,phiv:`ϕ`,varphi:`ϕ`,Chi:`Χ`,chi:`χ`,Psi:`Ψ`,psi:`ψ`,Omega:`Ω`,omega:`ω`,ohm:`Ω`,Gammad:`Ϝ`,gammad:`ϝ`,digamma:`ϝ`},Cc={Afr:`𝔄`,afr:`𝔞`,Acy:`А`,acy:`а`,Bcy:`Б`,bcy:`б`,Vcy:`В`,vcy:`в`,Gcy:`Г`,gcy:`г`,Dcy:`Д`,dcy:`д`,IEcy:`Е`,iecy:`е`,IOcy:`Ё`,iocy:`ё`,ZHcy:`Ж`,zhcy:`ж`,Zcy:`З`,zcy:`з`,Icy:`И`,icy:`и`,Jcy:`Й`,jcy:`й`,Kcy:`К`,kcy:`к`,Lcy:`Л`,lcy:`л`,Mcy:`М`,mcy:`м`,Ncy:`Н`,ncy:`н`,Ocy:`О`,ocy:`о`,Pcy:`П`,pcy:`п`,Rcy:`Р`,rcy:`р`,Scy:`С`,scy:`с`,Tcy:`Т`,tcy:`т`,Ucy:`У`,ucy:`у`,Fcy:`Ф`,fcy:`ф`,KHcy:`Х`,khcy:`х`,TScy:`Ц`,tscy:`ц`,CHcy:`Ч`,chcy:`ч`,SHcy:`Ш`,shcy:`ш`,SHCHcy:`Щ`,shchcy:`щ`,HARDcy:`Ъ`,hardcy:`ъ`,Ycy:`Ы`,ycy:`ы`,SOFTcy:`Ь`,softcy:`ь`,Ecy:`Э`,ecy:`э`,YUcy:`Ю`,yucy:`ю`,YAcy:`Я`,yacy:`я`,DJcy:`Ђ`,djcy:`ђ`,GJcy:`Ѓ`,gjcy:`ѓ`,Jukcy:`Є`,jukcy:`є`,DScy:`Ѕ`,dscy:`ѕ`,Iukcy:`І`,iukcy:`і`,YIcy:`Ї`,yicy:`ї`,Jsercy:`Ј`,jsercy:`ј`,LJcy:`Љ`,ljcy:`љ`,NJcy:`Њ`,njcy:`њ`,TSHcy:`Ћ`,tshcy:`ћ`,KJcy:`Ќ`,kjcy:`ќ`,Ubrcy:`Ў`,ubrcy:`ў`,DZcy:`Џ`,dzcy:`џ`},wc={plus:`+`,minus:`−`,mnplus:`∓`,mp:`∓`,pm:`±`,times:`×`,div:`÷`,divide:`÷`,sdot:`⋅`,star:`☆`,starf:`★`,bigstar:`★`,lowast:`∗`,ast:`*`,midast:`*`,compfn:`∘`,smallcircle:`∘`,bullet:`•`,bull:`•`,nbsp:`\xA0`,hellip:`…`,mldr:`…`,prime:`′`,Prime:`″`,tprime:`‴`,bprime:`‵`,backprime:`‵`,minus:`−`,minusd:`∸`,dotminus:`∸`,plusdo:`∔`,dotplus:`∔`,plusmn:`±`,minusplus:`∓`,mnplus:`∓`,mp:`∓`,setminus:`∖`,smallsetminus:`∖`,Backslash:`∖`,setmn:`∖`,ssetmn:`∖`,lowbar:`_`,verbar:`|`,vert:`|`,VerticalLine:`|`,colon:`:`,Colon:`∷`,Proportion:`∷`,ratio:`∶`,equals:`=`,ne:`≠`,nequiv:`≢`,equiv:`≡`,Congruent:`≡`,sim:`∼`,thicksim:`∼`,thksim:`∼`,sime:`≃`,simeq:`≃`,TildeEqual:`≃`,asymp:`≈`,approx:`≈`,thickapprox:`≈`,thkap:`≈`,TildeTilde:`≈`,ncong:`≇`,cong:`≅`,TildeFullEqual:`≅`,asympeq:`≍`,CupCap:`≍`,bump:`≎`,Bumpeq:`≎`,HumpDownHump:`≎`,bumpe:`≏`,bumpeq:`≏`,HumpEqual:`≏`,dotminus:`∸`,minusd:`∸`,plusdo:`∔`,dotplus:`∔`,le:`≤`,LessEqual:`≤`,ge:`≥`,GreaterEqual:`≥`,lesseqgtr:`⋚`,lesseqqgtr:`⪋`,greater:`>`,less:`<`},Tc={alefsym:`ℵ`,aleph:`ℵ`,beth:`ℶ`,gimel:`ℷ`,daleth:`ℸ`,forall:`∀`,ForAll:`∀`,part:`∂`,PartialD:`∂`,exist:`∃`,Exists:`∃`,nexist:`∄`,nexists:`∄`,empty:`∅`,emptyset:`∅`,emptyv:`∅`,varnothing:`∅`,nabla:`∇`,Del:`∇`,isin:`∈`,isinv:`∈`,in:`∈`,Element:`∈`,notin:`∉`,notinva:`∉`,ni:`∋`,niv:`∋`,SuchThat:`∋`,ReverseElement:`∋`,notni:`∌`,notniva:`∌`,prod:`∏`,Product:`∏`,coprod:`∐`,Coproduct:`∐`,sum:`∑`,Sum:`∑`,minus:`−`,mp:`∓`,plusdo:`∔`,dotplus:`∔`,setminus:`∖`,lowast:`∗`,radic:`√`,Sqrt:`√`,prop:`∝`,propto:`∝`,Proportional:`∝`,varpropto:`∝`,infin:`∞`,infintie:`⧝`,ang:`∠`,angle:`∠`,angmsd:`∡`,measuredangle:`∡`,angsph:`∢`,mid:`∣`,VerticalBar:`∣`,nmid:`∤`,nsmid:`∤`,npar:`∦`,parallel:`∥`,spar:`∥`,nparallel:`∦`,nspar:`∦`,and:`∧`,wedge:`∧`,or:`∨`,vee:`∨`,cap:`∩`,cup:`∪`,int:`∫`,Integral:`∫`,conint:`∮`,ContourIntegral:`∮`,Conint:`∯`,DoubleContourIntegral:`∯`,Cconint:`∰`,there4:`∴`,therefore:`∴`,Therefore:`∴`,becaus:`∵`,because:`∵`,Because:`∵`,ratio:`∶`,Proportion:`∷`,minusd:`∸`,dotminus:`∸`,mDDot:`∺`,homtht:`∻`,sim:`∼`,bsimg:`∽`,backsim:`∽`,ac:`∾`,mstpos:`∾`,acd:`∿`,VerticalTilde:`≀`,wr:`≀`,wreath:`≀`,nsime:`≄`,nsimeq:`≄`,nsimeq:`≄`,ncong:`≇`,simne:`≆`,ncongdot:`⩭̸`,ngsim:`≵`,nsim:`≁`,napprox:`≉`,nap:`≉`,ngeq:`≱`,nge:`≱`,nleq:`≰`,nle:`≰`,ngtr:`≯`,ngt:`≯`,nless:`≮`,nlt:`≮`,nprec:`⊀`,npr:`⊀`,nsucc:`⊁`,nsc:`⊁`},Ec={larr:`←`,leftarrow:`←`,LeftArrow:`←`,uarr:`↑`,uparrow:`↑`,UpArrow:`↑`,rarr:`→`,rightarrow:`→`,RightArrow:`→`,darr:`↓`,downarrow:`↓`,DownArrow:`↓`,harr:`↔`,leftrightarrow:`↔`,LeftRightArrow:`↔`,varr:`↕`,updownarrow:`↕`,UpDownArrow:`↕`,nwarr:`↖`,nwarrow:`↖`,UpperLeftArrow:`↖`,nearr:`↗`,nearrow:`↗`,UpperRightArrow:`↗`,searr:`↘`,searrow:`↘`,LowerRightArrow:`↘`,swarr:`↙`,swarrow:`↙`,LowerLeftArrow:`↙`,lArr:`⇐`,Leftarrow:`⇐`,uArr:`⇑`,Uparrow:`⇑`,rArr:`⇒`,Rightarrow:`⇒`,dArr:`⇓`,Downarrow:`⇓`,hArr:`⇔`,Leftrightarrow:`⇔`,iff:`⇔`,vArr:`⇕`,Updownarrow:`⇕`,lAarr:`⇚`,Lleftarrow:`⇚`,rAarr:`⇛`,Rrightarrow:`⇛`,lrarr:`⇆`,leftrightarrows:`⇆`,rlarr:`⇄`,rightleftarrows:`⇄`,lrhar:`⇋`,leftrightharpoons:`⇋`,ReverseEquilibrium:`⇋`,rlhar:`⇌`,rightleftharpoons:`⇌`,Equilibrium:`⇌`,udarr:`⇅`,UpArrowDownArrow:`⇅`,duarr:`⇵`,DownArrowUpArrow:`⇵`,llarr:`⇇`,leftleftarrows:`⇇`,rrarr:`⇉`,rightrightarrows:`⇉`,ddarr:`⇊`,downdownarrows:`⇊`,har:`↽`,lhard:`↽`,leftharpoondown:`↽`,lharu:`↼`,leftharpoonup:`↼`,rhard:`⇁`,rightharpoondown:`⇁`,rharu:`⇀`,rightharpoonup:`⇀`,lsh:`↰`,Lsh:`↰`,rsh:`↱`,Rsh:`↱`,ldsh:`↲`,rdsh:`↳`,hookleftarrow:`↩`,hookrightarrow:`↪`,mapstoleft:`↤`,mapstoup:`↥`,map:`↦`,mapsto:`↦`,mapstodown:`↧`,crarr:`↵`,nwarrow:`↖`,nearrow:`↗`,searrow:`↘`,swarrow:`↙`,nleftarrow:`↚`,nleftrightarrow:`↮`,nrightarrow:`↛`,nrarr:`↛`,larrtl:`↢`,rarrtl:`↣`,leftarrowtail:`↢`,rightarrowtail:`↣`,twoheadleftarrow:`↞`,twoheadrightarrow:`↠`,Larr:`↞`,Rarr:`↠`,larrhk:`↩`,rarrhk:`↪`,larrlp:`↫`,looparrowleft:`↫`,rarrlp:`↬`,looparrowright:`↬`,harrw:`↭`,leftrightsquigarrow:`↭`,nrarrw:`↝̸`,rarrw:`↝`,rightsquigarrow:`↝`,larrbfs:`⤟`,rarrbfs:`⤠`,nvHarr:`⤄`,nvlArr:`⤂`,nvrArr:`⤃`,larrfs:`⤝`,rarrfs:`⤞`,Map:`⤅`,larrsim:`⥳`,rarrsim:`⥴`,harrcir:`⥈`,Uarrocir:`⥉`,lurdshar:`⥊`,ldrdhar:`⥧`,ldrushar:`⥋`,rdldhar:`⥩`,lrhard:`⥭`,rlhar:`⇌`,uharr:`↾`,uharl:`↿`,dharr:`⇂`,dharl:`⇃`,Uarr:`↟`,Darr:`↡`,zigrarr:`⇝`,nwArr:`⇖`,neArr:`⇗`,seArr:`⇘`,swArr:`⇙`,nharr:`↮`,nhArr:`⇎`,nlarr:`↚`,nlArr:`⇍`,nrarr:`↛`,nrArr:`⇏`,larrb:`⇤`,LeftArrowBar:`⇤`,rarrb:`⇥`,RightArrowBar:`⇥`},Dc={square:`□`,Square:`□`,squ:`□`,squf:`▪`,squarf:`▪`,blacksquar:`▪`,blacksquare:`▪`,FilledVerySmallSquare:`▪`,blk34:`▓`,blk12:`▒`,blk14:`░`,block:`█`,srect:`▭`,rect:`▭`,sdot:`⋅`,sdotb:`⊡`,dotsquare:`⊡`,triangle:`▵`,tri:`▵`,trine:`▵`,utri:`▵`,triangledown:`▿`,dtri:`▿`,tridown:`▿`,triangleleft:`◃`,ltri:`◃`,triangleright:`▹`,rtri:`▹`,blacktriangle:`▴`,utrif:`▴`,blacktriangledown:`▾`,dtrif:`▾`,blacktriangleleft:`◂`,ltrif:`◂`,blacktriangleright:`▸`,rtrif:`▸`,loz:`◊`,lozenge:`◊`,blacklozenge:`⧫`,lozf:`⧫`,bigcirc:`◯`,xcirc:`◯`,circ:`ˆ`,Circle:`○`,cir:`○`,o:`○`,bullet:`•`,bull:`•`,hellip:`…`,mldr:`…`,nldr:`‥`,boxh:`─`,HorizontalLine:`─`,boxv:`│`,boxdr:`┌`,boxdl:`┐`,boxur:`└`,boxul:`┘`,boxvr:`├`,boxvl:`┤`,boxhd:`┬`,boxhu:`┴`,boxvh:`┼`,boxH:`═`,boxV:`║`,boxdR:`╒`,boxDr:`╓`,boxDR:`╔`,boxDl:`╕`,boxdL:`╖`,boxDL:`╗`,boxuR:`╘`,boxUr:`╙`,boxUR:`╚`,boxUl:`╜`,boxuL:`╛`,boxUL:`╝`,boxvR:`╞`,boxVr:`╟`,boxVR:`╠`,boxVl:`╢`,boxvL:`╡`,boxVL:`╣`,boxHd:`╤`,boxhD:`╥`,boxHD:`╦`,boxHu:`╧`,boxhU:`╨`,boxHU:`╩`,boxvH:`╪`,boxVh:`╫`,boxVH:`╬`},Oc={excl:`!`,iexcl:`¡`,brvbar:`¦`,sect:`§`,uml:`¨`,copy:`©`,ordf:`ª`,laquo:`«`,not:`¬`,shy:`­`,reg:`®`,macr:`¯`,deg:`°`,plusmn:`±`,sup2:`²`,sup3:`³`,acute:`´`,micro:`µ`,para:`¶`,middot:`·`,cedil:`¸`,sup1:`¹`,ordm:`º`,raquo:`»`,frac14:`¼`,frac12:`½`,frac34:`¾`,iquest:`¿`,nbsp:`\xA0`,comma:`,`,period:`.`,colon:`:`,semi:`;`,vert:`|`,Verbar:`‖`,verbar:`|`,dblac:`˝`,circ:`ˆ`,caron:`ˇ`,breve:`˘`,dot:`˙`,ring:`˚`,ogon:`˛`,tilde:`˜`,DiacriticalGrave:"`",DiacriticalAcute:`´`,DiacriticalTilde:`˜`,DiacriticalDot:`˙`,DiacriticalDoubleAcute:`˝`,grave:"`",acute:`´`},kc={cent:`¢`,pound:`£`,curren:`¤`,yen:`¥`,euro:`€`,dollar:`$`,euro:`€`,fnof:`ƒ`,inr:`₹`,af:`؋`,birr:`ብር`,peso:`₱`,rub:`₽`,won:`₩`,yuan:`¥`,cedil:`¸`},Ac={frac12:`½`,half:`½`,frac13:`⅓`,frac14:`¼`,frac15:`⅕`,frac16:`⅙`,frac18:`⅛`,frac23:`⅔`,frac25:`⅖`,frac34:`¾`,frac35:`⅗`,frac38:`⅜`,frac45:`⅘`,frac56:`⅚`,frac58:`⅝`,frac78:`⅞`,frasl:`⁄`},jc={trade:`™`,TRADE:`™`,telrec:`⌕`,target:`⌖`,ulcorn:`⌜`,ulcorner:`⌜`,urcorn:`⌝`,urcorner:`⌝`,dlcorn:`⌞`,llcorner:`⌞`,drcorn:`⌟`,lrcorner:`⌟`,intercal:`⊺`,intcal:`⊺`,oplus:`⊕`,CirclePlus:`⊕`,ominus:`⊖`,CircleMinus:`⊖`,otimes:`⊗`,CircleTimes:`⊗`,osol:`⊘`,odot:`⊙`,CircleDot:`⊙`,oast:`⊛`,circledast:`⊛`,odash:`⊝`,circleddash:`⊝`,ocirc:`⊚`,circledcirc:`⊚`,boxplus:`⊞`,plusb:`⊞`,boxminus:`⊟`,minusb:`⊟`,boxtimes:`⊠`,timesb:`⊠`,boxdot:`⊡`,sdotb:`⊡`,veebar:`⊻`,vee:`∨`,barvee:`⊽`,and:`∧`,wedge:`∧`,Cap:`⋒`,Cup:`⋓`,Fork:`⋔`,pitchfork:`⋔`,epar:`⋕`,ltlarr:`⥶`,nvap:`≍⃒`,nvsim:`∼⃒`,nvge:`≥⃒`,nvle:`≤⃒`,nvlt:`<⃒`,nvgt:`>⃒`,nvltrie:`⊴⃒`,nvrtrie:`⊵⃒`,Vdash:`⊩`,dashv:`⊣`,vDash:`⊨`,Vdash:`⊩`,Vvdash:`⊪`,nvdash:`⊬`,nvDash:`⊭`,nVdash:`⊮`,nVDash:`⊯`};({...yc,...bc,...xc,...Sc,...Cc,...wc,...Tc,...Ec,...Dc,...Oc,...kc,...Ac,...jc});let Mc={amp:`&`,apos:`'`,gt:`>`,lt:`<`,quot:`"`},Nc={nbsp:`\xA0`,copy:`©`,reg:`®`,trade:`™`,mdash:`—`,ndash:`–`,hellip:`…`,laquo:`«`,raquo:`»`,lsquo:`‘`,rsquo:`’`,ldquo:`“`,rdquo:`”`,bull:`•`,para:`¶`,sect:`§`,deg:`°`,frac12:`½`,frac14:`¼`,frac34:`¾`},Pc=new Set(`!?\\\\/[]$%{}^&*()<>|+`);function Fc(e){if(e[0]===`#`)throw Error(`[EntityReplacer] Invalid character '#' in entity name: "${e}"`);for(let t of e)if(Pc.has(t))throw Error(`[EntityReplacer] Invalid character '${t}' in entity name: "${e}"`);return e}function Ic(...e){let t=Object.create(null);for(let n of e)if(n)for(let e of Object.keys(n)){let r=n[e];if(typeof r==`string`)t[e]=r;else if(r&&typeof r==`object`&&r.val!==void 0){let n=r.val;typeof n==`string`&&(t[e]=n)}}return t}let Lc=`external`,Rc=`base`;function zc(e){return!e||e===Lc?new Set([Lc]):e===`all`?new Set([`all`]):e===Rc?new Set([Rc]):Array.isArray(e)?new Set(e):new Set([Lc])}let R=Object.freeze({allow:0,leave:1,remove:2,throw:3}),Bc=new Set([9,10,13]);function Vc(e){if(!e)return{xmlVersion:1,onLevel:R.allow,nullLevel:R.remove};let t=e.xmlVersion===1.1?1.1:1,n=R[e.onNCR]??R.allow,r=R[e.nullNCR]??R.remove;return{xmlVersion:t,onLevel:n,nullLevel:Math.max(r,R.remove)}}var Hc=class{constructor(e={}){this._limit=e.limit||{},this._maxTotalExpansions=this._limit.maxTotalExpansions||0,this._maxExpandedLength=this._limit.maxExpandedLength||0,this._postCheck=typeof e.postCheck==`function`?e.postCheck:e=>e,this._limitTiers=zc(this._limit.applyLimitsTo??Lc),this._numericAllowed=e.numericAllowed??!0,this._baseMap=Ic(Mc,e.namedEntities||null),this._externalMap=Object.create(null),this._inputMap=Object.create(null),this._totalExpansions=0,this._expandedLength=0,this._removeSet=new Set(e.remove&&Array.isArray(e.remove)?e.remove:[]),this._leaveSet=new Set(e.leave&&Array.isArray(e.leave)?e.leave:[]);let t=Vc(e.ncr);this._ncrXmlVersion=t.xmlVersion,this._ncrOnLevel=t.onLevel,this._ncrNullLevel=t.nullLevel}setExternalEntities(e){if(e)for(let t of Object.keys(e))Fc(t);this._externalMap=Ic(e)}addExternalEntity(e,t){Fc(e),typeof t==`string`&&t.indexOf(`&`)===-1&&(this._externalMap[e]=t)}addInputEntities(e){this._totalExpansions=0,this._expandedLength=0,this._inputMap=Ic(e)}reset(){return this._inputMap=Object.create(null),this._totalExpansions=0,this._expandedLength=0,this}setXmlVersion(e){this._ncrXmlVersion=e===1.1?1.1:1}decode(e){if(typeof e!=`string`||e.length===0)return e;let t=e,n=[],r=e.length,i=0,a=0,o=this._maxTotalExpansions>0,s=this._maxExpandedLength>0,c=o||s;for(;a<r;){if(e.charCodeAt(a)!==38){a++;continue}let t=a+1;for(;t<r&&e.charCodeAt(t)!==59&&t-a<=32;)t++;if(t>=r||e.charCodeAt(t)!==59){a++;continue}let l=e.slice(a+1,t);if(l.length===0){a++;continue}let u,d;if(this._removeSet.has(l))u=``,d===void 0&&(d=Lc);else if(this._leaveSet.has(l)){a++;continue}else if(l.charCodeAt(0)===35){let e=this._resolveNCR(l);if(e===void 0){a++;continue}u=e,d=Rc}else{let e=this._resolveName(l);u=e?.value,d=e?.tier}if(u===void 0){a++;continue}if(a>i&&n.push(e.slice(i,a)),n.push(u),i=t+1,a=i,c&&this._tierCounts(d)){if(o&&(this._totalExpansions++,this._totalExpansions>this._maxTotalExpansions))throw Error(`[EntityReplacer] Entity expansion count limit exceeded: ${this._totalExpansions} > ${this._maxTotalExpansions}`);if(s){let e=u.length-(l.length+2);if(e>0&&(this._expandedLength+=e,this._expandedLength>this._maxExpandedLength))throw Error(`[EntityReplacer] Expanded content length limit exceeded: ${this._expandedLength} > ${this._maxExpandedLength}`)}}}i<r&&n.push(e.slice(i));let l=n.length===0?e:n.join(``);return this._postCheck(l,t)}_tierCounts(e){return this._limitTiers.has(`all`)?!0:this._limitTiers.has(e)}_resolveName(e){if(e in this._inputMap)return{value:this._inputMap[e],tier:Lc};if(e in this._externalMap)return{value:this._externalMap[e],tier:Lc};if(e in this._baseMap)return{value:this._baseMap[e],tier:Rc}}_classifyNCR(e){return e===0?this._ncrNullLevel:e>=55296&&e<=57343||this._ncrXmlVersion===1&&e>=1&&e<=31&&!Bc.has(e)?R.remove:-1}_applyNCRAction(e,t,n){switch(e){case R.allow:return String.fromCodePoint(n);case R.remove:return``;case R.leave:return;case R.throw:throw Error(`[EntityDecoder] Prohibited numeric character reference &${t}; (U+${n.toString(16).toUpperCase().padStart(4,`0`)})`);default:return String.fromCodePoint(n)}}_resolveNCR(e){let t=e.charCodeAt(1),n;if(n=t===120||t===88?parseInt(e.slice(2),16):parseInt(e.slice(1),10),Number.isNaN(n)||n<0||n>1114111)return;let r=this._classifyNCR(n);if(!this._numericAllowed&&r<R.remove)return;let i=r===-1?this._ncrOnLevel:Math.max(this._ncrOnLevel,r);return this._applyNCRAction(i,e,n)}};let Uc=e=>ic.includes(e)?`__`+e:e,Wc={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(e,t){return t},attributeValueProcessor:function(e,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,entityDecoder:null,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(e,t,n){return e},captureMetaData:!1,maxNestedTags:100,strictReservedNames:!0,jPath:!0,onDangerousProperty:Uc};function Gc(e,t){if(typeof e!=`string`)return;let n=e.toLowerCase();if(ic.some(e=>n===e.toLowerCase())||ac.some(e=>n===e.toLowerCase()))throw Error(`[SECURITY] Invalid ${t}: "${e}" is a reserved JavaScript keyword that could cause prototype pollution`)}function Kc(e,t){return typeof e==`boolean`?{enabled:e,maxEntitySize:1e4,maxExpansionDepth:1e4,maxTotalExpansions:1/0,maxExpandedLength:1e5,maxEntityCount:1e3,allowedTags:null,tagFilter:null,appliesTo:`all`}:typeof e==`object`&&e?{enabled:e.enabled!==!1,maxEntitySize:Math.max(1,e.maxEntitySize??1e4),maxExpansionDepth:Math.max(1,e.maxExpansionDepth??1e4),maxTotalExpansions:Math.max(1,e.maxTotalExpansions??1/0),maxExpandedLength:Math.max(1,e.maxExpandedLength??1e5),maxEntityCount:Math.max(1,e.maxEntityCount??1e3),allowedTags:e.allowedTags??null,tagFilter:e.tagFilter??null,appliesTo:e.appliesTo??`all`}:Kc(!0)}let qc=function(e){let t=Object.assign({},Wc,e),n=[{value:t.attributeNamePrefix,name:`attributeNamePrefix`},{value:t.attributesGroupName,name:`attributesGroupName`},{value:t.textNodeName,name:`textNodeName`},{value:t.cdataPropName,name:`cdataPropName`},{value:t.commentPropName,name:`commentPropName`}];for(let{value:e,name:t}of n)e&&Gc(e,t);return t.onDangerousProperty===null&&(t.onDangerousProperty=Uc),t.processEntities=Kc(t.processEntities,t.htmlEntities),t.unpairedTagsSet=new Set(t.unpairedTags),t.stopNodes&&Array.isArray(t.stopNodes)&&(t.stopNodes=t.stopNodes.map(e=>typeof e==`string`&&e.startsWith(`*.`)?`..`+e.substring(2):e)),t},Jc;Jc=typeof Symbol==`function`?Symbol(`XML Node Metadata`):`@@xmlMetadata`;var Yc=class{constructor(e){this.tagname=e,this.child=[],this[`:@`]=Object.create(null)}add(e,t){e===`__proto__`&&(e=`#__proto__`),this.child.push({[e]:t})}addChild(e,t){e.tagname===`__proto__`&&(e.tagname=`#__proto__`),e[`:@`]&&Object.keys(e[`:@`]).length>0?this.child.push({[e.tagname]:e.child,":@":e[`:@`]}):this.child.push({[e.tagname]:e.child}),t!==void 0&&(this.child[this.child.length-1][Jc]={startIndex:t})}static getMetaDataSymbol(){return Jc}},Xc=class{constructor(e){this.suppressValidationErr=!e,this.options=e}readDocType(e,t){let n=Object.create(null),r=0;if(e[t+3]===`O`&&e[t+4]===`C`&&e[t+5]===`T`&&e[t+6]===`Y`&&e[t+7]===`P`&&e[t+8]===`E`){t+=9;let i=1,a=!1,o=!1,s=``;for(;t<e.length;t++)if(e[t]===`<`&&!o){if(a&&Zc(e,`!ENTITY`,t)){t+=7;let i,a;if([i,a,t]=this.readEntityExp(e,t+1,this.suppressValidationErr),a.indexOf(`&`)===-1){if(this.options.enabled!==!1&&this.options.maxEntityCount!=null&&r>=this.options.maxEntityCount)throw Error(`Entity count (${r+1}) exceeds maximum allowed (${this.options.maxEntityCount})`);n[i]=a,r++}}else if(a&&Zc(e,`!ELEMENT`,t)){t+=8;let{index:n}=this.readElementExp(e,t+1);t=n}else if(a&&Zc(e,`!ATTLIST`,t))t+=8;else if(a&&Zc(e,`!NOTATION`,t)){t+=9;let{index:n}=this.readNotationExp(e,t+1,this.suppressValidationErr);t=n}else if(Zc(e,`!--`,t))o=!0;else throw Error(`Invalid DOCTYPE`);i++,s=``}else if(e[t]===`>`){if(o?e[t-1]===`-`&&e[t-2]===`-`&&(o=!1,i--):i--,i===0)break}else e[t]===`[`?a=!0:s+=e[t];if(i!==0)throw Error(`Unclosed DOCTYPE`)}else throw Error(`Invalid Tag instead of DOCTYPE`);return{entities:n,i:t}}readEntityExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t])&&e[t]!==`"`&&e[t]!==`'`;)t++;let r=e.substring(n,t);if(Qc(r),t=z(e,t),!this.suppressValidationErr){if(e.substring(t,t+6).toUpperCase()===`SYSTEM`)throw Error(`External entities are not supported`);if(e[t]===`%`)throw Error(`Parameter entities are not supported`)}let i=``;if([t,i]=this.readIdentifierVal(e,t,`entity`),this.options.enabled!==!1&&this.options.maxEntitySize!=null&&i.length>this.options.maxEntitySize)throw Error(`Entity "${r}" size (${i.length}) exceeds maximum allowed size (${this.options.maxEntitySize})`);return t--,[r,i,t]}readNotationExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;let r=e.substring(n,t);!this.suppressValidationErr&&Qc(r),t=z(e,t);let i=e.substring(t,t+6).toUpperCase();if(!this.suppressValidationErr&&i!==`SYSTEM`&&i!==`PUBLIC`)throw Error(`Expected SYSTEM or PUBLIC, found "${i}"`);t+=i.length,t=z(e,t);let a=null,o=null;if(i===`PUBLIC`)[t,a]=this.readIdentifierVal(e,t,`publicIdentifier`),t=z(e,t),(e[t]===`"`||e[t]===`'`)&&([t,o]=this.readIdentifierVal(e,t,`systemIdentifier`));else if(i===`SYSTEM`&&([t,o]=this.readIdentifierVal(e,t,`systemIdentifier`),!this.suppressValidationErr&&!o))throw Error(`Missing mandatory system identifier for SYSTEM notation`);return{notationName:r,publicIdentifier:a,systemIdentifier:o,index:--t}}readIdentifierVal(e,t,n){let r=``,i=e[t];if(i!==`"`&&i!==`'`)throw Error(`Expected quoted string, found "${i}"`);t++;let a=t;for(;t<e.length&&e[t]!==i;)t++;if(r=e.substring(a,t),e[t]!==i)throw Error(`Unterminated ${n} value`);return t++,[t,r]}readElementExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;let r=e.substring(n,t);if(!this.suppressValidationErr&&!nc(r))throw Error(`Invalid element name: "${r}"`);t=z(e,t);let i=``;if(e[t]===`E`&&Zc(e,`MPTY`,t))t+=4;else if(e[t]===`A`&&Zc(e,`NY`,t))t+=2;else if(e[t]===`(`){t++;let n=t;for(;t<e.length&&e[t]!==`)`;)t++;if(i=e.substring(n,t),e[t]!==`)`)throw Error(`Unterminated content model`)}else if(!this.suppressValidationErr)throw Error(`Invalid Element Expression, found "${e[t]}"`);return{elementName:r,contentModel:i.trim(),index:t}}readAttlistExp(e,t){t=z(e,t);let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;let r=e.substring(n,t);for(Qc(r),t=z(e,t),n=t;t<e.length&&!/\s/.test(e[t]);)t++;let i=e.substring(n,t);if(!Qc(i))throw Error(`Invalid attribute name: "${i}"`);t=z(e,t);let a=``;if(e.substring(t,t+8).toUpperCase()===`NOTATION`){if(a=`NOTATION`,t+=8,t=z(e,t),e[t]!==`(`)throw Error(`Expected '(', found "${e[t]}"`);t++;let n=[];for(;t<e.length&&e[t]!==`)`;){let r=t;for(;t<e.length&&e[t]!==`|`&&e[t]!==`)`;)t++;let i=e.substring(r,t);if(i=i.trim(),!Qc(i))throw Error(`Invalid notation name: "${i}"`);n.push(i),e[t]===`|`&&(t++,t=z(e,t))}if(e[t]!==`)`)throw Error(`Unterminated list of notations`);t++,a+=` (`+n.join(`|`)+`)`}else{let n=t;for(;t<e.length&&!/\s/.test(e[t]);)t++;if(a+=e.substring(n,t),!this.suppressValidationErr&&![`CDATA`,`ID`,`IDREF`,`IDREFS`,`ENTITY`,`ENTITIES`,`NMTOKEN`,`NMTOKENS`].includes(a.toUpperCase()))throw Error(`Invalid attribute type: "${a}"`)}t=z(e,t);let o=``;return e.substring(t,t+8).toUpperCase()===`#REQUIRED`?(o=`#REQUIRED`,t+=8):e.substring(t,t+7).toUpperCase()===`#IMPLIED`?(o=`#IMPLIED`,t+=7):[t,o]=this.readIdentifierVal(e,t,`ATTLIST`),{elementName:r,attributeName:i,attributeType:a,defaultValue:o,index:t}}};let z=(e,t)=>{for(;t<e.length&&/\s/.test(e[t]);)t++;return t};function Zc(e,t,n){for(let r=0;r<t.length;r++)if(t[r]!==e[n+r+1])return!1;return!0}function Qc(e){if(nc(e))return e;throw Error(`Invalid entity name ${e}`)}let $c=/^[-+]?0x[a-fA-F0-9]+$/,el=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,tl={hex:!0,leadingZeros:!0,decimalPoint:`.`,eNotation:!0,infinity:`original`};function nl(e,t={}){if(t=Object.assign({},tl,t),!e||typeof e!=`string`)return e;let n=e.trim();if(n.length===0||t.skipLike!==void 0&&t.skipLike.test(n))return e;if(n===`0`)return 0;if(t.hex&&$c.test(n))return ol(n,16);if(!isFinite(n))return sl(e,Number(n),t);if(n.includes(`e`)||n.includes(`E`))return il(e,n,t);{let r=el.exec(n);if(r){let i=r[1]||``,a=r[2],o=al(r[3]),s=i?e[a.length+1]===`.`:e[a.length]===`.`;if(!t.leadingZeros&&(a.length>1||a.length===1&&!s))return e;{let r=Number(n),s=String(r);if(r===0)return r;if(s.search(/[eE]/)!==-1)return t.eNotation?r:e;if(n.indexOf(`.`)!==-1)return s===`0`||s===o||s===`${i}${o}`?r:e;let c=a?o:n;return a?c===s||i+c===s?r:e:c===s||c===i+s?r:e}}else return e}}let rl=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function il(e,t,n){if(!n.eNotation)return e;let r=t.match(rl);if(r){let i=r[1]||``,a=r[3].indexOf(`e`)===-1?`E`:`e`,o=r[2],s=i?e[o.length+1]===a:e[o.length]===a;return o.length>1&&s?e:o.length===1&&(r[3].startsWith(`.${a}`)||r[3][0]===a)?Number(t):o.length>0?n.leadingZeros&&!s?(t=(r[1]||``)+r[3],Number(t)):e:Number(t)}else return e}function al(e){return e&&e.indexOf(`.`)!==-1?(e=e.replace(/0+$/,``),e===`.`?e=`0`:e[0]===`.`?e=`0`+e:e[e.length-1]===`.`&&(e=e.substring(0,e.length-1)),e):e}function ol(e,t){if(parseInt)return parseInt(e,t);if(Number.parseInt)return Number.parseInt(e,t);if(window&&window.parseInt)return window.parseInt(e,t);throw Error(`parseInt, Number.parseInt, window.parseInt are not supported`)}function sl(e,t,n){let r=t===1/0;switch(n.infinity.toLowerCase()){case`null`:return null;case`infinity`:return t;case`string`:return r?`Infinity`:`-Infinity`;default:return e}}function cl(e){return typeof e==`function`?e:Array.isArray(e)?t=>{for(let n of e)if(typeof n==`string`&&t===n||n instanceof RegExp&&n.test(t))return!0}:()=>!1}var ll=class{constructor(e,t={},n){this.pattern=e,this.separator=t.separator||`.`,this.segments=this._parse(e),this.data=n,this._hasDeepWildcard=this.segments.some(e=>e.type===`deep-wildcard`),this._hasAttributeCondition=this.segments.some(e=>e.attrName!==void 0),this._hasPositionSelector=this.segments.some(e=>e.position!==void 0)}_parse(e){let t=[],n=0,r=``;for(;n<e.length;)e[n]===this.separator?n+1<e.length&&e[n+1]===this.separator?(r.trim()&&(t.push(this._parseSegment(r.trim())),r=``),t.push({type:`deep-wildcard`}),n+=2):(r.trim()&&t.push(this._parseSegment(r.trim())),r=``,n++):(r+=e[n],n++);return r.trim()&&t.push(this._parseSegment(r.trim())),t}_parseSegment(e){let t={type:`tag`},n=null,r=e,i=e.match(/^([^\[]+)(\[[^\]]*\])(.*)$/);if(i&&(r=i[1]+i[3],i[2])){let e=i[2].slice(1,-1);e&&(n=e)}let a,o=r;if(r.includes(`::`)){let t=r.indexOf(`::`);if(a=r.substring(0,t).trim(),o=r.substring(t+2).trim(),!a)throw Error(`Invalid namespace in pattern: ${e}`)}let s,c=null;if(o.includes(`:`)){let e=o.lastIndexOf(`:`),t=o.substring(0,e).trim(),n=o.substring(e+1).trim();[`first`,`last`,`odd`,`even`].includes(n)||/^nth\(\d+\)$/.test(n)?(s=t,c=n):s=o}else s=o;if(!s)throw Error(`Invalid segment pattern: ${e}`);if(t.tag=s,a&&(t.namespace=a),n)if(n.includes(`=`)){let e=n.indexOf(`=`);t.attrName=n.substring(0,e).trim(),t.attrValue=n.substring(e+1).trim()}else t.attrName=n.trim();if(c){let e=c.match(/^nth\((\d+)\)$/);e?(t.position=`nth`,t.positionValue=parseInt(e[1],10)):t.position=c}return t}get length(){return this.segments.length}hasDeepWildcard(){return this._hasDeepWildcard}hasAttributeCondition(){return this._hasAttributeCondition}hasPositionSelector(){return this._hasPositionSelector}toString(){return this.pattern}},ul=class{constructor(){this._byDepthAndTag=new Map,this._wildcardByDepth=new Map,this._deepWildcards=[],this._patterns=new Set,this._sealed=!1}add(e){if(this._sealed)throw TypeError(`ExpressionSet is sealed. Create a new ExpressionSet to add more expressions.`);if(this._patterns.has(e.pattern))return this;if(this._patterns.add(e.pattern),e.hasDeepWildcard())return this._deepWildcards.push(e),this;let t=e.length,n=e.segments[e.segments.length-1]?.tag;if(!n||n===`*`)this._wildcardByDepth.has(t)||this._wildcardByDepth.set(t,[]),this._wildcardByDepth.get(t).push(e);else{let r=`${t}:${n}`;this._byDepthAndTag.has(r)||this._byDepthAndTag.set(r,[]),this._byDepthAndTag.get(r).push(e)}return this}addAll(e){for(let t of e)this.add(t);return this}has(e){return this._patterns.has(e.pattern)}get size(){return this._patterns.size}seal(){return this._sealed=!0,this}get isSealed(){return this._sealed}matchesAny(e){return this.findMatch(e)!==null}findMatch(e){let t=e.getDepth(),n=`${t}:${e.getCurrentTag()}`,r=this._byDepthAndTag.get(n);if(r){for(let t=0;t<r.length;t++)if(e.matches(r[t]))return r[t]}let i=this._wildcardByDepth.get(t);if(i){for(let t=0;t<i.length;t++)if(e.matches(i[t]))return i[t]}for(let t=0;t<this._deepWildcards.length;t++)if(e.matches(this._deepWildcards[t]))return this._deepWildcards[t];return null}},dl=class{constructor(e){this._matcher=e}get separator(){return this._matcher.separator}getCurrentTag(){let e=this._matcher.path;return e.length>0?e[e.length-1].tag:void 0}getCurrentNamespace(){let e=this._matcher.path;return e.length>0?e[e.length-1].namespace:void 0}getAttrValue(e){let t=this._matcher.path;if(t.length!==0)return t[t.length-1].values?.[e]}hasAttr(e){let t=this._matcher.path;if(t.length===0)return!1;let n=t[t.length-1];return n.values!==void 0&&e in n.values}getPosition(){let e=this._matcher.path;return e.length===0?-1:e[e.length-1].position??0}getCounter(){let e=this._matcher.path;return e.length===0?-1:e[e.length-1].counter??0}getIndex(){return this.getPosition()}getDepth(){return this._matcher.path.length}toString(e,t=!0){return this._matcher.toString(e,t)}toArray(){return this._matcher.path.map(e=>e.tag)}matches(e){return this._matcher.matches(e)}matchesAny(e){return e.matchesAny(this._matcher)}},fl=class{constructor(e={}){this.separator=e.separator||`.`,this.path=[],this.siblingStacks=[],this._pathStringCache=null,this._view=new dl(this)}push(e,t=null,n=null){this._pathStringCache=null,this.path.length>0&&(this.path[this.path.length-1].values=void 0);let r=this.path.length;this.siblingStacks[r]||(this.siblingStacks[r]=new Map);let i=this.siblingStacks[r],a=n?`${n}:${e}`:e,o=i.get(a)||0,s=0;for(let e of i.values())s+=e;i.set(a,o+1);let c={tag:e,position:s,counter:o};n!=null&&(c.namespace=n),t!=null&&(c.values=t),this.path.push(c)}pop(){if(this.path.length===0)return;this._pathStringCache=null;let e=this.path.pop();return this.siblingStacks.length>this.path.length+1&&(this.siblingStacks.length=this.path.length+1),e}updateCurrent(e){if(this.path.length>0){let t=this.path[this.path.length-1];e!=null&&(t.values=e)}}getCurrentTag(){return this.path.length>0?this.path[this.path.length-1].tag:void 0}getCurrentNamespace(){return this.path.length>0?this.path[this.path.length-1].namespace:void 0}getAttrValue(e){if(this.path.length!==0)return this.path[this.path.length-1].values?.[e]}hasAttr(e){if(this.path.length===0)return!1;let t=this.path[this.path.length-1];return t.values!==void 0&&e in t.values}getPosition(){return this.path.length===0?-1:this.path[this.path.length-1].position??0}getCounter(){return this.path.length===0?-1:this.path[this.path.length-1].counter??0}getIndex(){return this.getPosition()}getDepth(){return this.path.length}toString(e,t=!0){let n=e||this.separator;if(n===this.separator&&t===!0){if(this._pathStringCache!==null)return this._pathStringCache;let e=this.path.map(e=>e.namespace?`${e.namespace}:${e.tag}`:e.tag).join(n);return this._pathStringCache=e,e}return this.path.map(e=>t&&e.namespace?`${e.namespace}:${e.tag}`:e.tag).join(n)}toArray(){return this.path.map(e=>e.tag)}reset(){this._pathStringCache=null,this.path=[],this.siblingStacks=[]}matches(e){let t=e.segments;return t.length===0?!1:e.hasDeepWildcard()?this._matchWithDeepWildcard(t):this._matchSimple(t)}_matchSimple(e){if(this.path.length!==e.length)return!1;for(let t=0;t<e.length;t++)if(!this._matchSegment(e[t],this.path[t],t===this.path.length-1))return!1;return!0}_matchWithDeepWildcard(e){let t=this.path.length-1,n=e.length-1;for(;n>=0&&t>=0;){let r=e[n];if(r.type===`deep-wildcard`){if(n--,n<0)return!0;let r=e[n],i=!1;for(let e=t;e>=0;e--)if(this._matchSegment(r,this.path[e],e===this.path.length-1)){t=e-1,n--,i=!0;break}if(!i)return!1}else{if(!this._matchSegment(r,this.path[t],t===this.path.length-1))return!1;t--,n--}}return n<0}_matchSegment(e,t,n){if(e.tag!==`*`&&e.tag!==t.tag||e.namespace!==void 0&&e.namespace!==`*`&&e.namespace!==t.namespace||e.attrName!==void 0&&(!n||!t.values||!(e.attrName in t.values)||e.attrValue!==void 0&&String(t.values[e.attrName])!==String(e.attrValue)))return!1;if(e.position!==void 0){if(!n)return!1;let r=t.counter??0;if(e.position===`first`&&r!==0||e.position===`odd`&&r%2!=1||e.position===`even`&&r%2!=0||e.position===`nth`&&r!==e.positionValue)return!1}return!0}matchesAny(e){return e.matchesAny(this)}snapshot(){return{path:this.path.map(e=>({...e})),siblingStacks:this.siblingStacks.map(e=>new Map(e))}}restore(e){this._pathStringCache=null,this.path=e.path.map(e=>({...e})),this.siblingStacks=e.siblingStacks.map(e=>new Map(e))}readOnly(){return this._view}};function pl(e,t){if(!e)return{};let n=t.attributesGroupName?e[t.attributesGroupName]:e;if(!n)return{};let r={};for(let e in n)if(e.startsWith(t.attributeNamePrefix)){let i=e.substring(t.attributeNamePrefix.length);r[i]=n[e]}else r[e]=n[e];return r}function ml(e){if(!e||typeof e!=`string`)return;let t=e.indexOf(`:`);if(t!==-1&&t>0){let n=e.substring(0,t);if(n!==`xmlns`)return n}}var hl=class{constructor(e,t){this.options=e,this.currentNode=null,this.tagsNodeStack=[],this.parseXml=bl,this.parseTextData=gl,this.resolveNameSpace=_l,this.buildAttributesMap=yl,this.isItStopNode=wl,this.replaceEntitiesValue=Sl,this.readStopNodeData=kl,this.saveTextToParentTag=Cl,this.addChild=xl,this.ignoreAttributesFn=cl(this.options.ignoreAttributes),this.entityExpansionCount=0,this.currentExpandedLength=0;let n={...Mc};this.options.entityDecoder?this.entityDecoder=this.options.entityDecoder:(typeof this.options.htmlEntities==`object`?n=this.options.htmlEntities:this.options.htmlEntities===!0&&(n={...Nc,...kc}),this.entityDecoder=new Hc({namedEntities:{...n,...t},numericAllowed:this.options.htmlEntities,limit:{maxTotalExpansions:this.options.processEntities.maxTotalExpansions,maxExpandedLength:this.options.processEntities.maxExpandedLength,applyLimitsTo:this.options.processEntities.appliesTo}})),this.matcher=new fl,this.readonlyMatcher=this.matcher.readOnly(),this.isCurrentNodeStopNode=!1,this.stopNodeExpressionsSet=new ul;let r=this.options.stopNodes;if(r&&r.length>0){for(let e=0;e<r.length;e++){let t=r[e];typeof t==`string`?this.stopNodeExpressionsSet.add(new ll(t)):t instanceof ll&&this.stopNodeExpressionsSet.add(t)}this.stopNodeExpressionsSet.seal()}}};function gl(e,t,n,r,i,a,o){let s=this.options;if(e!==void 0&&(s.trimValues&&!r&&(e=e.trim()),e.length>0)){o||(e=this.replaceEntitiesValue(e,t,n));let r=s.jPath?n.toString():n,c=s.tagValueProcessor(t,e,r,i,a);return c==null?e:typeof c!=typeof e||c!==e?c:s.trimValues||e.trim()===e?Al(e,s.parseTagValue,s.numberParseOptions):e}}function _l(e){if(this.options.removeNSPrefix){let t=e.split(`:`),n=e.charAt(0)===`/`?`/`:``;if(t[0]===`xmlns`)return``;t.length===2&&(e=n+t[1])}return e}let vl=RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,`gm`);function yl(e,t,n,r=!1){let i=this.options;if(r===!0||i.ignoreAttributes!==!0&&typeof e==`string`){let r=tc(e,vl),a=r.length,o={},s=Array(a),c=!1,l={};for(let e=0;e<a;e++){let t=this.resolveNameSpace(r[e][1]),a=r[e][4];if(t.length&&a!==void 0){let r=a;i.trimValues&&(r=r.trim()),r=this.replaceEntitiesValue(r,n,this.readonlyMatcher),s[e]=r,l[t]=r,c=!0}}c&&typeof t==`object`&&t.updateCurrent&&t.updateCurrent(l);let u=i.jPath?t.toString():this.readonlyMatcher,d=!1;for(let e=0;e<a;e++){let t=this.resolveNameSpace(r[e][1]);if(this.ignoreAttributesFn(t,u))continue;let n=i.attributeNamePrefix+t;if(t.length)if(i.transformAttributeName&&(n=i.transformAttributeName(n)),n=Ml(n,i),r[e][4]!==void 0){let r=s[e],a=i.attributeValueProcessor(t,r,u);a==null?o[n]=r:typeof a!=typeof r||a!==r?o[n]=a:o[n]=Al(r,i.parseAttributeValue,i.numberParseOptions),d=!0}else i.allowBooleanAttributes&&(o[n]=!0,d=!0)}if(!d)return;if(i.attributesGroupName&&!i.preserveOrder){let e={};return e[i.attributesGroupName]=o,e}return o}}let bl=function(e){e=e.replace(/\r\n?/g,`
12
+ `);let t=new Yc(`!xml`),n=t,r=``;this.matcher.reset(),this.entityDecoder.reset(),this.entityExpansionCount=0,this.currentExpandedLength=0;let i=this.options,a=new Xc(i.processEntities),o=e.length;for(let s=0;s<o;s++)if(e[s]===`<`){let c=e.charCodeAt(s+1);if(c===47){let t=El(e,`>`,s,`Closing Tag is not closed.`),a=e.substring(s+2,t).trim();if(i.removeNSPrefix){let e=a.indexOf(`:`);e!==-1&&(a=a.substr(e+1))}a=jl(i.transformTagName,a,``,i).tagName,n&&(r=this.saveTextToParentTag(r,n,this.readonlyMatcher));let o=this.matcher.getCurrentTag();if(a&&i.unpairedTagsSet.has(a))throw Error(`Unpaired tag can not be used as closing tag: </${a}>`);o&&i.unpairedTagsSet.has(o)&&(this.matcher.pop(),this.tagsNodeStack.pop()),this.matcher.pop(),this.isCurrentNodeStopNode=!1,n=this.tagsNodeStack.pop(),r=``,s=t}else if(c===63){let t=Ol(e,s,!1,`?>`);if(!t)throw Error(`Pi Tag is not closed.`);r=this.saveTextToParentTag(r,n,this.readonlyMatcher);let a=this.buildAttributesMap(t.tagExp,this.matcher,t.tagName,!0);if(a){let e=a[this.options.attributeNamePrefix+`version`];this.entityDecoder.setXmlVersion(Number(e)||1)}if(!(i.ignoreDeclaration&&t.tagName===`?xml`||i.ignorePiTags)){let e=new Yc(t.tagName);e.add(i.textNodeName,``),t.tagName!==t.tagExp&&t.attrExpPresent&&i.ignoreAttributes!==!0&&(e[`:@`]=a),this.addChild(n,e,this.readonlyMatcher,s)}s=t.closeIndex+1}else if(c===33&&e.charCodeAt(s+2)===45&&e.charCodeAt(s+3)===45){let t=El(e,`-->`,s+4,`Comment is not closed.`);if(i.commentPropName){let a=e.substring(s+4,t-2);r=this.saveTextToParentTag(r,n,this.readonlyMatcher),n.add(i.commentPropName,[{[i.textNodeName]:a}])}s=t}else if(c===33&&e.charCodeAt(s+2)===68){let t=a.readDocType(e,s);this.entityDecoder.addInputEntities(t.entities),s=t.i}else if(c===33&&e.charCodeAt(s+2)===91){let t=El(e,`]]>`,s,`CDATA is not closed.`)-2,a=e.substring(s+9,t);r=this.saveTextToParentTag(r,n,this.readonlyMatcher);let o=this.parseTextData(a,n.tagname,this.readonlyMatcher,!0,!1,!0,!0);o??=``,i.cdataPropName?n.add(i.cdataPropName,[{[i.textNodeName]:a}]):n.add(i.textNodeName,o),s=t+2}else{let a=Ol(e,s,i.removeNSPrefix);if(!a){let t=e.substring(Math.max(0,s-50),Math.min(o,s+50));throw Error(`readTagExp returned undefined at position ${s}. Context: "${t}"`)}let c=a.tagName,l=a.rawTagName,u=a.tagExp,d=a.attrExpPresent,f=a.closeIndex;if({tagName:c,tagExp:u}=jl(i.transformTagName,c,u,i),i.strictReservedNames&&(c===i.commentPropName||c===i.cdataPropName||c===i.textNodeName||c===i.attributesGroupName))throw Error(`Invalid tag name: ${c}`);n&&r&&n.tagname!==`!xml`&&(r=this.saveTextToParentTag(r,n,this.readonlyMatcher,!1));let p=n;p&&i.unpairedTagsSet.has(p.tagname)&&(n=this.tagsNodeStack.pop(),this.matcher.pop());let m=!1;u.length>0&&u.lastIndexOf(`/`)===u.length-1&&(m=!0,c[c.length-1]===`/`?(c=c.substr(0,c.length-1),u=c):u=u.substr(0,u.length-1),d=c!==u);let h=null,g;g=ml(l),c!==t.tagname&&this.matcher.push(c,{},g),c!==u&&d&&(h=this.buildAttributesMap(u,this.matcher,c),h&&pl(h,i)),c!==t.tagname&&(this.isCurrentNodeStopNode=this.isItStopNode());let _=s;if(this.isCurrentNodeStopNode){let t=``;if(m)s=a.closeIndex;else if(i.unpairedTagsSet.has(c))s=a.closeIndex;else{let n=this.readStopNodeData(e,l,f+1);if(!n)throw Error(`Unexpected end of ${l}`);s=n.i,t=n.tagContent}let r=new Yc(c);h&&(r[`:@`]=h),r.add(i.textNodeName,t),this.matcher.pop(),this.isCurrentNodeStopNode=!1,this.addChild(n,r,this.readonlyMatcher,_)}else{if(m){({tagName:c,tagExp:u}=jl(i.transformTagName,c,u,i));let e=new Yc(c);h&&(e[`:@`]=h),this.addChild(n,e,this.readonlyMatcher,_),this.matcher.pop(),this.isCurrentNodeStopNode=!1}else if(i.unpairedTagsSet.has(c)){let e=new Yc(c);h&&(e[`:@`]=h),this.addChild(n,e,this.readonlyMatcher,_),this.matcher.pop(),this.isCurrentNodeStopNode=!1,s=a.closeIndex;continue}else{let e=new Yc(c);if(this.tagsNodeStack.length>i.maxNestedTags)throw Error(`Maximum nested tags exceeded`);this.tagsNodeStack.push(n),h&&(e[`:@`]=h),this.addChild(n,e,this.readonlyMatcher,_),n=e}r=``,s=f}}}else r+=e[s];return t.child};function xl(e,t,n,r){this.options.captureMetaData||(r=void 0);let i=this.options.jPath?n.toString():n,a=this.options.updateTag(t.tagname,i,t[`:@`]);a===!1||(typeof a==`string`&&(t.tagname=a),e.addChild(t,r))}function Sl(e,t,n){let r=this.options.processEntities;if(!r||!r.enabled)return e;if(r.allowedTags){let i=this.options.jPath?n.toString():n;if(!(Array.isArray(r.allowedTags)?r.allowedTags.includes(t):r.allowedTags(t,i)))return e}if(r.tagFilter){let i=this.options.jPath?n.toString():n;if(!r.tagFilter(t,i))return e}return this.entityDecoder.decode(e)}function Cl(e,t,n,r){return e&&=(r===void 0&&(r=t.child.length===0),e=this.parseTextData(e,t.tagname,n,!1,t[`:@`]?Object.keys(t[`:@`]).length!==0:!1,r),e!==void 0&&e!==``&&t.add(this.options.textNodeName,e),``),e}function wl(){return this.stopNodeExpressionsSet.size===0?!1:this.matcher.matchesAny(this.stopNodeExpressionsSet)}function Tl(e,t,n=`>`){let r=0,i=e.length,a=n.charCodeAt(0),o=n.length>1?n.charCodeAt(1):-1,s=``,c=t;for(let n=t;n<i;n++){let t=e.charCodeAt(n);if(r)t===r&&(r=0);else if(t===34||t===39)r=t;else if(t===a)if(o!==-1){if(e.charCodeAt(n+1)===o)return s+=e.substring(c,n),{data:s,index:n}}else return s+=e.substring(c,n),{data:s,index:n};else t===9&&!r&&(s+=e.substring(c,n)+` `,c=n+1)}}function El(e,t,n,r){let i=e.indexOf(t,n);if(i===-1)throw Error(r);return i+t.length-1}function Dl(e,t,n,r){let i=e.indexOf(t,n);if(i===-1)throw Error(r);return i}function Ol(e,t,n,r=`>`){let i=Tl(e,t+1,r);if(!i)return;let a=i.data,o=i.index,s=a.search(/\s/),c=a,l=!0;s!==-1&&(c=a.substring(0,s),a=a.substring(s+1).trimStart());let u=c;if(n){let e=c.indexOf(`:`);e!==-1&&(c=c.substr(e+1),l=c!==i.data.substr(e+1))}return{tagName:c,tagExp:a,closeIndex:o,attrExpPresent:l,rawTagName:u}}function kl(e,t,n){let r=n,i=1,a=e.length;for(;n<a;n++)if(e[n]===`<`){let a=e.charCodeAt(n+1);if(a===47){let a=Dl(e,`>`,n,`${t} is not closed`);if(e.substring(n+2,a).trim()===t&&(i--,i===0))return{tagContent:e.substring(r,n),i:a};n=a}else if(a===63)n=El(e,`?>`,n+1,`StopNode is not closed.`);else if(a===33&&e.charCodeAt(n+2)===45&&e.charCodeAt(n+3)===45)n=El(e,`-->`,n+3,`StopNode is not closed.`);else if(a===33&&e.charCodeAt(n+2)===91)n=El(e,`]]>`,n,`StopNode is not closed.`)-2;else{let r=Ol(e,n,`>`);r&&((r&&r.tagName)===t&&r.tagExp[r.tagExp.length-1]!==`/`&&i++,n=r.closeIndex)}}}function Al(e,t,n){if(t&&typeof e==`string`){let t=e.trim();return t===`true`?!0:t===`false`?!1:nl(e,n)}else if(rc(e))return e;else return``}function jl(e,t,n,r){if(e){let r=e(t);n===t&&(n=r),t=r}return t=Ml(t,r),{tagName:t,tagExp:n}}function Ml(e,t){if(ac.includes(e))throw Error(`[SECURITY] Invalid name: "${e}" is a reserved JavaScript keyword that could cause prototype pollution`);return ic.includes(e)?t.onDangerousProperty(e):e}let Nl=Yc.getMetaDataSymbol();function Pl(e,t){if(!e||typeof e!=`object`)return{};if(!t)return e;let n={};for(let r in e)if(r.startsWith(t)){let i=r.substring(t.length);n[i]=e[r]}else n[r]=e[r];return n}function Fl(e,t,n,r){return Il(e,t,n,r)}function Il(e,t,n,r){let i,a={};for(let o=0;o<e.length;o++){let s=e[o],c=Ll(s);if(c!==void 0&&c!==t.textNodeName){let e=Pl(s[`:@`]||{},t.attributeNamePrefix);n.push(c,e)}if(c===t.textNodeName)i===void 0?i=s[c]:i+=``+s[c];else if(c===void 0)continue;else if(s[c]){let e=Il(s[c],t,n,r),i=zl(e,t);if(s[`:@`]?Rl(e,s[`:@`],r,t):Object.keys(e).length===1&&e[t.textNodeName]!==void 0&&!t.alwaysCreateTextNode?e=e[t.textNodeName]:Object.keys(e).length===0&&(t.alwaysCreateTextNode?e[t.textNodeName]=``:e=``),s[Nl]!==void 0&&typeof e==`object`&&e&&(e[Nl]=s[Nl]),a[c]!==void 0&&Object.prototype.hasOwnProperty.call(a,c))Array.isArray(a[c])||(a[c]=[a[c]]),a[c].push(e);else{let n=t.jPath?r.toString():r;t.isArray(c,n,i)?a[c]=[e]:a[c]=e}c!==void 0&&c!==t.textNodeName&&n.pop()}}return typeof i==`string`?i.length>0&&(a[t.textNodeName]=i):i!==void 0&&(a[t.textNodeName]=i),a}function Ll(e){let t=Object.keys(e);for(let e=0;e<t.length;e++){let n=t[e];if(n!==`:@`)return n}}function Rl(e,t,n,r){if(t){let i=Object.keys(t),a=i.length;for(let o=0;o<a;o++){let a=i[o],s=a.startsWith(r.attributeNamePrefix)?a.substring(r.attributeNamePrefix.length):a,c=r.jPath?n.toString()+`.`+s:n;r.isArray(a,c,!0,!0)?e[a]=[t[a]]:e[a]=t[a]}}}function zl(e,t){let{textNodeName:n}=t,r=Object.keys(e).length;return!!(r===0||r===1&&(e[n]||typeof e[n]==`boolean`||e[n]===0))}var Bl=class{constructor(e){this.externalEntities={},this.options=qc(e)}parse(e,t){if(typeof e!=`string`&&e.toString)e=e.toString();else if(typeof e!=`string`)throw Error(`XML data is accepted in String or Bytes[] form.`);if(t){t===!0&&(t={});let n=sc(e,t);if(n!==!0)throw Error(`${n.err.msg}:${n.err.line}:${n.err.col}`)}let n=new hl(this.options,this.externalEntities),r=n.parseXml(e);return this.options.preserveOrder||r===void 0?r:Fl(r,this.options,n.matcher,n.readonlyMatcher)}addEntity(e,t){if(t.indexOf(`&`)!==-1)throw Error(`Entity value can't have '&'`);if(e.indexOf(`&`)!==-1||e.indexOf(`;`)!==-1)throw Error(`An entity must be set without '&' and ';'. Eg. use '#xD' for '&#xD;'`);if(t===`&`)throw Error(`An entity with value '&' is not permitted`);this.externalEntities[e]=t}static getMetaDataSymbol(){return Yc.getMetaDataSymbol()}};function Vl(e,t){let n=``;t.format&&t.indentBy.length>0&&(n=`
13
13
  `);let r=[];if(t.stopNodes&&Array.isArray(t.stopNodes))for(let e=0;e<t.stopNodes.length;e++){let n=t.stopNodes[e];typeof n==`string`?r.push(new ll(n)):n instanceof ll&&r.push(n)}let i=new fl;return Hl(e,t,n,i,r)}function Hl(e,t,n,r,i){let a=``,o=!1;if(t.maxNestedTags&&r.getDepth()>t.maxNestedTags)throw Error(`Maximum nested tags exceeded`);if(!Array.isArray(e)){if(e!=null){let n=e.toString();return n=Yl(n,t),n}return``}for(let s=0;s<e.length;s++){let c=e[s],l=Kl(c);if(l===void 0)continue;let u=Ul(c[`:@`],t);r.push(l,u);let d=Jl(r,i);if(l===t.textNodeName){let e=c[l];d||(e=t.tagValueProcessor(l,e),e=Yl(e,t)),o&&(a+=n),a+=e,o=!1,r.pop();continue}else if(l===t.cdataPropName){o&&(a+=n);let e=c[l][0][t.textNodeName],i=String(e).replace(/\]\]>/g,`]]]]><![CDATA[>`);a+=`<![CDATA[${i}]]>`,o=!1,r.pop();continue}else if(l===t.commentPropName){let e=c[l][0][t.textNodeName],i=String(e).replace(/--/g,`- -`).replace(/-$/,`- `);a+=n+`<!--${i}-->`,o=!0,r.pop();continue}else if(l[0]===`?`){let e=ql(c[`:@`],t,d),i=l===`?xml`?``:n,s=c[l][0][t.textNodeName];s=s.length===0?``:` `+s,a+=i+`<${l}${s}${e}?>`,o=!0,r.pop();continue}let f=n;f!==``&&(f+=t.indentBy);let p=n+`<${l}${ql(c[`:@`],t,d)}`,m;m=d?Wl(c[l],t):Hl(c[l],t,f,r,i),t.unpairedTags.indexOf(l)===-1?(!m||m.length===0)&&t.suppressEmptyNode?a+=p+`/>`:m&&m.endsWith(`>`)?a+=p+`>${m}${n}</${l}>`:(a+=p+`>`,m&&n!==``&&(m.includes(`/>`)||m.includes(`</`))?a+=n+t.indentBy+m+n:a+=m,a+=`</${l}>`):t.suppressUnpairedNode?a+=p+`>`:a+=p+`/>`,o=!0,r.pop()}return a}function Ul(e,t){if(!e||t.ignoreAttributes)return null;let n={},r=!1;for(let i in e){if(!Object.prototype.hasOwnProperty.call(e,i))continue;let a=i.startsWith(t.attributeNamePrefix)?i.substr(t.attributeNamePrefix.length):i;n[a]=e[i],r=!0}return r?n:null}function Wl(e,t){if(!Array.isArray(e))return e==null?``:e.toString();let n=``;for(let r=0;r<e.length;r++){let i=e[r],a=Kl(i);if(a===t.textNodeName)n+=i[a];else if(a===t.cdataPropName)n+=i[a][0][t.textNodeName];else if(a===t.commentPropName)n+=i[a][0][t.textNodeName];else if(a&&a[0]===`?`)continue;else if(a){let e=Gl(i[`:@`],t),r=Wl(i[a],t);!r||r.length===0?n+=`<${a}${e}/>`:n+=`<${a}${e}>${r}</${a}>`}}return n}function Gl(e,t){let n=``;if(e&&!t.ignoreAttributes)for(let r in e){if(!Object.prototype.hasOwnProperty.call(e,r))continue;let i=e[r];i===!0&&t.suppressBooleanAttributes?n+=` ${r.substr(t.attributeNamePrefix.length)}`:n+=` ${r.substr(t.attributeNamePrefix.length)}="${i}"`}return n}function Kl(e){let t=Object.keys(e);for(let n=0;n<t.length;n++){let r=t[n];if(Object.prototype.hasOwnProperty.call(e,r)&&r!==`:@`)return r}}function ql(e,t,n){let r=``;if(e&&!t.ignoreAttributes)for(let i in e){if(!Object.prototype.hasOwnProperty.call(e,i))continue;let a;n?a=e[i]:(a=t.attributeValueProcessor(i,e[i]),a=Yl(a,t)),a===!0&&t.suppressBooleanAttributes?r+=` ${i.substr(t.attributeNamePrefix.length)}`:r+=` ${i.substr(t.attributeNamePrefix.length)}="${a}"`}return r}function Jl(e,t){if(!t||t.length===0)return!1;for(let n=0;n<t.length;n++)if(e.matches(t[n]))return!0;return!1}function Yl(e,t){if(e&&e.length>0&&t.processEntities)for(let n=0;n<t.entities.length;n++){let r=t.entities[n];e=e.replace(r.regex,r.val)}return e}function Xl(e){return typeof e==`function`?e:Array.isArray(e)?t=>{for(let n of e)if(typeof n==`string`&&t===n||n instanceof RegExp&&n.test(t))return!0}:()=>!1}let Zl={attributeNamePrefix:`@_`,attributesGroupName:!1,textNodeName:`#text`,ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:` `,suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:RegExp(`&`,`g`),val:`&amp;`},{regex:RegExp(`>`,`g`),val:`&gt;`},{regex:RegExp(`<`,`g`),val:`&lt;`},{regex:RegExp(`'`,`g`),val:`&apos;`},{regex:RegExp(`"`,`g`),val:`&quot;`}],processEntities:!0,stopNodes:[],oneListGroup:!1,maxNestedTags:100,jPath:!0};function B(e){if(this.options=Object.assign({},Zl,e),this.options.stopNodes&&Array.isArray(this.options.stopNodes)&&(this.options.stopNodes=this.options.stopNodes.map(e=>typeof e==`string`&&e.startsWith(`*.`)?`..`+e.substring(2):e)),this.stopNodeExpressions=[],this.options.stopNodes&&Array.isArray(this.options.stopNodes))for(let e=0;e<this.options.stopNodes.length;e++){let t=this.options.stopNodes[e];typeof t==`string`?this.stopNodeExpressions.push(new ll(t)):t instanceof ll&&this.stopNodeExpressions.push(t)}this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=Xl(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=eu),this.processTextOrObjNode=Ql,this.options.format?(this.indentate=$l,this.tagEndChar=`>
14
14
  `,this.newLine=`
15
15
  `):(this.indentate=function(){return``},this.tagEndChar=`>`,this.newLine=``)}B.prototype.build=function(e){if(this.options.preserveOrder)return Vl(e,this.options);{Array.isArray(e)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(e={[this.options.arrayNodeName]:e});let t=new fl;return this.j2x(e,0,t).val}},B.prototype.j2x=function(e,t,n){let r=``,i=``;if(this.options.maxNestedTags&&n.getDepth()>=this.options.maxNestedTags)throw Error(`Maximum nested tags exceeded`);let a=this.options.jPath?n.toString():n,o=this.checkStopNode(n);for(let s in e)if(Object.prototype.hasOwnProperty.call(e,s))if(e[s]===void 0)this.isAttribute(s)&&(i+=``);else if(e[s]===null)this.isAttribute(s)||s===this.options.cdataPropName?i+=``:s[0]===`?`?i+=this.indentate(t)+`<`+s+`?`+this.tagEndChar:i+=this.indentate(t)+`<`+s+`/`+this.tagEndChar;else if(e[s]instanceof Date)i+=this.buildTextValNode(e[s],s,``,t,n);else if(typeof e[s]!=`object`){let c=this.isAttribute(s);if(c&&!this.ignoreAttributesFn(c,a))r+=this.buildAttrPairStr(c,``+e[s],o);else if(!c)if(s===this.options.textNodeName){let t=this.options.tagValueProcessor(s,``+e[s]);i+=this.replaceEntitiesValue(t)}else{n.push(s);let r=this.checkStopNode(n);if(n.pop(),r){let n=``+e[s];n===``?i+=this.indentate(t)+`<`+s+this.closeTag(s)+this.tagEndChar:i+=this.indentate(t)+`<`+s+`>`+n+`</`+s+this.tagEndChar}else i+=this.buildTextValNode(e[s],s,``,t,n)}}else if(Array.isArray(e[s])){let r=e[s].length,a=``,o=``;for(let c=0;c<r;c++){let r=e[s][c];if(r!==void 0)if(r===null)s[0]===`?`?i+=this.indentate(t)+`<`+s+`?`+this.tagEndChar:i+=this.indentate(t)+`<`+s+`/`+this.tagEndChar;else if(typeof r==`object`)if(this.options.oneListGroup){n.push(s);let e=this.j2x(r,t+1,n);n.pop(),a+=e.val,this.options.attributesGroupName&&r.hasOwnProperty(this.options.attributesGroupName)&&(o+=e.attrStr)}else a+=this.processTextOrObjNode(r,s,t,n);else if(this.options.oneListGroup){let e=this.options.tagValueProcessor(s,r);e=this.replaceEntitiesValue(e),a+=e}else{n.push(s);let e=this.checkStopNode(n);if(n.pop(),e){let e=``+r;e===``?a+=this.indentate(t)+`<`+s+this.closeTag(s)+this.tagEndChar:a+=this.indentate(t)+`<`+s+`>`+e+`</`+s+this.tagEndChar}else a+=this.buildTextValNode(r,s,``,t,n)}}this.options.oneListGroup&&(a=this.buildObjectNode(a,s,o,t)),i+=a}else if(this.options.attributesGroupName&&s===this.options.attributesGroupName){let t=Object.keys(e[s]),n=t.length;for(let i=0;i<n;i++)r+=this.buildAttrPairStr(t[i],``+e[s][t[i]],o)}else i+=this.processTextOrObjNode(e[s],s,t,n);return{attrStr:r,val:i}},B.prototype.buildAttrPairStr=function(e,t,n){return n||(t=this.options.attributeValueProcessor(e,``+t),t=this.replaceEntitiesValue(t)),this.options.suppressBooleanAttributes&&t===`true`?` `+e:` `+e+`="`+t+`"`};function Ql(e,t,n,r){let i=this.extractAttributes(e);if(r.push(t,i),this.checkStopNode(r)){let i=this.buildRawContent(e),a=this.buildAttributesForStopNode(e);return r.pop(),this.buildObjectNode(i,t,a,n)}let a=this.j2x(e,n+1,r);return r.pop(),e[this.options.textNodeName]!==void 0&&Object.keys(e).length===1?this.buildTextValNode(e[this.options.textNodeName],t,a.attrStr,n,r):this.buildObjectNode(a.val,t,a.attrStr,n)}B.prototype.extractAttributes=function(e){if(!e||typeof e!=`object`)return null;let t={},n=!1;if(this.options.attributesGroupName&&e[this.options.attributesGroupName]){let r=e[this.options.attributesGroupName];for(let e in r){if(!Object.prototype.hasOwnProperty.call(r,e))continue;let i=e.startsWith(this.options.attributeNamePrefix)?e.substring(this.options.attributeNamePrefix.length):e;t[i]=r[e],n=!0}}else for(let r in e){if(!Object.prototype.hasOwnProperty.call(e,r))continue;let i=this.isAttribute(r);i&&(t[i]=e[r],n=!0)}return n?t:null},B.prototype.buildRawContent=function(e){if(typeof e==`string`)return e;if(typeof e!=`object`||!e)return String(e);if(e[this.options.textNodeName]!==void 0)return e[this.options.textNodeName];let t=``;for(let n in e){if(!Object.prototype.hasOwnProperty.call(e,n)||this.isAttribute(n)||this.options.attributesGroupName&&n===this.options.attributesGroupName)continue;let r=e[n];if(n===this.options.textNodeName)t+=r;else if(Array.isArray(r)){for(let e of r)if(typeof e==`string`||typeof e==`number`)t+=`<${n}>${e}</${n}>`;else if(typeof e==`object`&&e){let r=this.buildRawContent(e),i=this.buildAttributesForStopNode(e);r===``?t+=`<${n}${i}/>`:t+=`<${n}${i}>${r}</${n}>`}}else if(typeof r==`object`&&r){let e=this.buildRawContent(r),i=this.buildAttributesForStopNode(r);e===``?t+=`<${n}${i}/>`:t+=`<${n}${i}>${e}</${n}>`}else t+=`<${n}>${r}</${n}>`}return t},B.prototype.buildAttributesForStopNode=function(e){if(!e||typeof e!=`object`)return``;let t=``;if(this.options.attributesGroupName&&e[this.options.attributesGroupName]){let n=e[this.options.attributesGroupName];for(let e in n){if(!Object.prototype.hasOwnProperty.call(n,e))continue;let r=e.startsWith(this.options.attributeNamePrefix)?e.substring(this.options.attributeNamePrefix.length):e,i=n[e];i===!0&&this.options.suppressBooleanAttributes?t+=` `+r:t+=` `+r+`="`+i+`"`}}else for(let n in e){if(!Object.prototype.hasOwnProperty.call(e,n))continue;let r=this.isAttribute(n);if(r){let i=e[n];i===!0&&this.options.suppressBooleanAttributes?t+=` `+r:t+=` `+r+`="`+i+`"`}}return t},B.prototype.buildObjectNode=function(e,t,n,r){if(e===``)return t[0]===`?`?this.indentate(r)+`<`+t+n+`?`+this.tagEndChar:this.indentate(r)+`<`+t+n+this.closeTag(t)+this.tagEndChar;{let i=`</`+t+this.tagEndChar,a=``;return t[0]===`?`&&(a=`?`,i=``),(n||n===``)&&e.indexOf(`<`)===-1?this.indentate(r)+`<`+t+n+a+`>`+e+i:this.options.commentPropName!==!1&&t===this.options.commentPropName&&a.length===0?this.indentate(r)+`<!--${e}-->`+this.newLine:this.indentate(r)+`<`+t+n+a+this.tagEndChar+e+this.indentate(r)+i}},B.prototype.closeTag=function(e){let t=``;return this.options.unpairedTags.indexOf(e)===-1?t=this.options.suppressEmptyNode?`/`:`></${e}`:this.options.suppressUnpairedNode||(t=`/`),t},B.prototype.checkStopNode=function(e){if(!this.stopNodeExpressions||this.stopNodeExpressions.length===0)return!1;for(let t=0;t<this.stopNodeExpressions.length;t++)if(e.matches(this.stopNodeExpressions[t]))return!0;return!1},B.prototype.buildTextValNode=function(e,t,n,r,i){if(this.options.cdataPropName!==!1&&t===this.options.cdataPropName){let t=String(e).replace(/\]\]>/g,`]]]]><![CDATA[>`);return this.indentate(r)+`<![CDATA[${t}]]>`+this.newLine}else if(this.options.commentPropName!==!1&&t===this.options.commentPropName){let t=String(e).replace(/--/g,`- -`).replace(/-$/,`- `);return this.indentate(r)+`<!--${t}-->`+this.newLine}else if(t[0]===`?`)return this.indentate(r)+`<`+t+n+`?`+this.tagEndChar;else{let i=this.options.tagValueProcessor(t,e);return i=this.replaceEntitiesValue(i),i===``?this.indentate(r)+`<`+t+n+this.closeTag(t)+this.tagEndChar:this.indentate(r)+`<`+t+n+`>`+i+`</`+t+this.tagEndChar}},B.prototype.replaceEntitiesValue=function(e){if(e&&e.length>0&&this.options.processEntities)for(let t=0;t<this.options.entities.length;t++){let n=this.options.entities[t];e=e.replace(n.regex,n.val)}return e};function $l(e){return this.options.indentBy.repeat(e)}function eu(e){return e.startsWith(this.options.attributeNamePrefix)&&e!==this.options.textNodeName?e.substr(this.attrPrefixLen):!1}var tu=B,nu=class{axiosClient;baseURI;xmlParser;signingKey;ALGORITHM=`sha512`;TTL=1200;HASH_LENGTH=32;ITERATION_COUNT=1e4;constructor({axiosClient:e,baseURI:t}){this.axiosClient=e,this.baseURI=t,this.xmlParser=new Bl}async signUrl(e,t){let n=new URL(e);n.searchParams.set(`OC-Credential`,t),n.searchParams.set(`OC-Date`,new Date().toISOString()),n.searchParams.set(`OC-Expires`,this.TTL.toString()),n.searchParams.set(`OC-Verb`,`GET`);let r=await this.createHashedKey(n.toString());return n.searchParams.set(`OC-Algo`,`PBKDF2/${this.ITERATION_COUNT}-SHA512`),n.searchParams.set(`OC-Signature`,r),n.toString()}async getSignKey(){if(this.signingKey)return this.signingKey;let e=await this.axiosClient.get(j(this.baseURI,`ocs/v1.php/cloud/user/signing-key`),{headers:{"Content-Type":`application/x-www-form-urlencoded`}}),t=this.xmlParser.parse(e.data);return this.signingKey=t.ocs.data[`signing-key`],this.signingKey}async createHashedKey(e){return Qs(e,await this.getSignKey(),this.ITERATION_COUNT,this.HASH_LENGTH,this.ALGORITHM).toString(`hex`)}};let ru=(e,t)=>{let n=new URL(e);n.pathname=[...n.pathname.split(`/`),`ocs`,`v1.php`].filter(Boolean).join(`/`);let r=n.href,i=ss(r,t),a=new nu({baseURI:e,axiosClient:t});return{getCapabilities:()=>i.getCapabilities(),signUrl:(e,t)=>a.signUrl(e,t)}},iu=(e,{fileId:t,path:n,name:r})=>{if(n!==void 0)return j(e.webDavPath,n);if(t!==void 0){if(ns(e))throw Error(`public spaces need a path provided`);return j(`spaces`,t,r||``)}return e.webDavPath},au=(e,t)=>({copyFiles(t,{path:n,fileId:r},i,{path:a,parentFolderId:o,name:s},{overwrite:c,...l}={}){let u=iu(t,{fileId:r,path:n}),d=iu(i,{fileId:o,path:a,name:s});return e.copy(u,d,{overwrite:c||!1,...l})}}),ou=(e,t,n)=>({async createFolder(n,{path:r,parentFolderId:i,folderName:a,fetchFolder:o=!0,...s}){let c=iu(n,{fileId:i,path:r,name:a});if(await e.mkcol(c),o)return t.getFileInfo(n,{path:r},s)}}),su=(e,{axiosClient:t})=>({async getFileContents(n,{fileId:r,path:i},{responseType:a=`text`,noCache:o=!0,headers:s,...c}={}){try{let l=iu(n,{fileId:r,path:i}),u=await t.get(e.getFileUrl(l),{responseType:a,headers:{...o&&{"Cache-Control":`no-cache`},...s||{}},...c});return{response:u,body:u.data,headers:{ETag:u.headers.etag,"OC-ETag":u.headers[`oc-etag`],"OC-FileId":u.headers[`oc-fileid`]}}}catch(e){let{message:t,response:n}=e;throw new Jn(t,n,n.status)}}}),cu=(e,t)=>({async getFileInfo(t,n,r){return(await e.listFiles(t,n,{depth:0,...r})).resource}}),lu=(e,t,n,{axiosClient:r,baseUrl:i})=>({async getFileUrl(a,o,{disposition:s=`attachment`,version:c=null,username:l=``,...u}){if(s===`inline`){let e=await t.getFileContents(a,o,{responseType:`blob`,...u});return URL.createObjectURL(e.body)}if(c){if(!l)throw Error(`username is required for URL signing`);let t=e.getFileUrl(j(`meta`,o.fileId,`v`,c));return await ru(i,r).signUrl(t,l)}if(o.downloadURL)return o.downloadURL;let{downloadURL:d}=await n.getFileInfo(a,o,{davProperties:[N.DownloadURL]});return d},revokeUrl:e=>{e&&e.startsWith(`blob:`)&&URL.revokeObjectURL(e)}}),uu=(e,t)=>({getPublicFileUrl(t,n){return e.getFileUrl(j(`public-files`,n))}}),du=(e,t,n)=>({async listFiles(n,{path:r,fileId:i}={},{depth:a=1,davProperties:o,isTrash:s=!1,...c}={}){let l;if(ns(n)){l=await e.propfind(j(n.webDavPath,r),{depth:a,properties:o||ir.PublicLink,...c}),l.forEach(e=>{e.filename=e.filename.split(`/`).slice(1).join(`/`)}),l.length===1&&(l[0].filename=j(n.id,r,{leadingSlash:!0})),l.forEach(e=>{e.filename=e.filename.split(`/`).slice(2).join(`/`)});let t=n.driveAlias.startsWith(`ocm/`)?`ocm`:`public-link`;if((!r||r===`/`)&&a>0&&t===`ocm`&&l[0].props[N.PublicLinkItemType]===`file`&&(l=[{basename:n.fileId,type:`directory`,filename:``,props:{}},...l]),!r){let[r,...i]=l;return{resource:as({...r,id:n.id,driveAlias:n.driveAlias,webDavPath:n.webDavPath,publicLinkType:t}),children:i.map(t=>Zo(t,e.extraProps))}}let i=l.map(t=>Zo(t,e.extraProps));return{resource:i[0],children:i.slice(1)}}let u=async()=>{let e=await t.getPathForFileId(i);return this.listFiles(n,{path:e},{depth:a,davProperties:o})};try{let t=``;if(t=s?is(n.id):iu(n,{fileId:i,path:r}),l=await e.propfind(t,{depth:a,properties:o||ir.Default,...c}),s)return{resource:Zo(l[0],e.extraProps),children:l.slice(1).map(Qo)};let d=l.map(t=>Zo(t,e.extraProps)),f=i===n.id;return i&&!f&&d[0].fileId&&i!==d[0].fileId?u():{resource:d[0],children:d.slice(1)}}catch(e){if(e.statusCode===404&&i)return u();throw e}}}),fu=(e,t)=>({moveFiles(t,{path:n,fileId:r},i,{path:a,parentFolderId:o,name:s},{overwrite:c,...l}={}){let u=iu(t,{fileId:r,path:n}),d=iu(i,{fileId:o,path:a,name:s});return e.move(u,d,{overwrite:c||!1,...l})}}),pu=(e,t,n)=>({async putFileContents(n,{fileName:r,path:i,parentFolderId:a,content:o=``,previousEntityTag:s=``,overwrite:c,onUploadProgress:l=null,...u}){let d=iu(n,{fileId:a,name:r,path:i}),{result:f}=await e.put(d,o,{previousEntityTag:s,overwrite:c,onUploadProgress:l,...u});return t.getFileInfo(n,{fileId:f.headers.get(`Oc-Fileid`),path:i})}}),mu=(e,t)=>({deleteFile(t,{path:n,...r}){return e.delete(j(t.webDavPath,n),r)}}),hu=(e,t)=>({restoreFile(t,{id:n},{path:r},{overwrite:i,...a}={}){if(ns(t))return;let o=j(t.webDavPath,r);return e.move(j(t.webDavTrashPath,n),o,{overwrite:i,...a})}}),gu=(e,t)=>({restoreFileVersion(t,{parentFolderId:n,name:r,path:i},a,o={}){let s=iu(t,{path:i,fileId:n,name:r}),c=j(`meta`,n,`v`,a,{leadingSlash:!0}),l=j(`files`,s,{leadingSlash:!0});return e.copy(c,l,o)}}),_u=(e,t)=>({clearTrashBin(t,{id:n,...r}={}){let i=is(t.id);return n&&(i=j(i,n)),e.delete(i,r)}}),vu=(e,t)=>({async search(t,{davProperties:n=ir.Default,searchLimit:r,...i}){let{range:a,results:o}=await e.report(`/spaces/`,{pattern:t,limit:r,properties:n,...i});return{resources:o.map(t=>({...Zo(t,e.extraProps),highlights:t.props[N.Highlights]||``})),totalResults:a?parseInt(a?.split(`/`)[1]):null}}}),yu=(e,t)=>({async getPathForFileId(t,n={}){return(await e.propfind(j(`meta`,t,{leadingSlash:!0}),{properties:[N.MetaPathForUser],...n}))[0].props[N.MetaPathForUser]}});