@flowengage/react-chatbot 8.0.126 → 8.0.128

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.
@@ -18,7 +18,7 @@ var v = Object.defineProperty, y = Object.getOwnPropertyDescriptor, b = Object.g
18
18
  }, T = (e) => x.call(e, "module.exports") ? e["module.exports"] : w(v({}, "__esModule", { value: !0 }), e), E = (e) => {
19
19
  if (!e || typeof e != "object") throw Error("FlowEngage config is required");
20
20
  if (!e.siteId || typeof e.siteId != "string") throw Error("[FlowEngage] config.siteId is required. Pass it as <FlowEngageProvider siteId=\"your-site-id\" /> or config={{ siteId: 'your-site-id' }}.");
21
- let t = (e.apiBaseUrl || "https://be-flowengage-stage.oslabs.app").replace(/\/+$/, "");
21
+ let t = (e.apiBaseUrl || "https://be-flowengage-dev.oslabs.app").replace(/\/+$/, "");
22
22
  return {
23
23
  siteId: e.siteId.trim(),
24
24
  apiBaseUrl: t
@@ -13739,14 +13739,14 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13739
13739
  let a = i ? `Here is this section's full content — describe it from THIS text only, and do not call any tool:\n"""${i}"""\n` : "read the section's content silently first (fwh-read-content-mvp) if you don't already have it. ";
13740
13740
  R.current?.sendUserMessage?.(`Describe the section titled "${r}" in 3-4 sentences, starting with ${n === 0 ? "Starting with" : "Next —"} ${r}. Describe ONLY this section. If this section contains named sub-items (steps, checklist entries, cards, plans, FAQs, team members), name EVERY one of them in order with a short phrase each — never skip or collapse them into a summary; ` + a + "This section is ON THE PAGE THE VISITOR IS ALREADY ON — do NOT call fwh-navigate-mvp, do not go to a product/detail page, and do not offer to, even if this section's name also matches a page name. Do not mention any other section, do not ask whether to continue, then stop.", { suppressQuestion: !0 });
13741
13741
  };
13742
- let L = p(0), R = p(null), Se = p(null), Ce = p(""), we = p(async () => {}), Oe = p(!1), Ae = p(!1), je = p(!1), Me = p(!1), Ne = p("minimized"), Fe = p(null), Ie = p(null), z = p(null), Re = p(0), ze = p(!1), Be = p("idle"), Ve = p(null), B = p(null), He = p(!1), Ue = p(null), V = o((e = "minimized") => {
13742
+ let L = p(0), R = p(null), Se = p(null), Ce = p(""), we = p(async () => {}), Oe = p(!1), Ae = p(!1), je = p(!1), Me = p(!1), Ne = p("minimized"), Fe = p(null), Ie = p(null), z = p(null), Re = p(0), ze = p(!1), Be = p("idle"), Ve = p(null), B = p(!1), He = p(null), Ue = o((e = "minimized") => {
13743
13743
  console.warn("[FlowEngage:VoiceDebug] 🛑 requestSessionShutdown called", {
13744
13744
  destination: e,
13745
13745
  stack: (/* @__PURE__ */ Error()).stack?.split("\n").slice(1, 4).join(" | ")
13746
13746
  }), Ne.current = e, Me.current = !0, queueMicrotask(() => {
13747
13747
  Oe.current || (Oe.current = !0, we.current?.());
13748
13748
  });
13749
- }, [l]), We = o(() => {
13749
+ }, [l]), V = o(() => {
13750
13750
  ue.current &&= (clearTimeout(ue.current), null);
13751
13751
  }, []);
13752
13752
  c(() => {
@@ -13754,29 +13754,29 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13754
13754
  se.current = !1;
13755
13755
  return;
13756
13756
  }
13757
- if (se.current = !0, F.current = !1, ie(!1), We(), pe.current) {
13757
+ if (se.current = !0, F.current = !1, ie(!1), V(), pe.current) {
13758
13758
  pe.current = !1, R.current?.setMicMuted?.(!1);
13759
13759
  let e = fe.current;
13760
13760
  fe.current = "", R.current?.injectAgentSpeech?.("Thanks — I already have your email on file.", "interrupt"), e && R.current?.sendUserMessage?.(`The visitor's email is already on file — do not ask for it. Answer their question now: "${e}"`);
13761
13761
  }
13762
13762
  R.current?.sendContextualUpdate?.("EMAIL REQUIREMENT SATISFIED — the visitor's email is already on file. All earlier instructions about requiring or asking for an email are VOID. Never ask for it again.");
13763
- }, [x, We]);
13764
- let Ge = /(walk\s*(me\s*)?through|walkthrough|take me through|(complete|full|detailed) (overview|understanding|walkthrough|picture|breakdown|explanation)|give me (a|an|the) (overview|tour|walk)|tell me about (each|all)|go through (it|them|each|all)|overview of|one by one|tell me everything|explain (me )?(this|the) (whole |entire |full )?page|everything (about|on) this page|show me (each|all|around))/i, Ke = /(that covers everything|that was all|covered everything|that(?:'|’)?s everything)/i, qe = /^((uh+|um+|so|well|okay|ok|yeah)[,.\s]+)*(yes|yeah|yep|yup|sure|ok(ay)?|please|continue|go on|next|keep going|carry on|go ahead|resume|back to the tour)[\s.!,]*$/i, Je = /(would you like (me )?to take you|shall i take you|want me to take you|would you like to (go|explore|visit|see)|take you there)/i, Ye = /^((uh+|um+|oh|ah|so|well)[,.\s]+)*(cool|nice|great|awesome|wow|lovely|perfect|got it|gotcha|i see|understood|makes sense|interesting|right|alright|sounds good|mm+-?hmm+|hmm+|k)[\s.!,]*$/i, Xe = (e) => String(e || "").replace(/[\s.,!?]*((uh+|um+|er+|hmm+|mm+)[\s.,!?]*)+$/i, "").trim(), Ze = o(() => {
13765
- We(), ue.current = setTimeout(() => {
13763
+ }, [x, V]);
13764
+ let We = /(walk\s*(me\s*)?through|walkthrough|take me through|(complete|full|detailed) (overview|understanding|walkthrough|picture|breakdown|explanation)|give me (a|an|the) (overview|tour|walk)|tell me about (each|all)|go through (it|them|each|all)|overview of|one by one|tell me everything|explain (me )?(this|the) (whole |entire |full )?page|everything (about|on) this page|show me (each|all|around))/i, Ge = /(that covers everything|that was all|covered everything|that(?:'|’)?s everything)/i, Ke = /^((uh+|um+|so|well|okay|ok|yeah)[,.\s]+)*(yes|yeah|yep|yup|sure|ok(ay)?|please|continue|go on|next|keep going|carry on|go ahead|resume|back to the tour)[\s.!,]*$/i, qe = /(would you like (me )?to take you|shall i take you|want me to take you|would you like to (go|explore|visit|see)|take you there)/i, Je = /^((uh+|um+|oh|ah|so|well)[,.\s]+)*(cool|nice|great|awesome|wow|lovely|perfect|got it|gotcha|i see|understood|makes sense|interesting|right|alright|sounds good|mm+-?hmm+|hmm+|k)[\s.!,]*$/i, Ye = (e) => String(e || "").replace(/[\s.,!?]*((uh+|um+|er+|hmm+|mm+)[\s.,!?]*)+$/i, "").trim(), Xe = o(() => {
13765
+ V(), ue.current = setTimeout(() => {
13766
13766
  if (!(!F.current || se.current)) if (de.current < 3) {
13767
13767
  de.current += 1;
13768
13768
  try {
13769
13769
  R.current?.injectAgentSpeech?.("I still need your email in the box below to continue — could you enter it, please?", "queue");
13770
13770
  } catch {}
13771
- Ze();
13771
+ Xe();
13772
13772
  } else {
13773
13773
  try {
13774
13774
  R.current?.injectAgentSpeech?.("Since I haven't received your email, I'll close this session for now. Feel free to come back anytime — take care!", "queue");
13775
13775
  } catch {}
13776
- F.current = !1, ie(!1), We(), ze.current = !0;
13776
+ F.current = !1, ie(!1), V(), ze.current = !0;
13777
13777
  }
13778
13778
  }, 1e4);
13779
- }, [We]), H = o(async (e) => {
13779
+ }, [V]), Ze = o(async (e) => {
13780
13780
  Me.current = !0;
13781
13781
  try {
13782
13782
  Pn();
@@ -13815,10 +13815,10 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13815
13815
  s,
13816
13816
  a
13817
13817
  ]);
13818
- we.current = () => H(Ne.current === "chat" ? t : n), c(() => {
13818
+ we.current = () => Ze(Ne.current === "chat" ? t : n), c(() => {
13819
13819
  Ae.current = k;
13820
13820
  }, [k]), c(() => {
13821
- h && V("chat");
13821
+ h && Ue("chat");
13822
13822
  }, [h]), c(() => {
13823
13823
  let e = !1, o = null, c = null, p = null;
13824
13824
  return (async () => {
@@ -13863,7 +13863,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13863
13863
  ze.current = !0;
13864
13864
  },
13865
13865
  requestEmailCollection: () => {
13866
- S && (se.current || F.current || (F.current = !0, de.current = 0, ie(!0), Ze()));
13866
+ S && (se.current || F.current || (F.current = !0, de.current = 0, ie(!0), Xe()));
13867
13867
  }
13868
13868
  })), n = i ? Ee(i) : null, r = !!n?.transcript, u = i ? Le(i) : null, m = !!u, h = typeof window < "u" ? window.location.pathname : "/", g = typeof document < "u" ? document.title : "", _ = h.replace(/^\/[a-z]{2}(?:-[a-z]{2})?(?=\/|$)/i, "") || "/", b = _ === "/" || _ === "", C = {
13869
13869
  apiBaseUrl: a,
@@ -13905,13 +13905,13 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13905
13905
  },
13906
13906
  onUnhandledClientToolCall: (e) => console.error("[FlowEngage] Unhandled tool:", e?.tool_name),
13907
13907
  onSessionInfo: ({ emailOnFile: e }) => {
13908
- _e.current = !!e, e && (se.current = !0, F.current = !1, ie(!1), We(), console.log("[FlowEngage] email already on file per server — gate disabled"));
13908
+ _e.current = !!e, e && (se.current = !0, F.current = !1, ie(!1), V(), console.log("[FlowEngage] email already on file per server — gate disabled"));
13909
13909
  },
13910
13910
  onAgentTurnEnd: () => {
13911
13911
  e || he.current && (ge.current || pe.current || setTimeout(() => xe.current?.(), 250));
13912
13912
  },
13913
13913
  onSessionEnding: () => {
13914
- e || V("minimized");
13914
+ e || Ue("minimized");
13915
13915
  },
13916
13916
  onPanel: ({ title: t, items: n }) => {
13917
13917
  e || Kh(n, {
@@ -13923,11 +13923,11 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13923
13923
  onModeChange: ({ mode: t, tentative: n }) => {
13924
13924
  if (!e) {
13925
13925
  if (t === "speaking") {
13926
- Ve.current &&= (clearTimeout(Ve.current), null), Ue.current &&= (clearTimeout(Ue.current), null), O("speaking"), Be.current = "speaking", He.current = !1;
13926
+ Ve.current &&= (clearTimeout(Ve.current), null), He.current &&= (clearTimeout(He.current), null), O("speaking"), Be.current = "speaking", B.current = !1;
13927
13927
  return;
13928
13928
  }
13929
13929
  if (t === "user-speaking") {
13930
- if (F.current && !se.current && Ze(), Ue.current &&= (clearTimeout(Ue.current), null), Be.current === "speaking") return;
13930
+ if (F.current && !se.current && Xe(), He.current &&= (clearTimeout(He.current), null), Be.current === "speaking") return;
13931
13931
  try {
13932
13932
  Pn();
13933
13933
  } catch {}
@@ -13935,14 +13935,14 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13935
13935
  return;
13936
13936
  }
13937
13937
  if (t === "thinking") {
13938
- if (Ve.current &&= (clearTimeout(Ve.current), null), Ue.current &&= (clearTimeout(Ue.current), null), Be.current === "speaking") return;
13939
- O("thinking"), Be.current = "thinking", n && (Ue.current = setTimeout(() => {
13940
- Ue.current = null, !(e || Be.current !== "thinking") && (Be.current = "listening", O("listening"));
13938
+ if (Ve.current &&= (clearTimeout(Ve.current), null), He.current &&= (clearTimeout(He.current), null), Be.current === "speaking") return;
13939
+ O("thinking"), Be.current = "thinking", n && (He.current = setTimeout(() => {
13940
+ He.current = null, !(e || Be.current !== "thinking") && (Be.current = "listening", O("listening"));
13941
13941
  }, 4e3));
13942
13942
  return;
13943
13943
  }
13944
13944
  if (Be.current = "listening", ze.current) {
13945
- ze.current = !1, V();
13945
+ ze.current = !1, Ue();
13946
13946
  return;
13947
13947
  }
13948
13948
  if (le && !P && !se.current && !_e.current) {
@@ -13970,7 +13970,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13970
13970
  } catch {}
13971
13971
  }
13972
13972
  Ve.current && clearTimeout(Ve.current), Ve.current = setTimeout(() => {
13973
- e || Be.current !== "speaking" && (He.current || (Ve.current = null, Be.current = "listening", O("listening")));
13973
+ e || Be.current !== "speaking" && (B.current || (Ve.current = null, Be.current = "listening", O("listening")));
13974
13974
  }, 1200);
13975
13975
  }
13976
13976
  },
@@ -13981,20 +13981,18 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
13981
13981
  Jh();
13982
13982
  } catch {}
13983
13983
  let r = /\b(?:this|that|the)\s+(?:case\s*stud(?:y|ies)|product|article|blog|post|item|service)\b/i.test(String(t.message || ""));
13984
- if (!n && !r && t.role === "user" && Ge.test(String(t.message || ""))) typeof window < "u" && (window.__fe_user_nav_during_speech = null), I(!0), ge.current = !1, me.current = 0, L.current = -1, ve.current = O_(), ye.current = typeof window < "u" ? window.location.pathname : null, setTimeout(() => xe.current?.(), 400), console.log(`[FlowEngage] walkthrough armed — ${ve.current.length} sections on this page`);
13984
+ if (!n && !r && t.role === "user" && We.test(String(t.message || ""))) typeof window < "u" && (window.__fe_user_nav_during_speech = null), I(!0), ge.current = !1, me.current = 0, L.current = -1, ve.current = O_(), ye.current = typeof window < "u" ? window.location.pathname : null, setTimeout(() => xe.current?.(), 400), console.log(`[FlowEngage] walkthrough armed — ${ve.current.length} sections on this page`);
13985
13985
  else if (!n && t.role === "user" && he.current) {
13986
- let e = String(t.message || "").trim(), n = Xe(e), r = (e) => !!e && (qe.test(e) || Ye.test(e));
13987
- Je.test(be.current || "") ? (console.log("[FlowEngage] walkthrough ended — visitor accepted a navigation offer"), ye.current = null, ve.current = [], I(!1)) : !n || r(e) || r(n) ? ge.current && (ge.current = !1, console.debug("[FlowEngage] walkthrough resumed by visitor"), setTimeout(() => xe.current?.(), 300)) : (console.log("[FlowEngage] walkthrough ended — visitor moved to a new topic"), ye.current = null, ve.current = [], I(!1));
13986
+ let e = String(t.message || "").trim(), n = Ye(e), r = (e) => !!e && (Ke.test(e) || Je.test(e));
13987
+ qe.test(be.current || "") ? (console.log("[FlowEngage] walkthrough ended — visitor accepted a navigation offer"), ye.current = null, ve.current = [], I(!1)) : !n || r(e) || r(n) ? ge.current && (ge.current = !1, console.debug("[FlowEngage] walkthrough resumed by visitor"), setTimeout(() => xe.current?.(), 300)) : (console.log("[FlowEngage] walkthrough ended — visitor moved to a new topic"), ye.current = null, ve.current = [], I(!1));
13988
13988
  }
13989
- if (t.role !== "user" && !n && (be.current = String(t.message || "")), t.role !== "user" && Ke.test(String(t.message || ""))) {
13989
+ if (t.role !== "user" && !n && (be.current = String(t.message || "")), t.role !== "user" && Ge.test(String(t.message || ""))) {
13990
13990
  let e = ve.current.length;
13991
13991
  !e || L.current >= e - 1 ? I(!1) : console.debug(`[FlowEngage] agent claimed completion at step ${L.current + 1}/${e} — ignoring, tour continues`);
13992
13992
  }
13993
13993
  let a = t.role === "user" ? "user" : "bot", o = t.message || t.text || t.content || "";
13994
13994
  if (o) {
13995
- if (a === "user" && (Ce.current = o, typeof window < "u" && (window.__fe_user_nav_during_speech = null), He.current = !0, Ve.current &&= (clearTimeout(Ve.current), null), B.current && clearTimeout(B.current), B.current = setTimeout(() => {
13996
- B.current = null, !(Be.current === "speaking" || Be.current === "thinking") && (O("thinking"), Be.current = "thinking");
13997
- }, 1400), le && !oe && !se.current && !_e.current && (oe = !0, fe.current = o, pe.current = !0, R.current?.injectAgentSpeech?.("Before I answer that, could you please enter your email in the text box below?", "interrupt"), R.current?.setMicMuted?.(!0), F.current || (F.current = !0, de.current = 0, ie(!0), Ze()))), l.current = [...l.current, {
13995
+ if (a === "user" && (Ce.current = o, typeof window < "u" && (window.__fe_user_nav_during_speech = null), B.current = !0, Ve.current &&= (clearTimeout(Ve.current), null), Be.current !== "speaking" && (O("thinking"), Be.current = "thinking"), le && !oe && !se.current && !_e.current && (oe = !0, fe.current = o, pe.current = !0, R.current?.injectAgentSpeech?.("Before I answer that, could you please enter your email in the text box below?", "interrupt"), R.current?.setMicMuted?.(!0), F.current || (F.current = !0, de.current = 0, ie(!0), Xe()))), l.current = [...l.current, {
13998
13996
  sender: a,
13999
13997
  message: o,
14000
13998
  timestamp: (/* @__PURE__ */ new Date()).toISOString(),
@@ -14010,7 +14008,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14010
14008
  if (Ae.current && a === "bot" && /are you still there|still there\??|hello\?|anyone there|checking in|you there|are you available|is anyone|did you step away/i.test(o)) if (Re.current += 1, Re.current === 2) try {
14011
14009
  R.current?.sendContextualUpdate?.("IMPORTANT: The visitor is muted and has not responded to your last 2 checks. Make exactly ONE more check. If there is still no response, say: 'I feel like you are not active, so I'm ending this session. You can connect with me anytime.' then immediately call the fwh-end-session-mvp tool to end the voice session. Do NOT ask again after that.");
14012
14010
  } catch {}
14013
- else Re.current >= 5 && V("minimized");
14011
+ else Re.current >= 5 && Ue("minimized");
14014
14012
  }
14015
14013
  },
14016
14014
  onError: (t) => {
@@ -14023,7 +14021,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14023
14021
  try {
14024
14022
  R.current?.setMicMuted?.(!0);
14025
14023
  } catch {}
14026
- A(!0), O("error"), V("chat");
14024
+ A(!0), O("error"), Ue("chat");
14027
14025
  }
14028
14026
  },
14029
14027
  onDisconnect: (t) => {
@@ -14040,7 +14038,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14040
14038
  try {
14041
14039
  R.current?.setMicMuted?.(!0);
14042
14040
  } catch {}
14043
- A(!0), V("chat");
14041
+ A(!0), Ue("chat");
14044
14042
  }
14045
14043
  });
14046
14044
  if (e) {
@@ -14138,7 +14136,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14138
14136
  if (i) try {
14139
14137
  Le(i);
14140
14138
  } catch {}
14141
- typeof window < "u" && (window.__fe_user_nav_during_speech = null), Pr(), Ve.current &&= (clearTimeout(Ve.current), null), Ue.current &&= (clearTimeout(Ue.current), null), ue.current &&= (clearTimeout(ue.current), null), He.current = !1, Be.current = "idle", c && typeof window < "u" && (window.history.pushState = c), p && typeof window < "u" && window.removeEventListener("popstate", p);
14139
+ typeof window < "u" && (window.__fe_user_nav_during_speech = null), Pr(), Ve.current &&= (clearTimeout(Ve.current), null), He.current &&= (clearTimeout(He.current), null), ue.current &&= (clearTimeout(ue.current), null), B.current = !1, Be.current = "idle", c && typeof window < "u" && (window.history.pushState = c), p && typeof window < "u" && window.removeEventListener("popstate", p);
14142
14140
  let t = o || R.current, n = Fe.current, d = Ie.current;
14143
14141
  if (t?.endSession?.().catch(() => {}), n && s && a) {
14144
14142
  let e = d ? Math.round((Date.now() - d) / 1e3) : 0, t = JSON.stringify({
@@ -14160,7 +14158,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14160
14158
  r,
14161
14159
  i,
14162
14160
  a,
14163
- V
14161
+ Ue
14164
14162
  ]), c(() => {
14165
14163
  if (!ee) return;
14166
14164
  let e = (e) => {
@@ -14169,7 +14167,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14169
14167
  };
14170
14168
  return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
14171
14169
  }, [ee]);
14172
- let U = async () => {
14170
+ let H = async () => {
14173
14171
  if (R.current) try {
14174
14172
  if (k) {
14175
14173
  Re.current = 0, await R.current.setMicMuted?.(!1), A(!1);
@@ -14183,14 +14181,14 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14183
14181
  } catch {}
14184
14182
  }
14185
14183
  } catch {}
14186
- }, Qe = o(async (e) => {
14184
+ }, U = o(async (e) => {
14187
14185
  e?.preventDefault?.();
14188
14186
  let t = ae.trim().toLowerCase();
14189
14187
  if (!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)) {
14190
14188
  P("Please enter a valid email address.");
14191
14189
  return;
14192
14190
  }
14193
- P(""), se.current = !0, F.current = !1, We(), ie(!1), N(""), pe.current = !1;
14191
+ P(""), se.current = !0, F.current = !1, V(), ie(!1), N(""), pe.current = !1;
14194
14192
  try {
14195
14193
  typeof b == "function" && await b(t);
14196
14194
  } catch {}
@@ -14203,8 +14201,8 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14203
14201
  }, [
14204
14202
  ae,
14205
14203
  b,
14206
- We
14207
- ]), $e = Array.isArray(e) && e[0] || "#3B82F6";
14204
+ V
14205
+ ]), Qe = Array.isArray(e) && e[0] || "#3B82F6";
14208
14206
  return /* @__PURE__ */ _("div", {
14209
14207
  ref: z,
14210
14208
  style: {
@@ -14217,7 +14215,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14217
14215
  },
14218
14216
  children: [
14219
14217
  re && /* @__PURE__ */ _("form", {
14220
- onSubmit: Qe,
14218
+ onSubmit: U,
14221
14219
  style: {
14222
14220
  width: "270px",
14223
14221
  maxWidth: "calc(100vw - 40px)",
@@ -14280,7 +14278,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14280
14278
  padding: "10px 12px",
14281
14279
  borderRadius: "10px",
14282
14280
  border: "none",
14283
- background: ae.trim() ? $e : "#374151",
14281
+ background: ae.trim() ? Qe : "#374151",
14284
14282
  color: "white",
14285
14283
  fontSize: "14px",
14286
14284
  fontWeight: 600,
@@ -14349,7 +14347,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14349
14347
  alignItems: "center"
14350
14348
  },
14351
14349
  children: [/* @__PURE__ */ g("button", {
14352
- onClick: U,
14350
+ onClick: H,
14353
14351
  title: k ? "Unmute" : "Mute",
14354
14352
  style: {
14355
14353
  width: "24px",
@@ -14444,7 +14442,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14444
14442
  children: [
14445
14443
  /* @__PURE__ */ _("button", {
14446
14444
  onClick: () => {
14447
- te(!1), Ne.current = "chat", H(t);
14445
+ te(!1), Ne.current = "chat", Ze(t);
14448
14446
  },
14449
14447
  style: {
14450
14448
  display: "flex",
@@ -14548,7 +14546,7 @@ function H_({ orbColors: e, onEnterChat: t, onEndChat: n, agentId: r, siteId: i,
14548
14546
  }),
14549
14547
  /* @__PURE__ */ _("button", {
14550
14548
  onClick: () => {
14551
- te(!1), Ne.current = "minimized", H(n);
14549
+ te(!1), Ne.current = "minimized", Ze(n);
14552
14550
  },
14553
14551
  style: {
14554
14552
  display: "flex",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flowengage/react-chatbot",
3
- "version": "8.0.126",
3
+ "version": "8.0.128",
4
4
  "description": "Embeddable AI chat widget for React — powered by FlowEngage. Drop it in with a single siteId.",
5
5
  "keywords": [
6
6
  "chatbot",