@superinterface/react 2.24.2 → 2.24.4
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 +18 -18
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +18 -18
- package/dist/index.js.map +1 -1
- package/dist/server.cjs +9 -9
- package/dist/server.js +9 -9
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -445,7 +445,7 @@ var queryOptions = function(param) {
|
|
|
445
445
|
]);
|
|
446
446
|
return infiniteQueryOptions(_object_spread_props(_object_spread({
|
|
447
447
|
// @ts-ignore-next-line
|
|
448
|
-
queryFn: function() {
|
|
448
|
+
queryFn: /*#__PURE__*/ function() {
|
|
449
449
|
var _ref = _async_to_generator(function(param) {
|
|
450
450
|
var pageParam, queryKey2, _queryKey2, _key, variables, params;
|
|
451
451
|
return _ts_generator(this, function(_state) {
|
|
@@ -459,7 +459,7 @@ var queryOptions = function(param) {
|
|
|
459
459
|
})));
|
|
460
460
|
return [
|
|
461
461
|
2,
|
|
462
|
-
fetch("".concat(superinterfaceContext.baseUrl).concat(path2, "?").concat(params)).then(function() {
|
|
462
|
+
fetch("".concat(superinterfaceContext.baseUrl).concat(path2, "?").concat(params)).then(/*#__PURE__*/ function() {
|
|
463
463
|
var _ref = _async_to_generator(function(response) {
|
|
464
464
|
var errorResponse, error;
|
|
465
465
|
return _ts_generator(this, function(_state) {
|
|
@@ -896,9 +896,6 @@ var Content = function(param) {
|
|
|
896
896
|
}, [
|
|
897
897
|
fn
|
|
898
898
|
]);
|
|
899
|
-
if (!args) {
|
|
900
|
-
return null;
|
|
901
|
-
}
|
|
902
899
|
return /* @__PURE__ */ jsxs2(Code, {
|
|
903
900
|
variant: "ghost",
|
|
904
901
|
color: "gold",
|
|
@@ -907,10 +904,10 @@ var Content = function(param) {
|
|
|
907
904
|
wordBreak: "break-word"
|
|
908
905
|
},
|
|
909
906
|
children: [
|
|
910
|
-
/* @__PURE__ */ jsx13(Box2, {
|
|
907
|
+
args && /* @__PURE__ */ jsx13(Box2, {
|
|
911
908
|
children: args
|
|
912
909
|
}),
|
|
913
|
-
/* @__PURE__ */ jsx13(Box2, {
|
|
910
|
+
output && /* @__PURE__ */ jsx13(Box2, {
|
|
914
911
|
children: output
|
|
915
912
|
})
|
|
916
913
|
]
|
|
@@ -1528,7 +1525,10 @@ var Audio = function(param) {
|
|
|
1528
1525
|
var src = param.src;
|
|
1529
1526
|
return /* @__PURE__ */ jsx40(MediaContainer, {
|
|
1530
1527
|
children: /* @__PURE__ */ jsxs12(MediaPlayer2, {
|
|
1531
|
-
src:
|
|
1528
|
+
src: {
|
|
1529
|
+
src: src,
|
|
1530
|
+
type: "audio/".concat(src.split(".").pop())
|
|
1531
|
+
},
|
|
1532
1532
|
viewType: "audio",
|
|
1533
1533
|
crossOrigin: true,
|
|
1534
1534
|
playsInline: true,
|
|
@@ -2396,7 +2396,7 @@ var data = function(param) {
|
|
|
2396
2396
|
// src/hooks/messages/useCreateMessage/lib/mutationOptions/onMutate/index.ts
|
|
2397
2397
|
var onMutate = function(param) {
|
|
2398
2398
|
var queryClient = param.queryClient;
|
|
2399
|
-
return function() {
|
|
2399
|
+
return /*#__PURE__*/ function() {
|
|
2400
2400
|
var _ref = _async_to_generator(function(newMessage) {
|
|
2401
2401
|
var queryKey, prevMessages;
|
|
2402
2402
|
return _ts_generator(this, function(_state) {
|
|
@@ -2789,7 +2789,7 @@ var threadRunStepCompleted = function(param) {
|
|
|
2789
2789
|
};
|
|
2790
2790
|
// src/hooks/messages/useCreateMessage/lib/mutationOptions/mutationFn/handleResponse/handlers/threadRunRequiresAction.ts
|
|
2791
2791
|
import { map } from "radash";
|
|
2792
|
-
var threadRunRequiresAction = function() {
|
|
2792
|
+
var threadRunRequiresAction = /*#__PURE__*/ function() {
|
|
2793
2793
|
var _ref = _async_to_generator(function(param) {
|
|
2794
2794
|
var value, queryClient, messagesQueryKey, superinterfaceContext, toolCalls, toolOutputs;
|
|
2795
2795
|
return _ts_generator(this, function(_state) {
|
|
@@ -2803,7 +2803,7 @@ var threadRunRequiresAction = function() {
|
|
|
2803
2803
|
toolCalls = value.data.required_action.submit_client_tool_outputs.tool_calls;
|
|
2804
2804
|
return [
|
|
2805
2805
|
4,
|
|
2806
|
-
map(toolCalls, function() {
|
|
2806
|
+
map(toolCalls, /*#__PURE__*/ function() {
|
|
2807
2807
|
var _ref = _async_to_generator(function(toolCall) {
|
|
2808
2808
|
var fn, args, parsedArgs, output;
|
|
2809
2809
|
return _ts_generator(this, function(_state) {
|
|
@@ -2923,7 +2923,7 @@ var body = function(param) {
|
|
|
2923
2923
|
// src/hooks/messages/useCreateMessage/lib/mutationOptions/mutationFn/index.ts
|
|
2924
2924
|
var mutationFn = function(param) {
|
|
2925
2925
|
var superinterfaceContext = param.superinterfaceContext, queryClient = param.queryClient, threadContext = param.threadContext;
|
|
2926
|
-
return function() {
|
|
2926
|
+
return /*#__PURE__*/ function() {
|
|
2927
2927
|
var _ref = _async_to_generator(function(variables) {
|
|
2928
2928
|
var abortController, response, errorResponse, error, parser, reader, messagesQueryKey, _ref, done, value;
|
|
2929
2929
|
return _ts_generator(this, function(_state) {
|
|
@@ -3140,7 +3140,7 @@ var Root4 = function(param) {
|
|
|
3140
3140
|
var onSubmit = onSubmitArg ? partob2(onSubmitArg, {
|
|
3141
3141
|
reset: reset,
|
|
3142
3142
|
createMessage: createMessage
|
|
3143
|
-
}) : function() {
|
|
3143
|
+
}) : /*#__PURE__*/ function() {
|
|
3144
3144
|
var _ref = _async_to_generator(function(data2) {
|
|
3145
3145
|
var attachments;
|
|
3146
3146
|
return _ts_generator(this, function(_state) {
|
|
@@ -3414,7 +3414,7 @@ var body2 = function(param) {
|
|
|
3414
3414
|
// src/hooks/files/useCreateFile/lib/mutationOptions/mutationFn/index.ts
|
|
3415
3415
|
var mutationFn2 = function(param) {
|
|
3416
3416
|
var superinterfaceContext = param.superinterfaceContext, queryClient = param.queryClient, threadContext = param.threadContext;
|
|
3417
|
-
return function() {
|
|
3417
|
+
return /*#__PURE__*/ function() {
|
|
3418
3418
|
var _ref = _async_to_generator(function(variables) {
|
|
3419
3419
|
var response, result;
|
|
3420
3420
|
return _ts_generator(this, function(_state) {
|
|
@@ -3502,7 +3502,7 @@ var Control2 = function() {
|
|
|
3502
3502
|
var _useMessageFormContext = useMessageFormContext(), isDisabled = _useMessageFormContext.isDisabled, isLoading = _useMessageFormContext.isLoading, setFiles = _useMessageFormContext.setFiles;
|
|
3503
3503
|
var createFile = useCreateFile().createFile;
|
|
3504
3504
|
var addToast = useToasts().addToast;
|
|
3505
|
-
var onChange = useCallback2(function() {
|
|
3505
|
+
var onChange = useCallback2(/*#__PURE__*/ function() {
|
|
3506
3506
|
var _ref = _async_to_generator(function(event) {
|
|
3507
3507
|
var fileObjects, newFiles, _iteratorAbruptCompletion, _didIteratorError, _iteratorError, _loop, _iterator, _step, err;
|
|
3508
3508
|
return _ts_generator(this, function(_state) {
|
|
@@ -3890,7 +3890,7 @@ import { queryOptions as tanstackQueryOptions } from "@tanstack/react-query";
|
|
|
3890
3890
|
// src/hooks/assistants/useAssistant/lib/queryOptions/queryFn.ts
|
|
3891
3891
|
var queryFn = function(param) {
|
|
3892
3892
|
var superinterfaceContext = param.superinterfaceContext;
|
|
3893
|
-
return function() {
|
|
3893
|
+
return /*#__PURE__*/ function() {
|
|
3894
3894
|
var _ref = _async_to_generator(function(param) {
|
|
3895
3895
|
var queryKey, _queryKey, _key, assistantId, params;
|
|
3896
3896
|
return _ts_generator(this, function(_state) {
|
|
@@ -3901,7 +3901,7 @@ var queryFn = function(param) {
|
|
|
3901
3901
|
});
|
|
3902
3902
|
return [
|
|
3903
3903
|
2,
|
|
3904
|
-
fetch("".concat(superinterfaceContext.baseUrl, "/assistants/").concat(assistantId, "?").concat(params)).then(function() {
|
|
3904
|
+
fetch("".concat(superinterfaceContext.baseUrl, "/assistants/").concat(assistantId, "?").concat(params)).then(/*#__PURE__*/ function() {
|
|
3905
3905
|
var _ref = _async_to_generator(function(response) {
|
|
3906
3906
|
var errorResponse, error;
|
|
3907
3907
|
return _ts_generator(this, function(_state) {
|
|
@@ -4743,7 +4743,7 @@ var Content6 = function(param) {
|
|
|
4743
4743
|
];
|
|
4744
4744
|
});
|
|
4745
4745
|
}),
|
|
4746
|
-
onStop: function() {
|
|
4746
|
+
onStop: /*#__PURE__*/ function() {
|
|
4747
4747
|
var _ref = _async_to_generator(function(_event, chunks) {
|
|
4748
4748
|
var blob, audioContent;
|
|
4749
4749
|
return _ts_generator(this, function(_state) {
|