sootsim 0.1.224 → 0.1.225

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 (141) hide show
  1. package/dist-cli/bin.js +4 -4
  2. package/dist-cli/chunks/{agent-IXTIVO4B.js → agent-2QJNGCGQ.js} +2 -2
  3. package/dist-cli/chunks/{agent-wrapper-37QGL7LZ.js → agent-wrapper-JFTDMNBA.js} +2 -2
  4. package/dist-cli/chunks/{app-fonts-CMNA7ZLB.js → app-fonts-ZF73VQCZ.js} +2 -2
  5. package/dist-cli/chunks/{assert-VE7DZN64.js → assert-VOWVK5UT.js} +2 -2
  6. package/dist-cli/chunks/{auth-BEI6S5AK.js → auth-RAUKHPE3.js} +2 -2
  7. package/dist-cli/chunks/beta-7TBS7VDG.js +2 -0
  8. package/dist-cli/chunks/{camera-WGDO6BS4.js → camera-ZMQZISLH.js} +2 -2
  9. package/dist-cli/chunks/{chunk-FR2ZFWG2.js → chunk-347KANFK.js} +1 -1
  10. package/dist-cli/chunks/{chunk-CCW5EYIU.js → chunk-3LZ4N33H.js} +1 -1
  11. package/dist-cli/chunks/{chunk-NLTKRAPS.js → chunk-3QKH7HQL.js} +3 -3
  12. package/dist-cli/chunks/{chunk-SQ2QXZ4N.js → chunk-3W4H7IIQ.js} +2 -2
  13. package/dist-cli/chunks/{chunk-6UJEQVPW.js → chunk-6P4XXLDV.js} +2 -2
  14. package/dist-cli/chunks/{chunk-WZAF6VH6.js → chunk-AHQQF4W6.js} +2 -2
  15. package/dist-cli/chunks/{chunk-RQHZYDRX.js → chunk-AWY3D6YY.js} +2 -2
  16. package/dist-cli/chunks/{chunk-QS4PGGDS.js → chunk-B7IV5YY2.js} +1 -1
  17. package/dist-cli/chunks/{chunk-OYPMYSMY.js → chunk-BI4VCL6Q.js} +2 -2
  18. package/dist-cli/chunks/{chunk-HCA46V4W.js → chunk-CRSULHXN.js} +2 -2
  19. package/dist-cli/chunks/{chunk-X4623KU6.js → chunk-D74MZDQ5.js} +2 -2
  20. package/dist-cli/chunks/{chunk-CE7KFLTO.js → chunk-DOGQUNTS.js} +1 -1
  21. package/dist-cli/chunks/{chunk-2VBAA7XJ.js → chunk-DVK6PIUQ.js} +2 -2
  22. package/dist-cli/chunks/{chunk-FB4YNNHB.js → chunk-EH5ATUDN.js} +2 -2
  23. package/dist-cli/chunks/{chunk-MF4YHHL4.js → chunk-EWQMANOX.js} +1 -1
  24. package/dist-cli/chunks/{chunk-ZTYPCXG2.js → chunk-FCWI4FXZ.js} +2 -2
  25. package/dist-cli/chunks/{chunk-GVK4Q3BA.js → chunk-FHHD7KFS.js} +1 -1
  26. package/dist-cli/chunks/{chunk-2QIGZP7G.js → chunk-HS2NYELS.js} +1 -1
  27. package/dist-cli/chunks/{chunk-24QLCYJG.js → chunk-IP4QVK56.js} +2 -2
  28. package/dist-cli/chunks/chunk-JHAL2K27.js +1 -0
  29. package/dist-cli/chunks/{chunk-4CO7SKSJ.js → chunk-JI2BFZCM.js} +2 -2
  30. package/dist-cli/chunks/{chunk-NWLTJUCZ.js → chunk-KW72IOGD.js} +1 -1
  31. package/dist-cli/chunks/{chunk-K7FLRWXM.js → chunk-LHI6SSKZ.js} +1 -1
  32. package/dist-cli/chunks/{chunk-CEBMTKID.js → chunk-MOFL2C72.js} +2 -2
  33. package/dist-cli/chunks/{chunk-VR5W6I6B.js → chunk-NCJ6UORF.js} +2 -2
  34. package/dist-cli/chunks/{chunk-HYSKRSBW.js → chunk-NCJQISNJ.js} +1 -1
  35. package/dist-cli/chunks/{chunk-FVZQMYUJ.js → chunk-NT7DIPF6.js} +1 -1
  36. package/dist-cli/chunks/{chunk-ZVNBKS5H.js → chunk-OHEMKK3X.js} +2 -2
  37. package/dist-cli/chunks/{chunk-ZTCF4L5T.js → chunk-P73P4LEJ.js} +3 -3
  38. package/dist-cli/chunks/{chunk-S6LVSOND.js → chunk-PUXJ6MG3.js} +1 -1
  39. package/dist-cli/chunks/chunk-Q6HBPMI4.js +1 -0
  40. package/dist-cli/chunks/{chunk-KRZ5WWPA.js → chunk-QH5AHGSL.js} +2 -2
  41. package/dist-cli/chunks/{chunk-OPI6PLWA.js → chunk-TFNMU5WV.js} +1 -1
  42. package/dist-cli/chunks/{chunk-5FPSA6T3.js → chunk-TGRJ7ZJD.js} +2 -2
  43. package/dist-cli/chunks/{chunk-NWN2GQ36.js → chunk-UQKFXZT7.js} +1 -1
  44. package/dist-cli/chunks/{chunk-PFYMU6QF.js → chunk-UZM7EU4D.js} +3 -3
  45. package/dist-cli/chunks/{chunk-7KD7SO3A.js → chunk-UZWRZ3ND.js} +1 -1
  46. package/dist-cli/chunks/{chunk-HFTFALJY.js → chunk-V4M52O5I.js} +2 -2
  47. package/dist-cli/chunks/{chunk-KIZV52CA.js → chunk-VIHFW4WT.js} +3 -3
  48. package/dist-cli/chunks/{chunk-4WQ36IZO.js → chunk-W67AEQ3C.js} +3 -3
  49. package/dist-cli/chunks/{chunk-OOJ5OXYG.js → chunk-WDDOFF3W.js} +2 -2
  50. package/dist-cli/chunks/{chunk-AHA4PLGQ.js → chunk-XXDT7Q4C.js} +20 -31
  51. package/dist-cli/chunks/chunk-YWDWZW74.js +3 -0
  52. package/dist-cli/chunks/{chunk-QJ2UUEBC.js → chunk-ZPXGQH3V.js} +2 -2
  53. package/dist-cli/chunks/cli-version-I6MGYDFK.js +2 -0
  54. package/dist-cli/chunks/{compat-6R6UR3NV.js → compat-WQGSKB6D.js} +3 -3
  55. package/dist-cli/chunks/{config-IWITGWOX.js → config-24NABZH5.js} +2 -2
  56. package/dist-cli/chunks/{control-NN6KYHZ7.js → control-QN3OMNZB.js} +2 -2
  57. package/dist-cli/chunks/daemon-SCUUHMKS.js +2 -0
  58. package/dist-cli/chunks/{debug-AVD27HN2.js → debug-3AWVNHV2.js} +3 -3
  59. package/dist-cli/chunks/{desktop-ARRS4W7G.js → desktop-2Y7TM6YZ.js} +3 -3
  60. package/dist-cli/chunks/{detox-7ZVE4SEU.js → detox-I5LLQ7PW.js} +2 -2
  61. package/dist-cli/chunks/{device-KCAXPE2J.js → device-4OJVHSRG.js} +2 -2
  62. package/dist-cli/chunks/{diagnose-NN2P4YHG.js → diagnose-HUXZBMVI.js} +2 -2
  63. package/dist-cli/chunks/drivers-SQFPFW7V.js +2 -0
  64. package/dist-cli/chunks/{film-YYDHQCIK.js → film-MXZ444WR.js} +3 -3
  65. package/dist-cli/chunks/flow-P3IJ4VHB.js +2 -0
  66. package/dist-cli/chunks/help-GQY5VDRA.js +2 -0
  67. package/dist-cli/chunks/{home-paths-P5BF26CV.js → home-paths-RTMWY5WD.js} +2 -2
  68. package/dist-cli/chunks/inspect-DETXTJUP.js +2 -0
  69. package/dist-cli/chunks/install-desktop-CHYTPRFO.js +2 -0
  70. package/dist-cli/chunks/{login-3C6WS5WJ.js → login-YBPCBEPD.js} +4 -4
  71. package/dist-cli/chunks/{logout-N7NHSAJ6.js → logout-JR5ZSYLS.js} +2 -2
  72. package/dist-cli/chunks/{maestro-72YHMDN3.js → maestro-HHF4ISZI.js} +3 -3
  73. package/dist-cli/chunks/{maestro-generate-N6WRP4JB.js → maestro-generate-HFAYZHUF.js} +3 -3
  74. package/dist-cli/chunks/{mode-HTGZVPBB.js → mode-KI5E5FWJ.js} +2 -2
  75. package/dist-cli/chunks/optional-demo-registry-6VYITRX4.js +2 -0
  76. package/dist-cli/chunks/{perf-G3LOBGFB.js → perf-XJXFKHQ3.js} +2 -2
  77. package/dist-cli/chunks/{record-UCC52HPB.js → record-T7IKWLEV.js} +3 -3
  78. package/dist-cli/chunks/runtime-LXVX24LC.js +2 -0
  79. package/dist-cli/chunks/{screenshot-command-UERRRDTX.js → screenshot-command-VN42XKYN.js} +10 -10
  80. package/dist-cli/chunks/screenshots-capture-IJM5ZESL.js +40 -0
  81. package/dist-cli/chunks/{serve-YYYACL4G.js → serve-C4QC2HID.js} +2 -2
  82. package/dist-cli/chunks/{setup-DOQ3CNWU.js → setup-7GKAB4SB.js} +3 -3
  83. package/dist-cli/chunks/{skills-TY7JP5HL.js → skills-FHH2POMV.js} +2 -2
  84. package/dist-cli/chunks/{storage-5G6MYKIR.js → storage-ZJMSMGT4.js} +2 -2
  85. package/dist-cli/chunks/store-DU76KFTF.js +2 -0
  86. package/dist-cli/chunks/telemetry-PZGM7U27.js +2 -0
  87. package/dist-cli/chunks/{timeline-TEZJY6OI.js → timeline-NAMSRGWR.js} +2 -2
  88. package/dist-cli/chunks/{upgrade-2VHEHNNM.js → upgrade-E7WMFJYM.js} +2 -2
  89. package/dist-cli/chunks/upload-L2ZKQQMJ.js +2 -0
  90. package/dist-cli/chunks/{version-LPLQL5Y2.js → version-H54YADEJ.js} +2 -2
  91. package/dist-cli/chunks/{web-3O74TBQP.js → web-U5F5O7TY.js} +2 -2
  92. package/dist-cli/chunks/{what-happened-SHAO2WXX.js → what-happened-A42ORDPY.js} +2 -2
  93. package/dist-lib/agent-daemon-client.cjs +1 -1
  94. package/dist-lib/agent-events.cjs +1 -1
  95. package/dist-lib/agent-identity.cjs +1 -1
  96. package/dist-lib/agent-sessions.cjs +1 -1
  97. package/dist-lib/attached-projects.cjs +1 -1
  98. package/dist-lib/auth/shared-session.cjs +1 -1
  99. package/dist-lib/backend-origin.cjs +1 -1
  100. package/dist-lib/beta.cjs +1 -1
  101. package/dist-lib/beta.mjs +1 -1
  102. package/dist-lib/bridge-constants.cjs +1 -1
  103. package/dist-lib/cli-constants.cjs +1 -1
  104. package/dist-lib/config.cjs +1 -1
  105. package/dist-lib/detox/index.cjs +8 -4
  106. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  107. package/dist-lib/home-paths.cjs +1 -1
  108. package/dist-lib/host/bridge-host.cjs +1 -1
  109. package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
  110. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  111. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  112. package/dist-lib/host/websocket-proxy.cjs +1 -1
  113. package/dist-lib/index.cjs +1 -1
  114. package/dist-lib/jump-to-source-babel.cjs +1 -1
  115. package/dist-lib/menu.cjs +1 -1
  116. package/dist-lib/menu.mjs +1 -1
  117. package/dist-lib/metro.cjs +1 -1
  118. package/dist-lib/profiles.cjs +1 -1
  119. package/dist-lib/render-mode.cjs +1 -1
  120. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  121. package/dist-lib/sdk.cjs +1 -1
  122. package/dist-lib/sdk.mjs +1 -1
  123. package/dist-lib/skills.cjs +11 -7
  124. package/dist-lib/vite.cjs +1 -1
  125. package/package.json +1 -1
  126. package/dist-cli/chunks/beta-ZAFAH443.js +0 -2
  127. package/dist-cli/chunks/chunk-EVRV7ZEQ.js +0 -1
  128. package/dist-cli/chunks/chunk-FKMYICRL.js +0 -1
  129. package/dist-cli/chunks/cli-version-EEQU4RHG.js +0 -2
  130. package/dist-cli/chunks/daemon-OOS5GYH3.js +0 -2
  131. package/dist-cli/chunks/drivers-WKXM4KAQ.js +0 -2
  132. package/dist-cli/chunks/flow-RLO6T7NN.js +0 -2
  133. package/dist-cli/chunks/help-QGPISENF.js +0 -2
  134. package/dist-cli/chunks/inspect-CCH3ID2P.js +0 -2
  135. package/dist-cli/chunks/install-desktop-SD2XL3QE.js +0 -2
  136. package/dist-cli/chunks/optional-demo-registry-CUXZZ2PW.js +0 -2
  137. package/dist-cli/chunks/runtime-RCOICIJ4.js +0 -2
  138. package/dist-cli/chunks/screenshots-capture-RBBJE7EF.js +0 -41
  139. package/dist-cli/chunks/store-SVH7YFQP.js +0 -2
  140. package/dist-cli/chunks/telemetry-Z6SP2WSB.js +0 -2
  141. package/dist-cli/chunks/upload-WXQKH3QR.js +0 -2
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  var d=Object.defineProperty;var e=(a=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(a,{get:(b,c)=>(typeof require<"u"?require:b)[c]}):a)(function(a){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+a+'" is not supported')});var f=(a,b)=>{for(var c in b)d(a,c,{get:b[c],enumerable:!0})};export{e as a,f as b};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as r}from"./chunk-X4623KU6.js";var c=["ghs_","ghp_","gho_","ghu_","github_pat_"];function d(n){return!!(n&&n.length>=20&&c.some(t=>n.startsWith(t)))}function p(){let n=process.env.SOOT_INSTALLATION_TOKEN?.trim(),t=process.env.GITHUB_TOKEN?.trim(),e=n||t;if(!d(e))return null;let o=(process.env.SOOT_REPO||process.env.GITHUB_REPOSITORY||"").trim();if(!o)return null;let[i,s]=o.includes("/")?o.split("/",2):[null,null],u=(process.env.SOOT_REPO_ID||process.env.GITHUB_REPOSITORY_ID||"").trim(),l=(process.env.SOOT_INSTALLATION_ID||process.env.GITHUB_APP_INSTALLATION_ID||"").trim();return{kind:"github",token:e,repoId:o,repositoryId:u||null,owner:i||null,repo:s||null,installationId:l||null,source:n?"soot-runner":"github-actions"}}function g(){let n=process.env.SOOTSIM_API_KEY?.trim();if(n&&n.startsWith("sk_sootsim_"))return{kind:"api-key",secret:n,source:"env"};let t=p();if(t)return t;let e=r();return e?.token?{kind:"session",token:e.token,origin:e.origin}:null}function a(n){return n.kind==="api-key"?`Bearer ${n.secret}`:`Bearer ${n.token}`}function _(n){return!n||n.kind!=="github"?null:{repoId:n.repoId,owner:n.owner??void 0,repo:n.repo??void 0,installationId:n.installationId}}export{g as a,a as b,_ as c};
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as r}from"./chunk-D74MZDQ5.js";var c=["ghs_","ghp_","gho_","ghu_","github_pat_"];function d(n){return!!(n&&n.length>=20&&c.some(t=>n.startsWith(t)))}function p(){let n=process.env.SOOT_INSTALLATION_TOKEN?.trim(),t=process.env.GITHUB_TOKEN?.trim(),e=n||t;if(!d(e))return null;let o=(process.env.SOOT_REPO||process.env.GITHUB_REPOSITORY||"").trim();if(!o)return null;let[i,s]=o.includes("/")?o.split("/",2):[null,null],u=(process.env.SOOT_REPO_ID||process.env.GITHUB_REPOSITORY_ID||"").trim(),l=(process.env.SOOT_INSTALLATION_ID||process.env.GITHUB_APP_INSTALLATION_ID||"").trim();return{kind:"github",token:e,repoId:o,repositoryId:u||null,owner:i||null,repo:s||null,installationId:l||null,source:n?"soot-runner":"github-actions"}}function g(){let n=process.env.SOOTSIM_API_KEY?.trim();if(n&&n.startsWith("sk_sootsim_"))return{kind:"api-key",secret:n,source:"env"};let t=p();if(t)return t;let e=r();return e?.token?{kind:"session",token:e.token,origin:e.origin}:null}function a(n){return n.kind==="api-key"?`Bearer ${n.secret}`:`Bearer ${n.token}`}function _(n){return!n||n.kind!=="github"?null:{repoId:n.repoId,owner:n.owner??void 0,repo:n.repo??void 0,installationId:n.installationId}}export{g as a,a as b,_ as c};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{existsSync as A,mkdirSync as v,readFileSync as M,rmSync as f,writeFileSync as h}from"fs";import{tmpdir as w}from"os";import{dirname as B,join as U,resolve as V}from"path";import{execFileSync as b}from"child_process";import{readFileSync as _}from"fs";import{createRequire as y}from"module";var c=null,p=null;function m(r){c||(c=O());try{return c(r)}catch{return null}}function C(r){p||(p=T());try{return p(r)}catch{return null}}function T(){if(process.platform==="linux")return r=>{try{return _(`/proc/${r}/comm`,"utf8").trim()||null}catch{return null}};if(process.platform==="darwin"){let r=x();return r||F()}return()=>null}function O(){let r=Number(process.env.PPID);if(Number.isFinite(r)&&r>1&&r!==process.ppid)return()=>r;if(process.platform==="linux")return D();if(process.platform==="darwin"){let n=R();return n||k()}return()=>null}function D(){return r=>{try{let n=_(`/proc/${r}/stat`,"utf8"),t=n.lastIndexOf(")");if(t<0)return null;let e=n.slice(t+1).trim().split(/\s+/),i=Number(e[1]);return Number.isFinite(i)&&i>0?i:null}catch{return null}}}var E=3,l=216,P=16,S=48,L=16;function R(){if(!process.versions?.bun)return null;try{let r=y(import.meta.url),{dlopen:n,FFIType:t}=r("bun:ffi"),e=n("/usr/lib/libproc.dylib",{proc_pidinfo:{args:[t.i32,t.i32,t.u64,t.ptr,t.i32],returns:t.i32}}),i=Buffer.alloc(l);return o=>{if(Number(e.symbols.proc_pidinfo(o,E,0n,i,l))<=0)return null;let u=i.readUInt32LE(P);return u>0?u:null}}catch{return null}}function x(){if(!process.versions?.bun)return null;try{let r=y(import.meta.url),{dlopen:n,FFIType:t}=r("bun:ffi"),e=n("/usr/lib/libproc.dylib",{proc_pidinfo:{args:[t.i32,t.i32,t.u64,t.ptr,t.i32],returns:t.i32}}),i=Buffer.alloc(l);return o=>{if(Number(e.symbols.proc_pidinfo(o,E,0n,i,l))<=0)return null;let u=i.subarray(S,S+L),I=u.indexOf(0);return u.subarray(0,I<0?u.length:I).toString("utf8")||null}}catch{return null}}function F(){return r=>{try{let t=b("lsof",["-R","-p",String(r),"-d","cwd","-a"],{encoding:"utf8",timeout:2e3,stdio:["ignore","pipe","ignore"]}).split(`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{existsSync as A,mkdirSync as M,readFileSync as v,rmSync as f,writeFileSync as h}from"fs";import{tmpdir as w}from"os";import{dirname as B,join as U,resolve as V}from"path";import{execFileSync as b}from"child_process";import{readFileSync as _}from"fs";import{createRequire as y}from"module";var c=null,p=null;function m(r){c||(c=T());try{return c(r)}catch{return null}}function C(r){p||(p=O());try{return p(r)}catch{return null}}function O(){if(process.platform==="linux")return r=>{try{return _(`/proc/${r}/comm`,"utf8").trim()||null}catch{return null}};if(process.platform==="darwin"){let r=x();return r||F()}return()=>null}function T(){let r=Number(process.env.PPID);if(Number.isFinite(r)&&r>1&&r!==process.ppid)return()=>r;if(process.platform==="linux")return D();if(process.platform==="darwin"){let n=R();return n||k()}return()=>null}function D(){return r=>{try{let n=_(`/proc/${r}/stat`,"utf8"),t=n.lastIndexOf(")");if(t<0)return null;let e=n.slice(t+1).trim().split(/\s+/),i=Number(e[1]);return Number.isFinite(i)&&i>0?i:null}catch{return null}}}var g=3,l=216,P=16,S=48,L=16;function R(){if(!process.versions?.bun)return null;try{let r=y(import.meta.url),{dlopen:n,FFIType:t}=r("bun:ffi"),e=n("/usr/lib/libproc.dylib",{proc_pidinfo:{args:[t.i32,t.i32,t.u64,t.ptr,t.i32],returns:t.i32}}),i=Buffer.alloc(l);return o=>{if(Number(e.symbols.proc_pidinfo(o,g,0n,i,l))<=0)return null;let u=i.readUInt32LE(P);return u>0?u:null}}catch{return null}}function x(){if(!process.versions?.bun)return null;try{let r=y(import.meta.url),{dlopen:n,FFIType:t}=r("bun:ffi"),e=n("/usr/lib/libproc.dylib",{proc_pidinfo:{args:[t.i32,t.i32,t.u64,t.ptr,t.i32],returns:t.i32}}),i=Buffer.alloc(l);return o=>{if(Number(e.symbols.proc_pidinfo(o,g,0n,i,l))<=0)return null;let u=i.subarray(S,S+L),I=u.indexOf(0);return u.subarray(0,I<0?u.length:I).toString("utf8")||null}}catch{return null}}function F(){return r=>{try{let t=b("lsof",["-R","-p",String(r),"-d","cwd","-a"],{encoding:"utf8",timeout:2e3,stdio:["ignore","pipe","ignore"]}).split(`
3
3
  `)[1];return t&&t.trim().split(/\s+/)[0]||null}catch{return null}}}function k(){return r=>{try{let t=b("lsof",["-R","-p",String(r),"-d","cwd","-a"],{encoding:"utf8",timeout:2e3,stdio:["ignore","pipe","ignore"]}).split(`
4
- `)[1];if(!t)return null;let e=t.trim().split(/\s+/),i=Number(e[2]);return Number.isFinite(i)&&i>1?i:null}catch{return null}}}var d=1,N="SOOTSIM_CLI_CURRENT_SIM_PATH",W=["SOOTSIM_CLI_IDENTITY","AGENTBUS_SESSION","CLAUDE_CODE_SESSION_ID","CODEX_THREAD_ID","TERM_SESSION_ID","ITERM_SESSION_ID","TMUX_PANE","STY","KITTY_WINDOW_ID","WEZTERM_PANE","ALACRITTY_WINDOW_ID","WINDOWID","VSCODE_INJECTION"],$=/^(tmux|screen)/i;function g(r,n=20){let t=r,e=m(r);if(!e||e<=1)return null;for(let i=0;i<n;i++){let o=C(e);if(o&&$.test(o))return t;let s=m(e);if(!s||s<=1)return e;t=e,e=s}return e}function Y(){for(let n of W){let t=process.env[n];if(t&&t.trim())return{key:`${n}:${t.trim()}`,source:n,stable:!0}}let r=g(process.ppid);return r&&r>1?{key:`gppid-${r}`,source:"grand-ppid",stable:!0}:{key:`pid-${process.ppid}`,source:"ppid",stable:!1}}function H(){return Y().key}function tr(){return g(process.ppid)}function a(){if(process.env[N])return V(process.env[N]);let r=H();return U(w(),`sootsim-current-sim-${r}.json`)}function J(){let r=a();if(!A(r))return null;try{let n=JSON.parse(M(r,"utf8"));return n.version!==d||typeof n.simId!="string"||!n.simId.trim()||typeof n.updatedAt!="string"?(f(r,{force:!0}),null):{version:d,simId:n.simId.trim(),updatedAt:n.updatedAt}}catch{return f(r,{force:!0}),null}}function nr(){return J()?.simId||null}function er(r){let n=r.trim();if(!n)return;let t=a();v(B(t),{recursive:!0}),h(t,JSON.stringify({version:d,simId:n,updatedAt:new Date().toISOString()},null,2)+`
4
+ `)[1];if(!t)return null;let e=t.trim().split(/\s+/),i=Number(e[2]);return Number.isFinite(i)&&i>1?i:null}catch{return null}}}var d=1,N="SOOTSIM_CLI_CURRENT_SIM_PATH",W=["SOOTSIM_CLI_IDENTITY","AGENTBUS_SESSION","CLAUDE_CODE_SESSION_ID","CODEX_THREAD_ID","TERM_SESSION_ID","ITERM_SESSION_ID","TMUX_PANE","STY","KITTY_WINDOW_ID","WEZTERM_PANE","ALACRITTY_WINDOW_ID","WINDOWID","VSCODE_INJECTION"],$=/^(tmux|screen|agentbus)/i;function E(r,n=20){let t=r,e=m(r);if(!e||e<=1)return null;for(let i=0;i<n;i++){let o=C(e);if(o&&$.test(o))return t;let s=m(e);if(!s||s<=1)return e;t=e,e=s}return e}function Y(){for(let n of W){let t=process.env[n];if(t&&t.trim())return{key:`${n}:${t.trim()}`,source:n,stable:!0}}let r=E(process.ppid);return r&&r>1?{key:`gppid-${r}`,source:"grand-ppid",stable:!0}:{key:`pid-${process.ppid}`,source:"ppid",stable:!1}}function H(){return Y().key}function tr(){return E(process.ppid)}function a(){if(process.env[N])return V(process.env[N]);let r=H();return U(w(),`sootsim-current-sim-${r}.json`)}function J(){let r=a();if(!A(r))return null;try{let n=JSON.parse(v(r,"utf8"));return n.version!==d||typeof n.simId!="string"||!n.simId.trim()||typeof n.updatedAt!="string"?(f(r,{force:!0}),null):{version:d,simId:n.simId.trim(),updatedAt:n.updatedAt}}catch{return f(r,{force:!0}),null}}function nr(){return J()?.simId||null}function er(r){let n=r.trim();if(!n)return;let t=a();M(B(t),{recursive:!0}),h(t,JSON.stringify({version:d,simId:n,updatedAt:new Date().toISOString()},null,2)+`
5
5
  `)}function ir(){f(a(),{force:!0})}export{Y as a,H as b,tr as c,nr as d,er as e,ir as f};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  var o=!0,e="public beta",t=e,n="we send anonymous error and dependency data while you use it";export{o as a,e as b,t as c,n as d};
@@ -0,0 +1 @@
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{G as R,H as f,I as x,K as w,l as g,u as $,x as b}from"./chunk-K7FLRWXM.js";import{spawn as E}from"child_process";import k from"crypto";import o from"fs";import u from"path";import{Readable as C}from"stream";import{pipeline as T}from"stream/promises";var _="https://sootbean.com",U="SOOTSIM_CDN_ORIGIN",D="SOOTSIM_RUNTIME_CHANNEL",P="SOOTSIM_RUNTIME_VERSION",X="https://sootsim.com/changelog";function y(){try{let e=JSON.parse(o.readFileSync(b(),"utf8"));return e&&typeof e=="object"?e:{}}catch{return{}}}function d(e){let n=y();return(e||process.env[U]||n.cdnOrigin||_).replace(/\/+$/,"")}function S(e){let n=y();return e||process.env[D]||n.runtimeChannel||"stable"}function O(){let e=process.env[P];if(e&&e.trim())return e.trim();let n=y();return typeof n.runtimeVersion=="string"&&n.runtimeVersion.trim()?n.runtimeVersion.trim():null}function A(e){let n=new URL(`${d(e)}/runtimes/manifest.json`);return n.searchParams.set("t",String(Date.now())),n.toString()}function j(e,n){return`${d(n)}/runtimes/sootsim-runtime-${e}.tar.gz`}async function I(e){let n=A(e),i=await fetch(n,{headers:{Accept:"application/json"}});if(!i.ok)throw new Error(`manifest fetch failed: ${i.status} ${i.statusText} (${n})`);return await i.json()}function L(e,n={}){let i=S(n.channel),t=n.version||O()||e.channels[i]?.latest;if(!t)throw new Error(`no version specified and channel '${i}' has no latest entry in the manifest`);let s=e.versions[t];if(!s)throw new Error(`version ${t} not found in manifest; available: ${Object.keys(e.versions).slice(-10).join(", ")||"(none)"}`);return{version:t,channel:i,entry:s}}async function N(e={}){R();let n=d(e.cdnOrigin),i=await I(n),{version:t,channel:s,entry:r}=L(i,e),c=g(t),a=e.setActive!==!1;if(!e.force&&o.existsSync(u.join(c,"index.html")))return a&&x(t),{version:t,channel:s,cdnOrigin:n,runtimeDir:c,installed:!1,activated:a,manifest:i};let h=r.tarball||j(t,n),m=u.join($(),`sootsim-runtime-${t}.tar.gz`);process.stderr.write(`sootsim: downloading runtime ${t}\u2026
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{G as R,H as f,I as x,K as w,l as g,u as $,x as b}from"./chunk-LHI6SSKZ.js";import{spawn as E}from"child_process";import k from"crypto";import o from"fs";import u from"path";import{Readable as C}from"stream";import{pipeline as T}from"stream/promises";var _="https://sootbean.com",U="SOOTSIM_CDN_ORIGIN",D="SOOTSIM_RUNTIME_CHANNEL",P="SOOTSIM_RUNTIME_VERSION",X="https://sootsim.com/changelog";function y(){try{let e=JSON.parse(o.readFileSync(b(),"utf8"));return e&&typeof e=="object"?e:{}}catch{return{}}}function d(e){let n=y();return(e||process.env[U]||n.cdnOrigin||_).replace(/\/+$/,"")}function S(e){let n=y();return e||process.env[D]||n.runtimeChannel||"stable"}function O(){let e=process.env[P];if(e&&e.trim())return e.trim();let n=y();return typeof n.runtimeVersion=="string"&&n.runtimeVersion.trim()?n.runtimeVersion.trim():null}function A(e){let n=new URL(`${d(e)}/runtimes/manifest.json`);return n.searchParams.set("t",String(Date.now())),n.toString()}function j(e,n){return`${d(n)}/runtimes/sootsim-runtime-${e}.tar.gz`}async function I(e){let n=A(e),i=await fetch(n,{headers:{Accept:"application/json"}});if(!i.ok)throw new Error(`manifest fetch failed: ${i.status} ${i.statusText} (${n})`);return await i.json()}function L(e,n={}){let i=S(n.channel),t=n.version||O()||e.channels[i]?.latest;if(!t)throw new Error(`no version specified and channel '${i}' has no latest entry in the manifest`);let s=e.versions[t];if(!s)throw new Error(`version ${t} not found in manifest; available: ${Object.keys(e.versions).slice(-10).join(", ")||"(none)"}`);return{version:t,channel:i,entry:s}}async function N(e={}){R();let n=d(e.cdnOrigin),i=await I(n),{version:t,channel:s,entry:r}=L(i,e),c=g(t),a=e.setActive!==!1;if(!e.force&&o.existsSync(u.join(c,"index.html")))return a&&x(t),{version:t,channel:s,cdnOrigin:n,runtimeDir:c,installed:!1,activated:a,manifest:i};let h=r.tarball||j(t,n),m=u.join($(),`sootsim-runtime-${t}.tar.gz`);process.stderr.write(`sootsim: downloading runtime ${t}\u2026
3
3
  `),await F(h,m),process.stderr.write(`sootsim: extracting runtime ${t}\u2026
4
4
  `);let v=await G(m);if(v!==r.sha256)throw o.rmSync(m,{force:!0}),new Error(`sha256 mismatch for runtime ${t}: expected ${r.sha256}, actual ${v}`);let l=u.join(u.dirname(c),`.installing-${t}-${process.pid}`);o.rmSync(l,{recursive:!0,force:!0}),o.mkdirSync(l,{recursive:!0});try{if(await H(m,l),!o.existsSync(u.join(l,"index.html")))throw new Error(`extracted tarball for runtime ${t} is missing index.html`);o.rmSync(c,{recursive:!0,force:!0}),o.renameSync(l,c)}catch(p){throw o.rmSync(l,{recursive:!0,force:!0}),p}return a&&x(t),{version:t,channel:s,cdnOrigin:n,runtimeDir:c,installed:!0,activated:a,manifest:i}}async function Y(e={}){R();let n=d(e.cdnOrigin),i=S(e.channel),t=O();if(t){let p=f(),V=o.existsSync(u.join(g(t),"index.html"));if(p===t&&V)return{checked:!0,updated:!1,reason:`runtime is pinned to ${t}`,activeVersion:p,latestVersion:t};let M=await N({version:t,channel:i,cdnOrigin:n,setActive:!1});return{checked:!0,updated:!0,reason:`runtime is pinned to ${t}`,activeVersion:t,latestVersion:t,install:M}}let s=await I(n),r=s.channels[i]?.latest;if(!r)return{checked:!0,updated:!1,reason:`channel '${i}' has no latest runtime`,activeVersion:f()};if(!s.versions[r])return{checked:!0,updated:!1,reason:`manifest is missing version ${r}`,activeVersion:f(),latestVersion:r};let a=f(),h=a?g(a):null,m=h?o.existsSync(u.join(h,"index.html")):!1;if(!(!a||!m||w(r,a)>0))return{checked:!0,updated:!1,reason:"active runtime is current",activeVersion:a,latestVersion:r};let l=await N({version:r,channel:i,cdnOrigin:n,setActive:!1});return{checked:!0,updated:!0,activeVersion:r,latestVersion:r,install:l}}async function Z(e={}){let n=f(),i=O();if(i)return{active:n,latest:i,pinned:i,outdated:n!==i};try{let t=await I(d(e.cdnOrigin)),s=S(e.channel),r=t.channels[s]?.latest??null,c=!!(r&&(!n||w(r,n)>0));return{active:n,latest:r,pinned:null,outdated:c}}catch{return{active:n,latest:null,pinned:null,outdated:!1}}}async function F(e,n){let i=await fetch(e);if(!i.ok||!i.body)throw new Error(`download failed: ${i.status} ${i.statusText} (${e})`);o.mkdirSync(u.dirname(n),{recursive:!0});let t=`${n}.partial`;try{await T(C.fromWeb(i.body),o.createWriteStream(t)),o.renameSync(t,n)}catch(s){try{o.unlinkSync(t)}catch{}throw s}}function G(e){return new Promise((n,i)=>{let t=k.createHash("sha256"),s=o.createReadStream(e);s.on("data",r=>t.update(r)),s.on("error",i),s.on("end",()=>n(t.digest("hex")))})}function H(e,n){return new Promise((i,t)=>{let s=E("tar",["-xzf",e,"-C",n],{stdio:["ignore","inherit","inherit"]});s.on("error",t),s.on("exit",r=>{r===0?i():t(new Error(`tar exited with code ${r}`))})})}export{_ as a,X as b,d as c,S as d,O as e,I as f,N as g,Y as h,Z as i};
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import{createInterface as i}from"readline";var c=()=>i({input:process.stdin,output:process.stdout});function s(o){return new Promise(n=>{let r=c();r.question(o,t=>{r.close(),n(t.trim())})})}async function u(o,n=!0){let r=n?"[Y/n]":"[y/N]";if(!process.stdin.isTTY)return console.log(` ${o} ${r} ${n?"y":"n"} (non-interactive)`),n;let t=await s(` ${o} ${r} `);return t===""?n:t.toLowerCase().startsWith("y")}async function a(o,n){console.log(`
3
3
  ${o}
4
4
  `);for(let e=0;e<n.length;e++)console.log(` ${e+1}. ${n[e]}`);if(console.log(),!process.stdin.isTTY)return console.log(` choose [1-${n.length}]: 1 (non-interactive)`),0;let r=await s(` choose [1-${n.length}]: `),t=parseInt(r,10);return t>=1&&t<=n.length?t-1:0}export{u as a,a as b};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{h as w,j as u,k as m,l}from"./chunk-NWLTJUCZ.js";var p="sootsim:settings",v=["errorReporting","colorScheme","a11yMode","a11yDepth","screenshotCanvas","screenshotBackground","screenshotText","screenshotPose","screenshotDynamicSize","alwaysShowLiveWebViews","agentProvider","onboardingComplete","betaConsentVersion","detailedTelemetry"];function S(){if(typeof window>"u")return null;let e=window.sootsimElectron;return e&&typeof e=="object"?e:null}function g(e){let t={};for(let n of v){if(!(n in e))continue;let r=e[n],o=u[n];o.validate&&!o.validate(r)||o.options&&!o.options.includes(r)||(t[n]=r)}return t}function h(e){let t={};for(let n of v)t[n]=e[n];return t}function _(){if(typeof localStorage>"u")return{};try{let e=localStorage.getItem(p);return e?g(JSON.parse(e)):{}}catch{return{}}}function V(e){if(!(typeof localStorage>"u"))try{localStorage.setItem(p,JSON.stringify(h(e)))}catch{}}function E(){let t=S()?.sharedConfig?.settings;return!t||typeof t!="object"?{}:g(t)}function K(e){let t=S();if(t?.writeSharedConfig)try{t.writeSharedConfig({settings:h(e)})}catch{}}function b(){if(typeof window>"u")return null;let e=window.__sootsimSharedConfig;return e&&typeof e=="object"?e:null}function j(){let e=b()?.settings;return!e||typeof e!="object"?{}:g(e)}function D(e){if(!b())return;let t={settings:h(e)};try{if(globalThis.__sootsimBridgeRequest?.writeSharedConfig?.(t))return}catch{}if(!(typeof fetch>"u"))try{fetch("/__sootsim/shared-config",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t),keepalive:!0}).catch(()=>{})}catch{}}function k(){let e=_(),t=j(),n=E();return{...e,...t,...n}}function R(e){V(e),K(e),D(e)}function C(e){if(typeof window>"u")return()=>{};let t=i=>{if(!(i.key!==p||i.newValue==null))try{e(g(JSON.parse(i.newValue)))}catch{}};window.addEventListener("storage",t);let n=S(),r;n?.onSharedConfigChanged&&(r=n.onSharedConfigChanged(i=>{let d=i?.settings;!d||typeof d!="object"||e(g(d))}));let c=globalThis.__sootsimBridgeRequest?.subscribeSharedConfig?.(i=>{let d=i?.settings;!d||typeof d!="object"||e(g(d))});return()=>{window.removeEventListener("storage",t),r?.(),c?.()}}var M=l(),P=k();for(let e of Object.keys(m()))delete P[e];var s={...M,...P},f=[],a=null;function y(){for(let e of f)e();R(s)}C(e=>{let t={...s},n=!1;for(let[r,o]of Object.entries(e)){let c=r;t[c]!==o&&(t[c]=o,n=!0)}if(n){s=t,a=null;for(let r of f)r()}});var L={get(e){return s[e]},set(e,t){let n=u[e];n.validate&&!n.validate(t)||n.options&&!n.options.includes(t)||s[e]!==t&&(s={...s,[e]:t},e==="deviceModel"&&(a=null),y())},getAll(){return s},apply(e){let t=!1,n={...s};for(let[r,o]of Object.entries(e)){if(o===void 0)continue;let c=r,i=u[c];i&&(i.validate&&!i.validate(o)||i.options&&!i.options.includes(o)||n[c]!==o&&(n[c]=o,t=!0))}t&&(s=n,a=null,y())},reset(){s=l(),a=null,y()},subscribe(e){return f.push(e),()=>{f=f.filter(t=>t!==e)}},getDeviceSpec(){return a||(a=w(s.deviceModel)),a},getA11yMode(){return s.a11yMode},setA11yMode(e){this.set("a11yMode",e)},getInspectMode(){return s.inspectMode},setInspectMode(e){this.set("inspectMode",e)}};export{L as a};
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{h as w,j as u,k as m,l}from"./chunk-KW72IOGD.js";var p="sootsim:settings",v=["errorReporting","colorScheme","a11yMode","a11yDepth","screenshotCanvas","screenshotBackground","screenshotText","screenshotPose","screenshotDynamicSize","alwaysShowLiveWebViews","agentProvider","onboardingComplete","betaConsentVersion","detailedTelemetry"];function S(){if(typeof window>"u")return null;let e=window.sootsimElectron;return e&&typeof e=="object"?e:null}function g(e){let t={};for(let n of v){if(!(n in e))continue;let r=e[n],o=u[n];o.validate&&!o.validate(r)||o.options&&!o.options.includes(r)||(t[n]=r)}return t}function h(e){let t={};for(let n of v)t[n]=e[n];return t}function _(){if(typeof localStorage>"u")return{};try{let e=localStorage.getItem(p);return e?g(JSON.parse(e)):{}}catch{return{}}}function V(e){if(!(typeof localStorage>"u"))try{localStorage.setItem(p,JSON.stringify(h(e)))}catch{}}function E(){let t=S()?.sharedConfig?.settings;return!t||typeof t!="object"?{}:g(t)}function K(e){let t=S();if(t?.writeSharedConfig)try{t.writeSharedConfig({settings:h(e)})}catch{}}function b(){if(typeof window>"u")return null;let e=window.__sootsimSharedConfig;return e&&typeof e=="object"?e:null}function j(){let e=b()?.settings;return!e||typeof e!="object"?{}:g(e)}function D(e){if(!b())return;let t={settings:h(e)};try{if(globalThis.__sootsimBridgeRequest?.writeSharedConfig?.(t))return}catch{}if(!(typeof fetch>"u"))try{fetch("/__sootsim/shared-config",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t),keepalive:!0}).catch(()=>{})}catch{}}function k(){let e=_(),t=j(),n=E();return{...e,...t,...n}}function R(e){V(e),K(e),D(e)}function C(e){if(typeof window>"u")return()=>{};let t=i=>{if(!(i.key!==p||i.newValue==null))try{e(g(JSON.parse(i.newValue)))}catch{}};window.addEventListener("storage",t);let n=S(),r;n?.onSharedConfigChanged&&(r=n.onSharedConfigChanged(i=>{let d=i?.settings;!d||typeof d!="object"||e(g(d))}));let c=globalThis.__sootsimBridgeRequest?.subscribeSharedConfig?.(i=>{let d=i?.settings;!d||typeof d!="object"||e(g(d))});return()=>{window.removeEventListener("storage",t),r?.(),c?.()}}var M=l(),P=k();for(let e of Object.keys(m()))delete P[e];var s={...M,...P},f=[],a=null;function y(){for(let e of f)e();R(s)}C(e=>{let t={...s},n=!1;for(let[r,o]of Object.entries(e)){let c=r;t[c]!==o&&(t[c]=o,n=!0)}if(n){s=t,a=null;for(let r of f)r()}});var L={get(e){return s[e]},set(e,t){let n=u[e];n.validate&&!n.validate(t)||n.options&&!n.options.includes(t)||s[e]!==t&&(s={...s,[e]:t},e==="deviceModel"&&(a=null),y())},getAll(){return s},apply(e){let t=!1,n={...s};for(let[r,o]of Object.entries(e)){if(o===void 0)continue;let c=r,i=u[c];i&&(i.validate&&!i.validate(o)||i.options&&!i.options.includes(o)||n[c]!==o&&(n[c]=o,t=!0))}t&&(s=n,a=null,y())},reset(){s=l(),a=null,y()},subscribe(e){return f.push(e),()=>{f=f.filter(t=>t!==e)}},getDeviceSpec(){return a||(a=w(s.deviceModel)),a},getA11yMode(){return s.a11yMode},setA11yMode(e){this.set("a11yMode",e)},getInspectMode(){return s.inspectMode},setInspectMode(e){this.set("inspectMode",e)}};export{L as a};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import{execFileSync as d,spawn as g}from"child_process";import{existsSync as m}from"fs";import{homedir as h}from"os";import{join as C}from"path";var f=["/Applications/Google Chrome.app/Contents/MacOS/Google Chrome","~/Applications/Google Chrome.app/Contents/MacOS/Google Chrome","/Applications/Chromium.app/Contents/MacOS/Chromium","~/Applications/Chromium.app/Contents/MacOS/Chromium","/Applications/Microsoft Edge.app/Contents/MacOS/Microsoft Edge","~/Applications/Microsoft Edge.app/Contents/MacOS/Microsoft Edge","/Applications/Brave Browser.app/Contents/MacOS/Brave Browser","~/Applications/Brave Browser.app/Contents/MacOS/Brave Browser","/Applications/Arc.app/Contents/MacOS/Arc","~/Applications/Arc.app/Contents/MacOS/Arc"],O=["/usr/bin/google-chrome","/usr/bin/chromium","/usr/bin/chromium-browser","/usr/bin/microsoft-edge","/usr/bin/brave-browser","/snap/bin/chromium"],w=["C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe","C:\\Program Files (x86)\\Google\\Chrome\\Application\\chrome.exe","C:\\Program Files\\Microsoft\\Edge\\Application\\msedge.exe","C:\\Program Files (x86)\\Microsoft\\Edge\\Application\\msedge.exe","C:\\Program Files\\BraveSoftware\\Brave-Browser\\Application\\brave.exe","C:\\Program Files (x86)\\BraveSoftware\\Brave-Browser\\Application\\brave.exe"],U=["google-chrome","chromium","chromium-browser","microsoft-edge","brave-browser"],M=["chrome","msedge","brave"];function A(r){return r.startsWith("~/")?C(h(),r.slice(2)):r}function a(r){for(let n of r){let o=A(n);if(m(o))return o}return null}function x(r,n){try{let e=d(n==="win32"?"where":"which",[r],{encoding:"utf8",timeout:1500,stdio:["ignore","pipe","ignore"]}).trim();return e?e.split(/\r?\n/)[0]:null}catch{return null}}function c(r=process.platform){let n=process.env.CHROME_PATH||process.env.CHROMIUM_PATH;if(n&&m(n))return n;let o=a(r==="darwin"?f:r==="win32"?w:O);if(o)return o;let e=r==="win32"?M:U;for(let t of e){let i=x(t,r);if(i)return i}return null}function p(r,n={}){if(!r)throw new Error("openUrl requires a url");let o=n.platform??process.platform;return n.newWindow?s(r,{...n,platform:o,newWindow:!0}):o==="darwin"?{command:"open",args:n.background===!1?[r]:["-g",r],via:"system"}:o==="win32"?{command:"cmd",args:["/c","start","",r],via:"system"}:{command:"xdg-open",args:[r],via:"system"}}function s(r,n={}){if(!r)throw new Error("openUrl requires a url");let o=n.platform??process.platform,e="chromiumBinary"in n?n.chromiumBinary:c(o);if(!e)throw new Error("browser launch requires Chrome, Chromium, Edge, Brave, or Arc");let t=[];return n.newWindow!==!1&&t.push("--new-window"),t.push(r),{command:e,args:t,via:"chromium",target:e}}async function l(r,n,o){return new Promise((e,t)=>{let i=g(r,n,{detached:o,stdio:"ignore"});i.once("error",t),i.once("spawn",()=>{o&&i.unref(),e(i.pid)})})}async function u(r,n={}){let o=p(r,n),e=await l(o.command,o.args,n.detached??!0);return{...o,pid:e,attachUrl:r}}async function b(r,n={}){let o=s(r,n),e=await l(o.command,o.args,n.detached??!0);return{...o,pid:e,attachUrl:r}}async function v(r,n={}){await u(r,n)}export{c as a,u as b,b as c,v as d};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as k,b as O,c as x,e as m,f as I,g as h}from"./chunk-KRZ5WWPA.js";import{d as R}from"./chunk-RQHZYDRX.js";import{G as v,H as a,I as y,J as u,K as b,l as w,z as d}from"./chunk-K7FLRWXM.js";import S from"fs";import{WebSocket as N}from"ws";async function J(t,e={}){let[s,...n]=t;if(!s||s==="--help"||s==="-h"){A();return}switch(s){case"install":return T(n,e);case"list":case"ls":return _(n);case"use":return C(n);case"remove":case"rm":return U(n);case"which":case"active":return E();case"pin":return F(n);case"unpin":return P();case"notes":case"changelog":return G(n);default:console.error(` unknown runtime subcommand: ${s}`),A(),process.exit(1)}}function A(){console.log(`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as k,b as O,c as x,e as m,f as I,g as h}from"./chunk-QH5AHGSL.js";import{d as R}from"./chunk-AWY3D6YY.js";import{G as v,H as a,I as y,J as u,K as b,l as w,z as d}from"./chunk-LHI6SSKZ.js";import S from"fs";import{WebSocket as N}from"ws";async function J(t,e={}){let[s,...n]=t;if(!s||s==="--help"||s==="-h"){A();return}switch(s){case"install":return T(n,e);case"list":case"ls":return _(n);case"use":return C(n);case"remove":case"rm":return U(n);case"which":case"active":return E();case"pin":return F(n);case"unpin":return P();case"notes":case"changelog":return G(n);default:console.error(` unknown runtime subcommand: ${s}`),A(),process.exit(1)}}function A(){console.log(`
3
3
  sootsim runtime \u2014 manage engine runtimes under ~/.sootsim/runtimes/
4
4
 
5
5
  usage:
@@ -26,4 +26,4 @@ examples:
26
26
  sootsim runtime install --channel beta
27
27
  sootsim runtime use 1.2.3
28
28
  sootsim runtime notes
29
- `)}async function T(t,e){let{version:s,flags:n}=M(t),o=n.channel??e.channel??"stable",l=n.force===!0,r=n.setActive!==!1;v(),console.log("sootsim runtime install"),console.log(` cdn: ${x()}`);try{let i=await h({version:s,channel:o,force:l,setActive:r});console.log(` version: ${i.version} (channel: ${i.channel})`),i.installed?console.log(` installed ${i.version}`):console.log(` already installed at ${i.runtimeDir}`),r&&await f(i.version)}catch(i){console.error(` ${p(i)}`),process.exit(1)}}async function f(t){y(t),console.log(` active: ${t}`),await L(t)||console.log(` (no daemon running \u2014 next sootsim/electron launch will pick up ${t})`)}async function L(t){let{isDaemonLockfileFresh:e,readDaemonLockfile:s}=await import("./home-paths-P5BF26CV.js"),n=s();if(!e(n))return!1;let o=R();return new Promise(l=>{let r=!1,i=!1,g=D=>{r||(r=!0,l(D))},c=new N(`ws://127.0.0.1:${o}`,{handshakeTimeout:800}),$=setTimeout(()=>{try{c.close()}catch{}g(i)},1500);c.on("open",()=>{try{c.send(JSON.stringify({type:"runtime:use",version:t,id:0})),i=!0}catch{}setTimeout(()=>{try{c.close()}catch{}},100)}),c.on("close",()=>{clearTimeout($),g(i)}),c.on("error",()=>{clearTimeout($),g(!1)})})}async function _(t){v();let e=u(),s=a(),n=m();if(console.log("installed:"),e.length===0)console.log(" (none)");else for(let o of e)console.log(` ${o===s?"*":" "} ${o}${o===n?" (pinned)":""}`);n&&!e.includes(n)&&console.log(`pinned: ${n} (not installed \u2014 run \`sootsim runtime install\`)`);try{let o=await I();console.log("available (latest per channel):");for(let[r,i]of Object.entries(o.channels))console.log(` ${r.padEnd(8)} ${i.latest}`);let l=Object.keys(o.versions).sort(b).reverse();if(l.length>1){console.log("hosted versions:");for(let r of l)console.log(` ${r}`)}}catch(o){console.log(`available: (could not fetch manifest: ${p(o)})`)}}async function C(t){let e=t[0];e||(console.error(" usage: sootsim runtime use <version>"),process.exit(1));let s=u();s.includes(e)||(console.error(` version ${e} is not installed`),console.error(` installed: ${s.join(", ")||"(none)"}`),console.error(` run \`sootsim runtime install ${e}\` first`),process.exit(1)),await f(e)}async function U(t){let e=t[0];e||(console.error(" usage: sootsim runtime remove <version>"),process.exit(1)),a()===e&&(console.error(` cannot remove active runtime ${e}`),console.error(" switch with `sootsim runtime use <other>` first, or install another version"),process.exit(1));let n=w(e);if(!S.existsSync(n)){console.error(` ${e} is not installed`);return}S.rmSync(n,{recursive:!0,force:!0}),console.log(` removed ${e}`)}async function E(){let t=a();if(!t){console.log(" no active runtime");return}console.log(t)}async function F(t){let e=t[0];if(!e){let n=m();n?console.log(` runtime pinned to ${n}`):(console.log(" no pin \u2014 runtime follows channel latest"),console.log(" usage: sootsim runtime pin <version>"));return}if(d({runtimeVersion:e}),console.log(` pinned runtime to ${e}`),u().includes(e)){a()!==e&&await f(e);return}try{let n=await h({version:e,setActive:!1});console.log(n.installed?` installed ${n.version}`:` already installed at ${n.runtimeDir}`),await f(e)}catch(n){console.error(` ${p(n)}`),console.error(` pin saved, but ${e} could not be installed \u2014 check \`sootsim runtime list\` for hosted versions`),process.exit(1)}}async function P(){let t=m();if(!t){console.log(" no pin set");return}d({runtimeVersion:void 0}),console.log(` unpinned (was ${t}) \u2014 runtime follows channel latest again`),console.log(" run `sootsim upgrade` to move to the latest now")}async function G(t){t.length>0&&(console.error(" usage: sootsim runtime notes"),process.exit(1));let e=a();e&&console.log(` active runtime: v${e}`),console.log(` release notes: ${O}`)}function M(t){let e={},s=[];for(let n=0;n<t.length;n++){let o=t[n];if(o==="--channel"&&n+1<t.length){e.channel=t[n+1],n++;continue}if(o.startsWith("--channel=")){e.channel=o.slice(10);continue}if(o==="--force"){e.force=!0;continue}if(o==="--set-active=false"||o==="--no-set-active"){e.setActive=!1;continue}s.push(o)}return{version:s[0]??null,flags:e}}function p(t){return t instanceof Error?t.message:String(t)}export{J as a};
29
+ `)}async function T(t,e){let{version:s,flags:n}=M(t),o=n.channel??e.channel??"stable",l=n.force===!0,r=n.setActive!==!1;v(),console.log("sootsim runtime install"),console.log(` cdn: ${x()}`);try{let i=await h({version:s,channel:o,force:l,setActive:r});console.log(` version: ${i.version} (channel: ${i.channel})`),i.installed?console.log(` installed ${i.version}`):console.log(` already installed at ${i.runtimeDir}`),r&&await f(i.version)}catch(i){console.error(` ${p(i)}`),process.exit(1)}}async function f(t){y(t),console.log(` active: ${t}`),await L(t)||console.log(` (no daemon running \u2014 next sootsim/electron launch will pick up ${t})`)}async function L(t){let{isDaemonLockfileFresh:e,readDaemonLockfile:s}=await import("./home-paths-RTMWY5WD.js"),n=s();if(!e(n))return!1;let o=R();return new Promise(l=>{let r=!1,i=!1,g=D=>{r||(r=!0,l(D))},c=new N(`ws://127.0.0.1:${o}`,{handshakeTimeout:800}),$=setTimeout(()=>{try{c.close()}catch{}g(i)},1500);c.on("open",()=>{try{c.send(JSON.stringify({type:"runtime:use",version:t,id:0})),i=!0}catch{}setTimeout(()=>{try{c.close()}catch{}},100)}),c.on("close",()=>{clearTimeout($),g(i)}),c.on("error",()=>{clearTimeout($),g(!1)})})}async function _(t){v();let e=u(),s=a(),n=m();if(console.log("installed:"),e.length===0)console.log(" (none)");else for(let o of e)console.log(` ${o===s?"*":" "} ${o}${o===n?" (pinned)":""}`);n&&!e.includes(n)&&console.log(`pinned: ${n} (not installed \u2014 run \`sootsim runtime install\`)`);try{let o=await I();console.log("available (latest per channel):");for(let[r,i]of Object.entries(o.channels))console.log(` ${r.padEnd(8)} ${i.latest}`);let l=Object.keys(o.versions).sort(b).reverse();if(l.length>1){console.log("hosted versions:");for(let r of l)console.log(` ${r}`)}}catch(o){console.log(`available: (could not fetch manifest: ${p(o)})`)}}async function C(t){let e=t[0];e||(console.error(" usage: sootsim runtime use <version>"),process.exit(1));let s=u();s.includes(e)||(console.error(` version ${e} is not installed`),console.error(` installed: ${s.join(", ")||"(none)"}`),console.error(` run \`sootsim runtime install ${e}\` first`),process.exit(1)),await f(e)}async function U(t){let e=t[0];e||(console.error(" usage: sootsim runtime remove <version>"),process.exit(1)),a()===e&&(console.error(` cannot remove active runtime ${e}`),console.error(" switch with `sootsim runtime use <other>` first, or install another version"),process.exit(1));let n=w(e);if(!S.existsSync(n)){console.error(` ${e} is not installed`);return}S.rmSync(n,{recursive:!0,force:!0}),console.log(` removed ${e}`)}async function E(){let t=a();if(!t){console.log(" no active runtime");return}console.log(t)}async function F(t){let e=t[0];if(!e){let n=m();n?console.log(` runtime pinned to ${n}`):(console.log(" no pin \u2014 runtime follows channel latest"),console.log(" usage: sootsim runtime pin <version>"));return}if(d({runtimeVersion:e}),console.log(` pinned runtime to ${e}`),u().includes(e)){a()!==e&&await f(e);return}try{let n=await h({version:e,setActive:!1});console.log(n.installed?` installed ${n.version}`:` already installed at ${n.runtimeDir}`),await f(e)}catch(n){console.error(` ${p(n)}`),console.error(` pin saved, but ${e} could not be installed \u2014 check \`sootsim runtime list\` for hosted versions`),process.exit(1)}}async function P(){let t=m();if(!t){console.log(" no pin set");return}d({runtimeVersion:void 0}),console.log(` unpinned (was ${t}) \u2014 runtime follows channel latest again`),console.log(" run `sootsim upgrade` to move to the latest now")}async function G(t){t.length>0&&(console.error(" usage: sootsim runtime notes"),process.exit(1));let e=a();e&&console.log(` active runtime: v${e}`),console.log(` release notes: ${O}`)}function M(t){let e={},s=[];for(let n=0;n<t.length;n++){let o=t[n];if(o==="--channel"&&n+1<t.length){e.channel=t[n+1],n++;continue}if(o.startsWith("--channel=")){e.channel=o.slice(10);continue}if(o==="--force"){e.force=!0;continue}if(o==="--set-active=false"||o==="--no-set-active"){e.setActive=!1;continue}s.push(o)}return{version:s[0]??null,flags:e}}function p(t){return t instanceof Error?t.message:String(t)}export{J as a};
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  function C(t,e){let r=["--max-ms","--maxMs","--maxms","--max_ms"];for(let n of r){let s=t.indexOf(n);if(s>=0&&t[s+1]){let o=Number(t[s+1]);if(Number.isFinite(o))return Math.max(100,o)}}return e}var w=new Set(["tap","double-tap","tap-text","tap-id","long-press","touch"]);function S(t){return typeof t=="string"&&w.has(t)}async function v(t){return await t.send({type:"evaluate",code:"window.__sootsimEngineState?.inspectActive === true"})===!0}async function H(t,e){if(!S(e))return!1;try{return await v(t)}catch{return!1}}async function W(t){let e=await t.send({type:"evaluate",code:"(async () => await window.__sootsimTest.getNodeCount())()"});return{nodes:typeof e=="number"?e:0}}async function B(t,e=5,r){let n=r?.format?`, ${JSON.stringify(r)}`:"",s=await t.send({type:"evaluate",code:`(async () => await window.__sootsimTest.dumpTree(${e}${n}))()`});if(r?.format==="boxes"&&typeof s=="string")try{return{depth:e,tree:JSON.parse(s)}}catch{return{depth:e,tree:s}}return{depth:e,tree:s}}async function F(t){let e=await t.send({type:"evaluate",code:"window.location.href"});return{url:typeof e=="string"?e:""}}async function j(t,e){let r=`(async () => {
3
3
  const t = window.__sootsimTest
4
4
  const mainShell = window.SootSim?.bridges?.mainShell
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as d,b as p}from"./chunk-ZVNBKS5H.js";import{execSync as c}from"child_process";function s(e){try{return c(e,{stdio:["ignore","pipe","ignore"],timeout:3e3,encoding:"utf8"}).trim()||null}catch{return null}}function o(e){let n=e?.trim();return!n||!/^\d+$/.test(n)?null:Number(n)}function m(){let e=s("git remote get-url origin");if(!e)return null;let n=e.match(/github\.com[/:]([^/\s]+)\/([^/\s]+?)(?:\.git)?\/?$/i);return n?{owner:n[1],repo:n[2]}:null}function f(){let e=process.env.GITHUB_ACTIONS==="true",n=(process.env.SOOT_REPO||process.env.GITHUB_REPOSITORY||"").trim(),[r,i]=n.includes("/")?n.split("/",2):[null,null];if(e){let u=process.env.GITHUB_REF?.match(/^refs\/pull\/(\d+)\//)?.[1];return{owner:r,repo:i,branch:process.env.GITHUB_HEAD_REF?.trim()||process.env.GITHUB_REF_NAME?.trim()||null,commitSha:process.env.GITHUB_SHA?.trim()||null,githubUsername:process.env.GITHUB_ACTOR?.trim()||null,pullRequestNumber:o(process.env.SOOT_PR_NUMBER)??o(u),githubRunId:process.env.GITHUB_RUN_ID?.trim()||null,source:"ci"}}let l=s("git rev-parse --abbrev-ref HEAD"),t=r?null:m();return{owner:r??t?.owner??null,repo:i??t?.repo??null,branch:l==="HEAD"?null:l,commitSha:s("git rev-parse HEAD"),githubUsername:null,pullRequestNumber:o(process.env.SOOT_PR_NUMBER),githubRunId:null,source:"cli"}}function R(e){if(e.length===0)return{stepCount:null,failedStepIndex:null};let n=e.find(r=>r.status==="failure");return{stepCount:e.length,failedStepIndex:n?n.stepIndex:null}}function b(e){return e.auth?e.uploadedShare?!0:e.auth.kind==="github"||process.env.GITHUB_ACTIONS==="true":!1}async function S(e){let n=e.auth??d();if(!n)return null;let r=f(),i=e.owner??(n.kind==="github"?n.owner:null)??r.owner,l=e.repo??(n.kind==="github"?n.repo:null)??r.repo;try{let t=await fetch(`${e.origin.replace(/\/$/,"")}/api/sootsim/test-runs`,{method:"POST",headers:{"content-type":"application/json",authorization:p(n)},body:JSON.stringify({kind:e.kind,source:r.source,name:e.name??void 0,prompt:e.prompt??void 0,summary:e.summary??void 0,status:e.status,failureMessage:e.failureMessage??void 0,previewShareId:e.previewShareId??void 0,owner:i??void 0,repo:l??void 0,branch:r.branch??void 0,commitSha:r.commitSha??void 0,githubUsername:r.githubUsername??void 0,pullRequestNumber:r.pullRequestNumber??void 0,githubRunId:r.githubRunId??void 0,stepCount:e.stepCount??void 0,failedStepIndex:e.failedStepIndex??void 0,durationMs:e.durationMs??void 0,flowYamlSizeBytes:e.flowYamlSizeBytes??void 0})});if(!t.ok){let a=await t.text().catch(()=>"");return console.warn(` warn: run registration failed: /api/sootsim/test-runs ${t.status}${a?`: ${a.slice(0,200)}`:""}`),null}let u=await t.json();return u.run?.id?{id:u.run.id,previewUrl:u.run.previewUrl??null,traceUrl:u.run.traceUrl??null}:(console.warn(" warn: run registration returned no id"),null)}catch(t){return console.warn(` warn: run registration failed: ${t instanceof Error?t.message:String(t)}`),null}}export{R as a,b,S as c};
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as d,b as p}from"./chunk-OHEMKK3X.js";import{execSync as c}from"child_process";function s(e){try{return c(e,{stdio:["ignore","pipe","ignore"],timeout:3e3,encoding:"utf8"}).trim()||null}catch{return null}}function o(e){let n=e?.trim();return!n||!/^\d+$/.test(n)?null:Number(n)}function m(){let e=s("git remote get-url origin");if(!e)return null;let n=e.match(/github\.com[/:]([^/\s]+)\/([^/\s]+?)(?:\.git)?\/?$/i);return n?{owner:n[1],repo:n[2]}:null}function f(){let e=process.env.GITHUB_ACTIONS==="true",n=(process.env.SOOT_REPO||process.env.GITHUB_REPOSITORY||"").trim(),[r,i]=n.includes("/")?n.split("/",2):[null,null];if(e){let u=process.env.GITHUB_REF?.match(/^refs\/pull\/(\d+)\//)?.[1];return{owner:r,repo:i,branch:process.env.GITHUB_HEAD_REF?.trim()||process.env.GITHUB_REF_NAME?.trim()||null,commitSha:process.env.GITHUB_SHA?.trim()||null,githubUsername:process.env.GITHUB_ACTOR?.trim()||null,pullRequestNumber:o(process.env.SOOT_PR_NUMBER)??o(u),githubRunId:process.env.GITHUB_RUN_ID?.trim()||null,source:"ci"}}let l=s("git rev-parse --abbrev-ref HEAD"),t=r?null:m();return{owner:r??t?.owner??null,repo:i??t?.repo??null,branch:l==="HEAD"?null:l,commitSha:s("git rev-parse HEAD"),githubUsername:null,pullRequestNumber:o(process.env.SOOT_PR_NUMBER),githubRunId:null,source:"cli"}}function R(e){if(e.length===0)return{stepCount:null,failedStepIndex:null};let n=e.find(r=>r.status==="failure");return{stepCount:e.length,failedStepIndex:n?n.stepIndex:null}}function b(e){return e.auth?e.uploadedShare?!0:e.auth.kind==="github"||process.env.GITHUB_ACTIONS==="true":!1}async function S(e){let n=e.auth??d();if(!n)return null;let r=f(),i=e.owner??(n.kind==="github"?n.owner:null)??r.owner,l=e.repo??(n.kind==="github"?n.repo:null)??r.repo;try{let t=await fetch(`${e.origin.replace(/\/$/,"")}/api/sootsim/test-runs`,{method:"POST",headers:{"content-type":"application/json",authorization:p(n)},body:JSON.stringify({kind:e.kind,source:r.source,name:e.name??void 0,prompt:e.prompt??void 0,summary:e.summary??void 0,status:e.status,failureMessage:e.failureMessage??void 0,previewShareId:e.previewShareId??void 0,owner:i??void 0,repo:l??void 0,branch:r.branch??void 0,commitSha:r.commitSha??void 0,githubUsername:r.githubUsername??void 0,pullRequestNumber:r.pullRequestNumber??void 0,githubRunId:r.githubRunId??void 0,stepCount:e.stepCount??void 0,failedStepIndex:e.failedStepIndex??void 0,durationMs:e.durationMs??void 0,flowYamlSizeBytes:e.flowYamlSizeBytes??void 0})});if(!t.ok){let a=await t.text().catch(()=>"");return console.warn(` warn: run registration failed: /api/sootsim/test-runs ${t.status}${a?`: ${a.slice(0,200)}`:""}`),null}let u=await t.json();return u.run?.id?{id:u.run.id,previewUrl:u.run.previewUrl??null,traceUrl:u.run.traceUrl??null}:(console.warn(" warn: run registration returned no id"),null)}catch(t){return console.warn(` warn: run registration failed: ${t instanceof Error?t.message:String(t)}`),null}}export{R as a,b,S as c};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as ce}from"./chunk-FB4YNNHB.js";import{b as Et,c as Rt,k as Pt}from"./chunk-OYPMYSMY.js";import{a as oe,b as P,c as D,d as Ie,e as ie,f as V,g as de,h as ge,i as Mt,j as Ft,k as Te,l as Ot}from"./chunk-OOJ5OXYG.js";import{A as wt,B as xt,E as $t,G as St,I as ue,J as vt,P as We,a as ve,b as nt,c as rt,d as it,e as at,f as lt,g as ct,h as ut,i as dt,j as pt,k as Be,l as Ce,q as je,r as mt,s as ft,t as fe,u as gt,v as ke,w as Le,x as yt,y as ht,z as bt}from"./chunk-7KD7SO3A.js";import{e as kt,g as _t,i as It,j as Tt,k as Nt,l as _e}from"./chunk-RQHZYDRX.js";import{a as tt}from"./chunk-CE7KFLTO.js";import{a as Ae,c as De,d as Q}from"./chunk-CEBMTKID.js";import{c as ot}from"./chunk-FR2ZFWG2.js";import{b as st}from"./chunk-ZTCF4L5T.js";function qe(e){return`(async () => {
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as ce}from"./chunk-EH5ATUDN.js";import{b as Et,c as Rt,k as Pt}from"./chunk-BI4VCL6Q.js";import{a as oe,b as P,c as D,d as Ie,e as ie,f as V,g as de,h as ge,i as Mt,j as Ft,k as Te,l as Ot}from"./chunk-WDDOFF3W.js";import{A as wt,B as xt,E as $t,G as St,I as ue,J as vt,P as We,a as ve,b as nt,c as rt,d as it,e as at,f as lt,g as ct,h as ut,i as dt,j as pt,k as Be,l as Ce,q as je,r as mt,s as ft,t as fe,u as gt,v as ke,w as Le,x as yt,y as ht,z as bt}from"./chunk-UZWRZ3ND.js";import{e as kt,g as _t,i as It,j as Tt,k as Nt,l as _e}from"./chunk-AWY3D6YY.js";import{a as tt}from"./chunk-DOGQUNTS.js";import{a as Ae,c as De,d as Q}from"./chunk-MOFL2C72.js";import{c as ot}from"./chunk-347KANFK.js";import{b as st}from"./chunk-P73P4LEJ.js";function qe(e){return`(async () => {
3
3
  const bridge = globalThis.SootSim && globalThis.SootSim.bridges && globalThis.SootSim.bridges.hotRemount
4
4
  if (!bridge || typeof bridge.reloadExternalApp !== 'function') return false
5
5
  await bridge.reloadExternalApp({ resetStorage: ${e?"true":"false"} })
@@ -547,7 +547,7 @@ import{a as ce}from"./chunk-FB4YNNHB.js";import{b as Et,c as Rt,k as Pt}from"./c
547
547
  `);console.log(`${t??""}
548
548
 
549
549
  ${n}
550
- `),process.exit(0)}let F=c.wsPort,N=c.simId,L=c.simIdSource,M=c.commandTimeoutMs;if(y==="get"&&p==="diagnosis"){let x=a.indexOf("diagnosis"),t=x>=0?[...a.slice(0,x),...a.slice(x+1)]:a,{runDiagnose:n}=await import("./diagnose-NN2P4YHG.js"),r=await n(["recent",...t],o);process.exitCode=r;return}if(y==="do"&&p==="scan"){let{runCamera:x}=await import("./camera-WGDO6BS4.js");await x(a,{port:o.port});return}if(p==="list"&&a.some(x=>x==="--drivers"||x==="-D")){let{buildDriverListRows:x}=await import("./drivers-WKXM4KAQ.js"),t=x();console.log(` available drivers (${t.length}):
550
+ `),process.exit(0)}let F=c.wsPort,N=c.simId,L=c.simIdSource,M=c.commandTimeoutMs;if(y==="get"&&p==="diagnosis"){let x=a.indexOf("diagnosis"),t=x>=0?[...a.slice(0,x),...a.slice(x+1)]:a,{runDiagnose:n}=await import("./diagnose-HUXZBMVI.js"),r=await n(["recent",...t],o);process.exitCode=r;return}if(y==="do"&&p==="scan"){let{runCamera:x}=await import("./camera-ZMQZISLH.js");await x(a,{port:o.port});return}if(p==="list"&&a.some(x=>x==="--drivers"||x==="-D")){let{buildDriverListRows:x}=await import("./drivers-SQFPFW7V.js"),t=x();console.log(` available drivers (${t.length}):
551
551
  `);let n=Math.max(...t.map(i=>i.id.length),6),r=Math.max(...t.map(i=>i.kind.length),4);for(let i of t){let d=i.available?"\u2713":"\u2717",m=i.id.padEnd(n),f=i.kind.padEnd(r);console.log(` ${d} ${m} ${f} ${i.description}`),i.available&&i.detail?console.log(` ${i.detail}`):!i.available&&i.reason&&console.log(` unavailable: ${i.reason}`)}return}let u=It(c),j=N||"default",A=new Set(["errors","warnings","requests","js","eval","reload","globals","perf","storage-clear","list","wait","sleep"]),R=200;function K(x){let t=x.replace(/\s+/g," ").trim();if(!t)return"";if(/^<(!doctype html|html|\?xml)|<body[\s>]/i.test(t)){let r=/<title[^>]*>([^<]+)<\/title>/i.exec(x)?.[1]?.trim(),i=/<body[^>]*>([\s\S]*?)<\//i.exec(x)?.[1]?.replace(/<[^>]+>/g," ").replace(/\s+/g," ").trim().slice(0,80),d=r||i||"html error page";return`<html ${x.length}B> "${d}" (body elided \u2014 add --json for the full payload)`}return t.length<=R?t:`${t.slice(0,R)}\u2026 (+${t.length-R} more bytes)`}function U(x){let t=x.displayUrl||x.url;return x.status!=null?`${x.method} ${t} -> ${x.status}${x.statusText?` ${x.statusText}`:""}`:x.error?`${x.method} ${t} -> ${x.error}`:`${x.method} ${t}`}async function v(x){let t=me()?400:200;try{let{settled:n,elapsed:r}=await se({bridge:x,maxMs:t,pollMs:32,stablePolls:2});n||process.stderr.write(` \u26A0 auto-wait timed out after ${r??t}ms \u2014 next command may see mid-animation state. use \`sootsim do settle\` for a longer wait.
552
552
  `)}catch{}}function O(x,t){if(t.result?.reason==="offscreen"){let{x:n,y:r,screen:i}=t.result;console.error(` tap failed: ${x} resolved to (${Math.round(n)},${Math.round(r)}), outside the ${i?.width}x${i?.height} screen`),console.error(" the node exists but is scrolled out of view \u2014 scroll it on-screen first (sootsim do scroll / swipe), then tap.");return}console.error(` tap failed: ${x} stayed visible but did not receive a hittable press after ${t.attempts} attempt${t.attempts===1?"":"s"}`),t.result&&console.error(` last result: ${JSON.stringify(t.result)}`)}async function J(){try{return await u.send({type:"evaluate",code:`(() => ({
553
553
  console: ${ke},
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as me,c as ge,d as we,e as et,f as ye,g as be,h as tt,i as Se,j as nt}from"./chunk-KIZV52CA.js";import{a as Qe}from"./chunk-FB4YNNHB.js";import{a as rt}from"./chunk-4CO7SKSJ.js";import{a as it}from"./chunk-ZTYPCXG2.js";import{h as qe,p as Ye,r as Ze,v as Xe}from"./chunk-OYPMYSMY.js";import{f as Ue}from"./chunk-SQ2QXZ4N.js";import{a as He}from"./chunk-QS4PGGDS.js";import{h as fe,m as ze}from"./chunk-OOJ5OXYG.js";import{I as J,m as We,n as je,o as Ve,p as Je}from"./chunk-7KD7SO3A.js";import{g as pe,h as he,i as Ge}from"./chunk-RQHZYDRX.js";import{a as Ke}from"./chunk-GVK4Q3BA.js";import{a as Be,b as de}from"./chunk-VR5W6I6B.js";import{d as ue,e as Ne}from"./chunk-ZTCF4L5T.js";import{g as Le,h as Ce}from"./chunk-NWLTJUCZ.js";import*as $ from"fs";import{createHash as Jt,randomUUID as Gt}from"node:crypto";import{tmpdir as K}from"os";import*as w from"path";import*as S from"fs";import*as b from"path";var Ft="inset 0 0 0 0.5px #000, inset 0 0 0 2px #757575, inset 0 0 0 5px #212121",st=1;function $t(r){let e=Ce(r),t=e.scale,n=e.statusBarHeight>0&&!e.dynamicIsland&&e.homeIndicatorHeight===0&&e.cornerRadius===0,i=e.width,o=e.height,a=n?e.width+58:e.width+e.bezelWidth*2,s=n?e.height+111+111:e.height+e.bezelWidth*2,l=9.5,u=st,p=a+l*2,g=s+st*2,I=l+(n?29:e.bezelWidth),m=n?111:e.bezelWidth,P=n?52:e.cornerRadius+e.bezelWidth,k=[{side:"right",top:e.hardwareButtons.lock.top,height:e.hardwareButtons.lock.height,width:e.hardwareButtons.width},{side:"left",top:e.hardwareButtons.ringToggle.top,height:e.hardwareButtons.ringToggle.height,width:e.hardwareButtons.width},{side:"left",top:e.hardwareButtons.volumeUp.top,height:e.hardwareButtons.volumeUp.height,width:e.hardwareButtons.width},{side:"left",top:e.hardwareButtons.volumeDown.top,height:e.hardwareButtons.volumeDown.height,width:e.hardwareButtons.width}];return{model:r,renderScale:t,outerWidth:Math.round(p*t),outerHeight:Math.round(g*t),logicalOuterWidth:p,logicalOuterHeight:g,logicalFrameWidth:a,logicalFrameHeight:s,logicalFrameLeft:l,logicalFrameTop:u,logicalScreenWidth:i,logicalScreenHeight:o,logicalScreenLeft:I,logicalScreenTop:m,logicalScreenRadius:n?0:e.cornerRadius,logicalFrameRadius:P,frameBackground:n?"linear-gradient(180deg, #1b1c20 0%, #0f1012 42%, #050608 100%)":"#000000",frameOutline:n?"0 0 0 1px #1f2125":"0 0 0 1px #333",metallicRingShadow:n?null:Ft,buttons:k,legacyHomeButton:n?{top:111+e.height+47/2,left:e.width/2-64/2+29,size:64,ring:1.5}:null,showHomeIndicator:e.homeIndicatorHeight>0,logicalHomeIndicatorStripHeight:e.homeIndicatorHeight}}function Pt(r){let e=r.side==="right",t=e?"inset(-3px -3px -3px 0)":"inset(-3px 0 -3px -3px)";return`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as me,c as ge,d as we,e as et,f as ye,g as be,h as tt,i as Se,j as nt}from"./chunk-VIHFW4WT.js";import{a as Qe}from"./chunk-EH5ATUDN.js";import{a as rt}from"./chunk-JI2BFZCM.js";import{a as it}from"./chunk-FCWI4FXZ.js";import{h as qe,p as Ye,r as Ze,v as Xe}from"./chunk-BI4VCL6Q.js";import{f as Ue}from"./chunk-3W4H7IIQ.js";import{a as He}from"./chunk-B7IV5YY2.js";import{h as fe,m as ze}from"./chunk-WDDOFF3W.js";import{I as J,m as We,n as je,o as Ve,p as Je}from"./chunk-UZWRZ3ND.js";import{g as pe,h as he,i as Ge}from"./chunk-AWY3D6YY.js";import{a as Ke}from"./chunk-FHHD7KFS.js";import{a as Be,b as de}from"./chunk-NCJ6UORF.js";import{d as ue,e as Ne}from"./chunk-P73P4LEJ.js";import{g as Le,h as Ce}from"./chunk-KW72IOGD.js";import*as $ from"fs";import{createHash as Jt,randomUUID as Gt}from"node:crypto";import{tmpdir as K}from"os";import*as w from"path";import*as S from"fs";import*as b from"path";var Ft="inset 0 0 0 0.5px #000, inset 0 0 0 2px #757575, inset 0 0 0 5px #212121",st=1;function $t(r){let e=Ce(r),t=e.scale,n=e.statusBarHeight>0&&!e.dynamicIsland&&e.homeIndicatorHeight===0&&e.cornerRadius===0,i=e.width,o=e.height,a=n?e.width+58:e.width+e.bezelWidth*2,s=n?e.height+111+111:e.height+e.bezelWidth*2,l=9.5,u=st,p=a+l*2,g=s+st*2,I=l+(n?29:e.bezelWidth),m=n?111:e.bezelWidth,P=n?52:e.cornerRadius+e.bezelWidth,k=[{side:"right",top:e.hardwareButtons.lock.top,height:e.hardwareButtons.lock.height,width:e.hardwareButtons.width},{side:"left",top:e.hardwareButtons.ringToggle.top,height:e.hardwareButtons.ringToggle.height,width:e.hardwareButtons.width},{side:"left",top:e.hardwareButtons.volumeUp.top,height:e.hardwareButtons.volumeUp.height,width:e.hardwareButtons.width},{side:"left",top:e.hardwareButtons.volumeDown.top,height:e.hardwareButtons.volumeDown.height,width:e.hardwareButtons.width}];return{model:r,renderScale:t,outerWidth:Math.round(p*t),outerHeight:Math.round(g*t),logicalOuterWidth:p,logicalOuterHeight:g,logicalFrameWidth:a,logicalFrameHeight:s,logicalFrameLeft:l,logicalFrameTop:u,logicalScreenWidth:i,logicalScreenHeight:o,logicalScreenLeft:I,logicalScreenTop:m,logicalScreenRadius:n?0:e.cornerRadius,logicalFrameRadius:P,frameBackground:n?"linear-gradient(180deg, #1b1c20 0%, #0f1012 42%, #050608 100%)":"#000000",frameOutline:n?"0 0 0 1px #1f2125":"0 0 0 1px #333",metallicRingShadow:n?null:Ft,buttons:k,legacyHomeButton:n?{top:111+e.height+47/2,left:e.width/2-64/2+29,size:64,ring:1.5}:null,showHomeIndicator:e.homeIndicatorHeight>0,logicalHomeIndicatorStripHeight:e.homeIndicatorHeight}}function Pt(r){let e=r.side==="right",t=e?"inset(-3px -3px -3px 0)":"inset(-3px 0 -3px -3px)";return`
3
3
  <div
4
4
  aria-hidden="true"
5
5
  style="
@@ -559,7 +559,7 @@ flow extension:
559
559
  })()`}),console.log(` captured ${_.length} partial replay events`)}catch(c){console.warn(` event recorder stop failed: ${c?.message||String(c)}`)}console.error(`
560
560
  x failed: ${h.message}
561
561
  `),O&&(console.log(" partial profile:"),ut(O)),E&&console.log(` partial video: ${E}`);try{let c=d.lastFailedStep,y=c?`step-${String(c.index+1).padStart(2,"0")}-${c.kind}`:"unstaged",F=w.join(s,y);await d.captureFailureBundle(F,{error:h,stepIndex:c?.index,stepKind:c?.kind,stepTarget:c?.target}),ce=F,console.log(` failure bundle: ${F}`),console.log(" (contents: screenshot.png, describe.json, a11y.txt, tree.txt, console.json, error.json)")}catch(c){try{let y=w.join(s,"error.png");await d.captureScreenshot(y),console.log(` error screenshot: ${y}`)}catch{}console.log(` (failure bundle capture failed: ${c instanceof Error?c.message:String(c)})`)}await ze(T,{errorsCommand:`sootsim get errors 5${d.simId?` --sim ${d.simId}`:""}`,warningsCommand:`sootsim get warnings 5${d.simId?` --sim ${d.simId}`:""}`,requestsCommand:`sootsim get requests 5${d.simId?` --sim ${d.simId}`:""}`}),j=1}if(await d.liveStatus?.end(j===0?"passed":"failed"),m&&(j===0||E||_))try{let h=await Yt(_??[]),c=["--origin",P,"--events",h];k&&c.push("--public-origin",k),E&&c.push("--video",E),W&&c.push("--screenshot",W),E&&L&&Number.isFinite(L)&&(c.push("--video-duration-ms",String(Math.round(L))),c.push("--recorded-duration-ms",String(Math.round(L))));let y=d.getLastRecordingStartedAtMs();y&&Number.isFinite(y)&&c.push("--recording-started-at-ms",String(Math.round(y))),v.wsPort&&c.push("--port",String(v.wsPort)),d.simId&&c.push("--sim",d.simId),re&&c.push("--open"),Pe&&c.push("--owner",Pe),ke&&c.push("--repo",ke),c.push("--run-scope",ht),H&&c.push("--billing-kind",H),console.log(`
562
- preparing preview upload\u2026`);let F=d.getFlowTraceSteps();F.length>0&&c.push("--timeline-events",await Zt(F));let V=await Xt(F,y);V&&c.push("--snapshot-manifest",V),ce&&c.push("--failure-bundle",ce);let D=d.getLastRecordingFrameStats();D&&c.push("--trace-frame-stats",await Qt(D));let{runUpload:xt}=await import("./upload-WXQKH3QR.js");Fe=await xt(c,{})}catch(h){console.error(` preview upload failed: ${h?.message||h}`),j=1}return $e=d.getFlowTraceSteps(),T.close(),ae?(d.simId&&le.add(d.simId),await qt(v.wsPort,v.commandTimeoutMs,[...le])):d.simId&&d.simId!==Y&&Ne(d.simId),await de(),j}async function qt(r,e,t){let n=[...new Set(t.filter(Boolean))];if(n.length===0)return;let i=he(r,{commandTimeoutMs:e});try{let o=await i.listSims(),a=n.filter(l=>o.some(u=>u.id===l&&u.readyState==="open"));if(a.length===0)return;let s=await Xe(i,r,e,a);await Ye(o,a),s.closed.length>0&&console.log(` closed flow sim(s): ${s.closed.join(", ")}`),s.remaining.length>0&&console.warn(` warn: flow sim(s) still connected after close: ${s.remaining.join(", ")}`)}catch(o){console.warn(` warn: failed to close flow sim(s): ${o instanceof Error?o.message:String(o)}`)}finally{i.close()}}async function Yt(r){let{gzipSync:e}=await import("zlib"),t=r.map(o=>JSON.stringify(o)).join(`
562
+ preparing preview upload\u2026`);let F=d.getFlowTraceSteps();F.length>0&&c.push("--timeline-events",await Zt(F));let V=await Xt(F,y);V&&c.push("--snapshot-manifest",V),ce&&c.push("--failure-bundle",ce);let D=d.getLastRecordingFrameStats();D&&c.push("--trace-frame-stats",await Qt(D));let{runUpload:xt}=await import("./upload-L2ZKQQMJ.js");Fe=await xt(c,{})}catch(h){console.error(` preview upload failed: ${h?.message||h}`),j=1}return $e=d.getFlowTraceSteps(),T.close(),ae?(d.simId&&le.add(d.simId),await qt(v.wsPort,v.commandTimeoutMs,[...le])):d.simId&&d.simId!==Y&&Ne(d.simId),await de(),j}async function qt(r,e,t){let n=[...new Set(t.filter(Boolean))];if(n.length===0)return;let i=he(r,{commandTimeoutMs:e});try{let o=await i.listSims(),a=n.filter(l=>o.some(u=>u.id===l&&u.readyState==="open"));if(a.length===0)return;let s=await Xe(i,r,e,a);await Ye(o,a),s.closed.length>0&&console.log(` closed flow sim(s): ${s.closed.join(", ")}`),s.remaining.length>0&&console.warn(` warn: flow sim(s) still connected after close: ${s.remaining.join(", ")}`)}catch(o){console.warn(` warn: failed to close flow sim(s): ${o instanceof Error?o.message:String(o)}`)}finally{i.close()}}async function Yt(r){let{gzipSync:e}=await import("zlib"),t=r.map(o=>JSON.stringify(o)).join(`
563
563
  `)+(r.length?`
564
564
  `:""),n=e(Buffer.from(t,"utf8")),i=w.join(K(),`sootsim-events-${Date.now()}.jsonl.gz`);return $.writeFileSync(i,n),console.log(` events: ${r.length} written to ${i} (${n.length} bytes gz)`),i}async function Zt(r){let{gzipSync:e}=await import("zlib"),t=r.map((a,s)=>({schemaVersion:1,t:a.endedAtMs,seq:1e6+s,context:"host",kind:"flow-step",id:`flow-step-${a.stepIndex}`,data:{stepIndex:a.stepIndex,stepNumber:a.stepIndex+1,stepName:a.stepName,...a.targetLabel?{targetLabel:a.targetLabel}:{},status:a.status,durationMs:a.durationMs,startedAtMs:a.startedAtMs,endedAtMs:a.endedAtMs,...a.error?{error:a.error}:{}}})),n=t.map(a=>JSON.stringify(a)).join(`
565
565
  `)+`
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{H as I,m as B,n as E,o as y,t as v,v as A}from"./chunk-7KD7SO3A.js";import{h,l as N,m as P}from"./chunk-RQHZYDRX.js";var q={timeoutMs:1800,settleMs:48,startWindowMs:64};function w(e){return new Promise(t=>setTimeout(t,e))}function U(e){return e.includes("--json")}function Y(e){process.stdout.write(`${JSON.stringify(e??null,null,2)}
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{H as I,m as B,n as E,o as y,t as v,v as A}from"./chunk-UZWRZ3ND.js";import{h,l as N,m as P}from"./chunk-AWY3D6YY.js";var q={timeoutMs:1800,settleMs:48,startWindowMs:64};function w(e){return new Promise(t=>setTimeout(t,e))}function U(e){return e.includes("--json")}function Y(e){process.stdout.write(`${JSON.stringify(e??null,null,2)}
3
3
  `)}function V(e){process.stderr.write(`${e}
4
4
  `)}function b(e,t=Date.now()){let r=new Date(e),n=`${S(r.getHours())}:${S(r.getMinutes())}:${S(r.getSeconds())}`,s=t-e;if(s<0)return n;let o=Math.round(s/1e3);return o<60?`${n} +${o}s`:o<3600?`${n} +${Math.round(o/60)}m`:o<86400?`${n} +${Math.round(o/3600)}h`:`${n} +${Math.round(o/86400)}d`}function S(e){return e<10?`0${e}`:String(e)}async function D(e,t,...r){return N(e,`__sootsimTest.${t}`,...r)}async function k(e,t,...r){return P(e,`SootSim.bridges.mainShell.${t}`,...r)}async function z(e,t={}){try{let r=await D(e,"waitForScreenTransitions",q);if(!t.verbose||!r?.started)return;if(r.timedOut){console.log(` screen transition still active after ${r.waitedMs}ms; continuing`);return}r.waitedMs>0&&console.log(` waited ${r.waitedMs}ms for screen transition settle`)}catch{}}async function K(e,t,r,...n){let s=Date.now()+Math.max(0,r);for(;;)try{return await k(e,t,...n)}catch(o){if(!I(o)||Date.now()>=s)throw o;await w(50)}}async function Q(e,t,r,n={}){let s=n.attempts??30,o=n.intervalMs??500,l=n.minNodeCount??10;for(let a=0;a<s;a++){let u=h(e,{commandTimeoutMs:t,simId:r,simIdSource:n.simIdSource});try{let c=await u.send({type:"evaluate",code:"(async () => (await window.__sootsimTest?.getNodeCount()) || 0)()"});if(typeof c=="number"&&c>l)return{bridge:u,count:c}}catch{}u.close(),await w(o)}return null}async function X(e,t,r,n={}){let s=n.timeoutMs??8e3,o=n.intervalMs??250,l=Date.now()+s;for(;Date.now()<l;){let a=h(e,{commandTimeoutMs:t,simId:r,simIdSource:n.simIdSource});try{return await a.send({type:"evaluate",code:"1"}),a}catch{a.close()}await w(o)}return null}async function Z(e,t={}){let r=t.timeoutMs??1e4,n=t.errorGraceMs??3e3,s=t.pollIntervalMs??200,o=Date.now(),l=o+r,a=-1,u=o,c=null,d=!1,m={ready:!1,source:"timeout",elapsedMs:0,nodes:0,targets:0,flag:void 0,loadingText:"",externalReady:null,externalStatus:"",externalError:"",errors:0};for(;Date.now()<l;){try{let i=await e.send({type:"evaluate",code:B}),g=Date.now()-o,f=Number(i?.nodes)||0,$=Number(i?.targets)||0,x=Number(i?.errors)||0,C=i?.flag===!0,p=i?.externalReady,T=typeof i?.loadingText=="string"?i.loadingText.trim():"",W=typeof i?.externalStatus=="string"?i.externalStatus.trim():"",M=typeof i?.externalError=="string"?i.externalError.trim():"",R=typeof i?.externalError=="string"&&M.length>0;if(c=p,d=R,f!==a&&(a=f,u=g),m={ready:!1,source:"timeout",elapsedMs:g,nodes:f,targets:$,flag:i?.flag,loadingText:T,externalReady:typeof p=="boolean"?p:null,externalStatus:W,externalError:M,errors:x},C&&p!==!1&&!R&&!T&&y({nodes:f,targets:$})&&g-u>=E)return{...m,ready:!0,source:"flag"};if(g>=n&&x>0&&!C)return{...m,ready:!1,source:"error-bail"}}catch{}await w(s)}return c!==!1&&!d&&!m.loadingText&&y(m)?{...m,ready:!0,source:"nodes-fallback"}:{...m,ready:!1,source:"timeout",elapsedMs:Date.now()-o}}function O(e){let t=e.displayUrl||e.url;return e.status!=null?`${e.method} ${t} -> ${e.status}${e.statusText?` ${e.statusText}`:""}`:e.error?`${e.method} ${t} -> ${e.error}`:`${e.method} ${t}`}async function _(e,t,...r){return e.send({type:"call",path:`__sootsimTest.${t}`,args:r})}async function F(e,t={}){let r=await e.send({type:"evaluate",code:A});if(!r||typeof r!="object")return;let n=Math.max(0,Number(r.errors)||0),s=Math.max(0,Number(r.warnings)||0);if(n===0&&s===0)return;let o=[];if(n>0&&o.push(`${n} console error${n===1?"":"s"}`),s>0&&o.push(`${s} console warning${s===1?"":"s"}`),console.log(`
5
5
  console: ${o.join(", ")}`),t.errorsCommand&&console.log(` inspect: ${t.errorsCommand}`),s>0&&t.warningsCommand&&console.log(` inspect: ${t.warningsCommand}`),!t.includeTail||n===0)return;let l=await v(e,5);if(!(!Array.isArray(l)||l.length===0)){console.log(`
@@ -1,6 +1,6 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as m,b as I}from"./chunk-GVK4Q3BA.js";import{a as w,b as _,c as E}from"./chunk-NWN2GQ36.js";import{c as O}from"./chunk-ZTCF4L5T.js";import{G as k,o as D,q as f}from"./chunk-K7FLRWXM.js";import h from"fs";import v from"path";var c="default",$="profiles.json",a=1;function s(e){let r=e.trim();if(!r)throw new Error("profile id is required");if(!/^[A-Za-z0-9][A-Za-z0-9._-]*$/.test(r))throw new Error("profile ids must start with a letter or number and contain only letters, numbers, dot, dash, or underscore");if(r==="."||r==="..")throw new Error(`invalid profile id: ${r}`);return r}function g(){return v.join(f(),$)}function F(e){return`sootsim-profile-${s(e)}`}function B(e){return v.join(D(),"Partitions",F(e))}function b(e){return v.join(f(),"playwright",s(e))}function y(){try{let e=JSON.parse(h.readFileSync(g(),"utf8"));if(!e||e.version!==a)return{version:a,profiles:[]};let r=Array.isArray(e.profiles)?e.profiles.filter(t=>!!t&&typeof t.id=="string"&&typeof t.createdAt=="string"&&typeof t.updatedAt=="string").map(t=>({id:s(t.id),createdAt:t.createdAt,updatedAt:t.updatedAt})):[];return{version:a,profiles:r}}catch{return{version:a,profiles:[]}}}function T(e){return[...e].sort((r,t)=>r.id===c?-1:t.id===c?1:r.id.localeCompare(t.id))}function P(e){if(e.profiles.some(t=>t.id===c))return{...e,profiles:T(e.profiles)};let r=new Date().toISOString();return{version:a,profiles:T([{id:c,createdAt:r,updatedAt:r},...e.profiles])}}function S(e){k();let r=P(e),t=`${g()}.tmp`;return h.writeFileSync(t,`${JSON.stringify(r,null,2)}
3
- `,"utf8"),h.renameSync(t,g()),r}function q(){return S(y()).profiles}function j(e){let r=s(e);return q().find(t=>t.id===r)??null}function C(e=c){let r=s(e),t=j(r);return t||H(r)}function H(e){let r=s(e),t=P(y());if(t.profiles.some(i=>i.id===r))throw new Error(`profile already exists: ${r}`);let n=new Date().toISOString(),o={id:r,createdAt:n,updatedAt:n};return S({version:a,profiles:[...t.profiles,o]}),o}function pe(e){let r=s(e);if(r===c)throw new Error("the default profile cannot be deleted; clear it instead");let t=P(y()),n=t.profiles.find(o=>o.id===r);if(!n)throw new Error(`profile not found: ${r}`);return S({version:a,profiles:t.profiles.filter(o=>o.id!==r)}),z(r),n}function z(e){let r=s(e);for(let t of[B(r),b(r)])try{h.rmSync(t,{recursive:!0,force:!0})}catch{}}function K(){let e=w();return e?{available:!0,reason:null,detail:e}:{available:!1,reason:"no chromium-family browser found (chrome, chromium, edge, brave, arc)"}}async function Y(e){if(e.headless)return{launched:!1,message:"the chromium driver launches a visible browser window and cannot run headless \u2014 a headless `chrome --headless=new` process exits immediately and the sim never connects. for headless automation use `--driver playwright`."};let r=w();if(!r)return{launched:!1,message:"chromium not found \u2014 install chrome or run `sootsim list --drivers`"};if(!e.url)return{launched:!1,message:"chromium driver requires a target url"};if(e.profileId||e.ephemeralProfile)return{launched:!1,message:"profiles require electron or playwright; browser tabs use your current Chrome profile"};try{let t=await E(e.url,{detached:e.detached??!0});return{launched:!0,message:`chromium launched \u2192 ${e.url}`,pid:t.pid,target:t.target??r,attachUrl:e.url}}catch(t){return{launched:!1,message:`chromium spawn failed: ${t instanceof Error?t.message:String(t)}`}}}var A={id:"chromium",name:"chromium",description:"system chrome / chromium / edge \u2014 visible window (headless: use playwright)",kind:"browser",availability:K,launch:Y};function V(){let e=m();return e?{available:!0,reason:null,detail:`${e.kind} @ ${e.path}`}:{available:!1,reason:"sootsim desktop app not installed (run `sootsim desktop install`)"}}async function J(e){let r=m();if(!r)return{launched:!1,message:"sootsim desktop app not installed"};try{let t=await I(e.url,r,{device:e.device,profileId:e.profileId,ephemeralProfile:e.ephemeralProfile});return t.launched?{launched:!0,message:e.url?`electron launched via ${t.via} \u2192 ${e.url}`:`electron launched via ${t.via}`,target:t.target,attachUrl:e.url}:{launched:!1,message:"desktop companion failed to start"}}catch(t){return{launched:!1,message:`electron launch failed: ${t instanceof Error?t.message:String(t)}`}}}var M={id:"electron",name:"electron",description:"sootsim desktop companion app (native window, menu bar)",kind:"native",availability:V,launch:J};import{spawn as X}from"child_process";import{closeSync as Z,mkdtempSync as Q,openSync as ee,readFileSync as re}from"fs";import{createRequire as te}from"module";import{tmpdir as L}from"os";import{join as R}from"path";var ne=`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as m,b as _}from"./chunk-FHHD7KFS.js";import{a as w,b as I,c as E}from"./chunk-UQKFXZT7.js";import{c as k}from"./chunk-P73P4LEJ.js";import{G as O,o as D,q as f}from"./chunk-LHI6SSKZ.js";import h from"fs";import v from"path";var c="default",$="profiles.json",a=1;function s(e){let r=e.trim();if(!r)throw new Error("profile id is required");if(!/^[A-Za-z0-9][A-Za-z0-9._-]*$/.test(r))throw new Error("profile ids must start with a letter or number and contain only letters, numbers, dot, dash, or underscore");if(r==="."||r==="..")throw new Error(`invalid profile id: ${r}`);return r}function g(){return v.join(f(),$)}function G(e){return`sootsim-profile-${s(e)}`}function B(e){return v.join(D(),"Partitions",G(e))}function b(e){return v.join(f(),"playwright",s(e))}function y(){try{let e=JSON.parse(h.readFileSync(g(),"utf8"));if(!e||e.version!==a)return{version:a,profiles:[]};let r=Array.isArray(e.profiles)?e.profiles.filter(t=>!!t&&typeof t.id=="string"&&typeof t.createdAt=="string"&&typeof t.updatedAt=="string").map(t=>({id:s(t.id),createdAt:t.createdAt,updatedAt:t.updatedAt})):[];return{version:a,profiles:r}}catch{return{version:a,profiles:[]}}}function T(e){return[...e].sort((r,t)=>r.id===c?-1:t.id===c?1:r.id.localeCompare(t.id))}function P(e){if(e.profiles.some(t=>t.id===c))return{...e,profiles:T(e.profiles)};let r=new Date().toISOString();return{version:a,profiles:T([{id:c,createdAt:r,updatedAt:r},...e.profiles])}}function S(e){O();let r=P(e),t=`${g()}.tmp`;return h.writeFileSync(t,`${JSON.stringify(r,null,2)}
3
+ `,"utf8"),h.renameSync(t,g()),r}function q(){return S(y()).profiles}function j(e){let r=s(e);return q().find(t=>t.id===r)??null}function A(e=c){let r=s(e),t=j(r);return t||H(r)}function H(e){let r=s(e),t=P(y());if(t.profiles.some(n=>n.id===r))throw new Error(`profile already exists: ${r}`);let o=new Date().toISOString(),i={id:r,createdAt:o,updatedAt:o};return S({version:a,profiles:[...t.profiles,i]}),i}function pe(e){let r=s(e);if(r===c)throw new Error("the default profile cannot be deleted; clear it instead");let t=P(y()),o=t.profiles.find(i=>i.id===r);if(!o)throw new Error(`profile not found: ${r}`);return S({version:a,profiles:t.profiles.filter(i=>i.id!==r)}),z(r),o}function z(e){let r=s(e);for(let t of[B(r),b(r)])try{h.rmSync(t,{recursive:!0,force:!0})}catch{}}function K(){let e=w();return e?{available:!0,reason:null,detail:e}:{available:!1,reason:"no chromium-family browser found (chrome, chromium, edge, brave, arc)"}}async function Y(e){if(e.headless)return{launched:!1,message:"the chromium driver launches a visible browser window and cannot run headless \u2014 a headless `chrome --headless=new` process exits immediately and the sim never connects. for headless automation use `--driver playwright`."};let r=w();if(!r)return{launched:!1,message:"chromium not found \u2014 install chrome or run `sootsim list --drivers`"};if(!e.url)return{launched:!1,message:"chromium driver requires a target url"};if(e.profileId||e.ephemeralProfile)return{launched:!1,message:"profiles require electron or playwright; browser tabs use your current Chrome profile"};try{let t=await E(e.url,{detached:e.detached??!0});return{launched:!0,message:`chromium launched \u2192 ${e.url}`,pid:t.pid,target:t.target??r,attachUrl:e.url}}catch(t){return{launched:!1,message:`chromium spawn failed: ${t instanceof Error?t.message:String(t)}`}}}var C={id:"chromium",name:"chromium",description:"system chrome / chromium / edge \u2014 visible window (headless: use playwright)",kind:"browser",availability:K,launch:Y};function V(){let e=m();return e?{available:!0,reason:null,detail:`${e.kind} @ ${e.path}`}:{available:!1,reason:"sootsim desktop app not installed (run `sootsim desktop install`)"}}async function J(e){let r=m();if(!r)return{launched:!1,message:"sootsim desktop app not installed"};try{let t=await _(e.url,r,{device:e.device,profileId:e.profileId,ephemeralProfile:e.ephemeralProfile});return t.launched?{launched:!0,message:e.url?`electron launched via ${t.via} \u2192 ${e.url}`:`electron launched via ${t.via}`,target:t.target,attachUrl:e.url}:{launched:!1,message:"desktop companion failed to start"}}catch(t){return{launched:!1,message:`electron launch failed: ${t instanceof Error?t.message:String(t)}`}}}var M={id:"electron",name:"electron",description:"sootsim desktop companion app (native window, menu bar)",kind:"native",availability:V,launch:J};import{spawn as X}from"child_process";import{closeSync as Z,mkdtempSync as Q,openSync as ee,readFileSync as re}from"fs";import{createRequire as te}from"module";import{tmpdir as L}from"os";import{join as R}from"path";var oe=`
4
4
  const modulePath = process.env.SOOTSIM_PW_MODULE;
5
5
  const url = process.env.SOOTSIM_PW_URL;
6
6
  // the WS bridge port the sim page must register with, injected below as
@@ -33,7 +33,7 @@ const extraChromeArgs = (process.env.SOOTSIM_PW_CHROME_ARGS || '')
33
33
  const browserEngine = process.env.SOOTSIM_PW_BROWSER || 'chromium';
34
34
  // Local CanvasKit/WebGL work must never fall back to Playwright's software
35
35
  // renderer. CI may use the bundled browser for non-interactive coverage, but
36
- // local test drives fail closed unless a hardware-backed branded browser is
36
+ // local test drives fail closed unless the hardware-backed test browser is
37
37
  // proven after launch.
38
38
  const hardwareGpuRequired =
39
39
  browserEngine === 'chromium' &&
@@ -63,17 +63,15 @@ const { join } = require('path');
63
63
  // network/storage utilities). they reparent to launchd/init and survive, each
64
64
  // one busy enough to peg CPU at 100%+. close() only reaches the root.
65
65
  //
66
- // the prior approach was \`pgrep -f ms-playwright/[c]hromium\` \u2014 that filter is
67
- // deliberately narrow so a system Chrome (channel:'chrome' \u2192 /Applications/
68
- // Google Chrome.app/...) is never matched and never killed. but channel:'chrome'
69
- // is exactly the default path, so the reaper was a no-op in the common case and
70
- // every aborted/closed \`sootsim open\` leaked a renderer + gpu helper burning
71
- // 100%+ CPU until manually killed (multiple incidents 2026-06).
66
+ // the prior approach was \`pgrep -f ms-playwright/[c]hromium\`. it never matched
67
+ // system Chrome, so the reaper was a no-op in the common case and every
68
+ // aborted/closed \`sootsim open\` leaked a renderer + gpu helper burning 100%+
69
+ // CPU until manually killed (multiple incidents 2026-06).
72
70
  //
73
71
  // fix: identify our chrome tree by its UNIQUE user-data-dir. every helper a
74
72
  // chrome root spawns inherits \`--user-data-dir=<dir>\` in its cmdline, so
75
73
  // \`pgrep -f <profileDir>\` finds exactly the tree we launched and nothing else
76
- // \u2014 system Chrome and bundled playwright chromium alike. as a side benefit we
74
+ // \u2014 Chrome for Testing and bundled playwright chromium alike. as a side benefit we
77
75
  // no longer need the launch / launchPersistentContext fork: we ALWAYS use a
78
76
  // profile dir (mkdtemp'd if the caller didn't pass one, then removed at exit).
79
77
  const reapEnabled = process.platform !== 'win32';
@@ -259,11 +257,11 @@ const cleanupProfile = () => {
259
257
  if (typeof ownerWatch.unref === 'function') ownerWatch.unref();
260
258
  };
261
259
  startOwnerWatch();
262
- // Prefer real Google Chrome (looks like the user's browser, no leftover
263
- // "Chrome for Testing" processes). Local rendering is fail-closed: bundled
264
- // Chromium is allowed only under CI because its headless shell commonly has
265
- // no GPU and silently chooses SwiftShader. Set SOOTSIM_PW_CHANNEL to pin a
266
- // branded Chrome/Edge channel. NOTE: this is NOT enough to make \`sootsim perf cpu\`
260
+ // Local rendering uses Playwright's full Chrome for Testing app. On macOS its
261
+ // com.google.chrome.for.testing identity cannot intercept open/quit events for
262
+ // the user's com.google.Chrome browser. CI may use chromium_headless_shell;
263
+ // local rendering fails closed because that shell has no GPU and silently
264
+ // chooses SwiftShader. NOTE: this is NOT enough to make \`sootsim perf cpu\`
267
265
  // work \u2014 that profiles the tenant *worker*, and the JS Self-Profiler API
268
266
  // cannot be constructed in a dedicated worker (see
269
267
  // worker-handlers/cpu-profile.ts). cpu-profile needs a CDP-based profiler
@@ -276,13 +274,6 @@ const cleanupProfile = () => {
276
274
  context = await pw[browserEngine].launchPersistentContext(profileDir, { headless, viewport, deviceScaleFactor });
277
275
  process.stderr.write('[playwright-driver] launched ' + browserEngine + '\\n');
278
276
  } else {
279
- const pinnedChannel = process.env.SOOTSIM_PW_CHANNEL || '';
280
- const brandedChannel = /^(?:chrome(?:-beta|-dev|-canary)?|msedge(?:-beta|-dev|-canary)?)$/;
281
- if (hardwareGpuRequired && pinnedChannel && !brandedChannel.test(pinnedChannel)) {
282
- throw new Error(
283
- '[playwright-driver] local GPU rendering requires a branded Chrome/Edge channel; refused "' + pinnedChannel + '"'
284
- );
285
- }
286
277
  if (
287
278
  hardwareGpuRequired &&
288
279
  extraChromeArgs.some((arg) =>
@@ -292,11 +283,9 @@ const cleanupProfile = () => {
292
283
  ) {
293
284
  throw new Error('[playwright-driver] refused SwiftShader launch arguments');
294
285
  }
295
- const channelsToTry = pinnedChannel
296
- ? [pinnedChannel]
297
- : hardwareGpuRequired
298
- ? ['chrome']
299
- : ['chrome', null]; // null = bundled chromium, CI only
286
+ // one browser path per environment: the full, separately identified test app
287
+ // locally; chromium_headless_shell on CI. never launch a branded user browser.
288
+ const channelsToTry = hardwareGpuRequired ? ['chromium'] : [null];
300
289
  const launchWith = async (channel) => {
301
290
  const opts = channel
302
291
  ? { headless, channel, viewport, deviceScaleFactor }
@@ -318,7 +307,7 @@ const cleanupProfile = () => {
318
307
  '--disable-renderer-backgrounding',
319
308
  ];
320
309
  if (channel) {
321
- // branded chrome can bind the real platform GPU \u2014 force the native
310
+ // the full test browser can bind the real platform GPU \u2014 force the native
322
311
  // ANGLE backend and strip playwright's --enable-unsafe-swiftshader
323
312
  // default arg. without both, headless chrome silently falls back to
324
313
  // swiftshader software rendering for the CanvasKit/WebGL canvas and
@@ -473,6 +462,6 @@ const cleanupProfile = () => {
473
462
  process.stderr.write(String((err && err.stack) || err) + '\\n');
474
463
  process.exit(1);
475
464
  });
476
- `;function W(){let e=[process.cwd()+"/"];try{process.argv[1]&&e.push(process.argv[1])}catch{}for(let r of e)try{let t=te(r);for(let n of["playwright","playwright-chromium","playwright-core"])try{return{spec:n,modulePath:t.resolve(n)}}catch{}}catch{}return null}function oe(){let e=W();return e?{available:!0,reason:null,detail:`resolved via ${e.spec}`}:{available:!1,reason:"playwright not installed in the current workspace"}}function ie(e,r){return process.platform!=="linux"||e.headless||process.env.DISPLAY||process.env.WAYLAND_DISPLAY||!/missing x server|cannot open display|x server|x11/i.test(r)?null:" hint: linux without DISPLAY/WAYLAND_DISPLAY \u2014 rerun without --headed (or add --headless) to run playwright headless."}function se(e){return e.profileId?b(C(e.profileId).id):e.ephemeralProfile?Q(R(L(),"sootsim-playwright-profile-")):""}async function ae(e){let r=W();if(!r)return{launched:!1,message:"playwright not installed \u2014 run `bun add -D playwright` first"};if(!e.url)return{launched:!1,message:"playwright driver requires a target url"};let t=R(L(),`sootsim-playwright-host-${Date.now().toString(36)}-${process.pid}.log`),n=`${t}.connected`,o=ee(t,"a");try{let i=O(),p=X(process.execPath,["-e",ne],{detached:!0,stdio:["ignore","ignore",o],env:{...process.env,SOOTSIM_PW_MODULE:r.modulePath,SOOTSIM_PW_URL:e.url,SOOTSIM_PW_BRIDGE_PORT:e.bridgePort?String(e.bridgePort):"",SOOTSIM_PW_HEADLESS:e.headless??!0?"1":"0",SOOTSIM_PW_USERDATADIR:se(e),SOOTSIM_PW_CDP_PORT:e.cdpPort?String(e.cdpPort):"",SOOTSIM_PW_BROWSER:e.browser??"",SOOTSIM_PW_VIEWPORT:e.viewport?`${e.viewport.width}x${e.viewport.height}`:"",SOOTSIM_PW_CONNECTED_ACK_FILE:n,SOOTSIM_PW_CONNECT_TIMEOUT_MS:String(e.connectTimeoutMs??12e4),SOOTSIM_PW_OWNER_PID:i&&i>1?String(i):""}});p.unref();let x=await new Promise(l=>{let u=setTimeout(()=>l(null),4e3);p.once("exit",U=>{clearTimeout(u),l(U??0)})});if(x!==null){let l=re(t,"utf8").trim(),u=ie(e,l);return{launched:!1,message:`playwright host exited early (code ${x}) \u2014 host log ${t}${l?`:
465
+ `;function W(){let e=[process.cwd()+"/"];try{process.argv[1]&&e.push(process.argv[1])}catch{}for(let r of e)try{let t=te(r);for(let o of["playwright","playwright-chromium","playwright-core"])try{return{spec:o,modulePath:t.resolve(o)}}catch{}}catch{}return null}function ie(){let e=W();return e?{available:!0,reason:null,detail:`resolved via ${e.spec}`}:{available:!1,reason:"playwright not installed in the current workspace"}}function ne(e,r){return process.platform!=="linux"||e.headless||process.env.DISPLAY||process.env.WAYLAND_DISPLAY||!/missing x server|cannot open display|x server|x11/i.test(r)?null:" hint: linux without DISPLAY/WAYLAND_DISPLAY \u2014 rerun without --headed (or add --headless) to run playwright headless."}function se(e){return e.profileId?b(A(e.profileId).id):e.ephemeralProfile?Q(R(L(),"sootsim-playwright-profile-")):""}async function ae(e){let r=W();if(!r)return{launched:!1,message:"playwright not installed \u2014 run `bun add -D playwright` first"};if(!e.url)return{launched:!1,message:"playwright driver requires a target url"};let t=R(L(),`sootsim-playwright-host-${Date.now().toString(36)}-${process.pid}.log`),o=`${t}.connected`,i=ee(t,"a");try{let n=k(),p=X(process.execPath,["-e",oe],{detached:!0,stdio:["ignore","ignore",i],env:{...process.env,SOOTSIM_PW_MODULE:r.modulePath,SOOTSIM_PW_URL:e.url,SOOTSIM_PW_BRIDGE_PORT:e.bridgePort?String(e.bridgePort):"",SOOTSIM_PW_HEADLESS:e.headless??!0?"1":"0",SOOTSIM_PW_USERDATADIR:se(e),SOOTSIM_PW_CDP_PORT:e.cdpPort?String(e.cdpPort):"",SOOTSIM_PW_BROWSER:e.browser??"",SOOTSIM_PW_VIEWPORT:e.viewport?`${e.viewport.width}x${e.viewport.height}`:"",SOOTSIM_PW_CONNECTED_ACK_FILE:o,SOOTSIM_PW_CONNECT_TIMEOUT_MS:String(e.connectTimeoutMs??12e4),SOOTSIM_PW_OWNER_PID:n&&n>1?String(n):""}});p.unref();let x=await new Promise(l=>{let u=setTimeout(()=>l(null),4e3);p.once("exit",U=>{clearTimeout(u),l(U??0)})});if(x!==null){let l=re(t,"utf8").trim(),u=ne(e,l);return{launched:!1,message:`playwright host exited early (code ${x}) \u2014 host log ${t}${l?`:
477
466
  ${l}`:""}${u?`
478
- ${u}`:""}`}}return{launched:!0,message:`playwright chrome launched \u2192 ${e.url}`,pid:p.pid,target:r.spec,attachUrl:e.url,connectAckFile:n,diagnosticLogPath:t}}catch(i){return{launched:!1,message:`playwright launch failed: ${i instanceof Error?i.message:String(i)}`}}finally{Z(o)}}var N={id:"playwright",name:"playwright",description:"programmatic chromium via the playwright package \u2014 headless default",kind:"automation",availability:oe,launch:ae};function le(){return process.platform!=="darwin"&&process.platform!=="linux"&&process.platform!=="win32"?{available:!1,reason:`unsupported platform: ${process.platform}`}:{available:!0,reason:null,detail:process.platform==="darwin"?"open(1)":process.platform==="win32"?"cmd /c start":"xdg-open(1)"}}async function ce(e){if(e.headless)return{launched:!1,message:"system driver does not support --headless; use chromium or playwright"};if(!e.url)return{launched:!1,message:"system driver requires a target url"};if(e.profileId||e.ephemeralProfile)return{launched:!1,message:"profiles require electron or playwright; browser tabs use your current browser profile"};try{let r=await _(e.url,{detached:e.detached??!0,newWindow:e.newWindow});return{launched:!0,message:`${r.via} launch \u2192 ${e.url}`,pid:r.pid,target:r.target,attachUrl:e.url}}catch(r){return{launched:!1,message:`system launch failed: ${r instanceof Error?r.message:String(r)}`}}}var G={id:"system",name:"system",description:"shared browser launcher \u2014 system default or chromium window",kind:"delegate",availability:le,launch:ce};var d=[A,M,N,G];function Me(){return d}function Le(e){return d.find(r=>r.id===e)??null}function Re(e,r){if(e)return d.find(n=>n.id===e)??null;for(let t of r){let n=d.find(o=>o.id===t);if(n&&n.availability().available)return n}return null}function We(){return d.map(e=>{let r=e.availability();return{id:e.id,name:e.name,kind:e.kind,description:e.description,available:r.available,reason:r.reason,detail:r.detail??null}})}export{q as a,C as b,H as c,pe as d,z as e,A as f,M as g,N as h,G as i,d as j,Me as k,Le as l,Re as m,We as n};
467
+ ${u}`:""}`}}return{launched:!0,message:`playwright chrome launched \u2192 ${e.url}`,pid:p.pid,target:r.spec,attachUrl:e.url,connectAckFile:o,diagnosticLogPath:t}}catch(n){return{launched:!1,message:`playwright launch failed: ${n instanceof Error?n.message:String(n)}`}}finally{Z(i)}}var N={id:"playwright",name:"playwright",description:"programmatic chromium via the playwright package \u2014 headless default",kind:"automation",availability:ie,launch:ae};function le(){return process.platform!=="darwin"&&process.platform!=="linux"&&process.platform!=="win32"?{available:!1,reason:`unsupported platform: ${process.platform}`}:{available:!0,reason:null,detail:process.platform==="darwin"?"open(1)":process.platform==="win32"?"cmd /c start":"xdg-open(1)"}}async function ce(e){if(e.headless)return{launched:!1,message:"system driver does not support --headless; use chromium or playwright"};if(!e.url)return{launched:!1,message:"system driver requires a target url"};if(e.profileId||e.ephemeralProfile)return{launched:!1,message:"profiles require electron or playwright; browser tabs use your current browser profile"};try{let r=await I(e.url,{detached:e.detached??!0,newWindow:e.newWindow});return{launched:!0,message:`${r.via} launch \u2192 ${e.url}`,pid:r.pid,target:r.target,attachUrl:e.url}}catch(r){return{launched:!1,message:`system launch failed: ${r instanceof Error?r.message:String(r)}`}}}var F={id:"system",name:"system",description:"shared browser launcher \u2014 system default or chromium window",kind:"delegate",availability:le,launch:ce};var d=[C,M,N,F];function Me(){return d}function Le(e){return d.find(r=>r.id===e)??null}function Re(e,r){if(e)return d.find(o=>o.id===e)??null;for(let t of r){let o=d.find(i=>i.id===t);if(o&&o.availability().available)return o}return null}function We(){return d.map(e=>{let r=e.availability();return{id:e.id,name:e.name,kind:e.kind,description:e.description,available:r.available,reason:r.reason,detail:r.detail??null}})}export{q as a,A as b,H as c,pe as d,z as e,C as f,M as g,N as h,F as i,d as j,Me as k,Le as l,Re as m,We as n};
@@ -0,0 +1,3 @@
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{execSync as g}from"node:child_process";function l(e){let r=e;if(r&&typeof r.process=="function")try{let n=r.process();if(n&&typeof n.pid=="number"&&n.pid>0)return n.pid}catch{}if(r&&typeof r.browser=="function")try{let n=r.browser();if(n)return l(n)}catch{}return null}function a(e){let r=[];try{r=g(`pgrep -P ${e} || true`).toString().split(`
3
+ `).filter(Boolean)}catch{}for(let n of r)a(Number(n));try{process.kill(e,"SIGKILL")}catch{}}var i=new Set,c=!1;function w(){if(c)return;c=!0;let e=()=>{for(let r of i)a(r)};process.on("SIGTERM",()=>{e(),process.exit(0)}),process.on("SIGINT",()=>{e(),process.exit(0)}),process.on("exit",e)}async function f(e){let r=await e(),n=l(r),o=new Set;n!=null&&(o.add(n),i.add(n),w());let s=r;return typeof s.on=="function"&&s.on("disconnected",()=>{for(let t of o)i.delete(t)}),{browser:r,reapNow:()=>{for(let t of o)a(t),i.delete(t);o.clear()}}}async function m(e){let{browser:r}=await f(e);return r}var u=!1;function h(){return[`--use-angle=${process.platform==="darwin"?"metal":process.platform==="linux"?"vulkan":"default"}`,"--enable-gpu","--enable-gpu-rasterization","--enable-zero-copy","--ignore-gpu-blocklist"]}function b(e={}){let r=Array.isArray(e.args)?e.args:[],n=Array.isArray(e.ignoreDefaultArgs)?e.ignoreDefaultArgs:[];return{...e,channel:"chromium",args:[...h(),...r],ignoreDefaultArgs:[...n,"--enable-unsafe-swiftshader"]}}function p(e,r){return async()=>{let n=process.env.CI==="true"||process.env.CI==="1"||process.env.GITHUB_ACTIONS==="true";if(!u)try{let o=Array.isArray(r.args)?r.args:[];if(!n&&o.some(s=>s==="--enable-unsafe-swiftshader"||/^--use-angle=(?:swiftshader|swiftshader-webgl)$/i.test(String(s))))throw new Error("[reap-browser] refused local SwiftShader launch arguments");return await e(b(r))}catch(o){let s=o instanceof Error?o.message:String(o);if(!/not found at|not installed|Chromium distribution|Executable doesn't exist|No such file/i.test(s))throw o;if(!n)throw new Error("[reap-browser] Playwright Chrome for Testing is required for local GPU browser work; chromium_headless_shell fallback is disabled. Run `bunx playwright install chromium`.",{cause:o});u=!0,console.warn("[reap-browser] CI Chrome for Testing not found, falling back to chromium_headless_shell software rendering.")}return e(r)}}async function k(e,r={}){return m(p(e,r))}async function P(e,r={}){return f(p(e,r))}export{k as a,P as b};
@@ -1,3 +1,3 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{j as n}from"./chunk-NWLTJUCZ.js";var i=[];for(let[t,e]of Object.entries(n))e.cliFlag&&i.push({name:`--${e.cliFlag}`,short:e.cliFlagShort?`-${e.cliFlagShort}`:void 0,key:t,type:e.type==="enum"?"string":e.type,description:e.description,options:e.options,default:e.default});var a=i;function g(){let t=[];for(let e of a){let s=e.short?`${e.short}, ${e.name}`:` ${e.name}`,o=e.options?` [${e.options.join("|")}]`:"",r=e.default!==void 0?` (default: ${e.default})`:"";t.push(` ${s.padEnd(24)}${e.description}${o}${r}`)}return t.join(`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{j as n}from"./chunk-KW72IOGD.js";var i=[];for(let[t,e]of Object.entries(n))e.cliFlag&&i.push({name:`--${e.cliFlag}`,short:e.cliFlagShort?`-${e.cliFlagShort}`:void 0,key:t,type:e.type==="enum"?"string":e.type,description:e.description,options:e.options,default:e.default});var a=i;function g(){let t=[];for(let e of a){let s=e.short?`${e.short}, ${e.name}`:` ${e.name}`,o=e.options?` [${e.options.join("|")}]`:"",r=e.default!==void 0?` (default: ${e.default})`:"";t.push(` ${s.padEnd(24)}${e.description}${o}${r}`)}return t.join(`
3
3
  `)}export{g as a};
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a}from"./chunk-HS2NYELS.js";import"./chunk-NT7DIPF6.js";export{a as getCliVersion};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-FVZQMYUJ.js";import{existsSync as x,readFileSync as j}from"fs";import{resolve as g}from"path";async function P(s){(s.includes("--help")||s.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-NT7DIPF6.js";import{existsSync as x,readFileSync as j}from"fs";import{resolve as g}from"path";async function P(s){(s.includes("--help")||s.includes("-h"))&&(console.log(`
3
3
  sootsim compat \u2014 check package compatibility
4
4
 
5
5
  usage:
@@ -20,7 +20,7 @@ examples:
20
20
  sootsim compat react-native-reanimated
21
21
  sootsim compat --json
22
22
  sootsim compat --brief
23
- `),process.exit(0));let c=s.includes("--json"),e=s.includes("--brief"),l=s.indexOf("--app"),n=l!==-1&&s[l+1]?g(s[l+1]):process.cwd(),k=s.filter((o,a)=>!o.startsWith("-")&&(l===-1||a!==l+1))[0];if(c||e){let{scanDeps:o}=await import("./web-3O74TBQP.js"),a=g(n,"package.json");x(a)||(console.error(" no package.json found in",n),process.exit(1));let u=JSON.parse(j(a,"utf8")),r=o(u);if(c){console.log(JSON.stringify(r,null,2));return}if(r.packages.length===0){console.log(" no RN ecosystem packages detected");return}let T=Math.round(r.overallScore*100),v=r.packages.filter(i=>i.status==="full").length,$=r.packages.filter(i=>i.status==="partial"||i.status==="auto-stub").length,w=r.packages.filter(i=>i.status==="unsupported").length,p=[];v&&p.push(`${v} fully supported`),$&&p.push(`${$} partial`),w&&p.push(`${w} unsupported`),console.log(` ${p.join(", ")} \u2014 ${T}% compatible`);return}let{POLYFILL_REGISTRY:d}=await import("./web-3O74TBQP.js");if(k){W(k,d);return}let b=g(n,"package.json");x(b)||(console.error(" no package.json found in",n),process.exit(1));let m=JSON.parse(j(b,"utf8")),S={...m.dependencies,...m.devDependencies},t={full:[],partial:[],autoStub:[],unsupported:[],justWorks:[],unknown:[]};for(let o of Object.keys(S)){let a=d[o];if(a){let u=a.stubType==="native"?"full":a.stubType==="works"?"not-relevant":a.stubType;if(a.stubType!=="native"&&a.versions?.length){let r=Math.max(...a.versions.map(y=>y.coverage||0));u=r>=.8?"full":r>=.3?"partial":"auto-stub"}switch(u){case"full":t.full.push(o);break;case"partial":t.partial.push(o);break;case"auto-stub":t.autoStub.push(o);break;case"unsupported":t.unsupported.push(o);break;case"not-relevant":t.justWorks.push(o);break;default:f(o)&&t.unknown.push(o)}}else f(o)&&t.unknown.push(o)}console.log(`
23
+ `),process.exit(0));let c=s.includes("--json"),e=s.includes("--brief"),l=s.indexOf("--app"),n=l!==-1&&s[l+1]?g(s[l+1]):process.cwd(),k=s.filter((o,a)=>!o.startsWith("-")&&(l===-1||a!==l+1))[0];if(c||e){let{scanDeps:o}=await import("./web-U5F5O7TY.js"),a=g(n,"package.json");x(a)||(console.error(" no package.json found in",n),process.exit(1));let u=JSON.parse(j(a,"utf8")),r=o(u);if(c){console.log(JSON.stringify(r,null,2));return}if(r.packages.length===0){console.log(" no RN ecosystem packages detected");return}let T=Math.round(r.overallScore*100),v=r.packages.filter(i=>i.status==="full").length,$=r.packages.filter(i=>i.status==="partial"||i.status==="auto-stub").length,w=r.packages.filter(i=>i.status==="unsupported").length,p=[];v&&p.push(`${v} fully supported`),$&&p.push(`${$} partial`),w&&p.push(`${w} unsupported`),console.log(` ${p.join(", ")} \u2014 ${T}% compatible`);return}let{POLYFILL_REGISTRY:d}=await import("./web-U5F5O7TY.js");if(k){W(k,d);return}let b=g(n,"package.json");x(b)||(console.error(" no package.json found in",n),process.exit(1));let m=JSON.parse(j(b,"utf8")),S={...m.dependencies,...m.devDependencies},t={full:[],partial:[],autoStub:[],unsupported:[],justWorks:[],unknown:[]};for(let o of Object.keys(S)){let a=d[o];if(a){let u=a.stubType==="native"?"full":a.stubType==="works"?"not-relevant":a.stubType;if(a.stubType!=="native"&&a.versions?.length){let r=Math.max(...a.versions.map(y=>y.coverage||0));u=r>=.8?"full":r>=.3?"partial":"auto-stub"}switch(u){case"full":t.full.push(o);break;case"partial":t.partial.push(o);break;case"auto-stub":t.autoStub.push(o);break;case"unsupported":t.unsupported.push(o);break;case"not-relevant":t.justWorks.push(o);break;default:f(o)&&t.unknown.push(o)}}else f(o)&&t.unknown.push(o)}console.log(`
24
24
  sootsim compatibility report
25
25
  \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500
26
26
 
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{A as i,C as s,x as t}from"./chunk-K7FLRWXM.js";import"./chunk-FVZQMYUJ.js";function l(){let e=i();console.log(` telemetry is ${e?"ON":"OFF"}`),console.log(` config: ${t()}`);let o=process.env.DO_NOT_TRACK;(o==="1"||o==="true")&&console.log(` note: DO_NOT_TRACK=${o} is set \u2014 telemetry is off for this run`)}async function r(e){let o=e.find(n=>!n.startsWith("-"))?.toLowerCase();switch(o){case void 0:case"status":l();return;case"on":case"enable":s(!0),console.log(" telemetry ON"),console.log(` config: ${t()}`);return;case"off":case"disable":s(!1),console.log(" telemetry OFF"),console.log(` config: ${t()}`);return;default:console.error(` unknown telemetry action: ${o}`),console.error(" usage: sootsim config telemetry [on|off|status]"),process.exit(1)}}function c(){console.log(`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{A as i,C as s,x as t}from"./chunk-LHI6SSKZ.js";import"./chunk-NT7DIPF6.js";function l(){let e=i();console.log(` telemetry is ${e?"ON":"OFF"}`),console.log(` config: ${t()}`);let o=process.env.DO_NOT_TRACK;(o==="1"||o==="true")&&console.log(` note: DO_NOT_TRACK=${o} is set \u2014 telemetry is off for this run`)}async function r(e){let o=e.find(n=>!n.startsWith("-"))?.toLowerCase();switch(o){case void 0:case"status":l();return;case"on":case"enable":s(!0),console.log(" telemetry ON"),console.log(` config: ${t()}`);return;case"off":case"disable":s(!1),console.log(" telemetry OFF"),console.log(` config: ${t()}`);return;default:console.error(` unknown telemetry action: ${o}`),console.error(" usage: sootsim config telemetry [on|off|status]"),process.exit(1)}}function c(){console.log(`
3
3
  sootsim config \u2014 manage local CLI preferences
4
4
 
5
5
  usage:
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{d as a,e as b,f as c,g as d,h as e,i as f,j as g,k as h,l as i,m as j,n as k,o as l,p as m,q as n,r as o,s as p,t as q,u as r,v as s,w as t,x as u}from"./chunk-OYPMYSMY.js";import"./chunk-SQ2QXZ4N.js";import"./chunk-FKMYICRL.js";import"./chunk-HYSKRSBW.js";import"./chunk-CCW5EYIU.js";import"./chunk-QS4PGGDS.js";import"./chunk-OOJ5OXYG.js";import"./chunk-7KD7SO3A.js";import"./chunk-RQHZYDRX.js";import"./chunk-AHA4PLGQ.js";import"./chunk-GVK4Q3BA.js";import"./chunk-NWN2GQ36.js";import"./chunk-5FPSA6T3.js";import"./chunk-QJ2UUEBC.js";import"./chunk-FR2ZFWG2.js";import"./chunk-ZTCF4L5T.js";import"./chunk-K7FLRWXM.js";import"./chunk-NWLTJUCZ.js";import"./chunk-FVZQMYUJ.js";export{f as buildOpenUrl,e as buildShellUrl,s as closeSimsBulk,b as normalizeDeepLinkTarget,t as planBulkCloseTargets,k as playwrightHostPidForSim,h as printConnectedSims,c as resolveBundleTarget,d as resolveDefaultShellBaseUrl,a as resolveDriverConnectWaitOptions,r as runClaimCommand,u as runCloseCommand,q as runFocusCommand,n as runLinkCommand,o as runOpenCommand,p as runUseCommand,l as signalDriverLaunchConnected,g as summarizeSimUrl,m as terminatePlaywrightHostsForSims,i as waitForSimMatch,j as waitForSimMatchOrHostExit};
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{d as a,e as b,f as c,g as d,h as e,i as f,j as g,k as h,l as i,m as j,n as k,o as l,p as m,q as n,r as o,s as p,t as q,u as r,v as s,w as t,x as u}from"./chunk-BI4VCL6Q.js";import"./chunk-3W4H7IIQ.js";import"./chunk-JHAL2K27.js";import"./chunk-NCJQISNJ.js";import"./chunk-3LZ4N33H.js";import"./chunk-B7IV5YY2.js";import"./chunk-WDDOFF3W.js";import"./chunk-UZWRZ3ND.js";import"./chunk-AWY3D6YY.js";import"./chunk-XXDT7Q4C.js";import"./chunk-FHHD7KFS.js";import"./chunk-UQKFXZT7.js";import"./chunk-TGRJ7ZJD.js";import"./chunk-ZPXGQH3V.js";import"./chunk-347KANFK.js";import"./chunk-P73P4LEJ.js";import"./chunk-LHI6SSKZ.js";import"./chunk-KW72IOGD.js";import"./chunk-NT7DIPF6.js";export{f as buildOpenUrl,e as buildShellUrl,s as closeSimsBulk,b as normalizeDeepLinkTarget,t as planBulkCloseTargets,k as playwrightHostPidForSim,h as printConnectedSims,c as resolveBundleTarget,d as resolveDefaultShellBaseUrl,a as resolveDriverConnectWaitOptions,r as runClaimCommand,u as runCloseCommand,q as runFocusCommand,n as runLinkCommand,o as runOpenCommand,p as runUseCommand,l as signalDriverLaunchConnected,g as summarizeSimUrl,m as terminatePlaywrightHostsForSims,i as waitForSimMatch,j as waitForSimMatchOrHostExit};
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a,b,c,d,e}from"./chunk-DVK6PIUQ.js";import"./chunk-NCJ6UORF.js";import"./chunk-D74MZDQ5.js";import"./chunk-AHQQF4W6.js";import"./chunk-6P4XXLDV.js";import"./chunk-MOFL2C72.js";import"./chunk-ZPXGQH3V.js";import"./chunk-347KANFK.js";import"./chunk-P73P4LEJ.js";import"./chunk-LHI6SSKZ.js";import"./chunk-HS2NYELS.js";import"./chunk-PUXJ6MG3.js";import"./chunk-KW72IOGD.js";import"./chunk-NT7DIPF6.js";export{c as daemonInstall,b as getDaemonServiceStatus,a as runDaemon,d as teardownDaemonService,e as teardownSootsimHome};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{f,m as T}from"./chunk-OOJ5OXYG.js";import{K as S,L as $,M as N,N as A,O as v}from"./chunk-7KD7SO3A.js";import{g as D,i as O,k as x}from"./chunk-RQHZYDRX.js";import"./chunk-FR2ZFWG2.js";import"./chunk-ZTCF4L5T.js";import"./chunk-K7FLRWXM.js";import"./chunk-FVZQMYUJ.js";var H=["portals","sheets","layout","onlayout","animated","render","touch","yoga","all"],R="__sootsimShellAnimationTrace",q="__sootsimDebugAnimation";function L(){console.log(`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{f,m as T}from"./chunk-WDDOFF3W.js";import{K as S,L as $,M as N,N as A,O as v}from"./chunk-UZWRZ3ND.js";import{g as D,i as O,k as x}from"./chunk-AWY3D6YY.js";import"./chunk-347KANFK.js";import"./chunk-P73P4LEJ.js";import"./chunk-LHI6SSKZ.js";import"./chunk-NT7DIPF6.js";var H=["portals","sheets","layout","onlayout","animated","render","touch","yoga","all"],R="__sootsimShellAnimationTrace",q="__sootsimDebugAnimation";function L(){console.log(`
3
3
  sootsim debug \u2014 drive __sootsimDebug from the terminal
4
4
 
5
5
  usage:
@@ -170,7 +170,7 @@ examples:
170
170
  } : null,
171
171
  samples,
172
172
  }
173
- })()`}async function c(i,l){return x(i,l)}async function Y(i,l){let g=D(i,{port:l.port,stripBooleanFlags:["--pretty","--json","--help","-h"]}),u=g.positional;(!u[0]||i.includes("--help")||i.includes("-h"))&&(L(),process.exit(0));let P=g.wsPort,_=g.simId,n=!i.includes("--json"),y=_?` --sim ${_}`:"",k=u[0],r=u.slice(1);if(new Set(["state","js","eval","perf","memory","sample-color"]).has(k)){let{runInspect:e}=await import("./inspect-CCH3ID2P.js");await e(["debug",...i],{port:l.port,verbose:l.verbose});return}let t=O(g);try{switch(k){case"enable":{let e=B(r[0]);e.length===0&&(console.error(` usage: sootsim debug enable <channel[,channel,...]>
173
+ })()`}async function c(i,l){return x(i,l)}async function Y(i,l){let g=D(i,{port:l.port,stripBooleanFlags:["--pretty","--json","--help","-h"]}),u=g.positional;(!u[0]||i.includes("--help")||i.includes("-h"))&&(L(),process.exit(0));let P=g.wsPort,_=g.simId,n=!i.includes("--json"),y=_?` --sim ${_}`:"",k=u[0],r=u.slice(1);if(new Set(["state","js","eval","perf","memory","sample-color"]).has(k)){let{runInspect:e}=await import("./inspect-DETXTJUP.js");await e(["debug",...i],{port:l.port,verbose:l.verbose});return}let t=O(g);try{switch(k){case"enable":{let e=B(r[0]);e.length===0&&(console.error(` usage: sootsim debug enable <channel[,channel,...]>
174
174
  known: ${H.join(", ")}`),process.exit(1));let o=await v(t,"enable",e);console.log(a({active:o},n));break}case"disable":{let e=B(r[0]),o=await v(t,"disable",e);console.log(a({active:o},n));break}case"toggle":{let e=r[0];e||(console.error(" usage: sootsim debug toggle <channel>"),process.exit(1));let o=await c(t,`window.__sootsimDebug.toggle(${JSON.stringify(e)})`);console.log(a({[e]:o},n));break}case"status":{let e=await S(t);console.log(a(e,n));break}case"channels":{let e=await c(t,"window.__sootsimDebug.channels()");console.log(a(e,n));break}case"flags":{let e=await $(t);console.log(a(e,n));break}case"snapshot":{let e=r[0],o=e?`window.__sootsimDebug.snapshot(${JSON.stringify(e)})`:"window.__sootsimDebug.snapshot()",s=await c(t,`(() => { const s = ${o}; if (!s) return null; return { label: s.label, at: s.at, size: s.nodes.size }; })()`);console.log(a(s,n));break}case"snapshots":{let e=await c(t,"window.__sootsimDebug.snapshots()");console.log(a(e,n));break}case"diff":{let e=r[0],o=r[1];(!e||!o)&&(console.error(" usage: sootsim debug diff <labelA> <labelB>"),process.exit(1));let s=`(() => {
175
175
  const d = window.__sootsimDebug.diff(${JSON.stringify(e)}, ${JSON.stringify(o)});
176
176
  if (!d) return null;
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.224 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as g}from"./chunk-NLTKRAPS.js";import{a as v,h as k}from"./chunk-OYPMYSMY.js";import"./chunk-SQ2QXZ4N.js";import"./chunk-FKMYICRL.js";import"./chunk-HYSKRSBW.js";import"./chunk-CCW5EYIU.js";import"./chunk-QS4PGGDS.js";import{a as u}from"./chunk-OPI6PLWA.js";import"./chunk-OOJ5OXYG.js";import"./chunk-7KD7SO3A.js";import"./chunk-RQHZYDRX.js";import"./chunk-EVRV7ZEQ.js";import{b as m,g as f,l as h}from"./chunk-AHA4PLGQ.js";import{a as c}from"./chunk-GVK4Q3BA.js";import"./chunk-NWN2GQ36.js";import"./chunk-5FPSA6T3.js";import"./chunk-QJ2UUEBC.js";import"./chunk-FR2ZFWG2.js";import"./chunk-ZTCF4L5T.js";import"./chunk-K7FLRWXM.js";import"./chunk-NWLTJUCZ.js";import"./chunk-FVZQMYUJ.js";function I(e){let i=e.indexOf("--port");if(i<0)return;let o=e[i+1],t=o?Number(o):Number.NaN;return(!Number.isInteger(t)||t<=0)&&(console.error(` invalid --port value: ${o||"(missing)"}`),process.exit(1)),t}async function O(e,i){let o=I(e)??i.port;return o?k(String(o)):void 0}async function w(e,i){(e.includes("--help")||e.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.225 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as g}from"./chunk-3QKH7HQL.js";import{a as v,h as k}from"./chunk-BI4VCL6Q.js";import"./chunk-3W4H7IIQ.js";import"./chunk-JHAL2K27.js";import"./chunk-NCJQISNJ.js";import"./chunk-3LZ4N33H.js";import"./chunk-B7IV5YY2.js";import{a as u}from"./chunk-TFNMU5WV.js";import"./chunk-WDDOFF3W.js";import"./chunk-UZWRZ3ND.js";import"./chunk-AWY3D6YY.js";import"./chunk-Q6HBPMI4.js";import{b as m,g as f,l as h}from"./chunk-XXDT7Q4C.js";import{a as c}from"./chunk-FHHD7KFS.js";import"./chunk-UQKFXZT7.js";import"./chunk-TGRJ7ZJD.js";import"./chunk-ZPXGQH3V.js";import"./chunk-347KANFK.js";import"./chunk-P73P4LEJ.js";import"./chunk-LHI6SSKZ.js";import"./chunk-KW72IOGD.js";import"./chunk-NT7DIPF6.js";function I(e){let i=e.indexOf("--port");if(i<0)return;let o=e[i+1],t=o?Number(o):Number.NaN;return(!Number.isInteger(t)||t<=0)&&(console.error(` invalid --port value: ${o||"(missing)"}`),process.exit(1)),t}async function O(e,i){let o=I(e)??i.port;return o?k(String(o)):void 0}async function w(e,i){(e.includes("--help")||e.includes("-h"))&&(console.log(`
3
3
  sootsim desktop \u2014 launch the desktop companion
4
4
 
5
5
  usage:
@@ -16,7 +16,7 @@ examples:
16
16
  sootsim desktop --port 5173
17
17
  sootsim desktop --profile qa
18
18
  sootsim desktop --driver system
19
- `),process.exit(0));let o=e.indexOf("--driver"),t=o>=0?e[o+1]:void 0,n=e.find((r,a)=>e[a-1]==="--profile"),d=e.includes("--ephemeral");n&&d&&(console.error(" sootsim desktop: --profile cannot be combined with --ephemeral"),process.exit(1));let x=n?m(n).id:void 0,s=t||i.driver,l=f;if(s){let r=h(s);r||(console.error(` unknown driver "${s}" \u2014 run \`sootsim list --drivers\``),process.exit(1)),l=r}if(l.id==="electron"){let r=c();if(!r){if(v(),process.stdin.isTTY&&process.env.CI!=="1"&&process.env.SOOTSIM_NO_PROMPT!=="1"&&await u("run sootsim desktop install now?",!0)){console.log();let{runInstallDesktop:D}=await import("./install-desktop-SD2XL3QE.js");await D(["--yes"]),r=c()}r||process.exit(1)}console.log(` launching ${r.path}`)}let b=await O(e,i),p=await l.launch({url:b,device:i.device,profileId:x,ephemeralProfile:d});p.launched||(console.error(` ${p.message}`),process.exit(1)),console.log(` ${p.message}`)}function y(){console.log(`
19
+ `),process.exit(0));let o=e.indexOf("--driver"),t=o>=0?e[o+1]:void 0,n=e.find((r,a)=>e[a-1]==="--profile"),d=e.includes("--ephemeral");n&&d&&(console.error(" sootsim desktop: --profile cannot be combined with --ephemeral"),process.exit(1));let x=n?m(n).id:void 0,s=t||i.driver,l=f;if(s){let r=h(s);r||(console.error(` unknown driver "${s}" \u2014 run \`sootsim list --drivers\``),process.exit(1)),l=r}if(l.id==="electron"){let r=c();if(!r){if(v(),process.stdin.isTTY&&process.env.CI!=="1"&&process.env.SOOTSIM_NO_PROMPT!=="1"&&await u("run sootsim desktop install now?",!0)){console.log();let{runInstallDesktop:D}=await import("./install-desktop-CHYTPRFO.js");await D(["--yes"]),r=c()}r||process.exit(1)}console.log(` launching ${r.path}`)}let b=await O(e,i),p=await l.launch({url:b,device:i.device,profileId:x,ephemeralProfile:d});p.launched||(console.error(` ${p.message}`),process.exit(1)),console.log(` ${p.message}`)}function y(){console.log(`
20
20
  sootsim desktop \u2014 launch or install the desktop companion
21
21
 
22
22
  usage: