1import{d as b,J as w,w as k,c as l,a as e,t as m,u as a,k as f,F as y,o as d,m as c}from"./ClHkM_td.js";import{u as x}from"./D8G5JWCU.js";import{u as A}from"./BgaU3VSk.js";import{u as C}from"./_6RBNlyi.js";import"./C9xrhZ69.js";const B={class:"file-card pm-card pm-card--plain detail-card--nuxt"},I={class:"file-card__top"},D={class:"file-card__head-text"},S={class:"file-card__title"},F={class:"file-card__meta"},H={key:0,class:"pm-alert pm-alert--error",style:{"margin-top":"16px"}},N={class:"file-card__actions"},R=["href"],J=b({__name:"[fileId]",async setup(U){let o,p;const h=w(),{cabinetApi:v}=x(),i=c(()=>String(h.params.fileId||"")),{data:r,error:u,refresh:g}=([o,p]=k(()=>A("cabinet-file-detail",()=>v(`/files/${i.value}`),{watch:[i],server:!1})),o=await o,p(),o);C(u,g);const s=c(()=>String(r.value?.download_url||"").trim()),_=c(()=>{if(s.value&&/^https?:\/\//i.test(s.value)||s.value&&s.value.startsWith("/"))return s.value;const n=i.value;return n?`/cabinet/files/${encodeURIComponent(n)}/download`:""});return(n,t)=>(d(),l(y,null,[t[3]||(t[3]=e("section",{class:"page-head page-head--cabinet page-head--nuxt"},[e("div",null,[e("h1",{class:"page-head__title"},"Файл"),e("p",{class:"page-head__subtitle"},"ÐÑоÑмоÑÑ Ð¸ ÑкаÑивание Ñайла паÑиенÑа.")])],-1)),e("article",B,[e("div",I,[t[0]||(t[0]=e("div",{class:"file-card__icon-wrap","aria-hidden":"true"},[e("svg",{viewBox:"0 0 24 24",fill:"none"},[e("path",{d:"M3.5 8.5A1.5 1.5 0 0 1 5 7h4l2 2h8A1.5 1.5 0 0 1 20.5 10.5v7A2.5 2.5 0 0 1 18 20H6a2.5 2.5 0 0 1-2.5-2.5v-9Z",stroke:"currentColor","stroke-width":"1.7","stroke-linejoin":"round"})])],-1)),e("div",D,[e("div",S,m(a(r)?.doc?.title||a(r)?.doc?.name||"Файл"),1),e("div",F,m(a(r)?.doc?.date||a(r)?.doc?.created_at||"ÐаÑа не Ñказана"),1)]),t[1]||(t[1]=e("span",{class:"pm-badge pm-badge--primary"},"Файл",-1))]),a(u)?(d(),l("p",H," Ðе ÑдалоÑÑ Ð·Ð°Ð³ÑÑзиÑÑ Ñайл. ")):f("",!0),e("div",N,[a(_)?(d(),l("a",{key:0,class:"btn btn--primary",href:a(_),target:"_blank",rel:"noopener"}," СкаÑаÑÑ ",8,R)):f("",!0),t[2]||(t[2]=e("a",{class:"btn btn--ghost",href:"/cabinet/files"},"Ðазад",-1))])])],64))}});export{J as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.