@burtson-labs/bandit-engine 2.0.89 → 2.0.90

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.
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-ONQMRE2G.mjs";
4
4
  import {
5
5
  StreamingMarkdown_default
6
- } from "./chunk-OB2W4OR4.mjs";
6
+ } from "./chunk-RUMVTVNM.mjs";
7
7
  import {
8
8
  useMCPToolsStore
9
9
  } from "./chunk-L2EKYO4F.mjs";
@@ -40,10 +40,11 @@ import {
40
40
  sanitizeForTTS,
41
41
  stopTTS,
42
42
  themeMap_default,
43
+ useCanvasStore,
43
44
  useNotificationService,
44
45
  useTTS,
45
46
  useVoiceStore
46
- } from "./chunk-4VTF3MY4.mjs";
47
+ } from "./chunk-IVLVUNIB.mjs";
47
48
  import {
48
49
  authenticationService,
49
50
  brandingService_default,
@@ -85,7 +86,7 @@ import {
85
86
  } from "./chunk-KCI46M23.mjs";
86
87
 
87
88
  // src/chat/chat.tsx
88
- import { useCallback as useCallback6, useEffect as useEffect15, useLayoutEffect, useMemo as useMemo4, useRef as useRef13, useState as useState16 } from "react";
89
+ import { useCallback as useCallback6, useEffect as useEffect15, useLayoutEffect, useMemo as useMemo4, useRef as useRef13, useState as useState17 } from "react";
89
90
 
90
91
  // src/chat/custom-logo.tsx
91
92
  import React, { useEffect } from "react";
@@ -172,13 +173,165 @@ var Logo = ({ visible, atTop = false }) => {
172
173
  var custom_logo_default = Logo;
173
174
 
174
175
  // src/chat/chat.tsx
175
- import { Box as Box16, ThemeProvider, CssBaseline, CircularProgress as CircularProgress4, Typography as Typography11 } from "@mui/material";
176
+ import { Box as Box17, ThemeProvider, CssBaseline, CircularProgress as CircularProgress4, Typography as Typography11 } from "@mui/material";
176
177
  import { createTheme } from "@mui/material/styles";
178
+
179
+ // src/chat/canvas-panel.tsx
180
+ import { useState } from "react";
181
+ import { Box as Box2, Dialog, IconButton, Tab, Tabs, TextField, Tooltip } from "@mui/material";
182
+ import {
183
+ X as CloseIcon2,
184
+ Copy as CopyIcon,
185
+ Check as CheckIcon2,
186
+ Download as DownloadIcon,
187
+ Eye as PreviewIcon,
188
+ Pencil as EditIcon
189
+ } from "lucide-react";
190
+ import { jsx as jsx2, jsxs } from "react/jsx-runtime";
191
+ var CANVAS_WIDTH = "min(46vw, 760px)";
192
+ var CanvasBody = () => {
193
+ const { content, title, language, setContent, setTitle, close } = useCanvasStore();
194
+ const [tab, setTab] = useState("edit");
195
+ const [copied, setCopied] = useState(false);
196
+ const copy = async () => {
197
+ try {
198
+ await navigator.clipboard.writeText(content);
199
+ setCopied(true);
200
+ setTimeout(() => setCopied(false), 1500);
201
+ } catch {
202
+ }
203
+ };
204
+ const download = () => {
205
+ const safe = (title || "canvas").replace(/[^\w.-]+/g, "_") || "canvas";
206
+ const ext = language ? language : "md";
207
+ const blob = new Blob([content], { type: "text/plain;charset=utf-8" });
208
+ const url = URL.createObjectURL(blob);
209
+ const a = document.createElement("a");
210
+ a.href = url;
211
+ a.download = `${safe}.${ext}`;
212
+ a.click();
213
+ URL.revokeObjectURL(url);
214
+ };
215
+ return /* @__PURE__ */ jsxs(Box2, { sx: { display: "flex", flexDirection: "column", height: "100%", bgcolor: "background.paper" }, children: [
216
+ /* @__PURE__ */ jsxs(
217
+ Box2,
218
+ {
219
+ sx: {
220
+ display: "flex",
221
+ alignItems: "center",
222
+ gap: 0.5,
223
+ px: 1.5,
224
+ py: 1,
225
+ borderBottom: "1px solid",
226
+ borderColor: "divider",
227
+ flexShrink: 0
228
+ },
229
+ children: [
230
+ /* @__PURE__ */ jsx2(
231
+ TextField,
232
+ {
233
+ value: title,
234
+ onChange: (e) => setTitle(e.target.value),
235
+ variant: "standard",
236
+ placeholder: "Untitled",
237
+ InputProps: { disableUnderline: true, sx: { fontWeight: 700, fontSize: 15 } },
238
+ sx: { flex: 1, minWidth: 0 }
239
+ }
240
+ ),
241
+ /* @__PURE__ */ jsx2(Tooltip, { title: copied ? "Copied" : "Copy", arrow: true, children: /* @__PURE__ */ jsx2(IconButton, { size: "small", onClick: copy, "aria-label": "Copy canvas", children: copied ? /* @__PURE__ */ jsx2(CheckIcon2, { size: 16 }) : /* @__PURE__ */ jsx2(CopyIcon, { size: 16 }) }) }),
242
+ /* @__PURE__ */ jsx2(Tooltip, { title: `Download .${language || "md"}`, arrow: true, children: /* @__PURE__ */ jsx2(IconButton, { size: "small", onClick: download, "aria-label": "Download canvas", children: /* @__PURE__ */ jsx2(DownloadIcon, { size: 16 }) }) }),
243
+ /* @__PURE__ */ jsx2(Tooltip, { title: "Close canvas", arrow: true, children: /* @__PURE__ */ jsx2(IconButton, { size: "small", onClick: close, "aria-label": "Close canvas", children: /* @__PURE__ */ jsx2(CloseIcon2, { size: 18 }) }) })
244
+ ]
245
+ }
246
+ ),
247
+ /* @__PURE__ */ jsxs(
248
+ Tabs,
249
+ {
250
+ value: tab,
251
+ onChange: (_, v) => setTab(v),
252
+ variant: "fullWidth",
253
+ sx: {
254
+ minHeight: 40,
255
+ borderBottom: "1px solid",
256
+ borderColor: "divider",
257
+ flexShrink: 0,
258
+ "& .MuiTab-root": { minHeight: 40, textTransform: "none", fontWeight: 600 }
259
+ },
260
+ children: [
261
+ /* @__PURE__ */ jsx2(Tab, { value: "edit", label: "Edit", icon: /* @__PURE__ */ jsx2(EditIcon, { size: 14 }), iconPosition: "start" }),
262
+ /* @__PURE__ */ jsx2(Tab, { value: "preview", label: "Preview", icon: /* @__PURE__ */ jsx2(PreviewIcon, { size: 14 }), iconPosition: "start" })
263
+ ]
264
+ }
265
+ ),
266
+ /* @__PURE__ */ jsx2(Box2, { sx: { flex: 1, overflow: "auto", minHeight: 0 }, children: tab === "edit" ? /* @__PURE__ */ jsx2(
267
+ Box2,
268
+ {
269
+ component: "textarea",
270
+ value: content,
271
+ onChange: (e) => setContent(e.target.value),
272
+ spellCheck: false,
273
+ placeholder: "Write or edit here\u2026",
274
+ sx: {
275
+ width: "100%",
276
+ height: "100%",
277
+ boxSizing: "border-box",
278
+ border: 0,
279
+ outline: 0,
280
+ resize: "none",
281
+ p: 2,
282
+ bgcolor: "transparent",
283
+ color: "text.primary",
284
+ fontFamily: language ? "ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" : "inherit",
285
+ fontSize: 14,
286
+ lineHeight: 1.6
287
+ }
288
+ }
289
+ ) : /* @__PURE__ */ jsx2(Box2, { sx: { p: 2 }, children: /* @__PURE__ */ jsx2(StreamingMarkdown_default, { content, isStreaming: false }) }) })
290
+ ] });
291
+ };
292
+ var CanvasPanel = ({ isMobile }) => {
293
+ const open = useCanvasStore((s) => s.open);
294
+ const close = useCanvasStore((s) => s.close);
295
+ if (!open) return null;
296
+ if (isMobile) {
297
+ return /* @__PURE__ */ jsx2(
298
+ Dialog,
299
+ {
300
+ fullScreen: true,
301
+ open,
302
+ onClose: close,
303
+ slotProps: { paper: { sx: { bgcolor: "background.paper" } } },
304
+ children: /* @__PURE__ */ jsx2(CanvasBody, {})
305
+ }
306
+ );
307
+ }
308
+ return /* @__PURE__ */ jsx2(
309
+ Box2,
310
+ {
311
+ sx: (theme) => ({
312
+ position: "fixed",
313
+ top: 0,
314
+ right: 0,
315
+ bottom: 0,
316
+ width: CANVAS_WIDTH,
317
+ zIndex: 1,
318
+ borderLeft: "1px solid",
319
+ borderColor: "divider",
320
+ boxShadow: "-8px 0 28px rgba(0,0,0,0.22)",
321
+ bgcolor: theme.palette.background.paper
322
+ }),
323
+ children: /* @__PURE__ */ jsx2(CanvasBody, {})
324
+ }
325
+ );
326
+ };
327
+ var canvas_panel_default = CanvasPanel;
328
+
329
+ // src/chat/chat.tsx
177
330
  import { Navigate } from "react-router-dom";
178
331
 
179
332
  // src/chat/chat-scroll-to-bottom-button.tsx
180
- import { IconButton } from "@mui/material";
181
- import { jsx as jsx2 } from "react/jsx-runtime";
333
+ import { IconButton as IconButton2 } from "@mui/material";
334
+ import { jsx as jsx3 } from "react/jsx-runtime";
182
335
  var ChatScrollToBottomButton = ({
183
336
  inputHeight,
184
337
  onClick,
@@ -187,8 +340,8 @@ var ChatScrollToBottomButton = ({
187
340
  }) => {
188
341
  const verticalBuffer = isMobile ? 44 : 80;
189
342
  const bottomOffset = Math.max(inputHeight + verticalBuffer, verticalBuffer + 72);
190
- return /* @__PURE__ */ jsx2(
191
- IconButton,
343
+ return /* @__PURE__ */ jsx3(
344
+ IconButton2,
192
345
  {
193
346
  onClick,
194
347
  sx: {
@@ -210,22 +363,22 @@ var ChatScrollToBottomButton = ({
210
363
  transform: "translateX(-50%) translateY(1px)"
211
364
  }
212
365
  },
213
- children: /* @__PURE__ */ jsx2(ArrowDownwardIcon, { sx: { color: "inherit" } })
366
+ children: /* @__PURE__ */ jsx3(ArrowDownwardIcon, { sx: { color: "inherit" } })
214
367
  }
215
368
  );
216
369
  };
217
370
  var chat_scroll_to_bottom_button_default = ChatScrollToBottomButton;
218
371
 
219
372
  // src/chat/bandit-chat-logo.tsx
220
- import { useEffect as useEffect2, useState } from "react";
373
+ import { useEffect as useEffect2, useState as useState2 } from "react";
221
374
  import { useTheme as useTheme2 } from "@mui/material/styles";
222
- import { jsx as jsx3 } from "react/jsx-runtime";
375
+ import { jsx as jsx4 } from "react/jsx-runtime";
223
376
  var darkLogo = "https://cdn.burtson.ai/logos/bandit-ai-logo-simple.png";
224
377
  var lightLogo = "https://cdn.burtson.ai/logos/bandit-ai-logo-simple-alt.png";
225
378
  var BanditChatLogo = ({ atTop = false, visible = false }) => {
226
379
  const theme = useTheme2();
227
380
  const logoUrl = theme.palette.mode === "light" ? lightLogo : darkLogo;
228
- const [isVisible, setIsVisible] = useState(false);
381
+ const [isVisible, setIsVisible] = useState2(false);
229
382
  useEffect2(() => {
230
383
  if (visible) {
231
384
  const timeout = setTimeout(() => setIsVisible(true), 50);
@@ -235,7 +388,7 @@ var BanditChatLogo = ({ atTop = false, visible = false }) => {
235
388
  }, [visible]);
236
389
  const backgroundStyle = { backgroundImage: `url(${logoUrl})` };
237
390
  const className = `bandit-logo ${isVisible ? "bandit-logo-visible" : "bandit-logo-hidden"}`;
238
- return /* @__PURE__ */ jsx3("div", { className: "bandit-logo-container", style: atTop ? { alignItems: "flex-start" } : void 0, children: /* @__PURE__ */ jsx3(
391
+ return /* @__PURE__ */ jsx4("div", { className: "bandit-logo-container", style: atTop ? { alignItems: "flex-start" } : void 0, children: /* @__PURE__ */ jsx4(
239
392
  "div",
240
393
  {
241
394
  className,
@@ -249,12 +402,12 @@ var BanditChatLogo = ({ atTop = false, visible = false }) => {
249
402
  var bandit_chat_logo_default = BanditChatLogo;
250
403
 
251
404
  // src/chat/chat-messages.tsx
252
- import { Box as Box3 } from "@mui/material";
405
+ import { Box as Box4 } from "@mui/material";
253
406
 
254
407
  // src/chat/source-chips.tsx
255
- import { useMemo, useState as useState2 } from "react";
256
- import { Box as Box2, Tooltip } from "@mui/material";
257
- import { jsx as jsx4, jsxs } from "react/jsx-runtime";
408
+ import { useMemo, useState as useState3 } from "react";
409
+ import { Box as Box3, Tooltip as Tooltip2 } from "@mui/material";
410
+ import { jsx as jsx5, jsxs as jsxs2 } from "react/jsx-runtime";
258
411
  var parseWebSources = (content) => {
259
412
  if (!content) return [];
260
413
  const idx = content.lastIndexOf("**Sources**");
@@ -291,11 +444,11 @@ var domainOf = (url) => {
291
444
  }
292
445
  };
293
446
  var SourceChip = ({ source }) => {
294
- const [failed, setFailed] = useState2(false);
447
+ const [failed, setFailed] = useState3(false);
295
448
  const domain = domainOf(source.url);
296
449
  const label = source.title?.trim() || domain;
297
- return /* @__PURE__ */ jsx4(Tooltip, { title: `${label} \xB7 ${domain}`, arrow: true, children: /* @__PURE__ */ jsxs(
298
- Box2,
450
+ return /* @__PURE__ */ jsx5(Tooltip2, { title: `${label} \xB7 ${domain}`, arrow: true, children: /* @__PURE__ */ jsxs2(
451
+ Box3,
299
452
  {
300
453
  component: "a",
301
454
  href: source.url,
@@ -320,8 +473,8 @@ var SourceChip = ({ source }) => {
320
473
  "&:hover": { borderColor: "primary.main", bgcolor: "action.selected" }
321
474
  },
322
475
  children: [
323
- failed ? /* @__PURE__ */ jsx4(
324
- Box2,
476
+ failed ? /* @__PURE__ */ jsx5(
477
+ Box3,
325
478
  {
326
479
  sx: {
327
480
  width: 16,
@@ -337,8 +490,8 @@ var SourceChip = ({ source }) => {
337
490
  },
338
491
  children: domain.charAt(0).toUpperCase()
339
492
  }
340
- ) : /* @__PURE__ */ jsx4(
341
- Box2,
493
+ ) : /* @__PURE__ */ jsx5(
494
+ Box3,
342
495
  {
343
496
  component: "img",
344
497
  src: `https://icons.duckduckgo.com/ip3/${domain}.ico`,
@@ -348,8 +501,8 @@ var SourceChip = ({ source }) => {
348
501
  sx: { width: 16, height: 16, borderRadius: "4px", flexShrink: 0 }
349
502
  }
350
503
  ),
351
- /* @__PURE__ */ jsx4(
352
- Box2,
504
+ /* @__PURE__ */ jsx5(
505
+ Box3,
353
506
  {
354
507
  component: "span",
355
508
  sx: { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" },
@@ -363,19 +516,19 @@ var SourceChip = ({ source }) => {
363
516
  var SourceChips = ({ content }) => {
364
517
  const sources = useMemo(() => parseWebSources(content), [content]);
365
518
  if (sources.length === 0) return null;
366
- return /* @__PURE__ */ jsx4(
367
- Box2,
519
+ return /* @__PURE__ */ jsx5(
520
+ Box3,
368
521
  {
369
522
  sx: { display: "flex", flexWrap: "wrap", gap: 0.75, mt: 1.5 },
370
523
  "aria-label": "Sources",
371
- children: sources.map((s, i) => /* @__PURE__ */ jsx4(SourceChip, { source: s }, `${s.url}-${i}`))
524
+ children: sources.map((s, i) => /* @__PURE__ */ jsx5(SourceChip, { source: s }, `${s.url}-${i}`))
372
525
  }
373
526
  );
374
527
  };
375
528
  var source_chips_default = SourceChips;
376
529
 
377
530
  // src/chat/chat-messages.tsx
378
- import { jsx as jsx5, jsxs as jsxs2 } from "react/jsx-runtime";
531
+ import { jsx as jsx6, jsxs as jsxs3 } from "react/jsx-runtime";
379
532
  var ChatMessages = ({
380
533
  pendingMessage,
381
534
  streamBuffer,
@@ -395,7 +548,7 @@ var ChatMessages = ({
395
548
  const lastIndex = history.length - 1;
396
549
  const hasActivePlaceholder = lastIndex >= 0 && history[lastIndex]?.answer === "...";
397
550
  if (!responseStarted && !pendingMessage && history.length === 0) return null;
398
- return /* @__PURE__ */ jsxs2(Box3, { sx: { px: isMobile ? 0 : 0, pt: "100px", display: "flex", flexDirection: "column", gap: 2 }, children: [
551
+ return /* @__PURE__ */ jsxs3(Box4, { sx: { px: isMobile ? 0 : 0, pt: "100px", display: "flex", flexDirection: "column", gap: 2 }, children: [
399
552
  history.map((entry, index) => {
400
553
  const isLast = index === lastIndex;
401
554
  const isPlaceholder = entry.answer === "...";
@@ -404,8 +557,8 @@ var ChatMessages = ({
404
557
  const content = isLast ? isStreaming ? streamBuffer || "" : isPlaceholder ? "" : entry.answer : entry.answer;
405
558
  const rawSources = entry.sourceFiles;
406
559
  const sourceSummaries = rawSources ? rawSources.filter((doc) => doc && typeof doc.name === "string" && doc.name.trim()).map((doc) => ({ id: doc.id || doc.name, name: doc.name.trim() })) : void 0;
407
- const responseNode = /* @__PURE__ */ jsxs2(
408
- Box3,
560
+ const responseNode = /* @__PURE__ */ jsxs3(
561
+ Box4,
409
562
  {
410
563
  sx: {
411
564
  minHeight: isLast ? isMobile ? "80px" : "60px" : void 0,
@@ -414,8 +567,8 @@ var ChatMessages = ({
414
567
  transition: "min-height 0.25s cubic-bezier(0.4, 0, 0.2, 1)"
415
568
  },
416
569
  children: [
417
- /* @__PURE__ */ jsx5(
418
- Box3,
570
+ /* @__PURE__ */ jsx6(
571
+ Box4,
419
572
  {
420
573
  sx: {
421
574
  position: showLoader ? "static" : "absolute",
@@ -428,14 +581,14 @@ var ChatMessages = ({
428
581
  pointerEvents: showLoader ? "auto" : "none",
429
582
  zIndex: showLoader ? 1 : 0
430
583
  },
431
- children: /* @__PURE__ */ jsxs2(Box3, { sx: { display: "flex", alignItems: "center", gap: 1, minHeight: "40px", pl: 2 }, children: [
432
- /* @__PURE__ */ jsxs2("div", { className: "typing-only", children: [
433
- /* @__PURE__ */ jsx5("span", { className: "dot" }),
434
- /* @__PURE__ */ jsx5("span", { className: "dot" }),
435
- /* @__PURE__ */ jsx5("span", { className: "dot" })
584
+ children: /* @__PURE__ */ jsxs3(Box4, { sx: { display: "flex", alignItems: "center", gap: 1, minHeight: "40px", pl: 2 }, children: [
585
+ /* @__PURE__ */ jsxs3("div", { className: "typing-only", children: [
586
+ /* @__PURE__ */ jsx6("span", { className: "dot" }),
587
+ /* @__PURE__ */ jsx6("span", { className: "dot" }),
588
+ /* @__PURE__ */ jsx6("span", { className: "dot" })
436
589
  ] }),
437
- showThinking && /* @__PURE__ */ jsx5(
438
- Box3,
590
+ showThinking && /* @__PURE__ */ jsx6(
591
+ Box4,
439
592
  {
440
593
  component: "span",
441
594
  sx: {
@@ -451,8 +604,8 @@ var ChatMessages = ({
451
604
  ] })
452
605
  }
453
606
  ),
454
- /* @__PURE__ */ jsxs2(
455
- Box3,
607
+ /* @__PURE__ */ jsxs3(
608
+ Box4,
456
609
  {
457
610
  sx: {
458
611
  position: showLoader ? "absolute" : "static",
@@ -466,7 +619,7 @@ var ChatMessages = ({
466
619
  zIndex: 1
467
620
  },
468
621
  children: [
469
- /* @__PURE__ */ jsx5(
622
+ /* @__PURE__ */ jsx6(
470
623
  StreamingMarkdown_default,
471
624
  {
472
625
  content: isStreaming && isLast ? content : stripSourcesForDisplay(content),
@@ -474,14 +627,14 @@ var ChatMessages = ({
474
627
  sources: sourceSummaries
475
628
  }
476
629
  ),
477
- /* @__PURE__ */ jsx5(source_chips_default, { content })
630
+ /* @__PURE__ */ jsx6(source_chips_default, { content })
478
631
  ]
479
632
  }
480
633
  )
481
634
  ]
482
635
  }
483
636
  );
484
- return /* @__PURE__ */ jsx5(Box3, { children: /* @__PURE__ */ jsx5(
637
+ return /* @__PURE__ */ jsx6(Box4, { children: /* @__PURE__ */ jsx6(
485
638
  ai_response_text_field_default,
486
639
  {
487
640
  question: entry.question,
@@ -496,17 +649,17 @@ var ChatMessages = ({
496
649
  }
497
650
  ) }, index);
498
651
  }),
499
- /* @__PURE__ */ jsx5("div", { style: { height: "1px" }, ref: scrollTargetRef })
652
+ /* @__PURE__ */ jsx6("div", { style: { height: "1px" }, ref: scrollTargetRef })
500
653
  ] });
501
654
  };
502
655
  var chat_messages_default = ChatMessages;
503
656
 
504
657
  // src/chat/chat-input.tsx
505
- import { useEffect as useEffect3, useRef as useRef2, useState as useState4 } from "react";
506
- import { Box as Box4, TextField, IconButton as IconButton3, Tooltip as Tooltip2, Avatar as Avatar2, Typography, CircularProgress as CircularProgress2, Collapse } from "@mui/material";
658
+ import { useEffect as useEffect3, useRef as useRef2, useState as useState5 } from "react";
659
+ import { Box as Box5, TextField as TextField2, IconButton as IconButton4, Tooltip as Tooltip3, Avatar as Avatar2, Typography, CircularProgress as CircularProgress2, Collapse } from "@mui/material";
507
660
 
508
661
  // src/services/stt/transcriber.tsx
509
- import { useState as useState3, useRef } from "react";
662
+ import { useState as useState4, useRef } from "react";
510
663
 
511
664
  // src/services/stt/sound-recorder.service.ts
512
665
  import { first, from, fromEvent, map, shareReplay, switchMap } from "rxjs";
@@ -650,9 +803,9 @@ var STTClient = class {
650
803
  };
651
804
 
652
805
  // src/services/stt/transcriber.tsx
653
- import { CircularProgress, IconButton as IconButton2, useTheme as useTheme3 } from "@mui/material";
806
+ import { CircularProgress, IconButton as IconButton3, useTheme as useTheme3 } from "@mui/material";
654
807
  import { from as from2, Subscription, switchMap as switchMap2 } from "rxjs";
655
- import { Fragment as Fragment2, jsx as jsx6, jsxs as jsxs3 } from "react/jsx-runtime";
808
+ import { Fragment as Fragment2, jsx as jsx7, jsxs as jsxs4 } from "react/jsx-runtime";
656
809
  var initialButtonStyles = (badgeBackground, fileText, hoverBadgeBackground) => ({
657
810
  bgcolor: badgeBackground,
658
811
  color: fileText,
@@ -666,10 +819,10 @@ var Transcriber = ({ onTranscriptionCompleted }) => {
666
819
  const badgeBackground = theme.palette.chat.badge;
667
820
  const fileText = theme.palette.chat.fileText;
668
821
  const hoverBadgeBackground = theme.palette.chat.badgeHover;
669
- const [status, setStatus] = useState3("IDLE");
822
+ const [status, setStatus] = useState4("IDLE");
670
823
  const recorderRef = useRef(new SoundRecorderService());
671
- const [iconButtonStyles] = useState3(() => initialButtonStyles(badgeBackground, fileText, hoverBadgeBackground));
672
- const [recordingSub, setRecordingSub] = useState3(() => new Subscription());
824
+ const [iconButtonStyles] = useState4(() => initialButtonStyles(badgeBackground, fileText, hoverBadgeBackground));
825
+ const [recordingSub, setRecordingSub] = useState4(() => new Subscription());
673
826
  const start = () => {
674
827
  recordingSub.unsubscribe();
675
828
  const recording = recorderRef.current.start();
@@ -700,7 +853,7 @@ var Transcriber = ({ onTranscriptionCompleted }) => {
700
853
  setStatus("LOADING");
701
854
  stop();
702
855
  };
703
- return /* @__PURE__ */ jsx6(
856
+ return /* @__PURE__ */ jsx7(
704
857
  "div",
705
858
  {
706
859
  style: {
@@ -710,27 +863,27 @@ var Transcriber = ({ onTranscriptionCompleted }) => {
710
863
  backgroundColor: status === "RECORDING" ? "rgba(0,0,0,.3)" : "rgba(0,0,0,0)",
711
864
  borderRadius: "50px"
712
865
  },
713
- children: status === "IDLE" ? /* @__PURE__ */ jsx6(IconButton2, { sx: { ...iconButtonStyles }, onClick: handleRecordClick, children: /* @__PURE__ */ jsx6(MicIcon, { sx: { color: "#aaa", cursor: "pointer" } }) }) : status === "RECORDING" ? /* @__PURE__ */ jsxs3(Fragment2, { children: [
714
- /* @__PURE__ */ jsx6(
715
- IconButton2,
866
+ children: status === "IDLE" ? /* @__PURE__ */ jsx7(IconButton3, { sx: { ...iconButtonStyles }, onClick: handleRecordClick, children: /* @__PURE__ */ jsx7(MicIcon, { sx: { color: "#aaa", cursor: "pointer" } }) }) : status === "RECORDING" ? /* @__PURE__ */ jsxs4(Fragment2, { children: [
867
+ /* @__PURE__ */ jsx7(
868
+ IconButton3,
716
869
  {
717
870
  onClick: handleCancelClick,
718
871
  sx: { ...iconButtonStyles, marginRight: 1 },
719
- children: /* @__PURE__ */ jsx6(CloseIcon, {})
872
+ children: /* @__PURE__ */ jsx7(CloseIcon, {})
720
873
  }
721
874
  ),
722
- /* @__PURE__ */ jsx6(
723
- IconButton2,
875
+ /* @__PURE__ */ jsx7(
876
+ IconButton3,
724
877
  {
725
878
  sx: {
726
879
  ...iconButtonStyles,
727
880
  filter: "invert(110%)"
728
881
  },
729
882
  onClick: handleSubmitClick,
730
- children: /* @__PURE__ */ jsx6(CheckIcon, {})
883
+ children: /* @__PURE__ */ jsx7(CheckIcon, {})
731
884
  }
732
885
  )
733
- ] }) : status === "LOADING" ? /* @__PURE__ */ jsx6(IconButton2, { sx: { ...iconButtonStyles }, children: /* @__PURE__ */ jsx6(CircularProgress, { size: 20 }) }) : null
886
+ ] }) : status === "LOADING" ? /* @__PURE__ */ jsx7(IconButton3, { sx: { ...iconButtonStyles }, children: /* @__PURE__ */ jsx7(CircularProgress, { size: 20 }) }) : null
734
887
  }
735
888
  );
736
889
  };
@@ -776,7 +929,7 @@ var useVoiceModeStore = create((set) => ({
776
929
 
777
930
  // src/chat/chat-input.tsx
778
931
  import { shallow } from "zustand/shallow";
779
- import { Fragment as Fragment3, jsx as jsx7, jsxs as jsxs4 } from "react/jsx-runtime";
932
+ import { Fragment as Fragment3, jsx as jsx8, jsxs as jsxs5 } from "react/jsx-runtime";
780
933
  var ChatInput = (props) => {
781
934
  const {
782
935
  inputValue,
@@ -819,13 +972,13 @@ var ChatInput = (props) => {
819
972
  }),
820
973
  shallow
821
974
  );
822
- const [memoryOpen, setMemoryOpen] = useState4(false);
823
- const [fileInputs, setFileInputs] = useState4([]);
975
+ const [memoryOpen, setMemoryOpen] = useState5(false);
976
+ const [fileInputs, setFileInputs] = useState5([]);
824
977
  const fileInputRef = useRef2(null);
825
- const [brandingText, setBrandingText] = useState4("");
826
- const [feedbackModalOpen, setFeedbackModalOpen] = useState4(false);
827
- const [isKeyboardOpen, setKeyboardOpen] = useState4(false);
828
- const [moreActionsOpen, setMoreActionsOpen] = useState4(false);
978
+ const [brandingText, setBrandingText] = useState5("");
979
+ const [feedbackModalOpen, setFeedbackModalOpen] = useState5(false);
980
+ const [isKeyboardOpen, setKeyboardOpen] = useState5(false);
981
+ const [moreActionsOpen, setMoreActionsOpen] = useState5(false);
829
982
  const compactMobile = isMobile;
830
983
  const primaryIconSize = isMobile ? 32 : 40;
831
984
  const sendIconSize = isMobile ? 36 : 44;
@@ -1073,8 +1226,8 @@ ${sanitize(
1073
1226
  }, [isMobile, hasSecondaryActions]);
1074
1227
  const renderAttachmentButton = (key) => {
1075
1228
  if (!hasAttachmentAction) return null;
1076
- return /* @__PURE__ */ jsx7(Tooltip2, { title: "Attach files or images", children: /* @__PURE__ */ jsx7(
1077
- IconButton3,
1229
+ return /* @__PURE__ */ jsx8(Tooltip3, { title: "Attach files or images", children: /* @__PURE__ */ jsx8(
1230
+ IconButton4,
1078
1231
  {
1079
1232
  onClick: () => fileInputRef.current?.click(),
1080
1233
  sx: {
@@ -1091,8 +1244,8 @@ ${sanitize(
1091
1244
  };
1092
1245
  const renderMemoryButton = (key) => {
1093
1246
  if (!hasMemoryAction) return null;
1094
- return /* @__PURE__ */ jsx7(Tooltip2, { title: "Memory", children: /* @__PURE__ */ jsx7(
1095
- IconButton3,
1247
+ return /* @__PURE__ */ jsx8(Tooltip3, { title: "Memory", children: /* @__PURE__ */ jsx8(
1248
+ IconButton4,
1096
1249
  {
1097
1250
  onClick: () => setMemoryOpen(true),
1098
1251
  sx: {
@@ -1103,14 +1256,14 @@ ${sanitize(
1103
1256
  borderRadius: "50%",
1104
1257
  "&:hover": { bgcolor: hoverBadgeBackground }
1105
1258
  },
1106
- children: /* @__PURE__ */ jsx7(PsychologyIcon, { fontSize: "small" })
1259
+ children: /* @__PURE__ */ jsx8(PsychologyIcon, { fontSize: "small" })
1107
1260
  }
1108
1261
  ) }, key ?? "memory");
1109
1262
  };
1110
1263
  const renderFeedbackButton = (key) => {
1111
1264
  if (!hasFeedbackAction) return null;
1112
- return /* @__PURE__ */ jsx7(Tooltip2, { title: "Send Feedback", children: /* @__PURE__ */ jsx7(
1113
- IconButton3,
1265
+ return /* @__PURE__ */ jsx8(Tooltip3, { title: "Send Feedback", children: /* @__PURE__ */ jsx8(
1266
+ IconButton4,
1114
1267
  {
1115
1268
  onClick: () => setFeedbackModalOpen(true),
1116
1269
  sx: {
@@ -1121,17 +1274,17 @@ ${sanitize(
1121
1274
  borderRadius: "50%",
1122
1275
  "&:hover": { bgcolor: hoverBadgeBackground }
1123
1276
  },
1124
- children: /* @__PURE__ */ jsx7(FeedbackIcon, { fontSize: "small" })
1277
+ children: /* @__PURE__ */ jsx8(FeedbackIcon, { fontSize: "small" })
1125
1278
  }
1126
1279
  ) }, key ?? "feedback");
1127
1280
  };
1128
1281
  const renderSttButton = (key) => {
1129
1282
  if (!hasSttAction) return null;
1130
- return /* @__PURE__ */ jsx7(Box4, { sx: { display: "flex", alignItems: "center" }, children: /* @__PURE__ */ jsx7(transcriber_default, { onTranscriptionCompleted: handleTranscriptionCompleted }) }, key ?? "stt");
1283
+ return /* @__PURE__ */ jsx8(Box5, { sx: { display: "flex", alignItems: "center" }, children: /* @__PURE__ */ jsx8(transcriber_default, { onTranscriptionCompleted: handleTranscriptionCompleted }) }, key ?? "stt");
1131
1284
  };
1132
- return /* @__PURE__ */ jsxs4(Fragment3, { children: [
1133
- /* @__PURE__ */ jsxs4(
1134
- Box4,
1285
+ return /* @__PURE__ */ jsxs5(Fragment3, { children: [
1286
+ /* @__PURE__ */ jsxs5(
1287
+ Box5,
1135
1288
  {
1136
1289
  sx: {
1137
1290
  width: "100%",
@@ -1150,8 +1303,8 @@ ${sanitize(
1150
1303
  },
1151
1304
  ref: inputContainerRef,
1152
1305
  children: [
1153
- /* @__PURE__ */ jsxs4(
1154
- Box4,
1306
+ /* @__PURE__ */ jsxs5(
1307
+ Box5,
1155
1308
  {
1156
1309
  sx: {
1157
1310
  width: "100%",
@@ -1166,8 +1319,8 @@ ${sanitize(
1166
1319
  gap: isMobile ? compactMobile ? 0.75 : 1 : 1
1167
1320
  },
1168
1321
  children: [
1169
- /* @__PURE__ */ jsxs4(
1170
- Box4,
1322
+ /* @__PURE__ */ jsxs5(
1323
+ Box5,
1171
1324
  {
1172
1325
  sx: {
1173
1326
  display: "flex",
@@ -1177,8 +1330,8 @@ ${sanitize(
1177
1330
  flexDirection: "row"
1178
1331
  },
1179
1332
  children: [
1180
- fileInputs.map((file, idx) => /* @__PURE__ */ jsxs4(
1181
- Box4,
1333
+ fileInputs.map((file, idx) => /* @__PURE__ */ jsxs5(
1334
+ Box5,
1182
1335
  {
1183
1336
  sx: {
1184
1337
  position: "relative",
@@ -1191,7 +1344,7 @@ ${sanitize(
1191
1344
  gap: isMobile ? compactMobile ? 0.6 : 0.9 : 1
1192
1345
  },
1193
1346
  children: [
1194
- /* @__PURE__ */ jsx7(
1347
+ /* @__PURE__ */ jsx8(
1195
1348
  Avatar2,
1196
1349
  {
1197
1350
  sx: {
@@ -1205,22 +1358,22 @@ ${sanitize(
1205
1358
  children: getFileIcon(file.name)
1206
1359
  }
1207
1360
  ),
1208
- /* @__PURE__ */ jsx7(Typography, { variant: "caption", sx: { color: fileText }, children: file.name }),
1209
- /* @__PURE__ */ jsx7(
1210
- IconButton3,
1361
+ /* @__PURE__ */ jsx8(Typography, { variant: "caption", sx: { color: fileText }, children: file.name }),
1362
+ /* @__PURE__ */ jsx8(
1363
+ IconButton4,
1211
1364
  {
1212
1365
  size: "small",
1213
1366
  onClick: () => setFileInputs((prev) => prev.filter((_, i) => i !== idx)),
1214
1367
  sx: { ml: 0.5, color: theme.palette.mode === "dark" ? "#aaa" : "#444" },
1215
- children: /* @__PURE__ */ jsx7(CloseIcon, { sx: { fontSize: 14 } })
1368
+ children: /* @__PURE__ */ jsx8(CloseIcon, { sx: { fontSize: 14 } })
1216
1369
  }
1217
1370
  )
1218
1371
  ]
1219
1372
  },
1220
1373
  idx
1221
1374
  )),
1222
- pastedImages.map((img, idx) => /* @__PURE__ */ jsxs4(Box4, { sx: { position: "relative" }, children: [
1223
- /* @__PURE__ */ jsx7(
1375
+ pastedImages.map((img, idx) => /* @__PURE__ */ jsxs5(Box5, { sx: { position: "relative" }, children: [
1376
+ /* @__PURE__ */ jsx8(
1224
1377
  Avatar2,
1225
1378
  {
1226
1379
  src: img,
@@ -1232,8 +1385,8 @@ ${sanitize(
1232
1385
  }
1233
1386
  }
1234
1387
  ),
1235
- /* @__PURE__ */ jsx7(
1236
- IconButton3,
1388
+ /* @__PURE__ */ jsx8(
1389
+ IconButton4,
1237
1390
  {
1238
1391
  size: "small",
1239
1392
  onClick: () => removeImage(idx),
@@ -1249,7 +1402,7 @@ ${sanitize(
1249
1402
  bgcolor: "rgba(255, 5, 5, 0.85)"
1250
1403
  }
1251
1404
  },
1252
- children: /* @__PURE__ */ jsx7(
1405
+ children: /* @__PURE__ */ jsx8(
1253
1406
  CloseIcon,
1254
1407
  {
1255
1408
  sx: {
@@ -1261,7 +1414,7 @@ ${sanitize(
1261
1414
  }
1262
1415
  )
1263
1416
  ] }, `img-${idx}`)),
1264
- /* @__PURE__ */ jsx7(
1417
+ /* @__PURE__ */ jsx8(
1265
1418
  "input",
1266
1419
  {
1267
1420
  type: "file",
@@ -1298,16 +1451,16 @@ ${sanitize(
1298
1451
  ]
1299
1452
  }
1300
1453
  ),
1301
- /* @__PURE__ */ jsx7(
1302
- Box4,
1454
+ /* @__PURE__ */ jsx8(
1455
+ Box5,
1303
1456
  {
1304
1457
  sx: {
1305
1458
  display: "flex",
1306
1459
  maxHeight: "200px",
1307
1460
  overflowY: "auto"
1308
1461
  },
1309
- children: /* @__PURE__ */ jsx7(
1310
- TextField,
1462
+ children: /* @__PURE__ */ jsx8(
1463
+ TextField2,
1311
1464
  {
1312
1465
  fullWidth: true,
1313
1466
  multiline: true,
@@ -1338,8 +1491,8 @@ ${sanitize(
1338
1491
  )
1339
1492
  }
1340
1493
  ),
1341
- /* @__PURE__ */ jsxs4(
1342
- Box4,
1494
+ /* @__PURE__ */ jsxs5(
1495
+ Box5,
1343
1496
  {
1344
1497
  sx: {
1345
1498
  display: "flex",
@@ -1349,8 +1502,8 @@ ${sanitize(
1349
1502
  mt: isMobile ? 0.5 : 1
1350
1503
  },
1351
1504
  children: [
1352
- /* @__PURE__ */ jsxs4(
1353
- Box4,
1505
+ /* @__PURE__ */ jsxs5(
1506
+ Box5,
1354
1507
  {
1355
1508
  sx: {
1356
1509
  display: "flex",
@@ -1359,13 +1512,13 @@ ${sanitize(
1359
1512
  minHeight: primaryIconSize
1360
1513
  },
1361
1514
  children: [
1362
- isVoiceModeEligible && /* @__PURE__ */ jsxs4(Fragment3, { children: [
1363
- /* @__PURE__ */ jsx7(
1364
- Tooltip2,
1515
+ isVoiceModeEligible && /* @__PURE__ */ jsxs5(Fragment3, { children: [
1516
+ /* @__PURE__ */ jsx8(
1517
+ Tooltip3,
1365
1518
  {
1366
1519
  title: !isVoiceModeEnabled ? "Enable voice mode" : voiceStatus === "error" ? voiceError || "Voice mode error" : voiceStatus === "processing" ? "Transcribing your speech" : voiceStatus === "recording" ? "Recording - click to stop" : voiceStatus === "initializing" ? "Preparing microphone" : "Listening - click to turn off",
1367
- children: /* @__PURE__ */ jsx7(
1368
- IconButton3,
1520
+ children: /* @__PURE__ */ jsx8(
1521
+ IconButton4,
1369
1522
  {
1370
1523
  onClick: toggleVoiceMode,
1371
1524
  sx: {
@@ -1381,12 +1534,12 @@ ${sanitize(
1381
1534
  bgcolor: isVoiceModeEnabled ? alpha(theme.palette.error.main, theme.palette.mode === "dark" ? 0.55 : 0.38) : hoverBadgeBackground
1382
1535
  }
1383
1536
  },
1384
- children: !isVoiceModeEnabled ? /* @__PURE__ */ jsx7(GraphicEqIcon, { fontSize: "small", sx: { color: theme.palette.mode === "dark" ? fileText : theme.palette.text.secondary } }) : voiceStatus === "processing" || voiceStatus === "initializing" ? /* @__PURE__ */ jsx7(CircularProgress2, { size: 18, sx: { color: fileText } }) : voiceStatus === "error" ? /* @__PURE__ */ jsx7(HearingDisabledIcon, { fontSize: "small", sx: { color: theme.palette.error.light } }) : voiceStatus === "recording" ? /* @__PURE__ */ jsx7(GraphicEqIcon, { fontSize: "small", sx: { color: theme.palette.error.light } }) : /* @__PURE__ */ jsx7(GraphicEqIcon, { fontSize: "small", sx: { color: theme.palette.common.white } })
1537
+ children: !isVoiceModeEnabled ? /* @__PURE__ */ jsx8(GraphicEqIcon, { fontSize: "small", sx: { color: theme.palette.mode === "dark" ? fileText : theme.palette.text.secondary } }) : voiceStatus === "processing" || voiceStatus === "initializing" ? /* @__PURE__ */ jsx8(CircularProgress2, { size: 18, sx: { color: fileText } }) : voiceStatus === "error" ? /* @__PURE__ */ jsx8(HearingDisabledIcon, { fontSize: "small", sx: { color: theme.palette.error.light } }) : voiceStatus === "recording" ? /* @__PURE__ */ jsx8(GraphicEqIcon, { fontSize: "small", sx: { color: theme.palette.error.light } }) : /* @__PURE__ */ jsx8(GraphicEqIcon, { fontSize: "small", sx: { color: theme.palette.common.white } })
1385
1538
  }
1386
1539
  )
1387
1540
  }
1388
1541
  ),
1389
- !isMobile && isVoiceModeEnabled && /* @__PURE__ */ jsx7(
1542
+ !isMobile && isVoiceModeEnabled && /* @__PURE__ */ jsx8(
1390
1543
  Typography,
1391
1544
  {
1392
1545
  variant: "caption",
@@ -1404,8 +1557,8 @@ ${sanitize(
1404
1557
  !isMobile && renderAttachmentButton("attach-inline"),
1405
1558
  !isMobile && renderMemoryButton("memory-inline"),
1406
1559
  !isMobile && renderSttButton("stt-inline"),
1407
- isMobile && hasSecondaryActions && /* @__PURE__ */ jsx7(
1408
- IconButton3,
1560
+ isMobile && hasSecondaryActions && /* @__PURE__ */ jsx8(
1561
+ IconButton4,
1409
1562
  {
1410
1563
  onClick: () => setMoreActionsOpen((prev) => !prev),
1411
1564
  sx: {
@@ -1417,7 +1570,7 @@ ${sanitize(
1417
1570
  transition: "background-color 0.2s ease",
1418
1571
  "&:hover": { bgcolor: hoverBadgeBackground }
1419
1572
  },
1420
- children: /* @__PURE__ */ jsx7(
1573
+ children: /* @__PURE__ */ jsx8(
1421
1574
  ExpandMoreIcon,
1422
1575
  {
1423
1576
  fontSize: "small",
@@ -1432,8 +1585,8 @@ ${sanitize(
1432
1585
  ]
1433
1586
  }
1434
1587
  ),
1435
- /* @__PURE__ */ jsx7(Box4, { sx: { display: "flex", alignItems: "center", gap: isMobile ? 0.6 : 1 }, children: /* @__PURE__ */ jsx7(Tooltip2, { title: isStreaming ? "Stop response" : "Send message", children: /* @__PURE__ */ jsx7("span", { children: /* @__PURE__ */ jsx7(
1436
- IconButton3,
1588
+ /* @__PURE__ */ jsx8(Box5, { sx: { display: "flex", alignItems: "center", gap: isMobile ? 0.6 : 1 }, children: /* @__PURE__ */ jsx8(Tooltip3, { title: isStreaming ? "Stop response" : "Send message", children: /* @__PURE__ */ jsx8("span", { children: /* @__PURE__ */ jsx8(
1589
+ IconButton4,
1437
1590
  {
1438
1591
  onClick: isStreaming ? onStop || (() => {
1439
1592
  }) : handleSubmit,
@@ -1449,14 +1602,14 @@ ${sanitize(
1449
1602
  "&:hover": { bgcolor: sendButtonHover },
1450
1603
  "&.Mui-disabled": { opacity: 0.5 }
1451
1604
  },
1452
- children: isStreaming ? /* @__PURE__ */ jsx7(CloseIcon, { fontSize: "small" }) : /* @__PURE__ */ jsx7(ArrowUpwardIcon, { fontSize: "small" })
1605
+ children: isStreaming ? /* @__PURE__ */ jsx8(CloseIcon, { fontSize: "small" }) : /* @__PURE__ */ jsx8(ArrowUpwardIcon, { fontSize: "small" })
1453
1606
  }
1454
1607
  ) }) }) })
1455
1608
  ]
1456
1609
  }
1457
1610
  ),
1458
- isMobile && hasSecondaryActions && /* @__PURE__ */ jsx7(Collapse, { in: moreActionsOpen, unmountOnExit: true, children: /* @__PURE__ */ jsxs4(
1459
- Box4,
1611
+ isMobile && hasSecondaryActions && /* @__PURE__ */ jsx8(Collapse, { in: moreActionsOpen, unmountOnExit: true, children: /* @__PURE__ */ jsxs5(
1612
+ Box5,
1460
1613
  {
1461
1614
  sx: {
1462
1615
  display: "flex",
@@ -1477,7 +1630,7 @@ ${sanitize(
1477
1630
  ]
1478
1631
  }
1479
1632
  ),
1480
- /* @__PURE__ */ jsxs4(
1633
+ /* @__PURE__ */ jsxs5(
1481
1634
  Typography,
1482
1635
  {
1483
1636
  variant: "caption",
@@ -1503,8 +1656,8 @@ ${sanitize(
1503
1656
  ]
1504
1657
  }
1505
1658
  ),
1506
- isMemoryEnabled && /* @__PURE__ */ jsx7(memory_modal_default, { open: memoryOpen, onClose: () => setMemoryOpen(false) }),
1507
- isFeedbackEnabled && /* @__PURE__ */ jsx7(
1659
+ isMemoryEnabled && /* @__PURE__ */ jsx8(memory_modal_default, { open: memoryOpen, onClose: () => setMemoryOpen(false) }),
1660
+ isFeedbackEnabled && /* @__PURE__ */ jsx8(
1508
1661
  FeedbackModal,
1509
1662
  {
1510
1663
  open: feedbackModalOpen,
@@ -1517,8 +1670,8 @@ ${sanitize(
1517
1670
  var chat_input_default = ChatInput;
1518
1671
 
1519
1672
  // src/chat/ask-user-card.tsx
1520
- import { useEffect as useEffect4, useState as useState5 } from "react";
1521
- import { Box as Box5, Paper, Typography as Typography2, Button, TextField as TextField2, Chip, Stack } from "@mui/material";
1673
+ import { useEffect as useEffect4, useState as useState6 } from "react";
1674
+ import { Box as Box6, Paper, Typography as Typography2, Button, TextField as TextField3, Chip, Stack } from "@mui/material";
1522
1675
  import { useTheme as useTheme5, alpha as alpha2 } from "@mui/material/styles";
1523
1676
 
1524
1677
  // src/store/askUserStore.ts
@@ -1584,12 +1737,12 @@ var parseAskUserQuestions = (rawJson) => {
1584
1737
  };
1585
1738
 
1586
1739
  // src/chat/ask-user-card.tsx
1587
- import { jsx as jsx8, jsxs as jsxs5 } from "react/jsx-runtime";
1740
+ import { jsx as jsx9, jsxs as jsxs6 } from "react/jsx-runtime";
1588
1741
  var AskUserCard = () => {
1589
1742
  const theme = useTheme5();
1590
1743
  const { pending, submit, cancel } = useAskUserStore();
1591
- const [selected, setSelected] = useState5({});
1592
- const [freeform, setFreeform] = useState5({});
1744
+ const [selected, setSelected] = useState6({});
1745
+ const [freeform, setFreeform] = useState6({});
1593
1746
  useEffect4(() => {
1594
1747
  if (!pending) return;
1595
1748
  const preselected = {};
@@ -1610,7 +1763,7 @@ var AskUserCard = () => {
1610
1763
  });
1611
1764
  submit(final);
1612
1765
  };
1613
- return /* @__PURE__ */ jsx8(Box5, { sx: { width: "100%", display: "flex", justifyContent: "center", px: { xs: 1, sm: 2 }, mb: 1.5 }, children: /* @__PURE__ */ jsxs5(
1766
+ return /* @__PURE__ */ jsx9(Box6, { sx: { width: "100%", display: "flex", justifyContent: "center", px: { xs: 1, sm: 2 }, mb: 1.5 }, children: /* @__PURE__ */ jsxs6(
1614
1767
  Paper,
1615
1768
  {
1616
1769
  elevation: 0,
@@ -1623,13 +1776,13 @@ var AskUserCard = () => {
1623
1776
  bgcolor: alpha2(theme.palette.primary.main, 0.06)
1624
1777
  },
1625
1778
  children: [
1626
- /* @__PURE__ */ jsx8(Typography2, { variant: "caption", sx: { color: theme.palette.primary.main, fontWeight: 700, letterSpacing: 0.4 }, children: "BANDIT NEEDS A QUICK DECISION" }),
1627
- pending.questions.map((q) => /* @__PURE__ */ jsxs5(Box5, { sx: { mt: 1.5 }, children: [
1628
- q.header && /* @__PURE__ */ jsx8(Chip, { label: q.header, size: "small", sx: { mb: 0.75, fontWeight: 600 }, color: "primary", variant: "outlined" }),
1629
- /* @__PURE__ */ jsx8(Typography2, { sx: { fontWeight: 600, color: theme.palette.text.primary, mb: 1 }, children: q.question }),
1630
- q.options && q.options.length > 0 && /* @__PURE__ */ jsx8(Stack, { spacing: 1, children: q.options.map((opt) => {
1779
+ /* @__PURE__ */ jsx9(Typography2, { variant: "caption", sx: { color: theme.palette.primary.main, fontWeight: 700, letterSpacing: 0.4 }, children: "BANDIT NEEDS A QUICK DECISION" }),
1780
+ pending.questions.map((q) => /* @__PURE__ */ jsxs6(Box6, { sx: { mt: 1.5 }, children: [
1781
+ q.header && /* @__PURE__ */ jsx9(Chip, { label: q.header, size: "small", sx: { mb: 0.75, fontWeight: 600 }, color: "primary", variant: "outlined" }),
1782
+ /* @__PURE__ */ jsx9(Typography2, { sx: { fontWeight: 600, color: theme.palette.text.primary, mb: 1 }, children: q.question }),
1783
+ q.options && q.options.length > 0 && /* @__PURE__ */ jsx9(Stack, { spacing: 1, children: q.options.map((opt) => {
1631
1784
  const isSel = selected[q.id] === opt.label && !freeform[q.id]?.trim();
1632
- return /* @__PURE__ */ jsx8(
1785
+ return /* @__PURE__ */ jsx9(
1633
1786
  Button,
1634
1787
  {
1635
1788
  onClick: () => {
@@ -1646,9 +1799,9 @@ var AskUserCard = () => {
1646
1799
  px: 1.5,
1647
1800
  borderColor: alpha2(theme.palette.primary.main, 0.4)
1648
1801
  },
1649
- children: /* @__PURE__ */ jsxs5(Box5, { children: [
1650
- /* @__PURE__ */ jsx8(Typography2, { sx: { fontWeight: 600, lineHeight: 1.3 }, children: opt.label }),
1651
- opt.description && /* @__PURE__ */ jsx8(
1802
+ children: /* @__PURE__ */ jsxs6(Box6, { children: [
1803
+ /* @__PURE__ */ jsx9(Typography2, { sx: { fontWeight: 600, lineHeight: 1.3 }, children: opt.label }),
1804
+ opt.description && /* @__PURE__ */ jsx9(
1652
1805
  Typography2,
1653
1806
  {
1654
1807
  variant: "caption",
@@ -1661,8 +1814,8 @@ var AskUserCard = () => {
1661
1814
  opt.label
1662
1815
  );
1663
1816
  }) }),
1664
- q.allowFreeform !== false && /* @__PURE__ */ jsx8(
1665
- TextField2,
1817
+ q.allowFreeform !== false && /* @__PURE__ */ jsx9(
1818
+ TextField3,
1666
1819
  {
1667
1820
  fullWidth: true,
1668
1821
  size: "small",
@@ -1673,9 +1826,9 @@ var AskUserCard = () => {
1673
1826
  }
1674
1827
  )
1675
1828
  ] }, q.id)),
1676
- /* @__PURE__ */ jsxs5(Box5, { sx: { display: "flex", justifyContent: "flex-end", gap: 1, mt: 2 }, children: [
1677
- /* @__PURE__ */ jsx8(Button, { onClick: cancel, color: "inherit", sx: { textTransform: "none", color: theme.palette.text.secondary }, children: "Skip" }),
1678
- /* @__PURE__ */ jsx8(Button, { onClick: handleSubmit, disabled: !allAnswered, variant: "contained", sx: { textTransform: "none" }, children: "Submit" })
1829
+ /* @__PURE__ */ jsxs6(Box6, { sx: { display: "flex", justifyContent: "flex-end", gap: 1, mt: 2 }, children: [
1830
+ /* @__PURE__ */ jsx9(Button, { onClick: cancel, color: "inherit", sx: { textTransform: "none", color: theme.palette.text.secondary }, children: "Skip" }),
1831
+ /* @__PURE__ */ jsx9(Button, { onClick: handleSubmit, disabled: !allAnswered, variant: "contained", sx: { textTransform: "none" }, children: "Submit" })
1679
1832
  ] })
1680
1833
  ]
1681
1834
  }
@@ -2567,9 +2720,9 @@ The user explicitly asked you to remember this. Respond with a short third-perso
2567
2720
  };
2568
2721
 
2569
2722
  // src/chat/hooks/useMoodEngine.tsx
2570
- import { useState as useState6 } from "react";
2723
+ import { useState as useState7 } from "react";
2571
2724
  var useMoodEngine = () => {
2572
- const [mood, setMood] = useState6("neutral");
2725
+ const [mood, setMood] = useState7("neutral");
2573
2726
  const analyzeMood = async (message) => {
2574
2727
  try {
2575
2728
  const detected = await detectMessageMood(message);
@@ -4288,9 +4441,9 @@ var useAutoScroll = (options = {}) => {
4288
4441
  };
4289
4442
 
4290
4443
  // src/hooks/useNetworkStatus.ts
4291
- import { useState as useState7, useEffect as useEffect6, useCallback as useCallback3 } from "react";
4444
+ import { useState as useState8, useEffect as useEffect6, useCallback as useCallback3 } from "react";
4292
4445
  var useNetworkStatus = () => {
4293
- const [networkStatus, setNetworkStatus] = useState7({
4446
+ const [networkStatus, setNetworkStatus] = useState8({
4294
4447
  isOnline: navigator.onLine,
4295
4448
  isSlowConnection: false,
4296
4449
  connectionQuality: "fast",
@@ -4369,16 +4522,16 @@ var useNetworkStatus = () => {
4369
4522
 
4370
4523
  // src/chat/chat-app-bar.tsx
4371
4524
  import { Avatar as Avatar8 } from "@mui/material";
4372
- import { useEffect as useEffect12, useRef as useRef10, useState as useState14 } from "react";
4525
+ import { useEffect as useEffect12, useRef as useRef10, useState as useState15 } from "react";
4373
4526
  import {
4374
- Box as Box12,
4375
- IconButton as IconButton9,
4527
+ Box as Box13,
4528
+ IconButton as IconButton10,
4376
4529
  Menu as Menu5,
4377
4530
  MenuItem as MenuItem5,
4378
- Tooltip as Tooltip5,
4531
+ Tooltip as Tooltip6,
4379
4532
  useMediaQuery as useMediaQuery5,
4380
4533
  useTheme as useTheme12,
4381
- Dialog as Dialog5,
4534
+ Dialog as Dialog6,
4382
4535
  DialogTitle as DialogTitle5,
4383
4536
  DialogContent as DialogContent5,
4384
4537
  DialogActions as DialogActions5,
@@ -4388,14 +4541,14 @@ import {
4388
4541
  import { useNavigate } from "react-router-dom";
4389
4542
 
4390
4543
  // src/chat/conversation-drawer.tsx
4391
- import { useState as useState12, useMemo as useMemo2, useEffect as useEffect10, useRef as useRef8, useCallback as useCallback4 } from "react";
4544
+ import { useState as useState13, useMemo as useMemo2, useEffect as useEffect10, useRef as useRef8, useCallback as useCallback4 } from "react";
4392
4545
  import {
4393
4546
  Drawer,
4394
- Box as Box10,
4547
+ Box as Box11,
4395
4548
  Typography as Typography7,
4396
- IconButton as IconButton7,
4397
- Tooltip as Tooltip4,
4398
- TextField as TextField6,
4549
+ IconButton as IconButton8,
4550
+ Tooltip as Tooltip5,
4551
+ TextField as TextField7,
4399
4552
  InputAdornment,
4400
4553
  useMediaQuery as useMediaQuery4,
4401
4554
  Collapse as Collapse2,
@@ -4404,7 +4557,7 @@ import {
4404
4557
  MenuItem as MenuItem3,
4405
4558
  ListItemIcon as ListItemIcon3,
4406
4559
  ListItemText as ListItemText3,
4407
- Dialog as Dialog3,
4560
+ Dialog as Dialog4,
4408
4561
  DialogTitle as DialogTitle3,
4409
4562
  DialogContent as DialogContent3,
4410
4563
  DialogActions as DialogActions3,
@@ -4412,19 +4565,19 @@ import {
4412
4565
  Avatar as Avatar6,
4413
4566
  alpha as alpha6
4414
4567
  } from "@mui/material";
4415
- import { X as CloseIcon4, X as ClearIcon, Search as SearchIcon, Folder as FolderIcon4, MoreVertical as MoreVertIcon3, Trash2 as DeleteSweepIcon, Inbox as InboxIcon3, Plus as AddIcon4, Settings as SettingsIcon2, Brain as MemoryIcon } from "lucide-react";
4568
+ import { X as CloseIcon5, X as ClearIcon, Search as SearchIcon, Folder as FolderIcon4, MoreVertical as MoreVertIcon3, Trash2 as DeleteSweepIcon, Inbox as InboxIcon3, Plus as AddIcon4, Settings as SettingsIcon2, Brain as MemoryIcon } from "lucide-react";
4416
4569
  import { useTheme as useTheme10 } from "@mui/material/styles";
4417
4570
 
4418
4571
  // src/chat/project-management-modal.tsx
4419
- import { useState as useState8, useEffect as useEffect7, useRef as useRef5 } from "react";
4572
+ import { useState as useState9, useEffect as useEffect7, useRef as useRef5 } from "react";
4420
4573
  import {
4421
4574
  Modal,
4422
4575
  Button as Button2,
4423
- TextField as TextField3,
4576
+ TextField as TextField4,
4424
4577
  List,
4425
4578
  ListItem,
4426
- IconButton as IconButton4,
4427
- Box as Box6,
4579
+ IconButton as IconButton5,
4580
+ Box as Box7,
4428
4581
  Typography as Typography3,
4429
4582
  Avatar as Avatar3,
4430
4583
  Chip as Chip2,
@@ -4435,9 +4588,9 @@ import {
4435
4588
  SwipeableDrawer,
4436
4589
  useMediaQuery as useMediaQuery2
4437
4590
  } from "@mui/material";
4438
- import { Plus as AddIcon2, Pencil as EditIcon, Trash2 as DeleteIcon, MoreVertical as MoreVertIcon, Folder as FolderIcon, X as CloseIcon2, ArrowLeft as ArrowBackIcon } from "lucide-react";
4591
+ import { Plus as AddIcon2, Pencil as EditIcon2, Trash2 as DeleteIcon, MoreVertical as MoreVertIcon, Folder as FolderIcon, X as CloseIcon3, ArrowLeft as ArrowBackIcon } from "lucide-react";
4439
4592
  import { useTheme as useTheme6, alpha as alpha3 } from "@mui/material/styles";
4440
- import { Fragment as Fragment4, jsx as jsx9, jsxs as jsxs6 } from "react/jsx-runtime";
4593
+ import { Fragment as Fragment4, jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
4441
4594
  var DEFAULT_COLORS = [
4442
4595
  "#2196F3",
4443
4596
  "#4CAF50",
@@ -4467,18 +4620,18 @@ var ProjectManagementModal = ({
4467
4620
  hydrate
4468
4621
  } = useProjectStore();
4469
4622
  const { getConversationsByProject } = useConversationStore();
4470
- const [showCreateForm, setShowCreateForm] = useState8(false);
4471
- const [editingProject, setEditingProject] = useState8(null);
4472
- const [formData, setFormData] = useState8({
4623
+ const [showCreateForm, setShowCreateForm] = useState9(false);
4624
+ const [editingProject, setEditingProject] = useState9(null);
4625
+ const [formData, setFormData] = useState9({
4473
4626
  name: "",
4474
4627
  description: "",
4475
4628
  instructions: "",
4476
4629
  color: DEFAULT_COLORS[0]
4477
4630
  });
4478
- const [menuAnchor, setMenuAnchor] = useState8(null);
4479
- const [selectedProject, setSelectedProject] = useState8(null);
4480
- const [loading, setLoading] = useState8(false);
4481
- const [error, setError] = useState8(null);
4631
+ const [menuAnchor, setMenuAnchor] = useState9(null);
4632
+ const [selectedProject, setSelectedProject] = useState9(null);
4633
+ const [loading, setLoading] = useState9(false);
4634
+ const [error, setError] = useState9(null);
4482
4635
  const modalContainerRef = useRef5(null);
4483
4636
  useEffect7(() => {
4484
4637
  if (open && !_hasHydrated) {
@@ -4595,8 +4748,8 @@ var ProjectManagementModal = ({
4595
4748
  const hoverSurface = alpha3(theme.palette.primary.main, theme.palette.mode === "dark" ? 0.22 : 0.08);
4596
4749
  const headerTitle = showCreateForm ? editingProject ? "Edit Project" : "Create Project" : "Manage Projects";
4597
4750
  const headerSubtitle = showCreateForm ? "Name, describe, and color-code your project." : "Organize conversations into cohesive projects.";
4598
- const content = /* @__PURE__ */ jsxs6(
4599
- Box6,
4751
+ const content = /* @__PURE__ */ jsxs7(
4752
+ Box7,
4600
4753
  {
4601
4754
  ref: modalContainerRef,
4602
4755
  sx: {
@@ -4614,8 +4767,8 @@ var ProjectManagementModal = ({
4614
4767
  position: "relative"
4615
4768
  },
4616
4769
  children: [
4617
- isMobile && /* @__PURE__ */ jsx9(
4618
- Box6,
4770
+ isMobile && /* @__PURE__ */ jsx10(
4771
+ Box7,
4619
4772
  {
4620
4773
  sx: {
4621
4774
  width: 56,
@@ -4628,8 +4781,8 @@ var ProjectManagementModal = ({
4628
4781
  }
4629
4782
  }
4630
4783
  ),
4631
- /* @__PURE__ */ jsxs6(
4632
- Box6,
4784
+ /* @__PURE__ */ jsxs7(
4785
+ Box7,
4633
4786
  {
4634
4787
  sx: {
4635
4788
  px: isMobile ? 1.5 : 2.75,
@@ -4641,8 +4794,8 @@ var ProjectManagementModal = ({
4641
4794
  gap: 1
4642
4795
  },
4643
4796
  children: [
4644
- /* @__PURE__ */ jsxs6(
4645
- Box6,
4797
+ /* @__PURE__ */ jsxs7(
4798
+ Box7,
4646
4799
  {
4647
4800
  sx: {
4648
4801
  display: "flex",
@@ -4651,8 +4804,8 @@ var ProjectManagementModal = ({
4651
4804
  gap: 1
4652
4805
  },
4653
4806
  children: [
4654
- /* @__PURE__ */ jsxs6(
4655
- Box6,
4807
+ /* @__PURE__ */ jsxs7(
4808
+ Box7,
4656
4809
  {
4657
4810
  sx: {
4658
4811
  display: "flex",
@@ -4662,8 +4815,8 @@ var ProjectManagementModal = ({
4662
4815
  flex: 1
4663
4816
  },
4664
4817
  children: [
4665
- showCreateForm && /* @__PURE__ */ jsx9(IconButton4, { onClick: resetForm, size: "small", sx: { mr: 0.5 }, children: /* @__PURE__ */ jsx9(ArrowBackIcon, { size: 16 }) }),
4666
- /* @__PURE__ */ jsx9(
4818
+ showCreateForm && /* @__PURE__ */ jsx10(IconButton5, { onClick: resetForm, size: "small", sx: { mr: 0.5 }, children: /* @__PURE__ */ jsx10(ArrowBackIcon, { size: 16 }) }),
4819
+ /* @__PURE__ */ jsx10(
4667
4820
  Typography3,
4668
4821
  {
4669
4822
  variant: "h6",
@@ -4680,16 +4833,16 @@ var ProjectManagementModal = ({
4680
4833
  ]
4681
4834
  }
4682
4835
  ),
4683
- /* @__PURE__ */ jsx9(IconButton4, { onClick: handleClose, size: "small", children: /* @__PURE__ */ jsx9(CloseIcon2, {}) })
4836
+ /* @__PURE__ */ jsx10(IconButton5, { onClick: handleClose, size: "small", children: /* @__PURE__ */ jsx10(CloseIcon3, {}) })
4684
4837
  ]
4685
4838
  }
4686
4839
  ),
4687
- /* @__PURE__ */ jsx9(Typography3, { variant: "body2", color: "text.secondary", children: headerSubtitle })
4840
+ /* @__PURE__ */ jsx10(Typography3, { variant: "body2", color: "text.secondary", children: headerSubtitle })
4688
4841
  ]
4689
4842
  }
4690
4843
  ),
4691
- /* @__PURE__ */ jsxs6(
4692
- Box6,
4844
+ /* @__PURE__ */ jsxs7(
4845
+ Box7,
4693
4846
  {
4694
4847
  sx: {
4695
4848
  flex: 1,
@@ -4701,10 +4854,10 @@ var ProjectManagementModal = ({
4701
4854
  gap: 2.5
4702
4855
  },
4703
4856
  children: [
4704
- error && /* @__PURE__ */ jsx9(Alert, { severity: "error", onClose: () => setError(null), children: error }),
4705
- showCreateForm ? /* @__PURE__ */ jsxs6(Box6, { sx: { display: "flex", flexDirection: "column", gap: 2 }, children: [
4706
- /* @__PURE__ */ jsx9(
4707
- TextField3,
4857
+ error && /* @__PURE__ */ jsx10(Alert, { severity: "error", onClose: () => setError(null), children: error }),
4858
+ showCreateForm ? /* @__PURE__ */ jsxs7(Box7, { sx: { display: "flex", flexDirection: "column", gap: 2 }, children: [
4859
+ /* @__PURE__ */ jsx10(
4860
+ TextField4,
4708
4861
  {
4709
4862
  label: "Project name",
4710
4863
  value: formData.name,
@@ -4715,8 +4868,8 @@ var ProjectManagementModal = ({
4715
4868
  autoFocus: true
4716
4869
  }
4717
4870
  ),
4718
- /* @__PURE__ */ jsx9(
4719
- TextField3,
4871
+ /* @__PURE__ */ jsx10(
4872
+ TextField4,
4720
4873
  {
4721
4874
  label: "Description (optional)",
4722
4875
  value: formData.description,
@@ -4727,8 +4880,8 @@ var ProjectManagementModal = ({
4727
4880
  disabled: loading
4728
4881
  }
4729
4882
  ),
4730
- /* @__PURE__ */ jsx9(
4731
- TextField3,
4883
+ /* @__PURE__ */ jsx10(
4884
+ TextField4,
4732
4885
  {
4733
4886
  label: "Project instructions (optional)",
4734
4887
  helperText: "Standing context the assistant uses for every chat in this project \u2014 goals, tone, key facts.",
@@ -4740,10 +4893,10 @@ var ProjectManagementModal = ({
4740
4893
  disabled: loading
4741
4894
  }
4742
4895
  ),
4743
- /* @__PURE__ */ jsxs6(Box6, { children: [
4744
- /* @__PURE__ */ jsx9(Typography3, { variant: "subtitle2", sx: { mb: 1 }, children: "Color" }),
4745
- /* @__PURE__ */ jsx9(Box6, { sx: { display: "flex", flexWrap: "wrap", gap: 1 }, children: DEFAULT_COLORS.map((color) => /* @__PURE__ */ jsx9(
4746
- Box6,
4896
+ /* @__PURE__ */ jsxs7(Box7, { children: [
4897
+ /* @__PURE__ */ jsx10(Typography3, { variant: "subtitle2", sx: { mb: 1 }, children: "Color" }),
4898
+ /* @__PURE__ */ jsx10(Box7, { sx: { display: "flex", flexWrap: "wrap", gap: 1 }, children: DEFAULT_COLORS.map((color) => /* @__PURE__ */ jsx10(
4899
+ Box7,
4747
4900
  {
4748
4901
  sx: {
4749
4902
  width: 32,
@@ -4763,11 +4916,11 @@ var ProjectManagementModal = ({
4763
4916
  color
4764
4917
  )) })
4765
4918
  ] })
4766
- ] }) : /* @__PURE__ */ jsxs6(Box6, { sx: { display: "flex", flexDirection: "column", gap: 2 }, children: [
4767
- /* @__PURE__ */ jsx9(
4919
+ ] }) : /* @__PURE__ */ jsxs7(Box7, { sx: { display: "flex", flexDirection: "column", gap: 2 }, children: [
4920
+ /* @__PURE__ */ jsx10(
4768
4921
  Button2,
4769
4922
  {
4770
- startIcon: /* @__PURE__ */ jsx9(AddIcon2, {}),
4923
+ startIcon: /* @__PURE__ */ jsx10(AddIcon2, {}),
4771
4924
  onClick: () => setShowCreateForm(true),
4772
4925
  variant: "contained",
4773
4926
  sx: {
@@ -4779,8 +4932,8 @@ var ProjectManagementModal = ({
4779
4932
  children: "Create project"
4780
4933
  }
4781
4934
  ),
4782
- projects.length === 0 ? /* @__PURE__ */ jsxs6(
4783
- Box6,
4935
+ projects.length === 0 ? /* @__PURE__ */ jsxs7(
4936
+ Box7,
4784
4937
  {
4785
4938
  sx: {
4786
4939
  textAlign: "center",
@@ -4792,15 +4945,15 @@ var ProjectManagementModal = ({
4792
4945
  backgroundColor: subtleSurface
4793
4946
  },
4794
4947
  children: [
4795
- /* @__PURE__ */ jsx9(FolderIcon, { size: 48, style: { marginBottom: 8, opacity: 0.5 } }),
4796
- /* @__PURE__ */ jsx9(Typography3, { variant: "body1", sx: { fontWeight: 600 }, children: "No projects yet" }),
4797
- /* @__PURE__ */ jsx9(Typography3, { variant: "body2", children: "Create your first project to organize conversations." })
4948
+ /* @__PURE__ */ jsx10(FolderIcon, { size: 48, style: { marginBottom: 8, opacity: 0.5 } }),
4949
+ /* @__PURE__ */ jsx10(Typography3, { variant: "body1", sx: { fontWeight: 600 }, children: "No projects yet" }),
4950
+ /* @__PURE__ */ jsx10(Typography3, { variant: "body2", children: "Create your first project to organize conversations." })
4798
4951
  ]
4799
4952
  }
4800
- ) : /* @__PURE__ */ jsx9(List, { sx: { display: "flex", flexDirection: "column", gap: 1.25, py: 0 }, children: projects.map((project) => {
4953
+ ) : /* @__PURE__ */ jsx10(List, { sx: { display: "flex", flexDirection: "column", gap: 1.25, py: 0 }, children: projects.map((project) => {
4801
4954
  const conversationCount = getConversationsByProject(project.id).length;
4802
- return /* @__PURE__ */ jsx9(ListItem, { disablePadding: true, children: /* @__PURE__ */ jsxs6(
4803
- Box6,
4955
+ return /* @__PURE__ */ jsx10(ListItem, { disablePadding: true, children: /* @__PURE__ */ jsxs7(
4956
+ Box7,
4804
4957
  {
4805
4958
  sx: {
4806
4959
  display: "flex",
@@ -4818,7 +4971,7 @@ var ProjectManagementModal = ({
4818
4971
  }
4819
4972
  },
4820
4973
  children: [
4821
- /* @__PURE__ */ jsx9(
4974
+ /* @__PURE__ */ jsx10(
4822
4975
  Avatar3,
4823
4976
  {
4824
4977
  sx: {
@@ -4827,12 +4980,12 @@ var ProjectManagementModal = ({
4827
4980
  height: 36,
4828
4981
  fontSize: "1rem"
4829
4982
  },
4830
- children: /* @__PURE__ */ jsx9(FolderIcon, { size: 16 })
4983
+ children: /* @__PURE__ */ jsx10(FolderIcon, { size: 16 })
4831
4984
  }
4832
4985
  ),
4833
- /* @__PURE__ */ jsxs6(Box6, { sx: { flex: 1, minWidth: 0 }, children: [
4834
- /* @__PURE__ */ jsxs6(Box6, { sx: { display: "flex", alignItems: "center", gap: 1, flexWrap: "wrap" }, children: [
4835
- /* @__PURE__ */ jsx9(
4986
+ /* @__PURE__ */ jsxs7(Box7, { sx: { flex: 1, minWidth: 0 }, children: [
4987
+ /* @__PURE__ */ jsxs7(Box7, { sx: { display: "flex", alignItems: "center", gap: 1, flexWrap: "wrap" }, children: [
4988
+ /* @__PURE__ */ jsx10(
4836
4989
  Typography3,
4837
4990
  {
4838
4991
  variant: "subtitle1",
@@ -4840,7 +4993,7 @@ var ProjectManagementModal = ({
4840
4993
  children: project.name
4841
4994
  }
4842
4995
  ),
4843
- /* @__PURE__ */ jsx9(
4996
+ /* @__PURE__ */ jsx10(
4844
4997
  Chip2,
4845
4998
  {
4846
4999
  label: `${conversationCount}`,
@@ -4855,7 +5008,7 @@ var ProjectManagementModal = ({
4855
5008
  }
4856
5009
  )
4857
5010
  ] }),
4858
- project.description && /* @__PURE__ */ jsx9(
5011
+ project.description && /* @__PURE__ */ jsx10(
4859
5012
  Typography3,
4860
5013
  {
4861
5014
  variant: "body2",
@@ -4865,8 +5018,8 @@ var ProjectManagementModal = ({
4865
5018
  }
4866
5019
  )
4867
5020
  ] }),
4868
- /* @__PURE__ */ jsx9(
4869
- IconButton4,
5021
+ /* @__PURE__ */ jsx10(
5022
+ IconButton5,
4870
5023
  {
4871
5024
  onClick: (e) => {
4872
5025
  e.stopPropagation();
@@ -4878,7 +5031,7 @@ var ProjectManagementModal = ({
4878
5031
  mt: 0.25,
4879
5032
  zIndex: 1
4880
5033
  },
4881
- children: /* @__PURE__ */ jsx9(MoreVertIcon, { size: 16 })
5034
+ children: /* @__PURE__ */ jsx10(MoreVertIcon, { size: 16 })
4882
5035
  }
4883
5036
  )
4884
5037
  ]
@@ -4889,8 +5042,8 @@ var ProjectManagementModal = ({
4889
5042
  ]
4890
5043
  }
4891
5044
  ),
4892
- /* @__PURE__ */ jsx9(
4893
- Box6,
5045
+ /* @__PURE__ */ jsx10(
5046
+ Box7,
4894
5047
  {
4895
5048
  sx: {
4896
5049
  px: isMobile ? 1.5 : 2.75,
@@ -4900,8 +5053,8 @@ var ProjectManagementModal = ({
4900
5053
  justifyContent: "flex-end",
4901
5054
  gap: 1
4902
5055
  },
4903
- children: showCreateForm ? /* @__PURE__ */ jsxs6(Fragment4, { children: [
4904
- /* @__PURE__ */ jsx9(
5056
+ children: showCreateForm ? /* @__PURE__ */ jsxs7(Fragment4, { children: [
5057
+ /* @__PURE__ */ jsx10(
4905
5058
  Button2,
4906
5059
  {
4907
5060
  onClick: resetForm,
@@ -4910,21 +5063,21 @@ var ProjectManagementModal = ({
4910
5063
  children: "Cancel"
4911
5064
  }
4912
5065
  ),
4913
- /* @__PURE__ */ jsx9(
5066
+ /* @__PURE__ */ jsx10(
4914
5067
  Button2,
4915
5068
  {
4916
5069
  onClick: editingProject ? handleEditProject : handleCreateProject,
4917
5070
  variant: "contained",
4918
5071
  disabled: loading,
4919
- startIcon: loading ? /* @__PURE__ */ jsx9(CircularProgress3, { size: 16 }) : void 0,
5072
+ startIcon: loading ? /* @__PURE__ */ jsx10(CircularProgress3, { size: 16 }) : void 0,
4920
5073
  sx: { textTransform: "none", borderRadius: 2 },
4921
5074
  children: editingProject ? "Update project" : "Create project"
4922
5075
  }
4923
5076
  )
4924
- ] }) : /* @__PURE__ */ jsx9(Button2, { onClick: handleClose, sx: { textTransform: "none", borderRadius: 2 }, children: "Close" })
5077
+ ] }) : /* @__PURE__ */ jsx10(Button2, { onClick: handleClose, sx: { textTransform: "none", borderRadius: 2 }, children: "Close" })
4925
5078
  }
4926
5079
  ),
4927
- /* @__PURE__ */ jsxs6(
5080
+ /* @__PURE__ */ jsxs7(
4928
5081
  Menu,
4929
5082
  {
4930
5083
  anchorEl: menuAnchor,
@@ -4946,20 +5099,20 @@ var ProjectManagementModal = ({
4946
5099
  }
4947
5100
  },
4948
5101
  children: [
4949
- /* @__PURE__ */ jsx9(
5102
+ /* @__PURE__ */ jsx10(
4950
5103
  MenuItem,
4951
5104
  {
4952
5105
  onClick: () => {
4953
5106
  if (!selectedProject) return;
4954
5107
  startEdit(selectedProject);
4955
5108
  },
4956
- children: /* @__PURE__ */ jsxs6(Box6, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
4957
- /* @__PURE__ */ jsx9(EditIcon, { size: 16 }),
4958
- /* @__PURE__ */ jsx9(Typography3, { variant: "body2", color: "inherit", children: "Edit" })
5109
+ children: /* @__PURE__ */ jsxs7(Box7, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
5110
+ /* @__PURE__ */ jsx10(EditIcon2, { size: 16 }),
5111
+ /* @__PURE__ */ jsx10(Typography3, { variant: "body2", color: "inherit", children: "Edit" })
4959
5112
  ] })
4960
5113
  }
4961
5114
  ),
4962
- /* @__PURE__ */ jsx9(
5115
+ /* @__PURE__ */ jsx10(
4963
5116
  MenuItem,
4964
5117
  {
4965
5118
  onClick: () => {
@@ -4967,9 +5120,9 @@ var ProjectManagementModal = ({
4967
5120
  handleDeleteProject(selectedProject);
4968
5121
  },
4969
5122
  sx: { color: theme.palette.error.main },
4970
- children: /* @__PURE__ */ jsxs6(Box6, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
4971
- /* @__PURE__ */ jsx9(DeleteIcon, { size: 16 }),
4972
- /* @__PURE__ */ jsx9(Typography3, { variant: "body2", color: "inherit", children: "Delete" })
5123
+ children: /* @__PURE__ */ jsxs7(Box7, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
5124
+ /* @__PURE__ */ jsx10(DeleteIcon, { size: 16 }),
5125
+ /* @__PURE__ */ jsx10(Typography3, { variant: "body2", color: "inherit", children: "Delete" })
4973
5126
  ] })
4974
5127
  }
4975
5128
  )
@@ -4979,7 +5132,7 @@ var ProjectManagementModal = ({
4979
5132
  ]
4980
5133
  }
4981
5134
  );
4982
- return /* @__PURE__ */ jsx9(Fragment4, { children: isMobile ? /* @__PURE__ */ jsx9(
5135
+ return /* @__PURE__ */ jsx10(Fragment4, { children: isMobile ? /* @__PURE__ */ jsx10(
4983
5136
  SwipeableDrawer,
4984
5137
  {
4985
5138
  anchor: "bottom",
@@ -4999,7 +5152,7 @@ var ProjectManagementModal = ({
4999
5152
  },
5000
5153
  children: content
5001
5154
  }
5002
- ) : /* @__PURE__ */ jsx9(
5155
+ ) : /* @__PURE__ */ jsx10(
5003
5156
  Modal,
5004
5157
  {
5005
5158
  open,
@@ -5018,9 +5171,9 @@ var ProjectManagementModal = ({
5018
5171
  var project_management_modal_default = ProjectManagementModal;
5019
5172
 
5020
5173
  // src/chat/move-conversation-modal.tsx
5021
- import { useState as useState9, useEffect as useEffect8 } from "react";
5174
+ import { useState as useState10, useEffect as useEffect8 } from "react";
5022
5175
  import {
5023
- Dialog,
5176
+ Dialog as Dialog2,
5024
5177
  DialogTitle,
5025
5178
  DialogContent,
5026
5179
  DialogActions,
@@ -5033,12 +5186,12 @@ import {
5033
5186
  Typography as Typography4,
5034
5187
  Avatar as Avatar4,
5035
5188
  Radio,
5036
- Box as Box7,
5189
+ Box as Box8,
5037
5190
  Divider
5038
5191
  } from "@mui/material";
5039
5192
  import { Folder as FolderIcon2, Inbox as InboxIcon } from "lucide-react";
5040
5193
  import { useTheme as useTheme7 } from "@mui/material/styles";
5041
- import { jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
5194
+ import { jsx as jsx11, jsxs as jsxs8 } from "react/jsx-runtime";
5042
5195
  var MoveConversationModal = ({
5043
5196
  open,
5044
5197
  onClose,
@@ -5048,7 +5201,7 @@ var MoveConversationModal = ({
5048
5201
  const theme = useTheme7();
5049
5202
  const { projects, _hasHydrated, hydrate } = useProjectStore();
5050
5203
  const { moveConversationToProject } = useConversationStore();
5051
- const [selectedProjectId, setSelectedProjectId] = useState9(
5204
+ const [selectedProjectId, setSelectedProjectId] = useState10(
5052
5205
  currentProjectId
5053
5206
  );
5054
5207
  useEffect8(() => {
@@ -5075,8 +5228,8 @@ var MoveConversationModal = ({
5075
5228
  };
5076
5229
  const conversationCount = conversations.length;
5077
5230
  const isMultiple = conversationCount > 1;
5078
- return /* @__PURE__ */ jsxs7(
5079
- Dialog,
5231
+ return /* @__PURE__ */ jsxs8(
5232
+ Dialog2,
5080
5233
  {
5081
5234
  open,
5082
5235
  onClose,
@@ -5089,20 +5242,20 @@ var MoveConversationModal = ({
5089
5242
  }
5090
5243
  },
5091
5244
  children: [
5092
- /* @__PURE__ */ jsxs7(DialogTitle, { children: [
5245
+ /* @__PURE__ */ jsxs8(DialogTitle, { children: [
5093
5246
  "Move ",
5094
5247
  isMultiple ? `${conversationCount} Conversations` : "Conversation"
5095
5248
  ] }),
5096
- /* @__PURE__ */ jsxs7(DialogContent, { sx: { px: 3 }, children: [
5097
- /* @__PURE__ */ jsx10(Typography4, { variant: "body2", color: "text.secondary", sx: { mb: 2 }, children: isMultiple ? `Select a project to move ${conversationCount} conversations to:` : `Select a project to move "${conversations[0]?.name}" to:` }),
5098
- /* @__PURE__ */ jsxs7(List2, { children: [
5099
- /* @__PURE__ */ jsx10(ListItem2, { disablePadding: true, children: /* @__PURE__ */ jsxs7(
5249
+ /* @__PURE__ */ jsxs8(DialogContent, { sx: { px: 3 }, children: [
5250
+ /* @__PURE__ */ jsx11(Typography4, { variant: "body2", color: "text.secondary", sx: { mb: 2 }, children: isMultiple ? `Select a project to move ${conversationCount} conversations to:` : `Select a project to move "${conversations[0]?.name}" to:` }),
5251
+ /* @__PURE__ */ jsxs8(List2, { children: [
5252
+ /* @__PURE__ */ jsx11(ListItem2, { disablePadding: true, children: /* @__PURE__ */ jsxs8(
5100
5253
  ListItemButton,
5101
5254
  {
5102
5255
  onClick: () => setSelectedProjectId(null),
5103
5256
  selected: selectedProjectId === null,
5104
5257
  children: [
5105
- /* @__PURE__ */ jsx10(ListItemIcon, { children: /* @__PURE__ */ jsx10(
5258
+ /* @__PURE__ */ jsx11(ListItemIcon, { children: /* @__PURE__ */ jsx11(
5106
5259
  Radio,
5107
5260
  {
5108
5261
  checked: selectedProjectId === null,
@@ -5110,7 +5263,7 @@ var MoveConversationModal = ({
5110
5263
  size: "small"
5111
5264
  }
5112
5265
  ) }),
5113
- /* @__PURE__ */ jsx10(ListItemIcon, { children: /* @__PURE__ */ jsx10(
5266
+ /* @__PURE__ */ jsx11(ListItemIcon, { children: /* @__PURE__ */ jsx11(
5114
5267
  Avatar4,
5115
5268
  {
5116
5269
  sx: {
@@ -5118,10 +5271,10 @@ var MoveConversationModal = ({
5118
5271
  width: 32,
5119
5272
  height: 32
5120
5273
  },
5121
- children: /* @__PURE__ */ jsx10(InboxIcon, {})
5274
+ children: /* @__PURE__ */ jsx11(InboxIcon, {})
5122
5275
  }
5123
5276
  ) }),
5124
- /* @__PURE__ */ jsx10(
5277
+ /* @__PURE__ */ jsx11(
5125
5278
  ListItemText,
5126
5279
  {
5127
5280
  primary: "No Project",
@@ -5131,14 +5284,14 @@ var MoveConversationModal = ({
5131
5284
  ]
5132
5285
  }
5133
5286
  ) }),
5134
- /* @__PURE__ */ jsx10(Divider, { sx: { my: 1 } }),
5135
- projects.map((project) => /* @__PURE__ */ jsx10(ListItem2, { disablePadding: true, children: /* @__PURE__ */ jsxs7(
5287
+ /* @__PURE__ */ jsx11(Divider, { sx: { my: 1 } }),
5288
+ projects.map((project) => /* @__PURE__ */ jsx11(ListItem2, { disablePadding: true, children: /* @__PURE__ */ jsxs8(
5136
5289
  ListItemButton,
5137
5290
  {
5138
5291
  onClick: () => setSelectedProjectId(project.id),
5139
5292
  selected: selectedProjectId === project.id,
5140
5293
  children: [
5141
- /* @__PURE__ */ jsx10(ListItemIcon, { children: /* @__PURE__ */ jsx10(
5294
+ /* @__PURE__ */ jsx11(ListItemIcon, { children: /* @__PURE__ */ jsx11(
5142
5295
  Radio,
5143
5296
  {
5144
5297
  checked: selectedProjectId === project.id,
@@ -5146,7 +5299,7 @@ var MoveConversationModal = ({
5146
5299
  size: "small"
5147
5300
  }
5148
5301
  ) }),
5149
- /* @__PURE__ */ jsx10(ListItemIcon, { children: /* @__PURE__ */ jsx10(
5302
+ /* @__PURE__ */ jsx11(ListItemIcon, { children: /* @__PURE__ */ jsx11(
5150
5303
  Avatar4,
5151
5304
  {
5152
5305
  sx: {
@@ -5154,10 +5307,10 @@ var MoveConversationModal = ({
5154
5307
  width: 32,
5155
5308
  height: 32
5156
5309
  },
5157
- children: /* @__PURE__ */ jsx10(FolderIcon2, {})
5310
+ children: /* @__PURE__ */ jsx11(FolderIcon2, {})
5158
5311
  }
5159
5312
  ) }),
5160
- /* @__PURE__ */ jsx10(
5313
+ /* @__PURE__ */ jsx11(
5161
5314
  ListItemText,
5162
5315
  {
5163
5316
  primary: project.name,
@@ -5167,16 +5320,16 @@ var MoveConversationModal = ({
5167
5320
  ]
5168
5321
  }
5169
5322
  ) }, project.id)),
5170
- projects.length === 0 && /* @__PURE__ */ jsx10(Box7, { sx: {
5323
+ projects.length === 0 && /* @__PURE__ */ jsx11(Box8, { sx: {
5171
5324
  textAlign: "center",
5172
5325
  py: 2,
5173
5326
  color: theme.palette.text.secondary
5174
- }, children: /* @__PURE__ */ jsx10(Typography4, { variant: "body2", children: "No projects available. Create a project first to organize conversations." }) })
5327
+ }, children: /* @__PURE__ */ jsx11(Typography4, { variant: "body2", children: "No projects available. Create a project first to organize conversations." }) })
5175
5328
  ] })
5176
5329
  ] }),
5177
- /* @__PURE__ */ jsxs7(DialogActions, { sx: { px: 3, pb: 2 }, children: [
5178
- /* @__PURE__ */ jsx10(Button3, { onClick: onClose, children: "Cancel" }),
5179
- /* @__PURE__ */ jsxs7(
5330
+ /* @__PURE__ */ jsxs8(DialogActions, { sx: { px: 3, pb: 2 }, children: [
5331
+ /* @__PURE__ */ jsx11(Button3, { onClick: onClose, children: "Cancel" }),
5332
+ /* @__PURE__ */ jsxs8(
5180
5333
  Button3,
5181
5334
  {
5182
5335
  onClick: handleMove,
@@ -5196,26 +5349,26 @@ var MoveConversationModal = ({
5196
5349
  var move_conversation_modal_default = MoveConversationModal;
5197
5350
 
5198
5351
  // src/chat/simple-conversation-item.tsx
5199
- import { useState as useState10, useRef as useRef6, useEffect as useEffect9 } from "react";
5352
+ import { useState as useState11, useRef as useRef6, useEffect as useEffect9 } from "react";
5200
5353
  import {
5201
- Box as Box8,
5354
+ Box as Box9,
5202
5355
  Typography as Typography5,
5203
- IconButton as IconButton5,
5356
+ IconButton as IconButton6,
5204
5357
  Menu as Menu2,
5205
5358
  MenuItem as MenuItem2,
5206
5359
  ListItemIcon as ListItemIcon2,
5207
5360
  ListItemText as ListItemText2,
5208
5361
  useMediaQuery as useMediaQuery3,
5209
- TextField as TextField4,
5210
- Dialog as Dialog2,
5362
+ TextField as TextField5,
5363
+ Dialog as Dialog3,
5211
5364
  DialogTitle as DialogTitle2,
5212
5365
  DialogContent as DialogContent2,
5213
5366
  DialogActions as DialogActions2,
5214
5367
  Button as Button4
5215
5368
  } from "@mui/material";
5216
- import { MoreVertical as MoreVertIcon2, Pencil as EditIcon2, Trash2 as DeleteIcon2, GripVertical as DragIcon, MailOpen as MoveIcon } from "lucide-react";
5369
+ import { MoreVertical as MoreVertIcon2, Pencil as EditIcon3, Trash2 as DeleteIcon2, GripVertical as DragIcon, MailOpen as MoveIcon } from "lucide-react";
5217
5370
  import { useTheme as useTheme8, alpha as alpha4 } from "@mui/material/styles";
5218
- import { Fragment as Fragment5, jsx as jsx11, jsxs as jsxs8 } from "react/jsx-runtime";
5371
+ import { Fragment as Fragment5, jsx as jsx12, jsxs as jsxs9 } from "react/jsx-runtime";
5219
5372
  var SimpleConversationItem = ({
5220
5373
  conversation,
5221
5374
  isSelected,
@@ -5233,12 +5386,12 @@ var SimpleConversationItem = ({
5233
5386
  }) => {
5234
5387
  const theme = useTheme8();
5235
5388
  const isMobile = useMediaQuery3(theme.breakpoints.down("sm"));
5236
- const [anchorEl, setAnchorEl] = useState10(null);
5237
- const [isEditing, setIsEditing] = useState10(false);
5238
- const [editName, setEditName] = useState10(conversation.name);
5239
- const [isDragging, setIsDragging] = useState10(false);
5240
- const [isTouchDragging, setIsTouchDragging] = useState10(false);
5241
- const [showRenameDialog, setShowRenameDialog] = useState10(false);
5389
+ const [anchorEl, setAnchorEl] = useState11(null);
5390
+ const [isEditing, setIsEditing] = useState11(false);
5391
+ const [editName, setEditName] = useState11(conversation.name);
5392
+ const [isDragging, setIsDragging] = useState11(false);
5393
+ const [isTouchDragging, setIsTouchDragging] = useState11(false);
5394
+ const [showRenameDialog, setShowRenameDialog] = useState11(false);
5242
5395
  const longPressTimeoutRef = useRef6(null);
5243
5396
  const touchStartPointRef = useRef6(null);
5244
5397
  const activeTouchIdRef = useRef6(null);
@@ -5250,8 +5403,8 @@ var SimpleConversationItem = ({
5250
5403
  const regex = new RegExp(`(${query.trim()})`, "gi");
5251
5404
  const parts = text.split(regex);
5252
5405
  return parts.map(
5253
- (part, index) => regex.test(part) ? /* @__PURE__ */ jsx11(
5254
- Box8,
5406
+ (part, index) => regex.test(part) ? /* @__PURE__ */ jsx12(
5407
+ Box9,
5255
5408
  {
5256
5409
  component: "span",
5257
5410
  sx: {
@@ -5386,9 +5539,9 @@ var SimpleConversationItem = ({
5386
5539
  setIsTouchDragging(false);
5387
5540
  }
5388
5541
  }, [isTouchDragActive, isTouchDragging]);
5389
- return /* @__PURE__ */ jsxs8(Fragment5, { children: [
5390
- /* @__PURE__ */ jsxs8(
5391
- Box8,
5542
+ return /* @__PURE__ */ jsxs9(Fragment5, { children: [
5543
+ /* @__PURE__ */ jsxs9(
5544
+ Box9,
5392
5545
  {
5393
5546
  "data-project-id": conversation.projectId ?? "__ungrouped",
5394
5547
  draggable: !isMobile && !isEditing,
@@ -5440,7 +5593,7 @@ var SimpleConversationItem = ({
5440
5593
  }
5441
5594
  },
5442
5595
  children: [
5443
- !isMobile && !isEditing && /* @__PURE__ */ jsx11(
5596
+ !isMobile && !isEditing && /* @__PURE__ */ jsx12(
5444
5597
  DragIcon,
5445
5598
  {
5446
5599
  size: 16,
@@ -5448,9 +5601,9 @@ var SimpleConversationItem = ({
5448
5601
  style: { marginRight: 4, cursor: "grab" }
5449
5602
  }
5450
5603
  ),
5451
- /* @__PURE__ */ jsxs8(Box8, { sx: { flex: 1, minWidth: 0 }, children: [
5452
- isEditing ? /* @__PURE__ */ jsx11(
5453
- TextField4,
5604
+ /* @__PURE__ */ jsxs9(Box9, { sx: { flex: 1, minWidth: 0 }, children: [
5605
+ isEditing ? /* @__PURE__ */ jsx12(
5606
+ TextField5,
5454
5607
  {
5455
5608
  value: editName,
5456
5609
  onChange: (e) => setEditName(e.target.value),
@@ -5472,7 +5625,7 @@ var SimpleConversationItem = ({
5472
5625
  }
5473
5626
  }
5474
5627
  }
5475
- ) : /* @__PURE__ */ jsx11(
5628
+ ) : /* @__PURE__ */ jsx12(
5476
5629
  Typography5,
5477
5630
  {
5478
5631
  variant: "body2",
@@ -5487,7 +5640,7 @@ var SimpleConversationItem = ({
5487
5640
  children: highlightText(conversation.name, searchQuery)
5488
5641
  }
5489
5642
  ),
5490
- !isEditing && snippet && /* @__PURE__ */ jsx11(
5643
+ !isEditing && snippet && /* @__PURE__ */ jsx12(
5491
5644
  Typography5,
5492
5645
  {
5493
5646
  variant: "caption",
@@ -5506,8 +5659,8 @@ var SimpleConversationItem = ({
5506
5659
  }
5507
5660
  )
5508
5661
  ] }),
5509
- !isEditing && /* @__PURE__ */ jsx11(
5510
- IconButton5,
5662
+ !isEditing && /* @__PURE__ */ jsx12(
5663
+ IconButton6,
5511
5664
  {
5512
5665
  onClick: handleMenuOpen,
5513
5666
  size: "small",
@@ -5535,10 +5688,10 @@ var SimpleConversationItem = ({
5535
5688
  }
5536
5689
  }
5537
5690
  },
5538
- children: /* @__PURE__ */ jsx11(MoreVertIcon2, { size: 16 })
5691
+ children: /* @__PURE__ */ jsx12(MoreVertIcon2, { size: 16 })
5539
5692
  }
5540
5693
  ),
5541
- /* @__PURE__ */ jsxs8(
5694
+ /* @__PURE__ */ jsxs9(
5542
5695
  Menu2,
5543
5696
  {
5544
5697
  anchorEl,
@@ -5565,17 +5718,17 @@ var SimpleConversationItem = ({
5565
5718
  }
5566
5719
  },
5567
5720
  children: [
5568
- onRename && /* @__PURE__ */ jsxs8(MenuItem2, { onClick: handleEdit, children: [
5569
- /* @__PURE__ */ jsx11(ListItemIcon2, { children: /* @__PURE__ */ jsx11(EditIcon2, { size: 16 }) }),
5570
- /* @__PURE__ */ jsx11(ListItemText2, { children: "Rename" })
5721
+ onRename && /* @__PURE__ */ jsxs9(MenuItem2, { onClick: handleEdit, children: [
5722
+ /* @__PURE__ */ jsx12(ListItemIcon2, { children: /* @__PURE__ */ jsx12(EditIcon3, { size: 16 }) }),
5723
+ /* @__PURE__ */ jsx12(ListItemText2, { children: "Rename" })
5571
5724
  ] }),
5572
- onMove && /* @__PURE__ */ jsxs8(MenuItem2, { onClick: handleMove, children: [
5573
- /* @__PURE__ */ jsx11(ListItemIcon2, { children: /* @__PURE__ */ jsx11(MoveIcon, { size: 16 }) }),
5574
- /* @__PURE__ */ jsx11(ListItemText2, { children: "Move to Project" })
5725
+ onMove && /* @__PURE__ */ jsxs9(MenuItem2, { onClick: handleMove, children: [
5726
+ /* @__PURE__ */ jsx12(ListItemIcon2, { children: /* @__PURE__ */ jsx12(MoveIcon, { size: 16 }) }),
5727
+ /* @__PURE__ */ jsx12(ListItemText2, { children: "Move to Project" })
5575
5728
  ] }),
5576
- /* @__PURE__ */ jsxs8(MenuItem2, { onClick: handleDelete, children: [
5577
- /* @__PURE__ */ jsx11(ListItemIcon2, { children: /* @__PURE__ */ jsx11(DeleteIcon2, { size: 16 }) }),
5578
- /* @__PURE__ */ jsx11(ListItemText2, { children: "Delete" })
5729
+ /* @__PURE__ */ jsxs9(MenuItem2, { onClick: handleDelete, children: [
5730
+ /* @__PURE__ */ jsx12(ListItemIcon2, { children: /* @__PURE__ */ jsx12(DeleteIcon2, { size: 16 }) }),
5731
+ /* @__PURE__ */ jsx12(ListItemText2, { children: "Delete" })
5579
5732
  ] })
5580
5733
  ]
5581
5734
  }
@@ -5583,8 +5736,8 @@ var SimpleConversationItem = ({
5583
5736
  ]
5584
5737
  }
5585
5738
  ),
5586
- isMobile && /* @__PURE__ */ jsxs8(
5587
- Dialog2,
5739
+ isMobile && /* @__PURE__ */ jsxs9(
5740
+ Dialog3,
5588
5741
  {
5589
5742
  open: showRenameDialog,
5590
5743
  onClose: () => {
@@ -5599,9 +5752,9 @@ var SimpleConversationItem = ({
5599
5752
  }
5600
5753
  },
5601
5754
  children: [
5602
- /* @__PURE__ */ jsx11(DialogTitle2, { sx: { pb: 1 }, children: "Rename Conversation" }),
5603
- /* @__PURE__ */ jsx11(DialogContent2, { children: /* @__PURE__ */ jsx11(
5604
- TextField4,
5755
+ /* @__PURE__ */ jsx12(DialogTitle2, { sx: { pb: 1 }, children: "Rename Conversation" }),
5756
+ /* @__PURE__ */ jsx12(DialogContent2, { children: /* @__PURE__ */ jsx12(
5757
+ TextField5,
5605
5758
  {
5606
5759
  value: editName,
5607
5760
  onChange: (e) => setEditName(e.target.value),
@@ -5613,8 +5766,8 @@ var SimpleConversationItem = ({
5613
5766
  }
5614
5767
  }
5615
5768
  ) }),
5616
- /* @__PURE__ */ jsxs8(DialogActions2, { sx: { px: 3, pb: 2 }, children: [
5617
- /* @__PURE__ */ jsx11(
5769
+ /* @__PURE__ */ jsxs9(DialogActions2, { sx: { px: 3, pb: 2 }, children: [
5770
+ /* @__PURE__ */ jsx12(
5618
5771
  Button4,
5619
5772
  {
5620
5773
  onClick: () => {
@@ -5624,7 +5777,7 @@ var SimpleConversationItem = ({
5624
5777
  children: "Cancel"
5625
5778
  }
5626
5779
  ),
5627
- /* @__PURE__ */ jsx11(
5780
+ /* @__PURE__ */ jsx12(
5628
5781
  Button4,
5629
5782
  {
5630
5783
  onClick: () => {
@@ -5645,20 +5798,20 @@ var SimpleConversationItem = ({
5645
5798
  var simple_conversation_item_default = SimpleConversationItem;
5646
5799
 
5647
5800
  // src/chat/project-header.tsx
5648
- import { useRef as useRef7, useState as useState11 } from "react";
5801
+ import { useRef as useRef7, useState as useState12 } from "react";
5649
5802
  import {
5650
- Box as Box9,
5803
+ Box as Box10,
5651
5804
  Typography as Typography6,
5652
- IconButton as IconButton6,
5805
+ IconButton as IconButton7,
5653
5806
  Avatar as Avatar5,
5654
5807
  Chip as Chip3,
5655
- Tooltip as Tooltip3,
5656
- TextField as TextField5,
5808
+ Tooltip as Tooltip4,
5809
+ TextField as TextField6,
5657
5810
  alpha as alpha5
5658
5811
  } from "@mui/material";
5659
- import { ChevronDown as ExpandMoreIcon2, ChevronUp as ExpandLessIcon, Plus as AddIcon3, Folder as FolderIcon3, FolderOpen as FolderOpenIcon, Inbox as InboxIcon2, X as CloseIcon3, Check as CheckIcon2 } from "lucide-react";
5812
+ import { ChevronDown as ExpandMoreIcon2, ChevronUp as ExpandLessIcon, Plus as AddIcon3, Folder as FolderIcon3, FolderOpen as FolderOpenIcon, Inbox as InboxIcon2, X as CloseIcon4, Check as CheckIcon3 } from "lucide-react";
5660
5813
  import { useTheme as useTheme9 } from "@mui/material/styles";
5661
- import { jsx as jsx12, jsxs as jsxs9 } from "react/jsx-runtime";
5814
+ import { jsx as jsx13, jsxs as jsxs10 } from "react/jsx-runtime";
5662
5815
  var ProjectHeader = ({
5663
5816
  projectId,
5664
5817
  projectName,
@@ -5675,9 +5828,9 @@ var ProjectHeader = ({
5675
5828
  const theme = useTheme9();
5676
5829
  const { createNewConversation } = useConversationStore();
5677
5830
  const { renameProject } = useProjectStore();
5678
- const [isHovered, setIsHovered] = useState11(false);
5679
- const [isDragOver, setIsDragOver] = useState11(false);
5680
- const [renameDraft, setRenameDraft] = useState11(projectName);
5831
+ const [isHovered, setIsHovered] = useState12(false);
5832
+ const [isDragOver, setIsDragOver] = useState12(false);
5833
+ const [renameDraft, setRenameDraft] = useState12(projectName);
5681
5834
  const renameActionRef = useRef7("none");
5682
5835
  const isUngrouped = projectId === null;
5683
5836
  const Icon = isCollapsed ? FolderIcon3 : FolderOpenIcon;
@@ -5724,8 +5877,8 @@ var ProjectHeader = ({
5724
5877
  setRenameDraft(projectName);
5725
5878
  onRenameComplete?.();
5726
5879
  };
5727
- return /* @__PURE__ */ jsxs9(
5728
- Box9,
5880
+ return /* @__PURE__ */ jsxs10(
5881
+ Box10,
5729
5882
  {
5730
5883
  "data-project-id": projectId ?? "__ungrouped",
5731
5884
  onMouseEnter: () => setIsHovered(true),
@@ -5751,7 +5904,7 @@ var ProjectHeader = ({
5751
5904
  } : {}
5752
5905
  },
5753
5906
  children: [
5754
- /* @__PURE__ */ jsx12(
5907
+ /* @__PURE__ */ jsx13(
5755
5908
  Avatar5,
5756
5909
  {
5757
5910
  sx: {
@@ -5760,18 +5913,18 @@ var ProjectHeader = ({
5760
5913
  height: 28,
5761
5914
  mr: 1.5
5762
5915
  },
5763
- children: isUngrouped ? /* @__PURE__ */ jsx12(
5916
+ children: isUngrouped ? /* @__PURE__ */ jsx13(
5764
5917
  InboxIcon2,
5765
5918
  {
5766
5919
  size: 16,
5767
5920
  color: theme.palette.text.disabled,
5768
5921
  style: { opacity: 0.7 }
5769
5922
  }
5770
- ) : /* @__PURE__ */ jsx12(Icon, { size: 16 })
5923
+ ) : /* @__PURE__ */ jsx13(Icon, { size: 16 })
5771
5924
  }
5772
5925
  ),
5773
- isRenaming && !isUngrouped ? /* @__PURE__ */ jsx12(
5774
- TextField5,
5926
+ isRenaming && !isUngrouped ? /* @__PURE__ */ jsx13(
5927
+ TextField6,
5775
5928
  {
5776
5929
  value: renameDraft,
5777
5930
  onChange: (e) => setRenameDraft(e.target.value),
@@ -5817,7 +5970,7 @@ var ProjectHeader = ({
5817
5970
  }
5818
5971
  }
5819
5972
  }
5820
- ) : /* @__PURE__ */ jsxs9(
5973
+ ) : /* @__PURE__ */ jsxs10(
5821
5974
  Typography6,
5822
5975
  {
5823
5976
  variant: "subtitle2",
@@ -5830,7 +5983,7 @@ var ProjectHeader = ({
5830
5983
  },
5831
5984
  children: [
5832
5985
  projectName,
5833
- isDragOver && /* @__PURE__ */ jsx12(
5986
+ isDragOver && /* @__PURE__ */ jsx13(
5834
5987
  Typography6,
5835
5988
  {
5836
5989
  component: "span",
@@ -5846,7 +5999,7 @@ var ProjectHeader = ({
5846
5999
  ]
5847
6000
  }
5848
6001
  ),
5849
- /* @__PURE__ */ jsx12(
6002
+ /* @__PURE__ */ jsx13(
5850
6003
  Chip3,
5851
6004
  {
5852
6005
  label: conversationCount,
@@ -5866,9 +6019,9 @@ var ProjectHeader = ({
5866
6019
  }
5867
6020
  }
5868
6021
  ),
5869
- isRenaming && !isUngrouped && /* @__PURE__ */ jsxs9(Box9, { sx: { display: "flex", alignItems: "center", gap: 0.5, ml: 1 }, children: [
5870
- /* @__PURE__ */ jsx12(Tooltip3, { title: "Cancel and remove", children: /* @__PURE__ */ jsx12(
5871
- IconButton6,
6022
+ isRenaming && !isUngrouped && /* @__PURE__ */ jsxs10(Box10, { sx: { display: "flex", alignItems: "center", gap: 0.5, ml: 1 }, children: [
6023
+ /* @__PURE__ */ jsx13(Tooltip4, { title: "Cancel and remove", children: /* @__PURE__ */ jsx13(
6024
+ IconButton7,
5872
6025
  {
5873
6026
  size: "small",
5874
6027
  onMouseDown: (e) => {
@@ -5877,11 +6030,11 @@ var ProjectHeader = ({
5877
6030
  onRenameCancelDelete ? onRenameCancelDelete() : cancelRename();
5878
6031
  },
5879
6032
  sx: { color: alpha5(theme.palette.error.main, 0.9) },
5880
- children: /* @__PURE__ */ jsx12(CloseIcon3, { size: 16 })
6033
+ children: /* @__PURE__ */ jsx13(CloseIcon4, { size: 16 })
5881
6034
  }
5882
6035
  ) }),
5883
- /* @__PURE__ */ jsx12(Tooltip3, { title: "Save", children: /* @__PURE__ */ jsx12(
5884
- IconButton6,
6036
+ /* @__PURE__ */ jsx13(Tooltip4, { title: "Save", children: /* @__PURE__ */ jsx13(
6037
+ IconButton7,
5885
6038
  {
5886
6039
  size: "small",
5887
6040
  onMouseDown: (e) => {
@@ -5890,12 +6043,12 @@ var ProjectHeader = ({
5890
6043
  commitRename();
5891
6044
  },
5892
6045
  sx: { color: theme.palette.success.main },
5893
- children: /* @__PURE__ */ jsx12(CheckIcon2, { size: 16 })
6046
+ children: /* @__PURE__ */ jsx13(CheckIcon3, { size: 16 })
5894
6047
  }
5895
6048
  ) })
5896
6049
  ] }),
5897
- isHovered && !isDragOver && !isUngrouped && !isRenaming && /* @__PURE__ */ jsx12(Tooltip3, { title: `Add conversation to ${projectName.toLowerCase()}`, arrow: true, children: /* @__PURE__ */ jsx12(
5898
- IconButton6,
6050
+ isHovered && !isDragOver && !isUngrouped && !isRenaming && /* @__PURE__ */ jsx13(Tooltip4, { title: `Add conversation to ${projectName.toLowerCase()}`, arrow: true, children: /* @__PURE__ */ jsx13(
6051
+ IconButton7,
5899
6052
  {
5900
6053
  onClick: handleAddConversation,
5901
6054
  size: "small",
@@ -5911,18 +6064,18 @@ var ProjectHeader = ({
5911
6064
  },
5912
6065
  transition: "all 0.2s ease"
5913
6066
  },
5914
- children: /* @__PURE__ */ jsx12(AddIcon3, { size: 16 })
6067
+ children: /* @__PURE__ */ jsx13(AddIcon3, { size: 16 })
5915
6068
  }
5916
6069
  ) }),
5917
- !isUngrouped && !isRenaming && /* @__PURE__ */ jsx12(
5918
- IconButton6,
6070
+ !isUngrouped && !isRenaming && /* @__PURE__ */ jsx13(
6071
+ IconButton7,
5919
6072
  {
5920
6073
  size: "small",
5921
6074
  sx: {
5922
6075
  color: theme.palette.text.secondary,
5923
6076
  transition: "transform 0.2s ease"
5924
6077
  },
5925
- children: isCollapsed ? /* @__PURE__ */ jsx12(ExpandMoreIcon2, { size: 16 }) : /* @__PURE__ */ jsx12(ExpandLessIcon, { size: 16 })
6078
+ children: isCollapsed ? /* @__PURE__ */ jsx13(ExpandMoreIcon2, { size: 16 }) : /* @__PURE__ */ jsx13(ExpandLessIcon, { size: 16 })
5926
6079
  }
5927
6080
  )
5928
6081
  ]
@@ -5944,7 +6097,7 @@ var TOOLTIP_COPY = {
5944
6097
  var tooltip = (key) => TOOLTIP_COPY[key];
5945
6098
 
5946
6099
  // src/chat/conversation-drawer.tsx
5947
- import { Fragment as Fragment6, jsx as jsx13, jsxs as jsxs10 } from "react/jsx-runtime";
6100
+ import { Fragment as Fragment6, jsx as jsx14, jsxs as jsxs11 } from "react/jsx-runtime";
5948
6101
  var BANDIT_AVATAR = "https://cdn.burtson.ai/images/bandit-head.png";
5949
6102
  var coerceOptionalString = (value) => {
5950
6103
  if (typeof value !== "string") return void 0;
@@ -5995,16 +6148,16 @@ var ConversationDrawer = ({ open, onClose }) => {
5995
6148
  createProject,
5996
6149
  deleteProject
5997
6150
  } = useProjectStore();
5998
- const [projectManagementOpen, setProjectManagementOpen] = useState12(false);
5999
- const [memoryModalOpen, setMemoryModalOpen] = useState12(false);
6000
- const [collapsedProjects, setCollapsedProjects] = useState12(/* @__PURE__ */ new Set());
6151
+ const [projectManagementOpen, setProjectManagementOpen] = useState13(false);
6152
+ const [memoryModalOpen, setMemoryModalOpen] = useState13(false);
6153
+ const [collapsedProjects, setCollapsedProjects] = useState13(/* @__PURE__ */ new Set());
6001
6154
  const didInitCollapseRef = useRef8(false);
6002
- const [searchQuery, setSearchQuery] = useState12("");
6003
- const [menuAnchorEl, setMenuAnchorEl] = useState12(null);
6004
- const [clearConfirmOpen, setClearConfirmOpen] = useState12(false);
6005
- const [moveModalOpen, setMoveModalOpen] = useState12(false);
6006
- const [conversationToMove, setConversationToMove] = useState12(null);
6007
- const [renameProjectId, setRenameProjectId] = useState12(null);
6155
+ const [searchQuery, setSearchQuery] = useState13("");
6156
+ const [menuAnchorEl, setMenuAnchorEl] = useState13(null);
6157
+ const [clearConfirmOpen, setClearConfirmOpen] = useState13(false);
6158
+ const [moveModalOpen, setMoveModalOpen] = useState13(false);
6159
+ const [conversationToMove, setConversationToMove] = useState13(null);
6160
+ const [renameProjectId, setRenameProjectId] = useState13(null);
6008
6161
  const getCustomClaim = useCallback4((key) => {
6009
6162
  if (!user) return void 0;
6010
6163
  const record = user;
@@ -6037,7 +6190,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6037
6190
  }
6038
6191
  return void 0;
6039
6192
  }, [user, userDisplayName]);
6040
- const [avatarImage, setAvatarImage] = useState12(BANDIT_AVATAR);
6193
+ const [avatarImage, setAvatarImage] = useState13(BANDIT_AVATAR);
6041
6194
  useEffect10(() => {
6042
6195
  const fresh = readPersistedToken();
6043
6196
  const store = useAuthenticationStore.getState();
@@ -6197,8 +6350,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6197
6350
  setMoveModalOpen(false);
6198
6351
  setConversationToMove(null);
6199
6352
  };
6200
- return /* @__PURE__ */ jsxs10(Fragment6, { children: [
6201
- /* @__PURE__ */ jsxs10(
6353
+ return /* @__PURE__ */ jsxs11(Fragment6, { children: [
6354
+ /* @__PURE__ */ jsxs11(
6202
6355
  Drawer,
6203
6356
  {
6204
6357
  anchor: "left",
@@ -6240,8 +6393,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6240
6393
  }
6241
6394
  },
6242
6395
  children: [
6243
- /* @__PURE__ */ jsxs10(
6244
- Box10,
6396
+ /* @__PURE__ */ jsxs11(
6397
+ Box11,
6245
6398
  {
6246
6399
  sx: {
6247
6400
  p: 2,
@@ -6252,8 +6405,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6252
6405
  gap: 1
6253
6406
  },
6254
6407
  children: [
6255
- /* @__PURE__ */ jsx13(Tooltip4, { title: "Memories", arrow: true, children: /* @__PURE__ */ jsx13(
6256
- IconButton7,
6408
+ /* @__PURE__ */ jsx14(Tooltip5, { title: "Memories", arrow: true, children: /* @__PURE__ */ jsx14(
6409
+ IconButton8,
6257
6410
  {
6258
6411
  onClick: () => setMemoryModalOpen(true),
6259
6412
  size: "small",
@@ -6265,11 +6418,11 @@ var ConversationDrawer = ({ open, onClose }) => {
6265
6418
  bgcolor: alpha6(theme.palette.primary.main, 0.1)
6266
6419
  }
6267
6420
  },
6268
- children: /* @__PURE__ */ jsx13(MemoryIcon, {})
6421
+ children: /* @__PURE__ */ jsx14(MemoryIcon, {})
6269
6422
  }
6270
6423
  ) }),
6271
- /* @__PURE__ */ jsx13(Tooltip4, { title: tooltip("manageProjects"), arrow: true, children: /* @__PURE__ */ jsx13(
6272
- IconButton7,
6424
+ /* @__PURE__ */ jsx14(Tooltip5, { title: tooltip("manageProjects"), arrow: true, children: /* @__PURE__ */ jsx14(
6425
+ IconButton8,
6273
6426
  {
6274
6427
  onClick: () => setProjectManagementOpen(true),
6275
6428
  size: "small",
@@ -6281,11 +6434,11 @@ var ConversationDrawer = ({ open, onClose }) => {
6281
6434
  bgcolor: alpha6(theme.palette.primary.main, 0.1)
6282
6435
  }
6283
6436
  },
6284
- children: /* @__PURE__ */ jsx13(FolderIcon4, {})
6437
+ children: /* @__PURE__ */ jsx14(FolderIcon4, {})
6285
6438
  }
6286
6439
  ) }),
6287
- /* @__PURE__ */ jsx13(Tooltip4, { title: tooltip("conversationOptions"), arrow: true, children: /* @__PURE__ */ jsx13(
6288
- IconButton7,
6440
+ /* @__PURE__ */ jsx14(Tooltip5, { title: tooltip("conversationOptions"), arrow: true, children: /* @__PURE__ */ jsx14(
6441
+ IconButton8,
6289
6442
  {
6290
6443
  onClick: handleMenuOpen,
6291
6444
  size: "small",
@@ -6297,11 +6450,11 @@ var ConversationDrawer = ({ open, onClose }) => {
6297
6450
  bgcolor: alpha6(theme.palette.text.primary, 0.1)
6298
6451
  }
6299
6452
  },
6300
- children: /* @__PURE__ */ jsx13(MoreVertIcon3, {})
6453
+ children: /* @__PURE__ */ jsx14(MoreVertIcon3, {})
6301
6454
  }
6302
6455
  ) }),
6303
- isMobile && /* @__PURE__ */ jsx13(Tooltip4, { title: tooltip("closeConversationsPanel"), children: /* @__PURE__ */ jsx13(
6304
- IconButton7,
6456
+ isMobile && /* @__PURE__ */ jsx14(Tooltip5, { title: tooltip("closeConversationsPanel"), children: /* @__PURE__ */ jsx14(
6457
+ IconButton8,
6305
6458
  {
6306
6459
  onClick: (e) => {
6307
6460
  e.preventDefault();
@@ -6317,14 +6470,14 @@ var ConversationDrawer = ({ open, onClose }) => {
6317
6470
  bgcolor: alpha6(theme.palette.error.main, 0.1)
6318
6471
  }
6319
6472
  },
6320
- children: /* @__PURE__ */ jsx13(CloseIcon4, {})
6473
+ children: /* @__PURE__ */ jsx14(CloseIcon5, {})
6321
6474
  }
6322
6475
  ) })
6323
6476
  ]
6324
6477
  }
6325
6478
  ),
6326
- /* @__PURE__ */ jsx13(Box10, { sx: { p: 2, pb: 1 }, children: /* @__PURE__ */ jsx13(
6327
- TextField6,
6479
+ /* @__PURE__ */ jsx14(Box11, { sx: { p: 2, pb: 1 }, children: /* @__PURE__ */ jsx14(
6480
+ TextField7,
6328
6481
  {
6329
6482
  fullWidth: true,
6330
6483
  size: "small",
@@ -6333,16 +6486,16 @@ var ConversationDrawer = ({ open, onClose }) => {
6333
6486
  onChange: (e) => setSearchQuery(e.target.value),
6334
6487
  variant: "outlined",
6335
6488
  InputProps: {
6336
- startAdornment: /* @__PURE__ */ jsx13(InputAdornment, { position: "start", children: /* @__PURE__ */ jsx13(SearchIcon, { size: 16, color: theme.palette.text.secondary }) }),
6337
- endAdornment: searchQuery && /* @__PURE__ */ jsx13(InputAdornment, { position: "end", children: /* @__PURE__ */ jsx13(Tooltip4, { title: tooltip("clearSearch"), children: /* @__PURE__ */ jsx13(
6338
- IconButton7,
6489
+ startAdornment: /* @__PURE__ */ jsx14(InputAdornment, { position: "start", children: /* @__PURE__ */ jsx14(SearchIcon, { size: 16, color: theme.palette.text.secondary }) }),
6490
+ endAdornment: searchQuery && /* @__PURE__ */ jsx14(InputAdornment, { position: "end", children: /* @__PURE__ */ jsx14(Tooltip5, { title: tooltip("clearSearch"), children: /* @__PURE__ */ jsx14(
6491
+ IconButton8,
6339
6492
  {
6340
6493
  onClick: handleSearchClear,
6341
6494
  size: "small",
6342
6495
  edge: "end",
6343
6496
  "aria-label": tooltip("clearSearch"),
6344
6497
  sx: { color: theme.palette.text.secondary },
6345
- children: /* @__PURE__ */ jsx13(ClearIcon, { size: 16 })
6498
+ children: /* @__PURE__ */ jsx14(ClearIcon, { size: 16 })
6346
6499
  }
6347
6500
  ) }) })
6348
6501
  },
@@ -6359,9 +6512,9 @@ var ConversationDrawer = ({ open, onClose }) => {
6359
6512
  }
6360
6513
  }
6361
6514
  ) }),
6362
- /* @__PURE__ */ jsxs10(Box10, { sx: { flex: 1, overflow: "auto", display: "flex", flexDirection: "column" }, children: [
6363
- /* @__PURE__ */ jsxs10(
6364
- Box10,
6515
+ /* @__PURE__ */ jsxs11(Box11, { sx: { flex: 1, overflow: "auto", display: "flex", flexDirection: "column" }, children: [
6516
+ /* @__PURE__ */ jsxs11(
6517
+ Box11,
6365
6518
  {
6366
6519
  onClick: async () => {
6367
6520
  const names = new Set(projects.map((p) => p.name));
@@ -6395,8 +6548,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6395
6548
  "&:hover": { bgcolor: alpha6(theme.palette.text.primary, 0.04) }
6396
6549
  },
6397
6550
  children: [
6398
- /* @__PURE__ */ jsx13(
6399
- Box10,
6551
+ /* @__PURE__ */ jsx14(
6552
+ Box11,
6400
6553
  {
6401
6554
  sx: {
6402
6555
  width: 28,
@@ -6408,10 +6561,10 @@ var ConversationDrawer = ({ open, onClose }) => {
6408
6561
  justifyContent: "center",
6409
6562
  flexShrink: 0
6410
6563
  },
6411
- children: /* @__PURE__ */ jsx13(FolderIcon4, { size: 16, color: theme.palette.success.main })
6564
+ children: /* @__PURE__ */ jsx14(FolderIcon4, { size: 16, color: theme.palette.success.main })
6412
6565
  }
6413
6566
  ),
6414
- /* @__PURE__ */ jsx13(
6567
+ /* @__PURE__ */ jsx14(
6415
6568
  Typography7,
6416
6569
  {
6417
6570
  variant: "subtitle2",
@@ -6419,22 +6572,22 @@ var ConversationDrawer = ({ open, onClose }) => {
6419
6572
  children: "New Project"
6420
6573
  }
6421
6574
  ),
6422
- /* @__PURE__ */ jsx13(Tooltip4, { title: tooltip("addProject"), arrow: true, children: /* @__PURE__ */ jsx13(
6423
- IconButton7,
6575
+ /* @__PURE__ */ jsx14(Tooltip5, { title: tooltip("addProject"), arrow: true, children: /* @__PURE__ */ jsx14(
6576
+ IconButton8,
6424
6577
  {
6425
6578
  size: "small",
6426
6579
  "aria-label": tooltip("addProject"),
6427
6580
  sx: { color: theme.palette.success.main },
6428
- children: /* @__PURE__ */ jsx13(AddIcon4, { size: 16 })
6581
+ children: /* @__PURE__ */ jsx14(AddIcon4, { size: 16 })
6429
6582
  }
6430
6583
  ) })
6431
6584
  ]
6432
6585
  }
6433
6586
  ),
6434
- /* @__PURE__ */ jsx13(Divider2, { sx: { opacity: 0.3 } }),
6435
- filteredProjectGroups.map((group, index) => /* @__PURE__ */ jsxs10(Box10, { children: [
6436
- group.id === null && filteredProjectGroups.length > 1 && /* @__PURE__ */ jsxs10(
6437
- Box10,
6587
+ /* @__PURE__ */ jsx14(Divider2, { sx: { opacity: 0.3 } }),
6588
+ filteredProjectGroups.map((group, index) => /* @__PURE__ */ jsxs11(Box11, { children: [
6589
+ group.id === null && filteredProjectGroups.length > 1 && /* @__PURE__ */ jsxs11(
6590
+ Box11,
6438
6591
  {
6439
6592
  sx: {
6440
6593
  py: 2,
@@ -6444,9 +6597,9 @@ var ConversationDrawer = ({ open, onClose }) => {
6444
6597
  gap: 2
6445
6598
  },
6446
6599
  children: [
6447
- /* @__PURE__ */ jsx13(Divider2, { sx: { flex: 1, opacity: 0.6 } }),
6448
- /* @__PURE__ */ jsxs10(Box10, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
6449
- /* @__PURE__ */ jsx13(
6600
+ /* @__PURE__ */ jsx14(Divider2, { sx: { flex: 1, opacity: 0.6 } }),
6601
+ /* @__PURE__ */ jsxs11(Box11, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
6602
+ /* @__PURE__ */ jsx14(
6450
6603
  InboxIcon3,
6451
6604
  {
6452
6605
  size: 14,
@@ -6454,7 +6607,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6454
6607
  style: { opacity: 0.7 }
6455
6608
  }
6456
6609
  ),
6457
- /* @__PURE__ */ jsx13(
6610
+ /* @__PURE__ */ jsx14(
6458
6611
  Typography7,
6459
6612
  {
6460
6613
  variant: "caption",
@@ -6469,12 +6622,12 @@ var ConversationDrawer = ({ open, onClose }) => {
6469
6622
  }
6470
6623
  )
6471
6624
  ] }),
6472
- /* @__PURE__ */ jsx13(Divider2, { sx: { flex: 1, opacity: 0.6 } })
6625
+ /* @__PURE__ */ jsx14(Divider2, { sx: { flex: 1, opacity: 0.6 } })
6473
6626
  ]
6474
6627
  }
6475
6628
  ),
6476
- group.id !== null ? /* @__PURE__ */ jsxs10(Fragment6, { children: [
6477
- /* @__PURE__ */ jsx13(
6629
+ group.id !== null ? /* @__PURE__ */ jsxs11(Fragment6, { children: [
6630
+ /* @__PURE__ */ jsx14(
6478
6631
  project_header_default,
6479
6632
  {
6480
6633
  projectId: group.id,
@@ -6503,8 +6656,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6503
6656
  }
6504
6657
  }
6505
6658
  ),
6506
- /* @__PURE__ */ jsx13(Collapse2, { in: !group.collapsed, children: /* @__PURE__ */ jsxs10(Box10, { sx: { pb: 1 }, children: [
6507
- group.conversations.map((conversation) => /* @__PURE__ */ jsx13(
6659
+ /* @__PURE__ */ jsx14(Collapse2, { in: !group.collapsed, children: /* @__PURE__ */ jsxs11(Box11, { sx: { pb: 1 }, children: [
6660
+ group.conversations.map((conversation) => /* @__PURE__ */ jsx14(
6508
6661
  simple_conversation_item_default,
6509
6662
  {
6510
6663
  conversation,
@@ -6524,8 +6677,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6524
6677
  },
6525
6678
  conversation.id
6526
6679
  )),
6527
- group.conversations.length === 0 && !group.collapsed && group.id !== null && /* @__PURE__ */ jsxs10(
6528
- Box10,
6680
+ group.conversations.length === 0 && !group.collapsed && group.id !== null && /* @__PURE__ */ jsxs11(
6681
+ Box11,
6529
6682
  {
6530
6683
  sx: {
6531
6684
  p: 3,
@@ -6533,17 +6686,17 @@ var ConversationDrawer = ({ open, onClose }) => {
6533
6686
  color: theme.palette.text.secondary
6534
6687
  },
6535
6688
  children: [
6536
- /* @__PURE__ */ jsx13(Typography7, { variant: "body2", children: "No conversations in this project yet" }),
6537
- /* @__PURE__ */ jsx13(Typography7, { variant: "caption", sx: { mt: 1, display: "block" }, children: "Drag conversations here or use the + button above" })
6689
+ /* @__PURE__ */ jsx14(Typography7, { variant: "body2", children: "No conversations in this project yet" }),
6690
+ /* @__PURE__ */ jsx14(Typography7, { variant: "caption", sx: { mt: 1, display: "block" }, children: "Drag conversations here or use the + button above" })
6538
6691
  ]
6539
6692
  }
6540
6693
  )
6541
6694
  ] }) }),
6542
- /* @__PURE__ */ jsx13(Divider2, { sx: { opacity: 0.3 } })
6695
+ /* @__PURE__ */ jsx14(Divider2, { sx: { opacity: 0.3 } })
6543
6696
  ] }) : (
6544
6697
  // Special handling for ungrouped - no header, just conversations in scrollable area
6545
- /* @__PURE__ */ jsx13(
6546
- Box10,
6698
+ /* @__PURE__ */ jsx14(
6699
+ Box11,
6547
6700
  {
6548
6701
  sx: {
6549
6702
  minHeight: 0,
@@ -6556,7 +6709,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6556
6709
  mx: 1,
6557
6710
  mb: 1
6558
6711
  },
6559
- children: group.conversations.map((conversation) => /* @__PURE__ */ jsx13(
6712
+ children: group.conversations.map((conversation) => /* @__PURE__ */ jsx14(
6560
6713
  simple_conversation_item_default,
6561
6714
  {
6562
6715
  conversation,
@@ -6580,8 +6733,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6580
6733
  )
6581
6734
  )
6582
6735
  ] }, group.id || "ungrouped")),
6583
- filteredProjectGroups.length === 0 && /* @__PURE__ */ jsxs10(
6584
- Box10,
6736
+ filteredProjectGroups.length === 0 && /* @__PURE__ */ jsxs11(
6737
+ Box11,
6585
6738
  {
6586
6739
  sx: {
6587
6740
  flex: 1,
@@ -6594,14 +6747,14 @@ var ConversationDrawer = ({ open, onClose }) => {
6594
6747
  color: theme.palette.text.secondary
6595
6748
  },
6596
6749
  children: [
6597
- /* @__PURE__ */ jsx13(Typography7, { variant: "h6", sx: { mb: 1 }, children: searchQuery ? "No conversations found" : "No conversations yet" }),
6598
- /* @__PURE__ */ jsx13(Typography7, { variant: "body2", sx: { mb: 3, maxWidth: 280 }, children: searchQuery ? `No conversations match "${searchQuery}"` : "Start your first conversation to begin organizing your chats into projects" })
6750
+ /* @__PURE__ */ jsx14(Typography7, { variant: "h6", sx: { mb: 1 }, children: searchQuery ? "No conversations found" : "No conversations yet" }),
6751
+ /* @__PURE__ */ jsx14(Typography7, { variant: "body2", sx: { mb: 3, maxWidth: 280 }, children: searchQuery ? `No conversations match "${searchQuery}"` : "Start your first conversation to begin organizing your chats into projects" })
6599
6752
  ]
6600
6753
  }
6601
6754
  )
6602
6755
  ] }),
6603
- /* @__PURE__ */ jsxs10(
6604
- Box10,
6756
+ /* @__PURE__ */ jsxs11(
6757
+ Box11,
6605
6758
  {
6606
6759
  onClick: user ? () => {
6607
6760
  window.location.href = "/profile";
@@ -6622,7 +6775,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6622
6775
  "&:hover": user ? { bgcolor: alpha6(theme.palette.primary.main, 0.08) } : void 0
6623
6776
  },
6624
6777
  children: [
6625
- /* @__PURE__ */ jsx13(
6778
+ /* @__PURE__ */ jsx14(
6626
6779
  Avatar6,
6627
6780
  {
6628
6781
  src: avatarImage,
@@ -6637,8 +6790,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6637
6790
  children: avatarInitials
6638
6791
  }
6639
6792
  ),
6640
- /* @__PURE__ */ jsxs10(
6641
- Box10,
6793
+ /* @__PURE__ */ jsxs11(
6794
+ Box11,
6642
6795
  {
6643
6796
  sx: {
6644
6797
  minWidth: 0,
@@ -6650,7 +6803,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6650
6803
  gap: 0.25
6651
6804
  },
6652
6805
  children: [
6653
- /* @__PURE__ */ jsx13(
6806
+ /* @__PURE__ */ jsx14(
6654
6807
  Typography7,
6655
6808
  {
6656
6809
  variant: "subtitle2",
@@ -6659,7 +6812,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6659
6812
  children: user ? userDisplayName : "Not signed in"
6660
6813
  }
6661
6814
  ),
6662
- /* @__PURE__ */ jsx13(
6815
+ /* @__PURE__ */ jsx14(
6663
6816
  Typography7,
6664
6817
  {
6665
6818
  variant: "caption",
@@ -6671,8 +6824,8 @@ var ConversationDrawer = ({ open, onClose }) => {
6671
6824
  ]
6672
6825
  }
6673
6826
  ),
6674
- user && /* @__PURE__ */ jsx13(
6675
- Box10,
6827
+ user && /* @__PURE__ */ jsx14(
6828
+ Box11,
6676
6829
  {
6677
6830
  sx: {
6678
6831
  flexShrink: 0,
@@ -6685,7 +6838,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6685
6838
  border: `1px solid ${alpha6(theme.palette.divider, 0.8)}`,
6686
6839
  color: theme.palette.text.secondary
6687
6840
  },
6688
- children: /* @__PURE__ */ jsx13(SettingsIcon2, { size: 16 })
6841
+ children: /* @__PURE__ */ jsx14(SettingsIcon2, { size: 16 })
6689
6842
  }
6690
6843
  )
6691
6844
  ]
@@ -6694,15 +6847,15 @@ var ConversationDrawer = ({ open, onClose }) => {
6694
6847
  ]
6695
6848
  }
6696
6849
  ),
6697
- /* @__PURE__ */ jsx13(
6850
+ /* @__PURE__ */ jsx14(
6698
6851
  project_management_modal_default,
6699
6852
  {
6700
6853
  open: projectManagementOpen,
6701
6854
  onClose: () => setProjectManagementOpen(false)
6702
6855
  }
6703
6856
  ),
6704
- /* @__PURE__ */ jsx13(memory_modal_default, { open: memoryModalOpen, onClose: () => setMemoryModalOpen(false) }),
6705
- conversationToMove && /* @__PURE__ */ jsx13(
6857
+ /* @__PURE__ */ jsx14(memory_modal_default, { open: memoryModalOpen, onClose: () => setMemoryModalOpen(false) }),
6858
+ conversationToMove && /* @__PURE__ */ jsx14(
6706
6859
  move_conversation_modal_default,
6707
6860
  {
6708
6861
  open: moveModalOpen,
@@ -6711,7 +6864,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6711
6864
  currentProjectId: conversationToMove.projectId
6712
6865
  }
6713
6866
  ),
6714
- /* @__PURE__ */ jsx13(
6867
+ /* @__PURE__ */ jsx14(
6715
6868
  Menu3,
6716
6869
  {
6717
6870
  anchorEl: menuAnchorEl,
@@ -6725,7 +6878,7 @@ var ConversationDrawer = ({ open, onClose }) => {
6725
6878
  vertical: "bottom",
6726
6879
  horizontal: "right"
6727
6880
  },
6728
- children: /* @__PURE__ */ jsxs10(
6881
+ children: /* @__PURE__ */ jsxs11(
6729
6882
  MenuItem3,
6730
6883
  {
6731
6884
  onClick: () => {
@@ -6734,26 +6887,26 @@ var ConversationDrawer = ({ open, onClose }) => {
6734
6887
  },
6735
6888
  sx: { color: theme.palette.error.main },
6736
6889
  children: [
6737
- /* @__PURE__ */ jsx13(ListItemIcon3, { children: /* @__PURE__ */ jsx13(DeleteSweepIcon, { size: 16, color: theme.palette.error.main }) }),
6738
- /* @__PURE__ */ jsx13(ListItemText3, { children: "Clear All Conversations" })
6890
+ /* @__PURE__ */ jsx14(ListItemIcon3, { children: /* @__PURE__ */ jsx14(DeleteSweepIcon, { size: 16, color: theme.palette.error.main }) }),
6891
+ /* @__PURE__ */ jsx14(ListItemText3, { children: "Clear All Conversations" })
6739
6892
  ]
6740
6893
  }
6741
6894
  )
6742
6895
  }
6743
6896
  ),
6744
- /* @__PURE__ */ jsxs10(
6745
- Dialog3,
6897
+ /* @__PURE__ */ jsxs11(
6898
+ Dialog4,
6746
6899
  {
6747
6900
  open: clearConfirmOpen,
6748
6901
  onClose: () => setClearConfirmOpen(false),
6749
6902
  maxWidth: "sm",
6750
6903
  fullWidth: true,
6751
6904
  children: [
6752
- /* @__PURE__ */ jsx13(DialogTitle3, { children: "Clear All Conversations?" }),
6753
- /* @__PURE__ */ jsx13(DialogContent3, { children: /* @__PURE__ */ jsx13(Typography7, { children: "This will permanently delete all conversations and cannot be undone. Are you sure you want to continue?" }) }),
6754
- /* @__PURE__ */ jsxs10(DialogActions3, { children: [
6755
- /* @__PURE__ */ jsx13(Button5, { onClick: () => setClearConfirmOpen(false), children: "Cancel" }),
6756
- /* @__PURE__ */ jsx13(
6905
+ /* @__PURE__ */ jsx14(DialogTitle3, { children: "Clear All Conversations?" }),
6906
+ /* @__PURE__ */ jsx14(DialogContent3, { children: /* @__PURE__ */ jsx14(Typography7, { children: "This will permanently delete all conversations and cannot be undone. Are you sure you want to continue?" }) }),
6907
+ /* @__PURE__ */ jsxs11(DialogActions3, { children: [
6908
+ /* @__PURE__ */ jsx14(Button5, { onClick: () => setClearConfirmOpen(false), children: "Cancel" }),
6909
+ /* @__PURE__ */ jsx14(
6757
6910
  Button5,
6758
6911
  {
6759
6912
  onClick: handleClearAllConfirm,
@@ -6771,13 +6924,13 @@ var ConversationDrawer = ({ open, onClose }) => {
6771
6924
  var conversation_drawer_default = ConversationDrawer;
6772
6925
 
6773
6926
  // src/chat/enhanced-mobile-conversations-modal.tsx
6774
- import { useState as useState13, useMemo as useMemo3, useEffect as useEffect11, useRef as useRef9, useCallback as useCallback5 } from "react";
6927
+ import { useState as useState14, useMemo as useMemo3, useEffect as useEffect11, useRef as useRef9, useCallback as useCallback5 } from "react";
6775
6928
  import {
6776
- Box as Box11,
6777
- IconButton as IconButton8,
6929
+ Box as Box12,
6930
+ IconButton as IconButton9,
6778
6931
  Modal as Modal2,
6779
6932
  Typography as Typography8,
6780
- TextField as TextField7,
6933
+ TextField as TextField8,
6781
6934
  InputAdornment as InputAdornment2,
6782
6935
  Slide,
6783
6936
  Collapse as Collapse3,
@@ -6786,7 +6939,7 @@ import {
6786
6939
  MenuItem as MenuItem4,
6787
6940
  ListItemIcon as ListItemIcon4,
6788
6941
  ListItemText as ListItemText4,
6789
- Dialog as Dialog4,
6942
+ Dialog as Dialog5,
6790
6943
  DialogTitle as DialogTitle4,
6791
6944
  DialogContent as DialogContent4,
6792
6945
  DialogActions as DialogActions4,
@@ -6796,9 +6949,9 @@ import {
6796
6949
  Avatar as Avatar7,
6797
6950
  Chip as Chip4
6798
6951
  } from "@mui/material";
6799
- import { X as CloseIcon5, X as ClearIcon2, Search as SearchIcon2, Folder as FolderIcon5, MoreVertical as MoreVertIcon4, Trash2 as DeleteSweepIcon2, Inbox as InboxIcon4, Plus as AddIcon5, Settings as SettingsIcon3, Brain as MemoryIcon2 } from "lucide-react";
6952
+ import { X as CloseIcon6, X as ClearIcon2, Search as SearchIcon2, Folder as FolderIcon5, MoreVertical as MoreVertIcon4, Trash2 as DeleteSweepIcon2, Inbox as InboxIcon4, Plus as AddIcon5, Settings as SettingsIcon3, Brain as MemoryIcon2 } from "lucide-react";
6800
6953
  import { useTheme as useTheme11, alpha as alpha7 } from "@mui/material/styles";
6801
- import { Fragment as Fragment7, jsx as jsx14, jsxs as jsxs11 } from "react/jsx-runtime";
6954
+ import { Fragment as Fragment7, jsx as jsx15, jsxs as jsxs12 } from "react/jsx-runtime";
6802
6955
  var BANDIT_AVATAR2 = "https://cdn.burtson.ai/images/bandit-head.png";
6803
6956
  var coerceOptionalString2 = (value) => {
6804
6957
  if (typeof value !== "string") return void 0;
@@ -6849,19 +7002,19 @@ var EnhancedMobileConversationsModal = ({
6849
7002
  createProject,
6850
7003
  deleteProject
6851
7004
  } = useProjectStore();
6852
- const [projectManagementOpen, setProjectManagementOpen] = useState13(false);
6853
- const [memoryModalOpen, setMemoryModalOpen] = useState13(false);
6854
- const [collapsedProjects, setCollapsedProjects] = useState13(/* @__PURE__ */ new Set());
7005
+ const [projectManagementOpen, setProjectManagementOpen] = useState14(false);
7006
+ const [memoryModalOpen, setMemoryModalOpen] = useState14(false);
7007
+ const [collapsedProjects, setCollapsedProjects] = useState14(/* @__PURE__ */ new Set());
6855
7008
  const didInitCollapseRef = useRef9(false);
6856
- const [searchQuery, setSearchQuery] = useState13("");
6857
- const [menuAnchorEl, setMenuAnchorEl] = useState13(null);
6858
- const [clearConfirmOpen, setClearConfirmOpen] = useState13(false);
6859
- const [moveModalOpen, setMoveModalOpen] = useState13(false);
6860
- const [conversationToMove, setConversationToMove] = useState13(null);
6861
- const [renameProjectId, setRenameProjectId] = useState13(null);
6862
- const [deletedConversationIds, setDeletedConversationIds] = useState13(/* @__PURE__ */ new Set());
6863
- const [touchDragState, setTouchDragState] = useState13({ conversationId: null, originProjectId: null, hoverProjectId: null });
6864
- const [avatarImage, setAvatarImage] = useState13(BANDIT_AVATAR2);
7009
+ const [searchQuery, setSearchQuery] = useState14("");
7010
+ const [menuAnchorEl, setMenuAnchorEl] = useState14(null);
7011
+ const [clearConfirmOpen, setClearConfirmOpen] = useState14(false);
7012
+ const [moveModalOpen, setMoveModalOpen] = useState14(false);
7013
+ const [conversationToMove, setConversationToMove] = useState14(null);
7014
+ const [renameProjectId, setRenameProjectId] = useState14(null);
7015
+ const [deletedConversationIds, setDeletedConversationIds] = useState14(/* @__PURE__ */ new Set());
7016
+ const [touchDragState, setTouchDragState] = useState14({ conversationId: null, originProjectId: null, hoverProjectId: null });
7017
+ const [avatarImage, setAvatarImage] = useState14(BANDIT_AVATAR2);
6865
7018
  const getCustomClaim = useCallback5((key) => {
6866
7019
  if (!user) return void 0;
6867
7020
  const record = user;
@@ -7132,8 +7285,8 @@ var EnhancedMobileConversationsModal = ({
7132
7285
  return changed ? next : prev;
7133
7286
  });
7134
7287
  }, [conversations]);
7135
- return /* @__PURE__ */ jsxs11(Fragment7, { children: [
7136
- /* @__PURE__ */ jsx14(
7288
+ return /* @__PURE__ */ jsxs12(Fragment7, { children: [
7289
+ /* @__PURE__ */ jsx15(
7137
7290
  Modal2,
7138
7291
  {
7139
7292
  open,
@@ -7142,8 +7295,8 @@ var EnhancedMobileConversationsModal = ({
7142
7295
  display: "flex",
7143
7296
  alignItems: "flex-end"
7144
7297
  },
7145
- children: /* @__PURE__ */ jsx14(Slide, { direction: "up", in: open, children: /* @__PURE__ */ jsxs11(
7146
- Box11,
7298
+ children: /* @__PURE__ */ jsx15(Slide, { direction: "up", in: open, children: /* @__PURE__ */ jsxs12(
7299
+ Box12,
7147
7300
  {
7148
7301
  sx: {
7149
7302
  width: "100%",
@@ -7156,7 +7309,7 @@ var EnhancedMobileConversationsModal = ({
7156
7309
  overflow: "hidden"
7157
7310
  },
7158
7311
  children: [
7159
- /* @__PURE__ */ jsx14(
7312
+ /* @__PURE__ */ jsx15(
7160
7313
  AppBar,
7161
7314
  {
7162
7315
  position: "static",
@@ -7166,9 +7319,9 @@ var EnhancedMobileConversationsModal = ({
7166
7319
  color: theme.palette.text.primary,
7167
7320
  borderBottom: `1px solid ${theme.palette.divider}`
7168
7321
  },
7169
- children: /* @__PURE__ */ jsxs11(Toolbar, { children: [
7170
- /* @__PURE__ */ jsx14(Typography8, { variant: "h6", sx: { flex: 1, fontWeight: 600 }, children: "Conversations" }),
7171
- visibleConversationCount > 0 && /* @__PURE__ */ jsx14(
7322
+ children: /* @__PURE__ */ jsxs12(Toolbar, { children: [
7323
+ /* @__PURE__ */ jsx15(Typography8, { variant: "h6", sx: { flex: 1, fontWeight: 600 }, children: "Conversations" }),
7324
+ visibleConversationCount > 0 && /* @__PURE__ */ jsx15(
7172
7325
  Chip4,
7173
7326
  {
7174
7327
  label: visibleConversationCount,
@@ -7181,44 +7334,44 @@ var EnhancedMobileConversationsModal = ({
7181
7334
  }
7182
7335
  }
7183
7336
  ),
7184
- /* @__PURE__ */ jsx14(
7185
- IconButton8,
7337
+ /* @__PURE__ */ jsx15(
7338
+ IconButton9,
7186
7339
  {
7187
7340
  onClick: () => setMemoryModalOpen(true),
7188
7341
  "aria-label": "Memory",
7189
7342
  sx: { color: theme.palette.text.secondary },
7190
- children: /* @__PURE__ */ jsx14(MemoryIcon2, {})
7343
+ children: /* @__PURE__ */ jsx15(MemoryIcon2, {})
7191
7344
  }
7192
7345
  ),
7193
- /* @__PURE__ */ jsx14(
7194
- IconButton8,
7346
+ /* @__PURE__ */ jsx15(
7347
+ IconButton9,
7195
7348
  {
7196
7349
  onClick: () => setProjectManagementOpen(true),
7197
7350
  sx: { color: theme.palette.text.secondary },
7198
- children: /* @__PURE__ */ jsx14(FolderIcon5, {})
7351
+ children: /* @__PURE__ */ jsx15(FolderIcon5, {})
7199
7352
  }
7200
7353
  ),
7201
- /* @__PURE__ */ jsx14(
7202
- IconButton8,
7354
+ /* @__PURE__ */ jsx15(
7355
+ IconButton9,
7203
7356
  {
7204
7357
  onClick: handleMenuOpen,
7205
7358
  sx: { color: theme.palette.text.secondary },
7206
- children: /* @__PURE__ */ jsx14(MoreVertIcon4, {})
7359
+ children: /* @__PURE__ */ jsx15(MoreVertIcon4, {})
7207
7360
  }
7208
7361
  ),
7209
- /* @__PURE__ */ jsx14(
7210
- IconButton8,
7362
+ /* @__PURE__ */ jsx15(
7363
+ IconButton9,
7211
7364
  {
7212
7365
  onClick: onClose,
7213
7366
  sx: { color: theme.palette.text.secondary },
7214
- children: /* @__PURE__ */ jsx14(CloseIcon5, {})
7367
+ children: /* @__PURE__ */ jsx15(CloseIcon6, {})
7215
7368
  }
7216
7369
  )
7217
7370
  ] })
7218
7371
  }
7219
7372
  ),
7220
- /* @__PURE__ */ jsx14(Box11, { sx: { p: 2, pb: 1 }, children: /* @__PURE__ */ jsx14(
7221
- TextField7,
7373
+ /* @__PURE__ */ jsx15(Box12, { sx: { p: 2, pb: 1 }, children: /* @__PURE__ */ jsx15(
7374
+ TextField8,
7222
7375
  {
7223
7376
  fullWidth: true,
7224
7377
  size: "small",
@@ -7227,22 +7380,22 @@ var EnhancedMobileConversationsModal = ({
7227
7380
  onChange: (e) => setSearchQuery(e.target.value),
7228
7381
  variant: "outlined",
7229
7382
  InputProps: {
7230
- startAdornment: /* @__PURE__ */ jsx14(InputAdornment2, { position: "start", children: /* @__PURE__ */ jsx14(SearchIcon2, { size: 16, color: theme.palette.text.secondary }) }),
7231
- endAdornment: searchQuery && /* @__PURE__ */ jsx14(InputAdornment2, { position: "end", children: /* @__PURE__ */ jsx14(
7232
- IconButton8,
7383
+ startAdornment: /* @__PURE__ */ jsx15(InputAdornment2, { position: "start", children: /* @__PURE__ */ jsx15(SearchIcon2, { size: 16, color: theme.palette.text.secondary }) }),
7384
+ endAdornment: searchQuery && /* @__PURE__ */ jsx15(InputAdornment2, { position: "end", children: /* @__PURE__ */ jsx15(
7385
+ IconButton9,
7233
7386
  {
7234
7387
  onClick: handleSearchClear,
7235
7388
  size: "small",
7236
7389
  edge: "end",
7237
7390
  sx: { color: theme.palette.text.secondary },
7238
- children: /* @__PURE__ */ jsx14(ClearIcon2, { size: 16 })
7391
+ children: /* @__PURE__ */ jsx15(ClearIcon2, { size: 16 })
7239
7392
  }
7240
7393
  ) })
7241
7394
  }
7242
7395
  }
7243
7396
  ) }),
7244
- /* @__PURE__ */ jsxs11(
7245
- Box11,
7397
+ /* @__PURE__ */ jsxs12(
7398
+ Box12,
7246
7399
  {
7247
7400
  sx: {
7248
7401
  flex: 1,
@@ -7253,8 +7406,8 @@ var EnhancedMobileConversationsModal = ({
7253
7406
  pb: 2
7254
7407
  },
7255
7408
  children: [
7256
- touchDragActive && activeDragConversation && /* @__PURE__ */ jsxs11(
7257
- Box11,
7409
+ touchDragActive && activeDragConversation && /* @__PURE__ */ jsxs12(
7410
+ Box12,
7258
7411
  {
7259
7412
  sx: {
7260
7413
  position: "absolute",
@@ -7279,7 +7432,7 @@ var EnhancedMobileConversationsModal = ({
7279
7432
  overflow: "hidden"
7280
7433
  },
7281
7434
  children: [
7282
- /* @__PURE__ */ jsxs11(
7435
+ /* @__PURE__ */ jsxs12(
7283
7436
  Typography8,
7284
7437
  {
7285
7438
  variant: "caption",
@@ -7292,8 +7445,8 @@ var EnhancedMobileConversationsModal = ({
7292
7445
  },
7293
7446
  children: [
7294
7447
  "Move",
7295
- /* @__PURE__ */ jsxs11(
7296
- Box11,
7448
+ /* @__PURE__ */ jsxs12(
7449
+ Box12,
7297
7450
  {
7298
7451
  component: "span",
7299
7452
  sx: {
@@ -7313,7 +7466,7 @@ var EnhancedMobileConversationsModal = ({
7313
7466
  ]
7314
7467
  }
7315
7468
  ),
7316
- /* @__PURE__ */ jsx14(
7469
+ /* @__PURE__ */ jsx15(
7317
7470
  Typography8,
7318
7471
  {
7319
7472
  variant: "caption",
@@ -7322,11 +7475,11 @@ var EnhancedMobileConversationsModal = ({
7322
7475
  fontWeight: 500,
7323
7476
  whiteSpace: "nowrap"
7324
7477
  },
7325
- children: activeHoverLabel ? /* @__PURE__ */ jsxs11(Fragment7, { children: [
7478
+ children: activeHoverLabel ? /* @__PURE__ */ jsxs12(Fragment7, { children: [
7326
7479
  "to",
7327
7480
  " ",
7328
- /* @__PURE__ */ jsx14(
7329
- Box11,
7481
+ /* @__PURE__ */ jsx15(
7482
+ Box12,
7330
7483
  {
7331
7484
  component: "span",
7332
7485
  sx: {
@@ -7342,8 +7495,8 @@ var EnhancedMobileConversationsModal = ({
7342
7495
  ]
7343
7496
  }
7344
7497
  ),
7345
- /* @__PURE__ */ jsxs11(
7346
- Box11,
7498
+ /* @__PURE__ */ jsxs12(
7499
+ Box12,
7347
7500
  {
7348
7501
  onClick: async () => {
7349
7502
  const names = new Set(projects.map((p) => p.name));
@@ -7377,8 +7530,8 @@ var EnhancedMobileConversationsModal = ({
7377
7530
  "&:hover": { bgcolor: alpha7(theme.palette.text.primary, 0.04) }
7378
7531
  },
7379
7532
  children: [
7380
- /* @__PURE__ */ jsx14(
7381
- Box11,
7533
+ /* @__PURE__ */ jsx15(
7534
+ Box12,
7382
7535
  {
7383
7536
  sx: {
7384
7537
  width: 28,
@@ -7390,10 +7543,10 @@ var EnhancedMobileConversationsModal = ({
7390
7543
  justifyContent: "center",
7391
7544
  flexShrink: 0
7392
7545
  },
7393
- children: /* @__PURE__ */ jsx14(FolderIcon5, { size: 16, color: theme.palette.success.main })
7546
+ children: /* @__PURE__ */ jsx15(FolderIcon5, { size: 16, color: theme.palette.success.main })
7394
7547
  }
7395
7548
  ),
7396
- /* @__PURE__ */ jsx14(
7549
+ /* @__PURE__ */ jsx15(
7397
7550
  Typography8,
7398
7551
  {
7399
7552
  variant: "subtitle2",
@@ -7401,14 +7554,14 @@ var EnhancedMobileConversationsModal = ({
7401
7554
  children: "New Project"
7402
7555
  }
7403
7556
  ),
7404
- /* @__PURE__ */ jsx14(IconButton8, { size: "small", sx: { color: theme.palette.success.main }, children: /* @__PURE__ */ jsx14(AddIcon5, { size: 16 }) })
7557
+ /* @__PURE__ */ jsx15(IconButton9, { size: "small", sx: { color: theme.palette.success.main }, children: /* @__PURE__ */ jsx15(AddIcon5, { size: 16 }) })
7405
7558
  ]
7406
7559
  }
7407
7560
  ),
7408
- /* @__PURE__ */ jsx14(Divider3, { sx: { opacity: 0.3 } }),
7409
- filteredProjectGroups.map((group, index) => /* @__PURE__ */ jsxs11(Box11, { children: [
7410
- group.id === null && filteredProjectGroups.length > 1 && /* @__PURE__ */ jsxs11(
7411
- Box11,
7561
+ /* @__PURE__ */ jsx15(Divider3, { sx: { opacity: 0.3 } }),
7562
+ filteredProjectGroups.map((group, index) => /* @__PURE__ */ jsxs12(Box12, { children: [
7563
+ group.id === null && filteredProjectGroups.length > 1 && /* @__PURE__ */ jsxs12(
7564
+ Box12,
7412
7565
  {
7413
7566
  sx: {
7414
7567
  py: 2,
@@ -7418,9 +7571,9 @@ var EnhancedMobileConversationsModal = ({
7418
7571
  gap: 2
7419
7572
  },
7420
7573
  children: [
7421
- /* @__PURE__ */ jsx14(Divider3, { sx: { flex: 1, opacity: 0.6 } }),
7422
- /* @__PURE__ */ jsxs11(Box11, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
7423
- /* @__PURE__ */ jsx14(
7574
+ /* @__PURE__ */ jsx15(Divider3, { sx: { flex: 1, opacity: 0.6 } }),
7575
+ /* @__PURE__ */ jsxs12(Box12, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
7576
+ /* @__PURE__ */ jsx15(
7424
7577
  InboxIcon4,
7425
7578
  {
7426
7579
  size: 14,
@@ -7428,7 +7581,7 @@ var EnhancedMobileConversationsModal = ({
7428
7581
  style: { opacity: 0.7 }
7429
7582
  }
7430
7583
  ),
7431
- /* @__PURE__ */ jsx14(
7584
+ /* @__PURE__ */ jsx15(
7432
7585
  Typography8,
7433
7586
  {
7434
7587
  variant: "caption",
@@ -7443,12 +7596,12 @@ var EnhancedMobileConversationsModal = ({
7443
7596
  }
7444
7597
  )
7445
7598
  ] }),
7446
- /* @__PURE__ */ jsx14(Divider3, { sx: { flex: 1, opacity: 0.6 } })
7599
+ /* @__PURE__ */ jsx15(Divider3, { sx: { flex: 1, opacity: 0.6 } })
7447
7600
  ]
7448
7601
  }
7449
7602
  ),
7450
- group.id !== null ? /* @__PURE__ */ jsxs11(Fragment7, { children: [
7451
- /* @__PURE__ */ jsx14(
7603
+ group.id !== null ? /* @__PURE__ */ jsxs12(Fragment7, { children: [
7604
+ /* @__PURE__ */ jsx15(
7452
7605
  project_header_default,
7453
7606
  {
7454
7607
  projectId: group.id,
@@ -7478,8 +7631,8 @@ var EnhancedMobileConversationsModal = ({
7478
7631
  isTouchTarget: touchDragActive && touchDragState.hoverProjectId === group.id
7479
7632
  }
7480
7633
  ),
7481
- /* @__PURE__ */ jsx14(Collapse3, { in: !group.collapsed, children: /* @__PURE__ */ jsx14(
7482
- Box11,
7634
+ /* @__PURE__ */ jsx15(Collapse3, { in: !group.collapsed, children: /* @__PURE__ */ jsx15(
7635
+ Box12,
7483
7636
  {
7484
7637
  "data-project-id": group.id ?? "__ungrouped",
7485
7638
  sx: {
@@ -7489,7 +7642,7 @@ var EnhancedMobileConversationsModal = ({
7489
7642
  transition: "border 0.2s ease, background-color 0.2s ease",
7490
7643
  backgroundColor: touchDragActive && touchDragState.hoverProjectId === group.id ? alpha7(theme.palette.primary.main, 0.08) : "transparent"
7491
7644
  },
7492
- children: group.conversations.map((conversation) => /* @__PURE__ */ jsx14(
7645
+ children: group.conversations.map((conversation) => /* @__PURE__ */ jsx15(
7493
7646
  simple_conversation_item_default,
7494
7647
  {
7495
7648
  conversation,
@@ -7523,8 +7676,8 @@ var EnhancedMobileConversationsModal = ({
7523
7676
  ) })
7524
7677
  ] }) : (
7525
7678
  // Special handling for ungrouped - no header, just conversations in scrollable area
7526
- /* @__PURE__ */ jsx14(
7527
- Box11,
7679
+ /* @__PURE__ */ jsx15(
7680
+ Box12,
7528
7681
  {
7529
7682
  sx: {
7530
7683
  minHeight: 0,
@@ -7540,7 +7693,7 @@ var EnhancedMobileConversationsModal = ({
7540
7693
  backgroundColor: touchDragActive && touchDragState.hoverProjectId === "__ungrouped" ? alpha7(theme.palette.primary.main, 0.08) : alpha7(theme.palette.background.default, 0.3)
7541
7694
  },
7542
7695
  "data-project-id": "__ungrouped",
7543
- children: group.conversations.map((conversation) => /* @__PURE__ */ jsx14(
7696
+ children: group.conversations.map((conversation) => /* @__PURE__ */ jsx15(
7544
7697
  simple_conversation_item_default,
7545
7698
  {
7546
7699
  conversation,
@@ -7574,8 +7727,8 @@ var EnhancedMobileConversationsModal = ({
7574
7727
  )
7575
7728
  )
7576
7729
  ] }, group.id || "ungrouped")),
7577
- filteredProjectGroups.length === 0 && /* @__PURE__ */ jsxs11(
7578
- Box11,
7730
+ filteredProjectGroups.length === 0 && /* @__PURE__ */ jsxs12(
7731
+ Box12,
7579
7732
  {
7580
7733
  sx: {
7581
7734
  flex: 1,
@@ -7588,16 +7741,16 @@ var EnhancedMobileConversationsModal = ({
7588
7741
  color: theme.palette.text.secondary
7589
7742
  },
7590
7743
  children: [
7591
- /* @__PURE__ */ jsx14(Typography8, { variant: "h6", sx: { mb: 1 }, children: searchQuery ? "No conversations found" : "No conversations yet" }),
7592
- /* @__PURE__ */ jsx14(Typography8, { variant: "body2", sx: { mb: 3, maxWidth: 280 }, children: searchQuery ? `No conversations match "${searchQuery}"` : "Start your first conversation to begin organizing your chats into projects" })
7744
+ /* @__PURE__ */ jsx15(Typography8, { variant: "h6", sx: { mb: 1 }, children: searchQuery ? "No conversations found" : "No conversations yet" }),
7745
+ /* @__PURE__ */ jsx15(Typography8, { variant: "body2", sx: { mb: 3, maxWidth: 280 }, children: searchQuery ? `No conversations match "${searchQuery}"` : "Start your first conversation to begin organizing your chats into projects" })
7593
7746
  ]
7594
7747
  }
7595
7748
  )
7596
7749
  ]
7597
7750
  }
7598
7751
  ),
7599
- /* @__PURE__ */ jsxs11(
7600
- Box11,
7752
+ /* @__PURE__ */ jsxs12(
7753
+ Box12,
7601
7754
  {
7602
7755
  onClick: user ? () => {
7603
7756
  window.location.href = "/profile";
@@ -7614,7 +7767,7 @@ var EnhancedMobileConversationsModal = ({
7614
7767
  cursor: user ? "pointer" : "default"
7615
7768
  },
7616
7769
  children: [
7617
- /* @__PURE__ */ jsx14(
7770
+ /* @__PURE__ */ jsx15(
7618
7771
  Avatar7,
7619
7772
  {
7620
7773
  src: avatarImage,
@@ -7629,8 +7782,8 @@ var EnhancedMobileConversationsModal = ({
7629
7782
  children: avatarInitials
7630
7783
  }
7631
7784
  ),
7632
- /* @__PURE__ */ jsxs11(Box11, { sx: { display: "flex", flexDirection: "column", flex: 1, minWidth: 0, gap: 0.25 }, children: [
7633
- /* @__PURE__ */ jsx14(
7785
+ /* @__PURE__ */ jsxs12(Box12, { sx: { display: "flex", flexDirection: "column", flex: 1, minWidth: 0, gap: 0.25 }, children: [
7786
+ /* @__PURE__ */ jsx15(
7634
7787
  Typography8,
7635
7788
  {
7636
7789
  variant: "subtitle2",
@@ -7639,7 +7792,7 @@ var EnhancedMobileConversationsModal = ({
7639
7792
  children: user ? userDisplayName : "Not signed in"
7640
7793
  }
7641
7794
  ),
7642
- /* @__PURE__ */ jsx14(
7795
+ /* @__PURE__ */ jsx15(
7643
7796
  Typography8,
7644
7797
  {
7645
7798
  variant: "caption",
@@ -7649,8 +7802,8 @@ var EnhancedMobileConversationsModal = ({
7649
7802
  }
7650
7803
  )
7651
7804
  ] }),
7652
- user && /* @__PURE__ */ jsx14(
7653
- Box11,
7805
+ user && /* @__PURE__ */ jsx15(
7806
+ Box12,
7654
7807
  {
7655
7808
  sx: {
7656
7809
  flexShrink: 0,
@@ -7663,7 +7816,7 @@ var EnhancedMobileConversationsModal = ({
7663
7816
  border: `1px solid ${alpha7(theme.palette.divider, 0.8)}`,
7664
7817
  color: theme.palette.text.secondary
7665
7818
  },
7666
- children: /* @__PURE__ */ jsx14(SettingsIcon3, { size: 16 })
7819
+ children: /* @__PURE__ */ jsx15(SettingsIcon3, { size: 16 })
7667
7820
  }
7668
7821
  )
7669
7822
  ]
@@ -7674,15 +7827,15 @@ var EnhancedMobileConversationsModal = ({
7674
7827
  ) })
7675
7828
  }
7676
7829
  ),
7677
- /* @__PURE__ */ jsx14(
7830
+ /* @__PURE__ */ jsx15(
7678
7831
  project_management_modal_default,
7679
7832
  {
7680
7833
  open: projectManagementOpen,
7681
7834
  onClose: () => setProjectManagementOpen(false)
7682
7835
  }
7683
7836
  ),
7684
- /* @__PURE__ */ jsx14(memory_modal_default, { open: memoryModalOpen, onClose: () => setMemoryModalOpen(false) }),
7685
- conversationToMove && /* @__PURE__ */ jsx14(
7837
+ /* @__PURE__ */ jsx15(memory_modal_default, { open: memoryModalOpen, onClose: () => setMemoryModalOpen(false) }),
7838
+ conversationToMove && /* @__PURE__ */ jsx15(
7686
7839
  move_conversation_modal_default,
7687
7840
  {
7688
7841
  open: moveModalOpen,
@@ -7691,7 +7844,7 @@ var EnhancedMobileConversationsModal = ({
7691
7844
  currentProjectId: conversationToMove.projectId
7692
7845
  }
7693
7846
  ),
7694
- /* @__PURE__ */ jsx14(
7847
+ /* @__PURE__ */ jsx15(
7695
7848
  Menu4,
7696
7849
  {
7697
7850
  anchorEl: menuAnchorEl,
@@ -7705,7 +7858,7 @@ var EnhancedMobileConversationsModal = ({
7705
7858
  vertical: "bottom",
7706
7859
  horizontal: "right"
7707
7860
  },
7708
- children: /* @__PURE__ */ jsxs11(
7861
+ children: /* @__PURE__ */ jsxs12(
7709
7862
  MenuItem4,
7710
7863
  {
7711
7864
  onClick: () => {
@@ -7715,26 +7868,26 @@ var EnhancedMobileConversationsModal = ({
7715
7868
  disabled: visibleConversationCount === 0,
7716
7869
  sx: { color: theme.palette.error.main },
7717
7870
  children: [
7718
- /* @__PURE__ */ jsx14(ListItemIcon4, { children: /* @__PURE__ */ jsx14(DeleteSweepIcon2, { size: 16, color: theme.palette.error.main }) }),
7719
- /* @__PURE__ */ jsx14(ListItemText4, { children: "Clear All Conversations" })
7871
+ /* @__PURE__ */ jsx15(ListItemIcon4, { children: /* @__PURE__ */ jsx15(DeleteSweepIcon2, { size: 16, color: theme.palette.error.main }) }),
7872
+ /* @__PURE__ */ jsx15(ListItemText4, { children: "Clear All Conversations" })
7720
7873
  ]
7721
7874
  }
7722
7875
  )
7723
7876
  }
7724
7877
  ),
7725
- /* @__PURE__ */ jsxs11(
7726
- Dialog4,
7878
+ /* @__PURE__ */ jsxs12(
7879
+ Dialog5,
7727
7880
  {
7728
7881
  open: clearConfirmOpen,
7729
7882
  onClose: () => setClearConfirmOpen(false),
7730
7883
  maxWidth: "sm",
7731
7884
  fullWidth: true,
7732
7885
  children: [
7733
- /* @__PURE__ */ jsx14(DialogTitle4, { children: "Clear All Conversations?" }),
7734
- /* @__PURE__ */ jsx14(DialogContent4, { children: /* @__PURE__ */ jsx14(Typography8, { children: visibleConversationCount === 0 ? "No conversations available to clear." : `This will permanently delete ${visibleConversationCount} conversation${visibleConversationCount === 1 ? "" : "s"} and cannot be undone.` }) }),
7735
- /* @__PURE__ */ jsxs11(DialogActions4, { children: [
7736
- /* @__PURE__ */ jsx14(Button6, { onClick: () => setClearConfirmOpen(false), children: "Cancel" }),
7737
- /* @__PURE__ */ jsx14(
7886
+ /* @__PURE__ */ jsx15(DialogTitle4, { children: "Clear All Conversations?" }),
7887
+ /* @__PURE__ */ jsx15(DialogContent4, { children: /* @__PURE__ */ jsx15(Typography8, { children: visibleConversationCount === 0 ? "No conversations available to clear." : `This will permanently delete ${visibleConversationCount} conversation${visibleConversationCount === 1 ? "" : "s"} and cannot be undone.` }) }),
7888
+ /* @__PURE__ */ jsxs12(DialogActions4, { children: [
7889
+ /* @__PURE__ */ jsx15(Button6, { onClick: () => setClearConfirmOpen(false), children: "Cancel" }),
7890
+ /* @__PURE__ */ jsx15(
7738
7891
  Button6,
7739
7892
  {
7740
7893
  onClick: handleClearAllConfirm,
@@ -7753,7 +7906,7 @@ var enhanced_mobile_conversations_modal_default = EnhancedMobileConversationsMod
7753
7906
 
7754
7907
  // src/chat/chat-app-bar.tsx
7755
7908
  import { shallow as shallow2 } from "zustand/shallow";
7756
- import { Fragment as Fragment8, jsx as jsx15, jsxs as jsxs12 } from "react/jsx-runtime";
7909
+ import { Fragment as Fragment8, jsx as jsx16, jsxs as jsxs13 } from "react/jsx-runtime";
7757
7910
  var CDN_BASE = "https://cdn.burtson.ai/";
7758
7911
  var banditHead = `${CDN_BASE}/images/bandit-head.png`;
7759
7912
  var modelAvatars = {
@@ -7800,12 +7953,12 @@ var ChatAppBar = ({
7800
7953
  menuBackground,
7801
7954
  menuText
7802
7955
  } = theme.palette.chat.appBar;
7803
- const [modelAnchorEl, setModelAnchorEl] = useState14(null);
7804
- const [engineAnchorEl, setEngineAnchorEl] = useState14(null);
7805
- const [voiceAnchorEl, setVoiceAnchorEl] = useState14(null);
7806
- const [modalOpen, setModalOpen] = useState14(false);
7807
- const [confirmModelChangeOpen, setConfirmModelChangeOpen] = useState14(false);
7808
- const [pendingModel, setPendingModel] = useState14(null);
7956
+ const [modelAnchorEl, setModelAnchorEl] = useState15(null);
7957
+ const [engineAnchorEl, setEngineAnchorEl] = useState15(null);
7958
+ const [voiceAnchorEl, setVoiceAnchorEl] = useState15(null);
7959
+ const [modalOpen, setModalOpen] = useState15(false);
7960
+ const [confirmModelChangeOpen, setConfirmModelChangeOpen] = useState15(false);
7961
+ const [pendingModel, setPendingModel] = useState15(null);
7809
7962
  const { conversations, currentId, createNewConversation, _hasHydrated } = useConversationStore();
7810
7963
  const { preferences } = usePreferencesStore();
7811
7964
  const { settings: packageSettings } = usePackageSettingsStore();
@@ -7849,16 +8002,16 @@ var ChatAppBar = ({
7849
8002
  };
7850
8003
  const syncIndicatorIcon = (() => {
7851
8004
  if (isPlaygroundMode2 || !syncEnabled) {
7852
- return /* @__PURE__ */ jsx15(CloudOffIcon, { fontSize: "small", color: "disabled" });
8005
+ return /* @__PURE__ */ jsx16(CloudOffIcon, { fontSize: "small", color: "disabled" });
7853
8006
  }
7854
8007
  switch (syncStatus) {
7855
8008
  case "syncing":
7856
- return /* @__PURE__ */ jsx15(SyncIcon, { fontSize: "small", sx: syncSpinSx, color: "primary" });
8009
+ return /* @__PURE__ */ jsx16(SyncIcon, { fontSize: "small", sx: syncSpinSx, color: "primary" });
7857
8010
  case "error":
7858
- return /* @__PURE__ */ jsx15(ErrorOutlineIcon, { fontSize: "small", color: "error" });
8011
+ return /* @__PURE__ */ jsx16(ErrorOutlineIcon, { fontSize: "small", color: "error" });
7859
8012
  case "idle":
7860
8013
  default:
7861
- return /* @__PURE__ */ jsx15(CloudDoneIcon, { fontSize: "small", color: "success" });
8014
+ return /* @__PURE__ */ jsx16(CloudDoneIcon, { fontSize: "small", color: "success" });
7862
8015
  }
7863
8016
  })();
7864
8017
  const syncTooltip = (() => {
@@ -7964,9 +8117,9 @@ var ChatAppBar = ({
7964
8117
  }
7965
8118
  safeNavigate("/");
7966
8119
  }
7967
- return /* @__PURE__ */ jsxs12(Fragment8, { children: [
7968
- /* @__PURE__ */ jsxs12(
7969
- Box12,
8120
+ return /* @__PURE__ */ jsxs13(Fragment8, { children: [
8121
+ /* @__PURE__ */ jsxs13(
8122
+ Box13,
7970
8123
  {
7971
8124
  sx: {
7972
8125
  position: "fixed",
@@ -7986,8 +8139,8 @@ var ChatAppBar = ({
7986
8139
  }
7987
8140
  },
7988
8141
  children: [
7989
- /* @__PURE__ */ jsxs12(
7990
- Box12,
8142
+ /* @__PURE__ */ jsxs13(
8143
+ Box13,
7991
8144
  {
7992
8145
  sx: {
7993
8146
  display: "flex",
@@ -8007,17 +8160,17 @@ var ChatAppBar = ({
8007
8160
  }
8008
8161
  },
8009
8162
  children: [
8010
- /* @__PURE__ */ jsx15(Tooltip5, { title: homeTooltip, arrow: true, children: /* @__PURE__ */ jsx15(
8011
- IconButton9,
8163
+ /* @__PURE__ */ jsx16(Tooltip6, { title: homeTooltip, arrow: true, children: /* @__PURE__ */ jsx16(
8164
+ IconButton10,
8012
8165
  {
8013
8166
  onClick: goToHome,
8014
8167
  sx: pillButtonStyles,
8015
8168
  "aria-label": "Go to home page",
8016
- children: /* @__PURE__ */ jsx15(HomeIcon, {})
8169
+ children: /* @__PURE__ */ jsx16(HomeIcon, {})
8017
8170
  }
8018
8171
  ) }),
8019
- showLimitedAdminPanel() && /* @__PURE__ */ jsx15(Tooltip5, { title: "Management & Settings", arrow: true, children: /* @__PURE__ */ jsx15(
8020
- IconButton9,
8172
+ showLimitedAdminPanel() && /* @__PURE__ */ jsx16(Tooltip6, { title: "Management & Settings", arrow: true, children: /* @__PURE__ */ jsx16(
8173
+ IconButton10,
8021
8174
  {
8022
8175
  onClick: () => safeNavigate(managementPath),
8023
8176
  sx: {
@@ -8028,11 +8181,11 @@ var ChatAppBar = ({
8028
8181
  }
8029
8182
  },
8030
8183
  "aria-label": "Open management settings",
8031
- children: /* @__PURE__ */ jsx15(SettingsIcon, {})
8184
+ children: /* @__PURE__ */ jsx16(SettingsIcon, {})
8032
8185
  }
8033
8186
  ) }),
8034
- /* @__PURE__ */ jsx15(Tooltip5, { title: syncTooltip, arrow: true, children: /* @__PURE__ */ jsxs12(
8035
- IconButton9,
8187
+ /* @__PURE__ */ jsx16(Tooltip6, { title: syncTooltip, arrow: true, children: /* @__PURE__ */ jsxs13(
8188
+ IconButton10,
8036
8189
  {
8037
8190
  onClick: handleSyncBadgeClick,
8038
8191
  disabled: syncButtonDisabled,
@@ -8047,8 +8200,8 @@ var ChatAppBar = ({
8047
8200
  "aria-label": "Conversation sync status",
8048
8201
  children: [
8049
8202
  syncIndicatorIcon,
8050
- pendingCount > 0 && !syncButtonDisabled && syncStatus !== "syncing" && /* @__PURE__ */ jsx15(
8051
- Box12,
8203
+ pendingCount > 0 && !syncButtonDisabled && syncStatus !== "syncing" && /* @__PURE__ */ jsx16(
8204
+ Box13,
8052
8205
  {
8053
8206
  sx: {
8054
8207
  position: "absolute",
@@ -8073,8 +8226,8 @@ var ChatAppBar = ({
8073
8226
  ]
8074
8227
  }
8075
8228
  ) }),
8076
- !isMobile && /* @__PURE__ */ jsx15(Tooltip5, { title: `${drawerOpen ? "Close" : "Open"} Conversations`, arrow: true, children: /* @__PURE__ */ jsxs12(
8077
- IconButton9,
8229
+ !isMobile && /* @__PURE__ */ jsx16(Tooltip6, { title: `${drawerOpen ? "Close" : "Open"} Conversations`, arrow: true, children: /* @__PURE__ */ jsxs13(
8230
+ IconButton10,
8078
8231
  {
8079
8232
  onClick: () => setDrawerOpen(!drawerOpen),
8080
8233
  sx: {
@@ -8087,9 +8240,9 @@ var ChatAppBar = ({
8087
8240
  "aria-label": `${drawerOpen ? "Close" : "Open"} conversations drawer`,
8088
8241
  "aria-pressed": drawerOpen,
8089
8242
  children: [
8090
- drawerOpen ? /* @__PURE__ */ jsx15(NotesIcon, {}) : /* @__PURE__ */ jsx15(NotesIconOutlined, {}),
8091
- conversations.length > 0 && /* @__PURE__ */ jsx15(
8092
- Box12,
8243
+ drawerOpen ? /* @__PURE__ */ jsx16(NotesIcon, {}) : /* @__PURE__ */ jsx16(NotesIconOutlined, {}),
8244
+ conversations.length > 0 && /* @__PURE__ */ jsx16(
8245
+ Box13,
8093
8246
  {
8094
8247
  sx: {
8095
8248
  position: "absolute",
@@ -8114,8 +8267,8 @@ var ChatAppBar = ({
8114
8267
  ]
8115
8268
  }
8116
8269
  ) }),
8117
- !isMobile && canShowNewConversationButton && /* @__PURE__ */ jsx15(Tooltip5, { title: "Start New Conversation", arrow: true, children: /* @__PURE__ */ jsx15(
8118
- IconButton9,
8270
+ !isMobile && canShowNewConversationButton && /* @__PURE__ */ jsx16(Tooltip6, { title: "Start New Conversation", arrow: true, children: /* @__PURE__ */ jsx16(
8271
+ IconButton10,
8119
8272
  {
8120
8273
  onClick: () => createNewConversation(),
8121
8274
  sx: {
@@ -8128,14 +8281,14 @@ var ChatAppBar = ({
8128
8281
  }
8129
8282
  },
8130
8283
  "aria-label": "Create new conversation",
8131
- children: /* @__PURE__ */ jsx15(AddIcon, {})
8284
+ children: /* @__PURE__ */ jsx16(AddIcon, {})
8132
8285
  }
8133
8286
  ) })
8134
8287
  ]
8135
8288
  }
8136
8289
  ),
8137
- /* @__PURE__ */ jsxs12(
8138
- Box12,
8290
+ /* @__PURE__ */ jsxs13(
8291
+ Box13,
8139
8292
  {
8140
8293
  sx: {
8141
8294
  display: "flex",
@@ -8155,8 +8308,8 @@ var ChatAppBar = ({
8155
8308
  }
8156
8309
  },
8157
8310
  children: [
8158
- isMobile && /* @__PURE__ */ jsx15(Tooltip5, { title: `Conversations (${conversations.length})`, arrow: true, children: /* @__PURE__ */ jsxs12(
8159
- IconButton9,
8311
+ isMobile && /* @__PURE__ */ jsx16(Tooltip6, { title: `Conversations (${conversations.length})`, arrow: true, children: /* @__PURE__ */ jsxs13(
8312
+ IconButton10,
8160
8313
  {
8161
8314
  onClick: () => setModalOpen(true),
8162
8315
  sx: {
@@ -8165,9 +8318,9 @@ var ChatAppBar = ({
8165
8318
  },
8166
8319
  "aria-label": `Open conversations modal with ${conversations.length} conversations`,
8167
8320
  children: [
8168
- /* @__PURE__ */ jsx15(NotesIcon, { fontSize: "small" }),
8169
- conversations.length > 0 && /* @__PURE__ */ jsx15(
8170
- Box12,
8321
+ /* @__PURE__ */ jsx16(NotesIcon, { fontSize: "small" }),
8322
+ conversations.length > 0 && /* @__PURE__ */ jsx16(
8323
+ Box13,
8171
8324
  {
8172
8325
  sx: {
8173
8326
  position: "absolute",
@@ -8192,8 +8345,8 @@ var ChatAppBar = ({
8192
8345
  ]
8193
8346
  }
8194
8347
  ) }),
8195
- isMobile && canShowNewConversationButton && /* @__PURE__ */ jsx15(Tooltip5, { title: "Start New Conversation", arrow: true, children: /* @__PURE__ */ jsx15(
8196
- IconButton9,
8348
+ isMobile && canShowNewConversationButton && /* @__PURE__ */ jsx16(Tooltip6, { title: "Start New Conversation", arrow: true, children: /* @__PURE__ */ jsx16(
8349
+ IconButton10,
8197
8350
  {
8198
8351
  onClick: () => {
8199
8352
  createNewConversation();
@@ -8209,11 +8362,11 @@ var ChatAppBar = ({
8209
8362
  }
8210
8363
  },
8211
8364
  "aria-label": "Create new conversation",
8212
- children: /* @__PURE__ */ jsx15(AddIcon, { fontSize: "small" })
8365
+ children: /* @__PURE__ */ jsx16(AddIcon, { fontSize: "small" })
8213
8366
  }
8214
8367
  ) }),
8215
- /* @__PURE__ */ jsx15(Tooltip5, { title: `Current AI: ${selectedModel.replace("Bandit-", "")}`, arrow: true, children: /* @__PURE__ */ jsx15(
8216
- IconButton9,
8368
+ /* @__PURE__ */ jsx16(Tooltip6, { title: `Current AI: ${selectedModel.replace("Bandit-", "")}`, arrow: true, children: /* @__PURE__ */ jsx16(
8369
+ IconButton10,
8217
8370
  {
8218
8371
  onClick: (e) => setModelAnchorEl(e.currentTarget),
8219
8372
  sx: {
@@ -8227,7 +8380,7 @@ var ChatAppBar = ({
8227
8380
  }
8228
8381
  },
8229
8382
  "aria-label": `Change AI personality. Currently using ${selectedModel}`,
8230
- children: /* @__PURE__ */ jsx15(
8383
+ children: /* @__PURE__ */ jsx16(
8231
8384
  Avatar8,
8232
8385
  {
8233
8386
  src: currentAvatar,
@@ -8244,16 +8397,16 @@ var ChatAppBar = ({
8244
8397
  )
8245
8398
  }
8246
8399
  ) }),
8247
- /* @__PURE__ */ jsx15(Tooltip5, { title: `Engine \xB7 ${engineDisplay}`, arrow: true, children: /* @__PURE__ */ jsx15(
8248
- IconButton9,
8400
+ /* @__PURE__ */ jsx16(Tooltip6, { title: `Engine \xB7 ${engineDisplay}`, arrow: true, children: /* @__PURE__ */ jsx16(
8401
+ IconButton10,
8249
8402
  {
8250
8403
  onClick: (e) => setEngineAnchorEl(e.currentTarget),
8251
8404
  sx: pillButtonStyles,
8252
8405
  "aria-label": `Change base model (engine). Currently ${engineDisplay}`,
8253
- children: /* @__PURE__ */ jsx15(AutoAwesomeIcon, { fontSize: "small" })
8406
+ children: /* @__PURE__ */ jsx16(AutoAwesomeIcon, { fontSize: "small" })
8254
8407
  }
8255
8408
  ) }),
8256
- /* @__PURE__ */ jsxs12(
8409
+ /* @__PURE__ */ jsxs13(
8257
8410
  Menu5,
8258
8411
  {
8259
8412
  anchorEl: engineAnchorEl,
@@ -8262,8 +8415,8 @@ var ChatAppBar = ({
8262
8415
  transformOrigin: { horizontal: "right", vertical: "top" },
8263
8416
  anchorOrigin: { horizontal: "right", vertical: "bottom" },
8264
8417
  children: [
8265
- /* @__PURE__ */ jsx15(Typography9, { variant: "overline", sx: { px: 2, color: theme.palette.text.secondary }, children: "Engine \xB7 base model" }),
8266
- engines.length === 0 && /* @__PURE__ */ jsx15(MenuItem5, { disabled: true, children: /* @__PURE__ */ jsx15(Typography9, { variant: "body2", children: "No engines available" }) }),
8418
+ /* @__PURE__ */ jsx16(Typography9, { variant: "overline", sx: { px: 2, color: theme.palette.text.secondary }, children: "Engine \xB7 base model" }),
8419
+ engines.length === 0 && /* @__PURE__ */ jsx16(MenuItem5, { disabled: true, children: /* @__PURE__ */ jsx16(Typography9, { variant: "body2", children: "No engines available" }) }),
8267
8420
  engines.map((engine) => {
8268
8421
  const badges = [
8269
8422
  engine.vision && "vision",
@@ -8271,7 +8424,7 @@ var ChatAppBar = ({
8271
8424
  engine.thinking && "thinking",
8272
8425
  engine.cloud && "cloud"
8273
8426
  ].filter(Boolean);
8274
- return /* @__PURE__ */ jsxs12(
8427
+ return /* @__PURE__ */ jsxs13(
8275
8428
  MenuItem5,
8276
8429
  {
8277
8430
  selected: engine.id === resolvedEngineId,
@@ -8291,13 +8444,13 @@ var ChatAppBar = ({
8291
8444
  whiteSpace: "normal"
8292
8445
  },
8293
8446
  children: [
8294
- /* @__PURE__ */ jsxs12(Box12, { sx: { display: "flex", alignItems: "center", gap: 1, width: "100%" }, children: [
8295
- /* @__PURE__ */ jsx15(Typography9, { variant: "body2", sx: { fontWeight: 600, flex: 1 }, children: cleanEngineName(engine.displayName) }),
8296
- engine.id === resolvedEngineId && /* @__PURE__ */ jsx15(Box12, { sx: { width: 8, height: 8, borderRadius: "50%", bgcolor: theme.palette.primary.main } })
8447
+ /* @__PURE__ */ jsxs13(Box13, { sx: { display: "flex", alignItems: "center", gap: 1, width: "100%" }, children: [
8448
+ /* @__PURE__ */ jsx16(Typography9, { variant: "body2", sx: { fontWeight: 600, flex: 1 }, children: cleanEngineName(engine.displayName) }),
8449
+ engine.id === resolvedEngineId && /* @__PURE__ */ jsx16(Box13, { sx: { width: 8, height: 8, borderRadius: "50%", bgcolor: theme.palette.primary.main } })
8297
8450
  ] }),
8298
- /* @__PURE__ */ jsx15(Typography9, { variant: "caption", sx: { color: theme.palette.text.secondary }, children: engine.available ? engine.description : engine.unavailableReason || "Unavailable" }),
8299
- badges.length > 0 && /* @__PURE__ */ jsx15(Box12, { sx: { display: "flex", gap: 0.5, flexWrap: "wrap", mt: 0.25 }, children: badges.map((b) => /* @__PURE__ */ jsx15(
8300
- Box12,
8451
+ /* @__PURE__ */ jsx16(Typography9, { variant: "caption", sx: { color: theme.palette.text.secondary }, children: engine.available ? engine.description : engine.unavailableReason || "Unavailable" }),
8452
+ badges.length > 0 && /* @__PURE__ */ jsx16(Box13, { sx: { display: "flex", gap: 0.5, flexWrap: "wrap", mt: 0.25 }, children: badges.map((b) => /* @__PURE__ */ jsx16(
8453
+ Box13,
8301
8454
  {
8302
8455
  sx: {
8303
8456
  fontSize: "0.65rem",
@@ -8319,7 +8472,7 @@ var ChatAppBar = ({
8319
8472
  ]
8320
8473
  }
8321
8474
  ),
8322
- /* @__PURE__ */ jsx15(
8475
+ /* @__PURE__ */ jsx16(
8323
8476
  Menu5,
8324
8477
  {
8325
8478
  anchorEl: modelAnchorEl,
@@ -8355,7 +8508,7 @@ var ChatAppBar = ({
8355
8508
  }
8356
8509
  }
8357
8510
  },
8358
- children: availableModels.map((model) => /* @__PURE__ */ jsxs12(
8511
+ children: availableModels.map((model) => /* @__PURE__ */ jsxs13(
8359
8512
  MenuItem5,
8360
8513
  {
8361
8514
  selected: model.name === selectedModel,
@@ -8402,7 +8555,7 @@ var ChatAppBar = ({
8402
8555
  px: 2
8403
8556
  },
8404
8557
  children: [
8405
- /* @__PURE__ */ jsx15(
8558
+ /* @__PURE__ */ jsx16(
8406
8559
  Avatar8,
8407
8560
  {
8408
8561
  src: model.avatarBase64 || modelAvatars[model.name] || banditHead,
@@ -8415,12 +8568,12 @@ var ChatAppBar = ({
8415
8568
  }
8416
8569
  }
8417
8570
  ),
8418
- /* @__PURE__ */ jsxs12(Box12, { sx: { flex: 1 }, children: [
8419
- /* @__PURE__ */ jsx15(Typography9, { variant: "body2", sx: { fontWeight: 500 }, children: model.name.replace("Bandit-", "") }),
8420
- /* @__PURE__ */ jsx15(Typography9, { variant: "caption", sx: { color: theme.palette.text.secondary, display: "block" }, children: model.name === selectedModel ? "Currently active" : "Switch to this AI" })
8571
+ /* @__PURE__ */ jsxs13(Box13, { sx: { flex: 1 }, children: [
8572
+ /* @__PURE__ */ jsx16(Typography9, { variant: "body2", sx: { fontWeight: 500 }, children: model.name.replace("Bandit-", "") }),
8573
+ /* @__PURE__ */ jsx16(Typography9, { variant: "caption", sx: { color: theme.palette.text.secondary, display: "block" }, children: model.name === selectedModel ? "Currently active" : "Switch to this AI" })
8421
8574
  ] }),
8422
- model.name === selectedModel && /* @__PURE__ */ jsx15(
8423
- Box12,
8575
+ model.name === selectedModel && /* @__PURE__ */ jsx16(
8576
+ Box13,
8424
8577
  {
8425
8578
  sx: {
8426
8579
  width: 8,
@@ -8436,9 +8589,9 @@ var ChatAppBar = ({
8436
8589
  ))
8437
8590
  }
8438
8591
  ),
8439
- isTTSAvailable && /* @__PURE__ */ jsxs12(Fragment8, { children: [
8440
- /* @__PURE__ */ jsx15(Tooltip5, { title: `Voice: ${selectedVoice ? toTitleCase(selectedVoice.split("-")[1]) : "Default"}`, arrow: true, children: /* @__PURE__ */ jsx15(
8441
- IconButton9,
8592
+ isTTSAvailable && /* @__PURE__ */ jsxs13(Fragment8, { children: [
8593
+ /* @__PURE__ */ jsx16(Tooltip6, { title: `Voice: ${selectedVoice ? toTitleCase(selectedVoice.split("-")[1]) : "Default"}`, arrow: true, children: /* @__PURE__ */ jsx16(
8594
+ IconButton10,
8442
8595
  {
8443
8596
  onClick: (e) => setVoiceAnchorEl(e.currentTarget),
8444
8597
  sx: {
@@ -8451,10 +8604,10 @@ var ChatAppBar = ({
8451
8604
  }
8452
8605
  },
8453
8606
  "aria-label": `Change voice. Currently using ${selectedVoice ? toTitleCase(selectedVoice.split("-")[1]) : "default"}`,
8454
- children: /* @__PURE__ */ jsx15(RecordVoiceOverIcon, { fontSize: "small" })
8607
+ children: /* @__PURE__ */ jsx16(RecordVoiceOverIcon, { fontSize: "small" })
8455
8608
  }
8456
8609
  ) }),
8457
- /* @__PURE__ */ jsx15(
8610
+ /* @__PURE__ */ jsx16(
8458
8611
  Menu5,
8459
8612
  {
8460
8613
  anchorEl: voiceAnchorEl,
@@ -8491,7 +8644,7 @@ var ChatAppBar = ({
8491
8644
  }
8492
8645
  }
8493
8646
  },
8494
- children: availableVoices.length > 0 ? availableVoices.map((voice) => /* @__PURE__ */ jsx15(
8647
+ children: availableVoices.length > 0 ? availableVoices.map((voice) => /* @__PURE__ */ jsx16(
8495
8648
  MenuItem5,
8496
8649
  {
8497
8650
  selected: voice === selectedVoice,
@@ -8499,14 +8652,14 @@ var ChatAppBar = ({
8499
8652
  handleVoiceChange(voice);
8500
8653
  setVoiceAnchorEl(null);
8501
8654
  },
8502
- children: /* @__PURE__ */ jsxs12(Box12, { sx: { display: "flex", alignItems: "center", gap: 1, width: "100%" }, children: [
8503
- /* @__PURE__ */ jsx15(RecordVoiceOverIcon, { fontSize: "small", sx: { color: theme.palette.text.secondary } }),
8504
- /* @__PURE__ */ jsxs12(Box12, { sx: { flex: 1 }, children: [
8505
- /* @__PURE__ */ jsx15(Typography9, { variant: "body2", children: toTitleCase(voice.split("-")[1]) }),
8506
- /* @__PURE__ */ jsx15(Typography9, { variant: "caption", sx: { color: theme.palette.text.secondary }, children: voice === selectedVoice ? "Currently active" : "Switch to this voice" })
8655
+ children: /* @__PURE__ */ jsxs13(Box13, { sx: { display: "flex", alignItems: "center", gap: 1, width: "100%" }, children: [
8656
+ /* @__PURE__ */ jsx16(RecordVoiceOverIcon, { fontSize: "small", sx: { color: theme.palette.text.secondary } }),
8657
+ /* @__PURE__ */ jsxs13(Box13, { sx: { flex: 1 }, children: [
8658
+ /* @__PURE__ */ jsx16(Typography9, { variant: "body2", children: toTitleCase(voice.split("-")[1]) }),
8659
+ /* @__PURE__ */ jsx16(Typography9, { variant: "caption", sx: { color: theme.palette.text.secondary }, children: voice === selectedVoice ? "Currently active" : "Switch to this voice" })
8507
8660
  ] }),
8508
- voice === selectedVoice && /* @__PURE__ */ jsx15(
8509
- Box12,
8661
+ voice === selectedVoice && /* @__PURE__ */ jsx16(
8662
+ Box13,
8510
8663
  {
8511
8664
  sx: {
8512
8665
  width: 8,
@@ -8519,7 +8672,7 @@ var ChatAppBar = ({
8519
8672
  ] })
8520
8673
  },
8521
8674
  voice
8522
- )) : /* @__PURE__ */ jsx15(MenuItem5, { disabled: true, children: /* @__PURE__ */ jsx15(Typography9, { variant: "body2", color: "text.secondary", children: "No voices available" }) })
8675
+ )) : /* @__PURE__ */ jsx16(MenuItem5, { disabled: true, children: /* @__PURE__ */ jsx16(Typography9, { variant: "body2", color: "text.secondary", children: "No voices available" }) })
8523
8676
  }
8524
8677
  )
8525
8678
  ] })
@@ -8529,17 +8682,17 @@ var ChatAppBar = ({
8529
8682
  ]
8530
8683
  }
8531
8684
  ),
8532
- /* @__PURE__ */ jsx15(conversation_drawer_default, { open: drawerOpen, onClose: () => setDrawerOpen(false) }),
8533
- /* @__PURE__ */ jsx15(enhanced_mobile_conversations_modal_default, { open: modalOpen, onClose: () => setModalOpen(false) }),
8534
- /* @__PURE__ */ jsxs12(
8535
- Dialog5,
8685
+ /* @__PURE__ */ jsx16(conversation_drawer_default, { open: drawerOpen, onClose: () => setDrawerOpen(false) }),
8686
+ /* @__PURE__ */ jsx16(enhanced_mobile_conversations_modal_default, { open: modalOpen, onClose: () => setModalOpen(false) }),
8687
+ /* @__PURE__ */ jsxs13(
8688
+ Dialog6,
8536
8689
  {
8537
8690
  open: confirmModelChangeOpen,
8538
8691
  onClose: () => setConfirmModelChangeOpen(false),
8539
8692
  children: [
8540
- /* @__PURE__ */ jsx15(DialogTitle5, { children: "Change personality and start new conversation?" }),
8541
- /* @__PURE__ */ jsx15(DialogContent5, { children: /* @__PURE__ */ jsxs12(Box12, { display: "flex", alignItems: "center", gap: 2, mt: 1, justifyContent: "center", children: [
8542
- /* @__PURE__ */ jsx15(
8693
+ /* @__PURE__ */ jsx16(DialogTitle5, { children: "Change personality and start new conversation?" }),
8694
+ /* @__PURE__ */ jsx16(DialogContent5, { children: /* @__PURE__ */ jsxs13(Box13, { display: "flex", alignItems: "center", gap: 2, mt: 1, justifyContent: "center", children: [
8695
+ /* @__PURE__ */ jsx16(
8543
8696
  Avatar8,
8544
8697
  {
8545
8698
  src: pendingModelAvatar,
@@ -8547,15 +8700,15 @@ var ChatAppBar = ({
8547
8700
  sx: { width: 40, height: 40, filter: "brightness(1.7)" }
8548
8701
  }
8549
8702
  ),
8550
- /* @__PURE__ */ jsxs12(Typography9, { variant: "body2", children: [
8703
+ /* @__PURE__ */ jsxs13(Typography9, { variant: "body2", children: [
8551
8704
  "Your current conversation will be saved, and a new one will begin with ",
8552
- /* @__PURE__ */ jsx15("strong", { children: pendingModel }),
8705
+ /* @__PURE__ */ jsx16("strong", { children: pendingModel }),
8553
8706
  "."
8554
8707
  ] })
8555
8708
  ] }) }),
8556
- /* @__PURE__ */ jsxs12(DialogActions5, { children: [
8557
- /* @__PURE__ */ jsx15(Button7, { onClick: () => setConfirmModelChangeOpen(false), children: "Cancel" }),
8558
- /* @__PURE__ */ jsx15(
8709
+ /* @__PURE__ */ jsxs13(DialogActions5, { children: [
8710
+ /* @__PURE__ */ jsx16(Button7, { onClick: () => setConfirmModelChangeOpen(false), children: "Cancel" }),
8711
+ /* @__PURE__ */ jsx16(
8559
8712
  Button7,
8560
8713
  {
8561
8714
  onClick: () => {
@@ -8658,19 +8811,19 @@ Respond with just the title and nothing else.
8658
8811
  };
8659
8812
 
8660
8813
  // src/chat/query-suggestion-picker.tsx
8661
- import { useEffect as useEffect13, useRef as useRef11, useState as useState15 } from "react";
8662
- import { Box as Box13, useMediaQuery as useMediaQuery6 } from "@mui/material";
8814
+ import { useEffect as useEffect13, useRef as useRef11, useState as useState16 } from "react";
8815
+ import { Box as Box14, useMediaQuery as useMediaQuery6 } from "@mui/material";
8663
8816
  import { useTheme as useTheme13, alpha as alpha8 } from "@mui/material/styles";
8664
8817
  import ReactMarkdown from "react-markdown";
8665
8818
  import remarkGfm from "remark-gfm";
8666
8819
  import rehypeRaw from "rehype-raw";
8667
- import { Fragment as Fragment9, jsx as jsx16 } from "react/jsx-runtime";
8820
+ import { Fragment as Fragment9, jsx as jsx17 } from "react/jsx-runtime";
8668
8821
  var markdownComponents = {
8669
- p: ({ node, ...props }) => /* @__PURE__ */ jsx16("span", { ...props }),
8670
- mark: ({ node, children, ...props }) => /* @__PURE__ */ jsx16("mark", { ...props, children }),
8822
+ p: ({ node, ...props }) => /* @__PURE__ */ jsx17("span", { ...props }),
8823
+ mark: ({ node, children, ...props }) => /* @__PURE__ */ jsx17("mark", { ...props, children }),
8671
8824
  code: ({ node, children, ...props }) => {
8672
8825
  const { inline, ...rest } = props;
8673
- return inline ? /* @__PURE__ */ jsx16("code", { ...rest, children }) : /* @__PURE__ */ jsx16("code", { ...rest, children });
8826
+ return inline ? /* @__PURE__ */ jsx17("code", { ...rest, children }) : /* @__PURE__ */ jsx17("code", { ...rest, children });
8674
8827
  }
8675
8828
  };
8676
8829
  var QuerySuggestionPicker = ({
@@ -8678,9 +8831,9 @@ var QuerySuggestionPicker = ({
8678
8831
  inputHeight
8679
8832
  }) => {
8680
8833
  const hasGenerated = useRef11(false);
8681
- const [hasSentPrompt, setHasSentPrompt] = useState15(false);
8682
- const [examplePrompts, setExamplePrompts] = useState15([]);
8683
- const [visiblePrompts, setVisiblePrompts] = useState15([]);
8834
+ const [hasSentPrompt, setHasSentPrompt] = useState16(false);
8835
+ const [examplePrompts, setExamplePrompts] = useState16([]);
8836
+ const [visiblePrompts, setVisiblePrompts] = useState16([]);
8684
8837
  const scrollRef = useRef11(null);
8685
8838
  const theme = useTheme13();
8686
8839
  const isMobile = useMediaQuery6((theme2) => theme2.breakpoints.down("sm"));
@@ -8743,8 +8896,8 @@ var QuerySuggestionPicker = ({
8743
8896
  return () => clearInterval(interval);
8744
8897
  }, [hasSentPrompt, examplePrompts.length]);
8745
8898
  const displayPrompts = isMobile ? visiblePrompts.slice(0, Math.min(visiblePrompts.length, 6)) : visiblePrompts;
8746
- return displayPrompts.length > 0 && /* @__PURE__ */ jsx16(Fragment9, { children: /* @__PURE__ */ jsx16(
8747
- Box13,
8899
+ return displayPrompts.length > 0 && /* @__PURE__ */ jsx17(Fragment9, { children: /* @__PURE__ */ jsx17(
8900
+ Box14,
8748
8901
  {
8749
8902
  ref: scrollRef,
8750
8903
  sx: {
@@ -8760,8 +8913,8 @@ var QuerySuggestionPicker = ({
8760
8913
  pb: isMobile ? 0.4 : 0,
8761
8914
  "&::-webkit-scrollbar": { display: "none" }
8762
8915
  },
8763
- children: displayPrompts.map((prompt, i) => /* @__PURE__ */ jsx16(
8764
- Box13,
8916
+ children: displayPrompts.map((prompt, i) => /* @__PURE__ */ jsx17(
8917
+ Box14,
8765
8918
  {
8766
8919
  sx: {
8767
8920
  px: isMobile ? 1.4 : 2,
@@ -8795,8 +8948,8 @@ var QuerySuggestionPicker = ({
8795
8948
  onSend(prompt, []);
8796
8949
  setHasSentPrompt(true);
8797
8950
  },
8798
- children: /* @__PURE__ */ jsx16(
8799
- Box13,
8951
+ children: /* @__PURE__ */ jsx17(
8952
+ Box14,
8800
8953
  {
8801
8954
  sx: {
8802
8955
  flex: 1,
@@ -8820,7 +8973,7 @@ var QuerySuggestionPicker = ({
8820
8973
  padding: "0.1em 0.25em"
8821
8974
  }
8822
8975
  },
8823
- children: /* @__PURE__ */ jsx16(
8976
+ children: /* @__PURE__ */ jsx17(
8824
8977
  ReactMarkdown,
8825
8978
  {
8826
8979
  remarkPlugins: [remarkGfm],
@@ -8839,9 +8992,9 @@ var QuerySuggestionPicker = ({
8839
8992
  };
8840
8993
 
8841
8994
  // ../../src/pages/under-review.tsx
8842
- import { Box as Box14, Typography as Typography10, useTheme as useTheme14 } from "@mui/material";
8995
+ import { Box as Box15, Typography as Typography10, useTheme as useTheme14 } from "@mui/material";
8843
8996
  import { useNavigate as useNavigate2 } from "react-router-dom";
8844
- import { jsx as jsx17, jsxs as jsxs13 } from "react/jsx-runtime";
8997
+ import { jsx as jsx18, jsxs as jsxs14 } from "react/jsx-runtime";
8845
8998
  var UnderReview = () => {
8846
8999
  const theme = useTheme14();
8847
9000
  const navigate = useNavigate2();
@@ -8849,8 +9002,8 @@ var UnderReview = () => {
8849
9002
  localStorage.removeItem("authToken");
8850
9003
  navigate("/login");
8851
9004
  };
8852
- return /* @__PURE__ */ jsxs13(
8853
- Box14,
9005
+ return /* @__PURE__ */ jsxs14(
9006
+ Box15,
8854
9007
  {
8855
9008
  sx: {
8856
9009
  minHeight: "100vh",
@@ -8865,8 +9018,8 @@ var UnderReview = () => {
8865
9018
  position: "relative"
8866
9019
  },
8867
9020
  children: [
8868
- /* @__PURE__ */ jsx17(
8869
- Box14,
9021
+ /* @__PURE__ */ jsx18(
9022
+ Box15,
8870
9023
  {
8871
9024
  onClick: handleSneakyLogout,
8872
9025
  sx: {
@@ -8891,13 +9044,13 @@ var UnderReview = () => {
8891
9044
  title: "Reset session"
8892
9045
  }
8893
9046
  ),
8894
- /* @__PURE__ */ jsx17(Typography10, { variant: "h4", sx: { mb: 2, fontWeight: 700, color: theme.palette.error.main }, children: "Under Review" }),
8895
- /* @__PURE__ */ jsxs13(Typography10, { variant: "body1", sx: { mb: 2, color: theme.palette.text.secondary }, children: [
9047
+ /* @__PURE__ */ jsx18(Typography10, { variant: "h4", sx: { mb: 2, fontWeight: 700, color: theme.palette.error.main }, children: "Under Review" }),
9048
+ /* @__PURE__ */ jsxs14(Typography10, { variant: "body1", sx: { mb: 2, color: theme.palette.text.secondary }, children: [
8896
9049
  "Your request to use our services is currently being reviewed.",
8897
- /* @__PURE__ */ jsx17("br", {}),
9050
+ /* @__PURE__ */ jsx18("br", {}),
8898
9051
  "For more info, please contact ",
8899
9052
  " ",
8900
- /* @__PURE__ */ jsx17("a", { href: "mailto:team@banditai.ai", style: { color: theme.palette.primary.main, fontWeight: 600 }, children: "team@banditai.ai" })
9053
+ /* @__PURE__ */ jsx18("a", { href: "mailto:team@banditai.ai", style: { color: theme.palette.primary.main, fontWeight: 600 }, children: "team@banditai.ai" })
8901
9054
  ] })
8902
9055
  ]
8903
9056
  }
@@ -8906,8 +9059,8 @@ var UnderReview = () => {
8906
9059
  var under_review_default = UnderReview;
8907
9060
 
8908
9061
  // src/components/ConnectionStatus.tsx
8909
- import { Box as Box15, Chip as Chip5, useTheme as useTheme15 } from "@mui/material";
8910
- import { jsx as jsx18 } from "react/jsx-runtime";
9062
+ import { Box as Box16, Chip as Chip5, useTheme as useTheme15 } from "@mui/material";
9063
+ import { jsx as jsx19 } from "react/jsx-runtime";
8911
9064
  var ConnectionStatus = ({
8912
9065
  showWhenGood = false,
8913
9066
  position = "top"
@@ -8921,28 +9074,28 @@ var ConnectionStatus = ({
8921
9074
  switch (connectionQuality) {
8922
9075
  case "offline":
8923
9076
  return {
8924
- icon: /* @__PURE__ */ jsx18(WifiOffIcon, { sx: { fontSize: 16 } }),
9077
+ icon: /* @__PURE__ */ jsx19(WifiOffIcon, { sx: { fontSize: 16 } }),
8925
9078
  label: "Offline",
8926
9079
  color: "error",
8927
9080
  severity: "high"
8928
9081
  };
8929
9082
  case "slow":
8930
9083
  return {
8931
- icon: /* @__PURE__ */ jsx18(SignalWifi2BarIcon, { sx: { fontSize: 16 } }),
9084
+ icon: /* @__PURE__ */ jsx19(SignalWifi2BarIcon, { sx: { fontSize: 16 } }),
8932
9085
  label: "Slow connection",
8933
9086
  color: "warning",
8934
9087
  severity: "medium"
8935
9088
  };
8936
9089
  case "fast":
8937
9090
  return {
8938
- icon: /* @__PURE__ */ jsx18(WifiIcon, { sx: { fontSize: 16 } }),
9091
+ icon: /* @__PURE__ */ jsx19(WifiIcon, { sx: { fontSize: 16 } }),
8939
9092
  label: "Connected",
8940
9093
  color: "success",
8941
9094
  severity: "low"
8942
9095
  };
8943
9096
  default:
8944
9097
  return {
8945
- icon: /* @__PURE__ */ jsx18(WifiIcon, { sx: { fontSize: 16 } }),
9098
+ icon: /* @__PURE__ */ jsx19(WifiIcon, { sx: { fontSize: 16 } }),
8946
9099
  label: "Unknown",
8947
9100
  color: "default",
8948
9101
  severity: "low"
@@ -8950,8 +9103,8 @@ var ConnectionStatus = ({
8950
9103
  }
8951
9104
  };
8952
9105
  const config = getStatusConfig();
8953
- return /* @__PURE__ */ jsx18(
8954
- Box15,
9106
+ return /* @__PURE__ */ jsx19(
9107
+ Box16,
8955
9108
  {
8956
9109
  sx: {
8957
9110
  position: "fixed",
@@ -8966,7 +9119,7 @@ var ConnectionStatus = ({
8966
9119
  "100%": { opacity: 1 }
8967
9120
  }
8968
9121
  },
8969
- children: /* @__PURE__ */ jsx18(
9122
+ children: /* @__PURE__ */ jsx19(
8970
9123
  Chip5,
8971
9124
  {
8972
9125
  icon: config.icon,
@@ -9279,7 +9432,7 @@ var useVoiceMode = (config) => {
9279
9432
  };
9280
9433
 
9281
9434
  // src/chat/chat.tsx
9282
- import { jsx as jsx19, jsxs as jsxs14 } from "react/jsx-runtime";
9435
+ import { jsx as jsx20, jsxs as jsxs15 } from "react/jsx-runtime";
9283
9436
  var ChatContent = () => {
9284
9437
  const packageSettings = usePackageSettingsStore((state) => state.settings);
9285
9438
  const featureFlag = useFeatureFlag();
@@ -9287,8 +9440,8 @@ var ChatContent = () => {
9287
9440
  const ossMode = isOSSMode() || !packageSettings?.featureFlags?.subscriptionType;
9288
9441
  const playgroundBypassAccess = packageSettings?.playgroundBypassAuth || typeof window !== "undefined" && window.location.pathname.includes("/playground");
9289
9442
  const notificationService = useNotificationService();
9290
- const [selectedTheme, setSelectedTheme] = useState16(null);
9291
- const [themeLoading, setThemeLoading] = useState16(true);
9443
+ const [selectedTheme, setSelectedTheme] = useState17(null);
9444
+ const [themeLoading, setThemeLoading] = useState17(true);
9292
9445
  const token = authenticationService.getToken();
9293
9446
  const claims = token ? authenticationService.parseJwtClaims(token) : null;
9294
9447
  const baseTheme = themeMap_default[selectedTheme ?? "bandit-dark"] || banditDarkTheme;
@@ -9339,6 +9492,7 @@ var ChatContent = () => {
9339
9492
  initialized
9340
9493
  } = useVoiceStore();
9341
9494
  const isVoiceModeEnabled = useVoiceModeStore((state) => state.enabled);
9495
+ const canvasOpen = useCanvasStore((state) => state.open);
9342
9496
  const previousVoiceModeEnabledRef = useRef13(isVoiceModeEnabled);
9343
9497
  const historyRef = useRef13(history);
9344
9498
  useEffect15(() => {
@@ -9387,14 +9541,14 @@ var ChatContent = () => {
9387
9541
  }, [packageSettings?.gatewayApiUrl, availableVoices.length, initialized, loadVoicesFromAPI, token]);
9388
9542
  const provider = useAIProviderStore((state) => state.provider);
9389
9543
  const inputRef = useRef13(null);
9390
- const [pastedImages, setPastedImages] = useState16([]);
9544
+ const [pastedImages, setPastedImages] = useState17([]);
9391
9545
  const inputContainerRef = useRef13(null);
9392
- const [inputHeight, setInputHeight] = useState16(80);
9393
- const [isSubmitting, setIsSubmitting] = useState16(false);
9394
- const [pendingMessage, setPendingMessage] = useState16(null);
9546
+ const [inputHeight, setInputHeight] = useState17(80);
9547
+ const [isSubmitting, setIsSubmitting] = useState17(false);
9548
+ const [pendingMessage, setPendingMessage] = useState17(null);
9395
9549
  const { conversations, currentId, _hasHydrated, hydrate } = useConversationStore();
9396
- const [isMobile, setIsMobile] = useState16(false);
9397
- const [drawerOpen, setDrawerOpen] = useState16(false);
9550
+ const [isMobile, setIsMobile] = useState17(false);
9551
+ const [drawerOpen, setDrawerOpen] = useState17(false);
9398
9552
  const { generateName } = useConversationNameGenerator();
9399
9553
  const { preferences } = usePreferencesStore();
9400
9554
  const { containerRef: chatContainerRef, targetRef: scrollTargetRef, scrollToBottom, getScrollState } = useAutoScroll({
@@ -9406,14 +9560,14 @@ var ChatContent = () => {
9406
9560
  const chatContainerEl = chatContainerRef.current;
9407
9561
  const scrollTargetEl = scrollTargetRef.current;
9408
9562
  const { isSlowConnection, connectionQuality, trackRequestStart, trackRequestEnd } = useNetworkStatus();
9409
- const [showScrollToBottom, setShowScrollToBottom] = useState16(false);
9410
- const [streamBuffer, setStreamBuffer] = useState16("");
9411
- const [responseStarted, setResponseStarted] = useState16(false);
9412
- const [isStreaming, setIsStreaming] = useState16(false);
9413
- const [isThinking, setIsThinking] = useState16(false);
9563
+ const [showScrollToBottom, setShowScrollToBottom] = useState17(false);
9564
+ const [streamBuffer, setStreamBuffer] = useState17("");
9565
+ const [responseStarted, setResponseStarted] = useState17(false);
9566
+ const [isStreaming, setIsStreaming] = useState17(false);
9567
+ const [isThinking, setIsThinking] = useState17(false);
9414
9568
  const initialLogoState = history.length === 0;
9415
- const [logoVisible, setLogoVisible] = useState16(initialLogoState);
9416
- const [logoShouldRender, setLogoShouldRender] = useState16(initialLogoState);
9569
+ const [logoVisible, setLogoVisible] = useState17(initialLogoState);
9570
+ const [logoShouldRender, setLogoShouldRender] = useState17(initialLogoState);
9417
9571
  const streamingGraceUntilRef = useRef13(0);
9418
9572
  const GRACE_MS = 450;
9419
9573
  const GRACE_OFFSET_DESKTOP = 28;
@@ -9422,8 +9576,8 @@ var ChatContent = () => {
9422
9576
  const lastSpokenResponseRef = useRef13(null);
9423
9577
  const previousConversationIdRef = useRef13(null);
9424
9578
  const logoFadeTimeoutRef = useRef13(null);
9425
- const [branding, setBranding] = useState16(null);
9426
- const [brandingLoading, setBrandingLoading] = useState16(true);
9579
+ const [branding, setBranding] = useState17(null);
9580
+ const [brandingLoading, setBrandingLoading] = useState17(true);
9427
9581
  const isBrandingLoadInProgressRef = useRef13(false);
9428
9582
  const logoOnly = history.length === 0 && !brandingLoading;
9429
9583
  useEffect15(() => {
@@ -10191,10 +10345,10 @@ var ChatContent = () => {
10191
10345
  }
10192
10346
  };
10193
10347
  if (!hydrated || brandingLoading || themeLoading) {
10194
- return /* @__PURE__ */ jsxs14(ThemeProvider, { theme: banditTheme, children: [
10195
- /* @__PURE__ */ jsx19(CssBaseline, {}),
10196
- /* @__PURE__ */ jsxs14(
10197
- Box16,
10348
+ return /* @__PURE__ */ jsxs15(ThemeProvider, { theme: banditTheme, children: [
10349
+ /* @__PURE__ */ jsx20(CssBaseline, {}),
10350
+ /* @__PURE__ */ jsxs15(
10351
+ Box17,
10198
10352
  {
10199
10353
  sx: (theme) => ({
10200
10354
  minHeight: "100dvh",
@@ -10207,8 +10361,8 @@ var ChatContent = () => {
10207
10361
  color: theme.palette.text.primary
10208
10362
  }),
10209
10363
  children: [
10210
- /* @__PURE__ */ jsx19(CircularProgress4, { size: 32, thickness: 4 }),
10211
- /* @__PURE__ */ jsx19(Typography11, { variant: "body2", color: "text.secondary", children: "Preparing your workspace..." })
10364
+ /* @__PURE__ */ jsx20(CircularProgress4, { size: 32, thickness: 4 }),
10365
+ /* @__PURE__ */ jsx20(Typography11, { variant: "body2", color: "text.secondary", children: "Preparing your workspace..." })
10212
10366
  ]
10213
10367
  }
10214
10368
  )
@@ -10216,15 +10370,15 @@ var ChatContent = () => {
10216
10370
  }
10217
10371
  const userHasAccess = playgroundBypassAccess || ossMode || claims?.roles?.includes("super-user") || claims?.roles?.includes("admin");
10218
10372
  if (!userHasAccess) {
10219
- return /* @__PURE__ */ jsxs14(ThemeProvider, { theme: banditTheme, children: [
10220
- /* @__PURE__ */ jsx19(CssBaseline, {}),
10221
- /* @__PURE__ */ jsx19(under_review_default, {})
10373
+ return /* @__PURE__ */ jsxs15(ThemeProvider, { theme: banditTheme, children: [
10374
+ /* @__PURE__ */ jsx20(CssBaseline, {}),
10375
+ /* @__PURE__ */ jsx20(under_review_default, {})
10222
10376
  ] });
10223
10377
  }
10224
- return /* @__PURE__ */ jsxs14(ThemeProvider, { theme: banditTheme, children: [
10225
- /* @__PURE__ */ jsx19(CssBaseline, {}),
10226
- /* @__PURE__ */ jsxs14(
10227
- Box16,
10378
+ return /* @__PURE__ */ jsxs15(ThemeProvider, { theme: banditTheme, children: [
10379
+ /* @__PURE__ */ jsx20(CssBaseline, {}),
10380
+ /* @__PURE__ */ jsxs15(
10381
+ Box17,
10228
10382
  {
10229
10383
  sx: (theme) => ({
10230
10384
  display: "flex",
@@ -10237,12 +10391,12 @@ var ChatContent = () => {
10237
10391
  position: "fixed",
10238
10392
  top: 0,
10239
10393
  left: drawerOpen && !isMobile ? "340px" : 0,
10240
- width: drawerOpen && !isMobile ? "calc(100vw - 340px)" : "100vw",
10394
+ width: !isMobile && canvasOpen ? `calc(100vw - ${drawerOpen ? "340px" : "0px"} - ${CANVAS_WIDTH})` : drawerOpen && !isMobile ? "calc(100vw - 340px)" : "100vw",
10241
10395
  zIndex: 0,
10242
10396
  transition: "left 0.3s ease-in-out, width 0.3s ease-in-out"
10243
10397
  }),
10244
10398
  children: [
10245
- /* @__PURE__ */ jsx19(
10399
+ /* @__PURE__ */ jsx20(
10246
10400
  chat_app_bar_default,
10247
10401
  {
10248
10402
  availableModels,
@@ -10254,8 +10408,8 @@ var ChatContent = () => {
10254
10408
  setDrawerOpen
10255
10409
  }
10256
10410
  ),
10257
- /* @__PURE__ */ jsx19(
10258
- Box16,
10411
+ /* @__PURE__ */ jsx20(
10412
+ Box17,
10259
10413
  {
10260
10414
  ref: chatContainerRef,
10261
10415
  sx: {
@@ -10275,8 +10429,8 @@ var ChatContent = () => {
10275
10429
  msOverflowStyle: "none",
10276
10430
  "&::-webkit-scrollbar": { display: "none" }
10277
10431
  },
10278
- children: /* @__PURE__ */ jsxs14(
10279
- Box16,
10432
+ children: /* @__PURE__ */ jsxs15(
10433
+ Box17,
10280
10434
  {
10281
10435
  sx: {
10282
10436
  width: "100%",
@@ -10286,9 +10440,9 @@ var ChatContent = () => {
10286
10440
  pt: 2
10287
10441
  },
10288
10442
  children: [
10289
- logoShouldRender && !brandingLoading && (branding?.logoBase64 ? /* @__PURE__ */ jsx19(custom_logo_default, { visible: logoVisible, atTop: true }) : /* @__PURE__ */ jsx19(bandit_chat_logo_default, { visible: logoVisible, atTop: true })),
10290
- /* @__PURE__ */ jsx19(
10291
- Box16,
10443
+ logoShouldRender && !brandingLoading && (branding?.logoBase64 ? /* @__PURE__ */ jsx20(custom_logo_default, { visible: logoVisible, atTop: true }) : /* @__PURE__ */ jsx20(bandit_chat_logo_default, { visible: logoVisible, atTop: true })),
10444
+ /* @__PURE__ */ jsx20(
10445
+ Box17,
10292
10446
  {
10293
10447
  sx: {
10294
10448
  margin: "0 auto",
@@ -10297,7 +10451,7 @@ var ChatContent = () => {
10297
10451
  flexShrink: 0,
10298
10452
  px: isMobile ? 0 : 0
10299
10453
  },
10300
- children: /* @__PURE__ */ jsx19(
10454
+ children: /* @__PURE__ */ jsx20(
10301
10455
  chat_messages_default,
10302
10456
  {
10303
10457
  isStreaming,
@@ -10321,7 +10475,7 @@ var ChatContent = () => {
10321
10475
  )
10322
10476
  }
10323
10477
  ),
10324
- showScrollToBottom && /* @__PURE__ */ jsx19(
10478
+ showScrollToBottom && /* @__PURE__ */ jsx20(
10325
10479
  chat_scroll_to_bottom_button_default,
10326
10480
  {
10327
10481
  inputHeight,
@@ -10330,8 +10484,8 @@ var ChatContent = () => {
10330
10484
  onClick: handleScrollToBottomClick
10331
10485
  }
10332
10486
  ),
10333
- history.length === 0 && componentStatus !== "Loading" && !isMobile && /* @__PURE__ */ jsx19(
10334
- Box16,
10487
+ history.length === 0 && componentStatus !== "Loading" && !isMobile && /* @__PURE__ */ jsx20(
10488
+ Box17,
10335
10489
  {
10336
10490
  sx: (theme) => ({
10337
10491
  position: "absolute",
@@ -10349,8 +10503,8 @@ var ChatContent = () => {
10349
10503
  })
10350
10504
  }
10351
10505
  ),
10352
- /* @__PURE__ */ jsxs14(
10353
- Box16,
10506
+ /* @__PURE__ */ jsxs15(
10507
+ Box17,
10354
10508
  {
10355
10509
  sx: {
10356
10510
  display: "flex",
@@ -10361,10 +10515,10 @@ var ChatContent = () => {
10361
10515
  maxWidth: "768px"
10362
10516
  },
10363
10517
  children: [
10364
- /* @__PURE__ */ jsx19(Box16, { sx: { flex: "1 1 auto" } }),
10365
- history.length === 0 && componentStatus !== "Loading" && !pendingMessage && preferences.chatSuggestionsEnabled && /* @__PURE__ */ jsx19(Box16, { sx: { marginBottom: "20px" }, children: /* @__PURE__ */ jsx19(QuerySuggestionPicker, { onSend: handleSend, inputHeight }) }),
10366
- /* @__PURE__ */ jsx19(ask_user_card_default, {}),
10367
- /* @__PURE__ */ jsx19(
10518
+ /* @__PURE__ */ jsx20(Box17, { sx: { flex: "1 1 auto" } }),
10519
+ history.length === 0 && componentStatus !== "Loading" && !pendingMessage && preferences.chatSuggestionsEnabled && /* @__PURE__ */ jsx20(Box17, { sx: { marginBottom: "20px" }, children: /* @__PURE__ */ jsx20(QuerySuggestionPicker, { onSend: handleSend, inputHeight }) }),
10520
+ /* @__PURE__ */ jsx20(ask_user_card_default, {}),
10521
+ /* @__PURE__ */ jsx20(
10368
10522
  chat_input_default,
10369
10523
  {
10370
10524
  inputValue,
@@ -10391,7 +10545,7 @@ var ChatContent = () => {
10391
10545
  ]
10392
10546
  }
10393
10547
  ),
10394
- preferences.feedbackEnabled && !isMobile && /* @__PURE__ */ jsx19(
10548
+ preferences.feedbackEnabled && !isMobile && /* @__PURE__ */ jsx20(
10395
10549
  FeedbackButton,
10396
10550
  {
10397
10551
  fullScreen: false,
@@ -10404,10 +10558,11 @@ var ChatContent = () => {
10404
10558
  }
10405
10559
  }
10406
10560
  ),
10407
- /* @__PURE__ */ jsx19(ConnectionStatus, { position: "top", showWhenGood: false })
10561
+ /* @__PURE__ */ jsx20(ConnectionStatus, { position: "top", showWhenGood: false })
10408
10562
  ]
10409
10563
  }
10410
- )
10564
+ ),
10565
+ /* @__PURE__ */ jsx20(canvas_panel_default, { isMobile })
10411
10566
  ] });
10412
10567
  };
10413
10568
  var Chat = () => {
@@ -10433,13 +10588,13 @@ var Chat = () => {
10433
10588
  });
10434
10589
  if (!allowUnauthenticated && !bypassAuth && !authenticationService.isAuthenticated()) {
10435
10590
  debugLogger.debug("User is not authenticated, redirecting to login");
10436
- return /* @__PURE__ */ jsx19(Navigate, { to: "/login", replace: true });
10591
+ return /* @__PURE__ */ jsx20(Navigate, { to: "/login", replace: true });
10437
10592
  }
10438
- return /* @__PURE__ */ jsx19(ChatContent, {});
10593
+ return /* @__PURE__ */ jsx20(ChatContent, {});
10439
10594
  };
10440
10595
  var chat_default = Chat;
10441
10596
 
10442
10597
  export {
10443
10598
  chat_default
10444
10599
  };
10445
- //# sourceMappingURL=chunk-PROLD2QV.mjs.map
10600
+ //# sourceMappingURL=chunk-42X7ZU6O.mjs.map