@eloquentai/chat-sdk 0.36.0 → 0.36.1-dev.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,16 +1,16 @@
1
1
  "use client";
2
- import { L as Tt, c as Qe, u as Mt, g as at, X as Pt, i as At, A as Ot, d as V, e as De, f as Ut, h as jt, r as Dt, t as $t, j as Bt, N as et, k as Oe, l as Lt, H as Nt, w as it, m as Zt, s as Kt, n as Vt, o as Ht, E as Wt, p as Ft, S as Jt, C as Gt, T as Yt } from "./skeleton-CNz9cQ6u.js";
3
- import { jsx as x, jsxs as ze, Fragment as st } from "react/jsx-runtime";
4
- import { useState as _, useEffect as Z, useMemo as Je, useCallback as w, useRef as N } from "react";
5
- import { createPortal as Ge } from "react-dom";
6
- import Xt from "react-dom/client";
2
+ import { L as At, c as nt, u as Pt, g as ct, X as Ot, i as Ut, A as jt, d as H, e as Ze, f as Dt, h as $t, r as Bt, t as Lt, j as Nt, N as at, k as Be, l as Zt, H as Kt, w as ut, m as Vt, s as Wt, n as Ht, o as Ft, E as Jt, p as Gt, S as Yt, C as Xt, T as Qt } from "./skeleton-CFoCj07s.js";
3
+ import { jsx as _, jsxs as Oe, Fragment as dt } from "react/jsx-runtime";
4
+ import { useState as S, useEffect as F, useMemo as et, useCallback as w, useRef as N } from "react";
5
+ import { createPortal as tt } from "react-dom";
6
+ import eo from "react-dom/client";
7
7
  try {
8
8
  let e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {}, t = new e.Error().stack;
9
- t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "0f0cacb8-b6c4-4392-a4a8-2de01d4f72f9", e._sentryDebugIdIdentifier = "sentry-dbid-0f0cacb8-b6c4-4392-a4a8-2de01d4f72f9");
9
+ t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "ecc97119-d6fa-4d7a-a28c-30a2203dca14", e._sentryDebugIdIdentifier = "sentry-dbid-ecc97119-d6fa-4d7a-a28c-30a2203dca14");
10
10
  } catch {
11
11
  }
12
12
  if (typeof window < "u") {
13
- const e = "production";
13
+ const e = "development";
14
14
  import("./index-hFbiYJI3.js").then(({ init: t }) => {
15
15
  t({
16
16
  dsn: void 0,
@@ -26,51 +26,51 @@ if (typeof window < "u") {
26
26
  "x-auth-token"
27
27
  ]), n = o.request?.headers;
28
28
  if (n)
29
- for (const i of Object.keys(n))
30
- r.has(i.toLowerCase()) && (n[i] = "[Filtered]");
29
+ for (const a of Object.keys(n))
30
+ r.has(a.toLowerCase()) && (n[a] = "[Filtered]");
31
31
  return o.request && (o.request.data = "[Filtered]"), o;
32
32
  }
33
33
  });
34
34
  });
35
35
  }
36
- const Ze = '/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-space-x-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-ease:initial;--eloq-aura-angle:0deg}}}@layer theme{:root,:host{--eloq-font-sans:system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";--eloq-font-mono:ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--eloq-color-red-50:oklch(97.1% .013 17.38);--eloq-color-red-200:oklch(88.5% .062 18.334);--eloq-color-red-400:oklch(70.4% .191 22.216);--eloq-color-red-500:oklch(63.7% .237 25.331);--eloq-color-red-800:oklch(44.4% .177 26.899);--eloq-color-amber-50:oklch(98.7% .022 95.277);--eloq-color-amber-200:oklch(92.4% .12 95.746);--eloq-color-amber-400:oklch(82.8% .189 84.429);--eloq-color-amber-500:oklch(76.9% .188 70.08);--eloq-color-amber-800:oklch(47.3% .137 46.201);--eloq-color-yellow-400:oklch(85.2% .199 91.936);--eloq-color-green-50:oklch(98.2% .018 155.826);--eloq-color-green-200:oklch(92.5% .084 155.995);--eloq-color-green-400:oklch(79.2% .209 151.711);--eloq-color-green-500:oklch(72.3% .219 149.579);--eloq-color-green-800:oklch(44.8% .119 151.328);--eloq-color-blue-50:oklch(97% .014 254.604);--eloq-color-blue-200:oklch(88.2% .059 254.128);--eloq-color-blue-400:oklch(70.7% .165 254.624);--eloq-color-blue-500:oklch(62.3% .214 259.815);--eloq-color-blue-800:oklch(42.4% .199 265.638);--eloq-color-gray-200:oklch(92.8% .006 264.531);--eloq-color-gray-300:oklch(87.2% .01 258.338);--eloq-color-gray-400:oklch(70.7% .022 261.325);--eloq-color-gray-500:oklch(55.1% .027 264.364);--eloq-color-gray-600:oklch(44.6% .03 256.802);--eloq-color-black:#000;--eloq-color-white:#fff;--eloq-spacing:.25rem;--eloq-container-xs:20rem;--eloq-text-xs:.75rem;--eloq-text-xs--line-height:calc(1 / .75);--eloq-text-sm:.875rem;--eloq-text-sm--line-height:calc(1.25 / .875);--eloq-text-base:1rem;--eloq-text-base--line-height: 1.5 ;--eloq-text-2xl:1.5rem;--eloq-text-2xl--line-height:calc(2 / 1.5);--eloq-font-weight-medium:500;--eloq-font-weight-semibold:600;--eloq-tracking-tight:-.025em;--eloq-leading-relaxed:1.625;--eloq-radius-md:calc(var(--radius) - 2px);--eloq-radius-lg:var(--radius);--eloq-radius-xl:.75rem;--eloq-radius-2xl:1rem;--eloq-radius-3xl:1.5rem;--eloq-drop-shadow-lg:0 4px 4px #00000026;--eloq-drop-shadow-xl:0 9px 7px #0000001a;--eloq-ease-out:cubic-bezier(0, 0, .2, 1);--eloq-animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--eloq-default-transition-duration:.15s;--eloq-default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--eloq-default-font-family:var(--eloq-font-sans);--eloq-default-mono-font-family:var(--eloq-font-mono);--eloq-animate-panel-in:panel-in .35s cubic-bezier(.16, 1, .3, 1) both;--eloq-animate-panel-out:panel-out .25s cubic-bezier(.4, 0, 1, 1) both;--eloq-animate-thinking-dot:thinking-dot 1.2s ease-in-out infinite;--eloq-animate-thinking-shimmer:thinking-shimmer 1.8s linear infinite;--eloq-animate-regenerating:regenerating-sweep 1.2s linear infinite;--eloq-animate-text-in:text-in .35s ease-out both;--eloq-animate-message-in:message-in .3s ease-out both;--eloq-animate-slide-up-in:slide-up-in .3s ease-out both}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--eloq-default-font-family,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");font-feature-settings:var(--eloq-default-font-feature-settings,normal);font-variation-settings:var(--eloq-default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--eloq-default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);font-feature-settings:var(--eloq-default-mono-font-feature-settings,normal);font-variation-settings:var(--eloq-default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring:where(:not(iframe)){outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}:root{--background:0 0% 100%;--foreground:0 0% 3.9%;--card:0 0% 100%;--card-foreground:0 0% 3.9%;--popover:0 0% 100%;--popover-foreground:0 0% 3.9%;--primary:267 56% 46%;--primary-foreground:0 0% 98%;--secondary:0 0% 96.1%;--secondary-foreground:0 0% 9%;--muted:0 0% 96.1%;--muted-foreground:0 0% 45.1%;--accent:0 0% 96.1%;--accent-foreground:0 0% 9%;--destructive:0 84.2% 60.2%;--destructive-foreground:0 0% 98%;--border:0 0% 89.8%;--input:0 0% 89.8%;--ring:0 0% 3.9%;--cream:37.5 44% 96.5%;--chart-1:12 76% 61%;--chart-2:173 58% 39%;--chart-3:197 37% 24%;--chart-4:43 74% 66%;--chart-5:27 87% 67%;--radius:.5rem}.dark{--background:262 50% 10%;--foreground:262 5% 90%;--card:262 50% 10%;--card-foreground:262 5% 90%;--popover:262 50% 5%;--popover-foreground:262 5% 90%;--primary:262 62% 70%;--primary-foreground:0 0% 100%;--primary-dark:262 62% 60%;--secondary:262 30% 30%;--secondary-foreground:0 0% 100%;--secondary-dark:262 30% 20%;--secondary-light:262 30% 40%;--tertiary:267 56% 46%;--tertiary-foreground:0 0% 100%;--tertiary-dark:267 38% 25%;--tertiary-light:263 100% 85%;--muted:224 30% 25%;--muted-foreground:262 5% 90%;--accent:224 30% 25%;--accent-foreground:262 5% 100%;--accent-dark:224 30% 15%;--destructive:0 100% 30%;--destructive-foreground:262 5% 90%;--border:0 0% 30%;--input:262 30% 25%;--ring:262 62% 71%;--cream:257 28% 20%;--radius:.5rem;--sidebar-background:var(--background);--sidebar-foreground:var(--foreground);--sidebar-primary:var(--primary);--sidebar-primary-foreground:var(--primary-foreground);--sidebar-accent:var(--accent);--sidebar-accent-foreground:var(--accent-foreground);--sidebar-border:var(--border);--sidebar-ring:var(--ring)}*{border-color:hsl(var(--border))}body{background-color:hsl(var(--background));color:hsl(var(--foreground))}}@layer components;@layer utilities{.eloq\\:pointer-events-none{pointer-events:none}.eloq\\:sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.eloq\\:absolute{position:absolute}.eloq\\:relative{position:relative}.eloq\\:inset-0{inset:0}.eloq\\:inset-x-0{inset-inline:0}.eloq\\:top-0{top:0}.eloq\\:top-0\\.5{top:calc(var(--eloq-spacing) * .5)}.eloq\\:-right-\\[9px\\]{right:-9px}.eloq\\:right-0\\.5{right:calc(var(--eloq-spacing) * .5)}.eloq\\:right-2{right:calc(var(--eloq-spacing) * 2)}.eloq\\:right-16{right:calc(var(--eloq-spacing) * 16)}.eloq\\:bottom-0{bottom:0}.eloq\\:bottom-1{bottom:var(--eloq-spacing)}.eloq\\:bottom-2{bottom:calc(var(--eloq-spacing) * 2)}.eloq\\:bottom-10{bottom:calc(var(--eloq-spacing) * 10)}.eloq\\:left-0{left:0}.eloq\\:left-2{left:calc(var(--eloq-spacing) * 2)}.eloq\\:left-\\[calc\\(50\\%-0\\.75rem\\)\\]{left:calc(50% - .75rem)}.eloq\\:z-10{z-index:10}.eloq\\:z-20{z-index:20}.eloq\\:z-30{z-index:30}.eloq\\:m-0{margin:0}.eloq\\:m-auto{margin:auto}.eloq\\:mx-1{margin-inline:var(--eloq-spacing)}.eloq\\:mx-auto{margin-inline:auto}.eloq\\:my-2{margin-block:calc(var(--eloq-spacing) * 2)}.eloq\\:my-4{margin-block:calc(var(--eloq-spacing) * 4)}.eloq\\:-mt-2{margin-top:calc(var(--eloq-spacing) * -2)}.eloq\\:-mt-6{margin-top:calc(var(--eloq-spacing) * -6)}.eloq\\:-mt-20{margin-top:calc(var(--eloq-spacing) * -20)}.eloq\\:mt-1{margin-top:var(--eloq-spacing)}.eloq\\:mt-2{margin-top:calc(var(--eloq-spacing) * 2)}.eloq\\:mt-10{margin-top:calc(var(--eloq-spacing) * 10)}.eloq\\:mr-1{margin-right:var(--eloq-spacing)}.eloq\\:mr-\\[2px\\]{margin-right:2px}.eloq\\:mb-1{margin-bottom:var(--eloq-spacing)}.eloq\\:mb-3{margin-bottom:calc(var(--eloq-spacing) * 3)}.eloq\\:mb-4{margin-bottom:calc(var(--eloq-spacing) * 4)}.eloq\\:mb-10{margin-bottom:calc(var(--eloq-spacing) * 10)}.eloq\\:ml-0{margin-left:0}.eloq\\:ml-1{margin-left:var(--eloq-spacing)}.eloq\\:ml-5{margin-left:calc(var(--eloq-spacing) * 5)}.eloq\\:box-content{box-sizing:content-box}.eloq\\:block{display:block}.eloq\\:flex{display:flex}.eloq\\:hidden{display:none}.eloq\\:inline-flex{display:inline-flex}.eloq\\:aspect-square{aspect-ratio:1}.eloq\\:h-1{height:var(--eloq-spacing)}.eloq\\:h-2\\.5{height:calc(var(--eloq-spacing) * 2.5)}.eloq\\:h-3{height:calc(var(--eloq-spacing) * 3)}.eloq\\:h-4{height:calc(var(--eloq-spacing) * 4)}.eloq\\:h-5{height:calc(var(--eloq-spacing) * 5)}.eloq\\:h-6{height:calc(var(--eloq-spacing) * 6)}.eloq\\:h-8{height:calc(var(--eloq-spacing) * 8)}.eloq\\:h-10{height:calc(var(--eloq-spacing) * 10)}.eloq\\:h-12{height:calc(var(--eloq-spacing) * 12)}.eloq\\:h-14{height:calc(var(--eloq-spacing) * 14)}.eloq\\:h-16{height:calc(var(--eloq-spacing) * 16)}.eloq\\:h-\\[0\\.42em\\]{height:.42em}.eloq\\:h-\\[160px\\]{height:160px}.eloq\\:h-\\[220px\\]{height:220px}.eloq\\:h-\\[560px\\]{height:560px}.eloq\\:h-\\[600px\\]{height:600px}.eloq\\:h-full{height:100%}.eloq\\:max-h-\\[132px\\]{max-height:132px}.eloq\\:min-h-\\[48px\\]{min-height:48px}.eloq\\:min-h-\\[80px\\]{min-height:80px}.eloq\\:w-2\\.5{width:calc(var(--eloq-spacing) * 2.5)}.eloq\\:w-2\\/3{width:66.6667%}.eloq\\:w-3{width:calc(var(--eloq-spacing) * 3)}.eloq\\:w-4{width:calc(var(--eloq-spacing) * 4)}.eloq\\:w-5{width:calc(var(--eloq-spacing) * 5)}.eloq\\:w-6{width:calc(var(--eloq-spacing) * 6)}.eloq\\:w-8{width:calc(var(--eloq-spacing) * 8)}.eloq\\:w-10{width:calc(var(--eloq-spacing) * 10)}.eloq\\:w-12{width:calc(var(--eloq-spacing) * 12)}.eloq\\:w-14{width:calc(var(--eloq-spacing) * 14)}.eloq\\:w-16{width:calc(var(--eloq-spacing) * 16)}.eloq\\:w-24{width:calc(var(--eloq-spacing) * 24)}.eloq\\:w-32{width:calc(var(--eloq-spacing) * 32)}.eloq\\:w-48{width:calc(var(--eloq-spacing) * 48)}.eloq\\:w-\\[0\\.42em\\]{width:.42em}.eloq\\:w-\\[70\\%\\]{width:70%}.eloq\\:w-\\[320px\\]{width:320px}.eloq\\:w-\\[340px\\]{width:340px}.eloq\\:w-\\[348px\\]{width:348px}.eloq\\:w-\\[380px\\]{width:380px}.eloq\\:w-\\[420px\\]{width:420px}.eloq\\:w-full{width:100%}.eloq\\:max-w-\\[75\\%\\]{max-width:75%}.eloq\\:max-w-\\[88\\%\\]{max-width:88%}.eloq\\:max-w-full{max-width:100%}.eloq\\:max-w-xs{max-width:var(--eloq-container-xs)}.eloq\\:min-w-0{min-width:0}.eloq\\:min-w-min{min-width:min-content}.eloq\\:flex-1{flex:1}.eloq\\:flex-none{flex:none}.eloq\\:flex-shrink-0,.eloq\\:shrink-0{flex-shrink:0}.eloq\\:flex-grow{flex-grow:1}.eloq\\:origin-bottom-right{transform-origin:100% 100%}.eloq\\:translate-x-0{--tw-translate-x:0px;translate:var(--tw-translate-x) var(--tw-translate-y)}.eloq\\:translate-x-8{--tw-translate-x:calc(var(--eloq-spacing) * 8);translate:var(--tw-translate-x) var(--tw-translate-y)}.eloq\\:scale-95{--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x) var(--tw-scale-y)}.eloq\\:scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}.eloq\\:-scale-x-100{--tw-scale-x: -100% ;scale:var(--tw-scale-x) var(--tw-scale-y)}.eloq\\:scale-\\[0\\.05\\]{scale:.05}.eloq\\:transform{transform:var(--tw-rotate-x,) var(--tw-rotate-y,) var(--tw-rotate-z,) var(--tw-skew-x,) var(--tw-skew-y,)}.eloq\\:animate-message-in{animation:var(--eloq-animate-message-in)}.eloq\\:animate-panel-in{animation:var(--eloq-animate-panel-in)}.eloq\\:animate-panel-out{animation:var(--eloq-animate-panel-out)}.eloq\\:animate-pulse{animation:var(--eloq-animate-pulse)}.eloq\\:animate-regenerating{animation:var(--eloq-animate-regenerating)}.eloq\\:animate-slide-up-in{animation:var(--eloq-animate-slide-up-in)}.eloq\\:animate-text-in{animation:var(--eloq-animate-text-in)}.eloq\\:animate-thinking-dot{animation:var(--eloq-animate-thinking-dot)}.eloq\\:animate-thinking-shimmer{animation:var(--eloq-animate-thinking-shimmer)}.eloq\\:cursor-default{cursor:default}.eloq\\:cursor-grab{cursor:grab}.eloq\\:cursor-pointer{cursor:pointer}.eloq\\:touch-none{touch-action:none}.eloq\\:resize-none{resize:none}.eloq\\:list-decimal{list-style-type:decimal}.eloq\\:list-disc{list-style-type:disc}.eloq\\:flex-col{flex-direction:column}.eloq\\:flex-row{flex-direction:row}.eloq\\:flex-wrap{flex-wrap:wrap}.eloq\\:items-center{align-items:center}.eloq\\:items-end{align-items:flex-end}.eloq\\:items-start{align-items:flex-start}.eloq\\:justify-between{justify-content:space-between}.eloq\\:justify-center{justify-content:center}.eloq\\:justify-end{justify-content:flex-end}.eloq\\:justify-start{justify-content:flex-start}.eloq\\:gap-1{gap:var(--eloq-spacing)}.eloq\\:gap-1\\.5{gap:calc(var(--eloq-spacing) * 1.5)}.eloq\\:gap-2{gap:calc(var(--eloq-spacing) * 2)}.eloq\\:gap-3{gap:calc(var(--eloq-spacing) * 3)}.eloq\\:gap-\\[0\\.25em\\]{gap:.25em}:where(.eloq\\:space-y-0>:not(:last-child)){--tw-space-y-reverse:0;margin-block:0}:where(.eloq\\:space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(var(--eloq-spacing) * var(--tw-space-y-reverse));margin-block-end:calc(var(--eloq-spacing) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-1\\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 1.5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 1.5) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-x-1>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(var(--eloq-spacing) * var(--tw-space-x-reverse));margin-inline-end:calc(var(--eloq-spacing) * calc(1 - var(--tw-space-x-reverse)))}:where(.eloq\\:space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--eloq-spacing) * 2) * var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--eloq-spacing) * 2) * calc(1 - var(--tw-space-x-reverse)))}:where(.eloq\\:space-x-3>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--eloq-spacing) * 3) * var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--eloq-spacing) * 3) * calc(1 - var(--tw-space-x-reverse)))}.eloq\\:self-end{align-self:flex-end}.eloq\\:self-stretch{align-self:stretch}.eloq\\:overflow-hidden{overflow:hidden}.eloq\\:overflow-x-auto{overflow-x:auto}.eloq\\:rounded-2xl{border-radius:var(--eloq-radius-2xl)}.eloq\\:rounded-3xl{border-radius:var(--eloq-radius-3xl)}.eloq\\:rounded-\\[inherit\\]{border-radius:inherit}.eloq\\:rounded-full{border-radius:3.40282e38px}.eloq\\:rounded-lg{border-radius:var(--eloq-radius-lg)}.eloq\\:rounded-md{border-radius:var(--eloq-radius-md)}.eloq\\:rounded-none{border-radius:0}.eloq\\:rounded-xl{border-radius:var(--eloq-radius-xl)}.eloq\\:rounded-t-2xl{border-top-left-radius:var(--eloq-radius-2xl);border-top-right-radius:var(--eloq-radius-2xl)}.eloq\\:border{border-style:var(--tw-border-style);border-width:1px}.eloq\\:border-0{border-style:var(--tw-border-style);border-width:0}.eloq\\:border-x{border-inline-style:var(--tw-border-style);border-inline-width:1px}.eloq\\:border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.eloq\\:border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.eloq\\:border-l-4{border-left-style:var(--tw-border-style);border-left-width:4px}.eloq\\:border-dashed{--tw-border-style:dashed;border-style:dashed}.eloq\\:border-amber-400{border-color:var(--eloq-color-amber-400)}.eloq\\:border-blue-500{border-color:var(--eloq-color-blue-500)}.eloq\\:border-border{border-color:hsl(var(--border))}.eloq\\:border-green-500{border-color:var(--eloq-color-green-500)}.eloq\\:border-input{border-color:hsl(var(--input))}.eloq\\:border-red-500{border-color:var(--eloq-color-red-500)}.eloq\\:border-t-transparent{border-top-color:#0000}.eloq\\:border-l-transparent{border-left-color:#0000}.eloq\\:bg-\\[\\#0a0a0a\\]{background-color:#0a0a0a}.eloq\\:bg-\\[\\#000\\]{background-color:#000}.eloq\\:bg-\\[\\#fff\\]{background-color:#fff}.eloq\\:bg-amber-50{background-color:var(--eloq-color-amber-50)}.eloq\\:bg-background{background-color:hsl(var(--background))}.eloq\\:bg-black\\/20{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:bg-black\\/20{background-color:color-mix(in oklab,var(--eloq-color-black) 20%,transparent)}}.eloq\\:bg-black\\/60{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:bg-black\\/60{background-color:color-mix(in oklab,var(--eloq-color-black) 60%,transparent)}}.eloq\\:bg-blue-50{background-color:var(--eloq-color-blue-50)}.eloq\\:bg-border{background-color:hsl(var(--border))}.eloq\\:bg-card{background-color:hsl(var(--card))}.eloq\\:bg-cream{background-color:hsl(var(--cream))}.eloq\\:bg-gray-400{background-color:var(--eloq-color-gray-400)}.eloq\\:bg-green-50{background-color:var(--eloq-color-green-50)}.eloq\\:bg-muted{background-color:hsl(var(--muted))}.eloq\\:bg-muted-foreground{background-color:hsl(var(--muted-foreground))}.eloq\\:bg-primary{background-color:hsl(var(--primary))}.eloq\\:bg-red-50{background-color:var(--eloq-color-red-50)}.eloq\\:bg-white,.eloq\\:bg-white\\/20{background-color:var(--eloq-color-white)}@supports (color:color-mix(in lab,red,red)){.eloq\\:bg-white\\/20{background-color:color-mix(in oklab,var(--eloq-color-white) 20%,transparent)}}.eloq\\:fill-none{fill:none}.eloq\\:fill-yellow-400{fill:var(--eloq-color-yellow-400)}.eloq\\:object-contain{object-fit:contain}.eloq\\:object-cover{object-fit:cover}.eloq\\:p-0{padding:0}.eloq\\:p-0\\.5{padding:calc(var(--eloq-spacing) * .5)}.eloq\\:p-1{padding:var(--eloq-spacing)}.eloq\\:p-1\\.5{padding:calc(var(--eloq-spacing) * 1.5)}.eloq\\:p-2{padding:calc(var(--eloq-spacing) * 2)}.eloq\\:p-3{padding:calc(var(--eloq-spacing) * 3)}.eloq\\:p-4{padding:calc(var(--eloq-spacing) * 4)}.eloq\\:p-6{padding:calc(var(--eloq-spacing) * 6)}.eloq\\:p-\\[1px\\]{padding:1px}.eloq\\:px-0{padding-inline:0}.eloq\\:px-2{padding-inline:calc(var(--eloq-spacing) * 2)}.eloq\\:px-3{padding-inline:calc(var(--eloq-spacing) * 3)}.eloq\\:px-4{padding-inline:calc(var(--eloq-spacing) * 4)}.eloq\\:px-5{padding-inline:calc(var(--eloq-spacing) * 5)}.eloq\\:px-\\[12px\\]{padding-inline:12px}.eloq\\:px-\\[16px\\]{padding-inline:16px}.eloq\\:py-1{padding-block:var(--eloq-spacing)}.eloq\\:py-1\\.5{padding-block:calc(var(--eloq-spacing) * 1.5)}.eloq\\:py-2{padding-block:calc(var(--eloq-spacing) * 2)}.eloq\\:py-3{padding-block:calc(var(--eloq-spacing) * 3)}.eloq\\:py-3\\.5{padding-block:calc(var(--eloq-spacing) * 3.5)}.eloq\\:py-\\[8px\\]{padding-block:8px}.eloq\\:py-\\[12px\\]{padding-block:12px}.eloq\\:pt-0{padding-top:0}.eloq\\:pt-2{padding-top:calc(var(--eloq-spacing) * 2)}.eloq\\:pt-4{padding-top:calc(var(--eloq-spacing) * 4)}.eloq\\:pt-5{padding-top:calc(var(--eloq-spacing) * 5)}.eloq\\:pt-6{padding-top:calc(var(--eloq-spacing) * 6)}.eloq\\:pt-10{padding-top:calc(var(--eloq-spacing) * 10)}.eloq\\:pt-24{padding-top:calc(var(--eloq-spacing) * 24)}.eloq\\:pr-2{padding-right:calc(var(--eloq-spacing) * 2)}.eloq\\:pr-4{padding-right:calc(var(--eloq-spacing) * 4)}.eloq\\:pr-12{padding-right:calc(var(--eloq-spacing) * 12)}.eloq\\:pb-2{padding-bottom:calc(var(--eloq-spacing) * 2)}.eloq\\:pb-4{padding-bottom:calc(var(--eloq-spacing) * 4)}.eloq\\:pb-10{padding-bottom:calc(var(--eloq-spacing) * 10)}.eloq\\:pb-14{padding-bottom:calc(var(--eloq-spacing) * 14)}.eloq\\:pl-3{padding-left:calc(var(--eloq-spacing) * 3)}.eloq\\:pl-4{padding-left:calc(var(--eloq-spacing) * 4)}.eloq\\:pl-11{padding-left:calc(var(--eloq-spacing) * 11)}.eloq\\:text-center{text-align:center}.eloq\\:text-left{text-align:left}.eloq\\:text-2xl{font-size:var(--eloq-text-2xl);line-height:var(--tw-leading,var(--eloq-text-2xl--line-height))}.eloq\\:text-base{font-size:var(--eloq-text-base);line-height:var(--tw-leading,var(--eloq-text-base--line-height))}.eloq\\:text-sm{font-size:var(--eloq-text-sm);line-height:var(--tw-leading,var(--eloq-text-sm--line-height))}.eloq\\:text-xs{font-size:var(--eloq-text-xs);line-height:var(--tw-leading,var(--eloq-text-xs--line-height))}.eloq\\:text-\\[10px\\]{font-size:10px}.eloq\\:leading-5{--tw-leading:calc(var(--eloq-spacing) * 5);line-height:calc(var(--eloq-spacing) * 5)}.eloq\\:leading-none{--tw-leading:1;line-height:1}.eloq\\:leading-relaxed{--tw-leading:var(--eloq-leading-relaxed);line-height:var(--eloq-leading-relaxed)}.eloq\\:font-medium{--tw-font-weight:var(--eloq-font-weight-medium);font-weight:var(--eloq-font-weight-medium)}.eloq\\:font-semibold{--tw-font-weight:var(--eloq-font-weight-semibold);font-weight:var(--eloq-font-weight-semibold)}.eloq\\:tracking-tight{--tw-tracking:var(--eloq-tracking-tight);letter-spacing:var(--eloq-tracking-tight)}.eloq\\:whitespace-nowrap{white-space:nowrap}.eloq\\:text-\\[\\#000\\]{color:#000}.eloq\\:text-\\[\\#fff\\]{color:#fff}.eloq\\:text-amber-500{color:var(--eloq-color-amber-500)}.eloq\\:text-amber-800{color:var(--eloq-color-amber-800)}.eloq\\:text-blue-500{color:var(--eloq-color-blue-500)}.eloq\\:text-blue-800{color:var(--eloq-color-blue-800)}.eloq\\:text-card-foreground{color:hsl(var(--card-foreground))}.eloq\\:text-destructive{color:hsl(var(--destructive))}.eloq\\:text-foreground{color:hsl(var(--foreground))}.eloq\\:text-gray-300{color:var(--eloq-color-gray-300)}.eloq\\:text-gray-400{color:var(--eloq-color-gray-400)}.eloq\\:text-gray-500{color:var(--eloq-color-gray-500)}.eloq\\:text-green-500{color:var(--eloq-color-green-500)}.eloq\\:text-green-800{color:var(--eloq-color-green-800)}.eloq\\:text-muted{color:hsl(var(--muted))}.eloq\\:text-muted-foreground{color:hsl(var(--muted-foreground))}.eloq\\:text-primary{color:hsl(var(--primary))}.eloq\\:text-primary-foreground{color:hsl(var(--primary-foreground))}.eloq\\:text-red-500{color:var(--eloq-color-red-500)}.eloq\\:text-red-800{color:var(--eloq-color-red-800)}.eloq\\:text-white{color:var(--eloq-color-white)}.eloq\\:text-yellow-400{color:var(--eloq-color-yellow-400)}.eloq\\:italic{font-style:italic}.eloq\\:underline{text-decoration-line:underline}.eloq\\:opacity-0{opacity:0}.eloq\\:opacity-50{opacity:.5}.eloq\\:opacity-70{opacity:.7}.eloq\\:opacity-75{opacity:.75}.eloq\\:opacity-100{opacity:1}.eloq\\:shadow-\\[0_-8px_24px_rgba\\(0\\,0\\,0\\,0\\.08\\)\\]{--tw-shadow:0 -8px 24px var(--tw-shadow-color,#00000014);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:shadow-\\[0_0_4px_0_rgba\\(0\\,0\\,0\\,0\\.20\\)\\]{--tw-shadow:0 0 4px 0 var(--tw-shadow-color,#0003);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:shadow-\\[0_3px_4px_-2px_rgba\\(0\\,0\\,0\\,0\\.04\\)\\]{--tw-shadow:0 3px 4px -2px var(--tw-shadow-color,#0000000a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:ring-offset-background{--tw-ring-offset-color:hsl(var(--background))}.eloq\\:outline-2{outline-style:var(--tw-outline-style);outline-width:2px}.eloq\\:outline-offset-2{outline-offset:2px}.eloq\\:outline-transparent{outline-color:#0000}.eloq\\:drop-shadow-lg{--tw-drop-shadow-size:drop-shadow(0 4px 4px var(--tw-drop-shadow-color,#00000026));--tw-drop-shadow:drop-shadow(var(--eloq-drop-shadow-lg));filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.eloq\\:transition-\\[outline-color\\]{transition-property:outline-color;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-\\[width\\]{transition-property:width;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:duration-150{--tw-duration:.15s;transition-duration:.15s}.eloq\\:duration-200{--tw-duration:.2s;transition-duration:.2s}.eloq\\:duration-300{--tw-duration:.3s;transition-duration:.3s}.eloq\\:duration-500{--tw-duration:.5s;transition-duration:.5s}.eloq\\:ease-out{--tw-ease:var(--eloq-ease-out);transition-timing-function:var(--eloq-ease-out)}.eloq\\:select-none{-webkit-user-select:none;user-select:none}.eloq\\:placeholder\\:text-muted-foreground::placeholder{color:hsl(var(--muted-foreground))}.eloq\\:last\\:mb-0:last-child{margin-bottom:0}@media(hover:hover){.eloq\\:hover\\:bg-black\\/5:hover{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:hover\\:bg-black\\/5:hover{background-color:color-mix(in oklab,var(--eloq-color-black) 5%,transparent)}}.eloq\\:hover\\:bg-black\\/80:hover{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:hover\\:bg-black\\/80:hover{background-color:color-mix(in oklab,var(--eloq-color-black) 80%,transparent)}}.eloq\\:hover\\:bg-muted:hover{background-color:hsl(var(--muted))}.eloq\\:hover\\:text-foreground:hover{color:hsl(var(--foreground))}.eloq\\:hover\\:text-gray-600:hover{color:var(--eloq-color-gray-600)}.eloq\\:hover\\:text-primary:hover{color:hsl(var(--primary))}.eloq\\:hover\\:opacity-80:hover{opacity:.8}.eloq\\:hover\\:opacity-90:hover{opacity:.9}.eloq\\:hover\\:opacity-100:hover{opacity:1}.eloq\\:hover\\:drop-shadow-xl:hover{--tw-drop-shadow-size:drop-shadow(0 9px 7px var(--tw-drop-shadow-color,#0000001a));--tw-drop-shadow:drop-shadow(var(--eloq-drop-shadow-xl));filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}}.eloq\\:focus-visible\\:ring-1:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:focus-visible\\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:focus-visible\\:ring-muted:focus-visible{--tw-ring-color:hsl(var(--muted))}.eloq\\:focus-visible\\:ring-primary:focus-visible{--tw-ring-color:hsl(var(--primary))}.eloq\\:focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)}.eloq\\:focus-visible\\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.eloq\\:active\\:cursor-grabbing:active{cursor:grabbing}.eloq\\:disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.eloq\\:disabled\\:opacity-50:disabled{opacity:.5}@media(prefers-reduced-motion:reduce){.eloq\\:motion-reduce\\:animate-none{animation:none}.eloq\\:motion-reduce\\:opacity-70{opacity:.7}}@media(min-width:40rem){.eloq\\:sm\\:text-sm{font-size:var(--eloq-text-sm);line-height:var(--tw-leading,var(--eloq-text-sm--line-height))}}@media(min-width:48rem){.eloq\\:md\\:text-sm{font-size:var(--eloq-text-sm);line-height:var(--tw-leading,var(--eloq-text-sm--line-height))}}.eloq\\:dark\\:border:is(.dark *){border-style:var(--tw-border-style);border-width:1px}.eloq\\:dark\\:border-b:is(.dark *){border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.eloq\\:dark\\:border-border:is(.dark *){border-color:hsl(var(--border))}.eloq\\:dark\\:bg-amber-400\\/10:is(.dark *){background-color:var(--eloq-color-amber-400)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-amber-400\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-amber-400) 10%,transparent)}}.eloq\\:dark\\:bg-blue-500\\/10:is(.dark *){background-color:var(--eloq-color-blue-500)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-blue-500\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-blue-500) 10%,transparent)}}.eloq\\:dark\\:bg-card:is(.dark *){background-color:hsl(var(--card))}.eloq\\:dark\\:bg-gray-200:is(.dark *){background-color:var(--eloq-color-gray-200)}.eloq\\:dark\\:bg-green-500\\/10:is(.dark *){background-color:var(--eloq-color-green-500)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-green-500\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-green-500) 10%,transparent)}}.eloq\\:dark\\:bg-muted:is(.dark *){background-color:hsl(var(--muted))}.eloq\\:dark\\:bg-red-500\\/10:is(.dark *){background-color:var(--eloq-color-red-500)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-red-500\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-red-500) 10%,transparent)}}.eloq\\:dark\\:text-amber-200:is(.dark *){color:var(--eloq-color-amber-200)}.eloq\\:dark\\:text-amber-400:is(.dark *){color:var(--eloq-color-amber-400)}.eloq\\:dark\\:text-blue-200:is(.dark *){color:var(--eloq-color-blue-200)}.eloq\\:dark\\:text-blue-400:is(.dark *){color:var(--eloq-color-blue-400)}.eloq\\:dark\\:text-gray-500:is(.dark *){color:var(--eloq-color-gray-500)}.eloq\\:dark\\:text-green-200:is(.dark *){color:var(--eloq-color-green-200)}.eloq\\:dark\\:text-green-400:is(.dark *){color:var(--eloq-color-green-400)}.eloq\\:dark\\:text-muted-foreground:is(.dark *),.eloq\\:dark\\:text-muted-foreground\\/50:is(.dark *){color:hsl(var(--muted-foreground))}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:text-muted-foreground\\/50:is(.dark *){color:color-mix(in oklab,hsl(var(--muted-foreground)) 50%,transparent)}}.eloq\\:dark\\:text-red-200:is(.dark *){color:var(--eloq-color-red-200)}.eloq\\:dark\\:text-red-400:is(.dark *){color:var(--eloq-color-red-400)}.eloq\\:dark\\:shadow-none:is(.dark *){--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}@media(hover:hover){.eloq\\:dark\\:hover\\:bg-white\\/10:is(.dark *):hover{background-color:var(--eloq-color-white)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:hover\\:bg-white\\/10:is(.dark *):hover{background-color:color-mix(in oklab,var(--eloq-color-white) 10%,transparent)}}.eloq\\:dark\\:hover\\:text-gray-300:is(.dark *):hover{color:var(--eloq-color-gray-300)}.eloq\\:dark\\:hover\\:text-primary:is(.dark *):hover{color:hsl(var(--primary))}}.no-scrollbar::-webkit-scrollbar{display:none}.no-scrollbar{-ms-overflow-style:none;scrollbar-width:none}}body{background-color:#0000}.eloquent-chat{font-family:system-ui,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol}.collapse{visibility:unset!important}.eloq-wrap-anywhere{overflow-wrap:anywhere}.eloq-thin-scrollbar{scrollbar-width:thin;scrollbar-color:hsl(var(--border)) transparent}.eloq-thin-scrollbar::-webkit-scrollbar{width:8px;height:8px}.eloq-thin-scrollbar::-webkit-scrollbar-thumb{background-color:hsl(var(--border));border-radius:9999px}.eloq-thin-scrollbar::-webkit-scrollbar-track{background-color:#0000}.eloq-test-mode-stripe{background:repeating-linear-gradient(-45deg,#f6e05e,#f6e05e 10px,#000 10px 20px)}.eloq-thinking-shimmer{--eloq-thinking-base:#9ca3af;--eloq-thinking-highlight:#4b5563;background:linear-gradient(90deg,var(--eloq-thinking-base) 0%,var(--eloq-thinking-base) 35%,var(--eloq-thinking-highlight) 50%,var(--eloq-thinking-base) 65%,var(--eloq-thinking-base) 100%);color:#0000;background-size:200% 100%;-webkit-background-clip:text;background-clip:text}.dark .eloq-thinking-shimmer{--eloq-thinking-base:#6b7280;--eloq-thinking-highlight:#e5e7eb}@media(prefers-reduced-motion:reduce){.eloq-thinking-shimmer{color:var(--eloq-thinking-base);background:0 0}}.eloq-regenerating-text{opacity:.4;transition:opacity .25s ease-out}.eloq-regenerating-sweep{border-radius:inherit;pointer-events:none;background:linear-gradient(100deg,#0000 30%,#ffffff8c,#0000 70%) 0 0/200% 100%;position:absolute;inset:0}.dark .eloq-regenerating-sweep{background-image:linear-gradient(100deg,#0000 30%,#ffffff1f,#0000 70%)}@media(prefers-reduced-motion:reduce){.eloq-regenerating-sweep{display:none}}@property --eloq-aura-angle{syntax:"<angle>";inherits:false;initial-value:0deg}.eloq-aura{--eloq-aura-strong:#9e9e9e;--eloq-aura-soft:#d1d1d1;background:conic-gradient(from var(--eloq-aura-angle),var(--eloq-aura-strong),var(--eloq-aura-soft),var(--eloq-aura-strong));border-radius:9999px;padding:2px;animation:2.6s linear infinite eloq-aura-spin;position:relative}@keyframes eloq-aura-spin{to{--eloq-aura-angle:360deg}}.eloq-aura-shine{border-radius:inherit;pointer-events:none;position:absolute;inset:0;overflow:hidden}.eloq-aura-shine:after{content:"";background:linear-gradient(90deg,#0000,#fffc,#0000);width:18%;position:absolute;top:-20%;bottom:-20%;left:0;transform:translate(-200%)skew(-20deg)}.eloq-aura-shine--active:after{animation:1.1s ease-in-out both eloq-aura-shine-sweep}@keyframes eloq-aura-shine-sweep{0%{transform:translate(-200%)skew(-20deg)}to{transform:translate(700%)skew(-20deg)}}@media(prefers-reduced-motion:reduce){.eloq-aura{animation:none}.eloq-aura-shine:after,.eloq-aura-shine--active:after{opacity:0;animation:none}}@keyframes panel-in{0%{opacity:0;transform:scale(.05)}to{opacity:1;transform:scale(1)}}@keyframes thinking-dot{0%,60%,to{opacity:.45;transform:translateY(0)}30%{opacity:1;transform:translateY(-3px)}}@keyframes regenerating-sweep{0%{background-position:150% 0}to{background-position:-50% 0}}@keyframes text-in{0%{opacity:0}to{opacity:1}}@keyframes thinking-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@keyframes panel-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.05)}}@keyframes message-in{0%{opacity:0;transform:translateY(.5rem)}to{opacity:1;transform:translateY(0)}}@keyframes slide-up-in{0%{transform:translateY(100%)}to{transform:translateY(0)}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-space-x-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@keyframes pulse{50%{opacity:.5}}', Qt = ".eloquentai-chat-launcher{transition:transform .2s ease-in-out}.eloquentai-chat-launcher:hover{transform:scale(1.1)}";
37
- function eo({
36
+ const Fe = '/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-space-x-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-ease:initial;--eloq-aura-angle:0deg}}}@layer theme{:root,:host{--eloq-font-sans:system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";--eloq-font-mono:ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--eloq-color-red-50:oklch(97.1% .013 17.38);--eloq-color-red-200:oklch(88.5% .062 18.334);--eloq-color-red-400:oklch(70.4% .191 22.216);--eloq-color-red-500:oklch(63.7% .237 25.331);--eloq-color-red-800:oklch(44.4% .177 26.899);--eloq-color-amber-50:oklch(98.7% .022 95.277);--eloq-color-amber-200:oklch(92.4% .12 95.746);--eloq-color-amber-400:oklch(82.8% .189 84.429);--eloq-color-amber-500:oklch(76.9% .188 70.08);--eloq-color-amber-800:oklch(47.3% .137 46.201);--eloq-color-yellow-400:oklch(85.2% .199 91.936);--eloq-color-green-50:oklch(98.2% .018 155.826);--eloq-color-green-200:oklch(92.5% .084 155.995);--eloq-color-green-400:oklch(79.2% .209 151.711);--eloq-color-green-500:oklch(72.3% .219 149.579);--eloq-color-green-800:oklch(44.8% .119 151.328);--eloq-color-blue-50:oklch(97% .014 254.604);--eloq-color-blue-200:oklch(88.2% .059 254.128);--eloq-color-blue-400:oklch(70.7% .165 254.624);--eloq-color-blue-500:oklch(62.3% .214 259.815);--eloq-color-blue-800:oklch(42.4% .199 265.638);--eloq-color-gray-200:oklch(92.8% .006 264.531);--eloq-color-gray-300:oklch(87.2% .01 258.338);--eloq-color-gray-400:oklch(70.7% .022 261.325);--eloq-color-gray-500:oklch(55.1% .027 264.364);--eloq-color-gray-600:oklch(44.6% .03 256.802);--eloq-color-black:#000;--eloq-color-white:#fff;--eloq-spacing:.25rem;--eloq-container-xs:20rem;--eloq-text-xs:.75rem;--eloq-text-xs--line-height:calc(1 / .75);--eloq-text-sm:.875rem;--eloq-text-sm--line-height:calc(1.25 / .875);--eloq-text-base:1rem;--eloq-text-base--line-height: 1.5 ;--eloq-text-2xl:1.5rem;--eloq-text-2xl--line-height:calc(2 / 1.5);--eloq-font-weight-medium:500;--eloq-font-weight-semibold:600;--eloq-tracking-tight:-.025em;--eloq-leading-relaxed:1.625;--eloq-radius-md:calc(var(--radius) - 2px);--eloq-radius-lg:var(--radius);--eloq-radius-xl:.75rem;--eloq-radius-2xl:1rem;--eloq-radius-3xl:1.5rem;--eloq-drop-shadow-lg:0 4px 4px #00000026;--eloq-drop-shadow-xl:0 9px 7px #0000001a;--eloq-ease-out:cubic-bezier(0, 0, .2, 1);--eloq-animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--eloq-default-transition-duration:.15s;--eloq-default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--eloq-default-font-family:var(--eloq-font-sans);--eloq-default-mono-font-family:var(--eloq-font-mono);--eloq-animate-panel-in:panel-in .35s cubic-bezier(.16, 1, .3, 1) both;--eloq-animate-panel-out:panel-out .25s cubic-bezier(.4, 0, 1, 1) both;--eloq-animate-thinking-dot:thinking-dot 1.2s ease-in-out infinite;--eloq-animate-thinking-shimmer:thinking-shimmer 1.8s linear infinite;--eloq-animate-regenerating:regenerating-sweep 1.2s linear infinite;--eloq-animate-text-in:text-in .35s ease-out both;--eloq-animate-message-in:message-in .3s ease-out both;--eloq-animate-slide-up-in:slide-up-in .3s ease-out both}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--eloq-default-font-family,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");font-feature-settings:var(--eloq-default-font-feature-settings,normal);font-variation-settings:var(--eloq-default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--eloq-default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);font-feature-settings:var(--eloq-default-mono-font-feature-settings,normal);font-variation-settings:var(--eloq-default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring:where(:not(iframe)){outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}:root{--background:0 0% 100%;--foreground:0 0% 3.9%;--card:0 0% 100%;--card-foreground:0 0% 3.9%;--popover:0 0% 100%;--popover-foreground:0 0% 3.9%;--primary:267 56% 46%;--primary-foreground:0 0% 98%;--secondary:0 0% 96.1%;--secondary-foreground:0 0% 9%;--muted:0 0% 96.1%;--muted-foreground:0 0% 45.1%;--accent:0 0% 96.1%;--accent-foreground:0 0% 9%;--destructive:0 84.2% 60.2%;--destructive-foreground:0 0% 98%;--border:0 0% 89.8%;--input:0 0% 89.8%;--ring:0 0% 3.9%;--cream:37.5 44% 96.5%;--chart-1:12 76% 61%;--chart-2:173 58% 39%;--chart-3:197 37% 24%;--chart-4:43 74% 66%;--chart-5:27 87% 67%;--radius:.5rem}.dark{--background:262 50% 10%;--foreground:262 5% 90%;--card:262 50% 10%;--card-foreground:262 5% 90%;--popover:262 50% 5%;--popover-foreground:262 5% 90%;--primary:262 62% 70%;--primary-foreground:0 0% 100%;--primary-dark:262 62% 60%;--secondary:262 30% 30%;--secondary-foreground:0 0% 100%;--secondary-dark:262 30% 20%;--secondary-light:262 30% 40%;--tertiary:267 56% 46%;--tertiary-foreground:0 0% 100%;--tertiary-dark:267 38% 25%;--tertiary-light:263 100% 85%;--muted:224 30% 25%;--muted-foreground:262 5% 90%;--accent:224 30% 25%;--accent-foreground:262 5% 100%;--accent-dark:224 30% 15%;--destructive:0 100% 30%;--destructive-foreground:262 5% 90%;--border:0 0% 30%;--input:262 30% 25%;--ring:262 62% 71%;--cream:257 28% 20%;--radius:.5rem;--sidebar-background:var(--background);--sidebar-foreground:var(--foreground);--sidebar-primary:var(--primary);--sidebar-primary-foreground:var(--primary-foreground);--sidebar-accent:var(--accent);--sidebar-accent-foreground:var(--accent-foreground);--sidebar-border:var(--border);--sidebar-ring:var(--ring)}*{border-color:hsl(var(--border))}body{background-color:hsl(var(--background));color:hsl(var(--foreground))}}@layer components;@layer utilities{.eloq\\:pointer-events-none{pointer-events:none}.eloq\\:sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.eloq\\:absolute{position:absolute}.eloq\\:relative{position:relative}.eloq\\:inset-0{inset:0}.eloq\\:inset-x-0{inset-inline:0}.eloq\\:top-0{top:0}.eloq\\:top-0\\.5{top:calc(var(--eloq-spacing) * .5)}.eloq\\:-right-\\[9px\\]{right:-9px}.eloq\\:right-0\\.5{right:calc(var(--eloq-spacing) * .5)}.eloq\\:right-2{right:calc(var(--eloq-spacing) * 2)}.eloq\\:right-16{right:calc(var(--eloq-spacing) * 16)}.eloq\\:bottom-0{bottom:0}.eloq\\:bottom-1{bottom:var(--eloq-spacing)}.eloq\\:bottom-2{bottom:calc(var(--eloq-spacing) * 2)}.eloq\\:bottom-10{bottom:calc(var(--eloq-spacing) * 10)}.eloq\\:left-0{left:0}.eloq\\:left-2{left:calc(var(--eloq-spacing) * 2)}.eloq\\:left-\\[calc\\(50\\%-0\\.75rem\\)\\]{left:calc(50% - .75rem)}.eloq\\:z-10{z-index:10}.eloq\\:z-20{z-index:20}.eloq\\:z-30{z-index:30}.eloq\\:m-0{margin:0}.eloq\\:m-auto{margin:auto}.eloq\\:mx-1{margin-inline:var(--eloq-spacing)}.eloq\\:mx-auto{margin-inline:auto}.eloq\\:my-2{margin-block:calc(var(--eloq-spacing) * 2)}.eloq\\:my-4{margin-block:calc(var(--eloq-spacing) * 4)}.eloq\\:-mt-2{margin-top:calc(var(--eloq-spacing) * -2)}.eloq\\:-mt-6{margin-top:calc(var(--eloq-spacing) * -6)}.eloq\\:-mt-20{margin-top:calc(var(--eloq-spacing) * -20)}.eloq\\:mt-1{margin-top:var(--eloq-spacing)}.eloq\\:mt-2{margin-top:calc(var(--eloq-spacing) * 2)}.eloq\\:mt-10{margin-top:calc(var(--eloq-spacing) * 10)}.eloq\\:mr-1{margin-right:var(--eloq-spacing)}.eloq\\:mr-\\[2px\\]{margin-right:2px}.eloq\\:mb-1{margin-bottom:var(--eloq-spacing)}.eloq\\:mb-3{margin-bottom:calc(var(--eloq-spacing) * 3)}.eloq\\:mb-4{margin-bottom:calc(var(--eloq-spacing) * 4)}.eloq\\:mb-10{margin-bottom:calc(var(--eloq-spacing) * 10)}.eloq\\:ml-0{margin-left:0}.eloq\\:ml-1{margin-left:var(--eloq-spacing)}.eloq\\:ml-5{margin-left:calc(var(--eloq-spacing) * 5)}.eloq\\:box-content{box-sizing:content-box}.eloq\\:block{display:block}.eloq\\:flex{display:flex}.eloq\\:hidden{display:none}.eloq\\:inline-flex{display:inline-flex}.eloq\\:aspect-square{aspect-ratio:1}.eloq\\:h-1{height:var(--eloq-spacing)}.eloq\\:h-2\\.5{height:calc(var(--eloq-spacing) * 2.5)}.eloq\\:h-3{height:calc(var(--eloq-spacing) * 3)}.eloq\\:h-4{height:calc(var(--eloq-spacing) * 4)}.eloq\\:h-5{height:calc(var(--eloq-spacing) * 5)}.eloq\\:h-6{height:calc(var(--eloq-spacing) * 6)}.eloq\\:h-8{height:calc(var(--eloq-spacing) * 8)}.eloq\\:h-10{height:calc(var(--eloq-spacing) * 10)}.eloq\\:h-12{height:calc(var(--eloq-spacing) * 12)}.eloq\\:h-14{height:calc(var(--eloq-spacing) * 14)}.eloq\\:h-16{height:calc(var(--eloq-spacing) * 16)}.eloq\\:h-\\[0\\.42em\\]{height:.42em}.eloq\\:h-\\[160px\\]{height:160px}.eloq\\:h-\\[220px\\]{height:220px}.eloq\\:h-\\[560px\\]{height:560px}.eloq\\:h-\\[600px\\]{height:600px}.eloq\\:h-full{height:100%}.eloq\\:max-h-\\[132px\\]{max-height:132px}.eloq\\:min-h-\\[48px\\]{min-height:48px}.eloq\\:min-h-\\[80px\\]{min-height:80px}.eloq\\:w-2\\.5{width:calc(var(--eloq-spacing) * 2.5)}.eloq\\:w-2\\/3{width:66.6667%}.eloq\\:w-3{width:calc(var(--eloq-spacing) * 3)}.eloq\\:w-4{width:calc(var(--eloq-spacing) * 4)}.eloq\\:w-5{width:calc(var(--eloq-spacing) * 5)}.eloq\\:w-6{width:calc(var(--eloq-spacing) * 6)}.eloq\\:w-8{width:calc(var(--eloq-spacing) * 8)}.eloq\\:w-10{width:calc(var(--eloq-spacing) * 10)}.eloq\\:w-12{width:calc(var(--eloq-spacing) * 12)}.eloq\\:w-14{width:calc(var(--eloq-spacing) * 14)}.eloq\\:w-16{width:calc(var(--eloq-spacing) * 16)}.eloq\\:w-24{width:calc(var(--eloq-spacing) * 24)}.eloq\\:w-32{width:calc(var(--eloq-spacing) * 32)}.eloq\\:w-48{width:calc(var(--eloq-spacing) * 48)}.eloq\\:w-\\[0\\.42em\\]{width:.42em}.eloq\\:w-\\[70\\%\\]{width:70%}.eloq\\:w-\\[320px\\]{width:320px}.eloq\\:w-\\[340px\\]{width:340px}.eloq\\:w-\\[348px\\]{width:348px}.eloq\\:w-\\[380px\\]{width:380px}.eloq\\:w-\\[420px\\]{width:420px}.eloq\\:w-full{width:100%}.eloq\\:max-w-\\[75\\%\\]{max-width:75%}.eloq\\:max-w-\\[88\\%\\]{max-width:88%}.eloq\\:max-w-full{max-width:100%}.eloq\\:max-w-xs{max-width:var(--eloq-container-xs)}.eloq\\:min-w-0{min-width:0}.eloq\\:min-w-min{min-width:min-content}.eloq\\:flex-1{flex:1}.eloq\\:flex-none{flex:none}.eloq\\:flex-shrink-0,.eloq\\:shrink-0{flex-shrink:0}.eloq\\:flex-grow{flex-grow:1}.eloq\\:origin-bottom-right{transform-origin:100% 100%}.eloq\\:translate-x-0{--tw-translate-x:0px;translate:var(--tw-translate-x) var(--tw-translate-y)}.eloq\\:translate-x-8{--tw-translate-x:calc(var(--eloq-spacing) * 8);translate:var(--tw-translate-x) var(--tw-translate-y)}.eloq\\:scale-95{--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x) var(--tw-scale-y)}.eloq\\:scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}.eloq\\:-scale-x-100{--tw-scale-x: -100% ;scale:var(--tw-scale-x) var(--tw-scale-y)}.eloq\\:scale-\\[0\\.05\\]{scale:.05}.eloq\\:transform{transform:var(--tw-rotate-x,) var(--tw-rotate-y,) var(--tw-rotate-z,) var(--tw-skew-x,) var(--tw-skew-y,)}.eloq\\:animate-message-in{animation:var(--eloq-animate-message-in)}.eloq\\:animate-panel-in{animation:var(--eloq-animate-panel-in)}.eloq\\:animate-panel-out{animation:var(--eloq-animate-panel-out)}.eloq\\:animate-pulse{animation:var(--eloq-animate-pulse)}.eloq\\:animate-regenerating{animation:var(--eloq-animate-regenerating)}.eloq\\:animate-slide-up-in{animation:var(--eloq-animate-slide-up-in)}.eloq\\:animate-text-in{animation:var(--eloq-animate-text-in)}.eloq\\:animate-thinking-dot{animation:var(--eloq-animate-thinking-dot)}.eloq\\:animate-thinking-shimmer{animation:var(--eloq-animate-thinking-shimmer)}.eloq\\:cursor-default{cursor:default}.eloq\\:cursor-grab{cursor:grab}.eloq\\:cursor-pointer{cursor:pointer}.eloq\\:touch-none{touch-action:none}.eloq\\:resize-none{resize:none}.eloq\\:list-decimal{list-style-type:decimal}.eloq\\:list-disc{list-style-type:disc}.eloq\\:flex-col{flex-direction:column}.eloq\\:flex-row{flex-direction:row}.eloq\\:flex-wrap{flex-wrap:wrap}.eloq\\:items-center{align-items:center}.eloq\\:items-end{align-items:flex-end}.eloq\\:items-start{align-items:flex-start}.eloq\\:justify-between{justify-content:space-between}.eloq\\:justify-center{justify-content:center}.eloq\\:justify-end{justify-content:flex-end}.eloq\\:justify-start{justify-content:flex-start}.eloq\\:gap-1{gap:var(--eloq-spacing)}.eloq\\:gap-1\\.5{gap:calc(var(--eloq-spacing) * 1.5)}.eloq\\:gap-2{gap:calc(var(--eloq-spacing) * 2)}.eloq\\:gap-3{gap:calc(var(--eloq-spacing) * 3)}.eloq\\:gap-\\[0\\.25em\\]{gap:.25em}:where(.eloq\\:space-y-0>:not(:last-child)){--tw-space-y-reverse:0;margin-block:0}:where(.eloq\\:space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(var(--eloq-spacing) * var(--tw-space-y-reverse));margin-block-end:calc(var(--eloq-spacing) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-1\\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 1.5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 1.5) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--eloq-spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--eloq-spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.eloq\\:space-x-1>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(var(--eloq-spacing) * var(--tw-space-x-reverse));margin-inline-end:calc(var(--eloq-spacing) * calc(1 - var(--tw-space-x-reverse)))}:where(.eloq\\:space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--eloq-spacing) * 2) * var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--eloq-spacing) * 2) * calc(1 - var(--tw-space-x-reverse)))}:where(.eloq\\:space-x-3>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--eloq-spacing) * 3) * var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--eloq-spacing) * 3) * calc(1 - var(--tw-space-x-reverse)))}.eloq\\:self-end{align-self:flex-end}.eloq\\:self-stretch{align-self:stretch}.eloq\\:overflow-hidden{overflow:hidden}.eloq\\:overflow-x-auto{overflow-x:auto}.eloq\\:rounded-2xl{border-radius:var(--eloq-radius-2xl)}.eloq\\:rounded-3xl{border-radius:var(--eloq-radius-3xl)}.eloq\\:rounded-\\[inherit\\]{border-radius:inherit}.eloq\\:rounded-full{border-radius:3.40282e38px}.eloq\\:rounded-lg{border-radius:var(--eloq-radius-lg)}.eloq\\:rounded-md{border-radius:var(--eloq-radius-md)}.eloq\\:rounded-none{border-radius:0}.eloq\\:rounded-xl{border-radius:var(--eloq-radius-xl)}.eloq\\:rounded-t-2xl{border-top-left-radius:var(--eloq-radius-2xl);border-top-right-radius:var(--eloq-radius-2xl)}.eloq\\:border{border-style:var(--tw-border-style);border-width:1px}.eloq\\:border-0{border-style:var(--tw-border-style);border-width:0}.eloq\\:border-x{border-inline-style:var(--tw-border-style);border-inline-width:1px}.eloq\\:border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.eloq\\:border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.eloq\\:border-l-4{border-left-style:var(--tw-border-style);border-left-width:4px}.eloq\\:border-dashed{--tw-border-style:dashed;border-style:dashed}.eloq\\:border-amber-400{border-color:var(--eloq-color-amber-400)}.eloq\\:border-blue-500{border-color:var(--eloq-color-blue-500)}.eloq\\:border-border{border-color:hsl(var(--border))}.eloq\\:border-green-500{border-color:var(--eloq-color-green-500)}.eloq\\:border-input{border-color:hsl(var(--input))}.eloq\\:border-red-500{border-color:var(--eloq-color-red-500)}.eloq\\:border-t-transparent{border-top-color:#0000}.eloq\\:border-l-transparent{border-left-color:#0000}.eloq\\:bg-\\[\\#0a0a0a\\]{background-color:#0a0a0a}.eloq\\:bg-\\[\\#000\\]{background-color:#000}.eloq\\:bg-\\[\\#fff\\]{background-color:#fff}.eloq\\:bg-amber-50{background-color:var(--eloq-color-amber-50)}.eloq\\:bg-background{background-color:hsl(var(--background))}.eloq\\:bg-black\\/20{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:bg-black\\/20{background-color:color-mix(in oklab,var(--eloq-color-black) 20%,transparent)}}.eloq\\:bg-black\\/60{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:bg-black\\/60{background-color:color-mix(in oklab,var(--eloq-color-black) 60%,transparent)}}.eloq\\:bg-blue-50{background-color:var(--eloq-color-blue-50)}.eloq\\:bg-border{background-color:hsl(var(--border))}.eloq\\:bg-card{background-color:hsl(var(--card))}.eloq\\:bg-cream{background-color:hsl(var(--cream))}.eloq\\:bg-gray-400{background-color:var(--eloq-color-gray-400)}.eloq\\:bg-green-50{background-color:var(--eloq-color-green-50)}.eloq\\:bg-muted{background-color:hsl(var(--muted))}.eloq\\:bg-muted-foreground{background-color:hsl(var(--muted-foreground))}.eloq\\:bg-primary{background-color:hsl(var(--primary))}.eloq\\:bg-red-50{background-color:var(--eloq-color-red-50)}.eloq\\:bg-white,.eloq\\:bg-white\\/20{background-color:var(--eloq-color-white)}@supports (color:color-mix(in lab,red,red)){.eloq\\:bg-white\\/20{background-color:color-mix(in oklab,var(--eloq-color-white) 20%,transparent)}}.eloq\\:fill-none{fill:none}.eloq\\:fill-yellow-400{fill:var(--eloq-color-yellow-400)}.eloq\\:object-contain{object-fit:contain}.eloq\\:object-cover{object-fit:cover}.eloq\\:p-0{padding:0}.eloq\\:p-0\\.5{padding:calc(var(--eloq-spacing) * .5)}.eloq\\:p-1{padding:var(--eloq-spacing)}.eloq\\:p-1\\.5{padding:calc(var(--eloq-spacing) * 1.5)}.eloq\\:p-2{padding:calc(var(--eloq-spacing) * 2)}.eloq\\:p-3{padding:calc(var(--eloq-spacing) * 3)}.eloq\\:p-4{padding:calc(var(--eloq-spacing) * 4)}.eloq\\:p-6{padding:calc(var(--eloq-spacing) * 6)}.eloq\\:p-\\[1px\\]{padding:1px}.eloq\\:px-0{padding-inline:0}.eloq\\:px-2{padding-inline:calc(var(--eloq-spacing) * 2)}.eloq\\:px-3{padding-inline:calc(var(--eloq-spacing) * 3)}.eloq\\:px-4{padding-inline:calc(var(--eloq-spacing) * 4)}.eloq\\:px-5{padding-inline:calc(var(--eloq-spacing) * 5)}.eloq\\:px-\\[12px\\]{padding-inline:12px}.eloq\\:px-\\[16px\\]{padding-inline:16px}.eloq\\:py-1{padding-block:var(--eloq-spacing)}.eloq\\:py-1\\.5{padding-block:calc(var(--eloq-spacing) * 1.5)}.eloq\\:py-2{padding-block:calc(var(--eloq-spacing) * 2)}.eloq\\:py-3{padding-block:calc(var(--eloq-spacing) * 3)}.eloq\\:py-3\\.5{padding-block:calc(var(--eloq-spacing) * 3.5)}.eloq\\:py-\\[8px\\]{padding-block:8px}.eloq\\:py-\\[12px\\]{padding-block:12px}.eloq\\:pt-0{padding-top:0}.eloq\\:pt-2{padding-top:calc(var(--eloq-spacing) * 2)}.eloq\\:pt-4{padding-top:calc(var(--eloq-spacing) * 4)}.eloq\\:pt-5{padding-top:calc(var(--eloq-spacing) * 5)}.eloq\\:pt-6{padding-top:calc(var(--eloq-spacing) * 6)}.eloq\\:pt-10{padding-top:calc(var(--eloq-spacing) * 10)}.eloq\\:pt-24{padding-top:calc(var(--eloq-spacing) * 24)}.eloq\\:pr-2{padding-right:calc(var(--eloq-spacing) * 2)}.eloq\\:pr-4{padding-right:calc(var(--eloq-spacing) * 4)}.eloq\\:pr-12{padding-right:calc(var(--eloq-spacing) * 12)}.eloq\\:pb-2{padding-bottom:calc(var(--eloq-spacing) * 2)}.eloq\\:pb-4{padding-bottom:calc(var(--eloq-spacing) * 4)}.eloq\\:pb-10{padding-bottom:calc(var(--eloq-spacing) * 10)}.eloq\\:pb-14{padding-bottom:calc(var(--eloq-spacing) * 14)}.eloq\\:pl-3{padding-left:calc(var(--eloq-spacing) * 3)}.eloq\\:pl-4{padding-left:calc(var(--eloq-spacing) * 4)}.eloq\\:pl-11{padding-left:calc(var(--eloq-spacing) * 11)}.eloq\\:text-center{text-align:center}.eloq\\:text-left{text-align:left}.eloq\\:text-2xl{font-size:var(--eloq-text-2xl);line-height:var(--tw-leading,var(--eloq-text-2xl--line-height))}.eloq\\:text-base{font-size:var(--eloq-text-base);line-height:var(--tw-leading,var(--eloq-text-base--line-height))}.eloq\\:text-sm{font-size:var(--eloq-text-sm);line-height:var(--tw-leading,var(--eloq-text-sm--line-height))}.eloq\\:text-xs{font-size:var(--eloq-text-xs);line-height:var(--tw-leading,var(--eloq-text-xs--line-height))}.eloq\\:text-\\[10px\\]{font-size:10px}.eloq\\:leading-5{--tw-leading:calc(var(--eloq-spacing) * 5);line-height:calc(var(--eloq-spacing) * 5)}.eloq\\:leading-none{--tw-leading:1;line-height:1}.eloq\\:leading-relaxed{--tw-leading:var(--eloq-leading-relaxed);line-height:var(--eloq-leading-relaxed)}.eloq\\:font-medium{--tw-font-weight:var(--eloq-font-weight-medium);font-weight:var(--eloq-font-weight-medium)}.eloq\\:font-semibold{--tw-font-weight:var(--eloq-font-weight-semibold);font-weight:var(--eloq-font-weight-semibold)}.eloq\\:tracking-tight{--tw-tracking:var(--eloq-tracking-tight);letter-spacing:var(--eloq-tracking-tight)}.eloq\\:whitespace-nowrap{white-space:nowrap}.eloq\\:text-\\[\\#000\\]{color:#000}.eloq\\:text-\\[\\#fff\\]{color:#fff}.eloq\\:text-amber-500{color:var(--eloq-color-amber-500)}.eloq\\:text-amber-800{color:var(--eloq-color-amber-800)}.eloq\\:text-blue-500{color:var(--eloq-color-blue-500)}.eloq\\:text-blue-800{color:var(--eloq-color-blue-800)}.eloq\\:text-card-foreground{color:hsl(var(--card-foreground))}.eloq\\:text-destructive{color:hsl(var(--destructive))}.eloq\\:text-foreground{color:hsl(var(--foreground))}.eloq\\:text-gray-300{color:var(--eloq-color-gray-300)}.eloq\\:text-gray-400{color:var(--eloq-color-gray-400)}.eloq\\:text-gray-500{color:var(--eloq-color-gray-500)}.eloq\\:text-green-500{color:var(--eloq-color-green-500)}.eloq\\:text-green-800{color:var(--eloq-color-green-800)}.eloq\\:text-muted{color:hsl(var(--muted))}.eloq\\:text-muted-foreground{color:hsl(var(--muted-foreground))}.eloq\\:text-primary{color:hsl(var(--primary))}.eloq\\:text-primary-foreground{color:hsl(var(--primary-foreground))}.eloq\\:text-red-500{color:var(--eloq-color-red-500)}.eloq\\:text-red-800{color:var(--eloq-color-red-800)}.eloq\\:text-white{color:var(--eloq-color-white)}.eloq\\:text-yellow-400{color:var(--eloq-color-yellow-400)}.eloq\\:italic{font-style:italic}.eloq\\:underline{text-decoration-line:underline}.eloq\\:opacity-0{opacity:0}.eloq\\:opacity-50{opacity:.5}.eloq\\:opacity-70{opacity:.7}.eloq\\:opacity-75{opacity:.75}.eloq\\:opacity-100{opacity:1}.eloq\\:shadow-\\[0_-8px_24px_rgba\\(0\\,0\\,0\\,0\\.08\\)\\]{--tw-shadow:0 -8px 24px var(--tw-shadow-color,#00000014);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:shadow-\\[0_0_4px_0_rgba\\(0\\,0\\,0\\,0\\.20\\)\\]{--tw-shadow:0 0 4px 0 var(--tw-shadow-color,#0003);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:shadow-\\[0_3px_4px_-2px_rgba\\(0\\,0\\,0\\,0\\.04\\)\\]{--tw-shadow:0 3px 4px -2px var(--tw-shadow-color,#0000000a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:ring-offset-background{--tw-ring-offset-color:hsl(var(--background))}.eloq\\:outline-2{outline-style:var(--tw-outline-style);outline-width:2px}.eloq\\:outline-offset-2{outline-offset:2px}.eloq\\:outline-transparent{outline-color:#0000}.eloq\\:drop-shadow-lg{--tw-drop-shadow-size:drop-shadow(0 4px 4px var(--tw-drop-shadow-color,#00000026));--tw-drop-shadow:drop-shadow(var(--eloq-drop-shadow-lg));filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.eloq\\:transition-\\[outline-color\\]{transition-property:outline-color;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-\\[width\\]{transition-property:width;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--eloq-default-transition-timing-function));transition-duration:var(--tw-duration,var(--eloq-default-transition-duration))}.eloq\\:duration-150{--tw-duration:.15s;transition-duration:.15s}.eloq\\:duration-200{--tw-duration:.2s;transition-duration:.2s}.eloq\\:duration-300{--tw-duration:.3s;transition-duration:.3s}.eloq\\:duration-500{--tw-duration:.5s;transition-duration:.5s}.eloq\\:ease-out{--tw-ease:var(--eloq-ease-out);transition-timing-function:var(--eloq-ease-out)}.eloq\\:select-none{-webkit-user-select:none;user-select:none}.eloq\\:placeholder\\:text-muted-foreground::placeholder{color:hsl(var(--muted-foreground))}.eloq\\:last\\:mb-0:last-child{margin-bottom:0}@media(hover:hover){.eloq\\:hover\\:bg-black\\/5:hover{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:hover\\:bg-black\\/5:hover{background-color:color-mix(in oklab,var(--eloq-color-black) 5%,transparent)}}.eloq\\:hover\\:bg-black\\/80:hover{background-color:var(--eloq-color-black)}@supports (color:color-mix(in lab,red,red)){.eloq\\:hover\\:bg-black\\/80:hover{background-color:color-mix(in oklab,var(--eloq-color-black) 80%,transparent)}}.eloq\\:hover\\:bg-muted:hover{background-color:hsl(var(--muted))}.eloq\\:hover\\:text-foreground:hover{color:hsl(var(--foreground))}.eloq\\:hover\\:text-gray-600:hover{color:var(--eloq-color-gray-600)}.eloq\\:hover\\:text-primary:hover{color:hsl(var(--primary))}.eloq\\:hover\\:opacity-80:hover{opacity:.8}.eloq\\:hover\\:opacity-90:hover{opacity:.9}.eloq\\:hover\\:opacity-100:hover{opacity:1}.eloq\\:hover\\:drop-shadow-xl:hover{--tw-drop-shadow-size:drop-shadow(0 9px 7px var(--tw-drop-shadow-color,#0000001a));--tw-drop-shadow:drop-shadow(var(--eloq-drop-shadow-xl));filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}}.eloq\\:focus-visible\\:ring-1:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:focus-visible\\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.eloq\\:focus-visible\\:ring-muted:focus-visible{--tw-ring-color:hsl(var(--muted))}.eloq\\:focus-visible\\:ring-primary:focus-visible{--tw-ring-color:hsl(var(--primary))}.eloq\\:focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)}.eloq\\:focus-visible\\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.eloq\\:active\\:cursor-grabbing:active{cursor:grabbing}.eloq\\:disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.eloq\\:disabled\\:opacity-50:disabled{opacity:.5}@media(prefers-reduced-motion:reduce){.eloq\\:motion-reduce\\:animate-none{animation:none}.eloq\\:motion-reduce\\:opacity-70{opacity:.7}}@media(min-width:40rem){.eloq\\:sm\\:text-sm{font-size:var(--eloq-text-sm);line-height:var(--tw-leading,var(--eloq-text-sm--line-height))}}@media(min-width:48rem){.eloq\\:md\\:text-sm{font-size:var(--eloq-text-sm);line-height:var(--tw-leading,var(--eloq-text-sm--line-height))}}.eloq\\:dark\\:border:is(.dark *){border-style:var(--tw-border-style);border-width:1px}.eloq\\:dark\\:border-b:is(.dark *){border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.eloq\\:dark\\:border-border:is(.dark *){border-color:hsl(var(--border))}.eloq\\:dark\\:bg-amber-400\\/10:is(.dark *){background-color:var(--eloq-color-amber-400)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-amber-400\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-amber-400) 10%,transparent)}}.eloq\\:dark\\:bg-blue-500\\/10:is(.dark *){background-color:var(--eloq-color-blue-500)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-blue-500\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-blue-500) 10%,transparent)}}.eloq\\:dark\\:bg-card:is(.dark *){background-color:hsl(var(--card))}.eloq\\:dark\\:bg-gray-200:is(.dark *){background-color:var(--eloq-color-gray-200)}.eloq\\:dark\\:bg-green-500\\/10:is(.dark *){background-color:var(--eloq-color-green-500)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-green-500\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-green-500) 10%,transparent)}}.eloq\\:dark\\:bg-muted:is(.dark *){background-color:hsl(var(--muted))}.eloq\\:dark\\:bg-red-500\\/10:is(.dark *){background-color:var(--eloq-color-red-500)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:bg-red-500\\/10:is(.dark *){background-color:color-mix(in oklab,var(--eloq-color-red-500) 10%,transparent)}}.eloq\\:dark\\:text-amber-200:is(.dark *){color:var(--eloq-color-amber-200)}.eloq\\:dark\\:text-amber-400:is(.dark *){color:var(--eloq-color-amber-400)}.eloq\\:dark\\:text-blue-200:is(.dark *){color:var(--eloq-color-blue-200)}.eloq\\:dark\\:text-blue-400:is(.dark *){color:var(--eloq-color-blue-400)}.eloq\\:dark\\:text-gray-500:is(.dark *){color:var(--eloq-color-gray-500)}.eloq\\:dark\\:text-green-200:is(.dark *){color:var(--eloq-color-green-200)}.eloq\\:dark\\:text-green-400:is(.dark *){color:var(--eloq-color-green-400)}.eloq\\:dark\\:text-muted-foreground:is(.dark *),.eloq\\:dark\\:text-muted-foreground\\/50:is(.dark *){color:hsl(var(--muted-foreground))}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:text-muted-foreground\\/50:is(.dark *){color:color-mix(in oklab,hsl(var(--muted-foreground)) 50%,transparent)}}.eloq\\:dark\\:text-red-200:is(.dark *){color:var(--eloq-color-red-200)}.eloq\\:dark\\:text-red-400:is(.dark *){color:var(--eloq-color-red-400)}.eloq\\:dark\\:shadow-none:is(.dark *){--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}@media(hover:hover){.eloq\\:dark\\:hover\\:bg-white\\/10:is(.dark *):hover{background-color:var(--eloq-color-white)}@supports (color:color-mix(in lab,red,red)){.eloq\\:dark\\:hover\\:bg-white\\/10:is(.dark *):hover{background-color:color-mix(in oklab,var(--eloq-color-white) 10%,transparent)}}.eloq\\:dark\\:hover\\:text-gray-300:is(.dark *):hover{color:var(--eloq-color-gray-300)}.eloq\\:dark\\:hover\\:text-primary:is(.dark *):hover{color:hsl(var(--primary))}}.no-scrollbar::-webkit-scrollbar{display:none}.no-scrollbar{-ms-overflow-style:none;scrollbar-width:none}}body{background-color:#0000}.eloquent-chat{font-family:system-ui,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol}.collapse{visibility:unset!important}.eloq-wrap-anywhere{overflow-wrap:anywhere}.eloq-thin-scrollbar{scrollbar-width:thin;scrollbar-color:hsl(var(--border)) transparent}.eloq-thin-scrollbar::-webkit-scrollbar{width:8px;height:8px}.eloq-thin-scrollbar::-webkit-scrollbar-thumb{background-color:hsl(var(--border));border-radius:9999px}.eloq-thin-scrollbar::-webkit-scrollbar-track{background-color:#0000}.eloq-test-mode-stripe{background:repeating-linear-gradient(-45deg,#f6e05e,#f6e05e 10px,#000 10px 20px)}.eloq-thinking-shimmer{--eloq-thinking-base:#9ca3af;--eloq-thinking-highlight:#4b5563;background:linear-gradient(90deg,var(--eloq-thinking-base) 0%,var(--eloq-thinking-base) 35%,var(--eloq-thinking-highlight) 50%,var(--eloq-thinking-base) 65%,var(--eloq-thinking-base) 100%);color:#0000;background-size:200% 100%;-webkit-background-clip:text;background-clip:text}.dark .eloq-thinking-shimmer{--eloq-thinking-base:#6b7280;--eloq-thinking-highlight:#e5e7eb}@media(prefers-reduced-motion:reduce){.eloq-thinking-shimmer{color:var(--eloq-thinking-base);background:0 0}}.eloq-regenerating-text{opacity:.4;transition:opacity .25s ease-out}.eloq-regenerating-sweep{border-radius:inherit;pointer-events:none;background:linear-gradient(100deg,#0000 30%,#ffffff8c,#0000 70%) 0 0/200% 100%;position:absolute;inset:0}.dark .eloq-regenerating-sweep{background-image:linear-gradient(100deg,#0000 30%,#ffffff1f,#0000 70%)}@media(prefers-reduced-motion:reduce){.eloq-regenerating-sweep{display:none}}@property --eloq-aura-angle{syntax:"<angle>";inherits:false;initial-value:0deg}.eloq-aura{--eloq-aura-strong:#9e9e9e;--eloq-aura-soft:#d1d1d1;background:conic-gradient(from var(--eloq-aura-angle),var(--eloq-aura-strong),var(--eloq-aura-soft),var(--eloq-aura-strong));border-radius:9999px;padding:2px;animation:2.6s linear infinite eloq-aura-spin;position:relative}@keyframes eloq-aura-spin{to{--eloq-aura-angle:360deg}}.eloq-aura-shine{border-radius:inherit;pointer-events:none;position:absolute;inset:0;overflow:hidden}.eloq-aura-shine:after{content:"";background:linear-gradient(90deg,#0000,#fffc,#0000);width:18%;position:absolute;top:-20%;bottom:-20%;left:0;transform:translate(-200%)skew(-20deg)}.eloq-aura-shine--active:after{animation:1.1s ease-in-out both eloq-aura-shine-sweep}@keyframes eloq-aura-shine-sweep{0%{transform:translate(-200%)skew(-20deg)}to{transform:translate(700%)skew(-20deg)}}@media(prefers-reduced-motion:reduce){.eloq-aura{animation:none}.eloq-aura-shine:after,.eloq-aura-shine--active:after{opacity:0;animation:none}}@keyframes panel-in{0%{opacity:0;transform:scale(.05)}to{opacity:1;transform:scale(1)}}@keyframes thinking-dot{0%,60%,to{opacity:.45;transform:translateY(0)}30%{opacity:1;transform:translateY(-3px)}}@keyframes regenerating-sweep{0%{background-position:150% 0}to{background-position:-50% 0}}@keyframes text-in{0%{opacity:0}to{opacity:1}}@keyframes thinking-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@keyframes panel-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.05)}}@keyframes message-in{0%{opacity:0;transform:translateY(.5rem)}to{opacity:1;transform:translateY(0)}}@keyframes slide-up-in{0%{transform:translateY(100%)}to{transform:translateY(0)}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-space-x-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@keyframes pulse{50%{opacity:.5}}', to = ".eloquentai-chat-launcher{transition:transform .2s ease-in-out}.eloquentai-chat-launcher:hover{transform:scale(1.1)}";
37
+ function oo({
38
38
  toggleBubble: e,
39
39
  isDarkMode: t = !1
40
40
  }) {
41
41
  const o = t ? "#fff" : "#000", r = t ? "#000000" : "#ffffff";
42
- return /* @__PURE__ */ x("div", { className: "eloq:absolute eloq:inset-0 eloq:m-auto eloq:flex eloq:items-center eloq:justify-center eloq:overflow-hidden", children: /* @__PURE__ */ x(
42
+ return /* @__PURE__ */ _("div", { className: "eloq:absolute eloq:inset-0 eloq:m-auto eloq:flex eloq:items-center eloq:justify-center eloq:overflow-hidden", children: /* @__PURE__ */ _(
43
43
  "div",
44
44
  {
45
- className: Qe(
45
+ className: nt(
46
46
  "eloq:chat-bubble eloq:relative eloq:flex eloq:items-center eloq:justify-center eloq:w-12 eloq:h-12 eloq:rounded-full eloq:cursor-pointer",
47
47
  // Inverted in dark mode: a black launcher disappears on dark pages.
48
48
  t ? "eloq:bg-[#fff] eloq:text-[#000]" : "eloq:bg-[#000] eloq:text-[#fff]"
49
49
  ),
50
50
  onClick: e,
51
- children: /* @__PURE__ */ x("div", { className: "eloq:absolute eloq:inset-0 eloq:flex eloq:justify-center eloq:items-center eloq:m-auto", children: /* @__PURE__ */ x(Tt, { bgColor: o, fgColor: r }) })
51
+ children: /* @__PURE__ */ _("div", { className: "eloq:absolute eloq:inset-0 eloq:flex eloq:justify-center eloq:items-center eloq:m-auto", children: /* @__PURE__ */ _(At, { bgColor: o, fgColor: r }) })
52
52
  }
53
53
  ) });
54
54
  }
55
- function Ke({ children: e, head: t, ...o }) {
56
- const [r, n] = _(null), i = r?.contentWindow?.document?.head, c = r?.contentWindow?.document?.body;
57
- return /* @__PURE__ */ ze("iframe", { ...o, ref: n, children: [
58
- i && Ge(t, i),
59
- c && Ge(e, c)
55
+ function Je({ children: e, head: t, ...o }) {
56
+ const [r, n] = S(null), a = r?.contentWindow?.document?.head, c = r?.contentWindow?.document?.body;
57
+ return /* @__PURE__ */ Oe("iframe", { ...o, ref: n, children: [
58
+ a && tt(t, a),
59
+ c && tt(e, c)
60
60
  ] });
61
61
  }
62
- function to({ children: e, container: t }) {
63
- return Ge(e, t);
62
+ function ro({ children: e, container: t }) {
63
+ return tt(e, t);
64
64
  }
65
- function oo({
65
+ function no({
66
66
  message: e,
67
67
  isVisible: t,
68
68
  onDismiss: o,
69
69
  onMessageClick: r,
70
70
  autoHideDelay: n
71
71
  }) {
72
- const [i, c] = _(!1), [s, u] = _("entering"), a = Mt();
73
- return Z(() => {
72
+ const [a, c] = S(!1), [s, u] = S("entering"), i = Pt();
73
+ return F(() => {
74
74
  if (t) {
75
75
  c(!0), u("entering");
76
76
  const l = setTimeout(() => {
@@ -92,10 +92,10 @@ function oo({
92
92
  }, 300);
93
93
  return () => clearTimeout(l);
94
94
  }
95
- }, [t, o, n]), i ? /* @__PURE__ */ x(
95
+ }, [t, o, n]), a ? /* @__PURE__ */ _(
96
96
  "div",
97
97
  {
98
- className: Qe(
98
+ className: nt(
99
99
  // right-16 leaves a ~7px gap between the tail tip and the launcher
100
100
  // circle's edge — the tail points at it without sliding underneath.
101
101
  "eloq:absolute eloq:right-16 eloq:bottom-0 eloq:max-w-xs eloq:transform eloq:transition-all eloq:duration-500 eloq:ease-out",
@@ -103,56 +103,56 @@ function oo({
103
103
  s === "visible" && "eloq:translate-x-0 eloq:opacity-100 eloq:scale-100",
104
104
  s === "exiting" && "eloq:translate-x-8 eloq:opacity-0 eloq:scale-95"
105
105
  ),
106
- children: /* @__PURE__ */ x("div", { className: "eloq:relative eloq:drop-shadow-lg eloq:hover:drop-shadow-xl eloq:transition-all eloq:duration-300", children: /* @__PURE__ */ ze(
106
+ children: /* @__PURE__ */ _("div", { className: "eloq:relative eloq:drop-shadow-lg eloq:hover:drop-shadow-xl eloq:transition-all eloq:duration-300", children: /* @__PURE__ */ Oe(
107
107
  "div",
108
108
  {
109
109
  className: "eloq:relative eloq:rounded-lg eloq:border eloq:p-3 eloq:cursor-pointer",
110
110
  style: {
111
- backgroundColor: a.botBubbleColor
111
+ backgroundColor: i.botBubbleColor
112
112
  },
113
113
  onClick: r,
114
114
  children: [
115
- /* @__PURE__ */ ze(
115
+ /* @__PURE__ */ Oe(
116
116
  "svg",
117
117
  {
118
118
  "aria-hidden": !0,
119
119
  className: "eloq:absolute eloq:bottom-1 eloq:-right-[9px] eloq:h-4 eloq:w-4 eloq:-scale-x-100",
120
120
  viewBox: "0 0 10.54 11.14",
121
121
  children: [
122
- /* @__PURE__ */ x(
122
+ /* @__PURE__ */ _(
123
123
  "path",
124
124
  {
125
125
  d: "M5.75,0s0,.36,0,.51c-.09,4.52-5.74,10.64-5.74,10.64,8.19.02,10.54-2.26,10.54-2.26h0c-1.6-2.96-3.19-5.92-4.79-8.88Z",
126
- fill: a.botBubbleColor,
126
+ fill: i.botBubbleColor,
127
127
  strokeWidth: 2,
128
128
  vectorEffect: "non-scaling-stroke",
129
129
  style: { stroke: "hsl(var(--border))" }
130
130
  }
131
131
  ),
132
- /* @__PURE__ */ x(
132
+ /* @__PURE__ */ _(
133
133
  "rect",
134
134
  {
135
135
  x: "6.2",
136
136
  y: "-1",
137
137
  width: "6",
138
138
  height: "14",
139
- fill: a.botBubbleColor
139
+ fill: i.botBubbleColor
140
140
  }
141
141
  )
142
142
  ]
143
143
  }
144
144
  ),
145
- /* @__PURE__ */ x(
145
+ /* @__PURE__ */ _(
146
146
  "p",
147
147
  {
148
148
  className: "eloq:text-sm eloq:leading-relaxed eloq:pr-4",
149
149
  style: {
150
- color: a.botBubbleTextColor || at(a.botBubbleColor)
150
+ color: i.botBubbleTextColor || ct(i.botBubbleColor)
151
151
  },
152
152
  children: e
153
153
  }
154
154
  ),
155
- /* @__PURE__ */ x(
155
+ /* @__PURE__ */ _(
156
156
  "button",
157
157
  {
158
158
  "aria-label": "Dismiss message",
@@ -163,9 +163,9 @@ function oo({
163
163
  style: {
164
164
  // Follows the bubble's computed text colour, so the X blends
165
165
  // with the message on any bubble background (and dark mode).
166
- color: a.botBubbleTextColor || at(a.botBubbleColor)
166
+ color: i.botBubbleTextColor || ct(i.botBubbleColor)
167
167
  },
168
- children: /* @__PURE__ */ x(Pt, { className: "eloq:w-2.5 eloq:h-2.5", strokeWidth: 1.75 })
168
+ children: /* @__PURE__ */ _(Ot, { className: "eloq:w-2.5 eloq:h-2.5", strokeWidth: 1.75 })
169
169
  }
170
170
  )
171
171
  ]
@@ -174,24 +174,24 @@ function oo({
174
174
  }
175
175
  ) : null;
176
176
  }
177
- function lt(e) {
177
+ function pt(e) {
178
178
  if (typeof document > "u") return null;
179
179
  const t = document.cookie.match(new RegExp(`(?:^|; )${e}=([^;]*)`));
180
180
  return t ? decodeURIComponent(t[1]) : null;
181
181
  }
182
- function ro(e, t, o) {
182
+ function ao(e, t, o) {
183
183
  if (typeof document > "u") return;
184
184
  const r = new Date(Date.now() + o * 60 * 60 * 1e3).toUTCString();
185
185
  document.cookie = `${e}=${encodeURIComponent(t)}; expires=${r}; path=/; SameSite=Lax`;
186
186
  }
187
- function no(e) {
187
+ function io(e) {
188
188
  typeof document > "u" || (document.cookie = `${e}=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/`);
189
189
  }
190
- function ao({
190
+ function so({
191
191
  chatProps: e,
192
192
  chatSettings: t
193
193
  }) {
194
- return Je(() => t ? {
194
+ return et(() => t ? {
195
195
  assistantName: t.agent_name,
196
196
  assistantLogo: t.avatar_url || void 0,
197
197
  theme: {
@@ -219,7 +219,7 @@ function ao({
219
219
  subtitle: t.subtitle || "Ask me anything"
220
220
  } : e, [e, t]);
221
221
  }
222
- function io() {
222
+ function lo() {
223
223
  if (typeof window > "u")
224
224
  return {};
225
225
  const e = new URLSearchParams(window.location.search), t = {};
@@ -227,9 +227,9 @@ function io() {
227
227
  t[r] = o;
228
228
  }), t;
229
229
  }
230
- const so = "eloquent-ai::conversation-data", Ce = typeof window < "u", lo = 1800 * 1e3;
231
- function tt({ appId: e }) {
232
- const t = Je(() => `${so}-${e}`, [e]), o = Je(
230
+ const co = "eloquent-ai::conversation-data", Te = typeof window < "u", uo = 1800 * 1e3;
231
+ function it({ appId: e }) {
232
+ const t = et(() => `${co}-${e}`, [e]), o = et(
233
233
  () => ({
234
234
  conversationId: null,
235
235
  userId: null,
@@ -239,31 +239,31 @@ function tt({ appId: e }) {
239
239
  []
240
240
  ), r = w(() => {
241
241
  try {
242
- if (!Ce) return o;
243
- const a = localStorage.getItem(t);
244
- return a ? JSON.parse(a) : o;
245
- } catch (a) {
242
+ if (!Te) return o;
243
+ const i = localStorage.getItem(t);
244
+ return i ? JSON.parse(i) : o;
245
+ } catch (i) {
246
246
  return console.error(
247
247
  "Error retrieving conversation data from localStorage:",
248
- a
248
+ i
249
249
  ), o;
250
250
  }
251
251
  }, [t, o]), n = w(() => {
252
252
  try {
253
- const a = r();
254
- return a.lastActivity ? Date.now() - a.lastActivity > lo : !0;
255
- } catch (a) {
256
- return console.error("Error checking conversation expiration:", a), !0;
253
+ const i = r();
254
+ return i.lastActivity ? Date.now() - i.lastActivity > uo : !0;
255
+ } catch (i) {
256
+ return console.error("Error checking conversation expiration:", i), !0;
257
257
  }
258
- }, [r]), i = w(
259
- (a, l, d, p, h) => {
258
+ }, [r]), a = w(
259
+ (i, l, d, p, h) => {
260
260
  try {
261
- if (!Ce) return;
261
+ if (!Te) return;
262
262
  const f = {
263
- conversationId: a,
263
+ conversationId: i,
264
264
  userId: l,
265
265
  deviceId: p,
266
- messages: co(d),
266
+ messages: po(d),
267
267
  lastActivity: Date.now(),
268
268
  chatToken: h
269
269
  };
@@ -275,24 +275,24 @@ function tt({ appId: e }) {
275
275
  [t]
276
276
  ), c = w(() => {
277
277
  try {
278
- if (!Ce) return;
279
- const a = r();
278
+ if (!Te) return;
279
+ const i = r();
280
280
  localStorage.setItem(
281
281
  t,
282
- JSON.stringify({ ...a, isChatClosed: !0 })
282
+ JSON.stringify({ ...i, isChatClosed: !0 })
283
283
  );
284
- } catch (a) {
284
+ } catch (i) {
285
285
  console.error(
286
286
  "Error marking conversation as closed in localStorage:",
287
- a
287
+ i
288
288
  );
289
289
  }
290
290
  }, [t, r]), s = w(() => {
291
291
  try {
292
- if (!Ce) return;
293
- const a = localStorage.getItem(t);
294
- if (a) {
295
- const l = JSON.parse(a);
292
+ if (!Te) return;
293
+ const i = localStorage.getItem(t);
294
+ if (i) {
295
+ const l = JSON.parse(i);
296
296
  localStorage.setItem(
297
297
  t,
298
298
  JSON.stringify({
@@ -302,160 +302,160 @@ function tt({ appId: e }) {
302
302
  })
303
303
  );
304
304
  }
305
- } catch (a) {
305
+ } catch (i) {
306
306
  console.error(
307
307
  "Error clearing conversation data from localStorage:",
308
- a
308
+ i
309
309
  );
310
310
  }
311
311
  }, [t, o]), u = w(() => {
312
312
  try {
313
- if (!Ce) return;
314
- const a = r();
315
- a.conversationId && (a.lastActivity = Date.now(), localStorage.setItem(t, JSON.stringify(a)));
316
- } catch (a) {
317
- console.error("Error updating last activity timestamp:", a);
313
+ if (!Te) return;
314
+ const i = r();
315
+ i.conversationId && (i.lastActivity = Date.now(), localStorage.setItem(t, JSON.stringify(i)));
316
+ } catch (i) {
317
+ console.error("Error updating last activity timestamp:", i);
318
318
  }
319
319
  }, [r, t]);
320
320
  return {
321
321
  isChatExpired: n,
322
- saveChatData: i,
322
+ saveChatData: a,
323
323
  clearChatData: s,
324
324
  getSavedChatData: r,
325
325
  updateLastActivity: u,
326
326
  markChatClosed: c
327
327
  };
328
328
  }
329
- function co(e) {
329
+ function po(e) {
330
330
  return e.flatMap((t) => {
331
331
  if (!t.attachments) return [t];
332
- const o = t.attachments.filter((r) => At(r.url)).map(({ url: r, mimeType: n, name: i }) => ({ url: r, mimeType: n, name: i }));
332
+ const o = t.attachments.filter((r) => Ut(r.url)).map(({ url: r, mimeType: n, name: a }) => ({ url: r, mimeType: n, name: a }));
333
333
  return o.length > 0 ? [{ ...t, attachments: o }] : t.content ? [{ ...t, attachments: void 0 }] : [];
334
334
  });
335
335
  }
336
- const uo = "aws-appsync-event-ws", po = 15e3, ho = 3e5, fo = 5e3, go = 1;
337
- function mo(e) {
336
+ const ho = "aws-appsync-event-ws", fo = 15e3, go = 3e5, mo = 5e3, bo = 1;
337
+ function wo(e) {
338
338
  const t = new URL(e);
339
339
  return /\.appsync-api\.[\w-]+\.amazonaws\.com(\.cn)?$/.test(t.hostname) && (t.hostname = t.hostname.replace(
340
340
  ".appsync-api.",
341
341
  ".appsync-realtime-api."
342
342
  )), t.protocol = "wss:", t.pathname = `${t.pathname.replace(/\/$/, "")}/realtime`, t.toString();
343
343
  }
344
- function bo(e, t) {
344
+ function vo(e, t) {
345
345
  const o = new URL(e).host;
346
346
  return "authorizationToken" in t ? { Authorization: t.authorizationToken, host: o } : { "x-api-key": t.apiKey, host: o };
347
347
  }
348
- function vo(e) {
348
+ function qo(e) {
349
349
  return `header-${btoa(JSON.stringify(e)).replace(/\+/g, "-").replace(/\//g, "_").replace(/=+$/, "")}`;
350
350
  }
351
- function Ve(e) {
351
+ function Ge(e) {
352
352
  return !e || e.length === 0 ? "unknown error" : e.map((t) => `${t.errorType ?? "Error"}: ${t.message ?? ""}`).join("; ");
353
353
  }
354
- function wo(e) {
354
+ function yo(e) {
355
355
  const {
356
356
  httpEndpoint: t,
357
357
  auth: o,
358
358
  channel: r,
359
359
  onEvent: n,
360
- onDisconnect: i,
360
+ onDisconnect: a,
361
361
  createWebSocket: c = (l, d) => new WebSocket(l, d)
362
- } = e, s = bo(t, o), u = mo(t), a = crypto.randomUUID();
362
+ } = e, s = vo(t, o), u = wo(t), i = crypto.randomUUID();
363
363
  return new Promise((l, d) => {
364
364
  let p;
365
365
  try {
366
366
  p = c(u, [
367
- uo,
368
- vo(s)
367
+ ho,
368
+ qo(s)
369
369
  ]);
370
- } catch (m) {
371
- d(m instanceof Error ? m : new Error(String(m)));
370
+ } catch (b) {
371
+ d(b instanceof Error ? b : new Error(String(b)));
372
372
  return;
373
373
  }
374
- let h = "connecting", f = !1, g = ho, k = Date.now(), q = null, I = null;
375
- const j = () => {
376
- q && (clearTimeout(q), q = null), I && (clearInterval(I), I = null);
377
- }, S = (m) => {
374
+ let h = "connecting", f = !1, g = go, R = Date.now(), v = null, z = null;
375
+ const A = () => {
376
+ v && (clearTimeout(v), v = null), z && (clearInterval(z), z = null);
377
+ }, E = (b) => {
378
378
  if (h === "closed") return;
379
- const y = h === "established";
380
- h = "closed", j();
379
+ const q = h === "established";
380
+ h = "closed", A();
381
381
  try {
382
382
  p.close();
383
383
  } catch {
384
384
  }
385
- f || (y ? i(m) : d(new Error(m)));
386
- }, $ = (m) => {
387
- p.readyState === go && p.send(JSON.stringify(m));
388
- }, R = (m) => {
389
- q && clearTimeout(q), q = setTimeout(() => {
390
- S(`Timed out waiting for ${m}`);
391
- }, po);
385
+ f || (q ? a(b) : d(new Error(b)));
386
+ }, j = (b) => {
387
+ p.readyState === bo && p.send(JSON.stringify(b));
388
+ }, P = (b) => {
389
+ v && clearTimeout(v), v = setTimeout(() => {
390
+ E(`Timed out waiting for ${b}`);
391
+ }, fo);
392
392
  };
393
393
  p.addEventListener("open", () => {
394
- h !== "closed" && ($({ type: "connection_init" }), R("connection_ack"));
395
- }), p.addEventListener("message", (m) => {
394
+ h !== "closed" && (j({ type: "connection_init" }), P("connection_ack"));
395
+ }), p.addEventListener("message", (b) => {
396
396
  if (h === "closed") return;
397
- let y;
397
+ let q;
398
398
  try {
399
- y = JSON.parse(String(m.data));
399
+ q = JSON.parse(String(b.data));
400
400
  } catch {
401
401
  console.warn("[EloquentChatSDK] Unparseable realtime frame ignored");
402
402
  return;
403
403
  }
404
- switch (y.type) {
404
+ switch (q.type) {
405
405
  case "connection_ack": {
406
406
  if (h !== "connecting") return;
407
- h = "subscribing", typeof y.connectionTimeoutMs == "number" && (g = y.connectionTimeoutMs), $({
407
+ h = "subscribing", typeof q.connectionTimeoutMs == "number" && (g = q.connectionTimeoutMs), j({
408
408
  type: "subscribe",
409
- id: a,
409
+ id: i,
410
410
  channel: r,
411
411
  authorization: s
412
- }), R("subscribe_success");
412
+ }), P("subscribe_success");
413
413
  return;
414
414
  }
415
415
  case "connection_error": {
416
- S(`Connection error: ${Ve(y.errors)}`);
416
+ E(`Connection error: ${Ge(q.errors)}`);
417
417
  return;
418
418
  }
419
419
  case "subscribe_success": {
420
- if (h !== "subscribing" || y.id !== a) return;
421
- h = "established", q && (clearTimeout(q), q = null), k = Date.now(), I = setInterval(() => {
422
- Date.now() - k > g && S("Keep-alive timeout");
423
- }, fo), l({
420
+ if (h !== "subscribing" || q.id !== i) return;
421
+ h = "established", v && (clearTimeout(v), v = null), R = Date.now(), z = setInterval(() => {
422
+ Date.now() - R > g && E("Keep-alive timeout");
423
+ }, mo), l({
424
424
  close: () => {
425
- f = !0, $({ type: "unsubscribe", id: a }), S("Closed by client");
425
+ f = !0, j({ type: "unsubscribe", id: i }), E("Closed by client");
426
426
  }
427
427
  });
428
428
  return;
429
429
  }
430
430
  case "subscribe_error": {
431
- if (y.id !== a) return;
432
- S(`Subscribe error: ${Ve(y.errors)}`);
431
+ if (q.id !== i) return;
432
+ E(`Subscribe error: ${Ge(q.errors)}`);
433
433
  return;
434
434
  }
435
435
  case "ka": {
436
- k = Date.now();
436
+ R = Date.now();
437
437
  return;
438
438
  }
439
439
  case "data": {
440
- if (y.id !== a) return;
441
- k = Date.now();
442
- let P = y.event;
443
- if (typeof P == "string")
440
+ if (q.id !== i) return;
441
+ R = Date.now();
442
+ let C = q.event;
443
+ if (typeof C == "string")
444
444
  try {
445
- P = JSON.parse(P);
445
+ C = JSON.parse(C);
446
446
  } catch {
447
447
  console.warn(
448
448
  "[EloquentChatSDK] Unparseable realtime event ignored"
449
449
  );
450
450
  return;
451
451
  }
452
- n(P);
452
+ n(C);
453
453
  return;
454
454
  }
455
455
  case "broadcast_error": {
456
456
  console.warn(
457
457
  "[EloquentChatSDK] Realtime broadcast error:",
458
- Ve(y.errors)
458
+ Ge(q.errors)
459
459
  );
460
460
  return;
461
461
  }
@@ -463,16 +463,16 @@ function wo(e) {
463
463
  return;
464
464
  }
465
465
  }), p.addEventListener("close", () => {
466
- S("WebSocket closed");
466
+ E("WebSocket closed");
467
467
  }), p.addEventListener("error", () => {
468
- S("WebSocket error");
468
+ E("WebSocket error");
469
469
  });
470
470
  });
471
471
  }
472
- function qo(e, t) {
472
+ function xo(e, t) {
473
473
  return typeof t == "bigint" ? t.toString() : t;
474
474
  }
475
- class yo {
475
+ class ko {
476
476
  constructor(t) {
477
477
  this._getter = t, this._value = void 0;
478
478
  }
@@ -481,14 +481,14 @@ class yo {
481
481
  return t !== void 0 && (this._value = t(), this._getter = void 0), this._value;
482
482
  }
483
483
  }
484
- function xo(e) {
485
- return new yo(e);
484
+ function _o(e) {
485
+ return new ko(e);
486
486
  }
487
- function yt(e) {
487
+ function It(e) {
488
488
  const t = e.startsWith("^") ? 1 : 0, o = e.endsWith("$") ? e.length - 1 : e.length;
489
489
  return e.slice(t, o);
490
490
  }
491
- function ko(e, t, o) {
491
+ function Co(e, t, o) {
492
492
  Object.defineProperty(e, t, {
493
493
  value: o,
494
494
  writable: !0,
@@ -496,28 +496,28 @@ function ko(e, t, o) {
496
496
  configurable: !0
497
497
  });
498
498
  }
499
- const xt = "captureStackTrace" in Error ? Error.captureStackTrace : (...e) => {
499
+ const Rt = "captureStackTrace" in Error ? Error.captureStackTrace : (...e) => {
500
500
  };
501
- function Ye(e) {
501
+ function ot(e) {
502
502
  return typeof e == "object" && e !== null && !Array.isArray(e);
503
503
  }
504
- function _o(e) {
505
- if (Ye(e) === !1)
504
+ function So(e) {
505
+ if (ot(e) === !1)
506
506
  return !1;
507
507
  const t = e.constructor;
508
508
  if (t === void 0 || typeof t != "function")
509
509
  return !0;
510
510
  const o = t.prototype;
511
- return !(Ye(o) === !1 || Object.prototype.hasOwnProperty.call(o, "isPrototypeOf") === !1);
511
+ return !(ot(o) === !1 || Object.prototype.hasOwnProperty.call(o, "isPrototypeOf") === !1);
512
512
  }
513
- function ct(e) {
513
+ function ht(e) {
514
514
  return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
515
515
  }
516
- function Co(e, t, o) {
516
+ function Io(e, t, o) {
517
517
  const r = new e._zod.constr(t ?? e._zod.def);
518
518
  return (!t || o?.parent) && (r._zod.parent = e), r;
519
519
  }
520
- function ye(e) {
520
+ function Ce(e) {
521
521
  const t = e;
522
522
  if (!t)
523
523
  return {};
@@ -530,10 +530,10 @@ function ye(e) {
530
530
  }
531
531
  return delete t.message, typeof t.error == "string" ? { ...t, error: () => t.error } : t;
532
532
  }
533
- function So(e) {
533
+ function Ro(e) {
534
534
  return Object.keys(e).filter((t) => e[t]._zod.optin !== void 0 && e[t]._zod.optout === "optional");
535
535
  }
536
- function qe(e, t = 0) {
536
+ function _e(e, t = 0) {
537
537
  if (e.aborted === !0)
538
538
  return !0;
539
539
  for (let o = t; o < e.issues.length; o++)
@@ -541,7 +541,7 @@ function qe(e, t = 0) {
541
541
  return !0;
542
542
  return !1;
543
543
  }
544
- function Io(e, t = 0) {
544
+ function Eo(e, t = 0) {
545
545
  if (e.aborted === !0)
546
546
  return !0;
547
547
  for (let o = t; o < e.issues.length; o++)
@@ -549,80 +549,80 @@ function Io(e, t = 0) {
549
549
  return !0;
550
550
  return !1;
551
551
  }
552
- function Ie(e, t) {
552
+ function Ae(e, t) {
553
553
  return t.map((o) => {
554
554
  var r;
555
555
  return (r = o).path ?? (r.path = []), o.path.unshift(e), o;
556
556
  });
557
557
  }
558
- function Se(e) {
558
+ function Me(e) {
559
559
  return typeof e == "string" ? e : e?.message;
560
560
  }
561
- function ut(e, t, o) {
561
+ function ft(e, t, o) {
562
562
  var r;
563
563
  for (let n = t; n < e.length; n++)
564
564
  (r = e[n]).schema ?? (r.schema = o);
565
565
  }
566
- function xe(e, t, o) {
566
+ function Se(e, t, o) {
567
567
  var r;
568
568
  const n = e.inst?._zod?.traits;
569
569
  n?.has("$ZodType") && (n.has("$ZodCheck") ? (r = e).schema ?? (r.schema = e.inst) : e.schema = e.inst);
570
- const i = e.schema !== e.inst ? e.schema?._zod.def?.error : void 0, c = e.message ? e.message : Se(e.inst?._zod.def?.error?.(e)) ?? Se(i?.(e)) ?? Se(t?.error?.(e)) ?? Se(o.customError?.(e)) ?? Se(o.localeError?.(e)) ?? "Invalid input", s = {};
570
+ const a = e.schema !== e.inst ? e.schema?._zod.def?.error : void 0, c = e.message ? e.message : Me(e.inst?._zod.def?.error?.(e)) ?? Me(a?.(e)) ?? Me(t?.error?.(e)) ?? Me(o.customError?.(e)) ?? Me(o.localeError?.(e)) ?? "Invalid input", s = {};
571
571
  for (const u of Object.keys(e))
572
572
  u === "inst" || u === "schema" || u === "continue" || u === "input" || u === "__proto__" || (s[u] = e[u]);
573
573
  return s.path ?? (s.path = []), s.message = c, t?.reportInput && (s.input = e.input), s;
574
574
  }
575
- function Eo(e, t) {
575
+ function zo(e, t) {
576
576
  for (const o in t) {
577
577
  const r = Object.getOwnPropertyDescriptor(t, o);
578
- r.get ? Object.defineProperty(e, o, { ...r, enumerable: !1 }) : Ro(e, o, r.value);
578
+ r.get ? Object.defineProperty(e, o, { ...r, enumerable: !1 }) : Mo(e, o, r.value);
579
579
  }
580
580
  }
581
- function Re(e, t, o, r = !0) {
581
+ function Ue(e, t, o, r = !0) {
582
582
  return Object.defineProperty(e, t, { configurable: !0, writable: !0, enumerable: r, value: o }), o;
583
583
  }
584
- function zo(e, t, o) {
585
- return Re(e, t, o, !1);
584
+ function To(e, t, o) {
585
+ return Ue(e, t, o, !1);
586
586
  }
587
- function Ro(e, t, o) {
587
+ function Mo(e, t, o) {
588
588
  Object.defineProperty(e, t, {
589
589
  configurable: !0,
590
590
  get() {
591
- return this == null ? o : Re(this, t, o.bind(this));
591
+ return this == null ? o : Ue(this, t, o.bind(this));
592
592
  },
593
593
  set(r) {
594
- Re(this, t, r);
594
+ Ue(this, t, r);
595
595
  }
596
596
  });
597
597
  }
598
- function To(e, t) {
598
+ function Ao(e, t) {
599
599
  const o = Object.getPrototypeOf(e);
600
600
  return t in o ? void 0 : o;
601
601
  }
602
- let He, be = !1;
603
- const Mo = {
602
+ let Ye, qe = !1;
603
+ const Po = {
604
604
  configurable: !0,
605
605
  get() {
606
- be = !0;
606
+ qe = !0;
607
607
  }
608
608
  };
609
- function ue(e, t, o) {
609
+ function me(e, t, o) {
610
610
  const r = Object.getPrototypeOf(e._zod);
611
- if (t in r && He !== e._zod) {
612
- He = void 0;
611
+ if (t in r && Ye !== e._zod) {
612
+ Ye = void 0;
613
613
  return;
614
614
  }
615
- He = e._zod, Object.defineProperty(r, t, {
615
+ Ye = e._zod, Object.defineProperty(r, t, {
616
616
  configurable: !0,
617
617
  get() {
618
- Object.defineProperty(this, t, Mo);
619
- const n = be;
620
- be = !1;
618
+ Object.defineProperty(this, t, Po);
619
+ const n = qe;
620
+ qe = !1;
621
621
  try {
622
- const i = o(this);
623
- return be ? delete this[t] : Object.defineProperty(this, t, { configurable: !0, writable: !0, value: i }), be = be || n, i;
624
- } catch (i) {
625
- throw delete this[t], be = be || n, i;
622
+ const a = o(this);
623
+ return qe ? delete this[t] : Object.defineProperty(this, t, { configurable: !0, writable: !0, value: a }), qe = qe || n, a;
624
+ } catch (a) {
625
+ throw delete this[t], qe = qe || n, a;
626
626
  }
627
627
  },
628
628
  set(n) {
@@ -630,31 +630,31 @@ function ue(e, t, o) {
630
630
  }
631
631
  });
632
632
  }
633
- function Po(e, t, o, r) {
634
- const n = To(e, t);
633
+ function Oo(e, t, o, r) {
634
+ const n = Ao(e, t);
635
635
  n && Object.defineProperty(n, t, {
636
636
  configurable: !0,
637
637
  get() {
638
- const i = { configurable: !0, writable: !0, enumerable: r, value: void 0 };
639
- return Object.defineProperty(this, t, i), i.value = o(this), Object.defineProperty(this, t, i), i.value;
638
+ const a = { configurable: !0, writable: !0, enumerable: r, value: void 0 };
639
+ return Object.defineProperty(this, t, a), a.value = o(this), Object.defineProperty(this, t, a), a.value;
640
640
  },
641
- set(i) {
642
- Object.defineProperty(this, t, { configurable: !0, writable: !0, enumerable: r, value: i });
641
+ set(a) {
642
+ Object.defineProperty(this, t, { configurable: !0, writable: !0, enumerable: r, value: a });
643
643
  }
644
644
  });
645
645
  }
646
- var dt;
647
- const We = { value: void 0, enumerable: !1 };
648
- let pt = "captureStackTrace" in Error ? Error : null;
649
- function Ao(e) {
650
- const t = pt;
646
+ var gt;
647
+ const Xe = { value: void 0, enumerable: !1 };
648
+ let mt = "captureStackTrace" in Error ? Error : null;
649
+ function Uo(e) {
650
+ const t = mt;
651
651
  if (t) {
652
652
  const o = t.stackTraceLimit;
653
653
  if (typeof o == "number") {
654
654
  try {
655
655
  t.stackTraceLimit = 0;
656
656
  } catch {
657
- return pt = null, new e();
657
+ return mt = null, new e();
658
658
  }
659
659
  try {
660
660
  return new e();
@@ -665,48 +665,48 @@ function Ao(e) {
665
665
  }
666
666
  return new e();
667
667
  }
668
- function F(e, t, o, r) {
668
+ function X(e, t, o, r) {
669
669
  const n = {};
670
- function i(p) {
670
+ function a(p) {
671
671
  this.def = p, this.constr = d, this.traits = /* @__PURE__ */ new Set();
672
672
  }
673
- i.prototype = n;
673
+ a.prototype = n;
674
674
  const c = o, s = c && /* @__PURE__ */ new WeakSet();
675
675
  function u(p, h) {
676
676
  if (p._zod) {
677
677
  if (p._zod.traits.has(e))
678
678
  return;
679
679
  } else {
680
- We.value = new i(h);
680
+ Xe.value = new a(h);
681
681
  try {
682
- Object.defineProperty(p, "_zod", We);
682
+ Object.defineProperty(p, "_zod", Xe);
683
683
  } finally {
684
- We.value = void 0;
684
+ Xe.value = void 0;
685
685
  }
686
686
  }
687
687
  if (p._zod.traits.add(e), t(p, h), s) {
688
- const g = Object.getPrototypeOf(p), k = p._zod.constr.prototype;
689
- let q = g;
690
- for (; q && q !== k; )
691
- q = Object.getPrototypeOf(q);
692
- const I = q ?? g;
693
- s.has(I) || (s.add(I), Eo(I, c));
688
+ const g = Object.getPrototypeOf(p), R = p._zod.constr.prototype;
689
+ let v = g;
690
+ for (; v && v !== R; )
691
+ v = Object.getPrototypeOf(v);
692
+ const z = v ?? g;
693
+ s.has(z) || (s.add(z), zo(z, c));
694
694
  }
695
695
  const f = d.prototype;
696
696
  for (const g in f)
697
697
  Object.prototype.hasOwnProperty.call(f, g) && (g in p || (p[g] = f[g].bind(p)));
698
698
  }
699
- const a = r?.Parent ?? Object;
700
- class l extends a {
699
+ const i = r?.Parent ?? Object;
700
+ class l extends i {
701
701
  }
702
702
  Object.defineProperty(l, "name", { value: e });
703
703
  function d(p) {
704
- const h = r?.Parent ? Ao(l) : this;
704
+ const h = r?.Parent ? Uo(l) : this;
705
705
  u(h, p);
706
706
  const f = h._zod.deferred;
707
707
  if (f) {
708
- for (const k of f)
709
- k();
708
+ for (const R of f)
709
+ R();
710
710
  h._zod.deferred = void 0;
711
711
  }
712
712
  const g = globalThis.__zod_globalConfig?.postProcessor;
@@ -716,32 +716,32 @@ function F(e, t, o, r) {
716
716
  value: (p) => r?.Parent && p instanceof r.Parent ? !0 : p?._zod?.traits?.has(e)
717
717
  }), Object.defineProperty(d, "name", { value: e }), d;
718
718
  }
719
- class Ee extends Error {
719
+ class Pe extends Error {
720
720
  constructor() {
721
721
  super("Encountered Promise during synchronous parse. Use .parseAsync() instead.");
722
722
  }
723
723
  }
724
- (dt = globalThis).__zod_globalConfig ?? (dt.__zod_globalConfig = {});
725
- const Ue = globalThis.__zod_globalConfig;
726
- function ve(e) {
727
- return e && Object.assign(Ue, e), Ue;
724
+ (gt = globalThis).__zod_globalConfig ?? (gt.__zod_globalConfig = {});
725
+ const Le = globalThis.__zod_globalConfig;
726
+ function ye(e) {
727
+ return e && Object.assign(Le, e), Le;
728
728
  }
729
- function Oo() {
729
+ function jo() {
730
730
  const e = this._zod;
731
- return e.message ?? (e.message = JSON.stringify(e.def, qo, 2)), e.message;
731
+ return e.message ?? (e.message = JSON.stringify(e.def, xo, 2)), e.message;
732
732
  }
733
- function Uo(e) {
733
+ function Do(e) {
734
734
  this._zod.message = e;
735
735
  }
736
- const jo = {
737
- get: Oo,
738
- set: Uo,
736
+ const $o = {
737
+ get: jo,
738
+ set: Do,
739
739
  enumerable: !0,
740
740
  configurable: !0
741
- }, Fe = { value: void 0, enumerable: !1 }, ht = /* @__PURE__ */ new WeakSet([Object.prototype, Error.prototype]), Do = (e, t) => {
742
- e.name = "$ZodError", Fe.value = t, Object.defineProperty(e, "issues", Fe), Fe.value = void 0, Object.defineProperty(e, "message", jo);
741
+ }, Qe = { value: void 0, enumerable: !1 }, bt = /* @__PURE__ */ new WeakSet([Object.prototype, Error.prototype]), Bo = (e, t) => {
742
+ e.name = "$ZodError", Qe.value = t, Object.defineProperty(e, "issues", Qe), Qe.value = void 0, Object.defineProperty(e, "message", $o);
743
743
  const o = Object.getPrototypeOf(e);
744
- ht.has(o) || (ht.add(o), Object.defineProperty(o, "toString", {
744
+ bt.has(o) || (bt.add(o), Object.defineProperty(o, "toString", {
745
745
  configurable: !0,
746
746
  enumerable: !1,
747
747
  get() {
@@ -752,103 +752,103 @@ const jo = {
752
752
  Object.defineProperty(this, "toString", { value: r, configurable: !0, writable: !0 });
753
753
  }
754
754
  }));
755
- }, $e = F("$ZodError", Do, void 0, {
755
+ }, Ke = X("$ZodError", Bo, void 0, {
756
756
  Parent: Error
757
- }), $o = (e) => {
758
- const t = (o, r, n, i) => {
757
+ }), Lo = (e) => {
758
+ const t = (o, r, n, a) => {
759
759
  const c = n ? { ...n, async: !1 } : { async: !1 }, s = o._zod.run({ value: r, issues: [] }, c);
760
760
  if (s instanceof Promise)
761
- throw new Ee();
761
+ throw new Pe();
762
762
  if (s.issues.length) {
763
- const u = new (i?.Err ?? e)(s.issues.map((a) => xe(a, c, ve())));
764
- throw xt(u, i?.callee ?? t), u;
763
+ const u = new (a?.Err ?? e)(s.issues.map((i) => Se(i, c, ye())));
764
+ throw Rt(u, a?.callee ?? t), u;
765
765
  }
766
766
  return s.value;
767
767
  };
768
768
  return t;
769
- }, Bo = /* @__PURE__ */ $o($e), Lo = (e) => {
770
- const t = async (o, r, n, i) => {
769
+ }, No = /* @__PURE__ */ Lo(Ke), Zo = (e) => {
770
+ const t = async (o, r, n, a) => {
771
771
  const c = n ? { ...n, async: !0 } : { async: !0 };
772
772
  let s = o._zod.run({ value: r, issues: [] }, c);
773
773
  if (s instanceof Promise && (s = await s), s.issues.length) {
774
- const u = new (i?.Err ?? e)(s.issues.map((a) => xe(a, c, ve())));
775
- throw xt(u, i?.callee ?? t), u;
774
+ const u = new (a?.Err ?? e)(s.issues.map((i) => Se(i, c, ye())));
775
+ throw Rt(u, a?.callee ?? t), u;
776
776
  }
777
777
  return s.value;
778
778
  };
779
779
  return t;
780
- }, No = /* @__PURE__ */ Lo($e), Zo = (e) => (t, o, r) => {
781
- const n = r ? { ...r, async: !1 } : { async: !1 }, i = t._zod.run({ value: o, issues: [] }, n);
782
- if (i instanceof Promise)
783
- throw new Ee();
784
- return i.issues.length ? kt(e, i.issues, n) : { success: !0, data: i.value };
785
- }, Ko = /* @__PURE__ */ Zo($e);
786
- function kt(e, t, o) {
780
+ }, Ko = /* @__PURE__ */ Zo(Ke), Vo = (e) => (t, o, r) => {
781
+ const n = r ? { ...r, async: !1 } : { async: !1 }, a = t._zod.run({ value: o, issues: [] }, n);
782
+ if (a instanceof Promise)
783
+ throw new Pe();
784
+ return a.issues.length ? Et(e, a.issues, n) : { success: !0, data: a.value };
785
+ }, Wo = /* @__PURE__ */ Vo(Ke);
786
+ function Et(e, t, o) {
787
787
  let r;
788
788
  return {
789
789
  success: !1,
790
790
  get error() {
791
- return r || (r = new e(t.map((n) => xe(n, o, ve()))), t = void 0, o = void 0), r;
791
+ return r || (r = new e(t.map((n) => Se(n, o, ye()))), t = void 0, o = void 0), r;
792
792
  },
793
793
  set error(n) {
794
794
  r = n, t = void 0, o = void 0;
795
795
  }
796
796
  };
797
797
  }
798
- const Vo = (e) => async (t, o, r) => {
798
+ const Ho = (e) => async (t, o, r) => {
799
799
  const n = r ? { ...r, async: !0 } : { async: !0 };
800
- let i = t._zod.run({ value: o, issues: [] }, n);
801
- return i instanceof Promise && (i = await i), i.issues.length ? kt(e, i.issues, n) : { success: !0, data: i.value };
802
- }, Ho = /* @__PURE__ */ Vo($e), Wo = /^[\s\S]{0,}$/, Fo = /^-?\d+(?:\.\d+)?$/, Jo = /^null$/i, Go = {
800
+ let a = t._zod.run({ value: o, issues: [] }, n);
801
+ return a instanceof Promise && (a = await a), a.issues.length ? Et(e, a.issues, n) : { success: !0, data: a.value };
802
+ }, Fo = /* @__PURE__ */ Ho(Ke), Jo = /^[\s\S]{0,}$/, Go = /^-?\d+(?:\.\d+)?$/, Yo = /^null$/i, Xo = {
803
803
  major: 4,
804
804
  minor: 6,
805
805
  patch: 7
806
- }, we = /* @__PURE__ */ F("$ZodType", (e, t) => {
806
+ }, xe = /* @__PURE__ */ X("$ZodType", (e, t) => {
807
807
  var o;
808
- e ?? (e = {}), e._zod.def = t, e._zod.bag = e._zod.bag || {}, e._zod.version = Go;
808
+ e ?? (e = {}), e._zod.def = t, e._zod.bag = e._zod.bag || {}, e._zod.version = Xo;
809
809
  const r = e._zod.def.checks, n = e._zod.traits.has("$ZodCheck") ? [e, ...r ?? []] : r?.length ? [...r] : [];
810
- for (const i of n)
811
- for (const c of i._zod.onattach)
810
+ for (const a of n)
811
+ for (const c of a._zod.onattach)
812
812
  c(e);
813
813
  if (n.length === 0)
814
814
  (o = e._zod).deferred ?? (o.deferred = []), e._zod.deferred?.push(() => {
815
815
  e._zod.run = e._zod.parse;
816
816
  });
817
817
  else {
818
- const i = (s, u, a) => {
818
+ const a = (s, u, i) => {
819
819
  if (s.memo)
820
820
  return s;
821
- let l = qe(s), d;
821
+ let l = _e(s), d;
822
822
  for (const p of u) {
823
823
  if (p._zod.def.when) {
824
- if (Io(s) || !p._zod.def.when(s))
824
+ if (Eo(s) || !p._zod.def.when(s))
825
825
  continue;
826
826
  } else if (l)
827
827
  continue;
828
828
  const h = s.issues.length, f = p._zod.check(s);
829
- if (f instanceof Promise && a?.async === !1)
830
- throw new Ee();
829
+ if (f instanceof Promise && i?.async === !1)
830
+ throw new Pe();
831
831
  if (d || f instanceof Promise)
832
832
  d = (d ?? Promise.resolve()).then(async () => {
833
- await f, s.issues.length !== h && (ut(s.issues, h, e), l || (l = qe(s, h)));
833
+ await f, s.issues.length !== h && (ft(s.issues, h, e), l || (l = _e(s, h)));
834
834
  });
835
835
  else {
836
836
  if (s.issues.length === h)
837
837
  continue;
838
- ut(s.issues, h, e), l || (l = qe(s, h));
838
+ ft(s.issues, h, e), l || (l = _e(s, h));
839
839
  }
840
840
  }
841
841
  return d ? d.then(() => s) : s;
842
- }, c = (s, u, a) => {
843
- if (qe(s))
842
+ }, c = (s, u, i) => {
843
+ if (_e(s))
844
844
  return s.aborted = !0, s;
845
- const l = i(u, n, a);
845
+ const l = a(u, n, i);
846
846
  if (l instanceof Promise) {
847
- if (a.async === !1)
848
- throw new Ee();
849
- return l.then((d) => e._zod.parse(d, a));
847
+ if (i.async === !1)
848
+ throw new Pe();
849
+ return l.then((d) => e._zod.parse(d, i));
850
850
  }
851
- return e._zod.parse(l, a);
851
+ return e._zod.parse(l, i);
852
852
  };
853
853
  e._zod.run = (s, u) => {
854
854
  if (u.skipChecks)
@@ -857,46 +857,46 @@ const Vo = (e) => async (t, o, r) => {
857
857
  const l = e._zod.parse({ value: s.value, issues: [] }, { ...u, skipChecks: !0 });
858
858
  return l instanceof Promise ? l.then((d) => c(d, s, u)) : c(l, s, u);
859
859
  }
860
- const a = e._zod.parse(s, u);
861
- if (a instanceof Promise) {
860
+ const i = e._zod.parse(s, u);
861
+ if (i instanceof Promise) {
862
862
  if (u.async === !1)
863
- throw new Ee();
864
- return a.then((l) => i(l, n, u));
863
+ throw new Pe();
864
+ return i.then((l) => a(l, n, u));
865
865
  }
866
- return i(a, n, u);
866
+ return a(i, n, u);
867
867
  };
868
868
  }
869
869
  }, {
870
870
  // Wrappers extend this by installing a richer factory over it; reading it eagerly would defeat the laziness.
871
871
  get "~standard"() {
872
- return zo(this, "~standard", Xo(this));
872
+ return To(this, "~standard", er(this));
873
873
  },
874
874
  set "~standard"(e) {
875
- Re(this, "~standard", e);
875
+ Ue(this, "~standard", e);
876
876
  }
877
- }), _t = (e, t) => e.issues.length ? { issues: e.issues.map((o) => xe(o, t, ve())) } : { value: e.value };
878
- async function Yo(e, t) {
877
+ }), zt = (e, t) => e.issues.length ? { issues: e.issues.map((o) => Se(o, t, ye())) } : { value: e.value };
878
+ async function Qo(e, t) {
879
879
  const o = { async: !0 };
880
- return _t(await e._zod.run({ value: t, issues: [] }, o), o);
880
+ return zt(await e._zod.run({ value: t, issues: [] }, o), o);
881
881
  }
882
- function Xo(e) {
882
+ function er(e) {
883
883
  return {
884
884
  validate: (t) => {
885
885
  const o = { async: !1 };
886
886
  try {
887
887
  const r = e._zod.run({ value: t, issues: [] }, o);
888
888
  if (!(r instanceof Promise))
889
- return _t(r, o);
889
+ return zt(r, o);
890
890
  } catch {
891
891
  }
892
- return Yo(e, t);
892
+ return Qo(e, t);
893
893
  },
894
894
  vendor: "zod",
895
895
  version: 1
896
896
  };
897
897
  }
898
- const Qo = /* @__PURE__ */ F("$ZodString", (e, t) => {
899
- we.init(e, t), e._zod.pattern = t.pattern ?? Wo, e._zod.parse = (o, r) => {
898
+ const tr = /* @__PURE__ */ X("$ZodString", (e, t) => {
899
+ xe.init(e, t), e._zod.pattern = t.pattern ?? Jo, e._zod.parse = (o, r) => {
900
900
  if (t.coerce)
901
901
  try {
902
902
  o.value = String(o.value);
@@ -909,8 +909,8 @@ const Qo = /* @__PURE__ */ F("$ZodString", (e, t) => {
909
909
  inst: e
910
910
  }), o;
911
911
  };
912
- }), er = /* @__PURE__ */ F("$ZodNull", (e, t) => {
913
- we.init(e, t), e._zod.pattern = Jo, e._zod.values = /* @__PURE__ */ new Set([null]), e._zod.parse = (o, r) => {
912
+ }), or = /* @__PURE__ */ X("$ZodNull", (e, t) => {
913
+ xe.init(e, t), e._zod.pattern = Yo, e._zod.values = /* @__PURE__ */ new Set([null]), e._zod.parse = (o, r) => {
914
914
  const n = o.value;
915
915
  return n === null || o.issues.push({
916
916
  expected: "null",
@@ -920,13 +920,13 @@ const Qo = /* @__PURE__ */ F("$ZodString", (e, t) => {
920
920
  }), o;
921
921
  };
922
922
  });
923
- function je(e, t, o, r, n, i) {
924
- const c = o in r, s = i === "optional";
923
+ function Ne(e, t, o, r, n, a) {
924
+ const c = o in r, s = a === "optional";
925
925
  if (!(!c && s && n === "optional")) {
926
926
  if (e.issues.length) {
927
927
  if (n !== void 0 && s && !c)
928
928
  return;
929
- t.issues.push(...Ie(o, e.issues));
929
+ t.issues.push(...Ae(o, e.issues));
930
930
  }
931
931
  if (!c && n === void 0) {
932
932
  e.issues.length || t.issues.push({
@@ -940,13 +940,13 @@ function je(e, t, o, r, n, i) {
940
940
  e.value === void 0 ? (c || n === "defaulted" && !s) && (t.value[o] = void 0) : t.value[o] = e.value;
941
941
  }
942
942
  }
943
- const tr = [];
944
- function or(e) {
945
- const t = Object.keys(e.shape), o = Object.getOwnPropertySymbols(e.shape), r = o.length ? o : tr, n = r.length ? [...t, ...r] : t;
943
+ const rr = [];
944
+ function nr(e) {
945
+ const t = Object.keys(e.shape), o = Object.getOwnPropertySymbols(e.shape), r = o.length ? o : rr, n = r.length ? [...t, ...r] : t;
946
946
  for (const c of n)
947
947
  if (!e.shape?.[c]?._zod?.traits?.has("$ZodType"))
948
948
  throw new Error(`Invalid element at key "${String(c)}": expected a Zod schema`);
949
- const i = So(e.shape);
949
+ const a = Ro(e.shape);
950
950
  return {
951
951
  ...e,
952
952
  allKeys: n,
@@ -954,15 +954,15 @@ function or(e) {
954
954
  // string-only: handleCatchall matches it against `for...in`, which never yields a symbol
955
955
  keySet: new Set(t),
956
956
  numKeys: t.length,
957
- optionalKeys: new Set(i)
957
+ optionalKeys: new Set(a)
958
958
  };
959
959
  }
960
- function rr(e, t, o, r, n, i, c) {
961
- const s = [], u = n.keySet, a = n.catchall._zod, l = a.def.type, d = a.optin, p = a.optout;
960
+ function ar(e, t, o, r, n, a, c) {
961
+ const s = [], u = n.keySet, i = n.catchall._zod, l = i.def.type, d = i.optin, p = i.optout;
962
962
  let h = 0;
963
963
  for (const f in t) {
964
964
  if (c && o.issues.length !== h) {
965
- if (qe(o, h))
965
+ if (_e(o, h))
966
966
  break;
967
967
  h = o.issues.length;
968
968
  }
@@ -976,35 +976,35 @@ function rr(e, t, o, r, n, i, c) {
976
976
  s.push(f);
977
977
  continue;
978
978
  }
979
- const g = a.run({ value: t[f], issues: [] }, r);
980
- g instanceof Promise ? e.push(g.then((k) => je(k, o, f, t, d, p))) : je(g, o, f, t, d, p);
979
+ const g = i.run({ value: t[f], issues: [] }, r);
980
+ g instanceof Promise ? e.push(g.then((R) => Ne(R, o, f, t, d, p))) : Ne(g, o, f, t, d, p);
981
981
  }
982
982
  return s.length && o.issues.push({
983
983
  code: "unrecognized_keys",
984
984
  keys: s,
985
985
  input: t,
986
- inst: i,
986
+ inst: a,
987
987
  // Describes the shape of the input, not the validity of the parsed value, so it never aborts. The parse still fails; the schema's own checks just get to run first, and an enclosing intersection can reconcile the key against a sibling operand.
988
988
  continue: !0
989
989
  }), e.length ? Promise.all(e).then(() => o) : o;
990
990
  }
991
- const nr = /* @__PURE__ */ F("$ZodObject", (e, t) => {
992
- we.init(e, t);
991
+ const ir = /* @__PURE__ */ X("$ZodObject", (e, t) => {
992
+ xe.init(e, t);
993
993
  const o = Object.getOwnPropertyDescriptor(t, "shape"), r = o?.get ? o.get.raw : t.shape ?? {};
994
994
  if (r) {
995
- const a = () => {
995
+ const i = () => {
996
996
  const l = { ...r };
997
- return Object.defineProperty(t, "shape", { value: l }), a.raw = l, l;
997
+ return Object.defineProperty(t, "shape", { value: l }), i.raw = l, l;
998
998
  };
999
- a.raw = r, Object.defineProperty(t, "shape", { get: a });
999
+ i.raw = r, Object.defineProperty(t, "shape", { get: i });
1000
1000
  }
1001
- const n = xo(() => or(t));
1002
- ue(e, "propValues", (a) => {
1003
- const l = a.def.shape, d = {};
1001
+ const n = _o(() => nr(t));
1002
+ me(e, "propValues", (i) => {
1003
+ const l = i.def.shape, d = {};
1004
1004
  for (const p in l) {
1005
1005
  const h = l[p]._zod;
1006
1006
  if (h.values) {
1007
- Object.prototype.hasOwnProperty.call(d, p) || ko(d, p, /* @__PURE__ */ new Set());
1007
+ Object.prototype.hasOwnProperty.call(d, p) || Co(d, p, /* @__PURE__ */ new Set());
1008
1008
  for (const f of h.values)
1009
1009
  d[p].add(f);
1010
1010
  h.optin !== void 0 && d[p].add(void 0);
@@ -1012,63 +1012,63 @@ const nr = /* @__PURE__ */ F("$ZodObject", (e, t) => {
1012
1012
  }
1013
1013
  return d;
1014
1014
  });
1015
- const i = Ye, c = t.catchall;
1015
+ const a = ot, c = t.catchall;
1016
1016
  let s;
1017
- const u = Ue.memoizer;
1018
- u?.attach(e), e._zod.parse = (a, l) => {
1017
+ const u = Le.memoizer;
1018
+ u?.attach(e), e._zod.parse = (i, l) => {
1019
1019
  s ?? (s = n.value);
1020
- const d = a.value;
1021
- if (!i(d))
1022
- return a.issues.push({
1020
+ const d = i.value;
1021
+ if (!a(d))
1022
+ return i.issues.push({
1023
1023
  expected: "object",
1024
1024
  code: "invalid_type",
1025
1025
  input: d,
1026
1026
  inst: e
1027
- }), a;
1028
- a.value = u ? u.alloc(e, a, {}, l) : {};
1027
+ }), i;
1028
+ i.value = u ? u.alloc(e, i, {}, l) : {};
1029
1029
  const p = [], h = s.shape, f = l?.abortEarly;
1030
- let g = a.issues.length;
1031
- for (const k of s.allKeys) {
1032
- if (f && a.issues.length !== g) {
1033
- if (qe(a, g))
1030
+ let g = i.issues.length;
1031
+ for (const R of s.allKeys) {
1032
+ if (f && i.issues.length !== g) {
1033
+ if (_e(i, g))
1034
1034
  break;
1035
- g = a.issues.length;
1035
+ g = i.issues.length;
1036
1036
  }
1037
- if (k === "__proto__")
1037
+ if (R === "__proto__")
1038
1038
  continue;
1039
- const q = h[k], I = q._zod.optin, j = q._zod.optout, S = q._zod.run({ value: d[k], issues: [] }, l);
1040
- S instanceof Promise ? p.push(S.then(($) => je($, a, k, d, I, j))) : je(S, a, k, d, I, j);
1039
+ const v = h[R], z = v._zod.optin, A = v._zod.optout, E = v._zod.run({ value: d[R], issues: [] }, l);
1040
+ E instanceof Promise ? p.push(E.then((j) => Ne(j, i, R, d, z, A))) : Ne(E, i, R, d, z, A);
1041
1041
  }
1042
- return c ? rr(p, d, a, l, n.value, e, f === !0) : p.length ? Promise.all(p).then(() => a) : a;
1042
+ return c ? ar(p, d, i, l, n.value, e, f === !0) : p.length ? Promise.all(p).then(() => i) : i;
1043
1043
  };
1044
1044
  });
1045
- function ft(e, t, o, r) {
1046
- for (const i of e)
1047
- if (i.issues.length === 0)
1048
- return t.value = i.value, t;
1049
- const n = e.filter((i) => !qe(i));
1045
+ function wt(e, t, o, r) {
1046
+ for (const a of e)
1047
+ if (a.issues.length === 0)
1048
+ return t.value = a.value, t;
1049
+ const n = e.filter((a) => !_e(a));
1050
1050
  return n.length === 1 ? (t.value = n[0].value, n[0]) : (t.issues.push({
1051
1051
  code: "invalid_union",
1052
1052
  input: t.value,
1053
1053
  inst: o,
1054
- errors: e.map((i) => i.issues.map((c) => xe(c, r, ve())))
1054
+ errors: e.map((a) => a.issues.map((c) => Se(c, r, ye())))
1055
1055
  }), t);
1056
1056
  }
1057
- const ar = /* @__PURE__ */ F("$ZodUnion", (e, t) => {
1058
- we.init(e, t), ue(e, "optin", (r) => r.def.options.some((n) => n._zod.optin === "defaulted") ? "defaulted" : r.def.options.some((n) => n._zod.optin !== void 0) ? "optional" : void 0), ue(e, "optout", (r) => r.def.options.some((n) => n._zod.optout === "optional") ? "optional" : void 0), ue(e, "values", (r) => {
1057
+ const sr = /* @__PURE__ */ X("$ZodUnion", (e, t) => {
1058
+ xe.init(e, t), me(e, "optin", (r) => r.def.options.some((n) => n._zod.optin === "defaulted") ? "defaulted" : r.def.options.some((n) => n._zod.optin !== void 0) ? "optional" : void 0), me(e, "optout", (r) => r.def.options.some((n) => n._zod.optout === "optional") ? "optional" : void 0), me(e, "values", (r) => {
1059
1059
  if (r.def.options.every((n) => n._zod.values))
1060
1060
  return new Set(r.def.options.flatMap((n) => Array.from(n._zod.values)));
1061
- }), ue(e, "pattern", (r) => {
1061
+ }), me(e, "pattern", (r) => {
1062
1062
  if (r.def.options.every((n) => n._zod.pattern)) {
1063
- const n = r.def.options.map((i) => i._zod.pattern);
1064
- return new RegExp(`^(${n.map((i) => yt(i.source)).join("|")})$`);
1063
+ const n = r.def.options.map((a) => a._zod.pattern);
1064
+ return new RegExp(`^(${n.map((a) => It(a.source)).join("|")})$`);
1065
1065
  }
1066
1066
  });
1067
1067
  const o = t.options.length === 1 ? t.options[0]._zod.run : null;
1068
1068
  e._zod.parse = (r, n) => {
1069
1069
  if (o)
1070
1070
  return o(r, n);
1071
- let i = !1;
1071
+ let a = !1;
1072
1072
  const c = [];
1073
1073
  for (const s of t.options) {
1074
1074
  const u = s._zod.run({
@@ -1076,25 +1076,25 @@ const ar = /* @__PURE__ */ F("$ZodUnion", (e, t) => {
1076
1076
  issues: []
1077
1077
  }, n);
1078
1078
  if (u instanceof Promise)
1079
- c.push(u), i = !0;
1079
+ c.push(u), a = !0;
1080
1080
  else {
1081
1081
  if (u.issues.length === 0)
1082
1082
  return u;
1083
1083
  c.push(u);
1084
1084
  }
1085
1085
  }
1086
- return i ? Promise.all(c).then((s) => ft(s, r, e, n)) : ft(c, r, e, n);
1086
+ return a ? Promise.all(c).then((s) => wt(s, r, e, n)) : wt(c, r, e, n);
1087
1087
  };
1088
- }), ir = /* @__PURE__ */ F("$ZodRecord", (e, t) => {
1089
- we.init(e, t);
1090
- const o = Ue.memoizer;
1088
+ }), lr = /* @__PURE__ */ X("$ZodRecord", (e, t) => {
1089
+ xe.init(e, t);
1090
+ const o = Le.memoizer;
1091
1091
  o?.attach(e), e._zod.parse = (r, n) => {
1092
- const i = r.value;
1093
- if (!_o(i))
1092
+ const a = r.value;
1093
+ if (!So(a))
1094
1094
  return r.issues.push({
1095
1095
  expected: "record",
1096
1096
  code: "invalid_type",
1097
- input: i,
1097
+ input: a,
1098
1098
  inst: e
1099
1099
  }), r;
1100
1100
  const c = [], s = t.keyType._zod.values;
@@ -1112,7 +1112,7 @@ const ar = /* @__PURE__ */ F("$ZodUnion", (e, t) => {
1112
1112
  r.issues.push({
1113
1113
  code: "invalid_key",
1114
1114
  origin: "record",
1115
- issues: d.issues.map((f) => xe(f, n, ve())),
1115
+ issues: d.issues.map((f) => Se(f, n, ye())),
1116
1116
  input: l,
1117
1117
  path: [l],
1118
1118
  inst: e
@@ -1122,49 +1122,49 @@ const ar = /* @__PURE__ */ F("$ZodUnion", (e, t) => {
1122
1122
  const p = d.value;
1123
1123
  if (p === "__proto__")
1124
1124
  continue;
1125
- const h = t.valueType._zod.run({ value: i[l], issues: [] }, n);
1125
+ const h = t.valueType._zod.run({ value: a[l], issues: [] }, n);
1126
1126
  h instanceof Promise ? c.push(h.then((f) => {
1127
- f.issues.length && r.issues.push(...Ie(l, f.issues)), r.value[p] = f.value;
1128
- })) : (h.issues.length && r.issues.push(...Ie(l, h.issues)), r.value[p] = h.value);
1127
+ f.issues.length && r.issues.push(...Ae(l, f.issues)), r.value[p] = f.value;
1128
+ })) : (h.issues.length && r.issues.push(...Ae(l, h.issues)), r.value[p] = h.value);
1129
1129
  }
1130
- let a;
1131
- for (const l in i)
1130
+ let i;
1131
+ for (const l in a)
1132
1132
  if (!u.has(l))
1133
1133
  if (t.mode === "loose") {
1134
1134
  if (l === "__proto__")
1135
1135
  continue;
1136
- r.value[l] = i[l];
1136
+ r.value[l] = a[l];
1137
1137
  } else
1138
- a = a ?? [], a.push(l);
1139
- a && a.length > 0 && r.issues.push({
1138
+ i = i ?? [], i.push(l);
1139
+ i && i.length > 0 && r.issues.push({
1140
1140
  code: "unrecognized_keys",
1141
- input: i,
1141
+ input: a,
1142
1142
  inst: e,
1143
- keys: a,
1143
+ keys: i,
1144
1144
  continue: !0
1145
1145
  });
1146
1146
  } else {
1147
1147
  r.value = o ? o.alloc(e, r, {}, n) : {};
1148
1148
  let u;
1149
- for (const a of Reflect.ownKeys(i)) {
1150
- if (a === "__proto__" || !Object.prototype.propertyIsEnumerable.call(i, a))
1149
+ for (const i of Reflect.ownKeys(a)) {
1150
+ if (i === "__proto__" || !Object.prototype.propertyIsEnumerable.call(a, i))
1151
1151
  continue;
1152
- let l = t.keyType._zod.run({ value: a, issues: [] }, n);
1152
+ let l = t.keyType._zod.run({ value: i, issues: [] }, n);
1153
1153
  if (l instanceof Promise)
1154
1154
  throw new Error("Async schemas not supported in object keys currently");
1155
- if (typeof a == "string" && Fo.test(a) && l.issues.length) {
1156
- const f = t.keyType._zod.run({ value: Number(a), issues: [] }, n);
1155
+ if (typeof i == "string" && Go.test(i) && l.issues.length) {
1156
+ const f = t.keyType._zod.run({ value: Number(i), issues: [] }, n);
1157
1157
  if (f instanceof Promise)
1158
1158
  throw new Error("Async schemas not supported in object keys currently");
1159
1159
  f.issues.length === 0 && (l = f);
1160
1160
  }
1161
1161
  if (l.issues.length) {
1162
- t.mode === "loose" ? r.value[a] = i[a] : s ? (u = u ?? [], u.push(a)) : r.issues.push({
1162
+ t.mode === "loose" ? r.value[i] = a[i] : s ? (u = u ?? [], u.push(i)) : r.issues.push({
1163
1163
  code: "invalid_key",
1164
1164
  origin: "record",
1165
- issues: l.issues.map((f) => xe(f, n, ve())),
1166
- input: a,
1167
- path: [a],
1165
+ issues: l.issues.map((f) => Se(f, n, ye())),
1166
+ input: i,
1167
+ path: [i],
1168
1168
  inst: e
1169
1169
  });
1170
1170
  continue;
@@ -1172,14 +1172,14 @@ const ar = /* @__PURE__ */ F("$ZodUnion", (e, t) => {
1172
1172
  const p = l.value;
1173
1173
  if (p === "__proto__")
1174
1174
  continue;
1175
- const h = t.valueType._zod.run({ value: i[a], issues: [] }, n);
1175
+ const h = t.valueType._zod.run({ value: a[i], issues: [] }, n);
1176
1176
  h instanceof Promise ? c.push(h.then((f) => {
1177
- f.issues.length && r.issues.push(...Ie(a, f.issues)), r.value[p] = f.value;
1178
- })) : (h.issues.length && r.issues.push(...Ie(a, h.issues)), r.value[p] = h.value);
1177
+ f.issues.length && r.issues.push(...Ae(i, f.issues)), r.value[p] = f.value;
1178
+ })) : (h.issues.length && r.issues.push(...Ae(i, h.issues)), r.value[p] = h.value);
1179
1179
  }
1180
1180
  u && u.length > 0 && r.issues.push({
1181
1181
  code: "unrecognized_keys",
1182
- input: i,
1182
+ input: a,
1183
1183
  inst: e,
1184
1184
  keys: u,
1185
1185
  continue: !0
@@ -1187,64 +1187,64 @@ const ar = /* @__PURE__ */ F("$ZodUnion", (e, t) => {
1187
1187
  }
1188
1188
  return c.length ? Promise.all(c).then(() => r) : r;
1189
1189
  };
1190
- }), sr = /* @__PURE__ */ F("$ZodLiteral", (e, t) => {
1191
- we.init(e, t);
1190
+ }), cr = /* @__PURE__ */ X("$ZodLiteral", (e, t) => {
1191
+ xe.init(e, t);
1192
1192
  const o = new Set(t.values);
1193
- e._zod.values = o, ue(e, "pattern", (r) => {
1193
+ e._zod.values = o, me(e, "pattern", (r) => {
1194
1194
  const n = r.def.values;
1195
- return new RegExp(n.length ? `^(${n.map((i) => typeof i == "string" ? ct(i) : i ? ct(i.toString()) : String(i)).join("|")})$` : "^[^\\s\\S]$");
1195
+ return new RegExp(n.length ? `^(${n.map((a) => typeof a == "string" ? ht(a) : a ? ht(a.toString()) : String(a)).join("|")})$` : "^[^\\s\\S]$");
1196
1196
  }), e._zod.parse = (r, n) => {
1197
- const i = r.value;
1198
- return o.has(i) || r.issues.push({
1197
+ const a = r.value;
1198
+ return o.has(a) || r.issues.push({
1199
1199
  code: "invalid_value",
1200
1200
  values: t.values,
1201
- input: i,
1201
+ input: a,
1202
1202
  inst: e
1203
1203
  }), r;
1204
1204
  };
1205
- }), lr = /* @__PURE__ */ F("$ZodNullable", (e, t) => {
1206
- we.init(e, t), ue(e, "optin", (o) => o.def.innerType._zod.optin), ue(e, "optout", (o) => o.def.innerType._zod.optout), ue(e, "pattern", (o) => {
1205
+ }), ur = /* @__PURE__ */ X("$ZodNullable", (e, t) => {
1206
+ xe.init(e, t), me(e, "optin", (o) => o.def.innerType._zod.optin), me(e, "optout", (o) => o.def.innerType._zod.optout), me(e, "pattern", (o) => {
1207
1207
  const r = o.def.innerType._zod.pattern;
1208
- return r ? new RegExp(`^(${yt(r.source)}|null)$`) : void 0;
1209
- }), ue(e, "values", (o) => o.def.innerType._zod.values ? /* @__PURE__ */ new Set([...o.def.innerType._zod.values, null]) : void 0), e._zod.parse = (o, r) => o.value === null ? o : t.innerType._zod.run(o, r);
1208
+ return r ? new RegExp(`^(${It(r.source)}|null)$`) : void 0;
1209
+ }), me(e, "values", (o) => o.def.innerType._zod.values ? /* @__PURE__ */ new Set([...o.def.innerType._zod.values, null]) : void 0), e._zod.parse = (o, r) => o.value === null ? o : t.innerType._zod.run(o, r);
1210
1210
  });
1211
- function cr(e) {
1211
+ function dr(e) {
1212
1212
  return e.checks && (e.checks = [...e.checks]), e;
1213
1213
  }
1214
1214
  // @__NO_SIDE_EFFECTS__
1215
- function ur(e, t) {
1216
- return new e(cr({ type: "string", ...ye(t) }));
1215
+ function pr(e, t) {
1216
+ return new e(dr({ type: "string", ...Ce(t) }));
1217
1217
  }
1218
1218
  // @__NO_SIDE_EFFECTS__
1219
- function dr(e, t) {
1219
+ function hr(e, t) {
1220
1220
  return new e({
1221
1221
  type: "null",
1222
- ...ye(t)
1222
+ ...Ce(t)
1223
1223
  });
1224
1224
  }
1225
- const ke = /* @__PURE__ */ F("ZodMiniType", (e, t) => {
1225
+ const Ie = /* @__PURE__ */ X("ZodMiniType", (e, t) => {
1226
1226
  if (!e._zod)
1227
1227
  throw new Error("Uninitialized schema in ZodMiniType.");
1228
- we.init(e, t), e.def = t, e.type = t.type;
1228
+ xe.init(e, t), e.def = t, e.type = t.type;
1229
1229
  }, {
1230
1230
  // `with` is an alias for `check`: the same function object, not a wrapper.
1231
1231
  get with() {
1232
1232
  return this.check;
1233
1233
  },
1234
1234
  set with(e) {
1235
- Re(this, "with", e);
1235
+ Ue(this, "with", e);
1236
1236
  },
1237
1237
  parse(e, t) {
1238
- return Bo(this, e, t, { callee: this.parse });
1238
+ return No(this, e, t, { callee: this.parse });
1239
1239
  },
1240
1240
  parseAsync(e, t) {
1241
- return No(this, e, t, { callee: this.parseAsync });
1241
+ return Ko(this, e, t, { callee: this.parseAsync });
1242
1242
  },
1243
1243
  safeParse(e, t) {
1244
- return Ko(this, e, t);
1244
+ return Wo(this, e, t);
1245
1245
  },
1246
1246
  safeParseAsync(e, t) {
1247
- return Ho(this, e, t);
1247
+ return Fo(this, e, t);
1248
1248
  },
1249
1249
  check(...e) {
1250
1250
  const t = this.def;
@@ -1257,7 +1257,7 @@ const ke = /* @__PURE__ */ F("ZodMiniType", (e, t) => {
1257
1257
  }, { parent: !0 });
1258
1258
  },
1259
1259
  clone(e, t) {
1260
- return Co(this, e, t);
1260
+ return Io(this, e, t);
1261
1261
  },
1262
1262
  brand() {
1263
1263
  return this;
@@ -1268,373 +1268,406 @@ const ke = /* @__PURE__ */ F("ZodMiniType", (e, t) => {
1268
1268
  apply(e, ...t) {
1269
1269
  return t.length === 0 ? e(this) : e(this, ...t);
1270
1270
  }
1271
- }), pr = /* @__PURE__ */ F("ZodMiniString", (e, t) => {
1272
- Qo.init(e, t), ke.init(e, t);
1271
+ }), fr = /* @__PURE__ */ X("ZodMiniString", (e, t) => {
1272
+ tr.init(e, t), Ie.init(e, t);
1273
1273
  });
1274
1274
  // @__NO_SIDE_EFFECTS__
1275
- function E(e) {
1276
- return /* @__PURE__ */ ur(pr, e);
1275
+ function T(e) {
1276
+ return /* @__PURE__ */ pr(fr, e);
1277
1277
  }
1278
- const hr = /* @__PURE__ */ F("ZodMiniNull", (e, t) => {
1279
- er.init(e, t), ke.init(e, t);
1278
+ const gr = /* @__PURE__ */ X("ZodMiniNull", (e, t) => {
1279
+ or.init(e, t), Ie.init(e, t);
1280
1280
  });
1281
1281
  // @__NO_SIDE_EFFECTS__
1282
- function fr(e) {
1283
- return /* @__PURE__ */ dr(hr, e);
1282
+ function mr(e) {
1283
+ return /* @__PURE__ */ hr(gr, e);
1284
1284
  }
1285
- const gr = /* @__PURE__ */ F("ZodMiniObject", (e, t) => {
1286
- nr.init(e, t), ke.init(e, t), Po(e, "shape", (o) => o._zod.def.shape, !1);
1285
+ const br = /* @__PURE__ */ X("ZodMiniObject", (e, t) => {
1286
+ ir.init(e, t), Ie.init(e, t), Oo(e, "shape", (o) => o._zod.def.shape, !1);
1287
1287
  });
1288
1288
  // @__NO_SIDE_EFFECTS__
1289
- function U(e, t) {
1289
+ function $(e, t) {
1290
1290
  const o = {
1291
1291
  type: "object",
1292
1292
  shape: e ?? {},
1293
- ...ye(t)
1293
+ ...Ce(t)
1294
1294
  };
1295
- return new gr(o);
1295
+ return new br(o);
1296
1296
  }
1297
- const mr = /* @__PURE__ */ F("ZodMiniUnion", (e, t) => {
1298
- ar.init(e, t), ke.init(e, t);
1297
+ const wr = /* @__PURE__ */ X("ZodMiniUnion", (e, t) => {
1298
+ sr.init(e, t), Ie.init(e, t);
1299
1299
  });
1300
1300
  // @__NO_SIDE_EFFECTS__
1301
- function br(e, t) {
1302
- return new mr({
1301
+ function vr(e, t) {
1302
+ return new wr({
1303
1303
  type: "union",
1304
1304
  options: e,
1305
- ...ye(t)
1305
+ ...Ce(t)
1306
1306
  });
1307
1307
  }
1308
- const gt = /* @__PURE__ */ F("ZodMiniRecord", (e, t) => {
1309
- ir.init(e, t), ke.init(e, t);
1308
+ const vt = /* @__PURE__ */ X("ZodMiniRecord", (e, t) => {
1309
+ lr.init(e, t), Ie.init(e, t);
1310
1310
  });
1311
1311
  // @__NO_SIDE_EFFECTS__
1312
- function vr(e, t, o) {
1313
- return !t || !t._zod ? new gt({
1312
+ function qr(e, t, o) {
1313
+ return !t || !t._zod ? new vt({
1314
1314
  type: "record",
1315
- keyType: /* @__PURE__ */ E(),
1315
+ keyType: /* @__PURE__ */ T(),
1316
1316
  valueType: e,
1317
- ...ye(t)
1318
- }) : new gt({
1317
+ ...Ce(t)
1318
+ }) : new vt({
1319
1319
  type: "record",
1320
1320
  keyType: e,
1321
1321
  valueType: t,
1322
- ...ye(o)
1322
+ ...Ce(o)
1323
1323
  });
1324
1324
  }
1325
- const wr = /* @__PURE__ */ F("ZodMiniLiteral", (e, t) => {
1326
- sr.init(e, t), ke.init(e, t);
1325
+ const yr = /* @__PURE__ */ X("ZodMiniLiteral", (e, t) => {
1326
+ cr.init(e, t), Ie.init(e, t);
1327
1327
  });
1328
1328
  // @__NO_SIDE_EFFECTS__
1329
- function se(e, t) {
1330
- return new wr({
1329
+ function fe(e, t) {
1330
+ return new yr({
1331
1331
  type: "literal",
1332
1332
  values: Array.isArray(e) ? e : [e],
1333
- ...ye(t)
1333
+ ...Ce(t)
1334
1334
  });
1335
1335
  }
1336
- const qr = /* @__PURE__ */ F("ZodMiniNullable", (e, t) => {
1337
- lr.init(e, t), ke.init(e, t);
1336
+ const xr = /* @__PURE__ */ X("ZodMiniNullable", (e, t) => {
1337
+ ur.init(e, t), Ie.init(e, t);
1338
1338
  });
1339
1339
  // @__NO_SIDE_EFFECTS__
1340
- function ot(e) {
1341
- return new qr({
1340
+ function st(e) {
1341
+ return new xr({
1342
1342
  type: "nullable",
1343
1343
  innerType: e
1344
1344
  });
1345
1345
  }
1346
- ve({ jitless: !0 });
1347
- const yr = /* @__PURE__ */ U({
1348
- type: /* @__PURE__ */ se("utterance"),
1349
- content: /* @__PURE__ */ E(),
1350
- role: /* @__PURE__ */ E()
1351
- }), xr = /* @__PURE__ */ U({
1352
- type: /* @__PURE__ */ se("agent_cognition"),
1353
- content: /* @__PURE__ */ E()
1354
- }), kr = /* @__PURE__ */ U({
1355
- type: /* @__PURE__ */ se("chat_closed_expired"),
1356
- content: /* @__PURE__ */ E()
1357
- }), _r = /* @__PURE__ */ U({
1358
- type: /* @__PURE__ */ se("agent_captured_url"),
1359
- content: /* @__PURE__ */ E()
1360
- }), Cr = /* @__PURE__ */ U({
1361
- type: /* @__PURE__ */ se("agent_topic"),
1362
- content: /* @__PURE__ */ E()
1363
- }), Sr = /* @__PURE__ */ U({
1364
- type: /* @__PURE__ */ se("agent_summary"),
1365
- content: /* @__PURE__ */ E()
1366
- }), Ir = /* @__PURE__ */ U({
1367
- type: /* @__PURE__ */ se("chat_rating"),
1368
- content: /* @__PURE__ */ E()
1369
- }), Er = /* @__PURE__ */ U({
1370
- type: /* @__PURE__ */ se("breadcrumb"),
1371
- content: /* @__PURE__ */ E()
1372
- }), zr = /* @__PURE__ */ U({
1373
- type: /* @__PURE__ */ se("chat_escalated"),
1374
- content: /* @__PURE__ */ fr()
1375
- }), Rr = /* @__PURE__ */ U({
1376
- type: /* @__PURE__ */ se("error"),
1377
- code: /* @__PURE__ */ E()
1378
- }), Tr = /* @__PURE__ */ U({
1379
- message_id: /* @__PURE__ */ ot(/* @__PURE__ */ E()),
1380
- created_at: /* @__PURE__ */ E(),
1381
- data: yr
1382
- }), Mr = /* @__PURE__ */ U({
1383
- created_at: /* @__PURE__ */ E(),
1384
- data: Rr
1385
- }), Pr = /* @__PURE__ */ U({
1386
- created_at: /* @__PURE__ */ E(),
1387
- data: xr
1388
- }), Ar = /* @__PURE__ */ U({
1389
- message_id: /* @__PURE__ */ ot(/* @__PURE__ */ E()),
1390
- created_at: /* @__PURE__ */ E(),
1346
+ ye({ jitless: !0 });
1347
+ const kr = /* @__PURE__ */ $({
1348
+ type: /* @__PURE__ */ fe("utterance"),
1349
+ content: /* @__PURE__ */ T(),
1350
+ role: /* @__PURE__ */ T()
1351
+ }), _r = /* @__PURE__ */ $({
1352
+ type: /* @__PURE__ */ fe("agent_cognition"),
1353
+ content: /* @__PURE__ */ T()
1354
+ }), Cr = /* @__PURE__ */ $({
1355
+ type: /* @__PURE__ */ fe("chat_closed_expired"),
1356
+ content: /* @__PURE__ */ T()
1357
+ }), Sr = /* @__PURE__ */ $({
1358
+ type: /* @__PURE__ */ fe("agent_captured_url"),
1359
+ content: /* @__PURE__ */ T()
1360
+ }), Ir = /* @__PURE__ */ $({
1361
+ type: /* @__PURE__ */ fe("agent_topic"),
1362
+ content: /* @__PURE__ */ T()
1363
+ }), Rr = /* @__PURE__ */ $({
1364
+ type: /* @__PURE__ */ fe("agent_summary"),
1365
+ content: /* @__PURE__ */ T()
1366
+ }), Er = /* @__PURE__ */ $({
1367
+ type: /* @__PURE__ */ fe("chat_rating"),
1368
+ content: /* @__PURE__ */ T()
1369
+ }), zr = /* @__PURE__ */ $({
1370
+ type: /* @__PURE__ */ fe("breadcrumb"),
1371
+ content: /* @__PURE__ */ T()
1372
+ }), Tr = /* @__PURE__ */ $({
1373
+ type: /* @__PURE__ */ fe("chat_escalated"),
1374
+ content: /* @__PURE__ */ mr()
1375
+ }), Mr = /* @__PURE__ */ $({
1376
+ type: /* @__PURE__ */ fe("error"),
1377
+ code: /* @__PURE__ */ T()
1378
+ }), Ar = /* @__PURE__ */ $({
1379
+ message_id: /* @__PURE__ */ st(/* @__PURE__ */ T()),
1380
+ created_at: /* @__PURE__ */ T(),
1391
1381
  data: kr
1392
- }), Or = /* @__PURE__ */ U({
1393
- created_at: /* @__PURE__ */ E(),
1382
+ }), Pr = /* @__PURE__ */ $({
1383
+ created_at: /* @__PURE__ */ T(),
1384
+ data: Mr
1385
+ }), Or = /* @__PURE__ */ $({
1386
+ created_at: /* @__PURE__ */ T(),
1394
1387
  data: _r
1395
- }), Ur = /* @__PURE__ */ U({
1396
- created_at: /* @__PURE__ */ E(),
1388
+ }), Ur = /* @__PURE__ */ $({
1389
+ message_id: /* @__PURE__ */ st(/* @__PURE__ */ T()),
1390
+ created_at: /* @__PURE__ */ T(),
1397
1391
  data: Cr
1398
- }), jr = /* @__PURE__ */ U({
1399
- created_at: /* @__PURE__ */ E(),
1392
+ }), jr = /* @__PURE__ */ $({
1393
+ created_at: /* @__PURE__ */ T(),
1400
1394
  data: Sr
1401
- }), Dr = /* @__PURE__ */ U({
1402
- created_at: /* @__PURE__ */ E(),
1395
+ }), Dr = /* @__PURE__ */ $({
1396
+ created_at: /* @__PURE__ */ T(),
1403
1397
  data: Ir
1404
- }), $r = /* @__PURE__ */ U({
1405
- created_at: /* @__PURE__ */ E(),
1398
+ }), $r = /* @__PURE__ */ $({
1399
+ created_at: /* @__PURE__ */ T(),
1400
+ data: Rr
1401
+ }), Br = /* @__PURE__ */ $({
1402
+ created_at: /* @__PURE__ */ T(),
1406
1403
  data: Er
1407
- }), Br = /* @__PURE__ */ U({
1408
- message_id: /* @__PURE__ */ ot(/* @__PURE__ */ E()),
1409
- created_at: /* @__PURE__ */ E(),
1404
+ }), Lr = /* @__PURE__ */ $({
1405
+ created_at: /* @__PURE__ */ T(),
1410
1406
  data: zr
1411
- }), Lr = /* @__PURE__ */ br([
1412
- Tr,
1413
- Mr,
1407
+ }), Nr = /* @__PURE__ */ $({
1408
+ message_id: /* @__PURE__ */ st(/* @__PURE__ */ T()),
1409
+ created_at: /* @__PURE__ */ T(),
1410
+ data: Tr
1411
+ }), Zr = /* @__PURE__ */ vr([
1412
+ Ar,
1414
1413
  Pr,
1415
1414
  Or,
1416
- Ur,
1417
1415
  jr,
1418
- Ar,
1419
1416
  Dr,
1420
1417
  $r,
1421
- Br
1422
- ]), Nr = /* @__PURE__ */ U({
1423
- url: /* @__PURE__ */ E(),
1424
- mimeType: /* @__PURE__ */ se(Ot),
1425
- name: /* @__PURE__ */ E()
1426
- }), Zr = /* @__PURE__ */ U({
1427
- data: Nr
1428
- }), Kr = /* @__PURE__ */ U({
1429
- data: /* @__PURE__ */ U({ urls: /* @__PURE__ */ vr(/* @__PURE__ */ E(), /* @__PURE__ */ E()) })
1430
- }), Vr = 500, Hr = 3e4, Wr = 6e4;
1431
- function Fr({
1418
+ Ur,
1419
+ Br,
1420
+ Lr,
1421
+ Nr
1422
+ ]), Kr = /* @__PURE__ */ $({
1423
+ url: /* @__PURE__ */ T(),
1424
+ mimeType: /* @__PURE__ */ fe(jt),
1425
+ name: /* @__PURE__ */ T()
1426
+ }), Vr = /* @__PURE__ */ $({
1427
+ data: Kr
1428
+ }), Wr = /* @__PURE__ */ $({
1429
+ data: /* @__PURE__ */ $({ urls: /* @__PURE__ */ qr(/* @__PURE__ */ T(), /* @__PURE__ */ T()) })
1430
+ }), Hr = 500, Fr = 3e4, Jr = 6e4, Gr = 1e4, Yr = 12e4;
1431
+ function Xr({
1432
1432
  chatSettings: e,
1433
1433
  chatId: t,
1434
1434
  messages: o,
1435
1435
  onMessage: r,
1436
- onCognition: n,
1437
- onCognitionComplete: i,
1438
- onError: c,
1439
- onChatClosed: s,
1440
- onAgentCapturedUrl: u,
1441
- onAgentTopic: a,
1442
- onAgentSummary: l,
1443
- onRatingRequest: d,
1444
- onBreadcrumb: p,
1445
- fetchHistory: h,
1446
- getChatToken: f,
1447
- backupPollingInterval: g = Wr
1436
+ onMissedUserMessage: n,
1437
+ onCognition: a,
1438
+ onCognitionComplete: c,
1439
+ onError: s,
1440
+ onChatClosed: u,
1441
+ onAgentCapturedUrl: i,
1442
+ onAgentTopic: l,
1443
+ onAgentSummary: d,
1444
+ onRatingRequest: p,
1445
+ onBreadcrumb: h,
1446
+ fetchHistory: f,
1447
+ getChatToken: g,
1448
+ backupPollingInterval: R = Jr
1448
1449
  }) {
1449
- const k = N(/* @__PURE__ */ new Set());
1450
- Z(() => {
1451
- for (const D of o)
1452
- D.id && k.current.add(D.id);
1450
+ const v = N(/* @__PURE__ */ new Set());
1451
+ F(() => {
1452
+ for (const M of o)
1453
+ M.id && v.current.add(M.id);
1453
1454
  }, [o]);
1454
- const q = N(null), I = N(null), j = N(0), S = N(null), $ = N(null), R = N(!1), m = N(!1), y = V(r), P = V(n), oe = V(i), G = V(c), re = V(s), ne = V(u), T = V(a), L = V(l), A = V(d), K = V(p), X = V(h), H = V(f), { publishError: W } = De(), ae = e?.app_sync_url, Q = e?.app_sync_api_key, ee = !!(ae && Q), fe = V(ae), b = V(Q), v = w(() => {
1455
- q.current && (q.current.close(), q.current = null);
1456
- }, []), C = w(() => {
1457
- $.current && (clearInterval($.current), $.current = null);
1458
- }, []), O = w(() => {
1459
- S.current && (clearTimeout(S.current), S.current = null);
1460
- }, []), M = N(() => {
1461
- }), B = w(
1462
- async (D) => {
1463
- v();
1464
- const ie = fe.current, te = b.current;
1465
- if (!ie || !te)
1455
+ const z = N(null), A = N(null), E = N(0), j = N(null), P = N(null), b = N(null), q = N(null), C = N(0), te = N(!1), Q = N(!1), ne = H(r), ae = H(n), D = H(a), J = H(c), Z = H(s), V = H(u), oe = H(i), ce = H(l), G = H(d), ie = H(p), Y = H(h), ue = H(f), be = H(g), { publishError: pe } = Ze(), re = e?.app_sync_url, he = e?.app_sync_api_key, m = !!(re && he), x = H(re), O = H(he), U = w(() => {
1456
+ z.current && (z.current.close(), z.current = null);
1457
+ }, []), k = w(() => {
1458
+ P.current && (clearInterval(P.current), P.current = null);
1459
+ }, []), y = w(() => {
1460
+ C.current = 0, b.current && (clearInterval(b.current), b.current = null), q.current && (clearTimeout(q.current), q.current = null);
1461
+ }, []), B = w(() => {
1462
+ C.current = Math.max(0, C.current - 1), C.current === 0 && y();
1463
+ }, [y]), I = w(() => {
1464
+ j.current && (clearTimeout(j.current), j.current = null);
1465
+ }, []), K = N(() => {
1466
+ }), se = w(
1467
+ async (M) => {
1468
+ U();
1469
+ const le = x.current, we = O.current;
1470
+ if (!le || !we)
1466
1471
  throw new Error("Cannot connect: AppSync settings not available");
1467
- const Te = H.current(), Be = await wo({
1468
- httpEndpoint: ie,
1469
- auth: Te ? { authorizationToken: Te } : { apiKey: te },
1470
- channel: `/default/chat/${D}`,
1472
+ const W = be.current(), ze = await yo({
1473
+ httpEndpoint: le,
1474
+ auth: W ? { authorizationToken: W } : { apiKey: we },
1475
+ channel: `/default/chat/${M}`,
1471
1476
  onDisconnect: () => {
1472
- q.current = null, M.current();
1477
+ z.current = null, K.current();
1473
1478
  },
1474
- onEvent: (Le) => {
1475
- const _e = Lr.safeParse(Le);
1476
- if (!_e.success) {
1477
- console.error("Invalid conversation response:", _e.error);
1479
+ onEvent: (ke) => {
1480
+ const ve = Zr.safeParse(ke);
1481
+ if (!ve.success) {
1482
+ console.error("Invalid conversation response:", ve.error);
1478
1483
  return;
1479
1484
  }
1480
- const le = _e.data;
1481
- switch (le.data.type) {
1485
+ const ge = ve.data;
1486
+ switch (ge.data.type) {
1482
1487
  case "utterance": {
1483
- const Y = le, he = Y.message_id ?? crypto.randomUUID();
1484
- if (k.current.has(he))
1488
+ const L = ge, de = L.message_id ?? crypto.randomUUID();
1489
+ if (v.current.has(de))
1485
1490
  return;
1486
- k.current.add(he), oe.current(), y.current(
1491
+ v.current.add(de), B(), J.current(), ne.current(
1487
1492
  {
1488
- message_id: he,
1493
+ message_id: de,
1489
1494
  response: {
1490
- id: he,
1491
- type: Y.data.type,
1492
- content: Y.data.content
1495
+ id: de,
1496
+ type: L.data.type,
1497
+ content: L.data.content
1493
1498
  }
1494
1499
  },
1495
- D
1500
+ M
1496
1501
  );
1497
1502
  return;
1498
1503
  }
1499
1504
  case "error": {
1500
- const he = parseInt(le.data.code);
1501
- W({ code: he, message: Ut(he) }), G.current?.();
1505
+ const de = parseInt(ge.data.code);
1506
+ pe({ code: de, message: Dt(de) }), Z.current?.();
1502
1507
  return;
1503
1508
  }
1504
1509
  case "agent_cognition": {
1505
- const Y = le;
1506
- P.current(Y.data.content);
1510
+ const L = ge;
1511
+ D.current(L.data.content);
1507
1512
  return;
1508
1513
  }
1509
1514
  case "agent_captured_url": {
1510
- const Y = le;
1511
- ne.current?.(Y.data.content);
1515
+ const L = ge;
1516
+ oe.current?.(L.data.content);
1512
1517
  return;
1513
1518
  }
1514
1519
  case "agent_topic": {
1515
- const Y = le;
1516
- T.current?.(Y.data.content);
1520
+ const L = ge;
1521
+ ce.current?.(L.data.content);
1517
1522
  return;
1518
1523
  }
1519
1524
  case "agent_summary": {
1520
- const Y = le;
1521
- L.current?.(Y.data.content);
1525
+ const L = ge;
1526
+ G.current?.(L.data.content);
1522
1527
  return;
1523
1528
  }
1524
1529
  case "chat_closed_expired": {
1525
- re.current?.(), A.current?.();
1530
+ V.current?.(), ie.current?.();
1526
1531
  return;
1527
1532
  }
1528
1533
  case "chat_rating": {
1529
- A.current?.();
1534
+ ie.current?.();
1530
1535
  return;
1531
1536
  }
1532
1537
  case "breadcrumb": {
1533
- K.current?.();
1538
+ Y.current?.();
1534
1539
  return;
1535
1540
  }
1536
1541
  case "chat_escalated": {
1537
- re.current?.(), A.current?.();
1542
+ V.current?.(), ie.current?.();
1538
1543
  return;
1539
1544
  }
1540
1545
  default:
1541
1546
  console.warn(
1542
1547
  "Unknown notification type:",
1543
- le.data.type
1548
+ ge.data.type
1544
1549
  );
1545
1550
  }
1546
1551
  }
1547
1552
  });
1548
- q.current = Be;
1553
+ z.current = ze;
1549
1554
  },
1550
1555
  // The *Ref entries are latest-refs (stable identities); listed to satisfy
1551
1556
  // exhaustive-deps, which can't see that useLatestRef returns a ref.
1552
1557
  [
1553
- v,
1554
- W,
1555
- fe,
1556
- b,
1557
- H,
1558
- y,
1559
- P,
1558
+ U,
1559
+ B,
1560
+ pe,
1561
+ x,
1562
+ O,
1563
+ be,
1564
+ ne,
1565
+ D,
1566
+ J,
1567
+ Z,
1568
+ V,
1560
1569
  oe,
1570
+ ce,
1561
1571
  G,
1562
- re,
1563
- ne,
1564
- T,
1565
- L,
1566
- A,
1567
- K
1572
+ ie,
1573
+ Y
1568
1574
  ]
1569
- ), z = w(
1570
- async (D) => {
1575
+ ), ee = w(
1576
+ async (M) => {
1577
+ let le;
1571
1578
  try {
1572
- const ie = await X.current(D);
1573
- for (const te of ie)
1574
- te.role !== "assistant" || !te.message_id || k.current.has(te.message_id) || (k.current.add(te.message_id), y.current(
1575
- { message_id: te.message_id, response: te.response },
1576
- D
1577
- ));
1578
- } catch (ie) {
1579
- console.warn("Backup poll failed:", ie);
1579
+ le = await ue.current(M);
1580
+ } catch (W) {
1581
+ console.warn("Backup poll failed:", W);
1582
+ return;
1580
1583
  }
1584
+ if (A.current !== M) return;
1585
+ const we = le.filter(
1586
+ (W) => W.role === "user" || W.role === "assistant"
1587
+ );
1588
+ we.forEach((W, ze) => {
1589
+ if (!W.message_id || v.current.has(W.message_id))
1590
+ return;
1591
+ const ke = we[ze - 1]?.message_id ?? null, ve = { message_id: W.message_id, response: W.response };
1592
+ if (W.role === "user") {
1593
+ ae.current?.(
1594
+ ve,
1595
+ M,
1596
+ ke,
1597
+ W.created_at
1598
+ );
1599
+ return;
1600
+ }
1601
+ v.current.add(W.message_id), B(), ne.current(ve, M, ke);
1602
+ });
1581
1603
  },
1582
- [X, y]
1583
- ), J = w(
1584
- (D) => {
1585
- C(), $.current = setInterval(
1586
- () => z(D),
1587
- g
1604
+ [ue, ne, ae, B]
1605
+ ), je = w(
1606
+ (M) => {
1607
+ k(), P.current = setInterval(
1608
+ () => ee(M),
1609
+ R
1588
1610
  );
1589
1611
  },
1590
- [C, z, g]
1591
- ), de = w(
1592
- function D() {
1593
- if (!R.current || m.current || S.current)
1612
+ [k, ee, R]
1613
+ ), Ve = w(
1614
+ function M() {
1615
+ if (!te.current || Q.current || j.current)
1594
1616
  return;
1595
- const ie = I.current;
1596
- if (!ie) return;
1597
- const te = Math.min(
1598
- Vr * Math.pow(2, j.current),
1599
- Hr
1617
+ const le = A.current;
1618
+ if (!le) return;
1619
+ const we = Math.min(
1620
+ Hr * Math.pow(2, E.current),
1621
+ Fr
1600
1622
  );
1601
- j.current += 1, S.current = setTimeout(async () => {
1602
- S.current = null, m.current = !0;
1623
+ E.current += 1, j.current = setTimeout(async () => {
1624
+ j.current = null, Q.current = !0;
1603
1625
  try {
1604
- await B(ie), j.current = 0, m.current = !1, await z(ie);
1626
+ await se(le), E.current = 0, Q.current = !1, await ee(le);
1605
1627
  } catch {
1606
- m.current = !1, D();
1628
+ Q.current = !1, M();
1607
1629
  }
1608
- }, te);
1630
+ }, we);
1609
1631
  },
1610
- [B, z]
1632
+ [se, ee]
1611
1633
  );
1612
- Z(() => {
1613
- M.current = de;
1634
+ F(() => {
1635
+ K.current = Ve;
1614
1636
  });
1615
- const pe = w(
1616
- async (D) => {
1617
- if (!ee || !D)
1637
+ const Re = w(
1638
+ async (M) => {
1639
+ if (!m || !M)
1618
1640
  throw new Error(
1619
1641
  "Cannot connect: AppSync settings not ready or missing chatId"
1620
1642
  );
1621
- O(), R.current = !0, I.current = D, j.current = 0, J(D), await B(D);
1643
+ I(), te.current = !0, A.current = M, E.current = 0, je(M), await se(M);
1622
1644
  },
1623
- [ee, O, B, J]
1624
- ), ge = w(() => {
1625
- R.current = !1, I.current = null, j.current = 0, O(), C(), v();
1626
- }, [O, C, v]), me = w(() => {
1627
- k.current.clear();
1645
+ [m, I, se, je]
1646
+ ), Ee = w(() => {
1647
+ te.current = !1, A.current = null, E.current = 0, I(), k(), y(), U();
1648
+ }, [I, k, y, U]), We = w(() => {
1649
+ const M = A.current;
1650
+ if (!M) return;
1651
+ const le = C.current + 1;
1652
+ y(), C.current = le, b.current = setInterval(
1653
+ () => ee(M),
1654
+ Gr
1655
+ ), q.current = setTimeout(
1656
+ y,
1657
+ Yr
1658
+ );
1659
+ }, [ee, y]), He = w(() => {
1660
+ v.current.clear();
1628
1661
  }, []);
1629
- return Z(() => {
1630
- !t || !ee || I.current === t || pe(t).catch((D) => {
1631
- console.error("Failed to eagerly connect:", D), I.current = t, R.current = !0, M.current();
1632
- });
1633
- }, [t, ee, pe]), Z(() => () => {
1634
- ge();
1635
- }, [ge]), { connect: pe, disconnect: ge, clearProcessedIds: me };
1636
- }
1637
- function Jr(e) {
1662
+ return F(() => {
1663
+ !t || !m || A.current === t || Re(t).catch((M) => {
1664
+ console.error("Failed to eagerly connect:", M), A.current === t && (te.current = !0, K.current());
1665
+ }).then(() => ee(t));
1666
+ }, [t, m, Re, ee]), F(() => () => {
1667
+ Ee();
1668
+ }, [Ee]), { connect: Re, disconnect: Ee, clearProcessedIds: He, expectReply: We };
1669
+ }
1670
+ function Qr(e) {
1638
1671
  return {
1639
1672
  id: e.message_id,
1640
1673
  content: e.response.content ?? "",
@@ -1642,7 +1675,30 @@ function Jr(e) {
1642
1675
  timestamp: (/* @__PURE__ */ new Date()).toISOString()
1643
1676
  };
1644
1677
  }
1645
- function Gr(e) {
1678
+ function en(e, t) {
1679
+ return {
1680
+ id: e.message_id,
1681
+ content: e.response.content,
1682
+ sender: "user",
1683
+ timestamp: t
1684
+ };
1685
+ }
1686
+ function qt(e, t, o) {
1687
+ const r = (a) => [
1688
+ ...e.slice(0, a),
1689
+ t,
1690
+ ...e.slice(a)
1691
+ ];
1692
+ if (o === null) {
1693
+ const a = e.findIndex(
1694
+ (c) => !c.isWelcomeMessage
1695
+ );
1696
+ return r(a === -1 ? e.length : a);
1697
+ }
1698
+ const n = o ? e.findIndex((a) => a.id === o) : -1;
1699
+ return n === -1 ? [...e, t] : r(n + 1);
1700
+ }
1701
+ function tn(e) {
1646
1702
  return {
1647
1703
  id: crypto.randomUUID(),
1648
1704
  content: e,
@@ -1651,7 +1707,7 @@ function Gr(e) {
1651
1707
  isWelcomeMessage: !0
1652
1708
  };
1653
1709
  }
1654
- function Yr() {
1710
+ function on() {
1655
1711
  return {
1656
1712
  id: crypto.randomUUID(),
1657
1713
  content: "",
@@ -1660,7 +1716,7 @@ function Yr() {
1660
1716
  isRatingRequest: !0
1661
1717
  };
1662
1718
  }
1663
- function Xr() {
1719
+ function rn() {
1664
1720
  return {
1665
1721
  id: crypto.randomUUID(),
1666
1722
  content: "This conversation is closed, please start a new chat.",
@@ -1668,7 +1724,7 @@ function Xr() {
1668
1724
  timestamp: (/* @__PURE__ */ new Date()).toISOString()
1669
1725
  };
1670
1726
  }
1671
- function Qr(e, t) {
1727
+ function nn(e, t) {
1672
1728
  return {
1673
1729
  ...e,
1674
1730
  id: crypto.randomUUID(),
@@ -1685,12 +1741,12 @@ function Qr(e, t) {
1685
1741
  } : {}
1686
1742
  };
1687
1743
  }
1688
- function en(e, t, o) {
1744
+ function yt(e, t, o) {
1689
1745
  return e.map(
1690
1746
  (r) => r.id === t ? o(r) : r
1691
1747
  );
1692
1748
  }
1693
- function tn(e, t, o) {
1749
+ function an(e, t, o) {
1694
1750
  return {
1695
1751
  ...e,
1696
1752
  attachments: e.attachments?.map(
@@ -1698,254 +1754,296 @@ function tn(e, t, o) {
1698
1754
  )
1699
1755
  };
1700
1756
  }
1701
- function on(e, t) {
1757
+ function sn(e, t) {
1702
1758
  return e.flatMap((o) => o.id !== t ? [o] : o.content ? [{ ...o, attachments: void 0 }] : []);
1703
1759
  }
1704
- function rn({
1760
+ function ln({
1705
1761
  appId: e,
1706
1762
  userId: t,
1707
1763
  userName: o,
1708
1764
  userData: r,
1709
1765
  externalId: n,
1710
- deviceId: i,
1766
+ deviceId: a,
1711
1767
  apiClient: c,
1712
1768
  chatSettings: s,
1713
1769
  messages: u,
1714
- setMessages: a,
1770
+ setMessages: i,
1715
1771
  currentChat: l,
1716
1772
  setCurrentChat: d,
1717
1773
  onChatClosed: p,
1718
1774
  isChatClosed: h,
1719
1775
  onAgentMessage: f
1720
1776
  }) {
1721
- const { saveChatData: g, clearChatData: k, updateLastActivity: q, markChatClosed: I } = tt({
1777
+ const { saveChatData: g, clearChatData: R, updateLastActivity: v, markChatClosed: z } = it({
1722
1778
  appId: e
1723
- }), { publishApiError: j, publishNetworkError: S } = De(), { showCognition: $, hideCognition: R } = jt(), m = V(c), y = V(u), P = w(
1724
- (b, v) => {
1725
- if (!b.response.content) return;
1726
- const C = !!s?.welcome_message && b.response.content === s.welcome_message, O = y.current.some(
1727
- (M) => M.isRatingRequest
1779
+ }), { publishApiError: A, publishNetworkError: E } = Ze(), { showCognition: j, hideCognition: P } = $t(), b = H(c), q = H(u), C = N(0), te = w(
1780
+ (m, x, O) => {
1781
+ if (!m.response.content) return;
1782
+ const U = !!s?.welcome_message && m.response.content === s.welcome_message, k = q.current.some(
1783
+ (I) => I.isRatingRequest
1784
+ ), y = q.current.some(
1785
+ (I) => I.id === m.message_id
1728
1786
  );
1729
- !C && !O && f?.(), a((M) => {
1730
- if (M.some((J) => J.isRatingRequest) || s?.welcome_message && b.response.content === s.welcome_message)
1731
- return M;
1732
- const z = [
1733
- ...M.filter((J) => !J.isThinking),
1734
- Jr(b)
1735
- ];
1787
+ !U && !k && !y && f?.();
1788
+ const B = C.current;
1789
+ i((I) => {
1790
+ if (C.current !== B || I.some((ee) => ee.isRatingRequest) || I.some((ee) => ee.id === m.message_id) || s?.welcome_message && m.response.content === s.welcome_message)
1791
+ return I;
1792
+ const K = I.filter((ee) => !ee.isThinking), se = qt(
1793
+ K,
1794
+ Qr(m),
1795
+ O
1796
+ );
1736
1797
  return g(
1737
- v,
1798
+ x,
1738
1799
  t,
1739
- z,
1740
- i,
1741
- m.current?.getChatToken()
1742
- ), z;
1800
+ se,
1801
+ a,
1802
+ b.current?.getChatToken()
1803
+ ), se;
1743
1804
  });
1744
1805
  },
1745
1806
  [
1746
1807
  s,
1747
- i,
1748
- g,
1749
1808
  a,
1809
+ g,
1810
+ i,
1750
1811
  t,
1751
- m,
1752
- y,
1812
+ b,
1813
+ q,
1753
1814
  f
1754
1815
  ]
1755
- ), oe = w(() => {
1756
- R(), a((b) => b.filter((v) => !v.isThinking));
1757
- }, [a, R]), G = w(() => {
1758
- a((b) => [...b.filter((C) => !C.isRatingRequest), Yr()]);
1759
- }, [a]);
1760
- Z(() => {
1761
- }, [G]);
1762
- const re = w(
1763
- (b) => m.current ? m.current.getChatHistory(b) : Promise.resolve([]),
1764
- [m]
1765
- ), ne = w(() => m.current?.getChatToken() ?? null, [m]), T = w(() => {
1766
- I(), p?.();
1767
- }, [I, p]), { connect: L, disconnect: A, clearProcessedIds: K } = Fr({
1816
+ ), Q = w(
1817
+ (m, x, O, U) => {
1818
+ if (!m.response.content) return;
1819
+ const k = C.current;
1820
+ i((y) => {
1821
+ if (C.current !== k || y.some(
1822
+ (K) => K.id === m.message_id || // A send whose reply POST hasn't resolved still has its local id.
1823
+ K.sender === "user" && K.isNew && K.content === m.response.content
1824
+ )) return y;
1825
+ const I = qt(
1826
+ y,
1827
+ en(m, U),
1828
+ O
1829
+ );
1830
+ return g(
1831
+ x,
1832
+ t,
1833
+ I,
1834
+ a,
1835
+ b.current?.getChatToken()
1836
+ ), I;
1837
+ });
1838
+ },
1839
+ [i, g, t, a, b]
1840
+ ), ne = w(() => {
1841
+ P(), i((m) => m.filter((x) => !x.isThinking));
1842
+ }, [i, P]), ae = w(() => {
1843
+ i((m) => [...m.filter((O) => !O.isRatingRequest), on()]);
1844
+ }, [i]);
1845
+ F(() => {
1846
+ }, [ae]);
1847
+ const D = w(
1848
+ (m) => b.current ? b.current.getChatHistory(m) : Promise.resolve([]),
1849
+ [b]
1850
+ ), J = w(() => b.current?.getChatToken() ?? null, [b]), Z = w(() => {
1851
+ z(), p?.();
1852
+ }, [z, p]), { connect: V, disconnect: oe, clearProcessedIds: ce, expectReply: G } = Xr({
1768
1853
  chatSettings: s,
1769
1854
  chatId: l?.id ?? null,
1770
1855
  messages: u,
1771
- onMessage: P,
1772
- onCognition: $,
1773
- onCognitionComplete: R,
1774
- onError: oe,
1775
- onChatClosed: T,
1776
- onRatingRequest: G,
1777
- onBreadcrumb: T,
1778
- fetchHistory: re,
1779
- getChatToken: ne
1780
- }), X = w(() => {
1781
- R(), A(), K(), Dt(u), a(
1782
- (b) => b.filter((v) => Array.isArray(v) ? !1 : v.isWelcomeMessage)
1783
- ), k(), d(null);
1856
+ onMessage: te,
1857
+ onMissedUserMessage: Q,
1858
+ onCognition: j,
1859
+ onCognitionComplete: P,
1860
+ onError: ne,
1861
+ onChatClosed: Z,
1862
+ onRatingRequest: ae,
1863
+ onBreadcrumb: Z,
1864
+ fetchHistory: D,
1865
+ getChatToken: J
1866
+ }), ie = w(() => {
1867
+ C.current += 1, P(), oe(), ce(), Bt(u), i(
1868
+ (m) => m.filter((x) => Array.isArray(x) ? !1 : x.isWelcomeMessage)
1869
+ ), R(), d(null);
1784
1870
  }, [
1785
- R,
1786
- A,
1787
- K,
1871
+ P,
1872
+ oe,
1873
+ ce,
1788
1874
  u,
1789
- k,
1790
- a,
1875
+ R,
1876
+ i,
1791
1877
  d
1792
- ]), H = w(
1793
- (b, v) => a((C) => en(C, b, v)),
1794
- [a]
1795
- ), W = w(
1796
- async (b) => {
1797
- const v = await b.createConversation({
1878
+ ]), Y = w(
1879
+ (m, x) => i((O) => yt(O, m, x)),
1880
+ [i]
1881
+ ), ue = w(
1882
+ async (m) => {
1883
+ const x = await m.createConversation({
1798
1884
  userId: n || t,
1799
- deviceId: i,
1885
+ deviceId: a,
1800
1886
  userName: o,
1801
1887
  userData: r,
1802
1888
  externalMetadata: {
1803
- searchParams: io()
1889
+ searchParams: lo()
1804
1890
  }
1805
1891
  });
1806
- d({ id: v.chat_id });
1892
+ d({ id: x.chat_id });
1807
1893
  try {
1808
- await L(v.chat_id);
1809
- } catch (C) {
1894
+ await V(x.chat_id);
1895
+ } catch (O) {
1810
1896
  console.warn(
1811
1897
  "Failed to connect realtime channel, continuing with REST-only delivery:",
1812
- C
1898
+ O
1813
1899
  );
1814
1900
  }
1815
- return v.chat_id;
1901
+ return x.chat_id;
1816
1902
  },
1817
- [n, t, i, o, r, d, L]
1818
- ), ae = w(
1819
- (b, v, C, O) => Promise.all(
1820
- C.map(
1821
- ({ file: M }, B) => b.uploadAttachment({
1822
- conversationId: v,
1823
- file: M,
1824
- onProgress: (z) => H(
1825
- O,
1826
- (J) => tn(J, B, z)
1903
+ [n, t, a, o, r, d, V]
1904
+ ), be = w(
1905
+ (m, x, O, U) => Promise.all(
1906
+ O.map(
1907
+ ({ file: k }, y) => m.uploadAttachment({
1908
+ conversationId: x,
1909
+ file: k,
1910
+ onProgress: (B) => Y(
1911
+ U,
1912
+ (I) => an(I, y, B)
1827
1913
  )
1828
- }).catch((z) => {
1829
- throw $t(z, M.name);
1914
+ }).catch((B) => {
1915
+ throw Lt(B, k.name);
1830
1916
  })
1831
1917
  )
1832
1918
  ),
1833
- [H]
1834
- ), Q = w(
1835
- (b, v, C, O) => {
1836
- R(), O && a((B) => on(B, C)), a((B) => B.filter((z) => !z.isThinking));
1837
- const M = () => H(C, (B) => ({ ...B, isFailed: !0 }));
1838
- if (b instanceof Bt) {
1839
- M();
1919
+ [Y]
1920
+ ), pe = w(
1921
+ (m, x, O, U) => {
1922
+ P(), U && i((y) => sn(y, O)), i((y) => y.filter((B) => !B.isThinking));
1923
+ const k = () => Y(O, (y) => ({ ...y, isFailed: !0 }));
1924
+ if (m instanceof Nt) {
1925
+ k();
1840
1926
  return;
1841
1927
  }
1842
- if (b instanceof et || b instanceof Oe && b.status === 403) {
1843
- S();
1928
+ if (m instanceof at || m instanceof Be && m.status === 403) {
1929
+ E();
1844
1930
  return;
1845
1931
  }
1846
- j(b), b instanceof Oe && // A 401 means an expired or closed chat token: drop the session so
1932
+ A(m), m instanceof Be && // A 401 means an expired or closed chat token: drop the session so
1847
1933
  // the next send starts a fresh one, as for a client-side expiry.
1848
- (b.status >= 500 || b.status === 401) ? (d(null), k(), a((B) => B.filter((z) => z.id !== C)), v.reset()) : M();
1934
+ (m.status >= 500 || m.status === 401) ? (d(null), R(), i((y) => y.filter((B) => B.id !== O)), x.reset()) : k();
1849
1935
  },
1850
1936
  [
1851
- R,
1852
- a,
1853
- H,
1854
- S,
1855
- j,
1937
+ P,
1938
+ i,
1939
+ Y,
1940
+ E,
1941
+ A,
1856
1942
  d,
1857
- k
1943
+ R
1858
1944
  ]
1859
- ), ee = w(
1860
- async (b, v = []) => {
1861
- if (!c || u.some((O) => O.isRatingRequest)) return;
1945
+ ), re = w(
1946
+ async (m, x = []) => {
1947
+ if (!c || u.some((k) => k.isRatingRequest)) return;
1862
1948
  if (h) {
1863
- a((O) => [...O, Xr()]);
1949
+ i((k) => [...k, rn()]);
1864
1950
  return;
1865
1951
  }
1866
- const C = Qr(b, v);
1867
- a([...u, C]), q();
1952
+ const O = C.current, U = nn(m, x);
1953
+ i((k) => [...k, U]), v();
1868
1954
  try {
1869
- const O = l?.id || await W(c), M = await ae(
1955
+ const k = l?.id || await ue(c), y = await be(
1870
1956
  c,
1871
- O,
1872
- v,
1873
- C.id
1957
+ k,
1958
+ x,
1959
+ U.id
1874
1960
  );
1875
- M.length > 0 && H(C.id, (z) => ({
1876
- ...z,
1877
- attachments: Lt(M, v)
1961
+ y.length > 0 && Y(U.id, (I) => ({
1962
+ ...I,
1963
+ attachments: Zt(y, x)
1878
1964
  }));
1879
1965
  const B = await c.replyToConversation({
1880
- text: b.content,
1881
- attachments: M,
1882
- conversationId: O,
1966
+ text: m.content,
1967
+ attachments: y,
1968
+ conversationId: k,
1883
1969
  userId: n || t,
1884
- deviceId: i,
1970
+ deviceId: a,
1885
1971
  userName: o,
1886
1972
  userData: r
1887
1973
  });
1888
- H(C.id, (z) => ({
1889
- ...z,
1890
- id: B.message_id,
1891
- isNew: !1
1892
- }));
1893
- } catch (O) {
1894
- throw Q(
1895
- O,
1974
+ i((I) => {
1975
+ if (C.current !== O) return I;
1976
+ const K = yt(
1977
+ I,
1978
+ U.id,
1979
+ (se) => ({ ...se, id: B.message_id, isNew: !1 })
1980
+ );
1981
+ return g(
1982
+ k,
1983
+ t,
1984
+ K,
1985
+ a,
1986
+ c.getChatToken()
1987
+ ), K;
1988
+ }), G();
1989
+ } catch (k) {
1990
+ throw pe(
1991
+ k,
1896
1992
  c,
1897
- C.id,
1898
- v.length > 0
1899
- ), O;
1993
+ U.id,
1994
+ x.length > 0
1995
+ ), k;
1900
1996
  }
1901
1997
  },
1902
1998
  [
1903
1999
  c,
1904
2000
  u,
1905
2001
  h,
1906
- a,
1907
- q,
2002
+ i,
2003
+ v,
1908
2004
  l?.id,
1909
- W,
1910
- ae,
1911
- H,
1912
- Q,
2005
+ ue,
2006
+ be,
2007
+ Y,
2008
+ g,
2009
+ G,
2010
+ pe,
1913
2011
  n,
1914
2012
  t,
1915
- i,
2013
+ a,
1916
2014
  o,
1917
2015
  r
1918
2016
  ]
1919
- ), fe = w(
1920
- async (b) => {
1921
- const v = l?.id;
1922
- !m.current || !v || await m.current.addRating(v, b);
2017
+ ), he = w(
2018
+ async (m) => {
2019
+ const x = l?.id;
2020
+ !b.current || !x || await b.current.addRating(x, m);
1923
2021
  },
1924
- [l?.id, m]
2022
+ [l?.id, b]
1925
2023
  );
1926
2024
  return {
1927
- onCleanMessages: X,
1928
- onSendMessage: ee,
1929
- onRateChat: fe
2025
+ onCleanMessages: ie,
2026
+ onSendMessage: re,
2027
+ onRateChat: he
1930
2028
  };
1931
2029
  }
1932
- const nn = { BASE_URL: "/", DEV: !1, MODE: "prod", PROD: !0, SSR: !1, VITE_API_URL: "https://chat.eloquentai.co", VITE_CDN_URL: "https://cdn.eloquentai.co", VITE_ENVIRONMENT: "prod", VITE_REGION_API_URL: "https://region.eloquentai.co" };
1933
- function Ct(e) {
1934
- return typeof window > "u" || typeof import.meta > "u" ? "" : nn[e] || "";
2030
+ const cn = { BASE_URL: "/", DEV: !1, MODE: "dev", PROD: !0, SSR: !1, VITE_API_URL: "https://chat.eloquentai.dev", VITE_CDN_URL: "https://cdn.eloquentai.dev", VITE_ENVIRONMENT: "dev", VITE_REGION_API_URL: "https://region.eloquentai.dev" };
2031
+ function Tt(e) {
2032
+ return typeof window > "u" || typeof import.meta > "u" ? "" : cn[e] || "";
1935
2033
  }
1936
- const an = Ct("VITE_API_URL"), sn = Ct("VITE_REGION_API_URL");
1937
- function ln() {
1938
- return an || "";
2034
+ const un = Tt("VITE_API_URL"), dn = Tt("VITE_REGION_API_URL");
2035
+ function pn() {
2036
+ return un || "";
1939
2037
  }
1940
- function cn() {
1941
- return sn || "";
2038
+ function hn() {
2039
+ return dn || "";
1942
2040
  }
1943
- class un {
2041
+ class fn {
1944
2042
  httpClient;
1945
2043
  userId = null;
1946
2044
  conversationId = null;
1947
2045
  constructor(t) {
1948
- this.userId = t.userId || null, this.httpClient = new Nt(t);
2046
+ this.userId = t.userId || null, this.httpClient = new Kt(t);
1949
2047
  }
1950
2048
  getUserData() {
1951
2049
  return {
@@ -1972,7 +2070,7 @@ class un {
1972
2070
  * Get organization data by app ID
1973
2071
  */
1974
2072
  async getOrganizationByAppId(t) {
1975
- const o = cn();
2073
+ const o = hn();
1976
2074
  return await this.httpClient.getExternal(
1977
2075
  `${o}/by-app-id/${t}`
1978
2076
  );
@@ -2019,14 +2117,14 @@ class un {
2019
2117
  o,
2020
2118
  t.onProgress
2021
2119
  );
2022
- return Zr.parse(r).data;
2120
+ return Vr.parse(r).data;
2023
2121
  }
2024
2122
  async getAttachmentUrls(t, o) {
2025
2123
  const r = await this.httpClient.post(
2026
2124
  `/v1/chat/${t}/attachments/urls`,
2027
2125
  { urls: o }
2028
2126
  );
2029
- return Kr.parse(r).data.urls;
2127
+ return Wr.parse(r).data.urls;
2030
2128
  }
2031
2129
  async identifyUser(t) {
2032
2130
  const o = {
@@ -2044,62 +2142,62 @@ class un {
2044
2142
  )).data;
2045
2143
  }
2046
2144
  }
2047
- const dn = {
2145
+ const gn = {
2048
2146
  retries: 3,
2049
2147
  minDelayMs: 200,
2050
2148
  maxDelayMs: 1e3,
2051
2149
  factor: 2
2052
2150
  };
2053
- function pn(e) {
2054
- return e instanceof et ? !0 : e instanceof Oe ? e.status === 429 || e.status >= 500 : !1;
2151
+ function mn(e) {
2152
+ return e instanceof at ? !0 : e instanceof Be ? e.status === 429 || e.status >= 500 : !1;
2055
2153
  }
2056
- function hn(e, t) {
2154
+ function bn(e, t) {
2057
2155
  const o = t.minDelayMs * t.factor ** e, r = Math.min(o, t.maxDelayMs);
2058
2156
  return Math.random() * r;
2059
2157
  }
2060
- async function mt(e, t = {}) {
2061
- const o = { ...dn, ...t };
2158
+ async function xt(e, t = {}) {
2159
+ const o = { ...gn, ...t };
2062
2160
  for (let r = 0; ; r++)
2063
2161
  try {
2064
2162
  return await e();
2065
2163
  } catch (n) {
2066
- if (r >= o.retries || !pn(n))
2164
+ if (r >= o.retries || !mn(n))
2067
2165
  throw n;
2068
2166
  await new Promise(
2069
- (i) => setTimeout(i, hn(r, o))
2167
+ (a) => setTimeout(a, bn(r, o))
2070
2168
  );
2071
2169
  }
2072
2170
  }
2073
- const Pe = /* @__PURE__ */ new Map(), Ae = /* @__PURE__ */ new Map();
2074
- function fn(e, t, o) {
2075
- const r = o?.dedupe !== !1, [n, i] = _(
2076
- () => Pe.get(e)
2077
- ), { publishApiError: c, publishNetworkError: s } = De(), [u, a] = _(void 0), [l, d] = _(!1), p = N(!0);
2171
+ const De = /* @__PURE__ */ new Map(), $e = /* @__PURE__ */ new Map();
2172
+ function wn(e, t, o) {
2173
+ const r = o?.dedupe !== !1, [n, a] = S(
2174
+ () => De.get(e)
2175
+ ), { publishApiError: c, publishNetworkError: s } = Ze(), [u, i] = S(void 0), [l, d] = S(!1), p = N(!0);
2078
2176
  N(() => (p.current = !0, () => {
2079
2177
  p.current = !1;
2080
2178
  }));
2081
2179
  const h = w(async () => {
2082
- if (Pe.has(e)) {
2083
- const f = Pe.get(e);
2084
- return i(f), f;
2180
+ if (De.has(e)) {
2181
+ const f = De.get(e);
2182
+ return a(f), f;
2085
2183
  }
2086
- d(!0), a(void 0);
2184
+ d(!0), i(void 0);
2087
2185
  try {
2088
- if (r && Ae.has(e))
2089
- return await Ae.get(e);
2186
+ if (r && $e.has(e))
2187
+ return await $e.get(e);
2090
2188
  const f = t();
2091
- r && Ae.set(e, f);
2189
+ r && $e.set(e, f);
2092
2190
  const g = await f;
2093
- return Pe.set(e, g), p.current && i(g), g;
2191
+ return De.set(e, g), p.current && a(g), g;
2094
2192
  } catch (f) {
2095
- throw f instanceof et || f instanceof Oe && f.status === 403 ? s() : c(f), p.current && a(f), f;
2193
+ throw f instanceof at || f instanceof Be && f.status === 403 ? s() : c(f), p.current && i(f), f;
2096
2194
  } finally {
2097
- Ae.delete(e), p.current && d(!1);
2195
+ $e.delete(e), p.current && d(!1);
2098
2196
  }
2099
2197
  }, [e, r, t, c, s]);
2100
2198
  return { data: n, error: u, isLoading: l, fetch: h };
2101
2199
  }
2102
- function bt(e, t) {
2200
+ function kt(e, t) {
2103
2201
  const o = e?.deviceId || crypto.randomUUID();
2104
2202
  return e?.userId ? e.externalId !== t ? { userId: e.userId, externalId: t, deviceId: o } : {
2105
2203
  userId: e.userId,
@@ -2107,11 +2205,11 @@ function bt(e, t) {
2107
2205
  deviceId: o
2108
2206
  } : t ? { userId: t, externalId: t, deviceId: o } : { userId: crypto.randomUUID(), externalId: null, deviceId: o };
2109
2207
  }
2110
- function gn(e) {
2111
- const { appId: t, initialUserId: o } = e, { getSavedChatData: r } = tt({ appId: t }), [n, i] = _(
2112
- () => bt(r(), o)
2113
- ), [c, s] = _(o);
2114
- return c !== o && (s(o), i(bt(r(), o))), {
2208
+ function vn(e) {
2209
+ const { appId: t, initialUserId: o } = e, { getSavedChatData: r } = it({ appId: t }), [n, a] = S(
2210
+ () => kt(r(), o)
2211
+ ), [c, s] = S(o);
2212
+ return c !== o && (s(o), a(kt(r(), o))), {
2115
2213
  // Identity is available synchronously; kept in the contract because
2116
2214
  // consumers (SDK boot) still key off it.
2117
2215
  isReady: !0,
@@ -2120,7 +2218,7 @@ function gn(e) {
2120
2218
  externalId: n.externalId
2121
2219
  };
2122
2220
  }
2123
- function mn({
2221
+ function qn({
2124
2222
  apiUrl: e,
2125
2223
  appId: t,
2126
2224
  initialUserId: o,
@@ -2128,92 +2226,92 @@ function mn({
2128
2226
  userData: n
2129
2227
  }) {
2130
2228
  const {
2131
- userId: i,
2229
+ userId: a,
2132
2230
  externalId: c,
2133
2231
  deviceId: s,
2134
2232
  isReady: u
2135
- } = gn({ appId: t, initialUserId: o }), { isChatExpired: a, clearChatData: l, getSavedChatData: d } = tt({
2233
+ } = vn({ appId: t, initialUserId: o }), { isChatExpired: i, clearChatData: l, getSavedChatData: d } = it({
2136
2234
  appId: t
2137
- }), { current: p } = N(e || ln()), [h] = _(
2138
- new un({
2235
+ }), { current: p } = N(e || pn()), [h] = S(
2236
+ new fn({
2139
2237
  baseURL: p,
2140
2238
  appId: t
2141
2239
  })
2142
- ), [f, g] = _(null), [k, q] = _(null), [I, j] = _([]), [S, $] = _(!1), [R, m] = _(!1), [y, P] = _(!0), G = fn(`sdk-boot-${t}`, () => h.boot()).fetch;
2143
- Z(() => {
2144
- if (a())
2240
+ ), [f, g] = S(null), [R, v] = S(null), [z, A] = S([]), [E, j] = S(!1), [P, b] = S(!1), [q, C] = S(!0), Q = wn(`sdk-boot-${t}`, () => h.boot()).fetch;
2241
+ F(() => {
2242
+ if (i())
2145
2243
  l();
2146
2244
  else {
2147
2245
  const {
2148
- conversationId: ne,
2149
- userId: T,
2150
- messages: L,
2151
- isChatClosed: A,
2152
- chatToken: K
2246
+ conversationId: ae,
2247
+ userId: D,
2248
+ messages: J,
2249
+ isChatClosed: Z,
2250
+ chatToken: V
2153
2251
  } = d();
2154
- ne && T && (q({
2155
- id: ne
2156
- }), h.setChatToken(K ?? null), L && L.length > 0 && j(L), A && m(!0));
2252
+ ae && D && (v({
2253
+ id: ae
2254
+ }), h.setChatToken(V ?? null), J && J.length > 0 && A(J), Z && b(!0));
2157
2255
  }
2158
- }, [d, a, l, h]);
2159
- const re = N(!1);
2160
- return Z(() => {
2161
- if (re.current) return;
2162
- re.current = !0, (async () => {
2163
- const [T, L] = await it(
2164
- mt(() => h.getOrganizationByAppId(t))
2256
+ }, [d, i, l, h]);
2257
+ const ne = N(!1);
2258
+ return F(() => {
2259
+ if (ne.current) return;
2260
+ ne.current = !0, (async () => {
2261
+ const [D, J] = await ut(
2262
+ xt(() => h.getOrganizationByAppId(t))
2165
2263
  );
2166
- if (L) {
2167
- console.error("Failed to fetch organization data:", L), P(!1), $(!0);
2264
+ if (J) {
2265
+ console.error("Failed to fetch organization data:", J), C(!1), j(!0);
2168
2266
  return;
2169
2267
  }
2170
- h.setRegion(T.region);
2171
- const [A, K] = await it(mt(G));
2172
- if (K) {
2173
- P(!1), $(!0);
2268
+ h.setRegion(D.region);
2269
+ const [Z, V] = await ut(xt(Q));
2270
+ if (V) {
2271
+ C(!1), j(!0);
2174
2272
  return;
2175
2273
  }
2176
2274
  const {
2177
- conversationId: X,
2178
- userId: H,
2179
- messages: W
2275
+ conversationId: oe,
2276
+ userId: ce,
2277
+ messages: G
2180
2278
  } = d();
2181
- X && H && W.some(Zt) && j(
2182
- await Kt(h, X, W)
2279
+ oe && ce && G.some(Vt) && A(
2280
+ await Wt(h, oe, G)
2183
2281
  );
2184
- const ae = A.chat_settings.welcome_message;
2185
- g(A.chat_settings), P(A.chat_settings.is_active ?? !0), ae && j((Q) => Q.length > 0 || Q.some((ee) => ee.isWelcomeMessage) ? Q : [Gr(ae)]), $(!0);
2282
+ const ie = Z.chat_settings.welcome_message;
2283
+ g(Z.chat_settings), C(Z.chat_settings.is_active ?? !0), ie && A((Y) => Y.length > 0 || Y.some((ue) => ue.isWelcomeMessage) ? Y : [tn(ie)]), j(!0);
2186
2284
  })();
2187
- }, [u, h, t, G, d]), {
2188
- userId: i,
2285
+ }, [u, h, t, Q, d]), {
2286
+ userId: a,
2189
2287
  userName: r,
2190
2288
  userData: n,
2191
2289
  externalId: c,
2192
2290
  deviceId: s,
2193
2291
  apiClient: h,
2194
2292
  chatSettings: f,
2195
- currentChat: k,
2196
- messages: I,
2197
- isReady: S,
2198
- isChatClosed: R,
2199
- isChatActive: y
2293
+ currentChat: R,
2294
+ messages: z,
2295
+ isReady: E,
2296
+ isChatClosed: P,
2297
+ isChatActive: q
2200
2298
  };
2201
2299
  }
2202
- const St = "(max-width: 640px)";
2203
- function bn() {
2204
- return typeof window > "u" ? !1 : window.matchMedia(St).matches;
2300
+ const Mt = "(max-width: 640px)";
2301
+ function yn() {
2302
+ return typeof window > "u" ? !1 : window.matchMedia(Mt).matches;
2205
2303
  }
2206
- function vn(e) {
2207
- const [t, o] = _(bn), [r, n] = _(
2304
+ function xn(e) {
2305
+ const [t, o] = S(yn), [r, n] = S(
2208
2306
  null
2209
- ), i = e ?? t, c = typeof window > "u";
2210
- return Z(() => {
2307
+ ), a = e ?? t, c = typeof window > "u";
2308
+ return F(() => {
2211
2309
  if (c) return;
2212
- const s = window.matchMedia(St), u = (a) => {
2213
- o(a.matches);
2310
+ const s = window.matchMedia(Mt), u = (i) => {
2311
+ o(i.matches);
2214
2312
  };
2215
2313
  return u(s), s.addEventListener("change", u), () => s.removeEventListener("change", u);
2216
- }, [c]), Z(() => {
2314
+ }, [c]), F(() => {
2217
2315
  if (c) return;
2218
2316
  const s = document.createElement("div");
2219
2317
  return s.className = "eloquent-ai-chat-portal", s.style.position = "relative", s.style.zIndex = "30", document.body.appendChild(s), n(s), () => {
@@ -2221,40 +2319,40 @@ function vn(e) {
2221
2319
  };
2222
2320
  }, [c]), {
2223
2321
  isMobileScreen: t,
2224
- isMobile: i,
2322
+ isMobile: a,
2225
2323
  portalContainer: r
2226
2324
  };
2227
2325
  }
2228
- const vt = 1245, wn = [
2326
+ const _t = 1245, kn = [
2229
2327
  [2.32, 0.4],
2230
2328
  [4.25, 0.18]
2231
- ], qn = [
2329
+ ], _n = [
2232
2330
  { start: 0, duration: 0.22, level: 0.45 },
2233
2331
  { start: 0.16, duration: 0.2, level: 0.25 }
2234
- ], yn = 0.3, xn = 3e-3, wt = 1e-4;
2235
- function qt(e, t, o, r, n, i) {
2332
+ ], Cn = 0.3, Sn = 3e-3, Ct = 1e-4;
2333
+ function St(e, t, o, r, n, a) {
2236
2334
  const c = e.createOscillator(), s = e.createGain();
2237
- c.type = "sine", c.frequency.setValueAtTime(o, n), s.gain.setValueAtTime(wt, n), s.gain.exponentialRampToValueAtTime(r, n + xn), s.gain.exponentialRampToValueAtTime(wt, n + i), c.connect(s).connect(t), c.start(n), c.stop(n + i + 0.05);
2335
+ c.type = "sine", c.frequency.setValueAtTime(o, n), s.gain.setValueAtTime(Ct, n), s.gain.exponentialRampToValueAtTime(r, n + Sn), s.gain.exponentialRampToValueAtTime(Ct, n + a), c.connect(s).connect(t), c.start(n), c.stop(n + a + 0.05);
2238
2336
  }
2239
- function kn(e) {
2337
+ function In(e) {
2240
2338
  const t = e.createGain();
2241
- t.gain.value = yn;
2339
+ t.gain.value = Cn;
2242
2340
  const o = e.createBiquadFilter();
2243
2341
  o.type = "lowpass", o.frequency.value = 6e3, t.connect(o).connect(e.destination);
2244
2342
  const r = e.currentTime + 0.02;
2245
- qn.forEach((n) => {
2246
- qt(
2343
+ _n.forEach((n) => {
2344
+ St(
2247
2345
  e,
2248
2346
  t,
2249
- vt,
2347
+ _t,
2250
2348
  n.level,
2251
2349
  r + n.start,
2252
2350
  n.duration
2253
- ), wn.forEach(([i, c]) => {
2254
- qt(
2351
+ ), kn.forEach(([a, c]) => {
2352
+ St(
2255
2353
  e,
2256
2354
  t,
2257
- vt * i,
2355
+ _t * a,
2258
2356
  n.level * c,
2259
2357
  r + n.start,
2260
2358
  n.duration * 0.35
@@ -2262,34 +2360,34 @@ function kn(e) {
2262
2360
  });
2263
2361
  });
2264
2362
  }
2265
- const Xe = "eloquentai:notification-sound-muted", _n = 3e3;
2266
- function Cn() {
2363
+ const rt = "eloquentai:notification-sound-muted", Rn = 3e3;
2364
+ function En() {
2267
2365
  try {
2268
- return window.localStorage.getItem(Xe) === "true";
2366
+ return window.localStorage.getItem(rt) === "true";
2269
2367
  } catch {
2270
2368
  return !1;
2271
2369
  }
2272
2370
  }
2273
- function Sn(e) {
2371
+ function zn(e) {
2274
2372
  try {
2275
- e ? window.localStorage.setItem(Xe, "true") : window.localStorage.removeItem(Xe);
2373
+ e ? window.localStorage.setItem(rt, "true") : window.localStorage.removeItem(rt);
2276
2374
  } catch {
2277
2375
  }
2278
2376
  }
2279
- function In(e) {
2377
+ function Tn(e) {
2280
2378
  return document.visibilityState === "visible" && document.hasFocus() && e;
2281
2379
  }
2282
- function En() {
2380
+ function Mn() {
2283
2381
  const e = window.webkitAudioContext;
2284
2382
  return window.AudioContext ?? e ?? null;
2285
2383
  }
2286
- function zn({
2384
+ function An({
2287
2385
  isEnabled: e,
2288
2386
  isOpen: t
2289
2387
  }) {
2290
- const [o, r] = _(Cn), n = N(null), i = N(0), c = V(t), s = V(o), u = w(() => {
2388
+ const [o, r] = S(En), n = N(null), a = N(0), c = H(t), s = H(o), u = w(() => {
2291
2389
  if (!e) return;
2292
- const d = En();
2390
+ const d = Mn();
2293
2391
  if (!d) return;
2294
2392
  try {
2295
2393
  n.current ??= new d();
@@ -2300,38 +2398,38 @@ function zn({
2300
2398
  (p === "suspended" || p === "interrupted") && n.current.resume().catch(() => {
2301
2399
  });
2302
2400
  }, [e]);
2303
- Z(() => {
2401
+ F(() => {
2304
2402
  if (!e) return;
2305
2403
  const d = { capture: !0 }, p = () => u();
2306
2404
  return window.addEventListener("pointerdown", p, d), window.addEventListener("keydown", p, d), () => {
2307
2405
  window.removeEventListener("pointerdown", p, d), window.removeEventListener("keydown", p, d);
2308
2406
  };
2309
2407
  }, [e, u]);
2310
- const a = w(() => {
2311
- if (!e || s.current || In(c.current)) return;
2408
+ const i = w(() => {
2409
+ if (!e || s.current || Tn(c.current)) return;
2312
2410
  const d = n.current;
2313
2411
  if (!d || d.state !== "running") return;
2314
2412
  const p = Date.now();
2315
- p - i.current < _n || (i.current = p, kn(d));
2413
+ p - a.current < Rn || (a.current = p, In(d));
2316
2414
  }, [e, s, c]), l = w(() => {
2317
2415
  r((d) => !d);
2318
2416
  }, []);
2319
- return Z(() => {
2320
- Sn(o);
2321
- }, [o]), { notify: a, unlock: u, isMuted: o, toggleMuted: l };
2417
+ return F(() => {
2418
+ zn(o);
2419
+ }, [o]), { notify: i, unlock: u, isMuted: o, toggleMuted: l };
2322
2420
  }
2323
- const Rn = 2, Tn = (e) => `eloquent-ai:chat-widget-closed-${e}`;
2324
- function Mn({
2421
+ const Pn = 2, On = (e) => `eloquent-ai:chat-widget-closed-${e}`;
2422
+ function Un({
2325
2423
  environment: e,
2326
2424
  apiUrl: t,
2327
2425
  appId: o,
2328
2426
  userId: r,
2329
2427
  userName: n,
2330
- userData: i,
2428
+ userData: a,
2331
2429
  chatProps: c,
2332
2430
  isMobile: s,
2333
2431
  isInitiallyOpen: u,
2334
- hasCloseButton: a,
2432
+ hasCloseButton: i,
2335
2433
  hasCleanChatButton: l,
2336
2434
  // Deprecated aliases, kept until hosts migrate to the is/has names above.
2337
2435
  initialOpen: d,
@@ -2339,156 +2437,156 @@ function Mn({
2339
2437
  cleanChatButton: h,
2340
2438
  proactiveMessageHideDelay: f = 5e3,
2341
2439
  isAlwaysOpen: g = !1,
2342
- hasCleanChatButtonOverride: k
2440
+ hasCleanChatButtonOverride: R
2343
2441
  }) {
2344
- const { isMobile: q, portalContainer: I } = vn(s), {
2345
- userId: j,
2346
- externalId: S,
2347
- deviceId: $,
2348
- apiClient: R,
2349
- chatSettings: m,
2350
- currentChat: y,
2351
- messages: P,
2352
- isReady: oe,
2353
- isChatClosed: G,
2354
- isChatActive: re
2355
- } = mn({
2442
+ const { isMobile: v, portalContainer: z } = xn(s), {
2443
+ userId: A,
2444
+ externalId: E,
2445
+ deviceId: j,
2446
+ apiClient: P,
2447
+ chatSettings: b,
2448
+ currentChat: q,
2449
+ messages: C,
2450
+ isReady: te,
2451
+ isChatClosed: Q,
2452
+ isChatActive: ne
2453
+ } = qn({
2356
2454
  apiUrl: t,
2357
2455
  appId: o,
2358
2456
  initialUserId: r,
2359
2457
  userName: n,
2360
- userData: i
2361
- }), ne = ao({ chatProps: c, chatSettings: m }), T = u ?? d ?? !1, L = a ?? p ?? !0, A = l ?? h ?? !0, K = Tn(o), [X, H] = _(() => g ? !0 : lt(K) === "true" || q ? !1 : T ?? q), [W, ae] = _(!1);
2362
- Z(() => {
2363
- if (!oe || W || (ae(!0), g)) return;
2364
- const ce = m?.initial_open;
2365
- ce != null && (q || ce && lt(K) === "true" || H(ce));
2458
+ userData: a
2459
+ }), ae = so({ chatProps: c, chatSettings: b }), D = u ?? d ?? !1, J = i ?? p ?? !0, Z = l ?? h ?? !0, V = On(o), [oe, ce] = S(() => g ? !0 : pt(V) === "true" || v ? !1 : D ?? v), [G, ie] = S(!1);
2460
+ F(() => {
2461
+ if (!te || G || (ie(!0), g)) return;
2462
+ const L = b?.initial_open;
2463
+ L != null && (v || L && pt(V) === "true" || ce(L));
2366
2464
  }, [
2367
- oe,
2368
- W,
2369
- m?.initial_open,
2370
- q,
2371
- K,
2465
+ te,
2466
+ G,
2467
+ b?.initial_open,
2468
+ v,
2469
+ V,
2372
2470
  g
2373
2471
  ]);
2374
- const Q = m?.initial_open ?? T, ee = m?.close_button ?? L, fe = k ?? m?.clean_chat_button ?? A, b = m?.proactive_message_hide_delay ?? f, v = zn({
2375
- isEnabled: m?.notification_sound !== !1,
2376
- isOpen: X
2377
- }), { unlock: C } = v, O = w(
2378
- (ce) => {
2379
- g || (C(), H((Me) => {
2380
- const nt = typeof ce == "function" ? ce(Me) : ce;
2381
- return nt ? no(K) : ro(K, "true", Rn), nt;
2472
+ const Y = b?.initial_open ?? D, ue = b?.close_button ?? J, be = R ?? b?.clean_chat_button ?? Z, pe = b?.proactive_message_hide_delay ?? f, re = An({
2473
+ isEnabled: b?.notification_sound !== !1,
2474
+ isOpen: oe
2475
+ }), { unlock: he } = re, m = w(
2476
+ (L) => {
2477
+ g || (he(), ce((de) => {
2478
+ const lt = typeof L == "function" ? L(de) : L;
2479
+ return lt ? io(V) : ao(V, "true", Pn), lt;
2382
2480
  }));
2383
2481
  },
2384
- [K, g, C]
2385
- ), M = Vt(X, 400), [B, z] = _(
2482
+ [V, g, he]
2483
+ ), x = Ht(oe, 400), [O, U] = S(
2386
2484
  c?.messages ?? []
2387
- ), [J, de] = _(y), [pe, ge] = _(!1), [me, D] = _(P);
2388
- me !== P && (D(P), P.length > 0 && z(P));
2389
- const [ie, te] = _(y);
2390
- ie !== y && (te(y), y && de(y));
2391
- const [Te, Be] = _(G);
2392
- Te !== G && (Be(G), G && ge(!0));
2393
- const Le = w(() => {
2394
- ge(!0);
2395
- }, []), [_e, le] = _(!1), Y = oe && m?.auto_display_welcome_message && m?.welcome_message ? m.welcome_message : "", he = {
2396
- text: Y,
2397
- isVisible: Y !== "" && !_e,
2398
- autoHideDelay: b
2399
- }, { onSendMessage: It, onCleanMessages: Ne, onRateChat: Et } = rn({
2485
+ ), [k, y] = S(q), [B, I] = S(!1), [K, se] = S(C);
2486
+ K !== C && (se(C), C.length > 0 && U(C));
2487
+ const [ee, je] = S(q);
2488
+ ee !== q && (je(q), q && y(q));
2489
+ const [Ve, Re] = S(Q);
2490
+ Ve !== Q && (Re(Q), Q && I(!0));
2491
+ const Ee = w(() => {
2492
+ I(!0);
2493
+ }, []), [We, He] = S(!1), M = te && b?.auto_display_welcome_message && b?.welcome_message ? b.welcome_message : "", le = {
2494
+ text: M,
2495
+ isVisible: M !== "" && !We,
2496
+ autoHideDelay: pe
2497
+ }, { onSendMessage: we, onCleanMessages: W, onRateChat: ze } = ln({
2400
2498
  appId: o,
2401
- userId: j,
2499
+ userId: A,
2402
2500
  userName: n,
2403
- userData: i,
2404
- externalId: S,
2405
- deviceId: $,
2406
- apiClient: R,
2407
- chatSettings: m,
2408
- setMessages: z,
2409
- messages: B,
2410
- currentChat: J,
2411
- setCurrentChat: de,
2412
- onChatClosed: Le,
2413
- isChatClosed: pe,
2414
- onAgentMessage: v.notify
2501
+ userData: a,
2502
+ externalId: E,
2503
+ deviceId: j,
2504
+ apiClient: P,
2505
+ chatSettings: b,
2506
+ setMessages: U,
2507
+ messages: O,
2508
+ currentChat: k,
2509
+ setCurrentChat: y,
2510
+ onChatClosed: Ee,
2511
+ isChatClosed: B,
2512
+ onAgentMessage: re.notify
2415
2513
  });
2416
- Z(() => {
2417
- P.length > 0 && z(P);
2418
- }, [P]), Z(() => {
2419
- y && de(y);
2420
- }, [y]);
2421
- const rt = N(null);
2422
- Z(() => {
2423
- if (!J || !S || !R) return;
2424
- const ce = {
2425
- userId: j,
2514
+ F(() => {
2515
+ C.length > 0 && U(C);
2516
+ }, [C]), F(() => {
2517
+ q && y(q);
2518
+ }, [q]);
2519
+ const ke = N(null);
2520
+ F(() => {
2521
+ if (!k || !E || !P) return;
2522
+ const L = {
2523
+ userId: A,
2426
2524
  userName: n,
2427
- userData: i,
2428
- externalId: S,
2429
- deviceId: $,
2430
- conversationId: J.id
2431
- }, Me = JSON.stringify(ce);
2432
- rt.current !== Me && (rt.current = Me, R.identifyUser(ce));
2525
+ userData: a,
2526
+ externalId: E,
2527
+ deviceId: j,
2528
+ conversationId: k.id
2529
+ }, de = JSON.stringify(L);
2530
+ ke.current !== de && (ke.current = de, P.identifyUser(L));
2433
2531
  }, [
2434
- S,
2435
- j,
2532
+ E,
2533
+ A,
2436
2534
  n,
2437
- i,
2438
- $,
2439
- J,
2440
- R
2535
+ a,
2536
+ j,
2537
+ k,
2538
+ P
2441
2539
  ]);
2442
- const zt = w(() => {
2443
- Ne(), ge(!1);
2444
- }, [Ne]), Rt = w(() => {
2445
- le(!0);
2540
+ const ve = w(() => {
2541
+ W(), I(!1);
2542
+ }, [W]), ge = w(() => {
2543
+ He(!0);
2446
2544
  }, []);
2447
2545
  return {
2448
- isReady: oe,
2449
- isChatActive: re,
2450
- isInitiallyOpen: Q,
2451
- hasCloseButton: ee,
2452
- hasCleanChatButton: fe,
2453
- isMobile: q,
2454
- chatId: J?.id ?? null,
2455
- chatInterfaceProps: ne,
2456
- chatOpen: X,
2457
- chatOpenDebounced: M,
2458
- messages: B,
2459
- portalContainer: I,
2460
- onSendMessage: It,
2461
- setChatOpen: O,
2462
- onCleanMessages: Ne,
2463
- proactiveMessage: he,
2464
- hideProactiveMessage: Rt,
2465
- isChatClosed: pe,
2466
- onStartNewChat: zt,
2467
- onRateChat: Et,
2468
- unlockSound: C,
2469
- isSoundMuted: v.isMuted,
2470
- toggleSound: v.toggleMuted
2546
+ isReady: te,
2547
+ isChatActive: ne,
2548
+ isInitiallyOpen: Y,
2549
+ hasCloseButton: ue,
2550
+ hasCleanChatButton: be,
2551
+ isMobile: v,
2552
+ chatId: k?.id ?? null,
2553
+ chatInterfaceProps: ae,
2554
+ chatOpen: oe,
2555
+ chatOpenDebounced: x,
2556
+ messages: O,
2557
+ portalContainer: z,
2558
+ onSendMessage: we,
2559
+ setChatOpen: m,
2560
+ onCleanMessages: W,
2561
+ proactiveMessage: le,
2562
+ hideProactiveMessage: ge,
2563
+ isChatClosed: B,
2564
+ onStartNewChat: ve,
2565
+ onRateChat: ze,
2566
+ unlockSound: he,
2567
+ isSoundMuted: re.isMuted,
2568
+ toggleSound: re.toggleMuted
2471
2569
  };
2472
2570
  }
2473
- function Pn(e) {
2474
- const [t, o] = _(0);
2475
- return Z(() => {
2571
+ function jn(e) {
2572
+ const [t, o] = S(0);
2573
+ return F(() => {
2476
2574
  const r = window.visualViewport;
2477
2575
  if (!e || !r) {
2478
2576
  o(0);
2479
2577
  return;
2480
2578
  }
2481
2579
  const n = () => {
2482
- const i = window.innerHeight - r.height - r.offsetTop;
2483
- o(Math.max(0, Math.round(i)));
2580
+ const a = window.innerHeight - r.height - r.offsetTop;
2581
+ o(Math.max(0, Math.round(a)));
2484
2582
  };
2485
2583
  return n(), r.addEventListener("resize", n), r.addEventListener("scroll", n), () => {
2486
2584
  r.removeEventListener("resize", n), r.removeEventListener("scroll", n), o(0);
2487
2585
  };
2488
2586
  }, [e]), t;
2489
2587
  }
2490
- function An(e) {
2491
- Z(() => {
2588
+ function Dn(e) {
2589
+ F(() => {
2492
2590
  if (!e) return;
2493
2591
  const { body: t } = document, o = window.scrollY, r = {
2494
2592
  position: t.style.position,
@@ -2502,18 +2600,18 @@ function An(e) {
2502
2600
  };
2503
2601
  }, [e]);
2504
2602
  }
2505
- function On() {
2506
- const [e, t] = _(!1), [o, r] = _(null), n = N(null), i = N(null), c = w((u) => {
2507
- const a = (l) => {
2508
- r(l), t(!0), i.current = null, n.current && clearTimeout(n.current), n.current = setTimeout(() => {
2603
+ function $n() {
2604
+ const [e, t] = S(!1), [o, r] = S(null), n = N(null), a = N(null), c = w((u) => {
2605
+ const i = (l) => {
2606
+ r(l), t(!0), a.current = null, n.current && clearTimeout(n.current), n.current = setTimeout(() => {
2509
2607
  n.current = null;
2510
- const d = i.current;
2511
- d && a(d);
2608
+ const d = a.current;
2609
+ d && i(d);
2512
2610
  }, 1e3);
2513
2611
  };
2514
- n.current ? i.current = u : a(u);
2612
+ n.current ? a.current = u : i(u);
2515
2613
  }, []), s = w(() => {
2516
- n.current && (clearTimeout(n.current), n.current = null), i.current = null, t(!1), r(null);
2614
+ n.current && (clearTimeout(n.current), n.current = null), a.current = null, t(!1), r(null);
2517
2615
  }, []);
2518
2616
  return {
2519
2617
  isVisible: e,
@@ -2522,34 +2620,34 @@ function On() {
2522
2620
  hideCognition: s
2523
2621
  };
2524
2622
  }
2525
- function Un({
2623
+ function Bn({
2526
2624
  children: e
2527
2625
  }) {
2528
- const t = On();
2529
- return /* @__PURE__ */ x(Ht.Provider, { value: t, children: e });
2626
+ const t = $n();
2627
+ return /* @__PURE__ */ _(Ft.Provider, { value: t, children: e });
2530
2628
  }
2531
- const jn = ({ children: e }) => {
2532
- const [t, o] = _(null), [r, n] = _(!1), i = Ft(o), a = {
2629
+ const Ln = ({ children: e }) => {
2630
+ const [t, o] = S(null), [r, n] = S(!1), a = Gt(o), i = {
2533
2631
  error: t,
2534
2632
  hideSdk: r,
2535
- publishApiError: i,
2633
+ publishApiError: a,
2536
2634
  publishError: (l) => o(l),
2537
2635
  publishNetworkError: () => n(!0),
2538
2636
  clearError: () => o(null)
2539
2637
  };
2540
- return /* @__PURE__ */ x(Wt.Provider, { value: a, children: e });
2541
- }, Dn = 100;
2542
- function $n({
2638
+ return /* @__PURE__ */ _(Jt.Provider, { value: i, children: e });
2639
+ }, Nn = 100;
2640
+ function Zn({
2543
2641
  appId: e,
2544
2642
  userId: t,
2545
2643
  userName: o,
2546
2644
  userData: r,
2547
2645
  chatProps: n,
2548
- proactiveMessageHideDelay: i = 5e3,
2646
+ proactiveMessageHideDelay: a = 5e3,
2549
2647
  isMobile: c,
2550
2648
  hasCloseButton: s,
2551
2649
  hasCleanChatButton: u,
2552
- isInitiallyOpen: a,
2650
+ isInitiallyOpen: i,
2553
2651
  // Deprecated aliases, resolved in useChat (new name wins).
2554
2652
  closeButton: l,
2555
2653
  cleanChatButton: d,
@@ -2557,67 +2655,67 @@ function $n({
2557
2655
  INTERNAL_ONLY_CHAT_INTERFACE_ONLY: h = !1,
2558
2656
  INTERNAL_ONLY_SHOW_CLEAN_CHAT_BUTTON: f = void 0,
2559
2657
  INTERNAL_ONLY_BLOCK_STYLE: g = !1,
2560
- INTERNAL_ONLY_FEATURE_MESSAGE_CLICK: k = void 0,
2561
- INTERNAL_ONLY_FEATURE_CLEAR_CHAT_CLICK: q = void 0,
2562
- INTERNAL_ONLY_ON_CHAT_ID: I = void 0,
2563
- INTERNAL_ONLY_HIGHLIGHTED_MESSAGE_ID: j = null,
2564
- INTERNAL_ONLY_ON_MESSAGE_SENT: S = void 0,
2565
- INTERNAL_ONLY_SHOW_COPY_BUTTON: $ = !1,
2566
- INTERNAL_ONLY_ENVIRONMENT: R = "live",
2567
- INTERNAL_ONLY_API_URL: m
2658
+ INTERNAL_ONLY_FEATURE_MESSAGE_CLICK: R = void 0,
2659
+ INTERNAL_ONLY_FEATURE_CLEAR_CHAT_CLICK: v = void 0,
2660
+ INTERNAL_ONLY_ON_CHAT_ID: z = void 0,
2661
+ INTERNAL_ONLY_HIGHLIGHTED_MESSAGE_ID: A = null,
2662
+ INTERNAL_ONLY_ON_MESSAGE_SENT: E = void 0,
2663
+ INTERNAL_ONLY_SHOW_COPY_BUTTON: j = !1,
2664
+ INTERNAL_ONLY_ENVIRONMENT: P = "live",
2665
+ INTERNAL_ONLY_API_URL: b
2568
2666
  }) {
2569
- const { hideSdk: y } = De(), {
2570
- isReady: P,
2571
- isChatActive: oe,
2572
- isInitiallyOpen: G,
2573
- hasCloseButton: re,
2574
- hasCleanChatButton: ne,
2575
- isMobile: T,
2576
- chatId: L,
2577
- chatOpen: A,
2578
- unlockSound: K,
2579
- isSoundMuted: X,
2580
- toggleSound: H,
2581
- chatInterfaceProps: W,
2582
- chatOpenDebounced: ae,
2583
- messages: Q,
2584
- portalContainer: ee,
2585
- onSendMessage: fe,
2586
- setChatOpen: b,
2587
- proactiveMessage: v,
2588
- hideProactiveMessage: C,
2589
- isChatClosed: O,
2590
- onStartNewChat: M,
2591
- onRateChat: B
2592
- } = Mn({
2593
- environment: R,
2594
- apiUrl: m,
2667
+ const { hideSdk: q } = Ze(), {
2668
+ isReady: C,
2669
+ isChatActive: te,
2670
+ isInitiallyOpen: Q,
2671
+ hasCloseButton: ne,
2672
+ hasCleanChatButton: ae,
2673
+ isMobile: D,
2674
+ chatId: J,
2675
+ chatOpen: Z,
2676
+ unlockSound: V,
2677
+ isSoundMuted: oe,
2678
+ toggleSound: ce,
2679
+ chatInterfaceProps: G,
2680
+ chatOpenDebounced: ie,
2681
+ messages: Y,
2682
+ portalContainer: ue,
2683
+ onSendMessage: be,
2684
+ setChatOpen: pe,
2685
+ proactiveMessage: re,
2686
+ hideProactiveMessage: he,
2687
+ isChatClosed: m,
2688
+ onStartNewChat: x,
2689
+ onRateChat: O
2690
+ } = Un({
2691
+ environment: P,
2692
+ apiUrl: b,
2595
2693
  appId: e,
2596
2694
  userId: t,
2597
2695
  userName: o,
2598
2696
  userData: r,
2599
2697
  chatProps: n,
2600
2698
  isMobile: c,
2601
- isInitiallyOpen: a,
2699
+ isInitiallyOpen: i,
2602
2700
  hasCloseButton: s,
2603
2701
  hasCleanChatButton: u,
2604
2702
  initialOpen: p,
2605
2703
  closeButton: l,
2606
2704
  cleanChatButton: d,
2607
- proactiveMessageHideDelay: i,
2705
+ proactiveMessageHideDelay: a,
2608
2706
  // Embedded: the interface is the page content with no launcher to reopen
2609
2707
  // it, so nothing (boot initial_open, closed-cookie, props) may close it.
2610
2708
  isAlwaysOpen: h,
2611
2709
  hasCleanChatButtonOverride: f
2612
- }), z = N(void 0);
2613
- Z(() => {
2614
- !I || z.current === L || (z.current = L, I(L));
2615
- }, [L, I]);
2616
- const J = Pn(T && A);
2617
- An(T && A);
2618
- const de = !P;
2619
- if (y || de && !h || !de && !oe) return null;
2620
- const pe = () => /* @__PURE__ */ ze(
2710
+ }), U = N(void 0);
2711
+ F(() => {
2712
+ !z || U.current === J || (U.current = J, z(J));
2713
+ }, [J, z]);
2714
+ const k = jn(D && Z);
2715
+ Dn(D && Z);
2716
+ const y = !C;
2717
+ if (q || y && !h || !y && !te) return null;
2718
+ const B = () => /* @__PURE__ */ Oe(
2621
2719
  "div",
2622
2720
  {
2623
2721
  style: {
@@ -2633,37 +2731,37 @@ function $n({
2633
2731
  ...g ? { position: "relative", inset: 0, width: "100%", height: "100%" } : {}
2634
2732
  },
2635
2733
  children: [
2636
- /* @__PURE__ */ x("style", { children: Qt }),
2637
- /* @__PURE__ */ x(
2638
- Ke,
2734
+ /* @__PURE__ */ _("style", { children: to }),
2735
+ /* @__PURE__ */ _(
2736
+ Je,
2639
2737
  {
2640
2738
  className: "eloquentai-chat-messaging",
2641
- head: /* @__PURE__ */ ze(st, { children: [
2642
- /* @__PURE__ */ x("link", { rel: "preconnect", href: "https://fonts.googleapis.com" }),
2643
- /* @__PURE__ */ x("link", { rel: "preconnect", href: "https://fonts.gstatic.com" }),
2644
- /* @__PURE__ */ x(
2739
+ head: /* @__PURE__ */ Oe(dt, { children: [
2740
+ /* @__PURE__ */ _("link", { rel: "preconnect", href: "https://fonts.googleapis.com" }),
2741
+ /* @__PURE__ */ _("link", { rel: "preconnect", href: "https://fonts.gstatic.com" }),
2742
+ /* @__PURE__ */ _(
2645
2743
  "link",
2646
2744
  {
2647
2745
  href: "https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap",
2648
2746
  rel: "stylesheet"
2649
2747
  }
2650
2748
  ),
2651
- /* @__PURE__ */ x("style", { children: Ze })
2749
+ /* @__PURE__ */ _("style", { children: Fe })
2652
2750
  ] }),
2653
2751
  style: {
2654
- display: A || ae ? "block" : "none",
2655
- width: T ? "100vw" : "400px",
2752
+ display: Z || ie ? "block" : "none",
2753
+ width: D ? "100vw" : "400px",
2656
2754
  // 100dvh accounts for mobile browser chrome (e.g. address bar); 100vh fallback for older browsers
2657
2755
  "--chat-mobile-viewport-height": "100dvh",
2658
- height: T ? "var(--chat-mobile-viewport-height, 100vh)" : "700px",
2659
- maxHeight: T ? "var(--chat-mobile-viewport-height, 100vh)" : `calc(100% - ${Dn}px)`,
2756
+ height: D ? "var(--chat-mobile-viewport-height, 100vh)" : "700px",
2757
+ maxHeight: D ? "var(--chat-mobile-viewport-height, 100vh)" : `calc(100% - ${Nn}px)`,
2660
2758
  border: "none",
2661
2759
  zIndex: 2147483e3,
2662
2760
  position: "fixed",
2663
- top: T ? 0 : void 0,
2664
- left: T ? 0 : void 0,
2665
- right: T ? 0 : 16,
2666
- bottom: T ? 0 : 16,
2761
+ top: D ? 0 : void 0,
2762
+ left: D ? 0 : void 0,
2763
+ right: D ? 0 : 16,
2764
+ bottom: D ? 0 : 16,
2667
2765
  ...g ? {
2668
2766
  position: "relative",
2669
2767
  top: 0,
@@ -2676,46 +2774,46 @@ function $n({
2676
2774
  zIndex: 0
2677
2775
  } : {}
2678
2776
  },
2679
- children: de ? (
2777
+ children: y ? (
2680
2778
  // Only reachable in embedded mode (the launcher returns null while
2681
2779
  // booting): hold the widget's frame with a skeleton so a remount —
2682
2780
  // project/environment switch in the host app — doesn't flash an
2683
2781
  // empty hole where the chat was.
2684
- /* @__PURE__ */ x(Jt, { isOpen: !0, isMobile: T, skipAnimation: !0 })
2685
- ) : /* @__PURE__ */ x(
2686
- Gt,
2782
+ /* @__PURE__ */ _(Yt, { isOpen: !0, isMobile: D, skipAnimation: !0 })
2783
+ ) : /* @__PURE__ */ _(
2784
+ Xt,
2687
2785
  {
2688
- ...W,
2786
+ ...G,
2689
2787
  hasIntroAnimation: !h,
2690
- isTestMode: R === "test",
2691
- isOpen: A,
2692
- keyboardInset: J,
2693
- messages: Q,
2694
- onSendMessage: (me, D) => (K(), S?.(me), fe(me, D)),
2695
- onMessageClick: k,
2696
- highlightedMessageId: j,
2697
- isMobile: T,
2698
- hasCloseButton: re,
2699
- hasCleanChatButton: ne,
2700
- hasCopyButton: $,
2701
- isChatClosed: O,
2702
- onStartNewChat: M,
2703
- onRateChat: B,
2704
- isSoundMuted: X,
2705
- onToggleSound: H,
2706
- onClose: () => b(!1),
2788
+ isTestMode: P === "test",
2789
+ isOpen: Z,
2790
+ keyboardInset: k,
2791
+ messages: Y,
2792
+ onSendMessage: (K, se) => (V(), E?.(K), be(K, se)),
2793
+ onMessageClick: R,
2794
+ highlightedMessageId: A,
2795
+ isMobile: D,
2796
+ hasCloseButton: ne,
2797
+ hasCleanChatButton: ae,
2798
+ hasCopyButton: j,
2799
+ isChatClosed: m,
2800
+ onStartNewChat: x,
2801
+ onRateChat: O,
2802
+ isSoundMuted: oe,
2803
+ onToggleSound: ce,
2804
+ onClose: () => pe(!1),
2707
2805
  onCleanChat: () => {
2708
- M(), q?.();
2806
+ x(), v?.();
2709
2807
  }
2710
2808
  }
2711
2809
  )
2712
2810
  }
2713
2811
  ),
2714
- !h && /* @__PURE__ */ x(
2715
- Ke,
2812
+ !h && /* @__PURE__ */ _(
2813
+ Je,
2716
2814
  {
2717
2815
  className: "eloquentai-chat-launcher",
2718
- head: /* @__PURE__ */ x("style", { children: Ze }),
2816
+ head: /* @__PURE__ */ _("style", { children: Fe }),
2719
2817
  style: {
2720
2818
  position: "fixed",
2721
2819
  bottom: 17,
@@ -2724,26 +2822,26 @@ function $n({
2724
2822
  width: 48,
2725
2823
  height: 48,
2726
2824
  border: "none",
2727
- zIndex: T ? 2147482999 : 2147483e3,
2728
- opacity: A ? 0 : 1,
2729
- pointerEvents: A ? "none" : "auto",
2730
- transition: A ? "opacity 100ms ease-in" : "opacity 200ms ease-out 320ms"
2825
+ zIndex: D ? 2147482999 : 2147483e3,
2826
+ opacity: Z ? 0 : 1,
2827
+ pointerEvents: Z ? "none" : "auto",
2828
+ transition: Z ? "opacity 100ms ease-in" : "opacity 200ms ease-out 320ms"
2731
2829
  },
2732
- children: /* @__PURE__ */ x(
2733
- eo,
2830
+ children: /* @__PURE__ */ _(
2831
+ oo,
2734
2832
  {
2735
- isOpen: A,
2736
- toggleBubble: () => b((me) => !me),
2737
- isDarkMode: W?.theme?.mode === "dark"
2833
+ isOpen: Z,
2834
+ toggleBubble: () => pe((K) => !K),
2835
+ isDarkMode: G?.theme?.mode === "dark"
2738
2836
  }
2739
2837
  )
2740
2838
  }
2741
2839
  ),
2742
- W?.displayWelcomeMessages ? /* @__PURE__ */ x(
2743
- Ke,
2840
+ G?.displayWelcomeMessages ? /* @__PURE__ */ _(
2841
+ Je,
2744
2842
  {
2745
2843
  className: "eloquentai-chat-proactive-message",
2746
- head: /* @__PURE__ */ x("style", { children: Ze }),
2844
+ head: /* @__PURE__ */ _("style", { children: Fe }),
2747
2845
  style: {
2748
2846
  position: "fixed",
2749
2847
  // Aligns the bubble's tail with the launcher's center: the
@@ -2752,22 +2850,22 @@ function $n({
2752
2850
  bottom: 24,
2753
2851
  right: 17
2754
2852
  },
2755
- children: /* @__PURE__ */ x(Yt, { ...W?.theme ?? {}, children: /* @__PURE__ */ x(
2853
+ children: /* @__PURE__ */ _(Qt, { ...G?.theme ?? {}, children: /* @__PURE__ */ _(
2756
2854
  "div",
2757
2855
  {
2758
- className: Qe("eloq:w-full eloq:h-full", {
2759
- dark: W?.theme?.mode === "dark"
2856
+ className: nt("eloq:w-full eloq:h-full", {
2857
+ dark: G?.theme?.mode === "dark"
2760
2858
  }),
2761
- children: v && !G && /* @__PURE__ */ x(
2762
- oo,
2859
+ children: re && !Q && /* @__PURE__ */ _(
2860
+ no,
2763
2861
  {
2764
- message: v.text,
2765
- isVisible: v.isVisible,
2766
- onDismiss: C,
2862
+ message: re.text,
2863
+ isVisible: re.isVisible,
2864
+ onDismiss: he,
2767
2865
  onMessageClick: () => {
2768
- b(!0), C();
2866
+ pe(!0), he();
2769
2867
  },
2770
- autoHideDelay: v.autoHideDelay
2868
+ autoHideDelay: re.autoHideDelay
2771
2869
  }
2772
2870
  )
2773
2871
  }
@@ -2777,21 +2875,21 @@ function $n({
2777
2875
  ]
2778
2876
  }
2779
2877
  );
2780
- return /* @__PURE__ */ x(st, { children: g ? pe() : ee ? /* @__PURE__ */ x(to, { container: ee, children: pe() }) : null });
2878
+ return /* @__PURE__ */ _(dt, { children: g ? B() : ue ? /* @__PURE__ */ _(ro, { container: ue, children: B() }) : null });
2781
2879
  }
2782
- function Bn(e) {
2783
- return /* @__PURE__ */ x(jn, { children: /* @__PURE__ */ x(Un, { children: /* @__PURE__ */ x($n, { ...e }) }) });
2880
+ function Kn(e) {
2881
+ return /* @__PURE__ */ _(Ln, { children: /* @__PURE__ */ _(Bn, { children: /* @__PURE__ */ _(Zn, { ...e }) }) });
2784
2882
  }
2785
- function Hn(e, t) {
2786
- return ((r, n, i) => {
2787
- const c = Xt.createRoot(n);
2788
- return c.render(/* @__PURE__ */ x(r, { ...i })), c.unmount;
2789
- })(Bn, e, t);
2883
+ function Gn(e, t) {
2884
+ return ((r, n, a) => {
2885
+ const c = eo.createRoot(n);
2886
+ return c.render(/* @__PURE__ */ _(r, { ...a })), c.unmount;
2887
+ })(Kn, e, t);
2790
2888
  }
2791
2889
  export {
2792
- Bn as Chat,
2793
- Gt as ChatInterface,
2794
- Hn as renderChat,
2795
- Fr as useRealtimeSocket
2890
+ Kn as Chat,
2891
+ Xt as ChatInterface,
2892
+ Gn as renderChat,
2893
+ Xr as useRealtimeSocket
2796
2894
  };
2797
2895
  //# sourceMappingURL=index.mjs.map