peachsim 0.1.745 → 0.1.746

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.
Files changed (76) hide show
  1. package/cli/drivers/playwright-sim-host.ts +2 -0
  2. package/dist-lib/agent-daemon-client.cjs +1 -1
  3. package/dist-lib/agent-events.cjs +1 -1
  4. package/dist-lib/agent-identity.cjs +1 -1
  5. package/dist-lib/agent-sessions.cjs +1 -1
  6. package/dist-lib/attached-projects.cjs +1 -1
  7. package/dist-lib/auth/shared-session.cjs +1 -1
  8. package/dist-lib/backend-origin.cjs +1 -1
  9. package/dist-lib/beta.cjs +1 -1
  10. package/dist-lib/beta.mjs +1 -1
  11. package/dist-lib/bridge-constants.cjs +1 -1
  12. package/dist-lib/bridge-contract-input.cjs +1 -1
  13. package/dist-lib/bridge-contract-input.mjs +1 -1
  14. package/dist-lib/bridge-contract.cjs +1 -1
  15. package/dist-lib/bridge-contract.mjs +1 -1
  16. package/dist-lib/capture-contract.cjs +1 -1
  17. package/dist-lib/capture-contract.mjs +1 -1
  18. package/dist-lib/cli-constants.cjs +1 -1
  19. package/dist-lib/cloud-contract.cjs +1 -1
  20. package/dist-lib/cloud-contract.mjs +1 -1
  21. package/dist-lib/cloud-test-args.cjs +1 -1
  22. package/dist-lib/cloud-test-args.mjs +1 -1
  23. package/dist-lib/cloud.cjs +1 -1
  24. package/dist-lib/cloud.mjs +1 -1
  25. package/dist-lib/config.cjs +1 -1
  26. package/dist-lib/detox/index.cjs +98 -10
  27. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  28. package/dist-lib/home-paths.cjs +1 -1
  29. package/dist-lib/host/bridge-host.cjs +128 -11
  30. package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
  31. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  32. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  33. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  34. package/dist-lib/host/websocket-proxy.cjs +1 -1
  35. package/dist-lib/index.cjs +4 -4
  36. package/dist-lib/jump-to-source-babel.cjs +1 -1
  37. package/dist-lib/jump-to-source-native.cjs +1 -1
  38. package/dist-lib/kotlin-host.cjs +1 -1
  39. package/dist-lib/menu.cjs +1 -1
  40. package/dist-lib/menu.mjs +1 -1
  41. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  42. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  43. package/dist-lib/metro-production-bundle.cjs +1 -1
  44. package/dist-lib/metro-production-bundle.mjs +1 -1
  45. package/dist-lib/metro.cjs +1 -1
  46. package/dist-lib/native-app-identity.cjs +1 -1
  47. package/dist-lib/native-app-identity.mjs +1 -1
  48. package/dist-lib/native-firebase-metadata.cjs +1 -1
  49. package/dist-lib/native-firebase-metadata.mjs +1 -1
  50. package/dist-lib/plist.cjs +1 -1
  51. package/dist-lib/plist.mjs +1 -1
  52. package/dist-lib/profiles.cjs +1 -1
  53. package/dist-lib/public-brand.cjs +1 -1
  54. package/dist-lib/react-native-host-modules.cjs +1 -1
  55. package/dist-lib/react-native-host-modules.mjs +1 -1
  56. package/dist-lib/render-mode.cjs +1 -1
  57. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  58. package/dist-lib/sdk.cjs +1 -1
  59. package/dist-lib/sdk.mjs +1 -1
  60. package/dist-lib/skills.cjs +129 -12
  61. package/dist-lib/swift-compile.cjs +58 -6
  62. package/dist-lib/swift-compile.mjs +57 -6
  63. package/dist-lib/swift-package.cjs +1 -1
  64. package/dist-lib/swift-package.mjs +1 -1
  65. package/dist-lib/swift-submit.cjs +1 -1
  66. package/dist-lib/swift-submit.mjs +1 -1
  67. package/dist-lib/swift-toolchain.cjs +1 -1
  68. package/dist-lib/swift.cjs +1 -1
  69. package/dist-lib/vite-swift.cjs +383 -10
  70. package/dist-lib/vite.cjs +4 -4
  71. package/package.json +1 -1
  72. package/src/swift-compile.ts +76 -8
  73. package/src/swift-host.ts +23 -3
  74. package/src/vite-plugin-one.ts +2 -2
  75. package/src/vite-plugin.ts +10 -1
  76. package/src/xcode-project.ts +86 -1
@@ -24,6 +24,7 @@ import {
24
24
  WEBVIEW_HOST_BINDING,
25
25
  WEBVIEW_INSTANCE_ATTRIBUTE,
26
26
  WEBVIEW_SCHEME_NAVIGATION_EVENT,
27
+ WEBVIEW_NETWORK_NAVIGATION_EVENT,
27
28
  webViewAutomationHelpersSource,
28
29
  } from '../../../peach-engine/src/webview-automation-host'
29
30
  import { DISPOSABLE_BROWSER_CACHE_DIR_NAMES } from '../../src/browser-cache'
@@ -483,6 +484,7 @@ const cleanupProfile = () => {
483
484
  hostBinding: ${JSON.stringify(WEBVIEW_HOST_BINDING)},
484
485
  instanceAttribute: ${JSON.stringify(WEBVIEW_INSTANCE_ATTRIBUTE)},
485
486
  schemeNavigationEvent: ${JSON.stringify(WEBVIEW_SCHEME_NAVIGATION_EVENT)},
487
+ networkNavigationEvent: ${JSON.stringify(WEBVIEW_NETWORK_NAVIGATION_EVENT)},
486
488
  configTimingName: webViewTimingName,
487
489
  bootstrapSource: '(' + ${JSON.stringify(WEBVIEW_HOST_BOOTSTRAP_SOURCE)} + ')(' + JSON.stringify(webViewTimingName) + ');',
488
490
  },
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
package/dist-lib/beta.cjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
package/dist-lib/beta.mjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/beta.ts
4
4
  var IS_BETA = true;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/bridge-contract.ts
4
4
  var SIM_LONG_PRESS_MAX_MS = 5e3;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/bridge-contract.ts
4
4
  var REFUSED_PERFORM_STEP_TYPES = [
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/capture-contract.ts
4
4
  var RNX_SCREEN_CAPTURE_VERSION = 1;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/cloud-contract.ts
4
4
  var RNX_CLOUD_MAX_ARTIFACT_BYTES = 20 * 1024 * 1024;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/cloud-test-args.ts
4
4
  var CLOUD_TEST_ARGS_MAX_COUNT = 32;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (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);
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -840,6 +840,7 @@ function readBrowserCompositeCaptureRequest(value) {
840
840
  var WEBVIEW_INSTANCE_ATTRIBUTE = "data-peach-webview";
841
841
  var WEBVIEW_HOST_BINDING = "__peachWebViewHost";
842
842
  var WEBVIEW_SCHEME_NAVIGATION_EVENT = "peach:webview-scheme-navigation";
843
+ var WEBVIEW_NETWORK_NAVIGATION_EVENT = "peach:webview-network-navigation";
843
844
  var WEBVIEW_FRAME_NAME_PREFIX = "peach-webview:";
844
845
  function readWebViewHostRequest(value) {
845
846
  if (!value || typeof value !== "object") return null;
@@ -851,6 +852,11 @@ function readWebViewHostRequest(value) {
851
852
  const instanceId = text("instanceId");
852
853
  if (instanceId === null) return null;
853
854
  const kind = field("kind");
855
+ if (kind === "navigationDecision") {
856
+ const requestId = field("requestId");
857
+ const allow = field("allow");
858
+ return typeof requestId === "number" && typeof allow === "boolean" ? { kind, instanceId, requestId, allow } : null;
859
+ }
854
860
  if (kind === "detach") return { kind, instanceId };
855
861
  if (kind === "evaluate") {
856
862
  const js = text("js");
@@ -1014,6 +1020,7 @@ function webViewAutomationNames(timingName, bootstrapSource) {
1014
1020
  hostBinding: WEBVIEW_HOST_BINDING,
1015
1021
  instanceAttribute: WEBVIEW_INSTANCE_ATTRIBUTE,
1016
1022
  schemeNavigationEvent: WEBVIEW_SCHEME_NAVIGATION_EVENT,
1023
+ networkNavigationEvent: WEBVIEW_NETWORK_NAVIGATION_EVENT,
1017
1024
  configTimingName: timingName,
1018
1025
  bootstrapSource: `(${bootstrapSource})(${JSON.stringify(timingName)});`
1019
1026
  };
@@ -1023,6 +1030,7 @@ async function automateWebViewFrames(context, names, helpers) {
1023
1030
  const browser = context.browser();
1024
1031
  if (!browser) throw new Error("webview automation needs the browser behind its context");
1025
1032
  const browserSession = await browser.newBrowserCDPSession();
1033
+ let nextNetworkDecision = 0;
1026
1034
  const byFrameId = /* @__PURE__ */ new Map();
1027
1035
  const byInstance = /* @__PURE__ */ new Map();
1028
1036
  const beforeKeys = /* @__PURE__ */ new Set();
@@ -1179,6 +1187,28 @@ async function automateWebViewFrames(context, names, helpers) {
1179
1187
  });
1180
1188
  }).catch(() => browserSession.send("Fetch.continueRequest", { requestId })).catch(() => {
1181
1189
  });
1190
+ const decideNavigation = async (bound, detail) => {
1191
+ if (!bound.navigation) return true;
1192
+ const requestId = ++nextNetworkDecision;
1193
+ const answer = new Promise(
1194
+ (resolve2) => bound.decisions.set(requestId, resolve2)
1195
+ );
1196
+ await bound.page.evaluate(
1197
+ ([eventName, detail2]) => {
1198
+ window.dispatchEvent(new CustomEvent(eventName, { detail: detail2 }));
1199
+ },
1200
+ [
1201
+ names.networkNavigationEvent,
1202
+ {
1203
+ ...detail,
1204
+ instanceId: bound.instanceId,
1205
+ navigation: bound.navigation.id,
1206
+ requestId
1207
+ }
1208
+ ]
1209
+ );
1210
+ return answer;
1211
+ };
1182
1212
  await browserSession.send("Fetch.enable", {
1183
1213
  patterns: [{ urlPattern: "*", resourceType: "Document", requestStage: "Request" }]
1184
1214
  });
@@ -1231,6 +1261,12 @@ async function automateWebViewFrames(context, names, helpers) {
1231
1261
  const status = event.responseStatusCode;
1232
1262
  const received = event.responseHeaders ?? [];
1233
1263
  if (status >= 300 && status < 400) {
1264
+ const continueRedirect = () => settle("Fetch.fulfillRequest", {
1265
+ responseCode: status,
1266
+ responsePhrase: event.responseStatusText || void 0,
1267
+ responseHeaders: helpers.withFrameEmbedderHeaders(helpers.withoutFramingRefusals(received)).filter((header) => !/^content-(encoding|length)$/i.test(header.name)),
1268
+ body: ""
1269
+ });
1234
1270
  const location = received.find((header) => header.name.toLowerCase() === "location");
1235
1271
  if (location) {
1236
1272
  let target = "";
@@ -1241,16 +1277,47 @@ async function automateWebViewFrames(context, names, helpers) {
1241
1277
  if (helpers.isAppScheme(target))
1242
1278
  reportSchemeNavigation(bound.page, bound.instanceId, target);
1243
1279
  }
1244
- void settle("Fetch.continueRequest", {});
1280
+ if (bound.navigation && location) {
1281
+ const target = new URL(location.value, event.request.url).href;
1282
+ void decideNavigation(bound, {
1283
+ phase: "redirect",
1284
+ url: target,
1285
+ status,
1286
+ mime: ""
1287
+ }).then(
1288
+ (allow) => allow ? continueRedirect() : settle("Fetch.failRequest", { errorReason: "Aborted" })
1289
+ );
1290
+ } else void continueRedirect();
1245
1291
  return;
1246
1292
  }
1247
- void fulfill(requestId, event, [
1248
- ...helpers.withFrameEmbedderHeaders(helpers.withoutFramingRefusals(received)),
1249
- {
1250
- name: "Server-Timing",
1251
- value: `${names.configTimingName};desc="${encodeURIComponent(bound.config)}"`
1293
+ const finishResponse = async () => {
1294
+ const mime = received.find((header) => header.name.toLowerCase() === "content-type")?.value.split(";")[0].trim() ?? "";
1295
+ if (bound.navigation && bound.navigation.type !== 2) {
1296
+ const allow = await decideNavigation(bound, {
1297
+ phase: "response",
1298
+ url: event.request.url,
1299
+ status,
1300
+ mime
1301
+ });
1302
+ if (!allow) {
1303
+ await settle("Fetch.failRequest", { errorReason: "Aborted" });
1304
+ return;
1305
+ }
1252
1306
  }
1253
- ]);
1307
+ if (bound.navigation) {
1308
+ const config = JSON.parse(bound.config);
1309
+ config.documentUrl = event.request.url;
1310
+ bound.config = JSON.stringify(config);
1311
+ }
1312
+ await fulfill(requestId, event, [
1313
+ ...helpers.withFrameEmbedderHeaders(helpers.withoutFramingRefusals(received)),
1314
+ {
1315
+ name: "Server-Timing",
1316
+ value: `${names.configTimingName};desc="${encodeURIComponent(bound.config)}"`
1317
+ }
1318
+ ]);
1319
+ };
1320
+ void finishResponse();
1254
1321
  });
1255
1322
  const evaluateIn = async (bound, scripts) => {
1256
1323
  let frame = null;
@@ -1300,9 +1367,18 @@ async function automateWebViewFrames(context, names, helpers) {
1300
1367
  }
1301
1368
  const request = helpers.readRequest(value);
1302
1369
  if (!request) return;
1370
+ if (request.kind === "navigationDecision") {
1371
+ const bound2 = byInstance.get(request.instanceId);
1372
+ const decide = bound2?.decisions.get(request.requestId);
1373
+ bound2?.decisions.delete(request.requestId);
1374
+ decide?.(request.allow);
1375
+ return;
1376
+ }
1303
1377
  if (request.kind === "detach") {
1304
1378
  const bound2 = byInstance.get(request.instanceId);
1305
1379
  if (bound2) {
1380
+ for (const decide of bound2.decisions.values()) decide(false);
1381
+ bound2.decisions.clear();
1306
1382
  byFrameId.delete(bound2.frameId);
1307
1383
  await bound2.frameSession?.detach().catch(() => {
1308
1384
  });
@@ -1334,11 +1410,15 @@ async function automateWebViewFrames(context, names, helpers) {
1334
1410
  const frameId = described.node?.frameId;
1335
1411
  if (!frameId) return;
1336
1412
  const previous = byInstance.get(request.instanceId);
1413
+ if (previous?.frameId === frameId && previous.config === request.config) return;
1337
1414
  if (previous) {
1415
+ for (const decide of previous.decisions.values()) decide(false);
1416
+ previous.decisions.clear();
1338
1417
  byFrameId.delete(previous.frameId);
1339
1418
  await previous.frameSession?.detach().catch(() => {
1340
1419
  });
1341
1420
  }
1421
+ const config = JSON.parse(request.config);
1342
1422
  const bound = {
1343
1423
  instanceId: request.instanceId,
1344
1424
  page: source.page,
@@ -1346,6 +1426,8 @@ async function automateWebViewFrames(context, names, helpers) {
1346
1426
  config: request.config,
1347
1427
  afterContent: request.afterContent,
1348
1428
  incognito: request.incognito,
1429
+ navigation: config.webKit ? { id: config.webKit.navigation, type: config.webKit.navigationType } : null,
1430
+ decisions: /* @__PURE__ */ new Map(),
1349
1431
  load: { url: request.url, headers: request.headers },
1350
1432
  evaluations: Promise.resolve(),
1351
1433
  frameSession: null
@@ -1417,9 +1499,15 @@ var WEBVIEW_FRAME_BRIDGE_SOURCE = `function (config) {
1417
1499
  var systemFont = document.createElement('style');
1418
1500
  // srcdoc's base belongs to the app page; the system font belongs to the host.
1419
1501
  systemFont.textContent = config.systemFontStyle;
1420
- document.head.appendChild(systemFont);
1502
+ var fontHeadObserver = new MutationObserver(function() {
1503
+ if (!document.head) return;
1504
+ document.head.appendChild(systemFont);
1505
+ fontHeadObserver.disconnect();
1506
+ });
1507
+ fontHeadObserver.observe(document, { childList: true, subtree: true });
1508
+ if (document.head) { document.head.appendChild(systemFont); fontHeadObserver.disconnect(); }
1421
1509
  Object.defineProperty(window, 'devicePixelRatio', { configurable: true, get: function() { return config.deviceScale; } });
1422
- window.parent.postMessage({ __sootsimWebViewKind: 'webKitCommit' }, '*');
1510
+ window.parent.postMessage({ __sootsimWebViewKind: 'webKitCommit', url: config.documentUrl }, '*');
1423
1511
  window.webkit = window.webkit || {};
1424
1512
  window.webkit.messageHandlers = Object.create(null);
1425
1513
  setMessageHandlers(webKit.messageHandlers);
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.745 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.746 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;