import{r as h,j as e}from"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a2777.js";import{u as j}from"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277720.js";import{u as v}from"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277729.js";import{Y as f,V as g,$ as r}from"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277711.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a27778.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277719.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a27777.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277723.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a27774.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a27773.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a27772.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277710.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a27776.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a27779.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277735.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277736.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277737.js";import"./v_7_4_3_5_5680d44b-ceb1-449a-bec3-8cbef70a277738.js";function M(){const{language:a}=j(),{automaticoBK:i,keys:n,createOrEditAttBk:s,setCreateOrEditAttBk:l,setActiveKey:o,saveAutomaticoBK:c,startCreateOrEditAtt:m,removeAutomaticoBK:d}=v();h.useEffect(()=>(m(),()=>{l({date:"",time:"",recurrency:"",items:[]})}),[]);const u=e.jsxs("div",{className:"form-control w-full",children:[e.jsx("label",{className:"label",children:e.jsx("span",{className:"label-text",children:a.agendamento_recorrencia})}),e.jsxs("select",{className:"!py-0 select select-bordered !select-sm w-full",onChange:t=>l({...s,recurrency:t.target.value}),value:s.recurrency,children:[e.jsx("option",{value:"",children:a.noneSelected}),e.jsx("option",{value:"diario",children:a.diario}),e.jsx("option",{value:"semanal",children:a.semanal}),e.jsx("option",{value:"mensal",children:a.mensal}),e.jsx("option",{value:"trimestral",children:a.trimestral}),e.jsx("option",{value:"semestral",children:a.semestral}),e.jsx("option",{value:"anual",children:a.anual})]})]}),p=e.jsxs("div",{className:"flex justify-between gap-6",children:[e.jsxs("div",{className:"form-control w-full max-w-xs",children:[e.jsx("label",{className:"label",children:e.jsx("span",{className:"label-text",children:a.agendamento_table_data})}),e.jsx("input",{type:"Date",className:"input input-bordered w-full max-w-xs input-sm",value:s.date,onChange:t=>l({...s,date:t.target.value}),min:new Date().toISOString().split("T")[0]})]}),e.jsxs("div",{className:"form-control w-full max-w-xs",children:[e.jsx("label",{className:"label",children:e.jsx("span",{className:"label-text",children:a.agendamento_table_hora})}),e.jsx("input",{type:"time",className:"input input-bordered w-full max-w-xs input-sm cursor-pointer",value:s.time,onChange:t=>l({...s,time:t.target.value})})]})]}),x=n.map(t=>e.jsx("div",{children:e.jsx("label",{htmlFor:t.tag,children:e.jsxs("div",{className:"flex justify-between cursor-pointer items-center hover:bg-[var(--dropdown-background-hover)] h-9 px-1 py-2 rounded",children:[e.jsxs("div",{className:"flex align-center items-center m-2",children:[e.jsx("span",{className:"mr-2",children:t.icon}),e.jsx("span",{children:a[t.nome]})]}),e.jsx("div",{className:"pulse",children:e.jsx(f,{id:t.tag,switchUpdate:()=>o(t.tag,!t.checked),estado:t.checked})})]})})},t.tag));return e.jsxs("div",{className:"grid gap-5 min-w-[500px]",children:[e.jsxs(g,{children:[" ",a.modalTitle," "]}),e.jsx("div",{className:"flex flex-col gap-2 overflow-x-auto",style:{maxHeight:"calc(100vh - 300px)"},children:x}),p,u,e.jsxs("div",{className:"flex justify-between",children:[i.date.length>0&&e.jsx(r,{name:a.removeAutoBackup,funcao:d}),e.jsx(r,{name:a.save,funcao:c})]})]})}export{M as default};
