import{T as g,c as _,a as n,b as e,w as v,t as i,d,v as p,u as t,y as f,g as y,o as h,q as S}from"./app-13978987.js";import{_ as V}from"./AdminLayout-bd13ff9d.js";import{_ as U}from"./PageHeader-8c638686.js";import{_ as x}from"./SpinnerBtn-cb152833.js";import{_ as E}from"./RichEditor-132d6d13.js";import{_ as r}from"./InputFieldError-52549d23.js";import"./dropdown-45d66330.js";import"./FloatingDropdown-0be3e47c.js";const M={class:"container p-4 sm:p-6"},j={class:"card mx-auto w-[800px]"},O={class:"card-body"},T={class:"mb-2"},w={class:"label mb-2"},$={class:"mb-2"},k={class:"label mb-2"},C={class:"mb-2"},D={class:"label mb-2"},B={class:"mb-2"},I={class:"label mb-2"},L={class:"mb-2 mt-3"},N={class:"mb-2 mt-10"},q={class:"mb-2"},A={class:"mb-2"},F={class:"mb-2 mt-2"},P={class:"mb-2 mt-2"},z={class:"mb-2 mt-3"},G={for:"toggle-status",class:"toggle toggle-sm"},H=e("div",{class:"toggle-body"},null,-1),J={class:"label label-md"},K={class:"mb-2"},Q=y({layout:V}),le=Object.assign(Q,{__name:"Edit",props:["buttons","job"],setup(u){const c=u,m=c.job,s=g({title:m.title??"",location:m.location??"",type:m.type??"",expert_level:m.expert_level??"",description:m.description??"",is_active:m.is_active??!0,seo:m.meta??{title:"",image:"",description:"",tags:""},_method:"put"}),b=()=>{s.post(route("admin.jobs.update",c.job),{onSuccess:()=>{S.success(trans("Updated Successfully")),s.reset()}})};return(a,l)=>(h(),_("main",M,[n(U,{title:"Edit Integration",buttons:u.buttons},null,8,["buttons"]),e("div",j,[e("div",O,[e("form",{onSubmit:v(b,["prevent"])},[e("div",T,[e("label",w,i(a.trans("Title")),1),d(e("input",{type:"text","onUpdate:modelValue":l[0]||(l[0]=o=>t(s).title=o),class:"input",placeholder:"Software Engineer"},null,512),[[p,t(s).title]]),n(r,{message:t(s).errors.title},null,8,["message"])]),e("div",$,[e("label",k,i(a.trans("Location")),1),d(e("input",{type:"text","onUpdate:modelValue":l[1]||(l[1]=o=>t(s).location=o),class:"input",placeholder:"California, US"},null,512),[[p,t(s).location]]),n(r,{message:t(s).errors.location},null,8,["message"])]),e("div",C,[e("label",D,i(a.trans("Type")),1),d(e("input",{type:"text","onUpdate:modelValue":l[2]||(l[2]=o=>t(s).type=o),class:"input",placeholder:"Fulltime, Part-time"},null,512),[[p,t(s).type]]),n(r,{message:t(s).errors.type},null,8,["message"])]),e("div",B,[e("label",I,i(a.trans("Expert Level")),1),d(e("input",{type:"text","onUpdate:modelValue":l[3]||(l[3]=o=>t(s).expert_level=o),class:"input",placeholder:"Senior, Mid"},null,512),[[p,t(s).expert_level]]),n(r,{message:t(s).errors.expert_level},null,8,["message"])]),e("div",L,[e("label",null,i(a.trans("Description")),1),n(E,{modelValue:t(s).description,"onUpdate:modelValue":l[4]||(l[4]=o=>t(s).description=o)},null,8,["modelValue"]),n(r,{message:t(s).errors.description},null,8,["message"])]),e("h6",N,i(a.trans("SEO Settings")),1),e("div",q,[e("label",null,i(a.trans("SEO Meta Title")),1),d(e("input",{"onUpdate:modelValue":l[5]||(l[5]=o=>t(s).seo.title=o),type:"text",class:"input"},null,512),[[p,t(s).seo.title]]),n(r,{message:t(s).errors["seo.title"]},null,8,["message"])]),e("div",A,[e("label",null,i(a.trans("SEO Meta Image")),1),e("input",{onChange:l[6]||(l[6]=o=>t(s).seo.image=o.target.files[0]),type:"file",class:"input",accept:"image/*"},null,32),n(r,{message:t(s).errors["seo.image"]},null,8,["message"])]),e("div",F,[e("label",null,i(a.trans("SEO Meta Description")),1),d(e("textarea",{"onUpdate:modelValue":l[7]||(l[7]=o=>t(s).seo.description=o),class:"input h-100"},null,512),[[p,t(s).seo.description]]),n(r,{message:t(s).errors["seo.description"]},null,8,["message"])]),e("div",P,[e("label",null,i(a.trans("SEO Meta Tags")),1),d(e("input",{"onUpdate:modelValue":l[8]||(l[8]=o=>t(s).seo.tags=o),type:"text",class:"input"},null,512),[[p,t(s).seo.tags]]),n(r,{message:t(s).errors["seo.tags"]},null,8,["message"])]),e("div",z,[e("div",null,[e("label",G,[d(e("input",{"onUpdate:modelValue":l[9]||(l[9]=o=>t(s).is_active=o),class:"toggle-input peer sr-only",id:"toggle-status",type:"checkbox"},null,512),[[f,t(s).is_active]]),H,e("span",J,i(a.trans("Is Active?")),1)])])]),e("div",K,[n(x,{classes:"btn btn-primary",processing:t(s).processing,"btn-text":a.trans("Update")},null,8,["processing","btn-text"])])],32)])])]))}});export{le as default};
