peachsim 0.1.1477 → 0.1.1481
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/cli/commands/control.ts +68 -42
- package/cli/commands/detox.ts +15 -10
- package/cli/commands/flow.ts +1 -2
- package/cli/commands/inspect/settling.ts +5 -1
- package/cli/commands/setup.ts +20 -13
- package/cli/commands/test.ts +2 -1
- package/cli/dev-build-freshness.ts +14 -14
- package/cli/outbound-endpoints.ts +80 -6
- package/detox/index.ts +27 -14
- package/detox/matchers.ts +17 -6
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +1 -1
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +1 -1
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +1 -1
- package/dist-lib/bundle-channel.cjs +42 -14
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +1 -1
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +1 -1
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +1 -1
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +1 -1
- package/dist-lib/config.cjs +19 -3
- package/dist-lib/config.mjs +19 -3
- package/dist-lib/detox/index.cjs +80 -13
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/expo-swift-bundle.cjs +24 -8
- package/dist-lib/expo-swift-metadata.cjs +18 -6
- package/dist-lib/expo-swift-metadata.mjs +18 -6
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +489 -355
- package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +46 -19
- package/dist-lib/jump-to-source-babel.cjs +1 -1
- package/dist-lib/jump-to-source-native.cjs +1 -1
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +1 -1
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +1 -1
- package/dist-lib/metro-production-bundle.cjs +24 -6
- package/dist-lib/metro-production-bundle.mjs +22 -6
- package/dist-lib/metro.cjs +41 -18
- package/dist-lib/native-app-identity-project.cjs +1 -1
- package/dist-lib/native-app-identity-project.mjs +1 -1
- package/dist-lib/native-app-identity.cjs +19 -5
- package/dist-lib/native-app-identity.mjs +19 -5
- package/dist-lib/native-firebase-metadata.cjs +22 -7
- package/dist-lib/native-firebase-metadata.mjs +20 -7
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +1 -1
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/react-native-host-modules.cjs +3 -1
- package/dist-lib/react-native-host-modules.mjs +3 -1
- package/dist-lib/scripts/dev-server-scanner.cjs +404 -279
- package/dist-lib/sdk.cjs +6 -2
- package/dist-lib/sdk.mjs +6 -2
- package/dist-lib/skills.cjs +618 -440
- package/dist-lib/swift-compile.cjs +1 -1
- package/dist-lib/swift-compile.mjs +1 -1
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +1 -1
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +1 -1
- package/dist-lib/swift-toolchain.cjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vite-swift.cjs +1 -1
- package/dist-lib/vite.cjs +1 -1
- package/dist-lib/worklet-executable.cjs +27 -7
- package/dist-lib/worklet-executable.mjs +27 -7
- package/package.json +1 -1
- package/scripts/dev-server-scanner.ts +493 -188
- package/src/bundleGlobalFooter.ts +26 -3
- package/src/config.ts +3 -2
- package/src/configured-bundle-producer.ts +2 -1
- package/src/expo-swift-host.ts +33 -7
- package/src/metro-production-bundle.ts +11 -4
- package/src/native-app-identity.ts +3 -2
- package/src/native-firebase-metadata.ts +5 -3
- package/src/react-native-host-modules.ts +2 -0
- package/src/worker-system-chunks.ts +53 -51
- package/src/worklet-executable.ts +38 -6
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/beta.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/beta.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -9787,6 +9787,20 @@ ${[...new Set(units.map((unit) => unit.namespace))].map((namespace) => `import $
|
|
|
9787
9787
|
}
|
|
9788
9788
|
`;
|
|
9789
9789
|
}
|
|
9790
|
+
function failureRecordPath(packagePath) {
|
|
9791
|
+
return `${packagePath}.failed.json`;
|
|
9792
|
+
}
|
|
9793
|
+
function readFailedCompilation(packagePath) {
|
|
9794
|
+
let record4;
|
|
9795
|
+
try {
|
|
9796
|
+
record4 = JSON.parse(import_node_fs15.default.readFileSync(failureRecordPath(packagePath), "utf8"));
|
|
9797
|
+
} catch {
|
|
9798
|
+
return null;
|
|
9799
|
+
}
|
|
9800
|
+
if (typeof record4 !== "object" || record4 === null || !("stamp" in record4) || !("diagnostic" in record4) || typeof record4.stamp !== "string" || typeof record4.diagnostic !== "string")
|
|
9801
|
+
return null;
|
|
9802
|
+
return { stamp: record4.stamp, diagnostic: record4.diagnostic };
|
|
9803
|
+
}
|
|
9790
9804
|
async function compileExpoSwiftModules(root, base, publishArtifact) {
|
|
9791
9805
|
const units = await collectExpoSwiftSources(root);
|
|
9792
9806
|
if (!units) return null;
|
|
@@ -9822,12 +9836,12 @@ async function compileExpoSwiftModules(root, base, publishArtifact) {
|
|
|
9822
9836
|
)
|
|
9823
9837
|
);
|
|
9824
9838
|
const stamp = sourceStamp(packagePath, module2.root);
|
|
9825
|
-
const failed =
|
|
9839
|
+
const failed = readFailedCompilation(packagePath);
|
|
9826
9840
|
if (failed?.stamp === stamp) {
|
|
9827
9841
|
failures.set(unit.moduleId, failed.diagnostic);
|
|
9828
9842
|
continue;
|
|
9829
9843
|
}
|
|
9830
|
-
|
|
9844
|
+
import_node_fs15.default.rmSync(failureRecordPath(packagePath), { force: true });
|
|
9831
9845
|
stamps.set(unit, stamp);
|
|
9832
9846
|
candidates.push(unit);
|
|
9833
9847
|
}
|
|
@@ -9891,10 +9905,13 @@ let package = Package(name: "PeachExpo", targets: [${targets.map((name2) => `.ta
|
|
|
9891
9905
|
throw error;
|
|
9892
9906
|
const missing = error instanceof SwiftMissingModulesError;
|
|
9893
9907
|
if ((sourceErrors.length && sourceErrors.length === errors.length || missing) && sourceStamp(packagePath, module2.root) === stamps.get(unit)) {
|
|
9894
|
-
|
|
9895
|
-
|
|
9896
|
-
|
|
9897
|
-
|
|
9908
|
+
import_node_fs15.default.writeFileSync(
|
|
9909
|
+
failureRecordPath(packagePath),
|
|
9910
|
+
JSON.stringify({
|
|
9911
|
+
stamp: stamps.get(unit),
|
|
9912
|
+
diagnostic: missing ? diagnostic : sourceErrors.join("\n")
|
|
9913
|
+
})
|
|
9914
|
+
);
|
|
9898
9915
|
}
|
|
9899
9916
|
failures.set(
|
|
9900
9917
|
unit.moduleId,
|
|
@@ -9923,7 +9940,7 @@ let package = Package(name: "PeachExpo", targets: [${targets.map((name2) => `.ta
|
|
|
9923
9940
|
}
|
|
9924
9941
|
return result;
|
|
9925
9942
|
}
|
|
9926
|
-
var import_node_child_process9, import_node_crypto8, import_node_fs15, import_node_module, import_node_os9, import_node_path16, import_node_util3, run3, scriptEnv, EXPO_SWIFT_ENTRY
|
|
9943
|
+
var import_node_child_process9, import_node_crypto8, import_node_fs15, import_node_module, import_node_os9, import_node_path16, import_node_util3, run3, scriptEnv, EXPO_SWIFT_ENTRY;
|
|
9927
9944
|
var init_expo_swift_host = __esm({
|
|
9928
9945
|
"src/expo-swift-host.ts"() {
|
|
9929
9946
|
"use strict";
|
|
@@ -9943,7 +9960,6 @@ var init_expo_swift_host = __esm({
|
|
|
9943
9960
|
run3 = (0, import_node_util3.promisify)(import_node_child_process9.execFile);
|
|
9944
9961
|
scriptEnv = { ...process.env, [RNX_FORKED_SCRIPT_ENV]: "1" };
|
|
9945
9962
|
EXPO_SWIFT_ENTRY = "Sources/PeachExpoApp/PeachExpoEntry.swift";
|
|
9946
|
-
failedCompilations = /* @__PURE__ */ new Map();
|
|
9947
9963
|
}
|
|
9948
9964
|
});
|
|
9949
9965
|
|
|
@@ -11424,10 +11440,23 @@ async function terminateProcessGroup(child, signal = "SIGTERM", gracefulTimeoutM
|
|
|
11424
11440
|
init_backend_origin();
|
|
11425
11441
|
|
|
11426
11442
|
// src/bundleGlobalFooter.ts
|
|
11443
|
+
function findBundleFooter(source, prefix) {
|
|
11444
|
+
let end = source.length;
|
|
11445
|
+
while (end > 0) {
|
|
11446
|
+
const newline = source.lastIndexOf("\n", end - 1);
|
|
11447
|
+
if (newline < 0) return -1;
|
|
11448
|
+
const line = newline + 1;
|
|
11449
|
+
if (source.startsWith(prefix, line)) return newline;
|
|
11450
|
+
if (line !== end && !source.startsWith("globalThis.", line) && !source.startsWith("//", line)) {
|
|
11451
|
+
return -1;
|
|
11452
|
+
}
|
|
11453
|
+
end = newline;
|
|
11454
|
+
}
|
|
11455
|
+
return -1;
|
|
11456
|
+
}
|
|
11427
11457
|
function readBundleGlobalFooter(source, name2) {
|
|
11428
11458
|
const prefix = `globalThis.${name2}=`;
|
|
11429
|
-
const start = source
|
|
11430
|
-
${prefix}`);
|
|
11459
|
+
const start = findBundleFooter(source, prefix);
|
|
11431
11460
|
if (start < 0) return null;
|
|
11432
11461
|
const end = source.indexOf("\n", start + 1);
|
|
11433
11462
|
const line = source.slice(start + 1, end < 0 ? void 0 : end);
|
|
@@ -11438,8 +11467,7 @@ ${prefix}`);
|
|
|
11438
11467
|
}
|
|
11439
11468
|
function insertBundleGlobalFooter(source, name2, value) {
|
|
11440
11469
|
const prefix = `globalThis.${name2}=`;
|
|
11441
|
-
const start = source
|
|
11442
|
-
${prefix}`);
|
|
11470
|
+
const start = findBundleFooter(source, prefix);
|
|
11443
11471
|
if (start >= 0) {
|
|
11444
11472
|
readBundleGlobalFooter(source, name2);
|
|
11445
11473
|
const end = source.indexOf("\n", start + 1);
|
|
@@ -11448,7 +11476,7 @@ ${prefix}`);
|
|
|
11448
11476
|
const json = JSON.stringify(value).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029").replace(/<\//g, "<\\/");
|
|
11449
11477
|
const footer = `
|
|
11450
11478
|
${prefix}${json};`;
|
|
11451
|
-
const identity = source
|
|
11479
|
+
const identity = findBundleFooter(source, "globalThis.__sootsimModulePaths=");
|
|
11452
11480
|
return identity < 0 ? source + footer : source.slice(0, identity) + footer + source.slice(identity);
|
|
11453
11481
|
}
|
|
11454
11482
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/cloud.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/cloud.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
3
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4
4
|
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
package/dist-lib/config.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -44,6 +44,22 @@ function isValidRuntimeVersion(value) {
|
|
|
44
44
|
return value.length <= 100 && /^[0-9A-Za-z][0-9A-Za-z._+-]*$/.test(value);
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
+
// src/bundleGlobalFooter.ts
|
|
48
|
+
function findBundleFooter(source, prefix) {
|
|
49
|
+
let end = source.length;
|
|
50
|
+
while (end > 0) {
|
|
51
|
+
const newline = source.lastIndexOf("\n", end - 1);
|
|
52
|
+
if (newline < 0) return -1;
|
|
53
|
+
const line = newline + 1;
|
|
54
|
+
if (source.startsWith(prefix, line)) return newline;
|
|
55
|
+
if (line !== end && !source.startsWith("globalThis.", line) && !source.startsWith("//", line)) {
|
|
56
|
+
return -1;
|
|
57
|
+
}
|
|
58
|
+
end = newline;
|
|
59
|
+
}
|
|
60
|
+
return -1;
|
|
61
|
+
}
|
|
62
|
+
|
|
47
63
|
// src/is-record.ts
|
|
48
64
|
function isRecord(value) {
|
|
49
65
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
@@ -94,7 +110,7 @@ function readPeachBundleConfig(value) {
|
|
|
94
110
|
return { config: value.config, runtimePackages: [...value.runtimePackages] };
|
|
95
111
|
}
|
|
96
112
|
function readPeachBundleConfigFooter(source) {
|
|
97
|
-
const start = source
|
|
113
|
+
const start = findBundleFooter(source, BUNDLE_CONFIG_PREFIX);
|
|
98
114
|
if (start < 0) return null;
|
|
99
115
|
const end = source.indexOf("\n", start + 1);
|
|
100
116
|
const line = source.slice(start + 1, end < 0 ? void 0 : end);
|
|
@@ -112,7 +128,7 @@ function createPeachBundleConfigFooter(config) {
|
|
|
112
128
|
function detachPeachBundleConfigFooter(source) {
|
|
113
129
|
const configuredBundle = readPeachBundleConfigFooter(source);
|
|
114
130
|
if (!configuredBundle) return { source, configuredBundle };
|
|
115
|
-
const start = source
|
|
131
|
+
const start = findBundleFooter(source, BUNDLE_CONFIG_PREFIX);
|
|
116
132
|
const end = source.indexOf("\n", start + 1);
|
|
117
133
|
return {
|
|
118
134
|
source: source.slice(0, start) + source.slice(end < 0 ? source.length : end),
|
package/dist-lib/config.mjs
CHANGED
|
@@ -1,8 +1,24 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
|
|
3
3
|
// src/config.ts
|
|
4
4
|
import { isValidRuntimeVersion } from "@contrast/runtime-delivery/version";
|
|
5
5
|
|
|
6
|
+
// src/bundleGlobalFooter.ts
|
|
7
|
+
function findBundleFooter(source, prefix) {
|
|
8
|
+
let end = source.length;
|
|
9
|
+
while (end > 0) {
|
|
10
|
+
const newline = source.lastIndexOf("\n", end - 1);
|
|
11
|
+
if (newline < 0) return -1;
|
|
12
|
+
const line = newline + 1;
|
|
13
|
+
if (source.startsWith(prefix, line)) return newline;
|
|
14
|
+
if (line !== end && !source.startsWith("globalThis.", line) && !source.startsWith("//", line)) {
|
|
15
|
+
return -1;
|
|
16
|
+
}
|
|
17
|
+
end = newline;
|
|
18
|
+
}
|
|
19
|
+
return -1;
|
|
20
|
+
}
|
|
21
|
+
|
|
6
22
|
// src/is-record.ts
|
|
7
23
|
function isRecord(value) {
|
|
8
24
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
@@ -53,7 +69,7 @@ function readPeachBundleConfig(value) {
|
|
|
53
69
|
return { config: value.config, runtimePackages: [...value.runtimePackages] };
|
|
54
70
|
}
|
|
55
71
|
function readPeachBundleConfigFooter(source) {
|
|
56
|
-
const start = source
|
|
72
|
+
const start = findBundleFooter(source, BUNDLE_CONFIG_PREFIX);
|
|
57
73
|
if (start < 0) return null;
|
|
58
74
|
const end = source.indexOf("\n", start + 1);
|
|
59
75
|
const line = source.slice(start + 1, end < 0 ? void 0 : end);
|
|
@@ -71,7 +87,7 @@ function createPeachBundleConfigFooter(config) {
|
|
|
71
87
|
function detachPeachBundleConfigFooter(source) {
|
|
72
88
|
const configuredBundle = readPeachBundleConfigFooter(source);
|
|
73
89
|
if (!configuredBundle) return { source, configuredBundle };
|
|
74
|
-
const start = source
|
|
90
|
+
const start = findBundleFooter(source, BUNDLE_CONFIG_PREFIX);
|
|
75
91
|
const end = source.indexOf("\n", start + 1);
|
|
76
92
|
return {
|
|
77
93
|
source: source.slice(0, start) + source.slice(end < 0 ? source.length : end),
|
package/dist-lib/detox/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1373,7 +1373,7 @@ function readChromiumQueue(deps, verified, own) {
|
|
|
1373
1373
|
"chromium-admission"
|
|
1374
1374
|
);
|
|
1375
1375
|
fs3.mkdirSync(dir, { recursive: true });
|
|
1376
|
-
const limit = Math.max(2, Math.floor(os2.
|
|
1376
|
+
const limit = Math.max(2, Math.floor(os2.cpus().length / 3));
|
|
1377
1377
|
const live = (entry) => {
|
|
1378
1378
|
const match = /^(\d+)-(\d+)-/.exec(entry);
|
|
1379
1379
|
if (!match) return false;
|
|
@@ -2649,6 +2649,8 @@ async function automateWebViewFrames(context, names, helpers, tenantWorkers) {
|
|
|
2649
2649
|
const browser = context.browser();
|
|
2650
2650
|
if (!browser) throw new Error("webview automation needs the browser behind its context");
|
|
2651
2651
|
const browserSession = await browser.newBrowserCDPSession();
|
|
2652
|
+
context.on("close", () => void browserSession.detach().catch(() => {
|
|
2653
|
+
}));
|
|
2652
2654
|
const cookieOperations = helpers.cookieOperations();
|
|
2653
2655
|
let nextNetworkDecision = 0;
|
|
2654
2656
|
const byFrameId = /* @__PURE__ */ new Map();
|
|
@@ -4078,9 +4080,12 @@ ${WEBVIEW_FRAME_COLOR_SCHEME_SOURCE} var webKit = config.webKit || null;
|
|
|
4078
4080
|
if (!lastEditable || !lastEditable.isConnected) return;
|
|
4079
4081
|
var state = editorState(lastEditable);
|
|
4080
4082
|
var candidate = payload.candidate;
|
|
4083
|
+
// a verbatim candidate still spells the word before the caret; an
|
|
4084
|
+
// empty-field prediction inserts into a still-empty editor.
|
|
4081
4085
|
if (!candidate || state.selectionStart !== state.selectionEnd ||
|
|
4082
4086
|
state.selectionEnd !== candidate.end || candidate.end !== state.text.length ||
|
|
4083
|
-
|
|
4087
|
+
(candidate.start === candidate.end ? state.text.length !== 0 :
|
|
4088
|
+
state.text.slice(candidate.start, candidate.end) !== candidate.text)) return;
|
|
4084
4089
|
if ('value' in lastEditable) lastEditable.setSelectionRange(candidate.start, candidate.end);
|
|
4085
4090
|
else {
|
|
4086
4091
|
var walker = document.createTreeWalker(lastEditable, NodeFilter.SHOW_TEXT);
|
|
@@ -8131,6 +8136,15 @@ var IOS_NAMED_FACES = [
|
|
|
8131
8136
|
italic: false,
|
|
8132
8137
|
metrics: SF_COMPACT_KEYCAP_METRICS
|
|
8133
8138
|
},
|
|
8139
|
+
// no named instance carries the keycap grade at wght 400
|
|
8140
|
+
{
|
|
8141
|
+
family: SF_COMPACT_KEYCAP_FONT_FAMILY,
|
|
8142
|
+
postScript: ".SFCompact-LightG3-400",
|
|
8143
|
+
file: "sf-compact-keycaps-400.woff2",
|
|
8144
|
+
weight: 0,
|
|
8145
|
+
italic: false,
|
|
8146
|
+
metrics: { ...SF_COMPACT_KEYCAP_METRICS, capHeight: 1365, xHeight: 1049 }
|
|
8147
|
+
},
|
|
8134
8148
|
{
|
|
8135
8149
|
family: "Menlo",
|
|
8136
8150
|
postScript: "Menlo-Regular",
|
|
@@ -8264,6 +8278,42 @@ var BOOT_FONT_URLS = [...BASE_FONT_URLS];
|
|
|
8264
8278
|
var PLATFORM_FONT_FAMILIES = [DEFAULT_FONT_FAMILY, EMOJI_FONT_FAMILY];
|
|
8265
8279
|
var _registeredFamilies = new Set(PLATFORM_FONT_FAMILIES);
|
|
8266
8280
|
|
|
8281
|
+
// ../peach-engine/src/engine/scroll-momentum-math.ts
|
|
8282
|
+
var IOS_STATUS_BAR_SCROLL_TO_TOP_RESPONSE_SECONDS = 0.6;
|
|
8283
|
+
var IOS_STATUS_BAR_SCROLL_TO_TOP_OMEGA = 2 * Math.PI / IOS_STATUS_BAR_SCROLL_TO_TOP_RESPONSE_SECONDS;
|
|
8284
|
+
var IOS_STATUS_BAR_SCROLL_TO_TOP_CONTROL_POINT_Y = Math.fround(0.2);
|
|
8285
|
+
var ANDROID_DECELERATION_RATE = Math.log(0.78) / Math.log(0.9);
|
|
8286
|
+
var ANDROID_FLING_INFLEXION = 0.35;
|
|
8287
|
+
var ANDROID_START_TENSION = 0.5;
|
|
8288
|
+
var ANDROID_END_TENSION = 1;
|
|
8289
|
+
var ANDROID_SPLINE_P1 = ANDROID_START_TENSION * ANDROID_FLING_INFLEXION;
|
|
8290
|
+
var ANDROID_SPLINE_P2 = 1 - ANDROID_END_TENSION * (1 - ANDROID_FLING_INFLEXION);
|
|
8291
|
+
var ANDROID_SPLINE_SAMPLES = 100;
|
|
8292
|
+
var ANDROID_PHYSICAL_COEFFICIENT = 9.80665 * 39.37 * 160 * 0.84;
|
|
8293
|
+
var ANDROID_SPLINE_POSITION = createAndroidSplinePosition();
|
|
8294
|
+
function createAndroidSplinePosition() {
|
|
8295
|
+
const position = Array.from({ length: ANDROID_SPLINE_SAMPLES + 1 }).fill(0);
|
|
8296
|
+
let xMin = 0;
|
|
8297
|
+
for (let i = 0; i < ANDROID_SPLINE_SAMPLES; i++) {
|
|
8298
|
+
const alpha = i / ANDROID_SPLINE_SAMPLES;
|
|
8299
|
+
let xMax = 1;
|
|
8300
|
+
let x = 0;
|
|
8301
|
+
let coefficient = 0;
|
|
8302
|
+
while (true) {
|
|
8303
|
+
x = xMin + (xMax - xMin) / 2;
|
|
8304
|
+
coefficient = 3 * x * (1 - x);
|
|
8305
|
+
const tx = coefficient * ((1 - x) * ANDROID_SPLINE_P1 + x * ANDROID_SPLINE_P2) + x * x * x;
|
|
8306
|
+
if (Math.abs(tx - alpha) < 1e-5) break;
|
|
8307
|
+
if (tx > alpha) xMax = x;
|
|
8308
|
+
else xMin = x;
|
|
8309
|
+
}
|
|
8310
|
+
position[i] = coefficient * ((1 - x) * ANDROID_START_TENSION + x) + x * x * x;
|
|
8311
|
+
}
|
|
8312
|
+
position[ANDROID_SPLINE_SAMPLES] = 1;
|
|
8313
|
+
return position;
|
|
8314
|
+
}
|
|
8315
|
+
var RESTING_FRAME_MS = 1e3 / 60;
|
|
8316
|
+
|
|
8267
8317
|
// ../peach-engine/src/engine/scroll-platform.ts
|
|
8268
8318
|
var IOS_SCROLL_AXIS_TANGENT = Math.sqrt(3);
|
|
8269
8319
|
function scrollTouchSlop(platform, primaryDelta) {
|
|
@@ -9051,15 +9101,23 @@ var SootSimWaitForScrollAction = class {
|
|
|
9051
9101
|
};
|
|
9052
9102
|
|
|
9053
9103
|
// detox/matchers.ts
|
|
9104
|
+
function createMatcher(type, value) {
|
|
9105
|
+
if (typeof value === "string") return { type, value };
|
|
9106
|
+
return {
|
|
9107
|
+
type,
|
|
9108
|
+
value: value.source,
|
|
9109
|
+
regexFlags: value.flags.replace(/[^ims]/g, "") + "u"
|
|
9110
|
+
};
|
|
9111
|
+
}
|
|
9054
9112
|
var by = {
|
|
9055
9113
|
id(testID) {
|
|
9056
|
-
return
|
|
9114
|
+
return createMatcher("id", testID);
|
|
9057
9115
|
},
|
|
9058
9116
|
text(text) {
|
|
9059
|
-
return
|
|
9117
|
+
return createMatcher("text", text);
|
|
9060
9118
|
},
|
|
9061
9119
|
label(accessibilityLabel) {
|
|
9062
|
-
return
|
|
9120
|
+
return createMatcher("label", accessibilityLabel);
|
|
9063
9121
|
},
|
|
9064
9122
|
type(nativeType) {
|
|
9065
9123
|
return { type: "type", value: nativeType };
|
|
@@ -9698,13 +9756,21 @@ async function waitForSootsimIdle(page, maxMs = 3e3, strict = false, transitionS
|
|
|
9698
9756
|
}
|
|
9699
9757
|
async function findNodeByMatcher(matcher) {
|
|
9700
9758
|
const page = getPage();
|
|
9701
|
-
if (matcher.index !== void 0 || matcher.type === "text") {
|
|
9759
|
+
if (matcher.regexFlags !== void 0 || matcher.index !== void 0 || matcher.type === "text") {
|
|
9702
9760
|
return page.evaluate(async (indexedMatcher) => {
|
|
9703
|
-
const
|
|
9761
|
+
const regex = indexedMatcher.regexFlags !== void 0 ? new RegExp(indexedMatcher.value, indexedMatcher.regexFlags) : null;
|
|
9762
|
+
const filter = regex ? {} : indexedMatcher.type === "id" ? { hasId: indexedMatcher.value } : indexedMatcher.type === "text" ? { hasText: indexedMatcher.value } : indexedMatcher.type === "label" ? { hasLabel: indexedMatcher.value } : indexedMatcher.type === "role" ? { hasRole: indexedMatcher.value } : { type: indexedMatcher.value };
|
|
9704
9763
|
const results = await window.__sootsimTest.queryAll(filter);
|
|
9705
|
-
const indexed =
|
|
9706
|
-
|
|
9707
|
-
|
|
9764
|
+
const indexed = results.filter((node) => {
|
|
9765
|
+
if (indexedMatcher.type === "text" && node.type !== "text" && node.nodeId >= 0)
|
|
9766
|
+
return false;
|
|
9767
|
+
if (!regex)
|
|
9768
|
+
return indexedMatcher.type !== "text" || node.text === indexedMatcher.value;
|
|
9769
|
+
const matches = (value) => typeof value === "string" && regex.test(value);
|
|
9770
|
+
if (indexedMatcher.type === "id") return matches(node.testID) || matches(node.id);
|
|
9771
|
+
if (indexedMatcher.type === "text") return matches(node.text);
|
|
9772
|
+
return matches(node.accessibilityLabel || (node.accessible ? node.text : null));
|
|
9773
|
+
});
|
|
9708
9774
|
return indexed[indexedMatcher.index ?? 0] ?? null;
|
|
9709
9775
|
}, matcher);
|
|
9710
9776
|
}
|
|
@@ -10156,14 +10222,15 @@ function createSootSimElement(matcher) {
|
|
|
10156
10222
|
async replaceText(text) {
|
|
10157
10223
|
const page = getPage();
|
|
10158
10224
|
const node = await findNodeByMatcher(matcher);
|
|
10159
|
-
|
|
10225
|
+
const resolvedId = node?.testID ?? node?.id;
|
|
10226
|
+
if (matcher.type === "id" && typeof resolvedId === "string" && typeof node?.nodeId === "number" && node.nodeId >= 1073741824) {
|
|
10160
10227
|
const replaced = await page.evaluate(
|
|
10161
10228
|
async ({ id, value: value2 }) => {
|
|
10162
10229
|
const mainShell = window.SootSim?.bridges?.mainShell;
|
|
10163
10230
|
if (typeof mainShell?.callTestBridge !== "function") return false;
|
|
10164
10231
|
return mainShell.callTestBridge("replaceTextByTestId", id, value2);
|
|
10165
10232
|
},
|
|
10166
|
-
{ id:
|
|
10233
|
+
{ id: resolvedId, value: text }
|
|
10167
10234
|
);
|
|
10168
10235
|
if (replaced === true) return;
|
|
10169
10236
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -9553,7 +9553,20 @@ ${[...new Set(units.map((unit) => unit.namespace))].map((namespace) => `import $
|
|
|
9553
9553
|
}
|
|
9554
9554
|
`;
|
|
9555
9555
|
}
|
|
9556
|
-
|
|
9556
|
+
function failureRecordPath(packagePath) {
|
|
9557
|
+
return `${packagePath}.failed.json`;
|
|
9558
|
+
}
|
|
9559
|
+
function readFailedCompilation(packagePath) {
|
|
9560
|
+
let record2;
|
|
9561
|
+
try {
|
|
9562
|
+
record2 = JSON.parse(import_node_fs15.default.readFileSync(failureRecordPath(packagePath), "utf8"));
|
|
9563
|
+
} catch {
|
|
9564
|
+
return null;
|
|
9565
|
+
}
|
|
9566
|
+
if (typeof record2 !== "object" || record2 === null || !("stamp" in record2) || !("diagnostic" in record2) || typeof record2.stamp !== "string" || typeof record2.diagnostic !== "string")
|
|
9567
|
+
return null;
|
|
9568
|
+
return { stamp: record2.stamp, diagnostic: record2.diagnostic };
|
|
9569
|
+
}
|
|
9557
9570
|
async function compileExpoSwiftModules(root, base, publishArtifact) {
|
|
9558
9571
|
const units = await collectExpoSwiftSources(root);
|
|
9559
9572
|
if (!units) return null;
|
|
@@ -9589,12 +9602,12 @@ async function compileExpoSwiftModules(root, base, publishArtifact) {
|
|
|
9589
9602
|
)
|
|
9590
9603
|
);
|
|
9591
9604
|
const stamp = sourceStamp(packagePath, module2.root);
|
|
9592
|
-
const failed =
|
|
9605
|
+
const failed = readFailedCompilation(packagePath);
|
|
9593
9606
|
if (failed?.stamp === stamp) {
|
|
9594
9607
|
failures.set(unit.moduleId, failed.diagnostic);
|
|
9595
9608
|
continue;
|
|
9596
9609
|
}
|
|
9597
|
-
|
|
9610
|
+
import_node_fs15.default.rmSync(failureRecordPath(packagePath), { force: true });
|
|
9598
9611
|
stamps.set(unit, stamp);
|
|
9599
9612
|
candidates.push(unit);
|
|
9600
9613
|
}
|
|
@@ -9658,10 +9671,13 @@ let package = Package(name: "PeachExpo", targets: [${targets.map((name2) => `.ta
|
|
|
9658
9671
|
throw error;
|
|
9659
9672
|
const missing = error instanceof SwiftMissingModulesError;
|
|
9660
9673
|
if ((sourceErrors.length && sourceErrors.length === errors.length || missing) && sourceStamp(packagePath, module2.root) === stamps.get(unit)) {
|
|
9661
|
-
|
|
9662
|
-
|
|
9663
|
-
|
|
9664
|
-
|
|
9674
|
+
import_node_fs15.default.writeFileSync(
|
|
9675
|
+
failureRecordPath(packagePath),
|
|
9676
|
+
JSON.stringify({
|
|
9677
|
+
stamp: stamps.get(unit),
|
|
9678
|
+
diagnostic: missing ? diagnostic : sourceErrors.join("\n")
|
|
9679
|
+
})
|
|
9680
|
+
);
|
|
9665
9681
|
}
|
|
9666
9682
|
failures.set(
|
|
9667
9683
|
unit.moduleId,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1481 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -30,10 +30,23 @@ __export(expoSwiftContract_exports, {
|
|
|
30
30
|
module.exports = __toCommonJS(expoSwiftContract_exports);
|
|
31
31
|
|
|
32
32
|
// src/bundleGlobalFooter.ts
|
|
33
|
+
function findBundleFooter(source, prefix) {
|
|
34
|
+
let end = source.length;
|
|
35
|
+
while (end > 0) {
|
|
36
|
+
const newline = source.lastIndexOf("\n", end - 1);
|
|
37
|
+
if (newline < 0) return -1;
|
|
38
|
+
const line = newline + 1;
|
|
39
|
+
if (source.startsWith(prefix, line)) return newline;
|
|
40
|
+
if (line !== end && !source.startsWith("globalThis.", line) && !source.startsWith("//", line)) {
|
|
41
|
+
return -1;
|
|
42
|
+
}
|
|
43
|
+
end = newline;
|
|
44
|
+
}
|
|
45
|
+
return -1;
|
|
46
|
+
}
|
|
33
47
|
function readBundleGlobalFooter(source, name) {
|
|
34
48
|
const prefix = `globalThis.${name}=`;
|
|
35
|
-
const start = source
|
|
36
|
-
${prefix}`);
|
|
49
|
+
const start = findBundleFooter(source, prefix);
|
|
37
50
|
if (start < 0) return null;
|
|
38
51
|
const end = source.indexOf("\n", start + 1);
|
|
39
52
|
const line = source.slice(start + 1, end < 0 ? void 0 : end);
|
|
@@ -44,8 +57,7 @@ ${prefix}`);
|
|
|
44
57
|
}
|
|
45
58
|
function insertBundleGlobalFooter(source, name, value) {
|
|
46
59
|
const prefix = `globalThis.${name}=`;
|
|
47
|
-
const start = source
|
|
48
|
-
${prefix}`);
|
|
60
|
+
const start = findBundleFooter(source, prefix);
|
|
49
61
|
if (start >= 0) {
|
|
50
62
|
readBundleGlobalFooter(source, name);
|
|
51
63
|
const end = source.indexOf("\n", start + 1);
|
|
@@ -54,7 +66,7 @@ ${prefix}`);
|
|
|
54
66
|
const json = JSON.stringify(value).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029").replace(/<\//g, "<\\/");
|
|
55
67
|
const footer = `
|
|
56
68
|
${prefix}${json};`;
|
|
57
|
-
const identity = source
|
|
69
|
+
const identity = findBundleFooter(source, "globalThis.__sootsimModulePaths=");
|
|
58
70
|
return identity < 0 ? source + footer : source.slice(0, identity) + footer + source.slice(identity);
|
|
59
71
|
}
|
|
60
72
|
|