peachsim 0.1.2490 → 0.1.2492
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/bridge-flow-runner.ts +190 -167
- package/cli/cloud-box-artifact.ts +49 -0
- package/cli/cloud-client.ts +7 -2
- package/cli/commands/inspect/settling.ts +7 -2
- package/cli/commands/platform.ts +7 -1
- package/cli/native-input.ts +18 -8
- 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 +2 -2
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +5 -5
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +3 -3
- package/dist-lib/bundle-channel.cjs +2 -2
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +3 -3
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +3 -3
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +2 -2
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +7 -7
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/config.mjs +5 -5
- package/dist-lib/detox/index.cjs +8 -3
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/esm-chunks/{acorn-V3XDEDP6.mjs → acorn-FU2FRHH2.mjs} +3 -3
- package/dist-lib/esm-chunks/{chunk-ZMCFZNUO.mjs → chunk-2PXTYLHZ.mjs} +5 -5
- package/dist-lib/esm-chunks/{chunk-HEOMLBGO.mjs → chunk-5CBH6U4Z.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-P6RAV46E.mjs → chunk-5D567O3G.mjs} +5 -5
- package/dist-lib/esm-chunks/{chunk-3JP3KRAD.mjs → chunk-66G5BBLZ.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-633546VE.mjs → chunk-AYLLC3WV.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-KGUUTG42.mjs → chunk-DDEXJ7N5.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-ZR3V6DY4.mjs → chunk-DIKB4ZTF.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-FLENJWNX.mjs → chunk-HHC6G7P2.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-ISB7UYPO.mjs → chunk-HMFMZEYN.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-MSVSZ66J.mjs → chunk-IOMFLWBI.mjs} +2 -2
- package/dist-lib/esm-chunks/{chunk-6J6FWZLQ.mjs → chunk-MA2ZJ77J.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-DCO5CMNF.mjs → chunk-N27ZLCKM.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-N7VZ7VEK.mjs → chunk-PZMRNAME.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-KUFZD2CT.mjs → chunk-QI3ZYNIW.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-E6Q66I6T.mjs → chunk-SUBUXVVR.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-PBEN5WRU.mjs → chunk-WBME7FVJ.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-LATLGHGM.mjs → chunk-WHCH5I3R.mjs} +12 -12
- package/dist-lib/esm-chunks/{chunk-HGXXVBJG.mjs → chunk-WXSE2Q5H.mjs} +3 -3
- package/dist-lib/esm-chunks/{chunk-6V2ECPE7.mjs → chunk-WZC67JCE.mjs} +1 -1
- package/dist-lib/esm-chunks/{chunk-O7GFR7YK.mjs → chunk-XMN5ZUL5.mjs} +4 -4
- package/dist-lib/esm-chunks/{chunk-AQ3PGPWE.mjs → chunk-YLQTCLSU.mjs} +1 -1
- package/dist-lib/esm-chunks/{metro-layout-parser-JHKSRYFH.mjs → metro-layout-parser-MCDRWEZS.mjs} +3 -3
- package/dist-lib/esm-chunks/{swift-package-prebuilt-JX5THTBC.mjs → swift-package-prebuilt-UFSFZOBX.mjs} +10 -10
- package/dist-lib/esm-chunks/{swift-sdk-app-module-W6JPOC7Q.mjs → swift-sdk-app-module-G4ILN2V5.mjs} +13 -13
- package/dist-lib/esm-chunks/{swift-sdk-image-7IQKWX4J.mjs → swift-sdk-image-VIXRBEVE.mjs} +13 -13
- package/dist-lib/esm-chunks/{swift-sdk-image-producer-IFBEHFC5.mjs → swift-sdk-image-producer-CDWJNY67.mjs} +4 -4
- package/dist-lib/expo-swift-bundle.cjs +2 -2
- package/dist-lib/expo-swift-metadata.cjs +1 -1
- package/dist-lib/expo-swift-metadata.mjs +7 -7
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +5 -4
- package/dist-lib/host/fetch-proxy-handler.cjs +2 -2
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +2 -2
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +11 -5
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +3 -3
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +3 -3
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +4 -4
- package/dist-lib/native-app-identity-project.cjs +1 -1
- package/dist-lib/native-app-identity-project.mjs +15 -15
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +6 -6
- package/dist-lib/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.mjs +3 -3
- package/dist-lib/pdfium-raster.cjs +1 -1
- package/dist-lib/pdfium-raster.mjs +2 -2
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +3 -3
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/public-origins-lib-esm.json +79 -79
- package/dist-lib/public-origins-lib.json +69 -69
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +2 -2
- package/dist-lib/reap-browser.cjs +1 -1
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +8 -3
- package/dist-lib/sdk.mjs +14 -9
- package/dist-lib/skills.cjs +168 -186
- package/dist-lib/swift-compile.cjs +1 -1
- package/dist-lib/swift-compile.mjs +10 -10
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +3 -3
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +5 -5
- package/dist-lib/swift-svg-raster.cjs +1 -1
- package/dist-lib/swift-svg-raster.mjs +2 -2
- package/dist-lib/swift-toolchain.cjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vendor/@peculiar/x509.cjs +1 -1
- package/dist-lib/vendor/@ruby/prism/src/nodes.js.cjs +1 -1
- package/dist-lib/vendor/@ruby/prism/src/parsePrism.js.cjs +1 -1
- package/dist-lib/vendor/@xmldom/xmldom.cjs +1 -1
- package/dist-lib/vendor/acorn.cjs +1 -1
- package/dist-lib/vendor/bplist-parser.cjs +1 -1
- package/dist-lib/vendor/ignore.cjs +1 -1
- package/dist-lib/vendor/magic-string.cjs +1 -1
- package/dist-lib/vendor/plist.cjs +1 -1
- package/dist-lib/vendor/smol-toml.cjs +1 -1
- package/dist-lib/vendor/stream-json.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/tokenizer/index.js.cjs +1 -1
- package/dist-lib/vendor/sucrase/dist/parser/tokenizer/types.js.cjs +1 -1
- package/dist-lib/vendor/sucrase.cjs +1 -1
- package/dist-lib/vendor/terser.cjs +1 -1
- package/dist-lib/vendor/valibot.cjs +1 -1
- package/dist-lib/vendor/ws.cjs +1 -1
- package/dist-lib/vendor/zod.cjs +1 -1
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +3 -3
- package/dist-types/packages/peach-engine/src/engine/node.d.ts +1 -1
- package/dist-types/packages/peach-engine/src/engine/types.d.ts +1 -1
- package/dist-types/packages/peach-engine/src/render-worker/host.d.ts +2 -1
- package/dist-types/packages/peach-engine/src/render-worker/protocol.d.ts +8 -9
- package/dist-types/packages/peach-globals/src/index.d.ts +2 -2
- package/dist-types/packages/peach-globals/src/nodeContract.d.ts +1 -0
- package/dist-types/packages/peach-globals/src/testBridgeContract.d.ts +13 -1
- package/package.json +1 -1
- package/src/bridge-contract.ts +2 -17
- package/src/connect.ts +1 -1
- package/src/guest-bundle.ts +3 -2
package/dist-lib/sdk.mjs
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
import {
|
|
3
3
|
SEMANTIC_WAIT_MAX_TIMEOUT_MS,
|
|
4
4
|
parseDiagnosticsResult
|
|
5
|
-
} from "./esm-chunks/chunk-
|
|
5
|
+
} from "./esm-chunks/chunk-WXSE2Q5H.mjs";
|
|
6
6
|
import {
|
|
7
7
|
LAUNCH_METADATA_KEYS,
|
|
8
8
|
LAUNCH_METADATA_QUERY_PARAM
|
|
9
|
-
} from "./esm-chunks/chunk-
|
|
9
|
+
} from "./esm-chunks/chunk-PZMRNAME.mjs";
|
|
10
10
|
import {
|
|
11
11
|
HEADLESS_TENANT_FETCH_HUNG_MARKER,
|
|
12
12
|
readyProbeContentBasis,
|
|
13
13
|
readyProbeHasContent,
|
|
14
14
|
readyProbeIsReady
|
|
15
|
-
} from "./esm-chunks/chunk-
|
|
15
|
+
} from "./esm-chunks/chunk-DDEXJ7N5.mjs";
|
|
16
16
|
import {
|
|
17
17
|
sleep
|
|
18
|
-
} from "./esm-chunks/chunk-
|
|
19
|
-
import "./esm-chunks/chunk-
|
|
18
|
+
} from "./esm-chunks/chunk-QI3ZYNIW.mjs";
|
|
19
|
+
import "./esm-chunks/chunk-WBME7FVJ.mjs";
|
|
20
20
|
import {
|
|
21
21
|
__publicField
|
|
22
|
-
} from "./esm-chunks/chunk-
|
|
22
|
+
} from "./esm-chunks/chunk-WZC67JCE.mjs";
|
|
23
23
|
|
|
24
24
|
// cli/commands/inspect/core.ts
|
|
25
25
|
var MAX_MS_FLAG_ALIASES = ["--max-ms", "--maxMs", "--maxms", "--max_ms", "--timeout"];
|
|
@@ -1798,7 +1798,9 @@ function renderActivityIdleScript({
|
|
|
1798
1798
|
}
|
|
1799
1799
|
const blockers = []
|
|
1800
1800
|
const stats = await Promise.race([
|
|
1801
|
-
Promise.resolve()
|
|
1801
|
+
Promise.resolve()
|
|
1802
|
+
.then(() => host?.queryReadinessStats ? host.queryReadinessStats() : host?.queryStats(false))
|
|
1803
|
+
.catch(() => null),
|
|
1802
1804
|
new Promise((resolve) => setTimeout(() => resolve(null), 500)),
|
|
1803
1805
|
])
|
|
1804
1806
|
if (stats) {
|
|
@@ -1954,7 +1956,10 @@ async function waitForSootsimIdle({
|
|
|
1954
1956
|
const motionRead = strict || screenStill
|
|
1955
1957
|
? answer(() => globalThis.__sootsimTest?.listAnimations?.()).catch(() => null)
|
|
1956
1958
|
: null
|
|
1957
|
-
const
|
|
1959
|
+
const host = globalThis.__sootsimRenderHost
|
|
1960
|
+
const statsRead = answer(() =>
|
|
1961
|
+
host?.queryReadinessStats ? host.queryReadinessStats() : host?.queryStats?.(false)
|
|
1962
|
+
).catch(() => null)
|
|
1958
1963
|
// image preparation ends in the tenant before the compositor decodes
|
|
1959
1964
|
// and realizes its pixels. both owners must finish before settling.
|
|
1960
1965
|
// the compositor rejects a stats request it is too busy to answer.
|
package/dist-lib/skills.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -35508,7 +35508,7 @@ var init_swift_standin_digest = __esm({
|
|
|
35508
35508
|
|
|
35509
35509
|
// src/expo-native-compiler-digest.ts
|
|
35510
35510
|
function expoNativeCompilerDigestValue() {
|
|
35511
|
-
return true ? "
|
|
35511
|
+
return true ? "1c0184f1321579a9b9b9c0308b04ff09e6300798e4e113cf490c8718edbeb72c" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
|
|
35512
35512
|
}
|
|
35513
35513
|
var import_node_crypto12;
|
|
35514
35514
|
var init_expo_native_compiler_digest = __esm({
|
|
@@ -118790,10 +118790,11 @@ var init_metro_runtime_source = __esm({
|
|
|
118790
118790
|
function productionNativeGuestSource(source) {
|
|
118791
118791
|
return source.startsWith(productionPrelude) ? source : productionPrelude + source;
|
|
118792
118792
|
}
|
|
118793
|
-
function swiftGuestBundle(packageName2) {
|
|
118793
|
+
function swiftGuestBundle(packageName2, metadataUrl) {
|
|
118794
|
+
const args = metadataUrl ? [packageName2, metadataUrl] : [packageName2];
|
|
118794
118795
|
return guestBundle(
|
|
118795
118796
|
"peachsim/swift",
|
|
118796
|
-
`AppRegistry.registerComponent('PeachSwift', () => host.createSwiftPreviewEntry(${JSON.stringify(
|
|
118797
|
+
`AppRegistry.registerComponent('PeachSwift', () => host.createSwiftPreviewEntry(${args.map((arg) => JSON.stringify(arg)).join(", ")}))`
|
|
118797
118798
|
);
|
|
118798
118799
|
}
|
|
118799
118800
|
function kotlinGuestBundle() {
|
|
@@ -147239,6 +147240,7 @@ async function deleteRemoteSim(options2) {
|
|
|
147239
147240
|
return { simId: parsed2.simId, status: parsed2.status };
|
|
147240
147241
|
}
|
|
147241
147242
|
function resolveCloudSessionForParsed(parsed2) {
|
|
147243
|
+
if (parsed2.explicitPort) return null;
|
|
147242
147244
|
const session = readCloudSession();
|
|
147243
147245
|
if (!session) return null;
|
|
147244
147246
|
if (session.service === "box") {
|
|
@@ -175253,6 +175255,14 @@ async function prepareSwiftInput(input, opts = {}) {
|
|
|
175253
175255
|
host2.disposeSwiftProject(packagePath);
|
|
175254
175256
|
throw error;
|
|
175255
175257
|
}
|
|
175258
|
+
const createGuestSource = async (config, metadataUrl) => {
|
|
175259
|
+
const source = await produceConfiguredBundle(
|
|
175260
|
+
swiftGuestBundle(name3, metadataUrl),
|
|
175261
|
+
config,
|
|
175262
|
+
/* @__PURE__ */ new Set()
|
|
175263
|
+
);
|
|
175264
|
+
return appInfo.identity ? insertNativeAppIdentityFooter(source, appInfo.identity) : source;
|
|
175265
|
+
};
|
|
175256
175266
|
return {
|
|
175257
175267
|
host: host2,
|
|
175258
175268
|
module: module2,
|
|
@@ -175260,15 +175270,13 @@ async function prepareSwiftInput(input, opts = {}) {
|
|
|
175260
175270
|
name: name3,
|
|
175261
175271
|
appProject,
|
|
175262
175272
|
appInfo,
|
|
175273
|
+
async guestSourceForMetadataUrl(metadataUrl) {
|
|
175274
|
+
return createGuestSource(await loadRNXAppConfig(appProject), metadataUrl);
|
|
175275
|
+
},
|
|
175263
175276
|
async build(origin) {
|
|
175264
175277
|
const config = await loadRNXAppConfig(appProject);
|
|
175265
175278
|
host2.configureSwiftProject(packagePath, config);
|
|
175266
|
-
const
|
|
175267
|
-
swiftGuestBundle(name3),
|
|
175268
|
-
config,
|
|
175269
|
-
/* @__PURE__ */ new Set()
|
|
175270
|
-
);
|
|
175271
|
-
const guestSource = appInfo.identity ? insertNativeAppIdentityFooter(source, appInfo.identity) : source;
|
|
175279
|
+
const guestSource = await createGuestSource(config);
|
|
175272
175280
|
const metadata = await host2.swiftPackageMetadata(
|
|
175273
175281
|
packagePath,
|
|
175274
175282
|
name3,
|
|
@@ -175330,6 +175338,7 @@ async function prepareNativeInput(input, opts) {
|
|
|
175330
175338
|
metadataPath: SWIFT_PACKAGE_PATH + encodeURIComponent(prepared.name),
|
|
175331
175339
|
icon: prepared.appInfo.icon,
|
|
175332
175340
|
assets: assets2,
|
|
175341
|
+
guestSourceForMetadataUrl: prepared.guestSourceForMetadataUrl,
|
|
175333
175342
|
dispose: prepared.dispose
|
|
175334
175343
|
};
|
|
175335
175344
|
} catch (error) {
|
|
@@ -178674,7 +178683,9 @@ function renderActivityIdleScript({
|
|
|
178674
178683
|
}
|
|
178675
178684
|
const blockers = []
|
|
178676
178685
|
const stats = await Promise.race([
|
|
178677
|
-
Promise.resolve()
|
|
178686
|
+
Promise.resolve()
|
|
178687
|
+
.then(() => host?.queryReadinessStats ? host.queryReadinessStats() : host?.queryStats(false))
|
|
178688
|
+
.catch(() => null),
|
|
178678
178689
|
new Promise((resolve) => setTimeout(() => resolve(null), 500)),
|
|
178679
178690
|
])
|
|
178680
178691
|
if (stats) {
|
|
@@ -178830,7 +178841,10 @@ async function waitForSootsimIdle({
|
|
|
178830
178841
|
const motionRead = strict || screenStill
|
|
178831
178842
|
? answer(() => globalThis.__sootsimTest?.listAnimations?.()).catch(() => null)
|
|
178832
178843
|
: null
|
|
178833
|
-
const
|
|
178844
|
+
const host = globalThis.__sootsimRenderHost
|
|
178845
|
+
const statsRead = answer(() =>
|
|
178846
|
+
host?.queryReadinessStats ? host.queryReadinessStats() : host?.queryStats?.(false)
|
|
178847
|
+
).catch(() => null)
|
|
178834
178848
|
// image preparation ends in the tenant before the compositor decodes
|
|
178835
178849
|
// and realizes its pixels. both owners must finish before settling.
|
|
178836
178850
|
// the compositor rejects a stats request it is too busy to answer.
|
|
@@ -180573,178 +180587,145 @@ var init_bridge_flow_runner = __esm({
|
|
|
180573
180587
|
// (match scoped to a container). a nested selector resolves the same way,
|
|
180574
180588
|
// and a relative filter holds when ANY match of its anchor satisfies it.
|
|
180575
180589
|
async findElementScoped(opts, preferHittable = false) {
|
|
180576
|
-
const
|
|
180577
|
-
const
|
|
180578
|
-
|
|
180579
|
-
|
|
180580
|
-
|
|
180581
|
-
|
|
180582
|
-
|
|
180583
|
-
|
|
180584
|
-
|
|
180585
|
-
|
|
180586
|
-
|
|
180587
|
-
|
|
180588
|
-
|
|
180589
|
-
|
|
180590
|
-
|
|
180591
|
-
|
|
180592
|
-
|
|
180593
|
-
|
|
180594
|
-
|
|
180595
|
-
|
|
180596
|
-
const
|
|
180597
|
-
const
|
|
180598
|
-
|
|
180599
|
-
|
|
180600
|
-
|
|
180601
|
-
|
|
180602
|
-
|
|
180603
|
-
|
|
180604
|
-
|
|
180605
|
-
|
|
180606
|
-
|
|
180607
|
-
|
|
180608
|
-
|
|
180609
|
-
|
|
180610
|
-
|
|
180611
|
-
|
|
180612
|
-
|
|
180613
|
-
|
|
180614
|
-
|
|
180615
|
-
|
|
180616
|
-
|
|
180617
|
-
|
|
180618
|
-
|
|
180619
|
-
|
|
180620
|
-
|
|
180621
|
-
|
|
180622
|
-
|
|
180623
|
-
|
|
180624
|
-
|
|
180625
|
-
|
|
180626
|
-
|
|
180627
|
-
|
|
180628
|
-
|
|
180629
|
-
|
|
180630
|
-
|
|
180631
|
-
|
|
180632
|
-
|
|
180633
|
-
|
|
180634
|
-
|
|
180635
|
-
|
|
180636
|
-
|
|
180637
|
-
|
|
180638
|
-
|
|
180639
|
-
|
|
180640
|
-
|
|
180641
|
-
|
|
180642
|
-
|
|
180643
|
-
|
|
180644
|
-
|
|
180645
|
-
|
|
180646
|
-
|
|
180647
|
-
|
|
180648
|
-
|
|
180649
|
-
if (
|
|
180650
|
-
|
|
180651
|
-
|
|
180652
|
-
|
|
180653
|
-
|
|
180654
|
-
|
|
180655
|
-
|
|
180656
|
-
|
|
180657
|
-
|
|
180658
|
-
|
|
180659
|
-
|
|
180660
|
-
|
|
180661
|
-
|
|
180662
|
-
|
|
180663
|
-
|
|
180664
|
-
|
|
180665
|
-
|
|
180666
|
-
(
|
|
180667
|
-
|
|
180668
|
-
|
|
180669
|
-
|
|
180670
|
-
|
|
180671
|
-
|
|
180672
|
-
|
|
180673
|
-
|
|
180674
|
-
|
|
180675
|
-
|
|
180676
|
-
|
|
180677
|
-
|
|
180678
|
-
|
|
180679
|
-
|
|
180680
|
-
|
|
180681
|
-
|
|
180682
|
-
|
|
180683
|
-
|
|
180684
|
-
|
|
180685
|
-
|
|
180686
|
-
|
|
180687
|
-
|
|
180688
|
-
|
|
180689
|
-
|
|
180690
|
-
|
|
180691
|
-
|
|
180692
|
-
}
|
|
180693
|
-
|
|
180694
|
-
|
|
180695
|
-
|
|
180696
|
-
|
|
180697
|
-
|
|
180698
|
-
|
|
180699
|
-
|
|
180700
|
-
|
|
180701
|
-
|
|
180702
|
-
|
|
180703
|
-
|
|
180704
|
-
|
|
180705
|
-
|
|
180706
|
-
|
|
180707
|
-
|
|
180708
|
-
|
|
180709
|
-
|
|
180710
|
-
|
|
180711
|
-
|
|
180712
|
-
|
|
180713
|
-
}
|
|
180714
|
-
|
|
180715
|
-
// index takes the first in the ios hierarchy, which lays siblings out
|
|
180716
|
-
// by position rather than subview order (RAN on ios 27: two views with
|
|
180717
|
-
// one identifier, the first subview moved below by a transform, maestro
|
|
180718
|
-
// takes the upper one). a list that renders rows in key order and
|
|
180719
|
-
// places them by transform still resolves its top row.
|
|
180720
|
-
candidates.sort(byPosition)
|
|
180721
|
-
if (sel.index == null && sel.text && !sel.id) {
|
|
180722
|
-
candidates.sort((a, b) => (a.text || '').length - (b.text || '').length)
|
|
180723
|
-
}
|
|
180724
|
-
return candidates
|
|
180725
|
-
}
|
|
180726
|
-
// maestro Filters.index: a negative index counts from the end
|
|
180727
|
-
const pick = (candidates, rawIndex) => {
|
|
180728
|
-
if (rawIndex == null) return candidates
|
|
180729
|
-
const index = Math.trunc(Number(rawIndex))
|
|
180730
|
-
const resolved = index >= 0 ? index : candidates.length + index
|
|
180731
|
-
return candidates[resolved] ? [candidates[resolved]] : []
|
|
180732
|
-
}
|
|
180733
|
-
const matches = pick(matchAll(selector), selector.index)
|
|
180734
|
-
const nodes = ${JSON.stringify(preferHittable && opts.index == null)} ? matches : matches.slice(0, 1)
|
|
180735
|
-
return nodes.map((node) => ({
|
|
180736
|
-
nodeId: typeof node.nodeId === 'number' ? node.nodeId : null,
|
|
180737
|
-
id: node.id || null,
|
|
180738
|
-
testID: node.testID || null,
|
|
180739
|
-
text: node.text || null,
|
|
180740
|
-
absolutePosition: node.absolutePosition,
|
|
180741
|
-
layout: node.layout,
|
|
180742
|
-
// authoritative visibility, as in findElement above.
|
|
180743
|
-
visibleFrame: node.visibleFrame || null,
|
|
180744
|
-
isTextInput: !!node.isTextInput,
|
|
180745
|
-
}))
|
|
180746
|
-
})()`);
|
|
180747
|
-
if (!candidates?.length) return null;
|
|
180590
|
+
const relativeKeys = ["below", "above", "leftOf", "rightOf"];
|
|
180591
|
+
const needsAnchors = opts.childOf != null || relativeKeys.some((key2) => opts[key2] != null);
|
|
180592
|
+
const recordQuery = this.bridge.send({
|
|
180593
|
+
type: "query",
|
|
180594
|
+
simId: this.opts.simId,
|
|
180595
|
+
query: { kind: "nodes", id: needsAnchors ? void 0 : opts.id }
|
|
180596
|
+
});
|
|
180597
|
+
const [screen, result] = await Promise.all([this.screenBounds(), recordQuery]);
|
|
180598
|
+
const all = result.records;
|
|
180599
|
+
if (!Array.isArray(all)) throw new Error("engine returned no selector node records");
|
|
180600
|
+
const bounds = (n) => {
|
|
180601
|
+
const left = Math.trunc(n.absolutePosition.x);
|
|
180602
|
+
const top = Math.trunc(n.absolutePosition.y);
|
|
180603
|
+
return {
|
|
180604
|
+
x: left,
|
|
180605
|
+
y: top,
|
|
180606
|
+
width: Math.trunc(n.absolutePosition.x + n.layout.width) - left,
|
|
180607
|
+
height: Math.trunc(n.absolutePosition.y + n.layout.height) - top
|
|
180608
|
+
};
|
|
180609
|
+
};
|
|
180610
|
+
const painted = (n) => (n.visibleFrame?.area ?? 0) > 0;
|
|
180611
|
+
const centerOnScreen = (n) => {
|
|
180612
|
+
const cx = n.absolutePosition.x + n.layout.width / 2;
|
|
180613
|
+
const cy = n.absolutePosition.y + n.layout.height / 2;
|
|
180614
|
+
return cx >= 0 && cx <= screen.width && cy >= 0 && cy <= screen.height;
|
|
180615
|
+
};
|
|
180616
|
+
const byPosition = (a, b) => a.absolutePosition.y - b.absolutePosition.y || a.absolutePosition.x - b.absolutePosition.x;
|
|
180617
|
+
const relative6 = {
|
|
180618
|
+
below: (n, other) => bounds(n).y > bounds(other).y,
|
|
180619
|
+
above: (n, other) => bounds(n).y < bounds(other).y,
|
|
180620
|
+
leftOf: (n, other) => bounds(n).x < bounds(other).x,
|
|
180621
|
+
rightOf: (n, other) => bounds(n).x > bounds(other).x
|
|
180622
|
+
};
|
|
180623
|
+
const traitFilters = /* @__PURE__ */ new Map([
|
|
180624
|
+
["TEXT", (node) => node.text != null],
|
|
180625
|
+
[
|
|
180626
|
+
"SQUARE",
|
|
180627
|
+
(node) => {
|
|
180628
|
+
const frame = bounds(node);
|
|
180629
|
+
return Math.abs(1 - frame.width / frame.height) < 0.03;
|
|
180630
|
+
}
|
|
180631
|
+
],
|
|
180632
|
+
["LONG_TEXT", (node) => (node.text?.length ?? 0) > 200]
|
|
180633
|
+
]);
|
|
180634
|
+
const matchAll = (raw2) => {
|
|
180635
|
+
const sel = typeof raw2 === "string" ? { text: raw2 } : raw2;
|
|
180636
|
+
const matchesId = sel.id == null ? null : maestroSelectorMatcher(sel.id, "id");
|
|
180637
|
+
const matchesText = sel.text == null ? null : maestroSelectorMatcher(sel.text, "text");
|
|
180638
|
+
let candidates2 = all.filter(
|
|
180639
|
+
(n) => (!matchesId || matchesId(n.testID)) && (!matchesText || matchesText(n.text) || matchesText(n.accessibilityLabel) || matchesText(n.placeholder))
|
|
180640
|
+
);
|
|
180641
|
+
if (sel.width != null || sel.height != null) {
|
|
180642
|
+
const tolerance = sel.tolerance ?? 0;
|
|
180643
|
+
candidates2 = candidates2.filter((n) => {
|
|
180644
|
+
const b = bounds(n);
|
|
180645
|
+
return (sel.width == null || Math.abs(b.width - sel.width) <= tolerance) && (sel.height == null || Math.abs(b.height - sel.height) <= tolerance);
|
|
180646
|
+
});
|
|
180647
|
+
}
|
|
180648
|
+
for (const trait of sel.traits ? String(sel.traits).split(" ") : []) {
|
|
180649
|
+
const filter = traitFilters.get(trait.replaceAll("-", "_").toUpperCase());
|
|
180650
|
+
if (!filter) throw new Error("unknown selector trait: " + trait);
|
|
180651
|
+
candidates2 = candidates2.filter(filter);
|
|
180652
|
+
}
|
|
180653
|
+
if (sel.enabled != null) {
|
|
180654
|
+
candidates2 = candidates2.filter(
|
|
180655
|
+
(n) => !n.accessibilityState?.disabled === sel.enabled
|
|
180656
|
+
);
|
|
180657
|
+
}
|
|
180658
|
+
if (sel.selected != null) {
|
|
180659
|
+
candidates2 = candidates2.filter(
|
|
180660
|
+
(n) => !!n.accessibilityState?.selected === sel.selected
|
|
180661
|
+
);
|
|
180662
|
+
}
|
|
180663
|
+
if (sel.checked != null) {
|
|
180664
|
+
candidates2 = candidates2.filter(
|
|
180665
|
+
(n) => (n.accessibilityRole === "switch" && n.accessibilityState?.checked === true) === sel.checked
|
|
180666
|
+
);
|
|
180667
|
+
}
|
|
180668
|
+
for (const key2 of relativeKeys) {
|
|
180669
|
+
const anchor = sel[key2];
|
|
180670
|
+
if (anchor == null) continue;
|
|
180671
|
+
const anchors = pick2(
|
|
180672
|
+
matchAll(anchor),
|
|
180673
|
+
typeof anchor === "string" ? void 0 : anchor.index
|
|
180674
|
+
);
|
|
180675
|
+
candidates2 = candidates2.filter(
|
|
180676
|
+
(n) => anchors.some((other) => relative6[key2](n, other))
|
|
180677
|
+
);
|
|
180678
|
+
}
|
|
180679
|
+
if (sel.childOf) {
|
|
180680
|
+
const containers = matchAll(sel.childOf);
|
|
180681
|
+
const container = containers.find(painted) ?? containers[0];
|
|
180682
|
+
if (!container) return [];
|
|
180683
|
+
const x0 = container.absolutePosition.x;
|
|
180684
|
+
const y0 = container.absolutePosition.y;
|
|
180685
|
+
const x1 = x0 + container.layout.width;
|
|
180686
|
+
const y1 = y0 + container.layout.height;
|
|
180687
|
+
candidates2 = candidates2.filter((n) => {
|
|
180688
|
+
const cx = n.absolutePosition.x + n.layout.width / 2;
|
|
180689
|
+
const cy = n.absolutePosition.y + n.layout.height / 2;
|
|
180690
|
+
return cx >= x0 && cx <= x1 && cy >= y0 && cy <= y1;
|
|
180691
|
+
});
|
|
180692
|
+
}
|
|
180693
|
+
const onScreen = candidates2.filter(centerOnScreen);
|
|
180694
|
+
const paintedCandidates = candidates2.filter(painted);
|
|
180695
|
+
if (paintedCandidates.length > 0) {
|
|
180696
|
+
if (sel.index == null) {
|
|
180697
|
+
const hittable = paintedCandidates.filter(centerOnScreen);
|
|
180698
|
+
candidates2 = hittable.length > 0 ? hittable : paintedCandidates;
|
|
180699
|
+
} else {
|
|
180700
|
+
candidates2 = paintedCandidates;
|
|
180701
|
+
}
|
|
180702
|
+
} else if (onScreen.length > 0) candidates2 = onScreen;
|
|
180703
|
+
candidates2.sort(byPosition);
|
|
180704
|
+
if (sel.index == null && sel.text && !sel.id) {
|
|
180705
|
+
candidates2.sort((a, b) => (a.text || "").length - (b.text || "").length);
|
|
180706
|
+
}
|
|
180707
|
+
return candidates2;
|
|
180708
|
+
};
|
|
180709
|
+
const pick2 = (candidates2, rawIndex) => {
|
|
180710
|
+
if (rawIndex == null) return candidates2;
|
|
180711
|
+
const index = Math.trunc(Number(rawIndex));
|
|
180712
|
+
const resolved = index >= 0 ? index : candidates2.length + index;
|
|
180713
|
+
return candidates2[resolved] ? [candidates2[resolved]] : [];
|
|
180714
|
+
};
|
|
180715
|
+
const matches = pick2(matchAll(opts), opts.index);
|
|
180716
|
+
const nodes = preferHittable && opts.index == null ? matches : matches.slice(0, 1);
|
|
180717
|
+
const candidates = nodes.map((node) => ({
|
|
180718
|
+
nodeId: typeof node.nodeId === "number" ? node.nodeId : null,
|
|
180719
|
+
id: node.id || null,
|
|
180720
|
+
testID: node.testID || null,
|
|
180721
|
+
text: node.text || null,
|
|
180722
|
+
absolutePosition: node.absolutePosition,
|
|
180723
|
+
layout: node.layout,
|
|
180724
|
+
// authoritative visibility, as in findElement above.
|
|
180725
|
+
visibleFrame: node.visibleFrame || null,
|
|
180726
|
+
isTextInput: !!node.isTextInput
|
|
180727
|
+
}));
|
|
180728
|
+
if (!candidates.length) return null;
|
|
180748
180729
|
return preferHittable && opts.index == null ? this.preferHittableCandidate(candidates) : candidates[0];
|
|
180749
180730
|
}
|
|
180750
180731
|
async preferHittableCandidate(candidates) {
|
|
@@ -181015,13 +180996,14 @@ var init_bridge_flow_runner = __esm({
|
|
|
181015
180996
|
const element = await this.findElement(opts);
|
|
181016
180997
|
if (!element) return false;
|
|
181017
180998
|
const frame = element.visibleFrame;
|
|
181018
|
-
const
|
|
180999
|
+
const area = frame?.area;
|
|
181000
|
+
const usable = !!frame && Number.isFinite(frame.width) && Number.isFinite(frame.height) && typeof area === "number" && Number.isFinite(area);
|
|
181019
181001
|
if (!usable) {
|
|
181020
181002
|
throw new Error(
|
|
181021
181003
|
`authoritative visibility unavailable for ${JSON.stringify(opts)}: the engine returned visibleFrame ${JSON.stringify(frame ?? null)}`
|
|
181022
181004
|
);
|
|
181023
181005
|
}
|
|
181024
|
-
return frame.width > 0 && frame.height > 0 &&
|
|
181006
|
+
return frame.width > 0 && frame.height > 0 && area > 0;
|
|
181025
181007
|
}
|
|
181026
181008
|
async inputText(text7) {
|
|
181027
181009
|
if (!await this.waitForFocusedTextInput()) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
import {
|
|
3
3
|
FOUNDATION_IMPLICIT_MODULES,
|
|
4
4
|
MULTI_MANIFEST_VERSION,
|
|
@@ -63,15 +63,15 @@ import {
|
|
|
63
63
|
withoutSwiftDeclarations,
|
|
64
64
|
wrapUIApplicationMainEntry,
|
|
65
65
|
writeSwiftProject
|
|
66
|
-
} from "./esm-chunks/chunk-
|
|
67
|
-
import "./esm-chunks/chunk-
|
|
68
|
-
import "./esm-chunks/chunk-
|
|
69
|
-
import "./esm-chunks/chunk-
|
|
70
|
-
import "./esm-chunks/chunk-
|
|
71
|
-
import "./esm-chunks/chunk-
|
|
72
|
-
import "./esm-chunks/chunk-
|
|
73
|
-
import "./esm-chunks/chunk-
|
|
74
|
-
import "./esm-chunks/chunk-
|
|
66
|
+
} from "./esm-chunks/chunk-WHCH5I3R.mjs";
|
|
67
|
+
import "./esm-chunks/chunk-MA2ZJ77J.mjs";
|
|
68
|
+
import "./esm-chunks/chunk-HMFMZEYN.mjs";
|
|
69
|
+
import "./esm-chunks/chunk-SUBUXVVR.mjs";
|
|
70
|
+
import "./esm-chunks/chunk-DIKB4ZTF.mjs";
|
|
71
|
+
import "./esm-chunks/chunk-5CBH6U4Z.mjs";
|
|
72
|
+
import "./esm-chunks/chunk-HHC6G7P2.mjs";
|
|
73
|
+
import "./esm-chunks/chunk-WBME7FVJ.mjs";
|
|
74
|
+
import "./esm-chunks/chunk-WZC67JCE.mjs";
|
|
75
75
|
export {
|
|
76
76
|
FOUNDATION_IMPLICIT_MODULES,
|
|
77
77
|
MULTI_MANIFEST_VERSION,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
import {
|
|
3
3
|
OBJC_RESOURCE_ACCESSOR_BODY,
|
|
4
4
|
OBJC_RESOURCE_ACCESSOR_HEADER,
|
|
@@ -33,8 +33,8 @@ import {
|
|
|
33
33
|
swiftResourceBundles,
|
|
34
34
|
swiftTargetModuleName,
|
|
35
35
|
withoutGlogModuleMap
|
|
36
|
-
} from "./esm-chunks/chunk-
|
|
37
|
-
import "./esm-chunks/chunk-
|
|
36
|
+
} from "./esm-chunks/chunk-SUBUXVVR.mjs";
|
|
37
|
+
import "./esm-chunks/chunk-WZC67JCE.mjs";
|
|
38
38
|
export {
|
|
39
39
|
OBJC_RESOURCE_ACCESSOR_BODY,
|
|
40
40
|
OBJC_RESOURCE_ACCESSOR_HEADER,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
import {
|
|
3
3
|
isSwiftMetalLibrarySources
|
|
4
|
-
} from "./esm-chunks/chunk-
|
|
5
|
-
import "./esm-chunks/chunk-
|
|
4
|
+
} from "./esm-chunks/chunk-HMFMZEYN.mjs";
|
|
5
|
+
import "./esm-chunks/chunk-DIKB4ZTF.mjs";
|
|
6
6
|
import {
|
|
7
7
|
isRecord
|
|
8
|
-
} from "./esm-chunks/chunk-
|
|
9
|
-
import "./esm-chunks/chunk-
|
|
8
|
+
} from "./esm-chunks/chunk-WBME7FVJ.mjs";
|
|
9
|
+
import "./esm-chunks/chunk-WZC67JCE.mjs";
|
|
10
10
|
|
|
11
11
|
// src/swift-submit.ts
|
|
12
12
|
var SWIFT_COMPILE_PATH = "/api/swift-compile";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.2492 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|