@poe-platform/safe-js 0.1.170 → 0.1.172
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-MZW43CYT.js → chunk-MKCG75T2.js} +2 -2
- package/dist/safe-js/chunks/{chunk-WPI4GGVU.js → chunk-WVYGEWML.js} +1239 -1010
- package/dist/safe-js/chunks/chunk-WVYGEWML.js.map +7 -0
- 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/dist/safe-js/interp/regexp-iterator.d.ts +14 -0
- package/dist/safe-js/interp/values.d.ts +2 -1
- package/dist/safe-js/snapshot/replay-data.d.ts +9 -1
- package/package.json +2 -2
- package/dist/safe-js/chunks/chunk-WPI4GGVU.js.map +0 -7
- /package/dist/safe-js/chunks/{chunk-MZW43CYT.js.map → chunk-MKCG75T2.js.map} +0 -0
package/dist/safe-js/cli.js
CHANGED
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
resolveFsConfig,
|
|
23
23
|
splitFrontmatter,
|
|
24
24
|
withBrokenPipeGuard
|
|
25
|
-
} from "./chunks/chunk-
|
|
25
|
+
} from "./chunks/chunk-MKCG75T2.js";
|
|
26
26
|
import {
|
|
27
27
|
Budget,
|
|
28
28
|
SandboxError,
|
|
@@ -34,7 +34,7 @@ import {
|
|
|
34
34
|
replaceErrorStack,
|
|
35
35
|
restore,
|
|
36
36
|
run
|
|
37
|
-
} from "./chunks/chunk-
|
|
37
|
+
} from "./chunks/chunk-WVYGEWML.js";
|
|
38
38
|
import "./chunks/chunk-4YIDX44G.js";
|
|
39
39
|
|
|
40
40
|
// packages/safe-js/src/cli.ts
|
package/dist/safe-js/core.js
CHANGED
package/dist/safe-js/index.js
CHANGED
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
runWithSpawnUsageAccumulator,
|
|
27
27
|
splitFrontmatter,
|
|
28
28
|
supportsSpawnMode
|
|
29
|
-
} from "./chunks/chunk-
|
|
29
|
+
} from "./chunks/chunk-MKCG75T2.js";
|
|
30
30
|
import {
|
|
31
31
|
Budget,
|
|
32
32
|
FileSnapshotBackend,
|
|
@@ -50,7 +50,7 @@ import {
|
|
|
50
50
|
registerPendingHostCallPolicy,
|
|
51
51
|
restore,
|
|
52
52
|
run
|
|
53
|
-
} from "./chunks/chunk-
|
|
53
|
+
} from "./chunks/chunk-WVYGEWML.js";
|
|
54
54
|
import "./chunks/chunk-4YIDX44G.js";
|
|
55
55
|
|
|
56
56
|
// packages/safe-js/src/parse.ts
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { SandboxRegex } from "./values.js";
|
|
2
|
+
declare const regexpIteratorBrand: unique symbol;
|
|
3
|
+
export type SandboxRegExpIterator = {
|
|
4
|
+
readonly [regexpIteratorBrand]: true;
|
|
5
|
+
};
|
|
6
|
+
export type RegExpIteratorState = {
|
|
7
|
+
matcher: SandboxRegex | undefined;
|
|
8
|
+
input: string | undefined;
|
|
9
|
+
exhausted: boolean;
|
|
10
|
+
};
|
|
11
|
+
export declare function isSandboxRegExpIterator(value: unknown): value is SandboxRegExpIterator;
|
|
12
|
+
export declare function restoreSandboxRegExpIterator(state: RegExpIteratorState, target?: SandboxRegExpIterator): SandboxRegExpIterator;
|
|
13
|
+
export declare function regexpIteratorState(value: SandboxRegExpIterator): RegExpIteratorState;
|
|
14
|
+
export {};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export { getRegexProperties } from "./regexp-properties.js";
|
|
2
2
|
import { sandboxMapBrand, sandboxSetBrand } from "./collection-brands.js";
|
|
3
3
|
import { type SandboxCollectionIterator } from "./collection-iterator.js";
|
|
4
|
+
import { type SandboxRegExpIterator } from "./regexp-iterator.js";
|
|
4
5
|
import type { Budget, CompileTicket } from "./budget.js";
|
|
5
6
|
import { CompileScope } from "./regex/compile-guard.js";
|
|
6
7
|
import type { GeneratorChannel } from "./generator.js";
|
|
@@ -15,7 +16,7 @@ declare const sandboxRegexBrand: unique symbol;
|
|
|
15
16
|
declare const sandboxRegexPattern: unique symbol;
|
|
16
17
|
declare const sandboxRetainedValues: unique symbol;
|
|
17
18
|
export type SandboxPrimitive = string | number | boolean | symbol | null | undefined;
|
|
18
|
-
export type SandboxValue = SandboxPrimitive | Date | Float32Array | SandboxObject | SandboxArray | SandboxClosure | SandboxGenerator | SandboxCollectionIterator | SandboxMap | SandboxSet | SandboxPromise | SandboxRegex;
|
|
19
|
+
export type SandboxValue = SandboxPrimitive | Date | Float32Array | SandboxObject | SandboxArray | SandboxClosure | SandboxGenerator | SandboxCollectionIterator | SandboxRegExpIterator | SandboxMap | SandboxSet | SandboxPromise | SandboxRegex;
|
|
19
20
|
export type SandboxObject = {
|
|
20
21
|
[key: string]: SandboxValue;
|
|
21
22
|
[key: symbol]: SandboxValue;
|
|
@@ -27,7 +27,15 @@ type Properties = Record<string, {
|
|
|
27
27
|
enumerable: boolean;
|
|
28
28
|
writable: boolean;
|
|
29
29
|
}>;
|
|
30
|
-
type DataNode =
|
|
30
|
+
type DataNode = {
|
|
31
|
+
kind: "regexp-iterator";
|
|
32
|
+
matcher: Atom;
|
|
33
|
+
input: Atom;
|
|
34
|
+
exhausted: boolean;
|
|
35
|
+
properties: Properties;
|
|
36
|
+
extensible: boolean;
|
|
37
|
+
symbolEntries?: Array<SerializedSymbolProperty<Atom>>;
|
|
38
|
+
} | SerializedSymbol | {
|
|
31
39
|
kind: "boxed";
|
|
32
40
|
value: Atom;
|
|
33
41
|
properties: Properties;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@poe-platform/safe-js",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.172",
|
|
4
4
|
"description": "Budgeted JavaScript interpreter with explicit host capabilities and resumable execution",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"access": "public"
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@poe-platform/safe-fs": "0.1.
|
|
61
|
+
"@poe-platform/safe-fs": "0.1.172",
|
|
62
62
|
"yaml": "^2.8.2",
|
|
63
63
|
"jose": "^6.1.3",
|
|
64
64
|
"@types/node": "^25.2.2"
|