@opencloud-eu/web-pkg 5.1.0 → 6.1.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 (224) hide show
  1. package/dist/TextEditor-B0ZZfO_w.js +819 -0
  2. package/dist/assets/worker-BVTM6bn-.js +1 -0
  3. package/dist/assets/worker-C-Nrpmiq.js +24 -0
  4. package/dist/assets/worker-CzI1mBNb.js +24 -0
  5. package/dist/assets/worker-DDmV-och.js +24 -0
  6. package/dist/composables-TkULFBg4.js +20165 -0
  7. package/dist/src/apps/types.d.ts +9 -12
  8. package/dist/src/components/AppBar/AppBar.vue.d.ts +154 -96
  9. package/dist/src/components/AppBar/index.d.ts +0 -1
  10. package/dist/src/components/AppLoadingSpinner.vue.d.ts +2 -1
  11. package/dist/src/components/AppTemplates/AppWrapper.vue.d.ts +37 -33
  12. package/dist/src/components/AppTemplates/AppWrapperRoute.d.ts +1 -1
  13. package/dist/src/components/AppTemplates/PartialViews/ErrorScreen.vue.d.ts +5 -4
  14. package/dist/src/components/AppTemplates/PartialViews/LoadingScreen.vue.d.ts +2 -1
  15. package/dist/src/components/AppTopBar.vue.d.ts +13 -4
  16. package/dist/src/components/Avatars/AvatarUpload.vue.d.ts +3 -4
  17. package/dist/src/components/Avatars/UserAvatar.vue.d.ts +11 -1
  18. package/dist/src/components/BatchActions.vue.d.ts +16 -15
  19. package/dist/src/components/ContextActions/ActionMenuDropItem.vue.d.ts +11 -2
  20. package/dist/src/components/ContextActions/ActionMenuItem.vue.d.ts +9 -8
  21. package/dist/src/components/ContextActions/ContextActionMenu.vue.d.ts +41 -22
  22. package/dist/src/components/ContextActions/ContextMenuQuickAction.vue.d.ts +176 -23
  23. package/dist/src/components/CreateLinkModal.vue.d.ts +17 -7
  24. package/dist/src/components/CreateShortcutModal.vue.d.ts +233 -0
  25. package/dist/src/components/CustomComponentTarget.vue.d.ts +12 -13
  26. package/dist/src/components/FilesList/ContextActions.vue.d.ts +56 -37
  27. package/dist/src/components/FilesList/ResourceGhostElement.vue.d.ts +22 -11
  28. package/dist/src/components/FilesList/ResourceIcon.vue.d.ts +10 -1
  29. package/dist/src/components/FilesList/ResourceLink.vue.d.ts +7 -6
  30. package/dist/src/components/FilesList/ResourceListItem.vue.d.ts +13 -4
  31. package/dist/src/components/FilesList/ResourceName.vue.d.ts +10 -1
  32. package/dist/src/components/FilesList/ResourceSize.vue.d.ts +6 -5
  33. package/dist/src/components/FilesList/ResourceStatusIndicators.vue.d.ts +10 -1
  34. package/dist/src/components/FilesList/ResourceTable.vue.d.ts +51 -154
  35. package/dist/src/components/FilesList/ResourceTile.vue.d.ts +37 -153
  36. package/dist/src/components/FilesList/ResourceTiles.vue.d.ts +34 -119
  37. package/dist/src/components/Filters/DateFilter.vue.d.ts +37 -0
  38. package/dist/src/components/Filters/ItemFilterInline.vue.d.ts +6 -5
  39. package/dist/src/components/Groupware/Accounts/AccountsSwitch.vue.d.ts +3 -0
  40. package/dist/src/components/Groupware/Accounts/index.d.ts +1 -0
  41. package/dist/src/components/Groupware/index.d.ts +1 -0
  42. package/dist/src/components/ItemFilter.vue.d.ts +19 -204
  43. package/dist/src/components/ItemFilterToggle.vue.d.ts +6 -5
  44. package/dist/src/components/LinkRoleDropdown.vue.d.ts +7 -6
  45. package/dist/src/components/LoadingIndicator.vue.d.ts +5 -4
  46. package/dist/src/components/Modals/DatePickerModal.vue.d.ts +8 -7
  47. package/dist/src/components/Modals/EmojiPickerModal.vue.d.ts +6 -5
  48. package/dist/src/components/Modals/FilePickerModal.vue.d.ts +8 -7
  49. package/dist/src/components/Modals/ResourceConflictModal.vue.d.ts +9 -8
  50. package/dist/src/components/Modals/SaveAsModal.vue.d.ts +8 -7
  51. package/dist/src/components/Modals/SpaceMoveInfoModal.vue.d.ts +5 -4
  52. package/dist/src/components/Modals/UnsavedChangesModal.vue.d.ts +5 -4
  53. package/dist/src/components/Navigation/MobileNav.vue.d.ts +3 -0
  54. package/dist/src/components/Navigation/index.d.ts +1 -0
  55. package/dist/src/components/NoContentMessage.vue.d.ts +19 -13
  56. package/dist/src/components/Pagination.vue.d.ts +5 -4
  57. package/dist/src/components/QuotaSelect.vue.d.ts +7 -6
  58. package/dist/src/components/Search/ResourcePreview.vue.d.ts +10 -41
  59. package/dist/src/components/SearchBarFilter.vue.d.ts +7 -6
  60. package/dist/src/components/SideBar/CompareSaveDialog.vue.d.ts +6 -5
  61. package/dist/src/components/SideBar/FileSideBar.vue.d.ts +10 -75
  62. package/dist/src/components/SideBar/Files/FileInfo.vue.d.ts +10 -1
  63. package/dist/src/components/SideBar/SideBar.vue.d.ts +20 -21
  64. package/dist/src/components/SideBar/SideBarPanels.vue.d.ts +21 -22
  65. package/dist/src/components/SideBar/Spaces/Details/SpaceDetails.vue.d.ts +10 -1
  66. package/dist/src/components/SideBar/Spaces/Details/SpaceDetailsMultiple.vue.d.ts +10 -1
  67. package/dist/src/components/SideBar/Spaces/SpaceInfo.vue.d.ts +2 -1
  68. package/dist/src/components/SideBar/Spaces/SpaceNoSelection.vue.d.ts +2 -1
  69. package/dist/src/components/SideBar/WebDavDetails.vue.d.ts +7 -6
  70. package/dist/src/components/SpaceQuota.vue.d.ts +10 -1
  71. package/dist/src/components/Spaces/QuotaModal.vue.d.ts +13 -4
  72. package/dist/src/components/Spaces/SpaceImageModal.vue.d.ts +12 -4
  73. package/dist/src/components/TextEditor/TextEditor.vue.d.ts +22 -161
  74. package/dist/src/components/TextEditor/index.d.ts +16 -138
  75. package/dist/src/components/VersionCheck.vue.d.ts +2 -1
  76. package/dist/src/components/ViewOptions.vue.d.ts +10 -1
  77. package/dist/src/components/index.d.ts +2 -1
  78. package/dist/src/composables/actions/files/useFileActionFallbackToDownload.d.ts +1 -1
  79. package/dist/src/composables/actions/files/useFileActions.d.ts +2 -2
  80. package/dist/src/composables/actions/files/useFileActionsCopy.d.ts +1 -1
  81. package/dist/src/composables/actions/files/useFileActionsCopyPermanentLink.d.ts +1 -1
  82. package/dist/src/composables/actions/files/useFileActionsCreateLink.d.ts +1 -1
  83. package/dist/src/composables/actions/files/useFileActionsCreateNewFile.d.ts +1 -1
  84. package/dist/src/composables/actions/files/useFileActionsCreateNewFolder.d.ts +1 -1
  85. package/dist/src/composables/actions/files/useFileActionsCreateNewShortcut.d.ts +1 -1
  86. package/dist/src/composables/actions/files/useFileActionsCreateSpaceFromResource.d.ts +1 -1
  87. package/dist/src/composables/actions/files/useFileActionsDelete.d.ts +1 -1
  88. package/dist/src/composables/actions/files/useFileActionsDisableSync.d.ts +1 -1
  89. package/dist/src/composables/actions/files/useFileActionsDownloadArchive.d.ts +1 -1
  90. package/dist/src/composables/actions/files/useFileActionsDownloadFile.d.ts +1 -1
  91. package/dist/src/composables/actions/files/useFileActionsEmptyTrashBin.d.ts +1 -1
  92. package/dist/src/composables/actions/files/useFileActionsEnableSync.d.ts +1 -1
  93. package/dist/src/composables/actions/files/useFileActionsFavorite.d.ts +1 -1
  94. package/dist/src/composables/actions/files/useFileActionsMove.d.ts +1 -1
  95. package/dist/src/composables/actions/files/useFileActionsNavigate.d.ts +1 -1
  96. package/dist/src/composables/actions/files/useFileActionsOpenShortcut.d.ts +1 -1
  97. package/dist/src/composables/actions/files/useFileActionsOpenWithApp.d.ts +1 -1
  98. package/dist/src/composables/actions/files/useFileActionsOpenWithDefault.d.ts +1 -1
  99. package/dist/src/composables/actions/files/useFileActionsPaste.d.ts +1 -1
  100. package/dist/src/composables/actions/files/useFileActionsRename.d.ts +2 -2
  101. package/dist/src/composables/actions/files/useFileActionsRestore.d.ts +2 -2
  102. package/dist/src/composables/actions/files/useFileActionsSaveAs.d.ts +1 -1
  103. package/dist/src/composables/actions/files/useFileActionsSetImage.d.ts +1 -1
  104. package/dist/src/composables/actions/files/useFileActionsShowActions.d.ts +1 -1
  105. package/dist/src/composables/actions/files/useFileActionsShowDetails.d.ts +1 -1
  106. package/dist/src/composables/actions/files/useFileActionsShowShares.d.ts +1 -1
  107. package/dist/src/composables/actions/files/useFileActionsToggleHideShare.d.ts +1 -1
  108. package/dist/src/composables/actions/files/useFileActionsUndoDelete.d.ts +2 -2
  109. package/dist/src/composables/actions/helpers/useIsAppActive.d.ts +1 -1
  110. package/dist/src/composables/actions/helpers/useIsFilesAppActive.d.ts +1 -1
  111. package/dist/src/composables/actions/helpers/useIsSearchActive.d.ts +1 -1
  112. package/dist/src/composables/actions/spaces/index.d.ts +1 -0
  113. package/dist/src/composables/actions/spaces/useSpaceActionsCreate.d.ts +7 -0
  114. package/dist/src/composables/actions/spaces/useSpaceActionsDelete.d.ts +1 -1
  115. package/dist/src/composables/actions/spaces/useSpaceActionsDeleteImage.d.ts +1 -1
  116. package/dist/src/composables/actions/spaces/useSpaceActionsDisable.d.ts +1 -1
  117. package/dist/src/composables/actions/spaces/useSpaceActionsDuplicate.d.ts +1 -1
  118. package/dist/src/composables/actions/spaces/useSpaceActionsEditDescription.d.ts +1 -1
  119. package/dist/src/composables/actions/spaces/useSpaceActionsEditQuota.d.ts +1 -1
  120. package/dist/src/composables/actions/spaces/useSpaceActionsEditReadmeContent.d.ts +1 -1
  121. package/dist/src/composables/actions/spaces/useSpaceActionsNavigateToTrash.d.ts +1 -1
  122. package/dist/src/composables/actions/spaces/useSpaceActionsRename.d.ts +1 -1
  123. package/dist/src/composables/actions/spaces/useSpaceActionsRestore.d.ts +1 -1
  124. package/dist/src/composables/actions/spaces/useSpaceActionsSetIcon.d.ts +1 -1
  125. package/dist/src/composables/actions/spaces/useSpaceActionsShowMembers.d.ts +1 -1
  126. package/dist/src/composables/actions/useActionsShowDetails.d.ts +1 -1
  127. package/dist/src/composables/appDefaults/useAppConfig.d.ts +1 -1
  128. package/dist/src/composables/appDefaults/useAppDocumentTitle.d.ts +2 -1
  129. package/dist/src/composables/appDefaults/useAppFileHandling.d.ts +4 -2
  130. package/dist/src/composables/appDefaults/useAppMeta.d.ts +1 -1
  131. package/dist/src/composables/authContext/useAuthService.d.ts +3 -1
  132. package/dist/src/composables/authContext/useRequest.d.ts +2 -2
  133. package/dist/src/composables/driveResolver/useSpacesLoading.d.ts +1 -1
  134. package/dist/src/composables/embedMode/useEmbedMode.d.ts +8 -8
  135. package/dist/src/composables/eventBus/useEventBus.d.ts +1 -1
  136. package/dist/src/composables/filesList/useResourceRouteResolver.d.ts +1 -1
  137. package/dist/src/composables/folderLink/useFolderLink.d.ts +2 -2
  138. package/dist/src/composables/index.d.ts +1 -1
  139. package/dist/src/composables/isTopBarSticky/useIsTopBarSticky.d.ts +1 -1
  140. package/dist/src/composables/keyboardActions/useInterceptModifierClick.d.ts +1 -1
  141. package/dist/src/composables/links/useLinkTypes.d.ts +1 -1
  142. package/dist/src/composables/localStorage/useLocalStorage.d.ts +1 -1
  143. package/dist/src/composables/navItems/index.d.ts +1 -0
  144. package/dist/src/composables/navItems/useNavItems.d.ts +13 -0
  145. package/dist/src/composables/piniaStores/apps.d.ts +31 -31
  146. package/dist/src/composables/piniaStores/auth.d.ts +30 -24
  147. package/dist/src/composables/piniaStores/avatars.d.ts +9 -9
  148. package/dist/src/composables/piniaStores/capabilities.d.ts +160 -160
  149. package/dist/src/composables/piniaStores/clipboard.d.ts +49 -49
  150. package/dist/src/composables/piniaStores/config/config.d.ts +135 -141
  151. package/dist/src/composables/piniaStores/config/types.d.ts +6 -20
  152. package/dist/src/composables/piniaStores/extensionRegistry/extensionPreferences.d.ts +4 -4
  153. package/dist/src/composables/piniaStores/extensionRegistry/extensionRegistry.d.ts +1 -1
  154. package/dist/src/composables/piniaStores/extensionRegistry/types.d.ts +14 -1
  155. package/dist/src/composables/piniaStores/groupware/accounts.d.ts +511 -0
  156. package/dist/src/composables/piniaStores/{groupwareConfig/groupwareConfig.d.ts → groupware/config.d.ts} +107 -80
  157. package/dist/src/composables/piniaStores/groupware/index.d.ts +3 -0
  158. package/dist/src/composables/piniaStores/{groupwareConfig → groupware}/types.d.ts +30 -18
  159. package/dist/src/composables/piniaStores/index.d.ts +1 -1
  160. package/dist/src/composables/piniaStores/messages.d.ts +70 -70
  161. package/dist/src/composables/piniaStores/modals.d.ts +197 -209
  162. package/dist/src/composables/piniaStores/resources.d.ts +11 -11
  163. package/dist/src/composables/piniaStores/shares/shares.d.ts +1 -1
  164. package/dist/src/composables/piniaStores/shares/types.d.ts +2 -1
  165. package/dist/src/composables/piniaStores/sideBar.d.ts +8 -22
  166. package/dist/src/composables/piniaStores/spaces.d.ts +189 -188
  167. package/dist/src/composables/piniaStores/theme.d.ts +10 -10
  168. package/dist/src/composables/piniaStores/updates.d.ts +10 -10
  169. package/dist/src/composables/piniaStores/user.d.ts +5 -5
  170. package/dist/src/composables/piniaStores/webWorkers.d.ts +1 -1
  171. package/dist/src/composables/requestHeaders/useRequestHeaders.d.ts +1 -1
  172. package/dist/src/composables/resources/useGetResourceContext.d.ts +26 -26
  173. package/dist/src/composables/resources/useLoadPreview.d.ts +1 -1
  174. package/dist/src/composables/resources/useResourceContents.d.ts +1 -1
  175. package/dist/src/composables/resources/useResourceIndicators.d.ts +12 -1
  176. package/dist/src/composables/resources/useResourceViewContextMenu.d.ts +4 -3
  177. package/dist/src/composables/resources/useResourceViewDrag.d.ts +23 -13
  178. package/dist/src/composables/resources/useResourceViewHelpers.d.ts +30 -20
  179. package/dist/src/composables/resources/useResourceViewSelection.d.ts +2 -2
  180. package/dist/src/composables/selection/useSelectedResources.d.ts +2 -1
  181. package/dist/src/composables/spaces/useCreateSpace.d.ts +2 -1
  182. package/dist/src/composables/spaces/useSpaceHelpers.d.ts +1 -1
  183. package/dist/src/composables/webWorkers/deleteWorker/useDeleteWorker.d.ts +1 -1
  184. package/dist/src/composables/webWorkers/pasteWorker/usePasteWorker.d.ts +2 -2
  185. package/dist/src/composables/webWorkers/restoreWorker/useRestoreWorker.d.ts +1 -1
  186. package/dist/src/composables/webWorkers/tokenTimerWorker/useTokenTimerWorker.d.ts +3 -1
  187. package/dist/src/constants.d.ts +0 -6
  188. package/dist/src/extensionPoints.d.ts +3 -0
  189. package/dist/src/helpers/filesize.d.ts +0 -7
  190. package/dist/src/helpers/index.d.ts +1 -2
  191. package/dist/src/helpers/resource/conflictHandling/conflictDialog.d.ts +1 -1
  192. package/dist/src/helpers/resource/conflictHandling/transfer.d.ts +4 -4
  193. package/dist/src/helpers/resource/conflictHandling/types.d.ts +1 -1
  194. package/dist/src/helpers/share/driveItem.d.ts +1 -1
  195. package/dist/src/helpers/versions.d.ts +5 -0
  196. package/dist/src/index.d.ts +1 -0
  197. package/dist/src/router/common.d.ts +1 -1
  198. package/dist/src/router/index.d.ts +2 -1
  199. package/dist/src/router/public.d.ts +1 -1
  200. package/dist/src/router/shares.d.ts +1 -1
  201. package/dist/src/router/spaces.d.ts +1 -1
  202. package/dist/src/router/trash.d.ts +1 -1
  203. package/dist/src/services/passwordPolicy/rules.d.ts +3 -9
  204. package/dist/src/services/preview/types.d.ts +1 -1
  205. package/dist/src/services/uppy/DropTarget/plugin.d.ts +2 -1
  206. package/dist/src/services/uppy/uppyService.d.ts +3 -3
  207. package/dist/web-pkg.js +4251 -354
  208. package/package.json +36 -38
  209. package/src/index.ts +1 -0
  210. package/dist/TextEditor-CXSedGM4.js +0 -867
  211. package/dist/assets/worker-22sDKzz_.js +0 -21
  212. package/dist/assets/worker-BBQqm_-D.js +0 -1
  213. package/dist/assets/worker-BSCY2vwA.js +0 -21
  214. package/dist/assets/worker-DH8D29Kr.js +0 -21
  215. package/dist/index-CEJcEmbf.js +0 -25419
  216. package/dist/src/components/AppBar/CreateSpace.vue.d.ts +0 -18
  217. package/dist/src/components/PortalTarget.vue.d.ts +0 -2
  218. package/dist/src/composables/piniaStores/groupwareConfig/index.d.ts +0 -2
  219. package/dist/src/composables/portalTarget/eventTopics.d.ts +0 -3
  220. package/dist/src/composables/portalTarget/index.d.ts +0 -2
  221. package/dist/src/composables/portalTarget/usePortalTarget.d.ts +0 -4
  222. package/dist/src/helpers/contextMenuDropdown.d.ts +0 -7
  223. package/dist/src/helpers/statusIndicators.d.ts +0 -12
  224. package/dist/web-pkg.umd.cjs +0 -36
@@ -1,21 +0,0 @@
1
- (function(){"use strict";function Dn(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var _r={exports:{}},Vn;function Xo(){return Vn||(Vn=1,(function(t){var e=Object.prototype.hasOwnProperty,r="~";function n(){}Object.create&&(n.prototype=Object.create(null),new n().__proto__||(r=!1));function i(l,c,a){this.fn=l,this.context=c,this.once=a||!1}function s(l,c,a,h,p){if(typeof a!="function")throw new TypeError("The listener must be a function");var b=new i(a,h||l,p),g=r?r+c:c;return l._events[g]?l._events[g].fn?l._events[g]=[l._events[g],b]:l._events[g].push(b):(l._events[g]=b,l._eventsCount++),l}function o(l,c){--l._eventsCount===0?l._events=new n:delete l._events[c]}function u(){this._events=new n,this._eventsCount=0}u.prototype.eventNames=function(){var c=[],a,h;if(this._eventsCount===0)return c;for(h in a=this._events)e.call(a,h)&&c.push(r?h.slice(1):h);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(a)):c},u.prototype.listeners=function(c){var a=r?r+c:c,h=this._events[a];if(!h)return[];if(h.fn)return[h.fn];for(var p=0,b=h.length,g=new Array(b);p<b;p++)g[p]=h[p].fn;return g},u.prototype.listenerCount=function(c){var a=r?r+c:c,h=this._events[a];return h?h.fn?1:h.length:0},u.prototype.emit=function(c,a,h,p,b,g){var m=r?r+c:c;if(!this._events[m])return!1;var y=this._events[m],v=arguments.length,E,T;if(y.fn){switch(y.once&&this.removeListener(c,y.fn,void 0,!0),v){case 1:return y.fn.call(y.context),!0;case 2:return y.fn.call(y.context,a),!0;case 3:return y.fn.call(y.context,a,h),!0;case 4:return y.fn.call(y.context,a,h,p),!0;case 5:return y.fn.call(y.context,a,h,p,b),!0;case 6:return y.fn.call(y.context,a,h,p,b,g),!0}for(T=1,E=new Array(v-1);T<v;T++)E[T-1]=arguments[T];y.fn.apply(y.context,E)}else{var N=y.length,S;for(T=0;T<N;T++)switch(y[T].once&&this.removeListener(c,y[T].fn,void 0,!0),v){case 1:y[T].fn.call(y[T].context);break;case 2:y[T].fn.call(y[T].context,a);break;case 3:y[T].fn.call(y[T].context,a,h);break;case 4:y[T].fn.call(y[T].context,a,h,p);break;default:if(!E)for(S=1,E=new Array(v-1);S<v;S++)E[S-1]=arguments[S];y[T].fn.apply(y[T].context,E)}}return!0},u.prototype.on=function(c,a,h){return s(this,c,a,h,!1)},u.prototype.once=function(c,a,h){return s(this,c,a,h,!0)},u.prototype.removeListener=function(c,a,h,p){var b=r?r+c:c;if(!this._events[b])return this;if(!a)return o(this,b),this;var g=this._events[b];if(g.fn)g.fn===a&&(!p||g.once)&&(!h||g.context===h)&&o(this,b);else{for(var m=0,y=[],v=g.length;m<v;m++)(g[m].fn!==a||p&&!g[m].once||h&&g[m].context!==h)&&y.push(g[m]);y.length?this._events[b]=y.length===1?y[0]:y:o(this,b)}return this},u.prototype.removeAllListeners=function(c){var a;return c?(a=r?r+c:c,this._events[a]&&o(this,a)):(this._events=new n,this._eventsCount=0),this},u.prototype.off=u.prototype.removeListener,u.prototype.addListener=u.prototype.on,u.prefixed=r,u.EventEmitter=u,t.exports=u})(_r)),_r.exports}var Yo=Xo(),Zo=Dn(Yo);class Ur extends Error{name="TimeoutError";constructor(e,r){super(e,r),Error.captureStackTrace?.(this,Ur)}}const Hn=t=>t.reason??new DOMException("This operation was aborted.","AbortError");function Qo(t,e){const{milliseconds:r,fallback:n,message:i,customTimers:s={setTimeout,clearTimeout},signal:o}=e;let u,l;const a=new Promise((h,p)=>{if(typeof r!="number"||Math.sign(r)!==1)throw new TypeError(`Expected \`milliseconds\` to be a positive number, got \`${r}\``);if(o?.aborted){p(Hn(o));return}if(o&&(l=()=>{p(Hn(o))},o.addEventListener("abort",l,{once:!0})),t.then(h,p),r===Number.POSITIVE_INFINITY)return;const b=new Ur;u=s.setTimeout.call(void 0,()=>{if(n){try{h(n())}catch(g){p(g)}return}typeof t.cancel=="function"&&t.cancel(),i===!1?h():i instanceof Error?p(i):(b.message=i??`Promise timed out after ${r} milliseconds`,p(b))},r)}).finally(()=>{a.clear(),l&&o&&o.removeEventListener("abort",l)});return a.clear=()=>{s.clearTimeout.call(void 0,u),u=void 0},a}function ea(t,e,r){let n=0,i=t.length;for(;i>0;){const s=Math.trunc(i/2);let o=n+s;r(t[o],e)<=0?(n=++o,i-=s+1):i=s}return n}class ta{#e=[];enqueue(e,r){const{priority:n=0,id:i}=r??{},s={priority:n,id:i,run:e};if(this.size===0||this.#e[this.size-1].priority>=n){this.#e.push(s);return}const o=ea(this.#e,s,(u,l)=>l.priority-u.priority);this.#e.splice(o,0,s)}setPriority(e,r){const n=this.#e.findIndex(s=>s.id===e);if(n===-1)throw new ReferenceError(`No promise function with the id "${e}" exists in the queue.`);const[i]=this.#e.splice(n,1);this.enqueue(i.run,{priority:r,id:e})}dequeue(){return this.#e.shift()?.run}filter(e){return this.#e.filter(r=>r.priority===e.priority).map(r=>r.run)}get size(){return this.#e.length}}class ra extends Zo{#e;#r;#s=0;#t;#n=!1;#d=!1;#l;#g=0;#f=0;#c;#p;#h;#o=[];#a=0;#i;#I;#u=0;#w;#m;#F=1n;#x=new Map;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:Number.POSITIVE_INFINITY,interval:0,concurrency:Number.POSITIVE_INFINITY,autoStart:!0,queueClass:ta,strict:!1,...e},!(typeof e.intervalCap=="number"&&e.intervalCap>=1))throw new 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 new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??""}\` (${typeof e.interval})`);if(e.strict&&e.interval===0)throw new TypeError("The `strict` option requires a non-zero `interval`");if(e.strict&&e.intervalCap===Number.POSITIVE_INFINITY)throw new TypeError("The `strict` option requires a finite `intervalCap`");if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#r=e.intervalCap===Number.POSITIVE_INFINITY||e.interval===0,this.#t=e.intervalCap,this.#l=e.interval,this.#h=e.strict,this.#i=new e.queueClass,this.#I=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw new TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#m=e.autoStart===!1,this.#M()}#E(e){for(;this.#a<this.#o.length;){const n=this.#o[this.#a];if(n!==void 0&&e-n>=this.#l)this.#a++;else break}(this.#a>100&&this.#a>this.#o.length/2||this.#a===this.#o.length)&&(this.#o=this.#o.slice(this.#a),this.#a=0)}#L(e){this.#h?this.#o.push(e):this.#s++}#_(){this.#h?this.#o.length>this.#a&&this.#o.pop():this.#s>0&&this.#s--}#v(){return this.#o.length-this.#a}get#U(){return this.#r?!0:this.#h?this.#v()<this.#t:this.#s<this.#t}get#B(){return this.#u<this.#w}#k(){this.#u--,this.#u===0&&this.emit("pendingZero"),this.#N(),this.emit("next")}#$(){this.#p=void 0,this.#C(),this.#O()}#j(e){if(this.#h){if(this.#E(e),this.#v()>=this.#t){const n=this.#o[this.#a],i=this.#l-(e-n);return this.#T(i),!0}return!1}if(this.#c===void 0){const r=this.#g-e;if(r<0){if(this.#f>0){const n=e-this.#f;if(n<this.#l)return this.#T(this.#l-n),!0}this.#s=this.#e?this.#u:0}else return this.#T(r),!0}return!1}#T(e){this.#p===void 0&&(this.#p=setTimeout(()=>{this.#$()},e))}#A(){this.#c&&(clearInterval(this.#c),this.#c=void 0)}#S(){this.#p&&(clearTimeout(this.#p),this.#p=void 0)}#N(){if(this.#i.size===0){if(this.#A(),this.emit("empty"),this.#u===0){if(this.#S(),this.#h&&this.#a>0){const r=Date.now();this.#E(r)}this.emit("idle")}return!1}let e=!1;if(!this.#m){const r=Date.now(),n=!this.#j(r);if(this.#U&&this.#B){const i=this.#i.dequeue();this.#r||(this.#L(r),this.#b()),this.emit("active"),i(),n&&this.#O(),e=!0}}return e}#O(){this.#r||this.#c!==void 0||this.#h||(this.#c=setInterval(()=>{this.#C()},this.#l),this.#g=Date.now()+this.#l)}#C(){this.#h||(this.#s===0&&this.#u===0&&this.#c&&this.#A(),this.#s=this.#e?this.#u:0),this.#P(),this.#b()}#P(){for(;this.#N(););}get concurrency(){return this.#w}set concurrency(e){if(!(typeof e=="number"&&e>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#w=e,this.#P()}setPriority(e,r){if(typeof r!="number"||!Number.isFinite(r))throw new TypeError(`Expected \`priority\` to be a finite number, got \`${r}\` (${typeof r})`);this.#i.setPriority(e,r)}async add(e,r={}){return r={timeout:this.timeout,...r,id:r.id??(this.#F++).toString()},new Promise((n,i)=>{const s=Symbol(`task-${r.id}`);this.#i.enqueue(async()=>{this.#u++,this.#x.set(s,{id:r.id,priority:r.priority??0,startTime:Date.now(),timeout:r.timeout});let o;try{try{r.signal?.throwIfAborted()}catch(c){throw this.#D(),this.#x.delete(s),c}this.#f=Date.now();let u=e({signal:r.signal});if(r.timeout&&(u=Qo(Promise.resolve(u),{milliseconds:r.timeout,message:`Task timed out after ${r.timeout}ms (queue has ${this.#u} running, ${this.#i.size} waiting)`})),r.signal){const{signal:c}=r;u=Promise.race([u,new Promise((a,h)=>{o=()=>{h(c.reason)},c.addEventListener("abort",o,{once:!0})})])}const l=await u;n(l),this.emit("completed",l)}catch(u){i(u),this.emit("error",u)}finally{o&&r.signal?.removeEventListener("abort",o),this.#x.delete(s),queueMicrotask(()=>{this.#k()})}},r),this.emit("add"),this.#N()})}async addAll(e,r){return Promise.all(e.map(async n=>this.add(n,r)))}start(){return this.#m?(this.#m=!1,this.#P(),this):this}pause(){this.#m=!0}clear(){this.#i=new this.#I,this.#A(),this.#R(),this.emit("empty"),this.#u===0&&(this.#S(),this.emit("idle")),this.emit("next")}async onEmpty(){this.#i.size!==0&&await this.#y("empty")}async onSizeLessThan(e){this.#i.size<e||await this.#y("next",()=>this.#i.size<e)}async onIdle(){this.#u===0&&this.#i.size===0||await this.#y("idle")}async onPendingZero(){this.#u!==0&&await this.#y("pendingZero")}async onRateLimit(){this.isRateLimited||await this.#y("rateLimit")}async onRateLimitCleared(){this.isRateLimited&&await this.#y("rateLimitCleared")}onError(){return new Promise((e,r)=>{const n=i=>{this.off("error",n),r(i)};this.on("error",n)})}async#y(e,r){return new Promise(n=>{const i=()=>{r&&!r()||(this.off(e,i),n())};this.on(e,i)})}get size(){return this.#i.size}sizeBy(e){return this.#i.filter(e).length}get pending(){return this.#u}get isPaused(){return this.#m}#M(){this.#r||(this.on("add",()=>{this.#i.size>0&&this.#b()}),this.on("next",()=>{this.#b()}))}#b(){this.#r||this.#d||(this.#d=!0,queueMicrotask(()=>{this.#d=!1,this.#R()}))}#D(){this.#r||(this.#_(),this.#b())}#R(){const e=this.#n;if(this.#r||this.#i.size===0){e&&(this.#n=!1,this.emit("rateLimitCleared"));return}let r;if(this.#h){const i=Date.now();this.#E(i),r=this.#v()}else r=this.#s;const n=r>=this.#t;n!==e&&(this.#n=n,this.emit(n?"rateLimit":"rateLimitCleared"))}get isRateLimited(){return this.#n}get isSaturated(){return this.#u===this.#w&&this.#i.size>0||this.isRateLimited&&this.#i.size>0}get runningTasks(){return[...this.#x.values()].map(e=>({...e}))}}const je=globalThis||void 0||self;function na(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var qn={exports:{}},Z=qn.exports={},Le,_e;function Br(){throw new Error("setTimeout has not been defined")}function kr(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?Le=setTimeout:Le=Br}catch{Le=Br}try{typeof clearTimeout=="function"?_e=clearTimeout:_e=kr}catch{_e=kr}})();function zn(t){if(Le===setTimeout)return setTimeout(t,0);if((Le===Br||!Le)&&setTimeout)return Le=setTimeout,setTimeout(t,0);try{return Le(t,0)}catch{try{return Le.call(null,t,0)}catch{return Le.call(this,t,0)}}}function ia(t){if(_e===clearTimeout)return clearTimeout(t);if((_e===kr||!_e)&&clearTimeout)return _e=clearTimeout,clearTimeout(t);try{return _e(t)}catch{try{return _e.call(null,t)}catch{return _e.call(this,t)}}}var Me=[],dt=!1,et,Zt=-1;function sa(){!dt||!et||(dt=!1,et.length?Me=et.concat(Me):Zt=-1,Me.length&&Wn())}function Wn(){if(!dt){var t=zn(sa);dt=!0;for(var e=Me.length;e;){for(et=Me,Me=[];++Zt<e;)et&&et[Zt].run();Zt=-1,e=Me.length}et=null,dt=!1,ia(t)}}Z.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];Me.push(new Gn(t,e)),Me.length===1&&!dt&&zn(Wn)};function Gn(t,e){this.fun=t,this.array=e}Gn.prototype.run=function(){this.fun.apply(null,this.array)},Z.title="browser",Z.browser=!0,Z.env={},Z.argv=[],Z.version="",Z.versions={};function De(){}Z.on=De,Z.addListener=De,Z.once=De,Z.off=De,Z.removeListener=De,Z.removeAllListeners=De,Z.emit=De,Z.prependListener=De,Z.prependOnceListener=De,Z.listeners=function(t){return[]},Z.binding=function(t){throw new Error("process.binding is not supported")},Z.cwd=function(){return"/"},Z.chdir=function(t){throw new Error("process.chdir is not supported")},Z.umask=function(){return 0};var oa=qn.exports;const Ue=na(oa);function Kn(t,e){return function(){return t.apply(e,arguments)}}const{toString:aa}=Object.prototype,{getPrototypeOf:$r}=Object,{iterator:Qt,toStringTag:Jn}=Symbol,er=(t=>e=>{const r=aa.call(e);return t[r]||(t[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Re=t=>(t=t.toLowerCase(),e=>er(e)===t),tr=t=>e=>typeof e===t,{isArray:pt}=Array,gt=tr("undefined");function St(t){return t!==null&&!gt(t)&&t.constructor!==null&&!gt(t.constructor)&&xe(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Xn=Re("ArrayBuffer");function ua(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Xn(t.buffer),e}const la=tr("string"),xe=tr("function"),Yn=tr("number"),Ot=t=>t!==null&&typeof t=="object",ca=t=>t===!0||t===!1,rr=t=>{if(er(t)!=="object")return!1;const e=$r(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Jn in t)&&!(Qt in t)},fa=t=>{if(!Ot(t)||St(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},ha=Re("Date"),da=Re("File"),pa=Re("Blob"),ga=Re("FileList"),ma=t=>Ot(t)&&xe(t.pipe),ya=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||xe(t.append)&&((e=er(t))==="formdata"||e==="object"&&xe(t.toString)&&t.toString()==="[object FormData]"))},ba=Re("URLSearchParams"),[wa,xa,Ea,va]=["ReadableStream","Request","Response","Headers"].map(Re),Ta=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ct(t,e,{allOwnKeys:r=!1}={}){if(t===null||typeof t>"u")return;let n,i;if(typeof t!="object"&&(t=[t]),pt(t))for(n=0,i=t.length;n<i;n++)e.call(null,t[n],n,t);else{if(St(t))return;const s=r?Object.getOwnPropertyNames(t):Object.keys(t),o=s.length;let u;for(n=0;n<o;n++)u=s[n],e.call(null,t[u],u,t)}}function Zn(t,e){if(St(t))return null;e=e.toLowerCase();const r=Object.keys(t);let n=r.length,i;for(;n-- >0;)if(i=r[n],e===i.toLowerCase())return i;return null}const tt=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:je,Qn=t=>!gt(t)&&t!==tt;function jr(){const{caseless:t,skipUndefined:e}=Qn(this)&&this||{},r={},n=(i,s)=>{if(s==="__proto__"||s==="constructor"||s==="prototype")return;const o=t&&Zn(r,s)||s;rr(r[o])&&rr(i)?r[o]=jr(r[o],i):rr(i)?r[o]=jr({},i):pt(i)?r[o]=i.slice():(!e||!gt(i))&&(r[o]=i)};for(let i=0,s=arguments.length;i<s;i++)arguments[i]&&Ct(arguments[i],n);return r}const Aa=(t,e,r,{allOwnKeys:n}={})=>(Ct(e,(i,s)=>{r&&xe(i)?Object.defineProperty(t,s,{value:Kn(i,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(t,s,{value:i,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),t),Na=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),Pa=(t,e,r,n)=>{t.prototype=Object.create(e.prototype,n),Object.defineProperty(t.prototype,"constructor",{value:t,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(t,"super",{value:e.prototype}),r&&Object.assign(t.prototype,r)},Ia=(t,e,r,n)=>{let i,s,o;const u={};if(e=e||{},t==null)return e;do{for(i=Object.getOwnPropertyNames(t),s=i.length;s-- >0;)o=i[s],(!n||n(o,t,e))&&!u[o]&&(e[o]=t[o],u[o]=!0);t=r!==!1&&$r(t)}while(t&&(!r||r(t,e))&&t!==Object.prototype);return e},Sa=(t,e,r)=>{t=String(t),(r===void 0||r>t.length)&&(r=t.length),r-=e.length;const n=t.indexOf(e,r);return n!==-1&&n===r},Oa=t=>{if(!t)return null;if(pt(t))return t;let e=t.length;if(!Yn(e))return null;const r=new Array(e);for(;e-- >0;)r[e]=t[e];return r},Ca=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&$r(Uint8Array)),Ra=(t,e)=>{const n=(t&&t[Qt]).call(t);let i;for(;(i=n.next())&&!i.done;){const s=i.value;e.call(t,s[0],s[1])}},Fa=(t,e)=>{let r;const n=[];for(;(r=t.exec(e))!==null;)n.push(r);return n},La=Re("HTMLFormElement"),_a=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,i){return n.toUpperCase()+i}),ei=(({hasOwnProperty:t})=>(e,r)=>t.call(e,r))(Object.prototype),Ua=Re("RegExp"),ti=(t,e)=>{const r=Object.getOwnPropertyDescriptors(t),n={};Ct(r,(i,s)=>{let o;(o=e(i,s,t))!==!1&&(n[s]=o||i)}),Object.defineProperties(t,n)},Ba=t=>{ti(t,(e,r)=>{if(xe(t)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=t[r];if(xe(n)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},ka=(t,e)=>{const r={},n=i=>{i.forEach(s=>{r[s]=!0})};return pt(t)?n(t):n(String(t).split(e)),r},$a=()=>{},ja=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function Ma(t){return!!(t&&xe(t.append)&&t[Jn]==="FormData"&&t[Qt])}const Da=t=>{const e=new Array(10),r=(n,i)=>{if(Ot(n)){if(e.indexOf(n)>=0)return;if(St(n))return n;if(!("toJSON"in n)){e[i]=n;const s=pt(n)?[]:{};return Ct(n,(o,u)=>{const l=r(o,i+1);!gt(l)&&(s[u]=l)}),e[i]=void 0,s}}return n};return r(t,0)},Va=Re("AsyncFunction"),Ha=t=>t&&(Ot(t)||xe(t))&&xe(t.then)&&xe(t.catch),ri=((t,e)=>t?setImmediate:e?((r,n)=>(tt.addEventListener("message",({source:i,data:s})=>{i===tt&&s===r&&n.length&&n.shift()()},!1),i=>{n.push(i),tt.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",xe(tt.postMessage)),qa=typeof queueMicrotask<"u"?queueMicrotask.bind(tt):typeof Ue<"u"&&Ue.nextTick||ri;var I={isArray:pt,isArrayBuffer:Xn,isBuffer:St,isFormData:ya,isArrayBufferView:ua,isString:la,isNumber:Yn,isBoolean:ca,isObject:Ot,isPlainObject:rr,isEmptyObject:fa,isReadableStream:wa,isRequest:xa,isResponse:Ea,isHeaders:va,isUndefined:gt,isDate:ha,isFile:da,isBlob:pa,isRegExp:Ua,isFunction:xe,isStream:ma,isURLSearchParams:ba,isTypedArray:Ca,isFileList:ga,forEach:Ct,merge:jr,extend:Aa,trim:Ta,stripBOM:Na,inherits:Pa,toFlatObject:Ia,kindOf:er,kindOfTest:Re,endsWith:Sa,toArray:Oa,forEachEntry:Ra,matchAll:Fa,isHTMLForm:La,hasOwnProperty:ei,hasOwnProp:ei,reduceDescriptors:ti,freezeMethods:Ba,toObjectSet:ka,toCamelCase:_a,noop:$a,toFiniteNumber:ja,findKey:Zn,global:tt,isContextDefined:Qn,isSpecCompliantForm:Ma,toJSONObject:Da,isAsyncFn:Va,isThenable:Ha,setImmediate:ri,asap:qa,isIterable:t=>t!=null&&xe(t[Qt])},ni={},nr={};nr.byteLength=Ga,nr.toByteArray=Ja,nr.fromByteArray=Za;for(var Be=[],Ie=[],za=typeof Uint8Array<"u"?Uint8Array:Array,Mr="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",mt=0,Wa=Mr.length;mt<Wa;++mt)Be[mt]=Mr[mt],Ie[Mr.charCodeAt(mt)]=mt;Ie[45]=62,Ie[95]=63;function ii(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");r===-1&&(r=e);var n=r===e?0:4-r%4;return[r,n]}function Ga(t){var e=ii(t),r=e[0],n=e[1];return(r+n)*3/4-n}function Ka(t,e,r){return(e+r)*3/4-r}function Ja(t){var e,r=ii(t),n=r[0],i=r[1],s=new za(Ka(t,n,i)),o=0,u=i>0?n-4:n,l;for(l=0;l<u;l+=4)e=Ie[t.charCodeAt(l)]<<18|Ie[t.charCodeAt(l+1)]<<12|Ie[t.charCodeAt(l+2)]<<6|Ie[t.charCodeAt(l+3)],s[o++]=e>>16&255,s[o++]=e>>8&255,s[o++]=e&255;return i===2&&(e=Ie[t.charCodeAt(l)]<<2|Ie[t.charCodeAt(l+1)]>>4,s[o++]=e&255),i===1&&(e=Ie[t.charCodeAt(l)]<<10|Ie[t.charCodeAt(l+1)]<<4|Ie[t.charCodeAt(l+2)]>>2,s[o++]=e>>8&255,s[o++]=e&255),s}function Xa(t){return Be[t>>18&63]+Be[t>>12&63]+Be[t>>6&63]+Be[t&63]}function Ya(t,e,r){for(var n,i=[],s=e;s<r;s+=3)n=(t[s]<<16&16711680)+(t[s+1]<<8&65280)+(t[s+2]&255),i.push(Xa(n));return i.join("")}function Za(t){for(var e,r=t.length,n=r%3,i=[],s=16383,o=0,u=r-n;o<u;o+=s)i.push(Ya(t,o,o+s>u?u:o+s));return n===1?(e=t[r-1],i.push(Be[e>>2]+Be[e<<4&63]+"==")):n===2&&(e=(t[r-2]<<8)+t[r-1],i.push(Be[e>>10]+Be[e>>4&63]+Be[e<<2&63]+"=")),i.join("")}var Dr={};Dr.read=function(t,e,r,n,i){var s,o,u=i*8-n-1,l=(1<<u)-1,c=l>>1,a=-7,h=r?i-1:0,p=r?-1:1,b=t[e+h];for(h+=p,s=b&(1<<-a)-1,b>>=-a,a+=u;a>0;s=s*256+t[e+h],h+=p,a-=8);for(o=s&(1<<-a)-1,s>>=-a,a+=n;a>0;o=o*256+t[e+h],h+=p,a-=8);if(s===0)s=1-c;else{if(s===l)return o?NaN:(b?-1:1)*(1/0);o=o+Math.pow(2,n),s=s-c}return(b?-1:1)*o*Math.pow(2,s-n)},Dr.write=function(t,e,r,n,i,s){var o,u,l,c=s*8-i-1,a=(1<<c)-1,h=a>>1,p=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,b=n?0:s-1,g=n?1:-1,m=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(u=isNaN(e)?1:0,o=a):(o=Math.floor(Math.log(e)/Math.LN2),e*(l=Math.pow(2,-o))<1&&(o--,l*=2),o+h>=1?e+=p/l:e+=p*Math.pow(2,1-h),e*l>=2&&(o++,l/=2),o+h>=a?(u=0,o=a):o+h>=1?(u=(e*l-1)*Math.pow(2,i),o=o+h):(u=e*Math.pow(2,h-1)*Math.pow(2,i),o=0));i>=8;t[r+b]=u&255,b+=g,u/=256,i-=8);for(o=o<<i|u,c+=i;c>0;t[r+b]=o&255,b+=g,o/=256,c-=8);t[r+b-g]|=m*128};(function(t){const e=nr,r=Dr,n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=a,t.SlowBuffer=S,t.INSPECT_MAX_BYTES=50;const i=2147483647;t.kMaxLength=i;const{Uint8Array:s,ArrayBuffer:o,SharedArrayBuffer:u}=globalThis;a.TYPED_ARRAY_SUPPORT=l(),!a.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function l(){try{const w=new s(1),f={foo:function(){return 42}};return Object.setPrototypeOf(f,s.prototype),Object.setPrototypeOf(w,f),w.foo()===42}catch{return!1}}Object.defineProperty(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}});function c(w){if(w>i)throw new RangeError('The value "'+w+'" is invalid for option "size"');const f=new s(w);return Object.setPrototypeOf(f,a.prototype),f}function a(w,f,d){if(typeof w=="number"){if(typeof f=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return g(w)}return h(w,f,d)}a.poolSize=8192;function h(w,f,d){if(typeof w=="string")return m(w,f);if(o.isView(w))return v(w);if(w==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof w);if($e(w,o)||w&&$e(w.buffer,o)||typeof u<"u"&&($e(w,u)||w&&$e(w.buffer,u)))return E(w,f,d);if(typeof w=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const x=w.valueOf&&w.valueOf();if(x!=null&&x!==w)return a.from(x,f,d);const A=T(w);if(A)return A;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof w[Symbol.toPrimitive]=="function")return a.from(w[Symbol.toPrimitive]("string"),f,d);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof w)}a.from=function(w,f,d){return h(w,f,d)},Object.setPrototypeOf(a.prototype,s.prototype),Object.setPrototypeOf(a,s);function p(w){if(typeof w!="number")throw new TypeError('"size" argument must be of type number');if(w<0)throw new RangeError('The value "'+w+'" is invalid for option "size"')}function b(w,f,d){return p(w),w<=0?c(w):f!==void 0?typeof d=="string"?c(w).fill(f,d):c(w).fill(f):c(w)}a.alloc=function(w,f,d){return b(w,f,d)};function g(w){return p(w),c(w<0?0:N(w)|0)}a.allocUnsafe=function(w){return g(w)},a.allocUnsafeSlow=function(w){return g(w)};function m(w,f){if((typeof f!="string"||f==="")&&(f="utf8"),!a.isEncoding(f))throw new TypeError("Unknown encoding: "+f);const d=F(w,f)|0;let x=c(d);const A=x.write(w,f);return A!==d&&(x=x.slice(0,A)),x}function y(w){const f=w.length<0?0:N(w.length)|0,d=c(f);for(let x=0;x<f;x+=1)d[x]=w[x]&255;return d}function v(w){if($e(w,s)){const f=new s(w);return E(f.buffer,f.byteOffset,f.byteLength)}return y(w)}function E(w,f,d){if(f<0||w.byteLength<f)throw new RangeError('"offset" is outside of buffer bounds');if(w.byteLength<f+(d||0))throw new RangeError('"length" is outside of buffer bounds');let x;return f===void 0&&d===void 0?x=new s(w):d===void 0?x=new s(w,f):x=new s(w,f,d),Object.setPrototypeOf(x,a.prototype),x}function T(w){if(a.isBuffer(w)){const f=N(w.length)|0,d=c(f);return d.length===0||w.copy(d,0,0,f),d}if(w.length!==void 0)return typeof w.length!="number"||Mn(w.length)?c(0):y(w);if(w.type==="Buffer"&&Array.isArray(w.data))return y(w.data)}function N(w){if(w>=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return w|0}function S(w){return+w!=w&&(w=0),a.alloc(+w)}a.isBuffer=function(f){return f!=null&&f._isBuffer===!0&&f!==a.prototype},a.compare=function(f,d){if($e(f,s)&&(f=a.from(f,f.offset,f.byteLength)),$e(d,s)&&(d=a.from(d,d.offset,d.byteLength)),!a.isBuffer(f)||!a.isBuffer(d))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(f===d)return 0;let x=f.length,A=d.length;for(let P=0,O=Math.min(x,A);P<O;++P)if(f[P]!==d[P]){x=f[P],A=d[P];break}return x<A?-1:A<x?1:0},a.isEncoding=function(f){switch(String(f).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},a.concat=function(f,d){if(!Array.isArray(f))throw new TypeError('"list" argument must be an Array of Buffers');if(f.length===0)return a.alloc(0);let x;if(d===void 0)for(d=0,x=0;x<f.length;++x)d+=f[x].length;const A=a.allocUnsafe(d);let P=0;for(x=0;x<f.length;++x){let O=f[x];if($e(O,s))P+O.length>A.length?(a.isBuffer(O)||(O=a.from(O)),O.copy(A,P)):s.prototype.set.call(A,O,P);else if(a.isBuffer(O))O.copy(A,P);else throw new TypeError('"list" argument must be an Array of Buffers');P+=O.length}return A};function F(w,f){if(a.isBuffer(w))return w.length;if(o.isView(w)||$e(w,o))return w.byteLength;if(typeof w!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof w);const d=w.length,x=arguments.length>2&&arguments[2]===!0;if(!x&&d===0)return 0;let A=!1;for(;;)switch(f){case"ascii":case"latin1":case"binary":return d;case"utf8":case"utf-8":return jn(w).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return d*2;case"hex":return d>>>1;case"base64":return Go(w).length;default:if(A)return x?-1:jn(w).length;f=(""+f).toLowerCase(),A=!0}}a.byteLength=F;function L(w,f,d){let x=!1;if((f===void 0||f<0)&&(f=0),f>this.length||((d===void 0||d>this.length)&&(d=this.length),d<=0)||(d>>>=0,f>>>=0,d<=f))return"";for(w||(w="utf8");;)switch(w){case"hex":return ce(this,f,d);case"utf8":case"utf-8":return ae(this,f,d);case"ascii":return Ye(this,f,d);case"latin1":case"binary":return re(this,f,d);case"base64":return J(this,f,d);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Ze(this,f,d);default:if(x)throw new TypeError("Unknown encoding: "+w);w=(w+"").toLowerCase(),x=!0}}a.prototype._isBuffer=!0;function U(w,f,d){const x=w[f];w[f]=w[d],w[d]=x}a.prototype.swap16=function(){const f=this.length;if(f%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let d=0;d<f;d+=2)U(this,d,d+1);return this},a.prototype.swap32=function(){const f=this.length;if(f%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let d=0;d<f;d+=4)U(this,d,d+3),U(this,d+1,d+2);return this},a.prototype.swap64=function(){const f=this.length;if(f%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let d=0;d<f;d+=8)U(this,d,d+7),U(this,d+1,d+6),U(this,d+2,d+5),U(this,d+3,d+4);return this},a.prototype.toString=function(){const f=this.length;return f===0?"":arguments.length===0?ae(this,0,f):L.apply(this,arguments)},a.prototype.toLocaleString=a.prototype.toString,a.prototype.equals=function(f){if(!a.isBuffer(f))throw new TypeError("Argument must be a Buffer");return this===f?!0:a.compare(this,f)===0},a.prototype.inspect=function(){let f="";const d=t.INSPECT_MAX_BYTES;return f=this.toString("hex",0,d).replace(/(.{2})/g,"$1 ").trim(),this.length>d&&(f+=" ... "),"<Buffer "+f+">"},n&&(a.prototype[n]=a.prototype.inspect),a.prototype.compare=function(f,d,x,A,P){if($e(f,s)&&(f=a.from(f,f.offset,f.byteLength)),!a.isBuffer(f))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof f);if(d===void 0&&(d=0),x===void 0&&(x=f?f.length:0),A===void 0&&(A=0),P===void 0&&(P=this.length),d<0||x>f.length||A<0||P>this.length)throw new RangeError("out of range index");if(A>=P&&d>=x)return 0;if(A>=P)return-1;if(d>=x)return 1;if(d>>>=0,x>>>=0,A>>>=0,P>>>=0,this===f)return 0;let O=P-A,k=x-d;const X=Math.min(O,k),z=this.slice(A,P),Y=f.slice(d,x);for(let D=0;D<X;++D)if(z[D]!==Y[D]){O=z[D],k=Y[D];break}return O<k?-1:k<O?1:0};function _(w,f,d,x,A){if(w.length===0)return-1;if(typeof d=="string"?(x=d,d=0):d>2147483647?d=2147483647:d<-2147483648&&(d=-2147483648),d=+d,Mn(d)&&(d=A?0:w.length-1),d<0&&(d=w.length+d),d>=w.length){if(A)return-1;d=w.length-1}else if(d<0)if(A)d=0;else return-1;if(typeof f=="string"&&(f=a.from(f,x)),a.isBuffer(f))return f.length===0?-1:j(w,f,d,x,A);if(typeof f=="number")return f=f&255,typeof s.prototype.indexOf=="function"?A?s.prototype.indexOf.call(w,f,d):s.prototype.lastIndexOf.call(w,f,d):j(w,[f],d,x,A);throw new TypeError("val must be string, number or Buffer")}function j(w,f,d,x,A){let P=1,O=w.length,k=f.length;if(x!==void 0&&(x=String(x).toLowerCase(),x==="ucs2"||x==="ucs-2"||x==="utf16le"||x==="utf-16le")){if(w.length<2||f.length<2)return-1;P=2,O/=2,k/=2,d/=2}function X(Y,D){return P===1?Y[D]:Y.readUInt16BE(D*P)}let z;if(A){let Y=-1;for(z=d;z<O;z++)if(X(w,z)===X(f,Y===-1?0:z-Y)){if(Y===-1&&(Y=z),z-Y+1===k)return Y*P}else Y!==-1&&(z-=z-Y),Y=-1}else for(d+k>O&&(d=O-k),z=d;z>=0;z--){let Y=!0;for(let D=0;D<k;D++)if(X(w,z+D)!==X(f,D)){Y=!1;break}if(Y)return z}return-1}a.prototype.includes=function(f,d,x){return this.indexOf(f,d,x)!==-1},a.prototype.indexOf=function(f,d,x){return _(this,f,d,x,!0)},a.prototype.lastIndexOf=function(f,d,x){return _(this,f,d,x,!1)};function pe(w,f,d,x){d=Number(d)||0;const A=w.length-d;x?(x=Number(x),x>A&&(x=A)):x=A;const P=f.length;x>P/2&&(x=P/2);let O;for(O=0;O<x;++O){const k=parseInt(f.substr(O*2,2),16);if(Mn(k))return O;w[d+O]=k}return O}function oe(w,f,d,x){return Lr(jn(f,w.length-d),w,d,x)}function R(w,f,d,x){return Lr(Mg(f),w,d,x)}function le(w,f,d,x){return Lr(Go(f),w,d,x)}function Pe(w,f,d,x){return Lr(Dg(f,w.length-d),w,d,x)}a.prototype.write=function(f,d,x,A){if(d===void 0)A="utf8",x=this.length,d=0;else if(x===void 0&&typeof d=="string")A=d,x=this.length,d=0;else if(isFinite(d))d=d>>>0,isFinite(x)?(x=x>>>0,A===void 0&&(A="utf8")):(A=x,x=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const P=this.length-d;if((x===void 0||x>P)&&(x=P),f.length>0&&(x<0||d<0)||d>this.length)throw new RangeError("Attempt to write outside buffer bounds");A||(A="utf8");let O=!1;for(;;)switch(A){case"hex":return pe(this,f,d,x);case"utf8":case"utf-8":return oe(this,f,d,x);case"ascii":case"latin1":case"binary":return R(this,f,d,x);case"base64":return le(this,f,d,x);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Pe(this,f,d,x);default:if(O)throw new TypeError("Unknown encoding: "+A);A=(""+A).toLowerCase(),O=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function J(w,f,d){return f===0&&d===w.length?e.fromByteArray(w):e.fromByteArray(w.slice(f,d))}function ae(w,f,d){d=Math.min(w.length,d);const x=[];let A=f;for(;A<d;){const P=w[A];let O=null,k=P>239?4:P>223?3:P>191?2:1;if(A+k<=d){let X,z,Y,D;switch(k){case 1:P<128&&(O=P);break;case 2:X=w[A+1],(X&192)===128&&(D=(P&31)<<6|X&63,D>127&&(O=D));break;case 3:X=w[A+1],z=w[A+2],(X&192)===128&&(z&192)===128&&(D=(P&15)<<12|(X&63)<<6|z&63,D>2047&&(D<55296||D>57343)&&(O=D));break;case 4:X=w[A+1],z=w[A+2],Y=w[A+3],(X&192)===128&&(z&192)===128&&(Y&192)===128&&(D=(P&15)<<18|(X&63)<<12|(z&63)<<6|Y&63,D>65535&&D<1114112&&(O=D))}}O===null?(O=65533,k=1):O>65535&&(O-=65536,x.push(O>>>10&1023|55296),O=56320|O&1023),x.push(O),A+=k}return ke(x)}const K=4096;function ke(w){const f=w.length;if(f<=K)return String.fromCharCode.apply(String,w);let d="",x=0;for(;x<f;)d+=String.fromCharCode.apply(String,w.slice(x,x+=K));return d}function Ye(w,f,d){let x="";d=Math.min(w.length,d);for(let A=f;A<d;++A)x+=String.fromCharCode(w[A]&127);return x}function re(w,f,d){let x="";d=Math.min(w.length,d);for(let A=f;A<d;++A)x+=String.fromCharCode(w[A]);return x}function ce(w,f,d){const x=w.length;(!f||f<0)&&(f=0),(!d||d<0||d>x)&&(d=x);let A="";for(let P=f;P<d;++P)A+=Vg[w[P]];return A}function Ze(w,f,d){const x=w.slice(f,d);let A="";for(let P=0;P<x.length-1;P+=2)A+=String.fromCharCode(x[P]+x[P+1]*256);return A}a.prototype.slice=function(f,d){const x=this.length;f=~~f,d=d===void 0?x:~~d,f<0?(f+=x,f<0&&(f=0)):f>x&&(f=x),d<0?(d+=x,d<0&&(d=0)):d>x&&(d=x),d<f&&(d=f);const A=this.subarray(f,d);return Object.setPrototypeOf(A,a.prototype),A};function V(w,f,d){if(w%1!==0||w<0)throw new RangeError("offset is not uint");if(w+f>d)throw new RangeError("Trying to access beyond buffer length")}a.prototype.readUintLE=a.prototype.readUIntLE=function(f,d,x){f=f>>>0,d=d>>>0,x||V(f,d,this.length);let A=this[f],P=1,O=0;for(;++O<d&&(P*=256);)A+=this[f+O]*P;return A},a.prototype.readUintBE=a.prototype.readUIntBE=function(f,d,x){f=f>>>0,d=d>>>0,x||V(f,d,this.length);let A=this[f+--d],P=1;for(;d>0&&(P*=256);)A+=this[f+--d]*P;return A},a.prototype.readUint8=a.prototype.readUInt8=function(f,d){return f=f>>>0,d||V(f,1,this.length),this[f]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(f,d){return f=f>>>0,d||V(f,2,this.length),this[f]|this[f+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(f,d){return f=f>>>0,d||V(f,2,this.length),this[f]<<8|this[f+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(f,d){return f=f>>>0,d||V(f,4,this.length),(this[f]|this[f+1]<<8|this[f+2]<<16)+this[f+3]*16777216},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(f,d){return f=f>>>0,d||V(f,4,this.length),this[f]*16777216+(this[f+1]<<16|this[f+2]<<8|this[f+3])},a.prototype.readBigUInt64LE=Qe(function(f){f=f>>>0,It(f,"offset");const d=this[f],x=this[f+7];(d===void 0||x===void 0)&&Yt(f,this.length-8);const A=d+this[++f]*2**8+this[++f]*2**16+this[++f]*2**24,P=this[++f]+this[++f]*2**8+this[++f]*2**16+x*2**24;return BigInt(A)+(BigInt(P)<<BigInt(32))}),a.prototype.readBigUInt64BE=Qe(function(f){f=f>>>0,It(f,"offset");const d=this[f],x=this[f+7];(d===void 0||x===void 0)&&Yt(f,this.length-8);const A=d*2**24+this[++f]*2**16+this[++f]*2**8+this[++f],P=this[++f]*2**24+this[++f]*2**16+this[++f]*2**8+x;return(BigInt(A)<<BigInt(32))+BigInt(P)}),a.prototype.readIntLE=function(f,d,x){f=f>>>0,d=d>>>0,x||V(f,d,this.length);let A=this[f],P=1,O=0;for(;++O<d&&(P*=256);)A+=this[f+O]*P;return P*=128,A>=P&&(A-=Math.pow(2,8*d)),A},a.prototype.readIntBE=function(f,d,x){f=f>>>0,d=d>>>0,x||V(f,d,this.length);let A=d,P=1,O=this[f+--A];for(;A>0&&(P*=256);)O+=this[f+--A]*P;return P*=128,O>=P&&(O-=Math.pow(2,8*d)),O},a.prototype.readInt8=function(f,d){return f=f>>>0,d||V(f,1,this.length),this[f]&128?(255-this[f]+1)*-1:this[f]},a.prototype.readInt16LE=function(f,d){f=f>>>0,d||V(f,2,this.length);const x=this[f]|this[f+1]<<8;return x&32768?x|4294901760:x},a.prototype.readInt16BE=function(f,d){f=f>>>0,d||V(f,2,this.length);const x=this[f+1]|this[f]<<8;return x&32768?x|4294901760:x},a.prototype.readInt32LE=function(f,d){return f=f>>>0,d||V(f,4,this.length),this[f]|this[f+1]<<8|this[f+2]<<16|this[f+3]<<24},a.prototype.readInt32BE=function(f,d){return f=f>>>0,d||V(f,4,this.length),this[f]<<24|this[f+1]<<16|this[f+2]<<8|this[f+3]},a.prototype.readBigInt64LE=Qe(function(f){f=f>>>0,It(f,"offset");const d=this[f],x=this[f+7];(d===void 0||x===void 0)&&Yt(f,this.length-8);const A=this[f+4]+this[f+5]*2**8+this[f+6]*2**16+(x<<24);return(BigInt(A)<<BigInt(32))+BigInt(d+this[++f]*2**8+this[++f]*2**16+this[++f]*2**24)}),a.prototype.readBigInt64BE=Qe(function(f){f=f>>>0,It(f,"offset");const d=this[f],x=this[f+7];(d===void 0||x===void 0)&&Yt(f,this.length-8);const A=(d<<24)+this[++f]*2**16+this[++f]*2**8+this[++f];return(BigInt(A)<<BigInt(32))+BigInt(this[++f]*2**24+this[++f]*2**16+this[++f]*2**8+x)}),a.prototype.readFloatLE=function(f,d){return f=f>>>0,d||V(f,4,this.length),r.read(this,f,!0,23,4)},a.prototype.readFloatBE=function(f,d){return f=f>>>0,d||V(f,4,this.length),r.read(this,f,!1,23,4)},a.prototype.readDoubleLE=function(f,d){return f=f>>>0,d||V(f,8,this.length),r.read(this,f,!0,52,8)},a.prototype.readDoubleBE=function(f,d){return f=f>>>0,d||V(f,8,this.length),r.read(this,f,!1,52,8)};function q(w,f,d,x,A,P){if(!a.isBuffer(w))throw new TypeError('"buffer" argument must be a Buffer instance');if(f>A||f<P)throw new RangeError('"value" argument is out of bounds');if(d+x>w.length)throw new RangeError("Index out of range")}a.prototype.writeUintLE=a.prototype.writeUIntLE=function(f,d,x,A){if(f=+f,d=d>>>0,x=x>>>0,!A){const k=Math.pow(2,8*x)-1;q(this,f,d,x,k,0)}let P=1,O=0;for(this[d]=f&255;++O<x&&(P*=256);)this[d+O]=f/P&255;return d+x},a.prototype.writeUintBE=a.prototype.writeUIntBE=function(f,d,x,A){if(f=+f,d=d>>>0,x=x>>>0,!A){const k=Math.pow(2,8*x)-1;q(this,f,d,x,k,0)}let P=x-1,O=1;for(this[d+P]=f&255;--P>=0&&(O*=256);)this[d+P]=f/O&255;return d+x},a.prototype.writeUint8=a.prototype.writeUInt8=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,1,255,0),this[d]=f&255,d+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,2,65535,0),this[d]=f&255,this[d+1]=f>>>8,d+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,2,65535,0),this[d]=f>>>8,this[d+1]=f&255,d+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,4,4294967295,0),this[d+3]=f>>>24,this[d+2]=f>>>16,this[d+1]=f>>>8,this[d]=f&255,d+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,4,4294967295,0),this[d]=f>>>24,this[d+1]=f>>>16,this[d+2]=f>>>8,this[d+3]=f&255,d+4};function Fr(w,f,d,x,A){Wo(f,x,A,w,d,7);let P=Number(f&BigInt(4294967295));w[d++]=P,P=P>>8,w[d++]=P,P=P>>8,w[d++]=P,P=P>>8,w[d++]=P;let O=Number(f>>BigInt(32)&BigInt(4294967295));return w[d++]=O,O=O>>8,w[d++]=O,O=O>>8,w[d++]=O,O=O>>8,w[d++]=O,d}function Do(w,f,d,x,A){Wo(f,x,A,w,d,7);let P=Number(f&BigInt(4294967295));w[d+7]=P,P=P>>8,w[d+6]=P,P=P>>8,w[d+5]=P,P=P>>8,w[d+4]=P;let O=Number(f>>BigInt(32)&BigInt(4294967295));return w[d+3]=O,O=O>>8,w[d+2]=O,O=O>>8,w[d+1]=O,O=O>>8,w[d]=O,d+8}a.prototype.writeBigUInt64LE=Qe(function(f,d=0){return Fr(this,f,d,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeBigUInt64BE=Qe(function(f,d=0){return Do(this,f,d,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeIntLE=function(f,d,x,A){if(f=+f,d=d>>>0,!A){const X=Math.pow(2,8*x-1);q(this,f,d,x,X-1,-X)}let P=0,O=1,k=0;for(this[d]=f&255;++P<x&&(O*=256);)f<0&&k===0&&this[d+P-1]!==0&&(k=1),this[d+P]=(f/O>>0)-k&255;return d+x},a.prototype.writeIntBE=function(f,d,x,A){if(f=+f,d=d>>>0,!A){const X=Math.pow(2,8*x-1);q(this,f,d,x,X-1,-X)}let P=x-1,O=1,k=0;for(this[d+P]=f&255;--P>=0&&(O*=256);)f<0&&k===0&&this[d+P+1]!==0&&(k=1),this[d+P]=(f/O>>0)-k&255;return d+x},a.prototype.writeInt8=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,1,127,-128),f<0&&(f=255+f+1),this[d]=f&255,d+1},a.prototype.writeInt16LE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,2,32767,-32768),this[d]=f&255,this[d+1]=f>>>8,d+2},a.prototype.writeInt16BE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,2,32767,-32768),this[d]=f>>>8,this[d+1]=f&255,d+2},a.prototype.writeInt32LE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,4,2147483647,-2147483648),this[d]=f&255,this[d+1]=f>>>8,this[d+2]=f>>>16,this[d+3]=f>>>24,d+4},a.prototype.writeInt32BE=function(f,d,x){return f=+f,d=d>>>0,x||q(this,f,d,4,2147483647,-2147483648),f<0&&(f=4294967295+f+1),this[d]=f>>>24,this[d+1]=f>>>16,this[d+2]=f>>>8,this[d+3]=f&255,d+4},a.prototype.writeBigInt64LE=Qe(function(f,d=0){return Fr(this,f,d,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),a.prototype.writeBigInt64BE=Qe(function(f,d=0){return Do(this,f,d,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Vo(w,f,d,x,A,P){if(d+x>w.length)throw new RangeError("Index out of range");if(d<0)throw new RangeError("Index out of range")}function Ho(w,f,d,x,A){return f=+f,d=d>>>0,A||Vo(w,f,d,4),r.write(w,f,d,x,23,4),d+4}a.prototype.writeFloatLE=function(f,d,x){return Ho(this,f,d,!0,x)},a.prototype.writeFloatBE=function(f,d,x){return Ho(this,f,d,!1,x)};function qo(w,f,d,x,A){return f=+f,d=d>>>0,A||Vo(w,f,d,8),r.write(w,f,d,x,52,8),d+8}a.prototype.writeDoubleLE=function(f,d,x){return qo(this,f,d,!0,x)},a.prototype.writeDoubleBE=function(f,d,x){return qo(this,f,d,!1,x)},a.prototype.copy=function(f,d,x,A){if(!a.isBuffer(f))throw new TypeError("argument should be a Buffer");if(x||(x=0),!A&&A!==0&&(A=this.length),d>=f.length&&(d=f.length),d||(d=0),A>0&&A<x&&(A=x),A===x||f.length===0||this.length===0)return 0;if(d<0)throw new RangeError("targetStart out of bounds");if(x<0||x>=this.length)throw new RangeError("Index out of range");if(A<0)throw new RangeError("sourceEnd out of bounds");A>this.length&&(A=this.length),f.length-d<A-x&&(A=f.length-d+x);const P=A-x;return this===f&&typeof s.prototype.copyWithin=="function"?this.copyWithin(d,x,A):s.prototype.set.call(f,this.subarray(x,A),d),P},a.prototype.fill=function(f,d,x,A){if(typeof f=="string"){if(typeof d=="string"?(A=d,d=0,x=this.length):typeof x=="string"&&(A=x,x=this.length),A!==void 0&&typeof A!="string")throw new TypeError("encoding must be a string");if(typeof A=="string"&&!a.isEncoding(A))throw new TypeError("Unknown encoding: "+A);if(f.length===1){const O=f.charCodeAt(0);(A==="utf8"&&O<128||A==="latin1")&&(f=O)}}else typeof f=="number"?f=f&255:typeof f=="boolean"&&(f=Number(f));if(d<0||this.length<d||this.length<x)throw new RangeError("Out of range index");if(x<=d)return this;d=d>>>0,x=x===void 0?this.length:x>>>0,f||(f=0);let P;if(typeof f=="number")for(P=d;P<x;++P)this[P]=f;else{const O=a.isBuffer(f)?f:a.from(f,A),k=O.length;if(k===0)throw new TypeError('The value "'+f+'" is invalid for argument "value"');for(P=0;P<x-d;++P)this[P+d]=O[P%k]}return this};const Pt={};function $n(w,f,d){Pt[w]=class extends d{constructor(){super(),Object.defineProperty(this,"message",{value:f.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${w}]`,this.stack,delete this.name}get code(){return w}set code(A){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:A,writable:!0})}toString(){return`${this.name} [${w}]: ${this.message}`}}}$n("ERR_BUFFER_OUT_OF_BOUNDS",function(w){return w?`${w} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),$n("ERR_INVALID_ARG_TYPE",function(w,f){return`The "${w}" argument must be of type number. Received type ${typeof f}`},TypeError),$n("ERR_OUT_OF_RANGE",function(w,f,d){let x=`The value of "${w}" is out of range.`,A=d;return Number.isInteger(d)&&Math.abs(d)>2**32?A=zo(String(d)):typeof d=="bigint"&&(A=String(d),(d>BigInt(2)**BigInt(32)||d<-(BigInt(2)**BigInt(32)))&&(A=zo(A)),A+="n"),x+=` It must be ${f}. Received ${A}`,x},RangeError);function zo(w){let f="",d=w.length;const x=w[0]==="-"?1:0;for(;d>=x+4;d-=3)f=`_${w.slice(d-3,d)}${f}`;return`${w.slice(0,d)}${f}`}function kg(w,f,d){It(f,"offset"),(w[f]===void 0||w[f+d]===void 0)&&Yt(f,w.length-(d+1))}function Wo(w,f,d,x,A,P){if(w>d||w<f){const O=typeof f=="bigint"?"n":"";let k;throw f===0||f===BigInt(0)?k=`>= 0${O} and < 2${O} ** ${(P+1)*8}${O}`:k=`>= -(2${O} ** ${(P+1)*8-1}${O}) and < 2 ** ${(P+1)*8-1}${O}`,new Pt.ERR_OUT_OF_RANGE("value",k,w)}kg(x,A,P)}function It(w,f){if(typeof w!="number")throw new Pt.ERR_INVALID_ARG_TYPE(f,"number",w)}function Yt(w,f,d){throw Math.floor(w)!==w?(It(w,d),new Pt.ERR_OUT_OF_RANGE("offset","an integer",w)):f<0?new Pt.ERR_BUFFER_OUT_OF_BOUNDS:new Pt.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${f}`,w)}const $g=/[^+/0-9A-Za-z-_]/g;function jg(w){if(w=w.split("=")[0],w=w.trim().replace($g,""),w.length<2)return"";for(;w.length%4!==0;)w=w+"=";return w}function jn(w,f){f=f||1/0;let d;const x=w.length;let A=null;const P=[];for(let O=0;O<x;++O){if(d=w.charCodeAt(O),d>55295&&d<57344){if(!A){if(d>56319){(f-=3)>-1&&P.push(239,191,189);continue}else if(O+1===x){(f-=3)>-1&&P.push(239,191,189);continue}A=d;continue}if(d<56320){(f-=3)>-1&&P.push(239,191,189),A=d;continue}d=(A-55296<<10|d-56320)+65536}else A&&(f-=3)>-1&&P.push(239,191,189);if(A=null,d<128){if((f-=1)<0)break;P.push(d)}else if(d<2048){if((f-=2)<0)break;P.push(d>>6|192,d&63|128)}else if(d<65536){if((f-=3)<0)break;P.push(d>>12|224,d>>6&63|128,d&63|128)}else if(d<1114112){if((f-=4)<0)break;P.push(d>>18|240,d>>12&63|128,d>>6&63|128,d&63|128)}else throw new Error("Invalid code point")}return P}function Mg(w){const f=[];for(let d=0;d<w.length;++d)f.push(w.charCodeAt(d)&255);return f}function Dg(w,f){let d,x,A;const P=[];for(let O=0;O<w.length&&!((f-=2)<0);++O)d=w.charCodeAt(O),x=d>>8,A=d%256,P.push(A),P.push(x);return P}function Go(w){return e.toByteArray(jg(w))}function Lr(w,f,d,x){let A;for(A=0;A<x&&!(A+d>=f.length||A>=w.length);++A)f[A+d]=w[A];return A}function $e(w,f){return w instanceof f||w!=null&&w.constructor!=null&&w.constructor.name!=null&&w.constructor.name===f.name}function Mn(w){return w!==w}const Vg=(function(){const w="0123456789abcdef",f=new Array(256);for(let d=0;d<16;++d){const x=d*16;for(let A=0;A<16;++A)f[x+A]=w[d]+w[A]}return f})();function Qe(w){return typeof BigInt>"u"?Hg:w}function Hg(){throw new Error("BigInt not supported")}})(ni);const si=ni.Buffer;let B=class Ko extends Error{static from(e,r,n,i,s,o){const u=new Ko(e.message,r||e.code,n,i,s);return u.cause=e,u.name=e.name,o&&Object.assign(u,o),u}constructor(e,r,n,i,s){super(e),this.name="AxiosError",this.isAxiosError=!0,r&&(this.code=r),n&&(this.config=n),i&&(this.request=i),s&&(this.response=s,this.status=s.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:I.toJSONObject(this.config),code:this.code,status:this.status}}};B.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",B.ERR_BAD_OPTION="ERR_BAD_OPTION",B.ECONNABORTED="ECONNABORTED",B.ETIMEDOUT="ETIMEDOUT",B.ERR_NETWORK="ERR_NETWORK",B.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",B.ERR_DEPRECATED="ERR_DEPRECATED",B.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",B.ERR_BAD_REQUEST="ERR_BAD_REQUEST",B.ERR_CANCELED="ERR_CANCELED",B.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",B.ERR_INVALID_URL="ERR_INVALID_URL";var Qa=null;function Vr(t){return I.isPlainObject(t)||I.isArray(t)}function oi(t){return I.endsWith(t,"[]")?t.slice(0,-2):t}function ai(t,e,r){return t?t.concat(e).map(function(i,s){return i=oi(i),!r&&s?"["+i+"]":i}).join(r?".":""):e}function eu(t){return I.isArray(t)&&!t.some(Vr)}const tu=I.toFlatObject(I,{},null,function(e){return/^is[A-Z]/.test(e)});function ir(t,e,r){if(!I.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,r=I.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,y){return!I.isUndefined(y[m])});const n=r.metaTokens,i=r.visitor||a,s=r.dots,o=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&I.isSpecCompliantForm(e);if(!I.isFunction(i))throw new TypeError("visitor must be a function");function c(g){if(g===null)return"";if(I.isDate(g))return g.toISOString();if(I.isBoolean(g))return g.toString();if(!l&&I.isBlob(g))throw new B("Blob is not supported. Use a Buffer instead.");return I.isArrayBuffer(g)||I.isTypedArray(g)?l&&typeof Blob=="function"?new Blob([g]):si.from(g):g}function a(g,m,y){let v=g;if(g&&!y&&typeof g=="object"){if(I.endsWith(m,"{}"))m=n?m:m.slice(0,-2),g=JSON.stringify(g);else if(I.isArray(g)&&eu(g)||(I.isFileList(g)||I.endsWith(m,"[]"))&&(v=I.toArray(g)))return m=oi(m),v.forEach(function(T,N){!(I.isUndefined(T)||T===null)&&e.append(o===!0?ai([m],N,s):o===null?m:m+"[]",c(T))}),!1}return Vr(g)?!0:(e.append(ai(y,m,s),c(g)),!1)}const h=[],p=Object.assign(tu,{defaultVisitor:a,convertValue:c,isVisitable:Vr});function b(g,m){if(!I.isUndefined(g)){if(h.indexOf(g)!==-1)throw Error("Circular reference detected in "+m.join("."));h.push(g),I.forEach(g,function(v,E){(!(I.isUndefined(v)||v===null)&&i.call(e,v,I.isString(E)?E.trim():E,m,p))===!0&&b(v,m?m.concat(E):[E])}),h.pop()}}if(!I.isObject(t))throw new TypeError("data must be an object");return b(t),e}function ui(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(n){return e[n]})}function Hr(t,e){this._pairs=[],t&&ir(t,this,e)}const li=Hr.prototype;li.append=function(e,r){this._pairs.push([e,r])},li.toString=function(e){const r=e?function(n){return e.call(this,n,ui)}:ui;return this._pairs.map(function(i){return r(i[0])+"="+r(i[1])},"").join("&")};function ru(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function ci(t,e,r){if(!e)return t;const n=r&&r.encode||ru,i=I.isFunction(r)?{serialize:r}:r,s=i&&i.serialize;let o;if(s?o=s(e,i):o=I.isURLSearchParams(e)?e.toString():new Hr(e,i).toString(n),o){const u=t.indexOf("#");u!==-1&&(t=t.slice(0,u)),t+=(t.indexOf("?")===-1?"?":"&")+o}return t}class fi{constructor(){this.handlers=[]}use(e,r,n){return this.handlers.push({fulfilled:e,rejected:r,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&&(this.handlers=[])}forEach(e){I.forEach(this.handlers,function(n){n!==null&&e(n)})}}var qr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},nu=typeof URLSearchParams<"u"?URLSearchParams:Hr,iu=typeof FormData<"u"?FormData:null,su=typeof Blob<"u"?Blob:null,ou={isBrowser:!0,classes:{URLSearchParams:nu,FormData:iu,Blob:su},protocols:["http","https","file","blob","url","data"]};const zr=typeof window<"u"&&typeof document<"u",Wr=typeof navigator=="object"&&navigator||void 0,au=zr&&(!Wr||["ReactNative","NativeScript","NS"].indexOf(Wr.product)<0),uu=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",lu=zr&&window.location.href||"http://localhost";var cu=Object.freeze({__proto__:null,hasBrowserEnv:zr,hasStandardBrowserEnv:au,hasStandardBrowserWebWorkerEnv:uu,navigator:Wr,origin:lu}),fe={...cu,...ou};function fu(t,e){return ir(t,new fe.classes.URLSearchParams,{visitor:function(r,n,i,s){return fe.isNode&&I.isBuffer(r)?(this.append(n,r.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)},...e})}function hu(t){return I.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function du(t){const e={},r=Object.keys(t);let n;const i=r.length;let s;for(n=0;n<i;n++)s=r[n],e[s]=t[s];return e}function hi(t){function e(r,n,i,s){let o=r[s++];if(o==="__proto__")return!0;const u=Number.isFinite(+o),l=s>=r.length;return o=!o&&I.isArray(i)?i.length:o,l?(I.hasOwnProp(i,o)?i[o]=[i[o],n]:i[o]=n,!u):((!i[o]||!I.isObject(i[o]))&&(i[o]=[]),e(r,n,i[o],s)&&I.isArray(i[o])&&(i[o]=du(i[o])),!u)}if(I.isFormData(t)&&I.isFunction(t.entries)){const r={};return I.forEachEntry(t,(n,i)=>{e(hu(n),i,r,0)}),r}return null}function pu(t,e,r){if(I.isString(t))try{return(e||JSON.parse)(t),I.trim(t)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(t)}const Rt={transitional:qr,adapter:["xhr","http","fetch"],transformRequest:[function(e,r){const n=r.getContentType()||"",i=n.indexOf("application/json")>-1,s=I.isObject(e);if(s&&I.isHTMLForm(e)&&(e=new FormData(e)),I.isFormData(e))return i?JSON.stringify(hi(e)):e;if(I.isArrayBuffer(e)||I.isBuffer(e)||I.isStream(e)||I.isFile(e)||I.isBlob(e)||I.isReadableStream(e))return e;if(I.isArrayBufferView(e))return e.buffer;if(I.isURLSearchParams(e))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let u;if(s){if(n.indexOf("application/x-www-form-urlencoded")>-1)return fu(e,this.formSerializer).toString();if((u=I.isFileList(e))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return ir(u?{"files[]":e}:e,l&&new l,this.formSerializer)}}return s||i?(r.setContentType("application/json",!1),pu(e)):e}],transformResponse:[function(e){const r=this.transitional||Rt.transitional,n=r&&r.forcedJSONParsing,i=this.responseType==="json";if(I.isResponse(e)||I.isReadableStream(e))return e;if(e&&I.isString(e)&&(n&&!this.responseType||i)){const o=!(r&&r.silentJSONParsing)&&i;try{return JSON.parse(e,this.parseReviver)}catch(u){if(o)throw u.name==="SyntaxError"?B.from(u,B.ERR_BAD_RESPONSE,this,null,this.response):u}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:fe.classes.FormData,Blob:fe.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};I.forEach(["delete","get","head","post","put","patch"],t=>{Rt.headers[t]={}});const gu=I.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 mu=t=>{const e={};let r,n,i;return t&&t.split(`
2
- `).forEach(function(o){i=o.indexOf(":"),r=o.substring(0,i).trim().toLowerCase(),n=o.substring(i+1).trim(),!(!r||e[r]&&gu[r])&&(r==="set-cookie"?e[r]?e[r].push(n):e[r]=[n]:e[r]=e[r]?e[r]+", "+n:n)}),e};const di=Symbol("internals");function Ft(t){return t&&String(t).trim().toLowerCase()}function sr(t){return t===!1||t==null?t:I.isArray(t)?t.map(sr):String(t)}function yu(t){const e=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(t);)e[n[1]]=n[2];return e}const bu=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function Gr(t,e,r,n,i){if(I.isFunction(n))return n.call(this,e,r);if(i&&(e=r),!!I.isString(e)){if(I.isString(n))return e.indexOf(n)!==-1;if(I.isRegExp(n))return n.test(e)}}function wu(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,r,n)=>r.toUpperCase()+n)}function xu(t,e){const r=I.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+r,{value:function(i,s,o){return this[n].call(this,e,i,s,o)},configurable:!0})})}let Ee=class{constructor(e){e&&this.set(e)}set(e,r,n){const i=this;function s(u,l,c){const a=Ft(l);if(!a)throw new Error("header name must be a non-empty string");const h=I.findKey(i,a);(!h||i[h]===void 0||c===!0||c===void 0&&i[h]!==!1)&&(i[h||l]=sr(u))}const o=(u,l)=>I.forEach(u,(c,a)=>s(c,a,l));if(I.isPlainObject(e)||e instanceof this.constructor)o(e,r);else if(I.isString(e)&&(e=e.trim())&&!bu(e))o(mu(e),r);else if(I.isObject(e)&&I.isIterable(e)){let u={},l,c;for(const a of e){if(!I.isArray(a))throw TypeError("Object iterator must return a key-value pair");u[c=a[0]]=(l=u[c])?I.isArray(l)?[...l,a[1]]:[l,a[1]]:a[1]}o(u,r)}else e!=null&&s(r,e,n);return this}get(e,r){if(e=Ft(e),e){const n=I.findKey(this,e);if(n){const i=this[n];if(!r)return i;if(r===!0)return yu(i);if(I.isFunction(r))return r.call(this,i,n);if(I.isRegExp(r))return r.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,r){if(e=Ft(e),e){const n=I.findKey(this,e);return!!(n&&this[n]!==void 0&&(!r||Gr(this,this[n],n,r)))}return!1}delete(e,r){const n=this;let i=!1;function s(o){if(o=Ft(o),o){const u=I.findKey(n,o);u&&(!r||Gr(n,n[u],u,r))&&(delete n[u],i=!0)}}return I.isArray(e)?e.forEach(s):s(e),i}clear(e){const r=Object.keys(this);let n=r.length,i=!1;for(;n--;){const s=r[n];(!e||Gr(this,this[s],s,e,!0))&&(delete this[s],i=!0)}return i}normalize(e){const r=this,n={};return I.forEach(this,(i,s)=>{const o=I.findKey(n,s);if(o){r[o]=sr(i),delete r[s];return}const u=e?wu(s):String(s).trim();u!==s&&delete r[s],r[u]=sr(i),n[u]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const r=Object.create(null);return I.forEach(this,(n,i)=>{n!=null&&n!==!1&&(r[i]=e&&I.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,r])=>e+": "+r).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,...r){const n=new this(e);return r.forEach(i=>n.set(i)),n}static accessor(e){const n=(this[di]=this[di]={accessors:{}}).accessors,i=this.prototype;function s(o){const u=Ft(o);n[u]||(xu(i,o),n[u]=!0)}return I.isArray(e)?e.forEach(s):s(e),this}};Ee.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),I.reduceDescriptors(Ee.prototype,({value:t},e)=>{let r=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(n){this[r]=n}}}),I.freezeMethods(Ee);function Kr(t,e){const r=this||Rt,n=e||r,i=Ee.from(n.headers);let s=n.data;return I.forEach(t,function(u){s=u.call(r,s,i.normalize(),e?e.status:void 0)}),i.normalize(),s}function pi(t){return!!(t&&t.__CANCEL__)}let Lt=class extends B{constructor(e,r,n){super(e??"canceled",B.ERR_CANCELED,r,n),this.name="CanceledError",this.__CANCEL__=!0}};function gi(t,e,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?t(r):e(new B("Request failed with status code "+r.status,[B.ERR_BAD_REQUEST,B.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function Eu(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function vu(t,e){t=t||10;const r=new Array(t),n=new Array(t);let i=0,s=0,o;return e=e!==void 0?e:1e3,function(l){const c=Date.now(),a=n[s];o||(o=c),r[i]=l,n[i]=c;let h=s,p=0;for(;h!==i;)p+=r[h++],h=h%t;if(i=(i+1)%t,i===s&&(s=(s+1)%t),c-o<e)return;const b=a&&c-a;return b?Math.round(p*1e3/b):void 0}}function Tu(t,e){let r=0,n=1e3/e,i,s;const o=(c,a=Date.now())=>{r=a,i=null,s&&(clearTimeout(s),s=null),t(...c)};return[(...c)=>{const a=Date.now(),h=a-r;h>=n?o(c,a):(i=c,s||(s=setTimeout(()=>{s=null,o(i)},n-h)))},()=>i&&o(i)]}const or=(t,e,r=3)=>{let n=0;const i=vu(50,250);return Tu(s=>{const o=s.loaded,u=s.lengthComputable?s.total:void 0,l=o-n,c=i(l),a=o<=u;n=o;const h={loaded:o,total:u,progress:u?o/u:void 0,bytes:l,rate:c||void 0,estimated:c&&u&&a?(u-o)/c:void 0,event:s,lengthComputable:u!=null,[e?"download":"upload"]:!0};t(h)},r)},mi=(t,e)=>{const r=t!=null;return[n=>e[0]({lengthComputable:r,total:t,loaded:n}),e[1]]},yi=t=>(...e)=>I.asap(()=>t(...e));var Au=fe.hasStandardBrowserEnv?((t,e)=>r=>(r=new URL(r,fe.origin),t.protocol===r.protocol&&t.host===r.host&&(e||t.port===r.port)))(new URL(fe.origin),fe.navigator&&/(msie|trident)/i.test(fe.navigator.userAgent)):()=>!0,Nu=fe.hasStandardBrowserEnv?{write(t,e,r,n,i,s,o){if(typeof document>"u")return;const u=[`${t}=${encodeURIComponent(e)}`];I.isNumber(r)&&u.push(`expires=${new Date(r).toUTCString()}`),I.isString(n)&&u.push(`path=${n}`),I.isString(i)&&u.push(`domain=${i}`),s===!0&&u.push("secure"),I.isString(o)&&u.push(`SameSite=${o}`),document.cookie=u.join("; ")},read(t){if(typeof document>"u")return null;const e=document.cookie.match(new RegExp("(?:^|; )"+t+"=([^;]*)"));return e?decodeURIComponent(e[1]):null},remove(t){this.write(t,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function Pu(t){return typeof t!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function Iu(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function bi(t,e,r){let n=!Pu(e);return t&&(n||r==!1)?Iu(t,e):e}const wi=t=>t instanceof Ee?{...t}:t;function rt(t,e){e=e||{};const r={};function n(c,a,h,p){return I.isPlainObject(c)&&I.isPlainObject(a)?I.merge.call({caseless:p},c,a):I.isPlainObject(a)?I.merge({},a):I.isArray(a)?a.slice():a}function i(c,a,h,p){if(I.isUndefined(a)){if(!I.isUndefined(c))return n(void 0,c,h,p)}else return n(c,a,h,p)}function s(c,a){if(!I.isUndefined(a))return n(void 0,a)}function o(c,a){if(I.isUndefined(a)){if(!I.isUndefined(c))return n(void 0,c)}else return n(void 0,a)}function u(c,a,h){if(h in e)return n(c,a);if(h in t)return n(void 0,c)}const l={url:s,method:s,data:s,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:u,headers:(c,a,h)=>i(wi(c),wi(a),h,!0)};return I.forEach(Object.keys({...t,...e}),function(a){if(a==="__proto__"||a==="constructor"||a==="prototype")return;const h=I.hasOwnProp(l,a)?l[a]:i,p=h(t[a],e[a],a);I.isUndefined(p)&&h!==u||(r[a]=p)}),r}var xi=t=>{const e=rt({},t);let{data:r,withXSRFToken:n,xsrfHeaderName:i,xsrfCookieName:s,headers:o,auth:u}=e;if(e.headers=o=Ee.from(o),e.url=ci(bi(e.baseURL,e.url,e.allowAbsoluteUrls),t.params,t.paramsSerializer),u&&o.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?unescape(encodeURIComponent(u.password)):""))),I.isFormData(r)){if(fe.hasStandardBrowserEnv||fe.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(I.isFunction(r.getHeaders)){const l=r.getHeaders(),c=["content-type","content-length"];Object.entries(l).forEach(([a,h])=>{c.includes(a.toLowerCase())&&o.set(a,h)})}}if(fe.hasStandardBrowserEnv&&(n&&I.isFunction(n)&&(n=n(e)),n||n!==!1&&Au(e.url))){const l=i&&s&&Nu.read(s);l&&o.set(i,l)}return e},Su=typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(r,n){const i=xi(t);let s=i.data;const o=Ee.from(i.headers).normalize();let{responseType:u,onUploadProgress:l,onDownloadProgress:c}=i,a,h,p,b,g;function m(){b&&b(),g&&g(),i.cancelToken&&i.cancelToken.unsubscribe(a),i.signal&&i.signal.removeEventListener("abort",a)}let y=new XMLHttpRequest;y.open(i.method.toUpperCase(),i.url,!0),y.timeout=i.timeout;function v(){if(!y)return;const T=Ee.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),S={data:!u||u==="text"||u==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:T,config:t,request:y};gi(function(L){r(L),m()},function(L){n(L),m()},S),y=null}"onloadend"in y?y.onloadend=v:y.onreadystatechange=function(){!y||y.readyState!==4||y.status===0&&!(y.responseURL&&y.responseURL.indexOf("file:")===0)||setTimeout(v)},y.onabort=function(){y&&(n(new B("Request aborted",B.ECONNABORTED,t,y)),y=null)},y.onerror=function(N){const S=N&&N.message?N.message:"Network Error",F=new B(S,B.ERR_NETWORK,t,y);F.event=N||null,n(F),y=null},y.ontimeout=function(){let N=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const S=i.transitional||qr;i.timeoutErrorMessage&&(N=i.timeoutErrorMessage),n(new B(N,S.clarifyTimeoutError?B.ETIMEDOUT:B.ECONNABORTED,t,y)),y=null},s===void 0&&o.setContentType(null),"setRequestHeader"in y&&I.forEach(o.toJSON(),function(N,S){y.setRequestHeader(S,N)}),I.isUndefined(i.withCredentials)||(y.withCredentials=!!i.withCredentials),u&&u!=="json"&&(y.responseType=i.responseType),c&&([p,g]=or(c,!0),y.addEventListener("progress",p)),l&&y.upload&&([h,b]=or(l),y.upload.addEventListener("progress",h),y.upload.addEventListener("loadend",b)),(i.cancelToken||i.signal)&&(a=T=>{y&&(n(!T||T.type?new Lt(null,t,y):T),y.abort(),y=null)},i.cancelToken&&i.cancelToken.subscribe(a),i.signal&&(i.signal.aborted?a():i.signal.addEventListener("abort",a)));const E=Eu(i.url);if(E&&fe.protocols.indexOf(E)===-1){n(new B("Unsupported protocol "+E+":",B.ERR_BAD_REQUEST,t));return}y.send(s||null)})};const Ou=(t,e)=>{const{length:r}=t=t?t.filter(Boolean):[];if(e||r){let n=new AbortController,i;const s=function(c){if(!i){i=!0,u();const a=c instanceof Error?c:this.reason;n.abort(a instanceof B?a:new Lt(a instanceof Error?a.message:a))}};let o=e&&setTimeout(()=>{o=null,s(new B(`timeout of ${e}ms exceeded`,B.ETIMEDOUT))},e);const u=()=>{t&&(o&&clearTimeout(o),o=null,t.forEach(c=>{c.unsubscribe?c.unsubscribe(s):c.removeEventListener("abort",s)}),t=null)};t.forEach(c=>c.addEventListener("abort",s));const{signal:l}=n;return l.unsubscribe=()=>I.asap(u),l}},Cu=function*(t,e){let r=t.byteLength;if(r<e){yield t;return}let n=0,i;for(;n<r;)i=n+e,yield t.slice(n,i),n=i},Ru=async function*(t,e){for await(const r of Fu(t))yield*Cu(r,e)},Fu=async function*(t){if(t[Symbol.asyncIterator]){yield*t;return}const e=t.getReader();try{for(;;){const{done:r,value:n}=await e.read();if(r)break;yield n}}finally{await e.cancel()}},Ei=(t,e,r,n)=>{const i=Ru(t,e);let s=0,o,u=l=>{o||(o=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:a}=await i.next();if(c){u(),l.close();return}let h=a.byteLength;if(r){let p=s+=h;r(p)}l.enqueue(new Uint8Array(a))}catch(c){throw u(c),c}},cancel(l){return u(l),i.return()}},{highWaterMark:2})},vi=64*1024,{isFunction:ar}=I,Lu=(({Request:t,Response:e})=>({Request:t,Response:e}))(I.global),{ReadableStream:Ti,TextEncoder:Ai}=I.global,Ni=(t,...e)=>{try{return!!t(...e)}catch{return!1}},_u=t=>{t=I.merge.call({skipUndefined:!0},Lu,t);const{fetch:e,Request:r,Response:n}=t,i=e?ar(e):typeof fetch=="function",s=ar(r),o=ar(n);if(!i)return!1;const u=i&&ar(Ti),l=i&&(typeof Ai=="function"?(g=>m=>g.encode(m))(new Ai):async g=>new Uint8Array(await new r(g).arrayBuffer())),c=s&&u&&Ni(()=>{let g=!1;const m=new r(fe.origin,{body:new Ti,method:"POST",get duplex(){return g=!0,"half"}}).headers.has("Content-Type");return g&&!m}),a=o&&u&&Ni(()=>I.isReadableStream(new n("").body)),h={stream:a&&(g=>g.body)};i&&["text","arrayBuffer","blob","formData","stream"].forEach(g=>{!h[g]&&(h[g]=(m,y)=>{let v=m&&m[g];if(v)return v.call(m);throw new B(`Response type '${g}' is not supported`,B.ERR_NOT_SUPPORT,y)})});const p=async g=>{if(g==null)return 0;if(I.isBlob(g))return g.size;if(I.isSpecCompliantForm(g))return(await new r(fe.origin,{method:"POST",body:g}).arrayBuffer()).byteLength;if(I.isArrayBufferView(g)||I.isArrayBuffer(g))return g.byteLength;if(I.isURLSearchParams(g)&&(g=g+""),I.isString(g))return(await l(g)).byteLength},b=async(g,m)=>{const y=I.toFiniteNumber(g.getContentLength());return y??p(m)};return async g=>{let{url:m,method:y,data:v,signal:E,cancelToken:T,timeout:N,onDownloadProgress:S,onUploadProgress:F,responseType:L,headers:U,withCredentials:_="same-origin",fetchOptions:j}=xi(g),pe=e||fetch;L=L?(L+"").toLowerCase():"text";let oe=Ou([E,T&&T.toAbortSignal()],N),R=null;const le=oe&&oe.unsubscribe&&(()=>{oe.unsubscribe()});let Pe;try{if(F&&c&&y!=="get"&&y!=="head"&&(Pe=await b(U,v))!==0){let re=new r(m,{method:"POST",body:v,duplex:"half"}),ce;if(I.isFormData(v)&&(ce=re.headers.get("content-type"))&&U.setContentType(ce),re.body){const[Ze,V]=mi(Pe,or(yi(F)));v=Ei(re.body,vi,Ze,V)}}I.isString(_)||(_=_?"include":"omit");const J=s&&"credentials"in r.prototype,ae={...j,signal:oe,method:y.toUpperCase(),headers:U.normalize().toJSON(),body:v,duplex:"half",credentials:J?_:void 0};R=s&&new r(m,ae);let K=await(s?pe(R,j):pe(m,ae));const ke=a&&(L==="stream"||L==="response");if(a&&(S||ke&&le)){const re={};["status","statusText","headers"].forEach(q=>{re[q]=K[q]});const ce=I.toFiniteNumber(K.headers.get("content-length")),[Ze,V]=S&&mi(ce,or(yi(S),!0))||[];K=new n(Ei(K.body,vi,Ze,()=>{V&&V(),le&&le()}),re)}L=L||"text";let Ye=await h[I.findKey(h,L)||"text"](K,g);return!ke&&le&&le(),await new Promise((re,ce)=>{gi(re,ce,{data:Ye,headers:Ee.from(K.headers),status:K.status,statusText:K.statusText,config:g,request:R})})}catch(J){throw le&&le(),J&&J.name==="TypeError"&&/Load failed|fetch/i.test(J.message)?Object.assign(new B("Network Error",B.ERR_NETWORK,g,R,J&&J.response),{cause:J.cause||J}):B.from(J,J&&J.code,g,R,J&&J.response)}}},Uu=new Map,Pi=t=>{let e=t&&t.env||{};const{fetch:r,Request:n,Response:i}=e,s=[n,i,r];let o=s.length,u=o,l,c,a=Uu;for(;u--;)l=s[u],c=a.get(l),c===void 0&&a.set(l,c=u?new Map:_u(e)),a=c;return c};Pi();const Jr={http:Qa,xhr:Su,fetch:{get:Pi}};I.forEach(Jr,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const Ii=t=>`- ${t}`,Bu=t=>I.isFunction(t)||t===null||t===!1;function ku(t,e){t=I.isArray(t)?t:[t];const{length:r}=t;let n,i;const s={};for(let o=0;o<r;o++){n=t[o];let u;if(i=n,!Bu(n)&&(i=Jr[(u=String(n)).toLowerCase()],i===void 0))throw new B(`Unknown adapter '${u}'`);if(i&&(I.isFunction(i)||(i=i.get(e))))break;s[u||"#"+o]=i}if(!i){const o=Object.entries(s).map(([l,c])=>`adapter ${l} `+(c===!1?"is not supported by the environment":"is not available in the build"));let u=r?o.length>1?`since :
4
- `+o.map(Ii).join(`
5
- `):" "+Ii(o[0]):"as no adapter specified";throw new B("There is no suitable adapter to dispatch the request "+u,"ERR_NOT_SUPPORT")}return i}var Si={getAdapter:ku,adapters:Jr};function Xr(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Lt(null,t)}function Oi(t){return Xr(t),t.headers=Ee.from(t.headers),t.data=Kr.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),Si.getAdapter(t.adapter||Rt.adapter,t)(t).then(function(n){return Xr(t),n.data=Kr.call(t,t.transformResponse,n),n.headers=Ee.from(n.headers),n},function(n){return pi(n)||(Xr(t),n&&n.response&&(n.response.data=Kr.call(t,t.transformResponse,n.response),n.response.headers=Ee.from(n.response.headers))),Promise.reject(n)})}const Ci="1.13.5",ur={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{ur[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});const Ri={};ur.transitional=function(e,r,n){function i(s,o){return"[Axios v"+Ci+"] Transitional option '"+s+"'"+o+(n?". "+n:"")}return(s,o,u)=>{if(e===!1)throw new B(i(o," has been removed"+(r?" in "+r:"")),B.ERR_DEPRECATED);return r&&!Ri[o]&&(Ri[o]=!0,console.warn(i(o," has been deprecated since v"+r+" and will be removed in the near future"))),e?e(s,o,u):!0}},ur.spelling=function(e){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};function $u(t,e,r){if(typeof t!="object")throw new B("options must be an object",B.ERR_BAD_OPTION_VALUE);const n=Object.keys(t);let i=n.length;for(;i-- >0;){const s=n[i],o=e[s];if(o){const u=t[s],l=u===void 0||o(u,s,t);if(l!==!0)throw new B("option "+s+" must be "+l,B.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new B("Unknown option "+s,B.ERR_BAD_OPTION)}}var lr={assertOptions:$u,validators:ur};const Se=lr.validators;let nt=class{constructor(e){this.defaults=e||{},this.interceptors={request:new fi,response:new fi}}async request(e,r){try{return await this._request(e,r)}catch(n){if(n instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const s=i.stack?i.stack.replace(/^.+\n/,""):"";try{n.stack?s&&!String(n.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(n.stack+=`
6
- `+s):n.stack=s}catch{}}throw n}}_request(e,r){typeof e=="string"?(r=r||{},r.url=e):r=e||{},r=rt(this.defaults,r);const{transitional:n,paramsSerializer:i,headers:s}=r;n!==void 0&&lr.assertOptions(n,{silentJSONParsing:Se.transitional(Se.boolean),forcedJSONParsing:Se.transitional(Se.boolean),clarifyTimeoutError:Se.transitional(Se.boolean),legacyInterceptorReqResOrdering:Se.transitional(Se.boolean)},!1),i!=null&&(I.isFunction(i)?r.paramsSerializer={serialize:i}:lr.assertOptions(i,{encode:Se.function,serialize:Se.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),lr.assertOptions(r,{baseUrl:Se.spelling("baseURL"),withXsrfToken:Se.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let o=s&&I.merge(s.common,s[r.method]);s&&I.forEach(["delete","get","head","post","put","patch","common"],g=>{delete s[g]}),r.headers=Ee.concat(o,s);const u=[];let l=!0;this.interceptors.request.forEach(function(m){if(typeof m.runWhen=="function"&&m.runWhen(r)===!1)return;l=l&&m.synchronous;const y=r.transitional||qr;y&&y.legacyInterceptorReqResOrdering?u.unshift(m.fulfilled,m.rejected):u.push(m.fulfilled,m.rejected)});const c=[];this.interceptors.response.forEach(function(m){c.push(m.fulfilled,m.rejected)});let a,h=0,p;if(!l){const g=[Oi.bind(this),void 0];for(g.unshift(...u),g.push(...c),p=g.length,a=Promise.resolve(r);h<p;)a=a.then(g[h++],g[h++]);return a}p=u.length;let b=r;for(;h<p;){const g=u[h++],m=u[h++];try{b=g(b)}catch(y){m.call(this,y);break}}try{a=Oi.call(this,b)}catch(g){return Promise.reject(g)}for(h=0,p=c.length;h<p;)a=a.then(c[h++],c[h++]);return a}getUri(e){e=rt(this.defaults,e);const r=bi(e.baseURL,e.url,e.allowAbsoluteUrls);return ci(r,e.params,e.paramsSerializer)}};I.forEach(["delete","get","head","options"],function(e){nt.prototype[e]=function(r,n){return this.request(rt(n||{},{method:e,url:r,data:(n||{}).data}))}}),I.forEach(["post","put","patch"],function(e){function r(n){return function(s,o,u){return this.request(rt(u||{},{method:e,headers:n?{"Content-Type":"multipart/form-data"}:{},url:s,data:o}))}}nt.prototype[e]=r(),nt.prototype[e+"Form"]=r(!0)});let ju=class Jo{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(s){r=s});const n=this;this.promise.then(i=>{if(!n._listeners)return;let s=n._listeners.length;for(;s-- >0;)n._listeners[s](i);n._listeners=null}),this.promise.then=i=>{let s;const o=new Promise(u=>{n.subscribe(u),s=u}).then(i);return o.cancel=function(){n.unsubscribe(s)},o},e(function(s,o,u){n.reason||(n.reason=new Lt(s,o,u),r(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;const r=this._listeners.indexOf(e);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const e=new AbortController,r=n=>{e.abort(n)};return this.subscribe(r),e.signal.unsubscribe=()=>this.unsubscribe(r),e.signal}static source(){let e;return{token:new Jo(function(i){e=i}),cancel:e}}};function Mu(t){return function(r){return t.apply(null,r)}}function Du(t){return I.isObject(t)&&t.isAxiosError===!0}const Yr={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(Yr).forEach(([t,e])=>{Yr[e]=t});function Fi(t){const e=new nt(t),r=Kn(nt.prototype.request,e);return I.extend(r,nt.prototype,e,{allOwnKeys:!0}),I.extend(r,e,null,{allOwnKeys:!0}),r.create=function(i){return Fi(rt(t,i))},r}const Q=Fi(Rt);Q.Axios=nt,Q.CanceledError=Lt,Q.CancelToken=ju,Q.isCancel=pi,Q.VERSION=Ci,Q.toFormData=ir,Q.AxiosError=B,Q.Cancel=Q.CanceledError,Q.all=function(e){return Promise.all(e)},Q.spread=Mu,Q.isAxiosError=Du,Q.mergeConfig=rt,Q.AxiosHeaders=Ee,Q.formToJSON=t=>hi(I.isHTMLForm(t)?new FormData(t):t),Q.getAdapter=Si.getAdapter,Q.HttpStatusCode=Yr,Q.default=Q;const{Axios:Wg,AxiosError:Gg,CanceledError:Kg,isCancel:Jg,CancelToken:Xg,VERSION:Yg,all:Zg,Cancel:Qg,isAxiosError:e0,spread:t0,toFormData:r0,AxiosHeaders:n0,HttpStatusCode:i0,formToJSON:s0,getAdapter:o0,mergeConfig:a0}=Q,cr=t=>encodeURIComponent(t).split("%2F").join("/"),Vu=/^(\w+:\/\/[^/?]+)?(.*?)$/,Hu=t=>t.filter(e=>typeof e=="string"||typeof e=="number").map(e=>`${e}`).filter(e=>e),qu=t=>{const e=t.join("/"),[,r="",n=""]=e.match(Vu)||[];return{prefix:r,pathname:{parts:n.split("/").filter(i=>i!==""),hasLeading:/^\/+/.test(n),hasTrailing:/\/+$/.test(n)}}},zu=(t,e)=>{const{prefix:r,pathname:n}=t,{parts:i,hasLeading:s,hasTrailing:o}=n,{leadingSlash:u,trailingSlash:l}=e,c=u===!0||u==="keep"&&s,a=l===!0||l==="keep"&&o;let h=r;return i.length>0&&((h||c)&&(h+="/"),h+=i.join("/")),a&&(h+="/"),!h&&c&&(h+="/"),h},$=(...t)=>{const e=t[t.length-1];let r;e&&typeof e=="object"&&(r=e,t=t.slice(0,-1)),r={leadingSlash:!0,trailingSlash:!1,...r},t=Hu(t);const n=qu(t);return zu(n,r)};class Li extends Error{response;statusCode;constructor(e,r,n=null){super(e),this.response=r,this.statusCode=n}}class Wu extends Li{errorCode;constructor(e,r,n,i=null){super(e,n,i),this.errorCode=r}}function Gu(t,e=""){return`/public-files/${t}/${e}`.split("/").filter(Boolean).join("/")}function Ku(t,e=""){return`/ocm/${t}/${e}`.split("/").filter(Boolean).join("/")}var Zr,_i;function Ju(){if(_i)return Zr;_i=1;function t(i){if(typeof i!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(i))}function e(i,s){for(var o="",u=0,l=-1,c=0,a,h=0;h<=i.length;++h){if(h<i.length)a=i.charCodeAt(h);else{if(a===47)break;a=47}if(a===47){if(!(l===h-1||c===1))if(l!==h-1&&c===2){if(o.length<2||u!==2||o.charCodeAt(o.length-1)!==46||o.charCodeAt(o.length-2)!==46){if(o.length>2){var p=o.lastIndexOf("/");if(p!==o.length-1){p===-1?(o="",u=0):(o=o.slice(0,p),u=o.length-1-o.lastIndexOf("/")),l=h,c=0;continue}}else if(o.length===2||o.length===1){o="",u=0,l=h,c=0;continue}}s&&(o.length>0?o+="/..":o="..",u=2)}else o.length>0?o+="/"+i.slice(l+1,h):o=i.slice(l+1,h),u=h-l-1;l=h,c=0}else a===46&&c!==-1?++c:c=-1}return o}function r(i,s){var o=s.dir||s.root,u=s.base||(s.name||"")+(s.ext||"");return o?o===s.root?o+u:o+i+u:u}var n={resolve:function(){for(var s="",o=!1,u,l=arguments.length-1;l>=-1&&!o;l--){var c;l>=0?c=arguments[l]:(u===void 0&&(u=Ue.cwd()),c=u),t(c),c.length!==0&&(s=c+"/"+s,o=c.charCodeAt(0)===47)}return s=e(s,!o),o?s.length>0?"/"+s:"/":s.length>0?s:"."},normalize:function(s){if(t(s),s.length===0)return".";var o=s.charCodeAt(0)===47,u=s.charCodeAt(s.length-1)===47;return s=e(s,!o),s.length===0&&!o&&(s="."),s.length>0&&u&&(s+="/"),o?"/"+s:s},isAbsolute:function(s){return t(s),s.length>0&&s.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var s,o=0;o<arguments.length;++o){var u=arguments[o];t(u),u.length>0&&(s===void 0?s=u:s+="/"+u)}return s===void 0?".":n.normalize(s)},relative:function(s,o){if(t(s),t(o),s===o||(s=n.resolve(s),o=n.resolve(o),s===o))return"";for(var u=1;u<s.length&&s.charCodeAt(u)===47;++u);for(var l=s.length,c=l-u,a=1;a<o.length&&o.charCodeAt(a)===47;++a);for(var h=o.length,p=h-a,b=c<p?c:p,g=-1,m=0;m<=b;++m){if(m===b){if(p>b){if(o.charCodeAt(a+m)===47)return o.slice(a+m+1);if(m===0)return o.slice(a+m)}else c>b&&(s.charCodeAt(u+m)===47?g=m:m===0&&(g=0));break}var y=s.charCodeAt(u+m),v=o.charCodeAt(a+m);if(y!==v)break;y===47&&(g=m)}var E="";for(m=u+g+1;m<=l;++m)(m===l||s.charCodeAt(m)===47)&&(E.length===0?E+="..":E+="/..");return E.length>0?E+o.slice(a+g):(a+=g,o.charCodeAt(a)===47&&++a,o.slice(a))},_makeLong:function(s){return s},dirname:function(s){if(t(s),s.length===0)return".";for(var o=s.charCodeAt(0),u=o===47,l=-1,c=!0,a=s.length-1;a>=1;--a)if(o=s.charCodeAt(a),o===47){if(!c){l=a;break}}else c=!1;return l===-1?u?"/":".":u&&l===1?"//":s.slice(0,l)},basename:function(s,o){if(o!==void 0&&typeof o!="string")throw new TypeError('"ext" argument must be a string');t(s);var u=0,l=-1,c=!0,a;if(o!==void 0&&o.length>0&&o.length<=s.length){if(o.length===s.length&&o===s)return"";var h=o.length-1,p=-1;for(a=s.length-1;a>=0;--a){var b=s.charCodeAt(a);if(b===47){if(!c){u=a+1;break}}else p===-1&&(c=!1,p=a+1),h>=0&&(b===o.charCodeAt(h)?--h===-1&&(l=a):(h=-1,l=p))}return u===l?l=p:l===-1&&(l=s.length),s.slice(u,l)}else{for(a=s.length-1;a>=0;--a)if(s.charCodeAt(a)===47){if(!c){u=a+1;break}}else l===-1&&(c=!1,l=a+1);return l===-1?"":s.slice(u,l)}},extname:function(s){t(s);for(var o=-1,u=0,l=-1,c=!0,a=0,h=s.length-1;h>=0;--h){var p=s.charCodeAt(h);if(p===47){if(!c){u=h+1;break}continue}l===-1&&(c=!1,l=h+1),p===46?o===-1?o=h:a!==1&&(a=1):o!==-1&&(a=-1)}return o===-1||l===-1||a===0||a===1&&o===l-1&&o===u+1?"":s.slice(o,l)},format:function(s){if(s===null||typeof s!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof s);return r("/",s)},parse:function(s){t(s);var o={root:"",dir:"",base:"",ext:"",name:""};if(s.length===0)return o;var u=s.charCodeAt(0),l=u===47,c;l?(o.root="/",c=1):c=0;for(var a=-1,h=0,p=-1,b=!0,g=s.length-1,m=0;g>=c;--g){if(u=s.charCodeAt(g),u===47){if(!b){h=g+1;break}continue}p===-1&&(b=!1,p=g+1),u===46?a===-1?a=g:m!==1&&(m=1):a!==-1&&(m=-1)}return a===-1||p===-1||m===0||m===1&&a===p-1&&a===h+1?p!==-1&&(h===0&&l?o.base=o.name=s.slice(1,p):o.base=o.name=s.slice(h,p)):(h===0&&l?(o.name=s.slice(1,a),o.base=s.slice(1,p)):(o.name=s.slice(h,a),o.base=s.slice(h,p)),o.ext=s.slice(a,p)),h>0?o.dir=s.slice(0,h-1):l&&(o.dir="/"),o},sep:"/",delimiter:":",win32:null,posix:null};return n.posix=n,Zr=n,Zr}var Ui=Ju(),Bi=Dn(Ui);class Fe{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"}var Ve=(t=>(t.copy="COPY",t.delete="DELETE",t.lock="LOCK",t.mkcol="MKCOL",t.move="MOVE",t.propfind="PROPFIND",t.proppatch="PROPPATCH",t.put="PUT",t.report="REPORT",t.unlock="UNLOCK",t))(Ve||{});const fr=t=>({value:t,type:null}),Xu=t=>fr(t),M=t=>fr(t),hr=t=>fr(t),Yu=t=>fr(t),Zu={Permissions:M("permissions"),IsFavorite:hr("favorite"),FileId:M("fileid"),FileParent:M("file-parent"),Name:M("name"),OwnerId:M("owner-id"),OwnerDisplayName:M("owner-display-name"),PrivateLink:M("privatelink"),ContentLength:hr("getcontentlength"),ContentSize:hr("size"),LastModifiedDate:M("getlastmodified"),Tags:Xu("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:Yu("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:hr("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")},C=Object.fromEntries(Object.entries(Zu).map(([t,e])=>[t,e.value]));class it{static Default=[C.Permissions,C.IsFavorite,C.FileId,C.FileParent,C.Name,C.LockDiscovery,C.ActiveLock,C.OwnerId,C.OwnerDisplayName,C.RemoteItemId,C.ShareRoot,C.ShareTypes,C.PrivateLink,C.ContentLength,C.ContentSize,C.LastModifiedDate,C.ETag,C.MimeType,C.ResourceType,C.Tags,C.Audio,C.Location,C.Image,C.Photo,C.HasPreview];static PublicLink=it.Default.concat([C.PublicLinkItemType,C.PublicLinkPermission,C.PublicLinkExpiration,C.PublicLinkShareDate,C.PublicLinkShareOwner]);static Trashbin=[C.ContentLength,C.ResourceType,C.TrashbinOriginalLocation,C.TrashbinOriginalFilename,C.TrashbinDeletedDate,C.Permissions,C.FileParent];static DavNamespace=[C.ContentLength,C.LastModifiedDate,C.ETag,C.MimeType,C.ResourceType,C.LockDiscovery,C.ActiveLock]}var Qu=typeof je=="object"&&je&&je.Object===Object&&je,el=typeof self=="object"&&self&&self.Object===Object&&self,Qr=Qu||el||Function("return this")(),yt=Qr.Symbol,ki=Object.prototype,tl=ki.hasOwnProperty,rl=ki.toString,_t=yt?yt.toStringTag:void 0;function nl(t){var e=tl.call(t,_t),r=t[_t];try{t[_t]=void 0;var n=!0}catch{}var i=rl.call(t);return n&&(e?t[_t]=r:delete t[_t]),i}var il=Object.prototype,sl=il.toString;function ol(t){return sl.call(t)}var al="[object Null]",ul="[object Undefined]",$i=yt?yt.toStringTag:void 0;function ji(t){return t==null?t===void 0?ul:al:$i&&$i in Object(t)?nl(t):ol(t)}function ll(t){return t!=null&&typeof t=="object"}var cl="[object Symbol]";function en(t){return typeof t=="symbol"||ll(t)&&ji(t)==cl}function fl(t,e){for(var r=-1,n=t==null?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}var tn=Array.isArray,Mi=yt?yt.prototype:void 0,Di=Mi?Mi.toString:void 0;function Vi(t){if(typeof t=="string")return t;if(tn(t))return fl(t,Vi)+"";if(en(t))return Di?Di.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function Hi(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var hl="[object AsyncFunction]",dl="[object Function]",pl="[object GeneratorFunction]",gl="[object Proxy]";function ml(t){if(!Hi(t))return!1;var e=ji(t);return e==dl||e==pl||e==hl||e==gl}var rn=Qr["__core-js_shared__"],qi=(function(){var t=/[^.]+$/.exec(rn&&rn.keys&&rn.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function yl(t){return!!qi&&qi in t}var bl=Function.prototype,wl=bl.toString;function xl(t){if(t!=null){try{return wl.call(t)}catch{}try{return t+""}catch{}}return""}var El=/[\\^$.*+?()[\]{}|]/g,vl=/^\[object .+?Constructor\]$/,Tl=Function.prototype,Al=Object.prototype,Nl=Tl.toString,Pl=Al.hasOwnProperty,Il=RegExp("^"+Nl.call(Pl).replace(El,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Sl(t){if(!Hi(t)||yl(t))return!1;var e=ml(t)?Il:vl;return e.test(xl(t))}function Ol(t,e){return t?.[e]}function zi(t,e){var r=Ol(t,e);return Sl(r)?r:void 0}function Cl(t,e){return t===e||t!==t&&e!==e}var Rl=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Fl=/^\w*$/;function Ll(t,e){if(tn(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||en(t)?!0:Fl.test(t)||!Rl.test(t)||e!=null&&t in Object(e)}var Ut=zi(Object,"create");function _l(){this.__data__=Ut?Ut(null):{},this.size=0}function Ul(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var Bl="__lodash_hash_undefined__",kl=Object.prototype,$l=kl.hasOwnProperty;function jl(t){var e=this.__data__;if(Ut){var r=e[t];return r===Bl?void 0:r}return $l.call(e,t)?e[t]:void 0}var Ml=Object.prototype,Dl=Ml.hasOwnProperty;function Vl(t){var e=this.__data__;return Ut?e[t]!==void 0:Dl.call(e,t)}var Hl="__lodash_hash_undefined__";function ql(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Ut&&e===void 0?Hl:e,this}function st(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}st.prototype.clear=_l,st.prototype.delete=Ul,st.prototype.get=jl,st.prototype.has=Vl,st.prototype.set=ql;function zl(){this.__data__=[],this.size=0}function dr(t,e){for(var r=t.length;r--;)if(Cl(t[r][0],e))return r;return-1}var Wl=Array.prototype,Gl=Wl.splice;function Kl(t){var e=this.__data__,r=dr(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():Gl.call(e,r,1),--this.size,!0}function Jl(t){var e=this.__data__,r=dr(e,t);return r<0?void 0:e[r][1]}function Xl(t){return dr(this.__data__,t)>-1}function Yl(t,e){var r=this.__data__,n=dr(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}function bt(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}bt.prototype.clear=zl,bt.prototype.delete=Kl,bt.prototype.get=Jl,bt.prototype.has=Xl,bt.prototype.set=Yl;var Zl=zi(Qr,"Map");function Ql(){this.size=0,this.__data__={hash:new st,map:new(Zl||bt),string:new st}}function ec(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function pr(t,e){var r=t.__data__;return ec(e)?r[typeof e=="string"?"string":"hash"]:r.map}function tc(t){var e=pr(this,t).delete(t);return this.size-=e?1:0,e}function rc(t){return pr(this,t).get(t)}function nc(t){return pr(this,t).has(t)}function ic(t,e){var r=pr(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}function ot(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}ot.prototype.clear=Ql,ot.prototype.delete=tc,ot.prototype.get=rc,ot.prototype.has=nc,ot.prototype.set=ic;var sc="Expected a function";function nn(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(sc);var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],s=r.cache;if(s.has(i))return s.get(i);var o=t.apply(this,n);return r.cache=s.set(i,o)||s,o};return r.cache=new(nn.Cache||ot),r}nn.Cache=ot;var oc=500;function ac(t){var e=nn(t,function(n){return r.size===oc&&r.clear(),n}),r=e.cache;return e}var uc=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,lc=/\\(\\)?/g,cc=ac(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(uc,function(r,n,i,s){e.push(i?s.replace(lc,"$1"):n||r)}),e});function Bt(t){return t==null?"":Vi(t)}function fc(t,e){return tn(t)?t:Ll(t,e)?[t]:cc(Bt(t))}function hc(t){if(typeof t=="string"||en(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function dc(t,e){e=fc(e,t);for(var r=0,n=e.length;t!=null&&r<n;)t=t[hc(e[r++])];return r&&r==n?t:void 0}function pc(t,e,r){var n=t==null?void 0:dc(t,e);return n===void 0?r:n}function gc(t,e,r){var n=-1,i=t.length;e<0&&(e=-e>i?0:i+e),r=r>i?i:r,r<0&&(r+=i),i=e>r?0:r-e>>>0,e>>>=0;for(var s=Array(i);++n<i;)s[n]=t[n+e];return s}function mc(t,e,r){var n=t.length;return r=r===void 0?n:r,!e&&r>=n?t:gc(t,e,r)}var yc="\\ud800-\\udfff",bc="\\u0300-\\u036f",wc="\\ufe20-\\ufe2f",xc="\\u20d0-\\u20ff",Ec=bc+wc+xc,vc="\\ufe0e\\ufe0f",Tc="\\u200d",Ac=RegExp("["+Tc+yc+Ec+vc+"]");function Wi(t){return Ac.test(t)}function Nc(t){return t.split("")}var Gi="\\ud800-\\udfff",Pc="\\u0300-\\u036f",Ic="\\ufe20-\\ufe2f",Sc="\\u20d0-\\u20ff",Oc=Pc+Ic+Sc,Cc="\\ufe0e\\ufe0f",Rc="["+Gi+"]",sn="["+Oc+"]",on="\\ud83c[\\udffb-\\udfff]",Fc="(?:"+sn+"|"+on+")",Ki="[^"+Gi+"]",Ji="(?:\\ud83c[\\udde6-\\uddff]){2}",Xi="[\\ud800-\\udbff][\\udc00-\\udfff]",Lc="\\u200d",Yi=Fc+"?",Zi="["+Cc+"]?",_c="(?:"+Lc+"(?:"+[Ki,Ji,Xi].join("|")+")"+Zi+Yi+")*",Uc=Zi+Yi+_c,Bc="(?:"+[Ki+sn+"?",sn,Ji,Xi,Rc].join("|")+")",kc=RegExp(on+"(?="+on+")|"+Bc+Uc,"g");function $c(t){return t.match(kc)||[]}function jc(t){return Wi(t)?$c(t):Nc(t)}function Mc(t){return function(e){e=Bt(e);var r=Wi(e)?jc(e):void 0,n=r?r[0]:e.charAt(0),i=r?mc(r,1).join(""):e.slice(1);return n[t]()+i}}var Dc=Mc("toUpperCase");function Vc(t){return Dc(Bt(t).toLowerCase())}function Hc(t,e,r,n){for(var i=-1,s=t==null?0:t.length;++i<s;)r=e(r,t[i],i,t);return r}function qc(t){return function(e){return t?.[e]}}var zc={À:"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"},Wc=qc(zc),Gc=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Kc="\\u0300-\\u036f",Jc="\\ufe20-\\ufe2f",Xc="\\u20d0-\\u20ff",Yc=Kc+Jc+Xc,Zc="["+Yc+"]",Qc=RegExp(Zc,"g");function ef(t){return t=Bt(t),t&&t.replace(Gc,Wc).replace(Qc,"")}var tf=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function rf(t){return t.match(tf)||[]}var nf=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function sf(t){return nf.test(t)}var Qi="\\ud800-\\udfff",of="\\u0300-\\u036f",af="\\ufe20-\\ufe2f",uf="\\u20d0-\\u20ff",lf=of+af+uf,es="\\u2700-\\u27bf",ts="a-z\\xdf-\\xf6\\xf8-\\xff",cf="\\xac\\xb1\\xd7\\xf7",ff="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",hf="\\u2000-\\u206f",df=" \\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",rs="A-Z\\xc0-\\xd6\\xd8-\\xde",pf="\\ufe0e\\ufe0f",ns=cf+ff+hf+df,is="['’]",ss="["+ns+"]",gf="["+lf+"]",os="\\d+",mf="["+es+"]",as="["+ts+"]",us="[^"+Qi+ns+os+es+ts+rs+"]",yf="\\ud83c[\\udffb-\\udfff]",bf="(?:"+gf+"|"+yf+")",wf="[^"+Qi+"]",ls="(?:\\ud83c[\\udde6-\\uddff]){2}",cs="[\\ud800-\\udbff][\\udc00-\\udfff]",wt="["+rs+"]",xf="\\u200d",fs="(?:"+as+"|"+us+")",Ef="(?:"+wt+"|"+us+")",hs="(?:"+is+"(?:d|ll|m|re|s|t|ve))?",ds="(?:"+is+"(?:D|LL|M|RE|S|T|VE))?",ps=bf+"?",gs="["+pf+"]?",vf="(?:"+xf+"(?:"+[wf,ls,cs].join("|")+")"+gs+ps+")*",Tf="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Af="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Nf=gs+ps+vf,Pf="(?:"+[mf,ls,cs].join("|")+")"+Nf,If=RegExp([wt+"?"+as+"+"+hs+"(?="+[ss,wt,"$"].join("|")+")",Ef+"+"+ds+"(?="+[ss,wt+fs,"$"].join("|")+")",wt+"?"+fs+"+"+hs,wt+"+"+ds,Af,Tf,os,Pf].join("|"),"g");function Sf(t){return t.match(If)||[]}function Of(t,e,r){return t=Bt(t),e=e,e===void 0?sf(t)?Sf(t):rf(t):t.match(e)||[]}var Cf="['’]",Rf=RegExp(Cf,"g");function Ff(t){return function(e){return Hc(Of(ef(e).replace(Rf,"")),t,"")}}var Lf=Ff(function(t,e,r){return e=e.toLowerCase(),t+(r?Vc(e):e)});const _f={complex:["tar.bz2","tar.gz","tar.xz"]},an=t=>t.replace(/[^A-Za-z0-9\-_]/g,""),ms=(t,e)=>!t||typeof t!="string"?"":t.indexOf("!")>=0?t.split("!")[e]:"",Uf=t=>ms(t,0),ys=t=>ms(t,1),bs=t=>{const r=t.name.split(".");if(r.length>2)for(let n=0;n<r.length;n++){const i=r.slice(n,r.length).join(".");if(_f.complex.includes(i))return i}return r.length<2?"":r[r.length-1]},gr=t=>{if(!t)return t;const e={};return Object.keys(t).forEach(r=>{e[Lf(r)]=t[r]}),e};function xt(t,e=[]){const r=t.props[C.Name]?.toString()||Ui.basename(t.filename),n=t.props[C.FileId],i=t.type==="directory";let s;t.filename.startsWith("/files")||t.filename.startsWith("/space")?s=t.filename.split("/").slice(3).join("/"):s=t.filename,s.startsWith("/")||(s=`/${s}`);const o=bs({...t,name:r}),u=t.props[C.LockDiscovery];let l,c,a;u&&(l=u[C.ActiveLock],c=l[C.LockOwner],a=l[C.LockTime]);let h=[];t.props[C.ShareTypes]&&(h=t.props[C.ShareTypes]["share-type"],Array.isArray(h)||(h=[h]));const p={};for(const g of e||[]){const m=g.split(":").pop();t.props[m]&&(p[g]=t.props[m])}const b={id:n,fileId:n,storageId:Uf(n),parentFolderId:t.props[C.FileParent],mimeType:t.props[C.MimeType],name:r,extension:o,path:s,webDavPath:t.filename,type:i?"folder":t.type,isFolder:i,locked:!!l,lockOwner:c,lockTime:a,processing:t.processing||!1,mdate:t.props[C.LastModifiedDate],size:i?t.props[C.ContentSize]?.toString()||"0":t.props[C.ContentLength]?.toString()||"0",permissions:t.props[C.Permissions]||"",starred:t.props[C.IsFavorite]!==0,etag:t.props[C.ETag],shareTypes:h,privateLink:t.props[C.PrivateLink],downloadURL:t.props[C.DownloadURL],remoteItemId:t.props[C.RemoteItemId],remoteItemPath:t.props[C.ShareRoot],owner:{id:t.props[C.OwnerId],displayName:t.props[C.OwnerDisplayName]},tags:(t.props[C.Tags]||"").toString().split(",").filter(Boolean),audio:gr(t.props[C.Audio]),location:gr(t.props[C.Location]),image:gr(t.props[C.Image]),photo:gr(t.props[C.Photo]),extraProps:p,hasPreview:()=>t.props[C.HasPreview]===1,canUpload:function(){return this.permissions.indexOf(Fe.FolderCreateable)>=0},canDownload:function(){return this.permissions.indexOf(Fe.SecureView)===-1},canBeDeleted:function(){return this.permissions.indexOf(Fe.Deletable)>=0},canRename:function(){return this.permissions.indexOf(Fe.Renameable)>=0},canShare:function({ability:g}){return g.can("create-all","Share")&&this.permissions.indexOf(Fe.Shareable)>=0},canCreate:function(){return this.permissions.indexOf(Fe.FolderCreateable)>=0},canEditTags:function(){return this.permissions.indexOf(Fe.Updateable)>=0||this.permissions.indexOf(Fe.FileUpdateable)>=0||this.permissions.indexOf(Fe.FolderCreateable)>=0},isMounted:function(){return this.permissions.indexOf(Fe.Mounted)>=0},isReceivedShare:function(){return this.permissions.indexOf(Fe.Shared)>=0},isShareRoot(){return t.props[C.ShareRoot]?t.filename.split("/").length===3:!1},getDomSelector:()=>an(n)};return Object.defineProperty(b,"nodeId",{get(){return ys(this.id)}}),b}function Bf(t){const e=t.type==="directory",r=t.props[C.TrashbinOriginalFilename]?.toString(),n=bs({name:r,type:t.type}),i=Bi.basename(t.filename);return{type:e?"folder":t.type,isFolder:e,ddate:t.props[C.TrashbinDeletedDate],name:Bi.basename(r),extension:n,path:$(t.props[C.TrashbinOriginalLocation],{leadingSlash:!0}),id:i,parentFolderId:t.props[C.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:()=>an(i)}}var Ne=(t=>(t.createUpload="libre.graph/driveItem/upload/create",t.createPermissions="libre.graph/driveItem/permissions/create",t.createChildren="libre.graph/driveItem/children/create",t.readBasic="libre.graph/driveItem/basic/read",t.readPath="libre.graph/driveItem/path/read",t.readQuota="libre.graph/driveItem/quota/read",t.readContent="libre.graph/driveItem/content/read",t.readChildren="libre.graph/driveItem/children/read",t.readDeleted="libre.graph/driveItem/deleted/read",t.readPermissions="libre.graph/driveItem/permissions/read",t.readVersions="libre.graph/driveItem/versions/read",t.updatePath="libre.graph/driveItem/path/update",t.updateDeleted="libre.graph/driveItem/deleted/update",t.updatePermissions="libre.graph/driveItem/permissions/update",t.updateVersions="libre.graph/driveItem/versions/update",t.deleteStandard="libre.graph/driveItem/standard/delete",t.deleteDeleted="libre.graph/driveItem/deleted/delete",t.deletePermissions="libre.graph/driveItem/permissions/delete",t))(Ne||{});const un=t=>t?.driveType==="personal",ln=t=>t?.driveType==="public";function kf(t,e){return $("spaces",t,e,{leadingSlash:!0})}function cn(t,e=""){return $("spaces","trash-bin",t,e,{leadingSlash:!0})}function $f(t){const e=t.publicLinkPassword,r=t.props?.[C.FileId],n=t.props?.[C.PublicLinkItemType],i=t.props?.[C.PublicLinkPermission],s=t.props?.[C.PublicLinkExpiration],o=t.props?.[C.PublicLinkShareDate],u=t.props?.[C.PublicLinkShareOwner],l=t.publicLinkType;let c,a;return l==="ocm"?(c=`ocm/${t.id}`,a=Ku(t.id)):(c=`public/${t.id}`,a=Gu(t.id)),Object.assign(jf({...t,driveType:"public",driveAlias:c,webDavPath:a}),{...r&&{fileId:r},...e&&{publicLinkPassword:e},...n&&{publicLinkItemType:n},...i&&{publicLinkPermission:parseInt(i)},...s&&{publicLinkExpiration:s},...o&&{publicLinkShareDate:o},...u&&{publicLinkShareOwner:u},publicLinkType:l})}function jf(t){let e,r;t.special&&(e=t.special.find(c=>c.specialFolder.name==="image"),r=t.special.find(c=>c.specialFolder.name==="readme"),e&&(e.webDavUrl=decodeURI(e.webDavUrl)),r&&(r.webDavUrl=decodeURI(r.webDavUrl)));const n=t.root?.deleted?.state==="trashed",i=$(t.webDavPath||kf(t.id),{leadingSlash:!0}),s=$(t.serverUrl,"remote.php/dav",i),o=$(t.webDavTrashPath||cn(t.id),{leadingSlash:!0}),u=$(t.serverUrl,"remote.php/dav",o),l={id:t.id,fileId:t.id,storageId:t.id,mimeType:"",name:t.name,description:t.description,extension:"",path:"/",webDavPath:i,webDavTrashPath:o,driveAlias:t.driveAlias,driveType:t.driveType,type:"space",isFolder:!0,mdate:t.lastModifiedDateTime,size:t.quota?.used||0,tags:[],permissions:"",starred:!1,etag:"",shareTypes:[],privateLink:t.webUrl,downloadURL:"",owner:t.owner?.user,disabled:n,root:t.root,spaceQuota:t.quota,spaceImageData:e,spaceReadmeData:r,hasTrashedItems:t["@libre.graph.hasTrashedItems"]||!1,graphPermissions:void 0,canUpload:function({user:c}={}){return un(this)&&this.isOwner(c)?!0:this.graphPermissions?.includes(Ne.createUpload)},canDownload:function(){return!0},canBeDeleted:function({ability:c}={}){return this.disabled?c?.can("delete-all","Drive")?!0:this.graphPermissions?.includes(Ne.deletePermissions):!1},canRename:function({ability:c}={}){return c?.can("update-all","Drive")?!0:this.graphPermissions?.includes(Ne.deletePermissions)},canEditDescription:function({ability:c}={}){return c?.can("update-all","Drive")?!0:this.graphPermissions?.includes(Ne.deletePermissions)},canRestore:function({ability:c}={}){return this.disabled?c?.can("update-all","Drive")?!0:this.graphPermissions?.includes(Ne.deletePermissions):!1},canDisable:function({ability:c}={}){return this.disabled?!1:c?.can("delete-all","Drive")?!0:this.graphPermissions?.includes(Ne.deletePermissions)},canShare:function(){return this.graphPermissions?.includes(Ne.createPermissions)},canEditImage:function(){return this.disabled?!1:this.graphPermissions?.includes(Ne.deletePermissions)},canEditReadme:function(){return this.disabled?!1:this.graphPermissions?.includes(Ne.deletePermissions)},canRestoreFromTrashbin:function(){return this.graphPermissions?.includes(Ne.updateDeleted)},canDeleteFromTrashBin:function({user:c}={}){return un(this)&&this.isOwner(c)?!0:this.graphPermissions?.includes(Ne.deletePermissions)},canListVersions:function({user:c}={}){return un(this)&&this.isOwner(c)?!0:this.graphPermissions?.includes(Ne.readVersions)},canCreate:function(){return!0},canEditTags:function(){return!1},isMounted:function(){return!0},isReceivedShare:function(){return!1},isShareRoot:function(){return["share","mountpoint","public"].includes(t.driveType)},getDomSelector:()=>an(t.id),getDriveAliasAndItem({path:c}){return $(this.driveAlias,c,{leadingSlash:!1})},getWebDavUrl({path:c}){return $(s,c)},getWebDavTrashUrl({path:c}){return $(u,c)},isOwner(c){return c?.id===this.owner?.id}};return Object.defineProperty(l,"nodeId",{get(){return ys(this.id)}}),l}const Mf=(t,e)=>{const r=new URL(t);r.pathname=[...r.pathname.split("/"),"cloud","capabilities"].filter(Boolean).join("/"),r.searchParams.append("format","json");const n=r.href;return{async getCapabilities(){const i=await e.get(n);return pc(i,"data.ocs.data",{capabilities:null,version:null})}}};function Df(t){return t instanceof Uint8Array||ArrayBuffer.isView(t)&&t.constructor.name==="Uint8Array"}function kt(t,e=""){if(!Number.isSafeInteger(t)||t<0){const r=e&&`"${e}" `;throw new Error(`${r}expected integer >= 0, got ${t}`)}}function $t(t,e,r=""){const n=Df(t),i=t?.length,s=e!==void 0;if(!n||s&&i!==e){const o=r&&`"${r}" `,u=s?` of length ${e}`:"",l=n?`length=${i}`:`type=${typeof t}`;throw new Error(o+"expected Uint8Array"+u+", got "+l)}return t}function ws(t){if(typeof t!="function"||typeof t.create!="function")throw new Error("Hash must wrapped by utils.createHasher");kt(t.outputLen),kt(t.blockLen)}function mr(t,e=!0){if(t.destroyed)throw new Error("Hash instance has been destroyed");if(e&&t.finished)throw new Error("Hash#digest() has already been called")}function Vf(t,e){$t(t,void 0,"digestInto() output");const r=e.outputLen;if(t.length<r)throw new Error('"digestInto() output" expected to be of length >='+r)}function jt(...t){for(let e=0;e<t.length;e++)t[e].fill(0)}function yr(t){return new DataView(t.buffer,t.byteOffset,t.byteLength)}function Hf(t){if(typeof t!="string")throw new Error("string expected");return new Uint8Array(new TextEncoder().encode(t))}function xs(t,e=""){return typeof t=="string"?Hf(t):$t(t,void 0,e)}function qf(t,e){if(e!==void 0&&{}.toString.call(e)!=="[object Object]")throw new Error("options must be object or undefined");return Object.assign(t,e)}function zf(t,e={}){const r=(i,s)=>t(s).update(i).digest(),n=t(void 0);return r.outputLen=n.outputLen,r.blockLen=n.blockLen,r.create=i=>t(i),Object.assign(r,e),Object.freeze(r)}const Wf=t=>({oid:Uint8Array.from([6,9,96,134,72,1,101,3,4,2,t])});class Es{oHash;iHash;blockLen;outputLen;finished=!1;destroyed=!1;constructor(e,r){if(ws(e),$t(r,void 0,"key"),this.iHash=e.create(),typeof this.iHash.update!="function")throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const n=this.blockLen,i=new Uint8Array(n);i.set(r.length>n?e.create().update(r).digest():r);for(let s=0;s<i.length;s++)i[s]^=54;this.iHash.update(i),this.oHash=e.create();for(let s=0;s<i.length;s++)i[s]^=106;this.oHash.update(i),jt(i)}update(e){return mr(this),this.iHash.update(e),this}digestInto(e){mr(this),$t(e,this.outputLen,"output"),this.finished=!0,this.iHash.digestInto(e),this.oHash.update(e),this.oHash.digestInto(e),this.destroy()}digest(){const e=new Uint8Array(this.oHash.outputLen);return this.digestInto(e),e}_cloneInto(e){e||=Object.create(Object.getPrototypeOf(this),{});const{oHash:r,iHash:n,finished:i,destroyed:s,blockLen:o,outputLen:u}=this;return e=e,e.finished=i,e.destroyed=s,e.blockLen=o,e.outputLen=u,e.oHash=r._cloneInto(e.oHash),e.iHash=n._cloneInto(e.iHash),e}clone(){return this._cloneInto()}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}}const vs=(t,e,r)=>new Es(t,e).update(r).digest();vs.create=(t,e)=>new Es(t,e);function Gf(t,e,r,n){ws(t);const i=qf({dkLen:32,asyncTick:10},n),{c:s,dkLen:o,asyncTick:u}=i;if(kt(s,"c"),kt(o,"dkLen"),kt(u,"asyncTick"),s<1)throw new Error("iterations (c) must be >= 1");const l=xs(e,"password"),c=xs(r,"salt"),a=new Uint8Array(o),h=vs.create(t,l),p=h._cloneInto().update(c);return{c:s,dkLen:o,asyncTick:u,DK:a,PRF:h,PRFSalt:p}}function Kf(t,e,r,n,i){return t.destroy(),e.destroy(),n&&n.destroy(),jt(i),r}function Jf(t,e,r,n){const{c:i,dkLen:s,DK:o,PRF:u,PRFSalt:l}=Gf(t,e,r,n);let c;const a=new Uint8Array(4),h=yr(a),p=new Uint8Array(u.outputLen);for(let b=1,g=0;g<s;b++,g+=u.outputLen){const m=o.subarray(g,g+u.outputLen);h.setInt32(0,b,!1),(c=l._cloneInto(c)).update(a).digestInto(p),m.set(p.subarray(0,m.length));for(let y=1;y<i;y++){u._cloneInto(c).update(p).digestInto(p);for(let v=0;v<m.length;v++)m[v]^=p[v]}}return Kf(u,l,o,c,p)}class Xf{blockLen;outputLen;padOffset;isLE;buffer;view;finished=!1;length=0;pos=0;destroyed=!1;constructor(e,r,n,i){this.blockLen=e,this.outputLen=r,this.padOffset=n,this.isLE=i,this.buffer=new Uint8Array(e),this.view=yr(this.buffer)}update(e){mr(this),$t(e);const{view:r,buffer:n,blockLen:i}=this,s=e.length;for(let o=0;o<s;){const u=Math.min(i-this.pos,s-o);if(u===i){const l=yr(e);for(;i<=s-o;o+=i)this.process(l,o);continue}n.set(e.subarray(o,o+u),this.pos),this.pos+=u,o+=u,this.pos===i&&(this.process(r,0),this.pos=0)}return this.length+=e.length,this.roundClean(),this}digestInto(e){mr(this),Vf(e,this),this.finished=!0;const{buffer:r,view:n,blockLen:i,isLE:s}=this;let{pos:o}=this;r[o++]=128,jt(this.buffer.subarray(o)),this.padOffset>i-o&&(this.process(n,0),o=0);for(let h=o;h<i;h++)r[h]=0;n.setBigUint64(i-8,BigInt(this.length*8),s),this.process(n,0);const u=yr(e),l=this.outputLen;if(l%4)throw new Error("_sha2: outputLen must be aligned to 32bit");const c=l/4,a=this.get();if(c>a.length)throw new Error("_sha2: outputLen bigger than state");for(let h=0;h<c;h++)u.setUint32(4*h,a[h],s)}digest(){const{buffer:e,outputLen:r}=this;this.digestInto(e);const n=e.slice(0,r);return this.destroy(),n}_cloneInto(e){e||=new this.constructor,e.set(...this.get());const{blockLen:r,buffer:n,length:i,finished:s,destroyed:o,pos:u}=this;return e.destroyed=o,e.finished=s,e.length=i,e.pos=u,i%r&&e.buffer.set(n),e}clone(){return this._cloneInto()}}const he=Uint32Array.from([1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209]),br=BigInt(2**32-1),Ts=BigInt(32);function Yf(t,e=!1){return e?{h:Number(t&br),l:Number(t>>Ts&br)}:{h:Number(t>>Ts&br)|0,l:Number(t&br)|0}}function Zf(t,e=!1){const r=t.length;let n=new Uint32Array(r),i=new Uint32Array(r);for(let s=0;s<r;s++){const{h:o,l:u}=Yf(t[s],e);[n[s],i[s]]=[o,u]}return[n,i]}const As=(t,e,r)=>t>>>r,Ns=(t,e,r)=>t<<32-r|e>>>r,Et=(t,e,r)=>t>>>r|e<<32-r,vt=(t,e,r)=>t<<32-r|e>>>r,wr=(t,e,r)=>t<<64-r|e>>>r-32,xr=(t,e,r)=>t>>>r-32|e<<64-r;function He(t,e,r,n){const i=(e>>>0)+(n>>>0);return{h:t+r+(i/2**32|0)|0,l:i|0}}const Qf=(t,e,r)=>(t>>>0)+(e>>>0)+(r>>>0),eh=(t,e,r,n)=>e+r+n+(t/2**32|0)|0,th=(t,e,r,n)=>(t>>>0)+(e>>>0)+(r>>>0)+(n>>>0),rh=(t,e,r,n,i)=>e+r+n+i+(t/2**32|0)|0,nh=(t,e,r,n,i)=>(t>>>0)+(e>>>0)+(r>>>0)+(n>>>0)+(i>>>0),ih=(t,e,r,n,i,s)=>e+r+n+i+s+(t/2**32|0)|0,Ps=Zf(["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"].map(t=>BigInt(t))),sh=Ps[0],oh=Ps[1],Ge=new Uint32Array(80),Ke=new Uint32Array(80);class ah extends Xf{constructor(e){super(128,e,16,!1)}get(){const{Ah:e,Al:r,Bh:n,Bl:i,Ch:s,Cl:o,Dh:u,Dl:l,Eh:c,El:a,Fh:h,Fl:p,Gh:b,Gl:g,Hh:m,Hl:y}=this;return[e,r,n,i,s,o,u,l,c,a,h,p,b,g,m,y]}set(e,r,n,i,s,o,u,l,c,a,h,p,b,g,m,y){this.Ah=e|0,this.Al=r|0,this.Bh=n|0,this.Bl=i|0,this.Ch=s|0,this.Cl=o|0,this.Dh=u|0,this.Dl=l|0,this.Eh=c|0,this.El=a|0,this.Fh=h|0,this.Fl=p|0,this.Gh=b|0,this.Gl=g|0,this.Hh=m|0,this.Hl=y|0}process(e,r){for(let T=0;T<16;T++,r+=4)Ge[T]=e.getUint32(r),Ke[T]=e.getUint32(r+=4);for(let T=16;T<80;T++){const N=Ge[T-15]|0,S=Ke[T-15]|0,F=Et(N,S,1)^Et(N,S,8)^As(N,S,7),L=vt(N,S,1)^vt(N,S,8)^Ns(N,S,7),U=Ge[T-2]|0,_=Ke[T-2]|0,j=Et(U,_,19)^wr(U,_,61)^As(U,_,6),pe=vt(U,_,19)^xr(U,_,61)^Ns(U,_,6),oe=th(L,pe,Ke[T-7],Ke[T-16]),R=rh(oe,F,j,Ge[T-7],Ge[T-16]);Ge[T]=R|0,Ke[T]=oe|0}let{Ah:n,Al:i,Bh:s,Bl:o,Ch:u,Cl:l,Dh:c,Dl:a,Eh:h,El:p,Fh:b,Fl:g,Gh:m,Gl:y,Hh:v,Hl:E}=this;for(let T=0;T<80;T++){const N=Et(h,p,14)^Et(h,p,18)^wr(h,p,41),S=vt(h,p,14)^vt(h,p,18)^xr(h,p,41),F=h&b^~h&m,L=p&g^~p&y,U=nh(E,S,L,oh[T],Ke[T]),_=ih(U,v,N,F,sh[T],Ge[T]),j=U|0,pe=Et(n,i,28)^wr(n,i,34)^wr(n,i,39),oe=vt(n,i,28)^xr(n,i,34)^xr(n,i,39),R=n&s^n&u^s&u,le=i&o^i&l^o&l;v=m|0,E=y|0,m=b|0,y=g|0,b=h|0,g=p|0,{h,l:p}=He(c|0,a|0,_|0,j|0),c=u|0,a=l|0,u=s|0,l=o|0,s=n|0,o=i|0;const Pe=Qf(j,oe,le);n=eh(Pe,_,pe,R),i=Pe|0}({h:n,l:i}=He(this.Ah|0,this.Al|0,n|0,i|0)),{h:s,l:o}=He(this.Bh|0,this.Bl|0,s|0,o|0),{h:u,l}=He(this.Ch|0,this.Cl|0,u|0,l|0),{h:c,l:a}=He(this.Dh|0,this.Dl|0,c|0,a|0),{h,l:p}=He(this.Eh|0,this.El|0,h|0,p|0),{h:b,l:g}=He(this.Fh|0,this.Fl|0,b|0,g|0),{h:m,l:y}=He(this.Gh|0,this.Gl|0,m|0,y|0),{h:v,l:E}=He(this.Hh|0,this.Hl|0,v|0,E|0),this.set(n,i,s,o,u,l,c,a,h,p,b,g,m,y,v,E)}roundClean(){jt(Ge,Ke)}destroy(){jt(this.buffer),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}class uh extends ah{Ah=he[0]|0;Al=he[1]|0;Bh=he[2]|0;Bl=he[3]|0;Ch=he[4]|0;Cl=he[5]|0;Dh=he[6]|0;Dl=he[7]|0;Eh=he[8]|0;El=he[9]|0;Fh=he[10]|0;Fl=he[11]|0;Gh=he[12]|0;Gl=he[13]|0;Hh=he[14]|0;Hl=he[15]|0;constructor(){super(64)}}const lh=zf(()=>new uh,Wf(3)),ch=(t,e,r,n)=>si.from(Jf(lh,t,e,{c:r,dkLen:n})),Is=":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",fh=Is+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",hh="["+Is+"]["+fh+"]*",dh=new RegExp("^"+hh+"$");function Ss(t,e){const r=[];let n=e.exec(t);for(;n;){const i=[];i.startIndex=e.lastIndex-n[0].length;const s=n.length;for(let o=0;o<s;o++)i.push(n[o]);r.push(i),n=e.exec(t)}return r}const Er=function(t){const e=dh.exec(t);return!(e===null||typeof e>"u")};function ph(t){return typeof t<"u"}const gh={allowBooleanAttributes:!1,unpairedTags:[]};function mh(t,e){e=Object.assign({},gh,e);const r=[];let n=!1,i=!1;t[0]==="\uFEFF"&&(t=t.substr(1));for(let s=0;s<t.length;s++)if(t[s]==="<"&&t[s+1]==="?"){if(s+=2,s=Cs(t,s),s.err)return s}else if(t[s]==="<"){let o=s;if(s++,t[s]==="!"){s=Rs(t,s);continue}else{let u=!1;t[s]==="/"&&(u=!0,s++);let l="";for(;s<t.length&&t[s]!==">"&&t[s]!==" "&&t[s]!==" "&&t[s]!==`
7
- `&&t[s]!=="\r";s++)l+=t[s];if(l=l.trim(),l[l.length-1]==="/"&&(l=l.substring(0,l.length-1),s--),!Ah(l)){let h;return l.trim().length===0?h="Invalid space after '<'.":h="Tag '"+l+"' is an invalid name.",ee("InvalidTag",h,ge(t,s))}const c=wh(t,s);if(c===!1)return ee("InvalidAttr","Attributes for '"+l+"' have open quote.",ge(t,s));let a=c.value;if(s=c.index,a[a.length-1]==="/"){const h=s-a.length;a=a.substring(0,a.length-1);const p=Fs(a,e);if(p===!0)n=!0;else return ee(p.err.code,p.err.msg,ge(t,h+p.err.line))}else if(u)if(c.tagClosed){if(a.trim().length>0)return ee("InvalidTag","Closing tag '"+l+"' can't have attributes or invalid starting.",ge(t,o));if(r.length===0)return ee("InvalidTag","Closing tag '"+l+"' has not been opened.",ge(t,o));{const h=r.pop();if(l!==h.tagName){let p=ge(t,h.tagStartPos);return ee("InvalidTag","Expected closing tag '"+h.tagName+"' (opened in line "+p.line+", col "+p.col+") instead of closing tag '"+l+"'.",ge(t,o))}r.length==0&&(i=!0)}}else return ee("InvalidTag","Closing tag '"+l+"' doesn't have proper closing.",ge(t,s));else{const h=Fs(a,e);if(h!==!0)return ee(h.err.code,h.err.msg,ge(t,s-a.length+h.err.line));if(i===!0)return ee("InvalidXml","Multiple possible root nodes found.",ge(t,s));e.unpairedTags.indexOf(l)!==-1||r.push({tagName:l,tagStartPos:o}),n=!0}for(s++;s<t.length;s++)if(t[s]==="<")if(t[s+1]==="!"){s++,s=Rs(t,s);continue}else if(t[s+1]==="?"){if(s=Cs(t,++s),s.err)return s}else break;else if(t[s]==="&"){const h=vh(t,s);if(h==-1)return ee("InvalidChar","char '&' is not expected.",ge(t,s));s=h}else if(i===!0&&!Os(t[s]))return ee("InvalidXml","Extra text at the end",ge(t,s));t[s]==="<"&&s--}}else{if(Os(t[s]))continue;return ee("InvalidChar","char '"+t[s]+"' is not expected.",ge(t,s))}if(n){if(r.length==1)return ee("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",ge(t,r[0].tagStartPos));if(r.length>0)return ee("InvalidXml","Invalid '"+JSON.stringify(r.map(s=>s.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return ee("InvalidXml","Start tag expected.",1);return!0}function Os(t){return t===" "||t===" "||t===`
8
- `||t==="\r"}function Cs(t,e){const r=e;for(;e<t.length;e++)if(t[e]=="?"||t[e]==" "){const n=t.substr(r,e-r);if(e>5&&n==="xml")return ee("InvalidXml","XML declaration allowed only at the start of the document.",ge(t,e));if(t[e]=="?"&&t[e+1]==">"){e++;break}else continue}return e}function Rs(t,e){if(t.length>e+5&&t[e+1]==="-"&&t[e+2]==="-"){for(e+=3;e<t.length;e++)if(t[e]==="-"&&t[e+1]==="-"&&t[e+2]===">"){e+=2;break}}else if(t.length>e+8&&t[e+1]==="D"&&t[e+2]==="O"&&t[e+3]==="C"&&t[e+4]==="T"&&t[e+5]==="Y"&&t[e+6]==="P"&&t[e+7]==="E"){let r=1;for(e+=8;e<t.length;e++)if(t[e]==="<")r++;else if(t[e]===">"&&(r--,r===0))break}else if(t.length>e+9&&t[e+1]==="["&&t[e+2]==="C"&&t[e+3]==="D"&&t[e+4]==="A"&&t[e+5]==="T"&&t[e+6]==="A"&&t[e+7]==="["){for(e+=8;e<t.length;e++)if(t[e]==="]"&&t[e+1]==="]"&&t[e+2]===">"){e+=2;break}}return e}const yh='"',bh="'";function wh(t,e){let r="",n="",i=!1;for(;e<t.length;e++){if(t[e]===yh||t[e]===bh)n===""?n=t[e]:n!==t[e]||(n="");else if(t[e]===">"&&n===""){i=!0;break}r+=t[e]}return n!==""?!1:{value:r,index:e,tagClosed:i}}const xh=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function Fs(t,e){const r=Ss(t,xh),n={};for(let i=0;i<r.length;i++){if(r[i][1].length===0)return ee("InvalidAttr","Attribute '"+r[i][2]+"' has no space in starting.",Mt(r[i]));if(r[i][3]!==void 0&&r[i][4]===void 0)return ee("InvalidAttr","Attribute '"+r[i][2]+"' is without value.",Mt(r[i]));if(r[i][3]===void 0&&!e.allowBooleanAttributes)return ee("InvalidAttr","boolean attribute '"+r[i][2]+"' is not allowed.",Mt(r[i]));const s=r[i][2];if(!Th(s))return ee("InvalidAttr","Attribute '"+s+"' is an invalid name.",Mt(r[i]));if(!n.hasOwnProperty(s))n[s]=1;else return ee("InvalidAttr","Attribute '"+s+"' is repeated.",Mt(r[i]))}return!0}function Eh(t,e){let r=/\d/;for(t[e]==="x"&&(e++,r=/[\da-fA-F]/);e<t.length;e++){if(t[e]===";")return e;if(!t[e].match(r))break}return-1}function vh(t,e){if(e++,t[e]===";")return-1;if(t[e]==="#")return e++,Eh(t,e);let r=0;for(;e<t.length;e++,r++)if(!(t[e].match(/\w/)&&r<20)){if(t[e]===";")break;return-1}return e}function ee(t,e,r){return{err:{code:t,msg:e,line:r.line||r,col:r.col}}}function Th(t){return Er(t)}function Ah(t){return Er(t)}function ge(t,e){const r=t.substring(0,e).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}function Mt(t){return t.startIndex+t[1].length}const Nh={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(t,e){return e},attributeValueProcessor:function(t,e){return e},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(t,e,r){return t},captureMetaData:!1},Ph=function(t){return Object.assign({},Nh,t)};let vr;typeof Symbol!="function"?vr="@@xmlMetadata":vr=Symbol("XML Node Metadata");class at{constructor(e){this.tagname=e,this.child=[],this[":@"]={}}add(e,r){e==="__proto__"&&(e="#__proto__"),this.child.push({[e]:r})}addChild(e,r){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}),r!==void 0&&(this.child[this.child.length-1][vr]={startIndex:r})}static getMetaDataSymbol(){return vr}}class Ih{constructor(e){this.suppressValidationErr=!e}readDocType(e,r){const n={};if(e[r+3]==="O"&&e[r+4]==="C"&&e[r+5]==="T"&&e[r+6]==="Y"&&e[r+7]==="P"&&e[r+8]==="E"){r=r+9;let i=1,s=!1,o=!1,u="";for(;r<e.length;r++)if(e[r]==="<"&&!o){if(s&&ut(e,"!ENTITY",r)){r+=7;let l,c;if([l,c,r]=this.readEntityExp(e,r+1,this.suppressValidationErr),c.indexOf("&")===-1){const a=l.replace(/[.\-+*:]/g,"\\.");n[l]={regx:RegExp(`&${a};`,"g"),val:c}}}else if(s&&ut(e,"!ELEMENT",r)){r+=8;const{index:l}=this.readElementExp(e,r+1);r=l}else if(s&&ut(e,"!ATTLIST",r))r+=8;else if(s&&ut(e,"!NOTATION",r)){r+=9;const{index:l}=this.readNotationExp(e,r+1,this.suppressValidationErr);r=l}else if(ut(e,"!--",r))o=!0;else throw new Error("Invalid DOCTYPE");i++,u=""}else if(e[r]===">"){if(o?e[r-1]==="-"&&e[r-2]==="-"&&(o=!1,i--):i--,i===0)break}else e[r]==="["?s=!0:u+=e[r];if(i!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:n,i:r}}readEntityExp(e,r){r=ve(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r])&&e[r]!=='"'&&e[r]!=="'";)n+=e[r],r++;if(Dt(n),r=ve(e,r),!this.suppressValidationErr){if(e.substring(r,r+6).toUpperCase()==="SYSTEM")throw new Error("External entities are not supported");if(e[r]==="%")throw new Error("Parameter entities are not supported")}let i="";return[r,i]=this.readIdentifierVal(e,r,"entity"),r--,[n,i,r]}readNotationExp(e,r){r=ve(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r]);)n+=e[r],r++;!this.suppressValidationErr&&Dt(n),r=ve(e,r);const i=e.substring(r,r+6).toUpperCase();if(!this.suppressValidationErr&&i!=="SYSTEM"&&i!=="PUBLIC")throw new Error(`Expected SYSTEM or PUBLIC, found "${i}"`);r+=i.length,r=ve(e,r);let s=null,o=null;if(i==="PUBLIC")[r,s]=this.readIdentifierVal(e,r,"publicIdentifier"),r=ve(e,r),(e[r]==='"'||e[r]==="'")&&([r,o]=this.readIdentifierVal(e,r,"systemIdentifier"));else if(i==="SYSTEM"&&([r,o]=this.readIdentifierVal(e,r,"systemIdentifier"),!this.suppressValidationErr&&!o))throw new Error("Missing mandatory system identifier for SYSTEM notation");return{notationName:n,publicIdentifier:s,systemIdentifier:o,index:--r}}readIdentifierVal(e,r,n){let i="";const s=e[r];if(s!=='"'&&s!=="'")throw new Error(`Expected quoted string, found "${s}"`);for(r++;r<e.length&&e[r]!==s;)i+=e[r],r++;if(e[r]!==s)throw new Error(`Unterminated ${n} value`);return r++,[r,i]}readElementExp(e,r){r=ve(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r]);)n+=e[r],r++;if(!this.suppressValidationErr&&!Er(n))throw new Error(`Invalid element name: "${n}"`);r=ve(e,r);let i="";if(e[r]==="E"&&ut(e,"MPTY",r))r+=4;else if(e[r]==="A"&&ut(e,"NY",r))r+=2;else if(e[r]==="("){for(r++;r<e.length&&e[r]!==")";)i+=e[r],r++;if(e[r]!==")")throw new Error("Unterminated content model")}else if(!this.suppressValidationErr)throw new Error(`Invalid Element Expression, found "${e[r]}"`);return{elementName:n,contentModel:i.trim(),index:r}}readAttlistExp(e,r){r=ve(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r]);)n+=e[r],r++;Dt(n),r=ve(e,r);let i="";for(;r<e.length&&!/\s/.test(e[r]);)i+=e[r],r++;if(!Dt(i))throw new Error(`Invalid attribute name: "${i}"`);r=ve(e,r);let s="";if(e.substring(r,r+8).toUpperCase()==="NOTATION"){if(s="NOTATION",r+=8,r=ve(e,r),e[r]!=="(")throw new Error(`Expected '(', found "${e[r]}"`);r++;let u=[];for(;r<e.length&&e[r]!==")";){let l="";for(;r<e.length&&e[r]!=="|"&&e[r]!==")";)l+=e[r],r++;if(l=l.trim(),!Dt(l))throw new Error(`Invalid notation name: "${l}"`);u.push(l),e[r]==="|"&&(r++,r=ve(e,r))}if(e[r]!==")")throw new Error("Unterminated list of notations");r++,s+=" ("+u.join("|")+")"}else{for(;r<e.length&&!/\s/.test(e[r]);)s+=e[r],r++;const u=["CDATA","ID","IDREF","IDREFS","ENTITY","ENTITIES","NMTOKEN","NMTOKENS"];if(!this.suppressValidationErr&&!u.includes(s.toUpperCase()))throw new Error(`Invalid attribute type: "${s}"`)}r=ve(e,r);let o="";return e.substring(r,r+8).toUpperCase()==="#REQUIRED"?(o="#REQUIRED",r+=8):e.substring(r,r+7).toUpperCase()==="#IMPLIED"?(o="#IMPLIED",r+=7):[r,o]=this.readIdentifierVal(e,r,"ATTLIST"),{elementName:n,attributeName:i,attributeType:s,defaultValue:o,index:r}}}const ve=(t,e)=>{for(;e<t.length&&/\s/.test(t[e]);)e++;return e};function ut(t,e,r){for(let n=0;n<e.length;n++)if(e[n]!==t[r+n+1])return!1;return!0}function Dt(t){if(Er(t))return t;throw new Error(`Invalid entity name ${t}`)}const Sh=/^[-+]?0x[a-fA-F0-9]+$/,Oh=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,Ch={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};function Rh(t,e={}){if(e=Object.assign({},Ch,e),!t||typeof t!="string")return t;let r=t.trim();if(e.skipLike!==void 0&&e.skipLike.test(r))return t;if(t==="0")return 0;if(e.hex&&Sh.test(r))return Uh(r,16);if(r.includes("e")||r.includes("E"))return Lh(t,r,e);{const n=Oh.exec(r);if(n){const i=n[1]||"",s=n[2];let o=_h(n[3]);const u=i?t[s.length+1]===".":t[s.length]===".";if(!e.leadingZeros&&(s.length>1||s.length===1&&!u))return t;{const l=Number(r),c=String(l);if(l===0)return l;if(c.search(/[eE]/)!==-1)return e.eNotation?l:t;if(r.indexOf(".")!==-1)return c==="0"||c===o||c===`${i}${o}`?l:t;let a=s?o:r;return s?a===c||i+a===c?l:t:a===c||a===i+c?l:t}}else return t}}const Fh=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function Lh(t,e,r){if(!r.eNotation)return t;const n=e.match(Fh);if(n){let i=n[1]||"";const s=n[3].indexOf("e")===-1?"E":"e",o=n[2],u=i?t[o.length+1]===s:t[o.length]===s;return o.length>1&&u?t:o.length===1&&(n[3].startsWith(`.${s}`)||n[3][0]===s)?Number(e):r.leadingZeros&&!u?(e=(n[1]||"")+n[3],Number(e)):t}else return t}function _h(t){return t&&t.indexOf(".")!==-1&&(t=t.replace(/0+$/,""),t==="."?t="0":t[0]==="."?t="0"+t:t[t.length-1]==="."&&(t=t.substring(0,t.length-1))),t}function Uh(t,e){if(parseInt)return parseInt(t,e);if(Number.parseInt)return Number.parseInt(t,e);if(window&&window.parseInt)return window.parseInt(t,e);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")}function Ls(t){return typeof t=="function"?t:Array.isArray(t)?e=>{for(const r of t)if(typeof r=="string"&&e===r||r instanceof RegExp&&r.test(e))return!0}:()=>!1}class Bh{constructor(e){if(this.options=e,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(r,n)=>_s(n,10,"&#")},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(r,n)=>_s(n,16,"&#x")}},this.addExternalEntities=kh,this.parseXml=Vh,this.parseTextData=$h,this.resolveNameSpace=jh,this.buildAttributesMap=Dh,this.isItStopNode=Wh,this.replaceEntitiesValue=qh,this.readStopNodeData=Kh,this.saveTextToParentTag=zh,this.addChild=Hh,this.ignoreAttributesFn=Ls(this.options.ignoreAttributes),this.options.stopNodes&&this.options.stopNodes.length>0){this.stopNodesExact=new Set,this.stopNodesWildcard=new Set;for(let r=0;r<this.options.stopNodes.length;r++){const n=this.options.stopNodes[r];typeof n=="string"&&(n.startsWith("*.")?this.stopNodesWildcard.add(n.substring(2)):this.stopNodesExact.add(n))}}}}function kh(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r],i=n.replace(/[.\-+*:]/g,"\\.");this.lastEntities[n]={regex:new RegExp("&"+i+";","g"),val:t[n]}}}function $h(t,e,r,n,i,s,o){if(t!==void 0&&(this.options.trimValues&&!n&&(t=t.trim()),t.length>0)){o||(t=this.replaceEntitiesValue(t));const u=this.options.tagValueProcessor(e,t,r,i,s);return u==null?t:typeof u!=typeof t||u!==t?u:this.options.trimValues?hn(t,this.options.parseTagValue,this.options.numberParseOptions):t.trim()===t?hn(t,this.options.parseTagValue,this.options.numberParseOptions):t}}function jh(t){if(this.options.removeNSPrefix){const e=t.split(":"),r=t.charAt(0)==="/"?"/":"";if(e[0]==="xmlns")return"";e.length===2&&(t=r+e[1])}return t}const Mh=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function Dh(t,e){if(this.options.ignoreAttributes!==!0&&typeof t=="string"){const r=Ss(t,Mh),n=r.length,i={};for(let s=0;s<n;s++){const o=this.resolveNameSpace(r[s][1]);if(this.ignoreAttributesFn(o,e))continue;let u=r[s][4],l=this.options.attributeNamePrefix+o;if(o.length)if(this.options.transformAttributeName&&(l=this.options.transformAttributeName(l)),l==="__proto__"&&(l="#__proto__"),u!==void 0){this.options.trimValues&&(u=u.trim()),u=this.replaceEntitiesValue(u);const c=this.options.attributeValueProcessor(o,u,e);c==null?i[l]=u:typeof c!=typeof u||c!==u?i[l]=c:i[l]=hn(u,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(i[l]=!0)}if(!Object.keys(i).length)return;if(this.options.attributesGroupName){const s={};return s[this.options.attributesGroupName]=i,s}return i}}const Vh=function(t){t=t.replace(/\r\n?/g,`
9
- `);const e=new at("!xml");let r=e,n="",i="";const s=new Ih(this.options.processEntities);for(let o=0;o<t.length;o++)if(t[o]==="<")if(t[o+1]==="/"){const l=lt(t,">",o,"Closing Tag is not closed.");let c=t.substring(o+2,l).trim();if(this.options.removeNSPrefix){const p=c.indexOf(":");p!==-1&&(c=c.substr(p+1))}this.options.transformTagName&&(c=this.options.transformTagName(c)),r&&(n=this.saveTextToParentTag(n,r,i));const a=i.substring(i.lastIndexOf(".")+1);if(c&&this.options.unpairedTags.indexOf(c)!==-1)throw new Error(`Unpaired tag can not be used as closing tag: </${c}>`);let h=0;a&&this.options.unpairedTags.indexOf(a)!==-1?(h=i.lastIndexOf(".",i.lastIndexOf(".")-1),this.tagsNodeStack.pop()):h=i.lastIndexOf("."),i=i.substring(0,h),r=this.tagsNodeStack.pop(),n="",o=l}else if(t[o+1]==="?"){let l=fn(t,o,!1,"?>");if(!l)throw new Error("Pi Tag is not closed.");if(n=this.saveTextToParentTag(n,r,i),!(this.options.ignoreDeclaration&&l.tagName==="?xml"||this.options.ignorePiTags)){const c=new at(l.tagName);c.add(this.options.textNodeName,""),l.tagName!==l.tagExp&&l.attrExpPresent&&(c[":@"]=this.buildAttributesMap(l.tagExp,i)),this.addChild(r,c,i,o)}o=l.closeIndex+1}else if(t.substr(o+1,3)==="!--"){const l=lt(t,"-->",o+4,"Comment is not closed.");if(this.options.commentPropName){const c=t.substring(o+4,l-2);n=this.saveTextToParentTag(n,r,i),r.add(this.options.commentPropName,[{[this.options.textNodeName]:c}])}o=l}else if(t.substr(o+1,2)==="!D"){const l=s.readDocType(t,o);this.docTypeEntities=l.entities,o=l.i}else if(t.substr(o+1,2)==="!["){const l=lt(t,"]]>",o,"CDATA is not closed.")-2,c=t.substring(o+9,l);n=this.saveTextToParentTag(n,r,i);let a=this.parseTextData(c,r.tagname,i,!0,!1,!0,!0);a==null&&(a=""),this.options.cdataPropName?r.add(this.options.cdataPropName,[{[this.options.textNodeName]:c}]):r.add(this.options.textNodeName,a),o=l+2}else{let l=fn(t,o,this.options.removeNSPrefix),c=l.tagName;const a=l.rawTagName;let h=l.tagExp,p=l.attrExpPresent,b=l.closeIndex;if(this.options.transformTagName){const y=this.options.transformTagName(c);h===c&&(h=y),c=y}r&&n&&r.tagname!=="!xml"&&(n=this.saveTextToParentTag(n,r,i,!1));const g=r;g&&this.options.unpairedTags.indexOf(g.tagname)!==-1&&(r=this.tagsNodeStack.pop(),i=i.substring(0,i.lastIndexOf("."))),c!==e.tagname&&(i+=i?"."+c:c);const m=o;if(this.isItStopNode(this.stopNodesExact,this.stopNodesWildcard,i,c)){let y="";if(h.length>0&&h.lastIndexOf("/")===h.length-1)c[c.length-1]==="/"?(c=c.substr(0,c.length-1),i=i.substr(0,i.length-1),h=c):h=h.substr(0,h.length-1),o=l.closeIndex;else if(this.options.unpairedTags.indexOf(c)!==-1)o=l.closeIndex;else{const E=this.readStopNodeData(t,a,b+1);if(!E)throw new Error(`Unexpected end of ${a}`);o=E.i,y=E.tagContent}const v=new at(c);c!==h&&p&&(v[":@"]=this.buildAttributesMap(h,i)),y&&(y=this.parseTextData(y,c,i,!0,p,!0,!0)),i=i.substr(0,i.lastIndexOf(".")),v.add(this.options.textNodeName,y),this.addChild(r,v,i,m)}else{if(h.length>0&&h.lastIndexOf("/")===h.length-1){if(c[c.length-1]==="/"?(c=c.substr(0,c.length-1),i=i.substr(0,i.length-1),h=c):h=h.substr(0,h.length-1),this.options.transformTagName){const v=this.options.transformTagName(c);h===c&&(h=v),c=v}const y=new at(c);c!==h&&p&&(y[":@"]=this.buildAttributesMap(h,i)),this.addChild(r,y,i,m),i=i.substr(0,i.lastIndexOf("."))}else{const y=new at(c);this.tagsNodeStack.push(r),c!==h&&p&&(y[":@"]=this.buildAttributesMap(h,i)),this.addChild(r,y,i,m),r=y}n="",o=b}}else n+=t[o];return e.child};function Hh(t,e,r,n){this.options.captureMetaData||(n=void 0);const i=this.options.updateTag(e.tagname,r,e[":@"]);i===!1||(typeof i=="string"&&(e.tagname=i),t.addChild(e,n))}const qh=function(t){if(this.options.processEntities){for(let e in this.docTypeEntities){const r=this.docTypeEntities[e];t=t.replace(r.regx,r.val)}for(let e in this.lastEntities){const r=this.lastEntities[e];t=t.replace(r.regex,r.val)}if(this.options.htmlEntities)for(let e in this.htmlEntities){const r=this.htmlEntities[e];t=t.replace(r.regex,r.val)}t=t.replace(this.ampEntity.regex,this.ampEntity.val)}return t};function zh(t,e,r,n){return t&&(n===void 0&&(n=e.child.length===0),t=this.parseTextData(t,e.tagname,r,!1,e[":@"]?Object.keys(e[":@"]).length!==0:!1,n),t!==void 0&&t!==""&&e.add(this.options.textNodeName,t),t=""),t}function Wh(t,e,r,n){return!!(e&&e.has(n)||t&&t.has(r))}function Gh(t,e,r=">"){let n,i="";for(let s=e;s<t.length;s++){let o=t[s];if(n)o===n&&(n="");else if(o==='"'||o==="'")n=o;else if(o===r[0])if(r[1]){if(t[s+1]===r[1])return{data:i,index:s}}else return{data:i,index:s};else o===" "&&(o=" ");i+=o}}function lt(t,e,r,n){const i=t.indexOf(e,r);if(i===-1)throw new Error(n);return i+e.length-1}function fn(t,e,r,n=">"){const i=Gh(t,e+1,n);if(!i)return;let s=i.data;const o=i.index,u=s.search(/\s/);let l=s,c=!0;u!==-1&&(l=s.substring(0,u),s=s.substring(u+1).trimStart());const a=l;if(r){const h=l.indexOf(":");h!==-1&&(l=l.substr(h+1),c=l!==i.data.substr(h+1))}return{tagName:l,tagExp:s,closeIndex:o,attrExpPresent:c,rawTagName:a}}function Kh(t,e,r){const n=r;let i=1;for(;r<t.length;r++)if(t[r]==="<")if(t[r+1]==="/"){const s=lt(t,">",r,`${e} is not closed`);if(t.substring(r+2,s).trim()===e&&(i--,i===0))return{tagContent:t.substring(n,r),i:s};r=s}else if(t[r+1]==="?")r=lt(t,"?>",r+1,"StopNode is not closed.");else if(t.substr(r+1,3)==="!--")r=lt(t,"-->",r+3,"StopNode is not closed.");else if(t.substr(r+1,2)==="![")r=lt(t,"]]>",r,"StopNode is not closed.")-2;else{const s=fn(t,r,">");s&&((s&&s.tagName)===e&&s.tagExp[s.tagExp.length-1]!=="/"&&i++,r=s.closeIndex)}}function hn(t,e,r){if(e&&typeof t=="string"){const n=t.trim();return n==="true"?!0:n==="false"?!1:Rh(t,r)}else return ph(t)?t:""}function _s(t,e,r){const n=Number.parseInt(t,e);return n>=0&&n<=1114111?String.fromCodePoint(n):r+t+";"}const dn=at.getMetaDataSymbol();function Jh(t,e){return Us(t,e)}function Us(t,e,r){let n;const i={};for(let s=0;s<t.length;s++){const o=t[s],u=Xh(o);let l="";if(r===void 0?l=u:l=r+"."+u,u===e.textNodeName)n===void 0?n=o[u]:n+=""+o[u];else{if(u===void 0)continue;if(o[u]){let c=Us(o[u],e,l);const a=Zh(c,e);o[dn]!==void 0&&(c[dn]=o[dn]),o[":@"]?Yh(c,o[":@"],l,e):Object.keys(c).length===1&&c[e.textNodeName]!==void 0&&!e.alwaysCreateTextNode?c=c[e.textNodeName]:Object.keys(c).length===0&&(e.alwaysCreateTextNode?c[e.textNodeName]="":c=""),i[u]!==void 0&&i.hasOwnProperty(u)?(Array.isArray(i[u])||(i[u]=[i[u]]),i[u].push(c)):e.isArray(u,l,a)?i[u]=[c]:i[u]=c}}}return typeof n=="string"?n.length>0&&(i[e.textNodeName]=n):n!==void 0&&(i[e.textNodeName]=n),i}function Xh(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r];if(n!==":@")return n}}function Yh(t,e,r,n){if(e){const i=Object.keys(e),s=i.length;for(let o=0;o<s;o++){const u=i[o];n.isArray(u,r+"."+u,!0,!0)?t[u]=[e[u]]:t[u]=e[u]}}}function Zh(t,e){const{textNodeName:r}=e,n=Object.keys(t).length;return!!(n===0||n===1&&(t[r]||typeof t[r]=="boolean"||t[r]===0))}class Bs{constructor(e){this.externalEntities={},this.options=Ph(e)}parse(e,r){if(typeof e!="string"&&e.toString)e=e.toString();else if(typeof e!="string")throw new Error("XML data is accepted in String or Bytes[] form.");if(r){r===!0&&(r={});const s=mh(e,r);if(s!==!0)throw Error(`${s.err.msg}:${s.err.line}:${s.err.col}`)}const n=new Bh(this.options);n.addExternalEntities(this.externalEntities);const i=n.parseXml(e);return this.options.preserveOrder||i===void 0?i:Jh(i,this.options)}addEntity(e,r){if(r.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(e.indexOf("&")!==-1||e.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '&#xD;'");if(r==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[e]=r}static getMetaDataSymbol(){return at.getMetaDataSymbol()}}const Qh=`
10
- `;function ed(t,e){let r="";return e.format&&e.indentBy.length>0&&(r=Qh),ks(t,e,"",r)}function ks(t,e,r,n){let i="",s=!1;for(let o=0;o<t.length;o++){const u=t[o],l=td(u);if(l===void 0)continue;let c="";if(r.length===0?c=l:c=`${r}.${l}`,l===e.textNodeName){let g=u[l];rd(c,e)||(g=e.tagValueProcessor(l,g),g=js(g,e)),s&&(i+=n),i+=g,s=!1;continue}else if(l===e.cdataPropName){s&&(i+=n),i+=`<![CDATA[${u[l][0][e.textNodeName]}]]>`,s=!1;continue}else if(l===e.commentPropName){i+=n+`<!--${u[l][0][e.textNodeName]}-->`,s=!0;continue}else if(l[0]==="?"){const g=$s(u[":@"],e),m=l==="?xml"?"":n;let y=u[l][0][e.textNodeName];y=y.length!==0?" "+y:"",i+=m+`<${l}${y}${g}?>`,s=!0;continue}let a=n;a!==""&&(a+=e.indentBy);const h=$s(u[":@"],e),p=n+`<${l}${h}`,b=ks(u[l],e,c,a);e.unpairedTags.indexOf(l)!==-1?e.suppressUnpairedNode?i+=p+">":i+=p+"/>":(!b||b.length===0)&&e.suppressEmptyNode?i+=p+"/>":b&&b.endsWith(">")?i+=p+`>${b}${n}</${l}>`:(i+=p+">",b&&n!==""&&(b.includes("/>")||b.includes("</"))?i+=n+e.indentBy+b+n:i+=b,i+=`</${l}>`),s=!0}return i}function td(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r];if(t.hasOwnProperty(n)&&n!==":@")return n}}function $s(t,e){let r="";if(t&&!e.ignoreAttributes)for(let n in t){if(!t.hasOwnProperty(n))continue;let i=e.attributeValueProcessor(n,t[n]);i=js(i,e),i===!0&&e.suppressBooleanAttributes?r+=` ${n.substr(e.attributeNamePrefix.length)}`:r+=` ${n.substr(e.attributeNamePrefix.length)}="${i}"`}return r}function rd(t,e){t=t.substr(0,t.length-e.textNodeName.length-1);let r=t.substr(t.lastIndexOf(".")+1);for(let n in e.stopNodes)if(e.stopNodes[n]===t||e.stopNodes[n]==="*."+r)return!0;return!1}function js(t,e){if(t&&t.length>0&&e.processEntities)for(let r=0;r<e.entities.length;r++){const n=e.entities[r];t=t.replace(n.regex,n.val)}return t}const nd={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1};function qe(t){this.options=Object.assign({},nd,t),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=Ls(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=od),this.processTextOrObjNode=id,this.options.format?(this.indentate=sd,this.tagEndChar=`>
11
- `,this.newLine=`
12
- `):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}qe.prototype.build=function(t){return this.options.preserveOrder?ed(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t}),this.j2x(t,0,[]).val)},qe.prototype.j2x=function(t,e,r){let n="",i="";const s=r.join(".");for(let o in t)if(Object.prototype.hasOwnProperty.call(t,o))if(typeof t[o]>"u")this.isAttribute(o)&&(i+="");else if(t[o]===null)this.isAttribute(o)||o===this.options.cdataPropName?i+="":o[0]==="?"?i+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if(t[o]instanceof Date)i+=this.buildTextValNode(t[o],o,"",e);else if(typeof t[o]!="object"){const u=this.isAttribute(o);if(u&&!this.ignoreAttributesFn(u,s))n+=this.buildAttrPairStr(u,""+t[o]);else if(!u)if(o===this.options.textNodeName){let l=this.options.tagValueProcessor(o,""+t[o]);i+=this.replaceEntitiesValue(l)}else i+=this.buildTextValNode(t[o],o,"",e)}else if(Array.isArray(t[o])){const u=t[o].length;let l="",c="";for(let a=0;a<u;a++){const h=t[o][a];if(!(typeof h>"u"))if(h===null)o[0]==="?"?i+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if(typeof h=="object")if(this.options.oneListGroup){const p=this.j2x(h,e+1,r.concat(o));l+=p.val,this.options.attributesGroupName&&h.hasOwnProperty(this.options.attributesGroupName)&&(c+=p.attrStr)}else l+=this.processTextOrObjNode(h,o,e,r);else if(this.options.oneListGroup){let p=this.options.tagValueProcessor(o,h);p=this.replaceEntitiesValue(p),l+=p}else l+=this.buildTextValNode(h,o,"",e)}this.options.oneListGroup&&(l=this.buildObjectNode(l,o,c,e)),i+=l}else if(this.options.attributesGroupName&&o===this.options.attributesGroupName){const u=Object.keys(t[o]),l=u.length;for(let c=0;c<l;c++)n+=this.buildAttrPairStr(u[c],""+t[o][u[c]])}else i+=this.processTextOrObjNode(t[o],o,e,r);return{attrStr:n,val:i}},qe.prototype.buildAttrPairStr=function(t,e){return e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e),this.options.suppressBooleanAttributes&&e==="true"?" "+t:" "+t+'="'+e+'"'};function id(t,e,r,n){const i=this.j2x(t,r+1,n.concat(e));return t[this.options.textNodeName]!==void 0&&Object.keys(t).length===1?this.buildTextValNode(t[this.options.textNodeName],e,i.attrStr,r):this.buildObjectNode(i.val,e,i.attrStr,r)}qe.prototype.buildObjectNode=function(t,e,r,n){if(t==="")return e[0]==="?"?this.indentate(n)+"<"+e+r+"?"+this.tagEndChar:this.indentate(n)+"<"+e+r+this.closeTag(e)+this.tagEndChar;{let i="</"+e+this.tagEndChar,s="";return e[0]==="?"&&(s="?",i=""),(r||r==="")&&t.indexOf("<")===-1?this.indentate(n)+"<"+e+r+s+">"+t+i:this.options.commentPropName!==!1&&e===this.options.commentPropName&&s.length===0?this.indentate(n)+`<!--${t}-->`+this.newLine:this.indentate(n)+"<"+e+r+s+this.tagEndChar+t+this.indentate(n)+i}},qe.prototype.closeTag=function(t){let e="";return this.options.unpairedTags.indexOf(t)!==-1?this.options.suppressUnpairedNode||(e="/"):this.options.suppressEmptyNode?e="/":e=`></${t}`,e},qe.prototype.buildTextValNode=function(t,e,r,n){if(this.options.cdataPropName!==!1&&e===this.options.cdataPropName)return this.indentate(n)+`<![CDATA[${t}]]>`+this.newLine;if(this.options.commentPropName!==!1&&e===this.options.commentPropName)return this.indentate(n)+`<!--${t}-->`+this.newLine;if(e[0]==="?")return this.indentate(n)+"<"+e+r+"?"+this.tagEndChar;{let i=this.options.tagValueProcessor(e,t);return i=this.replaceEntitiesValue(i),i===""?this.indentate(n)+"<"+e+r+this.closeTag(e)+this.tagEndChar:this.indentate(n)+"<"+e+r+">"+i+"</"+e+this.tagEndChar}},qe.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(let e=0;e<this.options.entities.length;e++){const r=this.options.entities[e];t=t.replace(r.regex,r.val)}return t};function sd(t){return this.options.indentBy.repeat(t)}function od(t){return t.startsWith(this.options.attributeNamePrefix)&&t!==this.options.textNodeName?t.substr(this.attrPrefixLen):!1}class ad{axiosClient;baseURI;xmlParser;signingKey;ALGORITHM="sha512";TTL=1200;HASH_LENGTH=32;ITERATION_COUNT=1e4;constructor({axiosClient:e,baseURI:r}){this.axiosClient=e,this.baseURI=r,this.xmlParser=new Bs}async signUrl(e,r){const n=new URL(e);n.searchParams.set("OC-Credential",r),n.searchParams.set("OC-Date",new Date().toISOString()),n.searchParams.set("OC-Expires",this.TTL.toString()),n.searchParams.set("OC-Verb","GET");const i=await this.createHashedKey(n.toString());return n.searchParams.set("OC-Algo",`PBKDF2/${this.ITERATION_COUNT}-SHA512`),n.searchParams.set("OC-Signature",i),n.toString()}async getSignKey(){if(this.signingKey)return this.signingKey;const e=await this.axiosClient.get($(this.baseURI,"ocs/v1.php/cloud/user/signing-key"),{headers:{"Content-Type":"application/x-www-form-urlencoded"}}),r=this.xmlParser.parse(e.data);return this.signingKey=r.ocs.data["signing-key"],this.signingKey}async createHashedKey(e){const r=await this.getSignKey();return ch(e,r,this.ITERATION_COUNT,this.HASH_LENGTH,this.ALGORITHM).toString("hex")}}const ud=(t,e)=>{const r=new URL(t);r.pathname=[...r.pathname.split("/"),"ocs","v1.php"].filter(Boolean).join("/");const n=r.href,i=Mf(n,e),s=new ad({baseURI:t,axiosClient:e});return{getCapabilities:()=>i.getCapabilities(),signUrl:(o,u)=>s.signUrl(o,u)}},ze=(t,{fileId:e,path:r,name:n})=>{if(r!==void 0)return $(t.webDavPath,r);if(e!==void 0){if(ln(t))throw new Error("public spaces need a path provided");return $("spaces",e,n||"")}return t.webDavPath},ld=(t,e)=>({copyFiles(r,{path:n,fileId:i},s,{path:o,parentFolderId:u,name:l},{overwrite:c,...a}={}){const h=ze(r,{fileId:i,path:n}),p=ze(s,{fileId:u,path:o,name:l});return t.copy(h,p,{overwrite:c||!1,...a})}}),cd=(t,e,r)=>({async createFolder(n,{path:i,parentFolderId:s,folderName:o,fetchFolder:u=!0,...l}){const c=ze(n,{fileId:s,path:i,name:o});if(await t.mkcol(c),u)return e.getFileInfo(n,{path:i},l)}}),fd=(t,{axiosClient:e})=>({async getFileContents(r,{fileId:n,path:i},{responseType:s="text",noCache:o=!0,headers:u,...l}={}){try{const c=ze(r,{fileId:n,path:i}),a=await e.get(t.getFileUrl(c),{responseType:s,headers:{...o&&{"Cache-Control":"no-cache"},...u||{}},...l});return{response:a,body:a.data,headers:{ETag:a.headers.etag,"OC-ETag":a.headers["oc-etag"],"OC-FileId":a.headers["oc-fileid"]}}}catch(c){const{message:a,response:h}=c;throw new Li(a,h,h.status)}}}),hd=(t,e)=>({async getFileInfo(r,n,i){return(await t.listFiles(r,n,{depth:0,...i})).resource}}),dd=(t,e,r,{axiosClient:n,baseUrl:i})=>({async getFileUrl(s,o,{disposition:u="attachment",version:l=null,username:c="",...a}){if(u==="inline"){const p=await e.getFileContents(s,o,{responseType:"blob",...a});return URL.createObjectURL(p.body)}if(l){if(!c)throw new Error("username is required for URL signing");const p=t.getFileUrl($("meta",o.fileId,"v",l));return await ud(i,n).signUrl(p,c)}if(o.downloadURL)return o.downloadURL;const{downloadURL:h}=await r.getFileInfo(s,o,{davProperties:[C.DownloadURL]});return h},revokeUrl:s=>{s&&s.startsWith("blob:")&&URL.revokeObjectURL(s)}}),pd=(t,e)=>({getPublicFileUrl(r,n){return t.getFileUrl($("public-files",n))}}),gd=(t,e,r)=>({async listFiles(n,{path:i,fileId:s}={},{depth:o=1,davProperties:u,isTrash:l=!1,...c}={}){let a;if(ln(n)){a=await t.propfind($(n.webDavPath,i),{depth:o,properties:u||it.PublicLink,...c}),a.forEach(g=>{g.filename=g.filename.split("/").slice(1).join("/")}),a.length===1&&(a[0].filename=$(n.id,i,{leadingSlash:!0})),a.forEach(g=>{g.filename=g.filename.split("/").slice(2).join("/")});const p=n.driveAlias.startsWith("ocm/")?"ocm":"public-link";if((!i||i==="/")&&o>0&&p==="ocm"&&a[0].props[C.PublicLinkItemType]==="file"&&(a=[{basename:n.fileId,type:"directory",filename:"",props:{}},...a]),!i){const[g,...m]=a;return{resource:$f({...g,id:n.id,driveAlias:n.driveAlias,webDavPath:n.webDavPath,publicLinkType:p}),children:m.map(y=>xt(y,t.extraProps))}}const b=a.map(g=>xt(g,t.extraProps));return{resource:b[0],children:b.slice(1)}}const h=async()=>{const p=await e.getPathForFileId(s);return this.listFiles(n,{path:p},{depth:o,davProperties:u})};try{let p="";if(l?p=cn(n.id):p=ze(n,{fileId:s,path:i}),a=await t.propfind(p,{depth:o,properties:u||it.Default,...c}),l)return{resource:xt(a[0],t.extraProps),children:a.slice(1).map(Bf)};const b=a.map(m=>xt(m,t.extraProps)),g=s===n.id;return s&&!g&&b[0].fileId&&s!==b[0].fileId?h():{resource:b[0],children:b.slice(1)}}catch(p){if(p.statusCode===404&&s)return h();throw p}}}),md=(t,e)=>({moveFiles(r,{path:n,fileId:i},s,{path:o,parentFolderId:u,name:l},{overwrite:c,...a}={}){const h=ze(r,{fileId:i,path:n}),p=ze(s,{fileId:u,path:o,name:l});return t.move(h,p,{overwrite:c||!1,...a})}}),yd=(t,e,r)=>({async putFileContents(n,{fileName:i,path:s,parentFolderId:o,content:u="",previousEntityTag:l="",overwrite:c,onUploadProgress:a=null,...h}){const p=ze(n,{fileId:o,name:i,path:s}),{result:b}=await t.put(p,u,{previousEntityTag:l,overwrite:c,onUploadProgress:a,...h});return e.getFileInfo(n,{fileId:b.headers.get("Oc-Fileid"),path:s})}}),bd=(t,e)=>({deleteFile(r,{path:n,...i}){return t.delete($(r.webDavPath,n),i)}}),wd=(t,e)=>({restoreFile(r,{id:n},{path:i},{overwrite:s,...o}={}){if(ln(r))return;const u=$(r.webDavPath,i);return t.move($(r.webDavTrashPath,n),u,{overwrite:s,...o})}}),xd=(t,e)=>({restoreFileVersion(r,{parentFolderId:n,name:i,path:s},o,u={}){const l=ze(r,{path:s,fileId:n,name:i}),c=$("meta",n,"v",o,{leadingSlash:!0}),a=$("files",l,{leadingSlash:!0});return t.copy(c,a,u)}}),Ed=(t,e)=>({clearTrashBin(r,{id:n,...i}={}){let s=cn(r.id);return n&&(s=$(s,n)),t.delete(s,i)}}),vd=(t,e)=>({async search(r,{davProperties:n=it.Default,searchLimit:i,...s}){const o="/spaces/",{range:u,results:l}=await t.report(o,{pattern:r,limit:i,properties:n,...s});return{resources:l.map(c=>({...xt(c,t.extraProps),highlights:c.props[C.Highlights]||""})),totalResults:u?parseInt(u?.split("/")[1]):null}}}),Td=(t,e)=>({async getPathForFileId(r,n={}){return(await t.propfind($("meta",r,{leadingSlash:!0}),{properties:[C.MetaPathForUser],...n}))[0].props[C.MetaPathForUser]}});var Ad={2:t=>{function e(i,s,o){i instanceof RegExp&&(i=r(i,o)),s instanceof RegExp&&(s=r(s,o));var u=n(i,s,o);return u&&{start:u[0],end:u[1],pre:o.slice(0,u[0]),body:o.slice(u[0]+i.length,u[1]),post:o.slice(u[1]+s.length)}}function r(i,s){var o=s.match(i);return o?o[0]:null}function n(i,s,o){var u,l,c,a,h,p=o.indexOf(i),b=o.indexOf(s,p+1),g=p;if(p>=0&&b>0){for(u=[],c=o.length;g>=0&&!h;)g==p?(u.push(g),p=o.indexOf(i,g+1)):u.length==1?h=[u.pop(),b]:((l=u.pop())<c&&(c=l,a=b),b=o.indexOf(s,g+1)),g=p<b&&p>=0?p:b;u.length&&(h=[c,a])}return h}t.exports=e,e.range=n},47:(t,e,r)=>{var n=r(410),i=function(c){return typeof c=="string"};function s(c,a){for(var h=[],p=0;p<c.length;p++){var b=c[p];b&&b!=="."&&(b===".."?h.length&&h[h.length-1]!==".."?h.pop():a&&h.push(".."):h.push(b))}return h}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,u={};function l(c){return o.exec(c).slice(1)}u.resolve=function(){for(var c="",a=!1,h=arguments.length-1;h>=-1&&!a;h--){var p=h>=0?arguments[h]:Ue.cwd();if(!i(p))throw new TypeError("Arguments to path.resolve must be strings");p&&(c=p+"/"+c,a=p.charAt(0)==="/")}return(a?"/":"")+(c=s(c.split("/"),!a).join("/"))||"."},u.normalize=function(c){var a=u.isAbsolute(c),h=c.substr(-1)==="/";return(c=s(c.split("/"),!a).join("/"))||a||(c="."),c&&h&&(c+="/"),(a?"/":"")+c},u.isAbsolute=function(c){return c.charAt(0)==="/"},u.join=function(){for(var c="",a=0;a<arguments.length;a++){var h=arguments[a];if(!i(h))throw new TypeError("Arguments to path.join must be strings");h&&(c+=c?"/"+h:h)}return u.normalize(c)},u.relative=function(c,a){function h(E){for(var T=0;T<E.length&&E[T]==="";T++);for(var N=E.length-1;N>=0&&E[N]==="";N--);return T>N?[]:E.slice(T,N+1)}c=u.resolve(c).substr(1),a=u.resolve(a).substr(1);for(var p=h(c.split("/")),b=h(a.split("/")),g=Math.min(p.length,b.length),m=g,y=0;y<g;y++)if(p[y]!==b[y]){m=y;break}var v=[];for(y=m;y<p.length;y++)v.push("..");return(v=v.concat(b.slice(m))).join("/")},u._makeLong=function(c){return c},u.dirname=function(c){var a=l(c),h=a[0],p=a[1];return h||p?(p&&(p=p.substr(0,p.length-1)),h+p):"."},u.basename=function(c,a){var h=l(c)[2];return a&&h.substr(-1*a.length)===a&&(h=h.substr(0,h.length-a.length)),h},u.extname=function(c){return l(c)[3]},u.format=function(c){if(!n.isObject(c))throw new TypeError("Parameter 'pathObject' must be an object, not "+typeof c);var a=c.root||"";if(!i(a))throw new TypeError("'pathObject.root' must be a string or undefined, not "+typeof c.root);return(c.dir?c.dir+u.sep:"")+(c.base||"")},u.parse=function(c){if(!i(c))throw new TypeError("Parameter 'pathString' must be a string, not "+typeof c);var a=l(c);if(!a||a.length!==4)throw new TypeError("Invalid path '"+c+"'");return a[1]=a[1]||"",a[2]=a[2]||"",a[3]=a[3]||"",{root:a[0],dir:a[0]+a[1].slice(0,a[1].length-1),base:a[2],ext:a[3],name:a[2].slice(0,a[2].length-a[3].length)}},u.sep="/",u.delimiter=":",t.exports=u},101:function(t,e,r){var n;t=r.nmd(t),(function(){var i=(t&&t.exports,typeof je=="object"&&je);i.global!==i&&i.window;var s=function(a){this.message=a};(s.prototype=new Error).name="InvalidCharacterError";var o=function(a){throw new s(a)},u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=/[\t\n\f\r ]/g,c={encode:function(a){a=String(a),/[^\0-\xFF]/.test(a)&&o("The string to be encoded contains characters outside of the Latin1 range.");for(var h,p,b,g,m=a.length%3,y="",v=-1,E=a.length-m;++v<E;)h=a.charCodeAt(v)<<16,p=a.charCodeAt(++v)<<8,b=a.charCodeAt(++v),y+=u.charAt((g=h+p+b)>>18&63)+u.charAt(g>>12&63)+u.charAt(g>>6&63)+u.charAt(63&g);return m==2?(h=a.charCodeAt(v)<<8,p=a.charCodeAt(++v),y+=u.charAt((g=h+p)>>10)+u.charAt(g>>4&63)+u.charAt(g<<2&63)+"="):m==1&&(g=a.charCodeAt(v),y+=u.charAt(g>>2)+u.charAt(g<<4&63)+"=="),y},decode:function(a){var h=(a=String(a).replace(l,"")).length;h%4==0&&(h=(a=a.replace(/==?$/,"")).length),(h%4==1||/[^+a-zA-Z0-9/]/.test(a))&&o("Invalid character: the string to be decoded is not correctly encoded.");for(var p,b,g=0,m="",y=-1;++y<h;)b=u.indexOf(a.charAt(y)),p=g%4?64*p+b:b,g++%4&&(m+=String.fromCharCode(255&p>>(-2*g&6)));return m},version:"1.0.0"};(n=(function(){return c}).call(e,r,e,t))===void 0||(t.exports=n)})()},135:t=>{function e(r){return!!r.constructor&&typeof r.constructor.isBuffer=="function"&&r.constructor.isBuffer(r)}t.exports=function(r){return r!=null&&(e(r)||(function(n){return typeof n.readFloatLE=="function"&&typeof n.slice=="function"&&e(n.slice(0,0))})(r)||!!r._isBuffer)}},172:(t,e)=>{e.d=function(r){if(!r)return 0;for(var n=(r=r.toString()).length,i=r.length;i--;){var s=r.charCodeAt(i);56320<=s&&s<=57343&&i--,127<s&&s<=2047?n++:2047<s&&s<=65535&&(n+=2)}return n}},285:(t,e,r)=>{var n=r(2);t.exports=function(v){return v?(v.substr(0,2)==="{}"&&(v="\\{\\}"+v.substr(2)),y((function(E){return E.split("\\\\").join(i).split("\\{").join(s).split("\\}").join(o).split("\\,").join(u).split("\\.").join(l)})(v),!0).map(a)):[]};var i="\0SLASH"+Math.random()+"\0",s="\0OPEN"+Math.random()+"\0",o="\0CLOSE"+Math.random()+"\0",u="\0COMMA"+Math.random()+"\0",l="\0PERIOD"+Math.random()+"\0";function c(v){return parseInt(v,10)==v?parseInt(v,10):v.charCodeAt(0)}function a(v){return v.split(i).join("\\").split(s).join("{").split(o).join("}").split(u).join(",").split(l).join(".")}function h(v){if(!v)return[""];var E=[],T=n("{","}",v);if(!T)return v.split(",");var N=T.pre,S=T.body,F=T.post,L=N.split(",");L[L.length-1]+="{"+S+"}";var U=h(F);return F.length&&(L[L.length-1]+=U.shift(),L.push.apply(L,U)),E.push.apply(E,L),E}function p(v){return"{"+v+"}"}function b(v){return/^-?0\d/.test(v)}function g(v,E){return v<=E}function m(v,E){return v>=E}function y(v,E){var T=[],N=n("{","}",v);if(!N)return[v];var S=N.pre,F=N.post.length?y(N.post,!1):[""];if(/\$$/.test(N.pre))for(var L=0;L<F.length;L++){var U=S+"{"+N.body+"}"+F[L];T.push(U)}else{var _,j,pe=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(N.body),oe=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(N.body),R=pe||oe,le=N.body.indexOf(",")>=0;if(!R&&!le)return N.post.match(/,(?!,).*\}/)?y(v=N.pre+"{"+N.body+o+N.post):[v];if(R)_=N.body.split(/\.\./);else if((_=h(N.body)).length===1&&(_=y(_[0],!1).map(p)).length===1)return F.map((function(Fr){return N.pre+_[0]+Fr}));if(R){var Pe=c(_[0]),J=c(_[1]),ae=Math.max(_[0].length,_[1].length),K=_.length==3?Math.abs(c(_[2])):1,ke=g;J<Pe&&(K*=-1,ke=m);var Ye=_.some(b);j=[];for(var re=Pe;ke(re,J);re+=K){var ce;if(oe)(ce=String.fromCharCode(re))==="\\"&&(ce="");else if(ce=String(re),Ye){var Ze=ae-ce.length;if(Ze>0){var V=new Array(Ze+1).join("0");ce=re<0?"-"+V+ce.slice(1):V+ce}}j.push(ce)}}else{j=[];for(var q=0;q<_.length;q++)j.push.apply(j,y(_[q],!1))}for(q=0;q<j.length;q++)for(L=0;L<F.length;L++)U=S+j[q]+F[L],(!E||R||U)&&T.push(U)}return T}},298:t=>{var e,r;e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r={rotl:function(n,i){return n<<i|n>>>32-i},rotr:function(n,i){return n<<32-i|n>>>i},endian:function(n){if(n.constructor==Number)return 16711935&r.rotl(n,8)|4278255360&r.rotl(n,24);for(var i=0;i<n.length;i++)n[i]=r.endian(n[i]);return n},randomBytes:function(n){for(var i=[];n>0;n--)i.push(Math.floor(256*Math.random()));return i},bytesToWords:function(n){for(var i=[],s=0,o=0;s<n.length;s++,o+=8)i[o>>>5]|=n[s]<<24-o%32;return i},wordsToBytes:function(n){for(var i=[],s=0;s<32*n.length;s+=8)i.push(n[s>>>5]>>>24-s%32&255);return i},bytesToHex:function(n){for(var i=[],s=0;s<n.length;s++)i.push((n[s]>>>4).toString(16)),i.push((15&n[s]).toString(16));return i.join("")},hexToBytes:function(n){for(var i=[],s=0;s<n.length;s+=2)i.push(parseInt(n.substr(s,2),16));return i},bytesToBase64:function(n){for(var i=[],s=0;s<n.length;s+=3)for(var o=n[s]<<16|n[s+1]<<8|n[s+2],u=0;u<4;u++)8*s+6*u<=8*n.length?i.push(e.charAt(o>>>6*(3-u)&63)):i.push("=");return i.join("")},base64ToBytes:function(n){n=n.replace(/[^A-Z0-9+\/]/gi,"");for(var i=[],s=0,o=0;s<n.length;o=++s%4)o!=0&&i.push((e.indexOf(n.charAt(s-1))&Math.pow(2,-2*o+8)-1)<<2*o|e.indexOf(n.charAt(s))>>>6-2*o);return i}},t.exports=r},345:()=>{},388:()=>{},410:()=>{},526:t=>{var e={utf8:{stringToBytes:function(r){return e.bin.stringToBytes(unescape(encodeURIComponent(r)))},bytesToString:function(r){return decodeURIComponent(escape(e.bin.bytesToString(r)))}},bin:{stringToBytes:function(r){for(var n=[],i=0;i<r.length;i++)n.push(255&r.charCodeAt(i));return n},bytesToString:function(r){for(var n=[],i=0;i<r.length;i++)n.push(String.fromCharCode(r[i]));return n.join("")}}};t.exports=e},542:(t,e,r)=>{(function(){var n=r(298),i=r(526).utf8,s=r(135),o=r(526).bin,u=function(l,c){l.constructor==String?l=c&&c.encoding==="binary"?o.stringToBytes(l):i.stringToBytes(l):s(l)?l=Array.prototype.slice.call(l,0):Array.isArray(l)||l.constructor===Uint8Array||(l=l.toString());for(var a=n.bytesToWords(l),h=8*l.length,p=1732584193,b=-271733879,g=-1732584194,m=271733878,y=0;y<a.length;y++)a[y]=16711935&(a[y]<<8|a[y]>>>24)|4278255360&(a[y]<<24|a[y]>>>8);a[h>>>5]|=128<<h%32,a[14+(h+64>>>9<<4)]=h;var v=u._ff,E=u._gg,T=u._hh,N=u._ii;for(y=0;y<a.length;y+=16){var S=p,F=b,L=g,U=m;p=v(p,b,g,m,a[y+0],7,-680876936),m=v(m,p,b,g,a[y+1],12,-389564586),g=v(g,m,p,b,a[y+2],17,606105819),b=v(b,g,m,p,a[y+3],22,-1044525330),p=v(p,b,g,m,a[y+4],7,-176418897),m=v(m,p,b,g,a[y+5],12,1200080426),g=v(g,m,p,b,a[y+6],17,-1473231341),b=v(b,g,m,p,a[y+7],22,-45705983),p=v(p,b,g,m,a[y+8],7,1770035416),m=v(m,p,b,g,a[y+9],12,-1958414417),g=v(g,m,p,b,a[y+10],17,-42063),b=v(b,g,m,p,a[y+11],22,-1990404162),p=v(p,b,g,m,a[y+12],7,1804603682),m=v(m,p,b,g,a[y+13],12,-40341101),g=v(g,m,p,b,a[y+14],17,-1502002290),p=E(p,b=v(b,g,m,p,a[y+15],22,1236535329),g,m,a[y+1],5,-165796510),m=E(m,p,b,g,a[y+6],9,-1069501632),g=E(g,m,p,b,a[y+11],14,643717713),b=E(b,g,m,p,a[y+0],20,-373897302),p=E(p,b,g,m,a[y+5],5,-701558691),m=E(m,p,b,g,a[y+10],9,38016083),g=E(g,m,p,b,a[y+15],14,-660478335),b=E(b,g,m,p,a[y+4],20,-405537848),p=E(p,b,g,m,a[y+9],5,568446438),m=E(m,p,b,g,a[y+14],9,-1019803690),g=E(g,m,p,b,a[y+3],14,-187363961),b=E(b,g,m,p,a[y+8],20,1163531501),p=E(p,b,g,m,a[y+13],5,-1444681467),m=E(m,p,b,g,a[y+2],9,-51403784),g=E(g,m,p,b,a[y+7],14,1735328473),p=T(p,b=E(b,g,m,p,a[y+12],20,-1926607734),g,m,a[y+5],4,-378558),m=T(m,p,b,g,a[y+8],11,-2022574463),g=T(g,m,p,b,a[y+11],16,1839030562),b=T(b,g,m,p,a[y+14],23,-35309556),p=T(p,b,g,m,a[y+1],4,-1530992060),m=T(m,p,b,g,a[y+4],11,1272893353),g=T(g,m,p,b,a[y+7],16,-155497632),b=T(b,g,m,p,a[y+10],23,-1094730640),p=T(p,b,g,m,a[y+13],4,681279174),m=T(m,p,b,g,a[y+0],11,-358537222),g=T(g,m,p,b,a[y+3],16,-722521979),b=T(b,g,m,p,a[y+6],23,76029189),p=T(p,b,g,m,a[y+9],4,-640364487),m=T(m,p,b,g,a[y+12],11,-421815835),g=T(g,m,p,b,a[y+15],16,530742520),p=N(p,b=T(b,g,m,p,a[y+2],23,-995338651),g,m,a[y+0],6,-198630844),m=N(m,p,b,g,a[y+7],10,1126891415),g=N(g,m,p,b,a[y+14],15,-1416354905),b=N(b,g,m,p,a[y+5],21,-57434055),p=N(p,b,g,m,a[y+12],6,1700485571),m=N(m,p,b,g,a[y+3],10,-1894986606),g=N(g,m,p,b,a[y+10],15,-1051523),b=N(b,g,m,p,a[y+1],21,-2054922799),p=N(p,b,g,m,a[y+8],6,1873313359),m=N(m,p,b,g,a[y+15],10,-30611744),g=N(g,m,p,b,a[y+6],15,-1560198380),b=N(b,g,m,p,a[y+13],21,1309151649),p=N(p,b,g,m,a[y+4],6,-145523070),m=N(m,p,b,g,a[y+11],10,-1120210379),g=N(g,m,p,b,a[y+2],15,718787259),b=N(b,g,m,p,a[y+9],21,-343485551),p=p+S>>>0,b=b+F>>>0,g=g+L>>>0,m=m+U>>>0}return n.endian([p,b,g,m])};u._ff=function(l,c,a,h,p,b,g){var m=l+(c&a|~c&h)+(p>>>0)+g;return(m<<b|m>>>32-b)+c},u._gg=function(l,c,a,h,p,b,g){var m=l+(c&h|a&~h)+(p>>>0)+g;return(m<<b|m>>>32-b)+c},u._hh=function(l,c,a,h,p,b,g){var m=l+(c^a^h)+(p>>>0)+g;return(m<<b|m>>>32-b)+c},u._ii=function(l,c,a,h,p,b,g){var m=l+(a^(c|~h))+(p>>>0)+g;return(m<<b|m>>>32-b)+c},u._blocksize=16,u._digestsize=16,t.exports=function(l,c){if(l==null)throw new Error("Illegal argument "+l);var a=n.wordsToBytes(u(l,c));return c&&c.asBytes?a:c&&c.asString?o.bytesToString(a):n.bytesToHex(a)}})()},647:(t,e)=>{var r=Object.prototype.hasOwnProperty;function n(s){try{return decodeURIComponent(s.replace(/\+/g," "))}catch{return null}}function i(s){try{return encodeURIComponent(s)}catch{return null}}e.stringify=function(s,o){o=o||"";var u,l,c=[];for(l in typeof o!="string"&&(o="?"),s)if(r.call(s,l)){if((u=s[l])||u!=null&&!isNaN(u)||(u=""),l=i(l),u=i(u),l===null||u===null)continue;c.push(l+"="+u)}return c.length?o+c.join("&"):""},e.parse=function(s){for(var o,u=/([^=?#&]+)=?([^&]*)/g,l={};o=u.exec(s);){var c=n(o[1]),a=n(o[2]);c===null||a===null||c in l||(l[c]=a)}return l}},670:t=>{t.exports=function(e,r){if(r=r.split(":")[0],!(e=+e))return!1;switch(r){case"http":case"ws":return e!==80;case"https":case"wss":return e!==443;case"ftp":return e!==21;case"gopher":return e!==70;case"file":return!1}return e!==0}},737:(t,e,r)=>{var n=r(670),i=r(647),s=/^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/,o=/[\n\r\t]/g,u=/^[A-Za-z][A-Za-z0-9+-.]*:\/\//,l=/:\d+$/,c=/^([a-z][a-z0-9.+-]*:)?(\/\/)?([\\/]+)?([\S\s]*)/i,a=/^[a-zA-Z]:/;function h(E){return(E||"").toString().replace(s,"")}var p=[["#","hash"],["?","query"],function(E,T){return m(T.protocol)?E.replace(/\\/g,"/"):E},["/","pathname"],["@","auth",1],[NaN,"host",void 0,1,1],[/:(\d*)$/,"port",void 0,1],[NaN,"hostname",void 0,1,1]],b={hash:1,query:1};function g(E){var T,N=(typeof window<"u"?window:typeof je<"u"?je:typeof self<"u"?self:{}).location||{},S={},F=typeof(E=E||N);if(E.protocol==="blob:")S=new v(unescape(E.pathname),{});else if(F==="string")for(T in S=new v(E,{}),b)delete S[T];else if(F==="object"){for(T in E)T in b||(S[T]=E[T]);S.slashes===void 0&&(S.slashes=u.test(E.href))}return S}function m(E){return E==="file:"||E==="ftp:"||E==="http:"||E==="https:"||E==="ws:"||E==="wss:"}function y(E,T){E=(E=h(E)).replace(o,""),T=T||{};var N,S=c.exec(E),F=S[1]?S[1].toLowerCase():"",L=!!S[2],U=!!S[3],_=0;return L?U?(N=S[2]+S[3]+S[4],_=S[2].length+S[3].length):(N=S[2]+S[4],_=S[2].length):U?(N=S[3]+S[4],_=S[3].length):N=S[4],F==="file:"?_>=2&&(N=N.slice(2)):m(F)?N=S[4]:F?L&&(N=N.slice(2)):_>=2&&m(T.protocol)&&(N=S[4]),{protocol:F,slashes:L||m(F),slashesCount:_,rest:N}}function v(E,T,N){if(E=(E=h(E)).replace(o,""),!(this instanceof v))return new v(E,T,N);var S,F,L,U,_,j,pe=p.slice(),oe=typeof T,R=this,le=0;for(oe!=="object"&&oe!=="string"&&(N=T,T=null),N&&typeof N!="function"&&(N=i.parse),S=!(F=y(E||"",T=g(T))).protocol&&!F.slashes,R.slashes=F.slashes||S&&T.slashes,R.protocol=F.protocol||T.protocol||"",E=F.rest,(F.protocol==="file:"&&(F.slashesCount!==2||a.test(E))||!F.slashes&&(F.protocol||F.slashesCount<2||!m(R.protocol)))&&(pe[3]=[/(.*)/,"pathname"]);le<pe.length;le++)typeof(U=pe[le])!="function"?(L=U[0],j=U[1],L!=L?R[j]=E:typeof L=="string"?~(_=L==="@"?E.lastIndexOf(L):E.indexOf(L))&&(typeof U[2]=="number"?(R[j]=E.slice(0,_),E=E.slice(_+U[2])):(R[j]=E.slice(_),E=E.slice(0,_))):(_=L.exec(E))&&(R[j]=_[1],E=E.slice(0,_.index)),R[j]=R[j]||S&&U[3]&&T[j]||"",U[4]&&(R[j]=R[j].toLowerCase())):E=U(E,R);N&&(R.query=N(R.query)),S&&T.slashes&&R.pathname.charAt(0)!=="/"&&(R.pathname!==""||T.pathname!=="")&&(R.pathname=(function(Pe,J){if(Pe==="")return J;for(var ae=(J||"/").split("/").slice(0,-1).concat(Pe.split("/")),K=ae.length,ke=ae[K-1],Ye=!1,re=0;K--;)ae[K]==="."?ae.splice(K,1):ae[K]===".."?(ae.splice(K,1),re++):re&&(K===0&&(Ye=!0),ae.splice(K,1),re--);return Ye&&ae.unshift(""),ke!=="."&&ke!==".."||ae.push(""),ae.join("/")})(R.pathname,T.pathname)),R.pathname.charAt(0)!=="/"&&m(R.protocol)&&(R.pathname="/"+R.pathname),n(R.port,R.protocol)||(R.host=R.hostname,R.port=""),R.username=R.password="",R.auth&&(~(_=R.auth.indexOf(":"))?(R.username=R.auth.slice(0,_),R.username=encodeURIComponent(decodeURIComponent(R.username)),R.password=R.auth.slice(_+1),R.password=encodeURIComponent(decodeURIComponent(R.password))):R.username=encodeURIComponent(decodeURIComponent(R.auth)),R.auth=R.password?R.username+":"+R.password:R.username),R.origin=R.protocol!=="file:"&&m(R.protocol)&&R.host?R.protocol+"//"+R.host:"null",R.href=R.toString()}v.prototype={set:function(E,T,N){var S=this;switch(E){case"query":typeof T=="string"&&T.length&&(T=(N||i.parse)(T)),S[E]=T;break;case"port":S[E]=T,n(T,S.protocol)?T&&(S.host=S.hostname+":"+T):(S.host=S.hostname,S[E]="");break;case"hostname":S[E]=T,S.port&&(T+=":"+S.port),S.host=T;break;case"host":S[E]=T,l.test(T)?(T=T.split(":"),S.port=T.pop(),S.hostname=T.join(":")):(S.hostname=T,S.port="");break;case"protocol":S.protocol=T.toLowerCase(),S.slashes=!N;break;case"pathname":case"hash":if(T){var F=E==="pathname"?"/":"#";S[E]=T.charAt(0)!==F?F+T:T}else S[E]=T;break;case"username":case"password":S[E]=encodeURIComponent(T);break;case"auth":var L=T.indexOf(":");~L?(S.username=T.slice(0,L),S.username=encodeURIComponent(decodeURIComponent(S.username)),S.password=T.slice(L+1),S.password=encodeURIComponent(decodeURIComponent(S.password))):S.username=encodeURIComponent(decodeURIComponent(T))}for(var U=0;U<p.length;U++){var _=p[U];_[4]&&(S[_[1]]=S[_[1]].toLowerCase())}return S.auth=S.password?S.username+":"+S.password:S.username,S.origin=S.protocol!=="file:"&&m(S.protocol)&&S.host?S.protocol+"//"+S.host:"null",S.href=S.toString(),S},toString:function(E){E&&typeof E=="function"||(E=i.stringify);var T,N=this,S=N.host,F=N.protocol;F&&F.charAt(F.length-1)!==":"&&(F+=":");var L=F+(N.protocol&&N.slashes||m(N.protocol)?"//":"");return N.username?(L+=N.username,N.password&&(L+=":"+N.password),L+="@"):N.password?(L+=":"+N.password,L+="@"):N.protocol!=="file:"&&m(N.protocol)&&!S&&N.pathname!=="/"&&(L+="@"),(S[S.length-1]===":"||l.test(N.hostname)&&!N.port)&&(S+=":"),L+=S+N.pathname,(T=typeof N.query=="object"?E(N.query):N.query)&&(L+=T.charAt(0)!=="?"?"?"+T:T),N.hash&&(L+=N.hash),L}},v.extractProtocol=y,v.location=g,v.trimLeft=h,v.qs=i,t.exports=v},800:()=>{},805:()=>{},829:t=>{function e(c){return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},e(c)}function r(c){var a=typeof Map=="function"?new Map:void 0;return r=function(h){if(h===null||(p=h,Function.toString.call(p).indexOf("[native code]")===-1))return h;var p;if(typeof h!="function")throw new TypeError("Super expression must either be null or a function");if(a!==void 0){if(a.has(h))return a.get(h);a.set(h,b)}function b(){return n(h,arguments,s(this).constructor)}return b.prototype=Object.create(h.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}}),i(b,h)},r(c)}function n(c,a,h){return n=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch{return!1}})()?Reflect.construct:function(p,b,g){var m=[null];m.push.apply(m,b);var y=new(Function.bind.apply(p,m));return g&&i(y,g.prototype),y},n.apply(null,arguments)}function i(c,a){return i=Object.setPrototypeOf||function(h,p){return h.__proto__=p,h},i(c,a)}function s(c){return s=Object.setPrototypeOf?Object.getPrototypeOf:function(a){return a.__proto__||Object.getPrototypeOf(a)},s(c)}var o=(function(c){function a(h){var p;return(function(b,g){if(!(b instanceof g))throw new TypeError("Cannot call a class as a function")})(this,a),(p=(function(b,g){return!g||e(g)!=="object"&&typeof g!="function"?(function(m){if(m===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return m})(b):g})(this,s(a).call(this,h))).name="ObjectPrototypeMutationError",p}return(function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function");h.prototype=Object.create(p&&p.prototype,{constructor:{value:h,writable:!0,configurable:!0}}),p&&i(h,p)})(a,c),a})(r(Error));function u(c,a){for(var h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},p=a.split("."),b=p.length,g=function(v){var E=p[v];if(!c)return{v:void 0};if(E==="+"){if(Array.isArray(c))return{v:c.map((function(N,S){var F=p.slice(v+1);return F.length>0?u(N,F.join("."),h):h(c,S,p,v)}))};var T=p.slice(0,v).join(".");throw new Error("Object at wildcard (".concat(T,") is not an array"))}c=h(c,E,p,v)},m=0;m<b;m++){var y=g(m);if(e(y)==="object")return y.v}return c}function l(c,a){return c.length===a+1}t.exports={set:function(c,a,h){if(e(c)!="object"||c===null||a===void 0)return c;if(typeof a=="number")return c[a]=h,c[a];try{return u(c,a,(function(p,b,g,m){if(p===Reflect.getPrototypeOf({}))throw new o("Attempting to mutate Object.prototype");if(!p[b]){var y=Number.isInteger(Number(g[m+1])),v=g[m+1]==="+";p[b]=y||v?[]:{}}return l(g,m)&&(p[b]=h),p[b]}))}catch(p){if(p instanceof o)throw p;return c}},get:function(c,a){if(e(c)!="object"||c===null||a===void 0)return c;if(typeof a=="number")return c[a];try{return u(c,a,(function(h,p){return h[p]}))}catch{return c}},has:function(c,a){var h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(e(c)!="object"||c===null||a===void 0)return!1;if(typeof a=="number")return a in c;try{var p=!1;return u(c,a,(function(b,g,m,y){if(!l(m,y))return b&&b[g];p=h.own?b.hasOwnProperty(g):g in b})),p}catch{return!1}},hasOwn:function(c,a,h){return this.has(c,a,h||{own:!0})},isIn:function(c,a,h){var p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};if(e(c)!="object"||c===null||a===void 0)return!1;try{var b=!1,g=!1;return u(c,a,(function(m,y,v,E){return b=b||m===h||!!m&&m[y]===h,g=l(v,E)&&e(m)==="object"&&y in m,m&&m[y]})),p.validPath?b&&g:b}catch{return!1}},ObjectPrototypeMutationError:o}}},Ms={};function H(t){var e=Ms[t];if(e!==void 0)return e.exports;var r=Ms[t]={id:t,loaded:!1,exports:{}};return Ad[t].call(r.exports,r,r.exports,H),r.loaded=!0,r.exports}H.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return H.d(e,{a:e}),e},H.d=(t,e)=>{for(var r in e)H.o(e,r)&&!H.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},H.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),H.nmd=t=>(t.paths=[],t.children||(t.children=[]),t);var Nd=H(737),Pd=H.n(Nd);function pn(t){if(!gn(t))throw new Error("Parameter was not an error")}function gn(t){return!!t&&typeof t=="object"&&(e=t,Object.prototype.toString.call(e)==="[object Error]")||t instanceof Error;var e}class me extends Error{constructor(e,r){const n=[...arguments],{options:i,shortMessage:s}=(function(u){let l,c="";if(u.length===0)l={};else if(gn(u[0]))l={cause:u[0]},c=u.slice(1).join(" ")||"";else if(u[0]&&typeof u[0]=="object")l=Object.assign({},u[0]),c=u.slice(1).join(" ")||"";else{if(typeof u[0]!="string")throw new Error("Invalid arguments passed to Layerr");l={},c=c=u.join(" ")||""}return{options:l,shortMessage:c}})(n);let o=s;if(i.cause&&(o=`${o}: ${i.cause.message}`),super(o),this.message=o,i.name&&typeof i.name=="string"?this.name=i.name:this.name="Layerr",i.cause&&Object.defineProperty(this,"_cause",{value:i.cause}),Object.defineProperty(this,"_info",{value:{}}),i.info&&typeof i.info=="object"&&Object.assign(this._info,i.info),Error.captureStackTrace){const u=i.constructorOpt||this.constructor;Error.captureStackTrace(this,u)}}static cause(e){return pn(e),e._cause&&gn(e._cause)?e._cause:null}static fullStack(e){pn(e);const r=me.cause(e);return r?`${e.stack}
13
- caused by: ${me.fullStack(r)}`:e.stack??""}static info(e){pn(e);const r={},n=me.cause(e);return n&&Object.assign(r,me.info(n)),e._info&&Object.assign(r,e._info),r}toString(){let e=this.name||this.constructor.name||this.constructor.prototype.name;return this.message&&(e=`${e}: ${this.message}`),e}}var Id=H(47),Tr=H.n(Id);const Ds="__PATH_SEPARATOR_POSIX__",Vs="__PATH_SEPARATOR_WINDOWS__";function W(t){try{const e=t.replace(/\//g,Ds).replace(/\\\\/g,Vs);return encodeURIComponent(e).split(Vs).join("\\\\").split(Ds).join("/")}catch(e){throw new me(e,"Failed encoding path")}}function Hs(t){return t.startsWith("/")?t:"/"+t}function Vt(t){let e=t;return e[0]!=="/"&&(e="/"+e),/^.+\/$/.test(e)&&(e=e.substr(0,e.length-1)),e}function Sd(t){let e=new(Pd())(t).pathname;return e.length<=0&&(e="/"),Vt(e)}function G(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return(function(){return(function(n){var i=[];if(n.length===0)return"";if(typeof n[0]!="string")throw new TypeError("Url must be a string. Received "+n[0]);if(n[0].match(/^[^/:]+:\/*$/)&&n.length>1){var s=n.shift();n[0]=s+n[0]}n[0].match(/^file:\/\/\//)?n[0]=n[0].replace(/^([^/:]+):\/*/,"$1:///"):n[0]=n[0].replace(/^([^/:]+):\/*/,"$1://");for(var o=0;o<n.length;o++){var u=n[o];if(typeof u!="string")throw new TypeError("Url must be a string. Received "+u);u!==""&&(o>0&&(u=u.replace(/^[\/]+/,"")),u=o<n.length-1?u.replace(/[\/]+$/,""):u.replace(/[\/]+$/,"/"),i.push(u))}var l=i.join("/"),c=(l=l.replace(/\/(\?|&|#[^!])/g,"$1")).split("?");return c.shift()+(c.length>0?"?":"")+c.join("&")})(typeof arguments[0]=="object"?arguments[0]:[].slice.call(arguments))})(e.reduce(((n,i,s)=>((s===0||i!=="/"||i==="/"&&n[n.length-1]!=="/")&&n.push(i),n)),[]))}var Od=H(542),Ht=H.n(Od);function qs(t,e){const r=t.url.replace("//",""),n=r.indexOf("/")==-1?"/":r.slice(r.indexOf("/")),i=t.method?t.method.toUpperCase():"GET",s=!!/(^|,)\s*auth\s*($|,)/.test(e.qop)&&"auth",o=`00000000${e.nc}`.slice(-8),u=(function(p,b,g,m,y,v,E){const T=E||Ht()(`${b}:${g}:${m}`);return p&&p.toLowerCase()==="md5-sess"?Ht()(`${T}:${y}:${v}`):T})(e.algorithm,e.username,e.realm,e.password,e.nonce,e.cnonce,e.ha1),l=Ht()(`${i}:${n}`),c=s?Ht()(`${u}:${e.nonce}:${o}:${e.cnonce}:${s}:${l}`):Ht()(`${u}:${e.nonce}:${l}`),a={username:e.username,realm:e.realm,nonce:e.nonce,uri:n,qop:s,response:c,nc:o,cnonce:e.cnonce,algorithm:e.algorithm,opaque:e.opaque},h=[];for(const p in a)a[p]&&(p==="qop"||p==="nc"||p==="algorithm"?h.push(`${p}=${a[p]}`):h.push(`${p}="${a[p]}"`));return`Digest ${h.join(", ")}`}function zs(t){return(t.headers&&t.headers.get("www-authenticate")||"").split(/\s/)[0].toLowerCase()==="digest"}var Cd=H(101),Ws=H.n(Cd);function Gs(t){return Ws().decode(t)}function Ks(t,e){var r;return`Basic ${r=`${t}:${e}`,Ws().encode(r)}`}const Js=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope?self:typeof window<"u"?window:globalThis,Rd=Js.fetch.bind(Js);let Te=(function(t){return t.Auto="auto",t.Digest="digest",t.None="none",t.Password="password",t.Token="token",t})({}),Je=(function(t){return t.DataTypeNoLength="data-type-no-length",t.InvalidAuthType="invalid-auth-type",t.InvalidOutputFormat="invalid-output-format",t.LinkUnsupportedAuthType="link-unsupported-auth",t.InvalidUpdateRange="invalid-update-range",t.NotSupported="not-supported",t})({});function Xs(t,e,r,n,i){switch(t.authType){case Te.Auto:e&&r&&(t.headers.Authorization=Ks(e,r));break;case Te.Digest:t.digest=(function(o,u,l){return{username:o,password:u,ha1:l,nc:0,algorithm:"md5",hasDigestAuth:!1}})(e,r,i);break;case Te.None:break;case Te.Password:t.headers.Authorization=Ks(e,r);break;case Te.Token:t.headers.Authorization=`${(s=n).token_type} ${s.access_token}`;break;default:throw new me({info:{code:Je.InvalidAuthType}},`Invalid auth type: ${t.authType}`)}var s}H(345),H(800);const Ys="@@HOTPATCHER",Fd=()=>{};function mn(t){return{original:t,methods:[t],final:!1}}class Ld{constructor(){this._configuration={registry:{},getEmptyAction:"null"},this.__type__=Ys}get configuration(){return this._configuration}get getEmptyAction(){return this.configuration.getEmptyAction}set getEmptyAction(e){this.configuration.getEmptyAction=e}control(e){let r=arguments.length>1&&arguments[1]!==void 0&&arguments[1];if(!e||e.__type__!==Ys)throw new Error("Failed taking control of target HotPatcher instance: Invalid type or object");return Object.keys(e.configuration.registry).forEach((n=>{this.configuration.registry.hasOwnProperty(n)?r&&(this.configuration.registry[n]=Object.assign({},e.configuration.registry[n])):this.configuration.registry[n]=Object.assign({},e.configuration.registry[n])})),e._configuration=this.configuration,this}execute(e){const r=this.get(e)||Fd;for(var n=arguments.length,i=new Array(n>1?n-1:0),s=1;s<n;s++)i[s-1]=arguments[s];return r(...i)}get(e){const r=this.configuration.registry[e];if(!r)switch(this.getEmptyAction){case"null":return null;case"throw":throw new Error(`Failed handling method request: No method provided for override: ${e}`);default:throw new Error(`Failed handling request which resulted in an empty method: Invalid empty-action specified: ${this.getEmptyAction}`)}return(function(){for(var n=arguments.length,i=new Array(n),s=0;s<n;s++)i[s]=arguments[s];if(i.length===0)throw new Error("Failed creating sequence: No functions provided");return function(){for(var o=arguments.length,u=new Array(o),l=0;l<o;l++)u[l]=arguments[l];let c=u;const a=this;for(;i.length>0;)c=[i.shift().apply(a,c)];return c[0]}})(...r.methods)}isPatched(e){return!!this.configuration.registry[e]}patch(e,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const{chain:i=!1}=n;if(this.configuration.registry[e]&&this.configuration.registry[e].final)throw new Error(`Failed patching '${e}': Method marked as being final`);if(typeof r!="function")throw new Error(`Failed patching '${e}': Provided method is not a function`);if(i)this.configuration.registry[e]?this.configuration.registry[e].methods.push(r):this.configuration.registry[e]=mn(r);else if(this.isPatched(e)){const{original:s}=this.configuration.registry[e];this.configuration.registry[e]=Object.assign(mn(r),{original:s})}else this.configuration.registry[e]=mn(r);return this}patchInline(e,r){this.isPatched(e)||this.patch(e,r);for(var n=arguments.length,i=new Array(n>2?n-2:0),s=2;s<n;s++)i[s-2]=arguments[s];return this.execute(e,...i)}plugin(e){for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i<r;i++)n[i-1]=arguments[i];return n.forEach((s=>{this.patch(e,s,{chain:!0})})),this}restore(e){if(!this.isPatched(e))throw new Error(`Failed restoring method: No method present for key: ${e}`);if(typeof this.configuration.registry[e].original!="function")throw new Error(`Failed restoring method: Original method not found or of invalid type for key: ${e}`);return this.configuration.registry[e].methods=[this.configuration.registry[e].original],this}setFinal(e){if(!this.configuration.registry.hasOwnProperty(e))throw new Error(`Failed marking '${e}' as final: No method found for key`);return this.configuration.registry[e].final=!0,this}}let yn=null;function _d(){return yn||(yn=new Ld),yn}function Ar(t){return(function(e){if(typeof e!="object"||e===null||Object.prototype.toString.call(e)!="[object Object]")return!1;if(Object.getPrototypeOf(e)===null)return!0;let r=e;for(;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(e)===r})(t)?Object.assign({},t):Object.setPrototypeOf(Object.assign({},t),Object.getPrototypeOf(t))}function Zs(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];let n=null,i=[...e];for(;i.length>0;){const s=i.shift();n=n?Qs(n,s):Ar(s)}return n}function Qs(t,e){const r=Ar(t);return Object.keys(e).forEach((n=>{r.hasOwnProperty(n)?Array.isArray(e[n])?r[n]=Array.isArray(r[n])?[...r[n],...e[n]]:[...e[n]]:typeof e[n]=="object"&&e[n]?r[n]=typeof r[n]=="object"&&r[n]?Qs(r[n],e[n]):Ar(e[n]):r[n]=e[n]:r[n]=e[n]})),r}function Ud(t){const e={};for(const r of t.keys())e[r]=t.get(r);return e}function bn(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];if(e.length===0)return{};const n={};return e.reduce(((i,s)=>(Object.keys(s).forEach((o=>{const u=o.toLowerCase();n.hasOwnProperty(u)?i[n[u]]=s[o]:(n[u]=o,i[o]=s[o])})),i)),{})}H(805);const Bd=typeof ArrayBuffer=="function",{toString:kd}=Object.prototype;function eo(t){return Bd&&(t instanceof ArrayBuffer||kd.call(t)==="[object ArrayBuffer]")}function to(t){return t!=null&&t.constructor!=null&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)}function wn(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}}function xn(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const ro=wn((function(t){const e=t._digest;return delete t._digest,e.hasDigestAuth&&(t=Zs(t,{headers:{Authorization:qs(t,e)}})),xn(Nr(t),(function(r){let n=!1;return i=function(o){return n?o:r},(s=(function(){if(r.status==401)return e.hasDigestAuth=(function(o,u){if(!zs(o))return!1;const l=/([a-z0-9_-]+)=(?:"([^"]+)"|([a-z0-9_-]+))/gi;for(;;){const c=o.headers&&o.headers.get("www-authenticate")||"",a=l.exec(c);if(!a)break;u[a[1]]=a[2]||a[3]}return u.nc+=1,u.cnonce=(function(){let c="";for(let a=0;a<32;++a)c=`${c}${"abcdef0123456789"[Math.floor(16*Math.random())]}`;return c})(),!0})(r,e),(function(){if(e.hasDigestAuth)return xn(Nr(t=Zs(t,{headers:{Authorization:qs(t,e)}})),(function(o){return o.status==401?e.hasDigestAuth=!1:e.nc++,n=!0,o}))})();e.nc++})())&&s.then?s.then(i):i(s);var i,s}))})),$d=wn((function(t,e){return xn(Nr(t),(function(r){return r.ok?(e.authType=Te.Password,r):r.status==401&&zs(r)?(e.authType=Te.Digest,Xs(e,e.username,e.password,void 0,void 0),t._digest=e.digest,ro(t)):r}))})),ne=wn((function(t,e){return e.authType===Te.Auto?$d(t,e):t._digest?ro(t):Nr(t)}));function ie(t,e,r){const n=Ar(t);return n.headers=bn(e.headers,n.headers||{},r.headers||{}),r.data!==void 0&&(n.data=r.data),r.signal&&(n.signal=r.signal),e.httpAgent&&(n.httpAgent=e.httpAgent),e.httpsAgent&&(n.httpsAgent=e.httpsAgent),e.digest&&(n._digest=e.digest),typeof e.withCredentials=="boolean"&&(n.withCredentials=e.withCredentials),n}function Nr(t){const e=_d();return e.patchInline("request",(r=>e.patchInline("fetch",Rd,r.url,(function(n){let i={};const s={method:n.method};if(n.headers&&(i=bn(i,n.headers)),n.data!==void 0){const[o,u]=(function(l){if(typeof l=="string")return[l,{}];if(to(l))return[l,{}];if(eo(l))return[l,{}];if(l&&typeof l=="object")return[JSON.stringify(l),{"content-type":"application/json"}];throw new Error("Unable to convert request body: Unexpected body type: "+typeof l)})(n.data);s.body=o,i=bn(i,u)}return n.signal&&(s.signal=n.signal),n.withCredentials&&(s.credentials="include"),s.headers=i,s})(r))),t)}var jd=H(285);const Pr=t=>{if(typeof t!="string")throw new TypeError("invalid pattern");if(t.length>65536)throw new TypeError("pattern is too long")},Md={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},qt=t=>t.replace(/[[\]\\-]/g,"\\$&"),no=t=>t.join(""),Dd=(t,e)=>{const r=e;if(t.charAt(r)!=="[")throw new Error("not in a brace expression");const n=[],i=[];let s=r+1,o=!1,u=!1,l=!1,c=!1,a=r,h="";e:for(;s<t.length;){const m=t.charAt(s);if(m!=="!"&&m!=="^"||s!==r+1){if(m==="]"&&o&&!l){a=s+1;break}if(o=!0,m!=="\\"||l){if(m==="["&&!l){for(const[y,[v,E,T]]of Object.entries(Md))if(t.startsWith(y,s)){if(h)return["$.",!1,t.length-r,!0];s+=y.length,T?i.push(v):n.push(v),u=u||E;continue e}}l=!1,h?(m>h?n.push(qt(h)+"-"+qt(m)):m===h&&n.push(qt(m)),h="",s++):t.startsWith("-]",s+1)?(n.push(qt(m+"-")),s+=2):t.startsWith("-",s+1)?(h=m,s+=2):(n.push(qt(m)),s++)}else l=!0,s++}else c=!0,s++}if(a<s)return["",!1,0,!1];if(!n.length&&!i.length)return["$.",!1,t.length-r,!0];if(i.length===0&&n.length===1&&/^\\?.$/.test(n[0])&&!c)return[(p=n[0].length===2?n[0].slice(-1):n[0],p.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")),!1,a-r,!1];var p;const b="["+(c?"^":"")+no(n)+"]",g="["+(c?"":"^")+no(i)+"]";return[n.length&&i.length?"("+b+"|"+g+")":n.length?b:g,u,a-r,!0]},zt=function(t){let{windowsPathsNoEscape:e=!1}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e?t.replace(/\[([^\/\\])\]/g,"$1"):t.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1")},Vd=new Set(["!","?","+","*","@"]),io=t=>Vd.has(t),En="(?!\\.)",Hd=new Set(["[","."]),qd=new Set(["..","."]),zd=new Set("().*{}+?[]^$\\!"),vn="[^/]",so=vn+"*?",oo=vn+"+?";class ye{type;#e;#r;#s=!1;#t=[];#n;#d;#l;#g=!1;#f;#c;#p=!1;constructor(e,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.type=e,e&&(this.#r=!0),this.#n=r,this.#e=this.#n?this.#n.#e:this,this.#f=this.#e===this?n:this.#e.#f,this.#l=this.#e===this?[]:this.#e.#l,e!=="!"||this.#e.#g||this.#l.push(this),this.#d=this.#n?this.#n.#t.length:0}get hasMagic(){if(this.#r!==void 0)return this.#r;for(const e of this.#t)if(typeof e!="string"&&(e.type||e.hasMagic))return this.#r=!0;return this.#r}toString(){return this.#c!==void 0?this.#c:this.type?this.#c=this.type+"("+this.#t.map((e=>String(e))).join("|")+")":this.#c=this.#t.map((e=>String(e))).join("")}#h(){if(this!==this.#e)throw new Error("should only call on root");if(this.#g)return this;let e;for(this.toString(),this.#g=!0;e=this.#l.pop();){if(e.type!=="!")continue;let r=e,n=r.#n;for(;n;){for(let i=r.#d+1;!n.type&&i<n.#t.length;i++)for(const s of e.#t){if(typeof s=="string")throw new Error("string part in extglob AST??");s.copyIn(n.#t[i])}r=n,n=r.#n}}return this}push(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];for(const i of r)if(i!==""){if(typeof i!="string"&&!(i instanceof ye&&i.#n===this))throw new Error("invalid part: "+i);this.#t.push(i)}}toJSON(){const e=this.type===null?this.#t.slice().map((r=>typeof r=="string"?r:r.toJSON())):[this.type,...this.#t.map((r=>r.toJSON()))];return this.isStart()&&!this.type&&e.unshift([]),this.isEnd()&&(this===this.#e||this.#e.#g&&this.#n?.type==="!")&&e.push({}),e}isStart(){if(this.#e===this)return!0;if(!this.#n?.isStart())return!1;if(this.#d===0)return!0;const e=this.#n;for(let r=0;r<this.#d;r++){const n=e.#t[r];if(!(n instanceof ye&&n.type==="!"))return!1}return!0}isEnd(){if(this.#e===this||this.#n?.type==="!")return!0;if(!this.#n?.isEnd())return!1;if(!this.type)return this.#n?.isEnd();const e=this.#n?this.#n.#t.length:0;return this.#d===e-1}copyIn(e){typeof e=="string"?this.push(e):this.push(e.clone(this))}clone(e){const r=new ye(this.type,e);for(const n of this.#t)r.copyIn(n);return r}static#o(e,r,n,i){let s=!1,o=!1,u=-1,l=!1;if(r.type===null){let b=n,g="";for(;b<e.length;){const m=e.charAt(b++);if(s||m==="\\")s=!s,g+=m;else if(o)b===u+1?m!=="^"&&m!=="!"||(l=!0):m!=="]"||b===u+2&&l||(o=!1),g+=m;else if(m!=="[")if(i.noext||!io(m)||e.charAt(b)!=="(")g+=m;else{r.push(g),g="";const y=new ye(m,r);b=ye.#o(e,y,b,i),r.push(y)}else o=!0,u=b,l=!1,g+=m}return r.push(g),b}let c=n+1,a=new ye(null,r);const h=[];let p="";for(;c<e.length;){const b=e.charAt(c++);if(s||b==="\\")s=!s,p+=b;else if(o)c===u+1?b!=="^"&&b!=="!"||(l=!0):b!=="]"||c===u+2&&l||(o=!1),p+=b;else if(b!=="[")if(io(b)&&e.charAt(c)==="("){a.push(p),p="";const g=new ye(b,a);a.push(g),c=ye.#o(e,g,c,i)}else if(b!=="|"){if(b===")")return p===""&&r.#t.length===0&&(r.#p=!0),a.push(p),p="",r.push(...h,a),c;p+=b}else a.push(p),p="",h.push(a),a=new ye(null,r);else o=!0,u=c,l=!1,p+=b}return r.type=null,r.#r=void 0,r.#t=[e.substring(n-1)],c}static fromGlob(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const n=new ye(null,void 0,r);return ye.#o(e,n,0,r),n}toMMPattern(){if(this!==this.#e)return this.#e.toMMPattern();const e=this.toString(),[r,n,i,s]=this.toRegExpSource();if(!(i||this.#r||this.#f.nocase&&!this.#f.nocaseMagicOnly&&e.toUpperCase()!==e.toLowerCase()))return n;const o=(this.#f.nocase?"i":"")+(s?"u":"");return Object.assign(new RegExp(`^${r}$`,o),{_src:r,_glob:e})}get options(){return this.#f}toRegExpSource(e){const r=e??!!this.#f.dot;if(this.#e===this&&this.#h(),!this.type){const l=this.isStart()&&this.isEnd(),c=this.#t.map((p=>{const[b,g,m,y]=typeof p=="string"?ye.#i(p,this.#r,l):p.toRegExpSource(e);return this.#r=this.#r||m,this.#s=this.#s||y,b})).join("");let a="";if(this.isStart()&&typeof this.#t[0]=="string"&&(this.#t.length!==1||!qd.has(this.#t[0]))){const p=Hd,b=r&&p.has(c.charAt(0))||c.startsWith("\\.")&&p.has(c.charAt(2))||c.startsWith("\\.\\.")&&p.has(c.charAt(4)),g=!r&&!e&&p.has(c.charAt(0));a=b?"(?!(?:^|/)\\.\\.?(?:$|/))":g?En:""}let h="";return this.isEnd()&&this.#e.#g&&this.#n?.type==="!"&&(h="(?:$|\\/)"),[a+c+h,zt(c),this.#r=!!this.#r,this.#s]}const n=this.type==="*"||this.type==="+",i=this.type==="!"?"(?:(?!(?:":"(?:";let s=this.#a(r);if(this.isStart()&&this.isEnd()&&!s&&this.type!=="!"){const l=this.toString();return this.#t=[l],this.type=null,this.#r=void 0,[l,zt(this.toString()),!1,!1]}let o=!n||e||r?"":this.#a(!0);o===s&&(o=""),o&&(s=`(?:${s})(?:${o})*?`);let u="";return u=this.type==="!"&&this.#p?(this.isStart()&&!r?En:"")+oo:i+s+(this.type==="!"?"))"+(!this.isStart()||r||e?"":En)+so+")":this.type==="@"?")":this.type==="?"?")?":this.type==="+"&&o?")":this.type==="*"&&o?")?":`)${this.type}`),[u,zt(s),this.#r=!!this.#r,this.#s]}#a(e){return this.#t.map((r=>{if(typeof r=="string")throw new Error("string type in extglob ast??");const[n,i,s,o]=r.toRegExpSource(e);return this.#s=this.#s||o,n})).filter((r=>!(this.isStart()&&this.isEnd()&&!r))).join("|")}static#i(e,r){let n=arguments.length>2&&arguments[2]!==void 0&&arguments[2],i=!1,s="",o=!1;for(let u=0;u<e.length;u++){const l=e.charAt(u);if(i)i=!1,s+=(zd.has(l)?"\\":"")+l;else if(l!=="\\"){if(l==="["){const[c,a,h,p]=Dd(e,u);if(h){s+=c,o=o||a,u+=h-1,r=r||p;continue}}l!=="*"?l!=="?"?s+=l.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):(s+=vn,r=!0):(s+=n&&e==="*"?oo:so,r=!0)}else u===e.length-1?s+="\\\\":i=!0}return[s,zt(e),!!r,o]}}const de=function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Pr(e),!(!r.nocomment&&e.charAt(0)==="#")&&new Ir(e,r).match(t)},Wd=/^\*+([^+@!?\*\[\(]*)$/,Gd=t=>e=>!e.startsWith(".")&&e.endsWith(t),Kd=t=>e=>e.endsWith(t),Jd=t=>(t=t.toLowerCase(),e=>!e.startsWith(".")&&e.toLowerCase().endsWith(t)),Xd=t=>(t=t.toLowerCase(),e=>e.toLowerCase().endsWith(t)),Yd=/^\*+\.\*+$/,Zd=t=>!t.startsWith(".")&&t.includes("."),Qd=t=>t!=="."&&t!==".."&&t.includes("."),ep=/^\.\*+$/,tp=t=>t!=="."&&t!==".."&&t.startsWith("."),rp=/^\*+$/,np=t=>t.length!==0&&!t.startsWith("."),ip=t=>t.length!==0&&t!=="."&&t!=="..",sp=/^\?+([^+@!?\*\[\(]*)?$/,op=t=>{let[e,r=""]=t;const n=ao([e]);return r?(r=r.toLowerCase(),i=>n(i)&&i.toLowerCase().endsWith(r)):n},ap=t=>{let[e,r=""]=t;const n=uo([e]);return r?(r=r.toLowerCase(),i=>n(i)&&i.toLowerCase().endsWith(r)):n},up=t=>{let[e,r=""]=t;const n=uo([e]);return r?i=>n(i)&&i.endsWith(r):n},lp=t=>{let[e,r=""]=t;const n=ao([e]);return r?i=>n(i)&&i.endsWith(r):n},ao=t=>{let[e]=t;const r=e.length;return n=>n.length===r&&!n.startsWith(".")},uo=t=>{let[e]=t;const r=e.length;return n=>n.length===r&&n!=="."&&n!==".."},lo=typeof Ue=="object"&&Ue?typeof Ue.env=="object"&&Ue.env&&Ue.env.__MINIMATCH_TESTING_PLATFORM__||Ue.platform:"posix";de.sep=lo==="win32"?"\\":"/";const Oe=Symbol("globstar **");de.GLOBSTAR=Oe,de.filter=function(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return r=>de(r,t,e)};const Ce=function(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Object.assign({},t,e)};de.defaults=t=>{if(!t||typeof t!="object"||!Object.keys(t).length)return de;const e=de;return Object.assign((function(r,n){return e(r,n,Ce(t,arguments.length>2&&arguments[2]!==void 0?arguments[2]:{}))}),{Minimatch:class extends e.Minimatch{constructor(r){super(r,Ce(t,arguments.length>1&&arguments[1]!==void 0?arguments[1]:{}))}static defaults(r){return e.defaults(Ce(t,r)).Minimatch}},AST:class extends e.AST{constructor(r,n){super(r,n,Ce(t,arguments.length>2&&arguments[2]!==void 0?arguments[2]:{}))}static fromGlob(r){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.AST.fromGlob(r,Ce(t,n))}},unescape:function(r){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.unescape(r,Ce(t,n))},escape:function(r){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.escape(r,Ce(t,n))},filter:function(r){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.filter(r,Ce(t,n))},defaults:r=>e.defaults(Ce(t,r)),makeRe:function(r){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.makeRe(r,Ce(t,n))},braceExpand:function(r){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e.braceExpand(r,Ce(t,n))},match:function(r,n){let i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return e.match(r,n,Ce(t,i))},sep:e.sep,GLOBSTAR:Oe})};const co=function(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Pr(t),e.nobrace||!/\{(?:(?!\{).)*\}/.test(t)?[t]:jd(t)};de.braceExpand=co,de.makeRe=function(t){return new Ir(t,arguments.length>1&&arguments[1]!==void 0?arguments[1]:{}).makeRe()},de.match=function(t,e){const r=new Ir(e,arguments.length>2&&arguments[2]!==void 0?arguments[2]:{});return t=t.filter((n=>r.match(n))),r.options.nonull&&!t.length&&t.push(e),t};const fo=/[?*]|[+@!]\(.*?\)|\[|\]/;class Ir{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;regexp;constructor(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Pr(e),r=r||{},this.options=r,this.pattern=e,this.platform=r.platform||lo,this.isWindows=this.platform==="win32",this.windowsPathsNoEscape=!!r.windowsPathsNoEscape||r.allowWindowsEscape===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!r.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!r.nonegate,this.comment=!1,this.empty=!1,this.partial=!!r.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=r.windowsNoMagicRoot!==void 0?r.windowsNoMagicRoot:!(!this.isWindows||!this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(const e of this.set)for(const r of e)if(typeof r!="string")return!0;return!1}debug(){}make(){const e=this.pattern,r=this.options;if(!r.nocomment&&e.charAt(0)==="#")return void(this.comment=!0);if(!e)return void(this.empty=!0);this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],r.debug&&(this.debug=function(){return console.error(...arguments)}),this.debug(this.pattern,this.globSet);const n=this.globSet.map((s=>this.slashSplit(s)));this.globParts=this.preprocess(n),this.debug(this.pattern,this.globParts);let i=this.globParts.map(((s,o,u)=>{if(this.isWindows&&this.windowsNoMagicRoot){const l=!(s[0]!==""||s[1]!==""||s[2]!=="?"&&fo.test(s[2])||fo.test(s[3])),c=/^[a-z]:/i.test(s[0]);if(l)return[...s.slice(0,4),...s.slice(4).map((a=>this.parse(a)))];if(c)return[s[0],...s.slice(1).map((a=>this.parse(a)))]}return s.map((l=>this.parse(l)))}));if(this.debug(this.pattern,i),this.set=i.filter((s=>s.indexOf(!1)===-1)),this.isWindows)for(let s=0;s<this.set.length;s++){const o=this.set[s];o[0]===""&&o[1]===""&&this.globParts[s][2]==="?"&&typeof o[3]=="string"&&/^[a-z]:$/i.test(o[3])&&(o[2]="?")}this.debug(this.pattern,this.set)}preprocess(e){if(this.options.noglobstar)for(let n=0;n<e.length;n++)for(let i=0;i<e[n].length;i++)e[n][i]==="**"&&(e[n][i]="*");const{optimizationLevel:r=1}=this.options;return r>=2?(e=this.firstPhasePreProcess(e),e=this.secondPhasePreProcess(e)):e=r>=1?this.levelOneOptimize(e):this.adjascentGlobstarOptimize(e),e}adjascentGlobstarOptimize(e){return e.map((r=>{let n=-1;for(;(n=r.indexOf("**",n+1))!==-1;){let i=n;for(;r[i+1]==="**";)i++;i!==n&&r.splice(n,i-n)}return r}))}levelOneOptimize(e){return e.map((r=>(r=r.reduce(((n,i)=>{const s=n[n.length-1];return i==="**"&&s==="**"?n:i===".."&&s&&s!==".."&&s!=="."&&s!=="**"?(n.pop(),n):(n.push(i),n)}),[])).length===0?[""]:r))}levelTwoFileOptimize(e){Array.isArray(e)||(e=this.slashSplit(e));let r=!1;do{if(r=!1,!this.preserveMultipleSlashes){for(let i=1;i<e.length-1;i++){const s=e[i];i===1&&s===""&&e[0]===""||s!=="."&&s!==""||(r=!0,e.splice(i,1),i--)}e[0]!=="."||e.length!==2||e[1]!=="."&&e[1]!==""||(r=!0,e.pop())}let n=0;for(;(n=e.indexOf("..",n+1))!==-1;){const i=e[n-1];i&&i!=="."&&i!==".."&&i!=="**"&&(r=!0,e.splice(n-1,2),n-=2)}}while(r);return e.length===0?[""]:e}firstPhasePreProcess(e){let r=!1;do{r=!1;for(let n of e){let i=-1;for(;(i=n.indexOf("**",i+1))!==-1;){let o=i;for(;n[o+1]==="**";)o++;o>i&&n.splice(i+1,o-i);let u=n[i+1];const l=n[i+2],c=n[i+3];if(u!==".."||!l||l==="."||l===".."||!c||c==="."||c==="..")continue;r=!0,n.splice(i,1);const a=n.slice(0);a[i]="**",e.push(a),i--}if(!this.preserveMultipleSlashes){for(let o=1;o<n.length-1;o++){const u=n[o];o===1&&u===""&&n[0]===""||u!=="."&&u!==""||(r=!0,n.splice(o,1),o--)}n[0]!=="."||n.length!==2||n[1]!=="."&&n[1]!==""||(r=!0,n.pop())}let s=0;for(;(s=n.indexOf("..",s+1))!==-1;){const o=n[s-1];if(o&&o!=="."&&o!==".."&&o!=="**"){r=!0;const u=s===1&&n[s+1]==="**"?["."]:[];n.splice(s-1,2,...u),n.length===0&&n.push(""),s-=2}}}}while(r);return e}secondPhasePreProcess(e){for(let r=0;r<e.length-1;r++)for(let n=r+1;n<e.length;n++){const i=this.partsMatch(e[r],e[n],!this.preserveMultipleSlashes);if(i){e[r]=[],e[n]=i;break}}return e.filter((r=>r.length))}partsMatch(e,r){let n=arguments.length>2&&arguments[2]!==void 0&&arguments[2],i=0,s=0,o=[],u="";for(;i<e.length&&s<r.length;)if(e[i]===r[s])o.push(u==="b"?r[s]:e[i]),i++,s++;else if(n&&e[i]==="**"&&r[s]===e[i+1])o.push(e[i]),i++;else if(n&&r[s]==="**"&&e[i]===r[s+1])o.push(r[s]),s++;else if(e[i]!=="*"||!r[s]||!this.options.dot&&r[s].startsWith(".")||r[s]==="**"){if(r[s]!=="*"||!e[i]||!this.options.dot&&e[i].startsWith(".")||e[i]==="**"||u==="a")return!1;u="b",o.push(r[s]),i++,s++}else{if(u==="b")return!1;u="a",o.push(e[i]),i++,s++}return e.length===r.length&&o}parseNegate(){if(this.nonegate)return;const e=this.pattern;let r=!1,n=0;for(let i=0;i<e.length&&e.charAt(i)==="!";i++)r=!r,n++;n&&(this.pattern=e.slice(n)),this.negate=r}matchOne(e,r){let n=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const i=this.options;if(this.isWindows){const m=typeof e[0]=="string"&&/^[a-z]:$/i.test(e[0]),y=!m&&e[0]===""&&e[1]===""&&e[2]==="?"&&/^[a-z]:$/i.test(e[3]),v=typeof r[0]=="string"&&/^[a-z]:$/i.test(r[0]),E=y?3:m?0:void 0,T=!v&&r[0]===""&&r[1]===""&&r[2]==="?"&&typeof r[3]=="string"&&/^[a-z]:$/i.test(r[3])?3:v?0:void 0;if(typeof E=="number"&&typeof T=="number"){const[N,S]=[e[E],r[T]];N.toLowerCase()===S.toLowerCase()&&(r[T]=N,T>E?r=r.slice(T):E>T&&(e=e.slice(E)))}}const{optimizationLevel:s=1}=this.options;s>=2&&(e=this.levelTwoFileOptimize(e)),this.debug("matchOne",this,{file:e,pattern:r}),this.debug("matchOne",e.length,r.length);for(var o=0,u=0,l=e.length,c=r.length;o<l&&u<c;o++,u++){this.debug("matchOne loop");var a=r[u],h=e[o];if(this.debug(r,a,h),a===!1)return!1;if(a===Oe){this.debug("GLOBSTAR",[r,a,h]);var p=o,b=u+1;if(b===c){for(this.debug("** at the end");o<l;o++)if(e[o]==="."||e[o]===".."||!i.dot&&e[o].charAt(0)===".")return!1;return!0}for(;p<l;){var g=e[p];if(this.debug(`
14
- globstar while`,e,p,r,b,g),this.matchOne(e.slice(p),r.slice(b),n))return this.debug("globstar found match!",p,l,g),!0;if(g==="."||g===".."||!i.dot&&g.charAt(0)==="."){this.debug("dot detected!",e,p,r,b);break}this.debug("globstar swallow a segment, and continue"),p++}return!(!n||(this.debug(`
15
- >>> no match, partial?`,e,p,r,b),p!==l))}let m;if(typeof a=="string"?(m=h===a,this.debug("string match",a,h,m)):(m=a.test(h),this.debug("pattern match",a,h,m)),!m)return!1}if(o===l&&u===c)return!0;if(o===l)return n;if(u===c)return o===l-1&&e[o]==="";throw new Error("wtf?")}braceExpand(){return co(this.pattern,this.options)}parse(e){Pr(e);const r=this.options;if(e==="**")return Oe;if(e==="")return"";let n,i=null;(n=e.match(rp))?i=r.dot?ip:np:(n=e.match(Wd))?i=(r.nocase?r.dot?Xd:Jd:r.dot?Kd:Gd)(n[1]):(n=e.match(sp))?i=(r.nocase?r.dot?ap:op:r.dot?up:lp)(n):(n=e.match(Yd))?i=r.dot?Qd:Zd:(n=e.match(ep))&&(i=tp);const s=ye.fromGlob(e,this.options).toMMPattern();return i&&typeof s=="object"&&Reflect.defineProperty(s,"test",{value:i}),s}makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;const e=this.set;if(!e.length)return this.regexp=!1,this.regexp;const r=this.options,n=r.noglobstar?"[^/]*?":r.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",i=new Set(r.nocase?["i"]:[]);let s=e.map((l=>{const c=l.map((a=>{if(a instanceof RegExp)for(const h of a.flags.split(""))i.add(h);return typeof a=="string"?a.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):a===Oe?Oe:a._src}));return c.forEach(((a,h)=>{const p=c[h+1],b=c[h-1];a===Oe&&b!==Oe&&(b===void 0?p!==void 0&&p!==Oe?c[h+1]="(?:\\/|"+n+"\\/)?"+p:c[h]=n:p===void 0?c[h-1]=b+"(?:\\/|"+n+")?":p!==Oe&&(c[h-1]=b+"(?:\\/|\\/"+n+"\\/)"+p,c[h+1]=Oe))})),c.filter((a=>a!==Oe)).join("/")})).join("|");const[o,u]=e.length>1?["(?:",")"]:["",""];s="^"+o+s+u+"$",this.negate&&(s="^(?!"+s+").+$");try{this.regexp=new RegExp(s,[...i].join(""))}catch{this.regexp=!1}return this.regexp}slashSplit(e){return this.preserveMultipleSlashes?e.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(e)?["",...e.split(/\/+/)]:e.split(/\/+/)}match(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.partial;if(this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&r)return!0;const n=this.options;this.isWindows&&(e=e.split("\\").join("/"));const i=this.slashSplit(e);this.debug(this.pattern,"split",i);const s=this.set;this.debug(this.pattern,"set",s);let o=i[i.length-1];if(!o)for(let u=i.length-2;!o&&u>=0;u--)o=i[u];for(let u=0;u<s.length;u++){const l=s[u];let c=i;if(n.matchBase&&l.length===1&&(c=[o]),this.matchOne(c,l,r))return!!n.flipNegate||!this.negate}return!n.flipNegate&&this.negate}static defaults(e){return de.defaults(e).Minimatch}}function Tn(t){const e=new Error(`${arguments.length>1&&arguments[1]!==void 0?arguments[1]:""}Invalid response: ${t.status} ${t.statusText}`);return e.status=t.status,e.response=t,e}function se(t,e){const{status:r}=e;if(r===401&&t.digest)return e;if(r>=400)throw Tn(e);return e}function Tt(t,e){return arguments.length>2&&arguments[2]!==void 0&&arguments[2]?{data:e,headers:t.headers?Ud(t.headers):{},status:t.status,statusText:t.statusText}:e}de.AST=ye,de.Minimatch=Ir,de.escape=function(t){let{windowsPathsNoEscape:e=!1}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return e?t.replace(/[?*()[\]]/g,"[$&]"):t.replace(/[?*()[\]\\]/g,"\\$&")},de.unescape=zt;const cp=(ho=function(t,e,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const i=ie({url:G(t.remoteURL,W(e)),method:"COPY",headers:{Destination:G(t.remoteURL,W(r)),Overwrite:n.overwrite===!1?"F":"T",Depth:n.shallow?"0":"infinity"}},t,n);return o=function(u){se(t,u)},(s=ne(i,t))&&s.then||(s=Promise.resolve(s)),o?s.then(o):s;var s,o},function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];try{return Promise.resolve(ho.apply(this,t))}catch(r){return Promise.reject(r)}});var ho;const fp={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(t,e){return e},attributeValueProcessor:function(t,e){return e},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(t,e,r){return t},captureMetaData:!1},po=":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",hp=new RegExp("^["+po+"]["+po+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$");function go(t,e){const r=[];let n=e.exec(t);for(;n;){const i=[];i.startIndex=e.lastIndex-n[0].length;const s=n.length;for(let o=0;o<s;o++)i.push(n[o]);r.push(i),n=e.exec(t)}return r}const Sr=function(t){return hp.exec(t)!=null};let An;An=typeof Symbol!="function"?"@@xmlMetadata":Symbol("XML Node Metadata");class ct{constructor(e){this.tagname=e,this.child=[],this[":@"]={}}add(e,r){e==="__proto__"&&(e="#__proto__"),this.child.push({[e]:r})}addChild(e,r){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}),r!==void 0&&(this.child[this.child.length-1][An]={startIndex:r})}static getMetaDataSymbol(){return An}}class dp{constructor(e){this.suppressValidationErr=!e}readDocType(e,r){const n={};if(e[r+3]!=="O"||e[r+4]!=="C"||e[r+5]!=="T"||e[r+6]!=="Y"||e[r+7]!=="P"||e[r+8]!=="E")throw new Error("Invalid Tag instead of DOCTYPE");{r+=9;let i=1,s=!1,o=!1,u="";for(;r<e.length;r++)if(e[r]!=="<"||o)if(e[r]===">"){if(o?e[r-1]==="-"&&e[r-2]==="-"&&(o=!1,i--):i--,i===0)break}else e[r]==="["?s=!0:u+=e[r];else{if(s&&ft(e,"!ENTITY",r)){let l,c;r+=7,[l,c,r]=this.readEntityExp(e,r+1,this.suppressValidationErr),c.indexOf("&")===-1&&(n[l]={regx:RegExp(`&${l};`,"g"),val:c})}else if(s&&ft(e,"!ELEMENT",r)){r+=8;const{index:l}=this.readElementExp(e,r+1);r=l}else if(s&&ft(e,"!ATTLIST",r))r+=8;else if(s&&ft(e,"!NOTATION",r)){r+=9;const{index:l}=this.readNotationExp(e,r+1,this.suppressValidationErr);r=l}else{if(!ft(e,"!--",r))throw new Error("Invalid DOCTYPE");o=!0}i++,u=""}if(i!==0)throw new Error("Unclosed DOCTYPE")}return{entities:n,i:r}}readEntityExp(e,r){r=Ae(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r])&&e[r]!=='"'&&e[r]!=="'";)n+=e[r],r++;if(Wt(n),r=Ae(e,r),!this.suppressValidationErr){if(e.substring(r,r+6).toUpperCase()==="SYSTEM")throw new Error("External entities are not supported");if(e[r]==="%")throw new Error("Parameter entities are not supported")}let i="";return[r,i]=this.readIdentifierVal(e,r,"entity"),[n,i,--r]}readNotationExp(e,r){r=Ae(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r]);)n+=e[r],r++;!this.suppressValidationErr&&Wt(n),r=Ae(e,r);const i=e.substring(r,r+6).toUpperCase();if(!this.suppressValidationErr&&i!=="SYSTEM"&&i!=="PUBLIC")throw new Error(`Expected SYSTEM or PUBLIC, found "${i}"`);r+=i.length,r=Ae(e,r);let s=null,o=null;if(i==="PUBLIC")[r,s]=this.readIdentifierVal(e,r,"publicIdentifier"),e[r=Ae(e,r)]!=='"'&&e[r]!=="'"||([r,o]=this.readIdentifierVal(e,r,"systemIdentifier"));else if(i==="SYSTEM"&&([r,o]=this.readIdentifierVal(e,r,"systemIdentifier"),!this.suppressValidationErr&&!o))throw new Error("Missing mandatory system identifier for SYSTEM notation");return{notationName:n,publicIdentifier:s,systemIdentifier:o,index:--r}}readIdentifierVal(e,r,n){let i="";const s=e[r];if(s!=='"'&&s!=="'")throw new Error(`Expected quoted string, found "${s}"`);for(r++;r<e.length&&e[r]!==s;)i+=e[r],r++;if(e[r]!==s)throw new Error(`Unterminated ${n} value`);return[++r,i]}readElementExp(e,r){r=Ae(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r]);)n+=e[r],r++;if(!this.suppressValidationErr&&!Sr(n))throw new Error(`Invalid element name: "${n}"`);let i="";if(e[r=Ae(e,r)]==="E"&&ft(e,"MPTY",r))r+=4;else if(e[r]==="A"&&ft(e,"NY",r))r+=2;else if(e[r]==="("){for(r++;r<e.length&&e[r]!==")";)i+=e[r],r++;if(e[r]!==")")throw new Error("Unterminated content model")}else if(!this.suppressValidationErr)throw new Error(`Invalid Element Expression, found "${e[r]}"`);return{elementName:n,contentModel:i.trim(),index:r}}readAttlistExp(e,r){r=Ae(e,r);let n="";for(;r<e.length&&!/\s/.test(e[r]);)n+=e[r],r++;Wt(n),r=Ae(e,r);let i="";for(;r<e.length&&!/\s/.test(e[r]);)i+=e[r],r++;if(!Wt(i))throw new Error(`Invalid attribute name: "${i}"`);r=Ae(e,r);let s="";if(e.substring(r,r+8).toUpperCase()==="NOTATION"){if(s="NOTATION",e[r=Ae(e,r+=8)]!=="(")throw new Error(`Expected '(', found "${e[r]}"`);r++;let u=[];for(;r<e.length&&e[r]!==")";){let l="";for(;r<e.length&&e[r]!=="|"&&e[r]!==")";)l+=e[r],r++;if(l=l.trim(),!Wt(l))throw new Error(`Invalid notation name: "${l}"`);u.push(l),e[r]==="|"&&(r++,r=Ae(e,r))}if(e[r]!==")")throw new Error("Unterminated list of notations");r++,s+=" ("+u.join("|")+")"}else{for(;r<e.length&&!/\s/.test(e[r]);)s+=e[r],r++;const u=["CDATA","ID","IDREF","IDREFS","ENTITY","ENTITIES","NMTOKEN","NMTOKENS"];if(!this.suppressValidationErr&&!u.includes(s.toUpperCase()))throw new Error(`Invalid attribute type: "${s}"`)}r=Ae(e,r);let o="";return e.substring(r,r+8).toUpperCase()==="#REQUIRED"?(o="#REQUIRED",r+=8):e.substring(r,r+7).toUpperCase()==="#IMPLIED"?(o="#IMPLIED",r+=7):[r,o]=this.readIdentifierVal(e,r,"ATTLIST"),{elementName:n,attributeName:i,attributeType:s,defaultValue:o,index:r}}}const Ae=(t,e)=>{for(;e<t.length&&/\s/.test(t[e]);)e++;return e};function ft(t,e,r){for(let n=0;n<e.length;n++)if(e[n]!==t[r+n+1])return!1;return!0}function Wt(t){if(Sr(t))return t;throw new Error(`Invalid entity name ${t}`)}const pp=/^[-+]?0x[a-fA-F0-9]+$/,gp=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,mp={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0},yp=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function mo(t){return typeof t=="function"?t:Array.isArray(t)?e=>{for(const r of t)if(typeof r=="string"&&e===r||r instanceof RegExp&&r.test(e))return!0}:()=>!1}class bp{constructor(e){if(this.options=e,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(r,n)=>bo(n,10,"&#")},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(r,n)=>bo(n,16,"&#x")}},this.addExternalEntities=wp,this.parseXml=Ap,this.parseTextData=xp,this.resolveNameSpace=Ep,this.buildAttributesMap=Tp,this.isItStopNode=Sp,this.replaceEntitiesValue=Pp,this.readStopNodeData=Op,this.saveTextToParentTag=Ip,this.addChild=Np,this.ignoreAttributesFn=mo(this.options.ignoreAttributes),this.options.stopNodes&&this.options.stopNodes.length>0){this.stopNodesExact=new Set,this.stopNodesWildcard=new Set;for(let r=0;r<this.options.stopNodes.length;r++){const n=this.options.stopNodes[r];typeof n=="string"&&(n.startsWith("*.")?this.stopNodesWildcard.add(n.substring(2)):this.stopNodesExact.add(n))}}}}function wp(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r];this.lastEntities[n]={regex:new RegExp("&"+n+";","g"),val:t[n]}}}function xp(t,e,r,n,i,s,o){if(t!==void 0&&(this.options.trimValues&&!n&&(t=t.trim()),t.length>0)){o||(t=this.replaceEntitiesValue(t));const u=this.options.tagValueProcessor(e,t,r,i,s);return u==null?t:typeof u!=typeof t||u!==t?u:this.options.trimValues||t.trim()===t?yo(t,this.options.parseTagValue,this.options.numberParseOptions):t}}function Ep(t){if(this.options.removeNSPrefix){const e=t.split(":"),r=t.charAt(0)==="/"?"/":"";if(e[0]==="xmlns")return"";e.length===2&&(t=r+e[1])}return t}const vp=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function Tp(t,e){if(this.options.ignoreAttributes!==!0&&typeof t=="string"){const r=go(t,vp),n=r.length,i={};for(let s=0;s<n;s++){const o=this.resolveNameSpace(r[s][1]);if(this.ignoreAttributesFn(o,e))continue;let u=r[s][4],l=this.options.attributeNamePrefix+o;if(o.length)if(this.options.transformAttributeName&&(l=this.options.transformAttributeName(l)),l==="__proto__"&&(l="#__proto__"),u!==void 0){this.options.trimValues&&(u=u.trim()),u=this.replaceEntitiesValue(u);const c=this.options.attributeValueProcessor(o,u,e);i[l]=c==null?u:typeof c!=typeof u||c!==u?c:yo(u,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(i[l]=!0)}if(!Object.keys(i).length)return;if(this.options.attributesGroupName){const s={};return s[this.options.attributesGroupName]=i,s}return i}}const Ap=function(t){t=t.replace(/\r\n?/g,`
16
- `);const e=new ct("!xml");let r=e,n="",i="";const s=new dp(this.options.processEntities);for(let o=0;o<t.length;o++)if(t[o]==="<")if(t[o+1]==="/"){const u=ht(t,">",o,"Closing Tag is not closed.");let l=t.substring(o+2,u).trim();if(this.options.removeNSPrefix){const h=l.indexOf(":");h!==-1&&(l=l.substr(h+1))}this.options.transformTagName&&(l=this.options.transformTagName(l)),r&&(n=this.saveTextToParentTag(n,r,i));const c=i.substring(i.lastIndexOf(".")+1);if(l&&this.options.unpairedTags.indexOf(l)!==-1)throw new Error(`Unpaired tag can not be used as closing tag: </${l}>`);let a=0;c&&this.options.unpairedTags.indexOf(c)!==-1?(a=i.lastIndexOf(".",i.lastIndexOf(".")-1),this.tagsNodeStack.pop()):a=i.lastIndexOf("."),i=i.substring(0,a),r=this.tagsNodeStack.pop(),n="",o=u}else if(t[o+1]==="?"){let u=Nn(t,o,!1,"?>");if(!u)throw new Error("Pi Tag is not closed.");if(n=this.saveTextToParentTag(n,r,i),!(this.options.ignoreDeclaration&&u.tagName==="?xml"||this.options.ignorePiTags)){const l=new ct(u.tagName);l.add(this.options.textNodeName,""),u.tagName!==u.tagExp&&u.attrExpPresent&&(l[":@"]=this.buildAttributesMap(u.tagExp,i)),this.addChild(r,l,i,o)}o=u.closeIndex+1}else if(t.substr(o+1,3)==="!--"){const u=ht(t,"-->",o+4,"Comment is not closed.");if(this.options.commentPropName){const l=t.substring(o+4,u-2);n=this.saveTextToParentTag(n,r,i),r.add(this.options.commentPropName,[{[this.options.textNodeName]:l}])}o=u}else if(t.substr(o+1,2)==="!D"){const u=s.readDocType(t,o);this.docTypeEntities=u.entities,o=u.i}else if(t.substr(o+1,2)==="!["){const u=ht(t,"]]>",o,"CDATA is not closed.")-2,l=t.substring(o+9,u);n=this.saveTextToParentTag(n,r,i);let c=this.parseTextData(l,r.tagname,i,!0,!1,!0,!0);c==null&&(c=""),this.options.cdataPropName?r.add(this.options.cdataPropName,[{[this.options.textNodeName]:l}]):r.add(this.options.textNodeName,c),o=u+2}else{let u=Nn(t,o,this.options.removeNSPrefix),l=u.tagName;const c=u.rawTagName;let a=u.tagExp,h=u.attrExpPresent,p=u.closeIndex;if(this.options.transformTagName){const m=this.options.transformTagName(l);a===l&&(a=m),l=m}r&&n&&r.tagname!=="!xml"&&(n=this.saveTextToParentTag(n,r,i,!1));const b=r;b&&this.options.unpairedTags.indexOf(b.tagname)!==-1&&(r=this.tagsNodeStack.pop(),i=i.substring(0,i.lastIndexOf("."))),l!==e.tagname&&(i+=i?"."+l:l);const g=o;if(this.isItStopNode(this.stopNodesExact,this.stopNodesWildcard,i,l)){let m="";if(a.length>0&&a.lastIndexOf("/")===a.length-1)l[l.length-1]==="/"?(l=l.substr(0,l.length-1),i=i.substr(0,i.length-1),a=l):a=a.substr(0,a.length-1),o=u.closeIndex;else if(this.options.unpairedTags.indexOf(l)!==-1)o=u.closeIndex;else{const v=this.readStopNodeData(t,c,p+1);if(!v)throw new Error(`Unexpected end of ${c}`);o=v.i,m=v.tagContent}const y=new ct(l);l!==a&&h&&(y[":@"]=this.buildAttributesMap(a,i)),m&&(m=this.parseTextData(m,l,i,!0,h,!0,!0)),i=i.substr(0,i.lastIndexOf(".")),y.add(this.options.textNodeName,m),this.addChild(r,y,i,g)}else{if(a.length>0&&a.lastIndexOf("/")===a.length-1){if(l[l.length-1]==="/"?(l=l.substr(0,l.length-1),i=i.substr(0,i.length-1),a=l):a=a.substr(0,a.length-1),this.options.transformTagName){const y=this.options.transformTagName(l);a===l&&(a=y),l=y}const m=new ct(l);l!==a&&h&&(m[":@"]=this.buildAttributesMap(a,i)),this.addChild(r,m,i,g),i=i.substr(0,i.lastIndexOf("."))}else{const m=new ct(l);this.tagsNodeStack.push(r),l!==a&&h&&(m[":@"]=this.buildAttributesMap(a,i)),this.addChild(r,m,i,g),r=m}n="",o=p}}else n+=t[o];return e.child};function Np(t,e,r,n){this.options.captureMetaData||(n=void 0);const i=this.options.updateTag(e.tagname,r,e[":@"]);i===!1||(typeof i=="string"&&(e.tagname=i),t.addChild(e,n))}const Pp=function(t){if(this.options.processEntities){for(let e in this.docTypeEntities){const r=this.docTypeEntities[e];t=t.replace(r.regx,r.val)}for(let e in this.lastEntities){const r=this.lastEntities[e];t=t.replace(r.regex,r.val)}if(this.options.htmlEntities)for(let e in this.htmlEntities){const r=this.htmlEntities[e];t=t.replace(r.regex,r.val)}t=t.replace(this.ampEntity.regex,this.ampEntity.val)}return t};function Ip(t,e,r,n){return t&&(n===void 0&&(n=e.child.length===0),(t=this.parseTextData(t,e.tagname,r,!1,!!e[":@"]&&Object.keys(e[":@"]).length!==0,n))!==void 0&&t!==""&&e.add(this.options.textNodeName,t),t=""),t}function Sp(t,e,r,n){return!(!e||!e.has(n))||!(!t||!t.has(r))}function ht(t,e,r,n){const i=t.indexOf(e,r);if(i===-1)throw new Error(n);return i+e.length-1}function Nn(t,e,r){const n=(function(a,h){let p,b=arguments.length>2&&arguments[2]!==void 0?arguments[2]:">",g="";for(let m=h;m<a.length;m++){let y=a[m];if(p)y===p&&(p="");else if(y==='"'||y==="'")p=y;else if(y===b[0]){if(!b[1])return{data:g,index:m};if(a[m+1]===b[1])return{data:g,index:m}}else y===" "&&(y=" ");g+=y}})(t,e+1,arguments.length>3&&arguments[3]!==void 0?arguments[3]:">");if(!n)return;let i=n.data;const s=n.index,o=i.search(/\s/);let u=i,l=!0;o!==-1&&(u=i.substring(0,o),i=i.substring(o+1).trimStart());const c=u;if(r){const a=u.indexOf(":");a!==-1&&(u=u.substr(a+1),l=u!==n.data.substr(a+1))}return{tagName:u,tagExp:i,closeIndex:s,attrExpPresent:l,rawTagName:c}}function Op(t,e,r){const n=r;let i=1;for(;r<t.length;r++)if(t[r]==="<")if(t[r+1]==="/"){const s=ht(t,">",r,`${e} is not closed`);if(t.substring(r+2,s).trim()===e&&(i--,i===0))return{tagContent:t.substring(n,r),i:s};r=s}else if(t[r+1]==="?")r=ht(t,"?>",r+1,"StopNode is not closed.");else if(t.substr(r+1,3)==="!--")r=ht(t,"-->",r+3,"StopNode is not closed.");else if(t.substr(r+1,2)==="![")r=ht(t,"]]>",r,"StopNode is not closed.")-2;else{const s=Nn(t,r,">");s&&((s&&s.tagName)===e&&s.tagExp[s.tagExp.length-1]!=="/"&&i++,r=s.closeIndex)}}function yo(t,e,r){if(e&&typeof t=="string"){const n=t.trim();return n==="true"||n!=="false"&&(function(i){let s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(s=Object.assign({},mp,s),!i||typeof i!="string")return i;let o=i.trim();if(s.skipLike!==void 0&&s.skipLike.test(o))return i;if(i==="0")return 0;if(s.hex&&pp.test(o))return(function(l){if(parseInt)return parseInt(l,16);if(Number.parseInt)return Number.parseInt(l,16);if(window&&window.parseInt)return window.parseInt(l,16);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")})(o);if(o.includes("e")||o.includes("E"))return(function(l,c,a){if(!a.eNotation)return l;const h=c.match(yp);if(h){let p=h[1]||"";const b=h[3].indexOf("e")===-1?"E":"e",g=h[2],m=p?l[g.length+1]===b:l[g.length]===b;return g.length>1&&m?l:g.length!==1||!h[3].startsWith(`.${b}`)&&h[3][0]!==b?a.leadingZeros&&!m?(c=(h[1]||"")+h[3],Number(c)):l:Number(c)}return l})(i,o,s);{const l=gp.exec(o);if(l){const c=l[1]||"",a=l[2];let h=((u=l[3])&&u.indexOf(".")!==-1&&((u=u.replace(/0+$/,""))==="."?u="0":u[0]==="."?u="0"+u:u[u.length-1]==="."&&(u=u.substring(0,u.length-1))),u);const p=c?i[a.length+1]===".":i[a.length]===".";if(!s.leadingZeros&&(a.length>1||a.length===1&&!p))return i;{const b=Number(o),g=String(b);if(b===0)return b;if(g.search(/[eE]/)!==-1)return s.eNotation?b:i;if(o.indexOf(".")!==-1)return g==="0"||g===h||g===`${c}${h}`?b:i;let m=a?h:o;return a?m===g||c+m===g?b:i:m===g||m===c+g?b:i}}return i}var u})(t,r)}return t!==void 0?t:""}function bo(t,e,r){const n=Number.parseInt(t,e);return n>=0&&n<=1114111?String.fromCodePoint(n):r+t+";"}const Pn=ct.getMetaDataSymbol();function Cp(t,e){return wo(t,e)}function wo(t,e,r){let n;const i={};for(let s=0;s<t.length;s++){const o=t[s],u=Rp(o);let l="";if(l=r===void 0?u:r+"."+u,u===e.textNodeName)n===void 0?n=o[u]:n+=""+o[u];else{if(u===void 0)continue;if(o[u]){let c=wo(o[u],e,l);const a=Lp(c,e);o[Pn]!==void 0&&(c[Pn]=o[Pn]),o[":@"]?Fp(c,o[":@"],l,e):Object.keys(c).length!==1||c[e.textNodeName]===void 0||e.alwaysCreateTextNode?Object.keys(c).length===0&&(e.alwaysCreateTextNode?c[e.textNodeName]="":c=""):c=c[e.textNodeName],i[u]!==void 0&&i.hasOwnProperty(u)?(Array.isArray(i[u])||(i[u]=[i[u]]),i[u].push(c)):e.isArray(u,l,a)?i[u]=[c]:i[u]=c}}}return typeof n=="string"?n.length>0&&(i[e.textNodeName]=n):n!==void 0&&(i[e.textNodeName]=n),i}function Rp(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r];if(n!==":@")return n}}function Fp(t,e,r,n){if(e){const i=Object.keys(e),s=i.length;for(let o=0;o<s;o++){const u=i[o];n.isArray(u,r+"."+u,!0,!0)?t[u]=[e[u]]:t[u]=e[u]}}}function Lp(t,e){const{textNodeName:r}=e,n=Object.keys(t).length;return n===0||!(n!==1||!t[r]&&typeof t[r]!="boolean"&&t[r]!==0)}const _p={allowBooleanAttributes:!1,unpairedTags:[]};function xo(t){return t===" "||t===" "||t===`
17
- `||t==="\r"}function Eo(t,e){const r=e;for(;e<t.length;e++)if(!(t[e]!="?"&&t[e]!=" ")){const n=t.substr(r,e-r);if(e>5&&n==="xml")return te("InvalidXml","XML declaration allowed only at the start of the document.",be(t,e));if(t[e]=="?"&&t[e+1]==">"){e++;break}}return e}function vo(t,e){if(t.length>e+5&&t[e+1]==="-"&&t[e+2]==="-"){for(e+=3;e<t.length;e++)if(t[e]==="-"&&t[e+1]==="-"&&t[e+2]===">"){e+=2;break}}else if(t.length>e+8&&t[e+1]==="D"&&t[e+2]==="O"&&t[e+3]==="C"&&t[e+4]==="T"&&t[e+5]==="Y"&&t[e+6]==="P"&&t[e+7]==="E"){let r=1;for(e+=8;e<t.length;e++)if(t[e]==="<")r++;else if(t[e]===">"&&(r--,r===0))break}else if(t.length>e+9&&t[e+1]==="["&&t[e+2]==="C"&&t[e+3]==="D"&&t[e+4]==="A"&&t[e+5]==="T"&&t[e+6]==="A"&&t[e+7]==="["){for(e+=8;e<t.length;e++)if(t[e]==="]"&&t[e+1]==="]"&&t[e+2]===">"){e+=2;break}}return e}function Up(t,e){let r="",n="",i=!1;for(;e<t.length;e++){if(t[e]==='"'||t[e]==="'")n===""?n=t[e]:n!==t[e]||(n="");else if(t[e]===">"&&n===""){i=!0;break}r+=t[e]}return n===""&&{value:r,index:e,tagClosed:i}}const Bp=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function To(t,e){const r=go(t,Bp),n={};for(let i=0;i<r.length;i++){if(r[i][1].length===0)return te("InvalidAttr","Attribute '"+r[i][2]+"' has no space in starting.",Gt(r[i]));if(r[i][3]!==void 0&&r[i][4]===void 0)return te("InvalidAttr","Attribute '"+r[i][2]+"' is without value.",Gt(r[i]));if(r[i][3]===void 0&&!e.allowBooleanAttributes)return te("InvalidAttr","boolean attribute '"+r[i][2]+"' is not allowed.",Gt(r[i]));const s=r[i][2];if(!$p(s))return te("InvalidAttr","Attribute '"+s+"' is an invalid name.",Gt(r[i]));if(n.hasOwnProperty(s))return te("InvalidAttr","Attribute '"+s+"' is repeated.",Gt(r[i]));n[s]=1}return!0}function kp(t,e){if(t[++e]===";")return-1;if(t[e]==="#")return(function(n,i){let s=/\d/;for(n[i]==="x"&&(i++,s=/[\da-fA-F]/);i<n.length;i++){if(n[i]===";")return i;if(!n[i].match(s))break}return-1})(t,++e);let r=0;for(;e<t.length;e++,r++)if(!(t[e].match(/\w/)&&r<20)){if(t[e]===";")break;return-1}return e}function te(t,e,r){return{err:{code:t,msg:e,line:r.line||r,col:r.col}}}function $p(t){return Sr(t)}function be(t,e){const r=t.substring(0,e).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}function Gt(t){return t.startIndex+t[1].length}class Ao{constructor(e){this.externalEntities={},this.options=(function(r){return Object.assign({},fp,r)})(e)}parse(e,r){if(typeof e!="string"&&e.toString)e=e.toString();else if(typeof e!="string")throw new Error("XML data is accepted in String or Bytes[] form.");if(r){r===!0&&(r={});const s=(function(o,u){u=Object.assign({},_p,u);const l=[];let c=!1,a=!1;o[0]==="\uFEFF"&&(o=o.substr(1));for(let h=0;h<o.length;h++)if(o[h]==="<"&&o[h+1]==="?"){if(h+=2,h=Eo(o,h),h.err)return h}else{if(o[h]!=="<"){if(xo(o[h]))continue;return te("InvalidChar","char '"+o[h]+"' is not expected.",be(o,h))}{let p=h;if(h++,o[h]==="!"){h=vo(o,h);continue}{let b=!1;o[h]==="/"&&(b=!0,h++);let g="";for(;h<o.length&&o[h]!==">"&&o[h]!==" "&&o[h]!==" "&&o[h]!==`
18
- `&&o[h]!=="\r";h++)g+=o[h];if(g=g.trim(),g[g.length-1]==="/"&&(g=g.substring(0,g.length-1),h--),!Sr(g)){let v;return v=g.trim().length===0?"Invalid space after '<'.":"Tag '"+g+"' is an invalid name.",te("InvalidTag",v,be(o,h))}const m=Up(o,h);if(m===!1)return te("InvalidAttr","Attributes for '"+g+"' have open quote.",be(o,h));let y=m.value;if(h=m.index,y[y.length-1]==="/"){const v=h-y.length;y=y.substring(0,y.length-1);const E=To(y,u);if(E!==!0)return te(E.err.code,E.err.msg,be(o,v+E.err.line));c=!0}else if(b){if(!m.tagClosed)return te("InvalidTag","Closing tag '"+g+"' doesn't have proper closing.",be(o,h));if(y.trim().length>0)return te("InvalidTag","Closing tag '"+g+"' can't have attributes or invalid starting.",be(o,p));if(l.length===0)return te("InvalidTag","Closing tag '"+g+"' has not been opened.",be(o,p));{const v=l.pop();if(g!==v.tagName){let E=be(o,v.tagStartPos);return te("InvalidTag","Expected closing tag '"+v.tagName+"' (opened in line "+E.line+", col "+E.col+") instead of closing tag '"+g+"'.",be(o,p))}l.length==0&&(a=!0)}}else{const v=To(y,u);if(v!==!0)return te(v.err.code,v.err.msg,be(o,h-y.length+v.err.line));if(a===!0)return te("InvalidXml","Multiple possible root nodes found.",be(o,h));u.unpairedTags.indexOf(g)!==-1||l.push({tagName:g,tagStartPos:p}),c=!0}for(h++;h<o.length;h++)if(o[h]==="<"){if(o[h+1]==="!"){h++,h=vo(o,h);continue}if(o[h+1]!=="?")break;if(h=Eo(o,++h),h.err)return h}else if(o[h]==="&"){const v=kp(o,h);if(v==-1)return te("InvalidChar","char '&' is not expected.",be(o,h));h=v}else if(a===!0&&!xo(o[h]))return te("InvalidXml","Extra text at the end",be(o,h));o[h]==="<"&&h--}}}return c?l.length==1?te("InvalidTag","Unclosed tag '"+l[0].tagName+"'.",be(o,l[0].tagStartPos)):!(l.length>0)||te("InvalidXml","Invalid '"+JSON.stringify(l.map((h=>h.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):te("InvalidXml","Start tag expected.",1)})(e,r);if(s!==!0)throw Error(`${s.err.msg}:${s.err.line}:${s.err.col}`)}const n=new bp(this.options);n.addExternalEntities(this.externalEntities);const i=n.parseXml(e);return this.options.preserveOrder||i===void 0?i:Cp(i,this.options)}addEntity(e,r){if(r.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(e.indexOf("&")!==-1||e.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '&#xD;'");if(r==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[e]=r}static getMetaDataSymbol(){return ct.getMetaDataSymbol()}}var jp=H(829),We=H.n(jp),At=(function(t){return t.Array="array",t.Object="object",t.Original="original",t})(At||{});function No(t,e){if(!t.endsWith("propstat.prop.displayname"))return e}function Or(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:At.Original;const n=We().get(t,e);return r==="array"&&Array.isArray(n)===!1?[n]:r==="object"&&Array.isArray(n)?n[0]:n}function Kt(t,e){return e=e??{attributeNamePrefix:"@",attributeParsers:[],tagParsers:[No]},new Promise((r=>{r((function(n){const{multistatus:i}=n;if(i==="")return{multistatus:{response:[]}};if(!i)throw new Error("Invalid response: No root multistatus found");const s={multistatus:Array.isArray(i)?i[0]:i};return We().set(s,"multistatus.response",Or(s,"multistatus.response",At.Array)),We().set(s,"multistatus.response",We().get(s,"multistatus.response").map((o=>(function(u){const l=Object.assign({},u);return l.status?We().set(l,"status",Or(l,"status",At.Object)):(We().set(l,"propstat",Or(l,"propstat",At.Object)),We().set(l,"propstat.prop",Or(l,"propstat.prop",At.Object))),l})(o)))),s})((function(n){let{attributeNamePrefix:i,attributeParsers:s,tagParsers:o}=n;return new Ao({allowBooleanAttributes:!0,attributeNamePrefix:i,textNodeName:"text",ignoreAttributes:!1,removeNSPrefix:!0,numberParseOptions:{hex:!0,leadingZeros:!1},attributeValueProcessor(u,l,c){for(const a of s)try{const h=a(c,l);if(h!==l)return h}catch{}return l},tagValueProcessor(u,l,c){for(const a of o)try{const h=a(c,l);if(h!==l)return h}catch{}return l}})})(e).parse(t)))}))}function Cr(t,e){let r=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const{getlastmodified:n=null,getcontentlength:i="0",resourcetype:s=null,getcontenttype:o=null,getetag:u=null}=t,l=s&&typeof s=="object"&&s.collection!==void 0?"directory":"file",c={filename:e,basename:Tr().basename(e),lastmod:n,size:parseInt(i,10),type:l,etag:typeof u=="string"?u.replace(/"/g,""):null};return l==="file"&&(c.mime=o&&typeof o=="string"?o.split(";")[0]:""),r&&(t.displayname!==void 0&&(t.displayname=String(t.displayname)),c.props=t),c}function Mp(t,e){let r=arguments.length>2&&arguments[2]!==void 0&&arguments[2],n=null;try{t.multistatus.response[0].propstat&&(n=t.multistatus.response[0])}catch{}if(!n)throw new Error("Failed getting item stat: bad response");const{propstat:{prop:i,status:s}}=n,[o,u,l]=s.split(" ",3),c=parseInt(u,10);if(c>=400){const a=new Error(`Invalid response: ${c} ${l}`);throw a.status=c,a}return Cr(i,Vt(e),r)}function Dp(t){switch(String(t)){case"-3":return"unlimited";case"-2":case"-1":return"unknown";default:return parseInt(String(t),10)}}function In(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const Sn=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const{details:n=!1}=r,i=ie({url:G(t.remoteURL,W(e)),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:"0"}},t,r);return In(ne(i,t),(function(s){return se(t,s),In(s.text(),(function(o){return In(Kt(o,t.parsing),(function(u){const l=Mp(u,e,n);return Tt(s,l,n)}))}))}))}));function Po(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const Vp=Io((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=(function(s){if(!s||s==="/")return[];let o=s;const u=[];do u.push(o),o=Tr().dirname(o);while(o&&o!=="/");return u})(Vt(e));n.sort(((s,o)=>s.length>o.length?1:o.length>s.length?-1:0));let i=!1;return(function(s,o,u){if(typeof s[Oo]=="function"){let m=function(y){try{for(;!(l=h.next()).done;)if((y=o(l.value))&&y.then){if(!Co(y))return void y.then(m,a||(a=we.bind(null,c=new Nt,2)));y=y.v}c?we(c,1,y):c=y}catch(v){we(c||(c=new Nt),2,v)}};var l,c,a,h=s[Oo]();if(m(),h.return){var p=function(y){try{l.done||h.return()}catch{}return y};if(c&&c.then)return c.then(p,(function(y){throw p(y)}));p()}return c}if(!("length"in s))throw new TypeError("Object is not iterable");for(var b=[],g=0;g<s.length;g++)b.push(s[g]);return(function(m,y,v){var E,T,N=-1;return(function S(F){try{for(;++N<m.length&&(!v||!v());)if((F=y(N))&&F.then){if(!Co(F))return void F.then(S,T||(T=we.bind(null,E=new Nt,2)));F=F.v}E?we(E,1,F):E=F}catch(L){we(E||(E=new Nt),2,L)}})(),E})(b,(function(m){return o(b[m])}),u)})(n,(function(s){return o=function(){return(function(l,c){try{var a=Po(Sn(t,s),(function(h){if(h.type!=="directory")throw new Error(`Path includes a file: ${e}`)}))}catch(h){return c(h)}return a&&a.then?a.then(void 0,c):a})(0,(function(l){const c=l;return(function(){if(c.status===404)return i=!0,So(On(t,s,{...r,recursive:!1}));throw l})()}))},(u=(function(){if(i)return So(On(t,s,{...r,recursive:!1}))})())&&u.then?u.then(o):o();var o,u}),(function(){return!1}))}));function Io(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}}function Hp(){}function So(t,e){return t&&t.then?t.then(Hp):Promise.resolve()}const Oo=typeof Symbol<"u"?Symbol.iterator||(Symbol.iterator=Symbol("Symbol.iterator")):"@@iterator";function we(t,e,r){if(!t.s){if(r instanceof Nt){if(!r.s)return void(r.o=we.bind(null,t,e));1&e&&(e=r.s),r=r.v}if(r&&r.then)return void r.then(we.bind(null,t,e),we.bind(null,t,2));t.s=e,t.v=r;const n=t.o;n&&n(t)}}const Nt=(function(){function t(){}return t.prototype.then=function(e,r){const n=new t,i=this.s;if(i){const s=1&i?e:r;if(s){try{we(n,1,s(this.v))}catch(o){we(n,2,o)}return n}return this}return this.o=function(s){try{const o=s.v;1&s.s?we(n,1,e?e(o):o):r?we(n,1,r(o)):we(n,2,o)}catch(o){we(n,2,o)}},n},t})();function Co(t){return t instanceof Nt&&1&t.s}const On=Io((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(r.recursive===!0)return Vp(t,e,r);const n=ie({url:G(t.remoteURL,(i=W(e),i.endsWith("/")?i:i+"/")),method:"MKCOL"},t,r);var i;return Po(ne(n,t),(function(s){se(t,s)}))}));var qp=H(388),Ro=H.n(qp);const zp=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n={};if(typeof r.range=="object"&&typeof r.range.start=="number"){let u=`bytes=${r.range.start}-`;typeof r.range.end=="number"&&(u=`${u}${r.range.end}`),n.Range=u}const i=ie({url:G(t.remoteURL,W(e)),method:"GET",headers:n},t,r);return o=function(u){if(se(t,u),n.Range&&u.status!==206){const l=new Error(`Invalid response code for partial request: ${u.status}`);throw l.status=u.status,l}return r.callback&&setTimeout((()=>{r.callback(u)}),0),u.body},(s=ne(i,t))&&s.then||(s=Promise.resolve(s)),o?s.then(o):s;var s,o})),Wp=()=>{},Gp=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e,r){r.url||(r.url=G(t.remoteURL,W(e)));const n=ie(r,t,{});return s=function(o){return se(t,o),o},(i=ne(n,t))&&i.then||(i=Promise.resolve(i)),s?i.then(s):i;var i,s})),Kp=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=ie({url:G(t.remoteURL,W(e)),method:"DELETE"},t,r);return s=function(o){se(t,o)},(i=ne(n,t))&&i.then||(i=Promise.resolve(i)),s?i.then(s):i;var i,s})),Jp=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return(function(n,i){try{var s=(o=Sn(t,e,r),u=function(){return!0},l?u?u(o):o:(o&&o.then||(o=Promise.resolve(o)),u?o.then(u):o))}catch(c){return i(c)}var o,u,l;return s&&s.then?s.then(void 0,i):s})(0,(function(n){if(n.status===404)return!1;throw n}))}));function Cn(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const Xp=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=ie({url:G(t.remoteURL,W(e),"/"),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:r.deep?"infinity":"1"}},t,r);return Cn(ne(n,t),(function(i){return se(t,i),Cn(i.text(),(function(s){if(!s)throw new Error("Failed parsing directory contents: Empty response");return Cn(Kt(s,t.parsing),(function(o){const u=Hs(e);let l=(function(c,a,h){let p=arguments.length>3&&arguments[3]!==void 0&&arguments[3],b=arguments.length>4&&arguments[4]!==void 0&&arguments[4];const g=Tr().join(a,"/"),{multistatus:{response:m}}=c,y=m.map((v=>{const E=(function(N){try{return N.replace(/^https?:\/\/[^\/]+/,"")}catch(S){throw new me(S,"Failed normalising HREF")}})(v.href),{propstat:{prop:T}}=v;return Cr(T,g==="/"?decodeURIComponent(Vt(E)):Vt(Tr().relative(decodeURIComponent(g),decodeURIComponent(E))),p)}));return b?y:y.filter((v=>v.basename&&(v.type==="file"||v.filename!==h.replace(/\/$/,""))))})(o,Hs(t.remoteBasePath||t.remotePath),u,r.details,r.includeSelf);return r.glob&&(l=(function(c,a){return c.filter((h=>de(h.filename,a,{matchBase:!0})))})(l,r.glob)),Tt(i,l,r.details)}))}))}))}));function Rn(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}}const Yp=Rn((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=ie({url:G(t.remoteURL,W(e)),method:"GET",headers:{Accept:"text/plain"},transformResponse:[eg]},t,r);return Rr(ne(n,t),(function(i){return se(t,i),Rr(i.text(),(function(s){return Tt(i,s,r.details)}))}))}));function Rr(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const Zp=Rn((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=ie({url:G(t.remoteURL,W(e)),method:"GET"},t,r);return Rr(ne(n,t),(function(i){let s;return se(t,i),(function(o,u){var l=o();return l&&l.then?l.then(u):u()})((function(){return Rr(i.arrayBuffer(),(function(o){s=o}))}),(function(){return Tt(i,s,r.details)}))}))})),Qp=Rn((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const{format:n="binary"}=r;if(n!=="binary"&&n!=="text")throw new me({info:{code:Je.InvalidOutputFormat}},`Invalid output format: ${n}`);return n==="text"?Yp(t,e,r):Zp(t,e,r)})),eg=t=>t;function tg(t,e){let r="";return e.format&&e.indentBy.length>0&&(r=`
19
- `),Fo(t,e,"",r)}function Fo(t,e,r,n){let i="",s=!1;for(let o=0;o<t.length;o++){const u=t[o],l=rg(u);if(l===void 0)continue;let c="";if(c=r.length===0?l:`${r}.${l}`,l===e.textNodeName){let b=u[l];ng(c,e)||(b=e.tagValueProcessor(l,b),b=_o(b,e)),s&&(i+=n),i+=b,s=!1;continue}if(l===e.cdataPropName){s&&(i+=n),i+=`<![CDATA[${u[l][0][e.textNodeName]}]]>`,s=!1;continue}if(l===e.commentPropName){i+=n+`<!--${u[l][0][e.textNodeName]}-->`,s=!0;continue}if(l[0]==="?"){const b=Lo(u[":@"],e),g=l==="?xml"?"":n;let m=u[l][0][e.textNodeName];m=m.length!==0?" "+m:"",i+=g+`<${l}${m}${b}?>`,s=!0;continue}let a=n;a!==""&&(a+=e.indentBy);const h=n+`<${l}${Lo(u[":@"],e)}`,p=Fo(u[l],e,c,a);e.unpairedTags.indexOf(l)!==-1?e.suppressUnpairedNode?i+=h+">":i+=h+"/>":p&&p.length!==0||!e.suppressEmptyNode?p&&p.endsWith(">")?i+=h+`>${p}${n}</${l}>`:(i+=h+">",p&&n!==""&&(p.includes("/>")||p.includes("</"))?i+=n+e.indentBy+p+n:i+=p,i+=`</${l}>`):i+=h+"/>",s=!0}return i}function rg(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r];if(t.hasOwnProperty(n)&&n!==":@")return n}}function Lo(t,e){let r="";if(t&&!e.ignoreAttributes)for(let n in t){if(!t.hasOwnProperty(n))continue;let i=e.attributeValueProcessor(n,t[n]);i=_o(i,e),i===!0&&e.suppressBooleanAttributes?r+=` ${n.substr(e.attributeNamePrefix.length)}`:r+=` ${n.substr(e.attributeNamePrefix.length)}="${i}"`}return r}function ng(t,e){let r=(t=t.substr(0,t.length-e.textNodeName.length-1)).substr(t.lastIndexOf(".")+1);for(let n in e.stopNodes)if(e.stopNodes[n]===t||e.stopNodes[n]==="*."+r)return!0;return!1}function _o(t,e){if(t&&t.length>0&&e.processEntities)for(let r=0;r<e.entities.length;r++){const n=e.entities[r];t=t.replace(n.regex,n.val)}return t}const ig={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1};function Xe(t){this.options=Object.assign({},ig,t),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=mo(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=ag),this.processTextOrObjNode=sg,this.options.format?(this.indentate=og,this.tagEndChar=`>
20
- `,this.newLine=`
21
- `):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function sg(t,e,r,n){const i=this.j2x(t,r+1,n.concat(e));return t[this.options.textNodeName]!==void 0&&Object.keys(t).length===1?this.buildTextValNode(t[this.options.textNodeName],e,i.attrStr,r):this.buildObjectNode(i.val,e,i.attrStr,r)}function og(t){return this.options.indentBy.repeat(t)}function ag(t){return!(!t.startsWith(this.options.attributeNamePrefix)||t===this.options.textNodeName)&&t.substr(this.attrPrefixLen)}function ug(t){return new Xe({attributeNamePrefix:"@_",format:!0,ignoreAttributes:!1,suppressEmptyNode:!0}).build(Uo({lockinfo:{"@_xmlns:d":"DAV:",lockscope:{exclusive:{}},locktype:{write:{}},owner:{href:t}}},"d"))}function Uo(t,e){const r={...t};for(const n in r)r.hasOwnProperty(n)&&(r[n]&&typeof r[n]=="object"&&n.indexOf(":")===-1?(r[`${e}:${n}`]=Uo(r[n],e),delete r[n]):/^@_/.test(n)===!1&&(r[`${e}:${n}`]=r[n],delete r[n]));return r}function Fn(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}function Bo(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}}Xe.prototype.build=function(t){return this.options.preserveOrder?tg(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t}),this.j2x(t,0,[]).val)},Xe.prototype.j2x=function(t,e,r){let n="",i="";const s=r.join(".");for(let o in t)if(Object.prototype.hasOwnProperty.call(t,o))if(t[o]===void 0)this.isAttribute(o)&&(i+="");else if(t[o]===null)this.isAttribute(o)||o===this.options.cdataPropName?i+="":o[0]==="?"?i+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if(t[o]instanceof Date)i+=this.buildTextValNode(t[o],o,"",e);else if(typeof t[o]!="object"){const u=this.isAttribute(o);if(u&&!this.ignoreAttributesFn(u,s))n+=this.buildAttrPairStr(u,""+t[o]);else if(!u)if(o===this.options.textNodeName){let l=this.options.tagValueProcessor(o,""+t[o]);i+=this.replaceEntitiesValue(l)}else i+=this.buildTextValNode(t[o],o,"",e)}else if(Array.isArray(t[o])){const u=t[o].length;let l="",c="";for(let a=0;a<u;a++){const h=t[o][a];if(h!==void 0)if(h===null)o[0]==="?"?i+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if(typeof h=="object")if(this.options.oneListGroup){const p=this.j2x(h,e+1,r.concat(o));l+=p.val,this.options.attributesGroupName&&h.hasOwnProperty(this.options.attributesGroupName)&&(c+=p.attrStr)}else l+=this.processTextOrObjNode(h,o,e,r);else if(this.options.oneListGroup){let p=this.options.tagValueProcessor(o,h);p=this.replaceEntitiesValue(p),l+=p}else l+=this.buildTextValNode(h,o,"",e)}this.options.oneListGroup&&(l=this.buildObjectNode(l,o,c,e)),i+=l}else if(this.options.attributesGroupName&&o===this.options.attributesGroupName){const u=Object.keys(t[o]),l=u.length;for(let c=0;c<l;c++)n+=this.buildAttrPairStr(u[c],""+t[o][u[c]])}else i+=this.processTextOrObjNode(t[o],o,e,r);return{attrStr:n,val:i}},Xe.prototype.buildAttrPairStr=function(t,e){return e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e),this.options.suppressBooleanAttributes&&e==="true"?" "+t:" "+t+'="'+e+'"'},Xe.prototype.buildObjectNode=function(t,e,r,n){if(t==="")return e[0]==="?"?this.indentate(n)+"<"+e+r+"?"+this.tagEndChar:this.indentate(n)+"<"+e+r+this.closeTag(e)+this.tagEndChar;{let i="</"+e+this.tagEndChar,s="";return e[0]==="?"&&(s="?",i=""),!r&&r!==""||t.indexOf("<")!==-1?this.options.commentPropName!==!1&&e===this.options.commentPropName&&s.length===0?this.indentate(n)+`<!--${t}-->`+this.newLine:this.indentate(n)+"<"+e+r+s+this.tagEndChar+t+this.indentate(n)+i:this.indentate(n)+"<"+e+r+s+">"+t+i}},Xe.prototype.closeTag=function(t){let e="";return this.options.unpairedTags.indexOf(t)!==-1?this.options.suppressUnpairedNode||(e="/"):e=this.options.suppressEmptyNode?"/":`></${t}`,e},Xe.prototype.buildTextValNode=function(t,e,r,n){if(this.options.cdataPropName!==!1&&e===this.options.cdataPropName)return this.indentate(n)+`<![CDATA[${t}]]>`+this.newLine;if(this.options.commentPropName!==!1&&e===this.options.commentPropName)return this.indentate(n)+`<!--${t}-->`+this.newLine;if(e[0]==="?")return this.indentate(n)+"<"+e+r+"?"+this.tagEndChar;{let i=this.options.tagValueProcessor(e,t);return i=this.replaceEntitiesValue(i),i===""?this.indentate(n)+"<"+e+r+this.closeTag(e)+this.tagEndChar:this.indentate(n)+"<"+e+r+">"+i+"</"+e+this.tagEndChar}},Xe.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(let e=0;e<this.options.entities.length;e++){const r=this.options.entities[e];t=t.replace(r.regex,r.val)}return t};const lg=Bo((function(t,e,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const i=ie({url:G(t.remoteURL,W(e)),method:"UNLOCK",headers:{"Lock-Token":r}},t,n);return Fn(ne(i,t),(function(s){if(se(t,s),s.status!==204&&s.status!==200)throw Tn(s)}))})),cg=Bo((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const{refreshToken:n,timeout:i=fg}=r,s={Accept:"text/plain,application/xml",Timeout:i};n&&(s.If=n);const o=ie({url:G(t.remoteURL,W(e)),method:"LOCK",headers:s,data:ug(t.contactHref)},t,r);return Fn(ne(o,t),(function(u){return se(t,u),Fn(u.text(),(function(l){const c=(p=l,new Ao({removeNSPrefix:!0,parseAttributeValue:!0,parseTagValue:!0}).parse(p)),a=We().get(c,"prop.lockdiscovery.activelock.locktoken.href"),h=We().get(c,"prop.lockdiscovery.activelock.timeout");var p;if(!a)throw Tn(u,"No lock token received: ");return{token:a,serverTimeout:h}}))}))})),fg="Infinite, Second-4100000000";function Ln(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const hg=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const r=e.path||"/",n=ie({url:G(t.remoteURL,r),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:"0"}},t,e);return Ln(ne(n,t),(function(i){return se(t,i),Ln(i.text(),(function(s){return Ln(Kt(s,t.parsing),(function(o){const u=(function(l){try{const[c]=l.multistatus.response,{propstat:{prop:{"quota-used-bytes":a,"quota-available-bytes":h}}}=c;return a!==void 0&&h!==void 0?{used:parseInt(String(a),10),available:Dp(h)}:null}catch{}return null})(o);return Tt(i,u,e.details)}))}))}))}));function _n(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const dg=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const{details:n=!1}=r,i=ie({url:G(t.remoteURL,W(e)),method:"SEARCH",headers:{Accept:"text/plain,application/xml","Content-Type":t.headers["Content-Type"]||"application/xml; charset=utf-8"}},t,r);return _n(ne(i,t),(function(s){return se(t,s),_n(s.text(),(function(o){return _n(Kt(o,t.parsing),(function(u){const l=(function(c,a,h){const p={truncated:!1,results:[]};return p.truncated=c.multistatus.response.some((b=>(b.status||b.propstat?.status).split(" ",3)?.[1]==="507"&&b.href.replace(/\/$/,"").endsWith(W(a).replace(/\/$/,"")))),c.multistatus.response.forEach((b=>{if(b.propstat===void 0)return;const g=b.href.split("/").map(decodeURIComponent).join("/");p.results.push(Cr(b.propstat.prop,g,h))})),p})(u,e,n);return Tt(s,l,n)}))}))}))})),pg=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const i=ie({url:G(t.remoteURL,W(e)),method:"MOVE",headers:{Destination:G(t.remoteURL,W(r)),Overwrite:n.overwrite===!1?"F":"T"}},t,n);return o=function(u){se(t,u)},(s=ne(i,t))&&s.then||(s=Promise.resolve(s)),o?s.then(o):s;var s,o}));var gg=H(172);function mg(t){if(eo(t))return t.byteLength;if(to(t))return t.length;if(typeof t=="string")return(0,gg.d)(t);throw new me({info:{code:Je.DataTypeNoLength}},"Cannot calculate data length: Invalid type")}const yg=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const{contentLength:i=!0,overwrite:s=!0}=n,o={"Content-Type":"application/octet-stream"};i===!1||(o["Content-Length"]=typeof i=="number"?`${i}`:`${mg(r)}`),s||(o["If-None-Match"]="*");const u=ie({url:G(t.remoteURL,W(e)),method:"PUT",headers:o,data:r},t,n);return c=function(a){try{se(t,a)}catch(h){const p=h;if(p.status!==412||s)throw p;return!1}return!0},(l=ne(u,t))&&l.then||(l=Promise.resolve(l)),c?l.then(c):l;var l,c})),ko=(function(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}})((function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=ie({url:G(t.remoteURL,W(e)),method:"OPTIONS"},t,r);return s=function(o){try{se(t,o)}catch(u){throw u}return{compliance:(o.headers.get("DAV")??"").split(",").map((u=>u.trim())),server:o.headers.get("Server")??""}},(i=ne(n,t))&&i.then||(i=Promise.resolve(i)),s?i.then(s):i;var i,s}));function Jt(t,e,r){return r?e?e(t):t:(t&&t.then||(t=Promise.resolve(t)),e?t.then(e):t)}const bg=Un((function(t,e,r,n,i){let s=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{};if(r>n||r<0)throw new me({info:{code:Je.InvalidUpdateRange}},`Invalid update range ${r} for partial update`);const o={"Content-Type":"application/octet-stream","Content-Length":""+(n-r+1),"Content-Range":`bytes ${r}-${n}/*`},u=ie({url:G(t.remoteURL,W(e)),method:"PUT",headers:o,data:i},t,s);return Jt(ne(u,t),(function(l){se(t,l)}))}));function $o(t,e){var r=t();return r&&r.then?r.then(e):e(r)}const wg=Un((function(t,e,r,n,i){let s=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{};if(r>n||r<0)throw new me({info:{code:Je.InvalidUpdateRange}},`Invalid update range ${r} for partial update`);const o={"Content-Type":"application/x-sabredav-partialupdate","Content-Length":""+(n-r+1),"X-Update-Range":`bytes=${r}-${n}`},u=ie({url:G(t.remoteURL,W(e)),method:"PATCH",headers:o,data:i},t,s);return Jt(ne(u,t),(function(l){se(t,l)}))}));function Un(t){return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];try{return Promise.resolve(t.apply(this,e))}catch(n){return Promise.reject(n)}}}const xg=Un((function(t,e,r,n,i){let s=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{};return Jt(ko(t,e,s),(function(o){let u=!1;return $o((function(){if(o.compliance.includes("sabredav-partialupdate"))return Jt(wg(t,e,r,n,i,s),(function(l){return u=!0,l}))}),(function(l){let c=!1;return u?l:$o((function(){if(o.server.includes("Apache")&&o.compliance.includes("<http://apache.org/dav/propset/fs/1>"))return Jt(bg(t,e,r,n,i,s),(function(a){return c=!0,a}))}),(function(a){if(c)return a;throw new me({info:{code:Je.NotSupported}},"Not supported")}))}))}))})),Eg="https://github.com/perry-mitchell/webdav-client/blob/master/LOCK_CONTACT.md";function vg(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{authType:r=null,remoteBasePath:n,contactHref:i=Eg,ha1:s,headers:o={},httpAgent:u,httpsAgent:l,password:c,token:a,username:h,withCredentials:p}=e;let b=r;b||(b=h||c?Te.Password:Te.None);const g={authType:b,remoteBasePath:n,contactHref:i,ha1:s,headers:Object.assign({},o),httpAgent:u,httpsAgent:l,password:c,parsing:{attributeNamePrefix:e.attributeNamePrefix??"@",attributeParsers:[],tagParsers:[No]},remotePath:Sd(t),remoteURL:t,token:a,username:h,withCredentials:p};return Xs(g,h,c,a,s),{copyFile:(m,y,v)=>cp(g,m,y,v),createDirectory:(m,y)=>On(g,m,y),createReadStream:(m,y)=>(function(v,E){let T=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const N=new(Ro()).PassThrough;return zp(v,E,T).then((S=>{S.pipe(N)})).catch((S=>{N.emit("error",S)})),N})(g,m,y),createWriteStream:(m,y,v)=>(function(E,T){let N=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},S=arguments.length>3&&arguments[3]!==void 0?arguments[3]:Wp;const F=new(Ro()).PassThrough,L={};N.overwrite===!1&&(L["If-None-Match"]="*");const U=ie({url:G(E.remoteURL,W(T)),method:"PUT",headers:L,data:F,maxRedirects:0},E,N);return ne(U,E).then((_=>se(E,_))).then((_=>{setTimeout((()=>{S(_)}),0)})).catch((_=>{F.emit("error",_)})),F})(g,m,y,v),customRequest:(m,y)=>Gp(g,m,y),deleteFile:(m,y)=>Kp(g,m,y),exists:(m,y)=>Jp(g,m,y),getDirectoryContents:(m,y)=>Xp(g,m,y),getFileContents:(m,y)=>Qp(g,m,y),getFileDownloadLink:m=>(function(y,v){let E=G(y.remoteURL,W(v));const T=/^https:/i.test(E)?"https":"http";switch(y.authType){case Te.None:break;case Te.Password:{const N=Gs(y.headers.Authorization.replace(/^Basic /i,"").trim());E=E.replace(/^https?:\/\//,`${T}://${N}@`);break}default:throw new me({info:{code:Je.LinkUnsupportedAuthType}},`Unsupported auth type for file link: ${y.authType}`)}return E})(g,m),getFileUploadLink:m=>(function(y,v){let E=`${G(y.remoteURL,W(v))}?Content-Type=application/octet-stream`;const T=/^https:/i.test(E)?"https":"http";switch(y.authType){case Te.None:break;case Te.Password:{const N=Gs(y.headers.Authorization.replace(/^Basic /i,"").trim());E=E.replace(/^https?:\/\//,`${T}://${N}@`);break}default:throw new me({info:{code:Je.LinkUnsupportedAuthType}},`Unsupported auth type for file link: ${y.authType}`)}return E})(g,m),getHeaders:()=>Object.assign({},g.headers),getQuota:m=>hg(g,m),lock:(m,y)=>cg(g,m,y),moveFile:(m,y,v)=>pg(g,m,y,v),putFileContents:(m,y,v)=>yg(g,m,y,v),partialUpdateFileContents:(m,y,v,E,T)=>xg(g,m,y,v,E,T),getDAVCompliance:m=>ko(g,m),search:(m,y)=>dg(g,m,y),setHeaders:m=>{g.headers=Object.assign({},m)},stat:(m,y)=>Sn(g,m,y),unlock:(m,y,v)=>lg(g,m,y,v),registerAttributeParser:m=>{g.parsing.attributeParsers.push(m)},registerTagParser:m=>{g.parsing.tagParsers.push(m)}}}const ue=[];for(let t=0;t<256;++t)ue.push((t+256).toString(16).slice(1));function Tg(t,e=0){return(ue[t[e+0]]+ue[t[e+1]]+ue[t[e+2]]+ue[t[e+3]]+"-"+ue[t[e+4]]+ue[t[e+5]]+"-"+ue[t[e+6]]+ue[t[e+7]]+"-"+ue[t[e+8]]+ue[t[e+9]]+"-"+ue[t[e+10]]+ue[t[e+11]]+ue[t[e+12]]+ue[t[e+13]]+ue[t[e+14]]+ue[t[e+15]]).toLowerCase()}let Bn;const Ag=new Uint8Array(16);function Ng(){if(!Bn){if(typeof crypto>"u"||!crypto.getRandomValues)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");Bn=crypto.getRandomValues.bind(crypto)}return Bn(Ag)}var jo={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Pg(t,e,r){t=t||{};const n=t.random??t.rng?.()??Ng();if(n.length<16)throw new Error("Random bytes length must be >= 16");return n[6]=n[6]&15|64,n[8]=n[8]&63|128,Tg(n)}function Ig(t,e,r){return jo.randomUUID&&!t?jo.randomUUID():Pg(t)}const kn=(t,e)=>Object.fromEntries(Object.entries(t).map(([r,n])=>e.includes(r)?[r,n||""]:[it.DavNamespace.includes(r)?`d:${r}`:`oc:${r}`,n||""])),Mo=(t=[],{pattern:e,filterRules:r,limit:n=0,extraProps:i=[]})=>{let s="d:propfind";e&&(s="oc:search-files"),r&&(s="oc:filter-files");const o=t.reduce((a,h)=>Object.assign(a,{[h]:null}),{}),u=kn(o,i),l={[s]:{"d:prop":u,"@@xmlns:d":"DAV:","@@xmlns:oc":"http://owncloud.org/ns",...e&&{"oc:search":{"oc:pattern":e,"oc:limit":n}},...r&&{"oc:filter-rules":kn(r,[])}}};return new qe({format:!0,ignoreAttributes:!1,attributeNamePrefix:"@@",suppressEmptyNode:!0}).build(l)},Sg=t=>{const e={"d:propertyupdate":{"d:set":{"d:prop":kn(t,[])},"@@xmlns:d":"DAV:","@@xmlns:oc":"http://owncloud.org/ns"}};return new qe({format:!0,ignoreAttributes:!1,attributeNamePrefix:"@@",suppressEmptyNode:!0}).build(e)},Og=t=>{const e={},r=t.get("tus-version");return r?(e.version=r.split(","),t.get("tus-extension")&&(e.extension=t.get("tus-extension").split(",")),t.get("tus-resumable")&&(e.resumable=t.get("tus-resumable")),t.get("tus-max-size")&&(e.maxSize=parseInt(t.get("tus-max-size"),10)),e):null},Cg=async t=>{const e=n=>{const i=decodeURIComponent(n);return n?.startsWith("/remote.php/dav/")?$(i.replace("/remote.php/dav/",""),{leadingSlash:!0,trailingSlash:!1}):i};return(await Kt(t)).multistatus.response.map(({href:n,propstat:i})=>{const s={...Cr(i.prop,e(n),!0),processing:i.status==="HTTP/1.1 425 TOO EARLY"};return s.props.name&&(s.props.name=s.props.name.toString()),s})},Rg=t=>{const e=new Bs,r={message:"Unknown error",errorCode:void 0};try{const n=e.parse(t);if(!n["d:error"])return r;if(n["d:error"]["s:message"]){const i=n["d:error"]["s:message"];typeof i=="string"&&(r.message=i)}if(n["d:error"]["s:errorcode"]){const i=n["d:error"]["s:errorcode"];typeof i=="string"&&(r.errorCode=i)}}catch{return r}return r};class Fg{client;davPath;headers;extraProps;constructor({baseUrl:e,headers:r}){this.davPath=$(e,"remote.php/dav"),this.client=vg(this.davPath,{}),this.headers=r,this.extraProps=[]}mkcol(e,r={}){return this.request(e,{method:Ve.mkcol,...r})}async propfind(e,{depth:r=1,properties:n=[],headers:i={},...s}={}){const o={...i,Depth:r.toString()},{body:u,result:l}=await this.request(e,{method:Ve.propfind,data:Mo(n,{extraProps:this.extraProps}),headers:o,...s});return u?.length&&(u[0].tusSupport=Og(l.headers)),u}async report(e,{pattern:r="",filterRules:n=null,limit:i=30,properties:s,...o}={}){const{body:u,result:l}=await this.request(e,{method:Ve.report,data:Mo(s,{pattern:r,filterRules:n,limit:i,extraProps:this.extraProps}),...o});return{results:u,range:l.headers.get("content-range")}}copy(e,r,{overwrite:n=!1,headers:i={},...s}={}){const o=$(this.davPath,cr(r));return this.request(e,{method:Ve.copy,headers:{...i,Destination:o,overwrite:n?"T":"F"},...s})}move(e,r,{overwrite:n=!1,headers:i={},...s}={}){const o=$(this.davPath,cr(r));return this.request(e,{method:Ve.move,headers:{...i,Destination:o,overwrite:n?"T":"F"},...s})}put(e,r,{headers:n={},onUploadProgress:i,previousEntityTag:s,overwrite:o,...u}={}){const l={...n};return s?l["If-Match"]=s:o||(l["If-None-Match"]="*"),this.request(e,{method:Ve.put,data:r,headers:l,onUploadProgress:i,...u})}delete(e,r={}){return this.request(e,{method:Ve.delete,...r})}propPatch(e,r,n={}){const i=Sg(r);return this.request(e,{method:Ve.proppatch,data:i,...n})}getFileUrl(e){return $(this.davPath,cr(e))}buildHeaders(e={}){return{"Content-Type":"application/xml; charset=utf-8","X-Requested-With":"XMLHttpRequest","X-Request-ID":Ig(),...this.headers&&{...this.headers()},...e}}async request(e,r){const n=$(this.davPath,cr(e),{leadingSlash:!0}),i={...r,url:n,headers:this.buildHeaders(r.headers||{})};try{const s=await this.client.customRequest("",i);let o;if(s.status===207){const u=await s.text();o=await Cg(u)}return{body:o,status:s.status,result:s}}catch(s){const{response:o}=s,u=await o.text(),l=Rg(u);throw new Wu(l.message,l.errorCode,o,o.status)}}}const Lg=(t,e)=>({async listFileVersions(r,n={}){const[i,...s]=await t.propfind($("meta",r,"v",{leadingSlash:!0}),n);return s.map(o=>xt(o,t.extraProps))}}),_g=(t,e)=>({setFavorite(r,{path:n},i,s={}){const o={[C.IsFavorite]:i?"true":"false"};return t.propPatch($(r.webDavPath,n),o,s)}}),Ug=(t,e)=>({listFavoriteFiles({davProperties:r=it.Default,username:n="",...i}={}){return t.report($("files",n),{properties:r,filterRules:{favorite:1},...i})}}),Bg=(t,e)=>{const r=Q.create();e&&r.interceptors.request.use(R=>(Object.assign(R.headers,e()),R));const n={axiosClient:r,baseUrl:t},i=new Fg({baseUrl:t,headers:e}),s=R=>{i.extraProps.push(R)},o=Td(i),{getPathForFileId:u}=o,l=gd(i,o),{listFiles:c}=l,a=hd(l),{getFileInfo:h}=a,{createFolder:p}=cd(i,a),b=fd(i,n),{getFileContents:g}=b,{putFileContents:m}=yd(i,a),{getFileUrl:y,revokeUrl:v}=dd(i,b,a,n),{getPublicFileUrl:E}=pd(i),{copyFiles:T}=ld(i),{moveFiles:N}=md(i),{deleteFile:S}=bd(i),{restoreFile:F}=wd(i),{listFileVersions:L}=Lg(i),{restoreFileVersion:U}=xd(i),{clearTrashBin:_}=Ed(i),{search:j}=vd(i),{listFavoriteFiles:pe}=Ug(i),{setFavorite:oe}=_g(i);return{copyFiles:T,createFolder:p,deleteFile:S,restoreFile:F,restoreFileVersion:U,getFileContents:g,getFileInfo:h,getFileUrl:y,getPublicFileUrl:E,getPathForFileId:u,listFiles:c,listFileVersions:L,moveFiles:N,putFileContents:m,revokeUrl:v,clearTrashBin:_,search:j,listFavoriteFiles:pe,setFavorite:oe,registerExtraProp:s}};let Xt;self.onmessage=async t=>{const{topic:e,data:r}=JSON.parse(t.data);if(e==="tokenUpdate"&&Xt){Xt.Authorization?.toString().startsWith("Bearer")&&(Xt.Authorization=r.accessToken);return}const{baseUrl:n,headers:i,space:s,resources:o,concurrentRequests:u}=r;Xt=i;const l=Bg(n,()=>Xt),c=[],a=[],h=new ra({concurrency:u}),p=g=>e==="fileListDelete"?l.deleteFile(s,{path:g.path}):l.clearTrashBin(s,{id:g.id}),b=o.map(g=>h.add(async()=>{try{const{status:m}=await p(g);if(m===204){c.push(g);return}if(m===423){const{status:y}=await p(g);if(y===204){c.push(g);return}}}catch(m){console.error(m),a.push({resource:g,message:m.message,statusCode:m.statusCode,xReqId:m.response.headers?.get("x-request-id")})}}));await Promise.allSettled(b),postMessage(JSON.stringify({successful:c,failed:a}))}})();