1import{b1 as r,J as y,av as l,ai as d,K as c,M as b,b2 as u,Q as o,b3 as x}from"./index-B7Ng5BsD.js";function S(e,n){const a=n.status;return e<2&&![401,403,404,503].includes(a??0)}function f(e,n=!0){const a=r();return y({queryKey:u.channels(e,a),queryFn:()=>(x(a),o.getSocialInboxChannels(e)),enabled:!!a&&!!e&&n,retry:S,staleTime:15e3,...l(6e4)})}function C(e,n,a=!0){const t=r();return d({queryKey:u.conversations(e,n,t),initialPageParam:void 0,queryFn:({pageParam:s})=>(x(t),o.listSocialInboxConversations(e,{...n,limit:40,cursor:s})),getNextPageParam:s=>s.nextCursor??void 0,enabled:!!t&&!!e&&a,retry:S,staleTime:1e4,...l(15e3)})}function I(e,n){const a=r();return d({queryKey:u.conversation(e,n,a),initialPageParam:void 0,queryFn:({pageParam:t})=>(x(a),o.getSocialInboxConversation(e,n,t)),getNextPageParam:t=>t.nextMessagesCursor??void 0,enabled:!!a&&!!e&&!!n,retry:S,staleTime:5e3,...l(1e4)})}function i(e,n){const a=c();return b({mutationFn:n,onSettled:()=>{a.invalidateQueries({queryKey:u.all(e)})}})}function m(e){return i(e,n=>o.addSocialInboxChannel(e,n))}function g(e){return i(e,({id:n,...a})=>o.updateSocialInboxChannel(e,n,a))}function q(e){const n=c();return b({mutationFn:({id:a,cursor:t})=>o.syncSocialInboxChannel(e,a,t),onSettled:()=>{n.invalidateQueries({queryKey:u.all(e)})}})}function h(e,n){return i(e,a=>o.updateSocialInboxConversation(e,n,a))}function P(e,n){return i(e,()=>o.markSocialInboxRead(e,n))}function K(e,n){return i(e,a=>o.sendSocialInboxMessage(e,n,a))}function M(e,n){return i(e,a=>o.reviewSocialInboxDelivery(e,n,a))}function Q(e,n){return i(e,a=>o.addSocialInboxNote(e,n,a))}function F(e,n){const a=c();return b({mutationFn:t=>o.createSocialInboxLead(e,n,t),onSettled:()=>{a.invalidateQueries({queryKey:[e]})}})}function A(e,n){return i(e,a=>a.action==="send"?o.sendSocialInboxDraft(e,n,a.messageId,a.text):o.discardSocialInboxDraft(e,n,a.messageId))}export{g as a,q as b,h as c,Q as d,F as e,I as f,P as g,K as h,M as i,A as j,C as k,m as l,f as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.