@ashlr/hub 3.11.5 → 3.13.0

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 (408) hide show
  1. package/CHANGELOG.md +153 -0
  2. package/README.md +29 -16
  3. package/dist/authority-surface.json +91 -45
  4. package/dist/build-identity.json +2 -2
  5. package/dist/cli/authority.d.ts +145 -33
  6. package/dist/cli/authority.js +1196 -313
  7. package/dist/cli/authority.js.map +1 -1
  8. package/dist/cli/cloud.js +12 -3
  9. package/dist/cli/cloud.js.map +1 -1
  10. package/dist/core/authority/protected-paths.js +11 -0
  11. package/dist/core/authority/protected-paths.js.map +1 -1
  12. package/dist/core/authority/resident.d.ts +101 -0
  13. package/dist/core/authority/resident.js +246 -0
  14. package/dist/core/authority/resident.js.map +1 -0
  15. package/dist/core/authority/trust-roots.js +7 -1
  16. package/dist/core/authority/trust-roots.js.map +1 -1
  17. package/dist/core/authority/types.d.ts +43 -0
  18. package/dist/core/authority/types.js +6 -0
  19. package/dist/core/authority/types.js.map +1 -1
  20. package/dist/core/cloud/budget.js +11 -1
  21. package/dist/core/cloud/budget.js.map +1 -1
  22. package/dist/core/cloud/cloud-api.d.ts +25 -2
  23. package/dist/core/cloud/cloud-api.js +139 -5
  24. package/dist/core/cloud/cloud-api.js.map +1 -1
  25. package/dist/core/cloud/pr-actions.d.ts +93 -0
  26. package/dist/core/cloud/pr-actions.js +436 -0
  27. package/dist/core/cloud/pr-actions.js.map +1 -0
  28. package/dist/core/cloud/pr-preview.d.ts +128 -0
  29. package/dist/core/cloud/pr-preview.js +228 -0
  30. package/dist/core/cloud/pr-preview.js.map +1 -0
  31. package/dist/core/cloud/store.d.ts +2 -0
  32. package/dist/core/cloud/store.js +28 -0
  33. package/dist/core/cloud/store.js.map +1 -1
  34. package/dist/core/cloud/timeline-api.d.ts +24 -0
  35. package/dist/core/cloud/timeline-api.js +46 -0
  36. package/dist/core/cloud/timeline-api.js.map +1 -0
  37. package/dist/core/cloud/timeline-types.d.ts +62 -0
  38. package/dist/core/cloud/timeline-types.js +36 -0
  39. package/dist/core/cloud/timeline-types.js.map +1 -0
  40. package/dist/core/cloud/timeline.d.ts +102 -0
  41. package/dist/core/cloud/timeline.js +919 -0
  42. package/dist/core/cloud/timeline.js.map +1 -0
  43. package/dist/core/cloud/tracker.js +67 -0
  44. package/dist/core/cloud/tracker.js.map +1 -1
  45. package/dist/core/cloud/types.d.ts +38 -0
  46. package/dist/core/cloud/types.js +1 -1
  47. package/dist/core/cloud/types.js.map +1 -1
  48. package/dist/core/daemon/service-install-authority.d.ts +10 -2
  49. package/dist/core/daemon/service-install-authority.js +14 -5
  50. package/dist/core/daemon/service-install-authority.js.map +1 -1
  51. package/dist/core/daemon/service.d.ts +15 -0
  52. package/dist/core/daemon/service.js +26 -0
  53. package/dist/core/daemon/service.js.map +1 -1
  54. package/dist/core/fleet/cloud-intake.d.ts +95 -0
  55. package/dist/core/fleet/cloud-intake.js +557 -0
  56. package/dist/core/fleet/cloud-intake.js.map +1 -0
  57. package/dist/core/fleet/dispatch-router.d.ts +13 -0
  58. package/dist/core/fleet/dispatch-router.js +32 -8
  59. package/dist/core/fleet/dispatch-router.js.map +1 -1
  60. package/dist/core/fleet/fleet-merge-state.d.ts +10 -0
  61. package/dist/core/fleet/fleet-merge-state.js.map +1 -1
  62. package/dist/core/fleet/host-merge.d.ts +5 -0
  63. package/dist/core/fleet/host-merge.js +11 -0
  64. package/dist/core/fleet/host-merge.js.map +1 -1
  65. package/dist/core/fleet/merge-gates.d.ts +8 -0
  66. package/dist/core/fleet/merge-gates.js +25 -5
  67. package/dist/core/fleet/merge-gates.js.map +1 -1
  68. package/dist/core/fleet/standing-merge-pass.js +30 -0
  69. package/dist/core/fleet/standing-merge-pass.js.map +1 -1
  70. package/dist/core/fleet/tick-hooks-live.d.ts +9 -0
  71. package/dist/core/fleet/tick-hooks-live.js +44 -5
  72. package/dist/core/fleet/tick-hooks-live.js.map +1 -1
  73. package/dist/core/fleet/verify-check-run.d.ts +90 -0
  74. package/dist/core/fleet/verify-check-run.js +274 -0
  75. package/dist/core/fleet/verify-check-run.js.map +1 -0
  76. package/dist/core/routing/budget-api.d.ts +11 -0
  77. package/dist/core/routing/budget-api.js +64 -8
  78. package/dist/core/routing/budget-api.js.map +1 -1
  79. package/dist/core/routing/budget-store.d.ts +22 -1
  80. package/dist/core/routing/budget-store.js +22 -8
  81. package/dist/core/routing/budget-store.js.map +1 -1
  82. package/dist/core/universe/builtins/preparation/manifest.json +1 -1
  83. package/dist/core/universe/builtins/preparation/preparation-bridge.mjs +8 -2
  84. package/dist/core/universe/builtins/preparation/preparation-verification-fixtures.mjs +7 -1
  85. package/dist/core/verse/account-health.js +9 -3
  86. package/dist/core/verse/account-health.js.map +1 -1
  87. package/dist/core/verse/activity-api.d.ts +5 -1
  88. package/dist/core/verse/activity-api.js +62 -14
  89. package/dist/core/verse/activity-api.js.map +1 -1
  90. package/dist/core/verse/authority-api.d.ts +9 -1
  91. package/dist/core/verse/authority-api.js +82 -2
  92. package/dist/core/verse/authority-api.js.map +1 -1
  93. package/dist/core/verse/seat-readiness.d.ts +25 -0
  94. package/dist/core/verse/seat-readiness.js +43 -6
  95. package/dist/core/verse/seat-readiness.js.map +1 -1
  96. package/dist/core/verse/verse-api.d.ts +3 -1
  97. package/dist/core/verse/verse-api.js +6 -0
  98. package/dist/core/verse/verse-api.js.map +1 -1
  99. package/dist/core/web/public/next/assets/{ActionMenu-DffwPklw.js → ActionMenu-Dwjk6rUQ.js} +2 -2
  100. package/dist/core/web/public/next/assets/{ActionMenu-DffwPklw.js.map → ActionMenu-Dwjk6rUQ.js.map} +1 -1
  101. package/dist/core/web/public/next/assets/Advanced-cVYTAsfB.js +2 -0
  102. package/dist/core/web/public/next/assets/{Advanced-CxzE6ekM.js.map → Advanced-cVYTAsfB.js.map} +1 -1
  103. package/dist/core/web/public/next/assets/App-IsaWDsdF.js +7 -0
  104. package/dist/core/web/public/next/assets/{App-DFlp-vdv.js.map → App-IsaWDsdF.js.map} +1 -1
  105. package/dist/core/web/public/next/assets/AppsSection-DDqeSrty.js +2 -0
  106. package/dist/core/web/public/next/assets/{AppsSection-Ct2O605-.js.map → AppsSection-DDqeSrty.js.map} +1 -1
  107. package/dist/core/web/public/next/assets/{AreaTrend-o-GLl2Is.js → AreaTrend-C32rUaxm.js} +2 -2
  108. package/dist/core/web/public/next/assets/{AreaTrend-o-GLl2Is.js.map → AreaTrend-C32rUaxm.js.map} +1 -1
  109. package/dist/core/web/public/next/assets/AutonomyOffState-CmSSTHVe.css +1 -0
  110. package/dist/core/web/public/next/assets/AutonomyOffState-CpFYS3tQ.js +3 -0
  111. package/dist/core/web/public/next/assets/AutonomyOffState-CpFYS3tQ.js.map +1 -0
  112. package/dist/core/web/public/next/assets/AutonomySection-Dwn8UtOy.js +2 -0
  113. package/dist/core/web/public/next/assets/{AutonomySection-BTg7yVa1.js.map → AutonomySection-Dwn8UtOy.js.map} +1 -1
  114. package/dist/core/web/public/next/assets/{BranchBar-BjPFtGsj.js → BranchBar-ISZ7xUCj.js} +2 -2
  115. package/dist/core/web/public/next/assets/{BranchBar-BjPFtGsj.js.map → BranchBar-ISZ7xUCj.js.map} +1 -1
  116. package/dist/core/web/public/next/assets/BudgetControl-BARVp-En.js +2 -0
  117. package/dist/core/web/public/next/assets/BudgetControl-BARVp-En.js.map +1 -0
  118. package/dist/core/web/public/next/assets/{Button-OjVJSrFq.js → Button-DtE0rlWD.js} +2 -2
  119. package/dist/core/web/public/next/assets/{Button-OjVJSrFq.js.map → Button-DtE0rlWD.js.map} +1 -1
  120. package/dist/core/web/public/next/assets/{CapacityStrip-Bx4c3dxD.js → CapacityStrip-DKbKA_Aa.js} +2 -2
  121. package/dist/core/web/public/next/assets/{CapacityStrip-Bx4c3dxD.js.map → CapacityStrip-DKbKA_Aa.js.map} +1 -1
  122. package/dist/core/web/public/next/assets/{ChartFrame-B_w2Siqg.js → ChartFrame-DK_BDXCt.js} +2 -2
  123. package/dist/core/web/public/next/assets/{ChartFrame-B_w2Siqg.js.map → ChartFrame-DK_BDXCt.js.map} +1 -1
  124. package/dist/core/web/public/next/assets/ChatSection-C9myY4ei.js +3 -0
  125. package/dist/core/web/public/next/assets/ChatSection-C9myY4ei.js.map +1 -0
  126. package/dist/core/web/public/next/assets/{CloudBudgetForm-5Gf4iAok.js → CloudBudgetForm-CvjK4Oh6.js} +2 -2
  127. package/dist/core/web/public/next/assets/{CloudBudgetForm-5Gf4iAok.js.map → CloudBudgetForm-CvjK4Oh6.js.map} +1 -1
  128. package/dist/core/web/public/next/assets/{CommandPalette-iTpk6I8r.js → CommandPalette-DzPsth0u.js} +2 -2
  129. package/dist/core/web/public/next/assets/{CommandPalette-iTpk6I8r.js.map → CommandPalette-DzPsth0u.js.map} +1 -1
  130. package/dist/core/web/public/next/assets/CommandSection-Brp73iox.js +3 -0
  131. package/dist/core/web/public/next/assets/CommandSection-Brp73iox.js.map +1 -0
  132. package/dist/core/web/public/next/assets/{ConfirmDialog-_S9iE-cJ.js → ConfirmDialog-CLUhzaBj.js} +2 -2
  133. package/dist/core/web/public/next/assets/{ConfirmDialog-_S9iE-cJ.js.map → ConfirmDialog-CLUhzaBj.js.map} +1 -1
  134. package/dist/core/web/public/next/assets/{DeleteChatDialog-KUYUygiA.js → DeleteChatDialog-C_eDhV8b.js} +2 -2
  135. package/dist/core/web/public/next/assets/{DeleteChatDialog-KUYUygiA.js.map → DeleteChatDialog-C_eDhV8b.js.map} +1 -1
  136. package/dist/core/web/public/next/assets/{Dialog-BuIaG6HF.js → Dialog-BRd_B9OE.js} +2 -2
  137. package/dist/core/web/public/next/assets/{Dialog-BuIaG6HF.js.map → Dialog-BRd_B9OE.js.map} +1 -1
  138. package/dist/core/web/public/next/assets/{DiffPane-De4IQt82.js → DiffPane-Cpr9soB2.js} +2 -2
  139. package/dist/core/web/public/next/assets/{DiffPane-De4IQt82.js.map → DiffPane-Cpr9soB2.js.map} +1 -1
  140. package/dist/core/web/public/next/assets/{DiffViewer-B75t6Ile.js → DiffViewer-CNwd0W3Q.js} +2 -2
  141. package/dist/core/web/public/next/assets/{DiffViewer-B75t6Ile.js.map → DiffViewer-CNwd0W3Q.js.map} +1 -1
  142. package/dist/core/web/public/next/assets/DockHost-BcEq2qaS.js +2 -0
  143. package/dist/core/web/public/next/assets/{DockHost-BPqyhtCP.js.map → DockHost-BcEq2qaS.js.map} +1 -1
  144. package/dist/core/web/public/next/assets/{EmptyState-DXkT4vhW.js → EmptyState-DsN1H6MC.js} +2 -2
  145. package/dist/core/web/public/next/assets/{EmptyState-DXkT4vhW.js.map → EmptyState-DsN1H6MC.js.map} +1 -1
  146. package/dist/core/web/public/next/assets/{Epistemic-CfqFe_aP.js → Epistemic-fycQTBRO.js} +2 -2
  147. package/dist/core/web/public/next/assets/{Epistemic-CfqFe_aP.js.map → Epistemic-fycQTBRO.js.map} +1 -1
  148. package/dist/core/web/public/next/assets/EvidenceTimeline-PBDAiSuG.css +1 -0
  149. package/dist/core/web/public/next/assets/EvidenceTimeline-sCCAdnBK.js +2 -0
  150. package/dist/core/web/public/next/assets/EvidenceTimeline-sCCAdnBK.js.map +1 -0
  151. package/dist/core/web/public/next/assets/{FleetSection-B7f-XBiX.js → FleetSection-BG8iGraG.js} +3 -3
  152. package/dist/core/web/public/next/assets/{FleetSection-B7f-XBiX.js.map → FleetSection-BG8iGraG.js.map} +1 -1
  153. package/dist/core/web/public/next/assets/{Funnel-pXYySwXQ.js → Funnel-B88_wpA4.js} +2 -2
  154. package/dist/core/web/public/next/assets/{Funnel-pXYySwXQ.js.map → Funnel-B88_wpA4.js.map} +1 -1
  155. package/dist/core/web/public/next/assets/{GearTray-gj6lT7ba.js → GearTray-CpDt0xwj.js} +2 -2
  156. package/dist/core/web/public/next/assets/{GearTray-gj6lT7ba.js.map → GearTray-CpDt0xwj.js.map} +1 -1
  157. package/dist/core/web/public/next/assets/{GrowthSection-D8e9m9Wy.js → GrowthSection-BvZezOsX.js} +2 -2
  158. package/dist/core/web/public/next/assets/{GrowthSection-D8e9m9Wy.js.map → GrowthSection-BvZezOsX.js.map} +1 -1
  159. package/dist/core/web/public/next/assets/{HandoffDialog-VfKxKhxF.js → HandoffDialog-B1G6gQyk.js} +2 -2
  160. package/dist/core/web/public/next/assets/{HandoffDialog-VfKxKhxF.js.map → HandoffDialog-B1G6gQyk.js.map} +1 -1
  161. package/dist/core/web/public/next/assets/{Input-u1YR_Ogl.js → Input-CI0yBHmn.js} +2 -2
  162. package/dist/core/web/public/next/assets/{Input-u1YR_Ogl.js.map → Input-CI0yBHmn.js.map} +1 -1
  163. package/dist/core/web/public/next/assets/{LeaderCard-BDELBrnx.js → LeaderCard-BxxiEg4e.js} +2 -2
  164. package/dist/core/web/public/next/assets/{LeaderCard-BDELBrnx.js.map → LeaderCard-BxxiEg4e.js.map} +1 -1
  165. package/dist/core/web/public/next/assets/{MatrixHeatmap-NKLF2srR.js → MatrixHeatmap-iPFEU2Tv.js} +2 -2
  166. package/dist/core/web/public/next/assets/{MatrixHeatmap-NKLF2srR.js.map → MatrixHeatmap-iPFEU2Tv.js.map} +1 -1
  167. package/dist/core/web/public/next/assets/McpSection-nuXer4K-.js +2 -0
  168. package/dist/core/web/public/next/assets/{McpSection-D1tDvlRa.js.map → McpSection-nuXer4K-.js.map} +1 -1
  169. package/dist/core/web/public/next/assets/{MessageMarkdown-DlfLEJxu.js → MessageMarkdown-BCe4TsXk.js} +3 -3
  170. package/dist/core/web/public/next/assets/{MessageMarkdown-DlfLEJxu.js.map → MessageMarkdown-BCe4TsXk.js.map} +1 -1
  171. package/dist/core/web/public/next/assets/{MessageMarkdownRenderer-BYZzI115.js → MessageMarkdownRenderer-DL3LU5kL.js} +2 -2
  172. package/dist/core/web/public/next/assets/{MessageMarkdownRenderer-BYZzI115.js.map → MessageMarkdownRenderer-DL3LU5kL.js.map} +1 -1
  173. package/dist/core/web/public/next/assets/{Meter-BSVhU43Q.js → Meter-b69LM0mU.js} +2 -2
  174. package/dist/core/web/public/next/assets/{Meter-BSVhU43Q.js.map → Meter-b69LM0mU.js.map} +1 -1
  175. package/dist/core/web/public/next/assets/{MindSection-lqV2e_Sq.js → MindSection-Dc5v5rH3.js} +2 -2
  176. package/dist/core/web/public/next/assets/{MindSection-lqV2e_Sq.js.map → MindSection-Dc5v5rH3.js.map} +1 -1
  177. package/dist/core/web/public/next/assets/{MutationTokenDialog-CLGP72g6.js → MutationTokenDialog-Bm34BNVV.js} +2 -2
  178. package/dist/core/web/public/next/assets/{MutationTokenDialog-CLGP72g6.js.map → MutationTokenDialog-Bm34BNVV.js.map} +1 -1
  179. package/dist/core/web/public/next/assets/NeedsYouDrawer-N1cWJjpz.js +3 -0
  180. package/dist/core/web/public/next/assets/NeedsYouDrawer-N1cWJjpz.js.map +1 -0
  181. package/dist/core/web/public/next/assets/NeedsYouList-CH6Mq-E_.css +1 -0
  182. package/dist/core/web/public/next/assets/NeedsYouList-D5Kk549g.js +2 -0
  183. package/dist/core/web/public/next/assets/{NeedsYouList-eBOlJr0b.js.map → NeedsYouList-D5Kk549g.js.map} +1 -1
  184. package/dist/core/web/public/next/assets/{NewChatDialog-DoYTH26M.js → NewChatDialog-BqFTWgHU.js} +2 -2
  185. package/dist/core/web/public/next/assets/{NewChatDialog-DoYTH26M.js.map → NewChatDialog-BqFTWgHU.js.map} +1 -1
  186. package/dist/core/web/public/next/assets/OnboardingFlow-DcDsguAM.js +3 -0
  187. package/dist/core/web/public/next/assets/OnboardingFlow-DcDsguAM.js.map +1 -0
  188. package/dist/core/web/public/next/assets/OnboardingGate-BZafM1Vf.js +3 -0
  189. package/dist/core/web/public/next/assets/{OnboardingGate-DrDEVBqw.js.map → OnboardingGate-BZafM1Vf.js.map} +1 -1
  190. package/dist/core/web/public/next/assets/{PreviewPane-ULN673zm.js → PreviewPane-zT3gK9TD.js} +2 -2
  191. package/dist/core/web/public/next/assets/{PreviewPane-ULN673zm.js.map → PreviewPane-zT3gK9TD.js.map} +1 -1
  192. package/dist/core/web/public/next/assets/{ProviderLogo-8WaUjTlN.js → ProviderLogo-AwHn2sKm.js} +2 -2
  193. package/dist/core/web/public/next/assets/{ProviderLogo-8WaUjTlN.js.map → ProviderLogo-AwHn2sKm.js.map} +1 -1
  194. package/dist/core/web/public/next/assets/{RailStatus-Ckw9nvYU.js → RailStatus-xHrovWvI.js} +2 -2
  195. package/dist/core/web/public/next/assets/{RailStatus-Ckw9nvYU.js.map → RailStatus-xHrovWvI.js.map} +1 -1
  196. package/dist/core/web/public/next/assets/{RefreshIndicator-DGubF4vR.js → RefreshIndicator-SEFZlMB2.js} +2 -2
  197. package/dist/core/web/public/next/assets/{RefreshIndicator-DGubF4vR.js.map → RefreshIndicator-SEFZlMB2.js.map} +1 -1
  198. package/dist/core/web/public/next/assets/{ResourcePoolConsoleApp-BahEaY4d.js → ResourcePoolConsoleApp-CAxPQ4sZ.js} +3 -3
  199. package/dist/core/web/public/next/assets/{ResourcePoolConsoleApp-BahEaY4d.js.map → ResourcePoolConsoleApp-CAxPQ4sZ.js.map} +1 -1
  200. package/dist/core/web/public/next/assets/ResourcesChrome-BnhnEdJe.js +3 -0
  201. package/dist/core/web/public/next/assets/{ResourcesChrome-C2ZrA7la.js.map → ResourcesChrome-BnhnEdJe.js.map} +1 -1
  202. package/dist/core/web/public/next/assets/{ResourcesDrawer-BC93fzwQ.js → ResourcesDrawer-BAFGodny.js} +2 -2
  203. package/dist/core/web/public/next/assets/{ResourcesDrawer-BC93fzwQ.js.map → ResourcesDrawer-BAFGodny.js.map} +1 -1
  204. package/dist/core/web/public/next/assets/{RouteErrorBoundary-BvhHNpE_.js → RouteErrorBoundary-C8WGiixc.js} +2 -2
  205. package/dist/core/web/public/next/assets/{RouteErrorBoundary-BvhHNpE_.js.map → RouteErrorBoundary-C8WGiixc.js.map} +1 -1
  206. package/dist/core/web/public/next/assets/{RunInCloudAction-Dywfnw0C.js → RunInCloudAction-1-IPLYhf.js} +2 -2
  207. package/dist/core/web/public/next/assets/{RunInCloudAction-Dywfnw0C.js.map → RunInCloudAction-1-IPLYhf.js.map} +1 -1
  208. package/dist/core/web/public/next/assets/{SeatSelector-CH7hTgwy.js → SeatSelector-DpwNiX8F.js} +2 -2
  209. package/dist/core/web/public/next/assets/{SeatSelector-CH7hTgwy.js.map → SeatSelector-DpwNiX8F.js.map} +1 -1
  210. package/dist/core/web/public/next/assets/{Segmented-Wynbg0F5.js → Segmented-Wt1ATod9.js} +2 -2
  211. package/dist/core/web/public/next/assets/{Segmented-Wynbg0F5.js.map → Segmented-Wt1ATod9.js.map} +1 -1
  212. package/dist/core/web/public/next/assets/{Select-DMyLCkId.js → Select-By-V9lMc.js} +2 -2
  213. package/dist/core/web/public/next/assets/{Select-DMyLCkId.js.map → Select-By-V9lMc.js.map} +1 -1
  214. package/dist/core/web/public/next/assets/{SessionGate-8RtQFWeZ.js → SessionGate-WROS02tK.js} +2 -2
  215. package/dist/core/web/public/next/assets/{SessionGate-8RtQFWeZ.js.map → SessionGate-WROS02tK.js.map} +1 -1
  216. package/dist/core/web/public/next/assets/{SessionInsightChip-zBJbKv2L.js → SessionInsightChip-DNUcruwp.js} +2 -2
  217. package/dist/core/web/public/next/assets/{SessionInsightChip-zBJbKv2L.js.map → SessionInsightChip-DNUcruwp.js.map} +1 -1
  218. package/dist/core/web/public/next/assets/{SessionSearch-DfJIcxxM.js → SessionSearch-UHtt7a8f.js} +2 -2
  219. package/dist/core/web/public/next/assets/{SessionSearch-DfJIcxxM.js.map → SessionSearch-UHtt7a8f.js.map} +1 -1
  220. package/dist/core/web/public/next/assets/{SettingsSection-Da9RYyH5.js → SettingsSection-Bf74l0Gj.js} +2 -2
  221. package/dist/core/web/public/next/assets/{SettingsSection-Da9RYyH5.js.map → SettingsSection-Bf74l0Gj.js.map} +1 -1
  222. package/dist/core/web/public/next/assets/SetupChecklist-BhZpFLsj.css +1 -0
  223. package/dist/core/web/public/next/assets/SetupChecklist-CzpEcfOl.js +2 -0
  224. package/dist/core/web/public/next/assets/SetupChecklist-CzpEcfOl.js.map +1 -0
  225. package/dist/core/web/public/next/assets/{Sheet-DhXyIDmq.js → Sheet-HkBOBMTT.js} +2 -2
  226. package/dist/core/web/public/next/assets/{Sheet-DhXyIDmq.js.map → Sheet-HkBOBMTT.js.map} +1 -1
  227. package/dist/core/web/public/next/assets/{ShortcutsOverlay-Bi5f-wUw.js → ShortcutsOverlay-DiigiT8H.js} +2 -2
  228. package/dist/core/web/public/next/assets/{ShortcutsOverlay-Bi5f-wUw.js.map → ShortcutsOverlay-DiigiT8H.js.map} +1 -1
  229. package/dist/core/web/public/next/assets/Sidebar-C9YtBYVZ.js +3 -0
  230. package/dist/core/web/public/next/assets/Sidebar-C9YtBYVZ.js.map +1 -0
  231. package/dist/core/web/public/next/assets/{Slider-Bd9YFWEV.js → Slider-DaEDws-b.js} +2 -2
  232. package/dist/core/web/public/next/assets/{Slider-Bd9YFWEV.js.map → Slider-DaEDws-b.js.map} +1 -1
  233. package/dist/core/web/public/next/assets/{StatTile-DScTd3c-.js → StatTile-CTX41O6y.js} +2 -2
  234. package/dist/core/web/public/next/assets/{StatTile-DScTd3c-.js.map → StatTile-CTX41O6y.js.map} +1 -1
  235. package/dist/core/web/public/next/assets/{StatusBadge-DQ1UtQAJ.js → StatusBadge-CXG3iNL4.js} +2 -2
  236. package/dist/core/web/public/next/assets/{StatusBadge-DQ1UtQAJ.js.map → StatusBadge-CXG3iNL4.js.map} +1 -1
  237. package/dist/core/web/public/next/assets/{StepBand-BB3IJxhr.js → StepBand-jJTqYIdX.js} +2 -2
  238. package/dist/core/web/public/next/assets/{StepBand-BB3IJxhr.js.map → StepBand-jJTqYIdX.js.map} +1 -1
  239. package/dist/core/web/public/next/assets/{Surface-DWMtQe3Q.js → Surface-5bNA08tK.js} +2 -2
  240. package/dist/core/web/public/next/assets/{Surface-DWMtQe3Q.js.map → Surface-5bNA08tK.js.map} +1 -1
  241. package/dist/core/web/public/next/assets/{Swimlane-DcENqtdp.js → Swimlane-LrslsGxw.js} +2 -2
  242. package/dist/core/web/public/next/assets/{Swimlane-DcENqtdp.js.map → Swimlane-LrslsGxw.js.map} +1 -1
  243. package/dist/core/web/public/next/assets/{Switch-CenChEYf.js → Switch-BmCzfFnu.js} +2 -2
  244. package/dist/core/web/public/next/assets/{Switch-CenChEYf.js.map → Switch-BmCzfFnu.js.map} +1 -1
  245. package/dist/core/web/public/next/assets/{Tag-D4k5E3u0.js → Tag-WSUIaMVy.js} +2 -2
  246. package/dist/core/web/public/next/assets/{Tag-D4k5E3u0.js.map → Tag-WSUIaMVy.js.map} +1 -1
  247. package/dist/core/web/public/next/assets/{TerminalPane-DCQTukcE.js → TerminalPane-BVFgYX6K.js} +5 -5
  248. package/dist/core/web/public/next/assets/{TerminalPane-DCQTukcE.js.map → TerminalPane-BVFgYX6K.js.map} +1 -1
  249. package/dist/core/web/public/next/assets/{UniverseConsoleApp-DsuWT0pi.js → UniverseConsoleApp-BpphLqoz.js} +2 -2
  250. package/dist/core/web/public/next/assets/{UniverseConsoleApp-DsuWT0pi.js.map → UniverseConsoleApp-BpphLqoz.js.map} +1 -1
  251. package/dist/core/web/public/next/assets/{UniverseView-DyI5ApsA.js → UniverseView-DbpbSMwO.js} +4 -4
  252. package/dist/core/web/public/next/assets/{UniverseView-DyI5ApsA.js.map → UniverseView-DbpbSMwO.js.map} +1 -1
  253. package/dist/core/web/public/next/assets/{UsageSection-Imr28nwK.js → UsageSection-CUlaKtws.js} +3 -3
  254. package/dist/core/web/public/next/assets/{UsageSection-Imr28nwK.js.map → UsageSection-CUlaKtws.js.map} +1 -1
  255. package/dist/core/web/public/next/assets/VerseConsoleApp-DXDv1aOi.js +3 -0
  256. package/dist/core/web/public/next/assets/VerseConsoleApp-DXDv1aOi.js.map +1 -0
  257. package/dist/core/web/public/next/assets/{Workspace-CpxBO98E.js → Workspace-RXy0pqp6.js} +5 -5
  258. package/dist/core/web/public/next/assets/{Workspace-CpxBO98E.js.map → Workspace-RXy0pqp6.js.map} +1 -1
  259. package/dist/core/web/public/next/assets/{actions-DE8NoWV_.js → actions-BZTidCXZ.js} +2 -2
  260. package/dist/core/web/public/next/assets/{actions-DE8NoWV_.js.map → actions-BZTidCXZ.js.map} +1 -1
  261. package/dist/core/web/public/next/assets/{apps-model-CFGCUu9p.js → apps-model-CHO133qt.js} +2 -2
  262. package/dist/core/web/public/next/assets/{apps-model-CFGCUu9p.js.map → apps-model-CHO133qt.js.map} +1 -1
  263. package/dist/core/web/public/next/assets/{authority-model-CmnfJzmM.js → authority-model-8NeAEwAF.js} +2 -2
  264. package/dist/core/web/public/next/assets/{authority-model-CmnfJzmM.js.map → authority-model-8NeAEwAF.js.map} +1 -1
  265. package/dist/core/web/public/next/assets/{budget-queries-DjrPRFwl.js → budget-queries-DFF-3ICg.js} +2 -2
  266. package/dist/core/web/public/next/assets/{budget-queries-DjrPRFwl.js.map → budget-queries-DFF-3ICg.js.map} +1 -1
  267. package/dist/core/web/public/next/assets/{capacity-strip-model-C7cdQnuK.js → capacity-strip-model-5ViUgUlP.js} +2 -2
  268. package/dist/core/web/public/next/assets/{capacity-strip-model-C7cdQnuK.js.map → capacity-strip-model-5ViUgUlP.js.map} +1 -1
  269. package/dist/core/web/public/next/assets/{charts-DUD_jprE.js → charts-CzxWrZn7.js} +2 -2
  270. package/dist/core/web/public/next/assets/{charts-DUD_jprE.js.map → charts-CzxWrZn7.js.map} +1 -1
  271. package/dist/core/web/public/next/assets/cloud-model-CfRydq8N.js +2 -0
  272. package/dist/core/web/public/next/assets/{cloud-model-DoxBMDvx.js.map → cloud-model-CfRydq8N.js.map} +1 -1
  273. package/dist/core/web/public/next/assets/{cloud-queries-CTGvO-k-.js → cloud-queries-DmptbjS8.js} +2 -2
  274. package/dist/core/web/public/next/assets/{cloud-queries-CTGvO-k-.js.map → cloud-queries-DmptbjS8.js.map} +1 -1
  275. package/dist/core/web/public/next/assets/{command-catalog-CmrHNFzh.js → command-catalog-ffCAijVY.js} +2 -2
  276. package/dist/core/web/public/next/assets/{command-catalog-CmrHNFzh.js.map → command-catalog-ffCAijVY.js.map} +1 -1
  277. package/dist/core/web/public/next/assets/{context-model-2Owp2jYF.js → context-model-Bb15chFt.js} +2 -2
  278. package/dist/core/web/public/next/assets/{context-model-2Owp2jYF.js.map → context-model-Bb15chFt.js.map} +1 -1
  279. package/dist/core/web/public/next/assets/{context-model-9xywbXxX.js → context-model-CDeyP0cA.js} +2 -2
  280. package/dist/core/web/public/next/assets/{context-model-9xywbXxX.js.map → context-model-CDeyP0cA.js.map} +1 -1
  281. package/dist/core/web/public/next/assets/{context-queries-wvcRnV-I.js → context-queries-_9bFWb9v.js} +2 -2
  282. package/dist/core/web/public/next/assets/{context-queries-wvcRnV-I.js.map → context-queries-_9bFWb9v.js.map} +1 -1
  283. package/dist/core/web/public/next/assets/{control-queries-DB6Kh7UN.js → control-queries-CXtmZZH6.js} +2 -2
  284. package/dist/core/web/public/next/assets/{control-queries-DB6Kh7UN.js.map → control-queries-CXtmZZH6.js.map} +1 -1
  285. package/dist/core/web/public/next/assets/copy-setup-BIp0iaiZ.js +2 -0
  286. package/dist/core/web/public/next/assets/copy-setup-BIp0iaiZ.js.map +1 -0
  287. package/dist/core/web/public/next/assets/{dock-icons-BBUGl4tE.js → dock-icons-Cc43W7r4.js} +2 -2
  288. package/dist/core/web/public/next/assets/{dock-icons-BBUGl4tE.js.map → dock-icons-Cc43W7r4.js.map} +1 -1
  289. package/dist/core/web/public/next/assets/{fleet-model-BRfRWkZl.js → fleet-model-DOK8ZtEt.js} +2 -2
  290. package/dist/core/web/public/next/assets/{fleet-model-BRfRWkZl.js.map → fleet-model-DOK8ZtEt.js.map} +1 -1
  291. package/dist/core/web/public/next/assets/{fleet-queries-tU6UEXN2.js → fleet-queries-BeEAqD6y.js} +2 -2
  292. package/dist/core/web/public/next/assets/{fleet-queries-tU6UEXN2.js.map → fleet-queries-BeEAqD6y.js.map} +1 -1
  293. package/dist/core/web/public/next/assets/{focus-trap-BGOceFvj.js → focus-trap-ChZ5EFfM.js} +2 -2
  294. package/dist/core/web/public/next/assets/{focus-trap-BGOceFvj.js.map → focus-trap-ChZ5EFfM.js.map} +1 -1
  295. package/dist/core/web/public/next/assets/format-BmH2yWL6.js +2 -0
  296. package/dist/core/web/public/next/assets/format-BmH2yWL6.js.map +1 -0
  297. package/dist/core/web/public/next/assets/{git-model-53iRLInY.js → git-model-BFwAVbxF.js} +2 -2
  298. package/dist/core/web/public/next/assets/{git-model-53iRLInY.js.map → git-model-BFwAVbxF.js.map} +1 -1
  299. package/dist/core/web/public/next/assets/global-y_exIyAP.js +2 -0
  300. package/dist/core/web/public/next/assets/{global-CXHHMz9o.js.map → global-y_exIyAP.js.map} +1 -1
  301. package/dist/core/web/public/next/assets/{guarded-runners-B8zFVBVZ.js → guarded-runners-Cd4POBtI.js} +2 -2
  302. package/dist/core/web/public/next/assets/{guarded-runners-B8zFVBVZ.js.map → guarded-runners-Cd4POBtI.js.map} +1 -1
  303. package/dist/core/web/public/next/assets/{icons-D4s-jlxX.js → icons-CygCEFWs.js} +2 -2
  304. package/dist/core/web/public/next/assets/{icons-D4s-jlxX.js.map → icons-CygCEFWs.js.map} +1 -1
  305. package/dist/core/web/public/next/assets/{index-BG177cPN.js → index-CyK31YRm.js} +3 -3
  306. package/dist/core/web/public/next/assets/{index-BG177cPN.js.map → index-CyK31YRm.js.map} +1 -1
  307. package/dist/core/web/public/next/assets/{live-model-CEf01wrW.js → live-model-D7hilYFk.js} +2 -2
  308. package/dist/core/web/public/next/assets/live-model-D7hilYFk.js.map +1 -0
  309. package/dist/core/web/public/next/assets/{mind.module-D_xk6HIQ.js → mind.module-B15k0Y9q.js} +2 -2
  310. package/dist/core/web/public/next/assets/{mind.module-D_xk6HIQ.js.map → mind.module-B15k0Y9q.js.map} +1 -1
  311. package/dist/core/web/public/next/assets/mutations-CWlxEMEm.js +2 -0
  312. package/dist/core/web/public/next/assets/{mutations-CbTSofVH.js.map → mutations-CWlxEMEm.js.map} +1 -1
  313. package/dist/core/web/public/next/assets/{nav-CmZcbPFJ.js → nav-mimleI0R.js} +2 -2
  314. package/dist/core/web/public/next/assets/{nav-CmZcbPFJ.js.map → nav-mimleI0R.js.map} +1 -1
  315. package/dist/core/web/public/next/assets/{overnight-queries-CR0b_j-V.js → overnight-queries-DJ4mZKSj.js} +2 -2
  316. package/dist/core/web/public/next/assets/{overnight-queries-CR0b_j-V.js.map → overnight-queries-DJ4mZKSj.js.map} +1 -1
  317. package/dist/core/web/public/next/assets/primitives-DMijqcu0.js +1 -0
  318. package/dist/core/web/public/next/assets/{queries-rvRsAGW2.js → queries-Bw1McHTj.js} +2 -2
  319. package/dist/core/web/public/next/assets/{queries-rvRsAGW2.js.map → queries-Bw1McHTj.js.map} +1 -1
  320. package/dist/core/web/public/next/assets/{reasoning-pref-DMPQkujg.js → reasoning-pref-KkhI_5-j.js} +2 -2
  321. package/dist/core/web/public/next/assets/{reasoning-pref-DMPQkujg.js.map → reasoning-pref-KkhI_5-j.js.map} +1 -1
  322. package/dist/core/web/public/next/assets/{reveal-anchor-BKk2wZZZ.js → reveal-anchor-CCCx_kfT.js} +2 -2
  323. package/dist/core/web/public/next/assets/{reveal-anchor-BKk2wZZZ.js.map → reveal-anchor-CCCx_kfT.js.map} +1 -1
  324. package/dist/core/web/public/next/assets/{seat-subscription-CLn2ReSZ.js → seat-subscription-BhUUz7VL.js} +2 -2
  325. package/dist/core/web/public/next/assets/{seat-subscription-CLn2ReSZ.js.map → seat-subscription-BhUUz7VL.js.map} +1 -1
  326. package/dist/core/web/public/next/assets/{sidebar-model-CjQLvdag.js → sidebar-model-Dcd437cf.js} +2 -2
  327. package/dist/core/web/public/next/assets/{sidebar-model-CjQLvdag.js.map → sidebar-model-Dcd437cf.js.map} +1 -1
  328. package/dist/core/web/public/next/assets/{slots-DRxNosZg.js → slots-BL_J5mmV.js} +3 -3
  329. package/dist/core/web/public/next/assets/{slots-DRxNosZg.js.map → slots-BL_J5mmV.js.map} +1 -1
  330. package/dist/core/web/public/next/assets/{surface-data-DshUC_TU.js → surface-data-C3UAQ4QX.js} +2 -2
  331. package/dist/core/web/public/next/assets/{surface-data-DshUC_TU.js.map → surface-data-C3UAQ4QX.js.map} +1 -1
  332. package/dist/core/web/public/next/assets/surface-prefetch-BXKjPsV5.js +2 -0
  333. package/dist/core/web/public/next/assets/{surface-prefetch-DO8r4ttQ.js.map → surface-prefetch-BXKjPsV5.js.map} +1 -1
  334. package/dist/core/web/public/next/assets/{tasks-model-BKPFZAmZ.js → tasks-model-CzHvclVm.js} +2 -2
  335. package/dist/core/web/public/next/assets/{tasks-model-BKPFZAmZ.js.map → tasks-model-CzHvclVm.js.map} +1 -1
  336. package/dist/core/web/public/next/assets/{terminal-icons-DoeQkP3y.js → terminal-icons-BwgQTQP0.js} +2 -2
  337. package/dist/core/web/public/next/assets/{terminal-icons-DoeQkP3y.js.map → terminal-icons-BwgQTQP0.js.map} +1 -1
  338. package/dist/core/web/public/next/assets/types-IYKrYLku.js +2 -0
  339. package/dist/core/web/public/next/assets/types-IYKrYLku.js.map +1 -0
  340. package/dist/core/web/public/next/assets/{usage-queries-MnUeYzwp.js → usage-queries-pXxvy54x.js} +2 -2
  341. package/dist/core/web/public/next/assets/{usage-queries-MnUeYzwp.js.map → usage-queries-pXxvy54x.js.map} +1 -1
  342. package/dist/core/web/public/next/assets/{use-guarded-action-P12MfNwU.js → use-guarded-action-EgVWjM5c.js} +2 -2
  343. package/dist/core/web/public/next/assets/{use-guarded-action-P12MfNwU.js.map → use-guarded-action-EgVWjM5c.js.map} +1 -1
  344. package/dist/core/web/public/next/assets/{use-ticker-DIvAZ4Ey.js → use-ticker-BoqFxRFG.js} +2 -2
  345. package/dist/core/web/public/next/assets/{use-ticker-DIvAZ4Ey.js.map → use-ticker-BoqFxRFG.js.map} +1 -1
  346. package/dist/core/web/public/next/assets/{use-token-gate-DfEja7Wr.js → use-token-gate-DSNIIpI6.js} +2 -2
  347. package/dist/core/web/public/next/assets/{use-token-gate-DfEja7Wr.js.map → use-token-gate-DSNIIpI6.js.map} +1 -1
  348. package/dist/core/web/public/next/assets/{useOnboarding-CkOHadqC.js → useOnboarding-Bk0VnkxQ.js} +2 -2
  349. package/dist/core/web/public/next/assets/{useOnboarding-CkOHadqC.js.map → useOnboarding-Bk0VnkxQ.js.map} +1 -1
  350. package/dist/core/web/public/next/assets/{useSeatsRefresh-BDlbDlIU.js → useSeatsRefresh-q7Id9RcW.js} +2 -2
  351. package/dist/core/web/public/next/assets/{useSeatsRefresh-BDlbDlIU.js.map → useSeatsRefresh-q7Id9RcW.js.map} +1 -1
  352. package/dist/core/web/public/next/assets/{useVerseTranscript-BGtA55k2.js → useVerseTranscript-CqH51rt9.js} +2 -2
  353. package/dist/core/web/public/next/assets/{useVerseTranscript-BGtA55k2.js.map → useVerseTranscript-CqH51rt9.js.map} +1 -1
  354. package/dist/core/web/public/next/assets/{verse-icons-wOet9JZy.js → verse-icons-DsG1dOQx.js} +2 -2
  355. package/dist/core/web/public/next/assets/{verse-icons-wOet9JZy.js.map → verse-icons-DsG1dOQx.js.map} +1 -1
  356. package/dist/core/web/public/next/assets/{verse-model-CSzzdyu2.js → verse-model-JTuvRBVK.js} +2 -2
  357. package/dist/core/web/public/next/assets/{verse-model-CSzzdyu2.js.map → verse-model-JTuvRBVK.js.map} +1 -1
  358. package/dist/core/web/public/next/assets/{warmup-CecO_Nk0.js → warmup-Bv1RumVq.js} +3 -3
  359. package/dist/core/web/public/next/assets/{warmup-CecO_Nk0.js.map → warmup-Bv1RumVq.js.map} +1 -1
  360. package/dist/core/web/public/next/assets/why-seat-model-Cau8qG6O.js +2 -0
  361. package/dist/core/web/public/next/assets/why-seat-model-Cau8qG6O.js.map +1 -0
  362. package/dist/core/web/public/next/assets/{workspace-model-BdIVybKr.js → workspace-model-D-SLfads.js} +2 -2
  363. package/dist/core/web/public/next/assets/{workspace-model-BdIVybKr.js.map → workspace-model-D-SLfads.js.map} +1 -1
  364. package/dist/core/web/public/next/index.html +1 -1
  365. package/dist/release-dependency-inventory.json +1 -1
  366. package/docs/AUTONOMY-GAP.md +1 -1
  367. package/package.json +1 -1
  368. package/dist/core/web/public/next/assets/Advanced-CxzE6ekM.js +0 -2
  369. package/dist/core/web/public/next/assets/App-DFlp-vdv.js +0 -7
  370. package/dist/core/web/public/next/assets/AppsSection-Ct2O605-.js +0 -2
  371. package/dist/core/web/public/next/assets/AutonomyOffState-CXhXpsim.js +0 -2
  372. package/dist/core/web/public/next/assets/AutonomyOffState-CXhXpsim.js.map +0 -1
  373. package/dist/core/web/public/next/assets/AutonomyOffState-DmbE71vI.css +0 -1
  374. package/dist/core/web/public/next/assets/AutonomySection-BTg7yVa1.js +0 -2
  375. package/dist/core/web/public/next/assets/BudgetControl-ng6swoZp.js +0 -2
  376. package/dist/core/web/public/next/assets/BudgetControl-ng6swoZp.js.map +0 -1
  377. package/dist/core/web/public/next/assets/ChatSection-Bisj9R6E.js +0 -3
  378. package/dist/core/web/public/next/assets/ChatSection-Bisj9R6E.js.map +0 -1
  379. package/dist/core/web/public/next/assets/CommandSection-D8ZihzvE.js +0 -2
  380. package/dist/core/web/public/next/assets/CommandSection-D8ZihzvE.js.map +0 -1
  381. package/dist/core/web/public/next/assets/DockHost-BPqyhtCP.js +0 -2
  382. package/dist/core/web/public/next/assets/McpSection-D1tDvlRa.js +0 -2
  383. package/dist/core/web/public/next/assets/NeedsYouDrawer-D992XTOn.js +0 -2
  384. package/dist/core/web/public/next/assets/NeedsYouDrawer-D992XTOn.js.map +0 -1
  385. package/dist/core/web/public/next/assets/NeedsYouList-CruOt4JT.css +0 -1
  386. package/dist/core/web/public/next/assets/NeedsYouList-eBOlJr0b.js +0 -2
  387. package/dist/core/web/public/next/assets/OnboardingFlow-D3yfITK1.js +0 -2
  388. package/dist/core/web/public/next/assets/OnboardingFlow-D3yfITK1.js.map +0 -1
  389. package/dist/core/web/public/next/assets/OnboardingGate-DrDEVBqw.js +0 -3
  390. package/dist/core/web/public/next/assets/ResourcesChrome-C2ZrA7la.js +0 -3
  391. package/dist/core/web/public/next/assets/Sidebar-BuO3sViG.js +0 -3
  392. package/dist/core/web/public/next/assets/Sidebar-BuO3sViG.js.map +0 -1
  393. package/dist/core/web/public/next/assets/VerseConsoleApp-DeuBEvAO.js +0 -3
  394. package/dist/core/web/public/next/assets/VerseConsoleApp-DeuBEvAO.js.map +0 -1
  395. package/dist/core/web/public/next/assets/cloud-model-DoxBMDvx.js +0 -2
  396. package/dist/core/web/public/next/assets/copy-setup-CJQhFl-4.js +0 -2
  397. package/dist/core/web/public/next/assets/copy-setup-CJQhFl-4.js.map +0 -1
  398. package/dist/core/web/public/next/assets/format-DEAaVF6X.js +0 -2
  399. package/dist/core/web/public/next/assets/format-DEAaVF6X.js.map +0 -1
  400. package/dist/core/web/public/next/assets/global-CXHHMz9o.js +0 -2
  401. package/dist/core/web/public/next/assets/live-model-CEf01wrW.js.map +0 -1
  402. package/dist/core/web/public/next/assets/mutations-CbTSofVH.js +0 -2
  403. package/dist/core/web/public/next/assets/primitives-DNI-uJBd.js +0 -1
  404. package/dist/core/web/public/next/assets/surface-prefetch-DO8r4ttQ.js +0 -2
  405. package/dist/core/web/public/next/assets/types-D5XOdyw8.js +0 -2
  406. package/dist/core/web/public/next/assets/types-D5XOdyw8.js.map +0 -1
  407. package/dist/core/web/public/next/assets/why-seat-model-D68ZA7G8.js +0 -2
  408. package/dist/core/web/public/next/assets/why-seat-model-D68ZA7G8.js.map +0 -1
@@ -1,2 +1,2 @@
1
- import{a as e,c as t,n}from"./index-BG177cPN.js";var r=t(e(),1),i={group:`_group_15ia8_1`,block:`_block_15ia8_11`,option:`_option_15ia8_16`,sm:`_sm_15ia8_45`,glyph:`_glyph_15ia8_72`},a=n();function o({options:e,value:t,onChange:n,size:o=`md`,block:s=!1,className:c,...l}){let u=(0,r.useRef)(null);function d(r){let i=e.filter(e=>!e.disabled);if(i.length===0)return;let a=i[((i.findIndex(e=>e.value===t)+r)%i.length+i.length)%i.length];n(a.value),requestAnimationFrame(()=>{u.current?.querySelector(`[data-value="${a.value}"]`)?.focus()})}return(0,a.jsx)(`div`,{ref:u,role:`radiogroup`,className:`${i.group} ${i[o]} ${s?i.block:``} ${c??``}`,...l,children:e.map(e=>{let r=e.value===t;return(0,a.jsxs)(`button`,{type:`button`,role:`radio`,"aria-checked":r,"aria-label":e.ariaLabel,"data-value":e.value,tabIndex:r?0:-1,disabled:e.disabled,className:i.option,onClick:()=>n(e.value),onKeyDown:e=>{e.key===`ArrowRight`||e.key===`ArrowDown`?(e.preventDefault(),d(1)):(e.key===`ArrowLeft`||e.key===`ArrowUp`)&&(e.preventDefault(),d(-1))},children:[e.icon?(0,a.jsx)(`span`,{className:i.glyph,children:e.icon}):null,e.label]},e.value)})})}export{o as t};
2
- //# sourceMappingURL=Segmented-Wynbg0F5.js.map
1
+ import{a as e,c as t,n}from"./index-CyK31YRm.js";var r=t(e(),1),i={group:`_group_15ia8_1`,block:`_block_15ia8_11`,option:`_option_15ia8_16`,sm:`_sm_15ia8_45`,glyph:`_glyph_15ia8_72`},a=n();function o({options:e,value:t,onChange:n,size:o=`md`,block:s=!1,className:c,...l}){let u=(0,r.useRef)(null);function d(r){let i=e.filter(e=>!e.disabled);if(i.length===0)return;let a=i[((i.findIndex(e=>e.value===t)+r)%i.length+i.length)%i.length];n(a.value),requestAnimationFrame(()=>{u.current?.querySelector(`[data-value="${a.value}"]`)?.focus()})}return(0,a.jsx)(`div`,{ref:u,role:`radiogroup`,className:`${i.group} ${i[o]} ${s?i.block:``} ${c??``}`,...l,children:e.map(e=>{let r=e.value===t;return(0,a.jsxs)(`button`,{type:`button`,role:`radio`,"aria-checked":r,"aria-label":e.ariaLabel,"data-value":e.value,tabIndex:r?0:-1,disabled:e.disabled,className:i.option,onClick:()=>n(e.value),onKeyDown:e=>{e.key===`ArrowRight`||e.key===`ArrowDown`?(e.preventDefault(),d(1)):(e.key===`ArrowLeft`||e.key===`ArrowUp`)&&(e.preventDefault(),d(-1))},children:[e.icon?(0,a.jsx)(`span`,{className:i.glyph,children:e.icon}):null,e.label]},e.value)})})}export{o as t};
2
+ //# sourceMappingURL=Segmented-Wt1ATod9.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Segmented-Wynbg0F5.js","names":[],"sources":["../../../../../../src/web-ui/components/primitives/Segmented.module.css","../../../../../../src/web-ui/components/primitives/Segmented.tsx"],"sourcesContent":[".group {\n display: inline-flex;\n align-items: center;\n gap: 2px;\n padding: 2px;\n background: var(--bg-hover);\n border: 1px solid var(--border-subtle);\n border-radius: var(--radius-sm);\n}\n\n.block {\n display: flex;\n width: 100%;\n}\n\n.block .option {\n flex: 1;\n justify-content: center;\n}\n\n.option {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n gap: var(--space-1);\n height: calc(var(--density-row) - 6px);\n padding: 0 var(--space-3);\n /* Transparent rather than absent so the checked state can colour it without\n changing the option's box — everything is border-box, so the hairline\n costs no height and no horizontal drift when it appears. */\n border: 1px solid transparent;\n border-radius: calc(var(--radius-sm) - 1px);\n background: transparent;\n color: var(--text-secondary);\n font-family: var(--font-ui);\n font-size: var(--text-xs-size);\n font-weight: var(--font-weight-medium);\n white-space: nowrap;\n cursor: pointer;\n transition:\n background-color var(--duration-fast) var(--ease-standard),\n color var(--duration-fast) var(--ease-standard);\n}\n\n.sm .option {\n height: calc(var(--density-row-sm) - 6px);\n padding: 0 var(--space-2);\n font-size: var(--text-2xs-size);\n}\n\n.option:hover:not(:disabled):not([aria-checked='true']) {\n color: var(--text-primary);\n}\n\n/* No shadow. DESIGN-V2 §1.2 allows drop shadows only on true overlays\n (dialog, menu, toast) and §2 retires every elevation token but those three;\n a segmented control is chrome. It was not carrying its weight either: in\n dark, --shadow-sm is rgba(0,0,0,0.4) on a near-black ground, i.e. invisible,\n so the selected thumb read as fill-only in dark and fill+shadow in light —\n two looks for one state. The hairline does the separating in both. */\n.option[aria-checked='true'] {\n background: var(--bg-surface);\n color: var(--text-primary);\n border-color: var(--border-default);\n}\n\n.option:disabled {\n color: var(--text-disabled);\n cursor: not-allowed;\n}\n\n.glyph {\n display: inline-flex;\n flex: none;\n}\n","/**\n * components/primitives/Segmented.tsx — pick one of 2-4 options where the\n * choice applies instantly (theme, density, a status filter). It replaces\n * both a <select> (too heavy for three options) and a row of toggle buttons\n * (no single-selection semantics for a screen reader).\n *\n * Implemented as a radiogroup with ROVING TABINDEX: one Tab stop for the\n * group, arrows move between options and select as they go — the WAI-ARIA\n * radio-group pattern. Every option is reachable by keyboard and announced\n * as \"N of M\".\n */\nimport { useRef, type ReactNode } from 'react';\nimport styles from './Segmented.module.css';\n\nexport interface SegmentedOption<T extends string> {\n value: T;\n label: ReactNode;\n /** Leading 16px glyph; the text label always stays visible. */\n icon?: ReactNode;\n /** Spoken name when `label` is a glyph or an abbreviation. */\n ariaLabel?: string;\n disabled?: boolean;\n}\n\nexport interface SegmentedProps<T extends string> {\n options: ReadonlyArray<SegmentedOption<T>>;\n value: T;\n onChange: (next: T) => void;\n /** Accessible name for the group — required when no visible label precedes it. */\n 'aria-label'?: string;\n 'aria-labelledby'?: string;\n size?: 'sm' | 'md';\n /** Stretch each option to an equal share of the width. */\n block?: boolean;\n className?: string;\n}\n\nexport function Segmented<T extends string>({\n options,\n value,\n onChange,\n size = 'md',\n block = false,\n className,\n ...aria\n}: SegmentedProps<T>) {\n const groupRef = useRef<HTMLDivElement>(null);\n\n function move(delta: number): void {\n const enabled = options.filter((o) => !o.disabled);\n if (enabled.length === 0) return;\n const current = enabled.findIndex((o) => o.value === value);\n const next = enabled[(((current + delta) % enabled.length) + enabled.length) % enabled.length]!;\n onChange(next.value);\n // Keep DOM focus on the newly selected option (roving tabindex).\n requestAnimationFrame(() => {\n groupRef.current?.querySelector<HTMLButtonElement>(`[data-value=\"${next.value}\"]`)?.focus();\n });\n }\n\n return (\n <div\n ref={groupRef}\n role=\"radiogroup\"\n className={`${styles.group} ${styles[size]} ${block ? styles.block : ''} ${className ?? ''}`}\n {...aria}\n >\n {options.map((option) => {\n const selected = option.value === value;\n return (\n <button\n key={option.value}\n type=\"button\"\n role=\"radio\"\n aria-checked={selected}\n aria-label={option.ariaLabel}\n data-value={option.value}\n tabIndex={selected ? 0 : -1}\n disabled={option.disabled}\n className={styles.option}\n onClick={() => onChange(option.value)}\n onKeyDown={(e) => {\n if (e.key === 'ArrowRight' || e.key === 'ArrowDown') {\n e.preventDefault();\n move(1);\n } else if (e.key === 'ArrowLeft' || e.key === 'ArrowUp') {\n e.preventDefault();\n move(-1);\n }\n }}\n >\n {option.icon ? <span className={styles.glyph}>{option.icon}</span> : null}\n {option.label}\n </button>\n );\n })}\n </div>\n );\n}\n"],"mappings":"6LCqCA,SAAgB,EAA4B,CAC1C,UACA,QACA,WACA,OAAO,KACP,QAAQ,GACR,YACA,GAAG,GACiB,CACpB,IAAM,GAAA,EAAW,EAAA,OAAA,CAAuB,IAAI,EAE5C,SAAS,EAAK,EAAqB,CACjC,IAAM,EAAU,EAAQ,OAAQ,GAAM,CAAC,EAAE,QAAQ,EACjD,GAAI,EAAQ,SAAW,EAAG,OAE1B,IAAM,EAAO,IADG,EAAQ,UAAW,GAAM,EAAE,QAAU,CAC7B,EAAU,GAAS,EAAQ,OAAU,EAAQ,QAAU,EAAQ,QACvF,EAAS,EAAK,KAAK,EAEnB,0BAA4B,CAC1B,EAAS,SAAS,cAAiC,gBAAgB,EAAK,MAAM,GAAG,CAAC,EAAE,MAAM,CAC5F,CAAC,CACH,CAEA,OACE,EAAA,EAAA,IAAA,CAAC,MAAD,CACE,IAAK,EACL,KAAK,aACL,UAAW,GAAG,EAAO,MAAM,GAAG,EAAO,GAAM,GAAG,EAAQ,EAAO,MAAQ,GAAG,GAAG,GAAa,KACxF,GAAI,EAEH,SAAA,EAAQ,IAAK,GAAW,CACvB,IAAM,EAAW,EAAO,QAAU,EAClC,OACE,EAAA,EAAA,KAAA,CAAC,SAAD,CAEE,KAAK,SACL,KAAK,QACL,eAAc,EACd,aAAY,EAAO,UACnB,aAAY,EAAO,MACnB,SAAU,EAAW,EAAI,GACzB,SAAU,EAAO,SACjB,UAAW,EAAO,OAClB,YAAe,EAAS,EAAO,KAAK,EACpC,UAAY,GAAM,CACZ,EAAE,MAAQ,cAAgB,EAAE,MAAQ,aACtC,EAAE,eAAe,EACjB,EAAK,CAAC,IACG,EAAE,MAAQ,aAAe,EAAE,MAAQ,aAC5C,EAAE,eAAe,EACjB,EAAK,EAAE,EAEX,EAnBF,SAAA,CAqBG,EAAO,MAAO,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,UAAW,EAAO,MAAQ,SAAA,EAAO,IAAW,CAAA,EAAI,KACpE,EAAO,KACF,CAtBD,EAAA,EAAO,KAsBN,CAEZ,CAAC,CACE,CAAA,CAET"}
1
+ {"version":3,"file":"Segmented-Wt1ATod9.js","names":[],"sources":["../../../../../../src/web-ui/components/primitives/Segmented.module.css","../../../../../../src/web-ui/components/primitives/Segmented.tsx"],"sourcesContent":[".group {\n display: inline-flex;\n align-items: center;\n gap: 2px;\n padding: 2px;\n background: var(--bg-hover);\n border: 1px solid var(--border-subtle);\n border-radius: var(--radius-sm);\n}\n\n.block {\n display: flex;\n width: 100%;\n}\n\n.block .option {\n flex: 1;\n justify-content: center;\n}\n\n.option {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n gap: var(--space-1);\n height: calc(var(--density-row) - 6px);\n padding: 0 var(--space-3);\n /* Transparent rather than absent so the checked state can colour it without\n changing the option's box — everything is border-box, so the hairline\n costs no height and no horizontal drift when it appears. */\n border: 1px solid transparent;\n border-radius: calc(var(--radius-sm) - 1px);\n background: transparent;\n color: var(--text-secondary);\n font-family: var(--font-ui);\n font-size: var(--text-xs-size);\n font-weight: var(--font-weight-medium);\n white-space: nowrap;\n cursor: pointer;\n transition:\n background-color var(--duration-fast) var(--ease-standard),\n color var(--duration-fast) var(--ease-standard);\n}\n\n.sm .option {\n height: calc(var(--density-row-sm) - 6px);\n padding: 0 var(--space-2);\n font-size: var(--text-2xs-size);\n}\n\n.option:hover:not(:disabled):not([aria-checked='true']) {\n color: var(--text-primary);\n}\n\n/* No shadow. DESIGN-V2 §1.2 allows drop shadows only on true overlays\n (dialog, menu, toast) and §2 retires every elevation token but those three;\n a segmented control is chrome. It was not carrying its weight either: in\n dark, --shadow-sm is rgba(0,0,0,0.4) on a near-black ground, i.e. invisible,\n so the selected thumb read as fill-only in dark and fill+shadow in light —\n two looks for one state. The hairline does the separating in both. */\n.option[aria-checked='true'] {\n background: var(--bg-surface);\n color: var(--text-primary);\n border-color: var(--border-default);\n}\n\n.option:disabled {\n color: var(--text-disabled);\n cursor: not-allowed;\n}\n\n.glyph {\n display: inline-flex;\n flex: none;\n}\n","/**\n * components/primitives/Segmented.tsx — pick one of 2-4 options where the\n * choice applies instantly (theme, density, a status filter). It replaces\n * both a <select> (too heavy for three options) and a row of toggle buttons\n * (no single-selection semantics for a screen reader).\n *\n * Implemented as a radiogroup with ROVING TABINDEX: one Tab stop for the\n * group, arrows move between options and select as they go — the WAI-ARIA\n * radio-group pattern. Every option is reachable by keyboard and announced\n * as \"N of M\".\n */\nimport { useRef, type ReactNode } from 'react';\nimport styles from './Segmented.module.css';\n\nexport interface SegmentedOption<T extends string> {\n value: T;\n label: ReactNode;\n /** Leading 16px glyph; the text label always stays visible. */\n icon?: ReactNode;\n /** Spoken name when `label` is a glyph or an abbreviation. */\n ariaLabel?: string;\n disabled?: boolean;\n}\n\nexport interface SegmentedProps<T extends string> {\n options: ReadonlyArray<SegmentedOption<T>>;\n value: T;\n onChange: (next: T) => void;\n /** Accessible name for the group — required when no visible label precedes it. */\n 'aria-label'?: string;\n 'aria-labelledby'?: string;\n size?: 'sm' | 'md';\n /** Stretch each option to an equal share of the width. */\n block?: boolean;\n className?: string;\n}\n\nexport function Segmented<T extends string>({\n options,\n value,\n onChange,\n size = 'md',\n block = false,\n className,\n ...aria\n}: SegmentedProps<T>) {\n const groupRef = useRef<HTMLDivElement>(null);\n\n function move(delta: number): void {\n const enabled = options.filter((o) => !o.disabled);\n if (enabled.length === 0) return;\n const current = enabled.findIndex((o) => o.value === value);\n const next = enabled[(((current + delta) % enabled.length) + enabled.length) % enabled.length]!;\n onChange(next.value);\n // Keep DOM focus on the newly selected option (roving tabindex).\n requestAnimationFrame(() => {\n groupRef.current?.querySelector<HTMLButtonElement>(`[data-value=\"${next.value}\"]`)?.focus();\n });\n }\n\n return (\n <div\n ref={groupRef}\n role=\"radiogroup\"\n className={`${styles.group} ${styles[size]} ${block ? styles.block : ''} ${className ?? ''}`}\n {...aria}\n >\n {options.map((option) => {\n const selected = option.value === value;\n return (\n <button\n key={option.value}\n type=\"button\"\n role=\"radio\"\n aria-checked={selected}\n aria-label={option.ariaLabel}\n data-value={option.value}\n tabIndex={selected ? 0 : -1}\n disabled={option.disabled}\n className={styles.option}\n onClick={() => onChange(option.value)}\n onKeyDown={(e) => {\n if (e.key === 'ArrowRight' || e.key === 'ArrowDown') {\n e.preventDefault();\n move(1);\n } else if (e.key === 'ArrowLeft' || e.key === 'ArrowUp') {\n e.preventDefault();\n move(-1);\n }\n }}\n >\n {option.icon ? <span className={styles.glyph}>{option.icon}</span> : null}\n {option.label}\n </button>\n );\n })}\n </div>\n );\n}\n"],"mappings":"6LCqCA,SAAgB,EAA4B,CAC1C,UACA,QACA,WACA,OAAO,KACP,QAAQ,GACR,YACA,GAAG,GACiB,CACpB,IAAM,GAAA,EAAW,EAAA,OAAA,CAAuB,IAAI,EAE5C,SAAS,EAAK,EAAqB,CACjC,IAAM,EAAU,EAAQ,OAAQ,GAAM,CAAC,EAAE,QAAQ,EACjD,GAAI,EAAQ,SAAW,EAAG,OAE1B,IAAM,EAAO,IADG,EAAQ,UAAW,GAAM,EAAE,QAAU,CAC7B,EAAU,GAAS,EAAQ,OAAU,EAAQ,QAAU,EAAQ,QACvF,EAAS,EAAK,KAAK,EAEnB,0BAA4B,CAC1B,EAAS,SAAS,cAAiC,gBAAgB,EAAK,MAAM,GAAG,CAAC,EAAE,MAAM,CAC5F,CAAC,CACH,CAEA,OACE,EAAA,EAAA,IAAA,CAAC,MAAD,CACE,IAAK,EACL,KAAK,aACL,UAAW,GAAG,EAAO,MAAM,GAAG,EAAO,GAAM,GAAG,EAAQ,EAAO,MAAQ,GAAG,GAAG,GAAa,KACxF,GAAI,EAEH,SAAA,EAAQ,IAAK,GAAW,CACvB,IAAM,EAAW,EAAO,QAAU,EAClC,OACE,EAAA,EAAA,KAAA,CAAC,SAAD,CAEE,KAAK,SACL,KAAK,QACL,eAAc,EACd,aAAY,EAAO,UACnB,aAAY,EAAO,MACnB,SAAU,EAAW,EAAI,GACzB,SAAU,EAAO,SACjB,UAAW,EAAO,OAClB,YAAe,EAAS,EAAO,KAAK,EACpC,UAAY,GAAM,CACZ,EAAE,MAAQ,cAAgB,EAAE,MAAQ,aACtC,EAAE,eAAe,EACjB,EAAK,CAAC,IACG,EAAE,MAAQ,aAAe,EAAE,MAAQ,aAC5C,EAAE,eAAe,EACjB,EAAK,EAAE,EAEX,EAnBF,SAAA,CAqBG,EAAO,MAAO,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,UAAW,EAAO,MAAQ,SAAA,EAAO,IAAW,CAAA,EAAI,KACpE,EAAO,KACF,CAtBD,EAAA,EAAO,KAsBN,CAEZ,CAAC,CACE,CAAA,CAET"}
@@ -1,2 +1,2 @@
1
- import{a as e,c as t,n}from"./index-BG177cPN.js";import{i as r}from"./icons-D4s-jlxX.js";var i=t(e(),1),a={field:`_field_1yhua_1`,label:`_label_1yhua_8`,shell:`_shell_1yhua_15`,sm:`_sm_1yhua_28`,select:`_select_1yhua_42`,chevron:`_chevron_1yhua_72`,hint:`_hint_1yhua_79`},o=n();function s({label:e,hint:t,size:n=`md`,className:s,id:c,children:l,...u}){let d=(0,i.useId)(),f=c??d,p=`${f}-hint`;return(0,o.jsxs)(`div`,{className:`${a.field} ${s??``}`,children:[e?(0,o.jsx)(`label`,{className:a.label,htmlFor:f,children:e}):null,(0,o.jsxs)(`div`,{className:`${a.shell} ${a[n]}`,children:[(0,o.jsx)(`select`,{...u,id:f,className:a.select,"aria-describedby":[u[`aria-describedby`],t?p:null].filter(Boolean).join(` `)||void 0,children:l}),(0,o.jsx)(r,{className:a.chevron,size:14})]}),t?(0,o.jsx)(`p`,{id:p,className:a.hint,children:t}):null]})}export{s as t};
2
- //# sourceMappingURL=Select-DMyLCkId.js.map
1
+ import{a as e,c as t,n}from"./index-CyK31YRm.js";import{i as r}from"./icons-CygCEFWs.js";var i=t(e(),1),a={field:`_field_1yhua_1`,label:`_label_1yhua_8`,shell:`_shell_1yhua_15`,sm:`_sm_1yhua_28`,select:`_select_1yhua_42`,chevron:`_chevron_1yhua_72`,hint:`_hint_1yhua_79`},o=n();function s({label:e,hint:t,size:n=`md`,className:s,id:c,children:l,...u}){let d=(0,i.useId)(),f=c??d,p=`${f}-hint`;return(0,o.jsxs)(`div`,{className:`${a.field} ${s??``}`,children:[e?(0,o.jsx)(`label`,{className:a.label,htmlFor:f,children:e}):null,(0,o.jsxs)(`div`,{className:`${a.shell} ${a[n]}`,children:[(0,o.jsx)(`select`,{...u,id:f,className:a.select,"aria-describedby":[u[`aria-describedby`],t?p:null].filter(Boolean).join(` `)||void 0,children:l}),(0,o.jsx)(r,{className:a.chevron,size:14})]}),t?(0,o.jsx)(`p`,{id:p,className:a.hint,children:t}):null]})}export{s as t};
2
+ //# sourceMappingURL=Select-By-V9lMc.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Select-DMyLCkId.js","names":[],"sources":["../../../../../../src/web-ui/components/primitives/Select.module.css","../../../../../../src/web-ui/components/primitives/Select.tsx"],"sourcesContent":[".field {\n display: flex;\n flex-direction: column;\n gap: var(--space-1);\n min-width: 0;\n}\n\n.label {\n font-size: var(--text-xs-size);\n line-height: var(--text-xs-line);\n color: var(--text-secondary);\n font-weight: var(--font-weight-medium);\n}\n\n.shell {\n position: relative;\n display: flex;\n align-items: center;\n height: var(--density-row);\n background: var(--bg-input);\n border: 1px solid var(--border-default);\n border-radius: var(--radius-sm);\n transition:\n border-color var(--duration-fast) var(--ease-standard),\n box-shadow var(--duration-fast) var(--ease-standard);\n}\n\n.sm {\n height: var(--density-row-sm);\n}\n\n.shell:hover {\n border-color: var(--border-strong);\n}\n\n/* The system ring, not an --accent-100 wash: that token is pinned at 92%\n lightness in light and 22% in dark (tokens.css), so hue and saturation\n follow the operator's accent but LIGHTNESS never does — every preset and\n every slider position produced the same 1.34:1 / 1.15:1 near-invisible\n ring. --shadow-focus-ring is already the 2px-gap + 2px-accent shape\n DESIGN-V2 §6 asks for, and --border-focus is contrast-tested. */\n.shell:has(.select:focus-visible) {\n border-color: var(--border-focus);\n box-shadow: var(--shadow-focus-ring);\n}\n\n.select {\n appearance: none;\n -webkit-appearance: none;\n width: 100%;\n height: 100%;\n padding: 0 var(--space-6) 0 var(--space-2);\n border: none;\n background: none;\n color: var(--text-primary);\n font-family: var(--font-ui);\n font-size: var(--text-sm-size);\n cursor: pointer;\n}\n\n.select:focus,\n.select:focus-visible {\n outline: none;\n box-shadow: none;\n}\n\n.select:disabled {\n color: var(--text-disabled);\n cursor: not-allowed;\n}\n\n.chevron {\n position: absolute;\n right: var(--space-2);\n color: var(--text-tertiary);\n pointer-events: none;\n}\n\n.hint {\n font-size: var(--text-xs-size);\n line-height: var(--text-xs-line);\n color: var(--text-tertiary);\n}\n","/**\n * components/primitives/Select.tsx — a native <select> that does not look\n * native: the browser's own control is stripped and the chevron is our own\n * 16px glyph, so the field matches Input at every density.\n *\n * Deliberately NOT a custom listbox. A native select gets the platform's\n * keyboard handling, type-ahead, and mobile picker for free — a hand-rolled\n * popup would be a worse control with more code (DESIGN.md §3).\n */\nimport { useId, type ReactNode, type SelectHTMLAttributes } from 'react';\nimport { IconChevronDown } from './icons.js';\nimport styles from './Select.module.css';\n\nexport interface SelectProps extends Omit<SelectHTMLAttributes<HTMLSelectElement>, 'size' | 'className'> {\n label?: ReactNode;\n hint?: ReactNode;\n size?: 'sm' | 'md';\n className?: string;\n children: ReactNode;\n}\n\nexport function Select({ label, hint, size = 'md', className, id, children, ...rest }: SelectProps) {\n const generatedId = useId();\n const selectId = id ?? generatedId;\n const hintId = `${selectId}-hint`;\n\n return (\n <div className={`${styles.field} ${className ?? ''}`}>\n {label ? (\n <label className={styles.label} htmlFor={selectId}>\n {label}\n </label>\n ) : null}\n <div className={`${styles.shell} ${styles[size]}`}>\n <select\n {...rest}\n id={selectId}\n className={styles.select}\n aria-describedby={[rest['aria-describedby'], hint ? hintId : null].filter(Boolean).join(' ') || undefined}\n >\n {children}\n </select>\n <IconChevronDown className={styles.chevron} size={14} />\n </div>\n {hint ? (\n <p id={hintId} className={styles.hint}>\n {hint}\n </p>\n ) : null}\n </div>\n );\n}\n"],"mappings":"sRCqBA,SAAgB,EAAO,CAAE,QAAO,OAAM,OAAO,KAAM,YAAW,KAAI,WAAU,GAAG,GAAqB,CAClG,IAAM,GAAA,EAAc,EAAA,MAAA,CAAM,EACpB,EAAW,GAAM,EACjB,EAAS,GAAG,EAAS,OAE3B,OACE,EAAA,EAAA,KAAA,CAAC,MAAD,CAAK,UAAW,GAAG,EAAO,MAAM,GAAG,GAAa,KAAhD,SAAA,CACG,GACC,EAAA,EAAA,IAAA,CAAC,QAAD,CAAO,UAAW,EAAO,MAAO,QAAS,EACtC,SAAA,CACI,CAAA,EACL,MACJ,EAAA,EAAA,KAAA,CAAC,MAAD,CAAK,UAAW,GAAG,EAAO,MAAM,GAAG,EAAO,KAA1C,SAAA,EACE,EAAA,EAAA,IAAA,CAAC,SAAD,CACE,GAAI,EACJ,GAAI,EACJ,UAAW,EAAO,OAClB,mBAAkB,CAAC,EAAK,oBAAqB,EAAO,EAAS,IAAI,CAAC,CAAC,OAAO,OAAO,CAAC,CAAC,KAAK,GAAG,GAAK,IAAA,GAE/F,UACK,CAAA,GACR,EAAA,EAAA,IAAA,CAAC,EAAD,CAAiB,UAAW,EAAO,QAAS,KAAM,EAAK,CAAA,CACpD,IACJ,GACC,EAAA,EAAA,IAAA,CAAC,IAAD,CAAG,GAAI,EAAQ,UAAW,EAAO,KAC9B,SAAA,CACA,CAAA,EACD,IACD,GAET"}
1
+ {"version":3,"file":"Select-By-V9lMc.js","names":[],"sources":["../../../../../../src/web-ui/components/primitives/Select.module.css","../../../../../../src/web-ui/components/primitives/Select.tsx"],"sourcesContent":[".field {\n display: flex;\n flex-direction: column;\n gap: var(--space-1);\n min-width: 0;\n}\n\n.label {\n font-size: var(--text-xs-size);\n line-height: var(--text-xs-line);\n color: var(--text-secondary);\n font-weight: var(--font-weight-medium);\n}\n\n.shell {\n position: relative;\n display: flex;\n align-items: center;\n height: var(--density-row);\n background: var(--bg-input);\n border: 1px solid var(--border-default);\n border-radius: var(--radius-sm);\n transition:\n border-color var(--duration-fast) var(--ease-standard),\n box-shadow var(--duration-fast) var(--ease-standard);\n}\n\n.sm {\n height: var(--density-row-sm);\n}\n\n.shell:hover {\n border-color: var(--border-strong);\n}\n\n/* The system ring, not an --accent-100 wash: that token is pinned at 92%\n lightness in light and 22% in dark (tokens.css), so hue and saturation\n follow the operator's accent but LIGHTNESS never does — every preset and\n every slider position produced the same 1.34:1 / 1.15:1 near-invisible\n ring. --shadow-focus-ring is already the 2px-gap + 2px-accent shape\n DESIGN-V2 §6 asks for, and --border-focus is contrast-tested. */\n.shell:has(.select:focus-visible) {\n border-color: var(--border-focus);\n box-shadow: var(--shadow-focus-ring);\n}\n\n.select {\n appearance: none;\n -webkit-appearance: none;\n width: 100%;\n height: 100%;\n padding: 0 var(--space-6) 0 var(--space-2);\n border: none;\n background: none;\n color: var(--text-primary);\n font-family: var(--font-ui);\n font-size: var(--text-sm-size);\n cursor: pointer;\n}\n\n.select:focus,\n.select:focus-visible {\n outline: none;\n box-shadow: none;\n}\n\n.select:disabled {\n color: var(--text-disabled);\n cursor: not-allowed;\n}\n\n.chevron {\n position: absolute;\n right: var(--space-2);\n color: var(--text-tertiary);\n pointer-events: none;\n}\n\n.hint {\n font-size: var(--text-xs-size);\n line-height: var(--text-xs-line);\n color: var(--text-tertiary);\n}\n","/**\n * components/primitives/Select.tsx — a native <select> that does not look\n * native: the browser's own control is stripped and the chevron is our own\n * 16px glyph, so the field matches Input at every density.\n *\n * Deliberately NOT a custom listbox. A native select gets the platform's\n * keyboard handling, type-ahead, and mobile picker for free — a hand-rolled\n * popup would be a worse control with more code (DESIGN.md §3).\n */\nimport { useId, type ReactNode, type SelectHTMLAttributes } from 'react';\nimport { IconChevronDown } from './icons.js';\nimport styles from './Select.module.css';\n\nexport interface SelectProps extends Omit<SelectHTMLAttributes<HTMLSelectElement>, 'size' | 'className'> {\n label?: ReactNode;\n hint?: ReactNode;\n size?: 'sm' | 'md';\n className?: string;\n children: ReactNode;\n}\n\nexport function Select({ label, hint, size = 'md', className, id, children, ...rest }: SelectProps) {\n const generatedId = useId();\n const selectId = id ?? generatedId;\n const hintId = `${selectId}-hint`;\n\n return (\n <div className={`${styles.field} ${className ?? ''}`}>\n {label ? (\n <label className={styles.label} htmlFor={selectId}>\n {label}\n </label>\n ) : null}\n <div className={`${styles.shell} ${styles[size]}`}>\n <select\n {...rest}\n id={selectId}\n className={styles.select}\n aria-describedby={[rest['aria-describedby'], hint ? hintId : null].filter(Boolean).join(' ') || undefined}\n >\n {children}\n </select>\n <IconChevronDown className={styles.chevron} size={14} />\n </div>\n {hint ? (\n <p id={hintId} className={styles.hint}>\n {hint}\n </p>\n ) : null}\n </div>\n );\n}\n"],"mappings":"sRCqBA,SAAgB,EAAO,CAAE,QAAO,OAAM,OAAO,KAAM,YAAW,KAAI,WAAU,GAAG,GAAqB,CAClG,IAAM,GAAA,EAAc,EAAA,MAAA,CAAM,EACpB,EAAW,GAAM,EACjB,EAAS,GAAG,EAAS,OAE3B,OACE,EAAA,EAAA,KAAA,CAAC,MAAD,CAAK,UAAW,GAAG,EAAO,MAAM,GAAG,GAAa,KAAhD,SAAA,CACG,GACC,EAAA,EAAA,IAAA,CAAC,QAAD,CAAO,UAAW,EAAO,MAAO,QAAS,EACtC,SAAA,CACI,CAAA,EACL,MACJ,EAAA,EAAA,KAAA,CAAC,MAAD,CAAK,UAAW,GAAG,EAAO,MAAM,GAAG,EAAO,KAA1C,SAAA,EACE,EAAA,EAAA,IAAA,CAAC,SAAD,CACE,GAAI,EACJ,GAAI,EACJ,UAAW,EAAO,OAClB,mBAAkB,CAAC,EAAK,oBAAqB,EAAO,EAAS,IAAI,CAAC,CAAC,OAAO,OAAO,CAAC,CAAC,KAAK,GAAG,GAAK,IAAA,GAE/F,UACK,CAAA,GACR,EAAA,EAAA,IAAA,CAAC,EAAD,CAAiB,UAAW,EAAO,QAAS,KAAM,EAAK,CAAA,CACpD,IACJ,GACC,EAAA,EAAA,IAAA,CAAC,IAAD,CAAG,GAAI,EAAQ,UAAW,EAAO,KAC9B,SAAA,CACA,CAAA,EACD,IACD,GAET"}
@@ -1,2 +1,2 @@
1
- import{a as e,c as t,n}from"./index-BG177cPN.js";import{M as r,w as i,x as a}from"./global-CXHHMz9o.js";var o=t(e(),1),s={wrap:`_wrap_14qw9_1`,card:`_card_14qw9_10`,badge:`_badge_14qw9_19`,heading:`_heading_14qw9_24`,body:`_body_14qw9_31`,code:`_code_14qw9_38`,example:`_example_14qw9_49`,form:`_form_14qw9_56`,label:`_label_14qw9_63`,input:`_input_14qw9_68`,error:`_error_14qw9_82`,submit:`_submit_14qw9_87`,optional:`_optional_14qw9_107`},c=n(),l=/^[a-f0-9]{64}$/;function u({onAuthenticated:e,heading:t=`Connect to ashlr serve`,command:n=`ashlr serve`,subject:u=`This dashboard`,mutationField:d=!1}){let[f,p]=(0,o.useState)(``),[m,h]=(0,o.useState)(``),[g,_]=(0,o.useState)(null),[v,y]=(0,o.useState)(!1),b=(0,o.useRef)(null),x=(0,o.useId)(),S=(0,o.useId)(),C=(0,o.useId)(),w=(0,o.useRef)(e);w.current=e,(0,o.useEffect)(()=>{let e=!1;return a().then(t=>{t&&!e&&w.current?.()}),()=>{e=!0}},[]);async function T(t){t.preventDefault(),_(null);let n=m.trim();if(d&&n&&!l.test(n)){_(`That does not look like a mutation token — expected 64 hex characters (leave it empty to unlock later).`);return}y(!0);try{await i(f),p(``),d&&n&&r(n),h(``),e?.()}catch(e){_(e instanceof Error?e.message:`Could not establish a session.`),b.current?.select()}finally{y(!1)}}return(0,c.jsx)(`div`,{className:s.wrap,children:(0,c.jsxs)(`div`,{className:s.card,children:[(0,c.jsx)(`div`,{className:s.badge,"aria-hidden":`true`,children:`⛺`}),(0,c.jsx)(`h1`,{className:s.heading,children:t}),(0,c.jsxs)(`p`,{className:s.body,children:[u,` only ever talks to the ashlr server running on this machine (`,(0,c.jsx)(`code`,{children:`127.0.0.1`}),`, never a remote host). To read data, paste the`,` `,(0,c.jsx)(`strong`,{children:`read token`}),` printed in the terminal where you ran:`]}),(0,c.jsx)(`pre`,{className:s.code,children:n}),(0,c.jsxs)(`p`,{className:s.body,children:[`It looks like a 64-character hex string, printed once at startup — something like`,` `,(0,c.jsx)(`code`,{className:s.example,children:`a1b2c3…`}),`. This dialog never stores it: it is exchanged once for a short-lived session cookie, then discarded.`]}),(0,c.jsxs)(`form`,{onSubmit:T,className:s.form,noValidate:!0,children:[(0,c.jsx)(`label`,{htmlFor:x,className:s.label,children:`Read token`}),(0,c.jsx)(`input`,{ref:b,id:x,name:`read-token`,type:`password`,autoComplete:`off`,autoCorrect:`off`,spellCheck:!1,inputMode:`text`,className:s.input,value:f,onChange:e=>p(e.target.value),"aria-invalid":g?!0:void 0,"aria-describedby":g?C:void 0,placeholder:`64 hex characters`,autoFocus:!0}),d?(0,c.jsxs)(c.Fragment,{children:[(0,c.jsxs)(`label`,{htmlFor:S,className:s.label,children:[`Mutation token `,(0,c.jsx)(`span`,{className:s.optional,children:`optional — paste it now to enable sending`})]}),(0,c.jsx)(`input`,{id:S,name:`mutation-token`,type:`password`,autoComplete:`off`,autoCorrect:`off`,spellCheck:!1,inputMode:`text`,className:s.input,value:m,onChange:e=>h(e.target.value),placeholder:`64 hex characters, printed under “Dispatch enabled”`})]}):null,g?(0,c.jsx)(`p`,{id:C,className:s.error,role:`alert`,children:g}):null,(0,c.jsx)(`button`,{type:`submit`,className:s.submit,disabled:v||f.trim().length===0,children:v?`Connecting…`:`Connect`})]})]})})}export{u as SessionGate};
2
- //# sourceMappingURL=SessionGate-8RtQFWeZ.js.map
1
+ import{a as e,c as t,n}from"./index-CyK31YRm.js";import{N as r,S as i,T as a}from"./global-y_exIyAP.js";var o=t(e(),1),s={wrap:`_wrap_14qw9_1`,card:`_card_14qw9_10`,badge:`_badge_14qw9_19`,heading:`_heading_14qw9_24`,body:`_body_14qw9_31`,code:`_code_14qw9_38`,example:`_example_14qw9_49`,form:`_form_14qw9_56`,label:`_label_14qw9_63`,input:`_input_14qw9_68`,error:`_error_14qw9_82`,submit:`_submit_14qw9_87`,optional:`_optional_14qw9_107`},c=n(),l=/^[a-f0-9]{64}$/;function u({onAuthenticated:e,heading:t=`Connect to ashlr serve`,command:n=`ashlr serve`,subject:u=`This dashboard`,mutationField:d=!1}){let[f,p]=(0,o.useState)(``),[m,h]=(0,o.useState)(``),[g,_]=(0,o.useState)(null),[v,y]=(0,o.useState)(!1),b=(0,o.useRef)(null),x=(0,o.useId)(),S=(0,o.useId)(),C=(0,o.useId)(),w=(0,o.useRef)(e);w.current=e,(0,o.useEffect)(()=>{let e=!1;return i().then(t=>{t&&!e&&w.current?.()}),()=>{e=!0}},[]);async function T(t){t.preventDefault(),_(null);let n=m.trim();if(d&&n&&!l.test(n)){_(`That does not look like a mutation token — expected 64 hex characters (leave it empty to unlock later).`);return}y(!0);try{await a(f),p(``),d&&n&&r(n),h(``),e?.()}catch(e){_(e instanceof Error?e.message:`Could not establish a session.`),b.current?.select()}finally{y(!1)}}return(0,c.jsx)(`div`,{className:s.wrap,children:(0,c.jsxs)(`div`,{className:s.card,children:[(0,c.jsx)(`div`,{className:s.badge,"aria-hidden":`true`,children:`⛺`}),(0,c.jsx)(`h1`,{className:s.heading,children:t}),(0,c.jsxs)(`p`,{className:s.body,children:[u,` only ever talks to the ashlr server running on this machine (`,(0,c.jsx)(`code`,{children:`127.0.0.1`}),`, never a remote host). To read data, paste the`,` `,(0,c.jsx)(`strong`,{children:`read token`}),` printed in the terminal where you ran:`]}),(0,c.jsx)(`pre`,{className:s.code,children:n}),(0,c.jsxs)(`p`,{className:s.body,children:[`It looks like a 64-character hex string, printed once at startup — something like`,` `,(0,c.jsx)(`code`,{className:s.example,children:`a1b2c3…`}),`. This dialog never stores it: it is exchanged once for a short-lived session cookie, then discarded.`]}),(0,c.jsxs)(`form`,{onSubmit:T,className:s.form,noValidate:!0,children:[(0,c.jsx)(`label`,{htmlFor:x,className:s.label,children:`Read token`}),(0,c.jsx)(`input`,{ref:b,id:x,name:`read-token`,type:`password`,autoComplete:`off`,autoCorrect:`off`,spellCheck:!1,inputMode:`text`,className:s.input,value:f,onChange:e=>p(e.target.value),"aria-invalid":g?!0:void 0,"aria-describedby":g?C:void 0,placeholder:`64 hex characters`,autoFocus:!0}),d?(0,c.jsxs)(c.Fragment,{children:[(0,c.jsxs)(`label`,{htmlFor:S,className:s.label,children:[`Mutation token `,(0,c.jsx)(`span`,{className:s.optional,children:`optional — paste it now to enable sending`})]}),(0,c.jsx)(`input`,{id:S,name:`mutation-token`,type:`password`,autoComplete:`off`,autoCorrect:`off`,spellCheck:!1,inputMode:`text`,className:s.input,value:m,onChange:e=>h(e.target.value),placeholder:`64 hex characters, printed under “Dispatch enabled”`})]}):null,g?(0,c.jsx)(`p`,{id:C,className:s.error,role:`alert`,children:g}):null,(0,c.jsx)(`button`,{type:`submit`,className:s.submit,disabled:v||f.trim().length===0,children:v?`Connecting…`:`Connect`})]})]})})}export{u as SessionGate};
2
+ //# sourceMappingURL=SessionGate-WROS02tK.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SessionGate-8RtQFWeZ.js","names":[],"sources":["../../../../../../src/web-ui/components/auth/SessionGate.module.css","../../../../../../src/web-ui/components/auth/SessionGate.tsx"],"sourcesContent":[".wrap {\n min-height: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n padding: var(--space-6);\n background: var(--bg-canvas);\n}\n\n.card {\n width: min(480px, 100%);\n background: var(--bg-surface);\n border: 1px solid var(--border-default);\n border-radius: var(--radius-xl);\n box-shadow: var(--shadow-lg);\n padding: var(--space-8);\n}\n\n.badge {\n font-size: 28px;\n margin-bottom: var(--space-4);\n}\n\n.heading {\n font-size: var(--text-2xl-size);\n line-height: var(--text-2xl-line);\n font-weight: var(--font-weight-semibold);\n margin-bottom: var(--space-3);\n}\n\n.body {\n font-size: var(--text-sm-size);\n line-height: var(--text-sm-line);\n color: var(--text-secondary);\n margin-bottom: var(--space-3);\n}\n\n.code {\n font-family: var(--font-mono);\n font-size: var(--text-sm-size);\n background: var(--bg-code);\n border: 1px solid var(--border-subtle);\n border-radius: var(--radius-sm);\n padding: var(--space-3);\n margin-bottom: var(--space-3);\n overflow-x: auto;\n}\n\n.example {\n font-family: var(--font-mono);\n background: var(--bg-code);\n padding: 1px 4px;\n border-radius: var(--radius-xs);\n}\n\n.form {\n display: flex;\n flex-direction: column;\n gap: var(--space-2);\n margin-top: var(--space-5);\n}\n\n.label {\n font-size: var(--text-sm-size);\n font-weight: var(--font-weight-medium);\n}\n\n.input {\n padding: var(--space-3);\n border-radius: var(--radius-md);\n border: 1px solid var(--border-default);\n background: var(--bg-input);\n font-family: var(--font-mono);\n font-size: var(--text-sm-size);\n}\n\n.input:focus-visible {\n border-color: var(--border-focus);\n box-shadow: var(--shadow-focus-ring);\n}\n\n.error {\n color: var(--status-danger-fg);\n font-size: var(--text-sm-size);\n}\n\n.submit {\n margin-top: var(--space-2);\n padding: var(--space-3) var(--space-4);\n background: var(--accent-500);\n color: var(--text-on-accent);\n border-radius: var(--radius-md);\n font-weight: var(--font-weight-medium);\n text-align: center;\n transition: background var(--duration-fast) var(--ease-standard);\n}\n\n.submit:hover:not(:disabled) {\n background: var(--accent-600);\n}\n\n.submit:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.optional { font-weight: var(--font-weight-normal, 400); color: var(--text-tertiary); }\n","/**\n * components/auth/SessionGate.tsx — replaces the old bare \"⚠ HTTP 401 +\n * Retry\" first-run experience (foundation brief item 5). Shown whenever\n * auth-store's phase is 'unauthenticated': on first load before any read\n * token has been entered, AND any time a session expires mid-use (SSE\n * disconnects, the next GET reports 401).\n *\n * By default this screen owns nothing about the MUTATION token — that is a\n * separate, later step (MutationTokenDialog), because read authority and\n * dispatch authority are genuinely different capabilities on this server\n * (see server.ts). Surfaces where sending is the whole point (Verse) can opt\n * into an optional second field with `mutationField`; the authorities stay\n * separate (the mutation token only ever enters the memory-only hold), it\n * just spares the operator a second paste screen on the first Enter.\n */\nimport { useEffect, useId, useRef, useState, type FormEvent } from 'react';\nimport { adoptInjectedTokens, establishReadSession, setMutationToken } from '../../data/auth-store.js';\nimport styles from './SessionGate.module.css';\n\nconst TOKEN_RE = /^[a-f0-9]{64}$/;\n\nexport interface SessionGateProps {\n onAuthenticated?: () => void;\n heading?: string;\n command?: string;\n /** What the copy calls this surface (\"This dashboard\", \"Ashlr Verse\"). */\n subject?: string;\n /**\n * Also offer the mutation token on the same screen. The two authorities\n * stay separate (a pasted mutation token goes straight into the memory-only\n * hold, exactly as MutationTokenDialog would set it); this only collapses\n * two paste screens into one for surfaces where sending is the whole point.\n */\n mutationField?: boolean;\n}\n\nexport function SessionGate({ onAuthenticated, heading = 'Connect to ashlr serve', command = 'ashlr serve', subject = 'This dashboard', mutationField = false }: SessionGateProps) {\n const [token, setToken] = useState('');\n const [mutation, setMutation] = useState('');\n const [error, setError] = useState<string | null>(null);\n const [busy, setBusy] = useState(false);\n const inputRef = useRef<HTMLInputElement>(null);\n const inputId = useId();\n const mutationId = useId();\n const errorId = useId();\n const authenticatedRef = useRef(onAuthenticated);\n authenticatedRef.current = onAuthenticated;\n\n // Desktop wrapper: when the host injected tokens (window.__ASHLR_TOKENS__),\n // establish the session silently instead of asking for a paste.\n useEffect(() => {\n let cancelled = false;\n void adoptInjectedTokens().then((adopted) => {\n if (adopted && !cancelled) authenticatedRef.current?.();\n });\n return () => { cancelled = true; };\n }, []);\n\n async function onSubmit(e: FormEvent) {\n e.preventDefault();\n setError(null);\n const mutationTrimmed = mutation.trim();\n if (mutationField && mutationTrimmed && !TOKEN_RE.test(mutationTrimmed)) {\n setError('That does not look like a mutation token — expected 64 hex characters (leave it empty to unlock later).');\n return;\n }\n setBusy(true);\n try {\n await establishReadSession(token);\n setToken('');\n if (mutationField && mutationTrimmed) setMutationToken(mutationTrimmed);\n setMutation('');\n onAuthenticated?.();\n } catch (err) {\n setError(err instanceof Error ? err.message : 'Could not establish a session.');\n inputRef.current?.select();\n } finally {\n setBusy(false);\n }\n }\n\n return (\n <div className={styles.wrap}>\n <div className={styles.card}>\n <div className={styles.badge} aria-hidden=\"true\">\n ⛺\n </div>\n <h1 className={styles.heading}>{heading}</h1>\n <p className={styles.body}>\n {subject} only ever talks to the ashlr server running on this machine\n (<code>127.0.0.1</code>, never a remote host). To read data, paste the{' '}\n <strong>read token</strong> printed in the terminal where you ran:\n </p>\n <pre className={styles.code}>{command}</pre>\n <p className={styles.body}>\n It looks like a 64-character hex string, printed once at startup — something like{' '}\n <code className={styles.example}>a1b2c3…</code>. This dialog never stores it: it is\n exchanged once for a short-lived session cookie, then discarded.\n </p>\n <form onSubmit={onSubmit} className={styles.form} noValidate>\n <label htmlFor={inputId} className={styles.label}>\n Read token\n </label>\n <input\n ref={inputRef}\n id={inputId}\n name=\"read-token\"\n type=\"password\"\n autoComplete=\"off\"\n autoCorrect=\"off\"\n spellCheck={false}\n inputMode=\"text\"\n className={styles.input}\n value={token}\n onChange={(e) => setToken(e.target.value)}\n aria-invalid={error ? true : undefined}\n aria-describedby={error ? errorId : undefined}\n placeholder=\"64 hex characters\"\n autoFocus\n />\n {mutationField ? (\n <>\n <label htmlFor={mutationId} className={styles.label}>\n Mutation token <span className={styles.optional}>optional — paste it now to enable sending</span>\n </label>\n <input\n id={mutationId}\n name=\"mutation-token\"\n type=\"password\"\n autoComplete=\"off\"\n autoCorrect=\"off\"\n spellCheck={false}\n inputMode=\"text\"\n className={styles.input}\n value={mutation}\n onChange={(e) => setMutation(e.target.value)}\n placeholder=\"64 hex characters, printed under “Dispatch enabled”\"\n />\n </>\n ) : null}\n {error ? (\n <p id={errorId} className={styles.error} role=\"alert\">\n {error}\n </p>\n ) : null}\n <button type=\"submit\" className={styles.submit} disabled={busy || token.trim().length === 0}>\n {busy ? 'Connecting…' : 'Connect'}\n </button>\n </form>\n </div>\n </div>\n );\n}\n"],"mappings":"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"}
1
+ {"version":3,"file":"SessionGate-WROS02tK.js","names":[],"sources":["../../../../../../src/web-ui/components/auth/SessionGate.module.css","../../../../../../src/web-ui/components/auth/SessionGate.tsx"],"sourcesContent":[".wrap {\n min-height: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n padding: var(--space-6);\n background: var(--bg-canvas);\n}\n\n.card {\n width: min(480px, 100%);\n background: var(--bg-surface);\n border: 1px solid var(--border-default);\n border-radius: var(--radius-xl);\n box-shadow: var(--shadow-lg);\n padding: var(--space-8);\n}\n\n.badge {\n font-size: 28px;\n margin-bottom: var(--space-4);\n}\n\n.heading {\n font-size: var(--text-2xl-size);\n line-height: var(--text-2xl-line);\n font-weight: var(--font-weight-semibold);\n margin-bottom: var(--space-3);\n}\n\n.body {\n font-size: var(--text-sm-size);\n line-height: var(--text-sm-line);\n color: var(--text-secondary);\n margin-bottom: var(--space-3);\n}\n\n.code {\n font-family: var(--font-mono);\n font-size: var(--text-sm-size);\n background: var(--bg-code);\n border: 1px solid var(--border-subtle);\n border-radius: var(--radius-sm);\n padding: var(--space-3);\n margin-bottom: var(--space-3);\n overflow-x: auto;\n}\n\n.example {\n font-family: var(--font-mono);\n background: var(--bg-code);\n padding: 1px 4px;\n border-radius: var(--radius-xs);\n}\n\n.form {\n display: flex;\n flex-direction: column;\n gap: var(--space-2);\n margin-top: var(--space-5);\n}\n\n.label {\n font-size: var(--text-sm-size);\n font-weight: var(--font-weight-medium);\n}\n\n.input {\n padding: var(--space-3);\n border-radius: var(--radius-md);\n border: 1px solid var(--border-default);\n background: var(--bg-input);\n font-family: var(--font-mono);\n font-size: var(--text-sm-size);\n}\n\n.input:focus-visible {\n border-color: var(--border-focus);\n box-shadow: var(--shadow-focus-ring);\n}\n\n.error {\n color: var(--status-danger-fg);\n font-size: var(--text-sm-size);\n}\n\n.submit {\n margin-top: var(--space-2);\n padding: var(--space-3) var(--space-4);\n background: var(--accent-500);\n color: var(--text-on-accent);\n border-radius: var(--radius-md);\n font-weight: var(--font-weight-medium);\n text-align: center;\n transition: background var(--duration-fast) var(--ease-standard);\n}\n\n.submit:hover:not(:disabled) {\n background: var(--accent-600);\n}\n\n.submit:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.optional { font-weight: var(--font-weight-normal, 400); color: var(--text-tertiary); }\n","/**\n * components/auth/SessionGate.tsx — replaces the old bare \"⚠ HTTP 401 +\n * Retry\" first-run experience (foundation brief item 5). Shown whenever\n * auth-store's phase is 'unauthenticated': on first load before any read\n * token has been entered, AND any time a session expires mid-use (SSE\n * disconnects, the next GET reports 401).\n *\n * By default this screen owns nothing about the MUTATION token — that is a\n * separate, later step (MutationTokenDialog), because read authority and\n * dispatch authority are genuinely different capabilities on this server\n * (see server.ts). Surfaces where sending is the whole point (Verse) can opt\n * into an optional second field with `mutationField`; the authorities stay\n * separate (the mutation token only ever enters the memory-only hold), it\n * just spares the operator a second paste screen on the first Enter.\n */\nimport { useEffect, useId, useRef, useState, type FormEvent } from 'react';\nimport { adoptInjectedTokens, establishReadSession, setMutationToken } from '../../data/auth-store.js';\nimport styles from './SessionGate.module.css';\n\nconst TOKEN_RE = /^[a-f0-9]{64}$/;\n\nexport interface SessionGateProps {\n onAuthenticated?: () => void;\n heading?: string;\n command?: string;\n /** What the copy calls this surface (\"This dashboard\", \"Ashlr Verse\"). */\n subject?: string;\n /**\n * Also offer the mutation token on the same screen. The two authorities\n * stay separate (a pasted mutation token goes straight into the memory-only\n * hold, exactly as MutationTokenDialog would set it); this only collapses\n * two paste screens into one for surfaces where sending is the whole point.\n */\n mutationField?: boolean;\n}\n\nexport function SessionGate({ onAuthenticated, heading = 'Connect to ashlr serve', command = 'ashlr serve', subject = 'This dashboard', mutationField = false }: SessionGateProps) {\n const [token, setToken] = useState('');\n const [mutation, setMutation] = useState('');\n const [error, setError] = useState<string | null>(null);\n const [busy, setBusy] = useState(false);\n const inputRef = useRef<HTMLInputElement>(null);\n const inputId = useId();\n const mutationId = useId();\n const errorId = useId();\n const authenticatedRef = useRef(onAuthenticated);\n authenticatedRef.current = onAuthenticated;\n\n // Desktop wrapper: when the host injected tokens (window.__ASHLR_TOKENS__),\n // establish the session silently instead of asking for a paste.\n useEffect(() => {\n let cancelled = false;\n void adoptInjectedTokens().then((adopted) => {\n if (adopted && !cancelled) authenticatedRef.current?.();\n });\n return () => { cancelled = true; };\n }, []);\n\n async function onSubmit(e: FormEvent) {\n e.preventDefault();\n setError(null);\n const mutationTrimmed = mutation.trim();\n if (mutationField && mutationTrimmed && !TOKEN_RE.test(mutationTrimmed)) {\n setError('That does not look like a mutation token — expected 64 hex characters (leave it empty to unlock later).');\n return;\n }\n setBusy(true);\n try {\n await establishReadSession(token);\n setToken('');\n if (mutationField && mutationTrimmed) setMutationToken(mutationTrimmed);\n setMutation('');\n onAuthenticated?.();\n } catch (err) {\n setError(err instanceof Error ? err.message : 'Could not establish a session.');\n inputRef.current?.select();\n } finally {\n setBusy(false);\n }\n }\n\n return (\n <div className={styles.wrap}>\n <div className={styles.card}>\n <div className={styles.badge} aria-hidden=\"true\">\n ⛺\n </div>\n <h1 className={styles.heading}>{heading}</h1>\n <p className={styles.body}>\n {subject} only ever talks to the ashlr server running on this machine\n (<code>127.0.0.1</code>, never a remote host). To read data, paste the{' '}\n <strong>read token</strong> printed in the terminal where you ran:\n </p>\n <pre className={styles.code}>{command}</pre>\n <p className={styles.body}>\n It looks like a 64-character hex string, printed once at startup — something like{' '}\n <code className={styles.example}>a1b2c3…</code>. This dialog never stores it: it is\n exchanged once for a short-lived session cookie, then discarded.\n </p>\n <form onSubmit={onSubmit} className={styles.form} noValidate>\n <label htmlFor={inputId} className={styles.label}>\n Read token\n </label>\n <input\n ref={inputRef}\n id={inputId}\n name=\"read-token\"\n type=\"password\"\n autoComplete=\"off\"\n autoCorrect=\"off\"\n spellCheck={false}\n inputMode=\"text\"\n className={styles.input}\n value={token}\n onChange={(e) => setToken(e.target.value)}\n aria-invalid={error ? true : undefined}\n aria-describedby={error ? errorId : undefined}\n placeholder=\"64 hex characters\"\n autoFocus\n />\n {mutationField ? (\n <>\n <label htmlFor={mutationId} className={styles.label}>\n Mutation token <span className={styles.optional}>optional — paste it now to enable sending</span>\n </label>\n <input\n id={mutationId}\n name=\"mutation-token\"\n type=\"password\"\n autoComplete=\"off\"\n autoCorrect=\"off\"\n spellCheck={false}\n inputMode=\"text\"\n className={styles.input}\n value={mutation}\n onChange={(e) => setMutation(e.target.value)}\n placeholder=\"64 hex characters, printed under “Dispatch enabled”\"\n />\n </>\n ) : null}\n {error ? (\n <p id={errorId} className={styles.error} role=\"alert\">\n {error}\n </p>\n ) : null}\n <button type=\"submit\" className={styles.submit} disabled={busy || token.trim().length === 0}>\n {busy ? 'Connecting…' : 'Connect'}\n </button>\n </form>\n </div>\n </div>\n );\n}\n"],"mappings":"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"}
@@ -1,2 +1,2 @@
1
- import{a as e,c as t,n}from"./index-BG177cPN.js";import{p as r}from"./global-CXHHMz9o.js";import{u as i}from"./format-DEAaVF6X.js";import{n as a}from"./nav-CmZcbPFJ.js";import{d as o}from"./surface-data-DshUC_TU.js";import{n as s,o as c,t as l}from"./mind.module-D_xk6HIQ.js";var u=t(e(),1),d=n();function f({sessionId:e}){let t=r(o,{freshMs:6e4}),[n,f]=(0,u.useState)(!1),p=(0,u.useId)(),m=c(t.data?.value??null,e);if(m.length===0)return null;let h=m[0],g=`${s[h.kind]} · ${h.count}×`;function _(e){e.key===`Escape`&&n&&(e.stopPropagation(),f(!1))}return(0,d.jsxs)(`span`,{className:l.chipWrap,onKeyDown:_,children:[(0,d.jsxs)(`button`,{type:`button`,className:l.chip,"data-severity":h.severity,"aria-expanded":n,"aria-controls":p,"aria-label":`Reasoning insight for this chat: ${h.title}${m.length>1?` and ${m.length-1} more`:``}`,onClick:()=>f(e=>!e),children:[(0,d.jsx)(`span`,{className:l.chipDot,"data-severity":h.severity,"aria-hidden":`true`}),g,m.length>1?(0,d.jsxs)(`span`,{className:l.chipMore,children:[`+`,m.length-1]}):null]}),n?(0,d.jsxs)(`div`,{id:p,className:l.chipPanel,role:`region`,"aria-label":`Insights for this chat`,children:[(0,d.jsx)(`ul`,{className:l.chipList,children:m.map(e=>(0,d.jsxs)(`li`,{children:[(0,d.jsx)(`span`,{className:l.insightTitle,children:e.title}),(0,d.jsxs)(`span`,{className:l.insightMeta,children:[s[e.kind],` · `,e.count,`× · last seen `,i(e.lastAt)]})]},e.id))}),(0,d.jsx)(`button`,{type:`button`,className:l.link,onClick:()=>{f(!1),a(`mind`,`insight-${h.id}`)},children:`See it in Mind`})]}):null]})}export{f as SessionInsightChip};
2
- //# sourceMappingURL=SessionInsightChip-zBJbKv2L.js.map
1
+ import{a as e,c as t,n}from"./index-CyK31YRm.js";import{m as r}from"./global-y_exIyAP.js";import{u as i}from"./format-BmH2yWL6.js";import{n as a}from"./nav-mimleI0R.js";import{f as o}from"./surface-data-C3UAQ4QX.js";import{n as s,o as c,t as l}from"./mind.module-B15k0Y9q.js";var u=t(e(),1),d=n();function f({sessionId:e}){let t=r(o,{freshMs:6e4}),[n,f]=(0,u.useState)(!1),p=(0,u.useId)(),m=c(t.data?.value??null,e);if(m.length===0)return null;let h=m[0],g=`${s[h.kind]} · ${h.count}×`;function _(e){e.key===`Escape`&&n&&(e.stopPropagation(),f(!1))}return(0,d.jsxs)(`span`,{className:l.chipWrap,onKeyDown:_,children:[(0,d.jsxs)(`button`,{type:`button`,className:l.chip,"data-severity":h.severity,"aria-expanded":n,"aria-controls":p,"aria-label":`Reasoning insight for this chat: ${h.title}${m.length>1?` and ${m.length-1} more`:``}`,onClick:()=>f(e=>!e),children:[(0,d.jsx)(`span`,{className:l.chipDot,"data-severity":h.severity,"aria-hidden":`true`}),g,m.length>1?(0,d.jsxs)(`span`,{className:l.chipMore,children:[`+`,m.length-1]}):null]}),n?(0,d.jsxs)(`div`,{id:p,className:l.chipPanel,role:`region`,"aria-label":`Insights for this chat`,children:[(0,d.jsx)(`ul`,{className:l.chipList,children:m.map(e=>(0,d.jsxs)(`li`,{children:[(0,d.jsx)(`span`,{className:l.insightTitle,children:e.title}),(0,d.jsxs)(`span`,{className:l.insightMeta,children:[s[e.kind],` · `,e.count,`× · last seen `,i(e.lastAt)]})]},e.id))}),(0,d.jsx)(`button`,{type:`button`,className:l.link,onClick:()=>{f(!1),a(`mind`,`insight-${h.id}`)},children:`See it in Mind`})]}):null]})}export{f as SessionInsightChip};
2
+ //# sourceMappingURL=SessionInsightChip-DNUcruwp.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SessionInsightChip-zBJbKv2L.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/mind/SessionInsightChip.tsx"],"sourcesContent":["/**\n * routes/verse/mind/SessionInsightChip.tsx — the chat-header chip (SPEC-310C\n * §5 \"`mind/SessionInsightChip`: Chat's header shows it when an A7 loop or\n * struggle insight cites that chat\"; unit C7). Mounted by C2 through C0's\n * `session-insight-chip` slot, which lazy-loads this file and this named\n * export with exactly SessionInsightChipProps.\n *\n * It renders NOTHING unless the reasoning digest cites this chat in a loop\n * or struggle insight — no placeholder, no spinner, no error text in a chat\n * header (a missing digest is simply no chip). When it shows, it is one\n * quiet chip (\"Loop · npm test ×6\"); pressing it opens a small panel with\n * the insight(s) and a way to Mind. Reads the digest the Mind surface\n * already caches (60 s freshness); it never polls from the chat.\n */\nimport { useId, useState, type KeyboardEvent } from 'react';\nimport { useQuery } from '../../../data/hooks.js';\nimport { formatRelative } from '../autonomy/format.js';\nimport { goToSection } from '../command/nav.js';\nimport { reasoningDigestQuery } from '../command/surface-data.js';\nimport type { SessionInsightChipProps } from '../shell/slots.js';\nimport { KIND_LABEL, sessionInsights } from './mind-model.js';\nimport styles from './mind.module.css';\n\nexport function SessionInsightChip({ sessionId }: SessionInsightChipProps) {\n const digest = useQuery(reasoningDigestQuery, { freshMs: 60_000 });\n const [open, setOpen] = useState(false);\n const panelId = useId();\n const insights = sessionInsights(digest.data?.value ?? null, sessionId);\n if (insights.length === 0) return null;\n const first = insights[0]!;\n const label = `${KIND_LABEL[first.kind]} · ${first.count}×`;\n\n function onKey(e: KeyboardEvent<HTMLElement>): void {\n if (e.key === 'Escape' && open) {\n e.stopPropagation();\n setOpen(false);\n }\n }\n\n return (\n <span className={styles.chipWrap} onKeyDown={onKey}>\n <button\n type=\"button\"\n className={styles.chip}\n data-severity={first.severity}\n aria-expanded={open}\n aria-controls={panelId}\n aria-label={`Reasoning insight for this chat: ${first.title}${insights.length > 1 ? ` and ${insights.length - 1} more` : ''}`}\n onClick={() => setOpen((o) => !o)}\n >\n <span className={styles.chipDot} data-severity={first.severity} aria-hidden=\"true\" />\n {label}\n {insights.length > 1 ? <span className={styles.chipMore}>+{insights.length - 1}</span> : null}\n </button>\n {open ? (\n <div id={panelId} className={styles.chipPanel} role=\"region\" aria-label=\"Insights for this chat\">\n <ul className={styles.chipList}>\n {insights.map((i) => (\n <li key={i.id}>\n <span className={styles.insightTitle}>{i.title}</span>\n <span className={styles.insightMeta}>\n {KIND_LABEL[i.kind]} · {i.count}× · last seen {formatRelative(i.lastAt)}\n </span>\n </li>\n ))}\n </ul>\n <button\n type=\"button\"\n className={styles.link}\n onClick={() => {\n setOpen(false);\n goToSection('mind', `insight-${first.id}`);\n }}\n >\n See it in Mind\n </button>\n </div>\n ) : null}\n </span>\n );\n}\n"],"mappings":"ySAuBA,SAAgB,EAAmB,CAAE,aAAsC,CACzE,IAAM,EAAS,EAAS,EAAsB,CAAE,QAAS,GAAO,CAAC,EAC3D,CAAC,EAAM,IAAA,EAAW,EAAA,SAAA,CAAS,EAAK,EAChC,GAAA,EAAU,EAAA,MAAA,CAAM,EAChB,EAAW,EAAgB,EAAO,MAAM,OAAS,KAAM,CAAS,EACtE,GAAI,EAAS,SAAW,EAAG,OAAO,KAClC,IAAM,EAAQ,EAAS,GACjB,EAAQ,GAAG,EAAW,EAAM,MAAM,KAAK,EAAM,MAAM,GAEzD,SAAS,EAAM,EAAqC,CAC9C,EAAE,MAAQ,UAAY,IACxB,EAAE,gBAAgB,EAClB,EAAQ,EAAK,EAEjB,CAEA,OACE,EAAA,EAAA,KAAA,CAAC,OAAD,CAAM,UAAW,EAAO,SAAU,UAAW,EAA7C,SAAA,EACE,EAAA,EAAA,KAAA,CAAC,SAAD,CACE,KAAK,SACL,UAAW,EAAO,KAClB,gBAAe,EAAM,SACrB,gBAAe,EACf,gBAAe,EACf,aAAY,oCAAoC,EAAM,QAAQ,EAAS,OAAS,EAAI,QAAQ,EAAS,OAAS,EAAE,OAAS,KACzH,YAAe,EAAS,GAAM,CAAC,CAAC,EAPlC,SAAA,EASE,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,UAAW,EAAO,QAAS,gBAAe,EAAM,SAAU,cAAY,MAAQ,CAAA,EACnF,EACA,EAAS,OAAS,GAAI,EAAA,EAAA,KAAA,CAAC,OAAD,CAAM,UAAW,EAAO,SAAxB,SAAA,CAAkC,IAAE,EAAS,OAAS,CAAQ,CAAI,CAAA,EAAA,IACnF,CACP,CAAA,EAAA,GACC,EAAA,EAAA,KAAA,CAAC,MAAD,CAAK,GAAI,EAAS,UAAW,EAAO,UAAW,KAAK,SAAS,aAAW,yBAAxE,SAAA,EACE,EAAA,EAAA,IAAA,CAAC,KAAD,CAAI,UAAW,EAAO,SACnB,SAAA,EAAS,IAAK,IACb,EAAA,EAAA,KAAA,CAAC,KAAD,CAAA,SAAA,EACE,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,UAAW,EAAO,aAAe,SAAA,EAAE,KAAY,CAAA,GACrD,EAAA,EAAA,KAAA,CAAC,OAAD,CAAM,UAAW,EAAO,YAAxB,SAAA,CACG,EAAW,EAAE,MAAM,MAAI,EAAE,MAAM,iBAAe,EAAe,EAAE,MAAM,CAClE,CACJ,CAAA,CAAA,CAAA,EALK,EAAE,EAKP,CACL,CACC,CAAA,GACJ,EAAA,EAAA,IAAA,CAAC,SAAD,CACE,KAAK,SACL,UAAW,EAAO,KAClB,YAAe,CACb,EAAQ,EAAK,EACb,EAAY,OAAQ,WAAW,EAAM,IAAI,CAC3C,EACD,SAAA,gBAEO,CAAA,CACL,CACH,CAAA,EAAA,IACA,GAEV"}
1
+ {"version":3,"file":"SessionInsightChip-DNUcruwp.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/mind/SessionInsightChip.tsx"],"sourcesContent":["/**\n * routes/verse/mind/SessionInsightChip.tsx — the chat-header chip (SPEC-310C\n * §5 \"`mind/SessionInsightChip`: Chat's header shows it when an A7 loop or\n * struggle insight cites that chat\"; unit C7). Mounted by C2 through C0's\n * `session-insight-chip` slot, which lazy-loads this file and this named\n * export with exactly SessionInsightChipProps.\n *\n * It renders NOTHING unless the reasoning digest cites this chat in a loop\n * or struggle insight — no placeholder, no spinner, no error text in a chat\n * header (a missing digest is simply no chip). When it shows, it is one\n * quiet chip (\"Loop · npm test ×6\"); pressing it opens a small panel with\n * the insight(s) and a way to Mind. Reads the digest the Mind surface\n * already caches (60 s freshness); it never polls from the chat.\n */\nimport { useId, useState, type KeyboardEvent } from 'react';\nimport { useQuery } from '../../../data/hooks.js';\nimport { formatRelative } from '../autonomy/format.js';\nimport { goToSection } from '../command/nav.js';\nimport { reasoningDigestQuery } from '../command/surface-data.js';\nimport type { SessionInsightChipProps } from '../shell/slots.js';\nimport { KIND_LABEL, sessionInsights } from './mind-model.js';\nimport styles from './mind.module.css';\n\nexport function SessionInsightChip({ sessionId }: SessionInsightChipProps) {\n const digest = useQuery(reasoningDigestQuery, { freshMs: 60_000 });\n const [open, setOpen] = useState(false);\n const panelId = useId();\n const insights = sessionInsights(digest.data?.value ?? null, sessionId);\n if (insights.length === 0) return null;\n const first = insights[0]!;\n const label = `${KIND_LABEL[first.kind]} · ${first.count}×`;\n\n function onKey(e: KeyboardEvent<HTMLElement>): void {\n if (e.key === 'Escape' && open) {\n e.stopPropagation();\n setOpen(false);\n }\n }\n\n return (\n <span className={styles.chipWrap} onKeyDown={onKey}>\n <button\n type=\"button\"\n className={styles.chip}\n data-severity={first.severity}\n aria-expanded={open}\n aria-controls={panelId}\n aria-label={`Reasoning insight for this chat: ${first.title}${insights.length > 1 ? ` and ${insights.length - 1} more` : ''}`}\n onClick={() => setOpen((o) => !o)}\n >\n <span className={styles.chipDot} data-severity={first.severity} aria-hidden=\"true\" />\n {label}\n {insights.length > 1 ? <span className={styles.chipMore}>+{insights.length - 1}</span> : null}\n </button>\n {open ? (\n <div id={panelId} className={styles.chipPanel} role=\"region\" aria-label=\"Insights for this chat\">\n <ul className={styles.chipList}>\n {insights.map((i) => (\n <li key={i.id}>\n <span className={styles.insightTitle}>{i.title}</span>\n <span className={styles.insightMeta}>\n {KIND_LABEL[i.kind]} · {i.count}× · last seen {formatRelative(i.lastAt)}\n </span>\n </li>\n ))}\n </ul>\n <button\n type=\"button\"\n className={styles.link}\n onClick={() => {\n setOpen(false);\n goToSection('mind', `insight-${first.id}`);\n }}\n >\n See it in Mind\n </button>\n </div>\n ) : null}\n </span>\n );\n}\n"],"mappings":"ySAuBA,SAAgB,EAAmB,CAAE,aAAsC,CACzE,IAAM,EAAS,EAAS,EAAsB,CAAE,QAAS,GAAO,CAAC,EAC3D,CAAC,EAAM,IAAA,EAAW,EAAA,SAAA,CAAS,EAAK,EAChC,GAAA,EAAU,EAAA,MAAA,CAAM,EAChB,EAAW,EAAgB,EAAO,MAAM,OAAS,KAAM,CAAS,EACtE,GAAI,EAAS,SAAW,EAAG,OAAO,KAClC,IAAM,EAAQ,EAAS,GACjB,EAAQ,GAAG,EAAW,EAAM,MAAM,KAAK,EAAM,MAAM,GAEzD,SAAS,EAAM,EAAqC,CAC9C,EAAE,MAAQ,UAAY,IACxB,EAAE,gBAAgB,EAClB,EAAQ,EAAK,EAEjB,CAEA,OACE,EAAA,EAAA,KAAA,CAAC,OAAD,CAAM,UAAW,EAAO,SAAU,UAAW,EAA7C,SAAA,EACE,EAAA,EAAA,KAAA,CAAC,SAAD,CACE,KAAK,SACL,UAAW,EAAO,KAClB,gBAAe,EAAM,SACrB,gBAAe,EACf,gBAAe,EACf,aAAY,oCAAoC,EAAM,QAAQ,EAAS,OAAS,EAAI,QAAQ,EAAS,OAAS,EAAE,OAAS,KACzH,YAAe,EAAS,GAAM,CAAC,CAAC,EAPlC,SAAA,EASE,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,UAAW,EAAO,QAAS,gBAAe,EAAM,SAAU,cAAY,MAAQ,CAAA,EACnF,EACA,EAAS,OAAS,GAAI,EAAA,EAAA,KAAA,CAAC,OAAD,CAAM,UAAW,EAAO,SAAxB,SAAA,CAAkC,IAAE,EAAS,OAAS,CAAQ,CAAI,CAAA,EAAA,IACnF,CACP,CAAA,EAAA,GACC,EAAA,EAAA,KAAA,CAAC,MAAD,CAAK,GAAI,EAAS,UAAW,EAAO,UAAW,KAAK,SAAS,aAAW,yBAAxE,SAAA,EACE,EAAA,EAAA,IAAA,CAAC,KAAD,CAAI,UAAW,EAAO,SACnB,SAAA,EAAS,IAAK,IACb,EAAA,EAAA,KAAA,CAAC,KAAD,CAAA,SAAA,EACE,EAAA,EAAA,IAAA,CAAC,OAAD,CAAM,UAAW,EAAO,aAAe,SAAA,EAAE,KAAY,CAAA,GACrD,EAAA,EAAA,KAAA,CAAC,OAAD,CAAM,UAAW,EAAO,YAAxB,SAAA,CACG,EAAW,EAAE,MAAM,MAAI,EAAE,MAAM,iBAAe,EAAe,EAAE,MAAM,CAClE,CACJ,CAAA,CAAA,CAAA,EALK,EAAE,EAKP,CACL,CACC,CAAA,GACJ,EAAA,EAAA,IAAA,CAAC,SAAD,CACE,KAAK,SACL,UAAW,EAAO,KAClB,YAAe,CACb,EAAQ,EAAK,EACb,EAAY,OAAQ,WAAW,EAAM,IAAI,CAC3C,EACD,SAAA,gBAEO,CAAA,CACL,CACH,CAAA,EAAA,IACA,GAEV"}
@@ -1,2 +1,2 @@
1
- import{a as e,c as t,n}from"./index-BG177cPN.js";import{o as r}from"./global-CXHHMz9o.js";import{l as i}from"./verse-model-CSzzdyu2.js";import{o as a}from"./context-queries-wvcRnV-I.js";import{b as o,p as s,u as c}from"./context-model-2Owp2jYF.js";import{t as l}from"./use-token-gate-DfEja7Wr.js";import{t as u}from"./context.module-BijAfoJw.js";var d=t(e(),1),f=n();function p({onOpenSession:e,query:t,selectedId:n=null}){let p=(0,d.useId)(),m=(0,d.useId)(),h=t===void 0,[g,_]=(0,d.useState)(``),v=(h?g:t).trim(),[y,b]=(0,d.useState)({status:`idle`}),[x,S]=(0,d.useState)(0),C=(0,d.useRef)(!1);(0,d.useEffect)(()=>{if(C.current)return;if(v.length<2){b({status:`idle`});return}let e=new AbortController;b(e=>({status:`loading`,previous:e.status===`ready`?e.response:e.status===`loading`?e.previous:null}));let t=setTimeout(()=>{a(v,30,e.signal).then(t=>{e.signal.aborted||b({status:`ready`,response:t})}).catch(t=>{e.signal.aborted||(t instanceof r&&t.status===404?(C.current=!0,b({status:`unsupported`})):b({status:`error`,message:l(t)}))})},250);return()=>{clearTimeout(t),e.abort()}},[v,x]);let w=h?(0,f.jsxs)(`label`,{className:u.searchBox,htmlFor:p,children:[(0,f.jsx)(`span`,{className:`visually-hidden`,children:`Search messages in every chat`}),(0,f.jsx)(`input`,{id:p,type:`search`,className:u.input,value:g,placeholder:`Search messages`,autoComplete:`off`,spellCheck:!1,onChange:e=>_(e.target.value)})]}):null;if(y.status===`unsupported`)return h?(0,f.jsxs)(`div`,{className:u.search,children:[w,(0,f.jsxs)(`p`,{className:`${u.hint} ${u.searchNote}`,children:[`This server cannot search messages yet — update Ashlr and restart `,(0,f.jsx)(`code`,{children:`ashlr verse`}),`.`]})]}):null;if(y.status===`idle`&&!h)return null;let T=y.status===`ready`?y.response:y.status===`loading`?y.previous:null,E=T?c(T.hits):[],D=o(T?.query??v),O=y.status===`loading`;return(0,f.jsxs)(`section`,{className:u.search,"aria-labelledby":m,"aria-busy":O?!0:void 0,children:[w,(0,f.jsxs)(`h2`,{id:m,className:u.searchHead,children:[(0,f.jsx)(`span`,{children:`In messages`}),T&&!O?(0,f.jsx)(`span`,{className:u.searchCount,"aria-hidden":`true`,children:E.length}):null]}),(0,f.jsx)(`p`,{className:`visually-hidden`,role:`status`,"aria-live":`polite`,children:y.status===`ready`?E.length===0?`No messages match ${v}.`:`${E.length} ${E.length===1?`chat has`:`chats have`} matching messages.`:``}),y.status===`idle`?(0,f.jsx)(`p`,{className:`${u.hint} ${u.searchNote}`,children:`Searches what was said in every chat on this machine. Nothing is sent to a model.`}):y.status===`error`?(0,f.jsxs)(`div`,{className:u.searchError,role:`alert`,children:[(0,f.jsxs)(`span`,{children:[`Could not search messages: `,y.message]}),(0,f.jsx)(`button`,{type:`button`,className:`${u.secondary} ${u.small}`,onClick:()=>S(e=>e+1),children:`Retry`})]}):O&&!T?(0,f.jsx)(`p`,{className:`${u.hint} ${u.searchNote}`,children:`Searching messages…`}):E.length===0?(0,f.jsxs)(`p`,{className:`${u.hint} ${u.searchNote}`,children:[`No messages match “`,v,`”. Try fewer or different words.`]}):(0,f.jsx)(`ul`,{className:u.hits,children:E.map(t=>{let r=s(t.top.snippet,D),a=t.top.kind===`user`?`You`:`Agent`,o=t.count>1?` · ${t.count} matches`:``;return(0,f.jsx)(`li`,{children:(0,f.jsxs)(`button`,{type:`button`,className:`${u.hit} ${u[`engine-${t.engine}`]??``}`,"aria-current":t.sessionId===n?`true`:void 0,"data-session":t.sessionId,"data-engine":t.engine,onClick:()=>e(t.sessionId),children:[(0,f.jsx)(`span`,{className:u.hitMarker,"aria-hidden":`true`}),(0,f.jsx)(`span`,{className:u.hitTitle,title:t.title||`Untitled chat`,children:t.title||`Untitled chat`}),(0,f.jsx)(`time`,{className:u.hitTime,dateTime:t.latestAt,children:i(t.latestAt)}),(0,f.jsxs)(`span`,{className:u.hitSnippet,children:[(0,f.jsxs)(`span`,{className:u.hitWho,children:[a,o,`: `]}),r.map((e,t)=>e.match?(0,f.jsx)(`mark`,{children:e.text},t):(0,f.jsx)(`span`,{children:e.text},t))]})]})},t.sessionId)})}),T&&y.status!==`error`?(0,f.jsxs)(`p`,{className:`${u.hint} ${u.searchNote}`,children:[`Searched `,T.scannedSessions.toLocaleString(),` `,T.scannedSessions===1?`chat`:`chats`,T.truncated?` — the most recent ones only; older chats were not searched.`:`.`]}):null]})}export{p as SessionSearch};
2
- //# sourceMappingURL=SessionSearch-DfJIcxxM.js.map
1
+ import{a as e,c as t,n}from"./index-CyK31YRm.js";import{o as r}from"./global-y_exIyAP.js";import{l as i}from"./verse-model-JTuvRBVK.js";import{o as a}from"./context-queries-_9bFWb9v.js";import{b as o,p as s,u as c}from"./context-model-Bb15chFt.js";import{t as l}from"./use-token-gate-DSNIIpI6.js";import{t as u}from"./context.module-BijAfoJw.js";var d=t(e(),1),f=n();function p({onOpenSession:e,query:t,selectedId:n=null}){let p=(0,d.useId)(),m=(0,d.useId)(),h=t===void 0,[g,_]=(0,d.useState)(``),v=(h?g:t).trim(),[y,b]=(0,d.useState)({status:`idle`}),[x,S]=(0,d.useState)(0),C=(0,d.useRef)(!1);(0,d.useEffect)(()=>{if(C.current)return;if(v.length<2){b({status:`idle`});return}let e=new AbortController;b(e=>({status:`loading`,previous:e.status===`ready`?e.response:e.status===`loading`?e.previous:null}));let t=setTimeout(()=>{a(v,30,e.signal).then(t=>{e.signal.aborted||b({status:`ready`,response:t})}).catch(t=>{e.signal.aborted||(t instanceof r&&t.status===404?(C.current=!0,b({status:`unsupported`})):b({status:`error`,message:l(t)}))})},250);return()=>{clearTimeout(t),e.abort()}},[v,x]);let w=h?(0,f.jsxs)(`label`,{className:u.searchBox,htmlFor:p,children:[(0,f.jsx)(`span`,{className:`visually-hidden`,children:`Search messages in every chat`}),(0,f.jsx)(`input`,{id:p,type:`search`,className:u.input,value:g,placeholder:`Search messages`,autoComplete:`off`,spellCheck:!1,onChange:e=>_(e.target.value)})]}):null;if(y.status===`unsupported`)return h?(0,f.jsxs)(`div`,{className:u.search,children:[w,(0,f.jsxs)(`p`,{className:`${u.hint} ${u.searchNote}`,children:[`This server cannot search messages yet — update Ashlr and restart `,(0,f.jsx)(`code`,{children:`ashlr verse`}),`.`]})]}):null;if(y.status===`idle`&&!h)return null;let T=y.status===`ready`?y.response:y.status===`loading`?y.previous:null,E=T?c(T.hits):[],D=o(T?.query??v),O=y.status===`loading`;return(0,f.jsxs)(`section`,{className:u.search,"aria-labelledby":m,"aria-busy":O?!0:void 0,children:[w,(0,f.jsxs)(`h2`,{id:m,className:u.searchHead,children:[(0,f.jsx)(`span`,{children:`In messages`}),T&&!O?(0,f.jsx)(`span`,{className:u.searchCount,"aria-hidden":`true`,children:E.length}):null]}),(0,f.jsx)(`p`,{className:`visually-hidden`,role:`status`,"aria-live":`polite`,children:y.status===`ready`?E.length===0?`No messages match ${v}.`:`${E.length} ${E.length===1?`chat has`:`chats have`} matching messages.`:``}),y.status===`idle`?(0,f.jsx)(`p`,{className:`${u.hint} ${u.searchNote}`,children:`Searches what was said in every chat on this machine. Nothing is sent to a model.`}):y.status===`error`?(0,f.jsxs)(`div`,{className:u.searchError,role:`alert`,children:[(0,f.jsxs)(`span`,{children:[`Could not search messages: `,y.message]}),(0,f.jsx)(`button`,{type:`button`,className:`${u.secondary} ${u.small}`,onClick:()=>S(e=>e+1),children:`Retry`})]}):O&&!T?(0,f.jsx)(`p`,{className:`${u.hint} ${u.searchNote}`,children:`Searching messages…`}):E.length===0?(0,f.jsxs)(`p`,{className:`${u.hint} ${u.searchNote}`,children:[`No messages match “`,v,`”. Try fewer or different words.`]}):(0,f.jsx)(`ul`,{className:u.hits,children:E.map(t=>{let r=s(t.top.snippet,D),a=t.top.kind===`user`?`You`:`Agent`,o=t.count>1?` · ${t.count} matches`:``;return(0,f.jsx)(`li`,{children:(0,f.jsxs)(`button`,{type:`button`,className:`${u.hit} ${u[`engine-${t.engine}`]??``}`,"aria-current":t.sessionId===n?`true`:void 0,"data-session":t.sessionId,"data-engine":t.engine,onClick:()=>e(t.sessionId),children:[(0,f.jsx)(`span`,{className:u.hitMarker,"aria-hidden":`true`}),(0,f.jsx)(`span`,{className:u.hitTitle,title:t.title||`Untitled chat`,children:t.title||`Untitled chat`}),(0,f.jsx)(`time`,{className:u.hitTime,dateTime:t.latestAt,children:i(t.latestAt)}),(0,f.jsxs)(`span`,{className:u.hitSnippet,children:[(0,f.jsxs)(`span`,{className:u.hitWho,children:[a,o,`: `]}),r.map((e,t)=>e.match?(0,f.jsx)(`mark`,{children:e.text},t):(0,f.jsx)(`span`,{children:e.text},t))]})]})},t.sessionId)})}),T&&y.status!==`error`?(0,f.jsxs)(`p`,{className:`${u.hint} ${u.searchNote}`,children:[`Searched `,T.scannedSessions.toLocaleString(),` `,T.scannedSessions===1?`chat`:`chats`,T.truncated?` — the most recent ones only; older chats were not searched.`:`.`]}):null]})}export{p as SessionSearch};
2
+ //# sourceMappingURL=SessionSearch-UHtt7a8f.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SessionSearch-DfJIcxxM.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/context/SessionSearch.tsx"],"sourcesContent":["/**\n * routes/verse/context/SessionSearch.tsx — find a past chat by what was SAID\n * in it, not only by its title.\n *\n * The sidebar's field has always filtered chat titles and project paths on\n * the client, instantly. Titles are the first line of the first message, so\n * \"where did we decide the retry policy?\" was unanswerable without opening\n * chats one by one. This component answers it: a keyword search over every\n * session's user and assistant messages (GET /api/verse/search — a bounded\n * scan of events.jsonl on this machine; nothing is sent to a model).\n *\n * TWO WAYS TO MOUNT, one behaviour:\n *\n * - Controlled (`query` given): the sidebar passes ITS field's value, so one\n * box drives both the instant title filter above and the message matches\n * below. No second box — two search fields stacked in a 240px sidebar\n * would make the operator guess which one to type in.\n * - Standalone (`query` absent): renders its own field, for any surface that\n * has no search box of its own.\n *\n * One row per CHAT (the server ranks messages; the list ranks chats), with the\n * best-matching snippet and its terms marked. A query under two characters\n * asks nothing: a one-letter scan of every transcript is noise, not recall.\n * An older server without the route answers 404; the section then stays\n * silent rather than printing a permanent error for a feature that server\n * does not have — the title filter above still works.\n */\nimport { useEffect, useId, useRef, useState } from 'react';\nimport type { VerseSearchResponse } from '../../../../core/verse/types.js';\nimport { ApiError } from '../../../data/client.js';\nimport { formatRelative } from '../verse-model.js';\nimport {\n groupSearchHits,\n highlightSegments,\n searchTerms,\n SEARCH_DEBOUNCE_MS,\n SEARCH_LIMIT,\n SEARCH_MIN_CHARS,\n} from './context-model.js';\nimport { searchSessions } from './context-queries.js';\nimport { describeContextError } from './use-token-gate.js';\nimport styles from './context.module.css';\n\nexport interface SessionSearchProps {\n onOpenSession: (id: string) => void;\n /**\n * The query, when a surrounding field owns it (the sidebar). Absent → this\n * component renders its own field.\n */\n query?: string;\n /** The chat that is open, marked with aria-current like the sidebar's rows. */\n selectedId?: string | null;\n}\n\ntype SearchState =\n | { status: 'idle' }\n | { status: 'loading'; previous: VerseSearchResponse | null }\n | { status: 'ready'; response: VerseSearchResponse }\n | { status: 'error'; message: string }\n | { status: 'unsupported' };\n\nexport function SessionSearch({ onOpenSession, query, selectedId = null }: SessionSearchProps) {\n const inputId = useId();\n const headingId = useId();\n const standalone = query === undefined;\n const [own, setOwn] = useState('');\n const q = (standalone ? own : query).trim();\n const [state, setState] = useState<SearchState>({ status: 'idle' });\n const [retry, setRetry] = useState(0);\n /** Once the server has said it has no search route, stop asking for this mount's lifetime. */\n const unsupported = useRef(false);\n\n useEffect(() => {\n if (unsupported.current) return undefined;\n if (q.length < SEARCH_MIN_CHARS) {\n setState({ status: 'idle' });\n return undefined;\n }\n const controller = new AbortController();\n // Keep the previous answer on screen while the next one is fetched: a list\n // that blanks on every keystroke is harder to read than a slightly stale one.\n setState((prev) => ({\n status: 'loading',\n previous: prev.status === 'ready' ? prev.response : prev.status === 'loading' ? prev.previous : null,\n }));\n const timer = setTimeout(() => {\n searchSessions(q, SEARCH_LIMIT, controller.signal)\n .then((response) => {\n if (!controller.signal.aborted) setState({ status: 'ready', response });\n })\n .catch((err: unknown) => {\n if (controller.signal.aborted) return;\n if (err instanceof ApiError && err.status === 404) {\n unsupported.current = true;\n setState({ status: 'unsupported' });\n }\n else setState({ status: 'error', message: describeContextError(err) });\n });\n }, SEARCH_DEBOUNCE_MS);\n return () => {\n clearTimeout(timer);\n controller.abort();\n };\n }, [q, retry]);\n\n const field = standalone ? (\n <label className={styles.searchBox} htmlFor={inputId}>\n <span className=\"visually-hidden\">Search messages in every chat</span>\n <input id={inputId} type=\"search\" className={styles.input} value={own} placeholder=\"Search messages\"\n autoComplete=\"off\" spellCheck={false} onChange={(event) => setOwn(event.target.value)} />\n </label>\n ) : null;\n\n // Controlled and idle (the sidebar's field is empty or too short), or a\n // server without the route: nothing to say — the title list above is the\n // whole answer. A standalone field has no title list, so it says why.\n if (state.status === 'unsupported') {\n return standalone ? (\n <div className={styles.search}>\n {field}\n <p className={`${styles.hint} ${styles.searchNote}`}>This server cannot search messages yet — update Ashlr and restart <code>ashlr verse</code>.</p>\n </div>\n ) : null;\n }\n if (state.status === 'idle' && !standalone) return null;\n\n const response = state.status === 'ready' ? state.response : state.status === 'loading' ? state.previous : null;\n const groups = response ? groupSearchHits(response.hits) : [];\n const terms = searchTerms(response?.query ?? q);\n const busy = state.status === 'loading';\n\n return (\n <section className={styles.search} aria-labelledby={headingId} aria-busy={busy ? true : undefined}>\n {field}\n <h2 id={headingId} className={styles.searchHead}>\n <span>In messages</span>\n {response && !busy ? (\n <span className={styles.searchCount} aria-hidden=\"true\">{groups.length}</span>\n ) : null}\n </h2>\n\n {/* Announced once per answer, not per keystroke. */}\n <p className=\"visually-hidden\" role=\"status\" aria-live=\"polite\">\n {state.status === 'ready'\n ? groups.length === 0 ? `No messages match ${q}.` : `${groups.length} ${groups.length === 1 ? 'chat has' : 'chats have'} matching messages.`\n : ''}\n </p>\n\n {state.status === 'idle' ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>\n Searches what was said in every chat on this machine. Nothing is sent to a model.\n </p>\n ) : state.status === 'error' ? (\n <div className={styles.searchError} role=\"alert\">\n <span>Could not search messages: {state.message}</span>\n <button type=\"button\" className={`${styles.secondary} ${styles.small}`} onClick={() => setRetry((n) => n + 1)}>\n Retry\n </button>\n </div>\n ) : busy && !response ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>Searching messages…</p>\n ) : groups.length === 0 ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>No messages match “{q}”. Try fewer or different words.</p>\n ) : (\n <ul className={styles.hits}>\n {groups.map((group) => {\n const segments = highlightSegments(group.top.snippet, terms);\n const who = group.top.kind === 'user' ? 'You' : 'Agent';\n const more = group.count > 1 ? ` · ${group.count} matches` : '';\n return (\n <li key={group.sessionId}>\n <button type=\"button\" className={`${styles.hit} ${styles[`engine-${group.engine}`] ?? ''}`}\n aria-current={group.sessionId === selectedId ? 'true' : undefined}\n data-session={group.sessionId} data-engine={group.engine}\n onClick={() => onOpenSession(group.sessionId)}>\n <span className={styles.hitMarker} aria-hidden=\"true\" />\n {/* The title truncates to one line, so it carries itself in full as a tooltip. */}\n <span className={styles.hitTitle} title={group.title || 'Untitled chat'}>{group.title || 'Untitled chat'}</span>\n <time className={styles.hitTime} dateTime={group.latestAt}>{formatRelative(group.latestAt)}</time>\n <span className={styles.hitSnippet}>\n <span className={styles.hitWho}>{who}{more}: </span>\n {segments.map((segment, index) => (segment.match\n ? <mark key={index}>{segment.text}</mark>\n : <span key={index}>{segment.text}</span>))}\n </span>\n </button>\n </li>\n );\n })}\n </ul>\n )}\n\n {response && state.status !== 'error' ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>\n Searched {response.scannedSessions.toLocaleString()} {response.scannedSessions === 1 ? 'chat' : 'chats'}\n {response.truncated ? ' — the most recent ones only; older chats were not searched.' : '.'}\n </p>\n ) : null}\n </section>\n );\n}\n"],"mappings":"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"}
1
+ {"version":3,"file":"SessionSearch-UHtt7a8f.js","names":[],"sources":["../../../../../../src/web-ui/routes/verse/context/SessionSearch.tsx"],"sourcesContent":["/**\n * routes/verse/context/SessionSearch.tsx — find a past chat by what was SAID\n * in it, not only by its title.\n *\n * The sidebar's field has always filtered chat titles and project paths on\n * the client, instantly. Titles are the first line of the first message, so\n * \"where did we decide the retry policy?\" was unanswerable without opening\n * chats one by one. This component answers it: a keyword search over every\n * session's user and assistant messages (GET /api/verse/search — a bounded\n * scan of events.jsonl on this machine; nothing is sent to a model).\n *\n * TWO WAYS TO MOUNT, one behaviour:\n *\n * - Controlled (`query` given): the sidebar passes ITS field's value, so one\n * box drives both the instant title filter above and the message matches\n * below. No second box — two search fields stacked in a 240px sidebar\n * would make the operator guess which one to type in.\n * - Standalone (`query` absent): renders its own field, for any surface that\n * has no search box of its own.\n *\n * One row per CHAT (the server ranks messages; the list ranks chats), with the\n * best-matching snippet and its terms marked. A query under two characters\n * asks nothing: a one-letter scan of every transcript is noise, not recall.\n * An older server without the route answers 404; the section then stays\n * silent rather than printing a permanent error for a feature that server\n * does not have — the title filter above still works.\n */\nimport { useEffect, useId, useRef, useState } from 'react';\nimport type { VerseSearchResponse } from '../../../../core/verse/types.js';\nimport { ApiError } from '../../../data/client.js';\nimport { formatRelative } from '../verse-model.js';\nimport {\n groupSearchHits,\n highlightSegments,\n searchTerms,\n SEARCH_DEBOUNCE_MS,\n SEARCH_LIMIT,\n SEARCH_MIN_CHARS,\n} from './context-model.js';\nimport { searchSessions } from './context-queries.js';\nimport { describeContextError } from './use-token-gate.js';\nimport styles from './context.module.css';\n\nexport interface SessionSearchProps {\n onOpenSession: (id: string) => void;\n /**\n * The query, when a surrounding field owns it (the sidebar). Absent → this\n * component renders its own field.\n */\n query?: string;\n /** The chat that is open, marked with aria-current like the sidebar's rows. */\n selectedId?: string | null;\n}\n\ntype SearchState =\n | { status: 'idle' }\n | { status: 'loading'; previous: VerseSearchResponse | null }\n | { status: 'ready'; response: VerseSearchResponse }\n | { status: 'error'; message: string }\n | { status: 'unsupported' };\n\nexport function SessionSearch({ onOpenSession, query, selectedId = null }: SessionSearchProps) {\n const inputId = useId();\n const headingId = useId();\n const standalone = query === undefined;\n const [own, setOwn] = useState('');\n const q = (standalone ? own : query).trim();\n const [state, setState] = useState<SearchState>({ status: 'idle' });\n const [retry, setRetry] = useState(0);\n /** Once the server has said it has no search route, stop asking for this mount's lifetime. */\n const unsupported = useRef(false);\n\n useEffect(() => {\n if (unsupported.current) return undefined;\n if (q.length < SEARCH_MIN_CHARS) {\n setState({ status: 'idle' });\n return undefined;\n }\n const controller = new AbortController();\n // Keep the previous answer on screen while the next one is fetched: a list\n // that blanks on every keystroke is harder to read than a slightly stale one.\n setState((prev) => ({\n status: 'loading',\n previous: prev.status === 'ready' ? prev.response : prev.status === 'loading' ? prev.previous : null,\n }));\n const timer = setTimeout(() => {\n searchSessions(q, SEARCH_LIMIT, controller.signal)\n .then((response) => {\n if (!controller.signal.aborted) setState({ status: 'ready', response });\n })\n .catch((err: unknown) => {\n if (controller.signal.aborted) return;\n if (err instanceof ApiError && err.status === 404) {\n unsupported.current = true;\n setState({ status: 'unsupported' });\n }\n else setState({ status: 'error', message: describeContextError(err) });\n });\n }, SEARCH_DEBOUNCE_MS);\n return () => {\n clearTimeout(timer);\n controller.abort();\n };\n }, [q, retry]);\n\n const field = standalone ? (\n <label className={styles.searchBox} htmlFor={inputId}>\n <span className=\"visually-hidden\">Search messages in every chat</span>\n <input id={inputId} type=\"search\" className={styles.input} value={own} placeholder=\"Search messages\"\n autoComplete=\"off\" spellCheck={false} onChange={(event) => setOwn(event.target.value)} />\n </label>\n ) : null;\n\n // Controlled and idle (the sidebar's field is empty or too short), or a\n // server without the route: nothing to say — the title list above is the\n // whole answer. A standalone field has no title list, so it says why.\n if (state.status === 'unsupported') {\n return standalone ? (\n <div className={styles.search}>\n {field}\n <p className={`${styles.hint} ${styles.searchNote}`}>This server cannot search messages yet — update Ashlr and restart <code>ashlr verse</code>.</p>\n </div>\n ) : null;\n }\n if (state.status === 'idle' && !standalone) return null;\n\n const response = state.status === 'ready' ? state.response : state.status === 'loading' ? state.previous : null;\n const groups = response ? groupSearchHits(response.hits) : [];\n const terms = searchTerms(response?.query ?? q);\n const busy = state.status === 'loading';\n\n return (\n <section className={styles.search} aria-labelledby={headingId} aria-busy={busy ? true : undefined}>\n {field}\n <h2 id={headingId} className={styles.searchHead}>\n <span>In messages</span>\n {response && !busy ? (\n <span className={styles.searchCount} aria-hidden=\"true\">{groups.length}</span>\n ) : null}\n </h2>\n\n {/* Announced once per answer, not per keystroke. */}\n <p className=\"visually-hidden\" role=\"status\" aria-live=\"polite\">\n {state.status === 'ready'\n ? groups.length === 0 ? `No messages match ${q}.` : `${groups.length} ${groups.length === 1 ? 'chat has' : 'chats have'} matching messages.`\n : ''}\n </p>\n\n {state.status === 'idle' ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>\n Searches what was said in every chat on this machine. Nothing is sent to a model.\n </p>\n ) : state.status === 'error' ? (\n <div className={styles.searchError} role=\"alert\">\n <span>Could not search messages: {state.message}</span>\n <button type=\"button\" className={`${styles.secondary} ${styles.small}`} onClick={() => setRetry((n) => n + 1)}>\n Retry\n </button>\n </div>\n ) : busy && !response ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>Searching messages…</p>\n ) : groups.length === 0 ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>No messages match “{q}”. Try fewer or different words.</p>\n ) : (\n <ul className={styles.hits}>\n {groups.map((group) => {\n const segments = highlightSegments(group.top.snippet, terms);\n const who = group.top.kind === 'user' ? 'You' : 'Agent';\n const more = group.count > 1 ? ` · ${group.count} matches` : '';\n return (\n <li key={group.sessionId}>\n <button type=\"button\" className={`${styles.hit} ${styles[`engine-${group.engine}`] ?? ''}`}\n aria-current={group.sessionId === selectedId ? 'true' : undefined}\n data-session={group.sessionId} data-engine={group.engine}\n onClick={() => onOpenSession(group.sessionId)}>\n <span className={styles.hitMarker} aria-hidden=\"true\" />\n {/* The title truncates to one line, so it carries itself in full as a tooltip. */}\n <span className={styles.hitTitle} title={group.title || 'Untitled chat'}>{group.title || 'Untitled chat'}</span>\n <time className={styles.hitTime} dateTime={group.latestAt}>{formatRelative(group.latestAt)}</time>\n <span className={styles.hitSnippet}>\n <span className={styles.hitWho}>{who}{more}: </span>\n {segments.map((segment, index) => (segment.match\n ? <mark key={index}>{segment.text}</mark>\n : <span key={index}>{segment.text}</span>))}\n </span>\n </button>\n </li>\n );\n })}\n </ul>\n )}\n\n {response && state.status !== 'error' ? (\n <p className={`${styles.hint} ${styles.searchNote}`}>\n Searched {response.scannedSessions.toLocaleString()} {response.scannedSessions === 1 ? 'chat' : 'chats'}\n {response.truncated ? ' — the most recent ones only; older chats were not searched.' : '.'}\n </p>\n ) : null}\n </section>\n );\n}\n"],"mappings":"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"}
@@ -1,2 +1,2 @@
1
- import{a as e,c as t,n}from"./index-BG177cPN.js";import{C as r,S as i,_ as a,d as o,f as s,o as c,u as l,v as u,y as d}from"./global-CXHHMz9o.js";import{t as f}from"./Dialog-BuIaG6HF.js";import{n as p}from"./StatusBadge-DQ1UtQAJ.js";import{t as m}from"./MutationTokenDialog-CLGP72g6.js";import{r as h}from"./RouteErrorBoundary-BvhHNpE_.js";import{_n as ee,an as g,hn as _,on as v,sn as te}from"./VerseConsoleApp-DeuBEvAO.js";import{t as y}from"./Segmented-Wynbg0F5.js";import{n as b}from"./Tag-D4k5E3u0.js";import{T as x,v as S}from"./context-model-2Owp2jYF.js";import{t as C}from"./Button-OjVJSrFq.js";import{S as ne,c as re,f as ie,m as ae,n as oe,o as se,p as ce,t as le,u as ue}from"./icons-D4s-jlxX.js";import{a as de}from"./command-catalog-CmrHNFzh.js";import{i as fe,n as pe,p as me,r as he,s as ge,t as _e}from"./reasoning-pref-DMPQkujg.js";import{n as ve,t as ye}from"./use-token-gate-DfEja7Wr.js";import{t as be}from"./Meter-BSVhU43Q.js";import{t as w}from"./Slider-Bd9YFWEV.js";import{t as T}from"./Switch-CenChEYf.js";import{t as E}from"./Select-DMyLCkId.js";import{t as D}from"./Input-u1YR_Ogl.js";import"./primitives-DNI-uJBd.js";import{o as O,t as k}from"./useOnboarding-CkOHadqC.js";import{n as A}from"./ShortcutsOverlay-Bi5f-wUw.js";var j={section:`_section_1m00s_5`,strip:`_strip_1m00s_13`,stripTitle:`_stripTitle_1m00s_25`,scroll:`_scroll_1m00s_32`,column:`_column_1m00s_38`,panel:`_panel_1m00s_51`,panelHead:`_panelHead_1m00s_56`,panelTitle:`_panelTitle_1m00s_64`,panelBody:`_panelBody_1m00s_74`,row:`_row_1m00s_81`,rowStacked:`_rowStacked_1m00s_90`,rowText:`_rowText_1m00s_95`,rowLabel:`_rowLabel_1m00s_99`,rowDescription:`_rowDescription_1m00s_107`,rowControl:`_rowControl_1m00s_114`,swatches:`_swatches_1m00s_140`,swatch:`_swatch_1m00s_140`,swatchCheck:`_swatchCheck_1m00s_165`,sliderStack:`_sliderStack_1m00s_173`,contrastWarning:`_contrastWarning_1m00s_180`,preview:`_preview_1m00s_197`,previewRow:`_previewRow_1m00s_207`,previewHeading:`_previewHeading_1m00s_214`,previewBody:`_previewBody_1m00s_222`,previewNumerals:`_previewNumerals_1m00s_228`,origin:`_origin_1m00s_238`,note:`_note_1m00s_242`,noteIcon:`_noteIcon_1m00s_258`,code:`_code_1m00s_249`,panelNote:`_panelNote_1m00s_278`,about:`_about_1m00s_285`,aboutLine:`_aboutLine_1m00s_291`,aboutName:`_aboutName_1m00s_299`,link:`_link_1m00s_308`},M=n();function N({title:e,action:t,children:n}){return(0,M.jsxs)(`section`,{className:j.panel,children:[(0,M.jsxs)(`div`,{className:j.panelHead,children:[(0,M.jsx)(`h3`,{className:j.panelTitle,children:e}),t]}),(0,M.jsx)(`div`,{className:j.panelBody,children:n})]})}function P({label:e,description:t,htmlFor:n,labelId:r,stacked:i=!1,children:a}){let o=(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`span`,{className:j.rowLabel,id:r,children:e}),t?(0,M.jsx)(`span`,{className:j.rowDescription,children:t}):null]});return(0,M.jsxs)(`div`,{className:`${j.row} ${i?j.rowStacked:``}`,children:[(0,M.jsx)(`div`,{className:j.rowText,children:n?(0,M.jsx)(`label`,{htmlFor:n,className:j.rowText,children:o}):o}),(0,M.jsx)(`div`,{className:j.rowControl,children:a})]})}function xe(e,t,n=Date.now()){if(e){let t=S(e,n);return t?`Last completed ${t}.`:`Completed.`}return t?`Skipped. Nothing was missed — it is all reachable from the sections themselves.`:`Not seen yet. Replay it to take the two-minute tour.`}function Se(){let{completedAt:e,dismissedAt:t,open:n}=k();return(0,M.jsx)(N,{title:`Onboarding`,children:(0,M.jsx)(P,{label:`Replay the first-run tour`,description:`Your connected seats, whether a local runtime is available, how autonomy is turned on, and what each of the three stop controls really halts. ${xe(e,t)}`,children:(0,M.jsx)(C,{variant:`subtle`,size:`sm`,onClick:O,disabled:n,children:n?`Showing`:`Replay`})})})}var Ce=`3.11.5`,we=`Ashlr Verse`;function Te(){return(0,M.jsx)(N,{title:`About`,children:(0,M.jsx)(`div`,{className:`${j.row} ${j.rowStacked}`,children:(0,M.jsxs)(`div`,{className:j.about,children:[(0,M.jsx)(`p`,{className:j.aboutName,children:we}),(0,M.jsxs)(`p`,{className:j.aboutLine,children:[(0,M.jsxs)(b,{mono:!0,children:[`v`,Ce]}),(0,M.jsx)(`span`,{children:`ashlr-hub — local-first command center for agentic engineers.`})]}),(0,M.jsx)(`p`,{className:j.aboutLine,children:`Every session, token and artifact stays on this machine. The console talks to one local server and no third-party service.`}),(0,M.jsx)(`p`,{className:j.aboutLine,children:(0,M.jsxs)(`a`,{className:j.link,href:`https://github.com/ashlrai/ashlr-hub`,target:`_blank`,rel:`noreferrer noopener`,children:[`Source and changelog`,(0,M.jsx)(re,{size:12})]})})]})})})}var F=t(e(),1),Ee=/^#([0-9a-f]{3,8})$/i,De=/^(rgba?|hsla?)\(([^)]*)\)$/i;function I(e,t,n){return Math.min(n,Math.max(t,e))}function L(e,t){let n=e.trim();return n.endsWith(`%`)?Number.parseFloat(n)/100*t:Number.parseFloat(n)}function R(e,t,n){let r=(e%360+360)%360,i=(1-Math.abs(2*n-1))*t,a=i*(1-Math.abs(r/60%2-1)),o=n-i/2,s;return s=r<60?[i,a,0]:r<120?[a,i,0]:r<180?[0,i,a]:r<240?[0,a,i]:r<300?[a,0,i]:[i,0,a],{r:Math.round((s[0]+o)*255),g:Math.round((s[1]+o)*255),b:Math.round((s[2]+o)*255)}}function Oe(e){let t=[],n=0,r=``;for(let i of e){if(i===`(`?n+=1:i===`)`&&--n,i===`,`&&n===0){t.push(r),r=``;continue}r+=i}return t.push(r),t.map(e=>e.trim()).filter(e=>e.length>0)}function z(e){let t=e.trim(),n=/\s(\d*\.?\d+)%$/.exec(t);if(n)return{color:t.slice(0,n.index).trim(),pct:Number.parseFloat(n[1])};let r=/^(\d*\.?\d+)%\s/.exec(t);return r?{color:t.slice(r[0].length).trim(),pct:Number.parseFloat(r[1])}:{color:t,pct:null}}function ke(e){let t=/^color-mix\((.*)\)$/is.exec(e.trim());if(!t)return null;let n=Oe(t[1]);if(n.length!==3||n[0].replace(/\s+/g,` `).trim()!==`in srgb`)return null;let r=z(n[1]),i=z(n[2]);if(!r||!i)return null;let a=B(r.color),o=B(i.color);if(!a||!o)return null;let s=r.pct,c=i.pct;s===null&&c===null?(s=50,c=50):s===null?s=100-c:c===null&&(c=100-s);let l=s+c;if(l<=0)return null;let u=s/l,d=c/l,f=a.a*u+o.a*d;if(f<=0)return{r:0,g:0,b:0,a:0};let p=e=>I(Math.round((a[e]*a.a*u+o[e]*o.a*d)/f),0,255);return{r:p(`r`),g:p(`g`),b:p(`b`),a:I(f,0,1)}}function B(e){let t=e.trim().toLowerCase();if(t===`transparent`)return{r:0,g:0,b:0,a:0};if(t.startsWith(`color-mix(`))return ke(t);let n=Ee.exec(t);if(n){let e=n[1],t=e=>Number.parseInt(e.length===1?e+e:e,16);return e.length===3||e.length===4?{r:t(e[0]),g:t(e[1]),b:t(e[2]),a:e.length===4?t(e[3])/255:1}:e.length===6||e.length===8?{r:t(e.slice(0,2)),g:t(e.slice(2,4)),b:t(e.slice(4,6)),a:e.length===8?t(e.slice(6,8))/255:1}:null}let r=De.exec(t);if(!r)return null;let i=r[1],a=r[2].replace(/\//g,` `).split(/[\s,]+/).filter(Boolean);if(a.length<3)return null;let o=a.length>=4?I(L(a[3],1),0,1):1;if(i.startsWith(`rgb`))return{r:I(Math.round(L(a[0],255)),0,255),g:I(Math.round(L(a[1],255)),0,255),b:I(Math.round(L(a[2],255)),0,255),a:o};let s=Number.parseFloat(a[0]),c=I(L(a[1],1),0,1),l=I(L(a[2],1),0,1);return Number.isFinite(s)?{...R(s,c,l),a:o}:null}function V(e,t){if(e.a>=1)return e;let n=e.a;return{r:Math.round(e.r*n+t.r*(1-n)),g:Math.round(e.g*n+t.g*(1-n)),b:Math.round(e.b*n+t.b*(1-n)),a:1}}function H(e){let t=e=>{let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4};return .2126*t(e.r)+.7152*t(e.g)+.0722*t(e.b)}function U(e,t,n=`#ffffff`){let r=B(t),i=B(e),a=B(n);if(!r||!i||!a)return null;let o=V(r,a),s=H(V(i,o)),c=H(o),[l,u]=s>=c?[s,c]:[c,s];return(l+.05)/(u+.05)}function W(e,t,n,r=0){let i=R(e,I(t,0,100)/100,I(n+r,0,100)/100),a=e=>e.toString(16).padStart(2,`0`);return`#${a(i.r)}${a(i.g)}${a(i.b)}`}var G=[{id:`indigo`,label:`Indigo`,h:245,s:72,l:58},{id:`blue`,label:`Blue`,h:212,s:80,l:50},{id:`cyan`,label:`Cyan`,h:190,s:80,l:40},{id:`teal`,label:`Teal`,h:168,s:70,l:38},{id:`green`,label:`Green`,h:145,s:60,l:38},{id:`amber`,label:`Amber`,h:38,s:80,l:42},{id:`rose`,label:`Rose`,h:348,s:72,l:50},{id:`violet`,label:`Violet`,h:278,s:66,l:55}];function Ae(e=d()){let t=u();return e.theme===t.theme&&e.accentH===t.accentH&&e.accentS===t.accentS&&e.accentL===t.accentL&&e.density===t.density&&e.uiScale===t.uiScale&&e.displayFont===t.displayFont&&e.radius===t.radius&&e.motion===t.motion}function je(e=d()){return G.find(t=>t.h===e.accentH&&t.s===e.accentS&&t.l===e.accentL)??null}var Me=`#ffffff`,Ne=`#121214`,Pe=[{value:`system`,label:`System`,icon:(0,M.jsx)(ce,{})},{value:`light`,label:`Light`,icon:(0,M.jsx)(ne,{})},{value:`dark`,label:`Dark`,icon:(0,M.jsx)(ae,{})}],Fe=[{value:`default`,label:`Default`},{value:`large`,label:`Large`},{value:`xlarge`,label:`Extra large`}],Ie=[{value:`comfortable`,label:`Comfortable`},{value:`compact`,label:`Compact`}],Le=[{value:`grotesk`,label:`Space Grotesk`},{value:`ui`,label:`UI sans`},{value:`mono`,label:`Mono`}],Re=[{value:`sharp`,label:`Sharp`},{value:`default`,label:`Default`},{value:`soft`,label:`Soft`}];function ze(e,t){return`linear-gradient(to right, ${[0,60,120,180,240,300,360].map(n=>`${W(n,e,t)} ${n/360*100}%`).join(`, `)})`}function Be(e,t,n){let r=W(e,t,n,-8),i=W(e,t,n,14),a=U(r,Me),o=U(i,Ne),s=[];return a!==null&&a<4.5&&s.push(`light`),o!==null&&o<4.5&&s.push(`dark`),{lightRatio:a,darkRatio:o,failing:s}}function Ve({appearance:e,onChange:t,onReset:n}){let r=(0,F.useId)(),i=(0,F.useId)(),o=(0,F.useId)(),s=(0,F.useId)(),c=(0,F.useId)(),l=je(e),u=Be(e.accentH,e.accentS,e.accentL);return(0,M.jsxs)(N,{title:`Appearance`,action:(0,M.jsx)(C,{variant:`ghost`,size:`sm`,onClick:n,disabled:Ae(e),title:`Restore the shipped theme, accent, display size, density, font, radius and motion`,children:`Reset to defaults`}),children:[(0,M.jsx)(P,{label:`Theme`,description:`System follows your OS appearance setting.`,children:(0,M.jsx)(y,{"aria-label":`Theme`,options:Pe,value:e.theme,onChange:e=>t({theme:e})})}),(0,M.jsx)(P,{label:`Accent`,labelId:r,description:l?`${l.label} — used for links, focus rings and the one primary action per surface.`:`Custom hue — used for links, focus rings and the one primary action per surface.`,children:(0,M.jsx)(`div`,{className:j.swatches,role:`radiogroup`,"aria-labelledby":r,children:G.map(e=>{let n=l?.id===e.id;return(0,M.jsx)(`button`,{type:`button`,role:`radio`,"aria-checked":n,"aria-label":e.label,tabIndex:n||!l&&e.id===G[0].id?0:-1,className:j.swatch,style:{background:W(e.h,e.s,e.l)},onClick:()=>t({accentH:e.h,accentS:e.s,accentL:e.l}),children:n?(0,M.jsx)(`span`,{className:j.swatchCheck,children:(0,M.jsx)(oe,{size:12})}):null},e.id)})})}),(0,M.jsx)(P,{label:`Accent channels`,description:`Hue, saturation and lightness are written straight onto the root element — the whole app follows as you drag.`,stacked:!0,children:(0,M.jsxs)(`div`,{className:j.sliderStack,children:[(0,M.jsx)(w,{id:i,label:`Hue`,min:0,max:359,value:e.accentH,valueLabel:`${e.accentH}°`,valueText:`${e.accentH} degrees`,trackImage:ze(e.accentS,e.accentL),onChange:e=>t({accentH:Number(e.currentTarget.value)})}),(0,M.jsx)(w,{id:o,label:`Saturation`,min:0,max:100,value:e.accentS,valueLabel:`${e.accentS}%`,valueText:`${e.accentS} percent`,onChange:e=>t({accentS:Number(e.currentTarget.value)})}),(0,M.jsx)(w,{id:s,label:`Lightness`,min:a.min,max:a.max,value:e.accentL,valueLabel:`${e.accentL}%`,valueText:`${e.accentL} percent`,onChange:e=>t({accentL:Number(e.currentTarget.value)})}),u.failing.length>0?(0,M.jsxs)(`p`,{className:j.contrastWarning,role:`status`,children:[(0,M.jsx)(le,{size:14}),(0,M.jsxs)(`span`,{children:[`This accent falls below 4.5:1 as link text in`,` `,u.failing.length===2?`both themes`:`${u.failing[0]} mode`,`. Raise or lower the lightness to keep it readable.`]})]}):null]})}),(0,M.jsx)(P,{label:`Display size`,description:`Scales text AND spacing together across the whole app, for a large display or a long session. Applies as you pick it.`,children:(0,M.jsx)(y,{"aria-label":`Display size`,options:Fe,value:e.uiScale,onChange:e=>t({uiScale:e})})}),(0,M.jsx)(P,{label:`Density`,description:`Row height and control padding across every view. Independent of display size — a large, tightly packed interface is a valid choice.`,children:(0,M.jsx)(y,{"aria-label":`Density`,options:Ie,value:e.density,onChange:e=>t({density:e})})}),(0,M.jsx)(P,{label:`Display font`,description:`Titles, seat names, metrics and numerals. Body copy stays in the UI sans.`,children:(0,M.jsx)(y,{"aria-label":`Display font`,options:Le,value:e.displayFont,onChange:e=>t({displayFont:e})})}),(0,M.jsx)(P,{label:`Corner radius`,description:`Sharp reads like a terminal; soft reads like a consumer app.`,children:(0,M.jsx)(y,{"aria-label":`Corner radius`,options:Re,value:e.radius,onChange:e=>t({radius:e})})}),(0,M.jsx)(P,{label:`Reduce motion`,htmlFor:c,description:`Collapses every transition to 1ms. Defaults to your system preference; turning it off here overrides that.`,children:(0,M.jsx)(T,{id:c,checked:e.reduceMotion,onChange:e=>t({reduceMotion:e}),"aria-label":`Reduce motion`})}),(0,M.jsx)(P,{label:`Preview`,description:`Live, using the real components.`,stacked:!0,children:(0,M.jsxs)(`div`,{className:j.preview,children:[(0,M.jsx)(`p`,{className:j.previewHeading,children:`Ashlr Verse`}),(0,M.jsxs)(`p`,{className:j.previewBody,children:[`Body copy stays in the UI sans at the reading measure; numerals like`,` `,(0,M.jsx)(`span`,{className:j.previewNumerals,children:`18,420 / 66,000`}),` use the display face.`]}),(0,M.jsxs)(`div`,{className:j.previewRow,children:[(0,M.jsx)(C,{variant:`primary`,size:`sm`,children:`Primary`}),(0,M.jsx)(C,{variant:`subtle`,size:`sm`,children:`Subtle`}),(0,M.jsx)(C,{variant:`ghost`,size:`sm`,children:`Ghost`}),(0,M.jsx)(C,{variant:`danger`,size:`sm`,children:`Destructive`})]}),(0,M.jsxs)(`div`,{className:j.previewRow,children:[(0,M.jsx)(p,{status:`running`}),(0,M.jsx)(b,{engine:`claude`,children:`Claude Max`}),(0,M.jsx)(b,{engine:`local`,mono:!0,children:`qwen3-coder`})]}),(0,M.jsx)(be,{value:18420,max:66e3,label:`Context`}),(0,M.jsx)(D,{"aria-label":`Preview field`,placeholder:`A field at the current density`,size:`sm`})]})})]})}var He={collapsed:`Streams three lines while the model thinks, then folds to “Thought 12s · ~1.8k tok”.`,expanded:`Streams, and stays open when the thinking is done.`,hidden:`No reasoning in the transcript. The live status still says it is thinking, so a long think never looks like a hang.`},K=[`plan`,`accept-edits`,`auto`],q={plan:`Plan`,"accept-edits":`Accept edits`,auto:`Auto`},Ue={plan:`New chats plan and edit nothing until you switch them.`,"accept-edits":`New chats apply edits without asking — the default.`,auto:`New chats run in the CLI’s own auto mode.`},J={minimal:`Minimal`,low:`Low`,medium:`Medium`,high:`High`,xhigh:`Extra high`,max:`Max`},Y=``,We=new Set(K),X=new Set(x);function Z(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function Q(e){if(!Z(e)||!Z(e.global))return null;let t=e=>{let t={};return Z(e)?(typeof e.permissionMode==`string`&&We.has(e.permissionMode)&&(t.permissionMode=e.permissionMode),typeof e.effort==`string`&&X.has(e.effort)&&(t.effort=e.effort),t):t},n={};if(Z(e.seats))for(let[r,i]of Object.entries(e.seats))n[r]=t(i);return{global:t(e.global),seats:n}}function $(e){return e instanceof c&&(e.status===404||e.status===501)?"This server can’t set new-chat defaults yet — update Ashlr and restart `ashlr verse`.":`Couldn’t read the new-chat defaults. Reopen Settings to try again.`}function Ge(){let[e,t]=(0,F.useState)({state:`loading`}),[n,r]=(0,F.useState)(!1),[i,a]=(0,F.useState)(null),o=ve(),s=(0,F.useId)(),c=(0,F.useId)();(0,F.useEffect)(()=>{let e=new AbortController;return ge(e.signal).then(e=>{let n=Q(e);t(n?{state:`ready`,defaults:n}:{state:`unavailable`,message:$(null)})},n=>{e.signal.aborted||t({state:`unavailable`,message:$(n)})}),()=>e.abort()},[]);let l=(0,F.useCallback)(async(e,n)=>{a(null),r(!0);try{let r=await o.run(n,()=>me(e));if(r){let e=Q(r);e&&t({state:`ready`,defaults:e})}}catch(e){a(ye(e))}finally{r(!1)}},[o]);if(e.state===`loading`)return(0,M.jsx)(`p`,{className:j.panelNote,"aria-busy":`true`,children:`Reading new-chat defaults…`});if(e.state===`unavailable`)return(0,M.jsx)(`p`,{className:j.panelNote,children:e.message});let u=e.defaults.global,d=u.permissionMode&&u.permissionMode!==`bypass`?u.permissionMode:`accept-edits`,f=u.effort??null,p=Object.keys(e.defaults.seats).length;return(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(P,{label:`New chats start in`,description:Ue[d],labelId:s,children:(0,M.jsx)(y,{"aria-labelledby":s,size:`sm`,value:d,onChange:e=>{e!==d&&l({permissionMode:e},`Start new chats in ${q[e]}.`)},options:K.map(e=>({value:e,label:q[e],disabled:n}))})}),(0,M.jsx)(P,{label:`Reasoning effort for new chats`,description:p>0?`A seat that can’t use this level starts at its model’s own default. ${p===1?`One seat has its`:`${p} seats have their`} own default, which wins.`:`A seat that can’t use this level starts at its model’s own default.`,htmlFor:c,children:(0,M.jsxs)(E,{id:c,size:`sm`,value:f??Y,disabled:n,onChange:e=>{let t=e.target.value,n=t===Y?null:t;n!==f&&l({effort:n},n?`Start new chats at ${J[n]} effort.`:`Start new chats at the model’s default effort.`)},children:[(0,M.jsx)(`option`,{value:Y,children:`Model default`}),x.map(e=>(0,M.jsx)(`option`,{value:e,children:J[e]},e))]})}),i?(0,M.jsx)(`p`,{className:j.panelNote,role:`alert`,children:i}):null,(0,M.jsx)(m,{...o.dialog})]})}function Ke(){let e=fe(),t=(0,F.useId)();return(0,M.jsxs)(N,{title:`Chat`,children:[(0,M.jsx)(P,{label:`Reasoning`,description:He[e],labelId:t,children:(0,M.jsx)(y,{"aria-labelledby":t,size:`sm`,value:e,onChange:he,options:_e.map(e=>({value:e,label:pe[e]}))})}),(0,M.jsx)(Ge,{})]})}function qe(e){if(e===null)return`locked`;let t=Math.max(0,Math.round((e-Date.now())/6e4));return t<=0?`expiring now`:`unlocked for ${t} more minute${t===1?``:`s`}`}function Je(){let e=o(),t=s(),n=h(),[a,c]=(0,F.useState)(!1),l=(0,F.useRef)(null),u=typeof window>`u`?``:window.location.origin;async function d(){try{await navigator.clipboard.writeText(u),n.show(`Server address copied.`)}catch{n.show(`Could not reach the clipboard — select the field and copy manually.`,`danger`)}}async function m(){c(!1),await r(),n.show(`Disconnected. Paste the read token to reconnect.`)}return(0,M.jsxs)(N,{title:`Connection`,children:[(0,M.jsxs)(P,{label:`Server`,description:`This window talks to one local hub. Nothing leaves your machine.`,children:[(0,M.jsx)(`div`,{className:j.origin,children:(0,M.jsx)(D,{value:u,readOnly:!0,mono:!0,size:`sm`,"aria-label":`Server address`})}),(0,M.jsx)(C,{variant:`ghost`,size:`sm`,icon:(0,M.jsx)(se,{}),onClick:()=>void d(),children:`Copy`})]}),(0,M.jsx)(P,{label:`Read session`,description:`A 15-minute signed cookie, renewed silently while this tab stays open.`,children:(0,M.jsx)(p,{status:e===`authenticated`?`connected`:e===`checking`?`checking`:`disconnected`,tone:e===`authenticated`?`success`:e===`checking`?`running`:`danger`})}),(0,M.jsxs)(P,{label:`Mutation hold`,description:`Every action that changes something needs the mutation token. It is held in memory only, never stored, and clears when this tab closes.`,children:[(0,M.jsx)(p,{status:t.hasHold?qe(t.heldUntil):`locked`,tone:t.hasHold?`success`:`neutral`}),(0,M.jsx)(C,{variant:`subtle`,size:`sm`,icon:(0,M.jsx)(ie,{}),onClick:()=>{i(),n.show(`Mutation hold cleared.`)},disabled:!t.hasHold,children:`Lock now`})]}),(0,M.jsx)(P,{label:`Disconnect`,description:`Ends the read session in this browser and clears the mutation hold. Chats on the server are untouched.`,children:(0,M.jsx)(C,{variant:`danger`,size:`sm`,onClick:()=>c(!0),children:`Disconnect`})}),(0,M.jsx)(`div`,{className:j.row,children:(0,M.jsxs)(`p`,{className:j.note,children:[(0,M.jsx)(`span`,{className:j.noteIcon,children:(0,M.jsx)(ue,{size:14})}),(0,M.jsxs)(`span`,{children:[(0,M.jsx)(`strong`,{children:`Where the tokens come from.`}),` Start the console with`,` `,(0,M.jsx)(`code`,{className:j.code,children:`ashlr verse`}),` — it prints a read token and a mutation token in that terminal, and opens this page. The desktop app injects both for you. Tokens are never displayed here, and the hub never writes them into a page, a log line or an API response. Lost them? Stop the server and start it again; it mints a fresh pair.`]})]})}),(0,M.jsx)(f,{open:a,onClose:()=>c(!1),titleId:`verse-settings-disconnect`,title:`Disconnect from this server?`,description:`You will need the read token again to get back in. Running sessions keep running on the server.`,initialFocusRef:l,children:(0,M.jsxs)(`div`,{className:j.previewRow,style:{justifyContent:`flex-end`},children:[(0,M.jsx)(C,{ref:l,variant:`subtle`,onClick:()=>c(!1),children:`Cancel`}),(0,M.jsx)(C,{variant:`danger`,onClick:()=>void m(),children:`Disconnect`})]})})]})}var Ye=4e3;function Xe(e){let{enabled:t,registered:n,accelerator:r,error:i}=e.hotkey;return t?n?`Press ${r} in any app to bring Verse forward with the composer focused.`:`${r} is not active: ${i??`another app already uses it`}. Free the shortcut in that app, or turn this off.`:`Off. Turning it on takes ${r} away from every other app on this Mac.`}function Ze(e){let t=e.notifications.enabled?`Finished and failed chats, and new items that need you — only while Verse is in the background.`:`Off. The tray and the Dock badge still show what needs you.`;return e.notifications.delivery===`script`?`${t} On this unsigned build banners appear as Script Editor, and clicking one opens Script Editor rather than Verse.`:t}function Qe(){let e=te(),[t,n]=(0,F.useState)(null),[r,i]=(0,F.useState)(null),a=(0,F.useRef)(null);if((0,F.useEffect)(()=>{n(null),i(null),a.current!==null&&window.clearTimeout(a.current),a.current=null},[e]),(0,F.useEffect)(()=>()=>{a.current!==null&&window.clearTimeout(a.current)},[]),e===null)return(0,M.jsx)(N,{title:`Desktop`,children:(0,M.jsx)(`p`,{className:j.panelNote,"aria-busy":g()||void 0,children:g()?`Reading the desktop app’s settings…`:`The system-wide shortcut and notifications are available in the Verse desktop app.`})});function o(e,t){if(i(null),!v(e,t)){i(`The desktop app did not take the change. Nothing was changed.`);return}n(e),a.current!==null&&window.clearTimeout(a.current),a.current=window.setTimeout(()=>{a.current=null,n(null),i(`The desktop app did not answer. The switches show what it last reported.`)},Ye)}let s=e.hotkey.enabled&&!e.hotkey.registered;return(0,M.jsxs)(N,{title:`Desktop`,children:[(0,M.jsx)(P,{label:`System-wide shortcut (${e.hotkey.accelerator})`,description:(0,M.jsx)(`span`,{"data-tone":s?`warning`:void 0,role:s?`status`:void 0,children:Xe(e)}),children:(0,M.jsx)(T,{"aria-label":`System-wide shortcut`,checked:e.hotkey.enabled,disabled:t!==null,onChange:e=>o(`globalHotkey`,e)})}),(0,M.jsx)(P,{label:`Notifications`,description:Ze(e),children:(0,M.jsx)(T,{"aria-label":`Notifications`,checked:e.notifications.enabled,disabled:t!==null,onChange:e=>o(`notifications`,e)})}),t?(0,M.jsx)(`p`,{className:j.panelNote,role:`status`,children:`Waiting for the desktop app…`}):null,r?(0,M.jsx)(`p`,{className:j.panelNote,role:`alert`,children:r}):null]})}function $e(){let e=(0,F.useMemo)(()=>_(),[]),t=de(`shortcuts.open`)?.keys[0];return(0,M.jsxs)(N,{title:`Keyboard`,children:[(0,M.jsx)(`p`,{className:j.panelNote,children:t?`${ee(t,e)} shows this list from anywhere.`:null}),(0,M.jsx)(A,{platform:e})]})}function et(){let{appearance:e,set:t,reset:n}=l();return(0,M.jsxs)(`div`,{className:j.section,children:[(0,M.jsx)(`header`,{className:j.strip,"data-app-region":`drag`,children:(0,M.jsx)(`h2`,{className:j.stripTitle,children:`Settings`})}),(0,M.jsx)(`div`,{className:j.scroll,children:(0,M.jsxs)(`div`,{className:j.column,children:[(0,M.jsx)(Ve,{appearance:e,onChange:t,onReset:n}),(0,M.jsx)(Ke,{}),(0,M.jsx)(Qe,{}),(0,M.jsx)(Je,{}),(0,M.jsx)($e,{}),(0,M.jsx)(Se,{}),(0,M.jsx)(Te,{})]})})]})}export{et as SettingsSection};
2
- //# sourceMappingURL=SettingsSection-Da9RYyH5.js.map
1
+ import{a as e,c as t,n}from"./index-CyK31YRm.js";import{C as r,b as i,d as a,f as o,o as s,p as c,v as l,w as u,y as d}from"./global-y_exIyAP.js";import{t as f}from"./Dialog-BRd_B9OE.js";import{n as p}from"./StatusBadge-CXG3iNL4.js";import{t as m}from"./MutationTokenDialog-Bm34BNVV.js";import{r as h}from"./RouteErrorBoundary-C8WGiixc.js";import{_n as ee,an as g,hn as _,on as v,sn as te}from"./VerseConsoleApp-DXDv1aOi.js";import{t as y}from"./Segmented-Wt1ATod9.js";import{n as b}from"./Tag-WSUIaMVy.js";import{T as x,v as S}from"./context-model-Bb15chFt.js";import{t as C}from"./Button-DtE0rlWD.js";import{S as ne,c as re,f as ie,m as ae,n as oe,o as se,p as ce,t as le,u as ue}from"./icons-CygCEFWs.js";import{a as de}from"./command-catalog-ffCAijVY.js";import{i as fe,n as pe,p as me,r as he,s as ge,t as _e}from"./reasoning-pref-KkhI_5-j.js";import{n as ve,t as ye}from"./use-token-gate-DSNIIpI6.js";import{t as be}from"./Meter-b69LM0mU.js";import{t as w}from"./Slider-DaEDws-b.js";import{t as T}from"./Switch-BmCzfFnu.js";import{t as E}from"./Select-By-V9lMc.js";import{t as D}from"./Input-CI0yBHmn.js";import"./primitives-DMijqcu0.js";import{o as O,t as k}from"./useOnboarding-Bk0VnkxQ.js";import{n as A}from"./ShortcutsOverlay-DiigiT8H.js";var j={section:`_section_1m00s_5`,strip:`_strip_1m00s_13`,stripTitle:`_stripTitle_1m00s_25`,scroll:`_scroll_1m00s_32`,column:`_column_1m00s_38`,panel:`_panel_1m00s_51`,panelHead:`_panelHead_1m00s_56`,panelTitle:`_panelTitle_1m00s_64`,panelBody:`_panelBody_1m00s_74`,row:`_row_1m00s_81`,rowStacked:`_rowStacked_1m00s_90`,rowText:`_rowText_1m00s_95`,rowLabel:`_rowLabel_1m00s_99`,rowDescription:`_rowDescription_1m00s_107`,rowControl:`_rowControl_1m00s_114`,swatches:`_swatches_1m00s_140`,swatch:`_swatch_1m00s_140`,swatchCheck:`_swatchCheck_1m00s_165`,sliderStack:`_sliderStack_1m00s_173`,contrastWarning:`_contrastWarning_1m00s_180`,preview:`_preview_1m00s_197`,previewRow:`_previewRow_1m00s_207`,previewHeading:`_previewHeading_1m00s_214`,previewBody:`_previewBody_1m00s_222`,previewNumerals:`_previewNumerals_1m00s_228`,origin:`_origin_1m00s_238`,note:`_note_1m00s_242`,noteIcon:`_noteIcon_1m00s_258`,code:`_code_1m00s_249`,panelNote:`_panelNote_1m00s_278`,about:`_about_1m00s_285`,aboutLine:`_aboutLine_1m00s_291`,aboutName:`_aboutName_1m00s_299`,link:`_link_1m00s_308`},M=n();function N({title:e,action:t,children:n}){return(0,M.jsxs)(`section`,{className:j.panel,children:[(0,M.jsxs)(`div`,{className:j.panelHead,children:[(0,M.jsx)(`h3`,{className:j.panelTitle,children:e}),t]}),(0,M.jsx)(`div`,{className:j.panelBody,children:n})]})}function P({label:e,description:t,htmlFor:n,labelId:r,stacked:i=!1,children:a}){let o=(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`span`,{className:j.rowLabel,id:r,children:e}),t?(0,M.jsx)(`span`,{className:j.rowDescription,children:t}):null]});return(0,M.jsxs)(`div`,{className:`${j.row} ${i?j.rowStacked:``}`,children:[(0,M.jsx)(`div`,{className:j.rowText,children:n?(0,M.jsx)(`label`,{htmlFor:n,className:j.rowText,children:o}):o}),(0,M.jsx)(`div`,{className:j.rowControl,children:a})]})}function xe(e,t,n=Date.now()){if(e){let t=S(e,n);return t?`Last completed ${t}.`:`Completed.`}return t?`Skipped. Nothing was missed — it is all reachable from the sections themselves.`:`Not seen yet. Replay it to take the two-minute tour.`}function Se(){let{completedAt:e,dismissedAt:t,open:n}=k();return(0,M.jsx)(N,{title:`Onboarding`,children:(0,M.jsx)(P,{label:`Replay the first-run tour`,description:`Your connected seats, whether a local runtime is available, how autonomy is turned on, and what each of the three stop controls really halts. ${xe(e,t)}`,children:(0,M.jsx)(C,{variant:`subtle`,size:`sm`,onClick:O,disabled:n,children:n?`Showing`:`Replay`})})})}var Ce=`3.13.0`,we=`Ashlr Verse`;function Te(){return(0,M.jsx)(N,{title:`About`,children:(0,M.jsx)(`div`,{className:`${j.row} ${j.rowStacked}`,children:(0,M.jsxs)(`div`,{className:j.about,children:[(0,M.jsx)(`p`,{className:j.aboutName,children:we}),(0,M.jsxs)(`p`,{className:j.aboutLine,children:[(0,M.jsxs)(b,{mono:!0,children:[`v`,Ce]}),(0,M.jsx)(`span`,{children:`ashlr-hub — local-first command center for agentic engineers.`})]}),(0,M.jsx)(`p`,{className:j.aboutLine,children:`Every session, token and artifact stays on this machine. The console talks to one local server and no third-party service.`}),(0,M.jsx)(`p`,{className:j.aboutLine,children:(0,M.jsxs)(`a`,{className:j.link,href:`https://github.com/ashlrai/ashlr-hub`,target:`_blank`,rel:`noreferrer noopener`,children:[`Source and changelog`,(0,M.jsx)(re,{size:12})]})})]})})})}var F=t(e(),1),Ee=/^#([0-9a-f]{3,8})$/i,De=/^(rgba?|hsla?)\(([^)]*)\)$/i;function I(e,t,n){return Math.min(n,Math.max(t,e))}function L(e,t){let n=e.trim();return n.endsWith(`%`)?Number.parseFloat(n)/100*t:Number.parseFloat(n)}function R(e,t,n){let r=(e%360+360)%360,i=(1-Math.abs(2*n-1))*t,a=i*(1-Math.abs(r/60%2-1)),o=n-i/2,s;return s=r<60?[i,a,0]:r<120?[a,i,0]:r<180?[0,i,a]:r<240?[0,a,i]:r<300?[a,0,i]:[i,0,a],{r:Math.round((s[0]+o)*255),g:Math.round((s[1]+o)*255),b:Math.round((s[2]+o)*255)}}function Oe(e){let t=[],n=0,r=``;for(let i of e){if(i===`(`?n+=1:i===`)`&&--n,i===`,`&&n===0){t.push(r),r=``;continue}r+=i}return t.push(r),t.map(e=>e.trim()).filter(e=>e.length>0)}function z(e){let t=e.trim(),n=/\s(\d*\.?\d+)%$/.exec(t);if(n)return{color:t.slice(0,n.index).trim(),pct:Number.parseFloat(n[1])};let r=/^(\d*\.?\d+)%\s/.exec(t);return r?{color:t.slice(r[0].length).trim(),pct:Number.parseFloat(r[1])}:{color:t,pct:null}}function ke(e){let t=/^color-mix\((.*)\)$/is.exec(e.trim());if(!t)return null;let n=Oe(t[1]);if(n.length!==3||n[0].replace(/\s+/g,` `).trim()!==`in srgb`)return null;let r=z(n[1]),i=z(n[2]);if(!r||!i)return null;let a=B(r.color),o=B(i.color);if(!a||!o)return null;let s=r.pct,c=i.pct;s===null&&c===null?(s=50,c=50):s===null?s=100-c:c===null&&(c=100-s);let l=s+c;if(l<=0)return null;let u=s/l,d=c/l,f=a.a*u+o.a*d;if(f<=0)return{r:0,g:0,b:0,a:0};let p=e=>I(Math.round((a[e]*a.a*u+o[e]*o.a*d)/f),0,255);return{r:p(`r`),g:p(`g`),b:p(`b`),a:I(f,0,1)}}function B(e){let t=e.trim().toLowerCase();if(t===`transparent`)return{r:0,g:0,b:0,a:0};if(t.startsWith(`color-mix(`))return ke(t);let n=Ee.exec(t);if(n){let e=n[1],t=e=>Number.parseInt(e.length===1?e+e:e,16);return e.length===3||e.length===4?{r:t(e[0]),g:t(e[1]),b:t(e[2]),a:e.length===4?t(e[3])/255:1}:e.length===6||e.length===8?{r:t(e.slice(0,2)),g:t(e.slice(2,4)),b:t(e.slice(4,6)),a:e.length===8?t(e.slice(6,8))/255:1}:null}let r=De.exec(t);if(!r)return null;let i=r[1],a=r[2].replace(/\//g,` `).split(/[\s,]+/).filter(Boolean);if(a.length<3)return null;let o=a.length>=4?I(L(a[3],1),0,1):1;if(i.startsWith(`rgb`))return{r:I(Math.round(L(a[0],255)),0,255),g:I(Math.round(L(a[1],255)),0,255),b:I(Math.round(L(a[2],255)),0,255),a:o};let s=Number.parseFloat(a[0]),c=I(L(a[1],1),0,1),l=I(L(a[2],1),0,1);return Number.isFinite(s)?{...R(s,c,l),a:o}:null}function V(e,t){if(e.a>=1)return e;let n=e.a;return{r:Math.round(e.r*n+t.r*(1-n)),g:Math.round(e.g*n+t.g*(1-n)),b:Math.round(e.b*n+t.b*(1-n)),a:1}}function H(e){let t=e=>{let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4};return .2126*t(e.r)+.7152*t(e.g)+.0722*t(e.b)}function U(e,t,n=`#ffffff`){let r=B(t),i=B(e),a=B(n);if(!r||!i||!a)return null;let o=V(r,a),s=H(V(i,o)),c=H(o),[l,u]=s>=c?[s,c]:[c,s];return(l+.05)/(u+.05)}function W(e,t,n,r=0){let i=R(e,I(t,0,100)/100,I(n+r,0,100)/100),a=e=>e.toString(16).padStart(2,`0`);return`#${a(i.r)}${a(i.g)}${a(i.b)}`}var G=[{id:`indigo`,label:`Indigo`,h:245,s:72,l:58},{id:`blue`,label:`Blue`,h:212,s:80,l:50},{id:`cyan`,label:`Cyan`,h:190,s:80,l:40},{id:`teal`,label:`Teal`,h:168,s:70,l:38},{id:`green`,label:`Green`,h:145,s:60,l:38},{id:`amber`,label:`Amber`,h:38,s:80,l:42},{id:`rose`,label:`Rose`,h:348,s:72,l:50},{id:`violet`,label:`Violet`,h:278,s:66,l:55}];function Ae(e=i()){let t=d();return e.theme===t.theme&&e.accentH===t.accentH&&e.accentS===t.accentS&&e.accentL===t.accentL&&e.density===t.density&&e.uiScale===t.uiScale&&e.displayFont===t.displayFont&&e.radius===t.radius&&e.motion===t.motion}function je(e=i()){return G.find(t=>t.h===e.accentH&&t.s===e.accentS&&t.l===e.accentL)??null}var Me=`#ffffff`,Ne=`#121214`,Pe=[{value:`system`,label:`System`,icon:(0,M.jsx)(ce,{})},{value:`light`,label:`Light`,icon:(0,M.jsx)(ne,{})},{value:`dark`,label:`Dark`,icon:(0,M.jsx)(ae,{})}],Fe=[{value:`default`,label:`Default`},{value:`large`,label:`Large`},{value:`xlarge`,label:`Extra large`}],Ie=[{value:`comfortable`,label:`Comfortable`},{value:`compact`,label:`Compact`}],Le=[{value:`grotesk`,label:`Space Grotesk`},{value:`ui`,label:`UI sans`},{value:`mono`,label:`Mono`}],Re=[{value:`sharp`,label:`Sharp`},{value:`default`,label:`Default`},{value:`soft`,label:`Soft`}];function ze(e,t){return`linear-gradient(to right, ${[0,60,120,180,240,300,360].map(n=>`${W(n,e,t)} ${n/360*100}%`).join(`, `)})`}function Be(e,t,n){let r=W(e,t,n,-8),i=W(e,t,n,14),a=U(r,Me),o=U(i,Ne),s=[];return a!==null&&a<4.5&&s.push(`light`),o!==null&&o<4.5&&s.push(`dark`),{lightRatio:a,darkRatio:o,failing:s}}function Ve({appearance:e,onChange:t,onReset:n}){let r=(0,F.useId)(),i=(0,F.useId)(),a=(0,F.useId)(),o=(0,F.useId)(),s=(0,F.useId)(),c=je(e),u=Be(e.accentH,e.accentS,e.accentL);return(0,M.jsxs)(N,{title:`Appearance`,action:(0,M.jsx)(C,{variant:`ghost`,size:`sm`,onClick:n,disabled:Ae(e),title:`Restore the shipped theme, accent, display size, density, font, radius and motion`,children:`Reset to defaults`}),children:[(0,M.jsx)(P,{label:`Theme`,description:`System follows your OS appearance setting.`,children:(0,M.jsx)(y,{"aria-label":`Theme`,options:Pe,value:e.theme,onChange:e=>t({theme:e})})}),(0,M.jsx)(P,{label:`Accent`,labelId:r,description:c?`${c.label} — used for links, focus rings and the one primary action per surface.`:`Custom hue — used for links, focus rings and the one primary action per surface.`,children:(0,M.jsx)(`div`,{className:j.swatches,role:`radiogroup`,"aria-labelledby":r,children:G.map(e=>{let n=c?.id===e.id;return(0,M.jsx)(`button`,{type:`button`,role:`radio`,"aria-checked":n,"aria-label":e.label,tabIndex:n||!c&&e.id===G[0].id?0:-1,className:j.swatch,style:{background:W(e.h,e.s,e.l)},onClick:()=>t({accentH:e.h,accentS:e.s,accentL:e.l}),children:n?(0,M.jsx)(`span`,{className:j.swatchCheck,children:(0,M.jsx)(oe,{size:12})}):null},e.id)})})}),(0,M.jsx)(P,{label:`Accent channels`,description:`Hue, saturation and lightness are written straight onto the root element — the whole app follows as you drag.`,stacked:!0,children:(0,M.jsxs)(`div`,{className:j.sliderStack,children:[(0,M.jsx)(w,{id:i,label:`Hue`,min:0,max:359,value:e.accentH,valueLabel:`${e.accentH}°`,valueText:`${e.accentH} degrees`,trackImage:ze(e.accentS,e.accentL),onChange:e=>t({accentH:Number(e.currentTarget.value)})}),(0,M.jsx)(w,{id:a,label:`Saturation`,min:0,max:100,value:e.accentS,valueLabel:`${e.accentS}%`,valueText:`${e.accentS} percent`,onChange:e=>t({accentS:Number(e.currentTarget.value)})}),(0,M.jsx)(w,{id:o,label:`Lightness`,min:l.min,max:l.max,value:e.accentL,valueLabel:`${e.accentL}%`,valueText:`${e.accentL} percent`,onChange:e=>t({accentL:Number(e.currentTarget.value)})}),u.failing.length>0?(0,M.jsxs)(`p`,{className:j.contrastWarning,role:`status`,children:[(0,M.jsx)(le,{size:14}),(0,M.jsxs)(`span`,{children:[`This accent falls below 4.5:1 as link text in`,` `,u.failing.length===2?`both themes`:`${u.failing[0]} mode`,`. Raise or lower the lightness to keep it readable.`]})]}):null]})}),(0,M.jsx)(P,{label:`Display size`,description:`Scales text AND spacing together across the whole app, for a large display or a long session. Applies as you pick it.`,children:(0,M.jsx)(y,{"aria-label":`Display size`,options:Fe,value:e.uiScale,onChange:e=>t({uiScale:e})})}),(0,M.jsx)(P,{label:`Density`,description:`Row height and control padding across every view. Independent of display size — a large, tightly packed interface is a valid choice.`,children:(0,M.jsx)(y,{"aria-label":`Density`,options:Ie,value:e.density,onChange:e=>t({density:e})})}),(0,M.jsx)(P,{label:`Display font`,description:`Titles, seat names, metrics and numerals. Body copy stays in the UI sans.`,children:(0,M.jsx)(y,{"aria-label":`Display font`,options:Le,value:e.displayFont,onChange:e=>t({displayFont:e})})}),(0,M.jsx)(P,{label:`Corner radius`,description:`Sharp reads like a terminal; soft reads like a consumer app.`,children:(0,M.jsx)(y,{"aria-label":`Corner radius`,options:Re,value:e.radius,onChange:e=>t({radius:e})})}),(0,M.jsx)(P,{label:`Reduce motion`,htmlFor:s,description:`Collapses every transition to 1ms. Defaults to your system preference; turning it off here overrides that.`,children:(0,M.jsx)(T,{id:s,checked:e.reduceMotion,onChange:e=>t({reduceMotion:e}),"aria-label":`Reduce motion`})}),(0,M.jsx)(P,{label:`Preview`,description:`Live, using the real components.`,stacked:!0,children:(0,M.jsxs)(`div`,{className:j.preview,children:[(0,M.jsx)(`p`,{className:j.previewHeading,children:`Ashlr Verse`}),(0,M.jsxs)(`p`,{className:j.previewBody,children:[`Body copy stays in the UI sans at the reading measure; numerals like`,` `,(0,M.jsx)(`span`,{className:j.previewNumerals,children:`18,420 / 66,000`}),` use the display face.`]}),(0,M.jsxs)(`div`,{className:j.previewRow,children:[(0,M.jsx)(C,{variant:`primary`,size:`sm`,children:`Primary`}),(0,M.jsx)(C,{variant:`subtle`,size:`sm`,children:`Subtle`}),(0,M.jsx)(C,{variant:`ghost`,size:`sm`,children:`Ghost`}),(0,M.jsx)(C,{variant:`danger`,size:`sm`,children:`Destructive`})]}),(0,M.jsxs)(`div`,{className:j.previewRow,children:[(0,M.jsx)(p,{status:`running`}),(0,M.jsx)(b,{engine:`claude`,children:`Claude Max`}),(0,M.jsx)(b,{engine:`local`,mono:!0,children:`qwen3-coder`})]}),(0,M.jsx)(be,{value:18420,max:66e3,label:`Context`}),(0,M.jsx)(D,{"aria-label":`Preview field`,placeholder:`A field at the current density`,size:`sm`})]})})]})}var He={collapsed:`Streams three lines while the model thinks, then folds to “Thought 12s · ~1.8k tok”.`,expanded:`Streams, and stays open when the thinking is done.`,hidden:`No reasoning in the transcript. The live status still says it is thinking, so a long think never looks like a hang.`},K=[`plan`,`accept-edits`,`auto`],q={plan:`Plan`,"accept-edits":`Accept edits`,auto:`Auto`},Ue={plan:`New chats plan and edit nothing until you switch them.`,"accept-edits":`New chats apply edits without asking — the default.`,auto:`New chats run in the CLI’s own auto mode.`},J={minimal:`Minimal`,low:`Low`,medium:`Medium`,high:`High`,xhigh:`Extra high`,max:`Max`},Y=``,We=new Set(K),X=new Set(x);function Z(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function Q(e){if(!Z(e)||!Z(e.global))return null;let t=e=>{let t={};return Z(e)?(typeof e.permissionMode==`string`&&We.has(e.permissionMode)&&(t.permissionMode=e.permissionMode),typeof e.effort==`string`&&X.has(e.effort)&&(t.effort=e.effort),t):t},n={};if(Z(e.seats))for(let[r,i]of Object.entries(e.seats))n[r]=t(i);return{global:t(e.global),seats:n}}function $(e){return e instanceof s&&(e.status===404||e.status===501)?"This server can’t set new-chat defaults yet — update Ashlr and restart `ashlr verse`.":`Couldn’t read the new-chat defaults. Reopen Settings to try again.`}function Ge(){let[e,t]=(0,F.useState)({state:`loading`}),[n,r]=(0,F.useState)(!1),[i,a]=(0,F.useState)(null),o=ve(),s=(0,F.useId)(),c=(0,F.useId)();(0,F.useEffect)(()=>{let e=new AbortController;return ge(e.signal).then(e=>{let n=Q(e);t(n?{state:`ready`,defaults:n}:{state:`unavailable`,message:$(null)})},n=>{e.signal.aborted||t({state:`unavailable`,message:$(n)})}),()=>e.abort()},[]);let l=(0,F.useCallback)(async(e,n)=>{a(null),r(!0);try{let r=await o.run(n,()=>me(e));if(r){let e=Q(r);e&&t({state:`ready`,defaults:e})}}catch(e){a(ye(e))}finally{r(!1)}},[o]);if(e.state===`loading`)return(0,M.jsx)(`p`,{className:j.panelNote,"aria-busy":`true`,children:`Reading new-chat defaults…`});if(e.state===`unavailable`)return(0,M.jsx)(`p`,{className:j.panelNote,children:e.message});let u=e.defaults.global,d=u.permissionMode&&u.permissionMode!==`bypass`?u.permissionMode:`accept-edits`,f=u.effort??null,p=Object.keys(e.defaults.seats).length;return(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(P,{label:`New chats start in`,description:Ue[d],labelId:s,children:(0,M.jsx)(y,{"aria-labelledby":s,size:`sm`,value:d,onChange:e=>{e!==d&&l({permissionMode:e},`Start new chats in ${q[e]}.`)},options:K.map(e=>({value:e,label:q[e],disabled:n}))})}),(0,M.jsx)(P,{label:`Reasoning effort for new chats`,description:p>0?`A seat that can’t use this level starts at its model’s own default. ${p===1?`One seat has its`:`${p} seats have their`} own default, which wins.`:`A seat that can’t use this level starts at its model’s own default.`,htmlFor:c,children:(0,M.jsxs)(E,{id:c,size:`sm`,value:f??Y,disabled:n,onChange:e=>{let t=e.target.value,n=t===Y?null:t;n!==f&&l({effort:n},n?`Start new chats at ${J[n]} effort.`:`Start new chats at the model’s default effort.`)},children:[(0,M.jsx)(`option`,{value:Y,children:`Model default`}),x.map(e=>(0,M.jsx)(`option`,{value:e,children:J[e]},e))]})}),i?(0,M.jsx)(`p`,{className:j.panelNote,role:`alert`,children:i}):null,(0,M.jsx)(m,{...o.dialog})]})}function Ke(){let e=fe(),t=(0,F.useId)();return(0,M.jsxs)(N,{title:`Chat`,children:[(0,M.jsx)(P,{label:`Reasoning`,description:He[e],labelId:t,children:(0,M.jsx)(y,{"aria-labelledby":t,size:`sm`,value:e,onChange:he,options:_e.map(e=>({value:e,label:pe[e]}))})}),(0,M.jsx)(Ge,{})]})}function qe(e){if(e===null)return`locked`;let t=Math.max(0,Math.round((e-Date.now())/6e4));return t<=0?`expiring now`:`unlocked for ${t} more minute${t===1?``:`s`}`}function Je(){let e=o(),t=c(),n=h(),[i,a]=(0,F.useState)(!1),s=(0,F.useRef)(null),l=typeof window>`u`?``:window.location.origin;async function d(){try{await navigator.clipboard.writeText(l),n.show(`Server address copied.`)}catch{n.show(`Could not reach the clipboard — select the field and copy manually.`,`danger`)}}async function m(){a(!1),await u(),n.show(`Disconnected. Paste the read token to reconnect.`)}return(0,M.jsxs)(N,{title:`Connection`,children:[(0,M.jsxs)(P,{label:`Server`,description:`This window talks to one local hub. Nothing leaves your machine.`,children:[(0,M.jsx)(`div`,{className:j.origin,children:(0,M.jsx)(D,{value:l,readOnly:!0,mono:!0,size:`sm`,"aria-label":`Server address`})}),(0,M.jsx)(C,{variant:`ghost`,size:`sm`,icon:(0,M.jsx)(se,{}),onClick:()=>void d(),children:`Copy`})]}),(0,M.jsx)(P,{label:`Read session`,description:`A 15-minute signed cookie, renewed silently while this tab stays open.`,children:(0,M.jsx)(p,{status:e===`authenticated`?`connected`:e===`checking`?`checking`:`disconnected`,tone:e===`authenticated`?`success`:e===`checking`?`running`:`danger`})}),(0,M.jsxs)(P,{label:`Mutation hold`,description:`Every action that changes something needs the mutation token. It is held in memory only, never stored, and clears when this tab closes.`,children:[(0,M.jsx)(p,{status:t.hasHold?qe(t.heldUntil):`locked`,tone:t.hasHold?`success`:`neutral`}),(0,M.jsx)(C,{variant:`subtle`,size:`sm`,icon:(0,M.jsx)(ie,{}),onClick:()=>{r(),n.show(`Mutation hold cleared.`)},disabled:!t.hasHold,children:`Lock now`})]}),(0,M.jsx)(P,{label:`Disconnect`,description:`Ends the read session in this browser and clears the mutation hold. Chats on the server are untouched.`,children:(0,M.jsx)(C,{variant:`danger`,size:`sm`,onClick:()=>a(!0),children:`Disconnect`})}),(0,M.jsx)(`div`,{className:j.row,children:(0,M.jsxs)(`p`,{className:j.note,children:[(0,M.jsx)(`span`,{className:j.noteIcon,children:(0,M.jsx)(ue,{size:14})}),(0,M.jsxs)(`span`,{children:[(0,M.jsx)(`strong`,{children:`Where the tokens come from.`}),` Start the console with`,` `,(0,M.jsx)(`code`,{className:j.code,children:`ashlr verse`}),` — it prints a read token and a mutation token in that terminal, and opens this page. The desktop app injects both for you. Tokens are never displayed here, and the hub never writes them into a page, a log line or an API response. Lost them? Stop the server and start it again; it mints a fresh pair.`]})]})}),(0,M.jsx)(f,{open:i,onClose:()=>a(!1),titleId:`verse-settings-disconnect`,title:`Disconnect from this server?`,description:`You will need the read token again to get back in. Running sessions keep running on the server.`,initialFocusRef:s,children:(0,M.jsxs)(`div`,{className:j.previewRow,style:{justifyContent:`flex-end`},children:[(0,M.jsx)(C,{ref:s,variant:`subtle`,onClick:()=>a(!1),children:`Cancel`}),(0,M.jsx)(C,{variant:`danger`,onClick:()=>void m(),children:`Disconnect`})]})})]})}var Ye=4e3;function Xe(e){let{enabled:t,registered:n,accelerator:r,error:i}=e.hotkey;return t?n?`Press ${r} in any app to bring Verse forward with the composer focused.`:`${r} is not active: ${i??`another app already uses it`}. Free the shortcut in that app, or turn this off.`:`Off. Turning it on takes ${r} away from every other app on this Mac.`}function Ze(e){let t=e.notifications.enabled?`Finished and failed chats, and new items that need you — only while Verse is in the background.`:`Off. The tray and the Dock badge still show what needs you.`;return e.notifications.delivery===`script`?`${t} On this unsigned build banners appear as Script Editor, and clicking one opens Script Editor rather than Verse.`:t}function Qe(){let e=te(),[t,n]=(0,F.useState)(null),[r,i]=(0,F.useState)(null),a=(0,F.useRef)(null);if((0,F.useEffect)(()=>{n(null),i(null),a.current!==null&&window.clearTimeout(a.current),a.current=null},[e]),(0,F.useEffect)(()=>()=>{a.current!==null&&window.clearTimeout(a.current)},[]),e===null)return(0,M.jsx)(N,{title:`Desktop`,children:(0,M.jsx)(`p`,{className:j.panelNote,"aria-busy":g()||void 0,children:g()?`Reading the desktop app’s settings…`:`The system-wide shortcut and notifications are available in the Verse desktop app.`})});function o(e,t){if(i(null),!v(e,t)){i(`The desktop app did not take the change. Nothing was changed.`);return}n(e),a.current!==null&&window.clearTimeout(a.current),a.current=window.setTimeout(()=>{a.current=null,n(null),i(`The desktop app did not answer. The switches show what it last reported.`)},Ye)}let s=e.hotkey.enabled&&!e.hotkey.registered;return(0,M.jsxs)(N,{title:`Desktop`,children:[(0,M.jsx)(P,{label:`System-wide shortcut (${e.hotkey.accelerator})`,description:(0,M.jsx)(`span`,{"data-tone":s?`warning`:void 0,role:s?`status`:void 0,children:Xe(e)}),children:(0,M.jsx)(T,{"aria-label":`System-wide shortcut`,checked:e.hotkey.enabled,disabled:t!==null,onChange:e=>o(`globalHotkey`,e)})}),(0,M.jsx)(P,{label:`Notifications`,description:Ze(e),children:(0,M.jsx)(T,{"aria-label":`Notifications`,checked:e.notifications.enabled,disabled:t!==null,onChange:e=>o(`notifications`,e)})}),t?(0,M.jsx)(`p`,{className:j.panelNote,role:`status`,children:`Waiting for the desktop app…`}):null,r?(0,M.jsx)(`p`,{className:j.panelNote,role:`alert`,children:r}):null]})}function $e(){let e=(0,F.useMemo)(()=>_(),[]),t=de(`shortcuts.open`)?.keys[0];return(0,M.jsxs)(N,{title:`Keyboard`,children:[(0,M.jsx)(`p`,{className:j.panelNote,children:t?`${ee(t,e)} shows this list from anywhere.`:null}),(0,M.jsx)(A,{platform:e})]})}function et(){let{appearance:e,set:t,reset:n}=a();return(0,M.jsxs)(`div`,{className:j.section,children:[(0,M.jsx)(`header`,{className:j.strip,"data-app-region":`drag`,children:(0,M.jsx)(`h2`,{className:j.stripTitle,children:`Settings`})}),(0,M.jsx)(`div`,{className:j.scroll,children:(0,M.jsxs)(`div`,{className:j.column,children:[(0,M.jsx)(Ve,{appearance:e,onChange:t,onReset:n}),(0,M.jsx)(Ke,{}),(0,M.jsx)(Qe,{}),(0,M.jsx)(Je,{}),(0,M.jsx)($e,{}),(0,M.jsx)(Se,{}),(0,M.jsx)(Te,{})]})})]})}export{et as SettingsSection};
2
+ //# sourceMappingURL=SettingsSection-Bf74l0Gj.js.map