import{L as n,j as i,al as l}from"./vendor-mui-core-CDEc-eG6.js";import{m as d,r as c}from"./vendor-react-DX7tU9aY.js";import{aa as u,b1 as h}from"./vendor-ux-PO0jFgJf.js";import g from"./index-EZZK7Nyo.js";import"./vendor-utils-_C9URqjS.js";import"./vendor-hooks-Ca2cSNuD.js";import"./index-DcM4ljaV.js";import"./vendor-arcblock-BVQTtbN-.js";import"./confirm-BMWka5pp.js";import"./index-DBs9Ljax.js";import"./session-D6Z4R7oi.js";import"./did-address-BNKX5oDP.js";import"./empty-spinner-2fS4Uw6Z.js";import"./bundle-avatar-7Wt_FbiF.js";import"./shorten-label-CEQFm35C.js";import"./list-header-BKicL0iB.js";import"./click-to-copy-BmatCVrP.js";import"./question-mark-circle.svg-B0bcUgC5.js";import"./useSetState-CUbypYGT.js";import"./engine-CvxZhwAf.js";import"./api-Bo6lutcq.js";import"./vendor-mui-x-Bk3pxGrO.js";import"./react-beautiful-dnd.esm-C9wbL7D6.js";import"./raf-schd.esm-BZ-2sjAE.js";import"./wait-connect-B1z3SEpN.js";import"./get-safe-url-C1Ml6qBb.js";import"./item-CHfrpFLz.js";import"./delete-confirm-CwOFci6r.js";import"./index-BObu-fIz.js";import"./index-B0cxyMBd.js";import"./purify.es-HRjpPm7y.js";import"./index-BUN3g9UB.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(),a=n(t=>t.breakpoints.down("md")),m=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:a?{width:"100%",height:window.innerHeight}:{maxWidth:1350,minWidth:930,width:"80%"}},onClose:m,showCloseButton:!0,disableEscapeKeyDown:!0,open:!0,children:i.jsx(l,{sx:{height:"72vh",overflow:"auto",position:"relative"},children:e})}):e}export{T as default};
