@mndrk/agx 2.0.47 → 2.0.48

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 (342) hide show
  1. package/cloud-runtime/standalone/.next/BUILD_ID +1 -1
  2. package/cloud-runtime/standalone/.next/build-manifest.json +2 -2
  3. package/cloud-runtime/standalone/.next/prerender-manifest.json +3 -3
  4. package/cloud-runtime/standalone/.next/server/app/_global-error.html +2 -2
  5. package/cloud-runtime/standalone/.next/server/app/_global-error.rsc +1 -1
  6. package/cloud-runtime/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  7. package/cloud-runtime/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  8. package/cloud-runtime/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  9. package/cloud-runtime/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  10. package/cloud-runtime/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  11. package/cloud-runtime/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  12. package/cloud-runtime/standalone/.next/server/app/_not-found.html +2 -2
  13. package/cloud-runtime/standalone/.next/server/app/_not-found.rsc +2 -2
  14. package/cloud-runtime/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +2 -2
  15. package/cloud-runtime/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  16. package/cloud-runtime/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +2 -2
  17. package/cloud-runtime/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  18. package/cloud-runtime/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  19. package/cloud-runtime/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  20. package/cloud-runtime/standalone/.next/server/app/agents/[id]/page.js.nft.json +1 -1
  21. package/cloud-runtime/standalone/.next/server/app/agents/[id]/page_client-reference-manifest.js +1 -1
  22. package/cloud-runtime/standalone/.next/server/app/agents/page.js.nft.json +1 -1
  23. package/cloud-runtime/standalone/.next/server/app/agents/page_client-reference-manifest.js +1 -1
  24. package/cloud-runtime/standalone/.next/server/app/agents.html +2 -2
  25. package/cloud-runtime/standalone/.next/server/app/agents.rsc +3 -3
  26. package/cloud-runtime/standalone/.next/server/app/agents.segments/_full.segment.rsc +3 -3
  27. package/cloud-runtime/standalone/.next/server/app/agents.segments/_head.segment.rsc +1 -1
  28. package/cloud-runtime/standalone/.next/server/app/agents.segments/_index.segment.rsc +2 -2
  29. package/cloud-runtime/standalone/.next/server/app/agents.segments/_tree.segment.rsc +2 -2
  30. package/cloud-runtime/standalone/.next/server/app/agents.segments/agents/__PAGE__.segment.rsc +2 -2
  31. package/cloud-runtime/standalone/.next/server/app/agents.segments/agents.segment.rsc +1 -1
  32. package/cloud-runtime/standalone/.next/server/app/api/agent-specs/route.js.nft.json +1 -1
  33. package/cloud-runtime/standalone/.next/server/app/api/agents/[id]/profile/route.js.nft.json +1 -1
  34. package/cloud-runtime/standalone/.next/server/app/api/agents/export/route.js.nft.json +1 -1
  35. package/cloud-runtime/standalone/.next/server/app/api/automations/create/route.js.nft.json +1 -1
  36. package/cloud-runtime/standalone/.next/server/app/api/automations/route.js.nft.json +1 -1
  37. package/cloud-runtime/standalone/.next/server/app/api/chat/route.js.nft.json +1 -1
  38. package/cloud-runtime/standalone/.next/server/app/api/file-search/route.js.nft.json +1 -1
  39. package/cloud-runtime/standalone/.next/server/app/api/graphs/[graphId]/nodes/[nodeId]/route.js.nft.json +1 -1
  40. package/cloud-runtime/standalone/.next/server/app/api/health/route.js.nft.json +1 -1
  41. package/cloud-runtime/standalone/.next/server/app/api/knowledge-notes/route.js.nft.json +1 -1
  42. package/cloud-runtime/standalone/.next/server/app/api/learnings/route.js.nft.json +1 -1
  43. package/cloud-runtime/standalone/.next/server/app/api/linear/callback/route.js +1 -1
  44. package/cloud-runtime/standalone/.next/server/app/api/linear/callback/route.js.nft.json +1 -1
  45. package/cloud-runtime/standalone/.next/server/app/api/linear/cycles/route.js +1 -1
  46. package/cloud-runtime/standalone/.next/server/app/api/linear/cycles/route.js.nft.json +1 -1
  47. package/cloud-runtime/standalone/.next/server/app/api/linear/issues/context/route.js.nft.json +1 -1
  48. package/cloud-runtime/standalone/.next/server/app/api/linear/issues/route.js.nft.json +1 -1
  49. package/cloud-runtime/standalone/.next/server/app/api/linear/options/route.js +2 -2
  50. package/cloud-runtime/standalone/.next/server/app/api/linear/options/route.js.nft.json +1 -1
  51. package/cloud-runtime/standalone/.next/server/app/api/linear/status/route.js +1 -1
  52. package/cloud-runtime/standalone/.next/server/app/api/linear/status/route.js.nft.json +1 -1
  53. package/cloud-runtime/standalone/.next/server/app/api/linear/token/route.js +1 -1
  54. package/cloud-runtime/standalone/.next/server/app/api/linear/token/route.js.nft.json +1 -1
  55. package/cloud-runtime/standalone/.next/server/app/api/orchestrator/tasks/[taskId]/start/route.js.nft.json +1 -1
  56. package/cloud-runtime/standalone/.next/server/app/api/orchestrator/tasks/[taskId]/status/route.js.nft.json +1 -1
  57. package/cloud-runtime/standalone/.next/server/app/api/participants/route.js.nft.json +1 -1
  58. package/cloud-runtime/standalone/.next/server/app/api/projects/[id]/agents/route.js.nft.json +1 -1
  59. package/cloud-runtime/standalone/.next/server/app/api/projects/[id]/migrate-v1/route.js.nft.json +1 -1
  60. package/cloud-runtime/standalone/.next/server/app/api/projects/[id]/migrate-v2/route.js.nft.json +1 -1
  61. package/cloud-runtime/standalone/.next/server/app/api/projects/[id]/route.js.nft.json +1 -1
  62. package/cloud-runtime/standalone/.next/server/app/api/projects/[id]/skills/route.js.nft.json +1 -1
  63. package/cloud-runtime/standalone/.next/server/app/api/projects/[id]/threads/route.js.nft.json +1 -1
  64. package/cloud-runtime/standalone/.next/server/app/api/projects/[id]/variables/route.js.nft.json +1 -1
  65. package/cloud-runtime/standalone/.next/server/app/api/projects/route.js.nft.json +1 -1
  66. package/cloud-runtime/standalone/.next/server/app/api/prompt-jobs/[id]/cancel/route.js.nft.json +1 -1
  67. package/cloud-runtime/standalone/.next/server/app/api/prompt-jobs/[id]/route.js.nft.json +1 -1
  68. package/cloud-runtime/standalone/.next/server/app/api/prompt-jobs/[id]/runs/route.js.nft.json +1 -1
  69. package/cloud-runtime/standalone/.next/server/app/api/prompt-jobs/agents/route.js.nft.json +1 -1
  70. package/cloud-runtime/standalone/.next/server/app/api/prompt-jobs/poll/route.js.nft.json +1 -1
  71. package/cloud-runtime/standalone/.next/server/app/api/prompt-jobs/route.js.nft.json +1 -1
  72. package/cloud-runtime/standalone/.next/server/app/api/providers/route.js.nft.json +1 -1
  73. package/cloud-runtime/standalone/.next/server/app/api/queue/complete/route.js.nft.json +1 -1
  74. package/cloud-runtime/standalone/.next/server/app/api/queue/route.js.nft.json +1 -1
  75. package/cloud-runtime/standalone/.next/server/app/api/schedules/debug/route.js.nft.json +1 -1
  76. package/cloud-runtime/standalone/.next/server/app/api/schedules/poll/route.js.nft.json +1 -1
  77. package/cloud-runtime/standalone/.next/server/app/api/schedules/route.js.nft.json +1 -1
  78. package/cloud-runtime/standalone/.next/server/app/api/status/route.js.nft.json +1 -1
  79. package/cloud-runtime/standalone/.next/server/app/api/summarize/route.js.nft.json +1 -1
  80. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/comments/[commentId]/route.js.nft.json +1 -1
  81. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/comments/route.js.nft.json +1 -1
  82. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/costs/route.js.nft.json +1 -1
  83. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/dependencies/route.js.nft.json +1 -1
  84. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/events/route.js.nft.json +1 -1
  85. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/history/route.js.nft.json +1 -1
  86. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/metrics/route.js.nft.json +1 -1
  87. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/replan/route.js.nft.json +1 -1
  88. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/restart/route.js.nft.json +1 -1
  89. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/resume/route.js.nft.json +1 -1
  90. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/rollback/route.js.nft.json +1 -1
  91. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/route.js.nft.json +1 -1
  92. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/schedule/route.js.nft.json +1 -1
  93. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/start/route.js.nft.json +1 -1
  94. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/graph/stop/route.js.nft.json +1 -1
  95. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/history/route.js.nft.json +1 -1
  96. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/logs/route.js.nft.json +1 -1
  97. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/nodes/[nodeId]/comments/route.js.nft.json +1 -1
  98. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/nodes/[nodeId]/complete/route.js.nft.json +1 -1
  99. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/nodes/[nodeId]/fail/route.js.nft.json +1 -1
  100. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/nodes/[nodeId]/resume/route.js.nft.json +1 -1
  101. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/nodes/[nodeId]/start/route.js.nft.json +1 -1
  102. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/nodes/[nodeId]/stop/route.js.nft.json +1 -1
  103. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/nodes/[nodeId]/verify/route.js.nft.json +1 -1
  104. package/cloud-runtime/standalone/.next/server/app/api/tasks/[id]/route.js.nft.json +1 -1
  105. package/cloud-runtime/standalone/.next/server/app/api/tasks/assign-orphans/route.js.nft.json +1 -1
  106. package/cloud-runtime/standalone/.next/server/app/api/tasks/extract/route.js.nft.json +1 -1
  107. package/cloud-runtime/standalone/.next/server/app/api/tasks/route.js.nft.json +1 -1
  108. package/cloud-runtime/standalone/.next/server/app/api/threads/knowledge/route.js.nft.json +1 -1
  109. package/cloud-runtime/standalone/.next/server/app/api/threads/route.js.nft.json +1 -1
  110. package/cloud-runtime/standalone/.next/server/app/api/user-settings/route.js.nft.json +1 -1
  111. package/cloud-runtime/standalone/.next/server/app/automations/page/react-loadable-manifest.json +1 -1
  112. package/cloud-runtime/standalone/.next/server/app/automations/page.js.nft.json +1 -1
  113. package/cloud-runtime/standalone/.next/server/app/automations/page_client-reference-manifest.js +1 -1
  114. package/cloud-runtime/standalone/.next/server/app/automations.html +2 -2
  115. package/cloud-runtime/standalone/.next/server/app/automations.rsc +3 -3
  116. package/cloud-runtime/standalone/.next/server/app/automations.segments/_full.segment.rsc +3 -3
  117. package/cloud-runtime/standalone/.next/server/app/automations.segments/_head.segment.rsc +1 -1
  118. package/cloud-runtime/standalone/.next/server/app/automations.segments/_index.segment.rsc +2 -2
  119. package/cloud-runtime/standalone/.next/server/app/automations.segments/_tree.segment.rsc +2 -2
  120. package/cloud-runtime/standalone/.next/server/app/automations.segments/automations/__PAGE__.segment.rsc +2 -2
  121. package/cloud-runtime/standalone/.next/server/app/automations.segments/automations.segment.rsc +1 -1
  122. package/cloud-runtime/standalone/.next/server/app/board/page_client-reference-manifest.js +1 -1
  123. package/cloud-runtime/standalone/.next/server/app/board.html +2 -2
  124. package/cloud-runtime/standalone/.next/server/app/board.rsc +2 -2
  125. package/cloud-runtime/standalone/.next/server/app/board.segments/_full.segment.rsc +2 -2
  126. package/cloud-runtime/standalone/.next/server/app/board.segments/_head.segment.rsc +1 -1
  127. package/cloud-runtime/standalone/.next/server/app/board.segments/_index.segment.rsc +2 -2
  128. package/cloud-runtime/standalone/.next/server/app/board.segments/_tree.segment.rsc +2 -2
  129. package/cloud-runtime/standalone/.next/server/app/board.segments/board/__PAGE__.segment.rsc +1 -1
  130. package/cloud-runtime/standalone/.next/server/app/board.segments/board.segment.rsc +1 -1
  131. package/cloud-runtime/standalone/.next/server/app/execution-graph/page.js.nft.json +1 -1
  132. package/cloud-runtime/standalone/.next/server/app/execution-graph/page_client-reference-manifest.js +1 -1
  133. package/cloud-runtime/standalone/.next/server/app/execution-graph.html +2 -2
  134. package/cloud-runtime/standalone/.next/server/app/execution-graph.rsc +3 -3
  135. package/cloud-runtime/standalone/.next/server/app/execution-graph.segments/_full.segment.rsc +3 -3
  136. package/cloud-runtime/standalone/.next/server/app/execution-graph.segments/_head.segment.rsc +1 -1
  137. package/cloud-runtime/standalone/.next/server/app/execution-graph.segments/_index.segment.rsc +2 -2
  138. package/cloud-runtime/standalone/.next/server/app/execution-graph.segments/_tree.segment.rsc +2 -2
  139. package/cloud-runtime/standalone/.next/server/app/execution-graph.segments/execution-graph/__PAGE__.segment.rsc +2 -2
  140. package/cloud-runtime/standalone/.next/server/app/execution-graph.segments/execution-graph.segment.rsc +1 -1
  141. package/cloud-runtime/standalone/.next/server/app/folders/page.js.nft.json +1 -1
  142. package/cloud-runtime/standalone/.next/server/app/folders/page_client-reference-manifest.js +1 -1
  143. package/cloud-runtime/standalone/.next/server/app/folders.html +2 -2
  144. package/cloud-runtime/standalone/.next/server/app/folders.rsc +3 -3
  145. package/cloud-runtime/standalone/.next/server/app/folders.segments/_full.segment.rsc +3 -3
  146. package/cloud-runtime/standalone/.next/server/app/folders.segments/_head.segment.rsc +1 -1
  147. package/cloud-runtime/standalone/.next/server/app/folders.segments/_index.segment.rsc +2 -2
  148. package/cloud-runtime/standalone/.next/server/app/folders.segments/_tree.segment.rsc +2 -2
  149. package/cloud-runtime/standalone/.next/server/app/folders.segments/folders/__PAGE__.segment.rsc +2 -2
  150. package/cloud-runtime/standalone/.next/server/app/folders.segments/folders.segment.rsc +1 -1
  151. package/cloud-runtime/standalone/.next/server/app/index.html +2 -2
  152. package/cloud-runtime/standalone/.next/server/app/index.rsc +3 -3
  153. package/cloud-runtime/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
  154. package/cloud-runtime/standalone/.next/server/app/index.segments/_full.segment.rsc +3 -3
  155. package/cloud-runtime/standalone/.next/server/app/index.segments/_head.segment.rsc +1 -1
  156. package/cloud-runtime/standalone/.next/server/app/index.segments/_index.segment.rsc +2 -2
  157. package/cloud-runtime/standalone/.next/server/app/index.segments/_tree.segment.rsc +2 -2
  158. package/cloud-runtime/standalone/.next/server/app/page.js.nft.json +1 -1
  159. package/cloud-runtime/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  160. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/automations/page/react-loadable-manifest.json +1 -1
  161. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/automations/page.js.nft.json +1 -1
  162. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/automations/page_client-reference-manifest.js +1 -1
  163. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/graph/[taskId]/page.js.nft.json +1 -1
  164. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/graph/[taskId]/page_client-reference-manifest.js +1 -1
  165. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/knowledge/page.js.nft.json +1 -1
  166. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/knowledge/page_client-reference-manifest.js +1 -1
  167. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/linear/page/react-loadable-manifest.json +1 -1
  168. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/linear/page.js.nft.json +1 -1
  169. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/linear/page_client-reference-manifest.js +1 -1
  170. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/page.js.nft.json +1 -1
  171. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/page_client-reference-manifest.js +1 -1
  172. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/thread/[threadId]/page.js.nft.json +1 -1
  173. package/cloud-runtime/standalone/.next/server/app/projects/[slug]/thread/[threadId]/page_client-reference-manifest.js +1 -1
  174. package/cloud-runtime/standalone/.next/server/app/projects/orphans/page_client-reference-manifest.js +1 -1
  175. package/cloud-runtime/standalone/.next/server/app/projects/orphans.html +2 -2
  176. package/cloud-runtime/standalone/.next/server/app/projects/orphans.rsc +2 -2
  177. package/cloud-runtime/standalone/.next/server/app/projects/orphans.segments/_full.segment.rsc +2 -2
  178. package/cloud-runtime/standalone/.next/server/app/projects/orphans.segments/_head.segment.rsc +1 -1
  179. package/cloud-runtime/standalone/.next/server/app/projects/orphans.segments/_index.segment.rsc +2 -2
  180. package/cloud-runtime/standalone/.next/server/app/projects/orphans.segments/_tree.segment.rsc +2 -2
  181. package/cloud-runtime/standalone/.next/server/app/projects/orphans.segments/projects/orphans/__PAGE__.segment.rsc +1 -1
  182. package/cloud-runtime/standalone/.next/server/app/projects/orphans.segments/projects/orphans.segment.rsc +1 -1
  183. package/cloud-runtime/standalone/.next/server/app/projects/orphans.segments/projects.segment.rsc +1 -1
  184. package/cloud-runtime/standalone/.next/server/app/projects/page_client-reference-manifest.js +1 -1
  185. package/cloud-runtime/standalone/.next/server/app/projects.html +2 -2
  186. package/cloud-runtime/standalone/.next/server/app/projects.rsc +2 -2
  187. package/cloud-runtime/standalone/.next/server/app/projects.segments/_full.segment.rsc +2 -2
  188. package/cloud-runtime/standalone/.next/server/app/projects.segments/_head.segment.rsc +1 -1
  189. package/cloud-runtime/standalone/.next/server/app/projects.segments/_index.segment.rsc +2 -2
  190. package/cloud-runtime/standalone/.next/server/app/projects.segments/_tree.segment.rsc +2 -2
  191. package/cloud-runtime/standalone/.next/server/app/projects.segments/projects/__PAGE__.segment.rsc +1 -1
  192. package/cloud-runtime/standalone/.next/server/app/projects.segments/projects.segment.rsc +1 -1
  193. package/cloud-runtime/standalone/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  194. package/cloud-runtime/standalone/.next/server/app/settings.html +2 -2
  195. package/cloud-runtime/standalone/.next/server/app/settings.rsc +2 -2
  196. package/cloud-runtime/standalone/.next/server/app/settings.segments/_full.segment.rsc +2 -2
  197. package/cloud-runtime/standalone/.next/server/app/settings.segments/_head.segment.rsc +1 -1
  198. package/cloud-runtime/standalone/.next/server/app/settings.segments/_index.segment.rsc +2 -2
  199. package/cloud-runtime/standalone/.next/server/app/settings.segments/_tree.segment.rsc +2 -2
  200. package/cloud-runtime/standalone/.next/server/app/settings.segments/settings/__PAGE__.segment.rsc +1 -1
  201. package/cloud-runtime/standalone/.next/server/app/settings.segments/settings.segment.rsc +1 -1
  202. package/cloud-runtime/standalone/.next/server/app/skills/page_client-reference-manifest.js +1 -1
  203. package/cloud-runtime/standalone/.next/server/app/skills.html +2 -2
  204. package/cloud-runtime/standalone/.next/server/app/skills.rsc +2 -2
  205. package/cloud-runtime/standalone/.next/server/app/skills.segments/_full.segment.rsc +2 -2
  206. package/cloud-runtime/standalone/.next/server/app/skills.segments/_head.segment.rsc +1 -1
  207. package/cloud-runtime/standalone/.next/server/app/skills.segments/_index.segment.rsc +2 -2
  208. package/cloud-runtime/standalone/.next/server/app/skills.segments/_tree.segment.rsc +2 -2
  209. package/cloud-runtime/standalone/.next/server/app/skills.segments/skills/__PAGE__.segment.rsc +1 -1
  210. package/cloud-runtime/standalone/.next/server/app/skills.segments/skills.segment.rsc +1 -1
  211. package/cloud-runtime/standalone/.next/server/app/status/page_client-reference-manifest.js +1 -1
  212. package/cloud-runtime/standalone/.next/server/app/status.html +2 -2
  213. package/cloud-runtime/standalone/.next/server/app/status.rsc +2 -2
  214. package/cloud-runtime/standalone/.next/server/app/status.segments/_full.segment.rsc +2 -2
  215. package/cloud-runtime/standalone/.next/server/app/status.segments/_head.segment.rsc +1 -1
  216. package/cloud-runtime/standalone/.next/server/app/status.segments/_index.segment.rsc +2 -2
  217. package/cloud-runtime/standalone/.next/server/app/status.segments/_tree.segment.rsc +2 -2
  218. package/cloud-runtime/standalone/.next/server/app/status.segments/status/__PAGE__.segment.rsc +1 -1
  219. package/cloud-runtime/standalone/.next/server/app/status.segments/status.segment.rsc +1 -1
  220. package/cloud-runtime/standalone/.next/server/app/thread/[id]/page.js.nft.json +1 -1
  221. package/cloud-runtime/standalone/.next/server/app/thread/[id]/page_client-reference-manifest.js +1 -1
  222. package/cloud-runtime/standalone/.next/server/app/welcome/page.js.nft.json +1 -1
  223. package/cloud-runtime/standalone/.next/server/app/welcome/page_client-reference-manifest.js +1 -1
  224. package/cloud-runtime/standalone/.next/server/app/welcome.html +2 -2
  225. package/cloud-runtime/standalone/.next/server/app/welcome.rsc +3 -3
  226. package/cloud-runtime/standalone/.next/server/app/welcome.segments/_full.segment.rsc +3 -3
  227. package/cloud-runtime/standalone/.next/server/app/welcome.segments/_head.segment.rsc +1 -1
  228. package/cloud-runtime/standalone/.next/server/app/welcome.segments/_index.segment.rsc +2 -2
  229. package/cloud-runtime/standalone/.next/server/app/welcome.segments/_tree.segment.rsc +2 -2
  230. package/cloud-runtime/standalone/.next/server/app/welcome.segments/welcome/__PAGE__.segment.rsc +2 -2
  231. package/cloud-runtime/standalone/.next/server/app/welcome.segments/welcome.segment.rsc +1 -1
  232. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__015d40a6._.js +67 -0
  233. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__067034dd._.js +67 -0
  234. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__20a2cb22._.js +8 -8
  235. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__37844df7._.js +67 -0
  236. package/cloud-runtime/standalone/.next/server/chunks/{[root-of-the-server]__d9f2041b._.js → [root-of-the-server]__3a93931b._.js} +4 -4
  237. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__a3955224._.js +16 -16
  238. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__c8890cd6._.js +12 -12
  239. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__0b2a2b86._.js +3 -0
  240. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__32546242._.js +3 -0
  241. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__5ff9ead4._.js +3 -0
  242. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__f2c3b7ab._.js +1 -1
  243. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__f59f0dc7._.js +3 -0
  244. package/cloud-runtime/standalone/.next/server/chunks/ssr/{[root-of-the-server]__d96bb3b5._.js → [root-of-the-server]__fbe1ab4a._.js} +2 -2
  245. package/cloud-runtime/standalone/.next/server/chunks/ssr/_1e9b9b1e._.js +3 -0
  246. package/cloud-runtime/standalone/.next/server/chunks/ssr/_24fe6213._.js +3 -0
  247. package/cloud-runtime/standalone/.next/server/chunks/ssr/_36a0c486._.js +3 -0
  248. package/cloud-runtime/standalone/.next/server/chunks/ssr/_3b21d3b2._.js +95 -0
  249. package/cloud-runtime/standalone/.next/server/chunks/ssr/_3eeac8f9._.js +3 -0
  250. package/cloud-runtime/standalone/.next/server/chunks/ssr/_48db42b7._.js +3 -0
  251. package/cloud-runtime/standalone/.next/server/chunks/ssr/_59f30a73._.js +3 -0
  252. package/cloud-runtime/standalone/.next/server/chunks/ssr/_7d3b0032._.js +3 -0
  253. package/cloud-runtime/standalone/.next/server/chunks/ssr/_916950b3._.js +3 -0
  254. package/cloud-runtime/standalone/.next/server/chunks/ssr/_b598ae8a._.js +3 -0
  255. package/cloud-runtime/standalone/.next/server/chunks/ssr/_cc8c8302._.js +3 -0
  256. package/cloud-runtime/standalone/.next/server/chunks/ssr/_d972a4e1._.js +3 -0
  257. package/cloud-runtime/standalone/.next/server/chunks/ssr/_dd7bb6fb._.js +3 -0
  258. package/cloud-runtime/standalone/.next/server/chunks/ssr/_dd9880fb._.js +3 -0
  259. package/cloud-runtime/standalone/.next/server/chunks/ssr/_f02d786a._.js +3 -0
  260. package/cloud-runtime/standalone/.next/server/chunks/ssr/_fd8cafe9._.js +3 -0
  261. package/cloud-runtime/standalone/.next/server/chunks/ssr/app_projects_[slug]_linear_page_tsx_971a6ba7._.js +15 -12
  262. package/cloud-runtime/standalone/.next/server/chunks/ssr/components_chat-ui_bfeda794._.js +1 -1
  263. package/cloud-runtime/standalone/.next/server/chunks/ssr/components_thread_WorkspaceSidebar_tsx_e660301b._.js +1 -1
  264. package/cloud-runtime/standalone/.next/server/chunks/ssr/node_modules_lucide-react_dist_esm_54bf563f._.js +3 -0
  265. package/cloud-runtime/standalone/.next/server/middleware-manifest.json +5 -5
  266. package/cloud-runtime/standalone/.next/server/pages/404.html +2 -2
  267. package/cloud-runtime/standalone/.next/server/pages/500.html +2 -2
  268. package/cloud-runtime/standalone/.next/server/server-reference-manifest.js +1 -1
  269. package/cloud-runtime/standalone/.next/server/server-reference-manifest.json +1 -1
  270. package/cloud-runtime/standalone/.next/static/chunks/04c135686161dbb1.js +40 -0
  271. package/cloud-runtime/standalone/.next/static/chunks/0d63db0c39c0a3b2.js +1 -0
  272. package/cloud-runtime/standalone/.next/static/chunks/136ed07d84b14632.js +1 -0
  273. package/cloud-runtime/standalone/.next/static/chunks/18866ed04ed3a063.css +1 -0
  274. package/cloud-runtime/standalone/.next/static/chunks/{ccaf68956da192f8.js → 1bb38e61d891453c.js} +1 -1
  275. package/cloud-runtime/standalone/.next/static/chunks/2c7c8259c2b56bf5.js +1 -0
  276. package/cloud-runtime/standalone/.next/static/chunks/2da1f13d50dc4e54.js +1 -0
  277. package/cloud-runtime/standalone/.next/static/chunks/{fdadad2379039dce.js → 442eb8ef62bef9f9.js} +3 -3
  278. package/cloud-runtime/standalone/.next/static/chunks/{41c518743656a291.js → 5f33b52d582b0bb4.js} +1 -1
  279. package/cloud-runtime/standalone/.next/static/chunks/{97c11137cd6fc860.js → 64c2961edd3a3b13.js} +1 -1
  280. package/cloud-runtime/standalone/.next/static/chunks/{db131a0b6350e416.js → 692ce04abdbb3970.js} +1 -1
  281. package/cloud-runtime/standalone/.next/static/chunks/83be8569d298c6b0.js +1 -0
  282. package/cloud-runtime/standalone/.next/static/chunks/87b3afe828c8cc52.js +1 -0
  283. package/cloud-runtime/standalone/.next/static/chunks/{4343e7fe5bf5f34a.js → 9328740727c6456d.js} +1 -1
  284. package/cloud-runtime/standalone/.next/static/chunks/95d47e285ae9c031.js +1 -0
  285. package/cloud-runtime/standalone/.next/static/chunks/b9bf5d3ee92a1313.js +1 -0
  286. package/cloud-runtime/standalone/.next/static/chunks/ea35fb870141bcff.js +1 -0
  287. package/cloud-runtime/standalone/.next/static/chunks/f59722264449b61c.js +1 -0
  288. package/cloud-runtime/standalone/.next/static/chunks/f727d2c8f039511d.js +1 -0
  289. package/cloud-runtime/standalone/.next/static/chunks/{31fe4e36a00fd7b5.js → f8706212baa8ec67.js} +1 -1
  290. package/cloud-runtime/standalone/.next/static/chunks/fd823c9d1381335d.js +1 -0
  291. package/cloud-runtime/standalone/app/automations/page.tsx +11 -1
  292. package/cloud-runtime/standalone/app/projects/[slug]/layout.tsx +11 -1
  293. package/cloud-runtime/standalone/components/LinearBoard.tsx +118 -21
  294. package/cloud-runtime/standalone/components/chat-ui/ChatContainer.tsx +10 -0
  295. package/cloud-runtime/standalone/components/linear/RunScriptManager.tsx +356 -0
  296. package/cloud-runtime/standalone/components/thread/WorkspaceSidebar.tsx +35 -0
  297. package/cloud-runtime/standalone/hooks/useLinearRunScripts.ts +115 -0
  298. package/cloud-runtime/standalone/lib/linear-client.ts +33 -3
  299. package/cloud-runtime/standalone/lib/linear-execution-prompt.ts +92 -15
  300. package/cloud-runtime/standalone/state/automations/.state/c4300b01-1203-40fe-b3a9-b9fb9ec0c5cc.json +8 -0
  301. package/cloud-runtime/standalone/state/automations/active/c4300b01-1203-40fe-b3a9-b9fb9ec0c5cc.md +15 -0
  302. package/cloud-runtime/standalone/state/linearRunScripts.test.ts +99 -0
  303. package/cloud-runtime/standalone/state/linearRunScripts.ts +132 -0
  304. package/cloud-runtime/standalone/state/windowState.ts +21 -0
  305. package/cloud-runtime/standalone/tsconfig.tsbuildinfo +1 -1
  306. package/package.json +1 -1
  307. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__1154e5b3._.js +0 -67
  308. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__76290829._.js +0 -67
  309. package/cloud-runtime/standalone/.next/server/chunks/[root-of-the-server]__ad6d6402._.js +0 -67
  310. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__21a9eaef._.js +0 -3
  311. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__69887882._.js +0 -3
  312. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__9ad05ace._.js +0 -3
  313. package/cloud-runtime/standalone/.next/server/chunks/ssr/[root-of-the-server]__bb149a22._.js +0 -3
  314. package/cloud-runtime/standalone/.next/server/chunks/ssr/_11ce4c04._.js +0 -95
  315. package/cloud-runtime/standalone/.next/server/chunks/ssr/_1d949e96._.js +0 -3
  316. package/cloud-runtime/standalone/.next/server/chunks/ssr/_32a156b6._.js +0 -3
  317. package/cloud-runtime/standalone/.next/server/chunks/ssr/_43c091dc._.js +0 -3
  318. package/cloud-runtime/standalone/.next/server/chunks/ssr/_45175f47._.js +0 -3
  319. package/cloud-runtime/standalone/.next/server/chunks/ssr/_4f0c544d._.js +0 -3
  320. package/cloud-runtime/standalone/.next/server/chunks/ssr/_69164b06._.js +0 -95
  321. package/cloud-runtime/standalone/.next/server/chunks/ssr/_7f7a828a._.js +0 -3
  322. package/cloud-runtime/standalone/.next/server/chunks/ssr/_97f6a18e._.js +0 -3
  323. package/cloud-runtime/standalone/.next/server/chunks/ssr/_a511a014._.js +0 -3
  324. package/cloud-runtime/standalone/.next/server/chunks/ssr/_c3a3a829._.js +0 -3
  325. package/cloud-runtime/standalone/.next/server/chunks/ssr/_cee3cf86._.js +0 -95
  326. package/cloud-runtime/standalone/.next/server/chunks/ssr/node_modules_lucide-react_dist_esm_e8bdedc5._.js +0 -3
  327. package/cloud-runtime/standalone/.next/static/chunks/14fff3c493ea9c54.js +0 -1
  328. package/cloud-runtime/standalone/.next/static/chunks/2a9c83f8211196e0.js +0 -1
  329. package/cloud-runtime/standalone/.next/static/chunks/5405540470146645.js +0 -1
  330. package/cloud-runtime/standalone/.next/static/chunks/69f2db4b9996b9c1.js +0 -37
  331. package/cloud-runtime/standalone/.next/static/chunks/8aeb69ceb497ad85.css +0 -1
  332. package/cloud-runtime/standalone/.next/static/chunks/a9da98f883ac833b.js +0 -1
  333. package/cloud-runtime/standalone/.next/static/chunks/b2127dc67c5ade9f.js +0 -1
  334. package/cloud-runtime/standalone/.next/static/chunks/baf5d39d089efb87.js +0 -1
  335. package/cloud-runtime/standalone/.next/static/chunks/bf2a2fafb710e63c.js +0 -1
  336. package/cloud-runtime/standalone/.next/static/chunks/c78969fde5798275.js +0 -1
  337. package/cloud-runtime/standalone/.next/static/chunks/d3dc6fadb96ab3a2.js +0 -1
  338. package/cloud-runtime/standalone/state/automations/.state/24a6a5db-3b14-49c4-841f-29f10f015fbb.json +0 -8
  339. package/cloud-runtime/standalone/state/automations/active/24a6a5db-3b14-49c4-841f-29f10f015fbb.md +0 -17
  340. /package/cloud-runtime/standalone/.next/static/{lOB5InbmVcurTLQo9J3KK → gty0FO80D_lbq3o9lSpQQ}/_buildManifest.js +0 -0
  341. /package/cloud-runtime/standalone/.next/static/{lOB5InbmVcurTLQo9J3KK → gty0FO80D_lbq3o9lSpQQ}/_clientMiddlewareManifest.json +0 -0
  342. /package/cloud-runtime/standalone/.next/static/{lOB5InbmVcurTLQo9J3KK → gty0FO80D_lbq3o9lSpQQ}/_ssgManifest.js +0 -0
@@ -0,0 +1,356 @@
1
+ "use client";
2
+
3
+ import { useEffect, useMemo, useState } from "react";
4
+ import { Check, Plus, Save, Trash2 } from "lucide-react";
5
+ import ConfirmDialog from "@/components/ConfirmDialog";
6
+ import RichTextEditor from "@/components/RichTextEditor";
7
+ import type { LinearRunScript } from "@/state/linearRunScripts";
8
+
9
+ type EditorMode =
10
+ | { type: "new" }
11
+ | { type: "edit"; scriptId: string };
12
+
13
+ interface RunScriptManagerProps {
14
+ projectSlug?: string | null;
15
+ scripts: LinearRunScript[];
16
+ activeScriptId: string | null;
17
+ onSetActiveScriptId: (scriptId: string | null) => void;
18
+ onSaveScript: (input: { id?: string; name: string; prompt: string }) => LinearRunScript;
19
+ onDeleteScript: (scriptId: string) => void;
20
+ }
21
+
22
+ function formatUpdatedAt(iso: string): string {
23
+ try {
24
+ return new Date(iso).toLocaleString([], {
25
+ month: "short",
26
+ day: "numeric",
27
+ hour: "numeric",
28
+ minute: "2-digit",
29
+ });
30
+ } catch {
31
+ return iso;
32
+ }
33
+ }
34
+
35
+ function buildProjectLabel(projectSlug?: string | null): string {
36
+ return String(projectSlug ?? "").trim() || "global Linear board";
37
+ }
38
+
39
+ export default function RunScriptManager({
40
+ projectSlug,
41
+ scripts,
42
+ activeScriptId,
43
+ onSetActiveScriptId,
44
+ onSaveScript,
45
+ onDeleteScript,
46
+ }: RunScriptManagerProps) {
47
+ const activeScript = useMemo(
48
+ () => scripts.find((script) => script.id === activeScriptId) ?? null,
49
+ [activeScriptId, scripts]
50
+ );
51
+ const [editorMode, setEditorMode] = useState<EditorMode>(() =>
52
+ activeScriptId ? { type: "edit", scriptId: activeScriptId } : { type: "new" }
53
+ );
54
+ const [draftName, setDraftName] = useState("");
55
+ const [draftPrompt, setDraftPrompt] = useState("");
56
+ const [error, setError] = useState<string | null>(null);
57
+ const [deleteTarget, setDeleteTarget] = useState<LinearRunScript | null>(null);
58
+ const editingScriptId = editorMode.type === "edit" ? editorMode.scriptId : null;
59
+
60
+ useEffect(() => {
61
+ if (editorMode.type === "edit") {
62
+ const script = scripts.find((entry) => entry.id === editorMode.scriptId);
63
+ if (script) {
64
+ setDraftName(script.name);
65
+ setDraftPrompt(script.prompt);
66
+ return;
67
+ }
68
+ }
69
+
70
+ if (activeScript && editorMode.type !== "new") {
71
+ if (editorMode.type !== "edit" || editorMode.scriptId !== activeScript.id) {
72
+ setEditorMode({ type: "edit", scriptId: activeScript.id });
73
+ }
74
+ setDraftName(activeScript.name);
75
+ setDraftPrompt(activeScript.prompt);
76
+ return;
77
+ }
78
+
79
+ if (scripts.length === 0) {
80
+ if (editorMode.type !== "new") {
81
+ setEditorMode({ type: "new" });
82
+ setDraftName("");
83
+ setDraftPrompt("");
84
+ }
85
+ }
86
+ }, [activeScript, editingScriptId, editorMode, scripts]);
87
+
88
+ const selectScript = (script: LinearRunScript) => {
89
+ setEditorMode({ type: "edit", scriptId: script.id });
90
+ setDraftName(script.name);
91
+ setDraftPrompt(script.prompt);
92
+ setError(null);
93
+ onSetActiveScriptId(script.id);
94
+ };
95
+
96
+ const startNewScript = () => {
97
+ setEditorMode({ type: "new" });
98
+ setDraftName("");
99
+ setDraftPrompt("");
100
+ setError(null);
101
+ };
102
+
103
+ const handleSaveNew = () => {
104
+ try {
105
+ const saved = onSaveScript({
106
+ name: draftName,
107
+ prompt: draftPrompt,
108
+ });
109
+ setEditorMode({ type: "edit", scriptId: saved.id });
110
+ setError(null);
111
+ } catch (saveError) {
112
+ setError(saveError instanceof Error ? saveError.message : "Failed to save run script.");
113
+ }
114
+ };
115
+
116
+ const handleUpdate = () => {
117
+ if (editorMode.type !== "edit") {
118
+ handleSaveNew();
119
+ return;
120
+ }
121
+
122
+ try {
123
+ const saved = onSaveScript({
124
+ id: editorMode.scriptId,
125
+ name: draftName,
126
+ prompt: draftPrompt,
127
+ });
128
+ setEditorMode({ type: "edit", scriptId: saved.id });
129
+ setError(null);
130
+ } catch (saveError) {
131
+ setError(saveError instanceof Error ? saveError.message : "Failed to update run script.");
132
+ }
133
+ };
134
+
135
+ const confirmDelete = () => {
136
+ if (!deleteTarget) {
137
+ return;
138
+ }
139
+
140
+ onDeleteScript(deleteTarget.id);
141
+ if (editorMode.type === "edit" && editorMode.scriptId === deleteTarget.id) {
142
+ setEditorMode({ type: "new" });
143
+ setDraftName("");
144
+ setDraftPrompt("");
145
+ }
146
+ setDeleteTarget(null);
147
+ setError(null);
148
+ };
149
+
150
+ return (
151
+ <div className="flex flex-col gap-5">
152
+ <div className="flex flex-col gap-1">
153
+ <h3 className="text-sm font-semibold text-[var(--foreground)]">Run Scripts</h3>
154
+ <p className="text-xs leading-relaxed text-[var(--muted-foreground)]">
155
+ Save reusable execution prompts for the {buildProjectLabel(projectSlug)}. These scripts are stored locally on this device and layered on top of the built-in ticket context when you run a Linear task.
156
+ </p>
157
+ </div>
158
+
159
+ <div className="grid gap-5 md:grid-cols-[240px_minmax(0,1fr)]">
160
+ <aside className="rounded-xl border border-[var(--card-border)] bg-[var(--card-bg)] p-3">
161
+ <div className="mb-3 flex items-center justify-between">
162
+ <span className="text-[11px] font-semibold uppercase tracking-[0.16em] text-[var(--muted-foreground)]">
163
+ Library
164
+ </span>
165
+ <button
166
+ type="button"
167
+ className="inline-flex items-center gap-1 rounded-md border border-[var(--card-border)] px-2 py-1 text-[11px] font-medium text-[var(--foreground)] transition-colors hover:bg-[var(--background)]"
168
+ onClick={startNewScript}
169
+ >
170
+ <Plus size={12} />
171
+ New
172
+ </button>
173
+ </div>
174
+
175
+ <div className="flex flex-col gap-1.5">
176
+ <button
177
+ type="button"
178
+ className={`flex w-full items-center gap-2 rounded-lg px-3 py-2 text-left text-xs transition-colors ${
179
+ activeScriptId === null
180
+ ? "bg-[var(--background)] text-[var(--foreground)]"
181
+ : "text-[var(--muted-foreground)] hover:bg-[var(--background)] hover:text-[var(--foreground)]"
182
+ }`}
183
+ onClick={() => onSetActiveScriptId(null)}
184
+ >
185
+ <span
186
+ className={`flex h-4 w-4 shrink-0 items-center justify-center rounded-full border ${
187
+ activeScriptId === null
188
+ ? "border-blue-500 bg-blue-500 text-white"
189
+ : "border-[var(--card-border)]"
190
+ }`}
191
+ >
192
+ {activeScriptId === null ? <Check size={10} /> : null}
193
+ </span>
194
+ <span className="min-w-0 flex-1 truncate font-medium">AGX default</span>
195
+ </button>
196
+
197
+ {scripts.length === 0 ? (
198
+ <div className="rounded-lg border border-dashed border-[var(--card-border)] px-3 py-4 text-xs leading-relaxed text-[var(--muted-foreground)]">
199
+ No saved scripts yet. Create one to reuse your preferred Linear execution prompt.
200
+ </div>
201
+ ) : (
202
+ scripts.map((script) => {
203
+ const isActive = script.id === activeScriptId;
204
+ const isEditing = editorMode.type === "edit" && editorMode.scriptId === script.id;
205
+ return (
206
+ <button
207
+ key={script.id}
208
+ type="button"
209
+ className={`rounded-lg border px-3 py-2 text-left transition-colors ${
210
+ isEditing
211
+ ? "border-blue-500/50 bg-[var(--background)]"
212
+ : "border-transparent hover:border-[var(--card-border)] hover:bg-[var(--background)]"
213
+ }`}
214
+ onClick={() => selectScript(script)}
215
+ >
216
+ <div className="flex items-start gap-2">
217
+ <span
218
+ className={`mt-0.5 flex h-4 w-4 shrink-0 items-center justify-center rounded-full border ${
219
+ isActive
220
+ ? "border-blue-500 bg-blue-500 text-white"
221
+ : "border-[var(--card-border)]"
222
+ }`}
223
+ >
224
+ {isActive ? <Check size={10} /> : null}
225
+ </span>
226
+ <div className="min-w-0 flex-1">
227
+ <div className="truncate text-xs font-medium text-[var(--foreground)]">
228
+ {script.name}
229
+ </div>
230
+ <div className="mt-1 line-clamp-2 text-[11px] leading-relaxed text-[var(--muted-foreground)]">
231
+ {script.prompt}
232
+ </div>
233
+ <div className="mt-2 text-[10px] uppercase tracking-[0.14em] text-[var(--muted-foreground)]">
234
+ Updated {formatUpdatedAt(script.updatedAt)}
235
+ </div>
236
+ </div>
237
+ </div>
238
+ </button>
239
+ );
240
+ })
241
+ )}
242
+ </div>
243
+ </aside>
244
+
245
+ <section className="rounded-xl border border-[var(--card-border)] bg-[var(--card-bg)] p-4">
246
+ <div className="mb-4 flex items-start justify-between gap-3">
247
+ <div>
248
+ <h4 className="text-sm font-semibold text-[var(--foreground)]">
249
+ {editorMode.type === "edit" ? "Edit Run Script" : "New Run Script"}
250
+ </h4>
251
+ <p className="mt-1 text-xs leading-relaxed text-[var(--muted-foreground)]">
252
+ Use placeholders like <code>{"{{ticket.identifier}}"}</code>, <code>{"{{ticket.title}}"}</code>, <code>{"{{ticket.status}}"}</code>, <code>{"{{ticket.assignee}}"}</code>, <code>{"{{project.slug}}"}</code>, <code>{"{{knowledge_base.root}}"}</code>, <code>{"{{knowledge_base.issue_path}}"}</code>, and <code>{"{{worktree.path}}"}</code>.
253
+ </p>
254
+ </div>
255
+ {activeScript ? (
256
+ <span className="rounded-full border border-blue-500/30 bg-blue-500/10 px-2.5 py-1 text-[11px] font-medium text-blue-400">
257
+ Active: {activeScript.name}
258
+ </span>
259
+ ) : (
260
+ <span className="rounded-full border border-[var(--card-border)] px-2.5 py-1 text-[11px] font-medium text-[var(--muted-foreground)]">
261
+ Active: AGX default
262
+ </span>
263
+ )}
264
+ </div>
265
+
266
+ <div className="flex flex-col gap-3">
267
+ <label className="flex flex-col gap-1.5">
268
+ <span className="text-[11px] font-semibold uppercase tracking-[0.14em] text-[var(--muted-foreground)]">
269
+ Name
270
+ </span>
271
+ <input
272
+ type="text"
273
+ className="rounded-lg border border-[var(--card-border)] bg-[var(--background)] px-3 py-2 text-sm text-[var(--foreground)] outline-none transition-colors focus:border-blue-500"
274
+ placeholder="Investigation-first"
275
+ value={draftName}
276
+ onChange={(event) => setDraftName(event.target.value)}
277
+ />
278
+ </label>
279
+
280
+ <div className="flex flex-col gap-1.5">
281
+ <span className="text-[11px] font-semibold uppercase tracking-[0.14em] text-[var(--muted-foreground)]">
282
+ Prompt
283
+ </span>
284
+ <div className="overflow-hidden rounded-lg border border-[var(--card-border)] bg-[var(--background)] transition-colors focus-within:border-blue-500 [&_.rich-text-editor_.ProseMirror]:min-h-[220px]">
285
+ <RichTextEditor
286
+ content={draftPrompt}
287
+ onChange={setDraftPrompt}
288
+ placeholder={"Read {{ticket.identifier}} and the full comment thread in Linear before changing code.\nWrite your investigation to {{knowledge_base.issue_path}} and stop after posting a plan unless the issue is already approved for implementation."}
289
+ />
290
+ </div>
291
+ </div>
292
+
293
+ {error ? (
294
+ <div className="rounded-lg border border-red-500/30 bg-red-500/10 px-3 py-2 text-xs text-red-300">
295
+ {error}
296
+ </div>
297
+ ) : null}
298
+
299
+ <div className="flex flex-wrap items-center gap-2">
300
+ <button
301
+ type="button"
302
+ className="inline-flex items-center gap-1.5 rounded-lg bg-blue-500 px-3 py-2 text-sm font-medium text-white transition-colors hover:bg-blue-600"
303
+ onClick={handleSaveNew}
304
+ >
305
+ <Save size={14} />
306
+ Save as new
307
+ </button>
308
+ {editorMode.type === "edit" ? (
309
+ <button
310
+ type="button"
311
+ className="inline-flex items-center gap-1.5 rounded-lg border border-[var(--card-border)] px-3 py-2 text-sm font-medium text-[var(--foreground)] transition-colors hover:bg-[var(--background)]"
312
+ onClick={handleUpdate}
313
+ >
314
+ <Save size={14} />
315
+ Update
316
+ </button>
317
+ ) : null}
318
+ {editorMode.type === "edit" ? (
319
+ <button
320
+ type="button"
321
+ className="inline-flex items-center gap-1.5 rounded-lg border border-red-500/30 px-3 py-2 text-sm font-medium text-red-300 transition-colors hover:bg-red-500/10"
322
+ onClick={() => {
323
+ const script = scripts.find((entry) => entry.id === editorMode.scriptId) ?? null;
324
+ setDeleteTarget(script);
325
+ }}
326
+ >
327
+ <Trash2 size={14} />
328
+ Delete
329
+ </button>
330
+ ) : null}
331
+ <button
332
+ type="button"
333
+ className="inline-flex items-center gap-1.5 rounded-lg border border-[var(--card-border)] px-3 py-2 text-sm font-medium text-[var(--muted-foreground)] transition-colors hover:bg-[var(--background)] hover:text-[var(--foreground)]"
334
+ onClick={startNewScript}
335
+ >
336
+ <Plus size={14} />
337
+ Clear editor
338
+ </button>
339
+ </div>
340
+ </div>
341
+ </section>
342
+ </div>
343
+
344
+ <ConfirmDialog
345
+ isOpen={Boolean(deleteTarget)}
346
+ title="Delete run script?"
347
+ message="This removes the saved script from this device for the current project."
348
+ preview={deleteTarget?.name}
349
+ confirmLabel="Delete"
350
+ variant="danger"
351
+ onConfirm={confirmDelete}
352
+ onCancel={() => setDeleteTarget(null)}
353
+ />
354
+ </div>
355
+ );
356
+ }
@@ -45,6 +45,8 @@ interface WorkspaceSidebarProps {
45
45
  isRestoringActiveThread?: boolean;
46
46
  onToggle?: () => void;
47
47
  onSearch?: () => void;
48
+ width?: number;
49
+ onWidthChange?: (width: number) => void;
48
50
  // Projects
49
51
  projects?: ProjectWithAgents[];
50
52
  onCreateProject?: (payload: { name: string; description?: string; repos?: Array<{ name: string; path?: string; notes?: string }> }, threadId?: string) => Promise<unknown>;
@@ -90,7 +92,11 @@ export function WorkspaceSidebar({
90
92
  onSelectProject,
91
93
  activeProjectId = null,
92
94
  activeProjectView = null,
95
+ width,
96
+ onWidthChange,
93
97
  }: WorkspaceSidebarProps) {
98
+ const resizing = useRef(false);
99
+ const lastX = useRef(0);
94
100
  const emptyCtaRef = useRef<HTMLButtonElement | null>(null);
95
101
  const [hasMounted, setHasMounted] = useState(false);
96
102
  const [expandedProjects, setExpandedProjects] = useState<Set<string>>(new Set());
@@ -362,6 +368,7 @@ export function WorkspaceSidebar({
362
368
  className="workspace-sidebar"
363
369
  aria-label="Workspace sidebar"
364
370
  aria-busy={isLoading ? "true" : undefined}
371
+ style={width ? { width: `${width}px`, minWidth: `${width}px` } : undefined}
365
372
  >
366
373
  <div className="workspace-sidebar__brand">
367
374
  <div className="workspace-sidebar__brand-content flex items-center gap-2 px-1">
@@ -1262,6 +1269,34 @@ export function WorkspaceSidebar({
1262
1269
  />
1263
1270
  );
1264
1271
  })(), document.body)}
1272
+ {onWidthChange && (
1273
+ <div
1274
+ className="absolute right-0 top-0 bottom-0 z-20 w-1 cursor-col-resize group"
1275
+ onMouseDown={(e) => {
1276
+ e.preventDefault();
1277
+ resizing.current = true;
1278
+ const startX = e.clientX;
1279
+ const startWidth = width ?? 368;
1280
+ document.body.style.cursor = "col-resize";
1281
+ document.body.style.userSelect = "none";
1282
+ const onMouseMove = (ev: MouseEvent) => {
1283
+ const newWidth = Math.max(200, Math.min(600, startWidth + ev.clientX - startX));
1284
+ onWidthChange(newWidth);
1285
+ };
1286
+ const onMouseUp = () => {
1287
+ resizing.current = false;
1288
+ document.body.style.cursor = "";
1289
+ document.body.style.userSelect = "";
1290
+ window.removeEventListener("mousemove", onMouseMove);
1291
+ window.removeEventListener("mouseup", onMouseUp);
1292
+ };
1293
+ window.addEventListener("mousemove", onMouseMove);
1294
+ window.addEventListener("mouseup", onMouseUp);
1295
+ }}
1296
+ >
1297
+ <div className="absolute inset-y-0 right-0 w-1 transition-colors hover:bg-[var(--primary)]/40 group-hover:bg-[var(--primary)]/40" />
1298
+ </div>
1299
+ )}
1265
1300
  </aside>
1266
1301
  );
1267
1302
  }
@@ -0,0 +1,115 @@
1
+ "use client";
2
+
3
+ import { useCallback, useEffect, useMemo, useState } from "react";
4
+ import {
5
+ loadLinearRunScripts,
6
+ persistLinearRunScripts,
7
+ type LinearRunScript,
8
+ } from "@/state/linearRunScripts";
9
+
10
+ interface SaveLinearRunScriptInput {
11
+ id?: string;
12
+ name: string;
13
+ prompt: string;
14
+ }
15
+
16
+ function buildTimestamp(): string {
17
+ return new Date().toISOString();
18
+ }
19
+
20
+ function sortScripts(scripts: LinearRunScript[]): LinearRunScript[] {
21
+ return [...scripts].sort((left, right) => right.updatedAt.localeCompare(left.updatedAt));
22
+ }
23
+
24
+ export function useLinearRunScripts(projectSlug?: string | null) {
25
+ const [scripts, setScripts] = useState<LinearRunScript[]>([]);
26
+ const [activeScriptId, setActiveScriptIdState] = useState<string | null>(null);
27
+
28
+ useEffect(() => {
29
+ const state = loadLinearRunScripts(projectSlug);
30
+ setScripts(state.scripts);
31
+ setActiveScriptIdState(state.activeScriptId);
32
+ }, [projectSlug]);
33
+
34
+ const persistState = useCallback(
35
+ (nextScripts: LinearRunScript[], nextActiveScriptId: string | null) => {
36
+ setScripts(nextScripts);
37
+ setActiveScriptIdState(nextActiveScriptId);
38
+ persistLinearRunScripts(projectSlug, {
39
+ scripts: nextScripts,
40
+ activeScriptId: nextActiveScriptId,
41
+ });
42
+ },
43
+ [projectSlug]
44
+ );
45
+
46
+ const setActiveScriptId = useCallback(
47
+ (nextActiveScriptId: string | null) => {
48
+ const normalizedId =
49
+ nextActiveScriptId && scripts.some((script) => script.id === nextActiveScriptId)
50
+ ? nextActiveScriptId
51
+ : null;
52
+ persistState(scripts, normalizedId);
53
+ },
54
+ [persistState, scripts]
55
+ );
56
+
57
+ const saveScript = useCallback(
58
+ (input: SaveLinearRunScriptInput): LinearRunScript => {
59
+ const now = buildTimestamp();
60
+ const name = input.name.trim();
61
+ const prompt = input.prompt.trim();
62
+ if (!name || !prompt) {
63
+ throw new Error("Run script name and prompt are required.");
64
+ }
65
+
66
+ const existing = input.id ? scripts.find((script) => script.id === input.id) : null;
67
+ const nextScript: LinearRunScript = existing
68
+ ? {
69
+ ...existing,
70
+ name,
71
+ prompt,
72
+ updatedAt: now,
73
+ }
74
+ : {
75
+ id: crypto.randomUUID(),
76
+ name,
77
+ prompt,
78
+ createdAt: now,
79
+ updatedAt: now,
80
+ };
81
+
82
+ const nextScripts = sortScripts(
83
+ existing
84
+ ? scripts.map((script) => (script.id === existing.id ? nextScript : script))
85
+ : [nextScript, ...scripts]
86
+ );
87
+ persistState(nextScripts, nextScript.id);
88
+ return nextScript;
89
+ },
90
+ [persistState, scripts]
91
+ );
92
+
93
+ const deleteScript = useCallback(
94
+ (scriptId: string) => {
95
+ const nextScripts = scripts.filter((script) => script.id !== scriptId);
96
+ const nextActiveScriptId = activeScriptId === scriptId ? null : activeScriptId;
97
+ persistState(nextScripts, nextActiveScriptId);
98
+ },
99
+ [activeScriptId, persistState, scripts]
100
+ );
101
+
102
+ const activeScript = useMemo(
103
+ () => scripts.find((script) => script.id === activeScriptId) ?? null,
104
+ [activeScriptId, scripts]
105
+ );
106
+
107
+ return {
108
+ scripts,
109
+ activeScriptId,
110
+ activeScript,
111
+ setActiveScriptId,
112
+ saveScript,
113
+ deleteScript,
114
+ };
115
+ }
@@ -1,9 +1,12 @@
1
1
  import "server-only";
2
2
 
3
- import { readFileSync, unlinkSync, writeFileSync } from "node:fs";
3
+ import { existsSync, mkdirSync, readFileSync, unlinkSync, writeFileSync } from "node:fs";
4
+ import { homedir } from "node:os";
4
5
  import path from "node:path";
5
6
 
6
- const TOKEN_PATH = ".linear-token.json";
7
+ const AGX_DIR = path.join(homedir(), ".agx");
8
+ const TOKEN_FILENAME = "linear-token.json";
9
+ const LEGACY_TOKEN_PATH = ".linear-token.json";
7
10
  const LINEAR_GRAPHQL_URL = "https://api.linear.app/graphql";
8
11
 
9
12
  interface LinearToken {
@@ -127,19 +130,40 @@ interface LinearIssueConnection {
127
130
  }
128
131
 
129
132
  function getTokenPath(): string {
130
- return path.join(process.cwd(), TOKEN_PATH);
133
+ return path.join(AGX_DIR, TOKEN_FILENAME);
134
+ }
135
+
136
+ function getLegacyTokenPath(): string {
137
+ return path.join(process.cwd(), LEGACY_TOKEN_PATH);
131
138
  }
132
139
 
133
140
  export function getLinearToken(): LinearToken | null {
141
+ // Try the canonical path first
134
142
  try {
135
143
  const raw = readFileSync(getTokenPath(), "utf8");
136
144
  return JSON.parse(raw) as LinearToken;
145
+ } catch {
146
+ // fall through
147
+ }
148
+
149
+ // Migrate from legacy cwd-relative path
150
+ try {
151
+ const legacyPath = getLegacyTokenPath();
152
+ const raw = readFileSync(legacyPath, "utf8");
153
+ const token = JSON.parse(raw) as LinearToken;
154
+ // Save to new location and clean up old file
155
+ saveLinearToken(token);
156
+ try { unlinkSync(legacyPath); } catch { /* ignore */ }
157
+ return token;
137
158
  } catch {
138
159
  return null;
139
160
  }
140
161
  }
141
162
 
142
163
  export function saveLinearToken(token: LinearToken): void {
164
+ if (!existsSync(AGX_DIR)) {
165
+ mkdirSync(AGX_DIR, { recursive: true });
166
+ }
143
167
  writeFileSync(getTokenPath(), JSON.stringify(token, null, 2));
144
168
  }
145
169
 
@@ -149,6 +173,12 @@ export function deleteLinearToken(): void {
149
173
  } catch {
150
174
  // already gone
151
175
  }
176
+ // Also clean up legacy location
177
+ try {
178
+ unlinkSync(getLegacyTokenPath());
179
+ } catch {
180
+ // already gone
181
+ }
152
182
  }
153
183
 
154
184
  function serializeGraphQLValue(value: unknown): string {