@shepai/cli 1.167.0 → 1.168.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 (360) hide show
  1. package/dist/packages/core/src/application/ports/output/agents/interactive-agent-executor.interface.d.ts +38 -2
  2. package/dist/packages/core/src/application/ports/output/agents/interactive-agent-executor.interface.d.ts.map +1 -1
  3. package/dist/packages/core/src/application/ports/output/services/interactive-session-service.interface.d.ts +16 -1
  4. package/dist/packages/core/src/application/ports/output/services/interactive-session-service.interface.d.ts.map +1 -1
  5. package/dist/packages/core/src/application/use-cases/interactive/index.d.ts +2 -0
  6. package/dist/packages/core/src/application/use-cases/interactive/index.d.ts.map +1 -1
  7. package/dist/packages/core/src/application/use-cases/interactive/index.js +1 -0
  8. package/dist/packages/core/src/application/use-cases/interactive/respond-to-interaction.use-case.d.ts +17 -0
  9. package/dist/packages/core/src/application/use-cases/interactive/respond-to-interaction.use-case.d.ts.map +1 -0
  10. package/dist/packages/core/src/application/use-cases/interactive/respond-to-interaction.use-case.js +34 -0
  11. package/dist/packages/core/src/application/use-cases/repositories/delete-repository.use-case.d.ts.map +1 -1
  12. package/dist/packages/core/src/application/use-cases/repositories/delete-repository.use-case.js +6 -2
  13. package/dist/packages/core/src/infrastructure/di/container.d.ts.map +1 -1
  14. package/dist/packages/core/src/infrastructure/di/container.js +5 -0
  15. package/dist/packages/core/src/infrastructure/services/agents/common/executors/claude-code-interactive-executor.service.d.ts +3 -0
  16. package/dist/packages/core/src/infrastructure/services/agents/common/executors/claude-code-interactive-executor.service.d.ts.map +1 -1
  17. package/dist/packages/core/src/infrastructure/services/agents/common/executors/claude-code-interactive-executor.service.js +59 -6
  18. package/dist/packages/core/src/infrastructure/services/interactive/interactive-session.service.d.ts +7 -0
  19. package/dist/packages/core/src/infrastructure/services/interactive/interactive-session.service.d.ts.map +1 -1
  20. package/dist/packages/core/src/infrastructure/services/interactive/interactive-session.service.js +101 -1
  21. package/dist/src/presentation/web/app/api/interactive/chat/[featureId]/respond/route.d.ts +19 -0
  22. package/dist/src/presentation/web/app/api/interactive/chat/[featureId]/respond/route.d.ts.map +1 -0
  23. package/dist/src/presentation/web/app/api/interactive/chat/[featureId]/respond/route.js +33 -0
  24. package/dist/src/presentation/web/app/api/interactive/chat/[featureId]/stream/route.d.ts.map +1 -1
  25. package/dist/src/presentation/web/app/api/interactive/chat/[featureId]/stream/route.js +7 -0
  26. package/dist/src/presentation/web/app/layout.d.ts +0 -1
  27. package/dist/src/presentation/web/app/layout.d.ts.map +1 -1
  28. package/dist/src/presentation/web/app/layout.js +0 -1
  29. package/dist/src/presentation/web/components/assistant-ui/thread.d.ts +3 -2
  30. package/dist/src/presentation/web/components/assistant-ui/thread.d.ts.map +1 -1
  31. package/dist/src/presentation/web/components/assistant-ui/thread.js +26 -3
  32. package/dist/src/presentation/web/components/common/react-file-manager-dialog/react-file-manager-dialog.d.ts.map +1 -1
  33. package/dist/src/presentation/web/components/common/react-file-manager-dialog/react-file-manager-dialog.js +68 -56
  34. package/dist/src/presentation/web/components/features/chat/ChatDotIndicator.d.ts +1 -0
  35. package/dist/src/presentation/web/components/features/chat/ChatDotIndicator.d.ts.map +1 -1
  36. package/dist/src/presentation/web/components/features/chat/ChatDotIndicator.js +7 -1
  37. package/dist/src/presentation/web/components/features/chat/ChatDotIndicator.stories.d.ts +1 -0
  38. package/dist/src/presentation/web/components/features/chat/ChatDotIndicator.stories.d.ts.map +1 -1
  39. package/dist/src/presentation/web/components/features/chat/ChatDotIndicator.stories.js +3 -0
  40. package/dist/src/presentation/web/components/features/chat/ChatSheet.d.ts.map +1 -1
  41. package/dist/src/presentation/web/components/features/chat/ChatSheet.js +3 -1
  42. package/dist/src/presentation/web/components/features/chat/ChatTab.d.ts.map +1 -1
  43. package/dist/src/presentation/web/components/features/chat/ChatTab.js +3 -2
  44. package/dist/src/presentation/web/components/features/chat/InteractionBubble.d.ts +33 -0
  45. package/dist/src/presentation/web/components/features/chat/InteractionBubble.d.ts.map +1 -0
  46. package/dist/src/presentation/web/components/features/chat/InteractionBubble.js +155 -0
  47. package/dist/src/presentation/web/components/features/chat/InteractionBubble.stories.d.ts +22 -0
  48. package/dist/src/presentation/web/components/features/chat/InteractionBubble.stories.d.ts.map +1 -0
  49. package/dist/src/presentation/web/components/features/chat/InteractionBubble.stories.js +107 -0
  50. package/dist/src/presentation/web/components/features/chat/useChatRuntime.d.ts +16 -0
  51. package/dist/src/presentation/web/components/features/chat/useChatRuntime.d.ts.map +1 -1
  52. package/dist/src/presentation/web/components/features/chat/useChatRuntime.js +62 -1
  53. package/dist/src/presentation/web/components/features/control-center/control-center-inner.d.ts.map +1 -1
  54. package/dist/src/presentation/web/components/features/control-center/control-center-inner.js +18 -3
  55. package/dist/src/presentation/web/components/features/control-center/use-control-center-state.d.ts +1 -0
  56. package/dist/src/presentation/web/components/features/control-center/use-control-center-state.d.ts.map +1 -1
  57. package/dist/src/presentation/web/components/features/control-center/use-control-center-state.js +1 -1
  58. package/dist/src/presentation/web/hooks/use-graph-state.d.ts.map +1 -1
  59. package/dist/src/presentation/web/hooks/use-graph-state.js +16 -0
  60. package/dist/src/presentation/web/hooks/use-turn-statuses.d.ts +1 -1
  61. package/dist/src/presentation/web/hooks/use-turn-statuses.d.ts.map +1 -1
  62. package/dist/src/presentation/web/hooks/use-turn-statuses.js +1 -1
  63. package/dist/tsconfig.build.tsbuildinfo +1 -1
  64. package/package.json +1 -1
  65. package/web/.next/BUILD_ID +1 -1
  66. package/web/.next/app-path-routes-manifest.json +1 -0
  67. package/web/.next/build-manifest.json +7 -7
  68. package/web/.next/fallback-build-manifest.json +2 -2
  69. package/web/.next/prerender-manifest.json +3 -3
  70. package/web/.next/required-server-files.js +2 -2
  71. package/web/.next/required-server-files.json +2 -2
  72. package/web/.next/routes-manifest.json +8 -0
  73. package/web/.next/server/app/(dashboard)/@drawer/adopt/page/build-manifest.json +5 -5
  74. package/web/.next/server/app/(dashboard)/@drawer/adopt/page/react-loadable-manifest.json +1 -8
  75. package/web/.next/server/app/(dashboard)/@drawer/adopt/page/server-reference-manifest.json +29 -29
  76. package/web/.next/server/app/(dashboard)/@drawer/adopt/page.js +1 -1
  77. package/web/.next/server/app/(dashboard)/@drawer/adopt/page.js.nft.json +1 -1
  78. package/web/.next/server/app/(dashboard)/@drawer/adopt/page_client-reference-manifest.js +1 -1
  79. package/web/.next/server/app/(dashboard)/@drawer/chat/page/build-manifest.json +5 -5
  80. package/web/.next/server/app/(dashboard)/@drawer/chat/page/react-loadable-manifest.json +1 -8
  81. package/web/.next/server/app/(dashboard)/@drawer/chat/page/server-reference-manifest.json +27 -27
  82. package/web/.next/server/app/(dashboard)/@drawer/chat/page.js +1 -1
  83. package/web/.next/server/app/(dashboard)/@drawer/chat/page.js.nft.json +1 -1
  84. package/web/.next/server/app/(dashboard)/@drawer/chat/page_client-reference-manifest.js +1 -1
  85. package/web/.next/server/app/(dashboard)/@drawer/create/page/build-manifest.json +5 -5
  86. package/web/.next/server/app/(dashboard)/@drawer/create/page/react-loadable-manifest.json +1 -8
  87. package/web/.next/server/app/(dashboard)/@drawer/create/page/server-reference-manifest.json +30 -30
  88. package/web/.next/server/app/(dashboard)/@drawer/create/page.js +1 -1
  89. package/web/.next/server/app/(dashboard)/@drawer/create/page.js.nft.json +1 -1
  90. package/web/.next/server/app/(dashboard)/@drawer/create/page_client-reference-manifest.js +1 -1
  91. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page/build-manifest.json +5 -5
  92. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page/react-loadable-manifest.json +1 -8
  93. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page/server-reference-manifest.json +38 -38
  94. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js +1 -1
  95. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js.nft.json +1 -1
  96. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
  97. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page/build-manifest.json +5 -5
  98. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page/react-loadable-manifest.json +1 -8
  99. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page/server-reference-manifest.json +38 -38
  100. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js +1 -1
  101. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js.nft.json +1 -1
  102. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page_client-reference-manifest.js +1 -1
  103. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page/build-manifest.json +5 -5
  104. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page/react-loadable-manifest.json +1 -8
  105. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page/server-reference-manifest.json +28 -28
  106. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page.js +1 -1
  107. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page.js.nft.json +1 -1
  108. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/[tab]/page_client-reference-manifest.js +1 -1
  109. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page/build-manifest.json +5 -5
  110. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page/react-loadable-manifest.json +1 -8
  111. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page/server-reference-manifest.json +28 -28
  112. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page.js +1 -1
  113. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page.js.nft.json +1 -1
  114. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
  115. package/web/.next/server/app/(dashboard)/chat/page/build-manifest.json +5 -5
  116. package/web/.next/server/app/(dashboard)/chat/page/react-loadable-manifest.json +1 -8
  117. package/web/.next/server/app/(dashboard)/chat/page/server-reference-manifest.json +27 -27
  118. package/web/.next/server/app/(dashboard)/chat/page.js +1 -1
  119. package/web/.next/server/app/(dashboard)/chat/page.js.nft.json +1 -1
  120. package/web/.next/server/app/(dashboard)/chat/page_client-reference-manifest.js +1 -1
  121. package/web/.next/server/app/(dashboard)/create/page/build-manifest.json +5 -5
  122. package/web/.next/server/app/(dashboard)/create/page/react-loadable-manifest.json +1 -8
  123. package/web/.next/server/app/(dashboard)/create/page/server-reference-manifest.json +30 -30
  124. package/web/.next/server/app/(dashboard)/create/page.js +1 -1
  125. package/web/.next/server/app/(dashboard)/create/page.js.nft.json +1 -1
  126. package/web/.next/server/app/(dashboard)/create/page_client-reference-manifest.js +1 -1
  127. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page/build-manifest.json +5 -5
  128. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page/react-loadable-manifest.json +1 -8
  129. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page/server-reference-manifest.json +38 -38
  130. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js +1 -1
  131. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js.nft.json +1 -1
  132. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
  133. package/web/.next/server/app/(dashboard)/feature/[featureId]/page/build-manifest.json +5 -5
  134. package/web/.next/server/app/(dashboard)/feature/[featureId]/page/react-loadable-manifest.json +1 -8
  135. package/web/.next/server/app/(dashboard)/feature/[featureId]/page/server-reference-manifest.json +38 -38
  136. package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js +1 -1
  137. package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js.nft.json +1 -1
  138. package/web/.next/server/app/(dashboard)/feature/[featureId]/page_client-reference-manifest.js +1 -1
  139. package/web/.next/server/app/(dashboard)/page/build-manifest.json +5 -5
  140. package/web/.next/server/app/(dashboard)/page/react-loadable-manifest.json +1 -8
  141. package/web/.next/server/app/(dashboard)/page/server-reference-manifest.json +27 -27
  142. package/web/.next/server/app/(dashboard)/page.js +1 -1
  143. package/web/.next/server/app/(dashboard)/page.js.nft.json +1 -1
  144. package/web/.next/server/app/(dashboard)/page_client-reference-manifest.js +1 -1
  145. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page/build-manifest.json +5 -5
  146. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page/react-loadable-manifest.json +1 -8
  147. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page/server-reference-manifest.json +28 -28
  148. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page.js +1 -1
  149. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page.js.nft.json +1 -1
  150. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/[tab]/page_client-reference-manifest.js +1 -1
  151. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page/build-manifest.json +5 -5
  152. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page/react-loadable-manifest.json +1 -8
  153. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page/server-reference-manifest.json +28 -28
  154. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page.js +1 -1
  155. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page.js.nft.json +1 -1
  156. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
  157. package/web/.next/server/app/_global-error/page/build-manifest.json +5 -5
  158. package/web/.next/server/app/_global-error/page.js +1 -1
  159. package/web/.next/server/app/_global-error/page.js.nft.json +1 -1
  160. package/web/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
  161. package/web/.next/server/app/_global-error.html +2 -2
  162. package/web/.next/server/app/_global-error.rsc +7 -7
  163. package/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +2 -2
  164. package/web/.next/server/app/_global-error.segments/_full.segment.rsc +7 -7
  165. package/web/.next/server/app/_global-error.segments/_head.segment.rsc +3 -3
  166. package/web/.next/server/app/_global-error.segments/_index.segment.rsc +3 -3
  167. package/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  168. package/web/.next/server/app/_not-found/page/build-manifest.json +5 -5
  169. package/web/.next/server/app/_not-found/page/react-loadable-manifest.json +1 -8
  170. package/web/.next/server/app/_not-found/page/server-reference-manifest.json +6 -6
  171. package/web/.next/server/app/_not-found/page.js +1 -1
  172. package/web/.next/server/app/_not-found/page.js.nft.json +1 -1
  173. package/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  174. package/web/.next/server/app/api/attachments/preview/route.js.nft.json +1 -1
  175. package/web/.next/server/app/api/evidence/route.js.nft.json +1 -1
  176. package/web/.next/server/app/api/graph-data/route.js.nft.json +1 -1
  177. package/web/.next/server/app/api/interactive/chat/[featureId]/messages/route.js.nft.json +1 -1
  178. package/web/.next/server/app/api/interactive/chat/[featureId]/respond/route/app-paths-manifest.json +3 -0
  179. package/web/.next/server/app/api/interactive/chat/[featureId]/respond/route/build-manifest.json +11 -0
  180. package/web/.next/server/app/api/interactive/chat/[featureId]/respond/route/server-reference-manifest.json +4 -0
  181. package/web/.next/server/app/api/interactive/chat/[featureId]/respond/route.js +7 -0
  182. package/web/.next/server/app/api/interactive/chat/[featureId]/respond/route.js.map +5 -0
  183. package/web/.next/server/app/api/interactive/chat/[featureId]/respond/route.js.nft.json +1 -0
  184. package/web/.next/server/app/api/interactive/chat/[featureId]/respond/route_client-reference-manifest.js +2 -0
  185. package/web/.next/server/app/settings/page/build-manifest.json +5 -5
  186. package/web/.next/server/app/settings/page/react-loadable-manifest.json +1 -8
  187. package/web/.next/server/app/settings/page/server-reference-manifest.json +9 -9
  188. package/web/.next/server/app/settings/page.js +1 -1
  189. package/web/.next/server/app/settings/page.js.nft.json +1 -1
  190. package/web/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  191. package/web/.next/server/app/skills/page/build-manifest.json +5 -5
  192. package/web/.next/server/app/skills/page/react-loadable-manifest.json +1 -8
  193. package/web/.next/server/app/skills/page/server-reference-manifest.json +11 -11
  194. package/web/.next/server/app/skills/page.js +1 -1
  195. package/web/.next/server/app/skills/page.js.nft.json +1 -1
  196. package/web/.next/server/app/skills/page_client-reference-manifest.js +1 -1
  197. package/web/.next/server/app/tools/page/build-manifest.json +5 -5
  198. package/web/.next/server/app/tools/page/react-loadable-manifest.json +1 -8
  199. package/web/.next/server/app/tools/page/server-reference-manifest.json +11 -11
  200. package/web/.next/server/app/tools/page.js +1 -1
  201. package/web/.next/server/app/tools/page.js.nft.json +1 -1
  202. package/web/.next/server/app/tools/page_client-reference-manifest.js +1 -1
  203. package/web/.next/server/app/version/page/build-manifest.json +5 -5
  204. package/web/.next/server/app/version/page/react-loadable-manifest.json +1 -8
  205. package/web/.next/server/app/version/page/server-reference-manifest.json +6 -6
  206. package/web/.next/server/app/version/page.js +1 -1
  207. package/web/.next/server/app/version/page.js.nft.json +1 -1
  208. package/web/.next/server/app/version/page_client-reference-manifest.js +1 -1
  209. package/web/.next/server/app-paths-manifest.json +1 -0
  210. package/web/.next/server/chunks/8ba4b_server_app_api_interactive_chat_[featureId]_respond_route_actions_990d51bd.js +3 -0
  211. package/web/.next/server/chunks/8ba4b_server_app_api_interactive_chat_[featureId]_respond_route_actions_990d51bd.js.map +1 -0
  212. package/web/.next/server/chunks/[root-of-the-server]__31944fa2._.js +3 -0
  213. package/web/.next/server/chunks/[root-of-the-server]__31944fa2._.js.map +1 -0
  214. package/web/.next/server/chunks/[root-of-the-server]__8a281f8d._.js +9 -3
  215. package/web/.next/server/chunks/[root-of-the-server]__8a281f8d._.js.map +1 -1
  216. package/web/.next/server/chunks/[root-of-the-server]__a402b567._.js +1 -1
  217. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js +1 -1
  218. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js.map +1 -1
  219. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_feature-drawer-client_tsx_e9755fc8._.js +2 -2
  220. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_feature-drawer-client_tsx_e9755fc8._.js.map +1 -1
  221. package/web/.next/server/chunks/ssr/[root-of-the-server]__1abe77bb._.js +2 -2
  222. package/web/.next/server/chunks/ssr/[root-of-the-server]__1abe77bb._.js.map +1 -1
  223. package/web/.next/server/chunks/ssr/[root-of-the-server]__1f389e5d._.js +1 -1
  224. package/web/.next/server/chunks/ssr/[root-of-the-server]__1f389e5d._.js.map +1 -1
  225. package/web/.next/server/chunks/ssr/[root-of-the-server]__357d99f9._.js +1 -1
  226. package/web/.next/server/chunks/ssr/[root-of-the-server]__4fb81977._.js +1 -1
  227. package/web/.next/server/chunks/ssr/[root-of-the-server]__4fb81977._.js.map +1 -1
  228. package/web/.next/server/chunks/ssr/[root-of-the-server]__7562afc6._.js +2 -2
  229. package/web/.next/server/chunks/ssr/[root-of-the-server]__7562afc6._.js.map +1 -1
  230. package/web/.next/server/chunks/ssr/[root-of-the-server]__7dcd0917._.js +1 -1
  231. package/web/.next/server/chunks/ssr/[root-of-the-server]__7dcd0917._.js.map +1 -1
  232. package/web/.next/server/chunks/ssr/[root-of-the-server]__86ff0bc5._.js +2 -2
  233. package/web/.next/server/chunks/ssr/[root-of-the-server]__86ff0bc5._.js.map +1 -1
  234. package/web/.next/server/chunks/ssr/[root-of-the-server]__8b0aac03._.js +1 -1
  235. package/web/.next/server/chunks/ssr/[root-of-the-server]__b7b96453._.js +1 -1
  236. package/web/.next/server/chunks/ssr/[root-of-the-server]__b7b96453._.js.map +1 -1
  237. package/web/.next/server/chunks/ssr/[root-of-the-server]__ba7f5873._.js +1 -1
  238. package/web/.next/server/chunks/ssr/[root-of-the-server]__ba7f5873._.js.map +1 -1
  239. package/web/.next/server/chunks/ssr/[root-of-the-server]__c5e09f6f._.js +1 -1
  240. package/web/.next/server/chunks/ssr/[root-of-the-server]__c5e09f6f._.js.map +1 -1
  241. package/web/.next/server/chunks/ssr/[root-of-the-server]__d5e22d1a._.js +3 -0
  242. package/web/.next/server/chunks/ssr/{[root-of-the-server]__efeeaed4._.js.map → [root-of-the-server]__d5e22d1a._.js.map} +1 -1
  243. package/web/.next/server/chunks/ssr/[root-of-the-server]__f2acfd0e._.js +3 -0
  244. package/web/.next/server/chunks/ssr/[root-of-the-server]__f2acfd0e._.js.map +1 -0
  245. package/web/.next/server/chunks/ssr/[root-of-the-server]__f5614810._.js +3 -0
  246. package/web/.next/server/chunks/ssr/{[root-of-the-server]__d1040bd1._.js.map → [root-of-the-server]__f5614810._.js.map} +1 -1
  247. package/web/.next/server/chunks/ssr/_02e01240._.js +1 -1
  248. package/web/.next/server/chunks/ssr/_02e01240._.js.map +1 -1
  249. package/web/.next/server/chunks/ssr/_05c23ad9._.js +1 -1
  250. package/web/.next/server/chunks/ssr/_05c23ad9._.js.map +1 -1
  251. package/web/.next/server/chunks/ssr/_0727935d._.js +1 -1
  252. package/web/.next/server/chunks/ssr/_0727935d._.js.map +1 -1
  253. package/web/.next/server/chunks/ssr/_0edaf547._.js +3 -0
  254. package/web/.next/server/chunks/ssr/_0edaf547._.js.map +1 -0
  255. package/web/.next/server/chunks/ssr/_16eb4fec._.js +1 -1
  256. package/web/.next/server/chunks/ssr/_16eb4fec._.js.map +1 -1
  257. package/web/.next/server/chunks/ssr/_18886033._.js +1 -1
  258. package/web/.next/server/chunks/ssr/_18886033._.js.map +1 -1
  259. package/web/.next/server/chunks/ssr/_1e08a336._.js.map +1 -1
  260. package/web/.next/server/chunks/ssr/_22e00a14._.js +1 -1
  261. package/web/.next/server/chunks/ssr/_22e00a14._.js.map +1 -1
  262. package/web/.next/server/chunks/ssr/_4cbb7f95._.js +3 -0
  263. package/web/.next/server/chunks/ssr/_4cbb7f95._.js.map +1 -0
  264. package/web/.next/server/chunks/ssr/_56b9d60f._.js +1 -1
  265. package/web/.next/server/chunks/ssr/_56b9d60f._.js.map +1 -1
  266. package/web/.next/server/chunks/ssr/{_a5913a26._.js → _573d0b23._.js} +2 -2
  267. package/web/.next/server/chunks/ssr/{_a5913a26._.js.map → _573d0b23._.js.map} +1 -1
  268. package/web/.next/server/chunks/ssr/{_506a3bc3._.js → _682fc996._.js} +2 -2
  269. package/web/.next/server/chunks/ssr/_682fc996._.js.map +1 -0
  270. package/web/.next/server/chunks/ssr/{_b4c3ffcc._.js → _7b3ec8ac._.js} +2 -2
  271. package/web/.next/server/chunks/ssr/{_b4c3ffcc._.js.map → _7b3ec8ac._.js.map} +1 -1
  272. package/web/.next/server/chunks/ssr/_9a9ec6e6._.js +3 -0
  273. package/web/.next/server/chunks/ssr/_9a9ec6e6._.js.map +1 -0
  274. package/web/.next/server/chunks/ssr/_a1068852._.js +3 -0
  275. package/web/.next/server/chunks/ssr/_a1068852._.js.map +1 -0
  276. package/web/.next/server/chunks/ssr/_a5a5901d._.js +1 -1
  277. package/web/.next/server/chunks/ssr/_a5a5901d._.js.map +1 -1
  278. package/web/.next/server/chunks/ssr/_ad09f271._.js +1 -1
  279. package/web/.next/server/chunks/ssr/_ad09f271._.js.map +1 -1
  280. package/web/.next/server/chunks/ssr/_c3f595c6._.js +1 -1
  281. package/web/.next/server/chunks/ssr/_c3f595c6._.js.map +1 -1
  282. package/web/.next/server/chunks/ssr/_ea9e1556._.js +1 -1
  283. package/web/.next/server/chunks/ssr/_ea9e1556._.js.map +1 -1
  284. package/web/.next/server/chunks/ssr/_f1ba9be6._.js +2 -2
  285. package/web/.next/server/chunks/ssr/_f1ba9be6._.js.map +1 -1
  286. package/web/.next/server/chunks/ssr/_f33cd07e._.js +2 -2
  287. package/web/.next/server/chunks/ssr/_f33cd07e._.js.map +1 -1
  288. package/web/.next/server/chunks/ssr/_f8b45233._.js +1 -1
  289. package/web/.next/server/chunks/ssr/_f8b45233._.js.map +1 -1
  290. package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js +1 -1
  291. package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js.map +1 -1
  292. package/web/.next/server/chunks/ssr/f3a1f_components_common_control-center-drawer_repository-drawer-client_tsx_39a00c03._.js +1 -1
  293. package/web/.next/server/chunks/ssr/f3a1f_components_common_control-center-drawer_repository-drawer-client_tsx_39a00c03._.js.map +1 -1
  294. package/web/.next/server/chunks/ssr/node_modules__pnpm_12a7ede0._.js +3 -0
  295. package/web/.next/server/chunks/ssr/node_modules__pnpm_12a7ede0._.js.map +1 -0
  296. package/web/.next/server/chunks/ssr/src_presentation_web_app_actions_open-ide_ts_baaca5d5._.js +1 -1
  297. package/web/.next/server/chunks/ssr/src_presentation_web_components_895e5bfa._.js +1 -1
  298. package/web/.next/server/chunks/ssr/src_presentation_web_components_895e5bfa._.js.map +1 -1
  299. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js +1 -1
  300. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js.map +1 -1
  301. package/web/.next/server/chunks/ssr/src_presentation_web_components_ui_select_tsx_45d6b8ae._.js +1 -1
  302. package/web/.next/server/chunks/ssr/src_presentation_web_components_ui_select_tsx_45d6b8ae._.js.map +1 -1
  303. package/web/.next/server/middleware-build-manifest.js +5 -5
  304. package/web/.next/server/pages/500.html +2 -2
  305. package/web/.next/server/server-reference-manifest.js +1 -1
  306. package/web/.next/server/server-reference-manifest.json +48 -48
  307. package/web/.next/static/chunks/{fe70e73feb07bcfd.js → 08ec4c9ab61717aa.js} +1 -1
  308. package/web/.next/static/chunks/{dedf6ca63c5468fa.js → 09edd35d194bec06.js} +3 -3
  309. package/web/.next/static/chunks/{d6a1facd04a52af5.js → 0d5dda068da311fc.js} +3 -3
  310. package/web/.next/static/chunks/{7a7d7e71cf9b5a4e.js → 0db171679d1838bf.js} +1 -1
  311. package/web/.next/static/chunks/11cb8f996a5570ac.js +1 -0
  312. package/web/.next/static/chunks/{d4d8f0a137bd2eb4.js → 12803afee7d0afc8.js} +2 -2
  313. package/web/.next/static/chunks/14c1725595d10639.js +1 -0
  314. package/web/.next/static/chunks/{8866edda931a81c2.js → 1d82462f51924d3f.js} +1 -1
  315. package/web/.next/static/chunks/1fe75f9dd488d557.css +1 -0
  316. package/web/.next/static/chunks/2547ef4764d5a053.js +7 -0
  317. package/web/.next/static/chunks/35f8b762c261aa01.js +1 -0
  318. package/web/.next/static/chunks/4623ea78122c2d4d.js +1 -0
  319. package/web/.next/static/chunks/{d7eebb5c0aa9e101.js → 72b7a7374227b47e.js} +2 -2
  320. package/web/.next/static/chunks/84a181ff3270fd9f.js +1 -0
  321. package/web/.next/static/chunks/9531dfbcff94c28b.js +1 -0
  322. package/web/.next/static/chunks/{3f404f608aebc7bb.js → d67238b43d323f1d.js} +1 -1
  323. package/web/.next/static/chunks/daa74d46f5e8b397.js +3 -0
  324. package/web/.next/static/chunks/ed3a602003bcb31b.js +1 -0
  325. package/web/.next/static/chunks/ef1faff4c5100183.js +1 -0
  326. package/web/.next/static/chunks/{0be57768a211221a.js → f0825a7dc6f4fb83.js} +1 -1
  327. package/web/.next/static/chunks/fa024fa35b1b47ff.js +1 -0
  328. package/web/.next/static/chunks/{turbopack-432ef324fc27240c.js → turbopack-8a46f5841d1dbe2e.js} +1 -1
  329. package/web/.next/server/chunks/ssr/[root-of-the-server]__2d0c3840._.js +0 -3
  330. package/web/.next/server/chunks/ssr/[root-of-the-server]__2d0c3840._.js.map +0 -1
  331. package/web/.next/server/chunks/ssr/[root-of-the-server]__d1040bd1._.js +0 -3
  332. package/web/.next/server/chunks/ssr/[root-of-the-server]__efeeaed4._.js +0 -3
  333. package/web/.next/server/chunks/ssr/_3bcda5d7._.js +0 -3
  334. package/web/.next/server/chunks/ssr/_3bcda5d7._.js.map +0 -1
  335. package/web/.next/server/chunks/ssr/_4d49a312._.js +0 -3
  336. package/web/.next/server/chunks/ssr/_4d49a312._.js.map +0 -1
  337. package/web/.next/server/chunks/ssr/_506a3bc3._.js.map +0 -1
  338. package/web/.next/server/chunks/ssr/_5ab8e97d._.js +0 -3
  339. package/web/.next/server/chunks/ssr/_5ab8e97d._.js.map +0 -1
  340. package/web/.next/server/chunks/ssr/_9215e9ec._.js +0 -3
  341. package/web/.next/server/chunks/ssr/_9215e9ec._.js.map +0 -1
  342. package/web/.next/server/chunks/ssr/node_modules__pnpm_1300ae39._.js +0 -3
  343. package/web/.next/server/chunks/ssr/node_modules__pnpm_1300ae39._.js.map +0 -1
  344. package/web/.next/static/chunks/3208dc997aaee4d3.css +0 -1
  345. package/web/.next/static/chunks/3deefc76ea55047c.js +0 -1
  346. package/web/.next/static/chunks/40b6bcf1a2de4a0f.js +0 -1
  347. package/web/.next/static/chunks/420eb8b33d83c4cb.js +0 -1
  348. package/web/.next/static/chunks/63b0ad1dbc27a5d0.js +0 -1
  349. package/web/.next/static/chunks/65440524d7ee7d13.js +0 -1
  350. package/web/.next/static/chunks/6c634b447a6a0db8.js +0 -7
  351. package/web/.next/static/chunks/6d7b999c99d6d175.js +0 -9
  352. package/web/.next/static/chunks/6eb32cd5d2795a7c.js +0 -1
  353. package/web/.next/static/chunks/7f4d1ec4e9f921a3.js +0 -1
  354. package/web/.next/static/chunks/8180973e9cd6a99e.css +0 -1
  355. package/web/.next/static/chunks/c7e793951b20a67f.js +0 -1
  356. package/web/.next/static/chunks/da6d0839a24602eb.js +0 -3
  357. package/web/.next/static/chunks/db3bf9eb0b519bae.js +0 -1
  358. /package/web/.next/static/{JjjyVzk5ESdcMWkH6999z → kmMMaSvcntYsYhsTwYqdC}/_buildManifest.js +0 -0
  359. /package/web/.next/static/{JjjyVzk5ESdcMWkH6999z → kmMMaSvcntYsYhsTwYqdC}/_clientMiddlewareManifest.json +0 -0
  360. /package/web/.next/static/{JjjyVzk5ESdcMWkH6999z → kmMMaSvcntYsYhsTwYqdC}/_ssgManifest.js +0 -0
@@ -0,0 +1,33 @@
1
+ /**
2
+ * Respond to a pending agent interaction (AskUserQuestion).
3
+ *
4
+ * POST - Submit user's answers to the pending interaction.
5
+ * The agent resumes processing after receiving the response.
6
+ *
7
+ * `featureId` is a polymorphic scope key: a feature UUID, "repo-<id>", or "global".
8
+ */
9
+ import { NextResponse } from 'next/server';
10
+ import { resolve } from '../../../../../../lib/server-container.js';
11
+ export const dynamic = 'force-dynamic';
12
+ export async function POST(request, { params }) {
13
+ try {
14
+ const { featureId } = await params;
15
+ const body = (await request.json());
16
+ if (!body.answers || typeof body.answers !== 'object') {
17
+ return NextResponse.json({ error: 'answers must be a non-empty object' }, { status: 400 });
18
+ }
19
+ const useCase = resolve('RespondToInteractionUseCase');
20
+ await useCase.execute({
21
+ featureId,
22
+ answers: body.answers,
23
+ });
24
+ return NextResponse.json({ ok: true });
25
+ }
26
+ catch (error) {
27
+ const message = error instanceof Error ? error.message : String(error);
28
+ const status = message.includes('No pending interaction') ? 409 : 500;
29
+ // eslint-disable-next-line no-console
30
+ console.error('[POST /api/interactive/chat/:featureId/respond]', error);
31
+ return NextResponse.json({ error: message }, { status });
32
+ }
33
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"route.d.ts","sourceRoot":"","sources":["../../../../../../../../../../src/presentation/web/app/api/interactive/chat/[featureId]/stream/route.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAI/C,eAAO,MAAM,OAAO,kBAAkB,CAAC;AAEvC,UAAU,WAAW;IACnB,MAAM,EAAE,OAAO,CAAC;QAAE,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACxC;AAED,wBAAsB,GAAG,CAAC,OAAO,EAAE,WAAW,EAAE,EAAE,MAAM,EAAE,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC,CA4E1F"}
1
+ {"version":3,"file":"route.d.ts","sourceRoot":"","sources":["../../../../../../../../../../src/presentation/web/app/api/interactive/chat/[featureId]/stream/route.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAI/C,eAAO,MAAM,OAAO,kBAAkB,CAAC;AAEvC,UAAU,WAAW;IACnB,MAAM,EAAE,OAAO,CAAC;QAAE,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACxC;AAED,wBAAsB,GAAG,CAAC,OAAO,EAAE,WAAW,EAAE,EAAE,MAAM,EAAE,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC,CAoF1F"}
@@ -38,6 +38,13 @@ export async function GET(request, { params }) {
38
38
  if (chunk.done) {
39
39
  enqueue(`event: done\ndata: ${JSON.stringify({ done: true, featureId })}\n\n`);
40
40
  }
41
+ else if (chunk.interaction) {
42
+ // Agent is asking the user a question — emit interaction event
43
+ enqueue(`event: interaction\ndata: ${JSON.stringify({ interaction: chunk.interaction, featureId })}\n\n`);
44
+ if (chunk.log) {
45
+ enqueue(`event: log\ndata: ${JSON.stringify({ log: chunk.log, featureId })}\n\n`);
46
+ }
47
+ }
41
48
  else if (chunk.activity) {
42
49
  enqueue(`event: activity\ndata: ${JSON.stringify({ activity: chunk.activity, featureId })}\n\n`);
43
50
  // Also send log for the status indicator
@@ -1,6 +1,5 @@
1
1
  import type { Metadata } from 'next';
2
2
  import '@xyflow/react/dist/base.css';
3
- import '@cubone/react-file-manager/dist/style.css';
4
3
  import './globals.css';
5
4
  /** Force dynamic rendering for all pages since they depend on client-side context. */
6
5
  export declare const dynamic = "force-dynamic";
@@ -1 +1 @@
1
- {"version":3,"file":"layout.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/web/app/layout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAC;AAErC,OAAO,6BAA6B,CAAC;AACrC,OAAO,2CAA2C,CAAC;AACnD,OAAO,eAAe,CAAC;AAWvB,sFAAsF;AACtF,eAAO,MAAM,OAAO,kBAAkB,CAAC;AAEvC,eAAO,MAAM,QAAQ,EAAE,QAkBtB,CAAC;AAEF,wBAA8B,UAAU,CAAC,EACvC,QAAQ,GACT,EAAE,QAAQ,CAAC;IACV,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B,CAAC,oDA6BD"}
1
+ {"version":3,"file":"layout.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/web/app/layout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAC;AAErC,OAAO,6BAA6B,CAAC;AACrC,OAAO,eAAe,CAAC;AAWvB,sFAAsF;AACtF,eAAO,MAAM,OAAO,kBAAkB,CAAC;AAEvC,eAAO,MAAM,QAAQ,EAAE,QAkBtB,CAAC;AAEF,wBAA8B,UAAU,CAAC,EACvC,QAAQ,GACT,EAAE,QAAQ,CAAC;IACV,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B,CAAC,oDA6BD"}
@@ -1,7 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { cookies } from 'next/headers';
3
3
  import '@xyflow/react/dist/base.css';
4
- import '@cubone/react-file-manager/dist/style.css';
5
4
  import './globals.css';
6
5
  import { AppShell } from '../components/layouts/app-shell/index.js';
7
6
  import { Toaster } from '../components/ui/sonner.js';
@@ -1,6 +1,7 @@
1
- export declare function Thread({ className, statusBar, composer, }: {
1
+ export declare function Thread({ className, afterMessages, composer, }: {
2
2
  className?: string;
3
- statusBar?: React.ReactNode;
3
+ /** Content rendered inside the scrollable viewport, after messages (e.g. interaction bubbles). */
4
+ afterMessages?: React.ReactNode;
4
5
  composer?: React.ReactNode;
5
6
  }): import("react/jsx-runtime").JSX.Element;
6
7
  //# sourceMappingURL=thread.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"thread.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/web/components/assistant-ui/thread.tsx"],"names":[],"mappings":"AAuFA,wBAAgB,MAAM,CAAC,EACrB,SAAS,EACT,SAAS,EACT,QAAQ,GACT,EAAE;IACD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC5B,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B,2CAoBA"}
1
+ {"version":3,"file":"thread.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/web/components/assistant-ui/thread.tsx"],"names":[],"mappings":"AAwFA,wBAAgB,MAAM,CAAC,EACrB,SAAS,EACT,aAAa,EACb,QAAQ,GACT,EAAE;IACD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,kGAAkG;IAClG,aAAa,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAChC,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B,2CAqBA"}
@@ -6,7 +6,7 @@ import Markdown from 'react-markdown';
6
6
  import remarkGfm from 'remark-gfm';
7
7
  import { useTranslation } from 'react-i18next';
8
8
  import { cn } from '../../lib/utils.js';
9
- import { SendHorizontal, CircleStop, Copy, Paperclip, Bot, User, Maximize2, X, ChevronDown, ChevronUp, Loader2, } from 'lucide-react';
9
+ import { SendHorizontal, CircleStop, Copy, Paperclip, Bot, User, Maximize2, X, ChevronDown, ChevronUp, Loader2, Check, } from 'lucide-react';
10
10
  // ── Markdown components for assistant messages ──────────────────────────────
11
11
  const markdownComponents = {
12
12
  p: ({ children }) => _jsx("p", { className: "mb-2 leading-relaxed last:mb-0", children: children }),
@@ -40,20 +40,43 @@ const markdownComponents = {
40
40
  hr: () => _jsx("hr", { className: "border-border/40 my-3 border-t" }),
41
41
  };
42
42
  // ── Thread ──────────────────────────────────────────────────────────────────
43
- export function Thread({ className, statusBar, composer, }) {
43
+ export function Thread({ className, afterMessages, composer, }) {
44
44
  return (_jsxs(ThreadPrimitive.Root, { className: cn('flex h-full flex-col', className), children: [_jsxs(ThreadPrimitive.Viewport, { className: "flex flex-1 flex-col overflow-y-auto pt-4", children: [_jsx(ThreadPrimitive.Empty, { children: _jsx(ThreadEmpty, {}) }), _jsx(ThreadPrimitive.Messages, { components: {
45
45
  UserMessage,
46
46
  AssistantMessage,
47
- } })] }), statusBar, composer ?? _jsx(Composer, {})] }));
47
+ } }), afterMessages] }), composer ?? _jsx(Composer, {})] }));
48
48
  }
49
49
  // ── Empty state ─────────────────────────────────────────────────────────────
50
50
  function ThreadEmpty() {
51
51
  return (_jsxs("div", { className: "flex flex-1 flex-col items-center justify-center gap-2 p-8 text-center", children: [_jsx(Bot, { className: "text-muted-foreground/40 h-10 w-10" }), _jsx("p", { className: "text-muted-foreground text-sm", children: "Send a message to start chatting with the agent." })] }));
52
52
  }
53
53
  // ── User message ────────────────────────────────────────────────────────────
54
+ const INTERACTION_PREFIX = '{{interaction}}';
54
55
  const UserMessage = () => {
56
+ const message = useMessage();
57
+ // Check if this is an interaction response message
58
+ const firstPart = message?.content?.[0];
59
+ const text = firstPart && 'text' in firstPart ? firstPart.text : '';
60
+ if (text.startsWith(INTERACTION_PREFIX)) {
61
+ return _jsx(InteractionResponseMessage, { text: text });
62
+ }
55
63
  return (_jsxs(MessagePrimitive.Root, { className: "group flex w-full items-start gap-2.5 px-4 py-0.5", children: [_jsx("div", { className: "mt-0.5 flex h-6 w-6 shrink-0 items-center justify-center rounded-full bg-violet-500/15", children: _jsx(User, { className: "h-3.5 w-3.5 text-violet-500" }) }), _jsxs("div", { className: "flex max-w-[85%] min-w-0 flex-col gap-0.5", children: [_jsx("div", { className: "text-foreground mt-px overflow-hidden rounded-2xl rounded-tl-sm border border-violet-500/15 bg-violet-500/8 px-4 py-2 text-sm leading-relaxed break-words shadow-sm backdrop-blur-md", children: _jsx(MessagePrimitive.Content, { components: { Text: UserMessageText } }) }), _jsxs("div", { className: "flex items-center gap-1.5 opacity-0 transition-opacity group-hover:opacity-100", children: [_jsx(MessageMeta, {}), _jsx(ActionBarPrimitive.Root, { className: "flex items-center gap-1", children: _jsx(ActionBarPrimitive.Copy, { asChild: true, children: _jsx(IconButton, { tooltip: "Copy", children: _jsx(Copy, {}) }) }) })] })] })] }));
56
64
  };
65
+ /** Compact green bubble showing the user's selections from an AskUserQuestion interaction. */
66
+ function InteractionResponseMessage({ text }) {
67
+ const parsed = useMemo(() => {
68
+ try {
69
+ const json = text.slice(INTERACTION_PREFIX.length);
70
+ return JSON.parse(json);
71
+ }
72
+ catch {
73
+ return null;
74
+ }
75
+ }, [text]);
76
+ if (!parsed)
77
+ return null;
78
+ return (_jsxs(MessagePrimitive.Root, { className: "group flex w-full items-start gap-2.5 px-4 py-0.5", children: [_jsx("div", { className: "bg-muted flex h-6 w-6 shrink-0 items-center justify-center rounded-full", children: _jsx(Check, { className: "h-3.5 w-3.5 text-emerald-600 dark:text-emerald-400" }) }), _jsxs("div", { className: "flex min-w-0 flex-1 flex-col gap-0.5", children: [_jsx("div", { className: "text-foreground mt-px flex flex-wrap items-center gap-x-4 gap-y-1 rounded-2xl rounded-tl-sm border border-emerald-600/20 bg-emerald-50/50 px-4 py-2 text-sm shadow-sm dark:border-emerald-500/20 dark:bg-emerald-950/20", children: parsed.questions.map((q) => (_jsxs("span", { className: "flex items-center gap-2", children: [_jsx("span", { className: "inline-flex shrink-0 items-center rounded-full bg-emerald-100 px-2 py-0.5 text-[10px] font-semibold tracking-wider text-emerald-700 uppercase dark:bg-emerald-900/50 dark:text-emerald-400", children: q.header }), _jsx("span", { className: "text-muted-foreground text-xs", children: parsed.answers[q.question] || 'No answer' })] }, q.question))) }), _jsxs("div", { className: "flex items-center gap-1.5 opacity-0 transition-opacity group-hover:opacity-100", children: [_jsx(MessageMeta, {}), _jsx(ActionBarPrimitive.Root, { className: "flex items-center gap-1", children: _jsx(ActionBarPrimitive.Copy, { asChild: true, children: _jsx(IconButton, { tooltip: "Copy", children: _jsx(Copy, {}) }) }) })] })] })] }));
79
+ }
57
80
  function UserMessageText({ text }) {
58
81
  return _jsx("span", { className: "whitespace-pre-wrap", children: text });
59
82
  }
@@ -1 +1 @@
1
- {"version":3,"file":"react-file-manager-dialog.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/common/react-file-manager-dialog/react-file-manager-dialog.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAGV,2BAA2B,EAC5B,MAAM,oCAAoC,CAAC;AA2C5C,wBAAgB,sBAAsB,CAAC,EACrC,IAAI,EACJ,YAAY,EACZ,QAAQ,EACR,WAAW,GACZ,EAAE,2BAA2B,2CAgI7B"}
1
+ {"version":3,"file":"react-file-manager-dialog.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/common/react-file-manager-dialog/react-file-manager-dialog.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAGV,2BAA2B,EAC5B,MAAM,oCAAoC,CAAC;AAkK5C,wBAAgB,sBAAsB,CAAC,EACrC,IAAI,EACJ,YAAY,EACZ,QAAQ,EACR,WAAW,GACZ,EAAE,2BAA2B,2CAoJ7B"}
@@ -1,29 +1,11 @@
1
1
  'use client';
2
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import { useCallback, useEffect, useRef, useState } from 'react';
4
- import dynamic from 'next/dynamic';
5
- import { Loader2 } from 'lucide-react';
4
+ import { ChevronRight, Folder, FolderOpen, Loader2, Pencil } from 'lucide-react';
6
5
  import { toast } from 'sonner';
7
- import { Dialog, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, } from '../../ui/dialog.js';
6
+ import { Dialog, DialogContent, DialogDescription, DialogTitle } from '../../ui/dialog.js';
8
7
  import { Button } from '../../ui/button.js';
9
- const FileManager = dynamic(() => import('@cubone/react-file-manager').then((mod) => mod.FileManager), { ssr: false, loading: () => _jsx(FileManagerSkeleton, {}) });
10
- function FileManagerSkeleton() {
11
- return (_jsx("div", { className: "flex h-full w-full items-center justify-center", children: _jsx(Loader2, { className: "text-muted-foreground h-8 w-8 animate-spin" }) }));
12
- }
13
- function toFileManagerFiles(entries) {
14
- // The @cubone/react-file-manager component filters visible files by matching
15
- // file.path === currentPath + "/" + file.name. Since we dynamically fetch
16
- // directory contents on each navigation, we present all entries at the
17
- // FileManager's root level by using path = "/" + name. The real absolute
18
- // path is preserved in a custom `absolutePath` field for selection/navigation.
19
- return entries.map((entry) => ({
20
- name: entry.name,
21
- isDirectory: true,
22
- path: `/${entry.name}`,
23
- absolutePath: entry.path,
24
- updatedAt: entry.updatedAt,
25
- }));
26
- }
8
+ import { ScrollArea } from '../../ui/scroll-area.js';
27
9
  async function fetchDirectory(dirPath) {
28
10
  const params = new URLSearchParams();
29
11
  if (dirPath) {
@@ -36,19 +18,76 @@ async function fetchDirectory(dirPath) {
36
18
  }
37
19
  return res.json();
38
20
  }
21
+ function parseBreadcrumbs(currentPath) {
22
+ if (!currentPath)
23
+ return [];
24
+ const isWindows = /^[a-zA-Z]:/.test(currentPath);
25
+ const separator = isWindows ? '\\' : '/';
26
+ const parts = currentPath.split(/[\\/]/).filter(Boolean);
27
+ const crumbs = [];
28
+ for (let i = 0; i < parts.length; i++) {
29
+ const path = isWindows
30
+ ? parts.slice(0, i + 1).join(separator)
31
+ : separator + parts.slice(0, i + 1).join(separator);
32
+ crumbs.push({ label: parts[i], path });
33
+ }
34
+ return crumbs;
35
+ }
36
+ const MAX_VISIBLE_CRUMBS = 3;
37
+ function AddressBar({ currentPath, isEditing, onToggleEdit, onNavigate, }) {
38
+ const inputRef = useRef(null);
39
+ const [inputValue, setInputValue] = useState(currentPath);
40
+ useEffect(() => {
41
+ setInputValue(currentPath);
42
+ }, [currentPath]);
43
+ useEffect(() => {
44
+ if (isEditing && inputRef.current) {
45
+ inputRef.current.focus();
46
+ inputRef.current.select();
47
+ }
48
+ }, [isEditing]);
49
+ function handleSubmit() {
50
+ const trimmed = inputValue.trim();
51
+ if (trimmed) {
52
+ onNavigate(trimmed);
53
+ }
54
+ }
55
+ function closeEdit() {
56
+ setInputValue(currentPath);
57
+ onToggleEdit();
58
+ }
59
+ const breadcrumbs = parseBreadcrumbs(currentPath);
60
+ const needsCollapse = breadcrumbs.length > MAX_VISIBLE_CRUMBS;
61
+ const visibleCrumbs = needsCollapse ? breadcrumbs.slice(-MAX_VISIBLE_CRUMBS) : breadcrumbs;
62
+ return (_jsxs("div", { className: "border-b px-4 py-3", children: [_jsx("h2", { className: "text-foreground mb-2.5 text-sm font-semibold tracking-[-0.01em]", children: "Select Folder" }), isEditing ? (_jsx("input", { ref: inputRef, type: "text", value: inputValue, onChange: (e) => setInputValue(e.target.value), onKeyDown: (e) => {
63
+ if (e.key === 'Enter') {
64
+ e.preventDefault();
65
+ handleSubmit();
66
+ }
67
+ if (e.key === 'Escape') {
68
+ e.preventDefault();
69
+ closeEdit();
70
+ }
71
+ }, onBlur: closeEdit, className: "bg-muted/60 border-border focus:ring-ring/20 focus:border-ring w-full rounded-lg border px-3 py-2 font-mono text-xs transition-all outline-none focus:ring-2", placeholder: "Type a path and press Enter...", spellCheck: false, autoComplete: "off" })) : (_jsxs("div", { className: "bg-muted/40 flex items-center gap-1 rounded-lg px-2.5 py-2", children: [_jsx("button", { type: "button", onClick: () => onNavigate('/'), className: "text-muted-foreground hover:text-foreground hover:bg-background shrink-0 rounded px-1.5 py-0.5 font-mono text-xs transition-colors", children: "/" }), needsCollapse ? (_jsxs(_Fragment, { children: [_jsx(ChevronRight, { className: "text-muted-foreground/30 h-3 w-3 shrink-0" }), _jsx("span", { className: "text-muted-foreground/40 font-mono text-xs", children: "..." })] })) : null, visibleCrumbs.map((crumb, i) => {
72
+ const isLast = i === visibleCrumbs.length - 1;
73
+ return (_jsxs("span", { className: "flex shrink-0 items-center gap-1", children: [_jsx(ChevronRight, { className: "text-muted-foreground/30 h-3 w-3" }), isLast ? (_jsx("span", { className: "bg-primary/10 text-primary rounded px-2 py-0.5 font-mono text-xs font-medium", children: crumb.label })) : (_jsx("button", { type: "button", onClick: () => onNavigate(crumb.path), className: "text-muted-foreground hover:text-foreground hover:bg-background rounded px-1.5 py-0.5 font-mono text-xs transition-colors", children: crumb.label }))] }, crumb.path));
74
+ }), _jsx("div", { className: "flex-1" }), _jsx("button", { type: "button", onClick: onToggleEdit, className: "text-muted-foreground/40 hover:text-foreground hover:bg-background shrink-0 rounded p-1 transition-colors", "aria-label": "Edit path", children: _jsx(Pencil, { className: "h-3 w-3" }) })] }))] }));
75
+ }
39
76
  export function ReactFileManagerDialog({ open, onOpenChange, onSelect, initialPath, }) {
40
77
  const [entries, setEntries] = useState([]);
41
78
  const [currentPath, setCurrentPath] = useState('');
42
79
  const [isLoading, setIsLoading] = useState(false);
43
- const [selectedPath, setSelectedPath] = useState(null);
80
+ const [isEditingPath, setIsEditingPath] = useState(false);
44
81
  const hasLoadedRef = useRef(false);
82
+ const [renderKey, setRenderKey] = useState(0);
45
83
  const loadDirectory = useCallback(async (dirPath) => {
46
84
  setIsLoading(true);
47
- setSelectedPath(null);
85
+ setIsEditingPath(false);
48
86
  try {
49
87
  const data = await fetchDirectory(dirPath);
50
88
  setEntries(data.entries);
51
89
  setCurrentPath(data.currentPath);
90
+ setRenderKey((k) => k + 1);
52
91
  }
53
92
  catch (error) {
54
93
  const message = error instanceof Error ? error.message : 'Failed to load directory';
@@ -65,32 +104,13 @@ export function ReactFileManagerDialog({ open, onOpenChange, onSelect, initialPa
65
104
  }
66
105
  if (!open) {
67
106
  hasLoadedRef.current = false;
107
+ setIsEditingPath(false);
68
108
  }
69
109
  }, [open, initialPath, loadDirectory]);
70
- const handleFileOpen = useCallback((file) => {
71
- // Use absolutePath (real filesystem path) for navigation, not the
72
- // virtual path used by the FileManager tree.
73
- const realPath = file.absolutePath;
74
- if (file.isDirectory && realPath) {
75
- loadDirectory(realPath);
76
- }
77
- }, [loadDirectory]);
78
- const handleSelectionChange = useCallback((files) => {
79
- if (files.length === 1 && files[0].isDirectory) {
80
- const realPath = files[0].absolutePath;
81
- setSelectedPath(realPath ?? null);
82
- }
83
- else {
84
- setSelectedPath(null);
85
- }
86
- }, []);
87
- function handleSelect() {
88
- if (selectedPath) {
89
- onSelect(selectedPath);
90
- onOpenChange(false);
91
- }
110
+ function handleNavigate(path) {
111
+ loadDirectory(path);
92
112
  }
93
- function handleSelectCurrentPath() {
113
+ function handleSelect() {
94
114
  if (currentPath) {
95
115
  onSelect(currentPath);
96
116
  onOpenChange(false);
@@ -104,13 +124,5 @@ export function ReactFileManagerDialog({ open, onOpenChange, onSelect, initialPa
104
124
  if (!isOpen) {
105
125
  handleCancel();
106
126
  }
107
- }, children: _jsxs(DialogContent, { className: "flex h-[95dvh] max-w-[95vw] flex-col", onCloseAutoFocus: (e) => e.preventDefault(), children: [_jsxs(DialogHeader, { children: [_jsx(DialogTitle, { children: "Select Folder" }), _jsx(DialogDescription, { className: "truncate font-mono text-xs", children: currentPath || 'Loading...' })] }), _jsx("div", { className: "shep-file-manager min-h-0 flex-1 overflow-hidden rounded-md border", children: _jsx(FileManager, { files: toFileManagerFiles(entries), isLoading: isLoading, height: "100%", width: "100%", layout: "list", enableFilePreview: false, permissions: {
108
- upload: false,
109
- delete: false,
110
- create: false,
111
- download: false,
112
- copy: false,
113
- move: false,
114
- rename: false,
115
- }, onFileOpen: handleFileOpen, onSelectionChange: handleSelectionChange, onRefresh: () => loadDirectory(currentPath) }, currentPath) }), _jsxs(DialogFooter, { children: [_jsx(Button, { variant: "outline", onClick: handleCancel, children: "Cancel" }), _jsx(Button, { variant: "secondary", onClick: handleSelectCurrentPath, disabled: !currentPath, children: "Select Current Folder" }), _jsx(Button, { onClick: handleSelect, disabled: !selectedPath, children: "Select Folder" })] })] }) }));
127
+ }, children: _jsxs(DialogContent, { className: "flex h-[min(520px,85dvh)] w-full max-w-[460px] flex-col gap-0 overflow-hidden p-0", onCloseAutoFocus: (e) => e.preventDefault(), children: [_jsx(DialogTitle, { className: "sr-only", children: "Select Folder" }), _jsx(DialogDescription, { className: "sr-only", children: "Navigate to a folder and select it" }), _jsx(AddressBar, { currentPath: currentPath, isEditing: isEditingPath, onToggleEdit: () => setIsEditingPath((v) => !v), onNavigate: handleNavigate }), _jsx(ScrollArea, { className: "min-h-0 flex-1", children: isLoading && entries.length === 0 ? (_jsx("div", { className: "space-y-0.5 p-2", children: Array.from({ length: 8 }).map((_, i) => (_jsxs("div", { className: "flex items-center gap-3 rounded-lg px-3 py-2.5", style: { opacity: 1 - i * 0.1 }, children: [_jsx("div", { className: "bg-muted h-4 w-4 animate-pulse rounded" }), _jsx("div", { className: "bg-muted h-3.5 animate-pulse rounded", style: { width: `${40 + Math.random() * 35}%` } })] }, `skeleton-${i}`))) })) : entries.length === 0 ? (_jsxs("div", { className: "flex flex-col items-center justify-center py-20", children: [_jsx(FolderOpen, { className: "text-muted-foreground/25 mb-3 h-10 w-10" }), _jsx("p", { className: "text-muted-foreground/60 text-sm", children: "Empty folder" })] })) : (_jsx("div", { className: "p-2", children: entries.map((entry, i) => (_jsxs("button", { type: "button", onClick: () => handleNavigate(entry.path), className: "folder-row group flex w-full items-center gap-3 rounded-lg px-3 py-2.5 text-left transition-all hover:bg-[var(--color-primary)]/[0.06] active:scale-[0.997]", style: { animationDelay: `${i * 20}ms` }, children: [_jsx(Folder, { className: "text-muted-foreground/50 group-hover:text-primary h-[18px] w-[18px] shrink-0 transition-colors" }), _jsx("span", { className: "text-foreground min-w-0 flex-1 truncate text-[13px] font-medium", children: entry.name }), _jsx(ChevronRight, { className: "text-muted-foreground/0 group-hover:text-muted-foreground/40 h-3.5 w-3.5 shrink-0 transition-all" })] }, entry.path))) }, renderKey)) }), _jsxs("div", { className: "flex items-center gap-2 border-t px-4 py-3", children: [_jsx("p", { className: "text-muted-foreground min-w-0 flex-1 truncate font-mono text-[11px] leading-none", children: currentPath || '\u00A0' }), _jsx(Button, { variant: "ghost", size: "sm", onClick: handleCancel, className: "text-muted-foreground h-8 shrink-0 px-3 text-xs", children: "Cancel" }), _jsxs(Button, { size: "sm", onClick: handleSelect, disabled: !currentPath || isLoading, className: "h-8 shrink-0 px-5 text-xs font-medium", children: [isLoading ? _jsx(Loader2, { className: "mr-1.5 h-3 w-3 animate-spin" }) : null, "Select"] })] })] }) }));
116
128
  }
@@ -8,6 +8,7 @@ interface ChatDotIndicatorProps {
8
8
  * - idle: no dot (hidden)
9
9
  * - processing: pulsing blue dot
10
10
  * - unread: static green dot
11
+ * - awaiting_input: pulsing amber dot (agent needs user response)
11
12
  */
12
13
  export declare function ChatDotIndicator({ status, className }: ChatDotIndicatorProps): import("react/jsx-runtime").JSX.Element | null;
13
14
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"ChatDotIndicator.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatDotIndicator.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAE5D,UAAU,qBAAqB;IAC7B,MAAM,EAAE,UAAU,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,EAAE,MAAM,EAAE,SAAc,EAAE,EAAE,qBAAqB,kDAUjF"}
1
+ {"version":3,"file":"ChatDotIndicator.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatDotIndicator.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAE5D,UAAU,qBAAqB;IAC7B,MAAM,EAAE,UAAU,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,EAAE,MAAM,EAAE,SAAc,EAAE,EAAE,qBAAqB,kDAajF"}
@@ -5,9 +5,15 @@ import { jsx as _jsx } from "react/jsx-runtime";
5
5
  * - idle: no dot (hidden)
6
6
  * - processing: pulsing blue dot
7
7
  * - unread: static green dot
8
+ * - awaiting_input: pulsing amber dot (agent needs user response)
8
9
  */
9
10
  export function ChatDotIndicator({ status, className = '' }) {
10
11
  if (status === 'idle')
11
12
  return null;
12
- return (_jsx("span", { className: `absolute -top-0.5 -right-0.5 block rounded-full ${status === 'processing' ? 'h-2.5 w-2.5 animate-pulse bg-blue-500' : 'h-2 w-2 bg-green-500'} ${className}` }));
13
+ const dotClass = status === 'awaiting_input'
14
+ ? 'h-2.5 w-2.5 animate-pulse bg-amber-500'
15
+ : status === 'processing'
16
+ ? 'h-2.5 w-2.5 animate-pulse bg-blue-500'
17
+ : 'h-2 w-2 bg-green-500';
18
+ return (_jsx("span", { className: `absolute -top-0.5 -right-0.5 block rounded-full ${dotClass} ${className}` }));
13
19
  }
@@ -6,4 +6,5 @@ type Story = StoryObj<typeof ChatDotIndicator>;
6
6
  export declare const Idle: Story;
7
7
  export declare const Processing: Story;
8
8
  export declare const Unread: Story;
9
+ export declare const AwaitingInput: Story;
9
10
  //# sourceMappingURL=ChatDotIndicator.stories.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ChatDotIndicator.stories.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatDotIndicator.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAEtD,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,gBAAgB,CAWvC,CAAC;AAEF,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE/C,eAAO,MAAM,IAAI,EAAE,KAElB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,KAExB,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAEpB,CAAC"}
1
+ {"version":3,"file":"ChatDotIndicator.stories.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatDotIndicator.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAEtD,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,gBAAgB,CAWvC,CAAC;AAEF,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE/C,eAAO,MAAM,IAAI,EAAE,KAElB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,KAExB,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAEpB,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,KAE3B,CAAC"}
@@ -17,3 +17,6 @@ export const Processing = {
17
17
  export const Unread = {
18
18
  args: { status: 'unread' },
19
19
  };
20
+ export const AwaitingInput = {
21
+ args: { status: 'awaiting_input' },
22
+ };
@@ -1 +1 @@
1
- {"version":3,"file":"ChatSheet.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatSheet.tsx"],"names":[],"mappings":"AA2DA,wBAAgB,eAAe,4CAwY9B"}
1
+ {"version":3,"file":"ChatSheet.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatSheet.tsx"],"names":[],"mappings":"AA2DA,wBAAgB,eAAe,4CA4Y9B"}
@@ -261,7 +261,9 @@ export function GlobalChatPopup() {
261
261
  document.addEventListener('mouseup', onUp);
262
262
  }, className: "absolute end-0 bottom-0 z-10 h-4 w-4 cursor-se-resize" })) : null] })) : null, _jsxs(ChatFabWrapper, { swapPosition: swapPosition, sidebarState: sidebarState, isMaximized: isMaximized, children: [_jsxs(Button, { size: "icon", onClick: toggle, className: cn('relative h-14 w-14 rounded-full shadow-lg', 'transition-all duration-200 hover:scale-105 hover:shadow-xl active:scale-95', isOpen
263
263
  ? 'bg-violet-600 text-white hover:bg-violet-500'
264
- : 'bg-violet-500 text-white hover:bg-violet-400 dark:bg-violet-500 dark:hover:bg-violet-400'), children: [_jsx(MessageSquare, { className: cn('absolute h-7 w-7 stroke-[2.5] transition-all duration-200', isOpen ? 'scale-0 rotate-90 opacity-0' : 'scale-100 rotate-0 opacity-100') }), _jsx(X, { className: cn('absolute h-6 w-6 stroke-[2.5] transition-all duration-200', isOpen ? 'scale-100 rotate-0 opacity-100' : 'scale-0 -rotate-90 opacity-0') }), !isOpen && _jsx(ChatDotIndicator, { status: globalChatTurnStatus, className: "end-0 top-0" })] }), _jsx("div", { className: "pointer-events-none absolute bottom-[calc(100%+8px)] left-1/2 -translate-x-1/2 translate-y-1 opacity-0 transition-all duration-200 group-hover/fab:translate-y-0 group-hover/fab:opacity-100", children: _jsxs("div", { className: "bg-foreground rounded-lg px-3 py-1.5 text-center shadow-lg", children: [_jsx("p", { className: "text-background text-xs font-medium whitespace-nowrap", children: t('chat.shepChat') }), _jsxs("p", { className: "text-background/50 mt-0.5 flex items-center justify-center gap-1 text-[10px]", children: [_jsx("kbd", { className: "bg-background/15 rounded px-1 py-px font-mono", children: "\u2318" }), _jsx("kbd", { className: "bg-background/15 rounded px-1 py-px font-mono", children: "\u21E7" }), _jsx("kbd", { className: "bg-background/15 rounded px-1 py-px font-mono", children: "K" })] })] }) })] })] }));
264
+ : 'bg-violet-500 text-white hover:bg-violet-400 dark:bg-violet-500 dark:hover:bg-violet-400',
265
+ // Animated states when chat is closed
266
+ !isOpen && globalChatTurnStatus === 'processing' && 'chat-fab-spinning', !isOpen && globalChatTurnStatus === 'unread' && 'chat-fab-glow-unread', !isOpen && globalChatTurnStatus === 'awaiting_input' && 'chat-fab-glow-awaiting'), children: [_jsx(MessageSquare, { className: cn('absolute h-7 w-7 stroke-[2.5] transition-all duration-200', isOpen ? 'scale-0 rotate-90 opacity-0' : 'scale-100 rotate-0 opacity-100') }), _jsx(X, { className: cn('absolute h-6 w-6 stroke-[2.5] transition-all duration-200', isOpen ? 'scale-100 rotate-0 opacity-100' : 'scale-0 -rotate-90 opacity-0') }), !isOpen && _jsx(ChatDotIndicator, { status: globalChatTurnStatus, className: "end-0 top-0" })] }), _jsx("div", { className: "pointer-events-none absolute bottom-[calc(100%+8px)] left-1/2 -translate-x-1/2 translate-y-1 opacity-0 transition-all duration-200 group-hover/fab:translate-y-0 group-hover/fab:opacity-100", children: _jsxs("div", { className: "bg-foreground rounded-lg px-3 py-1.5 text-center shadow-lg", children: [_jsx("p", { className: "text-background text-xs font-medium whitespace-nowrap", children: t('chat.shepChat') }), _jsxs("p", { className: "text-background/50 mt-0.5 flex items-center justify-center gap-1 text-[10px]", children: [_jsx("kbd", { className: "bg-background/15 rounded px-1 py-px font-mono", children: "\u2318" }), _jsx("kbd", { className: "bg-background/15 rounded px-1 py-px font-mono", children: "\u21E7" }), _jsx("kbd", { className: "bg-background/15 rounded px-1 py-px font-mono", children: "K" })] })] }) })] })] }));
265
267
  }
266
268
  /** Wrapper for the Chat FAB that handles position swapping. */
267
269
  function ChatFabWrapper({ swapPosition, sidebarState, isMaximized, children, }) {
@@ -1 +1 @@
1
- {"version":3,"file":"ChatTab.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatTab.tsx"],"names":[],"mappings":"AAcA,MAAM,WAAW,YAAY;IAC3B,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAID,wBAAgB,OAAO,CAAC,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,YAAY,2CAwGhE"}
1
+ {"version":3,"file":"ChatTab.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/ChatTab.tsx"],"names":[],"mappings":"AAeA,MAAM,WAAW,YAAY;IAC3B,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAID,wBAAgB,OAAO,CAAC,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,YAAY,2CAsHhE"}
@@ -11,6 +11,7 @@ import { composeUserInput } from '../../../app/actions/compose-user-input.js';
11
11
  import { AgentModelPicker } from '../../features/settings/AgentModelPicker/index.js';
12
12
  import { useChatRuntime } from './useChatRuntime.js';
13
13
  import { ChatComposer } from './ChatComposer.js';
14
+ import { InteractionBubble } from './InteractionBubble.js';
14
15
  const IS_DEV = process.env.NODE_ENV === 'development';
15
16
  export function ChatTab({ featureId, worktreePath }) {
16
17
  const [overrideAgent, setOverrideAgent] = useState(undefined);
@@ -18,7 +19,7 @@ export function ChatTab({ featureId, worktreePath }) {
18
19
  const [debugMode, setDebugMode] = useState(false);
19
20
  const att = useAttachments();
20
21
  const contentTransform = useCallback((content) => composeUserInput(content, att.completedAttachments.map((a) => ({ path: a.path, name: a.name, notes: a.notes }))), [att.completedAttachments]);
21
- const { runtime, status, clearChat, sessionInfo, isChatLoading } = useChatRuntime(featureId, worktreePath, {
22
+ const { runtime, status, clearChat, sessionInfo, isChatLoading, pendingInteraction, respondToInteraction, } = useChatRuntime(featureId, worktreePath, {
22
23
  contentTransform,
23
24
  onMessageSent: att.clearAttachments,
24
25
  model: overrideModel,
@@ -54,7 +55,7 @@ export function ChatTab({ featureId, worktreePath }) {
54
55
  setOverrideAgent(agent);
55
56
  setOverrideModel(model);
56
57
  }, className: "w-55" }) }));
57
- return (_jsxs("div", { className: "flex h-full min-h-0 flex-col", children: [_jsx(ChatHeader, { sessionInfo: sessionInfo, isAgentActive: status.isRunning, onClear: clearChat, debugMode: debugMode, onDebugToggle: IS_DEV ? setDebugMode : undefined }), _jsx("div", { className: "flex min-h-0 flex-1 flex-col", children: isChatLoading ? (_jsx(ChatSkeleton, {})) : (_jsx(AssistantRuntimeProvider, { runtime: runtime, children: _jsx(Thread, { composer: composer }) })) })] }));
58
+ return (_jsxs("div", { className: "flex h-full min-h-0 flex-col", children: [_jsx(ChatHeader, { sessionInfo: sessionInfo, isAgentActive: status.isRunning, onClear: clearChat, debugMode: debugMode, onDebugToggle: IS_DEV ? setDebugMode : undefined }), _jsx("div", { className: "flex min-h-0 flex-1 flex-col", children: isChatLoading ? (_jsx(ChatSkeleton, {})) : (_jsx(AssistantRuntimeProvider, { runtime: runtime, children: _jsx(Thread, { composer: composer, afterMessages: pendingInteraction ? (_jsx(InteractionBubble, { interaction: pendingInteraction, onSubmit: respondToInteraction })) : undefined }) })) })] }));
58
59
  }
59
60
  // ── Loading skeleton ────────────────────────────────────────────────────────
60
61
  function ChatSkeleton() {
@@ -0,0 +1,33 @@
1
+ /** Shape matching UserQuestion from the agent executor interface. */
2
+ interface QuestionOption {
3
+ label: string;
4
+ description: string;
5
+ preview?: string;
6
+ }
7
+ interface Question {
8
+ question: string;
9
+ header: string;
10
+ options: QuestionOption[];
11
+ multiSelect: boolean;
12
+ }
13
+ export interface InteractionData {
14
+ toolCallId: string;
15
+ questions: Question[];
16
+ }
17
+ export interface InteractionBubbleProps {
18
+ interaction: InteractionData;
19
+ onSubmit: (answers: Record<string, string>) => void;
20
+ className?: string;
21
+ }
22
+ /**
23
+ * Renders an agent's AskUserQuestion interaction inline in the chat thread.
24
+ *
25
+ * - Single question: renders options directly
26
+ * - Multiple questions: tabbed interface with header chips as tabs
27
+ *
28
+ * After submission, the bubble disappears and a green summary message
29
+ * is persisted in the conversation history (rendered by InteractionResponseMessage in thread.tsx).
30
+ */
31
+ export declare function InteractionBubble({ interaction, onSubmit, className }: InteractionBubbleProps): import("react/jsx-runtime").JSX.Element;
32
+ export {};
33
+ //# sourceMappingURL=InteractionBubble.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InteractionBubble.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/web/components/features/chat/InteractionBubble.tsx"],"names":[],"mappings":"AAMA,qEAAqE;AACrE,UAAU,cAAc;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,UAAU,QAAQ;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,cAAc,EAAE,CAAC;IAC1B,WAAW,EAAE,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,eAAe;IAC9B,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,QAAQ,EAAE,CAAC;CACvB;AAED,MAAM,WAAW,sBAAsB;IACrC,WAAW,EAAE,eAAe,CAAC;IAC7B,QAAQ,EAAE,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAAK,IAAI,CAAC;IACpD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAC,EAAE,WAAW,EAAE,QAAQ,EAAE,SAAS,EAAE,EAAE,sBAAsB,2CAsB7F"}