sootsim 0.1.98 → 0.1.99

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 (144) hide show
  1. package/dist-cli/bin.js +3 -3
  2. package/dist-cli/chunks/{agent-AV7UQHGA.js → agent-FRLHFA7O.js} +2 -2
  3. package/dist-cli/chunks/{agent-wrapper-5W2PDZZX.js → agent-wrapper-PGM74DGK.js} +2 -2
  4. package/dist-cli/chunks/{assert-QCTKI4I6.js → assert-SZHEMF7T.js} +2 -2
  5. package/dist-cli/chunks/auto-bootstrap-AI5R4WGI.js +2 -0
  6. package/dist-cli/chunks/beta-WOHNLNX4.js +2 -0
  7. package/dist-cli/chunks/{chunk-36JO37LQ.js → chunk-3JAOZ6SY.js} +1 -1
  8. package/dist-cli/chunks/{chunk-ZIFZANWB.js → chunk-3YEWVBCW.js} +1 -1
  9. package/dist-cli/chunks/{chunk-ISIO4SR2.js → chunk-55M3WRUQ.js} +2 -2
  10. package/dist-cli/chunks/{chunk-6UGXIH6X.js → chunk-5O5EKOMJ.js} +2 -2
  11. package/dist-cli/chunks/{chunk-J2XMTE4K.js → chunk-6UQTZIUA.js} +2 -2
  12. package/dist-cli/chunks/{chunk-PZQVLWTL.js → chunk-6X5QLXOH.js} +2 -2
  13. package/dist-cli/chunks/{chunk-FNG7EEFU.js → chunk-6YPGG2TW.js} +2 -2
  14. package/dist-cli/chunks/{chunk-V3VDLHQ6.js → chunk-7XWCZ7SL.js} +2 -2
  15. package/dist-cli/chunks/{chunk-JE5YNG3L.js → chunk-AHZFERZ5.js} +1 -1
  16. package/dist-cli/chunks/{chunk-ZZKSTNCP.js → chunk-C5H3YWJD.js} +2 -2
  17. package/dist-cli/chunks/{chunk-Q4OS7YTL.js → chunk-CK746JAM.js} +3 -3
  18. package/dist-cli/chunks/{chunk-KJUP4MG5.js → chunk-CWDGYKLF.js} +1 -1
  19. package/dist-cli/chunks/{chunk-5GQR5BJ7.js → chunk-CWQSVRO6.js} +2 -2
  20. package/dist-cli/chunks/{chunk-L76C6UV4.js → chunk-EY623SM2.js} +1 -1
  21. package/dist-cli/chunks/{chunk-3QFEGZJA.js → chunk-F7PFPN2E.js} +1 -1
  22. package/dist-cli/chunks/chunk-FBFKGOHZ.js +1 -0
  23. package/dist-cli/chunks/chunk-GILWNDUQ.js +2 -0
  24. package/dist-cli/chunks/chunk-HMZEAZ24.js +1 -0
  25. package/dist-cli/chunks/{chunk-PH4GQWKG.js → chunk-JIU73CDT.js} +1 -1
  26. package/dist-cli/chunks/{chunk-55ZUACVB.js → chunk-JNF7362C.js} +2 -2
  27. package/dist-cli/chunks/{chunk-ZCV4Z3DO.js → chunk-KBSL524T.js} +2 -2
  28. package/dist-cli/chunks/chunk-MBJEHEBV.js +2 -0
  29. package/dist-cli/chunks/{chunk-BQR62XGM.js → chunk-MQUVTPGH.js} +1 -1
  30. package/dist-cli/chunks/{chunk-3RW36LEF.js → chunk-N3L4Z4VW.js} +2 -2
  31. package/dist-cli/chunks/chunk-N4PZHAUK.js +1 -0
  32. package/dist-cli/chunks/{chunk-YVPVF26I.js → chunk-NYJMVX7H.js} +1 -1
  33. package/dist-cli/chunks/{chunk-RP7NLZ26.js → chunk-ORD337AW.js} +2 -2
  34. package/dist-cli/chunks/{chunk-SNP2YECI.js → chunk-PULTHGDZ.js} +1 -1
  35. package/dist-cli/chunks/{chunk-DZYZQCET.js → chunk-PVVRIV4S.js} +2 -2
  36. package/dist-cli/chunks/{chunk-GFIXAGFA.js → chunk-PVZHEZSO.js} +1 -1
  37. package/dist-cli/chunks/{chunk-CLEO4DEV.js → chunk-RJYQUUE7.js} +2 -2
  38. package/dist-cli/chunks/{chunk-LWUHOZLQ.js → chunk-TAPEJKGG.js} +1 -1
  39. package/dist-cli/chunks/{chunk-VAMD4BL3.js → chunk-THJRUIOX.js} +3 -3
  40. package/dist-cli/chunks/{chunk-RVEZYFCE.js → chunk-THTKBQTR.js} +2 -2
  41. package/dist-cli/chunks/{chunk-MGZKAJV6.js → chunk-TXW4TZVG.js} +2 -2
  42. package/dist-cli/chunks/{chunk-Z5VQYEPL.js → chunk-UCJ3W4SE.js} +3 -3
  43. package/dist-cli/chunks/{chunk-ERDQVO6E.js → chunk-UMZDMPR3.js} +2 -2
  44. package/dist-cli/chunks/{chunk-UHQCVRXY.js → chunk-UTBM7KTJ.js} +1 -1
  45. package/dist-cli/chunks/{chunk-DLENSNEY.js → chunk-UYMLMK6L.js} +2 -2
  46. package/dist-cli/chunks/{chunk-S5IHTZL6.js → chunk-WQWDTQYG.js} +2 -2
  47. package/dist-cli/chunks/{chunk-I43WF32H.js → chunk-XI6NGTUM.js} +1 -1
  48. package/dist-cli/chunks/{chunk-JTBFEQH4.js → chunk-YI6LL2WK.js} +2 -2
  49. package/dist-cli/chunks/{chunk-5WAGGDFQ.js → chunk-YLYJIK7A.js} +1 -1
  50. package/dist-cli/chunks/{chunk-F2WCFGRK.js → chunk-ZBZBID4D.js} +2 -2
  51. package/dist-cli/chunks/cli-version-VKOUVCC4.js +2 -0
  52. package/dist-cli/chunks/{compat-NUHFYRSF.js → compat-TVJCJ34F.js} +3 -3
  53. package/dist-cli/chunks/{config-S6TVKOQJ.js → config-CMUGNG25.js} +2 -2
  54. package/dist-cli/chunks/{control-UZNJNYVG.js → control-E4T7L633.js} +2 -2
  55. package/dist-cli/chunks/{cpu-profile-XU4UXBGY.js → cpu-profile-IQPK6SJM.js} +2 -2
  56. package/dist-cli/chunks/{daemon-SYFY7U2Q.js → daemon-LWKCA22S.js} +2 -2
  57. package/dist-cli/chunks/{debug-S2KZ7ZZ4.js → debug-PN2YPNNI.js} +3 -3
  58. package/dist-cli/chunks/{detox-F5FVX7BH.js → detox-VGAKCOQU.js} +2 -2
  59. package/dist-cli/chunks/{device-UKDPJDNQ.js → device-NTABM3ML.js} +2 -2
  60. package/dist-cli/chunks/{diagnose-SHADVUWO.js → diagnose-OXKEHG7B.js} +2 -2
  61. package/dist-cli/chunks/drivers-NULC7FFQ.js +2 -0
  62. package/dist-cli/chunks/{electron-WIZUNPGZ.js → electron-T2VJKTFJ.js} +3 -3
  63. package/dist-cli/chunks/flow-YGNWLD2A.js +2 -0
  64. package/dist-cli/chunks/help-JHVDLNXW.js +2 -0
  65. package/dist-cli/chunks/{hints-ANBJHAN3.js → hints-PK7IJDZU.js} +2 -2
  66. package/dist-cli/chunks/{home-paths-OUI7LTGB.js → home-paths-5Y737ZVL.js} +2 -2
  67. package/dist-cli/chunks/{inspect-6AIEW43W.js → inspect-UBKCSZBM.js} +3 -3
  68. package/dist-cli/chunks/install-ZOZVAVYY.js +2 -0
  69. package/dist-cli/chunks/{install-desktop-4AZ2JWLE.js → install-desktop-ZXQ5WDII.js} +3 -3
  70. package/dist-cli/chunks/{keys-XZX57JNB.js → keys-5PJKPC7I.js} +2 -2
  71. package/dist-cli/chunks/{launch-RQZQV7UR.js → launch-FQQYHDRJ.js} +3 -3
  72. package/dist-cli/chunks/{login-DW5NMQZP.js → login-XKN4KFKG.js} +4 -4
  73. package/dist-cli/chunks/{logout-ADR77ELR.js → logout-JAV4KNVG.js} +2 -2
  74. package/dist-cli/chunks/{maestro-SUVQXANM.js → maestro-G2HCMZ5Z.js} +2 -2
  75. package/dist-cli/chunks/{preview-CKCO2N4V.js → preview-M6J7A2BB.js} +2 -2
  76. package/dist-cli/chunks/{profile-5DA3PCBY.js → profile-PCGDJ4OL.js} +2 -2
  77. package/dist-cli/chunks/{react-Z2RWJFRM.js → react-RFHZXELV.js} +2 -2
  78. package/dist-cli/chunks/{record-CVEAYVH7.js → record-GADTRQK5.js} +2 -2
  79. package/dist-cli/chunks/runtime-SKN5EFB4.js +2 -0
  80. package/dist-cli/chunks/{runtime-delivery-KPATO3DV.js → runtime-delivery-EFIF3XJI.js} +2 -2
  81. package/dist-cli/chunks/{screenshot-WVJT2TDY.js → screenshot-DB4XYQGP.js} +2 -2
  82. package/dist-cli/chunks/{screenshot-mode-OLKM4SDV.js → screenshot-mode-A3JCEB5V.js} +2 -2
  83. package/dist-cli/chunks/{screenshots-FTRBR6KJ.js → screenshots-ZVDLSBWH.js} +2 -2
  84. package/dist-cli/chunks/{server-JZOLCNYX.js → server-YGNXBQTO.js} +10 -10
  85. package/dist-cli/chunks/setup-repo-IZLJN26N.js +2 -0
  86. package/dist-cli/chunks/{skills-JUTRDTBM.js → skills-63TWUEWN.js} +2 -2
  87. package/dist-cli/chunks/{start-TFEX2AGE.js → start-57ZETJ7T.js} +4 -4
  88. package/dist-cli/chunks/store-7244VCM7.js +2 -0
  89. package/dist-cli/chunks/telemetry-MHTGW7IU.js +2 -0
  90. package/dist-cli/chunks/{test-GDQFRLG5.js → test-UVMR4HW4.js} +3 -3
  91. package/dist-cli/chunks/{three-mode-KEJUXBNY.js → three-mode-GHRYSPIP.js} +2 -2
  92. package/dist-cli/chunks/{timeline-I6GKU236.js → timeline-AHQTYOGW.js} +2 -2
  93. package/dist-cli/chunks/{upgrade-5DN5DOY6.js → upgrade-6N4WIHB3.js} +2 -2
  94. package/dist-cli/chunks/upload-M2QRY3MT.js +2 -0
  95. package/dist-cli/chunks/{web-TWR5HOUF.js → web-GWVV2MDT.js} +2 -2
  96. package/dist-cli/chunks/{what-happened-UY5JDEKR.js → what-happened-4VKIKJES.js} +2 -2
  97. package/dist-cli/chunks/{whoami-6C56SNN6.js → whoami-JODFPJAO.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/beta.cjs +1 -1
  105. package/dist-lib/beta.mjs +1 -1
  106. package/dist-lib/bridge-constants.cjs +63 -3
  107. package/dist-lib/cli-constants.cjs +1 -1
  108. package/dist-lib/config.cjs +1 -1
  109. package/dist-lib/detox/index.cjs +1 -1
  110. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  111. package/dist-lib/home-paths.cjs +1 -1
  112. package/dist-lib/host/bridge-host.cjs +1 -1
  113. package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
  114. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  115. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  116. package/dist-lib/host/websocket-proxy.cjs +1 -1
  117. package/dist-lib/index.cjs +1 -1
  118. package/dist-lib/metro.cjs +1 -1
  119. package/dist-lib/profiles.cjs +1 -1
  120. package/dist-lib/render-mode.cjs +1 -1
  121. package/dist-lib/scripts/demo-app-registry.cjs +1 -1
  122. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  123. package/dist-lib/skills.cjs +60 -3
  124. package/dist-lib/vite.cjs +1 -1
  125. package/package.json +1 -1
  126. package/src/bridge-constants.ts +77 -0
  127. package/src/vite-plugin.ts +7 -2
  128. package/dist-cli/chunks/auto-bootstrap-ZD2JO3X2.js +0 -2
  129. package/dist-cli/chunks/beta-LV2FJWCK.js +0 -2
  130. package/dist-cli/chunks/chunk-4IZWBEOU.js +0 -2
  131. package/dist-cli/chunks/chunk-4QCN4DMR.js +0 -1
  132. package/dist-cli/chunks/chunk-CBTPTUJA.js +0 -1
  133. package/dist-cli/chunks/chunk-LSPJL5XI.js +0 -1
  134. package/dist-cli/chunks/chunk-POQEZLEI.js +0 -2
  135. package/dist-cli/chunks/cli-version-XZIL5X5T.js +0 -2
  136. package/dist-cli/chunks/drivers-WHUFSQK6.js +0 -2
  137. package/dist-cli/chunks/flow-L54IDEQT.js +0 -2
  138. package/dist-cli/chunks/help-ORII3NB6.js +0 -2
  139. package/dist-cli/chunks/install-TYZARIPO.js +0 -2
  140. package/dist-cli/chunks/runtime-DSZU6QQH.js +0 -2
  141. package/dist-cli/chunks/setup-repo-7EXOSCGC.js +0 -2
  142. package/dist-cli/chunks/store-7GCZMEN5.js +0 -2
  143. package/dist-cli/chunks/telemetry-FE3PJGFM.js +0 -2
  144. package/dist-cli/chunks/upload-WYMSDACQ.js +0 -2
@@ -1,5 +1,5 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{A as T,B as y,M as x,z as F}from"./chunk-ZIFZANWB.js";import{c as S,e as N}from"./chunk-6UGXIH6X.js";import{b as k}from"./chunk-JE5YNG3L.js";import"./chunk-POQEZLEI.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";function _(n){let e=[];for(let t=0;t<n.length;t++)if(n[t]==="--since"&&t+1<n.length){e.push(t,t+1);let s=n[t+1].trim(),l=/^(\d+(?:\.\d+)?)(ms|s|m)?$/.exec(s);if(l){let a=Number(l[1]),m=l[2]??"ms",$=m==="s"?a*1e3:m==="m"?a*6e4:a;return{since:Date.now()-$,consumed:e}}let o=Number(s);if(Number.isFinite(o)&&o>1e12)return{since:o,consumed:e}}return{consumed:e}}function K(n){let e=[];for(let t=0;t<n.length;t++)if(n[t]==="--kinds"&&t+1<n.length)return e.push(t,t+1),{kinds:n[t+1].split(",").map(s=>s.trim()).filter(Boolean),consumed:e};return{consumed:e}}function O(n){let e=[];for(let t=0;t<n.length;t++)if(n[t]==="--limit"&&t+1<n.length){e.push(t,t+1);let s=Number(n[t+1]);if(Number.isFinite(s)&&s>0)return{limit:s,consumed:e}}return{consumed:e}}function j(n,e){if(e===null)return new Date(n).toLocaleTimeString();let t=(n-e)/1e3;return`${t>=0?"+":""}${t.toFixed(2)}s`}function B(n,e){switch(n){case"app-launch":return e.phase==="launch"?`launch ${e.appName??e.toAppId??""}`:`dismiss ${e.appName??e.fromAppId??""} \u2192 ${e.toAppId??""}`;case"toast":return`"${e.text??""}"${e.durationMs?` (${e.durationMs}ms)`:""}`;case"keyboard":return`${e.phase??"?"}${e.heightPx?` h=${e.heightPx}`:""}${e.mode?` ${e.mode}`:""}`;case"screen":return`${e.phase??"?"} ${e.name??e.activeName??""}`;case"route":return`${e.phase??"?"} ${e.path??e.pathname??""}`;case"alert":case"actionsheet":case"picker":return`${e.phase??"?"} ${e.title??e.message??""}`;case"notification":return`${e.title??""}${e.body?` \u2014 ${e.body}`:""}`;case"fetch":return`${e.method??"GET"} ${e.url??""}${e.status?` -> ${e.status}`:""}`;case"console":return`${e.level??"log"}: ${(e.message??"").toString().slice(0,120)}`;case"shell":return`${e.event??e.type??e.phase??""}`;case"scroll":return`${e.phase??"?"} ${e.target??""}`;case"gesture":return`${e.phase??"?"} ${e.type??""}`;case"text-input":return`${e.phase??"?"}${e.value!==void 0?` "${String(e.value).slice(0,40)}"`:""}`;case"layout":return`${e.kind??"?"} ${e.testID??e.type??""}${e.skipped?` skipped:${e.reason??"unknown"}`:""}`;case"react-commit":{let t=e.slowest;return`${e.fiberCount??"?"} fibers ${e.durationMs??"?"}ms${t?.displayName?` \xB7 ${t.displayName} ${t.durationMs??"?"}ms`:""}`}case"reanimated":case"animation":return`${e.kind??""} ${e.target??""}${e.durationMs?` ${e.durationMs}ms`:""}`}}function A(n,e){let t=j(n.t,e).padStart(8),s=n.context.padEnd(6),l=`[${n.kind}]`.padEnd(15),o="",a=n.data;return a&&typeof a=="object"&&(o=B(n.kind,a)),` ${t} ${s} ${l} ${o}`}function M(n){let e=[],t={label:"initial state",events:[],startedAt:n[0]?.t??null};e.push(t);for(let s of n)if(t.events.push(s),s.kind==="screen"||s.kind==="route"){let l=s.data,o=l?.phase;if(!o||o==="enter"||o==="appear"||o==="active"){let a=l?.name||l?.activeName||l?.path||l?.pathname||s.kind;e.length===1&&t.events.length===1?t.label=`${s.kind}: ${a}`:(t={label:`${s.kind}: ${a}`,events:[],startedAt:s.t},e.push(t))}}return e}async function J(n,e){let t=S(n,{port:e.port,stripBooleanFlags:["--summary","--all","--json","--no-advance","--help","-h","--flow","--noisy"],stripValueFlags:["--since","--kinds","--limit"]});(n.includes("--help")||n.includes("-h"))&&(console.log(`
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{A as T,B as y,M as x,z as F}from"./chunk-3YEWVBCW.js";import{c as S,e as N}from"./chunk-5O5EKOMJ.js";import{b as k}from"./chunk-AHZFERZ5.js";import"./chunk-GILWNDUQ.js";import"./chunk-CWDGYKLF.js";import"./chunk-UTBM7KTJ.js";function _(n){let e=[];for(let t=0;t<n.length;t++)if(n[t]==="--since"&&t+1<n.length){e.push(t,t+1);let s=n[t+1].trim(),l=/^(\d+(?:\.\d+)?)(ms|s|m)?$/.exec(s);if(l){let a=Number(l[1]),m=l[2]??"ms",$=m==="s"?a*1e3:m==="m"?a*6e4:a;return{since:Date.now()-$,consumed:e}}let o=Number(s);if(Number.isFinite(o)&&o>1e12)return{since:o,consumed:e}}return{consumed:e}}function K(n){let e=[];for(let t=0;t<n.length;t++)if(n[t]==="--kinds"&&t+1<n.length)return e.push(t,t+1),{kinds:n[t+1].split(",").map(s=>s.trim()).filter(Boolean),consumed:e};return{consumed:e}}function O(n){let e=[];for(let t=0;t<n.length;t++)if(n[t]==="--limit"&&t+1<n.length){e.push(t,t+1);let s=Number(n[t+1]);if(Number.isFinite(s)&&s>0)return{limit:s,consumed:e}}return{consumed:e}}function j(n,e){if(e===null)return new Date(n).toLocaleTimeString();let t=(n-e)/1e3;return`${t>=0?"+":""}${t.toFixed(2)}s`}function B(n,e){switch(n){case"app-launch":return e.phase==="launch"?`launch ${e.appName??e.toAppId??""}`:`dismiss ${e.appName??e.fromAppId??""} \u2192 ${e.toAppId??""}`;case"toast":return`"${e.text??""}"${e.durationMs?` (${e.durationMs}ms)`:""}`;case"keyboard":return`${e.phase??"?"}${e.heightPx?` h=${e.heightPx}`:""}${e.mode?` ${e.mode}`:""}`;case"screen":return`${e.phase??"?"} ${e.name??e.activeName??""}`;case"route":return`${e.phase??"?"} ${e.path??e.pathname??""}`;case"alert":case"actionsheet":case"picker":return`${e.phase??"?"} ${e.title??e.message??""}`;case"notification":return`${e.title??""}${e.body?` \u2014 ${e.body}`:""}`;case"fetch":return`${e.method??"GET"} ${e.url??""}${e.status?` -> ${e.status}`:""}`;case"console":return`${e.level??"log"}: ${(e.message??"").toString().slice(0,120)}`;case"shell":return`${e.event??e.type??e.phase??""}`;case"scroll":return`${e.phase??"?"} ${e.target??""}`;case"gesture":return`${e.phase??"?"} ${e.type??""}`;case"text-input":return`${e.phase??"?"}${e.value!==void 0?` "${String(e.value).slice(0,40)}"`:""}`;case"layout":return`${e.kind??"?"} ${e.testID??e.type??""}${e.skipped?` skipped:${e.reason??"unknown"}`:""}`;case"react-commit":{let t=e.slowest;return`${e.fiberCount??"?"} fibers ${e.durationMs??"?"}ms${t?.displayName?` \xB7 ${t.displayName} ${t.durationMs??"?"}ms`:""}`}case"reanimated":case"animation":return`${e.kind??""} ${e.target??""}${e.durationMs?` ${e.durationMs}ms`:""}`}}function A(n,e){let t=j(n.t,e).padStart(8),s=n.context.padEnd(6),l=`[${n.kind}]`.padEnd(15),o="",a=n.data;return a&&typeof a=="object"&&(o=B(n.kind,a)),` ${t} ${s} ${l} ${o}`}function M(n){let e=[],t={label:"initial state",events:[],startedAt:n[0]?.t??null};e.push(t);for(let s of n)if(t.events.push(s),s.kind==="screen"||s.kind==="route"){let l=s.data,o=l?.phase;if(!o||o==="enter"||o==="appear"||o==="active"){let a=l?.name||l?.activeName||l?.path||l?.pathname||s.kind;e.length===1&&t.events.length===1?t.label=`${s.kind}: ${a}`:(t={label:`${s.kind}: ${a}`,events:[],startedAt:s.t},e.push(t))}}return e}async function J(n,e){let t=S(n,{port:e.port,stripBooleanFlags:["--summary","--all","--json","--no-advance","--help","-h","--flow","--noisy"],stripValueFlags:["--since","--kinds","--limit"]});(n.includes("--help")||n.includes("-h"))&&(console.log(`
3
3
  sootsim what-happened \u2014 show recent events from the semantic timeline
4
4
 
5
5
  usage:
@@ -1,2 +1,2 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{d as i}from"./chunk-S5IHTZL6.js";import{d as n}from"./chunk-ERDQVO6E.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";async function u(){let o=i();if(o||(console.log(" not signed in"),console.log(" set SOOTSIM_API_KEY=sk_sootsim_\u2026 or run `sootsim login`"),process.exit(1)),o.kind==="api-key"){let r=`${o.secret.slice(0,14)}\u2026`,t=o.source==="env"?"SOOTSIM_API_KEY env var":"saved key (~/.config/sootsim/credentials.json)";console.log(` api key ${r}`),console.log(` source: ${t}`);return}if(o.kind==="github"){console.log(` github token (${o.source})`),console.log(` repo: ${o.repoId}`);return}let e=await n(),s=e?.user;console.log(` ${s?.email||s?.name||s?.id||"signed in"}`),console.log(` origin: ${e?.origin??o.origin}`),e?.updatedAt&&console.log(` updated: ${e.updatedAt}`)}export{u as runWhoami};
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ import{d as i}from"./chunk-WQWDTQYG.js";import{d as n}from"./chunk-UMZDMPR3.js";import"./chunk-CWDGYKLF.js";import"./chunk-UTBM7KTJ.js";async function u(){let o=i();if(o||(console.log(" not signed in"),console.log(" set SOOTSIM_API_KEY=sk_sootsim_\u2026 or run `sootsim login`"),process.exit(1)),o.kind==="api-key"){let r=`${o.secret.slice(0,14)}\u2026`,t=o.source==="env"?"SOOTSIM_API_KEY env var":"saved key (~/.config/sootsim/credentials.json)";console.log(` api key ${r}`),console.log(` source: ${t}`);return}if(o.kind==="github"){console.log(` github token (${o.source})`),console.log(` repo: ${o.repoId}`);return}let e=await n(),s=e?.user;console.log(` ${s?.email||s?.name||s?.id||"signed in"}`),console.log(` origin: ${e?.origin??o.origin}`),e?.updatedAt&&console.log(` updated: ${e.updatedAt}`)}export{u as runWhoami};
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
package/dist-lib/beta.cjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
package/dist-lib/beta.mjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/beta.ts
4
4
  var IS_BETA = true;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -24,15 +24,75 @@ var bridge_constants_exports = {};
24
24
  __export(bridge_constants_exports, {
25
25
  DEFAULT_SOOTSIM_BRIDGE_PORT: () => DEFAULT_SOOTSIM_BRIDGE_PORT,
26
26
  SOOTSIM_BRIDGE_SIM_CLOSE_CODE: () => SOOTSIM_BRIDGE_SIM_CLOSE_CODE,
27
- SOOTSIM_BRIDGE_SIM_CLOSE_REASON: () => SOOTSIM_BRIDGE_SIM_CLOSE_REASON
27
+ SOOTSIM_BRIDGE_SIM_CLOSE_REASON: () => SOOTSIM_BRIDGE_SIM_CLOSE_REASON,
28
+ resolveSootsimBridgePort: () => resolveSootsimBridgePort,
29
+ resolveSootsimBridgePortForHttpPort: () => resolveSootsimBridgePortForHttpPort,
30
+ resolveSootsimBridgePortForRuntimeLocation: () => resolveSootsimBridgePortForRuntimeLocation
28
31
  });
29
32
  module.exports = __toCommonJS(bridge_constants_exports);
30
33
  var DEFAULT_SOOTSIM_BRIDGE_PORT = 7668;
34
+ function parsePort(value) {
35
+ if (typeof value === "number") {
36
+ return Number.isInteger(value) && value > 0 ? value : null;
37
+ }
38
+ if (typeof value !== "string") return null;
39
+ const trimmed = value.trim();
40
+ if (!trimmed) return null;
41
+ const parsed = Number(trimmed);
42
+ return Number.isInteger(parsed) && parsed > 0 ? parsed : null;
43
+ }
44
+ function parsePortOffset(value) {
45
+ const parsed = parsePort(value);
46
+ return parsed === null ? 0 : parsed;
47
+ }
48
+ function resolveSootsimBridgePort(input = {}) {
49
+ const explicitPort = parsePort(input.explicitPort);
50
+ if (explicitPort !== null) return explicitPort;
51
+ return DEFAULT_SOOTSIM_BRIDGE_PORT + parsePortOffset(input.portOffset);
52
+ }
53
+ function resolveSootsimBridgePortForHttpPort(input) {
54
+ const explicitPort = parsePort(input.explicitPort);
55
+ if (explicitPort !== null) return explicitPort;
56
+ const httpPort = parsePort(input.httpPort);
57
+ const portOffset = httpPort === null ? 0 : Math.max(0, httpPort - input.baseHttpPort);
58
+ return resolveSootsimBridgePort({ portOffset });
59
+ }
60
+ var LOCAL_DEV_HTTP_BASE_PORTS = [3e3, 5173];
61
+ var MAX_LOCAL_DEV_PORT_OFFSET = 2e3;
62
+ function parseHrefPort(value) {
63
+ if (typeof value !== "string" || !value.trim()) return null;
64
+ try {
65
+ return parsePort(new URL(value).port);
66
+ } catch {
67
+ return null;
68
+ }
69
+ }
70
+ function closestLocalDevBaseHttpPort(httpPort) {
71
+ let closest = null;
72
+ for (const basePort of LOCAL_DEV_HTTP_BASE_PORTS) {
73
+ const offset = httpPort - basePort;
74
+ if (offset < 0 || offset > MAX_LOCAL_DEV_PORT_OFFSET) continue;
75
+ if (!closest || offset < closest.offset) closest = { basePort, offset };
76
+ }
77
+ return closest?.basePort ?? null;
78
+ }
79
+ function resolveSootsimBridgePortForRuntimeLocation(input = {}) {
80
+ const explicitPort = parsePort(input.explicitPort);
81
+ if (explicitPort !== null) return explicitPort;
82
+ const httpPort = parsePort(input.httpPort) ?? parseHrefPort(input.href);
83
+ if (httpPort === null) return DEFAULT_SOOTSIM_BRIDGE_PORT;
84
+ const baseHttpPort = closestLocalDevBaseHttpPort(httpPort);
85
+ if (baseHttpPort === null) return DEFAULT_SOOTSIM_BRIDGE_PORT;
86
+ return resolveSootsimBridgePortForHttpPort({ httpPort, baseHttpPort });
87
+ }
31
88
  var SOOTSIM_BRIDGE_SIM_CLOSE_CODE = 4001;
32
89
  var SOOTSIM_BRIDGE_SIM_CLOSE_REASON = "sootsim close";
33
90
  // Annotate the CommonJS export names for ESM import in node:
34
91
  0 && (module.exports = {
35
92
  DEFAULT_SOOTSIM_BRIDGE_PORT,
36
93
  SOOTSIM_BRIDGE_SIM_CLOSE_CODE,
37
- SOOTSIM_BRIDGE_SIM_CLOSE_REASON
94
+ SOOTSIM_BRIDGE_SIM_CLOSE_REASON,
95
+ resolveSootsimBridgePort,
96
+ resolveSootsimBridgePortForHttpPort,
97
+ resolveSootsimBridgePortForRuntimeLocation
38
98
  });
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/host/fetch-proxy-overrides.ts
4
4
  var FETCH_PROXY_BROWSER_USER_AGENT = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36";
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -9495,13 +9495,70 @@ var bridge_constants_exports = {};
9495
9495
  __export(bridge_constants_exports, {
9496
9496
  DEFAULT_SOOTSIM_BRIDGE_PORT: () => DEFAULT_SOOTSIM_BRIDGE_PORT,
9497
9497
  SOOTSIM_BRIDGE_SIM_CLOSE_CODE: () => SOOTSIM_BRIDGE_SIM_CLOSE_CODE,
9498
- SOOTSIM_BRIDGE_SIM_CLOSE_REASON: () => SOOTSIM_BRIDGE_SIM_CLOSE_REASON
9498
+ SOOTSIM_BRIDGE_SIM_CLOSE_REASON: () => SOOTSIM_BRIDGE_SIM_CLOSE_REASON,
9499
+ resolveSootsimBridgePort: () => resolveSootsimBridgePort,
9500
+ resolveSootsimBridgePortForHttpPort: () => resolveSootsimBridgePortForHttpPort,
9501
+ resolveSootsimBridgePortForRuntimeLocation: () => resolveSootsimBridgePortForRuntimeLocation
9499
9502
  });
9500
- var DEFAULT_SOOTSIM_BRIDGE_PORT, SOOTSIM_BRIDGE_SIM_CLOSE_CODE, SOOTSIM_BRIDGE_SIM_CLOSE_REASON;
9503
+ function parsePort(value) {
9504
+ if (typeof value === "number") {
9505
+ return Number.isInteger(value) && value > 0 ? value : null;
9506
+ }
9507
+ if (typeof value !== "string") return null;
9508
+ const trimmed = value.trim();
9509
+ if (!trimmed) return null;
9510
+ const parsed = Number(trimmed);
9511
+ return Number.isInteger(parsed) && parsed > 0 ? parsed : null;
9512
+ }
9513
+ function parsePortOffset(value) {
9514
+ const parsed = parsePort(value);
9515
+ return parsed === null ? 0 : parsed;
9516
+ }
9517
+ function resolveSootsimBridgePort(input = {}) {
9518
+ const explicitPort = parsePort(input.explicitPort);
9519
+ if (explicitPort !== null) return explicitPort;
9520
+ return DEFAULT_SOOTSIM_BRIDGE_PORT + parsePortOffset(input.portOffset);
9521
+ }
9522
+ function resolveSootsimBridgePortForHttpPort(input) {
9523
+ const explicitPort = parsePort(input.explicitPort);
9524
+ if (explicitPort !== null) return explicitPort;
9525
+ const httpPort = parsePort(input.httpPort);
9526
+ const portOffset = httpPort === null ? 0 : Math.max(0, httpPort - input.baseHttpPort);
9527
+ return resolveSootsimBridgePort({ portOffset });
9528
+ }
9529
+ function parseHrefPort(value) {
9530
+ if (typeof value !== "string" || !value.trim()) return null;
9531
+ try {
9532
+ return parsePort(new URL(value).port);
9533
+ } catch {
9534
+ return null;
9535
+ }
9536
+ }
9537
+ function closestLocalDevBaseHttpPort(httpPort) {
9538
+ let closest = null;
9539
+ for (const basePort of LOCAL_DEV_HTTP_BASE_PORTS) {
9540
+ const offset = httpPort - basePort;
9541
+ if (offset < 0 || offset > MAX_LOCAL_DEV_PORT_OFFSET) continue;
9542
+ if (!closest || offset < closest.offset) closest = { basePort, offset };
9543
+ }
9544
+ return closest?.basePort ?? null;
9545
+ }
9546
+ function resolveSootsimBridgePortForRuntimeLocation(input = {}) {
9547
+ const explicitPort = parsePort(input.explicitPort);
9548
+ if (explicitPort !== null) return explicitPort;
9549
+ const httpPort = parsePort(input.httpPort) ?? parseHrefPort(input.href);
9550
+ if (httpPort === null) return DEFAULT_SOOTSIM_BRIDGE_PORT;
9551
+ const baseHttpPort = closestLocalDevBaseHttpPort(httpPort);
9552
+ if (baseHttpPort === null) return DEFAULT_SOOTSIM_BRIDGE_PORT;
9553
+ return resolveSootsimBridgePortForHttpPort({ httpPort, baseHttpPort });
9554
+ }
9555
+ var DEFAULT_SOOTSIM_BRIDGE_PORT, LOCAL_DEV_HTTP_BASE_PORTS, MAX_LOCAL_DEV_PORT_OFFSET, SOOTSIM_BRIDGE_SIM_CLOSE_CODE, SOOTSIM_BRIDGE_SIM_CLOSE_REASON;
9501
9556
  var init_bridge_constants = __esm({
9502
9557
  "src/bridge-constants.ts"() {
9503
9558
  "use strict";
9504
9559
  DEFAULT_SOOTSIM_BRIDGE_PORT = 7668;
9560
+ LOCAL_DEV_HTTP_BASE_PORTS = [3e3, 5173];
9561
+ MAX_LOCAL_DEV_PORT_OFFSET = 2e3;
9505
9562
  SOOTSIM_BRIDGE_SIM_CLOSE_CODE = 4001;
9506
9563
  SOOTSIM_BRIDGE_SIM_CLOSE_REASON = "sootsim close";
9507
9564
  }
package/dist-lib/vite.cjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! sootsim v0.1.99 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sootsim",
3
- "version": "0.1.98",
3
+ "version": "0.1.99",
4
4
  "description": "sootsim CLI + vite/metro plugins + skills registry. bridge client for driving the proprietary sootsim-engine over WebSocket.",
5
5
  "author": "Tamagui LLC",
6
6
  "license": "MIT",
@@ -3,6 +3,83 @@
3
3
  // dev plugin, and runtime agree on the same value.
4
4
  export const DEFAULT_SOOTSIM_BRIDGE_PORT = 7668
5
5
 
6
+ function parsePort(value: unknown): number | null {
7
+ if (typeof value === 'number') {
8
+ return Number.isInteger(value) && value > 0 ? value : null
9
+ }
10
+ if (typeof value !== 'string') return null
11
+ const trimmed = value.trim()
12
+ if (!trimmed) return null
13
+ const parsed = Number(trimmed)
14
+ return Number.isInteger(parsed) && parsed > 0 ? parsed : null
15
+ }
16
+
17
+ function parsePortOffset(value: unknown): number {
18
+ const parsed = parsePort(value)
19
+ return parsed === null ? 0 : parsed
20
+ }
21
+
22
+ export function resolveSootsimBridgePort(
23
+ input: {
24
+ explicitPort?: unknown
25
+ portOffset?: unknown
26
+ } = {},
27
+ ): number {
28
+ const explicitPort = parsePort(input.explicitPort)
29
+ if (explicitPort !== null) return explicitPort
30
+ return DEFAULT_SOOTSIM_BRIDGE_PORT + parsePortOffset(input.portOffset)
31
+ }
32
+
33
+ export function resolveSootsimBridgePortForHttpPort(input: {
34
+ explicitPort?: unknown
35
+ httpPort?: unknown
36
+ baseHttpPort: number
37
+ }): number {
38
+ const explicitPort = parsePort(input.explicitPort)
39
+ if (explicitPort !== null) return explicitPort
40
+ const httpPort = parsePort(input.httpPort)
41
+ const portOffset = httpPort === null ? 0 : Math.max(0, httpPort - input.baseHttpPort)
42
+ return resolveSootsimBridgePort({ portOffset })
43
+ }
44
+
45
+ const LOCAL_DEV_HTTP_BASE_PORTS = [3000, 5173]
46
+ const MAX_LOCAL_DEV_PORT_OFFSET = 2000
47
+
48
+ function parseHrefPort(value: unknown): number | null {
49
+ if (typeof value !== 'string' || !value.trim()) return null
50
+ try {
51
+ return parsePort(new URL(value).port)
52
+ } catch {
53
+ return null
54
+ }
55
+ }
56
+
57
+ function closestLocalDevBaseHttpPort(httpPort: number): number | null {
58
+ let closest: { basePort: number; offset: number } | null = null
59
+ for (const basePort of LOCAL_DEV_HTTP_BASE_PORTS) {
60
+ const offset = httpPort - basePort
61
+ if (offset < 0 || offset > MAX_LOCAL_DEV_PORT_OFFSET) continue
62
+ if (!closest || offset < closest.offset) closest = { basePort, offset }
63
+ }
64
+ return closest?.basePort ?? null
65
+ }
66
+
67
+ export function resolveSootsimBridgePortForRuntimeLocation(
68
+ input: {
69
+ explicitPort?: unknown
70
+ href?: unknown
71
+ httpPort?: unknown
72
+ } = {},
73
+ ): number {
74
+ const explicitPort = parsePort(input.explicitPort)
75
+ if (explicitPort !== null) return explicitPort
76
+ const httpPort = parsePort(input.httpPort) ?? parseHrefPort(input.href)
77
+ if (httpPort === null) return DEFAULT_SOOTSIM_BRIDGE_PORT
78
+ const baseHttpPort = closestLocalDevBaseHttpPort(httpPort)
79
+ if (baseHttpPort === null) return DEFAULT_SOOTSIM_BRIDGE_PORT
80
+ return resolveSootsimBridgePortForHttpPort({ httpPort, baseHttpPort })
81
+ }
82
+
6
83
  // private websocket close code used when the daemon intentionally closes a
7
84
  // sim. browser clients treat it as terminal and skip their normal reconnect
8
85
  // loop; playwright-owned sims use it to close their hosting context.
@@ -20,7 +20,7 @@ import {
20
20
  compatStubsForBuildResolver,
21
21
  reactNativeDeepStubsForBuildResolver,
22
22
  } from '../../compat/src/stub-manifest.ts'
23
- import { DEFAULT_SOOTSIM_BRIDGE_PORT } from './bridge-constants.ts'
23
+ import { resolveSootsimBridgePort } from './bridge-constants.ts'
24
24
  import { shouldApplyWorkletsPlugin, transformWorkletsCode } from './worklets-babel.ts'
25
25
 
26
26
  const sootsimPluginRequire = createRequire(import.meta.url)
@@ -499,7 +499,12 @@ export function wsBridgePlugin(): Plugin {
499
499
  // never starts.
500
500
  void import('./host/bridge-host.ts')
501
501
  .then(({ SootSimBridgeHost }) => {
502
- bridgeHost = new SootSimBridgeHost({ port: DEFAULT_SOOTSIM_BRIDGE_PORT })
502
+ bridgeHost = new SootSimBridgeHost({
503
+ port: resolveSootsimBridgePort({
504
+ explicitPort: process.env.SOOTSIM_BRIDGE_PORT,
505
+ portOffset: process.env.PORT_OFFSET,
506
+ }),
507
+ })
503
508
  bridgeHost.start?.({ silent: true })
504
509
  })
505
510
  .catch((err: unknown) => {
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a,b,c,d}from"./chunk-Q4OS7YTL.js";import"./chunk-6UGXIH6X.js";import"./chunk-JE5YNG3L.js";import"./chunk-POQEZLEI.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";export{c as ensureDaemonRunning,a as ensureRuntimeInstalled,d as ensureSootsimReady,b as resolveBootstrapPort};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a,b,c,d,e}from"./chunk-GFIXAGFA.js";import"./chunk-UHQCVRXY.js";export{e as BETA_ASK_HEADLINE,c as BETA_LABEL,d as BETA_TAGLINE,b as BETA_VERSION_TARGET,a as IS_BETA};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- var t="http://localhost:5173/";export{t as a};
@@ -1 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
@@ -1 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
@@ -1 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- var O="sootsim close";export{O as a};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a}from"./chunk-SNP2YECI.js";import"./chunk-UHQCVRXY.js";export{a as getCliVersion};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import"./chunk-4QCN4DMR.js";import{a,b,c,d,e,f,g,h,i}from"./chunk-ZZKSTNCP.js";import"./chunk-BQR62XGM.js";import"./chunk-LSPJL5XI.js";import"./chunk-F2WCFGRK.js";import"./chunk-I43WF32H.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.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,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as c,b as d,c as e,d as f}from"./chunk-VAMD4BL3.js";import"./chunk-ISIO4SR2.js";import"./chunk-CBTPTUJA.js";import"./chunk-DZYZQCET.js";import"./chunk-CLEO4DEV.js";import"./chunk-S5IHTZL6.js";import{d as a,e as b}from"./chunk-RVEZYFCE.js";import"./chunk-JTBFEQH4.js";import"./chunk-RP7NLZ26.js";import"./chunk-J2XMTE4K.js";import"./chunk-ZIFZANWB.js";import"./chunk-LWUHOZLQ.js";import"./chunk-6UGXIH6X.js";import"./chunk-JE5YNG3L.js";import"./chunk-ZZKSTNCP.js";import"./chunk-BQR62XGM.js";import"./chunk-LSPJL5XI.js";import"./chunk-F2WCFGRK.js";import"./chunk-I43WF32H.js";import"./chunk-MGZKAJV6.js";import"./chunk-ERDQVO6E.js";import"./chunk-ZCV4Z3DO.js";import"./chunk-4IZWBEOU.js";import"./chunk-POQEZLEI.js";import"./chunk-V3VDLHQ6.js";import"./chunk-36JO37LQ.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";export{c as discoverSootsimUrl,e as hoistLeadingSimFlag,a as parseFlowFile,f as runFlow,d as runFlowPlayback,b as validateFlowFile};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a,b,c}from"./chunk-PZQVLWTL.js";import"./chunk-ZCV4Z3DO.js";import"./chunk-L76C6UV4.js";import"./chunk-4IZWBEOU.js";import"./chunk-POQEZLEI.js";import"./chunk-SNP2YECI.js";import"./chunk-GFIXAGFA.js";import"./chunk-36JO37LQ.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";export{c as printCommandHelp,b as printGroupHelp,a as printHelp};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a as o}from"./chunk-DLENSNEY.js";import"./chunk-PH4GQWKG.js";import"./chunk-Q4OS7YTL.js";import"./chunk-6UGXIH6X.js";import"./chunk-JE5YNG3L.js";import"./chunk-MGZKAJV6.js";import"./chunk-ERDQVO6E.js";import"./chunk-POQEZLEI.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.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,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a}from"./chunk-Z5VQYEPL.js";import"./chunk-6UGXIH6X.js";import"./chunk-JE5YNG3L.js";import"./chunk-POQEZLEI.js";import"./chunk-3RW36LEF.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";export{a as runRuntime};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a}from"./chunk-DLENSNEY.js";import"./chunk-PH4GQWKG.js";import"./chunk-Q4OS7YTL.js";import"./chunk-6UGXIH6X.js";import"./chunk-JE5YNG3L.js";import"./chunk-MGZKAJV6.js";import"./chunk-ERDQVO6E.js";import"./chunk-POQEZLEI.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";export{a as runSetupRepo};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a}from"./chunk-V3VDLHQ6.js";import"./chunk-36JO37LQ.js";import"./chunk-UHQCVRXY.js";export{a as settingsStore};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a,b}from"./chunk-MGZKAJV6.js";import"./chunk-ERDQVO6E.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";export{b as flushCliTelemetry,a as trackCliEvent};
@@ -1,2 +0,0 @@
1
- /*! sootsim v0.1.98 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
- import{a,b,c}from"./chunk-CLEO4DEV.js";import"./chunk-S5IHTZL6.js";import"./chunk-LWUHOZLQ.js";import"./chunk-6UGXIH6X.js";import"./chunk-JE5YNG3L.js";import"./chunk-LSPJL5XI.js";import"./chunk-I43WF32H.js";import"./chunk-MGZKAJV6.js";import"./chunk-ERDQVO6E.js";import"./chunk-POQEZLEI.js";import"./chunk-KJUP4MG5.js";import"./chunk-UHQCVRXY.js";export{a as resolveDefaultUploadOrigin,b as resolvePublicPreviewOrigin,c as runUpload};