import{J as n,j as i,ak as l}from"./vendor-mui-core-CnXrAOs3.js";import{j as d,r as c}from"./vendor-react-Dvs43sk9.js";import{V as u,b as h}from"./vendor-ux-5OlTXZBe.js";import g from"./index-CPlFvcnd.js";import"./vendor-utils-cJEl_UEd.js";import"./vendor-hooks-CjESGRlR.js";import"./lottie-web-4koyQiv_.js";import"./index-Cq3xfsOS.js";import"./vendor-arcblock-CqplRmyi.js";import"./confirm-D_oS4C5N.js";import"./index-DBs9Ljax.js";import"./session-BYq9-2GE.js";import"./did-address-C5FXzeAS.js";import"./empty-spinner-DYOzicuy.js";import"./bundle-avatar-B9iCn_eS.js";import"./shorten-label-RqvHqcC3.js";import"./list-header-BE2kzda_.js";import"./click-to-copy-CzGMi2Jw.js";import"./question-mark-circle.svg-B4stD6SS.js";import"./useSetState-DFuQZPPV.js";import"./engine-DXhw4g-J.js";import"./api-Btn0Tp3W.js";import"./vendor-mui-x-bJ5idfMH.js";import"./react-beautiful-dnd.esm-ZwmTP19t.js";import"./raf-schd.esm-CHNehTG3.js";import"./wait-connect-BA-9v9IK.js";import"./get-safe-url-mKD2PdwN.js";import"./item-D48n_jCS.js";import"./delete-confirm-DwFvaC6s.js";import"./index-B5fUUj0x.js";import"./index-De-Vgsb6.js";import"./index-D5TNmV3K.js";const r=new URL(window.location.href),s=r.searchParams.get("mode")==="dialog",w=s?"":r.searchParams.get("padding")||"";function T(){const{t:p}=u(),{componentDid:o}=d(),m=n(t=>t.breakpoints.down("md")),a=t=>{t.stopPropagation(),window.parent.postMessage({event:"resourceDialog.close",componentDid:o},"*")};c.useEffect(()=>{window.parent.postMessage({event:"resourceDialog.loaded",componentDid:o},"*")},[o]);const e=i.jsx(g,{padding:w,initUrl:r});return s?i.jsx(h,{className:"studio-dialog",title:p("blocklet.publish.blockletStudio"),maxWidth:!1,fullWidth:!1,PaperProps:{style:m?{width:"100%",height:window.innerHeight}:{maxWidth:1350,minWidth:930,width:"80%"}},onClose:a,showCloseButton:!0,disableEscapeKeyDown:!0,open:!0,children:i.jsx(l,{sx:{height:"72vh",overflow:"auto",position:"relative"},children:e})}):e}export{T as default};
