sootsim 0.1.68 → 0.1.70

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 (137) hide show
  1. package/dist-cli/bin.js +3 -3
  2. package/dist-cli/chunks/{agent-RWWC5VLR.js → agent-BE44JL24.js} +2 -2
  3. package/dist-cli/chunks/{agent-wrapper-AZ2TWUZV.js → agent-wrapper-WNAI6UXX.js} +2 -2
  4. package/dist-cli/chunks/{assert-YVADDYYY.js → assert-E4M7QE67.js} +2 -2
  5. package/dist-cli/chunks/auto-bootstrap-HJTFKMFY.js +2 -0
  6. package/dist-cli/chunks/beta-CBGWCGUS.js +2 -0
  7. package/dist-cli/chunks/{chunk-QYFPV5YO.js → chunk-2G764MLQ.js} +1 -1
  8. package/dist-cli/chunks/chunk-4G6XZHTF.js +119 -0
  9. package/dist-cli/chunks/{chunk-3NNUNABL.js → chunk-5MFLZW2Y.js} +1 -1
  10. package/dist-cli/chunks/{chunk-5LDGAVAV.js → chunk-6HWKKBZ4.js} +2 -2
  11. package/dist-cli/chunks/{chunk-ZP7YYRHI.js → chunk-6URW4GMA.js} +2 -2
  12. package/dist-cli/chunks/{chunk-G3WXMB3Z.js → chunk-772DATRO.js} +1 -1
  13. package/dist-cli/chunks/{chunk-K6N6DEL5.js → chunk-BKRVAP2K.js} +1 -1
  14. package/dist-cli/chunks/{chunk-2HVRBEOU.js → chunk-CF3ZE5OG.js} +2 -2
  15. package/dist-cli/chunks/{chunk-E7FCGYB5.js → chunk-CHPJTXQY.js} +2 -2
  16. package/dist-cli/chunks/{chunk-WHJFB6AK.js → chunk-CK3O33TK.js} +1 -1
  17. package/dist-cli/chunks/{chunk-TKDMCYGS.js → chunk-DJJXNSM3.js} +2 -2
  18. package/dist-cli/chunks/chunk-DKA5PC22.js +1 -0
  19. package/dist-cli/chunks/{chunk-GFXFPPNR.js → chunk-DSF4GC3A.js} +2 -2
  20. package/dist-cli/chunks/{chunk-Z6BCORBY.js → chunk-E3N4FEFL.js} +2 -2
  21. package/dist-cli/chunks/{chunk-CFR6W2AH.js → chunk-E5XC7KT7.js} +2 -2
  22. package/dist-cli/chunks/chunk-FIBZZOZX.js +2 -0
  23. package/dist-cli/chunks/{chunk-OFTI3N27.js → chunk-FLYYVMVE.js} +2 -2
  24. package/dist-cli/chunks/{chunk-5SGAFI2M.js → chunk-FNAG6YPG.js} +2 -2
  25. package/dist-cli/chunks/{chunk-3QA6YYSG.js → chunk-FQJGXRLT.js} +2 -2
  26. package/dist-cli/chunks/{chunk-QHAZOOK2.js → chunk-FVLAIRY5.js} +3 -3
  27. package/dist-cli/chunks/{chunk-6JGI2JVM.js → chunk-G26C77XT.js} +1 -1
  28. package/dist-cli/chunks/chunk-GZ52IGD2.js +2 -0
  29. package/dist-cli/chunks/{chunk-KKK4RTBP.js → chunk-HRKLS6LQ.js} +1 -1
  30. package/dist-cli/chunks/{chunk-TY5CBM3C.js → chunk-J4B6F25M.js} +2 -2
  31. package/dist-cli/chunks/chunk-JXRFI3TK.js +1 -0
  32. package/dist-cli/chunks/{chunk-D5LXWWGN.js → chunk-LLKII2H3.js} +2 -2
  33. package/dist-cli/chunks/{chunk-YSDIOWNN.js → chunk-MORPQN3J.js} +1 -1
  34. package/dist-cli/chunks/{chunk-5QUYJKLU.js → chunk-ODAH77AZ.js} +2 -2
  35. package/dist-cli/chunks/{chunk-HC43PTFD.js → chunk-PF3AVL5U.js} +1 -1
  36. package/dist-cli/chunks/{chunk-BQLKO6NP.js → chunk-QMDKGPM2.js} +2 -2
  37. package/dist-cli/chunks/{chunk-3HF6BNSA.js → chunk-QRZ6T5GY.js} +2 -2
  38. package/dist-cli/chunks/{chunk-WIW3G6HS.js → chunk-S2JBGZV2.js} +2 -2
  39. package/dist-cli/chunks/{chunk-TZYXNQHA.js → chunk-SPHONVYN.js} +1 -1
  40. package/dist-cli/chunks/{chunk-6453CCSA.js → chunk-T52ORT6E.js} +1 -1
  41. package/dist-cli/chunks/{chunk-FBO7YRJM.js → chunk-TGOEMAHH.js} +2 -2
  42. package/dist-cli/chunks/{chunk-H6YUT7HX.js → chunk-TPSFEKYW.js} +41 -36
  43. package/dist-cli/chunks/chunk-U47V7ETP.js +1 -0
  44. package/dist-cli/chunks/{chunk-J7XCQWQI.js → chunk-W3HQJ54T.js} +1 -1
  45. package/dist-cli/chunks/{chunk-52QFCYGQ.js → chunk-WAKMUKQJ.js} +3 -3
  46. package/dist-cli/chunks/{chunk-72Y42WVX.js → chunk-WMXSRYIL.js} +2 -2
  47. package/dist-cli/chunks/{chunk-2NFRZQ3K.js → chunk-WV24QU4A.js} +2 -2
  48. package/dist-cli/chunks/{chunk-WXISHMXL.js → chunk-Y5CJEIPS.js} +1 -1
  49. package/dist-cli/chunks/{chunk-C3R25CWY.js → chunk-YOY373LJ.js} +2 -2
  50. package/dist-cli/chunks/{chunk-TBVBPZRF.js → chunk-YQ4LB334.js} +2 -2
  51. package/dist-cli/chunks/cli-version-7WL6ETBT.js +2 -0
  52. package/dist-cli/chunks/{compat-Z3IFUQ73.js → compat-PVG3VFKR.js} +3 -3
  53. package/dist-cli/chunks/{config-XBERIMLW.js → config-LDQYS4IH.js} +2 -2
  54. package/dist-cli/chunks/{control-SWOP3KB7.js → control-BAFIJQHK.js} +2 -2
  55. package/dist-cli/chunks/{cpu-profile-SNX23Q5V.js → cpu-profile-XCBLHUWP.js} +2 -2
  56. package/dist-cli/chunks/{daemon-QQPC4GOV.js → daemon-53GLE3L6.js} +2 -2
  57. package/dist-cli/chunks/{debug-WENYS45R.js → debug-SOBODZAF.js} +3 -3
  58. package/dist-cli/chunks/demo-app-registry-7ZHREVE6.js +2 -0
  59. package/dist-cli/chunks/{detox-P4N47V6P.js → detox-MK2K6IZG.js} +2 -2
  60. package/dist-cli/chunks/{device-5WWFV22H.js → device-DCVPZOR6.js} +2 -2
  61. package/dist-cli/chunks/{diagnose-HJ4F3ER7.js → diagnose-AJXFZHMR.js} +2 -2
  62. package/dist-cli/chunks/drivers-GVUMEC4A.js +2 -0
  63. package/dist-cli/chunks/{electron-JHFA2OGV.js → electron-HPHSCSCR.js} +3 -3
  64. package/dist-cli/chunks/flow-HXG3QYZD.js +2 -0
  65. package/dist-cli/chunks/{hints-UHQ2T2RX.js → hints-X63I5MJQ.js} +2 -2
  66. package/dist-cli/chunks/{home-paths-NWDFFIX4.js → home-paths-OH6FJPMS.js} +2 -2
  67. package/dist-cli/chunks/{inspect-O34RH4AE.js → inspect-PZLVTXFL.js} +3 -3
  68. package/dist-cli/chunks/install-BZMOV4V3.js +2 -0
  69. package/dist-cli/chunks/{install-desktop-RYP35PHA.js → install-desktop-7D3HAJ5O.js} +3 -3
  70. package/dist-cli/chunks/{keys-U5YI77TK.js → keys-Y6PXP5QR.js} +2 -2
  71. package/dist-cli/chunks/{launch-UFOGCQWO.js → launch-HGTH5YBC.js} +3 -3
  72. package/dist-cli/chunks/{login-SPX6IK6Q.js → login-QXMJJWKS.js} +4 -4
  73. package/dist-cli/chunks/{logout-I6UE3XYL.js → logout-LTR3XSKG.js} +2 -2
  74. package/dist-cli/chunks/{maestro-IPEULAUZ.js → maestro-ORYTSHH2.js} +2 -2
  75. package/dist-cli/chunks/{preview-CE27FPGG.js → preview-M5LDASYT.js} +2 -2
  76. package/dist-cli/chunks/{profile-JZSFMO2Y.js → profile-PQLQWT3D.js} +2 -2
  77. package/dist-cli/chunks/{react-6IJQG4V3.js → react-JJOITVAS.js} +2 -2
  78. package/dist-cli/chunks/{record-6WDKEBXL.js → record-PSM2OORD.js} +2 -2
  79. package/dist-cli/chunks/runtime-RXJSCIY3.js +2 -0
  80. package/dist-cli/chunks/{runtime-delivery-C4KG6ISS.js → runtime-delivery-XVO4SI6R.js} +2 -2
  81. package/dist-cli/chunks/{screenshot-VQTI6G32.js → screenshot-6JDA3SXY.js} +8 -6
  82. package/dist-cli/chunks/{screenshot-mode-JBDCHRSS.js → screenshot-mode-Q3TBBM5O.js} +2 -2
  83. package/dist-cli/chunks/{screenshots-HLMGN2OX.js → screenshots-ZN4XVG62.js} +2 -2
  84. package/dist-cli/chunks/{server-U3QLKQDX.js → server-MUAIM7WS.js} +2 -2
  85. package/dist-cli/chunks/setup-repo-OKDEAMVI.js +2 -0
  86. package/dist-cli/chunks/{skills-SMML5DJP.js → skills-BPZW7ATI.js} +2 -2
  87. package/dist-cli/chunks/{start-7SCU4I64.js → start-NHUS5VXR.js} +4 -4
  88. package/dist-cli/chunks/store-ACINUZDS.js +2 -0
  89. package/dist-cli/chunks/telemetry-WIIZXAXV.js +2 -0
  90. package/dist-cli/chunks/{test-UWFHFDN7.js → test-ZXACHHT5.js} +3 -3
  91. package/dist-cli/chunks/{three-mode-CJUNGCIF.js → three-mode-54OREUHX.js} +2 -2
  92. package/dist-cli/chunks/{timeline-DIRXVM6R.js → timeline-EM52SUJA.js} +2 -2
  93. package/dist-cli/chunks/{upgrade-LQQU4GSZ.js → upgrade-2JLM5IK4.js} +2 -2
  94. package/dist-cli/chunks/upload-OJSCSJRQ.js +2 -0
  95. package/dist-cli/chunks/web-KLAOXMUS.js +2 -0
  96. package/dist-cli/chunks/{what-happened-QFXDQ6VU.js → what-happened-6XVYRXLO.js} +2 -2
  97. package/dist-cli/chunks/{whoami-HWXPDZEF.js → whoami-RQQBHF4S.js} +2 -2
  98. package/dist-lib/agent-daemon-client.cjs +1 -1
  99. package/dist-lib/agent-events.cjs +1 -1
  100. package/dist-lib/agent-sessions.cjs +1 -1
  101. package/dist-lib/attached-projects.cjs +1 -1
  102. package/dist-lib/auth/shared-session.cjs +1 -1
  103. package/dist-lib/backend-origin.cjs +1 -1
  104. package/dist-lib/bridge-constants.cjs +1 -1
  105. package/dist-lib/cli-constants.cjs +1 -1
  106. package/dist-lib/config.cjs +1 -1
  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/index.cjs +1 -1
  113. package/dist-lib/metro.cjs +1 -1
  114. package/dist-lib/profiles.cjs +1 -1
  115. package/dist-lib/render-mode.cjs +1 -1
  116. package/dist-lib/vite-base.cjs +1 -1
  117. package/dist-lib/vite.cjs +1 -1
  118. package/package.json +1 -1
  119. package/dist-cli/chunks/auto-bootstrap-E62IXD2G.js +0 -2
  120. package/dist-cli/chunks/beta-7MI67AHK.js +0 -2
  121. package/dist-cli/chunks/chunk-6TQ2IBH6.js +0 -2
  122. package/dist-cli/chunks/chunk-CMEWLMED.js +0 -1
  123. package/dist-cli/chunks/chunk-CZWZG7GL.js +0 -2
  124. package/dist-cli/chunks/chunk-FITG7BVA.js +0 -1
  125. package/dist-cli/chunks/chunk-HPFXTPOD.js +0 -1
  126. package/dist-cli/chunks/chunk-U7KUAZJB.js +0 -119
  127. package/dist-cli/chunks/cli-version-LM6OBGUK.js +0 -2
  128. package/dist-cli/chunks/demo-app-registry-QWOGX5C2.js +0 -2
  129. package/dist-cli/chunks/drivers-GAEMIY75.js +0 -2
  130. package/dist-cli/chunks/flow-J67STV2Q.js +0 -2
  131. package/dist-cli/chunks/install-ZB2AGO44.js +0 -2
  132. package/dist-cli/chunks/runtime-P54OGI57.js +0 -2
  133. package/dist-cli/chunks/setup-repo-TZULA5RK.js +0 -2
  134. package/dist-cli/chunks/store-WEIVIM3L.js +0 -2
  135. package/dist-cli/chunks/telemetry-U3BBVPLJ.js +0 -2
  136. package/dist-cli/chunks/upload-SSAFKJGF.js +0 -2
  137. package/dist-cli/chunks/web-AJU6QA43.js +0 -2
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{c as I,e as N,i as S}from"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{createWriteStream as k,mkdirSync as v,writeFileSync as C}from"fs";import{dirname as T,resolve as w}from"path";import{Readable as F}from"stream";import{pipeline as y}from"stream/promises";import{createGzip as x}from"zlib";async function U(o,m){let n=Number(b(o,"--duration")??"5");if(!Number.isFinite(n)||n<=0)return console.error(" --duration must be a positive number (seconds)"),1;let a=Number(b(o,"--sample-interval")??"10");if(!Number.isFinite(a)||a<=0)return console.error(" --sample-interval must be a positive number (milliseconds)"),1;let t=Number(b(o,"--max-buffer")??"100000");if(!Number.isFinite(t)||t<=0)return console.error(" --max-buffer must be a positive number"),1;let p=b(o,"--output")??b(o,"-o"),l=w(process.cwd(),p??"/tmp/sootsim.cpuprofile"),g=l.endsWith(".gz"),h=I(o,{port:m.port,stripValueFlags:["--duration","--output","-o","--sample-interval","--max-buffer"]}),c=N({...h,commandTimeoutMs:Math.max(3e4,(n+20)*1e3)});try{let u=await S(c,"SootSim.bridges.workerCpuProfileStart",{sampleInterval:a,maxBufferSize:t});if(!u?.started)return u?.error?.includes("cpu-profile-unsupported")?(console.error(" cpu-profile is currently unsupported."),console.error(" the JS Self-Profiler API cannot profile a dedicated worker, and"),console.error(" sootsim runs the guest app in the tenant worker. a CDP-based"),console.error(" profiler is required \u2014 tracked as the F28 follow-up.")):(console.error(" could not start tenant-worker profiler."),console.error(" is sootsim running? (try `sootsim list`)")),1;m.verbose&&console.error(` started: sampleInterval=${u.sampleInterval}ms buffer=${u.maxBufferSize}`),console.log(` recording for ${n}s\u2026`),await new Promise(r=>setTimeout(r,n*1e3));let s=await S(c,"SootSim.bridges.workerCpuProfileStop");if(!s||s.error||!s.trace)return console.error(` profile capture failed: ${s?.error??"no trace returned"}`),1;let P=B(s.trace),e=JSON.stringify(P);v(T(l),{recursive:!0}),g?await y(F.from([e]),x(),k(l)):C(l,e);let i=(Buffer.byteLength(e)/1024/1024).toFixed(2);return console.log(` samples: ${P.samples.length} (${i} MB uncompressed)`),console.log(` saved: ${l}`),console.log(" open in chrome devtools \u2192 Performance \u2192 Load profile to inspect."),0}catch(u){let s=u?.message??String(u);return console.error(` profile failed: ${s}`),/could not connect|ECONNREFUSED/i.test(s)&&console.error(" is sootsim running? (try `sootsim list`)"),1}finally{c.close()}}function B(o){let m=o.frames??[],n=o.resources??[],a=o.stacks??[],t=o.samples??[],p=1,l=[{id:p,callFrame:{functionName:"(root)",scriptId:"0",url:"",lineNumber:-1,columnNumber:-1},hitCount:0,children:[]}];for(let e=0;e<a.length;e++){let i=a[e],r=m[i.frameId]??{name:"(unknown)"},f=r.resource!==void 0?n[r.resource]??"":"";l.push({id:e+2,callFrame:{functionName:r.name||"(anonymous)",scriptId:r.resource!==void 0?String(r.resource):"0",url:f,lineNumber:typeof r.line=="number"?r.line-1:-1,columnNumber:typeof r.column=="number"?r.column-1:-1},hitCount:0,children:[]})}for(let e=0;e<a.length;e++){let i=a[e],r=e+2,f=i.parentId!==void 0?i.parentId+2:p,d=l[f-1];d&&!d.children.includes(r)&&d.children.push(r)}let g=[],h=[],c=t.length>0?t[0].timestamp:0,u=c;for(let e=0;e<t.length;e++){let i=t[e],r=i.stackId!==void 0?i.stackId+2:p;g.push(r);let f=l[r-1];f&&f.hitCount++;let d=e===0?0:i.timestamp-u;h.push(Math.max(0,Math.round(d*1e3))),u=i.timestamp}let s=Math.round(c*1e3),P=t.length>0?Math.round(t[t.length-1].timestamp*1e3):s;return{nodes:l,startTime:s,endTime:P,samples:g,timeDeltas:h}}function b(o,m){let n=o.indexOf(m);if(!(n<0||n===o.length-1))return o[n+1]}export{U as runCpuProfile};
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{c as I,e as N,i as S}from"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{createWriteStream as k,mkdirSync as v,writeFileSync as C}from"fs";import{dirname as T,resolve as w}from"path";import{Readable as F}from"stream";import{pipeline as y}from"stream/promises";import{createGzip as x}from"zlib";async function U(o,m){let n=Number(b(o,"--duration")??"5");if(!Number.isFinite(n)||n<=0)return console.error(" --duration must be a positive number (seconds)"),1;let a=Number(b(o,"--sample-interval")??"10");if(!Number.isFinite(a)||a<=0)return console.error(" --sample-interval must be a positive number (milliseconds)"),1;let t=Number(b(o,"--max-buffer")??"100000");if(!Number.isFinite(t)||t<=0)return console.error(" --max-buffer must be a positive number"),1;let p=b(o,"--output")??b(o,"-o"),l=w(process.cwd(),p??"/tmp/sootsim.cpuprofile"),g=l.endsWith(".gz"),h=I(o,{port:m.port,stripValueFlags:["--duration","--output","-o","--sample-interval","--max-buffer"]}),c=N({...h,commandTimeoutMs:Math.max(3e4,(n+20)*1e3)});try{let u=await S(c,"SootSim.bridges.workerCpuProfileStart",{sampleInterval:a,maxBufferSize:t});if(!u?.started)return u?.error?.includes("cpu-profile-unsupported")?(console.error(" cpu-profile is currently unsupported."),console.error(" the JS Self-Profiler API cannot profile a dedicated worker, and"),console.error(" sootsim runs the guest app in the tenant worker. a CDP-based"),console.error(" profiler is required \u2014 tracked as the F28 follow-up.")):(console.error(" could not start tenant-worker profiler."),console.error(" is sootsim running? (try `sootsim list`)")),1;m.verbose&&console.error(` started: sampleInterval=${u.sampleInterval}ms buffer=${u.maxBufferSize}`),console.log(` recording for ${n}s\u2026`),await new Promise(r=>setTimeout(r,n*1e3));let s=await S(c,"SootSim.bridges.workerCpuProfileStop");if(!s||s.error||!s.trace)return console.error(` profile capture failed: ${s?.error??"no trace returned"}`),1;let P=B(s.trace),e=JSON.stringify(P);v(T(l),{recursive:!0}),g?await y(F.from([e]),x(),k(l)):C(l,e);let i=(Buffer.byteLength(e)/1024/1024).toFixed(2);return console.log(` samples: ${P.samples.length} (${i} MB uncompressed)`),console.log(` saved: ${l}`),console.log(" open in chrome devtools \u2192 Performance \u2192 Load profile to inspect."),0}catch(u){let s=u?.message??String(u);return console.error(` profile failed: ${s}`),/could not connect|ECONNREFUSED/i.test(s)&&console.error(" is sootsim running? (try `sootsim list`)"),1}finally{c.close()}}function B(o){let m=o.frames??[],n=o.resources??[],a=o.stacks??[],t=o.samples??[],p=1,l=[{id:p,callFrame:{functionName:"(root)",scriptId:"0",url:"",lineNumber:-1,columnNumber:-1},hitCount:0,children:[]}];for(let e=0;e<a.length;e++){let i=a[e],r=m[i.frameId]??{name:"(unknown)"},f=r.resource!==void 0?n[r.resource]??"":"";l.push({id:e+2,callFrame:{functionName:r.name||"(anonymous)",scriptId:r.resource!==void 0?String(r.resource):"0",url:f,lineNumber:typeof r.line=="number"?r.line-1:-1,columnNumber:typeof r.column=="number"?r.column-1:-1},hitCount:0,children:[]})}for(let e=0;e<a.length;e++){let i=a[e],r=e+2,f=i.parentId!==void 0?i.parentId+2:p,d=l[f-1];d&&!d.children.includes(r)&&d.children.push(r)}let g=[],h=[],c=t.length>0?t[0].timestamp:0,u=c;for(let e=0;e<t.length;e++){let i=t[e],r=i.stackId!==void 0?i.stackId+2:p;g.push(r);let f=l[r-1];f&&f.hitCount++;let d=e===0?0:i.timestamp-u;h.push(Math.max(0,Math.round(d*1e3))),u=i.timestamp}let s=Math.round(c*1e3),P=t.length>0?Math.round(t[t.length-1].timestamp*1e3):s;return{nodes:l,startTime:s,endTime:P,samples:g,timeDeltas:h}}function b(o,m){let n=o.indexOf(m);if(!(n<0||n===o.length-1))return o[n+1]}export{U as runCpuProfile};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{c as T}from"./chunk-5SGAFI2M.js";import"./chunk-ZP7YYRHI.js";import"./chunk-U7KUAZJB.js";import"./chunk-6TQ2IBH6.js";import"./chunk-YSDIOWNN.js";import"./chunk-QYFPV5YO.js";import{a as _,b as N}from"./chunk-FBO7YRJM.js";import"./chunk-E7FCGYB5.js";import"./chunk-6JGI2JVM.js";import"./chunk-CZWZG7GL.js";import{g as I,o as C,p as w,q as B}from"./chunk-G3WXMB3Z.js";import{a as W}from"./chunk-HC43PTFD.js";import{execFileSync as et,spawnSync as s}from"child_process";import{existsSync as a,mkdirSync as v,readFileSync as rt,rmSync as S,writeFileSync as U}from"fs";import{homedir as $}from"os";import{dirname as M,resolve as p}from"path";import{execFileSync as Y}from"child_process";import{chmodSync as K,mkdirSync as D,rmSync as X,writeFileSync as P}from"fs";import{dirname as L}from"path";var Q="dev.sootsim.daemon",O="SootSim Daemon",F="0.1.36";function R(t,e,r){let o=w(),n=B(),i=L(L(n)),f=L(n),u=`${i}/Resources`;X(o,{recursive:!0,force:!0}),D(C(),{recursive:!0}),D(f,{recursive:!0}),D(u,{recursive:!0}),P(`${i}/Info.plist`,z()),P(`${i}/PkgInfo`,"APPL????"),P(n,J(t,e,r)),K(n,493);try{Y("codesign",["--force","--sign","-","--deep",o],{stdio:"pipe"})}catch(c){let g=c instanceof Error?c.message:String(c);console.warn(` warning: ad-hoc codesign of ${o} failed: ${g}
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{c as T}from"./chunk-FNAG6YPG.js";import"./chunk-6URW4GMA.js";import"./chunk-4G6XZHTF.js";import"./chunk-FIBZZOZX.js";import"./chunk-MORPQN3J.js";import"./chunk-2G764MLQ.js";import{a as _,b as N}from"./chunk-TGOEMAHH.js";import"./chunk-CHPJTXQY.js";import"./chunk-G26C77XT.js";import"./chunk-GZ52IGD2.js";import{g as I,o as C,p as w,q as B}from"./chunk-772DATRO.js";import{a as W}from"./chunk-PF3AVL5U.js";import{execFileSync as et,spawnSync as s}from"child_process";import{existsSync as a,mkdirSync as v,readFileSync as rt,rmSync as S,writeFileSync as U}from"fs";import{homedir as $}from"os";import{dirname as M,resolve as p}from"path";import{execFileSync as Y}from"child_process";import{chmodSync as K,mkdirSync as D,rmSync as X,writeFileSync as P}from"fs";import{dirname as L}from"path";var Q="dev.sootsim.daemon",O="SootSim Daemon",F="0.1.36";function R(t,e,r){let o=w(),n=B(),i=L(L(n)),f=L(n),u=`${i}/Resources`;X(o,{recursive:!0,force:!0}),D(C(),{recursive:!0}),D(f,{recursive:!0}),D(u,{recursive:!0}),P(`${i}/Info.plist`,z()),P(`${i}/PkgInfo`,"APPL????"),P(n,J(t,e,r)),K(n,493);try{Y("codesign",["--force","--sign","-","--deep",o],{stdio:"pipe"})}catch(c){let g=c instanceof Error?c.message:String(c);console.warn(` warning: ad-hoc codesign of ${o} failed: ${g}
3
3
  the daemon will still run, but Login Items may show a generic name.`)}return{bundlePath:o,launcherPath:n}}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">
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{e as f,l as T}from"./chunk-GFXFPPNR.js";import{F as A,G as D,H as O,I as x,J as v}from"./chunk-J7XCQWQI.js";import{c as S,e as $,g as N}from"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";var H=["portals","sheets","layout","onlayout","animated","render","touch","yoga","all"],R="__sootsimShellAnimationTrace",q="__sootsimDebugAnimation";function L(){console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{e as f,l as T}from"./chunk-DSF4GC3A.js";import{F as A,G as D,H as O,I as x,J as v}from"./chunk-W3HQJ54T.js";import{c as S,e as $,g as N}from"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.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:
@@ -167,7 +167,7 @@ examples:
167
167
  } : null,
168
168
  samples,
169
169
  }
170
- })()`}async function c(i,l){return N(i,l)}async function Y(i,l){let g=S(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","sample-color"]).has(k)){let{runInspect:e}=await import("./inspect-O34RH4AE.js");await e(["debug",...i],{port:l.port,verbose:l.verbose});return}let t=$(g);try{switch(k){case"enable":{let e=B(r[0]);e.length===0&&(console.error(` usage: sootsim debug enable <channel[,channel,...]>
170
+ })()`}async function c(i,l){return N(i,l)}async function Y(i,l){let g=S(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","sample-color"]).has(k)){let{runInspect:e}=await import("./inspect-PZLVTXFL.js");await e(["debug",...i],{port:l.port,verbose:l.verbose});return}let t=$(g);try{switch(k){case"enable":{let e=B(r[0]);e.length===0&&(console.error(` usage: sootsim debug enable <channel[,channel,...]>
171
171
  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 A(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 D(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=`(() => {
172
172
  const d = window.__sootsimDebug.diff(${JSON.stringify(e)}, ${JSON.stringify(o)});
173
173
  if (!d) return null;
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a}from"./chunk-J4B6F25M.js";import"./chunk-PF3AVL5U.js";export{a as APPS};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as S}from"./chunk-H6YUT7HX.js";import"./chunk-TKDMCYGS.js";import"./chunk-HPFXTPOD.js";import"./chunk-BQLKO6NP.js";import"./chunk-2NFRZQ3K.js";import"./chunk-Z6BCORBY.js";import"./chunk-2HVRBEOU.js";import"./chunk-D5LXWWGN.js";import"./chunk-WIW3G6HS.js";import"./chunk-GFXFPPNR.js";import"./chunk-J7XCQWQI.js";import"./chunk-TY5CBM3C.js";import"./chunk-72Y42WVX.js";import"./chunk-3NNUNABL.js";import"./chunk-FITG7BVA.js";import"./chunk-C3R25CWY.js";import"./chunk-K6N6DEL5.js";import"./chunk-ZP7YYRHI.js";import"./chunk-6TQ2IBH6.js";import"./chunk-FBO7YRJM.js";import"./chunk-E7FCGYB5.js";import"./chunk-5QUYJKLU.js";import"./chunk-6JGI2JVM.js";import"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{spawn as D}from"child_process";import{existsSync as u,mkdirSync as _,writeFileSync as f,unlinkSync as I}from"fs";import{tmpdir as P}from"os";import{dirname as $,resolve as n,join as M}from"path";function E(){try{let e=import.meta.resolve("sootsim/detox");return $(e.startsWith("file://")?e.slice(7):e)}catch{return n(import.meta.dirname,"..","..","detox")}}var F=`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as S}from"./chunk-TPSFEKYW.js";import"./chunk-DJJXNSM3.js";import"./chunk-DKA5PC22.js";import"./chunk-QMDKGPM2.js";import"./chunk-WV24QU4A.js";import"./chunk-E3N4FEFL.js";import"./chunk-CF3ZE5OG.js";import"./chunk-LLKII2H3.js";import"./chunk-S2JBGZV2.js";import"./chunk-DSF4GC3A.js";import"./chunk-W3HQJ54T.js";import"./chunk-J4B6F25M.js";import"./chunk-WMXSRYIL.js";import"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import"./chunk-6URW4GMA.js";import"./chunk-FIBZZOZX.js";import"./chunk-TGOEMAHH.js";import"./chunk-CHPJTXQY.js";import"./chunk-ODAH77AZ.js";import"./chunk-G26C77XT.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{spawn as D}from"child_process";import{existsSync as u,mkdirSync as _,writeFileSync as f,unlinkSync as I}from"fs";import{tmpdir as P}from"os";import{dirname as $,resolve as n,join as M}from"path";function E(){try{let e=import.meta.resolve("sootsim/detox");return $(e.startsWith("file://")?e.slice(7):e)}catch{return n(import.meta.dirname,"..","..","detox")}}var F=`
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.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-HPFXTPOD.js";import"./chunk-ZP7YYRHI.js";import"./chunk-5QUYJKLU.js";import{f as c,g as r,h as g}from"./chunk-6JGI2JVM.js";import{c as d,e as l,h as a}from"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";function h(){console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-DKA5PC22.js";import"./chunk-6URW4GMA.js";import"./chunk-ODAH77AZ.js";import{f as c,g as r,h as g}from"./chunk-G26C77XT.js";import{c as d,e as l,h as a}from"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.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.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{c as E,e as R,h as b}from"./chunk-5LDGAVAV.js";import{b as v}from"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.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.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{c as E,e as R,h as b}from"./chunk-6HWKKBZ4.js";import{b as v}from"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.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 diagnose \u2014 compact "what just went wrong?" report
4
4
 
5
5
  usage:
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-U47V7ETP.js";import{a,b,c,d,e,f,g,h,i}from"./chunk-WMXSRYIL.js";import"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.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.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as g}from"./chunk-KKK4RTBP.js";import"./chunk-CMEWLMED.js";import{a as v,f as h}from"./chunk-D5LXWWGN.js";import"./chunk-WIW3G6HS.js";import"./chunk-GFXFPPNR.js";import"./chunk-J7XCQWQI.js";import"./chunk-TY5CBM3C.js";import{b as f,g as u}from"./chunk-72Y42WVX.js";import{a as p}from"./chunk-3NNUNABL.js";import"./chunk-FITG7BVA.js";import{c as m}from"./chunk-C3R25CWY.js";import"./chunk-K6N6DEL5.js";import"./chunk-6TQ2IBH6.js";import"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";function b(e){let r=e.indexOf("--port");if(r<0)return;let o=e[r+1],i=o?Number(o):Number.NaN;return(!Number.isInteger(i)||i<=0)&&(console.error(` invalid --port value: ${o||"(missing)"}`),process.exit(1)),i}async function O(e,r){let o=b(e)??r.port;return o?h(String(o)):void 0}async function $(e,r){(e.includes("--help")||e.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as g}from"./chunk-HRKLS6LQ.js";import"./chunk-U47V7ETP.js";import{a as v,f as h}from"./chunk-LLKII2H3.js";import"./chunk-S2JBGZV2.js";import"./chunk-DSF4GC3A.js";import"./chunk-W3HQJ54T.js";import"./chunk-J4B6F25M.js";import{b as f,g as u}from"./chunk-WMXSRYIL.js";import{a as p}from"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import{c as m}from"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import"./chunk-FIBZZOZX.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";function b(e){let r=e.indexOf("--port");if(r<0)return;let o=e[r+1],i=o?Number(o):Number.NaN;return(!Number.isInteger(i)||i<=0)&&(console.error(` invalid --port value: ${o||"(missing)"}`),process.exit(1)),i}async function O(e,r){let o=b(e)??r.port;return o?h(String(o)):void 0}async function $(e,r){(e.includes("--help")||e.includes("-h"))&&(console.log(`
3
3
  sootsim electron \u2014 launch the desktop companion
4
4
 
5
5
  usage:
@@ -15,4 +15,4 @@ examples:
15
15
  sootsim electron
16
16
  sootsim electron --port 5173
17
17
  sootsim electron --profile qa
18
- `),process.exit(0));let o=e.indexOf("--driver"),i=o>=0?e[o+1]:void 0,t=e.find((n,a)=>e[a-1]==="--profile"),d=e.includes("--ephemeral");t&&d&&(console.error(" sootsim electron: --profile cannot be combined with --ephemeral"),process.exit(1));let x=t?m(t).id:void 0,s=i||r.driver,l=f;if(s){let n=u(s);n||(console.error(` unknown driver "${s}" \u2014 run \`sootsim list --drivers\``),process.exit(1)),l=n}if(l.id==="electron"){let n=p();if(!n){if(v(),process.stdin.isTTY&&process.env.CI!=="1"&&process.env.SOOTSIM_NO_PROMPT!=="1"&&await g("run sootsim install-desktop now?",!0)){console.log();let{runInstallDesktop:I}=await import("./install-desktop-RYP35PHA.js");await I(["--yes"]),n=p()}n||process.exit(1)}console.log(` launching ${n.path}`)}let w=await O(e,r),c=await l.launch({url:w,device:r.device,profileId:x,ephemeralProfile:d});c.launched||(console.error(` ${c.message}`),process.exit(1)),console.log(` ${c.message}`)}export{O as resolveElectronLaunchUrl,$ as runElectron};
18
+ `),process.exit(0));let o=e.indexOf("--driver"),i=o>=0?e[o+1]:void 0,t=e.find((n,a)=>e[a-1]==="--profile"),d=e.includes("--ephemeral");t&&d&&(console.error(" sootsim electron: --profile cannot be combined with --ephemeral"),process.exit(1));let x=t?m(t).id:void 0,s=i||r.driver,l=f;if(s){let n=u(s);n||(console.error(` unknown driver "${s}" \u2014 run \`sootsim list --drivers\``),process.exit(1)),l=n}if(l.id==="electron"){let n=p();if(!n){if(v(),process.stdin.isTTY&&process.env.CI!=="1"&&process.env.SOOTSIM_NO_PROMPT!=="1"&&await g("run sootsim install-desktop now?",!0)){console.log();let{runInstallDesktop:I}=await import("./install-desktop-7D3HAJ5O.js");await I(["--yes"]),n=p()}n||process.exit(1)}console.log(` launching ${n.path}`)}let w=await O(e,r),c=await l.launch({url:w,device:r.device,profileId:x,ephemeralProfile:d});c.launched||(console.error(` ${c.message}`),process.exit(1)),console.log(` ${c.message}`)}export{O as resolveElectronLaunchUrl,$ as runElectron};
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as c,b as d,c as e,d as f}from"./chunk-TPSFEKYW.js";import"./chunk-DJJXNSM3.js";import"./chunk-DKA5PC22.js";import"./chunk-QMDKGPM2.js";import"./chunk-WV24QU4A.js";import"./chunk-E3N4FEFL.js";import{d as a,e as b}from"./chunk-CF3ZE5OG.js";import"./chunk-LLKII2H3.js";import"./chunk-S2JBGZV2.js";import"./chunk-DSF4GC3A.js";import"./chunk-W3HQJ54T.js";import"./chunk-J4B6F25M.js";import"./chunk-WMXSRYIL.js";import"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import"./chunk-6URW4GMA.js";import"./chunk-FIBZZOZX.js";import"./chunk-TGOEMAHH.js";import"./chunk-CHPJTXQY.js";import"./chunk-ODAH77AZ.js";import"./chunk-G26C77XT.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";export{c as discoverSootsimUrl,e as hoistLeadingSimFlag,a as parseFlowFile,f as runFlow,d as runFlowPlayback,b as validateFlowFile};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as n,c as r,d as l}from"./chunk-TBVBPZRF.js";import"./chunk-6453CCSA.js";import"./chunk-HC43PTFD.js";function a(t){let s=t[0]??"list";if(s==="reset"){t[1]==="global"?(r(),console.log(" cleared global hint state")):(n(),console.log(" cleared hint state for this CLI identity"));return}if(s==="list"){let e=l();if(!e.length){console.log(" no hints registered");return}let i=Math.max(...e.map(o=>o.id.length));console.log(" registered hints:");for(let o of e){let c=typeof o.frequency=="string"?o.frequency:`cooldown ${o.frequency.cooldownMs}ms`;console.log(` ${o.id.padEnd(i)} ${c}`)}console.log(""),console.log(" env overrides:"),console.log(" SOOTSIM_HINTS=off suppress all hints"),console.log(" SOOTSIM_HINTS=always show every hint every time");return}console.error(` unknown subcommand: ${s}`),console.error(" usage:"),console.error(" sootsim hints list show registered hints"),console.error(" sootsim hints reset [global] clear shown-state"),process.exit(1)}export{a as runHints};
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as n,c as r,d as l}from"./chunk-YQ4LB334.js";import"./chunk-T52ORT6E.js";import"./chunk-PF3AVL5U.js";function a(t){let s=t[0]??"list";if(s==="reset"){t[1]==="global"?(r(),console.log(" cleared global hint state")):(n(),console.log(" cleared hint state for this CLI identity"));return}if(s==="list"){let e=l();if(!e.length){console.log(" no hints registered");return}let i=Math.max(...e.map(o=>o.id.length));console.log(" registered hints:");for(let o of e){let c=typeof o.frequency=="string"?o.frequency:`cooldown ${o.frequency.cooldownMs}ms`;console.log(` ${o.id.padEnd(i)} ${c}`)}console.log(""),console.log(" env overrides:"),console.log(" SOOTSIM_HINTS=off suppress all hints"),console.log(" SOOTSIM_HINTS=always show every hint every time");return}console.error(` unknown subcommand: ${s}`),console.error(" usage:"),console.error(" sootsim hints list show registered hints"),console.error(" sootsim hints reset [global] clear shown-state"),process.exit(1)}export{a as runHints};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{A,B,C,D,E,F,G,H,I,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-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";export{b as ACTIVE_RUNTIME_FILE,d as CONFIG_FILE,e as DAEMON_HEARTBEAT_STALE_MS,c as DAEMON_LOCKFILE,a as SOOTSIM_HOME_ENV,D as activeRuntimeDir,j as activeRuntimeFile,r as cacheDir,H as claimDaemonLockfile,C as compareSemver,t as configFilePath,p as daemonAppBundlePath,o as daemonAppDir,q as daemonAppLauncherPath,s as daemonLockfilePath,k as electronDir,l as electronUserDataDir,m as electronVersionDir,y as ensureSootsimHome,F as isDaemonLockfileFresh,g as isSootsimDevCheckout,B as listInstalledRuntimes,n as profilesDir,z as readActiveRuntime,E as readDaemonLockfile,u as readSharedConfig,w as readTelemetryEnabled,I as removeDaemonLockfile,i as runtimeDir,h as runtimesDir,f as sootsimHomeDir,A as writeActiveRuntime,G as writeDaemonLockfile,v as writeSharedConfig,x as writeTelemetryEnabled};
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{A,B,C,D,E,F,G,H,I,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-772DATRO.js";import"./chunk-PF3AVL5U.js";export{b as ACTIVE_RUNTIME_FILE,d as CONFIG_FILE,e as DAEMON_HEARTBEAT_STALE_MS,c as DAEMON_LOCKFILE,a as SOOTSIM_HOME_ENV,D as activeRuntimeDir,j as activeRuntimeFile,r as cacheDir,H as claimDaemonLockfile,C as compareSemver,t as configFilePath,p as daemonAppBundlePath,o as daemonAppDir,q as daemonAppLauncherPath,s as daemonLockfilePath,k as electronDir,l as electronUserDataDir,m as electronVersionDir,y as ensureSootsimHome,F as isDaemonLockfileFresh,g as isSootsimDevCheckout,B as listInstalledRuntimes,n as profilesDir,z as readActiveRuntime,E as readDaemonLockfile,u as readSharedConfig,w as readTelemetryEnabled,I as removeDaemonLockfile,i as runtimeDir,h as runtimesDir,f as sootsimHomeDir,A as writeActiveRuntime,G as writeDaemonLockfile,v as writeSharedConfig,x as writeTelemetryEnabled};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as Q}from"./chunk-TBVBPZRF.js";import{a as pt,b as ft}from"./chunk-TZYXNQHA.js";import{a as He,h as ye,k as ee}from"./chunk-2HVRBEOU.js";import{b as gt,c as yt,i as ht}from"./chunk-D5LXWWGN.js";import"./chunk-WIW3G6HS.js";import{a as Z,b as j,c as J,d as ne,e as V,f as ge,g as de,h as dt,i as ut,j as Fe,k as mt}from"./chunk-GFXFPPNR.js";import{B as at,D as le,E as lt,K as ct,a as fe,b as Ue,c as Ke,d as ze,e as Ye,f as Ge,g as Xe,h as Me,i as Ie,n as Ne,o as Ve,p as Qe,q as Ze,r as et,s as tt,t as ot,u as st,v as nt,w as rt,x as it}from"./chunk-J7XCQWQI.js";import"./chunk-TY5CBM3C.js";import"./chunk-72Y42WVX.js";import"./chunk-3NNUNABL.js";import"./chunk-FITG7BVA.js";import"./chunk-C3R25CWY.js";import"./chunk-K6N6DEL5.js";import{a as Be}from"./chunk-WXISHMXL.js";import{a as Se,c as ke}from"./chunk-U7KUAZJB.js";import{a as De}from"./chunk-6TQ2IBH6.js";import{c as Je,e as Le,f as qe,g as We,h as Te}from"./chunk-5LDGAVAV.js";import{b as je}from"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{existsSync as eo,mkdirSync as to,readFileSync as oo,rmSync as bt,writeFileSync as so}from"fs";import{tmpdir as no}from"os";import{dirname as ro,join as io,resolve as ao}from"path";var ue=1,lo="SOOTSIM_INSPECT_NOTICE_PATH",co=300*1e3,uo=15e3;function wt(){return ao(process.env[lo]||io(no(),"sootsim-inspect-notice-state.json"))}function mo(o,l){return Object.fromEntries(Object.entries(o).filter(([,i])=>typeof i?.signature=="string"&&Number.isFinite(i?.updatedAt)&&l-i.updatedAt<=co))}function po(o){let l=wt();if(!eo(l))return{version:ue,entries:{}};try{let i=JSON.parse(oo(l,"utf8"));return i.version!==ue||!i.entries||typeof i.entries!="object"?(bt(l,{force:!0}),{version:ue,entries:{}}):{version:ue,entries:mo(i.entries,o)}}catch{return bt(l,{force:!0}),{version:ue,entries:{}}}}function fo(o){let l=wt();to(ro(l),{recursive:!0}),so(l,JSON.stringify(o,null,2)+`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as Q}from"./chunk-YQ4LB334.js";import{a as pt,b as ft}from"./chunk-SPHONVYN.js";import{a as He,h as ye,k as ee}from"./chunk-CF3ZE5OG.js";import{b as gt,c as yt,i as ht}from"./chunk-LLKII2H3.js";import"./chunk-S2JBGZV2.js";import{a as Z,b as j,c as J,d as ne,e as V,f as ge,g as de,h as dt,i as ut,j as Fe,k as mt}from"./chunk-DSF4GC3A.js";import{B as at,D as le,E as lt,K as ct,a as fe,b as Ue,c as Ke,d as ze,e as Ye,f as Ge,g as Xe,h as Me,i as Ie,n as Ne,o as Ve,p as Qe,q as Ze,r as et,s as tt,t as ot,u as st,v as nt,w as rt,x as it}from"./chunk-W3HQJ54T.js";import"./chunk-J4B6F25M.js";import"./chunk-WMXSRYIL.js";import"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import{a as Be}from"./chunk-Y5CJEIPS.js";import{a as Se,c as ke}from"./chunk-4G6XZHTF.js";import{a as De}from"./chunk-FIBZZOZX.js";import{c as Je,e as Le,f as qe,g as We,h as Te}from"./chunk-6HWKKBZ4.js";import{b as je}from"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{existsSync as eo,mkdirSync as to,readFileSync as oo,rmSync as bt,writeFileSync as so}from"fs";import{tmpdir as no}from"os";import{dirname as ro,join as io,resolve as ao}from"path";var ue=1,lo="SOOTSIM_INSPECT_NOTICE_PATH",co=300*1e3,uo=15e3;function wt(){return ao(process.env[lo]||io(no(),"sootsim-inspect-notice-state.json"))}function mo(o,l){return Object.fromEntries(Object.entries(o).filter(([,i])=>typeof i?.signature=="string"&&Number.isFinite(i?.updatedAt)&&l-i.updatedAt<=co))}function po(o){let l=wt();if(!eo(l))return{version:ue,entries:{}};try{let i=JSON.parse(oo(l,"utf8"));return i.version!==ue||!i.entries||typeof i.entries!="object"?(bt(l,{force:!0}),{version:ue,entries:{}}):{version:ue,entries:mo(i.entries,o)}}catch{return bt(l,{force:!0}),{version:ue,entries:{}}}}function fo(o){let l=wt();to(ro(l),{recursive:!0}),so(l,JSON.stringify(o,null,2)+`
3
3
  `)}function go(o,l){let i=l.trim()||"default";return`${o}:${i}`}function _e(o,l,i,c={}){let f=c.nowMs??Date.now(),a=c.cooldownMs??uo,y=po(f),$=go(o,l),_=y.entries[$];return _&&_.signature===i&&f-_.updatedAt<a?!1:(y.entries[$]={signature:i,updatedAt:f},fo(y),!0)}async function xt(o,l={args:[]}){let i=await Ue(o);if(j(l.args)){J(i);return}console.log(` nodes: ${i.nodes}`)}function Ae(o,l){let i=o.indexOf(l);return i>=0&&i+1<o.length?o[i+1]:null}async function $t(o){let{bridge:l,args:i,positional:c}=o,f=i.includes("--verbose")||i.includes("-v"),a=j(i),y=f&&!a,$=i.includes("--watch")||i.includes("-w"),_=1e3,k=i.includes("--compact"),b=i.includes("--no-xy"),S=i.includes("--no-clipped"),M=Ae(i,"--testid-like"),I=Ae(i,"--only"),O=Ae(i,"--subtree"),D=c[1],u=D?/[*?]/.test(D):!1,H=!u&&!I?D:void 0,B=I??(u?D:void 0),C=async()=>{await ge(l,{verbose:y});let Y=await Ye(l,{describe:!0,verbose:f,filter:H||"",testIdLike:M||void 0,onlyGlob:B||void 0,subtreeRoot:O||void 0,compact:k,hideXy:b}),x=Y?.tree,T=Y?.shell,q=Y?.keyboard;if(a){J({shell:T,tree:x??"",keyboard:q});return}if(T&&typeof T=="object"){let E=[T.state?`state=${T.state}`:null,T.activeApp?`app=${T.activeApp}`:null,T.showSwitcher?"switcher":null,T.switcherPhase&&T.switcherPhase!=="idle"?`phase=${T.switcherPhase}`:null].filter(Boolean);E.length>0&&console.log(` shell: ${E.join(" ")}`)}if(typeof x=="string"&&x.startsWith("__SUBTREE_NOT_FOUND__:")){let E=x.slice(22);console.log(` subtree root not found: ${E}`),Q("subtree-root-not-found",E);return}if(!x){let E=Y?.nodeCount??0;console.log(" no matching nodes found"),!(H||M||B||O)&&E<10&&Q("app-still-loading",E);return}let z=x,G=0;if(S&&typeof z=="string"){let E=z.split(`
4
4
  `),se=[];for(let pe of E){if(pe.includes("(clipped:")){G+=1;continue}se.push(pe)}z=se.join(`
5
5
  `)}console.log(z),G>0&&console.log(` ${G} clipped row(s) hidden (omit --no-clipped to see)`);let re=H||M||B||O;if((H||M||B)&&!$&&Q("describe-filter-context"),!re&&!$&&x.split(`
@@ -114,7 +114,7 @@ import{a as Q}from"./chunk-TBVBPZRF.js";import{a as pt,b as ft}from"./chunk-TZYX
114
114
  `);console.log(`${t??""}
115
115
 
116
116
  ${n}
117
- `),process.exit(0)}let M=f.wsPort,I=f.simId,O=f.simIdSource,D=f.commandTimeoutMs;if(y==="list"&&c.some(e=>e==="--drivers"||e==="-D")){let{buildDriverListRows:e}=await import("./drivers-GAEMIY75.js"),t=e();console.log(` available drivers (${t.length}):
117
+ `),process.exit(0)}let M=f.wsPort,I=f.simId,O=f.simIdSource,D=f.commandTimeoutMs;if(y==="list"&&c.some(e=>e==="--drivers"||e==="-D")){let{buildDriverListRows:e}=await import("./drivers-GVUMEC4A.js"),t=e();console.log(` available drivers (${t.length}):
118
118
  `);let n=Math.max(...t.map(s=>s.id.length),6),r=Math.max(...t.map(s=>s.kind.length),4);for(let s of t){let d=s.available?"\u2713":"\u2717",m=s.id.padEnd(n),g=s.kind.padEnd(r);console.log(` ${d} ${m} ${g} ${s.description}`),s.available&&s.detail?console.log(` ${s.detail}`):!s.available&&s.reason&&console.log(` unavailable: ${s.reason}`)}return}let u=Le(f),H=I||"default",B=new Set(["errors","warnings","requests","js","eval","reload","globals","perf","list","wait","sleep"]),C=200;function oe(e){let t=e.replace(/\s+/g," ").trim();if(!t)return"";if(/^<(!doctype html|html|\?xml)|<body[\s>]/i.test(t)){let r=/<title[^>]*>([^<]+)<\/title>/i.exec(e)?.[1]?.trim(),s=/<body[^>]*>([\s\S]*?)<\//i.exec(e)?.[1]?.replace(/<[^>]+>/g," ").replace(/\s+/g," ").trim().slice(0,80),d=r||s||"html error page";return`<html ${e.length}B> "${d}" (body elided \u2014 add --json for the full payload)`}return t.length<=C?t:`${t.slice(0,C)}\u2026 (+${t.length-C} more bytes)`}function Y(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 x(e){let t=he()?5e3:1500;try{let{settled:n,elapsed:r}=await ee({bridge:e,maxMs:t,pollMs:32,stablePolls:2});n||process.stderr.write(` \u26A0 auto-wait timed out after ${r??t}ms \u2014 next command may see mid-animation state. use \`sootsim do settle\` for a longer wait.
119
119
  `)}catch{}}function T(e){return!(!e||e.hit===!1||e.ok===!1||e.pointerTapHandled===!1&&!e.keyboardOpened&&!e.isTextInput)}function q(e,t){return{id:e.target?.id??e.match?.id??e.node?.id??null,testID:e.target?.testID??e.match?.testID??e.node?.testID??null,text:e.target?.text??e.target?.accessibilityLabel??e.match?.text??e.match?.accessibilityLabel??e.node?.text??t??null,type:e.target?.type??e.match?.type??e.node?.type??null}}async function z(e){let t=0,n=null,r=null;try{await ee({bridge:u,maxMs:he()?3e3:1200,pollMs:32,stablePolls:2})}catch{}let s=Date.now()+(he()?5e3:2500);for(;Date.now()<=s||t===0;){t++;let d=await e.resolve();if(n=d,d?.error==="bridge-not-ready"||d?.ambiguous||d?.nthOutOfRange)return{payload:d,result:null,attempts:t,failure:"special"};if(d&&typeof d.cx=="number"&&typeof d.cy=="number"){let g=await u.send({type:"tap",x:d.cx,y:d.cy,target:q(d,e.textFallback)});if(r=g,T(g))return{payload:d,result:g,attempts:t}}let m=s-Date.now();if(m<=0)break;try{await ee({bridge:u,maxMs:Math.min(m,700),pollMs:32,stablePolls:2})}catch{await Z(Math.min(120,m))}}return{payload:n,result:r,attempts:t,failure:n&&typeof n.cx=="number"?"missed":"not-found"}}function G(e,t){console.error(` tap failed: ${e} stayed visible but did not receive a hittable press after ${t.attempts} attempt${t.attempts===1?"":"s"}`),t.result&&console.error(` last result: ${JSON.stringify(t.result)}`)}async function re(){try{return await u.send({type:"evaluate",code:`(() => ({
120
120
  console: window.__sootsimConsole?.count?.() || null,
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as o}from"./chunk-E5XC7KT7.js";import"./chunk-HRKLS6LQ.js";import"./chunk-FVLAIRY5.js";import"./chunk-TGOEMAHH.js";import"./chunk-CHPJTXQY.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";async function t(n){console.error(" note: `sootsim install` is now `sootsim setup-repo`. forwarding\u2026\n"),await o(n)}export{t as runInstall};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as b}from"./chunk-KKK4RTBP.js";import{a as x}from"./chunk-3NNUNABL.js";import"./chunk-HC43PTFD.js";import{spawn as k,spawnSync as u}from"child_process";import{chmodSync as S,createWriteStream as E,existsSync as w,mkdirSync as y,renameSync as T,rmSync as g,statSync as P}from"fs";import{tmpdir as D}from"os";import{dirname as M,join as f,resolve as v}from"path";var h="https://sootbean.com/api/electron-release";function A(){let r=process.arch;if(process.platform==="darwin"){let o=r==="arm64"?"mac-arm64":"mac-x64",n=`sootsim-latest-${o}.dmg`;return{platform:o,filename:n,url:`${h}/${n}`,install:_}}if(process.platform==="linux"){let o="sootsim-latest-linux-x64.AppImage";return{platform:"linux-x64",filename:o,url:`${h}/${o}`,install:L}}if(process.platform==="win32"){let o="sootsim-latest-win-x64.exe";return{platform:"win-x64",filename:o,url:`${h}/${o}`,install:C}}return null}async function O({url:r,dest:o,onProgress:n}){let s=await fetch(r,{redirect:"follow"});if(!s.ok)throw new Error(`download failed: ${s.status} ${s.statusText} (${r})`);let t=s.headers.get("content-length"),a=t?Number(t):null;if(!s.body)throw new Error("download failed: empty response body");y(M(o),{recursive:!0});let i=E(o),d=s.body.getReader(),c=0;try{for(;;){let{done:l,value:p}=await d.read();if(l)break;i.write(Buffer.from(p)),c+=p.byteLength,n?.(c,a)}}finally{await new Promise((l,p)=>{i.end(e=>e?p(e):l())})}}function I(r,o){let n=(r/1048576).toFixed(1);if(!o)return` ${n} MB`;let s=Math.min(100,Math.round(r/o*100)),t=(o/(1024*1024)).toFixed(1),a=24,i=Math.round(s/100*a);return` ${"\u2588".repeat(i)+"\u2591".repeat(a-i)} ${s}% ${n} / ${t} MB`}async function _(r){let o=u("hdiutil",["attach","-nobrowse","-readonly",r],{encoding:"utf8"});if(o.status!==0)throw new Error(`hdiutil attach failed: ${o.stderr||o.stdout}`.trim());let n=o.stdout.trim().split(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as b}from"./chunk-HRKLS6LQ.js";import{a as x}from"./chunk-5MFLZW2Y.js";import"./chunk-PF3AVL5U.js";import{spawn as k,spawnSync as u}from"child_process";import{chmodSync as S,createWriteStream as E,existsSync as w,mkdirSync as y,renameSync as T,rmSync as g,statSync as P}from"fs";import{tmpdir as D}from"os";import{dirname as M,join as f,resolve as v}from"path";var h="https://sootbean.com/api/electron-release";function A(){let r=process.arch;if(process.platform==="darwin"){let o=r==="arm64"?"mac-arm64":"mac-x64",n=`sootsim-latest-${o}.dmg`;return{platform:o,filename:n,url:`${h}/${n}`,install:_}}if(process.platform==="linux"){let o="sootsim-latest-linux-x64.AppImage";return{platform:"linux-x64",filename:o,url:`${h}/${o}`,install:L}}if(process.platform==="win32"){let o="sootsim-latest-win-x64.exe";return{platform:"win-x64",filename:o,url:`${h}/${o}`,install:C}}return null}async function O({url:r,dest:o,onProgress:n}){let s=await fetch(r,{redirect:"follow"});if(!s.ok)throw new Error(`download failed: ${s.status} ${s.statusText} (${r})`);let t=s.headers.get("content-length"),a=t?Number(t):null;if(!s.body)throw new Error("download failed: empty response body");y(M(o),{recursive:!0});let i=E(o),d=s.body.getReader(),c=0;try{for(;;){let{done:l,value:p}=await d.read();if(l)break;i.write(Buffer.from(p)),c+=p.byteLength,n?.(c,a)}}finally{await new Promise((l,p)=>{i.end(e=>e?p(e):l())})}}function I(r,o){let n=(r/1048576).toFixed(1);if(!o)return` ${n} MB`;let s=Math.min(100,Math.round(r/o*100)),t=(o/(1024*1024)).toFixed(1),a=24,i=Math.round(s/100*a);return` ${"\u2588".repeat(i)+"\u2591".repeat(a-i)} ${s}% ${n} / ${t} MB`}async function _(r){let o=u("hdiutil",["attach","-nobrowse","-readonly",r],{encoding:"utf8"});if(o.status!==0)throw new Error(`hdiutil attach failed: ${o.stderr||o.stdout}`.trim());let n=o.stdout.trim().split(`
3
3
  `),t=n[n.length-1].split(" ").pop()?.trim();if(!t||!w(t))throw new Error(`could not determine dmg mount point (output: ${o.stdout})`);let a=f(t,"sootsim.app");if(!w(a))throw u("hdiutil",["detach","-force",t]),new Error(`sootsim.app not found inside ${t}`);let i="/Applications",d=v(process.env.HOME||"","Applications"),c=i;try{let m=f(i,`.sootsim-write-probe-${process.pid}`);u("touch",[m]),w(m)?g(m,{force:!0}):c=d}catch{c=d}c===d&&y(c,{recursive:!0});let l=f(c,"sootsim.app");w(l)&&g(l,{recursive:!0,force:!0});let p=u("cp",["-R",a,l]),e=u("hdiutil",["detach","-force",t]);if(p.status!==0)throw new Error(`copy to ${l} failed: ${p.stderr?.toString()||""}`.trim());return e.status!==0&&console.warn(` warning: failed to unmount ${t} (${e.stderr?.toString().trim()||"unknown error"})`),u("xattr",["-dr","com.apple.quarantine",l]),l}async function L(r){let o=v(process.env.HOME||"","Applications");y(o,{recursive:!0});let n=f(o,"sootsim.AppImage");return w(n)&&g(n,{force:!0}),T(r,n),S(n,493),n}async function C(r){return await new Promise((o,n)=>{let s=k("cmd",["/c","start",'""',"/wait",r],{stdio:"inherit"});s.once("error",n),s.once("exit",t=>{t===0?o():n(new Error(`installer exited with code ${t}`))})}),r}async function Y(r){(r.includes("--help")||r.includes("-h"))&&(console.log(`
4
4
  sootsim install-desktop \u2014 download and install the optional desktop GUI
5
5
 
@@ -20,4 +20,4 @@ examples:
20
20
  `),process.exit(0));let o=r.includes("--yes")||r.includes("-y")||process.env.SOOTSIM_NO_PROMPT==="1"||process.env.CI==="1"||!process.stdin.isTTY,n=r.includes("--force"),s=x();if(s&&!n){console.log(` sootsim desktop already installed at: ${s.path}`),console.log(" pass --force to reinstall.");return}let t=A();if(t||(console.error(` no desktop build available for ${process.platform}/${process.arch}.`),console.error(" supported: darwin-arm64, darwin-x64, linux-x64, win32-x64"),process.exit(1)),console.log(` platform: ${t.platform}`),console.log(` download: ${t.url}`),console.log(),!o){if(!await b("download and install now?",!0)){console.log(" cancelled.");return}console.log()}let a=f(D(),`sootsim-install-${Date.now()}`),i=f(a,t.filename),d=0;process.stdout.write(` downloading ${t.filename}...
21
21
  `);try{await O({url:t.url,dest:i,onProgress:(e,m)=>{let $=Date.now();$-d<100&&e<(m??1/0)||(d=$,process.stdout.isTTY&&process.stdout.write(`\r\x1B[2K${I(e,m)}`))}})}catch(e){g(a,{recursive:!0,force:!0}),console.error(`
22
22
  download failed: ${e instanceof Error?e.message:String(e)}`),process.exit(1)}process.stdout.isTTY&&process.stdout.write(`
23
- `);let c=P(i).size;console.log(` downloaded ${(c/(1024*1024)).toFixed(1)} MB`),console.log(),console.log(" installing...");let{trackCliEvent:l,flushCliTelemetry:p}=await import("./telemetry-U3BBVPLJ.js");try{let e=await t.install(i);l({event:"cli_install_desktop_succeeded",properties:{platform:t.platform,size_bytes:c}}),console.log(` installed: ${e}`)}catch(e){l({event:"cli_install_desktop_failed",properties:{platform:t.platform,error:e instanceof Error?e.message:String(e)}}),await p(),console.error(` install failed: ${e instanceof Error?e.message:String(e)}`),console.error(` keeping download at ${i} for manual install.`),process.exit(1)}finally{g(a,{recursive:!0,force:!0})}console.log(),console.log(" next steps:"),console.log(" sootsim electron launch the desktop app"),console.log(" sootsim open <target> open a demo or bundle in it")}export{Y as runInstallDesktop};
23
+ `);let c=P(i).size;console.log(` downloaded ${(c/(1024*1024)).toFixed(1)} MB`),console.log(),console.log(" installing...");let{trackCliEvent:l,flushCliTelemetry:p}=await import("./telemetry-WIIZXAXV.js");try{let e=await t.install(i);l({event:"cli_install_desktop_succeeded",properties:{platform:t.platform,size_bytes:c}}),console.log(` installed: ${e}`)}catch(e){l({event:"cli_install_desktop_failed",properties:{platform:t.platform,error:e instanceof Error?e.message:String(e)}}),await p(),console.error(` install failed: ${e instanceof Error?e.message:String(e)}`),console.error(` keeping download at ${i} for manual install.`),process.exit(1)}finally{g(a,{recursive:!0,force:!0})}console.log(),console.log(" next steps:"),console.log(" sootsim electron launch the desktop app"),console.log(" sootsim open <target> open a demo or bundle in it")}export{Y as runInstallDesktop};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as l,b as d,c as k,d as y,e as g}from"./chunk-Z6BCORBY.js";import{d as c}from"./chunk-E7FCGYB5.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";async function a(){let s=await c();return s?.token||(process.stderr.write(" sootsim keys ... needs you to be signed in.\n run `sootsim login` first.\n"),process.exit(1)),{origin:s.origin,token:s.token}}function f(s){if(!s)return"never";try{return new Date(s).toLocaleString()}catch{return s}}async function h(s){let i=s[0];if(!i||i==="--help"||i==="-h"){u();return}if(i==="list"){let{origin:o,token:e}=await a(),n=await fetch(`${o.replace(/\/$/,"")}/api/sootsim/billing/keys`,{headers:{authorization:`Bearer ${e}`}});n.ok||(console.error(` keys list failed (${n.status})`),process.exit(1));let{keys:r}=await n.json();if(r.length===0){console.log(" no keys. create one with `sootsim keys create <label>`.");return}for(let t of r)console.log(` ${t.keyPrefix}\u2026 ${t.label.padEnd(24)} scopes=${t.scopes.join(",")} last=${f(t.lastUsedAt)} id=${t.id}`);return}if(i==="create"){let o=s[1]?.trim();o||(console.error(" usage: sootsim keys create <label>"),process.exit(1));let{origin:e,token:n}=await a(),r=await fetch(`${e.replace(/\/$/,"")}/api/sootsim/billing/keys`,{method:"POST",headers:{authorization:`Bearer ${n}`,"content-type":"application/json"},body:JSON.stringify({label:o})});r.ok||(console.error(` keys create failed (${r.status}): ${await r.text()}`),process.exit(1));let t=await r.json();console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as l,b as d,c as k,d as y,e as g}from"./chunk-E3N4FEFL.js";import{d as c}from"./chunk-CHPJTXQY.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";async function a(){let s=await c();return s?.token||(process.stderr.write(" sootsim keys ... needs you to be signed in.\n run `sootsim login` first.\n"),process.exit(1)),{origin:s.origin,token:s.token}}function f(s){if(!s)return"never";try{return new Date(s).toLocaleString()}catch{return s}}async function h(s){let i=s[0];if(!i||i==="--help"||i==="-h"){u();return}if(i==="list"){let{origin:o,token:e}=await a(),n=await fetch(`${o.replace(/\/$/,"")}/api/sootsim/billing/keys`,{headers:{authorization:`Bearer ${e}`}});n.ok||(console.error(` keys list failed (${n.status})`),process.exit(1));let{keys:r}=await n.json();if(r.length===0){console.log(" no keys. create one with `sootsim keys create <label>`.");return}for(let t of r)console.log(` ${t.keyPrefix}\u2026 ${t.label.padEnd(24)} scopes=${t.scopes.join(",")} last=${f(t.lastUsedAt)} id=${t.id}`);return}if(i==="create"){let o=s[1]?.trim();o||(console.error(" usage: sootsim keys create <label>"),process.exit(1));let{origin:e,token:n}=await a(),r=await fetch(`${e.replace(/\/$/,"")}/api/sootsim/billing/keys`,{method:"POST",headers:{authorization:`Bearer ${n}`,"content-type":"application/json"},body:JSON.stringify({label:o})});r.ok||(console.error(` keys create failed (${r.status}): ${await r.text()}`),process.exit(1));let t=await r.json();console.log(`
3
3
  created: ${t.record.label} (${t.record.keyPrefix}\u2026)`),console.log(` scopes: ${t.record.scopes.join(",")}`),console.log(`
4
4
  secret: ${t.secret}
5
5
  `),console.log(` copy this now \u2014 we can't show it again.
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-CMEWLMED.js";import{b as m}from"./chunk-72Y42WVX.js";import{a as u}from"./chunk-3NNUNABL.js";import"./chunk-FITG7BVA.js";import"./chunk-C3R25CWY.js";import"./chunk-K6N6DEL5.js";import{D as c,E as r,F as l,y as s,z as a}from"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{spawn as p}from"child_process";import{existsSync as h}from"fs";async function I(n){if(n.includes("--help")||n.includes("-h")){console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-U47V7ETP.js";import{b as m}from"./chunk-WMXSRYIL.js";import{a as u}from"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import{D as c,E as r,F as l,y as s,z as a}from"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{spawn as p}from"child_process";import{existsSync as h}from"fs";async function I(n){if(n.includes("--help")||n.includes("-h")){console.log(`
3
3
  sootsim launch \u2014 one-shot: install runtime if needed, start daemon, open app
4
4
 
5
5
  usage:
@@ -13,4 +13,4 @@ options:
13
13
  examples:
14
14
  sootsim launch
15
15
  sootsim launch --version 1.2.3
16
- `);return}let e=n.includes("--no-runtime-install"),i=n.indexOf("--channel"),t=i>=0&&n[i+1]?n[i+1]:"stable",o=n.indexOf("--version"),f=o>=0&&n[o+1]?n[o+1]:void 0;s(),await v({skipAutoInstall:e,channel:t,explicitVersion:f}),await d(),await x()}async function v(n){let e=a(),i=c();if(e&&i)return;n.skipAutoInstall&&(console.error(" no sootsim runtime installed. run `sootsim runtime install` first, or drop --no-runtime-install."),process.exit(1)),console.log("sootsim: first run \u2014 installing runtime");let{runRuntime:t}=await import("./runtime-P54OGI57.js"),o=[];n.explicitVersion&&o.push(n.explicitVersion),n.channel!=="stable"&&o.push("--channel",n.channel),await t(["install",...o],{channel:n.channel})}async function d(){let n=r();if(l(n))return;console.log("sootsim: starting daemon");let e=w();p(e,["server","--quiet"],{detached:!0,stdio:"ignore",env:process.env}).unref();let t=Date.now()+8e3;for(;Date.now()<t;){let o=r();if(l(o))return;await g(150)}console.error(" daemon didn't become ready within 8s \u2014 check ~/.sootsim/ or run `sootsim server` in a terminal to see errors"),process.exit(1)}async function x(){u()||(console.error(" no sootsim desktop companion installed. run `sootsim install-desktop` to download electron + the shell."),process.exit(1));let e=await m.launch({});e.launched||(console.error(` ${e.message}`),process.exit(1)),console.log(` ${e.message}`)}function w(){let n=process.argv[1];return n&&h(n)?n:"sootsim"}function g(n){return new Promise(e=>setTimeout(e,n))}async function R(){s(),await d()}export{R as ensureDaemonRunning,I as runLaunch};
16
+ `);return}let e=n.includes("--no-runtime-install"),i=n.indexOf("--channel"),t=i>=0&&n[i+1]?n[i+1]:"stable",o=n.indexOf("--version"),f=o>=0&&n[o+1]?n[o+1]:void 0;s(),await v({skipAutoInstall:e,channel:t,explicitVersion:f}),await d(),await x()}async function v(n){let e=a(),i=c();if(e&&i)return;n.skipAutoInstall&&(console.error(" no sootsim runtime installed. run `sootsim runtime install` first, or drop --no-runtime-install."),process.exit(1)),console.log("sootsim: first run \u2014 installing runtime");let{runRuntime:t}=await import("./runtime-RXJSCIY3.js"),o=[];n.explicitVersion&&o.push(n.explicitVersion),n.channel!=="stable"&&o.push("--channel",n.channel),await t(["install",...o],{channel:n.channel})}async function d(){let n=r();if(l(n))return;console.log("sootsim: starting daemon");let e=w();p(e,["server","--quiet"],{detached:!0,stdio:"ignore",env:process.env}).unref();let t=Date.now()+8e3;for(;Date.now()<t;){let o=r();if(l(o))return;await g(150)}console.error(" daemon didn't become ready within 8s \u2014 check ~/.sootsim/ or run `sootsim server` in a terminal to see errors"),process.exit(1)}async function x(){u()||(console.error(" no sootsim desktop companion installed. run `sootsim install-desktop` to download electron + the shell."),process.exit(1));let e=await m.launch({});e.launched||(console.error(` ${e.message}`),process.exit(1)),console.log(` ${e.message}`)}function w(){let n=process.argv[1];return n&&h(n)?n:"sootsim"}function g(n){return new Promise(e=>setTimeout(e,n))}async function R(){s(),await d()}export{R as ensureDaemonRunning,I as runLaunch};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as f,d as m}from"./chunk-E7FCGYB5.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{exec as S}from"node:child_process";import{randomBytes as $}from"node:crypto";import _ from"node:http";var I=process.env.SOOTSIM_AUTH_ORIGIN||"https://sootbean.com",h="http://localhost:3000";async function x(t){if(t)return t;if(process.env.SOOTSIM_AUTH_ORIGIN)return process.env.SOOTSIM_AUTH_ORIGIN;if(process.env.SOOTSIM_UPLOAD_ORIGIN)return process.env.SOOTSIM_UPLOAD_ORIGIN;try{if((await fetch(`${h}/api/auth/me`)).ok)return h}catch{}return I}function R(){console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as f,d as m}from"./chunk-CHPJTXQY.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{exec as S}from"node:child_process";import{randomBytes as $}from"node:crypto";import _ from"node:http";var I=process.env.SOOTSIM_AUTH_ORIGIN||"https://sootbean.com",h="http://localhost:3000";async function x(t){if(t)return t;if(process.env.SOOTSIM_AUTH_ORIGIN)return process.env.SOOTSIM_AUTH_ORIGIN;if(process.env.SOOTSIM_UPLOAD_ORIGIN)return process.env.SOOTSIM_UPLOAD_ORIGIN;try{if((await fetch(`${h}/api/auth/me`)).ok)return h}catch{}return I}function R(){console.log(`
3
3
  sootsim login \u2014 sign in so desktop uploads can attach to your account
4
4
 
5
5
  usage:
@@ -21,6 +21,6 @@ options:
21
21
  <p style="color:#ccc">${t}</p>
22
22
  </div>
23
23
  </body>
24
- </html>`}async function P(t){try{let o=await fetch(`${t.replace(/\/$/,"")}/api/dev-login`,{method:"POST"});if(o.status===403)return{ok:!1,error:"dev-login disabled (not in dev mode)"};if(!o.ok){let c=await o.text().catch(()=>"");return{ok:!1,error:`dev-login ${o.status}: ${c}`}}let e=await o.json();return e.token?{ok:!0,token:e.token,userId:e.user?.id,email:e.email}:{ok:!1,error:"dev-login response missing token"}}catch(o){return{ok:!1,error:o instanceof Error?o.message:"dev-login fetch failed"}}}function A(t){try{let o=new URL(t).hostname;return o==="localhost"||o==="127.0.0.1"||o.endsWith(".local")}catch{return!1}}async function G(t){(t.includes("--help")||t.includes("-h"))&&(R(),process.exit(0));let o=[...t],e=await x(T(o,"--origin"));if(A(e)){console.log(` detected local origin (${e}) \u2014 signing in as dev user`);let r=await P(e);if(r.ok){f({token:r.token,user:r.userId?{id:r.userId,email:r.email}:null,origin:e,source:"cli"});let s=await m(e),l=s?.user?.email||r.email||s?.user?.id||r.userId,{trackCliEvent:n,flushCliTelemetry:a}=await import("./telemetry-U3BBVPLJ.js");n({event:"cli_login_succeeded",identity:{userId:r.userId??s?.user?.id??null},properties:{origin:e,mode:"dev"}}),await a(),console.log(` signed in${l?` as ${l}`:""} (dev)`);return}console.log(` dev-login not available (${r.error}); falling back to browser`)}let c=$(16).toString("hex"),i=await new Promise(r=>{let s=_.createServer((l,n)=>{try{let a=new URL(l.url||"/","http://127.0.0.1"),w=a.searchParams.get("state"),k=a.searchParams.get("token"),b=a.searchParams.get("email")||void 0,O=a.searchParams.get("userId")||void 0,g=a.searchParams.get("error");if(n.setHeader("content-type","text/html; charset=utf-8"),g){n.end(u(`sign-in failed: ${g}`)),r({ok:!1,error:g}),s.close();return}if(w!==c){n.end(u("state mismatch. close this tab and retry `sootsim login`.")),r({ok:!1,error:"state mismatch"}),s.close();return}if(!k){n.end(u("missing token. close this tab and retry `sootsim login`.")),r({ok:!1,error:"missing token"}),s.close();return}n.end(u("sign-in complete. you can return to the terminal.")),r({ok:!0,token:k,email:b,userId:O}),s.close()}catch(a){n.statusCode=500,n.end(u("sign-in callback failed. retry `sootsim login`.")),r({ok:!1,error:a instanceof Error?a.message:"callback failed"}),s.close()}});s.listen(0,"127.0.0.1",()=>{let l=s.address();if(!l||typeof l=="string"){r({ok:!1,error:"failed to bind callback server"}),s.close();return}let n=new URL(`${e.replace(/\/$/,"")}/auth/sootsim-cli`);n.searchParams.set("state",c),n.searchParams.set("port",String(l.port)),n.searchParams.set("sootbean",e),console.log(" opening browser for sootsim login..."),console.log(` waiting for callback on 127.0.0.1:${l.port}`),console.log(` if nothing opens, visit:
24
+ </html>`}async function P(t){try{let o=await fetch(`${t.replace(/\/$/,"")}/api/dev-login`,{method:"POST"});if(o.status===403)return{ok:!1,error:"dev-login disabled (not in dev mode)"};if(!o.ok){let c=await o.text().catch(()=>"");return{ok:!1,error:`dev-login ${o.status}: ${c}`}}let e=await o.json();return e.token?{ok:!0,token:e.token,userId:e.user?.id,email:e.email}:{ok:!1,error:"dev-login response missing token"}}catch(o){return{ok:!1,error:o instanceof Error?o.message:"dev-login fetch failed"}}}function A(t){try{let o=new URL(t).hostname;return o==="localhost"||o==="127.0.0.1"||o.endsWith(".local")}catch{return!1}}async function G(t){(t.includes("--help")||t.includes("-h"))&&(R(),process.exit(0));let o=[...t],e=await x(T(o,"--origin"));if(A(e)){console.log(` detected local origin (${e}) \u2014 signing in as dev user`);let r=await P(e);if(r.ok){f({token:r.token,user:r.userId?{id:r.userId,email:r.email}:null,origin:e,source:"cli"});let s=await m(e),l=s?.user?.email||r.email||s?.user?.id||r.userId,{trackCliEvent:n,flushCliTelemetry:a}=await import("./telemetry-WIIZXAXV.js");n({event:"cli_login_succeeded",identity:{userId:r.userId??s?.user?.id??null},properties:{origin:e,mode:"dev"}}),await a(),console.log(` signed in${l?` as ${l}`:""} (dev)`);return}console.log(` dev-login not available (${r.error}); falling back to browser`)}let c=$(16).toString("hex"),i=await new Promise(r=>{let s=_.createServer((l,n)=>{try{let a=new URL(l.url||"/","http://127.0.0.1"),w=a.searchParams.get("state"),k=a.searchParams.get("token"),b=a.searchParams.get("email")||void 0,O=a.searchParams.get("userId")||void 0,g=a.searchParams.get("error");if(n.setHeader("content-type","text/html; charset=utf-8"),g){n.end(u(`sign-in failed: ${g}`)),r({ok:!1,error:g}),s.close();return}if(w!==c){n.end(u("state mismatch. close this tab and retry `sootsim login`.")),r({ok:!1,error:"state mismatch"}),s.close();return}if(!k){n.end(u("missing token. close this tab and retry `sootsim login`.")),r({ok:!1,error:"missing token"}),s.close();return}n.end(u("sign-in complete. you can return to the terminal.")),r({ok:!0,token:k,email:b,userId:O}),s.close()}catch(a){n.statusCode=500,n.end(u("sign-in callback failed. retry `sootsim login`.")),r({ok:!1,error:a instanceof Error?a.message:"callback failed"}),s.close()}});s.listen(0,"127.0.0.1",()=>{let l=s.address();if(!l||typeof l=="string"){r({ok:!1,error:"failed to bind callback server"}),s.close();return}let n=new URL(`${e.replace(/\/$/,"")}/auth/sootsim-cli`);n.searchParams.set("state",c),n.searchParams.set("port",String(l.port)),n.searchParams.set("sootbean",e),console.log(" opening browser for sootsim login..."),console.log(` waiting for callback on 127.0.0.1:${l.port}`),console.log(` if nothing opens, visit:
25
25
  ${n.toString()}
26
- `),L(n.toString())})});if(!i.ok){let{trackCliEvent:r,flushCliTelemetry:s}=await import("./telemetry-U3BBVPLJ.js");r({event:"cli_login_failed",properties:{origin:e,error:i.error}}),await s(),console.error(` login failed: ${i.error}`),process.exit(1)}f({token:i.token,user:i.userId?{id:i.userId,email:i.email}:null,origin:e,source:"cli"});let d=await m(e),p=d?.user?.email||i.email||d?.user?.id||i.userId,{trackCliEvent:y,flushCliTelemetry:v}=await import("./telemetry-U3BBVPLJ.js");y({event:"cli_login_succeeded",identity:{userId:i.userId??d?.user?.id??null},properties:{origin:e}}),await v(),console.log(` signed in${p?` as ${p}`:""}`)}export{G as runLogin};
26
+ `),L(n.toString())})});if(!i.ok){let{trackCliEvent:r,flushCliTelemetry:s}=await import("./telemetry-WIIZXAXV.js");r({event:"cli_login_failed",properties:{origin:e,error:i.error}}),await s(),console.error(` login failed: ${i.error}`),process.exit(1)}f({token:i.token,user:i.userId?{id:i.userId,email:i.email}:null,origin:e,source:"cli"});let d=await m(e),p=d?.user?.email||i.email||d?.user?.id||i.userId,{trackCliEvent:y,flushCliTelemetry:v}=await import("./telemetry-WIIZXAXV.js");y({event:"cli_login_succeeded",identity:{userId:i.userId??d?.user?.id??null},properties:{origin:e}}),await v(),console.log(` signed in${p?` as ${p}`:""}`)}export{G as runLogin};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as r,b as i}from"./chunk-FBO7YRJM.js";import{a as t,c as o}from"./chunk-E7FCGYB5.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";async function s(){let e=t();if(!e?.token){console.log(" not signed in");return}try{await fetch(`${e.origin.replace(/\/$/,"")}/api/auth/sign-out`,{method:"POST",headers:{authorization:`Bearer ${e.token}`}})}catch{}o(),r({event:"cli_logout",identity:{userId:e.user?.id??null},properties:{origin:e.origin}}),await i(),console.log(" signed out")}export{s as runLogout};
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as r,b as i}from"./chunk-TGOEMAHH.js";import{a as t,c as o}from"./chunk-CHPJTXQY.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";async function s(){let e=t();if(!e?.token){console.log(" not signed in");return}try{await fetch(`${e.origin.replace(/\/$/,"")}/api/auth/sign-out`,{method:"POST",headers:{authorization:`Bearer ${e.token}`}})}catch{}o(),r({event:"cli_logout",identity:{userId:e.user?.id??null},properties:{origin:e.origin}}),await i(),console.log(" signed out")}export{s as runLogout};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as h,c as w}from"./chunk-H6YUT7HX.js";import"./chunk-TKDMCYGS.js";import"./chunk-HPFXTPOD.js";import"./chunk-BQLKO6NP.js";import"./chunk-2NFRZQ3K.js";import"./chunk-Z6BCORBY.js";import"./chunk-2HVRBEOU.js";import"./chunk-D5LXWWGN.js";import"./chunk-WIW3G6HS.js";import"./chunk-GFXFPPNR.js";import"./chunk-J7XCQWQI.js";import"./chunk-TY5CBM3C.js";import"./chunk-72Y42WVX.js";import"./chunk-3NNUNABL.js";import"./chunk-FITG7BVA.js";import"./chunk-C3R25CWY.js";import"./chunk-K6N6DEL5.js";import"./chunk-ZP7YYRHI.js";import"./chunk-6TQ2IBH6.js";import"./chunk-FBO7YRJM.js";import"./chunk-E7FCGYB5.js";import"./chunk-5QUYJKLU.js";import"./chunk-6JGI2JVM.js";import"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import*as i from"fs";import*as l from"path";var v=[".maestro","maestro"];function x(){console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as h,c as w}from"./chunk-TPSFEKYW.js";import"./chunk-DJJXNSM3.js";import"./chunk-DKA5PC22.js";import"./chunk-QMDKGPM2.js";import"./chunk-WV24QU4A.js";import"./chunk-E3N4FEFL.js";import"./chunk-CF3ZE5OG.js";import"./chunk-LLKII2H3.js";import"./chunk-S2JBGZV2.js";import"./chunk-DSF4GC3A.js";import"./chunk-W3HQJ54T.js";import"./chunk-J4B6F25M.js";import"./chunk-WMXSRYIL.js";import"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import"./chunk-6URW4GMA.js";import"./chunk-FIBZZOZX.js";import"./chunk-TGOEMAHH.js";import"./chunk-CHPJTXQY.js";import"./chunk-ODAH77AZ.js";import"./chunk-G26C77XT.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import*as i from"fs";import*as l from"path";var v=[".maestro","maestro"];function x(){console.log(`
3
3
  sootsim maestro \u2014 run maestro YAML flows against sootsim (drop-in)
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-HC43PTFD.js";import{resolve as c,dirname as m}from"path";import{fileURLToPath as a}from"url";var t=m(a(import.meta.resolve("sootsim-engine/package.json")));async function g(o,r){(o.includes("--help")||o.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-PF3AVL5U.js";import{resolve as c,dirname as m}from"path";import{fileURLToPath as a}from"url";var t=m(a(import.meta.resolve("sootsim-engine/package.json")));async function g(o,r){(o.includes("--help")||o.includes("-h"))&&(console.log(`
3
3
  sootsim preview \u2014 production-like preview
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as s,c as i,d as t,e as n,f as c}from"./chunk-C3R25CWY.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";function f(){console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as s,c as i,d as t,e as n,f as c}from"./chunk-YOY373LJ.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";function f(){console.log(`
3
3
  sootsim profile \u2014 manage isolated storage profiles
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{c as w,e as b,h as m,i as f}from"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";function h(){console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{c as w,e as b,h as m,i as f}from"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";function h(){console.log(`
3
3
  sootsim react \u2014 inspect React component render cost in the tenant worker
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as P}from"./chunk-BQLKO6NP.js";import"./chunk-2NFRZQ3K.js";import{d as Y}from"./chunk-Z6BCORBY.js";import"./chunk-FITG7BVA.js";import{d as K}from"./chunk-K6N6DEL5.js";import"./chunk-FBO7YRJM.js";import"./chunk-E7FCGYB5.js";import{c as h,e as b,f as Q}from"./chunk-5LDGAVAV.js";import{b as X}from"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{existsSync as fe,mkdirSync as O,readdirSync as pe,readFileSync as ge,rmSync as z,writeFileSync as U}from"fs";import{homedir as we,tmpdir as he}from"os";import{dirname as W,extname as ee,join as C,resolve as be}from"path";var Z=24e4,ve=3e4;async function N(e,r,o,i){let t=Math.max(2e4,i+ve);try{return await e.send({type:"evaluate",code:r},{timeoutMs:t})}catch(n){let s=n instanceof Error?n.message:String(n);/^command timed out after \d+s$/.test(s)&&(console.error(` ${o} stalled \u2014 the render host did not finish within ${Math.round(t/1e3)}s; it is likely contended or wedged.
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as P}from"./chunk-QMDKGPM2.js";import"./chunk-WV24QU4A.js";import{d as Y}from"./chunk-E3N4FEFL.js";import"./chunk-JXRFI3TK.js";import{d as K}from"./chunk-BKRVAP2K.js";import"./chunk-TGOEMAHH.js";import"./chunk-CHPJTXQY.js";import{c as h,e as b,f as Q}from"./chunk-6HWKKBZ4.js";import{b as X}from"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{existsSync as fe,mkdirSync as O,readdirSync as pe,readFileSync as ge,rmSync as z,writeFileSync as U}from"fs";import{homedir as we,tmpdir as he}from"os";import{dirname as W,extname as ee,join as C,resolve as be}from"path";var Z=24e4,ve=3e4;async function N(e,r,o,i){let t=Math.max(2e4,i+ve);try{return await e.send({type:"evaluate",code:r},{timeoutMs:t})}catch(n){let s=n instanceof Error?n.message:String(n);/^command timed out after \d+s$/.test(s)&&(console.error(` ${o} stalled \u2014 the render host did not finish within ${Math.round(t/1e3)}s; it is likely contended or wedged.
3
3
  the capture lock auto-releases, so simply retry the recording.
4
4
  if it persists, recover the sim with \`sootsim close --sim <id>\`.`),process.exit(1)),/render host not available|already streaming|already recording/i.test(s)&&(console.error(` ${o} failed: ${s}
5
5
  a prior recording was abandoned and its capture is still
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a}from"./chunk-WAKMUKQJ.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-FLYYVMVE.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";export{a as runRuntime};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a,b,c,d,e,f,g,h,i,j,k,l}from"./chunk-OFTI3N27.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";export{a as DEFAULT_RUNTIME_CDN_ORIGIN,b as RUNTIME_CDN_ORIGIN_ENV,c as RUNTIME_CHANNEL_ENV,l as checkRuntimeUpToDate,h as fetchRuntimeManifest,j as installRuntime,d as resolveRuntimeCdnOrigin,e as resolveRuntimeChannel,i as resolveRuntimeVersion,f as runtimeManifestUrl,g as runtimeTarballUrl,k as updateRuntimeToLatest};
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a,b,c,d,e,f,g,h,i,j,k,l}from"./chunk-FLYYVMVE.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";export{a as DEFAULT_RUNTIME_CDN_ORIGIN,b as RUNTIME_CDN_ORIGIN_ENV,c as RUNTIME_CHANNEL_ENV,l as checkRuntimeUpToDate,h as fetchRuntimeManifest,j as installRuntime,d as resolveRuntimeCdnOrigin,e as resolveRuntimeChannel,i as resolveRuntimeVersion,f as runtimeManifestUrl,g as runtimeTarballUrl,k as updateRuntimeToLatest};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as R}from"./chunk-TKDMCYGS.js";import"./chunk-HPFXTPOD.js";import{a as b}from"./chunk-TZYXNQHA.js";import"./chunk-ZP7YYRHI.js";import"./chunk-5QUYJKLU.js";import{f as g}from"./chunk-6JGI2JVM.js";import{c as w,d as y,e as x,f as v,h as S}from"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{mkdirSync as $,writeFileSync as _}from"fs";import{dirname as A,resolve as B}from"path";async function z(e,o){(e.includes("--help")||e.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as R}from"./chunk-DJJXNSM3.js";import"./chunk-DKA5PC22.js";import{a as b}from"./chunk-SPHONVYN.js";import"./chunk-6URW4GMA.js";import"./chunk-ODAH77AZ.js";import{f as g}from"./chunk-G26C77XT.js";import{c as w,d as y,e as v,f as x,h as S}from"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{mkdirSync as $,writeFileSync as _}from"fs";import{dirname as A,resolve as B}from"path";async function z(e,o){(e.includes("--help")||e.includes("-h"))&&(console.log(`
3
3
  sootsim screenshot \u2014 capture the canvas as a PNG
4
4
 
5
5
  usage:
@@ -11,8 +11,9 @@ options:
11
11
  first positional arg works too: \`screenshot /tmp/x.png\`
12
12
  --with-frame wrap the captured screen in a tight device frame
13
13
  --no-frame capture the raw screen bitmap (default)
14
- --no-shell exclude the simulated iOS chrome (status bar, keyboard,
15
- toasts) \u2014 captures the tenant surfaces only
14
+ --no-shell tenant-only capture (no status bar, keyboard, toasts,
15
+ notification center, or other shell overlays). use for
16
+ clean app screenshots when a shell surface is in the way.
16
17
  --shell-only capture only the shell chrome, no tenant content
17
18
  --area x,y,w,h crop to a logical sootsim rect
18
19
  --id <testID> crop to a node's bounding box
@@ -22,12 +23,13 @@ options:
22
23
 
23
24
  examples:
24
25
  sootsim screenshot
26
+ sootsim screenshot --no-shell --output app.png
25
27
  sootsim screenshot --with-frame --output framed.png
26
28
  sootsim screenshot --area 0,200,393,400 --output hero.png
27
29
  sootsim screenshot --id loginButton --output button.png
28
- `),process.exit(0));let t=U(e);if(t.length>0){for(let{flag:l,suggestion:h}of t)console.error(h?` unknown flag: ${l} (did you mean ${h}?)`:` unknown flag: ${l}`);console.error(" run `sootsim screenshot --help` for the list of supported flags"),process.exit(1)}let r=e.includes("--gallery"),i=e.includes("--themes"),n=N(e),u=D(e);if(r||i)return n&&(console.error(" --with-frame is not supported with --gallery / --themes"),process.exit(1)),E(e,o);n&&e.some(l=>l==="--area"||l==="--id"||l==="--text")&&(console.error(" --with-frame only supports full-screen capture for now"),console.error(" remove --area / --id / --text, or capture raw and compose later"),process.exit(1));let s=w(e,{port:o.port,stripBooleanFlags:["--with-frame","--no-frame","--no-shell","--shell-only"],stripValueFlags:["--output","--area","--id","--text"]}),a=T(e),c=await P(e);if(await O(s.wsPort)){try{await M(s,a,c,n,u)}catch(l){console.error(` screenshot failed: ${l instanceof Error?l.message:String(l)}`),process.exit(1)}return}n&&(console.error(" --with-frame requires a running sootsim bridge"),console.error(" open the app in a live sim first, then rerun the command"),process.exit(1)),c&&(console.error(" --area / --id / --text require a running sootsim bridge"),console.error(" start one with `sootsim server`, `sootsim electron`, or your project dev server"),process.exit(1)),await E(e,o)}async function O(e){let o=y(e,{commandTimeoutMs:1e3});try{return await o.listSims(),!0}catch{return!1}finally{o.close()}}async function P(e){let o=e.find((i,n)=>e[n-1]==="--area");if(o){let i=o.split(",").map(c=>Number(c.trim()));if(i.length!==4||i.some(c=>!Number.isFinite(c)))throw new Error(`--area expects x,y,w,h (got "${o}")`);let[n,u,s,a]=i;return{x:n,y:u,w:s,h:a}}let t=e.find((i,n)=>e[n-1]==="--id"),r=e.find((i,n)=>e[n-1]==="--text");return t||r?{__matcher:{id:t,text:r}}:null}async function M(e,o,t,r,i){let n=x({...e,commandTimeoutMs:1e4});try{(await v(n)).hidden&&process.stderr.write(` \u26A0 screenshot will capture the LAST PAINTED canvas \u2014 likely stale.
30
+ `),process.exit(0));let t=U(e);if(t.length>0){for(let{flag:c,suggestion:h}of t)console.error(h?` unknown flag: ${c} (did you mean ${h}?)`:` unknown flag: ${c}`);console.error(" run `sootsim screenshot --help` for the list of supported flags"),process.exit(1)}let n=e.includes("--gallery"),i=e.includes("--themes"),r=N(e),u=D(e);if(n||i)return r&&(console.error(" --with-frame is not supported with --gallery / --themes"),process.exit(1)),E(e,o);r&&e.some(c=>c==="--area"||c==="--id"||c==="--text")&&(console.error(" --with-frame only supports full-screen capture for now"),console.error(" remove --area / --id / --text, or capture raw and compose later"),process.exit(1));let s=w(e,{port:o.port,stripBooleanFlags:["--with-frame","--no-frame","--no-shell","--shell-only"],stripValueFlags:["--output","--area","--id","--text"]}),a=T(e),l=await O(e);if(await P(s.wsPort)){try{await M(s,a,l,r,u)}catch(c){console.error(` screenshot failed: ${c instanceof Error?c.message:String(c)}`),process.exit(1)}return}r&&(console.error(" --with-frame requires a running sootsim bridge"),console.error(" open the app in a live sim first, then rerun the command"),process.exit(1)),l&&(console.error(" --area / --id / --text require a running sootsim bridge"),console.error(" start one with `sootsim server`, `sootsim electron`, or your project dev server"),process.exit(1)),await E(e,o)}async function P(e){let o=y(e,{commandTimeoutMs:1e3});try{return await o.listSims(),!0}catch{return!1}finally{o.close()}}async function O(e){let o=e.find((i,r)=>e[r-1]==="--area");if(o){let i=o.split(",").map(l=>Number(l.trim()));if(i.length!==4||i.some(l=>!Number.isFinite(l)))throw new Error(`--area expects x,y,w,h (got "${o}")`);let[r,u,s,a]=i;return{x:r,y:u,w:s,h:a}}let t=e.find((i,r)=>e[r-1]==="--id"),n=e.find((i,r)=>e[r-1]==="--text");return t||n?{__matcher:{id:t,text:n}}:null}async function M(e,o,t,n,i){let r=v({...e,commandTimeoutMs:1e4});try{(await x(r)).hidden&&process.stderr.write(` \u26A0 screenshot will capture the LAST PAINTED canvas \u2014 likely stale.
29
31
  navigation/\`shell\` commands sent before this screenshot may not
30
32
  have repainted yet. focus the tab manually or \`sootsim --sim <id>\`
31
33
  to target a visible sim before capturing.
32
34
 
33
- `);let s=t,a=t?.__matcher;if(a){let d=await n.send({type:"evaluate",code:b(a)});if(!d)throw new Error(a.id?`no node with id "${a.id}"`:`no node matching text "${a.text}"`);s=d}let c=s?{x:s.x,y:s.y,w:s.w,h:s.h}:void 0,p={type:"screenshot"};i&&(p.layers=i),c&&(p.crop=c);let h=(await n.send(p)).replace(/^data:image\/png;base64,/,"");c&&console.log(` area: x=${c.x} y=${c.y} w=${c.w} h=${c.h}`),i&&console.log(` layers: ${i}`);let m=B(process.cwd(),o||"/tmp/sootsim-inspect.png");$(A(m),{recursive:!0});let f=Buffer.from(h,"base64");if(r){let d=await L(n);if(!d)throw new Error("could not read current device model from the target sim");let k=await R(f,d);_(m,k),console.log(` frame: ${d}`)}else _(m,f);console.log(` saved: ${m}`)}finally{n.close()}}async function L(e){let o=await S(e,"SootSim.bridges.settings.get")??{deviceModel:null},t=typeof o.deviceModel=="string"?o.deviceModel:null;return!t||!(t in g)?null:t}function N(e){let o=!1;for(let t of e)t==="--with-frame"&&(o=!0),t==="--no-frame"&&(o=!1);return o}function D(e){if(e.includes("--shell-only"))return"shell";if(e.includes("--no-shell"))return"tenant"}var C=new Set(["--help","-h","--verbose","-v","--with-frame","--no-frame","--no-shell","--shell-only","--gallery","--themes"]),F=new Set(["--output","--area","--id","--text","--url","--port","--timeout","--sim"]),G={"--rect":"--area","--crop":"--area","--region":"--area","--bounds":"--area","--box":"--area","--xywh":"--area","--out":"--output","-o":"--output","--file":"--output","--path":"--output","--testid":"--id","--test-id":"--id","--test_id":"--id"};function U(e){let o=[];for(let t=0;t<e.length;t++){let r=e[t];if(r.startsWith("-")){if(F.has(r)){t++;continue}C.has(r)||o.push({flag:r,suggestion:G[r]})}}return o}function T(e){let o=e.find((t,r)=>e[r-1]==="--output");if(o)return o;for(let t=0;t<e.length;t++){let r=e[t];if(r.startsWith("-")){F.has(r)&&t++;continue}return r}}async function E(e,o){let t=T(e)||"sootsim-screenshot.png",r=e.includes("--gallery"),i=e.find((s,a)=>e[a-1]==="--url")||`http://localhost:${o.port||5173}`,{chromium:n}=await import("playwright"),u=await n.launch({channel:"chrome",headless:!0});try{if(r)console.log(" capturing gallery..."),console.log(" (gallery mode not yet implemented)");else{let s=await u.newPage({viewport:{width:500,height:900}});await s.goto(i,{waitUntil:"networkidle"}),await s.waitForTimeout(2e3);let a=B(process.cwd(),t);$(A(a),{recursive:!0}),await s.screenshot({path:a}),console.log(` saved: ${a}`),await s.close()}}catch(s){console.error(` screenshot failed: ${s.message}`),process.exitCode=1}finally{await u.close()}}export{z as runScreenshot};
35
+ `);let s=t,a=t?.__matcher;if(a){let p=await r.send({type:"evaluate",code:b(a)});if(!p)throw new Error(a.id?`no node with id "${a.id}"`:`no node matching text "${a.text}"`);s=p}let l=s?{x:s.x,y:s.y,w:s.w,h:s.h}:void 0,d={type:"screenshot"};i&&(d.layers=i),l&&(d.crop=l);let h=(await r.send(d)).replace(/^data:image\/png;base64,/,"");l&&console.log(` area: x=${l.x} y=${l.y} w=${l.w} h=${l.h}`),i&&console.log(` layers: ${i}`);let f=B(process.cwd(),o||"/tmp/sootsim-inspect.png");$(A(f),{recursive:!0});let m=Buffer.from(h,"base64");if(n){let p=await L(r);if(!p)throw new Error("could not read current device model from the target sim");let k=await R(m,p);_(f,k),console.log(` frame: ${p}`)}else _(f,m);console.log(` saved: ${f}`)}finally{r.close()}}async function L(e){let o=await S(e,"SootSim.bridges.settings.get")??{deviceModel:null},t=typeof o.deviceModel=="string"?o.deviceModel:null;return!t||!(t in g)?null:t}function N(e){let o=!1;for(let t of e)t==="--with-frame"&&(o=!0),t==="--no-frame"&&(o=!1);return o}function D(e){if(e.includes("--shell-only"))return"shell";if(e.includes("--no-shell"))return"tenant"}var C=new Set(["--help","-h","--verbose","-v","--with-frame","--no-frame","--no-shell","--shell-only","--gallery","--themes"]),F=new Set(["--output","--area","--id","--text","--url","--port","--timeout","--sim"]),G={"--rect":"--area","--crop":"--area","--region":"--area","--bounds":"--area","--box":"--area","--xywh":"--area","--out":"--output","-o":"--output","--file":"--output","--path":"--output","--testid":"--id","--test-id":"--id","--test_id":"--id"};function U(e){let o=[];for(let t=0;t<e.length;t++){let n=e[t];if(n.startsWith("-")){if(F.has(n)){t++;continue}C.has(n)||o.push({flag:n,suggestion:G[n]})}}return o}function T(e){let o=e.find((t,n)=>e[n-1]==="--output");if(o)return o;for(let t=0;t<e.length;t++){let n=e[t];if(n.startsWith("-")){F.has(n)&&t++;continue}return n}}async function E(e,o){let t=T(e)||"sootsim-screenshot.png",n=e.includes("--gallery"),i=e.find((s,a)=>e[a-1]==="--url")||`http://localhost:${o.port||5173}`,{chromium:r}=await import("playwright"),u=await r.launch({channel:"chrome",headless:!0});try{if(n)console.log(" capturing gallery..."),console.log(" (gallery mode not yet implemented)");else{let s=await u.newPage({viewport:{width:500,height:900}});await s.goto(i,{waitUntil:"networkidle"}),await s.waitForTimeout(2e3);let a=B(process.cwd(),t);$(A(a),{recursive:!0}),await s.screenshot({path:a}),console.log(` saved: ${a}`),await s.close()}}catch(s){console.error(` screenshot failed: ${s.message}`),process.exitCode=1}finally{await u.close()}}export{z as runScreenshot};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as o}from"./chunk-3HF6BNSA.js";import"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";async function n(e,s){(e.includes("--help")||e.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as o}from"./chunk-QRZ6T5GY.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";async function n(e,s){(e.includes("--help")||e.includes("-h"))&&(console.log(`
3
3
  sootsim screenshot-mode \u2014 toggle the screenshot-mode chrome overlay
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.68 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as Y}from"./chunk-H6YUT7HX.js";import{b as j}from"./chunk-TKDMCYGS.js";import"./chunk-HPFXTPOD.js";import"./chunk-BQLKO6NP.js";import"./chunk-2NFRZQ3K.js";import"./chunk-Z6BCORBY.js";import{b as O}from"./chunk-2HVRBEOU.js";import"./chunk-D5LXWWGN.js";import"./chunk-WIW3G6HS.js";import"./chunk-GFXFPPNR.js";import"./chunk-J7XCQWQI.js";import"./chunk-TY5CBM3C.js";import"./chunk-72Y42WVX.js";import"./chunk-3NNUNABL.js";import"./chunk-FITG7BVA.js";import"./chunk-C3R25CWY.js";import"./chunk-K6N6DEL5.js";import"./chunk-ZP7YYRHI.js";import"./chunk-6TQ2IBH6.js";import"./chunk-FBO7YRJM.js";import"./chunk-E7FCGYB5.js";import"./chunk-5QUYJKLU.js";import{a as w,b as D,c as k,d as z,e as x,f as T}from"./chunk-6JGI2JVM.js";import"./chunk-5LDGAVAV.js";import"./chunk-6453CCSA.js";import"./chunk-CZWZG7GL.js";import"./chunk-G3WXMB3Z.js";import"./chunk-HC43PTFD.js";import{mkdirSync as B,readFileSync as pe,writeFileSync as G}from"fs";import{tmpdir as je}from"os";import C from"path";import{mkdirSync as I,readFileSync as Q,writeFileSync as H}from"fs";import F from"path";function _(e){return e.replace(/\\/g,"/").replace(/\.png$/i,"").trim().split("/").filter(Boolean).join("--").replace(/[^A-Za-z0-9-]+/g,"-").replace(/-+/g,"-").replace(/^-|-$/g,"")||"slide"}function v(e){return e.replaceAll("&","&amp;").replaceAll("<","&lt;").replaceAll(">","&gt;").replaceAll('"',"&quot;")}function ee(e){let t=e.trim();return/^#[0-9a-f]{3}$/i.test(t)?`#${t[1]}${t[1]}${t[2]}${t[2]}${t[3]}${t[3]}`:t}function M(e,t){let o=ee(e),i=Math.max(0,Math.min(1,t)),n=o.match(/^#([0-9a-f]{6})$/i);if(n){let s=n[1],r=Number.parseInt(s.slice(0,2),16),a=Number.parseInt(s.slice(2,4),16),u=Number.parseInt(s.slice(4,6),16);return`rgba(${r}, ${a}, ${u}, ${i})`}return o.startsWith("rgb(")?o.replace(/^rgb\((.+)\)$/i,`rgba($1, ${i})`):o}function te(e){if(e.type==="solid")return e.color||"#000000";let t=e.direction??180,o=e.stops?.map(i=>`${i.color} ${i.offset}%`).join(", ")||"#000000 0%, #111111 100%";return`linear-gradient(${t}deg, ${o})`}function re(e){let t=e.glow;return t?`radial-gradient(circle at 50% 24%, ${M(t,.46)} 0%, ${M(t,.2)} 24%, rgba(0,0,0,0) 62%)`:"none"}function A(e){switch(e){case"tilted-left":return"perspective(2400px) rotateY(10deg) rotateZ(-2deg)";case"tilted-right":return"perspective(2400px) rotateY(-10deg) rotateZ(2deg)";case"cut-bottom":return"translateY(10%) scale(1.08)";case"cut-top":return"translateY(-16%) scale(1.08)";default:return"none"}}function L(...e){let t=e.map(o=>o.trim()).filter(o=>o.length>0&&o!=="none");return t.length>0?t.join(" "):"none"}function E(e){let t=M(e.color,e.opacity),o=M(e.color,e.opacity*.52);return`drop-shadow(0 34px ${e.spread}px ${o}) drop-shadow(0 0 ${e.blur}px ${t})`}function R(e,t){return!t.glow||e.color&&e.color!==w.color?e:{...e,color:t.glow}}function oe(e,t){if(e==="editorial-left"){let n=Math.round(t.height*.056),s=Math.round(t.height*.022);return{copyStyle:["position:absolute",`top:${Math.round(t.height*.12)}px`,`left:${Math.round(t.width*.085)}px`,`width:${Math.round(t.width*.42)}px`,"text-align:left","z-index:3"].join(";"),titleStyle:`font-size:${n}px;line-height:0.92;`,subStyle:`font-size:${s}px;line-height:1.36;max-width:${Math.round(t.width*.36)}px;`,eyebrowStyle:"align-items:flex-start;",deviceStyle:(r,a,u)=>{let p=Math.round(t.width*.68*(a.scale??r.scale)),l=Math.round(t.height*(.03+r.offsetY+(a.offsetY??0))),c=a.pose||r.pose||"tilted-right",m=R(r.shadow,u);return["position:absolute",`top:${Math.round(t.height*.18)+l}px`,`left:${Math.round(t.width*.56)}px`,`width:${p}px`,"transform-origin:center center",`transform:${A(c)}`,`filter:${E(m)}`,"z-index:2"].join(";")}}}if(e==="minimal-bottom"){let n=Math.round(t.height*.041),s=Math.round(t.height*.019);return{copyStyle:["position:absolute",`left:${Math.round(t.width*.12)}px`,`right:${Math.round(t.width*.12)}px`,`bottom:${Math.round(t.height*.085)}px`,"text-align:center","z-index:3"].join(";"),titleStyle:`font-size:${n}px;line-height:0.96;`,subStyle:`font-size:${s}px;line-height:1.34;max-width:${Math.round(t.width*.56)}px;margin:0 auto;`,eyebrowStyle:"align-items:center;",deviceStyle:(r,a,u)=>{let p=Math.round(t.width*.84*(a.scale??r.scale)),l=Math.round(t.height*(r.offsetY+(a.offsetY??0))),c=a.pose||r.pose,m=R(r.shadow,u);return["position:absolute",`top:${Math.round(t.height*.075)+l}px`,"left:50%",`width:${p}px`,"transform-origin:center center",`transform:${L("translateX(-50%)",A(c))}`,`filter:${E(m)}`,"z-index:2"].join(";")}}}let o=Math.round(t.height*.04),i=Math.round(t.height*.019);return{copyStyle:["position:absolute",`top:${Math.round(t.height*.084)}px`,"left:50%",`width:${Math.round(t.width*.88)}px`,"transform:translateX(-50%)","text-align:center","z-index:3"].join(";"),titleStyle:`font-size:${o}px;line-height:0.92;`,subStyle:`font-size:${i}px;line-height:1.34;max-width:${Math.round(t.width*.6)}px;margin:0 auto;`,eyebrowStyle:"align-items:center;",deviceStyle:(n,s,r)=>{let a=t.name==="ipad-13"?.54:.64,u=Math.round(t.width*a*(s.scale??n.scale)),p=Math.round(t.height*(n.offsetY+(s.offsetY??0))),l=s.pose||n.pose,c=R(n.shadow,r);return["position:absolute",`top:${Math.round(t.height*(t.name==="ipad-13"?.25:.28))+p}px`,"left:50%",`width:${u}px`,"transform-origin:center top",`transform:${L("translateX(-50%)",A(l))}`,`filter:${E(c)}`,"z-index:2"].join(";")}}}function ne({canvas:e,compose:t,slide:o,imageDataUrl:i}){let n=o.background??t.background,s=oe(t.text.preset,e),r=t.text.preset!=="none"&&!!(o.eyebrow||o.headline||o.subheadline),a=s.deviceStyle(t.frame,o,n),u=o.headline?`<div style="font-weight:780;white-space:pre-line;text-wrap:balance;${s.titleStyle}">${v(o.headline)}</div>`:"",p=o.subheadline?`<div style="margin-top:${Math.round(e.height*.018)}px;color:${t.text.subColor};white-space:pre-line;text-wrap:balance;${s.subStyle}">${v(o.subheadline)}</div>`:"",l=o.eyebrow?`<div style="display:flex;${s.eyebrowStyle}margin-bottom:${Math.round(e.height*.016)}px;"><div style="font-size:${Math.round(e.height*.014)}px;font-weight:700;letter-spacing:0.18em;text-transform:uppercase;color:${t.text.eyebrowColor};">${v(o.eyebrow)}</div></div>`:"";return`<!doctype html>
1
+ /*! sootsim v0.1.70 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as Y}from"./chunk-TPSFEKYW.js";import{b as j}from"./chunk-DJJXNSM3.js";import"./chunk-DKA5PC22.js";import"./chunk-QMDKGPM2.js";import"./chunk-WV24QU4A.js";import"./chunk-E3N4FEFL.js";import{b as O}from"./chunk-CF3ZE5OG.js";import"./chunk-LLKII2H3.js";import"./chunk-S2JBGZV2.js";import"./chunk-DSF4GC3A.js";import"./chunk-W3HQJ54T.js";import"./chunk-J4B6F25M.js";import"./chunk-WMXSRYIL.js";import"./chunk-5MFLZW2Y.js";import"./chunk-JXRFI3TK.js";import"./chunk-YOY373LJ.js";import"./chunk-BKRVAP2K.js";import"./chunk-6URW4GMA.js";import"./chunk-FIBZZOZX.js";import"./chunk-TGOEMAHH.js";import"./chunk-CHPJTXQY.js";import"./chunk-ODAH77AZ.js";import{a as w,b as D,c as k,d as z,e as x,f as T}from"./chunk-G26C77XT.js";import"./chunk-6HWKKBZ4.js";import"./chunk-T52ORT6E.js";import"./chunk-GZ52IGD2.js";import"./chunk-772DATRO.js";import"./chunk-PF3AVL5U.js";import{mkdirSync as B,readFileSync as pe,writeFileSync as G}from"fs";import{tmpdir as je}from"os";import C from"path";import{mkdirSync as I,readFileSync as Q,writeFileSync as H}from"fs";import F from"path";function _(e){return e.replace(/\\/g,"/").replace(/\.png$/i,"").trim().split("/").filter(Boolean).join("--").replace(/[^A-Za-z0-9-]+/g,"-").replace(/-+/g,"-").replace(/^-|-$/g,"")||"slide"}function v(e){return e.replaceAll("&","&amp;").replaceAll("<","&lt;").replaceAll(">","&gt;").replaceAll('"',"&quot;")}function ee(e){let t=e.trim();return/^#[0-9a-f]{3}$/i.test(t)?`#${t[1]}${t[1]}${t[2]}${t[2]}${t[3]}${t[3]}`:t}function M(e,t){let o=ee(e),i=Math.max(0,Math.min(1,t)),n=o.match(/^#([0-9a-f]{6})$/i);if(n){let s=n[1],r=Number.parseInt(s.slice(0,2),16),a=Number.parseInt(s.slice(2,4),16),u=Number.parseInt(s.slice(4,6),16);return`rgba(${r}, ${a}, ${u}, ${i})`}return o.startsWith("rgb(")?o.replace(/^rgb\((.+)\)$/i,`rgba($1, ${i})`):o}function te(e){if(e.type==="solid")return e.color||"#000000";let t=e.direction??180,o=e.stops?.map(i=>`${i.color} ${i.offset}%`).join(", ")||"#000000 0%, #111111 100%";return`linear-gradient(${t}deg, ${o})`}function re(e){let t=e.glow;return t?`radial-gradient(circle at 50% 24%, ${M(t,.46)} 0%, ${M(t,.2)} 24%, rgba(0,0,0,0) 62%)`:"none"}function A(e){switch(e){case"tilted-left":return"perspective(2400px) rotateY(10deg) rotateZ(-2deg)";case"tilted-right":return"perspective(2400px) rotateY(-10deg) rotateZ(2deg)";case"cut-bottom":return"translateY(10%) scale(1.08)";case"cut-top":return"translateY(-16%) scale(1.08)";default:return"none"}}function L(...e){let t=e.map(o=>o.trim()).filter(o=>o.length>0&&o!=="none");return t.length>0?t.join(" "):"none"}function E(e){let t=M(e.color,e.opacity),o=M(e.color,e.opacity*.52);return`drop-shadow(0 34px ${e.spread}px ${o}) drop-shadow(0 0 ${e.blur}px ${t})`}function R(e,t){return!t.glow||e.color&&e.color!==w.color?e:{...e,color:t.glow}}function oe(e,t){if(e==="editorial-left"){let n=Math.round(t.height*.056),s=Math.round(t.height*.022);return{copyStyle:["position:absolute",`top:${Math.round(t.height*.12)}px`,`left:${Math.round(t.width*.085)}px`,`width:${Math.round(t.width*.42)}px`,"text-align:left","z-index:3"].join(";"),titleStyle:`font-size:${n}px;line-height:0.92;`,subStyle:`font-size:${s}px;line-height:1.36;max-width:${Math.round(t.width*.36)}px;`,eyebrowStyle:"align-items:flex-start;",deviceStyle:(r,a,u)=>{let p=Math.round(t.width*.68*(a.scale??r.scale)),l=Math.round(t.height*(.03+r.offsetY+(a.offsetY??0))),c=a.pose||r.pose||"tilted-right",m=R(r.shadow,u);return["position:absolute",`top:${Math.round(t.height*.18)+l}px`,`left:${Math.round(t.width*.56)}px`,`width:${p}px`,"transform-origin:center center",`transform:${A(c)}`,`filter:${E(m)}`,"z-index:2"].join(";")}}}if(e==="minimal-bottom"){let n=Math.round(t.height*.041),s=Math.round(t.height*.019);return{copyStyle:["position:absolute",`left:${Math.round(t.width*.12)}px`,`right:${Math.round(t.width*.12)}px`,`bottom:${Math.round(t.height*.085)}px`,"text-align:center","z-index:3"].join(";"),titleStyle:`font-size:${n}px;line-height:0.96;`,subStyle:`font-size:${s}px;line-height:1.34;max-width:${Math.round(t.width*.56)}px;margin:0 auto;`,eyebrowStyle:"align-items:center;",deviceStyle:(r,a,u)=>{let p=Math.round(t.width*.84*(a.scale??r.scale)),l=Math.round(t.height*(r.offsetY+(a.offsetY??0))),c=a.pose||r.pose,m=R(r.shadow,u);return["position:absolute",`top:${Math.round(t.height*.075)+l}px`,"left:50%",`width:${p}px`,"transform-origin:center center",`transform:${L("translateX(-50%)",A(c))}`,`filter:${E(m)}`,"z-index:2"].join(";")}}}let o=Math.round(t.height*.04),i=Math.round(t.height*.019);return{copyStyle:["position:absolute",`top:${Math.round(t.height*.084)}px`,"left:50%",`width:${Math.round(t.width*.88)}px`,"transform:translateX(-50%)","text-align:center","z-index:3"].join(";"),titleStyle:`font-size:${o}px;line-height:0.92;`,subStyle:`font-size:${i}px;line-height:1.34;max-width:${Math.round(t.width*.6)}px;margin:0 auto;`,eyebrowStyle:"align-items:center;",deviceStyle:(n,s,r)=>{let a=t.name==="ipad-13"?.54:.64,u=Math.round(t.width*a*(s.scale??n.scale)),p=Math.round(t.height*(n.offsetY+(s.offsetY??0))),l=s.pose||n.pose,c=R(n.shadow,r);return["position:absolute",`top:${Math.round(t.height*(t.name==="ipad-13"?.25:.28))+p}px`,"left:50%",`width:${u}px`,"transform-origin:center top",`transform:${L("translateX(-50%)",A(l))}`,`filter:${E(c)}`,"z-index:2"].join(";")}}}function ne({canvas:e,compose:t,slide:o,imageDataUrl:i}){let n=o.background??t.background,s=oe(t.text.preset,e),r=t.text.preset!=="none"&&!!(o.eyebrow||o.headline||o.subheadline),a=s.deviceStyle(t.frame,o,n),u=o.headline?`<div style="font-weight:780;white-space:pre-line;text-wrap:balance;${s.titleStyle}">${v(o.headline)}</div>`:"",p=o.subheadline?`<div style="margin-top:${Math.round(e.height*.018)}px;color:${t.text.subColor};white-space:pre-line;text-wrap:balance;${s.subStyle}">${v(o.subheadline)}</div>`:"",l=o.eyebrow?`<div style="display:flex;${s.eyebrowStyle}margin-bottom:${Math.round(e.height*.016)}px;"><div style="font-size:${Math.round(e.height*.014)}px;font-weight:700;letter-spacing:0.18em;text-transform:uppercase;color:${t.text.eyebrowColor};">${v(o.eyebrow)}</div></div>`:"";return`<!doctype html>
3
3
  <html>
4
4
  <head>
5
5
  <meta charset="utf-8" />