import{J as n,j as i,ak as l}from"./vendor-mui-core-BPQ6AEW_.js";import{j as d,r as c}from"./vendor-react-CUXIiAnY.js";import{V as u,b as h}from"./vendor-ux-r9bApERu.js";import g from"./index-B40Ot_fG.js";import"./vendor-utils-BgSaqjGx.js";import"./vendor-hooks-PN9SWiQm.js";import"./lottie-web-4koyQiv_.js";import"./index-DY2wgD65.js";import"./vendor-arcblock-D8WYBDYe.js";import"./confirm-B8poMcDB.js";import"./index-DBs9Ljax.js";import"./session-f4MooMkP.js";import"./did-address-j4poFq12.js";import"./empty-spinner-G6osPzkH.js";import"./bundle-avatar-B6BCKAZI.js";import"./shorten-label-D6jbe4l0.js";import"./list-header-Cv_gaaAc.js";import"./click-to-copy-BuSTGPjJ.js";import"./question-mark-circle.svg-DK9nTUDZ.js";import"./useSetState-cWrp7qoX.js";import"./engine-B4EBuR9s.js";import"./api-uGeIZn4a.js";import"./vendor-mui-x-CWNb8fsW.js";import"./react-beautiful-dnd.esm-DFHKVO-K.js";import"./raf-schd.esm-JNUhxcps.js";import"./wait-connect-DEq0_d-q.js";import"./get-safe-url-DqysS0i0.js";import"./item-CkQtfUug.js";import"./delete-confirm-CP7dMVbK.js";import"./index-B7Hwfql4.js";import"./index-Dx6HKVtJ.js";import"./index-Dy3yCmIK.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};
