import{b as g,r as c,c as d,ac as h,aq as m,i as v,o as y,f as l,e as w,w as s,y as b,m as B,G as F,l as k,t as x,v as i,E as T,j as N,ak as C}from"./index-CS0Lg7FU.js";import{u as L,B as S,b as I,s as M}from"./browse-file-FeMKPK8w.js";import{_ as Q}from"./_plugin-vue_export-helper-BrVfw-gY.js";import"./browse-file-Dm2bZpUL.js";const j={class:"lightpage"},A={class:"lightcontent"},D={__name:"LightPage",setup(V){g();const u=L();let o=c(!1);c(1);let e=d(()=>u.curNode);console.log("curNode: ",e.value);function f(t){let a=M.browseFileTypeMap,r=!0;for(let _ in a)if(a[_].includes(t)){r=!1;break}return r}h(e,()=>{n()});async function n(){if(!e.value)return;let t;if(e.value.lightFile?(t=e.value.lightFile.file_type.toLowerCase(),e.value.lightFile.file_type_number):(t=e.value.file_type.toLowerCase(),e.value.file_type_number),o.value=f(t),o.value)this.type==="bom"&&this.currentBom;else{let a={isDrawer:!1,fileType:t,isAnnotation:!1,documentInfo:{internal_name:e.value.internal_name,object_id:e.value.object_id}};e.value.lightFile&&(a.lightweightInfo=e.value.lightFile),I(a)}}m(async()=>{n()});function p(){window.parent.postMessage("close-lightview","*")}return(t,a)=>(y(),v("div",j,[l(T,{class:"light-toolbar"},{default:s(()=>[l(b,{flat:""},{default:s(()=>[l(B,{name:"iconfont caxa-back",size:"17px",color:"grey-5",onClick:p})]),_:1}),l(F,{class:"title"},{default:s(()=>[k(x(i(e)&&i(e).name),1)]),_:1})]),_:1}),w("div",A,[N(l(S,null,null,512),[[C,!i(o)]])])]))}},G=Q(D,[["__scopeId","data-v-fdf22daf"]]);export{G as default};
