@stellar/stellar-sdk 13.0.0 → 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 +14 -4
- package/README.md +1 -1
- package/dist/stellar-sdk-minimal.js +426 -71
- package/dist/stellar-sdk-minimal.min.js +1 -1
- package/dist/stellar-sdk-no-axios.js +1022 -228
- package/dist/stellar-sdk-no-axios.min.js +1 -1
- package/dist/stellar-sdk-no-eventsource.js +149 -142
- package/dist/stellar-sdk-no-eventsource.min.js +1 -1
- package/dist/stellar-sdk.js +745 -299
- 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 +10 -10
|
@@ -27730,7 +27730,7 @@ var http_client = __webpack_require__(6371);
|
|
|
27730
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); }
|
|
27731
27731
|
|
|
27732
27732
|
|
|
27733
|
-
var version = "13.
|
|
27733
|
+
var version = "13.1.0";
|
|
27734
27734
|
var SERVER_TIME_MAP = {};
|
|
27735
27735
|
var AxiosClient = (0,http_client/* create */.vt)({
|
|
27736
27736
|
headers: {
|
|
@@ -29116,28 +29116,49 @@ var HorizonServer = function () {
|
|
|
29116
29116
|
}
|
|
29117
29117
|
return feeStats;
|
|
29118
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
|
+
}())
|
|
29119
29140
|
}, {
|
|
29120
29141
|
key: "submitTransaction",
|
|
29121
29142
|
value: (function () {
|
|
29122
|
-
var _submitTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29143
|
+
var _submitTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee5(transaction) {
|
|
29123
29144
|
var opts,
|
|
29124
29145
|
tx,
|
|
29125
|
-
|
|
29126
|
-
return server_regeneratorRuntime().wrap(function
|
|
29127
|
-
while (1) switch (
|
|
29146
|
+
_args5 = arguments;
|
|
29147
|
+
return server_regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
29148
|
+
while (1) switch (_context5.prev = _context5.next) {
|
|
29128
29149
|
case 0:
|
|
29129
|
-
opts =
|
|
29150
|
+
opts = _args5.length > 1 && _args5[1] !== undefined ? _args5[1] : {
|
|
29130
29151
|
skipMemoRequiredCheck: false
|
|
29131
29152
|
};
|
|
29132
29153
|
if (opts.skipMemoRequiredCheck) {
|
|
29133
|
-
|
|
29154
|
+
_context5.next = 4;
|
|
29134
29155
|
break;
|
|
29135
29156
|
}
|
|
29136
|
-
|
|
29157
|
+
_context5.next = 4;
|
|
29137
29158
|
return this.checkMemoRequired(transaction);
|
|
29138
29159
|
case 4:
|
|
29139
29160
|
tx = encodeURIComponent(transaction.toEnvelope().toXDR().toString("base64"));
|
|
29140
|
-
return
|
|
29161
|
+
return _context5.abrupt("return", horizon_axios_client.post(URI_default()(this.serverURL).segment("transactions").toString(), "tx=".concat(tx), {
|
|
29141
29162
|
timeout: SUBMIT_TRANSACTION_TIMEOUT
|
|
29142
29163
|
}).then(function (response) {
|
|
29143
29164
|
if (!response.data.result_xdr) {
|
|
@@ -29248,9 +29269,9 @@ var HorizonServer = function () {
|
|
|
29248
29269
|
}));
|
|
29249
29270
|
case 6:
|
|
29250
29271
|
case "end":
|
|
29251
|
-
return
|
|
29272
|
+
return _context5.stop();
|
|
29252
29273
|
}
|
|
29253
|
-
},
|
|
29274
|
+
}, _callee5, this);
|
|
29254
29275
|
}));
|
|
29255
29276
|
function submitTransaction(_x2) {
|
|
29256
29277
|
return _submitTransaction.apply(this, arguments);
|
|
@@ -29260,25 +29281,25 @@ var HorizonServer = function () {
|
|
|
29260
29281
|
}, {
|
|
29261
29282
|
key: "submitAsyncTransaction",
|
|
29262
29283
|
value: (function () {
|
|
29263
|
-
var _submitAsyncTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29284
|
+
var _submitAsyncTransaction = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee6(transaction) {
|
|
29264
29285
|
var opts,
|
|
29265
29286
|
tx,
|
|
29266
|
-
|
|
29267
|
-
return server_regeneratorRuntime().wrap(function
|
|
29268
|
-
while (1) switch (
|
|
29287
|
+
_args6 = arguments;
|
|
29288
|
+
return server_regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
29289
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
29269
29290
|
case 0:
|
|
29270
|
-
opts =
|
|
29291
|
+
opts = _args6.length > 1 && _args6[1] !== undefined ? _args6[1] : {
|
|
29271
29292
|
skipMemoRequiredCheck: false
|
|
29272
29293
|
};
|
|
29273
29294
|
if (opts.skipMemoRequiredCheck) {
|
|
29274
|
-
|
|
29295
|
+
_context6.next = 4;
|
|
29275
29296
|
break;
|
|
29276
29297
|
}
|
|
29277
|
-
|
|
29298
|
+
_context6.next = 4;
|
|
29278
29299
|
return this.checkMemoRequired(transaction);
|
|
29279
29300
|
case 4:
|
|
29280
29301
|
tx = encodeURIComponent(transaction.toEnvelope().toXDR().toString("base64"));
|
|
29281
|
-
return
|
|
29302
|
+
return _context6.abrupt("return", horizon_axios_client.post(URI_default()(this.serverURL).segment("transactions_async").toString(), "tx=".concat(tx)).then(function (response) {
|
|
29282
29303
|
return response.data;
|
|
29283
29304
|
}).catch(function (response) {
|
|
29284
29305
|
if (response instanceof Error) {
|
|
@@ -29288,9 +29309,9 @@ var HorizonServer = function () {
|
|
|
29288
29309
|
}));
|
|
29289
29310
|
case 6:
|
|
29290
29311
|
case "end":
|
|
29291
|
-
return
|
|
29312
|
+
return _context6.stop();
|
|
29292
29313
|
}
|
|
29293
|
-
},
|
|
29314
|
+
}, _callee6, this);
|
|
29294
29315
|
}));
|
|
29295
29316
|
function submitAsyncTransaction(_x3) {
|
|
29296
29317
|
return _submitAsyncTransaction.apply(this, arguments);
|
|
@@ -29375,21 +29396,21 @@ var HorizonServer = function () {
|
|
|
29375
29396
|
}, {
|
|
29376
29397
|
key: "loadAccount",
|
|
29377
29398
|
value: (function () {
|
|
29378
|
-
var _loadAccount = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29399
|
+
var _loadAccount = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee7(accountId) {
|
|
29379
29400
|
var res;
|
|
29380
|
-
return server_regeneratorRuntime().wrap(function
|
|
29381
|
-
while (1) switch (
|
|
29401
|
+
return server_regeneratorRuntime().wrap(function _callee7$(_context7) {
|
|
29402
|
+
while (1) switch (_context7.prev = _context7.next) {
|
|
29382
29403
|
case 0:
|
|
29383
|
-
|
|
29404
|
+
_context7.next = 2;
|
|
29384
29405
|
return this.accounts().accountId(accountId).call();
|
|
29385
29406
|
case 2:
|
|
29386
|
-
res =
|
|
29387
|
-
return
|
|
29407
|
+
res = _context7.sent;
|
|
29408
|
+
return _context7.abrupt("return", new AccountResponse(res));
|
|
29388
29409
|
case 4:
|
|
29389
29410
|
case "end":
|
|
29390
|
-
return
|
|
29411
|
+
return _context7.stop();
|
|
29391
29412
|
}
|
|
29392
|
-
},
|
|
29413
|
+
}, _callee7, this);
|
|
29393
29414
|
}));
|
|
29394
29415
|
function loadAccount(_x4) {
|
|
29395
29416
|
return _loadAccount.apply(this, arguments);
|
|
@@ -29404,88 +29425,88 @@ var HorizonServer = function () {
|
|
|
29404
29425
|
}, {
|
|
29405
29426
|
key: "checkMemoRequired",
|
|
29406
29427
|
value: (function () {
|
|
29407
|
-
var _checkMemoRequired = server_asyncToGenerator(server_regeneratorRuntime().mark(function
|
|
29428
|
+
var _checkMemoRequired = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee8(transaction) {
|
|
29408
29429
|
var destinations, i, operation, destination, account;
|
|
29409
|
-
return server_regeneratorRuntime().wrap(function
|
|
29410
|
-
while (1) switch (
|
|
29430
|
+
return server_regeneratorRuntime().wrap(function _callee8$(_context8) {
|
|
29431
|
+
while (1) switch (_context8.prev = _context8.next) {
|
|
29411
29432
|
case 0:
|
|
29412
29433
|
if (transaction instanceof lib.FeeBumpTransaction) {
|
|
29413
29434
|
transaction = transaction.innerTransaction;
|
|
29414
29435
|
}
|
|
29415
29436
|
if (!(transaction.memo.type !== "none")) {
|
|
29416
|
-
|
|
29437
|
+
_context8.next = 3;
|
|
29417
29438
|
break;
|
|
29418
29439
|
}
|
|
29419
|
-
return
|
|
29440
|
+
return _context8.abrupt("return");
|
|
29420
29441
|
case 3:
|
|
29421
29442
|
destinations = new Set();
|
|
29422
29443
|
i = 0;
|
|
29423
29444
|
case 5:
|
|
29424
29445
|
if (!(i < transaction.operations.length)) {
|
|
29425
|
-
|
|
29446
|
+
_context8.next = 36;
|
|
29426
29447
|
break;
|
|
29427
29448
|
}
|
|
29428
29449
|
operation = transaction.operations[i];
|
|
29429
|
-
|
|
29430
|
-
|
|
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;
|
|
29431
29452
|
break;
|
|
29432
29453
|
case 10:
|
|
29433
|
-
return
|
|
29454
|
+
return _context8.abrupt("break", 12);
|
|
29434
29455
|
case 11:
|
|
29435
|
-
return
|
|
29456
|
+
return _context8.abrupt("continue", 33);
|
|
29436
29457
|
case 12:
|
|
29437
29458
|
destination = operation.destination;
|
|
29438
29459
|
if (!destinations.has(destination)) {
|
|
29439
|
-
|
|
29460
|
+
_context8.next = 15;
|
|
29440
29461
|
break;
|
|
29441
29462
|
}
|
|
29442
|
-
return
|
|
29463
|
+
return _context8.abrupt("continue", 33);
|
|
29443
29464
|
case 15:
|
|
29444
29465
|
destinations.add(destination);
|
|
29445
29466
|
if (!destination.startsWith("M")) {
|
|
29446
|
-
|
|
29467
|
+
_context8.next = 18;
|
|
29447
29468
|
break;
|
|
29448
29469
|
}
|
|
29449
|
-
return
|
|
29470
|
+
return _context8.abrupt("continue", 33);
|
|
29450
29471
|
case 18:
|
|
29451
|
-
|
|
29452
|
-
|
|
29472
|
+
_context8.prev = 18;
|
|
29473
|
+
_context8.next = 21;
|
|
29453
29474
|
return this.loadAccount(destination);
|
|
29454
29475
|
case 21:
|
|
29455
|
-
account =
|
|
29476
|
+
account = _context8.sent;
|
|
29456
29477
|
if (!(account.data_attr["config.memo_required"] === ACCOUNT_REQUIRES_MEMO)) {
|
|
29457
|
-
|
|
29478
|
+
_context8.next = 24;
|
|
29458
29479
|
break;
|
|
29459
29480
|
}
|
|
29460
29481
|
throw new errors/* AccountRequiresMemoError */.Cu("account requires memo", destination, i);
|
|
29461
29482
|
case 24:
|
|
29462
|
-
|
|
29483
|
+
_context8.next = 33;
|
|
29463
29484
|
break;
|
|
29464
29485
|
case 26:
|
|
29465
|
-
|
|
29466
|
-
|
|
29467
|
-
if (!(
|
|
29468
|
-
|
|
29486
|
+
_context8.prev = 26;
|
|
29487
|
+
_context8.t1 = _context8["catch"](18);
|
|
29488
|
+
if (!(_context8.t1 instanceof errors/* AccountRequiresMemoError */.Cu)) {
|
|
29489
|
+
_context8.next = 30;
|
|
29469
29490
|
break;
|
|
29470
29491
|
}
|
|
29471
|
-
throw
|
|
29492
|
+
throw _context8.t1;
|
|
29472
29493
|
case 30:
|
|
29473
|
-
if (
|
|
29474
|
-
|
|
29494
|
+
if (_context8.t1 instanceof errors/* NotFoundError */.m_) {
|
|
29495
|
+
_context8.next = 32;
|
|
29475
29496
|
break;
|
|
29476
29497
|
}
|
|
29477
|
-
throw
|
|
29498
|
+
throw _context8.t1;
|
|
29478
29499
|
case 32:
|
|
29479
|
-
return
|
|
29500
|
+
return _context8.abrupt("continue", 33);
|
|
29480
29501
|
case 33:
|
|
29481
29502
|
i += 1;
|
|
29482
|
-
|
|
29503
|
+
_context8.next = 5;
|
|
29483
29504
|
break;
|
|
29484
29505
|
case 36:
|
|
29485
29506
|
case "end":
|
|
29486
|
-
return
|
|
29507
|
+
return _context8.stop();
|
|
29487
29508
|
}
|
|
29488
|
-
},
|
|
29509
|
+
}, _callee8, this, [[18, 26]]);
|
|
29489
29510
|
}));
|
|
29490
29511
|
function checkMemoRequired(_x5) {
|
|
29491
29512
|
return _checkMemoRequired.apply(this, arguments);
|
|
@@ -29519,7 +29540,321 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
29519
29540
|
});
|
|
29520
29541
|
|
|
29521
29542
|
;// ./node_modules/feaxios/dist/index.mjs
|
|
29522
|
-
|
|
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
|
+
|
|
29523
29858
|
// EXTERNAL MODULE: ./src/http-client/types.ts
|
|
29524
29859
|
var types = __webpack_require__(5798);
|
|
29525
29860
|
;// ./src/http-client/fetch-client.ts
|
|
@@ -29577,7 +29912,7 @@ function createFetchClient() {
|
|
|
29577
29912
|
var defaults = _objectSpread(_objectSpread({}, fetchConfig), {}, {
|
|
29578
29913
|
headers: fetchConfig.headers || {}
|
|
29579
29914
|
});
|
|
29580
|
-
var instance =
|
|
29915
|
+
var instance = src_default.create(defaults);
|
|
29581
29916
|
var requestInterceptors = new InterceptorManager();
|
|
29582
29917
|
var responseInterceptors = new InterceptorManager();
|
|
29583
29918
|
var httpClient = {
|
|
@@ -29941,7 +30276,7 @@ var lib = __webpack_require__(356);
|
|
|
29941
30276
|
var http_client = __webpack_require__(6371);
|
|
29942
30277
|
;// ./src/rpc/axios.ts
|
|
29943
30278
|
|
|
29944
|
-
var version = "13.
|
|
30279
|
+
var version = "13.1.0";
|
|
29945
30280
|
var AxiosClient = (0,http_client/* create */.vt)({
|
|
29946
30281
|
headers: {
|
|
29947
30282
|
'X-Client-Name': 'js-soroban-client',
|
|
@@ -30692,7 +31027,7 @@ var RpcServer = function () {
|
|
|
30692
31027
|
key: "requestAirdrop",
|
|
30693
31028
|
value: (function () {
|
|
30694
31029
|
var _requestAirdrop = server_asyncToGenerator(server_regeneratorRuntime().mark(function _callee22(address, friendbotUrl) {
|
|
30695
|
-
var account, response, meta, sequence, _error$response, _error$response$detai;
|
|
31030
|
+
var account, response, meta, txMeta, sequence, _error$response, _error$response$detai;
|
|
30696
31031
|
return server_regeneratorRuntime().wrap(function _callee22$(_context22) {
|
|
30697
31032
|
while (1) switch (_context22.prev = _context22.next) {
|
|
30698
31033
|
case 0:
|
|
@@ -30719,28 +31054,47 @@ var RpcServer = function () {
|
|
|
30719
31054
|
return axios.post("".concat(friendbotUrl, "?addr=").concat(encodeURIComponent(account)));
|
|
30720
31055
|
case 12:
|
|
30721
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:
|
|
30722
31075
|
meta = lib.xdr.TransactionMeta.fromXDR(response.data.result_meta_xdr, 'base64');
|
|
31076
|
+
case 23:
|
|
30723
31077
|
sequence = findCreatedAccountSequenceInTransactionMeta(meta);
|
|
30724
31078
|
return _context22.abrupt("return", new lib.Account(account, sequence));
|
|
30725
|
-
case
|
|
30726
|
-
_context22.prev =
|
|
31079
|
+
case 27:
|
|
31080
|
+
_context22.prev = 27;
|
|
30727
31081
|
_context22.t1 = _context22["catch"](9);
|
|
30728
31082
|
if (!(((_error$response = _context22.t1.response) === null || _error$response === void 0 ? void 0 : _error$response.status) === 400)) {
|
|
30729
|
-
_context22.next =
|
|
31083
|
+
_context22.next = 32;
|
|
30730
31084
|
break;
|
|
30731
31085
|
}
|
|
30732
31086
|
if (!((_error$response$detai = _context22.t1.response.detail) !== null && _error$response$detai !== void 0 && _error$response$detai.includes('createAccountAlreadyExist'))) {
|
|
30733
|
-
_context22.next =
|
|
31087
|
+
_context22.next = 32;
|
|
30734
31088
|
break;
|
|
30735
31089
|
}
|
|
30736
31090
|
return _context22.abrupt("return", this.getAccount(account));
|
|
30737
|
-
case
|
|
31091
|
+
case 32:
|
|
30738
31092
|
throw _context22.t1;
|
|
30739
|
-
case
|
|
31093
|
+
case 33:
|
|
30740
31094
|
case "end":
|
|
30741
31095
|
return _context22.stop();
|
|
30742
31096
|
}
|
|
30743
|
-
}, _callee22, this, [[9,
|
|
31097
|
+
}, _callee22, this, [[9, 27]]);
|
|
30744
31098
|
}));
|
|
30745
31099
|
function requestAirdrop(_x21, _x22) {
|
|
30746
31100
|
return _requestAirdrop.apply(this, arguments);
|
|
@@ -30953,6 +31307,7 @@ function parseRawEvents(raw) {
|
|
|
30953
31307
|
var _raw$events;
|
|
30954
31308
|
return {
|
|
30955
31309
|
latestLedger: raw.latestLedger,
|
|
31310
|
+
cursor: raw.cursor,
|
|
30956
31311
|
events: ((_raw$events = raw.events) !== null && _raw$events !== void 0 ? _raw$events : []).map(function (evt) {
|
|
30957
31312
|
var clone = _objectSpread({}, evt);
|
|
30958
31313
|
delete clone.contractId;
|
|
@@ -37201,6 +37556,101 @@ module.exports = {
|
|
|
37201
37556
|
}
|
|
37202
37557
|
|
|
37203
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
|
+
|
|
37204
37654
|
/***/ }),
|
|
37205
37655
|
|
|
37206
37656
|
/***/ 8075:
|
|
@@ -37232,34 +37682,23 @@ module.exports = function callBoundIntrinsic(name, allowMissing) {
|
|
|
37232
37682
|
"use strict";
|
|
37233
37683
|
|
|
37234
37684
|
|
|
37235
|
-
var bind = __webpack_require__(6743);
|
|
37236
|
-
var GetIntrinsic = __webpack_require__(453);
|
|
37237
37685
|
var setFunctionLength = __webpack_require__(6897);
|
|
37238
37686
|
|
|
37239
|
-
var $TypeError = __webpack_require__(9675);
|
|
37240
|
-
var $apply = GetIntrinsic('%Function.prototype.apply%');
|
|
37241
|
-
var $call = GetIntrinsic('%Function.prototype.call%');
|
|
37242
|
-
var $reflectApply = GetIntrinsic('%Reflect.apply%', true) || bind.call($call, $apply);
|
|
37243
|
-
|
|
37244
37687
|
var $defineProperty = __webpack_require__(655);
|
|
37245
|
-
|
|
37688
|
+
|
|
37689
|
+
var callBindBasic = __webpack_require__(3126);
|
|
37690
|
+
var applyBind = __webpack_require__(2205);
|
|
37246
37691
|
|
|
37247
37692
|
module.exports = function callBind(originalFunction) {
|
|
37248
|
-
|
|
37249
|
-
|
|
37250
|
-
}
|
|
37251
|
-
var func = $reflectApply(bind, $call, arguments);
|
|
37693
|
+
var func = callBindBasic(arguments);
|
|
37694
|
+
var adjustedLength = originalFunction.length - (arguments.length - 1);
|
|
37252
37695
|
return setFunctionLength(
|
|
37253
37696
|
func,
|
|
37254
|
-
1 +
|
|
37697
|
+
1 + (adjustedLength > 0 ? adjustedLength : 0),
|
|
37255
37698
|
true
|
|
37256
37699
|
);
|
|
37257
37700
|
};
|
|
37258
37701
|
|
|
37259
|
-
var applyBind = function applyBind() {
|
|
37260
|
-
return $reflectApply(bind, $apply, arguments);
|
|
37261
|
-
};
|
|
37262
|
-
|
|
37263
37702
|
if ($defineProperty) {
|
|
37264
37703
|
$defineProperty(module.exports, 'apply', { value: applyBind });
|
|
37265
37704
|
} else {
|
|
@@ -37267,6 +37706,32 @@ if ($defineProperty) {
|
|
|
37267
37706
|
}
|
|
37268
37707
|
|
|
37269
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
|
+
|
|
37270
37735
|
/***/ }),
|
|
37271
37736
|
|
|
37272
37737
|
/***/ 41:
|
|
@@ -37333,16 +37798,45 @@ module.exports = function defineDataProperty(
|
|
|
37333
37798
|
|
|
37334
37799
|
/***/ }),
|
|
37335
37800
|
|
|
37336
|
-
/***/
|
|
37801
|
+
/***/ 7176:
|
|
37337
37802
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
37338
37803
|
|
|
37339
37804
|
"use strict";
|
|
37340
37805
|
|
|
37341
37806
|
|
|
37342
|
-
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
|
+
|
|
37343
37837
|
|
|
37344
37838
|
/** @type {import('.')} */
|
|
37345
|
-
var $defineProperty =
|
|
37839
|
+
var $defineProperty = Object.defineProperty || false;
|
|
37346
37840
|
if ($defineProperty) {
|
|
37347
37841
|
try {
|
|
37348
37842
|
$defineProperty({}, 'a', { value: 1 });
|
|
@@ -37439,6 +37933,18 @@ module.exports = TypeError;
|
|
|
37439
37933
|
module.exports = URIError;
|
|
37440
37934
|
|
|
37441
37935
|
|
|
37936
|
+
/***/ }),
|
|
37937
|
+
|
|
37938
|
+
/***/ 9612:
|
|
37939
|
+
/***/ ((module) => {
|
|
37940
|
+
|
|
37941
|
+
"use strict";
|
|
37942
|
+
|
|
37943
|
+
|
|
37944
|
+
/** @type {import('.')} */
|
|
37945
|
+
module.exports = Object;
|
|
37946
|
+
|
|
37947
|
+
|
|
37442
37948
|
/***/ }),
|
|
37443
37949
|
|
|
37444
37950
|
/***/ 7007:
|
|
@@ -38632,6 +39138,8 @@ module.exports = Function.prototype.bind || implementation;
|
|
|
38632
39138
|
|
|
38633
39139
|
var undefined;
|
|
38634
39140
|
|
|
39141
|
+
var $Object = __webpack_require__(9612);
|
|
39142
|
+
|
|
38635
39143
|
var $Error = __webpack_require__(9383);
|
|
38636
39144
|
var $EvalError = __webpack_require__(1237);
|
|
38637
39145
|
var $RangeError = __webpack_require__(9290);
|
|
@@ -38640,6 +39148,12 @@ var $SyntaxError = __webpack_require__(8068);
|
|
|
38640
39148
|
var $TypeError = __webpack_require__(9675);
|
|
38641
39149
|
var $URIError = __webpack_require__(5345);
|
|
38642
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
|
+
|
|
38643
39157
|
var $Function = Function;
|
|
38644
39158
|
|
|
38645
39159
|
// eslint-disable-next-line consistent-return
|
|
@@ -38649,14 +39163,8 @@ var getEvalledConstructor = function (expressionSyntax) {
|
|
|
38649
39163
|
} catch (e) {}
|
|
38650
39164
|
};
|
|
38651
39165
|
|
|
38652
|
-
var $gOPD =
|
|
38653
|
-
|
|
38654
|
-
try {
|
|
38655
|
-
$gOPD({}, '');
|
|
38656
|
-
} catch (e) {
|
|
38657
|
-
$gOPD = null; // this is IE 8, which has a broken gOPD
|
|
38658
|
-
}
|
|
38659
|
-
}
|
|
39166
|
+
var $gOPD = __webpack_require__(5795);
|
|
39167
|
+
var $defineProperty = __webpack_require__(655);
|
|
38660
39168
|
|
|
38661
39169
|
var throwTypeError = function () {
|
|
38662
39170
|
throw new $TypeError();
|
|
@@ -38679,13 +39187,14 @@ var ThrowTypeError = $gOPD
|
|
|
38679
39187
|
: throwTypeError;
|
|
38680
39188
|
|
|
38681
39189
|
var hasSymbols = __webpack_require__(4039)();
|
|
38682
|
-
var
|
|
39190
|
+
var getDunderProto = __webpack_require__(7176);
|
|
38683
39191
|
|
|
38684
|
-
var getProto =
|
|
38685
|
-
|
|
38686
|
-
|
|
38687
|
-
|
|
38688
|
-
);
|
|
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);
|
|
38689
39198
|
|
|
38690
39199
|
var needsEval = {};
|
|
38691
39200
|
|
|
@@ -38732,7 +39241,8 @@ var INTRINSICS = {
|
|
|
38732
39241
|
'%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols || !getProto ? undefined : getProto(new Map()[Symbol.iterator]()),
|
|
38733
39242
|
'%Math%': Math,
|
|
38734
39243
|
'%Number%': Number,
|
|
38735
|
-
'%Object%': Object,
|
|
39244
|
+
'%Object%': $Object,
|
|
39245
|
+
'%Object.getOwnPropertyDescriptor%': $gOPD,
|
|
38736
39246
|
'%parseFloat%': parseFloat,
|
|
38737
39247
|
'%parseInt%': parseInt,
|
|
38738
39248
|
'%Promise%': typeof Promise === 'undefined' ? undefined : Promise,
|
|
@@ -38758,7 +39268,16 @@ var INTRINSICS = {
|
|
|
38758
39268
|
'%URIError%': $URIError,
|
|
38759
39269
|
'%WeakMap%': typeof WeakMap === 'undefined' ? undefined : WeakMap,
|
|
38760
39270
|
'%WeakRef%': typeof WeakRef === 'undefined' ? undefined : WeakRef,
|
|
38761
|
-
'%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
|
|
38762
39281
|
};
|
|
38763
39282
|
|
|
38764
39283
|
if (getProto) {
|
|
@@ -38853,11 +39372,11 @@ var LEGACY_ALIASES = {
|
|
|
38853
39372
|
|
|
38854
39373
|
var bind = __webpack_require__(6743);
|
|
38855
39374
|
var hasOwn = __webpack_require__(9957);
|
|
38856
|
-
var $concat = bind.call(
|
|
38857
|
-
var $spliceApply = bind.call(
|
|
38858
|
-
var $replace = bind.call(
|
|
38859
|
-
var $strSlice = bind.call(
|
|
38860
|
-
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);
|
|
38861
39380
|
|
|
38862
39381
|
/* adapted from https://github.com/lodash/lodash/blob/4.17.15/dist/lodash.js#L6735-L6744 */
|
|
38863
39382
|
var rePropName = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g;
|
|
@@ -38989,6 +39508,18 @@ module.exports = function GetIntrinsic(name, allowMissing) {
|
|
|
38989
39508
|
};
|
|
38990
39509
|
|
|
38991
39510
|
|
|
39511
|
+
/***/ }),
|
|
39512
|
+
|
|
39513
|
+
/***/ 6549:
|
|
39514
|
+
/***/ ((module) => {
|
|
39515
|
+
|
|
39516
|
+
"use strict";
|
|
39517
|
+
|
|
39518
|
+
|
|
39519
|
+
/** @type {import('./gOPD')} */
|
|
39520
|
+
module.exports = Object.getOwnPropertyDescriptor;
|
|
39521
|
+
|
|
39522
|
+
|
|
38992
39523
|
/***/ }),
|
|
38993
39524
|
|
|
38994
39525
|
/***/ 5795:
|
|
@@ -38997,9 +39528,8 @@ module.exports = function GetIntrinsic(name, allowMissing) {
|
|
|
38997
39528
|
"use strict";
|
|
38998
39529
|
|
|
38999
39530
|
|
|
39000
|
-
|
|
39001
|
-
|
|
39002
|
-
var $gOPD = GetIntrinsic('%Object.getOwnPropertyDescriptor%', true);
|
|
39531
|
+
/** @type {import('.')} */
|
|
39532
|
+
var $gOPD = __webpack_require__(6549);
|
|
39003
39533
|
|
|
39004
39534
|
if ($gOPD) {
|
|
39005
39535
|
try {
|
|
@@ -39043,29 +39573,6 @@ hasPropertyDescriptors.hasArrayLengthDefineBug = function hasArrayLengthDefineBu
|
|
|
39043
39573
|
module.exports = hasPropertyDescriptors;
|
|
39044
39574
|
|
|
39045
39575
|
|
|
39046
|
-
/***/ }),
|
|
39047
|
-
|
|
39048
|
-
/***/ 24:
|
|
39049
|
-
/***/ ((module) => {
|
|
39050
|
-
|
|
39051
|
-
"use strict";
|
|
39052
|
-
|
|
39053
|
-
|
|
39054
|
-
var test = {
|
|
39055
|
-
__proto__: null,
|
|
39056
|
-
foo: {}
|
|
39057
|
-
};
|
|
39058
|
-
|
|
39059
|
-
var $Object = Object;
|
|
39060
|
-
|
|
39061
|
-
/** @type {import('.')} */
|
|
39062
|
-
module.exports = function hasProto() {
|
|
39063
|
-
// @ts-expect-error: TS errors on an inherited property for some reason
|
|
39064
|
-
return { __proto__: test }.foo === test.foo
|
|
39065
|
-
&& !(test instanceof $Object);
|
|
39066
|
-
};
|
|
39067
|
-
|
|
39068
|
-
|
|
39069
39576
|
/***/ }),
|
|
39070
39577
|
|
|
39071
39578
|
/***/ 4039:
|
|
@@ -39077,6 +39584,7 @@ module.exports = function hasProto() {
|
|
|
39077
39584
|
var origSymbol = typeof Symbol !== 'undefined' && Symbol;
|
|
39078
39585
|
var hasSymbolSham = __webpack_require__(1333);
|
|
39079
39586
|
|
|
39587
|
+
/** @type {import('.')} */
|
|
39080
39588
|
module.exports = function hasNativeSymbols() {
|
|
39081
39589
|
if (typeof origSymbol !== 'function') { return false; }
|
|
39082
39590
|
if (typeof Symbol !== 'function') { return false; }
|
|
@@ -39095,11 +39603,13 @@ module.exports = function hasNativeSymbols() {
|
|
|
39095
39603
|
"use strict";
|
|
39096
39604
|
|
|
39097
39605
|
|
|
39606
|
+
/** @type {import('./shams')} */
|
|
39098
39607
|
/* eslint complexity: [2, 18], max-statements: [2, 33] */
|
|
39099
39608
|
module.exports = function hasSymbols() {
|
|
39100
39609
|
if (typeof Symbol !== 'function' || typeof Object.getOwnPropertySymbols !== 'function') { return false; }
|
|
39101
39610
|
if (typeof Symbol.iterator === 'symbol') { return true; }
|
|
39102
39611
|
|
|
39612
|
+
/** @type {{ [k in symbol]?: unknown }} */
|
|
39103
39613
|
var obj = {};
|
|
39104
39614
|
var sym = Symbol('test');
|
|
39105
39615
|
var symObj = Object(sym);
|
|
@@ -39118,7 +39628,7 @@ module.exports = function hasSymbols() {
|
|
|
39118
39628
|
|
|
39119
39629
|
var symVal = 42;
|
|
39120
39630
|
obj[sym] = symVal;
|
|
39121
|
-
for (
|
|
39631
|
+
for (var _ in obj) { return false; } // eslint-disable-line no-restricted-syntax, no-unreachable-loop
|
|
39122
39632
|
if (typeof Object.keys === 'function' && Object.keys(obj).length !== 0) { return false; }
|
|
39123
39633
|
|
|
39124
39634
|
if (typeof Object.getOwnPropertyNames === 'function' && Object.getOwnPropertyNames(obj).length !== 0) { return false; }
|
|
@@ -39129,7 +39639,8 @@ module.exports = function hasSymbols() {
|
|
|
39129
39639
|
if (!Object.prototype.propertyIsEnumerable.call(obj, sym)) { return false; }
|
|
39130
39640
|
|
|
39131
39641
|
if (typeof Object.getOwnPropertyDescriptor === 'function') {
|
|
39132
|
-
|
|
39642
|
+
// eslint-disable-next-line no-extra-parens
|
|
39643
|
+
var descriptor = /** @type {PropertyDescriptor} */ (Object.getOwnPropertyDescriptor(obj, sym));
|
|
39133
39644
|
if (descriptor.value !== symVal || descriptor.enumerable !== true) { return false; }
|
|
39134
39645
|
}
|
|
39135
39646
|
|
|
@@ -39342,35 +39853,46 @@ if (typeof Object.create === 'function') {
|
|
|
39342
39853
|
|
|
39343
39854
|
|
|
39344
39855
|
var hasToStringTag = __webpack_require__(9092)();
|
|
39345
|
-
var callBound = __webpack_require__(
|
|
39856
|
+
var callBound = __webpack_require__(6556);
|
|
39346
39857
|
|
|
39347
39858
|
var $toString = callBound('Object.prototype.toString');
|
|
39348
39859
|
|
|
39860
|
+
/** @type {import('.')} */
|
|
39349
39861
|
var isStandardArguments = function isArguments(value) {
|
|
39350
|
-
if (
|
|
39862
|
+
if (
|
|
39863
|
+
hasToStringTag
|
|
39864
|
+
&& value
|
|
39865
|
+
&& typeof value === 'object'
|
|
39866
|
+
&& Symbol.toStringTag in value
|
|
39867
|
+
) {
|
|
39351
39868
|
return false;
|
|
39352
39869
|
}
|
|
39353
39870
|
return $toString(value) === '[object Arguments]';
|
|
39354
39871
|
};
|
|
39355
39872
|
|
|
39873
|
+
/** @type {import('.')} */
|
|
39356
39874
|
var isLegacyArguments = function isArguments(value) {
|
|
39357
39875
|
if (isStandardArguments(value)) {
|
|
39358
39876
|
return true;
|
|
39359
39877
|
}
|
|
39360
|
-
return value !== null
|
|
39361
|
-
typeof value === 'object'
|
|
39362
|
-
|
|
39363
|
-
value.length
|
|
39364
|
-
|
|
39365
|
-
$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]';
|
|
39366
39886
|
};
|
|
39367
39887
|
|
|
39368
39888
|
var supportsStandardArguments = (function () {
|
|
39369
39889
|
return isStandardArguments(arguments);
|
|
39370
39890
|
}());
|
|
39371
39891
|
|
|
39892
|
+
// @ts-expect-error TODO make this not error
|
|
39372
39893
|
isStandardArguments.isLegacyArguments = isLegacyArguments; // for tests
|
|
39373
39894
|
|
|
39895
|
+
/** @type {import('.')} */
|
|
39374
39896
|
module.exports = supportsStandardArguments ? isStandardArguments : isLegacyArguments;
|
|
39375
39897
|
|
|
39376
39898
|
|
|
@@ -39545,6 +40067,66 @@ module.exports = function isTypedArray(value) {
|
|
|
39545
40067
|
};
|
|
39546
40068
|
|
|
39547
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
|
+
|
|
39548
40130
|
/***/ }),
|
|
39549
40131
|
|
|
39550
40132
|
/***/ 8859:
|
|
@@ -40261,7 +40843,8 @@ var parseValues = function parseQueryStringValues(str, options) {
|
|
|
40261
40843
|
var bracketEqualsPos = part.indexOf(']=');
|
|
40262
40844
|
var pos = bracketEqualsPos === -1 ? part.indexOf('=') : bracketEqualsPos + 1;
|
|
40263
40845
|
|
|
40264
|
-
var key
|
|
40846
|
+
var key;
|
|
40847
|
+
var val;
|
|
40265
40848
|
if (pos === -1) {
|
|
40266
40849
|
key = options.decoder(part, defaults.decoder, charset, 'key');
|
|
40267
40850
|
val = options.strictNullHandling ? null : '';
|
|
@@ -40276,7 +40859,7 @@ var parseValues = function parseQueryStringValues(str, options) {
|
|
|
40276
40859
|
}
|
|
40277
40860
|
|
|
40278
40861
|
if (val && options.interpretNumericEntities && charset === 'iso-8859-1') {
|
|
40279
|
-
val = interpretNumericEntities(val);
|
|
40862
|
+
val = interpretNumericEntities(String(val));
|
|
40280
40863
|
}
|
|
40281
40864
|
|
|
40282
40865
|
if (part.indexOf('[]=') > -1) {
|
|
@@ -40306,7 +40889,7 @@ var parseObject = function (chain, val, options, valuesParsed) {
|
|
|
40306
40889
|
? []
|
|
40307
40890
|
: [].concat(leaf);
|
|
40308
40891
|
} else {
|
|
40309
|
-
obj = options.plainObjects ?
|
|
40892
|
+
obj = options.plainObjects ? { __proto__: null } : {};
|
|
40310
40893
|
var cleanRoot = root.charAt(0) === '[' && root.charAt(root.length - 1) === ']' ? root.slice(1, -1) : root;
|
|
40311
40894
|
var decodedRoot = options.decodeDotInKeys ? cleanRoot.replace(/%2E/g, '.') : cleanRoot;
|
|
40312
40895
|
var index = parseInt(decodedRoot, 10);
|
|
@@ -40448,11 +41031,11 @@ module.exports = function (str, opts) {
|
|
|
40448
41031
|
var options = normalizeParseOptions(opts);
|
|
40449
41032
|
|
|
40450
41033
|
if (str === '' || str === null || typeof str === 'undefined') {
|
|
40451
|
-
return options.plainObjects ?
|
|
41034
|
+
return options.plainObjects ? { __proto__: null } : {};
|
|
40452
41035
|
}
|
|
40453
41036
|
|
|
40454
41037
|
var tempObj = typeof str === 'string' ? parseValues(str, options) : str;
|
|
40455
|
-
var obj = options.plainObjects ?
|
|
41038
|
+
var obj = options.plainObjects ? { __proto__: null } : {};
|
|
40456
41039
|
|
|
40457
41040
|
// Iterate over the keys and setup the new object
|
|
40458
41041
|
|
|
@@ -40513,11 +41096,13 @@ var defaults = {
|
|
|
40513
41096
|
arrayFormat: 'indices',
|
|
40514
41097
|
charset: 'utf-8',
|
|
40515
41098
|
charsetSentinel: false,
|
|
41099
|
+
commaRoundTrip: false,
|
|
40516
41100
|
delimiter: '&',
|
|
40517
41101
|
encode: true,
|
|
40518
41102
|
encodeDotInKeys: false,
|
|
40519
41103
|
encoder: utils.encode,
|
|
40520
41104
|
encodeValuesOnly: false,
|
|
41105
|
+
filter: void undefined,
|
|
40521
41106
|
format: defaultFormat,
|
|
40522
41107
|
formatter: formats.formatters[defaultFormat],
|
|
40523
41108
|
// deprecated
|
|
@@ -40629,7 +41214,7 @@ var stringify = function stringify(
|
|
|
40629
41214
|
objKeys = sort ? keys.sort(sort) : keys;
|
|
40630
41215
|
}
|
|
40631
41216
|
|
|
40632
|
-
var encodedPrefix = encodeDotInKeys ? prefix.replace(/\./g, '%2E') : prefix;
|
|
41217
|
+
var encodedPrefix = encodeDotInKeys ? String(prefix).replace(/\./g, '%2E') : String(prefix);
|
|
40633
41218
|
|
|
40634
41219
|
var adjustedPrefix = commaRoundTrip && isArray(obj) && obj.length === 1 ? encodedPrefix + '[]' : encodedPrefix;
|
|
40635
41220
|
|
|
@@ -40639,13 +41224,15 @@ var stringify = function stringify(
|
|
|
40639
41224
|
|
|
40640
41225
|
for (var j = 0; j < objKeys.length; ++j) {
|
|
40641
41226
|
var key = objKeys[j];
|
|
40642
|
-
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];
|
|
40643
41230
|
|
|
40644
41231
|
if (skipNulls && value === null) {
|
|
40645
41232
|
continue;
|
|
40646
41233
|
}
|
|
40647
41234
|
|
|
40648
|
-
var encodedKey = allowDots && encodeDotInKeys ? key.replace(/\./g, '%2E') : key;
|
|
41235
|
+
var encodedKey = allowDots && encodeDotInKeys ? String(key).replace(/\./g, '%2E') : String(key);
|
|
40649
41236
|
var keyPrefix = isArray(obj)
|
|
40650
41237
|
? typeof generateArrayPrefix === 'function' ? generateArrayPrefix(adjustedPrefix, encodedKey) : adjustedPrefix
|
|
40651
41238
|
: adjustedPrefix + (allowDots ? '.' + encodedKey : '[' + encodedKey + ']');
|
|
@@ -40736,7 +41323,7 @@ var normalizeStringifyOptions = function normalizeStringifyOptions(opts) {
|
|
|
40736
41323
|
arrayFormat: arrayFormat,
|
|
40737
41324
|
charset: charset,
|
|
40738
41325
|
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
|
40739
|
-
commaRoundTrip: opts.commaRoundTrip,
|
|
41326
|
+
commaRoundTrip: !!opts.commaRoundTrip,
|
|
40740
41327
|
delimiter: typeof opts.delimiter === 'undefined' ? defaults.delimiter : opts.delimiter,
|
|
40741
41328
|
encode: typeof opts.encode === 'boolean' ? opts.encode : defaults.encode,
|
|
40742
41329
|
encodeDotInKeys: typeof opts.encodeDotInKeys === 'boolean' ? opts.encodeDotInKeys : defaults.encodeDotInKeys,
|
|
@@ -40787,12 +41374,13 @@ module.exports = function (object, opts) {
|
|
|
40787
41374
|
var sideChannel = getSideChannel();
|
|
40788
41375
|
for (var i = 0; i < objKeys.length; ++i) {
|
|
40789
41376
|
var key = objKeys[i];
|
|
41377
|
+
var value = obj[key];
|
|
40790
41378
|
|
|
40791
|
-
if (options.skipNulls &&
|
|
41379
|
+
if (options.skipNulls && value === null) {
|
|
40792
41380
|
continue;
|
|
40793
41381
|
}
|
|
40794
41382
|
pushToArray(keys, stringify(
|
|
40795
|
-
|
|
41383
|
+
value,
|
|
40796
41384
|
key,
|
|
40797
41385
|
generateArrayPrefix,
|
|
40798
41386
|
commaRoundTrip,
|
|
@@ -40872,7 +41460,7 @@ var compactQueue = function compactQueue(queue) {
|
|
|
40872
41460
|
};
|
|
40873
41461
|
|
|
40874
41462
|
var arrayToObject = function arrayToObject(source, options) {
|
|
40875
|
-
var obj = options && options.plainObjects ?
|
|
41463
|
+
var obj = options && options.plainObjects ? { __proto__: null } : {};
|
|
40876
41464
|
for (var i = 0; i < source.length; ++i) {
|
|
40877
41465
|
if (typeof source[i] !== 'undefined') {
|
|
40878
41466
|
obj[i] = source[i];
|
|
@@ -40888,11 +41476,14 @@ var merge = function merge(target, source, options) {
|
|
|
40888
41476
|
return target;
|
|
40889
41477
|
}
|
|
40890
41478
|
|
|
40891
|
-
if (typeof source !== 'object') {
|
|
41479
|
+
if (typeof source !== 'object' && typeof source !== 'function') {
|
|
40892
41480
|
if (isArray(target)) {
|
|
40893
41481
|
target.push(source);
|
|
40894
41482
|
} else if (target && typeof target === 'object') {
|
|
40895
|
-
if (
|
|
41483
|
+
if (
|
|
41484
|
+
(options && (options.plainObjects || options.allowPrototypes))
|
|
41485
|
+
|| !has.call(Object.prototype, source)
|
|
41486
|
+
) {
|
|
40896
41487
|
target[source] = true;
|
|
40897
41488
|
}
|
|
40898
41489
|
} else {
|
|
@@ -40946,7 +41537,7 @@ var assign = function assignSingleSource(target, source) {
|
|
|
40946
41537
|
}, target);
|
|
40947
41538
|
};
|
|
40948
41539
|
|
|
40949
|
-
var decode = function (str,
|
|
41540
|
+
var decode = function (str, defaultDecoder, charset) {
|
|
40950
41541
|
var strWithoutPlus = str.replace(/\+/g, ' ');
|
|
40951
41542
|
if (charset === 'iso-8859-1') {
|
|
40952
41543
|
// unescape never throws, no try...catch needed:
|
|
@@ -45055,137 +45646,340 @@ module.exports = Sha512
|
|
|
45055
45646
|
|
|
45056
45647
|
/***/ }),
|
|
45057
45648
|
|
|
45058
|
-
/***/
|
|
45649
|
+
/***/ 4803:
|
|
45059
45650
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
45060
45651
|
|
|
45061
45652
|
"use strict";
|
|
45062
45653
|
|
|
45063
45654
|
|
|
45064
|
-
var GetIntrinsic = __webpack_require__(453);
|
|
45065
|
-
var callBound = __webpack_require__(8075);
|
|
45066
45655
|
var inspect = __webpack_require__(8859);
|
|
45067
45656
|
|
|
45068
45657
|
var $TypeError = __webpack_require__(9675);
|
|
45069
|
-
var $WeakMap = GetIntrinsic('%WeakMap%', true);
|
|
45070
|
-
var $Map = GetIntrinsic('%Map%', true);
|
|
45071
|
-
|
|
45072
|
-
var $weakMapGet = callBound('WeakMap.prototype.get', true);
|
|
45073
|
-
var $weakMapSet = callBound('WeakMap.prototype.set', true);
|
|
45074
|
-
var $weakMapHas = callBound('WeakMap.prototype.has', true);
|
|
45075
|
-
var $mapGet = callBound('Map.prototype.get', true);
|
|
45076
|
-
var $mapSet = callBound('Map.prototype.set', true);
|
|
45077
|
-
var $mapHas = callBound('Map.prototype.has', true);
|
|
45078
45658
|
|
|
45079
45659
|
/*
|
|
45080
45660
|
* This function traverses the list returning the node corresponding to the given key.
|
|
45081
45661
|
*
|
|
45082
|
-
* 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.
|
|
45083
45664
|
*/
|
|
45084
|
-
/** @type {import('.').listGetNode} */
|
|
45085
|
-
|
|
45665
|
+
/** @type {import('./list.d.ts').listGetNode} */
|
|
45666
|
+
// eslint-disable-next-line consistent-return
|
|
45667
|
+
var listGetNode = function (list, key, isDelete) {
|
|
45086
45668
|
/** @type {typeof list | NonNullable<(typeof list)['next']>} */
|
|
45087
45669
|
var prev = list;
|
|
45088
45670
|
/** @type {(typeof list)['next']} */
|
|
45089
45671
|
var curr;
|
|
45090
|
-
|
|
45672
|
+
// eslint-disable-next-line eqeqeq
|
|
45673
|
+
for (; (curr = prev.next) != null; prev = curr) {
|
|
45091
45674
|
if (curr.key === key) {
|
|
45092
45675
|
prev.next = curr.next;
|
|
45093
|
-
|
|
45094
|
-
|
|
45095
|
-
|
|
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
|
+
}
|
|
45096
45681
|
return curr;
|
|
45097
45682
|
}
|
|
45098
45683
|
}
|
|
45099
45684
|
};
|
|
45100
45685
|
|
|
45101
|
-
/** @type {import('.').listGet} */
|
|
45686
|
+
/** @type {import('./list.d.ts').listGet} */
|
|
45102
45687
|
var listGet = function (objects, key) {
|
|
45688
|
+
if (!objects) {
|
|
45689
|
+
return void undefined;
|
|
45690
|
+
}
|
|
45103
45691
|
var node = listGetNode(objects, key);
|
|
45104
45692
|
return node && node.value;
|
|
45105
45693
|
};
|
|
45106
|
-
/** @type {import('.').listSet} */
|
|
45694
|
+
/** @type {import('./list.d.ts').listSet} */
|
|
45107
45695
|
var listSet = function (objects, key, value) {
|
|
45108
45696
|
var node = listGetNode(objects, key);
|
|
45109
45697
|
if (node) {
|
|
45110
45698
|
node.value = value;
|
|
45111
45699
|
} else {
|
|
45112
45700
|
// Prepend the new node to the beginning of the list
|
|
45113
|
-
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
|
|
45114
45702
|
key: key,
|
|
45115
45703
|
next: objects.next,
|
|
45116
45704
|
value: value
|
|
45117
45705
|
});
|
|
45118
45706
|
}
|
|
45119
45707
|
};
|
|
45120
|
-
/** @type {import('.').listHas} */
|
|
45708
|
+
/** @type {import('./list.d.ts').listHas} */
|
|
45121
45709
|
var listHas = function (objects, key) {
|
|
45710
|
+
if (!objects) {
|
|
45711
|
+
return false;
|
|
45712
|
+
}
|
|
45122
45713
|
return !!listGetNode(objects, key);
|
|
45123
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
|
+
};
|
|
45124
45722
|
|
|
45125
45723
|
/** @type {import('.')} */
|
|
45126
|
-
module.exports = function
|
|
45127
|
-
/** @
|
|
45128
|
-
/** @
|
|
45129
|
-
/** @
|
|
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;
|
|
45130
45730
|
|
|
45131
|
-
/** @type {
|
|
45731
|
+
/** @type {Channel} */
|
|
45132
45732
|
var channel = {
|
|
45133
45733
|
assert: function (key) {
|
|
45134
45734
|
if (!channel.has(key)) {
|
|
45135
45735
|
throw new $TypeError('Side channel does not contain ' + inspect(key));
|
|
45136
45736
|
}
|
|
45137
45737
|
},
|
|
45138
|
-
|
|
45139
|
-
|
|
45140
|
-
|
|
45141
|
-
|
|
45142
|
-
|
|
45143
|
-
} else if ($Map) {
|
|
45144
|
-
if ($m) {
|
|
45145
|
-
return $mapGet($m, key);
|
|
45146
|
-
}
|
|
45147
|
-
} else {
|
|
45148
|
-
if ($o) { // eslint-disable-line no-lonely-if
|
|
45149
|
-
return listGet($o, key);
|
|
45150
|
-
}
|
|
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;
|
|
45151
45743
|
}
|
|
45744
|
+
return !!deletedNode;
|
|
45745
|
+
},
|
|
45746
|
+
get: function (key) {
|
|
45747
|
+
return listGet($o, key);
|
|
45152
45748
|
},
|
|
45153
45749
|
has: function (key) {
|
|
45154
|
-
|
|
45155
|
-
|
|
45156
|
-
|
|
45157
|
-
|
|
45158
|
-
|
|
45159
|
-
|
|
45160
|
-
|
|
45161
|
-
}
|
|
45162
|
-
}
|
|
45163
|
-
|
|
45164
|
-
|
|
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;
|
|
45165
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);
|
|
45166
45827
|
}
|
|
45167
45828
|
return false;
|
|
45168
45829
|
},
|
|
45169
45830
|
set: function (key, value) {
|
|
45170
|
-
if (
|
|
45171
|
-
|
|
45172
|
-
|
|
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));
|
|
45884
|
+
}
|
|
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
|
+
}
|
|
45173
45895
|
}
|
|
45174
|
-
|
|
45175
|
-
}
|
|
45176
|
-
|
|
45177
|
-
|
|
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
|
+
}
|
|
45178
45903
|
}
|
|
45179
|
-
$
|
|
45180
|
-
}
|
|
45181
|
-
|
|
45182
|
-
|
|
45183
|
-
$
|
|
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);
|
|
45184
45926
|
}
|
|
45185
|
-
listSet($o, key, value);
|
|
45186
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));
|
|
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);
|
|
45187
45980
|
}
|
|
45188
45981
|
};
|
|
45982
|
+
// @ts-expect-error TODO: figure out why this is erroring
|
|
45189
45983
|
return channel;
|
|
45190
45984
|
};
|
|
45191
45985
|
|