@telnyx/ai-chat-widget 5.0.0 → 5.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -5,15 +5,8 @@ import * as TooltipPrimitive from '@radix-ui/react-tooltip';
5
5
 
6
6
  declare type BaseProps = {
7
7
  /**
8
- * The default endpoint to use for the chat widget.
9
- * @default `aida`
10
- * @deprecated No longer has any effect — there is a single endpoint, and
11
- * this is already the default. Scheduled for removal in the next major.
12
- */
13
- endpoint?: 'aida';
14
- /**
15
- * The base URL for AIDA (Heavy thinking mode).
16
- * Optional — if omitted, defaults to the internal AIDA endpoint.
8
+ * The base URL for TAIA (Heavy thinking mode).
9
+ * Optional — if omitted, defaults to the internal TAIA endpoint.
17
10
  */
18
11
  chatAPIUrl?: string;
19
12
  /**
package/dist/index.mjs CHANGED
@@ -5803,7 +5803,7 @@ function rR() {
5803
5803
  }), [e, t];
5804
5804
  }
5805
5805
  const lt = {
5806
- // AIDA API URL (Heavy thinking mode)
5806
+ // TAIA API URL (Heavy thinking mode)
5807
5807
  CHAT_API_URL: "https://api.telnyx.com/v2/support_agent/support/portal",
5808
5808
  FEEDBACK_API_URL: "https://api.telnyx.com/v2/support_agent/support/portal",
5809
5809
  WIDGET_WIDTH: 360,
@@ -5918,15 +5918,15 @@ const uR = [
5918
5918
  ["path", { d: "M6 18a4 4 0 0 1-2-7.464", key: "k1g0md" }],
5919
5919
  ["path", { d: "M6.003 5.125a4 4 0 0 0-2.526 5.77", key: "q97ue3" }]
5920
5920
  ], dR = cR("brain", uR);
5921
- var qr = /* @__PURE__ */ ((e) => (e.AIDA = "aida", e))(qr || {});
5921
+ var qr = /* @__PURE__ */ ((e) => (e.TAIA = "taia", e))(qr || {});
5922
5922
  const ME = {
5923
- [qr.AIDA]: {
5923
+ [qr.TAIA]: {
5924
5924
  label: "Heavy thinking",
5925
5925
  icon: "🧠",
5926
5926
  /** Rendered in the mode toggle. */
5927
5927
  Icon: dR,
5928
5928
  ariaLabel: "Heavy thinking mode",
5929
- endpoint: qr.AIDA,
5929
+ endpoint: qr.TAIA,
5930
5930
  tooltip: {
5931
5931
  title: "🧠 Heavy thinking",
5932
5932
  capabilities: ["Troubleshooting tools", "Deep reasoning"],
@@ -9454,14 +9454,14 @@ const AI = {
9454
9454
  }, RI = (e, t) => ({
9455
9455
  user: AI,
9456
9456
  chatAPIUrl: lt.CHAT_API_URL,
9457
- hasAIDAConfig: !1,
9457
+ hasTAIAConfig: !1,
9458
9458
  feedbackAPIUrl: lt.FEEDBACK_API_URL,
9459
9459
  apiService: new Tr(
9460
9460
  lt.CHAT_API_URL,
9461
9461
  lt.FEEDBACK_API_URL,
9462
9462
  () => t().user
9463
9463
  ),
9464
- endpoint: qr.AIDA,
9464
+ endpoint: qr.TAIA,
9465
9465
  numRetries: 0,
9466
9466
  retryTimeoutId: null,
9467
9467
  sessionId: Zm(),
@@ -9480,7 +9480,7 @@ const AI = {
9480
9480
  );
9481
9481
  }),
9482
9482
  setChatAPIUrl: (n, r = !0) => e((a) => {
9483
- a.chatAPIUrl = n, a.hasAIDAConfig = r, a.apiService = new Tr(
9483
+ a.chatAPIUrl = n, a.hasTAIAConfig = r, a.apiService = new Tr(
9484
9484
  n,
9485
9485
  a.feedbackAPIUrl,
9486
9486
  () => t().user
@@ -9851,6 +9851,17 @@ const AI = {
9851
9851
  .visible {
9852
9852
  visibility: visible;
9853
9853
  }
9854
+ .sr-only {
9855
+ position: absolute;
9856
+ width: 1px;
9857
+ height: 1px;
9858
+ padding: 0;
9859
+ margin: -1px;
9860
+ overflow: hidden;
9861
+ clip-path: inset(50%);
9862
+ white-space: nowrap;
9863
+ border-width: 0;
9864
+ }
9854
9865
  .absolute {
9855
9866
  position: absolute;
9856
9867
  }
@@ -15166,17 +15177,19 @@ const Ql = (e) => /* @__PURE__ */ y.jsxs(
15166
15177
  /* @__PURE__ */ y.jsx(y_, { className: "text-black px-1 pt-1", children: "AI Assistant" })
15167
15178
  ] })
15168
15179
  ] }), w_ = () => /* @__PURE__ */ y.jsxs("span", { className: "text-white text-sm", children: [
15169
- "Read more",
15170
- /* @__PURE__ */ y.jsx(S_, { text: "here" }),
15180
+ /* @__PURE__ */ y.jsx(S_, { text: "Read more about the AI assistant" }),
15171
15181
  "."
15172
- ] }), S_ = ({ text: e }) => /* @__PURE__ */ y.jsx(
15182
+ ] }), S_ = ({ text: e }) => /* @__PURE__ */ y.jsxs(
15173
15183
  "a",
15174
15184
  {
15175
- className: "inline underline text-telnyx-light-green hover:text-white ml-1",
15185
+ className: "inline underline text-telnyx-light-green hover:text-white",
15176
15186
  target: "_blank",
15177
15187
  rel: "noopener noreferrer",
15178
15188
  href: "https://support.telnyx.com/en/articles/8020222-mission-control-portal-ai-chat-support",
15179
- children: e
15189
+ children: [
15190
+ e,
15191
+ /* @__PURE__ */ y.jsx("span", { className: "sr-only", children: " (opens in a new tab)" })
15192
+ ]
15180
15193
  }
15181
15194
  );
15182
15195
  function v_() {
@@ -48023,7 +48036,7 @@ const ZP = ie.create(jI), QP = ie.create(VI), Av = ({
48023
48036
  d === "error" && /* @__PURE__ */ y.jsx(gB, { onClick: r })
48024
48037
  ] });
48025
48038
  if (n === "loading")
48026
- return s === qr.AIDA ? /* @__PURE__ */ y.jsx(
48039
+ return s === qr.TAIA ? /* @__PURE__ */ y.jsx(
48027
48040
  OO,
48028
48041
  {
48029
48042
  isLoaded: !1,