@abtnode/blocklet-services 1.16.44-beta-20250518-020443-77ba168f → 1.16.44-beta-20250520-004606-6cd8a0d3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{AdapterDayjs-YbaNvT9I.js → AdapterDayjs-D2uo6EnV.js} +1 -1
- package/dist/assets/{ArrowDropDown-xgs4N3Rf.js → ArrowDropDown-PfUV1pZb.js} +1 -1
- package/dist/assets/{CheckCircle-JXD6tKIa.js → CheckCircle-zHdz-yvJ.js} +1 -1
- package/dist/assets/{ChevronLeft-D0eko_T8.js → ChevronLeft-3zBX65MM.js} +1 -1
- package/dist/assets/{ChevronRight-CQY9Ni7X.js → ChevronRight-BXgoqDfE.js} +1 -1
- package/dist/assets/{DeleteOutline-BEGOj_wq.js → DeleteOutline-BFB4Yy3c.js} +1 -1
- package/dist/assets/{Done-BUJJNjlP.js → Done-DboXobnH.js} +1 -1
- package/dist/assets/{Download-DdZEsxmZ.js → Download-X3XR698Z.js} +1 -1
- package/dist/assets/{Edit-vxeVwrqO.js → Edit-Cl3SK-FJ.js} +1 -1
- package/dist/assets/{Error-C-RD4e9g.js → Error-CPi5ht0i.js} +1 -1
- package/dist/assets/{ExpandLess-CmqG9SE7.js → ExpandLess-D7OENe4H.js} +1 -1
- package/dist/assets/{Google-B7PA4qF8.js → Google-Bl_7h7C7.js} +1 -1
- package/dist/assets/{InfoOutlined-BIr5nkjV.js → InfoOutlined-BGorl_CI.js} +1 -1
- package/dist/assets/{Launch-KvZQI_SA.js → Launch-5hxRq_We.js} +1 -1
- package/dist/assets/{LaunchOutlined-ClxZU_tj.js → LaunchOutlined-DCxTlWgy.js} +1 -1
- package/dist/assets/{MoreHoriz-H8rabTmY.js → MoreHoriz-Bncapj_R.js} +1 -1
- package/dist/assets/{PlayArrow-CmxnItFZ.js → PlayArrow-B19IPFeo.js} +1 -1
- package/dist/assets/{TuneOutlined-DmhFMgM-.js → TuneOutlined-OuRuIP5i.js} +1 -1
- package/dist/assets/{ViewList-DXk3qGFU.js → ViewList-Bj0HBob4.js} +1 -1
- package/dist/assets/{access-control-DupKwlXi.js → access-control-BVDJgnnG.js} +1 -1
- package/dist/assets/{actions-V9hjjowb.js → actions-B2RmHKJh.js} +1 -1
- package/dist/assets/{add-component-core-hWyA0oyr.js → add-component-core-BLsjc3lE.js} +15 -15
- package/dist/assets/add-resource-B0dZoJA8.js +1 -0
- package/dist/assets/{addon-DtaZ0TB3.js → addon-y9ZXCN0H.js} +1 -1
- package/dist/assets/{advanced-EG10mbK7.js → advanced-5oQIoiUN.js} +2 -2
- package/dist/assets/appearance-58f9Dbcn.js +1 -0
- package/dist/assets/{ar-2yn9i2dw.js → ar-C_INBNFD.js} +1 -1
- package/dist/assets/{audit-logs-WqpwTrlM.js → audit-logs-fYqimPuZ.js} +3 -3
- package/dist/assets/{authorize-DEmcifx9.js → authorize-DC-SAlai.js} +1 -1
- package/dist/assets/{base32-BPfgmw66.js → base32-B42OVABo.js} +1 -1
- package/dist/assets/{branding-CJx0esf8.js → branding-DwHt5TFQ.js} +2 -2
- package/dist/assets/{branding-DFhJVvNX.js → branding-eOJeN-jW.js} +1 -1
- package/dist/assets/{bundle-avatar-BbIyJr7P.js → bundle-avatar-BoczFLNt.js} +1 -1
- package/dist/assets/{button-m03GMAJs.js → button-C6SqoOU8.js} +1 -1
- package/dist/assets/{click-to-copy-DmYkL7Ui.js → click-to-copy-ClNoTzk4.js} +1 -1
- package/dist/assets/{collapse-FsvH0gRe.js → collapse-Dz_izL9k.js} +1 -1
- package/dist/assets/complete-B4rMuRkI.js +39 -0
- package/dist/assets/{component-BK7TQ5JB.js → component-BzBSZbVF.js} +1 -1
- package/dist/assets/{config-Cc-40NNR.js → config-CPFIXwk-.js} +2 -2
- package/dist/assets/{config-navigation-DH93rn-r.js → config-navigation-DdXZFw0Z.js} +3 -3
- package/dist/assets/{config-space-CxEu1ku3.js → config-space-CSZvQTns.js} +1 -1
- package/dist/assets/{config-Dl_53WnU.js → config-tQft4lvg.js} +1 -1
- package/dist/assets/{confirm-DFwkkng7.js → confirm-hm6dpNbC.js} +1 -1
- package/dist/assets/{connect-CX2tLgwf.js → connect-BeFPxq9a.js} +1 -1
- package/dist/assets/{connect-to-jqzhxL2-.js → connect-to-Dwm_wvvo.js} +1 -1
- package/dist/assets/{connect-tnlrEGOa.js → connect-wIDYWNYf.js} +1 -1
- package/dist/assets/dashboard-BwU59vns.js +239 -0
- package/dist/assets/{de-CEKbJD3-.js → de-EYXdEi3Y.js} +1 -1
- package/dist/assets/{delete-confirm-cVLum8Er.js → delete-confirm-BRkmB2tO.js} +1 -1
- package/dist/assets/{did-address-BI9LYTx-.js → did-address-Ddg6Is1P.js} +1 -1
- package/dist/assets/domain-action-card-BnxgZfnv.js +28 -0
- package/dist/assets/{domain-7fDuc1TD.js → domain-hqA29r7o.js} +1 -1
- package/dist/assets/domains-BkjwRhdu.js +1 -0
- package/dist/assets/{dot-BB5occkV.js → dot-CdVWOAIG.js} +2 -2
- package/dist/assets/{email-9P_7A90f.js → email-DhpxVPpg.js} +2 -2
- package/dist/assets/{es-dvMygD-W.js → es-3jqVamM8.js} +1 -1
- package/dist/assets/{exchange-passport-CfsGf2j7.js → exchange-passport-3R6TCPya.js} +1 -1
- package/dist/assets/{fr-BvFd5xp9.js → fr-CUcR-yNv.js} +1 -1
- package/dist/assets/{fuel-DOrn9jKI.js → fuel-C3Ao9T8_.js} +1 -1
- package/dist/assets/{gen-access-key-Ddbn2A92.js → gen-access-key-B5etX4Ba.js} +1 -1
- package/dist/assets/{get-safe-url-BcH2iukm.js → get-safe-url-DP-rZc23.js} +1 -1
- package/dist/assets/{get-safe-url-OaLLn0UN.js → get-safe-url-XcLmS0yc.js} +1 -1
- package/dist/assets/hi-DNldhMTl.js +5 -0
- package/dist/assets/{home-CJ28zTIJ.js → home-DtuKHXKD.js} +1 -1
- package/dist/assets/{id-B1Mq_eQI.js → id-CmSIFhX-.js} +1 -1
- package/dist/assets/iframe-BHwYGTAS.js +1 -0
- package/dist/assets/{index-BBKe69-Z.js → index-B6jePIag.js} +1 -1
- package/dist/assets/{index-d-GNQQ24.js → index-BKdJfp9x.js} +1 -1
- package/dist/assets/{index-C2sWzOOC.js → index-BULZWXKq.js} +1 -1
- package/dist/assets/{index-BiIZw9KG.js → index-BzItMezw.js} +7 -7
- package/dist/assets/{index-DwswX2WL.js → index-C0w1ugDi.js} +1 -1
- package/dist/assets/{index-D-mbJPLJ.js → index-C5_3pYA_.js} +1 -1
- package/dist/assets/{index-DfO-sKO8.js → index-C61DBznM.js} +1 -1
- package/dist/assets/{index-DxVAvQEw.js → index-CFtGBtAw.js} +1 -1
- package/dist/assets/{index-BQ8PIDUu.js → index-CVDucF7E.js} +7 -7
- package/dist/assets/{index-D3iGbfL9.js → index-Cb7iBSvd.js} +1 -1
- package/dist/assets/{index-DPmpjBeE.js → index-Cd3oZl-N.js} +4 -4
- package/dist/assets/{index-BmR2oN4p.js → index-CmOE3ceE.js} +5 -5
- package/dist/assets/{index-BoYbZj00.js → index-DAEEDx1o.js} +9 -9
- package/dist/assets/{index-Bi8r1T8R.js → index-DBsI6F1Z.js} +3 -3
- package/dist/assets/{index-CeU2W9XY.js → index-DaoLXOw4.js} +8 -8
- package/dist/assets/{index-DK8EXxrQ.js → index-Dm4t4XH1.js} +2 -2
- package/dist/assets/{index-BEVde8cE.js → index-ND58NXzr.js} +1 -1
- package/dist/assets/index-ToeWiBUL.js +55 -0
- package/dist/assets/{index-BXdw6keY.js → index-kszsTfNH.js} +1 -1
- package/dist/assets/index-sAnn-Wqb.js +10 -0
- package/dist/assets/{invitation-DmNSx8lT.js → invitation-qFWETxSc.js} +2 -2
- package/dist/assets/{invite-BRV4-5NB.js → invite-Bg2Azggi.js} +1 -1
- package/dist/assets/{issue-passport-DVYjG5SL.js → issue-passport-DtnZs7_A.js} +1 -1
- package/dist/assets/{item-F_qGx0RW.js → item-BYt6Ny1o.js} +2 -2
- package/dist/assets/{ja-CCKVmbEX.js → ja-D-vAGmH7.js} +1 -1
- package/dist/assets/{ko-A_w8tIEg.js → ko-DpdamIdS.js} +1 -1
- package/dist/assets/{landing-page-CUrvCtHZ.js → landing-page-BiznyWTw.js} +1 -1
- package/dist/assets/{layout-Dkaou_pj.js → layout-DE99yYfx.js} +1 -1
- package/dist/assets/list-BkVwpX1t.js +236 -0
- package/dist/assets/{list-Dq129hfR.js → list-UaF9rEdO.js} +2 -2
- package/dist/assets/localization-CTcPOuKl.js +1 -0
- package/dist/assets/{log-C_uY3dq9.js → log-D-KC9F0b.js} +1 -1
- package/dist/assets/{logger-BYg6vYBA.js → logger-GX3OECJW.js} +1 -1
- package/dist/assets/{login-D8Wk5up1.js → login-D5-7Lt94.js} +1 -1
- package/dist/assets/{login-oauth-callback-DMou-vp-.js → login-oauth-callback-PDI2Klq3.js} +1 -1
- package/dist/assets/{logo-uploader-CHTXjHOW.js → logo-uploader-BNZB1sug.js} +3 -3
- package/dist/assets/{lost-passport-DlnOD9y-.js → lost-passport-kNOXw46l.js} +1 -1
- package/dist/assets/{open-window-CuyFfntO.js → open-window-BEzzIgKH.js} +1 -1
- package/dist/assets/{overview-B451HiB6.js → overview-qlJHwq1E.js} +2 -2
- package/dist/assets/{page-header-DpNvpd52.js → page-header-D9UEVC59.js} +1 -1
- package/dist/assets/{passport-item-BWCHjFYy.js → passport-item-C7W2OqHa.js} +1 -1
- package/dist/assets/{permission-Cnn9EYOW.js → permission-KYy-A4oZ.js} +1 -1
- package/dist/assets/{preferences-Cqm2olsT.js → preferences-DXEo6kgA.js} +1 -1
- package/dist/assets/{profile-embed-CcuuyEXm.js → profile-embed-faK_BKhI.js} +1 -1
- package/dist/assets/pt-CEcOQeEC.js +5 -0
- package/dist/assets/publish-resource-D8YEMAlU.js +1 -0
- package/dist/assets/{react-beautiful-dnd.esm-cfY5JZV6.js → react-beautiful-dnd.esm-vpuu2z51.js} +1 -1
- package/dist/assets/ru-83xhwzPD.js +5 -0
- package/dist/assets/runtime-CKW1HKn_.js +1 -0
- package/dist/assets/sdk-B_abqbXe.js +1 -0
- package/dist/assets/{security-C8vye2TA.js → security-Dt3PKq-c.js} +4 -4
- package/dist/assets/{session-B2z_IWIe.js → session-CSqVp1zS.js} +1 -1
- package/dist/assets/setup-BlQH2Z6r.js +30 -0
- package/dist/assets/{spaces-DMMN97uo.js → spaces-rexKSkSX.js} +1 -1
- package/dist/assets/start-_8paEixr.js +187 -0
- package/dist/assets/{starting-progress-DeFtXRb_.js → starting-progress-CvmzmBMV.js} +2 -2
- package/dist/assets/{status-C73nIKwK.js → status-BDhcfo0L.js} +1 -1
- package/dist/assets/{step-actions-CqbOBcvS.js → step-actions-iPiCkXbU.js} +1 -1
- package/dist/assets/{studio-CiFHrC57.js → studio-A7rMh4Xk.js} +1 -1
- package/dist/assets/{switch-control-DnNP5DPe.js → switch-control-BmaFq4ZK.js} +1 -1
- package/dist/assets/{table-tips-hNIkakER.js → table-tips-DnNYXRDB.js} +1 -1
- package/dist/assets/th-BQLlyW1N.js +5 -0
- package/dist/assets/{traffic-B7XP49Y5.js → traffic-BMZEqBnG.js} +2 -2
- package/dist/assets/{transfer-BfUTfR-d.js → transfer-2aML1rIB.js} +1 -1
- package/dist/assets/{unsubscribe-Bf4dBSoS.js → unsubscribe-BuBJl9gX.js} +1 -1
- package/dist/assets/use-blocklet-logo-2Y2A06qi.js +2 -0
- package/dist/assets/{useAsync-DnXpD472.js → useAsync-JBeeXlrl.js} +1 -1
- package/dist/assets/{useLocalStorage-BRd3tKN9.js → useLocalStorage-BFO9aBYY.js} +1 -1
- package/dist/assets/{user-center-Ck0gNc-m.js → user-center-gbex4PJG.js} +2 -2
- package/dist/assets/{util-CVjZG67N.js → util-DMDaTiE0.js} +1 -1
- package/dist/assets/{util-DWicJSOi.js → util-xFBxHmZK.js} +1 -1
- package/dist/assets/{vendor-arcblock-DPRICUXM.js → vendor-arcblock-C99E80cF.js} +24 -24
- package/dist/assets/{vendor-hooks-Zkb4Ilbj.js → vendor-hooks-DpwFseeF.js} +1 -1
- package/dist/assets/{vendor-ux-did-connect-Ck9lzrbN.js → vendor-ux-did-connect-Qap4yrMu.js} +3 -3
- package/dist/assets/vi-DgWAr6FA.js +5 -0
- package/dist/assets/wrap-locale-C4cvZ4CE.js +1 -0
- package/dist/assets/{zh-Cti0XXui.js → zh-BL80PoOh.js} +2 -2
- package/dist/assets/{zh-tw-BLcDG99i.js → zh-tw-Dg5z1DFE.js} +1 -1
- package/dist/index.html +4 -4
- package/dist/service-worker.js +1 -1
- package/package.json +29 -29
- package/dist/assets/add-resource-BE6wXeqY.js +0 -1
- package/dist/assets/appearance-Czknho-C.js +0 -1
- package/dist/assets/complete-C834qh46.js +0 -39
- package/dist/assets/dashboard-Dc5xtJBc.js +0 -239
- package/dist/assets/domain-action-card-CoP_GfSR.js +0 -28
- package/dist/assets/domains-CGg1il1q.js +0 -1
- package/dist/assets/hi-C51yBXa5.js +0 -5
- package/dist/assets/iframe-D0kv9-rE.js +0 -1
- package/dist/assets/index-C26jJx3Z.js +0 -55
- package/dist/assets/index-DoCu_ga_.js +0 -10
- package/dist/assets/list-CUP3NH6M.js +0 -236
- package/dist/assets/localization-Cl5vfs2R.js +0 -1
- package/dist/assets/pt-7HHecjdA.js +0 -5
- package/dist/assets/publish-resource-BdSfAE92.js +0 -1
- package/dist/assets/ru-Bw8FVC4M.js +0 -5
- package/dist/assets/runtime-BKK1_RAt.js +0 -1
- package/dist/assets/sdk-CXaHNlMH.js +0 -1
- package/dist/assets/setup-CS2QWFMb.js +0 -30
- package/dist/assets/start-6o3_Gxa0.js +0 -187
- package/dist/assets/th-DyW-mYrC.js +0 -5
- package/dist/assets/use-blocklet-logo-Bv56-gH-.js +0 -2
- package/dist/assets/vi-bzer6J4H.js +0 -5
- package/dist/assets/wrap-locale-HcPVeI43.js +0 -1
|
@@ -0,0 +1,239 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/log-D-KC9F0b.js","assets/vendor-mui-core-Bh-qMRq3.js","assets/vendor-react-DEoibe3W.js","assets/useLocalStorage-BFO9aBYY.js","assets/vendor-ux-did-connect-Qap4yrMu.js","assets/vendor-utils-rHXShPKm.js","assets/vendor-hooks-DpwFseeF.js","assets/lottie-web-jYmAQWuC.js","assets/vendor-ux-did-connect-DpSGLE7B.css","assets/index-BzItMezw.js","assets/vendor-arcblock-C99E80cF.js","assets/index-DOq-_YXu.css","assets/Download-X3XR698Z.js","assets/bundle-avatar-BoczFLNt.js","assets/log-D33dFtt_.css","assets/index-DaoLXOw4.js","assets/ViewList-Bj0HBob4.js","assets/index-sAnn-Wqb.js","assets/Phone--BSu-btI.js","assets/Location-By12Z3Te.js","assets/Email-CdSNK0eA.js","assets/Timezone-YZ0dMUEr.js","assets/index-C5_3pYA_.js","assets/did-address-Ddg6Is1P.js","assets/permission-KYy-A4oZ.js","assets/session-CSqVp1zS.js","assets/click-to-copy-ClNoTzk4.js","assets/index-C61DBznM.js","assets/vendor-mui-x-CQTjfcpn.js","assets/AdapterDayjs-D2uo6EnV.js","assets/index-8eXqqyHQ.js","assets/useAsync-JBeeXlrl.js","assets/index-Cb7iBSvd.js","assets/DeleteOutline-BFB4Yy3c.js","assets/confirm-hm6dpNbC.js","assets/util-DMDaTiE0.js","assets/base32-B42OVABo.js","assets/sdk-B_abqbXe.js","assets/actions-B2RmHKJh.js","assets/MoreHoriz-Bncapj_R.js","assets/shorten-label-Bf7YQUd6.js","assets/PlayArrow-B19IPFeo.js","assets/get-safe-url-XcLmS0yc.js","assets/use-blocklet-logo-2Y2A06qi.js","assets/InfoOutlined-BGorl_CI.js","assets/dot-CdVWOAIG.js","assets/useSetState-CWq0AVWn.js","assets/use-mobile-ZAS6Si4t.js","assets/index-ND58NXzr.js","assets/use-mobile-JEGQfLZ2.js","assets/ExpandLess-D7OENe4H.js","assets/table-tips-DnNYXRDB.js","assets/index-Cd3oZl-N.js","assets/Error-CPi5ht0i.js","assets/empty-spinner-BZw_ShnT.js","assets/list-header-DNFbdM3a.js","assets/QuestionMarkCircle-DTf-Tya5.js","assets/index-DVQCgvFb.js","assets/Launch-5hxRq_We.js","assets/index-C849wD9b.js","assets/api-BjteVZFg.js","assets/ChevronRight-BXgoqDfE.js","assets/react-beautiful-dnd.esm-vpuu2z51.js","assets/raf-schd.esm-B3j6BePR.js","assets/item-BYt6Ny1o.js","assets/Done-DboXobnH.js","assets/delete-confirm-BRkmB2tO.js","assets/ArrowDropDown-PfUV1pZb.js","assets/index-DbsXFWms.js","assets/index-C0Iiqot3.css","assets/index-BdH_4Yfe.js","assets/overview-qlJHwq1E.js","assets/keyboard-arrow-down-rounded-DadBVmpO.js","assets/status-BDhcfo0L.js","assets/omit-D2k92RIF.js","assets/spaces-rexKSkSX.js","assets/domains-BkjwRhdu.js","assets/domain-action-card-BnxgZfnv.js","assets/util-xFBxHmZK.js","assets/CheckCircle-zHdz-yvJ.js","assets/index-DAEEDx1o.js","assets/passport-item-C7W2OqHa.js","assets/Google-Bl_7h7C7.js","assets/cloneDeep-UpFQ2VNg.js","assets/EditIcon-Dffk7mPL.js","assets/LockIcon-98CKEIBe.js","assets/appearance-58f9Dbcn.js","assets/audit-logs-fYqimPuZ.js","assets/index-CmOE3ceE.js","assets/collapse-Dz_izL9k.js","assets/section-C1TPQFRq.js","assets/list-BkVwpX1t.js","assets/traffic-BMZEqBnG.js","assets/iframe-BHwYGTAS.js","assets/LaunchOutlined-DCxTlWgy.js","assets/ChevronLeft-3zBX65MM.js","assets/index-CmQOzzP8.js","assets/config-navigation-DdXZFw0Z.js","assets/index-Bs1kxR8_.js","assets/slicedToArray-BSaY8ui4.js","assets/simple-select-DwWEI_ZU.js","assets/index-Dm4t4XH1.js","assets/connect-to-Dwm_wvvo.js","assets/config-space-CSZvQTns.js","assets/index-C0w1ugDi.js","assets/switch-control-BmaFq4ZK.js","assets/index-ToeWiBUL.js","assets/security-Dt3PKq-c.js","assets/config-tQft4lvg.js","assets/branding-eOJeN-jW.js","assets/logo-uploader-BNZB1sug.js","assets/advanced-5oQIoiUN.js","assets/runtime-CKW1HKn_.js","assets/index-CVDucF7E.js","assets/Edit-Cl3SK-FJ.js","assets/list-UaF9rEdO.js","assets/component-BzBSZbVF.js","assets/TuneOutlined-OuRuIP5i.js","assets/add-component-core-BLsjc3lE.js","assets/launch-result-message-Eea5FZDm.js","assets/page-header-D9UEVC59.js","assets/index-B6jePIag.js","assets/content-layout--sy9JlYZ.js","assets/add-component-core-D-IRi6XF.css","assets/index-BKdJfp9x.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{c as ie,u as Ze,p as fs,h as Xe,f as zn,g as ps,E as ms,i as hs,H as gs,_ as P,R as xs}from"./vendor-arcblock-C99E80cF.js";import{H as v,j as o,a9 as B,ah as G,I as Et,ap as vs,ak as Bn,X as Lt,q as ys,b4 as bs,ab as ne,b5 as ws,bw as js,T as U,bu as Ss,bs as xn,bv as vn,aa as C,bI as Cs,v as Z,a7 as st,bJ as _s,e as ee,ae as Is,bf as ks,be as Dt,bK as Hn,ad as _e,bL as Ts,aq as Es,ai as Ls,bM as Fn,bN as Vn,bO as qn,E as ae,b3 as Wn,y as Ds,bh as Ps}from"./vendor-mui-core-Bh-qMRq3.js";import{r as x,L as Gn,f as Kn,g as Rs,u as As,l as Ms}from"./vendor-react-DEoibe3W.js";import{r as H,b3 as $s,b1 as Pt,b4 as Os,B as Rt,j as M,a1 as yn,Y as Q,a as J,am as Ns,m as Qn,k as Us,d as zs,h as Bs,aI as Hs,y as Te,W as At,b5 as Fs,b6 as Vs,I as qs,C as Je,b7 as Ws,b8 as Gs,aq as Ks,_ as Qs}from"./vendor-ux-did-connect-Qap4yrMu.js";import{A as ot,f as N,B as ut,C as Zs,b as Xs,D as Js,E as Ys,F as Zn,v as me,G as Xn,H as eo,o as ve,I as to,J as no,u as ro,j as bn,g as so,K as wn,h as oo,l as dt,k as io,m as ao,L as co,O as lo,M as Ve,e as Ue,Q as uo,R as fo,T as po,N as mo,U as ho,c as jn}from"./index-BzItMezw.js";import{af as go,A as he,ag as xo,z as Jn,b as qe,ah as vo}from"./vendor-utils-rHXShPKm.js";import{_ as Sn}from"./useLocalStorage-BFO9aBYY.js";import{f as Mt}from"./index-8eXqqyHQ.js";import{C as Cn}from"./confirm-hm6dpNbC.js";import{d as yo}from"./PlayArrow-B19IPFeo.js";import{g as _n}from"./get-safe-url-XcLmS0yc.js";import{u as Yn}from"./session-CSqVp1zS.js";import{f as ge,x as bo}from"./vendor-hooks-DpwFseeF.js";import{i as wo,u as jo,M as So,c as Ie,s as Ye,H as Co,a as _o}from"./use-blocklet-logo-2Y2A06qi.js";import{d as Io}from"./InfoOutlined-BGorl_CI.js";import{_ as er,D as ko}from"./dot-CdVWOAIG.js";import{_ as tr}from"./useSetState-CWq0AVWn.js";import{u as To}from"./use-mobile-ZAS6Si4t.js";const nr=x.createContext({});function $t({children:e,type:t}){const[n,r]=x.useState([]),s=x.useRef([]),a=l=>{if(!s.current.includes(l)){const u=[...s.current,l];r(u),s.current=u}},i=l=>{if(s.current.includes(l)){const u=s.current.filter(d=>d!==l);r(u),s.current=u}},c=l=>{const u=n.filter(p=>l.find(f=>f===p));go(u,n).forEach(p=>i(p))};return o.jsx(nr.Provider,{value:{type:t,deletingBlocklets:n,addDeletingDid:a,removeDeletingDid:i,matchDeletingDid:c},children:e})}$t.propTypes={type:v.string,children:v.node.isRequired};$t.defaultProps={type:"blocklets"};function El(){return x.useContext(nr)}var Ot={},Eo=B;Object.defineProperty(Ot,"__esModule",{value:!0});var rr=Ot.default=void 0,Lo=Eo(H()),Do=o;rr=Ot.default=(0,Lo.default)((0,Do.jsx)("path",{d:"M6 6h12v12H6z"}),"Stop");var Nt={},Po=B;Object.defineProperty(Nt,"__esModule",{value:!0});var sr=Nt.default=void 0,Ro=Po(H()),Ao=o;sr=Nt.default=(0,Ro.default)((0,Ao.jsx)("path",{d:"M12 5V1L7 6l5 5V7c3.31 0 6 2.69 6 6s-2.69 6-6 6-6-2.69-6-6H4c0 4.42 3.58 8 8 8s8-3.58 8-8-3.58-8-8-8"}),"Replay");var Ut={},Mo=B;Object.defineProperty(Ut,"__esModule",{value:!0});var or=Ut.default=void 0,$o=Mo(H()),Oo=o;or=Ut.default=(0,$o.default)((0,Oo.jsx)("path",{d:"M12 6v3l4-4-4-4v3c-4.42 0-8 3.58-8 8 0 1.57.46 3.03 1.24 4.26L6.7 14.8c-.45-.83-.7-1.79-.7-2.8 0-3.31 2.69-6 6-6m6.76 1.74L17.3 9.2c.44.84.7 1.79.7 2.8 0 3.31-2.69 6-6 6v-3l-4 4 4 4v-3c4.42 0 8-3.58 8-8 0-1.57-.46-3.03-1.24-4.26"}),"Autorenew");var zt={},No=B;Object.defineProperty(zt,"__esModule",{value:!0});var ir=zt.default=void 0,Uo=No(H()),zo=o;ir=zt.default=(0,Uo.default)((0,zo.jsx)("path",{d:"M19.14 12.94c.04-.3.06-.61.06-.94 0-.32-.02-.64-.07-.94l2.03-1.58c.18-.14.23-.41.12-.61l-1.92-3.32c-.12-.22-.37-.29-.59-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54c-.04-.24-.24-.41-.48-.41h-3.84c-.24 0-.43.17-.47.41l-.36 2.54c-.59.24-1.13.57-1.62.94l-2.39-.96c-.22-.08-.47 0-.59.22L2.74 8.87c-.12.21-.08.47.12.61l2.03 1.58c-.05.3-.09.63-.09.94s.02.64.07.94l-2.03 1.58c-.18.14-.23.41-.12.61l1.92 3.32c.12.22.37.29.59.22l2.39-.96c.5.38 1.03.7 1.62.94l.36 2.54c.05.24.24.41.48.41h3.84c.24 0 .44-.17.47-.41l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.22.08.47 0 .59-.22l1.92-3.32c.12-.22.07-.47-.12-.61zM12 15.6c-1.98 0-3.6-1.62-3.6-3.6s1.62-3.6 3.6-3.6 3.6 1.62 3.6 3.6-1.62 3.6-3.6 3.6"}),"Settings");var Bt={},Bo=B;Object.defineProperty(Bt,"__esModule",{value:!0});var ar=Bt.default=void 0,Ho=Bo(H()),Fo=o;ar=Bt.default=(0,Ho.default)((0,Fo.jsx)("path",{d:"M18 17H6v-2h12zm0-4H6v-2h12zm0-4H6V7h12zM3 22l1.5-1.5L6 22l1.5-1.5L9 22l1.5-1.5L12 22l1.5-1.5L15 22l1.5-1.5L18 22l1.5-1.5L21 22V2l-1.5 1.5L18 2l-1.5 1.5L15 2l-1.5 1.5L12 2l-1.5 1.5L9 2 7.5 3.5 6 2 4.5 3.5 3 2z"}),"Receipt");var Ht={},Vo=B;Object.defineProperty(Ht,"__esModule",{value:!0});var cr=Ht.default=void 0,qo=Vo(H()),Wo=o;cr=Ht.default=(0,qo.default)((0,Wo.jsx)("path",{d:"M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3m-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3m0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5m8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5"}),"Group");var Ft={},Go=B;Object.defineProperty(Ft,"__esModule",{value:!0});var lr=Ft.default=void 0,Ko=Go(H()),Qo=o;lr=Ft.default=(0,Ko.default)((0,Qo.jsx)("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.42 0-8-3.58-8-8 0-1.85.63-3.55 1.69-4.9L16.9 18.31C15.55 19.37 13.85 20 12 20m6.31-3.1L7.1 5.69C8.45 4.63 10.15 4 12 4c4.42 0 8 3.58 8 8 0 1.85-.63 3.55-1.69 4.9"}),"NotInterested");var Vt=function(e){return o.jsx("svg",{...e,children:o.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.32989 8.20744C11.2787 6.82349 13.6098 6.08 16 6.08C18.3902 6.08 20.7213 6.82349 22.6701 8.20744C24.6189 9.59139 26.089 11.5473 26.8766 13.804C27.6642 16.0607 27.7304 18.5066 27.0659 20.8026C26.4419 22.9587 25.2026 24.8823 23.5044 26.3404H8.49555C6.79735 24.8823 5.55809 22.9587 4.9341 20.8026C4.26961 18.5066 4.33575 16.0607 5.12337 13.804C5.91098 11.5473 7.38107 9.59139 9.32989 8.20744ZM16 3.52C13.0786 3.52 10.2295 4.42871 7.84764 6.1202C5.46575 7.81169 3.66898 10.2022 2.70634 12.9604C1.7437 15.7187 1.66286 18.708 2.47501 21.5143C3.28717 24.3205 4.95211 26.8046 7.23909 28.6224C7.46554 28.8024 7.74628 28.9004 8.03554 28.9004H23.9644C24.2537 28.9004 24.5344 28.8024 24.7609 28.6224C27.0479 26.8046 28.7128 24.3205 29.5249 21.5143C30.3371 18.708 30.2563 15.7187 29.2936 12.9604C28.331 10.2022 26.5342 7.81169 24.1523 6.1202C21.7704 4.42871 18.9214 3.52 16 3.52ZM21.8829 13.5921C22.3827 13.0923 22.3827 12.2818 21.8829 11.7819C21.383 11.2821 20.5725 11.2821 20.0727 11.7819L17.868 13.9866C17.3072 13.7012 16.6724 13.5404 16 13.5404C13.7221 13.5404 11.8755 15.3869 11.8755 17.6648C11.8755 19.9427 13.7221 21.7892 16 21.7892C18.2779 21.7892 20.1244 19.9427 20.1244 17.6648C20.1244 16.9924 19.9635 16.3576 19.6782 15.7968L21.8829 13.5921ZM14.4355 17.6648C14.4355 16.8008 15.136 16.1004 16 16.1004C16.864 16.1004 17.5644 16.8008 17.5644 17.6648C17.5644 18.5288 16.864 19.2292 16 19.2292C15.136 19.2292 14.4355 18.5288 14.4355 17.6648Z",fill:"currentColor"})})};Vt.defaultProps={width:"32",height:"32",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg"};Vt.displayName="dashboard";var qt={},Zo=B;Object.defineProperty(qt,"__esModule",{value:!0});var ur=qt.default=void 0,Xo=Zo(H()),Jo=o;ur=qt.default=(0,Xo.default)((0,Jo.jsx)("path",{d:"m18.25 7.6-5.5-3.18c-.46-.27-1.04-.27-1.5 0L5.75 7.6c-.46.27-.75.76-.75 1.3v6.35c0 .54.29 1.03.75 1.3l5.5 3.18c.46.27 1.04.27 1.5 0l5.5-3.18c.46-.27.75-.76.75-1.3V8.9c0-.54-.29-1.03-.75-1.3M7 14.96v-4.62l4 2.32v4.61zm5-4.03L8 8.61l4-2.31 4 2.31zm1 6.34v-4.61l4-2.32v4.62zM7 2H3.5C2.67 2 2 2.67 2 3.5V7h2V4h3zm10 0h3.5c.83 0 1.5.67 1.5 1.5V7h-2V4h-3zM7 22H3.5c-.83 0-1.5-.67-1.5-1.5V17h2v3h3zm10 0h3.5c.83 0 1.5-.67 1.5-1.5V17h-2v3h-3z"}),"ViewInAr");const pe={Start:yo,Stop:rr,Restart:sr,Reload:or,Remove:$s,Config:ir,Log:ar,Group:cr,Cancel:lr,Dashboard:Vt,Overview:ur},Yo=(e,t)=>{if(!e)return"";const n=new URL(e),r=new URLSearchParams(n.searchParams),s=new URL(he(n.origin,t));return s.search=r.toString(),s.toString()},ei="internal",ti="external";function Wt({blocklet:e,onStart:t,onComplete:n,variant:r,hasPermission:s,getComponentUrl:a,useBlockletUrlEvaluation:i,...c}){const l=ot(),[u,d]=x.useState(null),[p,f]=x.useState(null),[y,g]=x.useState(!1),[h,_]=x.useState(null),{t:m}=x.useContext(Pt),[j]=Sn("skip-blocklet-setup",!1),{loading:b,recommendedUrl:R}=i(e),[$]=Sn("blocklet-type-filter",ei),S=N.isInProgress(e.status),[T,I]=x.useState(!1);x.useEffect(()=>{var A,z;if(!(e!=null&&e.controller))return;I(((z=(A=e==null?void 0:e.controller)==null?void 0:A.status)==null?void 0:z.value)===ie.BLOCKLET_CONTROLLER_STATUS.suspended),(async()=>{var V,Y,se;try{const q=await l.api.getLauncherSession({input:{launcherSessionId:(V=e==null?void 0:e.controller)==null?void 0:V.launcherSessionId,launcherUrl:(Y=e==null?void 0:e.controller)==null?void 0:Y.launcherUrl}});if(q!=null&&q.error){console.error("get launcher session failed",q.error);return}I([M.LAUNCH_SESSION_STATUS.overdue,M.LAUNCH_SESSION_STATUS.canceled,M.LAUNCH_SESSION_STATUS.terminated].includes((se=q==null?void 0:q.launcherSession)==null?void 0:se.status))}catch(q){console.error("call getLauncherSession error",q)}})()},[]);const{inService:E}=l,k=(w,A,z=!1)=>async()=>{const V=async $e=>{var Ne;t({action:w,blocklet:e}),g(!0),f(w);let Oe=!1;try{if(w==="remove")await A($e);else if(w==="start"){if(!N.hasRunnableComponent(e)){Q.error(m("blocklet.noComponent"));return}if(!E&&!j&&!((Ne=e.settings)!=null&&Ne.initialized)&&e.mode!==ie.BLOCKLET_MODES.DEVELOPMENT){if(!R||!yn(R)){Q.error(m("blocklet.gotoVisitError"));return}const K=Zs(l.info),gn=new URL(R);gn.searchParams.set("serverUrl",K),window.open(_n(gn.href,{allowDomains:null})),n({action:w,blocklet:e});return}const oe=e.children.filter(K=>!N.isInProgress(K.status)&&K.status!=="running").map(K=>K.meta.did),fe={did:e.meta.did,componentDids:oe};await A({input:fe})}else if(["stop","restart","reload"].includes(w)){const oe=e.children.filter(K=>K.status==="running").map(K=>K.meta.did),fe={did:e.meta.did,componentDids:oe};await A({input:fe})}else{const oe={did:e.meta.did};await A({input:oe})}w==="remove"?Oe=!0:await Xs(1e3),w==="reload"&&Q.success(m("blocklet.reloadSuccess")),_(null),n({action:w,blocklet:e})}catch(oe){const fe=`Blocklet ${w} failed: ${Mt(oe)}`;throw n({action:w,blocklet:e,error:new Error(fe)}),new Error(fe)}finally{Oe||g(!1)}},Y=()=>{g(!1),_(null)},se=N.getDisplayName(e,!0),q=e.mode===ie.BLOCKLET_MODES.DEVELOPMENT?{description:()=>o.jsx(U,{component:"div",children:o.jsx(U,{gutterBottom:!0,children:m("blocklet.action.removeApplicationDescription")})}),params:{removeType:"complete"}}:{description:($e,Oe)=>o.jsxs(U,{component:"div",children:[o.jsx(U,{gutterBottom:!0,children:m("blocklet.action.removeApplicationDescription")}),o.jsxs(Ss,{name:"removeType",value:$e.removeType,onChange:Ne=>Oe({...$e,removeType:Ne.target.value}),children:[o.jsx(xn,{value:"backup",control:o.jsx(vn,{}),label:m("blocklet.action.removeApplicationAfterBackup")}),o.jsx(xn,{value:"complete",control:o.jsx(vn,{}),label:m("blocklet.action.removeApplicationComplete")})]})]}),params:{removeType:"backup"}},ds={stop:{title:`${m("common.stop")} ${se}`,description:m("blocklet.action.stopDescription"),confirm:m("blocklet.action.confirmStop"),cancel:m("common.cancel"),onConfirm:V,onCancel:Y},restart:{title:`${m("common.restart")} ${se}`,description:m("blocklet.action.restartDescription"),confirm:m("blocklet.action.confirmRestart"),cancel:m("common.cancel"),onConfirm:V,onCancel:Y},remove:{title:`${m("common.remove")} ${se}`,confirm:m("blocklet.action.confirmRemove"),cancel:m("common.cancel"),onConfirm:V,onCancel:Y,...q},cancelDownload:{title:`${m("common.cancel")}`,description:m("blocklet.action.cancelDownloadDescription",{name:se}),confirm:m("common.confirm"),cancel:m("common.cancel"),onConfirm:V,onCancel:Y}};z?_(ds[w]):await V()},L=!!u,de=w=>{try{w.stopPropagation(),w.preventDefault()}catch{}d(w.currentTarget)},F=w=>{try{w.stopPropagation(),w.preventDefault()}catch{}d(null)},Ae=async(w,A)=>{try{A.stopPropagation(),A.preventDefault()}catch{}if(typeof w.handler=="function")try{g(!0),f(w.action),await w.handler()}catch(z){console.error(`Blocklet ${w.name} failed: `,z)}finally{g(!1),d(null)}else d(null)},as=!E&&N.isDeletableBlocklet(e)?{action:"remove",icon:pe.Remove,name:m("common.remove"),handler:k("remove",async({removeType:w})=>{w==="backup"&&await l.api.backupBlocklet({input:{appDid:e.appDid,to:"disk"}}),await l.api.deleteBlocklet({input:{did:e.meta.did,keepData:!1}})},!0),disabled:S}:null,cs={action:"remove",icon:({sx:w,...A})=>o.jsx(pe.Cancel,{sx:{...w,paddingRight:"2px",zoom:.95},...A}),name:m("common.cancel"),handler:k("cancelDownload",l.api.cancelDownloadBlocklet,!0)},ls=N.getAppMissingConfigs(e),us=()=>{var V;const w=`/${e.mountPoint||"/"}`.replace(/\/+/g,"/"),A=a==null?void 0:a({mountPoint:w,blocklet:e});if(!A||!yn(A)){Q.error(m("blocklet.gotoVisitError"));return}const z=(V=e==null?void 0:e.site)==null?void 0:V.domainAliases;window.open(_n(Yo(A,".well-known/service/admin"),{allowDomains:z==null?void 0:z.map(Y=>Y.value)}))};let Me=[{action:"start",icon:pe.Start,inExternal:!0,name:m("common.start"),handler:k("start",l.api.startBlocklet),disabled:T||e.children.every(w=>w.status==="running")||ut(e.status)||b||S},{action:"stop",icon:pe.Stop,inExternal:!0,name:m("common.stop"),handler:k("stop",l.api.stopBlocklet,!0),disabled:!["running","starting"].includes(e.status)},{action:"restart",inExternal:!0,icon:pe.Restart,name:m("common.restart"),handler:k("restart",l.api.restartBlocklet,!0),disabled:T||e.status!=="running"},ut(e.status)?cs:as,{separator:!0},E?null:{action:"dashboard",icon:({style:w,...A})=>o.jsx(pe.Dashboard,{...A,style:{...w,width:"26px",height:"26px",paddingRight:"3px"}}),name:m("sidebar.dashboard"),handler:us}].filter(Boolean);return $===ti&&(Me=Me.filter(w=>w.inExternal)),r==="menu"?o.jsxs(In,{"data-cy":"blocklet-actions",children:[o.jsx(Et,{"aria-label":"more","aria-controls":"actions-menu","aria-haspopup":"true","data-cy":"trigger-blocklet-actions","actions-blocklet-did":e.meta.did,onClick:de,size:"small",disabled:!s||!ut(e.status)&&y,children:o.jsx(Os,{})}),o.jsxs(vs,{id:"actions-menu",anchorEl:u,keepMounted:!0,open:L,onClose:F,PaperProps:{},children:[ls.length>0&&o.jsxs(Bn,{style:{maxWidth:"400px"},severity:"error",children:[m("blocklet.config.missingRequired"),o.jsx("br",{}),o.jsx(Gn,{to:`/blocklets/${e.meta.did}/components`,children:m("blocklet.config.gotoFix")})]}),Me.map((w,A)=>w.separator?o.jsx(Lt,{},`separator-${A}`):o.jsxs(ys,{dense:!0,onClick:z=>Ae(w,z),disabled:y||w.disabled,"data-cy":`${w.action}-blocklet`,children:[o.jsx(bs,{style:{minWidth:24},children:p===w.action&&y?o.jsx(ne,{size:16,sx:{marginRight:1}}):o.jsx(w.icon,{fontSize:"small"})}),o.jsx(ws,{primary:w.name})]},w.name))]}),h&&o.jsx(Cn,{title:h.title,description:h.description,confirm:h.confirm,cancel:h.cancel,params:h.params,onConfirm:h.onConfirm,onCancel:h.onCancel})]}):o.jsxs(In,{"data-cy":"blocklet-actions",...c,children:[o.jsx(js,{children:Me.filter(w=>!w.separator&&!w.onlyInMenu).map(w=>o.jsxs(Rt,{title:w.name,"data-cy":`${w.action}-blocklet`,onClick:()=>Ae(w),disabled:!!w.disabled||y,children:[p===w.action&&y?o.jsx(ne,{size:16,sx:{marginRight:1}}):o.jsx(w.icon,{}),o.jsx("span",{className:"blocklet-action-text",children:w.name})]},w.name))}),h&&o.jsx(Cn,{title:h.title,description:h.description,confirm:h.confirm,cancel:h.cancel,params:h.params,onConfirm:h.onConfirm,onCancel:h.onCancel})]})}Wt.propTypes={getComponentUrl:v.func,blocklet:v.object.isRequired,onStart:v.func.isRequired,onComplete:v.func.isRequired,variant:v.oneOf(["menu","group"]),hasPermission:v.bool,useBlockletUrlEvaluation:v.func};Wt.defaultProps={getComponentUrl:null,variant:"menu",hasPermission:!1,useBlockletUrlEvaluation:()=>{var e;return{loading:!1,recommendedUrl:(e=window==null?void 0:window.location)==null?void 0:e.href}}};const In=G.div`
|
|
3
|
+
display: flex;
|
|
4
|
+
align-items: center;
|
|
5
|
+
|
|
6
|
+
@media (max-width: ${e=>e.theme.breakpoints.values.sm}px) {
|
|
7
|
+
.MuiButton-root {
|
|
8
|
+
padding: 4px;
|
|
9
|
+
font-size: 10px;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
`,kn=x.memo(Wt),ni=e=>{const t={};let n=null;return N.forEachBlockletSync(e,r=>{t[r.meta.bundleDid]?n=N.getDisplayName(r,!0):r.meta.bundleDid&&(t[r.meta.bundleDid]=!0)}),n},ri=(e,t,n)=>{var a;const{hostname:r,href:s}=e;if(!t)return s;if(n){const c=/\d+[-.]\d+[-.]\d+[-.]\d+/.exec(r);if(!c)return s;const l=c[0],d=((((a=t.site)==null?void 0:a.domainAliases)||[]).map(p=>p.value).filter(Boolean).find(p=>p.endsWith(M.DEFAULT_DID_DOMAIN))||"").replace(`.${M.DEFAULT_DID_DOMAIN}`,"");return d?s.replace(r,`${d}-${l}.${M.DEFAULT_IP_DOMAIN_SUFFIX}`):s}return s.replace(t.meta.bundleDid,t.appPid)};function dr(){const{t:e}=J(),{api:t}=Yn(),{blocklet:n}=Js(),{inService:r}=ot(),[s,a]=x.useState(!1),[i,c]=x.useState(5),l=n&&n.structVersion!==M.APP_STRUCT_VERSION,u=()=>{try{if(n.status==="running"){Q.error(e("blocklet.migrate.tip.running"));return}const f=ni(n);if(f){Q.error(e("blocklet.migrate.tip.duplicate",{name:f}));return}a(!0)}catch(f){Q.error(Mt(f))}},d=()=>{const f=ri(window.location,n,r);setTimeout(()=>{window.location.href=f},5e3),c(5),setInterval(()=>{c(y=>y-1)},1e3)},p=()=>a(!1);return[l&&o.jsxs(Bn,{severity:"warning",style:{margin:"12px 0"},children:[o.jsxs(C,{display:"flex",alignItems:"center",children:[o.jsx(Rt,{variant:"contained",size:"small",color:"primary",onClick:()=>u(),style:{marginRight:8},children:e("blocklet.migrate.intro.l1")}),o.jsx("span",{children:e("blocklet.migrate.intro.l2")})]}),["l3","l4","l5","l6"].map(f=>o.jsx(C,{display:"flex",alignItems:"center",children:e(`blocklet.migrate.intro.${f}`)},f))]},"alert"),n&&o.jsx(Ns,{popup:!0,open:s,saveConnect:!1,forceConnected:!1,action:"migrate-app-to-struct-v2",checkFn:t.get,checkTimeout:5*60*1e3,onSuccess:d,extraParams:{appDid:n.appDid,did:n.meta.did,wt:Ys(n,!0),title:N.getDisplayName(n)},messages:{title:e("blocklet.migrate.title"),scan:e("blocklet.migrate.scan"),confirm:e("blocklet.migrate.confirm"),success:i>=0?e("blocklet.migrate.success",{sec:i}):"Redirecting..."},onClose:p},"connect")]}dr.propTypes={};function si(){const e=Cs();return[...e.breakpoints.keys].reverse().reduce((n,r)=>{const s=Z(e.breakpoints.up(r));return!n&&s?r:n},null)||"xs"}function oi(e){return o.jsx(st,{...e,children:o.jsx("path",{d:"M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M10 17L5 12L6.41 10.59L10 14.17L17.59 6.58L19 8L10 17Z"})})}function ii(e){return o.jsx(st,{...e,children:o.jsx("path",{d:"M13,14H11V10H13M13,18H11V16H13M1,21H23L12,2L1,21Z"})})}function ai(e){return o.jsx(st,{...e,children:o.jsx("path",{d:"M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2, 6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12, 13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z"})})}function ci(e){return o.jsx(st,{...e,children:o.jsx("path",{d:"M13,9H11V7H13M13,17H11V11H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12A10,10 0 0,0 12,2Z"})})}const ze={fontSize:20,marginInlineEnd:8},li={success:o.jsx(oi,{style:ze}),warning:o.jsx(ii,{style:ze}),error:o.jsx(ai,{style:ze}),info:o.jsx(ci,{style:ze})},ui=_s(e=>{const t={xl:"400px",lg:"400px",md:"400px",sm:"300px"},n=e.palette.background.default;return{lessPadding:{paddingLeft:8*2.5},contentRoot:{...e.typography.body2,display:"flex",backgroundColor:n,color:"#fff",alignItems:"center",padding:"6px 16px",borderRadius:"4px",boxShadow:"0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12)"},success:r=>({backgroundColor:`${Is[600]} !important`,width:t[r.breakpoint]}),error:r=>({backgroundColor:`${e.palette.error.dark} !important`,width:t[r.breakpoint]}),info:r=>({backgroundColor:`${e.palette.primary.main} !important`,width:t[r.breakpoint]}),warning:r=>({backgroundColor:`${ks[700]} !important`,width:t[r.breakpoint]}),icon:{fontSize:20},message:{display:"flex",alignItems:"center",padding:"8px 0",flex:1,width:0},action:{display:"flex",alignItems:"center",marginLeft:"auto",marginRight:-8,width:44}}});function Gt({keyId:e,notification:t={},viewAllUrl:n,content:r},s){var _,m,j;const a=ui({breakpoint:si()}),i=ee(),c=[a.contentRoot,a.lessPadding,a[t.severity]].join(" "),l=li[t.severity],{closeSnackbar:u}=Qn(),d=()=>u(e),p=Kn(),f=()=>{u(e),p(n)},y=ge(()=>wo(t),[t]),g=ge(()=>t==null?void 0:t.activity,[t]),h=jo({activity:g,users:[t==null?void 0:t.actorInfo],actors:[(_=t==null?void 0:t.activity)==null?void 0:_.actor],extra:{linkColor:i.palette.primary.main,userDid:(j=(m=t==null?void 0:t.receivers)==null?void 0:m[0])==null?void 0:j.did}});return o.jsxs(Us,{ref:s,className:c,children:[o.jsxs("div",{className:a.message,children:[l,o.jsx(fi,{onClick:f,style:{width:"calc(100% - 30px)"},children:o.jsx(C,{children:y?o.jsxs(o.Fragment,{children:[o.jsx("span",{className:"title",children:h}),g.meta?o.jsx(So,{meta:g.meta,type:g.type,sx:{display:"-webkit-box",overflow:"hidden",textOverflow:"ellipsis",WebkitLineClamp:3,WebkitBoxOrient:"vertical",color:"#fff"}}):null]}):o.jsxs(o.Fragment,{children:[o.jsx("span",{className:"title",children:t.title}),r||o.jsx("span",{className:"desc",children:t.description})]})})})]}),o.jsx("div",{className:a.action,children:o.jsx(Et,{"aria-label":"close",color:"inherit",onClick:d,size:"large",children:o.jsx(zs,{className:a.icon})},"close")})]})}const di=x.forwardRef(Gt);Gt.propTypes={viewAllUrl:v.string.isRequired,keyId:v.number.isRequired,notification:v.object.isRequired,content:v.node};Gt.defaultProps={content:null};const fi=G.div`
|
|
13
|
+
cursor: pointer;
|
|
14
|
+
display: flex;
|
|
15
|
+
flex-direction: column;
|
|
16
|
+
.title {
|
|
17
|
+
overflow: hidden;
|
|
18
|
+
text-overflow: ellipsis;
|
|
19
|
+
display: -webkit-box;
|
|
20
|
+
-webkit-line-clamp: 1;
|
|
21
|
+
-webkit-box-orient: vertical;
|
|
22
|
+
font-weight: bold;
|
|
23
|
+
}
|
|
24
|
+
.desc {
|
|
25
|
+
overflow: hidden;
|
|
26
|
+
text-overflow: ellipsis;
|
|
27
|
+
display: -webkit-box;
|
|
28
|
+
-webkit-line-clamp: 3;
|
|
29
|
+
-webkit-box-orient: vertical;
|
|
30
|
+
word-break: break-word;
|
|
31
|
+
}
|
|
32
|
+
`,pi=e=>{let t="rgba(0, 0, 0, 0.12)";return e==="warning"?t="#DE9E37":e==="error"?t="#F16E6E":t="rgba(0, 0, 0, 0.12)",t},mi=e=>e.every(t=>t.type==="text"),hi=e=>e.every(t=>t.type==="image"),gi=e=>xo(e,2).map(t=>({type:"combined",items:t})).filter(t=>(t.items||[]).every(n=>{var r,s,a;return(a=(s=(r=n==null?void 0:n.data)==null?void 0:r.text)==null?void 0:s.trim)==null?void 0:a.call(s)})),xi=e=>{if(!e.length||e.length<=1)return!1;const t=e[0].type;return e.every(n=>n.type===t)},vi=(e,t)=>{try{const n=Bs.toTypeInfo(e);if(!(n.role!==void 0&&n.role!==Hs.types.RoleType.ACCOUNT))return;const s=he(M.WELLKNOWN_SERVICE_PATH_PREFIX,"user");return Jn(s,{did:e,locale:t})}catch(n){console.error(n);return}},le=(e,t)=>({...e,...t?{filter:"invert(1)"}:{}}),Ee=e=>{if(!e)return null;try{return new URL(e).protocol!=="https:"?(console.warn("Image URL must use HTTPS protocol:",e),null):`/.well-known/service/proxy?url=${e}`}catch(t){return console.warn("Invalid image URL format:",e,t),null}};function fr({attachment:e}){const{data:t}=e,n=ee();let r="";try{r=new URL(t.url).host}catch{r=t.url}return o.jsxs(Dt,{target:"_blank",rel:"noopener noreferrer",href:t.url,className:"link",style:{wordBreak:"break-all"},onClick:s=>{s.customPreventRedirect=!0},children:[!!r&&o.jsx("span",{className:"url",children:r}),!!t.title&&o.jsx(C,{className:"title",style:{whiteSpace:"unset"},children:t.title}),!!t.description&&o.jsx(C,{className:"description",style:{whiteSpace:"unset",color:n.palette.text.secondary},children:t.description}),!!t.image&&o.jsx(Te,{src:Ze.getImagePath(t.image),alt:t.title||"",height:128,style:{borderRadius:"8px",maxWidth:"256px",objectFit:"cover"},fallback:Ee(Ze.getImagePath(t.image))})]})}fr.propTypes={attachment:v.object.isRequired};function pr({attachment:e}){const{data:t}=e;return o.jsx(Te,{src:Ze.getImagePath(t.url),alt:t.title||"",height:128,style:{borderRadius:"8px",maxWidth:"256px",objectFit:"cover"},fallback:Ee(Ze.getImagePath(t.url))})}pr.propTypes={attachment:v.object.isRequired};function mr({attachment:e,...t}){var c;const{data:n}=e,r=((c=n.color)==null?void 0:c.toLowerCase())||t.color,s=n.size||t.size,a=n.fontWeight||t.fontWeight||400;let i="14px";return s==="small"?i="12px":s==="normal"?i="14px":s==="big"?i="16px":s==="large"&&(i="18px"),o.jsx(yi,{className:"title",style:{fontSize:i,color:r,whiteSpace:"unset",fontWeight:a},children:n.text})}mr.propTypes={attachment:v.object.isRequired};const yi=G.span`
|
|
33
|
+
width: 100%;
|
|
34
|
+
display: -webkit-box;
|
|
35
|
+
-webkit-box-orient: vertical;
|
|
36
|
+
-webkit-line-clamp: 2;
|
|
37
|
+
overflow: hidden;
|
|
38
|
+
text-overflow: ellipsis;
|
|
39
|
+
white-space: normal;
|
|
40
|
+
word-break: break-word;
|
|
41
|
+
`;Kt.propTypes={locale:v.string,data:v.object.isRequired};Kt.defaultProps={locale:"en"};function Kt({locale:e="en",data:t}){const n={zh:"来自",en:"from"}[e]||"from",r={zh:"接收",en:"Received"}[e]||"Received",a=`https://${Ie.getUrlHost(t.chainHost)||Ie.getChainHost(t.chainId)}/explorer/tokens/${t.address}/tx`,i=ee(),c=i.palette.mode==="dark";let l=t.amount;t.decimal&&(l=t.amount/10**t.decimal);const u=ge(()=>({display:"flex",alignItems:"center",rowGap:2,columnGap:4,justifyContent:"space-between",flexWrap:"wrap"}));return o.jsx("a",{href:a,target:"_blank",rel:"noreferrer",onClick:d=>{d.customPreventRedirect=!0},children:o.jsxs(C,{display:"flex",flexDirection:"column",children:[o.jsxs(C,{sx:u,children:[o.jsx(U,{component:"div",sx:{fontWeight:700,color:i.palette.text.primary},children:r}),o.jsxs(U,{component:"div",align:"right",style:le(Ye.summaryStyle,c),flex:1,children:["+",l," ",t.symbol]})]}),o.jsxs(C,{sx:u,children:[o.jsx(U,{component:"div",style:le({...Ye.remarkStyle,fontSize:14},c),children:n}),o.jsx(C,{maxWidth:260,fontSize:14,children:o.jsx(At,{did:t.address,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:e})})]})]})})}Qt.propTypes={locale:v.string,data:v.object.isRequired};Qt.defaultProps={locale:"en"};function Qt({locale:e,data:t}){var d,p;const n={zh:"接收",en:"Received"}[e]||"Received",r={zh:"来自",en:"from"}[e]||"from",s=Ie.getUrlHost(t.chainHost)||Ie.getChainHost(t.chainId),a=t.did||((p=(d=t==null?void 0:t.credential)==null?void 0:d.issuer)==null?void 0:p.id)||"",i=`https://${s}/explorer/assets/${a}`,l=ee().palette.mode==="dark",u=ge(()=>({display:"flex",alignItems:"center",rowGap:2,columnGap:4,justifyContent:"space-between",flexWrap:"wrap"}));return o.jsx(C,{sx:{pr:1},children:o.jsx("a",{href:i,target:"_blank",style:{textDecoration:"none",color:"initial",display:"block"},onClick:f=>{f.customPreventRedirect=!0},rel:"noreferrer",children:o.jsxs(C,{display:"flex",flexDirection:"column",children:[o.jsxs(C,{sx:u,children:[o.jsx(U,{component:"div",sx:{fontWeight:700,color:"text.primary"},children:n}),o.jsx(U,{component:"div",align:"right",style:le(Ye.summaryStyle,l),children:"+1 Asset"})]}),a?o.jsxs(C,{sx:u,children:[o.jsx(U,{component:"div",style:le({...Ye.remarkStyle,fontSize:14},l),children:r}),o.jsx(C,{maxWidth:260,fontSize:14,children:o.jsx(At,{did:a,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:e})})]}):null]})})})}hr.propTypes={data:v.object.isRequired,locale:v.string};function hr({data:e,locale:t="en"}){const r=ee().palette.mode==="dark";return o.jsxs("a",{href:e.url,target:"_blank",style:{display:"flex",textDecoration:"none",color:"initial"},onClick:s=>{s.customPreventRedirect=!0},rel:"noreferrer",children:[o.jsx(Te,{className:"image",src:e.logo,width:50,height:50,alt:"",fallback:Ee(e.logo)}),o.jsxs("div",{style:{flex:1,marginLeft:"10px"},children:[o.jsx("div",{style:le({marginBottom:"6px"},r),children:e.title}),o.jsx(C,{maxWidth:260,fontSize:10,children:o.jsx(At,{did:e.appDID,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:t})})]})]})}Zt.propTypes={locale:v.string,data:v.object.isRequired};Zt.defaultProps={locale:"en"};function Zt({locale:e,data:t}){const n=Ie.getChainHost(t.chainId),r=`https://${n}/explorer/txs/${t.hash}`,s={zh:"交易详情",en:"Transaction Details"}[e]||"Transaction Details",a={zh:"交易哈希",en:"Transaction Hash"}[e]||"Transaction Hash",i=ee(),c=i.palette.mode==="dark";return o.jsxs("a",{href:r,target:"_blank",style:le({textDecoration:"none",color:"initial",display:"block",fontSize:14},c),onClick:l=>{l.customPreventRedirect=!0},rel:"noreferrer",children:[o.jsx("h6",{style:{color:i.palette.text.secondary,margin:0},children:n}),o.jsx("p",{style:{color:i.palette.warning.main,margin:0},children:s}),o.jsxs("div",{style:{wordBreak:"break-all"},children:[a,": ",t.hash]})]})}function gr({attachment:e,...t}){const{local:n}=x.useContext(Pt),r=Z(a=>a.breakpoints.down("md")),s=ee();return o.jsxs(bi,{...t,isMd:r,children:[e.type==="link"&&o.jsx(fr,{attachment:e,...t,isMd:r}),e.type==="image"&&o.jsx(pr,{attachment:e,isMd:r}),e.type==="text"&&o.jsx(mr,{attachment:e,isMd:r}),e.type==="token"&&o.jsx(Kt,{data:e.data,local:n,isMd:r}),e.type==="asset"||e.type==="vc"?o.jsx(Qt,{data:e.data,local:n,isMd:r}):null,e.type==="dapp"&&o.jsx(hr,{data:e.data,local:n,isMd:r}),e.type==="transaction"&&o.jsx(Zt,{data:e.data,local:n,...t,isMd:r}),e.type==="divider"&&o.jsx(Lt,{sx:{mb:1,mt:1},style:{color:s.palette.divider}})]})}const bi=G.div`
|
|
42
|
+
display: ${({sx:e={}})=>e.display||"flex"};
|
|
43
|
+
flex-direction: ${({sx:e={}})=>e.flexDirection||"column"};
|
|
44
|
+
gap: ${({sx:e={}})=>e.gap||1};
|
|
45
|
+
width: ${({isMd:e=!1})=>e?"100%":"auto"};
|
|
46
|
+
&:last-child {
|
|
47
|
+
margin-bottom: 0;
|
|
48
|
+
}
|
|
49
|
+
`;gr.propTypes={attachment:v.object.isRequired};function xr({data:e,...t}){const{items:n}=e;return o.jsx(wi,{...t,children:n.map(r=>o.jsxs(Hn,{variant:"outlined",sx:{p:2,borderRadius:"8px",minWidth:128},children:[o.jsxs(C,{display:"flex",alignItems:"center",gap:1,children:[r.icon?o.jsx(Te,{src:r.icon,alt:r.title,style:{width:16,height:16},fallback:Ee(r.icon)}):null,o.jsxs(C,{className:"metric-name",display:"flex",alignItems:"center",children:[r.title,r.subtitle?o.jsx(_e,{title:r.subtitle,arrow:!0,placement:"top",children:o.jsx(Io,{fontSize:"small",sx:{fontSize:14,ml:.5}})}):null]})]}),o.jsxs(C,{className:"metric-number",sx:{color:r.content_color||"rgba(3, 7, 18, 1)"},children:[r.content,r.sub_content?o.jsxs("span",{className:"sub-content",style:{color:r.sub_content_color||"rgba(156, 163, 175, 1)"},children:["(",r.sub_content,")"]}):null]})]},r.title))})}const wi=G(C)`
|
|
50
|
+
display: flex;
|
|
51
|
+
justify-content: flex-start;
|
|
52
|
+
flex-wrap: wrap;
|
|
53
|
+
gap: 16px;
|
|
54
|
+
.metric-number {
|
|
55
|
+
font-size: 18px;
|
|
56
|
+
font-weight: 600;
|
|
57
|
+
.sub-content {
|
|
58
|
+
font-size: 12px;
|
|
59
|
+
font-weight: 400;
|
|
60
|
+
margin-left: 4px;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
.metric-name {
|
|
64
|
+
font-size: 14px;
|
|
65
|
+
color: rgba(156, 163, 175, 1);
|
|
66
|
+
}
|
|
67
|
+
`;xr.propTypes={data:v.object.isRequired};function vr({data:e}){const{items:t}=e,n=Z(i=>i.breakpoints.down("sm")),r=Z(i=>i.breakpoints.down("md")),s=Z(i=>i.breakpoints.down("lg")),a=()=>n?1:r?3:s?4:6;return o.jsx(Ts,{variant:"quilted",cols:a(),gap:8,rowHeight:128,sx:{margin:0},children:t.map(i=>{const c=i.cover||i.display;return c?o.jsx("a",{href:i.link,target:"_blank",rel:"noopener noreferrer",children:o.jsx(Es,{children:o.jsx(Te,{src:c,alt:i.title||"",style:{borderRadius:"8px"},fallback:Ee(c)})})},c):null})})}vr.propTypes={data:v.object.isRequired};function Xt({data:e,feedType:t,...n}){return o.jsxs(ji,{...n,children:[t==="data-tracker"&&e.type==="table"&&o.jsx(xr,{data:e}),(t==="graphic"||t==="gallery")&&o.jsx(vr,{data:e})]})}const ji=G.div`
|
|
68
|
+
display: flex;
|
|
69
|
+
flex-direction: column;
|
|
70
|
+
width: 100%;
|
|
71
|
+
margin-bottom: 4px;
|
|
72
|
+
&:last-child {
|
|
73
|
+
margin-bottom: 0;
|
|
74
|
+
}
|
|
75
|
+
`;Xt.propTypes={data:v.object.isRequired,feedType:v.string};Xt.defaultProps={feedType:"data-tracker"};We.propTypes={data:v.object.isRequired,style:v.object};function We({data:e,style:t={}}){const r=ee().palette.mode==="dark";return o.jsx(U,{style:le({color:r&&e.darkModeColor?e.darkModeColor:e.color||"initial",margin:0,whiteSpace:"pre-line!important",...t},r),children:e.text})}function yr({data:e}){const t=[];for(let n=0;n<(e==null?void 0:e.length);n+=2){const r=e[n],s=e[n+1];r&&s?t.push(o.jsxs(Tn,{children:[o.jsx("td",{className:"label-col",children:o.jsx(We,{data:r.data,style:{whiteSpace:"nowrap"}})}),o.jsx("td",{className:"value-col",children:o.jsx(We,{data:s.data,style:{wordBreak:"break-all"}})})]},n)):r&&t.push(o.jsx(Tn,{children:o.jsx("td",{className:"label-col",children:o.jsx(We,{data:r.data})})},n))}return o.jsx("table",{style:{width:"100%"},children:o.jsx("tbody",{children:t})})}yr.propTypes={data:v.array.isRequired};const Tn=G.tr`
|
|
76
|
+
display: flex;
|
|
77
|
+
flex-direction: row;
|
|
78
|
+
justify-content: flex-start;
|
|
79
|
+
align-items: center;
|
|
80
|
+
gap: ${({theme:e})=>e.spacing(1)};
|
|
81
|
+
.label-col {
|
|
82
|
+
min-width: 130px;
|
|
83
|
+
flex-shrink: 0;
|
|
84
|
+
}
|
|
85
|
+
.value-col {
|
|
86
|
+
flex: 1;
|
|
87
|
+
}
|
|
88
|
+
`;function Jt({notification:e,severity:t,showSke:n=!0}){const{attachments:r,data:s,...a}=e,i=Z(d=>d.breakpoints.down("md"));if((!r||!r.length)&&qe(s))return null;const c=pi(t),l=(d,p=!1)=>{if(!d&&!Array.isArray(d))return null;let f=d,y={},g="horizontal";p&&mi(d)&&(f=gi(d),g="vertical",y={display:"flex",gap:8,flexDirection:"row",justifyContent:"flex-start",flexWrap:"wrap",height:"100%",width:i||f.length===1?"100%":"28%"});const h=xi(f);return o.jsx(C,{sx:{width:"100%",display:"flex",gap:1,flexDirection:p?"row":"column",justifyContent:"flex-start",alignItems:p?"center":"unset",flexWrap:"wrap"},children:f.map((_,m)=>_.type==="section"?o.jsx(yr,{data:_.fields},m):o.jsxs(x.Fragment,{children:[o.jsx(gr,{attachment:_,style:y,...a}),!(i&&g==="vertical")&&h&&f.length>1&&m!==f.length-1?o.jsx(Lt,{orientation:g,style:{color:Fs.dividerColor},sx:g==="vertical"?{ml:2,mr:2,height:32}:{}}):null]},m))})},u=hi(r);return o.jsx(Si,{children:o.jsxs("div",{className:"message-in-list",children:[r.length>0&&o.jsx("div",{className:"message-container",style:i?{width:"100%"}:{},children:u?l(r):o.jsx(Hn,{variant:"outlined",sx:{p:i?1:2,borderRadius:"8px",minWidth:128,borderColor:c},children:l(r)})}),!qe(s)&&o.jsx("div",{className:"message-container",children:o.jsx("div",{className:"data-container",children:o.jsx(Xt,{data:s,feedType:e.feedType})})}),r.length===0&&qe(s)&&n&&o.jsx(Ls,{className:"attach-ske",style:{marginTop:10},variant:"rectangular",height:150})]})})}const Si=G.div`
|
|
89
|
+
display: flex;
|
|
90
|
+
flex-direction: column;
|
|
91
|
+
.message-in-list {
|
|
92
|
+
padding: 8px 8px 8px 0;
|
|
93
|
+
display: flex;
|
|
94
|
+
border-radius: 8px;
|
|
95
|
+
}
|
|
96
|
+
.message-title {
|
|
97
|
+
color: #25292f;
|
|
98
|
+
font-size: 18px;
|
|
99
|
+
font-weight: bold;
|
|
100
|
+
word-break: break-all;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.attach-ske {
|
|
104
|
+
position: relative;
|
|
105
|
+
margin-left: 10px;
|
|
106
|
+
&::after {
|
|
107
|
+
content: '';
|
|
108
|
+
position: absolute;
|
|
109
|
+
left: -10px;
|
|
110
|
+
top: 0;
|
|
111
|
+
height: 100%;
|
|
112
|
+
width: 4px;
|
|
113
|
+
background-color: ${e=>e.leftLineColor};
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.message-body {
|
|
118
|
+
color: #25292f;
|
|
119
|
+
font-size: 16px;
|
|
120
|
+
word-break: break-all;
|
|
121
|
+
white-space: pre-line;
|
|
122
|
+
}
|
|
123
|
+
.message-container {
|
|
124
|
+
display: flex;
|
|
125
|
+
flex-direction: column;
|
|
126
|
+
justify-content: flex-start;
|
|
127
|
+
.data-container,
|
|
128
|
+
.attachment-container {
|
|
129
|
+
display: flex;
|
|
130
|
+
flex-direction: column;
|
|
131
|
+
width: 100%;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
.actions-container {
|
|
135
|
+
margin-top: 10px;
|
|
136
|
+
.actions-item {
|
|
137
|
+
margin-right: 8px;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
`;Jt.propTypes={severity:v.string.isRequired,notification:v.object.isRequired,showSke:v.bool};Jt.defaultProps={showSke:!0};const ft=e=>fs.sanitize(e,{ALLOWED_ATTR:["href","target","rel","class","id","style"]}),Ci=async(e,t)=>{const{type:n,did:r}=e;return zn.isSameAddr(n,"did")?await vi(r,t)||Xe.getLink(e):Xe.getLink(e)};function _i(e){return new TextEncoder().encode(e).length>=1e4}const Ii=async(e,t,n=!0)=>{let r=e;_i(e)&&(r=e.slice(0,1e4));const s=Xe.toTextList(r);return await Promise.all(s.map(async i=>{if(i instanceof Xe.Link){if(n){const c=await Ci(i,t),{type:l,chainId:u,did:d}=i;return zn.isSameAddr(l,"dapp")?`<em style="font-weight:bold;" data-type="${l}" data-chain-id="${u}" data-did="${d}">${i.text}</em>`:c?`<a target="_blank" rel="noopener noreferrer" style="color:#4598fa;font-weight:bold;" href="${c}">${i.text}</a>`:`<em style="font-weight:bold;" data-type="${l}" data-chain-id="${u}" data-did="${d}">${i.text}</em>`}return i.text}return i})).then(i=>i.join(""))};br.propTypes={notification:v.object,rows:v.number,minimal:v.bool};function br({notification:e,rows:t=2,minimal:n=!1}){const[r,s]=x.useState(!1),[a,i]=x.useState(""),{t:c,locale:l}=J(),{palette:u}=ee(),d=x.useMemo(()=>{const{attachments:m}=e||{};if(!m)return!1;try{return m.length>0}catch{return!1}},[e]),p=x.useMemo(()=>{const{blocks:m}=e||{};if(!m)return!1;try{return m.length>0}catch{return!1}},[e]),f=x.useMemo(()=>{const{description:m}=e||{};return!!m},[e]),y=x.useMemo(()=>{const{data:m}=e||{};return!qe(m)},[e]),g=x.useMemo(()=>d||p||f||y,[d,p,f,y]);if(x.useEffect(()=>{Ii((e==null?void 0:e.description)??"",l).then(m=>{i(m)})},[e==null?void 0:e.description,l]),!g)return null;const h=()=>t===0?"":r?`<span class='toggle-btn' data-name='toggle-expanded'>${c("common.collapse")}</span>`:`...<span class='toggle-btn' data-name='toggle-expanded'>${c("common.expand")}</span>`,_=m=>{const{target:j}=m;j.getAttribute("data-name")==="toggle-expanded"&&(s(!r),m.customPreventRedirect=!0)};return o.jsxs(ki,{color:n?u.primary.contrastText:"",children:[o.jsx(C,{className:"text-container",component:"div",onClick:_,children:a&&(!r&&t>0?o.jsx(Co,{basedOn:"letters",unsafeHTML:ft(a),maxLine:t,ellipsisHTML:ft(h())}):o.jsx(U,{component:"div",className:`content ${t===0?"ellipsis":""}`,style:{whiteSpace:"pre-line!important"},dangerouslySetInnerHTML:{__html:ft(`${a}${h()}`)}}))}),!n&&(d||y)?o.jsx(Jt,{severity:e.severity,notification:e}):null]})}const ki=G(C)`
|
|
141
|
+
width: 100%;
|
|
142
|
+
color: ${e=>e.color?e.color:e.theme.palette.text.secondary};
|
|
143
|
+
.text-container {
|
|
144
|
+
word-wrap: break-word;
|
|
145
|
+
word-break: break-all;
|
|
146
|
+
color: ${e=>e.color?e.color:e.theme.palette.text.secondary};
|
|
147
|
+
.toggle-btn {
|
|
148
|
+
display: inline-block;
|
|
149
|
+
white-space: nowrap;
|
|
150
|
+
cursor: pointer;
|
|
151
|
+
margin-left: 4px;
|
|
152
|
+
color: ${e=>e.theme.palette.secondary.main};
|
|
153
|
+
}
|
|
154
|
+
.content.ellipsis {
|
|
155
|
+
overflow: hidden;
|
|
156
|
+
text-overflow: ellipsis;
|
|
157
|
+
word-break: break-all;
|
|
158
|
+
display: block;
|
|
159
|
+
display: -webkit-box;
|
|
160
|
+
-webkit-box-orient: vertical;
|
|
161
|
+
-webkit-line-clamp: 2;
|
|
162
|
+
line-height: 1.25;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
`,Ti=x.memo(br);var D=function(t,n,r){return Fn.call(n,"css")?o.jsx(Vn,qn(t,n),r):o.jsx(t,n,r)},Be=function(t,n,r){return Fn.call(n,"css")?o.jsxs(Vn,qn(t,n),r):o.jsxs(t,n,r)};/**
|
|
166
|
+
* (c) Iconify
|
|
167
|
+
*
|
|
168
|
+
* For the full copyright and license information, please view the license.txt or license.gpl.txt
|
|
169
|
+
* files at https://github.com/iconify/iconify
|
|
170
|
+
*
|
|
171
|
+
* Licensed under MIT.
|
|
172
|
+
*
|
|
173
|
+
* @license MIT
|
|
174
|
+
* @version 3.1.1
|
|
175
|
+
*/const wr=Object.freeze({left:0,top:0,width:16,height:16}),et=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),Le=Object.freeze({...wr,...et}),gt=Object.freeze({...Le,body:"",hidden:!1});function Ei(e,t){const n={};!e.hFlip!=!t.hFlip&&(n.hFlip=!0),!e.vFlip!=!t.vFlip&&(n.vFlip=!0);const r=((e.rotate||0)+(t.rotate||0))%4;return r&&(n.rotate=r),n}function En(e,t){const n=Ei(e,t);for(const r in gt)r in et?r in e&&!(r in n)&&(n[r]=et[r]):r in t?n[r]=t[r]:r in e&&(n[r]=e[r]);return n}function Li(e,t){const n=e.icons,r=e.aliases||Object.create(null),s=Object.create(null);function a(i){if(n[i])return s[i]=[];if(!(i in s)){s[i]=null;const c=r[i]&&r[i].parent,l=c&&a(c);l&&(s[i]=[c].concat(l))}return s[i]}return Object.keys(n).concat(Object.keys(r)).forEach(a),s}function Di(e,t,n){const r=e.icons,s=e.aliases||Object.create(null);let a={};function i(c){a=En(r[c]||s[c],a)}return i(t),n.forEach(i),En(e,a)}function Pi(e,t){const n=[];if(typeof e!="object"||typeof e.icons!="object")return n;e.not_found instanceof Array&&e.not_found.forEach(s=>{t(s,null),n.push(s)});const r=Li(e);for(const s in r){const a=r[s];a&&(t(s,Di(e,s,a)),n.push(s))}return n}const je=/^[a-z0-9]+(-[a-z0-9]+)*$/,ye=(e,t,n,r="")=>{const s=e.split(":");if(e.slice(0,1)==="@"){if(s.length<2||s.length>3)return null;r=s.shift().slice(1)}if(s.length>3||!s.length)return null;if(s.length>1){const c=s.pop(),l=s.pop(),u={provider:s.length>0?s[0]:r,prefix:l,name:c};return t&&!Ge(u)?null:u}const a=s[0],i=a.split("-");if(i.length>1){const c={provider:r,prefix:i.shift(),name:i.join("-")};return t&&!Ge(c)?null:c}if(n&&r===""){const c={provider:r,prefix:"",name:a};return t&&!Ge(c,n)?null:c}return null},Ge=(e,t)=>e?!!((e.provider===""||e.provider.match(je))&&(t&&e.prefix===""||e.prefix.match(je))&&e.name.match(je)):!1,Ri={provider:"",aliases:{},not_found:{},...wr};function pt(e,t){for(const n in t)if(n in e&&typeof e[n]!=typeof t[n])return!1;return!0}function Ai(e){if(typeof e!="object"||e===null)return null;const t=e;if(typeof t.prefix!="string"||!e.icons||typeof e.icons!="object"||!pt(e,Ri))return null;const n=t.icons;for(const s in n){const a=n[s];if(!s.match(je)||typeof a.body!="string"||!pt(a,gt))return null}const r=t.aliases||Object.create(null);for(const s in r){const a=r[s],i=a.parent;if(!s.match(je)||typeof i!="string"||!n[i]&&!r[i]||!pt(a,gt))return null}return t}const tt=Object.create(null);function Mi(e,t){return{provider:e,prefix:t,icons:Object.create(null),missing:new Set}}function X(e,t){const n=tt[e]||(tt[e]=Object.create(null));return n[t]||(n[t]=Mi(e,t))}function Yt(e,t){return Ai(t)?Pi(t,(n,r)=>{r?e.icons[n]=r:e.missing.add(n)}):[]}function $i(e,t,n){try{if(typeof n.body=="string")return e.icons[t]={...n},!0}catch{}return!1}function Oi(e,t){let n=[];return(typeof e=="string"?[e]:Object.keys(tt)).forEach(s=>{(typeof s=="string"&&typeof t=="string"?[t]:Object.keys(tt[s]||{})).forEach(i=>{const c=X(s,i);n=n.concat(Object.keys(c.icons).map(l=>(s!==""?"@"+s+":":"")+i+":"+l))})}),n}let en=!1;function Ni(e){return en}function De(e){const t=typeof e=="string"?ye(e,!0,en):e;if(t){const n=X(t.provider,t.prefix),r=t.name;return n.icons[r]||(n.missing.has(r)?null:void 0)}}function Ui(e,t){const n=ye(e,!0,en);if(!n)return!1;const r=X(n.provider,n.prefix);return $i(r,n.name,t)}function jr(e,t){if(typeof e!="object")return!1;typeof t!="string"&&(t=e.provider||"");const n=e.prefix;if(!Ge({provider:t,prefix:n,name:"a"}))return!1;const r=X(t,n);return!!Yt(r,e)}function zi(e){return!!De(e)}function Bi(e){const t=De(e);return t?{...Le,...t}:null}const Sr=Object.freeze({width:null,height:null}),Cr=Object.freeze({...Sr,...et}),Hi=/(-?[0-9.]*[0-9]+[0-9.]*)/g,Fi=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function xt(e,t,n){if(t===1)return e;if(n=n||100,typeof e=="number")return Math.ceil(e*t*n)/n;if(typeof e!="string")return e;const r=e.split(Hi);if(r===null||!r.length)return e;const s=[];let a=r.shift(),i=Fi.test(a);for(;;){if(i){const c=parseFloat(a);isNaN(c)?s.push(a):s.push(Math.ceil(c*t*n)/n)}else s.push(a);if(a=r.shift(),a===void 0)return s.join("");i=!i}}const Vi=e=>e==="unset"||e==="undefined"||e==="none";function it(e,t){const n={...Le,...e},r={...Cr,...t},s={left:n.left,top:n.top,width:n.width,height:n.height};let a=n.body;[n,r].forEach(g=>{const h=[],_=g.hFlip,m=g.vFlip;let j=g.rotate;_?m?j+=2:(h.push("translate("+(s.width+s.left).toString()+" "+(0-s.top).toString()+")"),h.push("scale(-1 1)"),s.top=s.left=0):m&&(h.push("translate("+(0-s.left).toString()+" "+(s.height+s.top).toString()+")"),h.push("scale(1 -1)"),s.top=s.left=0);let b;switch(j<0&&(j-=Math.floor(j/4)*4),j=j%4,j){case 1:b=s.height/2+s.top,h.unshift("rotate(90 "+b.toString()+" "+b.toString()+")");break;case 2:h.unshift("rotate(180 "+(s.width/2+s.left).toString()+" "+(s.height/2+s.top).toString()+")");break;case 3:b=s.width/2+s.left,h.unshift("rotate(-90 "+b.toString()+" "+b.toString()+")");break}j%2===1&&(s.left!==s.top&&(b=s.left,s.left=s.top,s.top=b),s.width!==s.height&&(b=s.width,s.width=s.height,s.height=b)),h.length&&(a='<g transform="'+h.join(" ")+'">'+a+"</g>")});const i=r.width,c=r.height,l=s.width,u=s.height;let d,p;i===null?(p=c===null?"1em":c==="auto"?u:c,d=xt(p,l/u)):(d=i==="auto"?l:i,p=c===null?xt(d,u/l):c==="auto"?u:c);const f={},y=(g,h)=>{Vi(h)||(f[g]=h.toString())};return y("width",d),y("height",p),f.viewBox=s.left.toString()+" "+s.top.toString()+" "+l.toString()+" "+u.toString(),{attributes:f,body:a}}const qi=/\sid="(\S+)"/g,Wi="IconifyId"+Date.now().toString(16)+(Math.random()*16777216|0).toString(16);let Gi=0;function _r(e,t=Wi){const n=[];let r;for(;r=qi.exec(e);)n.push(r[1]);if(!n.length)return e;const s="suffix"+(Math.random()*16777216|Date.now()).toString(16);return n.forEach(a=>{const i=typeof t=="function"?t(a):t+(Gi++).toString(),c=a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+c+')([")]|\\.[a-z])',"g"),"$1"+i+s+"$3")}),e=e.replace(new RegExp(s,"g"),""),e}const ce={local:!0,session:!0},Ir={local:new Set,session:new Set};let tn=!1;function Ki(e){tn=e}const Ln="iconify2",ke="iconify",kr=ke+"-count",Dn=ke+"-version",Tr=36e5,Qi=168;function vt(e,t){try{return e.getItem(t)}catch{}}function nn(e,t,n){try{return e.setItem(t,n),!0}catch{}}function Pn(e,t){try{e.removeItem(t)}catch{}}function yt(e,t){return nn(e,kr,t.toString())}function bt(e){return parseInt(vt(e,kr))||0}let He=typeof window>"u"?{}:window;function Er(e){const t=e+"Storage";try{if(He&&He[t]&&typeof He[t].length=="number")return He[t]}catch{}ce[e]=!1}function Lr(e,t){const n=Er(e);if(!n)return;const r=vt(n,Dn);if(r!==Ln){if(r){const c=bt(n);for(let l=0;l<c;l++)Pn(n,ke+l.toString())}nn(n,Dn,Ln),yt(n,0);return}const s=Math.floor(Date.now()/Tr)-Qi,a=c=>{const l=ke+c.toString(),u=vt(n,l);if(typeof u=="string"){try{const d=JSON.parse(u);if(typeof d=="object"&&typeof d.cached=="number"&&d.cached>s&&typeof d.provider=="string"&&typeof d.data=="object"&&typeof d.data.prefix=="string"&&t(d,c))return!0}catch{}Pn(n,l)}};let i=bt(n);for(let c=i-1;c>=0;c--)a(c)||(c===i-1?(i--,yt(n,i)):Ir[e].add(c))}function Dr(){if(!tn){Ki(!0);for(const e in ce)Lr(e,t=>{const n=t.data,r=t.provider,s=n.prefix,a=X(r,s);if(!Yt(a,n).length)return!1;const i=n.lastModified||-1;return a.lastModifiedCached=a.lastModifiedCached?Math.min(a.lastModifiedCached,i):i,!0})}}function Pr(e,t){switch(e){case"local":case"session":ce[e]=t;break;case"all":for(const n in ce)ce[n]=t;break}}const wt=Object.create(null);function Rr(e,t){wt[e]=t}function jt(e){return wt[e]||wt[""]}function rn(e){let t;if(typeof e.resources=="string")t=[e.resources];else if(t=e.resources,!(t instanceof Array)||!t.length)return null;return{resources:t,path:e.path||"/",maxURL:e.maxURL||500,rotate:e.rotate||750,timeout:e.timeout||5e3,random:e.random===!0,index:e.index||0,dataAfterTimeout:e.dataAfterTimeout!==!1}}const at=Object.create(null),be=["https://api.simplesvg.com","https://api.unisvg.com"],Ke=[];for(;be.length>0;)be.length===1||Math.random()>.5?Ke.push(be.shift()):Ke.push(be.pop());at[""]=rn({resources:["https://api.iconify.design"].concat(Ke)});function Ar(e,t){const n=rn(t);return n===null?!1:(at[e]=n,!0)}function ct(e){return at[e]}function Zi(){return Object.keys(at)}const Xi=()=>{let e;try{if(e=fetch,typeof e=="function")return e}catch{}};let nt=Xi();function Ji(e){nt=e}function Yi(){return nt}function ea(e,t){const n=ct(e);if(!n)return 0;let r;if(!n.maxURL)r=0;else{let s=0;n.resources.forEach(i=>{s=Math.max(s,i.length)});const a=t+".json?icons=";r=n.maxURL-s-n.path.length-a.length}return r}function ta(e){return e===404}const na=(e,t,n)=>{const r=[],s=ea(e,t),a="icons";let i={type:a,provider:e,prefix:t,icons:[]},c=0;return n.forEach((l,u)=>{c+=l.length+1,c>=s&&u>0&&(r.push(i),i={type:a,provider:e,prefix:t,icons:[]},c=l.length),i.icons.push(l)}),r.push(i),r};function ra(e){if(typeof e=="string"){const t=ct(e);if(t)return t.path}return"/"}const sa=(e,t,n)=>{if(!nt){n("abort",424);return}let r=ra(t.provider);switch(t.type){case"icons":{const a=t.prefix,c=t.icons.join(","),l=new URLSearchParams({icons:c});r+=a+".json?"+l.toString();break}case"custom":{const a=t.uri;r+=a.slice(0,1)==="/"?a.slice(1):a;break}default:n("abort",400);return}let s=503;nt(e+r).then(a=>{const i=a.status;if(i!==200){setTimeout(()=>{n(ta(i)?"abort":"next",i)});return}return s=501,a.json()}).then(a=>{if(typeof a!="object"||a===null){setTimeout(()=>{a===404?n("abort",a):n("next",s)});return}setTimeout(()=>{n("success",a)})}).catch(()=>{n("next",s)})},oa={prepare:na,send:sa};function ia(e){const t={loaded:[],missing:[],pending:[]},n=Object.create(null);e.sort((s,a)=>s.provider!==a.provider?s.provider.localeCompare(a.provider):s.prefix!==a.prefix?s.prefix.localeCompare(a.prefix):s.name.localeCompare(a.name));let r={provider:"",prefix:"",name:""};return e.forEach(s=>{if(r.name===s.name&&r.prefix===s.prefix&&r.provider===s.provider)return;r=s;const a=s.provider,i=s.prefix,c=s.name,l=n[a]||(n[a]=Object.create(null)),u=l[i]||(l[i]=X(a,i));let d;c in u.icons?d=t.loaded:i===""||u.missing.has(c)?d=t.missing:d=t.pending;const p={provider:a,prefix:i,name:c};d.push(p)}),t}function Mr(e,t){e.forEach(n=>{const r=n.loaderCallbacks;r&&(n.loaderCallbacks=r.filter(s=>s.id!==t))})}function aa(e){e.pendingCallbacksFlag||(e.pendingCallbacksFlag=!0,setTimeout(()=>{e.pendingCallbacksFlag=!1;const t=e.loaderCallbacks?e.loaderCallbacks.slice(0):[];if(!t.length)return;let n=!1;const r=e.provider,s=e.prefix;t.forEach(a=>{const i=a.icons,c=i.pending.length;i.pending=i.pending.filter(l=>{if(l.prefix!==s)return!0;const u=l.name;if(e.icons[u])i.loaded.push({provider:r,prefix:s,name:u});else if(e.missing.has(u))i.missing.push({provider:r,prefix:s,name:u});else return n=!0,!0;return!1}),i.pending.length!==c&&(n||Mr([e],a.id),a.callback(i.loaded.slice(0),i.missing.slice(0),i.pending.slice(0),a.abort))})}))}let ca=0;function la(e,t,n){const r=ca++,s=Mr.bind(null,n,r);if(!t.pending.length)return s;const a={id:r,icons:t,callback:e,abort:s};return n.forEach(i=>{(i.loaderCallbacks||(i.loaderCallbacks=[])).push(a)}),s}function ua(e,t=!0,n=!1){const r=[];return e.forEach(s=>{const a=typeof s=="string"?ye(s,t,n):s;a&&r.push(a)}),r}var da={resources:[],index:0,timeout:2e3,rotate:750,random:!1,dataAfterTimeout:!1};function fa(e,t,n,r){const s=e.resources.length,a=e.random?Math.floor(Math.random()*s):e.index;let i;if(e.random){let S=e.resources.slice(0);for(i=[];S.length>1;){const T=Math.floor(Math.random()*S.length);i.push(S[T]),S=S.slice(0,T).concat(S.slice(T+1))}i=i.concat(S)}else i=e.resources.slice(a).concat(e.resources.slice(0,a));const c=Date.now();let l="pending",u=0,d,p=null,f=[],y=[];typeof r=="function"&&y.push(r);function g(){p&&(clearTimeout(p),p=null)}function h(){l==="pending"&&(l="aborted"),g(),f.forEach(S=>{S.status==="pending"&&(S.status="aborted")}),f=[]}function _(S,T){T&&(y=[]),typeof S=="function"&&y.push(S)}function m(){return{startTime:c,payload:t,status:l,queriesSent:u,queriesPending:f.length,subscribe:_,abort:h}}function j(){l="failed",y.forEach(S=>{S(void 0,d)})}function b(){f.forEach(S=>{S.status==="pending"&&(S.status="aborted")}),f=[]}function R(S,T,I){const E=T!=="success";switch(f=f.filter(k=>k!==S),l){case"pending":break;case"failed":if(E||!e.dataAfterTimeout)return;break;default:return}if(T==="abort"){d=I,j();return}if(E){d=I,f.length||(i.length?$():j());return}if(g(),b(),!e.random){const k=e.resources.indexOf(S.resource);k!==-1&&k!==e.index&&(e.index=k)}l="completed",y.forEach(k=>{k(I)})}function $(){if(l!=="pending")return;g();const S=i.shift();if(S===void 0){if(f.length){p=setTimeout(()=>{g(),l==="pending"&&(b(),j())},e.timeout);return}j();return}const T={status:"pending",resource:S,callback:(I,E)=>{R(T,I,E)}};f.push(T),u++,p=setTimeout($,e.rotate),n(S,t,T.callback)}return setTimeout($),m}function $r(e){const t={...da,...e};let n=[];function r(){n=n.filter(c=>c().status==="pending")}function s(c,l,u){const d=fa(t,c,l,(p,f)=>{r(),u&&u(p,f)});return n.push(d),d}function a(c){return n.find(l=>c(l))||null}return{query:s,find:a,setIndex:c=>{t.index=c},getIndex:()=>t.index,cleanup:r}}function Rn(){}const mt=Object.create(null);function pa(e){if(!mt[e]){const t=ct(e);if(!t)return;const n=$r(t),r={config:t,redundancy:n};mt[e]=r}return mt[e]}function Or(e,t,n){let r,s;if(typeof e=="string"){const a=jt(e);if(!a)return n(void 0,424),Rn;s=a.send;const i=pa(e);i&&(r=i.redundancy)}else{const a=rn(e);if(a){r=$r(a);const i=e.resources?e.resources[0]:"",c=jt(i);c&&(s=c.send)}}return!r||!s?(n(void 0,424),Rn):r.query(t,s,n)().abort}function ma(e,t){const n=e.lastModifiedCached;if(n&&n>=t)return n===t;if(e.lastModifiedCached=t,n)for(const r in ce)Lr(r,s=>{const a=s.data;return s.provider!==e.provider||a.prefix!==e.prefix||a.lastModified===t});return!0}function ha(e,t){tn||Dr();function n(r){let s;if(!ce[r]||!(s=Er(r)))return;const a=Ir[r];let i;if(a.size)a.delete(i=Array.from(a).shift());else if(i=bt(s),!yt(s,i+1))return;const c={cached:Math.floor(Date.now()/Tr),provider:e.provider,data:t};return nn(s,ke+i.toString(),JSON.stringify(c))}t.lastModified&&!ma(e,t.lastModified)||Object.keys(t.icons).length&&(t.not_found&&(t=Object.assign({},t),delete t.not_found),n("local")||n("session"))}function An(){}function ga(e){e.iconsLoaderFlag||(e.iconsLoaderFlag=!0,setTimeout(()=>{e.iconsLoaderFlag=!1,aa(e)}))}function xa(e,t){e.iconsToLoad?e.iconsToLoad=e.iconsToLoad.concat(t).sort():e.iconsToLoad=t,e.iconsQueueFlag||(e.iconsQueueFlag=!0,setTimeout(()=>{e.iconsQueueFlag=!1;const{provider:n,prefix:r}=e,s=e.iconsToLoad;delete e.iconsToLoad;let a;if(!s||!(a=jt(n)))return;a.prepare(n,r,s).forEach(c=>{Or(n,c,l=>{if(typeof l!="object")c.icons.forEach(u=>{e.missing.add(u)});else try{const u=Yt(e,l);if(!u.length)return;const d=e.pendingIcons;d&&u.forEach(p=>{d.delete(p)}),ha(e,l)}catch(u){console.error(u)}ga(e)})})}))}const va=e=>{const n=X(e.provider,e.prefix).pendingIcons;return!!(n&&n.has(e.name))},sn=(e,t)=>{const n=ua(e,!0,Ni()),r=ia(n);if(!r.pending.length){let l=!0;return t&&setTimeout(()=>{l&&t(r.loaded,r.missing,r.pending,An)}),()=>{l=!1}}const s=Object.create(null),a=[];let i,c;return r.pending.forEach(l=>{const{provider:u,prefix:d}=l;if(d===c&&u===i)return;i=u,c=d,a.push(X(u,d));const p=s[u]||(s[u]=Object.create(null));p[d]||(p[d]=[])}),r.pending.forEach(l=>{const{provider:u,prefix:d,name:p}=l,f=X(u,d),y=f.pendingIcons||(f.pendingIcons=new Set);y.has(p)||(y.add(p),s[u][d].push(p))}),a.forEach(l=>{const{provider:u,prefix:d}=l;s[u][d].length&&xa(l,s[u][d])}),t?la(t,r,a):An},ya=e=>new Promise((t,n)=>{const r=typeof e=="string"?ye(e,!0):e;if(!r){n(e);return}sn([r||e],s=>{if(s.length&&r){const a=De(r);if(a){t({...Le,...a});return}}n(e)})});function Nr(e,t){const n={...e};for(const r in t){const s=t[r],a=typeof s;r in Sr?(s===null||s&&(a==="string"||a==="number"))&&(n[r]=s):a===typeof n[r]&&(n[r]=r==="rotate"?s%4:s)}return n}const lt={...Cr,inline:!1},ht="iconify",St="iconify-inline",re="iconifyData"+Date.now();let ue=[];function Pe(e){for(let t=0;t<ue.length;t++){const n=ue[t];if((typeof n.node=="function"?n.node():n.node)===e)return n}}function Ur(e,t=!1){let n=Pe(e);return n?(n.temporary&&(n.temporary=t),n):(n={node:e,temporary:t},ue.push(n),n)}function ba(){if(document.documentElement)return Ur(document.documentElement);ue.push({node:()=>document.documentElement})}function wa(e){ue=ue.filter(t=>e!==t&&e!==(typeof t.node=="function"?t.node():t.node))}function Re(){return ue}function ja(e){const t=document;t.readyState&&t.readyState!=="loading"?e():t.addEventListener("DOMContentLoaded",e)}let Se=null;const Sa={childList:!0,subtree:!0,attributes:!0};function zr(e){if(!e.observer)return;const t=e.observer;t.pendingScan||(t.pendingScan=setTimeout(()=>{delete t.pendingScan,Se&&Se(e)}))}function Ca(e,t){if(!e.observer)return;const n=e.observer;if(!n.pendingScan)for(let r=0;r<t.length;r++){const s=t[r];if(s.addedNodes&&s.addedNodes.length>0||s.type==="attributes"&&s.target[re]!==void 0){n.paused||zr(e);return}}}function Br(e,t){e.observer.instance.observe(t,Sa)}function rt(e){let t=e.observer;if(t&&t.instance)return;const n=typeof e.node=="function"?e.node():e.node;!n||!window||(t||(t={paused:0},e.observer=t),t.instance=new window.MutationObserver(Ca.bind(null,e)),Br(e,n),t.paused||zr(e))}function Mn(){Re().forEach(rt)}function Hr(e){if(!e.observer)return;const t=e.observer;t.pendingScan&&(clearTimeout(t.pendingScan),delete t.pendingScan),t.instance&&(t.instance.disconnect(),delete t.instance)}function _a(e){const t=Se!==null;if(Se!==e&&(Se=e,t&&Re().forEach(Hr)),t){Mn();return}ja(Mn)}function Ct(e){(e?[e]:Re()).forEach(t=>{if(!t.observer){t.observer={paused:1};return}const n=t.observer;if(n.paused++,n.paused>1||!n.instance)return;n.instance.disconnect()})}function Ia(e){if(e){const t=Pe(e);t&&Ct(t)}else Ct()}function _t(e){(e?[e]:Re()).forEach(t=>{if(!t.observer){rt(t);return}const n=t.observer;if(n.paused&&(n.paused--,!n.paused)){const r=typeof t.node=="function"?t.node():t.node;if(r)n.instance?Br(t,r):rt(t);else return}})}function ka(e){if(e){const t=Pe(e);t&&_t(t)}else _t()}function Fr(e,t=!1){const n=Ur(e,t);return rt(n),n}function Vr(e){const t=Pe(e);t&&(Hr(t),wa(e))}function Ta(e,t){if(e.name!==t.name||e.mode!==t.mode)return!0;const n=e.customisations,r=t.customisations;for(const s in lt)if(n[s]!==r[s])return!0;return!1}function Ea(e,t=0){const n=e.replace(/^-?[0-9.]*/,"");function r(s){for(;s<0;)s+=4;return s%4}if(n===""){const s=parseInt(e);return isNaN(s)?0:r(s)}else if(n!==e){let s=0;switch(n){case"%":s=25;break;case"deg":s=90}if(s){let a=parseFloat(e.slice(0,e.length-n.length));return isNaN(a)?0:(a=a/s,a%1===0?r(a):0)}}return t}const La=/[\s,]+/;function Da(e,t){t.split(La).forEach(n=>{switch(n.trim()){case"horizontal":e.hFlip=!0;break;case"vertical":e.vFlip=!0;break}})}const Pa=["width","height"],Ra=["inline","hFlip","vFlip"];function Aa(e,t){return e===t||e==="true"?!0:e===""||e==="false"?!1:null}function Ma(e){const t=e.getAttribute("data-icon"),n=typeof t=="string"&&ye(t,!0);if(!n)return null;const r={...lt,inline:e.classList&&e.classList.contains(St)};Pa.forEach(c=>{const l=e.getAttribute("data-"+c);l&&(r[c]=l)});const s=e.getAttribute("data-rotate");typeof s=="string"&&(r.rotate=Ea(s));const a=e.getAttribute("data-flip");typeof a=="string"&&Da(r,a),Ra.forEach(c=>{const l="data-"+c,u=Aa(e.getAttribute(l),l);typeof u=="boolean"&&(r[c]=u)});const i=e.getAttribute("data-mode");return{name:t,icon:n,customisations:r,mode:i}}const $a="svg."+ht+", i."+ht+", span."+ht+", i."+St+", span."+St;function Oa(e){const t=[];return e.querySelectorAll($a).forEach(n=>{const r=n[re]||n.tagName.toLowerCase()!=="svg"?Ma(n):null;r&&t.push({node:n,props:r})}),t}function qr(e,t){let n=e.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const r in t)n+=" "+r+'="'+t[r]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+n+">"+e+"</svg>"}let Ce;function Na(){try{Ce=window.trustedTypes.createPolicy("iconify",{createHTML:e=>e})}catch{Ce=null}}function Ua(e){return Ce===void 0&&Na(),Ce?Ce.createHTML(e):e}function Wr(e){const t=new Set(["iconify"]);return["provider","prefix"].forEach(n=>{e[n]&&t.add("iconify--"+e[n])}),t}function Gr(e,t,n,r){const s=e.classList;if(r){const i=r.classList;Array.from(i).forEach(c=>{s.add(c)})}const a=[];return t.forEach(i=>{s.contains(i)?n.has(i)&&a.push(i):(s.add(i),a.push(i))}),n.forEach(i=>{t.has(i)||s.remove(i)}),a}function Kr(e,t,n){const r=e.style;(n||[]).forEach(a=>{r.removeProperty(a)});const s=[];for(const a in t)r.getPropertyValue(a)||(s.push(a),r.setProperty(a,t[a]));return s}function Qr(e,t,n){let r;try{r=document.createElement("span")}catch{return e}const s=t.customisations,a=it(n,s),i=e[re],c=qr(_r(a.body),{"aria-hidden":"true",role:"img",...a.attributes});r.innerHTML=Ua(c);const l=r.childNodes[0],u=e.attributes;for(let g=0;g<u.length;g++){const h=u.item(g),_=h.name;_!=="class"&&!l.hasAttribute(_)&&l.setAttribute(_,h.value)}const d=Wr(t.icon),p=Gr(l,d,new Set(i&&i.addedClasses),e),f=Kr(l,s.inline?{"vertical-align":"-0.125em"}:{},i&&i.addedStyles),y={...t,status:"loaded",addedClasses:p,addedStyles:f};return l[re]=y,e.parentNode&&e.parentNode.replaceChild(l,e),l}function za(e){return e.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function Ba(e){return"data:image/svg+xml,"+za(e)}function Ha(e){return'url("'+Ba(e)+'")'}const Fa={display:"inline-block"},It={"background-color":"currentColor"},Zr={"background-color":"transparent"},$n={image:"var(--svg)",repeat:"no-repeat",size:"100% 100%"},On={"-webkit-mask":It,mask:It,background:Zr};for(const e in On){const t=On[e];for(const n in $n)t[e+"-"+n]=$n[n]}function Nn(e){return e+(e.match(/^[-0-9.]+$/)?"px":"")}function Va(e,t,n,r){const s=t.customisations,a=it(n,s),i=a.attributes,c=e[re],l=qr(a.body,{...i,width:n.width+"",height:n.height+""}),u=Wr(t.icon),d=Gr(e,u,new Set(c&&c.addedClasses)),f={"--svg":Ha(l),width:Nn(i.width),height:Nn(i.height),...Fa,...r?It:Zr};s.inline&&(f["vertical-align"]="-0.125em");const y=Kr(e,f,c&&c.addedStyles),g={...t,status:"loaded",addedClasses:d,addedStyles:y};return e[re]=g,e}let Fe=!1;function qa(){Fe||(Fe=!0,setTimeout(()=>{Fe&&(Fe=!1,xe())}))}function xe(e,t=!1){const n=Object.create(null);function r(s,a){const{provider:i,prefix:c,name:l}=s,u=X(i,c),d=u.icons[l];if(d)return{status:"loaded",icon:d};if(u.missing.has(l))return{status:"missing"};if(a&&!va(s)){const p=n[i]||(n[i]=Object.create(null));(p[c]||(p[c]=new Set)).add(l)}return{status:"loading"}}(e?[e]:Re()).forEach(s=>{const a=typeof s.node=="function"?s.node():s.node;if(!a||!a.querySelectorAll)return;let i=!1,c=!1;function l(u,d,p){if(c||(c=!0,Ct(s)),u.tagName.toUpperCase()!=="SVG"){const f=d.mode,y=f==="mask"||(f==="bg"?!1:f==="style"?p.body.indexOf("currentColor")!==-1:null);if(typeof y=="boolean"){Va(u,d,{...Le,...p},y);return}}Qr(u,d,p)}Oa(a).forEach(({node:u,props:d})=>{const p=u[re];if(!p){const{status:y,icon:g}=r(d.icon,!0);if(g){l(u,d,g);return}i=i||y==="loading",u[re]={...d,status:y};return}let f;if(Ta(p,d)){if(f=r(d.icon,p.name!==d.name),!f.icon){i=i||f.status==="loading",Object.assign(p,{...d,status:f.status});return}}else{if(p.status!=="loading")return;if(f=r(d.icon,!1),!f.icon){p.status=f.status;return}}l(u,d,f.icon)}),s.temporary&&!i?Vr(a):t&&i?Fr(a,!0):c&&s.observer&&_t(s)});for(const s in n){const a=n[s];for(const i in a){const c=a[i];sn(Array.from(c).map(l=>({provider:s,prefix:i,name:l})),qa)}}}function Wa(e){const t=Pe(e);t?xe(t):xe({node:e,temporary:!0},!0)}function Xr(e,t,n=!1){const r=De(e);if(!r)return null;const s=ye(e),a=Nr(lt,t||{}),i=Qr(document.createElement("span"),{name:e,icon:s,customisations:a},r);return n?i.outerHTML:i}function Ga(){return"3.1.1"}function Ka(e,t){return Xr(e,t,!1)}function Qa(e,t){return Xr(e,t,!0)}function Za(e,t){const n=De(e);if(!n)return null;const r=Nr(lt,t||{});return it(n,r)}function Xa(e){e?Wa(e):xe()}if(typeof document<"u"&&typeof window<"u"){ba();const e=window;if(e.IconifyPreload!==void 0){const t=e.IconifyPreload,n="Invalid IconifyPreload syntax.";typeof t=="object"&&t!==null&&(t instanceof Array?t:[t]).forEach(r=>{try{(typeof r!="object"||r===null||r instanceof Array||typeof r.icons!="object"||typeof r.prefix!="string"||!jr(r))&&console.error(n)}catch{console.error(n)}})}setTimeout(()=>{_a(xe),xe()})}function Ja(e,t){Pr(e,t!==!1)}function Ya(e){Pr(e,!0)}Rr("",oa);if(typeof document<"u"&&typeof window<"u"){Dr();const e=window;if(e.IconifyProviders!==void 0){const t=e.IconifyProviders;if(typeof t=="object"&&t!==null)for(const n in t){const r="IconifyProviders["+n+"] is invalid.";try{const s=t[n];if(typeof s!="object"||!s||s.resources===void 0)continue;Ar(n,s)||console.error(r)}catch{console.error(r)}}}}const ec={getAPIConfig:ct,setAPIModule:Rr,sendAPIQuery:Or,setFetch:Ji,getFetch:Yi,listAPIProviders:Zi},tc={_api:ec,addAPIProvider:Ar,loadIcons:sn,loadIcon:ya,iconExists:zi,getIcon:Bi,listIcons:Oi,addIcon:Ui,addCollection:jr,replaceIDs:_r,calculateSize:xt,buildIcon:it,getVersion:Ga,renderSVG:Ka,renderHTML:Qa,renderIcon:Za,scan:Xa,observe:Fr,stopObserving:Vr,pauseObserver:Ia,resumeObserver:ka,enableCache:Ja,disableCache:Ya};try{self.Iconify===void 0&&(self.Iconify=tc)}catch{}var on={},nc=B;Object.defineProperty(on,"__esModule",{value:!0});var Jr=on.default=void 0,rc=nc(H()),sc=o;Jr=on.default=(0,rc.default)((0,sc.jsx)("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2M12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"}),"ErrorOutline");function an({infos:e}){const{t}=J(),n=new URL("https://community.arcblock.io/discussions/add");e.forEach(s=>{n.searchParams.set(s.label,s.value)});const r=e.map(s=>`* ${s.label}: ${s.value}`).join(`
|
|
176
|
+
`);return n.searchParams.set("report","server"),n.searchParams.set("context",`[Enter feedback here]
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
<!--
|
|
181
|
+
[Server Info]
|
|
182
|
+
${r}
|
|
183
|
+
* Page: ${window.location.href}
|
|
184
|
+
-->
|
|
185
|
+
`),D(C,{sx:{mx:{xs:0,md:2}},children:D(Dt,{sx:{color:"text.primary"},target:"_blank",href:n.href,rel:"noreferrer",style:{textDecoration:"underline"},children:t("common.reportIssue")})})}an.propTypes={infos:v.arrayOf(v.shape({label:v.string,value:v.string}))};an.defaultProps={infos:[]};var oc={year:{long:"year",short:"y"},day:{long:"day",short:"d"},hour:{long:"hour",short:"h"},minute:{long:"minute",short:"m"},second:{long:"second",short:"s"},millisecond:{long:"millisecond",short:"ms"},microsecond:{long:"microsecond",short:"µs"},nanosecond:{long:"nanosecond",short:"ns"}},ic={year:{long:"年",short:"年"},day:{long:"天",short:"天"},hour:{long:"小时",short:"小时"},minute:{long:"分钟",short:"分"},second:{long:"秒钟",short:"秒"},millisecond:{long:"毫秒",short:"毫秒"},microsecond:{long:"微秒",short:"微秒"},nanosecond:{long:"纳秒",short:"纳秒"}};const kt=new Map,ac=(e,t)=>{kt.set(e,t)},cc=(e="en_US")=>kt.get(e)||kt.get("en_US");var Yr={registerLang:ac,getLang:cc},lc=e=>{if(typeof e!="number")throw new TypeError("Expected a number");const t=e>0?Math.floor:Math.ceil;return{days:t(e/864e5),hours:t(e/36e5)%24,minutes:t(e/6e4)%60,seconds:t(e/1e3)%60,milliseconds:t(e)%1e3,microseconds:t(e*1e3)%1e3,nanoseconds:t(e*1e6)%1e3}};const uc=lc,{getLang:we}=Yr,dc=(e,t)=>t===1?e:`${e}s`,fc=1e-7;var pc=(e,t={})=>{if(!Number.isFinite(e))throw new TypeError("Expected a finite number");t.colonNotation&&(t.compact=!1,t.formatSubMilliseconds=!1,t.separateMilliseconds=!1,t.verbose=!1),t.compact&&(t.secondsDecimalDigits=0,t.millisecondsDecimalDigits=0);const n=we(t.locale),r=[],s=(c,l)=>{const u=Math.floor(c*10**l+fc);return(Math.round(u)/10**l).toFixed(l)},a=(c,l,u)=>{if((r.length===0||!t.colonNotation)&&c===0&&!(t.colonNotation&&l==="minute"))return;const{long:d}=n[l]||we("en_US")[l],{short:p}=n[l]||we("en_US")[l];let f=(u||c||"0").toString(),y,g;if(t.colonNotation){y=r.length>0?":":"",g="";const h=f.includes(".")?f.split(".")[0].length:f.length,_=r.length>0?2:1;f="0".repeat(Math.max(0,_-h))+f}else y="",t.locale==="zh_CN"?Object.values(i).filter(h=>h>0).length>1?!i.days&&!i.hours&&i.minutes&&t.compact?g=d:g=p:i.minutes?g=d:g=p:g=t.verbose?` ${dc(d,c)}`:p;r.push(y+f+g)},i=uc(e);if(a(Math.trunc(i.days/365),"year"),a(i.days%365,"day"),a(i.hours,"hour"),a(i.minutes,"minute"),t.separateMilliseconds||t.formatSubMilliseconds||!t.colonNotation&&e<1e3)if(a(i.seconds,"second"),t.formatSubMilliseconds)a(i.milliseconds,"millisecond"),a(i.microseconds,"microsecond"),a(i.nanoseconds,"nanosecond");else{const c=i.milliseconds+i.microseconds/1e3+i.nanoseconds/1e6,l=typeof t.millisecondsDecimalDigits=="number"?t.millisecondsDecimalDigits:0,u=c>=1?Math.round(c):Math.ceil(c),d=l?c.toFixed(l):u;a(Number.parseFloat(d,10),"millisecond",d)}else{const c=e/1e3%60,l=typeof t.secondsDecimalDigits=="number"?t.secondsDecimalDigits:1,u=s(c,l),d=t.keepDecimalsOnWholeSeconds?u:u.replace(/\.0+$/,"");a(Number.parseFloat(d,10),"second",d)}if(r.length===0){const c=(n.millisecond||we("en_US").millisecond).long,l=(n.millisecond||we("en_US").millisecond).short;return t.locale==="zh_CN"?`0${t.verbose?`${c}`:l}`:`0${t.verbose?` ${c}s`:l}`}if(t.compact)return r[0];if(typeof t.unitCount=="number"){const c=t.colonNotation?"":" ";return r.slice(0,Math.max(t.unitCount,1)).join(c)}return t.colonNotation?r.join(""):r.join(" ")};const mc=oc,hc=ic,{registerLang:cn}=Yr,es=pc;cn("en_US",mc);cn("zh_CN",hc);es.registerLang=cn;var gc=es;const ts=Rs(gc);var ln={},xc=B;Object.defineProperty(ln,"__esModule",{value:!0});var Tt=ln.default=void 0,vc=xc(H()),Un=o;Tt=ln.default=(0,vc.default)([(0,Un.jsx)("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2M12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"},"0"),(0,Un.jsx)("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"},"1")],"AccessTime");function te({children:e}){return Z(n=>n.breakpoints.down("md"))?o.jsx(_e,{enterDelay:500,leaveDelay:2e3,title:typeof e=="string"?e:"",children:o.jsx(C,{sx:{display:"flex",alignItems:"center",gap:1},children:o.jsx(Tt,{fontSize:"small"})})}):o.jsxs(C,{sx:{display:"flex",alignItems:"center",gap:1},children:[o.jsx(Tt,{fontSize:"small"}),e]})}te.propTypes={children:v.node.isRequired};const yc="https://launcher.arcblock.io/",bc=30*24*60*60*1e3;function un({launcherUrl:e,chainHost:t,nftId:n,launcherSessionId:r,...s}){var $,S,T,I,E,k;const{t:a,locale:i}=J(),c=ot(),[l,u]=tr({safeIframeRef:null,popoverAnchorEl:null}),d=x.useRef(null),p=Z(L=>L.breakpoints.down("md")),{sx:f={},...y}=s,g=p?"mobile":"desktop",h=er(async()=>{const[L,de]=await Promise.all([c.api.getLauncherSession({input:{launcherSessionId:r,launcherUrl:e}}),Zn({launcherUrl:e||yc,nftDid:n,launcherSessionId:r,locale:i})]);if(L!=null&&L.error)throw new Error(L.error);return{launcherSession:L.launcherSession,subscriptionURL:de}},[i]);if(h.loading)return o.jsx(ae,{label:o.jsxs(te,{children:[!p&&a("expiration.desktop.loading"),o.jsx(ne,{size:16})]}),variant:"success",sx:{cursor:"pointer",...f},...y});if(h.error)return console.error(h.error),o.jsx(ae,{label:o.jsx(te,{children:a(`expiration.${g}.loadFailed`)}),color:"error",variant:"success",sx:{cursor:"pointer",...f},...y,onClick:()=>h.retry()});const _=L=>{u({popoverAnchorEl:L.currentTarget})},m=()=>{u({popoverAnchorEl:null})},j=($=h.value)==null?void 0:$.launcherSession;let b="success";[M.LAUNCH_SESSION_STATUS.overdue,M.LAUNCH_SESSION_STATUS.canceled,M.LAUNCH_SESSION_STATUS.terminated].includes((T=(S=h.value)==null?void 0:S.launcherSession)==null?void 0:T.status)&&(b="error");let R=null;if(j.expirationDate&&!j.subscription){const L=me(j.expirationDate).diff(me(),"ms");R=a(`expiration.${g}.tips.${b}`,{validity:ts(L,{locale:Xn(i),compact:!0,verbose:!0})}),L>0&&L<=bc&&(b="warning")}return o.jsxs(o.Fragment,{children:[o.jsx(ae,{label:o.jsx(te,{children:R||((E=(I=j==null?void 0:j.subscription)==null?void 0:I.product)==null?void 0:E.name)||a("common.subscription")}),color:b,variant:b!=="success"?"contained":"outlined",sx:{cursor:"pointer",...f},...y,onClick:_}),o.jsx(Wn,{id:"popover-info",open:!!l.popoverAnchorEl,anchorEl:l.popoverAnchorEl,onClose:m,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:o.jsx(C,{sx:{width:{xs:"360px",md:"450px"}},children:o.jsx("iframe",{ref:d,title:a("common.subscription"),width:"100%",height:"600px",style:{border:0},src:(k=h.value)==null?void 0:k.subscriptionURL})})})]})}un.propTypes={chainHost:v.string.isRequired,nftId:v.string,launcherSessionId:v.string,sx:v.object,retention:v.number,launcherUrl:v.string.isRequired};un.defaultProps={sx:{},retention:0,nftId:"",launcherSessionId:""};const wc=30*24*60*60*1e3,jc="https://launcher.arcblock.io/";function dn({launcherUrl:e,chainHost:t,nftId:n,launcherSessionId:r,...s}){var S,T,I,E,k,L,de;const{t:a,locale:i}=J(),[c,l]=tr({safeIframeRef:null,popoverAnchorEl:null}),u=x.useRef(null),d=Z(F=>F.breakpoints.down("md")),p=ot(),{sx:f={},...y}=s,g=d?"mobile":"desktop",h=er(async()=>{const[F,Ae]=await Promise.all([p.api.getLauncherSession({input:{launcherSessionId:r||n,launcherUrl:e}}),Zn({launcherUrl:e||jc,nftDid:n,launcherSessionId:r,locale:i})]);if(F!=null&&F.error)throw new Error(F.error);return{launcherSession:F.launcherSession,subscriptionURL:Ae}},[i]);if(h.loading)return o.jsx(ae,{label:o.jsxs(te,{children:[!d&&a("expiration.desktop.loading"),o.jsx(ne,{size:16})]}),variant:"success",sx:{cursor:"pointer",...f},...y});if(h.error)return console.error(h.error),o.jsx(ae,{label:o.jsx(te,{children:a(`expiration.${g}.loadFailed`)}),color:"error",variant:"success",sx:{cursor:"pointer",...f},...y,onClick:()=>h.retry()});const _=(T=(S=h.value)==null?void 0:S.launcherSession)==null?void 0:T.expirationDate,m=me(_).isBefore(me()),j=me(_).diff(me(),"ms");let b="success";j<=wc&&(b="warning"),m&&(b="error");const R=F=>{l({popoverAnchorEl:F.currentTarget})},$=()=>{l({popoverAnchorEl:null})};return o.jsxs(o.Fragment,{children:[((E=(I=h.value)==null?void 0:I.launcherSession)==null?void 0:E.subscription)&&o.jsx(ae,{label:o.jsx(te,{children:a("expiration.desktop.nextInvoice",{date:eo(_,i)})}),color:"success",variant:"outlined",sx:{cursor:"pointer",...f},...y,onClick:R}),!((L=(k=h.value)==null?void 0:k.launcherSession)!=null&&L.subscription)&&o.jsx(ae,{label:o.jsx(te,{children:a(`expiration.${g}.tips.${b}`,{validity:ts(j,{locale:Xn(i),compact:!0,verbose:!0})})}),color:b,variant:b!=="success"?"contained":"outlined",sx:{cursor:"pointer",...f},...y,onClick:R}),o.jsx(Wn,{id:"popover-info",open:!!c.popoverAnchorEl,anchorEl:c.popoverAnchorEl,onClose:$,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},children:o.jsx(C,{sx:{width:{xs:"360px",md:"450px"}},children:o.jsx("iframe",{ref:u,title:a("common.subscription"),width:"100%",height:"600px",style:{border:0},src:(de=h.value)==null?void 0:de.subscriptionURL})})})]})}dn.propTypes={chainHost:v.string.isRequired,nftId:v.string,launcherSessionId:v.string,sx:v.object,retention:v.number,launcherUrl:v.string.isRequired};dn.defaultProps={sx:{},retention:0,nftId:"",launcherSessionId:""};var fn={},Sc=B;Object.defineProperty(fn,"__esModule",{value:!0});var ns=fn.default=void 0,Cc=Sc(H()),_c=o;ns=fn.default=(0,Cc.default)((0,_c.jsx)("path",{d:"M7 14H5v5h5v-2H7zm-2-4h2V7h3V5H5zm12 7h-3v2h5v-5h-2zM14 5v2h3v3h2V5z"}),"Fullscreen");var pn={},Ic=B;Object.defineProperty(pn,"__esModule",{value:!0});var rs=pn.default=void 0,kc=Ic(H()),Tc=o;rs=pn.default=(0,kc.default)((0,Tc.jsx)("path",{d:"M5 16h3v3h2v-5H5zm3-8H5v2h5V5H8zm6 11h2v-3h3v-2h-5zm2-11V5h-2v5h5V8z"}),"FullscreenExit");const Ec={width:24,height:24,body:'<path fill="currentColor" d="M6.4 18L5 16.6L14.6 7H6V5h12v12h-2V8.4L6.4 18Z"/>'};function mn({children:e,style:t,...n}){return o.jsx(Vs,{style:t,...n,children:e})}mn.propTypes={children:v.any.isRequired,style:v.object};mn.defaultProps={style:{}};const O={yellow:"#FFCF71",grey:"#aaaaaa",reverse:"#444",success:"#3ab39d",running:"#34BE74",error:"#D0021B",primary:"#1DC1C7"},Qe={added:O.grey,waiting:O.yellow,downloading:O.yellow,extracting:O.yellow,downloaded:O.grey,installing:O.yellow,installed:O.grey,starting:O.yellow,running:O.running,stopping:O.yellow,stopped:O.reverse,error:O.error,upgrading:O.yellow,restarting:O.yellow,corrupted:O.error,deleting:O.yellow,resource:O.primary},Lc={added:"primary",waiting:"info",downloading:"info",extracting:"info",downloaded:"primary",installing:"info",installed:"primary",starting:"info",running:"success",stopping:"warning",stopped:"reverse",error:"error",upgrading:"info",restarting:"info",corrupted:"error",deleting:"warning",resource:"primary"};function ss({isResource:e,status:t,variant:n,source:r,progress:s,...a}){const{t:i}=x.useContext(Pt),c=N.isInProgress(t),l=e&&t==="stopped"?"resource":t,u=i(`blocklet.status.${l}`);return n==="pin"?o.jsx(_e,{title:i("blocklet.statusTip",{status:u}),children:o.jsxs(C,{position:"relative",minHeight:14,minWidth:14,display:"flex",alignItems:"center",justifyContent:"center",...a,children:[o.jsx(C,{position:"absolute",width:"100%",height:"100%",borderRadius:"50%",bgcolor:Qe[l],style:{opacity:.15}}),o.jsx(C,{position:"absolute",width:"55%",height:"55%",borderRadius:"50%",bgcolor:Qe[l]})]})}):n==="dot"?o.jsx(_e,{title:i("blocklet.statusTip",{status:u}),children:o.jsx(ko,{color:Qe[l],...a})}):o.jsxs(mn,{type:Lc[l],...a,children:[c&&o.jsx(ne,{size:12,color:"inherit",style:{marginRight:5}}),u,l==="downloading"&&s?o.jsx("div",{style:{marginLeft:5},children:`${s} %`}):null]})}ss.propTypes={status:v.string.isRequired,variant:v.oneOf(["dot","tag","pin"]),source:v.string,progress:v.number,isResource:v.bool};ss.defaultProps={isResource:!1,variant:"tag",source:"",progress:0};function Dc(){const{inFullPage:e,toggleFullPage:t}=hs();return D(Et,{onClick:t,children:e?D(rs,{sx:{transform:"scale(1.3)"}}):D(ns,{sx:{transform:"scale(1.3)"}})})}function hn({children:e}){var _;const{t}=J(),{loading:n,error:r,actions:{refreshBlocklet:s},env:a,blocklet:i}=ve(),{info:c}=to(),l=As(),u=Z(m=>m.breakpoints.down("md")),{appId:d,version:p}=a,f=[{label:"App ID",value:d},{label:"App Version",value:p},{label:"App Bundle Name",value:(_=i==null?void 0:i.meta)==null?void 0:_.bundleName},{label:"Server Id",value:c.did},{label:"Server Version",value:c.version}],y=m=>{var b,R,$,S;const j=Array.isArray(m)?m:[m];if(u||j.unshift(D(Dc,{})),i){const T={cursor:"pointer",marginRight:{xs:"8px",md:"48px"}};no(i)?j.unshift(D(un,{chainHost:(b=i==null?void 0:i.controller)==null?void 0:b.chainHost,nftId:(R=i==null?void 0:i.controller)==null?void 0:R.nftId,launcherSessionId:($=i==null?void 0:i.controller)==null?void 0:$.launcherSessionId,launcherUrl:(S=i==null?void 0:i.controller)==null?void 0:S.launcherUrl,sx:T})):c.ownerNft&&c.launcher&&j.unshift(D(dn,{chainHost:c.launcher.chainHost,launcherUrl:c.launcher.url,nftId:c.ownerNft.did,launcherSessionId:c.ownerNft.launcherSessionId,sx:T}))}return j},g=_o({blocklet:i}),h={logo:g?D("img",{src:g,alt:"logo"}):null,brandAddon:D(C,{children:i&&Be(C,{component:"a",target:"_blank",href:window.blocklet.appUrl,rel:"noopener noreferrer",title:window.blocklet.appName,display:"flex",alignItems:"center",flexWrap:"wrap",gap:1,sx:{py:1,px:2,border:"1px solid",borderColor:"text.disabled",borderRadius:"30px",cursor:"pointer"},children:[D(_e,{title:N.isRunning(i==null?void 0:i.status)?void 0:t(`blocklet.status.${i==null?void 0:i.status}`),children:D(C,{sx:{width:8,height:8,borderRadius:"50%"},bgcolor:Qe[i==null?void 0:i.status]})}),D(C,{sx:{lineHeight:1,color:"text.secondary",maxWidth:u?66:240,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:N.getDisplayName(i)}),D(C,{component:qs,icon:Ec,sx:{color:"text.secondary"}})]})})};return Be(Pc,{legacy:!1,fullWidth:!0,headerAddons:y,headerProps:h,footerProps:{addon:D(an,{infos:f})},children:[!i&&n&&D(Je,{relative:"parent",children:D(ne,{})}),!i&&r&&Be(Je,{relative:"parent",children:[Be(C,{display:"flex",alignItems:"center",children:[D(Jr,{color:"error",sx:{marginRight:1}}),Mt(r)]}),D(Rt,{onClick:()=>s(),children:D("span",{style:{textDecoration:"underline"},children:t("common.retry")})})]}),!!i&&D(C,{flex:1,padding:u?2:3,display:"flex",flexDirection:"column",children:D(Ws,{FallbackComponent:ms,resetKeys:[l.pathname],children:e})})]})}hn.propTypes={children:v.any};hn.defaultProps={children:null};const Pc=G(ps)`
|
|
186
|
+
div.dashboard-content {
|
|
187
|
+
padding: 0;
|
|
188
|
+
}
|
|
189
|
+
.header-addons .locales {
|
|
190
|
+
max-height: 400px;
|
|
191
|
+
overflow-y: auto;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
.header-brand-addon {
|
|
195
|
+
display: block;
|
|
196
|
+
}
|
|
197
|
+
`;function Rc(){var _;const{t:e,locale:t}=J(),{blocklet:n,launcherSession:r,refreshSubscription:s}=ve(),{connectApi:a,session:i,api:c}=ro(),[l,u]=x.useState(!1),[d,p]=x.useState(""),[f,y]=bo({subscriptionURL:"#"});if(x.useEffect(()=>{var m,j;bn(n,r)&&so({launcherSessionId:(m=n==null?void 0:n.controller)==null?void 0:m.launcherSessionId,launcherUrl:(j=n==null?void 0:n.controller)==null?void 0:j.launcherUrl,locale:t}).then(b=>{y({subscriptionURL:b})}).catch(b=>{console.error("get subscription url error:",b)})},[n,r]),x.useEffect(()=>{var m;if((m=n.controller)!=null&&m.launcherUrl){const j=he(n.controller.launcherUrl,"__blocklet__.js?type=json");fetch(j).then(b=>b.json()).then(b=>{var S,T;const R=(T=(S=b.componentMountPoints)==null?void 0:S.find(I=>I.did==="z2qaCNvKMv5GjouKdcDWexv6WqtHbpNPQDnAk"))==null?void 0:T.mountPoint,$=he(n.controller.launcherUrl,R);p($)})}},[(_=n.controller)==null?void 0:_.launcherUrl]),!wn(r)&&(!n||!r||!oo(n)||r.status===M.LAUNCH_SESSION_STATUS.installed))return"";let g=null,h="";return wn(r)?(g=o.jsx(Ds,{onClick:()=>u(!0),children:e("blocklet.paynow")}),h=e("blocklet.suspendedCausedByExpired",{deadline:dt(r==null?void 0:r.reservedUntil,t)})):bn(n,r)?(g=o.jsx(Dt,{href:f.subscriptionURL,children:e("blocklet.manageSubscription")}),h=e("blocklet.suspendedCausedByExpired",{deadline:dt(r==null?void 0:r.reservedUntil,t)})):io(n,r)&&(g=o.jsx(Gn,{to:he(M.WELLKNOWN_BLOCKLET_ADMIN_PATH,"/did-spaces"),children:e("common.backup")}),h=e("blocklet.suspendedCausedByTerminated",{canceledAt:dt(r==null?void 0:r.terminatedAt,t),deadline:ao(r==null?void 0:r.terminatedAt,t)})),o.jsxs(C,{component:Gs,type:"error",sx:{"&> .alert-content":{display:"block"}},children:[l&&d&&r&&o.jsx(co,{session:i,connect:a,baseUrl:d,authToken:r.subscription.authToken,children:o.jsx(lo,{dialogProps:{open:l,onClose:()=>u(!1)},subscriptionId:r.subscription.id,successToast:!0,onPaid:()=>{c.post("/blocklet/start?fromSetup=1"),s(),u(!1)}})}),h,o.jsx(U,{component:"span",sx:{marginLeft:"4px"},children:g})]})}const os=x.createContext({});function Ll(){return x.useContext(os)}const{Provider:Ac,Consumer:Dl}=os,{did:W,appId:Mc}=window.env;function $c({children:e}){var S,T;const{t,locale:n}=J(),{blocklet:r}=ve(),[s,a]=x.useState([]),[i,c]=x.useState([]),[l,u]=x.useState([]),d=N.getDisplayName(r),p=((S=((r==null?void 0:r.environments)||[]).find(I=>I.key===ie.BLOCKLET_CONFIGURABLE_KEY.BLOCKLET_PASSPORT_COLOR))==null?void 0:S.value)||"auto",f=(r==null?void 0:r.trustedPassports)||[],y=(r==null?void 0:r.trustedFactories)||[],g=(r==null?void 0:r.enablePassportIssuance)!==!1,h=async()=>{try{const I=await Ue.doBatchQuery({getRoles:{input:{teamDid:W}},getPermissions:{input:{teamDid:W}},getInvitations:{input:{teamDid:W}}}),E=(I.getRoles.roles||[]).filter(k=>!M.RBAC_CONFIG.roles.some(L=>L.name===k.name&&(!L.passport||L.ci))).map(k=>(k.hasDescription=!!k.description,k.hasDescription||(k.description=t("team.passport.description",{teamName:d,title:k.title})),k));c(vo(E,[k=>uo(k.name)],["desc"])),u(I.getPermissions.permissions||[]),a(I.getInvitations.invitations||[])}catch(I){Q.error(I.message)}},_=({did:I}={})=>{const E={teamDid:W,user:{did:I}};return Ue.getUser({input:E})},m=({query:I,paging:E}={})=>{const k={teamDid:W};return E&&(k.paging=E),I&&(k.query=I),k.sort={lastLoginAt:-1},Ue.getUsers({input:k})},j=()=>Ue.getUsersCountPerRole({input:{teamDid:W}}),b=()=>h();x.useEffect(()=>{var I;(I=r==null?void 0:r.meta)!=null&&I.did&&h()},[(T=r==null?void 0:r.meta)==null?void 0:T.did]),x.useEffect(()=>{c(I=>I.map(E=>(E.hasDescription||(E.description=t("team.passport.description",{teamName:d,title:E.title})),{...E})))},[t,n]);const R=I=>{I.teamDid===W&&h()};Ve(ie.TeamEvents.userAdded,R,[W]),Ve(ie.TeamEvents.userRemoved,R,[W]),Ve(ie.TeamEvents.userUpdated,R,[W]);const $={teamDid:W,teamIssuerDid:Mc,teamName:d,invitations:s,roles:i,permissions:l,trustedPassports:f,trustedFactories:y,isNodeTeam:!1,enablePassportIssuance:g,refresh:b,passportColor:p,endpoint:window.location.origin,blocklet:r,api:{getUser:_,getUsers:m,getUsersCountPerRole:j}};return o.jsx(Ac,{value:$,children:e})}const Oc=x.lazy(()=>P(()=>import("./log-D-KC9F0b.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14]))),Nc=x.lazy(()=>P(()=>import("./index-DaoLXOw4.js"),__vite__mapDeps([15,2,1,5,4,6,7,8,10,16,9,11,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,3,41,42,43,44,45,46,47]))),Uc=x.lazy(()=>P(()=>import("./index-ND58NXzr.js"),__vite__mapDeps([48,4,2,5,1,6,7,8,44,10,9,11,49,50,34,30,38,39,51,3,41,42,25,43,45,31,46,47]))),zc=x.lazy(()=>P(()=>import("./index-Cd3oZl-N.js"),__vite__mapDeps([52,2,1,9,10,4,5,6,7,8,11,53,34,30,25,23,54,13,40,55,12,26,56,46,57,58,59,60,61,28,33,62,63,64,65,66,42,67,68,69,70]))),Bc=x.lazy(()=>P(()=>import("./overview-qlJHwq1E.js"),__vite__mapDeps([71,1,2,4,5,6,7,8,10,44,72,9,11,32,45,31,23,73,74,75,60,3,30,34,41,42,25,43,46,47]))),Hc=x.lazy(()=>P(()=>import("./domains-BkjwRhdu.js"),__vite__mapDeps([76,2,4,5,1,6,7,8,9,10,11,77,50,24,25,45,31,34,30,38,39,66,26,78,46,44,32,79]))),Fc=x.lazy(()=>P(()=>import("./index-DAEEDx1o.js"),__vite__mapDeps([80,2,6,5,1,4,7,8,9,10,11,23,81,17,18,19,20,21,35,36,49,24,25,82,83,84,34,30,55,46,85,3,41,42,43,44,45,31,47]))),Vc=x.lazy(()=>P(()=>import("./appearance-58f9Dbcn.js"),__vite__mapDeps([86,5,2,4,1,6,7,8,9,10,11,49]))),qc=x.lazy(()=>P(()=>import("./audit-logs-fYqimPuZ.js"),__vite__mapDeps([87,4,2,5,1,6,7,8,35,36,3,9,10,11,68,69,44,40,70,30,34,41,42,25,43,45,31,46,47]))),Wc=x.lazy(()=>P(()=>import("./index-CmOE3ceE.js"),__vite__mapDeps([88,2,1,5,4,6,7,8,9,10,11,43,25,89,90,40,32,91,59,13,44,79,17,18,19,20,21,35,36,23,92,45,31,93,94,95,61,96,30,28,29,49,3,34,41,42,46,47]))),Gc=x.lazy(()=>P(()=>import("./config-navigation-DdXZFw0Z.js"),__vite__mapDeps([97,2,4,5,1,6,7,8,74,83,10,98,9,11,99,100,67,60,43,25,62,63,93,30,3,34,41,42,44,45,31,46,47]))),Kc=x.lazy(()=>P(()=>import("./index-Dm4t4XH1.js"),__vite__mapDeps([101,1,2,6,5,10,4,7,8,9,11,49,60,102,103,75,30,33,32,104,39,42,105,55,3,34,41,25,43,44,45,31,46,47]))),Qc=x.lazy(()=>P(()=>import("./index-ToeWiBUL.js"),__vite__mapDeps([106,4,2,5,1,6,7,8,10,9,11,105,90,72,32,36,49]))),Zc=x.lazy(()=>P(()=>import("./security-Dt3PKq-c.js"),__vite__mapDeps([107,4,2,5,1,6,7,8,9,10,11,100,108,49,3,30,34,41,42,25,43,44,45,31,46,47]))),Xc=x.lazy(()=>P(()=>import("./branding-eOJeN-jW.js"),__vite__mapDeps([109,2,1,4,5,6,7,8,10,65,110,57,84,67,9,11,24,25,43,90]))),Jc=x.lazy(()=>P(()=>import("./advanced-5oQIoiUN.js"),__vite__mapDeps([111,2,1,9,10,4,5,6,7,8,11,24,25,34,30,46,90,26,32,23,73,74,3,41,42,43,44,45,31,47]))),Yc=x.lazy(()=>P(()=>import("./traffic-BMZEqBnG.js").then(e=>e.t),__vite__mapDeps([92,2,9,1,10,4,5,6,7,8,11,45,31,93,94,95,61,96,30,28,29]))),el=x.lazy(()=>P(()=>import("./runtime-CKW1HKn_.js"),__vite__mapDeps([112,2,1,4,5,6,7,8,9,10,11,104,13,3,30,34,41,42,25,43,44,45,31,46,47]))),tl=x.lazy(()=>P(()=>import("./index-CVDucF7E.js"),__vite__mapDeps([113,2,4,5,1,6,7,8,114,30,81,17,10,18,19,20,21,23,35,36,9,11,27,28,29,34,26,66,24,25,13,38,39,49,51,44,3,41,42,43,45,31,46,47]))),nl=x.lazy(()=>P(()=>import("./list-UaF9rEdO.js"),__vite__mapDeps([115,2,4,5,1,6,7,8,10,114,45,31,22,9,11,54,26,66,34,30,81,17,18,19,20,21,23,35,36,38,39,51,44,49,3,41,42,25,43,46,47]))),rl=x.lazy(()=>P(()=>import("./component-BzBSZbVF.js"),__vite__mapDeps([116,1,2,5,4,6,7,8,10,9,11,30,117,105,24,25,114,99,96,63,26,61,95,67,118,64,58,65,33,66,34,42,23,119,120,103,75,60,110,57,121,89,82,83,68,69,98,32,3,78,49,122,102,123,85,44,93,13,41,38,39,43,45,31,46,47]))),sl=x.lazy(()=>P(()=>import("./index-BKdJfp9x.js"),__vite__mapDeps([124,1,2,4,5,6,7,8,9,10,11]))),ol=he(M.WELLKNOWN_SERVICE_PATH_PREFIX,"user","notifications"),il=e=>{const{enqueueSnackbar:t}=Qn(),n=x.useCallback(r=>Jn(ol,{id:r.id,severity:r.severity||"all",componentDid:r.source==="system"?"system":r.componentDid||"all"}),[]);Ve(`${e}/${M.EVENTS.NOTIFICATION_BLOCKLET_CREATE}`,r=>{const s=n(r),{severity:a,description:i}=r||{},c=["error","warning"].includes(a)||r.sticky;r.source==="system"&&t(i,{variant:a,autoHideDuration:c?null:5e3,content:l=>o.jsx(di,{viewAllUrl:s,keyId:l,notification:r,content:o.jsx(Ti,{notification:r,minimal:!0,rows:0})})})},[],"user")};function is({blocklet:e,isAdmin:t}){return t?o.jsx(Wc,{blocklet:e}):o.jsx(xs,{status:403})}is.propTypes={blocklet:v.object.isRequired,isAdmin:v.bool.isRequired};const al=e=>{var d,p;const{t}=J(),{blocklet:n,actions:{refreshBlocklet:r},client:s,did:a}=ve(),i=(d=n==null?void 0:n.meta)==null?void 0:d.did,c=!n||ho(n.status)?[]:N.getAppMissingConfigs(n),l={overview:[{label:t("common.overview"),value:"overview"},{label:o.jsx(Ps,{"data-cy":"blocklet-list",color:"error",variant:"dot",invisible:!c.length,children:t("common.components")}),value:"components"}],"did-connect":[{label:t("common.members"),value:"members"},{label:t("team.member.passports"),value:"passports"},{label:t("common.setting"),value:"settings"},{label:t("common.security"),value:"security"},{label:t("oauth.client.tab"),value:"oauth"}],website:[{label:t("common.domains"),value:"domains"},{label:t("common.branding"),value:"branding"},{label:t("common.theming"),value:"theming"},{label:t("common.navigation"),value:"navigation"}],operations:[{label:t("common.notificationRecords"),value:"notifications",show:e},{label:t("common.analytics"),value:"analytics"},{label:t("common.auditLogs"),value:"audit-logs"},{label:t("common.advancedConfig"),value:"advanced"}],integrations:[{label:"Webhooks",value:"webhooks",show:e},{label:t("common.accessKeys"),value:"access-keys"}],developers:[{label:t("common.logs"),value:"logs",show:((p=n==null?void 0:n.children)==null?void 0:p.length)&&n.structVersion===M.APP_STRUCT_VERSION},{label:t("common.performance"),value:"performance"},{label:t("common.docs"),value:"docs"}]},u={overview:Bc,components:rl,members:o.jsx(Nc,{type:"blocklet",createPassportSvg:jn}),passports:o.jsx(Fc,{createPassportSvg:jn}),settings:o.jsx(Qc,{orientation:"vertical"}),security:o.jsx(Zc,{}),"did-spaces":o.jsx(Kc,{navOrientation:"horizontal"}),domains:Hc,branding:o.jsx(Xc,{blocklet:n,onUpdate:r}),theming:o.jsx(Vc,{}),navigation:Gc,sitemap:o.jsx(Qs,{children:t("common.comingSoon")}),notifications:o.jsx(is,{blocklet:n,isAdmin:e}),"audit-logs":o.jsx(qc,{scope:i,categories:["blocklet","team","security","certificates","gateway"]}),analytics:o.jsx(Yc,{client:s,did:a}),advanced:o.jsx(Jc,{blocklet:n,onUpdate:r}),webhooks:o.jsx(Uc,{}),"access-keys":o.jsx(tl,{}),logs:Oc,performance:o.jsx(el,{client:s,did:a}),docs:sl,publish:o.jsx(zc,{}),oauth:o.jsx(nl,{})};return{tabGroups:l,renders:u}};function cl(){var m,j;const e=Kn(),{tab:t="overview",subtab:n}=Ms(),{blocklet:r,refreshFlag:s}=ve(),{session:a}=Yn(),i=ge(()=>{var b;return(b=a==null?void 0:a.user)==null?void 0:b.did},[a]),c=To(),l=ge(()=>{var b;return((b=a.user)==null?void 0:b.role)&&po.includes(a.user.role)},[a]);il(i);const{tabGroups:u,renders:d}=al(l),p=b=>{e(`${M.WELLKNOWN_SERVICE_PATH_PREFIX}/admin/${t}/${b}`)},f=(u[t]||[]).filter(b=>b.show===void 0||b.show),y=((m=(f||[]).find(b=>b.value===n))==null?void 0:m.value)||((j=f==null?void 0:f[0])==null?void 0:j.value)||t,g=d[y]||d.overview,h=["overview"].includes(t),_=r?o.jsxs($t,{type:"components",children:[f.length>0&&o.jsxs(C,{mb:2,display:"flex",alignItems:"center",gap:2,children:[o.jsx(Ks,{tabs:f,current:y,onChange:p,scrollButtons:"auto"}),h&&!c&&o.jsx(C,{flex:1,display:"flex",justifyContent:"flex-end",children:o.jsx(C,{component:"div",className:"page-header",children:r?o.jsx(kn,{className:"page-actions",hasPermission:!0,blocklet:r,onStart:()=>{},onComplete:({error:b}={})=>{b&&Q.error(b.message)},variant:"group"}):null})})]}),o.jsx(C,{className:"page-content",children:o.jsx(x.Suspense,{fallback:o.jsx(Je,{relative:"parent",children:o.jsx(ne,{})}),children:x.isValidElement(g)?g:o.jsx(g,{blocklet:r})})})]}):o.jsx(Je,{relative:"parent",children:o.jsx(ne,{})});return o.jsx(mo,{children:o.jsx($c,{children:o.jsx(hn,{children:o.jsxs(ul,{children:[c&&h&&o.jsx(C,{component:"div",className:"page-header",mb:2,children:r?o.jsx(kn,{className:"page-actions",hasPermission:!0,blocklet:r,onStart:()=>{},onComplete:({error:b}={})=>{b&&Q.error(b.message)},variant:"group"}):null}),o.jsx(dr,{}),o.jsx(Rc,{}),_]})},`${s}`)})})}function ll(){var r;const{blocklet:e}=ve(),{t}=J(),n=(r=e==null?void 0:e.meta)==null?void 0:r.did;return x.useEffect(()=>{const s=fo();return n&&s.connect(),()=>{n&&s.isConnected()&&s.disconnect()}},[n]),o.jsxs(o.Fragment,{children:[o.jsx(gs,{children:o.jsx("title",{children:t("pageTitle.dashboard")})}),o.jsx(cl,{})]})}const ul=G.main`
|
|
198
|
+
.page-header {
|
|
199
|
+
display: flex;
|
|
200
|
+
justify-content: space-between;
|
|
201
|
+
align-items: center;
|
|
202
|
+
flex-wrap: wrap;
|
|
203
|
+
gap: 16px;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.page-title {
|
|
207
|
+
display: flex;
|
|
208
|
+
align-items: center;
|
|
209
|
+
|
|
210
|
+
.page-link {
|
|
211
|
+
font-size: 15px;
|
|
212
|
+
margin-top: 8px;
|
|
213
|
+
margin-left: 8px;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
@media (max-width: ${e=>e.theme.breakpoints.values.md}px) {
|
|
218
|
+
.page-header {
|
|
219
|
+
flex-direction: column;
|
|
220
|
+
align-items: flex-start;
|
|
221
|
+
.page-actions,
|
|
222
|
+
.MuiButtonGroup-root {
|
|
223
|
+
width: 100%;
|
|
224
|
+
}
|
|
225
|
+
.MuiButtonGroup-root {
|
|
226
|
+
.MuiButtonBase-root {
|
|
227
|
+
flex: 1;
|
|
228
|
+
}
|
|
229
|
+
.blocklet-action-text {
|
|
230
|
+
display: none;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.page-title {
|
|
236
|
+
margin-bottom: 15px;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
`,Pl=Object.freeze(Object.defineProperty({__proto__:null,default:ll},Symbol.toStringTag,{value:"Module"}));export{ss as B,mn as W,sr as a,ir as b,rr as c,Jr as d,cr as e,pe as f,El as g,Pl as h,ts as p,Ll as u};
|