sootsim 0.1.218 → 0.1.219

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 (149) hide show
  1. package/README.md +5 -3
  2. package/detox/index.ts +6 -7
  3. package/dist-cli/bin.js +4 -4
  4. package/dist-cli/chunks/{agent-TQJDQNML.js → agent-ZV6ME4EG.js} +2 -2
  5. package/dist-cli/chunks/{agent-wrapper-OAOFXHX2.js → agent-wrapper-EGFEAPFH.js} +2 -2
  6. package/dist-cli/chunks/{app-fonts-4VPAP3RZ.js → app-fonts-ZWVEYPCN.js} +2 -2
  7. package/dist-cli/chunks/{assert-DKNRGH4M.js → assert-SC3W6UNR.js} +2 -2
  8. package/dist-cli/chunks/{auth-ZYOAQEI2.js → auth-7OTPNXUI.js} +2 -2
  9. package/dist-cli/chunks/beta-QPKHTN3A.js +2 -0
  10. package/dist-cli/chunks/{camera-BJCRYG27.js → camera-RQGNYESB.js} +2 -2
  11. package/dist-cli/chunks/{chunk-AHTGZMT4.js → chunk-2CCJGEVS.js} +2 -2
  12. package/dist-cli/chunks/{chunk-OTCJCVFR.js → chunk-2DOBRWPU.js} +3 -3
  13. package/dist-cli/chunks/{chunk-T2NAWDMZ.js → chunk-2U4CK5R5.js} +2 -2
  14. package/dist-cli/chunks/{chunk-AY5S4CWZ.js → chunk-3B5UXJ3Y.js} +1 -1
  15. package/dist-cli/chunks/{chunk-V64N734Y.js → chunk-3GQ2VZT3.js} +2 -2
  16. package/dist-cli/chunks/{chunk-TNEHHCMZ.js → chunk-3PMTZACY.js} +2 -2
  17. package/dist-cli/chunks/{chunk-KLBOD2JL.js → chunk-3QEIIJ4U.js} +2 -2
  18. package/dist-cli/chunks/{chunk-NN7XOWXY.js → chunk-4KBHOKFR.js} +3 -3
  19. package/dist-cli/chunks/{chunk-LIR2VPPJ.js → chunk-7EMJ67H5.js} +9 -9
  20. package/dist-cli/chunks/{chunk-SXS5SPIZ.js → chunk-7RSH52LR.js} +1 -1
  21. package/dist-cli/chunks/{chunk-73WAFGRP.js → chunk-7VZLWO2D.js} +2 -2
  22. package/dist-cli/chunks/{chunk-4DLUGQXQ.js → chunk-AWM244TZ.js} +3 -3
  23. package/dist-cli/chunks/{chunk-YMFQOXT4.js → chunk-BTLNZG23.js} +1 -1
  24. package/dist-cli/chunks/{chunk-CJHPCUUV.js → chunk-C5LRFEF4.js} +1 -1
  25. package/dist-cli/chunks/{chunk-JDCABF7Y.js → chunk-EMWJQRT7.js} +2 -2
  26. package/dist-cli/chunks/{chunk-XB6FCXX3.js → chunk-FGIGSM4Z.js} +2 -2
  27. package/dist-cli/chunks/{chunk-TGXLBFTC.js → chunk-FJPEIFZW.js} +1 -1
  28. package/dist-cli/chunks/{chunk-QWJG2WVA.js → chunk-G26OO66G.js} +1 -1
  29. package/dist-cli/chunks/{chunk-F5H6XTMN.js → chunk-GXIL7GMS.js} +1 -1
  30. package/dist-cli/chunks/{chunk-Q7U5TPQN.js → chunk-I6SPORCZ.js} +1 -1
  31. package/dist-cli/chunks/{chunk-CRPOEKYT.js → chunk-ITYDRFAM.js} +3 -3
  32. package/dist-cli/chunks/chunk-J3WU2XCQ.js +1 -0
  33. package/dist-cli/chunks/{chunk-6WWKUDWP.js → chunk-JEMQ2DRI.js} +2 -2
  34. package/dist-cli/chunks/{chunk-ZJI2JP7F.js → chunk-JT5JOWHK.js} +1 -1
  35. package/dist-cli/chunks/{chunk-FEMAFOUH.js → chunk-JVJNG6BQ.js} +2 -2
  36. package/dist-cli/chunks/{chunk-Z4QP44SI.js → chunk-JYU7BIGJ.js} +2 -2
  37. package/dist-cli/chunks/{chunk-DVZVP32W.js → chunk-KLTHI6RE.js} +2 -2
  38. package/dist-cli/chunks/{chunk-L5HYRG4P.js → chunk-LNNBPSAL.js} +2 -2
  39. package/dist-cli/chunks/{chunk-AK4CONMS.js → chunk-LUWFFYQL.js} +2 -2
  40. package/dist-cli/chunks/chunk-NVDHSK33.js +119 -0
  41. package/dist-cli/chunks/{chunk-FAUOGIHF.js → chunk-PMERG7PS.js} +1 -1
  42. package/dist-cli/chunks/{chunk-EEUNNW2P.js → chunk-PYIMY6VO.js} +1 -1
  43. package/dist-cli/chunks/{chunk-IKZ4Z6ND.js → chunk-QH5KCAPX.js} +1 -1
  44. package/dist-cli/chunks/{chunk-VOZZ62OJ.js → chunk-RCHJJ5GW.js} +1 -1
  45. package/dist-cli/chunks/{chunk-RZMI7IKL.js → chunk-UEA4JYEY.js} +2 -2
  46. package/dist-cli/chunks/{chunk-MW3G72KG.js → chunk-V4VPUZVL.js} +91 -14
  47. package/dist-cli/chunks/{chunk-24FHNNST.js → chunk-WTWTKL3R.js} +6 -6
  48. package/dist-cli/chunks/chunk-Y6Y7QQLA.js +1 -0
  49. package/dist-cli/chunks/{chunk-7NP5BWIH.js → chunk-Y7GPDSA2.js} +1 -1
  50. package/dist-cli/chunks/{chunk-CMGPYPUE.js → chunk-ZGTMYSKV.js} +2 -2
  51. package/dist-cli/chunks/{chunk-Q7K5GJR4.js → chunk-ZHMKPUDR.js} +2 -2
  52. package/dist-cli/chunks/{chunk-2HJU3NAO.js → chunk-ZNDD2KOF.js} +1 -1
  53. package/dist-cli/chunks/{chunk-B4KB5TBV.js → chunk-ZXFWW4MR.js} +1 -1
  54. package/dist-cli/chunks/cli-version-ZUBCW7QA.js +2 -0
  55. package/dist-cli/chunks/{compat-IETPHSZ3.js → compat-WICAPL25.js} +3 -3
  56. package/dist-cli/chunks/{config-BOOBJ25W.js → config-MGQCNMDQ.js} +2 -2
  57. package/dist-cli/chunks/{control-U52Q4YES.js → control-GW7OQZ2R.js} +2 -2
  58. package/dist-cli/chunks/daemon-2A2YTRXY.js +2 -0
  59. package/dist-cli/chunks/{debug-X4AW6CXJ.js → debug-54HQV7MN.js} +3 -3
  60. package/dist-cli/chunks/{desktop-HHREMDE2.js → desktop-5FWYDFK2.js} +3 -3
  61. package/dist-cli/chunks/{detox-AXETJDTZ.js → detox-75KJXI7K.js} +2 -2
  62. package/dist-cli/chunks/{device-B7PBIMER.js → device-VRR2CFKN.js} +2 -2
  63. package/dist-cli/chunks/{diagnose-7YEDF42J.js → diagnose-DS623ULB.js} +2 -2
  64. package/dist-cli/chunks/drivers-6QFTJGK6.js +2 -0
  65. package/dist-cli/chunks/{film-XQMAOELQ.js → film-6I22LQ4E.js} +3 -3
  66. package/dist-cli/chunks/flow-4RXVOUUF.js +2 -0
  67. package/dist-cli/chunks/help-IXPZBF5H.js +2 -0
  68. package/dist-cli/chunks/{home-paths-I3NOFS6P.js → home-paths-D7QIYKT2.js} +2 -2
  69. package/dist-cli/chunks/inspect-SU5K5IER.js +2 -0
  70. package/dist-cli/chunks/install-desktop-PN4SCIMA.js +2 -0
  71. package/dist-cli/chunks/{login-O4ZPWWEU.js → login-ETKHVL7Z.js} +4 -4
  72. package/dist-cli/chunks/{logout-REEPRXWZ.js → logout-FLW7LPE3.js} +2 -2
  73. package/dist-cli/chunks/{maestro-OCUCS5DY.js → maestro-D3MAAOMX.js} +3 -3
  74. package/dist-cli/chunks/{maestro-generate-VHUHJFHR.js → maestro-generate-73HS4LME.js} +3 -3
  75. package/dist-cli/chunks/{mode-T24V4RZ4.js → mode-SOXJRJIN.js} +2 -2
  76. package/dist-cli/chunks/optional-demo-registry-N2J3NEGC.js +2 -0
  77. package/dist-cli/chunks/{perf-ZUER6TVQ.js → perf-YAKR4GMN.js} +2 -2
  78. package/dist-cli/chunks/{record-XDKPMUBK.js → record-HWKSSN3E.js} +3 -3
  79. package/dist-cli/chunks/runtime-ZUWXQ46T.js +2 -0
  80. package/dist-cli/chunks/{screenshot-command-MMUGPJ4I.js → screenshot-command-UNDC4C2R.js} +3 -3
  81. package/dist-cli/chunks/screenshots-capture-QZSUIT4R.js +41 -0
  82. package/dist-cli/chunks/{serve-BCATAS4S.js → serve-D66T2PP3.js} +2 -2
  83. package/dist-cli/chunks/{setup-LXPQLQ6I.js → setup-FML4JBOA.js} +9 -9
  84. package/dist-cli/chunks/{skills-OOPLWNI2.js → skills-O2KIPSJ6.js} +2 -2
  85. package/dist-cli/chunks/{storage-E7MGHPIG.js → storage-T7MGNCI7.js} +2 -2
  86. package/dist-cli/chunks/store-WTRJT3P5.js +2 -0
  87. package/dist-cli/chunks/telemetry-7HV5GWEK.js +2 -0
  88. package/dist-cli/chunks/{timeline-4AN6A5CV.js → timeline-OQEJCRNZ.js} +2 -2
  89. package/dist-cli/chunks/upgrade-TL36WOFS.js +4 -0
  90. package/dist-cli/chunks/upload-7CIEKZM6.js +2 -0
  91. package/dist-cli/chunks/{version-LI2X5HLA.js → version-XG3TA6TB.js} +2 -2
  92. package/dist-cli/chunks/web-LVUK3CHP.js +2 -0
  93. package/dist-cli/chunks/{what-happened-2NTKQ4AT.js → what-happened-SASUKQEF.js} +2 -2
  94. package/dist-lib/agent-daemon-client.cjs +1 -1
  95. package/dist-lib/agent-events.cjs +1 -1
  96. package/dist-lib/agent-identity.cjs +1 -1
  97. package/dist-lib/agent-sessions.cjs +1 -1
  98. package/dist-lib/attached-projects.cjs +1 -1
  99. package/dist-lib/auth/shared-session.cjs +1 -1
  100. package/dist-lib/backend-origin.cjs +1 -1
  101. package/dist-lib/beta.cjs +1 -1
  102. package/dist-lib/beta.mjs +1 -1
  103. package/dist-lib/bridge-constants.cjs +1 -1
  104. package/dist-lib/cli-constants.cjs +1 -1
  105. package/dist-lib/config.cjs +1 -1
  106. package/dist-lib/detox/index.cjs +53 -7
  107. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  108. package/dist-lib/home-paths.cjs +1 -1
  109. package/dist-lib/host/bridge-host.cjs +1 -1
  110. package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
  111. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  112. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  113. package/dist-lib/host/websocket-proxy.cjs +1 -1
  114. package/dist-lib/index.cjs +1 -1
  115. package/dist-lib/jump-to-source-babel.cjs +1 -1
  116. package/dist-lib/menu.cjs +1 -1
  117. package/dist-lib/menu.mjs +1 -1
  118. package/dist-lib/metro.cjs +1 -1
  119. package/dist-lib/profiles.cjs +1 -1
  120. package/dist-lib/render-mode.cjs +1 -1
  121. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  122. package/dist-lib/sdk.cjs +1 -1
  123. package/dist-lib/sdk.mjs +1 -1
  124. package/dist-lib/skills.cjs +164 -20
  125. package/dist-lib/vite.cjs +1 -1
  126. package/package.json +1 -1
  127. package/src/skills/builtin/a11y-review.ts +4 -1
  128. package/src/skills/builtin/perf-profile.ts +4 -1
  129. package/src/skills/builtin/screenshot-all.ts +4 -1
  130. package/src/skills/builtin/visual-diff.ts +4 -1
  131. package/dist-cli/chunks/beta-HL46FNX3.js +0 -2
  132. package/dist-cli/chunks/chunk-BZRIJJIK.js +0 -1
  133. package/dist-cli/chunks/chunk-FP3DRAKI.js +0 -119
  134. package/dist-cli/chunks/chunk-OUZAVYUG.js +0 -1
  135. package/dist-cli/chunks/cli-version-5FG6LIHX.js +0 -2
  136. package/dist-cli/chunks/daemon-EJDBU2UY.js +0 -2
  137. package/dist-cli/chunks/drivers-325S27FC.js +0 -2
  138. package/dist-cli/chunks/flow-V2SWGBAR.js +0 -2
  139. package/dist-cli/chunks/help-F4VH4LXF.js +0 -2
  140. package/dist-cli/chunks/inspect-NY5VGZNC.js +0 -2
  141. package/dist-cli/chunks/install-desktop-X7SXH7IN.js +0 -2
  142. package/dist-cli/chunks/optional-demo-registry-HPLGNZCO.js +0 -2
  143. package/dist-cli/chunks/runtime-4A24ALGX.js +0 -2
  144. package/dist-cli/chunks/screenshots-capture-OM6BE572.js +0 -41
  145. package/dist-cli/chunks/store-3DU64I7C.js +0 -2
  146. package/dist-cli/chunks/telemetry-AKRLP3AR.js +0 -2
  147. package/dist-cli/chunks/upgrade-FRBWFDPI.js +0 -4
  148. package/dist-cli/chunks/upload-XGUWNMYV.js +0 -2
  149. package/dist-cli/chunks/web-UDCVLGPU.js +0 -2
@@ -1,6 +1,6 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as m,b as I}from"./chunk-2HJU3NAO.js";import{a as w,b as _,c as T}from"./chunk-ZJI2JP7F.js";import{c as k}from"./chunk-CJHPCUUV.js";import{G as O,o as D,q as f}from"./chunk-YMFQOXT4.js";import h from"fs";import v from"path";var c="default",U="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(),U)}function G(e){return`sootsim-profile-${s(e)}`}function B(e){return v.join(D(),"Partitions",G(e))}function y(e){return v.join(f(),"playwright",s(e))}function b(){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 A(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:A(e.profiles)};let r=new Date().toISOString();return{version:a,profiles:A([{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 H(){return S(b()).profiles}function j(e){let r=s(e);return H().find(t=>t.id===r)??null}function E(e=c){let r=s(e),t=j(r);return t||q(r)}function q(e){let r=s(e),t=P(b());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(b()),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),y(r)])try{h.rmSync(t,{recursive:!0,force:!0})}catch{}}function Y(){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 K(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 T(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 M={id:"chromium",name:"chromium",description:"system chrome / chromium / edge \u2014 visible window (headless: use playwright)",kind:"browser",availability:Y,launch:K};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 C={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 W}from"path";var oe=`
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as m,b as I}from"./chunk-ZNDD2KOF.js";import{a as w,b as _,c as E}from"./chunk-JT5JOWHK.js";import{c as O}from"./chunk-C5LRFEF4.js";import{G as k,o as D,q as f}from"./chunk-BTLNZG23.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=`
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
@@ -31,6 +31,15 @@ const extraChromeArgs = (process.env.SOOTSIM_PW_CHROME_ARGS || '')
31
31
  // iOS Safari proxy \u2014 headless webkit keeps the real Apple GPU while headless
32
32
  // chromium falls back to SwiftShader software rendering for canvas/WebGL.
33
33
  const browserEngine = process.env.SOOTSIM_PW_BROWSER || 'chromium';
34
+ // Local CanvasKit/WebGL work must never fall back to Playwright's software
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
37
+ // proven after launch.
38
+ const hardwareGpuRequired =
39
+ browserEngine === 'chromium' &&
40
+ process.env.CI !== '1' &&
41
+ process.env.CI !== 'true';
42
+ const softwareRendererPattern = /swiftshader|software(?: rasterizer)?|llvmpipe|lavapipe|softpipe/i;
34
43
  // page viewport as '<w>x<h>'. the caller sizes it from the device profile;
35
44
  // the fallback is phone-shaped because the page hosts a phone sim \u2014 the
36
45
  // playwright default (1280x720 desktop) letterboxes the device frame.
@@ -82,6 +91,28 @@ const chromePidsByProfile = () => {
82
91
  .filter((p) => p && p !== process.pid);
83
92
  } catch { return []; }
84
93
  };
94
+ const chromeCommandsByProfile = () => {
95
+ if (!reapEnabled) return [];
96
+ const pids = chromePidsByProfile();
97
+ if (pids.length === 0) return [];
98
+ try {
99
+ return execSync('ps -p ' + pids.join(',') + ' -o command=', {
100
+ stdio: ['ignore', 'pipe', 'ignore'],
101
+ }).toString().split('\\n').filter(Boolean);
102
+ } catch { return []; }
103
+ };
104
+ const assertNoUnsafeSwiftShaderFlag = () => {
105
+ if (!hardwareGpuRequired) return;
106
+ const unsafe = chromeCommandsByProfile().find((command) =>
107
+ command.includes('--enable-unsafe-swiftshader') ||
108
+ /--use-angle=(?:swiftshader|swiftshader-webgl)(?:\\s|$)/i.test(command)
109
+ );
110
+ if (unsafe) {
111
+ throw new Error(
112
+ '[playwright-driver] refused software-rendering Chrome: launched process contains a SwiftShader flag'
113
+ );
114
+ }
115
+ };
85
116
  const killTree = (pid) => {
86
117
  let kids = [];
87
118
  try {
@@ -228,13 +259,11 @@ const cleanupProfile = () => {
228
259
  if (typeof ownerWatch.unref === 'function') ownerWatch.unref();
229
260
  };
230
261
  startOwnerWatch();
231
- // prefer real Google Chrome (looks like the user's browser, no leftover
232
- // "Chrome for Testing" processes). on platforms where Chrome can't be
233
- // installed (notably linux arm64, where \`npx playwright install chrome\`
234
- // errors with "not supported on Linux Arm64"), fall back to Playwright's
235
- // bundled chromium so the driver still works rather than crashing the
236
- // sim out entirely. set SOOTSIM_PW_CHANNEL=chrome|chromium|msedge|... to
237
- // pin the channel. NOTE: this is NOT enough to make \`sootsim perf cpu\`
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\`
238
267
  // work \u2014 that profiles the tenant *worker*, and the JS Self-Profiler API
239
268
  // cannot be constructed in a dedicated worker (see
240
269
  // worker-handlers/cpu-profile.ts). cpu-profile needs a CDP-based profiler
@@ -248,9 +277,26 @@ const cleanupProfile = () => {
248
277
  process.stderr.write('[playwright-driver] launched ' + browserEngine + '\\n');
249
278
  } else {
250
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
+ if (
287
+ hardwareGpuRequired &&
288
+ extraChromeArgs.some((arg) =>
289
+ arg === '--enable-unsafe-swiftshader' ||
290
+ /^--use-angle=(?:swiftshader|swiftshader-webgl)$/i.test(arg)
291
+ )
292
+ ) {
293
+ throw new Error('[playwright-driver] refused SwiftShader launch arguments');
294
+ }
251
295
  const channelsToTry = pinnedChannel
252
296
  ? [pinnedChannel]
253
- : ['chrome', null]; // null = bundled chromium
297
+ : hardwareGpuRequired
298
+ ? ['chrome']
299
+ : ['chrome', null]; // null = bundled chromium, CI only
254
300
  const launchWith = async (channel) => {
255
301
  const opts = channel
256
302
  ? { headless, channel, viewport, deviceScaleFactor }
@@ -318,7 +364,10 @@ const cleanupProfile = () => {
318
364
  /Chromium distribution/i.test(msg);
319
365
  if (!isMissingChannel) throw err; // unexpected failure: bubble up
320
366
  if (channel) {
321
- process.stderr.write('[playwright-driver] channel "' + channel + '" not available, falling back to bundled chromium\\n');
367
+ const next = hardwareGpuRequired
368
+ ? '; bundled Chromium is disabled for local GPU work\\n'
369
+ : ', falling back to bundled chromium\\n';
370
+ process.stderr.write('[playwright-driver] channel "' + channel + '" not available' + next);
322
371
  }
323
372
  }
324
373
  }
@@ -366,6 +415,34 @@ const cleanupProfile = () => {
366
415
  }, Number.isFinite(connectTimeoutMs) && connectTimeoutMs > 0 ? connectTimeoutMs : 120000);
367
416
  if (typeof connectTimer.unref === 'function') connectTimer.unref();
368
417
  const page = await context.newPage();
418
+ if (hardwareGpuRequired) {
419
+ assertNoUnsafeSwiftShaderFlag();
420
+ const gpu = await page.evaluate(() => {
421
+ const canvas = document.createElement('canvas');
422
+ const gl =
423
+ canvas.getContext('webgl2', { powerPreference: 'high-performance' }) ||
424
+ canvas.getContext('webgl', { powerPreference: 'high-performance' });
425
+ if (!gl) return { renderer: null, vendor: null };
426
+ const info = gl.getExtension('WEBGL_debug_renderer_info');
427
+ return {
428
+ renderer: info ? String(gl.getParameter(info.UNMASKED_RENDERER_WEBGL)) : null,
429
+ vendor: info ? String(gl.getParameter(info.UNMASKED_VENDOR_WEBGL)) : null,
430
+ };
431
+ });
432
+ if (!gpu.renderer) {
433
+ throw new Error(
434
+ '[playwright-driver] could not prove a hardware WebGL renderer; refusing local render-heavy launch'
435
+ );
436
+ }
437
+ if (softwareRendererPattern.test(gpu.renderer)) {
438
+ throw new Error('[playwright-driver] refused software WebGL renderer: ' + gpu.renderer);
439
+ }
440
+ assertNoUnsafeSwiftShaderFlag();
441
+ process.stderr.write(
442
+ '[playwright-driver] hardware WebGL renderer: ' + gpu.renderer +
443
+ (gpu.vendor ? ' (' + gpu.vendor + ')' : '') + '\\n'
444
+ );
445
+ }
369
446
  // surface page-side failures (engine boot crash, failed WS registration)
370
447
  // to stderr so a sim that never connects produces a real diagnostic
371
448
  // instead of a silent "timed out waiting for opened sim to connect".
@@ -396,6 +473,6 @@ const cleanupProfile = () => {
396
473
  process.stderr.write(String((err && err.stack) || err) + '\\n');
397
474
  process.exit(1);
398
475
  });
399
- `;function R(){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=R();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?y(E(e.profileId).id):e.ephemeralProfile?Q(W(L(),"sootsim-playwright-profile-")):""}async function ae(e){let r=R();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=W(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",F=>{clearTimeout(u),l(F??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?`:
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?`:
400
477
  ${l}`:""}${u?`
401
- ${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 _(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 $={id:"system",name:"system",description:"shared browser launcher \u2014 system default or chromium window",kind:"delegate",availability:le,launch:ce};var d=[M,C,N,$];function Ce(){return d}function Le(e){return d.find(r=>r.id===e)??null}function We(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 Re(){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{H as a,E as b,q as c,pe as d,z as e,M as f,C as g,N as h,$ as i,d as j,Ce as k,Le as l,We as m,Re as n};
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};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as R,b as U}from"./chunk-Q7K5GJR4.js";import{c as F}from"./chunk-RZMI7IKL.js";import{g as N,j as E,r as _,s as v,t as B}from"./chunk-YMFQOXT4.js";import{a as O}from"./chunk-SXS5SPIZ.js";import{execFileSync as W,spawnSync as s}from"child_process";import{existsSync as a,mkdirSync as x,readFileSync as nt,realpathSync as ot,rmSync as $,writeFileSync as H}from"fs";import{homedir as P}from"os";import{basename as st,dirname as T,resolve as f,sep as Y}from"path";import{execFileSync as X}from"child_process";import{chmodSync as Q,mkdirSync as I,rmSync as z,writeFileSync as A}from"fs";import{dirname as L}from"path";var J="dev.sootsim.daemon",j="SootSim Daemon",M="0.1.36";function V(t,e,r){let n=v(),o=B(),c=L(L(o)),l=L(o),u=`${c}/Resources`;z(n,{recursive:!0,force:!0}),I(_(),{recursive:!0}),I(l,{recursive:!0}),I(u,{recursive:!0}),A(`${c}/Info.plist`,Z()),A(`${c}/PkgInfo`,"APPL????"),A(o,tt(t,e,r)),Q(o,493);try{X("codesign",["--force","--sign","-","--deep",n],{stdio:"pipe"})}catch(i){let p=i instanceof Error?i.message:String(i);console.warn(` warning: ad-hoc codesign of ${n} failed: ${p}
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as R,b as U}from"./chunk-ZHMKPUDR.js";import{c as F}from"./chunk-UEA4JYEY.js";import{g as N,j as E,r as _,s as v,t as B}from"./chunk-BTLNZG23.js";import{a as O}from"./chunk-7RSH52LR.js";import{execFileSync as W,spawnSync as s}from"child_process";import{existsSync as a,mkdirSync as x,readFileSync as nt,realpathSync as ot,rmSync as $,writeFileSync as H}from"fs";import{homedir as P}from"os";import{basename as st,dirname as T,resolve as f,sep as Y}from"path";import{execFileSync as X}from"child_process";import{chmodSync as Q,mkdirSync as I,rmSync as z,writeFileSync as A}from"fs";import{dirname as L}from"path";var J="dev.sootsim.daemon",j="SootSim Daemon",M="0.1.36";function V(t,e,r){let n=v(),o=B(),c=L(L(o)),l=L(o),u=`${c}/Resources`;z(n,{recursive:!0,force:!0}),I(_(),{recursive:!0}),I(l,{recursive:!0}),I(u,{recursive:!0}),A(`${c}/Info.plist`,Z()),A(`${c}/PkgInfo`,"APPL????"),A(o,tt(t,e,r)),Q(o,493);try{X("codesign",["--force","--sign","-","--deep",n],{stdio:"pipe"})}catch(i){let p=i instanceof Error?i.message:String(i);console.warn(` warning: ad-hoc codesign of ${n} failed: ${p}
3
3
  the daemon will still run, but Login Items may show a generic name.`)}return{bundlePath:n,launcherPath:o}}function Z(){return`<?xml version="1.0" encoding="UTF-8"?>
4
4
  <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
5
5
  <plist version="1.0">
@@ -28,7 +28,7 @@ import{a as R,b as U}from"./chunk-Q7K5GJR4.js";import{c as F}from"./chunk-RZMI7I
28
28
  # stdout: ${r.stdout}
29
29
  # stderr: ${r.stderr}
30
30
  exec ${o}
31
- `}function et(t){return`'${t.replace(/'/g,"'\\''")}'`}var K=60,y="dev.sootsim.daemon",m="sootsim-daemon",g=f(P(),"Library/Logs/sootsim"),b=f(P(),".local/state/sootsim");async function Ft(t,e={}){let[r,...n]=t,o=e.port??7668;if(!r||r==="--help"||r==="-h"){q();return}new Set(["uninstall","restart","start","stop","logs"]).has(r)&&R({event:`daemon_${r}`,properties:{platform:process.platform,subsource:"daemon"}});try{switch(r){case"uninstall":return await ht();case"status":return await $t();case"restart":return await St();case"start":return await wt();case"stop":return await kt();case"logs":return await vt(n);default:console.error(` unknown daemon subcommand: ${r}`),q(),process.exit(1)}}finally{await U()}}function q(){F("daemon")}function it(){let t=at();if(t)return t;let e=ut();return{executable:process.execPath,prefixArgs:[e]}}function at(){if(!ct())return null;let t=lt();if(!t)return null;let e=O(),r=e==="0.0.0"?"sootsim":`sootsim@${e}`;return{executable:process.execPath,prefixArgs:[t,"exec","--yes","--package",r,"--","sootsim"]}}function ct(){let t=process.argv[1];return process.env.npm_command==="exec"?!0:t?D(t).includes(`${Y}_npx${Y}`):!1}function lt(){try{let e=W("which",["npm"],{encoding:"utf8"}).trim();if(e&&a(e))return G(e)}catch{}let t=process.env.npm_execpath;return t&&a(t)?G(t):null}function G(t){let e=D(t);if(st(e)==="npx-cli.js"){let r=f(T(e),"npm-cli.js");if(a(r))return r}return e}function ut(){try{let e=W("which",["sootsim"],{encoding:"utf8"}).trim();if(e&&a(e))return D(e)}catch{}let t=process.argv[1];if(t&&a(t))return D(t);throw new Error("could not locate the sootsim binary")}function D(t){try{return ot(t)}catch{return t}}function pt(t,e){x(g,{recursive:!0});let r=f(g,"bridge.out.log"),n=f(g,"bridge.err.log"),{launcherPath:o}=V(t,e,{stdout:r,stderr:n}),c=` <string>${mt(o)}</string>`;return`<?xml version="1.0" encoding="UTF-8"?>
31
+ `}function et(t){return`'${t.replace(/'/g,"'\\''")}'`}var K=60,y="dev.sootsim.daemon",m="sootsim-daemon",g=f(P(),"Library/Logs/sootsim"),b=f(P(),".local/state/sootsim");async function jt(t,e={}){let[r,...n]=t,o=e.port??7668;if(!r||r==="--help"||r==="-h"){q();return}new Set(["install","uninstall","restart","start","stop","logs"]).has(r)&&R({event:`daemon_${r}`,properties:{platform:process.platform,subsource:"daemon"}});try{switch(r){case"install":return await ft({port:o,force:n.includes("--force")});case"uninstall":return await $t();case"status":return await St();case"restart":return await wt();case"start":return await kt();case"stop":return await vt();case"logs":return await bt(n);default:console.error(` unknown daemon subcommand: ${r}`),q(),process.exit(1)}}finally{await U()}}function q(){F("daemon")}function it(){let t=at();if(t)return t;let e=ut();return{executable:process.execPath,prefixArgs:[e]}}function at(){if(!ct())return null;let t=lt();if(!t)return null;let e=O(),r=e==="0.0.0"?"sootsim":`sootsim@${e}`;return{executable:process.execPath,prefixArgs:[t,"exec","--yes","--package",r,"--","sootsim"]}}function ct(){let t=process.argv[1];return process.env.npm_command==="exec"?!0:t?D(t).includes(`${Y}_npx${Y}`):!1}function lt(){try{let e=W("which",["npm"],{encoding:"utf8"}).trim();if(e&&a(e))return G(e)}catch{}let t=process.env.npm_execpath;return t&&a(t)?G(t):null}function G(t){let e=D(t);if(st(e)==="npx-cli.js"){let r=f(T(e),"npm-cli.js");if(a(r))return r}return e}function ut(){try{let e=W("which",["sootsim"],{encoding:"utf8"}).trim();if(e&&a(e))return D(e)}catch{}let t=process.argv[1];if(t&&a(t))return D(t);throw new Error("could not locate the sootsim binary")}function D(t){try{return ot(t)}catch{return t}}function pt(t,e){x(g,{recursive:!0});let r=f(g,"bridge.out.log"),n=f(g,"bridge.err.log"),{launcherPath:o}=V(t,e,{stdout:r,stderr:n}),c=` <string>${mt(o)}</string>`;return`<?xml version="1.0" encoding="UTF-8"?>
32
32
  <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
33
33
  <plist version="1.0">
34
34
  <dict>
@@ -57,6 +57,6 @@ RestartSec=${K}
57
57
 
58
58
  [Install]
59
59
  WantedBy=default.target
60
- `}function mt(t){return t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")}function gt(t){return/[^\w@%+=:,./-]/.test(t)?`'${t.replace(/'/g,"'\\''")}'`:t}function S(){return f(P(),"Library/LaunchAgents",`${y}.plist`)}function w(){return f(P(),".config/systemd/user",`${m}.service`)}function jt(){if(E())return{supported:!1,installed:!1};if(process.platform==="darwin"){let t=S();return{supported:!0,installed:a(t),path:t}}if(process.platform==="linux"){let t=w();return{supported:!0,installed:a(t),path:t}}return{supported:!1,installed:!1}}async function Mt({port:t,force:e}){if(E())throw new Error("background daemon setup is unavailable in this environment");let r=it();if(console.log(` binary: ${[r.executable,...r.prefixArgs].join(" ")}`),console.log(` port: ${t}`),process.platform==="darwin"){let n=S();if(a(n)&&!e){console.log(` already installed at ${n}`),console.log(" pass --force to overwrite, or use 'sootsim daemon restart' to reload");return}x(T(n),{recursive:!0}),H(n,pt(r,t)),console.log(` wrote ${n}`);let o=`gui/${process.getuid()}`,c=`${o}/${y}`,l=()=>{let d=s("launchctl",["bootstrap",o,n],{stdio:"pipe",encoding:"utf8"}),k=(d.stderr||d.stdout||"").trim();if(d.status!==0)return{ok:!1,reason:`bootstrap exit ${d.status}${k?`: ${k}`:""}`};let C=s("launchctl",["print",c],{encoding:"utf8"});return C.status!==0?{ok:!1,reason:`bootstrap returned 0 but service not registered (print exit ${C.status})`}:{ok:!0}},u=l();if(!u.ok){let d=u.reason;if(s("launchctl",["bootout",c],{stdio:"ignore"}),u=l(),!u.ok)throw new Error(`launchctl bootstrap failed: ${u.reason}`+(d!==u.reason?` (initial: ${d})`:"")+" \u2014 try `sootsim daemon uninstall` then retry, or reboot if launchd state is stuck.")}let i=Date.now()+4e3,p,h;for(;Date.now()<i;){let d=s("launchctl",["print",c],{encoding:"utf8"});if(d.status===0&&(p=d.stdout?.match(/state\s*=\s*(\w+)/)?.[1],h=d.stdout?.match(/pid\s*=\s*(\d+)/)?.[1],p==="running"||h))break;await new Promise(k=>setTimeout(k,150))}if(p!=="running"&&!h)throw new Error(`daemon registered but did not reach running state within 4s (last state: ${p||"unknown"}). check ${f(g,"bridge.err.log")} \u2014 typically a stale runtime or a port already bound by another process.`);console.log(` registered (state: ${p||"unknown"}${h?`, pid ${h}`:""}, log: ${f(g,"bridge.err.log")})`);return}if(process.platform==="linux"){let n=w();if(a(n)&&!e){console.log(` already installed at ${n}`),console.log(" pass --force to overwrite, or use 'sootsim daemon restart' to reload");return}x(T(n),{recursive:!0}),H(n,dt(r,t)),console.log(` wrote ${n}`);let o=s("systemctl",["--user","daemon-reload"],{stdio:"pipe",encoding:"utf8"});if(o.status!==0){let i=(o.stderr||o.stdout||"").trim();throw new Error(`systemctl daemon-reload failed${i?`: ${i}`:""}`)}let c=s("systemctl",["--user","enable","--now",m],{stdio:"pipe",encoding:"utf8"});if(c.status!==0){let i=(c.stderr||c.stdout||"").trim();throw new Error(`systemctl enable --now failed${i?`: ${i}`:""} \u2014 try \`sootsim daemon uninstall\` then retry.`)}let u=(s("systemctl",["--user","is-active",m],{encoding:"utf8"}).stdout||"").trim()||"unknown";console.log(` registered (state: ${u}, journalctl --user -u ${m} to tail logs)`);try{let i=process.env.USER||process.env.LOGNAME||"";if(i){let p=s("loginctl",["show-user",i,"--property=Linger","--value"],{encoding:"utf8"});!((p.stdout||"").trim().toLowerCase()==="yes")&&p.status===0&&console.log(` note: linger is not enabled for "${i}". the daemon will exit at logout.
61
- enable persistence with: sudo loginctl enable-linger ${i}`)}}catch{}return}console.error(` background daemon is not supported on ${process.platform}`),console.error(" run 'sootsim serve' in a persistent shell instead"),process.exit(1)}function ft(){let t=[];if(process.platform==="darwin"){let e=S();a(e)&&(s("launchctl",["bootout",`gui/${process.getuid()}/${y}`],{stdio:"ignore"}),$(e,{force:!0}),t.push(e));let r=v();return a(r)&&($(r,{recursive:!0,force:!0}),t.push(r)),a(g)&&($(g,{recursive:!0,force:!0}),t.push(g)),{removed:t,missing:t.length===0}}if(process.platform==="linux"){let e=w();return a(e)&&(s("systemctl",["--user","disable","--now",m],{stdio:"ignore"}),$(e,{force:!0}),s("systemctl",["--user","daemon-reload"],{stdio:"ignore"}),s("systemctl",["--user","reset-failed",m],{stdio:"ignore"}),t.push(e)),a(b)&&($(b,{recursive:!0,force:!0}),t.push(b)),{removed:t,missing:t.length===0}}return{removed:t,missing:!0}}function yt(){let t=[],e=N();return a(e)&&($(e,{recursive:!0,force:!0}),t.push(e)),{removed:t,missing:t.length===0}}async function ht(){let t=ft();for(let r of t.removed)console.log(` removed ${r}`);let e=yt();for(let r of e.removed)console.log(` removed ${r}`);t.missing&&e.missing&&console.log(" not installed")}async function $t(){if(process.platform==="darwin"){let t=S();if(!a(t)){console.log(" installed: no");return}console.log(` installed: yes (${t})`);let e=bt(t);e&&console.log(` binary: ${e}`);let r=s("launchctl",["print",`gui/${process.getuid()}/${y}`],{encoding:"utf8"});if(r.status===0){let n=r.stdout.match(/state\s*=\s*(\w+)/)?.[1],o=r.stdout.match(/pid\s*=\s*(\d+)/)?.[1];console.log(` state: ${n||"unknown"}${o?` (pid ${o})`:""}`)}else console.log(" state: not running");return}if(process.platform==="linux"){let t=w();if(!a(t)){console.log(" installed: no");return}console.log(` installed: yes (${t})`);let e=s("systemctl",["--user","is-active",m],{encoding:"utf8"});console.log(` state: ${e.stdout.trim()||"unknown"}`);return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function St(){if(process.platform==="darwin"){let t=S();a(t)||(console.error(" daemon not registered \u2014 run `sootsim setup`"),process.exit(1));let e=s("launchctl",["kickstart","-k",`gui/${process.getuid()}/${y}`],{stdio:"pipe",encoding:"utf8"});e.status!==0&&(console.error(` kickstart failed: ${e.stderr?.trim()}`),process.exit(1)),console.log(" restarted");return}if(process.platform==="linux"){let t=w();a(t)||(console.error(" daemon not registered \u2014 run `sootsim setup`"),process.exit(1));let e=s("systemctl",["--user","restart",m],{stdio:"pipe",encoding:"utf8"});e.status!==0&&(console.error(` restart failed: ${e.stderr?.trim()}`),process.exit(1)),console.log(" restarted");return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function wt(){if(process.platform==="darwin"){s("launchctl",["kickstart",`gui/${process.getuid()}/${y}`],{stdio:"inherit"});return}if(process.platform==="linux"){s("systemctl",["--user","start",m],{stdio:"inherit"});return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function kt(){if(process.platform==="darwin"){s("launchctl",["bootout",`gui/${process.getuid()}/${y}`],{stdio:"inherit"});return}if(process.platform==="linux"){s("systemctl",["--user","stop",m],{stdio:"inherit"});return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function vt(t){let e=t.find(o=>/^-n\d+$|^--lines=\d+$|^\d+$/.test(o)),r=e?Number(e.replace(/\D/g,"")):200,n=t.includes("-f")||t.includes("--follow");if(process.platform==="darwin"){let o=f(g,"bridge.out.log"),c=f(g,"bridge.err.log"),l=[o,c].filter(i=>a(i));l.length===0&&(console.error(` no daemon logs yet at ${g} \u2014 run \`sootsim setup\` to install the daemon`),process.exit(1));let u=n?["-n",String(r),"-F",...l]:["-n",String(r),...l];s("tail",u,{stdio:"inherit"});return}if(process.platform==="linux"){let o=`${m}.service`,c=["--user","-u",o,"-n",String(r),"--no-pager"],l=s("journalctl",n?[...c,"-f"]:c,{encoding:"utf8",stdio:n?"inherit":"pipe"});if(n)return;let u=`${l.stdout||""}${l.stderr||""}`,i=/insufficient permissions|No journal files were opened/i.test(u);if(l.status===0&&!i){process.stdout.write(l.stdout||"");return}let p=s("journalctl",[`_SYSTEMD_USER_UNIT=${o}`,"-n",String(r),"--no-pager"],{encoding:"utf8"});if(p.status===0&&(p.stdout||"").trim()){process.stdout.write(p.stdout);return}console.error(` could not read --user journal for ${o} (this user isn't in the systemd-journal group yet).
62
- run: sudo journalctl _SYSTEMD_USER_UNIT=${o} -n ${r} --no-pager`),process.exit(1)}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}function bt(t){try{return nt(t,"utf8").match(/<array>\s*<string>([^<]+)<\/string>/)?.[1]||null}catch{return null}}export{Ft as a,jt as b,Mt as c,ft as d,yt as e};
60
+ `}function mt(t){return t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")}function gt(t){return/[^\w@%+=:,./-]/.test(t)?`'${t.replace(/'/g,"'\\''")}'`:t}function S(){return f(P(),"Library/LaunchAgents",`${y}.plist`)}function w(){return f(P(),".config/systemd/user",`${m}.service`)}function Mt(){if(E())return{supported:!1,installed:!1};if(process.platform==="darwin"){let t=S();return{supported:!0,installed:a(t),path:t}}if(process.platform==="linux"){let t=w();return{supported:!0,installed:a(t),path:t}}return{supported:!1,installed:!1}}async function ft({port:t,force:e}){if(E())throw new Error("background daemon setup is unavailable in this environment");let r=it();if(console.log(` binary: ${[r.executable,...r.prefixArgs].join(" ")}`),console.log(` port: ${t}`),process.platform==="darwin"){let n=S();if(a(n)&&!e){console.log(` already installed at ${n}`),console.log(" pass --force to overwrite, or use 'sootsim daemon restart' to reload");return}x(T(n),{recursive:!0}),H(n,pt(r,t)),console.log(` wrote ${n}`);let o=`gui/${process.getuid()}`,c=`${o}/${y}`,l=()=>{let d=s("launchctl",["bootstrap",o,n],{stdio:"pipe",encoding:"utf8"}),k=(d.stderr||d.stdout||"").trim();if(d.status!==0)return{ok:!1,reason:`bootstrap exit ${d.status}${k?`: ${k}`:""}`};let C=s("launchctl",["print",c],{encoding:"utf8"});return C.status!==0?{ok:!1,reason:`bootstrap returned 0 but service not registered (print exit ${C.status})`}:{ok:!0}},u=l();if(!u.ok){let d=u.reason;if(s("launchctl",["bootout",c],{stdio:"ignore"}),u=l(),!u.ok)throw new Error(`launchctl bootstrap failed: ${u.reason}`+(d!==u.reason?` (initial: ${d})`:"")+" \u2014 try `sootsim daemon uninstall` then retry, or reboot if launchd state is stuck.")}let i=Date.now()+4e3,p,h;for(;Date.now()<i;){let d=s("launchctl",["print",c],{encoding:"utf8"});if(d.status===0&&(p=d.stdout?.match(/state\s*=\s*(\w+)/)?.[1],h=d.stdout?.match(/pid\s*=\s*(\d+)/)?.[1],p==="running"||h))break;await new Promise(k=>setTimeout(k,150))}if(p!=="running"&&!h)throw new Error(`daemon registered but did not reach running state within 4s (last state: ${p||"unknown"}). check ${f(g,"bridge.err.log")} \u2014 typically a stale runtime or a port already bound by another process.`);console.log(` registered (state: ${p||"unknown"}${h?`, pid ${h}`:""}, log: ${f(g,"bridge.err.log")})`);return}if(process.platform==="linux"){let n=w();if(a(n)&&!e){console.log(` already installed at ${n}`),console.log(" pass --force to overwrite, or use 'sootsim daemon restart' to reload");return}x(T(n),{recursive:!0}),H(n,dt(r,t)),console.log(` wrote ${n}`);let o=s("systemctl",["--user","daemon-reload"],{stdio:"pipe",encoding:"utf8"});if(o.status!==0){let i=(o.stderr||o.stdout||"").trim();throw new Error(`systemctl daemon-reload failed${i?`: ${i}`:""}`)}let c=s("systemctl",["--user","enable","--now",m],{stdio:"pipe",encoding:"utf8"});if(c.status!==0){let i=(c.stderr||c.stdout||"").trim();throw new Error(`systemctl enable --now failed${i?`: ${i}`:""} \u2014 try \`sootsim daemon uninstall\` then retry.`)}let u=(s("systemctl",["--user","is-active",m],{encoding:"utf8"}).stdout||"").trim()||"unknown";console.log(` registered (state: ${u}, journalctl --user -u ${m} to tail logs)`);try{let i=process.env.USER||process.env.LOGNAME||"";if(i){let p=s("loginctl",["show-user",i,"--property=Linger","--value"],{encoding:"utf8"});!((p.stdout||"").trim().toLowerCase()==="yes")&&p.status===0&&console.log(` note: linger is not enabled for "${i}". the daemon will exit at logout.
61
+ enable persistence with: sudo loginctl enable-linger ${i}`)}}catch{}return}console.error(` background daemon is not supported on ${process.platform}`),console.error(" run 'sootsim serve' in a persistent shell instead"),process.exit(1)}function yt(){let t=[];if(process.platform==="darwin"){let e=S();a(e)&&(s("launchctl",["bootout",`gui/${process.getuid()}/${y}`],{stdio:"ignore"}),$(e,{force:!0}),t.push(e));let r=v();return a(r)&&($(r,{recursive:!0,force:!0}),t.push(r)),a(g)&&($(g,{recursive:!0,force:!0}),t.push(g)),{removed:t,missing:t.length===0}}if(process.platform==="linux"){let e=w();return a(e)&&(s("systemctl",["--user","disable","--now",m],{stdio:"ignore"}),$(e,{force:!0}),s("systemctl",["--user","daemon-reload"],{stdio:"ignore"}),s("systemctl",["--user","reset-failed",m],{stdio:"ignore"}),t.push(e)),a(b)&&($(b,{recursive:!0,force:!0}),t.push(b)),{removed:t,missing:t.length===0}}return{removed:t,missing:!0}}function ht(){let t=[],e=N();return a(e)&&($(e,{recursive:!0,force:!0}),t.push(e)),{removed:t,missing:t.length===0}}async function $t(){let t=yt();for(let r of t.removed)console.log(` removed ${r}`);let e=ht();for(let r of e.removed)console.log(` removed ${r}`);t.missing&&e.missing&&console.log(" not installed")}async function St(){if(process.platform==="darwin"){let t=S();if(!a(t)){console.log(" installed: no");return}console.log(` installed: yes (${t})`);let e=xt(t);e&&console.log(` binary: ${e}`);let r=s("launchctl",["print",`gui/${process.getuid()}/${y}`],{encoding:"utf8"});if(r.status===0){let n=r.stdout.match(/state\s*=\s*(\w+)/)?.[1],o=r.stdout.match(/pid\s*=\s*(\d+)/)?.[1];console.log(` state: ${n||"unknown"}${o?` (pid ${o})`:""}`)}else console.log(" state: not running");return}if(process.platform==="linux"){let t=w();if(!a(t)){console.log(" installed: no");return}console.log(` installed: yes (${t})`);let e=s("systemctl",["--user","is-active",m],{encoding:"utf8"});console.log(` state: ${e.stdout.trim()||"unknown"}`);return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function wt(){if(process.platform==="darwin"){let t=S();a(t)||(console.error(" daemon not registered \u2014 run `sootsim setup`"),process.exit(1));let e=s("launchctl",["kickstart","-k",`gui/${process.getuid()}/${y}`],{stdio:"pipe",encoding:"utf8"});e.status!==0&&(console.error(` kickstart failed: ${e.stderr?.trim()}`),process.exit(1)),console.log(" restarted");return}if(process.platform==="linux"){let t=w();a(t)||(console.error(" daemon not registered \u2014 run `sootsim setup`"),process.exit(1));let e=s("systemctl",["--user","restart",m],{stdio:"pipe",encoding:"utf8"});e.status!==0&&(console.error(` restart failed: ${e.stderr?.trim()}`),process.exit(1)),console.log(" restarted");return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function kt(){if(process.platform==="darwin"){s("launchctl",["kickstart",`gui/${process.getuid()}/${y}`],{stdio:"inherit"});return}if(process.platform==="linux"){s("systemctl",["--user","start",m],{stdio:"inherit"});return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function vt(){if(process.platform==="darwin"){s("launchctl",["bootout",`gui/${process.getuid()}/${y}`],{stdio:"inherit"});return}if(process.platform==="linux"){s("systemctl",["--user","stop",m],{stdio:"inherit"});return}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}async function bt(t){let e=t.find(o=>/^-n\d+$|^--lines=\d+$|^\d+$/.test(o)),r=e?Number(e.replace(/\D/g,"")):200,n=t.includes("-f")||t.includes("--follow");if(process.platform==="darwin"){let o=f(g,"bridge.out.log"),c=f(g,"bridge.err.log"),l=[o,c].filter(i=>a(i));l.length===0&&(console.error(` no daemon logs yet at ${g} \u2014 run \`sootsim setup\` to install the daemon`),process.exit(1));let u=n?["-n",String(r),"-F",...l]:["-n",String(r),...l];s("tail",u,{stdio:"inherit"});return}if(process.platform==="linux"){let o=`${m}.service`,c=["--user","-u",o,"-n",String(r),"--no-pager"],l=s("journalctl",n?[...c,"-f"]:c,{encoding:"utf8",stdio:n?"inherit":"pipe"});if(n)return;let u=`${l.stdout||""}${l.stderr||""}`,i=/insufficient permissions|No journal files were opened/i.test(u);if(l.status===0&&!i){process.stdout.write(l.stdout||"");return}let p=s("journalctl",[`_SYSTEMD_USER_UNIT=${o}`,"-n",String(r),"--no-pager"],{encoding:"utf8"});if(p.status===0&&(p.stdout||"").trim()){process.stdout.write(p.stdout);return}console.error(` could not read --user journal for ${o} (this user isn't in the systemd-journal group yet).
62
+ run: sudo journalctl _SYSTEMD_USER_UNIT=${o} -n ${r} --no-pager`),process.exit(1)}console.error(` unsupported platform: ${process.platform}`),process.exit(1)}function xt(t){try{return nt(t,"utf8").match(/<array>\s*<string>([^<]+)<\/string>/)?.[1]||null}catch{return null}}export{jt as a,Mt as b,ft as c,yt as d,ht as e};
@@ -0,0 +1 @@
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.219 | (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,5 +1,5 @@
1
- /*! sootsim v0.1.218 | (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-7NP5BWIH.js";import{h,l as N,m as P}from"./chunk-AHTGZMT4.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.219 | (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-Y7GPDSA2.js";import{h,l as N,m as P}from"./chunk-2CCJGEVS.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,2 +1,2 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as l}from"./chunk-TNEHHCMZ.js";import{A as o,B as s}from"./chunk-YMFQOXT4.js";function c(){let e=process.env.DO_NOT_TRACK;return e==="1"||e==="true"||!o()}function p(){if(c())return null;let e=process.env.VITE_POSTHOG_API_KEY||"";if(!e)return null;let t=process.env.SOOT_POSTHOG_HOST||process.env.VITE_POSTHOG_HOST||"https://us.i.posthog.com";return{apiKey:e,host:t.replace(/\/+$/,"")}}function u(){try{return s()}catch{return"anonymous-cli"}}function d(e){return e?e.userId?e.userId:e.installationId!=null?`install:${e.installationId}`:e.repoId?`repo:${e.repoId}`:e.shareId?`share:${e.shareId}`:u():u()}function f(e){let t=e.identity??{},n={$lib:"soot-cli",source:t.source??"cli",...e.properties};return t.userId&&(n.userId=t.userId),t.repoId&&(n.repoId=t.repoId),t.installationId!=null&&(n.installationId=String(t.installationId)),t.shareId&&(n.shareId=t.shareId),t.plan&&(n.plan=t.plan),{event:e.event,distinct_id:d(t),properties:n,timestamp:new Date().toISOString()}}var r=[],a=!1;async function i(){if(r.length===0)return;let e=p();if(!e){r.length=0;return}let t=r.splice(0,r.length).map(f);try{await fetch(`${e.host}/batch/`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({api_key:e.apiKey,batch:t}),signal:AbortSignal.timeout(2e3)})}catch{}}function I(){a||(a=!0,process.on("beforeExit",()=>void i()),process.on("exit",()=>void i()))}function y(e){if(c())return;I();let t=null;try{t=l()?.user?.id??null}catch{t=null}r.push({...e,identity:{source:"cli",userId:t,...e.identity}})}async function m(){await i()}export{y as a,m as b};
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as l}from"./chunk-3PMTZACY.js";import{A as o,B as s}from"./chunk-BTLNZG23.js";function c(){let e=process.env.DO_NOT_TRACK;return e==="1"||e==="true"||!o()}function p(){if(c())return null;let e=process.env.VITE_POSTHOG_API_KEY||"";if(!e)return null;let t=process.env.SOOT_POSTHOG_HOST||process.env.VITE_POSTHOG_HOST||"https://us.i.posthog.com";return{apiKey:e,host:t.replace(/\/+$/,"")}}function u(){try{return s()}catch{return"anonymous-cli"}}function d(e){return e?e.userId?e.userId:e.installationId!=null?`install:${e.installationId}`:e.repoId?`repo:${e.repoId}`:e.shareId?`share:${e.shareId}`:u():u()}function f(e){let t=e.identity??{},n={$lib:"soot-cli",source:t.source??"cli",...e.properties};return t.userId&&(n.userId=t.userId),t.repoId&&(n.repoId=t.repoId),t.installationId!=null&&(n.installationId=String(t.installationId)),t.shareId&&(n.shareId=t.shareId),t.plan&&(n.plan=t.plan),{event:e.event,distinct_id:d(t),properties:n,timestamp:new Date().toISOString()}}var r=[],a=!1;async function i(){if(r.length===0)return;let e=p();if(!e){r.length=0;return}let t=r.splice(0,r.length).map(f);try{await fetch(`${e.host}/batch/`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({api_key:e.apiKey,batch:t}),signal:AbortSignal.timeout(2e3)})}catch{}}function I(){a||(a=!0,process.on("beforeExit",()=>void i()),process.on("exit",()=>void i()))}function y(e){if(c())return;I();let t=null;try{t=l()?.user?.id??null}catch{t=null}r.push({...e,identity:{source:"cli",userId:t,...e.identity}})}async function m(){await i()}export{y as a,m as b};
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import{execFileSync as h,spawn as g}from"child_process";import{existsSync as s,readdirSync as k}from"fs";import{dirname as m,join as l,resolve as a}from"path";import{fileURLToPath as v}from"url";var c;function p(){if(c!==void 0)return c;try{c=m(v(import.meta.resolve("sootsim-engine/package.json")))}catch{c=null}return c}var I="dev.sootsim.simulator";function x(){let n=p();if(!n)return null;let e=l(n,"dist-electron/main.cjs");if(!s(e))return null;let i=D(n);return i?{path:i,platform:process.platform,kind:"dev-electron",engineDir:n}:null}function b(){let n=p();return n?s(l(n,"src-electron/main.ts")):!1}function D(n){let e=n;for(let i=0;i<6;i++){let t=l(e,"node_modules/.bin/electron");if(s(t))return t;let r=m(e);if(r===e)break;e=r}return null}function C(){let n=p(),i=["/Applications/sootsim.app",a(process.env.HOME||"","Applications/sootsim.app"),...n?[a(n,"app/sootsim.app")]:[]].find(t=>s(t));if(i)return{path:i,platform:"darwin",kind:"mac-app"};try{let t=h("mdfind",[`kMDItemCFBundleIdentifier == "${I}"`],{encoding:"utf8",timeout:3e3}).trim();if(t)return{path:t.split(`
3
3
  `)[0],platform:"darwin",kind:"mac-app"}}catch{}return null}function f(n){if(!s(n))return null;let e=k(n).filter(i=>i.startsWith("sootsim")&&i.endsWith(".AppImage")).sort().reverse()[0];return e?l(n,e):null}function w(){let n=p(),i=[a(process.env.HOME||"","Applications/sootsim.AppImage"),a(process.env.HOME||"",".local/bin/sootsim.AppImage"),"/opt/sootsim/sootsim.AppImage","/opt/sootsim/sootsim",...n?[a(n,"app/sootsim.AppImage"),a(n,"release/linux-unpacked/sootsim")]:[]].find(r=>s(r));if(i)return{path:i,platform:"linux",kind:i.endsWith(".AppImage")?"linux-appimage":"linux-binary"};let t=n?f(a(n,"app"))||f(a(n,"release")):null;return t?{path:t,platform:"linux",kind:"linux-appimage"}:null}function A(){let n=x();if(n)return n;if(b()){let e=p(),i=l(e,"dist-electron/main.cjs");return s(i)?console.error(` no node_modules/.bin/electron found near ${e}. run \`bun install\`.`):console.error(` dist-electron/main.cjs missing in ${e}.
4
4
  run: bun run --cwd packages/sootsim-engine build:electron-main
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import{createHash as b}from"node:crypto";import g from"node:fs";import{createRequire as S}from"node:module";import u from"node:path";var y=/\.(ttf|otf|woff|woff2)$/i;function P(t,n,r){if(!t||typeof t!="object")return;let o=t.fonts;if(Array.isArray(o))for(let i of o)typeof i=="string"&&r.push(i);let e=t[n];if(!e||typeof e!="object")return;let s=e.fonts;if(Array.isArray(s))for(let i of s){if(typeof i=="string"){r.push(i);continue}if(!i||typeof i!="object")continue;let c=i.fontDefinitions;if(Array.isArray(c))for(let a of c){if(!a||typeof a!="object")continue;let p=a.path;typeof p=="string"&&r.push(p)}}}function m(t,n){if(!Array.isArray(t))return[];let r=[];for(let o of t){let e=Array.isArray(o)?o[0]:o;if(typeof e!="string"||!/(^|\/)expo-font$/.test(e))continue;let s=Array.isArray(o)?o[1]??{}:{};P(s,n,r)}return r}function C(t){return t.slice(t.lastIndexOf("/")+1).replace(y,"")}function h(t,n){let r=n.replace(/\/+$/,""),o=new Set,e=[];for(let s of t){let i=s.replace(/^\.\//,"").replace(/^\/+/,"");!i||o.has(i)||(o.add(i),y.test(i)&&e.push({family:C(i),url:`${r}/assets/${i}`}))}return e}var d=S(import.meta.url);function x(t){try{let n=new URL(t),r=n.hostname.replace(/^\[|\]$/g,"").toLowerCase();if(r==="localhost"||r.endsWith(".localhost")||r==="0.0.0.0"||r==="::1"||/^127(?:\.\d{1,3}){3}$/.test(r))return n.origin}catch{}return null}var R=["app.config.js","app.config.ts","app.config.cjs","app.config.mjs","app.json"];function w(t){for(let n of R)try{if(g.statSync(u.join(t,n)).isFile())return!0}catch{}return!1}var j=new Set(["node_modules","artifacts","dist","build","out","coverage","tmp","public","ios","android","macos","windows","__fixtures__","__tests__","examples","example"]);function F(t,n){w(t)&&n.push(t);let r;try{r=g.readdirSync(t,{withFileTypes:!0})}catch{return}for(let o of r)o.isDirectory()&&(o.name.startsWith(".")||j.has(o.name)||F(u.join(t,o.name),n))}function _(t){try{return g.statSync(u.join(t,"package.json")).isFile()}catch{return!1}}function I(t){let n=x(t.bundleUrl);if(!n)return[];let r=t.repoDir||process.env.SOOT_REPO_DIR,o=r?u.resolve(r):process.cwd();if(!r&&!_(o))return[];let e=[];if(r)F(o,e),e.includes(o)||e.push(o);else{if(!w(o))return[];e.push(o)}if(e.length===0)return[];let s=(t.platform||process.env.SOOT_PLATFORM||"ios").toLowerCase(),i=null;try{let l=d.resolve("@expo/config",{paths:[...e,o]}),f=d(l);typeof f.getConfig=="function"&&(i=f.getConfig)}catch{}if(!i)return[];let c;for(let l of e)try{let f=i(l,{skipSDKVersionRequirement:!0});if(f?.exp&&typeof f.exp=="object"){let A=f.exp.plugins;if(Array.isArray(A)){c=f.exp;break}}}catch{}if(!c||typeof c!="object")return[];let a=c.plugins;if(!Array.isArray(a))return[];let p=m(a,s==="android"?"android":"ios");return h(p,n)}async function L(t,n){let r=x(t);if(!r)return null;let o=new AbortController,e=setTimeout(()=>o.abort(),n?.timeoutMs??1500);try{let s=await fetch(`${r}/`,{headers:{"expo-platform":"ios",Accept:"application/json"},signal:o.signal});if(!s.ok)return null;let c=(await s.json())?.extra?.expoClient?._internal?.projectRoot;return typeof c=="string"&&c.length>0?c:null}catch{return null}finally{clearTimeout(e)}}function M(t){return t.map(n=>`${encodeURIComponent(n.url)}::${encodeURIComponent(n.family)}`).join(",")}function k(t){let n=[];for(let r of t.split(",")){let o=r.trim();if(!o)continue;let e=o.indexOf("::"),s=e===-1?o:o.slice(0,e);try{n.push(decodeURIComponent(s))}catch{n.push(s)}}return n.filter(Boolean)}function D(t){let n=(t.split("?")[0].split(".").pop()||"").toLowerCase();return n==="ttf"?"font/ttf":n==="otf"?"font/otf":n==="woff"?"font/woff":n==="woff2"?"font/woff2":"application/octet-stream"}async function G(t,n){let r=[],o=new Set;for(let e of k(t)){let s=b("sha256").update(e).digest("hex");if(!o.has(s)){o.add(s);try{let i=await fetch(e);if(!i.ok){n?.onError?.(e,new Error(`${i.status} ${i.statusText}`));continue}let c=new Uint8Array(await i.arrayBuffer());r.push({url:e,urlhash:s,contentType:D(e),bytes:c}),n?.onStaged?.({url:e,byteLength:c.byteLength})}catch(i){n?.onError?.(e,i)}}}return r}export{I as a,L as b,M as c,G as d};
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a}from"./chunk-7RSH52LR.js";import"./chunk-PYIMY6VO.js";export{a as getCliVersion};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-EEUNNW2P.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.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-PYIMY6VO.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-UDCVLGPU.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-UDCVLGPU.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-LVUK3CHP.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-LVUK3CHP.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.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{A as i,C as s,x as t}from"./chunk-YMFQOXT4.js";import"./chunk-EEUNNW2P.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.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{A as i,C as s,x as t}from"./chunk-BTLNZG23.js";import"./chunk-PYIMY6VO.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.218 | (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-L5HYRG4P.js";import"./chunk-FEMAFOUH.js";import"./chunk-OUZAVYUG.js";import"./chunk-AY5S4CWZ.js";import"./chunk-B4KB5TBV.js";import"./chunk-FAUOGIHF.js";import"./chunk-CMGPYPUE.js";import"./chunk-7NP5BWIH.js";import"./chunk-AHTGZMT4.js";import"./chunk-MW3G72KG.js";import"./chunk-2HJU3NAO.js";import"./chunk-ZJI2JP7F.js";import"./chunk-6WWKUDWP.js";import"./chunk-XB6FCXX3.js";import"./chunk-Q7U5TPQN.js";import"./chunk-CJHPCUUV.js";import"./chunk-YMFQOXT4.js";import"./chunk-IKZ4Z6ND.js";import"./chunk-EEUNNW2P.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.219 | (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-LNNBPSAL.js";import"./chunk-JVJNG6BQ.js";import"./chunk-J3WU2XCQ.js";import"./chunk-3B5UXJ3Y.js";import"./chunk-ZXFWW4MR.js";import"./chunk-PMERG7PS.js";import"./chunk-ZGTMYSKV.js";import"./chunk-Y7GPDSA2.js";import"./chunk-2CCJGEVS.js";import"./chunk-V4VPUZVL.js";import"./chunk-ZNDD2KOF.js";import"./chunk-JT5JOWHK.js";import"./chunk-JEMQ2DRI.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.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.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a,b,c,d,e}from"./chunk-WTWTKL3R.js";import"./chunk-ZHMKPUDR.js";import"./chunk-3PMTZACY.js";import"./chunk-UEA4JYEY.js";import"./chunk-7VZLWO2D.js";import"./chunk-NVDHSK33.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-7RSH52LR.js";import"./chunk-FJPEIFZW.js";import"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.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.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{f,m as T}from"./chunk-CMGPYPUE.js";import{K as S,L as $,M as N,N as A,O as v}from"./chunk-7NP5BWIH.js";import{g as D,i as O,k as x}from"./chunk-AHTGZMT4.js";import"./chunk-Q7U5TPQN.js";import"./chunk-CJHPCUUV.js";import"./chunk-YMFQOXT4.js";import"./chunk-EEUNNW2P.js";var H=["portals","sheets","layout","onlayout","animated","render","touch","yoga","all"],R="__sootsimShellAnimationTrace",q="__sootsimDebugAnimation";function L(){console.log(`
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{f,m as T}from"./chunk-ZGTMYSKV.js";import{K as S,L as $,M as N,N as A,O as v}from"./chunk-Y7GPDSA2.js";import{g as D,i as O,k as x}from"./chunk-2CCJGEVS.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-PYIMY6VO.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-NY5VGZNC.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-SU5K5IER.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.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as g}from"./chunk-CRPOEKYT.js";import{a as v,h as k}from"./chunk-L5HYRG4P.js";import"./chunk-FEMAFOUH.js";import"./chunk-OUZAVYUG.js";import"./chunk-AY5S4CWZ.js";import"./chunk-B4KB5TBV.js";import"./chunk-FAUOGIHF.js";import{a as u}from"./chunk-F5H6XTMN.js";import"./chunk-CMGPYPUE.js";import"./chunk-7NP5BWIH.js";import"./chunk-AHTGZMT4.js";import"./chunk-BZRIJJIK.js";import{b as m,g as f,l as h}from"./chunk-MW3G72KG.js";import{a as c}from"./chunk-2HJU3NAO.js";import"./chunk-ZJI2JP7F.js";import"./chunk-6WWKUDWP.js";import"./chunk-XB6FCXX3.js";import"./chunk-Q7U5TPQN.js";import"./chunk-CJHPCUUV.js";import"./chunk-YMFQOXT4.js";import"./chunk-IKZ4Z6ND.js";import"./chunk-EEUNNW2P.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.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as g}from"./chunk-ITYDRFAM.js";import{a as v,h as k}from"./chunk-LNNBPSAL.js";import"./chunk-JVJNG6BQ.js";import"./chunk-J3WU2XCQ.js";import"./chunk-3B5UXJ3Y.js";import"./chunk-ZXFWW4MR.js";import"./chunk-PMERG7PS.js";import{a as u}from"./chunk-GXIL7GMS.js";import"./chunk-ZGTMYSKV.js";import"./chunk-Y7GPDSA2.js";import"./chunk-2CCJGEVS.js";import"./chunk-Y6Y7QQLA.js";import{b as m,g as f,l as h}from"./chunk-V4VPUZVL.js";import{a as c}from"./chunk-ZNDD2KOF.js";import"./chunk-JT5JOWHK.js";import"./chunk-JEMQ2DRI.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.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-X7SXH7IN.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-PN4SCIMA.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:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{e as P}from"./chunk-4DLUGQXQ.js";import"./chunk-NN7XOWXY.js";import{b as _,c as I}from"./chunk-Z4QP44SI.js";import"./chunk-V64N734Y.js";import"./chunk-JDCABF7Y.js";import{a as D}from"./chunk-T2NAWDMZ.js";import{a as b}from"./chunk-AK4CONMS.js";import"./chunk-L5HYRG4P.js";import"./chunk-FEMAFOUH.js";import"./chunk-OUZAVYUG.js";import"./chunk-AY5S4CWZ.js";import"./chunk-B4KB5TBV.js";import"./chunk-FAUOGIHF.js";import"./chunk-CMGPYPUE.js";import"./chunk-7NP5BWIH.js";import"./chunk-AHTGZMT4.js";import"./chunk-MW3G72KG.js";import"./chunk-2HJU3NAO.js";import"./chunk-ZJI2JP7F.js";import"./chunk-QWJG2WVA.js";import"./chunk-6WWKUDWP.js";import"./chunk-Q7K5GJR4.js";import"./chunk-TNEHHCMZ.js";import"./chunk-FP3DRAKI.js";import"./chunk-XB6FCXX3.js";import"./chunk-Q7U5TPQN.js";import"./chunk-CJHPCUUV.js";import"./chunk-YMFQOXT4.js";import"./chunk-IKZ4Z6ND.js";import"./chunk-EEUNNW2P.js";import{spawn as N}from"child_process";import{existsSync as x,mkdirSync as k,readFileSync as A,writeFileSync as w,unlinkSync as M}from"fs";import{tmpdir as F}from"os";import{dirname as L,resolve as l,join as R,relative as C}from"path";function W(){try{let e=import.meta.resolve("sootsim/detox");return L(e.startsWith("file://")?e.slice(7):e)}catch{return l(import.meta.dirname,"..","..","detox")}}var B=`
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{e as P}from"./chunk-AWM244TZ.js";import"./chunk-4KBHOKFR.js";import{b as _,c as I}from"./chunk-JYU7BIGJ.js";import"./chunk-3GQ2VZT3.js";import"./chunk-EMWJQRT7.js";import{a as D}from"./chunk-2U4CK5R5.js";import{a as b}from"./chunk-LUWFFYQL.js";import"./chunk-LNNBPSAL.js";import"./chunk-JVJNG6BQ.js";import"./chunk-J3WU2XCQ.js";import"./chunk-3B5UXJ3Y.js";import"./chunk-ZXFWW4MR.js";import"./chunk-PMERG7PS.js";import"./chunk-ZGTMYSKV.js";import"./chunk-Y7GPDSA2.js";import"./chunk-2CCJGEVS.js";import"./chunk-V4VPUZVL.js";import"./chunk-ZNDD2KOF.js";import"./chunk-JT5JOWHK.js";import"./chunk-G26OO66G.js";import"./chunk-JEMQ2DRI.js";import"./chunk-ZHMKPUDR.js";import"./chunk-3PMTZACY.js";import"./chunk-NVDHSK33.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.js";import{spawn as N}from"child_process";import{existsSync as x,mkdirSync as k,readFileSync as A,writeFileSync as w,unlinkSync as M}from"fs";import{tmpdir as F}from"os";import{dirname as L,resolve as l,join as R,relative as C}from"path";function W(){try{let e=import.meta.resolve("sootsim/detox");return L(e.startsWith("file://")?e.slice(7):e)}catch{return l(import.meta.dirname,"..","..","detox")}}var B=`
3
3
  sootsim detox \u2014 run detox-style tests against a sootsim shell
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-OUZAVYUG.js";import{g as d,i as l,l as a}from"./chunk-AHTGZMT4.js";import"./chunk-6WWKUDWP.js";import"./chunk-XB6FCXX3.js";import"./chunk-Q7U5TPQN.js";import"./chunk-CJHPCUUV.js";import"./chunk-YMFQOXT4.js";import{g as c,h as r,i as g}from"./chunk-IKZ4Z6ND.js";import"./chunk-EEUNNW2P.js";function h(){console.log(`
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-J3WU2XCQ.js";import{g as d,i as l,l as a}from"./chunk-2CCJGEVS.js";import"./chunk-JEMQ2DRI.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import{g as c,h as r,i as g}from"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.js";function h(){console.log(`
3
3
  sootsim device \u2014 inspect or change the live device preset for a sim
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{g as E,i as R,l as b}from"./chunk-AHTGZMT4.js";import"./chunk-Q7U5TPQN.js";import{b as v}from"./chunk-CJHPCUUV.js";import"./chunk-YMFQOXT4.js";import"./chunk-EEUNNW2P.js";function F(e){return e.ts??e.t??0}function W(e){return typeof e.message=="string"&&e.message.length>0?e.message:Array.isArray(e.args)?e.args.map(s=>typeof s=="string"?s:JSON.stringify(s)).join(" "):""}var B=new Set(["timeline","network","react","console","screen"]);function P(){console.log(`
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{g as E,i as R,l as b}from"./chunk-2CCJGEVS.js";import"./chunk-I6SPORCZ.js";import{b as v}from"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-PYIMY6VO.js";function F(e){return e.ts??e.t??0}function W(e){return typeof e.message=="string"&&e.message.length>0?e.message:Array.isArray(e.args)?e.args.map(s=>typeof s=="string"?s:JSON.stringify(s)).join(" "):""}var B=new Set(["timeline","network","react","console","screen"]);function P(){console.log(`
3
3
  sootsim get diagnosis \u2014 compact "what just went wrong?" report
4
4
 
5
5
  usage:
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-Y6Y7QQLA.js";import{f as a,g as b,h as c,i as d,j as e,k as f,l as g,m as h,n as i}from"./chunk-V4VPUZVL.js";import"./chunk-ZNDD2KOF.js";import"./chunk-JT5JOWHK.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-PYIMY6VO.js";export{e as ALL_DRIVERS,i as buildDriverListRows,a as chromiumDriver,b as electronDriver,f as getAllDrivers,g as getDriver,c as playwrightDriver,h as resolveDriver,d as systemDriver};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{c as L,d as T}from"./chunk-LIR2VPPJ.js";import{g as $,i as R,m as b}from"./chunk-AHTGZMT4.js";import"./chunk-Q7U5TPQN.js";import"./chunk-CJHPCUUV.js";import"./chunk-YMFQOXT4.js";import"./chunk-EEUNNW2P.js";import{existsSync as V,mkdirSync as W,unlinkSync as N,writeFileSync as x}from"node:fs";import{homedir as q}from"node:os";import{dirname as j,extname as H,join as K,resolve as E}from"node:path";import{spawnSync as C}from"node:child_process";var s=t=>new Promise(a=>setTimeout(a,t)),X=["--out","--fps","--script","--slow"],J=["--keep-three"],Q=["--background","--gradient","--gradient-angle","--colorway","--environment","--env-shape","--env-spread","--env-size","--env-color","--env-glow","--env-plastic","--room","--focus","--focus-amount","--focus-range"],Y=12e4,Z=16e6;function c(t,a){let n=t.indexOf(a);return n>=0?t[n+1]:void 0}async function r(t,a,n=3e4){return await t.send({type:"evaluate",code:a},{timeoutMs:n})}async function le(t,a){if(t.length===0||t.includes("--help")||t.includes("-h"))return console.log(`
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{c as L,d as T}from"./chunk-7EMJ67H5.js";import{g as $,i as R,m as b}from"./chunk-2CCJGEVS.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-PYIMY6VO.js";import{existsSync as V,mkdirSync as W,unlinkSync as N,writeFileSync as x}from"node:fs";import{homedir as q}from"node:os";import{dirname as j,extname as H,join as K,resolve as E}from"node:path";import{spawnSync as C}from"node:child_process";var s=t=>new Promise(a=>setTimeout(a,t)),X=["--out","--fps","--script","--slow"],J=["--keep-three"],Q=["--background","--gradient","--gradient-angle","--colorway","--environment","--env-shape","--env-spread","--env-size","--env-color","--env-glow","--env-plastic","--room","--focus","--focus-amount","--focus-range"],Y=12e4,Z=16e6;function c(t,a){let n=t.indexOf(a);return n>=0?t[n+1]:void 0}async function r(t,a,n=3e4){return await t.send({type:"evaluate",code:a},{timeoutMs:n})}async function le(t,a){if(t.length===0||t.includes("--help")||t.includes("-h"))return console.log(`
3
3
  sootsim film \u2014 record a flow flat, replay it on the 3d stage, save a clip
4
4
 
5
5
  usage:
@@ -33,7 +33,7 @@ examples:
33
33
  sootsim film flows/swap.yaml --script hero-arc --background gradient-neon --out ~/Desktop/swap-3d.mp4
34
34
  sootsim film flows/login.yaml --colorway deep-blue --environment on --env-shape pane --room on
35
35
  `),0;let n=t.find(d=>!d.startsWith("--")&&/\.ya?ml$/.test(d));if(!n||!V(E(n)))return console.error(` film: flow file not found: ${n??"(none given)"}`),1;let P=Number.parseInt(c(t,"--fps")??"30",10),h=c(t,"--script")??"hero-arc",D=t.includes("--keep-three"),v=n.replace(/^.*\//,"").replace(/\.ya?ml$/,""),I=c(t,"--out"),l=E(I??K(q(),"Desktop","sootsim-films",`${v}.webm`)),y=H(l).toLowerCase()===".mp4";if(y&&C("ffmpeg",["-version"]).status!==0)return console.error(" film: --out ends in .mp4 but ffmpeg is not installed"),console.error(" install ffmpeg or use a .webm output path"),1;let z=$(t,{port:a.port,stripValueFlags:[...X,...Q],stripBooleanFlags:J}),e=R({...z,commandTimeoutMs:6e4});try{let d=await r(e,`(() => { const s = window.SootSim?.bridges?.settings?.get?.() || {}
36
- return { threeMode: s.threeMode === true, editor: s.threeRecordingEditor === true } })()`);if(console.log(` film: recording flow ${v} on the flat canvas`),!await r(e,"(async () => !!(await window.SootSim?.bridges?.startRecording?.('video', undefined, { skipEntitlement: true })))()"))return console.error(" film: engine recording store did not start (is @sootsim/plugin-recording installed?)"),1;let O=Date.now();await s(500);let{runFlowPlayback:G}=await import("./flow-V2SWGBAR.js"),m=[n],S=c(t,"--sim");S&&m.push("--sim",S);let k=c(t,"--slow");k&&m.push("--slow",k);let f=await G(m);await s(400);let u=Math.min(Date.now()-O,Y);if(await r(e,"window.SootSim?.bridges?.stopRecording?.()"),f!==0)return console.error(` film: flow failed (exit ${f}) \u2014 not filming a broken take`),f;let _=!1;for(let o=0;o<50;o++){await s(400);let i=await r(e,`(() => { const s = window.SootSim?.bridges?.getRecordingState?.()
36
+ return { threeMode: s.threeMode === true, editor: s.threeRecordingEditor === true } })()`);if(console.log(` film: recording flow ${v} on the flat canvas`),!await r(e,"(async () => !!(await window.SootSim?.bridges?.startRecording?.('video', undefined, { skipEntitlement: true })))()"))return console.error(" film: engine recording store did not start (is @sootsim/plugin-recording installed?)"),1;let O=Date.now();await s(500);let{runFlowPlayback:G}=await import("./flow-4RXVOUUF.js"),m=[n],S=c(t,"--sim");S&&m.push("--sim",S);let k=c(t,"--slow");k&&m.push("--slow",k);let f=await G(m);await s(400);let u=Math.min(Date.now()-O,Y);if(await r(e,"window.SootSim?.bridges?.stopRecording?.()"),f!==0)return console.error(` film: flow failed (exit ${f}) \u2014 not filming a broken take`),f;let _=!1;for(let o=0;o<50;o++){await s(400);let i=await r(e,`(() => { const s = window.SootSim?.bridges?.getRecordingState?.()
37
37
  return { state: s?.state, hasBlob: !!s?.lastVideoBlob } })()`);if(i?.state==="idle"&&i.hasBlob){_=!0;break}}if(!_)return console.error(" film: flow recording never produced a video blob"),1;console.log(` film: flow captured (${(u/1e3).toFixed(1)}s)`),await r(e,"window.SootSim?.bridges?.settings?.set?.('threeMode', true)"),await L(e),await s(1400),await r(e,"window.SootSim?.bridges?.settings?.set?.('threeRecordingEditor', true)");let F=!1;for(let o=0;o<60;o++)if(await s(250),await r(e,`(() => { const rs = window.SootSim?.replayStore
38
38
  return rs?.value?.preview?.surface === 'video' && !!rs?.value?.preview?.flowVideoUrl })()`)){F=!0;break}if(!F)return console.error(" film: recording editor did not seed the replay store"),1;await r(e,`(async () => {
39
39
  const entitled = () =>
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{c,d,e,f,g,h}from"./chunk-AWM244TZ.js";import{c as a,d as b}from"./chunk-4KBHOKFR.js";import"./chunk-3GQ2VZT3.js";import"./chunk-EMWJQRT7.js";import"./chunk-2U4CK5R5.js";import"./chunk-LUWFFYQL.js";import"./chunk-LNNBPSAL.js";import"./chunk-JVJNG6BQ.js";import"./chunk-J3WU2XCQ.js";import"./chunk-3B5UXJ3Y.js";import"./chunk-ZXFWW4MR.js";import"./chunk-PMERG7PS.js";import"./chunk-ZGTMYSKV.js";import"./chunk-Y7GPDSA2.js";import"./chunk-2CCJGEVS.js";import"./chunk-V4VPUZVL.js";import"./chunk-ZNDD2KOF.js";import"./chunk-JT5JOWHK.js";import"./chunk-G26OO66G.js";import"./chunk-JEMQ2DRI.js";import"./chunk-ZHMKPUDR.js";import"./chunk-3PMTZACY.js";import"./chunk-NVDHSK33.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.js";export{e as discoverSootsimUrl,c as getLastFlowPreviewUploadResult,d as getLastFlowTraceSteps,g as hoistLeadingSimFlag,a as parseFlowFile,f as runFlowPlayback,h as runMaestroAuthoring,b as validateFlowFile};
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a,b,c}from"./chunk-UEA4JYEY.js";import"./chunk-7VZLWO2D.js";import"./chunk-NVDHSK33.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-7RSH52LR.js";import"./chunk-FJPEIFZW.js";import"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.js";export{c as printCommandHelp,b as printGroupHelp,a as printHelp};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.218 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z}from"./chunk-YMFQOXT4.js";import"./chunk-EEUNNW2P.js";export{b as ACTIVE_RUNTIME_FILE,e as CONFIG_FILE,f as DAEMON_HEARTBEAT_STALE_MS,c as DAEMON_LOCKFILE,d as DEV_BRIDGE_LOCKFILE,a as SOOTSIM_HOME_ENV,L as activeRuntimeDir,m as activeRuntimeFile,u as cacheDir,S as claimDaemonLockfile,K as compareSemver,x as configFilePath,F as consumeRuntimeUpgradeNotice,s as daemonAppBundlePath,r as daemonAppDir,t as daemonAppLauncherPath,v as daemonLockfilePath,w as devBridgeLockfilePath,n as electronDir,o as electronUserDataDir,p as electronVersionDir,G as ensureSootsimHome,O as isDaemonLockfileFresh,P as isDevBridgeLockfileFresh,i as isDevWorkstation,h as isSootsimDevCheckout,J as listInstalledRuntimes,q as profilesDir,H as readActiveRuntime,M as readDaemonLockfile,N as readDevBridgeLockfile,B as readOrCreateAnonymousId,y as readSharedConfig,A as readTelemetryEnabled,T as removeDaemonLockfile,U as removeDevBridgeLockfile,l as runtimeDir,D as runtimeUpgradeNoticePath,k as runtimesDir,j as shouldSkipPersistentDaemon,g as sootsimHomeDir,I as writeActiveRuntime,Q as writeDaemonLockfile,R as writeDevBridgeLockfile,E as writeRuntimeUpgradeNotice,z as writeSharedConfig,C as writeTelemetryEnabled};
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z}from"./chunk-BTLNZG23.js";import"./chunk-PYIMY6VO.js";export{b as ACTIVE_RUNTIME_FILE,e as CONFIG_FILE,f as DAEMON_HEARTBEAT_STALE_MS,c as DAEMON_LOCKFILE,d as DEV_BRIDGE_LOCKFILE,a as SOOTSIM_HOME_ENV,L as activeRuntimeDir,m as activeRuntimeFile,u as cacheDir,S as claimDaemonLockfile,K as compareSemver,x as configFilePath,F as consumeRuntimeUpgradeNotice,s as daemonAppBundlePath,r as daemonAppDir,t as daemonAppLauncherPath,v as daemonLockfilePath,w as devBridgeLockfilePath,n as electronDir,o as electronUserDataDir,p as electronVersionDir,G as ensureSootsimHome,O as isDaemonLockfileFresh,P as isDevBridgeLockfileFresh,i as isDevWorkstation,h as isSootsimDevCheckout,J as listInstalledRuntimes,q as profilesDir,H as readActiveRuntime,M as readDaemonLockfile,N as readDevBridgeLockfile,B as readOrCreateAnonymousId,y as readSharedConfig,A as readTelemetryEnabled,T as removeDaemonLockfile,U as removeDevBridgeLockfile,l as runtimeDir,D as runtimeUpgradeNoticePath,k as runtimesDir,j as shouldSkipPersistentDaemon,g as sootsimHomeDir,I as writeActiveRuntime,Q as writeDaemonLockfile,R as writeDevBridgeLockfile,E as writeRuntimeUpgradeNotice,z as writeSharedConfig,C as writeTelemetryEnabled};
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{j as a,k as b}from"./chunk-4KBHOKFR.js";import"./chunk-3GQ2VZT3.js";import"./chunk-LNNBPSAL.js";import"./chunk-JVJNG6BQ.js";import"./chunk-J3WU2XCQ.js";import"./chunk-3B5UXJ3Y.js";import"./chunk-ZXFWW4MR.js";import"./chunk-PMERG7PS.js";import"./chunk-ZGTMYSKV.js";import"./chunk-Y7GPDSA2.js";import"./chunk-2CCJGEVS.js";import"./chunk-V4VPUZVL.js";import"./chunk-ZNDD2KOF.js";import"./chunk-JT5JOWHK.js";import"./chunk-G26OO66G.js";import"./chunk-JEMQ2DRI.js";import"./chunk-NVDHSK33.js";import"./chunk-FGIGSM4Z.js";import"./chunk-I6SPORCZ.js";import"./chunk-C5LRFEF4.js";import"./chunk-BTLNZG23.js";import"./chunk-QH5KCAPX.js";import"./chunk-PYIMY6VO.js";export{a as printShellPerfReport,b as runInspect};
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.219 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a}from"./chunk-ITYDRFAM.js";import"./chunk-GXIL7GMS.js";import"./chunk-ZNDD2KOF.js";import"./chunk-PYIMY6VO.js";export{a as runInstallDesktop};