sootsim 0.1.122 → 0.1.124

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 (153) hide show
  1. package/dist-cli/bin.js +3 -3
  2. package/dist-cli/chunks/agent-3VAW5LZD.js +46 -0
  3. package/dist-cli/chunks/{agent-wrapper-KK5TEI3F.js → agent-wrapper-YCNCH7CG.js} +2 -2
  4. package/dist-cli/chunks/{app-fonts-UZXW5FWC.js → app-fonts-BKHY7U6N.js} +2 -2
  5. package/dist-cli/chunks/{assert-UZGKOSWO.js → assert-IJP5E6DT.js} +2 -2
  6. package/dist-cli/chunks/auto-bootstrap-EKA34I25.js +2 -0
  7. package/dist-cli/chunks/beta-DPPCI2ZU.js +2 -0
  8. package/dist-cli/chunks/{chunk-7AXDJ2RV.js → chunk-2IT7O7KQ.js} +2 -2
  9. package/dist-cli/chunks/chunk-2JTGXU4D.js +5 -0
  10. package/dist-cli/chunks/{chunk-GLVNMGFD.js → chunk-4YSKSJI3.js} +2 -2
  11. package/dist-cli/chunks/{chunk-GX2FFJV6.js → chunk-5GVG37QH.js} +2 -2
  12. package/dist-cli/chunks/chunk-66ETIVOD.js +1 -0
  13. package/dist-cli/chunks/{chunk-S2RR2IZC.js → chunk-A5O2QWEB.js} +1 -1
  14. package/dist-cli/chunks/{chunk-TZLLRML5.js → chunk-AUR7DDPB.js} +3 -3
  15. package/dist-cli/chunks/chunk-CA7DYUFF.js +7 -0
  16. package/dist-cli/chunks/{chunk-IRSVHE5W.js → chunk-DCZGWL5K.js} +1 -1
  17. package/dist-cli/chunks/{chunk-ESUDARF7.js → chunk-DGQN4QFL.js} +1 -1
  18. package/dist-cli/chunks/{chunk-S5KZH7JJ.js → chunk-E7GET25R.js} +2 -2
  19. package/dist-cli/chunks/{chunk-3MKNANBV.js → chunk-EESOIR2B.js} +2 -2
  20. package/dist-cli/chunks/{chunk-7OVVG4L6.js → chunk-F4W6VKRG.js} +2 -2
  21. package/dist-cli/chunks/{chunk-D5VB3SJP.js → chunk-FPHJY2YU.js} +1 -1
  22. package/dist-cli/chunks/{chunk-G6Z5E4KX.js → chunk-G6G5LYD3.js} +2 -2
  23. package/dist-cli/chunks/{chunk-366ZIBQX.js → chunk-GYK5RCAC.js} +1 -1
  24. package/dist-cli/chunks/{chunk-5GQJWYO7.js → chunk-HQ5JZI67.js} +1 -1
  25. package/dist-cli/chunks/{chunk-AK2PW7XZ.js → chunk-I4F7AUP2.js} +2 -2
  26. package/dist-cli/chunks/{chunk-LKSAMFVM.js → chunk-IA347TKV.js} +1 -1
  27. package/dist-cli/chunks/{chunk-BII2H2BR.js → chunk-J67NC7MV.js} +3 -3
  28. package/dist-cli/chunks/{chunk-FFMAP2HL.js → chunk-JOEOYLTY.js} +1 -1
  29. package/dist-cli/chunks/chunk-JUX2JKSR.js +2 -0
  30. package/dist-cli/chunks/{chunk-2XDZ42A6.js → chunk-KBFPZMXJ.js} +2 -2
  31. package/dist-cli/chunks/{chunk-IBEQOTJK.js → chunk-KTRDHNPZ.js} +1 -1
  32. package/dist-cli/chunks/{chunk-VHPYIZ3U.js → chunk-KXSJQP6J.js} +2 -2
  33. package/dist-cli/chunks/{chunk-SUQAFFJO.js → chunk-LTHY7I3V.js} +1 -1
  34. package/dist-cli/chunks/{chunk-36BDR3DE.js → chunk-NQZCZVNZ.js} +2 -2
  35. package/dist-cli/chunks/{chunk-QD5YATLL.js → chunk-OPWN5ZM7.js} +2 -2
  36. package/dist-cli/chunks/{chunk-3JHF4F55.js → chunk-PP5QI5FB.js} +1 -1
  37. package/dist-cli/chunks/{chunk-X6PIQ3OM.js → chunk-PQZNX54H.js} +2 -2
  38. package/dist-cli/chunks/{chunk-M6ML3LBZ.js → chunk-Q5YWPKAG.js} +2 -2
  39. package/dist-cli/chunks/{chunk-ITGWJM6W.js → chunk-QG4GIDXL.js} +2 -2
  40. package/dist-cli/chunks/{chunk-GNWVN4MO.js → chunk-QTHELIAB.js} +2 -2
  41. package/dist-cli/chunks/{chunk-NIL4WJUK.js → chunk-R7R5HWAT.js} +2 -2
  42. package/dist-cli/chunks/{chunk-2KKPINU2.js → chunk-RMDVV4YS.js} +1 -1
  43. package/dist-cli/chunks/{chunk-6NW6PC3P.js → chunk-TJLVKZJQ.js} +2 -2
  44. package/dist-cli/chunks/{chunk-RBWDMEWN.js → chunk-TJUPANGE.js} +1 -1
  45. package/dist-cli/chunks/{chunk-V4OEITZA.js → chunk-TUZCEXOT.js} +2 -2
  46. package/dist-cli/chunks/chunk-VXRIUP2K.js +1 -0
  47. package/dist-cli/chunks/{chunk-6PKYLQ36.js → chunk-WH3M4U2P.js} +1 -1
  48. package/dist-cli/chunks/chunk-X5LIH464.js +1 -0
  49. package/dist-cli/chunks/{chunk-3BCXNVBN.js → chunk-YFCC2KKG.js} +2 -2
  50. package/dist-cli/chunks/{chunk-UQHBJ2L2.js → chunk-ZL7STHLD.js} +1 -1
  51. package/dist-cli/chunks/{chunk-J27RHTWH.js → chunk-ZV3W66US.js} +2 -2
  52. package/dist-cli/chunks/cli-version-RTYBGBXB.js +2 -0
  53. package/dist-cli/chunks/{compat-QFC2IVZI.js → compat-AKOAVN2G.js} +3 -3
  54. package/dist-cli/chunks/{config-LU3HYSGJ.js → config-GYQK6ZKQ.js} +2 -2
  55. package/dist-cli/chunks/control-HNK3OF2T.js +2 -0
  56. package/dist-cli/chunks/{cpu-profile-SJV2ERLS.js → cpu-profile-TX4QMZZA.js} +2 -2
  57. package/dist-cli/chunks/{daemon-TMW3WV27.js → daemon-6BDWMPND.js} +24 -24
  58. package/dist-cli/chunks/{debug-PBM4L52R.js → debug-3EFC6N6J.js} +3 -3
  59. package/dist-cli/chunks/{detox-VANQVBBM.js → detox-BDBX3YVO.js} +2 -2
  60. package/dist-cli/chunks/{device-VIMOCLKX.js → device-CHHYWWPG.js} +2 -2
  61. package/dist-cli/chunks/{diagnose-CRCRKGLQ.js → diagnose-EAXEHFIG.js} +2 -2
  62. package/dist-cli/chunks/drivers-B4PIARZR.js +2 -0
  63. package/dist-cli/chunks/{electron-SWTX2DO7.js → electron-MHB2W6ZP.js} +3 -3
  64. package/dist-cli/chunks/flow-HWDVF2M3.js +2 -0
  65. package/dist-cli/chunks/help-7FMLHEKH.js +2 -0
  66. package/dist-cli/chunks/{hints-KM6DYEYZ.js → hints-QAKIPTMF.js} +2 -2
  67. package/dist-cli/chunks/home-paths-OD73ST5G.js +2 -0
  68. package/dist-cli/chunks/{inspect-Z3KYGCZ4.js → inspect-4SGHZLMG.js} +3 -3
  69. package/dist-cli/chunks/install-WZK6LXM6.js +2 -0
  70. package/dist-cli/chunks/{install-desktop-XDZLXMC2.js → install-desktop-SFPJHT2D.js} +3 -3
  71. package/dist-cli/chunks/{keys-KEPNUBCA.js → keys-XQZGTVEZ.js} +2 -2
  72. package/dist-cli/chunks/launch-KG2GSCQV.js +16 -0
  73. package/dist-cli/chunks/{login-RDMQ4LGI.js → login-KYT67KEA.js} +4 -4
  74. package/dist-cli/chunks/{logout-HDPMIRMV.js → logout-IBMVZBNN.js} +2 -2
  75. package/dist-cli/chunks/{maestro-A3QGVBQW.js → maestro-YA62KLKO.js} +2 -2
  76. package/dist-cli/chunks/{preview-HXMXXPPF.js → preview-CXH6NIVN.js} +2 -2
  77. package/dist-cli/chunks/{profile-CXIPWQLZ.js → profile-UVB3AVOS.js} +2 -2
  78. package/dist-cli/chunks/{react-PNVZTDPA.js → react-M2CHY2TY.js} +2 -2
  79. package/dist-cli/chunks/{record-LALIKJN2.js → record-SZORC67L.js} +3 -3
  80. package/dist-cli/chunks/runtime-PO4BMP3J.js +2 -0
  81. package/dist-cli/chunks/{runtime-delivery-IU6INVF7.js → runtime-delivery-NBQRZ65J.js} +2 -2
  82. package/dist-cli/chunks/{screenshot-RITJ6BZH.js → screenshot-I34CN2NI.js} +2 -2
  83. package/dist-cli/chunks/{screenshot-mode-4ZMTOYNG.js → screenshot-mode-NQNLKD67.js} +2 -2
  84. package/dist-cli/chunks/{screenshots-LDJZ4CFO.js → screenshots-NHQSKU5V.js} +2 -2
  85. package/dist-cli/chunks/{server-2Q6HJBRG.js → server-L3UP7BR6.js} +15 -15
  86. package/dist-cli/chunks/setup-repo-GUPYQ2J5.js +2 -0
  87. package/dist-cli/chunks/{skills-7HSB6DOQ.js → skills-ULNZRVS3.js} +2 -2
  88. package/dist-cli/chunks/{start-MM3GHFNB.js → start-G56BRWEF.js} +4 -4
  89. package/dist-cli/chunks/store-WW7XXZNM.js +2 -0
  90. package/dist-cli/chunks/telemetry-3FW6INA6.js +2 -0
  91. package/dist-cli/chunks/{test-JVZONK7Z.js → test-RVKY4RKI.js} +3 -3
  92. package/dist-cli/chunks/{three-mode-5LHS72VD.js → three-mode-MORULFUD.js} +2 -2
  93. package/dist-cli/chunks/{timeline-AN3WAGXK.js → timeline-PNE7JILB.js} +2 -2
  94. package/dist-cli/chunks/{upgrade-LES72FX4.js → upgrade-XAVE44HP.js} +2 -2
  95. package/dist-cli/chunks/upload-T6JS6GQQ.js +2 -0
  96. package/dist-cli/chunks/{version-SKCJLX5C.js → version-CXEJDONA.js} +2 -2
  97. package/dist-cli/chunks/{web-AWRFEEZU.js → web-HJUVVLLW.js} +2 -2
  98. package/dist-cli/chunks/{what-happened-JNCZGYUL.js → what-happened-JP3M2RDF.js} +2 -2
  99. package/dist-cli/chunks/{whoami-HYV4EQ5D.js → whoami-BCGVUSDW.js} +2 -2
  100. package/dist-lib/agent-daemon-client.cjs +50 -20
  101. package/dist-lib/agent-events.cjs +1 -1
  102. package/dist-lib/agent-sessions.cjs +1 -1
  103. package/dist-lib/attached-projects.cjs +1 -1
  104. package/dist-lib/auth/shared-session.cjs +1 -1
  105. package/dist-lib/backend-origin.cjs +1 -1
  106. package/dist-lib/beta.cjs +1 -1
  107. package/dist-lib/beta.mjs +1 -1
  108. package/dist-lib/bridge-constants.cjs +1 -1
  109. package/dist-lib/cli-constants.cjs +1 -1
  110. package/dist-lib/config.cjs +1 -1
  111. package/dist-lib/detox/index.cjs +1 -1
  112. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  113. package/dist-lib/home-paths.cjs +12 -1
  114. package/dist-lib/host/bridge-host.cjs +1 -1
  115. package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
  116. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  117. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  118. package/dist-lib/host/websocket-proxy.cjs +1 -1
  119. package/dist-lib/index.cjs +1 -1
  120. package/dist-lib/metro.cjs +1 -1
  121. package/dist-lib/profiles.cjs +1 -1
  122. package/dist-lib/render-mode.cjs +1 -1
  123. package/dist-lib/scripts/demo-app-registry.cjs +1 -1
  124. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  125. package/dist-lib/sdk.cjs +1 -1
  126. package/dist-lib/sdk.mjs +1 -1
  127. package/dist-lib/skills.cjs +1 -1
  128. package/dist-lib/vite.cjs +1 -1
  129. package/package.json +1 -1
  130. package/src/agent-daemon-client.ts +17 -0
  131. package/src/home-paths.ts +26 -0
  132. package/dist-cli/chunks/agent-LICWL6DE.js +0 -46
  133. package/dist-cli/chunks/auto-bootstrap-GCRCFYH5.js +0 -2
  134. package/dist-cli/chunks/beta-6BJEGCY4.js +0 -2
  135. package/dist-cli/chunks/chunk-3P4C6X6M.js +0 -1
  136. package/dist-cli/chunks/chunk-EGFZLSP4.js +0 -1
  137. package/dist-cli/chunks/chunk-KWXV47VS.js +0 -2
  138. package/dist-cli/chunks/chunk-LYZ3GSCB.js +0 -1
  139. package/dist-cli/chunks/chunk-RH3GHGRZ.js +0 -7
  140. package/dist-cli/chunks/chunk-T2YYBRII.js +0 -5
  141. package/dist-cli/chunks/cli-version-4BVXR3IU.js +0 -2
  142. package/dist-cli/chunks/control-L4C43O4N.js +0 -2
  143. package/dist-cli/chunks/drivers-OUO3WJ3H.js +0 -2
  144. package/dist-cli/chunks/flow-RGF7ZOD4.js +0 -2
  145. package/dist-cli/chunks/help-OTY4AGCS.js +0 -2
  146. package/dist-cli/chunks/home-paths-VON247XB.js +0 -2
  147. package/dist-cli/chunks/install-HHP7GSJ4.js +0 -2
  148. package/dist-cli/chunks/launch-S2H6FBFG.js +0 -16
  149. package/dist-cli/chunks/runtime-OQQOJSTS.js +0 -2
  150. package/dist-cli/chunks/setup-repo-3JXYJESB.js +0 -2
  151. package/dist-cli/chunks/store-EOS7PN7Y.js +0 -2
  152. package/dist-cli/chunks/telemetry-MJ2ZVNZG.js +0 -2
  153. package/dist-cli/chunks/upload-JE2ORZSH.js +0 -2
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as b}from"./chunk-ESUDARF7.js";import{a as x}from"./chunk-S2RR2IZC.js";import"./chunk-IBEQOTJK.js";import{spawn as v,spawnSync as u}from"child_process";import{chmodSync as S,copyFileSync as T,createWriteStream as E,existsSync as w,mkdirSync as y,rmSync as g,statSync as P,unlinkSync as D}from"fs";import{tmpdir as M}from"os";import{dirname as A,join as f,resolve as k}from"path";var h="https://sootbean.com/api/electron-release";function O(){let n=process.arch;if(process.platform==="darwin"){let o=n==="arm64"?"mac-arm64":"mac-x64",e=`sootsim-latest-${o}.dmg`;return{platform:o,filename:e,url:`${h}/${e}`,install:L}}if(process.platform==="linux"){let o=n==="arm64"?"linux-arm64":"linux-x64",e=`sootsim-latest-${o}.AppImage`;return{platform:o,filename:e,url:`${h}/${e}`,install:C}}if(process.platform==="win32"){let o="sootsim-latest-win-x64.exe";return{platform:"win-x64",filename:o,url:`${h}/${o}`,install:B}}return null}async function _({url:n,dest:o,onProgress:e}){let s=await fetch(n,{redirect:"follow"});if(!s.ok)throw new Error(`download failed: ${s.status} ${s.statusText} (${n})`);let t=s.headers.get("content-length"),a=t?Number(t):null;if(!s.body)throw new Error("download failed: empty response body");y(A(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,e?.(c,a)}}finally{await new Promise((l,p)=>{i.end(r=>r?p(r):l())})}}function I(n,o){let e=(n/1048576).toFixed(1);if(!o)return` ${e} MB`;let s=Math.min(100,Math.round(n/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}% ${e} / ${t} MB`}async function L(n){let o=u("hdiutil",["attach","-nobrowse","-readonly",n],{encoding:"utf8"});if(o.status!==0)throw new Error(`hdiutil attach failed: ${o.stderr||o.stdout}`.trim());let e=o.stdout.trim().split(`
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as b}from"./chunk-DGQN4QFL.js";import{a as x}from"./chunk-A5O2QWEB.js";import"./chunk-KTRDHNPZ.js";import{spawn as v,spawnSync as u}from"child_process";import{chmodSync as S,copyFileSync as T,createWriteStream as E,existsSync as w,mkdirSync as y,rmSync as g,statSync as P,unlinkSync as D}from"fs";import{tmpdir as M}from"os";import{dirname as A,join as f,resolve as k}from"path";var h="https://sootbean.com/api/electron-release";function O(){let n=process.arch;if(process.platform==="darwin"){let o=n==="arm64"?"mac-arm64":"mac-x64",e=`sootsim-latest-${o}.dmg`;return{platform:o,filename:e,url:`${h}/${e}`,install:L}}if(process.platform==="linux"){let o=n==="arm64"?"linux-arm64":"linux-x64",e=`sootsim-latest-${o}.AppImage`;return{platform:o,filename:e,url:`${h}/${e}`,install:C}}if(process.platform==="win32"){let o="sootsim-latest-win-x64.exe";return{platform:"win-x64",filename:o,url:`${h}/${o}`,install:B}}return null}async function _({url:n,dest:o,onProgress:e}){let s=await fetch(n,{redirect:"follow"});if(!s.ok)throw new Error(`download failed: ${s.status} ${s.statusText} (${n})`);let t=s.headers.get("content-length"),a=t?Number(t):null;if(!s.body)throw new Error("download failed: empty response body");y(A(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,e?.(c,a)}}finally{await new Promise((l,p)=>{i.end(r=>r?p(r):l())})}}function I(n,o){let e=(n/1048576).toFixed(1);if(!o)return` ${e} MB`;let s=Math.min(100,Math.round(n/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}% ${e} / ${t} MB`}async function L(n){let o=u("hdiutil",["attach","-nobrowse","-readonly",n],{encoding:"utf8"});if(o.status!==0)throw new Error(`hdiutil attach failed: ${o.stderr||o.stdout}`.trim());let e=o.stdout.trim().split(`
3
3
  `),t=e[e.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=k(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]),r=u("hdiutil",["detach","-force",t]);if(p.status!==0)throw new Error(`copy to ${l} failed: ${p.stderr?.toString()||""}`.trim());return r.status!==0&&console.warn(` warning: failed to unmount ${t} (${r.stderr?.toString().trim()||"unknown error"})`),u("xattr",["-dr","com.apple.quarantine",l]),l}async function C(n){let o=k(process.env.HOME||"","Applications");y(o,{recursive:!0});let e=f(o,"sootsim.AppImage");return w(e)&&g(e,{force:!0}),T(n,e),D(n),S(e,493),e}async function B(n){return await new Promise((o,e)=>{let s=v("cmd",["/c","start",'""',"/wait",n],{stdio:"inherit"});s.once("error",e),s.once("exit",t=>{t===0?o():e(new Error(`installer exited with code ${t}`))})}),n}async function G(n){(n.includes("--help")||n.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=n.includes("--yes")||n.includes("-y")||process.env.SOOTSIM_NO_PROMPT==="1"||process.env.CI==="1"||!process.stdin.isTTY,e=n.includes("--force"),s=x();if(s&&!e){console.log(` sootsim desktop already installed at: ${s.path}`),console.log(" pass --force to reinstall.");return}let t=O();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(M(),`sootsim-install-${Date.now()}`),i=f(a,t.filename),d=0;process.stdout.write(` downloading ${t.filename}...
21
21
  `);try{await _({url:t.url,dest:i,onProgress:(r,m)=>{let $=Date.now();$-d<100&&r<(m??1/0)||(d=$,process.stdout.isTTY&&process.stdout.write(`\r\x1B[2K${I(r,m)}`))}})}catch(r){g(a,{recursive:!0,force:!0}),console.error(`
22
22
  download failed: ${r instanceof Error?r.message:String(r)}`),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-MJ2ZVNZG.js");try{let r=await t.install(i);l({event:"cli_install_desktop_succeeded",properties:{platform:t.platform,size_bytes:c}}),console.log(` installed: ${r}`)}catch(r){l({event:"cli_install_desktop_failed",properties:{platform:t.platform,error:r instanceof Error?r.message:String(r)}}),await p(),console.error(` install failed: ${r instanceof Error?r.message:String(r)}`),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{G 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-3FW6INA6.js");try{let r=await t.install(i);l({event:"cli_install_desktop_succeeded",properties:{platform:t.platform,size_bytes:c}}),console.log(` installed: ${r}`)}catch(r){l({event:"cli_install_desktop_failed",properties:{platform:t.platform,error:r instanceof Error?r.message:String(r)}}),await p(),console.error(` install failed: ${r instanceof Error?r.message:String(r)}`),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{G as runInstallDesktop};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.122 | (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-7AXDJ2RV.js";import{d as c}from"./chunk-VHPYIZ3U.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.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.124 | (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-2IT7O7KQ.js";import{d as c}from"./chunk-KXSJQP6J.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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.
@@ -0,0 +1,16 @@
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-VXRIUP2K.js";import{b as h}from"./chunk-NQZCZVNZ.js";import{a as d}from"./chunk-A5O2QWEB.js";import"./chunk-66ETIVOD.js";import"./chunk-R7R5HWAT.js";import"./chunk-DCZGWL5K.js";import"./chunk-GYK5RCAC.js";import{A as t,B as u,F as m,G as r,H as a,h as l,i as c}from"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.js";import{spawn as v}from"child_process";import{existsSync as w}from"fs";async function O(n){if(n.includes("--help")||n.includes("-h")){console.log(`
3
+ sootsim launch \u2014 one-shot: install runtime if needed, start daemon, open app
4
+
5
+ usage:
6
+ sootsim launch [options]
7
+
8
+ options:
9
+ --no-runtime-install don't auto-install a runtime if none exists (fail instead)
10
+ --channel <name> runtime channel for auto-install (default: stable)
11
+ --version <version> specific runtime version to auto-install
12
+
13
+ examples:
14
+ sootsim launch
15
+ sootsim launch --version 1.2.3
16
+ `);return}let e=n.includes("--no-runtime-install"),i=n.indexOf("--channel"),s=i>=0&&n[i+1]?n[i+1]:"stable",o=n.indexOf("--version"),f=o>=0&&n[o+1]?n[o+1]:void 0;t(),await x({skipAutoInstall:e,channel:s,explicitVersion:f}),await p(),await k()}async function x(n){let e=u(),i=m();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:s}=await import("./runtime-PO4BMP3J.js"),o=[];n.explicitVersion&&o.push(n.explicitVersion),n.channel!=="stable"&&o.push("--channel",n.channel),await s(["install",...o],{channel:n.channel})}async function p(){let n=r();if(a(n))return;if(c()){let o=l()?"this is a dev workstation (IS_TAMAGUI_DEV=1)":"this is a dev checkout";console.error(` not spawning a standalone sootsim daemon \u2014 ${o}.`),console.error(" the live `bun dev` stack hosts the bridge in-process (run it, or its electron);"),console.error(" set SOOTSIM_FORCE_DAEMON_INSTALL=1 to spawn one here on purpose."),process.exit(1)}console.log("sootsim: starting daemon");let e=g();v(e,["server","--quiet"],{detached:!0,stdio:"ignore",env:process.env}).unref();let s=Date.now()+8e3;for(;Date.now()<s;){let o=r();if(a(o))return;await D(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 k(){d()||(console.error(" no sootsim desktop companion installed. run `sootsim install-desktop` to download electron + the shell."),process.exit(1));let e=await h.launch({});e.launched||(console.error(` ${e.message}`),process.exit(1)),console.log(` ${e.message}`)}function g(){let n=process.argv[1];return n&&w(n)?n:"sootsim"}function D(n){return new Promise(e=>setTimeout(e,n))}async function R(){t(),await p()}export{R as ensureDaemonRunning,O as runLaunch};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as g,d as m}from"./chunk-VHPYIZ3U.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.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(r){if(r)return r;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 L(){console.log(`
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as g,d as m}from"./chunk-KXSJQP6J.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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(r){if(r)return r;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 L(){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">${r}</p>
22
22
  </div>
23
23
  </body>
24
- </html>`}async function P(r){try{let e=await fetch(`${r.replace(/\/$/,"")}/api/dev-login`,{method:"POST"});if(e.status===403)return{ok:!1,error:"dev-login disabled (not in dev mode)"};if(!e.ok){let c=await e.text().catch(()=>"");return{ok:!1,error:`dev-login ${e.status}: ${c}`}}let t=await e.json();return t.token?{ok:!0,token:t.token,userId:t.user?.id,email:t.email}:{ok:!1,error:"dev-login response missing token"}}catch(e){return{ok:!1,error:e instanceof Error?e.message:"dev-login fetch failed"}}}function A(r){try{let e=new URL(r).hostname.replace(/^\[|\]$/g,"").toLowerCase();return!!(e==="localhost"||/^127(?:\.\d{1,3}){3}$/.test(e)||e==="::1"||e==="0.0.0.0"||e.endsWith(".local")||e.endsWith(".localhost")||e==="host.containers.internal"||e==="host.docker.internal"||e==="host.orb.internal"||e==="host.lima.internal"||e==="fd07:b51a:cc66:f0::fe")}catch{return!1}}async function G(r){(r.includes("--help")||r.includes("-h"))&&(L(),process.exit(0));let e=[...r],t=await x(R(e,"--origin"));if(A(t)){console.log(` detected local origin (${t}) \u2014 signing in as dev user`);let o=await P(t);if(o.ok){g({token:o.token,user:o.userId?{id:o.userId,email:o.email}:null,origin:t,source:"cli"});let s=await m(t),l=s?.user?.email||o.email||s?.user?.id||o.userId,{trackCliEvent:n,flushCliTelemetry:a}=await import("./telemetry-MJ2ZVNZG.js");n({event:"cli_login_succeeded",identity:{userId:o.userId??s?.user?.id??null},properties:{origin:t,mode:"dev"}}),await a(),console.log(` signed in${l?` as ${l}`:""} (dev)`);return}console.log(` dev-login not available (${o.error}); falling back to browser`)}let c=$(16).toString("hex"),i=await new Promise(o=>{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,f=a.searchParams.get("error");if(n.setHeader("content-type","text/html; charset=utf-8"),f){n.end(u(`sign-in failed: ${f}`)),o({ok:!1,error:f}),s.close();return}if(w!==c){n.end(u("state mismatch. close this tab and retry `sootsim login`.")),o({ok:!1,error:"state mismatch"}),s.close();return}if(!k){n.end(u("missing token. close this tab and retry `sootsim login`.")),o({ok:!1,error:"missing token"}),s.close();return}n.end(u("sign-in complete. you can return to the terminal.")),o({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`.")),o({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"){o({ok:!1,error:"failed to bind callback server"}),s.close();return}let n=new URL(`${t.replace(/\/$/,"")}/auth/sootsim-cli`);n.searchParams.set("state",c),n.searchParams.set("port",String(l.port)),n.searchParams.set("sootbean",t),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(r){try{let e=await fetch(`${r.replace(/\/$/,"")}/api/dev-login`,{method:"POST"});if(e.status===403)return{ok:!1,error:"dev-login disabled (not in dev mode)"};if(!e.ok){let c=await e.text().catch(()=>"");return{ok:!1,error:`dev-login ${e.status}: ${c}`}}let t=await e.json();return t.token?{ok:!0,token:t.token,userId:t.user?.id,email:t.email}:{ok:!1,error:"dev-login response missing token"}}catch(e){return{ok:!1,error:e instanceof Error?e.message:"dev-login fetch failed"}}}function A(r){try{let e=new URL(r).hostname.replace(/^\[|\]$/g,"").toLowerCase();return!!(e==="localhost"||/^127(?:\.\d{1,3}){3}$/.test(e)||e==="::1"||e==="0.0.0.0"||e.endsWith(".local")||e.endsWith(".localhost")||e==="host.containers.internal"||e==="host.docker.internal"||e==="host.orb.internal"||e==="host.lima.internal"||e==="fd07:b51a:cc66:f0::fe")}catch{return!1}}async function G(r){(r.includes("--help")||r.includes("-h"))&&(L(),process.exit(0));let e=[...r],t=await x(R(e,"--origin"));if(A(t)){console.log(` detected local origin (${t}) \u2014 signing in as dev user`);let o=await P(t);if(o.ok){g({token:o.token,user:o.userId?{id:o.userId,email:o.email}:null,origin:t,source:"cli"});let s=await m(t),l=s?.user?.email||o.email||s?.user?.id||o.userId,{trackCliEvent:n,flushCliTelemetry:a}=await import("./telemetry-3FW6INA6.js");n({event:"cli_login_succeeded",identity:{userId:o.userId??s?.user?.id??null},properties:{origin:t,mode:"dev"}}),await a(),console.log(` signed in${l?` as ${l}`:""} (dev)`);return}console.log(` dev-login not available (${o.error}); falling back to browser`)}let c=$(16).toString("hex"),i=await new Promise(o=>{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,f=a.searchParams.get("error");if(n.setHeader("content-type","text/html; charset=utf-8"),f){n.end(u(`sign-in failed: ${f}`)),o({ok:!1,error:f}),s.close();return}if(w!==c){n.end(u("state mismatch. close this tab and retry `sootsim login`.")),o({ok:!1,error:"state mismatch"}),s.close();return}if(!k){n.end(u("missing token. close this tab and retry `sootsim login`.")),o({ok:!1,error:"missing token"}),s.close();return}n.end(u("sign-in complete. you can return to the terminal.")),o({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`.")),o({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"){o({ok:!1,error:"failed to bind callback server"}),s.close();return}let n=new URL(`${t.replace(/\/$/,"")}/auth/sootsim-cli`);n.searchParams.set("state",c),n.searchParams.set("port",String(l.port)),n.searchParams.set("sootbean",t),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
- `),T(n.toString())})});if(!i.ok){let{trackCliEvent:o,flushCliTelemetry:s}=await import("./telemetry-MJ2ZVNZG.js");o({event:"cli_login_failed",properties:{origin:t,error:i.error}}),await s(),console.error(` login failed: ${i.error}`),process.exit(1)}g({token:i.token,user:i.userId?{id:i.userId,email:i.email}:null,origin:t,source:"cli"});let d=await m(t),p=d?.user?.email||i.email||d?.user?.id||i.userId,{trackCliEvent:y,flushCliTelemetry:v}=await import("./telemetry-MJ2ZVNZG.js");y({event:"cli_login_succeeded",identity:{userId:i.userId??d?.user?.id??null},properties:{origin:t}}),await v(),console.log(` signed in${p?` as ${p}`:""}`)}export{G as runLogin};
26
+ `),T(n.toString())})});if(!i.ok){let{trackCliEvent:o,flushCliTelemetry:s}=await import("./telemetry-3FW6INA6.js");o({event:"cli_login_failed",properties:{origin:t,error:i.error}}),await s(),console.error(` login failed: ${i.error}`),process.exit(1)}g({token:i.token,user:i.userId?{id:i.userId,email:i.email}:null,origin:t,source:"cli"});let d=await m(t),p=d?.user?.email||i.email||d?.user?.id||i.userId,{trackCliEvent:y,flushCliTelemetry:v}=await import("./telemetry-3FW6INA6.js");y({event:"cli_login_succeeded",identity:{userId:i.userId??d?.user?.id??null},properties:{origin:t}}),await v(),console.log(` signed in${p?` as ${p}`:""}`)}export{G as runLogin};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as r,b as i}from"./chunk-3BCXNVBN.js";import{a as t,c as o}from"./chunk-VHPYIZ3U.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.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.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as r,b as i}from"./chunk-YFCC2KKG.js";import{a as t,c as o}from"./chunk-KXSJQP6J.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as h,c as w}from"./chunk-BII2H2BR.js";import"./chunk-M6ML3LBZ.js";import"./chunk-EGFZLSP4.js";import"./chunk-ITGWJM6W.js";import"./chunk-QD5YATLL.js";import"./chunk-7AXDJ2RV.js";import"./chunk-AK2PW7XZ.js";import"./chunk-2XDZ42A6.js";import"./chunk-V4OEITZA.js";import"./chunk-G6Z5E4KX.js";import"./chunk-RBWDMEWN.js";import"./chunk-SUQAFFJO.js";import"./chunk-J27RHTWH.js";import"./chunk-36BDR3DE.js";import"./chunk-S2RR2IZC.js";import"./chunk-LYZ3GSCB.js";import"./chunk-NIL4WJUK.js";import"./chunk-IRSVHE5W.js";import"./chunk-366ZIBQX.js";import"./chunk-3BCXNVBN.js";import"./chunk-VHPYIZ3U.js";import"./chunk-3MKNANBV.js";import"./chunk-KWXV47VS.js";import"./chunk-UQHBJ2L2.js";import"./chunk-6NW6PC3P.js";import"./chunk-6PKYLQ36.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.js";import*as i from"fs";import*as l from"path";var v=[".maestro","maestro"];function x(){console.log(`
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as h,c as w}from"./chunk-J67NC7MV.js";import"./chunk-Q5YWPKAG.js";import"./chunk-X5LIH464.js";import"./chunk-QG4GIDXL.js";import"./chunk-OPWN5ZM7.js";import"./chunk-2IT7O7KQ.js";import"./chunk-I4F7AUP2.js";import"./chunk-KBFPZMXJ.js";import"./chunk-TUZCEXOT.js";import"./chunk-G6G5LYD3.js";import"./chunk-TJUPANGE.js";import"./chunk-LTHY7I3V.js";import"./chunk-ZV3W66US.js";import"./chunk-NQZCZVNZ.js";import"./chunk-A5O2QWEB.js";import"./chunk-66ETIVOD.js";import"./chunk-R7R5HWAT.js";import"./chunk-DCZGWL5K.js";import"./chunk-GYK5RCAC.js";import"./chunk-YFCC2KKG.js";import"./chunk-KXSJQP6J.js";import"./chunk-EESOIR2B.js";import"./chunk-JUX2JKSR.js";import"./chunk-ZL7STHLD.js";import"./chunk-TJLVKZJQ.js";import"./chunk-WH3M4U2P.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-IBEQOTJK.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.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import"./chunk-KTRDHNPZ.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.122 | (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-NIL4WJUK.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.js";function f(){console.log(`
1
+ /*! sootsim v0.1.124 | (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-R7R5HWAT.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{c as w,e as b,h as m,i as f}from"./chunk-J27RHTWH.js";import"./chunk-366ZIBQX.js";import"./chunk-UQHBJ2L2.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.js";function h(){console.log(`
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{c as w,e as b,h as m,i as f}from"./chunk-ZV3W66US.js";import"./chunk-GYK5RCAC.js";import"./chunk-ZL7STHLD.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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,10 +1,10 @@
1
- /*! sootsim v0.1.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as P}from"./chunk-ITGWJM6W.js";import"./chunk-QD5YATLL.js";import{d as Z,f as ee}from"./chunk-7AXDJ2RV.js";import"./chunk-SUQAFFJO.js";import{c as b,e as v,f as Y}from"./chunk-J27RHTWH.js";import"./chunk-LYZ3GSCB.js";import{d as X}from"./chunk-IRSVHE5W.js";import{b as Q}from"./chunk-366ZIBQX.js";import"./chunk-3BCXNVBN.js";import"./chunk-VHPYIZ3U.js";import"./chunk-UQHBJ2L2.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.js";import{existsSync as we,mkdirSync as B,readdirSync as he,readFileSync as be,rmSync as J,writeFileSync as I}from"fs";import{homedir as ve,tmpdir as ye}from"os";import{dirname as D,extname as oe,join as N,resolve as Se}from"path";var z=24e4,Re=3e4;async function W(e,r,o,i){let t=Math.max(2e4,i+Re);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.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as P}from"./chunk-QG4GIDXL.js";import"./chunk-OPWN5ZM7.js";import{d as Z,f as ee}from"./chunk-2IT7O7KQ.js";import"./chunk-LTHY7I3V.js";import{c as b,e as v,f as Y}from"./chunk-ZV3W66US.js";import"./chunk-66ETIVOD.js";import{d as X}from"./chunk-DCZGWL5K.js";import{b as Q}from"./chunk-GYK5RCAC.js";import"./chunk-YFCC2KKG.js";import"./chunk-KXSJQP6J.js";import"./chunk-ZL7STHLD.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.js";import{existsSync as we,mkdirSync as B,readdirSync as he,readFileSync as be,rmSync as J,writeFileSync as I}from"fs";import{homedir as ve,tmpdir as ye}from"os";import{dirname as D,extname as oe,join as N,resolve as Se}from"path";var z=24e4,Re=3e4;async function W(e,r,o,i){let t=Math.max(2e4,i+Re);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
6
6
  releasing. the lock self-heals in ~${Math.round((i+2e4)/1e3)}s \u2014 retry then, or recover now with
7
- \`sootsim close --sim <id>\` and reopen the sim.`),process.exit(1)),console.error(` ${o} failed: ${s}`),process.exit(1)}}var $e=new Set(["--sim","--port","-p","--mode","--duration","--fps","--format","--output","-o","--frames","--max-width","--origin","--owner","--repo"]),_e=new Set(["start","stop","cancel","status","prelude-start"]);function xe(e){for(let r=0;r<e.length;r++){let o=e[r];if(o.startsWith("-")){$e.has(o)&&r++;continue}return _e.has(o)?{name:o,index:r}:null}return null}function Oe(){let e=process.env,r=(e.SOOT_BRANCH||e.GITHUB_HEAD_REF||e.GITHUB_REF_NAME||"").trim(),o=(e.SOOT_SHA||e.GITHUB_SHA||"").trim(),i=(e.SOOT_PR_NUMBER||"").trim(),t=i?Number.parseInt(i,10):Number.NaN,n=(e.SOOT_PR_TITLE||"").trim();return{branch:r||void 0,commitSha:o||void 0,pullRequestNumber:Number.isFinite(t)&&t>0?t:void 0,pullRequestTitle:n||void 0}}function re(e){let r=l(e,"--owner")?.trim(),o=l(e,"--repo")?.trim();return(r&&!o||!r&&o)&&(console.error(" --owner and --repo must be provided together"),process.exit(1)),r&&o?{owner:r,repo:o}:null}async function Ve(e,r){let o=xe(e);if(o){let c=[...e.slice(0,o.index),...e.slice(o.index+1)];if(o.name==="start"){await Te(c,r);return}if(o.name==="prelude-start"){await Ie(c,r);return}if(o.name==="stop"){await Fe(c,r);return}if(o.name==="cancel"){await Ae(c,r);return}await Ce(c,r);return}let i=b(e,{port:r.port,stripBooleanFlags:["--no-shell","--shell-only","--open"],stripValueFlags:["--mode","--duration","--fps","--format","--output","--frames","--max-width","--origin","--owner","--repo"]}),t=ie(l(e,"--mode")),n=e.includes("--shell-only")?"shell":e.includes("--no-shell")?"tenant":void 0,s=l(e,"--format");s&&!["webm","mp4","gif","png"].includes(s)&&(console.error(` invalid --format "${s}" \u2014 expected webm | mp4 | gif | png`),process.exit(1));let d=l(e,"--output"),a=Number(l(e,"--duration")??"10");(!Number.isFinite(a)||a<=0)&&(console.error(` invalid --duration "${l(e,"--duration")}" \u2014 expected a positive number of seconds`),process.exit(1));let m=1800;a>m&&(console.error(` invalid --duration "${l(e,"--duration")}" \u2014 exceeds the ${m}s (30m) maximum`),process.exit(1));let u=Number(l(e,"--fps")??"30"),p=l(e,"--frames");if(p!==void 0){let c=Number(p);(!Number.isInteger(c)||c<=0)&&(console.error(` invalid --frames "${p}" \u2014 expected a positive integer count`),process.exit(1))}let x=e.includes("--open"),j=l(e,"--max-width")?Number(l(e,"--max-width")):void 0,g=Math.max(100,Math.round(a*1e3)),K=l(e,"--origin"),pe=re(e);if(t==="live"||t==="combined"){d&&console.log(` note: --output is ignored for --mode ${t} \u2014 the recording uploads to /preview/<id>`),n&&t==="live"&&console.log(` note: --${n==="shell"?"shell-only":"no-shell"} is ignored for --mode live \u2014 live recordings capture events only, no video`),await P("record",{originOverride:K,allowGitHubAuth:!0});let c=v({...i,commandTimeoutMs:6e4});try{await q(c),await ae(c,t),t==="combined"&&await E(c),await de(c,K,pe);let $=await ce(c,t,t==="combined"?n:void 0);$.ok||(console.error(` start failed: recording store refused to start (${t})`+($.error?`: ${$.error}`:"")),process.exit(1)),console.log(` recording ${t} for ${a}s`),await new Promise(_=>setTimeout(_,g)),await le(c);let O=await ue(c);me(O,x,t)}finally{c.close()}return}let C=p?Number(p):null,S=Ee(s,d,C);x&&console.log(" note: --open is ignored for local-file capture \u2014 it applies to --mode live/combined");let h=v({...i,commandTimeoutMs:6e4});try{if(await te(h),await E(h),S==="png"){let R=C??10,w=T(d,`sootsim-frames-${U()}`);d&&oe(d)&&console.log(` note: --frames writes multiple pngs, so --output "${d}" is a directory \u2014 frame-NNN.png files land inside it`),B(w,{recursive:!0});for(let f of he(w))/^frame-\d+\.png$/.test(f)&&J(N(w,f),{force:!0});console.log(` sampling ${R} frames over ${a}s \u2192 ${w}`);let y=await h.send({type:"evaluate",code:`window.__sootsimRecorder.startFrameCapture({ count: ${R}, durationMs: ${g}${n?`, layers: ${JSON.stringify(n)}`:""} })`});(!y.ok||!y.requestId)&&(console.error(` frame capture start failed: ${y.error??"unknown error"}`),process.exit(1)),await new Promise(f=>setTimeout(f,g));let fe=Date.now()+Math.max(5e3,g),A=null;for(;;){let f=await h.send({type:"evaluate",code:`window.__sootsimRecorder.getFrameCaptureResult(${y.requestId})`});if(f||(console.error(" frame capture result missing"),process.exit(1)),f.done){f.ok||(console.error(` frame capture failed: ${f.error??"unknown error"}`),process.exit(1)),A=f.frames??[];break}Date.now()>=fe&&(console.error(" frame capture timed out"),process.exit(1)),await new Promise(F=>setTimeout(F,100))}A.forEach((f,F)=>{let ge=`${w}/frame-${String(F+1).padStart(3,"0")}.png`;I(ge,Buffer.from(f.data,"base64"))}),console.log(` saved ${A.length} frames`);return}if(S==="gif"){let R=C??Math.max(10,Math.round(a*u/3)),w=T(d,`sootsim-${U()}.gif`);B(D(w),{recursive:!0}),console.log(` encoding gif: ${R} frames over ${a}s \u2192 ${w}`);let y=await W(h,`window.__sootsimRecorder.captureGif({ frames: ${R}, durationMs: ${g}${j?`, maxWidth: ${j}`:""}${n?`, layers: ${JSON.stringify(n)}`:""} })`,"gif encode",g);y||(console.error(" gif capture returned no frames"),process.exit(1)),I(w,Buffer.from(y.data,"base64")),console.log(` saved: ${w} (${G(y.size)})`);return}let c=T(d,`sootsim-${U()}.${S}`);B(D(c),{recursive:!0});let $={format:S,fps:u,durationMs:g};n&&($.layers=n);let O=await W(h,`window.__sootsimRecorder.start(${JSON.stringify($)})`,`${S} start`,g);O.ok||(console.error(` start failed: ${O.error??"unknown error"}`),/render host not available|already streaming|already recording/i.test(O.error??"")&&console.error(" a prior recording was abandoned and its capture is still\n releasing. retry in ~20s, or recover now with\n `sootsim close --sim <id>` then reopen the sim."),process.exit(1)),console.log(` recording ${S} for ${a}s \u2192 ${c}`),await new Promise(R=>setTimeout(R,g));let _=await W(h,"window.__sootsimRecorder.stop()",`${S} encode/flush`,g);_.ok||(console.error(` stop failed: ${_.error??"unknown error"}`),process.exit(1)),_.size||(console.error(" recorder returned an empty blob \u2014 nothing written"),process.exit(1)),await ne(h,c),console.log(` saved: ${c} (${G(_.size)})`)}finally{h.close()}}var ke=6e3;async function L(e,r){try{return await e.send({type:"evaluate",code:r},{timeoutMs:ke})}catch(o){let i=o instanceof Error?o.message:String(o);throw/^command timed out after \d+s$/.test(i)&&(console.error(" sim did not respond \u2014 it is connected to the bridge but has not\n loaded an app (or its page is unresponsive). run `sootsim list`\n and target a sim with a loaded app via --sim <id>."),process.exit(1)),o}}async function te(e){await L(e,'typeof window.__sootsimRecorder !== "undefined"')||(console.error(" window.__sootsimRecorder missing \u2014 is sootsim engine running in this sim?"),process.exit(1))}async function E(e){let{hidden:r}=await Y(e);r&&(console.error(` refusing to record: the sootsim tab is hidden, so frame capture
7
+ \`sootsim close --sim <id>\` and reopen the sim.`),process.exit(1)),console.error(` ${o} failed: ${s}`),process.exit(1)}}var $e=new Set(["--sim","--port","-p","--mode","--duration","--fps","--format","--output","-o","--frames","--max-width","--origin","--owner","--repo"]),_e=new Set(["start","stop","cancel","status","prelude-start"]);function xe(e){for(let r=0;r<e.length;r++){let o=e[r];if(o.startsWith("-")){$e.has(o)&&r++;continue}return _e.has(o)?{name:o,index:r}:null}return null}function Oe(){let e=process.env,r=(e.SOOT_BRANCH||e.GITHUB_HEAD_REF||e.GITHUB_REF_NAME||"").trim(),o=(e.SOOT_SHA||e.GITHUB_SHA||"").trim(),i=(e.SOOT_PR_NUMBER||"").trim(),t=i?Number.parseInt(i,10):Number.NaN,n=(e.SOOT_PR_TITLE||"").trim();return{branch:r||void 0,commitSha:o||void 0,pullRequestNumber:Number.isFinite(t)&&t>0?t:void 0,pullRequestTitle:n||void 0}}function re(e){let r=l(e,"--owner")?.trim(),o=l(e,"--repo")?.trim();return(r&&!o||!r&&o)&&(console.error(" --owner and --repo must be provided together"),process.exit(1)),r&&o?{owner:r,repo:o}:null}async function Ve(e,r){let o=xe(e);if(o){let c=[...e.slice(0,o.index),...e.slice(o.index+1)];if(o.name==="start"){await Te(c,r);return}if(o.name==="prelude-start"){await Ie(c,r);return}if(o.name==="stop"){await Fe(c,r);return}if(o.name==="cancel"){await Ae(c,r);return}await Ce(c,r);return}let i=b(e,{port:r.port,stripBooleanFlags:["--no-shell","--shell-only","--open"],stripValueFlags:["--mode","--duration","--fps","--format","--output","--frames","--max-width","--origin","--owner","--repo"]}),t=ie(l(e,"--mode")),n=e.includes("--shell-only")?"shell":e.includes("--no-shell")?"tenant":void 0,s=l(e,"--format");s&&!["webm","mp4","gif","png"].includes(s)&&(console.error(` invalid --format "${s}" \u2014 expected webm | mp4 | gif | png`),process.exit(1));let d=l(e,"--output"),a=Number(l(e,"--duration")??"10");(!Number.isFinite(a)||a<=0)&&(console.error(` invalid --duration "${l(e,"--duration")}" \u2014 expected a positive number of seconds`),process.exit(1));let m=600;a>m&&(console.error(` invalid --duration "${l(e,"--duration")}" \u2014 exceeds the ${m}s (10m) maximum`),process.exit(1));let u=Number(l(e,"--fps")??"30"),p=l(e,"--frames");if(p!==void 0){let c=Number(p);(!Number.isInteger(c)||c<=0)&&(console.error(` invalid --frames "${p}" \u2014 expected a positive integer count`),process.exit(1))}let x=e.includes("--open"),j=l(e,"--max-width")?Number(l(e,"--max-width")):void 0,g=Math.max(100,Math.round(a*1e3)),K=l(e,"--origin"),pe=re(e);if(t==="live"||t==="combined"){d&&console.log(` note: --output is ignored for --mode ${t} \u2014 the recording uploads to /preview/<id>`),n&&t==="live"&&console.log(` note: --${n==="shell"?"shell-only":"no-shell"} is ignored for --mode live \u2014 live recordings capture events only, no video`),await P("record",{originOverride:K,allowGitHubAuth:!0});let c=v({...i,commandTimeoutMs:6e4});try{await q(c),await ae(c,t),t==="combined"&&await E(c),await de(c,K,pe);let $=await ce(c,t,t==="combined"?n:void 0);$.ok||(console.error(` start failed: recording store refused to start (${t})`+($.error?`: ${$.error}`:"")),process.exit(1)),console.log(` recording ${t} for ${a}s`),await new Promise(_=>setTimeout(_,g)),await le(c);let O=await ue(c);me(O,x,t)}finally{c.close()}return}let C=p?Number(p):null,S=Ee(s,d,C);x&&console.log(" note: --open is ignored for local-file capture \u2014 it applies to --mode live/combined");let h=v({...i,commandTimeoutMs:6e4});try{if(await te(h),await E(h),S==="png"){let R=C??10,w=T(d,`sootsim-frames-${U()}`);d&&oe(d)&&console.log(` note: --frames writes multiple pngs, so --output "${d}" is a directory \u2014 frame-NNN.png files land inside it`),B(w,{recursive:!0});for(let f of he(w))/^frame-\d+\.png$/.test(f)&&J(N(w,f),{force:!0});console.log(` sampling ${R} frames over ${a}s \u2192 ${w}`);let y=await h.send({type:"evaluate",code:`window.__sootsimRecorder.startFrameCapture({ count: ${R}, durationMs: ${g}${n?`, layers: ${JSON.stringify(n)}`:""} })`});(!y.ok||!y.requestId)&&(console.error(` frame capture start failed: ${y.error??"unknown error"}`),process.exit(1)),await new Promise(f=>setTimeout(f,g));let fe=Date.now()+Math.max(5e3,g),A=null;for(;;){let f=await h.send({type:"evaluate",code:`window.__sootsimRecorder.getFrameCaptureResult(${y.requestId})`});if(f||(console.error(" frame capture result missing"),process.exit(1)),f.done){f.ok||(console.error(` frame capture failed: ${f.error??"unknown error"}`),process.exit(1)),A=f.frames??[];break}Date.now()>=fe&&(console.error(" frame capture timed out"),process.exit(1)),await new Promise(F=>setTimeout(F,100))}A.forEach((f,F)=>{let ge=`${w}/frame-${String(F+1).padStart(3,"0")}.png`;I(ge,Buffer.from(f.data,"base64"))}),console.log(` saved ${A.length} frames`);return}if(S==="gif"){let R=C??Math.max(10,Math.round(a*u/3)),w=T(d,`sootsim-${U()}.gif`);B(D(w),{recursive:!0}),console.log(` encoding gif: ${R} frames over ${a}s \u2192 ${w}`);let y=await W(h,`window.__sootsimRecorder.captureGif({ frames: ${R}, durationMs: ${g}${j?`, maxWidth: ${j}`:""}${n?`, layers: ${JSON.stringify(n)}`:""} })`,"gif encode",g);y||(console.error(" gif capture returned no frames"),process.exit(1)),I(w,Buffer.from(y.data,"base64")),console.log(` saved: ${w} (${G(y.size)})`);return}let c=T(d,`sootsim-${U()}.${S}`);B(D(c),{recursive:!0});let $={format:S,fps:u,durationMs:g};n&&($.layers=n);let O=await W(h,`window.__sootsimRecorder.start(${JSON.stringify($)})`,`${S} start`,g);O.ok||(console.error(` start failed: ${O.error??"unknown error"}`),/render host not available|already streaming|already recording/i.test(O.error??"")&&console.error(" a prior recording was abandoned and its capture is still\n releasing. retry in ~20s, or recover now with\n `sootsim close --sim <id>` then reopen the sim."),process.exit(1)),console.log(` recording ${S} for ${a}s \u2192 ${c}`),await new Promise(R=>setTimeout(R,g));let _=await W(h,"window.__sootsimRecorder.stop()",`${S} encode/flush`,g);_.ok||(console.error(` stop failed: ${_.error??"unknown error"}`),process.exit(1)),_.size||(console.error(" recorder returned an empty blob \u2014 nothing written"),process.exit(1)),await ne(h,c),console.log(` saved: ${c} (${G(_.size)})`)}finally{h.close()}}var ke=6e3;async function L(e,r){try{return await e.send({type:"evaluate",code:r},{timeoutMs:ke})}catch(o){let i=o instanceof Error?o.message:String(o);throw/^command timed out after \d+s$/.test(i)&&(console.error(" sim did not respond \u2014 it is connected to the bridge but has not\n loaded an app (or its page is unresponsive). run `sootsim list`\n and target a sim with a loaded app via --sim <id>."),process.exit(1)),o}}async function te(e){await L(e,'typeof window.__sootsimRecorder !== "undefined"')||(console.error(" window.__sootsimRecorder missing \u2014 is sootsim engine running in this sim?"),process.exit(1))}async function E(e){let{hidden:r}=await Y(e);r&&(console.error(` refusing to record: the sootsim tab is hidden, so frame capture
8
8
  would be throttled to ~1fps and produce a frozen-looking file.
9
9
  bring the chrome window to the foreground (un-minimize / switch to
10
10
  its tab) or run the recording in headless playwright, then retry.`),process.exit(1))}async function ne(e,r){let o=[],i=0;for(;;){let t=await e.send({type:"evaluate",code:`window.__sootsimRecorder.getBlobBase64({ offset: ${i}, chunk: 2097152 })`});if(!t)throw new Error("no blob available on recorder");if(o.push(Buffer.from(t.data,"base64")),i=t.offset,t.done)break}I(r,Buffer.concat(o))}function l(e,r){let o=e.indexOf(r);if(!(o<0||o===e.length-1))return e[o+1]}function Be(e){if(!e)return;let r=oe(e).toLowerCase().replace(/^\./,"");if(r==="webm"||r==="mp4"||r==="gif")return r;if(r==="png")return"png"}function Ee(e,r,o){return e||(o!=null?"png":Be(r)??"webm")}function U(){return new Date().toISOString().replace(/[:T]/g,"-").replace(/\..+/,"")}function Me(){let e=N(ve(),".sootsim","recordings");return B(e,{recursive:!0}),e}function T(e,r){return e?Se(process.cwd(),e):N(Me(),r)}function G(e){return e<1024?`${e}B`:e<1024*1024?`${(e/1024).toFixed(1)}KB`:`${(e/(1024*1024)).toFixed(2)}MB`}function ie(e){if(!e)return"video";if(e==="video"||e==="live"||e==="combined")return e;console.error(` invalid --mode "${e}" \u2014 expected video | live | combined`),process.exit(1)}function H(){return N(ye(),`sootsim-recording-${Q()}.json`)}function M(){let e=H();if(!we(e))return null;try{return{mode:"video",...JSON.parse(be(e,"utf8"))}}catch{return J(e,{force:!0}),null}}function Ue(e){I(H(),JSON.stringify(e,null,2))}function k(){J(H(),{force:!0})}function V(e,r){e&&r.simId&&e!==r.simId&&console.log(` note: the tracked recording session is on sim ${r.simId}, not the
@@ -0,0 +1,2 @@
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a,b}from"./chunk-AUR7DDPB.js";import"./chunk-ZV3W66US.js";import"./chunk-GYK5RCAC.js";import"./chunk-ZL7STHLD.js";import"./chunk-F4W6VKRG.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.js";export{b as formatReleaseEntry,a as runRuntime};
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a,b,c,d,e,f,g,h,i,j,k,l,m,n}from"./chunk-7OVVG4L6.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.js";export{a as DEFAULT_RUNTIME_CDN_ORIGIN,b as RUNTIME_CDN_ORIGIN_ENV,c as RUNTIME_CHANNEL_ENV,n as checkRuntimeUpToDate,h as fetchRuntimeManifest,j as fetchRuntimeReleases,l as installRuntime,d as resolveRuntimeCdnOrigin,e as resolveRuntimeChannel,k as resolveRuntimeVersion,f as runtimeManifestUrl,i as runtimeReleasesUrl,g as runtimeTarballUrl,m as updateRuntimeToLatest};
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a,b,c,d,e,f,g,h,i,j,k,l,m,n}from"./chunk-F4W6VKRG.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.js";export{a as DEFAULT_RUNTIME_CDN_ORIGIN,b as RUNTIME_CDN_ORIGIN_ENV,c as RUNTIME_CHANNEL_ENV,n as checkRuntimeUpToDate,h as fetchRuntimeManifest,j as fetchRuntimeReleases,l as installRuntime,d as resolveRuntimeCdnOrigin,e as resolveRuntimeChannel,k as resolveRuntimeVersion,f as runtimeManifestUrl,i as runtimeReleasesUrl,g as runtimeTarballUrl,m as updateRuntimeToLatest};
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as S}from"./chunk-M6ML3LBZ.js";import"./chunk-EGFZLSP4.js";import{a as b}from"./chunk-5GQJWYO7.js";import{c as g,d as w,e as y,f as v,h as x}from"./chunk-J27RHTWH.js";import"./chunk-366ZIBQX.js";import"./chunk-3MKNANBV.js";import"./chunk-UQHBJ2L2.js";import"./chunk-6NW6PC3P.js";import{f as m}from"./chunk-6PKYLQ36.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.js";import{mkdirSync as A,writeFileSync as R}from"fs";import{dirname as E,resolve as F}from"path";async function J(t,o){let e=U(t);(e.includes("--help")||e.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as S}from"./chunk-Q5YWPKAG.js";import"./chunk-X5LIH464.js";import{a as b}from"./chunk-HQ5JZI67.js";import{c as g,d as w,e as y,f as v,h as x}from"./chunk-ZV3W66US.js";import"./chunk-GYK5RCAC.js";import"./chunk-EESOIR2B.js";import"./chunk-ZL7STHLD.js";import"./chunk-TJLVKZJQ.js";import{f as m}from"./chunk-WH3M4U2P.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.js";import{mkdirSync as A,writeFileSync as R}from"fs";import{dirname as E,resolve as F}from"path";async function J(t,o){let e=U(t);(e.includes("--help")||e.includes("-h"))&&(console.log(`
3
3
  sootsim screenshot \u2014 capture the canvas as a PNG
4
4
 
5
5
  usage:
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as o}from"./chunk-S5KZH7JJ.js";import"./chunk-J27RHTWH.js";import"./chunk-366ZIBQX.js";import"./chunk-UQHBJ2L2.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.js";async function n(e,s){(e.includes("--help")||e.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{a as o}from"./chunk-E7GET25R.js";import"./chunk-ZV3W66US.js";import"./chunk-GYK5RCAC.js";import"./chunk-ZL7STHLD.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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.122 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{b as Y}from"./chunk-BII2H2BR.js";import{b as j}from"./chunk-M6ML3LBZ.js";import"./chunk-EGFZLSP4.js";import"./chunk-ITGWJM6W.js";import"./chunk-QD5YATLL.js";import"./chunk-7AXDJ2RV.js";import{b as O}from"./chunk-AK2PW7XZ.js";import"./chunk-2XDZ42A6.js";import"./chunk-V4OEITZA.js";import"./chunk-G6Z5E4KX.js";import"./chunk-RBWDMEWN.js";import"./chunk-SUQAFFJO.js";import"./chunk-J27RHTWH.js";import"./chunk-36BDR3DE.js";import"./chunk-S2RR2IZC.js";import"./chunk-LYZ3GSCB.js";import"./chunk-NIL4WJUK.js";import"./chunk-IRSVHE5W.js";import"./chunk-366ZIBQX.js";import"./chunk-3BCXNVBN.js";import"./chunk-VHPYIZ3U.js";import"./chunk-3MKNANBV.js";import"./chunk-KWXV47VS.js";import"./chunk-UQHBJ2L2.js";import"./chunk-6NW6PC3P.js";import{a as w,b as D,c as k,d as z,e as x,f as T}from"./chunk-6PKYLQ36.js";import"./chunk-T2YYBRII.js";import"./chunk-IBEQOTJK.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)";case"straight":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.124 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{b as Y}from"./chunk-J67NC7MV.js";import{b as j}from"./chunk-Q5YWPKAG.js";import"./chunk-X5LIH464.js";import"./chunk-QG4GIDXL.js";import"./chunk-OPWN5ZM7.js";import"./chunk-2IT7O7KQ.js";import{b as O}from"./chunk-I4F7AUP2.js";import"./chunk-KBFPZMXJ.js";import"./chunk-TUZCEXOT.js";import"./chunk-G6G5LYD3.js";import"./chunk-TJUPANGE.js";import"./chunk-LTHY7I3V.js";import"./chunk-ZV3W66US.js";import"./chunk-NQZCZVNZ.js";import"./chunk-A5O2QWEB.js";import"./chunk-66ETIVOD.js";import"./chunk-R7R5HWAT.js";import"./chunk-DCZGWL5K.js";import"./chunk-GYK5RCAC.js";import"./chunk-YFCC2KKG.js";import"./chunk-KXSJQP6J.js";import"./chunk-EESOIR2B.js";import"./chunk-JUX2JKSR.js";import"./chunk-ZL7STHLD.js";import"./chunk-TJLVKZJQ.js";import{a as w,b as D,c as k,d as z,e as x,f as T}from"./chunk-WH3M4U2P.js";import"./chunk-2JTGXU4D.js";import"./chunk-KTRDHNPZ.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)";case"straight":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" />