@poe-platform/safe-js 0.1.336 → 0.1.338
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/safe-js/chunks/{chunk-KJOBFY4U.js → chunk-4KQADMYQ.js} +33 -7
- package/dist/safe-js/chunks/{chunk-KJOBFY4U.js.map → chunk-4KQADMYQ.js.map} +2 -2
- package/dist/safe-js/chunks/{chunk-C4I6UVWQ.js → chunk-PAFYEKHR.js} +2 -2
- package/dist/safe-js/cli.js +2 -2
- package/dist/safe-js/core.js +1 -1
- package/dist/safe-js/index.js +2 -2
- package/package.json +2 -2
- /package/dist/safe-js/chunks/{chunk-C4I6UVWQ.js.map → chunk-PAFYEKHR.js.map} +0 -0
|
@@ -14883,7 +14883,7 @@ function createFloat32ArrayPrototypes(budget, constructor) {
|
|
|
14883
14883
|
getters.push(getter);
|
|
14884
14884
|
Object.defineProperty(shared, key, { get: accessorAdapter(getter, "get"), configurable: true });
|
|
14885
14885
|
}
|
|
14886
|
-
for (const key of ["set", "slice", "subarray", "fill", "copyWithin", "reverse", "at", "includes", "indexOf", "lastIndexOf", "forEach", "every", "some", "find"])
|
|
14886
|
+
for (const key of ["set", "slice", "subarray", "fill", "copyWithin", "reverse", "at", "includes", "indexOf", "lastIndexOf", "forEach", "every", "some", "find", "findIndex", "toLocaleString"])
|
|
14887
14887
|
Object.defineProperty(shared, key, { value: getFloat32Member(new Float32Array(0), key, budget, constructor), writable: true, configurable: true });
|
|
14888
14888
|
const arrayPrototype = resolveIntrinsicIdentity(budget, '["Array","prototype"]');
|
|
14889
14889
|
Object.defineProperty(shared, "toString", { value: getSandboxDataProperty(arrayPrototype, "toString", budget), writable: true, configurable: true });
|
|
@@ -14965,17 +14965,18 @@ function getFloat32Member(value, property, budget, defaultConstructor) {
|
|
|
14965
14965
|
if (key === "byteLength") return storage.length * 4;
|
|
14966
14966
|
if (key === "byteOffset") return storage.byteOffset;
|
|
14967
14967
|
if (key === "BYTES_PER_ELEMENT") return 4;
|
|
14968
|
-
if (!["set", "slice", "subarray", "fill", "copyWithin", "reverse", "at", "includes", "indexOf", "lastIndexOf", "forEach", "every", "some", "find"].includes(key)) return void 0;
|
|
14968
|
+
if (!["set", "slice", "subarray", "fill", "copyWithin", "reverse", "at", "includes", "indexOf", "lastIndexOf", "forEach", "every", "some", "find", "findIndex", "toLocaleString"].includes(key)) return void 0;
|
|
14969
|
+
const numberPrototype = key === "toLocaleString" ? getBoxedPrototype(0, budget) : void 0;
|
|
14969
14970
|
return createSandboxClosure({
|
|
14970
14971
|
guest: true,
|
|
14971
14972
|
sandbox: true,
|
|
14972
14973
|
name: key,
|
|
14973
|
-
length: key === "reverse" ? 0 : key === "set" || key === "fill" || key === "at" || key === "includes" || key === "indexOf" || key === "lastIndexOf" || key === "forEach" || key === "every" || key === "some" || key === "find" ? 1 : 2,
|
|
14974
|
+
length: key === "reverse" || key === "toLocaleString" ? 0 : key === "set" || key === "fill" || key === "at" || key === "includes" || key === "indexOf" || key === "lastIndexOf" || key === "forEach" || key === "every" || key === "some" || key === "find" || key === "findIndex" ? 1 : 2,
|
|
14974
14975
|
call: (args, context) => {
|
|
14975
14976
|
const receiver = context?.thisValue;
|
|
14976
14977
|
if (!isFloat32Array(receiver))
|
|
14977
14978
|
throw new TypeError(`Float32Array#${key} requires a Float32Array receiver.`);
|
|
14978
|
-
const storage2 = float32Storage(receiver, key === "slice" || key === "fill" || key === "copyWithin" || key === "reverse" || key === "at" || key === "includes" || key === "indexOf" || key === "lastIndexOf" || key === "forEach" || key === "every" || key === "some" || key === "find");
|
|
14979
|
+
const storage2 = float32Storage(receiver, key === "slice" || key === "fill" || key === "copyWithin" || key === "reverse" || key === "at" || key === "includes" || key === "indexOf" || key === "lastIndexOf" || key === "forEach" || key === "every" || key === "some" || key === "find" || key === "findIndex" || key === "toLocaleString");
|
|
14979
14980
|
if (key === "reverse") {
|
|
14980
14981
|
const release = retainValues(budget, () => [receiver, ...args]);
|
|
14981
14982
|
try {
|
|
@@ -15004,7 +15005,31 @@ function getFloat32Member(value, property, budget, defaultConstructor) {
|
|
|
15004
15005
|
}),
|
|
15005
15006
|
invokeClosure: context?.invokeClosure ?? ((callee, values, thisValue, construct) => invokeBuiltinClosure(callee, values, budget, context, thisValue, construct))
|
|
15006
15007
|
};
|
|
15007
|
-
if (key === "
|
|
15008
|
+
if (key === "toLocaleString") {
|
|
15009
|
+
return (async () => {
|
|
15010
|
+
let text = "";
|
|
15011
|
+
const release = retainValues(budget, () => [receiver, text, ...args]);
|
|
15012
|
+
try {
|
|
15013
|
+
for (let index = 0; index < storage2.length; index++) {
|
|
15014
|
+
budget.visitNode();
|
|
15015
|
+
const element = receiver[index];
|
|
15016
|
+
let part = "";
|
|
15017
|
+
if (element !== void 0) {
|
|
15018
|
+
const descriptor2 = context?.getProperty === void 0 && numberPrototype !== void 0 ? getSandboxPropertyDescriptor(numberPrototype, "toLocaleString", budget) : void 0;
|
|
15019
|
+
const method = context?.getProperty === void 0 && numberPrototype !== void 0 ? descriptor2 === void 0 ? void 0 : await readPropertyDescriptor(descriptor2, element, bridge) : await bridge.getProperty(element, "toLocaleString");
|
|
15020
|
+
if (!isSandboxClosure(method)) throw new TypeError("Element toLocaleString must be callable.");
|
|
15021
|
+
const converted = await invokeBuiltinClosure(method, [args[0], args[1]], budget, bridge, element);
|
|
15022
|
+
part = await sandboxString(converted, budget, bridge);
|
|
15023
|
+
}
|
|
15024
|
+
text = budget.allocateString(text + (index === 0 ? "" : ",") + part);
|
|
15025
|
+
}
|
|
15026
|
+
return text;
|
|
15027
|
+
} finally {
|
|
15028
|
+
release();
|
|
15029
|
+
}
|
|
15030
|
+
})();
|
|
15031
|
+
}
|
|
15032
|
+
if (key === "forEach" || key === "every" || key === "some" || key === "find" || key === "findIndex") {
|
|
15008
15033
|
const callback = args[0];
|
|
15009
15034
|
if (!isSandboxClosure(callback)) throw new TypeError(`Float32Array#${key} callback must be callable.`);
|
|
15010
15035
|
return (async () => {
|
|
@@ -15017,8 +15042,9 @@ function getFloat32Member(value, property, budget, defaultConstructor) {
|
|
|
15017
15042
|
if (key === "every" && !result) return false;
|
|
15018
15043
|
if (key === "some" && result) return true;
|
|
15019
15044
|
if (key === "find" && result) return element;
|
|
15045
|
+
if (key === "findIndex" && result) return index;
|
|
15020
15046
|
}
|
|
15021
|
-
return key === "forEach" || key === "find" ? void 0 : key === "every";
|
|
15047
|
+
return key === "findIndex" ? -1 : key === "forEach" || key === "find" ? void 0 : key === "every";
|
|
15022
15048
|
} finally {
|
|
15023
15049
|
release();
|
|
15024
15050
|
}
|
|
@@ -42473,4 +42499,4 @@ export {
|
|
|
42473
42499
|
FileSnapshotBackend,
|
|
42474
42500
|
run
|
|
42475
42501
|
};
|
|
42476
|
-
//# sourceMappingURL=chunk-
|
|
42502
|
+
//# sourceMappingURL=chunk-4KQADMYQ.js.map
|