@poe-platform/safe-js 0.1.441 → 0.1.442
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-XHHDLB42.js → chunk-7SGYDXE2.js} +2 -2
- package/dist/safe-js/chunks/{chunk-TIAM72UI.js → chunk-GL3SJA4W.js} +26 -25
- package/dist/safe-js/chunks/{chunk-TIAM72UI.js.map → chunk-GL3SJA4W.js.map} +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-XHHDLB42.js.map → chunk-7SGYDXE2.js.map} +0 -0
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
validateMigrationSemantics,
|
|
28
28
|
validateSnapshotData,
|
|
29
29
|
validateSnapshotMigration
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-GL3SJA4W.js";
|
|
31
31
|
|
|
32
32
|
// packages/safe-js/src/migrate.ts
|
|
33
33
|
import { createHash } from "node:crypto";
|
|
@@ -8249,4 +8249,4 @@ export {
|
|
|
8249
8249
|
parseMcpConfig,
|
|
8250
8250
|
makeMcpModule
|
|
8251
8251
|
};
|
|
8252
|
-
//# sourceMappingURL=chunk-
|
|
8252
|
+
//# sourceMappingURL=chunk-7SGYDXE2.js.map
|
|
@@ -13968,7 +13968,8 @@ function createObjectGlobal(methods2, budget) {
|
|
|
13968
13968
|
}
|
|
13969
13969
|
});
|
|
13970
13970
|
const properties = materializeFunctionProperties(constructor);
|
|
13971
|
-
const prototype = properties.prototype;
|
|
13971
|
+
const prototype = createIntrinsicObject(properties.prototype);
|
|
13972
|
+
properties.prototype = prototype;
|
|
13972
13973
|
Object.defineProperty(properties, "prototype", { writable: false });
|
|
13973
13974
|
for (const [name, method] of Object.entries(methods2)) {
|
|
13974
13975
|
Object.defineProperty(properties, name, { value: method, writable: true, configurable: true });
|
|
@@ -15813,7 +15814,7 @@ function createErrorConstructor(name, budget, guest) {
|
|
|
15813
15814
|
}
|
|
15814
15815
|
function createErrorPrototypes(budget, constructors2) {
|
|
15815
15816
|
const prototypes2 = /* @__PURE__ */ new Map();
|
|
15816
|
-
for (const name of errorNames) prototypes2.set(name,
|
|
15817
|
+
for (const name of errorNames) prototypes2.set(name, createIntrinsicObject());
|
|
15817
15818
|
errorPrototypes.set(budget, prototypes2);
|
|
15818
15819
|
for (const name of errorNames) {
|
|
15819
15820
|
const constructor = constructors2[name];
|
|
@@ -19929,7 +19930,7 @@ function createPrimitiveConstructor(options, budget) {
|
|
|
19929
19930
|
for (const [name, value] of methods2)
|
|
19930
19931
|
Object.defineProperty(prototype, name, { value, writable: true, configurable: true });
|
|
19931
19932
|
if (kind === "string") {
|
|
19932
|
-
const iteratorPrototype =
|
|
19933
|
+
const iteratorPrototype = createIntrinsicObject();
|
|
19933
19934
|
setSandboxPrototype(iteratorPrototype, resolveIntrinsicIdentity(budget, '["%IteratorPrototype%"]'));
|
|
19934
19935
|
Object.defineProperties(iteratorPrototype, {
|
|
19935
19936
|
next: { value: createSandboxClosure({
|
|
@@ -20299,8 +20300,8 @@ function createArrayGlobal(budget) {
|
|
|
20299
20300
|
configurable: true
|
|
20300
20301
|
});
|
|
20301
20302
|
Object.defineProperty(prototype, "constructor", { value: constructor, writable: true, configurable: true });
|
|
20302
|
-
const iteratorPrototype =
|
|
20303
|
-
const iterablePrototype =
|
|
20303
|
+
const iteratorPrototype = createIntrinsicObject();
|
|
20304
|
+
const iterablePrototype = createIntrinsicObject();
|
|
20304
20305
|
Object.defineProperty(iterablePrototype, Symbol.iterator, { value: createSandboxClosure({
|
|
20305
20306
|
guest: true,
|
|
20306
20307
|
sandbox: true,
|
|
@@ -22557,7 +22558,7 @@ function createDateGlobal(options) {
|
|
|
22557
22558
|
}
|
|
22558
22559
|
);
|
|
22559
22560
|
const clock = wrapCallerInjectedBindings({ now: readNow }, { ...options, moduleId: "<Date>" }).now;
|
|
22560
|
-
const prototype =
|
|
22561
|
+
const prototype = createIntrinsicObject();
|
|
22561
22562
|
const constructor = createSandboxClosure({
|
|
22562
22563
|
guest: true,
|
|
22563
22564
|
sandbox: true,
|
|
@@ -22692,7 +22693,7 @@ async function dateToJSON(receiver, budget, context) {
|
|
|
22692
22693
|
function createConsoleJsonGlobals(options) {
|
|
22693
22694
|
const sink = options.sink ?? console;
|
|
22694
22695
|
const globals = {
|
|
22695
|
-
JSON: {
|
|
22696
|
+
JSON: createIntrinsicObject({
|
|
22696
22697
|
rawJSON: createSandboxClosure({
|
|
22697
22698
|
sandbox: true,
|
|
22698
22699
|
guest: true,
|
|
@@ -22733,7 +22734,7 @@ function createConsoleJsonGlobals(options) {
|
|
|
22733
22734
|
call: async ([value, replacer, indent], context) => stringifyJson(value, replacer, indent, options.budget, context),
|
|
22734
22735
|
name: "stringify"
|
|
22735
22736
|
})
|
|
22736
|
-
},
|
|
22737
|
+
}),
|
|
22737
22738
|
console: options.hostCalls === void 0 ? {
|
|
22738
22739
|
error: createSandboxClosure({
|
|
22739
22740
|
sandbox: true,
|
|
@@ -23106,7 +23107,7 @@ function installCollectionPrototypes(budget, mapConstructor, setConstructor) {
|
|
|
23106
23107
|
{ name: "Map", constructor: mapConstructor, methods: mapMethods, size: mapSize, iterator: mapMethods.entries },
|
|
23107
23108
|
{ name: "Set", constructor: setConstructor, methods: setMethods, size: setSize, iterator: setMethods.values }
|
|
23108
23109
|
]) {
|
|
23109
|
-
const prototype =
|
|
23110
|
+
const prototype = createIntrinsicObject();
|
|
23110
23111
|
const species = createSandboxClosure({
|
|
23111
23112
|
guest: true,
|
|
23112
23113
|
sandbox: true,
|
|
@@ -23128,7 +23129,7 @@ function installCollectionPrototypes(budget, mapConstructor, setConstructor) {
|
|
|
23128
23129
|
}
|
|
23129
23130
|
function installCollectionIteratorPrototypes(budget) {
|
|
23130
23131
|
for (const name of ["Map", "Set"]) {
|
|
23131
|
-
const iteratorPrototype =
|
|
23132
|
+
const iteratorPrototype = createIntrinsicObject();
|
|
23132
23133
|
const kind = name === "Map" ? "map" : "set";
|
|
23133
23134
|
const next = createSandboxClosure({
|
|
23134
23135
|
guest: true,
|
|
@@ -23663,7 +23664,7 @@ async function regexSplit(target, input, limit, constructor, budget, context) {
|
|
|
23663
23664
|
|
|
23664
23665
|
// packages/safe-js/src/interp/globals/regex.ts
|
|
23665
23666
|
function installRegExpIteratorPrototype(budget) {
|
|
23666
|
-
const prototype =
|
|
23667
|
+
const prototype = createIntrinsicObject();
|
|
23667
23668
|
setSandboxPrototype(prototype, resolveIntrinsicIdentity(budget, '["%IteratorPrototype%"]'));
|
|
23668
23669
|
Object.defineProperties(prototype, {
|
|
23669
23670
|
next: { value: getRegExpIteratorMember("next", budget), writable: true, configurable: true },
|
|
@@ -23775,7 +23776,7 @@ function createRegexGlobals(options) {
|
|
|
23775
23776
|
writable: true,
|
|
23776
23777
|
configurable: true
|
|
23777
23778
|
});
|
|
23778
|
-
const prototype =
|
|
23779
|
+
const prototype = createIntrinsicObject();
|
|
23779
23780
|
Object.defineProperty(materializeFunctionProperties(constructor), Symbol.species, {
|
|
23780
23781
|
get: accessorAdapter(createSandboxClosure({
|
|
23781
23782
|
sandbox: true,
|
|
@@ -24224,7 +24225,7 @@ function installAsyncIteratorDispose(prototype, budget) {
|
|
|
24224
24225
|
|
|
24225
24226
|
// packages/safe-js/src/interp/globals/generator.ts
|
|
24226
24227
|
function createGeneratorPrototypes(budget) {
|
|
24227
|
-
const asyncIteratorPrototype =
|
|
24228
|
+
const asyncIteratorPrototype = createIntrinsicObject();
|
|
24228
24229
|
const asyncIterator = createSandboxClosure({
|
|
24229
24230
|
guest: true,
|
|
24230
24231
|
sandbox: true,
|
|
@@ -24245,8 +24246,8 @@ function createGeneratorPrototypes(budget) {
|
|
|
24245
24246
|
const state = /* @__PURE__ */ new Map();
|
|
24246
24247
|
for (const async of [false, true]) {
|
|
24247
24248
|
const tag = async ? "AsyncGenerator" : "Generator";
|
|
24248
|
-
const functionPrototype =
|
|
24249
|
-
const instancePrototype =
|
|
24249
|
+
const functionPrototype = createIntrinsicObject();
|
|
24250
|
+
const instancePrototype = createIntrinsicObject();
|
|
24250
24251
|
setSandboxPrototype(functionPrototype, resolveIntrinsicIdentity(budget, JSON.stringify(["%FunctionPrototype%"])));
|
|
24251
24252
|
setSandboxPrototype(instancePrototype, async ? asyncIteratorPrototype : resolveIntrinsicIdentity(budget, JSON.stringify(["%IteratorPrototype%"])));
|
|
24252
24253
|
Object.defineProperties(functionPrototype, {
|
|
@@ -24285,7 +24286,7 @@ function createGeneratorPrototypes(budget) {
|
|
|
24285
24286
|
|
|
24286
24287
|
// packages/safe-js/src/interp/globals/iterator-from.ts
|
|
24287
24288
|
function installIteratorFrom(constructor, budget) {
|
|
24288
|
-
const prototype =
|
|
24289
|
+
const prototype = createIntrinsicObject();
|
|
24289
24290
|
setSandboxPrototype(prototype, resolveIntrinsicIdentity(budget, '["%IteratorPrototype%"]'));
|
|
24290
24291
|
for (const name of ["next", "return"]) {
|
|
24291
24292
|
Object.defineProperty(prototype, name, { writable: true, configurable: true, value: createSandboxClosure({
|
|
@@ -24438,7 +24439,7 @@ function installIteratorConsumers(prototype, budget) {
|
|
|
24438
24439
|
|
|
24439
24440
|
// packages/safe-js/src/interp/globals/iterator-lazy.ts
|
|
24440
24441
|
function installLazyIteratorHelpers(common, budget) {
|
|
24441
|
-
const prototype =
|
|
24442
|
+
const prototype = createIntrinsicObject();
|
|
24442
24443
|
setSandboxPrototype(prototype, common);
|
|
24443
24444
|
Object.defineProperty(prototype, Symbol.toStringTag, { value: "Iterator Helper", configurable: true });
|
|
24444
24445
|
for (const operation of ["next", "return"]) {
|
|
@@ -24677,7 +24678,7 @@ function createIteratorGlobal(budget) {
|
|
|
24677
24678
|
|
|
24678
24679
|
// packages/safe-js/src/interp/globals/disposable-stack.ts
|
|
24679
24680
|
function createDisposableStackGlobal(budget) {
|
|
24680
|
-
const prototype =
|
|
24681
|
+
const prototype = createIntrinsicObject();
|
|
24681
24682
|
setSandboxPrototype(prototype, getSandboxPrototype(/* @__PURE__ */ Object.create(null), budget));
|
|
24682
24683
|
const constructor = createSandboxClosure({
|
|
24683
24684
|
guest: true,
|
|
@@ -24799,7 +24800,7 @@ function requireState(receiver) {
|
|
|
24799
24800
|
|
|
24800
24801
|
// packages/safe-js/src/interp/globals/async-disposable-stack.ts
|
|
24801
24802
|
function createAsyncDisposableStackGlobal(budget) {
|
|
24802
|
-
const prototype =
|
|
24803
|
+
const prototype = createIntrinsicObject();
|
|
24803
24804
|
setSandboxPrototype(prototype, getSandboxPrototype(/* @__PURE__ */ Object.create(null), budget));
|
|
24804
24805
|
const constructor = createSandboxClosure({
|
|
24805
24806
|
guest: true,
|
|
@@ -25049,7 +25050,7 @@ function createSymbolGlobal(budget) {
|
|
|
25049
25050
|
var resizeBuffer3 = Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "resize")?.value;
|
|
25050
25051
|
var transferBuffer2 = Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "transfer")?.value;
|
|
25051
25052
|
function createArrayBufferGlobal(budget) {
|
|
25052
|
-
const prototype =
|
|
25053
|
+
const prototype = createIntrinsicObject();
|
|
25053
25054
|
const constructor = createSandboxClosure({
|
|
25054
25055
|
guest: true,
|
|
25055
25056
|
sandbox: true,
|
|
@@ -25316,7 +25317,7 @@ methods.setFloat16 = function(...args) {
|
|
|
25316
25317
|
return Reflect.apply(writeUint16, this, [args[0], sign | bits, args[2]]);
|
|
25317
25318
|
};
|
|
25318
25319
|
function createDataViewGlobal(budget) {
|
|
25319
|
-
const prototype =
|
|
25320
|
+
const prototype = createIntrinsicObject();
|
|
25320
25321
|
const constructor = createSandboxClosure({
|
|
25321
25322
|
guest: true,
|
|
25322
25323
|
sandbox: true,
|
|
@@ -25513,7 +25514,7 @@ function createReflectGlobal(budget) {
|
|
|
25513
25514
|
}, context.stack, context);
|
|
25514
25515
|
} }
|
|
25515
25516
|
};
|
|
25516
|
-
const reflect = {};
|
|
25517
|
+
const reflect = createIntrinsicObject({});
|
|
25517
25518
|
for (const name of nativeReflectPropertyNames) {
|
|
25518
25519
|
const method = methods2[name];
|
|
25519
25520
|
if (method === void 0) continue;
|
|
@@ -28329,7 +28330,7 @@ async function callPromiseClosure(callback, args, thisValue, budget, context) {
|
|
|
28329
28330
|
function getPromisePrototype(budget) {
|
|
28330
28331
|
const existing = promisePrototypes2.get(budget);
|
|
28331
28332
|
if (existing !== void 0) return existing;
|
|
28332
|
-
const prototype = {
|
|
28333
|
+
const prototype = createIntrinsicObject({
|
|
28333
28334
|
then: createSandboxClosure({
|
|
28334
28335
|
sandbox: true,
|
|
28335
28336
|
call: ([onFulfilled, onRejected], context) => {
|
|
@@ -28490,7 +28491,7 @@ function getPromisePrototype(budget) {
|
|
|
28490
28491
|
name: "finally",
|
|
28491
28492
|
length: 1
|
|
28492
28493
|
})
|
|
28493
|
-
};
|
|
28494
|
+
});
|
|
28494
28495
|
intrinsicPromiseThenMethods.add(prototype.then);
|
|
28495
28496
|
for (const name of Object.keys(prototype)) {
|
|
28496
28497
|
Object.defineProperty(prototype, name, { enumerable: false });
|
|
@@ -47593,4 +47594,4 @@ export {
|
|
|
47593
47594
|
FileSnapshotBackend,
|
|
47594
47595
|
run
|
|
47595
47596
|
};
|
|
47596
|
-
//# sourceMappingURL=chunk-
|
|
47597
|
+
//# sourceMappingURL=chunk-GL3SJA4W.js.map
|