1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._posthogChunkIds=e._posthogChunkIds||{},e._posthogChunkIds[n]="01a109ac-5c93-7300-b043-d01a2be6b568")}catch(e){}}();import{_ as w}from"./r2Mya22F.js";import{S as B,af as D,A as F,B as M,Z as d,a0 as s,a9 as o,c as r,Y as p,aa as N,at as R,ac as b,ag as t,aq as S,$ as U,am as q}from"./CVOcV0X7.js";import{_ as z}from"./Cq8CYQB3.js";import{_ as Y}from"./CORQIeT0.js";import{_ as C}from"./CXWOfBWH.js";import{_ as H}from"./B67x0Frq.js";import{u as I,T as V,a as O,p as f,D as W}from"./RpgOXBD7.js";import"./UNpw5gcI.js";import"./BHLCqphU.js";import"./7JFtXw1n.js";import"./_Ippfxlp.js";import"./C63tX8t1.js";import"./CVX-Ezn7.js";import"./BUTEot8p.js";import"./CblmvyeJ.js";import"./BOMRRXdF.js";import"./DNNcwzrd.js";import"./BEh6-4wh.js";import"./DKZHEy-r.js";import"./C1Yr80As.js";import"./D-pctMGk.js";import"./GpVVYUbB.js";import"./NdYmAeDX.js";import"./Dix9bfnP.js";import"./OK_sthfU.js";import"./kRIii9yh.js";import"./jFYhBC76.js";import"./Bw5ZQwxj.js";import"./C03CyzQ7.js";import"./BWw22w6z.js";const Z={class:"sticky top-0 z-[60] w-full border-b border-default bg-default/95 backdrop-blur supports-[backdrop-filter]:bg-default/80"},j={"aria-label":"Response templates"},Ae=B({__name:"templates",setup(G){D({title:"Templates"});const i=F(),v=M(),{templates:h,loading:T}=I(),c=r(()=>i.path.replace(/\/$/,"")||"/"),l=r(()=>c.value==="/dashboard/templates"),g=r(()=>[{label:"Response Templates",icon:"i-hugeicons-file-02",to:"/dashboard/templates",current:l.value},{label:"Deliverables Form",icon:"i-hugeicons-check-list",to:"/dashboard/templates/deliverables-form",current:c.value.startsWith("/dashboard/templates/deliverables-form")}]),_=r(()=>f(i.query.type)),y=r(()=>`templates-${_.value}`);function P(e){return h.value.find(a=>a.type===e)??null}function E(e){const a=f(e),n={...i.query};a===W?delete n.type:n.type=a,v.replace({query:n})}const k=r(()=>V.map(e=>{const a=P(e)?.isActive===!0;return{label:O[e].tabLabel,active:_.value===e,badge:a?{label:"Live",color:"success",variant:"subtle"}:{label:"Off",color:"neutral",variant:"subtle"},onSelect:()=>E(e)}}));return(e,a)=>{const n=w,x=q,A=z,$=Y,m=C,u=S,L=H;return p(),d(L,{id:"templates",ui:o(l)?{body:"p-0 sm:p-0 gap-0 sm:gap-0"}:void 0},{header:s(()=>[t(n,{title:"Templates",border:"none"}),t(A,{"nav-items":o(g),title:"Template pages"},U({_:2},[o(l)?{name:"right",fn:s(()=>[t(x,{form:o(y),type:"submit",label:"Save changes",color:"primary",size:"sm",loading:o(T).saving},null,8,["form","loading"])]),key:"0"}:void 0]),1032,["nav-items"])]),body:s(()=>[o(l)?(p(),N(R,{key:0},[b("div",Z,[t(m,null,{default:s(()=>[b("nav",j,[t($,{items:o(k),highlight:"",orientation:"horizontal",color:"primary",class:"min-w-0 overflow-x-auto [scrollbar-width:none] [&::-webkit-scrollbar]:hidden"},null,8,["items"])])]),_:1})]),t(m,{class:"pt-6 pb-32"},{default:s(()=>[t(u)]),_:1})],64)):(p(),d(m,{key:1},{default:s(()=>[t(u)]),_:1}))]),_:1},8,["ui"])}}});export{Ae as default}; 2 3//# chunkId=01a109ac-5c93-7300-b043-d01a2be6b568
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.