@superinterface/react 4.4.0 → 5.0.0-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 +543 -498
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +6 -4
- package/dist/index.d.ts +6 -4
- package/dist/index.js +519 -474
- package/dist/index.js.map +1 -1
- package/dist/server.cjs +31 -35
- package/dist/server.cjs.map +1 -1
- package/dist/server.js +31 -35
- package/dist/server.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -8292,7 +8292,7 @@ var require_lib = __commonJS({
|
|
|
8292
8292
|
key: "parseMaybeAssign",
|
|
8293
8293
|
value: function parseMaybeAssign(refExpressionErrors, afterLeftParse) {
|
|
8294
8294
|
var _this = this;
|
|
8295
|
-
var
|
|
8295
|
+
var _jsx109;
|
|
8296
8296
|
var state = null;
|
|
8297
8297
|
var jsx2;
|
|
8298
8298
|
if (this.hasPlugin("jsx") && (this.match(143) || this.match(47))) {
|
|
@@ -8307,7 +8307,7 @@ var require_lib = __commonJS({
|
|
|
8307
8307
|
context.pop();
|
|
8308
8308
|
}
|
|
8309
8309
|
}
|
|
8310
|
-
if ((
|
|
8310
|
+
if ((_jsx109 = jsx2) != null && _jsx109.error || this.match(47)) {
|
|
8311
8311
|
var _jsx210, _jsx310;
|
|
8312
8312
|
state = state || this.state.clone();
|
|
8313
8313
|
var typeParameters;
|
|
@@ -13173,7 +13173,7 @@ var require_lib = __commonJS({
|
|
|
13173
13173
|
key: "parseMaybeAssign",
|
|
13174
13174
|
value: function parseMaybeAssign(refExpressionErrors, afterLeftParse) {
|
|
13175
13175
|
var _this = this;
|
|
13176
|
-
var
|
|
13176
|
+
var _jsx109, _jsx210, _typeCast, _jsx310, _typeCast2;
|
|
13177
13177
|
var state;
|
|
13178
13178
|
var jsx2;
|
|
13179
13179
|
var typeCast;
|
|
@@ -13189,7 +13189,7 @@ var require_lib = __commonJS({
|
|
|
13189
13189
|
context.pop();
|
|
13190
13190
|
}
|
|
13191
13191
|
}
|
|
13192
|
-
if (!((
|
|
13192
|
+
if (!((_jsx109 = jsx2) != null && _jsx109.error) && !this.match(47)) {
|
|
13193
13193
|
return _get(_get_prototype_of(TypeScriptParserMixin.prototype), "parseMaybeAssign", this).call(this, refExpressionErrors, afterLeftParse);
|
|
13194
13194
|
}
|
|
13195
13195
|
if (!state || state === this.state) state = this.state.clone();
|
|
@@ -37811,16 +37811,16 @@ var SuperinterfaceProvider = function(_ref) {
|
|
|
37811
37811
|
});
|
|
37812
37812
|
};
|
|
37813
37813
|
// src/components/threads/Thread/index.tsx
|
|
37814
|
-
import { c as
|
|
37814
|
+
import { c as _c77 } from "react-compiler-runtime";
|
|
37815
37815
|
// src/components/threads/Thread/Messages/index.tsx
|
|
37816
|
-
import { c as
|
|
37816
|
+
import { c as _c66 } from "react-compiler-runtime";
|
|
37817
37817
|
import { Flex as Flex18 } from "@radix-ui/themes";
|
|
37818
37818
|
// src/components/threads/Thread/Message/index.tsx
|
|
37819
|
-
import { c as
|
|
37819
|
+
import { c as _c60 } from "react-compiler-runtime";
|
|
37820
37820
|
import { useMemo as useMemo10 } from "react";
|
|
37821
37821
|
import { Box as Box12 } from "@radix-ui/themes";
|
|
37822
37822
|
// src/components/runSteps/RunSteps/index.tsx
|
|
37823
|
-
import { c as
|
|
37823
|
+
import { c as _c56 } from "react-compiler-runtime";
|
|
37824
37824
|
import { Flex as Flex16 } from "@radix-ui/themes";
|
|
37825
37825
|
import { useContext as useContext14 } from "react";
|
|
37826
37826
|
// src/contexts/components/ComponentsContext/index.tsx
|
|
@@ -42955,23 +42955,42 @@ var ImageFileContent = function(t0) {
|
|
|
42955
42955
|
}
|
|
42956
42956
|
return t2;
|
|
42957
42957
|
};
|
|
42958
|
+
// src/components/contents/ImageUrlContent.tsx
|
|
42959
|
+
import { c as _c45 } from "react-compiler-runtime";
|
|
42960
|
+
import { jsx as _jsx45 } from "react/jsx-runtime";
|
|
42961
|
+
var ImageUrlContent = function(t0) {
|
|
42962
|
+
var $ = _c45(2);
|
|
42963
|
+
var content2 = t0.content;
|
|
42964
|
+
var t1;
|
|
42965
|
+
if ($[0] !== content2.image_url.url) {
|
|
42966
|
+
t1 = /* @__PURE__ */ _jsx45(Image, {
|
|
42967
|
+
alt: "",
|
|
42968
|
+
src: content2.image_url.url
|
|
42969
|
+
});
|
|
42970
|
+
$[0] = content2.image_url.url;
|
|
42971
|
+
$[1] = t1;
|
|
42972
|
+
} else {
|
|
42973
|
+
t1 = $[1];
|
|
42974
|
+
}
|
|
42975
|
+
return t1;
|
|
42976
|
+
};
|
|
42958
42977
|
// src/components/messageGroups/MessageGroup/index.tsx
|
|
42959
|
-
import { c as
|
|
42978
|
+
import { c as _c51 } from "react-compiler-runtime";
|
|
42960
42979
|
import { useContext as useContext12 } from "react";
|
|
42961
42980
|
import { Box as Box9 } from "@radix-ui/themes";
|
|
42962
42981
|
// src/components/messageGroups/MessageGroup/Name.tsx
|
|
42963
|
-
import { c as
|
|
42982
|
+
import { c as _c46 } from "react-compiler-runtime";
|
|
42964
42983
|
import { Flex as Flex9, Text as Text6 } from "@radix-ui/themes";
|
|
42965
|
-
import { jsx as
|
|
42984
|
+
import { jsx as _jsx46 } from "react/jsx-runtime";
|
|
42966
42985
|
var Name = function(t0) {
|
|
42967
|
-
var $ =
|
|
42986
|
+
var $ = _c46(2);
|
|
42968
42987
|
var children = t0.children;
|
|
42969
42988
|
var t1;
|
|
42970
42989
|
if ($[0] !== children) {
|
|
42971
|
-
t1 = /* @__PURE__ */
|
|
42990
|
+
t1 = /* @__PURE__ */ _jsx46(Flex9, {
|
|
42972
42991
|
align: "center",
|
|
42973
42992
|
height: "var(--space-5)",
|
|
42974
|
-
children: /* @__PURE__ */
|
|
42993
|
+
children: /* @__PURE__ */ _jsx46(Text6, {
|
|
42975
42994
|
size: "2",
|
|
42976
42995
|
weight: "bold",
|
|
42977
42996
|
children: children
|
|
@@ -42985,20 +43004,20 @@ var Name = function(t0) {
|
|
|
42985
43004
|
return t1;
|
|
42986
43005
|
};
|
|
42987
43006
|
// src/components/messageGroups/MessageGroup/AssistantAvatar.tsx
|
|
42988
|
-
import { c as
|
|
43007
|
+
import { c as _c47 } from "react-compiler-runtime";
|
|
42989
43008
|
import { useContext as useContext10 } from "react";
|
|
42990
43009
|
import { Flex as Flex10 } from "@radix-ui/themes";
|
|
42991
43010
|
// src/contexts/assistants/AssistantAvatarContext/index.tsx
|
|
42992
43011
|
import { createContext as createContext6 } from "react";
|
|
42993
43012
|
import { Avatar } from "@radix-ui/themes";
|
|
42994
43013
|
import { LightningBoltIcon } from "@radix-ui/react-icons";
|
|
42995
|
-
import { jsx as
|
|
42996
|
-
var AssistantAvatarContext = /* @__PURE__ */ createContext6(/* @__PURE__ */
|
|
42997
|
-
fallback: /* @__PURE__ */
|
|
43014
|
+
import { jsx as _jsx47 } from "react/jsx-runtime";
|
|
43015
|
+
var AssistantAvatarContext = /* @__PURE__ */ createContext6(/* @__PURE__ */ _jsx47(Avatar, {
|
|
43016
|
+
fallback: /* @__PURE__ */ _jsx47(LightningBoltIcon, {}),
|
|
42998
43017
|
size: "1"
|
|
42999
43018
|
}));
|
|
43000
43019
|
// src/components/messageGroups/MessageGroup/AssistantAvatar.tsx
|
|
43001
|
-
import { jsx as
|
|
43020
|
+
import { jsx as _jsx48 } from "react/jsx-runtime";
|
|
43002
43021
|
function ownKeys25(e, r) {
|
|
43003
43022
|
var t = Object.keys(e);
|
|
43004
43023
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -43043,7 +43062,7 @@ function _toPrimitive25(t, r) {
|
|
|
43043
43062
|
return ("string" === r ? String : Number)(t);
|
|
43044
43063
|
}
|
|
43045
43064
|
var Root2 = function(t0) {
|
|
43046
|
-
var $ =
|
|
43065
|
+
var $ = _c47(6);
|
|
43047
43066
|
var children = t0.children, style = t0.style, className = t0.className;
|
|
43048
43067
|
var t1;
|
|
43049
43068
|
if ($[0] !== style) {
|
|
@@ -43058,7 +43077,7 @@ var Root2 = function(t0) {
|
|
|
43058
43077
|
}
|
|
43059
43078
|
var t2;
|
|
43060
43079
|
if ($[2] !== children || $[3] !== className || $[4] !== t1) {
|
|
43061
|
-
t2 = /* @__PURE__ */
|
|
43080
|
+
t2 = /* @__PURE__ */ _jsx48(Flex10, {
|
|
43062
43081
|
flexShrink: "0",
|
|
43063
43082
|
height: "24px",
|
|
43064
43083
|
width: "24px",
|
|
@@ -43076,12 +43095,12 @@ var Root2 = function(t0) {
|
|
|
43076
43095
|
return t2;
|
|
43077
43096
|
};
|
|
43078
43097
|
var AssistantAvatar = function(t0) {
|
|
43079
|
-
var $ =
|
|
43098
|
+
var $ = _c47(4);
|
|
43080
43099
|
var style = t0.style, className = t0.className;
|
|
43081
43100
|
var AssistantAvatarContextValue = useContext10(AssistantAvatarContext);
|
|
43082
43101
|
var t1;
|
|
43083
43102
|
if ($[0] !== AssistantAvatarContextValue || $[1] !== className || $[2] !== style) {
|
|
43084
|
-
t1 = /* @__PURE__ */
|
|
43103
|
+
t1 = /* @__PURE__ */ _jsx48(Root2, {
|
|
43085
43104
|
style: style,
|
|
43086
43105
|
className: className,
|
|
43087
43106
|
children: AssistantAvatarContextValue
|
|
@@ -43100,22 +43119,22 @@ AssistantAvatar.Root = Root2;
|
|
|
43100
43119
|
import { createContext as createContext7 } from "react";
|
|
43101
43120
|
var AssistantNameContext = /* @__PURE__ */ createContext7("Assistant");
|
|
43102
43121
|
// src/components/messageGroups/MessageGroup/UserAvatar.tsx
|
|
43103
|
-
import { c as
|
|
43122
|
+
import { c as _c48 } from "react-compiler-runtime";
|
|
43104
43123
|
import { useContext as useContext11 } from "react";
|
|
43105
43124
|
import { Flex as Flex11 } from "@radix-ui/themes";
|
|
43106
43125
|
// src/contexts/users/UserAvatarContext/index.tsx
|
|
43107
43126
|
import { createContext as createContext8 } from "react";
|
|
43108
43127
|
import { Avatar as Avatar2 } from "@radix-ui/themes";
|
|
43109
43128
|
import { PersonIcon } from "@radix-ui/react-icons";
|
|
43110
|
-
import { jsx as
|
|
43111
|
-
var UserAvatarContext = /* @__PURE__ */ createContext8(/* @__PURE__ */
|
|
43112
|
-
fallback: /* @__PURE__ */
|
|
43129
|
+
import { jsx as _jsx49 } from "react/jsx-runtime";
|
|
43130
|
+
var UserAvatarContext = /* @__PURE__ */ createContext8(/* @__PURE__ */ _jsx49(Avatar2, {
|
|
43131
|
+
fallback: /* @__PURE__ */ _jsx49(PersonIcon, {}),
|
|
43113
43132
|
size: "1"
|
|
43114
43133
|
}));
|
|
43115
43134
|
// src/components/messageGroups/MessageGroup/UserAvatar.tsx
|
|
43116
|
-
import { jsx as
|
|
43135
|
+
import { jsx as _jsx50 } from "react/jsx-runtime";
|
|
43117
43136
|
var UserAvatar = function() {
|
|
43118
|
-
var $ =
|
|
43137
|
+
var $ = _c48(3);
|
|
43119
43138
|
var UserAvatarContextValue = useContext11(UserAvatarContext);
|
|
43120
43139
|
var t0;
|
|
43121
43140
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
@@ -43129,7 +43148,7 @@ var UserAvatar = function() {
|
|
|
43129
43148
|
}
|
|
43130
43149
|
var t1;
|
|
43131
43150
|
if ($[1] !== UserAvatarContextValue) {
|
|
43132
|
-
t1 = /* @__PURE__ */
|
|
43151
|
+
t1 = /* @__PURE__ */ _jsx50(Flex11, {
|
|
43133
43152
|
flexShrink: "0",
|
|
43134
43153
|
height: "24px",
|
|
43135
43154
|
width: "24px",
|
|
@@ -43144,11 +43163,11 @@ var UserAvatar = function() {
|
|
|
43144
43163
|
return t1;
|
|
43145
43164
|
};
|
|
43146
43165
|
// src/components/messageGroups/MessageGroup/Messages.tsx
|
|
43147
|
-
import { c as
|
|
43166
|
+
import { c as _c49 } from "react-compiler-runtime";
|
|
43148
43167
|
import { Flex as Flex12 } from "@radix-ui/themes";
|
|
43149
|
-
import { jsx as
|
|
43168
|
+
import { jsx as _jsx51 } from "react/jsx-runtime";
|
|
43150
43169
|
var Messages = function(t0) {
|
|
43151
|
-
var $ =
|
|
43170
|
+
var $ = _c49(4);
|
|
43152
43171
|
var messageGroup = t0.messageGroup;
|
|
43153
43172
|
var t1;
|
|
43154
43173
|
if ($[0] !== messageGroup.messages) {
|
|
@@ -43160,7 +43179,7 @@ var Messages = function(t0) {
|
|
|
43160
43179
|
}
|
|
43161
43180
|
var t2;
|
|
43162
43181
|
if ($[2] !== t1) {
|
|
43163
|
-
t2 = /* @__PURE__ */
|
|
43182
|
+
t2 = /* @__PURE__ */ _jsx51(Flex12, {
|
|
43164
43183
|
direction: "column-reverse",
|
|
43165
43184
|
children: t1
|
|
43166
43185
|
});
|
|
@@ -43172,21 +43191,21 @@ var Messages = function(t0) {
|
|
|
43172
43191
|
return t2;
|
|
43173
43192
|
};
|
|
43174
43193
|
function _temp(message) {
|
|
43175
|
-
return /* @__PURE__ */
|
|
43194
|
+
return /* @__PURE__ */ _jsx51(Message, {
|
|
43176
43195
|
message: message
|
|
43177
43196
|
}, message.id);
|
|
43178
43197
|
}
|
|
43179
43198
|
// src/components/messageGroups/MessageGroup/Root.tsx
|
|
43180
|
-
import { c as
|
|
43199
|
+
import { c as _c50 } from "react-compiler-runtime";
|
|
43181
43200
|
import { forwardRef as forwardRef2 } from "react";
|
|
43182
43201
|
import { Flex as Flex13, Container } from "@radix-ui/themes";
|
|
43183
|
-
import { jsx as
|
|
43202
|
+
import { jsx as _jsx52 } from "react/jsx-runtime";
|
|
43184
43203
|
var Root3 = /* @__PURE__ */ forwardRef2(function Root4(t0, ref) {
|
|
43185
|
-
var $ =
|
|
43204
|
+
var $ = _c50(7);
|
|
43186
43205
|
var children = t0.children, style = t0.style, className = t0.className;
|
|
43187
43206
|
var t1;
|
|
43188
43207
|
if ($[0] !== children) {
|
|
43189
|
-
t1 = /* @__PURE__ */
|
|
43208
|
+
t1 = /* @__PURE__ */ _jsx52(Flex13, {
|
|
43190
43209
|
flexShrink: "0",
|
|
43191
43210
|
gap: "3",
|
|
43192
43211
|
children: children
|
|
@@ -43198,7 +43217,7 @@ var Root3 = /* @__PURE__ */ forwardRef2(function Root4(t0, ref) {
|
|
|
43198
43217
|
}
|
|
43199
43218
|
var t2;
|
|
43200
43219
|
if ($[2] !== className || $[3] !== ref || $[4] !== style || $[5] !== t1) {
|
|
43201
|
-
t2 = /* @__PURE__ */
|
|
43220
|
+
t2 = /* @__PURE__ */ _jsx52(Container, {
|
|
43202
43221
|
ref: ref,
|
|
43203
43222
|
size: "2",
|
|
43204
43223
|
flexGrow: "0",
|
|
@@ -43217,14 +43236,14 @@ var Root3 = /* @__PURE__ */ forwardRef2(function Root4(t0, ref) {
|
|
|
43217
43236
|
return t2;
|
|
43218
43237
|
});
|
|
43219
43238
|
// src/components/messageGroups/MessageGroup/index.tsx
|
|
43220
|
-
import { jsx as
|
|
43239
|
+
import { jsx as _jsx53, jsxs as _jsxs14, Fragment as _Fragment2 } from "react/jsx-runtime";
|
|
43221
43240
|
var Content5 = function(t0) {
|
|
43222
|
-
var $ =
|
|
43241
|
+
var $ = _c51(12);
|
|
43223
43242
|
var messageGroup = t0.messageGroup;
|
|
43224
43243
|
var assistantNameContext = useContext12(AssistantNameContext);
|
|
43225
43244
|
var t1;
|
|
43226
43245
|
if ($[0] !== messageGroup.role) {
|
|
43227
|
-
t1 = messageGroup.role === "user" ? /* @__PURE__ */
|
|
43246
|
+
t1 = messageGroup.role === "user" ? /* @__PURE__ */ _jsx53(UserAvatar, {}) : /* @__PURE__ */ _jsx53(AssistantAvatar, {});
|
|
43228
43247
|
$[0] = messageGroup.role;
|
|
43229
43248
|
$[1] = t1;
|
|
43230
43249
|
} else {
|
|
@@ -43233,7 +43252,7 @@ var Content5 = function(t0) {
|
|
|
43233
43252
|
var t2 = messageGroup.role === "user" ? "You" : assistantNameContext;
|
|
43234
43253
|
var t3;
|
|
43235
43254
|
if ($[2] !== t2) {
|
|
43236
|
-
t3 = /* @__PURE__ */
|
|
43255
|
+
t3 = /* @__PURE__ */ _jsx53(Name, {
|
|
43237
43256
|
children: t2
|
|
43238
43257
|
});
|
|
43239
43258
|
$[2] = t2;
|
|
@@ -43243,7 +43262,7 @@ var Content5 = function(t0) {
|
|
|
43243
43262
|
}
|
|
43244
43263
|
var t4;
|
|
43245
43264
|
if ($[4] !== messageGroup) {
|
|
43246
|
-
t4 = /* @__PURE__ */
|
|
43265
|
+
t4 = /* @__PURE__ */ _jsx53(Messages, {
|
|
43247
43266
|
messageGroup: messageGroup
|
|
43248
43267
|
});
|
|
43249
43268
|
$[4] = messageGroup;
|
|
@@ -43283,11 +43302,11 @@ var Content5 = function(t0) {
|
|
|
43283
43302
|
return t6;
|
|
43284
43303
|
};
|
|
43285
43304
|
var MessageGroup = function(t0) {
|
|
43286
|
-
var $ =
|
|
43305
|
+
var $ = _c51(6);
|
|
43287
43306
|
var messageGroup = t0.messageGroup, style = t0.style, className = t0.className;
|
|
43288
43307
|
var t1;
|
|
43289
43308
|
if ($[0] !== messageGroup) {
|
|
43290
|
-
t1 = /* @__PURE__ */
|
|
43309
|
+
t1 = /* @__PURE__ */ _jsx53(Content5, {
|
|
43291
43310
|
messageGroup: messageGroup
|
|
43292
43311
|
});
|
|
43293
43312
|
$[0] = messageGroup;
|
|
@@ -43297,7 +43316,7 @@ var MessageGroup = function(t0) {
|
|
|
43297
43316
|
}
|
|
43298
43317
|
var t2;
|
|
43299
43318
|
if ($[2] !== className || $[3] !== style || $[4] !== t1) {
|
|
43300
|
-
t2 = /* @__PURE__ */
|
|
43319
|
+
t2 = /* @__PURE__ */ _jsx53(Root3, {
|
|
43301
43320
|
className: className,
|
|
43302
43321
|
style: style,
|
|
43303
43322
|
children: t1
|
|
@@ -43318,20 +43337,20 @@ MessageGroup.UserAvatar = UserAvatar;
|
|
|
43318
43337
|
MessageGroup.Messages = Messages;
|
|
43319
43338
|
MessageGroup.Content = Content5;
|
|
43320
43339
|
// src/components/messages/MessageAttachments.tsx
|
|
43321
|
-
import { c as
|
|
43340
|
+
import { c as _c52 } from "react-compiler-runtime";
|
|
43322
43341
|
import { Flex as Flex14, Badge as Badge2 } from "@radix-ui/themes";
|
|
43323
43342
|
import { FileIcon } from "@radix-ui/react-icons";
|
|
43324
|
-
import { jsx as
|
|
43343
|
+
import { jsx as _jsx54, jsxs as _jsxs15 } from "react/jsx-runtime";
|
|
43325
43344
|
var MessageAttachments = function(t0) {
|
|
43326
43345
|
var _message$attachments;
|
|
43327
|
-
var $ =
|
|
43346
|
+
var $ = _c52(4);
|
|
43328
43347
|
var message = t0.message;
|
|
43329
43348
|
if (!((_message$attachments = message.attachments) !== null && _message$attachments !== void 0 && _message$attachments.length)) {
|
|
43330
43349
|
return null;
|
|
43331
43350
|
}
|
|
43332
43351
|
var t1;
|
|
43333
43352
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43334
|
-
t1 = /* @__PURE__ */
|
|
43353
|
+
t1 = /* @__PURE__ */ _jsx54(FileIcon, {});
|
|
43335
43354
|
$[0] = t1;
|
|
43336
43355
|
} else {
|
|
43337
43356
|
t1 = $[0];
|
|
@@ -43339,7 +43358,7 @@ var MessageAttachments = function(t0) {
|
|
|
43339
43358
|
var t2 = message.attachments.length > 1 ? "s" : "";
|
|
43340
43359
|
var t3;
|
|
43341
43360
|
if ($[1] !== message.attachments.length || $[2] !== t2) {
|
|
43342
|
-
t3 = /* @__PURE__ */
|
|
43361
|
+
t3 = /* @__PURE__ */ _jsx54(Flex14, {
|
|
43343
43362
|
align: "start",
|
|
43344
43363
|
pb: "1",
|
|
43345
43364
|
children: /* @__PURE__ */ _jsxs15(Badge2, {
|
|
@@ -43362,18 +43381,18 @@ var MessageAttachments = function(t0) {
|
|
|
43362
43381
|
return t3;
|
|
43363
43382
|
};
|
|
43364
43383
|
// src/components/skeletons/StartingSkeleton/index.tsx
|
|
43365
|
-
import { c as
|
|
43384
|
+
import { c as _c54 } from "react-compiler-runtime";
|
|
43366
43385
|
import { useContext as useContext13 } from "react";
|
|
43367
43386
|
import { Box as Box10 } from "@radix-ui/themes";
|
|
43368
43387
|
// src/components/skeletons/StartingContentSkeleton/index.tsx
|
|
43369
|
-
import { c as
|
|
43388
|
+
import { c as _c53 } from "react-compiler-runtime";
|
|
43370
43389
|
import { Skeleton } from "@radix-ui/themes";
|
|
43371
|
-
import { jsx as
|
|
43390
|
+
import { jsx as _jsx55 } from "react/jsx-runtime";
|
|
43372
43391
|
var StartingContentSkeleton = function() {
|
|
43373
|
-
var $ =
|
|
43392
|
+
var $ = _c53(1);
|
|
43374
43393
|
var t0;
|
|
43375
43394
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43376
|
-
t0 = /* @__PURE__ */
|
|
43395
|
+
t0 = /* @__PURE__ */ _jsx55(Skeleton, {
|
|
43377
43396
|
loading: true,
|
|
43378
43397
|
mt: "1",
|
|
43379
43398
|
height: "var(--space-4)",
|
|
@@ -43390,13 +43409,13 @@ var StartingContentSkeleton = function() {
|
|
|
43390
43409
|
return t0;
|
|
43391
43410
|
};
|
|
43392
43411
|
// src/components/skeletons/StartingSkeleton/index.tsx
|
|
43393
|
-
import { jsx as
|
|
43412
|
+
import { jsx as _jsx56, jsxs as _jsxs16 } from "react/jsx-runtime";
|
|
43394
43413
|
var StartingSkeleton = function(t0) {
|
|
43395
|
-
var $ =
|
|
43414
|
+
var $ = _c54(3);
|
|
43396
43415
|
var children = t0.children;
|
|
43397
43416
|
var t1;
|
|
43398
43417
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43399
|
-
t1 = /* @__PURE__ */
|
|
43418
|
+
t1 = /* @__PURE__ */ _jsx56(Content6, {});
|
|
43400
43419
|
$[0] = t1;
|
|
43401
43420
|
} else {
|
|
43402
43421
|
t1 = $[0];
|
|
@@ -43417,19 +43436,19 @@ var StartingSkeleton = function(t0) {
|
|
|
43417
43436
|
return t2;
|
|
43418
43437
|
};
|
|
43419
43438
|
var Root5 = function(t0) {
|
|
43420
|
-
var $ =
|
|
43439
|
+
var $ = _c54(6);
|
|
43421
43440
|
var children = t0.children;
|
|
43422
43441
|
var assistantNameContext = useContext13(AssistantNameContext);
|
|
43423
43442
|
var t1;
|
|
43424
43443
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43425
|
-
t1 = /* @__PURE__ */
|
|
43444
|
+
t1 = /* @__PURE__ */ _jsx56(MessageGroup.AssistantAvatar, {});
|
|
43426
43445
|
$[0] = t1;
|
|
43427
43446
|
} else {
|
|
43428
43447
|
t1 = $[0];
|
|
43429
43448
|
}
|
|
43430
43449
|
var t2;
|
|
43431
43450
|
if ($[1] !== assistantNameContext) {
|
|
43432
|
-
t2 = /* @__PURE__ */
|
|
43451
|
+
t2 = /* @__PURE__ */ _jsx56(MessageGroup.Name, {
|
|
43433
43452
|
children: assistantNameContext
|
|
43434
43453
|
});
|
|
43435
43454
|
$[1] = assistantNameContext;
|
|
@@ -43462,18 +43481,18 @@ var Content6 = StartingContentSkeleton;
|
|
|
43462
43481
|
StartingSkeleton.Root = Root5;
|
|
43463
43482
|
StartingSkeleton.Content = Content6;
|
|
43464
43483
|
// src/components/skeletons/MessagesSkeleton/index.tsx
|
|
43465
|
-
import { c as
|
|
43484
|
+
import { c as _c55 } from "react-compiler-runtime";
|
|
43466
43485
|
import { forwardRef as forwardRef3 } from "react";
|
|
43467
43486
|
import { Flex as Flex15, Avatar as Avatar3, Box as Box11, Skeleton as Skeleton2 } from "@radix-ui/themes";
|
|
43468
|
-
import { jsx as
|
|
43487
|
+
import { jsx as _jsx57, jsxs as _jsxs17 } from "react/jsx-runtime";
|
|
43469
43488
|
var MessagesSkeleton = /* @__PURE__ */ forwardRef3(function MessagesSkeleton2(_props, ref) {
|
|
43470
|
-
var $ =
|
|
43489
|
+
var $ = _c55(7);
|
|
43471
43490
|
var t0;
|
|
43472
43491
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43473
|
-
t0 = /* @__PURE__ */
|
|
43492
|
+
t0 = /* @__PURE__ */ _jsx57(Skeleton2, {
|
|
43474
43493
|
loading: true,
|
|
43475
|
-
children: /* @__PURE__ */
|
|
43476
|
-
fallback: /* @__PURE__ */
|
|
43494
|
+
children: /* @__PURE__ */ _jsx57(Avatar3, {
|
|
43495
|
+
fallback: /* @__PURE__ */ _jsx57(Flex15, {}),
|
|
43477
43496
|
size: "1"
|
|
43478
43497
|
})
|
|
43479
43498
|
});
|
|
@@ -43483,8 +43502,8 @@ var MessagesSkeleton = /* @__PURE__ */ forwardRef3(function MessagesSkeleton2(_p
|
|
|
43483
43502
|
}
|
|
43484
43503
|
var t1;
|
|
43485
43504
|
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43486
|
-
t1 = /* @__PURE__ */
|
|
43487
|
-
children: /* @__PURE__ */
|
|
43505
|
+
t1 = /* @__PURE__ */ _jsx57(MessageGroup.Name, {
|
|
43506
|
+
children: /* @__PURE__ */ _jsx57(Skeleton2, {
|
|
43488
43507
|
loading: true,
|
|
43489
43508
|
style: {
|
|
43490
43509
|
width: "128px"
|
|
@@ -43497,7 +43516,7 @@ var MessagesSkeleton = /* @__PURE__ */ forwardRef3(function MessagesSkeleton2(_p
|
|
|
43497
43516
|
}
|
|
43498
43517
|
var t2;
|
|
43499
43518
|
if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43500
|
-
t2 = /* @__PURE__ */
|
|
43519
|
+
t2 = /* @__PURE__ */ _jsx57(Skeleton2, {
|
|
43501
43520
|
loading: true,
|
|
43502
43521
|
style: {
|
|
43503
43522
|
width: "256px"
|
|
@@ -43509,7 +43528,7 @@ var MessagesSkeleton = /* @__PURE__ */ forwardRef3(function MessagesSkeleton2(_p
|
|
|
43509
43528
|
}
|
|
43510
43529
|
var t3;
|
|
43511
43530
|
if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
|
|
43512
|
-
t3 = /* @__PURE__ */
|
|
43531
|
+
t3 = /* @__PURE__ */ _jsx57(Skeleton2, {
|
|
43513
43532
|
loading: true,
|
|
43514
43533
|
style: {
|
|
43515
43534
|
width: "256px",
|
|
@@ -43528,7 +43547,7 @@ var MessagesSkeleton = /* @__PURE__ */ forwardRef3(function MessagesSkeleton2(_p
|
|
|
43528
43547
|
t1,
|
|
43529
43548
|
t2,
|
|
43530
43549
|
t3,
|
|
43531
|
-
/* @__PURE__ */
|
|
43550
|
+
/* @__PURE__ */ _jsx57(Skeleton2, {
|
|
43532
43551
|
loading: true,
|
|
43533
43552
|
style: {
|
|
43534
43553
|
width: "256px",
|
|
@@ -43568,6 +43587,7 @@ var ComponentsContext = /* @__PURE__ */ createContext9({
|
|
|
43568
43587
|
FallbackToolCall: FallbackToolCall,
|
|
43569
43588
|
TextContent: TextContent,
|
|
43570
43589
|
ImageFileContent: ImageFileContent,
|
|
43590
|
+
ImageUrlContent: ImageUrlContent,
|
|
43571
43591
|
MessageGroup: MessageGroup,
|
|
43572
43592
|
MessageAttachments: MessageAttachments,
|
|
43573
43593
|
StartingSkeleton: StartingSkeleton,
|
|
@@ -43576,9 +43596,9 @@ var ComponentsContext = /* @__PURE__ */ createContext9({
|
|
|
43576
43596
|
}
|
|
43577
43597
|
});
|
|
43578
43598
|
// src/components/runSteps/RunSteps/index.tsx
|
|
43579
|
-
import { jsx as
|
|
43599
|
+
import { jsx as _jsx58 } from "react/jsx-runtime";
|
|
43580
43600
|
var RunSteps = function(t0) {
|
|
43581
|
-
var $ =
|
|
43601
|
+
var $ = _c56(7);
|
|
43582
43602
|
var runSteps = t0.runSteps;
|
|
43583
43603
|
var componentsContext = useContext14(ComponentsContext);
|
|
43584
43604
|
var Component2 = componentsContext.components.RunStep;
|
|
@@ -43587,7 +43607,7 @@ var RunSteps = function(t0) {
|
|
|
43587
43607
|
var _t;
|
|
43588
43608
|
if ($[3] !== Component2) {
|
|
43589
43609
|
_t = function(runStep) {
|
|
43590
|
-
return /* @__PURE__ */
|
|
43610
|
+
return /* @__PURE__ */ _jsx58(Component2, {
|
|
43591
43611
|
runStep: runStep
|
|
43592
43612
|
}, runStep.id);
|
|
43593
43613
|
};
|
|
@@ -43605,7 +43625,7 @@ var RunSteps = function(t0) {
|
|
|
43605
43625
|
}
|
|
43606
43626
|
var t2;
|
|
43607
43627
|
if ($[5] !== t1) {
|
|
43608
|
-
t2 = /* @__PURE__ */
|
|
43628
|
+
t2 = /* @__PURE__ */ _jsx58(Flex16, {
|
|
43609
43629
|
direction: "column-reverse",
|
|
43610
43630
|
children: t1
|
|
43611
43631
|
});
|
|
@@ -43624,16 +43644,16 @@ var MessageContext = /* @__PURE__ */ createContext10({
|
|
|
43624
43644
|
// src/components/threads/Thread/Message/Provider.tsx
|
|
43625
43645
|
var Provider = MessageContext.Provider;
|
|
43626
43646
|
// src/components/threads/Thread/Message/Attachments/index.tsx
|
|
43627
|
-
import { c as
|
|
43628
|
-
import { jsx as
|
|
43647
|
+
import { c as _c57 } from "react-compiler-runtime";
|
|
43648
|
+
import { jsx as _jsx59 } from "react/jsx-runtime";
|
|
43629
43649
|
var Attachments = function(t0) {
|
|
43630
|
-
var $ =
|
|
43650
|
+
var $ = _c57(3);
|
|
43631
43651
|
var message = t0.message;
|
|
43632
43652
|
var _useComponents = useComponents(), t1 = _useComponents.components;
|
|
43633
43653
|
var MessageAttachments2 = t1.MessageAttachments;
|
|
43634
43654
|
var t2;
|
|
43635
43655
|
if ($[0] !== MessageAttachments2 || $[1] !== message) {
|
|
43636
|
-
t2 = /* @__PURE__ */
|
|
43656
|
+
t2 = /* @__PURE__ */ _jsx59(MessageAttachments2, {
|
|
43637
43657
|
message: message
|
|
43638
43658
|
});
|
|
43639
43659
|
$[0] = MessageAttachments2;
|
|
@@ -43645,18 +43665,18 @@ var Attachments = function(t0) {
|
|
|
43645
43665
|
return t2;
|
|
43646
43666
|
};
|
|
43647
43667
|
// src/components/messages/MessageContent/index.tsx
|
|
43648
|
-
import { c as
|
|
43668
|
+
import { c as _c59 } from "react-compiler-runtime";
|
|
43649
43669
|
// src/components/messages/MessageContent/ContentPart/index.tsx
|
|
43650
|
-
import { c as
|
|
43651
|
-
import { jsx as
|
|
43670
|
+
import { c as _c58 } from "react-compiler-runtime";
|
|
43671
|
+
import { jsx as _jsx60 } from "react/jsx-runtime";
|
|
43652
43672
|
var TextContent2 = function(t0) {
|
|
43653
|
-
var $ =
|
|
43673
|
+
var $ = _c58(3);
|
|
43654
43674
|
var content2 = t0.content;
|
|
43655
43675
|
var _useComponents = useComponents(), t1 = _useComponents.components;
|
|
43656
43676
|
var TextContent3 = t1.TextContent;
|
|
43657
43677
|
var t2;
|
|
43658
43678
|
if ($[0] !== TextContent3 || $[1] !== content2) {
|
|
43659
|
-
t2 = /* @__PURE__ */
|
|
43679
|
+
t2 = /* @__PURE__ */ _jsx60(TextContent3, {
|
|
43660
43680
|
content: content2
|
|
43661
43681
|
});
|
|
43662
43682
|
$[0] = TextContent3;
|
|
@@ -43668,13 +43688,13 @@ var TextContent2 = function(t0) {
|
|
|
43668
43688
|
return t2;
|
|
43669
43689
|
};
|
|
43670
43690
|
var ImageFileContent2 = function(t0) {
|
|
43671
|
-
var $ =
|
|
43691
|
+
var $ = _c58(3);
|
|
43672
43692
|
var content2 = t0.content;
|
|
43673
43693
|
var _useComponents = useComponents(), t1 = _useComponents.components;
|
|
43674
43694
|
var ImageFileContent3 = t1.ImageFileContent;
|
|
43675
43695
|
var t2;
|
|
43676
43696
|
if ($[0] !== ImageFileContent3 || $[1] !== content2) {
|
|
43677
|
-
t2 = /* @__PURE__ */
|
|
43697
|
+
t2 = /* @__PURE__ */ _jsx60(ImageFileContent3, {
|
|
43678
43698
|
content: content2
|
|
43679
43699
|
});
|
|
43680
43700
|
$[0] = ImageFileContent3;
|
|
@@ -43685,13 +43705,31 @@ var ImageFileContent2 = function(t0) {
|
|
|
43685
43705
|
}
|
|
43686
43706
|
return t2;
|
|
43687
43707
|
};
|
|
43708
|
+
var ImageUrlContent2 = function(t0) {
|
|
43709
|
+
var $ = _c58(3);
|
|
43710
|
+
var content2 = t0.content;
|
|
43711
|
+
var _useComponents = useComponents(), t1 = _useComponents.components;
|
|
43712
|
+
var ImageUrlContent3 = t1.ImageUrlContent;
|
|
43713
|
+
var t2;
|
|
43714
|
+
if ($[0] !== ImageUrlContent3 || $[1] !== content2) {
|
|
43715
|
+
t2 = /* @__PURE__ */ _jsx60(ImageUrlContent3, {
|
|
43716
|
+
content: content2
|
|
43717
|
+
});
|
|
43718
|
+
$[0] = ImageUrlContent3;
|
|
43719
|
+
$[1] = content2;
|
|
43720
|
+
$[2] = t2;
|
|
43721
|
+
} else {
|
|
43722
|
+
t2 = $[2];
|
|
43723
|
+
}
|
|
43724
|
+
return t2;
|
|
43725
|
+
};
|
|
43688
43726
|
var ContentPart = function(t0) {
|
|
43689
|
-
var $ =
|
|
43727
|
+
var $ = _c58(6);
|
|
43690
43728
|
var content2 = t0.content;
|
|
43691
43729
|
if (content2.type === "text") {
|
|
43692
43730
|
var t1;
|
|
43693
43731
|
if ($[0] !== content2) {
|
|
43694
|
-
t1 = /* @__PURE__ */
|
|
43732
|
+
t1 = /* @__PURE__ */ _jsx60(TextContent2, {
|
|
43695
43733
|
content: content2
|
|
43696
43734
|
});
|
|
43697
43735
|
$[0] = content2;
|
|
@@ -43704,7 +43742,7 @@ var ContentPart = function(t0) {
|
|
|
43704
43742
|
if (content2.type === "image_file") {
|
|
43705
43743
|
var _t;
|
|
43706
43744
|
if ($[2] !== content2) {
|
|
43707
|
-
_t = /* @__PURE__ */
|
|
43745
|
+
_t = /* @__PURE__ */ _jsx60(ImageFileContent2, {
|
|
43708
43746
|
content: content2
|
|
43709
43747
|
});
|
|
43710
43748
|
$[2] = content2;
|
|
@@ -43714,12 +43752,25 @@ var ContentPart = function(t0) {
|
|
|
43714
43752
|
}
|
|
43715
43753
|
return _t;
|
|
43716
43754
|
}
|
|
43755
|
+
if (content2.type === "image_url") {
|
|
43756
|
+
var _t2;
|
|
43757
|
+
if ($[4] !== content2) {
|
|
43758
|
+
_t2 = /* @__PURE__ */ _jsx60(ImageUrlContent2, {
|
|
43759
|
+
content: content2
|
|
43760
|
+
});
|
|
43761
|
+
$[4] = content2;
|
|
43762
|
+
$[5] = _t2;
|
|
43763
|
+
} else {
|
|
43764
|
+
_t2 = $[5];
|
|
43765
|
+
}
|
|
43766
|
+
return _t2;
|
|
43767
|
+
}
|
|
43717
43768
|
return null;
|
|
43718
43769
|
};
|
|
43719
43770
|
// src/components/messages/MessageContent/index.tsx
|
|
43720
|
-
import { Fragment as _Fragment3, jsx as
|
|
43771
|
+
import { Fragment as _Fragment3, jsx as _jsx61 } from "react/jsx-runtime";
|
|
43721
43772
|
var MessageContent = function(t0) {
|
|
43722
|
-
var $ =
|
|
43773
|
+
var $ = _c59(4);
|
|
43723
43774
|
var message = t0.message;
|
|
43724
43775
|
var t1;
|
|
43725
43776
|
if ($[0] !== message.content) {
|
|
@@ -43731,7 +43782,7 @@ var MessageContent = function(t0) {
|
|
|
43731
43782
|
}
|
|
43732
43783
|
var t2;
|
|
43733
43784
|
if ($[2] !== t1) {
|
|
43734
|
-
t2 = /* @__PURE__ */
|
|
43785
|
+
t2 = /* @__PURE__ */ _jsx61(_Fragment3, {
|
|
43735
43786
|
children: t1
|
|
43736
43787
|
});
|
|
43737
43788
|
$[2] = t1;
|
|
@@ -43742,14 +43793,14 @@ var MessageContent = function(t0) {
|
|
|
43742
43793
|
return t2;
|
|
43743
43794
|
};
|
|
43744
43795
|
function _temp2(content2, index) {
|
|
43745
|
-
return /* @__PURE__ */
|
|
43796
|
+
return /* @__PURE__ */ _jsx61(ContentPart, {
|
|
43746
43797
|
content: content2
|
|
43747
43798
|
}, index);
|
|
43748
43799
|
}
|
|
43749
43800
|
// src/components/threads/Thread/Message/index.tsx
|
|
43750
|
-
import { jsx as
|
|
43801
|
+
import { jsx as _jsx62, jsxs as _jsxs18 } from "react/jsx-runtime";
|
|
43751
43802
|
var Message = function(t0) {
|
|
43752
|
-
var $ =
|
|
43803
|
+
var $ = _c60(40);
|
|
43753
43804
|
var message = t0.message, className = t0.className, style = t0.style;
|
|
43754
43805
|
var t1;
|
|
43755
43806
|
bb0: {
|
|
@@ -43879,7 +43930,7 @@ var Message = function(t0) {
|
|
|
43879
43930
|
}
|
|
43880
43931
|
var t3;
|
|
43881
43932
|
if ($[24] !== olderRunSteps_0) {
|
|
43882
|
-
t3 = /* @__PURE__ */
|
|
43933
|
+
t3 = /* @__PURE__ */ _jsx62(RunSteps, {
|
|
43883
43934
|
runSteps: olderRunSteps_0
|
|
43884
43935
|
});
|
|
43885
43936
|
$[24] = olderRunSteps_0;
|
|
@@ -43901,10 +43952,10 @@ var Message = function(t0) {
|
|
|
43901
43952
|
t5 = /* @__PURE__ */ _jsxs18(Box12, {
|
|
43902
43953
|
style: t4,
|
|
43903
43954
|
children: [
|
|
43904
|
-
/* @__PURE__ */
|
|
43955
|
+
/* @__PURE__ */ _jsx62(Attachments, {
|
|
43905
43956
|
message: message
|
|
43906
43957
|
}),
|
|
43907
|
-
/* @__PURE__ */
|
|
43958
|
+
/* @__PURE__ */ _jsx62(MessageContent, {
|
|
43908
43959
|
message: message
|
|
43909
43960
|
})
|
|
43910
43961
|
]
|
|
@@ -43916,7 +43967,7 @@ var Message = function(t0) {
|
|
|
43916
43967
|
}
|
|
43917
43968
|
var t6;
|
|
43918
43969
|
if ($[29] !== laterRunSteps_0) {
|
|
43919
|
-
t6 = /* @__PURE__ */
|
|
43970
|
+
t6 = /* @__PURE__ */ _jsx62(RunSteps, {
|
|
43920
43971
|
runSteps: laterRunSteps_0
|
|
43921
43972
|
});
|
|
43922
43973
|
$[29] = laterRunSteps_0;
|
|
@@ -43946,7 +43997,7 @@ var Message = function(t0) {
|
|
|
43946
43997
|
}
|
|
43947
43998
|
var t8;
|
|
43948
43999
|
if ($[37] !== t2 || $[38] !== t7) {
|
|
43949
|
-
t8 = /* @__PURE__ */
|
|
44000
|
+
t8 = /* @__PURE__ */ _jsx62(Provider, {
|
|
43950
44001
|
value: t2,
|
|
43951
44002
|
children: t7
|
|
43952
44003
|
});
|
|
@@ -43965,10 +44016,10 @@ function _temp22(runStep_1) {
|
|
|
43965
44016
|
return runStep_1.step_details.type === "message_creation";
|
|
43966
44017
|
}
|
|
43967
44018
|
// src/components/threads/Thread/Messages/Content/index.tsx
|
|
43968
|
-
import { c as
|
|
44019
|
+
import { c as _c62 } from "react-compiler-runtime";
|
|
43969
44020
|
import { useEffect as useEffect3 } from "react";
|
|
43970
44021
|
// src/hooks/messageGroups/useMessageGroups/index.ts
|
|
43971
|
-
import { c as
|
|
44022
|
+
import { c as _c61 } from "react-compiler-runtime";
|
|
43972
44023
|
import { useMemo as useMemo11 } from "react";
|
|
43973
44024
|
// src/hooks/messageGroups/useMessageGroups/lib/messageGroups/index.ts
|
|
43974
44025
|
import _6 from "lodash";
|
|
@@ -44073,7 +44124,7 @@ var messageGroups = function(_ref) {
|
|
|
44073
44124
|
};
|
|
44074
44125
|
// src/hooks/messageGroups/useMessageGroups/index.ts
|
|
44075
44126
|
var useMessageGroups = function(t0) {
|
|
44076
|
-
var $ =
|
|
44127
|
+
var $ = _c61(4);
|
|
44077
44128
|
var messages2 = t0.messages;
|
|
44078
44129
|
var t1;
|
|
44079
44130
|
var t2;
|
|
@@ -44100,9 +44151,9 @@ var useMessageGroups = function(t0) {
|
|
|
44100
44151
|
return t1;
|
|
44101
44152
|
};
|
|
44102
44153
|
// src/components/threads/Thread/Messages/Content/index.tsx
|
|
44103
|
-
import { jsx as
|
|
44154
|
+
import { jsx as _jsx63, Fragment as _Fragment4 } from "react/jsx-runtime";
|
|
44104
44155
|
var Content7 = function() {
|
|
44105
|
-
var $ =
|
|
44156
|
+
var $ = _c62(15);
|
|
44106
44157
|
var _useMessages = useMessages(), messages2 = _useMessages.messages, isLoading = _useMessages.isLoading, isLoadingError = _useMessages.isLoadingError;
|
|
44107
44158
|
var addToast = useToasts().addToast;
|
|
44108
44159
|
var t0;
|
|
@@ -44145,7 +44196,7 @@ var Content7 = function() {
|
|
|
44145
44196
|
if (isLoading || isLoadingError) {
|
|
44146
44197
|
var _t;
|
|
44147
44198
|
if ($[6] !== MessagesSkeleton3) {
|
|
44148
|
-
_t = /* @__PURE__ */
|
|
44199
|
+
_t = /* @__PURE__ */ _jsx63(MessagesSkeleton3, {});
|
|
44149
44200
|
$[6] = MessagesSkeleton3;
|
|
44150
44201
|
$[7] = _t;
|
|
44151
44202
|
} else {
|
|
@@ -44158,7 +44209,7 @@ var Content7 = function() {
|
|
|
44158
44209
|
var _t2;
|
|
44159
44210
|
if ($[11] !== MessageGroup2) {
|
|
44160
44211
|
_t2 = function(messageGroup) {
|
|
44161
|
-
return /* @__PURE__ */
|
|
44212
|
+
return /* @__PURE__ */ _jsx63(MessageGroup2, {
|
|
44162
44213
|
messageGroup: messageGroup
|
|
44163
44214
|
}, messageGroup.id);
|
|
44164
44215
|
};
|
|
@@ -44176,7 +44227,7 @@ var Content7 = function() {
|
|
|
44176
44227
|
}
|
|
44177
44228
|
var t5;
|
|
44178
44229
|
if ($[13] !== t4) {
|
|
44179
|
-
t5 = /* @__PURE__ */
|
|
44230
|
+
t5 = /* @__PURE__ */ _jsx63(_Fragment4, {
|
|
44180
44231
|
children: t4
|
|
44181
44232
|
});
|
|
44182
44233
|
$[13] = t4;
|
|
@@ -44187,17 +44238,17 @@ var Content7 = function() {
|
|
|
44187
44238
|
return t5;
|
|
44188
44239
|
};
|
|
44189
44240
|
// src/components/threads/Thread/Messages/Progress/index.tsx
|
|
44190
|
-
import { c as
|
|
44241
|
+
import { c as _c63 } from "react-compiler-runtime";
|
|
44191
44242
|
import { useMemo as useMemo12 } from "react";
|
|
44192
44243
|
import { Box as Box13 } from "@radix-ui/themes";
|
|
44193
|
-
import { jsx as
|
|
44244
|
+
import { jsx as _jsx64, jsxs as _jsxs19 } from "react/jsx-runtime";
|
|
44194
44245
|
var StartingSkeleton2 = function() {
|
|
44195
|
-
var $ =
|
|
44246
|
+
var $ = _c63(2);
|
|
44196
44247
|
var _useComponents = useComponents(), t0 = _useComponents.components;
|
|
44197
44248
|
var StartingSkeleton3 = t0.StartingSkeleton;
|
|
44198
44249
|
var t1;
|
|
44199
44250
|
if ($[0] !== StartingSkeleton3) {
|
|
44200
|
-
t1 = /* @__PURE__ */
|
|
44251
|
+
t1 = /* @__PURE__ */ _jsx64(StartingSkeleton3, {});
|
|
44201
44252
|
$[0] = StartingSkeleton3;
|
|
44202
44253
|
$[1] = t1;
|
|
44203
44254
|
} else {
|
|
@@ -44206,12 +44257,12 @@ var StartingSkeleton2 = function() {
|
|
|
44206
44257
|
return t1;
|
|
44207
44258
|
};
|
|
44208
44259
|
var StartingContentSkeleton2 = function() {
|
|
44209
|
-
var $ =
|
|
44260
|
+
var $ = _c63(2);
|
|
44210
44261
|
var _useComponents = useComponents(), t0 = _useComponents.components;
|
|
44211
44262
|
var StartingContentSkeleton3 = t0.StartingContentSkeleton;
|
|
44212
44263
|
var t1;
|
|
44213
44264
|
if ($[0] !== StartingContentSkeleton3) {
|
|
44214
|
-
t1 = /* @__PURE__ */
|
|
44265
|
+
t1 = /* @__PURE__ */ _jsx64(StartingContentSkeleton3, {});
|
|
44215
44266
|
$[0] = StartingContentSkeleton3;
|
|
44216
44267
|
$[1] = t1;
|
|
44217
44268
|
} else {
|
|
@@ -44220,7 +44271,7 @@ var StartingContentSkeleton2 = function() {
|
|
|
44220
44271
|
return t1;
|
|
44221
44272
|
};
|
|
44222
44273
|
var Progress = function() {
|
|
44223
|
-
var $ =
|
|
44274
|
+
var $ = _c63(3);
|
|
44224
44275
|
var latestMessage = useLatestMessage().latestMessage;
|
|
44225
44276
|
var isMutatingMessage = useIsMutatingMessage();
|
|
44226
44277
|
var t0;
|
|
@@ -44253,7 +44304,7 @@ var Progress = function() {
|
|
|
44253
44304
|
if (isStartingSkeletonVisible) {
|
|
44254
44305
|
var t1;
|
|
44255
44306
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44256
|
-
t1 = /* @__PURE__ */
|
|
44307
|
+
t1 = /* @__PURE__ */ _jsx64(StartingSkeleton2, {});
|
|
44257
44308
|
$[0] = t1;
|
|
44258
44309
|
} else {
|
|
44259
44310
|
t1 = $[0];
|
|
@@ -44263,7 +44314,7 @@ var Progress = function() {
|
|
|
44263
44314
|
if (isMutatingMessage) {
|
|
44264
44315
|
var _t;
|
|
44265
44316
|
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44266
|
-
_t = /* @__PURE__ */
|
|
44317
|
+
_t = /* @__PURE__ */ _jsx64(MessageGroup.AssistantAvatar.Root, {});
|
|
44267
44318
|
$[1] = _t;
|
|
44268
44319
|
} else {
|
|
44269
44320
|
_t = $[1];
|
|
@@ -44273,8 +44324,8 @@ var Progress = function() {
|
|
|
44273
44324
|
t2 = /* @__PURE__ */ _jsxs19(MessageGroup.Root, {
|
|
44274
44325
|
children: [
|
|
44275
44326
|
_t,
|
|
44276
|
-
/* @__PURE__ */
|
|
44277
|
-
children: /* @__PURE__ */
|
|
44327
|
+
/* @__PURE__ */ _jsx64(Box13, {
|
|
44328
|
+
children: /* @__PURE__ */ _jsx64(StartingContentSkeleton2, {})
|
|
44278
44329
|
})
|
|
44279
44330
|
]
|
|
44280
44331
|
});
|
|
@@ -44287,7 +44338,7 @@ var Progress = function() {
|
|
|
44287
44338
|
return null;
|
|
44288
44339
|
};
|
|
44289
44340
|
// src/components/threads/Thread/Messages/Root/index.tsx
|
|
44290
|
-
import { c as
|
|
44341
|
+
import { c as _c64 } from "react-compiler-runtime";
|
|
44291
44342
|
import { Flex as Flex17 } from "@radix-ui/themes";
|
|
44292
44343
|
// src/hooks/misc/useInfiniteScroll/index.tsx
|
|
44293
44344
|
import { useRef as useRef3 } from "react";
|
|
@@ -44340,7 +44391,7 @@ var useInfiniteScroll = function(_ref) {
|
|
|
44340
44391
|
};
|
|
44341
44392
|
};
|
|
44342
44393
|
// src/components/threads/Thread/Messages/Root/index.tsx
|
|
44343
|
-
import { jsx as
|
|
44394
|
+
import { jsx as _jsx65, jsxs as _jsxs20 } from "react/jsx-runtime";
|
|
44344
44395
|
function ownKeys27(e, r) {
|
|
44345
44396
|
var t = Object.keys(e);
|
|
44346
44397
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -44385,7 +44436,7 @@ function _toPrimitive27(t, r) {
|
|
|
44385
44436
|
return ("string" === r ? String : Number)(t);
|
|
44386
44437
|
}
|
|
44387
44438
|
var Root6 = function(t0) {
|
|
44388
|
-
var $ =
|
|
44439
|
+
var $ = _c64(18);
|
|
44389
44440
|
var children = t0.children, style = t0.style, className = t0.className;
|
|
44390
44441
|
var _useMessages = useMessages(), isFetchingNextPage = _useMessages.isFetchingNextPage, hasNextPage = _useMessages.hasNextPage, fetchNextPage = _useMessages.fetchNextPage;
|
|
44391
44442
|
var t1;
|
|
@@ -44423,7 +44474,7 @@ var Root6 = function(t0) {
|
|
|
44423
44474
|
}
|
|
44424
44475
|
var t4;
|
|
44425
44476
|
if ($[8] !== hasNextPage || $[9] !== loaderRef) {
|
|
44426
|
-
t4 = hasNextPage && /* @__PURE__ */
|
|
44477
|
+
t4 = hasNextPage && /* @__PURE__ */ _jsx65(Flex17, {
|
|
44427
44478
|
ref: loaderRef
|
|
44428
44479
|
});
|
|
44429
44480
|
$[8] = hasNextPage;
|
|
@@ -44434,7 +44485,7 @@ var Root6 = function(t0) {
|
|
|
44434
44485
|
}
|
|
44435
44486
|
var t5;
|
|
44436
44487
|
if ($[11] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44437
|
-
t5 = /* @__PURE__ */
|
|
44488
|
+
t5 = /* @__PURE__ */ _jsx65(Flex17, {
|
|
44438
44489
|
flexShrink: "0",
|
|
44439
44490
|
flexGrow: "1"
|
|
44440
44491
|
});
|
|
@@ -44468,10 +44519,10 @@ var Root6 = function(t0) {
|
|
|
44468
44519
|
return t6;
|
|
44469
44520
|
};
|
|
44470
44521
|
// src/components/threads/Thread/Messages/NextPageSkeleton.tsx
|
|
44471
|
-
import { c as
|
|
44472
|
-
import { jsx as
|
|
44522
|
+
import { c as _c65 } from "react-compiler-runtime";
|
|
44523
|
+
import { jsx as _jsx66 } from "react/jsx-runtime";
|
|
44473
44524
|
var NextPageSkeleton = function() {
|
|
44474
|
-
var $ =
|
|
44525
|
+
var $ = _c65(2);
|
|
44475
44526
|
var hasNextPage = useMessages().hasNextPage;
|
|
44476
44527
|
var _useComponents = useComponents(), t0 = _useComponents.components;
|
|
44477
44528
|
var MessagesSkeleton3 = t0.MessagesSkeleton;
|
|
@@ -44480,7 +44531,7 @@ var NextPageSkeleton = function() {
|
|
|
44480
44531
|
}
|
|
44481
44532
|
var t1;
|
|
44482
44533
|
if ($[0] !== MessagesSkeleton3) {
|
|
44483
|
-
t1 = /* @__PURE__ */
|
|
44534
|
+
t1 = /* @__PURE__ */ _jsx66(MessagesSkeleton3, {});
|
|
44484
44535
|
$[0] = MessagesSkeleton3;
|
|
44485
44536
|
$[1] = t1;
|
|
44486
44537
|
} else {
|
|
@@ -44489,18 +44540,18 @@ var NextPageSkeleton = function() {
|
|
|
44489
44540
|
return t1;
|
|
44490
44541
|
};
|
|
44491
44542
|
// src/components/threads/Thread/Messages/index.tsx
|
|
44492
|
-
import { jsx as
|
|
44543
|
+
import { jsx as _jsx67, jsxs as _jsxs21 } from "react/jsx-runtime";
|
|
44493
44544
|
var Messages2 = function(t0) {
|
|
44494
|
-
var $ =
|
|
44545
|
+
var $ = _c66(9);
|
|
44495
44546
|
var children = t0.children, className = t0.className, style = t0.style;
|
|
44496
44547
|
var t1;
|
|
44497
44548
|
var t2;
|
|
44498
44549
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44499
|
-
t1 = /* @__PURE__ */
|
|
44550
|
+
t1 = /* @__PURE__ */ _jsx67(Flex18, {
|
|
44500
44551
|
flexShrink: "0",
|
|
44501
44552
|
height: "var(--space-3)"
|
|
44502
44553
|
});
|
|
44503
|
-
t2 = /* @__PURE__ */
|
|
44554
|
+
t2 = /* @__PURE__ */ _jsx67(Progress, {});
|
|
44504
44555
|
$[0] = t1;
|
|
44505
44556
|
$[1] = t2;
|
|
44506
44557
|
} else {
|
|
@@ -44511,9 +44562,9 @@ var Messages2 = function(t0) {
|
|
|
44511
44562
|
var t4;
|
|
44512
44563
|
var t5;
|
|
44513
44564
|
if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44514
|
-
t3 = /* @__PURE__ */
|
|
44515
|
-
t4 = /* @__PURE__ */
|
|
44516
|
-
t5 = /* @__PURE__ */
|
|
44565
|
+
t3 = /* @__PURE__ */ _jsx67(Content7, {});
|
|
44566
|
+
t4 = /* @__PURE__ */ _jsx67(NextPageSkeleton, {});
|
|
44567
|
+
t5 = /* @__PURE__ */ _jsx67(Flex18, {
|
|
44517
44568
|
flexShrink: "0",
|
|
44518
44569
|
flexGrow: "1",
|
|
44519
44570
|
minHeight: "var(--space-5)"
|
|
@@ -44554,9 +44605,9 @@ Messages2.Message = Message;
|
|
|
44554
44605
|
Messages2.NextPageSkeleton = NextPageSkeleton;
|
|
44555
44606
|
Messages2.Content = Content7;
|
|
44556
44607
|
// src/components/threads/Thread/MessageForm/index.tsx
|
|
44557
|
-
import { c as
|
|
44608
|
+
import { c as _c73 } from "react-compiler-runtime";
|
|
44558
44609
|
// src/components/threads/Thread/MessageForm/Submit/index.tsx
|
|
44559
|
-
import { c as
|
|
44610
|
+
import { c as _c67 } from "react-compiler-runtime";
|
|
44560
44611
|
import { ArrowUpIcon as ArrowUpIcon2, StopIcon } from "@radix-ui/react-icons";
|
|
44561
44612
|
import { IconButton as IconButton5, Flex as Flex19 } from "@radix-ui/themes";
|
|
44562
44613
|
// src/hooks/messages/useMessageFormContext/index.ts
|
|
@@ -44576,7 +44627,7 @@ var useMessageFormContext = function() {
|
|
|
44576
44627
|
return useContext15(MessageFormContext);
|
|
44577
44628
|
};
|
|
44578
44629
|
// src/components/threads/Thread/MessageForm/Submit/index.tsx
|
|
44579
|
-
import { jsx as
|
|
44630
|
+
import { jsx as _jsx68 } from "react/jsx-runtime";
|
|
44580
44631
|
function ownKeys28(e, r) {
|
|
44581
44632
|
var t = Object.keys(e);
|
|
44582
44633
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -44621,11 +44672,11 @@ function _toPrimitive28(t, r) {
|
|
|
44621
44672
|
return ("string" === r ? String : Number)(t);
|
|
44622
44673
|
}
|
|
44623
44674
|
var Root7 = function(t0) {
|
|
44624
|
-
var $ =
|
|
44675
|
+
var $ = _c67(4);
|
|
44625
44676
|
var children = t0.children, style = t0.style, className = t0.className;
|
|
44626
44677
|
var t1;
|
|
44627
44678
|
if ($[0] !== children || $[1] !== className || $[2] !== style) {
|
|
44628
|
-
t1 = /* @__PURE__ */
|
|
44679
|
+
t1 = /* @__PURE__ */ _jsx68(Flex19, {
|
|
44629
44680
|
flexShrink: "0",
|
|
44630
44681
|
align: "end",
|
|
44631
44682
|
style: style,
|
|
@@ -44642,7 +44693,7 @@ var Root7 = function(t0) {
|
|
|
44642
44693
|
return t1;
|
|
44643
44694
|
};
|
|
44644
44695
|
var Button3 = function(props) {
|
|
44645
|
-
var $ =
|
|
44696
|
+
var $ = _c67(10);
|
|
44646
44697
|
var superinterfaceContext = useSuperinterfaceContext();
|
|
44647
44698
|
var _useMessageFormContext = useMessageFormContext(), isDisabled = _useMessageFormContext.isDisabled, isLoading = _useMessageFormContext.isLoading, isFileLoading = _useMessageFormContext.isFileLoading;
|
|
44648
44699
|
if (isLoading) {
|
|
@@ -44659,14 +44710,14 @@ var Button3 = function(props) {
|
|
|
44659
44710
|
}
|
|
44660
44711
|
var _t2;
|
|
44661
44712
|
if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44662
|
-
_t2 = /* @__PURE__ */
|
|
44713
|
+
_t2 = /* @__PURE__ */ _jsx68(StopIcon, {});
|
|
44663
44714
|
$[2] = _t2;
|
|
44664
44715
|
} else {
|
|
44665
44716
|
_t2 = $[2];
|
|
44666
44717
|
}
|
|
44667
44718
|
var _t3;
|
|
44668
44719
|
if ($[3] !== props || $[4] !== _t) {
|
|
44669
|
-
_t3 = /* @__PURE__ */
|
|
44720
|
+
_t3 = /* @__PURE__ */ _jsx68(IconButton5, _objectSpread28(_objectSpread28({
|
|
44670
44721
|
type: "button",
|
|
44671
44722
|
onClick: _t
|
|
44672
44723
|
}, props), {}, {
|
|
@@ -44683,14 +44734,14 @@ var Button3 = function(props) {
|
|
|
44683
44734
|
var t0 = isDisabled || isFileLoading;
|
|
44684
44735
|
var t1;
|
|
44685
44736
|
if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44686
|
-
t1 = /* @__PURE__ */
|
|
44737
|
+
t1 = /* @__PURE__ */ _jsx68(ArrowUpIcon2, {});
|
|
44687
44738
|
$[6] = t1;
|
|
44688
44739
|
} else {
|
|
44689
44740
|
t1 = $[6];
|
|
44690
44741
|
}
|
|
44691
44742
|
var t2;
|
|
44692
44743
|
if ($[7] !== props || $[8] !== t0) {
|
|
44693
|
-
t2 = /* @__PURE__ */
|
|
44744
|
+
t2 = /* @__PURE__ */ _jsx68(IconButton5, _objectSpread28(_objectSpread28({
|
|
44694
44745
|
type: "submit",
|
|
44695
44746
|
disabled: t0
|
|
44696
44747
|
}, props), {}, {
|
|
@@ -44705,17 +44756,17 @@ var Button3 = function(props) {
|
|
|
44705
44756
|
return t2;
|
|
44706
44757
|
};
|
|
44707
44758
|
var Submit = function(props) {
|
|
44708
|
-
var $ =
|
|
44759
|
+
var $ = _c67(3);
|
|
44709
44760
|
var t0;
|
|
44710
44761
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
44711
|
-
t0 = /* @__PURE__ */
|
|
44762
|
+
t0 = /* @__PURE__ */ _jsx68(Button3, {});
|
|
44712
44763
|
$[0] = t0;
|
|
44713
44764
|
} else {
|
|
44714
44765
|
t0 = $[0];
|
|
44715
44766
|
}
|
|
44716
44767
|
var t1;
|
|
44717
44768
|
if ($[1] !== props) {
|
|
44718
|
-
t1 = /* @__PURE__ */
|
|
44769
|
+
t1 = /* @__PURE__ */ _jsx68(Root7, _objectSpread28(_objectSpread28({}, props), {}, {
|
|
44719
44770
|
children: t0
|
|
44720
44771
|
}));
|
|
44721
44772
|
$[1] = props;
|
|
@@ -44729,7 +44780,7 @@ Submit.Root = Root7;
|
|
|
44729
44780
|
Submit.Button = Button3;
|
|
44730
44781
|
// src/components/threads/Thread/MessageForm/Root/index.tsx
|
|
44731
44782
|
import { useQueryClient as useQueryClient4 } from "@tanstack/react-query";
|
|
44732
|
-
import { useMemo as useMemo13, useState as useState4
|
|
44783
|
+
import { useMemo as useMemo13, useState as useState4 } from "react";
|
|
44733
44784
|
import { useForm, FormProvider } from "react-hook-form";
|
|
44734
44785
|
import { Box as Box14 } from "@radix-ui/themes";
|
|
44735
44786
|
// src/components/threads/Thread/MessageForm/Root/lib/formOptions.ts
|
|
@@ -44743,7 +44794,7 @@ var formOptions = {
|
|
|
44743
44794
|
};
|
|
44744
44795
|
// src/components/threads/Thread/MessageForm/Root/index.tsx
|
|
44745
44796
|
import { partob } from "radash";
|
|
44746
|
-
import { jsx as
|
|
44797
|
+
import { jsx as _jsx69 } from "react/jsx-runtime";
|
|
44747
44798
|
function ownKeys29(e, r) {
|
|
44748
44799
|
var t = Object.keys(e);
|
|
44749
44800
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -44815,7 +44866,7 @@ var Root8 = function(_ref) {
|
|
|
44815
44866
|
var children = _ref.children, onSubmitArg = _ref.onSubmit, isDisabledArg = _ref.isDisabled, style = _ref.style, className = _ref.className;
|
|
44816
44867
|
var _useState4 = _sliced_to_array(useState4([]), 2), files = _useState4[0], setFiles = _useState4[1];
|
|
44817
44868
|
var formProps = useForm(formOptions);
|
|
44818
|
-
var handleSubmit = formProps.handleSubmit, isSubmitting = formProps.formState.isSubmitting,
|
|
44869
|
+
var handleSubmit = formProps.handleSubmit, isSubmitting = formProps.formState.isSubmitting, reset = formProps.reset, watch = formProps.watch;
|
|
44819
44870
|
var addToast = useToasts().addToast;
|
|
44820
44871
|
var queryClient = useQueryClient4();
|
|
44821
44872
|
var threadContext = useSuperinterfaceContext();
|
|
@@ -44850,16 +44901,9 @@ var Root8 = function(_ref) {
|
|
|
44850
44901
|
latestMessage,
|
|
44851
44902
|
isDisabledArg
|
|
44852
44903
|
]);
|
|
44853
|
-
var reset = useCallback3(function() {
|
|
44854
|
-
formReset();
|
|
44855
|
-
setFiles([]);
|
|
44856
|
-
}, [
|
|
44857
|
-
formReset
|
|
44858
|
-
]);
|
|
44859
44904
|
var onSubmit = onSubmitArg ? partob(onSubmitArg, {
|
|
44860
44905
|
reset: reset,
|
|
44861
|
-
createMessage: createMessage
|
|
44862
|
-
files: files
|
|
44906
|
+
createMessage: createMessage
|
|
44863
44907
|
}) : /* @__PURE__ */ function() {
|
|
44864
44908
|
var _ref2 = _asyncToGenerator6(function(data2) {
|
|
44865
44909
|
var attachments, imageFileContentParts, content2;
|
|
@@ -44876,6 +44920,7 @@ var Root8 = function(_ref) {
|
|
|
44876
44920
|
2
|
|
44877
44921
|
];
|
|
44878
44922
|
reset();
|
|
44923
|
+
setFiles([]);
|
|
44879
44924
|
attachments = files.filter(function(file_0) {
|
|
44880
44925
|
return file_0.purpose === "assistants";
|
|
44881
44926
|
}).map(function(file_1) {
|
|
@@ -44925,7 +44970,7 @@ var Root8 = function(_ref) {
|
|
|
44925
44970
|
};
|
|
44926
44971
|
}();
|
|
44927
44972
|
var content_0 = watch("content");
|
|
44928
|
-
return /* @__PURE__ */
|
|
44973
|
+
return /* @__PURE__ */ _jsx69(MessageFormContext.Provider, {
|
|
44929
44974
|
value: {
|
|
44930
44975
|
isDisabled: isDisabled,
|
|
44931
44976
|
isLoading: isLoading,
|
|
@@ -44934,13 +44979,13 @@ var Root8 = function(_ref) {
|
|
|
44934
44979
|
isFileLoading: isFileLoading,
|
|
44935
44980
|
content: content_0
|
|
44936
44981
|
},
|
|
44937
|
-
children: /* @__PURE__ */
|
|
44938
|
-
children: /* @__PURE__ */
|
|
44982
|
+
children: /* @__PURE__ */ _jsx69(FormProvider, _objectSpread29(_objectSpread29({}, formProps), {}, {
|
|
44983
|
+
children: /* @__PURE__ */ _jsx69(Box14, {
|
|
44939
44984
|
asChild: true,
|
|
44940
44985
|
flexShrink: "0",
|
|
44941
44986
|
style: style,
|
|
44942
44987
|
className: className,
|
|
44943
|
-
children: /* @__PURE__ */
|
|
44988
|
+
children: /* @__PURE__ */ _jsx69("form", {
|
|
44944
44989
|
onSubmit: handleSubmit(onSubmit),
|
|
44945
44990
|
children: children
|
|
44946
44991
|
})
|
|
@@ -44952,7 +44997,7 @@ var Root8 = function(_ref) {
|
|
|
44952
44997
|
import { useFormContext as useFormContext2 } from "react-hook-form";
|
|
44953
44998
|
import { Container as RadixContainer, Flex as Flex23 } from "@radix-ui/themes";
|
|
44954
44999
|
// src/components/threads/Thread/MessageForm/Field/Control.tsx
|
|
44955
|
-
import { c as
|
|
45000
|
+
import { c as _c69 } from "react-compiler-runtime";
|
|
44956
45001
|
import { Flex as Flex20 } from "@radix-ui/themes";
|
|
44957
45002
|
import { useFormContext } from "react-hook-form";
|
|
44958
45003
|
// src/hooks/misc/usePrevious.ts
|
|
@@ -44967,10 +45012,10 @@ var usePrevious = function(state) {
|
|
|
44967
45012
|
// src/components/threads/Thread/MessageForm/Field/Control.tsx
|
|
44968
45013
|
import { useContext as useContext16, useMemo as useMemo14, useRef as useRef5, useEffect as useEffect6 } from "react";
|
|
44969
45014
|
// src/components/textareas/TextareaBase/index.tsx
|
|
44970
|
-
import { c as
|
|
45015
|
+
import { c as _c68 } from "react-compiler-runtime";
|
|
44971
45016
|
import { forwardRef as forwardRef4 } from "react";
|
|
44972
45017
|
import TextareaAutosize from "react-textarea-autosize";
|
|
44973
|
-
import { jsx as
|
|
45018
|
+
import { jsx as _jsx70, Fragment as _Fragment5, jsxs as _jsxs22 } from "react/jsx-runtime";
|
|
44974
45019
|
var _excluded3 = [
|
|
44975
45020
|
"style",
|
|
44976
45021
|
"className"
|
|
@@ -45037,7 +45082,7 @@ function _objectWithoutPropertiesLoose3(r, e) {
|
|
|
45037
45082
|
return t;
|
|
45038
45083
|
}
|
|
45039
45084
|
var TextareaBase = /* @__PURE__ */ forwardRef4(function TextareaBase2(t0, ref) {
|
|
45040
|
-
var $ =
|
|
45085
|
+
var $ = _c68(14);
|
|
45041
45086
|
var className;
|
|
45042
45087
|
var rest;
|
|
45043
45088
|
var style;
|
|
@@ -45058,7 +45103,7 @@ var TextareaBase = /* @__PURE__ */ forwardRef4(function TextareaBase2(t0, ref) {
|
|
|
45058
45103
|
}
|
|
45059
45104
|
var t1;
|
|
45060
45105
|
if ($[4] === Symbol.for("react.memo_cache_sentinel")) {
|
|
45061
|
-
t1 = /* @__PURE__ */
|
|
45106
|
+
t1 = /* @__PURE__ */ _jsx70("style", {
|
|
45062
45107
|
children: ".superinterface-textarea { min-height: inherit; height: 30px; }\n.superinterface-textarea::placeholder { color: var(--gray-a10); }"
|
|
45063
45108
|
});
|
|
45064
45109
|
$[4] = t1;
|
|
@@ -45095,7 +45140,7 @@ var TextareaBase = /* @__PURE__ */ forwardRef4(function TextareaBase2(t0, ref) {
|
|
|
45095
45140
|
t5 = /* @__PURE__ */ _jsxs22(_Fragment5, {
|
|
45096
45141
|
children: [
|
|
45097
45142
|
t1,
|
|
45098
|
-
/* @__PURE__ */
|
|
45143
|
+
/* @__PURE__ */ _jsx70(TextareaAutosize, _objectSpread30({
|
|
45099
45144
|
ref: ref,
|
|
45100
45145
|
className: t2,
|
|
45101
45146
|
style: t4
|
|
@@ -45113,7 +45158,7 @@ var TextareaBase = /* @__PURE__ */ forwardRef4(function TextareaBase2(t0, ref) {
|
|
|
45113
45158
|
return t5;
|
|
45114
45159
|
});
|
|
45115
45160
|
// src/components/threads/Thread/MessageForm/Field/Control.tsx
|
|
45116
|
-
import { jsx as
|
|
45161
|
+
import { jsx as _jsx71 } from "react/jsx-runtime";
|
|
45117
45162
|
function ownKeys31(e, r) {
|
|
45118
45163
|
var t = Object.keys(e);
|
|
45119
45164
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -45158,11 +45203,11 @@ function _toPrimitive31(t, r) {
|
|
|
45158
45203
|
return ("string" === r ? String : Number)(t);
|
|
45159
45204
|
}
|
|
45160
45205
|
var Root9 = function(t0) {
|
|
45161
|
-
var $ =
|
|
45206
|
+
var $ = _c69(4);
|
|
45162
45207
|
var children = t0.children, style = t0.style, className = t0.className;
|
|
45163
45208
|
var t1;
|
|
45164
45209
|
if ($[0] !== children || $[1] !== className || $[2] !== style) {
|
|
45165
|
-
t1 = /* @__PURE__ */
|
|
45210
|
+
t1 = /* @__PURE__ */ _jsx71(Flex20, {
|
|
45166
45211
|
flexGrow: "1",
|
|
45167
45212
|
pt: "4px",
|
|
45168
45213
|
style: style,
|
|
@@ -45203,7 +45248,7 @@ var Input = function(props) {
|
|
|
45203
45248
|
isDisabledPrevious,
|
|
45204
45249
|
textareaProps
|
|
45205
45250
|
]);
|
|
45206
|
-
return /* @__PURE__ */
|
|
45251
|
+
return /* @__PURE__ */ _jsx71(TextareaBase, _objectSpread31(_objectSpread31(_objectSpread31({
|
|
45207
45252
|
minRows: 1,
|
|
45208
45253
|
placeholder: (_props$placeholder = props.placeholder) !== null && _props$placeholder !== void 0 ? _props$placeholder : "Message ".concat(assistantNameContext, "..."),
|
|
45209
45254
|
disabled: isDisabled,
|
|
@@ -45223,17 +45268,17 @@ var Input = function(props) {
|
|
|
45223
45268
|
}));
|
|
45224
45269
|
};
|
|
45225
45270
|
var Control = function(props) {
|
|
45226
|
-
var $ =
|
|
45271
|
+
var $ = _c69(3);
|
|
45227
45272
|
var t0;
|
|
45228
45273
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
45229
|
-
t0 = /* @__PURE__ */
|
|
45274
|
+
t0 = /* @__PURE__ */ _jsx71(Input, {});
|
|
45230
45275
|
$[0] = t0;
|
|
45231
45276
|
} else {
|
|
45232
45277
|
t0 = $[0];
|
|
45233
45278
|
}
|
|
45234
45279
|
var t1;
|
|
45235
45280
|
if ($[1] !== props) {
|
|
45236
|
-
t1 = /* @__PURE__ */
|
|
45281
|
+
t1 = /* @__PURE__ */ _jsx71(Root9, _objectSpread31(_objectSpread31({}, props), {}, {
|
|
45237
45282
|
children: t0
|
|
45238
45283
|
}));
|
|
45239
45284
|
$[1] = props;
|
|
@@ -45246,10 +45291,10 @@ var Control = function(props) {
|
|
|
45246
45291
|
Control.Root = Root9;
|
|
45247
45292
|
Control.Input = Input;
|
|
45248
45293
|
// src/components/threads/Thread/MessageForm/Field/Files/Preview.tsx
|
|
45249
|
-
import { c as
|
|
45294
|
+
import { c as _c70 } from "react-compiler-runtime";
|
|
45250
45295
|
import { Flex as Flex21, Card as Card2, Spinner as Spinner2, Text as Text7, IconButton as IconButton6 } from "@radix-ui/themes";
|
|
45251
45296
|
import { FileIcon as FileIcon2, Cross2Icon } from "@radix-ui/react-icons";
|
|
45252
|
-
import { jsx as
|
|
45297
|
+
import { jsx as _jsx72, jsxs as _jsxs23 } from "react/jsx-runtime";
|
|
45253
45298
|
function ownKeys32(e, r) {
|
|
45254
45299
|
var t = Object.keys(e);
|
|
45255
45300
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -45294,7 +45339,7 @@ function _toPrimitive32(t, r) {
|
|
|
45294
45339
|
return ("string" === r ? String : Number)(t);
|
|
45295
45340
|
}
|
|
45296
45341
|
var Preview = function(props) {
|
|
45297
|
-
var $ =
|
|
45342
|
+
var $ = _c70(8);
|
|
45298
45343
|
var _useMessageFormContext = useMessageFormContext(), files = _useMessageFormContext.files, setFiles = _useMessageFormContext.setFiles;
|
|
45299
45344
|
if (!files.length) {
|
|
45300
45345
|
return null;
|
|
@@ -45304,7 +45349,7 @@ var Preview = function(props) {
|
|
|
45304
45349
|
var _t;
|
|
45305
45350
|
if ($[3] !== setFiles) {
|
|
45306
45351
|
_t = function(file) {
|
|
45307
|
-
return /* @__PURE__ */
|
|
45352
|
+
return /* @__PURE__ */ _jsx72(Card2, {
|
|
45308
45353
|
variant: "ghost",
|
|
45309
45354
|
children: /* @__PURE__ */ _jsxs23(Flex21, {
|
|
45310
45355
|
align: "center",
|
|
@@ -45318,16 +45363,16 @@ var Preview = function(props) {
|
|
|
45318
45363
|
minWidth: "0",
|
|
45319
45364
|
maxWidth: "250px",
|
|
45320
45365
|
children: [
|
|
45321
|
-
/* @__PURE__ */
|
|
45366
|
+
/* @__PURE__ */ _jsx72(Flex21, {
|
|
45322
45367
|
flexShrink: "0",
|
|
45323
|
-
children: /* @__PURE__ */
|
|
45368
|
+
children: /* @__PURE__ */ _jsx72(Spinner2, {
|
|
45324
45369
|
loading: isOptimistic({
|
|
45325
45370
|
id: file.id
|
|
45326
45371
|
}),
|
|
45327
|
-
children: /* @__PURE__ */
|
|
45372
|
+
children: /* @__PURE__ */ _jsx72(FileIcon2, {})
|
|
45328
45373
|
})
|
|
45329
45374
|
}),
|
|
45330
|
-
/* @__PURE__ */
|
|
45375
|
+
/* @__PURE__ */ _jsx72(Text7, {
|
|
45331
45376
|
size: "2",
|
|
45332
45377
|
truncate: true,
|
|
45333
45378
|
wrap: "nowrap",
|
|
@@ -45335,9 +45380,9 @@ var Preview = function(props) {
|
|
|
45335
45380
|
})
|
|
45336
45381
|
]
|
|
45337
45382
|
}),
|
|
45338
|
-
/* @__PURE__ */
|
|
45383
|
+
/* @__PURE__ */ _jsx72(Flex21, {
|
|
45339
45384
|
flexShrink: "0",
|
|
45340
|
-
children: /* @__PURE__ */
|
|
45385
|
+
children: /* @__PURE__ */ _jsx72(IconButton6, {
|
|
45341
45386
|
onClick: function() {
|
|
45342
45387
|
return setFiles(function(prev) {
|
|
45343
45388
|
return prev.filter(function(prevFile) {
|
|
@@ -45348,7 +45393,7 @@ var Preview = function(props) {
|
|
|
45348
45393
|
color: "gray",
|
|
45349
45394
|
variant: "ghost",
|
|
45350
45395
|
size: "1",
|
|
45351
|
-
children: /* @__PURE__ */
|
|
45396
|
+
children: /* @__PURE__ */ _jsx72(Cross2Icon, {})
|
|
45352
45397
|
})
|
|
45353
45398
|
})
|
|
45354
45399
|
]
|
|
@@ -45369,7 +45414,7 @@ var Preview = function(props) {
|
|
|
45369
45414
|
}
|
|
45370
45415
|
var t1;
|
|
45371
45416
|
if ($[5] !== props || $[6] !== t0) {
|
|
45372
|
-
t1 = /* @__PURE__ */
|
|
45417
|
+
t1 = /* @__PURE__ */ _jsx72(Flex21, _objectSpread32(_objectSpread32({
|
|
45373
45418
|
flexBasis: "100%",
|
|
45374
45419
|
direction: "column",
|
|
45375
45420
|
pb: "2",
|
|
@@ -45386,15 +45431,15 @@ var Preview = function(props) {
|
|
|
45386
45431
|
return t1;
|
|
45387
45432
|
};
|
|
45388
45433
|
// src/components/threads/Thread/MessageForm/Field/Files/Control.tsx
|
|
45389
|
-
import { c as
|
|
45434
|
+
import { c as _c72 } from "react-compiler-runtime";
|
|
45390
45435
|
import { FilePlusIcon } from "@radix-ui/react-icons";
|
|
45391
45436
|
import { IconButton as IconButton7, Flex as Flex22 } from "@radix-ui/themes";
|
|
45392
45437
|
// src/hooks/files/useChangeFilesField/index.ts
|
|
45393
|
-
import { useCallback as
|
|
45438
|
+
import { useCallback as useCallback3 } from "react";
|
|
45394
45439
|
import { omit as omit4 } from "radash";
|
|
45395
45440
|
import dayjs2 from "dayjs";
|
|
45396
45441
|
// src/hooks/files/useCreateFile/index.ts
|
|
45397
|
-
import { c as
|
|
45442
|
+
import { c as _c71 } from "react-compiler-runtime";
|
|
45398
45443
|
import { useMutation as useMutation2, useQueryClient as useQueryClient5 } from "@tanstack/react-query";
|
|
45399
45444
|
// src/hooks/files/useCreateFile/lib/mutationOptions/mutationFn/body/formData.ts
|
|
45400
45445
|
var formData = function(variables) {
|
|
@@ -45630,7 +45675,7 @@ function _toPrimitive35(t, r) {
|
|
|
45630
45675
|
return ("string" === r ? String : Number)(t);
|
|
45631
45676
|
}
|
|
45632
45677
|
var useCreateFile = function(t0) {
|
|
45633
|
-
var $ =
|
|
45678
|
+
var $ = _c71(15);
|
|
45634
45679
|
var t1;
|
|
45635
45680
|
if ($[0] !== t0) {
|
|
45636
45681
|
t1 = t0 === void 0 ? {
|
|
@@ -45781,7 +45826,7 @@ var useChangeFilesField = function() {
|
|
|
45781
45826
|
var setFiles = useMessageFormContext().setFiles;
|
|
45782
45827
|
var createFile = useCreateFile().createFile;
|
|
45783
45828
|
var addToast = useToasts().addToast;
|
|
45784
|
-
var changeFilesField =
|
|
45829
|
+
var changeFilesField = useCallback3(/* @__PURE__ */ function() {
|
|
45785
45830
|
var _ref2 = _asyncToGenerator8(function(event) {
|
|
45786
45831
|
var fileObjects, newFiles, _iteratorAbruptCompletion, _didIteratorError, _iteratorError, _loop, _iterator, _step, err;
|
|
45787
45832
|
return _ts_generator(this, function(_state) {
|
|
@@ -45959,7 +46004,7 @@ var useChangeFilesField = function() {
|
|
|
45959
46004
|
// src/lib/files/filesFieldAccept.ts
|
|
45960
46005
|
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";
|
|
45961
46006
|
// src/components/threads/Thread/MessageForm/Field/Files/Control.tsx
|
|
45962
|
-
import { jsx as
|
|
46007
|
+
import { jsx as _jsx73, jsxs as _jsxs24 } from "react/jsx-runtime";
|
|
45963
46008
|
function ownKeys36(e, r) {
|
|
45964
46009
|
var t = Object.keys(e);
|
|
45965
46010
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -46004,7 +46049,7 @@ function _toPrimitive36(t, r) {
|
|
|
46004
46049
|
return ("string" === r ? String : Number)(t);
|
|
46005
46050
|
}
|
|
46006
46051
|
var Control2 = function(props) {
|
|
46007
|
-
var $ =
|
|
46052
|
+
var $ = _c72(11);
|
|
46008
46053
|
var _useMessageFormContext = useMessageFormContext(), isDisabled = _useMessageFormContext.isDisabled, isLoading = _useMessageFormContext.isLoading;
|
|
46009
46054
|
var changeFilesField = useChangeFilesField().changeFilesField;
|
|
46010
46055
|
var t0 = isDisabled || isLoading;
|
|
@@ -46015,7 +46060,7 @@ var Control2 = function(props) {
|
|
|
46015
46060
|
position: "relative",
|
|
46016
46061
|
overflow: "hidden"
|
|
46017
46062
|
};
|
|
46018
|
-
t2 = /* @__PURE__ */
|
|
46063
|
+
t2 = /* @__PURE__ */ _jsx73(FilePlusIcon, {});
|
|
46019
46064
|
$[0] = t1;
|
|
46020
46065
|
$[1] = t2;
|
|
46021
46066
|
} else {
|
|
@@ -46039,7 +46084,7 @@ var Control2 = function(props) {
|
|
|
46039
46084
|
}
|
|
46040
46085
|
var t4;
|
|
46041
46086
|
if ($[3] !== changeFilesField) {
|
|
46042
|
-
t4 = /* @__PURE__ */
|
|
46087
|
+
t4 = /* @__PURE__ */ _jsx73("input", {
|
|
46043
46088
|
type: "file",
|
|
46044
46089
|
multiple: true,
|
|
46045
46090
|
accept: filesFieldAccept,
|
|
@@ -46072,7 +46117,7 @@ var Control2 = function(props) {
|
|
|
46072
46117
|
}
|
|
46073
46118
|
var t6;
|
|
46074
46119
|
if ($[8] !== props || $[9] !== t5) {
|
|
46075
|
-
t6 = /* @__PURE__ */
|
|
46120
|
+
t6 = /* @__PURE__ */ _jsx73(Flex22, _objectSpread36(_objectSpread36({
|
|
46076
46121
|
pt: "2",
|
|
46077
46122
|
pr: "2",
|
|
46078
46123
|
flexGrow: "0"
|
|
@@ -46093,7 +46138,7 @@ var Files = {
|
|
|
46093
46138
|
Control: Control2
|
|
46094
46139
|
};
|
|
46095
46140
|
// src/components/threads/Thread/MessageForm/Field/index.tsx
|
|
46096
|
-
import { jsx as
|
|
46141
|
+
import { jsx as _jsx74 } from "react/jsx-runtime";
|
|
46097
46142
|
function ownKeys37(e, r) {
|
|
46098
46143
|
var t = Object.keys(e);
|
|
46099
46144
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -46141,18 +46186,18 @@ var Root10 = function(_ref) {
|
|
|
46141
46186
|
"use no memo";
|
|
46142
46187
|
var children = _ref.children, className = _ref.className, style = _ref.style;
|
|
46143
46188
|
var _useFormContext2 = useFormContext2(), errors = _useFormContext2.formState.errors;
|
|
46144
|
-
return /* @__PURE__ */
|
|
46189
|
+
return /* @__PURE__ */ _jsx74(RadixContainer, {
|
|
46145
46190
|
size: "2",
|
|
46146
46191
|
flexGrow: "0",
|
|
46147
46192
|
className: className,
|
|
46148
46193
|
style: style,
|
|
46149
|
-
children: /* @__PURE__ */
|
|
46194
|
+
children: /* @__PURE__ */ _jsx74(Flex23, {
|
|
46150
46195
|
direction: "column",
|
|
46151
46196
|
flexShrink: "0",
|
|
46152
|
-
children: /* @__PURE__ */
|
|
46197
|
+
children: /* @__PURE__ */ _jsx74(Flex23, {
|
|
46153
46198
|
direction: "column",
|
|
46154
46199
|
flexShrink: "0",
|
|
46155
|
-
children: /* @__PURE__ */
|
|
46200
|
+
children: /* @__PURE__ */ _jsx74(Flex23, {
|
|
46156
46201
|
style: _objectSpread37({
|
|
46157
46202
|
borderRadius: "var(--radius-2)",
|
|
46158
46203
|
borderWidth: "1px",
|
|
@@ -46176,7 +46221,7 @@ var Field = {
|
|
|
46176
46221
|
Files: Files
|
|
46177
46222
|
};
|
|
46178
46223
|
// src/components/threads/Thread/MessageForm/index.tsx
|
|
46179
|
-
import { jsx as
|
|
46224
|
+
import { jsx as _jsx75, jsxs as _jsxs25 } from "react/jsx-runtime";
|
|
46180
46225
|
function ownKeys38(e, r) {
|
|
46181
46226
|
var t = Object.keys(e);
|
|
46182
46227
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -46221,13 +46266,13 @@ function _toPrimitive38(t, r) {
|
|
|
46221
46266
|
return ("string" === r ? String : Number)(t);
|
|
46222
46267
|
}
|
|
46223
46268
|
var MessageForm = function(props) {
|
|
46224
|
-
var $ =
|
|
46269
|
+
var $ = _c73(3);
|
|
46225
46270
|
var t0;
|
|
46226
46271
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
46227
46272
|
t0 = /* @__PURE__ */ _jsxs25(Field.Root, {
|
|
46228
46273
|
children: [
|
|
46229
|
-
/* @__PURE__ */
|
|
46230
|
-
/* @__PURE__ */
|
|
46274
|
+
/* @__PURE__ */ _jsx75(Field.Control, {}),
|
|
46275
|
+
/* @__PURE__ */ _jsx75(Submit, {})
|
|
46231
46276
|
]
|
|
46232
46277
|
});
|
|
46233
46278
|
$[0] = t0;
|
|
@@ -46236,7 +46281,7 @@ var MessageForm = function(props) {
|
|
|
46236
46281
|
}
|
|
46237
46282
|
var t1;
|
|
46238
46283
|
if ($[1] !== props) {
|
|
46239
|
-
t1 = /* @__PURE__ */
|
|
46284
|
+
t1 = /* @__PURE__ */ _jsx75(Root8, _objectSpread38(_objectSpread38({}, props), {}, {
|
|
46240
46285
|
children: t0
|
|
46241
46286
|
}));
|
|
46242
46287
|
$[1] = props;
|
|
@@ -46250,32 +46295,32 @@ MessageForm.Root = Root8;
|
|
|
46250
46295
|
MessageForm.Field = Field;
|
|
46251
46296
|
MessageForm.Submit = Submit;
|
|
46252
46297
|
// src/components/threads/Thread/Root/index.tsx
|
|
46253
|
-
import { c as
|
|
46298
|
+
import { c as _c76 } from "react-compiler-runtime";
|
|
46254
46299
|
import { Flex as Flex25 } from "@radix-ui/themes";
|
|
46255
46300
|
// src/components/threads/Thread/Provider/index.tsx
|
|
46256
46301
|
var Provider2 = SuperinterfaceProvider;
|
|
46257
46302
|
// src/components/toasts/ToastsProvider/index.tsx
|
|
46258
|
-
import { c as
|
|
46259
|
-
import { useState as useState5, useCallback as
|
|
46303
|
+
import { c as _c75 } from "react-compiler-runtime";
|
|
46304
|
+
import { useState as useState5, useCallback as useCallback4 } from "react";
|
|
46260
46305
|
import * as Toast2 from "@radix-ui/react-toast";
|
|
46261
46306
|
// src/components/toasts/ToastsProvider/CustomToast.tsx
|
|
46262
|
-
import { c as
|
|
46307
|
+
import { c as _c74 } from "react-compiler-runtime";
|
|
46263
46308
|
import * as Toast from "@radix-ui/react-toast";
|
|
46264
46309
|
import { Card as Card3, Text as Text8, Flex as Flex24 } from "@radix-ui/themes";
|
|
46265
46310
|
import { CheckCircledIcon as CheckCircledIcon2, CrossCircledIcon } from "@radix-ui/react-icons";
|
|
46266
|
-
import { jsx as
|
|
46311
|
+
import { jsx as _jsx76, jsxs as _jsxs26 } from "react/jsx-runtime";
|
|
46267
46312
|
var CustomToast = function(t0) {
|
|
46268
|
-
var $ =
|
|
46313
|
+
var $ = _c74(7);
|
|
46269
46314
|
var toast = t0.toast;
|
|
46270
46315
|
var t1;
|
|
46271
46316
|
if ($[0] !== toast.type) {
|
|
46272
|
-
t1 = /* @__PURE__ */
|
|
46317
|
+
t1 = /* @__PURE__ */ _jsx76(Flex24, {
|
|
46273
46318
|
pr: "2",
|
|
46274
46319
|
height: "14px",
|
|
46275
46320
|
align: "center",
|
|
46276
|
-
children: toast.type === "success" ? /* @__PURE__ */
|
|
46321
|
+
children: toast.type === "success" ? /* @__PURE__ */ _jsx76(CheckCircledIcon2, {
|
|
46277
46322
|
color: "var(--accent-9)"
|
|
46278
|
-
}) : /* @__PURE__ */
|
|
46323
|
+
}) : /* @__PURE__ */ _jsx76(CrossCircledIcon, {
|
|
46279
46324
|
color: "var(--red-9)"
|
|
46280
46325
|
})
|
|
46281
46326
|
});
|
|
@@ -46286,7 +46331,7 @@ var CustomToast = function(t0) {
|
|
|
46286
46331
|
}
|
|
46287
46332
|
var t2;
|
|
46288
46333
|
if ($[2] !== toast.message) {
|
|
46289
|
-
t2 = /* @__PURE__ */
|
|
46334
|
+
t2 = /* @__PURE__ */ _jsx76(Text8, {
|
|
46290
46335
|
weight: "medium",
|
|
46291
46336
|
size: "1",
|
|
46292
46337
|
children: toast.message
|
|
@@ -46298,9 +46343,9 @@ var CustomToast = function(t0) {
|
|
|
46298
46343
|
}
|
|
46299
46344
|
var t3;
|
|
46300
46345
|
if ($[4] !== t1 || $[5] !== t2) {
|
|
46301
|
-
t3 = /* @__PURE__ */
|
|
46302
|
-
children: /* @__PURE__ */
|
|
46303
|
-
children: /* @__PURE__ */
|
|
46346
|
+
t3 = /* @__PURE__ */ _jsx76(Toast.Root, {
|
|
46347
|
+
children: /* @__PURE__ */ _jsx76(Card3, {
|
|
46348
|
+
children: /* @__PURE__ */ _jsx76(Toast.Title, {
|
|
46304
46349
|
children: /* @__PURE__ */ _jsxs26(Flex24, {
|
|
46305
46350
|
children: [
|
|
46306
46351
|
t1,
|
|
@@ -46319,9 +46364,9 @@ var CustomToast = function(t0) {
|
|
|
46319
46364
|
return t3;
|
|
46320
46365
|
};
|
|
46321
46366
|
// src/components/toasts/ToastsProvider/index.tsx
|
|
46322
|
-
import { jsx as
|
|
46367
|
+
import { jsx as _jsx77, jsxs as _jsxs27 } from "react/jsx-runtime";
|
|
46323
46368
|
var ToastsProvider = function(t0) {
|
|
46324
|
-
var $ =
|
|
46369
|
+
var $ = _c75(15);
|
|
46325
46370
|
var children = t0.children, t1 = t0.bottom;
|
|
46326
46371
|
var bottom = t1 === void 0 ? 0 : t1;
|
|
46327
46372
|
var t2;
|
|
@@ -46367,7 +46412,7 @@ var ToastsProvider = function(t0) {
|
|
|
46367
46412
|
}
|
|
46368
46413
|
var t6;
|
|
46369
46414
|
if ($[6] !== bottom) {
|
|
46370
|
-
t6 = /* @__PURE__ */
|
|
46415
|
+
t6 = /* @__PURE__ */ _jsx77(Toast2.Viewport, {
|
|
46371
46416
|
style: {
|
|
46372
46417
|
position: "absolute",
|
|
46373
46418
|
bottom: bottom,
|
|
@@ -46407,7 +46452,7 @@ var ToastsProvider = function(t0) {
|
|
|
46407
46452
|
}
|
|
46408
46453
|
var t8;
|
|
46409
46454
|
if ($[12] !== t4 || $[13] !== t7) {
|
|
46410
|
-
t8 = /* @__PURE__ */
|
|
46455
|
+
t8 = /* @__PURE__ */ _jsx77(ToastsContext.Provider, {
|
|
46411
46456
|
value: t4,
|
|
46412
46457
|
children: t7
|
|
46413
46458
|
});
|
|
@@ -46420,12 +46465,12 @@ var ToastsProvider = function(t0) {
|
|
|
46420
46465
|
return t8;
|
|
46421
46466
|
};
|
|
46422
46467
|
function _temp5(toast_0, index) {
|
|
46423
|
-
return /* @__PURE__ */
|
|
46468
|
+
return /* @__PURE__ */ _jsx77(CustomToast, {
|
|
46424
46469
|
toast: toast_0
|
|
46425
46470
|
}, index);
|
|
46426
46471
|
}
|
|
46427
46472
|
// src/components/threads/Thread/Root/index.tsx
|
|
46428
|
-
import { jsx as
|
|
46473
|
+
import { jsx as _jsx78 } from "react/jsx-runtime";
|
|
46429
46474
|
var _excluded4 = [
|
|
46430
46475
|
"children",
|
|
46431
46476
|
"style",
|
|
@@ -46493,7 +46538,7 @@ function _objectWithoutPropertiesLoose4(r, e) {
|
|
|
46493
46538
|
return t;
|
|
46494
46539
|
}
|
|
46495
46540
|
var Root12 = function(t0) {
|
|
46496
|
-
var $ =
|
|
46541
|
+
var $ = _c76(12);
|
|
46497
46542
|
var children;
|
|
46498
46543
|
var className;
|
|
46499
46544
|
var rest;
|
|
@@ -46517,7 +46562,7 @@ var Root12 = function(t0) {
|
|
|
46517
46562
|
}
|
|
46518
46563
|
var t1;
|
|
46519
46564
|
if ($[5] !== children || $[6] !== className || $[7] !== style) {
|
|
46520
|
-
t1 = /* @__PURE__ */
|
|
46565
|
+
t1 = /* @__PURE__ */ _jsx78(Flex25, {
|
|
46521
46566
|
direction: "column",
|
|
46522
46567
|
flexGrow: "1",
|
|
46523
46568
|
className: className,
|
|
@@ -46533,9 +46578,9 @@ var Root12 = function(t0) {
|
|
|
46533
46578
|
}
|
|
46534
46579
|
var t2;
|
|
46535
46580
|
if ($[9] !== rest || $[10] !== t1) {
|
|
46536
|
-
t2 = /* @__PURE__ */
|
|
46581
|
+
t2 = /* @__PURE__ */ _jsx78(ToastsProvider, {
|
|
46537
46582
|
bottom: "var(--space-9)",
|
|
46538
|
-
children: /* @__PURE__ */
|
|
46583
|
+
children: /* @__PURE__ */ _jsx78(Provider2, _objectSpread39(_objectSpread39({}, rest), {}, {
|
|
46539
46584
|
children: t1
|
|
46540
46585
|
}))
|
|
46541
46586
|
});
|
|
@@ -46548,7 +46593,7 @@ var Root12 = function(t0) {
|
|
|
46548
46593
|
return t2;
|
|
46549
46594
|
};
|
|
46550
46595
|
// src/components/threads/Thread/index.tsx
|
|
46551
|
-
import { jsx as
|
|
46596
|
+
import { jsx as _jsx79, jsxs as _jsxs28 } from "react/jsx-runtime";
|
|
46552
46597
|
function ownKeys40(e, r) {
|
|
46553
46598
|
var t = Object.keys(e);
|
|
46554
46599
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -46593,12 +46638,12 @@ function _toPrimitive40(t, r) {
|
|
|
46593
46638
|
return ("string" === r ? String : Number)(t);
|
|
46594
46639
|
}
|
|
46595
46640
|
var Thread = function(props) {
|
|
46596
|
-
var $ =
|
|
46641
|
+
var $ = _c77(4);
|
|
46597
46642
|
var t0;
|
|
46598
46643
|
var t1;
|
|
46599
46644
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
46600
|
-
t0 = /* @__PURE__ */
|
|
46601
|
-
t1 = /* @__PURE__ */
|
|
46645
|
+
t0 = /* @__PURE__ */ _jsx79(Messages2, {});
|
|
46646
|
+
t1 = /* @__PURE__ */ _jsx79(MessageForm, {});
|
|
46602
46647
|
$[0] = t0;
|
|
46603
46648
|
$[1] = t1;
|
|
46604
46649
|
} else {
|
|
@@ -46629,7 +46674,7 @@ var useMessageContext = function() {
|
|
|
46629
46674
|
return useContext17(MessageContext);
|
|
46630
46675
|
};
|
|
46631
46676
|
// src/hooks/assistants/useAssistant/index.ts
|
|
46632
|
-
import { c as
|
|
46677
|
+
import { c as _c78 } from "react-compiler-runtime";
|
|
46633
46678
|
import { useMemo as useMemo15 } from "react";
|
|
46634
46679
|
import { useQuery } from "@tanstack/react-query";
|
|
46635
46680
|
// src/hooks/assistants/useAssistant/lib/queryOptions/index.ts
|
|
@@ -46779,7 +46824,7 @@ function _toPrimitive41(t, r) {
|
|
|
46779
46824
|
return ("string" === r ? String : Number)(t);
|
|
46780
46825
|
}
|
|
46781
46826
|
var useAssistant = function(t0) {
|
|
46782
|
-
var $ =
|
|
46827
|
+
var $ = _c78(6);
|
|
46783
46828
|
var assistantId = t0.assistantId;
|
|
46784
46829
|
var superinterfaceContext = useSuperinterfaceContext();
|
|
46785
46830
|
var t1;
|
|
@@ -46812,11 +46857,11 @@ var useAssistant = function(t0) {
|
|
|
46812
46857
|
return t2;
|
|
46813
46858
|
};
|
|
46814
46859
|
// src/components/threads/ThreadDialog/index.tsx
|
|
46815
|
-
import { c as
|
|
46860
|
+
import { c as _c85 } from "react-compiler-runtime";
|
|
46816
46861
|
// src/components/threads/ThreadDialog/Root/index.tsx
|
|
46817
|
-
import { c as
|
|
46862
|
+
import { c as _c80 } from "react-compiler-runtime";
|
|
46818
46863
|
// src/components/threads/ThreadDialog/Provider/index.tsx
|
|
46819
|
-
import { c as
|
|
46864
|
+
import { c as _c79 } from "react-compiler-runtime";
|
|
46820
46865
|
import { useState as useState6 } from "react";
|
|
46821
46866
|
// src/contexts/threads/ThreadDialogContext/index.ts
|
|
46822
46867
|
import { createContext as createContext12 } from "react";
|
|
@@ -46830,9 +46875,9 @@ var useThreadDialogContext = function() {
|
|
|
46830
46875
|
return useContext18(ThreadDialogContext);
|
|
46831
46876
|
};
|
|
46832
46877
|
// src/components/threads/ThreadDialog/Provider/index.tsx
|
|
46833
|
-
import { jsx as
|
|
46878
|
+
import { jsx as _jsx80 } from "react/jsx-runtime";
|
|
46834
46879
|
var Provider4 = function(t0) {
|
|
46835
|
-
var $ =
|
|
46880
|
+
var $ = _c79(5);
|
|
46836
46881
|
var children = t0.children;
|
|
46837
46882
|
var threadDialogContext = useThreadDialogContext();
|
|
46838
46883
|
var _useState6 = _sliced_to_array(useState6(threadDialogContext.isOpen), 2), isOpen = _useState6[0], setIsOpen = _useState6[1];
|
|
@@ -46849,7 +46894,7 @@ var Provider4 = function(t0) {
|
|
|
46849
46894
|
}
|
|
46850
46895
|
var t2;
|
|
46851
46896
|
if ($[2] !== children || $[3] !== t1) {
|
|
46852
|
-
t2 = /* @__PURE__ */
|
|
46897
|
+
t2 = /* @__PURE__ */ _jsx80(ThreadDialogContext.Provider, {
|
|
46853
46898
|
value: t1,
|
|
46854
46899
|
children: children
|
|
46855
46900
|
});
|
|
@@ -46862,13 +46907,13 @@ var Provider4 = function(t0) {
|
|
|
46862
46907
|
return t2;
|
|
46863
46908
|
};
|
|
46864
46909
|
// src/components/threads/ThreadDialog/Root/index.tsx
|
|
46865
|
-
import { jsx as
|
|
46910
|
+
import { jsx as _jsx81 } from "react/jsx-runtime";
|
|
46866
46911
|
var Root13 = function(t0) {
|
|
46867
|
-
var $ =
|
|
46912
|
+
var $ = _c80(2);
|
|
46868
46913
|
var children = t0.children;
|
|
46869
46914
|
var t1;
|
|
46870
46915
|
if ($[0] !== children) {
|
|
46871
|
-
t1 = /* @__PURE__ */
|
|
46916
|
+
t1 = /* @__PURE__ */ _jsx81(Provider4, {
|
|
46872
46917
|
children: children
|
|
46873
46918
|
});
|
|
46874
46919
|
$[0] = children;
|
|
@@ -46879,13 +46924,13 @@ var Root13 = function(t0) {
|
|
|
46879
46924
|
return t1;
|
|
46880
46925
|
};
|
|
46881
46926
|
// src/components/threads/ThreadDialog/Trigger/index.tsx
|
|
46882
|
-
import { c as
|
|
46927
|
+
import { c as _c82 } from "react-compiler-runtime";
|
|
46883
46928
|
import { Flex as Flex26 } from "@radix-ui/themes";
|
|
46884
46929
|
// src/components/threads/ThreadDialog/Trigger/Button.tsx
|
|
46885
|
-
import { c as
|
|
46930
|
+
import { c as _c81 } from "react-compiler-runtime";
|
|
46886
46931
|
import { IconButton as IconButton8 } from "@radix-ui/themes";
|
|
46887
46932
|
import { ChatBubbleIcon } from "@radix-ui/react-icons";
|
|
46888
|
-
import { jsx as
|
|
46933
|
+
import { jsx as _jsx82 } from "react/jsx-runtime";
|
|
46889
46934
|
function ownKeys42(e, r) {
|
|
46890
46935
|
var t = Object.keys(e);
|
|
46891
46936
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -46930,17 +46975,17 @@ function _toPrimitive42(t, r) {
|
|
|
46930
46975
|
return ("string" === r ? String : Number)(t);
|
|
46931
46976
|
}
|
|
46932
46977
|
var Button4 = function(props) {
|
|
46933
|
-
var $ =
|
|
46978
|
+
var $ = _c81(3);
|
|
46934
46979
|
var t0;
|
|
46935
46980
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
46936
|
-
t0 = /* @__PURE__ */
|
|
46981
|
+
t0 = /* @__PURE__ */ _jsx82(ChatBubbleIcon, {});
|
|
46937
46982
|
$[0] = t0;
|
|
46938
46983
|
} else {
|
|
46939
46984
|
t0 = $[0];
|
|
46940
46985
|
}
|
|
46941
46986
|
var t1;
|
|
46942
46987
|
if ($[1] !== props) {
|
|
46943
|
-
t1 = /* @__PURE__ */
|
|
46988
|
+
t1 = /* @__PURE__ */ _jsx82(IconButton8, _objectSpread42(_objectSpread42({
|
|
46944
46989
|
size: "4",
|
|
46945
46990
|
radius: "full"
|
|
46946
46991
|
}, props), {}, {
|
|
@@ -46954,7 +46999,7 @@ var Button4 = function(props) {
|
|
|
46954
46999
|
return t1;
|
|
46955
47000
|
};
|
|
46956
47001
|
// src/components/threads/ThreadDialog/Trigger/index.tsx
|
|
46957
|
-
import { jsx as
|
|
47002
|
+
import { jsx as _jsx83 } from "react/jsx-runtime";
|
|
46958
47003
|
function ownKeys43(e, r) {
|
|
46959
47004
|
var t = Object.keys(e);
|
|
46960
47005
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -46999,7 +47044,7 @@ function _toPrimitive43(t, r) {
|
|
|
46999
47044
|
return ("string" === r ? String : Number)(t);
|
|
47000
47045
|
}
|
|
47001
47046
|
var Root14 = function(t0) {
|
|
47002
|
-
var $ =
|
|
47047
|
+
var $ = _c82(14);
|
|
47003
47048
|
var children = t0.children, style = t0.style, className = t0.className;
|
|
47004
47049
|
var _useThreadDialogContext = useThreadDialogContext(), setIsOpen = _useThreadDialogContext.setIsOpen, isOpen = _useThreadDialogContext.isOpen;
|
|
47005
47050
|
var t1 = isOpen ? "none" : "flex";
|
|
@@ -47044,7 +47089,7 @@ var Root14 = function(t0) {
|
|
|
47044
47089
|
}
|
|
47045
47090
|
var t6;
|
|
47046
47091
|
if ($[8] !== children || $[9] !== className || $[10] !== t2 || $[11] !== t3 || $[12] !== t5) {
|
|
47047
|
-
t6 = /* @__PURE__ */
|
|
47092
|
+
t6 = /* @__PURE__ */ _jsx83(Flex26, {
|
|
47048
47093
|
display: t2,
|
|
47049
47094
|
onClick: t3,
|
|
47050
47095
|
direction: "column",
|
|
@@ -47070,17 +47115,17 @@ var Root14 = function(t0) {
|
|
|
47070
47115
|
return t6;
|
|
47071
47116
|
};
|
|
47072
47117
|
var Trigger = function(args) {
|
|
47073
|
-
var $ =
|
|
47118
|
+
var $ = _c82(3);
|
|
47074
47119
|
var t0;
|
|
47075
47120
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
47076
|
-
t0 = /* @__PURE__ */
|
|
47121
|
+
t0 = /* @__PURE__ */ _jsx83(Button4, {});
|
|
47077
47122
|
$[0] = t0;
|
|
47078
47123
|
} else {
|
|
47079
47124
|
t0 = $[0];
|
|
47080
47125
|
}
|
|
47081
47126
|
var t1;
|
|
47082
47127
|
if ($[1] !== args) {
|
|
47083
|
-
t1 = /* @__PURE__ */
|
|
47128
|
+
t1 = /* @__PURE__ */ _jsx83(Root14, _objectSpread43(_objectSpread43({}, args), {}, {
|
|
47084
47129
|
children: t0
|
|
47085
47130
|
}));
|
|
47086
47131
|
$[1] = args;
|
|
@@ -47096,15 +47141,15 @@ function _temp6(prev) {
|
|
|
47096
47141
|
return !prev;
|
|
47097
47142
|
}
|
|
47098
47143
|
// src/components/threads/ThreadDialog/Content/index.tsx
|
|
47099
|
-
import { c as
|
|
47144
|
+
import { c as _c84 } from "react-compiler-runtime";
|
|
47100
47145
|
import { Card as Card4, Inset as Inset2, Flex as Flex28 } from "@radix-ui/themes";
|
|
47101
47146
|
// src/components/threads/ThreadDialog/Close/index.tsx
|
|
47102
|
-
import { c as
|
|
47147
|
+
import { c as _c83 } from "react-compiler-runtime";
|
|
47103
47148
|
import { Cross1Icon } from "@radix-ui/react-icons";
|
|
47104
47149
|
import { IconButton as IconButton9, Flex as Flex27 } from "@radix-ui/themes";
|
|
47105
|
-
import { jsx as
|
|
47150
|
+
import { jsx as _jsx84 } from "react/jsx-runtime";
|
|
47106
47151
|
var Close = function() {
|
|
47107
|
-
var $ =
|
|
47152
|
+
var $ = _c83(9);
|
|
47108
47153
|
var _useThreadDialogContext = useThreadDialogContext(), setIsOpen = _useThreadDialogContext.setIsOpen, isOpen = _useThreadDialogContext.isOpen;
|
|
47109
47154
|
var t0 = isOpen ? "flex" : "none";
|
|
47110
47155
|
var t1;
|
|
@@ -47139,10 +47184,10 @@ var Close = function() {
|
|
|
47139
47184
|
}
|
|
47140
47185
|
var t4;
|
|
47141
47186
|
if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
47142
|
-
t4 = /* @__PURE__ */
|
|
47187
|
+
t4 = /* @__PURE__ */ _jsx84(IconButton9, {
|
|
47143
47188
|
size: "2",
|
|
47144
47189
|
variant: "soft",
|
|
47145
|
-
children: /* @__PURE__ */
|
|
47190
|
+
children: /* @__PURE__ */ _jsx84(Cross1Icon, {})
|
|
47146
47191
|
});
|
|
47147
47192
|
$[5] = t4;
|
|
47148
47193
|
} else {
|
|
@@ -47150,7 +47195,7 @@ var Close = function() {
|
|
|
47150
47195
|
}
|
|
47151
47196
|
var t5;
|
|
47152
47197
|
if ($[6] !== t1 || $[7] !== t2) {
|
|
47153
|
-
t5 = /* @__PURE__ */
|
|
47198
|
+
t5 = /* @__PURE__ */ _jsx84(Flex27, {
|
|
47154
47199
|
display: t1,
|
|
47155
47200
|
onClick: t2,
|
|
47156
47201
|
direction: "column",
|
|
@@ -47175,7 +47220,7 @@ function _temp7(prev) {
|
|
|
47175
47220
|
return !prev;
|
|
47176
47221
|
}
|
|
47177
47222
|
// src/components/threads/ThreadDialog/Content/index.tsx
|
|
47178
|
-
import { jsx as
|
|
47223
|
+
import { jsx as _jsx85, jsxs as _jsxs29 } from "react/jsx-runtime";
|
|
47179
47224
|
function ownKeys44(e, r) {
|
|
47180
47225
|
var t = Object.keys(e);
|
|
47181
47226
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -47220,7 +47265,7 @@ function _toPrimitive44(t, r) {
|
|
|
47220
47265
|
return ("string" === r ? String : Number)(t);
|
|
47221
47266
|
}
|
|
47222
47267
|
var Root15 = function(t0) {
|
|
47223
|
-
var $ =
|
|
47268
|
+
var $ = _c84(19);
|
|
47224
47269
|
var children = t0.children, className = t0.className, style = t0.style;
|
|
47225
47270
|
var isOpen = useThreadDialogContext().isOpen;
|
|
47226
47271
|
if (!isOpen) {
|
|
@@ -47307,7 +47352,7 @@ var Root15 = function(t0) {
|
|
|
47307
47352
|
}
|
|
47308
47353
|
var t10;
|
|
47309
47354
|
if ($[10] !== children) {
|
|
47310
|
-
t10 = /* @__PURE__ */
|
|
47355
|
+
t10 = /* @__PURE__ */ _jsx85(Inset2, {
|
|
47311
47356
|
clip: "padding-box",
|
|
47312
47357
|
side: "all",
|
|
47313
47358
|
pb: "current",
|
|
@@ -47321,7 +47366,7 @@ var Root15 = function(t0) {
|
|
|
47321
47366
|
}
|
|
47322
47367
|
var t11;
|
|
47323
47368
|
if ($[12] === Symbol.for("react.memo_cache_sentinel")) {
|
|
47324
|
-
t11 = /* @__PURE__ */
|
|
47369
|
+
t11 = /* @__PURE__ */ _jsx85(Close, {});
|
|
47325
47370
|
$[12] = t11;
|
|
47326
47371
|
} else {
|
|
47327
47372
|
t11 = $[12];
|
|
@@ -47343,7 +47388,7 @@ var Root15 = function(t0) {
|
|
|
47343
47388
|
}
|
|
47344
47389
|
var t13;
|
|
47345
47390
|
if ($[15] !== className || $[16] !== t12 || $[17] !== t6) {
|
|
47346
|
-
t13 = /* @__PURE__ */
|
|
47391
|
+
t13 = /* @__PURE__ */ _jsx85(Flex28, {
|
|
47347
47392
|
className: className,
|
|
47348
47393
|
direction: "column",
|
|
47349
47394
|
justify: "end",
|
|
@@ -47367,7 +47412,7 @@ var Root15 = function(t0) {
|
|
|
47367
47412
|
return t13;
|
|
47368
47413
|
};
|
|
47369
47414
|
var Messages3 = function(t0) {
|
|
47370
|
-
var $ =
|
|
47415
|
+
var $ = _c84(5);
|
|
47371
47416
|
var className = t0.className, style = t0.style;
|
|
47372
47417
|
var t1;
|
|
47373
47418
|
if ($[0] !== style) {
|
|
@@ -47383,7 +47428,7 @@ var Messages3 = function(t0) {
|
|
|
47383
47428
|
}
|
|
47384
47429
|
var t2;
|
|
47385
47430
|
if ($[2] !== className || $[3] !== t1) {
|
|
47386
|
-
t2 = /* @__PURE__ */
|
|
47431
|
+
t2 = /* @__PURE__ */ _jsx85(Thread.Messages, {
|
|
47387
47432
|
className: className,
|
|
47388
47433
|
style: t1
|
|
47389
47434
|
});
|
|
@@ -47396,11 +47441,11 @@ var Messages3 = function(t0) {
|
|
|
47396
47441
|
return t2;
|
|
47397
47442
|
};
|
|
47398
47443
|
var FormContainer = function(t0) {
|
|
47399
|
-
var $ =
|
|
47444
|
+
var $ = _c84(4);
|
|
47400
47445
|
var children = t0.children, className = t0.className, style = t0.style;
|
|
47401
47446
|
var t1;
|
|
47402
47447
|
if ($[0] !== children || $[1] !== className || $[2] !== style) {
|
|
47403
|
-
t1 = /* @__PURE__ */
|
|
47448
|
+
t1 = /* @__PURE__ */ _jsx85(Flex28, {
|
|
47404
47449
|
direction: "column",
|
|
47405
47450
|
pl: "5",
|
|
47406
47451
|
pr: "5",
|
|
@@ -47420,10 +47465,10 @@ var FormContainer = function(t0) {
|
|
|
47420
47465
|
return t1;
|
|
47421
47466
|
};
|
|
47422
47467
|
var Content8 = function(props) {
|
|
47423
|
-
var $ =
|
|
47468
|
+
var $ = _c84(4);
|
|
47424
47469
|
var t0;
|
|
47425
47470
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
47426
|
-
t0 = /* @__PURE__ */
|
|
47471
|
+
t0 = /* @__PURE__ */ _jsx85(Messages3, {});
|
|
47427
47472
|
$[0] = t0;
|
|
47428
47473
|
} else {
|
|
47429
47474
|
t0 = $[0];
|
|
@@ -47433,8 +47478,8 @@ var Content8 = function(props) {
|
|
|
47433
47478
|
t1 = /* @__PURE__ */ _jsxs29(Thread.Root, {
|
|
47434
47479
|
children: [
|
|
47435
47480
|
t0,
|
|
47436
|
-
/* @__PURE__ */
|
|
47437
|
-
children: /* @__PURE__ */
|
|
47481
|
+
/* @__PURE__ */ _jsx85(FormContainer, {
|
|
47482
|
+
children: /* @__PURE__ */ _jsx85(Thread.MessageForm, {})
|
|
47438
47483
|
})
|
|
47439
47484
|
]
|
|
47440
47485
|
});
|
|
@@ -47444,7 +47489,7 @@ var Content8 = function(props) {
|
|
|
47444
47489
|
}
|
|
47445
47490
|
var t2;
|
|
47446
47491
|
if ($[2] !== props) {
|
|
47447
|
-
t2 = /* @__PURE__ */
|
|
47492
|
+
t2 = /* @__PURE__ */ _jsx85(Root15, _objectSpread44(_objectSpread44({}, props), {}, {
|
|
47448
47493
|
children: t1
|
|
47449
47494
|
}));
|
|
47450
47495
|
$[2] = props;
|
|
@@ -47458,15 +47503,15 @@ Content8.Root = Root15;
|
|
|
47458
47503
|
Content8.Messages = Messages3;
|
|
47459
47504
|
Content8.FormContainer = FormContainer;
|
|
47460
47505
|
// src/components/threads/ThreadDialog/index.tsx
|
|
47461
|
-
import { jsx as
|
|
47506
|
+
import { jsx as _jsx86, jsxs as _jsxs30 } from "react/jsx-runtime";
|
|
47462
47507
|
var ThreadDialog = function() {
|
|
47463
|
-
var $ =
|
|
47508
|
+
var $ = _c85(1);
|
|
47464
47509
|
var t0;
|
|
47465
47510
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
47466
47511
|
t0 = /* @__PURE__ */ _jsxs30(Root13, {
|
|
47467
47512
|
children: [
|
|
47468
|
-
/* @__PURE__ */
|
|
47469
|
-
/* @__PURE__ */
|
|
47513
|
+
/* @__PURE__ */ _jsx86(Content8, {}),
|
|
47514
|
+
/* @__PURE__ */ _jsx86(Trigger, {})
|
|
47470
47515
|
]
|
|
47471
47516
|
});
|
|
47472
47517
|
$[0] = t0;
|
|
@@ -47479,11 +47524,11 @@ ThreadDialog.Root = Root13;
|
|
|
47479
47524
|
ThreadDialog.Trigger = Trigger;
|
|
47480
47525
|
ThreadDialog.Content = Content8;
|
|
47481
47526
|
// src/components/threads/AudioThreadDialog/index.tsx
|
|
47482
|
-
import { c as
|
|
47527
|
+
import { c as _c100 } from "react-compiler-runtime";
|
|
47483
47528
|
// src/components/threads/AudioThread/index.tsx
|
|
47484
|
-
import { c as
|
|
47529
|
+
import { c as _c99 } from "react-compiler-runtime";
|
|
47485
47530
|
// src/components/threads/AudioThread/Root/index.tsx
|
|
47486
|
-
import { c as
|
|
47531
|
+
import { c as _c91 } from "react-compiler-runtime";
|
|
47487
47532
|
import { Flex as Flex29 } from "@radix-ui/themes";
|
|
47488
47533
|
// src/contexts/threads/AudioThreadContext/index.ts
|
|
47489
47534
|
import { createContext as createContext13 } from "react";
|
|
@@ -47496,12 +47541,12 @@ var useAudioThreadContext = function() {
|
|
|
47496
47541
|
return useContext19(AudioThreadContext);
|
|
47497
47542
|
};
|
|
47498
47543
|
// src/components/audioRuntimes/TtsAudioRuntimeProvider.tsx
|
|
47499
|
-
import { c as
|
|
47544
|
+
import { c as _c90 } from "react-compiler-runtime";
|
|
47500
47545
|
// src/hooks/audioRuntimes/useTtsAudioRuntime/index.ts
|
|
47501
|
-
import { c as
|
|
47546
|
+
import { c as _c89 } from "react-compiler-runtime";
|
|
47502
47547
|
import { useMemo as useMemo18 } from "react";
|
|
47503
47548
|
// src/hooks/misc/usePermission/index.ts
|
|
47504
|
-
import { c as
|
|
47549
|
+
import { c as _c86 } from "react-compiler-runtime";
|
|
47505
47550
|
import { useEffect as useEffect7, useState as useState7 } from "react";
|
|
47506
47551
|
// src/hooks/misc/usePermission/util.ts
|
|
47507
47552
|
var noop = function() {};
|
|
@@ -47525,7 +47570,7 @@ function off(obj) {
|
|
|
47525
47570
|
}
|
|
47526
47571
|
// src/hooks/misc/usePermission/index.ts
|
|
47527
47572
|
var usePermission = function(permissionDesc) {
|
|
47528
|
-
var $ =
|
|
47573
|
+
var $ = _c86(3);
|
|
47529
47574
|
var _useState7 = _sliced_to_array(useState7(""), 2), state = _useState7[0], setState = _useState7[1];
|
|
47530
47575
|
var t0;
|
|
47531
47576
|
var t1;
|
|
@@ -47571,13 +47616,13 @@ var usePermission = function(permissionDesc) {
|
|
|
47571
47616
|
// src/hooks/audioThreads/useRecorder/index.ts
|
|
47572
47617
|
import dayjs3 from "dayjs";
|
|
47573
47618
|
import { useAudioCapture } from "use-audio-capture";
|
|
47574
|
-
import { useMemo as useMemo16, useRef as useRef7, useState as useState8, useCallback as
|
|
47619
|
+
import { useMemo as useMemo16, useRef as useRef7, useState as useState8, useCallback as useCallback5, useEffect as useEffect9 } from "react";
|
|
47575
47620
|
import { useAudioPlayer } from "react-use-audio-player";
|
|
47576
47621
|
// src/hooks/misc/useInterval.ts
|
|
47577
|
-
import { c as
|
|
47622
|
+
import { c as _c87 } from "react-compiler-runtime";
|
|
47578
47623
|
import { useEffect as useEffect8, useRef as useRef6 } from "react";
|
|
47579
47624
|
var useInterval = function(callback, delay) {
|
|
47580
|
-
var $ =
|
|
47625
|
+
var $ = _c87(5);
|
|
47581
47626
|
var savedCallback = useRef6(_temp8);
|
|
47582
47627
|
var t0;
|
|
47583
47628
|
if ($[0] !== callback) {
|
|
@@ -47784,7 +47829,7 @@ var useRecorder = function(_ref) {
|
|
|
47784
47829
|
}, [
|
|
47785
47830
|
audioEngine
|
|
47786
47831
|
]);
|
|
47787
|
-
var handleSilence =
|
|
47832
|
+
var handleSilence = useCallback5(function() {
|
|
47788
47833
|
if (!silenceAnalyser) return;
|
|
47789
47834
|
var frequencyData = new Uint8Array(silenceAnalyser.frequencyBinCount);
|
|
47790
47835
|
silenceAnalyser.getByteFrequencyData(frequencyData);
|
|
@@ -47830,8 +47875,8 @@ var useRecorder = function(_ref) {
|
|
|
47830
47875
|
});
|
|
47831
47876
|
};
|
|
47832
47877
|
// src/hooks/audioThreads/useMessageAudio/index.ts
|
|
47833
|
-
import { c as
|
|
47834
|
-
import { useMemo as useMemo17, useRef as useRef8, useState as useState9, useEffect as useEffect10, useCallback as
|
|
47878
|
+
import { c as _c88 } from "react-compiler-runtime";
|
|
47879
|
+
import { useMemo as useMemo17, useRef as useRef8, useState as useState9, useEffect as useEffect10, useCallback as useCallback6 } from "react";
|
|
47835
47880
|
import nlp from "compromise";
|
|
47836
47881
|
import { Howler } from "howler";
|
|
47837
47882
|
import { useAudioPlayer as useAudioPlayer2 } from "react-use-audio-player";
|
|
@@ -47913,7 +47958,7 @@ var getMessageSentences = function(_ref) {
|
|
|
47913
47958
|
};
|
|
47914
47959
|
var useMessageAudio = function(t0) {
|
|
47915
47960
|
var _latestMessageProps$l;
|
|
47916
|
-
var $ =
|
|
47961
|
+
var $ = _c88(49);
|
|
47917
47962
|
var _onEnd = t0.onEnd, passedPlay = t0.play;
|
|
47918
47963
|
var _useState9 = _sliced_to_array(useState9(false), 2), isAudioPlayed = _useState9[0], setIsAudioPlayed = _useState9[1];
|
|
47919
47964
|
var t1;
|
|
@@ -48293,7 +48338,7 @@ function _asyncToGenerator11(n) {
|
|
|
48293
48338
|
};
|
|
48294
48339
|
}
|
|
48295
48340
|
var useTtsAudioRuntime = function(t0) {
|
|
48296
|
-
var $ =
|
|
48341
|
+
var $ = _c89(30);
|
|
48297
48342
|
var play = t0.play;
|
|
48298
48343
|
var addToast = useToasts().addToast;
|
|
48299
48344
|
var queryClient = useQueryClient6();
|
|
@@ -48467,9 +48512,9 @@ function _temp24() {
|
|
|
48467
48512
|
return _temp24.apply(this, arguments);
|
|
48468
48513
|
}
|
|
48469
48514
|
// src/components/audioRuntimes/TtsAudioRuntimeProvider.tsx
|
|
48470
|
-
import { jsx as
|
|
48515
|
+
import { jsx as _jsx87 } from "react/jsx-runtime";
|
|
48471
48516
|
var TtsAudioRuntimeProvider = function(t0) {
|
|
48472
|
-
var $ =
|
|
48517
|
+
var $ = _c90(7);
|
|
48473
48518
|
var children = t0.children, play = t0.play;
|
|
48474
48519
|
var t1;
|
|
48475
48520
|
if ($[0] !== play) {
|
|
@@ -48494,7 +48539,7 @@ var TtsAudioRuntimeProvider = function(t0) {
|
|
|
48494
48539
|
}
|
|
48495
48540
|
var t3;
|
|
48496
48541
|
if ($[4] !== children || $[5] !== t2) {
|
|
48497
|
-
t3 = /* @__PURE__ */
|
|
48542
|
+
t3 = /* @__PURE__ */ _jsx87(AudioThreadContext.Provider, {
|
|
48498
48543
|
value: t2,
|
|
48499
48544
|
children: children
|
|
48500
48545
|
});
|
|
@@ -48507,7 +48552,7 @@ var TtsAudioRuntimeProvider = function(t0) {
|
|
|
48507
48552
|
return t3;
|
|
48508
48553
|
};
|
|
48509
48554
|
// src/components/threads/AudioThread/Root/index.tsx
|
|
48510
|
-
import { jsx as
|
|
48555
|
+
import { jsx as _jsx88 } from "react/jsx-runtime";
|
|
48511
48556
|
var _excluded5 = [
|
|
48512
48557
|
"children"
|
|
48513
48558
|
];
|
|
@@ -48579,11 +48624,11 @@ function _objectWithoutPropertiesLoose5(r, e) {
|
|
|
48579
48624
|
return t;
|
|
48580
48625
|
}
|
|
48581
48626
|
var Content9 = function(t0) {
|
|
48582
|
-
var $ =
|
|
48627
|
+
var $ = _c91(4);
|
|
48583
48628
|
var children = t0.children, className = t0.className, style = t0.style;
|
|
48584
48629
|
var t1;
|
|
48585
48630
|
if ($[0] !== children || $[1] !== className || $[2] !== style) {
|
|
48586
|
-
t1 = /* @__PURE__ */
|
|
48631
|
+
t1 = /* @__PURE__ */ _jsx88(Flex29, {
|
|
48587
48632
|
direction: "column",
|
|
48588
48633
|
flexGrow: "1",
|
|
48589
48634
|
p: "9",
|
|
@@ -48601,7 +48646,7 @@ var Content9 = function(t0) {
|
|
|
48601
48646
|
return t1;
|
|
48602
48647
|
};
|
|
48603
48648
|
var AudioRuntimeProvider = function(t0) {
|
|
48604
|
-
var $ =
|
|
48649
|
+
var $ = _c91(3);
|
|
48605
48650
|
var children = t0.children, play = t0.play;
|
|
48606
48651
|
var audioThreadContext = useAudioThreadContext();
|
|
48607
48652
|
if (audioThreadContext.audioRuntime) {
|
|
@@ -48609,7 +48654,7 @@ var AudioRuntimeProvider = function(t0) {
|
|
|
48609
48654
|
}
|
|
48610
48655
|
var t1;
|
|
48611
48656
|
if ($[0] !== children || $[1] !== play) {
|
|
48612
|
-
t1 = /* @__PURE__ */
|
|
48657
|
+
t1 = /* @__PURE__ */ _jsx88(TtsAudioRuntimeProvider, {
|
|
48613
48658
|
play: play,
|
|
48614
48659
|
children: children
|
|
48615
48660
|
});
|
|
@@ -48622,7 +48667,7 @@ var AudioRuntimeProvider = function(t0) {
|
|
|
48622
48667
|
return t1;
|
|
48623
48668
|
};
|
|
48624
48669
|
var Provider5 = function(t0) {
|
|
48625
|
-
var $ =
|
|
48670
|
+
var $ = _c91(9);
|
|
48626
48671
|
var children;
|
|
48627
48672
|
var rest;
|
|
48628
48673
|
if ($[0] !== t0) {
|
|
@@ -48649,7 +48694,7 @@ var Provider5 = function(t0) {
|
|
|
48649
48694
|
}
|
|
48650
48695
|
var t2;
|
|
48651
48696
|
if ($[6] !== children || $[7] !== t1) {
|
|
48652
|
-
t2 = /* @__PURE__ */
|
|
48697
|
+
t2 = /* @__PURE__ */ _jsx88(AudioThreadContext.Provider, {
|
|
48653
48698
|
value: t1,
|
|
48654
48699
|
children: children
|
|
48655
48700
|
});
|
|
@@ -48662,7 +48707,7 @@ var Provider5 = function(t0) {
|
|
|
48662
48707
|
return t2;
|
|
48663
48708
|
};
|
|
48664
48709
|
var Root16 = function(t0) {
|
|
48665
|
-
var $ =
|
|
48710
|
+
var $ = _c91(16);
|
|
48666
48711
|
var children;
|
|
48667
48712
|
var className;
|
|
48668
48713
|
var play;
|
|
@@ -48689,8 +48734,8 @@ var Root16 = function(t0) {
|
|
|
48689
48734
|
}
|
|
48690
48735
|
var t1;
|
|
48691
48736
|
if ($[6] !== children || $[7] !== className || $[8] !== style) {
|
|
48692
|
-
t1 = /* @__PURE__ */
|
|
48693
|
-
children: /* @__PURE__ */
|
|
48737
|
+
t1 = /* @__PURE__ */ _jsx88(ToastsProvider, {
|
|
48738
|
+
children: /* @__PURE__ */ _jsx88(Content9, {
|
|
48694
48739
|
className: className,
|
|
48695
48740
|
style: style,
|
|
48696
48741
|
children: children
|
|
@@ -48705,7 +48750,7 @@ var Root16 = function(t0) {
|
|
|
48705
48750
|
}
|
|
48706
48751
|
var t2;
|
|
48707
48752
|
if ($[10] !== play || $[11] !== t1) {
|
|
48708
|
-
t2 = /* @__PURE__ */
|
|
48753
|
+
t2 = /* @__PURE__ */ _jsx88(AudioRuntimeProvider, {
|
|
48709
48754
|
play: play,
|
|
48710
48755
|
children: t1
|
|
48711
48756
|
});
|
|
@@ -48717,7 +48762,7 @@ var Root16 = function(t0) {
|
|
|
48717
48762
|
}
|
|
48718
48763
|
var t3;
|
|
48719
48764
|
if ($[13] !== rest || $[14] !== t2) {
|
|
48720
|
-
t3 = /* @__PURE__ */
|
|
48765
|
+
t3 = /* @__PURE__ */ _jsx88(Provider5, _objectSpread47(_objectSpread47({}, rest), {}, {
|
|
48721
48766
|
children: t2
|
|
48722
48767
|
}));
|
|
48723
48768
|
$[13] = rest;
|
|
@@ -48729,21 +48774,21 @@ var Root16 = function(t0) {
|
|
|
48729
48774
|
return t3;
|
|
48730
48775
|
};
|
|
48731
48776
|
// src/components/threads/AudioThread/Visualization/index.tsx
|
|
48732
|
-
import { c as
|
|
48733
|
-
import { useState as useState11, useCallback as
|
|
48777
|
+
import { c as _c93 } from "react-compiler-runtime";
|
|
48778
|
+
import { useState as useState11, useCallback as useCallback8, useEffect as useEffect12, useContext as useContext20, createContext as createContext14 } from "react";
|
|
48734
48779
|
import _9 from "lodash";
|
|
48735
48780
|
import { Flex as Flex31 } from "@radix-ui/themes";
|
|
48736
48781
|
// src/components/threads/AudioThread/BarsVisualizer/index.tsx
|
|
48737
48782
|
import _8 from "lodash";
|
|
48738
48783
|
import { Flex as Flex30, Grid } from "@radix-ui/themes";
|
|
48739
|
-
import { useState as useState10, useEffect as useEffect11, useCallback as
|
|
48784
|
+
import { useState as useState10, useEffect as useEffect11, useCallback as useCallback7 } from "react";
|
|
48740
48785
|
import { cluster } from "radash";
|
|
48741
|
-
import { jsx as
|
|
48786
|
+
import { jsx as _jsx89 } from "react/jsx-runtime";
|
|
48742
48787
|
var barCount = 4;
|
|
48743
48788
|
var BarsVisualizer = function(_ref) {
|
|
48744
48789
|
var visualizationAnalyser = _ref.visualizationAnalyser, backgroundColor = _ref.backgroundColor, height = _ref.height, barWidth = _ref.barWidth;
|
|
48745
48790
|
var _useState10 = _sliced_to_array(useState10([]), 2), barHeights = _useState10[0], setBarHeights = _useState10[1];
|
|
48746
|
-
var draw =
|
|
48791
|
+
var draw = useCallback7(function(_ref2) {
|
|
48747
48792
|
var visualizationAnalyser_0 = _ref2.visualizationAnalyser;
|
|
48748
48793
|
if (!visualizationAnalyser_0) {
|
|
48749
48794
|
setBarHeights(Array(barCount).fill(0));
|
|
@@ -48769,7 +48814,7 @@ var BarsVisualizer = function(_ref) {
|
|
|
48769
48814
|
draw,
|
|
48770
48815
|
visualizationAnalyser
|
|
48771
48816
|
]);
|
|
48772
|
-
return /* @__PURE__ */
|
|
48817
|
+
return /* @__PURE__ */ _jsx89(Grid, {
|
|
48773
48818
|
columns: "".concat(barCount),
|
|
48774
48819
|
gap: "1",
|
|
48775
48820
|
width: "auto",
|
|
@@ -48778,12 +48823,12 @@ var BarsVisualizer = function(_ref) {
|
|
|
48778
48823
|
gridTemplateColumns: "repeat(4, minmax(0, 1fr))"
|
|
48779
48824
|
},
|
|
48780
48825
|
children: barHeights.map(function(barHeight, index) {
|
|
48781
|
-
return /* @__PURE__ */
|
|
48826
|
+
return /* @__PURE__ */ _jsx89(Flex30, {
|
|
48782
48827
|
direction: "column",
|
|
48783
48828
|
align: "center",
|
|
48784
48829
|
justify: "center",
|
|
48785
48830
|
height: height,
|
|
48786
|
-
children: /* @__PURE__ */
|
|
48831
|
+
children: /* @__PURE__ */ _jsx89(Flex30, {
|
|
48787
48832
|
minHeight: "50%",
|
|
48788
48833
|
maxHeight: "100%",
|
|
48789
48834
|
height: "".concat(barHeight + 20, "%"),
|
|
@@ -48798,10 +48843,10 @@ var BarsVisualizer = function(_ref) {
|
|
|
48798
48843
|
});
|
|
48799
48844
|
};
|
|
48800
48845
|
// src/hooks/audioThreads/useStatus/index.ts
|
|
48801
|
-
import { c as
|
|
48846
|
+
import { c as _c92 } from "react-compiler-runtime";
|
|
48802
48847
|
import { useMemo as useMemo19 } from "react";
|
|
48803
48848
|
var useStatus = function() {
|
|
48804
|
-
var $ =
|
|
48849
|
+
var $ = _c92(2);
|
|
48805
48850
|
var audioRuntime = useAudioThreadContext().audioRuntime;
|
|
48806
48851
|
var t0;
|
|
48807
48852
|
bb0: {
|
|
@@ -48849,7 +48894,7 @@ var useStatus = function() {
|
|
|
48849
48894
|
return t1;
|
|
48850
48895
|
};
|
|
48851
48896
|
// src/components/threads/AudioThread/Visualization/index.tsx
|
|
48852
|
-
import { jsx as
|
|
48897
|
+
import { jsx as _jsx90, jsxs as _jsxs31 } from "react/jsx-runtime";
|
|
48853
48898
|
var _excluded6 = [
|
|
48854
48899
|
"children"
|
|
48855
48900
|
];
|
|
@@ -48930,7 +48975,7 @@ var Provider6 = function(_ref) {
|
|
|
48930
48975
|
var children = _ref.children;
|
|
48931
48976
|
var audioThreadContext = useAudioThreadContext();
|
|
48932
48977
|
var _useState11 = _sliced_to_array(useState11(0), 2), scale = _useState11[0], setScale = _useState11[1];
|
|
48933
|
-
var draw =
|
|
48978
|
+
var draw = useCallback8(function(_ref2) {
|
|
48934
48979
|
var visualizationAnalyser = _ref2.visualizationAnalyser;
|
|
48935
48980
|
if (!visualizationAnalyser) {
|
|
48936
48981
|
setScale(1);
|
|
@@ -48953,7 +48998,7 @@ var Provider6 = function(_ref) {
|
|
|
48953
48998
|
draw,
|
|
48954
48999
|
audioThreadContext
|
|
48955
49000
|
]);
|
|
48956
|
-
return /* @__PURE__ */
|
|
49001
|
+
return /* @__PURE__ */ _jsx90(AudioThreadVisualizationContext.Provider, {
|
|
48957
49002
|
value: {
|
|
48958
49003
|
scale: scale
|
|
48959
49004
|
},
|
|
@@ -48961,7 +49006,7 @@ var Provider6 = function(_ref) {
|
|
|
48961
49006
|
});
|
|
48962
49007
|
};
|
|
48963
49008
|
var Root17 = function(t0) {
|
|
48964
|
-
var $ =
|
|
49009
|
+
var $ = _c93(6);
|
|
48965
49010
|
var children;
|
|
48966
49011
|
var rest;
|
|
48967
49012
|
if ($[0] !== t0) {
|
|
@@ -48978,8 +49023,8 @@ var Root17 = function(t0) {
|
|
|
48978
49023
|
}
|
|
48979
49024
|
var t1;
|
|
48980
49025
|
if ($[3] !== children || $[4] !== rest) {
|
|
48981
|
-
t1 = /* @__PURE__ */
|
|
48982
|
-
children: /* @__PURE__ */
|
|
49026
|
+
t1 = /* @__PURE__ */ _jsx90(Provider6, {
|
|
49027
|
+
children: /* @__PURE__ */ _jsx90(Flex31, _objectSpread48(_objectSpread48({
|
|
48983
49028
|
direction: "column",
|
|
48984
49029
|
align: "center",
|
|
48985
49030
|
justify: "center",
|
|
@@ -48998,7 +49043,7 @@ var Root17 = function(t0) {
|
|
|
48998
49043
|
return t1;
|
|
48999
49044
|
};
|
|
49000
49045
|
var BarsVisualizer2 = function(t0) {
|
|
49001
|
-
var $ =
|
|
49046
|
+
var $ = _c93(10);
|
|
49002
49047
|
var rest;
|
|
49003
49048
|
var t1;
|
|
49004
49049
|
var t2;
|
|
@@ -49024,7 +49069,7 @@ var BarsVisualizer2 = function(t0) {
|
|
|
49024
49069
|
var t3 = status === "playing" ? "var(--accent-11)" : "var(--gray-11)";
|
|
49025
49070
|
var t4;
|
|
49026
49071
|
if ($[4] !== audioThreadContext.audioRuntime.assistant.visualizationAnalyser || $[5] !== barWidth || $[6] !== height || $[7] !== rest || $[8] !== t3) {
|
|
49027
|
-
t4 = /* @__PURE__ */
|
|
49072
|
+
t4 = /* @__PURE__ */ _jsx90(BarsVisualizer, _objectSpread48({
|
|
49028
49073
|
visualizationAnalyser: audioThreadContext.audioRuntime.assistant.visualizationAnalyser,
|
|
49029
49074
|
backgroundColor: t3,
|
|
49030
49075
|
height: height,
|
|
@@ -49042,7 +49087,7 @@ var BarsVisualizer2 = function(t0) {
|
|
|
49042
49087
|
return t4;
|
|
49043
49088
|
};
|
|
49044
49089
|
var AssistantVisualizationRoot = function(t0) {
|
|
49045
|
-
var $ =
|
|
49090
|
+
var $ = _c93(17);
|
|
49046
49091
|
var children;
|
|
49047
49092
|
var rest;
|
|
49048
49093
|
var t1;
|
|
@@ -49094,7 +49139,7 @@ var AssistantVisualizationRoot = function(t0) {
|
|
|
49094
49139
|
}
|
|
49095
49140
|
var t6;
|
|
49096
49141
|
if ($[11] !== children || $[12] !== height || $[13] !== rest || $[14] !== t5 || $[15] !== width2) {
|
|
49097
|
-
t6 = /* @__PURE__ */
|
|
49142
|
+
t6 = /* @__PURE__ */ _jsx90(Flex31, _objectSpread48(_objectSpread48({
|
|
49098
49143
|
align: "center",
|
|
49099
49144
|
justify: "center",
|
|
49100
49145
|
height: height,
|
|
@@ -49115,17 +49160,17 @@ var AssistantVisualizationRoot = function(t0) {
|
|
|
49115
49160
|
return t6;
|
|
49116
49161
|
};
|
|
49117
49162
|
var AssistantVisualization = function(props) {
|
|
49118
|
-
var $ =
|
|
49163
|
+
var $ = _c93(3);
|
|
49119
49164
|
var t0;
|
|
49120
49165
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49121
|
-
t0 = /* @__PURE__ */
|
|
49166
|
+
t0 = /* @__PURE__ */ _jsx90(BarsVisualizer2, {});
|
|
49122
49167
|
$[0] = t0;
|
|
49123
49168
|
} else {
|
|
49124
49169
|
t0 = $[0];
|
|
49125
49170
|
}
|
|
49126
49171
|
var t1;
|
|
49127
49172
|
if ($[1] !== props) {
|
|
49128
|
-
t1 = /* @__PURE__ */
|
|
49173
|
+
t1 = /* @__PURE__ */ _jsx90(AssistantVisualizationRoot, _objectSpread48(_objectSpread48({}, props), {}, {
|
|
49129
49174
|
children: t0
|
|
49130
49175
|
}));
|
|
49131
49176
|
$[1] = props;
|
|
@@ -49138,18 +49183,18 @@ var AssistantVisualization = function(props) {
|
|
|
49138
49183
|
AssistantVisualization.Root = AssistantVisualizationRoot;
|
|
49139
49184
|
AssistantVisualization.BarsVisualizer = BarsVisualizer2;
|
|
49140
49185
|
var AssistantInfo = function(props) {
|
|
49141
|
-
var $ =
|
|
49186
|
+
var $ = _c93(6);
|
|
49142
49187
|
var assistantNameContext = useContext20(AssistantNameContext);
|
|
49143
49188
|
var t0;
|
|
49144
49189
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49145
|
-
t0 = /* @__PURE__ */
|
|
49190
|
+
t0 = /* @__PURE__ */ _jsx90(MessageGroup.AssistantAvatar, {});
|
|
49146
49191
|
$[0] = t0;
|
|
49147
49192
|
} else {
|
|
49148
49193
|
t0 = $[0];
|
|
49149
49194
|
}
|
|
49150
49195
|
var t1;
|
|
49151
49196
|
if ($[1] !== assistantNameContext) {
|
|
49152
|
-
t1 = /* @__PURE__ */
|
|
49197
|
+
t1 = /* @__PURE__ */ _jsx90(MessageGroup.Name, {
|
|
49153
49198
|
children: assistantNameContext
|
|
49154
49199
|
});
|
|
49155
49200
|
$[1] = assistantNameContext;
|
|
@@ -49178,12 +49223,12 @@ var AssistantInfo = function(props) {
|
|
|
49178
49223
|
return t2;
|
|
49179
49224
|
};
|
|
49180
49225
|
var Visualization = function(props) {
|
|
49181
|
-
var $ =
|
|
49226
|
+
var $ = _c93(4);
|
|
49182
49227
|
var t0;
|
|
49183
49228
|
var t1;
|
|
49184
49229
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49185
|
-
t0 = /* @__PURE__ */
|
|
49186
|
-
t1 = /* @__PURE__ */
|
|
49230
|
+
t0 = /* @__PURE__ */ _jsx90(AssistantVisualization, {});
|
|
49231
|
+
t1 = /* @__PURE__ */ _jsx90(AssistantInfo, {});
|
|
49187
49232
|
$[0] = t0;
|
|
49188
49233
|
$[1] = t1;
|
|
49189
49234
|
} else {
|
|
@@ -49210,11 +49255,11 @@ Visualization.Provider = Provider6;
|
|
|
49210
49255
|
Visualization.AssistantVisualization = AssistantVisualization;
|
|
49211
49256
|
Visualization.AssistantInfo = AssistantInfo;
|
|
49212
49257
|
// src/components/threads/AudioThread/Status/index.tsx
|
|
49213
|
-
import { c as
|
|
49258
|
+
import { c as _c95 } from "react-compiler-runtime";
|
|
49214
49259
|
// src/components/threads/AudioThread/Status/StatusMessages.tsx
|
|
49215
|
-
import { c as
|
|
49260
|
+
import { c as _c94 } from "react-compiler-runtime";
|
|
49216
49261
|
import { Flex as Flex32, Text as Text9 } from "@radix-ui/themes";
|
|
49217
|
-
import { jsx as
|
|
49262
|
+
import { jsx as _jsx91, jsxs as _jsxs32 } from "react/jsx-runtime";
|
|
49218
49263
|
var html = function(_ref) {
|
|
49219
49264
|
var texts = _ref.texts;
|
|
49220
49265
|
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) {
|
|
@@ -49222,11 +49267,11 @@ var html = function(_ref) {
|
|
|
49222
49267
|
}).join(""), "\n }");
|
|
49223
49268
|
};
|
|
49224
49269
|
var StatusMessages = function(t0) {
|
|
49225
|
-
var $ =
|
|
49270
|
+
var $ = _c94(9);
|
|
49226
49271
|
var texts = t0.texts, className = t0.className, style = t0.style;
|
|
49227
49272
|
var t1;
|
|
49228
49273
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49229
|
-
t1 = /* @__PURE__ */
|
|
49274
|
+
t1 = /* @__PURE__ */ _jsx91(Text9, {
|
|
49230
49275
|
size: "2",
|
|
49231
49276
|
weight: "regular",
|
|
49232
49277
|
color: "gray",
|
|
@@ -49249,7 +49294,7 @@ var StatusMessages = function(t0) {
|
|
|
49249
49294
|
}
|
|
49250
49295
|
var t3;
|
|
49251
49296
|
if ($[3] !== t2) {
|
|
49252
|
-
t3 = /* @__PURE__ */
|
|
49297
|
+
t3 = /* @__PURE__ */ _jsx91("style", {
|
|
49253
49298
|
dangerouslySetInnerHTML: {
|
|
49254
49299
|
__html: t2
|
|
49255
49300
|
}
|
|
@@ -49281,7 +49326,7 @@ var StatusMessages = function(t0) {
|
|
|
49281
49326
|
return t4;
|
|
49282
49327
|
};
|
|
49283
49328
|
// src/components/threads/AudioThread/Status/index.tsx
|
|
49284
|
-
import { jsx as
|
|
49329
|
+
import { jsx as _jsx92 } from "react/jsx-runtime";
|
|
49285
49330
|
function ownKeys49(e, r) {
|
|
49286
49331
|
var t = Object.keys(e);
|
|
49287
49332
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -49326,7 +49371,7 @@ function _toPrimitive49(t, r) {
|
|
|
49326
49371
|
return ("string" === r ? String : Number)(t);
|
|
49327
49372
|
}
|
|
49328
49373
|
var Status = function(props) {
|
|
49329
|
-
var $ =
|
|
49374
|
+
var $ = _c95(12);
|
|
49330
49375
|
var status = useStatus().status;
|
|
49331
49376
|
if (status === "recording") {
|
|
49332
49377
|
var _t;
|
|
@@ -49343,7 +49388,7 @@ var Status = function(props) {
|
|
|
49343
49388
|
}
|
|
49344
49389
|
var _t2;
|
|
49345
49390
|
if ($[1] !== props) {
|
|
49346
|
-
_t2 = /* @__PURE__ */
|
|
49391
|
+
_t2 = /* @__PURE__ */ _jsx92(StatusMessages, _objectSpread49({
|
|
49347
49392
|
texts: _t
|
|
49348
49393
|
}, props));
|
|
49349
49394
|
$[1] = props;
|
|
@@ -49369,7 +49414,7 @@ var Status = function(props) {
|
|
|
49369
49414
|
}
|
|
49370
49415
|
var _t4;
|
|
49371
49416
|
if ($[4] !== props) {
|
|
49372
|
-
_t4 = /* @__PURE__ */
|
|
49417
|
+
_t4 = /* @__PURE__ */ _jsx92(StatusMessages, _objectSpread49({
|
|
49373
49418
|
texts: _t3
|
|
49374
49419
|
}, props));
|
|
49375
49420
|
$[4] = props;
|
|
@@ -49391,7 +49436,7 @@ var Status = function(props) {
|
|
|
49391
49436
|
}
|
|
49392
49437
|
var _t6;
|
|
49393
49438
|
if ($[7] !== props) {
|
|
49394
|
-
_t6 = /* @__PURE__ */
|
|
49439
|
+
_t6 = /* @__PURE__ */ _jsx92(StatusMessages, _objectSpread49({
|
|
49395
49440
|
texts: _t5
|
|
49396
49441
|
}, props));
|
|
49397
49442
|
$[7] = props;
|
|
@@ -49412,7 +49457,7 @@ var Status = function(props) {
|
|
|
49412
49457
|
}
|
|
49413
49458
|
var t1;
|
|
49414
49459
|
if ($[10] !== props) {
|
|
49415
|
-
t1 = /* @__PURE__ */
|
|
49460
|
+
t1 = /* @__PURE__ */ _jsx92(StatusMessages, _objectSpread49({
|
|
49416
49461
|
texts: t0
|
|
49417
49462
|
}, props));
|
|
49418
49463
|
$[10] = props;
|
|
@@ -49423,11 +49468,11 @@ var Status = function(props) {
|
|
|
49423
49468
|
return t1;
|
|
49424
49469
|
};
|
|
49425
49470
|
// src/components/threads/AudioThread/Form/index.tsx
|
|
49426
|
-
import { c as
|
|
49471
|
+
import { c as _c98 } from "react-compiler-runtime";
|
|
49427
49472
|
import { Flex as Flex34 } from "@radix-ui/themes";
|
|
49428
49473
|
// src/components/threads/AudioThread/Form/MicIcon.tsx
|
|
49429
|
-
import { c as
|
|
49430
|
-
import { jsx as
|
|
49474
|
+
import { c as _c96 } from "react-compiler-runtime";
|
|
49475
|
+
import { jsx as _jsx93 } from "react/jsx-runtime";
|
|
49431
49476
|
function ownKeys50(e, r) {
|
|
49432
49477
|
var t = Object.keys(e);
|
|
49433
49478
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -49472,10 +49517,10 @@ function _toPrimitive50(t, r) {
|
|
|
49472
49517
|
return ("string" === r ? String : Number)(t);
|
|
49473
49518
|
}
|
|
49474
49519
|
var MicIcon = function(props) {
|
|
49475
|
-
var $ =
|
|
49520
|
+
var $ = _c96(3);
|
|
49476
49521
|
var t0;
|
|
49477
49522
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49478
|
-
t0 = /* @__PURE__ */
|
|
49523
|
+
t0 = /* @__PURE__ */ _jsx93("path", {
|
|
49479
49524
|
stroke: "none",
|
|
49480
49525
|
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"
|
|
49481
49526
|
});
|
|
@@ -49485,7 +49530,7 @@ var MicIcon = function(props) {
|
|
|
49485
49530
|
}
|
|
49486
49531
|
var t1;
|
|
49487
49532
|
if ($[1] !== props) {
|
|
49488
|
-
t1 = /* @__PURE__ */
|
|
49533
|
+
t1 = /* @__PURE__ */ _jsx93("svg", _objectSpread50(_objectSpread50({
|
|
49489
49534
|
xmlns: "http://www.w3.org/2000/svg",
|
|
49490
49535
|
fill: "currentColor",
|
|
49491
49536
|
stroke: "currentColor",
|
|
@@ -49504,29 +49549,29 @@ var MicIcon = function(props) {
|
|
|
49504
49549
|
return t1;
|
|
49505
49550
|
};
|
|
49506
49551
|
// src/components/threads/AudioThread/Form/ActionButton/index.tsx
|
|
49507
|
-
import { c as
|
|
49552
|
+
import { c as _c97 } from "react-compiler-runtime";
|
|
49508
49553
|
import { Flex as Flex33, IconButton as IconButton10 } from "@radix-ui/themes";
|
|
49509
49554
|
import { StopIcon as StopIcon2, PauseIcon as PauseIcon2, ArrowUpIcon as ArrowUpIcon3, ResumeIcon } from "@radix-ui/react-icons";
|
|
49510
|
-
import { jsx as
|
|
49555
|
+
import { jsx as _jsx94, jsxs as _jsxs33 } from "react/jsx-runtime";
|
|
49511
49556
|
var ActionButton = function() {
|
|
49512
|
-
var $ =
|
|
49557
|
+
var $ = _c97(27);
|
|
49513
49558
|
var status = useStatus().status;
|
|
49514
49559
|
var audioThreadContext = useAudioThreadContext();
|
|
49515
49560
|
var superinterfaceContext = useSuperinterfaceContext();
|
|
49516
49561
|
if (status === "recording") {
|
|
49517
49562
|
var _t;
|
|
49518
49563
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49519
|
-
_t = /* @__PURE__ */
|
|
49564
|
+
_t = /* @__PURE__ */ _jsx94(PauseIcon2, {});
|
|
49520
49565
|
$[0] = _t;
|
|
49521
49566
|
} else {
|
|
49522
49567
|
_t = $[0];
|
|
49523
49568
|
}
|
|
49524
49569
|
var t1;
|
|
49525
49570
|
if ($[1] !== audioThreadContext.audioRuntime.user.pause) {
|
|
49526
|
-
t1 = /* @__PURE__ */
|
|
49571
|
+
t1 = /* @__PURE__ */ _jsx94(Flex33, {
|
|
49527
49572
|
mr: "3",
|
|
49528
49573
|
ml: "-7",
|
|
49529
|
-
children: /* @__PURE__ */
|
|
49574
|
+
children: /* @__PURE__ */ _jsx94(IconButton10, {
|
|
49530
49575
|
onClick: audioThreadContext.audioRuntime.user.pause,
|
|
49531
49576
|
color: "gray",
|
|
49532
49577
|
variant: "soft",
|
|
@@ -49541,14 +49586,14 @@ var ActionButton = function() {
|
|
|
49541
49586
|
}
|
|
49542
49587
|
var t2;
|
|
49543
49588
|
if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49544
|
-
t2 = /* @__PURE__ */
|
|
49589
|
+
t2 = /* @__PURE__ */ _jsx94(ArrowUpIcon3, {});
|
|
49545
49590
|
$[3] = t2;
|
|
49546
49591
|
} else {
|
|
49547
49592
|
t2 = $[3];
|
|
49548
49593
|
}
|
|
49549
49594
|
var t3;
|
|
49550
49595
|
if ($[4] !== audioThreadContext.audioRuntime.user.stop) {
|
|
49551
|
-
t3 = /* @__PURE__ */
|
|
49596
|
+
t3 = /* @__PURE__ */ _jsx94(IconButton10, {
|
|
49552
49597
|
onClick: audioThreadContext.audioRuntime.user.stop,
|
|
49553
49598
|
highContrast: true,
|
|
49554
49599
|
variant: "soft",
|
|
@@ -49580,14 +49625,14 @@ var ActionButton = function() {
|
|
|
49580
49625
|
if (status === "recorderPaused") {
|
|
49581
49626
|
var _t2;
|
|
49582
49627
|
if ($[9] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49583
|
-
_t2 = /* @__PURE__ */
|
|
49628
|
+
_t2 = /* @__PURE__ */ _jsx94(ResumeIcon, {});
|
|
49584
49629
|
$[9] = _t2;
|
|
49585
49630
|
} else {
|
|
49586
49631
|
_t2 = $[9];
|
|
49587
49632
|
}
|
|
49588
49633
|
var _t3;
|
|
49589
49634
|
if ($[10] !== audioThreadContext.audioRuntime.user.resume) {
|
|
49590
|
-
_t3 = /* @__PURE__ */
|
|
49635
|
+
_t3 = /* @__PURE__ */ _jsx94(IconButton10, {
|
|
49591
49636
|
onClick: audioThreadContext.audioRuntime.user.resume,
|
|
49592
49637
|
color: "red",
|
|
49593
49638
|
size: "4",
|
|
@@ -49603,7 +49648,7 @@ var ActionButton = function() {
|
|
|
49603
49648
|
if (status === "idle") {
|
|
49604
49649
|
var _t4;
|
|
49605
49650
|
if ($[12] !== audioThreadContext.audioRuntime.user) {
|
|
49606
|
-
_t4 = /* @__PURE__ */
|
|
49651
|
+
_t4 = /* @__PURE__ */ _jsx94(IconButton10, {
|
|
49607
49652
|
onClick: function() {
|
|
49608
49653
|
return audioThreadContext.audioRuntime.user.start();
|
|
49609
49654
|
},
|
|
@@ -49635,14 +49680,14 @@ var ActionButton = function() {
|
|
|
49635
49680
|
}
|
|
49636
49681
|
var _t6;
|
|
49637
49682
|
if ($[18] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49638
|
-
_t6 = /* @__PURE__ */
|
|
49683
|
+
_t6 = /* @__PURE__ */ _jsx94(StopIcon2, {});
|
|
49639
49684
|
$[18] = _t6;
|
|
49640
49685
|
} else {
|
|
49641
49686
|
_t6 = $[18];
|
|
49642
49687
|
}
|
|
49643
49688
|
var _t7;
|
|
49644
49689
|
if ($[19] !== _t5) {
|
|
49645
|
-
_t7 = /* @__PURE__ */
|
|
49690
|
+
_t7 = /* @__PURE__ */ _jsx94(IconButton10, {
|
|
49646
49691
|
onClick: _t5,
|
|
49647
49692
|
size: "4",
|
|
49648
49693
|
color: "gray",
|
|
@@ -49669,14 +49714,14 @@ var ActionButton = function() {
|
|
|
49669
49714
|
}
|
|
49670
49715
|
var _t9;
|
|
49671
49716
|
if ($[23] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49672
|
-
_t9 = /* @__PURE__ */
|
|
49717
|
+
_t9 = /* @__PURE__ */ _jsx94(ResumeIcon, {});
|
|
49673
49718
|
$[23] = _t9;
|
|
49674
49719
|
} else {
|
|
49675
49720
|
_t9 = $[23];
|
|
49676
49721
|
}
|
|
49677
49722
|
var _t10;
|
|
49678
49723
|
if ($[24] !== _t8) {
|
|
49679
|
-
_t10 = /* @__PURE__ */
|
|
49724
|
+
_t10 = /* @__PURE__ */ _jsx94(IconButton10, {
|
|
49680
49725
|
onClick: _t8,
|
|
49681
49726
|
size: "4",
|
|
49682
49727
|
children: _t9
|
|
@@ -49690,7 +49735,7 @@ var ActionButton = function() {
|
|
|
49690
49735
|
}
|
|
49691
49736
|
var t0;
|
|
49692
49737
|
if ($[26] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49693
|
-
t0 = /* @__PURE__ */
|
|
49738
|
+
t0 = /* @__PURE__ */ _jsx94(IconButton10, {
|
|
49694
49739
|
size: "4",
|
|
49695
49740
|
variant: "soft",
|
|
49696
49741
|
disabled: true
|
|
@@ -49702,7 +49747,7 @@ var ActionButton = function() {
|
|
|
49702
49747
|
return t0;
|
|
49703
49748
|
};
|
|
49704
49749
|
// src/components/threads/AudioThread/Form/index.tsx
|
|
49705
|
-
import { jsx as
|
|
49750
|
+
import { jsx as _jsx95, jsxs as _jsxs34 } from "react/jsx-runtime";
|
|
49706
49751
|
function ownKeys51(e, r) {
|
|
49707
49752
|
var t = Object.keys(e);
|
|
49708
49753
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -49747,17 +49792,17 @@ function _toPrimitive51(t, r) {
|
|
|
49747
49792
|
return ("string" === r ? String : Number)(t);
|
|
49748
49793
|
}
|
|
49749
49794
|
var Form = function(props) {
|
|
49750
|
-
var $ =
|
|
49795
|
+
var $ = _c98(17);
|
|
49751
49796
|
var status = useStatus().status;
|
|
49752
49797
|
var audioThreadContext = useAudioThreadContext();
|
|
49753
49798
|
var t0 = status === "recording" ? "var(--accent-11)" : "var(--gray-11)";
|
|
49754
49799
|
var t1;
|
|
49755
49800
|
if ($[0] !== t0) {
|
|
49756
|
-
t1 = /* @__PURE__ */
|
|
49801
|
+
t1 = /* @__PURE__ */ _jsx95(Flex34, {
|
|
49757
49802
|
ml: "-22.5px",
|
|
49758
49803
|
mr: "2",
|
|
49759
49804
|
align: "center",
|
|
49760
|
-
children: /* @__PURE__ */
|
|
49805
|
+
children: /* @__PURE__ */ _jsx95(MicIcon, {
|
|
49761
49806
|
style: {
|
|
49762
49807
|
color: t0
|
|
49763
49808
|
}
|
|
@@ -49783,7 +49828,7 @@ var Form = function(props) {
|
|
|
49783
49828
|
var t4 = status === "recording" ? "var(--accent-11)" : "var(--gray-11)";
|
|
49784
49829
|
var t5;
|
|
49785
49830
|
if ($[4] !== audioThreadContext.audioRuntime.user.visualizationAnalyser || $[5] !== t4) {
|
|
49786
|
-
t5 = /* @__PURE__ */
|
|
49831
|
+
t5 = /* @__PURE__ */ _jsx95(BarsVisualizer, {
|
|
49787
49832
|
visualizationAnalyser: audioThreadContext.audioRuntime.user.visualizationAnalyser,
|
|
49788
49833
|
backgroundColor: t4,
|
|
49789
49834
|
height: "20px",
|
|
@@ -49797,7 +49842,7 @@ var Form = function(props) {
|
|
|
49797
49842
|
}
|
|
49798
49843
|
var t6;
|
|
49799
49844
|
if ($[7] !== t3 || $[8] !== t5) {
|
|
49800
|
-
t6 = /* @__PURE__ */
|
|
49845
|
+
t6 = /* @__PURE__ */ _jsx95(Flex34, {
|
|
49801
49846
|
px: "2",
|
|
49802
49847
|
py: "1",
|
|
49803
49848
|
style: t3,
|
|
@@ -49827,7 +49872,7 @@ var Form = function(props) {
|
|
|
49827
49872
|
}
|
|
49828
49873
|
var t8;
|
|
49829
49874
|
if ($[13] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49830
|
-
t8 = /* @__PURE__ */
|
|
49875
|
+
t8 = /* @__PURE__ */ _jsx95(ActionButton, {});
|
|
49831
49876
|
$[13] = t8;
|
|
49832
49877
|
} else {
|
|
49833
49878
|
t8 = $[13];
|
|
@@ -49852,7 +49897,7 @@ var Form = function(props) {
|
|
|
49852
49897
|
return t9;
|
|
49853
49898
|
};
|
|
49854
49899
|
// src/components/threads/AudioThread/index.tsx
|
|
49855
|
-
import { jsx as
|
|
49900
|
+
import { jsx as _jsx96, jsxs as _jsxs35 } from "react/jsx-runtime";
|
|
49856
49901
|
function ownKeys52(e, r) {
|
|
49857
49902
|
var t = Object.keys(e);
|
|
49858
49903
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -49897,14 +49942,14 @@ function _toPrimitive52(t, r) {
|
|
|
49897
49942
|
return ("string" === r ? String : Number)(t);
|
|
49898
49943
|
}
|
|
49899
49944
|
var AudioThread = function(props) {
|
|
49900
|
-
var $ =
|
|
49945
|
+
var $ = _c99(5);
|
|
49901
49946
|
var t0;
|
|
49902
49947
|
var t1;
|
|
49903
49948
|
var t2;
|
|
49904
49949
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49905
|
-
t0 = /* @__PURE__ */
|
|
49906
|
-
t1 = /* @__PURE__ */
|
|
49907
|
-
t2 = /* @__PURE__ */
|
|
49950
|
+
t0 = /* @__PURE__ */ _jsx96(Visualization, {});
|
|
49951
|
+
t1 = /* @__PURE__ */ _jsx96(Status, {});
|
|
49952
|
+
t2 = /* @__PURE__ */ _jsx96(Form, {});
|
|
49908
49953
|
$[0] = t0;
|
|
49909
49954
|
$[1] = t1;
|
|
49910
49955
|
$[2] = t2;
|
|
@@ -49934,7 +49979,7 @@ AudioThread.Visualization = Visualization;
|
|
|
49934
49979
|
AudioThread.Status = Status;
|
|
49935
49980
|
AudioThread.Form = Form;
|
|
49936
49981
|
// src/components/threads/AudioThreadDialog/index.tsx
|
|
49937
|
-
import { jsx as
|
|
49982
|
+
import { jsx as _jsx97, jsxs as _jsxs36 } from "react/jsx-runtime";
|
|
49938
49983
|
function ownKeys53(e, r) {
|
|
49939
49984
|
var t = Object.keys(e);
|
|
49940
49985
|
if (Object.getOwnPropertySymbols) {
|
|
@@ -49979,14 +50024,14 @@ function _toPrimitive53(t, r) {
|
|
|
49979
50024
|
return ("string" === r ? String : Number)(t);
|
|
49980
50025
|
}
|
|
49981
50026
|
var AudioThreadDialog = function(props) {
|
|
49982
|
-
var $ =
|
|
50027
|
+
var $ = _c100(4);
|
|
49983
50028
|
var t0;
|
|
49984
50029
|
var t1;
|
|
49985
50030
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
49986
|
-
t0 = /* @__PURE__ */
|
|
49987
|
-
children: /* @__PURE__ */
|
|
50031
|
+
t0 = /* @__PURE__ */ _jsx97(Content8.Root, {
|
|
50032
|
+
children: /* @__PURE__ */ _jsx97(AudioThread, {})
|
|
49988
50033
|
});
|
|
49989
|
-
t1 = /* @__PURE__ */
|
|
50034
|
+
t1 = /* @__PURE__ */ _jsx97(Trigger, {});
|
|
49990
50035
|
$[0] = t0;
|
|
49991
50036
|
$[1] = t1;
|
|
49992
50037
|
} else {
|
|
@@ -50501,10 +50546,10 @@ var useWebrtcAudioRuntime = function() {
|
|
|
50501
50546
|
]);
|
|
50502
50547
|
};
|
|
50503
50548
|
// src/components/audioRuntimes/WebrtcAudioRuntimeProvider.tsx
|
|
50504
|
-
import { c as
|
|
50505
|
-
import { jsx as
|
|
50549
|
+
import { c as _c101 } from "react-compiler-runtime";
|
|
50550
|
+
import { jsx as _jsx98 } from "react/jsx-runtime";
|
|
50506
50551
|
var WebrtcAudioRuntimeProvider = function(t0) {
|
|
50507
|
-
var $ =
|
|
50552
|
+
var $ = _c101(5);
|
|
50508
50553
|
var children = t0.children;
|
|
50509
50554
|
var webrtcAudioRuntime = useWebrtcAudioRuntime().webrtcAudioRuntime;
|
|
50510
50555
|
var t1;
|
|
@@ -50519,7 +50564,7 @@ var WebrtcAudioRuntimeProvider = function(t0) {
|
|
|
50519
50564
|
}
|
|
50520
50565
|
var t2;
|
|
50521
50566
|
if ($[2] !== children || $[3] !== t1) {
|
|
50522
|
-
t2 = /* @__PURE__ */
|
|
50567
|
+
t2 = /* @__PURE__ */ _jsx98(AudioThreadContext.Provider, {
|
|
50523
50568
|
value: t1,
|
|
50524
50569
|
children: children
|
|
50525
50570
|
});
|
|
@@ -50532,14 +50577,14 @@ var WebrtcAudioRuntimeProvider = function(t0) {
|
|
|
50532
50577
|
return t2;
|
|
50533
50578
|
};
|
|
50534
50579
|
// src/components/gui/Gui/index.tsx
|
|
50535
|
-
import { c as
|
|
50580
|
+
import { c as _c104 } from "react-compiler-runtime";
|
|
50536
50581
|
import { useMemo as useMemo23 } from "react";
|
|
50537
50582
|
import { Flex as Flex35, Card as Card5, Spinner as Spinner3 } from "@radix-ui/themes";
|
|
50538
50583
|
// src/hooks/messages/useLatestAssistantMessage/index.ts
|
|
50539
|
-
import { c as
|
|
50584
|
+
import { c as _c102 } from "react-compiler-runtime";
|
|
50540
50585
|
import { useMemo as useMemo21 } from "react";
|
|
50541
50586
|
var useLatestAssistantMessage = function() {
|
|
50542
|
-
var $ =
|
|
50587
|
+
var $ = _c102(4);
|
|
50543
50588
|
var _useMessages = useMessages(), messages2 = _useMessages.messages;
|
|
50544
50589
|
var t0;
|
|
50545
50590
|
var t1;
|
|
@@ -50568,11 +50613,11 @@ function _temp11(message) {
|
|
|
50568
50613
|
return message.role === "assistant";
|
|
50569
50614
|
}
|
|
50570
50615
|
// src/hooks/messages/useLatestAssistantMessageWithContent/index.ts
|
|
50571
|
-
import { c as
|
|
50616
|
+
import { c as _c103 } from "react-compiler-runtime";
|
|
50572
50617
|
import { isEmpty as isEmpty3 } from "radash";
|
|
50573
50618
|
import { useMemo as useMemo22 } from "react";
|
|
50574
50619
|
var useLatestAssistantMessageWithContent = function() {
|
|
50575
|
-
var $ =
|
|
50620
|
+
var $ = _c103(4);
|
|
50576
50621
|
var _useMessages = useMessages(), messages2 = _useMessages.messages;
|
|
50577
50622
|
var t0;
|
|
50578
50623
|
var t1;
|
|
@@ -50604,14 +50649,14 @@ function _temp25(message) {
|
|
|
50604
50649
|
return message.role === "assistant" && message.content.some(_temp12);
|
|
50605
50650
|
}
|
|
50606
50651
|
// src/components/gui/Gui/index.tsx
|
|
50607
|
-
import { jsx as
|
|
50652
|
+
import { jsx as _jsx99, jsxs as _jsxs37 } from "react/jsx-runtime";
|
|
50608
50653
|
var StartingToolCalls3 = function() {
|
|
50609
|
-
var $ =
|
|
50654
|
+
var $ = _c104(2);
|
|
50610
50655
|
var _useComponents = useComponents(), t0 = _useComponents.components;
|
|
50611
50656
|
var StartingToolCalls4 = t0.StartingToolCalls;
|
|
50612
50657
|
var t1;
|
|
50613
50658
|
if ($[0] !== StartingToolCalls4) {
|
|
50614
|
-
t1 = /* @__PURE__ */
|
|
50659
|
+
t1 = /* @__PURE__ */ _jsx99(StartingToolCalls4, {});
|
|
50615
50660
|
$[0] = StartingToolCalls4;
|
|
50616
50661
|
$[1] = t1;
|
|
50617
50662
|
} else {
|
|
@@ -50620,7 +50665,7 @@ var StartingToolCalls3 = function() {
|
|
|
50620
50665
|
return t1;
|
|
50621
50666
|
};
|
|
50622
50667
|
var Content10 = function(t0) {
|
|
50623
|
-
var $ =
|
|
50668
|
+
var $ = _c104(5);
|
|
50624
50669
|
var latestRunStep = t0.latestRunStep;
|
|
50625
50670
|
var t1;
|
|
50626
50671
|
bb0: {
|
|
@@ -50642,7 +50687,7 @@ var Content10 = function(t0) {
|
|
|
50642
50687
|
if (!latestRunStep || latestRunStep.step_details.type !== "tool_calls") {
|
|
50643
50688
|
var _t;
|
|
50644
50689
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
50645
|
-
_t = /* @__PURE__ */
|
|
50690
|
+
_t = /* @__PURE__ */ _jsx99(Spinner3, {});
|
|
50646
50691
|
$[0] = _t;
|
|
50647
50692
|
} else {
|
|
50648
50693
|
_t = $[0];
|
|
@@ -50652,7 +50697,7 @@ var Content10 = function(t0) {
|
|
|
50652
50697
|
if (!latestToolCall) {
|
|
50653
50698
|
var _t2;
|
|
50654
50699
|
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
|
50655
|
-
_t2 = /* @__PURE__ */
|
|
50700
|
+
_t2 = /* @__PURE__ */ _jsx99(StartingToolCalls3, {});
|
|
50656
50701
|
$[1] = _t2;
|
|
50657
50702
|
} else {
|
|
50658
50703
|
_t2 = $[1];
|
|
@@ -50661,7 +50706,7 @@ var Content10 = function(t0) {
|
|
|
50661
50706
|
}
|
|
50662
50707
|
var t2;
|
|
50663
50708
|
if ($[2] !== latestRunStep || $[3] !== latestToolCall) {
|
|
50664
|
-
t2 = /* @__PURE__ */
|
|
50709
|
+
t2 = /* @__PURE__ */ _jsx99(ToolCall, {
|
|
50665
50710
|
runStep: latestRunStep,
|
|
50666
50711
|
toolCall: latestToolCall
|
|
50667
50712
|
});
|
|
@@ -50674,7 +50719,7 @@ var Content10 = function(t0) {
|
|
|
50674
50719
|
return t2;
|
|
50675
50720
|
};
|
|
50676
50721
|
var Progress2 = function(t0) {
|
|
50677
|
-
var $ =
|
|
50722
|
+
var $ = _c104(5);
|
|
50678
50723
|
var latestAssistantMessage = t0.latestAssistantMessage;
|
|
50679
50724
|
var isMutatingMessage = useIsMutatingMessage();
|
|
50680
50725
|
var t1;
|
|
@@ -50708,10 +50753,10 @@ var Progress2 = function(t0) {
|
|
|
50708
50753
|
}
|
|
50709
50754
|
var t4;
|
|
50710
50755
|
if ($[3] !== latestRunStep) {
|
|
50711
|
-
t4 = /* @__PURE__ */
|
|
50756
|
+
t4 = /* @__PURE__ */ _jsx99(Flex35, {
|
|
50712
50757
|
style: t3,
|
|
50713
|
-
children: /* @__PURE__ */
|
|
50714
|
-
children: /* @__PURE__ */
|
|
50758
|
+
children: /* @__PURE__ */ _jsx99(Card5, {
|
|
50759
|
+
children: /* @__PURE__ */ _jsx99(Content10, {
|
|
50715
50760
|
latestRunStep: latestRunStep
|
|
50716
50761
|
})
|
|
50717
50762
|
})
|
|
@@ -50724,20 +50769,20 @@ var Progress2 = function(t0) {
|
|
|
50724
50769
|
return t4;
|
|
50725
50770
|
};
|
|
50726
50771
|
var Gui = function() {
|
|
50727
|
-
var $ =
|
|
50772
|
+
var $ = _c104(8);
|
|
50728
50773
|
var latestAssistantMessage = useLatestAssistantMessage().latestAssistantMessage;
|
|
50729
50774
|
var latestAssistantMessageWithContent = useLatestAssistantMessageWithContent().latestAssistantMessageWithContent;
|
|
50730
50775
|
if (!latestAssistantMessage || !latestAssistantMessageWithContent) {
|
|
50731
50776
|
var _t3;
|
|
50732
50777
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
50733
|
-
_t3 = /* @__PURE__ */
|
|
50778
|
+
_t3 = /* @__PURE__ */ _jsx99(Flex35, {
|
|
50734
50779
|
direction: "column",
|
|
50735
50780
|
flexGrow: "1",
|
|
50736
|
-
children: /* @__PURE__ */
|
|
50781
|
+
children: /* @__PURE__ */ _jsx99(Flex35, {
|
|
50737
50782
|
align: "center",
|
|
50738
50783
|
justify: "center",
|
|
50739
50784
|
flexGrow: "1",
|
|
50740
|
-
children: /* @__PURE__ */
|
|
50785
|
+
children: /* @__PURE__ */ _jsx99(Spinner3, {
|
|
50741
50786
|
size: "3"
|
|
50742
50787
|
})
|
|
50743
50788
|
})
|
|
@@ -50750,7 +50795,7 @@ var Gui = function() {
|
|
|
50750
50795
|
}
|
|
50751
50796
|
var t0;
|
|
50752
50797
|
if ($[1] !== latestAssistantMessageWithContent) {
|
|
50753
|
-
t0 = /* @__PURE__ */
|
|
50798
|
+
t0 = /* @__PURE__ */ _jsx99(MessageContent, {
|
|
50754
50799
|
message: latestAssistantMessageWithContent
|
|
50755
50800
|
});
|
|
50756
50801
|
$[1] = latestAssistantMessageWithContent;
|
|
@@ -50760,7 +50805,7 @@ var Gui = function() {
|
|
|
50760
50805
|
}
|
|
50761
50806
|
var t1;
|
|
50762
50807
|
if ($[3] !== latestAssistantMessage) {
|
|
50763
|
-
t1 = /* @__PURE__ */
|
|
50808
|
+
t1 = /* @__PURE__ */ _jsx99(Progress2, {
|
|
50764
50809
|
latestAssistantMessage: latestAssistantMessage
|
|
50765
50810
|
});
|
|
50766
50811
|
$[3] = latestAssistantMessage;
|
|
@@ -50790,9 +50835,9 @@ function _temp13(rs) {
|
|
|
50790
50835
|
return rs.status === "in_progress";
|
|
50791
50836
|
}
|
|
50792
50837
|
// src/components/markdown/MarkdownProvider/index.tsx
|
|
50793
|
-
import { c as
|
|
50838
|
+
import { c as _c105 } from "react-compiler-runtime";
|
|
50794
50839
|
import { useMemo as useMemo24 } from "react";
|
|
50795
|
-
import { jsx as
|
|
50840
|
+
import { jsx as _jsx100 } from "react/jsx-runtime";
|
|
50796
50841
|
var _excluded7 = [
|
|
50797
50842
|
"children"
|
|
50798
50843
|
];
|
|
@@ -50815,7 +50860,7 @@ function _objectWithoutPropertiesLoose7(r, e) {
|
|
|
50815
50860
|
return t;
|
|
50816
50861
|
}
|
|
50817
50862
|
var MarkdownProvider = function(t0) {
|
|
50818
|
-
var $ =
|
|
50863
|
+
var $ = _c105(9);
|
|
50819
50864
|
var children;
|
|
50820
50865
|
var rest;
|
|
50821
50866
|
if ($[0] !== t0) {
|
|
@@ -50845,7 +50890,7 @@ var MarkdownProvider = function(t0) {
|
|
|
50845
50890
|
var value = t1;
|
|
50846
50891
|
var t3;
|
|
50847
50892
|
if ($[6] !== children || $[7] !== value) {
|
|
50848
|
-
t3 = /* @__PURE__ */
|
|
50893
|
+
t3 = /* @__PURE__ */ _jsx100(MarkdownContext.Provider, {
|
|
50849
50894
|
value: value,
|
|
50850
50895
|
children: children
|
|
50851
50896
|
});
|
|
@@ -50858,18 +50903,18 @@ var MarkdownProvider = function(t0) {
|
|
|
50858
50903
|
return t3;
|
|
50859
50904
|
};
|
|
50860
50905
|
// src/components/annotations/SourceAnnotation/index.tsx
|
|
50861
|
-
import { c as
|
|
50906
|
+
import { c as _c108 } from "react-compiler-runtime";
|
|
50862
50907
|
// src/components/annotations/SourceAnnotation/FileCitation/index.tsx
|
|
50863
|
-
import { c as
|
|
50908
|
+
import { c as _c107 } from "react-compiler-runtime";
|
|
50864
50909
|
import { useState as useState13 } from "react";
|
|
50865
50910
|
import { QuoteIcon as QuoteIcon2 } from "@radix-ui/react-icons";
|
|
50866
50911
|
import { Dialog, VisuallyHidden, IconButton as IconButton11 } from "@radix-ui/themes";
|
|
50867
50912
|
// src/components/annotations/SourceAnnotation/FileCitation/Content.tsx
|
|
50868
|
-
import { c as
|
|
50913
|
+
import { c as _c106 } from "react-compiler-runtime";
|
|
50869
50914
|
import { Flex as Flex36, Card as Card6, Inset as Inset3 } from "@radix-ui/themes";
|
|
50870
|
-
import { jsx as
|
|
50915
|
+
import { jsx as _jsx101 } from "react/jsx-runtime";
|
|
50871
50916
|
var Content11 = function(t0) {
|
|
50872
|
-
var $ =
|
|
50917
|
+
var $ = _c106(5);
|
|
50873
50918
|
var fileId = t0.fileId;
|
|
50874
50919
|
var superinterfaceContext = useSuperinterfaceContext();
|
|
50875
50920
|
var nextSearchParams = new URLSearchParams(superinterfaceContext.variables);
|
|
@@ -50906,18 +50951,18 @@ var Content11 = function(t0) {
|
|
|
50906
50951
|
}
|
|
50907
50952
|
var t5;
|
|
50908
50953
|
if ($[3] !== t3) {
|
|
50909
|
-
t5 = /* @__PURE__ */
|
|
50954
|
+
t5 = /* @__PURE__ */ _jsx101(Flex36, {
|
|
50910
50955
|
direction: "column",
|
|
50911
50956
|
flexGrow: "1",
|
|
50912
50957
|
gap: "3",
|
|
50913
|
-
children: /* @__PURE__ */
|
|
50958
|
+
children: /* @__PURE__ */ _jsx101(Card6, {
|
|
50914
50959
|
style: t1,
|
|
50915
|
-
children: /* @__PURE__ */
|
|
50960
|
+
children: /* @__PURE__ */ _jsx101(Inset3, {
|
|
50916
50961
|
clip: "padding-box",
|
|
50917
50962
|
style: t2,
|
|
50918
|
-
children: /* @__PURE__ */
|
|
50963
|
+
children: /* @__PURE__ */ _jsx101(Flex36, {
|
|
50919
50964
|
flexGrow: "1",
|
|
50920
|
-
children: /* @__PURE__ */
|
|
50965
|
+
children: /* @__PURE__ */ _jsx101("embed", {
|
|
50921
50966
|
src: t3,
|
|
50922
50967
|
style: t4
|
|
50923
50968
|
})
|
|
@@ -50933,9 +50978,9 @@ var Content11 = function(t0) {
|
|
|
50933
50978
|
return t5;
|
|
50934
50979
|
};
|
|
50935
50980
|
// src/components/annotations/SourceAnnotation/FileCitation/index.tsx
|
|
50936
|
-
import { jsx as
|
|
50981
|
+
import { jsx as _jsx102, jsxs as _jsxs38, Fragment as _Fragment6 } from "react/jsx-runtime";
|
|
50937
50982
|
var FileCitation = function(t0) {
|
|
50938
|
-
var $ =
|
|
50983
|
+
var $ = _c107(18);
|
|
50939
50984
|
var annotation = t0.annotation;
|
|
50940
50985
|
var _useState13 = _sliced_to_array(useState13(null), 2), activeFileId = _useState13[0], setActiveFileId = _useState13[1];
|
|
50941
50986
|
var t1;
|
|
@@ -50950,14 +50995,14 @@ var FileCitation = function(t0) {
|
|
|
50950
50995
|
}
|
|
50951
50996
|
var t2;
|
|
50952
50997
|
if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
|
|
50953
|
-
t2 = /* @__PURE__ */
|
|
50998
|
+
t2 = /* @__PURE__ */ _jsx102(QuoteIcon2, {});
|
|
50954
50999
|
$[2] = t2;
|
|
50955
51000
|
} else {
|
|
50956
51001
|
t2 = $[2];
|
|
50957
51002
|
}
|
|
50958
51003
|
var t3;
|
|
50959
51004
|
if ($[3] !== t1) {
|
|
50960
|
-
t3 = /* @__PURE__ */
|
|
51005
|
+
t3 = /* @__PURE__ */ _jsx102(IconButton11, {
|
|
50961
51006
|
variant: "soft",
|
|
50962
51007
|
color: "gray",
|
|
50963
51008
|
size: "1",
|
|
@@ -50993,9 +51038,9 @@ var FileCitation = function(t0) {
|
|
|
50993
51038
|
}
|
|
50994
51039
|
var t7;
|
|
50995
51040
|
if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
|
|
50996
|
-
t7 = /* @__PURE__ */
|
|
51041
|
+
t7 = /* @__PURE__ */ _jsx102(VisuallyHidden, {
|
|
50997
51042
|
asChild: true,
|
|
50998
|
-
children: /* @__PURE__ */
|
|
51043
|
+
children: /* @__PURE__ */ _jsx102(Dialog.Title, {
|
|
50999
51044
|
children: "Source"
|
|
51000
51045
|
})
|
|
51001
51046
|
});
|
|
@@ -51005,7 +51050,7 @@ var FileCitation = function(t0) {
|
|
|
51005
51050
|
}
|
|
51006
51051
|
var t8;
|
|
51007
51052
|
if ($[8] !== activeFileId) {
|
|
51008
|
-
t8 = activeFileId && /* @__PURE__ */
|
|
51053
|
+
t8 = activeFileId && /* @__PURE__ */ _jsx102(Content11, {
|
|
51009
51054
|
fileId: activeFileId
|
|
51010
51055
|
});
|
|
51011
51056
|
$[8] = activeFileId;
|
|
@@ -51033,7 +51078,7 @@ var FileCitation = function(t0) {
|
|
|
51033
51078
|
}
|
|
51034
51079
|
var t10;
|
|
51035
51080
|
if ($[12] !== t4 || $[13] !== t9) {
|
|
51036
|
-
t10 = /* @__PURE__ */
|
|
51081
|
+
t10 = /* @__PURE__ */ _jsx102(Dialog.Root, {
|
|
51037
51082
|
open: t4,
|
|
51038
51083
|
onOpenChange: t5,
|
|
51039
51084
|
children: t9
|
|
@@ -51061,7 +51106,7 @@ var FileCitation = function(t0) {
|
|
|
51061
51106
|
return t11;
|
|
51062
51107
|
};
|
|
51063
51108
|
// src/components/annotations/SourceAnnotation/index.tsx
|
|
51064
|
-
import { jsx as
|
|
51109
|
+
import { jsx as _jsx103 } from "react/jsx-runtime";
|
|
51065
51110
|
var _excluded8 = [
|
|
51066
51111
|
"children"
|
|
51067
51112
|
];
|
|
@@ -51084,7 +51129,7 @@ function _objectWithoutPropertiesLoose8(r, e) {
|
|
|
51084
51129
|
return t;
|
|
51085
51130
|
}
|
|
51086
51131
|
var SourceAnnotation = function(t0) {
|
|
51087
|
-
var $ =
|
|
51132
|
+
var $ = _c108(10);
|
|
51088
51133
|
var children;
|
|
51089
51134
|
var rest;
|
|
51090
51135
|
if ($[0] !== t0) {
|
|
@@ -51112,7 +51157,7 @@ var SourceAnnotation = function(t0) {
|
|
|
51112
51157
|
if (annotation.type === "file_citation") {
|
|
51113
51158
|
var t2;
|
|
51114
51159
|
if ($[5] !== annotation) {
|
|
51115
|
-
t2 = /* @__PURE__ */
|
|
51160
|
+
t2 = /* @__PURE__ */ _jsx103(FileCitation, {
|
|
51116
51161
|
annotation: annotation
|
|
51117
51162
|
});
|
|
51118
51163
|
$[5] = annotation;
|
|
@@ -51125,7 +51170,7 @@ var SourceAnnotation = function(t0) {
|
|
|
51125
51170
|
if (annotation.type === "file_path") {
|
|
51126
51171
|
var _t2;
|
|
51127
51172
|
if ($[7] !== annotation || $[8] !== children) {
|
|
51128
|
-
_t2 = /* @__PURE__ */
|
|
51173
|
+
_t2 = /* @__PURE__ */ _jsx103(FilePathAnnotation, {
|
|
51129
51174
|
annotation: annotation,
|
|
51130
51175
|
children: children
|
|
51131
51176
|
});
|
|
@@ -51141,7 +51186,7 @@ var SourceAnnotation = function(t0) {
|
|
|
51141
51186
|
return null;
|
|
51142
51187
|
};
|
|
51143
51188
|
// src/components/avatars/Avatar.tsx
|
|
51144
|
-
import { c as
|
|
51189
|
+
import { c as _c111 } from "react-compiler-runtime";
|
|
51145
51190
|
// src/enums/index.ts
|
|
51146
51191
|
var IconAvatarName = /* @__PURE__ */ function(IconAvatarName2) {
|
|
51147
51192
|
IconAvatarName2["BACKPACK"] = "BACKPACK";
|
|
@@ -51166,7 +51211,7 @@ var AvatarType = /* @__PURE__ */ function(AvatarType2) {
|
|
|
51166
51211
|
// src/components/avatars/Avatar.tsx
|
|
51167
51212
|
import { Avatar as RadixAvatar } from "@radix-ui/themes";
|
|
51168
51213
|
// src/components/imageAvatars/ImageAvatar/index.tsx
|
|
51169
|
-
import { c as
|
|
51214
|
+
import { c as _c109 } from "react-compiler-runtime";
|
|
51170
51215
|
import { Avatar as Avatar4 } from "@radix-ui/themes";
|
|
51171
51216
|
// src/components/imageAvatars/ImageAvatar/lib/optimizedSrc/path.ts
|
|
51172
51217
|
var width = function(_ref) {
|
|
@@ -51218,9 +51263,9 @@ var optimizedSrc = function(_ref) {
|
|
|
51218
51263
|
}));
|
|
51219
51264
|
};
|
|
51220
51265
|
// src/components/imageAvatars/ImageAvatar/index.tsx
|
|
51221
|
-
import { jsx as
|
|
51266
|
+
import { jsx as _jsx104 } from "react/jsx-runtime";
|
|
51222
51267
|
var ImageAvatar = function(t0) {
|
|
51223
|
-
var $ =
|
|
51268
|
+
var $ = _c109(9);
|
|
51224
51269
|
var imageAvatar = t0.imageAvatar, size = t0.size, className = t0.className, style = t0.style;
|
|
51225
51270
|
var superinterfaceContext = useSuperinterfaceContext();
|
|
51226
51271
|
var t1;
|
|
@@ -51239,7 +51284,7 @@ var ImageAvatar = function(t0) {
|
|
|
51239
51284
|
}
|
|
51240
51285
|
var t2;
|
|
51241
51286
|
if ($[4] !== className || $[5] !== size || $[6] !== style || $[7] !== t1) {
|
|
51242
|
-
t2 = /* @__PURE__ */
|
|
51287
|
+
t2 = /* @__PURE__ */ _jsx104(Avatar4, {
|
|
51243
51288
|
className: className,
|
|
51244
51289
|
style: style,
|
|
51245
51290
|
fallback: "",
|
|
@@ -51257,7 +51302,7 @@ var ImageAvatar = function(t0) {
|
|
|
51257
51302
|
return t2;
|
|
51258
51303
|
};
|
|
51259
51304
|
// src/components/iconAvatars/IconAvatar.tsx
|
|
51260
|
-
import { c as
|
|
51305
|
+
import { c as _c110 } from "react-compiler-runtime";
|
|
51261
51306
|
import { useMemo as useMemo25 } from "react";
|
|
51262
51307
|
import { Avatar as Avatar5 } from "@radix-ui/themes";
|
|
51263
51308
|
// src/lib/iconAvatars/iconAvatarComponents.ts
|
|
@@ -51265,16 +51310,16 @@ import { BackpackIcon, RocketIcon, MagicWandIcon, CubeIcon, TargetIcon, DiscIcon
|
|
|
51265
51310
|
var _obj;
|
|
51266
51311
|
var iconAvatarComponents = (_obj = {}, _define_property(_obj, IconAvatarName.BACKPACK, BackpackIcon), _define_property(_obj, IconAvatarName.ROCKET, RocketIcon), _define_property(_obj, IconAvatarName.MAGIC_WAND, MagicWandIcon), _define_property(_obj, IconAvatarName.CUBE, CubeIcon), _define_property(_obj, IconAvatarName.TARGET, TargetIcon), _define_property(_obj, IconAvatarName.DISC, DiscIcon), _define_property(_obj, IconAvatarName.GLOBE, GlobeIcon), _define_property(_obj, IconAvatarName.STAR, StarIcon), _define_property(_obj, IconAvatarName.LIGHTNING_BOLT, LightningBoltIcon2), _define_property(_obj, IconAvatarName.FACE, FaceIcon), _define_property(_obj, IconAvatarName.PERSON, PersonIcon2), _define_property(_obj, IconAvatarName.HEART, HeartIcon), _obj);
|
|
51267
51312
|
// src/components/iconAvatars/IconAvatar.tsx
|
|
51268
|
-
import { jsx as
|
|
51313
|
+
import { jsx as _jsx105 } from "react/jsx-runtime";
|
|
51269
51314
|
var IconAvatar = function(t0) {
|
|
51270
|
-
var $ =
|
|
51315
|
+
var $ = _c110(7);
|
|
51271
51316
|
var iconAvatar = t0.iconAvatar, size = t0.size, className = t0.className, style = t0.style;
|
|
51272
51317
|
var t1;
|
|
51273
51318
|
t1 = iconAvatarComponents[iconAvatar.name];
|
|
51274
51319
|
var Component2 = t1;
|
|
51275
51320
|
var t2;
|
|
51276
51321
|
if ($[0] !== Component2) {
|
|
51277
|
-
t2 = Component2 ? /* @__PURE__ */
|
|
51322
|
+
t2 = Component2 ? /* @__PURE__ */ _jsx105(Component2, {}) : "";
|
|
51278
51323
|
$[0] = Component2;
|
|
51279
51324
|
$[1] = t2;
|
|
51280
51325
|
} else {
|
|
@@ -51282,7 +51327,7 @@ var IconAvatar = function(t0) {
|
|
|
51282
51327
|
}
|
|
51283
51328
|
var t3;
|
|
51284
51329
|
if ($[2] !== className || $[3] !== size || $[4] !== style || $[5] !== t2) {
|
|
51285
|
-
t3 = /* @__PURE__ */
|
|
51330
|
+
t3 = /* @__PURE__ */ _jsx105(Avatar5, {
|
|
51286
51331
|
className: className,
|
|
51287
51332
|
style: style,
|
|
51288
51333
|
size: size,
|
|
@@ -51299,16 +51344,16 @@ var IconAvatar = function(t0) {
|
|
|
51299
51344
|
return t3;
|
|
51300
51345
|
};
|
|
51301
51346
|
// src/components/avatars/Avatar.tsx
|
|
51302
|
-
import { jsx as
|
|
51347
|
+
import { jsx as _jsx106 } from "react/jsx-runtime";
|
|
51303
51348
|
var Avatar6 = function(t0) {
|
|
51304
|
-
var $ =
|
|
51349
|
+
var $ = _c111(14);
|
|
51305
51350
|
var avatar = t0.avatar, t1 = t0.size, className = t0.className, style = t0.style;
|
|
51306
51351
|
var size = t1 === void 0 ? "1" : t1;
|
|
51307
51352
|
if (avatar) {
|
|
51308
51353
|
if (avatar.type === AvatarType.IMAGE && avatar.imageAvatar) {
|
|
51309
51354
|
var _t;
|
|
51310
51355
|
if ($[0] !== avatar.imageAvatar || $[1] !== className || $[2] !== size || $[3] !== style) {
|
|
51311
|
-
_t = /* @__PURE__ */
|
|
51356
|
+
_t = /* @__PURE__ */ _jsx106(ImageAvatar, {
|
|
51312
51357
|
imageAvatar: avatar.imageAvatar,
|
|
51313
51358
|
size: size,
|
|
51314
51359
|
className: className,
|
|
@@ -51327,7 +51372,7 @@ var Avatar6 = function(t0) {
|
|
|
51327
51372
|
if (avatar.type === AvatarType.ICON && avatar.iconAvatar) {
|
|
51328
51373
|
var _t2;
|
|
51329
51374
|
if ($[5] !== avatar.iconAvatar || $[6] !== className || $[7] !== size || $[8] !== style) {
|
|
51330
|
-
_t2 = /* @__PURE__ */
|
|
51375
|
+
_t2 = /* @__PURE__ */ _jsx106(IconAvatar, {
|
|
51331
51376
|
iconAvatar: avatar.iconAvatar,
|
|
51332
51377
|
size: size,
|
|
51333
51378
|
className: className,
|
|
@@ -51346,7 +51391,7 @@ var Avatar6 = function(t0) {
|
|
|
51346
51391
|
}
|
|
51347
51392
|
var t2;
|
|
51348
51393
|
if ($[10] !== className || $[11] !== size || $[12] !== style) {
|
|
51349
|
-
t2 = /* @__PURE__ */
|
|
51394
|
+
t2 = /* @__PURE__ */ _jsx106(RadixAvatar, {
|
|
51350
51395
|
fallback: "",
|
|
51351
51396
|
size: size,
|
|
51352
51397
|
className: className,
|
|
@@ -51362,9 +51407,9 @@ var Avatar6 = function(t0) {
|
|
|
51362
51407
|
return t2;
|
|
51363
51408
|
};
|
|
51364
51409
|
// src/components/components/ComponentsProvider.tsx
|
|
51365
|
-
import { c as
|
|
51410
|
+
import { c as _c112 } from "react-compiler-runtime";
|
|
51366
51411
|
import { useMemo as useMemo26 } from "react";
|
|
51367
|
-
import { jsx as
|
|
51412
|
+
import { jsx as _jsx107 } from "react/jsx-runtime";
|
|
51368
51413
|
var _excluded9 = [
|
|
51369
51414
|
"children"
|
|
51370
51415
|
];
|
|
@@ -51387,7 +51432,7 @@ function _objectWithoutPropertiesLoose9(r, e) {
|
|
|
51387
51432
|
return t;
|
|
51388
51433
|
}
|
|
51389
51434
|
var ComponentsProvider = function(t0) {
|
|
51390
|
-
var $ =
|
|
51435
|
+
var $ = _c112(9);
|
|
51391
51436
|
var children;
|
|
51392
51437
|
var rest;
|
|
51393
51438
|
if ($[0] !== t0) {
|
|
@@ -51417,7 +51462,7 @@ var ComponentsProvider = function(t0) {
|
|
|
51417
51462
|
var value = t1;
|
|
51418
51463
|
var t3;
|
|
51419
51464
|
if ($[6] !== children || $[7] !== value) {
|
|
51420
|
-
t3 = /* @__PURE__ */
|
|
51465
|
+
t3 = /* @__PURE__ */ _jsx107(ComponentsContext.Provider, {
|
|
51421
51466
|
value: value,
|
|
51422
51467
|
children: children
|
|
51423
51468
|
});
|
|
@@ -51430,11 +51475,11 @@ var ComponentsProvider = function(t0) {
|
|
|
51430
51475
|
return t3;
|
|
51431
51476
|
};
|
|
51432
51477
|
// src/components/assistants/AssistantProvider/index.tsx
|
|
51433
|
-
import { c as
|
|
51434
|
-
import { jsx as
|
|
51478
|
+
import { c as _c113 } from "react-compiler-runtime";
|
|
51479
|
+
import { jsx as _jsx108 } from "react/jsx-runtime";
|
|
51435
51480
|
var AssistantProvider = function(t0) {
|
|
51436
51481
|
var _assistant$name;
|
|
51437
|
-
var $ =
|
|
51482
|
+
var $ = _c113(10);
|
|
51438
51483
|
var children = t0.children;
|
|
51439
51484
|
var superinterfaceContext = useSuperinterfaceContext();
|
|
51440
51485
|
var t1;
|
|
@@ -51452,7 +51497,7 @@ var AssistantProvider = function(t0) {
|
|
|
51452
51497
|
var t3 = assistant === null || assistant === void 0 ? void 0 : assistant.avatar;
|
|
51453
51498
|
var t4;
|
|
51454
51499
|
if ($[2] !== t3) {
|
|
51455
|
-
t4 = /* @__PURE__ */
|
|
51500
|
+
t4 = /* @__PURE__ */ _jsx108(Avatar6, {
|
|
51456
51501
|
avatar: t3
|
|
51457
51502
|
});
|
|
51458
51503
|
$[2] = t3;
|
|
@@ -51462,7 +51507,7 @@ var AssistantProvider = function(t0) {
|
|
|
51462
51507
|
}
|
|
51463
51508
|
var t5;
|
|
51464
51509
|
if ($[4] !== children || $[5] !== t4) {
|
|
51465
|
-
t5 = /* @__PURE__ */
|
|
51510
|
+
t5 = /* @__PURE__ */ _jsx108(AssistantAvatarContext.Provider, {
|
|
51466
51511
|
value: t4,
|
|
51467
51512
|
children: children
|
|
51468
51513
|
});
|
|
@@ -51474,7 +51519,7 @@ var AssistantProvider = function(t0) {
|
|
|
51474
51519
|
}
|
|
51475
51520
|
var t6;
|
|
51476
51521
|
if ($[7] !== t2 || $[8] !== t5) {
|
|
51477
|
-
t6 = /* @__PURE__ */
|
|
51522
|
+
t6 = /* @__PURE__ */ _jsx108(AssistantNameContext.Provider, {
|
|
51478
51523
|
value: t2,
|
|
51479
51524
|
children: t5
|
|
51480
51525
|
});
|