import"./rolldown-runtime-DIIn1E2Q.js";import"./vendor-primevue-_eYbXsHY.js";import"./vendor-firebase-D7u00oy9.js";import{A as e,I as t,O as n,Q as r,R as i,et as a,ft as o,j as s,k as c,kt as l,pt as u}from"./vendor-vue-core-DO0afONr.js";import"./vendor-other-D7fTIduy.js";import"./useFeatureFlags-ChmiVSwD.js";import"./api-BebQfoGK.js";import"./vendor-markdown-Da9QPS2x.js";import"./colorUtil-xHrUTSza.js";import"./i18n-dAUEhQVe.js";import"./vendor-reka-ui-D1HCh14_.js";import"./Button-hTbieW3T.js";import"./dialogService-Cm1GEBK8.js";import"./formatUtil-Gr6H7233.js";import"./userStore-DMlTsx5E.js";import"./useErrorHandling-DudkVSep.js";import"./extensionStore-P-YqST__.js";import"./useExternalLink-DY6FqhTr.js";import"./vendor-tiptap-CcjHVRxb.js";import"./markdownRendererUtil-PltcX2Bi.js";import"./Popover-BhkpNQxC.js";import"./electronDownloadStore-BYrGQ7mS.js";import"./vendor-three-8NczM_fZ.js";import{t as d}from"./Load3DControls-E5pxy74X.js";import{t as f}from"./AnimationControls-DNRGBGTs.js";import"./load3dService-D7UetPdG.js";import{t as p}from"./useLoad3dViewer-9bWqoOpD.js";var m={class:`pointer-events-none absolute top-0 left-0 size-full`},h=i({__name:`Preview3d`,props:{modelUrl:{}},setup(i){let h=o(`containerRef`),g=l(p());return u([h,()=>i.modelUrl],async()=>{!h.value||!i.modelUrl||await g.value.initializeStandaloneViewer(h.value,i.modelUrl)}),r(()=>{g.value.cleanup()}),(r,i)=>(a(),s(`div`,{ref_key:`containerRef`,ref:h,class:`relative size-full self-center md:w-[calc(100%-150px)]`,onMouseenter:i[10]||=(...e)=>g.value.handleMouseEnter&&g.value.handleMouseEnter(...e),onMouseleave:i[11]||=(...e)=>g.value.handleMouseLeave&&g.value.handleMouseLeave(...e),onResize:i[12]||=(...e)=>g.value.handleResize&&g.value.handleResize(...e)},[n(`div`,m,[t(d,{"scene-config":g.value,"onUpdate:sceneConfig":i[0]||=e=>g.value=e,"model-config":g.value,"onUpdate:modelConfig":i[1]||=e=>g.value=e,"camera-config":g.value,"onUpdate:cameraConfig":i[2]||=e=>g.value=e,"light-config":g.value,"onUpdate:lightConfig":i[3]||=e=>g.value=e,"is-splat-model":g.value.isSplatModel,"is-ply-model":g.value.isPlyModel,"has-skeleton":g.value.hasSkeleton,onUpdateBackgroundImage:g.value.handleBackgroundImageUpdate,onExportModel:g.value.exportModel},null,8,[`scene-config`,`model-config`,`camera-config`,`light-config`,`is-splat-model`,`is-ply-model`,`has-skeleton`,`onUpdateBackgroundImage`,`onExportModel`]),g.value.animations&&g.value.animations.length>0?(a(),c(f,{key:0,animations:g.value.animations,"onUpdate:animations":i[4]||=e=>g.value.animations=e,playing:g.value.playing,"onUpdate:playing":i[5]||=e=>g.value.playing=e,"selected-speed":g.value.selectedSpeed,"onUpdate:selectedSpeed":i[6]||=e=>g.value.selectedSpeed=e,"selected-animation":g.value.selectedAnimation,"onUpdate:selectedAnimation":i[7]||=e=>g.value.selectedAnimation=e,"animation-progress":g.value.animationProgress,"onUpdate:animationProgress":i[8]||=e=>g.value.animationProgress=e,"animation-duration":g.value.animationDuration,"onUpdate:animationDuration":i[9]||=e=>g.value.animationDuration=e,onSeek:g.value.handleSeek},null,8,[`animations`,`playing`,`selected-speed`,`selected-animation`,`animation-progress`,`animation-duration`,`onSeek`])):e(``,!0)])],544))}});export{h as default};
//# sourceMappingURL=Preview3d-B0kIngs1.js.map