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{W as u,aF as h}from"./vendor-ux-bFYdDLNG.js";import g from"./index-CW1G8baa.js";import"./vendor-utils-_C9URqjS.js";import"./vendor-hooks-BrgYeCrj.js";import"./index-DGZk149v.js";import"./vendor-arcblock-DY2miJjh.js";import"./confirm-o5NpDvNJ.js";import"./index-DBs9Ljax.js";import"./session-Dxo7LCKC.js";import"./did-address-B_YXB1wQ.js";import"./empty-spinner-2fS4Uw6Z.js";import"./bundle-avatar-CoGnufMK.js";import"./shorten-label-CEQFm35C.js";import"./list-header-BKicL0iB.js";import"./click-to-copy-CH2KjgKM.js";import"./question-mark-circle.svg-B0bcUgC5.js";import"./useSetState-CUbypYGT.js";import"./engine-B4Mxizj3.js";import"./api-Bo6lutcq.js";import"./vendor-mui-x-Bk3pxGrO.js";import"./react-beautiful-dnd.esm-CVPot6HI.js";import"./raf-schd.esm-BZ-2sjAE.js";import"./wait-connect-D16c5vpx.js";import"./get-safe-url-B1bR9jl-.js";import"./item-C3aaDA7o.js";import"./delete-confirm-DS9-TjyF.js";import"./index-BTDbL_lq.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};
