@smapiot/piral-cloud-node 1.14.1-pre.20240610.3 → 1.14.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.cjs.js +55 -55
- package/lib/index.d.ts +5 -2
- package/lib/index.esm.js +55 -55
- package/package.json +1 -1
package/lib/index.cjs.js
CHANGED
|
@@ -39,7 +39,6 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
39
39
|
typeof exports2 === "object" && typeof module2 !== "undefined" ? factory(exports2) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global2 = typeof globalThis !== "undefined" ? globalThis : global2 || self, factory(global2.WebStreamsPolyfill = {}));
|
|
40
40
|
})(exports2, function(exports3) {
|
|
41
41
|
"use strict";
|
|
42
|
-
const SymbolPolyfill = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? Symbol : (description) => `Symbol(${description})`;
|
|
43
42
|
function noop2() {
|
|
44
43
|
return void 0;
|
|
45
44
|
}
|
|
@@ -53,7 +52,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
53
52
|
value: name,
|
|
54
53
|
configurable: true
|
|
55
54
|
});
|
|
56
|
-
} catch (
|
|
55
|
+
} catch (_a2) {
|
|
57
56
|
}
|
|
58
57
|
}
|
|
59
58
|
const originalPromise = Promise;
|
|
@@ -198,11 +197,11 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
198
197
|
return front._elements[cursor];
|
|
199
198
|
}
|
|
200
199
|
}
|
|
201
|
-
const AbortSteps =
|
|
202
|
-
const ErrorSteps =
|
|
203
|
-
const CancelSteps =
|
|
204
|
-
const PullSteps =
|
|
205
|
-
const ReleaseSteps =
|
|
200
|
+
const AbortSteps = Symbol("[[AbortSteps]]");
|
|
201
|
+
const ErrorSteps = Symbol("[[ErrorSteps]]");
|
|
202
|
+
const CancelSteps = Symbol("[[CancelSteps]]");
|
|
203
|
+
const PullSteps = Symbol("[[PullSteps]]");
|
|
204
|
+
const ReleaseSteps = Symbol("[[ReleaseSteps]]");
|
|
206
205
|
function ReadableStreamReaderGenericInitialize(reader, stream) {
|
|
207
206
|
reader._ownerReadableStream = stream;
|
|
208
207
|
stream._reader = reader;
|
|
@@ -448,8 +447,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
448
447
|
setFunctionName(ReadableStreamDefaultReader.prototype.cancel, "cancel");
|
|
449
448
|
setFunctionName(ReadableStreamDefaultReader.prototype.read, "read");
|
|
450
449
|
setFunctionName(ReadableStreamDefaultReader.prototype.releaseLock, "releaseLock");
|
|
451
|
-
if (typeof
|
|
452
|
-
Object.defineProperty(ReadableStreamDefaultReader.prototype,
|
|
450
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
451
|
+
Object.defineProperty(ReadableStreamDefaultReader.prototype, Symbol.toStringTag, {
|
|
453
452
|
value: "ReadableStreamDefaultReader",
|
|
454
453
|
configurable: true
|
|
455
454
|
});
|
|
@@ -568,9 +567,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
568
567
|
return this._asyncIteratorImpl.return(value);
|
|
569
568
|
}
|
|
570
569
|
};
|
|
571
|
-
|
|
572
|
-
Object.setPrototypeOf(ReadableStreamAsyncIteratorPrototype, AsyncIteratorPrototype);
|
|
573
|
-
}
|
|
570
|
+
Object.setPrototypeOf(ReadableStreamAsyncIteratorPrototype, AsyncIteratorPrototype);
|
|
574
571
|
function AcquireReadableStreamAsyncIterator(stream, preventCancel) {
|
|
575
572
|
const reader = AcquireReadableStreamDefaultReader(stream);
|
|
576
573
|
const impl = new ReadableStreamAsyncIteratorImpl(reader, preventCancel);
|
|
@@ -587,7 +584,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
587
584
|
}
|
|
588
585
|
try {
|
|
589
586
|
return x2._asyncIteratorImpl instanceof ReadableStreamAsyncIteratorImpl;
|
|
590
|
-
} catch (
|
|
587
|
+
} catch (_a2) {
|
|
591
588
|
return false;
|
|
592
589
|
}
|
|
593
590
|
}
|
|
@@ -597,6 +594,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
597
594
|
const NumberIsNaN = Number.isNaN || function(x2) {
|
|
598
595
|
return x2 !== x2;
|
|
599
596
|
};
|
|
597
|
+
var _a, _b, _c;
|
|
600
598
|
function CreateArrayFromList(elements) {
|
|
601
599
|
return elements.slice();
|
|
602
600
|
}
|
|
@@ -642,7 +640,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
642
640
|
}
|
|
643
641
|
function CreateAsyncFromSyncIterator(syncIteratorRecord) {
|
|
644
642
|
const syncIterable = {
|
|
645
|
-
[
|
|
643
|
+
[Symbol.iterator]: () => syncIteratorRecord.iterator
|
|
646
644
|
};
|
|
647
645
|
const asyncIterator = async function* () {
|
|
648
646
|
return yield* syncIterable;
|
|
@@ -650,17 +648,18 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
650
648
|
const nextMethod = asyncIterator.next;
|
|
651
649
|
return { iterator: asyncIterator, nextMethod, done: false };
|
|
652
650
|
}
|
|
651
|
+
const SymbolAsyncIterator = (_c = (_a = Symbol.asyncIterator) !== null && _a !== void 0 ? _a : (_b = Symbol.for) === null || _b === void 0 ? void 0 : _b.call(Symbol, "Symbol.asyncIterator")) !== null && _c !== void 0 ? _c : "@@asyncIterator";
|
|
653
652
|
function GetIterator(obj, hint = "sync", method) {
|
|
654
653
|
if (method === void 0) {
|
|
655
654
|
if (hint === "async") {
|
|
656
|
-
method = GetMethod(obj,
|
|
655
|
+
method = GetMethod(obj, SymbolAsyncIterator);
|
|
657
656
|
if (method === void 0) {
|
|
658
|
-
const syncMethod = GetMethod(obj,
|
|
657
|
+
const syncMethod = GetMethod(obj, Symbol.iterator);
|
|
659
658
|
const syncIteratorRecord = GetIterator(obj, "sync", syncMethod);
|
|
660
659
|
return CreateAsyncFromSyncIterator(syncIteratorRecord);
|
|
661
660
|
}
|
|
662
661
|
} else {
|
|
663
|
-
method = GetMethod(obj,
|
|
662
|
+
method = GetMethod(obj, Symbol.iterator);
|
|
664
663
|
}
|
|
665
664
|
}
|
|
666
665
|
if (method === void 0) {
|
|
@@ -788,8 +787,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
788
787
|
});
|
|
789
788
|
setFunctionName(ReadableStreamBYOBRequest.prototype.respond, "respond");
|
|
790
789
|
setFunctionName(ReadableStreamBYOBRequest.prototype.respondWithNewView, "respondWithNewView");
|
|
791
|
-
if (typeof
|
|
792
|
-
Object.defineProperty(ReadableStreamBYOBRequest.prototype,
|
|
790
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
791
|
+
Object.defineProperty(ReadableStreamBYOBRequest.prototype, Symbol.toStringTag, {
|
|
793
792
|
value: "ReadableStreamBYOBRequest",
|
|
794
793
|
configurable: true
|
|
795
794
|
});
|
|
@@ -926,8 +925,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
926
925
|
setFunctionName(ReadableByteStreamController.prototype.close, "close");
|
|
927
926
|
setFunctionName(ReadableByteStreamController.prototype.enqueue, "enqueue");
|
|
928
927
|
setFunctionName(ReadableByteStreamController.prototype.error, "error");
|
|
929
|
-
if (typeof
|
|
930
|
-
Object.defineProperty(ReadableByteStreamController.prototype,
|
|
928
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
929
|
+
Object.defineProperty(ReadableByteStreamController.prototype, Symbol.toStringTag, {
|
|
931
930
|
value: "ReadableByteStreamController",
|
|
932
931
|
configurable: true
|
|
933
932
|
});
|
|
@@ -1426,9 +1425,9 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1426
1425
|
return mode;
|
|
1427
1426
|
}
|
|
1428
1427
|
function convertByobReadOptions(options, context) {
|
|
1429
|
-
var
|
|
1428
|
+
var _a2;
|
|
1430
1429
|
assertDictionary(options, context);
|
|
1431
|
-
const min = (
|
|
1430
|
+
const min = (_a2 = options === null || options === void 0 ? void 0 : options.min) !== null && _a2 !== void 0 ? _a2 : 1;
|
|
1432
1431
|
return {
|
|
1433
1432
|
min: convertUnsignedLongLongWithEnforceRange(min, `${context} has member 'min' that`)
|
|
1434
1433
|
};
|
|
@@ -1574,8 +1573,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1574
1573
|
setFunctionName(ReadableStreamBYOBReader.prototype.cancel, "cancel");
|
|
1575
1574
|
setFunctionName(ReadableStreamBYOBReader.prototype.read, "read");
|
|
1576
1575
|
setFunctionName(ReadableStreamBYOBReader.prototype.releaseLock, "releaseLock");
|
|
1577
|
-
if (typeof
|
|
1578
|
-
Object.defineProperty(ReadableStreamBYOBReader.prototype,
|
|
1576
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
1577
|
+
Object.defineProperty(ReadableStreamBYOBReader.prototype, Symbol.toStringTag, {
|
|
1579
1578
|
value: "ReadableStreamBYOBReader",
|
|
1580
1579
|
configurable: true
|
|
1581
1580
|
});
|
|
@@ -1685,7 +1684,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1685
1684
|
}
|
|
1686
1685
|
try {
|
|
1687
1686
|
return typeof value.aborted === "boolean";
|
|
1688
|
-
} catch (
|
|
1687
|
+
} catch (_a2) {
|
|
1689
1688
|
return false;
|
|
1690
1689
|
}
|
|
1691
1690
|
}
|
|
@@ -1785,8 +1784,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1785
1784
|
setFunctionName(WritableStream.prototype.abort, "abort");
|
|
1786
1785
|
setFunctionName(WritableStream.prototype.close, "close");
|
|
1787
1786
|
setFunctionName(WritableStream.prototype.getWriter, "getWriter");
|
|
1788
|
-
if (typeof
|
|
1789
|
-
Object.defineProperty(WritableStream.prototype,
|
|
1787
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
1788
|
+
Object.defineProperty(WritableStream.prototype, Symbol.toStringTag, {
|
|
1790
1789
|
value: "WritableStream",
|
|
1791
1790
|
configurable: true
|
|
1792
1791
|
});
|
|
@@ -1829,12 +1828,12 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1829
1828
|
return true;
|
|
1830
1829
|
}
|
|
1831
1830
|
function WritableStreamAbort(stream, reason) {
|
|
1832
|
-
var
|
|
1831
|
+
var _a2;
|
|
1833
1832
|
if (stream._state === "closed" || stream._state === "errored") {
|
|
1834
1833
|
return promiseResolvedWith(void 0);
|
|
1835
1834
|
}
|
|
1836
1835
|
stream._writableStreamController._abortReason = reason;
|
|
1837
|
-
(
|
|
1836
|
+
(_a2 = stream._writableStreamController._abortController) === null || _a2 === void 0 ? void 0 : _a2.abort(reason);
|
|
1838
1837
|
const state = stream._state;
|
|
1839
1838
|
if (state === "closed" || state === "errored") {
|
|
1840
1839
|
return promiseResolvedWith(void 0);
|
|
@@ -2157,8 +2156,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2157
2156
|
setFunctionName(WritableStreamDefaultWriter.prototype.close, "close");
|
|
2158
2157
|
setFunctionName(WritableStreamDefaultWriter.prototype.releaseLock, "releaseLock");
|
|
2159
2158
|
setFunctionName(WritableStreamDefaultWriter.prototype.write, "write");
|
|
2160
|
-
if (typeof
|
|
2161
|
-
Object.defineProperty(WritableStreamDefaultWriter.prototype,
|
|
2159
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
2160
|
+
Object.defineProperty(WritableStreamDefaultWriter.prototype, Symbol.toStringTag, {
|
|
2162
2161
|
value: "WritableStreamDefaultWriter",
|
|
2163
2162
|
configurable: true
|
|
2164
2163
|
});
|
|
@@ -2308,8 +2307,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2308
2307
|
signal: { enumerable: true },
|
|
2309
2308
|
error: { enumerable: true }
|
|
2310
2309
|
});
|
|
2311
|
-
if (typeof
|
|
2312
|
-
Object.defineProperty(WritableStreamDefaultController.prototype,
|
|
2310
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
2311
|
+
Object.defineProperty(WritableStreamDefaultController.prototype, Symbol.toStringTag, {
|
|
2313
2312
|
value: "WritableStreamDefaultController",
|
|
2314
2313
|
configurable: true
|
|
2315
2314
|
});
|
|
@@ -2597,7 +2596,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2597
2596
|
try {
|
|
2598
2597
|
new ctor();
|
|
2599
2598
|
return true;
|
|
2600
|
-
} catch (
|
|
2599
|
+
} catch (_a2) {
|
|
2601
2600
|
return false;
|
|
2602
2601
|
}
|
|
2603
2602
|
}
|
|
@@ -2858,8 +2857,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2858
2857
|
setFunctionName(ReadableStreamDefaultController.prototype.close, "close");
|
|
2859
2858
|
setFunctionName(ReadableStreamDefaultController.prototype.enqueue, "enqueue");
|
|
2860
2859
|
setFunctionName(ReadableStreamDefaultController.prototype.error, "error");
|
|
2861
|
-
if (typeof
|
|
2862
|
-
Object.defineProperty(ReadableStreamDefaultController.prototype,
|
|
2860
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
2861
|
+
Object.defineProperty(ReadableStreamDefaultController.prototype, Symbol.toStringTag, {
|
|
2863
2862
|
value: "ReadableStreamDefaultController",
|
|
2864
2863
|
configurable: true
|
|
2865
2864
|
});
|
|
@@ -3631,6 +3630,9 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3631
3630
|
const options = convertIteratorOptions(rawOptions, "First parameter");
|
|
3632
3631
|
return AcquireReadableStreamAsyncIterator(this, options.preventCancel);
|
|
3633
3632
|
}
|
|
3633
|
+
[SymbolAsyncIterator](options) {
|
|
3634
|
+
return this.values(options);
|
|
3635
|
+
}
|
|
3634
3636
|
/**
|
|
3635
3637
|
* Creates a new ReadableStream wrapping the provided iterable or async iterable.
|
|
3636
3638
|
*
|
|
@@ -3660,19 +3662,17 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3660
3662
|
setFunctionName(ReadableStream2.prototype.pipeTo, "pipeTo");
|
|
3661
3663
|
setFunctionName(ReadableStream2.prototype.tee, "tee");
|
|
3662
3664
|
setFunctionName(ReadableStream2.prototype.values, "values");
|
|
3663
|
-
if (typeof
|
|
3664
|
-
Object.defineProperty(ReadableStream2.prototype,
|
|
3665
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3666
|
+
Object.defineProperty(ReadableStream2.prototype, Symbol.toStringTag, {
|
|
3665
3667
|
value: "ReadableStream",
|
|
3666
3668
|
configurable: true
|
|
3667
3669
|
});
|
|
3668
3670
|
}
|
|
3669
|
-
|
|
3670
|
-
|
|
3671
|
-
|
|
3672
|
-
|
|
3673
|
-
|
|
3674
|
-
});
|
|
3675
|
-
}
|
|
3671
|
+
Object.defineProperty(ReadableStream2.prototype, SymbolAsyncIterator, {
|
|
3672
|
+
value: ReadableStream2.prototype.values,
|
|
3673
|
+
writable: true,
|
|
3674
|
+
configurable: true
|
|
3675
|
+
});
|
|
3676
3676
|
function CreateReadableStream(startAlgorithm, pullAlgorithm, cancelAlgorithm, highWaterMark = 1, sizeAlgorithm = () => 1) {
|
|
3677
3677
|
const stream = Object.create(ReadableStream2.prototype);
|
|
3678
3678
|
InitializeReadableStream(stream);
|
|
@@ -3801,8 +3801,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3801
3801
|
highWaterMark: { enumerable: true },
|
|
3802
3802
|
size: { enumerable: true }
|
|
3803
3803
|
});
|
|
3804
|
-
if (typeof
|
|
3805
|
-
Object.defineProperty(ByteLengthQueuingStrategy.prototype,
|
|
3804
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3805
|
+
Object.defineProperty(ByteLengthQueuingStrategy.prototype, Symbol.toStringTag, {
|
|
3806
3806
|
value: "ByteLengthQueuingStrategy",
|
|
3807
3807
|
configurable: true
|
|
3808
3808
|
});
|
|
@@ -3853,8 +3853,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3853
3853
|
highWaterMark: { enumerable: true },
|
|
3854
3854
|
size: { enumerable: true }
|
|
3855
3855
|
});
|
|
3856
|
-
if (typeof
|
|
3857
|
-
Object.defineProperty(CountQueuingStrategy.prototype,
|
|
3856
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3857
|
+
Object.defineProperty(CountQueuingStrategy.prototype, Symbol.toStringTag, {
|
|
3858
3858
|
value: "CountQueuingStrategy",
|
|
3859
3859
|
configurable: true
|
|
3860
3860
|
});
|
|
@@ -3957,8 +3957,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3957
3957
|
readable: { enumerable: true },
|
|
3958
3958
|
writable: { enumerable: true }
|
|
3959
3959
|
});
|
|
3960
|
-
if (typeof
|
|
3961
|
-
Object.defineProperty(TransformStream.prototype,
|
|
3960
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3961
|
+
Object.defineProperty(TransformStream.prototype, Symbol.toStringTag, {
|
|
3962
3962
|
value: "TransformStream",
|
|
3963
3963
|
configurable: true
|
|
3964
3964
|
});
|
|
@@ -4072,8 +4072,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
4072
4072
|
setFunctionName(TransformStreamDefaultController.prototype.enqueue, "enqueue");
|
|
4073
4073
|
setFunctionName(TransformStreamDefaultController.prototype.error, "error");
|
|
4074
4074
|
setFunctionName(TransformStreamDefaultController.prototype.terminate, "terminate");
|
|
4075
|
-
if (typeof
|
|
4076
|
-
Object.defineProperty(TransformStreamDefaultController.prototype,
|
|
4075
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
4076
|
+
Object.defineProperty(TransformStreamDefaultController.prototype, Symbol.toStringTag, {
|
|
4077
4077
|
value: "TransformStreamDefaultController",
|
|
4078
4078
|
configurable: true
|
|
4079
4079
|
});
|
|
@@ -6969,7 +6969,7 @@ function createServiceClient(options) {
|
|
|
6969
6969
|
web-streams-polyfill/dist/ponyfill.es2018.js:
|
|
6970
6970
|
(**
|
|
6971
6971
|
* @license
|
|
6972
|
-
* web-streams-polyfill v3.3.
|
|
6972
|
+
* web-streams-polyfill v3.3.3
|
|
6973
6973
|
* Copyright 2024 Mattias Buelens, Diwank Singh Tomer and other contributors.
|
|
6974
6974
|
* This code is released under the MIT license.
|
|
6975
6975
|
* SPDX-License-Identifier: MIT
|
package/lib/index.d.ts
CHANGED
|
@@ -160,13 +160,16 @@ declare module "@smapiot/piral-cloud-node" {
|
|
|
160
160
|
|
|
161
161
|
export interface FetchClient {
|
|
162
162
|
getAuthorizationHeader(): Promise<string>;
|
|
163
|
-
fetch
|
|
163
|
+
fetch: {
|
|
164
|
+
(input: RequestInfo | URL, init?: RequestInit): Promise<Response>;
|
|
165
|
+
(input: string | Request | URL, init?: RequestInit): Promise<Response>;
|
|
166
|
+
};
|
|
164
167
|
Headers: {
|
|
165
168
|
new (init?: HeadersInit): Headers;
|
|
166
169
|
prototype: Headers;
|
|
167
170
|
};
|
|
168
171
|
FormData: {
|
|
169
|
-
new (form?: HTMLFormElement): FormData;
|
|
172
|
+
new (form?: HTMLFormElement, submitter?: HTMLElement): FormData;
|
|
170
173
|
prototype: FormData;
|
|
171
174
|
};
|
|
172
175
|
defaults: RequestInit;
|
package/lib/index.esm.js
CHANGED
|
@@ -45,7 +45,6 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
45
45
|
typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global2 = typeof globalThis !== "undefined" ? globalThis : global2 || self, factory(global2.WebStreamsPolyfill = {}));
|
|
46
46
|
})(exports, function(exports2) {
|
|
47
47
|
"use strict";
|
|
48
|
-
const SymbolPolyfill = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? Symbol : (description) => `Symbol(${description})`;
|
|
49
48
|
function noop2() {
|
|
50
49
|
return void 0;
|
|
51
50
|
}
|
|
@@ -59,7 +58,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
59
58
|
value: name,
|
|
60
59
|
configurable: true
|
|
61
60
|
});
|
|
62
|
-
} catch (
|
|
61
|
+
} catch (_a2) {
|
|
63
62
|
}
|
|
64
63
|
}
|
|
65
64
|
const originalPromise = Promise;
|
|
@@ -204,11 +203,11 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
204
203
|
return front._elements[cursor];
|
|
205
204
|
}
|
|
206
205
|
}
|
|
207
|
-
const AbortSteps =
|
|
208
|
-
const ErrorSteps =
|
|
209
|
-
const CancelSteps =
|
|
210
|
-
const PullSteps =
|
|
211
|
-
const ReleaseSteps =
|
|
206
|
+
const AbortSteps = Symbol("[[AbortSteps]]");
|
|
207
|
+
const ErrorSteps = Symbol("[[ErrorSteps]]");
|
|
208
|
+
const CancelSteps = Symbol("[[CancelSteps]]");
|
|
209
|
+
const PullSteps = Symbol("[[PullSteps]]");
|
|
210
|
+
const ReleaseSteps = Symbol("[[ReleaseSteps]]");
|
|
212
211
|
function ReadableStreamReaderGenericInitialize(reader, stream) {
|
|
213
212
|
reader._ownerReadableStream = stream;
|
|
214
213
|
stream._reader = reader;
|
|
@@ -454,8 +453,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
454
453
|
setFunctionName(ReadableStreamDefaultReader.prototype.cancel, "cancel");
|
|
455
454
|
setFunctionName(ReadableStreamDefaultReader.prototype.read, "read");
|
|
456
455
|
setFunctionName(ReadableStreamDefaultReader.prototype.releaseLock, "releaseLock");
|
|
457
|
-
if (typeof
|
|
458
|
-
Object.defineProperty(ReadableStreamDefaultReader.prototype,
|
|
456
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
457
|
+
Object.defineProperty(ReadableStreamDefaultReader.prototype, Symbol.toStringTag, {
|
|
459
458
|
value: "ReadableStreamDefaultReader",
|
|
460
459
|
configurable: true
|
|
461
460
|
});
|
|
@@ -574,9 +573,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
574
573
|
return this._asyncIteratorImpl.return(value);
|
|
575
574
|
}
|
|
576
575
|
};
|
|
577
|
-
|
|
578
|
-
Object.setPrototypeOf(ReadableStreamAsyncIteratorPrototype, AsyncIteratorPrototype);
|
|
579
|
-
}
|
|
576
|
+
Object.setPrototypeOf(ReadableStreamAsyncIteratorPrototype, AsyncIteratorPrototype);
|
|
580
577
|
function AcquireReadableStreamAsyncIterator(stream, preventCancel) {
|
|
581
578
|
const reader = AcquireReadableStreamDefaultReader(stream);
|
|
582
579
|
const impl = new ReadableStreamAsyncIteratorImpl(reader, preventCancel);
|
|
@@ -593,7 +590,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
593
590
|
}
|
|
594
591
|
try {
|
|
595
592
|
return x2._asyncIteratorImpl instanceof ReadableStreamAsyncIteratorImpl;
|
|
596
|
-
} catch (
|
|
593
|
+
} catch (_a2) {
|
|
597
594
|
return false;
|
|
598
595
|
}
|
|
599
596
|
}
|
|
@@ -603,6 +600,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
603
600
|
const NumberIsNaN = Number.isNaN || function(x2) {
|
|
604
601
|
return x2 !== x2;
|
|
605
602
|
};
|
|
603
|
+
var _a, _b, _c;
|
|
606
604
|
function CreateArrayFromList(elements) {
|
|
607
605
|
return elements.slice();
|
|
608
606
|
}
|
|
@@ -648,7 +646,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
648
646
|
}
|
|
649
647
|
function CreateAsyncFromSyncIterator(syncIteratorRecord) {
|
|
650
648
|
const syncIterable = {
|
|
651
|
-
[
|
|
649
|
+
[Symbol.iterator]: () => syncIteratorRecord.iterator
|
|
652
650
|
};
|
|
653
651
|
const asyncIterator = async function* () {
|
|
654
652
|
return yield* syncIterable;
|
|
@@ -656,17 +654,18 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
656
654
|
const nextMethod = asyncIterator.next;
|
|
657
655
|
return { iterator: asyncIterator, nextMethod, done: false };
|
|
658
656
|
}
|
|
657
|
+
const SymbolAsyncIterator = (_c = (_a = Symbol.asyncIterator) !== null && _a !== void 0 ? _a : (_b = Symbol.for) === null || _b === void 0 ? void 0 : _b.call(Symbol, "Symbol.asyncIterator")) !== null && _c !== void 0 ? _c : "@@asyncIterator";
|
|
659
658
|
function GetIterator(obj, hint = "sync", method) {
|
|
660
659
|
if (method === void 0) {
|
|
661
660
|
if (hint === "async") {
|
|
662
|
-
method = GetMethod(obj,
|
|
661
|
+
method = GetMethod(obj, SymbolAsyncIterator);
|
|
663
662
|
if (method === void 0) {
|
|
664
|
-
const syncMethod = GetMethod(obj,
|
|
663
|
+
const syncMethod = GetMethod(obj, Symbol.iterator);
|
|
665
664
|
const syncIteratorRecord = GetIterator(obj, "sync", syncMethod);
|
|
666
665
|
return CreateAsyncFromSyncIterator(syncIteratorRecord);
|
|
667
666
|
}
|
|
668
667
|
} else {
|
|
669
|
-
method = GetMethod(obj,
|
|
668
|
+
method = GetMethod(obj, Symbol.iterator);
|
|
670
669
|
}
|
|
671
670
|
}
|
|
672
671
|
if (method === void 0) {
|
|
@@ -794,8 +793,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
794
793
|
});
|
|
795
794
|
setFunctionName(ReadableStreamBYOBRequest.prototype.respond, "respond");
|
|
796
795
|
setFunctionName(ReadableStreamBYOBRequest.prototype.respondWithNewView, "respondWithNewView");
|
|
797
|
-
if (typeof
|
|
798
|
-
Object.defineProperty(ReadableStreamBYOBRequest.prototype,
|
|
796
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
797
|
+
Object.defineProperty(ReadableStreamBYOBRequest.prototype, Symbol.toStringTag, {
|
|
799
798
|
value: "ReadableStreamBYOBRequest",
|
|
800
799
|
configurable: true
|
|
801
800
|
});
|
|
@@ -932,8 +931,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
932
931
|
setFunctionName(ReadableByteStreamController.prototype.close, "close");
|
|
933
932
|
setFunctionName(ReadableByteStreamController.prototype.enqueue, "enqueue");
|
|
934
933
|
setFunctionName(ReadableByteStreamController.prototype.error, "error");
|
|
935
|
-
if (typeof
|
|
936
|
-
Object.defineProperty(ReadableByteStreamController.prototype,
|
|
934
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
935
|
+
Object.defineProperty(ReadableByteStreamController.prototype, Symbol.toStringTag, {
|
|
937
936
|
value: "ReadableByteStreamController",
|
|
938
937
|
configurable: true
|
|
939
938
|
});
|
|
@@ -1432,9 +1431,9 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1432
1431
|
return mode;
|
|
1433
1432
|
}
|
|
1434
1433
|
function convertByobReadOptions(options, context) {
|
|
1435
|
-
var
|
|
1434
|
+
var _a2;
|
|
1436
1435
|
assertDictionary(options, context);
|
|
1437
|
-
const min = (
|
|
1436
|
+
const min = (_a2 = options === null || options === void 0 ? void 0 : options.min) !== null && _a2 !== void 0 ? _a2 : 1;
|
|
1438
1437
|
return {
|
|
1439
1438
|
min: convertUnsignedLongLongWithEnforceRange(min, `${context} has member 'min' that`)
|
|
1440
1439
|
};
|
|
@@ -1580,8 +1579,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1580
1579
|
setFunctionName(ReadableStreamBYOBReader.prototype.cancel, "cancel");
|
|
1581
1580
|
setFunctionName(ReadableStreamBYOBReader.prototype.read, "read");
|
|
1582
1581
|
setFunctionName(ReadableStreamBYOBReader.prototype.releaseLock, "releaseLock");
|
|
1583
|
-
if (typeof
|
|
1584
|
-
Object.defineProperty(ReadableStreamBYOBReader.prototype,
|
|
1582
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
1583
|
+
Object.defineProperty(ReadableStreamBYOBReader.prototype, Symbol.toStringTag, {
|
|
1585
1584
|
value: "ReadableStreamBYOBReader",
|
|
1586
1585
|
configurable: true
|
|
1587
1586
|
});
|
|
@@ -1691,7 +1690,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1691
1690
|
}
|
|
1692
1691
|
try {
|
|
1693
1692
|
return typeof value.aborted === "boolean";
|
|
1694
|
-
} catch (
|
|
1693
|
+
} catch (_a2) {
|
|
1695
1694
|
return false;
|
|
1696
1695
|
}
|
|
1697
1696
|
}
|
|
@@ -1791,8 +1790,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1791
1790
|
setFunctionName(WritableStream.prototype.abort, "abort");
|
|
1792
1791
|
setFunctionName(WritableStream.prototype.close, "close");
|
|
1793
1792
|
setFunctionName(WritableStream.prototype.getWriter, "getWriter");
|
|
1794
|
-
if (typeof
|
|
1795
|
-
Object.defineProperty(WritableStream.prototype,
|
|
1793
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
1794
|
+
Object.defineProperty(WritableStream.prototype, Symbol.toStringTag, {
|
|
1796
1795
|
value: "WritableStream",
|
|
1797
1796
|
configurable: true
|
|
1798
1797
|
});
|
|
@@ -1835,12 +1834,12 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
1835
1834
|
return true;
|
|
1836
1835
|
}
|
|
1837
1836
|
function WritableStreamAbort(stream, reason) {
|
|
1838
|
-
var
|
|
1837
|
+
var _a2;
|
|
1839
1838
|
if (stream._state === "closed" || stream._state === "errored") {
|
|
1840
1839
|
return promiseResolvedWith(void 0);
|
|
1841
1840
|
}
|
|
1842
1841
|
stream._writableStreamController._abortReason = reason;
|
|
1843
|
-
(
|
|
1842
|
+
(_a2 = stream._writableStreamController._abortController) === null || _a2 === void 0 ? void 0 : _a2.abort(reason);
|
|
1844
1843
|
const state = stream._state;
|
|
1845
1844
|
if (state === "closed" || state === "errored") {
|
|
1846
1845
|
return promiseResolvedWith(void 0);
|
|
@@ -2163,8 +2162,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2163
2162
|
setFunctionName(WritableStreamDefaultWriter.prototype.close, "close");
|
|
2164
2163
|
setFunctionName(WritableStreamDefaultWriter.prototype.releaseLock, "releaseLock");
|
|
2165
2164
|
setFunctionName(WritableStreamDefaultWriter.prototype.write, "write");
|
|
2166
|
-
if (typeof
|
|
2167
|
-
Object.defineProperty(WritableStreamDefaultWriter.prototype,
|
|
2165
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
2166
|
+
Object.defineProperty(WritableStreamDefaultWriter.prototype, Symbol.toStringTag, {
|
|
2168
2167
|
value: "WritableStreamDefaultWriter",
|
|
2169
2168
|
configurable: true
|
|
2170
2169
|
});
|
|
@@ -2314,8 +2313,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2314
2313
|
signal: { enumerable: true },
|
|
2315
2314
|
error: { enumerable: true }
|
|
2316
2315
|
});
|
|
2317
|
-
if (typeof
|
|
2318
|
-
Object.defineProperty(WritableStreamDefaultController.prototype,
|
|
2316
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
2317
|
+
Object.defineProperty(WritableStreamDefaultController.prototype, Symbol.toStringTag, {
|
|
2319
2318
|
value: "WritableStreamDefaultController",
|
|
2320
2319
|
configurable: true
|
|
2321
2320
|
});
|
|
@@ -2603,7 +2602,7 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2603
2602
|
try {
|
|
2604
2603
|
new ctor();
|
|
2605
2604
|
return true;
|
|
2606
|
-
} catch (
|
|
2605
|
+
} catch (_a2) {
|
|
2607
2606
|
return false;
|
|
2608
2607
|
}
|
|
2609
2608
|
}
|
|
@@ -2864,8 +2863,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
2864
2863
|
setFunctionName(ReadableStreamDefaultController.prototype.close, "close");
|
|
2865
2864
|
setFunctionName(ReadableStreamDefaultController.prototype.enqueue, "enqueue");
|
|
2866
2865
|
setFunctionName(ReadableStreamDefaultController.prototype.error, "error");
|
|
2867
|
-
if (typeof
|
|
2868
|
-
Object.defineProperty(ReadableStreamDefaultController.prototype,
|
|
2866
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
2867
|
+
Object.defineProperty(ReadableStreamDefaultController.prototype, Symbol.toStringTag, {
|
|
2869
2868
|
value: "ReadableStreamDefaultController",
|
|
2870
2869
|
configurable: true
|
|
2871
2870
|
});
|
|
@@ -3637,6 +3636,9 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3637
3636
|
const options = convertIteratorOptions(rawOptions, "First parameter");
|
|
3638
3637
|
return AcquireReadableStreamAsyncIterator(this, options.preventCancel);
|
|
3639
3638
|
}
|
|
3639
|
+
[SymbolAsyncIterator](options) {
|
|
3640
|
+
return this.values(options);
|
|
3641
|
+
}
|
|
3640
3642
|
/**
|
|
3641
3643
|
* Creates a new ReadableStream wrapping the provided iterable or async iterable.
|
|
3642
3644
|
*
|
|
@@ -3666,19 +3668,17 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3666
3668
|
setFunctionName(ReadableStream2.prototype.pipeTo, "pipeTo");
|
|
3667
3669
|
setFunctionName(ReadableStream2.prototype.tee, "tee");
|
|
3668
3670
|
setFunctionName(ReadableStream2.prototype.values, "values");
|
|
3669
|
-
if (typeof
|
|
3670
|
-
Object.defineProperty(ReadableStream2.prototype,
|
|
3671
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3672
|
+
Object.defineProperty(ReadableStream2.prototype, Symbol.toStringTag, {
|
|
3671
3673
|
value: "ReadableStream",
|
|
3672
3674
|
configurable: true
|
|
3673
3675
|
});
|
|
3674
3676
|
}
|
|
3675
|
-
|
|
3676
|
-
|
|
3677
|
-
|
|
3678
|
-
|
|
3679
|
-
|
|
3680
|
-
});
|
|
3681
|
-
}
|
|
3677
|
+
Object.defineProperty(ReadableStream2.prototype, SymbolAsyncIterator, {
|
|
3678
|
+
value: ReadableStream2.prototype.values,
|
|
3679
|
+
writable: true,
|
|
3680
|
+
configurable: true
|
|
3681
|
+
});
|
|
3682
3682
|
function CreateReadableStream(startAlgorithm, pullAlgorithm, cancelAlgorithm, highWaterMark = 1, sizeAlgorithm = () => 1) {
|
|
3683
3683
|
const stream = Object.create(ReadableStream2.prototype);
|
|
3684
3684
|
InitializeReadableStream(stream);
|
|
@@ -3807,8 +3807,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3807
3807
|
highWaterMark: { enumerable: true },
|
|
3808
3808
|
size: { enumerable: true }
|
|
3809
3809
|
});
|
|
3810
|
-
if (typeof
|
|
3811
|
-
Object.defineProperty(ByteLengthQueuingStrategy.prototype,
|
|
3810
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3811
|
+
Object.defineProperty(ByteLengthQueuingStrategy.prototype, Symbol.toStringTag, {
|
|
3812
3812
|
value: "ByteLengthQueuingStrategy",
|
|
3813
3813
|
configurable: true
|
|
3814
3814
|
});
|
|
@@ -3859,8 +3859,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3859
3859
|
highWaterMark: { enumerable: true },
|
|
3860
3860
|
size: { enumerable: true }
|
|
3861
3861
|
});
|
|
3862
|
-
if (typeof
|
|
3863
|
-
Object.defineProperty(CountQueuingStrategy.prototype,
|
|
3862
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3863
|
+
Object.defineProperty(CountQueuingStrategy.prototype, Symbol.toStringTag, {
|
|
3864
3864
|
value: "CountQueuingStrategy",
|
|
3865
3865
|
configurable: true
|
|
3866
3866
|
});
|
|
@@ -3963,8 +3963,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
3963
3963
|
readable: { enumerable: true },
|
|
3964
3964
|
writable: { enumerable: true }
|
|
3965
3965
|
});
|
|
3966
|
-
if (typeof
|
|
3967
|
-
Object.defineProperty(TransformStream.prototype,
|
|
3966
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
3967
|
+
Object.defineProperty(TransformStream.prototype, Symbol.toStringTag, {
|
|
3968
3968
|
value: "TransformStream",
|
|
3969
3969
|
configurable: true
|
|
3970
3970
|
});
|
|
@@ -4078,8 +4078,8 @@ var require_ponyfill_es2018 = __commonJS({
|
|
|
4078
4078
|
setFunctionName(TransformStreamDefaultController.prototype.enqueue, "enqueue");
|
|
4079
4079
|
setFunctionName(TransformStreamDefaultController.prototype.error, "error");
|
|
4080
4080
|
setFunctionName(TransformStreamDefaultController.prototype.terminate, "terminate");
|
|
4081
|
-
if (typeof
|
|
4082
|
-
Object.defineProperty(TransformStreamDefaultController.prototype,
|
|
4081
|
+
if (typeof Symbol.toStringTag === "symbol") {
|
|
4082
|
+
Object.defineProperty(TransformStreamDefaultController.prototype, Symbol.toStringTag, {
|
|
4083
4083
|
value: "TransformStreamDefaultController",
|
|
4084
4084
|
configurable: true
|
|
4085
4085
|
});
|
|
@@ -6967,7 +6967,7 @@ export {
|
|
|
6967
6967
|
web-streams-polyfill/dist/ponyfill.es2018.js:
|
|
6968
6968
|
(**
|
|
6969
6969
|
* @license
|
|
6970
|
-
* web-streams-polyfill v3.3.
|
|
6970
|
+
* web-streams-polyfill v3.3.3
|
|
6971
6971
|
* Copyright 2024 Mattias Buelens, Diwank Singh Tomer and other contributors.
|
|
6972
6972
|
* This code is released under the MIT license.
|
|
6973
6973
|
* SPDX-License-Identifier: MIT
|