import{r as x,j as e}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b.js";import{u as g}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b36.js";import{A as h,q as f}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b24.js";import{u as C}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b20.js";import{au as j,ao as c,bv as m,al as v}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b11.js";import{c as y}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b105.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b8.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b7.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b9.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b6.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b19.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b4.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b3.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b2.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b10.js";function z({updateCat:p}){const{variaveisWA:i}=h(),{categories:r}=g(),{language:s}=C(),{close:u}=f(),[a,d]=x.useState([]),n=t=>{u(),p(t)};return e.jsx("div",{style:{position:"initial"},children:e.jsx("ul",{className:"overflow-hidden flex",children:e.jsxs("div",{className:i.modalOptions.content2,children:[e.jsx(j,{filtragem:t=>{let o=[];r.forEach(l=>{l.name?.toUpperCase().includes(t.toUpperCase())&&o.push(l)}),d(o)},placeholder:s.searchCategory,dependenciasADD:[r],btnClear:!0}),e.jsxs("div",{className:"max-w-[300px] overflow-x-hidden overflow-y-auto "+i.listagem.content1,style:{maxHeight:"calc(100vh - 63px)"},children:[a.length!==0&&e.jsx(c,{content:s.cancelSelection,icon:e.jsx(y,{className:"w-5 h-5 text-red-500"}),setFunction:()=>n(""),stroke:"1"}),a.map((t,o)=>e.jsx(c,{content:t.name,icon:e.jsx(m,{className:"w-5 h-5",style:{color:t.hexColor}}),setFunction:()=>n(t.id),stroke:"1"},o)),a.length===0&&e.jsx(v,{icon:e.jsx(m,{size:24,className:"text-[var(--primaria)]"}),title:s.noneCategoryFound,description:s.noneCategoryFound_des})]})]})})})}export{z as default};
