@abtnode/blocklet-services 1.16.47-beta-20250805-095401-14eb156b → 1.16.47-beta-20250807-110715-19ad6b43
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/api/index.js +2 -1
- package/api/libs/connect/v1.js +1 -1
- package/api/libs/env.js +1 -1
- package/api/routes/access-key.js +7 -1
- package/api/routes/csp-proxy.js +2 -2
- package/api/routes/user.js +31 -6
- package/dist/assets/{AdapterDayjs-D8zlc0TS.js → AdapterDayjs-OwV8ZfRo.js} +1 -1
- package/dist/assets/{Google-DxcTyhFe.js → Google-B5khWV-G.js} +1 -1
- package/dist/assets/{access-control-jFR93SsS.js → access-control-C9JoF-VW.js} +1 -1
- package/dist/assets/{actions-B0rWiAuM.js → actions-DiUxQ792.js} +1 -1
- package/dist/assets/{add-component-core-DfrJCl4a.js → add-component-core-DbPZIJoa.js} +39 -39
- package/dist/assets/add-resource-D0yHahVH.js +1 -0
- package/dist/assets/{addon-B-vtdIPn.js → addon-S-x2oOBW.js} +1 -1
- package/dist/assets/{advanced-B92lyz70.js → advanced-Brdzd_hV.js} +1 -1
- package/dist/assets/aigne-CEwSzcja.js +10 -0
- package/dist/assets/aistro-NLUOUWwT.png +0 -0
- package/dist/assets/{appearance-C1k2L_bA.js → appearance-Dptvfp0O.js} +1 -1
- package/dist/assets/ar-BCTLRONQ.js +1 -0
- package/dist/assets/{ar-DDlrXmSt.js → ar-qovKpPcU.js} +1 -1
- package/dist/assets/{arrow-down.svg-BnKvb8st.js → arrow-down.svg-mrRaEeKB.js} +1 -1
- package/dist/assets/{audit-logs-OO0l4GnY.js → audit-logs-FBpDejHE.js} +1 -1
- package/dist/assets/{authorize-BU6KP5W6.js → authorize-BeJTPWjw.js} +1 -1
- package/dist/assets/{base-chart-B1XQ7Ytj.js → base-chart-BR64ujqk.js} +1 -1
- package/dist/assets/{base32-BeRPpTcK.js → base32-Dq34Xpru.js} +1 -1
- package/dist/assets/{branding-D1JmhF3p.js → branding-BX3gHZjy.js} +2 -2
- package/dist/assets/{branding-CEu-c8uQ.js → branding-D1DQzFQg.js} +1 -1
- package/dist/assets/{bundle-avatar-BZQ_lZxy.js → bundle-avatar-B6WDP8U8.js} +1 -1
- package/dist/assets/button-BGOqx4KL.js +1 -0
- package/dist/assets/{click-to-copy-EOhAhdSS.js → click-to-copy-Lt7iNH-g.js} +1 -1
- package/dist/assets/{collapse-wumRocfe.js → collapse-tY1N2fk5.js} +1 -1
- package/dist/assets/{complete-DwaBuF4K.js → complete-QPs88Xvq.js} +1 -1
- package/dist/assets/{component-D31UJpJQ.js → component-IvlOow7w.js} +3 -3
- package/dist/assets/{config-Df0dxvZZ.js → config-BV13SrRs.js} +1 -1
- package/dist/assets/config-ZidMeHMX.js +53 -0
- package/dist/assets/{config-AgncsJiw.js → config-gRz3hnHQ.js} +1 -1
- package/dist/assets/{config-navigation-JJehoQAV.js → config-navigation--k3uzAVY.js} +3 -3
- package/dist/assets/{config-space-CrH2JnlQ.js → config-space-DmPAo0Uc.js} +1 -1
- package/dist/assets/{confirm-Cx2owMMo.js → confirm-DwicyBRo.js} +1 -1
- package/dist/assets/{connect-C7C7ILA6.js → connect-CCyhtcsX.js} +1 -1
- package/dist/assets/{connect-BD9OoHaD.js → connect-CXYynAHv.js} +1 -1
- package/dist/assets/{connect-to-nCPxtJH1.js → connect-to-duHzVFsc.js} +1 -1
- package/dist/assets/{content-layout-BZKNdb6s.js → content-layout-D5EfCmvE.js} +1 -1
- package/dist/assets/{createClass-BTaIsrxM.js → createClass-Cy-fAHUw.js} +1 -1
- package/dist/assets/{dashboard-CDjptZox.js → dashboard-DTH5SkDE.js} +3 -3
- package/dist/assets/{de-DSALrqI8.js → de-BrVlvg8I.js} +1 -1
- package/dist/assets/de-Bxv5hOpH.js +1 -0
- package/dist/assets/{delete-confirm-Wa3xVOUM.js → delete-confirm-Bn607XWd.js} +1 -1
- package/dist/assets/{did-address-C7IHZs6x.js → did-address-BYpODbk4.js} +1 -1
- package/dist/assets/{domain-DV7cdOEy.js → domain-D0AJ_QKJ.js} +1 -1
- package/dist/assets/{domain-action-card-CnvZTstr.js → domain-action-card-DIdC2BX8.js} +1 -1
- package/dist/assets/domains-BnUGWOh5.js +1 -0
- package/dist/assets/{dot-CE8yAFCN.js → dot-3RzyGk21.js} +1 -1
- package/dist/assets/{email-DQnz-4Bc.js → email-DSvOsQV4.js} +1 -1
- package/dist/assets/{empty-spinner-DCdg-gxP.js → empty-spinner-DXNgsKH2.js} +1 -1
- package/dist/assets/engine-DwJQ8ndb.js +1 -0
- package/dist/assets/es-CJASnE29.js +1 -0
- package/dist/assets/{es-DQvY5fGr.js → es-CWdREjkO.js} +1 -1
- package/dist/assets/{exchange-passport-D9HZFZwF.js → exchange-passport-Duueo_OR.js} +1 -1
- package/dist/assets/{form-D52FUB8q.js → form-DJLzfDke.js} +1 -1
- package/dist/assets/{form-text-input-DanXI___.js → form-text-input-BWWenIQu.js} +1 -1
- package/dist/assets/{form-wrapper-DgFURo9t.js → form-wrapper-RaRgkgkH.js} +1 -1
- package/dist/assets/{fr-BgvhEJ06.js → fr-CfM2gAY_.js} +1 -1
- package/dist/assets/fr-GN7UO4qD.js +1 -0
- package/dist/assets/{fuel-DEa3ECY8.js → fuel-BxPebmaf.js} +1 -1
- package/dist/assets/gen-access-key-C8QyyPtS.js +1 -0
- package/dist/assets/gen-simple-access-key-CGRxC9aD.js +1 -0
- package/dist/assets/get-safe-url-Byu99Iq6.js +1 -0
- package/dist/assets/hi-B6hnXdBn.js +5 -0
- package/dist/assets/hi-DWiwUAYV.js +1 -0
- package/dist/assets/{home-B7OWEVsn.js → home-D1KsByvB.js} +1 -1
- package/dist/assets/{id-DfDk8Cxy.js → id-BfAVuWhm.js} +1 -1
- package/dist/assets/id-SWQ4mJGx.js +1 -0
- package/dist/assets/{iframe-CqwYISrF.js → iframe-2AxKOYBR.js} +1 -1
- package/dist/assets/{index-296hnpGF.js → index-0DKBOdj7.js} +1 -1
- package/dist/assets/index-4wrVz6i1.js +124 -0
- package/dist/assets/{index-ChbREcnK.js → index-7UPsmpeB.js} +1 -1
- package/dist/assets/{index-BFOTYlfC.js → index-7Wt3WOLU.js} +1 -1
- package/dist/assets/{index-B0GLaTiX.js → index-8djlz-MG.js} +1 -1
- package/dist/assets/{index-DlaHLSvf.js → index-B2HJDbWz.js} +19 -19
- package/dist/assets/{index-C4hly8RC.js → index-BAYFdR7m.js} +1 -1
- package/dist/assets/{index-uY6moYTs.js → index-BDSe7HLW.js} +1 -1
- package/dist/assets/{index-BEmLxB7B.js → index-Br7EG_jz.js} +1 -1
- package/dist/assets/{index-diQW5vdJ.js → index-BsHHb1rN.js} +1 -1
- package/dist/assets/{index-Nd6gD7eY.js → index-CMhFwlvk.js} +1 -1
- package/dist/assets/{index-CKesQXQW.js → index-CTM6wiOX.js} +1 -1
- package/dist/assets/{index-Dj0TETp9.js → index-CgCVx1sf.js} +12 -12
- package/dist/assets/{index-Cylfu8Kg.js → index-CniiyWPl.js} +14 -14
- package/dist/assets/{index-AK4Fi3I2.js → index-Cp_r7DvZ.js} +1 -1
- package/dist/assets/{index-Yow2d7gN.js → index-Cw89V6wx.js} +1 -1
- package/dist/assets/{index-BetmKk0p.js → index-Cy8O6s0C.js} +1 -1
- package/dist/assets/index-D05HWeh6.js +1 -0
- package/dist/assets/{index-CiL_9BYm.js → index-DFmxGkG9.js} +12 -12
- package/dist/assets/{index-CiW-jlCS.js → index-DKLDL0NU.js} +1 -1
- package/dist/assets/{index-B-k9otcQ.js → index-DLvW-hX6.js} +1 -1
- package/dist/assets/{index-BDu1k7Fv.js → index-DSSx9Ohc.js} +1 -1
- package/dist/assets/{index-BBIMESWU.js → index-DU79Hpz9.js} +1 -1
- package/dist/assets/{index-Bbcgo0GF.js → index-DgGkR58E.js} +1 -1
- package/dist/assets/{index-LdkiJabL.js → index-Dmil4V_-.js} +1 -1
- package/dist/assets/{index-DtuUsb1T.js → index-DtYei0B0.js} +2 -1
- package/dist/assets/{index-78a5Cdpe.js → index-GRZ8tMAV.js} +1 -1
- package/dist/assets/{index-C0mn0MnL.js → index-Mu2Sji0B.js} +1 -1
- package/dist/assets/{index-DSNvDaKK.js → index-dytlEEOb.js} +1 -1
- package/dist/assets/{index-B4OZ6pVW.js → index-khjK2Z9N.js} +1 -1
- package/dist/assets/{index-Cbf4geph.js → index-l5234Nwn.js} +123 -122
- package/dist/assets/{invitation-D8IFGbTf.js → invitation-BiM8UWsv.js} +1 -1
- package/dist/assets/{invite-bBNbkUJu.js → invite-CAmhHCq3.js} +1 -1
- package/dist/assets/{isURL-By2TdRfN.js → isURL-DA2-tMLY.js} +1 -1
- package/dist/assets/{issue-passport-DaQDVQ7Y.js → issue-passport-BlDK-yh8.js} +1 -1
- package/dist/assets/item-Deax8Tcs.js +1 -0
- package/dist/assets/{ja-GXo4l4Hp.js → ja-616mK6Bu.js} +1 -1
- package/dist/assets/ja-CUi7rI9p.js +1 -0
- package/dist/assets/ko-Bx9B8tBH.js +1 -0
- package/dist/assets/{ko-1dMP3P8A.js → ko-CoUjs_Gj.js} +1 -1
- package/dist/assets/{landing-page-k9p91AEv.js → landing-page-BJTNr6j1.js} +1 -1
- package/dist/assets/{launch-result-message-BTMFIbUm.js → launch-result-message-BklGSk6L.js} +1 -1
- package/dist/assets/{layout-zg5WZEdp.js → layout-B_66AMXX.js} +1 -1
- package/dist/assets/{list-C6CNPBAR.js → list-XQkJnArQ.js} +1 -1
- package/dist/assets/{list-header-B8ZTLjYf.js → list-header-BnA6XPP6.js} +1 -1
- package/dist/assets/{list-CYJEZSon.js → list-uh5difGn.js} +2 -2
- package/dist/assets/localization-DrnuLXG0.js +1 -0
- package/dist/assets/{log-ssfC90VX.js → log-22OBDAZV.js} +1 -1
- package/dist/assets/logger-Dth79fFL.js +1 -0
- package/dist/assets/{login-aFsf6-QM.js → login-6f9xq_uw.js} +1 -1
- package/dist/assets/{login-oauth-callback-dKBg8IoH.js → login-oauth-callback-mHVhjuxd.js} +1 -1
- package/dist/assets/{logo-uploader-D0Gz6YoY.js → logo-uploader-3Gf22QS4.js} +2 -2
- package/dist/assets/{lost-passport-Bo6am6th.js → lost-passport-BIYbG7oY.js} +1 -1
- package/dist/assets/{observability-Cfy3MVZa.js → observability-CFK-gQFz.js} +1 -1
- package/dist/assets/{open-window-DBhAlL9B.js → open-window-nJnt1xUe.js} +1 -1
- package/dist/assets/{over-due-invoice-payment-D89GCKNm.js → over-due-invoice-payment-D1hhqrpZ.js} +1 -1
- package/dist/assets/{overview-Xs3x6yXg.js → overview-DGSAxk-A.js} +1 -1
- package/dist/assets/{page-header-18voA300.js → page-header-Fuppayrb.js} +1 -1
- package/dist/assets/{passport-item-D-B7gJms.js → passport-item-4tKOyK2N.js} +1 -1
- package/dist/assets/{permission-DqaOkW_Z.js → permission-CzDQ8THQ.js} +1 -1
- package/dist/assets/{playground-CC7NZ-_A.js → playground-BNACWW4o.js} +1 -1
- package/dist/assets/preferences-CaRaLLOf.js +1 -0
- package/dist/assets/profile-embed-B295K6Uq.js +1 -0
- package/dist/assets/pt-BPWMiPVo.js +1 -0
- package/dist/assets/pt-BjllWaWg.js +5 -0
- package/dist/assets/publish-resource-Bhl_UV8t.js +1 -0
- package/dist/assets/{react-beautiful-dnd.esm-DkLcR42r.js → react-beautiful-dnd.esm-DOptRWpa.js} +1 -1
- package/dist/assets/{react-stripe.esm-BqogJv7y.js → react-stripe.esm-XKR9U0Pi.js} +1 -1
- package/dist/assets/{required-Df9AZf0R.js → required-DyRlNY7J.js} +1 -1
- package/dist/assets/ru-XKA9Zu_7.js +5 -0
- package/dist/assets/ru-aN6KKhQS.js +1 -0
- package/dist/assets/{runtime-DjILMoeT.js → runtime-bUnoJYpr.js} +1 -1
- package/dist/assets/{sanitize-BSjwjSMl.js → sanitize-Bu5pIC-A.js} +2 -2
- package/dist/assets/sdk-CiMbVjwj.js +1 -0
- package/dist/assets/{section-X04H4Q-a.js → section-D6477Ce1.js} +2 -1
- package/dist/assets/{security-BXhgiheS.js → security-DO4dtLin.js} +1 -1
- package/dist/assets/{session-89Q1nGxB.js → session-YnDvY5CJ.js} +1 -1
- package/dist/assets/setup-DigmKGGp.js +30 -0
- package/dist/assets/{shorten-label-CdBn9U0H.js → shorten-label-Bj776ixm.js} +1 -1
- package/dist/assets/{simple-select-BkbgqOQi.js → simple-select-BDbQa-9S.js} +1 -1
- package/dist/assets/{spaces-BJeg7L1z.js → spaces-KdeOps1v.js} +1 -1
- package/dist/assets/{start-CLueiUKJ.js → start-h8SswMC5.js} +1 -1
- package/dist/assets/{starting-progress-DWesZE5w.js → starting-progress-BjFMTtUQ.js} +1 -1
- package/dist/assets/{status-DheLJdlM.js → status-E4FMnQqN.js} +1 -1
- package/dist/assets/{step-actions-DmraEWCH.js → step-actions-GaXwswph.js} +1 -1
- package/dist/assets/studio-CgXu1gEM.js +6 -0
- package/dist/assets/{switch-control-BbRt1rRM.js → switch-control-CkW4eeJ4.js} +1 -1
- package/dist/assets/{table-tips-73VcKMz1.js → table-tips-LM2ip4Rj.js} +1 -1
- package/dist/assets/{team-ZJuYy81P.js → team-DjZ9qE6U.js} +1 -1
- package/dist/assets/th-CFlSwxxc.js +1 -0
- package/dist/assets/th-C_39WNhc.js +5 -0
- package/dist/assets/{traffic-CMI1Sbrr.js → traffic-CW6sZXQr.js} +1 -1
- package/dist/assets/{transfer-CW4yMg3K.js → transfer-BUR6hEv2.js} +1 -1
- package/dist/assets/{unsubscribe-D3ZXIJIb.js → unsubscribe-Dfzg-bws.js} +1 -1
- package/dist/assets/{use-mobile-BDciCFXT.js → use-mobile-CO13Oymt.js} +1 -1
- package/dist/assets/{use-mobile-BlpLWscF.js → use-mobile-CzqOrBZu.js} +1 -1
- package/dist/assets/{use-server-logo-lZp3Hq92.js → use-server-logo-Bs73VID2.js} +1 -1
- package/dist/assets/{use-window-close-wo9PxrTe.js → use-window-close-Cvx_le30.js} +1 -1
- package/dist/assets/{useLocalStorage-B_thopuV.js → useLocalStorage-phc-OA98.js} +1 -1
- package/dist/assets/{user-center-D6gs6-WZ.js → user-center-DjDTKFEf.js} +3 -3
- package/dist/assets/{user-sessions-B56a-4tA.js → user-sessions-D3Rr-i1p.js} +1 -1
- package/dist/assets/{util-Dcj6HCP7.js → util-Bn2B0xma.js} +1 -1
- package/dist/assets/{util-DQF9oPrf.js → util-majSFCTY.js} +1 -1
- package/dist/assets/{vendor-arcblock--zSibe1w.js → vendor-arcblock-DU4xNzGM.js} +1 -1
- package/dist/assets/{vendor-mui-core-BOHKtf8y.js → vendor-mui-core-CAIaAq-_.js} +2 -2
- package/dist/assets/{vendor-mui-x-16EG-AFj.js → vendor-mui-x-DXh6Gdva.js} +1 -1
- package/dist/assets/{vendor-ux-Cra9XTth.js → vendor-ux-C1NY8cuW.js} +3 -3
- package/dist/assets/vi-B8pz6rul.js +5 -0
- package/dist/assets/vi-DnVHbPxD.js +1 -0
- package/dist/assets/wait-connect-DpAcPy2e.js +1 -0
- package/dist/assets/wrap-locale-DwZj0kLA.js +1 -0
- package/dist/assets/zh-CFHHHyA4.js +1 -0
- package/dist/assets/{zh-DxCg9Pae.js → zh-DEpjANkc.js} +1 -1
- package/dist/assets/{zh-BoO0jdid.js → zh-Dr_3RhGJ.js} +1 -1
- package/dist/assets/zh-tw-DEjVZpn9.js +1 -0
- package/dist/assets/{zh-tw-D4_7lUjD.js → zh-tw-DK_EuRfN.js} +1 -1
- package/dist/index.html +4 -4
- package/dist/service-worker.js +1 -1
- package/package.json +46 -46
- package/dist/assets/add-resource-Ch4SZAWK.js +0 -1
- package/dist/assets/aigne-BDdYezR9.js +0 -10
- package/dist/assets/ar-cWkdH-wM.js +0 -1
- package/dist/assets/button-VEuIVOxr.js +0 -1
- package/dist/assets/config-C6pSSzan.js +0 -46
- package/dist/assets/de-CKHR0Dxi.js +0 -1
- package/dist/assets/domains-BpVmxPqY.js +0 -1
- package/dist/assets/empty-DhZfJeme.js +0 -1
- package/dist/assets/engine-BD3-KjxK.js +0 -1
- package/dist/assets/es-2tKCVVW6.js +0 -1
- package/dist/assets/fr-C2hgGsGq.js +0 -1
- package/dist/assets/gen-access-key-DrTcGDFb.js +0 -1
- package/dist/assets/gen-simple-access-key-DiDRmpFf.js +0 -1
- package/dist/assets/get-safe-url-DOmcOTEp.js +0 -1
- package/dist/assets/hi-DLl5_Grb.js +0 -1
- package/dist/assets/hi-DtMqBGN3.js +0 -5
- package/dist/assets/id-BEDDZnYa.js +0 -1
- package/dist/assets/index-AbdeuSeu.js +0 -124
- package/dist/assets/index-B-WiXXyt.js +0 -1
- package/dist/assets/item-BhrhnieT.js +0 -1
- package/dist/assets/ja-BXpHGJqS.js +0 -1
- package/dist/assets/ko-CwVxJk3S.js +0 -1
- package/dist/assets/localization-DFWXvHpl.js +0 -1
- package/dist/assets/logger-D5kKPkv7.js +0 -1
- package/dist/assets/preferences-5iBfUn8N.js +0 -1
- package/dist/assets/profile-embed-MOxF7ggV.js +0 -1
- package/dist/assets/pt-5iS1WU13.js +0 -5
- package/dist/assets/pt-DM9_sWXT.js +0 -1
- package/dist/assets/publish-resource-BBnSOgDd.js +0 -1
- package/dist/assets/ru-DpIRvFxj.js +0 -5
- package/dist/assets/ru-DvP9XKXg.js +0 -1
- package/dist/assets/sdk-B-MwbsI_.js +0 -1
- package/dist/assets/setup-Da3ReRWd.js +0 -30
- package/dist/assets/studio-C4flChud.js +0 -6
- package/dist/assets/th-BjX3AJzF.js +0 -5
- package/dist/assets/th-DyGOy3ap.js +0 -1
- package/dist/assets/use-promise-window-open-u0untujg.js +0 -1
- package/dist/assets/vi-0Dtw7069.js +0 -5
- package/dist/assets/vi-BWy1Jg4e.js +0 -1
- package/dist/assets/wait-connect-CqwL_aoj.js +0 -1
- package/dist/assets/wrap-locale-DAzAra4f.js +0 -1
- package/dist/assets/zh-D_lJZbI3.js +0 -1
- package/dist/assets/zh-tw-CfWhHTHL.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{J as A,j as e,ak as t,a6 as E,Q as l,b3 as I,T as o,b4 as W,am as z,b5 as R,b6 as L,a5 as T,a3 as O,a$ as f,b1 as F}from"./vendor-mui-core-
|
|
1
|
+
import{J as A,j as e,ak as t,a6 as E,Q as l,b3 as I,T as o,b4 as W,am as z,b5 as R,b6 as L,a5 as T,a3 as O,a$ as f,b1 as F}from"./vendor-mui-core-CAIaAq-_.js";import{r as x}from"./vendor-react-Dvs43sk9.js";import{l as D}from"./vendor-hooks-DTeIFVkk.js";import{C as b}from"./vendor-utils-BOkrEpKO.js";import{a as B,c as u,t as H,H as U,I as M,e as K}from"./index-l5234Nwn.js";import{K as p}from"./landing-page-BJTNr6j1.js";import{T as Q,M as y}from"./vendor-ux-C1NY8cuW.js";import{W as $}from"./did-address-BYpODbk4.js";import"./vendor-arcblock-DU4xNzGM.js";import"./lottie-web-4koyQiv_.js";function re(){const{searchParams:r}=new URL(window.location.href),{session:d}=B(),{t:c}=Q(),m=r.get("client_id"),_=r.get("scope")||"profile:read",[g,w]=x.useState(_.split(" ").filter(Boolean)),v=A("(max-width: 600px)"),k=b(window.location.origin,u.WELLKNOWN_SERVICE_PATH_PREFIX,"/oauth/authorize"),C=x.useCallback(i=>i?i.startsWith("http")?i:`${b(u.WELLKNOWN_SERVICE_PATH_PREFIX,"/api/media/upload",window.blocklet.appPid)}/${i}`:"",[]),[h,j]=D({client:null,loading:!0});x.useEffect(()=>{(async()=>{const{data:n}=await K.get("/oauth/client",{params:{clientId:m}});j({client:n,loading:!1})})()},[m,j]);const S=i=>{i!=="profile:read"&&w(n=>n.includes(i)?n.filter(P=>P!==i):[...n,i])};if(h.loading||!d?.user)return e.jsx(p,{did:window.blocklet?.appPid,standalone:!0,children:e.jsx(t,{sx:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%"},children:e.jsx(E,{})})});if(!h.client)return e.jsx(p,{did:window.blocklet?.appPid,standalone:!0,children:e.jsx(t,{sx:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%"},children:e.jsx(H,{style:{backgroundColor:"transparent"},status:"error",title:c("notFoundOauthClient"),extra:e.jsx(l,{variant:"outlined",color:"primary",size:"small",startIcon:e.jsx(I,{}),href:"/",style:{borderRadius:4},children:c("connectCli.home")})})})});const{client:s}=h,{user:a}=d,N=(s.scope||"").split(" ");return e.jsxs(p,{did:window.blocklet?.appPid,standalone:!0,children:[e.jsx(U,{children:e.jsxs("title",{children:[c("oauth.authorize")," | ",window.blocklet?.appName]})}),e.jsx(M,{hideCloseButton:!0,children:e.jsxs(t,{sx:{display:"flex",flexDirection:"column",p:{xs:2,lg:3,xl:4},pt:{xs:3,xl:4},bgcolor:"background.paper"},className:"page-authorize",children:[e.jsxs(t,{sx:{textAlign:"center",mb:2},children:[e.jsxs(t,{sx:{display:"flex",alignItems:"center",justifyContent:"center",mb:2},children:[e.jsx(y,{src:window.blocklet?.appLogo,alt:"Server",width:48,height:48}),e.jsxs(t,{sx:{mx:2,display:"flex",alignItems:"center","& .dot":{width:8,height:8,borderRadius:"50%",bgcolor:"divider",mx:.5}},children:[e.jsx(t,{className:"dot"}),e.jsx(t,{className:"dot"}),e.jsx(t,{className:"dot"})]}),e.jsx(y,{src:C(s.logo_uri),alt:s.client_name,width:48,height:48})]}),e.jsxs(o,{sx:{mb:1,fontSize:"1.2rem","& .app-name":{color:"primary.main"}},children:["Authorize ",e.jsx("span",{className:"app-name",children:s.client_name})]})]}),e.jsxs(t,{sx:{display:"flex",alignItems:"center",width:"100%",overflow:"hidden",mb:3,p:2,border:"1px solid",borderColor:"divider",borderRadius:1},className:"info",children:[e.jsx(W,{src:a.avatar,style:{width:48,height:48,backgroundColor:"transparent",marginRight:16}}),e.jsxs(t,{sx:{flex:1,overflow:"hidden"},children:[e.jsx(z,{title:a.fullName,children:e.jsx(t,{className:"name",sx:{flex:1,overflow:"hidden",textOverflow:"ellipsis"},children:a.fullName})}),e.jsx(t,{className:"did",children:e.jsx($,{compact:!0,responsive:!1,did:a.did,showQrcode:!v})})]})]}),e.jsxs(o,{variant:"subtitle1",sx:{mb:2,fontWeight:500},children:["Allow ",s.client_name," to do the following on your behalf:"]}),e.jsxs(t,{sx:{border:"1px solid",borderColor:"divider",borderRadius:2,overflow:"hidden"},children:[e.jsx(t,{sx:{p:2},children:e.jsx(R,{children:Object.entries(u.OAUTH_SCOPES).filter(([i])=>N.includes(i)).map(([i,n])=>e.jsx(L,{control:e.jsx(T,{checked:g.includes(i),onChange:()=>S(i),disabled:i==="profile:read"||["blocklet:read","blocklet:write"].includes(i)&&!["owner","admin","member"].includes(a.role),color:"primary",sx:{"&.Mui-checked":{color:"success.main"}}}),label:e.jsx(t,{children:e.jsx(o,{variant:"body1",sx:{fontWeight:500},children:n})}),sx:{mb:0}},i))})}),(s.tos_uri||s.policy_uri)&&e.jsxs(e.Fragment,{children:[e.jsx(O,{}),e.jsx(t,{sx:{height:1,bgcolor:"divider"}}),e.jsx(t,{sx:{p:2,color:"text.secondary"},children:e.jsxs(o,{variant:"body2",children:["By authorize the access, you also agree with the"," ",!!s.tos_uri&&e.jsx(f,{href:s.tos_uri,target:"_blank",children:"Terms of Use"}),!!s.tos_uri&&!!s.policy_uri&&" and ",!!s.policy_uri&&e.jsx(f,{href:s.policy_uri,target:"_blank",children:"Privacy Policy"})]})})]})]}),e.jsxs("form",{method:"POST",action:k,children:[r.get("client_id")&&e.jsx("input",{type:"hidden",name:"client_id",value:r.get("client_id")}),r.get("response_type")&&e.jsx("input",{type:"hidden",name:"response_type",value:r.get("response_type")}),r.get("redirect_uri")&&e.jsx("input",{type:"hidden",name:"redirect_uri",value:r.get("redirect_uri")}),r.get("code_challenge")&&e.jsx("input",{type:"hidden",name:"code_challenge",value:r.get("code_challenge")}),r.get("code_challenge_method")&&e.jsx("input",{type:"hidden",name:"code_challenge_method",value:r.get("code_challenge_method")}),r.get("state")&&e.jsx("input",{type:"hidden",name:"state",value:r.get("state")}),e.jsx("input",{type:"hidden",name:"scope",value:g.join(" ")}),e.jsx(t,{sx:{mt:"auto",pt:3},children:e.jsxs(F,{direction:"row",spacing:2,children:[e.jsx(l,{variant:"outlined",size:"large",fullWidth:!0,type:"submit",name:"action",value:"deny",children:"Cancel"}),e.jsx(l,{variant:"contained",size:"large",fullWidth:!0,type:"submit",name:"action",value:"allow",children:"Authorize"})]})}),r.get("redirect_uri")&&e.jsxs(t,{sx:{mt:3,textAlign:"center"},children:[e.jsx(o,{variant:"body2",sx:{color:"text.secondary"},children:"You will be redirected to"}),e.jsx(o,{variant:"body2",sx:{color:"text.secondary",wordBreak:"break-all"},children:r.get("redirect_uri")})]}),e.jsx(t,{sx:{mt:2,textAlign:"center"},children:e.jsxs(o,{variant:"body2",children:["Not you?"," ",e.jsx(l,{variant:"text",color:"primary",onClick:()=>d.switchDid(),sx:{p:0,minWidth:"auto",textTransform:"none",verticalAlign:"baseline",fontWeight:"inherit",fontSize:"inherit","&:hover":{background:"none",textDecoration:"underline"}},children:"Use another account"})]})})]})]})})]})}export{re as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as p}from"./vendor-react-Dvs43sk9.js";import{D as L,j as f,b7 as T,T as j,ak as k,W as t}from"./vendor-mui-core-
|
|
1
|
+
import{r as p}from"./vendor-react-Dvs43sk9.js";import{D as L,j as f,b7 as T,T as j,ak as k,W as t}from"./vendor-mui-core-CAIaAq-_.js";import{E as C}from"./index-DLDRrQJH.js";import{a as D}from"./vendor-utils-BOkrEpKO.js";const A=a=>{const h=new Date(Math.min(...a)),r=(new Date(Math.max(...a))-h)/(1e3*60);return u=>{if(r<=10){const c=(a.length-a.length%r)/r;return u%c===0}const d=(a.length-a.length%6)/6;return u%d===0}};function S({title:a="",total:h=0,history:s=[],valueFn:b=n=>n,xAxisFormat:r=n=>n,visualMapPieces:u=[],markLineData:v={},extraInfo:d=null,empty:w=null,onHover:c=()=>{},hoverIndex:i=null}){const n=L(),o=p.useRef(null),y=p.useMemo(()=>D(s)?[]:s.map(e=>r(e.date)),[s,r]);p.useEffect(()=>{if(!o.current||i?.ref===o)return;const e=o.current.getEchartsInstance(),l=i?.seriesIndex,x=y.findIndex(g=>g===i?.dataValue);i&&x!==-1?e.dispatchAction({type:"showTip",seriesIndex:l,dataIndex:x}):(e.dispatchAction({type:"hideTip"}),e.dispatchAction({type:"showTip",seriesIndex:0,dataIndex:-1}))},[i?.dataIndex]);const m=p.useCallback(()=>{c?.(null)},[c]);if(p.useEffect(()=>{if(o.current){const e=o.current.getEchartsInstance(),l=e.getDom();return l.addEventListener("mouseleave",m),()=>{l.removeEventListener("mouseleave",m),e.dispose()}}},[m]),D(s))return w||null;const E=Math.max(...s.map(e=>e.value),h||0,0),M={tooltip:{trigger:"axis",formatter(e){const l=e[0].data,x=b(l),{seriesIndex:g,dataIndex:I}=e[0];return c?.({seriesIndex:g,dataIndex:I,dataValue:y[I],ref:i?.ref||o}),`${e[0].name}: <b>${x}</b>`},backgroundColor:n.palette.background.paper,borderColor:n.palette.divider,textStyle:{color:n.palette.text.primary},extraCssText:`box-shadow: ${n.shadows[2]}; border-radius: 4px;`},grid:{top:"48px",left:"16px",right:"16px",bottom:"0px",containLabel:!0},xAxis:{type:"category",boundaryGap:!1,data:y,axisTick:{show:!1},splitLine:{show:!1},axisLabel:{interval:A(s.map(e=>new Date(e.date)))}},yAxis:{type:"value",axisTick:{show:!1},splitLine:{show:!1},min:0,max:E,interval:Math.ceil(E/2),axisLabel:{formatter:b,padding:[5,0,0,0]}},visualMap:{show:!1,type:"piecewise",dimension:1,seriesIndex:0,pieces:u},series:[{name:`${a} Usage`,type:"line",smooth:!0,symbol:"none",lineStyle:{color:n.palette.primary.main,width:2.5},areaStyle:{},itemStyle:{},emphasis:{disabled:!0},data:s.map(e=>e.value),markLine:v}]};return f.jsxs(T,{sx:{p:1,position:"relative"},children:[f.jsx(j,{sx:{fontSize:"16px",fontWeight:"bold",color:"text.secondary",position:"absolute",top:8,left:16,zIndex:10},children:a}),f.jsx(C,{ref:o,option:M,style:{width:"100%",height:"200px"},onEvents:{globalout:m}}),d&&f.jsx(k,{sx:{color:"text.secondary",ml:2,mt:1,fontSize:12},children:d})]})}S.propTypes={title:t.string,total:t.number,history:t.array,valueFn:t.func,xAxisFormat:t.func,visualMapPieces:t.array,markLineData:t.object,extraInfo:t.node,empty:t.node,onHover:t.func,hoverIndex:t.object};export{S as B};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as x}from"./vendor-ux-
|
|
1
|
+
import{r as x}from"./vendor-ux-C1NY8cuW.js";import{e as m}from"./vendor-react-Dvs43sk9.js";class w{constructor(e,r,o){this.name=e,this.prefix=r,this.baseEncode=o}encode(e){if(e instanceof Uint8Array)return`${this.prefix}${this.baseEncode(e)}`;throw Error("Unknown type, must be binary type")}}class g{constructor(e,r,o){if(this.name=e,this.prefix=r,r.codePointAt(0)===void 0)throw new Error("Invalid prefix character");this.prefixCodePoint=r.codePointAt(0),this.baseDecode=o}decode(e){if(typeof e=="string"){if(e.codePointAt(0)!==this.prefixCodePoint)throw Error(`Unable to decode multibase string ${JSON.stringify(e)}, ${this.name} decoder only supports inputs prefixed with ${this.prefix}`);return this.baseDecode(e.slice(this.prefix.length))}else throw Error("Can only multibase decode strings")}or(e){return l(this,e)}}class y{constructor(e){this.decoders=e}or(e){return l(this,e)}decode(e){const r=e[0],o=this.decoders[r];if(o)return o.decode(e);throw RangeError(`Unable to decode multibase string ${JSON.stringify(e)}, only inputs prefixed with ${Object.keys(this.decoders)} are supported`)}}const l=(t,e)=>new y({...t.decoders||{[t.prefix]:t},...e.decoders||{[e.prefix]:e}});class E{constructor(e,r,o,s){this.name=e,this.prefix=r,this.baseEncode=o,this.baseDecode=s,this.encoder=new w(e,r,o),this.decoder=new g(e,r,s)}encode(e){return this.encoder.encode(e)}decode(e){return this.decoder.decode(e)}}const A=({name:t,prefix:e,encode:r,decode:o})=>new E(t,e,r,o),C=(t,e,r,o)=>{const s={};for(let p=0;p<e.length;++p)s[e[p]]=p;let i=t.length;for(;t[i-1]==="=";)--i;const a=new Uint8Array(i*r/8|0);let n=0,c=0,h=0;for(let p=0;p<i;++p){const u=s[t[p]];if(u===void 0)throw new SyntaxError(`Non-${o} character`);c=c<<r|u,n+=r,n>=8&&(n-=8,a[h++]=255&c>>n)}if(n>=r||255&c<<8-n)throw new SyntaxError("Unexpected end of data");return a},P=(t,e,r)=>{const o=e[e.length-1]==="=",s=(1<<r)-1;let i="",a=0,n=0;for(let c=0;c<t.length;++c)for(n=n<<8|t[c],a+=8;a>r;)a-=r,i+=e[s&n>>a];if(a&&(i+=e[s&n<<r-a]),o)for(;i.length*r&7;)i+="=";return i},d=({name:t,prefix:e,bitsPerChar:r,alphabet:o})=>A({prefix:e,name:t,encode(s){return P(s,o,r)},decode(s){return C(s,o,r,t)}}),$=d({prefix:"b",name:"base32",alphabet:"abcdefghijklmnopqrstuvwxyz234567",bitsPerChar:5}),v=d({prefix:"B",name:"base32upper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",bitsPerChar:5}),S=d({prefix:"c",name:"base32pad",alphabet:"abcdefghijklmnopqrstuvwxyz234567=",bitsPerChar:5}),U=d({prefix:"C",name:"base32padupper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567=",bitsPerChar:5}),q=d({prefix:"v",name:"base32hex",alphabet:"0123456789abcdefghijklmnopqrstuv",bitsPerChar:5}),B=d({prefix:"V",name:"base32hexupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV",bitsPerChar:5}),O=d({prefix:"t",name:"base32hexpad",alphabet:"0123456789abcdefghijklmnopqrstuv=",bitsPerChar:5}),j=d({prefix:"T",name:"base32hexpadupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV=",bitsPerChar:5}),k=d({prefix:"h",name:"base32z",alphabet:"ybndrfg8ejkmcpqxot1uwisza345h769",bitsPerChar:5}),D=Object.freeze(Object.defineProperty({__proto__:null,base32:$,base32hex:q,base32hexpad:O,base32hexpadupper:j,base32hexupper:B,base32pad:S,base32padupper:U,base32upper:v,base32z:k},Symbol.toStringTag,{value:"Module"})),N=m(D);var f,b;function R(){if(b)return f;b=1;const{toBuffer:t,toAddress:e,toBase58:r,toHex:o}=x(),{base32:s}=N;return f={encode:n=>{if(!n)return n;const c=t(e(n));return s.encode(c)},decode:n=>{if(!n)return n;const c=s.decode(n),h=r(c);return h.length>30?h:o(c)}},f}export{R as r};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-
|
|
2
|
-
import{T as fe,_ as be}from"./vendor-ux-Cra9XTth.js";import{j as e,b1 as U,T as E,ak as x,b4 as je,am as Y,I as A,bW as J,Y as se,at as ve,bB as ye,$ as we,bv as Ce,A as Z,aJ as Se,bX as Ie,R as ke,Q as W,W as k}from"./vendor-mui-core-BOHKtf8y.js";import{c as D}from"./index-Cbf4geph.js";import{E as N}from"./empty-spinner-DCdg-gxP.js";import{k as Pe,u as Re}from"./vendor-hooks-DTeIFVkk.js";import{r as m}from"./vendor-react-Dvs43sk9.js";import{D as Q,C as G,P as ee}from"./react-beautiful-dnd.esm-DkLcR42r.js";import{S as F}from"./studio-C4flChud.js";import"./vendor-utils-BOkrEpKO.js";import"./lottie-web-4koyQiv_.js";import"./vendor-arcblock--zSibe1w.js";import"./raf-schd.esm-CHNehTG3.js";import"./index-Dj0TETp9.js";var I={},te;function Ee(){if(te)return I;te=1,Object.defineProperty(I,"__esModule",{value:!0}),I.getVideoId=b,I.getEmbedUrl=c,I.getVideoCoverUrl=P,I.getVideoCheckUrl=y,I.getYoutubeId=r,I.getVimeoId=a,I.isVideoUrl=w;function r(s){const t=s.trim();return t.includes("youtu.be/")?t.split("youtu.be/")[1]?.split("?")[0]:t.includes("/embed/")?t.split("/embed/")[1]?.split("?")[0]:t.includes("youtube.com/watch")?new URL(t).searchParams.get("v"):t.includes("youtube.com/shorts/")?t.split("/shorts/")[1]?.split("?")[0]:""}function a(s){const t=s.trim();return t.includes("/embed/")?t.split("/embed/")[1]?.split("?")[0]:t.includes("vimeo.com/video/")?t.split("/video/")[1]?.split("?")[0]:t.includes("vimeo.com/channels/")?t.split("/channels/")[1]?.split("/")[1]?.split("?")[0]:t.includes("vimeo.com/groups/")?t.split("/groups/")[1]?.split("/")[1]?.split("?")[0]:t.includes("vimeo.com/")?t.split("vimeo.com/")[1]?.split("?")[0]:""}const p={};function b(s){const t=s.trim();return!t||!/^https?:\/\/.+\..+/.test(t)?[]:(p[t]||(p[t]=(()=>{const u=new URL(t);return u.host.includes("youtube.com")||u.host.includes("youtu.be")?[r(t),"youtube"]:u.host.includes("vimeo.com")?[a(t),"vimeo"]:[]})()),p[t])}const n={};function c(s,{modestbranding:t=1,controls:u=0,autoplay:g=0}={}){const j=s.trim();if(!j)return"";if(n[j]!==void 0)return n[j];const[O,l]=b(j);return l==="youtube"?n[j]=`https://www.youtube.com/embed/${O}?modestbranding=${t}&controls=${u}&autoplay=${g}`:l==="vimeo"?n[j]=`https://player.vimeo.com/video/${O}?autoplay=${g}`:n[j]="",n[j]}const d={};function P(s){const t=s.trim();if(!t)return"";if(d[t]!==void 0)return d[t];const[u,g]=b(t);return g==="youtube"?d[t]=`https://img.youtube.com/vi/${u}/mqdefault.jpg`:g==="vimeo"?d[t]=`https://i.vimeocdn.com/${u}/1000x563`:d[t]="",d[t]}function y(s){const t=s.trim();if(!t)return"";const[u,g]=b(t);return g==="youtube"?`https://www.youtube.com/oembed?url=https://www.youtube.com/watch?v=${u}&format=json`:g==="vimeo"?`https://vimeo.com/api/oembed.json?url=https://vimeo.com/${u}`:""}function w(s){const t=s.trim();return b(t).length>0}return I}var q=Ee();const re=m.lazy(()=>be(()=>import("./index-DlaHLSvf.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13])).then(r=>({default:r.Uploader}))),Oe=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/logo/upload`,Le=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/screenshots/upload`,Ve=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/logo`,_=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/screenshots`,De=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/videos`,oe=5,ie=3;function Xe(){const{t:r,locale:a}=fe(),[p,b]=m.useState(!1),[n,c]=m.useState(!1),[d,P]=m.useState([]),[y,w]=m.useState([]),[s,t]=m.useState(""),[u,g]=m.useState(""),[j,O]=m.useState(Date.now()),l=Pe(async()=>{const i=await(await fetch(_)).json();return P(i.screenshots||[]),w(i.videos?.filter(h=>!!h)||[]),i}),f=m.useRef(null),C=m.useRef(null);if(l.loading&&!l.data)return e.jsx(F,{children:e.jsx(N,{size:40})});if(l.error)return e.jsx(F,{children:e.jsx(U,{direction:"column",spacing:1,sx:{mb:3},children:e.jsx(E,{sx:{color:"error.main",fontWeight:"bold"},children:l.error.message})})});const T=async o=>{const i=o.filter(h=>!!h);w(i),await fetch(De,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({videos:i})})},le=async o=>{const i=Array.from(y),[h]=i.splice(o.source.index,1);i.splice(o.destination.index,0,h),await T(i)},ce=async o=>{const i=Array.from(d),[h]=i.splice(o.source.index,1);i.splice(o.destination.index,0,h),P(i),await fetch(`${_}/reorder`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({screenshots:i})})},B=async o=>{o.destination&&(o.source.droppableId==="screenshots"?await ce(o):o.source.droppableId==="videos"&&await le(o),l.runAsync())},H=o=>{g(o.trim()),c(!0)},K=async(o,i="")=>{let h=[];i?h=o?y.map(v=>v===i?o.trim():v):y.filter(v=>v!==i):o&&(h=[...y,o.trim()]),g(""),c(!1),(o||i)&&await T(h),l.runAsync()},de=o=>{b(!0),t(o)},M=()=>{b(!1),t("")};function ue(){const o=[{label:r("studio.type"),value:"png, jpg, webp, svg"},{label:r("studio.ratio"),value:"256x256"},{label:r("studio.size"),value:"<500KB"}],i=[{label:r("studio.tip"),value:r("studio.change")}];return e.jsx($,{title:r("common.logo"),rules:o,tips:i,children:e.jsx(x,{sx:{flex:1,cursor:"pointer"},children:e.jsx(je,{variant:"square",sx:{width:128,height:128},alt:"Blocklet Logo",src:`${Ve}?t=${j}`,onClick:()=>f.current?.open()})})})}function pe(){const o=[{label:r("studio.ratio"),value:"16 / 9"},{label:r("studio.count"),value:`1~${oe}`},{label:r("studio.size"),value:"<5MB"}],i=[{label:r("studio.tip"),value:r("studio.orderTipLong")}];return e.jsx($,{title:r("common.screenshot"),tips:i,rules:o,children:e.jsx(Q,{onDragEnd:B,children:e.jsx(G,{droppableId:"screenshots",direction:"horizontal",children:(v,L)=>e.jsxs(x,{ref:v.innerRef,...v.droppableProps,sx:{display:"flex",alignItems:"center",flex:1,mt:1,flexWrap:"wrap",minHeight:225,background:L.isDraggingOver?"#f5f5f5":"transparent",transition:"background-color 0.2s ease",border:L.isDraggingOver?"2px dashed #999":"none",borderRadius:"4px"},children:[d.map((S,z)=>e.jsx(ee,{draggableId:S,index:z,children:(R,V)=>{const X=`${_}/${S}`;return e.jsxs(x,{ref:R.innerRef,...R.draggableProps,...R.dragHandleProps,className:"image-wrapper",sx:{transform:V.isDragging?"scale(1.05)":"none",boxShadow:V.isDragging?"0 5px 10px rgba(0,0,0,0.15)":"none",transition:"transform 0.2s ease, box-shadow 0.2s ease"},children:[e.jsx("img",{alt:"screenshot",src:X,onClick:()=>de(S),style:{cursor:"pointer"}}),e.jsx(Y,{title:r("studio.deleteTooltip"),children:e.jsx(A,{className:"action",style:{top:10,color:"white",background:"red"},onClick:async()=>{await fetch(X,{method:"DELETE"}),l.runAsync()},children:e.jsx(J,{})})})]})}},S)),v.placeholder,d.length<oe&&h()]})})})});function h(){return e.jsx(x,{onClick:()=>C.current?.open(),sx:{display:"flex",justifyContent:"center",alignItems:"center",mb:2,width:400,height:225,fontSize:40,background:"#eee",cursor:"pointer",color:"#999"},children:"+"})}}function he(){const o=[{label:r("studio.count"),value:`1~${ie}`},{label:r("studio.videoType"),value:e.jsxs(e.Fragment,{children:[e.jsx("a",{href:"https://www.youtube.com/",target:"_blank",rel:"noreferrer",children:"Youtube"}),","," ",e.jsx("a",{href:"https://vimeo.com/",target:"_blank",rel:"noreferrer",children:"Vimeo"})]})}],i=[{label:`${r("studio.tip")}`,value:r("studio.videoTipLong")}];return e.jsxs($,{title:r("studio.video"),tips:i,rules:o,children:[e.jsx(Q,{onDragEnd:B,children:e.jsx(G,{droppableId:"videos",direction:"horizontal",children:(v,L)=>e.jsxs(x,{ref:v.innerRef,...v.droppableProps,sx:{display:"flex",alignItems:"center",flex:1,mt:1,flexWrap:"wrap",minHeight:225,background:L.isDraggingOver?"#f5f5f5":"transparent",transition:"background-color 0.2s ease",border:L.isDraggingOver?"2px dashed #999":"none",borderRadius:"4px"},children:[y.map((S,z)=>e.jsx(ee,{draggableId:S,index:z,children:(R,V)=>e.jsxs(x,{ref:R.innerRef,...R.draggableProps,...R.dragHandleProps,className:"image-wrapper",sx:{transform:V.isDragging?"scale(1.05)":"none",boxShadow:V.isDragging?"0 5px 10px rgba(0,0,0,0.15)":"none",transition:"transform 0.2s ease, box-shadow 0.2s ease"},children:[e.jsx("img",{alt:"videos",src:q.getVideoCoverUrl(S),onClick:()=>H(S),style:{cursor:"pointer"}}),e.jsx(x,{sx:{position:"absolute",cursor:"pointer",fontSize:"3rem"},onClick:()=>H(S),children:e.jsx(ae,{})}),e.jsx(Y,{title:r("studio.deleteTooltip"),children:e.jsx(A,{className:"action",style:{top:10,color:"white",background:"red"},onClick:()=>K(null,S),children:e.jsx(J,{})})})]})},S)),v.placeholder,y.length<ie&&h()]})})}),n&&e.jsx(ne,{t:r,handleOperateVideo:K,defaultUrl:u,videos:y})]});function h(){return e.jsx(x,{onClick:()=>c(!0),sx:{display:"flex",justifyContent:"center",alignItems:"center",mb:2,width:400,height:225,fontSize:40,background:"#eee",cursor:"pointer",color:"#999"},children:"+"})}}function me(){return e.jsx(se,{open:p,onClose:M,maxWidth:"xl",slotProps:{paper:{style:{backgroundColor:"transparent",boxShadow:"none"}}},children:e.jsx("img",{src:`${_}/${s}`,alt:"Screenshot Full",style:{maxWidth:"90vw",maxHeight:"90vh",objectFit:"contain"},onClick:M})})}function xe(){return e.jsxs(m.Suspense,{fallback:e.jsx(N,{size:40}),children:[e.jsx(re,{ref:f,locale:a,popup:!0,onUploadFinish:()=>{f.current?.close(),O(Date.now()),l.runAsync()},plugins:["ImageEditor"],installerProps:{disabled:!0},apiPathProps:{uploader:Oe,disableMediaKitPrefix:!0,disableMediaKitStatus:!0},coreProps:{restrictions:{allowedFileTypes:["image/png","image/jpeg","image/webp","image/svg+xml"],maxFileSize:1024*1024*.5,maxNumberOfFiles:1}},dashboardProps:{autoOpen:"imageEditor"},imageEditorProps:{actions:{revert:!0,rotate:!0,granularRotate:!0,flip:!0,zoomIn:!0,zoomOut:!0,cropSquare:!1,cropWidescreen:!1,cropWidescreenVertical:!1},cropperOptions:{autoCrop:!0,aspectRatio:1,initialAspectRatio:1,autoCropArea:1,croppedCanvasOptions:{minWidth:256,minHeight:256}}}},"uploader-logo"),e.jsx(re,{ref:C,locale:a,popup:!0,onUploadFinish:()=>{C.current?.close(),l.runAsync()},installerProps:{disabled:!0},plugins:["ImageEditor"],apiPathProps:{uploader:Le,disableMediaKitPrefix:!0,disableMediaKitStatus:!0},coreProps:{restrictions:{allowedFileTypes:["image/*","image/svg+xml"],maxFileSize:1024*1024*5,maxNumberOfFiles:5-d.length}},imageEditorProps:{actions:{revert:!0,rotate:!0,granularRotate:!0,flip:!0,zoomIn:!0,zoomOut:!0,cropSquare:!1,cropWidescreen:!1,cropWidescreenVertical:!1},cropperOptions:{autoCrop:!0,autoCropArea:1,aspectRatio:16/9,initialAspectRatio:16/9,croppedCanvasOptions:{minWidth:1280,minHeight:720,maxWidth:1280*2,maxHeight:720*2}}}},"uploader-screenshot")]})}const ge=`https://www.arcblock.io/docs/blocklet-store/${a}/supplying-images`;return e.jsx(F,{children:e.jsxs(Te,{children:[e.jsxs(U,{direction:"column",spacing:1,sx:{mb:3},children:[e.jsx(E,{variant:"h5",sx:{fontWeight:"bold"},children:r("studio.title",{title:l.data?.title})}),e.jsxs(E,{variant:"body2",sx:{color:"text.secondary"},children:[r("studio.description")," ",e.jsx("a",{href:ge,target:"_blank",rel:"noreferrer",children:r("studio.documentation")})]})]}),ue(),pe(),he(),me(),xe()]})})}function $({title:r,rules:a,tips:p,children:b}){return e.jsxs(x,{sx:{display:"flex",flexDirection:"column",mb:4},children:[e.jsxs(U,{direction:"column",spacing:1,sx:{mb:2},children:[e.jsx(E,{variant:"h6",sx:{fontWeight:"bold"},children:r}),e.jsx(U,{direction:"row",spacing:2,sx:{fontSize:"13px",opacity:.8},children:a.map(c=>n(c.label,c.value))}),p.map(c=>e.jsx(x,{sx:{fontSize:"13px",opacity:.8},children:n(c.label,c.value)}))]}),b]});function n(c,d){return e.jsxs(x,{component:"span",children:[e.jsxs(x,{component:"span",sx:{color:"#555",mr:.5},children:[c,":"]}),e.jsx(x,{component:"span",sx:{color:"#007ec6"},children:d})]})}}$.propTypes={title:k.string.isRequired,rules:k.array.isRequired,tips:k.array.isRequired,children:k.node.isRequired};function ne({handleOperateVideo:r,t:a,defaultUrl:p="",videos:b}){const[n,c]=m.useState(p),[d,P]=m.useState(!1),[y,w]=m.useState(!1),s=m.useRef(n),t=n!==p&&b.includes(n),u=!n&&p,g=!t&&(n&&n!==s.current||d),j=!!navigator.clipboard?.readText,{run:O}=Re(l,{wait:500,leading:!0});return e.jsxs(se,{open:!0,fullWidth:!0,maxWidth:"sm",children:[e.jsx(ye,{children:a(p?"studio.videoDialogEditTitle":"studio.videoDialogTitle")}),e.jsxs(we,{children:[e.jsx(Ce,{fullWidth:!0,value:n,onChange:f=>{const C=f.target.value.trim();c(C),C?O(C):w(!1)},placeholder:a("studio.videoInputLabel"),endAdornment:n?e.jsx(Z,{position:"end",children:e.jsx(A,{onClick:()=>{c(""),l("")},children:e.jsx(Se,{})})}):j&&e.jsx(Z,{position:"end",children:e.jsx(A,{onClick:async()=>{try{const f=(await navigator.clipboard.readText()||"").trim();c(f),l(f)}catch(f){console.error(f)}},children:e.jsx(Ie,{})})})}),e.jsxs(x,{sx:{mb:2,mt:.5},children:[t&&e.jsx(E,{variant:"body2",color:"error",children:a("studio.duplicateVideo")}),!t&&y&&e.jsx(E,{variant:"body2",color:"error",children:a("studio.videoDialogNoSrc")})]}),s.current?e.jsx("iframe",{width:"100%",height:"315",title:`video-${s.current}`,src:q.getEmbedUrl(s.current),allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowFullScreen:!0,border:"1px solid #eee"}):e.jsx(x,{sx:{display:"flex",justifyContent:"center",alignItems:"center",height:315,width:"100%",border:"1px solid #eee"},children:d?e.jsx(N,{size:40}):e.jsx(E,{variant:"h5",sx:{color:"text.secondary"},children:e.jsx(ae,{})})})]}),e.jsxs(ke,{children:[e.jsx(W,{onClick:()=>r(),children:a("studio.cancel")}),u&&e.jsx(W,{variant:"contained",color:"error",onClick:()=>r(null,p),children:a("studio.delete")}),g&&e.jsx(W,{variant:"contained",onClick:()=>l(n),disabled:!n||d,children:a("studio.preview")}),!u&&!g&&e.jsx(W,{variant:"contained",onClick:()=>r(s.current),disabled:!s.current||p===s.current||t,children:a("studio.confirm")})]})]});function l(f){s.current="";const C=q.getVideoCheckUrl(f);w(f?!C:!1),C&&(P(!0),fetch(C).then(T=>{T.ok?(s.current=f,w(!1)):w(!0)}).catch(()=>{w(!0)}).finally(()=>P(!1)))}}ne.propTypes={handleOperateVideo:k.func.isRequired,t:k.func.isRequired,defaultUrl:k.string,videos:k.array.isRequired};function ae(){return e.jsxs("svg",{viewBox:"0 0 56 56",fill:"none",xmlns:"http://www.w3.org/2000/svg",height:48,width:48,children:[e.jsx("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M28 56C43.464 56 56 43.464 56 28C56 12.536 43.464 0 28 0C12.536 0 0 12.536 0 28C0 43.464 12.536 56 28 56Z",fill:"black","fill-opacity":"0.54"}),e.jsx("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M39.6667 28L21 17.5V38.5L39.6667 28Z",fill:"white"})]})}const Te=ve.div`
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-B2HJDbWz.js","assets/index-l5234Nwn.js","assets/vendor-mui-core-CAIaAq-_.js","assets/vendor-react-Dvs43sk9.js","assets/vendor-ux-C1NY8cuW.js","assets/vendor-utils-BOkrEpKO.js","assets/vendor-hooks-DTeIFVkk.js","assets/lottie-web-4koyQiv_.js","assets/vendor-ux-DYcPPYq2.css","assets/vendor-arcblock-DU4xNzGM.js","assets/index-DrVXX4fX.css","assets/index-BPy8_fa2.js","assets/index-DRYJ0xIl.js","assets/index-B5LvOF-F.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{T as fe,_ as be}from"./vendor-ux-C1NY8cuW.js";import{j as e,b1 as U,T as E,ak as x,b4 as je,am as Y,I as A,bW as J,Y as se,at as ve,bB as ye,$ as we,bv as Ce,A as Z,aJ as Se,bX as Ie,R as ke,Q as W,W as k}from"./vendor-mui-core-CAIaAq-_.js";import{c as D}from"./index-l5234Nwn.js";import{E as N}from"./empty-spinner-DXNgsKH2.js";import{k as Pe,u as Re}from"./vendor-hooks-DTeIFVkk.js";import{r as m}from"./vendor-react-Dvs43sk9.js";import{D as Q,C as G,P as ee}from"./react-beautiful-dnd.esm-DOptRWpa.js";import{S as F}from"./studio-CgXu1gEM.js";import"./vendor-utils-BOkrEpKO.js";import"./lottie-web-4koyQiv_.js";import"./vendor-arcblock-DU4xNzGM.js";import"./raf-schd.esm-CHNehTG3.js";import"./index-CgCVx1sf.js";var I={},te;function Ee(){if(te)return I;te=1,Object.defineProperty(I,"__esModule",{value:!0}),I.getVideoId=b,I.getEmbedUrl=c,I.getVideoCoverUrl=P,I.getVideoCheckUrl=y,I.getYoutubeId=r,I.getVimeoId=a,I.isVideoUrl=w;function r(s){const t=s.trim();return t.includes("youtu.be/")?t.split("youtu.be/")[1]?.split("?")[0]:t.includes("/embed/")?t.split("/embed/")[1]?.split("?")[0]:t.includes("youtube.com/watch")?new URL(t).searchParams.get("v"):t.includes("youtube.com/shorts/")?t.split("/shorts/")[1]?.split("?")[0]:""}function a(s){const t=s.trim();return t.includes("/embed/")?t.split("/embed/")[1]?.split("?")[0]:t.includes("vimeo.com/video/")?t.split("/video/")[1]?.split("?")[0]:t.includes("vimeo.com/channels/")?t.split("/channels/")[1]?.split("/")[1]?.split("?")[0]:t.includes("vimeo.com/groups/")?t.split("/groups/")[1]?.split("/")[1]?.split("?")[0]:t.includes("vimeo.com/")?t.split("vimeo.com/")[1]?.split("?")[0]:""}const p={};function b(s){const t=s.trim();return!t||!/^https?:\/\/.+\..+/.test(t)?[]:(p[t]||(p[t]=(()=>{const u=new URL(t);return u.host.includes("youtube.com")||u.host.includes("youtu.be")?[r(t),"youtube"]:u.host.includes("vimeo.com")?[a(t),"vimeo"]:[]})()),p[t])}const n={};function c(s,{modestbranding:t=1,controls:u=0,autoplay:g=0}={}){const j=s.trim();if(!j)return"";if(n[j]!==void 0)return n[j];const[O,l]=b(j);return l==="youtube"?n[j]=`https://www.youtube.com/embed/${O}?modestbranding=${t}&controls=${u}&autoplay=${g}`:l==="vimeo"?n[j]=`https://player.vimeo.com/video/${O}?autoplay=${g}`:n[j]="",n[j]}const d={};function P(s){const t=s.trim();if(!t)return"";if(d[t]!==void 0)return d[t];const[u,g]=b(t);return g==="youtube"?d[t]=`https://img.youtube.com/vi/${u}/mqdefault.jpg`:g==="vimeo"?d[t]=`https://i.vimeocdn.com/${u}/1000x563`:d[t]="",d[t]}function y(s){const t=s.trim();if(!t)return"";const[u,g]=b(t);return g==="youtube"?`https://www.youtube.com/oembed?url=https://www.youtube.com/watch?v=${u}&format=json`:g==="vimeo"?`https://vimeo.com/api/oembed.json?url=https://vimeo.com/${u}`:""}function w(s){const t=s.trim();return b(t).length>0}return I}var q=Ee();const re=m.lazy(()=>be(()=>import("./index-B2HJDbWz.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13])).then(r=>({default:r.Uploader}))),Oe=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/logo/upload`,Le=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/screenshots/upload`,Ve=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/logo`,_=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/screenshots`,De=`${D.WELLKNOWN_SERVICE_PATH_PREFIX}/api/studio/videos`,oe=5,ie=3;function Xe(){const{t:r,locale:a}=fe(),[p,b]=m.useState(!1),[n,c]=m.useState(!1),[d,P]=m.useState([]),[y,w]=m.useState([]),[s,t]=m.useState(""),[u,g]=m.useState(""),[j,O]=m.useState(Date.now()),l=Pe(async()=>{const i=await(await fetch(_)).json();return P(i.screenshots||[]),w(i.videos?.filter(h=>!!h)||[]),i}),f=m.useRef(null),C=m.useRef(null);if(l.loading&&!l.data)return e.jsx(F,{children:e.jsx(N,{size:40})});if(l.error)return e.jsx(F,{children:e.jsx(U,{direction:"column",spacing:1,sx:{mb:3},children:e.jsx(E,{sx:{color:"error.main",fontWeight:"bold"},children:l.error.message})})});const T=async o=>{const i=o.filter(h=>!!h);w(i),await fetch(De,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({videos:i})})},le=async o=>{const i=Array.from(y),[h]=i.splice(o.source.index,1);i.splice(o.destination.index,0,h),await T(i)},ce=async o=>{const i=Array.from(d),[h]=i.splice(o.source.index,1);i.splice(o.destination.index,0,h),P(i),await fetch(`${_}/reorder`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({screenshots:i})})},B=async o=>{o.destination&&(o.source.droppableId==="screenshots"?await ce(o):o.source.droppableId==="videos"&&await le(o),l.runAsync())},H=o=>{g(o.trim()),c(!0)},K=async(o,i="")=>{let h=[];i?h=o?y.map(v=>v===i?o.trim():v):y.filter(v=>v!==i):o&&(h=[...y,o.trim()]),g(""),c(!1),(o||i)&&await T(h),l.runAsync()},de=o=>{b(!0),t(o)},M=()=>{b(!1),t("")};function ue(){const o=[{label:r("studio.type"),value:"png, jpg, webp, svg"},{label:r("studio.ratio"),value:"256x256"},{label:r("studio.size"),value:"<500KB"}],i=[{label:r("studio.tip"),value:r("studio.change")}];return e.jsx($,{title:r("common.logo"),rules:o,tips:i,children:e.jsx(x,{sx:{flex:1,cursor:"pointer"},children:e.jsx(je,{variant:"square",sx:{width:128,height:128},alt:"Blocklet Logo",src:`${Ve}?t=${j}`,onClick:()=>f.current?.open()})})})}function pe(){const o=[{label:r("studio.ratio"),value:"16 / 9"},{label:r("studio.count"),value:`1~${oe}`},{label:r("studio.size"),value:"<5MB"}],i=[{label:r("studio.tip"),value:r("studio.orderTipLong")}];return e.jsx($,{title:r("common.screenshot"),tips:i,rules:o,children:e.jsx(Q,{onDragEnd:B,children:e.jsx(G,{droppableId:"screenshots",direction:"horizontal",children:(v,L)=>e.jsxs(x,{ref:v.innerRef,...v.droppableProps,sx:{display:"flex",alignItems:"center",flex:1,mt:1,flexWrap:"wrap",minHeight:225,background:L.isDraggingOver?"#f5f5f5":"transparent",transition:"background-color 0.2s ease",border:L.isDraggingOver?"2px dashed #999":"none",borderRadius:"4px"},children:[d.map((S,z)=>e.jsx(ee,{draggableId:S,index:z,children:(R,V)=>{const X=`${_}/${S}`;return e.jsxs(x,{ref:R.innerRef,...R.draggableProps,...R.dragHandleProps,className:"image-wrapper",sx:{transform:V.isDragging?"scale(1.05)":"none",boxShadow:V.isDragging?"0 5px 10px rgba(0,0,0,0.15)":"none",transition:"transform 0.2s ease, box-shadow 0.2s ease"},children:[e.jsx("img",{alt:"screenshot",src:X,onClick:()=>de(S),style:{cursor:"pointer"}}),e.jsx(Y,{title:r("studio.deleteTooltip"),children:e.jsx(A,{className:"action",style:{top:10,color:"white",background:"red"},onClick:async()=>{await fetch(X,{method:"DELETE"}),l.runAsync()},children:e.jsx(J,{})})})]})}},S)),v.placeholder,d.length<oe&&h()]})})})});function h(){return e.jsx(x,{onClick:()=>C.current?.open(),sx:{display:"flex",justifyContent:"center",alignItems:"center",mb:2,width:400,height:225,fontSize:40,background:"#eee",cursor:"pointer",color:"#999"},children:"+"})}}function he(){const o=[{label:r("studio.count"),value:`1~${ie}`},{label:r("studio.videoType"),value:e.jsxs(e.Fragment,{children:[e.jsx("a",{href:"https://www.youtube.com/",target:"_blank",rel:"noreferrer",children:"Youtube"}),","," ",e.jsx("a",{href:"https://vimeo.com/",target:"_blank",rel:"noreferrer",children:"Vimeo"})]})}],i=[{label:`${r("studio.tip")}`,value:r("studio.videoTipLong")}];return e.jsxs($,{title:r("studio.video"),tips:i,rules:o,children:[e.jsx(Q,{onDragEnd:B,children:e.jsx(G,{droppableId:"videos",direction:"horizontal",children:(v,L)=>e.jsxs(x,{ref:v.innerRef,...v.droppableProps,sx:{display:"flex",alignItems:"center",flex:1,mt:1,flexWrap:"wrap",minHeight:225,background:L.isDraggingOver?"#f5f5f5":"transparent",transition:"background-color 0.2s ease",border:L.isDraggingOver?"2px dashed #999":"none",borderRadius:"4px"},children:[y.map((S,z)=>e.jsx(ee,{draggableId:S,index:z,children:(R,V)=>e.jsxs(x,{ref:R.innerRef,...R.draggableProps,...R.dragHandleProps,className:"image-wrapper",sx:{transform:V.isDragging?"scale(1.05)":"none",boxShadow:V.isDragging?"0 5px 10px rgba(0,0,0,0.15)":"none",transition:"transform 0.2s ease, box-shadow 0.2s ease"},children:[e.jsx("img",{alt:"videos",src:q.getVideoCoverUrl(S),onClick:()=>H(S),style:{cursor:"pointer"}}),e.jsx(x,{sx:{position:"absolute",cursor:"pointer",fontSize:"3rem"},onClick:()=>H(S),children:e.jsx(ae,{})}),e.jsx(Y,{title:r("studio.deleteTooltip"),children:e.jsx(A,{className:"action",style:{top:10,color:"white",background:"red"},onClick:()=>K(null,S),children:e.jsx(J,{})})})]})},S)),v.placeholder,y.length<ie&&h()]})})}),n&&e.jsx(ne,{t:r,handleOperateVideo:K,defaultUrl:u,videos:y})]});function h(){return e.jsx(x,{onClick:()=>c(!0),sx:{display:"flex",justifyContent:"center",alignItems:"center",mb:2,width:400,height:225,fontSize:40,background:"#eee",cursor:"pointer",color:"#999"},children:"+"})}}function me(){return e.jsx(se,{open:p,onClose:M,maxWidth:"xl",slotProps:{paper:{style:{backgroundColor:"transparent",boxShadow:"none"}}},children:e.jsx("img",{src:`${_}/${s}`,alt:"Screenshot Full",style:{maxWidth:"90vw",maxHeight:"90vh",objectFit:"contain"},onClick:M})})}function xe(){return e.jsxs(m.Suspense,{fallback:e.jsx(N,{size:40}),children:[e.jsx(re,{ref:f,locale:a,popup:!0,onUploadFinish:()=>{f.current?.close(),O(Date.now()),l.runAsync()},plugins:["ImageEditor"],installerProps:{disabled:!0},apiPathProps:{uploader:Oe,disableMediaKitPrefix:!0,disableMediaKitStatus:!0},coreProps:{restrictions:{allowedFileTypes:["image/png","image/jpeg","image/webp","image/svg+xml"],maxFileSize:1024*1024*.5,maxNumberOfFiles:1}},dashboardProps:{autoOpen:"imageEditor"},imageEditorProps:{actions:{revert:!0,rotate:!0,granularRotate:!0,flip:!0,zoomIn:!0,zoomOut:!0,cropSquare:!1,cropWidescreen:!1,cropWidescreenVertical:!1},cropperOptions:{autoCrop:!0,aspectRatio:1,initialAspectRatio:1,autoCropArea:1,croppedCanvasOptions:{minWidth:256,minHeight:256}}}},"uploader-logo"),e.jsx(re,{ref:C,locale:a,popup:!0,onUploadFinish:()=>{C.current?.close(),l.runAsync()},installerProps:{disabled:!0},plugins:["ImageEditor"],apiPathProps:{uploader:Le,disableMediaKitPrefix:!0,disableMediaKitStatus:!0},coreProps:{restrictions:{allowedFileTypes:["image/*","image/svg+xml"],maxFileSize:1024*1024*5,maxNumberOfFiles:5-d.length}},imageEditorProps:{actions:{revert:!0,rotate:!0,granularRotate:!0,flip:!0,zoomIn:!0,zoomOut:!0,cropSquare:!1,cropWidescreen:!1,cropWidescreenVertical:!1},cropperOptions:{autoCrop:!0,autoCropArea:1,aspectRatio:16/9,initialAspectRatio:16/9,croppedCanvasOptions:{minWidth:1280,minHeight:720,maxWidth:1280*2,maxHeight:720*2}}}},"uploader-screenshot")]})}const ge=`https://www.arcblock.io/docs/blocklet-store/${a}/supplying-images`;return e.jsx(F,{children:e.jsxs(Te,{children:[e.jsxs(U,{direction:"column",spacing:1,sx:{mb:3},children:[e.jsx(E,{variant:"h5",sx:{fontWeight:"bold"},children:r("studio.title",{title:l.data?.title})}),e.jsxs(E,{variant:"body2",sx:{color:"text.secondary"},children:[r("studio.description")," ",e.jsx("a",{href:ge,target:"_blank",rel:"noreferrer",children:r("studio.documentation")})]})]}),ue(),pe(),he(),me(),xe()]})})}function $({title:r,rules:a,tips:p,children:b}){return e.jsxs(x,{sx:{display:"flex",flexDirection:"column",mb:4},children:[e.jsxs(U,{direction:"column",spacing:1,sx:{mb:2},children:[e.jsx(E,{variant:"h6",sx:{fontWeight:"bold"},children:r}),e.jsx(U,{direction:"row",spacing:2,sx:{fontSize:"13px",opacity:.8},children:a.map(c=>n(c.label,c.value))}),p.map(c=>e.jsx(x,{sx:{fontSize:"13px",opacity:.8},children:n(c.label,c.value)}))]}),b]});function n(c,d){return e.jsxs(x,{component:"span",children:[e.jsxs(x,{component:"span",sx:{color:"#555",mr:.5},children:[c,":"]}),e.jsx(x,{component:"span",sx:{color:"#007ec6"},children:d})]})}}$.propTypes={title:k.string.isRequired,rules:k.array.isRequired,tips:k.array.isRequired,children:k.node.isRequired};function ne({handleOperateVideo:r,t:a,defaultUrl:p="",videos:b}){const[n,c]=m.useState(p),[d,P]=m.useState(!1),[y,w]=m.useState(!1),s=m.useRef(n),t=n!==p&&b.includes(n),u=!n&&p,g=!t&&(n&&n!==s.current||d),j=!!navigator.clipboard?.readText,{run:O}=Re(l,{wait:500,leading:!0});return e.jsxs(se,{open:!0,fullWidth:!0,maxWidth:"sm",children:[e.jsx(ye,{children:a(p?"studio.videoDialogEditTitle":"studio.videoDialogTitle")}),e.jsxs(we,{children:[e.jsx(Ce,{fullWidth:!0,value:n,onChange:f=>{const C=f.target.value.trim();c(C),C?O(C):w(!1)},placeholder:a("studio.videoInputLabel"),endAdornment:n?e.jsx(Z,{position:"end",children:e.jsx(A,{onClick:()=>{c(""),l("")},children:e.jsx(Se,{})})}):j&&e.jsx(Z,{position:"end",children:e.jsx(A,{onClick:async()=>{try{const f=(await navigator.clipboard.readText()||"").trim();c(f),l(f)}catch(f){console.error(f)}},children:e.jsx(Ie,{})})})}),e.jsxs(x,{sx:{mb:2,mt:.5},children:[t&&e.jsx(E,{variant:"body2",color:"error",children:a("studio.duplicateVideo")}),!t&&y&&e.jsx(E,{variant:"body2",color:"error",children:a("studio.videoDialogNoSrc")})]}),s.current?e.jsx("iframe",{width:"100%",height:"315",title:`video-${s.current}`,src:q.getEmbedUrl(s.current),allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowFullScreen:!0,border:"1px solid #eee"}):e.jsx(x,{sx:{display:"flex",justifyContent:"center",alignItems:"center",height:315,width:"100%",border:"1px solid #eee"},children:d?e.jsx(N,{size:40}):e.jsx(E,{variant:"h5",sx:{color:"text.secondary"},children:e.jsx(ae,{})})})]}),e.jsxs(ke,{children:[e.jsx(W,{onClick:()=>r(),children:a("studio.cancel")}),u&&e.jsx(W,{variant:"contained",color:"error",onClick:()=>r(null,p),children:a("studio.delete")}),g&&e.jsx(W,{variant:"contained",onClick:()=>l(n),disabled:!n||d,children:a("studio.preview")}),!u&&!g&&e.jsx(W,{variant:"contained",onClick:()=>r(s.current),disabled:!s.current||p===s.current||t,children:a("studio.confirm")})]})]});function l(f){s.current="";const C=q.getVideoCheckUrl(f);w(f?!C:!1),C&&(P(!0),fetch(C).then(T=>{T.ok?(s.current=f,w(!1)):w(!0)}).catch(()=>{w(!0)}).finally(()=>P(!1)))}}ne.propTypes={handleOperateVideo:k.func.isRequired,t:k.func.isRequired,defaultUrl:k.string,videos:k.array.isRequired};function ae(){return e.jsxs("svg",{viewBox:"0 0 56 56",fill:"none",xmlns:"http://www.w3.org/2000/svg",height:48,width:48,children:[e.jsx("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M28 56C43.464 56 56 43.464 56 28C56 12.536 43.464 0 28 0C12.536 0 0 12.536 0 28C0 43.464 12.536 56 28 56Z",fill:"black","fill-opacity":"0.54"}),e.jsx("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M39.6667 28L21 17.5V38.5L39.6667 28Z",fill:"white"})]})}const Te=ve.div`
|
|
3
3
|
margin-top: 24px;
|
|
4
4
|
.image-wrapper {
|
|
5
5
|
margin-bottom: 16px;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as j}from"./vendor-react-Dvs43sk9.js";import{j as e,bU as r1,at as U,ak as i,aj as K,z as h1,U as d1,I as W,a6 as n1,bE as p1,F as f1,O as x1,bV as Y,W as s,b7 as v1,b4 as m1,ar as g1,T as g,a3 as k,Q as V,b1 as u1}from"./vendor-mui-core-
|
|
1
|
+
import{r as j}from"./vendor-react-Dvs43sk9.js";import{j as e,bU as r1,at as U,ak as i,aj as K,z as h1,U as d1,I as W,a6 as n1,bE as p1,F as f1,O as x1,bV as Y,W as s,b7 as v1,b4 as m1,ar as g1,T as g,a3 as k,Q as V,b1 as u1}from"./vendor-mui-core-CAIaAq-_.js";import{C as j1,M as y1,e as Z1,b as w1,H as L1}from"./vendor-ux-C1NY8cuW.js";import{l as b1}from"./vendor-hooks-DTeIFVkk.js";import{U as $,ap as k1,aq as M1,R as p}from"./index-l5234Nwn.js";import{s as R1}from"./sanitize-Bu5pIC-A.js";import{F as E1}from"./form-text-input-BWWenIQu.js";import{R as _1}from"./required-DyRlNY7J.js";import{F as B1}from"./form-wrapper-RaRgkgkH.js";import{w as q}from"./permission-CzDQ8THQ.js";import{a as O1}from"./team-DjZ9qE6U.js";import{L as Z}from"./logo-uploader-3Gf22QS4.js";import{S as M}from"./section-D6477Ce1.js";import"./vendor-utils-BOkrEpKO.js";import"./lottie-web-4koyQiv_.js";import"./vendor-arcblock-DU4xNzGM.js";import"./omit-8QDODHip.js";import"./index-BPy8_fa2.js";import"./edit.svg-DycWG9v3.js";import"./session-YnDvY5CJ.js";import"./isURL-DA2-tMLY.js";function Q({label:l="",disabled:r=!1,required:d=!1,initialValue:y="",onChange:B=()=>{},style:f={},onSubmit:x=()=>{},triggers:a=[],options:n=[],formatterBeforeSubmit:O=L=>L.join(","),helperText:S="",placeholder:I="",renderImage:z=()=>null,renderLabel:R=()=>"",filterKeys:w=["name"],noEmpty:H=!1,...T}){const[L,P]=j.useState(!1),[E,C]=j.useState(!1),[_,F]=j.useState(""),A=j.useRef(null),[b,c]=j.useState(y),[h,v]=j.useState(b),u=j.useMemo(()=>{if(!n)return{};const o={};return n.forEach(t=>{o[t.code]=t}),o},[n]),i1=()=>{if(!n)return[];if(!_)return n.map(t=>t.code);const o=new RegExp(_.toLowerCase());return n.filter(t=>{for(let m=0;m<w.length;m++){const N=w[m];if(o.test(t[N]?.toLowerCase()))return!0}return!1}).map(t=>t.code)},c1=async()=>{C(!0);try{await x(typeof O=="function"?O(h):h)===!1?v(b):H&&!h.length?(v(y),c(y)):(v(h),c(h))}catch{v(b)}finally{C(!1),P(!1)}},t1=(o,t)=>{if(!Array.isArray(t)){v([]),B([]);return}const m=t.filter(N=>u[N]);if(!m.length){v([]),B([]);return}v(m),B(m)},s1=o=>{o.stopPropagation(),P(!0),setTimeout(()=>{if(A.current){const t=A.current.querySelector("input");t&&t.focus()}},500)},o1=L?e.jsx(r1,{ref:A,options:n,value:h,onChange:t1,inputValue:_,onInputChange:(o,t)=>{F(t)},fullWidth:!0,multiple:!0,variant:"outlined",margin:"dense",filterOptions:i1,getOptionLabel:o=>u[o]?.name,renderInput:o=>e.jsx(h1,{...o,label:"",placeholder:I}),renderOption:(o,t)=>{const m=h.indexOf(t)!==-1;return j.createElement(S1,{component:"li",...o,key:t},z(u[t]||{}),e.jsx(i,{sx:{"& > img":{mr:2,flexShrink:0}},style:{flex:1,fontWeight:m?"700":"normal"},children:R(t,u[t])||u[t]?.name}),e.jsx(i,{component:K,sx:{opacity:.5,width:18,height:18},style:{visibility:m?"visible":"hidden"}}))},...T,slots:{popper:H1}}):e.jsx(i,{className:"form-item-input slot",onClick:s1,style:{whiteSpace:"pre-wrap",cursor:"text"},sx:{px:1},children:h.filter(o=>n.some(t=>t.code===o)).map(o=>e.jsx(d1,{label:n.find(t=>t.code===o).name,style:{marginRight:8},size:"small"},o))});return e.jsx(B1,{className:"form",style:f,children:e.jsxs(i,{className:"form-item",children:[e.jsxs(i,{className:"form-item-label",children:[l,d&&e.jsx(_1,{})]}),e.jsxs(i,{className:"form-item-body",children:[e.jsx(i,{className:"form-item-input",children:o1}),L?e.jsx(i,{className:"form-item-action",children:e.jsxs(e.Fragment,{children:[e.jsx(W,{"data-cy":"schema-form-item-confirm",onClick:c1,disabled:r||E,size:"large",children:E?e.jsx(n1,{size:24}):e.jsx(p1,{})}),e.jsx(W,{"data-cy":"schema-form-item-cancel",onClick:()=>{v(b),P(!1)},disabled:r||E,size:"large",children:e.jsx(K,{})})]})}):null]}),L&&S&&e.jsx(f1,{children:S})]})})}Q.propTypes={style:s.object,onSubmit:s.func,onChange:s.func,label:s.string,initialValue:s.string,required:s.bool,disabled:s.bool,triggers:s.array,options:s.array,helperText:s.string,formatterBeforeSubmit:s.func,placeholder:s.string,renderImage:s.func,filterKeys:s.arrayOf(s.string),noEmpty:s.bool,renderLabel:s.func};const S1=U.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
justify-content: space-between;
|
|
4
4
|
align-items: center;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as u,b4 as x,W as e}from"./vendor-mui-core-
|
|
1
|
+
import{j as u,b4 as x,W as e}from"./vendor-mui-core-CAIaAq-_.js";import{$}from"./vendor-ux-C1NY8cuW.js";import{C as m}from"./vendor-utils-BOkrEpKO.js";import{U as l,a9 as v,aa as j,c as y,ab as E,ac as P}from"./index-l5234Nwn.js";function R({blocklet:o,ancestors:d=[]}){const t=l(),{inService:s}=t,n=v(o?.status)||j(o?.status),r=`?v=${o?.meta?.version}${n?"~":""}`;let a=s?`${m(E,y.WELLKNOWN_SERVICE_PATH_PREFIX,"/blocklet/logo-bundle")}${r}`:m(t.imgPrefix,"blocklet.png");if(o.source==="registry"&&o.deployedFrom&&o.meta.logo)a=`${m(o.deployedFrom,P(o.meta.bundleDid,o.meta.logo))}${r}`;else{const g=window.env?.apiPrefix||"/",i=d.concat(o),p=s?i.slice(1):i;a=`${m(g,`/blocklet/logo-bundle${p.map(c=>`/${c.meta.did}`).join("")}`)}${r}`}return{logoUrl:a,inService:s}}function h({blocklet:o,style:d={},size:t=40,ancestors:s=[],...n}){const r=l(),{logoUrl:a,inService:g}=R({blocklet:o,ancestors:s}),{variant:i}=n,p=g?()=>{}:f=>{f.target.src=`${r.imgPrefix}/blocklet.png`};let c=u.jsx("img",{src:a,onError:p,alt:o.meta.name,style:{width:t}});return o.meta.logo||(c=u.jsx($,{did:o.meta.did||"",responsive:!0})),u.jsx(x,{variant:i||"square",style:Object.assign({backgroundColor:"transparent",width:t,height:t,borderRadius:10},d),...n,children:c})}h.propTypes={blocklet:e.object.isRequired,style:e.object,size:e.oneOfType([e.number,e.string]),ancestors:e.array};export{h as B};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as o}from"./vendor-mui-core-CAIaAq-_.js";import{n as r}from"./vendor-ux-C1NY8cuW.js";function m({...t}){return o.jsx(r,{className:"bottom-button",variant:"contained",color:"primary",...t})}export{m as S};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as i}from"./vendor-react-Dvs43sk9.js";import{j as t,W as e}from"./vendor-mui-core-
|
|
1
|
+
import{r as i}from"./vendor-react-Dvs43sk9.js";import{j as t,W as e}from"./vendor-mui-core-CAIaAq-_.js";import{b as s,R as c}from"./vendor-ux-C1NY8cuW.js";function m({children:p,...r}){const{t:o}=i.useContext(s);return t.jsx(c,{tip:o("common.copyTip"),copiedTip:o("common.copiedTip"),...r,children:p})}m.propTypes={children:e.any.isRequired};export{m as C};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./vendor-react-Dvs43sk9.js";import{s as a,j as r,bk as e,bl as s,bm as n,bn as i}from"./vendor-mui-core-
|
|
1
|
+
import"./vendor-react-Dvs43sk9.js";import{s as a,j as r,bk as e,bl as s,bm as n,bn as i}from"./vendor-mui-core-CAIaAq-_.js";const c=a(o=>r.jsx(e,{disableGutters:!0,elevation:0,square:!0,...o}))(({theme:o})=>({border:`1px solid ${o.palette.divider}`,"&:not(:last-child)":{borderBottom:0},"&::before":{display:"none"}})),p=a(o=>r.jsx(s,{expandIcon:r.jsx(n,{sx:{fontSize:"0.9rem"}}),...o}))(({theme:o})=>({backgroundColor:o.palette.mode==="dark"?"rgba(255, 255, 255, .05)":"rgba(0, 0, 0, .03)",flexDirection:"row-reverse","& .MuiAccordionSummary-expandIconWrapper.Mui-expanded":{transform:"rotate(90deg)"},"& .MuiAccordionSummary-content":{marginLeft:o.spacing(1)}})),m=a(i)(({theme:o})=>({padding:o.spacing(2),borderTop:"1px solid rgba(0, 0, 0, .125)"}));export{c as A,p as a,m as b};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{at as E,j as e,ak as m,W as V}from"./vendor-mui-core-
|
|
1
|
+
import{at as E,j as e,ak as m,W as V}from"./vendor-mui-core-CAIaAq-_.js";import{a2 as J,m as ne,ak as H,al as oe,T as ae,am as O,c as ie,e as le,h as ce,an as ue,ao as me}from"./index-l5234Nwn.js";import{r as u}from"./vendor-react-Dvs43sk9.js";import{J as de,C as Q}from"./vendor-utils-BOkrEpKO.js";import{b as pe,a as j}from"./vendor-hooks-DTeIFVkk.js";import{u as he}from"./launch-result-message-BklGSk6L.js";import{T as fe,o as ge,H as X}from"./vendor-ux-C1NY8cuW.js";import{g as we}from"./get-safe-url-Byu99Iq6.js";import{g as xe,a as be}from"./setup-DigmKGGp.js";import{S as q}from"./button-BGOqx4KL.js";import{S as ke}from"./layout-B_66AMXX.js";import{p as ye,P as Ue,S as Se}from"./starting-progress-BjFMTtUQ.js";import"./vendor-arcblock-DU4xNzGM.js";import"./lottie-web-4koyQiv_.js";import"./config-space-DmPAo0Uc.js";import"./spaces-KdeOps1v.js";import"./api-Rnh95Dt4.js";import"./addon-S-x2oOBW.js";import"./question-mark-circle.svg-B4stD6SS.js";import"./use-server-logo-Bs73VID2.js";import"./server-logo-notext.svg-CKQB0tIp.js";import"./use-mobile-CzqOrBZu.js";import"./content-layout-D5EfCmvE.js";const ve=E(he)`
|
|
2
2
|
&& .result-footer {
|
|
3
3
|
height: 120px;
|
|
4
4
|
> div {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-
|
|
2
|
-
import{cf as ae,j as D,ak as le,am as _t,W as K,ax as ze,aD as dt,b as Ve,g as Ue,a as Te,m as Gh,s as oe,_ as U,h as We,T as rt,n as va,u as Fe,
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-B2HJDbWz.js","assets/index-l5234Nwn.js","assets/vendor-mui-core-CAIaAq-_.js","assets/vendor-react-Dvs43sk9.js","assets/vendor-ux-C1NY8cuW.js","assets/vendor-utils-BOkrEpKO.js","assets/vendor-hooks-DTeIFVkk.js","assets/lottie-web-4koyQiv_.js","assets/vendor-ux-DYcPPYq2.css","assets/vendor-arcblock-DU4xNzGM.js","assets/index-DrVXX4fX.css","assets/index-BPy8_fa2.js","assets/index-DRYJ0xIl.js","assets/index-B5LvOF-F.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{cf as ae,j as D,ak as le,am as _t,W as K,ax as ze,aD as dt,b as Ve,g as Ue,a as Te,m as Gh,s as oe,_ as U,h as We,T as rt,n as va,u as Fe,dT as Hh,i as ml,k as Oa,E as xf,G as wf,l as Pn,B as Yh,H as Kh,D as _n,c as Yt,I as tt,t as Qh,q as Df,ar as Xh,c1 as dr,Q as wn,R as Pf,K as Zh,L as Jh,N as lo,O as eg,P as tg,A as ng,Y as Gi,Z as _s,$ as Hi,J as _a,a0 as Is,a1 as rg,a2 as ag,aH as As,at as st,aL as og,dw as ig,dU as lg,bD as sg,aJ as js,aI as ug,c6 as cg,c7 as Ls,dV as dg,dW as fg,dX as pg,ch as hl,ca as Mr,an as mg,cg as Tf,aX as Bs,z as mt,b1 as Sf,dN as kf,dY as hg,M as Vt,a6 as an,bc as Rf,dZ as gg,b4 as bg,a$ as Ia,d_ as vg,bp as yg,b6 as Yi,bq as Ns,cM as Cg,aZ as xg,d$ as wg,d1 as Ef,bx as Mf,bd as Dg,cQ as Pg,e0 as Tg,bB as Fs,a5 as $s,e1 as Sg,be as kg}from"./vendor-mui-core-CAIaAq-_.js";import{aw as qs,n as zs,C as yr,ax as Rg,av as Eg}from"./vendor-utils-BOkrEpKO.js";import{d as Pe,a as Me,e as ln,g as Of,r as O,c as gl,b as Mg,i as _f}from"./vendor-react-Dvs43sk9.js";import{aZ as ne,L as Og,T as ut,H as je,b5 as re,b6 as If,b7 as sn,b8 as Kt,b9 as Tt,ba as Or,bb as Aa,bc as Ye,bd as ja,be as La,bf as bl,bg as Ba,bh as Af,bi as Na,bj as Fa,bk as _g,bl as Ig,bm as Ag,bn as jg,bo as Lg,bp as Bg,bq as Ng,br as Fg,bs as $g,bt as qg,bu as zg,bv as jt,bw as It,bx as $a,by as un,bz as jf,bA as vl,bB as Lf,bC as Vg,bD as Ug,bE as Wg,bF as In,bG as cn,bH as Gg,bI as Hg,bJ as Yg,bK as Kg,bL as Qg,bM as Xg,bN as _r,bO as Zg,bP as Jg,bQ as eb,bR as tb,aa as Vs,ab as nb,ac as rb,ad as ab,bS as Bf,bT as ob,bU as ib,bV as lb,bW as sb,bX as ub,bY as cb,bZ as db,b_ as fb,b$ as pb,c0 as mb,c1 as hb,b as Qt,a as qa,_ as gb,a0 as bb,B as so,I as Pt,n as uo,G as vb}from"./vendor-ux-C1NY8cuW.js";import{U as ft,a1 as dn,aq as Tn,R as At,f as $e,ap as Cr,ct as yb,c as be,cl as Sn,ck as Nf,an as Ff,cu as $f,T as Cb,af as fr,aN as xb,cv as wb}from"./index-l5234Nwn.js";import{f as Dt}from"./index-DBs9Ljax.js";import{b as Db,W as kn,u as yl,B as qf}from"./dashboard-DTH5SkDE.js";import{S as Pb}from"./switch-control-CkW4eeJ4.js";import{P as Ki,w as za}from"./permission-CzDQ8THQ.js";import{u as zf,r as Tb}from"./vendor-mui-x-DXh6Gdva.js";import{r as Se,A as Cl,B as pt,C as ya,D as Qi,t as De,E as Vf,F as Uf,c as Xi,o as Sb,G as $t,H as kb,I as Rb,J as Zi,K as Wf,L as Eb,M as Mb,N as Gf,O as xl,P as Us,Q as Ob,R as Ws,S as _b,T as Ib,p as Ab,a as Gs,b as jb,j as co,h as Hs,m as Lb,k as qr,u as mn,i as Bb,n as Nb,g as zr,f as fo,d as Vr,s as po,e as mo,x as Fb,z as $b,q as qb,l as zb,v as Vb,w as Ub,U as Wb,y as Gb,V as Hb,W as Yb}from"./index-DgGkR58E.js";import{f as Kb,d as Ys,c as Qb,b as Oe,_ as Re,a as Ee}from"./createClass-Cy-fAHUw.js";import{u as ke,a as ue,r as xr,w as Ca,g as Hf,b as fn,e as Yf,c as Xb,d as Zb,o as Ji}from"./raf-schd.esm-CHNehTG3.js";import{s as Jb}from"./sanitize-Bu5pIC-A.js";import{C as Ks}from"./click-to-copy-Lt7iNH-g.js";import{v as ho}from"./index-dytlEEOb.js";import{A as ev,a as tv,b as nv,I as rv,f as av,B as ov,d as iv}from"./add-component-core-DbPZIJoa.js";import{C as An}from"./confirm-DwicyBRo.js";import{a as xa,v as lv}from"./util-majSFCTY.js";import{C as sv}from"./lock.svg-COUP8tyO.js";import{D as uv}from"./delete-confirm-Bn607XWd.js";import{e as cv}from"./engine-DwJQ8ndb.js";import{I as dv}from"./iframe-2AxKOYBR.js";import{B as fv}from"./bundle-avatar-B6WDP8U8.js";import{A as Kf}from"./actions-DiUxQ792.js";import{v as go}from"./index-DLvW-hX6.js";import{W as pv}from"./did-address-BYpODbk4.js";import{b as mv}from"./vendor-hooks-DTeIFVkk.js";import"./lottie-web-4koyQiv_.js";import"./vendor-arcblock-DU4xNzGM.js";import"./useLocalStorage-phc-OA98.js";import"./get-safe-url-Byu99Iq6.js";import"./session-YnDvY5CJ.js";import"./team-DjZ9qE6U.js";import"./isURL-DA2-tMLY.js";import"./dot-3RzyGk21.js";import"./useAsync-BdgUavMa.js";import"./useSetState-DFuQZPPV.js";import"./index-CgCVx1sf.js";import"./over-due-invoice-payment-D1hhqrpZ.js";import"./use-mobile-CO13Oymt.js";import"./index-Br7EG_jz.js";import"./omit-8QDODHip.js";import"./index-BPy8_fa2.js";import"./item-Deax8Tcs.js";import"./wait-connect-DpAcPy2e.js";import"./launch-result-message-BklGSk6L.js";import"./page-header-Fuppayrb.js";import"./config-space-DmPAo0Uc.js";import"./spaces-KdeOps1v.js";import"./api-Rnh95Dt4.js";import"./required-DyRlNY7J.js";import"./index-BsHHb1rN.js";import"./Google-B5khWV-G.js";import"./cloneDeep-DwV-xVQF.js";import"./form-wrapper-RaRgkgkH.js";import"./logo-uploader-3Gf22QS4.js";import"./collapse-tY1N2fk5.js";import"./index-DU79Hpz9.js";import"./config-ZidMeHMX.js";import"./section-D6477Ce1.js";import"./form-text-input-BWWenIQu.js";import"./edit.svg-DycWG9v3.js";import"./index-D05HWeh6.js";import"./use-mobile-CzqOrBZu.js";import"./content-layout-D5EfCmvE.js";import"./connect-to-duHzVFsc.js";import"./index-7Wt3WOLU.js";import"./index-DRYJ0xIl.js";import"./index-BojVbZw0.js";import"./search-4YYphs0l.js";var hv=36e5;function gv(e,t){Se(2,arguments);var n=pt(t);return Cl(e,n*hv)}var bv=864e5;function vv(e,t){Se(2,arguments);var n=ya(e),a=ya(t),r=n.getTime()-Qi(n),o=a.getTime()-Qi(a);return Math.round((r-o)/bv)}var yv=6e4;function Cv(e,t){Se(2,arguments);var n=pt(t);return Cl(e,n*yv)}function xv(e,t){Se(2,arguments);var n=pt(t);return Cl(e,n*1e3)}function hr(e,t){Se(2,arguments);var n=De(e),a=De(t),r=n.getTime()-a.getTime();return r<0?-1:r>0?1:r}function wv(e,t){Se(2,arguments);var n=De(e),a=De(t);return n.getFullYear()-a.getFullYear()}function Qs(e,t){var n=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return n<0?-1:n>0?1:n}function Qf(e,t){Se(2,arguments);var n=De(e),a=De(t),r=Qs(n,a),o=Math.abs(vv(n,a));n.setDate(n.getDate()-r*o);var i=+(Qs(n,a)===-r),l=r*(o-i);return l===0?0:l}function Va(e,t){return Se(2,arguments),De(e).getTime()-De(t).getTime()}var Xs={ceil:Math.ceil,round:Math.round,floor:Math.floor,trunc:function(t){return t<0?Math.ceil(t):Math.floor(t)}},Dv="trunc";function Ir(e){return e?Xs[e]:Xs[Dv]}function Pv(e,t,n){Se(2,arguments);var a=Va(e,t)/Vf;return Ir(void 0)(a)}function Tv(e,t,n){Se(2,arguments);var a=Va(e,t)/Uf;return Ir(void 0)(a)}function el(e){Se(1,arguments);var t=De(e);return t.setHours(23,59,59,999),t}function Sv(e){Se(1,arguments);var t=De(e);return el(t).getTime()===Xi(t).getTime()}function Xf(e,t){Se(2,arguments);var n=De(e),a=De(t),r=hr(n,a),o=Math.abs(Sb(n,a)),i;if(o<1)i=0;else{n.getMonth()===1&&n.getDate()>27&&n.setDate(30),n.setMonth(n.getMonth()-r*o);var l=hr(n,a)===-r;Sv(De(e))&&o===1&&hr(e,a)===1&&(l=!1),i=r*(o-Number(l))}return i===0?0:i}function kv(e,t,n){Se(2,arguments);var a=Xf(e,t)/3;return Ir(void 0)(a)}function Rv(e,t,n){Se(2,arguments);var a=Va(e,t)/1e3;return Ir(void 0)(a)}function Ev(e,t,n){Se(2,arguments);var a=Qf(e,t)/7;return Ir(void 0)(a)}function Mv(e,t){Se(2,arguments);var n=De(e),a=De(t),r=hr(n,a),o=Math.abs(wv(n,a));n.setFullYear(1584),a.setFullYear(1584);var i=hr(n,a)===-r,l=r*(o-Number(i));return l===0?0:l}function Ov(e,t){var n;Se(1,arguments);var a=e||{},r=De(a.start),o=De(a.end),i=o.getTime();if(!(r.getTime()<=i))throw new RangeError("Invalid interval");var l=[],u=r;u.setHours(0,0,0,0);var s=Number((n=void 0)!==null&&n!==void 0?n:1);if(s<1||isNaN(s))throw new RangeError("`options.step` must be a number greater than 1");for(;u.getTime()<=i;)l.push(De(u)),u.setDate(u.getDate()+s),u.setHours(0,0,0,0);return l}function _v(e,t){if(e==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function Iv(e,t){var n,a;Se(1,arguments);var r=De(e);if(isNaN(r.getTime()))throw new RangeError("Invalid time value");var o=String((n=t?.format)!==null&&n!==void 0?n:"extended"),i=String((a=t?.representation)!==null&&a!==void 0?a:"complete");if(o!=="extended"&&o!=="basic")throw new RangeError("format must be 'extended' or 'basic'");if(i!=="date"&&i!=="time"&&i!=="complete")throw new RangeError("representation must be 'date', 'time', or 'complete'");var l="",u="",s=o==="extended"?"-":"",f=o==="extended"?":":"";if(i!=="time"){var c=$t(r.getDate(),2),d=$t(r.getMonth()+1,2),v=$t(r.getFullYear(),4);l="".concat(v).concat(s).concat(d).concat(s).concat(c)}if(i!=="date"){var y=r.getTimezoneOffset();if(y!==0){var g=Math.abs(y),C=$t(Math.floor(g/60),2),h=$t(g%60,2),p=y<0?"+":"-";u="".concat(p).concat(C,":").concat(h)}else u="Z";var m=$t(r.getHours(),2),b=$t(r.getMinutes(),2),k=$t(r.getSeconds(),2),x=l===""?"":"T",w=[m,b,k].join(f);l="".concat(l).concat(x).concat(w).concat(u)}return l}function Av(e){Se(1,arguments);var t=De(e),n=t.getDay();return n}function jv(e){Se(1,arguments);var t=De(e),n=t.getHours();return n}function Lv(e){Se(1,arguments);var t=De(e),n=t.getMinutes();return n}function Bv(e){Se(1,arguments);var t=De(e),n=t.getSeconds();return n}function Nv(e,t){Se(2,arguments);var n=De(e),a=De(t);return n.getTime()===a.getTime()}function Zs(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Kb(e))||t){n&&(e=n);var a=0,r=function(){};return{s:r,n:function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}},e:function(s){throw s},f:r}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
3
3
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o,i=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var s=n.next();return i=s.done,s},e:function(s){l=!0,o=s},f:function(){try{i||n.return==null||n.return()}finally{if(l)throw o}}}}function Zf(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Zf=function(){return!!e})()}function _e(e){var t=Zf();return function(){var n,a=Ys(e);if(t){var r=Ys(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return Qb(this,n)}}var Fv=10,Jf=function(){function e(){Ee(this,e),ne(this,"priority",void 0),ne(this,"subPriority",0)}return Re(e,[{key:"validate",value:function(n,a){return!0}}]),e}(),$v=function(e){Oe(n,e);var t=_e(n);function n(a,r,o,i,l){var u;return Ee(this,n),u=t.call(this),u.value=a,u.validateValue=r,u.setValue=o,u.priority=i,l&&(u.subPriority=l),u}return Re(n,[{key:"validate",value:function(r,o){return this.validateValue(r,this.value,o)}},{key:"set",value:function(r,o,i){return this.setValue(r,o,this.value,i)}}]),n}(Jf),qv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",Fv),ne(ae(a),"subPriority",-1),a}return Re(n,[{key:"set",value:function(r,o){if(o.timestampIsSet)return r;var i=new Date(0);return i.setFullYear(r.getUTCFullYear(),r.getUTCMonth(),r.getUTCDate()),i.setHours(r.getUTCHours(),r.getUTCMinutes(),r.getUTCSeconds(),r.getUTCMilliseconds()),i}}]),n}(Jf),Le=function(){function e(){Ee(this,e),ne(this,"incompatibleTokens",void 0),ne(this,"priority",void 0),ne(this,"subPriority",void 0)}return Re(e,[{key:"run",value:function(n,a,r,o){var i=this.parse(n,a,r,o);return i?{setter:new $v(i.value,this.validate,this.set,this.priority,this.subPriority),rest:i.rest}:null}},{key:"validate",value:function(n,a,r){return!0}}]),e}(),zv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",140),ne(ae(a),"incompatibleTokens",["R","u","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"G":case"GG":case"GGG":return i.era(r,{width:"abbreviated"})||i.era(r,{width:"narrow"});case"GGGGG":return i.era(r,{width:"narrow"});case"GGGG":default:return i.era(r,{width:"wide"})||i.era(r,{width:"abbreviated"})||i.era(r,{width:"narrow"})}}},{key:"set",value:function(r,o,i){return o.era=i,r.setUTCFullYear(i,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(Le),Ze={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},Et={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Je(e,t){return e&&{value:t(e.value),rest:e.rest}}function He(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function Mt(e,t){var n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};var a=n[1]==="+"?1:-1,r=n[2]?parseInt(n[2],10):0,o=n[3]?parseInt(n[3],10):0,i=n[5]?parseInt(n[5],10):0;return{value:a*(r*Vf+o*Uf+i*kb),rest:t.slice(n[0].length)}}function ep(e){return He(Ze.anyDigitsSigned,e)}function Xe(e,t){switch(e){case 1:return He(Ze.singleDigit,t);case 2:return He(Ze.twoDigits,t);case 3:return He(Ze.threeDigits,t);case 4:return He(Ze.fourDigits,t);default:return He(new RegExp("^\\d{1,"+e+"}"),t)}}function wa(e,t){switch(e){case 1:return He(Ze.singleDigitSigned,t);case 2:return He(Ze.twoDigitsSigned,t);case 3:return He(Ze.threeDigitsSigned,t);case 4:return He(Ze.fourDigitsSigned,t);default:return He(new RegExp("^-?\\d{1,"+e+"}"),t)}}function wl(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function tp(e,t){var n=t>0,a=n?t:1-t,r;if(a<=50)r=e||100;else{var o=a+50,i=Math.floor(o/100)*100,l=e>=o%100;r=e+i-(l?100:0)}return n?r:1-r}function np(e){return e%400===0||e%4===0&&e%100!==0}var Vv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",130),ne(ae(a),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){var l=function(s){return{year:s,isTwoDigitYear:o==="yy"}};switch(o){case"y":return Je(Xe(4,r),l);case"yo":return Je(i.ordinalNumber(r,{unit:"year"}),l);default:return Je(Xe(o.length,r),l)}}},{key:"validate",value:function(r,o){return o.isTwoDigitYear||o.year>0}},{key:"set",value:function(r,o,i){var l=r.getUTCFullYear();if(i.isTwoDigitYear){var u=tp(i.year,l);return r.setUTCFullYear(u,0,1),r.setUTCHours(0,0,0,0),r}var s=!("era"in o)||o.era===1?i.year:1-i.year;return r.setUTCFullYear(s,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(Le),Uv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",130),ne(ae(a),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){var l=function(s){return{year:s,isTwoDigitYear:o==="YY"}};switch(o){case"Y":return Je(Xe(4,r),l);case"Yo":return Je(i.ordinalNumber(r,{unit:"year"}),l);default:return Je(Xe(o.length,r),l)}}},{key:"validate",value:function(r,o){return o.isTwoDigitYear||o.year>0}},{key:"set",value:function(r,o,i,l){var u=Rb(r,l);if(i.isTwoDigitYear){var s=tp(i.year,u);return r.setUTCFullYear(s,0,l.firstWeekContainsDate),r.setUTCHours(0,0,0,0),Zi(r,l)}var f=!("era"in o)||o.era===1?i.year:1-i.year;return r.setUTCFullYear(f,0,l.firstWeekContainsDate),r.setUTCHours(0,0,0,0),Zi(r,l)}}]),n}(Le),Wv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",130),ne(ae(a),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o){return wa(o==="R"?4:o.length,r)}},{key:"set",value:function(r,o,i){var l=new Date(0);return l.setUTCFullYear(i,0,4),l.setUTCHours(0,0,0,0),Wf(l)}}]),n}(Le),Gv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",130),ne(ae(a),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o){return wa(o==="u"?4:o.length,r)}},{key:"set",value:function(r,o,i){return r.setUTCFullYear(i,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(Le),Hv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",120),ne(ae(a),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"Q":case"QQ":return Xe(o.length,r);case"Qo":return i.ordinalNumber(r,{unit:"quarter"});case"QQQ":return i.quarter(r,{width:"abbreviated",context:"formatting"})||i.quarter(r,{width:"narrow",context:"formatting"});case"QQQQQ":return i.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return i.quarter(r,{width:"wide",context:"formatting"})||i.quarter(r,{width:"abbreviated",context:"formatting"})||i.quarter(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,o){return o>=1&&o<=4}},{key:"set",value:function(r,o,i){return r.setUTCMonth((i-1)*3,1),r.setUTCHours(0,0,0,0),r}}]),n}(Le),Yv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",120),ne(ae(a),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"q":case"qq":return Xe(o.length,r);case"qo":return i.ordinalNumber(r,{unit:"quarter"});case"qqq":return i.quarter(r,{width:"abbreviated",context:"standalone"})||i.quarter(r,{width:"narrow",context:"standalone"});case"qqqqq":return i.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return i.quarter(r,{width:"wide",context:"standalone"})||i.quarter(r,{width:"abbreviated",context:"standalone"})||i.quarter(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,o){return o>=1&&o<=4}},{key:"set",value:function(r,o,i){return r.setUTCMonth((i-1)*3,1),r.setUTCHours(0,0,0,0),r}}]),n}(Le),Kv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),ne(ae(a),"priority",110),a}return Re(n,[{key:"parse",value:function(r,o,i){var l=function(s){return s-1};switch(o){case"M":return Je(He(Ze.month,r),l);case"MM":return Je(Xe(2,r),l);case"Mo":return Je(i.ordinalNumber(r,{unit:"month"}),l);case"MMM":return i.month(r,{width:"abbreviated",context:"formatting"})||i.month(r,{width:"narrow",context:"formatting"});case"MMMMM":return i.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return i.month(r,{width:"wide",context:"formatting"})||i.month(r,{width:"abbreviated",context:"formatting"})||i.month(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,o){return o>=0&&o<=11}},{key:"set",value:function(r,o,i){return r.setUTCMonth(i,1),r.setUTCHours(0,0,0,0),r}}]),n}(Le),Qv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",110),ne(ae(a),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){var l=function(s){return s-1};switch(o){case"L":return Je(He(Ze.month,r),l);case"LL":return Je(Xe(2,r),l);case"Lo":return Je(i.ordinalNumber(r,{unit:"month"}),l);case"LLL":return i.month(r,{width:"abbreviated",context:"standalone"})||i.month(r,{width:"narrow",context:"standalone"});case"LLLLL":return i.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return i.month(r,{width:"wide",context:"standalone"})||i.month(r,{width:"abbreviated",context:"standalone"})||i.month(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,o){return o>=0&&o<=11}},{key:"set",value:function(r,o,i){return r.setUTCMonth(i,1),r.setUTCHours(0,0,0,0),r}}]),n}(Le);function Xv(e,t,n){Se(2,arguments);var a=De(e),r=pt(t),o=Eb(a,n)-r;return a.setUTCDate(a.getUTCDate()-o*7),a}var Zv=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",100),ne(ae(a),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"w":return He(Ze.week,r);case"wo":return i.ordinalNumber(r,{unit:"week"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=1&&o<=53}},{key:"set",value:function(r,o,i,l){return Zi(Xv(r,i,l),l)}}]),n}(Le);function Jv(e,t){Se(2,arguments);var n=De(e),a=pt(t),r=Mb(n)-a;return n.setUTCDate(n.getUTCDate()-r*7),n}var ey=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",100),ne(ae(a),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"I":return He(Ze.week,r);case"Io":return i.ordinalNumber(r,{unit:"week"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=1&&o<=53}},{key:"set",value:function(r,o,i){return Wf(Jv(r,i))}}]),n}(Le),ty=[31,28,31,30,31,30,31,31,30,31,30,31],ny=[31,29,31,30,31,30,31,31,30,31,30,31],ry=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",90),ne(ae(a),"subPriority",1),ne(ae(a),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"d":return He(Ze.date,r);case"do":return i.ordinalNumber(r,{unit:"date"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){var i=r.getUTCFullYear(),l=np(i),u=r.getUTCMonth();return l?o>=1&&o<=ny[u]:o>=1&&o<=ty[u]}},{key:"set",value:function(r,o,i){return r.setUTCDate(i),r.setUTCHours(0,0,0,0),r}}]),n}(Le),ay=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",90),ne(ae(a),"subpriority",1),ne(ae(a),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"D":case"DD":return He(Ze.dayOfYear,r);case"Do":return i.ordinalNumber(r,{unit:"date"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){var i=r.getUTCFullYear(),l=np(i);return l?o>=1&&o<=366:o>=1&&o<=365}},{key:"set",value:function(r,o,i){return r.setUTCMonth(0,i),r.setUTCHours(0,0,0,0),r}}]),n}(Le);function Dl(e,t,n){var a,r,o,i,l,u,s,f;Se(2,arguments);var c=Gf(),d=pt((a=(r=(o=(i=n?.weekStartsOn)!==null&&i!==void 0?i:n==null||(l=n.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&o!==void 0?o:c.weekStartsOn)!==null&&r!==void 0?r:(s=c.locale)===null||s===void 0||(f=s.options)===null||f===void 0?void 0:f.weekStartsOn)!==null&&a!==void 0?a:0);if(!(d>=0&&d<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var v=De(e),y=pt(t),g=v.getUTCDay(),C=y%7,h=(C+7)%7,p=(h<d?7:0)+y-g;return v.setUTCDate(v.getUTCDate()+p),v}var oy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",90),ne(ae(a),"incompatibleTokens",["D","i","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"E":case"EE":case"EEE":return i.day(r,{width:"abbreviated",context:"formatting"})||i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"});case"EEEEE":return i.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"});case"EEEE":default:return i.day(r,{width:"wide",context:"formatting"})||i.day(r,{width:"abbreviated",context:"formatting"})||i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,o){return o>=0&&o<=6}},{key:"set",value:function(r,o,i,l){return r=Dl(r,i,l),r.setUTCHours(0,0,0,0),r}}]),n}(Le),iy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",90),ne(ae(a),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i,l){var u=function(f){var c=Math.floor((f-1)/7)*7;return(f+l.weekStartsOn+6)%7+c};switch(o){case"e":case"ee":return Je(Xe(o.length,r),u);case"eo":return Je(i.ordinalNumber(r,{unit:"day"}),u);case"eee":return i.day(r,{width:"abbreviated",context:"formatting"})||i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"});case"eeeee":return i.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"});case"eeee":default:return i.day(r,{width:"wide",context:"formatting"})||i.day(r,{width:"abbreviated",context:"formatting"})||i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,o){return o>=0&&o<=6}},{key:"set",value:function(r,o,i,l){return r=Dl(r,i,l),r.setUTCHours(0,0,0,0),r}}]),n}(Le),ly=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",90),ne(ae(a),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i,l){var u=function(f){var c=Math.floor((f-1)/7)*7;return(f+l.weekStartsOn+6)%7+c};switch(o){case"c":case"cc":return Je(Xe(o.length,r),u);case"co":return Je(i.ordinalNumber(r,{unit:"day"}),u);case"ccc":return i.day(r,{width:"abbreviated",context:"standalone"})||i.day(r,{width:"short",context:"standalone"})||i.day(r,{width:"narrow",context:"standalone"});case"ccccc":return i.day(r,{width:"narrow",context:"standalone"});case"cccccc":return i.day(r,{width:"short",context:"standalone"})||i.day(r,{width:"narrow",context:"standalone"});case"cccc":default:return i.day(r,{width:"wide",context:"standalone"})||i.day(r,{width:"abbreviated",context:"standalone"})||i.day(r,{width:"short",context:"standalone"})||i.day(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,o){return o>=0&&o<=6}},{key:"set",value:function(r,o,i,l){return r=Dl(r,i,l),r.setUTCHours(0,0,0,0),r}}]),n}(Le);function sy(e,t){Se(2,arguments);var n=pt(t);n%7===0&&(n=n-7);var a=1,r=De(e),o=r.getUTCDay(),i=n%7,l=(i+7)%7,u=(l<a?7:0)+n-o;return r.setUTCDate(r.getUTCDate()+u),r}var uy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",90),ne(ae(a),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){var l=function(s){return s===0?7:s};switch(o){case"i":case"ii":return Xe(o.length,r);case"io":return i.ordinalNumber(r,{unit:"day"});case"iii":return Je(i.day(r,{width:"abbreviated",context:"formatting"})||i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"}),l);case"iiiii":return Je(i.day(r,{width:"narrow",context:"formatting"}),l);case"iiiiii":return Je(i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"}),l);case"iiii":default:return Je(i.day(r,{width:"wide",context:"formatting"})||i.day(r,{width:"abbreviated",context:"formatting"})||i.day(r,{width:"short",context:"formatting"})||i.day(r,{width:"narrow",context:"formatting"}),l)}}},{key:"validate",value:function(r,o){return o>=1&&o<=7}},{key:"set",value:function(r,o,i){return r=sy(r,i),r.setUTCHours(0,0,0,0),r}}]),n}(Le),cy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",80),ne(ae(a),"incompatibleTokens",["b","B","H","k","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"a":case"aa":case"aaa":return i.dayPeriod(r,{width:"abbreviated",context:"formatting"})||i.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaaa":return i.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaa":default:return i.dayPeriod(r,{width:"wide",context:"formatting"})||i.dayPeriod(r,{width:"abbreviated",context:"formatting"})||i.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,o,i){return r.setUTCHours(wl(i),0,0,0),r}}]),n}(Le),dy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",80),ne(ae(a),"incompatibleTokens",["a","B","H","k","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"b":case"bb":case"bbb":return i.dayPeriod(r,{width:"abbreviated",context:"formatting"})||i.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbbb":return i.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbb":default:return i.dayPeriod(r,{width:"wide",context:"formatting"})||i.dayPeriod(r,{width:"abbreviated",context:"formatting"})||i.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,o,i){return r.setUTCHours(wl(i),0,0,0),r}}]),n}(Le),fy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",80),ne(ae(a),"incompatibleTokens",["a","b","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"B":case"BB":case"BBB":return i.dayPeriod(r,{width:"abbreviated",context:"formatting"})||i.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBBB":return i.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBB":default:return i.dayPeriod(r,{width:"wide",context:"formatting"})||i.dayPeriod(r,{width:"abbreviated",context:"formatting"})||i.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,o,i){return r.setUTCHours(wl(i),0,0,0),r}}]),n}(Le),py=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",70),ne(ae(a),"incompatibleTokens",["H","K","k","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"h":return He(Ze.hour12h,r);case"ho":return i.ordinalNumber(r,{unit:"hour"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=1&&o<=12}},{key:"set",value:function(r,o,i){var l=r.getUTCHours()>=12;return l&&i<12?r.setUTCHours(i+12,0,0,0):!l&&i===12?r.setUTCHours(0,0,0,0):r.setUTCHours(i,0,0,0),r}}]),n}(Le),my=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",70),ne(ae(a),"incompatibleTokens",["a","b","h","K","k","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"H":return He(Ze.hour23h,r);case"Ho":return i.ordinalNumber(r,{unit:"hour"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=0&&o<=23}},{key:"set",value:function(r,o,i){return r.setUTCHours(i,0,0,0),r}}]),n}(Le),hy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",70),ne(ae(a),"incompatibleTokens",["h","H","k","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"K":return He(Ze.hour11h,r);case"Ko":return i.ordinalNumber(r,{unit:"hour"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=0&&o<=11}},{key:"set",value:function(r,o,i){var l=r.getUTCHours()>=12;return l&&i<12?r.setUTCHours(i+12,0,0,0):r.setUTCHours(i,0,0,0),r}}]),n}(Le),gy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",70),ne(ae(a),"incompatibleTokens",["a","b","h","H","K","t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"k":return He(Ze.hour24h,r);case"ko":return i.ordinalNumber(r,{unit:"hour"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=1&&o<=24}},{key:"set",value:function(r,o,i){var l=i<=24?i%24:i;return r.setUTCHours(l,0,0,0),r}}]),n}(Le),by=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",60),ne(ae(a),"incompatibleTokens",["t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"m":return He(Ze.minute,r);case"mo":return i.ordinalNumber(r,{unit:"minute"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=0&&o<=59}},{key:"set",value:function(r,o,i){return r.setUTCMinutes(i,0,0),r}}]),n}(Le),vy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",50),ne(ae(a),"incompatibleTokens",["t","T"]),a}return Re(n,[{key:"parse",value:function(r,o,i){switch(o){case"s":return He(Ze.second,r);case"so":return i.ordinalNumber(r,{unit:"second"});default:return Xe(o.length,r)}}},{key:"validate",value:function(r,o){return o>=0&&o<=59}},{key:"set",value:function(r,o,i){return r.setUTCSeconds(i,0),r}}]),n}(Le),yy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",30),ne(ae(a),"incompatibleTokens",["t","T"]),a}return Re(n,[{key:"parse",value:function(r,o){var i=function(u){return Math.floor(u*Math.pow(10,-o.length+3))};return Je(Xe(o.length,r),i)}},{key:"set",value:function(r,o,i){return r.setUTCMilliseconds(i),r}}]),n}(Le),Cy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",10),ne(ae(a),"incompatibleTokens",["t","T","x"]),a}return Re(n,[{key:"parse",value:function(r,o){switch(o){case"X":return Mt(Et.basicOptionalMinutes,r);case"XX":return Mt(Et.basic,r);case"XXXX":return Mt(Et.basicOptionalSeconds,r);case"XXXXX":return Mt(Et.extendedOptionalSeconds,r);case"XXX":default:return Mt(Et.extended,r)}}},{key:"set",value:function(r,o,i){return o.timestampIsSet?r:new Date(r.getTime()-i)}}]),n}(Le),xy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",10),ne(ae(a),"incompatibleTokens",["t","T","X"]),a}return Re(n,[{key:"parse",value:function(r,o){switch(o){case"x":return Mt(Et.basicOptionalMinutes,r);case"xx":return Mt(Et.basic,r);case"xxxx":return Mt(Et.basicOptionalSeconds,r);case"xxxxx":return Mt(Et.extendedOptionalSeconds,r);case"xxx":default:return Mt(Et.extended,r)}}},{key:"set",value:function(r,o,i){return o.timestampIsSet?r:new Date(r.getTime()-i)}}]),n}(Le),wy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",40),ne(ae(a),"incompatibleTokens","*"),a}return Re(n,[{key:"parse",value:function(r){return ep(r)}},{key:"set",value:function(r,o,i){return[new Date(i*1e3),{timestampIsSet:!0}]}}]),n}(Le),Dy=function(e){Oe(n,e);var t=_e(n);function n(){var a;Ee(this,n);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return a=t.call.apply(t,[this].concat(o)),ne(ae(a),"priority",20),ne(ae(a),"incompatibleTokens","*"),a}return Re(n,[{key:"parse",value:function(r){return ep(r)}},{key:"set",value:function(r,o,i){return[new Date(i),{timestampIsSet:!0}]}}]),n}(Le),Py={G:new zv,y:new Vv,Y:new Uv,R:new Wv,u:new Gv,Q:new Hv,q:new Yv,M:new Kv,L:new Qv,w:new Zv,I:new ey,d:new ry,D:new ay,E:new oy,e:new iy,c:new ly,i:new uy,a:new cy,b:new dy,B:new fy,h:new py,H:new my,K:new hy,k:new gy,m:new by,s:new vy,S:new yy,X:new Cy,x:new xy,t:new wy,T:new Dy},Ty=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Sy=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,ky=/^'([^]*?)'?$/,Ry=/''/g,Ey=/\S/,My=/[a-zA-Z]/;function Oy(e,t,n,a){var r,o,i,l,u,s,f,c,d,v,y,g,C,h,p,m,b,k;Se(3,arguments);var x=String(e),w=String(t),P=Gf(),S=(r=(o=a?.locale)!==null&&o!==void 0?o:P.locale)!==null&&r!==void 0?r:xl;if(!S.match)throw new RangeError("locale must contain match property");var R=pt((i=(l=(u=(s=a?.firstWeekContainsDate)!==null&&s!==void 0?s:a==null||(f=a.locale)===null||f===void 0||(c=f.options)===null||c===void 0?void 0:c.firstWeekContainsDate)!==null&&u!==void 0?u:P.firstWeekContainsDate)!==null&&l!==void 0?l:(d=P.locale)===null||d===void 0||(v=d.options)===null||v===void 0?void 0:v.firstWeekContainsDate)!==null&&i!==void 0?i:1);if(!(R>=1&&R<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var E=pt((y=(g=(C=(h=a?.weekStartsOn)!==null&&h!==void 0?h:a==null||(p=a.locale)===null||p===void 0||(m=p.options)===null||m===void 0?void 0:m.weekStartsOn)!==null&&C!==void 0?C:P.weekStartsOn)!==null&&g!==void 0?g:(b=P.locale)===null||b===void 0||(k=b.options)===null||k===void 0?void 0:k.weekStartsOn)!==null&&y!==void 0?y:0);if(!(E>=0&&E<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(w==="")return x===""?De(n):new Date(NaN);var _={firstWeekContainsDate:R,weekStartsOn:E,locale:S},M=[new qv],A=w.match(Sy).map(function(V){var G=V[0];if(G in Us){var J=Us[G];return J(V,S.formatLong)}return V}).join("").match(Ty),B=[],q=Zs(A),W;try{var z=function(){var G=W.value;!(a!=null&&a.useAdditionalWeekYearTokens)&&Ob(G)&&Ws(G,w,e),!(a!=null&&a.useAdditionalDayOfYearTokens)&&_b(G)&&Ws(G,w,e);var J=G[0],fe=Py[J];if(fe){var Q=fe.incompatibleTokens;if(Array.isArray(Q)){var Z=B.find(function(Ce){return Q.includes(Ce.token)||Ce.token===J});if(Z)throw new RangeError("The format string mustn't contain `".concat(Z.fullToken,"` and `").concat(G,"` at the same time"))}else if(fe.incompatibleTokens==="*"&&B.length>0)throw new RangeError("The format string mustn't contain `".concat(G,"` and any other token at the same time"));B.push({token:J,fullToken:G});var ge=fe.run(x,G,S.match,_);if(!ge)return{v:new Date(NaN)};M.push(ge.setter),x=ge.rest}else{if(J.match(My))throw new RangeError("Format string contains an unescaped latin alphabet character `"+J+"`");if(G==="''"?G="'":J==="'"&&(G=_y(G)),x.indexOf(G)===0)x=x.slice(G.length);else return{v:new Date(NaN)}}};for(q.s();!(W=q.n()).done;){var Y=z();if(Og(Y)==="object")return Y.v}}catch(V){q.e(V)}finally{q.f()}if(x.length>0&&Ey.test(x))return new Date(NaN);var H=M.map(function(V){return V.priority}).sort(function(V,G){return G-V}).filter(function(V,G,J){return J.indexOf(V)===G}).map(function(V){return M.filter(function(G){return G.priority===V}).sort(function(G,J){return J.subPriority-G.subPriority})}).map(function(V){return V[0]}),T=De(n);if(isNaN(T.getTime()))return new Date(NaN);var N=Ib(T,Qi(T)),$={},j=Zs(H),I;try{for(j.s();!(I=j.n()).done;){var L=I.value;if(!L.validate(N,_))return new Date(NaN);var F=L.set(N,$,_);Array.isArray(F)?(N=F[0],_v($,F[1])):N=F}}catch(V){j.e(V)}finally{j.f()}return N}function _y(e){return e.match(ky)[1].replace(Ry,"'")}function Js(e){Se(1,arguments);var t=De(e);return t.setMinutes(0,0,0),t}function Iy(e,t){Se(2,arguments);var n=Js(e),a=Js(t);return n.getTime()===a.getTime()}function Ay(e,t){Se(2,arguments);var n=De(e),a=De(t);return n.getFullYear()===a.getFullYear()}function jy(e,t){Se(2,arguments);var n=De(e),a=pt(t);return n.setDate(a),n}function Ly(e,t){Se(2,arguments);var n=De(e),a=pt(t);return n.setHours(a),n}function By(e,t){Se(2,arguments);var n=De(e),a=pt(t);return n.setMinutes(a),n}function Ny(e,t){Se(2,arguments);var n=De(e),a=pt(t);return n.setSeconds(a),n}function rp({children:e=null,...t}){const{t:n}=ut(),{api:a}=ft(),{blocklet:r}=dn(),o=r?.settings?.autoCheckUpdate,i=async s=>{await a.updateAutoCheckUpdate({input:{did:r.meta.did,autoCheckUpdate:s}})},l=async()=>{try{const s=!o?.enabled;await i({enabled:s}),je.success(n(s?"storage.spaces.autoCheckUpdate.enabled":"storage.spaces.autoCheckUpdate.disabled"))}catch(s){je.error(s.message)}},u=!!o?.enabled;return D.jsxs(le,{sx:{display:"flex",flexDirection:"row",alignItems:"center"},children:[e,D.jsx(_t,{title:n("storage.spaces.autoCheckUpdate.title"),arrow:!0,placement:"right",children:D.jsx("div",{children:D.jsx(Pb,{checked:u,onChange:l,name:"enableWelcomePage",style:{...t.style,zoom:.8}})})})]})}rp.propTypes={children:K.any};var bo={},vo={exports:{}},eu;function Ge(){return eu||(eu=1,function(e){function t(){return e.exports=t=Object.assign?Object.assign.bind():function(n){for(var a=1;a<arguments.length;a++){var r=arguments[a];for(var o in r)({}).hasOwnProperty.call(r,o)&&(n[o]=r[o])}return n},e.exports.__esModule=!0,e.exports.default=e.exports,t.apply(null,arguments)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports}(vo)),vo.exports}var zn={},yo={},Co={},xo={},tu;function Fy(){return tu||(tu=1,function(e){var t=re();Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=t(Ge()),a=t(If()),r=t(Pe()),o=t(ze()),i=sn();function l(s){var f=(0,i.useTheme)();return r.default.createElement("div",{ref:s.forwardedRef,style:{display:"table",width:"100%",height:"100%",backgroundColor:f.palette.background.paper,opacity:.7}},r.default.createElement("div",{style:{display:"table-cell",width:"100%",height:"100%",verticalAlign:"middle",textAlign:"center"}},r.default.createElement(a.default,null)))}l.propTypes={theme:o.default.any};var u=r.default.forwardRef(function(f,c){return r.default.createElement(l,(0,n.default)({},f,{forwardedRef:c}))});e.default=u}(xo)),xo}var wo={},Do={},wt={},Po={exports:{}},To={exports:{}},So={exports:{}},nu;function $y(){return nu||(nu=1,function(e){var t=Kt().default;function n(a,r){if(t(a)!="object"||!a)return a;var o=a[Symbol.toPrimitive];if(o!==void 0){var i=o.call(a,r||"default");if(t(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(a)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports}(So)),So.exports}var ru;function ap(){return ru||(ru=1,function(e){var t=Kt().default,n=$y();function a(r){var o=n(r,"string");return t(o)=="symbol"?o:o+""}e.exports=a,e.exports.__esModule=!0,e.exports.default=e.exports}(To)),To.exports}var au;function nt(){return au||(au=1,function(e){var t=ap();function n(a,r,o){return(r=t(r))in a?Object.defineProperty(a,r,{value:o,enumerable:!0,configurable:!0,writable:!0}):a[r]=o,a}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports}(Po)),Po.exports}const qy={},ou=e=>{let t;const n=new Set,a=(f,c)=>{const d=typeof f=="function"?f(t):f;if(!Object.is(d,t)){const v=t;t=c??(typeof d!="object"||d===null)?d:Object.assign({},t,d),n.forEach(y=>y(t,v))}},r=()=>t,u={setState:a,getState:r,getInitialState:()=>s,subscribe:f=>(n.add(f),()=>n.delete(f)),destroy:()=>{(qy?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},s=t=e(a,r,u);return u},op=e=>e?ou(e):ou,{useDebugValue:zy}=Me,{useSyncExternalStoreWithSelector:Vy}=zf,Uy=e=>e;function ip(e,t=Uy,n){const a=Vy(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return zy(a),a}const iu=e=>{const t=typeof e=="function"?op(e):e,n=(a,r)=>ip(t,a,r);return Object.assign(n,t),n},lp=e=>e?iu(e):iu;var Wy=e=>lp(e);const Gy=Object.freeze(Object.defineProperty({__proto__:null,create:lp,createStore:op,default:Wy,useStore:ip},Symbol.toStringTag,{value:"Module"})),Hy=ln(Gy),{useDebugValue:Yy}=Me,{useSyncExternalStoreWithSelector:Ky}=zf,Qy=e=>e;function Xy(e,t=Qy,n){const a=Ky(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return Yy(a),a}const{createElement:Zy,createContext:Jy,useContext:lu,useMemo:eC,useRef:tC}=Me;function nC(){const e=Jy(void 0);return{Provider:({createStore:r,children:o})=>{const i=tC();return i.current||(i.current=r()),Zy(e.Provider,{value:i.current},o)},useStore:(r,o)=>{const i=lu(e);if(!i)throw new Error("Seems like you have not used zustand provider as an ancestor.");return Xy(i,r,o)},useStoreApi:()=>{const r=lu(e);if(!r)throw new Error("Seems like you have not used zustand provider as an ancestor.");return eC(()=>({...r}),[r])}}}const rC=Object.freeze(Object.defineProperty({__proto__:null,default:nC},Symbol.toStringTag,{value:"Module"})),aC=ln(rC);var Ur={exports:{}},ha={exports:{}},oC=ha.exports,su;function iC(){return su||(su=1,function(e,t){(function(n,a){e.exports=a()})(oC,function(){var n=typeof Promise=="function",a=function(w){if(typeof globalThis=="object")return globalThis;Object.defineProperty(w,"typeDetectGlobalObject",{get:function(){return this},configurable:!0});var P=typeDetectGlobalObject;return delete w.typeDetectGlobalObject,P}(Object.prototype),r=typeof Symbol<"u",o=typeof Map<"u",i=typeof Set<"u",l=typeof WeakMap<"u",u=typeof WeakSet<"u",s=typeof DataView<"u",f=r&&typeof Symbol.iterator<"u",c=r&&typeof Symbol.toStringTag<"u",d=i&&typeof Set.prototype.entries=="function",v=o&&typeof Map.prototype.entries=="function",y=d&&Object.getPrototypeOf(new Set().entries()),g=v&&Object.getPrototypeOf(new Map().entries()),C=f&&typeof Array.prototype[Symbol.iterator]=="function",h=C&&Object.getPrototypeOf([][Symbol.iterator]()),p=f&&typeof String.prototype[Symbol.iterator]=="function",m=p&&Object.getPrototypeOf(""[Symbol.iterator]()),b=8,k=-1;function x(w){var P=typeof w;if(P!=="object")return P;if(w===null)return"null";if(w===a)return"global";if(Array.isArray(w)&&(c===!1||!(Symbol.toStringTag in w)))return"Array";if(typeof window=="object"&&window!==null){if(typeof window.location=="object"&&w===window.location)return"Location";if(typeof window.document=="object"&&w===window.document)return"Document";if(typeof window.navigator=="object"){if(typeof window.navigator.mimeTypes=="object"&&w===window.navigator.mimeTypes)return"MimeTypeArray";if(typeof window.navigator.plugins=="object"&&w===window.navigator.plugins)return"PluginArray"}if((typeof window.HTMLElement=="function"||typeof window.HTMLElement=="object")&&w instanceof window.HTMLElement){if(w.tagName==="BLOCKQUOTE")return"HTMLQuoteElement";if(w.tagName==="TD")return"HTMLTableDataCellElement";if(w.tagName==="TH")return"HTMLTableHeaderCellElement"}}var S=c&&w[Symbol.toStringTag];if(typeof S=="string")return S;var R=Object.getPrototypeOf(w);return R===RegExp.prototype?"RegExp":R===Date.prototype?"Date":n&&R===Promise.prototype?"Promise":i&&R===Set.prototype?"Set":o&&R===Map.prototype?"Map":u&&R===WeakSet.prototype?"WeakSet":l&&R===WeakMap.prototype?"WeakMap":s&&R===DataView.prototype?"DataView":o&&R===g?"Map Iterator":i&&R===y?"Set Iterator":C&&R===h?"Array Iterator":p&&R===m?"String Iterator":R===null?"Object":Object.prototype.toString.call(w).slice(b,k)}return x})}(ha)),ha.exports}var uu;function sp(){if(uu)return Ur.exports;uu=1;/*!
|
|
4
4
|
* deep-eql
|
|
5
5
|
* Copyright(c) 2013 Jake Luer <jake@alogicalparadox.com>
|
|
@@ -346,7 +346,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
346
346
|
.ux-dialog_closeButton {
|
|
347
347
|
margin: 0;
|
|
348
348
|
}
|
|
349
|
-
`,rM=O.lazy(()=>gb(()=>import("./index-
|
|
349
|
+
`,rM=O.lazy(()=>gb(()=>import("./index-B2HJDbWz.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13])).then(e=>({default:e.Uploader}))),aM="/blocklet/component/upload",yf=[".html",".htm",".tgz",".zip"],oM=Number(window.env?.MAX_UPLOAD_FILE_SIZE)||be.MAX_UPLOAD_FILE_SIZE,iM=oM*1024*1024;function Mh({did:e,prefix:t,headers:n=()=>({}),onUploaded:a=zs,open:r=!1,onClose:o=zs}){const{t:i,locale:l}=ut(),u=O.useRef(null),s=O.useCallback(f=>{const{status:c,data:d}=f;if(c===200){a(d);return}je.error(i("blocklet.component.addComponentTip.uploadFailed"))},[a,i]);return O.useEffect(()=>{r?u.current?.open():u.current?.close()},[r]),D.jsx(lM,{id:`component-uploader-${e}`,children:D.jsx(rM,{ref:u,locale:l,popup:!0,onUploadFinish:s,plugins:[],onClose:o,installerProps:{disabled:!0},apiPathProps:{uploader:yr(t,aM,e),disableMediaKitPrefix:!0,disableMediaKitStatus:!0},coreProps:{restrictions:{allowedFileTypes:yf,maxFileSize:iM,maxNumberOfFiles:1}},tusProps:{headers:n},dashboardProps:{note:i("blocklet.component.addComponentTip.allowedFileTypes",{types:yf.map(f=>f.replace(".","")).join(", ")})}})},`component-uploader-${e}`)}Mh.propTypes={did:K.string.isRequired,prefix:K.string.isRequired,open:K.bool,headers:K.func,onUploaded:K.func,onClose:K.func};const lM=oe(le)`
|
|
350
350
|
.uploader-wrapper {
|
|
351
351
|
display: inline-flex;
|
|
352
352
|
position: relative;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{br as e,bs as c,bt as t,bu as o}from"./vendor-mui-core-
|
|
1
|
+
import{br as e,bs as c,bt as t,bu as o}from"./vendor-mui-core-CAIaAq-_.js";import{c as n}from"./index-l5234Nwn.js";const a=[{value:n.WHO_CAN_ACCESS.ALL,icon:e,title:{zh:"面向所有人",en:"Open to Everyone"},description:{zh:"任何人都可以访问应用而不需要身份验证。",en:"Anyone can access this blocklet without authenticating."}},{value:n.WHO_CAN_ACCESS.INVITED,icon:c,title:{zh:"仅限受邀",en:"Invite-Only Access"},description:{zh:"仅限受邀用户可访问应用。",en:"Only invited members can access."}},{value:n.WHO_CAN_ACCESS.ADMIN,icon:t,title:{zh:"仅限拥有者 & 管理员",en:"Owner & Admin Access."},description:{zh:"仅限拥有者或管理员访问应用。",en:"Only the owner or an admin can access it."}},{value:n.WHO_CAN_ACCESS.OWNER,icon:o,title:{zh:"仅限拥有者",en:"Owner-Only Access"},description:{zh:"仅限拥有者访问应用。",en:"Only the blocklet owner can access it."}}];export{a as A};
|