import{_ as d,y as f,a7 as h}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b11.js";import{j as e,r as n}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b.js";import{R as v}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b6.js";import{K as m,s as x,q as g,A as L,z as u,as as C,B as b}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b24.js";import{C as j}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b90.js";import{u as _}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b62.js";import{c as z}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b9.js";import{e as c}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b22.js";import{N as M}from"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b33.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b19.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b7.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b20.js";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b8.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";import"./v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b46.js";const R=n.lazy(() => __vitePreload(()=>import(chrome.runtime.getURL("content/assets/js/v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b87.js")),[]));function y(){return e.jsx(n.Suspense,{fallback:e.jsx(e.Fragment,{}),children:e.jsx(R,{})})}function I(){const{menuContent:r,setMenuContent:t}=m(_(a=>({menuContent:a.menuContent,setMenuContent:a.setMenuContent}))),o=x(a=>a.label),{open:l}=g.getState(),s=L(a=>a.isNewModel),i=u(a=>a.activeChat);n.useEffect(()=>{i?.id?.server==="@lid"&&t("children","respostasRapidas")},[i,t]);const p=[{id:"perfilContato",ico:e.jsx(C,{size:20}),name:"perfilContato",renderInLid:!1,funcao:()=>t("children","perfilContato")},{id:"respostasRapidas",ico:e.jsx(f,{size:20}),name:"RespostaRapida",renderInLid:!0,funcao:()=>t("children","respostasRapidas")},{id:"anotacoes",ico:e.jsx(z,{size:20}),name:"Agendamentos",renderInLid:!1,funcao:()=>t("children","anotacoes")},{id:"config",ico:e.jsx(h,{size:20}),name:"Config",renderInLid:!0,funcao:a=>l(e.jsx(y,{}),{placement:"bottom"},a.target)},{id:"close",ico:e.jsx(j,{size:20}),name:"Close",renderInLid:!0,funcao:a=>t("children","close")}];return e.jsx("div",{className:s?"bg-[var(--background-default)]":"bg-[var(--panel-header-background)]",children:e.jsx("div",{className:"h-[64px] p-2 flex gap-2 items-center "+(o.cor_primaria?"fill-[var(--primaria)] text-[var(--primaria)]":"fill-[var(--panel-header-icon)] text-[var(--panel-header-icon)]"),children:p.map(a=>i&&i.id.server==="@lid"&&!i.accountLid&&!a.renderInLid?null:e.jsx("div",{onClick:a.funcao,className:a.id==="close"?"ml-auto":"",children:e.jsx("div",{className:"menu-item pulse cursor-pointer rounded-[10px] p-2 hover:!bg-[var(--primaria)] hover:!text-[var(--letra)] "+(r.children===a.id?"bg-[var(--primaria)] text-[var(--letra)]":`bg-[var(--menu-bar-item-background-active)] ${o.cor_primaria?"text-[var(--primaria)]":"text-[var(--panel-header-icon)]"}`),children:a.ico})},a.id))})})}const E=n.lazy(() => __vitePreload(()=>import(chrome.runtime.getURL("content/assets/js/v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b88.js")).then(r=>r.i),[])),N=n.lazy(() => __vitePreload(()=>import(chrome.runtime.getURL("content/assets/js/v_7_4_2_25_48461181-0d14-4d2a-b9c3-5de50369a90b89.js")).then(r=>r.i),[]));function Q(){const{menuContent:r}=m(),t=u(s=>s.activeChat?.id?.user),o={perfilContato:e.jsx(E,{}),respostasRapidas:e.jsx(N,{}),anotacoes:e.jsx(M,{userID:t,viwerModel:"res",id:"notes_quick_reply"})};n.useEffect(()=>{b.getState().getSeletor("menuLateral",s=>{s.insertAdjacentElement("afterend",c)})},[]);const l=e.jsx("div",{className:"relative z-[100] h-full bg-[var(--background-default)] border-[var(--conversation-header-border)] border-solid shadow-sm border-l",children:e.jsxs("div",{style:{width:`${r.width}px`},children:[e.jsx(I,{}),e.jsx("div",{className:"bg-[var(--background-default)]",style:{maxHeight:"calc(100vh - 120px)"},children:e.jsx(n.Suspense,{fallback:e.jsx(e.Fragment,{}),children:o[r.children]})})]})});return v.createPortal(l,c)}export{Q as default};
