import{d as k,a as d,u as _,e as t,g as b,j as o,o as f,h as D,w as s,i as n,aQ as B,aR as h,s as v,G as g}from"./index.ace9693c.js";import{u as w}from"./useRouteParam.1483cbc1.js";import{u as C}from"./useSubscriptionWithDependencies.3c89067d.js";import{u as x}from"./usePageTitle.12638eb5.js";const I=k({__name:"BlockView",setup(y){const u=d(),a=_(),c=w("blockDocumentId"),r=t(()=>c.value?[c.value]:null),l=C(u.blockDocuments.getBlockDocument,r),e=t(()=>l.response),m=()=>{a.push(g.blocks())},i=t(()=>e.value?`Block: ${e.value.name}`:"Block");return x(i),(P,R)=>{const p=b("p-layout-default");return o(e)?(f(),D(p,{key:0,class:"block-view"},{header:s(()=>[n(o(B),{"block-document":o(e),onDelete:m},null,8,["block-document"])]),default:s(()=>[n(o(h),{"block-document":o(e)},null,8,["block-document"])]),_:1})):v("",!0)}}});export{I as default};
