@hiver/connector-agent 4.6.1-cfApps-beta.16 → 4.6.1-cfApps-beta.17

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.
@@ -1 +1 @@
1
- {"version":3,"file":"email-selection.d.ts","sourceRoot":"","sources":["../../../../../src/features/connector-cards/components/card-list/email-selection.tsx"],"names":[],"mappings":"AAwBA,UAAU,MAAM;IACd,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,IAAI,EAAE,cAAc,GAAG,IAAI,CAAC;IAC5B,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACtC,gBAAgB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,SAAS,EAAE,OAAO,CAAC;CACpB;AA4HD,eAAO,MAAM,cAAc,uEAAwE,MAAM,4CAmDxG,CAAC"}
1
+ {"version":3,"file":"email-selection.d.ts","sourceRoot":"","sources":["../../../../../src/features/connector-cards/components/card-list/email-selection.tsx"],"names":[],"mappings":"AAwBA,UAAU,MAAM;IACd,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,IAAI,EAAE,cAAc,GAAG,IAAI,CAAC;IAC5B,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACtC,gBAAgB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,SAAS,EAAE,OAAO,CAAC;CACpB;AA2HD,eAAO,MAAM,cAAc,uEAAwE,MAAM,4CAuDxG,CAAC"}
package/index.es.js CHANGED
@@ -14,9 +14,9 @@ var Ii = (e, t, n, r) => ({
14
14
  }
15
15
  });
16
16
  import * as A from "react";
17
- import xe, { useState as U, useRef as ye, useSyncExternalStore as _0, useLayoutEffect as ho, useEffect as fe, isValidElement as Gr, cloneElement as Ua, createContext as Yc, useContext as Fe, useCallback as we, forwardRef as Ts, useMemo as _e, Component as Dh, Fragment as Xa, useReducer as Nh, memo as A0, Suspense as Jc } from "react";
17
+ import Ee, { useState as U, useRef as ye, useSyncExternalStore as _0, useLayoutEffect as ho, useEffect as fe, isValidElement as Gr, cloneElement as Ua, createContext as Yc, useContext as Fe, useCallback as we, forwardRef as Ts, useMemo as _e, Component as Dh, Fragment as Xa, useReducer as Nh, memo as A0, Suspense as Jc } from "react";
18
18
  import kh, { createPortal as po } from "react-dom";
19
- import { keyframes as qc, styled as O, Stack as V, theme as Z, IconButton as ct, Typography as ee, Box as oe, Tooltip as Ee, Button as Ze, icons as yt, Menu as Mh, MenuItem as T0, ListItemIcon as Ph, brandIcons as S0, Grid as jh, Link as li, Skeleton as Qc, TableHead as Bh, TableCell as Ss, TableRow as L0, palette as Vh, Icon as O0, DatePicker as Gh, DateTextField as Hh, InputAdornment as Wh, Checkbox as R0, TextField as Zh, tooltipClasses as Uo, TableContainer as Uh, Table as Xh, TableBody as $h, Dialog as zh, Paper as Yh, Select as Jh, HiverProvider as Kc, CircularProgress as F0, FormControl as D0, RadioGroup as N0, FormControlLabel as k0, Radio as M0, ClickAwayListener as qh, OutlinedInput as Qh, Switch as Kh } from "@hiver/hiver-ui-kit";
19
+ import { keyframes as qc, styled as O, Stack as V, theme as Z, IconButton as ct, Typography as ee, Box as oe, Tooltip as xe, Button as Ze, icons as yt, Menu as Mh, MenuItem as T0, ListItemIcon as Ph, brandIcons as S0, Grid as jh, Link as li, Skeleton as Qc, TableHead as Bh, TableCell as Ss, TableRow as L0, palette as Vh, Icon as O0, DatePicker as Gh, DateTextField as Hh, InputAdornment as Wh, Checkbox as R0, TextField as Zh, tooltipClasses as Uo, TableContainer as Uh, Table as Xh, TableBody as $h, Dialog as zh, Paper as Yh, Select as Jh, HiverProvider as Kc, CircularProgress as F0, FormControl as D0, RadioGroup as N0, FormControlLabel as k0, Radio as M0, ClickAwayListener as qh, OutlinedInput as Qh, Switch as Kh } from "@hiver/hiver-ui-kit";
20
20
  var me = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, $a = { exports: {} }, So = {};
21
21
  /**
22
22
  * @license React
@@ -31,7 +31,7 @@ var $l;
31
31
  function ep() {
32
32
  if ($l) return So;
33
33
  $l = 1;
34
- var e = xe, t = Symbol.for("react.element"), n = Symbol.for("react.fragment"), r = Object.prototype.hasOwnProperty, o = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, i = { key: !0, ref: !0, __self: !0, __source: !0 };
34
+ var e = Ee, t = Symbol.for("react.element"), n = Symbol.for("react.fragment"), r = Object.prototype.hasOwnProperty, o = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, i = { key: !0, ref: !0, __self: !0, __source: !0 };
35
35
  function s(a, c, l) {
36
36
  var d, p = {}, b = null, C = null;
37
37
  l !== void 0 && (b = "" + l), c.key !== void 0 && (b = "" + c.key), c.ref !== void 0 && (C = c.ref);
@@ -54,7 +54,7 @@ var Lo = {};
54
54
  var zl;
55
55
  function tp() {
56
56
  return zl || (zl = 1, process.env.NODE_ENV !== "production" && function() {
57
- var e = xe, t = Symbol.for("react.element"), n = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), o = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), s = Symbol.for("react.provider"), a = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), l = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), p = Symbol.for("react.memo"), b = Symbol.for("react.lazy"), C = Symbol.for("react.offscreen"), m = Symbol.iterator, f = "@@iterator";
57
+ var e = Ee, t = Symbol.for("react.element"), n = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), o = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), s = Symbol.for("react.provider"), a = Symbol.for("react.context"), c = Symbol.for("react.forward_ref"), l = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), p = Symbol.for("react.memo"), b = Symbol.for("react.lazy"), C = Symbol.for("react.offscreen"), m = Symbol.iterator, f = "@@iterator";
58
58
  function h(S) {
59
59
  if (S === null || typeof S != "object")
60
60
  return null;
@@ -685,7 +685,7 @@ function Ls(e) {
685
685
  g.removeEventListener("animationend", y), o ? np(g, d, i) : d();
686
686
  };
687
687
  b || (l ? y() : (h.current = 1, g.className += ` ${f}`, g.addEventListener("animationend", y)));
688
- }, [b]), xe.createElement(xe.Fragment, null, a);
688
+ }, [b]), Ee.createElement(Ee.Fragment, null, a);
689
689
  };
690
690
  }
691
691
  function Yl(e, t) {
@@ -834,7 +834,7 @@ function sp(e) {
834
834
  const f = Yn("Toastify__progress-bar", c ? "Toastify__progress-bar--controlled" : "Toastify__progress-bar--animated", `Toastify__progress-bar-theme--${b}`, `Toastify__progress-bar--${o}`, { "Toastify__progress-bar--rtl": d }), h = kt(s) ? s({ rtl: d, type: o, defaultClassName: f }) : Yn(f, s), g = { [c && l >= 1 ? "onTransitionEnd" : "onAnimationEnd"]: c && l < 1 ? null : () => {
835
835
  p && r();
836
836
  } };
837
- return xe.createElement("div", { className: "Toastify__progress-bar--wrp", "data-hidden": C }, xe.createElement("div", { className: `Toastify__progress-bar--bg Toastify__progress-bar-theme--${b} Toastify__progress-bar--${o}` }), xe.createElement("div", { role: "progressbar", "aria-hidden": C ? "true" : "false", "aria-label": "notification timer", className: h, style: m, ...g }));
837
+ return Ee.createElement("div", { className: "Toastify__progress-bar--wrp", "data-hidden": C }, Ee.createElement("div", { className: `Toastify__progress-bar--bg Toastify__progress-bar-theme--${b} Toastify__progress-bar--${o}` }), Ee.createElement("div", { role: "progressbar", "aria-hidden": C ? "true" : "false", "aria-label": "notification timer", className: h, style: m, ...g }));
838
838
  }
839
839
  let ap = 1;
840
840
  const G0 = () => "" + ap++;
@@ -903,17 +903,17 @@ Ve.loading = (e, t) => Go(e, os("default", { isLoading: !0, autoClose: !1, close
903
903
  }, Ve.play = (e) => Jl(!0, e), Ve.pause = (e) => Jl(!1, e);
904
904
  const lp = typeof window < "u" ? ho : fe, _i = (e) => {
905
905
  let { theme: t, type: n, isLoading: r, ...o } = e;
906
- return xe.createElement("svg", { viewBox: "0 0 24 24", width: "100%", height: "100%", fill: t === "colored" ? "currentColor" : `var(--toastify-icon-color-${n})`, ...o });
906
+ return Ee.createElement("svg", { viewBox: "0 0 24 24", width: "100%", height: "100%", fill: t === "colored" ? "currentColor" : `var(--toastify-icon-color-${n})`, ...o });
907
907
  }, da = { info: function(e) {
908
- return xe.createElement(_i, { ...e }, xe.createElement("path", { d: "M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z" }));
908
+ return Ee.createElement(_i, { ...e }, Ee.createElement("path", { d: "M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z" }));
909
909
  }, warning: function(e) {
910
- return xe.createElement(_i, { ...e }, xe.createElement("path", { d: "M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z" }));
910
+ return Ee.createElement(_i, { ...e }, Ee.createElement("path", { d: "M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z" }));
911
911
  }, success: function(e) {
912
- return xe.createElement(_i, { ...e }, xe.createElement("path", { d: "M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z" }));
912
+ return Ee.createElement(_i, { ...e }, Ee.createElement("path", { d: "M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z" }));
913
913
  }, error: function(e) {
914
- return xe.createElement(_i, { ...e }, xe.createElement("path", { d: "M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z" }));
914
+ return Ee.createElement(_i, { ...e }, Ee.createElement("path", { d: "M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z" }));
915
915
  }, spinner: function() {
916
- return xe.createElement("div", { className: "Toastify__spinner" });
916
+ return Ee.createElement("div", { className: "Toastify__spinner" });
917
917
  } }, up = (e) => {
918
918
  const { isRunning: t, preventExitTransition: n, toastRef: r, eventHandlers: o, playToast: i } = ip(e), { closeButton: s, children: a, autoClose: c, onClick: l, type: d, hideProgressBar: p, closeToast: b, transition: C, position: m, className: f, style: h, bodyClassName: g, bodyStyle: y, progressClassName: v, progressStyle: E, updateId: x, role: I, progress: _, rtl: w, toastId: T, deleteToast: D, isIn: R, isLoading: F, closeOnClick: M, theme: G } = e, Y = Yn("Toastify__toast", `Toastify__toast-theme--${G}`, `Toastify__toast--${d}`, { "Toastify__toast--rtl": w }, { "Toastify__toast--close-on-click": M }), Q = kt(f) ? f({ rtl: w, position: m, type: d, defaultClassName: Y }) : Yn(Y, f), K = function(ue) {
919
919
  let { theme: B, type: N, isLoading: H, icon: W } = ue, J = null;
@@ -923,10 +923,10 @@ const lp = typeof window < "u" ? ho : fe, _i = (e) => {
923
923
  let ce = null;
924
924
  return s === !1 || (ce = kt(s) ? s(q) : Gr(s) ? Ua(s, q) : function(ue) {
925
925
  let { closeToast: B, theme: N, ariaLabel: H = "close" } = ue;
926
- return xe.createElement("button", { className: `Toastify__close-button Toastify__close-button--${N}`, type: "button", onClick: (W) => {
926
+ return Ee.createElement("button", { className: `Toastify__close-button Toastify__close-button--${N}`, type: "button", onClick: (W) => {
927
927
  W.stopPropagation(), B(W);
928
- }, "aria-label": H }, xe.createElement("svg", { "aria-hidden": "true", viewBox: "0 0 14 16" }, xe.createElement("path", { fillRule: "evenodd", d: "M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z" })));
929
- }(q)), xe.createElement(C, { isIn: R, done: D, position: m, preventExitTransition: n, nodeRef: r, playToast: i }, xe.createElement("div", { id: T, onClick: l, "data-in": R, className: Q, ...o, style: h, ref: r }, xe.createElement("div", { ...R && { role: I }, className: kt(g) ? g({ type: d }) : Yn("Toastify__toast-body", g), style: y }, K != null && xe.createElement("div", { className: Yn("Toastify__toast-icon", { "Toastify--animate-icon Toastify__zoom-enter": !F }) }, K), xe.createElement("div", null, a)), ce, xe.createElement(sp, { ...x && !z ? { key: `pb-${x}` } : {}, rtl: w, theme: G, delay: c, isRunning: t, isIn: R, closeToast: b, hide: p, type: d, style: E, className: v, controlledProgress: z, progress: _ || 0 })));
928
+ }, "aria-label": H }, Ee.createElement("svg", { "aria-hidden": "true", viewBox: "0 0 14 16" }, Ee.createElement("path", { fillRule: "evenodd", d: "M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z" })));
929
+ }(q)), Ee.createElement(C, { isIn: R, done: D, position: m, preventExitTransition: n, nodeRef: r, playToast: i }, Ee.createElement("div", { id: T, onClick: l, "data-in": R, className: Q, ...o, style: h, ref: r }, Ee.createElement("div", { ...R && { role: I }, className: kt(g) ? g({ type: d }) : Yn("Toastify__toast-body", g), style: y }, K != null && Ee.createElement("div", { className: Yn("Toastify__toast-icon", { "Toastify--animate-icon Toastify__zoom-enter": !F }) }, K), Ee.createElement("div", null, a)), ce, Ee.createElement(sp, { ...x && !z ? { key: `pb-${x}` } : {}, rtl: w, theme: G, delay: c, isRunning: t, isIn: R, closeToast: b, hide: p, type: d, style: E, className: v, controlledProgress: z, progress: _ || 0 })));
930
930
  }, Os = function(e, t) {
931
931
  return t === void 0 && (t = !1), { enter: `Toastify--animate Toastify__${e}-enter`, exit: `Toastify--animate Toastify__${e}-exit`, appendPosition: t };
932
932
  }, dp = Ls(Os("bounce", !0));
@@ -956,13 +956,13 @@ function el(e) {
956
956
  _.style.setProperty("--y", `${y ? w : -1 * w}px`), _.style.setProperty("--g", `${g}`), _.style.setProperty("--s", "" + (1 - (r ? E : 0))), v += _.offsetHeight, E += 0.025;
957
957
  });
958
958
  }
959
- }, [r, c, n]), xe.createElement("div", { ref: i, className: "Toastify", id: b, onMouseEnter: () => {
959
+ }, [r, c, n]), Ee.createElement("div", { ref: i, className: "Toastify", id: b, onMouseEnter: () => {
960
960
  n && (o(!1), Ve.pause());
961
961
  }, onMouseLeave: m }, s((f, h) => {
962
962
  const g = h.length ? { ...d } : { ...d, pointerEvents: "none" };
963
- return xe.createElement("div", { className: C(f), style: g, key: `container-${f}` }, h.map((y) => {
963
+ return Ee.createElement("div", { className: C(f), style: g, key: `container-${f}` }, h.map((y) => {
964
964
  let { content: v, props: E } = y;
965
- return xe.createElement(up, { ...E, stacked: n, collapseAll: m, isIn: a(E.toastId, E.containerId), style: E.style, key: `toast-${E.key}` }, v);
965
+ return Ee.createElement(up, { ...E, stacked: n, collapseAll: m, isIn: a(E.toastId, E.containerId), style: E.style, key: `toast-${E.key}` }, v);
966
966
  }));
967
967
  }));
968
968
  }
@@ -7304,7 +7304,7 @@ const l4 = (e) => /* @__PURE__ */ A.createElement("svg", { width: 20, height: 21
7304
7304
  /* @__PURE__ */ u.jsx(y4, { rating: b, setRating: f })
7305
7305
  ] })
7306
7306
  ] }),
7307
- /* @__PURE__ */ u.jsx(oe, { position: "relative", children: /* @__PURE__ */ u.jsx(Ee, { title: "Close", children: /* @__PURE__ */ u.jsx(g4, { onClick: h, children: /* @__PURE__ */ u.jsx(H3, { width: "16px", height: "16px" }) }) }) })
7307
+ /* @__PURE__ */ u.jsx(oe, { position: "relative", children: /* @__PURE__ */ u.jsx(xe, { title: "Close", children: /* @__PURE__ */ u.jsx(g4, { onClick: h, children: /* @__PURE__ */ u.jsx(H3, { width: "16px", height: "16px" }) }) }) })
7308
7308
  ]
7309
7309
  }
7310
7310
  ),
@@ -7379,7 +7379,7 @@ const l4 = (e) => /* @__PURE__ */ A.createElement("svg", { width: 20, height: 21
7379
7379
  /* @__PURE__ */ u.jsxs(A4, { gap: "4px", children: [
7380
7380
  /* @__PURE__ */ u.jsxs(V, { direction: "row", justifyContent: "space-between", children: [
7381
7381
  /* @__PURE__ */ u.jsx(O4, { variant: "body1_medium", children: x4 }),
7382
- /* @__PURE__ */ u.jsx(V, { onClick: i, position: "absolute", top: "4px", right: "4px", children: /* @__PURE__ */ u.jsx(Ee, { title: "Close", placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { children: /* @__PURE__ */ u.jsx(S4, {}) }) }) })
7382
+ /* @__PURE__ */ u.jsx(V, { onClick: i, position: "absolute", top: "4px", right: "4px", children: /* @__PURE__ */ u.jsx(xe, { title: "Close", placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { children: /* @__PURE__ */ u.jsx(S4, {}) }) }) })
7383
7383
  ] }),
7384
7384
  /* @__PURE__ */ u.jsx(R4, { variant: "body2", children: E4 })
7385
7385
  ] }),
@@ -7838,10 +7838,10 @@ const H4 = O(oe)`
7838
7838
  /* @__PURE__ */ u.jsx(tf, { variant: "h2", children: y ? bl : H1 })
7839
7839
  ] }),
7840
7840
  /* @__PURE__ */ u.jsxs(V, { direction: "row", children: [
7841
- /* @__PURE__ */ u.jsx(Ee, { title: U3, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: x, id: "help-button", sx: { height: "36px", width: "36px" }, children: /* @__PURE__ */ u.jsx("img", { src: N4, alt: "Help", height: "20px" }) }) }),
7841
+ /* @__PURE__ */ u.jsx(xe, { title: U3, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: x, id: "help-button", sx: { height: "36px", width: "36px" }, children: /* @__PURE__ */ u.jsx("img", { src: N4, alt: "Help", height: "20px" }) }) }),
7842
7842
  t && (o != null && o.length) ? /* @__PURE__ */ u.jsxs(u.Fragment, { children: [
7843
- r ? /* @__PURE__ */ u.jsx(Ee, { title: $1, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: s, sx: { height: "36px", width: "36px" }, children: /* @__PURE__ */ u.jsx("img", { src: P4, alt: "Link Task", height: "20px" }) }) }) : null,
7844
- n ? /* @__PURE__ */ u.jsx(Ee, { title: X1, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: i, sx: { height: "36px", width: "36px" }, children: /* @__PURE__ */ u.jsx("img", { src: D4, alt: "Add", height: "20px" }) }) }) : null
7843
+ r ? /* @__PURE__ */ u.jsx(xe, { title: $1, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: s, sx: { height: "36px", width: "36px" }, children: /* @__PURE__ */ u.jsx("img", { src: P4, alt: "Link Task", height: "20px" }) }) }) : null,
7844
+ n ? /* @__PURE__ */ u.jsx(xe, { title: X1, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: i, sx: { height: "36px", width: "36px" }, children: /* @__PURE__ */ u.jsx("img", { src: D4, alt: "Add", height: "20px" }) }) }) : null
7845
7845
  ] }) : null
7846
7846
  ] })
7847
7847
  ] })
@@ -7861,7 +7861,7 @@ var Bu;
7861
7861
  function Cb() {
7862
7862
  if (Bu) return Ea;
7863
7863
  Bu = 1;
7864
- var e = xe;
7864
+ var e = Ee;
7865
7865
  function t(c, l) {
7866
7866
  return c === l && (c !== 0 || 1 / c === 1 / l) || c !== c && l !== l;
7867
7867
  }
@@ -7912,7 +7912,7 @@ var Vu;
7912
7912
  function xb() {
7913
7913
  return Vu || (Vu = 1, process.env.NODE_ENV !== "production" && function() {
7914
7914
  typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
7915
- var e = xe;
7915
+ var e = Ee;
7916
7916
  function t(l, d) {
7917
7917
  return l === d && (l !== 0 || 1 / l === 1 / d) || l !== l && d !== d;
7918
7918
  }
@@ -15223,8 +15223,8 @@ const o8 = O(oe)`
15223
15223
  }
15224
15224
  ),
15225
15225
  /* @__PURE__ */ u.jsxs(c8, { className: "input-wrapper", children: [
15226
- /* @__PURE__ */ u.jsx(Ee, { title: b.toolTipTitle, arrow: !0, placement: "right-end", disableHoverListener: !0, children: le(b) }),
15227
- r != null && r.icon ? /* @__PURE__ */ u.jsx(Ee, { title: r.toolTipText, placement: "bottom", children: /* @__PURE__ */ u.jsx(d8, { className: "form--sideIcon", children: r == null ? void 0 : r.icon }) }) : null
15226
+ /* @__PURE__ */ u.jsx(xe, { title: b.toolTipTitle, arrow: !0, placement: "right-end", disableHoverListener: !0, children: le(b) }),
15227
+ r != null && r.icon ? /* @__PURE__ */ u.jsx(xe, { title: r.toolTipText, placement: "bottom", children: /* @__PURE__ */ u.jsx(d8, { className: "form--sideIcon", children: r == null ? void 0 : r.icon }) }) : null
15228
15228
  ] }),
15229
15229
  ce()
15230
15230
  ]
@@ -15273,7 +15273,7 @@ const o8 = O(oe)`
15273
15273
  const v = (E) => (x, I) => {
15274
15274
  n == null || n(x, I, E);
15275
15275
  };
15276
- return /* @__PURE__ */ u.jsx(h8, { spacing: b, children: e.map(({ id: E, title: x, formFields: I }) => I.every((w) => w.hideInUI) ? null : /* @__PURE__ */ u.jsxs(xe.Fragment, { children: [
15276
+ return /* @__PURE__ */ u.jsx(h8, { spacing: b, children: e.map(({ id: E, title: x, formFields: I }) => I.every((w) => w.hideInUI) ? null : /* @__PURE__ */ u.jsxs(Ee.Fragment, { children: [
15277
15277
  x && I.length ? /* @__PURE__ */ u.jsx(ee, { variant: "h3", className: "authform__section-title", children: x }) : null,
15278
15278
  /* @__PURE__ */ u.jsx(p8, { useFlexGap: !0, spacing: C, cols: y, children: I.map((w) => {
15279
15279
  var T;
@@ -15330,7 +15330,7 @@ const o8 = O(oe)`
15330
15330
  /* @__PURE__ */ u.jsx("img", { className: "preview-img", onError: () => r(!0), ...t }),
15331
15331
  /* @__PURE__ */ u.jsx(b8, { className: "play-icon" })
15332
15332
  ] });
15333
- }, B2 = O(({ className: e, ...t }) => /* @__PURE__ */ u.jsx(Ee, { ...t, classes: { popper: e } }))(({ tooltipStyle: e, arrowStyle: t }) => ({
15333
+ }, B2 = O(({ className: e, ...t }) => /* @__PURE__ */ u.jsx(xe, { ...t, classes: { popper: e } }))(({ tooltipStyle: e, arrowStyle: t }) => ({
15334
15334
  [`& .${Uo.arrow}`]: {
15335
15335
  ...t
15336
15336
  },
@@ -15995,7 +15995,7 @@ Do you want to continue?`, tx = "Select an object to create", nx = "Select an ob
15995
15995
  ] }) }),
15996
15996
  /* @__PURE__ */ u.jsx($h, { children: m.map((g, y) => /* @__PURE__ */ u.jsxs(eb, { children: [
15997
15997
  Object.values(g.cells).map((v, E) => f(v, E)),
15998
- /* @__PURE__ */ u.jsx(nb, { children: !b && g.externalResourceId && /* @__PURE__ */ u.jsx(Ee, { title: U1, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { className: "row-edit", onClick: () => h(g.externalResourceId), children: /* @__PURE__ */ u.jsx("img", { src: ux }) }) }) })
15998
+ /* @__PURE__ */ u.jsx(nb, { children: !b && g.externalResourceId && /* @__PURE__ */ u.jsx(xe, { title: U1, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { className: "row-edit", onClick: () => h(g.externalResourceId), children: /* @__PURE__ */ u.jsx("img", { src: ux }) }) }) })
15999
15999
  ] }, `id_${y}`)) })
16000
16000
  ] }) })
16001
16001
  ] });
@@ -16113,14 +16113,14 @@ const Zd = (e) => {
16113
16113
  });
16114
16114
  }, z = (q) => {
16115
16115
  const ce = /<>(.*?)<>/g, ue = q.split(ce);
16116
- return /* @__PURE__ */ u.jsx(xe.Fragment, { children: ue.map(
16116
+ return /* @__PURE__ */ u.jsx(Ee.Fragment, { children: ue.map(
16117
16117
  (B, N) => N % 2 === 1 ? /* @__PURE__ */ u.jsx(z4, { variant: "body2", onClick: Q, children: B }, N) : B
16118
16118
  ) });
16119
16119
  };
16120
16120
  return i ? /* @__PURE__ */ u.jsx(Jn, { variant: "rounded", width: "100%", height: 16, animation: "wave", margin: "4px 0 0 0" }) : Y ? /* @__PURE__ */ u.jsxs(rf, { gap: "7px", children: [
16121
16121
  f ? /* @__PURE__ */ u.jsx(V, { marginTop: "3px", flexShrink: "0", children: /* @__PURE__ */ u.jsx("img", { src: yx, width: "18px", height: "18px" }) }) : null,
16122
16122
  /* @__PURE__ */ u.jsx(of, { variant: "body2", children: R ? z(R) : Nu })
16123
- ] }) : /* @__PURE__ */ u.jsx(Ee, { title: T ? G : null, placement: "bottom", children: r ? /* @__PURE__ */ u.jsx(
16123
+ ] }) : /* @__PURE__ */ u.jsx(xe, { title: T ? G : null, placement: "bottom", children: r ? /* @__PURE__ */ u.jsx(
16124
16124
  sf,
16125
16125
  {
16126
16126
  ref: g,
@@ -16155,7 +16155,7 @@ const Zd = (e) => {
16155
16155
  },
16156
16156
  sx: { ...i },
16157
16157
  children: /* @__PURE__ */ u.jsxs(V, { direction: "row", children: [
16158
- r && /* @__PURE__ */ u.jsx(oe, { position: "absolute", right: 10, top: 10, children: /* @__PURE__ */ u.jsx(Ee, { title: "Close", placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: () => t(!1), children: /* @__PURE__ */ u.jsx("img", { src: $2 }) }) }) }),
16158
+ r && /* @__PURE__ */ u.jsx(oe, { position: "absolute", right: 10, top: 10, children: /* @__PURE__ */ u.jsx(xe, { title: "Close", placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: () => t(!1), children: /* @__PURE__ */ u.jsx("img", { src: $2 }) }) }) }),
16159
16159
  n
16160
16160
  ] })
16161
16161
  }
@@ -16391,8 +16391,8 @@ const Zd = (e) => {
16391
16391
  return null;
16392
16392
  const o = r[r.length - 1], i = r.slice(0, -1), s = t ? (i.length + 1) * 32 : 32;
16393
16393
  return /* @__PURE__ */ u.jsxs(q4, { width: s, isHovered: t, children: [
16394
- /* @__PURE__ */ u.jsx("div", { className: "hidden-actions", children: i.map(({ id: a, disabled: c, label: l, iconSrc: d, action: p }) => /* @__PURE__ */ u.jsx(Ee, { title: l, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: p, disabled: c, children: /* @__PURE__ */ u.jsx("img", { src: d }) }) }, a)) }),
16395
- o && /* @__PURE__ */ u.jsx(Ee, { title: o.label, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: o.action, disabled: o.disabled, children: /* @__PURE__ */ u.jsx("img", { src: o.iconSrc }) }) }, o.id)
16394
+ /* @__PURE__ */ u.jsx("div", { className: "hidden-actions", children: i.map(({ id: a, disabled: c, label: l, iconSrc: d, action: p }) => /* @__PURE__ */ u.jsx(xe, { title: l, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: p, disabled: c, children: /* @__PURE__ */ u.jsx("img", { src: d }) }) }, a)) }),
16395
+ o && /* @__PURE__ */ u.jsx(xe, { title: o.label, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: o.action, disabled: o.disabled, children: /* @__PURE__ */ u.jsx("img", { src: o.iconSrc }) }) }, o.id)
16396
16396
  ] });
16397
16397
  }, Xx = (e) => {
16398
16398
  const {
@@ -16502,11 +16502,11 @@ const Zd = (e) => {
16502
16502
  /* @__PURE__ */ u.jsxs(W4, { className: C ? "hiver-card-expanded" : "", onClick: (j) => B(j, D), children: [
16503
16503
  /* @__PURE__ */ u.jsxs(Z4, { children: [
16504
16504
  T && /* @__PURE__ */ u.jsx("img", { src: T, alt: I }),
16505
- /* @__PURE__ */ u.jsx(Ee, { title: f ? I : "", placement: "bottom", children: /* @__PURE__ */ u.jsx(U4, { variant: "h4", onMouseOver: (j) => N(j), onMouseLeave: (j) => N(j), children: I }) })
16505
+ /* @__PURE__ */ u.jsx(xe, { title: f ? I : "", placement: "bottom", children: /* @__PURE__ */ u.jsx(U4, { variant: "h4", onMouseOver: (j) => N(j), onMouseLeave: (j) => N(j), children: I }) })
16506
16506
  ] }),
16507
16507
  /* @__PURE__ */ u.jsxs(rf, { children: [
16508
16508
  /* @__PURE__ */ u.jsx(Ux, { actions: le, isHovered: v }),
16509
- /* @__PURE__ */ u.jsx(Ee, { title: C ? G1 : ml, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: (j) => B(j, D), children: /* @__PURE__ */ u.jsx(Cl, { className: C ? "" : "hiver-up" }) }) })
16509
+ /* @__PURE__ */ u.jsx(xe, { title: C ? G1 : ml, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: (j) => B(j, D), children: /* @__PURE__ */ u.jsx(Cl, { className: C ? "" : "hiver-up" }) }) })
16510
16510
  ] })
16511
16511
  ] }),
16512
16512
  /* @__PURE__ */ u.jsx(
@@ -16718,8 +16718,8 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16718
16718
  /* @__PURE__ */ u.jsxs(cb, { children: [
16719
16719
  /* @__PURE__ */ u.jsx(sb, { variant: "h3", children: b }),
16720
16720
  /* @__PURE__ */ u.jsxs(oe, { children: [
16721
- o ? /* @__PURE__ */ u.jsx(Ee, { title: Y5, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: v, children: /* @__PURE__ */ u.jsx(yt.Close, { sx: { height: "16px", width: "16px", opacity: "0.8" } }) }) }) : null,
16722
- /* @__PURE__ */ u.jsx(Ee, { title: o ? z5 : ml, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: g, children: /* @__PURE__ */ u.jsx(Cl, { className: o ? "" : "hiver-up" }) }) })
16721
+ o ? /* @__PURE__ */ u.jsx(xe, { title: Y5, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: v, children: /* @__PURE__ */ u.jsx(yt.Close, { sx: { height: "16px", width: "16px", opacity: "0.8" } }) }) }) : null,
16722
+ /* @__PURE__ */ u.jsx(xe, { title: o ? z5 : ml, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: g, children: /* @__PURE__ */ u.jsx(Cl, { className: o ? "" : "hiver-up" }) }) })
16723
16723
  ] })
16724
16724
  ] }),
16725
16725
  /* @__PURE__ */ u.jsx(lb, { className: o ? "slideDown" : "slideUp", ref: s, height: a, children: /* @__PURE__ */ u.jsxs(ub, { children: [
@@ -16768,14 +16768,14 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16768
16768
  }, [e]), { textRef: t, isOverflow: n };
16769
16769
  }, IE = (e) => {
16770
16770
  const { textRef: t, isOverflow: n } = nh(e.data.label);
16771
- return /* @__PURE__ */ u.jsx(Ee, { title: n ? e.data.value : null, placement: "bottom", children: /* @__PURE__ */ u.jsx(mb, { ref: t, variant: "body2", paddingTop: n ? "5px" : "0px", children: e.data.label }) });
16771
+ return /* @__PURE__ */ u.jsx(xe, { title: n ? e.data.value : null, placement: "bottom", children: /* @__PURE__ */ u.jsx(mb, { ref: t, variant: "body2", paddingTop: n ? "5px" : "0px", children: e.data.label }) });
16772
16772
  }, wE = (e) => /* @__PURE__ */ u.jsxs(En.MenuList, { ...e, children: [
16773
16773
  /* @__PURE__ */ u.jsx(bb, { children: /* @__PURE__ */ u.jsx(ee, { variant: "body2_medium", children: Wb }) }),
16774
16774
  e.children
16775
16775
  ] }), _E = (e) => {
16776
16776
  const { isSelected: t } = e, { textRef: n, isOverflow: r } = nh(e.data.label);
16777
16777
  return /* @__PURE__ */ u.jsx(En.Option, { ...e, children: /* @__PURE__ */ u.jsxs(V, { direction: "row", gap: "5px", justifyContent: "space-between", alignItems: "center", children: [
16778
- /* @__PURE__ */ u.jsx(Ee, { title: r ? e.data.value : null, placement: "bottom", children: /* @__PURE__ */ u.jsx(vb, { ref: n, className: "dropdown-item-text", variant: "body2", children: e.data.label }) }),
16778
+ /* @__PURE__ */ u.jsx(xe, { title: r ? e.data.value : null, placement: "bottom", children: /* @__PURE__ */ u.jsx(vb, { ref: n, className: "dropdown-item-text", variant: "body2", children: e.data.label }) }),
16779
16779
  t ? /* @__PURE__ */ u.jsx("img", { src: EE, width: "14px", height: "14px" }) : null
16780
16780
  ] }) });
16781
16781
  }, AE = (e) => /* @__PURE__ */ u.jsx(En.ValueContainer, { ...e, children: /* @__PURE__ */ u.jsxs(V, { direction: "row", alignItems: "center", gap: "4px", children: [
@@ -16787,7 +16787,6 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16787
16787
  border: `1px solid ${Z.palette.gray.gray5}`,
16788
16788
  borderRadius: "8px",
16789
16789
  boxShadow: "none",
16790
- marginTop: "12px",
16791
16790
  backgroundColor: Z.palette.gray.gray7,
16792
16791
  cursor: "pointer",
16793
16792
  "& > :first-child": {
@@ -16841,7 +16840,7 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16841
16840
  const l = String((c == null ? void 0 : c.value) || "");
16842
16841
  l && i && xE({ selectedEmail: l, conversationId: i }), o(l);
16843
16842
  };
16844
- return /* @__PURE__ */ u.jsx(
16843
+ return /* @__PURE__ */ u.jsx(xe, { title: "Selected email", placement: "top", children: /* @__PURE__ */ u.jsx("div", { style: { marginTop: "12px" }, children: /* @__PURE__ */ u.jsx(
16845
16844
  oi,
16846
16845
  {
16847
16846
  options: s,
@@ -16864,7 +16863,7 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16864
16863
  menuPortalTarget: document.body,
16865
16864
  isLoading: r
16866
16865
  }
16867
- );
16866
+ ) }) });
16868
16867
  }, OE = O(Yh)`
16869
16868
  width: stretch;
16870
16869
  height: 100%;
@@ -16890,7 +16889,7 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16890
16889
  backButtonTooltip: i,
16891
16890
  portalId: s
16892
16891
  }) => {
16893
- const a = xe.useRef(null), [c, l] = U(!1);
16892
+ const a = Ee.useRef(null), [c, l] = U(!1);
16894
16893
  return fe(() => {
16895
16894
  s && (a.current = document.querySelector(`[data-connectorid=${s}]`), l(!0));
16896
16895
  }, [s, l]), fe(() => () => {
@@ -16898,7 +16897,7 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16898
16897
  }, [n]), t && c && a.current && po(
16899
16898
  /* @__PURE__ */ u.jsxs(OE, { className: "layover-paper", elevation: 0, children: [
16900
16899
  /* @__PURE__ */ u.jsxs(V, { direction: "row", alignItems: "center", marginLeft: "-8px", children: [
16901
- /* @__PURE__ */ u.jsx(Ee, { title: i, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: r, children: /* @__PURE__ */ u.jsx(RE, { src: DE }) }) }),
16900
+ /* @__PURE__ */ u.jsx(xe, { title: i, placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: r, children: /* @__PURE__ */ u.jsx(RE, { src: DE }) }) }),
16902
16901
  /* @__PURE__ */ u.jsx(ee, { children: o })
16903
16902
  ] }),
16904
16903
  /* @__PURE__ */ u.jsx(FE, { children: e })
@@ -16956,7 +16955,7 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16956
16955
  /* @__PURE__ */ u.jsx(Jn, { width: "100px", height: "24px" })
16957
16956
  ] }) : /* @__PURE__ */ u.jsxs(jE, { children: [
16958
16957
  p && /* @__PURE__ */ u.jsx("img", { src: p, alt: d }),
16959
- /* @__PURE__ */ u.jsx(Ee, { title: i ? d : "", children: /* @__PURE__ */ u.jsx(
16958
+ /* @__PURE__ */ u.jsx(xe, { title: i ? d : "", children: /* @__PURE__ */ u.jsx(
16960
16959
  ee,
16961
16960
  {
16962
16961
  variant: "h4",
@@ -16967,8 +16966,8 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
16967
16966
  ) })
16968
16967
  ] }),
16969
16968
  /* @__PURE__ */ u.jsxs(V, { direction: "row", alignItems: "center", children: [
16970
- a ? /* @__PURE__ */ u.jsx(Ee, { title: V1, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: (f) => m(f), children: /* @__PURE__ */ u.jsx("img", { src: q2 }) }) }) : null,
16971
- /* @__PURE__ */ u.jsx(Ee, { title: a ? G1 : ml, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: () => c((f) => !f), children: /* @__PURE__ */ u.jsx(Cl, { className: a ? "" : "hiver-up" }) }) })
16969
+ a ? /* @__PURE__ */ u.jsx(xe, { title: V1, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: (f) => m(f), children: /* @__PURE__ */ u.jsx("img", { src: q2 }) }) }) : null,
16970
+ /* @__PURE__ */ u.jsx(xe, { title: a ? G1 : ml, placement: "bottom", children: /* @__PURE__ */ u.jsx(co, { onClick: () => c((f) => !f), children: /* @__PURE__ */ u.jsx(Cl, { className: a ? "" : "hiver-up" }) }) })
16972
16971
  ] })
16973
16972
  ] }),
16974
16973
  /* @__PURE__ */ u.jsx(
@@ -17393,7 +17392,7 @@ const Yx = "Bring your favourite tools into Hiver", Jx = "Plugin image", qx = "I
17393
17392
  " to ",
17394
17393
  D.connectorName
17395
17394
  ] }),
17396
- /* @__PURE__ */ u.jsx(Ee, { title: "Close Popup", placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: r, children: /* @__PURE__ */ u.jsx(GE, { src: $2 }) }) })
17395
+ /* @__PURE__ */ u.jsx(xe, { title: "Close Popup", placement: "bottom", children: /* @__PURE__ */ u.jsx(ct, { onClick: r, children: /* @__PURE__ */ u.jsx(GE, { src: $2 }) }) })
17397
17396
  ] }) : null,
17398
17397
  /* @__PURE__ */ u.jsxs(hh, { spacing: 3, children: [
17399
17398
  !t && !R ? /* @__PURE__ */ u.jsx(
@@ -18624,7 +18623,7 @@ const $c = /* @__PURE__ */ new Set(), BI = (e, t) => {
18624
18623
  setSelectedEmail: G
18625
18624
  }
18626
18625
  ) }),
18627
- tr && Nn && e && /* @__PURE__ */ u.jsx(Ee, { title: "Settings", placement: "bottom", children: /* @__PURE__ */ u.jsx(
18626
+ tr && Nn && e && /* @__PURE__ */ u.jsx(xe, { title: "Update customer identity mapping", placement: "top", children: /* @__PURE__ */ u.jsx(
18628
18627
  ct,
18629
18628
  {
18630
18629
  sx: { height: "32px", width: "32px", marginTop: "12px", flexShrink: 0 },
@@ -20125,7 +20124,7 @@ const hw = "Everything looks good", pw = "Something is not working", gw = "Share
20125
20124
  width: 100%;
20126
20125
  min-height: 40px;
20127
20126
  background-color: ${Z.palette.gray.gray6a};
20128
- `, Po = O(Ee)`
20127
+ `, Po = O(xe)`
20129
20128
  padding: 6px;
20130
20129
  border-radius: 6px;
20131
20130
  `, Bw = O(Ze)`
@@ -20226,7 +20225,7 @@ const hw = "Everything looks good", pw = "Something is not working", gw = "Share
20226
20225
  /* @__PURE__ */ u.jsxs(Rw, { children: [
20227
20226
  /* @__PURE__ */ u.jsxs(V, { flexDirection: "row", alignItems: "center", style: { height: "100%" }, children: [
20228
20227
  y && /* @__PURE__ */ u.jsx("img", { src: y, alt: "Logo", style: { marginRight: 8 }, height: 18, width: 18 }),
20229
- /* @__PURE__ */ u.jsx(Ee, { title: v, arrow: !0, placement: "top", children: /* @__PURE__ */ u.jsx(Fw, { variant: "h3", color: Z.palette.gray.black, width: o ? "100px" : "200px", children: v }) })
20228
+ /* @__PURE__ */ u.jsx(xe, { title: v, arrow: !0, placement: "top", children: /* @__PURE__ */ u.jsx(Fw, { variant: "h3", color: Z.palette.gray.black, width: o ? "100px" : "200px", children: v }) })
20230
20229
  ] }),
20231
20230
  o ? /* @__PURE__ */ u.jsx(Bw, { variant: "text", size: "small", endIcon: /* @__PURE__ */ u.jsx(yt.ArrowForward, {}), onClick: Y, children: vw }) : null
20232
20231
  ] }),
@@ -20236,7 +20235,7 @@ const hw = "Everything looks good", pw = "Something is not working", gw = "Share
20236
20235
  ce,
20237
20236
  ":"
20238
20237
  ] }),
20239
- /* @__PURE__ */ u.jsx(Ee, { title: (q == null ? void 0 : q.length) > Ga ? q : "", arrow: !0, placement: "top", children: ue ? /* @__PURE__ */ u.jsx(
20238
+ /* @__PURE__ */ u.jsx(xe, { title: (q == null ? void 0 : q.length) > Ga ? q : "", arrow: !0, placement: "top", children: ue ? /* @__PURE__ */ u.jsx(
20240
20239
  li,
20241
20240
  {
20242
20241
  href: ue,
@@ -20284,7 +20283,7 @@ const hw = "Everything looks good", pw = "Something is not working", gw = "Share
20284
20283
  }, t0 = (e, t, n, r = 10) => e >= n.left - r && e <= n.right + r && t >= n.top - r && t <= n.bottom + r, n0 = (e, t = 350, n = 400) => {
20285
20284
  const r = e.getBoundingClientRect(), o = window.innerHeight, i = window.innerWidth, s = r.top, a = o - r.bottom;
20286
20285
  return a >= t || a > s ? r.left < n / 2 ? "bottom-start" : i - r.right < n / 2 ? "bottom-end" : "bottom" : r.left < n / 2 ? "top-start" : i - r.right < n / 2 ? "top-end" : "top";
20287
- }, Zw = O(({ className: e, ...t }) => /* @__PURE__ */ u.jsx(Ee, { ...t, classes: { popper: e } }))(() => ({
20286
+ }, Zw = O(({ className: e, ...t }) => /* @__PURE__ */ u.jsx(xe, { ...t, classes: { popper: e } }))(() => ({
20288
20287
  [`& .${Uo.tooltip}`]: {
20289
20288
  backgroundColor: "#fff",
20290
20289
  padding: 0,
@@ -20299,7 +20298,7 @@ const hw = "Everything looks good", pw = "Something is not working", gw = "Share
20299
20298
  }
20300
20299
  }));
20301
20300
  function Uw({ elements: e, title: t, onKeyChange: n }) {
20302
- const [r, o] = U(!1), [i, s] = U(null), [a, c] = U(""), [l, d] = U("bottom"), [p, b] = U(!1), C = xe.useRef(null), m = xe.useRef({ x: 0, y: 0 }), f = xe.useCallback(() => {
20301
+ const [r, o] = U(!1), [i, s] = U(null), [a, c] = U(""), [l, d] = U("bottom"), [p, b] = U(!1), C = Ee.useRef(null), m = Ee.useRef({ x: 0, y: 0 }), f = Ee.useCallback(() => {
20303
20302
  C.current && (clearTimeout(C.current), C.current = null);
20304
20303
  }, []);
20305
20304
  fe(() => {
@@ -20567,7 +20566,7 @@ const Yw = (e) => {
20567
20566
  [Re.PAUSED]: "Synced",
20568
20567
  [Re.ERROR]: "Syncing failed",
20569
20568
  [Re.UNAUTHENTICATED]: "Sync conversation"
20570
- }, rn = Yc({}), c_ = O(({ className: e, ...t }) => /* @__PURE__ */ u.jsx(Ee, { ...t, classes: { popper: e } }))(() => ({
20569
+ }, rn = Yc({}), c_ = O(({ className: e, ...t }) => /* @__PURE__ */ u.jsx(xe, { ...t, classes: { popper: e } }))(() => ({
20571
20570
  [`& .${Uo.tooltip}`]: {
20572
20571
  backgroundColor: "#fff",
20573
20572
  padding: 0,
@@ -20780,7 +20779,7 @@ const Yw = (e) => {
20780
20779
  const { connectorFunctions: s } = Fe(rn), a = s == null ? void 0 : s.sendTrackingEvent, [c, l] = U(() => localStorage.getItem(o0) === "true"), [d, p] = U(!1), { connectorId: b, connectorName: C, connectorStatus: m } = n ?? {}, f = t || m !== As.DISABLED, h = m === As.UNAUTHENTICATED, g = r === Re.PENDING, y = () => {
20781
20780
  localStorage.setItem(o0, "true"), l(!0), p(!0), a == null || a(jt.email_logging_intro_popup_continue_clicked, { app_name: C });
20782
20781
  };
20783
- return c ? h ? /* @__PURE__ */ u.jsx($_, { connectorId: b, connectorName: C, isAdmin: t, isAuthenticated: !1, children: e }) : o ? /* @__PURE__ */ u.jsx(Ee, { title: b_, children: e }) : g ? /* @__PURE__ */ u.jsx(Ee, { title: m_.replace(":connectorName", C), children: e }) : i ? /* @__PURE__ */ u.jsx(u_, { defaultOpen: d, renderTooltip: i, children: e }) : /* @__PURE__ */ u.jsx(u.Fragment, { children: e }) : /* @__PURE__ */ u.jsx(j_, { onContinue: f ? y : void 0, connectorName: C, children: e });
20782
+ return c ? h ? /* @__PURE__ */ u.jsx($_, { connectorId: b, connectorName: C, isAdmin: t, isAuthenticated: !1, children: e }) : o ? /* @__PURE__ */ u.jsx(xe, { title: b_, children: e }) : g ? /* @__PURE__ */ u.jsx(xe, { title: m_.replace(":connectorName", C), children: e }) : i ? /* @__PURE__ */ u.jsx(u_, { defaultOpen: d, renderTooltip: i, children: e }) : /* @__PURE__ */ u.jsx(u.Fragment, { children: e }) : /* @__PURE__ */ u.jsx(j_, { onContinue: f ? y : void 0, connectorName: C, children: e });
20784
20783
  }, Y_ = (e) => /* @__PURE__ */ A.createElement("svg", { width: 124, height: 107, viewBox: "0 0 124 107", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ A.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M28.6168 54.7446C28.6931 52.5589 31.0146 51.1102 33.0842 51.8174C35.9985 52.8133 40.0375 53.9024 44.0621 54.043C48.0034 54.1806 51.968 53.4097 54.8762 52.6339C57.0264 52.0602 59.2927 53.6932 59.215 55.9172C59.1742 57.0856 58.4742 58.1269 57.3723 58.5178C54.8051 59.4284 49.7633 60.8927 44.3075 60.7022C38.7694 60.5088 33.1999 58.6241 30.4004 57.5311C29.2637 57.0873 28.5742 55.9641 28.6168 54.7446Z", fill: "url(#paint0_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("path", { d: "M47.223 43.6373C44.4928 30.7926 52.6922 18.1666 65.5368 15.4364C78.3815 12.7062 91.0075 20.9055 93.7377 33.7502L105.079 87.1053L84.1844 91.5466C70.0346 94.5542 56.1258 85.5217 53.1182 71.3719L47.223 43.6373Z", fill: "url(#paint1_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("mask", { id: "mask0_8481_102191", style: {
20785
20784
  maskType: "luminance"
20786
20785
  }, maskUnits: "userSpaceOnUse", x: 46, y: 14, width: 60, height: 79 }, /* @__PURE__ */ A.createElement("path", { d: "M47.223 43.6373C44.4928 30.7926 52.6922 18.1666 65.5368 15.4364C78.3815 12.7062 91.0075 20.9055 93.7377 33.7502L105.079 87.1053L84.1844 91.5466C70.0346 94.5542 56.1258 85.5217 53.1182 71.3719L47.223 43.6373Z", fill: "white" })), /* @__PURE__ */ A.createElement("g", { mask: "url(#mask0_8481_102191)" }, /* @__PURE__ */ A.createElement("ellipse", { cx: 63.7775, cy: 46.8684, rx: 1.48152, ry: 1.39438, transform: "rotate(-12 63.7775 46.8684)", fill: "#435C71" }), /* @__PURE__ */ A.createElement("rect", { x: 47.4368, y: 59.3203, width: 53.657, height: 13.2235, transform: "rotate(-12 47.4368 59.3203)", fill: "url(#paint2_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("rect", { x: 51.1907, y: 76.9824, width: 53.657, height: 10.4263, transform: "rotate(-12 51.1907 76.9824)", fill: "url(#paint3_linear_8481_102191)" })), /* @__PURE__ */ A.createElement("path", { opacity: 0.883952, d: "M113.939 51.0679C114.775 55 112.265 58.865 108.333 59.7008L107.842 59.8052C103.639 60.6986 99.5073 58.0155 98.6139 53.8123L97.205 47.1837L105.307 45.4616C109.239 44.6259 113.104 47.1359 113.939 51.0679Z", fill: "url(#paint4_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M68.7215 66.4138C67.1801 64.8725 67.6745 62.2062 69.587 61.1603C72.4457 59.5969 76.2861 57.1773 79.3785 54.0849C82.4099 51.0535 84.752 47.3461 86.2775 44.5465C87.3388 42.5989 90.0598 42.0819 91.6282 43.6503C92.4782 44.5003 92.758 45.7623 92.2604 46.8566C91.0829 49.4466 88.5191 54.344 84.4346 58.4285C80.2853 62.5778 74.8639 65.591 72.0553 66.9952C70.9363 67.5548 69.6062 67.2985 68.7215 66.4138Z", fill: "url(#paint5_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("rect", { x: 48.7264, y: 33.7744, width: 11.2108, height: 11.2108, rx: 5.59457, transform: "rotate(-12 48.7264 33.7744)", fill: "url(#paint6_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("rect", { x: 50.0175, y: 35.8193, width: 4.0158, height: 3.84848, rx: 1.92424, transform: "rotate(-12 50.0175 35.8193)", fill: "#435C71" }), /* @__PURE__ */ A.createElement("rect", { x: 59.2875, y: 31.5723, width: 11.2108, height: 11.2108, rx: 5.59457, transform: "rotate(-12 59.2875 31.5723)", fill: "#FFFEFE" }), /* @__PURE__ */ A.createElement("path", { opacity: 0.883952, d: "M111.25 38.5376C110.415 34.6055 106.55 32.0955 102.618 32.9313L102.127 33.0356C97.9234 33.9291 95.2403 38.0607 96.1337 42.2639L97.5426 48.8925L105.644 47.1705C109.576 46.3347 112.086 42.4696 111.25 38.5376Z", fill: "url(#paint7_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("rect", { x: 60.0181, y: 33.8037, width: 3.84848, height: 3.84848, rx: 1.90724, transform: "rotate(-12 60.0181 33.8037)", fill: "#435C71" }), /* @__PURE__ */ A.createElement("path", { d: "M36.9246 59.1604C36.4487 60.717 34.7371 61.6271 33.1805 61.1512C32.3613 60.9007 31.7241 60.3475 31.3259 59.5987L25.2059 46.7983C24.9784 46.3703 25.1286 45.8788 25.5566 45.6513L28.338 44.1724C28.7659 43.9449 29.2574 44.0951 29.4849 44.5231L36.6496 56.8367C37.0728 57.5036 37.15 58.423 36.9246 59.1604Z", fill: "#FFDF9F" }), /* @__PURE__ */ A.createElement("rect", { x: 27.9973, y: 44.333, width: 2.39869, height: 3.59807, transform: "rotate(152 27.9973 44.333)", fill: "#FF9090" }), /* @__PURE__ */ A.createElement("path", { d: "M26.6628 44.3769L26.9472 44.9118L28.0169 44.343L26.3106 41.1338L24.171 42.2714L25.0243 43.876C25.6661 43.5347 26.3215 43.7351 26.6628 44.3769Z", fill: "#FFB19F" }), /* @__PURE__ */ A.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M7.26386 27.248C9.3428 20.4481 16.5101 16.6372 23.31 18.7161C30.11 20.7951 33.9209 27.9624 31.8419 34.7623C29.763 41.5622 22.5956 45.3731 15.7958 43.2942C8.99587 41.2152 5.18493 34.0479 7.26386 27.248ZM9.72157 27.9983C8.06843 33.4055 11.1399 39.1821 16.5471 40.8352C21.9543 42.4884 27.7309 39.4168 29.384 34.0096C31.0372 28.6024 27.9657 22.8258 22.5585 21.1727C17.1513 19.5196 11.3747 22.5911 9.72157 27.9983Z", fill: "#FFE69F" }), /* @__PURE__ */ A.createElement("circle", { opacity: 0.414016, cx: 19.5529, cy: 31.0039, r: 10.2804, transform: "rotate(17 19.5529 31.0039)", fill: "#BBDEFC" }), /* @__PURE__ */ A.createElement("path", { d: "M14.3685 30.6746C15.7299 27.6867 18.9391 25.9803 22.1776 26.5225L22.2595 26.5475C23.7024 26.8095 24.3854 24.8682 23.1497 24.2218C22.3806 23.8074 21.5613 23.557 20.717 23.3884C17.3715 22.9031 14.0553 24.6664 12.6939 27.6543C12.2796 28.4235 12.0859 29.3497 12.0244 30.1372C11.8444 31.6051 13.8607 32.0424 14.4503 30.6997C14.3434 30.7566 14.3685 30.6746 14.3685 30.6746Z", fill: "#F6FBFF" }), /* @__PURE__ */ A.createElement("path", { d: "M10.2904 29.0679C11.9436 23.6607 17.7202 20.5893 23.1274 22.2424C25.6671 23.0189 27.5785 24.6783 28.9301 26.704C27.7539 24.1048 25.508 22.0744 22.5586 21.1727C17.1514 19.5196 11.3748 22.591 9.72165 27.9982C8.81993 30.9476 9.32924 33.97 10.7444 36.3735C9.82081 34.1203 9.51395 31.6077 10.2904 29.0679Z", fill: "#ADCBE7" }), /* @__PURE__ */ A.createElement("path", { opacity: 0.406087, d: "M36.4864 56.8021L36.1373 56.2691C36.3845 56.8563 36.428 57.5516 36.2372 58.1754C35.9273 59.189 34.5593 59.1971 34.0713 58.2806L28.3787 47.5877C28.0534 46.9767 27.3508 46.7619 26.7395 47.0866L25.7206 47.6277L31.4395 59.3516C31.7648 59.9627 32.27 60.5434 32.8706 60.8123C33.7054 61.1528 34.6593 61.1034 35.3726 60.7247C36.0858 60.3459 36.6602 59.5837 36.8444 58.7021C37.0351 58.0783 36.8117 57.4132 36.4864 56.8021Z", fill: "white" }), /* @__PURE__ */ A.createElement("path", { d: "M29.8826 48.4977C29.8006 48.4726 29.6368 48.4225 29.5799 48.3155L28.1579 45.6411C28.0442 45.4272 28.1193 45.1814 28.3332 45.0677C28.5472 44.9539 28.7929 45.0291 28.9067 45.243L30.3287 47.9174C30.4424 48.1313 30.3673 48.3771 30.1534 48.4908C30.1284 48.5728 29.9645 48.5227 29.8826 48.4977Z", fill: "#FFF5EB" }), /* @__PURE__ */ A.createElement("ellipse", { cx: 29.2637, cy: 54.631, rx: 1.50593, ry: 3.17918, transform: "rotate(-23 29.2637 54.631)", fill: "#FFC478" }), /* @__PURE__ */ A.createElement("ellipse", { cx: 34.0592, cy: 52.4078, rx: 0.920288, ry: 1.67325, transform: "rotate(106 34.0592 52.4078)", fill: "#FFC478" }), /* @__PURE__ */ A.createElement("path", { d: "M89.1282 19.2055L68.2257 26.8725L45.9197 28.3898L44.4929 16.4082C44.3371 13.798 47.5283 11.4502 50.9859 11.6309L65.1429 12.369L67.3969 12.4869C68.5309 12.5463 69.7066 12.3289 70.7522 11.8627L78.6899 8.34726C81.725 6.99992 85.3012 7.87475 86.2125 10.1876L89.1282 19.2055Z", fill: "url(#paint8_linear_8481_102191)" }), /* @__PURE__ */ A.createElement("path", { opacity: 0.479771, d: "M88.6262 19.0953L68.3101 26.5288L65.3314 12.5149L67.5211 12.6263C68.6228 12.6824 69.7652 12.471 70.7816 12.0192L78.4972 8.61266C81.4474 7.30707 84.9208 8.14856 85.8036 10.3829L88.6262 19.0953Z", fill: "#ADCBE7" }), /* @__PURE__ */ A.createElement("path", { d: "M91.6332 26.6212L46.9517 36.1186L46.0387 28.4438L89.2535 19.2582L91.6332 26.6212Z", fill: "#717DAD" }), /* @__PURE__ */ A.createElement("path", { d: "M102.961 24.2033C103.125 24.9722 102.371 25.7829 101.278 26.015L37.9675 39.4722C36.8754 39.7043 35.8568 39.2704 35.6933 38.5015C35.5301 37.7336 36.284 36.922 37.3761 36.6898L100.687 23.2327C101.779 23.0005 102.798 23.4354 102.961 24.2033Z", fill: "#9ED1FF" }), /* @__PURE__ */ A.createElement("path", { d: "M102.703 24.1718C102.838 24.805 102.067 25.5045 100.983 25.7349L69.5583 32.4144L69.0712 30.123L100.496 23.4436C101.58 23.2131 102.569 23.5394 102.703 24.1718Z", fill: "#78AFE1" }), /* @__PURE__ */ A.createElement("defs", null, /* @__PURE__ */ A.createElement("linearGradient", { id: "paint0_linear_8481_102191", x1: 32.2665, y1: 59.6553, x2: 59.0518, y2: 60.5906, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#FFFDE0" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#FFB362" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint1_linear_8481_102191", x1: 67.3434, y1: 85.966, x2: 103.216, y2: 78.3411, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#FFFABC" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#FFA650" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint2_linear_8481_102191", x1: 51.4347, y1: 74.8197, x2: 91.1539, y2: 74.8197, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#A3C1FF" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#4243FF" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint3_linear_8481_102191", x1: 55.1887, y1: 89.2031, x2: 94.9078, y2: 89.2031, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#A3C1FF" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#4243FF" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint4_linear_8481_102191", x1: 94.5023, y1: 53.1799, x2: 106.762, y2: 58.7056, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#FF9498" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#FFD671" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint5_linear_8481_102191", x1: 74.9906, y1: 66.9871, x2: 94.9778, y2: 46.9999, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#FFFDE0" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#FFB362" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint6_linear_8481_102191", x1: 50.5805, y1: 44.0581, x2: 59.9372, y2: 44.0581, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "white" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#E3EEF3" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint7_linear_8481_102191", x1: 88.4187, y1: 43.3906, x2: 99.3981, y2: 25.1833, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#FF9498" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#FFD671" })), /* @__PURE__ */ A.createElement("linearGradient", { id: "paint8_linear_8481_102191", x1: 56.4985, y1: 29.5482, x2: 100.532, y2: 20.1885, gradientUnits: "userSpaceOnUse" }, /* @__PURE__ */ A.createElement("stop", { stopColor: "#ECF7FF" }), /* @__PURE__ */ A.createElement("stop", { offset: 1, stopColor: "#C2E0FF" })))), Zl = ({ message: e }) => /* @__PURE__ */ u.jsxs(V, { justifyContent: "center", alignItems: "center", height: "100%", children: [
@@ -20880,11 +20879,11 @@ const Yw = (e) => {
20880
20879
  conversationId: i
20881
20880
  })));
20882
20881
  };
20883
- return /* @__PURE__ */ u.jsx(Ee, { title: r ? y_ : "", placement: "top", children: /* @__PURE__ */ u.jsxs(sA, { disabled: m || f, onClick: h, children: [
20882
+ return /* @__PURE__ */ u.jsx(xe, { title: r ? y_ : "", placement: "top", children: /* @__PURE__ */ u.jsxs(sA, { disabled: m || f, onClick: h, children: [
20884
20883
  /* @__PURE__ */ u.jsx(aA, { value: n, checked: n, disabled: r }),
20885
- /* @__PURE__ */ u.jsx(Ee, { title: (c == null ? void 0 : c.length) > 30 ? c : null, placement: "right", children: /* @__PURE__ */ u.jsx(lA, { variant: "body2", children: c }) }),
20884
+ /* @__PURE__ */ u.jsx(xe, { title: (c == null ? void 0 : c.length) > 30 ? c : null, placement: "right", children: /* @__PURE__ */ u.jsx(lA, { variant: "body2", children: c }) }),
20886
20885
  m ? /* @__PURE__ */ u.jsx(c0, { children: /* @__PURE__ */ u.jsx(cA, {}) }) : null,
20887
- f ? /* @__PURE__ */ u.jsx(Ee, { title: "Record not found in " + e, children: /* @__PURE__ */ u.jsx(c0, { children: /* @__PURE__ */ u.jsx(zc, {}) }) }) : null
20886
+ f ? /* @__PURE__ */ u.jsx(xe, { title: "Record not found in " + e, children: /* @__PURE__ */ u.jsx(c0, { children: /* @__PURE__ */ u.jsx(zc, {}) }) }) : null
20888
20887
  ] }) });
20889
20888
  }, dA = O(V)`
20890
20889
  color: #343c45;
@@ -21322,7 +21321,7 @@ const GA = O(V)`
21322
21321
  font-weight: 400;
21323
21322
  line-height: 12px;
21324
21323
  letter-spacing: 0;
21325
- `, d0 = O(Ee)`
21324
+ `, d0 = O(xe)`
21326
21325
  padding: 6px;
21327
21326
  border-radius: 6px;
21328
21327
  `, WA = () => {
@@ -21590,7 +21589,7 @@ const GA = O(V)`
21590
21589
  ] }),
21591
21590
  /* @__PURE__ */ u.jsxs(KA, { children: [
21592
21591
  G ? /* @__PURE__ */ u.jsx(cT, {}) : null,
21593
- l ? /* @__PURE__ */ u.jsx(Ee, { arrow: !0, title: r ? d_ : f_, children: /* @__PURE__ */ u.jsx(V, { children: /* @__PURE__ */ u.jsx(
21592
+ l ? /* @__PURE__ */ u.jsx(xe, { arrow: !0, title: r ? d_ : f_, children: /* @__PURE__ */ u.jsx(V, { children: /* @__PURE__ */ u.jsx(
21594
21593
  aT,
21595
21594
  {
21596
21595
  checked: r,
package/index.umd.js CHANGED
@@ -1089,7 +1089,7 @@ Do you want to continue?`,fx="Select an object to create",px="Select an object t
1089
1089
  color: ${d.theme.palette.gray.gray3};
1090
1090
  `,Sv=d.styled(d.Typography)`
1091
1091
  color: ${d.theme.palette.gray.gray3};
1092
- `,Tv="https://cdn.hiverhq.com/connectors-module/assets/PlugIn.svg",Av={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1,VITE_HIVER_CDN_URL:"https://cdn.hiverhq.com/",VITE_MY_ENV_VAR:"myVariable From Agent"},{VITE_HIVER_CDN_URL:Lv}=Av,J1=({isAdmin:e=!0,hideHeading:t=!1})=>{const{sendTrackingEvent:n,availableFeatures:r,connectorFunctions:o}=w.useContext(Ge),s=et(r,N3),a=et(r,Ts),i=g=>{g.stopPropagation(),n(zm),o==null||o.redirectToAdmin()},c=g=>{g.stopPropagation(),n(Ym),window.open(fv,"_blank")},l=()=>{n(y3,{source:"main_tab"})},f=a?mv:gv;return u.jsxs(Cv,{"data-testid":"noConnectors",children:[s?u.jsxs(u.Fragment,{children:[t?null:u.jsx(d.Typography,{variant:"h2",children:a?Vi:yv}),u.jsx(Ev,{onClick:l,href:hv,target:"_blank",children:u.jsx(L8,{src:Lv+f,alt:bv,aspectRatio:"1000/783"})})]}):u.jsxs(xv,{children:[u.jsx(vv,{variant:"body1_medium",children:av}),u.jsx("img",{src:Tv,alt:iv})]}),u.jsx(Iv,{variant:"body2",children:cv}),e?u.jsx(Y1,{endIcon:u.jsx(d.icons.ArrowForward,{}),onClick:i,...s&&{size:"medium"},children:a?uv:lv}):u.jsxs(u.Fragment,{children:[u.jsx(Y1,{onClick:c,children:dv}),u.jsxs(wv,{direction:"row",children:[u.jsx(_v,{}),u.jsx(Sv,{variant:"caption",children:pv})]})]})]})},Ov=()=>{const{availableFeatures:e}=w.useContext(Ge),t=et(e,Ts);return u.jsxs(Rd,{children:[u.jsxs(d.Stack,{direction:"row",boxSizing:"content-box",paddingTop:"20px",paddingBottom:"12px",height:"36px",gap:"8px",alignItems:"center",children:[t?u.jsx(Fd,{width:"20px",height:"20px"}):u.jsx(Dd,{}),u.jsx(Nd,{variant:"h2",children:t?Vi:bd})]}),u.jsxs(d.Stack,{gap:"12px",children:[u.jsx(_n,{variant:"rounded",width:"100%",height:"46px",animation:"wave"}),u.jsx(_n,{variant:"rounded",width:"100%",height:"46px",animation:"wave"}),u.jsx(_n,{variant:"rounded",width:"100%",height:"46px",animation:"wave"})]})]})},Fv=()=>{const{metaData:e,sendTrackingEvent:t,isAdmin:n,connectorFunctions:r}=w.useContext(Ge),[o,s]=w.useState(!1),a=w.useRef(null),[i,c]=w.useState(0),{templateUpdates:l}=e||{},{sections:f=[],actionButtons:g=[],title:y}=l||{},{version:v=""}=l||{},b=o5(v),p=w.useMemo(()=>r5(v),[v]),h=w.useMemo(()=>(g==null?void 0:g.filter(({isAdminPanelLink:I})=>!(!n&&I)))??[],[g,n]);if(w.useEffect(()=>{!p&&l&&Wi(v,!0)},[p,v,l]),w.useLayoutEffect(()=>{var I;(I=a.current)!=null&&I.scrollHeight&&c(a.current.scrollHeight)},[a]),w.useEffect(()=>{l&&!b&&t(Um,{update_version_id:v})},[]),!l||b)return null;const m=I=>{var E;I.stopPropagation(),s(_=>!_),(E=a.current)!=null&&E.scrollHeight&&c(a.current.scrollHeight),Wi(v,!1,!0)},x=(I,E="",_=!1,T=!1)=>{var S;if(I.stopPropagation(),_&&T?t(Km,{update_version_id:v}):T&&t(e3,{update_version_id:v}),!_&&E){(S=window.open(E,"_blank"))==null||S.focus();return}C(I,!1),r==null||r.redirectToAdmin()},C=(I,E=!0)=>{I.stopPropagation(),Wi(v,!1),s(!1),E&&t(t3,{update_version_id:v})};return u.jsxs(o4,{children:[u.jsxs(s4,{children:[u.jsx(r4,{variant:"h3",children:y}),u.jsxs(d.Box,{children:[o?u.jsx(d.Tooltip,{title:z3,placement:"bottom",children:u.jsx(d.IconButton,{onClick:C,children:u.jsx(d.icons.Close,{sx:{height:"16px",width:"16px",opacity:"0.8"}})})}):null,u.jsx(d.Tooltip,{title:o?X3:Bi,placement:"bottom",children:u.jsx(Or,{onClick:m,children:u.jsx(Xi,{className:o?"":"hiver-up"})})})]})]}),u.jsx(a4,{className:o?"slideDown":"slideUp",ref:a,height:i,children:u.jsxs(i4,{children:[f.map(({title:I,items:E,type:_})=>u.jsxs(f4,{children:[u.jsx(d.Typography,{variant:"body2_medium",children:I}),E.map(T=>{const S=_===U3,{deeplink:L,textHtml:N,imageUrl:k}=T,D=()=>u.jsx(z5,{className:S?"":"ellipsisClass",component:"div",variant:"body2",dangerouslySetInnerHTML:{__html:N}});return u.jsx(c4,{component:"ul",children:u.jsxs(l4,{component:S?"li":"div",marginLeft:k?"0":"14px",children:[k?u.jsx("img",{src:k}):null,L?u.jsx(jd,{target:"_blank",underline:"none",onClick:j=>x(j,L),fontSize:"13px",children:D()}):D()]})},N)})]},I)),u.jsx(d.Stack,{flexDirection:"row",gap:"8px",marginBottom:"11.5px",children:h.map(({text:I,link:E,isAdminPanelLink:_})=>u.jsx(u4,{variant:_?"contained":"text",children:u.jsx(d4,{variant:"caption",onClick:T=>x(T,E,_,!0),children:I})},I))})]})})]})},kv=({selectedEmail:e,conversationId:t})=>Ae({url:P8.replace(":conversationId",""+t),method:je.PATCH,data:{selectedEmail:e}}),Dv="data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%200%2014%2014'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='7'%20cy='7'%20r='7'%20fill='%23196FE0'/%3e%3cpath%20d='M10.8288%204.89995C10.5922%204.64324%2010.1976%204.63193%209.94761%204.87601L5.96804%208.75823L4.06989%206.75353C3.82948%206.49981%203.43531%206.49425%203.18845%206.74158C2.9418%206.98865%202.9366%207.39455%203.1768%207.64827L5.50404%2010.1061C5.626%2010.235%205.78808%2010.3%205.95059%2010.3C6.10477%2010.3%206.25896%2010.2414%206.37969%2010.124L10.8056%205.80646C11.0553%205.56278%2011.0659%205.15689%2010.8288%204.89995Z'%20fill='white'/%3e%3c/svg%3e",q1=e=>{const t=w.useRef(null),[n,r]=w.useState(!1);return w.useEffect(()=>{t.current&&r(t.current.scrollWidth>t.current.clientWidth)},[e]),{textRef:t,isOverflow:n}},Nv=e=>{const{textRef:t,isOverflow:n}=q1(e.data.label);return u.jsx(d.Tooltip,{title:n?e.data.value:null,placement:"bottom",children:u.jsx(p4,{ref:t,variant:"body2",paddingTop:n?"5px":"0px",children:e.data.label})})},Rv=e=>u.jsxs(en.MenuList,{...e,children:[u.jsx(h4,{children:u.jsx(d.Typography,{variant:"body2_medium",children:V4})}),e.children]}),Mv=e=>{const{isSelected:t}=e,{textRef:n,isOverflow:r}=q1(e.data.label);return u.jsx(en.Option,{...e,children:u.jsxs(d.Stack,{direction:"row",gap:"5px",justifyContent:"space-between",alignItems:"center",children:[u.jsx(d.Tooltip,{title:r?e.data.value:null,placement:"bottom",children:u.jsx(g4,{ref:n,className:"dropdown-item-text",variant:"body2",children:e.data.label})}),t?u.jsx("img",{src:Dv,width:"14px",height:"14px"}):null]})})},Pv=e=>u.jsx(en.ValueContainer,{...e,children:u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"4px",children:[u.jsx(d.icons.AccountCircle,{sx:{height:"20px",width:"20px",color:d.theme.palette.gray.gray3,flexShrink:0}}),u.jsx(d.Stack,{direction:"row",alignItems:"center",sx:{flex:1,minWidth:0,overflow:"hidden"},children:e.children})]})}),jv=e=>u.jsx(en.DropdownIndicator,{...e,children:e.selectProps.menuIsOpen?u.jsx(d.icons.ArrowDropUp,{sx:{height:"18px",width:"18px",color:d.theme.palette.gray.gray3}}):u.jsx(d.icons.ArrowDropDown,{sx:{height:"18px",width:"18px",color:d.theme.palette.gray.gray3}})}),Bv={control:e=>({...e,border:`1px solid ${d.theme.palette.gray.gray5}`,borderRadius:"8px",boxShadow:"none",marginTop:"12px",backgroundColor:d.theme.palette.gray.gray7,cursor:"pointer","& > :first-child":{"& > :first-child":{paddingTop:"0px"},"& > :nth-child(2)":{height:"0px"}}}),option:(e,t)=>({...e,backgroundColor:d.theme.palette.gray.white,color:d.theme.palette.gray.black,height:"36px",padding:"6px 16px","&:hover":{backgroundColor:t.isFocused?d.theme.palette.gray.gray7:d.theme.palette.gray.white}}),singleValue:e=>({...e}),menuList:e=>({...e,maxHeight:"160px",borderRadius:"4px",overflowX:"hidden"}),menu:e=>({...e,boxShadow:"0px 3px 15px 0px #00000040",marginTop:"3px"}),menuPortal:e=>({...e,zIndex:2,maxHeight:"160px"})},Vv=({selectedEmail:e,emailHeaders:t,root:n,isLoading:r,setSelectedEmail:o})=>{const{conversationId:s}=w.useContext(Ge),a=t?Object.entries(t).map(([c])=>({value:c,label:c})):e?[{value:e,label:e}]:[];w.useEffect(()=>{if(!e&&!r&&t&&Object.keys(t).length>0){const c=Object.keys(t)[0];c&&o(c)}},[t,o,e,r]);const i=c=>{const l=String((c==null?void 0:c.value)||"");l&&s&&kv({selectedEmail:l,conversationId:s}),o(l)};return u.jsx(No,{options:a,value:e&&!r?{value:e,label:e}:null,placeholder:"Select an email",name:"email-selection",type:"select",onChange:i,components:{...No.getDefaultComponents(),MenuList:Rv,Option:Mv,SingleValue:Nv,DropdownIndicator:jv,ValueContainer:Pv},root:n,styles:Bv,isSearchable:!1,menuPortalTarget:document.body,isLoading:r})},Gv=d.styled(d.Paper)`
1092
+ `,Tv="https://cdn.hiverhq.com/connectors-module/assets/PlugIn.svg",Av={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1,VITE_HIVER_CDN_URL:"https://cdn.hiverhq.com/",VITE_MY_ENV_VAR:"myVariable From Agent"},{VITE_HIVER_CDN_URL:Lv}=Av,J1=({isAdmin:e=!0,hideHeading:t=!1})=>{const{sendTrackingEvent:n,availableFeatures:r,connectorFunctions:o}=w.useContext(Ge),s=et(r,N3),a=et(r,Ts),i=g=>{g.stopPropagation(),n(zm),o==null||o.redirectToAdmin()},c=g=>{g.stopPropagation(),n(Ym),window.open(fv,"_blank")},l=()=>{n(y3,{source:"main_tab"})},f=a?mv:gv;return u.jsxs(Cv,{"data-testid":"noConnectors",children:[s?u.jsxs(u.Fragment,{children:[t?null:u.jsx(d.Typography,{variant:"h2",children:a?Vi:yv}),u.jsx(Ev,{onClick:l,href:hv,target:"_blank",children:u.jsx(L8,{src:Lv+f,alt:bv,aspectRatio:"1000/783"})})]}):u.jsxs(xv,{children:[u.jsx(vv,{variant:"body1_medium",children:av}),u.jsx("img",{src:Tv,alt:iv})]}),u.jsx(Iv,{variant:"body2",children:cv}),e?u.jsx(Y1,{endIcon:u.jsx(d.icons.ArrowForward,{}),onClick:i,...s&&{size:"medium"},children:a?uv:lv}):u.jsxs(u.Fragment,{children:[u.jsx(Y1,{onClick:c,children:dv}),u.jsxs(wv,{direction:"row",children:[u.jsx(_v,{}),u.jsx(Sv,{variant:"caption",children:pv})]})]})]})},Ov=()=>{const{availableFeatures:e}=w.useContext(Ge),t=et(e,Ts);return u.jsxs(Rd,{children:[u.jsxs(d.Stack,{direction:"row",boxSizing:"content-box",paddingTop:"20px",paddingBottom:"12px",height:"36px",gap:"8px",alignItems:"center",children:[t?u.jsx(Fd,{width:"20px",height:"20px"}):u.jsx(Dd,{}),u.jsx(Nd,{variant:"h2",children:t?Vi:bd})]}),u.jsxs(d.Stack,{gap:"12px",children:[u.jsx(_n,{variant:"rounded",width:"100%",height:"46px",animation:"wave"}),u.jsx(_n,{variant:"rounded",width:"100%",height:"46px",animation:"wave"}),u.jsx(_n,{variant:"rounded",width:"100%",height:"46px",animation:"wave"})]})]})},Fv=()=>{const{metaData:e,sendTrackingEvent:t,isAdmin:n,connectorFunctions:r}=w.useContext(Ge),[o,s]=w.useState(!1),a=w.useRef(null),[i,c]=w.useState(0),{templateUpdates:l}=e||{},{sections:f=[],actionButtons:g=[],title:y}=l||{},{version:v=""}=l||{},b=o5(v),p=w.useMemo(()=>r5(v),[v]),h=w.useMemo(()=>(g==null?void 0:g.filter(({isAdminPanelLink:I})=>!(!n&&I)))??[],[g,n]);if(w.useEffect(()=>{!p&&l&&Wi(v,!0)},[p,v,l]),w.useLayoutEffect(()=>{var I;(I=a.current)!=null&&I.scrollHeight&&c(a.current.scrollHeight)},[a]),w.useEffect(()=>{l&&!b&&t(Um,{update_version_id:v})},[]),!l||b)return null;const m=I=>{var E;I.stopPropagation(),s(_=>!_),(E=a.current)!=null&&E.scrollHeight&&c(a.current.scrollHeight),Wi(v,!1,!0)},x=(I,E="",_=!1,T=!1)=>{var S;if(I.stopPropagation(),_&&T?t(Km,{update_version_id:v}):T&&t(e3,{update_version_id:v}),!_&&E){(S=window.open(E,"_blank"))==null||S.focus();return}C(I,!1),r==null||r.redirectToAdmin()},C=(I,E=!0)=>{I.stopPropagation(),Wi(v,!1),s(!1),E&&t(t3,{update_version_id:v})};return u.jsxs(o4,{children:[u.jsxs(s4,{children:[u.jsx(r4,{variant:"h3",children:y}),u.jsxs(d.Box,{children:[o?u.jsx(d.Tooltip,{title:z3,placement:"bottom",children:u.jsx(d.IconButton,{onClick:C,children:u.jsx(d.icons.Close,{sx:{height:"16px",width:"16px",opacity:"0.8"}})})}):null,u.jsx(d.Tooltip,{title:o?X3:Bi,placement:"bottom",children:u.jsx(Or,{onClick:m,children:u.jsx(Xi,{className:o?"":"hiver-up"})})})]})]}),u.jsx(a4,{className:o?"slideDown":"slideUp",ref:a,height:i,children:u.jsxs(i4,{children:[f.map(({title:I,items:E,type:_})=>u.jsxs(f4,{children:[u.jsx(d.Typography,{variant:"body2_medium",children:I}),E.map(T=>{const S=_===U3,{deeplink:L,textHtml:N,imageUrl:k}=T,D=()=>u.jsx(z5,{className:S?"":"ellipsisClass",component:"div",variant:"body2",dangerouslySetInnerHTML:{__html:N}});return u.jsx(c4,{component:"ul",children:u.jsxs(l4,{component:S?"li":"div",marginLeft:k?"0":"14px",children:[k?u.jsx("img",{src:k}):null,L?u.jsx(jd,{target:"_blank",underline:"none",onClick:j=>x(j,L),fontSize:"13px",children:D()}):D()]})},N)})]},I)),u.jsx(d.Stack,{flexDirection:"row",gap:"8px",marginBottom:"11.5px",children:h.map(({text:I,link:E,isAdminPanelLink:_})=>u.jsx(u4,{variant:_?"contained":"text",children:u.jsx(d4,{variant:"caption",onClick:T=>x(T,E,_,!0),children:I})},I))})]})})]})},kv=({selectedEmail:e,conversationId:t})=>Ae({url:P8.replace(":conversationId",""+t),method:je.PATCH,data:{selectedEmail:e}}),Dv="data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%200%2014%2014'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='7'%20cy='7'%20r='7'%20fill='%23196FE0'/%3e%3cpath%20d='M10.8288%204.89995C10.5922%204.64324%2010.1976%204.63193%209.94761%204.87601L5.96804%208.75823L4.06989%206.75353C3.82948%206.49981%203.43531%206.49425%203.18845%206.74158C2.9418%206.98865%202.9366%207.39455%203.1768%207.64827L5.50404%2010.1061C5.626%2010.235%205.78808%2010.3%205.95059%2010.3C6.10477%2010.3%206.25896%2010.2414%206.37969%2010.124L10.8056%205.80646C11.0553%205.56278%2011.0659%205.15689%2010.8288%204.89995Z'%20fill='white'/%3e%3c/svg%3e",q1=e=>{const t=w.useRef(null),[n,r]=w.useState(!1);return w.useEffect(()=>{t.current&&r(t.current.scrollWidth>t.current.clientWidth)},[e]),{textRef:t,isOverflow:n}},Nv=e=>{const{textRef:t,isOverflow:n}=q1(e.data.label);return u.jsx(d.Tooltip,{title:n?e.data.value:null,placement:"bottom",children:u.jsx(p4,{ref:t,variant:"body2",paddingTop:n?"5px":"0px",children:e.data.label})})},Rv=e=>u.jsxs(en.MenuList,{...e,children:[u.jsx(h4,{children:u.jsx(d.Typography,{variant:"body2_medium",children:V4})}),e.children]}),Mv=e=>{const{isSelected:t}=e,{textRef:n,isOverflow:r}=q1(e.data.label);return u.jsx(en.Option,{...e,children:u.jsxs(d.Stack,{direction:"row",gap:"5px",justifyContent:"space-between",alignItems:"center",children:[u.jsx(d.Tooltip,{title:r?e.data.value:null,placement:"bottom",children:u.jsx(g4,{ref:n,className:"dropdown-item-text",variant:"body2",children:e.data.label})}),t?u.jsx("img",{src:Dv,width:"14px",height:"14px"}):null]})})},Pv=e=>u.jsx(en.ValueContainer,{...e,children:u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"4px",children:[u.jsx(d.icons.AccountCircle,{sx:{height:"20px",width:"20px",color:d.theme.palette.gray.gray3,flexShrink:0}}),u.jsx(d.Stack,{direction:"row",alignItems:"center",sx:{flex:1,minWidth:0,overflow:"hidden"},children:e.children})]})}),jv=e=>u.jsx(en.DropdownIndicator,{...e,children:e.selectProps.menuIsOpen?u.jsx(d.icons.ArrowDropUp,{sx:{height:"18px",width:"18px",color:d.theme.palette.gray.gray3}}):u.jsx(d.icons.ArrowDropDown,{sx:{height:"18px",width:"18px",color:d.theme.palette.gray.gray3}})}),Bv={control:e=>({...e,border:`1px solid ${d.theme.palette.gray.gray5}`,borderRadius:"8px",boxShadow:"none",backgroundColor:d.theme.palette.gray.gray7,cursor:"pointer","& > :first-child":{"& > :first-child":{paddingTop:"0px"},"& > :nth-child(2)":{height:"0px"}}}),option:(e,t)=>({...e,backgroundColor:d.theme.palette.gray.white,color:d.theme.palette.gray.black,height:"36px",padding:"6px 16px","&:hover":{backgroundColor:t.isFocused?d.theme.palette.gray.gray7:d.theme.palette.gray.white}}),singleValue:e=>({...e}),menuList:e=>({...e,maxHeight:"160px",borderRadius:"4px",overflowX:"hidden"}),menu:e=>({...e,boxShadow:"0px 3px 15px 0px #00000040",marginTop:"3px"}),menuPortal:e=>({...e,zIndex:2,maxHeight:"160px"})},Vv=({selectedEmail:e,emailHeaders:t,root:n,isLoading:r,setSelectedEmail:o})=>{const{conversationId:s}=w.useContext(Ge),a=t?Object.entries(t).map(([c])=>({value:c,label:c})):e?[{value:e,label:e}]:[];w.useEffect(()=>{if(!e&&!r&&t&&Object.keys(t).length>0){const c=Object.keys(t)[0];c&&o(c)}},[t,o,e,r]);const i=c=>{const l=String((c==null?void 0:c.value)||"");l&&s&&kv({selectedEmail:l,conversationId:s}),o(l)};return u.jsx(d.Tooltip,{title:"Selected email",placement:"top",children:u.jsx("div",{style:{marginTop:"12px"},children:u.jsx(No,{options:a,value:e&&!r?{value:e,label:e}:null,placeholder:"Select an email",name:"email-selection",type:"select",onChange:i,components:{...No.getDefaultComponents(),MenuList:Rv,Option:Mv,SingleValue:Nv,DropdownIndicator:jv,ValueContainer:Pv},root:n,styles:Bv,isSearchable:!1,menuPortalTarget:document.body,isLoading:r})})})},Gv=d.styled(d.Paper)`
1093
1093
  width: stretch;
1094
1094
  height: 100%;
1095
1095
  position: absolute;
@@ -1289,7 +1289,7 @@ Do you want to continue?`,fx="Select an object to create",px="Select an object t
1289
1289
  `,XE="data:image/svg+xml,%3csvg%20width='124'%20height='107'%20viewBox='0%200%20124%20107'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M28.6168%2054.7446C28.6931%2052.5589%2031.0146%2051.1102%2033.0842%2051.8174C35.9985%2052.8133%2040.0375%2053.9024%2044.0621%2054.043C48.0034%2054.1806%2051.968%2053.4097%2054.8762%2052.6339C57.0264%2052.0602%2059.2927%2053.6932%2059.215%2055.9172C59.1742%2057.0856%2058.4742%2058.1269%2057.3723%2058.5178C54.8051%2059.4284%2049.7633%2060.8927%2044.3075%2060.7022C38.7694%2060.5088%2033.1999%2058.6241%2030.4004%2057.5311C29.2637%2057.0873%2028.5742%2055.9641%2028.6168%2054.7446Z'%20fill='url(%23paint0_linear_8481_102191)'/%3e%3cpath%20d='M47.223%2043.6373C44.4928%2030.7926%2052.6922%2018.1666%2065.5368%2015.4364C78.3815%2012.7062%2091.0075%2020.9055%2093.7377%2033.7502L105.079%2087.1053L84.1844%2091.5466C70.0346%2094.5542%2056.1258%2085.5217%2053.1182%2071.3719L47.223%2043.6373Z'%20fill='url(%23paint1_linear_8481_102191)'/%3e%3cmask%20id='mask0_8481_102191'%20style='mask-type:luminance'%20maskUnits='userSpaceOnUse'%20x='46'%20y='14'%20width='60'%20height='79'%3e%3cpath%20d='M47.223%2043.6373C44.4928%2030.7926%2052.6922%2018.1666%2065.5368%2015.4364C78.3815%2012.7062%2091.0075%2020.9055%2093.7377%2033.7502L105.079%2087.1053L84.1844%2091.5466C70.0346%2094.5542%2056.1258%2085.5217%2053.1182%2071.3719L47.223%2043.6373Z'%20fill='white'/%3e%3c/mask%3e%3cg%20mask='url(%23mask0_8481_102191)'%3e%3cellipse%20cx='63.7775'%20cy='46.8684'%20rx='1.48152'%20ry='1.39438'%20transform='rotate(-12%2063.7775%2046.8684)'%20fill='%23435C71'/%3e%3crect%20x='47.4368'%20y='59.3203'%20width='53.657'%20height='13.2235'%20transform='rotate(-12%2047.4368%2059.3203)'%20fill='url(%23paint2_linear_8481_102191)'/%3e%3crect%20x='51.1907'%20y='76.9824'%20width='53.657'%20height='10.4263'%20transform='rotate(-12%2051.1907%2076.9824)'%20fill='url(%23paint3_linear_8481_102191)'/%3e%3c/g%3e%3cpath%20opacity='0.883952'%20d='M113.939%2051.0679C114.775%2055%20112.265%2058.865%20108.333%2059.7008L107.842%2059.8052C103.639%2060.6986%2099.5073%2058.0155%2098.6139%2053.8123L97.205%2047.1837L105.307%2045.4616C109.239%2044.6259%20113.104%2047.1359%20113.939%2051.0679Z'%20fill='url(%23paint4_linear_8481_102191)'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M68.7215%2066.4138C67.1801%2064.8725%2067.6745%2062.2062%2069.587%2061.1603C72.4457%2059.5969%2076.2861%2057.1773%2079.3785%2054.0849C82.4099%2051.0535%2084.752%2047.3461%2086.2775%2044.5465C87.3388%2042.5989%2090.0598%2042.0819%2091.6282%2043.6503C92.4782%2044.5003%2092.758%2045.7623%2092.2604%2046.8566C91.0829%2049.4466%2088.5191%2054.344%2084.4346%2058.4285C80.2853%2062.5778%2074.8639%2065.591%2072.0553%2066.9952C70.9363%2067.5548%2069.6062%2067.2985%2068.7215%2066.4138Z'%20fill='url(%23paint5_linear_8481_102191)'/%3e%3crect%20x='48.7264'%20y='33.7744'%20width='11.2108'%20height='11.2108'%20rx='5.59457'%20transform='rotate(-12%2048.7264%2033.7744)'%20fill='url(%23paint6_linear_8481_102191)'/%3e%3crect%20x='50.0175'%20y='35.8193'%20width='4.0158'%20height='3.84848'%20rx='1.92424'%20transform='rotate(-12%2050.0175%2035.8193)'%20fill='%23435C71'/%3e%3crect%20x='59.2875'%20y='31.5723'%20width='11.2108'%20height='11.2108'%20rx='5.59457'%20transform='rotate(-12%2059.2875%2031.5723)'%20fill='%23FFFEFE'/%3e%3cpath%20opacity='0.883952'%20d='M111.25%2038.5376C110.415%2034.6055%20106.55%2032.0955%20102.618%2032.9313L102.127%2033.0356C97.9234%2033.9291%2095.2403%2038.0607%2096.1337%2042.2639L97.5426%2048.8925L105.644%2047.1705C109.576%2046.3347%20112.086%2042.4696%20111.25%2038.5376Z'%20fill='url(%23paint7_linear_8481_102191)'/%3e%3crect%20x='60.0181'%20y='33.8037'%20width='3.84848'%20height='3.84848'%20rx='1.90724'%20transform='rotate(-12%2060.0181%2033.8037)'%20fill='%23435C71'/%3e%3cpath%20d='M36.9246%2059.1604C36.4487%2060.717%2034.7371%2061.6271%2033.1805%2061.1512C32.3613%2060.9007%2031.7241%2060.3475%2031.3259%2059.5987L25.2059%2046.7983C24.9784%2046.3703%2025.1286%2045.8788%2025.5566%2045.6513L28.338%2044.1724C28.7659%2043.9449%2029.2574%2044.0951%2029.4849%2044.5231L36.6496%2056.8367C37.0728%2057.5036%2037.15%2058.423%2036.9246%2059.1604Z'%20fill='%23FFDF9F'/%3e%3crect%20x='27.9973'%20y='44.333'%20width='2.39869'%20height='3.59807'%20transform='rotate(152%2027.9973%2044.333)'%20fill='%23FF9090'/%3e%3cpath%20d='M26.6628%2044.3769L26.9472%2044.9118L28.0169%2044.343L26.3106%2041.1338L24.171%2042.2714L25.0243%2043.876C25.6661%2043.5347%2026.3215%2043.7351%2026.6628%2044.3769Z'%20fill='%23FFB19F'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M7.26386%2027.248C9.3428%2020.4481%2016.5101%2016.6372%2023.31%2018.7161C30.11%2020.7951%2033.9209%2027.9624%2031.8419%2034.7623C29.763%2041.5622%2022.5956%2045.3731%2015.7958%2043.2942C8.99587%2041.2152%205.18493%2034.0479%207.26386%2027.248ZM9.72157%2027.9983C8.06843%2033.4055%2011.1399%2039.1821%2016.5471%2040.8352C21.9543%2042.4884%2027.7309%2039.4168%2029.384%2034.0096C31.0372%2028.6024%2027.9657%2022.8258%2022.5585%2021.1727C17.1513%2019.5196%2011.3747%2022.5911%209.72157%2027.9983Z'%20fill='%23FFE69F'/%3e%3ccircle%20opacity='0.414016'%20cx='19.5529'%20cy='31.0039'%20r='10.2804'%20transform='rotate(17%2019.5529%2031.0039)'%20fill='%23BBDEFC'/%3e%3cpath%20d='M14.3685%2030.6746C15.7299%2027.6867%2018.9391%2025.9803%2022.1776%2026.5225L22.2595%2026.5475C23.7024%2026.8095%2024.3854%2024.8682%2023.1497%2024.2218C22.3806%2023.8074%2021.5613%2023.557%2020.717%2023.3884C17.3715%2022.9031%2014.0553%2024.6664%2012.6939%2027.6543C12.2796%2028.4235%2012.0859%2029.3497%2012.0244%2030.1372C11.8444%2031.6051%2013.8607%2032.0424%2014.4503%2030.6997C14.3434%2030.7566%2014.3685%2030.6746%2014.3685%2030.6746Z'%20fill='%23F6FBFF'/%3e%3cpath%20d='M10.2904%2029.0679C11.9436%2023.6607%2017.7202%2020.5893%2023.1274%2022.2424C25.6671%2023.0189%2027.5785%2024.6783%2028.9301%2026.704C27.7539%2024.1048%2025.508%2022.0744%2022.5586%2021.1727C17.1514%2019.5196%2011.3748%2022.591%209.72165%2027.9982C8.81993%2030.9476%209.32924%2033.97%2010.7444%2036.3735C9.82081%2034.1203%209.51395%2031.6077%2010.2904%2029.0679Z'%20fill='%23ADCBE7'/%3e%3cpath%20opacity='0.406087'%20d='M36.4864%2056.8021L36.1373%2056.2691C36.3845%2056.8563%2036.428%2057.5516%2036.2372%2058.1754C35.9273%2059.189%2034.5593%2059.1971%2034.0713%2058.2806L28.3787%2047.5877C28.0534%2046.9767%2027.3508%2046.7619%2026.7395%2047.0866L25.7206%2047.6277L31.4395%2059.3516C31.7648%2059.9627%2032.27%2060.5434%2032.8706%2060.8123C33.7054%2061.1528%2034.6593%2061.1034%2035.3726%2060.7247C36.0858%2060.3459%2036.6602%2059.5837%2036.8444%2058.7021C37.0351%2058.0783%2036.8117%2057.4132%2036.4864%2056.8021Z'%20fill='white'/%3e%3cpath%20d='M29.8826%2048.4977C29.8006%2048.4726%2029.6368%2048.4225%2029.5799%2048.3155L28.1579%2045.6411C28.0442%2045.4272%2028.1193%2045.1814%2028.3332%2045.0677C28.5472%2044.9539%2028.7929%2045.0291%2028.9067%2045.243L30.3287%2047.9174C30.4424%2048.1313%2030.3673%2048.3771%2030.1534%2048.4908C30.1284%2048.5728%2029.9645%2048.5227%2029.8826%2048.4977Z'%20fill='%23FFF5EB'/%3e%3cellipse%20cx='29.2637'%20cy='54.631'%20rx='1.50593'%20ry='3.17918'%20transform='rotate(-23%2029.2637%2054.631)'%20fill='%23FFC478'/%3e%3cellipse%20cx='34.0592'%20cy='52.4078'%20rx='0.920288'%20ry='1.67325'%20transform='rotate(106%2034.0592%2052.4078)'%20fill='%23FFC478'/%3e%3cpath%20d='M89.1282%2019.2055L68.2257%2026.8725L45.9197%2028.3898L44.4929%2016.4082C44.3371%2013.798%2047.5283%2011.4502%2050.9859%2011.6309L65.1429%2012.369L67.3969%2012.4869C68.5309%2012.5463%2069.7066%2012.3289%2070.7522%2011.8627L78.6899%208.34726C81.725%206.99992%2085.3012%207.87475%2086.2125%2010.1876L89.1282%2019.2055Z'%20fill='url(%23paint8_linear_8481_102191)'/%3e%3cpath%20opacity='0.479771'%20d='M88.6262%2019.0953L68.3101%2026.5288L65.3314%2012.5149L67.5211%2012.6263C68.6228%2012.6824%2069.7652%2012.471%2070.7816%2012.0192L78.4972%208.61266C81.4474%207.30707%2084.9208%208.14856%2085.8036%2010.3829L88.6262%2019.0953Z'%20fill='%23ADCBE7'/%3e%3cpath%20d='M91.6332%2026.6212L46.9517%2036.1186L46.0387%2028.4438L89.2535%2019.2582L91.6332%2026.6212Z'%20fill='%23717DAD'/%3e%3cpath%20d='M102.961%2024.2033C103.125%2024.9722%20102.371%2025.7829%20101.278%2026.015L37.9675%2039.4722C36.8754%2039.7043%2035.8568%2039.2704%2035.6933%2038.5015C35.5301%2037.7336%2036.284%2036.922%2037.3761%2036.6898L100.687%2023.2327C101.779%2023.0005%20102.798%2023.4354%20102.961%2024.2033Z'%20fill='%239ED1FF'/%3e%3cpath%20d='M102.703%2024.1718C102.838%2024.805%20102.067%2025.5045%20100.983%2025.7349L69.5583%2032.4144L69.0712%2030.123L100.496%2023.4436C101.58%2023.2131%20102.569%2023.5394%20102.703%2024.1718Z'%20fill='%2378AFE1'/%3e%3cdefs%3e%3clinearGradient%20id='paint0_linear_8481_102191'%20x1='32.2665'%20y1='59.6553'%20x2='59.0518'%20y2='60.5906'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23FFFDE0'/%3e%3cstop%20offset='1'%20stop-color='%23FFB362'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint1_linear_8481_102191'%20x1='67.3434'%20y1='85.966'%20x2='103.216'%20y2='78.3411'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23FFFABC'/%3e%3cstop%20offset='1'%20stop-color='%23FFA650'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint2_linear_8481_102191'%20x1='51.4347'%20y1='74.8197'%20x2='91.1539'%20y2='74.8197'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23A3C1FF'/%3e%3cstop%20offset='1'%20stop-color='%234243FF'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint3_linear_8481_102191'%20x1='55.1887'%20y1='89.2031'%20x2='94.9078'%20y2='89.2031'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23A3C1FF'/%3e%3cstop%20offset='1'%20stop-color='%234243FF'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint4_linear_8481_102191'%20x1='94.5023'%20y1='53.1799'%20x2='106.762'%20y2='58.7056'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23FF9498'/%3e%3cstop%20offset='1'%20stop-color='%23FFD671'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint5_linear_8481_102191'%20x1='74.9906'%20y1='66.9871'%20x2='94.9778'%20y2='46.9999'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23FFFDE0'/%3e%3cstop%20offset='1'%20stop-color='%23FFB362'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint6_linear_8481_102191'%20x1='50.5805'%20y1='44.0581'%20x2='59.9372'%20y2='44.0581'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='white'/%3e%3cstop%20offset='1'%20stop-color='%23E3EEF3'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint7_linear_8481_102191'%20x1='88.4187'%20y1='43.3906'%20x2='99.3981'%20y2='25.1833'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23FF9498'/%3e%3cstop%20offset='1'%20stop-color='%23FFD671'/%3e%3c/linearGradient%3e%3clinearGradient%20id='paint8_linear_8481_102191'%20x1='56.4985'%20y1='29.5482'%20x2='100.532'%20y2='20.1885'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23ECF7FF'/%3e%3cstop%20offset='1'%20stop-color='%23C2E0FF'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e",zE=()=>u.jsxs(d.Box,{justifyItems:"center",marginTop:"40px",children:[u.jsx("img",{src:XE,width:124,height:107}),u.jsx(d.Typography,{variant:"body2",color:d.theme.palette.gray.gray3,children:gE})]}),YE=({searchResults:e,selectedObject:t,onReset:n,fetchCards:r})=>{const o=Vt(),{sendTrackingEvent:s,currentSmIds:a}=w.useContext(Ge),[i,c]=w.useState(null),l=gt(pE,{count:e.length.toString(),countSuffix:e.length>1?"s":"",searchObject:t.objectName,connectorName:t.connectorName}),f=(v,b)=>{s(S3,{search_keyword:t.label,search_result_label:b,sm_ids:a,connector_name:t.connectorName}),c({externalResourceId:v,formId:t.value.toString(),searchKeyword:t.label,searchResultLabel:b})},g=()=>{c(null),o(W8())},y=()=>{n(),r(),g()};return e.length?i?u.jsx(ZE,{meta:i,onBack:g,onLink:y}):u.jsxs(d.Stack,{gap:"14px",marginTop:"12px",children:[u.jsx(d.Typography,{variant:"body2",children:l}),u.jsx(d.Stack,{gap:"17px",children:e==null?void 0:e.map(({externalResourceId:v,name:b,description:p})=>u.jsxs(yp,{onClick:()=>f(v,b),direction:"row",children:[u.jsxs(d.Stack,{flexGrow:1,children:[u.jsx(d.Typography,{variant:"body2",color:d.theme.palette.gray.gray1,children:b}),u.jsx(d.Typography,{variant:"caption",color:d.theme.palette.gray.gray3,children:p})]}),u.jsx(d.Box,{alignSelf:"center",className:"search-item__chevron",width:"20px",height:"20px",children:u.jsx("img",{src:BE})})]},v))})]}):u.jsx(zE,{})},Yc=d.styled(d.Skeleton)`
1290
1290
  display: block;
1291
1291
  margin: ${e=>e.margin?e.margin:0};
1292
- `,JE=()=>u.jsxs(d.Stack,{marginTop:"12px",children:[u.jsx(Yc,{variant:"rounded",width:"50%",height:"16px",animation:"wave",margin:"0 0 18px 0"}),u.jsx(d.Stack,{gap:"17px",children:u.jsxs(yp,{gap:"8px",disableHover:!0,children:[u.jsx(Yc,{variant:"rounded",width:"30%",height:"16px",animation:"wave"}),u.jsx(Yc,{variant:"rounded",width:"70%",height:"16px",animation:"wave"})]})})]});let Jc={};const qc=new Set,qE=(e,t)=>{Jc={...Jc,[e]:t},qc.forEach(n=>n())},$E=e=>(qc.add(e),()=>qc.delete(e)),QE=e=>w.useSyncExternalStore($E,()=>Jc)[e],UE=async({id:e,searchString:t,args:n})=>{try{if(e===void 0||t===void 0)return[];const r=await Ae({url:DE.replace(":formId",e.toString()),method:je.POST,data:{search_string:t,args:n}});let o=null;return r!=null&&r.data&&"data"in r.data&&(o=r.data.data),o}catch(r){Ie({message:hn,type:ze}),console.error(r)}},KE=(e,t)=>Yt({mutationFn:UE,onMutate:({searchString:n,connectorName:r})=>{e(n,r)},onSuccess:(n,{searchString:r,connectorName:o})=>{t(r,n,o)}}),$c={OPEN_FORM_VIEW:"connector-agent-open-form-view"},eI=(e,t={})=>{const{delayAfterLoad:n=1e3}=t,r=w.useRef(!1),o=w.useRef(void 0),s=w.useCallback((c="auto")=>{const l=e.current;l&&l.scrollIntoView({behavior:c})},[e]),a=w.useCallback((c,l="smooth")=>{r.current||(o.current!==void 0&&clearTimeout(o.current),c&&(o.current=setTimeout(()=>{s(l),r.current=!0},n)))},[s,n]),i=w.useCallback(()=>{r.current=!1,o.current!==void 0&&clearTimeout(o.current)},[]);return w.useEffect(()=>()=>{o.current!==void 0&&clearTimeout(o.current)},[]),{scrollOnceAfterLoad:a,resetScrollState:i,hasScrolledOnce:r.current}},tI=e=>A.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},A.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.86993 0.652446C7.56922 0.248711 8.43078 0.248711 9.13007 0.652446L13.7981 3.34755C14.4974 3.75129 14.9282 4.49742 14.9282 5.30489V10.6951C14.9282 11.5026 14.4974 12.2487 13.7981 12.6524L9.13007 15.3476C8.43078 15.7513 7.56922 15.7513 6.86993 15.3476L2.20187 12.6524C1.50258 12.2487 1.0718 11.5026 1.0718 10.6951V5.30489C1.0718 4.49742 1.50258 3.75129 2.20187 3.34755L6.86993 0.652446Z",fill:"#FFD122"}),A.createElement("g",{filter:"url(#filter0_d_360_39563)"},A.createElement("path",{d:"M5.83154 4.43359V4.43359C6.84296 4.43359 7.66287 5.25351 7.66287 6.26492V11.5179V11.5179C6.65146 11.5179 5.83154 10.698 5.83154 9.68661V4.43359Z",fill:"white"})),A.createElement("g",{filter:"url(#filter1_d_360_39563)"},A.createElement("path",{d:"M8.57812 7.66211V7.66211C9.58954 7.66211 10.4095 8.48202 10.4095 9.49343V11.7103V11.7103C9.39804 11.7103 8.57812 10.8904 8.57812 9.87898V7.66211Z",fill:"white"})),A.createElement("defs",null,A.createElement("filter",{id:"filter0_d_360_39563",x:4.76488,y:3.36693,width:3.96488,height:9.21732,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},A.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),A.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),A.createElement("feOffset",null),A.createElement("feGaussianBlur",{stdDeviation:.533333}),A.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.114019 0"}),A.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_360_39563"}),A.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_360_39563",result:"shape"})),A.createElement("filter",{id:"filter1_d_360_39563",x:7.51146,y:6.59544,width:3.96488,height:6.18216,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},A.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),A.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),A.createElement("feOffset",null),A.createElement("feGaussianBlur",{stdDeviation:.533333}),A.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.114019 0"}),A.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_360_39563"}),A.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_360_39563",result:"shape"})))),nI="/v1/api/connectors/lookup/bulk",rI="/v1/api/connectors/lookup/bulk",oI=async e=>{const t=new URLSearchParams;e.forEach(o=>t.append("connector_ids",o));const n=`${nI}?${t.toString()}`;console.log("[fetchBulkLookupConfigs] GET",n);const r=await Ae({url:n,method:je.GET});return console.log("[fetchBulkLookupConfigs] response",r),r==null?void 0:r.data},sI=async e=>{const t=await Ae({url:rI,method:je.PUT,data:{entries:e}});return t==null?void 0:t.data},aI={fontSize:"14px",width:"209px",height:"40px",background:"#F6F8FC",borderRadius:"8px",fontWeight:400,"& .MuiOutlinedInput-notchedOutline":{borderColor:"#ECEFF6"}},iI={border:`1px solid ${d.theme.palette.gray.gray5}`,borderRadius:"8px",padding:"12px"},Cp={flex:1,height:"1px",backgroundColor:d.theme.palette.gray.gray6},cI={flexShrink:0,border:`1px solid ${d.theme.palette.gray.gray6}`,borderRadius:"15px"},lI={border:`1px solid ${d.theme.palette.gray.gray6}`,backgroundColor:d.theme.palette.gray.gray6a,borderRadius:"8px",padding:"8px 10px"},uI=w.memo(function({connector:t,selectedHiverParam:n,onChange:r}){var a;const o=((a=(t.presets??[]).find(i=>i.hiverParam===n))==null?void 0:a.objectParamLabel)??"",s=w.useCallback(i=>{r(t.connectorId,i.target.value)},[t.connectorId,r]);return u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"0px",justifyContent:"space-between",children:[u.jsx(d.Select,{value:n,onChange:s,size:"small",variant:"outlined",sx:aI,MenuProps:{sx:{zIndex:1500}},renderValue:i=>{var l;const c=((l=(t.presets??[]).find(f=>f.hiverParam===i))==null?void 0:l.label)??"";return u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"8px",children:[u.jsx(tI,{width:18,height:18}),u.jsx("span",{children:c})]})},children:(t.presets??[]).map(i=>u.jsx(d.MenuItem,{value:i.hiverParam,sx:{fontSize:"14px"},children:i.label},i.hiverParam))}),u.jsx(d.Box,{sx:Cp}),u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"4px",padding:"4px 12px",sx:cI,children:[t.logo&&u.jsx("img",{src:t.logo,width:16,height:16,alt:t.connectorName}),u.jsxs(d.Typography,{variant:"body2",color:d.theme.palette.gray.gray3,children:["Matches with ",t.connectorName,"'s"]})]}),u.jsx(d.Box,{sx:Cp}),u.jsx(d.Box,{sx:lI,children:u.jsx(d.Typography,{variant:"body2",fontSize:14,children:o})})]})}),dI=w.memo(function({open:t,onClose:n,connectors:r,onSaveSuccess:o}){const[s,a]=w.useState({});w.useEffect(()=>{if(t&&r.length>0){const v={};r.filter(b=>{var p;return((p=b.presets)==null?void 0:p.length)>1}).forEach(b=>{v[b.connectorId]=b.hiverParam}),a(v)}},[t,r]);const i=is(),{mutate:c,isPending:l}=Yt({mutationFn:sI,onSuccess:v=>{const b={};v.results.forEach(({connectorId:p,hiverParam:h})=>{b[p]=h}),i.setQueriesData({queryKey:["lookup","bulk"]},p=>p&&{...p,connectors:p.connectors.map(h=>b[h.connectorId]!==void 0?{...h,hiverParam:b[h.connectorId]}:h)}),Ie({message:"Identity mapping saved successfully",type:"success"}),o==null||o(),n()},onError:()=>{Ie({message:"Failed to save identity mapping",type:"error"})}}),f=w.useCallback(()=>{const v=Object.entries(s).map(([b,p])=>({connector_id:b,hiver_param:p}));c(v)},[s,c]),g=w.useCallback((v,b)=>{a(p=>({...p,[v]:b}))},[]),y=w.useCallback(v=>{v||n()},[n]);return u.jsx(ir,{shown:t,setShown:y,showCloseButton:!1,children:u.jsxs(d.Stack,{padding:"24px 20px",gap:"16px",sx:{minWidth:"800px"},children:[u.jsx(d.Typography,{variant:"h2",children:"Customer identity mapping"}),u.jsx(d.Typography,{variant:"body2",children:"Choose how Hiver should identify customers when fetching data from connected apps."}),r.some(v=>{var b;return((b=v.presets)==null?void 0:b.length)>1})&&u.jsx(d.Stack,{gap:"8px",sx:iI,children:r.filter(v=>{var b;return((b=v.presets)==null?void 0:b.length)>1}).map(v=>u.jsx(uI,{connector:v,selectedHiverParam:s[v.connectorId]??v.hiverParam,onChange:g},v.connectorId))}),u.jsxs(d.Stack,{direction:"row",justifyContent:"flex-end",gap:"8px",children:[u.jsx(d.Button,{variant:"text",onClick:n,children:"Cancel"}),u.jsx(d.Button,{variant:"contained",onClick:f,disabled:l,children:"Save"})]})]})})}),fI=({enabled:e,...t})=>{const{actionQueue:n}=w.useContext(Ge);n&&e&&n.register(t),w.useEffect(()=>{if(n)return()=>{n.destroy()}},[n,e])},pI=({isAdmin:e=!1})=>{var Pa,O;const{email:t,currentSmIds:n,sendTrackingEvent:r,availableFeatures:o,conversationId:s}=w.useContext(Ge),a=Vt(),{userGroupId:i,userId:c}=Bt()||{},l=w.useRef(!1),f=w.useRef(null),g=w.useRef(null),y=w.useRef(null),[v,b]=w.useState({}),[p,h]=w.useState(!1),[m,x]=w.useState(!1),[C,I]=w.useState(!1),[E,_]=w.useState(!1),[T,S]=w.useState(),[L,N]=w.useState(!1),[k,D]=w.useState(null),[j,G]=w.useState(),[Y,$]=w.useState(null),[Q,z]=w.useState(!1),[q,oe]=w.useState(!1),[ae,V]=w.useState(!1),R=be(Ix),H=be(wx),W=be(Sx),J=be(Tx),re=be(Lx),se=be(_x),B=be(H1),ee=be(Hx),ve=be(W1),X=be(Z1),Be=be(X1),De=be(Xv),Je=w.useMemo(()=>R?[...new Set(R.map(M=>M.connectorId).filter(Boolean))]:[],[R]),at=et(o,D3),cn=et(o,fd),xt=et(o,B3),Ke=et(o,G3),Qe=et(o,H3),jn=et(o,W3),zt=(Pa=Bt())==null?void 0:Pa.tenantPlatform,br=et(o,zt==="HIVERWEB"?`hot-${pd}`:pd),{data:ln,isSuccess:yr}=Er({queryKey:["lookup","bulk",Je.join(",")],queryFn:()=>oI(Je),enabled:Je.length>0&&br,refetchOnMount:!1}),Bn=yr&&((ln==null?void 0:ln.connectors)??[]).some(M=>{var Z;return(((Z=M.presets)==null?void 0:Z.length)??0)>1});fI({conversationId:s,openCreateForm:()=>I(!0),enabled:H});const de=w.useMemo(()=>!R||!R.length?null:Dx(R,W,J),[R,W,J]),Ee=s5(W),{data:rt,isLoading:it}=mp({senderEmail:t,conversationId:String(s),enabled:Ke&&!!t}),{emailHeaders:Ot,selectedEmail:Vn}=rt??{},{scrollOnceAfterLoad:Cn,resetScrollState:ro}=eI(g),La=se!==K.LOADING&&(!J||!Object.values(J).some(M=>M===K.LOADING))&&R&&R.length>0;w.useLayoutEffect(()=>{var M;Q&&!p&&q&&((M=y==null?void 0:y.current)!=null&&M.scrollHeight)&&Cn(!!La,"smooth")},[Q,p,q,La,Cn,(O=y==null?void 0:y.current)==null?void 0:O.scrollHeight,c]);const ll=(M,Z)=>{r(I3,{search_keyword:M,sm_ids:n,connector_name:Z,suggestion_type:De})},ul=(M,Z,te)=>{!Array.isArray(Z)||!Z.length?r(w3,{search_keyword:M,sm_ids:n,connector_name:te,suggestion_type:De}):Z.length&&r(_3,{num_of_results:Z.length,search_keyword:M,sm_ids:n,connector_name:te,suggestion_type:De})},{mutate:dl,reset:oo,data:Oa,isPending:Gn,isIdle:Zo}=KE(ll,ul),so=w.useCallback(()=>{oo(),D(null)},[oo,D]),un=w.useCallback(()=>{t&&n.length&&s&&a(Ia({inboxIds:n,conversationId:s}))},[a,t,n,s]),Fa=w.useCallback((M,Z)=>{M&&s&&Z&&a(Ea({id:M,channelType:"email",conversationId:s,externalResourceId:Z,contactEmail:t})).unwrap().catch(()=>{a(Gr(null))})},[a,s,t]);if(w.useEffect(()=>{(async()=>{c&&(z(await fi(c)),oe(await cu(c)))})()},[c]),w.useEffect(()=>{it||G(Vn||t)},[t,Vn,it]),w.useEffect(()=>{j&&s&&qE(String(s),j)},[j,s]),w.useEffect(()=>{q&&c&&lu(c)},[q,c]),w.useEffect(()=>{var M;if(X){x(!0);const{externalResourceId:Z}=X,te=(M=X.forms.find(ge=>ge.type==="edit"))==null?void 0:M.id;Fa(te,Z)}else x(!1),a(yx())},[X,Fa,a]),w.useEffect(()=>(un(),ro(),()=>{a(V1.clearConnectorList())}),[a,un,ro]),w.useEffect(()=>{if(re&&R&&R.length&&de&&!l.current){const{cards_per_app:M,total_empty_cards:Z,total_cards_with_errors:te}=de;r(Qm,{numOfCards:R.length,total_cards_loaded:R.length,total_empty_cards:Z,total_cards_with_errors:te,cards_per_app:M,sm_ids:n}),l.current=!0}return()=>{l.current=!1}},[re,R,de,r,n]),w.useEffect(()=>{s&&n&&n.length&&a(ba({inboxIds:n,conversationId:s,channelType:"email",isExpandedFormEnabled:jn}))},[a,n,s,jn]),w.useEffect(()=>{const M=Z=>{var ge;if(!(Z instanceof CustomEvent))return;const te=(ge=Z.detail)==null?void 0:ge.connectorKey;b({connectorKey:te})};return window.addEventListener($c.OPEN_FORM_VIEW,M),()=>{window.removeEventListener($c.OPEN_FORM_VIEW,M)}},[]),w.useEffect(()=>{if(!(B!=null&&B.length)||!v.connectorKey)return;const M=v.connectorKey;b({});const Z=B.find(te=>{var ge;return((ge=te.connectorKey)==null?void 0:ge.toLowerCase())===(M==null?void 0:M.toLowerCase())});Z&&($(Z),I(!0))},[B,v]),!t.length||se===K.LOADING)return u.jsx(Ov,{});const ka=M=>{r(n3,{connector_name:ee,source:M,sm_ids:n})},Da=M=>{I(!0),ka(M)},Na=()=>{_(!0),r(r3)},Xo=M=>{r(M,T),Be?N(!0):(I(!1),$(null))},Ra=M=>{if(X){const{connectorName:Z,title:te}=X;r(M,{connector_name:Z,card_title:te,sm_ids:n,ug_id:i})}Be?N(!0):a(Gr(null))},fl=()=>{I(!1),a(Gr(null)),S(void 0),N(!1)},zo=()=>{un(),a(V1.clearConnectorList())},Ma=[{label:"Go back",variant:"text",action:fl},{label:"Stay",variant:"contained",action:()=>N(!1)}],Yo=B.length>0,Jo=ve.length>0,pl=()=>Yo||Jo?u.jsx(sE,{haveCreateObjects:Yo,haveLinkObjects:Jo,onCreateClick:()=>Da(_d.MAIN_BUTTON),onLinkClick:()=>_(!0)}):u.jsx(J1,{isAdmin:e,hideHeading:!0});return u.jsxs(Rd,{ref:f,"data-testid":Array.isArray(R)?"connector-agent":"loading",id:"connector-agent-container",stopOverflow:C||E,children:[u.jsx(sp,{shown:L,setShown:N,title:ux,description:dx,buttons:Ma}),u.jsx(j5,{onWheel:()=>h(!0),ref:y,children:H?u.jsxs(u.Fragment,{children:[u.jsx(m4,{connectors:Ee,isWriteFlowEnabled:cn,haveCreateObjects:Yo,haveLinkObjects:Jo,cards:R,handleCreateNewObject:()=>Da(_d.ICON),handleLinkNewObject:Na}),xt?u.jsx(jE,{selectedObject:k,setSelectedObject:D,fetchSearchResults:dl,onReset:so,root:f.current}):null,u.jsxs(Hr,{children:[u.jsx(Wr,{condition:xt&&Gn,children:u.jsx(JE,{})},"search"),u.jsx(Wr,{condition:xt&&!!k&&!Zo,children:u.jsx(YE,{searchResults:Oa??[],selectedObject:k,onReset:so,fetchCards:un})},"results"),u.jsxs(Wr,{fallback:!0,children:[Ke&&(R!=null&&R.length)?u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"8px",children:[u.jsx(d.Stack,{sx:{flex:1,minWidth:0},children:u.jsx(Vv,{emailHeaders:Ot,selectedEmail:j,root:f.current,isLoading:it,setSelectedEmail:G})}),br&&Bn&&e&&u.jsx(d.Tooltip,{title:"Settings",placement:"bottom",children:u.jsx(d.IconButton,{sx:{height:"32px",width:"32px",marginTop:"12px",flexShrink:0},onClick:()=>V(!0),children:u.jsx(d.icons.SettingsOutlined,{sx:{height:"20px",width:"20px"}})})})]}):null,!Ke&&br&&Bn&&e&&(R!=null&&R.length)?u.jsx(d.Button,{fullWidth:!0,variant:"contained",startIcon:u.jsx(d.icons.SettingsOutlined,{sx:{height:"14px",width:"14px"}}),sx:{backgroundColor:"#edf1f6",color:"#4d596c",borderRadius:"6px",padding:"9px 12px",marginTop:"12px",textTransform:"none",fontWeight:500,fontSize:"14px",lineHeight:"20px",boxShadow:"none","&:hover":{backgroundColor:"#e2e8f0",boxShadow:"none"}},onClick:()=>V(!0),children:"Customer identity mapping"}):null,at?u.jsx(Fv,{}):null,u.jsxs(Hr,{children:[u.jsxs(Wr,{condition:!!R&&R.length>0,children:[u.jsx(sv,{cards:R,specificCardData:W,email:j??"",specificConnectorApiStatus:J,onCardUnlinking:un}),u.jsx("div",{ref:g,children:Qe?u.jsx(b5,{connectors:Ee,expanded:Q}):null})]},"cards-list"),u.jsx(Wr,{condition:!(R!=null&&R.length)&&cn,children:pl()},"create-banner")]})]},"cards")]})]}):u.jsx(J1,{isAdmin:e})}),u.jsx(Zc,{onClose:()=>Ra(m3),isOpen:m,setIsOpen:x,title:Q3,portalId:"connector-layover-portal",backButtonTooltip:"Back",children:u.jsx(ip,{isEdit:!0,onClose:()=>Ra(g3),onCreateSuccess:zo,metaData:T,setMetaData:S,connectors:Ee})}),u.jsx(Zc,{onClose:()=>Xo(l3),portalId:"connector-layover-portal",isOpen:C,setIsOpen:I,children:u.jsx(ip,{onClose:()=>Xo(c3),onCreateSuccess:zo,metaData:T,setMetaData:S,defaultOption:Y,connectors:Ee})}),u.jsx(Zc,{onClose:()=>_(!1),portalId:"connector-layover-portal",isOpen:E,setIsOpen:_,children:u.jsx(eE,{setOpenTaskLinking:_,onLinkingSuccess:un})}),!H&&u.jsx(L5,{}),u.jsx(dI,{open:ae,onClose:()=>V(!1),connectors:(ln==null?void 0:ln.connectors)??[],onSaveSuccess:un})]})},hI=({children:e,sendTrackingEvent:t,contactEmail:n,baseUrls:r={},currentSmIds:o=[],userEmail:s,metaData:a,availableFeatures:i,conversationId:c,connectorFunctions:l,stackingContext:f,isAdmin:g=!1,actionQueue:y})=>{const v=w.useMemo(()=>({userEmail:s,email:n,baseUrls:r,currentSmIds:o,metaData:a,conversationId:c,sendTrackingEvent:t||(()=>{}),availableFeatures:i,isAdmin:g,connectorFunctions:l,stackingContext:f,actionQueue:y}),[s,n,r,t,o,a,i,c,g,l,f,y]);return u.jsx(Ge.Provider,{value:v,children:e})},Qc=({children:e})=>{const[t]=w.useState(()=>new S2);return u.jsx(F2,{client:t,children:e})},gI=Qd({cardList:Bx,write:Cx,common:X8}),Uc=Mb({reducer:gI,devTools:!0}),mI=({children:e,userEmail:t,extraParams:n,contactEmail:r,baseUrls:o,availableFeatures:s,connectorFunctions:a,stackingContext:i,actionQueue:c})=>u.jsx($i,{store:Uc,children:u.jsx(d.HiverProvider,{custom:!0,children:u.jsx(Qc,{children:u.jsx(hI,{userEmail:t,availableFeatures:s,sendTrackingEvent:n==null?void 0:n.sendTrackingEvent,contactEmail:r,currentSmIds:n==null?void 0:n.currentSmIds,metaData:n==null?void 0:n.metaData,conversationId:n==null?void 0:n.conversationId,baseUrls:o,connectorFunctions:a,stackingContext:i,actionQueue:c,isAdmin:n==null?void 0:n.isAdmin,children:u.jsx(w.Suspense,{fallback:u.jsx(u.Fragment,{}),children:e})})})})}),Kc=d.styled(d.Box)`
1292
+ `,JE=()=>u.jsxs(d.Stack,{marginTop:"12px",children:[u.jsx(Yc,{variant:"rounded",width:"50%",height:"16px",animation:"wave",margin:"0 0 18px 0"}),u.jsx(d.Stack,{gap:"17px",children:u.jsxs(yp,{gap:"8px",disableHover:!0,children:[u.jsx(Yc,{variant:"rounded",width:"30%",height:"16px",animation:"wave"}),u.jsx(Yc,{variant:"rounded",width:"70%",height:"16px",animation:"wave"})]})})]});let Jc={};const qc=new Set,qE=(e,t)=>{Jc={...Jc,[e]:t},qc.forEach(n=>n())},$E=e=>(qc.add(e),()=>qc.delete(e)),QE=e=>w.useSyncExternalStore($E,()=>Jc)[e],UE=async({id:e,searchString:t,args:n})=>{try{if(e===void 0||t===void 0)return[];const r=await Ae({url:DE.replace(":formId",e.toString()),method:je.POST,data:{search_string:t,args:n}});let o=null;return r!=null&&r.data&&"data"in r.data&&(o=r.data.data),o}catch(r){Ie({message:hn,type:ze}),console.error(r)}},KE=(e,t)=>Yt({mutationFn:UE,onMutate:({searchString:n,connectorName:r})=>{e(n,r)},onSuccess:(n,{searchString:r,connectorName:o})=>{t(r,n,o)}}),$c={OPEN_FORM_VIEW:"connector-agent-open-form-view"},eI=(e,t={})=>{const{delayAfterLoad:n=1e3}=t,r=w.useRef(!1),o=w.useRef(void 0),s=w.useCallback((c="auto")=>{const l=e.current;l&&l.scrollIntoView({behavior:c})},[e]),a=w.useCallback((c,l="smooth")=>{r.current||(o.current!==void 0&&clearTimeout(o.current),c&&(o.current=setTimeout(()=>{s(l),r.current=!0},n)))},[s,n]),i=w.useCallback(()=>{r.current=!1,o.current!==void 0&&clearTimeout(o.current)},[]);return w.useEffect(()=>()=>{o.current!==void 0&&clearTimeout(o.current)},[]),{scrollOnceAfterLoad:a,resetScrollState:i,hasScrolledOnce:r.current}},tI=e=>A.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},A.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.86993 0.652446C7.56922 0.248711 8.43078 0.248711 9.13007 0.652446L13.7981 3.34755C14.4974 3.75129 14.9282 4.49742 14.9282 5.30489V10.6951C14.9282 11.5026 14.4974 12.2487 13.7981 12.6524L9.13007 15.3476C8.43078 15.7513 7.56922 15.7513 6.86993 15.3476L2.20187 12.6524C1.50258 12.2487 1.0718 11.5026 1.0718 10.6951V5.30489C1.0718 4.49742 1.50258 3.75129 2.20187 3.34755L6.86993 0.652446Z",fill:"#FFD122"}),A.createElement("g",{filter:"url(#filter0_d_360_39563)"},A.createElement("path",{d:"M5.83154 4.43359V4.43359C6.84296 4.43359 7.66287 5.25351 7.66287 6.26492V11.5179V11.5179C6.65146 11.5179 5.83154 10.698 5.83154 9.68661V4.43359Z",fill:"white"})),A.createElement("g",{filter:"url(#filter1_d_360_39563)"},A.createElement("path",{d:"M8.57812 7.66211V7.66211C9.58954 7.66211 10.4095 8.48202 10.4095 9.49343V11.7103V11.7103C9.39804 11.7103 8.57812 10.8904 8.57812 9.87898V7.66211Z",fill:"white"})),A.createElement("defs",null,A.createElement("filter",{id:"filter0_d_360_39563",x:4.76488,y:3.36693,width:3.96488,height:9.21732,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},A.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),A.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),A.createElement("feOffset",null),A.createElement("feGaussianBlur",{stdDeviation:.533333}),A.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.114019 0"}),A.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_360_39563"}),A.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_360_39563",result:"shape"})),A.createElement("filter",{id:"filter1_d_360_39563",x:7.51146,y:6.59544,width:3.96488,height:6.18216,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},A.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),A.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),A.createElement("feOffset",null),A.createElement("feGaussianBlur",{stdDeviation:.533333}),A.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.114019 0"}),A.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_360_39563"}),A.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_360_39563",result:"shape"})))),nI="/v1/api/connectors/lookup/bulk",rI="/v1/api/connectors/lookup/bulk",oI=async e=>{const t=new URLSearchParams;e.forEach(o=>t.append("connector_ids",o));const n=`${nI}?${t.toString()}`;console.log("[fetchBulkLookupConfigs] GET",n);const r=await Ae({url:n,method:je.GET});return console.log("[fetchBulkLookupConfigs] response",r),r==null?void 0:r.data},sI=async e=>{const t=await Ae({url:rI,method:je.PUT,data:{entries:e}});return t==null?void 0:t.data},aI={fontSize:"14px",width:"209px",height:"40px",background:"#F6F8FC",borderRadius:"8px",fontWeight:400,"& .MuiOutlinedInput-notchedOutline":{borderColor:"#ECEFF6"}},iI={border:`1px solid ${d.theme.palette.gray.gray5}`,borderRadius:"8px",padding:"12px"},Cp={flex:1,height:"1px",backgroundColor:d.theme.palette.gray.gray6},cI={flexShrink:0,border:`1px solid ${d.theme.palette.gray.gray6}`,borderRadius:"15px"},lI={border:`1px solid ${d.theme.palette.gray.gray6}`,backgroundColor:d.theme.palette.gray.gray6a,borderRadius:"8px",padding:"8px 10px"},uI=w.memo(function({connector:t,selectedHiverParam:n,onChange:r}){var a;const o=((a=(t.presets??[]).find(i=>i.hiverParam===n))==null?void 0:a.objectParamLabel)??"",s=w.useCallback(i=>{r(t.connectorId,i.target.value)},[t.connectorId,r]);return u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"0px",justifyContent:"space-between",children:[u.jsx(d.Select,{value:n,onChange:s,size:"small",variant:"outlined",sx:aI,MenuProps:{sx:{zIndex:1500}},renderValue:i=>{var l;const c=((l=(t.presets??[]).find(f=>f.hiverParam===i))==null?void 0:l.label)??"";return u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"8px",children:[u.jsx(tI,{width:18,height:18}),u.jsx("span",{children:c})]})},children:(t.presets??[]).map(i=>u.jsx(d.MenuItem,{value:i.hiverParam,sx:{fontSize:"14px"},children:i.label},i.hiverParam))}),u.jsx(d.Box,{sx:Cp}),u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"4px",padding:"4px 12px",sx:cI,children:[t.logo&&u.jsx("img",{src:t.logo,width:16,height:16,alt:t.connectorName}),u.jsxs(d.Typography,{variant:"body2",color:d.theme.palette.gray.gray3,children:["Matches with ",t.connectorName,"'s"]})]}),u.jsx(d.Box,{sx:Cp}),u.jsx(d.Box,{sx:lI,children:u.jsx(d.Typography,{variant:"body2",fontSize:14,children:o})})]})}),dI=w.memo(function({open:t,onClose:n,connectors:r,onSaveSuccess:o}){const[s,a]=w.useState({});w.useEffect(()=>{if(t&&r.length>0){const v={};r.filter(b=>{var p;return((p=b.presets)==null?void 0:p.length)>1}).forEach(b=>{v[b.connectorId]=b.hiverParam}),a(v)}},[t,r]);const i=is(),{mutate:c,isPending:l}=Yt({mutationFn:sI,onSuccess:v=>{const b={};v.results.forEach(({connectorId:p,hiverParam:h})=>{b[p]=h}),i.setQueriesData({queryKey:["lookup","bulk"]},p=>p&&{...p,connectors:p.connectors.map(h=>b[h.connectorId]!==void 0?{...h,hiverParam:b[h.connectorId]}:h)}),Ie({message:"Identity mapping saved successfully",type:"success"}),o==null||o(),n()},onError:()=>{Ie({message:"Failed to save identity mapping",type:"error"})}}),f=w.useCallback(()=>{const v=Object.entries(s).map(([b,p])=>({connector_id:b,hiver_param:p}));c(v)},[s,c]),g=w.useCallback((v,b)=>{a(p=>({...p,[v]:b}))},[]),y=w.useCallback(v=>{v||n()},[n]);return u.jsx(ir,{shown:t,setShown:y,showCloseButton:!1,children:u.jsxs(d.Stack,{padding:"24px 20px",gap:"16px",sx:{minWidth:"800px"},children:[u.jsx(d.Typography,{variant:"h2",children:"Customer identity mapping"}),u.jsx(d.Typography,{variant:"body2",children:"Choose how Hiver should identify customers when fetching data from connected apps."}),r.some(v=>{var b;return((b=v.presets)==null?void 0:b.length)>1})&&u.jsx(d.Stack,{gap:"8px",sx:iI,children:r.filter(v=>{var b;return((b=v.presets)==null?void 0:b.length)>1}).map(v=>u.jsx(uI,{connector:v,selectedHiverParam:s[v.connectorId]??v.hiverParam,onChange:g},v.connectorId))}),u.jsxs(d.Stack,{direction:"row",justifyContent:"flex-end",gap:"8px",children:[u.jsx(d.Button,{variant:"text",onClick:n,children:"Cancel"}),u.jsx(d.Button,{variant:"contained",onClick:f,disabled:l,children:"Save"})]})]})})}),fI=({enabled:e,...t})=>{const{actionQueue:n}=w.useContext(Ge);n&&e&&n.register(t),w.useEffect(()=>{if(n)return()=>{n.destroy()}},[n,e])},pI=({isAdmin:e=!1})=>{var Pa,O;const{email:t,currentSmIds:n,sendTrackingEvent:r,availableFeatures:o,conversationId:s}=w.useContext(Ge),a=Vt(),{userGroupId:i,userId:c}=Bt()||{},l=w.useRef(!1),f=w.useRef(null),g=w.useRef(null),y=w.useRef(null),[v,b]=w.useState({}),[p,h]=w.useState(!1),[m,x]=w.useState(!1),[C,I]=w.useState(!1),[E,_]=w.useState(!1),[T,S]=w.useState(),[L,N]=w.useState(!1),[k,D]=w.useState(null),[j,G]=w.useState(),[Y,$]=w.useState(null),[Q,z]=w.useState(!1),[q,oe]=w.useState(!1),[ae,V]=w.useState(!1),R=be(Ix),H=be(wx),W=be(Sx),J=be(Tx),re=be(Lx),se=be(_x),B=be(H1),ee=be(Hx),ve=be(W1),X=be(Z1),Be=be(X1),De=be(Xv),Je=w.useMemo(()=>R?[...new Set(R.map(M=>M.connectorId).filter(Boolean))]:[],[R]),at=et(o,D3),cn=et(o,fd),xt=et(o,B3),Ke=et(o,G3),Qe=et(o,H3),jn=et(o,W3),zt=(Pa=Bt())==null?void 0:Pa.tenantPlatform,br=et(o,zt==="HIVERWEB"?`hot-${pd}`:pd),{data:ln,isSuccess:yr}=Er({queryKey:["lookup","bulk",Je.join(",")],queryFn:()=>oI(Je),enabled:Je.length>0&&br,refetchOnMount:!1}),Bn=yr&&((ln==null?void 0:ln.connectors)??[]).some(M=>{var Z;return(((Z=M.presets)==null?void 0:Z.length)??0)>1});fI({conversationId:s,openCreateForm:()=>I(!0),enabled:H});const de=w.useMemo(()=>!R||!R.length?null:Dx(R,W,J),[R,W,J]),Ee=s5(W),{data:rt,isLoading:it}=mp({senderEmail:t,conversationId:String(s),enabled:Ke&&!!t}),{emailHeaders:Ot,selectedEmail:Vn}=rt??{},{scrollOnceAfterLoad:Cn,resetScrollState:ro}=eI(g),La=se!==K.LOADING&&(!J||!Object.values(J).some(M=>M===K.LOADING))&&R&&R.length>0;w.useLayoutEffect(()=>{var M;Q&&!p&&q&&((M=y==null?void 0:y.current)!=null&&M.scrollHeight)&&Cn(!!La,"smooth")},[Q,p,q,La,Cn,(O=y==null?void 0:y.current)==null?void 0:O.scrollHeight,c]);const ll=(M,Z)=>{r(I3,{search_keyword:M,sm_ids:n,connector_name:Z,suggestion_type:De})},ul=(M,Z,te)=>{!Array.isArray(Z)||!Z.length?r(w3,{search_keyword:M,sm_ids:n,connector_name:te,suggestion_type:De}):Z.length&&r(_3,{num_of_results:Z.length,search_keyword:M,sm_ids:n,connector_name:te,suggestion_type:De})},{mutate:dl,reset:oo,data:Oa,isPending:Gn,isIdle:Zo}=KE(ll,ul),so=w.useCallback(()=>{oo(),D(null)},[oo,D]),un=w.useCallback(()=>{t&&n.length&&s&&a(Ia({inboxIds:n,conversationId:s}))},[a,t,n,s]),Fa=w.useCallback((M,Z)=>{M&&s&&Z&&a(Ea({id:M,channelType:"email",conversationId:s,externalResourceId:Z,contactEmail:t})).unwrap().catch(()=>{a(Gr(null))})},[a,s,t]);if(w.useEffect(()=>{(async()=>{c&&(z(await fi(c)),oe(await cu(c)))})()},[c]),w.useEffect(()=>{it||G(Vn||t)},[t,Vn,it]),w.useEffect(()=>{j&&s&&qE(String(s),j)},[j,s]),w.useEffect(()=>{q&&c&&lu(c)},[q,c]),w.useEffect(()=>{var M;if(X){x(!0);const{externalResourceId:Z}=X,te=(M=X.forms.find(ge=>ge.type==="edit"))==null?void 0:M.id;Fa(te,Z)}else x(!1),a(yx())},[X,Fa,a]),w.useEffect(()=>(un(),ro(),()=>{a(V1.clearConnectorList())}),[a,un,ro]),w.useEffect(()=>{if(re&&R&&R.length&&de&&!l.current){const{cards_per_app:M,total_empty_cards:Z,total_cards_with_errors:te}=de;r(Qm,{numOfCards:R.length,total_cards_loaded:R.length,total_empty_cards:Z,total_cards_with_errors:te,cards_per_app:M,sm_ids:n}),l.current=!0}return()=>{l.current=!1}},[re,R,de,r,n]),w.useEffect(()=>{s&&n&&n.length&&a(ba({inboxIds:n,conversationId:s,channelType:"email",isExpandedFormEnabled:jn}))},[a,n,s,jn]),w.useEffect(()=>{const M=Z=>{var ge;if(!(Z instanceof CustomEvent))return;const te=(ge=Z.detail)==null?void 0:ge.connectorKey;b({connectorKey:te})};return window.addEventListener($c.OPEN_FORM_VIEW,M),()=>{window.removeEventListener($c.OPEN_FORM_VIEW,M)}},[]),w.useEffect(()=>{if(!(B!=null&&B.length)||!v.connectorKey)return;const M=v.connectorKey;b({});const Z=B.find(te=>{var ge;return((ge=te.connectorKey)==null?void 0:ge.toLowerCase())===(M==null?void 0:M.toLowerCase())});Z&&($(Z),I(!0))},[B,v]),!t.length||se===K.LOADING)return u.jsx(Ov,{});const ka=M=>{r(n3,{connector_name:ee,source:M,sm_ids:n})},Da=M=>{I(!0),ka(M)},Na=()=>{_(!0),r(r3)},Xo=M=>{r(M,T),Be?N(!0):(I(!1),$(null))},Ra=M=>{if(X){const{connectorName:Z,title:te}=X;r(M,{connector_name:Z,card_title:te,sm_ids:n,ug_id:i})}Be?N(!0):a(Gr(null))},fl=()=>{I(!1),a(Gr(null)),S(void 0),N(!1)},zo=()=>{un(),a(V1.clearConnectorList())},Ma=[{label:"Go back",variant:"text",action:fl},{label:"Stay",variant:"contained",action:()=>N(!1)}],Yo=B.length>0,Jo=ve.length>0,pl=()=>Yo||Jo?u.jsx(sE,{haveCreateObjects:Yo,haveLinkObjects:Jo,onCreateClick:()=>Da(_d.MAIN_BUTTON),onLinkClick:()=>_(!0)}):u.jsx(J1,{isAdmin:e,hideHeading:!0});return u.jsxs(Rd,{ref:f,"data-testid":Array.isArray(R)?"connector-agent":"loading",id:"connector-agent-container",stopOverflow:C||E,children:[u.jsx(sp,{shown:L,setShown:N,title:ux,description:dx,buttons:Ma}),u.jsx(j5,{onWheel:()=>h(!0),ref:y,children:H?u.jsxs(u.Fragment,{children:[u.jsx(m4,{connectors:Ee,isWriteFlowEnabled:cn,haveCreateObjects:Yo,haveLinkObjects:Jo,cards:R,handleCreateNewObject:()=>Da(_d.ICON),handleLinkNewObject:Na}),xt?u.jsx(jE,{selectedObject:k,setSelectedObject:D,fetchSearchResults:dl,onReset:so,root:f.current}):null,u.jsxs(Hr,{children:[u.jsx(Wr,{condition:xt&&Gn,children:u.jsx(JE,{})},"search"),u.jsx(Wr,{condition:xt&&!!k&&!Zo,children:u.jsx(YE,{searchResults:Oa??[],selectedObject:k,onReset:so,fetchCards:un})},"results"),u.jsxs(Wr,{fallback:!0,children:[Ke&&(R!=null&&R.length)?u.jsxs(d.Stack,{direction:"row",alignItems:"center",gap:"8px",children:[u.jsx(d.Stack,{sx:{flex:1,minWidth:0},children:u.jsx(Vv,{emailHeaders:Ot,selectedEmail:j,root:f.current,isLoading:it,setSelectedEmail:G})}),br&&Bn&&e&&u.jsx(d.Tooltip,{title:"Update customer identity mapping",placement:"top",children:u.jsx(d.IconButton,{sx:{height:"32px",width:"32px",marginTop:"12px",flexShrink:0},onClick:()=>V(!0),children:u.jsx(d.icons.SettingsOutlined,{sx:{height:"20px",width:"20px"}})})})]}):null,!Ke&&br&&Bn&&e&&(R!=null&&R.length)?u.jsx(d.Button,{fullWidth:!0,variant:"contained",startIcon:u.jsx(d.icons.SettingsOutlined,{sx:{height:"14px",width:"14px"}}),sx:{backgroundColor:"#edf1f6",color:"#4d596c",borderRadius:"6px",padding:"9px 12px",marginTop:"12px",textTransform:"none",fontWeight:500,fontSize:"14px",lineHeight:"20px",boxShadow:"none","&:hover":{backgroundColor:"#e2e8f0",boxShadow:"none"}},onClick:()=>V(!0),children:"Customer identity mapping"}):null,at?u.jsx(Fv,{}):null,u.jsxs(Hr,{children:[u.jsxs(Wr,{condition:!!R&&R.length>0,children:[u.jsx(sv,{cards:R,specificCardData:W,email:j??"",specificConnectorApiStatus:J,onCardUnlinking:un}),u.jsx("div",{ref:g,children:Qe?u.jsx(b5,{connectors:Ee,expanded:Q}):null})]},"cards-list"),u.jsx(Wr,{condition:!(R!=null&&R.length)&&cn,children:pl()},"create-banner")]})]},"cards")]})]}):u.jsx(J1,{isAdmin:e})}),u.jsx(Zc,{onClose:()=>Ra(m3),isOpen:m,setIsOpen:x,title:Q3,portalId:"connector-layover-portal",backButtonTooltip:"Back",children:u.jsx(ip,{isEdit:!0,onClose:()=>Ra(g3),onCreateSuccess:zo,metaData:T,setMetaData:S,connectors:Ee})}),u.jsx(Zc,{onClose:()=>Xo(l3),portalId:"connector-layover-portal",isOpen:C,setIsOpen:I,children:u.jsx(ip,{onClose:()=>Xo(c3),onCreateSuccess:zo,metaData:T,setMetaData:S,defaultOption:Y,connectors:Ee})}),u.jsx(Zc,{onClose:()=>_(!1),portalId:"connector-layover-portal",isOpen:E,setIsOpen:_,children:u.jsx(eE,{setOpenTaskLinking:_,onLinkingSuccess:un})}),!H&&u.jsx(L5,{}),u.jsx(dI,{open:ae,onClose:()=>V(!1),connectors:(ln==null?void 0:ln.connectors)??[],onSaveSuccess:un})]})},hI=({children:e,sendTrackingEvent:t,contactEmail:n,baseUrls:r={},currentSmIds:o=[],userEmail:s,metaData:a,availableFeatures:i,conversationId:c,connectorFunctions:l,stackingContext:f,isAdmin:g=!1,actionQueue:y})=>{const v=w.useMemo(()=>({userEmail:s,email:n,baseUrls:r,currentSmIds:o,metaData:a,conversationId:c,sendTrackingEvent:t||(()=>{}),availableFeatures:i,isAdmin:g,connectorFunctions:l,stackingContext:f,actionQueue:y}),[s,n,r,t,o,a,i,c,g,l,f,y]);return u.jsx(Ge.Provider,{value:v,children:e})},Qc=({children:e})=>{const[t]=w.useState(()=>new S2);return u.jsx(F2,{client:t,children:e})},gI=Qd({cardList:Bx,write:Cx,common:X8}),Uc=Mb({reducer:gI,devTools:!0}),mI=({children:e,userEmail:t,extraParams:n,contactEmail:r,baseUrls:o,availableFeatures:s,connectorFunctions:a,stackingContext:i,actionQueue:c})=>u.jsx($i,{store:Uc,children:u.jsx(d.HiverProvider,{custom:!0,children:u.jsx(Qc,{children:u.jsx(hI,{userEmail:t,availableFeatures:s,sendTrackingEvent:n==null?void 0:n.sendTrackingEvent,contactEmail:r,currentSmIds:n==null?void 0:n.currentSmIds,metaData:n==null?void 0:n.metaData,conversationId:n==null?void 0:n.conversationId,baseUrls:o,connectorFunctions:a,stackingContext:i,actionQueue:c,isAdmin:n==null?void 0:n.isAdmin,children:u.jsx(w.Suspense,{fallback:u.jsx(u.Fragment,{}),children:e})})})})}),Kc=d.styled(d.Box)`
1293
1293
  height: inherit;
1294
1294
  .MuiScopedCssBaseline-root {
1295
1295
  height: inherit;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hiver/connector-agent",
3
- "version": "4.6.1-cfApps-beta.16",
3
+ "version": "4.6.1-cfApps-beta.17",
4
4
  "main": "index.es.js",
5
5
  "module": "index.es.js",
6
6
  "types": "index.d.ts",