@xrkseek/harness-cli 0.1.3 → 0.1.4

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 (278) hide show
  1. package/README.md +41 -22
  2. package/dist/commands/plugin.js +16 -16
  3. package/dist/commands/plugin.js.map +1 -1
  4. package/dist/commands/serve.d.ts.map +1 -1
  5. package/dist/commands/serve.js +34 -3
  6. package/dist/commands/serve.js.map +1 -1
  7. package/dist/log.d.ts +6 -1
  8. package/dist/log.d.ts.map +1 -1
  9. package/dist/log.js +20 -6
  10. package/dist/log.js.map +1 -1
  11. package/dist/parse-args.js +8 -8
  12. package/dist/plugin/index.js +5 -5
  13. package/dist/plugin/index.js.map +1 -1
  14. package/dist/plugin/remap-inject.d.ts.map +1 -1
  15. package/dist/plugin/remap-inject.js +1 -0
  16. package/dist/plugin/remap-inject.js.map +1 -1
  17. package/node_modules/@xrkseek/preset-server/dist/tsconfig.tsbuildinfo +1 -1
  18. package/node_modules/@xrkseek/server-face/dist/handlers/cost-meter.d.ts +15 -22
  19. package/node_modules/@xrkseek/server-face/dist/handlers/cost-meter.d.ts.map +1 -1
  20. package/node_modules/@xrkseek/server-face/dist/handlers/cost-meter.js +19 -16
  21. package/node_modules/@xrkseek/server-face/dist/handlers/cost-meter.js.map +1 -1
  22. package/node_modules/@xrkseek/server-face/dist/index.d.ts +2 -1
  23. package/node_modules/@xrkseek/server-face/dist/index.d.ts.map +1 -1
  24. package/node_modules/@xrkseek/server-face/dist/index.js +2 -1
  25. package/node_modules/@xrkseek/server-face/dist/index.js.map +1 -1
  26. package/node_modules/@xrkseek/server-host/dist/index.d.ts.map +1 -1
  27. package/node_modules/@xrkseek/server-host/dist/index.js +12 -4
  28. package/node_modules/@xrkseek/server-host/dist/index.js.map +1 -1
  29. package/node_modules/@xrkseek/server-host/dist/sidebar-face-bridge.d.ts +10 -0
  30. package/node_modules/@xrkseek/server-host/dist/sidebar-face-bridge.d.ts.map +1 -0
  31. package/node_modules/@xrkseek/server-host/dist/sidebar-face-bridge.js +131 -0
  32. package/node_modules/@xrkseek/server-host/dist/sidebar-face-bridge.js.map +1 -0
  33. package/node_modules/@xrkseek/server-host/dist/wallet-bridge.d.ts.map +1 -1
  34. package/node_modules/@xrkseek/server-host/dist/wallet-bridge.js +29 -1
  35. package/node_modules/@xrkseek/server-host/dist/wallet-bridge.js.map +1 -1
  36. package/node_modules/@xrkseek/server-http/dist/dsh-compat/adapter-providers.d.ts.map +1 -1
  37. package/node_modules/@xrkseek/server-http/dist/dsh-compat/adapter-providers.js +3 -1
  38. package/node_modules/@xrkseek/server-http/dist/dsh-compat/adapter-providers.js.map +1 -1
  39. package/node_modules/@xrkseek/server-http/dist/dsh-compat/adapter-types.d.ts +4 -1
  40. package/node_modules/@xrkseek/server-http/dist/dsh-compat/adapter-types.d.ts.map +1 -1
  41. package/node_modules/@xrkseek/server-http/dist/dsh-compat/auto-review-http.js +1 -1
  42. package/node_modules/@xrkseek/server-http/dist/dsh-compat/auto-review-http.js.map +1 -1
  43. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-discovery.d.ts +41 -0
  44. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-discovery.d.ts.map +1 -0
  45. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-discovery.js +422 -0
  46. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-discovery.js.map +1 -0
  47. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-registry.d.ts +21 -0
  48. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-registry.d.ts.map +1 -0
  49. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-registry.js +34 -0
  50. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import-registry.js.map +1 -0
  51. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import.d.ts +1 -1
  52. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import.d.ts.map +1 -1
  53. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import.js +277 -23
  54. package/node_modules/@xrkseek/server-http/dist/dsh-compat/chat-import.js.map +1 -1
  55. package/node_modules/@xrkseek/server-http/dist/dsh-compat/community-root-http.d.ts +1 -1
  56. package/node_modules/@xrkseek/server-http/dist/dsh-compat/community-root-http.js +1 -1
  57. package/node_modules/@xrkseek/server-http/dist/dsh-compat/community-root-http.js.map +1 -1
  58. package/node_modules/@xrkseek/server-http/dist/dsh-compat/cordis-registry.d.ts +1 -1
  59. package/node_modules/@xrkseek/server-http/dist/dsh-compat/cordis-registry.d.ts.map +1 -1
  60. package/node_modules/@xrkseek/server-http/dist/dsh-compat/cordis-registry.js +2 -2
  61. package/node_modules/@xrkseek/server-http/dist/dsh-compat/cordis-registry.js.map +1 -1
  62. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-community-infer.js +1 -1
  63. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-community-infer.js.map +1 -1
  64. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-compat-matrix.d.ts +4 -4
  65. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-compat-matrix.d.ts.map +1 -1
  66. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-compat-matrix.js +26 -26
  67. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-compat-matrix.js.map +1 -1
  68. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-envelope.js +1 -1
  69. package/node_modules/@xrkseek/server-http/dist/dsh-compat/dsh-envelope.js.map +1 -1
  70. package/node_modules/@xrkseek/server-http/dist/dsh-compat/generic-dsh-http.d.ts +2 -2
  71. package/node_modules/@xrkseek/server-http/dist/dsh-compat/generic-dsh-http.js +1 -1
  72. package/node_modules/@xrkseek/server-http/dist/dsh-compat/generic-dsh-http.js.map +1 -1
  73. package/node_modules/@xrkseek/server-http/dist/dsh-compat/generic-plugin-http.js +3 -3
  74. package/node_modules/@xrkseek/server-http/dist/dsh-compat/generic-plugin-http.js.map +1 -1
  75. package/node_modules/@xrkseek/server-http/dist/dsh-compat/genui.js +1 -1
  76. package/node_modules/@xrkseek/server-http/dist/dsh-compat/genui.js.map +1 -1
  77. package/node_modules/@xrkseek/server-http/dist/dsh-compat/honest-http-catchall.js +3 -3
  78. package/node_modules/@xrkseek/server-http/dist/dsh-compat/honest-http-catchall.js.map +1 -1
  79. package/node_modules/@xrkseek/server-http/dist/dsh-compat/im-messaging-bridge.d.ts +2 -0
  80. package/node_modules/@xrkseek/server-http/dist/dsh-compat/im-messaging-bridge.d.ts.map +1 -1
  81. package/node_modules/@xrkseek/server-http/dist/dsh-compat/im-messaging-bridge.js +53 -1
  82. package/node_modules/@xrkseek/server-http/dist/dsh-compat/im-messaging-bridge.js.map +1 -1
  83. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.d.ts +21 -18
  84. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.d.ts.map +1 -1
  85. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.js +28 -15
  86. package/node_modules/@xrkseek/server-http/dist/dsh-compat/index.js.map +1 -1
  87. package/node_modules/@xrkseek/server-http/dist/dsh-compat/market.js +1 -1
  88. package/node_modules/@xrkseek/server-http/dist/dsh-compat/market.js.map +1 -1
  89. package/node_modules/@xrkseek/server-http/dist/dsh-compat/memento.d.ts +1 -0
  90. package/node_modules/@xrkseek/server-http/dist/dsh-compat/memento.d.ts.map +1 -1
  91. package/node_modules/@xrkseek/server-http/dist/dsh-compat/memento.js +77 -24
  92. package/node_modules/@xrkseek/server-http/dist/dsh-compat/memento.js.map +1 -1
  93. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mnemon.d.ts +24 -0
  94. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mnemon.d.ts.map +1 -1
  95. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mnemon.js +39 -10
  96. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mnemon.js.map +1 -1
  97. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-auth.d.ts +71 -0
  98. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-auth.d.ts.map +1 -0
  99. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-auth.js +349 -0
  100. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-auth.js.map +1 -0
  101. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-cpolar-component.d.ts +53 -0
  102. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-cpolar-component.d.ts.map +1 -0
  103. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-cpolar-component.js +233 -0
  104. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-cpolar-component.js.map +1 -0
  105. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-funnel-sidecar.d.ts +4 -0
  106. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-funnel-sidecar.d.ts.map +1 -0
  107. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-funnel-sidecar.js +86 -0
  108. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-funnel-sidecar.js.map +1 -0
  109. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-gate.d.ts +15 -0
  110. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-gate.d.ts.map +1 -0
  111. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-gate.js +41 -0
  112. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-gate.js.map +1 -0
  113. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-local-gateway.d.ts +22 -0
  114. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-local-gateway.d.ts.map +1 -0
  115. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-local-gateway.js +183 -0
  116. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-local-gateway.js.map +1 -0
  117. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-controllers.d.ts +68 -0
  118. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-controllers.d.ts.map +1 -0
  119. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-controllers.js +511 -0
  120. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-controllers.js.map +1 -0
  121. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-runtime.d.ts +34 -0
  122. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-runtime.d.ts.map +1 -0
  123. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-runtime.js +179 -0
  124. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote-runtime.js.map +1 -0
  125. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote.d.ts +19 -0
  126. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote.d.ts.map +1 -0
  127. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote.js +102 -0
  128. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access-remote.js.map +1 -0
  129. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.d.ts +31 -4
  130. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.d.ts.map +1 -1
  131. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.js +698 -33
  132. package/node_modules/@xrkseek/server-http/dist/dsh-compat/mobile-access.js.map +1 -1
  133. package/node_modules/@xrkseek/server-http/dist/dsh-compat/modlens.js +1 -1
  134. package/node_modules/@xrkseek/server-http/dist/dsh-compat/modlens.js.map +1 -1
  135. package/node_modules/@xrkseek/server-http/dist/dsh-compat/modsearch.d.ts.map +1 -1
  136. package/node_modules/@xrkseek/server-http/dist/dsh-compat/modsearch.js +4 -1
  137. package/node_modules/@xrkseek/server-http/dist/dsh-compat/modsearch.js.map +1 -1
  138. package/node_modules/@xrkseek/server-http/dist/dsh-compat/noema.js +1 -1
  139. package/node_modules/@xrkseek/server-http/dist/dsh-compat/noema.js.map +1 -1
  140. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket-qrcode.d.ts +3 -0
  141. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket-qrcode.d.ts.map +1 -0
  142. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket-qrcode.js +18 -0
  143. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket-qrcode.js.map +1 -0
  144. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket.d.ts +6 -3
  145. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket.d.ts.map +1 -1
  146. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket.js +204 -54
  147. package/node_modules/@xrkseek/server-http/dist/dsh-compat/pocket.js.map +1 -1
  148. package/node_modules/@xrkseek/server-http/dist/dsh-compat/releases.js +1 -1
  149. package/node_modules/@xrkseek/server-http/dist/dsh-compat/releases.js.map +1 -1
  150. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-adapter.d.ts +3 -0
  151. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-adapter.d.ts.map +1 -1
  152. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-adapter.js +185 -21
  153. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-adapter.js.map +1 -1
  154. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-browser.d.ts +3 -0
  155. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-browser.d.ts.map +1 -0
  156. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-browser.js +82 -0
  157. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-browser.js.map +1 -0
  158. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-face-bridge.d.ts +43 -0
  159. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-face-bridge.d.ts.map +1 -0
  160. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-face-bridge.js +2 -0
  161. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-face-bridge.js.map +1 -0
  162. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-git.d.ts +47 -13
  163. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-git.d.ts.map +1 -1
  164. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-git.js +146 -27
  165. package/node_modules/@xrkseek/server-http/dist/dsh-compat/sidebar-git.js.map +1 -1
  166. package/node_modules/@xrkseek/server-http/dist/dsh-compat/skin-market.js +1 -1
  167. package/node_modules/@xrkseek/server-http/dist/dsh-compat/skin-market.js.map +1 -1
  168. package/node_modules/@xrkseek/server-http/dist/dsh-compat/tokenledger.d.ts.map +1 -1
  169. package/node_modules/@xrkseek/server-http/dist/dsh-compat/tokenledger.js +22 -4
  170. package/node_modules/@xrkseek/server-http/dist/dsh-compat/tokenledger.js.map +1 -1
  171. package/node_modules/@xrkseek/server-http/dist/dsh-compat/tongflow.d.ts.map +1 -1
  172. package/node_modules/@xrkseek/server-http/dist/dsh-compat/tongflow.js +21 -2
  173. package/node_modules/@xrkseek/server-http/dist/dsh-compat/tongflow.js.map +1 -1
  174. package/node_modules/@xrkseek/server-http/dist/dsh-compat/turn-rewind-workspace.js +1 -1
  175. package/node_modules/@xrkseek/server-http/dist/dsh-compat/turn-rewind-workspace.js.map +1 -1
  176. package/node_modules/@xrkseek/server-http/dist/dsh-compat/turn-rewind.d.ts +2 -0
  177. package/node_modules/@xrkseek/server-http/dist/dsh-compat/turn-rewind.d.ts.map +1 -1
  178. package/node_modules/@xrkseek/server-http/dist/dsh-compat/turn-rewind.js +42 -3
  179. package/node_modules/@xrkseek/server-http/dist/dsh-compat/turn-rewind.js.map +1 -1
  180. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/contracts/wallet-port.d.ts +25 -7
  181. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/contracts/wallet-port.d.ts.map +1 -1
  182. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/contracts/wallet-port.js +2 -2
  183. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/doc-store.d.ts +2 -2
  184. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/doc-store.js +2 -2
  185. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/http-json.d.ts +12 -0
  186. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/http-json.d.ts.map +1 -0
  187. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/http-json.js +40 -0
  188. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/http-json.js.map +1 -0
  189. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/http-kit.d.ts +1 -1
  190. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/http-kit.js +1 -1
  191. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/http-kit.js.map +1 -1
  192. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/index.d.ts +7 -12
  193. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/index.d.ts.map +1 -1
  194. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/index.js +5 -8
  195. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/index.js.map +1 -1
  196. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/json-store.d.ts +5 -0
  197. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/json-store.d.ts.map +1 -0
  198. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/json-store.js +31 -0
  199. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/json-store.js.map +1 -0
  200. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.d.ts +37 -0
  201. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.d.ts.map +1 -0
  202. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.js +96 -0
  203. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/mobile-gate-kit.js.map +1 -0
  204. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/public-handler.d.ts +6 -0
  205. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/public-handler.d.ts.map +1 -0
  206. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/public-handler.js +2 -0
  207. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/public-handler.js.map +1 -0
  208. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/wallet-service.d.ts.map +1 -1
  209. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/wallet-service.js +66 -4
  210. package/node_modules/@xrkseek/server-http/dist/dsh-compat/underlying/wallet-service.js.map +1 -1
  211. package/node_modules/@xrkseek/server-http/dist/dsh-compat/undo.js +2 -2
  212. package/node_modules/@xrkseek/server-http/dist/dsh-compat/undo.js.map +1 -1
  213. package/node_modules/@xrkseek/server-http/dist/dsh-compat/usage-stats.js +1 -1
  214. package/node_modules/@xrkseek/server-http/dist/dsh-compat/usage-stats.js.map +1 -1
  215. package/node_modules/@xrkseek/server-http/dist/dsh-compat/vision.js +1 -1
  216. package/node_modules/@xrkseek/server-http/dist/dsh-compat/vision.js.map +1 -1
  217. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wallet.d.ts +2 -2
  218. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wallet.d.ts.map +1 -1
  219. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wallet.js +2 -2
  220. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wallet.js.map +1 -1
  221. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wallpaper.js +2 -2
  222. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wallpaper.js.map +1 -1
  223. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wire/settings-provider.d.ts +1 -1
  224. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wire/stub-handlers.js +1 -1
  225. package/node_modules/@xrkseek/server-http/dist/dsh-compat/wire/stub-handlers.js.map +1 -1
  226. package/node_modules/@xrkseek/server-http/dist/dsh-compat/xrk-json-store.js +3 -3
  227. package/node_modules/@xrkseek/server-http/dist/dsh-compat/xrk-json-store.js.map +1 -1
  228. package/node_modules/@xrkseek/server-http/dist/index.d.ts +1 -1
  229. package/node_modules/@xrkseek/server-http/dist/index.d.ts.map +1 -1
  230. package/node_modules/@xrkseek/server-http/dist/index.js +1 -1
  231. package/node_modules/@xrkseek/server-http/dist/index.js.map +1 -1
  232. package/node_modules/@xrkseek/server-http/package.json +7 -1
  233. package/node_modules/qrcode-generator/README.md +101 -0
  234. package/node_modules/qrcode-generator/package.json +30 -0
  235. package/node_modules/qrcode-generator/qrcode.d.ts +57 -0
  236. package/node_modules/qrcode-generator/qrcode.js +2297 -0
  237. package/node_modules/qrcode-generator/qrcode_SJIS.js +30 -0
  238. package/node_modules/qrcode-generator/qrcode_UTF8.js +26 -0
  239. package/node_modules/qrcode-generator/sample.html +49 -0
  240. package/node_modules/qrcode-generator/sample.js +49 -0
  241. package/node_modules/qrcode-generator/test/qrcode.js +118 -0
  242. package/package.json +4 -2
  243. package/product-web/assets/index-BNGm-t1O.js +112 -0
  244. package/product-web/assets/index-BNGm-t1O.js.map +1 -0
  245. package/product-web/boot.json +1 -1
  246. package/product-web/index.html +1 -1
  247. package/product-web/plugins/@xrkseek/client-locale/client.js +3 -3
  248. package/product-web/plugins/@xrkseek/client-modules/client.js +7 -6
  249. package/product-web/plugins/@xrkseek/client-runtime/client.js +7 -0
  250. package/product-web/plugins/@xrkseek/client-ui-agent-preset/client.js +37 -37
  251. package/product-web/plugins/@xrkseek/client-ui-attachment/client.js +14 -14
  252. package/product-web/plugins/@xrkseek/client-ui-commands/client.js +8 -8
  253. package/product-web/plugins/@xrkseek/client-ui-conversation/client.js +186 -193
  254. package/product-web/plugins/@xrkseek/client-ui-deliverables/client.js +5 -5
  255. package/product-web/plugins/@xrkseek/client-ui-directory-picker-browse/client.js +30 -30
  256. package/product-web/plugins/@xrkseek/client-ui-goal/client.js +8 -8
  257. package/product-web/plugins/@xrkseek/client-ui-input-trigger/client.js +5 -5
  258. package/product-web/plugins/@xrkseek/client-ui-jobs/client.js +9 -9
  259. package/product-web/plugins/@xrkseek/client-ui-layout/client.js +3 -3
  260. package/product-web/plugins/@xrkseek/client-ui-message-feedback/client.js +5 -5
  261. package/product-web/plugins/@xrkseek/client-ui-model-selection/client.js +18 -18
  262. package/product-web/plugins/@xrkseek/client-ui-permission-presets/client.js +3 -3
  263. package/product-web/plugins/@xrkseek/client-ui-plan/client.js +2 -2
  264. package/product-web/plugins/@xrkseek/client-ui-settings-general/client.js +27 -19
  265. package/product-web/plugins/@xrkseek/client-ui-settings-models/client.js +54 -54
  266. package/product-web/plugins/@xrkseek/client-ui-settings-plugin-inventory/client.js +13 -13
  267. package/product-web/plugins/@xrkseek/client-ui-settings-plugins/client.js +42 -42
  268. package/product-web/plugins/@xrkseek/client-ui-sidebar/client.js +16 -16
  269. package/product-web/plugins/@xrkseek/client-ui-skill/client.js +11 -11
  270. package/product-web/plugins/@xrkseek/client-ui-subagent/client.js +22 -22
  271. package/product-web/plugins/@xrkseek/client-ui-theme/client.js +4 -4
  272. package/product-web/plugins/@xrkseek/client-ui-tool/client.js +38 -38
  273. package/product-web/plugins/@xrkseek/client-ui-trajectory/client.js +144 -144
  274. package/product-web/plugins/@xrkseek/client-ui-user-questions/client.js +31 -31
  275. package/product-web/plugins/@xrkseek/client-ui-workflow-run/client.js +17 -17
  276. package/product-web/plugins/@xrkseek/client-ui-workspace/client.js +53 -53
  277. package/product-web/assets/index-C_NG-17x.js +0 -112
  278. package/product-web/assets/index-C_NG-17x.js.map +0 -1
@@ -0,0 +1,511 @@
1
+ /**
2
+ * Tailscale Funnel sidecar + cpolar process controllers (dsh-mobile compatible).
3
+ */
4
+ import { spawn } from "node:child_process";
5
+ import path from "node:path";
6
+ import { reserveLoopbackPort, startLocalProxyGateway, } from "./mobile-access-local-gateway.js";
7
+ const MAX_LOG_BUFFER = 65536;
8
+ const MAX_PROTOCOL_LINE = 8192;
9
+ const START_TIMEOUT_MS = 45_000;
10
+ const CPOLAR_HOST_SUFFIXES = [
11
+ ".cpolar.cn",
12
+ ".cpolar.io",
13
+ ".cpolar.top",
14
+ ".cpolar.com",
15
+ ];
16
+ function publicStatus(status) {
17
+ return {
18
+ enabled: status.enabled,
19
+ state: status.state,
20
+ ...(status.origin ? { origin: status.origin } : {}),
21
+ ...(status.loginUrl ? { loginUrl: status.loginUrl } : {}),
22
+ ...(status.setupUrl ? { setupUrl: status.setupUrl } : {}),
23
+ ...(status.errorCode ? { errorCode: status.errorCode } : {}),
24
+ };
25
+ }
26
+ function parseCpolarOrigin(line) {
27
+ if (!line.includes("Tunnel established at "))
28
+ return undefined;
29
+ const match = /Tunnel established at (https:\/\/[^"\s]+)/u.exec(line);
30
+ if (!match?.[1])
31
+ return undefined;
32
+ const url = new URL(match[1]);
33
+ if (url.protocol !== "https:" ||
34
+ url.port !== "" ||
35
+ !CPOLAR_HOST_SUFFIXES.some((s) => url.hostname.endsWith(s)) ||
36
+ url.pathname !== "/" ||
37
+ url.search !== "" ||
38
+ url.hash !== "") {
39
+ throw new Error("invalid_cpolar_origin");
40
+ }
41
+ return url.origin;
42
+ }
43
+ function parseFunnelOrigin(value) {
44
+ const url = new URL(value);
45
+ if (url.protocol !== "https:" ||
46
+ !url.hostname.endsWith(".ts.net") ||
47
+ url.port !== "" ||
48
+ url.pathname !== "/" ||
49
+ url.search !== "" ||
50
+ url.hash !== "") {
51
+ throw new Error("invalid_funnel_origin");
52
+ }
53
+ return url.origin;
54
+ }
55
+ function parseFunnelEvent(line) {
56
+ if (Buffer.byteLength(line, "utf8") > MAX_PROTOCOL_LINE) {
57
+ throw new Error("invalid_sidecar_protocol");
58
+ }
59
+ const value = JSON.parse(line);
60
+ if (value.version !== 1 || typeof value.type !== "string") {
61
+ throw new Error("invalid_sidecar_protocol");
62
+ }
63
+ if (value.type === "login") {
64
+ const url = new URL(String(value.url));
65
+ if (url.protocol !== "https:" || url.hostname !== "login.tailscale.com") {
66
+ throw new Error("invalid_sidecar_protocol");
67
+ }
68
+ return { type: "login", url: url.toString() };
69
+ }
70
+ if (value.type === "ready" || value.type === "serving") {
71
+ return {
72
+ type: value.type,
73
+ origin: parseFunnelOrigin(String(value.origin)),
74
+ };
75
+ }
76
+ if (value.type === "error") {
77
+ return {
78
+ type: "error",
79
+ code: String(value.code ?? "funnel_failed"),
80
+ ...(typeof value.url === "string" ? { url: value.url } : {}),
81
+ };
82
+ }
83
+ throw new Error("invalid_sidecar_protocol");
84
+ }
85
+ function withoutProxyEnv(env) {
86
+ const blocked = new Set([
87
+ "HTTP_PROXY",
88
+ "HTTPS_PROXY",
89
+ "ALL_PROXY",
90
+ "NO_PROXY",
91
+ ]);
92
+ return Object.fromEntries(Object.entries(env).filter(([k]) => !blocked.has(k.toUpperCase())));
93
+ }
94
+ function withoutTailscaleSecrets(env) {
95
+ const blocked = new Set([
96
+ "TS_AUTHKEY",
97
+ "TAILSCALE_AUTHKEY",
98
+ "TS_OAUTH_CLIENT_SECRET",
99
+ ]);
100
+ return Object.fromEntries(Object.entries(env).filter(([k]) => !blocked.has(k.toUpperCase())));
101
+ }
102
+ class BaseRemoteController {
103
+ createGateway;
104
+ loadEnabled;
105
+ saveEnabled;
106
+ enabled = false;
107
+ initialized = false;
108
+ disposed = false;
109
+ child;
110
+ gatewayValue;
111
+ generation = 0;
112
+ buffer = "";
113
+ latest = { enabled: false, state: "off" };
114
+ queue = Promise.resolve();
115
+ startupTimer;
116
+ constructor(createGateway, loadEnabled, saveEnabled) {
117
+ this.createGateway = createGateway;
118
+ this.loadEnabled = loadEnabled;
119
+ this.saveEnabled = saveEnabled;
120
+ }
121
+ async initialize() {
122
+ this.enabled = await this.loadEnabled();
123
+ this.initialized = true;
124
+ if (this.enabled)
125
+ await this.start();
126
+ else
127
+ this.publish({ enabled: false, state: "off" });
128
+ }
129
+ gateway() {
130
+ return this.gatewayValue;
131
+ }
132
+ status() {
133
+ return publicStatus(this.latest);
134
+ }
135
+ async setEnabled(enabled) {
136
+ if (!this.initialized || this.disposed) {
137
+ throw new Error("remote controller unavailable");
138
+ }
139
+ await this.enqueue(async () => {
140
+ if (this.enabled === enabled && (!enabled || this.child))
141
+ return;
142
+ if (!enabled)
143
+ await this.stop();
144
+ this.enabled = enabled;
145
+ await this.saveEnabled(enabled);
146
+ if (enabled)
147
+ await this.start();
148
+ else
149
+ this.publish({ enabled: false, state: "off" });
150
+ });
151
+ return this.status();
152
+ }
153
+ async reconnect() {
154
+ await this.enqueue(async () => {
155
+ if (!this.enabled) {
156
+ this.enabled = true;
157
+ await this.saveEnabled(true);
158
+ }
159
+ await this.stop();
160
+ await this.start();
161
+ });
162
+ return this.status();
163
+ }
164
+ async reset() {
165
+ await this.enqueue(async () => {
166
+ await this.stop();
167
+ this.enabled = false;
168
+ await this.saveEnabled(false);
169
+ this.publish({ enabled: false, state: "off" });
170
+ });
171
+ return this.status();
172
+ }
173
+ async close() {
174
+ if (this.disposed)
175
+ return;
176
+ this.disposed = true;
177
+ await this.enqueue(() => this.stop());
178
+ }
179
+ enqueue(op) {
180
+ const task = this.queue.then(op, op);
181
+ this.queue = task.then(() => undefined, () => undefined);
182
+ return task;
183
+ }
184
+ publish(status) {
185
+ this.latest = publicStatus(status);
186
+ }
187
+ async failGeneration(generation, code) {
188
+ if (generation !== this.generation)
189
+ return;
190
+ await this.stop();
191
+ if (this.enabled) {
192
+ this.publish({ enabled: true, state: "error", errorCode: code });
193
+ }
194
+ }
195
+ async stop() {
196
+ this.generation += 1;
197
+ if (this.startupTimer)
198
+ clearTimeout(this.startupTimer);
199
+ this.startupTimer = undefined;
200
+ const child = this.child;
201
+ this.child = undefined;
202
+ if (child && !child.killed) {
203
+ child.kill();
204
+ }
205
+ if (this.gatewayValue) {
206
+ await this.gatewayValue.close();
207
+ this.gatewayValue = undefined;
208
+ }
209
+ this.buffer = "";
210
+ }
211
+ }
212
+ export class CpolarRemoteController extends BaseRemoteController {
213
+ executable;
214
+ configFile;
215
+ region;
216
+ reservation;
217
+ constructor(createGateway, loadEnabled, saveEnabled, executable, configFile, region = "cn") {
218
+ super(createGateway, loadEnabled, saveEnabled);
219
+ this.executable = executable;
220
+ this.configFile = configFile;
221
+ this.region = region;
222
+ }
223
+ async start() {
224
+ const generation = ++this.generation;
225
+ const { stat } = await import("node:fs/promises");
226
+ try {
227
+ const est = await stat(this.executable);
228
+ if (!est.isFile())
229
+ throw new Error("missing");
230
+ }
231
+ catch {
232
+ this.publish({
233
+ enabled: true,
234
+ state: "unavailable",
235
+ errorCode: "cpolar_component_missing",
236
+ });
237
+ return;
238
+ }
239
+ try {
240
+ const cfg = await stat(this.configFile);
241
+ if (!cfg.isFile())
242
+ throw new Error("missing");
243
+ }
244
+ catch {
245
+ this.publish({
246
+ enabled: true,
247
+ state: "unavailable",
248
+ errorCode: "cpolar_config_missing",
249
+ });
250
+ return;
251
+ }
252
+ let reservation;
253
+ try {
254
+ reservation = await reserveLoopbackPort();
255
+ }
256
+ catch {
257
+ this.publish({
258
+ enabled: true,
259
+ state: "error",
260
+ errorCode: "cpolar_port_unavailable",
261
+ });
262
+ return;
263
+ }
264
+ this.reservation = reservation;
265
+ this.buffer = "";
266
+ this.publish({ enabled: true, state: "starting" });
267
+ const args = [
268
+ "http",
269
+ `-config=${path.resolve(this.configFile)}`,
270
+ `-region=${this.region}`,
271
+ "-inspect-addr=false",
272
+ "-redirect-https=true",
273
+ "-log=stdout",
274
+ "-log-level=INFO",
275
+ String(reservation.port),
276
+ ];
277
+ const child = spawn(this.executable, args, {
278
+ env: withoutProxyEnv(process.env),
279
+ shell: false,
280
+ stdio: ["pipe", "pipe", "pipe"],
281
+ windowsHide: true,
282
+ });
283
+ this.child = child;
284
+ child.stdout.setEncoding("utf8");
285
+ child.stderr.setEncoding("utf8");
286
+ child.stdout.on("data", (chunk) => this.consume(generation, String(chunk)));
287
+ child.stderr.on("data", (chunk) => this.consume(generation, String(chunk)));
288
+ child.once("error", () => {
289
+ void this.enqueue(() => this.failGeneration(generation, "cpolar_launch_failed"));
290
+ });
291
+ child.once("close", (code) => {
292
+ if (generation !== this.generation || this.child !== child)
293
+ return;
294
+ this.child = undefined;
295
+ if (this.enabled) {
296
+ void this.enqueue(() => this.failGeneration(generation, code === 0 ? "cpolar_stopped" : "cpolar_exited"));
297
+ }
298
+ });
299
+ this.startupTimer = setTimeout(() => {
300
+ void this.enqueue(() => this.failGeneration(generation, "cpolar_start_timeout"));
301
+ }, START_TIMEOUT_MS);
302
+ this.startupTimer.unref();
303
+ }
304
+ consume(generation, chunk) {
305
+ if (generation !== this.generation)
306
+ return;
307
+ this.buffer += chunk;
308
+ if (Buffer.byteLength(this.buffer, "utf8") > MAX_LOG_BUFFER &&
309
+ !this.buffer.includes("\n")) {
310
+ void this.enqueue(() => this.failGeneration(generation, "cpolar_invalid_output"));
311
+ return;
312
+ }
313
+ while (true) {
314
+ const newline = this.buffer.indexOf("\n");
315
+ if (newline < 0)
316
+ return;
317
+ const line = this.buffer.slice(0, newline).replace(/\r$/u, "");
318
+ this.buffer = this.buffer.slice(newline + 1);
319
+ try {
320
+ const origin = parseCpolarOrigin(line);
321
+ if (origin) {
322
+ void this.enqueue(() => this.attachGateway(generation, origin));
323
+ }
324
+ }
325
+ catch {
326
+ void this.enqueue(() => this.failGeneration(generation, "cpolar_invalid_origin"));
327
+ return;
328
+ }
329
+ }
330
+ }
331
+ async attachGateway(generation, origin) {
332
+ if (generation !== this.generation ||
333
+ !this.enabled ||
334
+ this.gatewayValue) {
335
+ return;
336
+ }
337
+ const reservation = this.reservation;
338
+ if (!reservation)
339
+ return;
340
+ this.publish({ enabled: true, state: "connecting", origin });
341
+ await reservation.release();
342
+ if (this.reservation === reservation)
343
+ this.reservation = undefined;
344
+ let gateway;
345
+ try {
346
+ gateway = await this.createGateway(origin, reservation.port);
347
+ }
348
+ catch {
349
+ await this.failGeneration(generation, "gateway_start_failed");
350
+ return;
351
+ }
352
+ if (generation !== this.generation || !this.enabled) {
353
+ await gateway.close();
354
+ return;
355
+ }
356
+ this.gatewayValue = gateway;
357
+ if (this.startupTimer)
358
+ clearTimeout(this.startupTimer);
359
+ this.startupTimer = undefined;
360
+ this.publish({ enabled: true, state: "ready", origin });
361
+ }
362
+ async stop() {
363
+ const reservation = this.reservation;
364
+ this.reservation = undefined;
365
+ if (reservation)
366
+ await reservation.release();
367
+ await super.stop();
368
+ }
369
+ }
370
+ export class FunnelRemoteController extends BaseRemoteController {
371
+ executable;
372
+ stateDirectory;
373
+ hostname;
374
+ constructor(createGateway, loadEnabled, saveEnabled, executable, stateDirectory, hostname) {
375
+ super(createGateway, loadEnabled, saveEnabled);
376
+ this.executable = executable;
377
+ this.stateDirectory = stateDirectory;
378
+ this.hostname = hostname;
379
+ }
380
+ async start() {
381
+ const generation = ++this.generation;
382
+ const { stat } = await import("node:fs/promises");
383
+ try {
384
+ const est = await stat(this.executable);
385
+ if (!est.isFile())
386
+ throw new Error("missing");
387
+ }
388
+ catch {
389
+ this.publish({
390
+ enabled: true,
391
+ state: "unavailable",
392
+ errorCode: "component_missing",
393
+ });
394
+ return;
395
+ }
396
+ this.buffer = "";
397
+ this.publish({ enabled: true, state: "starting" });
398
+ const child = spawn(this.executable, [
399
+ "--state-dir",
400
+ path.resolve(this.stateDirectory),
401
+ "--hostname",
402
+ this.hostname,
403
+ ], {
404
+ env: withoutTailscaleSecrets(process.env),
405
+ shell: false,
406
+ stdio: ["pipe", "pipe", "pipe"],
407
+ windowsHide: true,
408
+ });
409
+ this.child = child;
410
+ child.stderr.resume();
411
+ child.stdout.setEncoding("utf8");
412
+ child.stdout.on("data", (chunk) => this.consume(generation, String(chunk)));
413
+ child.once("error", () => {
414
+ void this.enqueue(() => this.failGeneration(generation, "sidecar_launch_failed"));
415
+ });
416
+ child.once("close", (code) => {
417
+ if (generation !== this.generation || this.child !== child)
418
+ return;
419
+ this.child = undefined;
420
+ if (this.enabled) {
421
+ void this.enqueue(() => this.failGeneration(generation, code === 0 ? "sidecar_stopped" : "sidecar_exited"));
422
+ }
423
+ });
424
+ }
425
+ consume(generation, chunk) {
426
+ if (generation !== this.generation)
427
+ return;
428
+ this.buffer += chunk;
429
+ if (Buffer.byteLength(this.buffer, "utf8") > MAX_PROTOCOL_LINE &&
430
+ !this.buffer.includes("\n")) {
431
+ void this.enqueue(() => this.failGeneration(generation, "invalid_sidecar_protocol"));
432
+ return;
433
+ }
434
+ while (true) {
435
+ const newline = this.buffer.indexOf("\n");
436
+ if (newline < 0)
437
+ return;
438
+ const line = this.buffer.slice(0, newline).replace(/\r$/u, "");
439
+ this.buffer = this.buffer.slice(newline + 1);
440
+ try {
441
+ const event = parseFunnelEvent(line);
442
+ void this.enqueue(() => this.handleEvent(generation, event));
443
+ }
444
+ catch {
445
+ void this.enqueue(() => this.failGeneration(generation, "invalid_sidecar_protocol"));
446
+ return;
447
+ }
448
+ }
449
+ }
450
+ async handleEvent(generation, event) {
451
+ if (generation !== this.generation || !this.enabled)
452
+ return;
453
+ if (event.type === "login") {
454
+ this.publish({
455
+ enabled: true,
456
+ state: "needs-login",
457
+ ...(event.url ? { loginUrl: event.url } : {}),
458
+ });
459
+ return;
460
+ }
461
+ if (event.type === "error") {
462
+ await this.failGeneration(generation, event.code ?? "funnel_failed");
463
+ return;
464
+ }
465
+ if (event.type === "ready" || event.type === "serving") {
466
+ const origin = event.origin;
467
+ let gateway;
468
+ try {
469
+ if (this.gatewayValue)
470
+ await this.gatewayValue.close();
471
+ this.gatewayValue = undefined;
472
+ gateway = await this.createGateway(origin);
473
+ }
474
+ catch {
475
+ await this.failGeneration(generation, "gateway_start_failed");
476
+ return;
477
+ }
478
+ if (generation !== this.generation || !this.enabled) {
479
+ await gateway.close();
480
+ return;
481
+ }
482
+ this.gatewayValue = gateway;
483
+ const address = gateway.address();
484
+ const child = this.child;
485
+ if (!child?.stdin) {
486
+ await this.failGeneration(generation, "sidecar_stopped");
487
+ return;
488
+ }
489
+ child.stdin.write(`${JSON.stringify({
490
+ version: 1,
491
+ type: "serve",
492
+ target: `http://${address.host}:${String(address.port)}`,
493
+ })}\n`, (err) => {
494
+ if (err) {
495
+ void this.enqueue(() => this.failGeneration(generation, "control_channel_failed"));
496
+ }
497
+ });
498
+ this.publish({ enabled: true, state: "ready", origin });
499
+ }
500
+ }
501
+ }
502
+ export async function createRemoteGatewayFactory(upstreamUrl) {
503
+ return async (publicOrigin, listenPort = 0) => {
504
+ return startLocalProxyGateway({
505
+ upstreamUrl,
506
+ listenPort,
507
+ publicOrigin,
508
+ });
509
+ };
510
+ }
511
+ //# sourceMappingURL=mobile-access-remote-controllers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mobile-access-remote-controllers.js","sourceRoot":"","sources":["../../src/dsh-compat/mobile-access-remote-controllers.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,KAAK,EAAuC,MAAM,oBAAoB,CAAC;AAChF,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAEL,mBAAmB,EACnB,sBAAsB,GACvB,MAAM,kCAAkC,CAAC;AAE1C,MAAM,cAAc,GAAG,KAAK,CAAC;AAC7B,MAAM,iBAAiB,GAAG,IAAI,CAAC;AAC/B,MAAM,gBAAgB,GAAG,MAAM,CAAC;AAEhC,MAAM,oBAAoB,GAAG;IAC3B,YAAY;IACZ,YAAY;IACZ,aAAa;IACb,aAAa;CACd,CAAC;AAgBF,SAAS,YAAY,CAAC,MAA8B;IAClD,OAAO;QACL,OAAO,EAAE,MAAM,CAAC,OAAO;QACvB,KAAK,EAAE,MAAM,CAAC,KAAK;QACnB,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE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,EAAE,YAAoB,EAAE,UAAU,GAAG,CAAC,EAAE,EAAE;QACpD,OAAO,sBAAsB,CAAC;YAC5B,WAAW;YACX,UAAU;YACV,YAAY;SACb,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,34 @@
1
+ import { CpolarComponentManager } from "./mobile-access-cpolar-component.js";
2
+ import { CpolarRemoteController, FunnelRemoteController } from "./mobile-access-remote-controllers.js";
3
+ export type RemoteProviderId = "tailscale" | "cpolar";
4
+ export declare class MobileRemoteRuntime {
5
+ readonly xrkHome: string | undefined;
6
+ private readonly remoteDir;
7
+ private readonly tailscaleControlFile;
8
+ private readonly cpolarControlFile;
9
+ private readonly providerFile;
10
+ private readonly tailscaleStateDir;
11
+ readonly cpolarComponent: CpolarComponentManager;
12
+ private provider;
13
+ private createGateway;
14
+ private tailscale;
15
+ private cpolar;
16
+ private initialized;
17
+ private initPromise;
18
+ constructor(xrkHome: string | undefined);
19
+ ensureInitialized(instanceId: string): Promise<void>;
20
+ private doInitialize;
21
+ private loadControl;
22
+ private saveControl;
23
+ activeController(): FunnelRemoteController | CpolarRemoteController;
24
+ selectProvider(provider: RemoteProviderId): Promise<void>;
25
+ buildRemotePayload(): Record<string, unknown>;
26
+ setRemoteEnabled(enabled: boolean): Promise<Record<string, unknown>>;
27
+ reconnect(): Promise<Record<string, unknown>>;
28
+ resetRemote(): Promise<Record<string, unknown>>;
29
+ getProvider(): RemoteProviderId;
30
+ }
31
+ export declare function getMobileRemoteRuntime(xrkHome: string | undefined): MobileRemoteRuntime;
32
+ /** Rebuild controllers after funnel sidecar is downloaded. */
33
+ export declare function resetMobileRemoteRuntime(xrkHome: string | undefined): void;
34
+ //# sourceMappingURL=mobile-access-remote-runtime.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mobile-access-remote-runtime.d.ts","sourceRoot":"","sources":["../../src/dsh-compat/mobile-access-remote-runtime.ts"],"names":[],"mappings":"AAOA,OAAO,EACL,sBAAsB,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