import{d as v,K as D,b as u,c as g,z as t,t as p,D as l,F as w,J as k,H as I,q as P}from"./registerWidgets.68b4d727.js";import{D as b,n as q}from"./DashPlayer.b3abf25c.js";import{L as x}from"./CircularLoading.d7ae4d10.js";import{r as B}from"./index.9f0d5f28.js";import{B as R}from"./BackButton.e07bee68.js";import{a as m}from"./asyncComputed.93878fc8.js";import{D as C}from"./dashes.22b9d6ab.js";import{W as F}from"./workspaces.987721db.js";import"./passwordlessManager.a7d5c3a4.js";import"./runnerData.d765a3b7.js";import"./executeJs.c67b4605.js";import"./PlayerNavbar.db54667c.js";import"./icons.ef86ff2e.js";import"./WidgetsFrame.990b2044.js";import"./colors.8344a969.js";import"./Modal.d08e28ea.js";import"./log.088604d7.js";import"./Passwordless.bf03ab53.js";import"./lottie.d1957a7e.js";import"./activeRecord.65858c58.js";(function(){try{var s=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},a=new Error().stack;a&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[a]="97d52ae6-9192-4295-a0cd-ad0faa0aff48",s._sentryDebugIdIdentifier="sentry-dbid-97d52ae6-9192-4295-a0cd-ad0faa0aff48")}catch{}})();const E=v({__name:"DashPreview",setup(s){const a=k(),o=I(),c=({id:e,type:n})=>{n==="dash"?(o.push({name:"dashPreview",params:{dashId:e},query:a.query}),h()):o.push({name:"form-preview",params:{formId:e},query:a.query})},f=()=>{var e;!((e=r.value)!=null&&e.path)||o.push(`/_editor/dash/${encodeURIComponent(r.value.path)}`)},{loading:y,result:r,refetch:h}=m(()=>C.get(a.params.dashPath)),{result:d}=m(()=>F.get()),i=D(()=>{if(!r.value||!d.value||!r.value.makeRunnerData(d.value))return null;const e=q.create(r.value.makeRunnerData(d.value),!1);return e.onRedirect(({url:n,queryParams:_})=>B(o,n,_)),e});return(e,n)=>(u(),g(w,null,[t(y)||!t(r)?(u(),p(x,{key:0,class:"loading",justify:"center"})):l("",!0),t(i)?(u(),p(b,{key:1,class:"player",dash:t(i).runnerData,"is-preview":!0,params:t(a).query,"dash-player-state":t(i),onNavigate:c},null,8,["dash","params","dash-player-state"])):l("",!0),t(r)?(u(),p(R,{key:2,onExitFullscreenPreview:f})):l("",!0)],64))}});const Z=P(E,[["__scopeId","data-v-dde58483"]]);export{Z as default};
//# sourceMappingURL=DashPreview.73315172.js.map
