@chrisjowen/wheelhouse 0.17.1 → 0.18.1

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 (398) hide show
  1. package/README.md +2 -2
  2. package/build/client/_app/immutable/assets/{0.DNJoTEVa.css → 0.Dyflbqc4.css} +1 -1
  3. package/build/client/_app/immutable/assets/0.Dyflbqc4.css.br +0 -0
  4. package/build/client/_app/immutable/assets/{0.DNJoTEVa.css.gz → 0.Dyflbqc4.css.gz} +0 -0
  5. package/build/client/_app/immutable/chunks/{CxexnUzw.js → BDtt0Y7t.js} +1 -1
  6. package/build/client/_app/immutable/chunks/BDtt0Y7t.js.br +0 -0
  7. package/build/client/_app/immutable/chunks/BDtt0Y7t.js.gz +0 -0
  8. package/build/client/_app/immutable/chunks/{CLADX83T.js → BL011DGQ.js} +1 -1
  9. package/build/client/_app/immutable/chunks/BL011DGQ.js.br +0 -0
  10. package/build/client/_app/immutable/chunks/BL011DGQ.js.gz +0 -0
  11. package/build/client/_app/immutable/chunks/{_8osrypQ.js → BSBcdyd3.js} +1 -1
  12. package/build/client/_app/immutable/chunks/BSBcdyd3.js.br +2 -0
  13. package/build/client/_app/immutable/chunks/BSBcdyd3.js.gz +0 -0
  14. package/build/client/_app/immutable/chunks/{DkntkkRH.js → Bj-Gheej.js} +1 -1
  15. package/build/client/_app/immutable/chunks/Bj-Gheej.js.br +0 -0
  16. package/build/client/_app/immutable/chunks/Bj-Gheej.js.gz +0 -0
  17. package/build/client/_app/immutable/chunks/{BS3n5c7l.js → COSi3XeB.js} +1 -1
  18. package/build/client/_app/immutable/chunks/COSi3XeB.js.br +0 -0
  19. package/build/client/_app/immutable/chunks/COSi3XeB.js.gz +0 -0
  20. package/build/client/_app/immutable/chunks/CSzf141e.js +1 -0
  21. package/build/client/_app/immutable/chunks/CSzf141e.js.br +0 -0
  22. package/build/client/_app/immutable/chunks/CSzf141e.js.gz +0 -0
  23. package/build/client/_app/immutable/chunks/{DP7xDWnQ.js → C_QL6rvF.js} +1 -1
  24. package/build/client/_app/immutable/chunks/C_QL6rvF.js.br +0 -0
  25. package/build/client/_app/immutable/chunks/C_QL6rvF.js.gz +0 -0
  26. package/build/client/_app/immutable/chunks/{CF9qC7cA.js → CoQMrCtk.js} +1 -1
  27. package/build/client/_app/immutable/chunks/CoQMrCtk.js.br +0 -0
  28. package/build/client/_app/immutable/chunks/CoQMrCtk.js.gz +0 -0
  29. package/build/client/_app/immutable/chunks/{CH2Y0BVE.js → Cpxqeawy.js} +1 -1
  30. package/build/client/_app/immutable/chunks/Cpxqeawy.js.br +0 -0
  31. package/build/client/_app/immutable/chunks/Cpxqeawy.js.gz +0 -0
  32. package/build/client/_app/immutable/chunks/{Ch7J5mLH.js → CtiH9jvV.js} +1 -1
  33. package/build/client/_app/immutable/chunks/CtiH9jvV.js.br +2 -0
  34. package/build/client/_app/immutable/chunks/CtiH9jvV.js.gz +0 -0
  35. package/build/client/_app/immutable/chunks/{DwBYQnih.js → CzBY7r8x.js} +1 -1
  36. package/build/client/_app/immutable/chunks/CzBY7r8x.js.br +0 -0
  37. package/build/client/_app/immutable/chunks/CzBY7r8x.js.gz +0 -0
  38. package/build/client/_app/immutable/chunks/{RedPhL9b.js → D2Frmdzl.js} +1 -1
  39. package/build/client/_app/immutable/chunks/D2Frmdzl.js.br +0 -0
  40. package/build/client/_app/immutable/chunks/D2Frmdzl.js.gz +0 -0
  41. package/build/client/_app/immutable/chunks/D9kzO4Vy.js +1 -0
  42. package/build/client/_app/immutable/chunks/D9kzO4Vy.js.br +0 -0
  43. package/build/client/_app/immutable/chunks/D9kzO4Vy.js.gz +0 -0
  44. package/build/client/_app/immutable/chunks/{Bgm2YDEc.js → Dcf7qESD.js} +1 -1
  45. package/build/client/_app/immutable/chunks/Dcf7qESD.js.br +0 -0
  46. package/build/client/_app/immutable/chunks/Dcf7qESD.js.gz +0 -0
  47. package/build/client/_app/immutable/chunks/{iI4tqZHC.js → Deh9Yuoc.js} +1 -1
  48. package/build/client/_app/immutable/chunks/Deh9Yuoc.js.br +0 -0
  49. package/build/client/_app/immutable/chunks/Deh9Yuoc.js.gz +0 -0
  50. package/build/client/_app/immutable/chunks/{D8F9xgmh.js → DglJ92hi.js} +1 -1
  51. package/build/client/_app/immutable/chunks/DglJ92hi.js.br +0 -0
  52. package/build/client/_app/immutable/chunks/DglJ92hi.js.gz +0 -0
  53. package/build/client/_app/immutable/chunks/{CXsGgEzT.js → I4bsCfS2.js} +1 -1
  54. package/build/client/_app/immutable/chunks/I4bsCfS2.js.br +0 -0
  55. package/build/client/_app/immutable/chunks/I4bsCfS2.js.gz +0 -0
  56. package/build/client/_app/immutable/chunks/{ClSB0siN.js → JUzTNcjv.js} +1 -1
  57. package/build/client/_app/immutable/chunks/JUzTNcjv.js.br +0 -0
  58. package/build/client/_app/immutable/chunks/JUzTNcjv.js.gz +0 -0
  59. package/build/client/_app/immutable/chunks/cM1ZMvyM.js +2 -0
  60. package/build/client/_app/immutable/chunks/cM1ZMvyM.js.br +0 -0
  61. package/build/client/_app/immutable/chunks/cM1ZMvyM.js.gz +0 -0
  62. package/build/client/_app/immutable/chunks/{CGRtmaS4.js → luPa70aT.js} +1 -1
  63. package/build/client/_app/immutable/chunks/luPa70aT.js.br +0 -0
  64. package/build/client/_app/immutable/chunks/luPa70aT.js.gz +0 -0
  65. package/build/client/_app/immutable/chunks/{BQPyzYAS.js → rwLE2q5W.js} +1 -1
  66. package/build/client/_app/immutable/chunks/rwLE2q5W.js.br +0 -0
  67. package/build/client/_app/immutable/chunks/rwLE2q5W.js.gz +0 -0
  68. package/build/client/_app/immutable/chunks/wHJhZAA4.js +1 -0
  69. package/build/client/_app/immutable/chunks/wHJhZAA4.js.br +0 -0
  70. package/build/client/_app/immutable/chunks/wHJhZAA4.js.gz +0 -0
  71. package/build/client/_app/immutable/entry/{app.DzMOOaXE.js → app.LCo0tRMU.js} +2 -2
  72. package/build/client/_app/immutable/entry/app.LCo0tRMU.js.br +0 -0
  73. package/build/client/_app/immutable/entry/app.LCo0tRMU.js.gz +0 -0
  74. package/build/client/_app/immutable/entry/start.Ce3bAKNA.js +1 -0
  75. package/build/client/_app/immutable/entry/start.Ce3bAKNA.js.br +0 -0
  76. package/build/client/_app/immutable/entry/start.Ce3bAKNA.js.gz +0 -0
  77. package/build/client/_app/immutable/nodes/{0.BIHpRnqw.js → 0.DjC9pa5r.js} +1 -1
  78. package/build/client/_app/immutable/nodes/0.DjC9pa5r.js.br +0 -0
  79. package/build/client/_app/immutable/nodes/0.DjC9pa5r.js.gz +0 -0
  80. package/build/client/_app/immutable/nodes/{1.BJIoIsvP.js → 1.BGpUfjP8.js} +1 -1
  81. package/build/client/_app/immutable/nodes/1.BGpUfjP8.js.br +0 -0
  82. package/build/client/_app/immutable/nodes/1.BGpUfjP8.js.gz +0 -0
  83. package/build/client/_app/immutable/nodes/{10.DRDVy09M.js → 10.Dqja5Hy7.js} +1 -1
  84. package/build/client/_app/immutable/nodes/10.Dqja5Hy7.js.br +0 -0
  85. package/build/client/_app/immutable/nodes/10.Dqja5Hy7.js.gz +0 -0
  86. package/build/client/_app/immutable/nodes/{11.B2EhouGG.js → 11.C2hpIuul.js} +1 -1
  87. package/build/client/_app/immutable/nodes/11.C2hpIuul.js.br +2 -0
  88. package/build/client/_app/immutable/nodes/11.C2hpIuul.js.gz +0 -0
  89. package/build/client/_app/immutable/nodes/{12.5fuIl1It.js → 12.D9gnyWPh.js} +1 -1
  90. package/build/client/_app/immutable/nodes/12.D9gnyWPh.js.br +0 -0
  91. package/build/client/_app/immutable/nodes/12.D9gnyWPh.js.gz +0 -0
  92. package/build/client/_app/immutable/nodes/{13.BHd8lAXB.js → 13.DL0THiQT.js} +1 -1
  93. package/build/client/_app/immutable/nodes/13.DL0THiQT.js.br +0 -0
  94. package/build/client/_app/immutable/nodes/13.DL0THiQT.js.gz +0 -0
  95. package/build/client/_app/immutable/nodes/{14.DgsN2-TN.js → 14.zHzRn1L0.js} +1 -1
  96. package/build/client/_app/immutable/nodes/14.zHzRn1L0.js.br +0 -0
  97. package/build/client/_app/immutable/nodes/14.zHzRn1L0.js.gz +0 -0
  98. package/build/client/_app/immutable/nodes/{15.CPHkfcQw.js → 15.CxiJzXJw.js} +1 -1
  99. package/build/client/_app/immutable/nodes/15.CxiJzXJw.js.br +0 -0
  100. package/build/client/_app/immutable/nodes/15.CxiJzXJw.js.gz +0 -0
  101. package/build/client/_app/immutable/nodes/{16.CrpxQoZ7.js → 16.ltkCLaiY.js} +1 -1
  102. package/build/client/_app/immutable/nodes/16.ltkCLaiY.js.br +0 -0
  103. package/build/client/_app/immutable/nodes/16.ltkCLaiY.js.gz +0 -0
  104. package/build/client/_app/immutable/nodes/{17.B83y7TTZ.js → 17.8mjwurTl.js} +1 -1
  105. package/build/client/_app/immutable/nodes/17.8mjwurTl.js.br +0 -0
  106. package/build/client/_app/immutable/nodes/17.8mjwurTl.js.gz +0 -0
  107. package/build/client/_app/immutable/nodes/{19.BGzbdUG8.js → 19.DIpFUdcm.js} +1 -1
  108. package/build/client/_app/immutable/nodes/19.DIpFUdcm.js.br +0 -0
  109. package/build/client/_app/immutable/nodes/19.DIpFUdcm.js.gz +0 -0
  110. package/build/client/_app/immutable/nodes/{2.B_zXlRDw.js → 2.CarjBwi1.js} +1 -1
  111. package/build/client/_app/immutable/nodes/2.CarjBwi1.js.br +0 -0
  112. package/build/client/_app/immutable/nodes/2.CarjBwi1.js.gz +0 -0
  113. package/build/client/_app/immutable/nodes/{20.CQE-Zjw-.js → 20.BP6YYSQm.js} +1 -1
  114. package/build/client/_app/immutable/nodes/20.BP6YYSQm.js.br +0 -0
  115. package/build/client/_app/immutable/nodes/20.BP6YYSQm.js.gz +0 -0
  116. package/build/client/_app/immutable/nodes/{21.BjSp2mZI.js → 21.lQoTeuLN.js} +1 -1
  117. package/build/client/_app/immutable/nodes/21.lQoTeuLN.js.br +0 -0
  118. package/build/client/_app/immutable/nodes/21.lQoTeuLN.js.gz +0 -0
  119. package/build/client/_app/immutable/nodes/{22.BycUFjCM.js → 22.DmHOHt5L.js} +1 -1
  120. package/build/client/_app/immutable/nodes/22.DmHOHt5L.js.br +0 -0
  121. package/build/client/_app/immutable/nodes/22.DmHOHt5L.js.gz +0 -0
  122. package/build/client/_app/immutable/nodes/{23.BjOud3nL.js → 23.D7UbkVJG.js} +1 -1
  123. package/build/client/_app/immutable/nodes/23.D7UbkVJG.js.br +0 -0
  124. package/build/client/_app/immutable/nodes/23.D7UbkVJG.js.gz +0 -0
  125. package/build/client/_app/immutable/nodes/{24.DmaWt7EU.js → 24.B6o--6Mq.js} +1 -1
  126. package/build/client/_app/immutable/nodes/24.B6o--6Mq.js.br +0 -0
  127. package/build/client/_app/immutable/nodes/24.B6o--6Mq.js.gz +0 -0
  128. package/build/client/_app/immutable/nodes/25.C4hB5RaJ.js +20 -0
  129. package/build/client/_app/immutable/nodes/25.C4hB5RaJ.js.br +0 -0
  130. package/build/client/_app/immutable/nodes/25.C4hB5RaJ.js.gz +0 -0
  131. package/build/client/_app/immutable/nodes/{26.BxG4S8mB.js → 26.CbeAF_H2.js} +1 -1
  132. package/build/client/_app/immutable/nodes/26.CbeAF_H2.js.br +0 -0
  133. package/build/client/_app/immutable/nodes/26.CbeAF_H2.js.gz +0 -0
  134. package/build/client/_app/immutable/nodes/{28.Ds4FDR_a.js → 28.D3Nqqpa-.js} +1 -1
  135. package/build/client/_app/immutable/nodes/28.D3Nqqpa-.js.br +0 -0
  136. package/build/client/_app/immutable/nodes/28.D3Nqqpa-.js.gz +0 -0
  137. package/build/client/_app/immutable/nodes/{3.CldWfpKa.js → 3.BgWGx5YP.js} +1 -1
  138. package/build/client/_app/immutable/nodes/3.BgWGx5YP.js.br +0 -0
  139. package/build/client/_app/immutable/nodes/3.BgWGx5YP.js.gz +0 -0
  140. package/build/client/_app/immutable/nodes/{4.Ds0FcslK.js → 4.CmSxKRLa.js} +1 -1
  141. package/build/client/_app/immutable/nodes/4.CmSxKRLa.js.br +0 -0
  142. package/build/client/_app/immutable/nodes/4.CmSxKRLa.js.gz +0 -0
  143. package/build/client/_app/immutable/nodes/{6.CvP4hVA3.js → 6.CExYN4s7.js} +1 -1
  144. package/build/client/_app/immutable/nodes/6.CExYN4s7.js.br +0 -0
  145. package/build/client/_app/immutable/nodes/6.CExYN4s7.js.gz +0 -0
  146. package/build/client/_app/immutable/nodes/{7.Ca_DVOMc.js → 7.B5DaW8rR.js} +1 -1
  147. package/build/client/_app/immutable/nodes/7.B5DaW8rR.js.br +0 -0
  148. package/build/client/_app/immutable/nodes/7.B5DaW8rR.js.gz +0 -0
  149. package/build/client/_app/immutable/nodes/{8.D8JqGvkd.js → 8.BAxGmD9j.js} +1 -1
  150. package/build/client/_app/immutable/nodes/8.BAxGmD9j.js.br +0 -0
  151. package/build/client/_app/immutable/nodes/8.BAxGmD9j.js.gz +0 -0
  152. package/build/client/_app/immutable/nodes/{9.CHSFcAbh.js → 9.B05Fdcd3.js} +1 -1
  153. package/build/client/_app/immutable/nodes/9.B05Fdcd3.js.br +0 -0
  154. package/build/client/_app/immutable/nodes/9.B05Fdcd3.js.gz +0 -0
  155. package/build/client/_app/version.json +1 -1
  156. package/build/client/_app/version.json.br +0 -0
  157. package/build/client/_app/version.json.gz +0 -0
  158. package/build/handler.js +4 -4
  159. package/build/index.js +4 -4
  160. package/build/server/chunks/chunks/{detail.js-T1brxxWW.js → detail.js-Cl-2Oh1e.js} +2 -2
  161. package/build/server/chunks/chunks/{feedback.js-0cB22LBt.js → feedback.js-7UNSvLAt.js} +2 -2
  162. package/build/server/chunks/chunks/{harness.js-DPojOlFJ.js → harness.js-C1CYCy4c.js} +2 -2
  163. package/build/server/chunks/chunks/{internal.js-BJRpqxxM.js → internal.js-DK7xaPVY.js} +3 -3
  164. package/build/server/chunks/chunks/{keychain.js-CsTOqhf4.js → keychain.js-CJIUvfTQ.js} +2 -2
  165. package/build/server/chunks/chunks/{marketplace-service.js-CckS3apE.js → marketplace-service.js-nufBLQts.js} +2 -2
  166. package/build/server/chunks/chunks/{page.js-D5V2PN2q.js → page.js-BVYP5P0m.js} +2 -2
  167. package/build/server/chunks/chunks/{previewhelper2.js-DRcdOpNv.js → previewhelper2.js-DPz8atKx.js} +2 -2
  168. package/build/server/chunks/chunks/{repo.js-CsdCOmUL.js → repo.js-CPooM_kq.js} +2 -2
  169. package/build/server/chunks/chunks/{runtime.js-CbmzOl0F.js → runtime.js-Bj0q2OTu.js} +12382 -11645
  170. package/build/server/chunks/chunks/{service.js-DztM8MY5.js → service.js-VAj_rquU.js} +2 -2
  171. package/build/server/chunks/chunks/{service2.js-DQccL6zz.js → service2.js-CbbDamOZ.js} +151 -441
  172. package/build/server/chunks/chunks/{starter.js-ROzdTBeO.js → starter.js-Bs7SaswL.js} +2 -2
  173. package/build/server/chunks/chunks/terminal.js-D6YKc4IS.js +189 -0
  174. package/build/server/chunks/chunks/{view.js-BDo4J83f.js → view.js-BiofJDNZ.js} +2 -2
  175. package/build/server/chunks/entries/endpoints/api/apps/_op_/{_server.ts.js-BTTHbZK6.js → _server.ts.js-Bjepmw90.js} +5 -5
  176. package/build/server/chunks/entries/endpoints/api/cloud/{_server.ts.js-m9cTbE-7.js → _server.ts.js-BkCwjJYX.js} +3 -3
  177. package/build/server/chunks/entries/endpoints/api/cloud/previews/{_server.ts.js-z8BbPJ2P.js → _server.ts.js-CXvN0rdQ.js} +5 -5
  178. package/build/server/chunks/entries/endpoints/api/events/{_server.ts.js-BniUpesu.js → _server.ts.js-v08IH4y_.js} +5 -5
  179. package/build/server/chunks/entries/endpoints/api/files/{_server.ts.js-B0WcXQJH.js → _server.ts.js-d0XuZob6.js} +5 -5
  180. package/build/server/chunks/entries/endpoints/api/firstmate/chat/{_server.ts.js-CncNeTwM.js → _server.ts.js-CZEvtgmJ.js} +5 -5
  181. package/build/server/chunks/entries/endpoints/api/firstmate/commands/{_server.ts.js-hnvcy9Ia.js → _server.ts.js-DojVtSlb.js} +5 -5
  182. package/build/server/chunks/entries/endpoints/api/firstmate/dismiss/{_server.ts.js-BQgc12gv.js → _server.ts.js-DXBMuJxa.js} +5 -5
  183. package/build/server/chunks/entries/endpoints/api/firstmate/input/{_server.ts.js-Cpq1OUlv.js → _server.ts.js-CL2HsmMI.js} +5 -5
  184. package/build/server/chunks/entries/endpoints/api/firstmate/interrupt/{_server.ts.js-DcduvTz-.js → _server.ts.js-Bi8yHsen.js} +5 -5
  185. package/build/server/chunks/entries/endpoints/api/firstmate/messages/{_server.ts.js-r_OTtndR.js → _server.ts.js-CiPPnBqE.js} +5 -5
  186. package/build/server/chunks/entries/endpoints/api/firstmate/pick/{_server.ts.js-DRc0m-xP.js → _server.ts.js-Dm0WehBE.js} +5 -5
  187. package/build/server/chunks/entries/endpoints/api/firstmate/reactions/{_server.ts.js-DBrNAwQy.js → _server.ts.js-CmK0bQFV.js} +5 -5
  188. package/build/server/chunks/entries/endpoints/api/firstmate/start/{_server.ts.js-D1Q8V-y_.js → _server.ts.js-CIR1beQf.js} +5 -5
  189. package/build/server/chunks/entries/endpoints/api/fleet/{_server.ts.js-cN8CO68M.js → _server.ts.js-B7G60uTf.js} +5 -5
  190. package/build/server/chunks/entries/endpoints/api/gateway/{_server.ts.js-BSpvCzuX.js → _server.ts.js-BKqRzjah.js} +5 -5
  191. package/build/server/chunks/entries/endpoints/api/health/{_server.ts.js-Cs9IYII5.js → _server.ts.js-DxYmytE-.js} +5 -5
  192. package/build/server/chunks/entries/endpoints/api/inbox/{_server.ts.js-D2iFH361.js → _server.ts.js-BHywbWob.js} +5 -5
  193. package/build/server/chunks/entries/endpoints/api/inbox/report/{_server.ts.js-BnZZNGqp.js → _server.ts.js-CK3DFFDx.js} +5 -5
  194. package/build/server/chunks/entries/endpoints/api/insights/{_server.ts.js-6-pUqSbs.js → _server.ts.js-AUTZjM3m.js} +5 -5
  195. package/build/server/chunks/entries/endpoints/api/plugins/_plugin_/config/{_server.ts.js-BRHI8EzR.js → _server.ts.js-COr7_-xt.js} +5 -5
  196. package/build/server/chunks/entries/endpoints/api/plugins/_plugin_/feedback/{_server.ts.js-D75GJhqf.js → _server.ts.js-DdgCnxxi.js} +6 -6
  197. package/build/server/chunks/entries/endpoints/api/plugins/_plugin_/feedback/summary/{_server.ts.js-DXlq6GNe.js → _server.ts.js-B-Bt7Bbc.js} +7 -7
  198. package/build/server/chunks/entries/endpoints/api/plugins/_plugin_/icon/_icon_/{_server.ts.js-DzCq67Pq.js → _server.ts.js-DI9Fk8K7.js} +5 -5
  199. package/build/server/chunks/entries/endpoints/api/plugins/_plugin_/load/{_server.ts.js-DP4Br_Kb.js → _server.ts.js-BQvP1Q-R.js} +2 -2
  200. package/build/server/chunks/entries/endpoints/api/plugins/_plugin_/ui/_...path_/{_server.ts.js-BTZibvW1.js → _server.ts.js-CmtQrDJT.js} +5 -5
  201. package/build/server/chunks/entries/endpoints/api/plugins/_plugin_/update/{_server.ts.js-BVEiTedk.js → _server.ts.js-CU0RTwoG.js} +2 -2
  202. package/build/server/chunks/entries/endpoints/api/plugins/{_server.ts.js-BARKIuL9.js → _server.ts.js-Bdirqc6N.js} +5 -5
  203. package/build/server/chunks/entries/endpoints/api/plugins/inspect/{_server.ts.js-vXn-DxW7.js → _server.ts.js-EbyqpOEx.js} +2 -2
  204. package/build/server/chunks/entries/endpoints/api/plugins/install/{_server.ts.js-BrTsfhpU.js → _server.ts.js-BwkGtYFQ.js} +2 -2
  205. package/build/server/chunks/entries/endpoints/api/plugins/marketplace/{_server.ts.js-uLUVa1Yc.js → _server.ts.js-CYD7YCIF.js} +6 -6
  206. package/build/server/chunks/entries/endpoints/api/plugins/marketplace/icon/_name_/{_server.ts.js-fFGC33td.js → _server.ts.js-gmMaK6QY.js} +6 -6
  207. package/build/server/chunks/entries/endpoints/api/plugins/marketplace/registries/{_server.ts.js-CV30SKJH.js → _server.ts.js-D43_Ml9Y.js} +6 -6
  208. package/build/server/chunks/entries/endpoints/api/plugins/roles/{_server.ts.js-BmywjWsD.js → _server.ts.js-BEUuxHTl.js} +5 -5
  209. package/build/server/chunks/entries/endpoints/api/plugins/updates/{_server.ts.js-C928jxXA.js → _server.ts.js-C1xwZyfT.js} +2 -2
  210. package/build/server/chunks/entries/endpoints/api/previews/check/{_server.ts.js-DsVDHPoG.js → _server.ts.js-qZdJXsGA.js} +5 -5
  211. package/build/server/chunks/entries/endpoints/api/projects/_id_/passage/{_server.ts.js-B5kai_f_.js → _server.ts.js-BM-c0-Ju.js} +6 -6
  212. package/build/server/chunks/entries/endpoints/api/projects/_id_/passage/commands/{_server.ts.js-DFdhVYKr.js → _server.ts.js-CHIAK59y.js} +6 -6
  213. package/build/server/chunks/entries/endpoints/api/projects/_id_/passage/consent/{_server.ts.js-C3rHPgm9.js → _server.ts.js-CH1IHuDe.js} +6 -6
  214. package/build/server/chunks/entries/endpoints/api/projects/_id_/passage/draft/{_server.ts.js-GMslvRRG.js → _server.ts.js-DgeSMGot.js} +6 -6
  215. package/build/server/chunks/entries/endpoints/api/projects/_id_/passage/file/{_server.ts.js-G6S2vjwB.js → _server.ts.js-BQQc8aTH.js} +6 -6
  216. package/build/server/chunks/entries/endpoints/api/projects/_id_/passage/test/{_server.ts.js-nDbd4-FQ.js → _server.ts.js-D92Af8_M.js} +6 -6
  217. package/build/server/chunks/entries/endpoints/api/second-mates/_id_/peek/{_server.ts.js-v9aqCXY5.js → _server.ts.js-7v53Dp0B.js} +5 -5
  218. package/build/server/chunks/entries/endpoints/api/services/{_server.ts.js-BLxZZ6h-.js → _server.ts.js-cTrwNrLS.js} +5 -5
  219. package/build/server/chunks/entries/endpoints/api/setup/{_server.ts.js-BViJ-Ufk.js → _server.ts.js-CmmK_jyt.js} +23 -10
  220. package/build/server/chunks/entries/endpoints/api/slots/{_server.ts.js-T0HJn3Nc.js → _server.ts.js-D7-4JbRn.js} +5 -5
  221. package/build/server/chunks/entries/endpoints/api/tasks/_id_/{_server.ts.js-DN9vhG-X.js → _server.ts.js-BI5hlIlZ.js} +6 -6
  222. package/build/server/chunks/entries/endpoints/api/tasks/_id_/artifacts/_...name_/{_server.ts.js-azR55GM-.js → _server.ts.js-DIP-NQ7a.js} +5 -5
  223. package/build/server/chunks/entries/endpoints/api/tasks/_id_/diff/{_server.ts.js-NfTPilV6.js → _server.ts.js-BP9_6wCq.js} +5 -5
  224. package/build/server/chunks/entries/endpoints/api/tasks/_id_/output/{_server.ts.js-DzTACS2K.js → _server.ts.js-BxO3Yh5r.js} +5 -5
  225. package/build/server/chunks/entries/endpoints/api/tasks/_id_/preview/{_server.ts.js-iObKq15r.js → _server.ts.js-jojxY4wz.js} +5 -5
  226. package/build/server/chunks/entries/endpoints/api/tasks/_id_/preview/helper/{_server.ts.js-CFL0gv8m.js → _server.ts.js-BAgqe8_d.js} +6 -6
  227. package/build/server/chunks/entries/endpoints/api/vault/{_server.ts.js-CxnJ6MH1.js → _server.ts.js-DBYZ3kuk.js} +5 -5
  228. package/build/server/chunks/entries/endpoints/api/wheelhouse/source/{_server.ts.js-BzHUulBR.js → _server.ts.js-Bvrz69xX.js} +2 -2
  229. package/build/server/chunks/entries/endpoints/api/wheelhouse/update/{_server.ts.js-CwIEgYLU.js → _server.ts.js-CAOg-IEp.js} +2 -2
  230. package/build/server/chunks/entries/endpoints/api/wheelhouse/upgrade/{_server.ts.js-BfV0Rwjv.js → _server.ts.js-CGEnB-6H.js} +2 -2
  231. package/build/server/chunks/entries/endpoints/tasks/_id_/review/{_server.ts.js-D0M-kf3z.js → _server.ts.js-BL2svrRm.js} +5 -5
  232. package/build/server/chunks/entries/{hooks.server.js-BK27kVep.js → hooks.server.js-BEXBvrCk.js} +6 -6
  233. package/build/server/chunks/entries/pages/{_layout.server.ts.js-thMV7ofo.js → _layout.server.ts.js-D3NceNiH.js} +2 -2
  234. package/build/server/chunks/entries/pages/{_page.server.ts.js-IJJCfEOr.js → _page.server.ts.js-DspaiJqP.js} +2 -2
  235. package/build/server/chunks/entries/pages/{_page.svelte.js-DK0vMDpM.js → _page.svelte.js-dxbEuRWy.js} +2 -2
  236. package/build/server/chunks/entries/pages/decisions/{_page.server.ts.js-BknW8CoP.js → _page.server.ts.js-BmPOLjxU.js} +2 -2
  237. package/build/server/chunks/entries/pages/deck/{_page.server.ts.js-FcsedjYb.js → _page.server.ts.js-CCy338c9.js} +2 -2
  238. package/build/server/chunks/entries/pages/files/{_page.server.ts.js-NxhxpluO.js → _page.server.ts.js-bxjhlft-.js} +2 -2
  239. package/build/server/chunks/entries/pages/harbour/{_page.server.ts.js-D0vCnVfw.js → _page.server.ts.js-CZFURrsD.js} +2 -2
  240. package/build/server/chunks/entries/pages/headroom/{_page.server.ts.js-8pe9nMCl.js → _page.server.ts.js-DvR2S3u3.js} +2 -2
  241. package/build/server/chunks/entries/pages/inbox/{_page.server.ts.js-D5ACh022.js → _page.server.ts.js-BesipmjT.js} +2 -2
  242. package/build/server/chunks/entries/pages/plugins/_plugin_/_page_/{_page.server.ts.js-BKpNXqUB.js → _page.server.ts.js-DHdujj6W.js} +2 -2
  243. package/build/server/chunks/entries/pages/projects/_id_/{_page.server.ts.js-DKtUeDFH.js → _page.server.ts.js-xmIQiuu2.js} +3 -3
  244. package/build/server/chunks/entries/pages/projects/_id_/_plugin_/_tab_/{_page.server.ts.js-CAfpJ8z4.js → _page.server.ts.js-D_Ii0uof.js} +3 -3
  245. package/build/server/chunks/entries/pages/projects/_id_/passage/{_page.server.ts.js-DhvAOslS.js → _page.server.ts.js-n6e3g77p.js} +4 -4
  246. package/build/server/chunks/entries/pages/projects/_id_/passage/edit/{_page.server.ts.js-BbR8eGg8.js → _page.server.ts.js-ZJwXvTNk.js} +2 -2
  247. package/build/server/chunks/entries/pages/remotes/{_page.server.ts.js-CFi9Cpz4.js → _page.server.ts.js-DbD1fRK0.js} +2 -2
  248. package/build/server/chunks/entries/pages/settings/cloud/{_page.server.ts.js-CGyBG4Yp.js → _page.server.ts.js-C_UO9VhC.js} +2 -2
  249. package/build/server/chunks/entries/pages/settings/gateway/{_page.server.ts.js-Bh0E2kwq.js → _page.server.ts.js-DmW9-_yt.js} +2 -2
  250. package/build/server/chunks/entries/pages/settings/plugins/{_page.server.ts.js-DcSZoBEC.js → _page.server.ts.js-BxdFy--G.js} +2 -2
  251. package/build/server/chunks/entries/pages/settings/plugins/_plugin_/{_page.server.ts.js-v3Tp8x_0.js → _page.server.ts.js-BfkLEaaA.js} +2 -2
  252. package/build/server/chunks/entries/pages/settings/setup/{_page.server.ts.js-BnpgnteD.js → _page.server.ts.js-CkR40WPa.js} +2 -2
  253. package/build/server/chunks/entries/pages/settings/update/{_page.server.ts.js-DQfv8ZWG.js → _page.server.ts.js-CN1Ahy44.js} +2 -2
  254. package/build/server/chunks/entries/pages/setup/{_page.server.ts.js-CvG2Lr9C.js → _page.server.ts.js-4IWnC99t.js} +4 -4
  255. package/build/server/chunks/entries/pages/setup/{_page.svelte.js-BZsw7k9z.js → _page.svelte.js-Beyd7UV-.js} +206 -33
  256. package/build/server/chunks/entries/pages/tasks/_id_/{_page.server.ts.js-_ivyEUli.js → _page.server.ts.js-BOxovAbm.js} +3 -3
  257. package/build/server/chunks/entries/pages/tasks/_id_/doc/{_page.server.ts.js-CSJ4X_eg.js → _page.server.ts.js-Bmg4TjLJ.js} +2 -2
  258. package/build/server/chunks/entries/pages/time/{_page.server.ts.js-CUc80zxD.js → _page.server.ts.js-D7R4GOAK.js} +2 -2
  259. package/build/server/chunks/{handler-CBnQILkF.js → handler-Bsxke96k.js} +3 -3
  260. package/build/server/chunks/{index.js-8K34DF7Q.js → index.js-CcawFdzD.js} +2 -2
  261. package/build/server/chunks/{manifest.js-DqAt-2-E.js → manifest.js-DkK5FPTc.js} +87 -87
  262. package/build/server/chunks/nodes/{0.js-B_9UrGRh.js → 0.js-Dr88qrfQ.js} +8 -8
  263. package/build/server/chunks/nodes/{1.js-DHSqapc6.js → 1.js-D9Gz264j.js} +2 -2
  264. package/build/server/chunks/nodes/{10.js-Cw8UPtK2.js → 10.js-DyFJpcP6.js} +2 -2
  265. package/build/server/chunks/nodes/{11.js-BIyDysEr.js → 11.js-CHYjTTCN.js} +7 -7
  266. package/build/server/chunks/nodes/{12.js-ClZNXjgF.js → 12.js-CMF6MLfu.js} +8 -8
  267. package/build/server/chunks/nodes/{13.js-B8qskPtO.js → 13.js-Y2UOSc1A.js} +8 -8
  268. package/build/server/chunks/nodes/{14.js-DRbS2pR2.js → 14.js-B1dU02LJ.js} +9 -9
  269. package/build/server/chunks/nodes/{15.js-EWY83mDS.js → 15.js-s36rxaaa.js} +8 -8
  270. package/build/server/chunks/nodes/{16.js-Cm0oYApC.js → 16.js-C_GznDot.js} +6 -6
  271. package/build/server/chunks/nodes/{17.js-Cu5a2UaQ.js → 17.js-B_z-Yacj.js} +2 -2
  272. package/build/server/chunks/nodes/{19.js-B7TKyMV0.js → 19.js-7kkszInA.js} +6 -6
  273. package/build/server/chunks/nodes/{2.js-DltTHZOL.js → 2.js-BoKn8yL8.js} +8 -8
  274. package/build/server/chunks/nodes/{20.js-CwLFSrxO.js → 20.js-Duw5u3lU.js} +7 -7
  275. package/build/server/chunks/nodes/{21.js-D_0U5UVP.js → 21.js-DDgwWnZG.js} +7 -7
  276. package/build/server/chunks/nodes/{22.js-C2r9JmW7.js → 22.js-8U2MYvHd.js} +7 -7
  277. package/build/server/chunks/nodes/{23.js-h4YwJvrO.js → 23.js-Dvy1bm8Z.js} +8 -8
  278. package/build/server/chunks/nodes/{24.js-BciJ1KTf.js → 24.js-C0hrPaj8.js} +4 -4
  279. package/build/server/chunks/nodes/{25.js-ZCknzNaV.js → 25.js-DPILN__F.js} +9 -9
  280. package/build/server/chunks/nodes/{26.js-BUolTInv.js → 26.js-g0xLmQX6.js} +8 -8
  281. package/build/server/chunks/nodes/{27.js-DcvlJkEN.js → 27.js-D-RYuUrP.js} +7 -7
  282. package/build/server/chunks/nodes/{28.js-DPp6-E4I.js → 28.js-ChEjRlOd.js} +7 -7
  283. package/build/server/chunks/nodes/{3.js-CLE5bCBt.js → 3.js-2LHex_7S.js} +7 -7
  284. package/build/server/chunks/nodes/{4.js-BXXDgWZn.js → 4.js-B0jcFsXF.js} +7 -7
  285. package/build/server/chunks/nodes/{5.js-BtthxHsw.js → 5.js-CeqH-HPW.js} +6 -6
  286. package/build/server/chunks/nodes/{6.js-C3hPPfLf.js → 6.js-BuLAK7U9.js} +7 -7
  287. package/build/server/chunks/nodes/{7.js-v18x97qv.js → 7.js-Ipoo2cZQ.js} +7 -7
  288. package/build/server/chunks/nodes/{8.js-Csojentz.js → 8.js-BffjWe3B.js} +7 -7
  289. package/build/server/chunks/nodes/{9.js-3NVn9Z4u.js → 9.js-CCDefHMh.js} +2 -2
  290. package/dist/cli.js +314 -157
  291. package/dist/wh-vault.js +1 -1
  292. package/package.json +2 -1
  293. package/skills/manage-wheelhouse/references/operations.md +53 -51
  294. package/build/client/_app/immutable/assets/0.DNJoTEVa.css.br +0 -0
  295. package/build/client/_app/immutable/chunks/BQPyzYAS.js.br +0 -0
  296. package/build/client/_app/immutable/chunks/BQPyzYAS.js.gz +0 -0
  297. package/build/client/_app/immutable/chunks/BS3n5c7l.js.br +0 -0
  298. package/build/client/_app/immutable/chunks/BS3n5c7l.js.gz +0 -0
  299. package/build/client/_app/immutable/chunks/Bgm2YDEc.js.br +0 -0
  300. package/build/client/_app/immutable/chunks/Bgm2YDEc.js.gz +0 -0
  301. package/build/client/_app/immutable/chunks/CF9qC7cA.js.br +0 -0
  302. package/build/client/_app/immutable/chunks/CF9qC7cA.js.gz +0 -0
  303. package/build/client/_app/immutable/chunks/CGRtmaS4.js.br +0 -0
  304. package/build/client/_app/immutable/chunks/CGRtmaS4.js.gz +0 -0
  305. package/build/client/_app/immutable/chunks/CH2Y0BVE.js.br +0 -0
  306. package/build/client/_app/immutable/chunks/CH2Y0BVE.js.gz +0 -0
  307. package/build/client/_app/immutable/chunks/CLADX83T.js.br +0 -0
  308. package/build/client/_app/immutable/chunks/CLADX83T.js.gz +0 -0
  309. package/build/client/_app/immutable/chunks/CS4t4atW.js +0 -1
  310. package/build/client/_app/immutable/chunks/CS4t4atW.js.br +0 -0
  311. package/build/client/_app/immutable/chunks/CS4t4atW.js.gz +0 -0
  312. package/build/client/_app/immutable/chunks/CU0ZJcdF.js +0 -2
  313. package/build/client/_app/immutable/chunks/CU0ZJcdF.js.br +0 -0
  314. package/build/client/_app/immutable/chunks/CU0ZJcdF.js.gz +0 -0
  315. package/build/client/_app/immutable/chunks/CXsGgEzT.js.br +0 -0
  316. package/build/client/_app/immutable/chunks/CXsGgEzT.js.gz +0 -0
  317. package/build/client/_app/immutable/chunks/Ch7J5mLH.js.br +0 -0
  318. package/build/client/_app/immutable/chunks/Ch7J5mLH.js.gz +0 -0
  319. package/build/client/_app/immutable/chunks/ClSB0siN.js.br +0 -0
  320. package/build/client/_app/immutable/chunks/ClSB0siN.js.gz +0 -0
  321. package/build/client/_app/immutable/chunks/CxexnUzw.js.br +0 -0
  322. package/build/client/_app/immutable/chunks/CxexnUzw.js.gz +0 -0
  323. package/build/client/_app/immutable/chunks/D8F9xgmh.js.br +0 -0
  324. package/build/client/_app/immutable/chunks/D8F9xgmh.js.gz +0 -0
  325. package/build/client/_app/immutable/chunks/DP7xDWnQ.js.br +0 -0
  326. package/build/client/_app/immutable/chunks/DP7xDWnQ.js.gz +0 -0
  327. package/build/client/_app/immutable/chunks/DkntkkRH.js.br +0 -0
  328. package/build/client/_app/immutable/chunks/DkntkkRH.js.gz +0 -0
  329. package/build/client/_app/immutable/chunks/DwBYQnih.js.br +0 -0
  330. package/build/client/_app/immutable/chunks/DwBYQnih.js.gz +0 -0
  331. package/build/client/_app/immutable/chunks/RedPhL9b.js.br +0 -0
  332. package/build/client/_app/immutable/chunks/RedPhL9b.js.gz +0 -0
  333. package/build/client/_app/immutable/chunks/XSztV5e-.js +0 -1
  334. package/build/client/_app/immutable/chunks/XSztV5e-.js.br +0 -0
  335. package/build/client/_app/immutable/chunks/XSztV5e-.js.gz +0 -0
  336. package/build/client/_app/immutable/chunks/_8osrypQ.js.br +0 -2
  337. package/build/client/_app/immutable/chunks/_8osrypQ.js.gz +0 -0
  338. package/build/client/_app/immutable/chunks/iI4tqZHC.js.br +0 -0
  339. package/build/client/_app/immutable/chunks/iI4tqZHC.js.gz +0 -0
  340. package/build/client/_app/immutable/entry/app.DzMOOaXE.js.br +0 -0
  341. package/build/client/_app/immutable/entry/app.DzMOOaXE.js.gz +0 -0
  342. package/build/client/_app/immutable/entry/start.BP7YKN_Q.js +0 -1
  343. package/build/client/_app/immutable/entry/start.BP7YKN_Q.js.br +0 -0
  344. package/build/client/_app/immutable/entry/start.BP7YKN_Q.js.gz +0 -0
  345. package/build/client/_app/immutable/nodes/0.BIHpRnqw.js.br +0 -0
  346. package/build/client/_app/immutable/nodes/0.BIHpRnqw.js.gz +0 -0
  347. package/build/client/_app/immutable/nodes/1.BJIoIsvP.js.br +0 -0
  348. package/build/client/_app/immutable/nodes/1.BJIoIsvP.js.gz +0 -0
  349. package/build/client/_app/immutable/nodes/10.DRDVy09M.js.br +0 -0
  350. package/build/client/_app/immutable/nodes/10.DRDVy09M.js.gz +0 -0
  351. package/build/client/_app/immutable/nodes/11.B2EhouGG.js.br +0 -0
  352. package/build/client/_app/immutable/nodes/11.B2EhouGG.js.gz +0 -0
  353. package/build/client/_app/immutable/nodes/12.5fuIl1It.js.br +0 -0
  354. package/build/client/_app/immutable/nodes/12.5fuIl1It.js.gz +0 -0
  355. package/build/client/_app/immutable/nodes/13.BHd8lAXB.js.br +0 -0
  356. package/build/client/_app/immutable/nodes/13.BHd8lAXB.js.gz +0 -0
  357. package/build/client/_app/immutable/nodes/14.DgsN2-TN.js.br +0 -0
  358. package/build/client/_app/immutable/nodes/14.DgsN2-TN.js.gz +0 -0
  359. package/build/client/_app/immutable/nodes/15.CPHkfcQw.js.br +0 -0
  360. package/build/client/_app/immutable/nodes/15.CPHkfcQw.js.gz +0 -0
  361. package/build/client/_app/immutable/nodes/16.CrpxQoZ7.js.br +0 -0
  362. package/build/client/_app/immutable/nodes/16.CrpxQoZ7.js.gz +0 -0
  363. package/build/client/_app/immutable/nodes/17.B83y7TTZ.js.br +0 -0
  364. package/build/client/_app/immutable/nodes/17.B83y7TTZ.js.gz +0 -0
  365. package/build/client/_app/immutable/nodes/19.BGzbdUG8.js.br +0 -0
  366. package/build/client/_app/immutable/nodes/19.BGzbdUG8.js.gz +0 -0
  367. package/build/client/_app/immutable/nodes/2.B_zXlRDw.js.br +0 -0
  368. package/build/client/_app/immutable/nodes/2.B_zXlRDw.js.gz +0 -0
  369. package/build/client/_app/immutable/nodes/20.CQE-Zjw-.js.br +0 -0
  370. package/build/client/_app/immutable/nodes/20.CQE-Zjw-.js.gz +0 -0
  371. package/build/client/_app/immutable/nodes/21.BjSp2mZI.js.br +0 -0
  372. package/build/client/_app/immutable/nodes/21.BjSp2mZI.js.gz +0 -0
  373. package/build/client/_app/immutable/nodes/22.BycUFjCM.js.br +0 -0
  374. package/build/client/_app/immutable/nodes/22.BycUFjCM.js.gz +0 -0
  375. package/build/client/_app/immutable/nodes/23.BjOud3nL.js.br +0 -0
  376. package/build/client/_app/immutable/nodes/23.BjOud3nL.js.gz +0 -0
  377. package/build/client/_app/immutable/nodes/24.DmaWt7EU.js.br +0 -0
  378. package/build/client/_app/immutable/nodes/24.DmaWt7EU.js.gz +0 -0
  379. package/build/client/_app/immutable/nodes/25.DpdKssoo.js +0 -15
  380. package/build/client/_app/immutable/nodes/25.DpdKssoo.js.br +0 -0
  381. package/build/client/_app/immutable/nodes/25.DpdKssoo.js.gz +0 -0
  382. package/build/client/_app/immutable/nodes/26.BxG4S8mB.js.br +0 -0
  383. package/build/client/_app/immutable/nodes/26.BxG4S8mB.js.gz +0 -0
  384. package/build/client/_app/immutable/nodes/28.Ds4FDR_a.js.br +0 -0
  385. package/build/client/_app/immutable/nodes/28.Ds4FDR_a.js.gz +0 -0
  386. package/build/client/_app/immutable/nodes/3.CldWfpKa.js.br +0 -0
  387. package/build/client/_app/immutable/nodes/3.CldWfpKa.js.gz +0 -0
  388. package/build/client/_app/immutable/nodes/4.Ds0FcslK.js.br +0 -0
  389. package/build/client/_app/immutable/nodes/4.Ds0FcslK.js.gz +0 -0
  390. package/build/client/_app/immutable/nodes/6.CvP4hVA3.js.br +0 -0
  391. package/build/client/_app/immutable/nodes/6.CvP4hVA3.js.gz +0 -0
  392. package/build/client/_app/immutable/nodes/7.Ca_DVOMc.js.br +0 -0
  393. package/build/client/_app/immutable/nodes/7.Ca_DVOMc.js.gz +0 -0
  394. package/build/client/_app/immutable/nodes/8.D8JqGvkd.js.br +0 -0
  395. package/build/client/_app/immutable/nodes/8.D8JqGvkd.js.gz +0 -0
  396. package/build/client/_app/immutable/nodes/9.CHSFcAbh.js.br +0 -0
  397. package/build/client/_app/immutable/nodes/9.CHSFcAbh.js.gz +0 -0
  398. package/build/server/chunks/chunks/terminal.js-BUurgI6D.js +0 -81
@@ -1,4 +1,4 @@
1
- import"../chunks/DsnmJJEf.js";import{o as Lo}from"../chunks/RYq3318d.js";import{m as $,q as aa,g as e,v as h,l as Vt,p as Nt,f as ve,h as d,o as M,s as a,r as o,t as m,d as b,a as s,b as Lt,i as v,y as te,x as Ut,aF as Oo,c as i,n as Ke,br as mn,bF as nn,w as ra,u as At,G as vr,aa as jt,j as Wt,A as Po,z as Bo,aB as Ho,k as Wo,$ as Uo}from"../chunks/BuRWgnCz.js";import{i as f}from"../chunks/BDpRITyb.js";import{e as Ye,s as O,a as Me,r as La,b as Xr,c as Ar,i as jr,l as Yo,f as Ko,h as Go}from"../chunks/Cwb6d3g_.js";import{p as Da}from"../chunks/_8osrypQ.js";import{c as As,a as Jr,b as Xo,l as dr}from"../chunks/D8F9xgmh.js";import{c as Jo,d as sn,p as cr,e as ut,g as Fr,h as Vo}from"../chunks/BQPyzYAS.js";import{s as Hn,a as Wn}from"../chunks/BT_DAfvO.js";import{a as Un,j as Qo,p as Zo,h as $o}from"../chunks/Dse7bjta.js";import{F as pn,h as Sr,m as Is}from"../chunks/CFTDQcgN.js";import{c as Ya}from"../chunks/DLuhTA05.js";import{s as pr,c as on,e as ei,a as ti,b as ai,d as dn,w as ri,S as ni,P as si,f as oi,g as ii,U as va,h as Yn,B as Kn,p as Vr,i as Qr,t as di,j as li,k as ci,l as ui,m as Gn,n as Xn,o as Zr,q as vi,r as fi,u as Jn,v as Vn}from"../chunks/CF9qC7cA.js";import{b as ya}from"../chunks/BWRIDih-.js";import{s as Ot,r as Pt,p as vt}from"../chunks/BAOiF0in.js";import{S as hn}from"../chunks/BXN538J3.js";import{L as mi}from"../chunks/o67KsWSa.js";import{f as Ms,i as ln,j as pi,W as hi,N as gi,r as xi,u as _i,m as bi,g as Qn,e as ki}from"../chunks/C_4BzEag.js";import{f as gn,b as js,e as Zn,g as wi,i as yi,j as zi,w as Si,L as $n}from"../chunks/Bgm2YDEc.js";import{a as Ti,S as Fs,b as Ai,s as Ii}from"../chunks/CXsGgEzT.js";import{A as Mi,l as es,a as ji,m as Fi,B as qi,e as Ri,M as Ci}from"../chunks/DP7xDWnQ.js";import{i as Ua}from"../chunks/CspN1OJw.js";import{C as fr,c as ta,r as $r,R as ts}from"../chunks/ClSB0siN.js";import{a as Ir}from"../chunks/BCUUi0V0.js";import{H as Ei,T as Di}from"../chunks/XSztV5e-.js";import{L as cn}from"../chunks/DZbbLeZ5.js";import{C as mr}from"../chunks/CqfUJirh.js";import{L as na}from"../chunks/CP7u-DWX.js";import{C as qs}from"../chunks/D-5zBf83.js";import{I as Bt}from"../chunks/xH4qmLqM.js";import{I as Ni}from"../chunks/BIfGCSel.js";import{B as as,R as Li}from"../chunks/DJnRpOqR.js";import{S as Oi}from"../chunks/DyHO2Vc7.js";import{S as rs}from"../chunks/BksDoLoM.js";import{S as Za}from"../chunks/IPRCqR05.js";import{k as Pi,X as za}from"../chunks/rS7QE60d.js";import{a as $a}from"../chunks/BMFk7aZ6.js";import{d as Rs,C as Cs,M as Es,g as Bi,r as Hi,c as Wi,L as ns,f as Ui,a as Ds,P as Yi,p as Ki,u as Gi,h as Xi,i as Ji,j as Vi,S as Qi}from"../chunks/CGRtmaS4.js";import{C as Oa}from"../chunks/Dw18qh6I.js";import{C as Qa}from"../chunks/cmRB1an4.js";import{H as Ns}from"../chunks/CtgbxGhR.js";import{M as Zi,a as $i}from"../chunks/CoGHF2lE.js";import{R as ed}from"../chunks/DXoZBzFG.js";import{R as Ls}from"../chunks/nW7-TN7t.js";import{A as Os}from"../chunks/C0iYpbLa.js";import{E as Ps}from"../chunks/IuxiJfHx.js";import{P as td}from"../chunks/Cu50g1zS.js";import{C as ad}from"../chunks/B0XeFYOk.js";import{G as ss}from"../chunks/DkntkkRH.js";import{G as Bs}from"../chunks/C8be1l5w.js";import{i as rd}from"../chunks/CKBPLT-z.js";import{P as Hs}from"../chunks/DNc9cRsu.js";import{K as Mr,L as nd}from"../chunks/BxpN0jPH.js";import{p as sd}from"../chunks/fuBLR9dZ.js";import{P as od}from"../chunks/DVEiwmFn.js";import{B as en}from"../chunks/C5BN6RHR.js";import{T as id}from"../chunks/kynOtL7x.js";import{A as dd}from"../chunks/C8YpFJ43.js";import{a as ld,r as cd,g as ud}from"../chunks/CU0ZJcdF.js";var vd=new Set(["$$slots","$$events","$$legacy"]);function Ws(u,t){let l=Pt(t,vd);const c={name:"app-window",size:24,node:[["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2"}],["path",{d:"M10 4v4"}],["path",{d:"M2 8h20"}],["path",{d:"M6 4v4"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var fd=new Set(["$$slots","$$events","$$legacy"]);function md(u,t){let l=Pt(t,fd);const c={name:"arrow-left-right",size:24,node:[["path",{d:"M8 3 4 7l4 4"}],["path",{d:"M4 7h16"}],["path",{d:"m16 21 4-4-4-4"}],["path",{d:"M20 17H4"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var pd=new Set(["$$slots","$$events","$$legacy"]);function hd(u,t){let l=Pt(t,pd);const c={name:"brain",size:24,node:[["path",{d:"M12 18V5"}],["path",{d:"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4"}],["path",{d:"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5"}],["path",{d:"M17.997 5.125a4 4 0 0 1 2.526 5.77"}],["path",{d:"M18 18a4 4 0 0 0 2-7.464"}],["path",{d:"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517"}],["path",{d:"M6 18a4 4 0 0 1-2-7.464"}],["path",{d:"M6.003 5.125a4 4 0 0 0-2.526 5.77"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var gd=new Set(["$$slots","$$events","$$legacy"]);function tn(u,t){let l=Pt(t,gd);const c={name:"file-pen",size:24,node:[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z"}]],aliases:["file-edit"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var xd=new Set(["$$slots","$$events","$$legacy"]);function os(u,t){let l=Pt(t,xd);const c={name:"globe",size:24,node:[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"}],["path",{d:"M2 12h20"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var _d=new Set(["$$slots","$$events","$$legacy"]);function bd(u,t){let l=Pt(t,_d);const c={name:"hash",size:24,node:[["line",{x1:"4",x2:"20",y1:"9",y2:"9"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var kd=new Set(["$$slots","$$events","$$legacy"]);function wd(u,t){let l=Pt(t,kd);const c={name:"list-todo",size:24,node:[["path",{d:"M13 5h8"}],["path",{d:"M13 12h8"}],["path",{d:"M13 19h8"}],["path",{d:"m3 17 2 2 4-4"}],["rect",{x:"3",y:"4",width:"6",height:"6",rx:"1"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var yd=new Set(["$$slots","$$events","$$legacy"]);function zd(u,t){let l=Pt(t,yd);const c={name:"panel-left",size:24,node:[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M9 3v18"}]],aliases:["sidebar"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Sd=new Set(["$$slots","$$events","$$legacy"]);function Td(u,t){let l=Pt(t,Sd);const c={name:"panel-right",size:24,node:[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M15 3v18"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Ad=new Set(["$$slots","$$events","$$legacy"]);function is(u,t){let l=Pt(t,Ad);const c={name:"paperclip",size:24,node:[["path",{d:"m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Id=new Set(["$$slots","$$events","$$legacy"]);function Md(u,t){let l=Pt(t,Id);const c={name:"pen-line",size:24,node:[["path",{d:"M13 21h8"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z"}]],aliases:["edit-3"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var jd=new Set(["$$slots","$$events","$$legacy"]);function Us(u,t){let l=Pt(t,jd);const c={name:"reply",size:24,node:[["path",{d:"M20 18v-2a4 4 0 0 0-4-4H4"}],["path",{d:"m9 17-5-5 5-5"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Fd=new Set(["$$slots","$$events","$$legacy"]);function qd(u,t){let l=Pt(t,Fd);const c={name:"square-slash",size:24,node:[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["line",{x1:"9",x2:"15",y1:"15",y2:"9"}]],aliases:["slash-square"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Rd=new Set(["$$slots","$$events","$$legacy"]);function Cd(u,t){let l=Pt(t,Rd);const c={name:"thumbs-up",size:24,node:[["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z"}],["path",{d:"M7 10v12"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Ed=new Set(["$$slots","$$events","$$legacy"]);function Dd(u,t){let l=Pt(t,Ed);const c={name:"upload",size:24,node:[["path",{d:"M12 3v12"}],["path",{d:"m17 8-5-5-5 5"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Nd=new Set(["$$slots","$$events","$$legacy"]);function ds(u,t){let l=Pt(t,Nd);const c={name:"wrench",size:24,node:[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}function Ld(u){if(u.stepFailed.length||u.trouble.some(l=>l.status==="failed"))return{label:"Something failed",tone:"danger"};const t=u.needsYou.length;return t?{label:`${t} need${t===1?"s":""} you`,tone:"sea"}:u.trouble.length?{label:"Keeping an eye on a problem",tone:"warning"}:{label:"All well",tone:"success"}}function Od(){let u=null;return(t,l)=>{const c=t.searchParams.get("chat");if(!c)return u=null,null;if(t.href===u)return null;const p=l?.tasks.find(x=>x.id===c);return p?(u=t.href,{kind:"task",id:p.id,title:p.shortTitle,project:l?.projects.find(x=>x.id===p.projectId)?.name??null,url:null}):null}}function Pd(){let u=null;return(t,l)=>{const c=t.searchParams.get("draft");return c?t.href===u||t.searchParams.get("chat")&&!l?null:(u=t.href,c):(u=null,null)}}function Bd(u){return u.type==="popstate"?null:u.to?.url.searchParams.get("decision")??null}const Hd="x-wheelhouse-filename",Wd="x-wheelhouse-filetype",qr=25*1024*1024;function xn(u){return u<1024?`${u} B`:u<1024*1024?`${Math.round(u/1024)} KB`:`${(u/(1024*1024)).toFixed(1)} MB`}function Ud(u){return`[attached file ${u.path} — ${u.name}, ${xn(u.size)}, ${u.type||"unknown type"}]`}const Yd=/^\[attached file (\/[^\n]*?\/([^/\n]+)) — \2, ([\d.]+) (B|KB|MB), ([^\]\n,]+)\][ \t]*$/gm,Kd={B:1,KB:1024,MB:1024*1024};function an(u){const t=[],l=u.replace(Yd,(c,p,x,k,g,S)=>(t.push({path:p,name:x,size:Math.round(Number(k)*Kd[g]),type:S==="unknown type"?"":S}),""));return t.length?{text:l.trim(),files:t}:{text:u,files:t}}const un=u=>/^image\/(png|jpeg|gif|webp|avif)$/.test(u);function Ys(u){if(u.type==="application/pdf")return"PDF";if(u.type.startsWith("image/"))return"Image";const t=/\.([A-Za-z0-9]{1,6})$/.exec(u.name)?.[1];return t?t.toUpperCase():u.type.startsWith("text/")?"Text":"File"}function Gd(u){if(!un(u.type))return null;const t=/\/uploads\/(\d{4}-\d{2}-\d{2})\/([a-f0-9]{12})\/([^/]+)$/.exec(u.path);return t?`/api/firstmate/uploads/${t[1]}/${t[2]}/${encodeURIComponent(t[3])}`:null}function Xd(u,t=new Date){const l=/^image\/(png|jpeg|gif|webp|avif)$/.exec(u)?.[1]?.replace("jpeg","jpg")??"png";return`Pasted image ${t.toISOString().slice(0,19).replace("T"," ").replace(/:/g,".")}.${l}`}const ls=`Too large · ${qr/(1024*1024)} MB at most`;class Jd{#e=$(aa([]));get drafts(){return e(this.#e)}set drafts(t){h(this.#e,t,!0)}#t=$([]);get dropped(){return e(this.#t)}set dropped(t){h(this.#t,t)}inflight=new Map;add(t,l,c=!1){for(const p of t){const k=c&&un(p.type)&&/^image\.\w+$/.test(p.name)||!p.name?Xd(p.type):p.name;this.drafts.push({id:crypto.randomUUID(),name:k,size:p.size,type:p.type,preview:un(p.type)?URL.createObjectURL(p):null,state:"uploading",progress:0,error:null,upload:null});const g=this.drafts[this.drafts.length-1];p.size>qr?this.fail(g,ls):p.size===0?this.fail(g,"Empty file"):this.send(g,p,l)}}remove(t){this.inflight.get(t)?.abort(),this.inflight.delete(t);const l=this.drafts.find(c=>c.id===t);l?.preview&&URL.revokeObjectURL(l.preview),this.drafts=this.drafts.filter(c=>c.id!==t)}take(){const t=this.drafts.filter(l=>l.state==="ready"&&l.upload);for(const l of t)l.preview&&URL.revokeObjectURL(l.preview);return this.drafts=this.drafts.filter(l=>!t.includes(l)),t.map(l=>l.upload)}get uploading(){return this.drafts.some(t=>t.state==="uploading")}get ready(){return this.drafts.some(t=>t.state==="ready")}fail(t,l){t.state="failed",t.error=l}send(t,l,c){const p=new XMLHttpRequest;this.inflight.set(t.id,p),p.open("POST","/api/firstmate/uploads"),p.setRequestHeader(hn,c),p.setRequestHeader(Hd,encodeURIComponent(t.name)),p.setRequestHeader(Wd,l.type),p.setRequestHeader("content-type","application/octet-stream"),p.upload.onprogress=x=>{x.lengthComputable&&(t.progress=x.loaded/x.total)},p.onload=()=>{this.inflight.delete(t.id);let x={};try{x=JSON.parse(p.responseText)}catch{}p.status===201&&typeof x.path=="string"?(t.upload={path:x.path,name:x.name??t.name,size:x.size??t.size,type:x.type??""},t.progress=1,t.state="ready"):p.status===413?this.fail(t,ls):this.fail(t,x.message??`Not uploaded · Wheelhouse answered ${p.status}`)},p.onerror=()=>{this.inflight.delete(t.id),this.fail(t,"Could not reach the Wheelhouse server")},p.send(l)}}const Tt=new Jd;var Vd=i('<button type="button" class="shrink-0 cursor-zoom-in rounded"><img alt="" loading="lazy" class="size-10 rounded border border-hair bg-muted object-cover"/></button>'),Qd=i('<span class="flex size-10 shrink-0 items-center justify-center rounded bg-sea/10 text-sea" aria-hidden="true"><!></span>'),Zd=i('<li class="flex items-center gap-2.5 py-1.5 text-sm"><!> <span class="min-w-0 truncate font-medium"> </span> <span class="ml-auto shrink-0 pl-2 text-xs text-muted-foreground"> </span></li>'),$d=i('<div data-sent-files=""><p class="mb-0.5 text-[0.8rem] font-semibold tracking-[0.08em] text-muted-foreground" style="font-variant-caps: all-small-caps"> </p> <ul class="flex flex-col divide-y divide-hair"></ul></div> <!>',1);function cs(u,t){Nt(t,!0);let l=vt(t,"pending",3,!1),c=aa({});const p=B=>c[B.path]?null:Gd(B),x=v(()=>t.files.filter(B=>p(B)));let k=$(null);var g=$d(),S=ve(g),U=d(S),D=M(U,!0),V=a(U,2);Ye(V,21,()=>t.files,B=>B.path,(B,j)=>{const K=v(()=>p(e(j)));var ce=Zd(),P=d(ce);{var ie=ae=>{var E=Vd(),de=M(E);m(()=>{O(E,"aria-label",`Enlarge ${e(j).name??""}`),O(de,"src",e(K))}),te("click",E,()=>h(k,e(x).indexOf(e(j)),!0)),Ut("error",de,()=>c[e(j).path]=!0),Oo(de),s(ae,E)},X=ae=>{var E=Qd(),de=d(E);pn(de,{class:"size-4"}),o(E),s(ae,E)};f(P,ae=>{e(K)?ae(ie):ae(X,-1)})}var w=a(P,2),z=M(w,!0),F=a(w,2),C=M(F);o(ce),m((ae,E)=>{O(w,"title",e(j).name),b(z,e(j).name),b(C,`${ae??""} · ${E??""}`)},[()=>Ys(e(j)),()=>xn(e(j).size)]),s(B,ce)}),o(V),o(S);var Q=a(S,2);{var q=B=>{{let j=v(()=>e(x).map(K=>({name:K.name,url:p(K)??""})));mi(B,{get shots(){return e(j)},get index(){return e(k)},set index(K){h(k,K,!0)}})}};f(Q,B=>{e(x).length&&B(q)})}m(()=>{Me(S,1,`mt-1.5 w-full max-w-[min(85%,62ch)] min-w-0 rounded-lg border border-hair bg-card px-3 py-2 sm:min-w-72 ${l()?"border-dashed opacity-60":""}`),b(D,t.files.length===1?"1 file attached":`${t.files.length} files attached`)}),s(u,g),Lt()}Vt(["click"]);const el=u=>({cardId:u.id,taskId:u.taskId,taskTitle:u.taskTitle,projectId:u.projectId,kind:u.kind,key:u.key,question:u.choices?.intro||u.question,askedAt:u.askedAt,secondMate:u.secondMate??null});function tl(u,t,l,c=new Set){const p=[],x=new Set;for(const g of u){const S=el(g),U=l[g.id]?.question===g.question?l[g.id]:null,D=g.sent&&g.sent.delivery!=="failed"?g.sent:null;!Ms(g)&&!c.has(g.id)&&!U&&!D||(U&&!(U.posted&&D)?p.push({id:g.id,head:S,card:g,answer:{choice:U.choice,label:ln(g,U.choice),picks:U.picks,note:U.note,at:null,delivery:U.posted?null:"sending"}}):D?(x.add(D.requestId),p.push({id:g.id,head:S,card:g,answer:{choice:D.choice,label:ln(g,D.choice),picks:D.picks,note:D.note,at:D.at,delivery:D.delivery}})):p.push({id:g.id,head:S,card:g,answer:null}))}const k=new Map(p.map(g=>[g.id,g]));for(const g of t)x.has(g.requestId)||g.delivery==="failed"||k.get(g.cardId)?.head.question!==g.question&&p.push({id:`answer:${g.requestId}`,head:{cardId:g.cardId,taskId:g.taskId,taskTitle:g.taskTitle,projectId:g.projectId,kind:g.kind,key:g.key,question:g.question,askedAt:g.askedAt},card:null,answer:{choice:g.choice,label:g.label,picks:g.picks,note:g.note,at:g.answeredAt,delivery:g.delivery}});return p}const vn=u=>{const t=u?Date.parse(u):NaN;return Number.isNaN(t)?null:t},al=u=>vn(u.head.askedAt)??vn(u.answer?.at);function rl(u,t){const l=new Map,c=[],p=u.map(g=>vn(g.at)),x=p.find(g=>g!==null)??null,k=t.map(g=>({d:g,at:al(g)})).sort((g,S)=>(g.at??1/0)-(S.at??1/0)||g.d.id.localeCompare(S.d.id));for(const{d:g,at:S}of k){if(S===null){c.push(g);continue}if(g.answer&&!g.card&&(x===null||S<x))continue;const U=p.findIndex(D=>D!==null&&D>S);U<0?c.push(g):l.set(U,[...l.get(U)??[],g])}return{before:l,end:c}}const us=/^[^\s()]+$/,nl=/^> About the decision on ([^\s()]+) \(key ([^\s()]+)\), not an answer yet: “(.*)”\n(?:> [^\n]*\n)*\n([\s\S]+)$/,sl='> Wheelhouse: if your reply changes what the captain should choose from, end it with a ```decision-form block: the question on its first line, then one "- option" line each ("- label: what it means", "(recommended)" on the one you recommend), or "- (written)" for a written answer. Wheelhouse shows it as the form the captain answers with.',ol=u=>`${u.taskId}:${u.key}`,Ks=u=>us.test(u.taskId)&&us.test(u.key);function il(u,t){const l=t.trim();return!l||!Ks(u)?"":`> About the decision on ${u.taskId} (key ${u.key}), not an answer yet: “${pr(u.question)}”
1
+ import"../chunks/DsnmJJEf.js";import{o as Lo}from"../chunks/RYq3318d.js";import{m as $,q as aa,g as e,v as h,l as Vt,p as Nt,f as ve,h as d,o as M,s as a,r as o,t as m,d as b,a as s,b as Lt,i as v,y as te,x as Ut,aF as Oo,c as i,n as Ke,br as mn,bF as nn,w as ra,u as At,G as vr,aa as jt,j as Wt,A as Po,z as Bo,aB as Ho,k as Wo,$ as Uo}from"../chunks/BuRWgnCz.js";import{i as f}from"../chunks/BDpRITyb.js";import{e as Ye,s as O,a as Me,r as La,b as Xr,c as Ar,i as jr,l as Yo,f as Ko,h as Go}from"../chunks/Cwb6d3g_.js";import{p as Da}from"../chunks/BSBcdyd3.js";import{c as As,a as Jr,b as Xo,l as dr}from"../chunks/DglJ92hi.js";import{c as Jo,d as sn,p as cr,e as ut,g as Fr,h as Vo}from"../chunks/rwLE2q5W.js";import{s as Hn,a as Wn}from"../chunks/BT_DAfvO.js";import{a as Un,j as Qo,p as Zo,h as $o}from"../chunks/Dse7bjta.js";import{F as pn,h as Sr,m as Is}from"../chunks/CFTDQcgN.js";import{c as Ya}from"../chunks/DLuhTA05.js";import{s as pr,c as on,e as ei,a as ti,b as ai,d as dn,w as ri,S as ni,P as si,f as oi,g as ii,U as va,h as Yn,B as Kn,p as Vr,i as Qr,t as di,j as li,k as ci,l as ui,m as Gn,n as Xn,o as Zr,q as vi,r as fi,u as Jn,v as Vn}from"../chunks/CoQMrCtk.js";import{b as ya}from"../chunks/BWRIDih-.js";import{s as Ot,r as Pt,p as vt}from"../chunks/BAOiF0in.js";import{S as hn}from"../chunks/BXN538J3.js";import{L as mi}from"../chunks/o67KsWSa.js";import{f as Ms,i as ln,j as pi,W as hi,N as gi,r as xi,u as _i,m as bi,g as Qn,e as ki}from"../chunks/C_4BzEag.js";import{f as gn,b as js,e as Zn,g as wi,i as yi,j as zi,w as Si,L as $n}from"../chunks/Dcf7qESD.js";import{a as Ti,S as Fs,b as Ai,s as Ii}from"../chunks/I4bsCfS2.js";import{A as Mi,l as es,a as ji,m as Fi,B as qi,e as Ri,M as Ci}from"../chunks/C_QL6rvF.js";import{i as Ua}from"../chunks/CspN1OJw.js";import{C as fr,c as ta,r as $r,R as ts}from"../chunks/JUzTNcjv.js";import{a as Ir}from"../chunks/BCUUi0V0.js";import{H as Ei,T as Di}from"../chunks/D9kzO4Vy.js";import{L as cn}from"../chunks/DZbbLeZ5.js";import{C as mr}from"../chunks/CqfUJirh.js";import{L as na}from"../chunks/CP7u-DWX.js";import{C as qs}from"../chunks/D-5zBf83.js";import{I as Bt}from"../chunks/xH4qmLqM.js";import{I as Ni}from"../chunks/BIfGCSel.js";import{B as as,R as Li}from"../chunks/DJnRpOqR.js";import{S as Oi}from"../chunks/DyHO2Vc7.js";import{S as rs}from"../chunks/BksDoLoM.js";import{S as Za}from"../chunks/IPRCqR05.js";import{k as Pi,X as za}from"../chunks/rS7QE60d.js";import{a as $a}from"../chunks/BMFk7aZ6.js";import{d as Rs,C as Cs,M as Es,g as Bi,r as Hi,c as Wi,L as ns,f as Ui,a as Ds,P as Yi,p as Ki,u as Gi,h as Xi,i as Ji,j as Vi,S as Qi}from"../chunks/luPa70aT.js";import{C as Oa}from"../chunks/Dw18qh6I.js";import{C as Qa}from"../chunks/cmRB1an4.js";import{H as Ns}from"../chunks/CtgbxGhR.js";import{M as Zi,a as $i}from"../chunks/CoGHF2lE.js";import{R as ed}from"../chunks/DXoZBzFG.js";import{R as Ls}from"../chunks/nW7-TN7t.js";import{A as Os}from"../chunks/C0iYpbLa.js";import{E as Ps}from"../chunks/IuxiJfHx.js";import{P as td}from"../chunks/Cu50g1zS.js";import{C as ad}from"../chunks/B0XeFYOk.js";import{G as ss}from"../chunks/Bj-Gheej.js";import{G as Bs}from"../chunks/C8be1l5w.js";import{i as rd}from"../chunks/CKBPLT-z.js";import{P as Hs}from"../chunks/DNc9cRsu.js";import{K as Mr,L as nd}from"../chunks/BxpN0jPH.js";import{p as sd}from"../chunks/fuBLR9dZ.js";import{P as od}from"../chunks/DVEiwmFn.js";import{B as en}from"../chunks/C5BN6RHR.js";import{T as id}from"../chunks/kynOtL7x.js";import{A as dd}from"../chunks/C8YpFJ43.js";import{a as ld,r as cd,g as ud}from"../chunks/cM1ZMvyM.js";var vd=new Set(["$$slots","$$events","$$legacy"]);function Ws(u,t){let l=Pt(t,vd);const c={name:"app-window",size:24,node:[["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2"}],["path",{d:"M10 4v4"}],["path",{d:"M2 8h20"}],["path",{d:"M6 4v4"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var fd=new Set(["$$slots","$$events","$$legacy"]);function md(u,t){let l=Pt(t,fd);const c={name:"arrow-left-right",size:24,node:[["path",{d:"M8 3 4 7l4 4"}],["path",{d:"M4 7h16"}],["path",{d:"m16 21 4-4-4-4"}],["path",{d:"M20 17H4"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var pd=new Set(["$$slots","$$events","$$legacy"]);function hd(u,t){let l=Pt(t,pd);const c={name:"brain",size:24,node:[["path",{d:"M12 18V5"}],["path",{d:"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4"}],["path",{d:"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5"}],["path",{d:"M17.997 5.125a4 4 0 0 1 2.526 5.77"}],["path",{d:"M18 18a4 4 0 0 0 2-7.464"}],["path",{d:"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517"}],["path",{d:"M6 18a4 4 0 0 1-2-7.464"}],["path",{d:"M6.003 5.125a4 4 0 0 0-2.526 5.77"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var gd=new Set(["$$slots","$$events","$$legacy"]);function tn(u,t){let l=Pt(t,gd);const c={name:"file-pen",size:24,node:[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z"}]],aliases:["file-edit"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var xd=new Set(["$$slots","$$events","$$legacy"]);function os(u,t){let l=Pt(t,xd);const c={name:"globe",size:24,node:[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"}],["path",{d:"M2 12h20"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var _d=new Set(["$$slots","$$events","$$legacy"]);function bd(u,t){let l=Pt(t,_d);const c={name:"hash",size:24,node:[["line",{x1:"4",x2:"20",y1:"9",y2:"9"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var kd=new Set(["$$slots","$$events","$$legacy"]);function wd(u,t){let l=Pt(t,kd);const c={name:"list-todo",size:24,node:[["path",{d:"M13 5h8"}],["path",{d:"M13 12h8"}],["path",{d:"M13 19h8"}],["path",{d:"m3 17 2 2 4-4"}],["rect",{x:"3",y:"4",width:"6",height:"6",rx:"1"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var yd=new Set(["$$slots","$$events","$$legacy"]);function zd(u,t){let l=Pt(t,yd);const c={name:"panel-left",size:24,node:[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M9 3v18"}]],aliases:["sidebar"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Sd=new Set(["$$slots","$$events","$$legacy"]);function Td(u,t){let l=Pt(t,Sd);const c={name:"panel-right",size:24,node:[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M15 3v18"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Ad=new Set(["$$slots","$$events","$$legacy"]);function is(u,t){let l=Pt(t,Ad);const c={name:"paperclip",size:24,node:[["path",{d:"m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Id=new Set(["$$slots","$$events","$$legacy"]);function Md(u,t){let l=Pt(t,Id);const c={name:"pen-line",size:24,node:[["path",{d:"M13 21h8"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z"}]],aliases:["edit-3"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var jd=new Set(["$$slots","$$events","$$legacy"]);function Us(u,t){let l=Pt(t,jd);const c={name:"reply",size:24,node:[["path",{d:"M20 18v-2a4 4 0 0 0-4-4H4"}],["path",{d:"m9 17-5-5 5-5"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Fd=new Set(["$$slots","$$events","$$legacy"]);function qd(u,t){let l=Pt(t,Fd);const c={name:"square-slash",size:24,node:[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["line",{x1:"9",x2:"15",y1:"15",y2:"9"}]],aliases:["slash-square"]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Rd=new Set(["$$slots","$$events","$$legacy"]);function Cd(u,t){let l=Pt(t,Rd);const c={name:"thumbs-up",size:24,node:[["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z"}],["path",{d:"M7 10v12"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Ed=new Set(["$$slots","$$events","$$legacy"]);function Dd(u,t){let l=Pt(t,Ed);const c={name:"upload",size:24,node:[["path",{d:"M12 3v12"}],["path",{d:"m17 8-5-5-5 5"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}var Nd=new Set(["$$slots","$$events","$$legacy"]);function ds(u,t){let l=Pt(t,Nd);const c={name:"wrench",size:24,node:[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z"}]]};Bt(u,Ot(()=>l,{get icon(){return c}}))}function Ld(u){if(u.stepFailed.length||u.trouble.some(l=>l.status==="failed"))return{label:"Something failed",tone:"danger"};const t=u.needsYou.length;return t?{label:`${t} need${t===1?"s":""} you`,tone:"sea"}:u.trouble.length?{label:"Keeping an eye on a problem",tone:"warning"}:{label:"All well",tone:"success"}}function Od(){let u=null;return(t,l)=>{const c=t.searchParams.get("chat");if(!c)return u=null,null;if(t.href===u)return null;const p=l?.tasks.find(x=>x.id===c);return p?(u=t.href,{kind:"task",id:p.id,title:p.shortTitle,project:l?.projects.find(x=>x.id===p.projectId)?.name??null,url:null}):null}}function Pd(){let u=null;return(t,l)=>{const c=t.searchParams.get("draft");return c?t.href===u||t.searchParams.get("chat")&&!l?null:(u=t.href,c):(u=null,null)}}function Bd(u){return u.type==="popstate"?null:u.to?.url.searchParams.get("decision")??null}const Hd="x-wheelhouse-filename",Wd="x-wheelhouse-filetype",qr=25*1024*1024;function xn(u){return u<1024?`${u} B`:u<1024*1024?`${Math.round(u/1024)} KB`:`${(u/(1024*1024)).toFixed(1)} MB`}function Ud(u){return`[attached file ${u.path} — ${u.name}, ${xn(u.size)}, ${u.type||"unknown type"}]`}const Yd=/^\[attached file (\/[^\n]*?\/([^/\n]+)) — \2, ([\d.]+) (B|KB|MB), ([^\]\n,]+)\][ \t]*$/gm,Kd={B:1,KB:1024,MB:1024*1024};function an(u){const t=[],l=u.replace(Yd,(c,p,x,k,g,S)=>(t.push({path:p,name:x,size:Math.round(Number(k)*Kd[g]),type:S==="unknown type"?"":S}),""));return t.length?{text:l.trim(),files:t}:{text:u,files:t}}const un=u=>/^image\/(png|jpeg|gif|webp|avif)$/.test(u);function Ys(u){if(u.type==="application/pdf")return"PDF";if(u.type.startsWith("image/"))return"Image";const t=/\.([A-Za-z0-9]{1,6})$/.exec(u.name)?.[1];return t?t.toUpperCase():u.type.startsWith("text/")?"Text":"File"}function Gd(u){if(!un(u.type))return null;const t=/\/uploads\/(\d{4}-\d{2}-\d{2})\/([a-f0-9]{12})\/([^/]+)$/.exec(u.path);return t?`/api/firstmate/uploads/${t[1]}/${t[2]}/${encodeURIComponent(t[3])}`:null}function Xd(u,t=new Date){const l=/^image\/(png|jpeg|gif|webp|avif)$/.exec(u)?.[1]?.replace("jpeg","jpg")??"png";return`Pasted image ${t.toISOString().slice(0,19).replace("T"," ").replace(/:/g,".")}.${l}`}const ls=`Too large · ${qr/(1024*1024)} MB at most`;class Jd{#e=$(aa([]));get drafts(){return e(this.#e)}set drafts(t){h(this.#e,t,!0)}#t=$([]);get dropped(){return e(this.#t)}set dropped(t){h(this.#t,t)}inflight=new Map;add(t,l,c=!1){for(const p of t){const k=c&&un(p.type)&&/^image\.\w+$/.test(p.name)||!p.name?Xd(p.type):p.name;this.drafts.push({id:crypto.randomUUID(),name:k,size:p.size,type:p.type,preview:un(p.type)?URL.createObjectURL(p):null,state:"uploading",progress:0,error:null,upload:null});const g=this.drafts[this.drafts.length-1];p.size>qr?this.fail(g,ls):p.size===0?this.fail(g,"Empty file"):this.send(g,p,l)}}remove(t){this.inflight.get(t)?.abort(),this.inflight.delete(t);const l=this.drafts.find(c=>c.id===t);l?.preview&&URL.revokeObjectURL(l.preview),this.drafts=this.drafts.filter(c=>c.id!==t)}take(){const t=this.drafts.filter(l=>l.state==="ready"&&l.upload);for(const l of t)l.preview&&URL.revokeObjectURL(l.preview);return this.drafts=this.drafts.filter(l=>!t.includes(l)),t.map(l=>l.upload)}get uploading(){return this.drafts.some(t=>t.state==="uploading")}get ready(){return this.drafts.some(t=>t.state==="ready")}fail(t,l){t.state="failed",t.error=l}send(t,l,c){const p=new XMLHttpRequest;this.inflight.set(t.id,p),p.open("POST","/api/firstmate/uploads"),p.setRequestHeader(hn,c),p.setRequestHeader(Hd,encodeURIComponent(t.name)),p.setRequestHeader(Wd,l.type),p.setRequestHeader("content-type","application/octet-stream"),p.upload.onprogress=x=>{x.lengthComputable&&(t.progress=x.loaded/x.total)},p.onload=()=>{this.inflight.delete(t.id);let x={};try{x=JSON.parse(p.responseText)}catch{}p.status===201&&typeof x.path=="string"?(t.upload={path:x.path,name:x.name??t.name,size:x.size??t.size,type:x.type??""},t.progress=1,t.state="ready"):p.status===413?this.fail(t,ls):this.fail(t,x.message??`Not uploaded · Wheelhouse answered ${p.status}`)},p.onerror=()=>{this.inflight.delete(t.id),this.fail(t,"Could not reach the Wheelhouse server")},p.send(l)}}const Tt=new Jd;var Vd=i('<button type="button" class="shrink-0 cursor-zoom-in rounded"><img alt="" loading="lazy" class="size-10 rounded border border-hair bg-muted object-cover"/></button>'),Qd=i('<span class="flex size-10 shrink-0 items-center justify-center rounded bg-sea/10 text-sea" aria-hidden="true"><!></span>'),Zd=i('<li class="flex items-center gap-2.5 py-1.5 text-sm"><!> <span class="min-w-0 truncate font-medium"> </span> <span class="ml-auto shrink-0 pl-2 text-xs text-muted-foreground"> </span></li>'),$d=i('<div data-sent-files=""><p class="mb-0.5 text-[0.8rem] font-semibold tracking-[0.08em] text-muted-foreground" style="font-variant-caps: all-small-caps"> </p> <ul class="flex flex-col divide-y divide-hair"></ul></div> <!>',1);function cs(u,t){Nt(t,!0);let l=vt(t,"pending",3,!1),c=aa({});const p=B=>c[B.path]?null:Gd(B),x=v(()=>t.files.filter(B=>p(B)));let k=$(null);var g=$d(),S=ve(g),U=d(S),D=M(U,!0),V=a(U,2);Ye(V,21,()=>t.files,B=>B.path,(B,j)=>{const K=v(()=>p(e(j)));var ce=Zd(),P=d(ce);{var ie=ae=>{var E=Vd(),de=M(E);m(()=>{O(E,"aria-label",`Enlarge ${e(j).name??""}`),O(de,"src",e(K))}),te("click",E,()=>h(k,e(x).indexOf(e(j)),!0)),Ut("error",de,()=>c[e(j).path]=!0),Oo(de),s(ae,E)},X=ae=>{var E=Qd(),de=d(E);pn(de,{class:"size-4"}),o(E),s(ae,E)};f(P,ae=>{e(K)?ae(ie):ae(X,-1)})}var w=a(P,2),z=M(w,!0),F=a(w,2),C=M(F);o(ce),m((ae,E)=>{O(w,"title",e(j).name),b(z,e(j).name),b(C,`${ae??""} · ${E??""}`)},[()=>Ys(e(j)),()=>xn(e(j).size)]),s(B,ce)}),o(V),o(S);var Q=a(S,2);{var q=B=>{{let j=v(()=>e(x).map(K=>({name:K.name,url:p(K)??""})));mi(B,{get shots(){return e(j)},get index(){return e(k)},set index(K){h(k,K,!0)}})}};f(Q,B=>{e(x).length&&B(q)})}m(()=>{Me(S,1,`mt-1.5 w-full max-w-[min(85%,62ch)] min-w-0 rounded-lg border border-hair bg-card px-3 py-2 sm:min-w-72 ${l()?"border-dashed opacity-60":""}`),b(D,t.files.length===1?"1 file attached":`${t.files.length} files attached`)}),s(u,g),Lt()}Vt(["click"]);const el=u=>({cardId:u.id,taskId:u.taskId,taskTitle:u.taskTitle,projectId:u.projectId,kind:u.kind,key:u.key,question:u.choices?.intro||u.question,askedAt:u.askedAt,secondMate:u.secondMate??null});function tl(u,t,l,c=new Set){const p=[],x=new Set;for(const g of u){const S=el(g),U=l[g.id]?.question===g.question?l[g.id]:null,D=g.sent&&g.sent.delivery!=="failed"?g.sent:null;!Ms(g)&&!c.has(g.id)&&!U&&!D||(U&&!(U.posted&&D)?p.push({id:g.id,head:S,card:g,answer:{choice:U.choice,label:ln(g,U.choice),picks:U.picks,note:U.note,at:null,delivery:U.posted?null:"sending"}}):D?(x.add(D.requestId),p.push({id:g.id,head:S,card:g,answer:{choice:D.choice,label:ln(g,D.choice),picks:D.picks,note:D.note,at:D.at,delivery:D.delivery}})):p.push({id:g.id,head:S,card:g,answer:null}))}const k=new Map(p.map(g=>[g.id,g]));for(const g of t)x.has(g.requestId)||g.delivery==="failed"||k.get(g.cardId)?.head.question!==g.question&&p.push({id:`answer:${g.requestId}`,head:{cardId:g.cardId,taskId:g.taskId,taskTitle:g.taskTitle,projectId:g.projectId,kind:g.kind,key:g.key,question:g.question,askedAt:g.askedAt},card:null,answer:{choice:g.choice,label:g.label,picks:g.picks,note:g.note,at:g.answeredAt,delivery:g.delivery}});return p}const vn=u=>{const t=u?Date.parse(u):NaN;return Number.isNaN(t)?null:t},al=u=>vn(u.head.askedAt)??vn(u.answer?.at);function rl(u,t){const l=new Map,c=[],p=u.map(g=>vn(g.at)),x=p.find(g=>g!==null)??null,k=t.map(g=>({d:g,at:al(g)})).sort((g,S)=>(g.at??1/0)-(S.at??1/0)||g.d.id.localeCompare(S.d.id));for(const{d:g,at:S}of k){if(S===null){c.push(g);continue}if(g.answer&&!g.card&&(x===null||S<x))continue;const U=p.findIndex(D=>D!==null&&D>S);U<0?c.push(g):l.set(U,[...l.get(U)??[],g])}return{before:l,end:c}}const us=/^[^\s()]+$/,nl=/^> About the decision on ([^\s()]+) \(key ([^\s()]+)\), not an answer yet: “(.*)”\n(?:> [^\n]*\n)*\n([\s\S]+)$/,sl='> Wheelhouse: if your reply changes what the captain should choose from, end it with a ```decision-form block: the question on its first line, then one "- option" line each ("- label: what it means", "(recommended)" on the one you recommend), or "- (written)" for a written answer. Wheelhouse shows it as the form the captain answers with.',ol=u=>`${u.taskId}:${u.key}`,Ks=u=>us.test(u.taskId)&&us.test(u.key);function il(u,t){const l=t.trim();return!l||!Ks(u)?"":`> About the decision on ${u.taskId} (key ${u.key}), not an answer yet: “${pr(u.question)}”
2
2
  ${sl}
3
3
 
4
4
  ${l}`}function ur(u){const t=u.replace(/\r\n?/g,`
@@ -1,4 +1,4 @@
1
- import"../chunks/DsnmJJEf.js";import{l as Ze,p as et,m as I,q as me,u as tt,a as v,b as at,k as rt,c as g,h as i,g as e,$ as st,s as n,r as l,i as b,v as $,o as u,t as m,d,f as ge,n as y,w as F,y as he}from"../chunks/BuRWgnCz.js";import{i as x}from"../chunks/BDpRITyb.js";import{h as nt,e as xe,r as fe,c as _e,s as W,a as be}from"../chunks/Cwb6d3g_.js";import{p as ot}from"../chunks/_8osrypQ.js";import{A as it}from"../chunks/ClsjySa8.js";import{S as lt}from"../chunks/BXN538J3.js";import{c as ye}from"../chunks/BCUUi0V0.js";import{B as j}from"../chunks/C5BN6RHR.js";import{S as dt}from"../chunks/DwBYQnih.js";var pt=g('<p class="mt-8 rounded-lg border border-dashed p-6 text-sm text-muted-foreground"> </p>'),ct=g('<span class="truncate text-muted-foreground"> </span>'),vt=g("<p> </p>"),ut=g(`<p>Set, in <code class="text-xs break-all"> </code>, readable by your
1
+ import"../chunks/DsnmJJEf.js";import{l as Ze,p as et,m as I,q as me,u as tt,a as v,b as at,k as rt,c as g,h as i,g as e,$ as st,s as n,r as l,i as b,v as $,o as u,t as m,d,f as ge,n as y,w as F,y as he}from"../chunks/BuRWgnCz.js";import{i as x}from"../chunks/BDpRITyb.js";import{h as nt,e as xe,r as fe,c as _e,s as W,a as be}from"../chunks/Cwb6d3g_.js";import{p as ot}from"../chunks/BSBcdyd3.js";import{A as it}from"../chunks/ClsjySa8.js";import{S as lt}from"../chunks/BXN538J3.js";import{c as ye}from"../chunks/BCUUi0V0.js";import{B as j}from"../chunks/C5BN6RHR.js";import{S as dt}from"../chunks/CzBY7r8x.js";var pt=g('<p class="mt-8 rounded-lg border border-dashed p-6 text-sm text-muted-foreground"> </p>'),ct=g('<span class="truncate text-muted-foreground"> </span>'),vt=g("<p> </p>"),ut=g(`<p>Set, in <code class="text-xs break-all"> </code>, readable by your
2
2
  user only. Replace it with <code class="text-xs"> </code>.</p>`),mt=g(`<p>Create the bot (see <a class="text-sea hover:underline" target="_blank" rel="noreferrer"> </a>), then run <code class="text-xs"> </code> in
3
3
  a terminal. It asks for the token there; it is never typed into this page.</p>`),gt=g('<p><span class="font-medium"> </span> <span class="text-muted-foreground"> </span></p> <p class="mt-0.5 text-xs text-muted-foreground">Only this account’s direct messages reach Firstmate.</p>',1),ht=g('<p class="text-muted-foreground">Not paired: no one’s messages reach Firstmate.</p>'),xt=g('<div class="mt-3 rounded-md border border-brass/60 bg-background px-4 py-3" aria-live="polite"><p class="text-xs text-muted-foreground">Send this code to the bot in a direct message</p> <p class="tabular mt-1 font-mono text-2xl font-semibold tracking-[0.2em]" data-testid="pairing-code"> </p> <p class="mt-1 text-xs text-muted-foreground"> </p></div>'),we=g('<p class="mt-2 text-xs text-muted-foreground"> </p>'),ft=g('<label class="flex items-start gap-2 text-sm"><input type="checkbox" class="mt-0.5 size-4 accent-[var(--sea)]"/> <span> <span class="block text-xs text-muted-foreground"> </span></span></label>'),_t=g('<p class="border-t px-4 py-3 text-sm text-danger" role="alert"> </p>'),bt=g(`<section class="mt-8 rounded-lg border bg-card"><header class="flex flex-wrap items-center justify-between gap-3 border-b px-4 py-3"><div class="min-w-0"><h2 class="font-display text-lg font-semibold"> </h2> <p class="flex items-center gap-2 text-sm"><span aria-hidden="true"></span> <span class="font-medium"> </span> <!></p></div> <!></header> <div class="divide-y"><!> <div class="grid gap-x-6 gap-y-1 px-4 py-3 sm:grid-cols-[minmax(0,12rem)_minmax(0,1fr)]"><p class="text-sm font-medium">Bot token</p> <div class="min-w-0 text-sm text-muted-foreground"><!></div></div> <div class="grid gap-x-6 gap-y-1 px-4 py-3 sm:grid-cols-[minmax(0,12rem)_minmax(0,1fr)]"><p class="text-sm font-medium">Paired account</p> <div class="min-w-0 text-sm"><!> <!> <!> <div class="mt-3 flex flex-wrap gap-2"><!> <!> <!></div></div></div> <fieldset class="grid gap-x-6 gap-y-1 px-4 py-3 sm:grid-cols-[minmax(0,12rem)_minmax(0,1fr)]"><legend class="sr-only"> </legend> <p class="text-sm font-medium" aria-hidden="true">Alerts sent</p> <div class="grid gap-x-4 gap-y-1.5 sm:grid-cols-2"><!> <label class="flex items-start gap-2 text-sm sm:col-span-2"><input type="checkbox" class="mt-0.5 size-4 accent-[var(--sea)]"/> <span>Titles only<span class="block text-xs text-muted-foreground">Alerts and decisions say only what happened and to which task, without their
4
4
  text, question or recommendation.</span></span></label></div></fieldset></div> <!></section>`),yt=g(`<!> <p class="mt-6 max-w-prose text-xs leading-relaxed text-muted-foreground">The gateway runs inside Wheelhouse, so it works only while Wheelhouse runs: for use away
@@ -1,4 +1,4 @@
1
- import"../chunks/DsnmJJEf.js";import{o as mt}from"../chunks/RYq3318d.js";import{p as Ve,m as H,q as nt,f as C,h as _,r as m,s as o,j as Te,n as se,w as ie,t as b,d as k,a as r,g as e,v as c,i as h,b as Xe,o as q,c as d,l as ot,y as Me,k as _t,$ as pt,aB as ht}from"../chunks/BuRWgnCz.js";import{i as W}from"../chunks/BDpRITyb.js";import{k as xt}from"../chunks/rS7QE60d.js";import{s as ee,a as Ge,f as He,r as Ye,e as ze,c as Ze,h as wt}from"../chunks/Cwb6d3g_.js";import{i as Ne}from"../chunks/CU0ZJcdF.js";import{p as Je}from"../chunks/_8osrypQ.js";import{S as bt}from"../chunks/DwBYQnih.js";import{I as kt}from"../chunks/D-2tF-22.js";import{D as Oe,I as yt}from"../chunks/iI4tqZHC.js";import{c as K}from"../chunks/DLuhTA05.js";import{p as Ke,s as Le}from"../chunks/BAOiF0in.js";import{D as Pt,a as Ct,b as Tt,c as Dt,d as $e,P as Wt,e as Rt,f as It,m as jt,i as zt}from"../chunks/CH2Y0BVE.js";import{B as _e}from"../chunks/C5BN6RHR.js";import{C as St,b as Ut,u as At,d as Bt,e as Et,p as Ft,f as Nt,c as Ot}from"../chunks/CxexnUzw.js";import{L as et}from"../chunks/CP7u-DWX.js";import{T as tt}from"../chunks/kynOtL7x.js";import{C as Lt}from"../chunks/cmRB1an4.js";import{C as $t}from"../chunks/CCL5M9Xl.js";import{S as qt}from"../chunks/BwPKBiav.js";import{R as Qe,E as Mt,e as Gt,w as Ht}from"../chunks/CMmxYmuw.js";import{l as at}from"../chunks/D8F9xgmh.js";import{a as Jt}from"../chunks/BCUUi0V0.js";import{R as Kt}from"../chunks/DXoZBzFG.js";import{C as Qt}from"../chunks/CqfUJirh.js";var Vt=d('<span class="flex items-center gap-1.5 text-muted-foreground"><!>Checking…</span>'),Xt=d('<span class="flex items-center gap-1.5 text-muted-foreground"><!>Up to date</span>'),Yt=d('<span class="text-muted-foreground" title="Installed at a commit, so it is not checked">Pinned to a commit</span>'),Zt=d('<span class="flex items-center gap-1.5 text-muted-foreground"><!>Could not check</span>'),ea=d("<!> ",1),ta=d('<span class="text-sea"> </span> <!>',1),qe=d("<!> <!>",1),aa=d('<p class="flex items-center gap-2 text-muted-foreground"><!> </p>'),ra=d('<p class="flex items-start gap-2 text-xs text-danger" role="alert"><!> </p> <!>',1),sa=d('<p class="text-xs text-danger" role="alert"> </p>'),rt=d("<!> <!> <!>",1),na=d("<p> </p>"),oa=d('<div class="flex flex-wrap items-center justify-end gap-2 text-xs sm:min-w-48"><!></div> <!>',1);function la(pe,a){Ve(a,!0);let ne=Ke(a,"checking",3,!1),de=Ke(a,"busy",19,()=>[]),U=H(!1),f=H("looking"),I=H(null),x=H(null),Q=H(nt({}));const w=h(()=>e(x)?jt(e(x),e(Q)):null),N=()=>Je.data.sessionToken;async function O(){c(U,!0),c(f,"looking"),c(I,null),c(x,null);const g=a.update.state==="newer-tag"?a.update.latest?.ref??null:null,u=await Bt({id:a.update.id,ref:g},N());if(!u.ok){c(I,u.error,!0),c(f,"failed");return}c(x,u.value,!0),c(Q,zt(u.value),!0),c(f,"review")}async function ce(){if(!e(x)||e(w))return;c(f,"saving"),c(I,null);const g=Ut(),u=await At(e(x),It(e(Q)),N());if(!u.ok){c(I,u.error,!0),c(f,"review");return}c(f,"restarting"),c(f,await g?"done":"slow",!0)}var ue=oa(),V=C(ue),he=_(V);{var xe=g=>{var u=Vt(),T=_(u);et(T,{class:"size-3.5 animate-spin"}),se(),m(u),r(g,u)},A=g=>{var u=Xt(),T=_(u);Lt(T,{class:"size-3.5 text-success"}),se(),m(u),r(g,u)},B=g=>{var u=Yt();r(g,u)},M=g=>{var u=Zt(),T=_(u);tt(T,{class:"size-3.5 text-warning"}),se(),m(u),b(()=>ee(u,"title",a.update.reason??void 0)),r(g,u)},J=g=>{var u=ta(),T=C(u),te=q(T,!0),ae=o(T,2);_e(ae,{variant:"outline",size:"xs",onclick:O,children:(we,be)=>{var fe=ea(),ve=C(fe);$t(ve,{});var ke=o(ve,1,!0);b(()=>k(ke,a.update.state==="newer-tag"?`Move to ${a.update.latest?.ref}`:"Update")),r(we,fe)},$$slots:{default:!0}}),b(()=>k(te,a.update.state==="newer-tag"?`${a.update.latest?.ref} is out`:`New commits${a.update.ref?` on ${a.update.ref}`:""}`)),r(g,u)};W(he,g=>{ne()?g(xe):a.update.state==="current"?g(A,1):a.update.state==="pinned"?g(B,2):a.update.state==="error"?g(M,3):g(J,-1)})}m(V);var oe=o(V,2);K(oe,()=>Rt,(g,u)=>{u(g,{get open(){return e(U)},set open(T){c(U,T,!0)},children:(T,te)=>{var ae=Te(),we=C(ae);{let be=h(()=>e(f)==="saving"||e(f)==="restarting"?"ignore":"close");K(we,()=>Pt,(fe,ve)=>{ve(fe,{class:"max-h-[calc(100dvh-2rem)] overflow-y-auto sm:max-w-lg",get interactOutsideBehavior(){return e(be)},children:(ke,Se)=>{var De=qe(),ye=C(De);K(ye,()=>Ct,(j,z)=>{z(j,{children:(t,n)=>{var i=qe(),s=C(i);K(s,()=>Tt,(v,P)=>{P(v,{class:"font-display text-lg",children:(G,E)=>{se();var F=ie();b(()=>k(F,`Update ${a.name??""}`)),r(G,F)},$$slots:{default:!0}})});var l=o(s,2);K(l,()=>Dt,(v,P)=>{P(v,{class:"tabular",children:(G,E)=>{var F=Te(),X=C(F);{var S=D=>{var L=ie();b(()=>k(L,`${a.update.version??""} → ${e(x).version??""}${a.update.state==="newer-tag"&&a.update.ref?`, from ${a.update.ref} to ${e(x).ref}`:""}`)),r(D,L)},R=D=>{var L=ie();b(()=>k(L,a.update.repository)),r(D,L)};W(X,D=>{e(x)?D(S):D(R,-1)})}r(G,F)},$$slots:{default:!0}})}),r(t,i)},$$slots:{default:!0}})});var Ue=o(ye,2);{var We=j=>{var z=aa(),t=_(z);et(t,{class:"size-4 animate-spin"});var n=o(t);m(z),b(()=>k(n,`Fetching ${a.update.repository??""}…`)),r(j,z)},Re=j=>{var z=ra(),t=C(z),n=_(t);tt(n,{class:"mt-0.5 size-3.5 shrink-0"});var i=o(n,1,!0);m(t);var s=o(t,2);K(s,()=>$e,(l,v)=>{v(l,{children:(P,G)=>{var E=Te(),F=C(E);{const X=(S,R)=>{_e(S,Le(()=>(R?.()).props,{variant:"ghost",children:(L,le)=>{se();var Pe=ie("Close");r(L,Pe)},$$slots:{default:!0}}))};K(F,()=>Oe,(S,R)=>{R(S,{child:X,$$slots:{child:!0}})})}r(P,E)},$$slots:{default:!0}})}),b(()=>k(i,e(I))),r(j,z)},Ae=j=>{var z=rt(),t=C(z);Wt(t,{get preview(){return e(x)},get busy(){return de()},get answers(){return e(Q)},set answers(l){c(Q,l,!0)}});var n=o(t,2);{var i=l=>{var v=sa(),P=q(v,!0);b(()=>k(P,e(I))),r(l,v)};W(n,l=>{e(I)&&l(i)})}var s=o(n,2);K(s,()=>$e,(l,v)=>{v(l,{children:(P,G)=>{var E=qe(),F=C(E);{const S=(R,D)=>{_e(R,Le(()=>(D?.()).props,{variant:"ghost",children:(le,Pe)=>{se();var Ce=ie("Cancel");r(le,Ce)},$$slots:{default:!0}}))};K(F,()=>Oe,(R,D)=>{D(R,{child:S,$$slots:{child:!0}})})}var X=o(F,2);{let S=h(()=>!!e(w)),R=h(()=>e(w)?`${e(w).title} is needed`:void 0);_e(X,{onclick:ce,get disabled(){return e(S)},get title(){return e(R)},children:(D,L)=>{se();var le=ie("Update and restart");r(D,le)},$$slots:{default:!0}})}r(P,E)},$$slots:{default:!0}})}),r(j,z)},Be=j=>{var z=rt(),t=C(z);{let l=h(()=>a.update.id),v=h(()=>e(x).version),P=h(()=>e(x).commit.slice(0,7)),G=h(()=>e(f)==="saving"||e(f)==="restarting"||e(f)==="done"||e(f)==="slow"?e(f):"saving");St(t,{get label(){return`Replace ${e(l)??""} with ${e(v)??""} at ${e(P)??""}`},get phase(){return e(G)}})}var n=o(t,2);{var i=l=>{var v=na(),P=q(v);b(()=>k(P,`${a.name??""}
1
+ import"../chunks/DsnmJJEf.js";import{o as mt}from"../chunks/RYq3318d.js";import{p as Ve,m as H,q as nt,f as C,h as _,r as m,s as o,j as Te,n as se,w as ie,t as b,d as k,a as r,g as e,v as c,i as h,b as Xe,o as q,c as d,l as ot,y as Me,k as _t,$ as pt,aB as ht}from"../chunks/BuRWgnCz.js";import{i as W}from"../chunks/BDpRITyb.js";import{k as xt}from"../chunks/rS7QE60d.js";import{s as ee,a as Ge,f as He,r as Ye,e as ze,c as Ze,h as wt}from"../chunks/Cwb6d3g_.js";import{i as Ne}from"../chunks/cM1ZMvyM.js";import{p as Je}from"../chunks/BSBcdyd3.js";import{S as bt}from"../chunks/CzBY7r8x.js";import{I as kt}from"../chunks/D-2tF-22.js";import{D as Oe,I as yt}from"../chunks/Deh9Yuoc.js";import{c as K}from"../chunks/DLuhTA05.js";import{p as Ke,s as Le}from"../chunks/BAOiF0in.js";import{D as Pt,a as Ct,b as Tt,c as Dt,d as $e,P as Wt,e as Rt,f as It,m as jt,i as zt}from"../chunks/Cpxqeawy.js";import{B as _e}from"../chunks/C5BN6RHR.js";import{C as St,b as Ut,u as At,d as Bt,e as Et,p as Ft,f as Nt,c as Ot}from"../chunks/BDtt0Y7t.js";import{L as et}from"../chunks/CP7u-DWX.js";import{T as tt}from"../chunks/kynOtL7x.js";import{C as Lt}from"../chunks/cmRB1an4.js";import{C as $t}from"../chunks/CCL5M9Xl.js";import{S as qt}from"../chunks/BwPKBiav.js";import{R as Qe,E as Mt,e as Gt,w as Ht}from"../chunks/CMmxYmuw.js";import{l as at}from"../chunks/DglJ92hi.js";import{a as Jt}from"../chunks/BCUUi0V0.js";import{R as Kt}from"../chunks/DXoZBzFG.js";import{C as Qt}from"../chunks/CqfUJirh.js";var Vt=d('<span class="flex items-center gap-1.5 text-muted-foreground"><!>Checking…</span>'),Xt=d('<span class="flex items-center gap-1.5 text-muted-foreground"><!>Up to date</span>'),Yt=d('<span class="text-muted-foreground" title="Installed at a commit, so it is not checked">Pinned to a commit</span>'),Zt=d('<span class="flex items-center gap-1.5 text-muted-foreground"><!>Could not check</span>'),ea=d("<!> ",1),ta=d('<span class="text-sea"> </span> <!>',1),qe=d("<!> <!>",1),aa=d('<p class="flex items-center gap-2 text-muted-foreground"><!> </p>'),ra=d('<p class="flex items-start gap-2 text-xs text-danger" role="alert"><!> </p> <!>',1),sa=d('<p class="text-xs text-danger" role="alert"> </p>'),rt=d("<!> <!> <!>",1),na=d("<p> </p>"),oa=d('<div class="flex flex-wrap items-center justify-end gap-2 text-xs sm:min-w-48"><!></div> <!>',1);function la(pe,a){Ve(a,!0);let ne=Ke(a,"checking",3,!1),de=Ke(a,"busy",19,()=>[]),U=H(!1),f=H("looking"),I=H(null),x=H(null),Q=H(nt({}));const w=h(()=>e(x)?jt(e(x),e(Q)):null),N=()=>Je.data.sessionToken;async function O(){c(U,!0),c(f,"looking"),c(I,null),c(x,null);const g=a.update.state==="newer-tag"?a.update.latest?.ref??null:null,u=await Bt({id:a.update.id,ref:g},N());if(!u.ok){c(I,u.error,!0),c(f,"failed");return}c(x,u.value,!0),c(Q,zt(u.value),!0),c(f,"review")}async function ce(){if(!e(x)||e(w))return;c(f,"saving"),c(I,null);const g=Ut(),u=await At(e(x),It(e(Q)),N());if(!u.ok){c(I,u.error,!0),c(f,"review");return}c(f,"restarting"),c(f,await g?"done":"slow",!0)}var ue=oa(),V=C(ue),he=_(V);{var xe=g=>{var u=Vt(),T=_(u);et(T,{class:"size-3.5 animate-spin"}),se(),m(u),r(g,u)},A=g=>{var u=Xt(),T=_(u);Lt(T,{class:"size-3.5 text-success"}),se(),m(u),r(g,u)},B=g=>{var u=Yt();r(g,u)},M=g=>{var u=Zt(),T=_(u);tt(T,{class:"size-3.5 text-warning"}),se(),m(u),b(()=>ee(u,"title",a.update.reason??void 0)),r(g,u)},J=g=>{var u=ta(),T=C(u),te=q(T,!0),ae=o(T,2);_e(ae,{variant:"outline",size:"xs",onclick:O,children:(we,be)=>{var fe=ea(),ve=C(fe);$t(ve,{});var ke=o(ve,1,!0);b(()=>k(ke,a.update.state==="newer-tag"?`Move to ${a.update.latest?.ref}`:"Update")),r(we,fe)},$$slots:{default:!0}}),b(()=>k(te,a.update.state==="newer-tag"?`${a.update.latest?.ref} is out`:`New commits${a.update.ref?` on ${a.update.ref}`:""}`)),r(g,u)};W(he,g=>{ne()?g(xe):a.update.state==="current"?g(A,1):a.update.state==="pinned"?g(B,2):a.update.state==="error"?g(M,3):g(J,-1)})}m(V);var oe=o(V,2);K(oe,()=>Rt,(g,u)=>{u(g,{get open(){return e(U)},set open(T){c(U,T,!0)},children:(T,te)=>{var ae=Te(),we=C(ae);{let be=h(()=>e(f)==="saving"||e(f)==="restarting"?"ignore":"close");K(we,()=>Pt,(fe,ve)=>{ve(fe,{class:"max-h-[calc(100dvh-2rem)] overflow-y-auto sm:max-w-lg",get interactOutsideBehavior(){return e(be)},children:(ke,Se)=>{var De=qe(),ye=C(De);K(ye,()=>Ct,(j,z)=>{z(j,{children:(t,n)=>{var i=qe(),s=C(i);K(s,()=>Tt,(v,P)=>{P(v,{class:"font-display text-lg",children:(G,E)=>{se();var F=ie();b(()=>k(F,`Update ${a.name??""}`)),r(G,F)},$$slots:{default:!0}})});var l=o(s,2);K(l,()=>Dt,(v,P)=>{P(v,{class:"tabular",children:(G,E)=>{var F=Te(),X=C(F);{var S=D=>{var L=ie();b(()=>k(L,`${a.update.version??""} → ${e(x).version??""}${a.update.state==="newer-tag"&&a.update.ref?`, from ${a.update.ref} to ${e(x).ref}`:""}`)),r(D,L)},R=D=>{var L=ie();b(()=>k(L,a.update.repository)),r(D,L)};W(X,D=>{e(x)?D(S):D(R,-1)})}r(G,F)},$$slots:{default:!0}})}),r(t,i)},$$slots:{default:!0}})});var Ue=o(ye,2);{var We=j=>{var z=aa(),t=_(z);et(t,{class:"size-4 animate-spin"});var n=o(t);m(z),b(()=>k(n,`Fetching ${a.update.repository??""}…`)),r(j,z)},Re=j=>{var z=ra(),t=C(z),n=_(t);tt(n,{class:"mt-0.5 size-3.5 shrink-0"});var i=o(n,1,!0);m(t);var s=o(t,2);K(s,()=>$e,(l,v)=>{v(l,{children:(P,G)=>{var E=Te(),F=C(E);{const X=(S,R)=>{_e(S,Le(()=>(R?.()).props,{variant:"ghost",children:(L,le)=>{se();var Pe=ie("Close");r(L,Pe)},$$slots:{default:!0}}))};K(F,()=>Oe,(S,R)=>{R(S,{child:X,$$slots:{child:!0}})})}r(P,E)},$$slots:{default:!0}})}),b(()=>k(i,e(I))),r(j,z)},Ae=j=>{var z=rt(),t=C(z);Wt(t,{get preview(){return e(x)},get busy(){return de()},get answers(){return e(Q)},set answers(l){c(Q,l,!0)}});var n=o(t,2);{var i=l=>{var v=sa(),P=q(v,!0);b(()=>k(P,e(I))),r(l,v)};W(n,l=>{e(I)&&l(i)})}var s=o(n,2);K(s,()=>$e,(l,v)=>{v(l,{children:(P,G)=>{var E=qe(),F=C(E);{const S=(R,D)=>{_e(R,Le(()=>(D?.()).props,{variant:"ghost",children:(le,Pe)=>{se();var Ce=ie("Cancel");r(le,Ce)},$$slots:{default:!0}}))};K(F,()=>Oe,(R,D)=>{D(R,{child:S,$$slots:{child:!0}})})}var X=o(F,2);{let S=h(()=>!!e(w)),R=h(()=>e(w)?`${e(w).title} is needed`:void 0);_e(X,{onclick:ce,get disabled(){return e(S)},get title(){return e(R)},children:(D,L)=>{se();var le=ie("Update and restart");r(D,le)},$$slots:{default:!0}})}r(P,E)},$$slots:{default:!0}})}),r(j,z)},Be=j=>{var z=rt(),t=C(z);{let l=h(()=>a.update.id),v=h(()=>e(x).version),P=h(()=>e(x).commit.slice(0,7)),G=h(()=>e(f)==="saving"||e(f)==="restarting"||e(f)==="done"||e(f)==="slow"?e(f):"saving");St(t,{get label(){return`Replace ${e(l)??""} with ${e(v)??""} at ${e(P)??""}`},get phase(){return e(G)}})}var n=o(t,2);{var i=l=>{var v=na(),P=q(v);b(()=>k(P,`${a.name??""}
2
2
  ${e(x).version??""} is installed and Wheelhouse restarted. Its row shows whether it loaded.`)),r(l,v)};W(n,l=>{e(f)==="done"&&l(i)})}var s=o(n,2);K(s,()=>$e,(l,v)=>{v(l,{children:(P,G)=>{var E=Te(),F=C(E);{const X=(S,R)=>{let D=()=>(R?.()).props;{let L=h(()=>e(f)==="saving"||e(f)==="restarting");_e(S,Le(D,{get disabled(){return e(L)},children:(le,Pe)=>{se();var Ce=ie("Done");r(le,Ce)},$$slots:{default:!0}}))}};K(F,()=>Oe,(S,R)=>{R(S,{child:X,$$slots:{child:!0}})})}r(P,E)},$$slots:{default:!0}})}),r(j,z)};W(Ue,j=>{e(f)==="looking"?j(We):e(f)==="failed"?j(Re,1):e(f)==="review"&&e(x)?j(Ae,2):e(x)&&j(Be,3)})}r(ke,De)},$$slots:{default:!0}})})}r(T,ae)},$$slots:{default:!0}})}),b(()=>ee(V,"data-update",a.update.state)),r(pe,ue),Xe()}var ia=d('<span class="text-xs text-muted-foreground">· off; turn it on below to choose it</span>'),da=d('<label><input type="radio" class="mt-1"/> <span> <!></span></label>'),ua=d('<p class="mt-2 text-xs text-warning" data-role-off=""> </p>'),va=d(`<fieldset class="rounded-lg border bg-card px-4 py-3"><legend class="px-1 text-sm font-medium"> </legend> <p class="text-xs text-muted-foreground">Where you review what the crew shows you. A plugin chosen here replaces Lavish and the preview
3
3
  helper while it is on; turning it off or removing it brings them back.</p> <div class="mt-2 grid gap-0.5"><label><input type="radio" class="mt-1"/> <span> </span></label> <!></div> <!></fieldset>`);function ca(pe,a){Ve(a,!0);let ne=Ke(a,"disabled",3,!1);const de=h(()=>Qe[a.view.role]),U=h(()=>a.view.chosen!==null&&a.view.active===null?a.view.providers.find(A=>A.id===a.view.chosen)?.name??a.view.chosen:null),f="flex items-start gap-2 rounded-md px-2 py-1.5 text-sm has-[:disabled]:text-muted-foreground has-[:enabled]:cursor-pointer has-[:enabled]:hover:bg-accent";var I=va(),x=_(I),Q=q(x,!0),w=o(x,4),N=_(w);Ge(N,1,He(f));var O=_(N);Ye(O);var ce=o(O,2),ue=q(ce,!0);m(N);var V=o(N,2);ze(V,17,()=>a.view.providers,A=>A.id,(A,B)=>{var M=da();Ge(M,1,He(f));var J=_(M);Ye(J);var oe=o(J,2),g=_(oe,!0),u=o(g);{var T=te=>{var ae=ia();r(te,ae)};W(u,te=>{e(B).on||te(T)})}m(oe),m(M),b(()=>{ee(M,"data-provider",e(B).id),ee(J,"name",`role-${a.view.role??""}`),Ze(J,a.view.chosen===e(B).id),J.disabled=ne()||!e(B).on&&a.view.chosen!==e(B).id,k(g,e(B).name)}),Me("change",J,()=>a.onchoose(e(B).id)),r(A,M)}),m(w);var he=o(w,2);{var xe=A=>{var B=ua(),M=q(B);b(()=>k(M,`${e(U)??""} is chosen but off, so the built-in is in use until it is on again.`)),r(A,B)};W(he,A=>{e(U)&&A(xe)})}m(I),b(()=>{ee(I,"data-role",a.view.role),k(Q,e(de).title),ee(O,"name",`role-${a.view.role??""}`),Ze(O,a.view.chosen===null),O.disabled=ne(),k(ue,e(de).builtin)}),Me("change",O,()=>a.onchoose(null)),r(pe,I),Xe()}ot(["change"]);var fa=d('<span class="hidden text-xs text-muted-foreground sm:inline"> </span>'),ga=d(`<!>Check for
4
4
  updates`,1),ma=d('<p class="mt-3 text-xs text-danger" role="alert"> </p>'),_a=d('<p class="mt-6 rounded-lg border border-danger/40 p-4 text-sm text-danger">Wheelhouse could not read which plugins are installed, so none of them loaded.</p>'),pa=d(`<p class="mt-6 rounded-lg border border-danger/40 p-4 text-sm text-danger">Wheelhouse’s plugins file is not valid, so every plugin keeps its default and nothing can be
@@ -1,2 +1,2 @@
1
- import"../chunks/DsnmJJEf.js";import{o as ft}from"../chunks/RYq3318d.js";import{l as pt,p as gt,m as T,q as Se,z as _t,f as P,t as f,a as d,b as xt,v as u,e as bt,g as e,d as l,c as i,h as c,s as a,i as w,o as m,$ as ht,r as v,w as Ee,y as ee,n as te,x as wt}from"../chunks/BuRWgnCz.js";import{i as x}from"../chunks/BDpRITyb.js";import{h as yt,e as je,s as re,a as kt}from"../chunks/Cwb6d3g_.js";import{i as $t}from"../chunks/CU0ZJcdF.js";import{p as Wt}from"../chunks/_8osrypQ.js";import{S as St}from"../chunks/DwBYQnih.js";import{E as Et,w as jt,a as Pt,d as Pe,b as Rt,c as Tt,r as Ot,m as At,e as Bt}from"../chunks/CMmxYmuw.js";import{a as Re,c as Te,S as Ct,C as Ft,b as Nt,l as zt}from"../chunks/CxexnUzw.js";import{S as It}from"../chunks/BwPKBiav.js";import{B as Oe}from"../chunks/C5BN6RHR.js";import{l as qt}from"../chunks/D8F9xgmh.js";import{R as Dt}from"../chunks/nW7-TN7t.js";var Lt=i('<p class="mt-1 max-w-prose text-sm text-muted-foreground"> </p>'),Vt=i('<p class="rounded-lg border border-danger/40 p-4 text-sm text-danger" role="alert"> </p>'),Ht=i('<div class="mt-3"><!></div>'),Mt=i("<!>Load and restart",1),Ut=i('<p class="mt-2 text-muted-foreground">This Wheelhouse cannot restart itself, so turn it on in a terminal with <code> </code>.</p>'),Gt=i('<p class="mt-2 text-danger" role="alert"> </p>'),Jt=i('<p class="mt-0.5 text-muted-foreground"> </p> <!> <!>',1),Kt=i('<section class="rounded-md border border-brass/60 bg-background px-4 py-3 text-sm" aria-labelledby="not-loaded"><h2 id="not-loaded" class="font-medium">Not loaded</h2> <!></section>'),Qt=i('<p class="rounded-lg border border-danger/40 p-4 text-sm text-danger"> </p>'),Xt=i('<p class="mt-2 text-xs text-muted-foreground"> </p>'),Yt=i(' <button type="button" class="cursor-pointer text-sea hover:underline disabled:cursor-not-allowed">Back to the default</button>',1),Zt=i('<button type="button" role="radio"> </button>'),er=i('<li class="flex flex-wrap items-center justify-between gap-x-4 gap-y-2 px-4 py-2.5 text-sm"><span class="min-w-0 break-words"> <span class="text-xs text-muted-foreground"> </span></span> <div class="inline-flex rounded-md border bg-muted/50 p-0.5 text-xs" role="radiogroup"></div></li>'),tr=i('<ul class="mt-2 divide-y rounded-md border bg-background" aria-label="Projects"></ul>'),rr=i('<p class="mt-2 text-sm text-muted-foreground">Wheelhouse knows no projects yet.</p>'),ar=i('<p class="mt-3 text-sm text-muted-foreground"> </p>'),sr=i('<span class="text-xs text-muted-foreground">Not saved yet</span> <button type="button" class="cursor-pointer text-xs text-muted-foreground hover:text-foreground hover:underline">Undo changes</button>',1),or=i('<form class="mt-3 grid max-w-xl gap-4 rounded-md border bg-background px-4 py-4"><!> <div class="flex flex-wrap items-center gap-3"><!> <!></div></form>'),nr=i('<dt class="text-muted-foreground">Addresses</dt> <dd> </dd>',1),dr=i('<dt class="text-muted-foreground">Sends</dt> <dd> </dd>',1),lr=i('<dt class="text-muted-foreground">Role</dt> <dd data-roles=""> </dd>',1),ir=i('<main class="px-4 py-6 sm:px-6 lg:px-10"><div class="surface px-5 py-6 sm:px-8 sm:py-8"><!> <p class="mt-6 text-sm text-muted-foreground"><a href="/settings/plugins" class="hover:text-foreground hover:underline">Plugins</a> <span aria-hidden="true">/</span> </p> <h1 class="mt-1 text-2xl"> </h1> <!> <div class="mt-8 grid max-w-3xl gap-8"><!> <!> <section aria-labelledby="where-on"><h2 id="where-on" class="section-label">Where it is on</h2> <!> <div class="mt-3 flex items-center justify-between gap-4 rounded-md border bg-background px-4 py-3"><div class="min-w-0 text-sm"><p class="font-medium">Every project <span class="font-normal text-muted-foreground" data-where=""> </span></p> <p class="text-xs text-muted-foreground" data-testid="every-project"><!></p></div> <!></div> <!></section> <section aria-labelledby="settings"><h2 id="settings" class="section-label">Settings</h2> <!></section> <section aria-labelledby="about"><h2 id="about" class="section-label">About</h2> <dl class="mt-3 grid grid-cols-[7rem_minmax(0,1fr)] gap-x-3 gap-y-1.5 text-sm"><dt class="text-muted-foreground">Adds</dt> <dd> </dd> <!> <!> <!> <dt class="text-muted-foreground">From</dt> <dd class="break-words"> </dd> <dt class="text-muted-foreground">Version</dt> <dd class="tabular"> </dd> <dt class="text-muted-foreground">By default</dt> <dd> </dd></dl></section></div></div></main> <!>',1);function $r(Ae,F){gt(F,!0);let N=T(null);const g=w(()=>e(N)??F.data.view),o=w(()=>e(g).plugin),L=()=>Wt.data.sessionToken;let A=T(!1),V=T(null),H;function B(t,r=!0){u(V,{text:t,ok:r},!0),clearTimeout(H),H=setTimeout(()=>u(V,null),r?4e3:8e3)}const Be="It applies now, with no restart.";async function M(t,r){u(A,!0);const s=await Te(e(o).id,t,L());if(u(A,!1),!s.ok)return B(s.error,!1);u(N,s.value,!0),B(`${typeof r=="string"?r:r(s.value)} ${Be}`)}let $=T(Se({})),C=T(Se({}));_t(()=>{const t=Re(F.data.view.settings);u($,{...t},!0),u(C,t,!0)});const ae=w(()=>Object.keys(e($)).some(t=>e($)[t]!==e(C)[t])),se=w(()=>e(g).settings.find(t=>t.required&&!e($)[t.key]?.trim()));async function Ce(t){if(t.preventDefault(),e(se))return B(`${e(se).title} is needed.`,!1);u(A,!0);const r=await Te(e(o).id,{settings:{...e($)}},L());if(u(A,!1),!r.ok)return B(r.error,!1);u(N,r.value,!0),u(C,Re(r.value.settings),!0),u($,{...e(C)},!0),B(`Settings saved. ${e(o).name} uses them from its next look, with no restart.`)}let O=T(null),z=T(null);async function Fe(){u(O,"saving"),u(z,null);const t=Nt(),r=await zt(e(o).id,L());if(!r.ok){u(O,null),u(z,r.error,!0);return}u(O,"restarting"),u(O,await t?"done":"slow",!0)}ft(()=>{const t=qt.onRestart(()=>{u(N,null),$t()});return()=>{t(),clearTimeout(H)}});const Ne=[{value:null,label:"As the plugin"},{value:!0,label:"On"},{value:!1,label:"Off"}],ze=w(()=>e(o).source==="installed"&&e(o).repository?`${e(o).repository}${e(o).commit?` at ${e(o).commit.slice(0,7)}`:""}`:"Comes with Wheelhouse"),oe=w(()=>Rt(e(o).hostRoutes??[],e(o).addressRewrites??[])),ne=w(()=>Tt(e(o).capabilities??[])),de=w(()=>Ot(e(o).provides??[])),I=w(()=>e(A)||!!e(g).configError);var le=ir();yt("kxeh91",t=>{bt(()=>{ht.title=`${e(o).name??""} · Plugins · Wheelhouse`})});var U=P(le),ie=c(U),ue=c(ie);St(ue,{});var G=a(ue,2),Ie=a(c(G),3);v(G);var ve=a(G,2),qe=m(ve,!0),ce=a(ve,2);{var De=t=>{var r=Lt(),s=m(r,!0);f(()=>l(s,e(o).description)),d(t,r)};x(ce,t=>{e(o).description&&t(De)})}var me=a(ce,2),fe=c(me);{var Le=t=>{var r=Vt(),s=m(r,!0);f(()=>l(s,e(g).configError)),d(t,r)};x(fe,t=>{e(g).configError&&t(Le)})}var pe=a(fe,2);{var Ve=t=>{var r=Kt(),s=a(c(r),2);{var n=b=>{var h=Ht(),_=c(h);Ft(_,{label:"Turn it on",get phase(){return e(O)}}),v(h),d(b,h)},p=b=>{var h=Jt(),_=P(h),y=m(_),W=a(_,2);{var R=k=>{Oe(k,{class:"mt-3",size:"sm",onclick:Fe,children:(j,q)=>{var D=Mt(),mt=P(D);Dt(mt,{}),te(),d(j,D)},$$slots:{default:!0}})},S=k=>{var j=Ut(),q=a(c(j)),D=m(q);te(),v(j),f(()=>l(D,`wheelhouse plugin enable ${e(o).id??""}`)),d(k,j)};x(W,k=>{F.data.canRestart?k(R):k(S,-1)})}var E=a(W,2);{var Z=k=>{var j=Gt(),q=m(j,!0);f(()=>l(q,e(z))),d(k,j)};x(E,k=>{e(z)&&k(Z)})}f(()=>l(y,`${e(o).name??""} is installed but turned off, so Wheelhouse has not started it. Wheelhouse loads
1
+ import"../chunks/DsnmJJEf.js";import{o as ft}from"../chunks/RYq3318d.js";import{l as pt,p as gt,m as T,q as Se,z as _t,f as P,t as f,a as d,b as xt,v as u,e as bt,g as e,d as l,c as i,h as c,s as a,i as w,o as m,$ as ht,r as v,w as Ee,y as ee,n as te,x as wt}from"../chunks/BuRWgnCz.js";import{i as x}from"../chunks/BDpRITyb.js";import{h as yt,e as je,s as re,a as kt}from"../chunks/Cwb6d3g_.js";import{i as $t}from"../chunks/cM1ZMvyM.js";import{p as Wt}from"../chunks/BSBcdyd3.js";import{S as St}from"../chunks/CzBY7r8x.js";import{E as Et,w as jt,a as Pt,d as Pe,b as Rt,c as Tt,r as Ot,m as At,e as Bt}from"../chunks/CMmxYmuw.js";import{a as Re,c as Te,S as Ct,C as Ft,b as Nt,l as zt}from"../chunks/BDtt0Y7t.js";import{S as It}from"../chunks/BwPKBiav.js";import{B as Oe}from"../chunks/C5BN6RHR.js";import{l as qt}from"../chunks/DglJ92hi.js";import{R as Dt}from"../chunks/nW7-TN7t.js";var Lt=i('<p class="mt-1 max-w-prose text-sm text-muted-foreground"> </p>'),Vt=i('<p class="rounded-lg border border-danger/40 p-4 text-sm text-danger" role="alert"> </p>'),Ht=i('<div class="mt-3"><!></div>'),Mt=i("<!>Load and restart",1),Ut=i('<p class="mt-2 text-muted-foreground">This Wheelhouse cannot restart itself, so turn it on in a terminal with <code> </code>.</p>'),Gt=i('<p class="mt-2 text-danger" role="alert"> </p>'),Jt=i('<p class="mt-0.5 text-muted-foreground"> </p> <!> <!>',1),Kt=i('<section class="rounded-md border border-brass/60 bg-background px-4 py-3 text-sm" aria-labelledby="not-loaded"><h2 id="not-loaded" class="font-medium">Not loaded</h2> <!></section>'),Qt=i('<p class="rounded-lg border border-danger/40 p-4 text-sm text-danger"> </p>'),Xt=i('<p class="mt-2 text-xs text-muted-foreground"> </p>'),Yt=i(' <button type="button" class="cursor-pointer text-sea hover:underline disabled:cursor-not-allowed">Back to the default</button>',1),Zt=i('<button type="button" role="radio"> </button>'),er=i('<li class="flex flex-wrap items-center justify-between gap-x-4 gap-y-2 px-4 py-2.5 text-sm"><span class="min-w-0 break-words"> <span class="text-xs text-muted-foreground"> </span></span> <div class="inline-flex rounded-md border bg-muted/50 p-0.5 text-xs" role="radiogroup"></div></li>'),tr=i('<ul class="mt-2 divide-y rounded-md border bg-background" aria-label="Projects"></ul>'),rr=i('<p class="mt-2 text-sm text-muted-foreground">Wheelhouse knows no projects yet.</p>'),ar=i('<p class="mt-3 text-sm text-muted-foreground"> </p>'),sr=i('<span class="text-xs text-muted-foreground">Not saved yet</span> <button type="button" class="cursor-pointer text-xs text-muted-foreground hover:text-foreground hover:underline">Undo changes</button>',1),or=i('<form class="mt-3 grid max-w-xl gap-4 rounded-md border bg-background px-4 py-4"><!> <div class="flex flex-wrap items-center gap-3"><!> <!></div></form>'),nr=i('<dt class="text-muted-foreground">Addresses</dt> <dd> </dd>',1),dr=i('<dt class="text-muted-foreground">Sends</dt> <dd> </dd>',1),lr=i('<dt class="text-muted-foreground">Role</dt> <dd data-roles=""> </dd>',1),ir=i('<main class="px-4 py-6 sm:px-6 lg:px-10"><div class="surface px-5 py-6 sm:px-8 sm:py-8"><!> <p class="mt-6 text-sm text-muted-foreground"><a href="/settings/plugins" class="hover:text-foreground hover:underline">Plugins</a> <span aria-hidden="true">/</span> </p> <h1 class="mt-1 text-2xl"> </h1> <!> <div class="mt-8 grid max-w-3xl gap-8"><!> <!> <section aria-labelledby="where-on"><h2 id="where-on" class="section-label">Where it is on</h2> <!> <div class="mt-3 flex items-center justify-between gap-4 rounded-md border bg-background px-4 py-3"><div class="min-w-0 text-sm"><p class="font-medium">Every project <span class="font-normal text-muted-foreground" data-where=""> </span></p> <p class="text-xs text-muted-foreground" data-testid="every-project"><!></p></div> <!></div> <!></section> <section aria-labelledby="settings"><h2 id="settings" class="section-label">Settings</h2> <!></section> <section aria-labelledby="about"><h2 id="about" class="section-label">About</h2> <dl class="mt-3 grid grid-cols-[7rem_minmax(0,1fr)] gap-x-3 gap-y-1.5 text-sm"><dt class="text-muted-foreground">Adds</dt> <dd> </dd> <!> <!> <!> <dt class="text-muted-foreground">From</dt> <dd class="break-words"> </dd> <dt class="text-muted-foreground">Version</dt> <dd class="tabular"> </dd> <dt class="text-muted-foreground">By default</dt> <dd> </dd></dl></section></div></div></main> <!>',1);function $r(Ae,F){gt(F,!0);let N=T(null);const g=w(()=>e(N)??F.data.view),o=w(()=>e(g).plugin),L=()=>Wt.data.sessionToken;let A=T(!1),V=T(null),H;function B(t,r=!0){u(V,{text:t,ok:r},!0),clearTimeout(H),H=setTimeout(()=>u(V,null),r?4e3:8e3)}const Be="It applies now, with no restart.";async function M(t,r){u(A,!0);const s=await Te(e(o).id,t,L());if(u(A,!1),!s.ok)return B(s.error,!1);u(N,s.value,!0),B(`${typeof r=="string"?r:r(s.value)} ${Be}`)}let $=T(Se({})),C=T(Se({}));_t(()=>{const t=Re(F.data.view.settings);u($,{...t},!0),u(C,t,!0)});const ae=w(()=>Object.keys(e($)).some(t=>e($)[t]!==e(C)[t])),se=w(()=>e(g).settings.find(t=>t.required&&!e($)[t.key]?.trim()));async function Ce(t){if(t.preventDefault(),e(se))return B(`${e(se).title} is needed.`,!1);u(A,!0);const r=await Te(e(o).id,{settings:{...e($)}},L());if(u(A,!1),!r.ok)return B(r.error,!1);u(N,r.value,!0),u(C,Re(r.value.settings),!0),u($,{...e(C)},!0),B(`Settings saved. ${e(o).name} uses them from its next look, with no restart.`)}let O=T(null),z=T(null);async function Fe(){u(O,"saving"),u(z,null);const t=Nt(),r=await zt(e(o).id,L());if(!r.ok){u(O,null),u(z,r.error,!0);return}u(O,"restarting"),u(O,await t?"done":"slow",!0)}ft(()=>{const t=qt.onRestart(()=>{u(N,null),$t()});return()=>{t(),clearTimeout(H)}});const Ne=[{value:null,label:"As the plugin"},{value:!0,label:"On"},{value:!1,label:"Off"}],ze=w(()=>e(o).source==="installed"&&e(o).repository?`${e(o).repository}${e(o).commit?` at ${e(o).commit.slice(0,7)}`:""}`:"Comes with Wheelhouse"),oe=w(()=>Rt(e(o).hostRoutes??[],e(o).addressRewrites??[])),ne=w(()=>Tt(e(o).capabilities??[])),de=w(()=>Ot(e(o).provides??[])),I=w(()=>e(A)||!!e(g).configError);var le=ir();yt("kxeh91",t=>{bt(()=>{ht.title=`${e(o).name??""} · Plugins · Wheelhouse`})});var U=P(le),ie=c(U),ue=c(ie);St(ue,{});var G=a(ue,2),Ie=a(c(G),3);v(G);var ve=a(G,2),qe=m(ve,!0),ce=a(ve,2);{var De=t=>{var r=Lt(),s=m(r,!0);f(()=>l(s,e(o).description)),d(t,r)};x(ce,t=>{e(o).description&&t(De)})}var me=a(ce,2),fe=c(me);{var Le=t=>{var r=Vt(),s=m(r,!0);f(()=>l(s,e(g).configError)),d(t,r)};x(fe,t=>{e(g).configError&&t(Le)})}var pe=a(fe,2);{var Ve=t=>{var r=Kt(),s=a(c(r),2);{var n=b=>{var h=Ht(),_=c(h);Ft(_,{label:"Turn it on",get phase(){return e(O)}}),v(h),d(b,h)},p=b=>{var h=Jt(),_=P(h),y=m(_),W=a(_,2);{var R=k=>{Oe(k,{class:"mt-3",size:"sm",onclick:Fe,children:(j,q)=>{var D=Mt(),mt=P(D);Dt(mt,{}),te(),d(j,D)},$$slots:{default:!0}})},S=k=>{var j=Ut(),q=a(c(j)),D=m(q);te(),v(j),f(()=>l(D,`wheelhouse plugin enable ${e(o).id??""}`)),d(k,j)};x(W,k=>{F.data.canRestart?k(R):k(S,-1)})}var E=a(W,2);{var Z=k=>{var j=Gt(),q=m(j,!0);f(()=>l(q,e(z))),d(k,j)};x(E,k=>{e(z)&&k(Z)})}f(()=>l(y,`${e(o).name??""} is installed but turned off, so Wheelhouse has not started it. Wheelhouse loads
2
2
  plugins when it starts, so loading it restarts Wheelhouse; Firstmate and its crew keep running.`)),d(b,h)};x(s,b=>{e(O)?b(n):b(p,-1)})}v(r),d(t,r)},He=t=>{var r=Qt(),s=m(r,!0);f(()=>l(s,e(o).reason??"Wheelhouse could not load it.")),d(t,r)};x(pe,t=>{e(o).state==="disabled"?t(Ve):e(o).state!=="loaded"&&t(He,1)})}var J=a(pe,2),ge=a(c(J),2);{var Me=t=>{var r=Xt(),s=m(r);f(()=>l(s,`What you choose here applies once ${e(o).name??""} is loaded.`)),d(t,r)};x(ge,t=>{e(o).state!=="loaded"&&t(Me)})}var K=a(ge,2),Q=c(K),X=c(Q),Ue=a(c(X)),Ge=m(Ue);v(X);var _e=a(X,2),Je=c(_e);{var Ke=t=>{var r=Ee();f(s=>l(r,`By default: ${s??""}. A project below can differ.`),[()=>At(Pe(e(o)))]),d(t,r)},Qe=t=>{var r=Yt(),s=P(r),n=a(s);f(()=>{l(s,`${e(g).on?"On":"Off"} for every project, except where a project below says otherwise. `),n.disabled=e(I)}),ee("click",n,()=>M({enabled:null},Bt)),d(t,r)};x(Je,t=>{e(g).enabled===null?t(Ke):t(Qe,-1)})}v(_e),v(Q);var Xe=a(Q,2);Et(Xe,{get view(){return e(g)},get disabled(){return e(I)},onchange:t=>M({enabled:t},`${e(o).name} is ${t?"on":"off"} for every project.`)}),v(K);var Ye=a(K,2);{var Ze=t=>{var r=tr();je(r,21,()=>e(g).projects,s=>s.id,(s,n)=>{var p=er(),b=c(p),h=c(b),_=a(h),y=m(_);v(b);var W=a(b,2);je(W,21,()=>Ne,R=>R.label,(R,S)=>{var E=Zt(),Z=m(E,!0);f(()=>{re(E,"aria-checked",e(n).enabled===e(S).value),E.disabled=e(I),kt(E,1,`min-h-7 cursor-pointer rounded px-2.5 py-1 transition-colors disabled:cursor-not-allowed ${e(n).enabled===e(S).value?"bg-card font-medium text-foreground shadow-sm ring-1 ring-hair":"text-muted-foreground hover:text-foreground"}`),l(Z,e(S).label)}),ee("click",E,()=>e(n).enabled!==e(S).value&&M({project:e(n).id,enabled:e(S).value},e(S).value===null?`${e(n).name} follows the plugin again.`:`${e(o).name} is ${e(S).value?"on":"off"} for ${e(n).name}.`)),d(R,E)}),v(W),v(p),f(()=>{re(p,"data-project",e(n).id),l(h,`${e(n).name??""} `),l(y,`· ${e(n).on?"on":"off"}${e(n).enabled===null?", as the plugin":""}`),re(W,"aria-label",`${e(o).name??""} for ${e(n).name??""}`)}),d(s,p)}),v(r),d(t,r)},et=t=>{var r=rr();d(t,r)};x(Ye,t=>{e(g).projects.length?t(Ze):t(et,-1)})}v(J);var Y=a(J,2),tt=a(c(Y),2);{var rt=t=>{var r=ar(),s=m(r);f(()=>l(s,`${e(o).name??""} has nothing to set.`)),d(t,r)},at=t=>{var r=or(),s=c(r);{let _=w(()=>!!e(g).configError);Ct(s,{get settings(){return e(g).settings},get disabled(){return e(_)},get answers(){return e($)},set answers(y){u($,y,!0)}})}var n=a(s,2),p=c(n);{let _=w(()=>!e(ae)||e(I));Oe(p,{type:"submit",size:"sm",get disabled(){return e(_)},children:(y,W)=>{te();var R=Ee("Save settings");d(y,R)},$$slots:{default:!0}})}var b=a(p,2);{var h=_=>{var y=sr(),W=a(P(y),2);ee("click",W,()=>u($,{...e(C)},!0)),d(_,y)};x(b,_=>{e(ae)&&_(h)})}v(n),v(r),wt("submit",r,Ce),d(t,r)};x(tt,t=>{e(g).settings.length===0?t(rt):t(at,-1)})}v(Y);var xe=a(Y,2),be=a(c(xe),2),he=a(c(be),2),st=m(he,!0),we=a(he,2);{var ot=t=>{var r=nr(),s=a(P(r),2),n=m(s,!0);f(p=>l(n,p),[()=>e(oe).join("; ")]),d(t,r)};x(we,t=>{e(oe).length&&t(ot)})}var ye=a(we,2);{var nt=t=>{var r=dr(),s=a(P(r),2),n=m(s,!0);f(p=>l(n,p),[()=>e(ne).join("; ")]),d(t,r)};x(ye,t=>{e(ne).length&&t(nt)})}var ke=a(ye,2);{var dt=t=>{var r=lr(),s=a(P(r),2),n=m(s,!0);f(p=>l(n,p),[()=>e(de).join("; ")]),d(t,r)};x(ke,t=>{e(de).length&&t(dt)})}var $e=a(ke,4),lt=m($e,!0),We=a($e,4),it=m(We,!0),ut=a(We,4),vt=m(ut,!0);v(be),v(xe),v(me),v(ie),v(U);var ct=a(U,2);It(ct,{get note(){return e(V)}}),f((t,r,s)=>{l(Ie,` ${e(o).name??""}`),l(qe,e(o).name),l(Ge,`· ${t??""}`),l(st,r),l(lt,e(ze)),l(it,e(o).version),l(vt,s)},[()=>jt(e(g)),()=>Pt(e(o).slots),()=>Pe(e(o))]),d(Ae,le),xt()}pt(["click"]);export{$r as component};
@@ -1,4 +1,4 @@
1
- import"../chunks/DsnmJJEf.js";import{p as N,a as n,b as q,k as E,w as b,c as f,h as i,$ as H,s as o,g as s,r as d,n as O,i as P,f as k,o as y,t as h,d as m}from"../chunks/BuRWgnCz.js";import{i as $}from"../chunks/BDpRITyb.js";import{h as T}from"../chunks/Cwb6d3g_.js";import{B as U}from"../chunks/C5BN6RHR.js";import{S as j}from"../chunks/DwBYQnih.js";var A=f('<code class="text-xs break-all text-foreground"> </code> ',1),G=f('<dt class="font-medium">Home</dt> <dd class="min-w-0"><code class="text-xs break-all"> </code></dd>',1),I=f(`<main class="px-4 py-6 sm:px-6 lg:px-10"><div class="surface px-5 py-6 sm:px-8 sm:py-8"><!> <h1 class="mt-6 text-2xl">Setup</h1> <p class="mt-1 max-w-prose text-sm text-muted-foreground">The setup wizard clones Firstmate or finds the one you have, checks the tools it needs and
1
+ import"../chunks/DsnmJJEf.js";import{p as N,a as n,b as q,k as E,w as b,c as f,h as i,$ as H,s as o,g as s,r as d,n as O,i as P,f as k,o as y,t as h,d as m}from"../chunks/BuRWgnCz.js";import{i as $}from"../chunks/BDpRITyb.js";import{h as T}from"../chunks/Cwb6d3g_.js";import{B as U}from"../chunks/C5BN6RHR.js";import{S as j}from"../chunks/CzBY7r8x.js";var A=f('<code class="text-xs break-all text-foreground"> </code> ',1),G=f('<dt class="font-medium">Home</dt> <dd class="min-w-0"><code class="text-xs break-all"> </code></dd>',1),I=f(`<main class="px-4 py-6 sm:px-6 lg:px-10"><div class="surface px-5 py-6 sm:px-8 sm:py-8"><!> <h1 class="mt-6 text-2xl">Setup</h1> <p class="mt-1 max-w-prose text-sm text-muted-foreground">The setup wizard clones Firstmate or finds the one you have, checks the tools it needs and
2
2
  Claude Code, runs Firstmate’s own checks and suggests plugins. Run it again any time: nothing
3
3
  is installed or changed without you agreeing first.</p> <dl class="mt-6 grid gap-x-6 gap-y-2 text-sm sm:grid-cols-[minmax(0,10rem)_minmax(0,1fr)]"><dt class="font-medium">Firstmate</dt> <dd class="min-w-0 text-muted-foreground"><!></dd> <!></dl> <div class="mt-6"><!></div></div></main>`);function X(S,x){N(x,!0);const a=P(()=>x.data.setup),D={flag:"given with --firstmate",cwd:"the Firstmate checkout Wheelhouse was started in",remembered:"chosen in setup, and remembered in Wheelhouse’s config"};var l=I();T("8kqwm0",t=>{E(()=>{H.title="Setup · Wheelhouse"})});var g=i(l),_=i(g);j(_,{});var c=o(_,6),u=o(i(c),2),F=i(u);{var C=t=>{var e=A(),r=k(e),p=y(r,!0),v=o(r);h(()=>{m(p,s(a).install.firstmateDir),m(v,`,
4
4
  ${D[s(a).install.source]??""}`)}),n(t,e)},R=t=>{var e=b();h(()=>m(e,`Not connected: ${s(a).problem??""}`)),n(t,e)};$(F,t=>{s(a).install?t(C):t(R,-1)})}d(u);var W=o(u,2);{var z=t=>{var e=G(),r=o(k(e),2),p=i(r),v=y(p,!0);d(r),h(()=>m(v,s(a).install.homeDir)),n(t,e)};$(W,t=>{s(a).install&&s(a).install.homeDir!==s(a).install.firstmateDir&&t(z)})}d(c);var w=o(c,2),B=i(w);U(B,{href:"/setup",children:(t,e)=>{O();var r=b("Run the setup wizard");n(t,r)},$$slots:{default:!0}}),d(w),d(g),d(l),n(S,l),q()}export{X as component};
@@ -1,4 +1,4 @@
1
- import"../chunks/DsnmJJEf.js";import{l as ae,p as re,m as N,q as oe,A as ie,u as ne,t as _,y as O,g as e,a as v,b as le,k as de,h as d,c as j,v as r,i as f,$ as ue,s as u,n as P,r as c,o as w,d as y,j as ce,f as pe}from"../chunks/BuRWgnCz.js";import{i as W}from"../chunks/BDpRITyb.js";import{h as he,r as B}from"../chunks/Cwb6d3g_.js";import{b as L}from"../chunks/BMFk7aZ6.js";import{p as me}from"../chunks/_8osrypQ.js";import{S as ve}from"../chunks/BXN538J3.js";import{S as fe}from"../chunks/DwBYQnih.js";import{w as Q}from"../chunks/DZeIs8RO.js";var be=j('<div class="rounded-md border border-warning/40 bg-warning/10 px-3 py-2 text-sm"><div class="font-medium text-warning">Install does not match chosen mode</div> <p class="mt-1 text-muted-foreground"> </p> <button type="button" class="mt-2 text-sm text-sea hover:underline disabled:opacity-50"> </button></div>'),V=j('<p class="text-sm text-danger" role="alert"> </p>'),ge=j('<p class="text-sm text-muted-foreground" aria-live="polite"> </p>'),xe=j(`<main class="px-4 py-6 sm:px-6 lg:px-10"><div class="surface px-5 py-6 sm:px-8 sm:py-8"><!> <h1 class="mt-6 text-2xl">Update</h1> <p class="mt-1 max-w-prose text-sm text-muted-foreground">Choose how Wheelhouse updates itself. Switching performs the reinstall or relink for the
1
+ import"../chunks/DsnmJJEf.js";import{l as ae,p as re,m as N,q as oe,A as ie,u as ne,t as _,y as O,g as e,a as v,b as le,k as de,h as d,c as j,v as r,i as f,$ as ue,s as u,n as P,r as c,o as w,d as y,j as ce,f as pe}from"../chunks/BuRWgnCz.js";import{i as W}from"../chunks/BDpRITyb.js";import{h as he,r as B}from"../chunks/Cwb6d3g_.js";import{b as L}from"../chunks/BMFk7aZ6.js";import{p as me}from"../chunks/BSBcdyd3.js";import{S as ve}from"../chunks/BXN538J3.js";import{S as fe}from"../chunks/CzBY7r8x.js";import{w as Q}from"../chunks/DZeIs8RO.js";var be=j('<div class="rounded-md border border-warning/40 bg-warning/10 px-3 py-2 text-sm"><div class="font-medium text-warning">Install does not match chosen mode</div> <p class="mt-1 text-muted-foreground"> </p> <button type="button" class="mt-2 text-sm text-sea hover:underline disabled:opacity-50"> </button></div>'),V=j('<p class="text-sm text-danger" role="alert"> </p>'),ge=j('<p class="text-sm text-muted-foreground" aria-live="polite"> </p>'),xe=j(`<main class="px-4 py-6 sm:px-6 lg:px-10"><div class="surface px-5 py-6 sm:px-8 sm:py-8"><!> <h1 class="mt-6 text-2xl">Update</h1> <p class="mt-1 max-w-prose text-sm text-muted-foreground">Choose how Wheelhouse updates itself. Switching performs the reinstall or relink for the
2
2
  chosen mode and restarts Wheelhouse.</p> <div class="mt-6 space-y-6"><div><div class="font-medium">Update source</div> <div class="mt-2 flex flex-col gap-3 text-sm"><label class="flex items-start gap-3"><input type="radio" name="source"/> <div><div class="font-medium">Published release</div> <p class="text-muted-foreground">Checks npm for the latest <code>@chrisjowen/wheelhouse</code> and updates the global npm
3
3
  install.</p></div></label> <label class="flex items-start gap-3"><input type="radio" name="source"/> <div><div class="font-medium">GitHub source</div> <p class="text-muted-foreground">Fast-forwards a local clone from GitHub, rebuilds and relinks (current behaviour).</p></div></label></div></div> <!> <!> <!> <p class="text-xs text-muted-foreground">Until a source is chosen it follows how Wheelhouse is installed. The header's update menu
4
4
  checks the chosen source every six hours and upgrades from it.</p></div></div></main>`);function Ce(X,H){re(H,!0);const A=[],k=f(()=>Q.view??H.data.view),i=f(()=>e(k).source),R=f(()=>e(k).mismatch),Y=f(()=>e(k).installKind),n=f(()=>e(k).job),S=f(()=>e(n)?.state==="running"||e(n)?.state==="restarting");let o=N(oe(ie(()=>H.data.view.source))),p=N(!1),b=N(null);ne(()=>{!e(S)&&!e(p)&&r(o,e(i),!0)});async function U(t){if(!(t===e(i)&&!e(R))){r(p,!0),r(b,null);try{const s=await fetch("/api/wheelhouse/source",{method:"POST",headers:{"content-type":"application/json",[ve]:me.data.sessionToken},body:JSON.stringify({source:t})}),a=await s.json().catch(()=>null);if(!s.ok||!a){r(b,a?.message??`Wheelhouse could not switch (${s.status}).`,!0),r(o,e(i),!0);return}a.job&&Q.follow(a)}catch{r(b,"Wheelhouse did not answer."),r(o,e(i),!0)}finally{r(p,!1)}}}var C=xe();he("1grzciw",t=>{de(()=>{ue.title="Update · Wheelhouse"})});var q=d(C),z=d(q);fe(z,{});var D=u(z,6),G=d(D),F=u(d(G),2),T=d(F),h=d(T);B(h),h.value=h.__value="published",P(2),c(T);var J=u(T,2),m=d(J);B(m),m.value=m.__value="github",P(2),c(J),c(F),c(G);var K=u(G,2);{var Z=t=>{var s=be(),a=u(d(s),2),$=w(a),g=u(a,2),l=w(g,!0);c(s),_(()=>{y($,`Wheelhouse is running ${e(Y)==="clone"?"from a git clone":"from the npm package"},
@@ -0,0 +1,20 @@
1
+ import"../chunks/DsnmJJEf.js";import{o as Yt}from"../chunks/RYq3318d.js";import{l as Zt,p as ea,f as H,h as d,o as h,r as i,t as p,d as v,y as _t,a as t,s as r,g as e,b as ta,i as $,c as l,m as X,n as A,v as o,w as V,j as Ft,u as _a,k as ar,$ as rr,x as sr}from"../chunks/BuRWgnCz.js";import{i as m}from"../chunks/BDpRITyb.js";import{e as Ze,s as re,a as Ge,h as or,r as xa,i as nr}from"../chunks/Cwb6d3g_.js";import{c as Ia}from"../chunks/DLuhTA05.js";import{a as ga}from"../chunks/BMFk7aZ6.js";import{g as ir,i as qt}from"../chunks/cM1ZMvyM.js";import{p as ha}from"../chunks/BSBcdyd3.js";import{B as q}from"../chunks/C5BN6RHR.js";import{H as Ot,T as ba,a as lr}from"../chunks/D9kzO4Vy.js";import{S as dr}from"../chunks/DtH7pDxF.js";import{s as Fa,r as Ta,p as Mt}from"../chunks/BAOiF0in.js";import{C as ka}from"../chunks/B0XeFYOk.js";import{K as ur,L as cr}from"../chunks/BxpN0jPH.js";import{C as Xe}from"../chunks/D-5zBf83.js";import{C as vr}from"../chunks/Dw18qh6I.js";import{C as wt}from"../chunks/cmRB1an4.js";import{C as mr}from"../chunks/ntd85-6_.js";import{E as pr}from"../chunks/IuxiJfHx.js";import{L as Aa}from"../chunks/CP7u-DWX.js";import{I as fr}from"../chunks/Deh9Yuoc.js";import{b as Jt}from"../chunks/BDtt0Y7t.js";import{l as _r}from"../chunks/DglJ92hi.js";import{S as xr}from"../chunks/BXN538J3.js";import{S as gr}from"../chunks/DGK4csRg.js";import{R as wa}from"../chunks/nW7-TN7t.js";import{I as Wa}from"../chunks/xH4qmLqM.js";var hr=new Set(["$$slots","$$events","$$legacy"]);function br(s,n){let C=Ta(n,hr);const u={name:"folder-git-2",size:24,node:[["path",{d:"M18 19a5 5 0 0 1-5-5v8"}],["path",{d:"M9 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v5"}],["circle",{cx:"13",cy:"12",r:"2"}],["circle",{cx:"20",cy:"19",r:"2"}]]};Wa(s,Fa(()=>C,{get icon(){return u}}))}var kr=new Set(["$$slots","$$events","$$legacy"]);function wr(s,n){let C=Ta(n,kr);const u={name:"folder-open",size:24,node:[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"}]]};Wa(s,Fa(()=>C,{get icon(){return u}}))}const ya="Fleetyard",yr=["claude","codex","pi"],$r={anthropic:"WHEELHOUSE_AGENT_ANTHROPIC_API_KEY",openai:"WHEELHOUSE_AGENT_OPENAI_API_KEY"},Pr=s=>s==="anthropic"||s==="openai",ut=(s,n,C,u,Z,de=!0)=>({agent:s,auth:n,provider:C,label:u,detail:Z,ready:de});function aa(s,n){const C=ut(s,"ours",null,`Paid by ${ya}`,`${ya} pays for the model; nothing to sign in to.`,!1),u=s==="claude"?[ut(s,"subscription","claude","My Claude subscription","Sign in to Claude Code with your Claude Pro or Max account."),ut(s,"apikey","anthropic","My Anthropic API key","Claude Code billed to an Anthropic API key.",!1)]:s==="codex"?[ut(s,"subscription","chatgpt","My ChatGPT subscription","Sign in to Codex with your ChatGPT Plus or Pro account."),ut(s,"apikey","openai","My OpenAI API key","Codex billed to an OpenAI API key.")]:[ut(s,"subscription","chatgpt","My ChatGPT subscription","Sign in to Pi with your ChatGPT Plus or Pro account."),ut(s,"subscription","claude","My Claude subscription","Pi with a Claude Pro or Max account.",!1),ut(s,"apikey","openai","My OpenAI API key","Pi billed to an OpenAI API key."),ut(s,"apikey","anthropic","My Anthropic API key","Pi billed to an Anthropic API key.")];return n?[...u,C]:u}const Cr=(s,n)=>s.agent===n.agent&&s.auth===n.auth&&s.provider===n.provider,Ht=(s,n)=>aa(s.agent,n).find(C=>Cr(C,s))??null,Sr=(s,n)=>Ht(s,n)?.ready===!0;function Ir(s){const n=aa(s,!1).find(C=>C.ready);return{agent:s,auth:n.auth,provider:n.provider}}const Xt=s=>Ot[s];function $a(s,n){const C=Ht(s,n);if(!C)return Xt(s.agent);const u=C.label.charAt(0).toLowerCase()+C.label.slice(1);return`${Xt(s.agent)}, ${s.auth==="ours"?u:`with ${u}`}`}var Fr=l('<button type="button" role="radio"><span class="block font-medium"> </span></button>'),Tr=l('<span class="shrink-0 rounded-full border px-2 py-0.5 text-xs text-muted-foreground">Coming soon</span>'),Ar=l('<li><button type="button" role="radio"><span aria-hidden="true"></span> <span class="min-w-0 flex-1"><span class="block font-medium"> </span> <span class="block text-xs text-muted-foreground"> </span></span> <!></button></li>'),Wr=l('<div class="grid gap-2 sm:grid-cols-3" role="radiogroup" aria-label="Agent"></div> <p class="mt-5 text-xs font-medium">Paid with</p> <ul class="mt-2 divide-y rounded-lg border bg-card" role="radiogroup" aria-label="Paid with"></ul>',1);function Er(s,n){ea(n,!0);let C=Mt(n,"cloud",3,!1),u=Mt(n,"disabled",3,!1);const Z=$(()=>aa(n.choice.agent,C())),de=R=>R!==n.choice.agent&&n.onchoose(Ir(R)),le=R=>R.auth===n.choice.auth&&R.provider===n.choice.provider;var Ee=Wr(),at=H(Ee);Ze(at,20,()=>yr,R=>R,(R,F)=>{var W=Fr(),se=d(W),$e=h(se,!0);i(W),p(je=>{re(W,"aria-checked",n.choice.agent===F),re(W,"data-agent",F),Ge(W,1,`rounded-lg border px-4 py-3 text-left text-sm disabled:cursor-not-allowed disabled:opacity-60 ${n.choice.agent===F?"border-sea ring-1 ring-sea":"hover:bg-muted/50"}`),W.disabled=u(),v($e,je)},[()=>Xt(F)]),_t("click",W,()=>de(F)),t(R,W)}),i(at);var ee=r(at,4);Ze(ee,21,()=>e(Z),R=>`${R.auth}/${R.provider}`,(R,F)=>{var W=Ar(),se=d(W),$e=d(se),je=r($e,2),He=d(je),vt=h(He,!0),mt=r(He,2),fe=h(mt,!0);i(je);var te=r(je,2);{var y=Re=>{var rt=Tr();t(Re,rt)};m(te,Re=>{e(F).ready||Re(y)})}i(se),i(W),p((Re,rt,st)=>{re(se,"aria-checked",Re),re(se,"aria-disabled",!e(F).ready),re(se,"data-auth",e(F).auth),re(se,"data-provider",e(F).provider??""),re(se,"data-ready",rt),Ge(se,1,`flex w-full items-start gap-3 px-4 py-3 text-left text-sm disabled:cursor-not-allowed ${e(F).ready?"hover:bg-muted/50":"opacity-60"}`),se.disabled=u()||!e(F).ready,Ge($e,1,`mt-0.5 size-3.5 shrink-0 rounded-full border ${st??""}`),v(vt,e(F).label),v(fe,e(F).detail)},[()=>le(e(F)),()=>String(e(F).ready),()=>le(e(F))?"border-sea bg-sea":""]),_t("click",se,()=>!le(e(F))&&n.onchoose(e(F))),t(R,W)}),i(ee),t(s,Ee),ta()}Zt(["click"]);var Rr=l("<p> </p>"),zr=l('<div class="rounded-md border border-sea/50 bg-background px-3 py-2 text-xs" role="group"><p> </p> <code class="mt-1 block font-mono break-all text-foreground"> </code> <div class="mt-2 flex gap-2"><!> <!></div></div>'),Or=l("<!>Installing…",1),Mr=l('<div class="mt-2"><!></div>'),Hr=l("<!>Copied",1),Nr=l("<!>Copy",1),Kr=l('<div class="mt-2"><p class="text-xs text-muted-foreground"> </p> <span class="mt-1 flex items-start gap-2 rounded-md border bg-muted/60 px-2.5 py-1.5 text-xs"><code class="min-w-0 flex-1 font-mono break-all text-foreground select-all"> </code> <button class="flex shrink-0 cursor-pointer items-center gap-1 text-muted-foreground hover:text-foreground"><!></button></span></div>'),Dr=l('<p class="mt-1.5 max-w-prose text-xs text-muted-foreground"> </p>'),Ur=l('<a class="mt-1.5 inline-flex items-center gap-1 text-xs text-sea hover:underline" target="_blank" rel="noreferrer"> <!></a>'),Lr=l("<!> <!> <!> <!>",1),Gr=l("<pre> </pre>"),jr=l('<li class="px-4 py-3"><div class="flex items-start gap-3"><!> <div class="min-w-0 flex-1"><p class="flex flex-wrap items-baseline gap-x-2 text-sm"><span class="font-mono font-medium"> </span> <span class="text-muted-foreground"> </span> <span class="sr-only"> </span></p> <!> <!> <!></div></div></li>');function Qt(s,n){ea(n,!0);let C=Mt(n,"busy",3,!1),u=Mt(n,"dryRun",3,!1),Z=X(!1),de=X(!1),le=X(null),Ee=X(null);const at={ok:{icon:vr,tone:"text-success",label:"Ready"},missing:{icon:Xe,tone:"text-danger",label:"Missing"},outdated:{icon:Xe,tone:"text-warning",label:"Outdated"},"needs-auth":{icon:ur,tone:"text-warning",label:"Sign in"},optional:{icon:ka,tone:"text-muted-foreground",label:"Optional"},unknown:{icon:ka,tone:"text-muted-foreground",label:"Unknown"}},ee=$(()=>at[n.item.status]);async function R(){if(!n.oninstall)return;o(Z,!1),o(de,!0),o(le,null);const J=await n.oninstall();o(de,!1),o(le,{ok:J.ok,text:(J.ok?J.output:J.error)??""},!0)}async function F(J){try{await navigator.clipboard.writeText(J),o(Ee,J,!0),setTimeout(()=>o(Ee,null),1500)}catch{}}var W=jr(),se=d(W),$e=d(se);Ia($e,()=>e(ee).icon,(J,he)=>{he(J,{get class(){return`mt-0.5 size-4 shrink-0 ${e(ee).tone??""}`},"aria-hidden":"true"})});var je=r($e,2),He=d(je),vt=d(He),mt=h(vt,!0),fe=r(vt,2),te=h(fe,!0),y=r(fe,2),Re=h(y,!0);i(He);var rt=r(He,2);{var st=J=>{var he=Rr(),et=h(he,!0);p(()=>{Ge(he,1,`mt-0.5 text-xs break-words ${(n.item.status==="ok"?"text-muted-foreground":e(ee).tone)??""}`),v(et,n.item.detail)}),t(J,he)};m(rt,J=>{n.item.detail&&J(st)})}var xt=r(rt,2);{var Ne=J=>{var he=Lr(),et=H(he);{var At=be=>{var ue=Mr(),_e=d(ue);{var Be=ke=>{var Pe=zr(),ot=d(Pe),nt=h(ot),it=r(ot,2),Ye=h(it,!0),lt=r(it,2),Ke=d(lt);q(Ke,{size:"sm",onclick:R,children:(Te,ht)=>{A();var pt=V("Run it");t(Te,pt)},$$slots:{default:!0}});var Ce=r(Ke,2);q(Ce,{size:"sm",variant:"ghost",onclick:()=>o(Z,!1),children:(Te,ht)=>{A();var pt=V("Cancel");t(Te,pt)},$$slots:{default:!0}}),i(lt),i(Pe),p(()=>{re(Pe,"aria-label",`Confirm installing ${n.item.tool??""}`),v(nt,`Wheelhouse will run${u()?" (dry run: it only says so)":""}:`),v(Ye,n.item.oneClick.command)}),t(ke,Pe)},Ve=ke=>{{let Pe=$(()=>C()||e(de));q(ke,{size:"sm",variant:"outline",get disabled(){return e(Pe)},onclick:()=>o(Z,!0),children:(ot,nt)=>{var it=Ft(),Ye=H(it);{var lt=Ce=>{var Te=Or(),ht=H(Te);Aa(ht,{class:"animate-spin"}),A(),t(Ce,Te)},Ke=Ce=>{var Te=V();p(()=>v(Te,`Install ${n.item.tool??""}…`)),t(Ce,Te)};m(Ye,Ce=>{e(de)?Ce(lt):Ce(Ke,-1)})}t(ot,it)},$$slots:{default:!0}})}};m(_e,ke=>{e(Z)?ke(Be):ke(Ve,-1)})}i(ue),t(be,ue)};m(et,be=>{n.item.oneClick&&be(At)})}var Wt=r(et,2);Ze(Wt,16,()=>n.item.terminal,be=>be,(be,ue)=>{var _e=Kr(),Be=d(_e),Ve=h(Be,!0),ke=r(Be,2),Pe=d(ke),ot=h(Pe,!0),nt=r(Pe,2),it=d(nt);{var Ye=Ke=>{var Ce=Hr(),Te=H(Ce);wt(Te,{class:"size-3.5"}),A(),t(Ke,Ce)},lt=Ke=>{var Ce=Nr(),Te=H(Ce);mr(Te,{class:"size-3.5"}),A(),t(Ke,Ce)};m(it,Ke=>{e(Ee)===ue?Ke(Ye):Ke(lt,-1)})}i(nt),i(ke),i(_e),p(()=>{v(Ve,n.item.oneClick?"Or run in your own terminal:":"Run in your own terminal:"),v(ot,ue),re(nt,"aria-label",`Copy ${ue??""}`)}),_t("click",nt,()=>F(ue)),t(be,_e)});var Et=r(Wt,2);{var yt=be=>{var ue=Dr(),_e=h(ue,!0);p(()=>v(_e,n.item.note)),t(be,ue)};m(Et,be=>{n.item.note&&be(yt)})}var gt=r(Et,2);{var Kt=be=>{var ue=Ur(),_e=d(ue),Be=r(_e);pr(Be,{class:"size-3"}),i(ue),p(()=>{re(ue,"href",n.item.link),v(_e,`How to install ${n.item.tool??""}`)}),t(be,ue)};m(gt,be=>{n.item.link&&be(Kt)})}t(J,he)};m(xt,J=>{n.item.status!=="ok"&&J(Ne)})}var Ie=r(xt,2);{var Fe=J=>{var he=Gr(),et=h(he,!0);p(()=>{Ge(he,1,`mt-2 max-h-48 overflow-auto rounded-md border px-2.5 py-1.5 font-mono text-[11px] whitespace-pre-wrap ${e(le).ok?"bg-muted/40 text-muted-foreground":"border-danger/40 bg-danger/5 text-danger"}`),v(et,e(le).text)}),t(J,he)};m(Ie,J=>{e(le)&&J(Fe)})}i(je),i(se),i(W),p(()=>{re(W,"data-tool",n.item.tool),re(W,"data-status",n.item.status),v(mt,n.item.tool),v(te,n.item.what),v(Re,e(ee).label)}),t(s,W),ta()}Zt(["click"]);async function We(s,n,C={}){try{const u=await fetch("/api/setup",{method:"POST",headers:{"content-type":"application/json",[xr]:s},body:JSON.stringify({action:n,...C})}),Z=await u.json().catch(()=>null);return u.ok&&Z?{ok:!0,value:Z}:{ok:!1,error:Z?.message??`Wheelhouse answered ${u.status}.`}}catch{return{ok:!1,error:"Wheelhouse did not answer."}}}const Se={view:async()=>{try{const s=await fetch("/api/setup");return s.ok?await s.json():null}catch{return null}},inspect:(s,n)=>We(s,"inspect",{dir:n}),clone:(s,n)=>We(s,"clone",{dir:n}),use:(s,n)=>We(s,"use",{dir:n}),sessionBackend:(s,n)=>We(s,"session-backend",{backend:n}),tools:s=>We(s,"tools"),install:(s,n)=>We(s,"install",{tool:n}),chooseAgent:(s,n)=>We(s,"agent-choose",{...n}),agent:s=>We(s,"agent"),agentInstall:s=>We(s,"agent-install"),agentTest:s=>We(s,"agent-test"),agentKey:(s,n,C=!1)=>We(s,"agent-key",{value:n,replace:C}),check:s=>We(s,"check"),plugins:s=>We(s,"plugins"),plugin:(s,n,C)=>We(s,"plugin",{id:n,on:C}),finish:s=>We(s,"finish")},Tt=["location","tools","claude","check","plugins","finish"],Pa={location:"Where Firstmate lives",tools:"Tools Firstmate needs",claude:"Claude Code",check:"Firstmate’s own checks",plugins:"Plugins",finish:"Start Firstmate"},Br=s=>typeof s=="string"&&Tt.includes(s),Vr={home:!1,tools:"unknown",claude:"unknown",check:"unknown",plugins:"unknown",tmux:!1};function Nt(s){const n=u=>s.home?u:"locked",C=(u,Z)=>u===Z?"done":u==="unknown"?"todo":"attention";return{location:s.home?"done":"todo",tools:n(C(s.tools,"ok")),claude:n(C(s.claude,"ok")),check:n(C(s.check,"ok")),plugins:n(s.plugins==="seen"?"done":"todo"),finish:Ea(s).ok?"todo":"locked"}}function Ea(s){if(!s.home)return{ok:!1,why:"Choose where Firstmate lives first."};if(s.backend==="herdr"){if(!s.herdr)return{ok:!1,why:"Install herdr, or update it, first: Wheelhouse runs Firstmate in it."}}else if(!s.tmux)return{ok:!1,why:"Install tmux first: Wheelhouse runs Firstmate in it."};if(s.claude!=="ok"){const n=Ot[s.harness??"claude"];return{ok:!1,why:s.claude==="missing"?`Install ${n} first.`:`Sign in to ${n} first, and test it.`}}return{ok:!0}}function Yr(s,n){const C=Nt(n),u=Tt.indexOf(s);return Tt.slice(u+1).find(Z=>C[Z]!=="locked")??s}function qr(s,n=!1){const C=Nt(s);return n&&C.claude!=="locked"&&C.claude!=="done"?"claude":Tt.find(u=>C[u]==="todo"||C[u]==="attention")??"finish"}function Jr(s){return!s||s.error?"unknown":s.items.some(n=>n.required&&n.status!=="ok")?"missing":"ok"}function Qr(s){return s?s.installed?s.signedIn===!0?"ok":s.signedIn===!1?"signed-out":"unknown":"missing":"unknown"}const Xr="/api/setup/terminal";var Zr=l('<span class="rounded-full border border-sea/50 bg-sea/10 px-2 py-0.5 text-xs text-sea" data-cloud-setup=""> </span>'),es=l('<span class="rounded-full border border-warning/50 bg-warning/10 px-2 py-0.5 text-xs text-warning" data-dry-run="">Dry run: installs only say what they would run</span>'),ts=l('<a class="ml-auto text-sm text-sea hover:underline" href="/">Back to Wheelhouse</a>'),as=l('<p class="mx-auto max-w-5xl px-4 pt-4 text-sm" role="status"> </p>'),rs=l('<li class="shrink-0"><button type="button"><span><!></span> <span class="whitespace-nowrap"> </span></button></li>'),ss=l(`<p class="mt-3 text-xs text-muted-foreground">To use a different one, start <code>wheelhouse open --firstmate &lt;dir&gt;</code>, or
2
+ run it outside a Firstmate checkout.</p>`),os=l('<p class="mt-2 max-w-prose text-sm text-muted-foreground">Wheelhouse is using the Firstmate at <code class="text-xs break-all text-foreground"> </code> </p> <div class="mt-6 flex flex-wrap gap-2"><!> <!></div> <!>',1),ns=l('<li><button type="button"> </button></li>'),is=l('<div class="mt-4"><p class="text-xs font-medium">Found on this computer</p> <ul class="mt-1 flex flex-wrap gap-2"></ul></div>'),Ca=l("<p> </p>"),ls=l('<ul class="mt-4 divide-y rounded-lg border bg-card"><!></ul>'),ds=l('<pre class="mt-3 max-h-40 overflow-auto rounded-md border bg-muted/40 px-2.5 py-1.5 font-mono text-[11px] whitespace-pre-wrap text-muted-foreground"> </pre>'),us=l('<p class="mt-2 max-w-prose text-sm text-muted-foreground"><!> Firstmate is a folder: its own scripts and skills, cloned from <a class="text-sea hover:underline" target="_blank" rel="noreferrer"> </a>, which also keeps its records. Wheelhouse remembers where it is, so <code>wheelhouse open</code> finds it from any folder.</p> <div class="mt-6 grid gap-2 sm:grid-cols-2" role="radiogroup" aria-label="How to get Firstmate"><button type="button" role="radio"><!> <span class="block font-medium">Clone Firstmate</span> <span class="block text-xs text-muted-foreground">Into a new or empty folder</span></button> <button type="button" role="radio"><!> <span class="block font-medium">Use one I already have</span> <span class="block text-xs text-muted-foreground">A Firstmate folder on this computer</span></button></div> <!> <label class="mt-4 grid gap-1"><span class="text-xs font-medium"> </span> <input class="h-9 rounded-md border border-input bg-background px-2.5 font-mono text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring" name="dir" autocomplete="off" spellcheck="false"/></label> <!> <!> <div class="mt-6 flex flex-wrap items-center gap-2"><!> <!></div> <!>',1),cs=l('<p class="mt-2 text-sm">Runs in <strong> </strong>, set by <code>--session-backend</code> or <code>WHEELHOUSE_SESSION_BACKEND</code>.</p>'),vs=l('<div class="mt-3 flex flex-wrap gap-2" role="group" aria-label="Session backend"></div>'),ms=l('<p class="mt-2 text-xs text-warning" data-session-warning=""><!> </p>'),ps=l('<p class="mt-2 text-xs text-danger"> </p>'),fs=l(`<div class="mt-4 rounded-lg border bg-card px-4 py-3"><p class="text-sm font-medium">Where Firstmate’s session runs</p> <p class="mt-1 max-w-prose text-xs text-muted-foreground">Wheelhouse runs Firstmate in its own tmux session, or, experimentally, in a herdr
3
+ session named <code> </code> </p> <!> <!> <!> <!></div>`),_s=l('<p class="mt-6 rounded-lg border border-danger/40 bg-danger/5 px-4 py-3 text-sm text-danger"> </p>'),xs=l('<span class="font-medium text-success">Everything Firstmate needs is here.</span>'),gs=l('<span class="font-medium"> </span> <span class="text-muted-foreground"> </span>',1),hs=l('<p class="mt-4 text-sm" data-tools-summary=""><!></p>'),bs=l('<li class="break-words"> </li>'),ks=l('<details class="mt-3 text-xs text-muted-foreground"><summary class="cursor-pointer"> </summary> <ul class="mt-1 list-disc pl-5"></ul></details>'),ws=l('<!> <ul class="mt-3 divide-y rounded-lg border bg-card"></ul> <!>',1),ys=l("<!>Check again",1),$s=l('<p class="mt-2 max-w-prose text-sm text-muted-foreground">What Firstmate needs, as its own check (<code>bin/fm-bootstrap.sh</code> </p> <!> <!> <div class="mt-6 flex flex-wrap gap-2"><!> <!></div>',1),Ps=l('<p class="mt-2 max-w-prose text-sm text-muted-foreground"> </p> <!>',1),Cs=l('<p class="mt-3 text-xs text-warning"><!> </p>'),Ss=l('<div class="mt-4 flex flex-wrap items-center gap-3 rounded-lg border bg-card px-4 py-3" data-agent-chosen=""><p class="min-w-0 flex-1 text-sm"><span class="font-medium"> </span></p> <!></div>'),Is=l('<div class="mt-4"><!></div>'),Fs=l('<p class="mt-2 text-xs text-muted-foreground"> </p>'),Ts=l("<!> <!>",1),As=l('<div class="mt-3"><!></div>'),Ws=l('<p class="mt-6 max-w-prose text-sm text-warning" data-coming-soon=""><!> </p> <!>',1),Es=l('<p class="mt-1 text-xs text-muted-foreground"> </p>'),Rs=l('<p class="flex items-center gap-2 text-sm font-medium text-success"><!> </p> <!>',1),zs=l('<p class="mb-3 max-w-prose text-sm text-warning"><!> </p>'),Os=l('<p class="mb-3 text-xs text-muted-foreground"> </p>'),Ms=l('<p class="text-sm text-warning" data-api-key-exists=""><!> </p> <div class="flex flex-wrap gap-2"><!> <!></div>',1),Hs=l('<div class="flex flex-wrap gap-2"><!> <!></div>'),Ns=l('<!> <!> <form class="grid max-w-md gap-2" data-api-key-form=""><label class="grid gap-1"><span class="text-xs font-medium"> </span> <input class="h-9 rounded-md border border-input bg-background px-2.5 font-mono text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring" type="password" name="api-key" autocomplete="off" spellcheck="false"/></label> <!></form> <p class="mt-2 max-w-prose text-xs text-muted-foreground">Wheelhouse keeps the key in the vault as <code> </code> </p>',1),Ks=l(`In Pi below, type <code>/login</code>, choose ChatGPT Plus/Pro (Codex) and
4
+ sign in. Then type <code>/quit</code> and Wheelhouse tests it; or test it now.`,1),Ds=l(`Sign in and accept the terms in Claude Code below. When it shows its prompt,
5
+ type <code>/exit</code> and Wheelhouse tests it; or test it now.`,1),Us=l('<p class="max-w-prose text-sm"><!></p> <div class="mt-3 flex h-[26rem] flex-col"><!></div> <div class="mt-3 flex flex-wrap gap-2"><!> <!></div>',1),Ls=l('<p class="max-w-prose text-sm text-warning"><!> </p>'),Gs=l('<!> <div class="mt-3 flex flex-wrap gap-2"><!> <!></div>',1),js=l('<p class="mt-2 text-xs text-muted-foreground"> <code> </code>, in a folder of Wheelhouse’s own.</p>'),Bs=l('<div class="mt-6"><!> <!></div>'),Vs=l('<ul class="mt-6 divide-y rounded-lg border bg-card"><!></ul> <!>',1),Ys=l('<p class="mt-2 max-w-prose text-sm text-muted-foreground"><!></p> <!> <!> <!>',1),qs=l('<!> <div class="mt-6 flex flex-wrap gap-2"><!></div>',1),Js=l('<p class="text-xs break-words text-muted-foreground"> </p>'),Qs=l('<li class="flex items-start gap-3 px-4 py-3 text-sm"><!> <div class="min-w-0"><p> </p> <!></div></li>'),Xs=l('<ul class="mt-6 divide-y rounded-lg border bg-card"></ul>'),Zs=l("<!>Run again",1),eo=l(`<p class="mt-2 max-w-prose text-sm text-muted-foreground">Firstmate’s own checks against its home (its bootstrap check and its readiness check), and
6
+ Wheelhouse’s: that it can read this Firstmate and run its session.</p> <!> <div class="mt-6 flex flex-wrap gap-2"><!> <!></div>`,1),Sa=l('<p class="text-xs text-muted-foreground"> </p>'),to=l('<li class="flex items-start gap-4 px-4 py-3"><div class="min-w-0 flex-1"><p class="text-sm font-medium"> </p> <!></div> <!></li>'),ao=l('<span class="flex items-center gap-1 text-xs text-success"><!>Installed</span>'),ro=l('<li class="flex flex-wrap items-start gap-4 px-4 py-3"><div class="min-w-0 flex-1"><p class="text-sm font-medium"> <span class="font-mono text-xs font-normal text-muted-foreground"> </span></p> <!></div> <!></li>'),so=l('<h2 class="mt-6 text-sm font-medium">Bundled with Wheelhouse</h2> <ul class="mt-2 divide-y rounded-lg border bg-card"></ul> <h2 class="mt-6 text-sm font-medium">To install</h2> <ul class="mt-2 divide-y rounded-lg border bg-card"></ul>',1),oo=l(`<p class="mt-2 max-w-prose text-sm text-muted-foreground">Plugins add pages, tabs and cards. The ones bundled with Wheelhouse turn on or off here
7
+ for every project (change it per project later in Settings → Plugins); the others install
8
+ from GitHub after you review what they are.</p> <!> <div class="mt-6 flex flex-wrap gap-2"><!></div>`,1),no=l('<p class="mt-2 flex items-center gap-2 text-sm font-medium text-success"><!>Firstmate is starting.</p> <p class="mt-1 max-w-prose text-sm text-muted-foreground"> </p> <div class="mt-3 flex h-[22rem] flex-col"><!></div>',1),io=l('<p class="mt-2 max-w-prose text-sm"> </p>'),lo=l('<!> <div class="mt-6"><!></div>',1),uo=l('<p class="mt-4 text-sm text-warning"><!> </p>'),co=l('<p class="mt-2 max-w-prose text-sm text-muted-foreground"> </p> <!> <div class="mt-6"><!></div>',1),vo=l('<p class="mt-4 flex items-center gap-2 text-sm text-muted-foreground" role="status"><!> </p>'),mo=l('<p class="mt-4 rounded-md border border-danger/40 bg-danger/5 px-3 py-2 text-sm text-danger" role="alert"> </p>'),po=l('<div class="min-h-dvh bg-background"><header class="border-b bg-header"><div class="mx-auto flex max-w-5xl flex-wrap items-center gap-3 px-4 py-3 sm:px-6"><!> <p class="font-display text-lg">Wheelhouse</p> <span class="text-sm text-muted-foreground">Set up Firstmate</span> <!> <!> <!></div></header> <!> <main class="mx-auto grid max-w-5xl gap-6 px-4 py-6 sm:px-6 md:grid-cols-[14rem_minmax(0,1fr)]"><nav aria-label="Setup steps"><ol class="no-scrollbar flex gap-1 overflow-x-auto md:flex-col"></ol></nav> <section class="surface min-w-0 px-5 py-6 sm:px-8" aria-labelledby="step-title"><h1 id="step-title" class="text-2xl"> </h1> <!> <!> <!></section></main></div>');function Lo(s,n){ea(n,!0);let C=X(null);const u=$(()=>e(C)??n.data.setup),Z=$(()=>e(u).agent??null),de=$(()=>e(Z)?.choice??null),le=$(()=>e(Z)?.cloud??null),Ee=$(()=>e(de)?.agent??e(u).tool?.harness??"claude"),at=$(()=>e(de)!==null||e(Ee)==="claude"),ee=$(()=>Ot[e(Ee)]);_a(()=>{n.data.setup,o(C,null)});const R=()=>ha.data.sessionToken;let F=X(null),W=X(null),se=X(null),$e=X(null),je=X(!1);const He=$(()=>({...Vr,home:e(u).install!==null,tools:Jr(e(F)),harness:e(Ee),claude:e(at)?Qr(e(W)):e(u).tool?.installed?"ok":"missing",check:e(se)?e(se).ok?"ok":"problems":"unknown",plugins:e(je)?"seen":"unknown",tmux:e(u).tmux,backend:e(u).session?.backend??"tmux",herdr:e(u).session?.herdr.ok??!1})),vt=$(()=>Nt(e(He))),mt=ha.url.searchParams.get("step");let fe=X("location");Yt(()=>{xt(Br(mt)&&Nt(e(He))[mt]!=="locked"?mt:qr(e(He),e(le)!==null))});let te=X(null),y=X(null);async function Re(){o(C,await Se.view()??e(C),!0)}function rt(a){e(vt)[a]!=="locked"&&xt(a)}const st=()=>rt(Yr(e(fe),e(He)));function xt(a){o(te,null),o(fe,a,!0);const c=e(u).install!==null;a==="tools"&&!e(F)&&c&&gt(),a==="claude"&&e(at)&&!e(W)&&ot(),a==="check"&&c&&ht(),a==="plugins"&&(o(je,!0),e($e)||ra())}let Ne=X("clone"),Ie=X(""),Fe=X(null),J=X(!1),he=X(null);Yt(()=>_r.onRestart(()=>{o($e,null),e(fe)==="plugins"&&ra()})),Yt(()=>{o(Ie,e(u).found[0]&&!e(u).install?e(u).found[0]:e(u).defaultDir,!0),e(u).found.length&&!e(u).install&&o(Ne,"existing")});let et=null;_a(()=>{const a=e(Ie);if(!a.trim()){o(Fe,null);return}et&&clearTimeout(et),et=setTimeout(async()=>{const c=await Se.inspect(R(),a);c.ok&&e(Ie)===a&&o(Fe,c.value,!0)},250)});async function At(a){a&&(o(y,"Restarting Wheelhouse to use it…"),await Jt()),await qt(),await Re(),o(F,null),o(se,null),o($e,null),o(J,!1),o(y,null),xt(e(le)?"claude":"tools")}async function Wt(){o(te,null),o(he,null),o(y,`Cloning Firstmate to ${e(Fe)?.dir??e(Ie)}…`);const a=await Se.clone(R(),e(Ie));if(!a.ok){o(y,null),o(te,a.error,!0);return}o(he,a.value.output,!0),await At(a.value.restarting)}async function Et(a=e(Ie)){o(te,null),o(y,`Using ${a}…`);const c=await Se.use(R(),a);if(!c.ok){o(y,null),o(te,c.error,!0);return}await At(c.value.restarting)}let yt=X(null);async function gt(){o(y,"Running Firstmate’s own check…");const a=await Se.tools(R());await Re(),o(y,null),a.ok?o(F,a.value,!0):o(te,a.error,!0)}async function Kt(a){o(te,null),o(y,"Saving…");const c=await Se.sessionBackend(R(),a);if(!c.ok){o(y,null),o(te,c.error,!0),await Re();return}c.value.restarting&&(o(y,`Restarting Wheelhouse to run Firstmate in ${c.value.session.backend}…`),await Jt(),await qt()),await Re(),o(y,null),o(F,null),o(se,null),gt()}async function be(a){o(yt,a,!0);const c=await Se.install(R(),a);return o(yt,null),c.ok&&!c.value.dryRun&&await gt(),c.ok?{ok:!0,output:c.value.output}:{ok:!1,error:c.error}}const ue=$(()=>e(F)?{missing:e(F).items.filter(a=>a.required&&a.status!=="ok").length,ready:e(F).items.filter(a=>a.status==="ok").length}:null);let _e=X(!1),Be=X(!1),Ve=X(""),ke=X(null),Pe=X(null);async function ot(){const a=await Se.agent(R());a.ok?o(W,a.value,!0):o(te,a.error,!0)}async function nt(a){o(te,null),o(y,"Saving…");const c=await Se.chooseAgent(R(),a);if(!c.ok){o(y,null),o(te,c.error,!0);return}c.value.restarting&&(o(y,`Restarting Wheelhouse to run Firstmate in ${Ot[a.agent]}…`),await Jt(),await qt()),await Re(),o(y,null),o(_e,!1),o(ke,null),o(Pe,null),o(Ve,""),o(W,null),o(se,null),ot()}async function it(){const a=await Se.agentInstall(R());return a.ok?(o(W,a.value.status,!0),{ok:!0,output:a.value.outcome.output}):{ok:!1,error:a.error}}async function Ye(){o(_e,!1),o(y,`Asking ${e(ee)} for one word…`);const a=await Se.agentTest(R());o(y,null),a.ok?o(W,a.value,!0):o(te,a.error,!0)}async function lt(a){o(te,null),o(ke,null),o(Pe,null),o(y,"Keeping the key in the vault…");const c=await Se.agentKey(R(),e(Ve),a);if(o(y,null),c.ok&&c.value.exists){o(Pe,c.value.message,!0);return}if(o(Ve,""),!c.ok){o(te,c.error,!0);return}o(ke,c.value.message,!0),await Ye()}function Ke(a){a.preventDefault(),lt(!1)}function Ce(){o(Pe,null),o(Ve,"")}function Te(a){a===lr.detached&&e(_e)&&Ye()}async function ht(){o(y,"Running the checks…");const a=await Se.check(R());o(y,null),a.ok?o(se,a.value,!0):o(te,a.error,!0)}let pt=X(null);async function ra(){const a=await Se.plugins(R());a.ok?o($e,a.value,!0):o(te,a.error,!0)}async function Ra(a,c){o(pt,a,!0);const U=await Se.plugin(R(),a,c);o(pt,null),U.ok?o($e,U.value,!0):o(te,U.error,!0)}let $t=X(null);const Dt=$(()=>Ea(e(He)));async function za(){o(te,null),o(y,"Starting Firstmate…");const a=await Se.finish(R());o(y,null),a.ok?o($t,a.value,!0):o(te,a.error,!0)}const Oa={done:wt,attention:Xe,locked:cr,todo:null},Ma={flag:"given with --firstmate",cwd:"the folder Wheelhouse ran in",remembered:"chosen in setup"};var Ut=po();or("g40i6i",a=>{ar(()=>{rr.title="Set up Firstmate · Wheelhouse"})});var Lt=d(Ut),sa=d(Lt),oa=d(sa);gr(oa,{class:"size-5 text-brass","aria-hidden":"true"});var na=r(oa,6);{var Ha=a=>{var c=Zr(),U=h(c);p(()=>v(U,`${e(le).product??""} setup`)),t(a,c)};m(na,a=>{e(le)&&a(Ha)})}var ia=r(na,2);{var Na=a=>{var c=es();t(a,c)};m(ia,a=>{e(u).dryRun&&a(Na)})}var Ka=r(ia,2);{var Da=a=>{var c=ts();t(a,c)};m(Ka,a=>{e(u).install&&a(Da)})}i(sa),i(Lt);var la=r(Lt,2);{var Ua=a=>{var c=as(),U=h(c,!0);p(()=>v(U,e(u).skillMessage)),t(a,c)};m(la,a=>{e(u).skillMessage&&a(Ua)})}var da=r(la,2),Gt=d(da),ua=d(Gt);Ze(ua,22,()=>Tt,a=>a,(a,c,U)=>{const ce=$(()=>e(vt)[c]),we=$(()=>Oa[e(ce)]);var Q=rs(),N=d(Q),S=d(N),E=d(S);{var L=g=>{var k=Ft(),z=H(k);Ia(z,()=>e(we),(G,K)=>{K(G,{class:"size-3.5","aria-hidden":"true"})}),t(g,k)},I=g=>{var k=V();p(()=>v(k,e(U)+1)),t(g,k)};m(E,g=>{e(we)?g(L):g(I,-1)})}i(S);var x=r(S,2),f=h(x,!0);i(N),i(Q),p(()=>{Ge(N,1,`flex w-full items-center gap-2.5 rounded-md px-2.5 py-2 text-left text-sm transition-colors disabled:cursor-not-allowed ${e(fe)===c?"bg-card font-medium shadow-sm ring-1 ring-border":"hover:bg-muted/60"} ${e(ce)==="locked"?"opacity-50":""}`),re(N,"aria-current",e(fe)===c?"step":void 0),N.disabled=e(ce)==="locked",re(N,"data-step",c),re(N,"data-state",e(ce)),Ge(S,1,`flex size-6 shrink-0 items-center justify-center rounded-full border text-xs ${e(ce)==="done"?"border-success bg-success text-white":e(ce)==="attention"?"border-warning text-warning":"text-muted-foreground"}`),v(f,c==="claude"?e(ee):Pa[c])}),_t("click",N,()=>rt(c)),t(a,Q)}),i(ua),i(Gt);var ca=r(Gt,2),va=d(ca),La=h(va,!0),ma=r(va,2);{var Ga=a=>{var c=Ft(),U=H(c);{var ce=Q=>{var N=os(),S=H(N),E=r(d(S)),L=h(E,!0),I=r(E);i(S);var x=r(S,2),f=d(x);q(f,{onclick:st,children:(K,oe)=>{A();var ae=V("Continue");t(K,ae)},$$slots:{default:!0}});var g=r(f,2);{var k=K=>{q(K,{variant:"outline",onclick:()=>o(J,!0),children:(oe,ae)=>{A();var O=V("Use a different Firstmate");t(oe,O)},$$slots:{default:!0}})};m(g,K=>{e(u).canChoose&&K(k)})}i(x);var z=r(x,2);{var G=K=>{var oe=ss();t(K,oe)};m(z,K=>{e(u).canChoose||K(G)})}p(()=>{v(L,e(u).install.firstmateDir),v(I,` (${Ma[e(u).install.source]??""}${e(u).install.homeDir!==e(u).install.firstmateDir?`; its home is ${e(u).install.homeDir}`:""}).`)}),t(Q,N)},we=Q=>{var N=us(),S=H(N),E=d(S);{var L=T=>{var b=V("Wheelhouse did not find Firstmate on this computer.");t(T,b)};m(E,T=>{e(u).problem&&!e(u).install&&T(L)})}var I=r(E,2),x=h(I,!0);A(3),i(S);var f=r(S,2),g=d(f),k=d(g);br(k,{class:"mb-1 size-4 text-sea","aria-hidden":"true"}),A(4),i(g);var z=r(g,2),G=d(z);wr(G,{class:"mb-1 size-4 text-sea","aria-hidden":"true"}),A(4),i(z),i(f);var K=r(f,2);{var oe=T=>{var b=is(),B=r(d(b),2);Ze(B,20,()=>e(u).found,ie=>ie,(ie,pe)=>{var Oe=ns(),De=d(Oe),dt=h(De,!0);i(Oe),p(()=>{Ge(De,1,`rounded-md border px-2.5 py-1 font-mono text-xs hover:bg-muted/60 ${e(Ie)===pe?"border-sea":""}`),v(dt,pe)}),_t("click",De,()=>o(Ie,pe,!0)),t(ie,Oe)}),i(B),i(b),t(T,b)};m(K,T=>{e(Ne)==="existing"&&e(u).found.length&&T(oe)})}var ae=r(K,2),O=d(ae),M=h(O,!0),Y=r(O,2);xa(Y),i(ae);var P=r(ae,2);{var j=T=>{var b=Ca(),B=h(b,!0);p(()=>{Ge(b,1,`mt-1.5 text-xs ${e(Fe).kind==="occupied"||e(Fe).kind==="invalid"?"text-danger":e(Fe).kind==="firstmate"?"text-success":"text-muted-foreground"}`),re(b,"data-location",e(Fe).kind),v(B,e(Fe).message)}),t(T,b)},ve=$(()=>e(Fe)&&e(Ie).trim());m(P,T=>{e(ve)&&T(j)})}var ze=r(P,2);{var xe=T=>{var b=ls(),B=d(b);Qt(B,{get item(){return e(u).git},get dryRun(){return e(u).dryRun}}),i(b),t(T,b)};m(ze,T=>{e(Ne)==="clone"&&e(u).git.status!=="ok"&&T(xe)})}var _=r(ze,2),w=d(_);{var D=T=>{{let b=$(()=>e(y)!==null);q(T,{get disabled(){return e(b)},onclick:()=>Et(e(Fe)?.dir),children:(B,ie)=>{A();var pe=V("Use this Firstmate");t(B,pe)},$$slots:{default:!0}})}},ne=T=>{{let b=$(()=>e(y)!==null||e(u).git.status!=="ok"||!(e(Fe)?.kind==="new"||e(Fe)?.kind==="empty"));q(T,{get disabled(){return e(b)},onclick:Wt,children:(B,ie)=>{A();var pe=V("Clone Firstmate here");t(B,pe)},$$slots:{default:!0}})}};m(w,T=>{e(Fe)?.kind==="firstmate"?T(D):e(Ne)==="clone"&&T(ne,1)})}var Le=r(w,2);{var qe=T=>{q(T,{variant:"ghost",onclick:()=>o(J,!1),children:(b,B)=>{A();var ie=V("Keep the current one");t(b,ie)},$$slots:{default:!0}})};m(Le,T=>{e(J)&&T(qe)})}i(_);var ft=r(_,2);{var Je=T=>{var b=ds(),B=h(b,!0);p(()=>v(B,e(he))),t(T,b)};m(ft,T=>{e(he)&&T(Je)})}p((T,b)=>{re(I,"href",T),v(x,b),re(g,"aria-checked",e(Ne)==="clone"),Ge(g,1,`rounded-lg border px-4 py-3 text-left text-sm ${e(Ne)==="clone"?"border-sea ring-1 ring-sea":"hover:bg-muted/50"}`),re(z,"aria-checked",e(Ne)==="existing"),Ge(z,1,`rounded-lg border px-4 py-3 text-left text-sm ${e(Ne)==="existing"?"border-sea ring-1 ring-sea":"hover:bg-muted/50"}`),v(M,e(Ne)==="clone"?"Clone it to":"Firstmate folder")},[()=>e(u).repository.replace(/\.git$/,""),()=>e(u).repository.replace(/^https:\/\//,"").replace(/\.git$/,"")]),_t("click",g,()=>{o(Ne,"clone"),o(Ie,e(u).defaultDir,!0)}),_t("click",z,()=>{o(Ne,"existing"),o(Ie,e(u).found[0]??"",!0)}),ga(Y,()=>e(Ie),T=>o(Ie,T)),t(Q,N)};m(U,Q=>{e(u).install&&!e(J)?Q(ce):Q(we,-1)})}t(a,c)},ja=a=>{var c=$s(),U=H(c),ce=r(d(U),2);i(U);var we=r(U,2);{var Q=x=>{const f=$(()=>e(u).session),g=$(()=>e(f).saved??"firstmate");var k=fs(),z=r(d(k),2),G=r(d(z)),K=h(G,!0),oe=r(G);i(z);var ae=r(z,2);{var O=_=>{var w=cs(),D=r(d(w)),ne=h(D,!0);A(5),i(w),p(()=>v(ne,e(f).backend)),t(_,w)},M=_=>{var w=vs();Ze(w,21,()=>[{value:"firstmate",label:`Same as Firstmate (${e(f).firstmate==="herdr"?"herdr":"tmux"})`},{value:"tmux",label:"tmux"},{value:"herdr",label:"herdr (experimental)"}],D=>D.value,(D,ne)=>{{let Le=$(()=>e(g)===e(ne).value?"default":"outline"),qe=$(()=>e(g)===e(ne).value),ft=$(()=>e(y)!==null);q(D,{size:"sm",get variant(){return e(Le)},get"aria-pressed"(){return e(qe)},get disabled(){return e(ft)},onclick:()=>e(g)!==e(ne).value&&Kt(e(ne).value==="firstmate"?null:e(ne).value),children:(Je,T)=>{A();var b=V();p(()=>v(b,e(ne).label)),t(Je,b)},$$slots:{default:!0}})}}),i(w),t(_,w)};m(ae,_=>{e(f).source==="env"?_(O):_(M,-1)})}var Y=r(ae,2);{var P=_=>{var w=Ca(),D=h(w,!0);p(()=>{Ge(w,1,`mt-2 text-xs ${e(f).herdr.ok?"text-muted-foreground":"text-warning"}`),v(D,e(f).herdr.ok?`herdr ${e(f).herdr.version} is installed.`:e(f).herdr.problem)}),t(_,w)};m(Y,_=>{e(f).backend==="herdr"&&_(P)})}var j=r(Y,2);{var ve=_=>{var w=ms(),D=d(w);Xe(D,{class:"mr-1 inline size-3.5"});var ne=r(D,1,!0);i(w),p(()=>v(ne,e(f).warning)),t(_,w)};m(j,_=>{e(f).warning&&_(ve)})}var ze=r(j,2);{var xe=_=>{var w=ps(),D=h(w,!0);p(()=>v(D,e(f).error)),t(_,w)};m(ze,_=>{e(f).error&&_(xe)})}i(k),p(()=>{re(k,"data-session-backend",e(f).backend),v(K,e(f).herdrSession),v(oe,` (herdr ${e(f).herdrMinVersion??""} or newer). It never
9
+ stops or restarts your herdr server or sessions.`)}),t(x,k)};m(we,x=>{e(u).session&&x(Q)})}var N=r(we,2);{var S=x=>{var f=Ft(),g=H(f);{var k=G=>{var K=_s(),oe=h(K,!0);p(()=>v(oe,e(F).error)),t(G,K)},z=G=>{var K=ws(),oe=H(K);{var ae=P=>{var j=hs(),ve=d(j);{var ze=_=>{var w=xs();t(_,w)},xe=_=>{var w=gs(),D=H(w),ne=h(D),Le=r(D,2),qe=h(Le);p(()=>{v(ne,`${e(ue).missing??""} still to install or fix`),v(qe,`· ${e(ue).ready??""} ready`)}),t(_,w)};m(ve,_=>{e(ue).missing===0?_(ze):_(xe,-1)})}i(j),t(P,j)};m(oe,P=>{e(ue)&&P(ae)})}var O=r(oe,2);Ze(O,21,()=>e(F).items,P=>P.tool,(P,j)=>{{let ve=$(()=>e(yt)!==null);Qt(P,{get item(){return e(j)},get dryRun(){return e(u).dryRun},get busy(){return e(ve)},oninstall:()=>be(e(j).tool)})}}),i(O);var M=r(O,2);{var Y=P=>{var j=ks(),ve=d(j),ze=h(ve),xe=r(ve,2);Ze(xe,21,()=>e(F).notes,nr,(_,w)=>{var D=bs(),ne=h(D,!0);p(()=>v(ne,e(w))),t(_,D)}),i(xe),i(j),p(()=>v(ze,`What else Firstmate’s check said (${e(F).notes.length??""})`)),t(P,j)};m(M,P=>{e(F).notes.length&&P(Y)})}t(G,K)};m(g,G=>{e(F).error?G(k):G(z,-1)})}t(x,f)};m(N,x=>{e(F)&&x(S)})}var E=r(N,2),L=d(E);q(L,{onclick:st,children:(x,f)=>{A();var g=V("Continue");t(x,g)},$$slots:{default:!0}});var I=r(L,2);{let x=$(()=>e(y)!==null);q(I,{variant:"outline",get disabled(){return e(x)},onclick:gt,children:(f,g)=>{var k=ys(),z=H(k);wa(z,{}),A(),t(f,k)},$$slots:{default:!0}})}i(E),p(()=>v(ce,`) reports it${e(F)?.backend?` for its ${e(F).backend} backend`:""}, on ${e(u).platform.label??""}. One-click installs use npm or Homebrew and show you the
10
+ command first; anything that needs sudo, a script or a sign-in is for your own terminal.`)),t(a,c)},Ba=a=>{var c=qs(),U=H(c);{var ce=S=>{var E=Ps(),L=H(E),I=h(L),x=r(L,2);q(x,{variant:"outline",onclick:Re,children:(f,g)=>{A();var k=V("Check again");t(f,k)},$$slots:{default:!0}}),p(()=>v(I,`You selected ${e(ee)??""}. ${e(u).tool?.installed?"It is installed.":"Install it and check again."} Sign in using the tool’s own terminal. Wheelhouse keeps
11
+ its permission settings and shows its conversation in chat.`)),t(S,E)},we=S=>{var E=Ys(),L=H(E),I=d(L);{var x=M=>{var Y=V();p(P=>v(Y,`Your ${e(le).product??""} machine was set up for ${P??""}. Sign
12
+ in below, yourself: Wheelhouse never answers for you and never keeps what you type
13
+ there.`),[()=>$a(e(le).answered,!0)]),t(M,Y)},f=M=>{var Y=V(`Wheelhouse runs Firstmate in the agent you choose here. Install it, then sign in and
14
+ accept its terms yourself, in its own screen below: Wheelhouse never answers for you
15
+ and never keeps what you type there.`);t(M,Y)};m(I,M=>{e(le)?M(x):M(f,-1)})}i(L);var g=r(L,2);{var k=M=>{var Y=Cs(),P=d(Y);Xe(P,{class:"mr-1 inline size-3.5"});var j=r(P,1,!0);i(Y),p(()=>v(j,e(Z).answersProblem)),t(M,Y)};m(g,M=>{e(Z)?.answersProblem&&M(k)})}var z=r(g,2);{var G=M=>{var Y=Ts(),P=H(Y);{var j=_=>{var w=Ss(),D=d(w),ne=d(D),Le=h(ne,!0);i(D);var qe=r(D,2);{var ft=Je=>{q(Je,{size:"sm",variant:"outline",onclick:()=>o(Be,!0),children:(T,b)=>{A();var B=V("Change");t(T,B)},$$slots:{default:!0}})};m(qe,Je=>{e(Z)?.fixed||Je(ft)})}i(w),p(Je=>v(Le,Je),[()=>$a(e(de),!0)]),t(_,w)},ve=_=>{var w=Is(),D=d(w);{let ne=$(()=>e(le)!==null),Le=$(()=>e(y)!==null||e(Z)?.fixed!=null);Er(D,{get choice(){return e(de)},get cloud(){return e(ne)},get disabled(){return e(Le)},onchoose:nt})}i(w),t(_,w)};m(P,_=>{e(le)&&!e(Be)?_(j):_(ve,-1)})}var ze=r(P,2);{var xe=_=>{var w=Fs(),D=h(w,!0);p(()=>v(D,e(Z).fixed)),t(_,w)};m(ze,_=>{e(Z)?.fixed&&_(xe)})}t(M,Y)};m(z,M=>{e(de)&&M(G)})}var K=r(z,2);{var oe=M=>{var Y=Ws(),P=H(Y),j=d(P);Xe(j,{class:"mr-1 inline size-4"});var ve=r(j);i(P);var ze=r(P,2);{var xe=_=>{var w=As(),D=d(w);q(D,{onclick:()=>o(Be,!0),children:(ne,Le)=>{A();var qe=V("Choose another way");t(ne,qe)},$$slots:{default:!0}}),i(w),t(_,w)};m(ze,_=>{e(le)&&!e(Be)&&_(xe)})}p(_=>v(ve,`${_??""} is coming soon. Choose another way to pay for ${e(ee)??""} for now.`),[()=>Ht(e(de),e(le)!==null)?.label??"That way to pay"]),t(M,Y)},ae=$(()=>e(de)&&!Sr(e(de),e(le)!==null)),O=M=>{var Y=Vs(),P=H(Y),j=d(P);{let xe=$(()=>e(y)!==null);Qt(j,{get item(){return e(W).install},get dryRun(){return e(u).dryRun},get busy(){return e(xe)},oninstall:it})}i(P);var ve=r(P,2);{var ze=xe=>{var _=Bs(),w=d(_);{var D=b=>{var B=Rs(),ie=H(B),pe=d(ie);wt(pe,{class:"size-4"});var Oe=r(pe);i(ie);var De=r(ie,2);{var dt=me=>{var Ae=Es(),Me=h(Ae,!0);p(()=>v(Me,e(ke))),t(me,Ae)};m(De,me=>{e(ke)&&me(dt)})}p(()=>v(Oe,`Signed in: ${e(ee)??""} answered.`)),t(b,B)},ne=b=>{const B=$(()=>$r[e(de).provider]);var ie=Ns(),pe=H(ie);{var Oe=ge=>{var Ue=zs(),Qe=d(Ue);Xe(Qe,{class:"mr-1 inline size-4"});var bt=r(Qe);i(Ue),p(()=>v(bt,`${e(ee)??""} did not answer: ${e(W).detail??""}`)),t(ge,Ue)};m(pe,ge=>{e(W).signedIn===!1&&ge(Oe)})}var De=r(pe,2);{var dt=ge=>{var Ue=Os(),Qe=h(Ue,!0);p(()=>v(Qe,e(ke))),t(ge,Ue)};m(De,ge=>{e(ke)&&ge(dt)})}var me=r(De,2),Ae=d(me),Me=d(Ae),ct=h(Me,!0),Pt=r(Me,2);xa(Pt),i(Ae);var ye=r(Ae,2);{var tt=ge=>{var Ue=Ms(),Qe=H(Ue),bt=d(Qe);Xe(bt,{class:"mr-1 inline size-4"});var St=r(bt,1,!0);i(Qe);var kt=r(Qe,2),zt=d(kt);{let jt=$(()=>e(y)!==null);q(zt,{type:"button",get disabled(){return e(jt)},onclick:()=>lt(!0),children:(Bt,tr)=>{A();var Vt=V("Replace it and sign in");t(Bt,Vt)},$$slots:{default:!0}})}var It=r(zt,2);{let jt=$(()=>e(y)!==null);q(It,{type:"button",variant:"outline",get disabled(){return e(jt)},onclick:Ce,children:(Bt,tr)=>{A();var Vt=V("Keep the one there");t(Bt,Vt)},$$slots:{default:!0}})}i(kt),p(()=>v(St,e(Pe))),t(ge,Ue)},Ct=ge=>{var Ue=Hs(),Qe=d(Ue);{let St=$(()=>e(y)!==null||!e(Ve).trim());q(Qe,{type:"submit",get disabled(){return e(St)},children:(kt,zt)=>{A();var It=V("Keep it in the vault and sign in");t(kt,It)},$$slots:{default:!0}})}var bt=r(Qe,2);{let St=$(()=>e(y)!==null);q(bt,{type:"button",variant:"outline",get disabled(){return e(St)},onclick:Ye,children:(kt,zt)=>{A();var It=V("Test it");t(kt,It)},$$slots:{default:!0}})}i(Ue),t(ge,Ue)};m(ye,ge=>{e(Pe)?ge(tt):ge(Ct,-1)})}i(me);var Rt=r(me,2),fa=r(d(Rt)),Za=h(fa,!0),er=r(fa);i(Rt),p(ge=>{v(ct,ge),re(Pt,"placeholder",e(B)),v(Za,e(B)),v(er,`, a name of the
16
+ agent’s own granted to no project, so no task gets it, and gives it to ${e(ee)??""}’s
17
+ own sign-in. It is never shown again; the Vault page shows only its name.`)},[()=>Ht(e(de),e(le)!==null)?.label]),sr("submit",me,Ke),ga(Pt,()=>e(Ve),ge=>o(Ve,ge)),t(b,ie)},Le=$(()=>e(de)?.auth==="apikey"&&Pr(e(de).provider)),qe=b=>{var B=Us(),ie=H(B),pe=d(ie);{var Oe=ye=>{var tt=V(`Sign in with your ChatGPT account using the link Codex shows below. When Codex
18
+ says you are signed in it exits, and Wheelhouse tests it; or test it now.`);t(ye,tt)},De=ye=>{var tt=Ks();A(4),t(ye,tt)},dt=ye=>{var tt=Ds();A(2),t(ye,tt)};m(pe,ye=>{e(Ee)==="codex"?ye(Oe):e(Ee)==="pi"?ye(De,1):ye(dt,-1)})}i(ie);var me=r(ie,2),Ae=d(me);{let ye=$(R);ba(Ae,{get token(){return e(ye)},get path(){return Xr},get label(){return`${e(ee)??""}, for signing in`},get connecting(){return`Starting ${e(ee)??""}…`},get detached(){return`${e(ee)??""} exited.`},onclosed:Te})}i(me);var Me=r(me,2),ct=d(Me);{let ye=$(()=>e(y)!==null);q(ct,{get disabled(){return e(ye)},onclick:Ye,children:(tt,Ct)=>{A();var Rt=V("I’m signed in: test it");t(tt,Rt)},$$slots:{default:!0}})}var Pt=r(ct,2);q(Pt,{variant:"ghost",onclick:()=>o(_e,!1),children:(ye,tt)=>{A();var Ct=V();p(()=>v(Ct,`Close ${e(ee)??""}`)),t(ye,Ct)},$$slots:{default:!0}}),i(Me),t(b,B)},ft=b=>{var B=Gs(),ie=H(B);{var pe=me=>{var Ae=Ls(),Me=d(Ae);Xe(Me,{class:"mr-1 inline size-4"});var ct=r(Me);i(Ae),p(()=>v(ct,`${e(ee)??""} did not answer: ${e(W).detail??""}`)),t(me,Ae)};m(ie,me=>{e(W).signedIn===!1&&me(pe)})}var Oe=r(ie,2),De=d(Oe);q(De,{onclick:()=>o(_e,!0),children:(me,Ae)=>{A();var Me=V();p(()=>v(Me,`Sign in to ${e(ee)??""}`)),t(me,Me)},$$slots:{default:!0}});var dt=r(De,2);{let me=$(()=>e(y)!==null);q(dt,{variant:"outline",get disabled(){return e(me)},onclick:Ye,children:(Ae,Me)=>{A();var ct=V("Test it");t(Ae,ct)},$$slots:{default:!0}})}i(Oe),t(b,B)};m(w,b=>{e(W).signedIn===!0?b(D):e(Le)?b(ne,1):e(_e)?b(qe,2):b(ft,-1)})}var Je=r(w,2);{var T=b=>{var B=js(),ie=d(B),pe=r(ie),Oe=h(pe,!0);A(),i(B),p(()=>{v(ie,`The test asks ${e(ee)??""} for one word, with `),v(Oe,e(Ee)==="codex"?"codex exec":e(Ee)==="pi"?"pi -p":"claude -p")}),t(b,B)};m(Je,b=>{e(W).signedIn!==!0&&!e(_e)&&b(T)})}i(_),p(b=>re(_,"data-claude-signed-in",b),[()=>String(e(W).signedIn)]),t(xe,_)};m(ve,xe=>{e(W).installed&&xe(ze)})}t(M,Y)};m(K,M=>{e(ae)?M(oe):e(W)&&M(O,1)})}t(S,E)};m(U,S=>{e(at)?S(we,-1):S(ce)})}var Q=r(U,2),N=d(Q);{let S=$(()=>!e(He).home);q(N,{onclick:st,get disabled(){return e(S)},children:(E,L)=>{A();var I=V("Continue");t(E,I)},$$slots:{default:!0}})}i(Q),t(a,c)},Va=a=>{var c=eo(),U=r(H(c),2);{var ce=S=>{var E=Xs();Ze(E,21,()=>e(se).lines,L=>L.label,(L,I)=>{var x=Qs(),f=d(x);{var g=O=>{wt(O,{class:"mt-0.5 size-4 shrink-0 text-success"})},k=O=>{Xe(O,{class:"mt-0.5 size-4 shrink-0 text-warning"})};m(f,O=>{e(I).ok?O(g):O(k,-1)})}var z=r(f,2),G=d(z),K=h(G,!0),oe=r(G,2);{var ae=O=>{var M=Js(),Y=h(M,!0);p(()=>v(Y,e(I).detail)),t(O,M)};m(oe,O=>{e(I).detail&&O(ae)})}i(z),i(x),p(O=>{re(x,"data-ok",O),v(K,e(I).label)},[()=>String(e(I).ok)]),t(L,x)}),i(E),t(S,E)};m(U,S=>{e(se)&&S(ce)})}var we=r(U,2),Q=d(we);q(Q,{onclick:st,children:(S,E)=>{A();var L=V("Continue");t(S,L)},$$slots:{default:!0}});var N=r(Q,2);{let S=$(()=>e(y)!==null);q(N,{variant:"outline",get disabled(){return e(S)},onclick:ht,children:(E,L)=>{var I=Zs(),x=H(I);wa(x,{}),A(),t(E,I)},$$slots:{default:!0}})}i(we),t(a,c)},Ya=a=>{var c=oo(),U=r(H(c),2);{var ce=N=>{var S=so(),E=r(H(S),2);Ze(E,21,()=>e($e).filter(I=>I.source==="bundled"),I=>I.id,(I,x)=>{var f=to(),g=d(f),k=d(g),z=h(k,!0),G=r(k,2);{var K=ae=>{var O=Sa(),M=h(O,!0);p(()=>v(M,e(x).description)),t(ae,O)};m(G,ae=>{e(x).description&&ae(K)})}i(g);var oe=r(g,2);{let ae=$(()=>e(pt)!==null);dr(oe,{get checked(){return e(x).on},get label(){return`${e(x).name??""} for every project`},get disabled(){return e(ae)},onchange:O=>Ra(e(x).id,O)})}i(f),p(()=>{re(f,"data-plugin",e(x).id),v(z,e(x).name)}),t(I,f)}),i(E);var L=r(E,4);Ze(L,21,()=>e($e).filter(I=>I.source==="installable"),I=>I.id,(I,x)=>{var f=ro(),g=d(f),k=d(g),z=d(k),G=r(z),K=h(G,!0);i(k);var oe=r(k,2);{var ae=P=>{var j=Sa(),ve=h(j,!0);p(()=>v(ve,e(x).description)),t(P,j)};m(oe,P=>{e(x).description&&P(ae)})}i(g);var O=r(g,2);{var M=P=>{var j=ao(),ve=d(j);wt(ve,{class:"size-3.5"}),A(),i(j),t(P,j)},Y=P=>{fr(P,{get suggested(){return e(x).repository},label:"Review and install"})};m(O,P=>{e(x).on?P(M):P(Y,-1)})}i(f),p(()=>{re(f,"data-plugin",e(x).id),v(z,`${e(x).name??""} `),v(K,e(x).repository)}),t(I,f)}),i(L),t(N,S)};m(U,N=>{e($e)&&N(ce)})}var we=r(U,2),Q=d(we);q(Q,{onclick:st,children:(N,S)=>{A();var E=V("Continue");t(N,E)},$$slots:{default:!0}}),i(we),t(a,c)},qa=a=>{var c=Ft(),U=H(c);{var ce=Q=>{var N=lo(),S=H(N);{var E=f=>{var g=no(),k=H(g),z=d(k);wt(z,{class:"size-4"}),A(),i(k);var G=r(k,2),K=h(G),oe=r(G,2),ae=d(oe);{let O=$(R);ba(ae,{get token(){return e(O)},label:"Firstmate’s terminal"})}i(oe),p(()=>v(K,`If ${e(ee)??""} asks you something first (trusting the Firstmate folder, or accepting its
19
+ permissions mode), answer it here. Then go to the chat.`)),t(f,g)},L=f=>{var g=io(),k=h(g,!0);p(()=>v(k,e($t).reason??"Firstmate is already running in another session; Wheelhouse shows it.")),t(f,g)};m(S,f=>{e($t).state==="ours"||e($t).state==="starting"?f(E):f(L,-1)})}var I=r(S,2),x=d(I);q(x,{onclick:()=>ir("/"),children:(f,g)=>{A();var k=V("Open the Firstmate chat");t(f,k)},$$slots:{default:!0}}),i(I),t(Q,N)},we=Q=>{var N=co(),S=H(N),E=h(S),L=r(S,2);{var I=g=>{var k=uo(),z=d(k);Xe(z,{class:"mr-1 inline size-4"});var G=r(z,1,!0);i(k),p(()=>v(G,e(Dt).why)),t(g,k)};m(L,g=>{e(Dt).ok||g(I)})}var x=r(L,2),f=d(x);{let g=$(()=>!e(Dt).ok||e(y)!==null);q(f,{get disabled(){return e(g)},onclick:za,children:(k,z)=>{A();var G=V("Start Firstmate");t(k,G)},$$slots:{default:!0}})}i(x),p(()=>v(E,`Wheelhouse starts Firstmate in ${e(ee)??""}, in its own ${e(u).session?.backend==="herdr"?`herdr session (${e(u).session.herdrSession})`:"tmux session"} (never a second one if Firstmate is already running), and opens its chat.
20
+ You can run this wizard again from Settings → Setup.`)),t(Q,N)};m(U,Q=>{e($t)?Q(ce):Q(we,-1)})}t(a,c)};m(ma,a=>{e(fe)==="location"?a(Ga):e(fe)==="tools"?a(ja,1):e(fe)==="claude"?a(Ba,2):e(fe)==="check"?a(Va,3):e(fe)==="plugins"?a(Ya,4):e(fe)==="finish"&&a(qa,5)})}var pa=r(ma,2);{var Ja=a=>{var c=vo(),U=d(c);Aa(U,{class:"size-4 animate-spin"});var ce=r(U,1,!0);i(c),p(()=>v(ce,e(y))),t(a,c)};m(pa,a=>{e(y)&&a(Ja)})}var Qa=r(pa,2);{var Xa=a=>{var c=mo(),U=h(c,!0);p(()=>v(U,e(te))),t(a,c)};m(Qa,a=>{e(te)&&a(Xa)})}i(ca),i(da),i(Ut),p(()=>v(La,e(fe)==="claude"?e(ee):Pa[e(fe)])),t(s,Ut),ta()}Zt(["click"]);export{Lo as component};