@stellar/stellar-sdk 13.0.0-rc.2 → 13.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +112 -7
- package/README.md +1 -1
- package/dist/stellar-sdk-minimal.js +448 -77
- package/dist/stellar-sdk-minimal.min.js +1 -1
- package/dist/stellar-sdk-no-axios.js +1044 -234
- package/dist/stellar-sdk-no-axios.min.js +1 -1
- package/dist/stellar-sdk-no-eventsource.js +171 -148
- package/dist/stellar-sdk-no-eventsource.min.js +1 -1
- package/dist/stellar-sdk.js +767 -305
- package/dist/stellar-sdk.min.js +1 -1
- package/lib/friendbot/index.d.ts +1 -0
- package/lib/horizon/call_builder.d.ts +1 -1
- package/lib/horizon/horizon_api.d.ts +13 -0
- package/lib/horizon/horizon_axios_client.js +1 -1
- package/lib/horizon/server.d.ts +5 -0
- package/lib/horizon/server.js +80 -59
- package/lib/minimal/friendbot/index.d.ts +1 -0
- package/lib/minimal/horizon/call_builder.d.ts +1 -1
- package/lib/minimal/horizon/horizon_api.d.ts +13 -0
- package/lib/minimal/horizon/horizon_axios_client.js +1 -1
- package/lib/minimal/horizon/server.d.ts +5 -0
- package/lib/minimal/horizon/server.js +80 -59
- package/lib/minimal/rpc/api.d.ts +2 -1
- package/lib/minimal/rpc/axios.js +1 -1
- package/lib/minimal/rpc/parsers.js +1 -0
- package/lib/minimal/rpc/server.js +27 -8
- package/lib/no-axios/friendbot/index.d.ts +1 -0
- package/lib/no-axios/horizon/call_builder.d.ts +1 -1
- package/lib/no-axios/horizon/horizon_api.d.ts +13 -0
- package/lib/no-axios/horizon/horizon_axios_client.js +1 -1
- package/lib/no-axios/horizon/server.d.ts +5 -0
- package/lib/no-axios/horizon/server.js +80 -59
- package/lib/no-axios/rpc/api.d.ts +2 -1
- package/lib/no-axios/rpc/axios.js +1 -1
- package/lib/no-axios/rpc/parsers.js +1 -0
- package/lib/no-axios/rpc/server.js +27 -8
- package/lib/no-eventsource/friendbot/index.d.ts +1 -0
- package/lib/no-eventsource/horizon/call_builder.d.ts +1 -1
- package/lib/no-eventsource/horizon/horizon_api.d.ts +13 -0
- package/lib/no-eventsource/horizon/horizon_axios_client.js +1 -1
- package/lib/no-eventsource/horizon/server.d.ts +5 -0
- package/lib/no-eventsource/horizon/server.js +80 -59
- package/lib/no-eventsource/rpc/api.d.ts +2 -1
- package/lib/no-eventsource/rpc/axios.js +1 -1
- package/lib/no-eventsource/rpc/parsers.js +1 -0
- package/lib/no-eventsource/rpc/server.js +27 -8
- package/lib/rpc/api.d.ts +2 -1
- package/lib/rpc/axios.js +1 -1
- package/lib/rpc/parsers.js +1 -0
- package/lib/rpc/server.js +27 -8
- package/package.json +11 -11
|
@@ -11063,6 +11063,12 @@ exports.walkInvocationTree = walkInvocationTree;
|
|
|
11063
11063
|
var _asset = __webpack_require__(1764);
|
|
11064
11064
|
var _address = __webpack_require__(1180);
|
|
11065
11065
|
var _scval = __webpack_require__(7177);
|
|
11066
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
11067
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
11068
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
11069
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
11070
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
11071
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
11066
11072
|
/**
|
|
11067
11073
|
* @typedef CreateInvocation
|
|
11068
11074
|
*
|
|
@@ -11076,6 +11082,9 @@ var _scval = __webpack_require__(7177);
|
|
|
11076
11082
|
* @prop {string} wasm.address contract address of this deployment
|
|
11077
11083
|
* @prop {string} wasm.salt hex salt that the user consumed when creating
|
|
11078
11084
|
* this contract (encoded in the resulting address)
|
|
11085
|
+
* @prop {any[]} [wasm.constructorArgs] a list of natively-represented values
|
|
11086
|
+
* (see {@link scValToNative}) that are passed to the constructor when
|
|
11087
|
+
* creating this contract
|
|
11079
11088
|
*/
|
|
11080
11089
|
|
|
11081
11090
|
/**
|
|
@@ -11084,8 +11093,8 @@ var _scval = __webpack_require__(7177);
|
|
|
11084
11093
|
* @prop {string} source the strkey of the contract (C...) being invoked
|
|
11085
11094
|
* @prop {string} function the name of the function being invoked
|
|
11086
11095
|
* @prop {any[]} args the natively-represented parameters to the function
|
|
11087
|
-
* invocation (see {@link scValToNative}
|
|
11088
|
-
* represented a JS types
|
|
11096
|
+
* invocation (see {@link scValToNative} for rules on how they're
|
|
11097
|
+
* represented a JS types)
|
|
11089
11098
|
*/
|
|
11090
11099
|
|
|
11091
11100
|
/**
|
|
@@ -11146,7 +11155,7 @@ function buildInvocationTree(root) {
|
|
|
11146
11155
|
/** @type {InvocationTree} */
|
|
11147
11156
|
var output = {};
|
|
11148
11157
|
|
|
11149
|
-
/** @type {xdr.CreateContractArgs
|
|
11158
|
+
/** @type {xdr.CreateContractArgs|xdr.CreateContractArgsV2|xdr.InvokeContractArgs} */
|
|
11150
11159
|
var inner = fn.value();
|
|
11151
11160
|
switch (fn["switch"]().value) {
|
|
11152
11161
|
// sorobanAuthorizedFunctionTypeContractFn
|
|
@@ -11162,8 +11171,11 @@ function buildInvocationTree(root) {
|
|
|
11162
11171
|
break;
|
|
11163
11172
|
|
|
11164
11173
|
// sorobanAuthorizedFunctionTypeCreateContractHostFn
|
|
11165
|
-
|
|
11174
|
+
// sorobanAuthorizedFunctionTypeCreateContractV2HostFn
|
|
11175
|
+
case 1: // fallthrough: just no ctor args in V1
|
|
11176
|
+
case 2:
|
|
11166
11177
|
{
|
|
11178
|
+
var createV2 = fn["switch"]().value === 2;
|
|
11167
11179
|
output.type = 'create';
|
|
11168
11180
|
output.args = {};
|
|
11169
11181
|
|
|
@@ -11187,11 +11199,15 @@ function buildInvocationTree(root) {
|
|
|
11187
11199
|
/** @type {xdr.ContractIdPreimageFromAddress} */
|
|
11188
11200
|
var details = preimage.fromAddress();
|
|
11189
11201
|
output.args.type = 'wasm';
|
|
11190
|
-
output.args.wasm = {
|
|
11202
|
+
output.args.wasm = _objectSpread({
|
|
11191
11203
|
salt: details.salt().toString('hex'),
|
|
11192
11204
|
hash: exec.wasmHash().toString('hex'),
|
|
11193
11205
|
address: _address.Address.fromScAddress(details.address()).toString()
|
|
11194
|
-
}
|
|
11206
|
+
}, createV2 && {
|
|
11207
|
+
constructorArgs: inner.constructorArgs().map(function (arg) {
|
|
11208
|
+
return (0, _scval.scValToNative)(arg);
|
|
11209
|
+
})
|
|
11210
|
+
});
|
|
11195
11211
|
break;
|
|
11196
11212
|
}
|
|
11197
11213
|
|
|
@@ -27714,7 +27730,7 @@ var http_client = __webpack_require__(6371);
|
|
|
27714
27730
|
function horizon_axios_client_typeof(o) { "@babel/helpers - typeof"; return horizon_axios_client_typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, horizon_axios_client_typeof(o); }
|
|
27715
27731
|
|
|
27716
27732
|
|
|
27717
|
-
var version = "13.
|
|
27733
|
+
var version = "13.1.0";
|
|
27718
27734
|
var SERVER_TIME_MAP = {};
|
|
27719
27735
|
var AxiosClient = (0,http_client/* create */.vt)({
|
|
27720
27736
|
headers: {
|
|
@@ -29100,28 +29116,49 @@ var HorizonServer = function () {
|
|
|
29100
29116
|
}
|
|
29101
29117
|
return feeStats;
|
|
29102
29118
|
}())
|
|
29119
|
+
}, {
|
|
29120
|
+
key: "root",
|
|
29121
|
+
value: (function () {
|
|
29122
|
+
var _root = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee4() {
|
|
29123
|
+
var cb;
|
|
29124
|
+
return server_regeneratorRuntime().wrap(function _callee4$(_context4) {
|
|
29125
|
+
while (1) switch (_context4.prev = _context4.next) {
|
|
29126
|
+
case 0:
|
|
29127
|
+
cb = new CallBuilder(URI_default()(this.serverURL));
|
|
29128
|
+
return _context4.abrupt("return", cb.call());
|
|
29129
|
+
case 2:
|
|
29130
|
+
case "end":
|
|
29131
|
+
return _context4.stop();
|
|
29132
|
+
}
|
|
29133
|
+
}, _callee4, this);
|
|
29134
|
+
}));
|
|
29135
|
+
function root() {
|
|
29136
|
+
return _root.apply(this, arguments);
|
|
29137
|
+
}
|
|
29138
|
+
return root;
|
|
29139
|
+
}())
|
|
29103
29140
|
}, {
|
|
29104
29141
|
key: "submitTransaction",
|
|
29105
29142
|
value: (function () {
|
|
29106
|
-
var _submitTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29143
|
+
var _submitTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee5(transaction) {
|
|
29107
29144
|
var opts,
|
|
29108
29145
|
tx,
|
|
29109
|
-
|
|
29110
|
-
return server_regeneratorRuntime().wrap(function
|
|
29111
|
-
while (1) switch (
|
|
29146
|
+
_args5 = arguments;
|
|
29147
|
+
return server_regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
29148
|
+
while (1) switch (_context5.prev = _context5.next) {
|
|
29112
29149
|
case 0:
|
|
29113
|
-
opts =
|
|
29150
|
+
opts = _args5.length > 1 && _args5[1] !== undefined ? _args5[1] : {
|
|
29114
29151
|
skipMemoRequiredCheck: false
|
|
29115
29152
|
};
|
|
29116
29153
|
if (opts.skipMemoRequiredCheck) {
|
|
29117
|
-
|
|
29154
|
+
_context5.next = 4;
|
|
29118
29155
|
break;
|
|
29119
29156
|
}
|
|
29120
|
-
|
|
29157
|
+
_context5.next = 4;
|
|
29121
29158
|
return this.checkMemoRequired(transaction);
|
|
29122
29159
|
case 4:
|
|
29123
29160
|
tx = encodeURIComponent(transaction.toEnvelope().toXDR().toString("base64"));
|
|
29124
|
-
return
|
|
29161
|
+
return _context5.abrupt("return", horizon_axios_client.post(URI_default()(this.serverURL).segment("transactions").toString(), "tx=".concat(tx), {
|
|
29125
29162
|
timeout: SUBMIT_TRANSACTION_TIMEOUT
|
|
29126
29163
|
}).then(function (response) {
|
|
29127
29164
|
if (!response.data.result_xdr) {
|
|
@@ -29232,9 +29269,9 @@ var HorizonServer = function () {
|
|
|
29232
29269
|
}));
|
|
29233
29270
|
case 6:
|
|
29234
29271
|
case "end":
|
|
29235
|
-
return
|
|
29272
|
+
return _context5.stop();
|
|
29236
29273
|
}
|
|
29237
|
-
},
|
|
29274
|
+
}, _callee5, this);
|
|
29238
29275
|
}));
|
|
29239
29276
|
function submitTransaction(_x2) {
|
|
29240
29277
|
return _submitTransaction.apply(this, arguments);
|
|
@@ -29244,25 +29281,25 @@ var HorizonServer = function () {
|
|
|
29244
29281
|
}, {
|
|
29245
29282
|
key: "submitAsyncTransaction",
|
|
29246
29283
|
value: (function () {
|
|
29247
|
-
var _submitAsyncTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29284
|
+
var _submitAsyncTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee6(transaction) {
|
|
29248
29285
|
var opts,
|
|
29249
29286
|
tx,
|
|
29250
|
-
|
|
29251
|
-
return server_regeneratorRuntime().wrap(function
|
|
29252
|
-
while (1) switch (
|
|
29287
|
+
_args6 = arguments;
|
|
29288
|
+
return server_regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
29289
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
29253
29290
|
case 0:
|
|
29254
|
-
opts =
|
|
29291
|
+
opts = _args6.length > 1 && _args6[1] !== undefined ? _args6[1] : {
|
|
29255
29292
|
skipMemoRequiredCheck: false
|
|
29256
29293
|
};
|
|
29257
29294
|
if (opts.skipMemoRequiredCheck) {
|
|
29258
|
-
|
|
29295
|
+
_context6.next = 4;
|
|
29259
29296
|
break;
|
|
29260
29297
|
}
|
|
29261
|
-
|
|
29298
|
+
_context6.next = 4;
|
|
29262
29299
|
return this.checkMemoRequired(transaction);
|
|
29263
29300
|
case 4:
|
|
29264
29301
|
tx = encodeURIComponent(transaction.toEnvelope().toXDR().toString("base64"));
|
|
29265
|
-
return
|
|
29302
|
+
return _context6.abrupt("return", horizon_axios_client.post(URI_default()(this.serverURL).segment("transactions_async").toString(), "tx=".concat(tx)).then(function (response) {
|
|
29266
29303
|
return response.data;
|
|
29267
29304
|
}).catch(function (response) {
|
|
29268
29305
|
if (response instanceof Error) {
|
|
@@ -29272,9 +29309,9 @@ var HorizonServer = function () {
|
|
|
29272
29309
|
}));
|
|
29273
29310
|
case 6:
|
|
29274
29311
|
case "end":
|
|
29275
|
-
return
|
|
29312
|
+
return _context6.stop();
|
|
29276
29313
|
}
|
|
29277
|
-
},
|
|
29314
|
+
}, _callee6, this);
|
|
29278
29315
|
}));
|
|
29279
29316
|
function submitAsyncTransaction(_x3) {
|
|
29280
29317
|
return _submitAsyncTransaction.apply(this, arguments);
|
|
@@ -29359,21 +29396,21 @@ var HorizonServer = function () {
|
|
|
29359
29396
|
}, {
|
|
29360
29397
|
key: "loadAccount",
|
|
29361
29398
|
value: (function () {
|
|
29362
|
-
var _loadAccount = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29399
|
+
var _loadAccount = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee7(accountId) {
|
|
29363
29400
|
var res;
|
|
29364
|
-
return server_regeneratorRuntime().wrap(function
|
|
29365
|
-
while (1) switch (
|
|
29401
|
+
return server_regeneratorRuntime().wrap(function _callee7$(_context7) {
|
|
29402
|
+
while (1) switch (_context7.prev = _context7.next) {
|
|
29366
29403
|
case 0:
|
|
29367
|
-
|
|
29404
|
+
_context7.next = 2;
|
|
29368
29405
|
return this.accounts().accountId(accountId).call();
|
|
29369
29406
|
case 2:
|
|
29370
|
-
res =
|
|
29371
|
-
return
|
|
29407
|
+
res = _context7.sent;
|
|
29408
|
+
return _context7.abrupt("return", new AccountResponse(res));
|
|
29372
29409
|
case 4:
|
|
29373
29410
|
case "end":
|
|
29374
|
-
return
|
|
29411
|
+
return _context7.stop();
|
|
29375
29412
|
}
|
|
29376
|
-
},
|
|
29413
|
+
}, _callee7, this);
|
|
29377
29414
|
}));
|
|
29378
29415
|
function loadAccount(_x4) {
|
|
29379
29416
|
return _loadAccount.apply(this, arguments);
|
|
@@ -29388,88 +29425,88 @@ var HorizonServer = function () {
|
|
|
29388
29425
|
}, {
|
|
29389
29426
|
key: "checkMemoRequired",
|
|
29390
29427
|
value: (function () {
|
|
29391
|
-
var _checkMemoRequired = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29428
|
+
var _checkMemoRequired = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee8(transaction) {
|
|
29392
29429
|
var destinations, i, operation, destination, account;
|
|
29393
|
-
return server_regeneratorRuntime().wrap(function
|
|
29394
|
-
while (1) switch (
|
|
29430
|
+
return server_regeneratorRuntime().wrap(function _callee8$(_context8) {
|
|
29431
|
+
while (1) switch (_context8.prev = _context8.next) {
|
|
29395
29432
|
case 0:
|
|
29396
29433
|
if (transaction instanceof lib.FeeBumpTransaction) {
|
|
29397
29434
|
transaction = transaction.innerTransaction;
|
|
29398
29435
|
}
|
|
29399
29436
|
if (!(transaction.memo.type !== "none")) {
|
|
29400
|
-
|
|
29437
|
+
_context8.next = 3;
|
|
29401
29438
|
break;
|
|
29402
29439
|
}
|
|
29403
|
-
return
|
|
29440
|
+
return _context8.abrupt("return");
|
|
29404
29441
|
case 3:
|
|
29405
29442
|
destinations = new Set();
|
|
29406
29443
|
i = 0;
|
|
29407
29444
|
case 5:
|
|
29408
29445
|
if (!(i < transaction.operations.length)) {
|
|
29409
|
-
|
|
29446
|
+
_context8.next = 36;
|
|
29410
29447
|
break;
|
|
29411
29448
|
}
|
|
29412
29449
|
operation = transaction.operations[i];
|
|
29413
|
-
|
|
29414
|
-
|
|
29450
|
+
_context8.t0 = operation.type;
|
|
29451
|
+
_context8.next = _context8.t0 === "payment" ? 10 : _context8.t0 === "pathPaymentStrictReceive" ? 10 : _context8.t0 === "pathPaymentStrictSend" ? 10 : _context8.t0 === "accountMerge" ? 10 : 11;
|
|
29415
29452
|
break;
|
|
29416
29453
|
case 10:
|
|
29417
|
-
return
|
|
29454
|
+
return _context8.abrupt("break", 12);
|
|
29418
29455
|
case 11:
|
|
29419
|
-
return
|
|
29456
|
+
return _context8.abrupt("continue", 33);
|
|
29420
29457
|
case 12:
|
|
29421
29458
|
destination = operation.destination;
|
|
29422
29459
|
if (!destinations.has(destination)) {
|
|
29423
|
-
|
|
29460
|
+
_context8.next = 15;
|
|
29424
29461
|
break;
|
|
29425
29462
|
}
|
|
29426
|
-
return
|
|
29463
|
+
return _context8.abrupt("continue", 33);
|
|
29427
29464
|
case 15:
|
|
29428
29465
|
destinations.add(destination);
|
|
29429
29466
|
if (!destination.startsWith("M")) {
|
|
29430
|
-
|
|
29467
|
+
_context8.next = 18;
|
|
29431
29468
|
break;
|
|
29432
29469
|
}
|
|
29433
|
-
return
|
|
29470
|
+
return _context8.abrupt("continue", 33);
|
|
29434
29471
|
case 18:
|
|
29435
|
-
|
|
29436
|
-
|
|
29472
|
+
_context8.prev = 18;
|
|
29473
|
+
_context8.next = 21;
|
|
29437
29474
|
return this.loadAccount(destination);
|
|
29438
29475
|
case 21:
|
|
29439
|
-
account =
|
|
29476
|
+
account = _context8.sent;
|
|
29440
29477
|
if (!(account.data_attr["config.memo_required"] === ACCOUNT_REQUIRES_MEMO)) {
|
|
29441
|
-
|
|
29478
|
+
_context8.next = 24;
|
|
29442
29479
|
break;
|
|
29443
29480
|
}
|
|
29444
29481
|
throw new errors/* AccountRequiresMemoError */.Cu("account requires memo", destination, i);
|
|
29445
29482
|
case 24:
|
|
29446
|
-
|
|
29483
|
+
_context8.next = 33;
|
|
29447
29484
|
break;
|
|
29448
29485
|
case 26:
|
|
29449
|
-
|
|
29450
|
-
|
|
29451
|
-
if (!(
|
|
29452
|
-
|
|
29486
|
+
_context8.prev = 26;
|
|
29487
|
+
_context8.t1 = _context8["catch"](18);
|
|
29488
|
+
if (!(_context8.t1 instanceof errors/* AccountRequiresMemoError */.Cu)) {
|
|
29489
|
+
_context8.next = 30;
|
|
29453
29490
|
break;
|
|
29454
29491
|
}
|
|
29455
|
-
throw
|
|
29492
|
+
throw _context8.t1;
|
|
29456
29493
|
case 30:
|
|
29457
|
-
if (
|
|
29458
|
-
|
|
29494
|
+
if (_context8.t1 instanceof errors/* NotFoundError */.m_) {
|
|
29495
|
+
_context8.next = 32;
|
|
29459
29496
|
break;
|
|
29460
29497
|
}
|
|
29461
|
-
throw
|
|
29498
|
+
throw _context8.t1;
|
|
29462
29499
|
case 32:
|
|
29463
|
-
return
|
|
29500
|
+
return _context8.abrupt("continue", 33);
|
|
29464
29501
|
case 33:
|
|
29465
29502
|
i += 1;
|
|
29466
|
-
|
|
29503
|
+
_context8.next = 5;
|
|
29467
29504
|
break;
|
|
29468
29505
|
case 36:
|
|
29469
29506
|
case "end":
|
|
29470
|
-
return
|
|
29507
|
+
return _context8.stop();
|
|
29471
29508
|
}
|
|
29472
|
-
},
|
|
29509
|
+
}, _callee8, this, [[18, 26]]);
|
|
29473
29510
|
}));
|
|
29474
29511
|
function checkMemoRequired(_x5) {
|
|
29475
29512
|
return _checkMemoRequired.apply(this, arguments);
|
|
@@ -29503,7 +29540,321 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
29503
29540
|
});
|
|
29504
29541
|
|
|
29505
29542
|
;// ./node_modules/feaxios/dist/index.mjs
|
|
29506
|
-
|
|
29543
|
+
// src/client.ts
|
|
29544
|
+
async function prepareAxiosResponse(options, res) {
|
|
29545
|
+
const response = { config: options };
|
|
29546
|
+
response.status = res.status;
|
|
29547
|
+
response.statusText = res.statusText;
|
|
29548
|
+
response.headers = res.headers;
|
|
29549
|
+
if (options.responseType === "stream") {
|
|
29550
|
+
response.data = res.body;
|
|
29551
|
+
return response;
|
|
29552
|
+
}
|
|
29553
|
+
return res[options.responseType || "text"]().then((data) => {
|
|
29554
|
+
if (options.transformResponse) {
|
|
29555
|
+
Array.isArray(options.transformResponse) ? options.transformResponse.map(
|
|
29556
|
+
(fn) => data = fn.call(options, data, res?.headers, res?.status)
|
|
29557
|
+
) : data = options.transformResponse(data, res?.headers, res?.status);
|
|
29558
|
+
response.data = data;
|
|
29559
|
+
} else {
|
|
29560
|
+
response.data = data;
|
|
29561
|
+
response.data = JSON.parse(data);
|
|
29562
|
+
}
|
|
29563
|
+
}).catch(Object).then(() => response);
|
|
29564
|
+
}
|
|
29565
|
+
async function handleFetch(options, fetchOptions) {
|
|
29566
|
+
let res = null;
|
|
29567
|
+
if ("any" in AbortSignal) {
|
|
29568
|
+
const signals = [];
|
|
29569
|
+
if (options.timeout) {
|
|
29570
|
+
signals.push(AbortSignal.timeout(options.timeout));
|
|
29571
|
+
}
|
|
29572
|
+
if (options.signal) {
|
|
29573
|
+
signals.push(options.signal);
|
|
29574
|
+
}
|
|
29575
|
+
if (signals.length > 0) {
|
|
29576
|
+
fetchOptions.signal = AbortSignal.any(signals);
|
|
29577
|
+
}
|
|
29578
|
+
} else {
|
|
29579
|
+
if (options.timeout) {
|
|
29580
|
+
fetchOptions.signal = AbortSignal.timeout(options.timeout);
|
|
29581
|
+
}
|
|
29582
|
+
}
|
|
29583
|
+
try {
|
|
29584
|
+
res = await fetch(options.url, fetchOptions);
|
|
29585
|
+
const ok = options.validateStatus ? options.validateStatus(res.status) : res.ok;
|
|
29586
|
+
if (!ok) {
|
|
29587
|
+
return Promise.reject(
|
|
29588
|
+
new AxiosError(
|
|
29589
|
+
`Request failed with status code ${res?.status}`,
|
|
29590
|
+
[AxiosError.ERR_BAD_REQUEST, AxiosError.ERR_BAD_RESPONSE][Math.floor(res?.status / 100) - 4],
|
|
29591
|
+
options,
|
|
29592
|
+
new Request(options.url, fetchOptions),
|
|
29593
|
+
await prepareAxiosResponse(options, res)
|
|
29594
|
+
)
|
|
29595
|
+
);
|
|
29596
|
+
}
|
|
29597
|
+
return await prepareAxiosResponse(options, res);
|
|
29598
|
+
} catch (error) {
|
|
29599
|
+
if (error.name === "AbortError" || error.name === "TimeoutError") {
|
|
29600
|
+
const isTimeoutError = error.name === "TimeoutError";
|
|
29601
|
+
return Promise.reject(
|
|
29602
|
+
isTimeoutError ? new AxiosError(
|
|
29603
|
+
options.timeoutErrorMessage || `timeout of ${options.timeout} ms exceeded`,
|
|
29604
|
+
AxiosError.ECONNABORTED,
|
|
29605
|
+
options,
|
|
29606
|
+
request
|
|
29607
|
+
) : new CanceledError(null, options)
|
|
29608
|
+
);
|
|
29609
|
+
}
|
|
29610
|
+
return Promise.reject(
|
|
29611
|
+
new AxiosError(
|
|
29612
|
+
error.message,
|
|
29613
|
+
void 0,
|
|
29614
|
+
options,
|
|
29615
|
+
request,
|
|
29616
|
+
void 0
|
|
29617
|
+
)
|
|
29618
|
+
);
|
|
29619
|
+
}
|
|
29620
|
+
}
|
|
29621
|
+
function buildURL(options) {
|
|
29622
|
+
let url = options.url || "";
|
|
29623
|
+
if (options.baseURL && options.url) {
|
|
29624
|
+
url = options.url.replace(/^(?!.*\/\/)\/?/, `${options.baseURL}/`);
|
|
29625
|
+
}
|
|
29626
|
+
if (options.params && Object.keys(options.params).length > 0 && options.url) {
|
|
29627
|
+
url += (~options.url.indexOf("?") ? "&" : "?") + (options.paramsSerializer ? options.paramsSerializer(options.params) : new URLSearchParams(options.params));
|
|
29628
|
+
}
|
|
29629
|
+
return url;
|
|
29630
|
+
}
|
|
29631
|
+
function mergeAxiosOptions(input, defaults) {
|
|
29632
|
+
const merged = {
|
|
29633
|
+
...defaults,
|
|
29634
|
+
...input
|
|
29635
|
+
};
|
|
29636
|
+
if (defaults?.params && input?.params) {
|
|
29637
|
+
merged.params = {
|
|
29638
|
+
...defaults?.params,
|
|
29639
|
+
...input?.params
|
|
29640
|
+
};
|
|
29641
|
+
}
|
|
29642
|
+
if (defaults?.headers && input?.headers) {
|
|
29643
|
+
merged.headers = new Headers(defaults.headers || {});
|
|
29644
|
+
const headers = new Headers(input.headers || {});
|
|
29645
|
+
headers.forEach((value, key) => {
|
|
29646
|
+
merged.headers.set(key, value);
|
|
29647
|
+
});
|
|
29648
|
+
}
|
|
29649
|
+
return merged;
|
|
29650
|
+
}
|
|
29651
|
+
function mergeFetchOptions(input, defaults) {
|
|
29652
|
+
const merged = {
|
|
29653
|
+
...defaults,
|
|
29654
|
+
...input
|
|
29655
|
+
};
|
|
29656
|
+
if (defaults?.headers && input?.headers) {
|
|
29657
|
+
merged.headers = new Headers(defaults.headers || {});
|
|
29658
|
+
const headers = new Headers(input.headers || {});
|
|
29659
|
+
headers.forEach((value, key) => {
|
|
29660
|
+
merged.headers.set(key, value);
|
|
29661
|
+
});
|
|
29662
|
+
}
|
|
29663
|
+
return merged;
|
|
29664
|
+
}
|
|
29665
|
+
function defaultTransformer(data, headers) {
|
|
29666
|
+
const contentType = headers.get("content-type");
|
|
29667
|
+
if (!contentType) {
|
|
29668
|
+
if (typeof data === "string") {
|
|
29669
|
+
headers.set("content-type", "text/plain");
|
|
29670
|
+
} else if (data instanceof URLSearchParams) {
|
|
29671
|
+
headers.set("content-type", "application/x-www-form-urlencoded");
|
|
29672
|
+
} else if (data instanceof Blob || data instanceof ArrayBuffer || ArrayBuffer.isView(data)) {
|
|
29673
|
+
headers.set("content-type", "application/octet-stream");
|
|
29674
|
+
} else if (typeof data === "object" && typeof data.append !== "function" && typeof data.text !== "function") {
|
|
29675
|
+
data = JSON.stringify(data);
|
|
29676
|
+
headers.set("content-type", "application/json");
|
|
29677
|
+
}
|
|
29678
|
+
} else {
|
|
29679
|
+
if (contentType === "application/x-www-form-urlencoded" && !(data instanceof URLSearchParams)) {
|
|
29680
|
+
data = new URLSearchParams(data);
|
|
29681
|
+
} else if (contentType === "application/json" && typeof data === "object") {
|
|
29682
|
+
data = JSON.stringify(data);
|
|
29683
|
+
}
|
|
29684
|
+
}
|
|
29685
|
+
return data;
|
|
29686
|
+
}
|
|
29687
|
+
async function request(configOrUrl, config, defaults, method, interceptors, data) {
|
|
29688
|
+
if (typeof configOrUrl === "string") {
|
|
29689
|
+
config = config || {};
|
|
29690
|
+
config.url = configOrUrl;
|
|
29691
|
+
} else
|
|
29692
|
+
config = configOrUrl || {};
|
|
29693
|
+
const options = mergeAxiosOptions(config, defaults || {});
|
|
29694
|
+
options.fetchOptions = options.fetchOptions || {};
|
|
29695
|
+
options.timeout = options.timeout || 0;
|
|
29696
|
+
options.headers = new Headers(options.headers || {});
|
|
29697
|
+
options.transformRequest = options.transformRequest ?? defaultTransformer;
|
|
29698
|
+
data = data || options.data;
|
|
29699
|
+
if (options.transformRequest && data) {
|
|
29700
|
+
Array.isArray(options.transformRequest) ? options.transformRequest.map(
|
|
29701
|
+
(fn) => data = fn.call(options, data, options.headers)
|
|
29702
|
+
) : data = options.transformRequest(data, options.headers);
|
|
29703
|
+
}
|
|
29704
|
+
options.url = buildURL(options);
|
|
29705
|
+
options.method = method || options.method || "get";
|
|
29706
|
+
if (interceptors && interceptors.request.handlers.length > 0) {
|
|
29707
|
+
const chain = interceptors.request.handlers.filter(
|
|
29708
|
+
(interceptor) => !interceptor?.runWhen || typeof interceptor.runWhen === "function" && interceptor.runWhen(options)
|
|
29709
|
+
).flatMap((interceptor) => [interceptor.fulfilled, interceptor.rejected]);
|
|
29710
|
+
let result = options;
|
|
29711
|
+
for (let i = 0, len = chain.length; i < len; i += 2) {
|
|
29712
|
+
const onFulfilled = chain[i];
|
|
29713
|
+
const onRejected = chain[i + 1];
|
|
29714
|
+
try {
|
|
29715
|
+
if (onFulfilled)
|
|
29716
|
+
result = onFulfilled(result);
|
|
29717
|
+
} catch (error) {
|
|
29718
|
+
if (onRejected)
|
|
29719
|
+
onRejected?.(error);
|
|
29720
|
+
break;
|
|
29721
|
+
}
|
|
29722
|
+
}
|
|
29723
|
+
}
|
|
29724
|
+
const init = mergeFetchOptions(
|
|
29725
|
+
{
|
|
29726
|
+
method: options.method?.toUpperCase(),
|
|
29727
|
+
body: data,
|
|
29728
|
+
headers: options.headers,
|
|
29729
|
+
credentials: options.withCredentials ? "include" : void 0,
|
|
29730
|
+
signal: options.signal
|
|
29731
|
+
},
|
|
29732
|
+
options.fetchOptions
|
|
29733
|
+
);
|
|
29734
|
+
let resp = handleFetch(options, init);
|
|
29735
|
+
if (interceptors && interceptors.response.handlers.length > 0) {
|
|
29736
|
+
const chain = interceptors.response.handlers.flatMap((interceptor) => [
|
|
29737
|
+
interceptor.fulfilled,
|
|
29738
|
+
interceptor.rejected
|
|
29739
|
+
]);
|
|
29740
|
+
for (let i = 0, len = chain.length; i < len; i += 2) {
|
|
29741
|
+
resp = resp.then(chain[i], chain[i + 1]);
|
|
29742
|
+
}
|
|
29743
|
+
}
|
|
29744
|
+
return resp;
|
|
29745
|
+
}
|
|
29746
|
+
var AxiosInterceptorManager = class {
|
|
29747
|
+
handlers = [];
|
|
29748
|
+
constructor() {
|
|
29749
|
+
this.handlers = [];
|
|
29750
|
+
}
|
|
29751
|
+
use = (onFulfilled, onRejected, options) => {
|
|
29752
|
+
this.handlers.push({
|
|
29753
|
+
fulfilled: onFulfilled,
|
|
29754
|
+
rejected: onRejected,
|
|
29755
|
+
runWhen: options?.runWhen
|
|
29756
|
+
});
|
|
29757
|
+
return this.handlers.length - 1;
|
|
29758
|
+
};
|
|
29759
|
+
eject = (id) => {
|
|
29760
|
+
if (this.handlers[id]) {
|
|
29761
|
+
this.handlers[id] = null;
|
|
29762
|
+
}
|
|
29763
|
+
};
|
|
29764
|
+
clear = () => {
|
|
29765
|
+
this.handlers = [];
|
|
29766
|
+
};
|
|
29767
|
+
};
|
|
29768
|
+
function createAxiosInstance(defaults) {
|
|
29769
|
+
defaults = defaults || {};
|
|
29770
|
+
const interceptors = {
|
|
29771
|
+
request: new AxiosInterceptorManager(),
|
|
29772
|
+
response: new AxiosInterceptorManager()
|
|
29773
|
+
};
|
|
29774
|
+
const axios2 = (url, config) => request(url, config, defaults, void 0, interceptors);
|
|
29775
|
+
axios2.defaults = defaults;
|
|
29776
|
+
axios2.interceptors = interceptors;
|
|
29777
|
+
axios2.getUri = (config) => {
|
|
29778
|
+
const merged = mergeAxiosOptions(config || {}, defaults);
|
|
29779
|
+
return buildURL(merged);
|
|
29780
|
+
};
|
|
29781
|
+
axios2.request = (config) => request(config, void 0, defaults, void 0, interceptors);
|
|
29782
|
+
["get", "delete", "head", "options"].forEach((method) => {
|
|
29783
|
+
axios2[method] = (url, config) => request(url, config, defaults, method, interceptors);
|
|
29784
|
+
});
|
|
29785
|
+
["post", "put", "patch"].forEach((method) => {
|
|
29786
|
+
axios2[method] = (url, data, config) => request(url, config, defaults, method, interceptors, data);
|
|
29787
|
+
});
|
|
29788
|
+
["postForm", "putForm", "patchForm"].forEach((method) => {
|
|
29789
|
+
axios2[method] = (url, data, config) => {
|
|
29790
|
+
config = config || {};
|
|
29791
|
+
config.headers = new Headers(config.headers || {});
|
|
29792
|
+
config.headers.set("content-type", "application/x-www-form-urlencoded");
|
|
29793
|
+
return request(
|
|
29794
|
+
url,
|
|
29795
|
+
config,
|
|
29796
|
+
defaults,
|
|
29797
|
+
method.replace("Form", ""),
|
|
29798
|
+
interceptors,
|
|
29799
|
+
data
|
|
29800
|
+
);
|
|
29801
|
+
};
|
|
29802
|
+
});
|
|
29803
|
+
return axios2;
|
|
29804
|
+
}
|
|
29805
|
+
var AxiosError = class extends Error {
|
|
29806
|
+
config;
|
|
29807
|
+
code;
|
|
29808
|
+
request;
|
|
29809
|
+
response;
|
|
29810
|
+
status;
|
|
29811
|
+
isAxiosError;
|
|
29812
|
+
constructor(message, code, config, request2, response) {
|
|
29813
|
+
super(message);
|
|
29814
|
+
if (Error.captureStackTrace) {
|
|
29815
|
+
Error.captureStackTrace(this, this.constructor);
|
|
29816
|
+
} else {
|
|
29817
|
+
this.stack = new Error().stack;
|
|
29818
|
+
}
|
|
29819
|
+
this.name = "AxiosError";
|
|
29820
|
+
this.code = code;
|
|
29821
|
+
this.config = config;
|
|
29822
|
+
this.request = request2;
|
|
29823
|
+
this.response = response;
|
|
29824
|
+
this.isAxiosError = true;
|
|
29825
|
+
}
|
|
29826
|
+
static ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
|
|
29827
|
+
static ERR_BAD_OPTION = "ERR_BAD_OPTION";
|
|
29828
|
+
static ERR_NETWORK = "ERR_NETWORK";
|
|
29829
|
+
static ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
|
|
29830
|
+
static ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
|
|
29831
|
+
static ERR_INVALID_URL = "ERR_INVALID_URL";
|
|
29832
|
+
static ERR_CANCELED = "ERR_CANCELED";
|
|
29833
|
+
static ECONNABORTED = "ECONNABORTED";
|
|
29834
|
+
static ETIMEDOUT = "ETIMEDOUT";
|
|
29835
|
+
};
|
|
29836
|
+
var CanceledError = class extends AxiosError {
|
|
29837
|
+
constructor(message, config, request2) {
|
|
29838
|
+
super(
|
|
29839
|
+
!message ? "canceled" : message,
|
|
29840
|
+
AxiosError.ERR_CANCELED,
|
|
29841
|
+
config,
|
|
29842
|
+
request2
|
|
29843
|
+
);
|
|
29844
|
+
this.name = "CanceledError";
|
|
29845
|
+
}
|
|
29846
|
+
};
|
|
29847
|
+
function isAxiosError(payload) {
|
|
29848
|
+
return payload !== null && typeof payload === "object" && payload.isAxiosError;
|
|
29849
|
+
}
|
|
29850
|
+
var axios = createAxiosInstance();
|
|
29851
|
+
axios.create = (defaults) => createAxiosInstance(defaults);
|
|
29852
|
+
|
|
29853
|
+
// src/index.ts
|
|
29854
|
+
var src_default = axios;
|
|
29855
|
+
|
|
29856
|
+
|
|
29857
|
+
|
|
29507
29858
|
// EXTERNAL MODULE: ./src/http-client/types.ts
|
|
29508
29859
|
var types = __webpack_require__(5798);
|
|
29509
29860
|
;// ./src/http-client/fetch-client.ts
|
|
@@ -29561,7 +29912,7 @@ function createFetchClient() {
|
|
|
29561
29912
|
var defaults = _objectSpread(_objectSpread({}, fetchConfig), {}, {
|
|
29562
29913
|
headers: fetchConfig.headers || {}
|
|
29563
29914
|
});
|
|
29564
|
-
var instance =
|
|
29915
|
+
var instance = src_default.create(defaults);
|
|
29565
29916
|
var requestInterceptors = new InterceptorManager();
|
|
29566
29917
|
var responseInterceptors = new InterceptorManager();
|
|
29567
29918
|
var httpClient = {
|
|
@@ -29925,7 +30276,7 @@ var lib = __webpack_require__(356);
|
|
|
29925
30276
|
var http_client = __webpack_require__(6371);
|
|
29926
30277
|
;// ./src/rpc/axios.ts
|
|
29927
30278
|
|
|
29928
|
-
var version = "13.
|
|
30279
|
+
var version = "13.1.0";
|
|
29929
30280
|
var AxiosClient = (0,http_client/* create */.vt)({
|
|
29930
30281
|
headers: {
|
|
29931
30282
|
'X-Client-Name': 'js-soroban-client',
|
|
@@ -30676,7 +31027,7 @@ var RpcServer = function () {
|
|
|
30676
31027
|
key: "requestAirdrop",
|
|
30677
31028
|
value: (function () {
|
|
30678
31029
|
var _requestAirdrop = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee22(address, friendbotUrl) {
|
|
30679
|
-
var account, response, meta, sequence, _error$response, _error$response$detai;
|
|
31030
|
+
var account, response, meta, txMeta, sequence, _error$response, _error$response$detai;
|
|
30680
31031
|
return server_regeneratorRuntime().wrap(function _callee22$(_context22) {
|
|
30681
31032
|
while (1) switch (_context22.prev = _context22.next) {
|
|
30682
31033
|
case 0:
|
|
@@ -30703,28 +31054,47 @@ var RpcServer = function () {
|
|
|
30703
31054
|
return axios.post("".concat(friendbotUrl, "?addr=").concat(encodeURIComponent(account)));
|
|
30704
31055
|
case 12:
|
|
30705
31056
|
response = _context22.sent;
|
|
31057
|
+
if (response.data.result_meta_xdr) {
|
|
31058
|
+
_context22.next = 22;
|
|
31059
|
+
break;
|
|
31060
|
+
}
|
|
31061
|
+
_context22.next = 16;
|
|
31062
|
+
return this.getTransaction(response.data.hash);
|
|
31063
|
+
case 16:
|
|
31064
|
+
txMeta = _context22.sent;
|
|
31065
|
+
if (!(txMeta.status !== api/* Api */.j.GetTransactionStatus.SUCCESS)) {
|
|
31066
|
+
_context22.next = 19;
|
|
31067
|
+
break;
|
|
31068
|
+
}
|
|
31069
|
+
throw new Error("Funding account ".concat(address, " failed"));
|
|
31070
|
+
case 19:
|
|
31071
|
+
meta = txMeta.resultMetaXdr;
|
|
31072
|
+
_context22.next = 23;
|
|
31073
|
+
break;
|
|
31074
|
+
case 22:
|
|
30706
31075
|
meta = lib.xdr.TransactionMeta.fromXDR(response.data.result_meta_xdr, 'base64');
|
|
31076
|
+
case 23:
|
|
30707
31077
|
sequence = findCreatedAccountSequenceInTransactionMeta(meta);
|
|
30708
31078
|
return _context22.abrupt("return", new lib.Account(account, sequence));
|
|
30709
|
-
case
|
|
30710
|
-
_context22.prev =
|
|
31079
|
+
case 27:
|
|
31080
|
+
_context22.prev = 27;
|
|
30711
31081
|
_context22.t1 = _context22["catch"](9);
|
|
30712
31082
|
if (!(((_error$response = _context22.t1.response) === null || _error$response === void 0 ? void 0 : _error$response.status) === 400)) {
|
|
30713
|
-
_context22.next =
|
|
31083
|
+
_context22.next = 32;
|
|
30714
31084
|
break;
|
|
30715
31085
|
}
|
|
30716
31086
|
if (!((_error$response$detai = _context22.t1.response.detail) !== null && _error$response$detai !== void 0 && _error$response$detai.includes('createAccountAlreadyExist'))) {
|
|
30717
|
-
_context22.next =
|
|
31087
|
+
_context22.next = 32;
|
|
30718
31088
|
break;
|
|
30719
31089
|
}
|
|
30720
31090
|
return _context22.abrupt("return", this.getAccount(account));
|
|
30721
|
-
case
|
|
31091
|
+
case 32:
|
|
30722
31092
|
throw _context22.t1;
|
|
30723
|
-
case
|
|
31093
|
+
case 33:
|
|
30724
31094
|
case "end":
|
|
30725
31095
|
return _context22.stop();
|
|
30726
31096
|
}
|
|
30727
|
-
}, _callee22, this, [[9,
|
|
31097
|
+
}, _callee22, this, [[9, 27]]);
|
|
30728
31098
|
}));
|
|
30729
31099
|
function requestAirdrop(_x21, _x22) {
|
|
30730
31100
|
return _requestAirdrop.apply(this, arguments);
|
|
@@ -30937,6 +31307,7 @@ function parseRawEvents(raw) {
|
|
|
30937
31307
|
var _raw$events;
|
|
30938
31308
|
return {
|
|
30939
31309
|
latestLedger: raw.latestLedger,
|
|
31310
|
+
cursor: raw.cursor,
|
|
30940
31311
|
events: ((_raw$events = raw.events) !== null && _raw$events !== void 0 ? _raw$events : []).map(function (evt) {
|
|
30941
31312
|
var clone = _objectSpread({}, evt);
|
|
30942
31313
|
delete clone.contractId;
|
|
@@ -37185,6 +37556,101 @@ module.exports = {
|
|
|
37185
37556
|
}
|
|
37186
37557
|
|
|
37187
37558
|
|
|
37559
|
+
/***/ }),
|
|
37560
|
+
|
|
37561
|
+
/***/ 3144:
|
|
37562
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
37563
|
+
|
|
37564
|
+
"use strict";
|
|
37565
|
+
|
|
37566
|
+
|
|
37567
|
+
var bind = __webpack_require__(6743);
|
|
37568
|
+
|
|
37569
|
+
var $apply = __webpack_require__(1002);
|
|
37570
|
+
var $call = __webpack_require__(76);
|
|
37571
|
+
var $reflectApply = __webpack_require__(7119);
|
|
37572
|
+
|
|
37573
|
+
/** @type {import('./actualApply')} */
|
|
37574
|
+
module.exports = $reflectApply || bind.call($call, $apply);
|
|
37575
|
+
|
|
37576
|
+
|
|
37577
|
+
/***/ }),
|
|
37578
|
+
|
|
37579
|
+
/***/ 2205:
|
|
37580
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
37581
|
+
|
|
37582
|
+
"use strict";
|
|
37583
|
+
|
|
37584
|
+
|
|
37585
|
+
var bind = __webpack_require__(6743);
|
|
37586
|
+
var $apply = __webpack_require__(1002);
|
|
37587
|
+
var actualApply = __webpack_require__(3144);
|
|
37588
|
+
|
|
37589
|
+
/** @type {import('./applyBind')} */
|
|
37590
|
+
module.exports = function applyBind() {
|
|
37591
|
+
return actualApply(bind, $apply, arguments);
|
|
37592
|
+
};
|
|
37593
|
+
|
|
37594
|
+
|
|
37595
|
+
/***/ }),
|
|
37596
|
+
|
|
37597
|
+
/***/ 1002:
|
|
37598
|
+
/***/ ((module) => {
|
|
37599
|
+
|
|
37600
|
+
"use strict";
|
|
37601
|
+
|
|
37602
|
+
|
|
37603
|
+
/** @type {import('./functionApply')} */
|
|
37604
|
+
module.exports = Function.prototype.apply;
|
|
37605
|
+
|
|
37606
|
+
|
|
37607
|
+
/***/ }),
|
|
37608
|
+
|
|
37609
|
+
/***/ 76:
|
|
37610
|
+
/***/ ((module) => {
|
|
37611
|
+
|
|
37612
|
+
"use strict";
|
|
37613
|
+
|
|
37614
|
+
|
|
37615
|
+
/** @type {import('./functionCall')} */
|
|
37616
|
+
module.exports = Function.prototype.call;
|
|
37617
|
+
|
|
37618
|
+
|
|
37619
|
+
/***/ }),
|
|
37620
|
+
|
|
37621
|
+
/***/ 3126:
|
|
37622
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
37623
|
+
|
|
37624
|
+
"use strict";
|
|
37625
|
+
|
|
37626
|
+
|
|
37627
|
+
var bind = __webpack_require__(6743);
|
|
37628
|
+
var $TypeError = __webpack_require__(9675);
|
|
37629
|
+
|
|
37630
|
+
var $call = __webpack_require__(76);
|
|
37631
|
+
var $actualApply = __webpack_require__(3144);
|
|
37632
|
+
|
|
37633
|
+
/** @type {import('.')} */
|
|
37634
|
+
module.exports = function callBindBasic(args) {
|
|
37635
|
+
if (args.length < 1 || typeof args[0] !== 'function') {
|
|
37636
|
+
throw new $TypeError('a function is required');
|
|
37637
|
+
}
|
|
37638
|
+
return $actualApply(bind, $call, args);
|
|
37639
|
+
};
|
|
37640
|
+
|
|
37641
|
+
|
|
37642
|
+
/***/ }),
|
|
37643
|
+
|
|
37644
|
+
/***/ 7119:
|
|
37645
|
+
/***/ ((module) => {
|
|
37646
|
+
|
|
37647
|
+
"use strict";
|
|
37648
|
+
|
|
37649
|
+
|
|
37650
|
+
/** @type {import('./reflectApply')} */
|
|
37651
|
+
module.exports = typeof Reflect !== 'undefined' && Reflect && Reflect.apply;
|
|
37652
|
+
|
|
37653
|
+
|
|
37188
37654
|
/***/ }),
|
|
37189
37655
|
|
|
37190
37656
|
/***/ 8075:
|
|
@@ -37216,34 +37682,23 @@ module.exports = function callBoundIntrinsic(name, allowMissing) {
|
|
|
37216
37682
|
"use strict";
|
|
37217
37683
|
|
|
37218
37684
|
|
|
37219
|
-
var bind = __webpack_require__(6743);
|
|
37220
|
-
var GetIntrinsic = __webpack_require__(453);
|
|
37221
37685
|
var setFunctionLength = __webpack_require__(6897);
|
|
37222
37686
|
|
|
37223
|
-
var $TypeError = __webpack_require__(9675);
|
|
37224
|
-
var $apply = GetIntrinsic('%Function.prototype.apply%');
|
|
37225
|
-
var $call = GetIntrinsic('%Function.prototype.call%');
|
|
37226
|
-
var $reflectApply = GetIntrinsic('%Reflect.apply%', true) || bind.call($call, $apply);
|
|
37227
|
-
|
|
37228
37687
|
var $defineProperty = __webpack_require__(655);
|
|
37229
|
-
|
|
37688
|
+
|
|
37689
|
+
var callBindBasic = __webpack_require__(3126);
|
|
37690
|
+
var applyBind = __webpack_require__(2205);
|
|
37230
37691
|
|
|
37231
37692
|
module.exports = function callBind(originalFunction) {
|
|
37232
|
-
|
|
37233
|
-
|
|
37234
|
-
}
|
|
37235
|
-
var func = $reflectApply(bind, $call, arguments);
|
|
37693
|
+
var func = callBindBasic(arguments);
|
|
37694
|
+
var adjustedLength = originalFunction.length - (arguments.length - 1);
|
|
37236
37695
|
return setFunctionLength(
|
|
37237
37696
|
func,
|
|
37238
|
-
1 +
|
|
37697
|
+
1 + (adjustedLength > 0 ? adjustedLength : 0),
|
|
37239
37698
|
true
|
|
37240
37699
|
);
|
|
37241
37700
|
};
|
|
37242
37701
|
|
|
37243
|
-
var applyBind = function applyBind() {
|
|
37244
|
-
return $reflectApply(bind, $apply, arguments);
|
|
37245
|
-
};
|
|
37246
|
-
|
|
37247
37702
|
if ($defineProperty) {
|
|
37248
37703
|
$defineProperty(module.exports, 'apply', { value: applyBind });
|
|
37249
37704
|
} else {
|
|
@@ -37251,6 +37706,32 @@ if ($defineProperty) {
|
|
|
37251
37706
|
}
|
|
37252
37707
|
|
|
37253
37708
|
|
|
37709
|
+
/***/ }),
|
|
37710
|
+
|
|
37711
|
+
/***/ 6556:
|
|
37712
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
37713
|
+
|
|
37714
|
+
"use strict";
|
|
37715
|
+
|
|
37716
|
+
|
|
37717
|
+
var GetIntrinsic = __webpack_require__(453);
|
|
37718
|
+
|
|
37719
|
+
var callBindBasic = __webpack_require__(3126);
|
|
37720
|
+
|
|
37721
|
+
/** @type {(thisArg: string, searchString: string, position?: number) => number} */
|
|
37722
|
+
var $indexOf = callBindBasic([GetIntrinsic('%String.prototype.indexOf%')]);
|
|
37723
|
+
|
|
37724
|
+
/** @type {import('.')} */
|
|
37725
|
+
module.exports = function callBoundIntrinsic(name, allowMissing) {
|
|
37726
|
+
// eslint-disable-next-line no-extra-parens
|
|
37727
|
+
var intrinsic = /** @type {Parameters<typeof callBindBasic>[0][0]} */ (GetIntrinsic(name, !!allowMissing));
|
|
37728
|
+
if (typeof intrinsic === 'function' && $indexOf(name, '.prototype.') > -1) {
|
|
37729
|
+
return callBindBasic([intrinsic]);
|
|
37730
|
+
}
|
|
37731
|
+
return intrinsic;
|
|
37732
|
+
};
|
|
37733
|
+
|
|
37734
|
+
|
|
37254
37735
|
/***/ }),
|
|
37255
37736
|
|
|
37256
37737
|
/***/ 41:
|
|
@@ -37317,16 +37798,45 @@ module.exports = function defineDataProperty(
|
|
|
37317
37798
|
|
|
37318
37799
|
/***/ }),
|
|
37319
37800
|
|
|
37320
|
-
/***/
|
|
37801
|
+
/***/ 7176:
|
|
37321
37802
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
37322
37803
|
|
|
37323
37804
|
"use strict";
|
|
37324
37805
|
|
|
37325
37806
|
|
|
37326
|
-
var
|
|
37807
|
+
var callBind = __webpack_require__(3126);
|
|
37808
|
+
var gOPD = __webpack_require__(5795);
|
|
37809
|
+
|
|
37810
|
+
// eslint-disable-next-line no-extra-parens, no-proto
|
|
37811
|
+
var hasProtoAccessor = /** @type {{ __proto__?: typeof Array.prototype }} */ ([]).__proto__ === Array.prototype;
|
|
37812
|
+
|
|
37813
|
+
// eslint-disable-next-line no-extra-parens
|
|
37814
|
+
var desc = hasProtoAccessor && gOPD && gOPD(Object.prototype, /** @type {keyof typeof Object.prototype} */ ('__proto__'));
|
|
37815
|
+
|
|
37816
|
+
var $Object = Object;
|
|
37817
|
+
var $getPrototypeOf = $Object.getPrototypeOf;
|
|
37818
|
+
|
|
37819
|
+
/** @type {import('./get')} */
|
|
37820
|
+
module.exports = desc && typeof desc.get === 'function'
|
|
37821
|
+
? callBind([desc.get])
|
|
37822
|
+
: typeof $getPrototypeOf === 'function'
|
|
37823
|
+
? /** @type {import('./get')} */ function getDunder(value) {
|
|
37824
|
+
// eslint-disable-next-line eqeqeq
|
|
37825
|
+
return $getPrototypeOf(value == null ? value : $Object(value));
|
|
37826
|
+
}
|
|
37827
|
+
: false;
|
|
37828
|
+
|
|
37829
|
+
|
|
37830
|
+
/***/ }),
|
|
37831
|
+
|
|
37832
|
+
/***/ 655:
|
|
37833
|
+
/***/ ((module) => {
|
|
37834
|
+
|
|
37835
|
+
"use strict";
|
|
37836
|
+
|
|
37327
37837
|
|
|
37328
37838
|
/** @type {import('.')} */
|
|
37329
|
-
var $defineProperty =
|
|
37839
|
+
var $defineProperty = Object.defineProperty || false;
|
|
37330
37840
|
if ($defineProperty) {
|
|
37331
37841
|
try {
|
|
37332
37842
|
$defineProperty({}, 'a', { value: 1 });
|
|
@@ -37423,6 +37933,18 @@ module.exports = TypeError;
|
|
|
37423
37933
|
module.exports = URIError;
|
|
37424
37934
|
|
|
37425
37935
|
|
|
37936
|
+
/***/ }),
|
|
37937
|
+
|
|
37938
|
+
/***/ 9612:
|
|
37939
|
+
/***/ ((module) => {
|
|
37940
|
+
|
|
37941
|
+
"use strict";
|
|
37942
|
+
|
|
37943
|
+
|
|
37944
|
+
/** @type {import('.')} */
|
|
37945
|
+
module.exports = Object;
|
|
37946
|
+
|
|
37947
|
+
|
|
37426
37948
|
/***/ }),
|
|
37427
37949
|
|
|
37428
37950
|
/***/ 7007:
|
|
@@ -38616,6 +39138,8 @@ module.exports = Function.prototype.bind || implementation;
|
|
|
38616
39138
|
|
|
38617
39139
|
var undefined;
|
|
38618
39140
|
|
|
39141
|
+
var $Object = __webpack_require__(9612);
|
|
39142
|
+
|
|
38619
39143
|
var $Error = __webpack_require__(9383);
|
|
38620
39144
|
var $EvalError = __webpack_require__(1237);
|
|
38621
39145
|
var $RangeError = __webpack_require__(9290);
|
|
@@ -38624,6 +39148,12 @@ var $SyntaxError = __webpack_require__(8068);
|
|
|
38624
39148
|
var $TypeError = __webpack_require__(9675);
|
|
38625
39149
|
var $URIError = __webpack_require__(5345);
|
|
38626
39150
|
|
|
39151
|
+
var abs = __webpack_require__(1514);
|
|
39152
|
+
var floor = __webpack_require__(8968);
|
|
39153
|
+
var max = __webpack_require__(6188);
|
|
39154
|
+
var min = __webpack_require__(8002);
|
|
39155
|
+
var pow = __webpack_require__(5880);
|
|
39156
|
+
|
|
38627
39157
|
var $Function = Function;
|
|
38628
39158
|
|
|
38629
39159
|
// eslint-disable-next-line consistent-return
|
|
@@ -38633,14 +39163,8 @@ var getEvalledConstructor = function (expressionSyntax) {
|
|
|
38633
39163
|
} catch (e) {}
|
|
38634
39164
|
};
|
|
38635
39165
|
|
|
38636
|
-
var $gOPD =
|
|
38637
|
-
|
|
38638
|
-
try {
|
|
38639
|
-
$gOPD({}, '');
|
|
38640
|
-
} catch (e) {
|
|
38641
|
-
$gOPD = null; // this is IE 8, which has a broken gOPD
|
|
38642
|
-
}
|
|
38643
|
-
}
|
|
39166
|
+
var $gOPD = __webpack_require__(5795);
|
|
39167
|
+
var $defineProperty = __webpack_require__(655);
|
|
38644
39168
|
|
|
38645
39169
|
var throwTypeError = function () {
|
|
38646
39170
|
throw new $TypeError();
|
|
@@ -38663,13 +39187,14 @@ var ThrowTypeError = $gOPD
|
|
|
38663
39187
|
: throwTypeError;
|
|
38664
39188
|
|
|
38665
39189
|
var hasSymbols = __webpack_require__(4039)();
|
|
38666
|
-
var
|
|
39190
|
+
var getDunderProto = __webpack_require__(7176);
|
|
38667
39191
|
|
|
38668
|
-
var getProto =
|
|
38669
|
-
|
|
38670
|
-
|
|
38671
|
-
|
|
38672
|
-
);
|
|
39192
|
+
var getProto = (typeof Reflect === 'function' && Reflect.getPrototypeOf)
|
|
39193
|
+
|| $Object.getPrototypeOf
|
|
39194
|
+
|| getDunderProto;
|
|
39195
|
+
|
|
39196
|
+
var $apply = __webpack_require__(1002);
|
|
39197
|
+
var $call = __webpack_require__(76);
|
|
38673
39198
|
|
|
38674
39199
|
var needsEval = {};
|
|
38675
39200
|
|
|
@@ -38716,7 +39241,8 @@ var INTRINSICS = {
|
|
|
38716
39241
|
'%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols || !getProto ? undefined : getProto(new Map()[Symbol.iterator]()),
|
|
38717
39242
|
'%Math%': Math,
|
|
38718
39243
|
'%Number%': Number,
|
|
38719
|
-
'%Object%': Object,
|
|
39244
|
+
'%Object%': $Object,
|
|
39245
|
+
'%Object.getOwnPropertyDescriptor%': $gOPD,
|
|
38720
39246
|
'%parseFloat%': parseFloat,
|
|
38721
39247
|
'%parseInt%': parseInt,
|
|
38722
39248
|
'%Promise%': typeof Promise === 'undefined' ? undefined : Promise,
|
|
@@ -38742,7 +39268,16 @@ var INTRINSICS = {
|
|
|
38742
39268
|
'%URIError%': $URIError,
|
|
38743
39269
|
'%WeakMap%': typeof WeakMap === 'undefined' ? undefined : WeakMap,
|
|
38744
39270
|
'%WeakRef%': typeof WeakRef === 'undefined' ? undefined : WeakRef,
|
|
38745
|
-
'%WeakSet%': typeof WeakSet === 'undefined' ? undefined : WeakSet
|
|
39271
|
+
'%WeakSet%': typeof WeakSet === 'undefined' ? undefined : WeakSet,
|
|
39272
|
+
|
|
39273
|
+
'%Function.prototype.call%': $call,
|
|
39274
|
+
'%Function.prototype.apply%': $apply,
|
|
39275
|
+
'%Object.defineProperty%': $defineProperty,
|
|
39276
|
+
'%Math.abs%': abs,
|
|
39277
|
+
'%Math.floor%': floor,
|
|
39278
|
+
'%Math.max%': max,
|
|
39279
|
+
'%Math.min%': min,
|
|
39280
|
+
'%Math.pow%': pow
|
|
38746
39281
|
};
|
|
38747
39282
|
|
|
38748
39283
|
if (getProto) {
|
|
@@ -38837,11 +39372,11 @@ var LEGACY_ALIASES = {
|
|
|
38837
39372
|
|
|
38838
39373
|
var bind = __webpack_require__(6743);
|
|
38839
39374
|
var hasOwn = __webpack_require__(9957);
|
|
38840
|
-
var $concat = bind.call(
|
|
38841
|
-
var $spliceApply = bind.call(
|
|
38842
|
-
var $replace = bind.call(
|
|
38843
|
-
var $strSlice = bind.call(
|
|
38844
|
-
var $exec = bind.call(
|
|
39375
|
+
var $concat = bind.call($call, Array.prototype.concat);
|
|
39376
|
+
var $spliceApply = bind.call($apply, Array.prototype.splice);
|
|
39377
|
+
var $replace = bind.call($call, String.prototype.replace);
|
|
39378
|
+
var $strSlice = bind.call($call, String.prototype.slice);
|
|
39379
|
+
var $exec = bind.call($call, RegExp.prototype.exec);
|
|
38845
39380
|
|
|
38846
39381
|
/* adapted from https://github.com/lodash/lodash/blob/4.17.15/dist/lodash.js#L6735-L6744 */
|
|
38847
39382
|
var rePropName = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g;
|
|
@@ -38973,6 +39508,18 @@ module.exports = function GetIntrinsic(name, allowMissing) {
|
|
|
38973
39508
|
};
|
|
38974
39509
|
|
|
38975
39510
|
|
|
39511
|
+
/***/ }),
|
|
39512
|
+
|
|
39513
|
+
/***/ 6549:
|
|
39514
|
+
/***/ ((module) => {
|
|
39515
|
+
|
|
39516
|
+
"use strict";
|
|
39517
|
+
|
|
39518
|
+
|
|
39519
|
+
/** @type {import('./gOPD')} */
|
|
39520
|
+
module.exports = Object.getOwnPropertyDescriptor;
|
|
39521
|
+
|
|
39522
|
+
|
|
38976
39523
|
/***/ }),
|
|
38977
39524
|
|
|
38978
39525
|
/***/ 5795:
|
|
@@ -38981,9 +39528,8 @@ module.exports = function GetIntrinsic(name, allowMissing) {
|
|
|
38981
39528
|
"use strict";
|
|
38982
39529
|
|
|
38983
39530
|
|
|
38984
|
-
|
|
38985
|
-
|
|
38986
|
-
var $gOPD = GetIntrinsic('%Object.getOwnPropertyDescriptor%', true);
|
|
39531
|
+
/** @type {import('.')} */
|
|
39532
|
+
var $gOPD = __webpack_require__(6549);
|
|
38987
39533
|
|
|
38988
39534
|
if ($gOPD) {
|
|
38989
39535
|
try {
|
|
@@ -39027,29 +39573,6 @@ hasPropertyDescriptors.hasArrayLengthDefineBug = function hasArrayLengthDefineBu
|
|
|
39027
39573
|
module.exports = hasPropertyDescriptors;
|
|
39028
39574
|
|
|
39029
39575
|
|
|
39030
|
-
/***/ }),
|
|
39031
|
-
|
|
39032
|
-
/***/ 24:
|
|
39033
|
-
/***/ ((module) => {
|
|
39034
|
-
|
|
39035
|
-
"use strict";
|
|
39036
|
-
|
|
39037
|
-
|
|
39038
|
-
var test = {
|
|
39039
|
-
__proto__: null,
|
|
39040
|
-
foo: {}
|
|
39041
|
-
};
|
|
39042
|
-
|
|
39043
|
-
var $Object = Object;
|
|
39044
|
-
|
|
39045
|
-
/** @type {import('.')} */
|
|
39046
|
-
module.exports = function hasProto() {
|
|
39047
|
-
// @ts-expect-error: TS errors on an inherited property for some reason
|
|
39048
|
-
return { __proto__: test }.foo === test.foo
|
|
39049
|
-
&& !(test instanceof $Object);
|
|
39050
|
-
};
|
|
39051
|
-
|
|
39052
|
-
|
|
39053
39576
|
/***/ }),
|
|
39054
39577
|
|
|
39055
39578
|
/***/ 4039:
|
|
@@ -39061,6 +39584,7 @@ module.exports = function hasProto() {
|
|
|
39061
39584
|
var origSymbol = typeof Symbol !== 'undefined' && Symbol;
|
|
39062
39585
|
var hasSymbolSham = __webpack_require__(1333);
|
|
39063
39586
|
|
|
39587
|
+
/** @type {import('.')} */
|
|
39064
39588
|
module.exports = function hasNativeSymbols() {
|
|
39065
39589
|
if (typeof origSymbol !== 'function') { return false; }
|
|
39066
39590
|
if (typeof Symbol !== 'function') { return false; }
|
|
@@ -39079,11 +39603,13 @@ module.exports = function hasNativeSymbols() {
|
|
|
39079
39603
|
"use strict";
|
|
39080
39604
|
|
|
39081
39605
|
|
|
39606
|
+
/** @type {import('./shams')} */
|
|
39082
39607
|
/* eslint complexity: [2, 18], max-statements: [2, 33] */
|
|
39083
39608
|
module.exports = function hasSymbols() {
|
|
39084
39609
|
if (typeof Symbol !== 'function' || typeof Object.getOwnPropertySymbols !== 'function') { return false; }
|
|
39085
39610
|
if (typeof Symbol.iterator === 'symbol') { return true; }
|
|
39086
39611
|
|
|
39612
|
+
/** @type {{ [k in symbol]?: unknown }} */
|
|
39087
39613
|
var obj = {};
|
|
39088
39614
|
var sym = Symbol('test');
|
|
39089
39615
|
var symObj = Object(sym);
|
|
@@ -39102,7 +39628,7 @@ module.exports = function hasSymbols() {
|
|
|
39102
39628
|
|
|
39103
39629
|
var symVal = 42;
|
|
39104
39630
|
obj[sym] = symVal;
|
|
39105
|
-
for (
|
|
39631
|
+
for (var _ in obj) { return false; } // eslint-disable-line no-restricted-syntax, no-unreachable-loop
|
|
39106
39632
|
if (typeof Object.keys === 'function' && Object.keys(obj).length !== 0) { return false; }
|
|
39107
39633
|
|
|
39108
39634
|
if (typeof Object.getOwnPropertyNames === 'function' && Object.getOwnPropertyNames(obj).length !== 0) { return false; }
|
|
@@ -39113,7 +39639,8 @@ module.exports = function hasSymbols() {
|
|
|
39113
39639
|
if (!Object.prototype.propertyIsEnumerable.call(obj, sym)) { return false; }
|
|
39114
39640
|
|
|
39115
39641
|
if (typeof Object.getOwnPropertyDescriptor === 'function') {
|
|
39116
|
-
|
|
39642
|
+
// eslint-disable-next-line no-extra-parens
|
|
39643
|
+
var descriptor = /** @type {PropertyDescriptor} */ (Object.getOwnPropertyDescriptor(obj, sym));
|
|
39117
39644
|
if (descriptor.value !== symVal || descriptor.enumerable !== true) { return false; }
|
|
39118
39645
|
}
|
|
39119
39646
|
|
|
@@ -39326,35 +39853,46 @@ if (typeof Object.create === 'function') {
|
|
|
39326
39853
|
|
|
39327
39854
|
|
|
39328
39855
|
var hasToStringTag = __webpack_require__(9092)();
|
|
39329
|
-
var callBound = __webpack_require__(
|
|
39856
|
+
var callBound = __webpack_require__(6556);
|
|
39330
39857
|
|
|
39331
39858
|
var $toString = callBound('Object.prototype.toString');
|
|
39332
39859
|
|
|
39860
|
+
/** @type {import('.')} */
|
|
39333
39861
|
var isStandardArguments = function isArguments(value) {
|
|
39334
|
-
if (
|
|
39862
|
+
if (
|
|
39863
|
+
hasToStringTag
|
|
39864
|
+
&& value
|
|
39865
|
+
&& typeof value === 'object'
|
|
39866
|
+
&& Symbol.toStringTag in value
|
|
39867
|
+
) {
|
|
39335
39868
|
return false;
|
|
39336
39869
|
}
|
|
39337
39870
|
return $toString(value) === '[object Arguments]';
|
|
39338
39871
|
};
|
|
39339
39872
|
|
|
39873
|
+
/** @type {import('.')} */
|
|
39340
39874
|
var isLegacyArguments = function isArguments(value) {
|
|
39341
39875
|
if (isStandardArguments(value)) {
|
|
39342
39876
|
return true;
|
|
39343
39877
|
}
|
|
39344
|
-
return value !== null
|
|
39345
|
-
typeof value === 'object'
|
|
39346
|
-
|
|
39347
|
-
value.length
|
|
39348
|
-
|
|
39349
|
-
$toString(value
|
|
39878
|
+
return value !== null
|
|
39879
|
+
&& typeof value === 'object'
|
|
39880
|
+
&& 'length' in value
|
|
39881
|
+
&& typeof value.length === 'number'
|
|
39882
|
+
&& value.length >= 0
|
|
39883
|
+
&& $toString(value) !== '[object Array]'
|
|
39884
|
+
&& 'callee' in value
|
|
39885
|
+
&& $toString(value.callee) === '[object Function]';
|
|
39350
39886
|
};
|
|
39351
39887
|
|
|
39352
39888
|
var supportsStandardArguments = (function () {
|
|
39353
39889
|
return isStandardArguments(arguments);
|
|
39354
39890
|
}());
|
|
39355
39891
|
|
|
39892
|
+
// @ts-expect-error TODO make this not error
|
|
39356
39893
|
isStandardArguments.isLegacyArguments = isLegacyArguments; // for tests
|
|
39357
39894
|
|
|
39895
|
+
/** @type {import('.')} */
|
|
39358
39896
|
module.exports = supportsStandardArguments ? isStandardArguments : isLegacyArguments;
|
|
39359
39897
|
|
|
39360
39898
|
|
|
@@ -39529,6 +40067,66 @@ module.exports = function isTypedArray(value) {
|
|
|
39529
40067
|
};
|
|
39530
40068
|
|
|
39531
40069
|
|
|
40070
|
+
/***/ }),
|
|
40071
|
+
|
|
40072
|
+
/***/ 1514:
|
|
40073
|
+
/***/ ((module) => {
|
|
40074
|
+
|
|
40075
|
+
"use strict";
|
|
40076
|
+
|
|
40077
|
+
|
|
40078
|
+
/** @type {import('./abs')} */
|
|
40079
|
+
module.exports = Math.abs;
|
|
40080
|
+
|
|
40081
|
+
|
|
40082
|
+
/***/ }),
|
|
40083
|
+
|
|
40084
|
+
/***/ 8968:
|
|
40085
|
+
/***/ ((module) => {
|
|
40086
|
+
|
|
40087
|
+
"use strict";
|
|
40088
|
+
|
|
40089
|
+
|
|
40090
|
+
/** @type {import('./abs')} */
|
|
40091
|
+
module.exports = Math.floor;
|
|
40092
|
+
|
|
40093
|
+
|
|
40094
|
+
/***/ }),
|
|
40095
|
+
|
|
40096
|
+
/***/ 6188:
|
|
40097
|
+
/***/ ((module) => {
|
|
40098
|
+
|
|
40099
|
+
"use strict";
|
|
40100
|
+
|
|
40101
|
+
|
|
40102
|
+
/** @type {import('./max')} */
|
|
40103
|
+
module.exports = Math.max;
|
|
40104
|
+
|
|
40105
|
+
|
|
40106
|
+
/***/ }),
|
|
40107
|
+
|
|
40108
|
+
/***/ 8002:
|
|
40109
|
+
/***/ ((module) => {
|
|
40110
|
+
|
|
40111
|
+
"use strict";
|
|
40112
|
+
|
|
40113
|
+
|
|
40114
|
+
/** @type {import('./min')} */
|
|
40115
|
+
module.exports = Math.min;
|
|
40116
|
+
|
|
40117
|
+
|
|
40118
|
+
/***/ }),
|
|
40119
|
+
|
|
40120
|
+
/***/ 5880:
|
|
40121
|
+
/***/ ((module) => {
|
|
40122
|
+
|
|
40123
|
+
"use strict";
|
|
40124
|
+
|
|
40125
|
+
|
|
40126
|
+
/** @type {import('./pow')} */
|
|
40127
|
+
module.exports = Math.pow;
|
|
40128
|
+
|
|
40129
|
+
|
|
39532
40130
|
/***/ }),
|
|
39533
40131
|
|
|
39534
40132
|
/***/ 8859:
|
|
@@ -40245,7 +40843,8 @@ var parseValues = function parseQueryStringValues(str, options) {
|
|
|
40245
40843
|
var bracketEqualsPos = part.indexOf(']=');
|
|
40246
40844
|
var pos = bracketEqualsPos === -1 ? part.indexOf('=') : bracketEqualsPos + 1;
|
|
40247
40845
|
|
|
40248
|
-
var key
|
|
40846
|
+
var key;
|
|
40847
|
+
var val;
|
|
40249
40848
|
if (pos === -1) {
|
|
40250
40849
|
key = options.decoder(part, defaults.decoder, charset, 'key');
|
|
40251
40850
|
val = options.strictNullHandling ? null : '';
|
|
@@ -40260,7 +40859,7 @@ var parseValues = function parseQueryStringValues(str, options) {
|
|
|
40260
40859
|
}
|
|
40261
40860
|
|
|
40262
40861
|
if (val && options.interpretNumericEntities && charset === 'iso-8859-1') {
|
|
40263
|
-
val = interpretNumericEntities(val);
|
|
40862
|
+
val = interpretNumericEntities(String(val));
|
|
40264
40863
|
}
|
|
40265
40864
|
|
|
40266
40865
|
if (part.indexOf('[]=') > -1) {
|
|
@@ -40290,7 +40889,7 @@ var parseObject = function (chain, val, options, valuesParsed) {
|
|
|
40290
40889
|
? []
|
|
40291
40890
|
: [].concat(leaf);
|
|
40292
40891
|
} else {
|
|
40293
|
-
obj = options.plainObjects ?
|
|
40892
|
+
obj = options.plainObjects ? { __proto__: null } : {};
|
|
40294
40893
|
var cleanRoot = root.charAt(0) === '[' && root.charAt(root.length - 1) === ']' ? root.slice(1, -1) : root;
|
|
40295
40894
|
var decodedRoot = options.decodeDotInKeys ? cleanRoot.replace(/%2E/g, '.') : cleanRoot;
|
|
40296
40895
|
var index = parseInt(decodedRoot, 10);
|
|
@@ -40432,11 +41031,11 @@ module.exports = function (str, opts) {
|
|
|
40432
41031
|
var options = normalizeParseOptions(opts);
|
|
40433
41032
|
|
|
40434
41033
|
if (str === '' || str === null || typeof str === 'undefined') {
|
|
40435
|
-
return options.plainObjects ?
|
|
41034
|
+
return options.plainObjects ? { __proto__: null } : {};
|
|
40436
41035
|
}
|
|
40437
41036
|
|
|
40438
41037
|
var tempObj = typeof str === 'string' ? parseValues(str, options) : str;
|
|
40439
|
-
var obj = options.plainObjects ?
|
|
41038
|
+
var obj = options.plainObjects ? { __proto__: null } : {};
|
|
40440
41039
|
|
|
40441
41040
|
// Iterate over the keys and setup the new object
|
|
40442
41041
|
|
|
@@ -40497,11 +41096,13 @@ var defaults = {
|
|
|
40497
41096
|
arrayFormat: 'indices',
|
|
40498
41097
|
charset: 'utf-8',
|
|
40499
41098
|
charsetSentinel: false,
|
|
41099
|
+
commaRoundTrip: false,
|
|
40500
41100
|
delimiter: '&',
|
|
40501
41101
|
encode: true,
|
|
40502
41102
|
encodeDotInKeys: false,
|
|
40503
41103
|
encoder: utils.encode,
|
|
40504
41104
|
encodeValuesOnly: false,
|
|
41105
|
+
filter: void undefined,
|
|
40505
41106
|
format: defaultFormat,
|
|
40506
41107
|
formatter: formats.formatters[defaultFormat],
|
|
40507
41108
|
// deprecated
|
|
@@ -40613,7 +41214,7 @@ var stringify = function stringify(
|
|
|
40613
41214
|
objKeys = sort ? keys.sort(sort) : keys;
|
|
40614
41215
|
}
|
|
40615
41216
|
|
|
40616
|
-
var encodedPrefix = encodeDotInKeys ? prefix.replace(/\./g, '%2E') : prefix;
|
|
41217
|
+
var encodedPrefix = encodeDotInKeys ? String(prefix).replace(/\./g, '%2E') : String(prefix);
|
|
40617
41218
|
|
|
40618
41219
|
var adjustedPrefix = commaRoundTrip && isArray(obj) && obj.length === 1 ? encodedPrefix + '[]' : encodedPrefix;
|
|
40619
41220
|
|
|
@@ -40623,13 +41224,15 @@ var stringify = function stringify(
|
|
|
40623
41224
|
|
|
40624
41225
|
for (var j = 0; j < objKeys.length; ++j) {
|
|
40625
41226
|
var key = objKeys[j];
|
|
40626
|
-
var value = typeof key === 'object' && typeof key.value !== 'undefined'
|
|
41227
|
+
var value = typeof key === 'object' && key && typeof key.value !== 'undefined'
|
|
41228
|
+
? key.value
|
|
41229
|
+
: obj[key];
|
|
40627
41230
|
|
|
40628
41231
|
if (skipNulls && value === null) {
|
|
40629
41232
|
continue;
|
|
40630
41233
|
}
|
|
40631
41234
|
|
|
40632
|
-
var encodedKey = allowDots && encodeDotInKeys ? key.replace(/\./g, '%2E') : key;
|
|
41235
|
+
var encodedKey = allowDots && encodeDotInKeys ? String(key).replace(/\./g, '%2E') : String(key);
|
|
40633
41236
|
var keyPrefix = isArray(obj)
|
|
40634
41237
|
? typeof generateArrayPrefix === 'function' ? generateArrayPrefix(adjustedPrefix, encodedKey) : adjustedPrefix
|
|
40635
41238
|
: adjustedPrefix + (allowDots ? '.' + encodedKey : '[' + encodedKey + ']');
|
|
@@ -40720,7 +41323,7 @@ var normalizeStringifyOptions = function normalizeStringifyOptions(opts) {
|
|
|
40720
41323
|
arrayFormat: arrayFormat,
|
|
40721
41324
|
charset: charset,
|
|
40722
41325
|
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
|
40723
|
-
commaRoundTrip: opts.commaRoundTrip,
|
|
41326
|
+
commaRoundTrip: !!opts.commaRoundTrip,
|
|
40724
41327
|
delimiter: typeof opts.delimiter === 'undefined' ? defaults.delimiter : opts.delimiter,
|
|
40725
41328
|
encode: typeof opts.encode === 'boolean' ? opts.encode : defaults.encode,
|
|
40726
41329
|
encodeDotInKeys: typeof opts.encodeDotInKeys === 'boolean' ? opts.encodeDotInKeys : defaults.encodeDotInKeys,
|
|
@@ -40771,12 +41374,13 @@ module.exports = function (object, opts) {
|
|
|
40771
41374
|
var sideChannel = getSideChannel();
|
|
40772
41375
|
for (var i = 0; i < objKeys.length; ++i) {
|
|
40773
41376
|
var key = objKeys[i];
|
|
41377
|
+
var value = obj[key];
|
|
40774
41378
|
|
|
40775
|
-
if (options.skipNulls &&
|
|
41379
|
+
if (options.skipNulls && value === null) {
|
|
40776
41380
|
continue;
|
|
40777
41381
|
}
|
|
40778
41382
|
pushToArray(keys, stringify(
|
|
40779
|
-
|
|
41383
|
+
value,
|
|
40780
41384
|
key,
|
|
40781
41385
|
generateArrayPrefix,
|
|
40782
41386
|
commaRoundTrip,
|
|
@@ -40856,7 +41460,7 @@ var compactQueue = function compactQueue(queue) {
|
|
|
40856
41460
|
};
|
|
40857
41461
|
|
|
40858
41462
|
var arrayToObject = function arrayToObject(source, options) {
|
|
40859
|
-
var obj = options && options.plainObjects ?
|
|
41463
|
+
var obj = options && options.plainObjects ? { __proto__: null } : {};
|
|
40860
41464
|
for (var i = 0; i < source.length; ++i) {
|
|
40861
41465
|
if (typeof source[i] !== 'undefined') {
|
|
40862
41466
|
obj[i] = source[i];
|
|
@@ -40872,11 +41476,14 @@ var merge = function merge(target, source, options) {
|
|
|
40872
41476
|
return target;
|
|
40873
41477
|
}
|
|
40874
41478
|
|
|
40875
|
-
if (typeof source !== 'object') {
|
|
41479
|
+
if (typeof source !== 'object' && typeof source !== 'function') {
|
|
40876
41480
|
if (isArray(target)) {
|
|
40877
41481
|
target.push(source);
|
|
40878
41482
|
} else if (target && typeof target === 'object') {
|
|
40879
|
-
if (
|
|
41483
|
+
if (
|
|
41484
|
+
(options && (options.plainObjects || options.allowPrototypes))
|
|
41485
|
+
|| !has.call(Object.prototype, source)
|
|
41486
|
+
) {
|
|
40880
41487
|
target[source] = true;
|
|
40881
41488
|
}
|
|
40882
41489
|
} else {
|
|
@@ -40930,7 +41537,7 @@ var assign = function assignSingleSource(target, source) {
|
|
|
40930
41537
|
}, target);
|
|
40931
41538
|
};
|
|
40932
41539
|
|
|
40933
|
-
var decode = function (str,
|
|
41540
|
+
var decode = function (str, defaultDecoder, charset) {
|
|
40934
41541
|
var strWithoutPlus = str.replace(/\+/g, ' ');
|
|
40935
41542
|
if (charset === 'iso-8859-1') {
|
|
40936
41543
|
// unescape never throws, no try...catch needed:
|
|
@@ -45039,137 +45646,340 @@ module.exports = Sha512
|
|
|
45039
45646
|
|
|
45040
45647
|
/***/ }),
|
|
45041
45648
|
|
|
45042
|
-
/***/
|
|
45649
|
+
/***/ 4803:
|
|
45043
45650
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
45044
45651
|
|
|
45045
45652
|
"use strict";
|
|
45046
45653
|
|
|
45047
45654
|
|
|
45048
|
-
var GetIntrinsic = __webpack_require__(453);
|
|
45049
|
-
var callBound = __webpack_require__(8075);
|
|
45050
45655
|
var inspect = __webpack_require__(8859);
|
|
45051
45656
|
|
|
45052
45657
|
var $TypeError = __webpack_require__(9675);
|
|
45053
|
-
var $WeakMap = GetIntrinsic('%WeakMap%', true);
|
|
45054
|
-
var $Map = GetIntrinsic('%Map%', true);
|
|
45055
|
-
|
|
45056
|
-
var $weakMapGet = callBound('WeakMap.prototype.get', true);
|
|
45057
|
-
var $weakMapSet = callBound('WeakMap.prototype.set', true);
|
|
45058
|
-
var $weakMapHas = callBound('WeakMap.prototype.has', true);
|
|
45059
|
-
var $mapGet = callBound('Map.prototype.get', true);
|
|
45060
|
-
var $mapSet = callBound('Map.prototype.set', true);
|
|
45061
|
-
var $mapHas = callBound('Map.prototype.has', true);
|
|
45062
45658
|
|
|
45063
45659
|
/*
|
|
45064
45660
|
* This function traverses the list returning the node corresponding to the given key.
|
|
45065
45661
|
*
|
|
45066
|
-
* That node is also moved to the head of the list, so that if it's accessed again we don't need to traverse the whole list.
|
|
45662
|
+
* That node is also moved to the head of the list, so that if it's accessed again we don't need to traverse the whole list.
|
|
45663
|
+
* By doing so, all the recently used nodes can be accessed relatively quickly.
|
|
45067
45664
|
*/
|
|
45068
|
-
/** @type {import('.').listGetNode} */
|
|
45069
|
-
|
|
45665
|
+
/** @type {import('./list.d.ts').listGetNode} */
|
|
45666
|
+
// eslint-disable-next-line consistent-return
|
|
45667
|
+
var listGetNode = function (list, key, isDelete) {
|
|
45070
45668
|
/** @type {typeof list | NonNullable<(typeof list)['next']>} */
|
|
45071
45669
|
var prev = list;
|
|
45072
45670
|
/** @type {(typeof list)['next']} */
|
|
45073
45671
|
var curr;
|
|
45074
|
-
|
|
45672
|
+
// eslint-disable-next-line eqeqeq
|
|
45673
|
+
for (; (curr = prev.next) != null; prev = curr) {
|
|
45075
45674
|
if (curr.key === key) {
|
|
45076
45675
|
prev.next = curr.next;
|
|
45077
|
-
|
|
45078
|
-
|
|
45079
|
-
|
|
45676
|
+
if (!isDelete) {
|
|
45677
|
+
// eslint-disable-next-line no-extra-parens
|
|
45678
|
+
curr.next = /** @type {NonNullable<typeof list.next>} */ (list.next);
|
|
45679
|
+
list.next = curr; // eslint-disable-line no-param-reassign
|
|
45680
|
+
}
|
|
45080
45681
|
return curr;
|
|
45081
45682
|
}
|
|
45082
45683
|
}
|
|
45083
45684
|
};
|
|
45084
45685
|
|
|
45085
|
-
/** @type {import('.').listGet} */
|
|
45686
|
+
/** @type {import('./list.d.ts').listGet} */
|
|
45086
45687
|
var listGet = function (objects, key) {
|
|
45688
|
+
if (!objects) {
|
|
45689
|
+
return void undefined;
|
|
45690
|
+
}
|
|
45087
45691
|
var node = listGetNode(objects, key);
|
|
45088
45692
|
return node && node.value;
|
|
45089
45693
|
};
|
|
45090
|
-
/** @type {import('.').listSet} */
|
|
45694
|
+
/** @type {import('./list.d.ts').listSet} */
|
|
45091
45695
|
var listSet = function (objects, key, value) {
|
|
45092
45696
|
var node = listGetNode(objects, key);
|
|
45093
45697
|
if (node) {
|
|
45094
45698
|
node.value = value;
|
|
45095
45699
|
} else {
|
|
45096
45700
|
// Prepend the new node to the beginning of the list
|
|
45097
|
-
objects.next = /** @type {import('.').ListNode<typeof value>} */ ({ // eslint-disable-line no-param-reassign, no-extra-parens
|
|
45701
|
+
objects.next = /** @type {import('./list.d.ts').ListNode<typeof value, typeof key>} */ ({ // eslint-disable-line no-param-reassign, no-extra-parens
|
|
45098
45702
|
key: key,
|
|
45099
45703
|
next: objects.next,
|
|
45100
45704
|
value: value
|
|
45101
45705
|
});
|
|
45102
45706
|
}
|
|
45103
45707
|
};
|
|
45104
|
-
/** @type {import('.').listHas} */
|
|
45708
|
+
/** @type {import('./list.d.ts').listHas} */
|
|
45105
45709
|
var listHas = function (objects, key) {
|
|
45710
|
+
if (!objects) {
|
|
45711
|
+
return false;
|
|
45712
|
+
}
|
|
45106
45713
|
return !!listGetNode(objects, key);
|
|
45107
45714
|
};
|
|
45715
|
+
/** @type {import('./list.d.ts').listDelete} */
|
|
45716
|
+
// eslint-disable-next-line consistent-return
|
|
45717
|
+
var listDelete = function (objects, key) {
|
|
45718
|
+
if (objects) {
|
|
45719
|
+
return listGetNode(objects, key, true);
|
|
45720
|
+
}
|
|
45721
|
+
};
|
|
45108
45722
|
|
|
45109
45723
|
/** @type {import('.')} */
|
|
45110
|
-
module.exports = function
|
|
45111
|
-
/** @
|
|
45112
|
-
/** @
|
|
45113
|
-
/** @
|
|
45724
|
+
module.exports = function getSideChannelList() {
|
|
45725
|
+
/** @typedef {ReturnType<typeof getSideChannelList>} Channel */
|
|
45726
|
+
/** @typedef {Parameters<Channel['get']>[0]} K */
|
|
45727
|
+
/** @typedef {Parameters<Channel['set']>[1]} V */
|
|
45728
|
+
|
|
45729
|
+
/** @type {import('./list.d.ts').RootNode<V, K> | undefined} */ var $o;
|
|
45114
45730
|
|
|
45115
|
-
/** @type {
|
|
45731
|
+
/** @type {Channel} */
|
|
45116
45732
|
var channel = {
|
|
45117
45733
|
assert: function (key) {
|
|
45118
45734
|
if (!channel.has(key)) {
|
|
45119
45735
|
throw new $TypeError('Side channel does not contain ' + inspect(key));
|
|
45120
45736
|
}
|
|
45121
45737
|
},
|
|
45122
|
-
|
|
45123
|
-
|
|
45124
|
-
|
|
45125
|
-
|
|
45126
|
-
|
|
45127
|
-
} else if ($Map) {
|
|
45128
|
-
if ($m) {
|
|
45129
|
-
return $mapGet($m, key);
|
|
45130
|
-
}
|
|
45131
|
-
} else {
|
|
45132
|
-
if ($o) { // eslint-disable-line no-lonely-if
|
|
45133
|
-
return listGet($o, key);
|
|
45134
|
-
}
|
|
45738
|
+
'delete': function (key) {
|
|
45739
|
+
var root = $o && $o.next;
|
|
45740
|
+
var deletedNode = listDelete($o, key);
|
|
45741
|
+
if (deletedNode && root && root === deletedNode) {
|
|
45742
|
+
$o = void undefined;
|
|
45135
45743
|
}
|
|
45744
|
+
return !!deletedNode;
|
|
45745
|
+
},
|
|
45746
|
+
get: function (key) {
|
|
45747
|
+
return listGet($o, key);
|
|
45136
45748
|
},
|
|
45137
45749
|
has: function (key) {
|
|
45138
|
-
|
|
45139
|
-
|
|
45140
|
-
|
|
45141
|
-
|
|
45142
|
-
|
|
45143
|
-
|
|
45144
|
-
|
|
45145
|
-
}
|
|
45146
|
-
}
|
|
45147
|
-
|
|
45148
|
-
|
|
45750
|
+
return listHas($o, key);
|
|
45751
|
+
},
|
|
45752
|
+
set: function (key, value) {
|
|
45753
|
+
if (!$o) {
|
|
45754
|
+
// Initialize the linked list as an empty node, so that we don't have to special-case handling of the first node: we can always refer to it as (previous node).next, instead of something like (list).head
|
|
45755
|
+
$o = {
|
|
45756
|
+
next: void undefined
|
|
45757
|
+
};
|
|
45758
|
+
}
|
|
45759
|
+
// eslint-disable-next-line no-extra-parens
|
|
45760
|
+
listSet(/** @type {NonNullable<typeof $o>} */ ($o), key, value);
|
|
45761
|
+
}
|
|
45762
|
+
};
|
|
45763
|
+
// @ts-expect-error TODO: figure out why this is erroring
|
|
45764
|
+
return channel;
|
|
45765
|
+
};
|
|
45766
|
+
|
|
45767
|
+
|
|
45768
|
+
/***/ }),
|
|
45769
|
+
|
|
45770
|
+
/***/ 507:
|
|
45771
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
45772
|
+
|
|
45773
|
+
"use strict";
|
|
45774
|
+
|
|
45775
|
+
|
|
45776
|
+
var GetIntrinsic = __webpack_require__(453);
|
|
45777
|
+
var callBound = __webpack_require__(6556);
|
|
45778
|
+
var inspect = __webpack_require__(8859);
|
|
45779
|
+
|
|
45780
|
+
var $TypeError = __webpack_require__(9675);
|
|
45781
|
+
var $Map = GetIntrinsic('%Map%', true);
|
|
45782
|
+
|
|
45783
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K) => V} */
|
|
45784
|
+
var $mapGet = callBound('Map.prototype.get', true);
|
|
45785
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K, value: V) => void} */
|
|
45786
|
+
var $mapSet = callBound('Map.prototype.set', true);
|
|
45787
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K) => boolean} */
|
|
45788
|
+
var $mapHas = callBound('Map.prototype.has', true);
|
|
45789
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K) => boolean} */
|
|
45790
|
+
var $mapDelete = callBound('Map.prototype.delete', true);
|
|
45791
|
+
/** @type {<K, V>(thisArg: Map<K, V>) => number} */
|
|
45792
|
+
var $mapSize = callBound('Map.prototype.size', true);
|
|
45793
|
+
|
|
45794
|
+
/** @type {import('.')} */
|
|
45795
|
+
module.exports = !!$Map && /** @type {Exclude<import('.'), false>} */ function getSideChannelMap() {
|
|
45796
|
+
/** @typedef {ReturnType<typeof getSideChannelMap>} Channel */
|
|
45797
|
+
/** @typedef {Parameters<Channel['get']>[0]} K */
|
|
45798
|
+
/** @typedef {Parameters<Channel['set']>[1]} V */
|
|
45799
|
+
|
|
45800
|
+
/** @type {Map<K, V> | undefined} */ var $m;
|
|
45801
|
+
|
|
45802
|
+
/** @type {Channel} */
|
|
45803
|
+
var channel = {
|
|
45804
|
+
assert: function (key) {
|
|
45805
|
+
if (!channel.has(key)) {
|
|
45806
|
+
throw new $TypeError('Side channel does not contain ' + inspect(key));
|
|
45807
|
+
}
|
|
45808
|
+
},
|
|
45809
|
+
'delete': function (key) {
|
|
45810
|
+
if ($m) {
|
|
45811
|
+
var result = $mapDelete($m, key);
|
|
45812
|
+
if ($mapSize($m) === 0) {
|
|
45813
|
+
$m = void undefined;
|
|
45149
45814
|
}
|
|
45815
|
+
return result;
|
|
45816
|
+
}
|
|
45817
|
+
return false;
|
|
45818
|
+
},
|
|
45819
|
+
get: function (key) { // eslint-disable-line consistent-return
|
|
45820
|
+
if ($m) {
|
|
45821
|
+
return $mapGet($m, key);
|
|
45822
|
+
}
|
|
45823
|
+
},
|
|
45824
|
+
has: function (key) {
|
|
45825
|
+
if ($m) {
|
|
45826
|
+
return $mapHas($m, key);
|
|
45150
45827
|
}
|
|
45151
45828
|
return false;
|
|
45152
45829
|
},
|
|
45153
45830
|
set: function (key, value) {
|
|
45154
|
-
if (
|
|
45155
|
-
|
|
45156
|
-
|
|
45831
|
+
if (!$m) {
|
|
45832
|
+
// @ts-expect-error TS can't handle narrowing a variable inside a closure
|
|
45833
|
+
$m = new $Map();
|
|
45834
|
+
}
|
|
45835
|
+
$mapSet($m, key, value);
|
|
45836
|
+
}
|
|
45837
|
+
};
|
|
45838
|
+
|
|
45839
|
+
// @ts-expect-error TODO: figure out why TS is erroring here
|
|
45840
|
+
return channel;
|
|
45841
|
+
};
|
|
45842
|
+
|
|
45843
|
+
|
|
45844
|
+
/***/ }),
|
|
45845
|
+
|
|
45846
|
+
/***/ 2271:
|
|
45847
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
45848
|
+
|
|
45849
|
+
"use strict";
|
|
45850
|
+
|
|
45851
|
+
|
|
45852
|
+
var GetIntrinsic = __webpack_require__(453);
|
|
45853
|
+
var callBound = __webpack_require__(6556);
|
|
45854
|
+
var inspect = __webpack_require__(8859);
|
|
45855
|
+
var getSideChannelMap = __webpack_require__(507);
|
|
45856
|
+
|
|
45857
|
+
var $TypeError = __webpack_require__(9675);
|
|
45858
|
+
var $WeakMap = GetIntrinsic('%WeakMap%', true);
|
|
45859
|
+
|
|
45860
|
+
/** @type {<K extends object, V>(thisArg: WeakMap<K, V>, key: K) => V} */
|
|
45861
|
+
var $weakMapGet = callBound('WeakMap.prototype.get', true);
|
|
45862
|
+
/** @type {<K extends object, V>(thisArg: WeakMap<K, V>, key: K, value: V) => void} */
|
|
45863
|
+
var $weakMapSet = callBound('WeakMap.prototype.set', true);
|
|
45864
|
+
/** @type {<K extends object, V>(thisArg: WeakMap<K, V>, key: K) => boolean} */
|
|
45865
|
+
var $weakMapHas = callBound('WeakMap.prototype.has', true);
|
|
45866
|
+
/** @type {<K extends object, V>(thisArg: WeakMap<K, V>, key: K) => boolean} */
|
|
45867
|
+
var $weakMapDelete = callBound('WeakMap.prototype.delete', true);
|
|
45868
|
+
|
|
45869
|
+
/** @type {import('.')} */
|
|
45870
|
+
module.exports = $WeakMap
|
|
45871
|
+
? /** @type {Exclude<import('.'), false>} */ function getSideChannelWeakMap() {
|
|
45872
|
+
/** @typedef {ReturnType<typeof getSideChannelWeakMap>} Channel */
|
|
45873
|
+
/** @typedef {Parameters<Channel['get']>[0]} K */
|
|
45874
|
+
/** @typedef {Parameters<Channel['set']>[1]} V */
|
|
45875
|
+
|
|
45876
|
+
/** @type {WeakMap<K & object, V> | undefined} */ var $wm;
|
|
45877
|
+
/** @type {Channel | undefined} */ var $m;
|
|
45878
|
+
|
|
45879
|
+
/** @type {Channel} */
|
|
45880
|
+
var channel = {
|
|
45881
|
+
assert: function (key) {
|
|
45882
|
+
if (!channel.has(key)) {
|
|
45883
|
+
throw new $TypeError('Side channel does not contain ' + inspect(key));
|
|
45157
45884
|
}
|
|
45158
|
-
|
|
45159
|
-
|
|
45160
|
-
if (
|
|
45161
|
-
|
|
45885
|
+
},
|
|
45886
|
+
'delete': function (key) {
|
|
45887
|
+
if ($WeakMap && key && (typeof key === 'object' || typeof key === 'function')) {
|
|
45888
|
+
if ($wm) {
|
|
45889
|
+
return $weakMapDelete($wm, key);
|
|
45890
|
+
}
|
|
45891
|
+
} else if (getSideChannelMap) {
|
|
45892
|
+
if ($m) {
|
|
45893
|
+
return $m['delete'](key);
|
|
45894
|
+
}
|
|
45162
45895
|
}
|
|
45163
|
-
|
|
45164
|
-
}
|
|
45165
|
-
|
|
45166
|
-
|
|
45167
|
-
$
|
|
45896
|
+
return false;
|
|
45897
|
+
},
|
|
45898
|
+
get: function (key) {
|
|
45899
|
+
if ($WeakMap && key && (typeof key === 'object' || typeof key === 'function')) {
|
|
45900
|
+
if ($wm) {
|
|
45901
|
+
return $weakMapGet($wm, key);
|
|
45902
|
+
}
|
|
45168
45903
|
}
|
|
45169
|
-
|
|
45904
|
+
return $m && $m.get(key);
|
|
45905
|
+
},
|
|
45906
|
+
has: function (key) {
|
|
45907
|
+
if ($WeakMap && key && (typeof key === 'object' || typeof key === 'function')) {
|
|
45908
|
+
if ($wm) {
|
|
45909
|
+
return $weakMapHas($wm, key);
|
|
45910
|
+
}
|
|
45911
|
+
}
|
|
45912
|
+
return !!$m && $m.has(key);
|
|
45913
|
+
},
|
|
45914
|
+
set: function (key, value) {
|
|
45915
|
+
if ($WeakMap && key && (typeof key === 'object' || typeof key === 'function')) {
|
|
45916
|
+
if (!$wm) {
|
|
45917
|
+
$wm = new $WeakMap();
|
|
45918
|
+
}
|
|
45919
|
+
$weakMapSet($wm, key, value);
|
|
45920
|
+
} else if (getSideChannelMap) {
|
|
45921
|
+
if (!$m) {
|
|
45922
|
+
$m = getSideChannelMap();
|
|
45923
|
+
}
|
|
45924
|
+
// eslint-disable-next-line no-extra-parens
|
|
45925
|
+
/** @type {NonNullable<typeof $m>} */ ($m).set(key, value);
|
|
45926
|
+
}
|
|
45927
|
+
}
|
|
45928
|
+
};
|
|
45929
|
+
|
|
45930
|
+
// @ts-expect-error TODO: figure out why this is erroring
|
|
45931
|
+
return channel;
|
|
45932
|
+
}
|
|
45933
|
+
: getSideChannelMap;
|
|
45934
|
+
|
|
45935
|
+
|
|
45936
|
+
/***/ }),
|
|
45937
|
+
|
|
45938
|
+
/***/ 920:
|
|
45939
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
45940
|
+
|
|
45941
|
+
"use strict";
|
|
45942
|
+
|
|
45943
|
+
|
|
45944
|
+
var $TypeError = __webpack_require__(9675);
|
|
45945
|
+
var inspect = __webpack_require__(8859);
|
|
45946
|
+
var getSideChannelList = __webpack_require__(4803);
|
|
45947
|
+
var getSideChannelMap = __webpack_require__(507);
|
|
45948
|
+
var getSideChannelWeakMap = __webpack_require__(2271);
|
|
45949
|
+
|
|
45950
|
+
var makeChannel = getSideChannelWeakMap || getSideChannelMap || getSideChannelList;
|
|
45951
|
+
|
|
45952
|
+
/** @type {import('.')} */
|
|
45953
|
+
module.exports = function getSideChannel() {
|
|
45954
|
+
/** @typedef {ReturnType<typeof getSideChannel>} Channel */
|
|
45955
|
+
|
|
45956
|
+
/** @type {Channel | undefined} */ var $channelData;
|
|
45957
|
+
|
|
45958
|
+
/** @type {Channel} */
|
|
45959
|
+
var channel = {
|
|
45960
|
+
assert: function (key) {
|
|
45961
|
+
if (!channel.has(key)) {
|
|
45962
|
+
throw new $TypeError('Side channel does not contain ' + inspect(key));
|
|
45170
45963
|
}
|
|
45964
|
+
},
|
|
45965
|
+
'delete': function (key) {
|
|
45966
|
+
return !!$channelData && $channelData['delete'](key);
|
|
45967
|
+
},
|
|
45968
|
+
get: function (key) {
|
|
45969
|
+
return $channelData && $channelData.get(key);
|
|
45970
|
+
},
|
|
45971
|
+
has: function (key) {
|
|
45972
|
+
return !!$channelData && $channelData.has(key);
|
|
45973
|
+
},
|
|
45974
|
+
set: function (key, value) {
|
|
45975
|
+
if (!$channelData) {
|
|
45976
|
+
$channelData = makeChannel();
|
|
45977
|
+
}
|
|
45978
|
+
|
|
45979
|
+
$channelData.set(key, value);
|
|
45171
45980
|
}
|
|
45172
45981
|
};
|
|
45982
|
+
// @ts-expect-error TODO: figure out why this is erroring
|
|
45173
45983
|
return channel;
|
|
45174
45984
|
};
|
|
45175
45985
|
|