@buzzni/saycode-cli 0.1.0 → 0.1.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/README.md +17 -3
- package/THIRD-PARTY-NOTICES.md +1 -29
- package/index.mjs +224 -1892
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -6,12 +6,12 @@ import require$$0 from "crypto";
|
|
|
6
6
|
import { mkdirSync, writeFileSync, readFileSync, rmSync, chmodSync } from "node:fs";
|
|
7
7
|
import { dirname, join } from "node:path";
|
|
8
8
|
import require$$0$1 from "fs";
|
|
9
|
-
import require$$1
|
|
10
|
-
import require$$2
|
|
9
|
+
import require$$1 from "url";
|
|
10
|
+
import require$$2 from "child_process";
|
|
11
11
|
import require$$3 from "http";
|
|
12
12
|
import require$$4 from "https";
|
|
13
|
-
import require$$1$
|
|
14
|
-
import require$$1$
|
|
13
|
+
import require$$1$1 from "tty";
|
|
14
|
+
import require$$1$2 from "util";
|
|
15
15
|
import require$$0$2 from "os";
|
|
16
16
|
import require$$0$6 from "events";
|
|
17
17
|
import require$$3$1 from "net";
|
|
@@ -37,7 +37,7 @@ function _mergeNamespaces(n, m) {
|
|
|
37
37
|
}
|
|
38
38
|
return Object.freeze(Object.defineProperty(n, Symbol.toStringTag, { value: "Module" }));
|
|
39
39
|
}
|
|
40
|
-
const version = "0.1.
|
|
40
|
+
const version = "0.1.1";
|
|
41
41
|
const manifest = {
|
|
42
42
|
version
|
|
43
43
|
};
|
|
@@ -235,30 +235,6 @@ Leaving never stops a remote session — it keeps running on the machine.`;
|
|
|
235
235
|
function getDefaultExportFromCjs(x) {
|
|
236
236
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
237
237
|
}
|
|
238
|
-
function getAugmentedNamespace(n) {
|
|
239
|
-
if (Object.prototype.hasOwnProperty.call(n, "__esModule")) return n;
|
|
240
|
-
var f = n.default;
|
|
241
|
-
if (typeof f == "function") {
|
|
242
|
-
var a = function a2() {
|
|
243
|
-
if (this instanceof a2) {
|
|
244
|
-
return Reflect.construct(f, arguments, this.constructor);
|
|
245
|
-
}
|
|
246
|
-
return f.apply(this, arguments);
|
|
247
|
-
};
|
|
248
|
-
a.prototype = f.prototype;
|
|
249
|
-
} else a = {};
|
|
250
|
-
Object.defineProperty(a, "__esModule", { value: true });
|
|
251
|
-
Object.keys(n).forEach(function(k) {
|
|
252
|
-
var d = Object.getOwnPropertyDescriptor(n, k);
|
|
253
|
-
Object.defineProperty(a, k, d.get ? d : {
|
|
254
|
-
enumerable: true,
|
|
255
|
-
get: function() {
|
|
256
|
-
return n[k];
|
|
257
|
-
}
|
|
258
|
-
});
|
|
259
|
-
});
|
|
260
|
-
return a;
|
|
261
|
-
}
|
|
262
238
|
function commonjsRequire(path) {
|
|
263
239
|
throw new Error('Could not dynamically require "' + path + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
264
240
|
}
|
|
@@ -2866,1754 +2842,6 @@ function parseProjectListV2Page(body) {
|
|
|
2866
2842
|
total: page.total
|
|
2867
2843
|
};
|
|
2868
2844
|
}
|
|
2869
|
-
var jsxRuntime = { exports: {} };
|
|
2870
|
-
var reactJsxRuntime_production = {};
|
|
2871
|
-
/**
|
|
2872
|
-
* @license React
|
|
2873
|
-
* react-jsx-runtime.production.js
|
|
2874
|
-
*
|
|
2875
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
2876
|
-
*
|
|
2877
|
-
* This source code is licensed under the MIT license found in the
|
|
2878
|
-
* LICENSE file in the root directory of this source tree.
|
|
2879
|
-
*/
|
|
2880
|
-
var hasRequiredReactJsxRuntime_production;
|
|
2881
|
-
function requireReactJsxRuntime_production() {
|
|
2882
|
-
if (hasRequiredReactJsxRuntime_production) return reactJsxRuntime_production;
|
|
2883
|
-
hasRequiredReactJsxRuntime_production = 1;
|
|
2884
|
-
var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment");
|
|
2885
|
-
function jsxProd(type, config, maybeKey) {
|
|
2886
|
-
var key = null;
|
|
2887
|
-
void 0 !== maybeKey && (key = "" + maybeKey);
|
|
2888
|
-
void 0 !== config.key && (key = "" + config.key);
|
|
2889
|
-
if ("key" in config) {
|
|
2890
|
-
maybeKey = {};
|
|
2891
|
-
for (var propName in config)
|
|
2892
|
-
"key" !== propName && (maybeKey[propName] = config[propName]);
|
|
2893
|
-
} else maybeKey = config;
|
|
2894
|
-
config = maybeKey.ref;
|
|
2895
|
-
return {
|
|
2896
|
-
$$typeof: REACT_ELEMENT_TYPE,
|
|
2897
|
-
type,
|
|
2898
|
-
key,
|
|
2899
|
-
ref: void 0 !== config ? config : null,
|
|
2900
|
-
props: maybeKey
|
|
2901
|
-
};
|
|
2902
|
-
}
|
|
2903
|
-
reactJsxRuntime_production.Fragment = REACT_FRAGMENT_TYPE;
|
|
2904
|
-
reactJsxRuntime_production.jsx = jsxProd;
|
|
2905
|
-
reactJsxRuntime_production.jsxs = jsxProd;
|
|
2906
|
-
return reactJsxRuntime_production;
|
|
2907
|
-
}
|
|
2908
|
-
var reactJsxRuntime_development = {};
|
|
2909
|
-
var react = { exports: {} };
|
|
2910
|
-
var react_production = {};
|
|
2911
|
-
/**
|
|
2912
|
-
* @license React
|
|
2913
|
-
* react.production.js
|
|
2914
|
-
*
|
|
2915
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
2916
|
-
*
|
|
2917
|
-
* This source code is licensed under the MIT license found in the
|
|
2918
|
-
* LICENSE file in the root directory of this source tree.
|
|
2919
|
-
*/
|
|
2920
|
-
var hasRequiredReact_production;
|
|
2921
|
-
function requireReact_production() {
|
|
2922
|
-
if (hasRequiredReact_production) return react_production;
|
|
2923
|
-
hasRequiredReact_production = 1;
|
|
2924
|
-
var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = Symbol.for("react.profiler"), REACT_CONSUMER_TYPE = Symbol.for("react.consumer"), REACT_CONTEXT_TYPE = Symbol.for("react.context"), REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"), REACT_MEMO_TYPE = Symbol.for("react.memo"), REACT_LAZY_TYPE = Symbol.for("react.lazy"), REACT_ACTIVITY_TYPE = Symbol.for("react.activity"), MAYBE_ITERATOR_SYMBOL = Symbol.iterator;
|
|
2925
|
-
function getIteratorFn(maybeIterable) {
|
|
2926
|
-
if (null === maybeIterable || "object" !== typeof maybeIterable) return null;
|
|
2927
|
-
maybeIterable = MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL] || maybeIterable["@@iterator"];
|
|
2928
|
-
return "function" === typeof maybeIterable ? maybeIterable : null;
|
|
2929
|
-
}
|
|
2930
|
-
var ReactNoopUpdateQueue = {
|
|
2931
|
-
isMounted: function() {
|
|
2932
|
-
return false;
|
|
2933
|
-
},
|
|
2934
|
-
enqueueForceUpdate: function() {
|
|
2935
|
-
},
|
|
2936
|
-
enqueueReplaceState: function() {
|
|
2937
|
-
},
|
|
2938
|
-
enqueueSetState: function() {
|
|
2939
|
-
}
|
|
2940
|
-
}, assign = Object.assign, emptyObject = {};
|
|
2941
|
-
function Component(props, context, updater) {
|
|
2942
|
-
this.props = props;
|
|
2943
|
-
this.context = context;
|
|
2944
|
-
this.refs = emptyObject;
|
|
2945
|
-
this.updater = updater || ReactNoopUpdateQueue;
|
|
2946
|
-
}
|
|
2947
|
-
Component.prototype.isReactComponent = {};
|
|
2948
|
-
Component.prototype.setState = function(partialState, callback) {
|
|
2949
|
-
if ("object" !== typeof partialState && "function" !== typeof partialState && null != partialState)
|
|
2950
|
-
throw Error(
|
|
2951
|
-
"takes an object of state variables to update or a function which returns an object of state variables."
|
|
2952
|
-
);
|
|
2953
|
-
this.updater.enqueueSetState(this, partialState, callback, "setState");
|
|
2954
|
-
};
|
|
2955
|
-
Component.prototype.forceUpdate = function(callback) {
|
|
2956
|
-
this.updater.enqueueForceUpdate(this, callback, "forceUpdate");
|
|
2957
|
-
};
|
|
2958
|
-
function ComponentDummy() {
|
|
2959
|
-
}
|
|
2960
|
-
ComponentDummy.prototype = Component.prototype;
|
|
2961
|
-
function PureComponent(props, context, updater) {
|
|
2962
|
-
this.props = props;
|
|
2963
|
-
this.context = context;
|
|
2964
|
-
this.refs = emptyObject;
|
|
2965
|
-
this.updater = updater || ReactNoopUpdateQueue;
|
|
2966
|
-
}
|
|
2967
|
-
var pureComponentPrototype = PureComponent.prototype = new ComponentDummy();
|
|
2968
|
-
pureComponentPrototype.constructor = PureComponent;
|
|
2969
|
-
assign(pureComponentPrototype, Component.prototype);
|
|
2970
|
-
pureComponentPrototype.isPureReactComponent = true;
|
|
2971
|
-
var isArrayImpl = Array.isArray;
|
|
2972
|
-
function noop() {
|
|
2973
|
-
}
|
|
2974
|
-
var ReactSharedInternals = { H: null, A: null, T: null, S: null }, hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
2975
|
-
function ReactElement(type, key, props) {
|
|
2976
|
-
var refProp = props.ref;
|
|
2977
|
-
return {
|
|
2978
|
-
$$typeof: REACT_ELEMENT_TYPE,
|
|
2979
|
-
type,
|
|
2980
|
-
key,
|
|
2981
|
-
ref: void 0 !== refProp ? refProp : null,
|
|
2982
|
-
props
|
|
2983
|
-
};
|
|
2984
|
-
}
|
|
2985
|
-
function cloneAndReplaceKey(oldElement, newKey) {
|
|
2986
|
-
return ReactElement(oldElement.type, newKey, oldElement.props);
|
|
2987
|
-
}
|
|
2988
|
-
function isValidElement(object) {
|
|
2989
|
-
return "object" === typeof object && null !== object && object.$$typeof === REACT_ELEMENT_TYPE;
|
|
2990
|
-
}
|
|
2991
|
-
function escape(key) {
|
|
2992
|
-
var escaperLookup = { "=": "=0", ":": "=2" };
|
|
2993
|
-
return "$" + key.replace(/[=:]/g, function(match) {
|
|
2994
|
-
return escaperLookup[match];
|
|
2995
|
-
});
|
|
2996
|
-
}
|
|
2997
|
-
var userProvidedKeyEscapeRegex = /\/+/g;
|
|
2998
|
-
function getElementKey(element, index) {
|
|
2999
|
-
return "object" === typeof element && null !== element && null != element.key ? escape("" + element.key) : index.toString(36);
|
|
3000
|
-
}
|
|
3001
|
-
function resolveThenable(thenable) {
|
|
3002
|
-
switch (thenable.status) {
|
|
3003
|
-
case "fulfilled":
|
|
3004
|
-
return thenable.value;
|
|
3005
|
-
case "rejected":
|
|
3006
|
-
throw thenable.reason;
|
|
3007
|
-
default:
|
|
3008
|
-
switch ("string" === typeof thenable.status ? thenable.then(noop, noop) : (thenable.status = "pending", thenable.then(
|
|
3009
|
-
function(fulfilledValue) {
|
|
3010
|
-
"pending" === thenable.status && (thenable.status = "fulfilled", thenable.value = fulfilledValue);
|
|
3011
|
-
},
|
|
3012
|
-
function(error) {
|
|
3013
|
-
"pending" === thenable.status && (thenable.status = "rejected", thenable.reason = error);
|
|
3014
|
-
}
|
|
3015
|
-
)), thenable.status) {
|
|
3016
|
-
case "fulfilled":
|
|
3017
|
-
return thenable.value;
|
|
3018
|
-
case "rejected":
|
|
3019
|
-
throw thenable.reason;
|
|
3020
|
-
}
|
|
3021
|
-
}
|
|
3022
|
-
throw thenable;
|
|
3023
|
-
}
|
|
3024
|
-
function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {
|
|
3025
|
-
var type = typeof children;
|
|
3026
|
-
if ("undefined" === type || "boolean" === type) children = null;
|
|
3027
|
-
var invokeCallback = false;
|
|
3028
|
-
if (null === children) invokeCallback = true;
|
|
3029
|
-
else
|
|
3030
|
-
switch (type) {
|
|
3031
|
-
case "bigint":
|
|
3032
|
-
case "string":
|
|
3033
|
-
case "number":
|
|
3034
|
-
invokeCallback = true;
|
|
3035
|
-
break;
|
|
3036
|
-
case "object":
|
|
3037
|
-
switch (children.$$typeof) {
|
|
3038
|
-
case REACT_ELEMENT_TYPE:
|
|
3039
|
-
case REACT_PORTAL_TYPE:
|
|
3040
|
-
invokeCallback = true;
|
|
3041
|
-
break;
|
|
3042
|
-
case REACT_LAZY_TYPE:
|
|
3043
|
-
return invokeCallback = children._init, mapIntoArray(
|
|
3044
|
-
invokeCallback(children._payload),
|
|
3045
|
-
array,
|
|
3046
|
-
escapedPrefix,
|
|
3047
|
-
nameSoFar,
|
|
3048
|
-
callback
|
|
3049
|
-
);
|
|
3050
|
-
}
|
|
3051
|
-
}
|
|
3052
|
-
if (invokeCallback)
|
|
3053
|
-
return callback = callback(children), invokeCallback = "" === nameSoFar ? "." + getElementKey(children, 0) : nameSoFar, isArrayImpl(callback) ? (escapedPrefix = "", null != invokeCallback && (escapedPrefix = invokeCallback.replace(userProvidedKeyEscapeRegex, "$&/") + "/"), mapIntoArray(callback, array, escapedPrefix, "", function(c) {
|
|
3054
|
-
return c;
|
|
3055
|
-
})) : null != callback && (isValidElement(callback) && (callback = cloneAndReplaceKey(
|
|
3056
|
-
callback,
|
|
3057
|
-
escapedPrefix + (null == callback.key || children && children.key === callback.key ? "" : ("" + callback.key).replace(
|
|
3058
|
-
userProvidedKeyEscapeRegex,
|
|
3059
|
-
"$&/"
|
|
3060
|
-
) + "/") + invokeCallback
|
|
3061
|
-
)), array.push(callback)), 1;
|
|
3062
|
-
invokeCallback = 0;
|
|
3063
|
-
var nextNamePrefix = "" === nameSoFar ? "." : nameSoFar + ":";
|
|
3064
|
-
if (isArrayImpl(children))
|
|
3065
|
-
for (var i = 0; i < children.length; i++)
|
|
3066
|
-
nameSoFar = children[i], type = nextNamePrefix + getElementKey(nameSoFar, i), invokeCallback += mapIntoArray(
|
|
3067
|
-
nameSoFar,
|
|
3068
|
-
array,
|
|
3069
|
-
escapedPrefix,
|
|
3070
|
-
type,
|
|
3071
|
-
callback
|
|
3072
|
-
);
|
|
3073
|
-
else if (i = getIteratorFn(children), "function" === typeof i)
|
|
3074
|
-
for (children = i.call(children), i = 0; !(nameSoFar = children.next()).done; )
|
|
3075
|
-
nameSoFar = nameSoFar.value, type = nextNamePrefix + getElementKey(nameSoFar, i++), invokeCallback += mapIntoArray(
|
|
3076
|
-
nameSoFar,
|
|
3077
|
-
array,
|
|
3078
|
-
escapedPrefix,
|
|
3079
|
-
type,
|
|
3080
|
-
callback
|
|
3081
|
-
);
|
|
3082
|
-
else if ("object" === type) {
|
|
3083
|
-
if ("function" === typeof children.then)
|
|
3084
|
-
return mapIntoArray(
|
|
3085
|
-
resolveThenable(children),
|
|
3086
|
-
array,
|
|
3087
|
-
escapedPrefix,
|
|
3088
|
-
nameSoFar,
|
|
3089
|
-
callback
|
|
3090
|
-
);
|
|
3091
|
-
array = String(children);
|
|
3092
|
-
throw Error(
|
|
3093
|
-
"Objects are not valid as a React child (found: " + ("[object Object]" === array ? "object with keys {" + Object.keys(children).join(", ") + "}" : array) + "). If you meant to render a collection of children, use an array instead."
|
|
3094
|
-
);
|
|
3095
|
-
}
|
|
3096
|
-
return invokeCallback;
|
|
3097
|
-
}
|
|
3098
|
-
function mapChildren(children, func, context) {
|
|
3099
|
-
if (null == children) return children;
|
|
3100
|
-
var result = [], count = 0;
|
|
3101
|
-
mapIntoArray(children, result, "", "", function(child) {
|
|
3102
|
-
return func.call(context, child, count++);
|
|
3103
|
-
});
|
|
3104
|
-
return result;
|
|
3105
|
-
}
|
|
3106
|
-
function lazyInitializer(payload) {
|
|
3107
|
-
if (-1 === payload._status) {
|
|
3108
|
-
var ctor = payload._result;
|
|
3109
|
-
ctor = ctor();
|
|
3110
|
-
ctor.then(
|
|
3111
|
-
function(moduleObject) {
|
|
3112
|
-
if (0 === payload._status || -1 === payload._status)
|
|
3113
|
-
payload._status = 1, payload._result = moduleObject;
|
|
3114
|
-
},
|
|
3115
|
-
function(error) {
|
|
3116
|
-
if (0 === payload._status || -1 === payload._status)
|
|
3117
|
-
payload._status = 2, payload._result = error;
|
|
3118
|
-
}
|
|
3119
|
-
);
|
|
3120
|
-
-1 === payload._status && (payload._status = 0, payload._result = ctor);
|
|
3121
|
-
}
|
|
3122
|
-
if (1 === payload._status) return payload._result.default;
|
|
3123
|
-
throw payload._result;
|
|
3124
|
-
}
|
|
3125
|
-
var reportGlobalError = "function" === typeof reportError ? reportError : function(error) {
|
|
3126
|
-
if ("object" === typeof window && "function" === typeof window.ErrorEvent) {
|
|
3127
|
-
var event = new window.ErrorEvent("error", {
|
|
3128
|
-
bubbles: true,
|
|
3129
|
-
cancelable: true,
|
|
3130
|
-
message: "object" === typeof error && null !== error && "string" === typeof error.message ? String(error.message) : String(error),
|
|
3131
|
-
error
|
|
3132
|
-
});
|
|
3133
|
-
if (!window.dispatchEvent(event)) return;
|
|
3134
|
-
} else if ("object" === typeof process && "function" === typeof process.emit) {
|
|
3135
|
-
process.emit("uncaughtException", error);
|
|
3136
|
-
return;
|
|
3137
|
-
}
|
|
3138
|
-
console.error(error);
|
|
3139
|
-
}, Children = {
|
|
3140
|
-
map: mapChildren,
|
|
3141
|
-
forEach: function(children, forEachFunc, forEachContext) {
|
|
3142
|
-
mapChildren(
|
|
3143
|
-
children,
|
|
3144
|
-
function() {
|
|
3145
|
-
forEachFunc.apply(this, arguments);
|
|
3146
|
-
},
|
|
3147
|
-
forEachContext
|
|
3148
|
-
);
|
|
3149
|
-
},
|
|
3150
|
-
count: function(children) {
|
|
3151
|
-
var n = 0;
|
|
3152
|
-
mapChildren(children, function() {
|
|
3153
|
-
n++;
|
|
3154
|
-
});
|
|
3155
|
-
return n;
|
|
3156
|
-
},
|
|
3157
|
-
toArray: function(children) {
|
|
3158
|
-
return mapChildren(children, function(child) {
|
|
3159
|
-
return child;
|
|
3160
|
-
}) || [];
|
|
3161
|
-
},
|
|
3162
|
-
only: function(children) {
|
|
3163
|
-
if (!isValidElement(children))
|
|
3164
|
-
throw Error(
|
|
3165
|
-
"React.Children.only expected to receive a single React element child."
|
|
3166
|
-
);
|
|
3167
|
-
return children;
|
|
3168
|
-
}
|
|
3169
|
-
};
|
|
3170
|
-
react_production.Activity = REACT_ACTIVITY_TYPE;
|
|
3171
|
-
react_production.Children = Children;
|
|
3172
|
-
react_production.Component = Component;
|
|
3173
|
-
react_production.Fragment = REACT_FRAGMENT_TYPE;
|
|
3174
|
-
react_production.Profiler = REACT_PROFILER_TYPE;
|
|
3175
|
-
react_production.PureComponent = PureComponent;
|
|
3176
|
-
react_production.StrictMode = REACT_STRICT_MODE_TYPE;
|
|
3177
|
-
react_production.Suspense = REACT_SUSPENSE_TYPE;
|
|
3178
|
-
react_production.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = ReactSharedInternals;
|
|
3179
|
-
react_production.__COMPILER_RUNTIME = {
|
|
3180
|
-
__proto__: null,
|
|
3181
|
-
c: function(size) {
|
|
3182
|
-
return ReactSharedInternals.H.useMemoCache(size);
|
|
3183
|
-
}
|
|
3184
|
-
};
|
|
3185
|
-
react_production.cache = function(fn) {
|
|
3186
|
-
return function() {
|
|
3187
|
-
return fn.apply(null, arguments);
|
|
3188
|
-
};
|
|
3189
|
-
};
|
|
3190
|
-
react_production.cacheSignal = function() {
|
|
3191
|
-
return null;
|
|
3192
|
-
};
|
|
3193
|
-
react_production.cloneElement = function(element, config, children) {
|
|
3194
|
-
if (null === element || void 0 === element)
|
|
3195
|
-
throw Error(
|
|
3196
|
-
"The argument must be a React element, but you passed " + element + "."
|
|
3197
|
-
);
|
|
3198
|
-
var props = assign({}, element.props), key = element.key;
|
|
3199
|
-
if (null != config)
|
|
3200
|
-
for (propName in void 0 !== config.key && (key = "" + config.key), config)
|
|
3201
|
-
!hasOwnProperty.call(config, propName) || "key" === propName || "__self" === propName || "__source" === propName || "ref" === propName && void 0 === config.ref || (props[propName] = config[propName]);
|
|
3202
|
-
var propName = arguments.length - 2;
|
|
3203
|
-
if (1 === propName) props.children = children;
|
|
3204
|
-
else if (1 < propName) {
|
|
3205
|
-
for (var childArray = Array(propName), i = 0; i < propName; i++)
|
|
3206
|
-
childArray[i] = arguments[i + 2];
|
|
3207
|
-
props.children = childArray;
|
|
3208
|
-
}
|
|
3209
|
-
return ReactElement(element.type, key, props);
|
|
3210
|
-
};
|
|
3211
|
-
react_production.createContext = function(defaultValue) {
|
|
3212
|
-
defaultValue = {
|
|
3213
|
-
$$typeof: REACT_CONTEXT_TYPE,
|
|
3214
|
-
_currentValue: defaultValue,
|
|
3215
|
-
_currentValue2: defaultValue,
|
|
3216
|
-
_threadCount: 0,
|
|
3217
|
-
Provider: null,
|
|
3218
|
-
Consumer: null
|
|
3219
|
-
};
|
|
3220
|
-
defaultValue.Provider = defaultValue;
|
|
3221
|
-
defaultValue.Consumer = {
|
|
3222
|
-
$$typeof: REACT_CONSUMER_TYPE,
|
|
3223
|
-
_context: defaultValue
|
|
3224
|
-
};
|
|
3225
|
-
return defaultValue;
|
|
3226
|
-
};
|
|
3227
|
-
react_production.createElement = function(type, config, children) {
|
|
3228
|
-
var propName, props = {}, key = null;
|
|
3229
|
-
if (null != config)
|
|
3230
|
-
for (propName in void 0 !== config.key && (key = "" + config.key), config)
|
|
3231
|
-
hasOwnProperty.call(config, propName) && "key" !== propName && "__self" !== propName && "__source" !== propName && (props[propName] = config[propName]);
|
|
3232
|
-
var childrenLength = arguments.length - 2;
|
|
3233
|
-
if (1 === childrenLength) props.children = children;
|
|
3234
|
-
else if (1 < childrenLength) {
|
|
3235
|
-
for (var childArray = Array(childrenLength), i = 0; i < childrenLength; i++)
|
|
3236
|
-
childArray[i] = arguments[i + 2];
|
|
3237
|
-
props.children = childArray;
|
|
3238
|
-
}
|
|
3239
|
-
if (type && type.defaultProps)
|
|
3240
|
-
for (propName in childrenLength = type.defaultProps, childrenLength)
|
|
3241
|
-
void 0 === props[propName] && (props[propName] = childrenLength[propName]);
|
|
3242
|
-
return ReactElement(type, key, props);
|
|
3243
|
-
};
|
|
3244
|
-
react_production.createRef = function() {
|
|
3245
|
-
return { current: null };
|
|
3246
|
-
};
|
|
3247
|
-
react_production.forwardRef = function(render) {
|
|
3248
|
-
return { $$typeof: REACT_FORWARD_REF_TYPE, render };
|
|
3249
|
-
};
|
|
3250
|
-
react_production.isValidElement = isValidElement;
|
|
3251
|
-
react_production.lazy = function(ctor) {
|
|
3252
|
-
return {
|
|
3253
|
-
$$typeof: REACT_LAZY_TYPE,
|
|
3254
|
-
_payload: { _status: -1, _result: ctor },
|
|
3255
|
-
_init: lazyInitializer
|
|
3256
|
-
};
|
|
3257
|
-
};
|
|
3258
|
-
react_production.memo = function(type, compare) {
|
|
3259
|
-
return {
|
|
3260
|
-
$$typeof: REACT_MEMO_TYPE,
|
|
3261
|
-
type,
|
|
3262
|
-
compare: void 0 === compare ? null : compare
|
|
3263
|
-
};
|
|
3264
|
-
};
|
|
3265
|
-
react_production.startTransition = function(scope) {
|
|
3266
|
-
var prevTransition = ReactSharedInternals.T, currentTransition = {};
|
|
3267
|
-
ReactSharedInternals.T = currentTransition;
|
|
3268
|
-
try {
|
|
3269
|
-
var returnValue = scope(), onStartTransitionFinish = ReactSharedInternals.S;
|
|
3270
|
-
null !== onStartTransitionFinish && onStartTransitionFinish(currentTransition, returnValue);
|
|
3271
|
-
"object" === typeof returnValue && null !== returnValue && "function" === typeof returnValue.then && returnValue.then(noop, reportGlobalError);
|
|
3272
|
-
} catch (error) {
|
|
3273
|
-
reportGlobalError(error);
|
|
3274
|
-
} finally {
|
|
3275
|
-
null !== prevTransition && null !== currentTransition.types && (prevTransition.types = currentTransition.types), ReactSharedInternals.T = prevTransition;
|
|
3276
|
-
}
|
|
3277
|
-
};
|
|
3278
|
-
react_production.unstable_useCacheRefresh = function() {
|
|
3279
|
-
return ReactSharedInternals.H.useCacheRefresh();
|
|
3280
|
-
};
|
|
3281
|
-
react_production.use = function(usable) {
|
|
3282
|
-
return ReactSharedInternals.H.use(usable);
|
|
3283
|
-
};
|
|
3284
|
-
react_production.useActionState = function(action, initialState, permalink) {
|
|
3285
|
-
return ReactSharedInternals.H.useActionState(action, initialState, permalink);
|
|
3286
|
-
};
|
|
3287
|
-
react_production.useCallback = function(callback, deps) {
|
|
3288
|
-
return ReactSharedInternals.H.useCallback(callback, deps);
|
|
3289
|
-
};
|
|
3290
|
-
react_production.useContext = function(Context) {
|
|
3291
|
-
return ReactSharedInternals.H.useContext(Context);
|
|
3292
|
-
};
|
|
3293
|
-
react_production.useDebugValue = function() {
|
|
3294
|
-
};
|
|
3295
|
-
react_production.useDeferredValue = function(value2, initialValue) {
|
|
3296
|
-
return ReactSharedInternals.H.useDeferredValue(value2, initialValue);
|
|
3297
|
-
};
|
|
3298
|
-
react_production.useEffect = function(create, deps) {
|
|
3299
|
-
return ReactSharedInternals.H.useEffect(create, deps);
|
|
3300
|
-
};
|
|
3301
|
-
react_production.useEffectEvent = function(callback) {
|
|
3302
|
-
return ReactSharedInternals.H.useEffectEvent(callback);
|
|
3303
|
-
};
|
|
3304
|
-
react_production.useId = function() {
|
|
3305
|
-
return ReactSharedInternals.H.useId();
|
|
3306
|
-
};
|
|
3307
|
-
react_production.useImperativeHandle = function(ref, create, deps) {
|
|
3308
|
-
return ReactSharedInternals.H.useImperativeHandle(ref, create, deps);
|
|
3309
|
-
};
|
|
3310
|
-
react_production.useInsertionEffect = function(create, deps) {
|
|
3311
|
-
return ReactSharedInternals.H.useInsertionEffect(create, deps);
|
|
3312
|
-
};
|
|
3313
|
-
react_production.useLayoutEffect = function(create, deps) {
|
|
3314
|
-
return ReactSharedInternals.H.useLayoutEffect(create, deps);
|
|
3315
|
-
};
|
|
3316
|
-
react_production.useMemo = function(create, deps) {
|
|
3317
|
-
return ReactSharedInternals.H.useMemo(create, deps);
|
|
3318
|
-
};
|
|
3319
|
-
react_production.useOptimistic = function(passthrough, reducer) {
|
|
3320
|
-
return ReactSharedInternals.H.useOptimistic(passthrough, reducer);
|
|
3321
|
-
};
|
|
3322
|
-
react_production.useReducer = function(reducer, initialArg, init) {
|
|
3323
|
-
return ReactSharedInternals.H.useReducer(reducer, initialArg, init);
|
|
3324
|
-
};
|
|
3325
|
-
react_production.useRef = function(initialValue) {
|
|
3326
|
-
return ReactSharedInternals.H.useRef(initialValue);
|
|
3327
|
-
};
|
|
3328
|
-
react_production.useState = function(initialState) {
|
|
3329
|
-
return ReactSharedInternals.H.useState(initialState);
|
|
3330
|
-
};
|
|
3331
|
-
react_production.useSyncExternalStore = function(subscribe, getSnapshot, getServerSnapshot) {
|
|
3332
|
-
return ReactSharedInternals.H.useSyncExternalStore(
|
|
3333
|
-
subscribe,
|
|
3334
|
-
getSnapshot,
|
|
3335
|
-
getServerSnapshot
|
|
3336
|
-
);
|
|
3337
|
-
};
|
|
3338
|
-
react_production.useTransition = function() {
|
|
3339
|
-
return ReactSharedInternals.H.useTransition();
|
|
3340
|
-
};
|
|
3341
|
-
react_production.version = "19.2.7";
|
|
3342
|
-
return react_production;
|
|
3343
|
-
}
|
|
3344
|
-
var react_development = { exports: {} };
|
|
3345
|
-
/**
|
|
3346
|
-
* @license React
|
|
3347
|
-
* react.development.js
|
|
3348
|
-
*
|
|
3349
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3350
|
-
*
|
|
3351
|
-
* This source code is licensed under the MIT license found in the
|
|
3352
|
-
* LICENSE file in the root directory of this source tree.
|
|
3353
|
-
*/
|
|
3354
|
-
react_development.exports;
|
|
3355
|
-
var hasRequiredReact_development;
|
|
3356
|
-
function requireReact_development() {
|
|
3357
|
-
if (hasRequiredReact_development) return react_development.exports;
|
|
3358
|
-
hasRequiredReact_development = 1;
|
|
3359
|
-
(function(module, exports) {
|
|
3360
|
-
"production" !== process.env.NODE_ENV && (function() {
|
|
3361
|
-
function defineDeprecationWarning(methodName, info) {
|
|
3362
|
-
Object.defineProperty(Component.prototype, methodName, {
|
|
3363
|
-
get: function() {
|
|
3364
|
-
console.warn(
|
|
3365
|
-
"%s(...) is deprecated in plain JavaScript React classes. %s",
|
|
3366
|
-
info[0],
|
|
3367
|
-
info[1]
|
|
3368
|
-
);
|
|
3369
|
-
}
|
|
3370
|
-
});
|
|
3371
|
-
}
|
|
3372
|
-
function getIteratorFn(maybeIterable) {
|
|
3373
|
-
if (null === maybeIterable || "object" !== typeof maybeIterable)
|
|
3374
|
-
return null;
|
|
3375
|
-
maybeIterable = MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL] || maybeIterable["@@iterator"];
|
|
3376
|
-
return "function" === typeof maybeIterable ? maybeIterable : null;
|
|
3377
|
-
}
|
|
3378
|
-
function warnNoop(publicInstance, callerName) {
|
|
3379
|
-
publicInstance = (publicInstance = publicInstance.constructor) && (publicInstance.displayName || publicInstance.name) || "ReactClass";
|
|
3380
|
-
var warningKey = publicInstance + "." + callerName;
|
|
3381
|
-
didWarnStateUpdateForUnmountedComponent[warningKey] || (console.error(
|
|
3382
|
-
"Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.",
|
|
3383
|
-
callerName,
|
|
3384
|
-
publicInstance
|
|
3385
|
-
), didWarnStateUpdateForUnmountedComponent[warningKey] = true);
|
|
3386
|
-
}
|
|
3387
|
-
function Component(props, context, updater) {
|
|
3388
|
-
this.props = props;
|
|
3389
|
-
this.context = context;
|
|
3390
|
-
this.refs = emptyObject;
|
|
3391
|
-
this.updater = updater || ReactNoopUpdateQueue;
|
|
3392
|
-
}
|
|
3393
|
-
function ComponentDummy() {
|
|
3394
|
-
}
|
|
3395
|
-
function PureComponent(props, context, updater) {
|
|
3396
|
-
this.props = props;
|
|
3397
|
-
this.context = context;
|
|
3398
|
-
this.refs = emptyObject;
|
|
3399
|
-
this.updater = updater || ReactNoopUpdateQueue;
|
|
3400
|
-
}
|
|
3401
|
-
function noop() {
|
|
3402
|
-
}
|
|
3403
|
-
function testStringCoercion(value2) {
|
|
3404
|
-
return "" + value2;
|
|
3405
|
-
}
|
|
3406
|
-
function checkKeyStringCoercion(value2) {
|
|
3407
|
-
try {
|
|
3408
|
-
testStringCoercion(value2);
|
|
3409
|
-
var JSCompiler_inline_result = false;
|
|
3410
|
-
} catch (e) {
|
|
3411
|
-
JSCompiler_inline_result = true;
|
|
3412
|
-
}
|
|
3413
|
-
if (JSCompiler_inline_result) {
|
|
3414
|
-
JSCompiler_inline_result = console;
|
|
3415
|
-
var JSCompiler_temp_const = JSCompiler_inline_result.error;
|
|
3416
|
-
var JSCompiler_inline_result$jscomp$0 = "function" === typeof Symbol && Symbol.toStringTag && value2[Symbol.toStringTag] || value2.constructor.name || "Object";
|
|
3417
|
-
JSCompiler_temp_const.call(
|
|
3418
|
-
JSCompiler_inline_result,
|
|
3419
|
-
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
3420
|
-
JSCompiler_inline_result$jscomp$0
|
|
3421
|
-
);
|
|
3422
|
-
return testStringCoercion(value2);
|
|
3423
|
-
}
|
|
3424
|
-
}
|
|
3425
|
-
function getComponentNameFromType(type) {
|
|
3426
|
-
if (null == type) return null;
|
|
3427
|
-
if ("function" === typeof type)
|
|
3428
|
-
return type.$$typeof === REACT_CLIENT_REFERENCE ? null : type.displayName || type.name || null;
|
|
3429
|
-
if ("string" === typeof type) return type;
|
|
3430
|
-
switch (type) {
|
|
3431
|
-
case REACT_FRAGMENT_TYPE:
|
|
3432
|
-
return "Fragment";
|
|
3433
|
-
case REACT_PROFILER_TYPE:
|
|
3434
|
-
return "Profiler";
|
|
3435
|
-
case REACT_STRICT_MODE_TYPE:
|
|
3436
|
-
return "StrictMode";
|
|
3437
|
-
case REACT_SUSPENSE_TYPE:
|
|
3438
|
-
return "Suspense";
|
|
3439
|
-
case REACT_SUSPENSE_LIST_TYPE:
|
|
3440
|
-
return "SuspenseList";
|
|
3441
|
-
case REACT_ACTIVITY_TYPE:
|
|
3442
|
-
return "Activity";
|
|
3443
|
-
}
|
|
3444
|
-
if ("object" === typeof type)
|
|
3445
|
-
switch ("number" === typeof type.tag && console.error(
|
|
3446
|
-
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
3447
|
-
), type.$$typeof) {
|
|
3448
|
-
case REACT_PORTAL_TYPE:
|
|
3449
|
-
return "Portal";
|
|
3450
|
-
case REACT_CONTEXT_TYPE:
|
|
3451
|
-
return type.displayName || "Context";
|
|
3452
|
-
case REACT_CONSUMER_TYPE:
|
|
3453
|
-
return (type._context.displayName || "Context") + ".Consumer";
|
|
3454
|
-
case REACT_FORWARD_REF_TYPE:
|
|
3455
|
-
var innerType = type.render;
|
|
3456
|
-
type = type.displayName;
|
|
3457
|
-
type || (type = innerType.displayName || innerType.name || "", type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef");
|
|
3458
|
-
return type;
|
|
3459
|
-
case REACT_MEMO_TYPE:
|
|
3460
|
-
return innerType = type.displayName || null, null !== innerType ? innerType : getComponentNameFromType(type.type) || "Memo";
|
|
3461
|
-
case REACT_LAZY_TYPE:
|
|
3462
|
-
innerType = type._payload;
|
|
3463
|
-
type = type._init;
|
|
3464
|
-
try {
|
|
3465
|
-
return getComponentNameFromType(type(innerType));
|
|
3466
|
-
} catch (x) {
|
|
3467
|
-
}
|
|
3468
|
-
}
|
|
3469
|
-
return null;
|
|
3470
|
-
}
|
|
3471
|
-
function getTaskName(type) {
|
|
3472
|
-
if (type === REACT_FRAGMENT_TYPE) return "<>";
|
|
3473
|
-
if ("object" === typeof type && null !== type && type.$$typeof === REACT_LAZY_TYPE)
|
|
3474
|
-
return "<...>";
|
|
3475
|
-
try {
|
|
3476
|
-
var name = getComponentNameFromType(type);
|
|
3477
|
-
return name ? "<" + name + ">" : "<...>";
|
|
3478
|
-
} catch (x) {
|
|
3479
|
-
return "<...>";
|
|
3480
|
-
}
|
|
3481
|
-
}
|
|
3482
|
-
function getOwner() {
|
|
3483
|
-
var dispatcher = ReactSharedInternals.A;
|
|
3484
|
-
return null === dispatcher ? null : dispatcher.getOwner();
|
|
3485
|
-
}
|
|
3486
|
-
function UnknownOwner() {
|
|
3487
|
-
return Error("react-stack-top-frame");
|
|
3488
|
-
}
|
|
3489
|
-
function hasValidKey(config) {
|
|
3490
|
-
if (hasOwnProperty.call(config, "key")) {
|
|
3491
|
-
var getter = Object.getOwnPropertyDescriptor(config, "key").get;
|
|
3492
|
-
if (getter && getter.isReactWarning) return false;
|
|
3493
|
-
}
|
|
3494
|
-
return void 0 !== config.key;
|
|
3495
|
-
}
|
|
3496
|
-
function defineKeyPropWarningGetter(props, displayName) {
|
|
3497
|
-
function warnAboutAccessingKey() {
|
|
3498
|
-
specialPropKeyWarningShown || (specialPropKeyWarningShown = true, console.error(
|
|
3499
|
-
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
3500
|
-
displayName
|
|
3501
|
-
));
|
|
3502
|
-
}
|
|
3503
|
-
warnAboutAccessingKey.isReactWarning = true;
|
|
3504
|
-
Object.defineProperty(props, "key", {
|
|
3505
|
-
get: warnAboutAccessingKey,
|
|
3506
|
-
configurable: true
|
|
3507
|
-
});
|
|
3508
|
-
}
|
|
3509
|
-
function elementRefGetterWithDeprecationWarning() {
|
|
3510
|
-
var componentName = getComponentNameFromType(this.type);
|
|
3511
|
-
didWarnAboutElementRef[componentName] || (didWarnAboutElementRef[componentName] = true, console.error(
|
|
3512
|
-
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
3513
|
-
));
|
|
3514
|
-
componentName = this.props.ref;
|
|
3515
|
-
return void 0 !== componentName ? componentName : null;
|
|
3516
|
-
}
|
|
3517
|
-
function ReactElement(type, key, props, owner, debugStack, debugTask) {
|
|
3518
|
-
var refProp = props.ref;
|
|
3519
|
-
type = {
|
|
3520
|
-
$$typeof: REACT_ELEMENT_TYPE,
|
|
3521
|
-
type,
|
|
3522
|
-
key,
|
|
3523
|
-
props,
|
|
3524
|
-
_owner: owner
|
|
3525
|
-
};
|
|
3526
|
-
null !== (void 0 !== refProp ? refProp : null) ? Object.defineProperty(type, "ref", {
|
|
3527
|
-
enumerable: false,
|
|
3528
|
-
get: elementRefGetterWithDeprecationWarning
|
|
3529
|
-
}) : Object.defineProperty(type, "ref", { enumerable: false, value: null });
|
|
3530
|
-
type._store = {};
|
|
3531
|
-
Object.defineProperty(type._store, "validated", {
|
|
3532
|
-
configurable: false,
|
|
3533
|
-
enumerable: false,
|
|
3534
|
-
writable: true,
|
|
3535
|
-
value: 0
|
|
3536
|
-
});
|
|
3537
|
-
Object.defineProperty(type, "_debugInfo", {
|
|
3538
|
-
configurable: false,
|
|
3539
|
-
enumerable: false,
|
|
3540
|
-
writable: true,
|
|
3541
|
-
value: null
|
|
3542
|
-
});
|
|
3543
|
-
Object.defineProperty(type, "_debugStack", {
|
|
3544
|
-
configurable: false,
|
|
3545
|
-
enumerable: false,
|
|
3546
|
-
writable: true,
|
|
3547
|
-
value: debugStack
|
|
3548
|
-
});
|
|
3549
|
-
Object.defineProperty(type, "_debugTask", {
|
|
3550
|
-
configurable: false,
|
|
3551
|
-
enumerable: false,
|
|
3552
|
-
writable: true,
|
|
3553
|
-
value: debugTask
|
|
3554
|
-
});
|
|
3555
|
-
Object.freeze && (Object.freeze(type.props), Object.freeze(type));
|
|
3556
|
-
return type;
|
|
3557
|
-
}
|
|
3558
|
-
function cloneAndReplaceKey(oldElement, newKey) {
|
|
3559
|
-
newKey = ReactElement(
|
|
3560
|
-
oldElement.type,
|
|
3561
|
-
newKey,
|
|
3562
|
-
oldElement.props,
|
|
3563
|
-
oldElement._owner,
|
|
3564
|
-
oldElement._debugStack,
|
|
3565
|
-
oldElement._debugTask
|
|
3566
|
-
);
|
|
3567
|
-
oldElement._store && (newKey._store.validated = oldElement._store.validated);
|
|
3568
|
-
return newKey;
|
|
3569
|
-
}
|
|
3570
|
-
function validateChildKeys(node2) {
|
|
3571
|
-
isValidElement(node2) ? node2._store && (node2._store.validated = 1) : "object" === typeof node2 && null !== node2 && node2.$$typeof === REACT_LAZY_TYPE && ("fulfilled" === node2._payload.status ? isValidElement(node2._payload.value) && node2._payload.value._store && (node2._payload.value._store.validated = 1) : node2._store && (node2._store.validated = 1));
|
|
3572
|
-
}
|
|
3573
|
-
function isValidElement(object) {
|
|
3574
|
-
return "object" === typeof object && null !== object && object.$$typeof === REACT_ELEMENT_TYPE;
|
|
3575
|
-
}
|
|
3576
|
-
function escape(key) {
|
|
3577
|
-
var escaperLookup = { "=": "=0", ":": "=2" };
|
|
3578
|
-
return "$" + key.replace(/[=:]/g, function(match) {
|
|
3579
|
-
return escaperLookup[match];
|
|
3580
|
-
});
|
|
3581
|
-
}
|
|
3582
|
-
function getElementKey(element, index) {
|
|
3583
|
-
return "object" === typeof element && null !== element && null != element.key ? (checkKeyStringCoercion(element.key), escape("" + element.key)) : index.toString(36);
|
|
3584
|
-
}
|
|
3585
|
-
function resolveThenable(thenable) {
|
|
3586
|
-
switch (thenable.status) {
|
|
3587
|
-
case "fulfilled":
|
|
3588
|
-
return thenable.value;
|
|
3589
|
-
case "rejected":
|
|
3590
|
-
throw thenable.reason;
|
|
3591
|
-
default:
|
|
3592
|
-
switch ("string" === typeof thenable.status ? thenable.then(noop, noop) : (thenable.status = "pending", thenable.then(
|
|
3593
|
-
function(fulfilledValue) {
|
|
3594
|
-
"pending" === thenable.status && (thenable.status = "fulfilled", thenable.value = fulfilledValue);
|
|
3595
|
-
},
|
|
3596
|
-
function(error) {
|
|
3597
|
-
"pending" === thenable.status && (thenable.status = "rejected", thenable.reason = error);
|
|
3598
|
-
}
|
|
3599
|
-
)), thenable.status) {
|
|
3600
|
-
case "fulfilled":
|
|
3601
|
-
return thenable.value;
|
|
3602
|
-
case "rejected":
|
|
3603
|
-
throw thenable.reason;
|
|
3604
|
-
}
|
|
3605
|
-
}
|
|
3606
|
-
throw thenable;
|
|
3607
|
-
}
|
|
3608
|
-
function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {
|
|
3609
|
-
var type = typeof children;
|
|
3610
|
-
if ("undefined" === type || "boolean" === type) children = null;
|
|
3611
|
-
var invokeCallback = false;
|
|
3612
|
-
if (null === children) invokeCallback = true;
|
|
3613
|
-
else
|
|
3614
|
-
switch (type) {
|
|
3615
|
-
case "bigint":
|
|
3616
|
-
case "string":
|
|
3617
|
-
case "number":
|
|
3618
|
-
invokeCallback = true;
|
|
3619
|
-
break;
|
|
3620
|
-
case "object":
|
|
3621
|
-
switch (children.$$typeof) {
|
|
3622
|
-
case REACT_ELEMENT_TYPE:
|
|
3623
|
-
case REACT_PORTAL_TYPE:
|
|
3624
|
-
invokeCallback = true;
|
|
3625
|
-
break;
|
|
3626
|
-
case REACT_LAZY_TYPE:
|
|
3627
|
-
return invokeCallback = children._init, mapIntoArray(
|
|
3628
|
-
invokeCallback(children._payload),
|
|
3629
|
-
array,
|
|
3630
|
-
escapedPrefix,
|
|
3631
|
-
nameSoFar,
|
|
3632
|
-
callback
|
|
3633
|
-
);
|
|
3634
|
-
}
|
|
3635
|
-
}
|
|
3636
|
-
if (invokeCallback) {
|
|
3637
|
-
invokeCallback = children;
|
|
3638
|
-
callback = callback(invokeCallback);
|
|
3639
|
-
var childKey = "" === nameSoFar ? "." + getElementKey(invokeCallback, 0) : nameSoFar;
|
|
3640
|
-
isArrayImpl(callback) ? (escapedPrefix = "", null != childKey && (escapedPrefix = childKey.replace(userProvidedKeyEscapeRegex, "$&/") + "/"), mapIntoArray(callback, array, escapedPrefix, "", function(c) {
|
|
3641
|
-
return c;
|
|
3642
|
-
})) : null != callback && (isValidElement(callback) && (null != callback.key && (invokeCallback && invokeCallback.key === callback.key || checkKeyStringCoercion(callback.key)), escapedPrefix = cloneAndReplaceKey(
|
|
3643
|
-
callback,
|
|
3644
|
-
escapedPrefix + (null == callback.key || invokeCallback && invokeCallback.key === callback.key ? "" : ("" + callback.key).replace(
|
|
3645
|
-
userProvidedKeyEscapeRegex,
|
|
3646
|
-
"$&/"
|
|
3647
|
-
) + "/") + childKey
|
|
3648
|
-
), "" !== nameSoFar && null != invokeCallback && isValidElement(invokeCallback) && null == invokeCallback.key && invokeCallback._store && !invokeCallback._store.validated && (escapedPrefix._store.validated = 2), callback = escapedPrefix), array.push(callback));
|
|
3649
|
-
return 1;
|
|
3650
|
-
}
|
|
3651
|
-
invokeCallback = 0;
|
|
3652
|
-
childKey = "" === nameSoFar ? "." : nameSoFar + ":";
|
|
3653
|
-
if (isArrayImpl(children))
|
|
3654
|
-
for (var i = 0; i < children.length; i++)
|
|
3655
|
-
nameSoFar = children[i], type = childKey + getElementKey(nameSoFar, i), invokeCallback += mapIntoArray(
|
|
3656
|
-
nameSoFar,
|
|
3657
|
-
array,
|
|
3658
|
-
escapedPrefix,
|
|
3659
|
-
type,
|
|
3660
|
-
callback
|
|
3661
|
-
);
|
|
3662
|
-
else if (i = getIteratorFn(children), "function" === typeof i)
|
|
3663
|
-
for (i === children.entries && (didWarnAboutMaps || console.warn(
|
|
3664
|
-
"Using Maps as children is not supported. Use an array of keyed ReactElements instead."
|
|
3665
|
-
), didWarnAboutMaps = true), children = i.call(children), i = 0; !(nameSoFar = children.next()).done; )
|
|
3666
|
-
nameSoFar = nameSoFar.value, type = childKey + getElementKey(nameSoFar, i++), invokeCallback += mapIntoArray(
|
|
3667
|
-
nameSoFar,
|
|
3668
|
-
array,
|
|
3669
|
-
escapedPrefix,
|
|
3670
|
-
type,
|
|
3671
|
-
callback
|
|
3672
|
-
);
|
|
3673
|
-
else if ("object" === type) {
|
|
3674
|
-
if ("function" === typeof children.then)
|
|
3675
|
-
return mapIntoArray(
|
|
3676
|
-
resolveThenable(children),
|
|
3677
|
-
array,
|
|
3678
|
-
escapedPrefix,
|
|
3679
|
-
nameSoFar,
|
|
3680
|
-
callback
|
|
3681
|
-
);
|
|
3682
|
-
array = String(children);
|
|
3683
|
-
throw Error(
|
|
3684
|
-
"Objects are not valid as a React child (found: " + ("[object Object]" === array ? "object with keys {" + Object.keys(children).join(", ") + "}" : array) + "). If you meant to render a collection of children, use an array instead."
|
|
3685
|
-
);
|
|
3686
|
-
}
|
|
3687
|
-
return invokeCallback;
|
|
3688
|
-
}
|
|
3689
|
-
function mapChildren(children, func, context) {
|
|
3690
|
-
if (null == children) return children;
|
|
3691
|
-
var result = [], count = 0;
|
|
3692
|
-
mapIntoArray(children, result, "", "", function(child) {
|
|
3693
|
-
return func.call(context, child, count++);
|
|
3694
|
-
});
|
|
3695
|
-
return result;
|
|
3696
|
-
}
|
|
3697
|
-
function lazyInitializer(payload) {
|
|
3698
|
-
if (-1 === payload._status) {
|
|
3699
|
-
var ioInfo = payload._ioInfo;
|
|
3700
|
-
null != ioInfo && (ioInfo.start = ioInfo.end = performance.now());
|
|
3701
|
-
ioInfo = payload._result;
|
|
3702
|
-
var thenable = ioInfo();
|
|
3703
|
-
thenable.then(
|
|
3704
|
-
function(moduleObject) {
|
|
3705
|
-
if (0 === payload._status || -1 === payload._status) {
|
|
3706
|
-
payload._status = 1;
|
|
3707
|
-
payload._result = moduleObject;
|
|
3708
|
-
var _ioInfo = payload._ioInfo;
|
|
3709
|
-
null != _ioInfo && (_ioInfo.end = performance.now());
|
|
3710
|
-
void 0 === thenable.status && (thenable.status = "fulfilled", thenable.value = moduleObject);
|
|
3711
|
-
}
|
|
3712
|
-
},
|
|
3713
|
-
function(error) {
|
|
3714
|
-
if (0 === payload._status || -1 === payload._status) {
|
|
3715
|
-
payload._status = 2;
|
|
3716
|
-
payload._result = error;
|
|
3717
|
-
var _ioInfo2 = payload._ioInfo;
|
|
3718
|
-
null != _ioInfo2 && (_ioInfo2.end = performance.now());
|
|
3719
|
-
void 0 === thenable.status && (thenable.status = "rejected", thenable.reason = error);
|
|
3720
|
-
}
|
|
3721
|
-
}
|
|
3722
|
-
);
|
|
3723
|
-
ioInfo = payload._ioInfo;
|
|
3724
|
-
if (null != ioInfo) {
|
|
3725
|
-
ioInfo.value = thenable;
|
|
3726
|
-
var displayName = thenable.displayName;
|
|
3727
|
-
"string" === typeof displayName && (ioInfo.name = displayName);
|
|
3728
|
-
}
|
|
3729
|
-
-1 === payload._status && (payload._status = 0, payload._result = thenable);
|
|
3730
|
-
}
|
|
3731
|
-
if (1 === payload._status)
|
|
3732
|
-
return ioInfo = payload._result, void 0 === ioInfo && console.error(
|
|
3733
|
-
"lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))\n\nDid you accidentally put curly braces around the import?",
|
|
3734
|
-
ioInfo
|
|
3735
|
-
), "default" in ioInfo || console.error(
|
|
3736
|
-
"lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))",
|
|
3737
|
-
ioInfo
|
|
3738
|
-
), ioInfo.default;
|
|
3739
|
-
throw payload._result;
|
|
3740
|
-
}
|
|
3741
|
-
function resolveDispatcher() {
|
|
3742
|
-
var dispatcher = ReactSharedInternals.H;
|
|
3743
|
-
null === dispatcher && console.error(
|
|
3744
|
-
"Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem."
|
|
3745
|
-
);
|
|
3746
|
-
return dispatcher;
|
|
3747
|
-
}
|
|
3748
|
-
function releaseAsyncTransition() {
|
|
3749
|
-
ReactSharedInternals.asyncTransitions--;
|
|
3750
|
-
}
|
|
3751
|
-
function enqueueTask(task) {
|
|
3752
|
-
if (null === enqueueTaskImpl)
|
|
3753
|
-
try {
|
|
3754
|
-
var requireString = ("require" + Math.random()).slice(0, 7);
|
|
3755
|
-
enqueueTaskImpl = (module && module[requireString]).call(
|
|
3756
|
-
module,
|
|
3757
|
-
"timers"
|
|
3758
|
-
).setImmediate;
|
|
3759
|
-
} catch (_err) {
|
|
3760
|
-
enqueueTaskImpl = function(callback) {
|
|
3761
|
-
false === didWarnAboutMessageChannel && (didWarnAboutMessageChannel = true, "undefined" === typeof MessageChannel && console.error(
|
|
3762
|
-
"This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning."
|
|
3763
|
-
));
|
|
3764
|
-
var channel = new MessageChannel();
|
|
3765
|
-
channel.port1.onmessage = callback;
|
|
3766
|
-
channel.port2.postMessage(void 0);
|
|
3767
|
-
};
|
|
3768
|
-
}
|
|
3769
|
-
return enqueueTaskImpl(task);
|
|
3770
|
-
}
|
|
3771
|
-
function aggregateErrors(errors) {
|
|
3772
|
-
return 1 < errors.length && "function" === typeof AggregateError ? new AggregateError(errors) : errors[0];
|
|
3773
|
-
}
|
|
3774
|
-
function popActScope(prevActQueue, prevActScopeDepth) {
|
|
3775
|
-
prevActScopeDepth !== actScopeDepth - 1 && console.error(
|
|
3776
|
-
"You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. "
|
|
3777
|
-
);
|
|
3778
|
-
actScopeDepth = prevActScopeDepth;
|
|
3779
|
-
}
|
|
3780
|
-
function recursivelyFlushAsyncActWork(returnValue, resolve, reject) {
|
|
3781
|
-
var queue = ReactSharedInternals.actQueue;
|
|
3782
|
-
if (null !== queue)
|
|
3783
|
-
if (0 !== queue.length)
|
|
3784
|
-
try {
|
|
3785
|
-
flushActQueue(queue);
|
|
3786
|
-
enqueueTask(function() {
|
|
3787
|
-
return recursivelyFlushAsyncActWork(returnValue, resolve, reject);
|
|
3788
|
-
});
|
|
3789
|
-
return;
|
|
3790
|
-
} catch (error) {
|
|
3791
|
-
ReactSharedInternals.thrownErrors.push(error);
|
|
3792
|
-
}
|
|
3793
|
-
else ReactSharedInternals.actQueue = null;
|
|
3794
|
-
0 < ReactSharedInternals.thrownErrors.length ? (queue = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, reject(queue)) : resolve(returnValue);
|
|
3795
|
-
}
|
|
3796
|
-
function flushActQueue(queue) {
|
|
3797
|
-
if (!isFlushing) {
|
|
3798
|
-
isFlushing = true;
|
|
3799
|
-
var i = 0;
|
|
3800
|
-
try {
|
|
3801
|
-
for (; i < queue.length; i++) {
|
|
3802
|
-
var callback = queue[i];
|
|
3803
|
-
do {
|
|
3804
|
-
ReactSharedInternals.didUsePromise = false;
|
|
3805
|
-
var continuation = callback(false);
|
|
3806
|
-
if (null !== continuation) {
|
|
3807
|
-
if (ReactSharedInternals.didUsePromise) {
|
|
3808
|
-
queue[i] = callback;
|
|
3809
|
-
queue.splice(0, i);
|
|
3810
|
-
return;
|
|
3811
|
-
}
|
|
3812
|
-
callback = continuation;
|
|
3813
|
-
} else break;
|
|
3814
|
-
} while (1);
|
|
3815
|
-
}
|
|
3816
|
-
queue.length = 0;
|
|
3817
|
-
} catch (error) {
|
|
3818
|
-
queue.splice(0, i + 1), ReactSharedInternals.thrownErrors.push(error);
|
|
3819
|
-
} finally {
|
|
3820
|
-
isFlushing = false;
|
|
3821
|
-
}
|
|
3822
|
-
}
|
|
3823
|
-
}
|
|
3824
|
-
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
3825
|
-
var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = Symbol.for("react.profiler"), REACT_CONSUMER_TYPE = Symbol.for("react.consumer"), REACT_CONTEXT_TYPE = Symbol.for("react.context"), REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"), REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"), REACT_MEMO_TYPE = Symbol.for("react.memo"), REACT_LAZY_TYPE = Symbol.for("react.lazy"), REACT_ACTIVITY_TYPE = Symbol.for("react.activity"), MAYBE_ITERATOR_SYMBOL = Symbol.iterator, didWarnStateUpdateForUnmountedComponent = {}, ReactNoopUpdateQueue = {
|
|
3826
|
-
isMounted: function() {
|
|
3827
|
-
return false;
|
|
3828
|
-
},
|
|
3829
|
-
enqueueForceUpdate: function(publicInstance) {
|
|
3830
|
-
warnNoop(publicInstance, "forceUpdate");
|
|
3831
|
-
},
|
|
3832
|
-
enqueueReplaceState: function(publicInstance) {
|
|
3833
|
-
warnNoop(publicInstance, "replaceState");
|
|
3834
|
-
},
|
|
3835
|
-
enqueueSetState: function(publicInstance) {
|
|
3836
|
-
warnNoop(publicInstance, "setState");
|
|
3837
|
-
}
|
|
3838
|
-
}, assign = Object.assign, emptyObject = {};
|
|
3839
|
-
Object.freeze(emptyObject);
|
|
3840
|
-
Component.prototype.isReactComponent = {};
|
|
3841
|
-
Component.prototype.setState = function(partialState, callback) {
|
|
3842
|
-
if ("object" !== typeof partialState && "function" !== typeof partialState && null != partialState)
|
|
3843
|
-
throw Error(
|
|
3844
|
-
"takes an object of state variables to update or a function which returns an object of state variables."
|
|
3845
|
-
);
|
|
3846
|
-
this.updater.enqueueSetState(this, partialState, callback, "setState");
|
|
3847
|
-
};
|
|
3848
|
-
Component.prototype.forceUpdate = function(callback) {
|
|
3849
|
-
this.updater.enqueueForceUpdate(this, callback, "forceUpdate");
|
|
3850
|
-
};
|
|
3851
|
-
var deprecatedAPIs = {
|
|
3852
|
-
isMounted: [
|
|
3853
|
-
"isMounted",
|
|
3854
|
-
"Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."
|
|
3855
|
-
],
|
|
3856
|
-
replaceState: [
|
|
3857
|
-
"replaceState",
|
|
3858
|
-
"Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."
|
|
3859
|
-
]
|
|
3860
|
-
};
|
|
3861
|
-
for (fnName in deprecatedAPIs)
|
|
3862
|
-
deprecatedAPIs.hasOwnProperty(fnName) && defineDeprecationWarning(fnName, deprecatedAPIs[fnName]);
|
|
3863
|
-
ComponentDummy.prototype = Component.prototype;
|
|
3864
|
-
deprecatedAPIs = PureComponent.prototype = new ComponentDummy();
|
|
3865
|
-
deprecatedAPIs.constructor = PureComponent;
|
|
3866
|
-
assign(deprecatedAPIs, Component.prototype);
|
|
3867
|
-
deprecatedAPIs.isPureReactComponent = true;
|
|
3868
|
-
var isArrayImpl = Array.isArray, REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"), ReactSharedInternals = {
|
|
3869
|
-
H: null,
|
|
3870
|
-
A: null,
|
|
3871
|
-
T: null,
|
|
3872
|
-
S: null,
|
|
3873
|
-
actQueue: null,
|
|
3874
|
-
asyncTransitions: 0,
|
|
3875
|
-
isBatchingLegacy: false,
|
|
3876
|
-
didScheduleLegacyUpdate: false,
|
|
3877
|
-
didUsePromise: false,
|
|
3878
|
-
thrownErrors: [],
|
|
3879
|
-
getCurrentStack: null,
|
|
3880
|
-
recentlyCreatedOwnerStacks: 0
|
|
3881
|
-
}, hasOwnProperty = Object.prototype.hasOwnProperty, createTask = console.createTask ? console.createTask : function() {
|
|
3882
|
-
return null;
|
|
3883
|
-
};
|
|
3884
|
-
deprecatedAPIs = {
|
|
3885
|
-
react_stack_bottom_frame: function(callStackForError) {
|
|
3886
|
-
return callStackForError();
|
|
3887
|
-
}
|
|
3888
|
-
};
|
|
3889
|
-
var specialPropKeyWarningShown, didWarnAboutOldJSXRuntime;
|
|
3890
|
-
var didWarnAboutElementRef = {};
|
|
3891
|
-
var unknownOwnerDebugStack = deprecatedAPIs.react_stack_bottom_frame.bind(
|
|
3892
|
-
deprecatedAPIs,
|
|
3893
|
-
UnknownOwner
|
|
3894
|
-
)();
|
|
3895
|
-
var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));
|
|
3896
|
-
var didWarnAboutMaps = false, userProvidedKeyEscapeRegex = /\/+/g, reportGlobalError = "function" === typeof reportError ? reportError : function(error) {
|
|
3897
|
-
if ("object" === typeof window && "function" === typeof window.ErrorEvent) {
|
|
3898
|
-
var event = new window.ErrorEvent("error", {
|
|
3899
|
-
bubbles: true,
|
|
3900
|
-
cancelable: true,
|
|
3901
|
-
message: "object" === typeof error && null !== error && "string" === typeof error.message ? String(error.message) : String(error),
|
|
3902
|
-
error
|
|
3903
|
-
});
|
|
3904
|
-
if (!window.dispatchEvent(event)) return;
|
|
3905
|
-
} else if ("object" === typeof process && "function" === typeof process.emit) {
|
|
3906
|
-
process.emit("uncaughtException", error);
|
|
3907
|
-
return;
|
|
3908
|
-
}
|
|
3909
|
-
console.error(error);
|
|
3910
|
-
}, didWarnAboutMessageChannel = false, enqueueTaskImpl = null, actScopeDepth = 0, didWarnNoAwaitAct = false, isFlushing = false, queueSeveralMicrotasks = "function" === typeof queueMicrotask ? function(callback) {
|
|
3911
|
-
queueMicrotask(function() {
|
|
3912
|
-
return queueMicrotask(callback);
|
|
3913
|
-
});
|
|
3914
|
-
} : enqueueTask;
|
|
3915
|
-
deprecatedAPIs = Object.freeze({
|
|
3916
|
-
__proto__: null,
|
|
3917
|
-
c: function(size) {
|
|
3918
|
-
return resolveDispatcher().useMemoCache(size);
|
|
3919
|
-
}
|
|
3920
|
-
});
|
|
3921
|
-
var fnName = {
|
|
3922
|
-
map: mapChildren,
|
|
3923
|
-
forEach: function(children, forEachFunc, forEachContext) {
|
|
3924
|
-
mapChildren(
|
|
3925
|
-
children,
|
|
3926
|
-
function() {
|
|
3927
|
-
forEachFunc.apply(this, arguments);
|
|
3928
|
-
},
|
|
3929
|
-
forEachContext
|
|
3930
|
-
);
|
|
3931
|
-
},
|
|
3932
|
-
count: function(children) {
|
|
3933
|
-
var n = 0;
|
|
3934
|
-
mapChildren(children, function() {
|
|
3935
|
-
n++;
|
|
3936
|
-
});
|
|
3937
|
-
return n;
|
|
3938
|
-
},
|
|
3939
|
-
toArray: function(children) {
|
|
3940
|
-
return mapChildren(children, function(child) {
|
|
3941
|
-
return child;
|
|
3942
|
-
}) || [];
|
|
3943
|
-
},
|
|
3944
|
-
only: function(children) {
|
|
3945
|
-
if (!isValidElement(children))
|
|
3946
|
-
throw Error(
|
|
3947
|
-
"React.Children.only expected to receive a single React element child."
|
|
3948
|
-
);
|
|
3949
|
-
return children;
|
|
3950
|
-
}
|
|
3951
|
-
};
|
|
3952
|
-
exports.Activity = REACT_ACTIVITY_TYPE;
|
|
3953
|
-
exports.Children = fnName;
|
|
3954
|
-
exports.Component = Component;
|
|
3955
|
-
exports.Fragment = REACT_FRAGMENT_TYPE;
|
|
3956
|
-
exports.Profiler = REACT_PROFILER_TYPE;
|
|
3957
|
-
exports.PureComponent = PureComponent;
|
|
3958
|
-
exports.StrictMode = REACT_STRICT_MODE_TYPE;
|
|
3959
|
-
exports.Suspense = REACT_SUSPENSE_TYPE;
|
|
3960
|
-
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = ReactSharedInternals;
|
|
3961
|
-
exports.__COMPILER_RUNTIME = deprecatedAPIs;
|
|
3962
|
-
exports.act = function(callback) {
|
|
3963
|
-
var prevActQueue = ReactSharedInternals.actQueue, prevActScopeDepth = actScopeDepth;
|
|
3964
|
-
actScopeDepth++;
|
|
3965
|
-
var queue = ReactSharedInternals.actQueue = null !== prevActQueue ? prevActQueue : [], didAwaitActCall = false;
|
|
3966
|
-
try {
|
|
3967
|
-
var result = callback();
|
|
3968
|
-
} catch (error) {
|
|
3969
|
-
ReactSharedInternals.thrownErrors.push(error);
|
|
3970
|
-
}
|
|
3971
|
-
if (0 < ReactSharedInternals.thrownErrors.length)
|
|
3972
|
-
throw popActScope(prevActQueue, prevActScopeDepth), callback = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, callback;
|
|
3973
|
-
if (null !== result && "object" === typeof result && "function" === typeof result.then) {
|
|
3974
|
-
var thenable = result;
|
|
3975
|
-
queueSeveralMicrotasks(function() {
|
|
3976
|
-
didAwaitActCall || didWarnNoAwaitAct || (didWarnNoAwaitAct = true, console.error(
|
|
3977
|
-
"You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);"
|
|
3978
|
-
));
|
|
3979
|
-
});
|
|
3980
|
-
return {
|
|
3981
|
-
then: function(resolve, reject) {
|
|
3982
|
-
didAwaitActCall = true;
|
|
3983
|
-
thenable.then(
|
|
3984
|
-
function(returnValue) {
|
|
3985
|
-
popActScope(prevActQueue, prevActScopeDepth);
|
|
3986
|
-
if (0 === prevActScopeDepth) {
|
|
3987
|
-
try {
|
|
3988
|
-
flushActQueue(queue), enqueueTask(function() {
|
|
3989
|
-
return recursivelyFlushAsyncActWork(
|
|
3990
|
-
returnValue,
|
|
3991
|
-
resolve,
|
|
3992
|
-
reject
|
|
3993
|
-
);
|
|
3994
|
-
});
|
|
3995
|
-
} catch (error$0) {
|
|
3996
|
-
ReactSharedInternals.thrownErrors.push(error$0);
|
|
3997
|
-
}
|
|
3998
|
-
if (0 < ReactSharedInternals.thrownErrors.length) {
|
|
3999
|
-
var _thrownError = aggregateErrors(
|
|
4000
|
-
ReactSharedInternals.thrownErrors
|
|
4001
|
-
);
|
|
4002
|
-
ReactSharedInternals.thrownErrors.length = 0;
|
|
4003
|
-
reject(_thrownError);
|
|
4004
|
-
}
|
|
4005
|
-
} else resolve(returnValue);
|
|
4006
|
-
},
|
|
4007
|
-
function(error) {
|
|
4008
|
-
popActScope(prevActQueue, prevActScopeDepth);
|
|
4009
|
-
0 < ReactSharedInternals.thrownErrors.length ? (error = aggregateErrors(
|
|
4010
|
-
ReactSharedInternals.thrownErrors
|
|
4011
|
-
), ReactSharedInternals.thrownErrors.length = 0, reject(error)) : reject(error);
|
|
4012
|
-
}
|
|
4013
|
-
);
|
|
4014
|
-
}
|
|
4015
|
-
};
|
|
4016
|
-
}
|
|
4017
|
-
var returnValue$jscomp$0 = result;
|
|
4018
|
-
popActScope(prevActQueue, prevActScopeDepth);
|
|
4019
|
-
0 === prevActScopeDepth && (flushActQueue(queue), 0 !== queue.length && queueSeveralMicrotasks(function() {
|
|
4020
|
-
didAwaitActCall || didWarnNoAwaitAct || (didWarnNoAwaitAct = true, console.error(
|
|
4021
|
-
"A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\n\nawait act(() => ...)"
|
|
4022
|
-
));
|
|
4023
|
-
}), ReactSharedInternals.actQueue = null);
|
|
4024
|
-
if (0 < ReactSharedInternals.thrownErrors.length)
|
|
4025
|
-
throw callback = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, callback;
|
|
4026
|
-
return {
|
|
4027
|
-
then: function(resolve, reject) {
|
|
4028
|
-
didAwaitActCall = true;
|
|
4029
|
-
0 === prevActScopeDepth ? (ReactSharedInternals.actQueue = queue, enqueueTask(function() {
|
|
4030
|
-
return recursivelyFlushAsyncActWork(
|
|
4031
|
-
returnValue$jscomp$0,
|
|
4032
|
-
resolve,
|
|
4033
|
-
reject
|
|
4034
|
-
);
|
|
4035
|
-
})) : resolve(returnValue$jscomp$0);
|
|
4036
|
-
}
|
|
4037
|
-
};
|
|
4038
|
-
};
|
|
4039
|
-
exports.cache = function(fn) {
|
|
4040
|
-
return function() {
|
|
4041
|
-
return fn.apply(null, arguments);
|
|
4042
|
-
};
|
|
4043
|
-
};
|
|
4044
|
-
exports.cacheSignal = function() {
|
|
4045
|
-
return null;
|
|
4046
|
-
};
|
|
4047
|
-
exports.captureOwnerStack = function() {
|
|
4048
|
-
var getCurrentStack = ReactSharedInternals.getCurrentStack;
|
|
4049
|
-
return null === getCurrentStack ? null : getCurrentStack();
|
|
4050
|
-
};
|
|
4051
|
-
exports.cloneElement = function(element, config, children) {
|
|
4052
|
-
if (null === element || void 0 === element)
|
|
4053
|
-
throw Error(
|
|
4054
|
-
"The argument must be a React element, but you passed " + element + "."
|
|
4055
|
-
);
|
|
4056
|
-
var props = assign({}, element.props), key = element.key, owner = element._owner;
|
|
4057
|
-
if (null != config) {
|
|
4058
|
-
var JSCompiler_inline_result;
|
|
4059
|
-
a: {
|
|
4060
|
-
if (hasOwnProperty.call(config, "ref") && (JSCompiler_inline_result = Object.getOwnPropertyDescriptor(
|
|
4061
|
-
config,
|
|
4062
|
-
"ref"
|
|
4063
|
-
).get) && JSCompiler_inline_result.isReactWarning) {
|
|
4064
|
-
JSCompiler_inline_result = false;
|
|
4065
|
-
break a;
|
|
4066
|
-
}
|
|
4067
|
-
JSCompiler_inline_result = void 0 !== config.ref;
|
|
4068
|
-
}
|
|
4069
|
-
JSCompiler_inline_result && (owner = getOwner());
|
|
4070
|
-
hasValidKey(config) && (checkKeyStringCoercion(config.key), key = "" + config.key);
|
|
4071
|
-
for (propName in config)
|
|
4072
|
-
!hasOwnProperty.call(config, propName) || "key" === propName || "__self" === propName || "__source" === propName || "ref" === propName && void 0 === config.ref || (props[propName] = config[propName]);
|
|
4073
|
-
}
|
|
4074
|
-
var propName = arguments.length - 2;
|
|
4075
|
-
if (1 === propName) props.children = children;
|
|
4076
|
-
else if (1 < propName) {
|
|
4077
|
-
JSCompiler_inline_result = Array(propName);
|
|
4078
|
-
for (var i = 0; i < propName; i++)
|
|
4079
|
-
JSCompiler_inline_result[i] = arguments[i + 2];
|
|
4080
|
-
props.children = JSCompiler_inline_result;
|
|
4081
|
-
}
|
|
4082
|
-
props = ReactElement(
|
|
4083
|
-
element.type,
|
|
4084
|
-
key,
|
|
4085
|
-
props,
|
|
4086
|
-
owner,
|
|
4087
|
-
element._debugStack,
|
|
4088
|
-
element._debugTask
|
|
4089
|
-
);
|
|
4090
|
-
for (key = 2; key < arguments.length; key++)
|
|
4091
|
-
validateChildKeys(arguments[key]);
|
|
4092
|
-
return props;
|
|
4093
|
-
};
|
|
4094
|
-
exports.createContext = function(defaultValue) {
|
|
4095
|
-
defaultValue = {
|
|
4096
|
-
$$typeof: REACT_CONTEXT_TYPE,
|
|
4097
|
-
_currentValue: defaultValue,
|
|
4098
|
-
_currentValue2: defaultValue,
|
|
4099
|
-
_threadCount: 0,
|
|
4100
|
-
Provider: null,
|
|
4101
|
-
Consumer: null
|
|
4102
|
-
};
|
|
4103
|
-
defaultValue.Provider = defaultValue;
|
|
4104
|
-
defaultValue.Consumer = {
|
|
4105
|
-
$$typeof: REACT_CONSUMER_TYPE,
|
|
4106
|
-
_context: defaultValue
|
|
4107
|
-
};
|
|
4108
|
-
defaultValue._currentRenderer = null;
|
|
4109
|
-
defaultValue._currentRenderer2 = null;
|
|
4110
|
-
return defaultValue;
|
|
4111
|
-
};
|
|
4112
|
-
exports.createElement = function(type, config, children) {
|
|
4113
|
-
for (var i = 2; i < arguments.length; i++)
|
|
4114
|
-
validateChildKeys(arguments[i]);
|
|
4115
|
-
i = {};
|
|
4116
|
-
var key = null;
|
|
4117
|
-
if (null != config)
|
|
4118
|
-
for (propName in didWarnAboutOldJSXRuntime || !("__self" in config) || "key" in config || (didWarnAboutOldJSXRuntime = true, console.warn(
|
|
4119
|
-
"Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform"
|
|
4120
|
-
)), hasValidKey(config) && (checkKeyStringCoercion(config.key), key = "" + config.key), config)
|
|
4121
|
-
hasOwnProperty.call(config, propName) && "key" !== propName && "__self" !== propName && "__source" !== propName && (i[propName] = config[propName]);
|
|
4122
|
-
var childrenLength = arguments.length - 2;
|
|
4123
|
-
if (1 === childrenLength) i.children = children;
|
|
4124
|
-
else if (1 < childrenLength) {
|
|
4125
|
-
for (var childArray = Array(childrenLength), _i = 0; _i < childrenLength; _i++)
|
|
4126
|
-
childArray[_i] = arguments[_i + 2];
|
|
4127
|
-
Object.freeze && Object.freeze(childArray);
|
|
4128
|
-
i.children = childArray;
|
|
4129
|
-
}
|
|
4130
|
-
if (type && type.defaultProps)
|
|
4131
|
-
for (propName in childrenLength = type.defaultProps, childrenLength)
|
|
4132
|
-
void 0 === i[propName] && (i[propName] = childrenLength[propName]);
|
|
4133
|
-
key && defineKeyPropWarningGetter(
|
|
4134
|
-
i,
|
|
4135
|
-
"function" === typeof type ? type.displayName || type.name || "Unknown" : type
|
|
4136
|
-
);
|
|
4137
|
-
var propName = 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;
|
|
4138
|
-
return ReactElement(
|
|
4139
|
-
type,
|
|
4140
|
-
key,
|
|
4141
|
-
i,
|
|
4142
|
-
getOwner(),
|
|
4143
|
-
propName ? Error("react-stack-top-frame") : unknownOwnerDebugStack,
|
|
4144
|
-
propName ? createTask(getTaskName(type)) : unknownOwnerDebugTask
|
|
4145
|
-
);
|
|
4146
|
-
};
|
|
4147
|
-
exports.createRef = function() {
|
|
4148
|
-
var refObject = { current: null };
|
|
4149
|
-
Object.seal(refObject);
|
|
4150
|
-
return refObject;
|
|
4151
|
-
};
|
|
4152
|
-
exports.forwardRef = function(render) {
|
|
4153
|
-
null != render && render.$$typeof === REACT_MEMO_TYPE ? console.error(
|
|
4154
|
-
"forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))."
|
|
4155
|
-
) : "function" !== typeof render ? console.error(
|
|
4156
|
-
"forwardRef requires a render function but was given %s.",
|
|
4157
|
-
null === render ? "null" : typeof render
|
|
4158
|
-
) : 0 !== render.length && 2 !== render.length && console.error(
|
|
4159
|
-
"forwardRef render functions accept exactly two parameters: props and ref. %s",
|
|
4160
|
-
1 === render.length ? "Did you forget to use the ref parameter?" : "Any additional parameter will be undefined."
|
|
4161
|
-
);
|
|
4162
|
-
null != render && null != render.defaultProps && console.error(
|
|
4163
|
-
"forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?"
|
|
4164
|
-
);
|
|
4165
|
-
var elementType = { $$typeof: REACT_FORWARD_REF_TYPE, render }, ownName;
|
|
4166
|
-
Object.defineProperty(elementType, "displayName", {
|
|
4167
|
-
enumerable: false,
|
|
4168
|
-
configurable: true,
|
|
4169
|
-
get: function() {
|
|
4170
|
-
return ownName;
|
|
4171
|
-
},
|
|
4172
|
-
set: function(name) {
|
|
4173
|
-
ownName = name;
|
|
4174
|
-
render.name || render.displayName || (Object.defineProperty(render, "name", { value: name }), render.displayName = name);
|
|
4175
|
-
}
|
|
4176
|
-
});
|
|
4177
|
-
return elementType;
|
|
4178
|
-
};
|
|
4179
|
-
exports.isValidElement = isValidElement;
|
|
4180
|
-
exports.lazy = function(ctor) {
|
|
4181
|
-
ctor = { _status: -1, _result: ctor };
|
|
4182
|
-
var lazyType = {
|
|
4183
|
-
$$typeof: REACT_LAZY_TYPE,
|
|
4184
|
-
_payload: ctor,
|
|
4185
|
-
_init: lazyInitializer
|
|
4186
|
-
}, ioInfo = {
|
|
4187
|
-
name: "lazy",
|
|
4188
|
-
start: -1,
|
|
4189
|
-
end: -1,
|
|
4190
|
-
value: null,
|
|
4191
|
-
owner: null,
|
|
4192
|
-
debugStack: Error("react-stack-top-frame"),
|
|
4193
|
-
debugTask: console.createTask ? console.createTask("lazy()") : null
|
|
4194
|
-
};
|
|
4195
|
-
ctor._ioInfo = ioInfo;
|
|
4196
|
-
lazyType._debugInfo = [{ awaited: ioInfo }];
|
|
4197
|
-
return lazyType;
|
|
4198
|
-
};
|
|
4199
|
-
exports.memo = function(type, compare) {
|
|
4200
|
-
null == type && console.error(
|
|
4201
|
-
"memo: The first argument must be a component. Instead received: %s",
|
|
4202
|
-
null === type ? "null" : typeof type
|
|
4203
|
-
);
|
|
4204
|
-
compare = {
|
|
4205
|
-
$$typeof: REACT_MEMO_TYPE,
|
|
4206
|
-
type,
|
|
4207
|
-
compare: void 0 === compare ? null : compare
|
|
4208
|
-
};
|
|
4209
|
-
var ownName;
|
|
4210
|
-
Object.defineProperty(compare, "displayName", {
|
|
4211
|
-
enumerable: false,
|
|
4212
|
-
configurable: true,
|
|
4213
|
-
get: function() {
|
|
4214
|
-
return ownName;
|
|
4215
|
-
},
|
|
4216
|
-
set: function(name) {
|
|
4217
|
-
ownName = name;
|
|
4218
|
-
type.name || type.displayName || (Object.defineProperty(type, "name", { value: name }), type.displayName = name);
|
|
4219
|
-
}
|
|
4220
|
-
});
|
|
4221
|
-
return compare;
|
|
4222
|
-
};
|
|
4223
|
-
exports.startTransition = function(scope) {
|
|
4224
|
-
var prevTransition = ReactSharedInternals.T, currentTransition = {};
|
|
4225
|
-
currentTransition._updatedFibers = /* @__PURE__ */ new Set();
|
|
4226
|
-
ReactSharedInternals.T = currentTransition;
|
|
4227
|
-
try {
|
|
4228
|
-
var returnValue = scope(), onStartTransitionFinish = ReactSharedInternals.S;
|
|
4229
|
-
null !== onStartTransitionFinish && onStartTransitionFinish(currentTransition, returnValue);
|
|
4230
|
-
"object" === typeof returnValue && null !== returnValue && "function" === typeof returnValue.then && (ReactSharedInternals.asyncTransitions++, returnValue.then(releaseAsyncTransition, releaseAsyncTransition), returnValue.then(noop, reportGlobalError));
|
|
4231
|
-
} catch (error) {
|
|
4232
|
-
reportGlobalError(error);
|
|
4233
|
-
} finally {
|
|
4234
|
-
null === prevTransition && currentTransition._updatedFibers && (scope = currentTransition._updatedFibers.size, currentTransition._updatedFibers.clear(), 10 < scope && console.warn(
|
|
4235
|
-
"Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table."
|
|
4236
|
-
)), null !== prevTransition && null !== currentTransition.types && (null !== prevTransition.types && prevTransition.types !== currentTransition.types && console.error(
|
|
4237
|
-
"We expected inner Transitions to have transferred the outer types set and that you cannot add to the outer Transition while inside the inner.This is a bug in React."
|
|
4238
|
-
), prevTransition.types = currentTransition.types), ReactSharedInternals.T = prevTransition;
|
|
4239
|
-
}
|
|
4240
|
-
};
|
|
4241
|
-
exports.unstable_useCacheRefresh = function() {
|
|
4242
|
-
return resolveDispatcher().useCacheRefresh();
|
|
4243
|
-
};
|
|
4244
|
-
exports.use = function(usable) {
|
|
4245
|
-
return resolveDispatcher().use(usable);
|
|
4246
|
-
};
|
|
4247
|
-
exports.useActionState = function(action, initialState, permalink) {
|
|
4248
|
-
return resolveDispatcher().useActionState(
|
|
4249
|
-
action,
|
|
4250
|
-
initialState,
|
|
4251
|
-
permalink
|
|
4252
|
-
);
|
|
4253
|
-
};
|
|
4254
|
-
exports.useCallback = function(callback, deps) {
|
|
4255
|
-
return resolveDispatcher().useCallback(callback, deps);
|
|
4256
|
-
};
|
|
4257
|
-
exports.useContext = function(Context) {
|
|
4258
|
-
var dispatcher = resolveDispatcher();
|
|
4259
|
-
Context.$$typeof === REACT_CONSUMER_TYPE && console.error(
|
|
4260
|
-
"Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?"
|
|
4261
|
-
);
|
|
4262
|
-
return dispatcher.useContext(Context);
|
|
4263
|
-
};
|
|
4264
|
-
exports.useDebugValue = function(value2, formatterFn) {
|
|
4265
|
-
return resolveDispatcher().useDebugValue(value2, formatterFn);
|
|
4266
|
-
};
|
|
4267
|
-
exports.useDeferredValue = function(value2, initialValue) {
|
|
4268
|
-
return resolveDispatcher().useDeferredValue(value2, initialValue);
|
|
4269
|
-
};
|
|
4270
|
-
exports.useEffect = function(create, deps) {
|
|
4271
|
-
null == create && console.warn(
|
|
4272
|
-
"React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?"
|
|
4273
|
-
);
|
|
4274
|
-
return resolveDispatcher().useEffect(create, deps);
|
|
4275
|
-
};
|
|
4276
|
-
exports.useEffectEvent = function(callback) {
|
|
4277
|
-
return resolveDispatcher().useEffectEvent(callback);
|
|
4278
|
-
};
|
|
4279
|
-
exports.useId = function() {
|
|
4280
|
-
return resolveDispatcher().useId();
|
|
4281
|
-
};
|
|
4282
|
-
exports.useImperativeHandle = function(ref, create, deps) {
|
|
4283
|
-
return resolveDispatcher().useImperativeHandle(ref, create, deps);
|
|
4284
|
-
};
|
|
4285
|
-
exports.useInsertionEffect = function(create, deps) {
|
|
4286
|
-
null == create && console.warn(
|
|
4287
|
-
"React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?"
|
|
4288
|
-
);
|
|
4289
|
-
return resolveDispatcher().useInsertionEffect(create, deps);
|
|
4290
|
-
};
|
|
4291
|
-
exports.useLayoutEffect = function(create, deps) {
|
|
4292
|
-
null == create && console.warn(
|
|
4293
|
-
"React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?"
|
|
4294
|
-
);
|
|
4295
|
-
return resolveDispatcher().useLayoutEffect(create, deps);
|
|
4296
|
-
};
|
|
4297
|
-
exports.useMemo = function(create, deps) {
|
|
4298
|
-
return resolveDispatcher().useMemo(create, deps);
|
|
4299
|
-
};
|
|
4300
|
-
exports.useOptimistic = function(passthrough, reducer) {
|
|
4301
|
-
return resolveDispatcher().useOptimistic(passthrough, reducer);
|
|
4302
|
-
};
|
|
4303
|
-
exports.useReducer = function(reducer, initialArg, init) {
|
|
4304
|
-
return resolveDispatcher().useReducer(reducer, initialArg, init);
|
|
4305
|
-
};
|
|
4306
|
-
exports.useRef = function(initialValue) {
|
|
4307
|
-
return resolveDispatcher().useRef(initialValue);
|
|
4308
|
-
};
|
|
4309
|
-
exports.useState = function(initialState) {
|
|
4310
|
-
return resolveDispatcher().useState(initialState);
|
|
4311
|
-
};
|
|
4312
|
-
exports.useSyncExternalStore = function(subscribe, getSnapshot, getServerSnapshot) {
|
|
4313
|
-
return resolveDispatcher().useSyncExternalStore(
|
|
4314
|
-
subscribe,
|
|
4315
|
-
getSnapshot,
|
|
4316
|
-
getServerSnapshot
|
|
4317
|
-
);
|
|
4318
|
-
};
|
|
4319
|
-
exports.useTransition = function() {
|
|
4320
|
-
return resolveDispatcher().useTransition();
|
|
4321
|
-
};
|
|
4322
|
-
exports.version = "19.2.7";
|
|
4323
|
-
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
4324
|
-
})();
|
|
4325
|
-
})(react_development, react_development.exports);
|
|
4326
|
-
return react_development.exports;
|
|
4327
|
-
}
|
|
4328
|
-
var hasRequiredReact;
|
|
4329
|
-
function requireReact() {
|
|
4330
|
-
if (hasRequiredReact) return react.exports;
|
|
4331
|
-
hasRequiredReact = 1;
|
|
4332
|
-
if (process.env.NODE_ENV === "production") {
|
|
4333
|
-
react.exports = requireReact_production();
|
|
4334
|
-
} else {
|
|
4335
|
-
react.exports = requireReact_development();
|
|
4336
|
-
}
|
|
4337
|
-
return react.exports;
|
|
4338
|
-
}
|
|
4339
|
-
/**
|
|
4340
|
-
* @license React
|
|
4341
|
-
* react-jsx-runtime.development.js
|
|
4342
|
-
*
|
|
4343
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
4344
|
-
*
|
|
4345
|
-
* This source code is licensed under the MIT license found in the
|
|
4346
|
-
* LICENSE file in the root directory of this source tree.
|
|
4347
|
-
*/
|
|
4348
|
-
var hasRequiredReactJsxRuntime_development;
|
|
4349
|
-
function requireReactJsxRuntime_development() {
|
|
4350
|
-
if (hasRequiredReactJsxRuntime_development) return reactJsxRuntime_development;
|
|
4351
|
-
hasRequiredReactJsxRuntime_development = 1;
|
|
4352
|
-
"production" !== process.env.NODE_ENV && (function() {
|
|
4353
|
-
function getComponentNameFromType(type) {
|
|
4354
|
-
if (null == type) return null;
|
|
4355
|
-
if ("function" === typeof type)
|
|
4356
|
-
return type.$$typeof === REACT_CLIENT_REFERENCE ? null : type.displayName || type.name || null;
|
|
4357
|
-
if ("string" === typeof type) return type;
|
|
4358
|
-
switch (type) {
|
|
4359
|
-
case REACT_FRAGMENT_TYPE:
|
|
4360
|
-
return "Fragment";
|
|
4361
|
-
case REACT_PROFILER_TYPE:
|
|
4362
|
-
return "Profiler";
|
|
4363
|
-
case REACT_STRICT_MODE_TYPE:
|
|
4364
|
-
return "StrictMode";
|
|
4365
|
-
case REACT_SUSPENSE_TYPE:
|
|
4366
|
-
return "Suspense";
|
|
4367
|
-
case REACT_SUSPENSE_LIST_TYPE:
|
|
4368
|
-
return "SuspenseList";
|
|
4369
|
-
case REACT_ACTIVITY_TYPE:
|
|
4370
|
-
return "Activity";
|
|
4371
|
-
}
|
|
4372
|
-
if ("object" === typeof type)
|
|
4373
|
-
switch ("number" === typeof type.tag && console.error(
|
|
4374
|
-
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
4375
|
-
), type.$$typeof) {
|
|
4376
|
-
case REACT_PORTAL_TYPE:
|
|
4377
|
-
return "Portal";
|
|
4378
|
-
case REACT_CONTEXT_TYPE:
|
|
4379
|
-
return type.displayName || "Context";
|
|
4380
|
-
case REACT_CONSUMER_TYPE:
|
|
4381
|
-
return (type._context.displayName || "Context") + ".Consumer";
|
|
4382
|
-
case REACT_FORWARD_REF_TYPE:
|
|
4383
|
-
var innerType = type.render;
|
|
4384
|
-
type = type.displayName;
|
|
4385
|
-
type || (type = innerType.displayName || innerType.name || "", type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef");
|
|
4386
|
-
return type;
|
|
4387
|
-
case REACT_MEMO_TYPE:
|
|
4388
|
-
return innerType = type.displayName || null, null !== innerType ? innerType : getComponentNameFromType(type.type) || "Memo";
|
|
4389
|
-
case REACT_LAZY_TYPE:
|
|
4390
|
-
innerType = type._payload;
|
|
4391
|
-
type = type._init;
|
|
4392
|
-
try {
|
|
4393
|
-
return getComponentNameFromType(type(innerType));
|
|
4394
|
-
} catch (x) {
|
|
4395
|
-
}
|
|
4396
|
-
}
|
|
4397
|
-
return null;
|
|
4398
|
-
}
|
|
4399
|
-
function testStringCoercion(value2) {
|
|
4400
|
-
return "" + value2;
|
|
4401
|
-
}
|
|
4402
|
-
function checkKeyStringCoercion(value2) {
|
|
4403
|
-
try {
|
|
4404
|
-
testStringCoercion(value2);
|
|
4405
|
-
var JSCompiler_inline_result = false;
|
|
4406
|
-
} catch (e) {
|
|
4407
|
-
JSCompiler_inline_result = true;
|
|
4408
|
-
}
|
|
4409
|
-
if (JSCompiler_inline_result) {
|
|
4410
|
-
JSCompiler_inline_result = console;
|
|
4411
|
-
var JSCompiler_temp_const = JSCompiler_inline_result.error;
|
|
4412
|
-
var JSCompiler_inline_result$jscomp$0 = "function" === typeof Symbol && Symbol.toStringTag && value2[Symbol.toStringTag] || value2.constructor.name || "Object";
|
|
4413
|
-
JSCompiler_temp_const.call(
|
|
4414
|
-
JSCompiler_inline_result,
|
|
4415
|
-
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
4416
|
-
JSCompiler_inline_result$jscomp$0
|
|
4417
|
-
);
|
|
4418
|
-
return testStringCoercion(value2);
|
|
4419
|
-
}
|
|
4420
|
-
}
|
|
4421
|
-
function getTaskName(type) {
|
|
4422
|
-
if (type === REACT_FRAGMENT_TYPE) return "<>";
|
|
4423
|
-
if ("object" === typeof type && null !== type && type.$$typeof === REACT_LAZY_TYPE)
|
|
4424
|
-
return "<...>";
|
|
4425
|
-
try {
|
|
4426
|
-
var name = getComponentNameFromType(type);
|
|
4427
|
-
return name ? "<" + name + ">" : "<...>";
|
|
4428
|
-
} catch (x) {
|
|
4429
|
-
return "<...>";
|
|
4430
|
-
}
|
|
4431
|
-
}
|
|
4432
|
-
function getOwner() {
|
|
4433
|
-
var dispatcher = ReactSharedInternals.A;
|
|
4434
|
-
return null === dispatcher ? null : dispatcher.getOwner();
|
|
4435
|
-
}
|
|
4436
|
-
function UnknownOwner() {
|
|
4437
|
-
return Error("react-stack-top-frame");
|
|
4438
|
-
}
|
|
4439
|
-
function hasValidKey(config) {
|
|
4440
|
-
if (hasOwnProperty.call(config, "key")) {
|
|
4441
|
-
var getter = Object.getOwnPropertyDescriptor(config, "key").get;
|
|
4442
|
-
if (getter && getter.isReactWarning) return false;
|
|
4443
|
-
}
|
|
4444
|
-
return void 0 !== config.key;
|
|
4445
|
-
}
|
|
4446
|
-
function defineKeyPropWarningGetter(props, displayName) {
|
|
4447
|
-
function warnAboutAccessingKey() {
|
|
4448
|
-
specialPropKeyWarningShown || (specialPropKeyWarningShown = true, console.error(
|
|
4449
|
-
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
4450
|
-
displayName
|
|
4451
|
-
));
|
|
4452
|
-
}
|
|
4453
|
-
warnAboutAccessingKey.isReactWarning = true;
|
|
4454
|
-
Object.defineProperty(props, "key", {
|
|
4455
|
-
get: warnAboutAccessingKey,
|
|
4456
|
-
configurable: true
|
|
4457
|
-
});
|
|
4458
|
-
}
|
|
4459
|
-
function elementRefGetterWithDeprecationWarning() {
|
|
4460
|
-
var componentName = getComponentNameFromType(this.type);
|
|
4461
|
-
didWarnAboutElementRef[componentName] || (didWarnAboutElementRef[componentName] = true, console.error(
|
|
4462
|
-
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
4463
|
-
));
|
|
4464
|
-
componentName = this.props.ref;
|
|
4465
|
-
return void 0 !== componentName ? componentName : null;
|
|
4466
|
-
}
|
|
4467
|
-
function ReactElement(type, key, props, owner, debugStack, debugTask) {
|
|
4468
|
-
var refProp = props.ref;
|
|
4469
|
-
type = {
|
|
4470
|
-
$$typeof: REACT_ELEMENT_TYPE,
|
|
4471
|
-
type,
|
|
4472
|
-
key,
|
|
4473
|
-
props,
|
|
4474
|
-
_owner: owner
|
|
4475
|
-
};
|
|
4476
|
-
null !== (void 0 !== refProp ? refProp : null) ? Object.defineProperty(type, "ref", {
|
|
4477
|
-
enumerable: false,
|
|
4478
|
-
get: elementRefGetterWithDeprecationWarning
|
|
4479
|
-
}) : Object.defineProperty(type, "ref", { enumerable: false, value: null });
|
|
4480
|
-
type._store = {};
|
|
4481
|
-
Object.defineProperty(type._store, "validated", {
|
|
4482
|
-
configurable: false,
|
|
4483
|
-
enumerable: false,
|
|
4484
|
-
writable: true,
|
|
4485
|
-
value: 0
|
|
4486
|
-
});
|
|
4487
|
-
Object.defineProperty(type, "_debugInfo", {
|
|
4488
|
-
configurable: false,
|
|
4489
|
-
enumerable: false,
|
|
4490
|
-
writable: true,
|
|
4491
|
-
value: null
|
|
4492
|
-
});
|
|
4493
|
-
Object.defineProperty(type, "_debugStack", {
|
|
4494
|
-
configurable: false,
|
|
4495
|
-
enumerable: false,
|
|
4496
|
-
writable: true,
|
|
4497
|
-
value: debugStack
|
|
4498
|
-
});
|
|
4499
|
-
Object.defineProperty(type, "_debugTask", {
|
|
4500
|
-
configurable: false,
|
|
4501
|
-
enumerable: false,
|
|
4502
|
-
writable: true,
|
|
4503
|
-
value: debugTask
|
|
4504
|
-
});
|
|
4505
|
-
Object.freeze && (Object.freeze(type.props), Object.freeze(type));
|
|
4506
|
-
return type;
|
|
4507
|
-
}
|
|
4508
|
-
function jsxDEVImpl(type, config, maybeKey, isStaticChildren, debugStack, debugTask) {
|
|
4509
|
-
var children = config.children;
|
|
4510
|
-
if (void 0 !== children)
|
|
4511
|
-
if (isStaticChildren)
|
|
4512
|
-
if (isArrayImpl(children)) {
|
|
4513
|
-
for (isStaticChildren = 0; isStaticChildren < children.length; isStaticChildren++)
|
|
4514
|
-
validateChildKeys(children[isStaticChildren]);
|
|
4515
|
-
Object.freeze && Object.freeze(children);
|
|
4516
|
-
} else
|
|
4517
|
-
console.error(
|
|
4518
|
-
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
4519
|
-
);
|
|
4520
|
-
else validateChildKeys(children);
|
|
4521
|
-
if (hasOwnProperty.call(config, "key")) {
|
|
4522
|
-
children = getComponentNameFromType(type);
|
|
4523
|
-
var keys = Object.keys(config).filter(function(k) {
|
|
4524
|
-
return "key" !== k;
|
|
4525
|
-
});
|
|
4526
|
-
isStaticChildren = 0 < keys.length ? "{key: someKey, " + keys.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
4527
|
-
didWarnAboutKeySpread[children + isStaticChildren] || (keys = 0 < keys.length ? "{" + keys.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
4528
|
-
'A props object containing a "key" prop is being spread into JSX:\n let props = %s;\n <%s {...props} />\nReact keys must be passed directly to JSX without using spread:\n let props = %s;\n <%s key={someKey} {...props} />',
|
|
4529
|
-
isStaticChildren,
|
|
4530
|
-
children,
|
|
4531
|
-
keys,
|
|
4532
|
-
children
|
|
4533
|
-
), didWarnAboutKeySpread[children + isStaticChildren] = true);
|
|
4534
|
-
}
|
|
4535
|
-
children = null;
|
|
4536
|
-
void 0 !== maybeKey && (checkKeyStringCoercion(maybeKey), children = "" + maybeKey);
|
|
4537
|
-
hasValidKey(config) && (checkKeyStringCoercion(config.key), children = "" + config.key);
|
|
4538
|
-
if ("key" in config) {
|
|
4539
|
-
maybeKey = {};
|
|
4540
|
-
for (var propName in config)
|
|
4541
|
-
"key" !== propName && (maybeKey[propName] = config[propName]);
|
|
4542
|
-
} else maybeKey = config;
|
|
4543
|
-
children && defineKeyPropWarningGetter(
|
|
4544
|
-
maybeKey,
|
|
4545
|
-
"function" === typeof type ? type.displayName || type.name || "Unknown" : type
|
|
4546
|
-
);
|
|
4547
|
-
return ReactElement(
|
|
4548
|
-
type,
|
|
4549
|
-
children,
|
|
4550
|
-
maybeKey,
|
|
4551
|
-
getOwner(),
|
|
4552
|
-
debugStack,
|
|
4553
|
-
debugTask
|
|
4554
|
-
);
|
|
4555
|
-
}
|
|
4556
|
-
function validateChildKeys(node2) {
|
|
4557
|
-
isValidElement(node2) ? node2._store && (node2._store.validated = 1) : "object" === typeof node2 && null !== node2 && node2.$$typeof === REACT_LAZY_TYPE && ("fulfilled" === node2._payload.status ? isValidElement(node2._payload.value) && node2._payload.value._store && (node2._payload.value._store.validated = 1) : node2._store && (node2._store.validated = 1));
|
|
4558
|
-
}
|
|
4559
|
-
function isValidElement(object) {
|
|
4560
|
-
return "object" === typeof object && null !== object && object.$$typeof === REACT_ELEMENT_TYPE;
|
|
4561
|
-
}
|
|
4562
|
-
var React = requireReact(), REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = Symbol.for("react.profiler"), REACT_CONSUMER_TYPE = Symbol.for("react.consumer"), REACT_CONTEXT_TYPE = Symbol.for("react.context"), REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"), REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"), REACT_MEMO_TYPE = Symbol.for("react.memo"), REACT_LAZY_TYPE = Symbol.for("react.lazy"), REACT_ACTIVITY_TYPE = Symbol.for("react.activity"), REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"), ReactSharedInternals = React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, hasOwnProperty = Object.prototype.hasOwnProperty, isArrayImpl = Array.isArray, createTask = console.createTask ? console.createTask : function() {
|
|
4563
|
-
return null;
|
|
4564
|
-
};
|
|
4565
|
-
React = {
|
|
4566
|
-
react_stack_bottom_frame: function(callStackForError) {
|
|
4567
|
-
return callStackForError();
|
|
4568
|
-
}
|
|
4569
|
-
};
|
|
4570
|
-
var specialPropKeyWarningShown;
|
|
4571
|
-
var didWarnAboutElementRef = {};
|
|
4572
|
-
var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(
|
|
4573
|
-
React,
|
|
4574
|
-
UnknownOwner
|
|
4575
|
-
)();
|
|
4576
|
-
var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));
|
|
4577
|
-
var didWarnAboutKeySpread = {};
|
|
4578
|
-
reactJsxRuntime_development.Fragment = REACT_FRAGMENT_TYPE;
|
|
4579
|
-
reactJsxRuntime_development.jsx = function(type, config, maybeKey) {
|
|
4580
|
-
var trackActualOwner = 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;
|
|
4581
|
-
return jsxDEVImpl(
|
|
4582
|
-
type,
|
|
4583
|
-
config,
|
|
4584
|
-
maybeKey,
|
|
4585
|
-
false,
|
|
4586
|
-
trackActualOwner ? Error("react-stack-top-frame") : unknownOwnerDebugStack,
|
|
4587
|
-
trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask
|
|
4588
|
-
);
|
|
4589
|
-
};
|
|
4590
|
-
reactJsxRuntime_development.jsxs = function(type, config, maybeKey) {
|
|
4591
|
-
var trackActualOwner = 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;
|
|
4592
|
-
return jsxDEVImpl(
|
|
4593
|
-
type,
|
|
4594
|
-
config,
|
|
4595
|
-
maybeKey,
|
|
4596
|
-
true,
|
|
4597
|
-
trackActualOwner ? Error("react-stack-top-frame") : unknownOwnerDebugStack,
|
|
4598
|
-
trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask
|
|
4599
|
-
);
|
|
4600
|
-
};
|
|
4601
|
-
})();
|
|
4602
|
-
return reactJsxRuntime_development;
|
|
4603
|
-
}
|
|
4604
|
-
var hasRequiredJsxRuntime;
|
|
4605
|
-
function requireJsxRuntime() {
|
|
4606
|
-
if (hasRequiredJsxRuntime) return jsxRuntime.exports;
|
|
4607
|
-
hasRequiredJsxRuntime = 1;
|
|
4608
|
-
if (process.env.NODE_ENV === "production") {
|
|
4609
|
-
jsxRuntime.exports = requireReactJsxRuntime_production();
|
|
4610
|
-
} else {
|
|
4611
|
-
jsxRuntime.exports = requireReactJsxRuntime_development();
|
|
4612
|
-
}
|
|
4613
|
-
return jsxRuntime.exports;
|
|
4614
|
-
}
|
|
4615
|
-
requireJsxRuntime();
|
|
4616
|
-
var reactExports = requireReact();
|
|
4617
2845
|
const DEFAULT_LANGUAGE = "ko";
|
|
4618
2846
|
function isLanguage(value2) {
|
|
4619
2847
|
return value2 === "ko" || value2 === "en" || value2 === "zh" || value2 === "ja";
|
|
@@ -6257,7 +4485,7 @@ const githubTriggersJa = {
|
|
|
6257
4485
|
"githubTriggers.templateLabel": "プロンプトテンプレート",
|
|
6258
4486
|
"githubTriggers.templateHint": "使用可能な変数: {pr.number} {pr.title} {pr.author} {pr.url} {pr.baseBranch} {pr.headBranch} {pr.labels} {event}",
|
|
6259
4487
|
"githubTriggers.presetReview": "「PR 自動レビュー」プリセットを挿入",
|
|
6260
|
-
"githubTriggers.presetReviewFix": "「PR レビュー +
|
|
4488
|
+
"githubTriggers.presetReviewFix": "「PR レビュー + フォローアップ修正」プリセットを挿入",
|
|
6261
4489
|
"githubTriggers.filterBaseBranch": "base ブランチ(完全一致、空欄で全て)",
|
|
6262
4490
|
"githubTriggers.filterLabel": "ラベル含む(空欄で全て)",
|
|
6263
4491
|
"githubTriggers.filterExcludeDrafts": "ドラフト PR を除外",
|
|
@@ -14580,14 +12808,6 @@ function translate(language, key, params) {
|
|
|
14580
12808
|
function translateCurrent(key, params) {
|
|
14581
12809
|
return translate(getCurrentLanguage(), key, params);
|
|
14582
12810
|
}
|
|
14583
|
-
const DEFAULT_CONTEXT = {
|
|
14584
|
-
language: DEFAULT_LANGUAGE,
|
|
14585
|
-
status: "ready",
|
|
14586
|
-
setLanguage: () => {
|
|
14587
|
-
},
|
|
14588
|
-
t: (key, params) => translate(DEFAULT_LANGUAGE, key, params)
|
|
14589
|
-
};
|
|
14590
|
-
reactExports.createContext(DEFAULT_CONTEXT);
|
|
14591
12811
|
function isAskUserQuestionToolName(value2) {
|
|
14592
12812
|
if (!value2) return false;
|
|
14593
12813
|
const normalized = value2.replace(/^functions\./i, "").replace(/^mcp__.+?__/i, "").replace(/\s+call$/i, "").replace(/[._\-\s]+/g, "").trim().toLowerCase();
|
|
@@ -16658,6 +14878,16 @@ class ApiClient {
|
|
|
16658
14878
|
);
|
|
16659
14879
|
}
|
|
16660
14880
|
}
|
|
14881
|
+
function consumeHiddenInput(current, chunk) {
|
|
14882
|
+
let value2 = current;
|
|
14883
|
+
for (const char of chunk) {
|
|
14884
|
+
if (char === "\n" || char === "\r" || char === "") return { type: "submit", value: value2 };
|
|
14885
|
+
if (char === "") return { type: "interrupt" };
|
|
14886
|
+
if (char === "") value2 = value2.slice(0, -1);
|
|
14887
|
+
else value2 += char;
|
|
14888
|
+
}
|
|
14889
|
+
return { type: "continue", value: value2 };
|
|
14890
|
+
}
|
|
16661
14891
|
const SECRETBOX_KEY_BYTES = 32;
|
|
16662
14892
|
function isNonEmptyString(value2) {
|
|
16663
14893
|
return typeof value2 === "string" && value2.length > 0;
|
|
@@ -16824,8 +15054,8 @@ function requireXMLHttpRequest() {
|
|
|
16824
15054
|
if (hasRequiredXMLHttpRequest) return XMLHttpRequest_1;
|
|
16825
15055
|
hasRequiredXMLHttpRequest = 1;
|
|
16826
15056
|
var fs = require$$0$1;
|
|
16827
|
-
var Url = require$$1
|
|
16828
|
-
var spawn = require$$2
|
|
15057
|
+
var Url = require$$1;
|
|
15058
|
+
var spawn = require$$2.spawn;
|
|
16829
15059
|
XMLHttpRequest_1 = XMLHttpRequest2;
|
|
16830
15060
|
XMLHttpRequest2.XMLHttpRequest = XMLHttpRequest2;
|
|
16831
15061
|
function XMLHttpRequest2(opts) {
|
|
@@ -18160,7 +16390,7 @@ function requireSupportsColor() {
|
|
|
18160
16390
|
if (hasRequiredSupportsColor) return supportsColor_1;
|
|
18161
16391
|
hasRequiredSupportsColor = 1;
|
|
18162
16392
|
const os = require$$0$2;
|
|
18163
|
-
const tty = require$$1$
|
|
16393
|
+
const tty = require$$1$1;
|
|
18164
16394
|
const hasFlag2 = requireHasFlag();
|
|
18165
16395
|
const { env } = process;
|
|
18166
16396
|
let forceColor;
|
|
@@ -18261,8 +16491,8 @@ function requireNode() {
|
|
|
18261
16491
|
if (hasRequiredNode) return node.exports;
|
|
18262
16492
|
hasRequiredNode = 1;
|
|
18263
16493
|
(function(module, exports) {
|
|
18264
|
-
const tty = require$$1$
|
|
18265
|
-
const util = require$$1$
|
|
16494
|
+
const tty = require$$1$1;
|
|
16495
|
+
const util = require$$1$2;
|
|
18266
16496
|
exports.init = init;
|
|
18267
16497
|
exports.log = log;
|
|
18268
16498
|
exports.formatArgs = formatArgs;
|
|
@@ -18964,7 +17194,6 @@ class XHR extends BaseXHR {
|
|
|
18964
17194
|
return new Request((opts2) => new XMLHttpRequest$1(opts2), this.uri(), opts);
|
|
18965
17195
|
}
|
|
18966
17196
|
}
|
|
18967
|
-
var bufferUtil = { exports: {} };
|
|
18968
17197
|
var constants;
|
|
18969
17198
|
var hasRequiredConstants;
|
|
18970
17199
|
function requireConstants() {
|
|
@@ -18988,15 +17217,10 @@ function requireConstants() {
|
|
|
18988
17217
|
};
|
|
18989
17218
|
return constants;
|
|
18990
17219
|
}
|
|
18991
|
-
|
|
18992
|
-
const __viteOptionalPeerDep_bufferutil_ws$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
18993
|
-
__proto__: null,
|
|
18994
|
-
default: __viteOptionalPeerDep_bufferutil_ws
|
|
18995
|
-
}, Symbol.toStringTag, { value: "Module" }));
|
|
18996
|
-
const require$$1 = /* @__PURE__ */ getAugmentedNamespace(__viteOptionalPeerDep_bufferutil_ws$1);
|
|
17220
|
+
var bufferUtil;
|
|
18997
17221
|
var hasRequiredBufferUtil;
|
|
18998
17222
|
function requireBufferUtil() {
|
|
18999
|
-
if (hasRequiredBufferUtil) return bufferUtil
|
|
17223
|
+
if (hasRequiredBufferUtil) return bufferUtil;
|
|
19000
17224
|
hasRequiredBufferUtil = 1;
|
|
19001
17225
|
const { EMPTY_BUFFER } = requireConstants();
|
|
19002
17226
|
const FastBuffer = Buffer[Symbol.species];
|
|
@@ -19045,28 +17269,14 @@ function requireBufferUtil() {
|
|
|
19045
17269
|
}
|
|
19046
17270
|
return buf;
|
|
19047
17271
|
}
|
|
19048
|
-
bufferUtil
|
|
17272
|
+
bufferUtil = {
|
|
19049
17273
|
concat,
|
|
19050
17274
|
mask: _mask,
|
|
19051
17275
|
toArrayBuffer,
|
|
19052
17276
|
toBuffer: toBuffer2,
|
|
19053
17277
|
unmask: _unmask
|
|
19054
17278
|
};
|
|
19055
|
-
|
|
19056
|
-
try {
|
|
19057
|
-
const bufferUtil$1 = require$$1;
|
|
19058
|
-
bufferUtil.exports.mask = function(source, mask, output, offset, length) {
|
|
19059
|
-
if (length < 48) _mask(source, mask, output, offset, length);
|
|
19060
|
-
else bufferUtil$1.mask(source, mask, output, offset, length);
|
|
19061
|
-
};
|
|
19062
|
-
bufferUtil.exports.unmask = function(buffer, mask) {
|
|
19063
|
-
if (buffer.length < 32) _unmask(buffer, mask);
|
|
19064
|
-
else bufferUtil$1.unmask(buffer, mask);
|
|
19065
|
-
};
|
|
19066
|
-
} catch (e) {
|
|
19067
|
-
}
|
|
19068
|
-
}
|
|
19069
|
-
return bufferUtil.exports;
|
|
17279
|
+
return bufferUtil;
|
|
19070
17280
|
}
|
|
19071
17281
|
var limiter;
|
|
19072
17282
|
var hasRequiredLimiter;
|
|
@@ -19502,12 +17712,6 @@ function requirePermessageDeflate() {
|
|
|
19502
17712
|
return permessageDeflate;
|
|
19503
17713
|
}
|
|
19504
17714
|
var validation = { exports: {} };
|
|
19505
|
-
const __viteOptionalPeerDep_utf8Validate_ws = {};
|
|
19506
|
-
const __viteOptionalPeerDep_utf8Validate_ws$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
19507
|
-
__proto__: null,
|
|
19508
|
-
default: __viteOptionalPeerDep_utf8Validate_ws
|
|
19509
|
-
}, Symbol.toStringTag, { value: "Module" }));
|
|
19510
|
-
const require$$2 = /* @__PURE__ */ getAugmentedNamespace(__viteOptionalPeerDep_utf8Validate_ws$1);
|
|
19511
17715
|
var hasRequiredValidation;
|
|
19512
17716
|
function requireValidation() {
|
|
19513
17717
|
if (hasRequiredValidation) return validation.exports;
|
|
@@ -19697,14 +17901,6 @@ function requireValidation() {
|
|
|
19697
17901
|
validation.exports.isValidUTF8 = function(buf) {
|
|
19698
17902
|
return buf.length < 24 ? _isValidUTF8(buf) : isUtf8(buf);
|
|
19699
17903
|
};
|
|
19700
|
-
} else if (!process.env.WS_NO_UTF_8_VALIDATE) {
|
|
19701
|
-
try {
|
|
19702
|
-
const isValidUTF8 = require$$2;
|
|
19703
|
-
validation.exports.isValidUTF8 = function(buf) {
|
|
19704
|
-
return buf.length < 32 ? _isValidUTF8(buf) : isValidUTF8(buf);
|
|
19705
|
-
};
|
|
19706
|
-
} catch (e) {
|
|
19707
|
-
}
|
|
19708
17904
|
}
|
|
19709
17905
|
return validation.exports;
|
|
19710
17906
|
}
|
|
@@ -20349,7 +18545,7 @@ function requireSender() {
|
|
|
20349
18545
|
const { randomFillSync } = require$$0;
|
|
20350
18546
|
const {
|
|
20351
18547
|
types: { isUint8Array }
|
|
20352
|
-
} = require$$1$
|
|
18548
|
+
} = require$$1$2;
|
|
20353
18549
|
const PerMessageDeflate = requirePermessageDeflate();
|
|
20354
18550
|
const { EMPTY_BUFFER, kWebSocket, NOOP } = requireConstants();
|
|
20355
18551
|
const { isBlob, isValidStatusCode } = requireValidation();
|
|
@@ -21227,7 +19423,7 @@ function requireWebsocket() {
|
|
|
21227
19423
|
const tls = require$$4$1;
|
|
21228
19424
|
const { randomBytes, createHash } = require$$0;
|
|
21229
19425
|
const { Duplex, Readable } = require$$0$5;
|
|
21230
|
-
const { URL: URL2 } = require$$1
|
|
19426
|
+
const { URL: URL2 } = require$$1;
|
|
21231
19427
|
const PerMessageDeflate = requirePermessageDeflate();
|
|
21232
19428
|
const Receiver = requireReceiver();
|
|
21233
19429
|
const Sender = requireSender();
|
|
@@ -25145,43 +23341,164 @@ Object.assign(lookup, {
|
|
|
25145
23341
|
io: lookup,
|
|
25146
23342
|
connect: lookup
|
|
25147
23343
|
});
|
|
25148
|
-
const
|
|
25149
|
-
const
|
|
25150
|
-
|
|
25151
|
-
|
|
23344
|
+
const CONNECT_ATTEMPTS = 3;
|
|
23345
|
+
const MAX_RETRY_DELAY_BUDGET_MS = 1e3;
|
|
23346
|
+
function connectSchedule(totalTimeoutMs) {
|
|
23347
|
+
const retryBudget = Math.min(MAX_RETRY_DELAY_BUDGET_MS, Math.max(0, Math.floor(totalTimeoutMs / 5)));
|
|
23348
|
+
const firstDelay = Math.floor(retryBudget / 4);
|
|
23349
|
+
return {
|
|
23350
|
+
attemptTimeoutMs: Math.max(1, Math.floor((totalTimeoutMs - retryBudget) / CONNECT_ATTEMPTS)),
|
|
23351
|
+
retryDelaysMs: [firstDelay, retryBudget - firstDelay]
|
|
23352
|
+
};
|
|
23353
|
+
}
|
|
23354
|
+
class RealtimeSocket {
|
|
23355
|
+
constructor(credential, serverUrl) {
|
|
25152
23356
|
this.credential = credential;
|
|
25153
23357
|
this.serverUrl = serverUrl;
|
|
25154
|
-
this.secretKey = decodeBase64(credential.secret);
|
|
25155
23358
|
this.socket = lookup(serverUrl, {
|
|
25156
23359
|
path: "/v1/updates",
|
|
25157
23360
|
auth: { token: credential.token, clientType: "user-scoped" },
|
|
25158
|
-
transports: ["websocket"]
|
|
23361
|
+
transports: ["websocket"],
|
|
23362
|
+
autoConnect: false,
|
|
23363
|
+
// Bound the initial handshake ourselves, then restore live reconnection.
|
|
23364
|
+
reconnection: false
|
|
25159
23365
|
});
|
|
25160
23366
|
}
|
|
25161
23367
|
socket;
|
|
25162
|
-
|
|
25163
|
-
|
|
25164
|
-
|
|
25165
|
-
|
|
25166
|
-
connect(
|
|
23368
|
+
connecting = null;
|
|
23369
|
+
cancelPendingConnect = null;
|
|
23370
|
+
connectedOnce = false;
|
|
23371
|
+
disposed = false;
|
|
23372
|
+
connect(totalTimeoutMs) {
|
|
25167
23373
|
if (this.socket.connected) return Promise.resolve();
|
|
25168
|
-
return new
|
|
25169
|
-
|
|
25170
|
-
|
|
23374
|
+
if (this.disposed) return Promise.reject(new Error("Realtime WebSocket transport was disposed."));
|
|
23375
|
+
if (this.connecting) return this.connecting;
|
|
23376
|
+
this.connecting = this.connectWithRetry(Math.max(1, totalTimeoutMs)).finally(() => {
|
|
23377
|
+
this.connecting = null;
|
|
23378
|
+
});
|
|
23379
|
+
return this.connecting;
|
|
23380
|
+
}
|
|
23381
|
+
async connectWithRetry(totalTimeoutMs) {
|
|
23382
|
+
if (this.connectedOnce) {
|
|
23383
|
+
this.socket.io.reconnection(false);
|
|
23384
|
+
this.socket.disconnect();
|
|
23385
|
+
}
|
|
23386
|
+
const schedule = connectSchedule(totalTimeoutMs);
|
|
23387
|
+
let lastError = null;
|
|
23388
|
+
for (let attempt = 0; attempt < CONNECT_ATTEMPTS; attempt += 1) {
|
|
23389
|
+
const result = await this.connectOnce(schedule.attemptTimeoutMs);
|
|
23390
|
+
if (result.type === "cancelled") throw this.cancelledError();
|
|
23391
|
+
if (result.type === "connected") {
|
|
23392
|
+
this.connectedOnce = true;
|
|
23393
|
+
this.socket.io.reconnection(true);
|
|
23394
|
+
return;
|
|
23395
|
+
}
|
|
23396
|
+
if (result.type === "error") lastError = result.error;
|
|
23397
|
+
this.socket.disconnect();
|
|
23398
|
+
const retryDelay = schedule.retryDelaysMs[attempt];
|
|
23399
|
+
if (retryDelay !== void 0 && retryDelay > 0 && !await this.waitForRetry(retryDelay)) {
|
|
23400
|
+
throw this.cancelledError();
|
|
23401
|
+
}
|
|
23402
|
+
}
|
|
23403
|
+
const cause = lastError ? ` Last error: ${this.safeErrorMessage(lastError)}` : "";
|
|
23404
|
+
throw new Error([
|
|
23405
|
+
`Realtime WebSocket /v1/updates at ${this.serverUrl} did not connect after ${CONNECT_ATTEMPTS} attempts within ${totalTimeoutMs}ms.`,
|
|
23406
|
+
`${cause} Retry the chat. If it keeps failing, check whether a VPN or proxy blocks WebSocket connections.`
|
|
23407
|
+
].join(""));
|
|
23408
|
+
}
|
|
23409
|
+
connectOnce(timeoutMs) {
|
|
23410
|
+
if (this.disposed) return Promise.resolve({ type: "cancelled" });
|
|
23411
|
+
return new Promise((resolve) => {
|
|
23412
|
+
let settled = false;
|
|
23413
|
+
let timer;
|
|
23414
|
+
const finish = (result) => {
|
|
23415
|
+
if (settled) return;
|
|
23416
|
+
settled = true;
|
|
25171
23417
|
clearTimeout(timer);
|
|
25172
|
-
|
|
25173
|
-
|
|
25174
|
-
|
|
23418
|
+
this.socket.off("connect", onConnect);
|
|
23419
|
+
this.socket.off("connect_error", onError);
|
|
23420
|
+
this.cancelPendingConnect = null;
|
|
23421
|
+
resolve(result);
|
|
23422
|
+
};
|
|
23423
|
+
const onConnect = () => finish({ type: "connected" });
|
|
23424
|
+
const onError = (error) => finish({ type: "error", error });
|
|
23425
|
+
timer = setTimeout(() => finish({ type: "timeout" }), timeoutMs);
|
|
23426
|
+
this.cancelPendingConnect = () => finish({ type: "cancelled" });
|
|
23427
|
+
this.socket.once("connect", onConnect);
|
|
23428
|
+
this.socket.once("connect_error", onError);
|
|
23429
|
+
this.socket.connect();
|
|
23430
|
+
});
|
|
23431
|
+
}
|
|
23432
|
+
waitForRetry(timeoutMs) {
|
|
23433
|
+
if (this.disposed) return Promise.resolve(false);
|
|
23434
|
+
return new Promise((resolve) => {
|
|
23435
|
+
let settled = false;
|
|
23436
|
+
const finish = (shouldContinue) => {
|
|
23437
|
+
if (settled) return;
|
|
23438
|
+
settled = true;
|
|
23439
|
+
clearTimeout(timer);
|
|
23440
|
+
this.cancelPendingConnect = null;
|
|
23441
|
+
resolve(shouldContinue);
|
|
23442
|
+
};
|
|
23443
|
+
const timer = setTimeout(() => finish(true), timeoutMs);
|
|
23444
|
+
this.cancelPendingConnect = () => finish(false);
|
|
23445
|
+
});
|
|
23446
|
+
}
|
|
23447
|
+
cancelledError() {
|
|
23448
|
+
return new Error("Realtime WebSocket connection was cancelled because the transport was disposed.");
|
|
23449
|
+
}
|
|
23450
|
+
safeErrorMessage(error) {
|
|
23451
|
+
return error.message.replaceAll(this.credential.token, "[redacted]").replaceAll(this.credential.secret, "[redacted]");
|
|
23452
|
+
}
|
|
23453
|
+
on(event, listener) {
|
|
23454
|
+
this.socket.on(event, listener);
|
|
23455
|
+
let active = true;
|
|
23456
|
+
return () => {
|
|
23457
|
+
if (!active) return;
|
|
23458
|
+
active = false;
|
|
23459
|
+
this.socket.off(event, listener);
|
|
23460
|
+
};
|
|
23461
|
+
}
|
|
23462
|
+
emitWithAck(event, payload, timeoutMs) {
|
|
23463
|
+
return new Promise((resolve, reject) => {
|
|
23464
|
+
const timer = setTimeout(() => reject(new Error(`Timed out waiting for ${event} acknowledgement`)), timeoutMs);
|
|
23465
|
+
this.socket.emit(event, payload, (response) => {
|
|
25175
23466
|
clearTimeout(timer);
|
|
25176
|
-
|
|
23467
|
+
resolve(response);
|
|
25177
23468
|
});
|
|
25178
23469
|
});
|
|
25179
23470
|
}
|
|
23471
|
+
dispose() {
|
|
23472
|
+
if (this.disposed) return;
|
|
23473
|
+
this.disposed = true;
|
|
23474
|
+
this.cancelPendingConnect?.();
|
|
23475
|
+
this.socket.removeAllListeners();
|
|
23476
|
+
this.socket.disconnect();
|
|
23477
|
+
}
|
|
23478
|
+
}
|
|
23479
|
+
const DEFAULT_SERVER_URL = "https://saycode.ai";
|
|
23480
|
+
const DEFAULT_ACK_TIMEOUT_MS = 15e3;
|
|
23481
|
+
const DEFAULT_CONNECT_TIMEOUT_MS = 15e3;
|
|
23482
|
+
class CliTransport {
|
|
23483
|
+
constructor(credential, serverUrl = DEFAULT_SERVER_URL) {
|
|
23484
|
+
this.credential = credential;
|
|
23485
|
+
this.serverUrl = serverUrl;
|
|
23486
|
+
this.secretKey = decodeBase64(credential.secret);
|
|
23487
|
+
this.realtime = new RealtimeSocket(credential, serverUrl);
|
|
23488
|
+
}
|
|
23489
|
+
realtime;
|
|
23490
|
+
secretKey;
|
|
23491
|
+
get key() {
|
|
23492
|
+
return this.secretKey;
|
|
23493
|
+
}
|
|
23494
|
+
connect(timeoutMs = DEFAULT_CONNECT_TIMEOUT_MS) {
|
|
23495
|
+
return this.realtime.connect(timeoutMs);
|
|
23496
|
+
}
|
|
25180
23497
|
onUpdate(listener) {
|
|
25181
|
-
this.
|
|
23498
|
+
return this.realtime.on("update", listener);
|
|
25182
23499
|
}
|
|
25183
23500
|
onEphemeral(listener) {
|
|
25184
|
-
this.
|
|
23501
|
+
return this.realtime.on("ephemeral", listener);
|
|
25185
23502
|
}
|
|
25186
23503
|
/**
|
|
25187
23504
|
* Encrypted RPC to a machine daemon or a live session, mirroring
|
|
@@ -25190,7 +23507,7 @@ class CliTransport {
|
|
|
25190
23507
|
*/
|
|
25191
23508
|
async rpc(target, method, params, ackTimeoutMs = DEFAULT_ACK_TIMEOUT_MS) {
|
|
25192
23509
|
const encrypted = this.secretKey ? encryptSecretBox(JSON.stringify(params), this.secretKey) : plainJsonToBase64(params);
|
|
25193
|
-
const response = await this.emitWithAck("rpc-call", {
|
|
23510
|
+
const response = await this.realtime.emitWithAck("rpc-call", {
|
|
25194
23511
|
method: `${target}:${method}`,
|
|
25195
23512
|
params: encrypted
|
|
25196
23513
|
}, ackTimeoutMs);
|
|
@@ -25204,18 +23521,8 @@ class CliTransport {
|
|
|
25204
23521
|
if (this.secretKey) return JSON.parse(decryptSecretBox(raw, this.secretKey));
|
|
25205
23522
|
return JSON.parse(Buffer.from(raw, "base64").toString("utf8"));
|
|
25206
23523
|
}
|
|
25207
|
-
emitWithAck(event, payload, timeoutMs) {
|
|
25208
|
-
return new Promise((resolve, reject) => {
|
|
25209
|
-
const timer = setTimeout(() => reject(new Error(`Timed out waiting for ${event} acknowledgement`)), timeoutMs);
|
|
25210
|
-
this.socket.emit(event, payload, (response) => {
|
|
25211
|
-
clearTimeout(timer);
|
|
25212
|
-
resolve(response);
|
|
25213
|
-
});
|
|
25214
|
-
});
|
|
25215
|
-
}
|
|
25216
23524
|
dispose() {
|
|
25217
|
-
this.
|
|
25218
|
-
this.socket.disconnect();
|
|
23525
|
+
this.realtime.dispose();
|
|
25219
23526
|
}
|
|
25220
23527
|
}
|
|
25221
23528
|
const REQUEST_TIMEOUT_MS = 2e4;
|
|
@@ -25456,8 +23763,8 @@ ${names}`);
|
|
|
25456
23763
|
}
|
|
25457
23764
|
this.activeSync = await this.resolver.resolve(this.activeWorkspace);
|
|
25458
23765
|
}
|
|
25459
|
-
createTransport() {
|
|
25460
|
-
return new CliTransport(
|
|
23766
|
+
createTransport(credential = this.activeSync) {
|
|
23767
|
+
return new CliTransport(credential, this.serverUrl);
|
|
25461
23768
|
}
|
|
25462
23769
|
}
|
|
25463
23770
|
function loadContext(env = process.env) {
|
|
@@ -25474,13 +23781,13 @@ function loadContext(env = process.env) {
|
|
|
25474
23781
|
}
|
|
25475
23782
|
return new CliContext(credential, serverUrlFromEnv(env), homeDir, out);
|
|
25476
23783
|
}
|
|
25477
|
-
async function withTransport(context, run) {
|
|
25478
|
-
const transport = context.createTransport();
|
|
23784
|
+
async function withTransport(context, run, providedTransport) {
|
|
23785
|
+
const transport = providedTransport ?? context.createTransport();
|
|
25479
23786
|
try {
|
|
25480
23787
|
await transport.connect();
|
|
25481
23788
|
return await run(transport);
|
|
25482
23789
|
} finally {
|
|
25483
|
-
transport.dispose();
|
|
23790
|
+
if (!providedTransport) transport.dispose();
|
|
25484
23791
|
}
|
|
25485
23792
|
}
|
|
25486
23793
|
function askHidden(question) {
|
|
@@ -25491,25 +23798,20 @@ function askHidden(question) {
|
|
|
25491
23798
|
if (stdin.isTTY) stdin.setRawMode(true);
|
|
25492
23799
|
let value2 = "";
|
|
25493
23800
|
const onData = (chunk) => {
|
|
25494
|
-
const
|
|
25495
|
-
if (
|
|
25496
|
-
|
|
25497
|
-
stdin.removeListener("data", onData);
|
|
25498
|
-
stdin.pause();
|
|
25499
|
-
process.stdout.write("\n");
|
|
25500
|
-
resolve(value2);
|
|
23801
|
+
const result = consumeHiddenInput(value2, chunk.toString("utf8"));
|
|
23802
|
+
if (result.type === "continue") {
|
|
23803
|
+
value2 = result.value;
|
|
25501
23804
|
return;
|
|
25502
23805
|
}
|
|
25503
|
-
if (
|
|
25504
|
-
|
|
25505
|
-
|
|
25506
|
-
|
|
25507
|
-
|
|
25508
|
-
|
|
25509
|
-
value2 = value2.slice(0, -1);
|
|
23806
|
+
if (stdin.isTTY) stdin.setRawMode(wasRaw);
|
|
23807
|
+
stdin.removeListener("data", onData);
|
|
23808
|
+
stdin.pause();
|
|
23809
|
+
process.stdout.write("\n");
|
|
23810
|
+
if (result.type === "submit") {
|
|
23811
|
+
resolve(result.value);
|
|
25510
23812
|
return;
|
|
25511
23813
|
}
|
|
25512
|
-
|
|
23814
|
+
process.exit(130);
|
|
25513
23815
|
};
|
|
25514
23816
|
stdin.resume();
|
|
25515
23817
|
stdin.on("data", onData);
|
|
@@ -25668,7 +23970,7 @@ async function prerollHistory(context, transport, sessionId, since) {
|
|
|
25668
23970
|
}
|
|
25669
23971
|
function followSession(input) {
|
|
25670
23972
|
let highestSeq = input.seenThroughSeq;
|
|
25671
|
-
input.transport.onUpdate((update) => {
|
|
23973
|
+
return input.transport.onUpdate((update) => {
|
|
25672
23974
|
input.onUpdate?.(update);
|
|
25673
23975
|
const message = readNewMessage(update, input.sessionId);
|
|
25674
23976
|
if (!message) return;
|
|
@@ -25751,6 +24053,7 @@ function isNewConversation(id) {
|
|
|
25751
24053
|
return id === NEW_CONVERSATION_ID;
|
|
25752
24054
|
}
|
|
25753
24055
|
function withNewConversationEntry(items, canCreate) {
|
|
24056
|
+
if (!canCreate) return [...items];
|
|
25754
24057
|
return [{ id: NEW_CONVERSATION_ID, label: "+ New conversation", detail: "" }, ...items];
|
|
25755
24058
|
}
|
|
25756
24059
|
const DEFAULT_RESUME_HISTORY = 20;
|
|
@@ -26105,7 +24408,7 @@ async function resolveSpawnTarget(context, options) {
|
|
|
26105
24408
|
}
|
|
26106
24409
|
return { machineId: await resolveMachineId(context, options.machine), directory: options.directory };
|
|
26107
24410
|
}
|
|
26108
|
-
async function runChat(context, options) {
|
|
24411
|
+
async function runChat(context, options, providedTransport) {
|
|
26109
24412
|
const resuming = !!options.sessionId;
|
|
26110
24413
|
const target = resuming ? null : await resolveSpawnTarget(context, options);
|
|
26111
24414
|
return withTransport(context, async (transport) => {
|
|
@@ -26122,7 +24425,7 @@ async function runChat(context, options) {
|
|
|
26122
24425
|
sessionId,
|
|
26123
24426
|
resumeHistoryCount({ resuming, ...options.since !== void 0 ? { since: options.since } : {} })
|
|
26124
24427
|
);
|
|
26125
|
-
followSession({
|
|
24428
|
+
const stopFollowing = followSession({
|
|
26126
24429
|
context,
|
|
26127
24430
|
transport,
|
|
26128
24431
|
sessionId,
|
|
@@ -26216,6 +24519,7 @@ Leaving. Reattach with \`saycode chat -s ${sessionId}\`.`);
|
|
|
26216
24519
|
}
|
|
26217
24520
|
}
|
|
26218
24521
|
} finally {
|
|
24522
|
+
stopFollowing();
|
|
26219
24523
|
process.off("SIGINT", onSigint);
|
|
26220
24524
|
rl.close();
|
|
26221
24525
|
}
|
|
@@ -26223,7 +24527,7 @@ Leaving. Reattach with \`saycode chat -s ${sessionId}\`.`);
|
|
|
26223
24527
|
Detached — the session keeps running. Reattach with \`saycode chat -s ${sessionId}\`.` : `
|
|
26224
24528
|
Leaving. Reattach with \`saycode chat -s ${sessionId}\`.`);
|
|
26225
24529
|
return outcome;
|
|
26226
|
-
});
|
|
24530
|
+
}, providedTransport);
|
|
26227
24531
|
}
|
|
26228
24532
|
const ESC = "\x1B";
|
|
26229
24533
|
const CTRL_C = "";
|
|
@@ -26408,7 +24712,7 @@ async function runWatch(context, options) {
|
|
|
26408
24712
|
const selectable = process.stdin.isTTY === true;
|
|
26409
24713
|
await withTransport(context, async (transport) => {
|
|
26410
24714
|
let activity = createActivityIndex();
|
|
26411
|
-
transport.onEphemeral((event) => {
|
|
24715
|
+
const stopActivity = transport.onEphemeral((event) => {
|
|
26412
24716
|
activity = applyActivity(activity, event);
|
|
26413
24717
|
});
|
|
26414
24718
|
let rows = [];
|
|
@@ -26453,11 +24757,12 @@ async function runWatch(context, options) {
|
|
|
26453
24757
|
wake = null;
|
|
26454
24758
|
}
|
|
26455
24759
|
} finally {
|
|
24760
|
+
stopActivity();
|
|
26456
24761
|
keyboard?.restore();
|
|
26457
24762
|
}
|
|
26458
24763
|
if (openSessionId) {
|
|
26459
24764
|
context.out.raw("\x1B[2J\x1B[H");
|
|
26460
|
-
await runChat(context, { sessionId: openSessionId, agent: "claude" });
|
|
24765
|
+
await runChat(context, { sessionId: openSessionId, agent: "claude" }, transport);
|
|
26461
24766
|
return;
|
|
26462
24767
|
}
|
|
26463
24768
|
context.out.raw("");
|
|
@@ -26552,6 +24857,30 @@ function applyAction(state, action) {
|
|
|
26552
24857
|
return state;
|
|
26553
24858
|
}
|
|
26554
24859
|
}
|
|
24860
|
+
function canCreateProjectConversation(project) {
|
|
24861
|
+
return Boolean(project?.detail?.trim());
|
|
24862
|
+
}
|
|
24863
|
+
class WorkspaceTransportOwner {
|
|
24864
|
+
constructor(create) {
|
|
24865
|
+
this.create = create;
|
|
24866
|
+
}
|
|
24867
|
+
current = null;
|
|
24868
|
+
disposed = false;
|
|
24869
|
+
get(credential) {
|
|
24870
|
+
if (this.disposed) throw new Error("Workspace transport owner was disposed.");
|
|
24871
|
+
if (this.current?.credential === credential) return this.current.transport;
|
|
24872
|
+
this.current?.transport.dispose();
|
|
24873
|
+
const transport = this.create(credential);
|
|
24874
|
+
this.current = { credential, transport };
|
|
24875
|
+
return transport;
|
|
24876
|
+
}
|
|
24877
|
+
dispose() {
|
|
24878
|
+
if (this.disposed) return;
|
|
24879
|
+
this.disposed = true;
|
|
24880
|
+
this.current?.transport.dispose();
|
|
24881
|
+
this.current = null;
|
|
24882
|
+
}
|
|
24883
|
+
}
|
|
26555
24884
|
const HEADER_LINES = 4;
|
|
26556
24885
|
function screenHeight() {
|
|
26557
24886
|
return Math.max(5, (process.stdout.rows ?? 24) - HEADER_LINES - 3);
|
|
@@ -26584,7 +24913,8 @@ async function loadLevel(context, state) {
|
|
|
26584
24913
|
label: row.summaryText ?? row.title ?? row.id,
|
|
26585
24914
|
detail: row.active ? "●" : "○"
|
|
26586
24915
|
}));
|
|
26587
|
-
|
|
24916
|
+
const project = state.selections.find((_, index) => state.levels[index] === "project");
|
|
24917
|
+
return withNewConversationEntry(rows, canCreateProjectConversation(project));
|
|
26588
24918
|
}
|
|
26589
24919
|
const machineId = selectedId(state, "machine");
|
|
26590
24920
|
const sessions = filterSessions(normalizeSessionRows(await context.rest.listSessions(), keys), {
|
|
@@ -26628,6 +24958,7 @@ async function runBrowse(context) {
|
|
|
26628
24958
|
}
|
|
26629
24959
|
let state = createBrowseState(levels);
|
|
26630
24960
|
const keyboard = startKeyboard(process.stdin);
|
|
24961
|
+
const transports2 = new WorkspaceTransportOwner((credential) => context.createTransport(credential));
|
|
26631
24962
|
const pending = [];
|
|
26632
24963
|
let wake = null;
|
|
26633
24964
|
keyboard.onKey((key) => {
|
|
@@ -26668,9 +24999,9 @@ async function runBrowse(context) {
|
|
|
26668
24999
|
try {
|
|
26669
25000
|
if (isNewConversation(chosen.id)) {
|
|
26670
25001
|
const projectId = selectedId(state, "project");
|
|
26671
|
-
await runChat(context, { project: projectId, agent: "claude" });
|
|
25002
|
+
await runChat(context, { project: projectId, agent: "claude" }, transports2.get(context.syncCredential));
|
|
26672
25003
|
} else {
|
|
26673
|
-
await runChat(context, { sessionId: chosen.id, agent: "claude" });
|
|
25004
|
+
await runChat(context, { sessionId: chosen.id, agent: "claude" }, transports2.get(context.syncCredential));
|
|
26674
25005
|
}
|
|
26675
25006
|
} catch (error) {
|
|
26676
25007
|
context.out.raw(`
|
|
@@ -26687,6 +25018,7 @@ Could not open that: ${error instanceof Error ? error.message : String(error)}`)
|
|
|
26687
25018
|
}
|
|
26688
25019
|
}
|
|
26689
25020
|
} finally {
|
|
25021
|
+
transports2.dispose();
|
|
26690
25022
|
keyboard.restore();
|
|
26691
25023
|
context.out.raw("");
|
|
26692
25024
|
}
|