@hiver/connector-agent 4.10.1-splitAppsNudge-beta.0 → 4.10.1-splitAppsNudge-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.es.js CHANGED
@@ -23860,7 +23860,7 @@ const TO = ({ observer: e, ...t }) => /* @__PURE__ */ u.jsx(su, { children: /* @
23860
23860
  n.setData(l, "connectorTabs");
23861
23861
  }, i = () => {
23862
23862
  const a = n.getData("connectors");
23863
- if (!Array.isArray(a) || !a.length) return r();
23863
+ if (!Array.isArray(a)) return r();
23864
23864
  typeof n.getData("sideBarTabs") == "number" && o();
23865
23865
  }, s = (a) => {
23866
23866
  if (!a) return;
@@ -23925,7 +23925,7 @@ const TO = ({ observer: e, ...t }) => /* @__PURE__ */ u.jsx(su, { children: /* @
23925
23925
  {
23926
23926
  open: !0,
23927
23927
  title: r,
23928
- placement: "left",
23928
+ placement: "left-start",
23929
23929
  disableFocusListener: !0,
23930
23930
  disableHoverListener: !0,
23931
23931
  disableTouchListener: !0,
@@ -23949,7 +23949,7 @@ const TO = ({ observer: e, ...t }) => /* @__PURE__ */ u.jsx(su, { children: /* @
23949
23949
  onClick: (o) => o.stopPropagation()
23950
23950
  },
23951
23951
  arrow: {
23952
- sx: { fontSize: "18px" }
23952
+ sx: { fontSize: "12px" }
23953
23953
  }
23954
23954
  },
23955
23955
  children: e
package/index.umd.js CHANGED
@@ -2964,7 +2964,7 @@ Do you want to continue?`,wv="Select an object to create",Iv="Select an object t
2964
2964
  line-height: 14px;
2965
2965
  color: #506dff;
2966
2966
  margin-left: 6px;
2967
- `,oL=[Te.PENDING,Te.LOGGED,Te.NOT_LOGGED,Te.PAUSED],sL=[Te.LOGGED,Te.PAUSED],aL=({status:e,emailLogStatus:t})=>{const{isAdmin:n,conversationId:r,connectorFunctions:o}=I.useContext(en),s=o==null?void 0:o.sendTrackingEvent,{refetch:a}=Xa({conversationId:r}),{mutate:i,isPending:c}=tL({onSuccess:a}),l=JS[e],f=$S[e],g=QS[e],{emailLogSettings:y,messageLogStatus:E}=t,{connectorName:m}=y??{},{logged:h,total:p}=E??{},b=sL.includes(e)&&p?` (${h}/${p})`:"",x=e===Te.ERROR,C=oL.includes(e),w=({close:_})=>d.jsx(KT,{close:_,emailLogStatus:t}),v=()=>{i({conversationId:r}),s==null||s(Nt.email_logging_failed_clicked,{app_name:m})};return d.jsx(jA,{logSettings:y,status:e,isAdmin:n,retry:x,renderEntities:C?w:void 0,children:d.jsxs(nL,{style:{cursor:C?"pointer":"not-allowed"},children:[l,g?g(`${f} ${b}`):null,x?d.jsx(rL,{variant:"text",disabled:c,onClick:v,children:"Retry"}):null]})})},Al=({emailLogStatus:e,containerElement:t,messageId:n,legacyMessageId:r})=>{if(!t)return null;const o=GS(e);return je.createPortal(d.jsx(aL,{status:o,emailLogStatus:e,messageId:n,legacyMessageId:r}),t)},iL=({observer:e})=>{var E;const[t,n]=I.useState({}),[r,o]=I.useState({}),[s,a]=I.useState({}),{conversationId:i}=I.useContext(en),{data:c}=Xa({conversationId:i}),l=(E=c==null?void 0:c.emailLogSettings)==null?void 0:E.enabled,f=m=>{n(h=>({...h,...m}))},g=m=>{o(h=>({...h,...m}))},y=m=>{a(m)};return I.useEffect(()=>{if(!(!e||!l))return e.observe({setEmailButtonContainers:f,setComposeButtonContainers:g,setSubjectButtonContainers:y}),()=>{e.destroy(),n({}),o({})}},[e,l]),c?d.jsxs(d.Fragment,{children:[Object.entries(t).map(([m,h])=>d.jsx(Al,{emailLogStatus:c,containerElement:h.element,messageId:h.messageId,legacyMessageId:h.legacyMessageId},m)),Object.entries(r).map(([m,h])=>d.jsx(Al,{emailLogStatus:c,containerElement:h.element},m)),Object.entries(s).map(([m,h])=>d.jsx(Al,{emailLogStatus:c,containerElement:h.element},m))]}):null},cL=({isAdmin:e,conversationId:t,connectorFunctions:n,children:r})=>{const o=I.useMemo(()=>({isAdmin:e,conversationId:t,connectorFunctions:n}),[e,t,n]);return d.jsx(en.Provider,{value:o,children:r})},lL=({children:e,...t})=>d.jsx(uc,{store:bl,children:d.jsx(u.HiverProvider,{inter:!0,children:d.jsx(ml,{children:d.jsx(I.Suspense,{fallback:d.jsx(d.Fragment,{}),children:d.jsx(cL,{...t,children:e})})})})}),za=".hiver-log-crm-button",Ya=".hiver-log-crm-compose-button",E2=".hiver-log-crm-subject-button";class uL{constructor({emailNodeFilter:t,composeNodeFilter:n,emailHeaderTargetSelector:r=".gE.iv.gt .c2",composeHeaderTargetSelector:o=".aoD.hl .bgW",emailMessageContainerSelector:s=".adn.ads",subjectContainer:a=null,disableAutoLogInEmail:i=!1,disableAutoLogInCompose:c=!1,disableAutoLogInSubject:l=!1}={}){Pe(this,"observer",null);Pe(this,"setComposeButtonContainers",null);Pe(this,"setEmailButtonContainers",null);Pe(this,"setSubjectButtonContainers",null);Pe(this,"emailNodeFilter");Pe(this,"composeNodeFilter");Pe(this,"emailHeaderTargetSelector");Pe(this,"composeHeaderTargetSelector");Pe(this,"emailMessageContainerSelector");Pe(this,"disableAutoLogInEmail");Pe(this,"disableAutoLogInCompose");Pe(this,"disableAutoLogInSubject");Pe(this,"subjectContainer",null);Pe(this,"_addLogButtonsOnEmail",()=>{if(this.disableAutoLogInEmail)return;document.querySelectorAll(za).forEach(r=>r.remove());const n=document.querySelectorAll(this.emailMessageContainerSelector);n.length&&n.forEach(r=>{var c;const o=r.querySelector(this.emailHeaderTargetSelector),s=r.getAttribute("data-message-id")||null,a=r.getAttribute("data-legacy-message-id")||null;if(o!=null&&o.querySelector(za))return;const i=document.createElement("div");i.classList.add(za.slice(1)),i.style.display="inline-block",i.style.marginLeft="8px",o==null||o.appendChild(i),(c=this.setEmailButtonContainers)==null||c.call(this,{[s??""]:{element:i,messageId:s,legacyMessageId:a}})})});Pe(this,"_addLogButtonsOnCompose",()=>{if(this.disableAutoLogInCompose)return;document.querySelectorAll(Ya).forEach(r=>r.remove());const n=document.querySelectorAll(this.composeHeaderTargetSelector);n.length&&n.forEach((r,o)=>{var a;if(r.querySelector(Ya))return;const s=document.createElement("div");s.classList.add(Ya.slice(1)),s.style.display="inline-block",r.appendChild(s),(a=this.setComposeButtonContainers)==null||a.call(this,{["_compose_"+o]:{element:s}})})});Pe(this,"_addLogButtonOnSubject",()=>{var r,o,s;if(this.disableAutoLogInSubject||!this.subjectContainer)return;const t=(r=this.subjectContainer)==null?void 0:r.querySelectorAll(E2);t==null||t.forEach(a=>a.remove());const n=document.createElement("div");n.classList.add(E2.slice(1)),n.style.display="inline-block",(o=this.subjectContainer)==null||o.appendChild(n),(s=this.setSubjectButtonContainers)==null||s.call(this,{crm_subject:{element:n}})});this.emailNodeFilter=t||this._defaultEmailNodeFilter,this.composeNodeFilter=n||this._defaultComposeNodeFilter,this.emailHeaderTargetSelector=r,this.composeHeaderTargetSelector=o,this.emailMessageContainerSelector=s,this.subjectContainer=a,this.disableAutoLogInEmail=i,this.disableAutoLogInCompose=c,this.disableAutoLogInSubject=l}_defaultEmailNodeFilter(t){var n,r;return!!(t.nodeType===1&&t instanceof Element&&((n=t.classList)!=null&&n.contains("a3s")||(r=t.classList)!=null&&r.contains("ii")||typeof t.querySelector=="function"&&t.querySelector(".a3s")))}_defaultComposeNodeFilter(t){var n,r;return!!(t.nodeType===1&&t instanceof Element&&((n=t.classList)!=null&&n.contains("hiver-new-email-top-div")||(r=t.classList)!=null&&r.contains("hiver-compose-bar")))}_initMutationObserver(){this.observer&&this.observer.disconnect(),this.observer=new MutationObserver(t=>{let n=!1,r=!1;t.forEach(o=>{if(o.type==="childList"){const s=Array.from(o.addedNodes);this.disableAutoLogInEmail||s.some(this.emailNodeFilter)&&(n=!0),this.disableAutoLogInCompose||s.some(this.composeNodeFilter)&&(r=!0)}}),n&&setTimeout(()=>this._addLogButtonsOnEmail(),100),r&&setTimeout(()=>this._addLogButtonsOnCompose(),100)}),this.observer.observe(document.body,{childList:!0,subtree:!0})}_init(){this._addLogButtonsOnEmail(),this._addLogButtonsOnCompose(),this._addLogButtonOnSubject()}observe({setComposeButtonContainers:t,setEmailButtonContainers:n,setSubjectButtonContainers:r}){this.setComposeButtonContainers=t,this.setEmailButtonContainers=n,this.setSubjectButtonContainers=r,this._init(),(!this.disableAutoLogInEmail||!this.disableAutoLogInCompose)&&this._initMutationObserver()}destroy(){document.querySelectorAll(za).forEach(r=>r.remove()),document.querySelectorAll(Ya).forEach(r=>r.remove()),this.observer&&(this.observer.disconnect(),this.observer=null)}}const dL=({observer:e,...t})=>d.jsx(yl,{children:d.jsxs(lL,{...t,children:[d.jsx(iL,{observer:e}),je.createPortal(d.jsx(xl,{id:"toast-message",children:d.jsx(ti,{position:"bottom-left",autoClose:5e3,hideProgressBar:!0,newestOnTop:!1,closeOnClick:!0,rtl:!1,draggable:!0,pauseOnHover:!0})}),document.body)]})}),fL=e=>ve({url:JE,method:De.POST,data:e}),pL=(...e)=>{},hL=e=>{const t=new AbortController,n=async(r=0)=>{try{pL("getConnectorsList",r);const o=await $0(e);if(t.signal.aborted)throw new Error("Fetch aborted");return o}catch(o){if(t.signal.aborted)throw new Error("Fetch aborted");return r>2?(console.error("Failed to get connectors list after 3 tries",o),[]):n(r+1)}};return{fetchConnectors:n,abort:t.abort.bind(t)}},gL=()=>{const e={connectorApiPending:!1,connectorApiAbort:null};if(!Pt())throw new Error("Please initiate bifrost by calling initConnectorsBifrost function before creating app store");const n=A6({name:"app-store",initialState:{}}),r=()=>{const i=n.getData("inboxIds");if(!Array.isArray(i)||!i.length)return;e.connectorApiAbort&&e.connectorApiAbort(),e.connectorApiPending=!0;const c={all:"true",inbox_id:i},{fetchConnectors:l,abort:f}=hL(c);e.connectorApiAbort=f,l().then(g=>{Array.isArray(g)&&n.setData(g,"connectors")}).catch(g=>{console.warn("Failed to fetch connectors",g)}).finally(()=>{e.connectorApiPending=!1})},o=i=>{(!Array.isArray(i)||!i.length)&&(i=n.getData("connectors")||[]);const c=n.getData("sideBarTabs")||0,l=[...i].sort((f,g)=>{const y=f.lastAccessed??0,E=g.lastAccessed??0;return y===E?0:y>E?-1:1}).map((f,g)=>({...f,sidebarView:g<c}));n.setData(l,"connectorTabs")},s=()=>{const i=n.getData("connectors");if(!Array.isArray(i)||!i.length)return r();typeof n.getData("sideBarTabs")=="number"&&o()},a=i=>{if(!i)return;const c=n.getData("connectorTabs"),l=c==null?void 0:c.find(g=>g.id===i);if(!l||l.sidebarView)return;const f=new Date().getTime();l.lastAccessed=f,o(c)};return n.subscribe(s,"connectors"),n.subscribe(()=>o(),"sideBarTabs",!1),n.subscribe(a,"connectorId",!1),n.subscribe(r,"inboxIds",!1),n},mL=({children:e})=>d.jsx(u.HiverProvider,{inter:!0,children:e}),bL=u.styled(({className:e,...t})=>d.jsx(u.Tooltip,{...t,classes:{popper:e}}))(()=>({[`& .${u.tooltipClasses.tooltip}`]:{backgroundColor:"#fff",padding:0,width:"min-content",borderRadius:"12px",maxWidth:"90vh",boxShadow:"0px 3px 15px 0px #00000040",color:"#000"},[`& .${u.tooltipClasses.arrow}`]:{color:"#fff !important"}})),yL=u.styled(u.Stack)`
2967
+ `,oL=[Te.PENDING,Te.LOGGED,Te.NOT_LOGGED,Te.PAUSED],sL=[Te.LOGGED,Te.PAUSED],aL=({status:e,emailLogStatus:t})=>{const{isAdmin:n,conversationId:r,connectorFunctions:o}=I.useContext(en),s=o==null?void 0:o.sendTrackingEvent,{refetch:a}=Xa({conversationId:r}),{mutate:i,isPending:c}=tL({onSuccess:a}),l=JS[e],f=$S[e],g=QS[e],{emailLogSettings:y,messageLogStatus:E}=t,{connectorName:m}=y??{},{logged:h,total:p}=E??{},b=sL.includes(e)&&p?` (${h}/${p})`:"",x=e===Te.ERROR,C=oL.includes(e),w=({close:_})=>d.jsx(KT,{close:_,emailLogStatus:t}),v=()=>{i({conversationId:r}),s==null||s(Nt.email_logging_failed_clicked,{app_name:m})};return d.jsx(jA,{logSettings:y,status:e,isAdmin:n,retry:x,renderEntities:C?w:void 0,children:d.jsxs(nL,{style:{cursor:C?"pointer":"not-allowed"},children:[l,g?g(`${f} ${b}`):null,x?d.jsx(rL,{variant:"text",disabled:c,onClick:v,children:"Retry"}):null]})})},Al=({emailLogStatus:e,containerElement:t,messageId:n,legacyMessageId:r})=>{if(!t)return null;const o=GS(e);return je.createPortal(d.jsx(aL,{status:o,emailLogStatus:e,messageId:n,legacyMessageId:r}),t)},iL=({observer:e})=>{var E;const[t,n]=I.useState({}),[r,o]=I.useState({}),[s,a]=I.useState({}),{conversationId:i}=I.useContext(en),{data:c}=Xa({conversationId:i}),l=(E=c==null?void 0:c.emailLogSettings)==null?void 0:E.enabled,f=m=>{n(h=>({...h,...m}))},g=m=>{o(h=>({...h,...m}))},y=m=>{a(m)};return I.useEffect(()=>{if(!(!e||!l))return e.observe({setEmailButtonContainers:f,setComposeButtonContainers:g,setSubjectButtonContainers:y}),()=>{e.destroy(),n({}),o({})}},[e,l]),c?d.jsxs(d.Fragment,{children:[Object.entries(t).map(([m,h])=>d.jsx(Al,{emailLogStatus:c,containerElement:h.element,messageId:h.messageId,legacyMessageId:h.legacyMessageId},m)),Object.entries(r).map(([m,h])=>d.jsx(Al,{emailLogStatus:c,containerElement:h.element},m)),Object.entries(s).map(([m,h])=>d.jsx(Al,{emailLogStatus:c,containerElement:h.element},m))]}):null},cL=({isAdmin:e,conversationId:t,connectorFunctions:n,children:r})=>{const o=I.useMemo(()=>({isAdmin:e,conversationId:t,connectorFunctions:n}),[e,t,n]);return d.jsx(en.Provider,{value:o,children:r})},lL=({children:e,...t})=>d.jsx(uc,{store:bl,children:d.jsx(u.HiverProvider,{inter:!0,children:d.jsx(ml,{children:d.jsx(I.Suspense,{fallback:d.jsx(d.Fragment,{}),children:d.jsx(cL,{...t,children:e})})})})}),za=".hiver-log-crm-button",Ya=".hiver-log-crm-compose-button",E2=".hiver-log-crm-subject-button";class uL{constructor({emailNodeFilter:t,composeNodeFilter:n,emailHeaderTargetSelector:r=".gE.iv.gt .c2",composeHeaderTargetSelector:o=".aoD.hl .bgW",emailMessageContainerSelector:s=".adn.ads",subjectContainer:a=null,disableAutoLogInEmail:i=!1,disableAutoLogInCompose:c=!1,disableAutoLogInSubject:l=!1}={}){Pe(this,"observer",null);Pe(this,"setComposeButtonContainers",null);Pe(this,"setEmailButtonContainers",null);Pe(this,"setSubjectButtonContainers",null);Pe(this,"emailNodeFilter");Pe(this,"composeNodeFilter");Pe(this,"emailHeaderTargetSelector");Pe(this,"composeHeaderTargetSelector");Pe(this,"emailMessageContainerSelector");Pe(this,"disableAutoLogInEmail");Pe(this,"disableAutoLogInCompose");Pe(this,"disableAutoLogInSubject");Pe(this,"subjectContainer",null);Pe(this,"_addLogButtonsOnEmail",()=>{if(this.disableAutoLogInEmail)return;document.querySelectorAll(za).forEach(r=>r.remove());const n=document.querySelectorAll(this.emailMessageContainerSelector);n.length&&n.forEach(r=>{var c;const o=r.querySelector(this.emailHeaderTargetSelector),s=r.getAttribute("data-message-id")||null,a=r.getAttribute("data-legacy-message-id")||null;if(o!=null&&o.querySelector(za))return;const i=document.createElement("div");i.classList.add(za.slice(1)),i.style.display="inline-block",i.style.marginLeft="8px",o==null||o.appendChild(i),(c=this.setEmailButtonContainers)==null||c.call(this,{[s??""]:{element:i,messageId:s,legacyMessageId:a}})})});Pe(this,"_addLogButtonsOnCompose",()=>{if(this.disableAutoLogInCompose)return;document.querySelectorAll(Ya).forEach(r=>r.remove());const n=document.querySelectorAll(this.composeHeaderTargetSelector);n.length&&n.forEach((r,o)=>{var a;if(r.querySelector(Ya))return;const s=document.createElement("div");s.classList.add(Ya.slice(1)),s.style.display="inline-block",r.appendChild(s),(a=this.setComposeButtonContainers)==null||a.call(this,{["_compose_"+o]:{element:s}})})});Pe(this,"_addLogButtonOnSubject",()=>{var r,o,s;if(this.disableAutoLogInSubject||!this.subjectContainer)return;const t=(r=this.subjectContainer)==null?void 0:r.querySelectorAll(E2);t==null||t.forEach(a=>a.remove());const n=document.createElement("div");n.classList.add(E2.slice(1)),n.style.display="inline-block",(o=this.subjectContainer)==null||o.appendChild(n),(s=this.setSubjectButtonContainers)==null||s.call(this,{crm_subject:{element:n}})});this.emailNodeFilter=t||this._defaultEmailNodeFilter,this.composeNodeFilter=n||this._defaultComposeNodeFilter,this.emailHeaderTargetSelector=r,this.composeHeaderTargetSelector=o,this.emailMessageContainerSelector=s,this.subjectContainer=a,this.disableAutoLogInEmail=i,this.disableAutoLogInCompose=c,this.disableAutoLogInSubject=l}_defaultEmailNodeFilter(t){var n,r;return!!(t.nodeType===1&&t instanceof Element&&((n=t.classList)!=null&&n.contains("a3s")||(r=t.classList)!=null&&r.contains("ii")||typeof t.querySelector=="function"&&t.querySelector(".a3s")))}_defaultComposeNodeFilter(t){var n,r;return!!(t.nodeType===1&&t instanceof Element&&((n=t.classList)!=null&&n.contains("hiver-new-email-top-div")||(r=t.classList)!=null&&r.contains("hiver-compose-bar")))}_initMutationObserver(){this.observer&&this.observer.disconnect(),this.observer=new MutationObserver(t=>{let n=!1,r=!1;t.forEach(o=>{if(o.type==="childList"){const s=Array.from(o.addedNodes);this.disableAutoLogInEmail||s.some(this.emailNodeFilter)&&(n=!0),this.disableAutoLogInCompose||s.some(this.composeNodeFilter)&&(r=!0)}}),n&&setTimeout(()=>this._addLogButtonsOnEmail(),100),r&&setTimeout(()=>this._addLogButtonsOnCompose(),100)}),this.observer.observe(document.body,{childList:!0,subtree:!0})}_init(){this._addLogButtonsOnEmail(),this._addLogButtonsOnCompose(),this._addLogButtonOnSubject()}observe({setComposeButtonContainers:t,setEmailButtonContainers:n,setSubjectButtonContainers:r}){this.setComposeButtonContainers=t,this.setEmailButtonContainers=n,this.setSubjectButtonContainers=r,this._init(),(!this.disableAutoLogInEmail||!this.disableAutoLogInCompose)&&this._initMutationObserver()}destroy(){document.querySelectorAll(za).forEach(r=>r.remove()),document.querySelectorAll(Ya).forEach(r=>r.remove()),this.observer&&(this.observer.disconnect(),this.observer=null)}}const dL=({observer:e,...t})=>d.jsx(yl,{children:d.jsxs(lL,{...t,children:[d.jsx(iL,{observer:e}),je.createPortal(d.jsx(xl,{id:"toast-message",children:d.jsx(ti,{position:"bottom-left",autoClose:5e3,hideProgressBar:!0,newestOnTop:!1,closeOnClick:!0,rtl:!1,draggable:!0,pauseOnHover:!0})}),document.body)]})}),fL=e=>ve({url:JE,method:De.POST,data:e}),pL=(...e)=>{},hL=e=>{const t=new AbortController,n=async(r=0)=>{try{pL("getConnectorsList",r);const o=await $0(e);if(t.signal.aborted)throw new Error("Fetch aborted");return o}catch(o){if(t.signal.aborted)throw new Error("Fetch aborted");return r>2?(console.error("Failed to get connectors list after 3 tries",o),[]):n(r+1)}};return{fetchConnectors:n,abort:t.abort.bind(t)}},gL=()=>{const e={connectorApiPending:!1,connectorApiAbort:null};if(!Pt())throw new Error("Please initiate bifrost by calling initConnectorsBifrost function before creating app store");const n=A6({name:"app-store",initialState:{}}),r=()=>{const i=n.getData("inboxIds");if(!Array.isArray(i)||!i.length)return;e.connectorApiAbort&&e.connectorApiAbort(),e.connectorApiPending=!0;const c={all:"true",inbox_id:i},{fetchConnectors:l,abort:f}=hL(c);e.connectorApiAbort=f,l().then(g=>{Array.isArray(g)&&n.setData(g,"connectors")}).catch(g=>{console.warn("Failed to fetch connectors",g)}).finally(()=>{e.connectorApiPending=!1})},o=i=>{(!Array.isArray(i)||!i.length)&&(i=n.getData("connectors")||[]);const c=n.getData("sideBarTabs")||0,l=[...i].sort((f,g)=>{const y=f.lastAccessed??0,E=g.lastAccessed??0;return y===E?0:y>E?-1:1}).map((f,g)=>({...f,sidebarView:g<c}));n.setData(l,"connectorTabs")},s=()=>{const i=n.getData("connectors");if(!Array.isArray(i))return r();typeof n.getData("sideBarTabs")=="number"&&o()},a=i=>{if(!i)return;const c=n.getData("connectorTabs"),l=c==null?void 0:c.find(g=>g.id===i);if(!l||l.sidebarView)return;const f=new Date().getTime();l.lastAccessed=f,o(c)};return n.subscribe(s,"connectors"),n.subscribe(()=>o(),"sideBarTabs",!1),n.subscribe(a,"connectorId",!1),n.subscribe(r,"inboxIds",!1),n},mL=({children:e})=>d.jsx(u.HiverProvider,{inter:!0,children:e}),bL=u.styled(({className:e,...t})=>d.jsx(u.Tooltip,{...t,classes:{popper:e}}))(()=>({[`& .${u.tooltipClasses.tooltip}`]:{backgroundColor:"#fff",padding:0,width:"min-content",borderRadius:"12px",maxWidth:"90vh",boxShadow:"0px 3px 15px 0px #00000040",color:"#000"},[`& .${u.tooltipClasses.arrow}`]:{color:"#fff !important"}})),yL=u.styled(u.Stack)`
2968
2968
  box-sizing: content-box !important;
2969
2969
  display: flex;
2970
2970
  flex-direction: column;
@@ -2995,4 +2995,4 @@ Do you want to continue?`,wv="Select an object to create",Iv="Select an object t
2995
2995
  letter-spacing: 0.4px;
2996
2996
  line-height: 20px;
2997
2997
  margin-top: 14px;
2998
- `,vL=({children:e,zIndex:t,onClose:n})=>{const r=d.jsxs(yL,{children:[d.jsx(xL,{variant:"h2",color:"text.primary",children:"Split apps view"}),d.jsx(CL,{variant:"body2",color:"text.secondary",children:"Each connected app now has its own tab, making it easier to view app-specific data"}),d.jsx(EL,{variant:"contained",color:"primary",onClick:n,children:"Dismiss"})]});return d.jsx(bL,{open:!0,title:r,placement:"left",disableFocusListener:!0,disableHoverListener:!0,disableTouchListener:!0,arrow:!0,slotProps:{popper:{sx:{zIndex:t+1},modifiers:[{name:"flip",enabled:!0},{name:"preventOverflow",enabled:!0}]},tooltip:{sx:{pointerEvents:"auto",maxWidth:"min(360px, calc(60vw - 24px))",padding:"12px"},onClick:o=>o.stopPropagation()},arrow:{sx:{fontSize:"18px"}}},children:e})},v2=Yo("LOCAL"),wL="connector-library-split-apps-nudge",IL=({open:e,targetRef:t,endElRef:n,zIndex:r,storageKey:o=wL,onClose:s})=>{const[a,i]=I.useState(()=>v2.getItem(o)==="true"),c=()=>{v2.setItem(o,"true"),i(!0),s()},l=f=>d.jsx(vL,{zIndex:r,onClose:c,children:f});return a?null:d.jsx(BE,{open:e,targetRef:t,endElRef:n,padding:8,zIndex:r,renderHighlight:l})},_L=e=>d.jsx(mL,{children:d.jsx(IL,{...e})});ce.ActionQueue=BS,ce.CONNECTORS_AGENT_EVENTS=gl,ce.ConnectorCardList=q_,ce.EmailLogger=dL,ce.GmailLogObserver=uL,ce.HiverConnectorBifrostAuth=ve,ce.IntegrationSense=PS,ce.SplitAppsNudge=_L,ce.addNewConnectors=Yh,ce.createAppStore=gL,ce.dismissNotification=wu,ce.fetchAppCfValues=fL,ce.getConnectorsBifrostConfigs=Pt,ce.getMetaData=h6,ce.initConnectorsBifrost=x3,ce.setCaptureFeedbackOnDemand=Jh,ce.shouldCaptureFeedback=wi,ce.shouldShowNotification=vu,ce.useConnectorSelectedEmail=T_,Object.defineProperty(ce,Symbol.toStringTag,{value:"Module"})});
2998
+ `,vL=({children:e,zIndex:t,onClose:n})=>{const r=d.jsxs(yL,{children:[d.jsx(xL,{variant:"h2",color:"text.primary",children:"Split apps view"}),d.jsx(CL,{variant:"body2",color:"text.secondary",children:"Each connected app now has its own tab, making it easier to view app-specific data"}),d.jsx(EL,{variant:"contained",color:"primary",onClick:n,children:"Dismiss"})]});return d.jsx(bL,{open:!0,title:r,placement:"left-start",disableFocusListener:!0,disableHoverListener:!0,disableTouchListener:!0,arrow:!0,slotProps:{popper:{sx:{zIndex:t+1},modifiers:[{name:"flip",enabled:!0},{name:"preventOverflow",enabled:!0}]},tooltip:{sx:{pointerEvents:"auto",maxWidth:"min(360px, calc(60vw - 24px))",padding:"12px"},onClick:o=>o.stopPropagation()},arrow:{sx:{fontSize:"12px"}}},children:e})},v2=Yo("LOCAL"),wL="connector-library-split-apps-nudge",IL=({open:e,targetRef:t,endElRef:n,zIndex:r,storageKey:o=wL,onClose:s})=>{const[a,i]=I.useState(()=>v2.getItem(o)==="true"),c=()=>{v2.setItem(o,"true"),i(!0),s()},l=f=>d.jsx(vL,{zIndex:r,onClose:c,children:f});return a?null:d.jsx(BE,{open:e,targetRef:t,endElRef:n,padding:8,zIndex:r,renderHighlight:l})},_L=e=>d.jsx(mL,{children:d.jsx(IL,{...e})});ce.ActionQueue=BS,ce.CONNECTORS_AGENT_EVENTS=gl,ce.ConnectorCardList=q_,ce.EmailLogger=dL,ce.GmailLogObserver=uL,ce.HiverConnectorBifrostAuth=ve,ce.IntegrationSense=PS,ce.SplitAppsNudge=_L,ce.addNewConnectors=Yh,ce.createAppStore=gL,ce.dismissNotification=wu,ce.fetchAppCfValues=fL,ce.getConnectorsBifrostConfigs=Pt,ce.getMetaData=h6,ce.initConnectorsBifrost=x3,ce.setCaptureFeedbackOnDemand=Jh,ce.shouldCaptureFeedback=wi,ce.shouldShowNotification=vu,ce.useConnectorSelectedEmail=T_,Object.defineProperty(ce,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hiver/connector-agent",
3
- "version": "4.10.1-splitAppsNudge-beta.0",
3
+ "version": "4.10.1-splitAppsNudge-beta.1",
4
4
  "main": "index.es.js",
5
5
  "module": "index.es.js",
6
6
  "types": "index.d.ts",