@superinterface/react 5.2.2 → 5.2.3-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1,4 +1,3 @@
1
- "use client";
2
1
  "use strict";
3
2
  function _array_like_to_array(arr, len) {
4
3
  if (len == null || len > arr.length) len = arr.length;
@@ -5609,7 +5608,7 @@ var require_lib = __commonJS({
5609
5608
  key: "parseMaybeAssign",
5610
5609
  value: function parseMaybeAssign(refExpressionErrors, afterLeftParse) {
5611
5610
  var _this = this;
5612
- var _jsx109;
5611
+ var _jsx110;
5613
5612
  var state = null;
5614
5613
  var jsx2;
5615
5614
  if (this.hasPlugin("jsx") && (this.match(143) || this.match(47))) {
@@ -5624,7 +5623,7 @@ var require_lib = __commonJS({
5624
5623
  context.pop();
5625
5624
  }
5626
5625
  }
5627
- if ((_jsx109 = jsx2) != null && _jsx109.error || this.match(47)) {
5626
+ if ((_jsx110 = jsx2) != null && _jsx110.error || this.match(47)) {
5628
5627
  var _jsx210, _jsx310;
5629
5628
  state = state || this.state.clone();
5630
5629
  var typeParameters;
@@ -13402,7 +13401,7 @@ var require_lib = __commonJS({
13402
13401
  key: "parseMaybeAssign",
13403
13402
  value: function parseMaybeAssign(refExpressionErrors, afterLeftParse) {
13404
13403
  var _this = this;
13405
- var _jsx109, _jsx210, _typeCast, _jsx310, _typeCast2;
13404
+ var _jsx110, _jsx210, _typeCast, _jsx310, _typeCast2;
13406
13405
  var state;
13407
13406
  var jsx2;
13408
13407
  var typeCast;
@@ -13418,7 +13417,7 @@ var require_lib = __commonJS({
13418
13417
  context.pop();
13419
13418
  }
13420
13419
  }
13421
- if (!((_jsx109 = jsx2) != null && _jsx109.error) && !this.match(47)) {
13420
+ if (!((_jsx110 = jsx2) != null && _jsx110.error) && !this.match(47)) {
13422
13421
  return _get(_get_prototype_of(TypeScriptParserMixin.prototype), "parseMaybeAssign", this).call(this, refExpressionErrors, afterLeftParse);
13423
13422
  }
13424
13423
  if (!state || state === this.state) state = this.state.clone();
@@ -37221,7 +37220,7 @@ var SuperinterfaceProvider = function(_ref) {
37221
37220
  });
37222
37221
  };
37223
37222
  // src/components/threads/Thread/index.tsx
37224
- var import_react_compiler_runtime77 = require("react-compiler-runtime");
37223
+ var import_react_compiler_runtime78 = require("react-compiler-runtime");
37225
37224
  // src/components/threads/Thread/Messages/index.tsx
37226
37225
  var import_react_compiler_runtime66 = require("react-compiler-runtime");
37227
37226
  var import_themes45 = require("@radix-ui/themes");
@@ -39959,7 +39958,8 @@ var threadRunRequiresAction = /* @__PURE__ */ function() {
39959
39958
  3,
39960
39959
  2
39961
39960
  ];
39962
- toolCalls = value.data.required_action.submit_client_tool_outputs.tool_calls;
39961
+ toolCalls = // @ts-ignore-next-line
39962
+ value.data.required_action.submit_client_tool_outputs.tool_calls;
39963
39963
  return [
39964
39964
  4,
39965
39965
  (0, import_radash9.map)(toolCalls, /* @__PURE__ */ function() {
@@ -44091,7 +44091,7 @@ Messages2.Message = Message;
44091
44091
  Messages2.NextPageSkeleton = NextPageSkeleton;
44092
44092
  Messages2.Content = Content7;
44093
44093
  // src/components/threads/Thread/MessageForm/index.tsx
44094
- var import_react_compiler_runtime73 = require("react-compiler-runtime");
44094
+ var import_react_compiler_runtime74 = require("react-compiler-runtime");
44095
44095
  // src/components/threads/Thread/MessageForm/Submit/index.tsx
44096
44096
  var import_react_compiler_runtime67 = require("react-compiler-runtime");
44097
44097
  var import_react_icons11 = require("@radix-ui/react-icons");
@@ -44266,8 +44266,41 @@ Submit.Root = Root7;
44266
44266
  Submit.Button = Button3;
44267
44267
  // src/components/threads/Thread/MessageForm/Root/index.tsx
44268
44268
  var import_react_query6 = require("@tanstack/react-query");
44269
- var import_react51 = require("react");
44269
+ var import_react52 = require("react");
44270
44270
  var import_react_hook_form = require("react-hook-form");
44271
+ // src/lib/reactHookForm/FormProvider.tsx
44272
+ var import_react_compiler_runtime68 = require("react-compiler-runtime");
44273
+ var import_react51 = require("react");
44274
+ var import_jsx_runtime69 = require("react/jsx-runtime");
44275
+ var FormContext = /* @__PURE__ */ (0, import_react51.createContext)(null);
44276
+ var useFormContext = function() {
44277
+ var value = (0, import_react51.useContext)(FormContext);
44278
+ if (!value) {
44279
+ throw new Error("useFormContext must be used within FormProvider");
44280
+ }
44281
+ return value;
44282
+ };
44283
+ var FormProvider = function(t0) {
44284
+ var $ = (0, import_react_compiler_runtime68.c)(3);
44285
+ var children = t0.children, form = t0.form;
44286
+ var t1;
44287
+ t1 = form;
44288
+ var contextValue = t1;
44289
+ var t2;
44290
+ if ($[0] !== children || $[1] !== contextValue) {
44291
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(FormContext.Provider, {
44292
+ value: contextValue,
44293
+ children: children
44294
+ });
44295
+ $[0] = children;
44296
+ $[1] = contextValue;
44297
+ $[2] = t2;
44298
+ } else {
44299
+ t2 = $[2];
44300
+ }
44301
+ return t2;
44302
+ };
44303
+ // src/components/threads/Thread/MessageForm/Root/index.tsx
44271
44304
  var import_themes47 = require("@radix-ui/themes");
44272
44305
  // src/components/threads/Thread/MessageForm/Root/lib/formOptions.ts
44273
44306
  var import_zod = require("zod");
@@ -44280,7 +44313,7 @@ var formOptions = {
44280
44313
  };
44281
44314
  // src/components/threads/Thread/MessageForm/Root/index.tsx
44282
44315
  var import_radash14 = require("radash");
44283
- var import_jsx_runtime69 = require("react/jsx-runtime");
44316
+ var import_jsx_runtime70 = require("react/jsx-runtime");
44284
44317
  function ownKeys30(e, r) {
44285
44318
  var t = Object.keys(e);
44286
44319
  if (Object.getOwnPropertySymbols) {
@@ -44350,7 +44383,7 @@ function _asyncToGenerator6(n) {
44350
44383
  var Root8 = function(_ref) {
44351
44384
  "use no memo";
44352
44385
  var children = _ref.children, onSubmitArg = _ref.onSubmit, isDisabledArg = _ref.isDisabled, style = _ref.style, className = _ref.className;
44353
- var _$_ref = _sliced_to_array((0, import_react51.useState)([]), 2), files = _$_ref[0], setFiles = _$_ref[1];
44386
+ var _$_ref = _sliced_to_array((0, import_react52.useState)([]), 2), files = _$_ref[0], setFiles = _$_ref[1];
44354
44387
  var formProps = (0, import_react_hook_form.useForm)(formOptions);
44355
44388
  var handleSubmit = formProps.handleSubmit, isSubmitting = formProps.formState.isSubmitting, formReset = formProps.reset, watch = formProps.watch;
44356
44389
  var addToast = useToasts().addToast;
@@ -44364,7 +44397,7 @@ var Root8 = function(_ref) {
44364
44397
  })
44365
44398
  }).createMessage;
44366
44399
  var isMutatingMessage = useIsMutatingMessage();
44367
- var isFileLoading = (0, import_react51.useMemo)(function() {
44400
+ var isFileLoading = (0, import_react52.useMemo)(function() {
44368
44401
  return files.some(function(file) {
44369
44402
  return isOptimistic({
44370
44403
  id: file.id
@@ -44373,21 +44406,21 @@ var Root8 = function(_ref) {
44373
44406
  }, [
44374
44407
  files
44375
44408
  ]);
44376
- var isLoading = (0, import_react51.useMemo)(function() {
44409
+ var isLoading = (0, import_react52.useMemo)(function() {
44377
44410
  return isMutatingMessage || isSubmitting;
44378
44411
  }, [
44379
44412
  isMutatingMessage,
44380
44413
  isSubmitting
44381
44414
  ]);
44382
44415
  var latestMessage = useLatestMessage().latestMessage;
44383
- var isDisabled = (0, import_react51.useMemo)(function() {
44416
+ var isDisabled = (0, import_react52.useMemo)(function() {
44384
44417
  var _latestMessage$metada;
44385
44418
  return !!(latestMessage !== null && latestMessage !== void 0 && (_latestMessage$metada = latestMessage.metadata) !== null && _latestMessage$metada !== void 0 && _latestMessage$metada.isBlocking) || !!isDisabledArg;
44386
44419
  }, [
44387
44420
  latestMessage,
44388
44421
  isDisabledArg
44389
44422
  ]);
44390
- var reset = (0, import_react51.useCallback)(function() {
44423
+ var reset = (0, import_react52.useCallback)(function() {
44391
44424
  formReset();
44392
44425
  setFiles([]);
44393
44426
  }, [
@@ -44462,7 +44495,7 @@ var Root8 = function(_ref) {
44462
44495
  };
44463
44496
  }();
44464
44497
  var content_0 = watch("content");
44465
- return /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(MessageFormContext.Provider, {
44498
+ return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(MessageFormContext.Provider, {
44466
44499
  value: {
44467
44500
  isDisabled: isDisabled,
44468
44501
  isLoading: isLoading,
@@ -44471,43 +44504,42 @@ var Root8 = function(_ref) {
44471
44504
  isFileLoading: isFileLoading,
44472
44505
  content: content_0
44473
44506
  },
44474
- children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_react_hook_form.FormProvider, _objectSpread30(_objectSpread30({}, formProps), {}, {
44475
- children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_themes47.Box, {
44507
+ children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(FormProvider, {
44508
+ form: formProps,
44509
+ children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_themes47.Box, {
44476
44510
  asChild: true,
44477
44511
  flexShrink: "0",
44478
44512
  style: style,
44479
44513
  className: className,
44480
- children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)("form", {
44514
+ children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("form", {
44481
44515
  onSubmit: handleSubmit(onSubmit),
44482
44516
  children: children
44483
44517
  })
44484
44518
  })
44485
- }))
44519
+ })
44486
44520
  });
44487
44521
  };
44488
44522
  // src/components/threads/Thread/MessageForm/Field/index.tsx
44489
- var import_react_hook_form3 = require("react-hook-form");
44490
44523
  var import_themes51 = require("@radix-ui/themes");
44491
44524
  // src/components/threads/Thread/MessageForm/Field/Control.tsx
44492
- var import_react_compiler_runtime69 = require("react-compiler-runtime");
44525
+ var import_react_compiler_runtime70 = require("react-compiler-runtime");
44493
44526
  var import_themes48 = require("@radix-ui/themes");
44494
- var import_react_hook_form2 = require("react-hook-form");
44495
44527
  // src/hooks/misc/usePrevious.ts
44496
- var import_react52 = require("react");
44528
+ var import_react53 = require("react");
44497
44529
  var usePrevious = function(state) {
44498
- var ref = (0, import_react52.useRef)(void 0);
44499
- (0, import_react52.useEffect)(function() {
44530
+ var ref = (0, import_react53.useRef)(void 0);
44531
+ (0, import_react53.useEffect)(function() {
44500
44532
  ref.current = state;
44501
44533
  });
44502
44534
  return ref.current;
44503
44535
  };
44504
44536
  // src/components/threads/Thread/MessageForm/Field/Control.tsx
44505
- var import_react54 = require("react");
44537
+ var import_react55 = require("react");
44506
44538
  // src/components/textareas/TextareaBase/index.tsx
44507
- var import_react_compiler_runtime68 = require("react-compiler-runtime");
44508
- var import_react53 = require("react");
44539
+ var import_react_compiler_runtime69 = require("react-compiler-runtime");
44540
+ var import_react54 = require("react");
44509
44541
  var import_react_textarea_autosize = __toESM(require("react-textarea-autosize"), 1);
44510
- var import_jsx_runtime70 = require("react/jsx-runtime");
44542
+ var import_jsx_runtime71 = require("react/jsx-runtime");
44511
44543
  var _excluded3 = [
44512
44544
  "style",
44513
44545
  "className"
@@ -44573,8 +44605,8 @@ function _objectWithoutPropertiesLoose3(r, e) {
44573
44605
  }
44574
44606
  return t;
44575
44607
  }
44576
- var TextareaBase = /* @__PURE__ */ (0, import_react53.forwardRef)(function TextareaBase2(t0, ref) {
44577
- var $ = (0, import_react_compiler_runtime68.c)(14);
44608
+ var TextareaBase = /* @__PURE__ */ (0, import_react54.forwardRef)(function TextareaBase2(t0, ref) {
44609
+ var $ = (0, import_react_compiler_runtime69.c)(14);
44578
44610
  var className;
44579
44611
  var rest;
44580
44612
  var style;
@@ -44595,7 +44627,7 @@ var TextareaBase = /* @__PURE__ */ (0, import_react53.forwardRef)(function Texta
44595
44627
  }
44596
44628
  var t1;
44597
44629
  if ($[4] === Symbol.for("react.memo_cache_sentinel")) {
44598
- t1 = /* @__PURE__ */ (0, import_jsx_runtime70.jsx)("style", {
44630
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime71.jsx)("style", {
44599
44631
  children: ".superinterface-textarea { min-height: inherit; height: 30px; }\n.superinterface-textarea::placeholder { color: var(--gray-a10); }"
44600
44632
  });
44601
44633
  $[4] = t1;
@@ -44629,10 +44661,10 @@ var TextareaBase = /* @__PURE__ */ (0, import_react53.forwardRef)(function Texta
44629
44661
  }
44630
44662
  var t5;
44631
44663
  if ($[9] !== ref || $[10] !== rest || $[11] !== t2 || $[12] !== t4) {
44632
- t5 = /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_jsx_runtime70.Fragment, {
44664
+ t5 = /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(import_jsx_runtime71.Fragment, {
44633
44665
  children: [
44634
44666
  t1,
44635
- /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_react_textarea_autosize.default, _objectSpread31({
44667
+ /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_react_textarea_autosize.default, _objectSpread31({
44636
44668
  ref: ref,
44637
44669
  className: t2,
44638
44670
  style: t4
@@ -44650,7 +44682,7 @@ var TextareaBase = /* @__PURE__ */ (0, import_react53.forwardRef)(function Texta
44650
44682
  return t5;
44651
44683
  });
44652
44684
  // src/components/threads/Thread/MessageForm/Field/Control.tsx
44653
- var import_jsx_runtime71 = require("react/jsx-runtime");
44685
+ var import_jsx_runtime72 = require("react/jsx-runtime");
44654
44686
  function ownKeys32(e, r) {
44655
44687
  var t = Object.keys(e);
44656
44688
  if (Object.getOwnPropertySymbols) {
@@ -44695,11 +44727,11 @@ function _toPrimitive32(t, r) {
44695
44727
  return ("string" === r ? String : Number)(t);
44696
44728
  }
44697
44729
  var Root9 = function(t0) {
44698
- var $ = (0, import_react_compiler_runtime69.c)(4);
44730
+ var $ = (0, import_react_compiler_runtime70.c)(4);
44699
44731
  var children = t0.children, style = t0.style, className = t0.className;
44700
44732
  var t1;
44701
44733
  if ($[0] !== children || $[1] !== className || $[2] !== style) {
44702
- t1 = /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_themes48.Flex, {
44734
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes48.Flex, {
44703
44735
  flexGrow: "1",
44704
44736
  pt: "4px",
44705
44737
  style: style,
@@ -44718,19 +44750,19 @@ var Root9 = function(t0) {
44718
44750
  var Input = function(props) {
44719
44751
  "use no memo";
44720
44752
  var _props$placeholder;
44721
- var assistantNameContext = (0, import_react54.useContext)(AssistantNameContext);
44722
- var register = (0, import_react_hook_form2.useFormContext)().register;
44753
+ var assistantNameContext = (0, import_react55.useContext)(AssistantNameContext);
44754
+ var register = useFormContext().register;
44723
44755
  var _useMessageFormContext = useMessageFormContext(), isDisabled = _useMessageFormContext.isDisabled, isLoading = _useMessageFormContext.isLoading;
44724
- var isSubmitDisabled = (0, import_react54.useMemo)(function() {
44756
+ var isSubmitDisabled = (0, import_react55.useMemo)(function() {
44725
44757
  return isDisabled || isLoading;
44726
44758
  }, [
44727
44759
  isDisabled,
44728
44760
  isLoading
44729
44761
  ]);
44730
44762
  var isDisabledPrevious = usePrevious(isDisabled);
44731
- var textareaRef = (0, import_react54.useRef)(null);
44763
+ var textareaRef = (0, import_react55.useRef)(null);
44732
44764
  var textareaProps = register("content");
44733
- (0, import_react54.useEffect)(function() {
44765
+ (0, import_react55.useEffect)(function() {
44734
44766
  if (isDisabled) return;
44735
44767
  if (!isDisabledPrevious) return;
44736
44768
  if (!textareaRef.current) return;
@@ -44740,7 +44772,7 @@ var Input = function(props) {
44740
44772
  isDisabledPrevious,
44741
44773
  textareaProps
44742
44774
  ]);
44743
- return /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(TextareaBase, _objectSpread32(_objectSpread32(_objectSpread32({
44775
+ return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(TextareaBase, _objectSpread32(_objectSpread32(_objectSpread32({
44744
44776
  minRows: 1,
44745
44777
  placeholder: (_props$placeholder = props.placeholder) !== null && _props$placeholder !== void 0 ? _props$placeholder : "Message ".concat(assistantNameContext, "..."),
44746
44778
  disabled: isDisabled,
@@ -44760,17 +44792,17 @@ var Input = function(props) {
44760
44792
  }));
44761
44793
  };
44762
44794
  var Control = function(props) {
44763
- var $ = (0, import_react_compiler_runtime69.c)(3);
44795
+ var $ = (0, import_react_compiler_runtime70.c)(3);
44764
44796
  var t0;
44765
44797
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
44766
- t0 = /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Input, {});
44798
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(Input, {});
44767
44799
  $[0] = t0;
44768
44800
  } else {
44769
44801
  t0 = $[0];
44770
44802
  }
44771
44803
  var t1;
44772
44804
  if ($[1] !== props) {
44773
- t1 = /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Root9, _objectSpread32(_objectSpread32({}, props), {}, {
44805
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(Root9, _objectSpread32(_objectSpread32({}, props), {}, {
44774
44806
  children: t0
44775
44807
  }));
44776
44808
  $[1] = props;
@@ -44783,10 +44815,10 @@ var Control = function(props) {
44783
44815
  Control.Root = Root9;
44784
44816
  Control.Input = Input;
44785
44817
  // src/components/threads/Thread/MessageForm/Field/Files/Preview.tsx
44786
- var import_react_compiler_runtime70 = require("react-compiler-runtime");
44818
+ var import_react_compiler_runtime71 = require("react-compiler-runtime");
44787
44819
  var import_themes49 = require("@radix-ui/themes");
44788
44820
  var import_react_icons12 = require("@radix-ui/react-icons");
44789
- var import_jsx_runtime72 = require("react/jsx-runtime");
44821
+ var import_jsx_runtime73 = require("react/jsx-runtime");
44790
44822
  function ownKeys33(e, r) {
44791
44823
  var t = Object.keys(e);
44792
44824
  if (Object.getOwnPropertySymbols) {
@@ -44831,7 +44863,7 @@ function _toPrimitive33(t, r) {
44831
44863
  return ("string" === r ? String : Number)(t);
44832
44864
  }
44833
44865
  var Preview = function(props) {
44834
- var $ = (0, import_react_compiler_runtime70.c)(8);
44866
+ var $ = (0, import_react_compiler_runtime71.c)(8);
44835
44867
  var _useMessageFormContext = useMessageFormContext(), files = _useMessageFormContext.files, setFiles = _useMessageFormContext.setFiles;
44836
44868
  if (!files.length) {
44837
44869
  return null;
@@ -44841,30 +44873,30 @@ var Preview = function(props) {
44841
44873
  var _t;
44842
44874
  if ($[3] !== setFiles) {
44843
44875
  _t = function(file) {
44844
- return /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes49.Card, {
44876
+ return /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes49.Card, {
44845
44877
  variant: "ghost",
44846
- children: /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(import_themes49.Flex, {
44878
+ children: /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(import_themes49.Flex, {
44847
44879
  align: "center",
44848
44880
  justify: "between",
44849
44881
  gap: "1",
44850
44882
  children: [
44851
- /* @__PURE__ */ (0, import_jsx_runtime72.jsxs)(import_themes49.Flex, {
44883
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(import_themes49.Flex, {
44852
44884
  align: "center",
44853
44885
  gap: "1",
44854
44886
  flexShrink: "1",
44855
44887
  minWidth: "0",
44856
44888
  maxWidth: "250px",
44857
44889
  children: [
44858
- /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes49.Flex, {
44890
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes49.Flex, {
44859
44891
  flexShrink: "0",
44860
- children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes49.Spinner, {
44892
+ children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes49.Spinner, {
44861
44893
  loading: isOptimistic({
44862
44894
  id: file.id
44863
44895
  }),
44864
- children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react_icons12.FileIcon, {})
44896
+ children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_react_icons12.FileIcon, {})
44865
44897
  })
44866
44898
  }),
44867
- /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes49.Text, {
44899
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes49.Text, {
44868
44900
  size: "2",
44869
44901
  truncate: true,
44870
44902
  wrap: "nowrap",
@@ -44872,9 +44904,9 @@ var Preview = function(props) {
44872
44904
  })
44873
44905
  ]
44874
44906
  }),
44875
- /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes49.Flex, {
44907
+ /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes49.Flex, {
44876
44908
  flexShrink: "0",
44877
- children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes49.IconButton, {
44909
+ children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes49.IconButton, {
44878
44910
  onClick: function() {
44879
44911
  return setFiles(function(prev) {
44880
44912
  return prev.filter(function(prevFile) {
@@ -44885,7 +44917,7 @@ var Preview = function(props) {
44885
44917
  color: "gray",
44886
44918
  variant: "ghost",
44887
44919
  size: "1",
44888
- children: /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_react_icons12.Cross2Icon, {})
44920
+ children: /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_react_icons12.Cross2Icon, {})
44889
44921
  })
44890
44922
  })
44891
44923
  ]
@@ -44906,7 +44938,7 @@ var Preview = function(props) {
44906
44938
  }
44907
44939
  var t1;
44908
44940
  if ($[5] !== props || $[6] !== t0) {
44909
- t1 = /* @__PURE__ */ (0, import_jsx_runtime72.jsx)(import_themes49.Flex, _objectSpread33(_objectSpread33({
44941
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes49.Flex, _objectSpread33(_objectSpread33({
44910
44942
  flexBasis: "100%",
44911
44943
  direction: "column",
44912
44944
  pb: "2",
@@ -44923,15 +44955,15 @@ var Preview = function(props) {
44923
44955
  return t1;
44924
44956
  };
44925
44957
  // src/components/threads/Thread/MessageForm/Field/Files/Control.tsx
44926
- var import_react_compiler_runtime72 = require("react-compiler-runtime");
44958
+ var import_react_compiler_runtime73 = require("react-compiler-runtime");
44927
44959
  var import_react_icons13 = require("@radix-ui/react-icons");
44928
44960
  var import_themes50 = require("@radix-ui/themes");
44929
44961
  // src/hooks/files/useChangeFilesField/index.ts
44930
- var import_react55 = require("react");
44962
+ var import_react56 = require("react");
44931
44963
  var import_radash15 = require("radash");
44932
44964
  var import_dayjs2 = __toESM(require("dayjs"), 1);
44933
44965
  // src/hooks/files/useCreateFile/index.ts
44934
- var import_react_compiler_runtime71 = require("react-compiler-runtime");
44966
+ var import_react_compiler_runtime72 = require("react-compiler-runtime");
44935
44967
  var import_react_query7 = require("@tanstack/react-query");
44936
44968
  // src/hooks/files/useCreateFile/lib/mutationOptions/mutationFn/body/formData.ts
44937
44969
  var formData = function(variables) {
@@ -45167,7 +45199,7 @@ function _toPrimitive36(t, r) {
45167
45199
  return ("string" === r ? String : Number)(t);
45168
45200
  }
45169
45201
  var useCreateFile = function(t0) {
45170
- var $ = (0, import_react_compiler_runtime71.c)(15);
45202
+ var $ = (0, import_react_compiler_runtime72.c)(15);
45171
45203
  var t1;
45172
45204
  if ($[0] !== t0) {
45173
45205
  t1 = t0 === void 0 ? {
@@ -45318,7 +45350,7 @@ var useChangeFilesField = function() {
45318
45350
  var setFiles = useMessageFormContext().setFiles;
45319
45351
  var createFile = useCreateFile().createFile;
45320
45352
  var addToast = useToasts().addToast;
45321
- var changeFilesField = (0, import_react55.useCallback)(/* @__PURE__ */ function() {
45353
+ var changeFilesField = (0, import_react56.useCallback)(/* @__PURE__ */ function() {
45322
45354
  var _ref2 = _asyncToGenerator8(function(event) {
45323
45355
  var fileObjects, newFiles, _iteratorAbruptCompletion, _didIteratorError, _iteratorError, _loop, _iterator, _step, err;
45324
45356
  return _ts_generator(this, function(_state) {
@@ -45496,7 +45528,7 @@ var useChangeFilesField = function() {
45496
45528
  // src/lib/files/filesFieldAccept.ts
45497
45529
  var filesFieldAccept = ".c,text/x-c,\n.cs,text/x-csharp,\n.cpp,text/x-c++,\n.doc,application/msword,\n.docx,application/vnd.openxmlformats-officedocument.wordprocessingml.document,\n.html,text/html,\n.java,text/x-java,\n.json,application/json,\n.md,text/markdown,\n.pdf,application/pdf,\n.php,text/x-php,\n.pptx,application/vnd.openxmlformats-officedocument.presentationml.presentation,\n.py,text/x-python,\n.py,text/x-script.python,\n.rb,text/x-ruby,\n.tex,text/x-tex,\n.txt,text/plain,\n.css,text/css,\n.js,text/javascript,\n.sh,application/x-sh,\n.ts,application/typescript,\n.png,image/png,\n.jpeg,image/jpeg,\n.jpg,image/jpeg,\n.webp,image/webp,\n.gif,image/gif";
45498
45530
  // src/components/threads/Thread/MessageForm/Field/Files/Control.tsx
45499
- var import_jsx_runtime73 = require("react/jsx-runtime");
45531
+ var import_jsx_runtime74 = require("react/jsx-runtime");
45500
45532
  function ownKeys37(e, r) {
45501
45533
  var t = Object.keys(e);
45502
45534
  if (Object.getOwnPropertySymbols) {
@@ -45541,7 +45573,7 @@ function _toPrimitive37(t, r) {
45541
45573
  return ("string" === r ? String : Number)(t);
45542
45574
  }
45543
45575
  var Control2 = function(props) {
45544
- var $ = (0, import_react_compiler_runtime72.c)(11);
45576
+ var $ = (0, import_react_compiler_runtime73.c)(11);
45545
45577
  var _useMessageFormContext = useMessageFormContext(), isDisabled = _useMessageFormContext.isDisabled, isLoading = _useMessageFormContext.isLoading;
45546
45578
  var changeFilesField = useChangeFilesField().changeFilesField;
45547
45579
  var t0 = isDisabled || isLoading;
@@ -45552,7 +45584,7 @@ var Control2 = function(props) {
45552
45584
  position: "relative",
45553
45585
  overflow: "hidden"
45554
45586
  };
45555
- t2 = /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_react_icons13.FilePlusIcon, {});
45587
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_react_icons13.FilePlusIcon, {});
45556
45588
  $[0] = t1;
45557
45589
  $[1] = t2;
45558
45590
  } else {
@@ -45576,7 +45608,7 @@ var Control2 = function(props) {
45576
45608
  }
45577
45609
  var t4;
45578
45610
  if ($[3] !== changeFilesField) {
45579
- t4 = /* @__PURE__ */ (0, import_jsx_runtime73.jsx)("input", {
45611
+ t4 = /* @__PURE__ */ (0, import_jsx_runtime74.jsx)("input", {
45580
45612
  type: "file",
45581
45613
  multiple: true,
45582
45614
  accept: filesFieldAccept,
@@ -45590,7 +45622,7 @@ var Control2 = function(props) {
45590
45622
  }
45591
45623
  var t5;
45592
45624
  if ($[5] !== t0 || $[6] !== t4) {
45593
- t5 = /* @__PURE__ */ (0, import_jsx_runtime73.jsxs)(import_themes50.IconButton, {
45625
+ t5 = /* @__PURE__ */ (0, import_jsx_runtime74.jsxs)(import_themes50.IconButton, {
45594
45626
  type: "button",
45595
45627
  variant: "ghost",
45596
45628
  color: "gray",
@@ -45609,7 +45641,7 @@ var Control2 = function(props) {
45609
45641
  }
45610
45642
  var t6;
45611
45643
  if ($[8] !== props || $[9] !== t5) {
45612
- t6 = /* @__PURE__ */ (0, import_jsx_runtime73.jsx)(import_themes50.Flex, _objectSpread37(_objectSpread37({
45644
+ t6 = /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_themes50.Flex, _objectSpread37(_objectSpread37({
45613
45645
  pt: "2",
45614
45646
  pr: "2",
45615
45647
  flexGrow: "0"
@@ -45630,7 +45662,7 @@ var Files = {
45630
45662
  Control: Control2
45631
45663
  };
45632
45664
  // src/components/threads/Thread/MessageForm/Field/index.tsx
45633
- var import_jsx_runtime74 = require("react/jsx-runtime");
45665
+ var import_jsx_runtime75 = require("react/jsx-runtime");
45634
45666
  function ownKeys38(e, r) {
45635
45667
  var t = Object.keys(e);
45636
45668
  if (Object.getOwnPropertySymbols) {
@@ -45677,19 +45709,19 @@ function _toPrimitive38(t, r) {
45677
45709
  var Root10 = function(_ref) {
45678
45710
  "use no memo";
45679
45711
  var children = _ref.children, className = _ref.className, style = _ref.style;
45680
- var _$_ref = (0, import_react_hook_form3.useFormContext)(), errors = _$_ref.formState.errors;
45681
- return /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_themes51.Container, {
45712
+ var _useFormContext = useFormContext(), errors = _useFormContext.formState.errors;
45713
+ return /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_themes51.Container, {
45682
45714
  size: "2",
45683
45715
  flexGrow: "0",
45684
45716
  className: className,
45685
45717
  style: style,
45686
- children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_themes51.Flex, {
45718
+ children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_themes51.Flex, {
45687
45719
  direction: "column",
45688
45720
  flexShrink: "0",
45689
- children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_themes51.Flex, {
45721
+ children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_themes51.Flex, {
45690
45722
  direction: "column",
45691
45723
  flexShrink: "0",
45692
- children: /* @__PURE__ */ (0, import_jsx_runtime74.jsx)(import_themes51.Flex, {
45724
+ children: /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(import_themes51.Flex, {
45693
45725
  style: _objectSpread38({
45694
45726
  borderRadius: "var(--radius-2)",
45695
45727
  borderWidth: "1px",
@@ -45713,7 +45745,7 @@ var Field = {
45713
45745
  Files: Files
45714
45746
  };
45715
45747
  // src/components/threads/Thread/MessageForm/index.tsx
45716
- var import_jsx_runtime75 = require("react/jsx-runtime");
45748
+ var import_jsx_runtime76 = require("react/jsx-runtime");
45717
45749
  function ownKeys39(e, r) {
45718
45750
  var t = Object.keys(e);
45719
45751
  if (Object.getOwnPropertySymbols) {
@@ -45758,13 +45790,13 @@ function _toPrimitive39(t, r) {
45758
45790
  return ("string" === r ? String : Number)(t);
45759
45791
  }
45760
45792
  var MessageForm = function(props) {
45761
- var $ = (0, import_react_compiler_runtime73.c)(3);
45793
+ var $ = (0, import_react_compiler_runtime74.c)(3);
45762
45794
  var t0;
45763
45795
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
45764
- t0 = /* @__PURE__ */ (0, import_jsx_runtime75.jsxs)(Field.Root, {
45796
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(Field.Root, {
45765
45797
  children: [
45766
- /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(Field.Control, {}),
45767
- /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(Submit, {})
45798
+ /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Field.Control, {}),
45799
+ /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Submit, {})
45768
45800
  ]
45769
45801
  });
45770
45802
  $[0] = t0;
@@ -45773,7 +45805,7 @@ var MessageForm = function(props) {
45773
45805
  }
45774
45806
  var t1;
45775
45807
  if ($[1] !== props) {
45776
- t1 = /* @__PURE__ */ (0, import_jsx_runtime75.jsx)(Root8, _objectSpread39(_objectSpread39({}, props), {}, {
45808
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Root8, _objectSpread39(_objectSpread39({}, props), {}, {
45777
45809
  children: t0
45778
45810
  }));
45779
45811
  $[1] = props;
@@ -45787,32 +45819,32 @@ MessageForm.Root = Root8;
45787
45819
  MessageForm.Field = Field;
45788
45820
  MessageForm.Submit = Submit;
45789
45821
  // src/components/threads/Thread/Root/index.tsx
45790
- var import_react_compiler_runtime76 = require("react-compiler-runtime");
45822
+ var import_react_compiler_runtime77 = require("react-compiler-runtime");
45791
45823
  var import_themes53 = require("@radix-ui/themes");
45792
45824
  // src/components/threads/Thread/Provider/index.tsx
45793
45825
  var Provider2 = SuperinterfaceProvider;
45794
45826
  // src/components/toasts/ToastsProvider/index.tsx
45795
- var import_react_compiler_runtime75 = require("react-compiler-runtime");
45796
- var import_react56 = require("react");
45827
+ var import_react_compiler_runtime76 = require("react-compiler-runtime");
45828
+ var import_react57 = require("react");
45797
45829
  var Toast2 = __toESM(require("@radix-ui/react-toast"), 1);
45798
45830
  // src/components/toasts/ToastsProvider/CustomToast.tsx
45799
- var import_react_compiler_runtime74 = require("react-compiler-runtime");
45831
+ var import_react_compiler_runtime75 = require("react-compiler-runtime");
45800
45832
  var Toast = __toESM(require("@radix-ui/react-toast"), 1);
45801
45833
  var import_themes52 = require("@radix-ui/themes");
45802
45834
  var import_react_icons14 = require("@radix-ui/react-icons");
45803
- var import_jsx_runtime76 = require("react/jsx-runtime");
45835
+ var import_jsx_runtime77 = require("react/jsx-runtime");
45804
45836
  var CustomToast = function(t0) {
45805
- var $ = (0, import_react_compiler_runtime74.c)(7);
45837
+ var $ = (0, import_react_compiler_runtime75.c)(7);
45806
45838
  var toast = t0.toast;
45807
45839
  var t1;
45808
45840
  if ($[0] !== toast.type) {
45809
- t1 = /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_themes52.Flex, {
45841
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_themes52.Flex, {
45810
45842
  pr: "2",
45811
45843
  height: "14px",
45812
45844
  align: "center",
45813
- children: toast.type === "success" ? /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_react_icons14.CheckCircledIcon, {
45845
+ children: toast.type === "success" ? /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_react_icons14.CheckCircledIcon, {
45814
45846
  color: "var(--accent-9)"
45815
- }) : /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_react_icons14.CrossCircledIcon, {
45847
+ }) : /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_react_icons14.CrossCircledIcon, {
45816
45848
  color: "var(--red-9)"
45817
45849
  })
45818
45850
  });
@@ -45823,7 +45855,7 @@ var CustomToast = function(t0) {
45823
45855
  }
45824
45856
  var t2;
45825
45857
  if ($[2] !== toast.message) {
45826
- t2 = /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_themes52.Text, {
45858
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_themes52.Text, {
45827
45859
  weight: "medium",
45828
45860
  size: "1",
45829
45861
  children: toast.message
@@ -45835,10 +45867,10 @@ var CustomToast = function(t0) {
45835
45867
  }
45836
45868
  var t3;
45837
45869
  if ($[4] !== t1 || $[5] !== t2) {
45838
- t3 = /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Toast.Root, {
45839
- children: /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(import_themes52.Card, {
45840
- children: /* @__PURE__ */ (0, import_jsx_runtime76.jsx)(Toast.Title, {
45841
- children: /* @__PURE__ */ (0, import_jsx_runtime76.jsxs)(import_themes52.Flex, {
45870
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(Toast.Root, {
45871
+ children: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(import_themes52.Card, {
45872
+ children: /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(Toast.Title, {
45873
+ children: /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(import_themes52.Flex, {
45842
45874
  children: [
45843
45875
  t1,
45844
45876
  t2
@@ -45856,9 +45888,9 @@ var CustomToast = function(t0) {
45856
45888
  return t3;
45857
45889
  };
45858
45890
  // src/components/toasts/ToastsProvider/index.tsx
45859
- var import_jsx_runtime77 = require("react/jsx-runtime");
45891
+ var import_jsx_runtime78 = require("react/jsx-runtime");
45860
45892
  var ToastsProvider = function(t0) {
45861
- var $ = (0, import_react_compiler_runtime75.c)(15);
45893
+ var $ = (0, import_react_compiler_runtime76.c)(15);
45862
45894
  var children = t0.children, t1 = t0.bottom;
45863
45895
  var bottom = t1 === void 0 ? 0 : t1;
45864
45896
  var t2;
@@ -45868,7 +45900,7 @@ var ToastsProvider = function(t0) {
45868
45900
  } else {
45869
45901
  t2 = $[0];
45870
45902
  }
45871
- var _ref = _sliced_to_array((0, import_react56.useState)(t2), 2), toasts = _ref[0], setToasts = _ref[1];
45903
+ var _ref = _sliced_to_array((0, import_react57.useState)(t2), 2), toasts = _ref[0], setToasts = _ref[1];
45872
45904
  var t3;
45873
45905
  if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
45874
45906
  t3 = function(toast) {
@@ -45904,7 +45936,7 @@ var ToastsProvider = function(t0) {
45904
45936
  }
45905
45937
  var t6;
45906
45938
  if ($[6] !== bottom) {
45907
- t6 = /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(Toast2.Viewport, {
45939
+ t6 = /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(Toast2.Viewport, {
45908
45940
  style: {
45909
45941
  position: "absolute",
45910
45942
  bottom: bottom,
@@ -45928,7 +45960,7 @@ var ToastsProvider = function(t0) {
45928
45960
  }
45929
45961
  var t7;
45930
45962
  if ($[8] !== children || $[9] !== t5 || $[10] !== t6) {
45931
- t7 = /* @__PURE__ */ (0, import_jsx_runtime77.jsxs)(Toast2.Provider, {
45963
+ t7 = /* @__PURE__ */ (0, import_jsx_runtime78.jsxs)(Toast2.Provider, {
45932
45964
  children: [
45933
45965
  children,
45934
45966
  t5,
@@ -45944,7 +45976,7 @@ var ToastsProvider = function(t0) {
45944
45976
  }
45945
45977
  var t8;
45946
45978
  if ($[12] !== t4 || $[13] !== t7) {
45947
- t8 = /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(ToastsContext.Provider, {
45979
+ t8 = /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(ToastsContext.Provider, {
45948
45980
  value: t4,
45949
45981
  children: t7
45950
45982
  });
@@ -45957,12 +45989,12 @@ var ToastsProvider = function(t0) {
45957
45989
  return t8;
45958
45990
  };
45959
45991
  function _temp5(toast_0, index) {
45960
- return /* @__PURE__ */ (0, import_jsx_runtime77.jsx)(CustomToast, {
45992
+ return /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(CustomToast, {
45961
45993
  toast: toast_0
45962
45994
  }, index);
45963
45995
  }
45964
45996
  // src/components/threads/Thread/Root/index.tsx
45965
- var import_jsx_runtime78 = require("react/jsx-runtime");
45997
+ var import_jsx_runtime79 = require("react/jsx-runtime");
45966
45998
  var _excluded4 = [
45967
45999
  "children",
45968
46000
  "style",
@@ -46030,7 +46062,7 @@ function _objectWithoutPropertiesLoose4(r, e) {
46030
46062
  return t;
46031
46063
  }
46032
46064
  var Root12 = function(t0) {
46033
- var $ = (0, import_react_compiler_runtime76.c)(12);
46065
+ var $ = (0, import_react_compiler_runtime77.c)(12);
46034
46066
  var children;
46035
46067
  var className;
46036
46068
  var rest;
@@ -46054,7 +46086,7 @@ var Root12 = function(t0) {
46054
46086
  }
46055
46087
  var t1;
46056
46088
  if ($[5] !== children || $[6] !== className || $[7] !== style) {
46057
- t1 = /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(import_themes53.Flex, {
46089
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(import_themes53.Flex, {
46058
46090
  direction: "column",
46059
46091
  flexGrow: "1",
46060
46092
  className: className,
@@ -46070,9 +46102,9 @@ var Root12 = function(t0) {
46070
46102
  }
46071
46103
  var t2;
46072
46104
  if ($[9] !== rest || $[10] !== t1) {
46073
- t2 = /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(ToastsProvider, {
46105
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(ToastsProvider, {
46074
46106
  bottom: "var(--space-9)",
46075
- children: /* @__PURE__ */ (0, import_jsx_runtime78.jsx)(Provider2, _objectSpread40(_objectSpread40({}, rest), {}, {
46107
+ children: /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(Provider2, _objectSpread40(_objectSpread40({}, rest), {}, {
46076
46108
  children: t1
46077
46109
  }))
46078
46110
  });
@@ -46085,7 +46117,7 @@ var Root12 = function(t0) {
46085
46117
  return t2;
46086
46118
  };
46087
46119
  // src/components/threads/Thread/index.tsx
46088
- var import_jsx_runtime79 = require("react/jsx-runtime");
46120
+ var import_jsx_runtime80 = require("react/jsx-runtime");
46089
46121
  function ownKeys41(e, r) {
46090
46122
  var t = Object.keys(e);
46091
46123
  if (Object.getOwnPropertySymbols) {
@@ -46130,12 +46162,12 @@ function _toPrimitive41(t, r) {
46130
46162
  return ("string" === r ? String : Number)(t);
46131
46163
  }
46132
46164
  var Thread = function(props) {
46133
- var $ = (0, import_react_compiler_runtime77.c)(4);
46165
+ var $ = (0, import_react_compiler_runtime78.c)(4);
46134
46166
  var t0;
46135
46167
  var t1;
46136
46168
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
46137
- t0 = /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(Messages2, {});
46138
- t1 = /* @__PURE__ */ (0, import_jsx_runtime79.jsx)(MessageForm, {});
46169
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(Messages2, {});
46170
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(MessageForm, {});
46139
46171
  $[0] = t0;
46140
46172
  $[1] = t1;
46141
46173
  } else {
@@ -46144,7 +46176,7 @@ var Thread = function(props) {
46144
46176
  }
46145
46177
  var t2;
46146
46178
  if ($[2] !== props) {
46147
- t2 = /* @__PURE__ */ (0, import_jsx_runtime79.jsxs)(Root12, _objectSpread41(_objectSpread41({}, props), {}, {
46179
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime80.jsxs)(Root12, _objectSpread41(_objectSpread41({}, props), {}, {
46148
46180
  children: [
46149
46181
  t0,
46150
46182
  t1
@@ -46161,13 +46193,13 @@ Thread.Root = Root12;
46161
46193
  Thread.Messages = Messages2;
46162
46194
  Thread.MessageForm = MessageForm;
46163
46195
  // src/hooks/messages/useMessageContext/index.ts
46164
- var import_react57 = require("react");
46196
+ var import_react58 = require("react");
46165
46197
  var useMessageContext = function() {
46166
- return (0, import_react57.useContext)(MessageContext);
46198
+ return (0, import_react58.useContext)(MessageContext);
46167
46199
  };
46168
46200
  // src/hooks/assistants/useAssistant/index.ts
46169
- var import_react_compiler_runtime78 = require("react-compiler-runtime");
46170
- var import_react58 = require("react");
46201
+ var import_react_compiler_runtime79 = require("react-compiler-runtime");
46202
+ var import_react59 = require("react");
46171
46203
  var import_react_query9 = require("@tanstack/react-query");
46172
46204
  // src/hooks/assistants/useAssistant/lib/queryOptions/index.ts
46173
46205
  var import_react_query8 = require("@tanstack/react-query");
@@ -46316,7 +46348,7 @@ function _toPrimitive42(t, r) {
46316
46348
  return ("string" === r ? String : Number)(t);
46317
46349
  }
46318
46350
  var useAssistant = function(t0) {
46319
- var $ = (0, import_react_compiler_runtime78.c)(6);
46351
+ var $ = (0, import_react_compiler_runtime79.c)(6);
46320
46352
  var assistantId = t0.assistantId;
46321
46353
  var superinterfaceContext = useSuperinterfaceContext();
46322
46354
  var t1;
@@ -46349,30 +46381,30 @@ var useAssistant = function(t0) {
46349
46381
  return t2;
46350
46382
  };
46351
46383
  // src/components/threads/ThreadDialog/index.tsx
46352
- var import_react_compiler_runtime85 = require("react-compiler-runtime");
46384
+ var import_react_compiler_runtime86 = require("react-compiler-runtime");
46353
46385
  // src/components/threads/ThreadDialog/Root/index.tsx
46354
- var import_react_compiler_runtime80 = require("react-compiler-runtime");
46386
+ var import_react_compiler_runtime81 = require("react-compiler-runtime");
46355
46387
  // src/components/threads/ThreadDialog/Provider/index.tsx
46356
- var import_react_compiler_runtime79 = require("react-compiler-runtime");
46357
- var import_react61 = require("react");
46388
+ var import_react_compiler_runtime80 = require("react-compiler-runtime");
46389
+ var import_react62 = require("react");
46358
46390
  // src/contexts/threads/ThreadDialogContext/index.ts
46359
- var import_react59 = require("react");
46360
- var ThreadDialogContext = /* @__PURE__ */ (0, import_react59.createContext)({
46391
+ var import_react60 = require("react");
46392
+ var ThreadDialogContext = /* @__PURE__ */ (0, import_react60.createContext)({
46361
46393
  isOpen: false,
46362
46394
  setIsOpen: function() {}
46363
46395
  });
46364
46396
  // src/hooks/threads/useThreadDialogContext/index.ts
46365
- var import_react60 = require("react");
46397
+ var import_react61 = require("react");
46366
46398
  var useThreadDialogContext = function() {
46367
- return (0, import_react60.useContext)(ThreadDialogContext);
46399
+ return (0, import_react61.useContext)(ThreadDialogContext);
46368
46400
  };
46369
46401
  // src/components/threads/ThreadDialog/Provider/index.tsx
46370
- var import_jsx_runtime80 = require("react/jsx-runtime");
46402
+ var import_jsx_runtime81 = require("react/jsx-runtime");
46371
46403
  var Provider4 = function(t0) {
46372
- var $ = (0, import_react_compiler_runtime79.c)(5);
46404
+ var $ = (0, import_react_compiler_runtime80.c)(5);
46373
46405
  var children = t0.children;
46374
46406
  var threadDialogContext = useThreadDialogContext();
46375
- var _ref = _sliced_to_array((0, import_react61.useState)(threadDialogContext.isOpen), 2), isOpen = _ref[0], setIsOpen = _ref[1];
46407
+ var _ref = _sliced_to_array((0, import_react62.useState)(threadDialogContext.isOpen), 2), isOpen = _ref[0], setIsOpen = _ref[1];
46376
46408
  var t1;
46377
46409
  if ($[0] !== isOpen) {
46378
46410
  t1 = {
@@ -46386,7 +46418,7 @@ var Provider4 = function(t0) {
46386
46418
  }
46387
46419
  var t2;
46388
46420
  if ($[2] !== children || $[3] !== t1) {
46389
- t2 = /* @__PURE__ */ (0, import_jsx_runtime80.jsx)(ThreadDialogContext.Provider, {
46421
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(ThreadDialogContext.Provider, {
46390
46422
  value: t1,
46391
46423
  children: children
46392
46424
  });
@@ -46399,13 +46431,13 @@ var Provider4 = function(t0) {
46399
46431
  return t2;
46400
46432
  };
46401
46433
  // src/components/threads/ThreadDialog/Root/index.tsx
46402
- var import_jsx_runtime81 = require("react/jsx-runtime");
46434
+ var import_jsx_runtime82 = require("react/jsx-runtime");
46403
46435
  var Root13 = function(t0) {
46404
- var $ = (0, import_react_compiler_runtime80.c)(2);
46436
+ var $ = (0, import_react_compiler_runtime81.c)(2);
46405
46437
  var children = t0.children;
46406
46438
  var t1;
46407
46439
  if ($[0] !== children) {
46408
- t1 = /* @__PURE__ */ (0, import_jsx_runtime81.jsx)(Provider4, {
46440
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(Provider4, {
46409
46441
  children: children
46410
46442
  });
46411
46443
  $[0] = children;
@@ -46416,13 +46448,13 @@ var Root13 = function(t0) {
46416
46448
  return t1;
46417
46449
  };
46418
46450
  // src/components/threads/ThreadDialog/Trigger/index.tsx
46419
- var import_react_compiler_runtime82 = require("react-compiler-runtime");
46451
+ var import_react_compiler_runtime83 = require("react-compiler-runtime");
46420
46452
  var import_themes55 = require("@radix-ui/themes");
46421
46453
  // src/components/threads/ThreadDialog/Trigger/Button.tsx
46422
- var import_react_compiler_runtime81 = require("react-compiler-runtime");
46454
+ var import_react_compiler_runtime82 = require("react-compiler-runtime");
46423
46455
  var import_themes54 = require("@radix-ui/themes");
46424
46456
  var import_react_icons15 = require("@radix-ui/react-icons");
46425
- var import_jsx_runtime82 = require("react/jsx-runtime");
46457
+ var import_jsx_runtime83 = require("react/jsx-runtime");
46426
46458
  function ownKeys43(e, r) {
46427
46459
  var t = Object.keys(e);
46428
46460
  if (Object.getOwnPropertySymbols) {
@@ -46467,17 +46499,17 @@ function _toPrimitive43(t, r) {
46467
46499
  return ("string" === r ? String : Number)(t);
46468
46500
  }
46469
46501
  var Button4 = function(props) {
46470
- var $ = (0, import_react_compiler_runtime81.c)(3);
46502
+ var $ = (0, import_react_compiler_runtime82.c)(3);
46471
46503
  var t0;
46472
46504
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
46473
- t0 = /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_react_icons15.ChatBubbleIcon, {});
46505
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(import_react_icons15.ChatBubbleIcon, {});
46474
46506
  $[0] = t0;
46475
46507
  } else {
46476
46508
  t0 = $[0];
46477
46509
  }
46478
46510
  var t1;
46479
46511
  if ($[1] !== props) {
46480
- t1 = /* @__PURE__ */ (0, import_jsx_runtime82.jsx)(import_themes54.IconButton, _objectSpread43(_objectSpread43({
46512
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(import_themes54.IconButton, _objectSpread43(_objectSpread43({
46481
46513
  size: "4",
46482
46514
  radius: "full"
46483
46515
  }, props), {}, {
@@ -46491,7 +46523,7 @@ var Button4 = function(props) {
46491
46523
  return t1;
46492
46524
  };
46493
46525
  // src/components/threads/ThreadDialog/Trigger/index.tsx
46494
- var import_jsx_runtime83 = require("react/jsx-runtime");
46526
+ var import_jsx_runtime84 = require("react/jsx-runtime");
46495
46527
  function ownKeys44(e, r) {
46496
46528
  var t = Object.keys(e);
46497
46529
  if (Object.getOwnPropertySymbols) {
@@ -46536,7 +46568,7 @@ function _toPrimitive44(t, r) {
46536
46568
  return ("string" === r ? String : Number)(t);
46537
46569
  }
46538
46570
  var Root14 = function(t0) {
46539
- var $ = (0, import_react_compiler_runtime82.c)(14);
46571
+ var $ = (0, import_react_compiler_runtime83.c)(14);
46540
46572
  var children = t0.children, style = t0.style, className = t0.className;
46541
46573
  var _useThreadDialogContext = useThreadDialogContext(), setIsOpen = _useThreadDialogContext.setIsOpen, isOpen = _useThreadDialogContext.isOpen;
46542
46574
  var t1 = isOpen ? "none" : "flex";
@@ -46581,7 +46613,7 @@ var Root14 = function(t0) {
46581
46613
  }
46582
46614
  var t6;
46583
46615
  if ($[8] !== children || $[9] !== className || $[10] !== t2 || $[11] !== t3 || $[12] !== t5) {
46584
- t6 = /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(import_themes55.Flex, {
46616
+ t6 = /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_themes55.Flex, {
46585
46617
  display: t2,
46586
46618
  onClick: t3,
46587
46619
  direction: "column",
@@ -46607,17 +46639,17 @@ var Root14 = function(t0) {
46607
46639
  return t6;
46608
46640
  };
46609
46641
  var Trigger = function(args) {
46610
- var $ = (0, import_react_compiler_runtime82.c)(3);
46642
+ var $ = (0, import_react_compiler_runtime83.c)(3);
46611
46643
  var t0;
46612
46644
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
46613
- t0 = /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Button4, {});
46645
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(Button4, {});
46614
46646
  $[0] = t0;
46615
46647
  } else {
46616
46648
  t0 = $[0];
46617
46649
  }
46618
46650
  var t1;
46619
46651
  if ($[1] !== args) {
46620
- t1 = /* @__PURE__ */ (0, import_jsx_runtime83.jsx)(Root14, _objectSpread44(_objectSpread44({}, args), {}, {
46652
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(Root14, _objectSpread44(_objectSpread44({}, args), {}, {
46621
46653
  children: t0
46622
46654
  }));
46623
46655
  $[1] = args;
@@ -46633,15 +46665,15 @@ function _temp6(prev) {
46633
46665
  return !prev;
46634
46666
  }
46635
46667
  // src/components/threads/ThreadDialog/Content/index.tsx
46636
- var import_react_compiler_runtime84 = require("react-compiler-runtime");
46668
+ var import_react_compiler_runtime85 = require("react-compiler-runtime");
46637
46669
  var import_themes57 = require("@radix-ui/themes");
46638
46670
  // src/components/threads/ThreadDialog/Close/index.tsx
46639
- var import_react_compiler_runtime83 = require("react-compiler-runtime");
46671
+ var import_react_compiler_runtime84 = require("react-compiler-runtime");
46640
46672
  var import_react_icons16 = require("@radix-ui/react-icons");
46641
46673
  var import_themes56 = require("@radix-ui/themes");
46642
- var import_jsx_runtime84 = require("react/jsx-runtime");
46674
+ var import_jsx_runtime85 = require("react/jsx-runtime");
46643
46675
  var Close = function() {
46644
- var $ = (0, import_react_compiler_runtime83.c)(9);
46676
+ var $ = (0, import_react_compiler_runtime84.c)(9);
46645
46677
  var _useThreadDialogContext = useThreadDialogContext(), setIsOpen = _useThreadDialogContext.setIsOpen, isOpen = _useThreadDialogContext.isOpen;
46646
46678
  var t0 = isOpen ? "flex" : "none";
46647
46679
  var t1;
@@ -46676,10 +46708,10 @@ var Close = function() {
46676
46708
  }
46677
46709
  var t4;
46678
46710
  if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
46679
- t4 = /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_themes56.IconButton, {
46711
+ t4 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_themes56.IconButton, {
46680
46712
  size: "2",
46681
46713
  variant: "soft",
46682
- children: /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_react_icons16.Cross1Icon, {})
46714
+ children: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_react_icons16.Cross1Icon, {})
46683
46715
  });
46684
46716
  $[5] = t4;
46685
46717
  } else {
@@ -46687,7 +46719,7 @@ var Close = function() {
46687
46719
  }
46688
46720
  var t5;
46689
46721
  if ($[6] !== t1 || $[7] !== t2) {
46690
- t5 = /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(import_themes56.Flex, {
46722
+ t5 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_themes56.Flex, {
46691
46723
  display: t1,
46692
46724
  onClick: t2,
46693
46725
  direction: "column",
@@ -46712,7 +46744,7 @@ function _temp7(prev) {
46712
46744
  return !prev;
46713
46745
  }
46714
46746
  // src/components/threads/ThreadDialog/Content/index.tsx
46715
- var import_jsx_runtime85 = require("react/jsx-runtime");
46747
+ var import_jsx_runtime86 = require("react/jsx-runtime");
46716
46748
  function ownKeys45(e, r) {
46717
46749
  var t = Object.keys(e);
46718
46750
  if (Object.getOwnPropertySymbols) {
@@ -46757,7 +46789,7 @@ function _toPrimitive45(t, r) {
46757
46789
  return ("string" === r ? String : Number)(t);
46758
46790
  }
46759
46791
  var Root15 = function(t0) {
46760
- var $ = (0, import_react_compiler_runtime84.c)(19);
46792
+ var $ = (0, import_react_compiler_runtime85.c)(19);
46761
46793
  var children = t0.children, className = t0.className, style = t0.style;
46762
46794
  var isOpen = useThreadDialogContext().isOpen;
46763
46795
  if (!isOpen) {
@@ -46844,7 +46876,7 @@ var Root15 = function(t0) {
46844
46876
  }
46845
46877
  var t10;
46846
46878
  if ($[10] !== children) {
46847
- t10 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_themes57.Inset, {
46879
+ t10 = /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(import_themes57.Inset, {
46848
46880
  clip: "padding-box",
46849
46881
  side: "all",
46850
46882
  pb: "current",
@@ -46858,14 +46890,14 @@ var Root15 = function(t0) {
46858
46890
  }
46859
46891
  var t11;
46860
46892
  if ($[12] === Symbol.for("react.memo_cache_sentinel")) {
46861
- t11 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(Close, {});
46893
+ t11 = /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Close, {});
46862
46894
  $[12] = t11;
46863
46895
  } else {
46864
46896
  t11 = $[12];
46865
46897
  }
46866
46898
  var t12;
46867
46899
  if ($[13] !== t10) {
46868
- t12 = /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)(import_themes57.Card, {
46900
+ t12 = /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(import_themes57.Card, {
46869
46901
  mb: t7,
46870
46902
  style: t8,
46871
46903
  children: [
@@ -46880,7 +46912,7 @@ var Root15 = function(t0) {
46880
46912
  }
46881
46913
  var t13;
46882
46914
  if ($[15] !== className || $[16] !== t12 || $[17] !== t6) {
46883
- t13 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_themes57.Flex, {
46915
+ t13 = /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(import_themes57.Flex, {
46884
46916
  className: className,
46885
46917
  direction: "column",
46886
46918
  justify: "end",
@@ -46904,7 +46936,7 @@ var Root15 = function(t0) {
46904
46936
  return t13;
46905
46937
  };
46906
46938
  var Messages3 = function(t0) {
46907
- var $ = (0, import_react_compiler_runtime84.c)(5);
46939
+ var $ = (0, import_react_compiler_runtime85.c)(5);
46908
46940
  var className = t0.className, style = t0.style;
46909
46941
  var t1;
46910
46942
  if ($[0] !== style) {
@@ -46920,7 +46952,7 @@ var Messages3 = function(t0) {
46920
46952
  }
46921
46953
  var t2;
46922
46954
  if ($[2] !== className || $[3] !== t1) {
46923
- t2 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(Thread.Messages, {
46955
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Thread.Messages, {
46924
46956
  className: className,
46925
46957
  style: t1
46926
46958
  });
@@ -46933,11 +46965,11 @@ var Messages3 = function(t0) {
46933
46965
  return t2;
46934
46966
  };
46935
46967
  var FormContainer = function(t0) {
46936
- var $ = (0, import_react_compiler_runtime84.c)(4);
46968
+ var $ = (0, import_react_compiler_runtime85.c)(4);
46937
46969
  var children = t0.children, className = t0.className, style = t0.style;
46938
46970
  var t1;
46939
46971
  if ($[0] !== children || $[1] !== className || $[2] !== style) {
46940
- t1 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(import_themes57.Flex, {
46972
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(import_themes57.Flex, {
46941
46973
  direction: "column",
46942
46974
  pl: "5",
46943
46975
  pr: "5",
@@ -46957,21 +46989,21 @@ var FormContainer = function(t0) {
46957
46989
  return t1;
46958
46990
  };
46959
46991
  var Content8 = function(props) {
46960
- var $ = (0, import_react_compiler_runtime84.c)(4);
46992
+ var $ = (0, import_react_compiler_runtime85.c)(4);
46961
46993
  var t0;
46962
46994
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
46963
- t0 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(Messages3, {});
46995
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Messages3, {});
46964
46996
  $[0] = t0;
46965
46997
  } else {
46966
46998
  t0 = $[0];
46967
46999
  }
46968
47000
  var t1;
46969
47001
  if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
46970
- t1 = /* @__PURE__ */ (0, import_jsx_runtime85.jsxs)(Thread.Root, {
47002
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(Thread.Root, {
46971
47003
  children: [
46972
47004
  t0,
46973
- /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(FormContainer, {
46974
- children: /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(Thread.MessageForm, {})
47005
+ /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(FormContainer, {
47006
+ children: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Thread.MessageForm, {})
46975
47007
  })
46976
47008
  ]
46977
47009
  });
@@ -46981,7 +47013,7 @@ var Content8 = function(props) {
46981
47013
  }
46982
47014
  var t2;
46983
47015
  if ($[2] !== props) {
46984
- t2 = /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(Root15, _objectSpread45(_objectSpread45({}, props), {}, {
47016
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Root15, _objectSpread45(_objectSpread45({}, props), {}, {
46985
47017
  children: t1
46986
47018
  }));
46987
47019
  $[2] = props;
@@ -46995,15 +47027,15 @@ Content8.Root = Root15;
46995
47027
  Content8.Messages = Messages3;
46996
47028
  Content8.FormContainer = FormContainer;
46997
47029
  // src/components/threads/ThreadDialog/index.tsx
46998
- var import_jsx_runtime86 = require("react/jsx-runtime");
47030
+ var import_jsx_runtime87 = require("react/jsx-runtime");
46999
47031
  var ThreadDialog = function() {
47000
- var $ = (0, import_react_compiler_runtime85.c)(1);
47032
+ var $ = (0, import_react_compiler_runtime86.c)(1);
47001
47033
  var t0;
47002
47034
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
47003
- t0 = /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(Root13, {
47035
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime87.jsxs)(Root13, {
47004
47036
  children: [
47005
- /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Content8, {}),
47006
- /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Trigger, {})
47037
+ /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(Content8, {}),
47038
+ /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(Trigger, {})
47007
47039
  ]
47008
47040
  });
47009
47041
  $[0] = t0;
@@ -47016,30 +47048,30 @@ ThreadDialog.Root = Root13;
47016
47048
  ThreadDialog.Trigger = Trigger;
47017
47049
  ThreadDialog.Content = Content8;
47018
47050
  // src/components/threads/AudioThreadDialog/index.tsx
47019
- var import_react_compiler_runtime100 = require("react-compiler-runtime");
47051
+ var import_react_compiler_runtime101 = require("react-compiler-runtime");
47020
47052
  // src/components/threads/AudioThread/index.tsx
47021
- var import_react_compiler_runtime99 = require("react-compiler-runtime");
47053
+ var import_react_compiler_runtime100 = require("react-compiler-runtime");
47022
47054
  // src/components/threads/AudioThread/Root/index.tsx
47023
- var import_react_compiler_runtime91 = require("react-compiler-runtime");
47055
+ var import_react_compiler_runtime92 = require("react-compiler-runtime");
47024
47056
  var import_themes58 = require("@radix-ui/themes");
47025
47057
  // src/contexts/threads/AudioThreadContext/index.ts
47026
- var import_react62 = require("react");
47027
- var AudioThreadContext = /* @__PURE__ */ (0, import_react62.createContext)({
47058
+ var import_react63 = require("react");
47059
+ var AudioThreadContext = /* @__PURE__ */ (0, import_react63.createContext)({
47028
47060
  audioRuntime: null
47029
47061
  });
47030
47062
  // src/hooks/threads/useAudioThreadContext/index.ts
47031
- var import_react63 = require("react");
47063
+ var import_react64 = require("react");
47032
47064
  var useAudioThreadContext = function() {
47033
- return (0, import_react63.useContext)(AudioThreadContext);
47065
+ return (0, import_react64.useContext)(AudioThreadContext);
47034
47066
  };
47035
47067
  // src/components/audioRuntimes/TtsAudioRuntimeProvider.tsx
47036
- var import_react_compiler_runtime90 = require("react-compiler-runtime");
47068
+ var import_react_compiler_runtime91 = require("react-compiler-runtime");
47037
47069
  // src/hooks/audioRuntimes/useTtsAudioRuntime/index.ts
47038
- var import_react_compiler_runtime89 = require("react-compiler-runtime");
47039
- var import_react68 = require("react");
47070
+ var import_react_compiler_runtime90 = require("react-compiler-runtime");
47071
+ var import_react69 = require("react");
47040
47072
  // src/hooks/misc/usePermission/index.ts
47041
- var import_react_compiler_runtime86 = require("react-compiler-runtime");
47042
- var import_react64 = require("react");
47073
+ var import_react_compiler_runtime87 = require("react-compiler-runtime");
47074
+ var import_react65 = require("react");
47043
47075
  // src/hooks/misc/usePermission/util.ts
47044
47076
  var noop = function() {};
47045
47077
  function on(obj) {
@@ -47062,8 +47094,8 @@ function off(obj) {
47062
47094
  }
47063
47095
  // src/hooks/misc/usePermission/index.ts
47064
47096
  var usePermission = function(permissionDesc) {
47065
- var $ = (0, import_react_compiler_runtime86.c)(3);
47066
- var _ref = _sliced_to_array((0, import_react64.useState)(""), 2), state = _ref[0], setState = _ref[1];
47097
+ var $ = (0, import_react_compiler_runtime87.c)(3);
47098
+ var _ref = _sliced_to_array((0, import_react65.useState)(""), 2), state = _ref[0], setState = _ref[1];
47067
47099
  var t0;
47068
47100
  var t1;
47069
47101
  if ($[0] !== permissionDesc) {
@@ -47102,20 +47134,20 @@ var usePermission = function(permissionDesc) {
47102
47134
  t0 = $[1];
47103
47135
  t1 = $[2];
47104
47136
  }
47105
- (0, import_react64.useEffect)(t0, t1);
47137
+ (0, import_react65.useEffect)(t0, t1);
47106
47138
  return state;
47107
47139
  };
47108
47140
  // src/hooks/audioThreads/useRecorder/index.ts
47109
47141
  var import_dayjs3 = __toESM(require("dayjs"), 1);
47110
47142
  var import_use_audio_capture = require("@supercorp/use-audio-capture");
47111
- var import_react66 = require("react");
47143
+ var import_react67 = require("react");
47112
47144
  var import_react_use_audio_player = require("react-use-audio-player");
47113
47145
  // src/hooks/misc/useInterval.ts
47114
- var import_react_compiler_runtime87 = require("react-compiler-runtime");
47115
- var import_react65 = require("react");
47146
+ var import_react_compiler_runtime88 = require("react-compiler-runtime");
47147
+ var import_react66 = require("react");
47116
47148
  var useInterval = function(callback, delay) {
47117
- var $ = (0, import_react_compiler_runtime87.c)(5);
47118
- var savedCallback = (0, import_react65.useRef)(_temp8);
47149
+ var $ = (0, import_react_compiler_runtime88.c)(5);
47150
+ var savedCallback = (0, import_react66.useRef)(_temp8);
47119
47151
  var t0;
47120
47152
  if ($[0] !== callback) {
47121
47153
  t0 = function() {
@@ -47126,7 +47158,7 @@ var useInterval = function(callback, delay) {
47126
47158
  } else {
47127
47159
  t0 = $[1];
47128
47160
  }
47129
- (0, import_react65.useEffect)(t0);
47161
+ (0, import_react66.useEffect)(t0);
47130
47162
  var t1;
47131
47163
  var t2;
47132
47164
  if ($[2] !== delay) {
@@ -47150,7 +47182,7 @@ var useInterval = function(callback, delay) {
47150
47182
  t1 = $[3];
47151
47183
  t2 = $[4];
47152
47184
  }
47153
- (0, import_react65.useEffect)(t1, t2);
47185
+ (0, import_react66.useEffect)(t1, t2);
47154
47186
  };
47155
47187
  function _temp8() {}
47156
47188
  // src/hooks/audioThreads/useRecorder/index.ts
@@ -47222,14 +47254,14 @@ function _asyncToGenerator10(n) {
47222
47254
  }
47223
47255
  var useRecorder = function(_ref) {
47224
47256
  var isStopOnSilence = _ref.isStopOnSilence, _onStart = _ref.onStart, _onStop = _ref.onStop;
47225
- var _$_ref = _sliced_to_array((0, import_react66.useState)(null), 2), silenceStart = _$_ref[0], setSilenceStart = _$_ref[1];
47226
- var _$_ref1 = _sliced_to_array((0, import_react66.useState)(null), 2), noiseStart = _$_ref1[0], setNoiseStart = _$_ref1[1];
47227
- var _$_ref2 = _sliced_to_array((0, import_react66.useState)(null), 2), mediaStream = _$_ref2[0], setMediaStream = _$_ref2[1];
47228
- var _$_ref3 = _sliced_to_array((0, import_react66.useState)("idle"), 2), status = _$_ref3[0], setStatus = _$_ref3[1];
47257
+ var _$_ref = _sliced_to_array((0, import_react67.useState)(null), 2), silenceStart = _$_ref[0], setSilenceStart = _$_ref[1];
47258
+ var _$_ref1 = _sliced_to_array((0, import_react67.useState)(null), 2), noiseStart = _$_ref1[0], setNoiseStart = _$_ref1[1];
47259
+ var _$_ref2 = _sliced_to_array((0, import_react67.useState)(null), 2), mediaStream = _$_ref2[0], setMediaStream = _$_ref2[1];
47260
+ var _$_ref3 = _sliced_to_array((0, import_react67.useState)("idle"), 2), status = _$_ref3[0], setStatus = _$_ref3[1];
47229
47261
  var startAudioPlayer = (0, import_react_use_audio_player.useAudioPlayer)();
47230
47262
  var endAudioPlayer = (0, import_react_use_audio_player.useAudioPlayer)();
47231
- var _$_ref4 = _sliced_to_array((0, import_react66.useState)(false), 2), isLoaded = _$_ref4[0], setIsLoaded = _$_ref4[1];
47232
- (0, import_react66.useEffect)(function() {
47263
+ var _$_ref4 = _sliced_to_array((0, import_react67.useState)(false), 2), isLoaded = _$_ref4[0], setIsLoaded = _$_ref4[1];
47264
+ (0, import_react67.useEffect)(function() {
47233
47265
  if (isLoaded) return;
47234
47266
  setIsLoaded(true);
47235
47267
  }, [
@@ -47289,9 +47321,9 @@ var useRecorder = function(_ref) {
47289
47321
  setNoiseStart(null);
47290
47322
  }
47291
47323
  });
47292
- var _$_ref5 = _sliced_to_array((0, import_react66.useState)(null), 2), audioEngine = _$_ref5[0], setAudioEngine = _$_ref5[1];
47293
- var isInited = (0, import_react66.useRef)(false);
47294
- (0, import_react66.useEffect)(function() {
47324
+ var _$_ref5 = _sliced_to_array((0, import_react67.useState)(null), 2), audioEngine = _$_ref5[0], setAudioEngine = _$_ref5[1];
47325
+ var isInited = (0, import_react67.useRef)(false);
47326
+ (0, import_react67.useEffect)(function() {
47295
47327
  if (!mediaStream) return;
47296
47328
  if (isInited.current) return;
47297
47329
  isInited.current = true;
@@ -47304,7 +47336,7 @@ var useRecorder = function(_ref) {
47304
47336
  isInited,
47305
47337
  mediaStream
47306
47338
  ]);
47307
- var visualizationAnalyser = (0, import_react66.useMemo)(function() {
47339
+ var visualizationAnalyser = (0, import_react67.useMemo)(function() {
47308
47340
  if (!audioEngine) return null;
47309
47341
  var result = audioEngine.audioContext.createAnalyser();
47310
47342
  audioEngine.source.connect(result);
@@ -47312,7 +47344,7 @@ var useRecorder = function(_ref) {
47312
47344
  }, [
47313
47345
  audioEngine
47314
47346
  ]);
47315
- var silenceAnalyser = (0, import_react66.useMemo)(function() {
47347
+ var silenceAnalyser = (0, import_react67.useMemo)(function() {
47316
47348
  if (!audioEngine) return null;
47317
47349
  var result_0 = audioEngine.audioContext.createAnalyser();
47318
47350
  result_0.minDecibels = -60;
@@ -47321,7 +47353,7 @@ var useRecorder = function(_ref) {
47321
47353
  }, [
47322
47354
  audioEngine
47323
47355
  ]);
47324
- var handleSilence = (0, import_react66.useCallback)(function() {
47356
+ var handleSilence = (0, import_react67.useCallback)(function() {
47325
47357
  if (!silenceAnalyser) return;
47326
47358
  var frequencyData = new Uint8Array(silenceAnalyser.frequencyBinCount);
47327
47359
  silenceAnalyser.getByteFrequencyData(frequencyData);
@@ -47344,7 +47376,7 @@ var useRecorder = function(_ref) {
47344
47376
  setNoiseStart,
47345
47377
  setSilenceStart
47346
47378
  ]);
47347
- (0, import_react66.useEffect)(function() {
47379
+ (0, import_react67.useEffect)(function() {
47348
47380
  if (!isStopOnSilence) return;
47349
47381
  requestAnimationFrame(function() {
47350
47382
  return handleSilence();
@@ -47367,8 +47399,8 @@ var useRecorder = function(_ref) {
47367
47399
  });
47368
47400
  };
47369
47401
  // src/hooks/audioThreads/useMessageAudio/index.ts
47370
- var import_react_compiler_runtime88 = require("react-compiler-runtime");
47371
- var import_react67 = require("react");
47402
+ var import_react_compiler_runtime89 = require("react-compiler-runtime");
47403
+ var import_react68 = require("react");
47372
47404
  var import_compromise = __toESM(require("compromise"), 1);
47373
47405
  var import_howler = require("howler");
47374
47406
  var import_react_use_audio_player2 = require("react-use-audio-player");
@@ -47449,7 +47481,7 @@ var getMessageSentences = function(_ref) {
47449
47481
  };
47450
47482
  var useMessageAudio = function(t0) {
47451
47483
  var _latestMessageProps$l, _latestMessageProps$l4, _latestMessageProps$l5;
47452
- var $ = (0, import_react_compiler_runtime88.c)(68);
47484
+ var $ = (0, import_react_compiler_runtime89.c)(68);
47453
47485
  var _onEnd = t0.onEnd, passedPlay = t0.play, t1 = t0.fullSentenceRegex;
47454
47486
  var t2;
47455
47487
  if ($[0] !== t1) {
@@ -47460,7 +47492,7 @@ var useMessageAudio = function(t0) {
47460
47492
  t2 = $[1];
47461
47493
  }
47462
47494
  var fullSentenceRegex = t2;
47463
- var _ref = _sliced_to_array((0, import_react67.useState)(false), 2), isAudioPlayed = _ref[0], setIsAudioPlayed = _ref[1];
47495
+ var _ref = _sliced_to_array((0, import_react68.useState)(false), 2), isAudioPlayed = _ref[0], setIsAudioPlayed = _ref[1];
47464
47496
  var t3;
47465
47497
  if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
47466
47498
  t3 = [];
@@ -47468,7 +47500,7 @@ var useMessageAudio = function(t0) {
47468
47500
  } else {
47469
47501
  t3 = $[2];
47470
47502
  }
47471
- var _ref1 = _sliced_to_array((0, import_react67.useState)(t3), 2), stoppedMessageIds = _ref1[0], setStoppedMessageIds = _ref1[1];
47503
+ var _ref1 = _sliced_to_array((0, import_react68.useState)(t3), 2), stoppedMessageIds = _ref1[0], setStoppedMessageIds = _ref1[1];
47472
47504
  var t4;
47473
47505
  if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
47474
47506
  t4 = [];
@@ -47476,12 +47508,12 @@ var useMessageAudio = function(t0) {
47476
47508
  } else {
47477
47509
  t4 = $[3];
47478
47510
  }
47479
- var _ref2 = _sliced_to_array((0, import_react67.useState)(t4), 2), playedMessageSentences = _ref2[0], setPlayedMessageSentences = _ref2[1];
47511
+ var _ref2 = _sliced_to_array((0, import_react68.useState)(t4), 2), playedMessageSentences = _ref2[0], setPlayedMessageSentences = _ref2[1];
47480
47512
  var audioPlayer = (0, import_react_use_audio_player2.useAudioPlayer)();
47481
47513
  var nextAudioPlayer = (0, import_react_use_audio_player2.useAudioPlayer)();
47482
47514
  var superinterfaceContext = useSuperinterfaceContext();
47483
- var _ref3 = _sliced_to_array((0, import_react67.useState)(false), 2), isPlaying = _ref3[0], setIsPlaying = _ref3[1];
47484
- var isLastSentencePlayedRef = (0, import_react67.useRef)(false);
47515
+ var _ref3 = _sliced_to_array((0, import_react68.useState)(false), 2), isPlaying = _ref3[0], setIsPlaying = _ref3[1];
47516
+ var isLastSentencePlayedRef = (0, import_react68.useRef)(false);
47485
47517
  var latestMessageProps = useLatestMessage();
47486
47518
  var t5;
47487
47519
  var t6;
@@ -47502,7 +47534,7 @@ var useMessageAudio = function(t0) {
47502
47534
  t5 = $[5];
47503
47535
  t6 = $[6];
47504
47536
  }
47505
- (0, import_react67.useEffect)(t5, t6);
47537
+ (0, import_react68.useEffect)(t5, t6);
47506
47538
  var t7;
47507
47539
  bb0: {
47508
47540
  if (!latestMessageProps.latestMessage) {
@@ -47725,7 +47757,7 @@ var useMessageAudio = function(t0) {
47725
47757
  } else {
47726
47758
  t11 = $[43];
47727
47759
  }
47728
- (0, import_react67.useEffect)(t10, t11);
47760
+ (0, import_react68.useEffect)(t10, t11);
47729
47761
  var t12;
47730
47762
  if ($[44] !== isPlaying || $[45] !== ((_latestMessageProps$l = latestMessageProps.latestMessage) === null || _latestMessageProps$l === void 0 ? void 0 : _latestMessageProps$l.status) || $[46] !== _onEnd || $[47] !== unplayedMessageSentences.length) {
47731
47763
  var _latestMessageProps$l3;
@@ -47761,7 +47793,7 @@ var useMessageAudio = function(t0) {
47761
47793
  } else {
47762
47794
  t14 = $[53];
47763
47795
  }
47764
- (0, import_react67.useEffect)(t12, t14);
47796
+ (0, import_react68.useEffect)(t12, t14);
47765
47797
  var t15;
47766
47798
  if ($[54] !== audioPlayer) {
47767
47799
  t15 = [
@@ -47772,9 +47804,9 @@ var useMessageAudio = function(t0) {
47772
47804
  } else {
47773
47805
  t15 = $[55];
47774
47806
  }
47775
- (0, import_react67.useEffect)(_temp9, t15);
47776
- var _ref4 = _sliced_to_array((0, import_react67.useState)(null), 2), audioEngine = _ref4[0], setAudioEngine = _ref4[1];
47777
- var isAudioEngineInited = (0, import_react67.useRef)(false);
47807
+ (0, import_react68.useEffect)(_temp9, t15);
47808
+ var _ref4 = _sliced_to_array((0, import_react68.useState)(null), 2), audioEngine = _ref4[0], setAudioEngine = _ref4[1];
47809
+ var isAudioEngineInited = (0, import_react68.useRef)(false);
47778
47810
  var t16;
47779
47811
  if ($[56] !== audioPlayer.playing) {
47780
47812
  t16 = function() {
@@ -47814,7 +47846,7 @@ var useMessageAudio = function(t0) {
47814
47846
  } else {
47815
47847
  t17 = $[59];
47816
47848
  }
47817
- (0, import_react67.useEffect)(t16, t17);
47849
+ (0, import_react68.useEffect)(t16, t17);
47818
47850
  var t18;
47819
47851
  bb1: {
47820
47852
  if (!audioEngine) {
@@ -47902,7 +47934,7 @@ function _asyncToGenerator11(n) {
47902
47934
  };
47903
47935
  }
47904
47936
  var useTtsAudioRuntime = function(t0) {
47905
- var $ = (0, import_react_compiler_runtime89.c)(30);
47937
+ var $ = (0, import_react_compiler_runtime90.c)(30);
47906
47938
  var play = t0.play, passedOnEnd = t0.onEnd;
47907
47939
  var addToast = useToasts().addToast;
47908
47940
  var queryClient = (0, import_react_query10.useQueryClient)();
@@ -48086,9 +48118,9 @@ function _temp24() {
48086
48118
  return _temp24.apply(this, arguments);
48087
48119
  }
48088
48120
  // src/components/audioRuntimes/TtsAudioRuntimeProvider.tsx
48089
- var import_jsx_runtime87 = require("react/jsx-runtime");
48121
+ var import_jsx_runtime88 = require("react/jsx-runtime");
48090
48122
  var TtsAudioRuntimeProvider = function(t0) {
48091
- var $ = (0, import_react_compiler_runtime90.c)(8);
48123
+ var $ = (0, import_react_compiler_runtime91.c)(8);
48092
48124
  var children = t0.children, play = t0.play, onEnd = t0.onEnd;
48093
48125
  var t1;
48094
48126
  if ($[0] !== onEnd || $[1] !== play) {
@@ -48115,7 +48147,7 @@ var TtsAudioRuntimeProvider = function(t0) {
48115
48147
  }
48116
48148
  var t3;
48117
48149
  if ($[5] !== children || $[6] !== t2) {
48118
- t3 = /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(AudioThreadContext.Provider, {
48150
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(AudioThreadContext.Provider, {
48119
48151
  value: t2,
48120
48152
  children: children
48121
48153
  });
@@ -48128,7 +48160,7 @@ var TtsAudioRuntimeProvider = function(t0) {
48128
48160
  return t3;
48129
48161
  };
48130
48162
  // src/components/threads/AudioThread/Root/index.tsx
48131
- var import_jsx_runtime88 = require("react/jsx-runtime");
48163
+ var import_jsx_runtime89 = require("react/jsx-runtime");
48132
48164
  var _excluded5 = [
48133
48165
  "children"
48134
48166
  ];
@@ -48201,11 +48233,11 @@ function _objectWithoutPropertiesLoose5(r, e) {
48201
48233
  return t;
48202
48234
  }
48203
48235
  var Content9 = function(t0) {
48204
- var $ = (0, import_react_compiler_runtime91.c)(4);
48236
+ var $ = (0, import_react_compiler_runtime92.c)(4);
48205
48237
  var children = t0.children, className = t0.className, style = t0.style;
48206
48238
  var t1;
48207
48239
  if ($[0] !== children || $[1] !== className || $[2] !== style) {
48208
- t1 = /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(import_themes58.Flex, {
48240
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(import_themes58.Flex, {
48209
48241
  direction: "column",
48210
48242
  flexGrow: "1",
48211
48243
  p: "9",
@@ -48223,7 +48255,7 @@ var Content9 = function(t0) {
48223
48255
  return t1;
48224
48256
  };
48225
48257
  var AudioRuntimeProvider = function(t0) {
48226
- var $ = (0, import_react_compiler_runtime91.c)(4);
48258
+ var $ = (0, import_react_compiler_runtime92.c)(4);
48227
48259
  var children = t0.children, play = t0.play, onEnd = t0.onEnd;
48228
48260
  var audioThreadContext = useAudioThreadContext();
48229
48261
  if (audioThreadContext.audioRuntime) {
@@ -48231,7 +48263,7 @@ var AudioRuntimeProvider = function(t0) {
48231
48263
  }
48232
48264
  var t1;
48233
48265
  if ($[0] !== children || $[1] !== onEnd || $[2] !== play) {
48234
- t1 = /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(TtsAudioRuntimeProvider, {
48266
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(TtsAudioRuntimeProvider, {
48235
48267
  play: play,
48236
48268
  onEnd: onEnd,
48237
48269
  children: children
@@ -48246,7 +48278,7 @@ var AudioRuntimeProvider = function(t0) {
48246
48278
  return t1;
48247
48279
  };
48248
48280
  var Provider5 = function(t0) {
48249
- var $ = (0, import_react_compiler_runtime91.c)(9);
48281
+ var $ = (0, import_react_compiler_runtime92.c)(9);
48250
48282
  var children;
48251
48283
  var rest;
48252
48284
  if ($[0] !== t0) {
@@ -48273,7 +48305,7 @@ var Provider5 = function(t0) {
48273
48305
  }
48274
48306
  var t2;
48275
48307
  if ($[6] !== children || $[7] !== t1) {
48276
- t2 = /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(AudioThreadContext.Provider, {
48308
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(AudioThreadContext.Provider, {
48277
48309
  value: t1,
48278
48310
  children: children
48279
48311
  });
@@ -48286,7 +48318,7 @@ var Provider5 = function(t0) {
48286
48318
  return t2;
48287
48319
  };
48288
48320
  var Root16 = function(t0) {
48289
- var $ = (0, import_react_compiler_runtime91.c)(18);
48321
+ var $ = (0, import_react_compiler_runtime92.c)(18);
48290
48322
  var children;
48291
48323
  var className;
48292
48324
  var onEnd;
@@ -48316,8 +48348,8 @@ var Root16 = function(t0) {
48316
48348
  }
48317
48349
  var t1;
48318
48350
  if ($[7] !== children || $[8] !== className || $[9] !== style) {
48319
- t1 = /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(ToastsProvider, {
48320
- children: /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(Content9, {
48351
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(ToastsProvider, {
48352
+ children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(Content9, {
48321
48353
  className: className,
48322
48354
  style: style,
48323
48355
  children: children
@@ -48332,7 +48364,7 @@ var Root16 = function(t0) {
48332
48364
  }
48333
48365
  var t2;
48334
48366
  if ($[11] !== onEnd || $[12] !== play || $[13] !== t1) {
48335
- t2 = /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(AudioRuntimeProvider, {
48367
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(AudioRuntimeProvider, {
48336
48368
  play: play,
48337
48369
  onEnd: onEnd,
48338
48370
  children: t1
@@ -48346,7 +48378,7 @@ var Root16 = function(t0) {
48346
48378
  }
48347
48379
  var t3;
48348
48380
  if ($[15] !== rest || $[16] !== t2) {
48349
- t3 = /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(Provider5, _objectSpread48(_objectSpread48({}, rest), {}, {
48381
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(Provider5, _objectSpread48(_objectSpread48({}, rest), {}, {
48350
48382
  children: t2
48351
48383
  }));
48352
48384
  $[15] = rest;
@@ -48358,21 +48390,21 @@ var Root16 = function(t0) {
48358
48390
  return t3;
48359
48391
  };
48360
48392
  // src/components/threads/AudioThread/Visualization/index.tsx
48361
- var import_react_compiler_runtime93 = require("react-compiler-runtime");
48362
- var import_react71 = require("react");
48393
+ var import_react_compiler_runtime94 = require("react-compiler-runtime");
48394
+ var import_react72 = require("react");
48363
48395
  var import_lodash9 = __toESM(require("lodash"), 1);
48364
48396
  var import_themes60 = require("@radix-ui/themes");
48365
48397
  // src/components/threads/AudioThread/BarsVisualizer/index.tsx
48366
48398
  var import_lodash8 = __toESM(require("lodash"), 1);
48367
48399
  var import_themes59 = require("@radix-ui/themes");
48368
- var import_react69 = require("react");
48400
+ var import_react70 = require("react");
48369
48401
  var import_radash17 = require("radash");
48370
- var import_jsx_runtime89 = require("react/jsx-runtime");
48402
+ var import_jsx_runtime90 = require("react/jsx-runtime");
48371
48403
  var barCount = 4;
48372
48404
  var BarsVisualizer = function(_ref) {
48373
48405
  var visualizationAnalyser = _ref.visualizationAnalyser, backgroundColor = _ref.backgroundColor, height = _ref.height, barWidth = _ref.barWidth;
48374
- var _$_ref = _sliced_to_array((0, import_react69.useState)([]), 2), barHeights = _$_ref[0], setBarHeights = _$_ref[1];
48375
- var draw = (0, import_react69.useCallback)(function(_ref2) {
48406
+ var _$_ref = _sliced_to_array((0, import_react70.useState)([]), 2), barHeights = _$_ref[0], setBarHeights = _$_ref[1];
48407
+ var draw = (0, import_react70.useCallback)(function(_ref2) {
48376
48408
  var visualizationAnalyser_0 = _ref2.visualizationAnalyser;
48377
48409
  if (!visualizationAnalyser_0) {
48378
48410
  setBarHeights(Array(barCount).fill(0));
@@ -48390,7 +48422,7 @@ var BarsVisualizer = function(_ref) {
48390
48422
  });
48391
48423
  });
48392
48424
  }, []);
48393
- (0, import_react69.useEffect)(function() {
48425
+ (0, import_react70.useEffect)(function() {
48394
48426
  draw({
48395
48427
  visualizationAnalyser: visualizationAnalyser
48396
48428
  });
@@ -48398,7 +48430,7 @@ var BarsVisualizer = function(_ref) {
48398
48430
  draw,
48399
48431
  visualizationAnalyser
48400
48432
  ]);
48401
- return /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(import_themes59.Grid, {
48433
+ return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_themes59.Grid, {
48402
48434
  columns: "".concat(barCount),
48403
48435
  gap: "1",
48404
48436
  width: "auto",
@@ -48407,12 +48439,12 @@ var BarsVisualizer = function(_ref) {
48407
48439
  gridTemplateColumns: "repeat(4, minmax(0, 1fr))"
48408
48440
  },
48409
48441
  children: barHeights.map(function(barHeight, index) {
48410
- return /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(import_themes59.Flex, {
48442
+ return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_themes59.Flex, {
48411
48443
  direction: "column",
48412
48444
  align: "center",
48413
48445
  justify: "center",
48414
48446
  height: height,
48415
- children: /* @__PURE__ */ (0, import_jsx_runtime89.jsx)(import_themes59.Flex, {
48447
+ children: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_themes59.Flex, {
48416
48448
  minHeight: "50%",
48417
48449
  maxHeight: "100%",
48418
48450
  height: "".concat(barHeight + 20, "%"),
@@ -48427,10 +48459,10 @@ var BarsVisualizer = function(_ref) {
48427
48459
  });
48428
48460
  };
48429
48461
  // src/hooks/audioThreads/useStatus/index.ts
48430
- var import_react_compiler_runtime92 = require("react-compiler-runtime");
48431
- var import_react70 = require("react");
48462
+ var import_react_compiler_runtime93 = require("react-compiler-runtime");
48463
+ var import_react71 = require("react");
48432
48464
  var useStatus = function() {
48433
- var $ = (0, import_react_compiler_runtime92.c)(2);
48465
+ var $ = (0, import_react_compiler_runtime93.c)(2);
48434
48466
  var audioRuntime = useAudioThreadContext().audioRuntime;
48435
48467
  var t0;
48436
48468
  bb0: {
@@ -48478,7 +48510,7 @@ var useStatus = function() {
48478
48510
  return t1;
48479
48511
  };
48480
48512
  // src/components/threads/AudioThread/Visualization/index.tsx
48481
- var import_jsx_runtime90 = require("react/jsx-runtime");
48513
+ var import_jsx_runtime91 = require("react/jsx-runtime");
48482
48514
  var _excluded6 = [
48483
48515
  "children"
48484
48516
  ];
@@ -48552,14 +48584,14 @@ function _objectWithoutPropertiesLoose6(r, e) {
48552
48584
  }
48553
48585
  return t;
48554
48586
  }
48555
- var AudioThreadVisualizationContext = /* @__PURE__ */ (0, import_react71.createContext)({
48587
+ var AudioThreadVisualizationContext = /* @__PURE__ */ (0, import_react72.createContext)({
48556
48588
  scale: 0
48557
48589
  });
48558
48590
  var Provider6 = function(_ref) {
48559
48591
  var children = _ref.children;
48560
48592
  var audioThreadContext = useAudioThreadContext();
48561
- var _$_ref = _sliced_to_array((0, import_react71.useState)(0), 2), scale = _$_ref[0], setScale = _$_ref[1];
48562
- var draw = (0, import_react71.useCallback)(function(_ref2) {
48593
+ var _$_ref = _sliced_to_array((0, import_react72.useState)(0), 2), scale = _$_ref[0], setScale = _$_ref[1];
48594
+ var draw = (0, import_react72.useCallback)(function(_ref2) {
48563
48595
  var visualizationAnalyser = _ref2.visualizationAnalyser;
48564
48596
  if (!visualizationAnalyser) {
48565
48597
  setScale(1);
@@ -48574,7 +48606,7 @@ var Provider6 = function(_ref) {
48574
48606
  });
48575
48607
  });
48576
48608
  }, []);
48577
- (0, import_react71.useEffect)(function() {
48609
+ (0, import_react72.useEffect)(function() {
48578
48610
  draw({
48579
48611
  visualizationAnalyser: audioThreadContext.audioRuntime.user.visualizationAnalyser
48580
48612
  });
@@ -48582,7 +48614,7 @@ var Provider6 = function(_ref) {
48582
48614
  draw,
48583
48615
  audioThreadContext
48584
48616
  ]);
48585
- return /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(AudioThreadVisualizationContext.Provider, {
48617
+ return /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(AudioThreadVisualizationContext.Provider, {
48586
48618
  value: {
48587
48619
  scale: scale
48588
48620
  },
@@ -48590,7 +48622,7 @@ var Provider6 = function(_ref) {
48590
48622
  });
48591
48623
  };
48592
48624
  var Root17 = function(t0) {
48593
- var $ = (0, import_react_compiler_runtime93.c)(6);
48625
+ var $ = (0, import_react_compiler_runtime94.c)(6);
48594
48626
  var children;
48595
48627
  var rest;
48596
48628
  if ($[0] !== t0) {
@@ -48607,8 +48639,8 @@ var Root17 = function(t0) {
48607
48639
  }
48608
48640
  var t1;
48609
48641
  if ($[3] !== children || $[4] !== rest) {
48610
- t1 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(Provider6, {
48611
- children: /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_themes60.Flex, _objectSpread49(_objectSpread49({
48642
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(Provider6, {
48643
+ children: /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_themes60.Flex, _objectSpread49(_objectSpread49({
48612
48644
  direction: "column",
48613
48645
  align: "center",
48614
48646
  justify: "center",
@@ -48627,7 +48659,7 @@ var Root17 = function(t0) {
48627
48659
  return t1;
48628
48660
  };
48629
48661
  var BarsVisualizer2 = function(t0) {
48630
- var $ = (0, import_react_compiler_runtime93.c)(10);
48662
+ var $ = (0, import_react_compiler_runtime94.c)(10);
48631
48663
  var rest;
48632
48664
  var t1;
48633
48665
  var t2;
@@ -48653,7 +48685,7 @@ var BarsVisualizer2 = function(t0) {
48653
48685
  var t3 = status === "playing" ? "var(--accent-11)" : "var(--gray-11)";
48654
48686
  var t4;
48655
48687
  if ($[4] !== audioThreadContext.audioRuntime.assistant.visualizationAnalyser || $[5] !== barWidth || $[6] !== height || $[7] !== rest || $[8] !== t3) {
48656
- t4 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(BarsVisualizer, _objectSpread49({
48688
+ t4 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(BarsVisualizer, _objectSpread49({
48657
48689
  visualizationAnalyser: audioThreadContext.audioRuntime.assistant.visualizationAnalyser,
48658
48690
  backgroundColor: t3,
48659
48691
  height: height,
@@ -48671,7 +48703,7 @@ var BarsVisualizer2 = function(t0) {
48671
48703
  return t4;
48672
48704
  };
48673
48705
  var AssistantVisualizationRoot = function(t0) {
48674
- var $ = (0, import_react_compiler_runtime93.c)(17);
48706
+ var $ = (0, import_react_compiler_runtime94.c)(17);
48675
48707
  var children;
48676
48708
  var rest;
48677
48709
  var t1;
@@ -48696,7 +48728,7 @@ var AssistantVisualizationRoot = function(t0) {
48696
48728
  var height = t1 === void 0 ? "200px" : t1;
48697
48729
  var width2 = t2 === void 0 ? "200px" : t2;
48698
48730
  var status = useStatus().status;
48699
- var scale = (0, import_react71.useContext)(AudioThreadVisualizationContext).scale;
48731
+ var scale = (0, import_react72.useContext)(AudioThreadVisualizationContext).scale;
48700
48732
  var t3 = status === "playing" ? "var(--accent-4)" : "var(--gray-4)";
48701
48733
  var t4;
48702
48734
  if ($[5] !== rest.style) {
@@ -48723,7 +48755,7 @@ var AssistantVisualizationRoot = function(t0) {
48723
48755
  }
48724
48756
  var t6;
48725
48757
  if ($[11] !== children || $[12] !== height || $[13] !== rest || $[14] !== t5 || $[15] !== width2) {
48726
- t6 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(import_themes60.Flex, _objectSpread49(_objectSpread49({
48758
+ t6 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_themes60.Flex, _objectSpread49(_objectSpread49({
48727
48759
  align: "center",
48728
48760
  justify: "center",
48729
48761
  height: height,
@@ -48744,17 +48776,17 @@ var AssistantVisualizationRoot = function(t0) {
48744
48776
  return t6;
48745
48777
  };
48746
48778
  var AssistantVisualization = function(props) {
48747
- var $ = (0, import_react_compiler_runtime93.c)(3);
48779
+ var $ = (0, import_react_compiler_runtime94.c)(3);
48748
48780
  var t0;
48749
48781
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
48750
- t0 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(BarsVisualizer2, {});
48782
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(BarsVisualizer2, {});
48751
48783
  $[0] = t0;
48752
48784
  } else {
48753
48785
  t0 = $[0];
48754
48786
  }
48755
48787
  var t1;
48756
48788
  if ($[1] !== props) {
48757
- t1 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(AssistantVisualizationRoot, _objectSpread49(_objectSpread49({}, props), {}, {
48789
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(AssistantVisualizationRoot, _objectSpread49(_objectSpread49({}, props), {}, {
48758
48790
  children: t0
48759
48791
  }));
48760
48792
  $[1] = props;
@@ -48767,18 +48799,18 @@ var AssistantVisualization = function(props) {
48767
48799
  AssistantVisualization.Root = AssistantVisualizationRoot;
48768
48800
  AssistantVisualization.BarsVisualizer = BarsVisualizer2;
48769
48801
  var AssistantInfo = function(props) {
48770
- var $ = (0, import_react_compiler_runtime93.c)(6);
48771
- var assistantNameContext = (0, import_react71.useContext)(AssistantNameContext);
48802
+ var $ = (0, import_react_compiler_runtime94.c)(6);
48803
+ var assistantNameContext = (0, import_react72.useContext)(AssistantNameContext);
48772
48804
  var t0;
48773
48805
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
48774
- t0 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(MessageGroup.AssistantAvatar, {});
48806
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(MessageGroup.AssistantAvatar, {});
48775
48807
  $[0] = t0;
48776
48808
  } else {
48777
48809
  t0 = $[0];
48778
48810
  }
48779
48811
  var t1;
48780
48812
  if ($[1] !== assistantNameContext) {
48781
- t1 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(MessageGroup.Name, {
48813
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(MessageGroup.Name, {
48782
48814
  children: assistantNameContext
48783
48815
  });
48784
48816
  $[1] = assistantNameContext;
@@ -48788,7 +48820,7 @@ var AssistantInfo = function(props) {
48788
48820
  }
48789
48821
  var t2;
48790
48822
  if ($[3] !== props || $[4] !== t1) {
48791
- t2 = /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)(import_themes60.Flex, _objectSpread49(_objectSpread49({
48823
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)(import_themes60.Flex, _objectSpread49(_objectSpread49({
48792
48824
  ml: "-22.5px",
48793
48825
  gap: "3",
48794
48826
  pt: "5"
@@ -48807,12 +48839,12 @@ var AssistantInfo = function(props) {
48807
48839
  return t2;
48808
48840
  };
48809
48841
  var Visualization = function(props) {
48810
- var $ = (0, import_react_compiler_runtime93.c)(4);
48842
+ var $ = (0, import_react_compiler_runtime94.c)(4);
48811
48843
  var t0;
48812
48844
  var t1;
48813
48845
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
48814
- t0 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(AssistantVisualization, {});
48815
- t1 = /* @__PURE__ */ (0, import_jsx_runtime90.jsx)(AssistantInfo, {});
48846
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(AssistantVisualization, {});
48847
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(AssistantInfo, {});
48816
48848
  $[0] = t0;
48817
48849
  $[1] = t1;
48818
48850
  } else {
@@ -48821,7 +48853,7 @@ var Visualization = function(props) {
48821
48853
  }
48822
48854
  var t2;
48823
48855
  if ($[2] !== props) {
48824
- t2 = /* @__PURE__ */ (0, import_jsx_runtime90.jsxs)(Root17, _objectSpread49(_objectSpread49({}, props), {}, {
48856
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)(Root17, _objectSpread49(_objectSpread49({}, props), {}, {
48825
48857
  children: [
48826
48858
  t0,
48827
48859
  t1
@@ -48839,11 +48871,11 @@ Visualization.Provider = Provider6;
48839
48871
  Visualization.AssistantVisualization = AssistantVisualization;
48840
48872
  Visualization.AssistantInfo = AssistantInfo;
48841
48873
  // src/components/threads/AudioThread/Status/index.tsx
48842
- var import_react_compiler_runtime95 = require("react-compiler-runtime");
48874
+ var import_react_compiler_runtime96 = require("react-compiler-runtime");
48843
48875
  // src/components/threads/AudioThread/Status/StatusMessages.tsx
48844
- var import_react_compiler_runtime94 = require("react-compiler-runtime");
48876
+ var import_react_compiler_runtime95 = require("react-compiler-runtime");
48845
48877
  var import_themes61 = require("@radix-ui/themes");
48846
- var import_jsx_runtime91 = require("react/jsx-runtime");
48878
+ var import_jsx_runtime92 = require("react/jsx-runtime");
48847
48879
  var html = function(_ref) {
48848
48880
  var texts = _ref.texts;
48849
48881
  return "\n .status-messages-texts:after {\n content: '".concat(texts[0], "';\n animation: texts ").concat(texts.length * 5, "s linear infinite;\n }\n\n @keyframes texts {\n ").concat(texts.map(function(_10, i) {
@@ -48851,11 +48883,11 @@ var html = function(_ref) {
48851
48883
  }).join(""), "\n }");
48852
48884
  };
48853
48885
  var StatusMessages = function(t0) {
48854
- var $ = (0, import_react_compiler_runtime94.c)(9);
48886
+ var $ = (0, import_react_compiler_runtime95.c)(9);
48855
48887
  var texts = t0.texts, className = t0.className, style = t0.style;
48856
48888
  var t1;
48857
48889
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
48858
- t1 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)(import_themes61.Text, {
48890
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(import_themes61.Text, {
48859
48891
  size: "2",
48860
48892
  weight: "regular",
48861
48893
  color: "gray",
@@ -48878,7 +48910,7 @@ var StatusMessages = function(t0) {
48878
48910
  }
48879
48911
  var t3;
48880
48912
  if ($[3] !== t2) {
48881
- t3 = /* @__PURE__ */ (0, import_jsx_runtime91.jsx)("style", {
48913
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime92.jsx)("style", {
48882
48914
  dangerouslySetInnerHTML: {
48883
48915
  __html: t2
48884
48916
  }
@@ -48890,7 +48922,7 @@ var StatusMessages = function(t0) {
48890
48922
  }
48891
48923
  var t4;
48892
48924
  if ($[5] !== className || $[6] !== style || $[7] !== t3) {
48893
- t4 = /* @__PURE__ */ (0, import_jsx_runtime91.jsxs)(import_themes61.Flex, {
48925
+ t4 = /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(import_themes61.Flex, {
48894
48926
  justify: "center",
48895
48927
  pb: "5",
48896
48928
  className: className,
@@ -48910,7 +48942,7 @@ var StatusMessages = function(t0) {
48910
48942
  return t4;
48911
48943
  };
48912
48944
  // src/components/threads/AudioThread/Status/index.tsx
48913
- var import_jsx_runtime92 = require("react/jsx-runtime");
48945
+ var import_jsx_runtime93 = require("react/jsx-runtime");
48914
48946
  function ownKeys50(e, r) {
48915
48947
  var t = Object.keys(e);
48916
48948
  if (Object.getOwnPropertySymbols) {
@@ -48955,7 +48987,7 @@ function _toPrimitive50(t, r) {
48955
48987
  return ("string" === r ? String : Number)(t);
48956
48988
  }
48957
48989
  var Status = function(props) {
48958
- var $ = (0, import_react_compiler_runtime95.c)(12);
48990
+ var $ = (0, import_react_compiler_runtime96.c)(12);
48959
48991
  var status = useStatus().status;
48960
48992
  if (status === "recording") {
48961
48993
  var _t;
@@ -48972,7 +49004,7 @@ var Status = function(props) {
48972
49004
  }
48973
49005
  var _t2;
48974
49006
  if ($[1] !== props) {
48975
- _t2 = /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(StatusMessages, _objectSpread50({
49007
+ _t2 = /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(StatusMessages, _objectSpread50({
48976
49008
  texts: _t
48977
49009
  }, props));
48978
49010
  $[1] = props;
@@ -48998,7 +49030,7 @@ var Status = function(props) {
48998
49030
  }
48999
49031
  var _t4;
49000
49032
  if ($[4] !== props) {
49001
- _t4 = /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(StatusMessages, _objectSpread50({
49033
+ _t4 = /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(StatusMessages, _objectSpread50({
49002
49034
  texts: _t3
49003
49035
  }, props));
49004
49036
  $[4] = props;
@@ -49020,7 +49052,7 @@ var Status = function(props) {
49020
49052
  }
49021
49053
  var _t6;
49022
49054
  if ($[7] !== props) {
49023
- _t6 = /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(StatusMessages, _objectSpread50({
49055
+ _t6 = /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(StatusMessages, _objectSpread50({
49024
49056
  texts: _t5
49025
49057
  }, props));
49026
49058
  $[7] = props;
@@ -49041,7 +49073,7 @@ var Status = function(props) {
49041
49073
  }
49042
49074
  var t1;
49043
49075
  if ($[10] !== props) {
49044
- t1 = /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(StatusMessages, _objectSpread50({
49076
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime93.jsx)(StatusMessages, _objectSpread50({
49045
49077
  texts: t0
49046
49078
  }, props));
49047
49079
  $[10] = props;
@@ -49052,11 +49084,11 @@ var Status = function(props) {
49052
49084
  return t1;
49053
49085
  };
49054
49086
  // src/components/threads/AudioThread/Form/index.tsx
49055
- var import_react_compiler_runtime98 = require("react-compiler-runtime");
49087
+ var import_react_compiler_runtime99 = require("react-compiler-runtime");
49056
49088
  var import_themes63 = require("@radix-ui/themes");
49057
49089
  // src/components/threads/AudioThread/Form/MicIcon.tsx
49058
- var import_react_compiler_runtime96 = require("react-compiler-runtime");
49059
- var import_jsx_runtime93 = require("react/jsx-runtime");
49090
+ var import_react_compiler_runtime97 = require("react-compiler-runtime");
49091
+ var import_jsx_runtime94 = require("react/jsx-runtime");
49060
49092
  function ownKeys51(e, r) {
49061
49093
  var t = Object.keys(e);
49062
49094
  if (Object.getOwnPropertySymbols) {
@@ -49101,10 +49133,10 @@ function _toPrimitive51(t, r) {
49101
49133
  return ("string" === r ? String : Number)(t);
49102
49134
  }
49103
49135
  var MicIcon = function(props) {
49104
- var $ = (0, import_react_compiler_runtime96.c)(3);
49136
+ var $ = (0, import_react_compiler_runtime97.c)(3);
49105
49137
  var t0;
49106
49138
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
49107
- t0 = /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("path", {
49139
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("path", {
49108
49140
  stroke: "none",
49109
49141
  d: "M192 0c-53 0-96 43-96 96v160c0 53 43 96 96 96s96-43 96-96V96c0-53-43-96-96-96zM64 216c0-13.3-10.7-24-24-24s-24 10.7-24 24v40c0 89.1 66.2 162.7 152 174.4V464h-48c-13.3 0-24 10.7-24 24s10.7 24 24 24h144c13.3 0 24-10.7 24-24s-10.7-24-24-24h-48v-33.6c85.8-11.7 152-85.3 152-174.4v-40c0-13.3-10.7-24-24-24s-24 10.7-24 24v40c0 70.7-57.3 128-128 128S64 326.7 64 256v-40z"
49110
49142
  });
@@ -49114,7 +49146,7 @@ var MicIcon = function(props) {
49114
49146
  }
49115
49147
  var t1;
49116
49148
  if ($[1] !== props) {
49117
- t1 = /* @__PURE__ */ (0, import_jsx_runtime93.jsx)("svg", _objectSpread51(_objectSpread51({
49149
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)("svg", _objectSpread51(_objectSpread51({
49118
49150
  xmlns: "http://www.w3.org/2000/svg",
49119
49151
  fill: "currentColor",
49120
49152
  stroke: "currentColor",
@@ -49133,29 +49165,29 @@ var MicIcon = function(props) {
49133
49165
  return t1;
49134
49166
  };
49135
49167
  // src/components/threads/AudioThread/Form/ActionButton/index.tsx
49136
- var import_react_compiler_runtime97 = require("react-compiler-runtime");
49168
+ var import_react_compiler_runtime98 = require("react-compiler-runtime");
49137
49169
  var import_themes62 = require("@radix-ui/themes");
49138
49170
  var import_react_icons17 = require("@radix-ui/react-icons");
49139
- var import_jsx_runtime94 = require("react/jsx-runtime");
49171
+ var import_jsx_runtime95 = require("react/jsx-runtime");
49140
49172
  var ActionButton = function() {
49141
- var $ = (0, import_react_compiler_runtime97.c)(27);
49173
+ var $ = (0, import_react_compiler_runtime98.c)(27);
49142
49174
  var status = useStatus().status;
49143
49175
  var audioThreadContext = useAudioThreadContext();
49144
49176
  var superinterfaceContext = useSuperinterfaceContext();
49145
49177
  if (status === "recording") {
49146
49178
  var _t;
49147
49179
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
49148
- _t = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_icons17.PauseIcon, {});
49180
+ _t = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_react_icons17.PauseIcon, {});
49149
49181
  $[0] = _t;
49150
49182
  } else {
49151
49183
  _t = $[0];
49152
49184
  }
49153
49185
  var t1;
49154
49186
  if ($[1] !== audioThreadContext.audioRuntime.user.pause) {
49155
- t1 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.Flex, {
49187
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.Flex, {
49156
49188
  mr: "3",
49157
49189
  ml: "-7",
49158
- children: /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.IconButton, {
49190
+ children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.IconButton, {
49159
49191
  onClick: audioThreadContext.audioRuntime.user.pause,
49160
49192
  color: "gray",
49161
49193
  variant: "soft",
@@ -49170,14 +49202,14 @@ var ActionButton = function() {
49170
49202
  }
49171
49203
  var t2;
49172
49204
  if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
49173
- t2 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_icons17.ArrowUpIcon, {});
49205
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_react_icons17.ArrowUpIcon, {});
49174
49206
  $[3] = t2;
49175
49207
  } else {
49176
49208
  t2 = $[3];
49177
49209
  }
49178
49210
  var t3;
49179
49211
  if ($[4] !== audioThreadContext.audioRuntime.user.stop) {
49180
- t3 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.IconButton, {
49212
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.IconButton, {
49181
49213
  onClick: audioThreadContext.audioRuntime.user.stop,
49182
49214
  highContrast: true,
49183
49215
  variant: "soft",
@@ -49191,7 +49223,7 @@ var ActionButton = function() {
49191
49223
  }
49192
49224
  var t4;
49193
49225
  if ($[6] !== t1 || $[7] !== t3) {
49194
- t4 = /* @__PURE__ */ (0, import_jsx_runtime94.jsxs)(import_themes62.Flex, {
49226
+ t4 = /* @__PURE__ */ (0, import_jsx_runtime95.jsxs)(import_themes62.Flex, {
49195
49227
  align: "center",
49196
49228
  children: [
49197
49229
  t1,
@@ -49209,14 +49241,14 @@ var ActionButton = function() {
49209
49241
  if (status === "recorderPaused") {
49210
49242
  var _t2;
49211
49243
  if ($[9] === Symbol.for("react.memo_cache_sentinel")) {
49212
- _t2 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_icons17.ResumeIcon, {});
49244
+ _t2 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_react_icons17.ResumeIcon, {});
49213
49245
  $[9] = _t2;
49214
49246
  } else {
49215
49247
  _t2 = $[9];
49216
49248
  }
49217
49249
  var _t3;
49218
49250
  if ($[10] !== audioThreadContext.audioRuntime.user.resume) {
49219
- _t3 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.IconButton, {
49251
+ _t3 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.IconButton, {
49220
49252
  onClick: audioThreadContext.audioRuntime.user.resume,
49221
49253
  color: "red",
49222
49254
  size: "4",
@@ -49232,7 +49264,7 @@ var ActionButton = function() {
49232
49264
  if (status === "idle") {
49233
49265
  var _t4;
49234
49266
  if ($[12] !== audioThreadContext.audioRuntime.user) {
49235
- _t4 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.IconButton, {
49267
+ _t4 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.IconButton, {
49236
49268
  onClick: function() {
49237
49269
  return audioThreadContext.audioRuntime.user.start();
49238
49270
  },
@@ -49264,14 +49296,14 @@ var ActionButton = function() {
49264
49296
  }
49265
49297
  var _t6;
49266
49298
  if ($[18] === Symbol.for("react.memo_cache_sentinel")) {
49267
- _t6 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_icons17.StopIcon, {});
49299
+ _t6 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_react_icons17.StopIcon, {});
49268
49300
  $[18] = _t6;
49269
49301
  } else {
49270
49302
  _t6 = $[18];
49271
49303
  }
49272
49304
  var _t7;
49273
49305
  if ($[19] !== _t5) {
49274
- _t7 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.IconButton, {
49306
+ _t7 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.IconButton, {
49275
49307
  onClick: _t5,
49276
49308
  size: "4",
49277
49309
  color: "gray",
@@ -49298,14 +49330,14 @@ var ActionButton = function() {
49298
49330
  }
49299
49331
  var _t9;
49300
49332
  if ($[23] === Symbol.for("react.memo_cache_sentinel")) {
49301
- _t9 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_react_icons17.ResumeIcon, {});
49333
+ _t9 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_react_icons17.ResumeIcon, {});
49302
49334
  $[23] = _t9;
49303
49335
  } else {
49304
49336
  _t9 = $[23];
49305
49337
  }
49306
49338
  var _t0;
49307
49339
  if ($[24] !== _t8) {
49308
- _t0 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.IconButton, {
49340
+ _t0 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.IconButton, {
49309
49341
  onClick: _t8,
49310
49342
  size: "4",
49311
49343
  children: _t9
@@ -49319,7 +49351,7 @@ var ActionButton = function() {
49319
49351
  }
49320
49352
  var t0;
49321
49353
  if ($[26] === Symbol.for("react.memo_cache_sentinel")) {
49322
- t0 = /* @__PURE__ */ (0, import_jsx_runtime94.jsx)(import_themes62.IconButton, {
49354
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes62.IconButton, {
49323
49355
  size: "4",
49324
49356
  variant: "soft",
49325
49357
  disabled: true
@@ -49331,7 +49363,7 @@ var ActionButton = function() {
49331
49363
  return t0;
49332
49364
  };
49333
49365
  // src/components/threads/AudioThread/Form/index.tsx
49334
- var import_jsx_runtime95 = require("react/jsx-runtime");
49366
+ var import_jsx_runtime96 = require("react/jsx-runtime");
49335
49367
  function ownKeys52(e, r) {
49336
49368
  var t = Object.keys(e);
49337
49369
  if (Object.getOwnPropertySymbols) {
@@ -49376,17 +49408,17 @@ function _toPrimitive52(t, r) {
49376
49408
  return ("string" === r ? String : Number)(t);
49377
49409
  }
49378
49410
  var Form = function(props) {
49379
- var $ = (0, import_react_compiler_runtime98.c)(17);
49411
+ var $ = (0, import_react_compiler_runtime99.c)(17);
49380
49412
  var status = useStatus().status;
49381
49413
  var audioThreadContext = useAudioThreadContext();
49382
49414
  var t0 = status === "recording" ? "var(--accent-11)" : "var(--gray-11)";
49383
49415
  var t1;
49384
49416
  if ($[0] !== t0) {
49385
- t1 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes63.Flex, {
49417
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(import_themes63.Flex, {
49386
49418
  ml: "-22.5px",
49387
49419
  mr: "2",
49388
49420
  align: "center",
49389
- children: /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(MicIcon, {
49421
+ children: /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(MicIcon, {
49390
49422
  style: {
49391
49423
  color: t0
49392
49424
  }
@@ -49412,7 +49444,7 @@ var Form = function(props) {
49412
49444
  var t4 = status === "recording" ? "var(--accent-11)" : "var(--gray-11)";
49413
49445
  var t5;
49414
49446
  if ($[4] !== audioThreadContext.audioRuntime.user.visualizationAnalyser || $[5] !== t4) {
49415
- t5 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(BarsVisualizer, {
49447
+ t5 = /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(BarsVisualizer, {
49416
49448
  visualizationAnalyser: audioThreadContext.audioRuntime.user.visualizationAnalyser,
49417
49449
  backgroundColor: t4,
49418
49450
  height: "20px",
@@ -49426,7 +49458,7 @@ var Form = function(props) {
49426
49458
  }
49427
49459
  var t6;
49428
49460
  if ($[7] !== t3 || $[8] !== t5) {
49429
- t6 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(import_themes63.Flex, {
49461
+ t6 = /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(import_themes63.Flex, {
49430
49462
  px: "2",
49431
49463
  py: "1",
49432
49464
  style: t3,
@@ -49440,7 +49472,7 @@ var Form = function(props) {
49440
49472
  }
49441
49473
  var t7;
49442
49474
  if ($[10] !== t1 || $[11] !== t6) {
49443
- t7 = /* @__PURE__ */ (0, import_jsx_runtime95.jsxs)(import_themes63.Flex, {
49475
+ t7 = /* @__PURE__ */ (0, import_jsx_runtime96.jsxs)(import_themes63.Flex, {
49444
49476
  pb: "3",
49445
49477
  align: "center",
49446
49478
  children: [
@@ -49456,14 +49488,14 @@ var Form = function(props) {
49456
49488
  }
49457
49489
  var t8;
49458
49490
  if ($[13] === Symbol.for("react.memo_cache_sentinel")) {
49459
- t8 = /* @__PURE__ */ (0, import_jsx_runtime95.jsx)(ActionButton, {});
49491
+ t8 = /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(ActionButton, {});
49460
49492
  $[13] = t8;
49461
49493
  } else {
49462
49494
  t8 = $[13];
49463
49495
  }
49464
49496
  var t9;
49465
49497
  if ($[14] !== props || $[15] !== t7) {
49466
- t9 = /* @__PURE__ */ (0, import_jsx_runtime95.jsxs)(import_themes63.Flex, _objectSpread52(_objectSpread52({
49498
+ t9 = /* @__PURE__ */ (0, import_jsx_runtime96.jsxs)(import_themes63.Flex, _objectSpread52(_objectSpread52({
49467
49499
  direction: "column",
49468
49500
  align: "center"
49469
49501
  }, props), {}, {
@@ -49481,7 +49513,7 @@ var Form = function(props) {
49481
49513
  return t9;
49482
49514
  };
49483
49515
  // src/components/threads/AudioThread/index.tsx
49484
- var import_jsx_runtime96 = require("react/jsx-runtime");
49516
+ var import_jsx_runtime97 = require("react/jsx-runtime");
49485
49517
  function ownKeys53(e, r) {
49486
49518
  var t = Object.keys(e);
49487
49519
  if (Object.getOwnPropertySymbols) {
@@ -49526,14 +49558,14 @@ function _toPrimitive53(t, r) {
49526
49558
  return ("string" === r ? String : Number)(t);
49527
49559
  }
49528
49560
  var AudioThread = function(props) {
49529
- var $ = (0, import_react_compiler_runtime99.c)(5);
49561
+ var $ = (0, import_react_compiler_runtime100.c)(5);
49530
49562
  var t0;
49531
49563
  var t1;
49532
49564
  var t2;
49533
49565
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
49534
- t0 = /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(Visualization, {});
49535
- t1 = /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(Status, {});
49536
- t2 = /* @__PURE__ */ (0, import_jsx_runtime96.jsx)(Form, {});
49566
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Visualization, {});
49567
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Status, {});
49568
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Form, {});
49537
49569
  $[0] = t0;
49538
49570
  $[1] = t1;
49539
49571
  $[2] = t2;
@@ -49544,7 +49576,7 @@ var AudioThread = function(props) {
49544
49576
  }
49545
49577
  var t3;
49546
49578
  if ($[3] !== props) {
49547
- t3 = /* @__PURE__ */ (0, import_jsx_runtime96.jsxs)(Root16, _objectSpread53(_objectSpread53({}, props), {}, {
49579
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)(Root16, _objectSpread53(_objectSpread53({}, props), {}, {
49548
49580
  children: [
49549
49581
  t0,
49550
49582
  t1,
@@ -49563,7 +49595,7 @@ AudioThread.Visualization = Visualization;
49563
49595
  AudioThread.Status = Status;
49564
49596
  AudioThread.Form = Form;
49565
49597
  // src/components/threads/AudioThreadDialog/index.tsx
49566
- var import_jsx_runtime97 = require("react/jsx-runtime");
49598
+ var import_jsx_runtime98 = require("react/jsx-runtime");
49567
49599
  function ownKeys54(e, r) {
49568
49600
  var t = Object.keys(e);
49569
49601
  if (Object.getOwnPropertySymbols) {
@@ -49608,14 +49640,14 @@ function _toPrimitive54(t, r) {
49608
49640
  return ("string" === r ? String : Number)(t);
49609
49641
  }
49610
49642
  var AudioThreadDialog = function(props) {
49611
- var $ = (0, import_react_compiler_runtime100.c)(4);
49643
+ var $ = (0, import_react_compiler_runtime101.c)(4);
49612
49644
  var t0;
49613
49645
  var t1;
49614
49646
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
49615
- t0 = /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Content8.Root, {
49616
- children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(AudioThread, {})
49647
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(Content8.Root, {
49648
+ children: /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(AudioThread, {})
49617
49649
  });
49618
- t1 = /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Trigger, {});
49650
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(Trigger, {});
49619
49651
  $[0] = t0;
49620
49652
  $[1] = t1;
49621
49653
  } else {
@@ -49624,7 +49656,7 @@ var AudioThreadDialog = function(props) {
49624
49656
  }
49625
49657
  var t2;
49626
49658
  if ($[2] !== props) {
49627
- t2 = /* @__PURE__ */ (0, import_jsx_runtime97.jsxs)(Root13, _objectSpread54(_objectSpread54({}, props), {}, {
49659
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime98.jsxs)(Root13, _objectSpread54(_objectSpread54({}, props), {}, {
49628
49660
  children: [
49629
49661
  t0,
49630
49662
  t1
@@ -49641,7 +49673,7 @@ AudioThreadDialog.Root = Root13;
49641
49673
  AudioThreadDialog.Trigger = Trigger;
49642
49674
  AudioThreadDialog.Content = Content8;
49643
49675
  // src/hooks/audioRuntimes/useWebrtcAudioRuntime/index.ts
49644
- var import_react72 = require("react");
49676
+ var import_react73 = require("react");
49645
49677
  function asyncGeneratorStep12(n, t, e, r, o, a, c) {
49646
49678
  try {
49647
49679
  var i = n[a](c), u = i.value;
@@ -49730,22 +49762,22 @@ var useWebrtcAudioRuntime = function() {
49730
49762
  console.warn("Could not build analyzers:", err_0);
49731
49763
  }
49732
49764
  };
49733
- var _ref = _sliced_to_array((0, import_react72.useState)("idle"), 2), recorderStatus = _ref[0], setRecorderStatus = _ref[1];
49765
+ var _ref = _sliced_to_array((0, import_react73.useState)("idle"), 2), recorderStatus = _ref[0], setRecorderStatus = _ref[1];
49734
49766
  var superinterfaceContext = useSuperinterfaceContext();
49735
- var _ref1 = _sliced_to_array((0, import_react72.useState)(false), 2), userIsPending = _ref1[0], setUserIsPending = _ref1[1];
49736
- var _ref2 = _sliced_to_array((0, import_react72.useState)(false), 2), assistantPlaying = _ref2[0], setAssistantPlaying = _ref2[1];
49737
- var _ref3 = _sliced_to_array((0, import_react72.useState)(false), 2), assistantPaused = _ref3[0], setAssistantPaused = _ref3[1];
49738
- var _ref4 = _sliced_to_array((0, import_react72.useState)(true), 2), assistantIsPending = _ref4[0], setAssistantIsPending = _ref4[1];
49739
- var _ref5 = _sliced_to_array((0, import_react72.useState)(false), 2), assistantIsReady = _ref5[0], setAssistantIsReady = _ref5[1];
49740
- var _ref6 = _sliced_to_array((0, import_react72.useState)(false), 2), assistantAudioPlayed = _ref6[0], setAssistantAudioPlayed = _ref6[1];
49741
- var sessionStartedRef = (0, import_react72.useRef)(false);
49742
- var pcRef = (0, import_react72.useRef)(null);
49743
- var localStreamRef = (0, import_react72.useRef)(null);
49744
- var remoteStreamRef = (0, import_react72.useRef)(null);
49745
- var userAnalyserRef = (0, import_react72.useRef)(null);
49746
- var assistantAnalyserRef = (0, import_react72.useRef)(null);
49747
- var assistantAudioElRef = (0, import_react72.useRef)(null);
49748
- (0, import_react72.useEffect)(function() {
49767
+ var _ref1 = _sliced_to_array((0, import_react73.useState)(false), 2), userIsPending = _ref1[0], setUserIsPending = _ref1[1];
49768
+ var _ref2 = _sliced_to_array((0, import_react73.useState)(false), 2), assistantPlaying = _ref2[0], setAssistantPlaying = _ref2[1];
49769
+ var _ref3 = _sliced_to_array((0, import_react73.useState)(false), 2), assistantPaused = _ref3[0], setAssistantPaused = _ref3[1];
49770
+ var _ref4 = _sliced_to_array((0, import_react73.useState)(true), 2), assistantIsPending = _ref4[0], setAssistantIsPending = _ref4[1];
49771
+ var _ref5 = _sliced_to_array((0, import_react73.useState)(false), 2), assistantIsReady = _ref5[0], setAssistantIsReady = _ref5[1];
49772
+ var _ref6 = _sliced_to_array((0, import_react73.useState)(false), 2), assistantAudioPlayed = _ref6[0], setAssistantAudioPlayed = _ref6[1];
49773
+ var sessionStartedRef = (0, import_react73.useRef)(false);
49774
+ var pcRef = (0, import_react73.useRef)(null);
49775
+ var localStreamRef = (0, import_react73.useRef)(null);
49776
+ var remoteStreamRef = (0, import_react73.useRef)(null);
49777
+ var userAnalyserRef = (0, import_react73.useRef)(null);
49778
+ var assistantAnalyserRef = (0, import_react73.useRef)(null);
49779
+ var assistantAudioElRef = (0, import_react73.useRef)(null);
49780
+ (0, import_react73.useEffect)(function() {
49749
49781
  return function() {
49750
49782
  if (pcRef.current) {
49751
49783
  pcRef.current.close();
@@ -50081,7 +50113,7 @@ var useWebrtcAudioRuntime = function() {
50081
50113
  return _ref7.apply(this, arguments);
50082
50114
  };
50083
50115
  }();
50084
- return (0, import_react72.useMemo)(function() {
50116
+ return (0, import_react73.useMemo)(function() {
50085
50117
  return {
50086
50118
  webrtcAudioRuntime: {
50087
50119
  user: {
@@ -50130,10 +50162,10 @@ var useWebrtcAudioRuntime = function() {
50130
50162
  ]);
50131
50163
  };
50132
50164
  // src/components/audioRuntimes/WebrtcAudioRuntimeProvider.tsx
50133
- var import_react_compiler_runtime101 = require("react-compiler-runtime");
50134
- var import_jsx_runtime98 = require("react/jsx-runtime");
50165
+ var import_react_compiler_runtime102 = require("react-compiler-runtime");
50166
+ var import_jsx_runtime99 = require("react/jsx-runtime");
50135
50167
  var WebrtcAudioRuntimeProvider = function(t0) {
50136
- var $ = (0, import_react_compiler_runtime101.c)(5);
50168
+ var $ = (0, import_react_compiler_runtime102.c)(5);
50137
50169
  var children = t0.children;
50138
50170
  var webrtcAudioRuntime = useWebrtcAudioRuntime().webrtcAudioRuntime;
50139
50171
  var t1;
@@ -50148,7 +50180,7 @@ var WebrtcAudioRuntimeProvider = function(t0) {
50148
50180
  }
50149
50181
  var t2;
50150
50182
  if ($[2] !== children || $[3] !== t1) {
50151
- t2 = /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(AudioThreadContext.Provider, {
50183
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(AudioThreadContext.Provider, {
50152
50184
  value: t1,
50153
50185
  children: children
50154
50186
  });
@@ -50161,14 +50193,14 @@ var WebrtcAudioRuntimeProvider = function(t0) {
50161
50193
  return t2;
50162
50194
  };
50163
50195
  // src/components/gui/Gui/index.tsx
50164
- var import_react_compiler_runtime104 = require("react-compiler-runtime");
50165
- var import_react75 = require("react");
50196
+ var import_react_compiler_runtime105 = require("react-compiler-runtime");
50197
+ var import_react76 = require("react");
50166
50198
  var import_themes64 = require("@radix-ui/themes");
50167
50199
  // src/hooks/messages/useLatestAssistantMessage/index.ts
50168
- var import_react_compiler_runtime102 = require("react-compiler-runtime");
50169
- var import_react73 = require("react");
50200
+ var import_react_compiler_runtime103 = require("react-compiler-runtime");
50201
+ var import_react74 = require("react");
50170
50202
  var useLatestAssistantMessage = function() {
50171
- var $ = (0, import_react_compiler_runtime102.c)(4);
50203
+ var $ = (0, import_react_compiler_runtime103.c)(4);
50172
50204
  var _useMessages = useMessages(), messages2 = _useMessages.messages;
50173
50205
  var t0;
50174
50206
  var t1;
@@ -50197,11 +50229,11 @@ function _temp11(message) {
50197
50229
  return message.role === "assistant";
50198
50230
  }
50199
50231
  // src/hooks/messages/useLatestAssistantMessageWithContent/index.ts
50200
- var import_react_compiler_runtime103 = require("react-compiler-runtime");
50232
+ var import_react_compiler_runtime104 = require("react-compiler-runtime");
50201
50233
  var import_radash18 = require("radash");
50202
- var import_react74 = require("react");
50234
+ var import_react75 = require("react");
50203
50235
  var useLatestAssistantMessageWithContent = function() {
50204
- var $ = (0, import_react_compiler_runtime103.c)(4);
50236
+ var $ = (0, import_react_compiler_runtime104.c)(4);
50205
50237
  var _useMessages = useMessages(), messages2 = _useMessages.messages;
50206
50238
  var t0;
50207
50239
  var t1;
@@ -50233,14 +50265,14 @@ function _temp25(message) {
50233
50265
  return message.role === "assistant" && message.content.some(_temp12);
50234
50266
  }
50235
50267
  // src/components/gui/Gui/index.tsx
50236
- var import_jsx_runtime99 = require("react/jsx-runtime");
50268
+ var import_jsx_runtime100 = require("react/jsx-runtime");
50237
50269
  var StartingToolCalls3 = function() {
50238
- var $ = (0, import_react_compiler_runtime104.c)(2);
50270
+ var $ = (0, import_react_compiler_runtime105.c)(2);
50239
50271
  var _useComponents = useComponents(), t0 = _useComponents.components;
50240
50272
  var StartingToolCalls4 = t0.StartingToolCalls;
50241
50273
  var t1;
50242
50274
  if ($[0] !== StartingToolCalls4) {
50243
- t1 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(StartingToolCalls4, {});
50275
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(StartingToolCalls4, {});
50244
50276
  $[0] = StartingToolCalls4;
50245
50277
  $[1] = t1;
50246
50278
  } else {
@@ -50249,7 +50281,7 @@ var StartingToolCalls3 = function() {
50249
50281
  return t1;
50250
50282
  };
50251
50283
  var Content10 = function(t0) {
50252
- var $ = (0, import_react_compiler_runtime104.c)(5);
50284
+ var $ = (0, import_react_compiler_runtime105.c)(5);
50253
50285
  var latestRunStep = t0.latestRunStep;
50254
50286
  var t1;
50255
50287
  bb0: {
@@ -50271,7 +50303,7 @@ var Content10 = function(t0) {
50271
50303
  if (!latestRunStep || latestRunStep.step_details.type !== "tool_calls") {
50272
50304
  var _t;
50273
50305
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
50274
- _t = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_themes64.Spinner, {});
50306
+ _t = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_themes64.Spinner, {});
50275
50307
  $[0] = _t;
50276
50308
  } else {
50277
50309
  _t = $[0];
@@ -50281,7 +50313,7 @@ var Content10 = function(t0) {
50281
50313
  if (!latestToolCall) {
50282
50314
  var _t2;
50283
50315
  if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
50284
- _t2 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(StartingToolCalls3, {});
50316
+ _t2 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(StartingToolCalls3, {});
50285
50317
  $[1] = _t2;
50286
50318
  } else {
50287
50319
  _t2 = $[1];
@@ -50290,7 +50322,7 @@ var Content10 = function(t0) {
50290
50322
  }
50291
50323
  var t2;
50292
50324
  if ($[2] !== latestRunStep || $[3] !== latestToolCall) {
50293
- t2 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(ToolCall, {
50325
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(ToolCall, {
50294
50326
  runStep: latestRunStep,
50295
50327
  toolCall: latestToolCall
50296
50328
  });
@@ -50303,7 +50335,7 @@ var Content10 = function(t0) {
50303
50335
  return t2;
50304
50336
  };
50305
50337
  var Progress2 = function(t0) {
50306
- var $ = (0, import_react_compiler_runtime104.c)(5);
50338
+ var $ = (0, import_react_compiler_runtime105.c)(5);
50307
50339
  var latestAssistantMessage = t0.latestAssistantMessage;
50308
50340
  var isMutatingMessage = useIsMutatingMessage();
50309
50341
  var t1;
@@ -50337,10 +50369,10 @@ var Progress2 = function(t0) {
50337
50369
  }
50338
50370
  var t4;
50339
50371
  if ($[3] !== latestRunStep) {
50340
- t4 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_themes64.Flex, {
50372
+ t4 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_themes64.Flex, {
50341
50373
  style: t3,
50342
- children: /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_themes64.Card, {
50343
- children: /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(Content10, {
50374
+ children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_themes64.Card, {
50375
+ children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(Content10, {
50344
50376
  latestRunStep: latestRunStep
50345
50377
  })
50346
50378
  })
@@ -50353,20 +50385,20 @@ var Progress2 = function(t0) {
50353
50385
  return t4;
50354
50386
  };
50355
50387
  var Gui = function() {
50356
- var $ = (0, import_react_compiler_runtime104.c)(8);
50388
+ var $ = (0, import_react_compiler_runtime105.c)(8);
50357
50389
  var latestAssistantMessage = useLatestAssistantMessage().latestAssistantMessage;
50358
50390
  var latestAssistantMessageWithContent = useLatestAssistantMessageWithContent().latestAssistantMessageWithContent;
50359
50391
  if (!latestAssistantMessage || !latestAssistantMessageWithContent) {
50360
50392
  var _t3;
50361
50393
  if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
50362
- _t3 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_themes64.Flex, {
50394
+ _t3 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_themes64.Flex, {
50363
50395
  direction: "column",
50364
50396
  flexGrow: "1",
50365
- children: /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_themes64.Flex, {
50397
+ children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_themes64.Flex, {
50366
50398
  align: "center",
50367
50399
  justify: "center",
50368
50400
  flexGrow: "1",
50369
- children: /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(import_themes64.Spinner, {
50401
+ children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_themes64.Spinner, {
50370
50402
  size: "3"
50371
50403
  })
50372
50404
  })
@@ -50379,7 +50411,7 @@ var Gui = function() {
50379
50411
  }
50380
50412
  var t0;
50381
50413
  if ($[1] !== latestAssistantMessageWithContent) {
50382
- t0 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(MessageContent, {
50414
+ t0 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(MessageContent, {
50383
50415
  message: latestAssistantMessageWithContent
50384
50416
  });
50385
50417
  $[1] = latestAssistantMessageWithContent;
@@ -50389,7 +50421,7 @@ var Gui = function() {
50389
50421
  }
50390
50422
  var t1;
50391
50423
  if ($[3] !== latestAssistantMessage) {
50392
- t1 = /* @__PURE__ */ (0, import_jsx_runtime99.jsx)(Progress2, {
50424
+ t1 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(Progress2, {
50393
50425
  latestAssistantMessage: latestAssistantMessage
50394
50426
  });
50395
50427
  $[3] = latestAssistantMessage;
@@ -50399,7 +50431,7 @@ var Gui = function() {
50399
50431
  }
50400
50432
  var t2;
50401
50433
  if ($[5] !== t0 || $[6] !== t1) {
50402
- t2 = /* @__PURE__ */ (0, import_jsx_runtime99.jsxs)(import_themes64.Flex, {
50434
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime100.jsxs)(import_themes64.Flex, {
50403
50435
  direction: "column",
50404
50436
  flexGrow: "1",
50405
50437
  children: [
@@ -50419,9 +50451,9 @@ function _temp13(rs) {
50419
50451
  return rs.status === "in_progress";
50420
50452
  }
50421
50453
  // src/components/markdown/MarkdownProvider/index.tsx
50422
- var import_react_compiler_runtime105 = require("react-compiler-runtime");
50423
- var import_react76 = require("react");
50424
- var import_jsx_runtime100 = require("react/jsx-runtime");
50454
+ var import_react_compiler_runtime106 = require("react-compiler-runtime");
50455
+ var import_react77 = require("react");
50456
+ var import_jsx_runtime101 = require("react/jsx-runtime");
50425
50457
  var _excluded7 = [
50426
50458
  "children"
50427
50459
  ];
@@ -50444,7 +50476,7 @@ function _objectWithoutPropertiesLoose7(r, e) {
50444
50476
  return t;
50445
50477
  }
50446
50478
  var MarkdownProvider = function(t0) {
50447
- var $ = (0, import_react_compiler_runtime105.c)(9);
50479
+ var $ = (0, import_react_compiler_runtime106.c)(9);
50448
50480
  var children;
50449
50481
  var rest;
50450
50482
  if ($[0] !== t0) {
@@ -50474,7 +50506,7 @@ var MarkdownProvider = function(t0) {
50474
50506
  var value = t1;
50475
50507
  var t3;
50476
50508
  if ($[6] !== children || $[7] !== value) {
50477
- t3 = /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(MarkdownContext.Provider, {
50509
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(MarkdownContext.Provider, {
50478
50510
  value: value,
50479
50511
  children: children
50480
50512
  });
@@ -50487,18 +50519,18 @@ var MarkdownProvider = function(t0) {
50487
50519
  return t3;
50488
50520
  };
50489
50521
  // src/components/annotations/SourceAnnotation/index.tsx
50490
- var import_react_compiler_runtime108 = require("react-compiler-runtime");
50522
+ var import_react_compiler_runtime109 = require("react-compiler-runtime");
50491
50523
  // src/components/annotations/SourceAnnotation/FileCitation/index.tsx
50492
- var import_react_compiler_runtime107 = require("react-compiler-runtime");
50493
- var import_react77 = require("react");
50524
+ var import_react_compiler_runtime108 = require("react-compiler-runtime");
50525
+ var import_react78 = require("react");
50494
50526
  var import_react_icons18 = require("@radix-ui/react-icons");
50495
50527
  var import_themes66 = require("@radix-ui/themes");
50496
50528
  // src/components/annotations/SourceAnnotation/FileCitation/Content.tsx
50497
- var import_react_compiler_runtime106 = require("react-compiler-runtime");
50529
+ var import_react_compiler_runtime107 = require("react-compiler-runtime");
50498
50530
  var import_themes65 = require("@radix-ui/themes");
50499
- var import_jsx_runtime101 = require("react/jsx-runtime");
50531
+ var import_jsx_runtime102 = require("react/jsx-runtime");
50500
50532
  var Content11 = function(t0) {
50501
- var $ = (0, import_react_compiler_runtime106.c)(5);
50533
+ var $ = (0, import_react_compiler_runtime107.c)(5);
50502
50534
  var fileId = t0.fileId;
50503
50535
  var superinterfaceContext = useSuperinterfaceContext();
50504
50536
  var nextSearchParams = new URLSearchParams(superinterfaceContext.variables);
@@ -50535,18 +50567,18 @@ var Content11 = function(t0) {
50535
50567
  }
50536
50568
  var t5;
50537
50569
  if ($[3] !== t3) {
50538
- t5 = /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(import_themes65.Flex, {
50570
+ t5 = /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes65.Flex, {
50539
50571
  direction: "column",
50540
50572
  flexGrow: "1",
50541
50573
  gap: "3",
50542
- children: /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(import_themes65.Card, {
50574
+ children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes65.Card, {
50543
50575
  style: t1,
50544
- children: /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(import_themes65.Inset, {
50576
+ children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes65.Inset, {
50545
50577
  clip: "padding-box",
50546
50578
  style: t2,
50547
- children: /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(import_themes65.Flex, {
50579
+ children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes65.Flex, {
50548
50580
  flexGrow: "1",
50549
- children: /* @__PURE__ */ (0, import_jsx_runtime101.jsx)("embed", {
50581
+ children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)("embed", {
50550
50582
  src: t3,
50551
50583
  style: t4
50552
50584
  })
@@ -50562,11 +50594,11 @@ var Content11 = function(t0) {
50562
50594
  return t5;
50563
50595
  };
50564
50596
  // src/components/annotations/SourceAnnotation/FileCitation/index.tsx
50565
- var import_jsx_runtime102 = require("react/jsx-runtime");
50597
+ var import_jsx_runtime103 = require("react/jsx-runtime");
50566
50598
  var FileCitation = function(t0) {
50567
- var $ = (0, import_react_compiler_runtime107.c)(18);
50599
+ var $ = (0, import_react_compiler_runtime108.c)(18);
50568
50600
  var annotation = t0.annotation;
50569
- var _ref = _sliced_to_array((0, import_react77.useState)(null), 2), activeFileId = _ref[0], setActiveFileId = _ref[1];
50601
+ var _ref = _sliced_to_array((0, import_react78.useState)(null), 2), activeFileId = _ref[0], setActiveFileId = _ref[1];
50570
50602
  var t1;
50571
50603
  if ($[0] !== annotation.file_citation.file_id) {
50572
50604
  t1 = function() {
@@ -50579,14 +50611,14 @@ var FileCitation = function(t0) {
50579
50611
  }
50580
50612
  var t2;
50581
50613
  if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
50582
- t2 = /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_react_icons18.QuoteIcon, {});
50614
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(import_react_icons18.QuoteIcon, {});
50583
50615
  $[2] = t2;
50584
50616
  } else {
50585
50617
  t2 = $[2];
50586
50618
  }
50587
50619
  var t3;
50588
50620
  if ($[3] !== t1) {
50589
- t3 = /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes66.IconButton, {
50621
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(import_themes66.IconButton, {
50590
50622
  variant: "soft",
50591
50623
  color: "gray",
50592
50624
  size: "1",
@@ -50622,9 +50654,9 @@ var FileCitation = function(t0) {
50622
50654
  }
50623
50655
  var t7;
50624
50656
  if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
50625
- t7 = /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes66.VisuallyHidden, {
50657
+ t7 = /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(import_themes66.VisuallyHidden, {
50626
50658
  asChild: true,
50627
- children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes66.Dialog.Title, {
50659
+ children: /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(import_themes66.Dialog.Title, {
50628
50660
  children: "Source"
50629
50661
  })
50630
50662
  });
@@ -50634,7 +50666,7 @@ var FileCitation = function(t0) {
50634
50666
  }
50635
50667
  var t8;
50636
50668
  if ($[8] !== activeFileId) {
50637
- t8 = activeFileId && /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(Content11, {
50669
+ t8 = activeFileId && /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(Content11, {
50638
50670
  fileId: activeFileId
50639
50671
  });
50640
50672
  $[8] = activeFileId;
@@ -50644,7 +50676,7 @@ var FileCitation = function(t0) {
50644
50676
  }
50645
50677
  var t9;
50646
50678
  if ($[10] !== t8) {
50647
- t9 = /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)(import_themes66.Dialog.Content, {
50679
+ t9 = /* @__PURE__ */ (0, import_jsx_runtime103.jsxs)(import_themes66.Dialog.Content, {
50648
50680
  width: "1000px",
50649
50681
  height: "90vh",
50650
50682
  maxWidth: "calc(100vw - 2 * var(--space-4))",
@@ -50662,7 +50694,7 @@ var FileCitation = function(t0) {
50662
50694
  }
50663
50695
  var t10;
50664
50696
  if ($[12] !== t4 || $[13] !== t9) {
50665
- t10 = /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(import_themes66.Dialog.Root, {
50697
+ t10 = /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(import_themes66.Dialog.Root, {
50666
50698
  open: t4,
50667
50699
  onOpenChange: t5,
50668
50700
  children: t9
@@ -50675,7 +50707,7 @@ var FileCitation = function(t0) {
50675
50707
  }
50676
50708
  var t11;
50677
50709
  if ($[15] !== t10 || $[16] !== t3) {
50678
- t11 = /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)(import_jsx_runtime102.Fragment, {
50710
+ t11 = /* @__PURE__ */ (0, import_jsx_runtime103.jsxs)(import_jsx_runtime103.Fragment, {
50679
50711
  children: [
50680
50712
  t3,
50681
50713
  t10
@@ -50690,7 +50722,7 @@ var FileCitation = function(t0) {
50690
50722
  return t11;
50691
50723
  };
50692
50724
  // src/components/annotations/SourceAnnotation/index.tsx
50693
- var import_jsx_runtime103 = require("react/jsx-runtime");
50725
+ var import_jsx_runtime104 = require("react/jsx-runtime");
50694
50726
  var _excluded8 = [
50695
50727
  "children"
50696
50728
  ];
@@ -50713,7 +50745,7 @@ function _objectWithoutPropertiesLoose8(r, e) {
50713
50745
  return t;
50714
50746
  }
50715
50747
  var SourceAnnotation = function(t0) {
50716
- var $ = (0, import_react_compiler_runtime108.c)(10);
50748
+ var $ = (0, import_react_compiler_runtime109.c)(10);
50717
50749
  var children;
50718
50750
  var rest;
50719
50751
  if ($[0] !== t0) {
@@ -50741,7 +50773,7 @@ var SourceAnnotation = function(t0) {
50741
50773
  if (annotation.type === "file_citation") {
50742
50774
  var t2;
50743
50775
  if ($[5] !== annotation) {
50744
- t2 = /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(FileCitation, {
50776
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(FileCitation, {
50745
50777
  annotation: annotation
50746
50778
  });
50747
50779
  $[5] = annotation;
@@ -50754,7 +50786,7 @@ var SourceAnnotation = function(t0) {
50754
50786
  if (annotation.type === "file_path") {
50755
50787
  var _t2;
50756
50788
  if ($[7] !== annotation || $[8] !== children) {
50757
- _t2 = /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(FilePathAnnotation, {
50789
+ _t2 = /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(FilePathAnnotation, {
50758
50790
  annotation: annotation,
50759
50791
  children: children
50760
50792
  });
@@ -50770,7 +50802,7 @@ var SourceAnnotation = function(t0) {
50770
50802
  return null;
50771
50803
  };
50772
50804
  // src/components/avatars/Avatar.tsx
50773
- var import_react_compiler_runtime111 = require("react-compiler-runtime");
50805
+ var import_react_compiler_runtime112 = require("react-compiler-runtime");
50774
50806
  // src/enums/index.ts
50775
50807
  var IconAvatarName = /* @__PURE__ */ function(IconAvatarName2) {
50776
50808
  IconAvatarName2["BACKPACK"] = "BACKPACK";
@@ -50795,7 +50827,7 @@ var AvatarType = /* @__PURE__ */ function(AvatarType2) {
50795
50827
  // src/components/avatars/Avatar.tsx
50796
50828
  var import_themes69 = require("@radix-ui/themes");
50797
50829
  // src/components/imageAvatars/ImageAvatar/index.tsx
50798
- var import_react_compiler_runtime109 = require("react-compiler-runtime");
50830
+ var import_react_compiler_runtime110 = require("react-compiler-runtime");
50799
50831
  var import_themes67 = require("@radix-ui/themes");
50800
50832
  // src/components/imageAvatars/ImageAvatar/lib/optimizedSrc/path.ts
50801
50833
  var width = function(_ref) {
@@ -50847,9 +50879,9 @@ var optimizedSrc = function(_ref) {
50847
50879
  }));
50848
50880
  };
50849
50881
  // src/components/imageAvatars/ImageAvatar/index.tsx
50850
- var import_jsx_runtime104 = require("react/jsx-runtime");
50882
+ var import_jsx_runtime105 = require("react/jsx-runtime");
50851
50883
  var ImageAvatar = function(t0) {
50852
- var $ = (0, import_react_compiler_runtime109.c)(9);
50884
+ var $ = (0, import_react_compiler_runtime110.c)(9);
50853
50885
  var imageAvatar = t0.imageAvatar, size = t0.size, className = t0.className, style = t0.style;
50854
50886
  var superinterfaceContext = useSuperinterfaceContext();
50855
50887
  var t1;
@@ -50868,7 +50900,7 @@ var ImageAvatar = function(t0) {
50868
50900
  }
50869
50901
  var t2;
50870
50902
  if ($[4] !== className || $[5] !== size || $[6] !== style || $[7] !== t1) {
50871
- t2 = /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(import_themes67.Avatar, {
50903
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_themes67.Avatar, {
50872
50904
  className: className,
50873
50905
  style: style,
50874
50906
  fallback: "",
@@ -50886,24 +50918,24 @@ var ImageAvatar = function(t0) {
50886
50918
  return t2;
50887
50919
  };
50888
50920
  // src/components/iconAvatars/IconAvatar.tsx
50889
- var import_react_compiler_runtime110 = require("react-compiler-runtime");
50890
- var import_react78 = require("react");
50921
+ var import_react_compiler_runtime111 = require("react-compiler-runtime");
50922
+ var import_react79 = require("react");
50891
50923
  var import_themes68 = require("@radix-ui/themes");
50892
50924
  // src/lib/iconAvatars/iconAvatarComponents.ts
50893
50925
  var import_react_icons19 = require("@radix-ui/react-icons");
50894
50926
  var _obj;
50895
50927
  var iconAvatarComponents = (_obj = {}, _define_property(_obj, IconAvatarName.BACKPACK, import_react_icons19.BackpackIcon), _define_property(_obj, IconAvatarName.ROCKET, import_react_icons19.RocketIcon), _define_property(_obj, IconAvatarName.MAGIC_WAND, import_react_icons19.MagicWandIcon), _define_property(_obj, IconAvatarName.CUBE, import_react_icons19.CubeIcon), _define_property(_obj, IconAvatarName.TARGET, import_react_icons19.TargetIcon), _define_property(_obj, IconAvatarName.DISC, import_react_icons19.DiscIcon), _define_property(_obj, IconAvatarName.GLOBE, import_react_icons19.GlobeIcon), _define_property(_obj, IconAvatarName.STAR, import_react_icons19.StarIcon), _define_property(_obj, IconAvatarName.LIGHTNING_BOLT, import_react_icons19.LightningBoltIcon), _define_property(_obj, IconAvatarName.FACE, import_react_icons19.FaceIcon), _define_property(_obj, IconAvatarName.PERSON, import_react_icons19.PersonIcon), _define_property(_obj, IconAvatarName.HEART, import_react_icons19.HeartIcon), _obj);
50896
50928
  // src/components/iconAvatars/IconAvatar.tsx
50897
- var import_jsx_runtime105 = require("react/jsx-runtime");
50929
+ var import_jsx_runtime106 = require("react/jsx-runtime");
50898
50930
  var IconAvatar = function(t0) {
50899
- var $ = (0, import_react_compiler_runtime110.c)(7);
50931
+ var $ = (0, import_react_compiler_runtime111.c)(7);
50900
50932
  var iconAvatar = t0.iconAvatar, size = t0.size, className = t0.className, style = t0.style;
50901
50933
  var t1;
50902
50934
  t1 = iconAvatarComponents[iconAvatar.name];
50903
50935
  var Component2 = t1;
50904
50936
  var t2;
50905
50937
  if ($[0] !== Component2) {
50906
- t2 = Component2 ? /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(Component2, {}) : "";
50938
+ t2 = Component2 ? /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(Component2, {}) : "";
50907
50939
  $[0] = Component2;
50908
50940
  $[1] = t2;
50909
50941
  } else {
@@ -50911,7 +50943,7 @@ var IconAvatar = function(t0) {
50911
50943
  }
50912
50944
  var t3;
50913
50945
  if ($[2] !== className || $[3] !== size || $[4] !== style || $[5] !== t2) {
50914
- t3 = /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_themes68.Avatar, {
50946
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(import_themes68.Avatar, {
50915
50947
  className: className,
50916
50948
  style: style,
50917
50949
  size: size,
@@ -50928,16 +50960,16 @@ var IconAvatar = function(t0) {
50928
50960
  return t3;
50929
50961
  };
50930
50962
  // src/components/avatars/Avatar.tsx
50931
- var import_jsx_runtime106 = require("react/jsx-runtime");
50963
+ var import_jsx_runtime107 = require("react/jsx-runtime");
50932
50964
  var Avatar6 = function(t0) {
50933
- var $ = (0, import_react_compiler_runtime111.c)(14);
50965
+ var $ = (0, import_react_compiler_runtime112.c)(14);
50934
50966
  var avatar = t0.avatar, t1 = t0.size, className = t0.className, style = t0.style;
50935
50967
  var size = t1 === void 0 ? "1" : t1;
50936
50968
  if (avatar) {
50937
50969
  if (avatar.type === AvatarType.IMAGE && avatar.imageAvatar) {
50938
50970
  var _t;
50939
50971
  if ($[0] !== avatar.imageAvatar || $[1] !== className || $[2] !== size || $[3] !== style) {
50940
- _t = /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(ImageAvatar, {
50972
+ _t = /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(ImageAvatar, {
50941
50973
  imageAvatar: avatar.imageAvatar,
50942
50974
  size: size,
50943
50975
  className: className,
@@ -50956,7 +50988,7 @@ var Avatar6 = function(t0) {
50956
50988
  if (avatar.type === AvatarType.ICON && avatar.iconAvatar) {
50957
50989
  var _t2;
50958
50990
  if ($[5] !== avatar.iconAvatar || $[6] !== className || $[7] !== size || $[8] !== style) {
50959
- _t2 = /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(IconAvatar, {
50991
+ _t2 = /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(IconAvatar, {
50960
50992
  iconAvatar: avatar.iconAvatar,
50961
50993
  size: size,
50962
50994
  className: className,
@@ -50975,7 +51007,7 @@ var Avatar6 = function(t0) {
50975
51007
  }
50976
51008
  var t2;
50977
51009
  if ($[10] !== className || $[11] !== size || $[12] !== style) {
50978
- t2 = /* @__PURE__ */ (0, import_jsx_runtime106.jsx)(import_themes69.Avatar, {
51010
+ t2 = /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(import_themes69.Avatar, {
50979
51011
  fallback: "",
50980
51012
  size: size,
50981
51013
  className: className,
@@ -50991,9 +51023,9 @@ var Avatar6 = function(t0) {
50991
51023
  return t2;
50992
51024
  };
50993
51025
  // src/components/components/ComponentsProvider.tsx
50994
- var import_react_compiler_runtime112 = require("react-compiler-runtime");
50995
- var import_react79 = require("react");
50996
- var import_jsx_runtime107 = require("react/jsx-runtime");
51026
+ var import_react_compiler_runtime113 = require("react-compiler-runtime");
51027
+ var import_react80 = require("react");
51028
+ var import_jsx_runtime108 = require("react/jsx-runtime");
50997
51029
  var _excluded9 = [
50998
51030
  "children"
50999
51031
  ];
@@ -51016,7 +51048,7 @@ function _objectWithoutPropertiesLoose9(r, e) {
51016
51048
  return t;
51017
51049
  }
51018
51050
  var ComponentsProvider = function(t0) {
51019
- var $ = (0, import_react_compiler_runtime112.c)(9);
51051
+ var $ = (0, import_react_compiler_runtime113.c)(9);
51020
51052
  var children;
51021
51053
  var rest;
51022
51054
  if ($[0] !== t0) {
@@ -51046,7 +51078,7 @@ var ComponentsProvider = function(t0) {
51046
51078
  var value = t1;
51047
51079
  var t3;
51048
51080
  if ($[6] !== children || $[7] !== value) {
51049
- t3 = /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(ComponentsContext.Provider, {
51081
+ t3 = /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(ComponentsContext.Provider, {
51050
51082
  value: value,
51051
51083
  children: children
51052
51084
  });
@@ -51059,11 +51091,11 @@ var ComponentsProvider = function(t0) {
51059
51091
  return t3;
51060
51092
  };
51061
51093
  // src/components/assistants/AssistantProvider/index.tsx
51062
- var import_react_compiler_runtime113 = require("react-compiler-runtime");
51063
- var import_jsx_runtime108 = require("react/jsx-runtime");
51094
+ var import_react_compiler_runtime114 = require("react-compiler-runtime");
51095
+ var import_jsx_runtime109 = require("react/jsx-runtime");
51064
51096
  var AssistantProvider = function(t0) {
51065
51097
  var _assistant$name;
51066
- var $ = (0, import_react_compiler_runtime113.c)(10);
51098
+ var $ = (0, import_react_compiler_runtime114.c)(10);
51067
51099
  var children = t0.children;
51068
51100
  var superinterfaceContext = useSuperinterfaceContext();
51069
51101
  var t1;
@@ -51081,7 +51113,7 @@ var AssistantProvider = function(t0) {
51081
51113
  var t3 = assistant === null || assistant === void 0 ? void 0 : assistant.avatar;
51082
51114
  var t4;
51083
51115
  if ($[2] !== t3) {
51084
- t4 = /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(Avatar6, {
51116
+ t4 = /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(Avatar6, {
51085
51117
  avatar: t3
51086
51118
  });
51087
51119
  $[2] = t3;
@@ -51091,7 +51123,7 @@ var AssistantProvider = function(t0) {
51091
51123
  }
51092
51124
  var t5;
51093
51125
  if ($[4] !== children || $[5] !== t4) {
51094
- t5 = /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(AssistantAvatarContext.Provider, {
51126
+ t5 = /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(AssistantAvatarContext.Provider, {
51095
51127
  value: t4,
51096
51128
  children: children
51097
51129
  });
@@ -51103,7 +51135,7 @@ var AssistantProvider = function(t0) {
51103
51135
  }
51104
51136
  var t6;
51105
51137
  if ($[7] !== t2 || $[8] !== t5) {
51106
- t6 = /* @__PURE__ */ (0, import_jsx_runtime108.jsx)(AssistantNameContext.Provider, {
51138
+ t6 = /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(AssistantNameContext.Provider, {
51107
51139
  value: t2,
51108
51140
  children: t5
51109
51141
  });