sliccy 5.59.1 → 5.60.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.
- package/dist/ui/assets/__vite-browser-external-DZX1xHt-.js +1 -0
- package/dist/ui/assets/account-store-BddNCTSm.js +98 -0
- package/dist/ui/assets/account-store-dvAfa3y8.js +38 -0
- package/dist/ui/assets/adobe-C0iTCwW2.js +1 -0
- package/dist/ui/assets/adobe-DC5UT0ZJ.js +2 -0
- package/dist/ui/assets/adobe-oauth-state-Csa5ciQS.js +1 -0
- package/dist/ui/assets/{adobe-oauth-state-BeQ7T3Vk.js → adobe-oauth-state-Vbbfo7gR.js} +1 -1
- package/dist/ui/assets/agent-message-to-chat-QyCEPmi8.js +7 -0
- package/dist/ui/assets/{anthropic-messages-BP_xL8Mh.js → anthropic-messages-CIsUSIzG.js} +3 -3
- package/dist/ui/assets/{anthropic-messages-BwBPoNP0.js → anthropic-messages-_fPAePlR.js} +3 -3
- package/dist/ui/assets/{apps-Bs4OZdLX.js → apps-ztx90XZQ.js} +1 -1
- package/dist/ui/assets/attachments-CByeG2Ru.js +1 -0
- package/dist/ui/assets/{azure-openai-hnPmyx7n.js → azure-openai-BKnOwPkT.js} +1 -1
- package/dist/ui/assets/{azure-openai-EZeNxE7d.js → azure-openai-Y9U14npX.js} +1 -1
- package/dist/ui/assets/{azure-openai-responses-BXDkTtSH.js → azure-openai-responses-DhzbC_tL.js} +1 -1
- package/dist/ui/assets/{azure-openai-responses-De9pJjBR.js → azure-openai-responses-bHfWNMbx.js} +1 -1
- package/dist/ui/assets/base64-DpPqYZJF.js +1 -0
- package/dist/ui/assets/bedrock-camp-BEi8MYUS.js +1 -0
- package/dist/ui/assets/bedrock-camp-CvxD6hHk.js +1 -0
- package/dist/ui/assets/bridge-launch-params-jegYRGJ6.js +1 -0
- package/dist/ui/assets/{browser-2wdq8OwU.js → browser-COVn7LPD.js} +6 -6
- package/dist/ui/assets/{cdp-Bwq6NLAx.js → cdp-7evcrxxP.js} +1 -1
- package/dist/ui/assets/cerebras-D_u7JsxU.js +1 -0
- package/dist/ui/assets/cerebras-ZAPHCT6L.js +1 -0
- package/dist/ui/assets/client-CpLUc-P8.js +4 -0
- package/dist/ui/assets/clipboard-Bd1Wp2vH.js +1 -0
- package/dist/ui/assets/compat-DyT25qXb.js +2 -0
- package/dist/ui/assets/{completionchunk-B2eUYPOo.js → completionchunk-D8ek1SQ-.js} +1 -1
- package/dist/ui/assets/{composer-speech-CgPswGW1.js → composer-speech-BWsih2Nz.js} +1 -1
- package/dist/ui/assets/{connect-surface-Ccit9qN8.js → connect-surface-YVJhSwyb.js} +1 -1
- package/dist/ui/assets/{context-compaction-LYFtS2_f.js → context-compaction-dcYYajWb.js} +6 -6
- package/dist/ui/assets/cost-command-Cpg2Em0Q.js +1613 -0
- package/dist/ui/assets/db-DjAqlQ2I.js +1 -0
- package/dist/ui/assets/db-ysOO0kLr.js +1 -0
- package/dist/ui/assets/dictation-priming-DGpw1lUV.js +1 -0
- package/dist/ui/assets/dip-BumXS1a9.js +233 -0
- package/dist/ui/assets/discovery-preference-DCtfbqw1.js +1 -0
- package/dist/ui/assets/dist-0FRaZO2z.js +12 -0
- package/dist/ui/assets/{dist-DH3_TPic.js → dist-BhEJb2Dl.js} +1 -1
- package/dist/ui/assets/{dist-DD6YY4Ks2.js → dist-Bj10RLrf.js} +1 -1
- package/dist/ui/assets/{dist-BHXb30bf.js → dist-Bq5i9FMJ.js} +4 -4
- package/dist/ui/assets/dist-CJ6ilPeJ.js +18 -0
- package/dist/ui/assets/{dist-D58cmC11.js → dist-Cc2eS9kS.js} +1 -1
- package/dist/ui/assets/{dist-CC_gNVTb.js → dist-DB-MlM2G.js} +1 -1
- package/dist/ui/assets/{dist-Bw2SRiP7.js → dist-DuLHpm2f.js} +1 -1
- package/dist/ui/assets/dist-DvjiIrEx.js +23 -0
- package/dist/ui/assets/{dist-D1pcMg_U.js → dist-d2CXjMIs.js} +3 -3
- package/dist/ui/assets/electron-overlay-route-CjT6k9Df.js +1 -0
- package/dist/ui/assets/ensure-speech-assets-D2Pclall.js +1 -0
- package/dist/ui/assets/es-CP2z28j0.js +53 -0
- package/dist/ui/assets/esp8266-CkAPDkuz.js +1 -0
- package/dist/ui/assets/esptool-operations-C0DUkD34.js +13 -0
- package/dist/ui/assets/esptool-operations-iCYPdIRA.js +12 -0
- package/dist/ui/assets/extension-bridge-transport-DHBo-K6K.js +1 -0
- package/dist/ui/assets/{follower-navigate-watcher-CRVUcrQz.js → follower-navigate-watcher-Cn5RjYxg.js} +1 -1
- package/dist/ui/assets/{fs-C4sVSIbi.js → fs-BVM9dzPP.js} +1 -1
- package/dist/ui/assets/fs-CMpdIYZs.js +2 -0
- package/dist/ui/assets/git-config-Lj0BT7Oc.js +7 -0
- package/dist/ui/assets/github-CmX1lUH3.js +2 -0
- package/dist/ui/assets/github-copilot-C9loxoyp.js +1 -0
- package/dist/ui/assets/github-copilot-JdvDIR67.js +2 -0
- package/dist/ui/assets/github-ndbvNRbv.js +1 -0
- package/dist/ui/assets/global-db-DvmmimLY.js +1 -0
- package/dist/ui/assets/{google-generative-ai-C58ldv83.js → google-generative-ai-CyS9qbzb.js} +1 -1
- package/dist/ui/assets/{google-generative-ai-Eq6eGS5h.js → google-generative-ai-DkRyuoBH.js} +1 -1
- package/dist/ui/assets/{google-shared-DQbld86Z.js → google-shared-CCJkdw81.js} +2 -2
- package/dist/ui/assets/{google-shared-DwCjfFnw.js → google-shared-p5XdfI6c.js} +3 -3
- package/dist/ui/assets/{google-vertex-C18Xl3dV.js → google-vertex-Cp9ldPyE.js} +1 -1
- package/dist/ui/assets/{google-vertex-CkkAgSFr.js → google-vertex-D7VRnbrL.js} +1 -1
- package/dist/ui/assets/{handoff-link-CLvhqfpd.js → handoff-link-CfgH86mb.js} +1 -1
- package/dist/ui/assets/hear-D7srqY_7.js +1 -0
- package/dist/ui/assets/hear-acxY6mf0.js +1 -0
- package/dist/ui/assets/hid-device-registry-DboUgvzI.js +1 -0
- package/dist/ui/assets/hid-picker-Bhoh8hxy.js +1 -0
- package/dist/ui/assets/installer-D7LGGQGy.js +3 -0
- package/dist/ui/assets/{js-realm-worker-CeYHBMC5.js → js-realm-worker-B4uCLm52.js} +3 -3
- package/dist/ui/assets/{json-parse-B51EftGA.js → json-parse-CpLf0aqK.js} +1 -1
- package/dist/ui/assets/{json-parse-C7d6hyOc.js → json-parse-rb7sUwcH.js} +1 -1
- package/dist/ui/assets/kernel-worker-DMnEeTNU.js +8759 -0
- package/dist/ui/assets/{kokoro-C-DxSDte.js → kokoro-CGDCwNNA.js} +2 -2
- package/dist/ui/assets/{kokoro-BFFlHn4y.js → kokoro-D3TYeL2z.js} +2 -2
- package/dist/ui/assets/{kokoro-engine-DENIKgTV.js → kokoro-engine-DLKTuHMR.js} +2 -2
- package/dist/ui/assets/legacy-api-aliases-BQSsmFIS.js +1 -0
- package/dist/ui/assets/legacy-api-aliases-DWJHPSiz.js +1 -0
- package/dist/ui/assets/{legacy-styles-kYboUbpI.js → legacy-styles-DcRu2WCJ.js} +1 -1
- package/dist/ui/assets/lick-manager-Ct3WOtut.js +2 -0
- package/dist/ui/assets/lick-ws-bridge-C_bJMGw6.js +1 -0
- package/dist/ui/assets/{lick-ws-bridge-DpPrSP8R.js → lick-ws-bridge-SPFIXhG2.js} +1 -1
- package/dist/ui/assets/llm-session-id-ZObKEXzb.js +1 -0
- package/dist/ui/assets/local-llm-B5vPCdpH.js +2 -0
- package/dist/ui/assets/{local-llm-wgOnNpVi.js → local-llm-DS8tu43V.js} +1 -1
- package/dist/ui/assets/magick-wasm-B-rybRPb.js +43 -0
- package/dist/ui/assets/main-D8Y-cnmF.js +22 -0
- package/dist/ui/assets/{main-cherry-d-KDlb8k.js → main-cherry-CGm5knH6.js} +1 -1
- package/dist/ui/assets/{mime-types-BqLkKWa7.js → mime-types-D7IV6i7k.js} +1 -1
- package/dist/ui/assets/mistral-conversations-CLDzxp2F.js +8 -0
- package/dist/ui/assets/mistral-conversations-DbKikZnf.js +7 -0
- package/dist/ui/assets/{models-ByRUWfA-.js → models-CzSI8IsT.js} +1 -1
- package/dist/ui/assets/{mount-C0YbhdMr.js → mount-C4XESP9i.js} +1 -1
- package/dist/ui/assets/mount-Hr9QXuwp.js +2 -0
- package/dist/ui/assets/{mount-bridge-client-0Afn2H9Y.js → mount-bridge-client-BVLVI9yX.js} +1 -1
- package/dist/ui/assets/mount-recovery-BHHDw9yC.js +2 -0
- package/dist/ui/assets/mount-table-store-CTrzlrNn.js +1 -0
- package/dist/ui/assets/navigation-watcher-BoJS9hdc.js +1 -0
- package/dist/ui/assets/new-session-u-78FCPG.js +2 -0
- package/dist/ui/assets/oauth-bootstrap-DHKASsxn.js +2 -0
- package/dist/ui/assets/{oauth-service-w5HZt7Xx.js → oauth-service-CmM0tZSO.js} +1 -1
- package/dist/ui/assets/oauth-service-DSuwOpMz.js +1 -0
- package/dist/ui/assets/{openai-BeH6aC_-.js → openai-BxFF4GUL.js} +2 -2
- package/dist/ui/assets/{openai-BvKpRLAG.js → openai-CmTnPr9N.js} +2 -2
- package/dist/ui/assets/openai-codex-Djc_-qM9.js +1 -0
- package/dist/ui/assets/openai-codex-gi-RyKX_.js +1 -0
- package/dist/ui/assets/{openai-codex-responses-BDYh8ojD.js → openai-codex-responses-B_k2rCqO.js} +1 -1
- package/dist/ui/assets/{openai-codex-responses-C7QnNmC0.js → openai-codex-responses-RviMslSH.js} +1 -1
- package/dist/ui/assets/{openai-completions-t-glszMQ.js → openai-completions-CGLtJfv2.js} +1 -1
- package/dist/ui/assets/{openai-completions-BnAjXzgN.js → openai-completions-COYKlBqA.js} +1 -1
- package/dist/ui/assets/{openai-responses-o9_kr7GP.js → openai-responses-C4mUX6jK.js} +1 -1
- package/dist/ui/assets/{openai-responses-BofM6cmY.js → openai-responses-D02gU0ey.js} +1 -1
- package/dist/ui/assets/{openai-responses-shared-79gch22X.js → openai-responses-shared-CCTyKL6A.js} +2 -2
- package/dist/ui/assets/{openai-responses-shared-DKPwc9Eh.js → openai-responses-shared-bVKJbQt9.js} +2 -2
- package/dist/ui/assets/{openrouter-images-PT0FZmkM.js → openrouter-images-BrQDTa3_.js} +1 -1
- package/dist/ui/assets/{openrouter-images-D0dgD5eX.js → openrouter-images-DtvjLeGK.js} +1 -1
- package/dist/ui/assets/otel-C1NYdIbe.js +3 -0
- package/dist/ui/assets/otel-joHgpnL_.js +3 -0
- package/dist/ui/assets/page-follower-tray-DFeLlotx.js +5 -0
- package/dist/ui/assets/panel-rpc-handlers-CTZqBsvr.js +2 -0
- package/dist/ui/assets/{pdfjs-BdCnB7P8.js → pdfjs-B1saeD0h.js} +5 -5
- package/dist/ui/assets/{port-bridge-client-Btb0CfZS.js → port-bridge-client-CdvMlimf.js} +1 -1
- package/dist/ui/assets/{port-bridge-client-BtsJUDjt.js → port-bridge-client-CsrXhMWo.js} +1 -1
- package/dist/ui/assets/preload-helper-Czpn1I53.js +1 -0
- package/dist/ui/assets/process-manager-B5dz0PkO.js +1 -0
- package/dist/ui/assets/provider-DeZ3vGbS.js +2 -0
- package/dist/ui/assets/provider-POdkeNpc.js +1 -0
- package/dist/ui/assets/provider-settings-3FoUN196.js +1 -0
- package/dist/ui/assets/provider-settings-BraIAAA7.js +2 -0
- package/dist/ui/assets/provider-store-access-B_pR-9Xx.js +2 -0
- package/dist/ui/assets/provider-store-access-BkJ_SWbe.js +1 -0
- package/dist/ui/assets/providers-B26DtTJa.js +1 -0
- package/dist/ui/assets/providers-CvODsjGm.js +2 -0
- package/dist/ui/assets/proxied-fetch-DETjVL-j.js +2 -0
- package/dist/ui/assets/proxied-fetch-sbHa3Tte.js +1 -0
- package/dist/ui/assets/{py-realm-worker-C5_FcpVv.js → py-realm-worker-VuYxvTG9.js} +2 -2
- package/dist/ui/assets/{pyodide-CVuZVKDU.js → pyodide-BahZNzwn.js} +2 -2
- package/dist/ui/assets/{quick-llm-8fakxnYS.js → quick-llm-DzhE1JW0.js} +1 -1
- package/dist/ui/assets/{readline-D4m_9EmN.js → readline-0OE_8qoR.js} +1 -1
- package/dist/ui/assets/remote-cdp-transport-DOoXIxy3.js +1 -0
- package/dist/ui/assets/{remote-terminal-view-BOSJ_t1v.js → remote-terminal-view-C7x7cM1d.js} +2 -2
- package/dist/ui/assets/runtime-mode-M-qJL9jF.js +1 -0
- package/dist/ui/assets/safe-buffer-C0pSmFaz.js +12 -0
- package/dist/ui/assets/script-catalog-BYXhqRAc.js +2 -0
- package/dist/ui/assets/{secret-env-CGjJCzwN.js → secret-env-1E2r2H5F.js} +1 -1
- package/dist/ui/assets/{secret-topology-_rfIhUjY.js → secret-topology-D2k1IxFk.js} +1 -1
- package/dist/ui/assets/{secrets-bridge-client-a5aLwwny.js → secrets-bridge-client-CONYX8PU.js} +1 -1
- package/dist/ui/assets/serial-picker-CUd91lje.js +1 -0
- package/dist/ui/assets/session-freezer-CUzeQ9yz.js +21 -0
- package/dist/ui/assets/{setup-sprinkle-exec-P2hO-taT.js → setup-sprinkle-exec-DD6jqggr.js} +1 -1
- package/dist/ui/assets/setup-sudo-cXyK0NGW.js +2 -0
- package/dist/ui/assets/{shared-Cq5Q0noX.js → shared-Dwjvg8S5.js} +1 -1
- package/dist/ui/assets/shared-X5SFnyK-.js +4 -0
- package/dist/ui/assets/skills-otSlGBFl.js +6 -0
- package/dist/ui/assets/{slicc-editor-DKckizoI.js → slicc-editor-BoIEeofq.js} +2 -2
- package/dist/ui/assets/{speak-DG2fJcBd.js → speak-WMi1eHMn.js} +3 -3
- package/dist/ui/assets/{speak-CcZ3Uni4.js → speak-YEgNUk4w.js} +1 -1
- package/dist/ui/assets/{sprinkle-bridge-C0ycYX8f.js → sprinkle-bridge-CmJpELpy.js} +1 -1
- package/dist/ui/assets/sprinkle-manager-DXrwoVHS.js +1 -0
- package/dist/ui/assets/{sprinkle-renderer-Bk_e6Kbr.js → sprinkle-renderer-B0y9_9py.js} +2 -2
- package/dist/ui/assets/{wc-shell-ChAQky0u.js → src-6TqoULh8.js} +94 -211
- package/dist/ui/assets/src-CS5gSDhT.js +1 -0
- package/dist/ui/assets/src-Dk1QVJRd.js +1 -0
- package/dist/ui/assets/store-BfzctFJC.js +1 -0
- package/dist/ui/assets/{sudo-CBMei9fD.js → sudo-LN3PJp6v.js} +1 -1
- package/dist/ui/assets/telemetry-C8rZr13D.js +3 -0
- package/dist/ui/assets/timestamp-preference-DgrTvVNx.js +2 -0
- package/dist/ui/assets/transcript-limits-D0M7bLr9.js +1 -0
- package/dist/ui/assets/{transform-messages-ZX8cvJiJ.js → transform-messages-CVIV-EgO.js} +1 -1
- package/dist/ui/assets/transform-messages-fFaW-DLG.js +1 -0
- package/dist/ui/assets/transformers-env-8w05vuhN.js +1 -0
- package/dist/ui/assets/{transformers-env-w-btTDFl.js → transformers-env-sL29_hFb.js} +1 -1
- package/dist/ui/assets/{transformers.web-C6PlPLR-.js → transformers.web-CrioJkWG.js} +4 -4
- package/dist/ui/assets/{transformers.web-DkJGoARp.js → transformers.web-D6viRW2X.js} +5 -5
- package/dist/ui/assets/tray-follower-status-CyJIKXH4.js +1 -0
- package/dist/ui/assets/tray-join-url-BIvzbiFR.js +1 -0
- package/dist/ui/assets/tray-leader-DcLymd_E.js +1 -0
- package/dist/ui/assets/tray-leave-runtime-lJcLlwtm.js +1 -0
- package/dist/ui/assets/tray-runtime-config-DJIIJaBR.js +1 -0
- package/dist/ui/assets/tray-runtime-config-DlPGhxQs.js +1 -0
- package/dist/ui/assets/tray-sync-protocol-CVdiCvfU.js +1 -0
- package/dist/ui/assets/upgrade-detection-DIIyklC5.js +1 -0
- package/dist/ui/assets/usb-device-registry-BOGfZXgp.js +1 -0
- package/dist/ui/assets/{usb-operations-D-YdmmuG.js → usb-operations-BQbhk96u.js} +1 -1
- package/dist/ui/assets/usb-picker-Cl6Cwuv9.js +1 -0
- package/dist/ui/assets/voice-reply-DHV6R4En.js +1 -0
- package/dist/ui/assets/wc-attach-DU0svqb7.js +13 -0
- package/dist/ui/assets/wc-extension-oy0LEz26.js +2 -0
- package/dist/ui/assets/{wc-float-label-CNeJqRLg.js → wc-float-label-DeQPr3pd.js} +1 -1
- package/dist/ui/assets/wc-follower-DcQtc8YB.js +17 -0
- package/dist/ui/assets/wc-live-D7BaYtR7.js +8 -0
- package/dist/ui/assets/wc-nav-BqxVwvjV.js +2 -0
- package/dist/ui/assets/wc-onboarding-D9lPUOm-.js +2 -0
- package/dist/ui/assets/{wc-permissions-CAEOwurQ.js → wc-permissions-DW60QZxV.js} +3 -3
- package/dist/ui/assets/wc-permissions-providers-DMTDytlu.js +2 -0
- package/dist/ui/assets/wc-placeholder-C0wfdFBG.js +4 -0
- package/dist/ui/assets/wc-scoop-color-CByZNEJo.js +1 -0
- package/dist/ui/assets/wc-settings-qEE2zwaO.js +51 -0
- package/dist/ui/assets/wc-shell-BHZzK20y.js +117 -0
- package/dist/ui/assets/wc-sprinkles-DlE9uQTj.js +2 -0
- package/dist/ui/assets/wc-tray-BdFq9TlZ.js +2 -0
- package/dist/ui/assets/{whisper-engine-DBy-Rgc0.js → whisper-engine-C0mT2z02.js} +1 -1
- package/dist/ui/assets/whisper-session-DvjyTCj0.js +2 -0
- package/dist/ui/assets/xai-grok-Bx0idvJc.js +1 -0
- package/dist/ui/assets/xai-grok-CemZ8tZD.js +1 -0
- package/dist/ui/assets/xterm-DX7Hb5S-.js +47 -0
- package/dist/ui/assets/xterm-U4TA8lIC.js +35 -0
- package/dist/ui/index.html +24 -15
- package/dist/ui/packages/webapp/index.html +24 -15
- package/package.json +2 -2
- package/dist/ui/assets/__vite-browser-external-s4_sx6bN.js +0 -1
- package/dist/ui/assets/account-store-B2gG-qc_.js +0 -38
- package/dist/ui/assets/account-store-HRvOCmO4.js +0 -103
- package/dist/ui/assets/adobe-CHBAf7Hs.js +0 -1
- package/dist/ui/assets/adobe-CJZTrRE1.js +0 -2
- package/dist/ui/assets/adobe-oauth-state-C9eB9J5F.js +0 -1
- package/dist/ui/assets/agent-message-to-chat-ColCoNOH.js +0 -7
- package/dist/ui/assets/bedrock-camp-CZFsedRI.js +0 -1
- package/dist/ui/assets/bedrock-camp-Czep_VHL.js +0 -1
- package/dist/ui/assets/cdp-bridge-CUqQUcaF.js +0 -1
- package/dist/ui/assets/cerebras-C2wowhxn.js +0 -1
- package/dist/ui/assets/cerebras-CPDv_lSy.js +0 -1
- package/dist/ui/assets/clipboard-B_tsQU_u.js +0 -1
- package/dist/ui/assets/compat-FrhC6T45.js +0 -2
- package/dist/ui/assets/dip-DjQjKj4G.js +0 -1
- package/dist/ui/assets/discovery-preference-ChE43Rww.js +0 -1
- package/dist/ui/assets/dist-0c-Ms6jt.js +0 -23
- package/dist/ui/assets/dist-C30gQBcj2.js +0 -12
- package/dist/ui/assets/dist-CF1SACsY.js +0 -18
- package/dist/ui/assets/ensure-speech-assets-DOfhoSLd.js +0 -1
- package/dist/ui/assets/es-kEo2Tmh4.js +0 -53
- package/dist/ui/assets/esp8266-DhxGJGHR.js +0 -1
- package/dist/ui/assets/esp8266-dt3vHImh.js +0 -1
- package/dist/ui/assets/esptool-operations-BBtDOaij.js +0 -12
- package/dist/ui/assets/esptool-operations-wGO-l9-a.js +0 -13
- package/dist/ui/assets/extension-bridge-transport-Bi9JIuzJ.js +0 -1
- package/dist/ui/assets/fs-BuwyzyMW.js +0 -2
- package/dist/ui/assets/github-Bypbpxj_.js +0 -1
- package/dist/ui/assets/github-C85Bo5sl.js +0 -2
- package/dist/ui/assets/github-copilot-Bl3DpxDS.js +0 -2
- package/dist/ui/assets/github-copilot-BzF1rbqF.js +0 -1
- package/dist/ui/assets/hear-C7y434Fx.js +0 -1
- package/dist/ui/assets/hear-tL55Pr9X.js +0 -1
- package/dist/ui/assets/hid-device-registry-6w-g8ZpF.js +0 -1
- package/dist/ui/assets/hid-picker-Cp7Sp5N-.js +0 -1
- package/dist/ui/assets/kernel-worker-BwALz4mK.js +0 -10443
- package/dist/ui/assets/lick-ws-bridge-Cu9jmlYC.js +0 -1
- package/dist/ui/assets/main-CGnZl3f-.js +0 -24
- package/dist/ui/assets/mistral-conversations-DKqvekSA.js +0 -7
- package/dist/ui/assets/mistral-conversations-szVW8BsU.js +0 -8
- package/dist/ui/assets/mount-D5pPoQkC.js +0 -2
- package/dist/ui/assets/mount-id-nJcx05eu.js +0 -1
- package/dist/ui/assets/mount-table-store-s20mtVA3.js +0 -1
- package/dist/ui/assets/navigation-watcher-DTSw-td6.js +0 -1
- package/dist/ui/assets/new-session-Bs6AOhFK.js +0 -2
- package/dist/ui/assets/oauth-bootstrap-CE5ZvKUd.js +0 -2
- package/dist/ui/assets/oauth-service-Cf0jA8F5.js +0 -1
- package/dist/ui/assets/openai-codex-8wcYifFj.js +0 -1
- package/dist/ui/assets/openai-codex-xmVYehg_.js +0 -1
- package/dist/ui/assets/otel-BvlmHUjk.js +0 -3
- package/dist/ui/assets/otel-CCT7TRJr.js +0 -3
- package/dist/ui/assets/page-follower-tray-CowMs-O6.js +0 -5
- package/dist/ui/assets/panel-rpc-handlers-D7f3wT75.js +0 -2
- package/dist/ui/assets/preload-helper-CZgWQFsJ.js +0 -1
- package/dist/ui/assets/provider-DgMyEny4.js +0 -2
- package/dist/ui/assets/provider-m3ooafCg.js +0 -1
- package/dist/ui/assets/provider-settings-DJevRg9o.js +0 -1
- package/dist/ui/assets/provider-store-access-QXzphIMd.js +0 -1
- package/dist/ui/assets/provider-store-access-ZxL11bFB.js +0 -1
- package/dist/ui/assets/providers-B3oFOoQS.js +0 -1
- package/dist/ui/assets/providers-BW6jnLVy.js +0 -2
- package/dist/ui/assets/proxied-fetch-CQqrhHlW.js +0 -1
- package/dist/ui/assets/proxied-fetch-D3wsof0i.js +0 -2
- package/dist/ui/assets/remote-cdp-transport-DspFAFy_.js +0 -1
- package/dist/ui/assets/serial-picker-bJGym01W.js +0 -1
- package/dist/ui/assets/session-freezer-jxkdAA5Q.js +0 -1
- package/dist/ui/assets/sprinkle-manager-Bvx4CxCm.js +0 -1
- package/dist/ui/assets/src-BQoW5KdD.js +0 -1
- package/dist/ui/assets/src-BvERX0WZ.js +0 -1
- package/dist/ui/assets/store-B7DeyKtl.js +0 -1
- package/dist/ui/assets/transform-messages-DwI5R8if.js +0 -1
- package/dist/ui/assets/transformers-env-BwX2ts-q.js +0 -1
- package/dist/ui/assets/tray-leader-DKj3IyXq.js +0 -1
- package/dist/ui/assets/tray-leave-runtime-CPrd1hfA.js +0 -1
- package/dist/ui/assets/upgrade-detection-B_nKAXxR.js +0 -1
- package/dist/ui/assets/usb-device-registry-k6vTKonT.js +0 -1
- package/dist/ui/assets/usb-picker-DJjZemi7.js +0 -1
- package/dist/ui/assets/voice-reply-D08ppelD.js +0 -1
- package/dist/ui/assets/wc-attach-BD0vIfkn.js +0 -13
- package/dist/ui/assets/wc-extension-B6ny75yf.js +0 -2
- package/dist/ui/assets/wc-follower-DBHiqt6g.js +0 -17
- package/dist/ui/assets/wc-live-CuefElQr.js +0 -258
- package/dist/ui/assets/wc-nav-CQU9lWdP.js +0 -2
- package/dist/ui/assets/wc-onboarding-DaQiGWxH.js +0 -2
- package/dist/ui/assets/wc-permissions-providers-CbkqRh4J.js +0 -2
- package/dist/ui/assets/wc-placeholder-DCIY4YK0.js +0 -4
- package/dist/ui/assets/wc-settings-BDh89SFJ.js +0 -51
- package/dist/ui/assets/wc-sprinkles-CxI-YvJH.js +0 -2
- package/dist/ui/assets/wc-tray-DL8LCTDP.js +0 -2
- package/dist/ui/assets/whisper-session-C8cizjJD.js +0 -2
- package/dist/ui/assets/xai-grok-BnqGjgBw.js +0 -1
- package/dist/ui/assets/xai-grok-yL8zMte6.js +0 -1
- package/dist/ui/assets/xterm-DMlKjmUi.js +0 -36
- package/dist/ui/assets/xterm-Dwh1I9AE.js +0 -48
|
@@ -7,7 +7,7 @@ e.read=function(e,t,n,r,i){var a,o,s=i*8-r-1,c=(1<<s)-1,l=c>>1,u=-7,d=n?i-1:0,f=
|
|
|
7
7
|
* @author Feross Aboukhadijeh <https://feross.org>
|
|
8
8
|
* @license MIT
|
|
9
9
|
*/
|
|
10
|
-
let r=t(),i=n(),a=typeof Symbol==`function`&&typeof Symbol.for==`function`?Symbol.for(`nodejs.util.inspect.custom`):null;e.Buffer=l,e.SlowBuffer=b,e.INSPECT_MAX_BYTES=50;let o=2147483647;e.kMaxLength=o,l.TYPED_ARRAY_SUPPORT=s(),!l.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 s(){try{let e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),e.foo()===42}catch{return!1}}Object.defineProperty(l.prototype,"parent",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.buffer}}),Object.defineProperty(l.prototype,"offset",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.byteOffset}});function c(e){if(e>o)throw RangeError(`The value "`+e+`" is invalid for option "size"`);let t=new Uint8Array(e);return Object.setPrototypeOf(t,l.prototype),t}function l(e,t,n){if(typeof e==`number`){if(typeof t==`string`)throw TypeError(`The "string" argument must be of type string. Received type number`);return p(e)}return u(e,t,n)}l.poolSize=8192;function u(e,t,n){if(typeof e==`string`)return m(e,t);if(ArrayBuffer.isView(e))return g(e);if(e==null)throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e);if(L(e,ArrayBuffer)||e&&L(e.buffer,ArrayBuffer)||typeof SharedArrayBuffer<`u`&&(L(e,SharedArrayBuffer)||e&&L(e.buffer,SharedArrayBuffer)))return _(e,t,n);if(typeof e==`number`)throw TypeError(`The "value" argument must not be of type number. Received type number`);let r=e.valueOf&&e.valueOf();if(r!=null&&r!==e)return l.from(r,t,n);let i=v(e);if(i)return i;if(typeof Symbol<`u`&&Symbol.toPrimitive!=null&&typeof e[Symbol.toPrimitive]==`function`)return l.from(e[Symbol.toPrimitive](`string`),t,n);throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e)}l.from=function(e,t,n){return u(e,t,n)},Object.setPrototypeOf(l.prototype,Uint8Array.prototype),Object.setPrototypeOf(l,Uint8Array);function d(e){if(typeof e!=`number`)throw TypeError(`"size" argument must be of type number`);if(e<0)throw RangeError(`The value "`+e+`" is invalid for option "size"`)}function f(e,t,n){return d(e),e<=0||t===void 0?c(e):typeof n==`string`?c(e).fill(t,n):c(e).fill(t)}l.alloc=function(e,t,n){return f(e,t,n)};function p(e){return d(e),c(e<0?0:y(e)|0)}l.allocUnsafe=function(e){return p(e)},l.allocUnsafeSlow=function(e){return p(e)};function m(e,t){if((typeof t!=`string`||t===``)&&(t=`utf8`),!l.isEncoding(t))throw TypeError(`Unknown encoding: `+t);let n=x(e,t)|0,r=c(n),i=r.write(e,t);return i!==n&&(r=r.slice(0,i)),r}function h(e){let t=e.length<0?0:y(e.length)|0,n=c(t);for(let r=0;r<t;r+=1)n[r]=e[r]&255;return n}function g(e){if(L(e,Uint8Array)){let t=new Uint8Array(e);return _(t.buffer,t.byteOffset,t.byteLength)}return h(e)}function _(e,t,n){if(t<0||e.byteLength<t)throw RangeError(`"offset" is outside of buffer bounds`);if(e.byteLength<t+(n||0))throw RangeError(`"length" is outside of buffer bounds`);let r;return r=t===void 0&&n===void 0?new Uint8Array(e):n===void 0?new Uint8Array(e,t):new Uint8Array(e,t,n),Object.setPrototypeOf(r,l.prototype),r}function v(e){if(l.isBuffer(e)){let t=y(e.length)|0,n=c(t);return n.length===0||e.copy(n,0,0,t),n}if(e.length!==void 0)return typeof e.length!=`number`||R(e.length)?c(0):h(e);if(e.type===`Buffer`&&Array.isArray(e.data))return h(e.data)}function y(e){if(e>=o)throw RangeError(`Attempt to allocate Buffer larger than maximum size: 0x`+o.toString(16)+` bytes`);return e|0}function b(e){return+e!=e&&(e=0),l.alloc(+e)}l.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==l.prototype},l.compare=function(e,t){if(L(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),L(t,Uint8Array)&&(t=l.from(t,t.offset,t.byteLength)),!l.isBuffer(e)||!l.isBuffer(t))throw TypeError(`The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array`);if(e===t)return 0;let n=e.length,r=t.length;for(let i=0,a=Math.min(n,r);i<a;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:+(r<n)},l.isEncoding=function(e){switch(String(e).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}},l.concat=function(e,t){if(!Array.isArray(e))throw TypeError(`"list" argument must be an Array of Buffers`);if(e.length===0)return l.alloc(0);let n;if(t===void 0)for(t=0,n=0;n<e.length;++n)t+=e[n].length;let r=l.allocUnsafe(t),i=0;for(n=0;n<e.length;++n){let t=e[n];if(L(t,Uint8Array))i+t.length>r.length?(l.isBuffer(t)||(t=l.from(t)),t.copy(r,i)):Uint8Array.prototype.set.call(r,t,i);else if(l.isBuffer(t))t.copy(r,i);else throw TypeError(`"list" argument must be an Array of Buffers`);i+=t.length}return r};function x(e,t){if(l.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||L(e,ArrayBuffer))return e.byteLength;if(typeof e!=`string`)throw TypeError(`The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type `+typeof e);let n=e.length,r=arguments.length>2&&arguments[2]===!0;if(!r&&n===0)return 0;let i=!1;for(;;)switch(t){case`ascii`:case`latin1`:case`binary`:return n;case`utf8`:case`utf-8`:return ve(e).length;case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return n*2;case`hex`:return n>>>1;case`base64`:return xe(e).length;default:if(i)return r?-1:ve(e).length;t=(``+t).toLowerCase(),i=!0}}l.byteLength=x;function S(e,t,n){let r=!1;if((t===void 0||t<0)&&(t=0),t>this.length||((n===void 0||n>this.length)&&(n=this.length),n<=0)||(n>>>=0,t>>>=0,n<=t))return``;for(e||=`utf8`;;)switch(e){case`hex`:return ie(this,t,n);case`utf8`:case`utf-8`:return ee(this,t,n);case`ascii`:return ne(this,t,n);case`latin1`:case`binary`:return re(this,t,n);case`base64`:return j(this,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return ae(this,t,n);default:if(r)throw TypeError(`Unknown encoding: `+e);e=(e+``).toLowerCase(),r=!0}}l.prototype._isBuffer=!0;function C(e,t,n){let r=e[t];e[t]=e[n],e[n]=r}l.prototype.swap16=function(){let e=this.length;if(e%2!=0)throw RangeError(`Buffer size must be a multiple of 16-bits`);for(let t=0;t<e;t+=2)C(this,t,t+1);return this},l.prototype.swap32=function(){let e=this.length;if(e%4!=0)throw RangeError(`Buffer size must be a multiple of 32-bits`);for(let t=0;t<e;t+=4)C(this,t,t+3),C(this,t+1,t+2);return this},l.prototype.swap64=function(){let e=this.length;if(e%8!=0)throw RangeError(`Buffer size must be a multiple of 64-bits`);for(let t=0;t<e;t+=8)C(this,t,t+7),C(this,t+1,t+6),C(this,t+2,t+5),C(this,t+3,t+4);return this},l.prototype.toString=function(){let e=this.length;return e===0?``:arguments.length===0?ee(this,0,e):S.apply(this,arguments)},l.prototype.toLocaleString=l.prototype.toString,l.prototype.equals=function(e){if(!l.isBuffer(e))throw TypeError(`Argument must be a Buffer`);return this===e?!0:l.compare(this,e)===0},l.prototype.inspect=function(){let t=``,n=e.INSPECT_MAX_BYTES;return t=this.toString(`hex`,0,n).replace(/(.{2})/g,`$1 `).trim(),this.length>n&&(t+=` ... `),`<Buffer `+t+`>`},a&&(l.prototype[a]=l.prototype.inspect),l.prototype.compare=function(e,t,n,r,i){if(L(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),!l.isBuffer(e))throw TypeError(`The "target" argument must be one of type Buffer or Uint8Array. Received type `+typeof e);if(t===void 0&&(t=0),n===void 0&&(n=e?e.length:0),r===void 0&&(r=0),i===void 0&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw RangeError(`out of range index`);if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;let a=i-r,o=n-t,s=Math.min(a,o),c=this.slice(r,i),u=e.slice(t,n);for(let e=0;e<s;++e)if(c[e]!==u[e]){a=c[e],o=u[e];break}return a<o?-1:+(o<a)};function w(e,t,n,r,i){if(e.length===0)return-1;if(typeof n==`string`?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,R(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0)if(i)n=0;else return-1;if(typeof t==`string`&&(t=l.from(t,r)),l.isBuffer(t))return t.length===0?-1:T(e,t,n,r,i);if(typeof t==`number`)return t&=255,typeof Uint8Array.prototype.indexOf==`function`?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):T(e,[t],n,r,i);throw TypeError(`val must be string, number or Buffer`)}function T(e,t,n,r,i){let a=1,o=e.length,s=t.length;if(r!==void 0&&(r=String(r).toLowerCase(),r===`ucs2`||r===`ucs-2`||r===`utf16le`||r===`utf-16le`)){if(e.length<2||t.length<2)return-1;a=2,o/=2,s/=2,n/=2}function c(e,t){return a===1?e[t]:e.readUInt16BE(t*a)}let l;if(i){let r=-1;for(l=n;l<o;l++)if(c(e,l)===c(t,r===-1?0:l-r)){if(r===-1&&(r=l),l-r+1===s)return r*a}else r!==-1&&(l-=l-r),r=-1}else for(n+s>o&&(n=o-s),l=n;l>=0;l--){let n=!0;for(let r=0;r<s;r++)if(c(e,l+r)!==c(t,r)){n=!1;break}if(n)return l}return-1}l.prototype.includes=function(e,t,n){return this.indexOf(e,t,n)!==-1},l.prototype.indexOf=function(e,t,n){return w(this,e,t,n,!0)},l.prototype.lastIndexOf=function(e,t,n){return w(this,e,t,n,!1)};function E(e,t,n,r){n=Number(n)||0;let i=e.length-n;r?(r=Number(r),r>i&&(r=i)):r=i;let a=t.length;r>a/2&&(r=a/2);let o;for(o=0;o<r;++o){let r=parseInt(t.substr(o*2,2),16);if(R(r))return o;e[n+o]=r}return o}function D(e,t,n,r){return Se(ve(t,e.length-n),e,n,r)}function O(e,t,n,r){return Se(ye(t),e,n,r)}function k(e,t,n,r){return Se(xe(t),e,n,r)}function A(e,t,n,r){return Se(be(t,e.length-n),e,n,r)}l.prototype.write=function(e,t,n,r){if(t===void 0)r=`utf8`,n=this.length,t=0;else if(n===void 0&&typeof t==`string`)r=t,n=this.length,t=0;else if(isFinite(t))t>>>=0,isFinite(n)?(n>>>=0,r===void 0&&(r=`utf8`)):(r=n,n=void 0);else throw Error(`Buffer.write(string, encoding, offset[, length]) is no longer supported`);let i=this.length-t;if((n===void 0||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw RangeError(`Attempt to write outside buffer bounds`);r||=`utf8`;let a=!1;for(;;)switch(r){case`hex`:return E(this,e,t,n);case`utf8`:case`utf-8`:return D(this,e,t,n);case`ascii`:case`latin1`:case`binary`:return O(this,e,t,n);case`base64`:return k(this,e,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return A(this,e,t,n);default:if(a)throw TypeError(`Unknown encoding: `+r);r=(``+r).toLowerCase(),a=!0}},l.prototype.toJSON=function(){return{type:`Buffer`,data:Array.prototype.slice.call(this._arr||this,0)}};function j(e,t,n){return t===0&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function ee(e,t,n){n=Math.min(e.length,n);let r=[],i=t;for(;i<n;){let t=e[i],a=null,o=t>239?4:t>223?3:t>191?2:1;if(i+o<=n){let n,r,s,c;switch(o){case 1:t<128&&(a=t);break;case 2:n=e[i+1],(n&192)==128&&(c=(t&31)<<6|n&63,c>127&&(a=c));break;case 3:n=e[i+1],r=e[i+2],(n&192)==128&&(r&192)==128&&(c=(t&15)<<12|(n&63)<<6|r&63,c>2047&&(c<55296||c>57343)&&(a=c));break;case 4:n=e[i+1],r=e[i+2],s=e[i+3],(n&192)==128&&(r&192)==128&&(s&192)==128&&(c=(t&15)<<18|(n&63)<<12|(r&63)<<6|s&63,c>65535&&c<1114112&&(a=c))}}a===null?(a=65533,o=1):a>65535&&(a-=65536,r.push(a>>>10&1023|55296),a=56320|a&1023),r.push(a),i+=o}return te(r)}let M=4096;function te(e){let t=e.length;if(t<=M)return String.fromCharCode.apply(String,e);let n=``,r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=M));return n}function ne(e,t,n){let r=``;n=Math.min(e.length,n);for(let i=t;i<n;++i)r+=String.fromCharCode(e[i]&127);return r}function re(e,t,n){let r=``;n=Math.min(e.length,n);for(let i=t;i<n;++i)r+=String.fromCharCode(e[i]);return r}function ie(e,t,n){let r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);let i=``;for(let r=t;r<n;++r)i+=z[e[r]];return i}function ae(e,t,n){let r=e.slice(t,n),i=``;for(let e=0;e<r.length-1;e+=2)i+=String.fromCharCode(r[e]+r[e+1]*256);return i}l.prototype.slice=function(e,t){let n=this.length;e=~~e,t=t===void 0?n:~~t,e<0?(e+=n,e<0&&(e=0)):e>n&&(e=n),t<0?(t+=n,t<0&&(t=0)):t>n&&(t=n),t<e&&(t=e);let r=this.subarray(e,t);return Object.setPrototypeOf(r,l.prototype),r};function N(e,t,n){if(e%1!=0||e<0)throw RangeError(`offset is not uint`);if(e+t>n)throw RangeError(`Trying to access beyond buffer length`)}l.prototype.readUintLE=l.prototype.readUIntLE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=this[e],i=1,a=0;for(;++a<t&&(i*=256);)r+=this[e+a]*i;return r},l.prototype.readUintBE=l.prototype.readUIntBE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=this[e+--t],i=1;for(;t>0&&(i*=256);)r+=this[e+--t]*i;return r},l.prototype.readUint8=l.prototype.readUInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),this[e]},l.prototype.readUint16LE=l.prototype.readUInt16LE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUint16BE=l.prototype.readUInt16BE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUint32LE=l.prototype.readUInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216},l.prototype.readUint32BE=l.prototype.readUInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readBigUInt64LE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=t+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24,i=this[++e]+this[++e]*2**8+this[++e]*2**16+n*2**24;return BigInt(r)+(BigInt(i)<<BigInt(32))}),l.prototype.readBigUInt64BE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=t*2**24+this[++e]*2**16+this[++e]*2**8+this[++e],i=this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n;return(BigInt(r)<<BigInt(32))+BigInt(i)}),l.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=this[e],i=1,a=0;for(;++a<t&&(i*=256);)r+=this[e+a]*i;return i*=128,r>=i&&(r-=2**(8*t)),r},l.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=t,i=1,a=this[e+--r];for(;r>0&&(i*=256);)a+=this[e+--r]*i;return i*=128,a>=i&&(a-=2**(8*t)),a},l.prototype.readInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]},l.prototype.readInt16LE=function(e,t){e>>>=0,t||N(e,2,this.length);let n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n},l.prototype.readInt16BE=function(e,t){e>>>=0,t||N(e,2,this.length);let n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n},l.prototype.readInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readBigInt64LE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=this[e+4]+this[e+5]*2**8+this[e+6]*2**16+(n<<24);return(BigInt(r)<<BigInt(32))+BigInt(t+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24)}),l.prototype.readBigInt64BE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=(t<<24)+this[++e]*2**16+this[++e]*2**8+this[++e];return(BigInt(r)<<BigInt(32))+BigInt(this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n)}),l.prototype.readFloatLE=function(e,t){return e>>>=0,t||N(e,4,this.length),i.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,t){return e>>>=0,t||N(e,4,this.length),i.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,t){return e>>>=0,t||N(e,8,this.length),i.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,t){return e>>>=0,t||N(e,8,this.length),i.read(this,e,!1,52,8)};function P(e,t,n,r,i,a){if(!l.isBuffer(e))throw TypeError(`"buffer" argument must be a Buffer instance`);if(t>i||t<a)throw RangeError(`"value" argument is out of bounds`);if(n+r>e.length)throw RangeError(`Index out of range`)}l.prototype.writeUintLE=l.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){let r=2**(8*n)-1;P(this,e,t,n,r,0)}let i=1,a=0;for(this[t]=e&255;++a<n&&(i*=256);)this[t+a]=e/i&255;return t+n},l.prototype.writeUintBE=l.prototype.writeUIntBE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){let r=2**(8*n)-1;P(this,e,t,n,r,0)}let i=n-1,a=1;for(this[t+i]=e&255;--i>=0&&(a*=256);)this[t+i]=e/a&255;return t+n},l.prototype.writeUint8=l.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,1,255,0),this[t]=e&255,t+1},l.prototype.writeUint16LE=l.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,65535,0),this[t]=e&255,this[t+1]=e>>>8,t+2},l.prototype.writeUint16BE=l.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=e&255,t+2},l.prototype.writeUint32LE=l.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=e&255,t+4},l.prototype.writeUint32BE=l.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};function oe(e,t,n,r,i){me(t,r,i,e,n,7);let a=Number(t&BigInt(4294967295));e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n++]=o,o>>=8,e[n++]=o,o>>=8,e[n++]=o,o>>=8,e[n++]=o,n}function se(e,t,n,r,i){me(t,r,i,e,n,7);let a=Number(t&BigInt(4294967295));e[n+7]=a,a>>=8,e[n+6]=a,a>>=8,e[n+5]=a,a>>=8,e[n+4]=a;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n+3]=o,o>>=8,e[n+2]=o,o>>=8,e[n+1]=o,o>>=8,e[n]=o,n+8}l.prototype.writeBigUInt64LE=B(function(e,t=0){return oe(this,e,t,BigInt(0),BigInt(`0xffffffffffffffff`))}),l.prototype.writeBigUInt64BE=B(function(e,t=0){return se(this,e,t,BigInt(0),BigInt(`0xffffffffffffffff`))}),l.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){let r=2**(8*n-1);P(this,e,t,n,r-1,-r)}let i=0,a=1,o=0;for(this[t]=e&255;++i<n&&(a*=256);)e<0&&o===0&&this[t+i-1]!==0&&(o=1),this[t+i]=(e/a>>0)-o&255;return t+n},l.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){let r=2**(8*n-1);P(this,e,t,n,r-1,-r)}let i=n-1,a=1,o=0;for(this[t+i]=e&255;--i>=0&&(a*=256);)e<0&&o===0&&this[t+i+1]!==0&&(o=1),this[t+i]=(e/a>>0)-o&255;return t+n},l.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=e&255,t+1},l.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,32767,-32768),this[t]=e&255,this[t+1]=e>>>8,t+2},l.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=e&255,t+2},l.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,2147483647,-2147483648),this[t]=e&255,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},l.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4},l.prototype.writeBigInt64LE=B(function(e,t=0){return oe(this,e,t,-BigInt(`0x8000000000000000`),BigInt(`0x7fffffffffffffff`))}),l.prototype.writeBigInt64BE=B(function(e,t=0){return se(this,e,t,-BigInt(`0x8000000000000000`),BigInt(`0x7fffffffffffffff`))});function ce(e,t,n,r,i,a){if(n+r>e.length||n<0)throw RangeError(`Index out of range`)}function le(e,t,n,r,a){return t=+t,n>>>=0,a||ce(e,t,n,4,34028234663852886e22,-34028234663852886e22),i.write(e,t,n,r,23,4),n+4}l.prototype.writeFloatLE=function(e,t,n){return le(this,e,t,!0,n)},l.prototype.writeFloatBE=function(e,t,n){return le(this,e,t,!1,n)};function ue(e,t,n,r,a){return t=+t,n>>>=0,a||ce(e,t,n,8,17976931348623157e292,-17976931348623157e292),i.write(e,t,n,r,52,8),n+8}l.prototype.writeDoubleLE=function(e,t,n){return ue(this,e,t,!0,n)},l.prototype.writeDoubleBE=function(e,t,n){return ue(this,e,t,!1,n)},l.prototype.copy=function(e,t,n,r){if(!l.isBuffer(e))throw TypeError(`argument should be a Buffer`);if(n||=0,!r&&r!==0&&(r=this.length),t>=e.length&&(t=e.length),t||=0,r>0&&r<n&&(r=n),r===n||e.length===0||this.length===0)return 0;if(t<0)throw RangeError(`targetStart out of bounds`);if(n<0||n>=this.length)throw RangeError(`Index out of range`);if(r<0)throw RangeError(`sourceEnd out of bounds`);r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);let i=r-n;return this===e&&typeof Uint8Array.prototype.copyWithin==`function`?this.copyWithin(t,n,r):Uint8Array.prototype.set.call(e,this.subarray(n,r),t),i},l.prototype.fill=function(e,t,n,r){if(typeof e==`string`){if(typeof t==`string`?(r=t,t=0,n=this.length):typeof n==`string`&&(r=n,n=this.length),r!==void 0&&typeof r!=`string`)throw TypeError(`encoding must be a string`);if(typeof r==`string`&&!l.isEncoding(r))throw TypeError(`Unknown encoding: `+r);if(e.length===1){let t=e.charCodeAt(0);(r===`utf8`&&t<128||r===`latin1`)&&(e=t)}}else typeof e==`number`?e&=255:typeof e==`boolean`&&(e=Number(e));if(t<0||this.length<t||this.length<n)throw RangeError(`Out of range index`);if(n<=t)return this;t>>>=0,n=n===void 0?this.length:n>>>0,e||=0;let i;if(typeof e==`number`)for(i=t;i<n;++i)this[i]=e;else{let a=l.isBuffer(e)?e:l.from(e,r),o=a.length;if(o===0)throw TypeError(`The value "`+e+`" is invalid for argument "value"`);for(i=0;i<n-t;++i)this[i+t]=a[i%o]}return this};let de={};function fe(e,t,n){de[e]=class extends n{constructor(){super(),Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(e){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:e,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}fe(`ERR_BUFFER_OUT_OF_BOUNDS`,function(e){return e?`${e} is outside of buffer bounds`:`Attempt to access memory outside buffer bounds`},RangeError),fe(`ERR_INVALID_ARG_TYPE`,function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`},TypeError),fe(`ERR_OUT_OF_RANGE`,function(e,t,n){let r=`The value of "${e}" is out of range.`,i=n;return Number.isInteger(n)&&Math.abs(n)>2**32?i=F(String(n)):typeof n==`bigint`&&(i=String(n),(n>BigInt(2)**BigInt(32)||n<-(BigInt(2)**BigInt(32)))&&(i=F(i)),i+=`n`),r+=` It must be ${t}. Received ${i}`,r},RangeError);function F(e){let t=``,n=e.length,r=+(e[0]===`-`);for(;n>=r+4;n-=3)t=`_${e.slice(n-3,n)}${t}`;return`${e.slice(0,n)}${t}`}function pe(e,t,n){I(t,`offset`),(e[t]===void 0||e[t+n]===void 0)&&he(t,e.length-(n+1))}function me(e,t,n,r,i,a){if(e>n||e<t){let r=typeof t==`bigint`?`n`:``,i;throw i=a>3?t===0||t===BigInt(0)?`>= 0${r} and < 2${r} ** ${(a+1)*8}${r}`:`>= -(2${r} ** ${(a+1)*8-1}${r}) and < 2 ** ${(a+1)*8-1}${r}`:`>= ${t}${r} and <= ${n}${r}`,new de.ERR_OUT_OF_RANGE(`value`,i,e)}pe(r,i,a)}function I(e,t){if(typeof e!=`number`)throw new de.ERR_INVALID_ARG_TYPE(t,`number`,e)}function he(e,t,n){throw Math.floor(e)===e?t<0?new de.ERR_BUFFER_OUT_OF_BOUNDS:new de.ERR_OUT_OF_RANGE(n||`offset`,`>= ${+!!n} and <= ${t}`,e):(I(e,n),new de.ERR_OUT_OF_RANGE(n||`offset`,`an integer`,e))}let ge=/[^+/0-9A-Za-z-_]/g;function _e(e){if(e=e.split(`=`)[0],e=e.trim().replace(ge,``),e.length<2)return``;for(;e.length%4!=0;)e+=`=`;return e}function ve(e,t){t||=1/0;let n,r=e.length,i=null,a=[];for(let o=0;o<r;++o){if(n=e.charCodeAt(o),n>55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&a.push(239,191,189);continue}else if(o+1===r){(t-=3)>-1&&a.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&a.push(239,191,189),i=n;continue}n=(i-55296<<10|n-56320)+65536}else i&&(t-=3)>-1&&a.push(239,191,189);if(i=null,n<128){if(--t<0)break;a.push(n)}else if(n<2048){if((t-=2)<0)break;a.push(n>>6|192,n&63|128)}else if(n<65536){if((t-=3)<0)break;a.push(n>>12|224,n>>6&63|128,n&63|128)}else if(n<1114112){if((t-=4)<0)break;a.push(n>>18|240,n>>12&63|128,n>>6&63|128,n&63|128)}else throw Error(`Invalid code point`)}return a}function ye(e){let t=[];for(let n=0;n<e.length;++n)t.push(e.charCodeAt(n)&255);return t}function be(e,t){let n,r,i,a=[];for(let o=0;o<e.length&&!((t-=2)<0);++o)n=e.charCodeAt(o),r=n>>8,i=n%256,a.push(i),a.push(r);return a}function xe(e){return r.toByteArray(_e(e))}function Se(e,t,n,r){let i;for(i=0;i<r&&!(i+n>=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function L(e,t){return e instanceof t||e!=null&&e.constructor!=null&&e.constructor.name!=null&&e.constructor.name===t.name}function R(e){return e!==e}let z=(function(){let e=`0123456789abcdef`,t=Array(256);for(let n=0;n<16;++n){let r=n*16;for(let i=0;i<16;++i)t[r+i]=e[n]+e[i]}return t})();function B(e){return typeof BigInt>`u`?Ce:e}function Ce(){throw Error(`BigInt not supported`)}})),i=r();globalThis.Buffer===void 0&&(globalThis.Buffer=i.Buffer);var a=class extends Error{status;statusText;url;body;constructor(e,t,n,r){let i=typeof r==`string`&&r?`: ${r.slice(0,200)}`:r&&typeof r==`object`?`: ${o(r).slice(0,200)}`:``;super(`HTTP ${e} ${t} ${n}${i}`),this.status=e,this.statusText=t,this.url=n,this.body=r,this.name=`HttpError`}};function o(e){try{return JSON.stringify(e)}catch{return String(e)}}function s(e){return new Promise(t=>setTimeout(t,e))}function c(e,t,n){let r;if(r=/^[a-z][a-z0-9+.-]*:\/\//i.test(t)?t:e?`${e.endsWith(`/`)?e.slice(0,-1):e}${t.startsWith(`/`)?t:`/${t}`}`:t,!n)return r;let i=[];for(let[e,t]of Object.entries(n))if(t!=null)if(Array.isArray(t))for(let n of t)n!=null&&i.push(`${encodeURIComponent(e)}=${encodeURIComponent(String(n))}`);else i.push(`${encodeURIComponent(e)}=${encodeURIComponent(String(t))}`);return i.length===0?r:r+(r.includes(`?`)?`&`:`?`)+i.join(`&`)}function l(e,t){let n={};if(e)for(let[t,r]of Object.entries(e))n[t]=r;if(t)for(let[e,r]of Object.entries(t))n[e]=r;return n}function u(e){if(!e)return!1;let t=e.toLowerCase();return t.startsWith(`application/json`)||/[+/]json(;|$|\s)/.test(t)}function d(e){if(!e)return null;let t=e.trim();if(!t)return null;if(/^\d+(\.\d+)?$/.test(t)){let e=Number(t);if(Number.isFinite(e)&&e>=0)return Math.round(e*1e3)}let n=Date.parse(t);if(Number.isFinite(n)){let e=n-Date.now();return e>0?e:0}return null}async function f(e){if(u(e.headers.get(`content-type`))){let t=await e.text();if(!t)return null;try{return JSON.parse(t)}catch{return t}}return e.text()}function p(e,t){if(e!=null)return typeof e==`string`||e instanceof ArrayBuffer||ArrayBuffer.isView(e)||typeof Blob<`u`&&e instanceof Blob||typeof FormData<`u`&&e instanceof FormData||typeof URLSearchParams<`u`&&e instanceof URLSearchParams||typeof ReadableStream<`u`&&e instanceof ReadableStream?e:typeof e==`object`?(Object.keys(t).some(e=>e.toLowerCase()===`content-type`)||(t[`Content-Type`]=`application/json`),JSON.stringify(e)):String(e)}function m(e){let t=e.sleep??s;function n(n){let r=new Set(n.retry?.on??[]),i=Math.max(1,Math.trunc(n.retry?.maxAttempts??1));async function o(o,s,u={}){let m=c(n.baseUrl,s,u.params),h=l(n.headers,u.headers);if(n.token){let e=await n.token({method:o,path:s,url:m});e&&(Object.keys(h).some(e=>e.toLowerCase()===`authorization`)||(h.Authorization=`Bearer ${e}`))}let g=p(u.body,h),_={method:o,headers:h};g!==void 0&&(_.body=g);let v=null;for(let o=0;o<i;o++){let s=n.timeoutMs?new AbortController:null,c=s?setTimeout(()=>s.abort(Error(`timeout`)),n.timeoutMs):null,l=u.signal&&s?.signal?AbortSignal.any([u.signal,s.signal]):u.signal??s?.signal,p=l?{..._,signal:l}:_,h;try{h=await e.fetch(m,p)}finally{c!==null&&clearTimeout(c)}if(v=h,h.ok){let e=await f(h);return u.raw?{body:e,headers:Object.fromEntries(h.headers.entries()),status:h.status}:e}if(!(o+1<i&&r.has(h.status))){let e=await f(h).catch(()=>null);throw new a(h.status,h.statusText,m,e)}let g=d(h.headers.get(`retry-after`)),y=500*2**o;await t(g===null?y:g)}if(v){let e=await f(v).catch(()=>null);throw new a(v.status,v.statusText,m,e)}throw Error(`http: no attempts made for ${o} ${m}`)}return Object.freeze({get:((e,t)=>o(`GET`,e,t)),post:((e,t)=>o(`POST`,e,t)),put:((e,t)=>o(`PUT`,e,t)),patch:((e,t)=>o(`PATCH`,e,t)),delete:((e,t)=>o(`DELETE`,e,t))})}return Object.freeze({client:n})}var h=e(((e,t)=>{t.exports={}})),g=e(((e,t)=>{
|
|
10
|
+
let r=t(),i=n(),a=typeof Symbol==`function`&&typeof Symbol.for==`function`?Symbol.for(`nodejs.util.inspect.custom`):null;e.Buffer=l,e.SlowBuffer=b,e.INSPECT_MAX_BYTES=50;let o=2147483647;e.kMaxLength=o,l.TYPED_ARRAY_SUPPORT=s(),!l.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 s(){try{let e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),e.foo()===42}catch{return!1}}Object.defineProperty(l.prototype,"parent",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.buffer}}),Object.defineProperty(l.prototype,"offset",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.byteOffset}});function c(e){if(e>o)throw RangeError(`The value "`+e+`" is invalid for option "size"`);let t=new Uint8Array(e);return Object.setPrototypeOf(t,l.prototype),t}function l(e,t,n){if(typeof e==`number`){if(typeof t==`string`)throw TypeError(`The "string" argument must be of type string. Received type number`);return p(e)}return u(e,t,n)}l.poolSize=8192;function u(e,t,n){if(typeof e==`string`)return m(e,t);if(ArrayBuffer.isView(e))return g(e);if(e==null)throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e);if(L(e,ArrayBuffer)||e&&L(e.buffer,ArrayBuffer)||typeof SharedArrayBuffer<`u`&&(L(e,SharedArrayBuffer)||e&&L(e.buffer,SharedArrayBuffer)))return _(e,t,n);if(typeof e==`number`)throw TypeError(`The "value" argument must not be of type number. Received type number`);let r=e.valueOf&&e.valueOf();if(r!=null&&r!==e)return l.from(r,t,n);let i=v(e);if(i)return i;if(typeof Symbol<`u`&&Symbol.toPrimitive!=null&&typeof e[Symbol.toPrimitive]==`function`)return l.from(e[Symbol.toPrimitive](`string`),t,n);throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e)}l.from=function(e,t,n){return u(e,t,n)},Object.setPrototypeOf(l.prototype,Uint8Array.prototype),Object.setPrototypeOf(l,Uint8Array);function d(e){if(typeof e!=`number`)throw TypeError(`"size" argument must be of type number`);if(e<0)throw RangeError(`The value "`+e+`" is invalid for option "size"`)}function f(e,t,n){return d(e),e<=0||t===void 0?c(e):typeof n==`string`?c(e).fill(t,n):c(e).fill(t)}l.alloc=function(e,t,n){return f(e,t,n)};function p(e){return d(e),c(e<0?0:y(e)|0)}l.allocUnsafe=function(e){return p(e)},l.allocUnsafeSlow=function(e){return p(e)};function m(e,t){if((typeof t!=`string`||t===``)&&(t=`utf8`),!l.isEncoding(t))throw TypeError(`Unknown encoding: `+t);let n=x(e,t)|0,r=c(n),i=r.write(e,t);return i!==n&&(r=r.slice(0,i)),r}function h(e){let t=e.length<0?0:y(e.length)|0,n=c(t);for(let r=0;r<t;r+=1)n[r]=e[r]&255;return n}function g(e){if(L(e,Uint8Array)){let t=new Uint8Array(e);return _(t.buffer,t.byteOffset,t.byteLength)}return h(e)}function _(e,t,n){if(t<0||e.byteLength<t)throw RangeError(`"offset" is outside of buffer bounds`);if(e.byteLength<t+(n||0))throw RangeError(`"length" is outside of buffer bounds`);let r;return r=t===void 0&&n===void 0?new Uint8Array(e):n===void 0?new Uint8Array(e,t):new Uint8Array(e,t,n),Object.setPrototypeOf(r,l.prototype),r}function v(e){if(l.isBuffer(e)){let t=y(e.length)|0,n=c(t);return n.length===0||e.copy(n,0,0,t),n}if(e.length!==void 0)return typeof e.length!=`number`||R(e.length)?c(0):h(e);if(e.type===`Buffer`&&Array.isArray(e.data))return h(e.data)}function y(e){if(e>=o)throw RangeError(`Attempt to allocate Buffer larger than maximum size: 0x`+o.toString(16)+` bytes`);return e|0}function b(e){return+e!=e&&(e=0),l.alloc(+e)}l.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==l.prototype},l.compare=function(e,t){if(L(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),L(t,Uint8Array)&&(t=l.from(t,t.offset,t.byteLength)),!l.isBuffer(e)||!l.isBuffer(t))throw TypeError(`The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array`);if(e===t)return 0;let n=e.length,r=t.length;for(let i=0,a=Math.min(n,r);i<a;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:+(r<n)},l.isEncoding=function(e){switch(String(e).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}},l.concat=function(e,t){if(!Array.isArray(e))throw TypeError(`"list" argument must be an Array of Buffers`);if(e.length===0)return l.alloc(0);let n;if(t===void 0)for(t=0,n=0;n<e.length;++n)t+=e[n].length;let r=l.allocUnsafe(t),i=0;for(n=0;n<e.length;++n){let t=e[n];if(L(t,Uint8Array))i+t.length>r.length?(l.isBuffer(t)||(t=l.from(t)),t.copy(r,i)):Uint8Array.prototype.set.call(r,t,i);else if(l.isBuffer(t))t.copy(r,i);else throw TypeError(`"list" argument must be an Array of Buffers`);i+=t.length}return r};function x(e,t){if(l.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||L(e,ArrayBuffer))return e.byteLength;if(typeof e!=`string`)throw TypeError(`The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type `+typeof e);let n=e.length,r=arguments.length>2&&arguments[2]===!0;if(!r&&n===0)return 0;let i=!1;for(;;)switch(t){case`ascii`:case`latin1`:case`binary`:return n;case`utf8`:case`utf-8`:return ve(e).length;case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return n*2;case`hex`:return n>>>1;case`base64`:return xe(e).length;default:if(i)return r?-1:ve(e).length;t=(``+t).toLowerCase(),i=!0}}l.byteLength=x;function S(e,t,n){let r=!1;if((t===void 0||t<0)&&(t=0),t>this.length||((n===void 0||n>this.length)&&(n=this.length),n<=0)||(n>>>=0,t>>>=0,n<=t))return``;for(e||=`utf8`;;)switch(e){case`hex`:return ie(this,t,n);case`utf8`:case`utf-8`:return ee(this,t,n);case`ascii`:return ne(this,t,n);case`latin1`:case`binary`:return re(this,t,n);case`base64`:return j(this,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return ae(this,t,n);default:if(r)throw TypeError(`Unknown encoding: `+e);e=(e+``).toLowerCase(),r=!0}}l.prototype._isBuffer=!0;function C(e,t,n){let r=e[t];e[t]=e[n],e[n]=r}l.prototype.swap16=function(){let e=this.length;if(e%2!=0)throw RangeError(`Buffer size must be a multiple of 16-bits`);for(let t=0;t<e;t+=2)C(this,t,t+1);return this},l.prototype.swap32=function(){let e=this.length;if(e%4!=0)throw RangeError(`Buffer size must be a multiple of 32-bits`);for(let t=0;t<e;t+=4)C(this,t,t+3),C(this,t+1,t+2);return this},l.prototype.swap64=function(){let e=this.length;if(e%8!=0)throw RangeError(`Buffer size must be a multiple of 64-bits`);for(let t=0;t<e;t+=8)C(this,t,t+7),C(this,t+1,t+6),C(this,t+2,t+5),C(this,t+3,t+4);return this},l.prototype.toString=function(){let e=this.length;return e===0?``:arguments.length===0?ee(this,0,e):S.apply(this,arguments)},l.prototype.toLocaleString=l.prototype.toString,l.prototype.equals=function(e){if(!l.isBuffer(e))throw TypeError(`Argument must be a Buffer`);return this===e||l.compare(this,e)===0},l.prototype.inspect=function(){let t=``,n=e.INSPECT_MAX_BYTES;return t=this.toString(`hex`,0,n).replace(/(.{2})/g,`$1 `).trim(),this.length>n&&(t+=` ... `),`<Buffer `+t+`>`},a&&(l.prototype[a]=l.prototype.inspect),l.prototype.compare=function(e,t,n,r,i){if(L(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),!l.isBuffer(e))throw TypeError(`The "target" argument must be one of type Buffer or Uint8Array. Received type `+typeof e);if(t===void 0&&(t=0),n===void 0&&(n=e?e.length:0),r===void 0&&(r=0),i===void 0&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw RangeError(`out of range index`);if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;let a=i-r,o=n-t,s=Math.min(a,o),c=this.slice(r,i),u=e.slice(t,n);for(let e=0;e<s;++e)if(c[e]!==u[e]){a=c[e],o=u[e];break}return a<o?-1:+(o<a)};function w(e,t,n,r,i){if(e.length===0)return-1;if(typeof n==`string`?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,R(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0)if(i)n=0;else return-1;if(typeof t==`string`&&(t=l.from(t,r)),l.isBuffer(t))return t.length===0?-1:T(e,t,n,r,i);if(typeof t==`number`)return t&=255,typeof Uint8Array.prototype.indexOf==`function`?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):T(e,[t],n,r,i);throw TypeError(`val must be string, number or Buffer`)}function T(e,t,n,r,i){let a=1,o=e.length,s=t.length;if(r!==void 0&&(r=String(r).toLowerCase(),r===`ucs2`||r===`ucs-2`||r===`utf16le`||r===`utf-16le`)){if(e.length<2||t.length<2)return-1;a=2,o/=2,s/=2,n/=2}function c(e,t){return a===1?e[t]:e.readUInt16BE(t*a)}let l;if(i){let r=-1;for(l=n;l<o;l++)if(c(e,l)===c(t,r===-1?0:l-r)){if(r===-1&&(r=l),l-r+1===s)return r*a}else r!==-1&&(l-=l-r),r=-1}else for(n+s>o&&(n=o-s),l=n;l>=0;l--){let n=!0;for(let r=0;r<s;r++)if(c(e,l+r)!==c(t,r)){n=!1;break}if(n)return l}return-1}l.prototype.includes=function(e,t,n){return this.indexOf(e,t,n)!==-1},l.prototype.indexOf=function(e,t,n){return w(this,e,t,n,!0)},l.prototype.lastIndexOf=function(e,t,n){return w(this,e,t,n,!1)};function E(e,t,n,r){n=Number(n)||0;let i=e.length-n;r?(r=Number(r),r>i&&(r=i)):r=i;let a=t.length;r>a/2&&(r=a/2);let o;for(o=0;o<r;++o){let r=parseInt(t.substr(o*2,2),16);if(R(r))return o;e[n+o]=r}return o}function D(e,t,n,r){return Se(ve(t,e.length-n),e,n,r)}function O(e,t,n,r){return Se(ye(t),e,n,r)}function k(e,t,n,r){return Se(xe(t),e,n,r)}function A(e,t,n,r){return Se(be(t,e.length-n),e,n,r)}l.prototype.write=function(e,t,n,r){if(t===void 0)r=`utf8`,n=this.length,t=0;else if(n===void 0&&typeof t==`string`)r=t,n=this.length,t=0;else if(isFinite(t))t>>>=0,isFinite(n)?(n>>>=0,r===void 0&&(r=`utf8`)):(r=n,n=void 0);else throw Error(`Buffer.write(string, encoding, offset[, length]) is no longer supported`);let i=this.length-t;if((n===void 0||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw RangeError(`Attempt to write outside buffer bounds`);r||=`utf8`;let a=!1;for(;;)switch(r){case`hex`:return E(this,e,t,n);case`utf8`:case`utf-8`:return D(this,e,t,n);case`ascii`:case`latin1`:case`binary`:return O(this,e,t,n);case`base64`:return k(this,e,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return A(this,e,t,n);default:if(a)throw TypeError(`Unknown encoding: `+r);r=(``+r).toLowerCase(),a=!0}},l.prototype.toJSON=function(){return{type:`Buffer`,data:Array.prototype.slice.call(this._arr||this,0)}};function j(e,t,n){return t===0&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function ee(e,t,n){n=Math.min(e.length,n);let r=[],i=t;for(;i<n;){let t=e[i],a=null,o=t>239?4:t>223?3:t>191?2:1;if(i+o<=n){let n,r,s,c;switch(o){case 1:t<128&&(a=t);break;case 2:n=e[i+1],(n&192)==128&&(c=(t&31)<<6|n&63,c>127&&(a=c));break;case 3:n=e[i+1],r=e[i+2],(n&192)==128&&(r&192)==128&&(c=(t&15)<<12|(n&63)<<6|r&63,c>2047&&(c<55296||c>57343)&&(a=c));break;case 4:n=e[i+1],r=e[i+2],s=e[i+3],(n&192)==128&&(r&192)==128&&(s&192)==128&&(c=(t&15)<<18|(n&63)<<12|(r&63)<<6|s&63,c>65535&&c<1114112&&(a=c))}}a===null?(a=65533,o=1):a>65535&&(a-=65536,r.push(a>>>10&1023|55296),a=56320|a&1023),r.push(a),i+=o}return te(r)}let M=4096;function te(e){let t=e.length;if(t<=M)return String.fromCharCode.apply(String,e);let n=``,r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=M));return n}function ne(e,t,n){let r=``;n=Math.min(e.length,n);for(let i=t;i<n;++i)r+=String.fromCharCode(e[i]&127);return r}function re(e,t,n){let r=``;n=Math.min(e.length,n);for(let i=t;i<n;++i)r+=String.fromCharCode(e[i]);return r}function ie(e,t,n){let r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);let i=``;for(let r=t;r<n;++r)i+=z[e[r]];return i}function ae(e,t,n){let r=e.slice(t,n),i=``;for(let e=0;e<r.length-1;e+=2)i+=String.fromCharCode(r[e]+r[e+1]*256);return i}l.prototype.slice=function(e,t){let n=this.length;e=~~e,t=t===void 0?n:~~t,e<0?(e+=n,e<0&&(e=0)):e>n&&(e=n),t<0?(t+=n,t<0&&(t=0)):t>n&&(t=n),t<e&&(t=e);let r=this.subarray(e,t);return Object.setPrototypeOf(r,l.prototype),r};function N(e,t,n){if(e%1!=0||e<0)throw RangeError(`offset is not uint`);if(e+t>n)throw RangeError(`Trying to access beyond buffer length`)}l.prototype.readUintLE=l.prototype.readUIntLE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=this[e],i=1,a=0;for(;++a<t&&(i*=256);)r+=this[e+a]*i;return r},l.prototype.readUintBE=l.prototype.readUIntBE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=this[e+--t],i=1;for(;t>0&&(i*=256);)r+=this[e+--t]*i;return r},l.prototype.readUint8=l.prototype.readUInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),this[e]},l.prototype.readUint16LE=l.prototype.readUInt16LE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUint16BE=l.prototype.readUInt16BE=function(e,t){return e>>>=0,t||N(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUint32LE=l.prototype.readUInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216},l.prototype.readUint32BE=l.prototype.readUInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readBigUInt64LE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=t+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24,i=this[++e]+this[++e]*2**8+this[++e]*2**16+n*2**24;return BigInt(r)+(BigInt(i)<<BigInt(32))}),l.prototype.readBigUInt64BE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=t*2**24+this[++e]*2**16+this[++e]*2**8+this[++e],i=this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n;return(BigInt(r)<<BigInt(32))+BigInt(i)}),l.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=this[e],i=1,a=0;for(;++a<t&&(i*=256);)r+=this[e+a]*i;return i*=128,r>=i&&(r-=2**(8*t)),r},l.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||N(e,t,this.length);let r=t,i=1,a=this[e+--r];for(;r>0&&(i*=256);)a+=this[e+--r]*i;return i*=128,a>=i&&(a-=2**(8*t)),a},l.prototype.readInt8=function(e,t){return e>>>=0,t||N(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]},l.prototype.readInt16LE=function(e,t){e>>>=0,t||N(e,2,this.length);let n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n},l.prototype.readInt16BE=function(e,t){e>>>=0,t||N(e,2,this.length);let n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n},l.prototype.readInt32LE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,t){return e>>>=0,t||N(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readBigInt64LE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=this[e+4]+this[e+5]*2**8+this[e+6]*2**16+(n<<24);return(BigInt(r)<<BigInt(32))+BigInt(t+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24)}),l.prototype.readBigInt64BE=B(function(e){e>>>=0,I(e,`offset`);let t=this[e],n=this[e+7];(t===void 0||n===void 0)&&he(e,this.length-8);let r=(t<<24)+this[++e]*2**16+this[++e]*2**8+this[++e];return(BigInt(r)<<BigInt(32))+BigInt(this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n)}),l.prototype.readFloatLE=function(e,t){return e>>>=0,t||N(e,4,this.length),i.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,t){return e>>>=0,t||N(e,4,this.length),i.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,t){return e>>>=0,t||N(e,8,this.length),i.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,t){return e>>>=0,t||N(e,8,this.length),i.read(this,e,!1,52,8)};function P(e,t,n,r,i,a){if(!l.isBuffer(e))throw TypeError(`"buffer" argument must be a Buffer instance`);if(t>i||t<a)throw RangeError(`"value" argument is out of bounds`);if(n+r>e.length)throw RangeError(`Index out of range`)}l.prototype.writeUintLE=l.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){let r=2**(8*n)-1;P(this,e,t,n,r,0)}let i=1,a=0;for(this[t]=e&255;++a<n&&(i*=256);)this[t+a]=e/i&255;return t+n},l.prototype.writeUintBE=l.prototype.writeUIntBE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){let r=2**(8*n)-1;P(this,e,t,n,r,0)}let i=n-1,a=1;for(this[t+i]=e&255;--i>=0&&(a*=256);)this[t+i]=e/a&255;return t+n},l.prototype.writeUint8=l.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,1,255,0),this[t]=e&255,t+1},l.prototype.writeUint16LE=l.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,65535,0),this[t]=e&255,this[t+1]=e>>>8,t+2},l.prototype.writeUint16BE=l.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=e&255,t+2},l.prototype.writeUint32LE=l.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=e&255,t+4},l.prototype.writeUint32BE=l.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};function oe(e,t,n,r,i){me(t,r,i,e,n,7);let a=Number(t&BigInt(4294967295));e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n++]=o,o>>=8,e[n++]=o,o>>=8,e[n++]=o,o>>=8,e[n++]=o,n}function se(e,t,n,r,i){me(t,r,i,e,n,7);let a=Number(t&BigInt(4294967295));e[n+7]=a,a>>=8,e[n+6]=a,a>>=8,e[n+5]=a,a>>=8,e[n+4]=a;let o=Number(t>>BigInt(32)&BigInt(4294967295));return e[n+3]=o,o>>=8,e[n+2]=o,o>>=8,e[n+1]=o,o>>=8,e[n]=o,n+8}l.prototype.writeBigUInt64LE=B(function(e,t=0){return oe(this,e,t,BigInt(0),BigInt(`0xffffffffffffffff`))}),l.prototype.writeBigUInt64BE=B(function(e,t=0){return se(this,e,t,BigInt(0),BigInt(`0xffffffffffffffff`))}),l.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){let r=2**(8*n-1);P(this,e,t,n,r-1,-r)}let i=0,a=1,o=0;for(this[t]=e&255;++i<n&&(a*=256);)e<0&&o===0&&this[t+i-1]!==0&&(o=1),this[t+i]=(e/a>>0)-o&255;return t+n},l.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){let r=2**(8*n-1);P(this,e,t,n,r-1,-r)}let i=n-1,a=1,o=0;for(this[t+i]=e&255;--i>=0&&(a*=256);)e<0&&o===0&&this[t+i+1]!==0&&(o=1),this[t+i]=(e/a>>0)-o&255;return t+n},l.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=e&255,t+1},l.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,32767,-32768),this[t]=e&255,this[t+1]=e>>>8,t+2},l.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=e&255,t+2},l.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,2147483647,-2147483648),this[t]=e&255,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},l.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||P(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4},l.prototype.writeBigInt64LE=B(function(e,t=0){return oe(this,e,t,-BigInt(`0x8000000000000000`),BigInt(`0x7fffffffffffffff`))}),l.prototype.writeBigInt64BE=B(function(e,t=0){return se(this,e,t,-BigInt(`0x8000000000000000`),BigInt(`0x7fffffffffffffff`))});function ce(e,t,n,r,i,a){if(n+r>e.length||n<0)throw RangeError(`Index out of range`)}function le(e,t,n,r,a){return t=+t,n>>>=0,a||ce(e,t,n,4,34028234663852886e22,-34028234663852886e22),i.write(e,t,n,r,23,4),n+4}l.prototype.writeFloatLE=function(e,t,n){return le(this,e,t,!0,n)},l.prototype.writeFloatBE=function(e,t,n){return le(this,e,t,!1,n)};function ue(e,t,n,r,a){return t=+t,n>>>=0,a||ce(e,t,n,8,17976931348623157e292,-17976931348623157e292),i.write(e,t,n,r,52,8),n+8}l.prototype.writeDoubleLE=function(e,t,n){return ue(this,e,t,!0,n)},l.prototype.writeDoubleBE=function(e,t,n){return ue(this,e,t,!1,n)},l.prototype.copy=function(e,t,n,r){if(!l.isBuffer(e))throw TypeError(`argument should be a Buffer`);if(n||=0,!r&&r!==0&&(r=this.length),t>=e.length&&(t=e.length),t||=0,r>0&&r<n&&(r=n),r===n||e.length===0||this.length===0)return 0;if(t<0)throw RangeError(`targetStart out of bounds`);if(n<0||n>=this.length)throw RangeError(`Index out of range`);if(r<0)throw RangeError(`sourceEnd out of bounds`);r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);let i=r-n;return this===e&&typeof Uint8Array.prototype.copyWithin==`function`?this.copyWithin(t,n,r):Uint8Array.prototype.set.call(e,this.subarray(n,r),t),i},l.prototype.fill=function(e,t,n,r){if(typeof e==`string`){if(typeof t==`string`?(r=t,t=0,n=this.length):typeof n==`string`&&(r=n,n=this.length),r!==void 0&&typeof r!=`string`)throw TypeError(`encoding must be a string`);if(typeof r==`string`&&!l.isEncoding(r))throw TypeError(`Unknown encoding: `+r);if(e.length===1){let t=e.charCodeAt(0);(r===`utf8`&&t<128||r===`latin1`)&&(e=t)}}else typeof e==`number`?e&=255:typeof e==`boolean`&&(e=Number(e));if(t<0||this.length<t||this.length<n)throw RangeError(`Out of range index`);if(n<=t)return this;t>>>=0,n=n===void 0?this.length:n>>>0,e||=0;let i;if(typeof e==`number`)for(i=t;i<n;++i)this[i]=e;else{let a=l.isBuffer(e)?e:l.from(e,r),o=a.length;if(o===0)throw TypeError(`The value "`+e+`" is invalid for argument "value"`);for(i=0;i<n-t;++i)this[i+t]=a[i%o]}return this};let de={};function fe(e,t,n){de[e]=class extends n{constructor(){super(),Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(e){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:e,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}fe(`ERR_BUFFER_OUT_OF_BOUNDS`,function(e){return e?`${e} is outside of buffer bounds`:`Attempt to access memory outside buffer bounds`},RangeError),fe(`ERR_INVALID_ARG_TYPE`,function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`},TypeError),fe(`ERR_OUT_OF_RANGE`,function(e,t,n){let r=`The value of "${e}" is out of range.`,i=n;return Number.isInteger(n)&&Math.abs(n)>2**32?i=F(String(n)):typeof n==`bigint`&&(i=String(n),(n>BigInt(2)**BigInt(32)||n<-(BigInt(2)**BigInt(32)))&&(i=F(i)),i+=`n`),r+=` It must be ${t}. Received ${i}`,r},RangeError);function F(e){let t=``,n=e.length,r=+(e[0]===`-`);for(;n>=r+4;n-=3)t=`_${e.slice(n-3,n)}${t}`;return`${e.slice(0,n)}${t}`}function pe(e,t,n){I(t,`offset`),(e[t]===void 0||e[t+n]===void 0)&&he(t,e.length-(n+1))}function me(e,t,n,r,i,a){if(e>n||e<t){let r=typeof t==`bigint`?`n`:``,i;throw i=a>3?t===0||t===BigInt(0)?`>= 0${r} and < 2${r} ** ${(a+1)*8}${r}`:`>= -(2${r} ** ${(a+1)*8-1}${r}) and < 2 ** ${(a+1)*8-1}${r}`:`>= ${t}${r} and <= ${n}${r}`,new de.ERR_OUT_OF_RANGE(`value`,i,e)}pe(r,i,a)}function I(e,t){if(typeof e!=`number`)throw new de.ERR_INVALID_ARG_TYPE(t,`number`,e)}function he(e,t,n){throw Math.floor(e)===e?t<0?new de.ERR_BUFFER_OUT_OF_BOUNDS:new de.ERR_OUT_OF_RANGE(n||`offset`,`>= ${+!!n} and <= ${t}`,e):(I(e,n),new de.ERR_OUT_OF_RANGE(n||`offset`,`an integer`,e))}let ge=/[^+/0-9A-Za-z-_]/g;function _e(e){if(e=e.split(`=`)[0],e=e.trim().replace(ge,``),e.length<2)return``;for(;e.length%4!=0;)e+=`=`;return e}function ve(e,t){t||=1/0;let n,r=e.length,i=null,a=[];for(let o=0;o<r;++o){if(n=e.charCodeAt(o),n>55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&a.push(239,191,189);continue}else if(o+1===r){(t-=3)>-1&&a.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&a.push(239,191,189),i=n;continue}n=(i-55296<<10|n-56320)+65536}else i&&(t-=3)>-1&&a.push(239,191,189);if(i=null,n<128){if(--t<0)break;a.push(n)}else if(n<2048){if((t-=2)<0)break;a.push(n>>6|192,n&63|128)}else if(n<65536){if((t-=3)<0)break;a.push(n>>12|224,n>>6&63|128,n&63|128)}else if(n<1114112){if((t-=4)<0)break;a.push(n>>18|240,n>>12&63|128,n>>6&63|128,n&63|128)}else throw Error(`Invalid code point`)}return a}function ye(e){let t=[];for(let n=0;n<e.length;++n)t.push(e.charCodeAt(n)&255);return t}function be(e,t){let n,r,i,a=[];for(let o=0;o<e.length&&!((t-=2)<0);++o)n=e.charCodeAt(o),r=n>>8,i=n%256,a.push(i),a.push(r);return a}function xe(e){return r.toByteArray(_e(e))}function Se(e,t,n,r){let i;for(i=0;i<r&&!(i+n>=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function L(e,t){return e instanceof t||e!=null&&e.constructor!=null&&e.constructor.name!=null&&e.constructor.name===t.name}function R(e){return e!==e}let z=(function(){let e=`0123456789abcdef`,t=Array(256);for(let n=0;n<16;++n){let r=n*16;for(let i=0;i<16;++i)t[r+i]=e[n]+e[i]}return t})();function B(e){return typeof BigInt>`u`?Ce:e}function Ce(){throw Error(`BigInt not supported`)}})),i=r();globalThis.Buffer===void 0&&(globalThis.Buffer=i.Buffer);var a=class extends Error{status;statusText;url;body;constructor(e,t,n,r){let i=typeof r==`string`&&r?`: ${r.slice(0,200)}`:r&&typeof r==`object`?`: ${o(r).slice(0,200)}`:``;super(`HTTP ${e} ${t} ${n}${i}`),this.status=e,this.statusText=t,this.url=n,this.body=r,this.name=`HttpError`}};function o(e){try{return JSON.stringify(e)}catch{return String(e)}}function s(e){return new Promise(t=>setTimeout(t,e))}function c(e,t,n){let r;if(r=/^[a-z][a-z0-9+.-]*:\/\//i.test(t)?t:e?`${e.endsWith(`/`)?e.slice(0,-1):e}${t.startsWith(`/`)?t:`/${t}`}`:t,!n)return r;let i=[];for(let[e,t]of Object.entries(n))if(t!=null)if(Array.isArray(t))for(let n of t)n!=null&&i.push(`${encodeURIComponent(e)}=${encodeURIComponent(String(n))}`);else i.push(`${encodeURIComponent(e)}=${encodeURIComponent(String(t))}`);return i.length===0?r:r+(r.includes(`?`)?`&`:`?`)+i.join(`&`)}function l(e,t){let n={};if(e)for(let[t,r]of Object.entries(e))n[t]=r;if(t)for(let[e,r]of Object.entries(t))n[e]=r;return n}function u(e){if(!e)return!1;let t=e.toLowerCase();return t.startsWith(`application/json`)||/[+/]json(;|$|\s)/.test(t)}function d(e){if(!e)return null;let t=e.trim();if(!t)return null;if(/^\d+(\.\d+)?$/.test(t)){let e=Number(t);if(Number.isFinite(e)&&e>=0)return Math.round(e*1e3)}let n=Date.parse(t);if(Number.isFinite(n)){let e=n-Date.now();return e>0?e:0}return null}async function f(e){if(u(e.headers.get(`content-type`))){let t=await e.text();if(!t)return null;try{return JSON.parse(t)}catch{return t}}return e.text()}function p(e,t){if(e!=null)return typeof e==`string`||e instanceof ArrayBuffer||ArrayBuffer.isView(e)||typeof Blob<`u`&&e instanceof Blob||typeof FormData<`u`&&e instanceof FormData||typeof URLSearchParams<`u`&&e instanceof URLSearchParams||typeof ReadableStream<`u`&&e instanceof ReadableStream?e:typeof e==`object`?(Object.keys(t).some(e=>e.toLowerCase()===`content-type`)||(t[`Content-Type`]=`application/json`),JSON.stringify(e)):String(e)}function m(e){let t=e.sleep??s;function n(n){let r=new Set(n.retry?.on??[]),i=Math.max(1,Math.trunc(n.retry?.maxAttempts??1));async function o(o,s,u={}){let m=c(n.baseUrl,s,u.params),h=l(n.headers,u.headers);if(n.token){let e=await n.token({method:o,path:s,url:m});e&&(Object.keys(h).some(e=>e.toLowerCase()===`authorization`)||(h.Authorization=`Bearer ${e}`))}let g=p(u.body,h),_={method:o,headers:h};g!==void 0&&(_.body=g);let v=null;for(let o=0;o<i;o++){let s=n.timeoutMs?new AbortController:null,c=s?setTimeout(()=>s.abort(Error(`timeout`)),n.timeoutMs):null,l=u.signal&&s?.signal?AbortSignal.any([u.signal,s.signal]):u.signal??s?.signal,p=l?{..._,signal:l}:_,h;try{h=await e.fetch(m,p)}finally{c!==null&&clearTimeout(c)}if(v=h,h.ok){let e=await f(h);return u.raw?{body:e,headers:Object.fromEntries(h.headers.entries()),status:h.status}:e}if(!(o+1<i&&r.has(h.status))){let e=await f(h).catch(()=>null);throw new a(h.status,h.statusText,m,e)}let g=d(h.headers.get(`retry-after`)),y=500*2**o;await t(g===null?y:g)}if(v){let e=await f(v).catch(()=>null);throw new a(v.status,v.statusText,m,e)}throw Error(`http: no attempts made for ${o} ${m}`)}return Object.freeze({get:((e,t)=>o(`GET`,e,t)),post:((e,t)=>o(`POST`,e,t)),put:((e,t)=>o(`PUT`,e,t)),patch:((e,t)=>o(`PATCH`,e,t)),delete:((e,t)=>o(`DELETE`,e,t))})}return Object.freeze({client:n})}var h=e(((e,t)=>{t.exports={}})),g=e(((e,t)=>{
|
|
11
11
|
/**
|
|
12
12
|
* [js-md5]{@link https://github.com/emn178/js-md5}
|
|
13
13
|
*
|
|
@@ -38,8 +38,8 @@ let r=t(),i=n(),a=typeof Symbol==`function`&&typeof Symbol.for==`function`?Symbo
|
|
|
38
38
|
(function(){var e=`input is invalid type`,n=typeof window==`object`,i=n?window:{};i.JS_SHA256_NO_WINDOW&&(n=!1);var a=!n&&typeof self==`object`,o=!i.JS_SHA256_NO_NODE_JS&&typeof process==`object`&&process.versions&&process.versions.node&&process.type!=`renderer`;o?i=globalThis:a&&(i=self);var s=!i.JS_SHA256_NO_COMMON_JS&&typeof t==`object`&&t.exports,c=typeof define==`function`&&define.amd,l=!i.JS_SHA256_NO_ARRAY_BUFFER&&typeof ArrayBuffer<`u`,u=`0123456789abcdef`.split(``),d=[-2147483648,8388608,32768,128],f=[24,16,8,0],p=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],m=[`hex`,`array`,`digest`,`arrayBuffer`],g=[];(i.JS_SHA256_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(e){return Object.prototype.toString.call(e)===`[object Array]`}),l&&(i.JS_SHA256_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(e){return typeof e==`object`&&e.buffer&&e.buffer.constructor===ArrayBuffer});var _=function(e,t){return function(n){return new S(t,!0).update(n)[e]()}},v=function(e){var t=_(`hex`,e);o&&(t=y(t,e)),t.create=function(){return new S(e)},t.update=function(e){return t.create().update(e)};for(var n=0;n<m.length;++n){var r=m[n];t[r]=_(r,e)}return t},y=function(t,n){var a=h(),o=r().Buffer,s=n?`sha224`:`sha256`,c=o.from&&!i.JS_SHA256_NO_BUFFER_FROM?o.from:function(e){return new o(e)};return function(n){if(typeof n==`string`)return a.createHash(s).update(n,`utf8`).digest(`hex`);if(n==null)throw Error(e);return n.constructor===ArrayBuffer&&(n=new Uint8Array(n)),Array.isArray(n)||ArrayBuffer.isView(n)||n.constructor===o?a.createHash(s).update(c(n)).digest(`hex`):t(n)}},b=function(e,t){return function(n,r){return new C(n,t,!0).update(r)[e]()}},x=function(e){var t=b(`hex`,e);t.create=function(t){return new C(t,e)},t.update=function(e,n){return t.create(e).update(n)};for(var n=0;n<m.length;++n){var r=m[n];t[r]=b(r,e)}return t};function S(e,t){t?(g[0]=g[16]=g[1]=g[2]=g[3]=g[4]=g[5]=g[6]=g[7]=g[8]=g[9]=g[10]=g[11]=g[12]=g[13]=g[14]=g[15]=0,this.blocks=g):this.blocks=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],e?(this.h0=3238371032,this.h1=914150663,this.h2=812702999,this.h3=4144912697,this.h4=4290775857,this.h5=1750603025,this.h6=1694076839,this.h7=3204075428):(this.h0=1779033703,this.h1=3144134277,this.h2=1013904242,this.h3=2773480762,this.h4=1359893119,this.h5=2600822924,this.h6=528734635,this.h7=1541459225),this.block=this.start=this.bytes=this.hBytes=0,this.finalized=this.hashed=!1,this.first=!0,this.is224=e}S.prototype.update=function(t){if(!this.finalized){var n,r=typeof t;if(r!==`string`){if(r===`object`){if(t===null)throw Error(e);if(l&&t.constructor===ArrayBuffer)t=new Uint8Array(t);else if(!Array.isArray(t)&&(!l||!ArrayBuffer.isView(t)))throw Error(e)}else throw Error(e);n=!0}for(var i,a=0,o,s=t.length,c=this.blocks;a<s;){if(this.hashed&&(this.hashed=!1,c[0]=this.block,this.block=c[16]=c[1]=c[2]=c[3]=c[4]=c[5]=c[6]=c[7]=c[8]=c[9]=c[10]=c[11]=c[12]=c[13]=c[14]=c[15]=0),n)for(o=this.start;a<s&&o<64;++a)c[o>>>2]|=t[a]<<f[o++&3];else for(o=this.start;a<s&&o<64;++a)i=t.charCodeAt(a),i<128?c[o>>>2]|=i<<f[o++&3]:i<2048?(c[o>>>2]|=(192|i>>>6)<<f[o++&3],c[o>>>2]|=(128|i&63)<<f[o++&3]):i<55296||i>=57344?(c[o>>>2]|=(224|i>>>12)<<f[o++&3],c[o>>>2]|=(128|i>>>6&63)<<f[o++&3],c[o>>>2]|=(128|i&63)<<f[o++&3]):(i=65536+((i&1023)<<10|t.charCodeAt(++a)&1023),c[o>>>2]|=(240|i>>>18)<<f[o++&3],c[o>>>2]|=(128|i>>>12&63)<<f[o++&3],c[o>>>2]|=(128|i>>>6&63)<<f[o++&3],c[o>>>2]|=(128|i&63)<<f[o++&3]);this.lastByteIndex=o,this.bytes+=o-this.start,o>=64?(this.block=c[16],this.start=o-64,this.hash(),this.hashed=!0):this.start=o}return this.bytes>4294967295&&(this.hBytes+=this.bytes/4294967296<<0,this.bytes%=4294967296),this}},S.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var e=this.blocks,t=this.lastByteIndex;e[16]=this.block,e[t>>>2]|=d[t&3],this.block=e[16],t>=56&&(this.hashed||this.hash(),e[0]=this.block,e[16]=e[1]=e[2]=e[3]=e[4]=e[5]=e[6]=e[7]=e[8]=e[9]=e[10]=e[11]=e[12]=e[13]=e[14]=e[15]=0),e[14]=this.hBytes<<3|this.bytes>>>29,e[15]=this.bytes<<3,this.hash()}},S.prototype.hash=function(){var e=this.h0,t=this.h1,n=this.h2,r=this.h3,i=this.h4,a=this.h5,o=this.h6,s=this.h7,c=this.blocks,l,u,d,f,m,h,g,_,v,y,b;for(l=16;l<64;++l)m=c[l-15],u=(m>>>7|m<<25)^(m>>>18|m<<14)^m>>>3,m=c[l-2],d=(m>>>17|m<<15)^(m>>>19|m<<13)^m>>>10,c[l]=c[l-16]+u+c[l-7]+d<<0;for(b=t&n,l=0;l<64;l+=4)this.first?(this.is224?(_=300032,m=c[0]-1413257819,s=m-150054599<<0,r=m+24177077<<0):(_=704751109,m=c[0]-210244248,s=m-1521486534<<0,r=m+143694565<<0),this.first=!1):(u=(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10),d=(i>>>6|i<<26)^(i>>>11|i<<21)^(i>>>25|i<<7),_=e&t,f=_^e&n^b,g=i&a^~i&o,m=s+d+g+p[l]+c[l],h=u+f,s=r+m<<0,r=m+h<<0),u=(r>>>2|r<<30)^(r>>>13|r<<19)^(r>>>22|r<<10),d=(s>>>6|s<<26)^(s>>>11|s<<21)^(s>>>25|s<<7),v=r&e,f=v^r&t^_,g=s&i^~s&a,m=o+d+g+p[l+1]+c[l+1],h=u+f,o=n+m<<0,n=m+h<<0,u=(n>>>2|n<<30)^(n>>>13|n<<19)^(n>>>22|n<<10),d=(o>>>6|o<<26)^(o>>>11|o<<21)^(o>>>25|o<<7),y=n&r,f=y^n&e^v,g=o&s^~o&i,m=a+d+g+p[l+2]+c[l+2],h=u+f,a=t+m<<0,t=m+h<<0,u=(t>>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10),d=(a>>>6|a<<26)^(a>>>11|a<<21)^(a>>>25|a<<7),b=t&n,f=b^t&r^y,g=a&o^~a&s,m=i+d+g+p[l+3]+c[l+3],h=u+f,i=e+m<<0,e=m+h<<0,this.chromeBugWorkAround=!0;this.h0=this.h0+e<<0,this.h1=this.h1+t<<0,this.h2=this.h2+n<<0,this.h3=this.h3+r<<0,this.h4=this.h4+i<<0,this.h5=this.h5+a<<0,this.h6=this.h6+o<<0,this.h7=this.h7+s<<0},S.prototype.hex=function(){this.finalize();var e=this.h0,t=this.h1,n=this.h2,r=this.h3,i=this.h4,a=this.h5,o=this.h6,s=this.h7,c=u[e>>>28&15]+u[e>>>24&15]+u[e>>>20&15]+u[e>>>16&15]+u[e>>>12&15]+u[e>>>8&15]+u[e>>>4&15]+u[e&15]+u[t>>>28&15]+u[t>>>24&15]+u[t>>>20&15]+u[t>>>16&15]+u[t>>>12&15]+u[t>>>8&15]+u[t>>>4&15]+u[t&15]+u[n>>>28&15]+u[n>>>24&15]+u[n>>>20&15]+u[n>>>16&15]+u[n>>>12&15]+u[n>>>8&15]+u[n>>>4&15]+u[n&15]+u[r>>>28&15]+u[r>>>24&15]+u[r>>>20&15]+u[r>>>16&15]+u[r>>>12&15]+u[r>>>8&15]+u[r>>>4&15]+u[r&15]+u[i>>>28&15]+u[i>>>24&15]+u[i>>>20&15]+u[i>>>16&15]+u[i>>>12&15]+u[i>>>8&15]+u[i>>>4&15]+u[i&15]+u[a>>>28&15]+u[a>>>24&15]+u[a>>>20&15]+u[a>>>16&15]+u[a>>>12&15]+u[a>>>8&15]+u[a>>>4&15]+u[a&15]+u[o>>>28&15]+u[o>>>24&15]+u[o>>>20&15]+u[o>>>16&15]+u[o>>>12&15]+u[o>>>8&15]+u[o>>>4&15]+u[o&15];return this.is224||(c+=u[s>>>28&15]+u[s>>>24&15]+u[s>>>20&15]+u[s>>>16&15]+u[s>>>12&15]+u[s>>>8&15]+u[s>>>4&15]+u[s&15]),c},S.prototype.toString=S.prototype.hex,S.prototype.digest=function(){this.finalize();var e=this.h0,t=this.h1,n=this.h2,r=this.h3,i=this.h4,a=this.h5,o=this.h6,s=this.h7,c=[e>>>24&255,e>>>16&255,e>>>8&255,e&255,t>>>24&255,t>>>16&255,t>>>8&255,t&255,n>>>24&255,n>>>16&255,n>>>8&255,n&255,r>>>24&255,r>>>16&255,r>>>8&255,r&255,i>>>24&255,i>>>16&255,i>>>8&255,i&255,a>>>24&255,a>>>16&255,a>>>8&255,a&255,o>>>24&255,o>>>16&255,o>>>8&255,o&255];return this.is224||c.push(s>>>24&255,s>>>16&255,s>>>8&255,s&255),c},S.prototype.array=S.prototype.digest,S.prototype.arrayBuffer=function(){this.finalize();var e=new ArrayBuffer(this.is224?28:32),t=new DataView(e);return t.setUint32(0,this.h0),t.setUint32(4,this.h1),t.setUint32(8,this.h2),t.setUint32(12,this.h3),t.setUint32(16,this.h4),t.setUint32(20,this.h5),t.setUint32(24,this.h6),this.is224||t.setUint32(28,this.h7),e};function C(t,n,r){var i,a=typeof t;if(a===`string`){var o=[],s=t.length,c=0,u;for(i=0;i<s;++i)u=t.charCodeAt(i),u<128?o[c++]=u:u<2048?(o[c++]=192|u>>>6,o[c++]=128|u&63):u<55296||u>=57344?(o[c++]=224|u>>>12,o[c++]=128|u>>>6&63,o[c++]=128|u&63):(u=65536+((u&1023)<<10|t.charCodeAt(++i)&1023),o[c++]=240|u>>>18,o[c++]=128|u>>>12&63,o[c++]=128|u>>>6&63,o[c++]=128|u&63);t=o}else if(a===`object`){if(t===null)throw Error(e);if(l&&t.constructor===ArrayBuffer)t=new Uint8Array(t);else if(!Array.isArray(t)&&(!l||!ArrayBuffer.isView(t)))throw Error(e)}else throw Error(e);t.length>64&&(t=new S(n,!0).update(t).array());var d=[],f=[];for(i=0;i<64;++i){var p=t[i]||0;d[i]=92^p,f[i]=54^p}S.call(this,n,r),this.update(f),this.oKeyPad=d,this.inner=!0,this.sharedMemory=r}C.prototype=new S,C.prototype.finalize=function(){if(S.prototype.finalize.call(this),this.inner){this.inner=!1;var e=this.array();S.call(this,this.is224,this.sharedMemory),this.update(this.oKeyPad),this.update(e),S.prototype.finalize.call(this)}};var w=v();w.sha256=w,w.sha224=v(!0),w.sha256.hmac=x(),w.sha224.hmac=x(!0),s?t.exports=w:(i.sha256=w.sha256,i.sha224=w.sha224,c&&define(function(){return w}))})()})),y=g(),b=_(),x=v(),S=4,C=0,w=1,T=2;function E(e){let t=e.length;for(;--t>=0;)e[t]=0}var D=0,O=1,k=2,A=29,j=256,ee=286,M=30,te=19,ne=573,re=15,ie=16,ae=7,N=256,P=16,oe=17,se=18,ce=new Uint8Array([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0]),le=new Uint8Array([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13]),ue=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),de=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),fe=512,F=Array(288*2);E(F);var pe=Array(M*2);E(pe);var me=Array(fe);E(me);var I=Array(256);E(I);var he=Array(A);E(he);var ge=Array(M);E(ge);var _e=class{constructor(e,t,n,r,i){this.static_tree=e,this.extra_bits=t,this.extra_base=n,this.elems=r,this.max_length=i,this.has_stree=e&&e.length}},ve,ye,be,xe=class{constructor(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}},Se=e=>e<256?me[e]:me[256+(e>>>7)],L=(e,t)=>{e.pending_buf[e.pending++]=t&255,e.pending_buf[e.pending++]=t>>>8&255},R=(e,t,n)=>{e.bi_valid>ie-n?(e.bi_buf|=t<<e.bi_valid&65535,L(e,e.bi_buf),e.bi_buf=t>>ie-e.bi_valid,e.bi_valid+=n-ie):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=n)},z=(e,t,n)=>{R(e,n[t*2],n[t*2+1])},B=(e,t)=>{let n=0;do n|=e&1,e>>>=1,n<<=1;while(--t>0);return n>>>1},Ce=e=>{e.bi_valid===16?(L(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=e.bi_buf&255,e.bi_buf>>=8,e.bi_valid-=8)},we=(e,t)=>{let n=t.dyn_tree,r=t.max_code,i=t.stat_desc.static_tree,a=t.stat_desc.has_stree,o=t.stat_desc.extra_bits,s=t.stat_desc.extra_base,c=t.stat_desc.max_length,l,u,d,f,p,m,h=0;for(f=0;f<=re;f++)e.bl_count[f]=0;for(n[e.heap[e.heap_max]*2+1]=0,l=e.heap_max+1;l<ne;l++)u=e.heap[l],f=n[n[u*2+1]*2+1]+1,f>c&&(f=c,h++),n[u*2+1]=f,!(u>r)&&(e.bl_count[f]++,p=0,u>=s&&(p=o[u-s]),m=n[u*2],e.opt_len+=m*(f+p),a&&(e.static_len+=m*(i[u*2+1]+p)));if(h!==0){do{for(f=c-1;e.bl_count[f]===0;)f--;e.bl_count[f]--,e.bl_count[f+1]+=2,e.bl_count[c]--,h-=2}while(h>0);for(f=c;f!==0;f--)for(u=e.bl_count[f];u!==0;)d=e.heap[--l],!(d>r)&&(n[d*2+1]!==f&&(e.opt_len+=(f-n[d*2+1])*n[d*2],n[d*2+1]=f),u--)}},Te=(e,t,n)=>{let r=Array(16),i=0,a,o;for(a=1;a<=re;a++)i=i+n[a-1]<<1,r[a]=i;for(o=0;o<=t;o++){let t=e[o*2+1];t!==0&&(e[o*2]=B(r[t]++,t))}},Ee=()=>{let e,t,n,r,i,a=Array(16);for(n=0,r=0;r<A-1;r++)for(he[r]=n,e=0;e<1<<ce[r];e++)I[n++]=r;for(I[n-1]=r,i=0,r=0;r<16;r++)for(ge[r]=i,e=0;e<1<<le[r];e++)me[i++]=r;for(i>>=7;r<M;r++)for(ge[r]=i<<7,e=0;e<1<<le[r]-7;e++)me[256+i++]=r;for(t=0;t<=re;t++)a[t]=0;for(e=0;e<=143;)F[e*2+1]=8,e++,a[8]++;for(;e<=255;)F[e*2+1]=9,e++,a[9]++;for(;e<=279;)F[e*2+1]=7,e++,a[7]++;for(;e<=287;)F[e*2+1]=8,e++,a[8]++;for(Te(F,287,a),e=0;e<M;e++)pe[e*2+1]=5,pe[e*2]=B(e,5);ve=new _e(F,ce,257,ee,re),ye=new _e(pe,le,0,M,re),be=new _e([],ue,0,te,ae)},De=e=>{let t;for(t=0;t<ee;t++)e.dyn_ltree[t*2]=0;for(t=0;t<M;t++)e.dyn_dtree[t*2]=0;for(t=0;t<te;t++)e.bl_tree[t*2]=0;e.dyn_ltree[N*2]=1,e.opt_len=e.static_len=0,e.sym_next=e.matches=0},Oe=e=>{e.bi_valid>8?L(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},ke=(e,t,n,r)=>{let i=t*2,a=n*2;return e[i]<e[a]||e[i]===e[a]&&r[t]<=r[n]},Ae=(e,t,n)=>{let r=e.heap[n],i=n<<1;for(;i<=e.heap_len&&(i<e.heap_len&&ke(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!ke(t,r,e.heap[i],e.depth));)e.heap[n]=e.heap[i],n=i,i<<=1;e.heap[n]=r},je=(e,t,n)=>{let r,i,a=0,o,s;if(e.sym_next!==0)do r=e.pending_buf[e.sym_buf+a++]&255,r+=(e.pending_buf[e.sym_buf+a++]&255)<<8,i=e.pending_buf[e.sym_buf+a++],r===0?z(e,i,t):(o=I[i],z(e,o+j+1,t),s=ce[o],s!==0&&(i-=he[o],R(e,i,s)),r--,o=Se(r),z(e,o,n),s=le[o],s!==0&&(r-=ge[o],R(e,r,s)));while(a<e.sym_next);z(e,N,t)},Me=(e,t)=>{let n=t.dyn_tree,r=t.stat_desc.static_tree,i=t.stat_desc.has_stree,a=t.stat_desc.elems,o,s,c=-1,l;for(e.heap_len=0,e.heap_max=ne,o=0;o<a;o++)n[o*2]===0?n[o*2+1]=0:(e.heap[++e.heap_len]=c=o,e.depth[o]=0);for(;e.heap_len<2;)l=e.heap[++e.heap_len]=c<2?++c:0,n[l*2]=1,e.depth[l]=0,e.opt_len--,i&&(e.static_len-=r[l*2+1]);for(t.max_code=c,o=e.heap_len>>1;o>=1;o--)Ae(e,n,o);l=a;do o=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Ae(e,n,1),s=e.heap[1],e.heap[--e.heap_max]=o,e.heap[--e.heap_max]=s,n[l*2]=n[o*2]+n[s*2],e.depth[l]=(e.depth[o]>=e.depth[s]?e.depth[o]:e.depth[s])+1,n[o*2+1]=n[s*2+1]=l,e.heap[1]=l++,Ae(e,n,1);while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],we(e,t),Te(n,c,e.bl_count)},Ne=(e,t,n)=>{let r,i=-1,a,o=t[1],s=0,c=7,l=4;for(o===0&&(c=138,l=3),t[(n+1)*2+1]=65535,r=0;r<=n;r++)a=o,o=t[(r+1)*2+1],!(++s<c&&a===o)&&(s<l?e.bl_tree[a*2]+=s:a===0?s<=10?e.bl_tree[oe*2]++:e.bl_tree[se*2]++:(a!==i&&e.bl_tree[a*2]++,e.bl_tree[P*2]++),s=0,i=a,o===0?(c=138,l=3):a===o?(c=6,l=3):(c=7,l=4))},Pe=(e,t,n)=>{let r,i=-1,a,o=t[1],s=0,c=7,l=4;for(o===0&&(c=138,l=3),r=0;r<=n;r++)if(a=o,o=t[(r+1)*2+1],!(++s<c&&a===o)){if(s<l)do z(e,a,e.bl_tree);while(--s!==0);else a===0?s<=10?(z(e,oe,e.bl_tree),R(e,s-3,3)):(z(e,se,e.bl_tree),R(e,s-11,7)):(a!==i&&(z(e,a,e.bl_tree),s--),z(e,P,e.bl_tree),R(e,s-3,2));s=0,i=a,o===0?(c=138,l=3):a===o?(c=6,l=3):(c=7,l=4)}},Fe=e=>{let t;for(Ne(e,e.dyn_ltree,e.l_desc.max_code),Ne(e,e.dyn_dtree,e.d_desc.max_code),Me(e,e.bl_desc),t=te-1;t>=3&&e.bl_tree[de[t]*2+1]===0;t--);return e.opt_len+=3*(t+1)+5+5+4,t},Ie=(e,t,n,r)=>{let i;for(R(e,t-257,5),R(e,n-1,5),R(e,r-4,4),i=0;i<r;i++)R(e,e.bl_tree[de[i]*2+1],3);Pe(e,e.dyn_ltree,t-1),Pe(e,e.dyn_dtree,n-1)},Le=e=>{let t=4093624447,n;for(n=0;n<=31;n++,t>>>=1)if(t&1&&e.dyn_ltree[n*2]!==0)return C;if(e.dyn_ltree[18]!==0||e.dyn_ltree[20]!==0||e.dyn_ltree[26]!==0)return w;for(n=32;n<j;n++)if(e.dyn_ltree[n*2]!==0)return w;return C},Re=!1,ze=e=>{Re||=(Ee(),!0),e.l_desc=new xe(e.dyn_ltree,ve),e.d_desc=new xe(e.dyn_dtree,ye),e.bl_desc=new xe(e.bl_tree,be),e.bi_buf=0,e.bi_valid=0,De(e)},Be=(e,t,n,r)=>{R(e,(D<<1)+ +!!r,3),Oe(e),L(e,n),L(e,~n),n&&e.pending_buf.set(e.window.subarray(t,t+n),e.pending),e.pending+=n},Ve=e=>{R(e,O<<1,3),z(e,N,F),Ce(e)},He=(e,t,n,r)=>{let i,a,o=0;e.level>0?(e.strm.data_type===T&&(e.strm.data_type=Le(e)),Me(e,e.l_desc),Me(e,e.d_desc),o=Fe(e),i=e.opt_len+3+7>>>3,a=e.static_len+3+7>>>3,a<=i&&(i=a)):i=a=n+5,n+4<=i&&t!==-1?Be(e,t,n,r):e.strategy===S||a===i?(R(e,(O<<1)+ +!!r,3),je(e,F,pe)):(R(e,(k<<1)+ +!!r,3),Ie(e,e.l_desc.max_code+1,e.d_desc.max_code+1,o+1),je(e,e.dyn_ltree,e.dyn_dtree)),De(e),r&&Oe(e)},Ue=(e,t,n)=>(e.pending_buf[e.sym_buf+e.sym_next++]=t,e.pending_buf[e.sym_buf+e.sym_next++]=t>>8,e.pending_buf[e.sym_buf+e.sym_next++]=n,t===0?e.dyn_ltree[n*2]++:(e.matches++,t--,e.dyn_ltree[(I[n]+j+1)*2]++,e.dyn_dtree[Se(t)*2]++),e.sym_next===e.sym_end),We=(e,t,n,r)=>{let i=e&65535|0,a=e>>>16&65535|0,o=0;for(;n!==0;){o=n>2e3?2e3:n,n-=o;do i=i+t[r++]|0,a=a+i|0;while(--o);i%=65521,a%=65521}return i|a<<16|0},Ge=new Uint32Array((()=>{let e,t=[];for(var n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=e&1?3988292384^e>>>1:e>>>1;t[n]=e}return t})()),V=(e,t,n,r)=>{let i=Ge,a=r+n;e^=-1;for(let n=r;n<a;n++)e=e>>>8^i[(e^t[n])&255];return e^-1},Ke={2:`need dictionary`,1:`stream end`,0:``,"-1":`file error`,"-2":`stream error`,"-3":`data error`,"-4":`insufficient memory`,"-5":`buffer error`,"-6":`incompatible version`},qe=9,Je=573,H=3,Ye=258,U=262,Xe=32,Ze=42,Qe=57,$e=69,et=73,tt=91,nt=103,rt=113,it=666,W=1,at=2,ot=3,st=4,ct=3,lt=(e,t)=>(e.msg=Ke[t],t),ut=e=>e*2-(e>4?9:0),dt=e=>{let t=e.length;for(;--t>=0;)e[t]=0},ft=e=>{let t,n,r,i=e.w_size;t=e.hash_size,r=t;do n=e.head[--r],e.head[r]=n>=i?n-i:0;while(--t);t=i,r=t;do n=e.prev[--r],e.prev[r]=n>=i?n-i:0;while(--t)},pt=(e,t,n)=>(t<<e.hash_shift^n)&e.hash_mask,mt=(e,t)=>{let n;if(e.legacy_hash)n=e.ins_h=pt(e,e.ins_h,e.window[t+H-1]);else{let r=e.window,i=r[t]|r[t+1]<<8|r[t+2]<<16|r[t+3]<<24;n=e.ins_h=Math.imul(i,66521)+66521>>>16&e.hash_mask}let r=e.prev[t&e.w_mask]=e.head[n];return e.head[n]=t,r},G=e=>{let t=e.state,n=t.pending;n>e.avail_out&&(n=e.avail_out),n!==0&&(e.output.set(t.pending_buf.subarray(t.pending_out,t.pending_out+n),e.next_out),e.next_out+=n,t.pending_out+=n,e.total_out+=n,e.avail_out-=n,t.pending-=n,t.pending===0&&(t.pending_out=0))},K=(e,t)=>{He(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,G(e.strm)},q=(e,t)=>{e.pending_buf[e.pending++]=t},ht=(e,t)=>{e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=t&255},gt=(e,t,n,r)=>{let i=e.avail_in;return i>r&&(i=r),i===0?0:(e.avail_in-=i,t.set(e.input.subarray(e.next_in,e.next_in+i),n),e.state.wrap===1?e.adler=We(e.adler,t,i,n):e.state.wrap===2&&(e.adler=V(e.adler,t,i,n)),e.next_in+=i,e.total_in+=i,i)},_t=(e,t)=>{let n=e.max_chain_length,r=e.strstart,i,a,o=e.prev_length,s=e.nice_match,c=e.strstart>e.w_size-U?e.strstart-(e.w_size-U):0,l=e.window,u=e.w_mask,d=e.prev,f=e.strstart+Ye,p=l[r+o-1],m=l[r+o];e.prev_length>=e.good_match&&(n>>=2),s>e.lookahead&&(s=e.lookahead);do{if(i=t,l[i+o]!==m||l[i+o-1]!==p||l[i]!==l[r]||l[++i]!==l[r+1])continue;r+=2,i++;do;while(l[++r]===l[++i]&&l[++r]===l[++i]&&l[++r]===l[++i]&&l[++r]===l[++i]&&l[++r]===l[++i]&&l[++r]===l[++i]&&l[++r]===l[++i]&&l[++r]===l[++i]&&r<f);if(a=Ye-(f-r),r=f-Ye,a>o){if(e.match_start=t,o=a,a>=s)break;p=l[r+o-1],m=l[r+o]}}while((t=d[t&u])>c&&--n!==0);return o<=e.lookahead?o:e.lookahead},vt=e=>{let t=e.w_size,n,r,i;do{if(r=e.window_size-e.lookahead-e.strstart,e.strstart>=t+(t-U)&&(e.window.set(e.window.subarray(t,t+t-r),0),e.match_start-=t,e.strstart-=t,e.block_start-=t,e.insert>e.strstart&&(e.insert=e.strstart),ft(e),r+=t),e.strm.avail_in===0)break;if(n=gt(e.strm,e.window,e.strstart+e.lookahead,r),e.lookahead+=n,!e.legacy_hash){if(e.lookahead+e.insert>H)for(i=e.strstart-e.insert;e.insert&&(mt(e,i),i++,e.insert--,!(e.lookahead+e.insert<=H)););}else if(e.lookahead+e.insert>=H)for(i=e.strstart-e.insert,e.ins_h=e.window[i],e.ins_h=pt(e,e.ins_h,e.window[i+1]);e.insert&&(mt(e,i),i++,e.insert--,!(e.lookahead+e.insert<H)););}while(e.lookahead<U&&e.strm.avail_in!==0)},yt=(e,t)=>{let n=e.pending_buf_size-5>e.w_size?e.w_size:e.pending_buf_size-5,r,i,a,o=0,s=e.strm.avail_in;do{if(r=65535,a=e.bi_valid+42>>3,e.strm.avail_out<a||(a=e.strm.avail_out-a,i=e.strstart-e.block_start,r>i+e.strm.avail_in&&(r=i+e.strm.avail_in),r>a&&(r=a),r<n&&(r===0&&t!==4||t===0||r!==i+e.strm.avail_in)))break;o=+(t===4&&r===i+e.strm.avail_in),Be(e,0,0,o),e.pending_buf[e.pending-4]=r,e.pending_buf[e.pending-3]=r>>8,e.pending_buf[e.pending-2]=~r,e.pending_buf[e.pending-1]=~r>>8,G(e.strm),i&&(i>r&&(i=r),e.strm.output.set(e.window.subarray(e.block_start,e.block_start+i),e.strm.next_out),e.strm.next_out+=i,e.strm.avail_out-=i,e.strm.total_out+=i,e.block_start+=i,r-=i),r&&(gt(e.strm,e.strm.output,e.strm.next_out,r),e.strm.next_out+=r,e.strm.avail_out-=r,e.strm.total_out+=r)}while(o===0);return s-=e.strm.avail_in,s&&(s>=e.w_size?(e.matches=2,e.window.set(e.strm.input.subarray(e.strm.next_in-e.w_size,e.strm.next_in),0),e.strstart=e.w_size,e.insert=e.strstart):(e.window_size-e.strstart<=s&&(e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,e.insert>e.strstart&&(e.insert=e.strstart)),e.window.set(e.strm.input.subarray(e.strm.next_in-s,e.strm.next_in),e.strstart),e.strstart+=s,e.insert+=s>e.w_size-e.insert?e.w_size-e.insert:s),e.block_start=e.strstart),e.high_water<e.strstart&&(e.high_water=e.strstart),o?st:t!==0&&t!==4&&e.strm.avail_in===0&&e.strstart===e.block_start?at:(a=e.window_size-e.strstart,e.strm.avail_in>a&&e.block_start>=e.w_size&&(e.block_start-=e.w_size,e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,a+=e.w_size,e.insert>e.strstart&&(e.insert=e.strstart)),a>e.strm.avail_in&&(a=e.strm.avail_in),a&&(gt(e.strm,e.window,e.strstart,a),e.strstart+=a,e.insert+=a>e.w_size-e.insert?e.w_size-e.insert:a),e.high_water<e.strstart&&(e.high_water=e.strstart),a=e.bi_valid+42>>3,a=e.pending_buf_size-a>65535?65535:e.pending_buf_size-a,n=a>e.w_size?e.w_size:a,i=e.strstart-e.block_start,(i>=n||(i||t===4)&&t!==0&&e.strm.avail_in===0&&i<=a)&&(r=i>a?a:i,o=+(t===4&&e.strm.avail_in===0&&r===i),Be(e,e.block_start,r,o),e.block_start+=r,G(e.strm)),o?ot:W)},bt=(e,t)=>{let n,r;for(;;){if(e.lookahead<U){if(vt(e),e.lookahead<U&&t===0)return W;if(e.lookahead===0)break}if(n=0,e.lookahead>=H&&(n=mt(e,e.strstart)),n!==0&&e.strstart-n<=e.w_size-U&&(e.match_length=_t(e,n)),e.match_length>=H)if(r=Ue(e,e.strstart-e.match_start,e.match_length-H),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=H){e.match_length--;do e.strstart++,n=mt(e,e.strstart);while(--e.match_length!==0);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.legacy_hash&&(e.ins_h=e.window[e.strstart],e.ins_h=pt(e,e.ins_h,e.window[e.strstart+1]));else r=Ue(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(K(e,!1),e.strm.avail_out===0))return W}return e.insert=e.strstart<H-1?e.strstart:H-1,t===4?(K(e,!0),e.strm.avail_out===0?ot:st):e.sym_next&&(K(e,!1),e.strm.avail_out===0)?W:at},xt=(e,t)=>{let n,r,i;for(;;){if(e.lookahead<U){if(vt(e),e.lookahead<U&&t===0)return W;if(e.lookahead===0)break}if(n=0,e.lookahead>=H&&(n=mt(e,e.strstart)),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=H-1,n!==0&&e.prev_length<e.max_lazy_match&&e.strstart-n<=e.w_size-U&&(e.match_length=_t(e,n),e.match_length<=5&&(e.strategy===1||e.match_length===H&&e.strstart-e.match_start>4096)&&(e.match_length=H-1)),e.prev_length>=H&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-H,r=Ue(e,e.strstart-1-e.prev_match,e.prev_length-H),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=i&&(n=mt(e,e.strstart));while(--e.prev_length!==0);if(e.match_available=0,e.match_length=H-1,e.strstart++,r&&(K(e,!1),e.strm.avail_out===0))return W}else if(e.match_available){if(r=Ue(e,0,e.window[e.strstart-1]),r&&K(e,!1),e.strstart++,e.lookahead--,e.strm.avail_out===0)return W}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&=(r=Ue(e,0,e.window[e.strstart-1]),0),e.insert=e.strstart<H-1?e.strstart:H-1,t===4?(K(e,!0),e.strm.avail_out===0?ot:st):e.sym_next&&(K(e,!1),e.strm.avail_out===0)?W:at},St=(e,t)=>{let n,r,i,a,o=e.window;for(;;){if(e.lookahead<=Ye){if(vt(e),e.lookahead<=Ye&&t===0)return W;if(e.lookahead===0)break}if(e.match_length=0,e.lookahead>=H&&e.strstart>0&&(i=e.strstart-1,r=o[i],r===o[++i]&&r===o[++i]&&r===o[++i])){a=e.strstart+Ye;do;while(r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&r===o[++i]&&i<a);e.match_length=Ye-(a-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=H?(n=Ue(e,1,e.match_length-H),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=Ue(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(K(e,!1),e.strm.avail_out===0))return W}return e.insert=0,t===4?(K(e,!0),e.strm.avail_out===0?ot:st):e.sym_next&&(K(e,!1),e.strm.avail_out===0)?W:at},Ct=(e,t)=>{let n;for(;;){if(e.lookahead===0&&(vt(e),e.lookahead===0)){if(t===0)return W;break}if(e.match_length=0,n=Ue(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(K(e,!1),e.strm.avail_out===0))return W}return e.insert=0,t===4?(K(e,!0),e.strm.avail_out===0?ot:st):e.sym_next&&(K(e,!1),e.strm.avail_out===0)?W:at},J=class{constructor(e,t,n,r,i){this.good_length=e,this.max_lazy=t,this.nice_length=n,this.max_chain=r,this.func=i}},wt=[new J(0,0,0,0,yt),new J(4,4,8,4,bt),new J(4,5,16,8,bt),new J(4,6,32,32,bt),new J(4,4,16,16,xt),new J(8,16,32,32,xt),new J(8,16,128,128,xt),new J(8,32,128,256,xt),new J(32,128,258,1024,xt),new J(32,258,258,4096,xt)],Tt=e=>{e.window_size=2*e.w_size,dt(e.head),e.max_lazy_match=wt[e.level].max_lazy,e.good_match=wt[e.level].good_length,e.nice_match=wt[e.level].nice_length,e.max_chain_length=wt[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=H-1,e.match_available=0,e.ins_h=0},Et=class{constructor(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=8,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.legacy_hash=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(Je*2),this.dyn_dtree=new Uint16Array(122),this.bl_tree=new Uint16Array(78),dt(this.dyn_ltree),dt(this.dyn_dtree),dt(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(16),this.heap=new Uint16Array(573),dt(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),dt(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}},Dt=e=>{if(!e)return 1;let t=e.state;return+(!t||t.strm!==e||t.status!==Ze&&t.status!==Qe&&t.status!==$e&&t.status!==et&&t.status!==tt&&t.status!==nt&&t.status!==rt&&t.status!==it)},Ot=e=>{if(Dt(e))return lt(e,-2);e.total_in=e.total_out=0,e.data_type=2;let t=e.state;return t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap===2?Qe:t.wrap?Ze:rt,e.adler=t.wrap===2?0:1,t.last_flush=-2,ze(t),0},kt=e=>{let t=Ot(e);return t===0&&Tt(e.state),t},At=(e,t,n,r,i,a,o)=>{if(!e)return-2;let s=1;if(t===-1&&(t=6),r<0?(s=0,r=-r):r>15&&(s=2,r-=16),i<1||i>qe||n!==8||r<8||r>15||t<0||t>9||a<0||a>4||r===8&&s!==1)return lt(e,-2);r===8&&(r=9);let c=new Et;return e.state=c,c.strm=e,c.status=Ze,c.wrap=s,c.gzhead=null,c.w_bits=r,c.w_size=1<<c.w_bits,c.w_mask=c.w_size-1,c.legacy_hash=+!!o,c.hash_bits=i+7,!c.legacy_hash&&c.hash_bits<15&&(c.hash_bits=15),c.hash_size=1<<c.hash_bits,c.hash_mask=c.hash_size-1,c.hash_shift=~~((c.hash_bits+H-1)/H),c.window=new Uint8Array(c.w_size*2),c.head=new Uint16Array(c.hash_size),c.prev=new Uint16Array(c.w_size),c.lit_bufsize=1<<i+6,c.pending_buf_size=c.lit_bufsize*4,c.pending_buf=new Uint8Array(c.pending_buf_size),c.sym_buf=c.lit_bufsize,c.sym_end=(c.lit_bufsize-1)*3,c.level=t,c.strategy=a,c.method=n,kt(e)},jt=(e,t)=>{if(Dt(e)||t>5||t<0)return e?lt(e,-2):-2;let n=e.state;if(!e.output||e.avail_in!==0&&!e.input||n.status===it&&t!==4)return lt(e,e.avail_out===0?-5:-2);let r=n.last_flush;if(n.last_flush=t,n.pending!==0){if(G(e),e.avail_out===0)return n.last_flush=-1,0}else if(e.avail_in===0&&ut(t)<=ut(r)&&t!==4)return lt(e,-5);if(n.status===it&&e.avail_in!==0)return lt(e,-5);if(n.status===Ze&&n.wrap===0&&(n.status=rt),n.status===Ze){let t=8+(n.w_bits-8<<4)<<8,r=-1;if(r=n.strategy>=2||n.level<2?0:n.level<6?1:n.level===6?2:3,t|=r<<6,n.strstart!==0&&(t|=Xe),t+=31-t%31,ht(n,t),n.strstart!==0&&(ht(n,e.adler>>>16),ht(n,e.adler&65535)),e.adler=1,n.status=rt,G(e),n.pending!==0)return n.last_flush=-1,0}if(n.status===Qe){if(e.adler=0,q(n,31),q(n,139),q(n,8),n.gzhead)q(n,+!!n.gzhead.text+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),q(n,n.gzhead.time&255),q(n,n.gzhead.time>>8&255),q(n,n.gzhead.time>>16&255),q(n,n.gzhead.time>>24&255),q(n,n.level===9?2:n.strategy>=2||n.level<2?4:0),q(n,n.gzhead.os&255),n.gzhead.extra&&n.gzhead.extra.length&&(q(n,n.gzhead.extra.length&255),q(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(e.adler=V(e.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=$e;else if(q(n,0),q(n,0),q(n,0),q(n,0),q(n,0),q(n,n.level===9?2:n.strategy>=2||n.level<2?4:0),q(n,ct),n.status=rt,G(e),n.pending!==0)return n.last_flush=-1,0}if(n.status===$e){if(n.gzhead.extra){let t=n.pending,r=(n.gzhead.extra.length&65535)-n.gzindex;for(;n.pending+r>n.pending_buf_size;){let i=n.pending_buf_size-n.pending;if(n.pending_buf.set(n.gzhead.extra.subarray(n.gzindex,n.gzindex+i),n.pending),n.pending=n.pending_buf_size,n.gzhead.hcrc&&n.pending>t&&(e.adler=V(e.adler,n.pending_buf,n.pending-t,t)),n.gzindex+=i,G(e),n.pending!==0)return n.last_flush=-1,0;t=0,r-=i}let i=new Uint8Array(n.gzhead.extra);n.pending_buf.set(i.subarray(n.gzindex,n.gzindex+r),n.pending),n.pending+=r,n.gzhead.hcrc&&n.pending>t&&(e.adler=V(e.adler,n.pending_buf,n.pending-t,t)),n.gzindex=0}n.status=et}if(n.status===et){if(n.gzhead.name){let t=n.pending,r;do{if(n.pending===n.pending_buf_size){if(n.gzhead.hcrc&&n.pending>t&&(e.adler=V(e.adler,n.pending_buf,n.pending-t,t)),G(e),n.pending!==0)return n.last_flush=-1,0;t=0}r=n.gzindex<n.gzhead.name.length?n.gzhead.name.charCodeAt(n.gzindex++)&255:0,q(n,r)}while(r!==0);n.gzhead.hcrc&&n.pending>t&&(e.adler=V(e.adler,n.pending_buf,n.pending-t,t)),n.gzindex=0}n.status=tt}if(n.status===tt){if(n.gzhead.comment){let t=n.pending,r;do{if(n.pending===n.pending_buf_size){if(n.gzhead.hcrc&&n.pending>t&&(e.adler=V(e.adler,n.pending_buf,n.pending-t,t)),G(e),n.pending!==0)return n.last_flush=-1,0;t=0}r=n.gzindex<n.gzhead.comment.length?n.gzhead.comment.charCodeAt(n.gzindex++)&255:0,q(n,r)}while(r!==0);n.gzhead.hcrc&&n.pending>t&&(e.adler=V(e.adler,n.pending_buf,n.pending-t,t))}n.status=nt}if(n.status===nt){if(n.gzhead.hcrc){if(n.pending+2>n.pending_buf_size&&(G(e),n.pending!==0))return n.last_flush=-1,0;q(n,e.adler&255),q(n,e.adler>>8&255),e.adler=0}if(n.status=rt,G(e),n.pending!==0)return n.last_flush=-1,0}if(e.avail_in!==0||n.lookahead!==0||t!==0&&n.status!==it){let r=n.level===0?yt(n,t):n.strategy===2?Ct(n,t):n.strategy===3?St(n,t):wt[n.level].func(n,t);if((r===ot||r===st)&&(n.status=it),r===W||r===ot)return e.avail_out===0&&(n.last_flush=-1),0;if(r===at&&(t===1?Ve(n):t!==5&&(Be(n,0,0,!1),t===3&&(dt(n.head),n.lookahead===0&&(n.strstart=0,n.block_start=0,n.insert=0))),G(e),e.avail_out===0))return n.last_flush=-1,0}return t===4?n.wrap<=0?1:(n.wrap===2?(q(n,e.adler&255),q(n,e.adler>>8&255),q(n,e.adler>>16&255),q(n,e.adler>>24&255),q(n,e.total_in&255),q(n,e.total_in>>8&255),q(n,e.total_in>>16&255),q(n,e.total_in>>24&255)):(ht(n,e.adler>>>16),ht(n,e.adler&65535)),G(e),n.wrap>0&&(n.wrap=-n.wrap),+(n.pending===0)):0},Mt=e=>{if(Dt(e))return-2;let t=e.state.status;return e.state=null,t===rt?lt(e,-3):0},Nt=(e,t)=>{let n=t.length;if(Dt(e))return-2;let r=e.state,i=r.wrap;if(i===2||i===1&&r.status!==Ze||r.lookahead)return-2;if(i===1&&(e.adler=We(e.adler,t,n,0)),r.wrap=0,n>=r.w_size){i===0&&(dt(r.head),r.strstart=0,r.block_start=0,r.insert=0);let e=new Uint8Array(r.w_size);e.set(t.subarray(n-r.w_size,n),0),t=e,n=r.w_size}let a=e.avail_in,o=e.next_in,s=e.input;for(e.avail_in=n,e.next_in=0,e.input=t,vt(r);r.lookahead>=H;){let e=r.strstart,t=r.lookahead-(H-1);do mt(r,e),e++;while(--t);r.strstart=e,r.lookahead=H-1,vt(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=H-1,r.match_available=0,e.next_in=o,e.input=s,e.avail_in=a,r.wrap=i,0},Pt=16209,Ft=16191;function It(e,t){let n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,C,w,T,E=e.state;n=e.next_in,w=e.input,r=n+(e.avail_in-5),i=e.next_out,T=e.output,a=i-(t-e.avail_out),o=i+(e.avail_out-257),s=E.dmax,c=E.wsize,l=E.whave,u=E.wnext,d=E.window,f=E.hold,p=E.bits,m=E.lencode,h=E.distcode,g=(1<<E.lenbits)-1,_=(1<<E.distbits)-1;top:do{p<15&&(f+=w[n++]<<p,p+=8,f+=w[n++]<<p,p+=8),v=m[f&g];dolen:for(;;){if(y=v>>>24,f>>>=y,p-=y,y=v>>>16&255,y===0)T[i++]=v&65535;else if(y&16){b=v&65535,y&=15,y&&(p<y&&(f+=w[n++]<<p,p+=8),b+=f&(1<<y)-1,f>>>=y,p-=y),p<15&&(f+=w[n++]<<p,p+=8,f+=w[n++]<<p,p+=8),v=h[f&_];dodist:for(;;){if(y=v>>>24,f>>>=y,p-=y,y=v>>>16&255,y&16){if(x=v&65535,y&=15,p<y&&(f+=w[n++]<<p,p+=8,p<y&&(f+=w[n++]<<p,p+=8)),x+=f&(1<<y)-1,x>s){e.msg=`invalid distance too far back`,E.mode=Pt;break top}if(f>>>=y,p-=y,y=i-a,x>y){if(y=x-y,y>l&&E.sane){e.msg=`invalid distance too far back`,E.mode=Pt;break top}if(S=0,C=d,u===0){if(S+=c-y,y<b){b-=y;do T[i++]=d[S++];while(--y);S=i-x,C=T}}else if(u<y){if(S+=c+u-y,y-=u,y<b){b-=y;do T[i++]=d[S++];while(--y);if(S=0,u<b){y=u,b-=y;do T[i++]=d[S++];while(--y);S=i-x,C=T}}}else if(S+=u-y,y<b){b-=y;do T[i++]=d[S++];while(--y);S=i-x,C=T}for(;b>2;)T[i++]=C[S++],T[i++]=C[S++],T[i++]=C[S++],b-=3;b&&(T[i++]=C[S++],b>1&&(T[i++]=C[S++]))}else{S=i-x;do T[i++]=T[S++],T[i++]=T[S++],T[i++]=T[S++],b-=3;while(b>2);b&&(T[i++]=T[S++],b>1&&(T[i++]=T[S++]))}}else if(y&64){e.msg=`invalid distance code`,E.mode=Pt;break top}else{v=h[(v&65535)+(f&(1<<y)-1)];continue dodist}break}}else if(!(y&64)){v=m[(v&65535)+(f&(1<<y)-1)];continue dolen}else if(y&32){E.mode=Ft;break top}else{e.msg=`invalid literal/length code`,E.mode=Pt;break top}break}}while(n<r&&i<o);b=p>>3,n-=b,p-=b<<3,f&=(1<<p)-1,e.next_in=n,e.next_out=i,e.avail_in=n<r?5+(r-n):5-(n-r),e.avail_out=i<o?257+(o-i):257-(i-o),E.hold=f,E.bits=p}var Lt=15,Rt=852,zt=592,Bt=0,Vt=1,Ht=2,Ut=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),Wt=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,199,75]),Gt=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),Kt=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]),qt=(e,t,n,r,i,a,o,s)=>{let c=s.bits,l=0,u=0,d=0,f=0,p=0,m=0,h=0,g=0,_=0,v=0,y,b,x,S,C,w=null,T,E=new Uint16Array(16),D=new Uint16Array(16),O=null,k,A,j;for(l=0;l<=Lt;l++)E[l]=0;for(u=0;u<r;u++)E[t[n+u]]++;for(p=c,f=Lt;f>=1&&E[f]===0;f--);if(p>f&&(p=f),f===0)return i[a++]=20971520,i[a++]=20971520,s.bits=1,0;for(d=1;d<f&&E[d]===0;d++);for(p<d&&(p=d),g=1,l=1;l<=Lt;l++)if(g<<=1,g-=E[l],g<0)return-1;if(g>0&&(e===Bt||f!==1))return-1;for(D[1]=0,l=1;l<Lt;l++)D[l+1]=D[l]+E[l];for(u=0;u<r;u++)t[n+u]!==0&&(o[D[t[n+u]]++]=u);if(e===Bt?(w=O=o,T=20):e===Vt?(w=Ut,O=Wt,T=257):(w=Gt,O=Kt,T=0),v=0,u=0,l=d,C=a,m=p,h=0,x=-1,_=1<<p,S=_-1,e===Vt&&_>Rt||e===Ht&&_>zt)return 1;for(;;){k=l-h,o[u]+1<T?(A=0,j=o[u]):o[u]>=T?(A=O[o[u]-T],j=w[o[u]-T]):(A=96,j=0),y=1<<l-h,b=1<<m,d=b;do b-=y,i[C+(v>>h)+b]=k<<24|A<<16|j|0;while(b!==0);for(y=1<<l-1;v&y;)y>>=1;if(y===0?v=0:(v&=y-1,v+=y),u++,--E[l]===0){if(l===f)break;l=t[n+o[u]]}if(l>p&&(v&S)!==x){for(h===0&&(h=p),C+=d,m=l-h,g=1<<m;m+h<f&&(g-=E[m+h],!(g<=0));)m++,g<<=1;if(_+=1<<m,e===Vt&&_>Rt||e===Ht&&_>zt)return 1;x=v&S,i[x]=p<<24|m<<16|C-a|0}}return v!==0&&(i[C+v]=l-h<<24|4194304),s.bits=p,0},Jt=0,Yt=1,Xt=2,Zt=16180,Qt=16181,$t=16182,en=16183,tn=16184,nn=16185,rn=16186,an=16187,on=16188,sn=16189,cn=16190,ln=16191,un=16192,dn=16193,fn=16194,pn=16195,mn=16196,hn=16197,gn=16198,_n=16199,vn=16200,yn=16201,bn=16202,xn=16203,Sn=16204,Cn=16205,wn=16206,Tn=16207,En=16208,Y=16209,Dn=16210,On=16211,kn=852,An=592,jn=e=>(e>>>24&255)+(e>>>8&65280)+((e&65280)<<8)+((e&255)<<24),Mn=class{constructor(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}},Nn=e=>{if(!e)return 1;let t=e.state;return+(!t||t.strm!==e||t.mode<Zt||t.mode>On)},Pn=e=>{if(Nn(e))return-2;let t=e.state;return e.total_in=e.total_out=t.total=0,e.msg=``,t.wrap&&(e.adler=t.wrap&1),t.mode=Zt,t.last=0,t.havedict=0,t.flags=-1,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(kn),t.distcode=t.distdyn=new Int32Array(An),t.sane=1,t.back=-1,0},Fn=e=>{if(Nn(e))return-2;let t=e.state;return t.wsize=0,t.whave=0,t.wnext=0,Pn(e)},In=(e,t)=>{let n;if(Nn(e))return-2;let r=e.state;return t<0?(n=0,t=-t):(n=(t>>4)+5,t<48&&(t&=15)),t&&(t<8||t>15)?-2:(r.window!==null&&r.wbits!==t&&(r.window=null),r.wrap=n,r.wbits=t,Fn(e))},Ln=(e,t)=>{if(!e)return-2;let n=new Mn;e.state=n,n.strm=e,n.window=null,n.mode=Zt;let r=In(e,t);return r!==0&&(e.state=null),r},Rn=!0,zn,Bn,Vn=e=>{if(Rn){zn=new Int32Array(512),Bn=new Int32Array(32);let t=0;for(;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(qt(Yt,e.lens,0,288,zn,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;qt(Xt,e.lens,0,32,Bn,0,e.work,{bits:5}),Rn=!1}e.lencode=zn,e.lenbits=9,e.distcode=Bn,e.distbits=5},Hn=(e,t,n,r)=>{let i,a=e.state;return a.window===null&&(a.window=new Uint8Array(1<<a.wbits)),a.wsize===0&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0),r>=a.wsize?(a.window.set(t.subarray(n-a.wsize,n),0),a.wnext=0,a.whave=a.wsize):(i=a.wsize-a.wnext,i>r&&(i=r),a.window.set(t.subarray(n-r,n-r+i),a.wnext),r-=i,r?(a.window.set(t.subarray(n-r,n),0),a.wnext=r,a.whave=a.wsize):(a.wnext+=i,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=i))),0},Un=(e,t)=>{let n,r,i,a,o,s,c,l,u,d,f,p,m,h,g=0,_,v,y,b,x,S,C,w,T=new Uint8Array(4),E,D,O=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Nn(e)||!e.output||!e.input&&e.avail_in!==0)return-2;n=e.state,n.mode===ln&&(n.mode=un),o=e.next_out,i=e.output,c=e.avail_out,a=e.next_in,r=e.input,s=e.avail_in,l=n.hold,u=n.bits,d=s,f=c,w=0;inf_leave:for(;;)switch(n.mode){case Zt:if(n.wrap===0){n.mode=un;break}for(;u<16;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(n.wrap&2&&l===35615){n.wbits===0&&(n.wbits=15),n.check=0,T[0]=l&255,T[1]=l>>>8&255,n.check=V(n.check,T,2,0),l=0,u=0,n.mode=Qt;break}if(n.head&&(n.head.done=!1),!(n.wrap&1)||(((l&255)<<8)+(l>>8))%31){e.msg=`incorrect header check`,n.mode=Y;break}if((l&15)!=8){e.msg=`unknown compression method`,n.mode=Y;break}if(l>>>=4,u-=4,C=(l&15)+8,n.wbits===0&&(n.wbits=C),C>15||C>n.wbits){e.msg=`invalid window size`,n.mode=Y;break}n.dmax=1<<n.wbits,n.flags=0,e.adler=n.check=1,n.mode=l&512?sn:ln,l=0,u=0;break;case Qt:for(;u<16;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(n.flags=l,(n.flags&255)!=8){e.msg=`unknown compression method`,n.mode=Y;break}if(n.flags&57344){e.msg=`unknown header flags set`,n.mode=Y;break}n.head&&(n.head.text=l>>8&1),n.flags&512&&n.wrap&4&&(T[0]=l&255,T[1]=l>>>8&255,n.check=V(n.check,T,2,0)),l=0,u=0,n.mode=$t;case $t:for(;u<32;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}n.head&&(n.head.time=l),n.flags&512&&n.wrap&4&&(T[0]=l&255,T[1]=l>>>8&255,T[2]=l>>>16&255,T[3]=l>>>24&255,n.check=V(n.check,T,4,0)),l=0,u=0,n.mode=en;case en:for(;u<16;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}n.head&&(n.head.xflags=l&255,n.head.os=l>>8),n.flags&512&&n.wrap&4&&(T[0]=l&255,T[1]=l>>>8&255,n.check=V(n.check,T,2,0)),l=0,u=0,n.mode=tn;case tn:if(n.flags&1024){for(;u<16;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}n.length=l,n.head&&(n.head.extra_len=l),n.flags&512&&n.wrap&4&&(T[0]=l&255,T[1]=l>>>8&255,n.check=V(n.check,T,2,0)),l=0,u=0}else n.head&&(n.head.extra=null);n.mode=nn;case nn:if(n.flags&1024&&(p=n.length,p>s&&(p=s),p&&(n.head&&(C=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Uint8Array(n.head.extra_len)),n.head.extra.set(r.subarray(a,a+p),C)),n.flags&512&&n.wrap&4&&(n.check=V(n.check,r,p,a)),s-=p,a+=p,n.length-=p),n.length))break inf_leave;n.length=0,n.mode=rn;case rn:if(n.flags&2048){if(s===0)break inf_leave;p=0;do C=r[a+p++],n.head&&C&&n.length<65536&&(n.head.name+=String.fromCharCode(C));while(C&&p<s);if(n.flags&512&&n.wrap&4&&(n.check=V(n.check,r,p,a)),s-=p,a+=p,C)break inf_leave}else n.head&&(n.head.name=null);n.length=0,n.mode=an;case an:if(n.flags&4096){if(s===0)break inf_leave;p=0;do C=r[a+p++],n.head&&C&&n.length<65536&&(n.head.comment+=String.fromCharCode(C));while(C&&p<s);if(n.flags&512&&n.wrap&4&&(n.check=V(n.check,r,p,a)),s-=p,a+=p,C)break inf_leave}else n.head&&(n.head.comment=null);n.mode=on;case on:if(n.flags&512){for(;u<16;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(n.wrap&4&&l!==(n.check&65535)){e.msg=`header crc mismatch`,n.mode=Y;break}l=0,u=0}n.head&&(n.head.hcrc=n.flags>>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=ln;break;case sn:for(;u<32;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}e.adler=n.check=jn(l),l=0,u=0,n.mode=cn;case cn:if(n.havedict===0)return e.next_out=o,e.avail_out=c,e.next_in=a,e.avail_in=s,n.hold=l,n.bits=u,2;e.adler=n.check=1,n.mode=ln;case ln:if(t===5||t===6)break inf_leave;case un:if(n.last){l>>>=u&7,u-=u&7,n.mode=wn;break}for(;u<3;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}switch(n.last=l&1,l>>>=1,--u,l&3){case 0:n.mode=dn;break;case 1:if(Vn(n),n.mode=_n,t===6){l>>>=2,u-=2;break inf_leave}break;case 2:n.mode=mn;break;case 3:e.msg=`invalid block type`,n.mode=Y}l>>>=2,u-=2;break;case dn:for(l>>>=u&7,u-=u&7;u<32;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if((l&65535)!=(l>>>16^65535)){e.msg=`invalid stored block lengths`,n.mode=Y;break}if(n.length=l&65535,l=0,u=0,n.mode=fn,t===6)break inf_leave;case fn:n.mode=pn;case pn:if(p=n.length,p){if(p>s&&(p=s),p>c&&(p=c),p===0)break inf_leave;i.set(r.subarray(a,a+p),o),s-=p,a+=p,c-=p,o+=p,n.length-=p;break}n.mode=ln;break;case mn:for(;u<14;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(n.nlen=(l&31)+257,l>>>=5,u-=5,n.ndist=(l&31)+1,l>>>=5,u-=5,n.ncode=(l&15)+4,l>>>=4,u-=4,n.nlen>286||n.ndist>30){e.msg=`too many length or distance symbols`,n.mode=Y;break}n.have=0,n.mode=hn;case hn:for(;n.have<n.ncode;){for(;u<3;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}n.lens[O[n.have++]]=l&7,l>>>=3,u-=3}for(;n.have<19;)n.lens[O[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,E={bits:n.lenbits},w=qt(Jt,n.lens,0,19,n.lencode,0,n.work,E),n.lenbits=E.bits,w){e.msg=`invalid code lengths set`,n.mode=Y;break}n.have=0,n.mode=gn;case gn:for(;n.have<n.nlen+n.ndist;){for(;g=n.lencode[l&(1<<n.lenbits)-1],_=g>>>24,v=g>>>16&255,y=g&65535,!(_<=u);){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(y<16)l>>>=_,u-=_,n.lens[n.have++]=y;else{if(y===16){for(D=_+2;u<D;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(l>>>=_,u-=_,n.have===0){e.msg=`invalid bit length repeat`,n.mode=Y;break}C=n.lens[n.have-1],p=3+(l&3),l>>>=2,u-=2}else if(y===17){for(D=_+3;u<D;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}l>>>=_,u-=_,C=0,p=3+(l&7),l>>>=3,u-=3}else{for(D=_+7;u<D;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}l>>>=_,u-=_,C=0,p=11+(l&127),l>>>=7,u-=7}if(n.have+p>n.nlen+n.ndist){e.msg=`invalid bit length repeat`,n.mode=Y;break}for(;p--;)n.lens[n.have++]=C}}if(n.mode===Y)break;if(n.lens[256]===0){e.msg=`invalid code -- missing end-of-block`,n.mode=Y;break}if(n.lenbits=9,E={bits:n.lenbits},w=qt(Yt,n.lens,0,n.nlen,n.lencode,0,n.work,E),n.lenbits=E.bits,w){e.msg=`invalid literal/lengths set`,n.mode=Y;break}if(n.distbits=6,n.distcode=n.distdyn,E={bits:n.distbits},w=qt(Xt,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,E),n.distbits=E.bits,w){e.msg=`invalid distances set`,n.mode=Y;break}if(n.mode=_n,t===6)break inf_leave;case _n:n.mode=vn;case vn:if(s>=6&&c>=258){e.next_out=o,e.avail_out=c,e.next_in=a,e.avail_in=s,n.hold=l,n.bits=u,It(e,f),o=e.next_out,i=e.output,c=e.avail_out,a=e.next_in,r=e.input,s=e.avail_in,l=n.hold,u=n.bits,n.mode===ln&&(n.back=-1);break}for(n.back=0;g=n.lencode[l&(1<<n.lenbits)-1],_=g>>>24,v=g>>>16&255,y=g&65535,!(_<=u);){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(v&&!(v&240)){for(b=_,x=v,S=y;g=n.lencode[S+((l&(1<<b+x)-1)>>b)],_=g>>>24,v=g>>>16&255,y=g&65535,!(b+_<=u);){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}l>>>=b,u-=b,n.back+=b}if(l>>>=_,u-=_,n.back+=_,n.length=y,v===0){n.mode=Cn;break}if(v&32){n.back=-1,n.mode=ln;break}if(v&64){e.msg=`invalid literal/length code`,n.mode=Y;break}n.extra=v&15,n.mode=yn;case yn:if(n.extra){for(D=n.extra;u<D;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}n.length+=l&(1<<n.extra)-1,l>>>=n.extra,u-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=bn;case bn:for(;g=n.distcode[l&(1<<n.distbits)-1],_=g>>>24,v=g>>>16&255,y=g&65535,!(_<=u);){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(!(v&240)){for(b=_,x=v,S=y;g=n.distcode[S+((l&(1<<b+x)-1)>>b)],_=g>>>24,v=g>>>16&255,y=g&65535,!(b+_<=u);){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}l>>>=b,u-=b,n.back+=b}if(l>>>=_,u-=_,n.back+=_,v&64){e.msg=`invalid distance code`,n.mode=Y;break}n.offset=y,n.extra=v&15,n.mode=xn;case xn:if(n.extra){for(D=n.extra;u<D;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}n.offset+=l&(1<<n.extra)-1,l>>>=n.extra,u-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg=`invalid distance too far back`,n.mode=Y;break}n.mode=Sn;case Sn:if(c===0)break inf_leave;if(p=f-c,n.offset>p){if(p=n.offset-p,p>n.whave&&n.sane){e.msg=`invalid distance too far back`,n.mode=Y;break}p>n.wnext?(p-=n.wnext,m=n.wsize-p):m=n.wnext-p,p>n.length&&(p=n.length),h=n.window}else h=i,m=o-n.offset,p=n.length;p>c&&(p=c),c-=p,n.length-=p;do i[o++]=h[m++];while(--p);n.length===0&&(n.mode=vn);break;case Cn:if(c===0)break inf_leave;i[o++]=n.length,c--,n.mode=vn;break;case wn:if(n.wrap){for(;u<32;){if(s===0)break inf_leave;s--,l|=r[a++]<<u,u+=8}if(f-=c,e.total_out+=f,n.total+=f,n.wrap&4&&f&&(e.adler=n.check=n.flags?V(n.check,i,f,o-f):We(n.check,i,f,o-f)),f=c,n.wrap&4&&(n.flags?l:jn(l))!==n.check){e.msg=`incorrect data check`,n.mode=Y;break}l=0,u=0}n.mode=Tn;case Tn:if(n.wrap&&n.flags){for(;u<32;){if(s===0)break inf_leave;s--,l+=r[a++]<<u,u+=8}if(n.wrap&4&&l!==(n.total&4294967295)){e.msg=`incorrect length check`,n.mode=Y;break}l=0,u=0}n.mode=En;case En:w=1;break inf_leave;case Y:w=-3;break inf_leave;case Dn:return-4;case On:default:return-2}return e.next_out=o,e.avail_out=c,e.next_in=a,e.avail_in=s,n.hold=l,n.bits=u,(n.wsize||f!==e.avail_out&&n.mode<Y&&(n.mode<wn||t!==4))&&Hn(e,e.output,e.next_out,f-e.avail_out)?(n.mode=Dn,-4):(d-=e.avail_in,f-=e.avail_out,e.total_in+=d,e.total_out+=f,n.total+=f,n.wrap&4&&f&&(e.adler=n.check=n.flags?V(n.check,i,f,e.next_out-f):We(n.check,i,f,e.next_out-f)),e.data_type=n.bits+(n.last?64:0)+(n.mode===ln?128:0)+(n.mode===_n||n.mode===fn?256:0),(d===0&&f===0||t===4)&&w===0&&(w=-5),w)},Wn=e=>{if(Nn(e))return-2;let t=e.state;return t.window&&=null,e.state=null,0},Gn=(e,t)=>{let n=t.length,r,i,a;return Nn(e)||(r=e.state,r.wrap!==0&&r.mode!==cn)?-2:r.mode===cn&&(i=1,i=We(i,t,n,0),i!==r.check)?-3:(a=Hn(e,t,n,n),a?(r.mode=Dn,-4):(r.havedict=1,0))},Kn=class{constructor(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg=``,this.state=null,this.data_type=2,this.adler=0}},qn=e=>{let t=new Uint8Array(e.reduce((e,t)=>e+t.length,0)),n=0;for(let r of e)t.set(r,n),n+=r.length;return t},Jn=Object.prototype.toString,Yn={level:-1,chunkSize:16384,windowBits:15,memLevel:8,strategy:0,raw:!1,gzip:!1,legacyHash:!1,dictionary:new Uint8Array},Xn=class{options;err;msg;ended;started;chunks;strm;result;constructor(e={}){this.options=Object.assign({},Yn,e);let t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg=``,this.ended=!1,this.started=!1,this.chunks=[],this.result=new Uint8Array,this.strm=new Kn,this.strm.avail_out=0;let n=At(this.strm,t.level,8,t.windowBits,t.memLevel,t.strategy,t.legacyHash);if(n!==0)throw Error(Ke[n]);Jn.call(t.dictionary)===`[object ArrayBuffer]`&&(t.dictionary=new Uint8Array(t.dictionary));let r=t.dictionary;if(r.length){if(t.gzip)throw Error(`dictionary is not supported with gzip`);if(n=Nt(this.strm,r),n!==0)throw Error(Ke[n])}}push(e,t=!1){let n=this.strm,r=this.options.chunkSize,i,a;if(this.ended)return!1;for(a=typeof t==`number`?t:t===!0?4:0,typeof e==`string`?n.input=new TextEncoder().encode(e):Jn.call(e)===`[object ArrayBuffer]`?n.input=new Uint8Array(e):n.input=e,n.next_in=0,n.avail_in=n.input.length,this.started||(this.started=!0,this.onStart(n));;){if(n.avail_out===0&&(n.output=new Uint8Array(r),n.next_out=0,n.avail_out=r),(a===2||a===3)&&n.avail_out<=6){this.onData(n.output.subarray(0,n.next_out)),n.avail_out=0;continue}if(i=jt(n,a),i===1){n.next_out>0&&this.onData(n.output.subarray(0,n.next_out)),i=Mt(this.strm);break}if(n.avail_out===0){this.onData(n.output);continue}if(a>0&&n.next_out>0){this.onData(n.output.subarray(0,n.next_out)),n.avail_out=0;continue}if(n.avail_in===0)return!0}return this.err=i,this.msg=n.msg||Ke[i],this.ended=!0,this.onEnd(i),i===0}onStart(e){}onData(e){this.chunks.push(e)}onEnd(e){e===0&&(this.result=qn(this.chunks)),this.chunks=[]}};function Zn(e,t={}){let n=new Xn(t);if(n.push(e,!0),n.err)throw Error(n.msg);return n.result}function Qn(e,t={}){return Zn(e,Object.assign({},t,{raw:!0}))}function $n(e,t={}){return Zn(e,Object.assign({},t,{gzip:!0}))}var er=Object.prototype.toString,tr={chunkSize:1024*64,windowBits:15,raw:!1,dictionary:new Uint8Array},nr=class{options;err;msg;ended;started;chunks;strm;result;constructor(e={}){this.options=Object.assign({},tr,e);let t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,t.windowBits===0&&(t.windowBits=-15)),t.windowBits>=0&&t.windowBits<16&&!e.windowBits&&(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(t.windowBits&15||(t.windowBits|=15)),this.err=0,this.msg=``,this.ended=!1,this.started=!1,this.chunks=[],this.result=new Uint8Array,this.strm=new Kn,this.strm.avail_out=0;let n=Ln(this.strm,t.windowBits);if(n!==0)throw Error(Ke[n]);er.call(t.dictionary)===`[object ArrayBuffer]`&&(t.dictionary=new Uint8Array(t.dictionary));let r=t.dictionary;if(t.raw&&r.length&&(n=Gn(this.strm,r),n!==0))throw Error(Ke[n])}push(e,t=!1){let n=this.strm,r=this.options.chunkSize,i,a,o;if(this.ended)return this.err===0;for(a=typeof t==`number`?t:t===!0?4:0,er.call(e)===`[object ArrayBuffer]`?n.input=new Uint8Array(e):n.input=e,n.next_in=0,n.avail_in=n.input.length,this.started||(this.started=!0,this.onStart(n));;){if(n.avail_out===0&&(n.output=new Uint8Array(r),n.next_out=0,n.avail_out=r),i=Un(n,a),i===2){let e=this.options.dictionary;e.length&&(i=Gn(n,e),i===0?i=Un(n,a):i===-3&&(i=2))}for(;n.avail_in>0&&i===1&&n.state.wrap&2&&n.state.flags!==0&&n.input[n.next_in]!==0;)Fn(n),i=Un(n,a);if(i===-2||i===-3||i===2||i===-4)break;if(o=n.avail_out,n.next_out&&(n.avail_out===0||i===1||a>0)&&(this.onData(n.output.length===n.next_out?n.output:n.output.subarray(0,n.next_out)),n.avail_out=0,n.next_out=0),!((i===0||i===-5)&&o===0)){if(i===1){i=Wn(this.strm);break}if(n.avail_in===0){if(a===4){i=Wn(this.strm),i===0&&(i=-5);break}return!0}}}return this.err=i,this.msg=n.msg||Ke[i],this.ended=!0,this.onEnd(i),i===0}onStart(e){}onData(e){this.chunks.push(e)}onEnd(e){e===0&&(this.result=qn(this.chunks)),this.chunks=[]}};function rr(e,t={}){let n=new nr(t);if(n.push(e,!0),n.err)throw Error(n.msg);let r=n.result;return t.toText?new TextDecoder().decode(r):r}function ir(e,t={}){return rr(e,{...t,raw:!0})}function ar(e){let t=[],n={},r=[],i=(e,t)=>{if(e in n){let r=n[e];Array.isArray(r)?r.push(String(t)):n[e]=[String(r),String(t)]}else n[e]=t},a=2;for(;a<e.length;){let n=e[a];if(n===`--`){r.push(...e.slice(a+1));break}if(n.startsWith(`--`)){let t=n.slice(2),r=t.indexOf(`=`);if(r!==-1){i(t.slice(0,r),t.slice(r+1)),a++;continue}let o=e[a+1];if(o!==void 0&&!o.startsWith(`-`)){i(t,o),a+=2;continue}i(t,!0),a++;continue}if(n.startsWith(`-`)&&n.length>1){for(let e of n.slice(1))i(e,!0);a++;continue}t.push(n),a++}return{positional:t,flags:n,subcommand:t.length>0&&/^[a-z][\w-]*$/i.test(t[0])?t[0]:null,passthrough:r}}function or(e){let t=[...e];return Object.defineProperty(t,"parseFlags",{value:()=>ar(t),enumerable:!1,writable:!1,configurable:!1}),t}function sr(e){let t=e=>{if(typeof e==`string`)return e;if(e instanceof Error)return e.message;if(e==null)return String(e);try{return JSON.stringify(e)}catch{return String(e)}},n=(e,t,n)=>t===void 0?`${e(`Error:`)} ${n}\n`:t===``?`${e(n)}\n`:`${e(`${t}:`)} ${n}\n`,r=(t,n)=>t===void 0?`${e.color.yellow(`Warning:`)} ${n}\n`:t===``?`${e.color.yellow(n)}\n`:`${e.color.yellow(`${t}:`)} ${n}\n`;return{die(r,i){let a=typeof i==`number`?i:i?.exitCode??1,o=typeof i==`object`&&i&&`prefix`in i?i.prefix:void 0,s=t(r);throw e.writeStderr(n(e.color.red,o,s)),e.exit(a),Error(`unreachable`)},out(t){if(typeof t==`string`){e.writeStdout(t.endsWith(`
|
|
39
39
|
`)?t:`${t}\n`);return}try{e.writeStdout(`${JSON.stringify(t,null,2)}\n`)}catch{e.writeStdout(`${String(t)}\n`)}},warn(n,i){let a=typeof i==`object`&&i&&`prefix`in i?i.prefix:void 0;e.writeStderr(r(a,t(n)))},help(t){throw e.writeStdout(t.endsWith(`
|
|
40
40
|
`)?t:`${t}\n`),e.exit(0),Error(`unreachable`)}}}const cr={reset:`\x1B[0m`,green:`\x1B[32m`,red:`\x1B[31m`,yellow:`\x1B[33m`,gray:`\x1B[90m`,bold:`\x1B[1m`,cyan:`\x1B[36m`,dim:`\x1B[2m`};function lr(e){let t=e.isTTY&&!e.noColor,n=e=>n=>t?`${e}${n}${cr.reset}`:String(n);return{enabled:t,green:n(cr.green),red:n(cr.red),yellow:n(cr.yellow),gray:n(cr.gray),bold:n(cr.bold),cyan:n(cr.cyan),dim:n(cr.dim)}}const ur={ms:1,s:1e3,m:6e4,h:36e5,d:864e5,w:6048e5,M:26298e5,y:315576e5};function dr(e){if(typeof e==`number`&&Number.isFinite(e))return Math.trunc(e);if(typeof e!=`string`)throw TypeError(`time.parseDuration: spec must be string or number`);let t=e.trim(),n=/^([0-9]+(?:\.[0-9]+)?)\s*(ms|s|m|h|d|w|M|y)?$/.exec(t);if(!n)throw RangeError(`time.parseDuration: unrecognized spec "${e}"`);let r=Number(n[1]),i=n[2]??`ms`;return Math.trunc(r*ur[i])}function fr(e){return e<10?`0${e}`:String(e)}const pr={parseDuration:dr,ago(e,t=new Date){return new Date(t.getTime()-dr(e))},range(e,t=new Date){let n=new Date(t.getTime());return{start:new Date(n.getTime()-dr(e)),end:n}},future(e,t=new Date){let n=new Date(t.getTime());return{start:n,end:new Date(n.getTime()+dr(e))}},gmailDate(e,t=new Date){let n=new Date(t.getTime()-dr(e));return`${n.getFullYear()}/${fr(n.getMonth()+1)}/${fr(n.getDate())}`}},mr=/\u001b\[[0-9;]*m/g;function hr(e){return e.replace(mr,``)}function gr(e){return hr(e).length}function _r(e,t){let n=String(e??``);return t<=0?``:gr(n)<=t?n:t<=1?n.slice(0,t):`${hr(n).slice(0,t-1)}…`}function vr(e,t){let n=String(e??``),r=gr(n);return r===t?n:r>t?_r(n,t):n+` `.repeat(t-r)}function yr(e,t){if(!e.length)return``;let n=Math.max(...e.map(e=>e.length)),r=[];for(let i=0;i<n;i++)if(t&&t[i]!==void 0)r[i]=t[i];else{let t=0;for(let n of e){let e=i<n.length?String(n[i]??``):``;t=Math.max(t,gr(e))}r[i]=t}return e.map(e=>r.map((t,n)=>vr(n<e.length?String(e[n]??``):``,t)).join(` `).replace(/\s+$/,``)).join(`
|
|
41
|
-
`)}function br(e){return e instanceof Date?e:new Date(e)}function xr(e,t=`short`){let n=br(e);if(Number.isNaN(n.getTime()))return String(e);if(t===`iso`)return n.toISOString();if(t===`locale`)return new Intl.DateTimeFormat(void 0,{dateStyle:`medium`}).format(n);if(t===`human`){let e=Date.now()-n.getTime(),t=Math.abs(e);if(t<6e4)return e>=0?`just now`:`in a moment`;let r=(t,n)=>e>=0?`${t} ${n}${t===1?``:`s`} ago`:`in ${t} ${n}${t===1?``:`s`}`;return t<36e5?r(Math.round(t/6e4),`minute`):t<864e5?r(Math.round(t/36e5),`hour`):t<26298e5?r(Math.round(t/864e5),`day`):t<315576e5?r(Math.round(t/26298e5),`month`):r(Math.round(t/315576e5),`year`)}return`${n.getFullYear()}-${fr(n.getMonth()+1)}-${fr(n.getDate())}`}const Sr={trunc:_r,col:vr,table:yr,date:xr},Cr=async(e,t,n)=>{let r=Math.max(1,Math.trunc(e)||1),i=Array(t.length),a=0,o=[],s=async()=>{for(;;){let e=a++;if(e>=t.length)return;i[e]=await n(t[e],e)}};for(let e=0;e<Math.min(r,t.length);e++)o.push(s());return await Promise.all(o),i};function wr(e,t){let n=[];for(let r of e)r===``||r===`.`||(r===`..`?n.length>0&&n[n.length-1]!==`..`?n.pop():t&&n.push(`..`):n.push(r));return n}function Tr(e){if(e.length===0)return`.`;let t=e.charCodeAt(0)===47,n=e.charCodeAt(e.length-1)===47,r=wr(e.split(`/`),!t).join(`/`);return r.length===0&&!t&&(r=`.`),r.length>0&&n&&(r+=`/`),(t?`/`:``)+r}function Er(...e){let t=e.filter(e=>typeof e==`string`&&e.length>0).join(`/`);return t.length===0?`.`:Tr(t)}function Dr(e){if(e.length===0)return`.`;let t=e.charCodeAt(0)===47,n=-1,r=!0;for(let t=e.length-1;t>=1;t--)if(e.charCodeAt(t)===47){if(!r){n=t;break}}else r=!1;return n===-1?t?`/`:`.`:t&&n===1?`//`:e.slice(0,n)}function Or(e,t){let n=0,r=-1,i=!0;for(let t=e.length-1;t>=0;t--)if(e.charCodeAt(t)===47){if(!i){n=t+1;break}}else r===-1&&(i=!1,r=t+1);let a=r===-1?``:e.slice(n,r);return t&&a.endsWith(t)&&a!==t?a.slice(0,a.length-t.length):a}function kr(e){let t=Or(e),n=t.lastIndexOf(`.`);return n<=0?``:t.slice(n)}function Ar(...e){let t=``,n=!1;for(let r=e.length-1;r>=0&&!n;r--){let i=e[r];typeof i!=`string`||i.length===0||(t=t.length>0?`${i}/${t}`:i,n=i.charCodeAt(0)===47)}n||(t=t.length>0?`/${t}`:`/`);let r=wr(t.split(`/`),!1).join(`/`);return r.length>0?`/${r}`:`/`}function jr(e,t){let n=Ar(e),r=Ar(t);if(n===r)return``;let i=n.split(`/`).filter(Boolean),a=r.split(`/`).filter(Boolean),o=0;for(;o<i.length&&o<a.length&&i[o]===a[o];)o++;return[...i.slice(o).map(()=>`..`),...a.slice(o)].join(`/`)}function Mr(e){let t=e.charCodeAt(0)===47?`/`:``,n=Or(e),r=kr(e),i=r?n.slice(0,n.length-r.length):n,a=Dr(e);return a===`.`&&t===``&&(a=``),{root:t,dir:a,base:n,ext:r,name:i}}function Nr(e){let t=e.dir||e.root||``,n=e.base||`${e.name||``}${e.ext||``}`;return t?t===e.root?`${t}${n}`:`${t}/${n}`:n}const Pr={sep:`/`,delimiter:`:`,basename:Or,dirname:Dr,extname:kr,isAbsolute:e=>e.length>0&&e.charCodeAt(0)===47,join:Er,normalize:Tr,resolve:Ar,relative:jr,parse:Mr,format:Nr},Fr=65536,Ir={md5:y.md5,sha1:b.sha1,sha256:x.sha256};function Lr(e,t){let n=globalThis.Buffer;if(!n)throw Error(`crypto.createHash: Buffer is unavailable in this environment`);return t?n.from(e,t):n.from(e)}function Rr(e,t){return typeof e==`string`?t===`hex`||t===`base64`||t===`base64url`||t===`latin1`||t===`binary`?new Uint8Array(Lr(e,t===`binary`?`latin1`:t)):e:ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):e}function zr(e){let t=Ir[String(e).toLowerCase().replace(`-`,``)];if(!t)throw Error(`Digest method not supported: ${e}`);let n=t.create(),r=!1,i={update(e,t){if(r)throw Error(`Digest already called`);return n.update(Rr(e,t)),i},digest(e){r=!0;let t=Lr(n.array());return e?t.toString(e):t}};return i}function Br(){let e=globalThis.crypto;if(!e||typeof e.getRandomValues!=`function`)throw Error(`crypto: globalThis.crypto is unavailable in this environment`);return e}function Vr(e){return Br().getRandomValues(e)}function Hr(e){for(let t=0;t<e.length;t+=Fr){let n=Math.min(t+Fr,e.length);Vr(e.subarray(t,n))}}function Ur(e){return e instanceof Uint8Array?e:new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}const X=Array.from({length:256},(e,t)=>(t+256).toString(16).slice(1));function Wr(){let e=Br();if(typeof e.randomUUID==`function`)return e.randomUUID();let t=Vr(new Uint8Array(16));return t[6]=t[6]&15|64,t[8]=t[8]&63|128,`${X[t[0]]}${X[t[1]]}${X[t[2]]}${X[t[3]]}-${X[t[4]]}${X[t[5]]}-${X[t[6]]}${X[t[7]]}-${X[t[8]]}${X[t[9]]}-${X[t[10]]}${X[t[11]]}${X[t[12]]}${X[t[13]]}${X[t[14]]}${X[t[15]]}`}const Gr={randomFillSync(e,t=0,n){let r=Ur(e),i=t,a=n===void 0?r.length:i+n;return Hr(r.subarray(i,a)),e},randomBytes(e){let t=globalThis.Buffer,n=t&&typeof t.allocUnsafe==`function`?t.allocUnsafe(e):new Uint8Array(e);return Hr(Ur(n)),n},randomUUID:Wr,getRandomValues(e){return Vr(e)},createHash:zr,get webcrypto(){return Br()},get subtle(){return Br().subtle}};var Z=class extends Error{actual;expected;operator;generatedMessage;code;constructor(e={}){let t=!e.message;super(e.message||`${Kr(e.actual)} ${e.operator||`!=`} ${Kr(e.expected)}`),this.name=`AssertionError`,this.actual=e.actual,this.expected=e.expected,this.operator=e.operator||``,this.generatedMessage=t,this.code=`ERR_ASSERTION`}};function Kr(e){if(typeof e==`string`)return JSON.stringify(e);if(e==null)return String(e);if(typeof e==`object`)try{return JSON.stringify(e)}catch{return String(e)}return String(e)}function Q(e,t){return e instanceof Error?e:typeof e==`string`?new Z({message:e}):t()}function qr(e,t,n,r){if(e.length!==t.length)return!1;for(let i=0;i<e.length;i++)if(!Yr(e[i],t[i],n,r))return!1;return!0}function Jr(e,t,n,r){let i=Object.keys(e);if(i.length!==Object.keys(t).length)return!1;for(let a of i){if(!Object.prototype.hasOwnProperty.call(t,a))return!1;let i=e[a],o=t[a];if(!Yr(i,o,n,r))return!1}return!0}function Yr(e,t,n,r){if((n?Object.is(e,t):e===t)||!n&&e==t)return!0;if(typeof e!=`object`||typeof t!=`object`||e===null||t===null)return!1;let i=e,a=t;return n&&Object.getPrototypeOf(i)!==Object.getPrototypeOf(a)?!1:r.get(i)===a?!0:(r.set(i,a),Array.isArray(e)===Array.isArray(t)?Array.isArray(e)&&Array.isArray(t)?qr(e,t,n,r):Jr(i,a,n,r):!1)}function Xr(e,t){try{if(e instanceof t)return!0}catch{}try{return!!t(e)}catch{return!1}}function Zr(e,t){for(let[n,r]of Object.entries(t)){let t=e[n];if(r instanceof RegExp){if(typeof t!=`string`||!r.test(t))return!1}else if(t!==r)return!1}return!0}function Qr(e,t){if(t===void 0)return!0;if(t instanceof RegExp){let n=e instanceof Error?e.message:String(e);return t.test(n)}return typeof t==`function`?Xr(e,t):t&&typeof t==`object`?!e||typeof e!=`object`?!1:Zr(e,t):!1}function $r(e){let t=(e,t)=>{if(!e)throw Q(t,()=>new Z({message:`The expression evaluated to a falsy value`,actual:e,expected:!0,operator:`==`}))},n=((e,n)=>t(e,n)),r=(e,t,n)=>{if(!Object.is(e,t))throw Q(n,()=>new Z({actual:e,expected:t,operator:`strictEqual`}))},i=(t,n,i)=>{if(e){r(t,n,i);return}if(t!=n)throw Q(i,()=>new Z({actual:t,expected:n,operator:`==`}))},a=(e,t,n)=>{if(Object.is(e,t))throw Q(n,()=>new Z({actual:e,expected:t,operator:`notStrictEqual`}))},o=(t,n,r)=>{if(e){a(t,n,r);return}if(t==n)throw Q(r,()=>new Z({actual:t,expected:n,operator:`!=`}))},s=(e,t,n)=>{if(!Yr(e,t,!0,new WeakMap))throw Q(n,()=>new Z({actual:e,expected:t,operator:`deepStrictEqual`}))},c=(t,n,r)=>{if(e){s(t,n,r);return}if(!Yr(t,n,!1,new WeakMap))throw Q(r,()=>new Z({actual:t,expected:n,operator:`deepEqual`}))},l=(e,t,n)=>{if(Yr(e,t,!0,new WeakMap))throw Q(n,()=>new Z({actual:e,expected:t,operator:`notDeepStrictEqual`}))};return n.ok=t,n.equal=i,n.notEqual=o,n.strictEqual=r,n.notStrictEqual=a,n.deepEqual=c,n.deepStrictEqual=s,n.notDeepEqual=(t,n,r)=>{if(e){l(t,n,r);return}if(Yr(t,n,!1,new WeakMap))throw Q(r,()=>new Z({actual:t,expected:n,operator:`notDeepEqual`}))},n.notDeepStrictEqual=l,n.throws=(e,t,n)=>{let r,i=!1;try{e()}catch(e){r=e,i=!0}if(!i)throw Q(typeof t==`string`?t:n,()=>new Z({message:`Missing expected exception`,operator:`throws`}));if(!(typeof t==`string`||t instanceof Error)&&!Qr(r,t))throw Q(n,()=>new Z({message:`Got unwanted exception`,actual:r,operator:`throws`}))},n.doesNotThrow=(e,t)=>{try{e()}catch(e){throw Q(t,()=>new Z({message:`Got unwanted exception`,actual:e,operator:`doesNotThrow`}))}},n.fail=e=>{throw Q(e,()=>new Z({message:`Failed`,operator:`fail`}))},n.AssertionError=Z,n}const ei=$r(!0);ei.strict=ei;const ti=$r(!1);ti.strict=ei;const ni=Symbol.for(`nodejs.util.inspect.custom`),ri=Symbol.for(`nodejs.util.promisify.custom`);function ii(e){return`'${e.replace(/\\/g,`\\\\`).replace(/'/g,`\\'`).replace(/\n/g,`\\n`)}'`}function ai(e){if(e===null)return`null`;let t=typeof e;if(t===`string`)return ii(e);if(t===`number`)return Object.is(e,-0)?`-0`:String(e);if(t===`bigint`)return`${String(e)}n`;if(t===`boolean`||t===`undefined`)return String(e);if(t===`symbol`)return e.toString();if(t===`function`){let t=e.name;return t?`[Function: ${t}]`:`[Function (anonymous)]`}return null}function oi(e){return e instanceof RegExp?e.toString():e instanceof Date?Number.isNaN(e.getTime())?`Invalid Date`:e.toISOString():e instanceof Error?e.stack||`${e.name}: ${e.message}`:null}function si(e,t,n){if(Array.isArray(e))return e.length===0?`[]`:`[ ${e.map(e=>ci(e,t+1,n)).join(`, `)} ]`;if(e instanceof Map){let r=[...e].map(([e,r])=>`${ci(e,t+1,n)} => ${ci(r,t+1,n)}`);return`Map(${e.size}) {${r.length?` ${r.join(`, `)} `:``}}`}if(e instanceof Set){let r=[...e].map(e=>ci(e,t+1,n));return`Set(${e.size}) {${r.length?` ${r.join(`, `)} `:``}}`}let r=Object.keys(e),i=e.constructor?e.constructor.name:``,a=i&&i!==`Object`?`${i} `:``;return r.length===0?`${a}{}`:`${a}{ ${r.map(r=>`${/^[A-Za-z_$][A-Za-z0-9_$]*$/.test(r)?r:ii(r)}: ${ci(e[r],t+1,n)}`).join(`, `)} }`}function ci(e,t,n){let r=ai(e);if(r!==null)return r;let i=e,a=oi(i);if(a!==null)return a;let o=i[ni];if(typeof o==`function`)try{return String(o.call(i,n.maxDepth,n.opts))}catch{}if(n.seen.has(e))return`[Circular *1]`;if(n.maxDepth!==null&&t>n.maxDepth)return Array.isArray(e)?`[Array]`:`[Object]`;n.seen.add(e);try{return si(i,t,n)}finally{n.seen.delete(e)}}function li(e,t={}){let n=t.depth===void 0?2:t.depth;return ci(e,0,{seen:new Set,maxDepth:n,opts:t})}function ui(e,t,n,r){if(e===`%%`)return`%`;if(n.i>=t.length)return e;let i=t[n.i];switch(e){case`%s`:return n.i++,typeof i==`string`?i:typeof i==`bigint`?`${String(i)}n`:i==null||typeof i==`number`||typeof i==`boolean`?String(i):li(i,{depth:r.depth===void 0?2:r.depth});case`%d`:return n.i++,typeof i==`bigint`?`${String(i)}n`:Number.isNaN(Number(i))?`NaN`:String(Number(i));case`%i`:return n.i++,typeof i==`bigint`?`${String(i)}n`:String(Number.parseInt(i,10));case`%f`:return n.i++,String(typeof i==`bigint`?i:Number.parseFloat(i));case`%j`:n.i++;try{return JSON.stringify(i)??`undefined`}catch{return`[Circular]`}case`%o`:return n.i++,li(i,{depth:4});case`%O`:return n.i++,li(i,{depth:null});case`%c`:return n.i++,``;default:return e}}function di(e,...t){let n=t[0];if(typeof n!=`string`)return t.map(e=>typeof e==`string`?e:li(e)).join(` `);let r={i:1},i=n.replace(/%[sdifjoOc%]/g,n=>ui(n,t,r,e));for(;r.i<t.length;r.i++){let e=t[r.i];i+=` ${typeof e==`string`?e:li(e)}`}return i}function fi(...e){return di({},...e)}function pi(e,t){if(e==null)throw TypeError(`The constructor to "inherits" must not be null or undefined`);if(t==null)throw TypeError(`The super constructor to "inherits" must not be null or undefined`);if(t.prototype===void 0)throw TypeError(`The super constructor to "inherits" must have a prototype`);e.super_=t,Object.setPrototypeOf(e.prototype,t.prototype)}function mi(e){if(typeof e!=`function`)throw TypeError(`The "original" argument must be of type function`);let t=e[ri];if(t){if(typeof t!=`function`)throw TypeError(`The [util.promisify.custom] property must be of type function`);return t}function n(...t){return new Promise((n,r)=>{e.call(this,...t,(e,...t)=>{if(e){r(e);return}n(t.length>1?t:t[0])})})}return Object.setPrototypeOf(n,Object.getPrototypeOf(e)),Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)),n}const hi=li;hi.custom=ni;const gi=mi;gi.custom=ri;const _i={format:fi,formatWithOptions:di,inspect:hi,inherits:pi,promisify:gi};function vi(e){return typeof e==`string`?new Uint8Array(Lr(e,`utf8`)):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e)}function yi(e){let t={};return e&&(typeof e.level==`number`&&(t.level=e.level),typeof e.windowBits==`number`&&(t.windowBits=e.windowBits),typeof e.memLevel==`number`&&(t.memLevel=e.memLevel),typeof e.strategy==`number`&&(t.strategy=e.strategy)),t}function bi(e,t,n){return Lr(e(vi(t),yi(n)))}function xi(e,t,n,r){let i=typeof n==`function`?n:r,a=typeof n==`function`?void 0:n;if(typeof i!=`function`)throw TypeError(`zlib: callback is required`);let o;try{o=bi(e,t,a)}catch(e){queueMicrotask(()=>i(e instanceof Error?e:Error(String(e))));return}queueMicrotask(()=>i(null,o))}const Si={gzipSync:(e,t)=>bi($n,e,t),gunzipSync:(e,t)=>bi(rr,e,t),deflateSync:(e,t)=>bi(Zn,e,t),inflateSync:(e,t)=>bi(rr,e,t),deflateRawSync:(e,t)=>bi(Qn,e,t),inflateRawSync:(e,t)=>bi(ir,e,t),gzip:(e,t,n)=>xi($n,e,t,n),gunzip:(e,t,n)=>xi(rr,e,t,n),deflate:(e,t,n)=>xi(Zn,e,t,n),inflate:(e,t,n)=>xi(rr,e,t,n),deflateRaw:(e,t,n)=>xi(Qn,e,t,n),inflateRaw:(e,t,n)=>xi(ir,e,t,n),constants:{Z_NO_FLUSH:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1}},Ci={tmpdir:()=>`/tmp`,homedir:()=>`/home/user`,platform:()=>`linux`,arch:()=>`x64`,EOL:`
|
|
42
|
-
`,cpus:()=>[{model:`virtual`,speed:0}],hostname:()=>`slicc`,type:()=>`Linux`,release:()=>`0.0.0`};function wi(e){let t=typeof e==`string`?e:e.href;if(!t.startsWith(`file://`))throw TypeError(`fileURLToPath: not a file URL`);let n=t.slice(7);return decodeURIComponent(n)}function Ti(e){let t=e.split(`/`).map(e=>encodeURIComponent(e)).join(`/`);return new URL(`file://${t}`)}const Ei={URL:globalThis.URL,URLSearchParams:globalThis.URLSearchParams,fileURLToPath:wi,pathToFileURL:Ti};var Di=class{_events=new Map;on(e,t){let n=this._events.get(e);return n?n.push(t):this._events.set(e,[t]),this}addListener(e,t){return this.on(e,t)}off(e,t){let n=this._events.get(e);if(n){let r=n.indexOf(t);r!==-1&&n.splice(r,1),n.length===0&&this._events.delete(e)}return this}removeListener(e,t){return this.off(e,t)}once(e,t){let n=(...r)=>{this.off(e,n),t(...r)};return this.on(e,n)}emit(e,...t){let n=this._events.get(e);if(!n||n.length===0)return!1;for(let e of[...n])e(...t);return!0}removeAllListeners(e){return e===void 0?this._events.clear():this._events.delete(e),this}listenerCount(e){return this._events.get(e)?.length??0}listeners(e){return[...this._events.get(e)??[]]}};const Oi=Object.assign(Di,{EventEmitter:Di,default:Di});var ki=class{_events=new Map;writable=!0;readable=!0;on(e,t){let n=this._events.get(e);return n?n.push(t):this._events.set(e,[t]),this}once(e,t){let n=(...r)=>{this.off(e,n),t(...r)};return this.on(e,n)}off(e,t){let n=this._events.get(e);if(n){let e=n.indexOf(t);e!==-1&&n.splice(e,1)}return this}emit(e,...t){let n=this._events.get(e);if(!n||n.length===0)return!1;for(let e of[...n])e(...t);return!0}pipe(e){return e}removeListener(e,t){return this.off(e,t)}removeAllListeners(){return this._events.clear(),this}},Ai=class extends ki{read(){return null}destroy(){return this}},ji=class extends ki{write(e,t,n){return n&&queueMicrotask(n),!0}end(e){return e&&queueMicrotask(e),this}destroy(){return this}},Mi=class extends ki{write(e,t,n){return n&&queueMicrotask(n),!0}end(e){return e&&queueMicrotask(e),this}read(){return null}destroy(){return this}};const Ni={Readable:Ai,Writable:ji,Transform:Mi,PassThrough:class extends Mi{},Stream:ki};let Pi=1;function Fi(e){if(typeof e==`string`)return e;if(ArrayBuffer.isView(e)){let t=e;return new TextDecoder().decode(new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}return e==null?``:String(e)}function Ii(e,t){return t===void 0||t===`utf8`||t===`utf-8`?e:t===`buffer`||t===null?Lr(e):Lr(e).toString(t)}function Li(e,t){if(e.length===0)return Ii(``,t);if(typeof e[0]==`string`)return e.join(``);let n=globalThis.Buffer;return n?n.concat(e):e[0]}function Ri(e,t,n){t.length>0&&e.emit(`data`,Ii(t,n)),e.readable=!1,e.emit(`end`)}function zi(e){let t=e=>{typeof e==`function`&&queueMicrotask(e)};return{writable:!0,write(n,r,i){return e.stdin.write(Fi(n)),t(typeof r==`function`?r:i),!0},end(n,r,i){n!==void 0&&typeof n!=`function`&&e.stdin.write(Fi(n)),e.stdin.end(),this.writable=!1,t(typeof n==`function`?n:typeof r==`function`?r:i)}}}var Bi=class extends Di{stdout;stderr;stdin;pid;exitCode=null;signalCode=null;killed=!1;spawnfile;spawnargs;handle;constructor(e,t,n,r){super(),this.handle=e,this.pid=Pi++,this.spawnfile=n,this.spawnargs=r,this.stdout=new Ai,this.stderr=new Ai,this.stdin=zi(e),e.done.then(e=>this.finish(e,t),e=>this.emit(`error`,e instanceof Error?e:Error(String(e))))}finish(e,t){Ri(this.stdout,e.stdout,t),Ri(this.stderr,e.stderr,t),this.exitCode=e.exitCode;let n=this.killed?null:e.exitCode,r=this.killed?this.signalCode:null;this.emit(`exit`,n,r),this.emit(`close`,n,r)}kill(e=`SIGTERM`){return this.killed=!0,this.signalCode=e,this.handle.kill(e).catch(()=>{}),!0}};function Vi(e){let t=(t,n,r,i,a)=>{let o=e.start(t),s=new Bi(o,r,i,a);return n.input!==void 0&&s.stdin.write(Fi(n.input)),queueMicrotask(()=>o.stdin.end()),s},n=(e,t,n,r)=>{if(typeof r!=`function`)return;let i=[],a=[];e.stdout.on(`data`,e=>i.push(e)),e.stderr.on(`data`,e=>a.push(e)),e.once(`error`,e=>r(e,Li(i,t),Li(a,t))),e.once(`close`,(o,s)=>{let c=Li(i,t),l=Li(a,t);if(o===0){r(null,c,l);return}r(Object.assign(Error(`Command failed: ${n}\n${Fi(l)}`),{code:o===null?void 0:o,killed:e.killed,signal:s??null,cmd:n}),c,l)})},r=(e,r,i)=>{let a=typeof r==`function`?r:i,o=r&&typeof r==`object`?r:{},s=o.encoding===void 0?`utf8`:o.encoding,c=t(e,o,s,e,[]);return n(c,s,e,a),c},i=(e,r,i,a)=>{let o=[],s={},c;Array.isArray(r)?(o=r,typeof i==`function`?c=i:(s=i??{},c=typeof a==`function`?a:void 0)):typeof r==`function`?c=r:r&&typeof r==`object`&&(s=r,c=typeof i==`function`?i:void 0);let l=s.encoding===void 0?`utf8`:s.encoding,u=[e,...o],d=t(u,s,l,e,o);return n(d,l,u.join(` `),c),d},a=(e,n,r)=>{let i=[],a={};Array.isArray(n)?(i=n,a=r??{}):n&&typeof n==`object`&&(a=n);let o=a.encoding===void 0?`buffer`:a.encoding;return t(a.shell?`${e}${i.length?` ${i.join(` `)}`:``}`:[e,...i],a,o,e,i)},o=(e,t)=>new Promise((n,i)=>{r(e,t,(e,t,r)=>{if(e){i(Object.assign(e,{stdout:t,stderr:r}));return}n({stdout:t,stderr:r})})}),s=(e,t,n)=>new Promise((r,a)=>{i(e,Array.isArray(t)?t:[],Array.isArray(t)?n:t,(e,t,n)=>{if(e){a(Object.assign(e,{stdout:t,stderr:n}));return}r({stdout:t,stderr:n})})}),c=e=>()=>{throw Error(`child_process.${e} is not available in the browser realm`)},l=(e,t)=>{Object.defineProperty(e,ri,{value:t,enumerable:!1,configurable:!0})};return l(r,o),l(i,s),{exec:r,execFile:i,spawn:a,execSync:c(`execSync`),spawnSync:c(`spawnSync`),execFileSync:c(`execFileSync`),fork:c(`fork`),ChildProcess:Bi}}const Hi=new Set([`child_process`,`events`,`fs`,`fs/promises`,`os`,`path`,`stream`,`url`,`crypto`,`process`,`buffer`,`assert`,`assert/strict`,`util`]),Ui=new Set([...new Set(`assert.assert/strict.async_hooks.buffer.child_process.cluster.console.constants.crypto.dgram.diagnostics_channel.dns.dns/promises.domain.events.fs.fs/promises.http.http2.https.inspector.inspector/promises.module.net.os.path.path/posix.path/win32.perf_hooks.process.punycode.querystring.readline.readline/promises.repl.stream.stream/consumers.stream/promises.stream/web.string_decoder.sys.timers.timers/promises.tls.trace_events.tty.url.util.util/types.v8.vm.wasi.worker_threads.zlib`.split(`.`))].filter(e=>!Hi.has(e)));function Wi(e){let t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return n}var Gi=class{rpc;targetId;selector;index;constructor(e,t,n,r){this.rpc=e,this.targetId=t,this.selector=n,this.index=r}evalOnElement(e){let t=`(() => { const els = document.querySelectorAll(${JSON.stringify(this.selector)}); const el = els[${this.index}]; ${e} })()`;return this.rpc.call(`browser`,`evalAsync`,[this.targetId,t])}async textContent(){return this.evalOnElement(`return el ? el.textContent : null;`)}async getAttribute(e){return this.evalOnElement(`return el ? el.getAttribute(${JSON.stringify(e)}) : null;`)}async isVisible(){return this.evalOnElement(`if (!el) return false; const s = getComputedStyle(el); if (s.display === 'none' || s.visibility === 'hidden' || s.opacity === '0') return false; const r = el.getBoundingClientRect(); return r.width > 0 && r.height > 0;`)}async boundingBox(){return this.evalOnElement(`if (!el) return null; const r = el.getBoundingClientRect(); return { x: r.x, y: r.y, width: r.width, height: r.height };`)}},Ki=class{rpc;targetId;onClose;closed=!1;constructor(e,t,n){this.rpc=e,this.targetId=t,this.onClose=n}async goto(e,t){await this.rpc.call(`browser`,`navigateTab`,[this.targetId,e])}async waitForLoadState(e){await this.rpc.call(`browser`,`waitForLoadState`,[this.targetId,e??`load`])}async waitForTimeout(e){await new Promise(t=>setTimeout(t,e))}async evaluate(e,...t){let n=typeof e==`string`?e:`(${e.toString()}).apply(null, JSON.parse(${JSON.stringify(JSON.stringify(t))}))`;return this.rpc.call(`browser`,`evalAsync`,[this.targetId,n])}async screenshot(e){let t={};e?.fullPage!==void 0&&(t.fullPage=e.fullPage);let n=Wi(await this.rpc.call(`browser`,`screenshotTab`,[this.targetId,t]));return e?.path&&await this.rpc.call(`vfs`,`writeFileBinary`,[e.path,n]),n}async $(e){return await this.rpc.call(`browser`,`evalAsync`,[this.targetId,`!!document.querySelector(${JSON.stringify(e)})`])?new Gi(this.rpc,this.targetId,e,0):null}async $$(e){let t=await this.rpc.call(`browser`,`evalAsync`,[this.targetId,`document.querySelectorAll(${JSON.stringify(e)}).length`]),n=[];for(let r=0;r<t;r++)n.push(new Gi(this.rpc,this.targetId,e,r));return n}async $$eval(e,t,...n){if(typeof t==`string`)return this.rpc.call(`browser`,`evalAsync`,[this.targetId,t]);let r=`(${t.toString()}).apply(null, [Array.from(document.querySelectorAll(${JSON.stringify(e)}))].concat(JSON.parse(${JSON.stringify(JSON.stringify(n))})))`;return this.rpc.call(`browser`,`evalAsync`,[this.targetId,r])}async content(){return this.rpc.call(`browser`,`evalAsync`,[this.targetId,`document.documentElement.outerHTML`])}async setViewportSize(e){await this.rpc.call(`browser`,`setViewport`,[this.targetId,e.width,e.height])}async close(){this.closed||(this.closed=!0,await this.rpc.call(`browser`,`closeTab`,[this.targetId]),this.onClose?.())}},qi=class{rpc;openPages=[];constructor(e){this.rpc=e}async newPage(e){let t=await this.rpc.call(`browser`,`createTab`,[`about:blank`]);e?.viewport&&await this.rpc.call(`browser`,`setViewport`,[t,e.viewport.width,e.viewport.height]);let n=new Ki(this.rpc,t,()=>{let e=this.openPages.indexOf(n);e!==-1&&this.openPages.splice(e,1)});return this.openPages.push(n),n}pages(){return[...this.openPages]}async close(){let e=this.openPages.splice(0,this.openPages.length);for(let t of e)await t.close()}},Ji=class{rpc;openPages=[];openContexts=[];constructor(e){this.rpc=e}async newPage(e){let t=await this.rpc.call(`browser`,`createTab`,[`about:blank`]);e?.viewport&&await this.rpc.call(`browser`,`setViewport`,[t,e.viewport.width,e.viewport.height]);let n=new Ki(this.rpc,t,()=>{let e=this.openPages.indexOf(n);e!==-1&&this.openPages.splice(e,1)});return this.openPages.push(n),n}async newContext(e){let t=new qi(this.rpc);return this.openContexts.push(t),t}contexts(){return[...this.openContexts]}async close(){let e=this.openPages.splice(0,this.openPages.length);for(let t of e)await t.close();let t=this.openContexts.splice(0,this.openContexts.length);for(let e of t)await e.close()}};function Yi(e){let t=async t=>new Ji(e),n=async(t,n)=>new Ji(e);return{chromium:{launch:t,connect:n,connectOverCDP:n},firefox:{launch:t,connect:n},webkit:{launch:t,connect:n}}}var Xi=class{port;nextId=1;pending=new Map;eventSubscribers=new Map;handler;disposed=!1;constructor(e){this.port=e,this.handler=e=>{let t=e.data;if(t?.type===`realm-rpc-res`){let t=e.data,n=this.pending.get(t.id);if(!n)return;this.pending.delete(t.id),typeof t.error==`string`?n.reject(Error(t.error)):n.resolve(t.result);return}if(t?.type===`realm-event`){let t=e.data,n=this.eventSubscribers.get(t.channel);if(!n)return;for(let e of[...n])try{e(t.payload)}catch{}}},e.addEventListener(`message`,this.handler),e.start?.()}get pendingCount(){return this.pending.size}call(e,t,n=[]){if(this.disposed)return Promise.reject(Error(`realm-rpc: client disposed`));let r=this.nextId++,i={type:`realm-rpc-req`,id:r,channel:e,op:t,args:n};return new Promise((e,t)=>{this.pending.set(r,{resolve:e,reject:t}),this.port.postMessage(i)})}onEvent(e,t){if(this.disposed)return()=>{};let n=this.eventSubscribers.get(e);return n||(n=new Set,this.eventSubscribers.set(e,n)),n.add(t),()=>{let n=this.eventSubscribers.get(e);n&&(n.delete(t),n.size===0&&this.eventSubscribers.delete(e))}}dispose(){if(this.disposed)return;this.disposed=!0,this.port.removeEventListener(`message`,this.handler);let e=Error(`realm-rpc: client disposed`);for(let t of this.pending.values())t.reject(e);this.pending.clear(),this.eventSubscribers.clear()}};const Zi=new Set([`bcrypt`,`better-sqlite3`,`canvas`,`cpu-features`,`fsevents`,`leveldown`,`libxmljs`,`libxmljs2`,`node-gyp-build`,`node-sass`,`puppeteer`,`robotjs`,`sass-embedded`,`sharp`,`snappy`,`sqlite3`,`tree-sitter`,`usb`]),Qi={sharp:` Use the built-in 'convert' shell command for image work.`,canvas:` Use the built-in 'convert' / OffscreenCanvas for image work.`,"better-sqlite3":` Use the built-in 'sqlite3' shell command (sql.js WASM).`,sqlite3:` Use the built-in 'sqlite3' shell command (sql.js WASM).`,bcrypt:` Use crypto.subtle.digest() with PBKDF2 / Argon2 in pure JS.`,puppeteer:` Use the built-in browser-automation shell commands.`};function $i(e,t){let n=Qi[t]??``;return Error(`require('${e}'): '${t}' is a Node native module (C++ bindings) — it cannot run in the browser sandbox.${n}`)}function ea(e){if(!e)return``;let t=e.lastIndexOf(`/`);return t<0?``:t===0?`/`:e.substring(0,t)}function ta(e){return/^[A-Za-z0-9_\-./:@]+$/.test(e)?e:`'`+e.replace(/'/g,`'\\''`)+`'`}function na(e,t){return e===``?t:e===`/`?`/${t}`:`${e}/${t}`}function ra(e){let t=ea(e.argv[1]??``),n=na(t,`references`),r=na(t,`assets`),i=na(t,`.config`);async function a(){let t;try{t=await e.fs.exists(i)}catch{return null}if(!t)return null;let n;try{n=await e.fs.readFile(i)}catch{return null}let r=typeof n==`string`?n:String(n);if(!r.trim())return null;let a;try{a=JSON.parse(r)}catch(e){let t=e instanceof Error?e.message:String(e);throw Error(`skill.config(): failed to parse ${i}: ${t}`)}if(a&&typeof a==`object`&&!Array.isArray(a))return a;throw Error(`skill.config(): ${i} must contain a JSON object`)}async function o(t){let n=await a();if(t===void 0)return n;if(typeof t!=`object`||!t||Array.isArray(t))throw TypeError(`skill.config(updates): updates must be a plain object`);let r={...n??{},...t};return await e.fs.writeFile(i,JSON.stringify(r,null,2)+`
|
|
41
|
+
`)}function br(e){return e instanceof Date?e:new Date(e)}function xr(e,t=`short`){let n=br(e);if(Number.isNaN(n.getTime()))return String(e);if(t===`iso`)return n.toISOString();if(t===`locale`)return new Intl.DateTimeFormat(void 0,{dateStyle:`medium`}).format(n);if(t===`human`){let e=Date.now()-n.getTime(),t=Math.abs(e);if(t<6e4)return e>=0?`just now`:`in a moment`;let r=(t,n)=>e>=0?`${t} ${n}${t===1?``:`s`} ago`:`in ${t} ${n}${t===1?``:`s`}`;return t<36e5?r(Math.round(t/6e4),`minute`):t<864e5?r(Math.round(t/36e5),`hour`):t<26298e5?r(Math.round(t/864e5),`day`):t<315576e5?r(Math.round(t/26298e5),`month`):r(Math.round(t/315576e5),`year`)}return`${n.getFullYear()}-${fr(n.getMonth()+1)}-${fr(n.getDate())}`}const Sr={trunc:_r,col:vr,table:yr,date:xr},Cr=async(e,t,n)=>{let r=Math.max(1,Math.trunc(e)||1),i=Array(t.length),a=0,o=[],s=async()=>{for(;;){let e=a++;if(e>=t.length)return;i[e]=await n(t[e],e)}};for(let e=0;e<Math.min(r,t.length);e++)o.push(s());return await Promise.all(o),i};function wr(e,t){let n=[];for(let r of e)r===``||r===`.`||(r===`..`?n.length>0&&n[n.length-1]!==`..`?n.pop():t&&n.push(`..`):n.push(r));return n}function Tr(e){if(e.length===0)return`.`;let t=e.charCodeAt(0)===47,n=e.charCodeAt(e.length-1)===47,r=wr(e.split(`/`),!t).join(`/`);return r.length===0&&!t&&(r=`.`),r.length>0&&n&&(r+=`/`),(t?`/`:``)+r}function Er(...e){let t=e.filter(e=>typeof e==`string`&&e.length>0).join(`/`);return t.length===0?`.`:Tr(t)}function Dr(e){if(e.length===0)return`.`;let t=e.charCodeAt(0)===47,n=-1,r=!0;for(let t=e.length-1;t>=1;t--)if(e.charCodeAt(t)===47){if(!r){n=t;break}}else r=!1;return n===-1?t?`/`:`.`:t&&n===1?`//`:e.slice(0,n)}function Or(e,t){let n=0,r=-1,i=!0;for(let t=e.length-1;t>=0;t--)if(e.charCodeAt(t)===47){if(!i){n=t+1;break}}else r===-1&&(i=!1,r=t+1);let a=r===-1?``:e.slice(n,r);return t&&a.endsWith(t)&&a!==t?a.slice(0,a.length-t.length):a}function kr(e){let t=Or(e),n=t.lastIndexOf(`.`);return n<=0?``:t.slice(n)}function Ar(...e){let t=``,n=!1;for(let r=e.length-1;r>=0&&!n;r--){let i=e[r];typeof i!=`string`||i.length===0||(t=t.length>0?`${i}/${t}`:i,n=i.charCodeAt(0)===47)}n||(t=t.length>0?`/${t}`:`/`);let r=wr(t.split(`/`),!1).join(`/`);return r.length>0?`/${r}`:`/`}function jr(e,t){let n=Ar(e),r=Ar(t);if(n===r)return``;let i=n.split(`/`).filter(Boolean),a=r.split(`/`).filter(Boolean),o=0;for(;o<i.length&&o<a.length&&i[o]===a[o];)o++;return[...i.slice(o).map(()=>`..`),...a.slice(o)].join(`/`)}function Mr(e){let t=e.charCodeAt(0)===47?`/`:``,n=Or(e),r=kr(e),i=r?n.slice(0,n.length-r.length):n,a=Dr(e);return a===`.`&&t===``&&(a=``),{root:t,dir:a,base:n,ext:r,name:i}}function Nr(e){let t=e.dir||e.root||``,n=e.base||`${e.name||``}${e.ext||``}`;return t?t===e.root?`${t}${n}`:`${t}/${n}`:n}const Pr={sep:`/`,delimiter:`:`,basename:Or,dirname:Dr,extname:kr,isAbsolute:e=>e.length>0&&e.charCodeAt(0)===47,join:Er,normalize:Tr,resolve:Ar,relative:jr,parse:Mr,format:Nr},Fr=65536,Ir={md5:y.md5,sha1:b.sha1,sha256:x.sha256};function Lr(e,t){let n=globalThis.Buffer;if(!n)throw Error(`crypto.createHash: Buffer is unavailable in this environment`);return t?n.from(e,t):n.from(e)}function Rr(e,t){return typeof e==`string`?t===`hex`||t===`base64`||t===`base64url`||t===`latin1`||t===`binary`?new Uint8Array(Lr(e,t===`binary`?`latin1`:t)):e:ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):e}function zr(e){let t=String(e).toLowerCase().replace(`-`,``),n=Ir[t];if(!n)throw Error(`Digest method not supported: ${e}`);let r=n.create(),i=!1,a={update(e,t){if(i)throw Error(`Digest already called`);return r.update(Rr(e,t)),a},digest(e){i=!0;let t=Lr(r.array());return e?t.toString(e):t}};return a}function Br(){let e=globalThis.crypto;if(!e||typeof e.getRandomValues!=`function`)throw Error(`crypto: globalThis.crypto is unavailable in this environment`);return e}function Vr(e){return Br().getRandomValues(e)}function Hr(e){for(let t=0;t<e.length;t+=Fr){let n=Math.min(t+Fr,e.length);Vr(e.subarray(t,n))}}function Ur(e){return e instanceof Uint8Array?e:new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}const X=Array.from({length:256},(e,t)=>(t+256).toString(16).slice(1));function Wr(){let e=Br();if(typeof e.randomUUID==`function`)return e.randomUUID();let t=Vr(new Uint8Array(16));return t[6]=t[6]&15|64,t[8]=t[8]&63|128,`${X[t[0]]}${X[t[1]]}${X[t[2]]}${X[t[3]]}-${X[t[4]]}${X[t[5]]}-${X[t[6]]}${X[t[7]]}-${X[t[8]]}${X[t[9]]}-${X[t[10]]}${X[t[11]]}${X[t[12]]}${X[t[13]]}${X[t[14]]}${X[t[15]]}`}const Gr={randomFillSync(e,t=0,n){let r=Ur(e),i=t,a=n===void 0?r.length:i+n;return Hr(r.subarray(i,a)),e},randomBytes(e){let t=globalThis.Buffer,n=t&&typeof t.allocUnsafe==`function`?t.allocUnsafe(e):new Uint8Array(e);return Hr(Ur(n)),n},randomUUID:Wr,getRandomValues(e){return Vr(e)},createHash:zr,get webcrypto(){return Br()},get subtle(){return Br().subtle}};var Z=class extends Error{actual;expected;operator;generatedMessage;code;constructor(e={}){let t=!e.message;super(e.message||`${Kr(e.actual)} ${e.operator||`!=`} ${Kr(e.expected)}`),this.name=`AssertionError`,this.actual=e.actual,this.expected=e.expected,this.operator=e.operator||``,this.generatedMessage=t,this.code=`ERR_ASSERTION`}};function Kr(e){if(typeof e==`string`)return JSON.stringify(e);if(e==null)return String(e);if(typeof e==`object`)try{return JSON.stringify(e)}catch{return String(e)}return String(e)}function Q(e,t){return e instanceof Error?e:typeof e==`string`?new Z({message:e}):t()}function qr(e,t,n,r){if(e.length!==t.length)return!1;for(let i=0;i<e.length;i++)if(!Yr(e[i],t[i],n,r))return!1;return!0}function Jr(e,t,n,r){let i=Object.keys(e);if(i.length!==Object.keys(t).length)return!1;for(let a of i){if(!Object.prototype.hasOwnProperty.call(t,a))return!1;let i=e[a],o=t[a];if(!Yr(i,o,n,r))return!1}return!0}function Yr(e,t,n,r){if((n?Object.is(e,t):e===t)||!n&&e==t)return!0;if(typeof e!=`object`||typeof t!=`object`||e===null||t===null)return!1;let i=e,a=t;return n&&Object.getPrototypeOf(i)!==Object.getPrototypeOf(a)?!1:r.get(i)===a?!0:(r.set(i,a),Array.isArray(e)===Array.isArray(t)?Array.isArray(e)&&Array.isArray(t)?qr(e,t,n,r):Jr(i,a,n,r):!1)}function Xr(e,t){try{if(e instanceof t)return!0}catch{}try{return!!t(e)}catch{return!1}}function Zr(e,t){for(let[n,r]of Object.entries(t)){let t=e[n];if(r instanceof RegExp){if(typeof t!=`string`||!r.test(t))return!1}else if(t!==r)return!1}return!0}function Qr(e,t){if(t===void 0)return!0;if(t instanceof RegExp){let n=e instanceof Error?e.message:String(e);return t.test(n)}return typeof t==`function`?Xr(e,t):t&&typeof t==`object`?!e||typeof e!=`object`?!1:Zr(e,t):!1}function $r(e){let t=(e,t)=>{if(!e)throw Q(t,()=>new Z({message:`The expression evaluated to a falsy value`,actual:e,expected:!0,operator:`==`}))},n=((e,n)=>t(e,n)),r=(e,t,n)=>{if(!Object.is(e,t))throw Q(n,()=>new Z({actual:e,expected:t,operator:`strictEqual`}))},i=(t,n,i)=>{if(e){r(t,n,i);return}if(t!=n)throw Q(i,()=>new Z({actual:t,expected:n,operator:`==`}))},a=(e,t,n)=>{if(Object.is(e,t))throw Q(n,()=>new Z({actual:e,expected:t,operator:`notStrictEqual`}))},o=(t,n,r)=>{if(e){a(t,n,r);return}if(t==n)throw Q(r,()=>new Z({actual:t,expected:n,operator:`!=`}))},s=(e,t,n)=>{if(!Yr(e,t,!0,new WeakMap))throw Q(n,()=>new Z({actual:e,expected:t,operator:`deepStrictEqual`}))},c=(t,n,r)=>{if(e){s(t,n,r);return}if(!Yr(t,n,!1,new WeakMap))throw Q(r,()=>new Z({actual:t,expected:n,operator:`deepEqual`}))},l=(e,t,n)=>{if(Yr(e,t,!0,new WeakMap))throw Q(n,()=>new Z({actual:e,expected:t,operator:`notDeepStrictEqual`}))};return n.ok=t,n.equal=i,n.notEqual=o,n.strictEqual=r,n.notStrictEqual=a,n.deepEqual=c,n.deepStrictEqual=s,n.notDeepEqual=(t,n,r)=>{if(e){l(t,n,r);return}if(Yr(t,n,!1,new WeakMap))throw Q(r,()=>new Z({actual:t,expected:n,operator:`notDeepEqual`}))},n.notDeepStrictEqual=l,n.throws=(e,t,n)=>{let r,i=!1;try{e()}catch(e){r=e,i=!0}if(!i)throw Q(typeof t==`string`?t:n,()=>new Z({message:`Missing expected exception`,operator:`throws`}));if(!(typeof t==`string`||t instanceof Error)&&!Qr(r,t))throw Q(n,()=>new Z({message:`Got unwanted exception`,actual:r,operator:`throws`}))},n.doesNotThrow=(e,t)=>{try{e()}catch(e){throw Q(t,()=>new Z({message:`Got unwanted exception`,actual:e,operator:`doesNotThrow`}))}},n.fail=e=>{throw Q(e,()=>new Z({message:`Failed`,operator:`fail`}))},n.AssertionError=Z,n}const ei=$r(!0);ei.strict=ei;const ti=$r(!1);ti.strict=ei;const ni=Symbol.for(`nodejs.util.inspect.custom`),ri=Symbol.for(`nodejs.util.promisify.custom`);function ii(e){return`'${e.replace(/\\/g,`\\\\`).replace(/'/g,`\\'`).replace(/\n/g,`\\n`)}'`}function ai(e){if(e===null)return`null`;let t=typeof e;if(t===`string`)return ii(e);if(t===`number`)return Object.is(e,-0)?`-0`:String(e);if(t===`bigint`)return`${String(e)}n`;if(t===`boolean`||t===`undefined`)return String(e);if(t===`symbol`)return e.toString();if(t===`function`){let t=e.name;return t?`[Function: ${t}]`:`[Function (anonymous)]`}return null}function oi(e){return e instanceof RegExp?e.toString():e instanceof Date?Number.isNaN(e.getTime())?`Invalid Date`:e.toISOString():e instanceof Error?e.stack||`${e.name}: ${e.message}`:null}function si(e,t,n){if(Array.isArray(e))return e.length===0?`[]`:`[ ${e.map(e=>ci(e,t+1,n)).join(`, `)} ]`;if(e instanceof Map){let r=[...e].map(([e,r])=>`${ci(e,t+1,n)} => ${ci(r,t+1,n)}`);return`Map(${e.size}) {${r.length?` ${r.join(`, `)} `:``}}`}if(e instanceof Set){let r=[...e].map(e=>ci(e,t+1,n));return`Set(${e.size}) {${r.length?` ${r.join(`, `)} `:``}}`}let r=Object.keys(e),i=e.constructor?e.constructor.name:``,a=i&&i!==`Object`?`${i} `:``;return r.length===0?`${a}{}`:`${a}{ ${r.map(r=>`${/^[A-Za-z_$][A-Za-z0-9_$]*$/.test(r)?r:ii(r)}: ${ci(e[r],t+1,n)}`).join(`, `)} }`}function ci(e,t,n){let r=ai(e);if(r!==null)return r;let i=e,a=oi(i);if(a!==null)return a;let o=i[ni];if(typeof o==`function`)try{return String(o.call(i,n.maxDepth,n.opts))}catch{}if(n.seen.has(e))return`[Circular *1]`;if(n.maxDepth!==null&&t>n.maxDepth)return Array.isArray(e)?`[Array]`:`[Object]`;n.seen.add(e);try{return si(i,t,n)}finally{n.seen.delete(e)}}function li(e,t={}){let n=t.depth===void 0?2:t.depth;return ci(e,0,{seen:new Set,maxDepth:n,opts:t})}function ui(e,t,n,r){if(e===`%%`)return`%`;if(n.i>=t.length)return e;let i=t[n.i];switch(e){case`%s`:return n.i++,typeof i==`string`?i:typeof i==`bigint`?`${String(i)}n`:i==null||typeof i==`number`||typeof i==`boolean`?String(i):li(i,{depth:r.depth===void 0?2:r.depth});case`%d`:return n.i++,typeof i==`bigint`?`${String(i)}n`:Number.isNaN(Number(i))?`NaN`:String(Number(i));case`%i`:return n.i++,typeof i==`bigint`?`${String(i)}n`:String(Number.parseInt(i,10));case`%f`:return n.i++,String(typeof i==`bigint`?i:Number.parseFloat(i));case`%j`:n.i++;try{return JSON.stringify(i)??`undefined`}catch{return`[Circular]`}case`%o`:return n.i++,li(i,{depth:4});case`%O`:return n.i++,li(i,{depth:null});case`%c`:return n.i++,``;default:return e}}function di(e,...t){let n=t[0];if(typeof n!=`string`)return t.map(e=>typeof e==`string`?e:li(e)).join(` `);let r={i:1},i=n.replace(/%[sdifjoOc%]/g,n=>ui(n,t,r,e));for(;r.i<t.length;r.i++){let e=t[r.i];i+=` ${typeof e==`string`?e:li(e)}`}return i}function fi(...e){return di({},...e)}function pi(e,t){if(e==null)throw TypeError(`The constructor to "inherits" must not be null or undefined`);if(t==null)throw TypeError(`The super constructor to "inherits" must not be null or undefined`);if(t.prototype===void 0)throw TypeError(`The super constructor to "inherits" must have a prototype`);e.super_=t,Object.setPrototypeOf(e.prototype,t.prototype)}function mi(e){if(typeof e!=`function`)throw TypeError(`The "original" argument must be of type function`);let t=e[ri];if(t){if(typeof t!=`function`)throw TypeError(`The [util.promisify.custom] property must be of type function`);return t}function n(...t){return new Promise((n,r)=>{e.call(this,...t,(e,...t)=>{if(e){r(e);return}n(t.length>1?t:t[0])})})}return Object.setPrototypeOf(n,Object.getPrototypeOf(e)),Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)),n}const hi=li;hi.custom=ni;const gi=mi;gi.custom=ri;const _i={format:fi,formatWithOptions:di,inspect:hi,inherits:pi,promisify:gi};function vi(e){return typeof e==`string`?new Uint8Array(Lr(e,`utf8`)):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e)}function yi(e){let t={};return e&&(typeof e.level==`number`&&(t.level=e.level),typeof e.windowBits==`number`&&(t.windowBits=e.windowBits),typeof e.memLevel==`number`&&(t.memLevel=e.memLevel),typeof e.strategy==`number`&&(t.strategy=e.strategy)),t}function bi(e,t,n){return Lr(e(vi(t),yi(n)))}function xi(e,t,n,r){let i=typeof n==`function`?n:r,a=typeof n==`function`?void 0:n;if(typeof i!=`function`)throw TypeError(`zlib: callback is required`);let o;try{o=bi(e,t,a)}catch(e){queueMicrotask(()=>i(e instanceof Error?e:Error(String(e))));return}queueMicrotask(()=>i(null,o))}const Si={gzipSync:(e,t)=>bi($n,e,t),gunzipSync:(e,t)=>bi(rr,e,t),deflateSync:(e,t)=>bi(Zn,e,t),inflateSync:(e,t)=>bi(rr,e,t),deflateRawSync:(e,t)=>bi(Qn,e,t),inflateRawSync:(e,t)=>bi(ir,e,t),gzip:(e,t,n)=>xi($n,e,t,n),gunzip:(e,t,n)=>xi(rr,e,t,n),deflate:(e,t,n)=>xi(Zn,e,t,n),inflate:(e,t,n)=>xi(rr,e,t,n),deflateRaw:(e,t,n)=>xi(Qn,e,t,n),inflateRaw:(e,t,n)=>xi(ir,e,t,n),constants:{Z_NO_FLUSH:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1}},Ci={tmpdir:()=>`/tmp`,homedir:()=>`/home/user`,platform:()=>`linux`,arch:()=>`x64`,EOL:`
|
|
42
|
+
`,cpus:()=>[{model:`virtual`,speed:0}],hostname:()=>`slicc`,type:()=>`Linux`,release:()=>`0.0.0`};function wi(e){let t=typeof e==`string`?e:e.href;if(!t.startsWith(`file://`))throw TypeError(`fileURLToPath: not a file URL`);let n=t.slice(7);return decodeURIComponent(n)}function Ti(e){let t=e.split(`/`).map(e=>encodeURIComponent(e)).join(`/`);return new URL(`file://${t}`)}const Ei={URL:globalThis.URL,URLSearchParams:globalThis.URLSearchParams,fileURLToPath:wi,pathToFileURL:Ti};var Di=class{_events=new Map;on(e,t){let n=this._events.get(e);return n?n.push(t):this._events.set(e,[t]),this}addListener(e,t){return this.on(e,t)}off(e,t){let n=this._events.get(e);if(n){let r=n.indexOf(t);r!==-1&&n.splice(r,1),n.length===0&&this._events.delete(e)}return this}removeListener(e,t){return this.off(e,t)}once(e,t){let n=(...r)=>{this.off(e,n),t(...r)};return this.on(e,n)}emit(e,...t){let n=this._events.get(e);if(!n||n.length===0)return!1;for(let e of[...n])e(...t);return!0}removeAllListeners(e){return e===void 0?this._events.clear():this._events.delete(e),this}listenerCount(e){return this._events.get(e)?.length??0}listeners(e){return[...this._events.get(e)??[]]}};const Oi=Object.assign(Di,{EventEmitter:Di,default:Di});var ki=class{_events=new Map;writable=!0;readable=!0;on(e,t){let n=this._events.get(e);return n?n.push(t):this._events.set(e,[t]),this}once(e,t){let n=(...r)=>{this.off(e,n),t(...r)};return this.on(e,n)}off(e,t){let n=this._events.get(e);if(n){let e=n.indexOf(t);e!==-1&&n.splice(e,1)}return this}emit(e,...t){let n=this._events.get(e);if(!n||n.length===0)return!1;for(let e of[...n])e(...t);return!0}pipe(e){return e}removeListener(e,t){return this.off(e,t)}removeAllListeners(){return this._events.clear(),this}},Ai=class extends ki{read(){return null}destroy(){return this}},ji=class extends ki{write(e,t,n){return n&&queueMicrotask(n),!0}end(e){return e&&queueMicrotask(e),this}destroy(){return this}},Mi=class extends ki{write(e,t,n){return n&&queueMicrotask(n),!0}end(e){return e&&queueMicrotask(e),this}read(){return null}destroy(){return this}};const Ni={Readable:Ai,Writable:ji,Transform:Mi,PassThrough:class extends Mi{},Stream:ki};let Pi=1;function Fi(e){if(typeof e==`string`)return e;if(ArrayBuffer.isView(e)){let t=e;return new TextDecoder().decode(new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}return e==null?``:String(e)}function Ii(e,t){return t===void 0||t===`utf8`||t===`utf-8`?e:t===`buffer`||t===null?Lr(e):Lr(e).toString(t)}function Li(e,t){if(e.length===0)return Ii(``,t);if(typeof e[0]==`string`)return e.join(``);let n=globalThis.Buffer;return n?n.concat(e):e[0]}function Ri(e,t,n){t.length>0&&e.emit(`data`,Ii(t,n)),e.readable=!1,e.emit(`end`)}function zi(e){let t=e=>{typeof e==`function`&&queueMicrotask(e)};return{writable:!0,write(n,r,i){return e.stdin.write(Fi(n)),t(typeof r==`function`?r:i),!0},end(n,r,i){n!==void 0&&typeof n!=`function`&&e.stdin.write(Fi(n)),e.stdin.end(),this.writable=!1,t(typeof n==`function`?n:typeof r==`function`?r:i)}}}var Bi=class extends Di{stdout;stderr;stdin;pid;exitCode=null;signalCode=null;killed=!1;spawnfile;spawnargs;handle;constructor(e,t,n,r){super(),this.handle=e,this.pid=Pi++,this.spawnfile=n,this.spawnargs=r,this.stdout=new Ai,this.stderr=new Ai,this.stdin=zi(e),e.done.then(e=>this.finish(e,t),e=>this.emit(`error`,e instanceof Error?e:Error(String(e))))}finish(e,t){Ri(this.stdout,e.stdout,t),Ri(this.stderr,e.stderr,t),this.exitCode=e.exitCode;let n=this.killed?null:e.exitCode,r=this.killed?this.signalCode:null;this.emit(`exit`,n,r),this.emit(`close`,n,r)}kill(e=`SIGTERM`){return this.killed=!0,this.signalCode=e,this.handle.kill(e).catch(()=>{}),!0}};function Vi(e){let t=(t,n,r,i,a)=>{let o=e.start(t),s=new Bi(o,r,i,a);return n.input!==void 0&&s.stdin.write(Fi(n.input)),queueMicrotask(()=>o.stdin.end()),s},n=(e,t,n,r)=>{if(typeof r!=`function`)return;let i=[],a=[];e.stdout.on(`data`,e=>i.push(e)),e.stderr.on(`data`,e=>a.push(e)),e.once(`error`,e=>r(e,Li(i,t),Li(a,t))),e.once(`close`,(o,s)=>{let c=Li(i,t),l=Li(a,t);if(o===0){r(null,c,l);return}r(Object.assign(Error(`Command failed: ${n}\n${Fi(l)}`),{code:o===null?void 0:o,killed:e.killed,signal:s??null,cmd:n}),c,l)})},r=(e,r,i)=>{let a=typeof r==`function`?r:i,o=r&&typeof r==`object`?r:{},s=o.encoding===void 0?`utf8`:o.encoding,c=t(e,o,s,e,[]);return n(c,s,e,a),c},i=(e,r,i,a)=>{let o=[],s={},c;Array.isArray(r)?(o=r,typeof i==`function`?c=i:(s=i??{},c=typeof a==`function`?a:void 0)):typeof r==`function`?c=r:r&&typeof r==`object`&&(s=r,c=typeof i==`function`?i:void 0);let l=s.encoding===void 0?`utf8`:s.encoding,u=[e,...o],d=t(u,s,l,e,o);return n(d,l,u.join(` `),c),d},a=(e,n,r)=>{let i=[],a={};Array.isArray(n)?(i=n,a=r??{}):n&&typeof n==`object`&&(a=n);let o=a.encoding===void 0?`buffer`:a.encoding,s=a.shell?`${e}${i.length?` ${i.join(` `)}`:``}`:[e,...i];return t(s,a,o,e,i)},o=(e,t)=>new Promise((n,i)=>{r(e,t,(e,t,r)=>{if(e){i(Object.assign(e,{stdout:t,stderr:r}));return}n({stdout:t,stderr:r})})}),s=(e,t,n)=>new Promise((r,a)=>{i(e,Array.isArray(t)?t:[],Array.isArray(t)?n:t,(e,t,n)=>{if(e){a(Object.assign(e,{stdout:t,stderr:n}));return}r({stdout:t,stderr:n})})}),c=e=>()=>{throw Error(`child_process.${e} is not available in the browser realm`)},l=(e,t)=>{Object.defineProperty(e,ri,{value:t,enumerable:!1,configurable:!0})};return l(r,o),l(i,s),{exec:r,execFile:i,spawn:a,execSync:c(`execSync`),spawnSync:c(`spawnSync`),execFileSync:c(`execFileSync`),fork:c(`fork`),ChildProcess:Bi}}const Hi=new Set([`child_process`,`events`,`fs`,`fs/promises`,`os`,`path`,`stream`,`url`,`crypto`,`process`,`buffer`,`assert`,`assert/strict`,`util`]),Ui=new Set([...new Set(`assert.assert/strict.async_hooks.buffer.child_process.cluster.console.constants.crypto.dgram.diagnostics_channel.dns.dns/promises.domain.events.fs.fs/promises.http.http2.https.inspector.inspector/promises.module.net.os.path.path/posix.path/win32.perf_hooks.process.punycode.querystring.readline.readline/promises.repl.stream.stream/consumers.stream/promises.stream/web.string_decoder.sys.timers.timers/promises.tls.trace_events.tty.url.util.util/types.v8.vm.wasi.worker_threads.zlib`.split(`.`))].filter(e=>!Hi.has(e)));function Wi(e){let t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return n}var Gi=class{rpc;targetId;selector;index;constructor(e,t,n,r){this.rpc=e,this.targetId=t,this.selector=n,this.index=r}evalOnElement(e){let t=`(() => { const els = document.querySelectorAll(${JSON.stringify(this.selector)}); const el = els[${this.index}]; ${e} })()`;return this.rpc.call(`browser`,`evalAsync`,[this.targetId,t])}async textContent(){return this.evalOnElement(`return el ? el.textContent : null;`)}async getAttribute(e){return this.evalOnElement(`return el ? el.getAttribute(${JSON.stringify(e)}) : null;`)}async isVisible(){return this.evalOnElement(`if (!el) return false; const s = getComputedStyle(el); if (s.display === 'none' || s.visibility === 'hidden' || s.opacity === '0') return false; const r = el.getBoundingClientRect(); return r.width > 0 && r.height > 0;`)}async boundingBox(){return this.evalOnElement(`if (!el) return null; const r = el.getBoundingClientRect(); return { x: r.x, y: r.y, width: r.width, height: r.height };`)}},Ki=class{rpc;targetId;onClose;closed=!1;constructor(e,t,n){this.rpc=e,this.targetId=t,this.onClose=n}async goto(e,t){await this.rpc.call(`browser`,`navigateTab`,[this.targetId,e])}async waitForLoadState(e){await this.rpc.call(`browser`,`waitForLoadState`,[this.targetId,e??`load`])}async waitForTimeout(e){await new Promise(t=>setTimeout(t,e))}async evaluate(e,...t){let n=typeof e==`string`?e:`(${e.toString()}).apply(null, JSON.parse(${JSON.stringify(JSON.stringify(t))}))`;return this.rpc.call(`browser`,`evalAsync`,[this.targetId,n])}async screenshot(e){let t={};e?.fullPage!==void 0&&(t.fullPage=e.fullPage);let n=Wi(await this.rpc.call(`browser`,`screenshotTab`,[this.targetId,t]));return e?.path&&await this.rpc.call(`vfs`,`writeFileBinary`,[e.path,n]),n}async $(e){return await this.rpc.call(`browser`,`evalAsync`,[this.targetId,`!!document.querySelector(${JSON.stringify(e)})`])?new Gi(this.rpc,this.targetId,e,0):null}async $$(e){let t=await this.rpc.call(`browser`,`evalAsync`,[this.targetId,`document.querySelectorAll(${JSON.stringify(e)}).length`]),n=[];for(let r=0;r<t;r++)n.push(new Gi(this.rpc,this.targetId,e,r));return n}async $$eval(e,t,...n){if(typeof t==`string`)return this.rpc.call(`browser`,`evalAsync`,[this.targetId,t]);let r=`(${t.toString()}).apply(null, [Array.from(document.querySelectorAll(${JSON.stringify(e)}))].concat(JSON.parse(${JSON.stringify(JSON.stringify(n))})))`;return this.rpc.call(`browser`,`evalAsync`,[this.targetId,r])}async content(){return this.rpc.call(`browser`,`evalAsync`,[this.targetId,`document.documentElement.outerHTML`])}async setViewportSize(e){await this.rpc.call(`browser`,`setViewport`,[this.targetId,e.width,e.height])}async close(){this.closed||(this.closed=!0,await this.rpc.call(`browser`,`closeTab`,[this.targetId]),this.onClose?.())}},qi=class{rpc;openPages=[];constructor(e){this.rpc=e}async newPage(e){let t=await this.rpc.call(`browser`,`createTab`,[`about:blank`]);e?.viewport&&await this.rpc.call(`browser`,`setViewport`,[t,e.viewport.width,e.viewport.height]);let n=new Ki(this.rpc,t,()=>{let e=this.openPages.indexOf(n);e!==-1&&this.openPages.splice(e,1)});return this.openPages.push(n),n}pages(){return[...this.openPages]}async close(){let e=this.openPages.splice(0,this.openPages.length);for(let t of e)await t.close()}},Ji=class{rpc;openPages=[];openContexts=[];constructor(e){this.rpc=e}async newPage(e){let t=await this.rpc.call(`browser`,`createTab`,[`about:blank`]);e?.viewport&&await this.rpc.call(`browser`,`setViewport`,[t,e.viewport.width,e.viewport.height]);let n=new Ki(this.rpc,t,()=>{let e=this.openPages.indexOf(n);e!==-1&&this.openPages.splice(e,1)});return this.openPages.push(n),n}async newContext(e){let t=new qi(this.rpc);return this.openContexts.push(t),t}contexts(){return[...this.openContexts]}async close(){let e=this.openPages.splice(0,this.openPages.length);for(let t of e)await t.close();let t=this.openContexts.splice(0,this.openContexts.length);for(let e of t)await e.close()}};function Yi(e){let t=async t=>new Ji(e),n=async(t,n)=>new Ji(e);return{chromium:{launch:t,connect:n,connectOverCDP:n},firefox:{launch:t,connect:n},webkit:{launch:t,connect:n}}}var Xi=class{port;nextId=1;pending=new Map;eventSubscribers=new Map;handler;disposed=!1;constructor(e){this.port=e,this.handler=e=>{let t=e.data;if(t?.type===`realm-rpc-res`){let t=e.data,n=this.pending.get(t.id);if(!n)return;this.pending.delete(t.id),typeof t.error==`string`?n.reject(Error(t.error)):n.resolve(t.result);return}if(t?.type===`realm-event`){let t=e.data,n=this.eventSubscribers.get(t.channel);if(!n)return;for(let e of[...n])try{e(t.payload)}catch{}}},e.addEventListener(`message`,this.handler),e.start?.()}get pendingCount(){return this.pending.size}call(e,t,n=[]){if(this.disposed)return Promise.reject(Error(`realm-rpc: client disposed`));let r=this.nextId++,i={type:`realm-rpc-req`,id:r,channel:e,op:t,args:n};return new Promise((e,t)=>{this.pending.set(r,{resolve:e,reject:t}),this.port.postMessage(i)})}onEvent(e,t){if(this.disposed)return()=>{};let n=this.eventSubscribers.get(e);return n||(n=new Set,this.eventSubscribers.set(e,n)),n.add(t),()=>{let n=this.eventSubscribers.get(e);n&&(n.delete(t),n.size===0&&this.eventSubscribers.delete(e))}}dispose(){if(this.disposed)return;this.disposed=!0,this.port.removeEventListener(`message`,this.handler);let e=Error(`realm-rpc: client disposed`);for(let t of this.pending.values())t.reject(e);this.pending.clear(),this.eventSubscribers.clear()}};const Zi=new Set([`bcrypt`,`better-sqlite3`,`canvas`,`cpu-features`,`fsevents`,`leveldown`,`libxmljs`,`libxmljs2`,`node-gyp-build`,`node-sass`,`puppeteer`,`robotjs`,`sass-embedded`,`sharp`,`snappy`,`sqlite3`,`tree-sitter`,`usb`]),Qi={sharp:` Use the built-in 'convert' shell command for image work.`,canvas:` Use the built-in 'convert' / OffscreenCanvas for image work.`,"better-sqlite3":` Use the built-in 'sqlite3' shell command (sql.js WASM).`,sqlite3:` Use the built-in 'sqlite3' shell command (sql.js WASM).`,bcrypt:` Use crypto.subtle.digest() with PBKDF2 / Argon2 in pure JS.`,puppeteer:` Use the built-in browser-automation shell commands.`};function $i(e,t){let n=Qi[t]??``;return Error(`require('${e}'): '${t}' is a Node native module (C++ bindings) — it cannot run in the browser sandbox.${n}`)}function ea(e){if(!e)return``;let t=e.lastIndexOf(`/`);return t<0?``:t===0?`/`:e.substring(0,t)}function ta(e){return/^[A-Za-z0-9_\-./:@]+$/.test(e)?e:`'`+e.replace(/'/g,`'\\''`)+`'`}function na(e,t){return e===``?t:e===`/`?`/${t}`:`${e}/${t}`}function ra(e){let t=ea(e.argv[1]??``),n=na(t,`references`),r=na(t,`assets`),i=na(t,`.config`);async function a(){let t;try{t=await e.fs.exists(i)}catch{return null}if(!t)return null;let n;try{n=await e.fs.readFile(i)}catch{return null}let r=typeof n==`string`?n:String(n);if(!r.trim())return null;let a;try{a=JSON.parse(r)}catch(e){let t=e instanceof Error?e.message:String(e);throw Error(`skill.config(): failed to parse ${i}: ${t}`)}if(a&&typeof a==`object`&&!Array.isArray(a))return a;throw Error(`skill.config(): ${i} must contain a JSON object`)}async function o(t){let n=await a();if(t===void 0)return n;if(typeof t!=`object`||!t||Array.isArray(t))throw TypeError(`skill.config(updates): updates must be a plain object`);let r={...n??{},...t};return await e.fs.writeFile(i,JSON.stringify(r,null,2)+`
|
|
43
43
|
`),r}async function s(t){if(typeof t!=`string`||!t.trim())throw TypeError(`skill.token(providerId): providerId must be a non-empty string`);let n=`oauth-token ${ta(t)}`,{stdout:r,stderr:i,exitCode:a}=await e.exec(n);if(a!==0){let e=i.trim()||`oauth-token exited with code ${a}`;throw Error(`skill.token('${t}'): ${e}`)}return r.replace(/\r?\n+$/,``)}return Object.freeze({dir:t,refs:n,assets:r,config:o,token:s})}function $(e){if(!e||e===`/`)return`/`;e.startsWith(`/`)||(e=`/`+e);let t=e.split(`/`),n=[];for(let e of t)e===``||e===`.`||(e===`..`?n.pop():n.push(e));return`/`+n.join(`/`)}function ia(e){let t=$(e);if(t===`/`)return`/`;let n=t.lastIndexOf(`/`);return n===0?`/`:t.slice(0,n)}function aa(e){return Object.assign(Error(`ENOENT: no such file or directory, '${e}'`),{code:`ENOENT`})}function oa(e){return Object.assign(Error(`ENOSYNC: file too large for sync access, '${e}' — use async readFile() instead`),{code:`ENOSYNC`})}function sa(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}var ca=class{tree=new Map;initialPaths=new Set;initialContent=new Map;initialIsDirectory=new Map;mkdtempCounter=0;touched=!1;constructor(e){this.loadSnapshot(e)}loadSnapshot(e){this.tree=new Map,this.initialPaths=new Set,this.initialContent=new Map,this.initialIsDirectory=new Map,this.tree.set(`/`,{content:new Uint8Array,isDirectory:!0}),this.initialPaths.add(`/`),this.initialIsDirectory.set(`/`,!0);for(let t of e.entries){let e=$(t.path);this.tree.set(e,{content:t.content,isDirectory:t.isDirectory,truncated:t.truncated}),this.initialPaths.add(e),this.initialIsDirectory.set(e,t.isDirectory),t.isDirectory||this.initialContent.set(e,t.content)}for(let t of e.entries){let e=ia($(t.path));for(;e!==`/`&&!this.tree.has(e);)this.tree.set(e,{content:new Uint8Array,isDirectory:!0}),this.initialPaths.add(e),this.initialIsDirectory.set(e,!0),e=ia(e)}}wasUsed(){return this.touched}applySnapshot(e){this.loadSnapshot(e)}applySnapshotPreservingMutations(e){let t=this.getMutations();this.loadSnapshot(e);for(let e of t.deleted){if(this.tree.get(e)?.isDirectory){let t=e===`/`?`/`:e+`/`;for(let n of Array.from(this.tree.keys()))n!==e&&n.startsWith(t)&&this.tree.delete(n)}this.tree.delete(e)}for(let e of t.created)this.ensureParentDirs(e.path),this.tree.set(e.path,{content:e.content,isDirectory:e.isDirectory});for(let e of t.modified)this.ensureParentDirs(e.path),this.tree.set(e.path,{content:e.content,isDirectory:!1})}resetBaseline(){this.initialPaths=new Set,this.initialContent=new Map,this.initialIsDirectory=new Map;for(let[e,t]of this.tree.entries())this.initialPaths.add(e),this.initialIsDirectory.set(e,t.isDirectory),t.isDirectory||this.initialContent.set(e,t.content)}ensureParentDirs(e){let t=ia(e);t!==`/`&&(this.tree.has(t)||this.mkdir(t,!0))}readFile(e){this.touched=!0;let t=$(e),n=this.tree.get(t);if(!n||n.isDirectory)throw aa(t);if(n.truncated)throw oa(t);return n.content}writeFile(e,t){this.touched=!0;let n=$(e);this.ensureParentDirs(n),this.tree.set(n,{content:t,isDirectory:!1})}exists(e){this.touched=!0;let t=$(e);return this.tree.has(t)}stat(e){this.touched=!0;let t=$(e),n=this.tree.get(t);if(!n)throw aa(t);return{isFile:!n.isDirectory,isDirectory:n.isDirectory,size:n.isDirectory?0:n.content.byteLength}}readdir(e){this.touched=!0;let t=$(e);if(!this.tree.get(t)?.isDirectory)throw aa(t);let n=t===`/`?`/`:t+`/`,r=new Set;for(let e of this.tree.keys()){if(e===t||e===`/`||!e.startsWith(n))continue;let i=e.slice(n.length).split(`/`)[0];i&&r.add(i)}return Array.from(r)}mkdir(e,t){this.touched=!0;let n=$(e);if(this.tree.has(n)){if(this.tree.get(n).isDirectory)return;throw Object.assign(Error(`EEXIST: file already exists, '${n}'`),{code:`EEXIST`})}let r=ia(n);if(r!==`/`&&!this.tree.has(r)){if(!t)throw aa(n);this.mkdir(r,!0)}this.tree.set(n,{content:new Uint8Array,isDirectory:!0})}rm(e,t){this.touched=!0;let n=$(e),r=this.tree.get(n);if(!r)throw aa(n);if(r.isDirectory){let e=n===`/`?`/`:n+`/`,r=Array.from(this.tree.keys()).filter(t=>t!==n&&t.startsWith(e));if(r.length>0&&!t)throw Object.assign(Error(`ENOTEMPTY: directory not empty, '${n}'`),{code:`ENOTEMPTY`});for(let e of r)this.tree.delete(e)}this.tree.delete(n)}copyFile(e,t){this.touched=!0;let n=$(e),r=this.tree.get(n);if(!r||r.isDirectory)throw aa(n);let i=$(t);this.ensureParentDirs(i),this.tree.set(i,{content:r.content.slice(),isDirectory:!1})}rename(e,t){this.touched=!0;let n=$(e),r=this.tree.get(n);if(!r)throw aa(n);let i=$(t);if(r.isDirectory){let e=n===`/`?`/`:n+`/`,t=Array.from(this.tree.keys()).filter(t=>t!==n&&t.startsWith(e));this.ensureParentDirs(i),this.tree.set(i,r),this.tree.delete(n);for(let e of t){let t=this.tree.get(e),r=i+e.slice(n.length);this.tree.set(r,t),this.tree.delete(e)}return}this.ensureParentDirs(i),this.tree.set(i,r),this.tree.delete(n)}unlink(e){this.touched=!0;let t=$(e),n=this.tree.get(t);if(!n)throw aa(t);if(n.isDirectory)throw Object.assign(Error(`EISDIR: illegal operation on a directory, unlink '${t}'`),{code:`EISDIR`});this.tree.delete(t)}mkdtemp(e){this.touched=!0;for(let t=0;t<100;t++){let t=`_${String(this.mkdtempCounter).padStart(6,`0`)}`;this.mkdtempCounter++;let n=$(e+t);if(!this.tree.has(n))return this.mkdir(n,!0),n}throw Error(`mkdtemp: failed to create unique directory after 100 attempts`)}getMutations(){let e=[],t=[],n=[];for(let[r,i]of this.tree.entries()){if(r===`/`)continue;if(!this.initialPaths.has(r)){e.push({path:r,content:i.content,isDirectory:i.isDirectory});continue}let a=this.initialIsDirectory.get(r);if(a!==void 0&&a!==i.isDirectory){n.push(r),e.push({path:r,content:i.content,isDirectory:i.isDirectory});continue}if(!i.isDirectory){let e=this.initialContent.get(r);e&&!sa(e,i.content)&&t.push({path:r,content:i.content})}}for(let e of this.initialPaths)e!==`/`&&(this.tree.has(e)||n.push(e));return{created:e,modified:t,deleted:n}}};function la(e){if(!e)return``;let t=e.lastIndexOf(`/`);return t<0?``:t===0?`/`:e.substring(0,t)}var ua=class extends Error{code;constructor(e){super(`Process exited with code ${e}`),this.code=e,this.name=`NodeExitError`}};function da(e){if(typeof e==`string`)return e;if(e==null)return String(e);try{return JSON.stringify(e)}catch{return String(e)}}async function fa(e,t){let n;try{n=await e.call(`vfs`,`snapshot`,[t])}catch{n={entries:[]}}return new ca(n)}function pa(e){return{usbBridge:ro(e),serialBridge:ao(e),hidBridge:so(e)}}async function ma(e,t){let n=[],r=[],i=e=>{n.push(typeof e==`string`?e:String(e))},a=e=>{r.push(typeof e==`string`?e:String(e))},o=_a(i,a),{processShim:s,getDidCallProcessExit:c}=va(e,i,a),l=!!e.env?.NO_COLOR,u=lr({isTTY:!l,noColor:l}),d=sr({writeStdout:i,writeStderr:a,exit:e=>{throw new ua(e)},color:u}),f=new Xi(t),p=Ea(f,w),h=await fa(f,e.cwd);Object.assign(p,Da(h,e.cwd));let g=ba(f,h,e.cwd),_=Ca(g,{cwd:e.cwd}),v=ra({argv:e.argv,fs:p,exec:g}),y=Va(f),{usbBridge:b,serialBridge:x,hidBridge:S}=pa(f),C=m({fetch:w});async function w(e,t){let n=e instanceof Request?e.url:e instanceof URL?e.toString():String(e),r=await f.call(`fetch`,`request`,[n,Ba(t,e)]),i=r.body.byteLength===0?null:r.body.buffer.slice(r.body.byteOffset,r.body.byteOffset+r.body.byteLength),a=new Response(i,{status:r.status,statusText:r.statusText,headers:r.headers});return Object.defineProperty(a,"url",{value:r.url||n}),a}let T=wa({exec:g,agent:_,skill:v,http:C,browser:y,usb:b,serial:x,hid:S,cli:d,color:u}),E=e.filename,D=la(E),O=await Aa(f,e.code,e.cwd,E),k=Na({graph:O,fsBridge:p,processShim:s,childProcess:Vi(g),nodeConsole:o,sliccyModules:T,shimmedPackages:Ma(f)}).require,A={exports:{},filename:e.filename},j=O.entrySource!==void 0,ee=O.entrySource??e.code,M=globalThis;M.__slicc_compileWasm=e=>f.call(`wasm`,`compile`,[e]);let te=await za(ee,{process:s,console:o,require:k,module:A,exports:A.exports,fetch:w,__dirname:D,__filename:E},a,j);await ha(f,h,a),c()||await ga(f),delete M.__slicc_compileWasm,f.dispose(),t.postMessage({type:`realm-done`,stdout:n.join(``),stderr:r.join(``),exitCode:te})}async function ha(e,t,n){let r=t.getMutations();if(r.created.length||r.modified.length||r.deleted.length)try{await e.call(`vfs`,`flushWrites`,[r])}catch(e){n(`[sync-fs] flush failed: ${e instanceof Error?e.message:String(e)}\n`)}}async function ga(e){let t=Date.now()+1e3,n=0;do await new Promise(e=>setTimeout(e,0)),n++;while(e.pendingCount>0&&n<50&&Date.now()<t)}function _a(e,t){return{log:(...t)=>e(`${t.map(da).join(` `)}
|
|
44
44
|
`),info:(...t)=>e(`${t.map(da).join(` `)}
|
|
45
45
|
`),warn:(...e)=>t(`${e.map(da).join(` `)}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{t as e}from"./rolldown-runtime-aKtaBQYM.js";var t=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.ALL=e.COLLECTION=e.ATOM=e.SPECIAL=e.INF=e._INFINITY=e.INFINITY=e.NAN=e.BOOL=e.NULL=e.OBJ=e.ARR=e.NUM=e.STR=void 0,e.STR=1,e.NUM=2,e.ARR=4,e.OBJ=8,e.NULL=16,e.BOOL=32,e.NAN=64,e.INFINITY=128,e._INFINITY=256,e.INF=e.INFINITY|e._INFINITY,e.SPECIAL=e.NULL|e.BOOL|e.INF|e.NAN,e.ATOM=e.STR|e.NUM|e.SPECIAL,e.COLLECTION=e.ARR|e.OBJ,e.ALL=e.ATOM|e.COLLECTION,e.Allow={STR:e.STR,NUM:e.NUM,ARR:e.ARR,OBJ:e.OBJ,NULL:e.NULL,BOOL:e.BOOL,NAN:e.NAN,INFINITY:e.INFINITY,_INFINITY:e._INFINITY,INF:e.INF,SPECIAL:e.SPECIAL,ATOM:e.ATOM,COLLECTION:e.COLLECTION,ALL:e.ALL},e.default=e.Allow})),n=e((e=>{var n=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),r=e&&e.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&n(t,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.MalformedJSON=e.PartialJSON=e.parseJSON=e.parse=void 0;let i=t();Object.defineProperty(e,"Allow",{enumerable:!0,get:function(){return i.Allow}}),r(t(),e);var a=class extends Error{};e.PartialJSON=a;var o=class extends Error{};e.MalformedJSON=o;function s(e,t=i.Allow.ALL){if(typeof e!=`string`)throw TypeError(`expecting str, got ${typeof e}`);if(!e.trim())throw Error(`${e} is empty`);return c(e.trim(),t)}e.parseJSON=s;let c=(e,t)=>{let n=e.length,r=0,s=e=>{throw new a(`${e} at position ${r}`)},c=e=>{throw new o(`${e} at position ${r}`)},l=()=>(m(),r>=n&&s(`Unexpected end of input`),e[r]===`"`?u():e[r]===`{`?d():e[r]===`[`?f():e.substring(r,r+4)===`null`||i.Allow.NULL&t&&n-r<4&&`null`.startsWith(e.substring(r))?(r+=4,null):e.substring(r,r+4)===`true`||i.Allow.BOOL&t&&n-r<4&&`true`.startsWith(e.substring(r))?(r+=4,!0):e.substring(r,r+5)===`false`||i.Allow.BOOL&t&&n-r<5&&`false`.startsWith(e.substring(r))?(r+=5,!1):e.substring(r,r+8)===`Infinity`||i.Allow.INFINITY&t&&n-r<8&&`Infinity`.startsWith(e.substring(r))?(r+=8,1/0):e.substring(r,r+9)===`-Infinity`||i.Allow._INFINITY&t&&1<n-r&&n-r<9&&`-Infinity`.startsWith(e.substring(r))?(r+=9,-1/0):e.substring(r,r+3)===`NaN`||i.Allow.NAN&t&&n-r<3&&`NaN`.startsWith(e.substring(r))?(r+=3,NaN):p()),u=()=>{let a=r,o=!1;for(r++;r<n&&(e[r]!==`"`||o&&e[r-1]===`\\`);)o=e[r]
|
|
1
|
+
import{t as e}from"./rolldown-runtime-aKtaBQYM.js";var t=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.ALL=e.COLLECTION=e.ATOM=e.SPECIAL=e.INF=e._INFINITY=e.INFINITY=e.NAN=e.BOOL=e.NULL=e.OBJ=e.ARR=e.NUM=e.STR=void 0,e.STR=1,e.NUM=2,e.ARR=4,e.OBJ=8,e.NULL=16,e.BOOL=32,e.NAN=64,e.INFINITY=128,e._INFINITY=256,e.INF=e.INFINITY|e._INFINITY,e.SPECIAL=e.NULL|e.BOOL|e.INF|e.NAN,e.ATOM=e.STR|e.NUM|e.SPECIAL,e.COLLECTION=e.ARR|e.OBJ,e.ALL=e.ATOM|e.COLLECTION,e.Allow={STR:e.STR,NUM:e.NUM,ARR:e.ARR,OBJ:e.OBJ,NULL:e.NULL,BOOL:e.BOOL,NAN:e.NAN,INFINITY:e.INFINITY,_INFINITY:e._INFINITY,INF:e.INF,SPECIAL:e.SPECIAL,ATOM:e.ATOM,COLLECTION:e.COLLECTION,ALL:e.ALL},e.default=e.Allow})),n=e((e=>{var n=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),r=e&&e.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&n(t,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.MalformedJSON=e.PartialJSON=e.parseJSON=e.parse=void 0;let i=t();Object.defineProperty(e,"Allow",{enumerable:!0,get:function(){return i.Allow}}),r(t(),e);var a=class extends Error{};e.PartialJSON=a;var o=class extends Error{};e.MalformedJSON=o;function s(e,t=i.Allow.ALL){if(typeof e!=`string`)throw TypeError(`expecting str, got ${typeof e}`);if(!e.trim())throw Error(`${e} is empty`);return c(e.trim(),t)}e.parseJSON=s;let c=(e,t)=>{let n=e.length,r=0,s=e=>{throw new a(`${e} at position ${r}`)},c=e=>{throw new o(`${e} at position ${r}`)},l=()=>(m(),r>=n&&s(`Unexpected end of input`),e[r]===`"`?u():e[r]===`{`?d():e[r]===`[`?f():e.substring(r,r+4)===`null`||i.Allow.NULL&t&&n-r<4&&`null`.startsWith(e.substring(r))?(r+=4,null):e.substring(r,r+4)===`true`||i.Allow.BOOL&t&&n-r<4&&`true`.startsWith(e.substring(r))?(r+=4,!0):e.substring(r,r+5)===`false`||i.Allow.BOOL&t&&n-r<5&&`false`.startsWith(e.substring(r))?(r+=5,!1):e.substring(r,r+8)===`Infinity`||i.Allow.INFINITY&t&&n-r<8&&`Infinity`.startsWith(e.substring(r))?(r+=8,1/0):e.substring(r,r+9)===`-Infinity`||i.Allow._INFINITY&t&&1<n-r&&n-r<9&&`-Infinity`.startsWith(e.substring(r))?(r+=9,-1/0):e.substring(r,r+3)===`NaN`||i.Allow.NAN&t&&n-r<3&&`NaN`.startsWith(e.substring(r))?(r+=3,NaN):p()),u=()=>{let a=r,o=!1;for(r++;r<n&&(e[r]!==`"`||o&&e[r-1]===`\\`);)o=e[r]===`\\`&&!o,r++;if(e.charAt(r)==`"`)try{return JSON.parse(e.substring(a,++r-Number(o)))}catch(e){c(String(e))}else if(i.Allow.STR&t)try{return JSON.parse(e.substring(a,r-Number(o))+`"`)}catch{return JSON.parse(e.substring(a,e.lastIndexOf(`\\`))+`"`)}s(`Unterminated string literal`)},d=()=>{r++,m();let a={};try{for(;e[r]!==`}`;){if(m(),r>=n&&i.Allow.OBJ&t)return a;let o=u();m(),r++;try{a[o]=l()}catch(e){if(i.Allow.OBJ&t)return a;throw e}m(),e[r]===`,`&&r++}}catch{if(i.Allow.OBJ&t)return a;s(`Expected '}' at end of object`)}return r++,a},f=()=>{r++;let n=[];try{for(;e[r]!==`]`;)n.push(l()),m(),e[r]===`,`&&r++}catch{if(i.Allow.ARR&t)return n;s(`Expected ']' at end of array`)}return r++,n},p=()=>{if(r===0){e===`-`&&c(`Not sure what '-' is`);try{return JSON.parse(e)}catch(n){if(i.Allow.NUM&t)try{return JSON.parse(e.substring(0,e.lastIndexOf(`e`)))}catch{}c(String(n))}}let a=r;for(e[r]===`-`&&r++;e[r]&&`,]}`.indexOf(e[r])===-1;)r++;r==n&&!(i.Allow.NUM&t)&&s(`Unterminated number literal`);try{return JSON.parse(e.substring(a,r))}catch{e.substring(a,r)===`-`&&s(`Not sure what '-' is`);try{return JSON.parse(e.substring(a,e.lastIndexOf(`e`)))}catch(e){c(String(e))}}},m=()=>{for(;r<n&&`
|
|
2
2
|
\r `.includes(e[r]);)r++};return l()};e.parse=s}))();const r=new Set([`"`,`\\`,`/`,`b`,`f`,`n`,`r`,`t`,`u`]);function i(e){let t=e.codePointAt(0);return t!==void 0&&t>=0&&t<=31}function a(e){switch(e){case`\b`:return`\\b`;case`\f`:return`\\f`;case`
|
|
3
3
|
`:return`\\n`;case`\r`:return`\\r`;case` `:return`\\t`;default:return`\\u${e.codePointAt(0)?.toString(16).padStart(4,`0`)??`0000`}`}}function o(e){let t=``,n=!1;for(let o=0;o<e.length;o++){let s=e[o];if(!n){t+=s,s===`"`&&(n=!0);continue}if(s===`"`){t+=s,n=!1;continue}if(s===`\\`){let n=e[o+1];if(n===void 0){t+=`\\\\`;continue}if(n===`u`){let n=e.slice(o+2,o+6);if(/^[0-9a-fA-F]{4}$/.test(n)){t+=`\\u${n}`,o+=5;continue}}if(r.has(n)){t+=`\\${n}`,o+=1;continue}t+=`\\\\`;continue}t+=i(s)?a(s):s}return t}function s(e){try{return JSON.parse(e)}catch(t){let n=o(e);if(n!==e)return JSON.parse(n);throw t}}function c(e){if(!e||e.trim()===``)return{};try{return s(e)}catch{try{return(0,n.parse)(e)??{}}catch{try{return(0,n.parse)(o(e))??{}}catch{return{}}}}}export{c as n,s as t};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{t as e}from"./rolldown-runtime-aKtaBQYM.js";var t=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.ALL=e.COLLECTION=e.ATOM=e.SPECIAL=e.INF=e._INFINITY=e.INFINITY=e.NAN=e.BOOL=e.NULL=e.OBJ=e.ARR=e.NUM=e.STR=void 0,e.STR=1,e.NUM=2,e.ARR=4,e.OBJ=8,e.NULL=16,e.BOOL=32,e.NAN=64,e.INFINITY=128,e._INFINITY=256,e.INF=e.INFINITY|e._INFINITY,e.SPECIAL=e.NULL|e.BOOL|e.INF|e.NAN,e.ATOM=e.STR|e.NUM|e.SPECIAL,e.COLLECTION=e.ARR|e.OBJ,e.ALL=e.ATOM|e.COLLECTION,e.Allow={STR:e.STR,NUM:e.NUM,ARR:e.ARR,OBJ:e.OBJ,NULL:e.NULL,BOOL:e.BOOL,NAN:e.NAN,INFINITY:e.INFINITY,_INFINITY:e._INFINITY,INF:e.INF,SPECIAL:e.SPECIAL,ATOM:e.ATOM,COLLECTION:e.COLLECTION,ALL:e.ALL},e.default=e.Allow})),n=e((e=>{var n=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),r=e&&e.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&n(t,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.MalformedJSON=e.PartialJSON=e.parseJSON=e.parse=void 0;var i=t();Object.defineProperty(e,"Allow",{enumerable:!0,get:function(){return i.Allow}}),r(t(),e);var a=class extends Error{};e.PartialJSON=a;var o=class extends Error{};e.MalformedJSON=o;function s(e,t=i.Allow.ALL){if(typeof e!=`string`)throw TypeError(`expecting str, got ${typeof e}`);if(!e.trim())throw Error(`${e} is empty`);return c(e.trim(),t)}e.parseJSON=s;var c=(e,t)=>{let n=e.length,r=0,s=e=>{throw new a(`${e} at position ${r}`)},c=e=>{throw new o(`${e} at position ${r}`)},l=()=>(m(),r>=n&&s(`Unexpected end of input`),e[r]===`"`?u():e[r]===`{`?d():e[r]===`[`?f():e.substring(r,r+4)===`null`||i.Allow.NULL&t&&n-r<4&&`null`.startsWith(e.substring(r))?(r+=4,null):e.substring(r,r+4)===`true`||i.Allow.BOOL&t&&n-r<4&&`true`.startsWith(e.substring(r))?(r+=4,!0):e.substring(r,r+5)===`false`||i.Allow.BOOL&t&&n-r<5&&`false`.startsWith(e.substring(r))?(r+=5,!1):e.substring(r,r+8)===`Infinity`||i.Allow.INFINITY&t&&n-r<8&&`Infinity`.startsWith(e.substring(r))?(r+=8,1/0):e.substring(r,r+9)===`-Infinity`||i.Allow._INFINITY&t&&1<n-r&&n-r<9&&`-Infinity`.startsWith(e.substring(r))?(r+=9,-1/0):e.substring(r,r+3)===`NaN`||i.Allow.NAN&t&&n-r<3&&`NaN`.startsWith(e.substring(r))?(r+=3,NaN):p()),u=()=>{let a=r,o=!1;for(r++;r<n&&(e[r]!==`"`||o&&e[r-1]===`\\`);)o=e[r]
|
|
1
|
+
import{t as e}from"./rolldown-runtime-aKtaBQYM.js";var t=e((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.ALL=e.COLLECTION=e.ATOM=e.SPECIAL=e.INF=e._INFINITY=e.INFINITY=e.NAN=e.BOOL=e.NULL=e.OBJ=e.ARR=e.NUM=e.STR=void 0,e.STR=1,e.NUM=2,e.ARR=4,e.OBJ=8,e.NULL=16,e.BOOL=32,e.NAN=64,e.INFINITY=128,e._INFINITY=256,e.INF=e.INFINITY|e._INFINITY,e.SPECIAL=e.NULL|e.BOOL|e.INF|e.NAN,e.ATOM=e.STR|e.NUM|e.SPECIAL,e.COLLECTION=e.ARR|e.OBJ,e.ALL=e.ATOM|e.COLLECTION,e.Allow={STR:e.STR,NUM:e.NUM,ARR:e.ARR,OBJ:e.OBJ,NULL:e.NULL,BOOL:e.BOOL,NAN:e.NAN,INFINITY:e.INFINITY,_INFINITY:e._INFINITY,INF:e.INF,SPECIAL:e.SPECIAL,ATOM:e.ATOM,COLLECTION:e.COLLECTION,ALL:e.ALL},e.default=e.Allow})),n=e((e=>{var n=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),r=e&&e.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&n(t,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.Allow=e.MalformedJSON=e.PartialJSON=e.parseJSON=e.parse=void 0;var i=t();Object.defineProperty(e,"Allow",{enumerable:!0,get:function(){return i.Allow}}),r(t(),e);var a=class extends Error{};e.PartialJSON=a;var o=class extends Error{};e.MalformedJSON=o;function s(e,t=i.Allow.ALL){if(typeof e!=`string`)throw TypeError(`expecting str, got ${typeof e}`);if(!e.trim())throw Error(`${e} is empty`);return c(e.trim(),t)}e.parseJSON=s;var c=(e,t)=>{let n=e.length,r=0,s=e=>{throw new a(`${e} at position ${r}`)},c=e=>{throw new o(`${e} at position ${r}`)},l=()=>(m(),r>=n&&s(`Unexpected end of input`),e[r]===`"`?u():e[r]===`{`?d():e[r]===`[`?f():e.substring(r,r+4)===`null`||i.Allow.NULL&t&&n-r<4&&`null`.startsWith(e.substring(r))?(r+=4,null):e.substring(r,r+4)===`true`||i.Allow.BOOL&t&&n-r<4&&`true`.startsWith(e.substring(r))?(r+=4,!0):e.substring(r,r+5)===`false`||i.Allow.BOOL&t&&n-r<5&&`false`.startsWith(e.substring(r))?(r+=5,!1):e.substring(r,r+8)===`Infinity`||i.Allow.INFINITY&t&&n-r<8&&`Infinity`.startsWith(e.substring(r))?(r+=8,1/0):e.substring(r,r+9)===`-Infinity`||i.Allow._INFINITY&t&&1<n-r&&n-r<9&&`-Infinity`.startsWith(e.substring(r))?(r+=9,-1/0):e.substring(r,r+3)===`NaN`||i.Allow.NAN&t&&n-r<3&&`NaN`.startsWith(e.substring(r))?(r+=3,NaN):p()),u=()=>{let a=r,o=!1;for(r++;r<n&&(e[r]!==`"`||o&&e[r-1]===`\\`);)o=e[r]===`\\`&&!o,r++;if(e.charAt(r)==`"`)try{return JSON.parse(e.substring(a,++r-Number(o)))}catch(e){c(String(e))}else if(i.Allow.STR&t)try{return JSON.parse(e.substring(a,r-Number(o))+`"`)}catch{return JSON.parse(e.substring(a,e.lastIndexOf(`\\`))+`"`)}s(`Unterminated string literal`)},d=()=>{r++,m();let a={};try{for(;e[r]!==`}`;){if(m(),r>=n&&i.Allow.OBJ&t)return a;let o=u();m(),r++;try{a[o]=l()}catch(e){if(i.Allow.OBJ&t)return a;throw e}m(),e[r]===`,`&&r++}}catch{if(i.Allow.OBJ&t)return a;s(`Expected '}' at end of object`)}return r++,a},f=()=>{r++;let n=[];try{for(;e[r]!==`]`;)n.push(l()),m(),e[r]===`,`&&r++}catch{if(i.Allow.ARR&t)return n;s(`Expected ']' at end of array`)}return r++,n},p=()=>{if(r===0){e===`-`&&c(`Not sure what '-' is`);try{return JSON.parse(e)}catch(n){if(i.Allow.NUM&t)try{return JSON.parse(e.substring(0,e.lastIndexOf(`e`)))}catch{}c(String(n))}}let a=r;for(e[r]===`-`&&r++;e[r]&&`,]}`.indexOf(e[r])===-1;)r++;r==n&&!(i.Allow.NUM&t)&&s(`Unterminated number literal`);try{return JSON.parse(e.substring(a,r))}catch{e.substring(a,r)===`-`&&s(`Not sure what '-' is`);try{return JSON.parse(e.substring(a,e.lastIndexOf(`e`)))}catch(e){c(String(e))}}},m=()=>{for(;r<n&&`
|
|
2
2
|
\r `.includes(e[r]);)r++};return l()};e.parse=s}))(),r=new Set([`"`,`\\`,`/`,`b`,`f`,`n`,`r`,`t`,`u`]);function i(e){let t=e.codePointAt(0);return t!==void 0&&t>=0&&t<=31}function a(e){switch(e){case`\b`:return`\\b`;case`\f`:return`\\f`;case`
|
|
3
3
|
`:return`\\n`;case`\r`:return`\\r`;case` `:return`\\t`;default:return`\\u${e.codePointAt(0)?.toString(16).padStart(4,`0`)??`0000`}`}}function o(e){let t=``,n=!1;for(let o=0;o<e.length;o++){let s=e[o];if(!n){t+=s,s===`"`&&(n=!0);continue}if(s===`"`){t+=s,n=!1;continue}if(s===`\\`){let n=e[o+1];if(n===void 0){t+=`\\\\`;continue}if(n===`u`){let n=e.slice(o+2,o+6);if(/^[0-9a-fA-F]{4}$/.test(n)){t+=`\\u${n}`,o+=5;continue}}if(r.has(n)){t+=`\\${n}`,o+=1;continue}t+=`\\\\`;continue}t+=i(s)?a(s):s}return t}function s(e){try{return JSON.parse(e)}catch(t){let n=o(e);if(n!==e)return JSON.parse(n);throw t}}function c(e){if(!e||e.trim()===``)return{};try{return s(e)}catch{try{return(0,n.parse)(e)??{}}catch{try{return(0,n.parse)(o(e))??{}}catch{return{}}}}}export{c as n,s as t};
|