import{j as e}from"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89263.js";import{a as h}from"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89262.js";import{u as j}from"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89264.js";import{u as v}from"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892636.js";import{b1 as f,D as g,H as r}from"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89268.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89265.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89266.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892625.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89269.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892610.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c89267.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c8926.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892620.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892644.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892645.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892646.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892647.js";import"./v_7_4_3_72_6a457bf5-eeae-4570-8821-bd6fa39c892648.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};
