import{r as e}from"./rolldown-runtime-DCMCV6zW.js";import"./vendor-primevue-DxVRNMbC.js";import"./vendor-firebase-CdLSXhbt.js";import{A as t,Dt as n,I as r,O as i,R as a,et as o,ft as s,j as c,k as l,pt as u}from"./vendor-vue-core-X6q-rGJs.js";import"./vendor-other-CyG3qq8S.js";import"./useFeatureFlags-CxRWjdi1.js";import"./api-DQLKc1Xa.js";import"./vendor-markdown-Cola12Wc.js";import"./colorUtil-Cth7eqhK.js";import"./i18n-DjV_9lZM.js";import"./vendor-reka-ui-CHPbCe4i.js";import"./Button-C7dWyQyS.js";import"./dialogService-Cqui0UMO.js";import"./systemStatsStore-D9aNY5gT.js";import"./useErrorHandling-BFB8eSj5.js";import"./dialogStore-CXD5Bcfy.js";import"./useCopyToClipboard-C74olorb.js";import"./vendor-tiptap-BXSIIPYY.js";import"./markdownRendererUtil-Bm7Umh6C.js";import"./useExternalLink-Cc30SNi3.js";import"./vendor-three-CHi1XwmR.js";import{t as d}from"./Load3DControls-C7Lxgjdd.js";import{t as f}from"./AnimationControls-C9rBFNWa.js";import"./load3dService-Ctk3mPz3.js";import{t as p}from"./useLoad3dViewer-B76fxHL5.js";var m={class:`pointer-events-none absolute top-0 left-0 size-full`},h=a({__name:`Preview3d`,props:{modelUrl:{}},setup(e){let a=s(`containerRef`),h=n(p());return u([a,()=>e.modelUrl],async()=>{!a.value||!e.modelUrl||await h.value.initializeStandaloneViewer(a.value,e.modelUrl)}),(e,n)=>(o(),c(`div`,{ref_key:`containerRef`,ref:a,class:`relative w-full h-full`,onMouseenter:n[10]||=(...e)=>h.value.handleMouseEnter&&h.value.handleMouseEnter(...e),onMouseleave:n[11]||=(...e)=>h.value.handleMouseLeave&&h.value.handleMouseLeave(...e),onResize:n[12]||=(...e)=>h.value.handleResize&&h.value.handleResize(...e)},[i(`div`,m,[r(d,{"scene-config":h.value,"onUpdate:sceneConfig":n[0]||=e=>h.value=e,"model-config":h.value,"onUpdate:modelConfig":n[1]||=e=>h.value=e,"camera-config":h.value,"onUpdate:cameraConfig":n[2]||=e=>h.value=e,"light-config":h.value,"onUpdate:lightConfig":n[3]||=e=>h.value=e,"is-splat-model":h.value.isSplatModel,"is-ply-model":h.value.isPlyModel,"has-skeleton":h.value.hasSkeleton,onUpdateBackgroundImage:h.value.handleBackgroundImageUpdate,onExportModel:h.value.exportModel},null,8,[`scene-config`,`model-config`,`camera-config`,`light-config`,`is-splat-model`,`is-ply-model`,`has-skeleton`,`onUpdateBackgroundImage`,`onExportModel`]),h.value.animations&&h.value.animations.length>0?(o(),l(f,{key:0,animations:h.value.animations,"onUpdate:animations":n[4]||=e=>h.value.animations=e,playing:h.value.playing,"onUpdate:playing":n[5]||=e=>h.value.playing=e,"selected-speed":h.value.selectedSpeed,"onUpdate:selectedSpeed":n[6]||=e=>h.value.selectedSpeed=e,"selected-animation":h.value.selectedAnimation,"onUpdate:selectedAnimation":n[7]||=e=>h.value.selectedAnimation=e,"animation-progress":h.value.animationProgress,"onUpdate:animationProgress":n[8]||=e=>h.value.animationProgress=e,"animation-duration":h.value.animationDuration,"onUpdate:animationDuration":n[9]||=e=>h.value.animationDuration=e,onSeek:h.value.handleSeek},null,8,[`animations`,`playing`,`selected-speed`,`selected-animation`,`animation-progress`,`animation-duration`,`onSeek`])):t(``,!0)])],544))}});export{h as default};
//# sourceMappingURL=Preview3d-B7oua7GI.js.map