@abtnode/blocklet-services 1.16.43-beta-20250508-132430-79f0da2d → 1.16.43-beta-20250509-094134-34c76f98

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (179) hide show
  1. package/api/services/auth/session.js +9 -12
  2. package/dist/assets/{AdapterDayjs-DdJ4VT-y.js → AdapterDayjs-DWoymUZR.js} +1 -1
  3. package/dist/assets/{ArrowDropDown-eLxSrK0e.js → ArrowDropDown-oIFrKvRQ.js} +1 -1
  4. package/dist/assets/{CheckCircle-DxRgzKvx.js → CheckCircle-DKTlmPGr.js} +1 -1
  5. package/dist/assets/{ChevronLeft-B15pinY6.js → ChevronLeft-CFwnl5kG.js} +1 -1
  6. package/dist/assets/{ChevronRight-B2sjje0T.js → ChevronRight-8T5vdE8C.js} +1 -1
  7. package/dist/assets/{Community-HWgwjOzD.js → Community-BUrh_Kqh.js} +1 -1
  8. package/dist/assets/{DeleteOutline-DYyAnzFX.js → DeleteOutline-1ZpdOBb4.js} +1 -1
  9. package/dist/assets/{Done-CiSqPhhR.js → Done-1iBqzwts.js} +1 -1
  10. package/dist/assets/{Download-Zxb7WMKn.js → Download-BZiCoF-V.js} +1 -1
  11. package/dist/assets/{Edit-RoUmIPTL.js → Edit-BGameSEw.js} +1 -1
  12. package/dist/assets/{EditIcon-_JnvyTnF.js → EditIcon-Tb4i_lkD.js} +1 -1
  13. package/dist/assets/{Email-22EBBQEA.js → Email-DVjqqt2m.js} +1 -1
  14. package/dist/assets/{Error-C782OBuj.js → Error-DmLM9r9y.js} +1 -1
  15. package/dist/assets/{ExpandLess-CJztBroj.js → ExpandLess-mzw0LYV7.js} +1 -1
  16. package/dist/assets/{Google-DwaWO1n0.js → Google-DknSY4FA.js} +1 -1
  17. package/dist/assets/{Holiday-Lj9LTNQ5.js → Holiday-Aqm_6mkn.js} +1 -1
  18. package/dist/assets/{InfoOutlined-BCqZENBx.js → InfoOutlined-BMdv5FNj.js} +1 -1
  19. package/dist/assets/{Launch-BbLsJvEN.js → Launch-BGXBIBAE.js} +1 -1
  20. package/dist/assets/{LaunchOutlined-BdTDYYqz.js → LaunchOutlined-C1cAhHQM.js} +1 -1
  21. package/dist/assets/{Location-R9yMI3QX.js → Location-9D-5nMVA.js} +1 -1
  22. package/dist/assets/{LockIcon-DEqu2BZe.js → LockIcon-DJgkKDXB.js} +1 -1
  23. package/dist/assets/{Meeting-CYNfXiDR.js → Meeting-Drc_0V1u.js} +1 -1
  24. package/dist/assets/{MoreHoriz-Bp9phGCA.js → MoreHoriz-KJHmH0lv.js} +1 -1
  25. package/dist/assets/{OffSick-BWarRVS4.js → OffSick-C991mOvw.js} +1 -1
  26. package/dist/assets/{Phone-Df90pdBA.js → Phone-BfBgFKKG.js} +1 -1
  27. package/dist/assets/{PlayArrow-qTn22j6x.js → PlayArrow-CY4IxSfG.js} +1 -1
  28. package/dist/assets/{QuestionMarkCircle-DV5837_n.js → QuestionMarkCircle-dkY86QWO.js} +1 -1
  29. package/dist/assets/{ServerLogo-7OspbhQZ.js → ServerLogo-BTwLn5Zv.js} +1 -1
  30. package/dist/assets/{Timezone-BfjUkoy7.js → Timezone-BWB21Pdc.js} +1 -1
  31. package/dist/assets/{TuneOutlined-BkH0zJXZ.js → TuneOutlined-BEZh1SVU.js} +1 -1
  32. package/dist/assets/{ViewList-BBNBkCo1.js → ViewList-BwVW4Mbn.js} +1 -1
  33. package/dist/assets/{WorkingRemotely-C3lk6KRk.js → WorkingRemotely-DHNo6euv.js} +1 -1
  34. package/dist/assets/{access-control-DVj3Uudk.js → access-control-BULUPRVa.js} +1 -1
  35. package/dist/assets/{actions-CcV0Tb1p.js → actions-7FcWNRsN.js} +1 -1
  36. package/dist/assets/{add-component-core-BxVPX1qJ.js → add-component-core-BMiZ7LE5.js} +13 -13
  37. package/dist/assets/{add-resource-CR93luK2.js → add-resource-j8u2ovZD.js} +1 -1
  38. package/dist/assets/{addon-igarTbiO.js → addon-vARTsq3u.js} +1 -1
  39. package/dist/assets/advanced-u-DAzAIF.js +14 -0
  40. package/dist/assets/api-BjteVZFg.js +1 -0
  41. package/dist/assets/{appearance-CuEL_wAd.js → appearance-DROrcrHA.js} +1 -1
  42. package/dist/assets/{audit-logs-DXfN0Akp.js → audit-logs-CcVb9ghw.js} +2 -2
  43. package/dist/assets/{authorize-DyX7LBCN.js → authorize-ChpWebj3.js} +1 -1
  44. package/dist/assets/{base32-sa8QWx2s.js → base32-HzVjc8tz.js} +1 -1
  45. package/dist/assets/{branding-B8w6MlXP.js → branding-BbyygUCZ.js} +2 -2
  46. package/dist/assets/{branding-CVWmoAus.js → branding-Be5nWHmr.js} +1 -1
  47. package/dist/assets/{bundle-avatar-DJNl27pn.js → bundle-avatar-CkhAjy4c.js} +1 -1
  48. package/dist/assets/button-Bk6R99H4.js +1 -0
  49. package/dist/assets/click-to-copy-CzMRt9dA.js +1 -0
  50. package/dist/assets/{cloneDeep-DBPWtvi_.js → cloneDeep-UpFQ2VNg.js} +1 -1
  51. package/dist/assets/{complete-jXf2IsN1.js → complete-B8pYAeSZ.js} +1 -1
  52. package/dist/assets/{component-DFHLfmfe.js → component-B79RqFMg.js} +1 -1
  53. package/dist/assets/{config-E-Dkdpbo.js → config-Cr_HvxTH.js} +1 -1
  54. package/dist/assets/{config-navigation-BbbAAFTA.js → config-navigation-BEcY6Wrz.js} +3 -3
  55. package/dist/assets/{config-space-B3L4cc62.js → config-space-CxYC75c6.js} +1 -1
  56. package/dist/assets/{config-DIa982AP.js → config-zGEZcVMw.js} +1 -1
  57. package/dist/assets/{confirm-CHZbNj0g.js → confirm-qyOtSX3L.js} +1 -1
  58. package/dist/assets/{connect-60F826H5.js → connect-D3ZxLXkG.js} +1 -1
  59. package/dist/assets/{connect-xMiXau0y.js → connect-sAGOXOYo.js} +1 -1
  60. package/dist/assets/{connect-to-Do1R8dL3.js → connect-to-DjFFSoXW.js} +1 -1
  61. package/dist/assets/{content-layout-clTZd0qL.js → content-layout-HQq6mBBk.js} +1 -1
  62. package/dist/assets/{dashboard-BjhEdRo6.js → dashboard-CuF4binC.js} +12 -12
  63. package/dist/assets/{delete-confirm-D-jVITSf.js → delete-confirm-DQ_YJQpj.js} +1 -1
  64. package/dist/assets/{did-address-anPrguG7.js → did-address-Dd9R3pkY.js} +1 -1
  65. package/dist/assets/{domain-CYWI_G__.js → domain-B2_scx4B.js} +1 -1
  66. package/dist/assets/{domain-action-card-CDfoYMjV.js → domain-action-card-DE7xLk29.js} +1 -1
  67. package/dist/assets/domains-bZXw9tDX.js +1 -0
  68. package/dist/assets/{dot-Bc3KtmUA.js → dot-B5LFAb8e.js} +1 -1
  69. package/dist/assets/{email-CQL_CvUV.js → email-CWYkPTia.js} +1 -1
  70. package/dist/assets/{empty-spinner-Bm-LVesB.js → empty-spinner-g1Jw7iuj.js} +1 -1
  71. package/dist/assets/{exchange-passport-nsHr64lM.js → exchange-passport-BbC_bBga.js} +1 -1
  72. package/dist/assets/{fuel-BEbwZqYG.js → fuel-BdagEU33.js} +1 -1
  73. package/dist/assets/{gen-access-key-DsEy5ZlI.js → gen-access-key-Cf76OFN7.js} +1 -1
  74. package/dist/assets/get-safe-url-Dh8rhVin.js +1 -0
  75. package/dist/assets/get-safe-url-_fT029s-.js +1 -0
  76. package/dist/assets/{home-DUvgZ0gR.js → home-BSxVGonp.js} +1 -1
  77. package/dist/assets/{iframe-D7qMCC0L.js → iframe-DXRYs3PX.js} +1 -1
  78. package/dist/assets/{index-iTlCZ1FK.js → index-B9xM_Hng.js} +1 -1
  79. package/dist/assets/{index-BUwaZJ5Y.js → index-BFsMuPKK.js} +4 -4
  80. package/dist/assets/{index-DFkZuM1_.js → index-BPuJmMx-.js} +1 -1
  81. package/dist/assets/{index-DyU89GO9.js → index-BQJa9ZJC.js} +1 -1
  82. package/dist/assets/{index-Bpz-SuLt.js → index-BSuIcvk6.js} +12 -12
  83. package/dist/assets/{index-CiWjpC34.js → index-Bs1kxR8_.js} +1 -1
  84. package/dist/assets/{index-DiZbt9Ww.js → index-C-RHInKj.js} +4 -4
  85. package/dist/assets/{index-hgktawrH.js → index-CXDRY0Gs.js} +1 -1
  86. package/dist/assets/{index-B1yanBlZ.js → index-Cc-_2bD1.js} +1 -1
  87. package/dist/assets/{index-w68bai-3.js → index-Cy1Hvxt0.js} +1 -1
  88. package/dist/assets/{index-BJfBmMvG.js → index-CzGXBMFc.js} +1 -1
  89. package/dist/assets/{index-Pu5My3eU.js → index-DEsvwKlq.js} +1 -1
  90. package/dist/assets/{index-CYz41Upz.js → index-DF0z_zii.js} +1 -1
  91. package/dist/assets/{index-OVTGvi9j.js → index-DW75AsWb.js} +1 -1
  92. package/dist/assets/{index-BmpX2Oqa.js → index-Djpx18Tz.js} +2 -2
  93. package/dist/assets/{index-DQncaTCr.js → index-DpW-Ik8u.js} +9 -9
  94. package/dist/assets/{index-egCz4jdE.js → index-TE82Z_py.js} +1 -1
  95. package/dist/assets/{index-DBajhv2h.js → index-aMtQhU6T.js} +18 -18
  96. package/dist/assets/{index-CZqp_6Zr.js → index-aQxEawZE.js} +14 -14
  97. package/dist/assets/{index-Ctbrsvlm.js → index-cs-08BqN.js} +4 -4
  98. package/dist/assets/{index-0ncGiO4u.js → index-ftkgQlGr.js} +1 -1
  99. package/dist/assets/{index-DZ9Jqm_w.js → index-m_po8k60.js} +2 -2
  100. package/dist/assets/{index-pvu3nbgn.js → index-mbuQZLIX.js} +1 -1
  101. package/dist/assets/{index-B6vKQTr4.js → index-yiU4BWrm.js} +1 -1
  102. package/dist/assets/{invitation-DqKIvv6t.js → invitation-B8tJTJsE.js} +1 -1
  103. package/dist/assets/{invite-uMWH0SpB.js → invite-EdScAUQO.js} +1 -1
  104. package/dist/assets/{issue-passport-BurnsPQZ.js → issue-passport-CStwxDqe.js} +1 -1
  105. package/dist/assets/{item-C69diC1y.js → item-B4NAOVBY.js} +2 -2
  106. package/dist/assets/{landing-page-CUkHfAZ5.js → landing-page-CBb5_s7o.js} +1 -1
  107. package/dist/assets/{launch-result-message-CiDoyZ_1.js → launch-result-message-mW7oxgKT.js} +1 -1
  108. package/dist/assets/{layout-CLOmXrMq.js → layout-uc9mKcbg.js} +1 -1
  109. package/dist/assets/{list-D69IwVXI.js → list-BK68Cxh8.js} +8 -8
  110. package/dist/assets/{list-header-D9r1Z68x.js → list-header-D4MXeBc7.js} +1 -1
  111. package/dist/assets/localization-CJlgb0T8.js +1 -0
  112. package/dist/assets/{log-CskQJ4o-.js → log-BdBIH8S_.js} +1 -1
  113. package/dist/assets/{logger-D6jfI5U_.js → logger-DCttRmHI.js} +1 -1
  114. package/dist/assets/{login-DWvvPy3b.js → login-CKa2oQPz.js} +1 -1
  115. package/dist/assets/{login-oauth-callback-gLyMSemT.js → login-oauth-callback-DVRZRaip.js} +1 -1
  116. package/dist/assets/{logo-uploader-D5rcqbIA.js → logo-uploader-DRH-fnyc.js} +3 -3
  117. package/dist/assets/{lost-passport-BWY_TJIl.js → lost-passport-ClMglNv0.js} +1 -1
  118. package/dist/assets/{omit-CM6MPIu5.js → omit-D2k92RIF.js} +1 -1
  119. package/dist/assets/{open-window-DKiwPBLK.js → open-window-Cu3fShwR.js} +1 -1
  120. package/dist/assets/{overview-DedgPJyh.js → overview-D5q1KD9x.js} +1 -1
  121. package/dist/assets/{page-header-D7vhn9dN.js → page-header-C1NOmuYB.js} +1 -1
  122. package/dist/assets/{passport-item-B45OGe4c.js → passport-item-CjxzZUKR.js} +1 -1
  123. package/dist/assets/{permission-6aZ4MNgh.js → permission-DzaDpKIW.js} +1 -1
  124. package/dist/assets/preferences-Dmcgwjhp.js +1 -0
  125. package/dist/assets/profile-embed-DsYLFLkt.js +1 -0
  126. package/dist/assets/publish-resource--xDHKiTt.js +1 -0
  127. package/dist/assets/{react-beautiful-dnd.esm-DPnGSgvn.js → react-beautiful-dnd.esm-CrdGz16R.js} +1 -1
  128. package/dist/assets/{relative-time-CKENJIpb.js → relative-time-tY0x-ayF.js} +1 -1
  129. package/dist/assets/{runtime-Dfcxeun4.js → runtime-CRViKGyG.js} +1 -1
  130. package/dist/assets/sdk-D0dqnQoQ.js +1 -0
  131. package/dist/assets/{security-zb06EOxl.js → security-fwRPOvQx.js} +1 -1
  132. package/dist/assets/{session-Ir9UAnhf.js → session-xl6Fb2Wm.js} +1 -1
  133. package/dist/assets/{setup-Pi8eih8l.js → setup-KZaDiyeL.js} +3 -3
  134. package/dist/assets/{shorten-label-DTcisg7Q.js → shorten-label-srsBvHNw.js} +1 -1
  135. package/dist/assets/{simple-select-DpNtA3N5.js → simple-select-DyL9G1FX.js} +1 -1
  136. package/dist/assets/{slicedToArray-CM_xB2K2.js → slicedToArray-B3Jznk0w.js} +1 -1
  137. package/dist/assets/{spaces-DfgQftqB.js → spaces-BtThOmfG.js} +1 -1
  138. package/dist/assets/{start-CnF5I9iM.js → start-DNZ-ulwN.js} +1 -1
  139. package/dist/assets/{starting-progress-CUkPGiLq.js → starting-progress-CN1sTPnO.js} +1 -1
  140. package/dist/assets/{status-w7wNdwd8.js → status-kLLmMBy7.js} +1 -1
  141. package/dist/assets/{step-actions-CvAYbv4K.js → step-actions-DSriMOaL.js} +1 -1
  142. package/dist/assets/{studio-mvCiDQFy.js → studio-CqjHflyE.js} +1 -1
  143. package/dist/assets/{switch-control-BP0JyiwP.js → switch-control-DsHfwUN7.js} +1 -1
  144. package/dist/assets/{traffic-Bo3Bp96o.js → traffic-38eCC37i.js} +1 -1
  145. package/dist/assets/{transfer-DsERsnl1.js → transfer-zdDZ9_KG.js} +1 -1
  146. package/dist/assets/{unsubscribe-l6QkVxmr.js → unsubscribe-DiFsgDJ8.js} +1 -1
  147. package/dist/assets/use-blocklet-logo-OwFyCoUV.js +1 -0
  148. package/dist/assets/{use-mobile-BleYjZfN.js → use-mobile-B-WdQWoB.js} +1 -1
  149. package/dist/assets/{use-mobile-BnYZ5d8f.js → use-mobile-PBkFclTq.js} +1 -1
  150. package/dist/assets/{useAsync-BTtZas5A.js → useAsync-DV3NyLhI.js} +1 -1
  151. package/dist/assets/{useLocalStorage-C7usthsI.js → useLocalStorage-DeyICx-h.js} +1 -1
  152. package/dist/assets/{user-center-CSjvhqGU.js → user-center-D-0-UOTc.js} +1 -1
  153. package/dist/assets/{util-CRVGSd5f.js → util-CZd-jYUF.js} +1 -1
  154. package/dist/assets/{util-CKfiFLd5.js → util-DStpLP3f.js} +1 -1
  155. package/dist/assets/{vendor-arcblock-Bi9JkCAO.js → vendor-arcblock-CORkwLwW.js} +5 -5
  156. package/dist/assets/{vendor-hooks-zv9Oe7Yx.js → vendor-hooks-rDgu5KV9.js} +1 -1
  157. package/dist/assets/{vendor-mui-core-FzKVVAue.js → vendor-mui-core-DMvlMpwf.js} +1 -1
  158. package/dist/assets/{vendor-mui-x-B9zuOzS0.js → vendor-mui-x-mcVodcG2.js} +1 -1
  159. package/dist/assets/vendor-utils-rHXShPKm.js +208 -0
  160. package/dist/assets/vendor-ux-did-connect-akcz-Ldw.js +2296 -0
  161. package/dist/assets/{wrap-locale-BmmKAsYR.js → wrap-locale-NyChvVhT.js} +1 -1
  162. package/dist/index.html +6 -6
  163. package/dist/service-worker.js +1 -1
  164. package/package.json +30 -30
  165. package/dist/assets/advanced-C22Mc4mt.js +0 -14
  166. package/dist/assets/api-DPHyou8y.js +0 -1
  167. package/dist/assets/button-D0USBc4l.js +0 -1
  168. package/dist/assets/click-to-copy-Dhxc_blG.js +0 -1
  169. package/dist/assets/domains-D-YYFzTK.js +0 -1
  170. package/dist/assets/get-safe-url-CH0a4wzx.js +0 -1
  171. package/dist/assets/get-safe-url-Cn647BYQ.js +0 -1
  172. package/dist/assets/localization-CAh5vCty.js +0 -1
  173. package/dist/assets/preferences-DU_A8Q43.js +0 -1
  174. package/dist/assets/profile-embed-B8hvxRm0.js +0 -1
  175. package/dist/assets/publish-resource-riTnsr3y.js +0 -1
  176. package/dist/assets/sdk-DUAPwTSQ.js +0 -1
  177. package/dist/assets/use-blocklet-logo-BiDCl8v3.js +0 -2
  178. package/dist/assets/vendor-utils-lR6P1BXz.js +0 -208
  179. package/dist/assets/vendor-ux-did-connect-CaDmrsW1.js +0 -2296
@@ -1 +1 @@
1
- import{j as e,T as w,ap as y,e as A,v as C,aa as n,H as t}from"./vendor-mui-core-FzKVVAue.js";import{h as P,bA as z,bB as E,Z as j,bC as L}from"./vendor-ux-did-connect-CaDmrsW1.js";import{t as M}from"./vendor-arcblock-Bi9JkCAO.js";import{f as R}from"./vendor-hooks-zv9Oe7Yx.js";function H({linkProps:r,showExtra:o,...a}){return e.jsxs(w,{...a,children:["Powered by"," ",e.jsx(y,{href:"https://www.arcblock.io",target:"_blank",...r,children:"ArcBlock"}),"'s"," ",e.jsx(y,{href:"https://www.blocklet.io",target:"_blank",...r,children:"Blocklet Technology"}),o?", the decentralized web engine.":null]})}function k({did:r,children:o,title:a,description:d,actions:u,logo:i,logoSize:c,poweredBy:x,termsOfUse:m,standalone:v}){const s=(globalThis==null?void 0:globalThis.blocklet)||(globalThis==null?void 0:globalThis.env)||{},{palette:g}=A(),f=C(l=>l.breakpoints.down("lg")),B=M({meta:s}),I=R(()=>{const l=s.appPid,b=P.isEthereumDid(l),D=b?void 0:z(l);return b?E(l):D.color},[s==null?void 0:s.appPid]);if(!r)return o;a===void 0&&(a=s.appName),d===void 0&&(d=s.appDescription),i===void 0&&(i=B||""),typeof i=="string"&&(i?i=e.jsx(n,{sx:{height:c,maxHeight:c,objectFit:"contain"},component:"img",src:i,alt:`${s.appName}'s logo`}):i=e.jsx(j,{size:c,did:r,src:i,variant:"rounded"})),x===void 0&&(x=e.jsx(H,{linkProps:{color:g.text.secondary,sx:{"&:hover":{textDecoration:"underline"}}},showExtra:!f,sx:{textAlign:"center",fontSize:"12px",color:"text.secondary"}}));let p=o;!o&&!f&&(p=e.jsx(n,{sx:{filter:"blur(180px)",display:"flex"},children:e.jsx(j,{size:210,did:r,variant:"rounded"})}));const T=!!o;let h=!v;return f&&(h=!T),e.jsxs(n,{sx:{width:"100vw",minHeight:"100vh",display:"flex",justifyContent:"center",alignItems:"center",px:{xs:2,sm:4,md:8},pt:{xs:2,sm:4,md:6},pb:{xs:5,md:8},background:`radial-gradient(circle at bottom right, ${L(I,.3)} 10%, ${g.background.default} 50%)`,position:"relative"},children:[e.jsxs(n,{sx:{maxWidth:1200,display:"flex",alignItems:"center",justifyContent:[h,p].filter(Boolean).length>1?"space-between":"center",width:"100%",margin:"auto"},children:[h?e.jsxs(n,{sx:{display:"flex",flexDirection:"column",gap:1.5},children:[e.jsx(n,{sx:{display:"flex",alignItems:"center"},children:i}),e.jsx(w,{variant:"h2",sx:{fontWeight:"bold",fontSize:{sm:"2.25rem",md:"2.75rem",xl:"3.5rem"}},children:a}),d?e.jsx(n,{variant:"h5",sx:{mb:2,color:"text.secondary"},children:d}):null,u?e.jsx(n,{sx:{mt:8},children:u}):null,m?e.jsx(n,{sx:{mt:-1,color:"grey"},children:m}):null]}):null,p]}),e.jsx(n,{sx:{position:"absolute",zIndex:10,bottom:10,left:10,right:10,textAlign:"center"},children:x})]})}k.propTypes={did:t.string.isRequired,children:t.any.isRequired,title:t.any,description:t.any,logo:t.any,logoSize:t.number,actions:t.any,poweredBy:t.any,termsOfUse:t.any,standalone:t.bool};k.defaultProps={title:void 0,description:void 0,logo:void 0,logoSize:50,standalone:!1};export{k as L};
1
+ import{j as e,T as w,ap as y,e as P,v as z,aa as n,H as t}from"./vendor-mui-core-DMvlMpwf.js";import{h as A,bf as C,bg as E,Z as j,bh as L}from"./vendor-ux-did-connect-akcz-Ldw.js";import{t as M}from"./vendor-arcblock-CORkwLwW.js";import{f as R}from"./vendor-hooks-rDgu5KV9.js";function H({linkProps:r,showExtra:o,...a}){return e.jsxs(w,{...a,children:["Powered by"," ",e.jsx(y,{href:"https://www.arcblock.io",target:"_blank",...r,children:"ArcBlock"}),"'s"," ",e.jsx(y,{href:"https://www.blocklet.io",target:"_blank",...r,children:"Blocklet Technology"}),o?", the decentralized web engine.":null]})}function k({did:r,children:o,title:a,description:d,actions:u,logo:i,logoSize:c,poweredBy:x,termsOfUse:m,standalone:v}){const s=(globalThis==null?void 0:globalThis.blocklet)||(globalThis==null?void 0:globalThis.env)||{},{palette:g}=P(),f=z(l=>l.breakpoints.down("lg")),I=M({meta:s}),T=R(()=>{const l=s.appPid,b=A.isEthereumDid(l),D=b?void 0:C(l);return b?E(l):D.color},[s==null?void 0:s.appPid]);if(!r)return o;a===void 0&&(a=s.appName),d===void 0&&(d=s.appDescription),i===void 0&&(i=I||""),typeof i=="string"&&(i?i=e.jsx(n,{sx:{height:c,maxHeight:c,objectFit:"contain"},component:"img",src:i,alt:`${s.appName}'s logo`}):i=e.jsx(j,{size:c,did:r,src:i,variant:"rounded"})),x===void 0&&(x=e.jsx(H,{linkProps:{color:g.text.secondary,sx:{"&:hover":{textDecoration:"underline"}}},showExtra:!f,sx:{textAlign:"center",fontSize:"12px",color:"text.secondary"}}));let p=o;!o&&!f&&(p=e.jsx(n,{sx:{filter:"blur(180px)",display:"flex"},children:e.jsx(j,{size:210,did:r,variant:"rounded"})}));const B=!!o;let h=!v;return f&&(h=!B),e.jsxs(n,{sx:{width:"100vw",minHeight:"100vh",display:"flex",justifyContent:"center",alignItems:"center",px:{xs:2,sm:4,md:8},pt:{xs:2,sm:4,md:6},pb:{xs:5,md:8},background:`radial-gradient(circle at bottom right, ${L(T,.3)} 10%, ${g.background.default} 50%)`,position:"relative"},children:[e.jsxs(n,{sx:{maxWidth:1200,display:"flex",alignItems:"center",justifyContent:[h,p].filter(Boolean).length>1?"space-between":"center",width:"100%",margin:"auto"},children:[h?e.jsxs(n,{sx:{display:"flex",flexDirection:"column",gap:1.5},children:[e.jsx(n,{sx:{display:"flex",alignItems:"center"},children:i}),e.jsx(w,{variant:"h2",sx:{fontWeight:"bold",fontSize:{sm:"2.25rem",md:"2.75rem",xl:"3.5rem"}},children:a}),d?e.jsx(n,{variant:"h5",sx:{mb:2,color:"text.secondary"},children:d}):null,u?e.jsx(n,{sx:{mt:8},children:u}):null,m?e.jsx(n,{sx:{mt:-1,color:"grey"},children:m}):null]}):null,p]}),e.jsx(n,{sx:{position:"absolute",zIndex:10,bottom:10,left:10,right:10,textAlign:"center"},children:x})]})}k.propTypes={did:t.string.isRequired,children:t.any.isRequired,title:t.any,description:t.any,logo:t.any,logoSize:t.number,actions:t.any,poweredBy:t.any,termsOfUse:t.any,standalone:t.bool};k.defaultProps={title:void 0,description:void 0,logo:void 0,logoSize:50,standalone:!1};export{k as L};
@@ -1,4 +1,4 @@
1
- import{j as t,H as i,ah as c,ag as h,ab as d,c0 as m,c1 as p}from"./vendor-mui-core-FzKVVAue.js";function l({variant:e,title:o,subTitle:s,footer:a,...n}){let r;switch(e){case"error":r=p;break;case"info":r=m;break;case"loading":r=d;break;default:r=h}return t.jsx(u,{variant:e,...n,children:t.jsxs("div",{className:"result-body",children:[t.jsx("span",{className:`result-icon color-${e}`,children:t.jsx(r,{})}),t.jsx("div",{className:`result-title color-${e} ${o?"":"ele-hide"}`,children:o}),t.jsx("div",{className:`result-sub-title ${s?"":"ele-hide"}`,children:s}),a&&t.jsx("div",{className:"result-footer",children:a})]})})}l.propTypes={variant:i.oneOf(["success","error","info","loading"]),title:i.string,subTitle:i.any,footer:i.any};l.defaultProps={variant:"success",title:"",subTitle:"",footer:null};const u=c.div`
1
+ import{j as t,H as i,ah as c,ag as h,ab as d,c0 as m,c1 as p}from"./vendor-mui-core-DMvlMpwf.js";function l({variant:e,title:o,subTitle:s,footer:a,...n}){let r;switch(e){case"error":r=p;break;case"info":r=m;break;case"loading":r=d;break;default:r=h}return t.jsx(u,{variant:e,...n,children:t.jsxs("div",{className:"result-body",children:[t.jsx("span",{className:`result-icon color-${e}`,children:t.jsx(r,{})}),t.jsx("div",{className:`result-title color-${e} ${o?"":"ele-hide"}`,children:o}),t.jsx("div",{className:`result-sub-title ${s?"":"ele-hide"}`,children:s}),a&&t.jsx("div",{className:"result-footer",children:a})]})})}l.propTypes={variant:i.oneOf(["success","error","info","loading"]),title:i.string,subTitle:i.any,footer:i.any};l.defaultProps={variant:"success",title:"",subTitle:"",footer:null};const u=c.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  align-items: center;
@@ -1,4 +1,4 @@
1
- import{j as r,ah as m}from"./vendor-mui-core-FzKVVAue.js";import{C as c}from"./content-layout-clTZd0qL.js";import{u,_ as s}from"./vendor-ux-did-connect-CaDmrsW1.js";import{c as i}from"./vendor-arcblock-Bi9JkCAO.js";import{J as p}from"./index-BUwaZJ5Y.js";const d=m(c)`
1
+ import{j as r,ah as m}from"./vendor-mui-core-DMvlMpwf.js";import{C as c}from"./content-layout-HQq6mBBk.js";import{u,_ as s}from"./vendor-ux-did-connect-akcz-Ldw.js";import{c as i}from"./vendor-arcblock-CORkwLwW.js";import{J as p}from"./index-BFsMuPKK.js";const d=m(c)`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as N,ap as se,aa as m,ah as E,T as A,v as W,X as ne,bL as Re,ad as Je,bM as et,ar as tt,ai as rt,a9 as Te,m as st,bZ as nt,y as it,s as ot,I as at}from"./vendor-mui-core-FzKVVAue.js";import{f as D,u as ee,l as lt}from"./vendor-hooks-zv9Oe7Yx.js";import{h as ct,j as Ie,Y as ie,b2 as oe,b6 as dt,u as Se,r as Me,I as $e,bD as ut}from"./vendor-ux-did-connect-CaDmrsW1.js";import{S as pt}from"./index-DFkZuM1_.js";import{B as ht}from"./bundle-avatar-DJNl27pn.js";import{a as mt,g as ae,l as ft,c as B,s as G,H as gt,u as Ae,M as Ne,b as Q,d as xt,m as yt,i as vt}from"./use-blocklet-logo-BiDCl8v3.js";import{R as Pe}from"./relative-time-CKENJIpb.js";import{ae as le,ad as ce,A as U,ag as bt,z as ze,b as _,a0 as jt}from"./vendor-utils-lR6P1BXz.js";import{u as Le,p as wt,h as X,f as De,w as kt}from"./vendor-arcblock-Bi9JkCAO.js";import{d as Ct}from"./InfoOutlined-BCqZENBx.js";import{d as Rt}from"./CheckCircle-DxRgzKvx.js";import{U as Tt,C as It,I as St}from"./index-pvu3nbgn.js";import{p as Mt}from"./util-CRVGSd5f.js";import{z as $t}from"./index-BUwaZJ5Y.js";function de({blocklet:e,style:t,size:n,...s}){const a=mt({blocklet:e,square:!0}),{variant:l}=s;return r.jsx(Y,{variant:l||"square",style:Object.assign({backgroundColor:"transparent",width:n,height:n,borderRadius:10},t),...s,children:r.jsx("img",{src:a,alt:"",style:{width:n}})})}de.propTypes={blocklet:i.object.isRequired,style:i.object,size:i.oneOfType([i.number,i.string])};de.defaultProps={style:{},size:40};function Ee({attachment:e}){const{data:t}=e,n=N();let s="";try{s=new URL(t.url).host}catch{s=t.url}return r.jsxs(se,{target:"_blank",rel:"noopener noreferrer",href:t.url,className:"link",style:{wordBreak:"break-all"},onClick:a=>{a.customPreventRedirect=!0},children:[!!s&&r.jsx("span",{className:"url",children:s}),!!t.title&&r.jsx(m,{className:"title",style:{whiteSpace:"unset"},children:t.title}),!!t.description&&r.jsx(m,{className:"description",style:{whiteSpace:"unset",color:n.palette.text.secondary},children:t.description}),!!t.image&&r.jsx("img",{src:Le.getImagePath(t.image),alt:t.title||"",height:128,style:{borderRadius:"8px",maxWidth:"256px",objectFit:"cover"}})]})}Ee.propTypes={attachment:i.object.isRequired};function _e({attachment:e}){const{data:t}=e;return r.jsx("img",{src:Le.getImagePath(t.url),alt:t.title||"",height:128,style:{borderRadius:"8px",maxWidth:"256px",objectFit:"cover"}})}_e.propTypes={attachment:i.object.isRequired};function He({attachment:e,...t}){var c;const{data:n}=e,s=((c=n.color)==null?void 0:c.toLowerCase())||t.color,a=n.size||t.size,l=n.fontWeight||t.fontWeight||400;let o="14px";return a==="small"?o="12px":a==="normal"?o="14px":a==="big"?o="16px":a==="large"&&(o="18px"),r.jsx(At,{className:"title",style:{fontSize:o,color:s,whiteSpace:"unset",fontWeight:l},children:n.text})}He.propTypes={attachment:i.object.isRequired};const At=E.span`
1
+ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as N,ap as se,aa as m,ah as E,T as A,v as W,X as ne,bL as Re,ad as Ze,bM as et,ar as tt,ai as rt,a9 as Te,m as st,bZ as nt,y as it,s as ot,I as at}from"./vendor-mui-core-DMvlMpwf.js";import{f as D,u as ee,l as lt}from"./vendor-hooks-rDgu5KV9.js";import{h as ct,aJ as dt,j as Ie,Y as ie,b2 as oe,b6 as ut,u as Se,r as Me,I as $e,bi as pt}from"./vendor-ux-did-connect-akcz-Ldw.js";import{S as ht}from"./index-BPuJmMx-.js";import{B as mt}from"./bundle-avatar-CkhAjy4c.js";import{a as ft,g as ae,c as B,s as G,H as gt,u as Ae,M as Ne,b as Q,d as xt,m as yt,i as vt}from"./use-blocklet-logo-OwFyCoUV.js";import{R as Pe}from"./relative-time-tY0x-ayF.js";import{ae as le,ad as ce,A as U,ag as bt,z as ze,b as _,a0 as jt}from"./vendor-utils-rHXShPKm.js";import{u as Le,p as wt,h as X,f as De,w as kt}from"./vendor-arcblock-CORkwLwW.js";import{d as Ct}from"./InfoOutlined-BMdv5FNj.js";import{d as Rt}from"./CheckCircle-DKTlmPGr.js";import{U as Tt,C as It,I as St}from"./index-mbuQZLIX.js";import{p as Mt}from"./util-CZd-jYUF.js";import{z as $t}from"./index-BFsMuPKK.js";function de({blocklet:e,style:t,size:n,...s}){const a=ft({blocklet:e,square:!0}),{variant:l}=s;return r.jsx(Y,{variant:l||"square",style:Object.assign({backgroundColor:"transparent",width:n,height:n,borderRadius:10},t),...s,children:r.jsx("img",{src:a,alt:"",style:{width:n}})})}de.propTypes={blocklet:i.object.isRequired,style:i.object,size:i.oneOfType([i.number,i.string])};de.defaultProps={style:{},size:40};function Ee({attachment:e}){const{data:t}=e,n=N();let s="";try{s=new URL(t.url).host}catch{s=t.url}return r.jsxs(se,{target:"_blank",rel:"noopener noreferrer",href:t.url,className:"link",style:{wordBreak:"break-all"},onClick:a=>{a.customPreventRedirect=!0},children:[!!s&&r.jsx("span",{className:"url",children:s}),!!t.title&&r.jsx(m,{className:"title",style:{whiteSpace:"unset"},children:t.title}),!!t.description&&r.jsx(m,{className:"description",style:{whiteSpace:"unset",color:n.palette.text.secondary},children:t.description}),!!t.image&&r.jsx("img",{src:Le.getImagePath(t.image),alt:t.title||"",height:128,style:{borderRadius:"8px",maxWidth:"256px",objectFit:"cover"}})]})}Ee.propTypes={attachment:i.object.isRequired};function _e({attachment:e}){const{data:t}=e;return r.jsx("img",{src:Le.getImagePath(t.url),alt:t.title||"",height:128,style:{borderRadius:"8px",maxWidth:"256px",objectFit:"cover"}})}_e.propTypes={attachment:i.object.isRequired};function He({attachment:e,...t}){var c;const{data:n}=e,s=((c=n.color)==null?void 0:c.toLowerCase())||t.color,a=n.size||t.size,l=n.fontWeight||t.fontWeight||400;let o="14px";return a==="small"?o="12px":a==="normal"?o="14px":a==="big"?o="16px":a==="large"&&(o="18px"),r.jsx(At,{className:"title",style:{fontSize:o,color:s,whiteSpace:"unset",fontWeight:l},children:n.text})}He.propTypes={attachment:i.object.isRequired};const At=E.span`
2
2
  width: 100%;
3
3
  display: -webkit-box;
4
4
  -webkit-box-orient: vertical;
@@ -7,7 +7,7 @@ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as
7
7
  text-overflow: ellipsis;
8
8
  white-space: normal;
9
9
  word-break: break-word;
10
- `,Nt=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},Pt=e=>e.every(t=>t.type==="text"),zt=e=>e.every(t=>t.type==="image"),Lt=e=>bt(e,2).map(t=>({type:"combined",items:t})).filter(t=>(t.items||[]).every(n=>{var s,a,l;return(l=(a=(s=n==null?void 0:n.data)==null?void 0:s.text)==null?void 0:a.trim)==null?void 0:l.call(a)})),Dt=e=>{if(!e.length||e.length<=1)return!1;const t=e[0].type;return e.every(n=>n.type===t)},Et=(e,t)=>{try{const n=ct.toTypeInfo(e);if(!(n.role!==void 0&&n.role!==ft.types.RoleType.ACCOUNT))return;const a=U(Ie.WELLKNOWN_SERVICE_PATH_PREFIX,"user");return ze(a,{did:e,locale:t})}catch(n){console.error(n);return}},_t=(e,t)=>{var s;const n=(s=t==null?void 0:t.componentMountPoints)==null?void 0:s.find(a=>a.did===e);return n==null?void 0:n.mountPoint},Ht=(e,t)=>{var a,l,o;if(!e)return null;if(((a=e.actions)==null?void 0:a.length)===1)return e.actions[0].link||null;const n=ae(e.activity),s=(n==null?void 0:n.metaLink)||(n==null?void 0:n.targetLink);if(s)return le(s)||ce(s)?s:U(t,s);if(((l=e.attachments)==null?void 0:l.length)===1){const c=e.attachments[0];if(c.type==="link")return((o=c.data)==null?void 0:o.url)||null}return null},te=e=>{const{receivers:t=[]}=e;return t.length?t.every(n=>n.read):!0};function qt(e){const t=e.getBoundingClientRect(),n=window.innerWidth||document.documentElement.clientWidth,s=window.innerHeight||document.documentElement.clientHeight,a=t.height,l=t.width;let o=0;t.top>=0&&t.bottom<=s?o=a:t.top<0&&t.bottom>0&&t.bottom<=s?o=t.bottom:t.top>=0&&t.top<s&&t.bottom>s?o=s-t.top:t.top<0&&t.bottom>s&&(o=s);let c=0;return t.left>=0&&t.right<=n?c=l:t.left<0&&t.right>0&&t.right<=n?c=t.right:t.left>=0&&t.left<n&&t.right>n?c=n-t.left:t.left<0&&t.right>n&&(c=n),o*c/(a*l)>=.5}const Wt=e=>{if(!e)return[];const t=[],n=5,s=Array.from(e.querySelectorAll(".notification-row")),a=s.length;for(let l=0;l<a;l+=n){const o=s.slice(l,l+n);let c=!0;for(const u of o){const x=u.id;if(qt(u))t.push(x);else{c=!1;break}}if(!c)break}return t},qe=e=>{var n;const t=[];return e&&((n=e.items)!=null&&n.length?e.items.forEach(s=>{te(s)||t.push(s)}):te(e)||t.push(e)),t},Bt=(e,t)=>{let n=[];return t.length&&t.forEach(s=>{const a=e.get(s);a&&(n=n.concat(qe(a)))}),n},H=(e,t)=>({...e,...t?{filter:"invert(1)"}:{}});ue.propTypes={locale:i.string,data:i.object.isRequired};ue.defaultProps={locale:"en"};function ue({locale:e="en",data:t}){const n={zh:"来自",en:"from"}[e]||"from",s={zh:"接收",en:"Received"}[e]||"Received",l=`https://${B.getUrlHost(t.chainHost)||B.getChainHost(t.chainId)}/explorer/tokens/${t.address}/tx`,o=N(),c=o.palette.mode==="dark";let u=t.amount;t.decimal&&(u=t.amount/10**t.decimal);const x=D(()=>({display:"flex",alignItems:"center",rowGap:2,columnGap:4,justifyContent:"space-between",flexWrap:"wrap"}));return r.jsx("a",{href:l,target:"_blank",rel:"noreferrer",onClick:y=>{y.customPreventRedirect=!0},children:r.jsxs(m,{display:"flex",flexDirection:"column",children:[r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",sx:{fontWeight:700,color:o.palette.text.primary},children:s}),r.jsxs(A,{component:"div",align:"right",style:H(G.summaryStyle,c),flex:1,children:["+",u," ",t.symbol]})]}),r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",style:H({...G.remarkStyle,fontSize:14},c),children:n}),r.jsx(m,{maxWidth:260,fontSize:14,children:r.jsx(ie,{did:t.address,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:e})})]})]})})}pe.propTypes={locale:i.string,data:i.object.isRequired};pe.defaultProps={locale:"en"};function pe({locale:e,data:t}){var y,b;const n={zh:"接收",en:"Received"}[e]||"Received",s={zh:"来自",en:"from"}[e]||"from",a=B.getUrlHost(t.chainHost)||B.getChainHost(t.chainId),l=t.did||((b=(y=t==null?void 0:t.credential)==null?void 0:y.issuer)==null?void 0:b.id)||"",o=`https://${a}/explorer/assets/${l}`,u=N().palette.mode==="dark",x=D(()=>({display:"flex",alignItems:"center",rowGap:2,columnGap:4,justifyContent:"space-between",flexWrap:"wrap"}));return r.jsx(m,{sx:{pr:1},children:r.jsx("a",{href:o,target:"_blank",style:{textDecoration:"none",color:"initial",display:"block"},onClick:j=>{j.customPreventRedirect=!0},rel:"noreferrer",children:r.jsxs(m,{display:"flex",flexDirection:"column",children:[r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",sx:{fontWeight:700,color:"text.primary"},children:n}),r.jsx(A,{component:"div",align:"right",style:H(G.summaryStyle,u),children:"+1 Asset"})]}),l?r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",style:H({...G.remarkStyle,fontSize:14},u),children:s}),r.jsx(m,{maxWidth:260,fontSize:14,children:r.jsx(ie,{did:l,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:e})})]}):null]})})})}We.propTypes={data:i.object.isRequired,locale:i.string};function We({data:e,locale:t="en"}){const s=N().palette.mode==="dark";return r.jsxs("a",{href:e.url,target:"_blank",style:{display:"flex",textDecoration:"none",color:"initial"},onClick:a=>{a.customPreventRedirect=!0},rel:"noreferrer",children:[r.jsx("img",{className:"image",src:e.logo,width:50,height:50,alt:""}),r.jsxs("div",{style:{flex:1,marginLeft:"10px"},children:[r.jsx("div",{style:H({marginBottom:"6px"},s),children:e.title}),r.jsx(m,{maxWidth:260,fontSize:10,children:r.jsx(ie,{did:e.appDID,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:t})})]})]})}he.propTypes={locale:i.string,data:i.object.isRequired};he.defaultProps={locale:"en"};function he({locale:e,data:t}){const n=B.getChainHost(t.chainId),s=`https://${n}/explorer/txs/${t.hash}`,a={zh:"交易详情",en:"Transaction Details"}[e]||"Transaction Details",l={zh:"交易哈希",en:"Transaction Hash"}[e]||"Transaction Hash",o=N(),c=o.palette.mode==="dark";return r.jsxs("a",{href:s,target:"_blank",style:H({textDecoration:"none",color:"initial",display:"block",fontSize:14},c),onClick:u=>{u.customPreventRedirect=!0},rel:"noreferrer",children:[r.jsx("h6",{style:{color:o.palette.text.secondary,margin:0},children:n}),r.jsx("p",{style:{color:o.palette.warning.main,margin:0},children:a}),r.jsxs("div",{style:{wordBreak:"break-all"},children:[l,": ",t.hash]})]})}function Be({attachment:e,...t}){const{local:n}=p.useContext(oe),s=W(l=>l.breakpoints.down("md")),a=N();return r.jsxs(Ut,{...t,isMd:s,children:[e.type==="link"&&r.jsx(Ee,{attachment:e,...t,isMd:s}),e.type==="image"&&r.jsx(_e,{attachment:e,isMd:s}),e.type==="text"&&r.jsx(He,{attachment:e,isMd:s}),e.type==="token"&&r.jsx(ue,{data:e.data,local:n,isMd:s}),e.type==="asset"||e.type==="vc"?r.jsx(pe,{data:e.data,local:n,isMd:s}):null,e.type==="dapp"&&r.jsx(We,{data:e.data,local:n,isMd:s}),e.type==="transaction"&&r.jsx(he,{data:e.data,local:n,...t,isMd:s}),e.type==="divider"&&r.jsx(ne,{sx:{mb:1,mt:1},style:{color:a.palette.divider}})]})}const Ut=E.div`
10
+ `,Nt=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},Pt=e=>e.every(t=>t.type==="text"),zt=e=>e.every(t=>t.type==="image"),Lt=e=>bt(e,2).map(t=>({type:"combined",items:t})).filter(t=>(t.items||[]).every(n=>{var s,a,l;return(l=(a=(s=n==null?void 0:n.data)==null?void 0:s.text)==null?void 0:a.trim)==null?void 0:l.call(a)})),Dt=e=>{if(!e.length||e.length<=1)return!1;const t=e[0].type;return e.every(n=>n.type===t)},Et=(e,t)=>{try{const n=ct.toTypeInfo(e);if(!(n.role!==void 0&&n.role!==dt.types.RoleType.ACCOUNT))return;const a=U(Ie.WELLKNOWN_SERVICE_PATH_PREFIX,"user");return ze(a,{did:e,locale:t})}catch(n){console.error(n);return}},_t=(e,t)=>{var s;const n=(s=t==null?void 0:t.componentMountPoints)==null?void 0:s.find(a=>a.did===e);return n==null?void 0:n.mountPoint},Ht=(e,t)=>{var a,l,o;if(!e)return null;if(((a=e.actions)==null?void 0:a.length)===1)return e.actions[0].link||null;const n=ae(e.activity),s=(n==null?void 0:n.metaLink)||(n==null?void 0:n.targetLink);if(s)return le(s)||ce(s)?s:U(t,s);if(((l=e.attachments)==null?void 0:l.length)===1){const c=e.attachments[0];if(c.type==="link")return((o=c.data)==null?void 0:o.url)||null}return null},te=e=>{const{receivers:t=[]}=e;return t.length?t.every(n=>n.read):!0};function qt(e){const t=e.getBoundingClientRect(),n=window.innerWidth||document.documentElement.clientWidth,s=window.innerHeight||document.documentElement.clientHeight,a=t.height,l=t.width;let o=0;t.top>=0&&t.bottom<=s?o=a:t.top<0&&t.bottom>0&&t.bottom<=s?o=t.bottom:t.top>=0&&t.top<s&&t.bottom>s?o=s-t.top:t.top<0&&t.bottom>s&&(o=s);let c=0;return t.left>=0&&t.right<=n?c=l:t.left<0&&t.right>0&&t.right<=n?c=t.right:t.left>=0&&t.left<n&&t.right>n?c=n-t.left:t.left<0&&t.right>n&&(c=n),o*c/(a*l)>=.5}const Wt=e=>{if(!e)return[];const t=[],n=5,s=Array.from(e.querySelectorAll(".notification-row")),a=s.length;for(let l=0;l<a;l+=n){const o=s.slice(l,l+n);let c=!0;for(const u of o){const x=u.id;if(qt(u))t.push(x);else{c=!1;break}}if(!c)break}return t},qe=e=>{var n;const t=[];return e&&((n=e.items)!=null&&n.length?e.items.forEach(s=>{te(s)||t.push(s)}):te(e)||t.push(e)),t},Bt=(e,t)=>{let n=[];return t.length&&t.forEach(s=>{const a=e.get(s);a&&(n=n.concat(qe(a)))}),n},H=(e,t)=>({...e,...t?{filter:"invert(1)"}:{}});ue.propTypes={locale:i.string,data:i.object.isRequired};ue.defaultProps={locale:"en"};function ue({locale:e="en",data:t}){const n={zh:"来自",en:"from"}[e]||"from",s={zh:"接收",en:"Received"}[e]||"Received",l=`https://${B.getUrlHost(t.chainHost)||B.getChainHost(t.chainId)}/explorer/tokens/${t.address}/tx`,o=N(),c=o.palette.mode==="dark";let u=t.amount;t.decimal&&(u=t.amount/10**t.decimal);const x=D(()=>({display:"flex",alignItems:"center",rowGap:2,columnGap:4,justifyContent:"space-between",flexWrap:"wrap"}));return r.jsx("a",{href:l,target:"_blank",rel:"noreferrer",onClick:y=>{y.customPreventRedirect=!0},children:r.jsxs(m,{display:"flex",flexDirection:"column",children:[r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",sx:{fontWeight:700,color:o.palette.text.primary},children:s}),r.jsxs(A,{component:"div",align:"right",style:H(G.summaryStyle,c),flex:1,children:["+",u," ",t.symbol]})]}),r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",style:H({...G.remarkStyle,fontSize:14},c),children:n}),r.jsx(m,{maxWidth:260,fontSize:14,children:r.jsx(ie,{did:t.address,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:e})})]})]})})}pe.propTypes={locale:i.string,data:i.object.isRequired};pe.defaultProps={locale:"en"};function pe({locale:e,data:t}){var y,b;const n={zh:"接收",en:"Received"}[e]||"Received",s={zh:"来自",en:"from"}[e]||"from",a=B.getUrlHost(t.chainHost)||B.getChainHost(t.chainId),l=t.did||((b=(y=t==null?void 0:t.credential)==null?void 0:y.issuer)==null?void 0:b.id)||"",o=`https://${a}/explorer/assets/${l}`,u=N().palette.mode==="dark",x=D(()=>({display:"flex",alignItems:"center",rowGap:2,columnGap:4,justifyContent:"space-between",flexWrap:"wrap"}));return r.jsx(m,{sx:{pr:1},children:r.jsx("a",{href:o,target:"_blank",style:{textDecoration:"none",color:"initial",display:"block"},onClick:j=>{j.customPreventRedirect=!0},rel:"noreferrer",children:r.jsxs(m,{display:"flex",flexDirection:"column",children:[r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",sx:{fontWeight:700,color:"text.primary"},children:n}),r.jsx(A,{component:"div",align:"right",style:H(G.summaryStyle,u),children:"+1 Asset"})]}),l?r.jsxs(m,{sx:x,children:[r.jsx(A,{component:"div",style:H({...G.remarkStyle,fontSize:14},u),children:s}),r.jsx(m,{maxWidth:260,fontSize:14,children:r.jsx(ie,{did:l,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:e})})]}):null]})})})}We.propTypes={data:i.object.isRequired,locale:i.string};function We({data:e,locale:t="en"}){const s=N().palette.mode==="dark";return r.jsxs("a",{href:e.url,target:"_blank",style:{display:"flex",textDecoration:"none",color:"initial"},onClick:a=>{a.customPreventRedirect=!0},rel:"noreferrer",children:[r.jsx("img",{className:"image",src:e.logo,width:50,height:50,alt:""}),r.jsxs("div",{style:{flex:1,marginLeft:"10px"},children:[r.jsx("div",{style:H({marginBottom:"6px"},s),children:e.title}),r.jsx(m,{maxWidth:260,fontSize:10,children:r.jsx(ie,{did:e.appDID,showQrcode:!0,copyable:!0,compact:!0,responsive:!0,locale:t})})]})]})}he.propTypes={locale:i.string,data:i.object.isRequired};he.defaultProps={locale:"en"};function he({locale:e,data:t}){const n=B.getChainHost(t.chainId),s=`https://${n}/explorer/txs/${t.hash}`,a={zh:"交易详情",en:"Transaction Details"}[e]||"Transaction Details",l={zh:"交易哈希",en:"Transaction Hash"}[e]||"Transaction Hash",o=N(),c=o.palette.mode==="dark";return r.jsxs("a",{href:s,target:"_blank",style:H({textDecoration:"none",color:"initial",display:"block",fontSize:14},c),onClick:u=>{u.customPreventRedirect=!0},rel:"noreferrer",children:[r.jsx("h6",{style:{color:o.palette.text.secondary,margin:0},children:n}),r.jsx("p",{style:{color:o.palette.warning.main,margin:0},children:a}),r.jsxs("div",{style:{wordBreak:"break-all"},children:[l,": ",t.hash]})]})}function Be({attachment:e,...t}){const{local:n}=p.useContext(oe),s=W(l=>l.breakpoints.down("md")),a=N();return r.jsxs(Ut,{...t,isMd:s,children:[e.type==="link"&&r.jsx(Ee,{attachment:e,...t,isMd:s}),e.type==="image"&&r.jsx(_e,{attachment:e,isMd:s}),e.type==="text"&&r.jsx(He,{attachment:e,isMd:s}),e.type==="token"&&r.jsx(ue,{data:e.data,local:n,isMd:s}),e.type==="asset"||e.type==="vc"?r.jsx(pe,{data:e.data,local:n,isMd:s}):null,e.type==="dapp"&&r.jsx(We,{data:e.data,local:n,isMd:s}),e.type==="transaction"&&r.jsx(he,{data:e.data,local:n,...t,isMd:s}),e.type==="divider"&&r.jsx(ne,{sx:{mb:1,mt:1},style:{color:a.palette.divider}})]})}const Ut=E.div`
11
11
  display: ${({sx:e={}})=>e.display||"flex"};
12
12
  flex-direction: ${({sx:e={}})=>e.flexDirection||"column"};
13
13
  gap: ${({sx:e={}})=>e.gap||1};
@@ -15,7 +15,7 @@ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as
15
15
  &:last-child {
16
16
  margin-bottom: 0;
17
17
  }
18
- `;Be.propTypes={attachment:i.object.isRequired};function Ue({data:e,...t}){const{items:n}=e;return r.jsx(Ot,{...t,children:n.map(s=>r.jsxs(Re,{variant:"outlined",sx:{p:2,borderRadius:"8px",minWidth:128},children:[r.jsxs(m,{display:"flex",alignItems:"center",gap:1,children:[s.icon?r.jsx("img",{src:s.icon,alt:s.title,style:{width:16,height:16}}):null,r.jsxs(m,{className:"metric-name",display:"flex",alignItems:"center",children:[s.title,s.subtitle?r.jsx(Je,{title:s.subtitle,arrow:!0,placement:"top",children:r.jsx(Ct,{fontSize:"small",sx:{fontSize:14,ml:.5}})}):null]})]}),r.jsxs(m,{className:"metric-number",sx:{color:s.content_color||"rgba(3, 7, 18, 1)"},children:[s.content,s.sub_content?r.jsxs("span",{className:"sub-content",style:{color:s.sub_content_color||"rgba(156, 163, 175, 1)"},children:["(",s.sub_content,")"]}):null]})]},s.title))})}const Ot=E(m)`
18
+ `;Be.propTypes={attachment:i.object.isRequired};function Ue({data:e,...t}){const{items:n}=e;return r.jsx(Ot,{...t,children:n.map(s=>r.jsxs(Re,{variant:"outlined",sx:{p:2,borderRadius:"8px",minWidth:128},children:[r.jsxs(m,{display:"flex",alignItems:"center",gap:1,children:[s.icon?r.jsx("img",{src:s.icon,alt:s.title,style:{width:16,height:16}}):null,r.jsxs(m,{className:"metric-name",display:"flex",alignItems:"center",children:[s.title,s.subtitle?r.jsx(Ze,{title:s.subtitle,arrow:!0,placement:"top",children:r.jsx(Ct,{fontSize:"small",sx:{fontSize:14,ml:.5}})}):null]})]}),r.jsxs(m,{className:"metric-number",sx:{color:s.content_color||"rgba(3, 7, 18, 1)"},children:[s.content,s.sub_content?r.jsxs("span",{className:"sub-content",style:{color:s.sub_content_color||"rgba(156, 163, 175, 1)"},children:["(",s.sub_content,")"]}):null]})]},s.title))})}const Ot=E(m)`
19
19
  display: flex;
20
20
  justify-content: flex-start;
21
21
  flex-wrap: wrap;
@@ -54,7 +54,7 @@ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as
54
54
  .value-col {
55
55
  flex: 1;
56
56
  }
57
- `;function fe({notification:e,severity:t,showSke:n=!0}){const{attachments:s,data:a,...l}=e,o=W(y=>y.breakpoints.down("md"));if((!s||!s.length)&&_(a))return null;const c=Nt(t),u=(y,b=!1)=>{if(!y&&!Array.isArray(y))return null;let j=y,C={},R="horizontal";b&&Pt(y)&&(j=Lt(y),R="vertical",C={display:"flex",gap:8,flexDirection:"row",justifyContent:"flex-start",flexWrap:"wrap",height:"100%",width:o||j.length===1?"100%":"28%"});const d=Dt(j);return r.jsx(m,{sx:{width:"100%",display:"flex",gap:1,flexDirection:b?"row":"column",justifyContent:"flex-start",alignItems:b?"center":"unset",flexWrap:"wrap"},children:j.map((h,g)=>h.type==="section"?r.jsx(Fe,{data:h.fields},g):r.jsxs(p.Fragment,{children:[r.jsx(Be,{attachment:h,style:C,...l}),!(o&&R==="vertical")&&d&&j.length>1&&g!==j.length-1?r.jsx(ne,{orientation:R,style:{color:dt.dividerColor},sx:R==="vertical"?{ml:2,mr:2,height:32}:{}}):null]},g))})},x=zt(s);return r.jsx(Vt,{children:r.jsxs("div",{className:"message-in-list",children:[s.length>0&&r.jsx("div",{className:"message-container",style:o?{width:"100%"}:{},children:x?u(s):r.jsx(Re,{variant:"outlined",sx:{p:2,borderRadius:"8px",minWidth:128,borderColor:c},children:u(s)})}),!_(a)&&r.jsx("div",{className:"message-container",children:r.jsx("div",{className:"data-container",children:r.jsx(me,{data:a,feedType:e.feedType})})}),s.length===0&&_(a)&&n&&r.jsx(rt,{className:"attach-ske",style:{marginTop:10},variant:"rectangular",height:150})]})})}const Vt=E.div`
57
+ `;function fe({notification:e,severity:t,showSke:n=!0}){const{attachments:s,data:a,...l}=e,o=W(y=>y.breakpoints.down("md"));if((!s||!s.length)&&_(a))return null;const c=Nt(t),u=(y,b=!1)=>{if(!y&&!Array.isArray(y))return null;let j=y,C={},R="horizontal";b&&Pt(y)&&(j=Lt(y),R="vertical",C={display:"flex",gap:8,flexDirection:"row",justifyContent:"flex-start",flexWrap:"wrap",height:"100%",width:o||j.length===1?"100%":"28%"});const d=Dt(j);return r.jsx(m,{sx:{width:"100%",display:"flex",gap:1,flexDirection:b?"row":"column",justifyContent:"flex-start",alignItems:b?"center":"unset",flexWrap:"wrap"},children:j.map((h,g)=>h.type==="section"?r.jsx(Fe,{data:h.fields},g):r.jsxs(p.Fragment,{children:[r.jsx(Be,{attachment:h,style:C,...l}),!(o&&R==="vertical")&&d&&j.length>1&&g!==j.length-1?r.jsx(ne,{orientation:R,style:{color:ut.dividerColor},sx:R==="vertical"?{ml:2,mr:2,height:32}:{}}):null]},g))})},x=zt(s);return r.jsx(Vt,{children:r.jsxs("div",{className:"message-in-list",children:[s.length>0&&r.jsx("div",{className:"message-container",style:o?{width:"100%"}:{},children:x?u(s):r.jsx(Re,{variant:"outlined",sx:{p:2,borderRadius:"8px",minWidth:128,borderColor:c},children:u(s)})}),!_(a)&&r.jsx("div",{className:"message-container",children:r.jsx("div",{className:"data-container",children:r.jsx(me,{data:a,feedType:e.feedType})})}),s.length===0&&_(a)&&n&&r.jsx(rt,{className:"attach-ske",style:{marginTop:10},variant:"rectangular",height:150})]})})}const Vt=E.div`
58
58
  display: flex;
59
59
  flex-direction: column;
60
60
  .message-in-list {
@@ -106,7 +106,7 @@ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as
106
106
  margin-right: 8px;
107
107
  }
108
108
  }
109
- `;fe.propTypes={severity:i.string.isRequired,notification:i.object.isRequired,showSke:i.bool};fe.defaultProps={showSke:!0};const J=e=>wt.sanitize(e,{ALLOWED_ATTR:["href","target","rel","class","id","style"]}),Gt=async(e,t)=>{const{type:n,did:s}=e;return De.isSameAddr(n,"did")?await Et(s,t)||X.getLink(e):X.getLink(e)},Qt=async(e,t,n=!0)=>{const s=X.toTextList(e);return await Promise.all(s.map(async l=>{if(l instanceof X.Link){if(n){const o=await Gt(l,t),{type:c,chainId:u,did:x}=l;return De.isSameAddr(c,"dapp")?`<em style="font-weight:bold;" data-type="${c}" data-chain-id="${u}" data-did="${x}">${l.text}</em>`:o?`<a target="_blank" rel="noopener noreferrer" style="color:#4598fa;font-weight:bold;" href="${o}">${l.text}</a>`:`<em style="font-weight:bold;" data-type="${c}" data-chain-id="${u}" data-did="${x}">${l.text}</em>`}return l.text}return l})).then(l=>l.join(""))};Ve.propTypes={notification:i.object,rows:i.number,minimal:i.bool};function Ve({notification:e,rows:t=2,minimal:n=!1}){const[s,a]=p.useState(!1),[l,o]=p.useState(""),{t:c,locale:u}=Se(),{palette:x}=N(),y=p.useMemo(()=>{const{attachments:g}=e||{};if(!g)return!1;try{return g.length>0}catch{return!1}},[e]),b=p.useMemo(()=>{const{blocks:g}=e||{};if(!g)return!1;try{return g.length>0}catch{return!1}},[e]),j=p.useMemo(()=>{const{description:g}=e||{};return!!g},[e]),C=p.useMemo(()=>{const{data:g}=e||{};return!_(g)},[e]),R=p.useMemo(()=>y||b||j||C,[y,b,j,C]);if(p.useEffect(()=>{Qt((e==null?void 0:e.description)??"",u).then(g=>{o(g)})},[e==null?void 0:e.description,u]),!R)return null;const d=()=>t===0?"":s?`<span class='toggle-btn' data-name='toggle-expanded'>${c("common.collapse")}</span>`:`...<span class='toggle-btn' data-name='toggle-expanded'>${c("common.expand")}</span>`,h=g=>{const{target:T}=g;T.getAttribute("data-name")==="toggle-expanded"&&(a(!s),g.customPreventRedirect=!0)};return r.jsxs(Xt,{color:n?x.primary.contrastText:"",children:[r.jsx(m,{className:"text-container",component:"div",onClick:h,children:l&&(!s&&t>0?r.jsx(gt,{basedOn:"letters",unsafeHTML:J(l),maxLine:t,ellipsisHTML:J(d())}):r.jsx(A,{component:"div",className:`content ${t===0?"ellipsis":""}`,style:{whiteSpace:"pre-line!important"},dangerouslySetInnerHTML:{__html:J(`${l}${d()}`)}}))}),!n&&(y||C)?r.jsx(fe,{severity:e.severity,notification:e}):null]})}const Xt=E(m)`
109
+ `;fe.propTypes={severity:i.string.isRequired,notification:i.object.isRequired,showSke:i.bool};fe.defaultProps={showSke:!0};const Z=e=>wt.sanitize(e,{ALLOWED_ATTR:["href","target","rel","class","id","style"]}),Gt=async(e,t)=>{const{type:n,did:s}=e;return De.isSameAddr(n,"did")?await Et(s,t)||X.getLink(e):X.getLink(e)},Qt=async(e,t,n=!0)=>{const s=X.toTextList(e);return await Promise.all(s.map(async l=>{if(l instanceof X.Link){if(n){const o=await Gt(l,t),{type:c,chainId:u,did:x}=l;return De.isSameAddr(c,"dapp")?`<em style="font-weight:bold;" data-type="${c}" data-chain-id="${u}" data-did="${x}">${l.text}</em>`:o?`<a target="_blank" rel="noopener noreferrer" style="color:#4598fa;font-weight:bold;" href="${o}">${l.text}</a>`:`<em style="font-weight:bold;" data-type="${c}" data-chain-id="${u}" data-did="${x}">${l.text}</em>`}return l.text}return l})).then(l=>l.join(""))};Ve.propTypes={notification:i.object,rows:i.number,minimal:i.bool};function Ve({notification:e,rows:t=2,minimal:n=!1}){const[s,a]=p.useState(!1),[l,o]=p.useState(""),{t:c,locale:u}=Se(),{palette:x}=N(),y=p.useMemo(()=>{const{attachments:g}=e||{};if(!g)return!1;try{return g.length>0}catch{return!1}},[e]),b=p.useMemo(()=>{const{blocks:g}=e||{};if(!g)return!1;try{return g.length>0}catch{return!1}},[e]),j=p.useMemo(()=>{const{description:g}=e||{};return!!g},[e]),C=p.useMemo(()=>{const{data:g}=e||{};return!_(g)},[e]),R=p.useMemo(()=>y||b||j||C,[y,b,j,C]);if(p.useEffect(()=>{Qt((e==null?void 0:e.description)??"",u).then(g=>{o(g)})},[e==null?void 0:e.description,u]),!R)return null;const d=()=>t===0?"":s?`<span class='toggle-btn' data-name='toggle-expanded'>${c("common.collapse")}</span>`:`...<span class='toggle-btn' data-name='toggle-expanded'>${c("common.expand")}</span>`,h=g=>{const{target:T}=g;T.getAttribute("data-name")==="toggle-expanded"&&(a(!s),g.customPreventRedirect=!0)};return r.jsxs(Xt,{color:n?x.primary.contrastText:"",children:[r.jsx(m,{className:"text-container",component:"div",onClick:h,children:l&&(!s&&t>0?r.jsx(gt,{basedOn:"letters",unsafeHTML:Z(l),maxLine:t,ellipsisHTML:Z(d())}):r.jsx(A,{component:"div",className:`content ${t===0?"ellipsis":""}`,style:{whiteSpace:"pre-line!important"},dangerouslySetInnerHTML:{__html:Z(`${l}${d()}`)}}))}),!n&&(y||C)?r.jsx(fe,{severity:e.severity,notification:e}):null]})}const Xt=E(m)`
110
110
  width: 100%;
111
111
  color: ${e=>e.color?e.color:e.theme.palette.text.secondary};
112
112
  .text-container {
@@ -131,7 +131,7 @@ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as
131
131
  line-height: 1.25;
132
132
  }
133
133
  }
134
- `,Kt=p.memo(Ve);var ge={},Yt=Te;Object.defineProperty(ge,"__esModule",{value:!0});var Ge=ge.default=void 0,Zt=Yt(Me()),Jt=r;Ge=ge.default=(0,Zt.default)((0,Jt.jsx)("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2m5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12z"}),"Cancel");var xe={},er=Te;Object.defineProperty(xe,"__esModule",{value:!0});var Qe=xe.default=void 0,tr=er(Me()),rr=r;Qe=xe.default=(0,tr.default)((0,rr.jsx)("path",{d:"M1 21h22L12 2zm12-3h-2v-2h2zm0-4h-2v-4h2z"}),"Warning");const sr={error:Ge,warning:Qe,info:kt,success:Rt};ye.propTypes={severity:i.oneOf(["error","warning","info","success"]).isRequired,size:i.number};ye.defaultProps={size:32};function ye({severity:e="info",size:t=32}){const n=N(),a=D(()=>({error:n.palette.error.main,warning:n.palette.warning.main,info:n.palette.info.main,success:n.palette.success.main}))[e],l=sr[e],o=st(a,.1);return r.jsx(Y,{sx:{width:t,height:t,bgcolor:o,color:a},children:r.jsx(l,{fontSize:"small"})})}const nr={width:24,height:24,body:'<g fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M0 0h24v24H0z"/><path fill="currentColor" d="M5.821 4.91c3.898-2.765 9.469-2.539 13.073.536c3.667 3.127 4.168 8.238 1.152 11.897c-2.842 3.447-7.965 4.583-12.231 2.805l-.232-.101l-4.375.931l-.075.013l-.11.009l-.113-.004l-.044-.005l-.11-.02l-.105-.034l-.1-.044l-.076-.042l-.108-.077l-.081-.074l-.073-.083l-.053-.075l-.065-.115l-.042-.106l-.031-.113l-.013-.075l-.009-.11l.004-.113l.005-.044l.02-.11l.022-.072l1.15-3.451l-.022-.036C.969 12.45 1.97 7.805 5.59 5.079l.23-.168z"/></g>'},ir={width:24,height:24,body:'<g fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M0 0h24v24H0z"/><path fill="currentColor" d="M12 2a5 5 0 1 1-5 5l.005-.217A5 5 0 0 1 12 2zm2 12a5 5 0 0 1 5 5v1a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-1a5 5 0 0 1 5-5h4z"/></g>'},or={width:24,height:24,body:'<g fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M0 0h24v24H0z"/><path fill="currentColor" d="M17 3.34A10 10 0 1 1 2 12l.005-.324A10 10 0 0 1 17 3.34zM12 6a1 1 0 0 0-1 1a3 3 0 1 0 0 6v2a1.024 1.024 0 0 1-.866-.398l-.068-.101a1 1 0 0 0-1.732.998a3 3 0 0 0 2.505 1.5H11a1 1 0 0 0 .883.994L12 18a1 1 0 0 0 1-1l.176-.005A3 3 0 0 0 13 11V9c.358-.012.671.14.866.398l.068.101a1 1 0 0 0 1.732-.998A3 3 0 0 0 13.161 7H13a1 1 0 0 0-1-1zm1 7a1 1 0 0 1 0 2v-2zm-2-4v2a1 1 0 0 1 0-2z"/></g>'},ar={width:24,height:24,body:'<g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M8 12a4 4 0 1 0 8 0a4 4 0 1 0-8 0"/><path d="M16 12v1.5a2.5 2.5 0 0 0 5 0V12a9 9 0 1 0-5.5 8.28"/></g>'},lr={width:24,height:24,body:'<path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m15 10l-4 4l6 6l4-16l-18 7l4 2l2 6l3-4"/>'},ke={comment:{icon:nr,bgColor:"rgba(239, 246, 255, 1)",color:"rgba(43, 127, 255, 1)"},like:{icon:"👍",bgColor:"rgba(244, 244, 245, 1)",color:"yellow",renderType:"emoji"},follow:{icon:ir,bgColor:"rgba(238, 242, 255, 1)",color:"rgba(97, 95, 255, 1)"},tips:{icon:or,bgColor:"rgba(254, 252, 232, 1)",color:"rgba(240, 177, 0, 1)"},mention:{icon:ar,bgColor:"rgba(244, 244, 245, 1)",color:"rgba(43, 127, 255, 1)"},assign:{icon:lr,bgColor:"rgba(244, 244, 245, 1)",color:"rgba(43, 127, 255, 1)"}};ve.propTypes={activity:i.oneOf(["comment","like","follow","tips","mention","assign"]).isRequired,size:i.number};ve.defaultProps={size:32};function ve({activity:e,size:t=32}){const n=ke[e]||ke.comment,s=n.icon;return r.jsx(Y,{sx:{bgcolor:n.bgColor,color:n.color,width:t,height:t},children:n.renderType==="emoji"?r.jsx("span",{style:{fontSize:"14px"},children:s}):r.jsx($e,{icon:s})})}const re={avatar:i.string,fullName:i.string,did:i.string};function K({actor:e,size:t,teamDid:n,inService:s,showName:a}){const l=D(()=>({...e,avatar:e!=null&&e.avatar?Mt(e.avatar,n,s):null}),[e,n,s]),o=c=>{e&&(c.stopPropagation(),window.open(ze(U(Ie.WELLKNOWN_SERVICE_PATH_PREFIX,"user"),{did:e.did}),"_blank"),c.customPreventRedirect=!0)};return r.jsxs(m,{display:"flex",alignItems:"center",gap:1,onClick:o,role:"button",style:{cursor:"pointer"},title:(e==null?void 0:e.fullName)||"",children:[l.avatar?r.jsx(Tt,{user:l,showDid:!0,cardType:It.AvatarOnly,infoType:St.Minimal,avatarSize:t,shape:"circle",sx:{width:t,height:t,borderRadius:"100%",overflow:"hidden",transition:"transform 0.2s ease-in-out","&:hover":{transform:"scale(1.1)"}}}):r.jsx(Y,{sx:{width:t,height:t}}),a&&r.jsx("span",{children:e==null?void 0:e.fullName})]})}K.propTypes={actor:i.shape(re).isRequired,size:i.number.isRequired,teamDid:i.string,inService:i.bool,showName:i.bool};K.defaultProps={teamDid:"",inService:!1,showName:!1};Z.propTypes={actors:i.oneOfType([i.shape(re),i.arrayOf(i.shape(re))]).isRequired,size:i.number,maxDisplay:i.number,teamDid:i.string,inService:i.bool,showName:i.bool,avatarFallback:i.node};Z.defaultProps={size:32,maxDisplay:9,teamDid:"",inService:!0,showName:!1,avatarFallback:null};function Z({actors:e,size:t=32,maxDisplay:n=9,teamDid:s="",inService:a=!0,showName:l=!1,avatarFallback:o=null}){const c=D(()=>{const u=Array.isArray(e)?e:[e];return jt(u,"did").filter(Boolean)},[e]);return c.length===1||!c.length?r.jsx(K,{actor:c[0],size:t,teamDid:s,inService:a,showName:l}):r.jsx(nt,{total:c.length,renderSurplus:u=>u<100?r.jsxs("span",{children:["+",u]}):r.jsx("span",{children:"99+"}),max:n,sx:{justifyContent:"flex-end",height:`${t}px`,".MuiAvatar-root":{width:`${t}px`,height:`${t}px`,fontSize:`${t/2.5}px`,border:0,zIndex:2}},children:c.map((u,x)=>u!=null&&u.avatar?r.jsx(K,{actor:u,size:t,teamDid:s,inService:a},(u==null?void 0:u.did)||x):o)})}const Ce=3;Ye.propTypes={notification:i.object.isRequired,isMultiple:i.bool,blocklet:i.object,mountPoint:i.string,avatarFallback:i.node};Xe.propTypes={notification:i.object.isRequired,mountPoint:i.string};Ke.propTypes={items:i.array.isRequired,activity:i.object.isRequired,blocklet:i.object,mountPoint:i.string,viewMoreLink:i.string,avatarFallback:i.node};function Xe({notification:e,mountPoint:t=""}){var o;const{activity:n}=e,{type:s,meta:a={}}=n||{},l=Ae({activity:n,users:[e==null?void 0:e.actorInfo],actors:[(o=e==null?void 0:e.activity)==null?void 0:o.actor],mountPoint:t});return _(n)||!n.type||!n.actor||_(n.target)?null:r.jsxs(m,{children:[r.jsx(A,{variant:"body1",color:"text.secondary",sx:{mb:.5},children:l}),a?r.jsx(Ne,{meta:a,type:s}):null]})}function Ke({items:e,activity:t,blocklet:n,mountPoint:s="",viewMoreLink:a="",avatarFallback:l=null}){const o=N(),c=D(()=>{var d;return(n==null?void 0:n.did)||((d=n==null?void 0:n.meta)==null?void 0:d.did)||""},[n]),{locale:u}=p.useContext(oe),x=D(()=>!_(t.meta)&&Object.values(t.meta).some(d=>d!=null),[t]),y=Ae({activity:t,users:e.map(d=>d==null?void 0:d.actorInfo),actors:e.map(d=>{var h;return(h=d==null?void 0:d.activity)==null?void 0:h.actor}),mountPoint:s}),b=ee(d=>{if(!d.activity)return null;const h=ae(d.activity);return h!=null&&h.metaLink?le(h==null?void 0:h.metaLink)||ce(h==null?void 0:h.metaLink)?h==null?void 0:h.metaLink:U(s,h.metaLink):null}),j=ee((d,h)=>{if(!h)return;const g=b(h);g&&(window.open(g,"_blank"),d.customPreventRedirect=!0)}),C=e.length>Ce,R=e.slice(0,Ce);return r.jsxs(m,{sx:{width:"100%"},children:[r.jsx(A,{variant:"body1",color:"text.secondary",sx:{mb:3},children:y}),x?r.jsxs(m,{className:"sub-content",display:"flex",flexDirection:"column",gap:3,children:[R.map(d=>{var h;return r.jsxs(m,{display:"flex",flexDirection:"column",gap:1,onClick:g=>j(g,d),children:[r.jsxs(m,{display:"flex",alignItems:"center",gap:1,children:[Q(d)?r.jsx(Z,{actors:d.actorInfo,size:32,teamDid:c}):l,r.jsx(A,{variant:"subtitle1",color:"text.primary",children:Q(d)?(h=d==null?void 0:d.actorInfo)==null?void 0:h.fullName:"System"})," ","·",r.jsx(Pe,{value:d.createdAt,locale:u,shouldUpdate:!0,style:{color:o.palette.text.secondary,fontSize:"0.875rem",minWidth:"50px",whiteSpace:"nowrap"}})]}),d.activity.meta?r.jsx(m,{pl:5,children:r.jsx(Ne,{meta:d.activity.meta,type:d.activity.type})}):null]},d.id)}),C&&a?r.jsx(m,{mt:1,display:"flex",justifyContent:"center",children:r.jsxs(it,{size:"large",variant:"text",component:se,href:a,target:"_blank",rel:"noopener noreferrer",onClick:d=>{d.customPreventRedirect=!0},children:["View More ",r.jsx($e,{icon:xt,style:{marginLeft:4}})]})}):null]}):null]})}function Ye({notification:e,isMultiple:t=!1,blocklet:n,mountPoint:s="",avatarFallback:a}){const l=D(()=>{if(!e.activity)return null;const o=ae(e.activity);return o!=null&&o.targetLink?le(o==null?void 0:o.targetLink)||ce(o==null?void 0:o.targetLink)?o==null?void 0:o.targetLink:U(s,o.targetLink):null},[e.activity,s]);return t?r.jsx(Ke,{items:e.items,activity:e.activity,blocklet:n,mountPoint:s,viewMoreLink:l,avatarFallback:a}):r.jsx(Xe,{notification:e,mountPoint:s})}const cr=ot(m)`
134
+ `,Kt=p.memo(Ve);var ge={},Yt=Te;Object.defineProperty(ge,"__esModule",{value:!0});var Ge=ge.default=void 0,Jt=Yt(Me()),Zt=r;Ge=ge.default=(0,Jt.default)((0,Zt.jsx)("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2m5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12z"}),"Cancel");var xe={},er=Te;Object.defineProperty(xe,"__esModule",{value:!0});var Qe=xe.default=void 0,tr=er(Me()),rr=r;Qe=xe.default=(0,tr.default)((0,rr.jsx)("path",{d:"M1 21h22L12 2zm12-3h-2v-2h2zm0-4h-2v-4h2z"}),"Warning");const sr={error:Ge,warning:Qe,info:kt,success:Rt};ye.propTypes={severity:i.oneOf(["error","warning","info","success"]).isRequired,size:i.number};ye.defaultProps={size:32};function ye({severity:e="info",size:t=32}){const n=N(),a=D(()=>({error:n.palette.error.main,warning:n.palette.warning.main,info:n.palette.info.main,success:n.palette.success.main}))[e],l=sr[e],o=st(a,.1);return r.jsx(Y,{sx:{width:t,height:t,bgcolor:o,color:a},children:r.jsx(l,{fontSize:"small"})})}const nr={width:24,height:24,body:'<g fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M0 0h24v24H0z"/><path fill="currentColor" d="M5.821 4.91c3.898-2.765 9.469-2.539 13.073.536c3.667 3.127 4.168 8.238 1.152 11.897c-2.842 3.447-7.965 4.583-12.231 2.805l-.232-.101l-4.375.931l-.075.013l-.11.009l-.113-.004l-.044-.005l-.11-.02l-.105-.034l-.1-.044l-.076-.042l-.108-.077l-.081-.074l-.073-.083l-.053-.075l-.065-.115l-.042-.106l-.031-.113l-.013-.075l-.009-.11l.004-.113l.005-.044l.02-.11l.022-.072l1.15-3.451l-.022-.036C.969 12.45 1.97 7.805 5.59 5.079l.23-.168z"/></g>'},ir={width:24,height:24,body:'<g fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M0 0h24v24H0z"/><path fill="currentColor" d="M12 2a5 5 0 1 1-5 5l.005-.217A5 5 0 0 1 12 2zm2 12a5 5 0 0 1 5 5v1a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-1a5 5 0 0 1 5-5h4z"/></g>'},or={width:24,height:24,body:'<g fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M0 0h24v24H0z"/><path fill="currentColor" d="M17 3.34A10 10 0 1 1 2 12l.005-.324A10 10 0 0 1 17 3.34zM12 6a1 1 0 0 0-1 1a3 3 0 1 0 0 6v2a1.024 1.024 0 0 1-.866-.398l-.068-.101a1 1 0 0 0-1.732.998a3 3 0 0 0 2.505 1.5H11a1 1 0 0 0 .883.994L12 18a1 1 0 0 0 1-1l.176-.005A3 3 0 0 0 13 11V9c.358-.012.671.14.866.398l.068.101a1 1 0 0 0 1.732-.998A3 3 0 0 0 13.161 7H13a1 1 0 0 0-1-1zm1 7a1 1 0 0 1 0 2v-2zm-2-4v2a1 1 0 0 1 0-2z"/></g>'},ar={width:24,height:24,body:'<g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M8 12a4 4 0 1 0 8 0a4 4 0 1 0-8 0"/><path d="M16 12v1.5a2.5 2.5 0 0 0 5 0V12a9 9 0 1 0-5.5 8.28"/></g>'},lr={width:24,height:24,body:'<path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m15 10l-4 4l6 6l4-16l-18 7l4 2l2 6l3-4"/>'},ke={comment:{icon:nr,bgColor:"rgba(239, 246, 255, 1)",color:"rgba(43, 127, 255, 1)"},like:{icon:"👍",bgColor:"rgba(244, 244, 245, 1)",color:"yellow",renderType:"emoji"},follow:{icon:ir,bgColor:"rgba(238, 242, 255, 1)",color:"rgba(97, 95, 255, 1)"},tips:{icon:or,bgColor:"rgba(254, 252, 232, 1)",color:"rgba(240, 177, 0, 1)"},mention:{icon:ar,bgColor:"rgba(244, 244, 245, 1)",color:"rgba(43, 127, 255, 1)"},assign:{icon:lr,bgColor:"rgba(244, 244, 245, 1)",color:"rgba(43, 127, 255, 1)"}};ve.propTypes={activity:i.oneOf(["comment","like","follow","tips","mention","assign"]).isRequired,size:i.number};ve.defaultProps={size:32};function ve({activity:e,size:t=32}){const n=ke[e]||ke.comment,s=n.icon;return r.jsx(Y,{sx:{bgcolor:n.bgColor,color:n.color,width:t,height:t},children:n.renderType==="emoji"?r.jsx("span",{style:{fontSize:"14px"},children:s}):r.jsx($e,{icon:s})})}const re={avatar:i.string,fullName:i.string,did:i.string};function K({actor:e,size:t,teamDid:n,inService:s,showName:a}){const l=D(()=>({...e,avatar:e!=null&&e.avatar?Mt(e.avatar,n,s):null}),[e,n,s]),o=c=>{e&&(c.stopPropagation(),window.open(ze(U(Ie.WELLKNOWN_SERVICE_PATH_PREFIX,"user"),{did:e.did}),"_blank"),c.customPreventRedirect=!0)};return r.jsxs(m,{display:"flex",alignItems:"center",gap:1,onClick:o,role:"button",style:{cursor:"pointer"},title:(e==null?void 0:e.fullName)||"",children:[l.avatar?r.jsx(Tt,{user:l,showDid:!0,cardType:It.AvatarOnly,infoType:St.Minimal,avatarSize:t,shape:"circle",sx:{width:t,height:t,borderRadius:"100%",overflow:"hidden",transition:"transform 0.2s ease-in-out","&:hover":{transform:"scale(1.1)"}}}):r.jsx(Y,{sx:{width:t,height:t}}),a&&r.jsx("span",{children:e==null?void 0:e.fullName})]})}K.propTypes={actor:i.shape(re).isRequired,size:i.number.isRequired,teamDid:i.string,inService:i.bool,showName:i.bool};K.defaultProps={teamDid:"",inService:!1,showName:!1};J.propTypes={actors:i.oneOfType([i.shape(re),i.arrayOf(i.shape(re))]).isRequired,size:i.number,maxDisplay:i.number,teamDid:i.string,inService:i.bool,showName:i.bool,avatarFallback:i.node};J.defaultProps={size:32,maxDisplay:9,teamDid:"",inService:!0,showName:!1,avatarFallback:null};function J({actors:e,size:t=32,maxDisplay:n=9,teamDid:s="",inService:a=!0,showName:l=!1,avatarFallback:o=null}){const c=D(()=>{const u=Array.isArray(e)?e:[e];return jt(u,"did").filter(Boolean)},[e]);return c.length===1||!c.length?r.jsx(K,{actor:c[0],size:t,teamDid:s,inService:a,showName:l}):r.jsx(nt,{total:c.length,renderSurplus:u=>u<100?r.jsxs("span",{children:["+",u]}):r.jsx("span",{children:"99+"}),max:n,sx:{justifyContent:"flex-end",height:`${t}px`,".MuiAvatar-root":{width:`${t}px`,height:`${t}px`,fontSize:`${t/2.5}px`,border:0,zIndex:2}},children:c.map((u,x)=>u!=null&&u.avatar?r.jsx(K,{actor:u,size:t,teamDid:s,inService:a},(u==null?void 0:u.did)||x):o)})}const Ce=3;Ye.propTypes={notification:i.object.isRequired,isMultiple:i.bool,blocklet:i.object,mountPoint:i.string,avatarFallback:i.node};Xe.propTypes={notification:i.object.isRequired,mountPoint:i.string};Ke.propTypes={items:i.array.isRequired,activity:i.object.isRequired,blocklet:i.object,mountPoint:i.string,viewMoreLink:i.string,avatarFallback:i.node};function Xe({notification:e,mountPoint:t=""}){var o;const{activity:n}=e,{type:s,meta:a={}}=n||{},l=Ae({activity:n,users:[e==null?void 0:e.actorInfo],actors:[(o=e==null?void 0:e.activity)==null?void 0:o.actor],mountPoint:t});return _(n)||!n.type||!n.actor||_(n.target)?null:r.jsxs(m,{children:[r.jsx(A,{variant:"body1",color:"text.secondary",sx:{mb:.5},children:l}),a?r.jsx(Ne,{meta:a,type:s}):null]})}function Ke({items:e,activity:t,blocklet:n,mountPoint:s="",viewMoreLink:a="",avatarFallback:l=null}){const o=N(),c=D(()=>{var d;return(n==null?void 0:n.did)||((d=n==null?void 0:n.meta)==null?void 0:d.did)||""},[n]),{locale:u}=p.useContext(oe),x=D(()=>!_(t.meta)&&Object.values(t.meta).some(d=>d!=null),[t]),y=Ae({activity:t,users:e.map(d=>d==null?void 0:d.actorInfo),actors:e.map(d=>{var h;return(h=d==null?void 0:d.activity)==null?void 0:h.actor}),mountPoint:s}),b=ee(d=>{if(!d.activity)return null;const h=ae(d.activity);return h!=null&&h.metaLink?le(h==null?void 0:h.metaLink)||ce(h==null?void 0:h.metaLink)?h==null?void 0:h.metaLink:U(s,h.metaLink):null}),j=ee((d,h)=>{if(!h)return;const g=b(h);g&&(window.open(g,"_blank"),d.customPreventRedirect=!0)}),C=e.length>Ce,R=e.slice(0,Ce);return r.jsxs(m,{sx:{width:"100%"},children:[r.jsx(A,{variant:"body1",color:"text.secondary",sx:{mb:3},children:y}),x?r.jsxs(m,{className:"sub-content",display:"flex",flexDirection:"column",gap:3,children:[R.map(d=>{var h;return r.jsxs(m,{display:"flex",flexDirection:"column",gap:1,onClick:g=>j(g,d),children:[r.jsxs(m,{display:"flex",alignItems:"center",gap:1,children:[Q(d)?r.jsx(J,{actors:d.actorInfo,size:32,teamDid:c}):l,r.jsx(A,{variant:"subtitle1",color:"text.primary",children:Q(d)?(h=d==null?void 0:d.actorInfo)==null?void 0:h.fullName:"System"})," ","·",r.jsx(Pe,{value:d.createdAt,locale:u,shouldUpdate:!0,style:{color:o.palette.text.secondary,fontSize:"0.875rem",minWidth:"50px",whiteSpace:"nowrap"}})]}),d.activity.meta?r.jsx(m,{pl:5,children:r.jsx(Ne,{meta:d.activity.meta,type:d.activity.type})}):null]},d.id)}),C&&a?r.jsx(m,{mt:1,display:"flex",justifyContent:"center",children:r.jsxs(it,{size:"large",variant:"text",component:se,href:a,target:"_blank",rel:"noopener noreferrer",onClick:d=>{d.customPreventRedirect=!0},children:["View More ",r.jsx($e,{icon:xt,style:{marginLeft:4}})]})}):null]}):null]})}function Ye({notification:e,isMultiple:t=!1,blocklet:n,mountPoint:s="",avatarFallback:a}){const l=D(()=>{if(!e.activity)return null;const o=ae(e.activity);return o!=null&&o.targetLink?le(o==null?void 0:o.targetLink)||ce(o==null?void 0:o.targetLink)?o==null?void 0:o.targetLink:U(s,o.targetLink):null},[e.activity,s]);return t?r.jsx(Ke,{items:e.items,activity:e.activity,blocklet:n,mountPoint:s,viewMoreLink:l,avatarFallback:a}):r.jsx(Xe,{notification:e,mountPoint:s})}const cr=ot(m)`
135
135
  display: flex;
136
136
  justify-content: center;
137
137
  align-items: center;
@@ -142,7 +142,7 @@ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as
142
142
  .empty-icon {
143
143
  margin: 10px 0;
144
144
  }
145
- `;function be({color:e,children:t,...n}){const s=$t();return r.jsxs(cr,{...n,children:[r.jsx("img",{src:`${s.imgPrefix}/all-done.png`,alt:"All Done",width:200,height:200,style:{maxHeight:"100%",maxWidth:"100%"},onError:a=>{a.target.style.display="none"}}),r.jsx(m,{className:"empty-content",children:t})]})}be.propTypes={color:i.string,children:i.any};be.defaultProps={color:"inherit",children:null};dr.propTypes={data:i.array,blockletMap:i.object,onReadBatch:i.func,inDialog:i.bool,highlightId:i.string,highlight:i.bool,type:i.oneOf(["server","service"])};Ze.propTypes={notification:i.object,blocklet:i.object,onReadBatch:i.func,inDialog:i.bool,highlight:i.bool};V.propTypes={blocklet:i.object,size:i.number,showName:i.bool,hideDot:i.bool};function V({blocklet:e,size:t=40,showName:n=!1,hideDot:s=!1}){var o,c;const a=(e==null?void 0:e.did)||((o=e==null?void 0:e.meta)==null?void 0:o.did)||"",l=((e==null?void 0:e.alsoKnownAs)||[]).concat((e==null?void 0:e.appId)||(e==null?void 0:e.appDid)||(e==null?void 0:e.appPid)||"");return r.jsxs(m,{className:"component-avatar",display:"flex",alignItems:"center",sx:{gap:s?"8px":"4px"},children:[!s&&r.jsx("span",{className:"dot"}),e?r.jsx(m,{children:l.includes(a)?r.jsx(de,{blocklet:e,size:t,style:{borderRadius:8}}):r.jsx(ht,{blocklet:e,ancestors:e.ancestors??[],size:t,style:{borderRadius:8}})}):r.jsx(pt,{width:t,height:t}),n&&r.jsx("span",{className:"component-name",children:(c=e==null?void 0:e.meta)==null?void 0:c.title})]})}function Ze({notification:e,blocklet:t,onReadBatch:n=()=>{},inDialog:s=!1,highlight:a}){const{locale:l}=p.useContext(oe),o=N(),c=W(v=>v.breakpoints.down("md")),u=p.useRef(null),x=p.useMemo(()=>te(e),[e]),y=p.useMemo(()=>vt(e),[e]),b=p.useMemo(()=>Q(e),[e]),j=p.useMemo(()=>{const{actions:v,action:I}=e;let w=v??[];return!w.length&&I&&(w=[{name:"Visit",link:I}]),w},[e]),C=p.useMemo(()=>e.items||[],[e]),R=p.useMemo(()=>C.length>0,[C]),d=p.useMemo(()=>y?R?C.map(v=>{var I;return Q(v)?v.actorInfo:{did:(I=v.activity)==null?void 0:I.actor}}).filter(Boolean):e.actorInfo??[]:[],[C,e.actorInfo,R,y]),h=p.useMemo(()=>{var v;return(t==null?void 0:t.did)||((v=t==null?void 0:t.meta)==null?void 0:v.did)||""},[t]),g=p.useMemo(()=>_t(h,window.blocklet),[h]),T=ee((v,I)=>{const w=qe(v);if(w.length&&n(w.map(M=>M.id)),I&&!I.customPreventRedirect){const M=Ht(v,g);M&&typeof M=="string"&&window.open(M,"_blank","noopener,noreferrer")}});return r.jsxs(ur,{ref:u,className:"notification-row",id:e.id,isRead:x,inDialog:s,highlight:a,isMd:c,onClick:v=>T(e,v),children:[y?r.jsx(ve,{activity:e.activity.type,size:c?24:32}):r.jsx(ye,{severity:e.severity,size:c?24:32}),r.jsxs(m,{className:"notification",display:"flex",flexDirection:"column",alignItems:"start",children:[r.jsxs(m,{width:"100%",display:"flex",justifyContent:"space-between",alignItems:"center",gap:1,className:"header",mb:1.5,children:[y&&b?r.jsx(Z,{actors:d,teamDid:h,size:c?24:32,avatarFallback:r.jsx(V,{blocklet:t,hideDot:!0,size:c?24:32})}):r.jsx(V,{blocklet:t,hideDot:!0,size:c?24:32}),r.jsx(Pe,{value:e.createdAt,locale:l,shouldUpdate:!0,style:{color:o.palette.text.secondary,fontSize:"0.875rem",minWidth:"50px",whiteSpace:"nowrap"}})]}),y?r.jsx(Ye,{notification:e,isMultiple:R,blocklet:t,mountPoint:g,avatarFallback:r.jsx(V,{blocklet:t,hideDot:!0,size:c?24:32})}):r.jsxs(r.Fragment,{children:[r.jsx(A,{variant:"body1",className:"title",color:"rgba(24, 24, 27, 1)",style:{marginTop:0},sx:{mb:.5},children:e.title}),r.jsx(Kt,{notification:e,rows:s?0:2})]}),j.length>0?r.jsx(m,{display:"flex",justifyContent:"start",alignItems:"center",gap:1,mt:1.5,children:j.map((v,I)=>r.jsxs(p.Fragment,{children:[r.jsx(se,{href:v.link,target:"_blank",className:"link",rel:"noopener noreferrer",sx:{fontSize:"15px"},onClick:w=>{w.customPreventRedirect=!0},children:v.name},v.link),I<j.length-1?r.jsx(ne,{orientation:"vertical",sx:{ml:1,mr:1,height:12,borderWidth:"1px"}}):null]},v.link))}):null]}),(e==null?void 0:e.description)&&e.severity==="error"&&r.jsx(m,{className:"copy-button",children:r.jsx(at,{size:"small",children:r.jsx(ut,{sx:{fontSize:22},content:(e==null?void 0:e.description)||""})})})]})}function dr({data:e,blockletMap:t,onReadBatch:n=()=>{},inDialog:s=!1,highlightId:a,highlight:l=!1,type:o="service"}){const{t:c}=Se(),u=p.useRef(null),[x,y]=p.useState(!1),[b,j]=p.useState(!0),[C,R]=p.useState(!1),d=p.useRef(new Set),h=p.useRef(new Set),g=p.useRef(null),T=p.useRef(null),v=p.useRef(!1),I=p.useMemo(()=>s?e==null?void 0:e.slice(0,5):e,[s,e]),w=p.useMemo(()=>yt(I),[I]),M=p.useMemo(()=>{const f=new Map;return w&&w.length&&w.forEach(k=>{f.set(k.id,k)}),f},[w]);p.useEffect(()=>{const f=()=>{j(document.visibilityState==="visible")};return document.addEventListener("visibilitychange",f),()=>{document.removeEventListener("visibilitychange",f)}},[]);const O=p.useCallback(()=>{if(!s&&d.current.size>0){const f=[];d.current.forEach(k=>{if(h.current.has(k))return;const S=M.get(k);if(S){const{receivers:z=[],items:L=[]}=S;if(z.length&&!z[0].read&&(f.push(k),h.current.add(k),L.length>0&&L.forEach($=>{const P=$.id;P&&!h.current.has(P)&&(f.push(P),h.current.add(P))}),T.current)){const $=document.getElementById(k);$&&T.current.unobserve($)}}}),f.length>0&&(n(f),setTimeout(()=>{y(!1)},300)),d.current.clear()}},[s,M,n]),q=p.useCallback(()=>{if(s||!u.current||!b)return;T.current&&T.current.disconnect();const f={root:null,rootMargin:"0px",threshold:.5},k=new IntersectionObserver(z=>{x&&z.forEach(L=>{const $=L.target.id;if(h.current.has($))return;const P=M.get($);if(P){const{receivers:je=[]}=P;je.length&&!je[0].read&&(L.isIntersecting?(d.current.add($),C||O()):d.current.delete($))}})},f);T.current=k,Array.from(u.current.querySelectorAll(".notification-row")).filter(z=>{const L=z.id;if(h.current.has(L))return!1;const $=M.get(L);if($){const{receivers:P=[]}=$;return P.length&&!P[0].read}return!1}).forEach(z=>{k.observe(z)}),v.current=!1},[x,s,C,b,M,O]);return p.useEffect(()=>{s||(v.current=!0,T.current&&b&&x&&setTimeout(()=>{q()},0))},[I,x,b,q,s]),p.useEffect(()=>{if(s||!u.current||!b)return;let f=window;if(o==="server"&&(f=document.getElementById("arc__dashboard-main")),!f){const S=document.getElementsByClassName("dashboard-main")[0];S&&(f=S)}if(!f)return;const k=S=>{S.isTrusted&&(x||y(!0),R(!0),g.current&&clearTimeout(g.current),g.current=setTimeout(()=>{R(!1),O(),v.current&&q()},300))};return f.addEventListener("scroll",k,{passive:!0}),()=>{f.removeEventListener("scroll",k),g.current&&clearTimeout(g.current)}},[s,x,b,O,q,o]),p.useEffect(()=>(s||q(),()=>{T.current&&T.current.disconnect()}),[q,s]),lt(()=>{setTimeout(()=>{const f=Wt(u.current),k=Bt(M,f);n(k.map(S=>S.id))},2e3)}),w!=null&&w.length?r.jsx(m,{ref:u,display:"flex",flexDirection:"column",sx:{...s?{maxHeight:"calc(-200px + 100vh)",overflow:"auto"}:{}},children:w==null?void 0:w.map(f=>{var S;const k=f.source==="system"?t.get(f.entityId||f.sender):t.get(f.componentDid||f.sender);return((S=f==null?void 0:f.type)==null?void 0:S.toLowerCase())==="passthrough"?null:r.jsx(Ze,{highlight:l&&a===f.id,inDialog:s,notification:f,blocklet:k,onReadBatch:n},f.id)})}):r.jsx(be,{children:c("notification.allDone")})}const ur=E("div")`
145
+ `;function be({color:e,children:t,...n}){const s=$t();return r.jsxs(cr,{...n,children:[r.jsx("img",{src:`${s.imgPrefix}/all-done.png`,alt:"All Done",width:200,height:200,style:{maxHeight:"100%",maxWidth:"100%"},onError:a=>{a.target.style.display="none"}}),r.jsx(m,{className:"empty-content",children:t})]})}be.propTypes={color:i.string,children:i.any};be.defaultProps={color:"inherit",children:null};dr.propTypes={data:i.array,blockletMap:i.object,onReadBatch:i.func,inDialog:i.bool,highlightId:i.string,highlight:i.bool,type:i.oneOf(["server","service"])};Je.propTypes={notification:i.object,blocklet:i.object,onReadBatch:i.func,inDialog:i.bool,highlight:i.bool};V.propTypes={blocklet:i.object,size:i.number,showName:i.bool,hideDot:i.bool};function V({blocklet:e,size:t=40,showName:n=!1,hideDot:s=!1}){var o,c;const a=(e==null?void 0:e.did)||((o=e==null?void 0:e.meta)==null?void 0:o.did)||"",l=((e==null?void 0:e.alsoKnownAs)||[]).concat((e==null?void 0:e.appId)||(e==null?void 0:e.appDid)||(e==null?void 0:e.appPid)||"");return r.jsxs(m,{className:"component-avatar",display:"flex",alignItems:"center",sx:{gap:s?"8px":"4px"},children:[!s&&r.jsx("span",{className:"dot"}),e?r.jsx(m,{children:l.includes(a)?r.jsx(de,{blocklet:e,size:t,style:{borderRadius:8}}):r.jsx(mt,{blocklet:e,ancestors:e.ancestors??[],size:t,style:{borderRadius:8}})}):r.jsx(ht,{width:t,height:t}),n&&r.jsx("span",{className:"component-name",children:(c=e==null?void 0:e.meta)==null?void 0:c.title})]})}function Je({notification:e,blocklet:t,onReadBatch:n=()=>{},inDialog:s=!1,highlight:a}){const{locale:l}=p.useContext(oe),o=N(),c=W(v=>v.breakpoints.down("md")),u=p.useRef(null),x=p.useMemo(()=>te(e),[e]),y=p.useMemo(()=>vt(e),[e]),b=p.useMemo(()=>Q(e),[e]),j=p.useMemo(()=>{const{actions:v,action:I}=e;let w=v??[];return!w.length&&I&&(w=[{name:"Visit",link:I}]),w},[e]),C=p.useMemo(()=>e.items||[],[e]),R=p.useMemo(()=>C.length>0,[C]),d=p.useMemo(()=>y?R?C.map(v=>{var I;return Q(v)?v.actorInfo:{did:(I=v.activity)==null?void 0:I.actor}}).filter(Boolean):e.actorInfo??[]:[],[C,e.actorInfo,R,y]),h=p.useMemo(()=>{var v;return(t==null?void 0:t.did)||((v=t==null?void 0:t.meta)==null?void 0:v.did)||""},[t]),g=p.useMemo(()=>_t(h,window.blocklet),[h]),T=ee((v,I)=>{const w=qe(v);if(w.length&&n(w.map(M=>M.id)),I&&!I.customPreventRedirect){const M=Ht(v,g);M&&typeof M=="string"&&window.open(M,"_blank","noopener,noreferrer")}});return r.jsxs(ur,{ref:u,className:"notification-row",id:e.id,isRead:x,inDialog:s,highlight:a,isMd:c,onClick:v=>T(e,v),children:[y?r.jsx(ve,{activity:e.activity.type,size:c?24:32}):r.jsx(ye,{severity:e.severity,size:c?24:32}),r.jsxs(m,{className:"notification",display:"flex",flexDirection:"column",alignItems:"start",children:[r.jsxs(m,{width:"100%",display:"flex",justifyContent:"space-between",alignItems:"center",gap:1,className:"header",mb:1.5,children:[y&&b?r.jsx(J,{actors:d,teamDid:h,size:c?24:32,avatarFallback:r.jsx(V,{blocklet:t,hideDot:!0,size:c?24:32})}):r.jsx(V,{blocklet:t,hideDot:!0,size:c?24:32}),r.jsx(Pe,{value:e.createdAt,locale:l,shouldUpdate:!0,style:{color:o.palette.text.secondary,fontSize:"0.875rem",minWidth:"50px",whiteSpace:"nowrap"}})]}),y?r.jsx(Ye,{notification:e,isMultiple:R,blocklet:t,mountPoint:g,avatarFallback:r.jsx(V,{blocklet:t,hideDot:!0,size:c?24:32})}):r.jsxs(r.Fragment,{children:[r.jsx(A,{variant:"body1",className:"title",color:"rgba(24, 24, 27, 1)",style:{marginTop:0},sx:{mb:.5},children:e.title}),r.jsx(Kt,{notification:e,rows:s?0:2})]}),j.length>0?r.jsx(m,{display:"flex",justifyContent:"start",alignItems:"center",gap:1,mt:1.5,children:j.map((v,I)=>r.jsxs(p.Fragment,{children:[r.jsx(se,{href:v.link,target:"_blank",className:"link",rel:"noopener noreferrer",sx:{fontSize:"15px"},onClick:w=>{w.customPreventRedirect=!0},children:v.name},v.link),I<j.length-1?r.jsx(ne,{orientation:"vertical",sx:{ml:1,mr:1,height:12,borderWidth:"1px"}}):null]},v.link))}):null]}),(e==null?void 0:e.description)&&e.severity==="error"&&r.jsx(m,{className:"copy-button",children:r.jsx(at,{size:"small",children:r.jsx(pt,{sx:{fontSize:22},content:(e==null?void 0:e.description)||""})})})]})}function dr({data:e,blockletMap:t,onReadBatch:n=()=>{},inDialog:s=!1,highlightId:a,highlight:l=!1,type:o="service"}){const{t:c}=Se(),u=p.useRef(null),[x,y]=p.useState(!1),[b,j]=p.useState(!0),[C,R]=p.useState(!1),d=p.useRef(new Set),h=p.useRef(new Set),g=p.useRef(null),T=p.useRef(null),v=p.useRef(!1),I=p.useMemo(()=>s?e==null?void 0:e.slice(0,5):e,[s,e]),w=p.useMemo(()=>yt(I),[I]),M=p.useMemo(()=>{const f=new Map;return w&&w.length&&w.forEach(k=>{f.set(k.id,k)}),f},[w]);p.useEffect(()=>{const f=()=>{j(document.visibilityState==="visible")};return document.addEventListener("visibilitychange",f),()=>{document.removeEventListener("visibilitychange",f)}},[]);const O=p.useCallback(()=>{if(!s&&d.current.size>0){const f=[];d.current.forEach(k=>{if(h.current.has(k))return;const S=M.get(k);if(S){const{receivers:z=[],items:L=[]}=S;if(z.length&&!z[0].read&&(f.push(k),h.current.add(k),L.length>0&&L.forEach($=>{const P=$.id;P&&!h.current.has(P)&&(f.push(P),h.current.add(P))}),T.current)){const $=document.getElementById(k);$&&T.current.unobserve($)}}}),f.length>0&&(n(f),setTimeout(()=>{y(!1)},300)),d.current.clear()}},[s,M,n]),q=p.useCallback(()=>{if(s||!u.current||!b)return;T.current&&T.current.disconnect();const f={root:null,rootMargin:"0px",threshold:.5},k=new IntersectionObserver(z=>{x&&z.forEach(L=>{const $=L.target.id;if(h.current.has($))return;const P=M.get($);if(P){const{receivers:je=[]}=P;je.length&&!je[0].read&&(L.isIntersecting?(d.current.add($),C||O()):d.current.delete($))}})},f);T.current=k,Array.from(u.current.querySelectorAll(".notification-row")).filter(z=>{const L=z.id;if(h.current.has(L))return!1;const $=M.get(L);if($){const{receivers:P=[]}=$;return P.length&&!P[0].read}return!1}).forEach(z=>{k.observe(z)}),v.current=!1},[x,s,C,b,M,O]);return p.useEffect(()=>{s||(v.current=!0,T.current&&b&&x&&setTimeout(()=>{q()},0))},[I,x,b,q,s]),p.useEffect(()=>{if(s||!u.current||!b)return;let f=window;if(o==="server"&&(f=document.getElementById("arc__dashboard-main")),!f){const S=document.getElementsByClassName("dashboard-main")[0];S&&(f=S)}if(!f)return;const k=S=>{S.isTrusted&&(x||y(!0),R(!0),g.current&&clearTimeout(g.current),g.current=setTimeout(()=>{R(!1),O(),v.current&&q()},300))};return f.addEventListener("scroll",k,{passive:!0}),()=>{f.removeEventListener("scroll",k),g.current&&clearTimeout(g.current)}},[s,x,b,O,q,o]),p.useEffect(()=>(s||q(),()=>{T.current&&T.current.disconnect()}),[q,s]),lt(()=>{setTimeout(()=>{const f=Wt(u.current),k=Bt(M,f);n(k.map(S=>S.id))},2e3)}),w!=null&&w.length?r.jsx(m,{ref:u,display:"flex",flexDirection:"column",sx:{...s?{maxHeight:"calc(-200px + 100vh)",overflow:"auto"}:{}},children:w==null?void 0:w.map(f=>{var S;const k=f.source==="system"?t.get(f.entityId||f.sender):t.get(f.componentDid||f.sender);return((S=f==null?void 0:f.type)==null?void 0:S.toLowerCase())==="passthrough"?null:r.jsx(Je,{highlight:l&&a===f.id,inDialog:s,notification:f,blocklet:k,onReadBatch:n},f.id)})}):r.jsx(be,{children:c("notification.allDone")})}const ur=E("div")`
146
146
  @keyframes flash-bg {
147
147
  0% {
148
148
  background-color: ${e=>e.theme.palette.warning.light};
@@ -233,4 +233,4 @@ import{r as p}from"./vendor-react-DEoibe3W.js";import{H as i,j as r,bd as Y,e as
233
233
  text-decoration: none;
234
234
  }
235
235
  }
236
- `;export{Z as A,de as B,dr as N,V as S,Ye as a,Kt as b,te as c};
236
+ `;export{J as A,de as B,dr as N,V as S,Ye as a,Kt as b,te as c};
@@ -1 +1 @@
1
- import"./vendor-react-DEoibe3W.js";import{s as d,w as h,j as e,aa as a,al as t,H as i}from"./vendor-mui-core-FzKVVAue.js";const l=d(h)(({theme:r})=>({backgroundColor:r.palette.background.default,"& .header-row":{display:"flex",justifyContent:"space-between",alignItems:"center",gap:r.spacing(1)},"& .right":{display:"flex",alignItems:"center",gap:r.spacing(1.5)},"& .tabs":{marginTop:r.spacing(2),"& .MuiButton-root":{border:"none",color:"#999","&.active":{color:"#222"}}},"@media (max-width: 900px)":{"& .header-row":{flexDirection:"column",alignItems:"flex-start"},"& .right":{flexDirection:"column",width:"100%",".search-always-open, .toolbar-btn-show, a, button, .MuiButtonGroup-root":{width:"100% !important"}}}}));function c({left:r,tabs:s,actions:n,...o}){return!r&&!s?e.jsx(l,{elevation:0,...o,children:e.jsxs(a,{className:"header-row",children:[e.jsx(a,{className:"left"}),e.jsx(t,{direction:"row",className:"right",children:n})]})}):r&&!s||!r&&s?e.jsx(l,{elevation:0,...o,children:e.jsxs(a,{className:"header-row",children:[e.jsx(a,{className:"left",children:r||s}),e.jsx(t,{direction:"row",className:"right",children:n})]})}):e.jsxs(l,{elevation:0,...o,children:[e.jsxs(a,{className:"header-row",children:[e.jsx(a,{className:"left",children:r}),e.jsx(t,{direction:"row",className:"right",children:n})]}),s&&e.jsx(a,{mt:2,children:s})]})}c.propTypes={left:i.node,tabs:i.node,actions:i.node};c.defaultProps={left:null,tabs:null,actions:null};export{c as L};
1
+ import"./vendor-react-DEoibe3W.js";import{s as d,w as h,j as e,aa as a,al as t,H as i}from"./vendor-mui-core-DMvlMpwf.js";const l=d(h)(({theme:r})=>({backgroundColor:r.palette.background.default,"& .header-row":{display:"flex",justifyContent:"space-between",alignItems:"center",gap:r.spacing(1)},"& .right":{display:"flex",alignItems:"center",gap:r.spacing(1.5)},"& .tabs":{marginTop:r.spacing(2),"& .MuiButton-root":{border:"none",color:"#999","&.active":{color:"#222"}}},"@media (max-width: 900px)":{"& .header-row":{flexDirection:"column",alignItems:"flex-start"},"& .right":{flexDirection:"column",width:"100%",".search-always-open, .toolbar-btn-show, a, button, .MuiButtonGroup-root":{width:"100% !important"}}}}));function c({left:r,tabs:s,actions:n,...o}){return!r&&!s?e.jsx(l,{elevation:0,...o,children:e.jsxs(a,{className:"header-row",children:[e.jsx(a,{className:"left"}),e.jsx(t,{direction:"row",className:"right",children:n})]})}):r&&!s||!r&&s?e.jsx(l,{elevation:0,...o,children:e.jsxs(a,{className:"header-row",children:[e.jsx(a,{className:"left",children:r||s}),e.jsx(t,{direction:"row",className:"right",children:n})]})}):e.jsxs(l,{elevation:0,...o,children:[e.jsxs(a,{className:"header-row",children:[e.jsx(a,{className:"left",children:r}),e.jsx(t,{direction:"row",className:"right",children:n})]}),s&&e.jsx(a,{mt:2,children:s})]})}c.propTypes={left:i.node,tabs:i.node,actions:i.node};c.defaultProps={left:null,tabs:null,actions:null};export{c as L};
@@ -0,0 +1 @@
1
+ import{j as o}from"./vendor-mui-core-DMvlMpwf.js";import"./vendor-react-DEoibe3W.js";import{S as t}from"./studio-CqjHflyE.js";import"./vendor-ux-did-connect-akcz-Ldw.js";import"./vendor-utils-rHXShPKm.js";import"./vendor-hooks-rDgu5KV9.js";import"./lottie-web-jYmAQWuC.js";import"./vendor-arcblock-CORkwLwW.js";import"./TuneOutlined-BEZh1SVU.js";function d(){return o.jsx(t,{children:"Coming soon..."})}export{d as default};