import{_ as v}from"./D_7E8SMU.js";import{_ as h}from"./BOhf1Bbf.js";import{P as w,j as b,d as I,w as C,m as s,o as p,b as o,G as m,c as u,e as c,t as i,D as k,I as _,f as P}from"./Bgmy51Qv.js";import{u as V}from"./DKgjlGGV.js";import"./CNIrc0EA.js";import"./DZl4_Bww.js";import"./AmaTRG5a.js";import"./BHvLfWtM.js";import"./DuSynPle.js";import"./B2895E6R.js";import"./7pZkuj9N.js";const B={class:"input-wrapper"},D=["placeholder"],q={key:0,class:"error"},F={class:"input-wrapper"},L=["placeholder"],N={key:0,class:"error"},R={class:"input-wrapper"},j={class:"block"},Q={__name:"[id]",setup(K){var d;const{statusObj:y}=V(),l=w(),e=b({id:"",title:"",link:"",type:(d=l==null?void 0:l.query)==null?void 0:d.type,status:2,image:""}),f=t=>{e.value.status=t.key};return(t,a)=>{const g=v,$=h;return p(),I($,{ref:"dataPageRef","set-api":"setFooterImageLink","get-api":"getFooterImageLink","set-image-api":"setFooterImageLinkImage","route-name":"footer-links",hash:"payment-social",name:t.$t("dataPage.fImgs"),"validation-keys":["title","link"],"file-keys":["id","type"],result:s(e),gate:"footer_link",onResult:a[2]||(a[2]=n=>e.value=n)},{form:C(({hasError:n})=>[o("div",B,[o("label",null,i(t.$t("index.title")),1),m(o("input",{type:"text",placeholder:t.$t("index.title"),name:"title","onUpdate:modelValue":a[0]||(a[0]=r=>s(e).title=r),class:k({invalid:!s(e).title&&n})},null,10,D),[[_,s(e).title]]),!s(e).title&&n?(p(),u("span",q,i(t.$t("category.req",{type:t.$t("index.title")})),1)):c("",!0)]),o("div",F,[o("label",null,i(t.$t("admin.link")),1),m(o("input",{type:"text",placeholder:t.$t("admin.link"),name:"link","onUpdate:modelValue":a[1]||(a[1]=r=>s(e).link=r),ref:"link",class:k({invalid:!s(e).link&&n})},null,10,L),[[_,s(e).link]]),!s(e).link&&n?(p(),u("span",N,i(t.$t("category.req",{type:t.$t("admin.link")})),1)):c("",!0)]),o("div",R,[o("label",j,i(t.$t("category.status")),1),P(g,{selectedKey:`${s(e).status}`,options:s(y),onClicked:f},null,8,["selectedKey","options"])])]),_:1},8,["name","result"])}}};export{Q as default};
