@adecore/agents-react 0.67.0 → 0.68.0

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.
Files changed (77) hide show
  1. package/dist/agents/AgentIcon.d.ts +7 -0
  2. package/dist/agents/AgentIcon.js +70 -31
  3. package/dist/chat/logic/timeline.d.ts +2 -0
  4. package/dist/chat/logic/timeline.js +47 -0
  5. package/dist/chat/subagent-list.d.ts +1 -2
  6. package/dist/chat/ui/Composer.js +491 -447
  7. package/dist/chat/ui/Markdown.d.ts +1 -1
  8. package/dist/chat/ui/Markdown.js +277 -203
  9. package/dist/chat/ui/PromptEditor.d.ts +3 -1
  10. package/dist/chat/ui/PromptEditor.js +4 -1
  11. package/dist/chat/ui/Timeline.js +5 -4
  12. package/dist/chat/ui/composer/ComposerMenu.js +22 -12
  13. package/dist/chat/ui/composer/chips.d.ts +2 -1
  14. package/dist/chat/ui/composer/chips.js +44 -1
  15. package/dist/chat/ui/composer/key-handler.d.ts +2 -0
  16. package/dist/chat/ui/composer/key-handler.js +12 -2
  17. package/dist/chat/ui/composer/placeholder.d.ts +2 -1
  18. package/dist/chat/ui/composer/placeholder.js +31 -10
  19. package/dist/chat/ui/composer/use-composer-menus.js +49 -39
  20. package/dist/chat/ui/composer/use-prompt-menus.d.ts +10 -7
  21. package/dist/chat/ui/composer/use-prompt-menus.js +183 -157
  22. package/dist/chat/ui/composer/use-prompt-suggestion.d.ts +16 -0
  23. package/dist/chat/ui/composer/use-prompt-suggestion.js +55 -0
  24. package/dist/chat/ui/index.d.ts +1 -1
  25. package/dist/chat/ui/index.js +1 -1
  26. package/dist/chat/ui/markdown-cache.d.ts +4 -0
  27. package/dist/chat/ui/markdown-cache.js +47 -0
  28. package/dist/chat/ui/reference-lookup.d.ts +2 -1
  29. package/dist/chat/ui/reference-lookup.js +1 -1
  30. package/dist/chat/ui/rows/SubagentRow.js +26 -24
  31. package/dist/chat/ui/rows/TaskRow.d.ts +11 -1
  32. package/dist/chat/ui/rows/TaskRow.js +281 -197
  33. package/dist/chat/ui/thread-references.js +12 -9
  34. package/dist/chat-client.d.ts +3 -1
  35. package/dist/chat-client.js +82 -30
  36. package/dist/chat-sink.d.ts +1 -0
  37. package/dist/host/host-hooks.d.ts +4 -1
  38. package/dist/host/host-hooks.js +11 -0
  39. package/dist/host/host.d.ts +18 -0
  40. package/dist/index.d.ts +1 -1
  41. package/dist/locales/en/agent-chat.d.ts +1 -0
  42. package/dist/locales/en/agent-chat.js +2 -1
  43. package/dist/locales/nl/agent-chat.d.ts +1 -0
  44. package/dist/locales/nl/agent-chat.js +2 -1
  45. package/dist/state/chats.d.ts +2 -0
  46. package/dist/state/chats.js +21 -5
  47. package/dist/theme.css +6 -0
  48. package/package.json +9 -9
  49. package/src/agents/AgentIcon.tsx +6 -2
  50. package/src/chat/logic/timeline.ts +63 -0
  51. package/src/chat/subagent-list.ts +1 -4
  52. package/src/chat/ui/Composer.tsx +15 -2
  53. package/src/chat/ui/Markdown.tsx +97 -55
  54. package/src/chat/ui/PromptEditor.tsx +7 -2
  55. package/src/chat/ui/Timeline.tsx +17 -14
  56. package/src/chat/ui/composer/ComposerMenu.tsx +14 -6
  57. package/src/chat/ui/composer/chips.ts +51 -2
  58. package/src/chat/ui/composer/key-handler.ts +17 -2
  59. package/src/chat/ui/composer/placeholder.ts +14 -3
  60. package/src/chat/ui/composer/use-composer-menus.ts +8 -3
  61. package/src/chat/ui/composer/use-prompt-menus.ts +33 -4
  62. package/src/chat/ui/composer/use-prompt-suggestion.ts +36 -0
  63. package/src/chat/ui/index.ts +1 -1
  64. package/src/chat/ui/markdown-cache.ts +60 -0
  65. package/src/chat/ui/reference-lookup.ts +4 -2
  66. package/src/chat/ui/rows/SubagentRow.tsx +1 -1
  67. package/src/chat/ui/rows/TaskRow.tsx +54 -9
  68. package/src/chat/ui/thread-references.ts +4 -2
  69. package/src/chat-client.ts +79 -22
  70. package/src/chat-sink.ts +6 -1
  71. package/src/host/host-hooks.ts +19 -1
  72. package/src/host/host.ts +41 -0
  73. package/src/index.ts +3 -0
  74. package/src/locales/en/agent-chat.ts +2 -1
  75. package/src/locales/nl/agent-chat.ts +2 -1
  76. package/src/state/chats.ts +22 -6
  77. package/src/theme.css +6 -0
@@ -39,6 +39,7 @@ import { useNotice } from './composer/use-notice.js';
39
39
  import { usePendingRequests } from './composer/use-pending-requests.js';
40
40
  import { usePromptHistory } from './composer/use-prompt-history.js';
41
41
  import { usePromptHold } from './composer/use-prompt-hold.js';
42
+ import { usePromptSuggestion } from './composer/use-prompt-suggestion.js';
42
43
  import { useTakeBack } from './composer/use-take-back.js';
43
44
  import { ComposerInput } from './ComposerInput.js';
44
45
  import { GoalDock } from './GoalDock.js';
@@ -56,7 +57,7 @@ function sendLabelKey(busy, steerable, delivery) {
56
57
  return delivery === 'steer' ? 'composer.steerButton' : 'composer.queueWithSteerButton';
57
58
  }
58
59
  export function Composer(t0) {
59
- const $ = _c(248);
60
+ const $ = _c(260);
60
61
  const {
61
62
  chatId,
62
63
  info,
@@ -300,96 +301,137 @@ export function Composer(t0) {
300
301
  }
301
302
  const sigils = t16;
302
303
  let t17;
303
- if ($[49] !== chatId || $[50] !== disabled || $[51] !== readOnly || $[52] !== sigils) {
304
- t17 = {
304
+ if ($[49] !== draft) {
305
+ t17 = isEmptyDraft(draft);
306
+ $[49] = draft;
307
+ $[50] = t17;
308
+ } else {
309
+ t17 = $[50];
310
+ }
311
+ const t18 = pending.length > 0;
312
+ let t19;
313
+ if ($[51] === Symbol.for("react.memo_cache_sentinel")) {
314
+ t19 = text_0 => inputRef.current?.insert(text_0);
315
+ $[51] = t19;
316
+ } else {
317
+ t19 = $[51];
318
+ }
319
+ let t20;
320
+ if ($[52] !== chatId || $[53] !== info || $[54] !== t17 || $[55] !== t18 || $[56] !== writable) {
321
+ t20 = {
322
+ chatId,
323
+ info,
324
+ empty: t17,
325
+ writable,
326
+ asked: t18,
327
+ fill: t19
328
+ };
329
+ $[52] = chatId;
330
+ $[53] = info;
331
+ $[54] = t17;
332
+ $[55] = t18;
333
+ $[56] = writable;
334
+ $[57] = t20;
335
+ } else {
336
+ t20 = $[57];
337
+ }
338
+ const suggestion = usePromptSuggestion(t20);
339
+ const t21 = suggestion?.text ?? null;
340
+ let t22;
341
+ if ($[58] !== chatId || $[59] !== disabled || $[60] !== readOnly || $[61] !== sigils || $[62] !== t21) {
342
+ t22 = {
305
343
  chatId,
306
344
  disabled,
307
345
  readOnly,
346
+ suggestion: t21,
308
347
  ...sigils
309
348
  };
310
- $[49] = chatId;
311
- $[50] = disabled;
312
- $[51] = readOnly;
313
- $[52] = sigils;
314
- $[53] = t17;
315
- } else {
316
- t17 = $[53];
317
- }
318
- const placeholder = useHintedPlaceholder(t17);
319
- let t18;
320
- if ($[54] !== draft.mentions || $[55] !== draft.skills || $[56] !== host.ReferenceIcon || $[57] !== menus.namedLook || $[58] !== menus.referenceChips) {
321
- t18 = chipDecorations({
349
+ $[58] = chatId;
350
+ $[59] = disabled;
351
+ $[60] = readOnly;
352
+ $[61] = sigils;
353
+ $[62] = t21;
354
+ $[63] = t22;
355
+ } else {
356
+ t22 = $[63];
357
+ }
358
+ const placeholder = useHintedPlaceholder(t22);
359
+ let t23;
360
+ if ($[64] !== draft.mentions || $[65] !== draft.skills || $[66] !== host.ReferenceIcon || $[67] !== menus.hostSkills || $[68] !== menus.namedLook || $[69] !== menus.referenceChips) {
361
+ t23 = chipDecorations({
322
362
  mentions: draft.mentions,
323
363
  skills: draft.skills,
324
364
  references: menus.referenceChips,
325
365
  referenceIcon: host.ReferenceIcon,
326
- named: menus.namedLook
366
+ named: menus.namedLook,
367
+ hostSkills: menus.hostSkills
327
368
  });
328
- $[54] = draft.mentions;
329
- $[55] = draft.skills;
330
- $[56] = host.ReferenceIcon;
331
- $[57] = menus.namedLook;
332
- $[58] = menus.referenceChips;
333
- $[59] = t18;
369
+ $[64] = draft.mentions;
370
+ $[65] = draft.skills;
371
+ $[66] = host.ReferenceIcon;
372
+ $[67] = menus.hostSkills;
373
+ $[68] = menus.namedLook;
374
+ $[69] = menus.referenceChips;
375
+ $[70] = t23;
334
376
  } else {
335
- t18 = $[59];
377
+ t23 = $[70];
336
378
  }
337
- let t19;
338
- if ($[60] !== t18) {
339
- t19 = [t18, LEAVE_DROPS_TO_THE_CARD];
340
- $[60] = t18;
341
- $[61] = t19;
379
+ let t24;
380
+ if ($[71] !== t23) {
381
+ t24 = [t23, LEAVE_DROPS_TO_THE_CARD];
382
+ $[71] = t23;
383
+ $[72] = t24;
342
384
  } else {
343
- t19 = $[61];
385
+ t24 = $[72];
344
386
  }
345
- const editorExtensions = t19;
346
- let t20;
347
- if ($[62] !== chatId) {
348
- t20 = () => timelineAtEnd(chatId);
349
- $[62] = chatId;
350
- $[63] = t20;
387
+ const editorExtensions = t24;
388
+ let t25;
389
+ if ($[73] !== chatId) {
390
+ t25 = () => timelineAtEnd(chatId);
391
+ $[73] = chatId;
392
+ $[74] = t25;
351
393
  } else {
352
- t20 = $[63];
394
+ t25 = $[74];
353
395
  }
354
- const atEnd = useSyncExternalStore(subscribeTimelineEnd, t20, _temp3);
355
- let t21;
356
- if ($[64] !== info.queue) {
357
- t21 = info.queue ?? [];
358
- $[64] = info.queue;
359
- $[65] = t21;
396
+ const atEnd = useSyncExternalStore(subscribeTimelineEnd, t25, _temp3);
397
+ let t26;
398
+ if ($[75] !== info.queue) {
399
+ t26 = info.queue ?? [];
400
+ $[75] = info.queue;
401
+ $[76] = t26;
360
402
  } else {
361
- t21 = $[65];
403
+ t26 = $[76];
362
404
  }
363
- const queue = t21;
364
- let t22;
365
- if ($[66] !== draft) {
366
- t22 = isEmptyDraft(draft);
367
- $[66] = draft;
368
- $[67] = t22;
405
+ const queue = t26;
406
+ let t27;
407
+ if ($[77] !== draft) {
408
+ t27 = isEmptyDraft(draft);
409
+ $[77] = draft;
410
+ $[78] = t27;
369
411
  } else {
370
- t22 = $[67];
412
+ t27 = $[78];
371
413
  }
372
- const empty = t22;
373
- let t23;
374
- let t24;
375
- if ($[68] !== focused) {
376
- t23 = () => {
414
+ const empty = t27;
415
+ let t28;
416
+ let t29;
417
+ if ($[79] !== focused) {
418
+ t28 = () => {
377
419
  if (focused) {
378
420
  inputRef.current?.focus();
379
421
  }
380
422
  };
381
- t24 = [focused];
382
- $[68] = focused;
383
- $[69] = t23;
384
- $[70] = t24;
423
+ t29 = [focused];
424
+ $[79] = focused;
425
+ $[80] = t28;
426
+ $[81] = t29;
385
427
  } else {
386
- t23 = $[69];
387
- t24 = $[70];
428
+ t28 = $[80];
429
+ t29 = $[81];
388
430
  }
389
- useEffect(t23, t24);
390
- let t25;
391
- if ($[71] !== chatId || $[72] !== draft.text || $[73] !== files.noteKey || $[74] !== history || $[75] !== host || $[76] !== menus || $[77] !== sendKey || $[78] !== submit || $[79] !== toggleStash) {
392
- t25 = composerKeyHandler({
431
+ useEffect(t28, t29);
432
+ let t30;
433
+ if ($[82] !== chatId || $[83] !== draft.text || $[84] !== files.noteKey || $[85] !== history || $[86] !== host || $[87] !== menus || $[88] !== sendKey || $[89] !== submit || $[90] !== suggestion || $[91] !== toggleStash) {
434
+ t30 = composerKeyHandler({
393
435
  chatId,
394
436
  host,
395
437
  sendKey,
@@ -397,43 +439,45 @@ export function Composer(t0) {
397
439
  menus,
398
440
  history,
399
441
  noteKey: files.noteKey,
442
+ suggestion,
400
443
  toggleStash,
401
444
  submit
402
445
  });
403
- $[71] = chatId;
404
- $[72] = draft.text;
405
- $[73] = files.noteKey;
406
- $[74] = history;
407
- $[75] = host;
408
- $[76] = menus;
409
- $[77] = sendKey;
410
- $[78] = submit;
411
- $[79] = toggleStash;
412
- $[80] = t25;
413
- } else {
414
- t25 = $[80];
415
- }
416
- const onKeyDown = t25;
446
+ $[82] = chatId;
447
+ $[83] = draft.text;
448
+ $[84] = files.noteKey;
449
+ $[85] = history;
450
+ $[86] = host;
451
+ $[87] = menus;
452
+ $[88] = sendKey;
453
+ $[89] = submit;
454
+ $[90] = suggestion;
455
+ $[91] = toggleStash;
456
+ $[92] = t30;
457
+ } else {
458
+ t30 = $[92];
459
+ }
460
+ const onKeyDown = t30;
417
461
  const pointSurface = _temp4;
418
- let t26;
419
- if ($[81] !== writable) {
420
- t26 = event_0 => {
462
+ let t31;
463
+ if ($[93] !== writable) {
464
+ t31 = event_0 => {
421
465
  if (!writable || event_0.button !== 0 || event_0.defaultPrevented || surfacePartOf(event_0.target, event_0.currentTarget) !== "surface") {
422
466
  return;
423
467
  }
424
468
  event_0.preventDefault();
425
469
  inputRef.current?.setCaret(Infinity);
426
470
  };
427
- $[81] = writable;
428
- $[82] = t26;
471
+ $[93] = writable;
472
+ $[94] = t31;
429
473
  } else {
430
- t26 = $[82];
474
+ t31 = $[94];
431
475
  }
432
- const pressSurface = t26;
433
- const t27 = "chat-composer-content pointer-events-none relative z-10 @container/composer-area w-full";
434
- let t28;
435
- if ($[83] !== atEnd || $[84] !== chatId || $[85] !== readOnly || $[86] !== t) {
436
- t28 = !atEnd && !readOnly && /*#__PURE__*/_jsx("div", {
476
+ const pressSurface = t31;
477
+ const t32 = "chat-composer-content pointer-events-none relative z-10 @container/composer-area w-full";
478
+ let t33;
479
+ if ($[95] !== atEnd || $[96] !== chatId || $[97] !== readOnly || $[98] !== t) {
480
+ t33 = !atEnd && !readOnly && /*#__PURE__*/_jsx("div", {
437
481
  className: "absolute inset-x-0 bottom-full mb-2 flex justify-center",
438
482
  children: /*#__PURE__*/_jsx(Tooltip, {
439
483
  label: t("composer.jumpToEnd"),
@@ -450,524 +494,524 @@ export function Composer(t0) {
450
494
  })
451
495
  })
452
496
  });
453
- $[83] = atEnd;
454
- $[84] = chatId;
455
- $[85] = readOnly;
456
- $[86] = t;
457
- $[87] = t28;
497
+ $[95] = atEnd;
498
+ $[96] = chatId;
499
+ $[97] = readOnly;
500
+ $[98] = t;
501
+ $[99] = t33;
458
502
  } else {
459
- t28 = $[87];
503
+ t33 = $[99];
460
504
  }
461
- let t29;
462
- if ($[88] !== chatId || $[89] !== workflowPill) {
463
- t29 = /*#__PURE__*/_jsx(ChatActivity, {
505
+ let t34;
506
+ if ($[100] !== chatId || $[101] !== workflowPill) {
507
+ t34 = /*#__PURE__*/_jsx(ChatActivity, {
464
508
  chatId: chatId,
465
509
  workflows: workflowPill
466
510
  });
467
- $[88] = chatId;
468
- $[89] = workflowPill;
469
- $[90] = t29;
511
+ $[100] = chatId;
512
+ $[101] = workflowPill;
513
+ $[102] = t34;
470
514
  } else {
471
- t29 = $[90];
515
+ t34 = $[102];
472
516
  }
473
- const t30 = files.dragging ? "border-accent bg-[color-mix(in_srgb,var(--accent-soft)_60%,var(--surface-raised))]" : "border-border bg-[color-mix(in_srgb,var(--surface-raised)_92%,transparent)]";
474
- let t31;
475
- if ($[91] !== t30) {
476
- t31 = clsx("@container/composer pointer-events-auto relative z-1 flex flex-col overflow-hidden rounded-2xl border shadow-float backdrop-blur-[14px] focus-ring-within", t30);
477
- $[91] = t30;
478
- $[92] = t31;
517
+ const t35 = files.dragging ? "border-accent bg-[color-mix(in_srgb,var(--accent-soft)_60%,var(--surface-raised))]" : "border-border bg-[color-mix(in_srgb,var(--surface-raised)_92%,transparent)]";
518
+ let t36;
519
+ if ($[103] !== t35) {
520
+ t36 = clsx("@container/composer pointer-events-auto relative z-1 flex flex-col overflow-hidden rounded-2xl border shadow-float backdrop-blur-[14px] focus-ring-within", t35);
521
+ $[103] = t35;
522
+ $[104] = t36;
479
523
  } else {
480
- t31 = $[92];
524
+ t36 = $[104];
481
525
  }
482
- const t32 = files.dropTarget;
483
- let t33;
484
- if ($[93] !== chatId || $[94] !== focused || $[95] !== host.ComposerHeaderSlot || $[96] !== scope.id || $[97] !== writable) {
485
- t33 = host.ComposerHeaderSlot && /*#__PURE__*/_jsx(host.ComposerHeaderSlot, {
526
+ const t37 = files.dropTarget;
527
+ let t38;
528
+ if ($[105] !== chatId || $[106] !== focused || $[107] !== host.ComposerHeaderSlot || $[108] !== scope.id || $[109] !== writable) {
529
+ t38 = host.ComposerHeaderSlot && /*#__PURE__*/_jsx(host.ComposerHeaderSlot, {
486
530
  scopeId: scope.id,
487
531
  chatId: chatId,
488
532
  disabled: !writable,
489
533
  focused: focused
490
534
  });
491
- $[93] = chatId;
492
- $[94] = focused;
493
- $[95] = host.ComposerHeaderSlot;
494
- $[96] = scope.id;
495
- $[97] = writable;
496
- $[98] = t33;
535
+ $[105] = chatId;
536
+ $[106] = focused;
537
+ $[107] = host.ComposerHeaderSlot;
538
+ $[108] = scope.id;
539
+ $[109] = writable;
540
+ $[110] = t38;
497
541
  } else {
498
- t33 = $[98];
542
+ t38 = $[110];
499
543
  }
500
544
  const T0 = PromptComposer;
501
- const t34 = !empty;
502
- const t35 = capabilities?.denyReason === true;
503
- let t36;
504
- if ($[99] === Symbol.for("react.memo_cache_sentinel")) {
505
- t36 = () => inputRef.current?.focus();
506
- $[99] = t36;
545
+ const t39 = !empty;
546
+ const t40 = capabilities?.denyReason === true;
547
+ let t41;
548
+ if ($[111] === Symbol.for("react.memo_cache_sentinel")) {
549
+ t41 = () => inputRef.current?.focus();
550
+ $[111] = t41;
507
551
  } else {
508
- t36 = $[99];
552
+ t41 = $[111];
509
553
  }
510
- const t37 = writable && "data-[text-cursor]:cursor-text";
511
- let t38;
512
- if ($[100] !== t37) {
513
- t38 = clsx(t37);
514
- $[100] = t37;
515
- $[101] = t38;
554
+ const t42 = writable && "data-[text-cursor]:cursor-text";
555
+ let t43;
556
+ if ($[112] !== t42) {
557
+ t43 = clsx(t42);
558
+ $[112] = t42;
559
+ $[113] = t43;
516
560
  } else {
517
- t38 = $[101];
561
+ t43 = $[113];
518
562
  }
519
- let t39;
520
- if ($[102] !== chatId || $[103] !== info) {
521
- t39 = /*#__PURE__*/_jsx(LimitDock, {
563
+ let t44;
564
+ if ($[114] !== chatId || $[115] !== info) {
565
+ t44 = /*#__PURE__*/_jsx(LimitDock, {
522
566
  chatId: chatId,
523
567
  info: info
524
568
  });
525
- $[102] = chatId;
526
- $[103] = info;
527
- $[104] = t39;
569
+ $[114] = chatId;
570
+ $[115] = info;
571
+ $[116] = t44;
528
572
  } else {
529
- t39 = $[104];
573
+ t44 = $[116];
530
574
  }
531
- const t40 = capabilities?.goals;
532
- let t41;
533
- if ($[105] !== chatId || $[106] !== info || $[107] !== t40) {
534
- t41 = /*#__PURE__*/_jsx(GoalDock, {
575
+ const t45 = capabilities?.goals;
576
+ let t46;
577
+ if ($[117] !== chatId || $[118] !== info || $[119] !== t45) {
578
+ t46 = /*#__PURE__*/_jsx(GoalDock, {
535
579
  chatId: chatId,
536
580
  info: info,
537
- goals: t40
581
+ goals: t45
538
582
  });
539
- $[105] = chatId;
540
- $[106] = info;
541
- $[107] = t40;
542
- $[108] = t41;
583
+ $[117] = chatId;
584
+ $[118] = info;
585
+ $[119] = t45;
586
+ $[120] = t46;
543
587
  } else {
544
- t41 = $[108];
588
+ t46 = $[120];
545
589
  }
546
- let t42;
547
- if ($[109] !== chatId || $[110] !== compactionOffer || $[111] !== controls.compact || $[112] !== scope) {
548
- t42 = compactionOffer && /*#__PURE__*/_jsx(ResumeCompactionDock, {
590
+ let t47;
591
+ if ($[121] !== chatId || $[122] !== compactionOffer || $[123] !== controls.compact || $[124] !== scope) {
592
+ t47 = compactionOffer && /*#__PURE__*/_jsx(ResumeCompactionDock, {
549
593
  tokens: compactionOffer.tokens,
550
594
  reason: compactionOffer.reason,
551
595
  onCompact: controls.compact,
552
596
  onDismiss: () => dismissResumeCompaction(scope, chatId, compactionOffer.turnId)
553
597
  });
554
- $[109] = chatId;
555
- $[110] = compactionOffer;
556
- $[111] = controls.compact;
557
- $[112] = scope;
558
- $[113] = t42;
598
+ $[121] = chatId;
599
+ $[122] = compactionOffer;
600
+ $[123] = controls.compact;
601
+ $[124] = scope;
602
+ $[125] = t47;
559
603
  } else {
560
- t42 = $[113];
604
+ t47 = $[125];
561
605
  }
562
- let t43;
563
- if ($[114] !== menus) {
564
- t43 = /*#__PURE__*/_jsx(ComposerMenu, {
606
+ let t48;
607
+ if ($[126] !== menus) {
608
+ t48 = /*#__PURE__*/_jsx(ComposerMenu, {
565
609
  menus: menus
566
610
  });
567
- $[114] = menus;
568
- $[115] = t43;
611
+ $[126] = menus;
612
+ $[127] = t48;
569
613
  } else {
570
- t43 = $[115];
614
+ t48 = $[127];
571
615
  }
572
- let t44;
573
- if ($[116] !== chatId || $[117] !== info.queuePaused || $[118] !== queue || $[119] !== takeBack || $[120] !== takingBack) {
574
- t44 = queue.length > 0 && /*#__PURE__*/_jsx(QueuedMessages, {
616
+ let t49;
617
+ if ($[128] !== chatId || $[129] !== info.queuePaused || $[130] !== queue || $[131] !== takeBack || $[132] !== takingBack) {
618
+ t49 = queue.length > 0 && /*#__PURE__*/_jsx(QueuedMessages, {
575
619
  chatId: chatId,
576
620
  queue: queue,
577
621
  paused: info.queuePaused === true,
578
622
  takingBack: takingBack !== null,
579
623
  onEdit: message => void takeBack(message)
580
624
  });
581
- $[116] = chatId;
582
- $[117] = info.queuePaused;
583
- $[118] = queue;
584
- $[119] = takeBack;
585
- $[120] = takingBack;
586
- $[121] = t44;
587
- } else {
588
- t44 = $[121];
589
- }
590
- let t45;
591
- if ($[122] !== box.removeQuote || $[123] !== chatId || $[124] !== draft.quote || $[125] !== draft.quoteSource || $[126] !== notice || $[127] !== t) {
592
- t45 = draft.quote !== "" && /*#__PURE__*/_jsx(DraftQuote, {
625
+ $[128] = chatId;
626
+ $[129] = info.queuePaused;
627
+ $[130] = queue;
628
+ $[131] = takeBack;
629
+ $[132] = takingBack;
630
+ $[133] = t49;
631
+ } else {
632
+ t49 = $[133];
633
+ }
634
+ let t50;
635
+ if ($[134] !== box.removeQuote || $[135] !== chatId || $[136] !== draft.quote || $[137] !== draft.quoteSource || $[138] !== notice || $[139] !== t) {
636
+ t50 = draft.quote !== "" && /*#__PURE__*/_jsx(DraftQuote, {
593
637
  chatId: chatId,
594
638
  quote: draft.quote,
595
639
  source: draft.quoteSource,
596
640
  onRemove: box.removeQuote,
597
641
  onSourceGone: () => notice.setNotice(t("rows.user.quoteGone"), "info")
598
642
  });
599
- $[122] = box.removeQuote;
600
- $[123] = chatId;
601
- $[124] = draft.quote;
602
- $[125] = draft.quoteSource;
603
- $[126] = notice;
604
- $[127] = t;
605
- $[128] = t45;
643
+ $[134] = box.removeQuote;
644
+ $[135] = chatId;
645
+ $[136] = draft.quote;
646
+ $[137] = draft.quoteSource;
647
+ $[138] = notice;
648
+ $[139] = t;
649
+ $[140] = t50;
606
650
  } else {
607
- t45 = $[128];
651
+ t50 = $[140];
608
652
  }
609
- let t46;
610
- if ($[129] !== box.removeAttachment || $[130] !== draft.attachments) {
611
- t46 = draft.attachments.length > 0 && /*#__PURE__*/_jsx(DraftAttachments, {
653
+ let t51;
654
+ if ($[141] !== box.removeAttachment || $[142] !== draft.attachments) {
655
+ t51 = draft.attachments.length > 0 && /*#__PURE__*/_jsx(DraftAttachments, {
612
656
  attachments: draft.attachments,
613
657
  onRemove: box.removeAttachment
614
658
  });
615
- $[129] = box.removeAttachment;
616
- $[130] = draft.attachments;
617
- $[131] = t46;
659
+ $[141] = box.removeAttachment;
660
+ $[142] = draft.attachments;
661
+ $[143] = t51;
618
662
  } else {
619
- t46 = $[131];
663
+ t51 = $[143];
620
664
  }
621
- const t47 = !writable;
622
- let t48;
623
- if ($[132] !== box || $[133] !== history || $[134] !== hold || $[135] !== menus) {
624
- t48 = (value, selection, state) => {
665
+ const t52 = !writable;
666
+ let t53;
667
+ if ($[144] !== box || $[145] !== history || $[146] !== hold || $[147] !== menus) {
668
+ t53 = (value, selection, state) => {
625
669
  hold.noteInput();
626
670
  box.setText(value);
627
671
  menus.setMenuIndex(0);
628
672
  menus.trackTriggers(value, selection, state);
629
673
  history.edited(value);
630
674
  };
631
- $[132] = box;
632
- $[133] = history;
633
- $[134] = hold;
634
- $[135] = menus;
635
- $[136] = t48;
675
+ $[144] = box;
676
+ $[145] = history;
677
+ $[146] = hold;
678
+ $[147] = menus;
679
+ $[148] = t53;
636
680
  } else {
637
- t48 = $[136];
681
+ t53 = $[148];
638
682
  }
639
- let t49;
640
- if ($[137] !== hold || $[138] !== menus) {
641
- t49 = () => {
683
+ let t54;
684
+ if ($[149] !== hold || $[150] !== menus) {
685
+ t54 = () => {
642
686
  menus.close();
643
687
  hold.release("blur");
644
688
  };
645
- $[137] = hold;
646
- $[138] = menus;
647
- $[139] = t49;
689
+ $[149] = hold;
690
+ $[150] = menus;
691
+ $[151] = t54;
648
692
  } else {
649
- t49 = $[139];
693
+ t54 = $[151];
650
694
  }
651
- let t50;
652
- if ($[140] !== dictationToolbar || $[141] !== draft.text || $[142] !== editorExtensions || $[143] !== files.onCopy || $[144] !== files.onPaste || $[145] !== focused || $[146] !== hold.setComposing || $[147] !== menus.inputAria || $[148] !== menus.trackTriggers || $[149] !== onKeyDown || $[150] !== placeholder || $[151] !== t47 || $[152] !== t48 || $[153] !== t49) {
653
- t50 = /*#__PURE__*/_jsx(ComposerInput, {
695
+ let t55;
696
+ if ($[152] !== dictationToolbar || $[153] !== draft.text || $[154] !== editorExtensions || $[155] !== files.onCopy || $[156] !== files.onPaste || $[157] !== focused || $[158] !== hold.setComposing || $[159] !== menus.inputAria || $[160] !== menus.trackTriggers || $[161] !== onKeyDown || $[162] !== placeholder || $[163] !== t52 || $[164] !== t53 || $[165] !== t54) {
697
+ t55 = /*#__PURE__*/_jsx(ComposerInput, {
654
698
  ref: inputRef,
655
699
  dictationToolbar: dictationToolbar,
656
700
  className: "composer-input select-text text-sm leading-normal text-text",
657
701
  value: draft.text,
658
702
  placeholder: placeholder,
659
- disabled: t47,
703
+ disabled: t52,
660
704
  tabbable: focused,
661
705
  extensions: editorExtensions,
662
706
  aria: menus.inputAria,
663
- onChange: t48,
707
+ onChange: t53,
664
708
  onSelectionChange: menus.trackTriggers,
665
- onBlur: t49,
709
+ onBlur: t54,
666
710
  onComposing: hold.setComposing,
667
711
  onKeyDown: onKeyDown,
668
712
  onPaste: files.onPaste,
669
713
  onCopy: files.onCopy
670
714
  });
671
- $[140] = dictationToolbar;
672
- $[141] = draft.text;
673
- $[142] = editorExtensions;
674
- $[143] = files.onCopy;
675
- $[144] = files.onPaste;
676
- $[145] = focused;
677
- $[146] = hold.setComposing;
678
- $[147] = menus.inputAria;
679
- $[148] = menus.trackTriggers;
680
- $[149] = onKeyDown;
681
- $[150] = placeholder;
682
- $[151] = t47;
683
- $[152] = t48;
684
- $[153] = t49;
685
- $[154] = t50;
686
- } else {
687
- t50 = $[154];
715
+ $[152] = dictationToolbar;
716
+ $[153] = draft.text;
717
+ $[154] = editorExtensions;
718
+ $[155] = files.onCopy;
719
+ $[156] = files.onPaste;
720
+ $[157] = focused;
721
+ $[158] = hold.setComposing;
722
+ $[159] = menus.inputAria;
723
+ $[160] = menus.trackTriggers;
724
+ $[161] = onKeyDown;
725
+ $[162] = placeholder;
726
+ $[163] = t52;
727
+ $[164] = t53;
728
+ $[165] = t54;
729
+ $[166] = t55;
730
+ } else {
731
+ t55 = $[166];
688
732
  }
689
- let t51;
690
- if ($[155] !== notice.notice || $[156] !== notice.tone) {
691
- t51 = notice.notice && /*#__PURE__*/_jsx("div", {
733
+ let t56;
734
+ if ($[167] !== notice.notice || $[168] !== notice.tone) {
735
+ t56 = notice.notice && /*#__PURE__*/_jsx("div", {
692
736
  className: clsx("px-5 pb-1 text-xs @max-md/composer:px-3.5", notice.tone === "error" ? "text-status-error" : "text-text-muted"),
693
737
  role: notice.tone === "error" ? "alert" : "status",
694
738
  children: notice.notice
695
739
  });
696
- $[155] = notice.notice;
697
- $[156] = notice.tone;
698
- $[157] = t51;
740
+ $[167] = notice.notice;
741
+ $[168] = notice.tone;
742
+ $[169] = t56;
699
743
  } else {
700
- t51 = $[157];
744
+ t56 = $[169];
701
745
  }
702
- const t52 = guard.visible && /*#__PURE__*/_jsxs("div", {
746
+ const t57 = guard.visible && /*#__PURE__*/_jsxs("div", {
703
747
  className: clsx("px-5 pb-1 text-right text-xs tabular-nums @max-md/composer:px-3.5", guard.tooLong ? "text-status-error" : "text-text-faint"),
704
748
  children: [formatNumber(guard.count), " / ", formatNumber(PROMPT_MAX_CHARS), guard.tooLong && ` ${t("composer.tooLong")}`]
705
749
  });
706
750
  const T1 = ComposerControls;
707
- const t53 = capabilities?.attachments !== false;
708
- const t54 = !busy || !empty;
709
- const t55 = empty || !writable || guard.tooLong;
710
- const t56 = t(sendLabelKey(busy, steerable, sendDelivery));
711
- let t57;
712
- if ($[158] !== draft.text || $[159] !== sendKey) {
713
- t57 = sendShortcut(sendKey, draft.text.includes("\n"));
714
- $[158] = draft.text;
715
- $[159] = sendKey;
716
- $[160] = t57;
717
- } else {
718
- t57 = $[160];
719
- }
720
- let t58;
721
- if ($[161] !== submit) {
722
- t58 = alternate => submit(alternate ? "alternate" : "default");
723
- $[161] = submit;
724
- $[162] = t58;
725
- } else {
726
- t58 = $[162];
727
- }
728
- const t59 = continuable !== null && continuable !== sentFor && empty && writable && pending.length === 0 && extraPrompts.length === 0 ? continueTurn : null;
729
- let t60;
730
- if ($[163] !== t54 || $[164] !== t55 || $[165] !== t56 || $[166] !== t57 || $[167] !== t58 || $[168] !== t59) {
731
- t60 = {
732
- visible: t54,
733
- disabled: t55,
734
- label: t56,
735
- kbd: t57,
736
- onSend: t58,
737
- onContinue: t59
751
+ const t58 = capabilities?.attachments !== false;
752
+ const t59 = !busy || !empty;
753
+ const t60 = empty || !writable || guard.tooLong;
754
+ const t61 = t(sendLabelKey(busy, steerable, sendDelivery));
755
+ let t62;
756
+ if ($[170] !== draft.text || $[171] !== sendKey) {
757
+ t62 = sendShortcut(sendKey, draft.text.includes("\n"));
758
+ $[170] = draft.text;
759
+ $[171] = sendKey;
760
+ $[172] = t62;
761
+ } else {
762
+ t62 = $[172];
763
+ }
764
+ let t63;
765
+ if ($[173] !== submit) {
766
+ t63 = alternate => submit(alternate ? "alternate" : "default");
767
+ $[173] = submit;
768
+ $[174] = t63;
769
+ } else {
770
+ t63 = $[174];
771
+ }
772
+ const t64 = continuable !== null && continuable !== sentFor && empty && writable && pending.length === 0 && extraPrompts.length === 0 ? continueTurn : null;
773
+ let t65;
774
+ if ($[175] !== t59 || $[176] !== t60 || $[177] !== t61 || $[178] !== t62 || $[179] !== t63 || $[180] !== t64) {
775
+ t65 = {
776
+ visible: t59,
777
+ disabled: t60,
778
+ label: t61,
779
+ kbd: t62,
780
+ onSend: t63,
781
+ onContinue: t64
738
782
  };
739
- $[163] = t54;
740
- $[164] = t55;
741
- $[165] = t56;
742
- $[166] = t57;
743
- $[167] = t58;
744
- $[168] = t59;
745
- $[169] = t60;
746
- } else {
747
- t60 = $[169];
748
- }
749
- let t61;
750
- if ($[170] !== files) {
751
- t61 = picked => {
783
+ $[175] = t59;
784
+ $[176] = t60;
785
+ $[177] = t61;
786
+ $[178] = t62;
787
+ $[179] = t63;
788
+ $[180] = t64;
789
+ $[181] = t65;
790
+ } else {
791
+ t65 = $[181];
792
+ }
793
+ let t66;
794
+ if ($[182] !== files) {
795
+ t66 = picked => {
752
796
  files.addFiles(picked);
753
797
  inputRef.current?.focus();
754
798
  };
755
- $[170] = files;
756
- $[171] = t61;
799
+ $[182] = files;
800
+ $[183] = t66;
757
801
  } else {
758
- t61 = $[171];
802
+ t66 = $[183];
759
803
  }
760
- let t62;
761
- let t63;
762
- if ($[172] !== writable) {
763
- t62 = sigil => {
804
+ let t67;
805
+ let t68;
806
+ if ($[184] !== writable) {
807
+ t67 = sigil => {
764
808
  if (writable) {
765
809
  inputRef.current?.insertSigil(sigil);
766
810
  }
767
811
  };
768
- t63 = added => {
812
+ t68 = added => {
769
813
  if (writable) {
770
814
  inputRef.current?.insert(added);
771
815
  }
772
816
  };
773
- $[172] = writable;
774
- $[173] = t62;
775
- $[174] = t63;
817
+ $[184] = writable;
818
+ $[185] = t67;
819
+ $[186] = t68;
776
820
  } else {
777
- t62 = $[173];
778
- t63 = $[174];
821
+ t67 = $[185];
822
+ t68 = $[186];
779
823
  }
780
- let t64;
781
- if ($[175] !== T1 || $[176] !== chatId || $[177] !== controls || $[178] !== empty || $[179] !== info || $[180] !== providerFixed || $[181] !== restoreStashed || $[182] !== setDictationToolbar || $[183] !== sigils || $[184] !== t53 || $[185] !== t60 || $[186] !== t61 || $[187] !== t62 || $[188] !== t63 || $[189] !== toggleStash || $[190] !== writable) {
782
- t64 = /*#__PURE__*/_jsx(T1, {
824
+ let t69;
825
+ if ($[187] !== T1 || $[188] !== chatId || $[189] !== controls || $[190] !== empty || $[191] !== info || $[192] !== providerFixed || $[193] !== restoreStashed || $[194] !== setDictationToolbar || $[195] !== sigils || $[196] !== t58 || $[197] !== t65 || $[198] !== t66 || $[199] !== t67 || $[200] !== t68 || $[201] !== toggleStash || $[202] !== writable) {
826
+ t69 = /*#__PURE__*/_jsx(T1, {
783
827
  chatId: chatId,
784
828
  info: info,
785
829
  providerFixed: providerFixed,
786
830
  writable: writable,
787
- attachable: t53,
831
+ attachable: t58,
788
832
  emptyDraft: empty,
789
833
  sigils: sigils,
790
834
  controls: controls,
791
- send: t60,
835
+ send: t65,
792
836
  dictationToolbar: setDictationToolbar,
793
- onFiles: t61,
837
+ onFiles: t66,
794
838
  onRestore: restoreStashed,
795
839
  onStash: toggleStash,
796
- onSigil: t62,
797
- insert: t63
840
+ onSigil: t67,
841
+ insert: t68
798
842
  });
799
- $[175] = T1;
800
- $[176] = chatId;
801
- $[177] = controls;
802
- $[178] = empty;
803
- $[179] = info;
804
- $[180] = providerFixed;
805
- $[181] = restoreStashed;
806
- $[182] = setDictationToolbar;
807
- $[183] = sigils;
808
- $[184] = t53;
809
- $[185] = t60;
810
- $[186] = t61;
811
- $[187] = t62;
812
- $[188] = t63;
813
- $[189] = toggleStash;
814
- $[190] = writable;
815
- $[191] = t64;
816
- } else {
817
- t64 = $[191];
843
+ $[187] = T1;
844
+ $[188] = chatId;
845
+ $[189] = controls;
846
+ $[190] = empty;
847
+ $[191] = info;
848
+ $[192] = providerFixed;
849
+ $[193] = restoreStashed;
850
+ $[194] = setDictationToolbar;
851
+ $[195] = sigils;
852
+ $[196] = t58;
853
+ $[197] = t65;
854
+ $[198] = t66;
855
+ $[199] = t67;
856
+ $[200] = t68;
857
+ $[201] = toggleStash;
858
+ $[202] = writable;
859
+ $[203] = t69;
860
+ } else {
861
+ t69 = $[203];
818
862
  }
819
- let t65;
820
- if ($[192] !== pointSurface || $[193] !== pressSurface || $[194] !== t38 || $[195] !== t39 || $[196] !== t41 || $[197] !== t42 || $[198] !== t43 || $[199] !== t44 || $[200] !== t45 || $[201] !== t46 || $[202] !== t50 || $[203] !== t51 || $[204] !== t52 || $[205] !== t64) {
821
- t65 = /*#__PURE__*/_jsxs("div", {
822
- className: t38,
863
+ let t70;
864
+ if ($[204] !== pointSurface || $[205] !== pressSurface || $[206] !== t43 || $[207] !== t44 || $[208] !== t46 || $[209] !== t47 || $[210] !== t48 || $[211] !== t49 || $[212] !== t50 || $[213] !== t51 || $[214] !== t55 || $[215] !== t56 || $[216] !== t57 || $[217] !== t69) {
865
+ t70 = /*#__PURE__*/_jsxs("div", {
866
+ className: t43,
823
867
  onPointerOver: pointSurface,
824
868
  onMouseDown: pressSurface,
825
- children: [t39, t41, t42, t43, t44, t45, t46, t50, t51, t52, t64]
869
+ children: [t44, t46, t47, t48, t49, t50, t51, t55, t56, t57, t69]
826
870
  });
827
- $[192] = pointSurface;
828
- $[193] = pressSurface;
829
- $[194] = t38;
830
- $[195] = t39;
831
- $[196] = t41;
832
- $[197] = t42;
833
- $[198] = t43;
834
- $[199] = t44;
835
- $[200] = t45;
836
- $[201] = t46;
837
- $[202] = t50;
838
- $[203] = t51;
839
- $[204] = t52;
840
- $[205] = t64;
841
- $[206] = t65;
842
- } else {
843
- t65 = $[206];
871
+ $[204] = pointSurface;
872
+ $[205] = pressSurface;
873
+ $[206] = t43;
874
+ $[207] = t44;
875
+ $[208] = t46;
876
+ $[209] = t47;
877
+ $[210] = t48;
878
+ $[211] = t49;
879
+ $[212] = t50;
880
+ $[213] = t51;
881
+ $[214] = t55;
882
+ $[215] = t56;
883
+ $[216] = t57;
884
+ $[217] = t69;
885
+ $[218] = t70;
886
+ } else {
887
+ t70 = $[218];
844
888
  }
845
- let t66;
846
- if ($[207] !== T0 || $[208] !== answerPromptsElsewhere || $[209] !== chatId || $[210] !== disabled || $[211] !== focused || $[212] !== hold || $[213] !== pending || $[214] !== t34 || $[215] !== t35 || $[216] !== t36 || $[217] !== t65) {
847
- t66 = /*#__PURE__*/_jsx(T0, {
889
+ let t71;
890
+ if ($[219] !== T0 || $[220] !== answerPromptsElsewhere || $[221] !== chatId || $[222] !== disabled || $[223] !== focused || $[224] !== hold || $[225] !== pending || $[226] !== t39 || $[227] !== t40 || $[228] !== t41 || $[229] !== t70) {
891
+ t71 = /*#__PURE__*/_jsx(T0, {
848
892
  chatId: chatId,
849
893
  pending: pending,
850
894
  focused: focused,
851
895
  onShowElsewhere: answerPromptsElsewhere,
852
896
  disabled: disabled,
853
- hasDraft: t34,
854
- denyReason: t35,
855
- onAllAnswered: t36,
897
+ hasDraft: t39,
898
+ denyReason: t40,
899
+ onAllAnswered: t41,
856
900
  hold: hold,
857
- children: t65
901
+ children: t70
858
902
  });
859
- $[207] = T0;
860
- $[208] = answerPromptsElsewhere;
861
- $[209] = chatId;
862
- $[210] = disabled;
863
- $[211] = focused;
864
- $[212] = hold;
865
- $[213] = pending;
866
- $[214] = t34;
867
- $[215] = t35;
868
- $[216] = t36;
869
- $[217] = t65;
870
- $[218] = t66;
871
- } else {
872
- t66 = $[218];
903
+ $[219] = T0;
904
+ $[220] = answerPromptsElsewhere;
905
+ $[221] = chatId;
906
+ $[222] = disabled;
907
+ $[223] = focused;
908
+ $[224] = hold;
909
+ $[225] = pending;
910
+ $[226] = t39;
911
+ $[227] = t40;
912
+ $[228] = t41;
913
+ $[229] = t70;
914
+ $[230] = t71;
915
+ } else {
916
+ t71 = $[230];
873
917
  }
874
- let t67;
875
- if ($[219] !== files.dropTarget || $[220] !== t31 || $[221] !== t33 || $[222] !== t66) {
876
- t67 = /*#__PURE__*/_jsxs("div", {
877
- className: t31,
878
- ...t32,
879
- children: [t33, t66]
918
+ let t72;
919
+ if ($[231] !== files.dropTarget || $[232] !== t36 || $[233] !== t38 || $[234] !== t71) {
920
+ t72 = /*#__PURE__*/_jsxs("div", {
921
+ className: t36,
922
+ ...t37,
923
+ children: [t38, t71]
880
924
  });
881
- $[219] = files.dropTarget;
882
- $[220] = t31;
883
- $[221] = t33;
884
- $[222] = t66;
885
- $[223] = t67;
925
+ $[231] = files.dropTarget;
926
+ $[232] = t36;
927
+ $[233] = t38;
928
+ $[234] = t71;
929
+ $[235] = t72;
886
930
  } else {
887
- t67 = $[223];
931
+ t72 = $[235];
888
932
  }
889
- let t68;
890
- if ($[224] !== statusItems) {
891
- t68 = /*#__PURE__*/_jsx(ComposerStatusLine, {
933
+ let t73;
934
+ if ($[236] !== statusItems) {
935
+ t73 = /*#__PURE__*/_jsx(ComposerStatusLine, {
892
936
  items: statusItems
893
937
  });
894
- $[224] = statusItems;
895
- $[225] = t68;
938
+ $[236] = statusItems;
939
+ $[237] = t73;
896
940
  } else {
897
- t68 = $[225];
941
+ t73 = $[237];
898
942
  }
899
- const t69 = controls.confirmClear;
900
- let t70;
901
- if ($[226] !== t) {
902
- t70 = t("composer.clear.title");
903
- $[226] = t;
904
- $[227] = t70;
943
+ const t74 = controls.confirmClear;
944
+ let t75;
945
+ if ($[238] !== t) {
946
+ t75 = t("composer.clear.title");
947
+ $[238] = t;
948
+ $[239] = t75;
905
949
  } else {
906
- t70 = $[227];
950
+ t75 = $[239];
907
951
  }
908
- let t71;
909
- if ($[228] !== t) {
910
- t71 = t("composer.clear.description");
911
- $[228] = t;
912
- $[229] = t71;
952
+ let t76;
953
+ if ($[240] !== t) {
954
+ t76 = t("composer.clear.description");
955
+ $[240] = t;
956
+ $[241] = t76;
913
957
  } else {
914
- t71 = $[229];
958
+ t76 = $[241];
915
959
  }
916
- let t72;
917
- if ($[230] !== t) {
918
- t72 = t("composer.clear.confirm");
919
- $[230] = t;
920
- $[231] = t72;
960
+ let t77;
961
+ if ($[242] !== t) {
962
+ t77 = t("composer.clear.confirm");
963
+ $[242] = t;
964
+ $[243] = t77;
921
965
  } else {
922
- t72 = $[231];
966
+ t77 = $[243];
923
967
  }
924
- let t73;
925
- if ($[232] !== t) {
926
- t73 = t("composer.notice.clearFailed");
927
- $[232] = t;
928
- $[233] = t73;
929
- } else {
930
- t73 = $[233];
931
- }
932
- let t74;
933
- if ($[234] !== controls.cancelClear || $[235] !== controls.confirmClear || $[236] !== controls.forceClearThread || $[237] !== t70 || $[238] !== t71 || $[239] !== t72 || $[240] !== t73) {
934
- t74 = /*#__PURE__*/_jsx(PromptDialog, {
935
- open: t69,
936
- title: t70,
937
- description: t71,
938
- confirmLabel: t72,
968
+ let t78;
969
+ if ($[244] !== t) {
970
+ t78 = t("composer.notice.clearFailed");
971
+ $[244] = t;
972
+ $[245] = t78;
973
+ } else {
974
+ t78 = $[245];
975
+ }
976
+ let t79;
977
+ if ($[246] !== controls.cancelClear || $[247] !== controls.confirmClear || $[248] !== controls.forceClearThread || $[249] !== t75 || $[250] !== t76 || $[251] !== t77 || $[252] !== t78) {
978
+ t79 = /*#__PURE__*/_jsx(PromptDialog, {
979
+ open: t74,
980
+ title: t75,
981
+ description: t76,
982
+ confirmLabel: t77,
939
983
  danger: true,
940
- fallbackMessage: t73,
984
+ fallbackMessage: t78,
941
985
  onConfirm: controls.forceClearThread,
942
986
  onOpenChange: controls.cancelClear
943
987
  });
944
- $[234] = controls.cancelClear;
945
- $[235] = controls.confirmClear;
946
- $[236] = controls.forceClearThread;
947
- $[237] = t70;
948
- $[238] = t71;
949
- $[239] = t72;
950
- $[240] = t73;
951
- $[241] = t74;
988
+ $[246] = controls.cancelClear;
989
+ $[247] = controls.confirmClear;
990
+ $[248] = controls.forceClearThread;
991
+ $[249] = t75;
992
+ $[250] = t76;
993
+ $[251] = t77;
994
+ $[252] = t78;
995
+ $[253] = t79;
952
996
  } else {
953
- t74 = $[241];
997
+ t79 = $[253];
954
998
  }
955
- let t75;
956
- if ($[242] !== t28 || $[243] !== t29 || $[244] !== t67 || $[245] !== t68 || $[246] !== t74) {
957
- t75 = /*#__PURE__*/_jsxs("div", {
958
- className: t27,
959
- children: [t28, t29, t67, t68, t74]
999
+ let t80;
1000
+ if ($[254] !== t33 || $[255] !== t34 || $[256] !== t72 || $[257] !== t73 || $[258] !== t79) {
1001
+ t80 = /*#__PURE__*/_jsxs("div", {
1002
+ className: t32,
1003
+ children: [t33, t34, t72, t73, t79]
960
1004
  });
961
- $[242] = t28;
962
- $[243] = t29;
963
- $[244] = t67;
964
- $[245] = t68;
965
- $[246] = t74;
966
- $[247] = t75;
1005
+ $[254] = t33;
1006
+ $[255] = t34;
1007
+ $[256] = t72;
1008
+ $[257] = t73;
1009
+ $[258] = t79;
1010
+ $[259] = t80;
967
1011
  } else {
968
- t75 = $[247];
1012
+ t80 = $[259];
969
1013
  }
970
- return t75;
1014
+ return t80;
971
1015
  }
972
1016
  function _temp4(event) {
973
1017
  event.currentTarget.toggleAttribute("data-text-cursor", surfacePartOf(event.target, event.currentTarget) !== "action");