groove-dev 0.27.86 → 0.27.88

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 (538) hide show
  1. package/CLAUDE.md +11 -0
  2. package/moe-training/client/scrubber.js +4 -2
  3. package/moe-training/client/step-classifier.js +17 -0
  4. package/moe-training/client/trajectory-capture.js +80 -6
  5. package/moe-training/client/transmission-queue.js +11 -0
  6. package/moe-training/test/client/scrubber.test.js +14 -4
  7. package/moe-training/test/client/step-classifier.test.js +47 -0
  8. package/moe-training/test/client/transmission-queue.test.js +33 -0
  9. package/node_modules/@groove-dev/cli/bin/groove.js +10 -1
  10. package/node_modules/@groove-dev/cli/package.json +1 -1
  11. package/node_modules/@groove-dev/cli/src/commands/connect.js +116 -205
  12. package/node_modules/@groove-dev/cli/src/commands/disconnect.js +38 -62
  13. package/node_modules/@groove-dev/cli/src/commands/remotes.js +75 -0
  14. package/node_modules/@groove-dev/daemon/package.json +1 -1
  15. package/node_modules/@groove-dev/daemon/src/api.js +115 -7
  16. package/node_modules/@groove-dev/daemon/src/conversations.js +29 -3
  17. package/node_modules/@groove-dev/daemon/src/process.js +56 -1
  18. package/node_modules/@groove-dev/daemon/src/providers/codex.js +28 -10
  19. package/node_modules/@groove-dev/daemon/src/registry.js +30 -0
  20. package/node_modules/@groove-dev/daemon/src/validate.js +23 -0
  21. package/node_modules/@groove-dev/gui/dist/assets/index-BSqk8cbI.css +1 -0
  22. package/node_modules/@groove-dev/gui/dist/assets/index-B_igwWvq.js +8642 -0
  23. package/node_modules/@groove-dev/gui/dist/index.html +2 -2
  24. package/node_modules/@groove-dev/gui/package.json +2 -1
  25. package/node_modules/@groove-dev/gui/src/components/agents/agent-file-tree.jsx +254 -0
  26. package/node_modules/@groove-dev/gui/src/components/agents/code-review.jsx +177 -0
  27. package/node_modules/@groove-dev/gui/src/components/agents/diff-viewer.jsx +148 -0
  28. package/node_modules/@groove-dev/gui/src/components/agents/workspace-mode.jsx +377 -0
  29. package/node_modules/@groove-dev/gui/src/components/chat/chat-input.jsx +117 -40
  30. package/node_modules/@groove-dev/gui/src/components/chat/chat-messages.jsx +10 -13
  31. package/node_modules/@groove-dev/gui/src/components/chat/chat-view.jsx +26 -1
  32. package/node_modules/@groove-dev/gui/src/components/chat/conversation-list.jsx +14 -14
  33. package/node_modules/@groove-dev/gui/src/components/chat/model-picker.jsx +5 -0
  34. package/node_modules/@groove-dev/gui/src/components/preview/preview-workspace.jsx +6 -5
  35. package/node_modules/@groove-dev/gui/src/components/preview/screenshot-overlay.jsx +41 -29
  36. package/node_modules/@groove-dev/gui/src/stores/groove.js +138 -3
  37. package/node_modules/@groove-dev/gui/src/views/agents.jsx +36 -3
  38. package/node_modules/@groove-dev/gui/src/views/settings.jsx +104 -26
  39. package/node_modules/base64-arraybuffer/CHANGELOG.md +28 -0
  40. package/node_modules/base64-arraybuffer/LICENSE +22 -0
  41. package/node_modules/base64-arraybuffer/README.md +27 -0
  42. package/node_modules/base64-arraybuffer/dist/base64-arraybuffer.es5.js +50 -0
  43. package/node_modules/base64-arraybuffer/dist/base64-arraybuffer.es5.js.map +1 -0
  44. package/node_modules/base64-arraybuffer/dist/base64-arraybuffer.umd.js +61 -0
  45. package/node_modules/base64-arraybuffer/dist/base64-arraybuffer.umd.js.map +1 -0
  46. package/node_modules/base64-arraybuffer/dist/lib/index.js +48 -0
  47. package/node_modules/base64-arraybuffer/dist/lib/index.js.map +1 -0
  48. package/node_modules/base64-arraybuffer/dist/types/index.d.ts +2 -0
  49. package/node_modules/base64-arraybuffer/package.json +54 -0
  50. package/node_modules/base64-arraybuffer/rollup.config.ts +40 -0
  51. package/node_modules/css-line-break/CHANGELOG.md +58 -0
  52. package/node_modules/css-line-break/LICENSE +22 -0
  53. package/node_modules/css-line-break/README.md +66 -0
  54. package/node_modules/css-line-break/dist/css-line-break.es5.js +706 -0
  55. package/node_modules/css-line-break/dist/css-line-break.es5.js.map +1 -0
  56. package/node_modules/css-line-break/dist/css-line-break.umd.js +718 -0
  57. package/node_modules/css-line-break/dist/css-line-break.umd.js.map +1 -0
  58. package/node_modules/css-line-break/dist/lib/LineBreak.js +516 -0
  59. package/node_modules/css-line-break/dist/lib/LineBreak.js.map +1 -0
  60. package/node_modules/css-line-break/dist/lib/Util.js +109 -0
  61. package/node_modules/css-line-break/dist/lib/Util.js.map +1 -0
  62. package/node_modules/css-line-break/dist/lib/index.js +9 -0
  63. package/node_modules/css-line-break/dist/lib/index.js.map +1 -0
  64. package/node_modules/css-line-break/dist/lib/linebreak-trie.js +6 -0
  65. package/node_modules/css-line-break/dist/lib/linebreak-trie.js.map +1 -0
  66. package/node_modules/css-line-break/dist/types/LineBreak.d.ts +38 -0
  67. package/node_modules/css-line-break/dist/types/Util.d.ts +5 -0
  68. package/node_modules/css-line-break/dist/types/index.d.ts +2 -0
  69. package/node_modules/css-line-break/dist/types/linebreak-trie.d.ts +2 -0
  70. package/node_modules/css-line-break/package.json +61 -0
  71. package/node_modules/css-line-break/rollup.config.ts +40 -0
  72. package/node_modules/html2canvas/CHANGELOG.md +566 -0
  73. package/node_modules/html2canvas/LICENSE +22 -0
  74. package/node_modules/html2canvas/README.md +73 -0
  75. package/node_modules/html2canvas/dist/html2canvas.esm.js +7822 -0
  76. package/node_modules/html2canvas/dist/html2canvas.esm.js.map +1 -0
  77. package/node_modules/html2canvas/dist/html2canvas.js +7830 -0
  78. package/node_modules/html2canvas/dist/html2canvas.js.map +1 -0
  79. package/node_modules/html2canvas/dist/html2canvas.min.js +20 -0
  80. package/node_modules/html2canvas/dist/lib/__tests__/index.js +144 -0
  81. package/node_modules/html2canvas/dist/lib/__tests__/index.js.map +1 -0
  82. package/node_modules/html2canvas/dist/lib/core/__mocks__/cache-storage.js +10 -0
  83. package/node_modules/html2canvas/dist/lib/core/__mocks__/cache-storage.js.map +1 -0
  84. package/node_modules/html2canvas/dist/lib/core/__mocks__/context.js +22 -0
  85. package/node_modules/html2canvas/dist/lib/core/__mocks__/context.js.map +1 -0
  86. package/node_modules/html2canvas/dist/lib/core/__mocks__/features.js +12 -0
  87. package/node_modules/html2canvas/dist/lib/core/__mocks__/features.js.map +1 -0
  88. package/node_modules/html2canvas/dist/lib/core/__mocks__/logger.js +24 -0
  89. package/node_modules/html2canvas/dist/lib/core/__mocks__/logger.js.map +1 -0
  90. package/node_modules/html2canvas/dist/lib/core/__tests__/cache-storage.js +420 -0
  91. package/node_modules/html2canvas/dist/lib/core/__tests__/cache-storage.js.map +1 -0
  92. package/node_modules/html2canvas/dist/lib/core/__tests__/logger.js +28 -0
  93. package/node_modules/html2canvas/dist/lib/core/__tests__/logger.js.map +1 -0
  94. package/node_modules/html2canvas/dist/lib/core/bitwise.js +6 -0
  95. package/node_modules/html2canvas/dist/lib/core/bitwise.js.map +1 -0
  96. package/node_modules/html2canvas/dist/lib/core/cache-storage.js +198 -0
  97. package/node_modules/html2canvas/dist/lib/core/cache-storage.js.map +1 -0
  98. package/node_modules/html2canvas/dist/lib/core/context.js +18 -0
  99. package/node_modules/html2canvas/dist/lib/core/context.js.map +1 -0
  100. package/node_modules/html2canvas/dist/lib/core/debugger.js +25 -0
  101. package/node_modules/html2canvas/dist/lib/core/debugger.js.map +1 -0
  102. package/node_modules/html2canvas/dist/lib/core/features.js +193 -0
  103. package/node_modules/html2canvas/dist/lib/core/features.js.map +1 -0
  104. package/node_modules/html2canvas/dist/lib/core/logger.js +88 -0
  105. package/node_modules/html2canvas/dist/lib/core/logger.js.map +1 -0
  106. package/node_modules/html2canvas/dist/lib/core/util.js +5 -0
  107. package/node_modules/html2canvas/dist/lib/core/util.js.map +1 -0
  108. package/node_modules/html2canvas/dist/lib/css/IPropertyDescriptor.js +3 -0
  109. package/node_modules/html2canvas/dist/lib/css/IPropertyDescriptor.js.map +1 -0
  110. package/node_modules/html2canvas/dist/lib/css/ITypeDescriptor.js +3 -0
  111. package/node_modules/html2canvas/dist/lib/css/ITypeDescriptor.js.map +1 -0
  112. package/node_modules/html2canvas/dist/lib/css/index.js +216 -0
  113. package/node_modules/html2canvas/dist/lib/css/index.js.map +1 -0
  114. package/node_modules/html2canvas/dist/lib/css/layout/__mocks__/bounds.js +9 -0
  115. package/node_modules/html2canvas/dist/lib/css/layout/__mocks__/bounds.js.map +1 -0
  116. package/node_modules/html2canvas/dist/lib/css/layout/bounds.js +42 -0
  117. package/node_modules/html2canvas/dist/lib/css/layout/bounds.js.map +1 -0
  118. package/node_modules/html2canvas/dist/lib/css/layout/text.js +137 -0
  119. package/node_modules/html2canvas/dist/lib/css/layout/text.js.map +1 -0
  120. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/background-tests.js +48 -0
  121. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/background-tests.js.map +1 -0
  122. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/font-family.js +25 -0
  123. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/font-family.js.map +1 -0
  124. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/paint-order.js +88 -0
  125. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/paint-order.js.map +1 -0
  126. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/text-shadow.js +94 -0
  127. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/text-shadow.js.map +1 -0
  128. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/transform-tests.js +18 -0
  129. package/node_modules/html2canvas/dist/lib/css/property-descriptors/__tests__/transform-tests.js.map +1 -0
  130. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-clip.js +24 -0
  131. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-clip.js.map +1 -0
  132. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-color.js +11 -0
  133. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-color.js.map +1 -0
  134. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-image.js +24 -0
  135. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-image.js.map +1 -0
  136. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-origin.js +24 -0
  137. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-origin.js.map +1 -0
  138. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-position.js +17 -0
  139. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-position.js.map +1 -0
  140. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-repeat.js +36 -0
  141. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-repeat.js.map +1 -0
  142. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-size.js +24 -0
  143. package/node_modules/html2canvas/dist/lib/css/property-descriptors/background-size.js.map +1 -0
  144. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-color.js +15 -0
  145. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-color.js.map +1 -0
  146. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-radius.js +18 -0
  147. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-radius.js.map +1 -0
  148. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-style.js +27 -0
  149. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-style.js.map +1 -0
  150. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-width.js +21 -0
  151. package/node_modules/html2canvas/dist/lib/css/property-descriptors/border-width.js.map +1 -0
  152. package/node_modules/html2canvas/dist/lib/css/property-descriptors/box-shadow.js +55 -0
  153. package/node_modules/html2canvas/dist/lib/css/property-descriptors/box-shadow.js.map +1 -0
  154. package/node_modules/html2canvas/dist/lib/css/property-descriptors/color.js +11 -0
  155. package/node_modules/html2canvas/dist/lib/css/property-descriptors/color.js.map +1 -0
  156. package/node_modules/html2canvas/dist/lib/css/property-descriptors/content.js +20 -0
  157. package/node_modules/html2canvas/dist/lib/css/property-descriptors/content.js.map +1 -0
  158. package/node_modules/html2canvas/dist/lib/css/property-descriptors/counter-increment.js +31 -0
  159. package/node_modules/html2canvas/dist/lib/css/property-descriptors/counter-increment.js.map +1 -0
  160. package/node_modules/html2canvas/dist/lib/css/property-descriptors/counter-reset.js +27 -0
  161. package/node_modules/html2canvas/dist/lib/css/property-descriptors/counter-reset.js.map +1 -0
  162. package/node_modules/html2canvas/dist/lib/css/property-descriptors/direction.js +19 -0
  163. package/node_modules/html2canvas/dist/lib/css/property-descriptors/direction.js.map +1 -0
  164. package/node_modules/html2canvas/dist/lib/css/property-descriptors/display.js +82 -0
  165. package/node_modules/html2canvas/dist/lib/css/property-descriptors/display.js.map +1 -0
  166. package/node_modules/html2canvas/dist/lib/css/property-descriptors/duration.js +15 -0
  167. package/node_modules/html2canvas/dist/lib/css/property-descriptors/duration.js.map +1 -0
  168. package/node_modules/html2canvas/dist/lib/css/property-descriptors/float.js +23 -0
  169. package/node_modules/html2canvas/dist/lib/css/property-descriptors/float.js.map +1 -0
  170. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-family.js +33 -0
  171. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-family.js.map +1 -0
  172. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-size.js +11 -0
  173. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-size.js.map +1 -0
  174. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-style.js +21 -0
  175. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-style.js.map +1 -0
  176. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-variant.js +14 -0
  177. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-variant.js.map +1 -0
  178. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-weight.js +26 -0
  179. package/node_modules/html2canvas/dist/lib/css/property-descriptors/font-weight.js.map +1 -0
  180. package/node_modules/html2canvas/dist/lib/css/property-descriptors/letter-spacing.js +22 -0
  181. package/node_modules/html2canvas/dist/lib/css/property-descriptors/letter-spacing.js.map +1 -0
  182. package/node_modules/html2canvas/dist/lib/css/property-descriptors/line-break.js +24 -0
  183. package/node_modules/html2canvas/dist/lib/css/property-descriptors/line-break.js.map +1 -0
  184. package/node_modules/html2canvas/dist/lib/css/property-descriptors/line-height.js +25 -0
  185. package/node_modules/html2canvas/dist/lib/css/property-descriptors/line-height.js.map +1 -0
  186. package/node_modules/html2canvas/dist/lib/css/property-descriptors/list-style-image.js +17 -0
  187. package/node_modules/html2canvas/dist/lib/css/property-descriptors/list-style-image.js.map +1 -0
  188. package/node_modules/html2canvas/dist/lib/css/property-descriptors/list-style-position.js +19 -0
  189. package/node_modules/html2canvas/dist/lib/css/property-descriptors/list-style-position.js.map +1 -0
  190. package/node_modules/html2canvas/dist/lib/css/property-descriptors/list-style-type.js +123 -0
  191. package/node_modules/html2canvas/dist/lib/css/property-descriptors/list-style-type.js.map +1 -0
  192. package/node_modules/html2canvas/dist/lib/css/property-descriptors/margin.js +14 -0
  193. package/node_modules/html2canvas/dist/lib/css/property-descriptors/margin.js.map +1 -0
  194. package/node_modules/html2canvas/dist/lib/css/property-descriptors/opacity.js +17 -0
  195. package/node_modules/html2canvas/dist/lib/css/property-descriptors/opacity.js.map +1 -0
  196. package/node_modules/html2canvas/dist/lib/css/property-descriptors/overflow-wrap.js +19 -0
  197. package/node_modules/html2canvas/dist/lib/css/property-descriptors/overflow-wrap.js.map +1 -0
  198. package/node_modules/html2canvas/dist/lib/css/property-descriptors/overflow.js +28 -0
  199. package/node_modules/html2canvas/dist/lib/css/property-descriptors/overflow.js.map +1 -0
  200. package/node_modules/html2canvas/dist/lib/css/property-descriptors/padding.js +15 -0
  201. package/node_modules/html2canvas/dist/lib/css/property-descriptors/padding.js.map +1 -0
  202. package/node_modules/html2canvas/dist/lib/css/property-descriptors/paint-order.js +34 -0
  203. package/node_modules/html2canvas/dist/lib/css/property-descriptors/paint-order.js.map +1 -0
  204. package/node_modules/html2canvas/dist/lib/css/property-descriptors/position.js +23 -0
  205. package/node_modules/html2canvas/dist/lib/css/property-descriptors/position.js.map +1 -0
  206. package/node_modules/html2canvas/dist/lib/css/property-descriptors/quotes.js +42 -0
  207. package/node_modules/html2canvas/dist/lib/css/property-descriptors/quotes.js.map +1 -0
  208. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-align.js +22 -0
  209. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-align.js.map +1 -0
  210. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-decoration-color.js +11 -0
  211. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-decoration-color.js.map +1 -0
  212. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-decoration-line.js +29 -0
  213. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-decoration-line.js.map +1 -0
  214. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-shadow.js +47 -0
  215. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-shadow.js.map +1 -0
  216. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-transform.js +21 -0
  217. package/node_modules/html2canvas/dist/lib/css/property-descriptors/text-transform.js.map +1 -0
  218. package/node_modules/html2canvas/dist/lib/css/property-descriptors/transform-origin.js +25 -0
  219. package/node_modules/html2canvas/dist/lib/css/property-descriptors/transform-origin.js.map +1 -0
  220. package/node_modules/html2canvas/dist/lib/css/property-descriptors/transform.js +37 -0
  221. package/node_modules/html2canvas/dist/lib/css/property-descriptors/transform.js.map +1 -0
  222. package/node_modules/html2canvas/dist/lib/css/property-descriptors/visibility.js +21 -0
  223. package/node_modules/html2canvas/dist/lib/css/property-descriptors/visibility.js.map +1 -0
  224. package/node_modules/html2canvas/dist/lib/css/property-descriptors/webkit-text-stroke-color.js +11 -0
  225. package/node_modules/html2canvas/dist/lib/css/property-descriptors/webkit-text-stroke-color.js.map +1 -0
  226. package/node_modules/html2canvas/dist/lib/css/property-descriptors/webkit-text-stroke-width.js +17 -0
  227. package/node_modules/html2canvas/dist/lib/css/property-descriptors/webkit-text-stroke-width.js.map +1 -0
  228. package/node_modules/html2canvas/dist/lib/css/property-descriptors/word-break.js +27 -0
  229. package/node_modules/html2canvas/dist/lib/css/property-descriptors/word-break.js.map +1 -0
  230. package/node_modules/html2canvas/dist/lib/css/property-descriptors/z-index.js +20 -0
  231. package/node_modules/html2canvas/dist/lib/css/property-descriptors/z-index.js.map +1 -0
  232. package/node_modules/html2canvas/dist/lib/css/syntax/__tests__/tokernizer-tests.js +34 -0
  233. package/node_modules/html2canvas/dist/lib/css/syntax/__tests__/tokernizer-tests.js.map +1 -0
  234. package/node_modules/html2canvas/dist/lib/css/syntax/parser.js +147 -0
  235. package/node_modules/html2canvas/dist/lib/css/syntax/parser.js.map +1 -0
  236. package/node_modules/html2canvas/dist/lib/css/syntax/tokenizer.js +630 -0
  237. package/node_modules/html2canvas/dist/lib/css/syntax/tokenizer.js.map +1 -0
  238. package/node_modules/html2canvas/dist/lib/css/types/__tests__/color-tests.js +66 -0
  239. package/node_modules/html2canvas/dist/lib/css/types/__tests__/color-tests.js.map +1 -0
  240. package/node_modules/html2canvas/dist/lib/css/types/__tests__/image-tests.js +233 -0
  241. package/node_modules/html2canvas/dist/lib/css/types/__tests__/image-tests.js.map +1 -0
  242. package/node_modules/html2canvas/dist/lib/css/types/angle.js +81 -0
  243. package/node_modules/html2canvas/dist/lib/css/types/angle.js.map +1 -0
  244. package/node_modules/html2canvas/dist/lib/css/types/color.js +288 -0
  245. package/node_modules/html2canvas/dist/lib/css/types/color.js.map +1 -0
  246. package/node_modules/html2canvas/dist/lib/css/types/functions/-prefix-linear-gradient.js +33 -0
  247. package/node_modules/html2canvas/dist/lib/css/types/functions/-prefix-linear-gradient.js.map +1 -0
  248. package/node_modules/html2canvas/dist/lib/css/types/functions/-prefix-radial-gradient.js +84 -0
  249. package/node_modules/html2canvas/dist/lib/css/types/functions/-prefix-radial-gradient.js.map +1 -0
  250. package/node_modules/html2canvas/dist/lib/css/types/functions/-webkit-gradient.js +60 -0
  251. package/node_modules/html2canvas/dist/lib/css/types/functions/-webkit-gradient.js.map +1 -0
  252. package/node_modules/html2canvas/dist/lib/css/types/functions/__tests__/radial-gradient.js +68 -0
  253. package/node_modules/html2canvas/dist/lib/css/types/functions/__tests__/radial-gradient.js.map +1 -0
  254. package/node_modules/html2canvas/dist/lib/css/types/functions/counter.js +374 -0
  255. package/node_modules/html2canvas/dist/lib/css/types/functions/counter.js.map +1 -0
  256. package/node_modules/html2canvas/dist/lib/css/types/functions/gradient.js +165 -0
  257. package/node_modules/html2canvas/dist/lib/css/types/functions/gradient.js.map +1 -0
  258. package/node_modules/html2canvas/dist/lib/css/types/functions/linear-gradient.js +28 -0
  259. package/node_modules/html2canvas/dist/lib/css/types/functions/linear-gradient.js.map +1 -0
  260. package/node_modules/html2canvas/dist/lib/css/types/functions/radial-gradient.js +91 -0
  261. package/node_modules/html2canvas/dist/lib/css/types/functions/radial-gradient.js.map +1 -0
  262. package/node_modules/html2canvas/dist/lib/css/types/image.js +53 -0
  263. package/node_modules/html2canvas/dist/lib/css/types/image.js.map +1 -0
  264. package/node_modules/html2canvas/dist/lib/css/types/index.js +3 -0
  265. package/node_modules/html2canvas/dist/lib/css/types/index.js.map +1 -0
  266. package/node_modules/html2canvas/dist/lib/css/types/length-percentage.js +52 -0
  267. package/node_modules/html2canvas/dist/lib/css/types/length-percentage.js.map +1 -0
  268. package/node_modules/html2canvas/dist/lib/css/types/length.js +8 -0
  269. package/node_modules/html2canvas/dist/lib/css/types/length.js.map +1 -0
  270. package/node_modules/html2canvas/dist/lib/css/types/time.js +18 -0
  271. package/node_modules/html2canvas/dist/lib/css/types/time.js.map +1 -0
  272. package/node_modules/html2canvas/dist/lib/dom/__mocks__/document-cloner.js +24 -0
  273. package/node_modules/html2canvas/dist/lib/dom/__mocks__/document-cloner.js.map +1 -0
  274. package/node_modules/html2canvas/dist/lib/dom/document-cloner.js +530 -0
  275. package/node_modules/html2canvas/dist/lib/dom/document-cloner.js.map +1 -0
  276. package/node_modules/html2canvas/dist/lib/dom/element-container.js +35 -0
  277. package/node_modules/html2canvas/dist/lib/dom/element-container.js.map +1 -0
  278. package/node_modules/html2canvas/dist/lib/dom/elements/li-element-container.js +30 -0
  279. package/node_modules/html2canvas/dist/lib/dom/elements/li-element-container.js.map +1 -0
  280. package/node_modules/html2canvas/dist/lib/dom/elements/ol-element-container.js +31 -0
  281. package/node_modules/html2canvas/dist/lib/dom/elements/ol-element-container.js.map +1 -0
  282. package/node_modules/html2canvas/dist/lib/dom/elements/select-element-container.js +31 -0
  283. package/node_modules/html2canvas/dist/lib/dom/elements/select-element-container.js.map +1 -0
  284. package/node_modules/html2canvas/dist/lib/dom/elements/textarea-element-container.js +30 -0
  285. package/node_modules/html2canvas/dist/lib/dom/elements/textarea-element-container.js.map +1 -0
  286. package/node_modules/html2canvas/dist/lib/dom/node-parser.js +142 -0
  287. package/node_modules/html2canvas/dist/lib/dom/node-parser.js.map +1 -0
  288. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/canvas-element-container.js +32 -0
  289. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/canvas-element-container.js.map +1 -0
  290. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/iframe-element-container.js +55 -0
  291. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/iframe-element-container.js.map +1 -0
  292. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/image-element-container.js +33 -0
  293. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/image-element-container.js.map +1 -0
  294. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/index.js +3 -0
  295. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/index.js.map +1 -0
  296. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/input-element-container.js +102 -0
  297. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/input-element-container.js.map +1 -0
  298. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/pseudo-elements.js +1 -0
  299. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/pseudo-elements.js.map +1 -0
  300. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/svg-element-container.js +38 -0
  301. package/node_modules/html2canvas/dist/lib/dom/replaced-elements/svg-element-container.js.map +1 -0
  302. package/node_modules/html2canvas/dist/lib/dom/text-container.js +32 -0
  303. package/node_modules/html2canvas/dist/lib/dom/text-container.js.map +1 -0
  304. package/node_modules/html2canvas/dist/lib/index.js +181 -0
  305. package/node_modules/html2canvas/dist/lib/index.js.map +1 -0
  306. package/node_modules/html2canvas/dist/lib/invariant.js +10 -0
  307. package/node_modules/html2canvas/dist/lib/invariant.js.map +1 -0
  308. package/node_modules/html2canvas/dist/lib/render/background.js +187 -0
  309. package/node_modules/html2canvas/dist/lib/render/background.js.map +1 -0
  310. package/node_modules/html2canvas/dist/lib/render/bezier-curve.js +36 -0
  311. package/node_modules/html2canvas/dist/lib/render/bezier-curve.js.map +1 -0
  312. package/node_modules/html2canvas/dist/lib/render/border.js +105 -0
  313. package/node_modules/html2canvas/dist/lib/render/border.js.map +1 -0
  314. package/node_modules/html2canvas/dist/lib/render/bound-curves.js +190 -0
  315. package/node_modules/html2canvas/dist/lib/render/bound-curves.js.map +1 -0
  316. package/node_modules/html2canvas/dist/lib/render/box-sizing.js +21 -0
  317. package/node_modules/html2canvas/dist/lib/render/box-sizing.js.map +1 -0
  318. package/node_modules/html2canvas/dist/lib/render/canvas/canvas-renderer.js +1030 -0
  319. package/node_modules/html2canvas/dist/lib/render/canvas/canvas-renderer.js.map +1 -0
  320. package/node_modules/html2canvas/dist/lib/render/canvas/foreignobject-renderer.js +108 -0
  321. package/node_modules/html2canvas/dist/lib/render/canvas/foreignobject-renderer.js.map +1 -0
  322. package/node_modules/html2canvas/dist/lib/render/effects.js +41 -0
  323. package/node_modules/html2canvas/dist/lib/render/effects.js.map +1 -0
  324. package/node_modules/html2canvas/dist/lib/render/font-metrics.js +55 -0
  325. package/node_modules/html2canvas/dist/lib/render/font-metrics.js.map +1 -0
  326. package/node_modules/html2canvas/dist/lib/render/path.js +27 -0
  327. package/node_modules/html2canvas/dist/lib/render/path.js.map +1 -0
  328. package/node_modules/html2canvas/dist/lib/render/renderer.js +12 -0
  329. package/node_modules/html2canvas/dist/lib/render/renderer.js.map +1 -0
  330. package/node_modules/html2canvas/dist/lib/render/stacking-context.js +172 -0
  331. package/node_modules/html2canvas/dist/lib/render/stacking-context.js.map +1 -0
  332. package/node_modules/html2canvas/dist/lib/render/vector.js +18 -0
  333. package/node_modules/html2canvas/dist/lib/render/vector.js.map +1 -0
  334. package/node_modules/html2canvas/dist/types/__tests__/index.d.ts +1 -0
  335. package/node_modules/html2canvas/dist/types/core/__mocks__/cache-storage.d.ts +2 -0
  336. package/node_modules/html2canvas/dist/types/core/__mocks__/context.d.ts +9 -0
  337. package/node_modules/html2canvas/dist/types/core/__mocks__/features.d.ts +8 -0
  338. package/node_modules/html2canvas/dist/types/core/__mocks__/logger.d.ts +9 -0
  339. package/node_modules/html2canvas/dist/types/core/__tests__/cache-storage.d.ts +1 -0
  340. package/node_modules/html2canvas/dist/types/core/__tests__/logger.d.ts +1 -0
  341. package/node_modules/html2canvas/dist/types/core/bitwise.d.ts +1 -0
  342. package/node_modules/html2canvas/dist/types/core/cache-storage.d.ts +26 -0
  343. package/node_modules/html2canvas/dist/types/core/context.d.ts +15 -0
  344. package/node_modules/html2canvas/dist/types/core/debugger.d.ts +8 -0
  345. package/node_modules/html2canvas/dist/types/core/features.d.ts +12 -0
  346. package/node_modules/html2canvas/dist/types/core/logger.d.ts +18 -0
  347. package/node_modules/html2canvas/dist/types/core/util.d.ts +1 -0
  348. package/node_modules/html2canvas/dist/types/css/IPropertyDescriptor.d.ts +36 -0
  349. package/node_modules/html2canvas/dist/types/css/ITypeDescriptor.d.ts +6 -0
  350. package/node_modules/html2canvas/dist/types/css/index.d.ts +132 -0
  351. package/node_modules/html2canvas/dist/types/css/layout/__mocks__/bounds.d.ts +2 -0
  352. package/node_modules/html2canvas/dist/types/css/layout/bounds.d.ts +14 -0
  353. package/node_modules/html2canvas/dist/types/css/layout/text.d.ts +10 -0
  354. package/node_modules/html2canvas/dist/types/css/property-descriptors/__tests__/background-tests.d.ts +1 -0
  355. package/node_modules/html2canvas/dist/types/css/property-descriptors/__tests__/font-family.d.ts +1 -0
  356. package/node_modules/html2canvas/dist/types/css/property-descriptors/__tests__/paint-order.d.ts +1 -0
  357. package/node_modules/html2canvas/dist/types/css/property-descriptors/__tests__/text-shadow.d.ts +1 -0
  358. package/node_modules/html2canvas/dist/types/css/property-descriptors/__tests__/transform-tests.d.ts +1 -0
  359. package/node_modules/html2canvas/dist/types/css/property-descriptors/background-clip.d.ts +8 -0
  360. package/node_modules/html2canvas/dist/types/css/property-descriptors/background-color.d.ts +2 -0
  361. package/node_modules/html2canvas/dist/types/css/property-descriptors/background-image.d.ts +3 -0
  362. package/node_modules/html2canvas/dist/types/css/property-descriptors/background-origin.d.ts +8 -0
  363. package/node_modules/html2canvas/dist/types/css/property-descriptors/background-position.d.ts +5 -0
  364. package/node_modules/html2canvas/dist/types/css/property-descriptors/background-repeat.d.ts +9 -0
  365. package/node_modules/html2canvas/dist/types/css/property-descriptors/background-size.d.ts +11 -0
  366. package/node_modules/html2canvas/dist/types/css/property-descriptors/border-color.d.ts +5 -0
  367. package/node_modules/html2canvas/dist/types/css/property-descriptors/border-radius.d.ts +7 -0
  368. package/node_modules/html2canvas/dist/types/css/property-descriptors/border-style.d.ts +12 -0
  369. package/node_modules/html2canvas/dist/types/css/property-descriptors/border-width.d.ts +5 -0
  370. package/node_modules/html2canvas/dist/types/css/property-descriptors/box-shadow.d.ts +14 -0
  371. package/node_modules/html2canvas/dist/types/css/property-descriptors/color.d.ts +2 -0
  372. package/node_modules/html2canvas/dist/types/css/property-descriptors/content.d.ts +4 -0
  373. package/node_modules/html2canvas/dist/types/css/property-descriptors/counter-increment.d.ts +7 -0
  374. package/node_modules/html2canvas/dist/types/css/property-descriptors/counter-reset.d.ts +7 -0
  375. package/node_modules/html2canvas/dist/types/css/property-descriptors/direction.d.ts +6 -0
  376. package/node_modules/html2canvas/dist/types/css/property-descriptors/display.d.ts +35 -0
  377. package/node_modules/html2canvas/dist/types/css/property-descriptors/duration.d.ts +2 -0
  378. package/node_modules/html2canvas/dist/types/css/property-descriptors/float.d.ts +9 -0
  379. package/node_modules/html2canvas/dist/types/css/property-descriptors/font-family.d.ts +4 -0
  380. package/node_modules/html2canvas/dist/types/css/property-descriptors/font-size.d.ts +2 -0
  381. package/node_modules/html2canvas/dist/types/css/property-descriptors/font-style.d.ts +7 -0
  382. package/node_modules/html2canvas/dist/types/css/property-descriptors/font-variant.d.ts +2 -0
  383. package/node_modules/html2canvas/dist/types/css/property-descriptors/font-weight.d.ts +2 -0
  384. package/node_modules/html2canvas/dist/types/css/property-descriptors/letter-spacing.d.ts +2 -0
  385. package/node_modules/html2canvas/dist/types/css/property-descriptors/line-break.d.ts +6 -0
  386. package/node_modules/html2canvas/dist/types/css/property-descriptors/line-height.d.ts +4 -0
  387. package/node_modules/html2canvas/dist/types/css/property-descriptors/list-style-image.d.ts +3 -0
  388. package/node_modules/html2canvas/dist/types/css/property-descriptors/list-style-position.d.ts +6 -0
  389. package/node_modules/html2canvas/dist/types/css/property-descriptors/list-style-type.d.ts +58 -0
  390. package/node_modules/html2canvas/dist/types/css/property-descriptors/margin.d.ts +5 -0
  391. package/node_modules/html2canvas/dist/types/css/property-descriptors/opacity.d.ts +2 -0
  392. package/node_modules/html2canvas/dist/types/css/property-descriptors/overflow-wrap.d.ts +6 -0
  393. package/node_modules/html2canvas/dist/types/css/property-descriptors/overflow.d.ts +9 -0
  394. package/node_modules/html2canvas/dist/types/css/property-descriptors/padding.d.ts +5 -0
  395. package/node_modules/html2canvas/dist/types/css/property-descriptors/paint-order.d.ts +8 -0
  396. package/node_modules/html2canvas/dist/types/css/property-descriptors/position.d.ts +9 -0
  397. package/node_modules/html2canvas/dist/types/css/property-descriptors/quotes.d.ts +8 -0
  398. package/node_modules/html2canvas/dist/types/css/property-descriptors/text-align.d.ts +7 -0
  399. package/node_modules/html2canvas/dist/types/css/property-descriptors/text-decoration-color.d.ts +2 -0
  400. package/node_modules/html2canvas/dist/types/css/property-descriptors/text-decoration-line.d.ts +10 -0
  401. package/node_modules/html2canvas/dist/types/css/property-descriptors/text-shadow.d.ts +12 -0
  402. package/node_modules/html2canvas/dist/types/css/property-descriptors/text-transform.d.ts +8 -0
  403. package/node_modules/html2canvas/dist/types/css/property-descriptors/transform-origin.d.ts +4 -0
  404. package/node_modules/html2canvas/dist/types/css/property-descriptors/transform.d.ts +4 -0
  405. package/node_modules/html2canvas/dist/types/css/property-descriptors/visibility.d.ts +7 -0
  406. package/node_modules/html2canvas/dist/types/css/property-descriptors/webkit-text-stroke-color.d.ts +2 -0
  407. package/node_modules/html2canvas/dist/types/css/property-descriptors/webkit-text-stroke-width.d.ts +2 -0
  408. package/node_modules/html2canvas/dist/types/css/property-descriptors/word-break.d.ts +7 -0
  409. package/node_modules/html2canvas/dist/types/css/property-descriptors/z-index.d.ts +7 -0
  410. package/node_modules/html2canvas/dist/types/css/syntax/__tests__/tokernizer-tests.d.ts +1 -0
  411. package/node_modules/html2canvas/dist/types/css/syntax/parser.d.ts +34 -0
  412. package/node_modules/html2canvas/dist/types/css/syntax/tokenizer.d.ts +94 -0
  413. package/node_modules/html2canvas/dist/types/css/types/__tests__/color-tests.d.ts +1 -0
  414. package/node_modules/html2canvas/dist/types/css/types/__tests__/image-tests.d.ts +1 -0
  415. package/node_modules/html2canvas/dist/types/css/types/angle.d.ts +7 -0
  416. package/node_modules/html2canvas/dist/types/css/types/color.d.ts +11 -0
  417. package/node_modules/html2canvas/dist/types/css/types/functions/-prefix-linear-gradient.d.ts +4 -0
  418. package/node_modules/html2canvas/dist/types/css/types/functions/-prefix-radial-gradient.d.ts +4 -0
  419. package/node_modules/html2canvas/dist/types/css/types/functions/-webkit-gradient.d.ts +4 -0
  420. package/node_modules/html2canvas/dist/types/css/types/functions/__tests__/radial-gradient.d.ts +1 -0
  421. package/node_modules/html2canvas/dist/types/css/types/functions/counter.d.ts +10 -0
  422. package/node_modules/html2canvas/dist/types/css/types/functions/gradient.d.ts +7 -0
  423. package/node_modules/html2canvas/dist/types/css/types/functions/linear-gradient.d.ts +4 -0
  424. package/node_modules/html2canvas/dist/types/css/types/functions/radial-gradient.d.ts +12 -0
  425. package/node_modules/html2canvas/dist/types/css/types/image.d.ts +54 -0
  426. package/node_modules/html2canvas/dist/types/css/types/index.d.ts +1 -0
  427. package/node_modules/html2canvas/dist/types/css/types/length-percentage.d.ts +11 -0
  428. package/node_modules/html2canvas/dist/types/css/types/length.d.ts +4 -0
  429. package/node_modules/html2canvas/dist/types/css/types/time.d.ts +2 -0
  430. package/node_modules/html2canvas/dist/types/dom/__mocks__/document-cloner.d.ts +6 -0
  431. package/node_modules/html2canvas/dist/types/dom/document-cloner.d.ts +45 -0
  432. package/node_modules/html2canvas/dist/types/dom/element-container.d.ts +19 -0
  433. package/node_modules/html2canvas/dist/types/dom/elements/li-element-container.d.ts +6 -0
  434. package/node_modules/html2canvas/dist/types/dom/elements/ol-element-container.d.ts +7 -0
  435. package/node_modules/html2canvas/dist/types/dom/elements/select-element-container.d.ts +6 -0
  436. package/node_modules/html2canvas/dist/types/dom/elements/textarea-element-container.d.ts +6 -0
  437. package/node_modules/html2canvas/dist/types/dom/node-parser.d.ts +23 -0
  438. package/node_modules/html2canvas/dist/types/dom/replaced-elements/canvas-element-container.d.ts +8 -0
  439. package/node_modules/html2canvas/dist/types/dom/replaced-elements/iframe-element-container.d.ts +11 -0
  440. package/node_modules/html2canvas/dist/types/dom/replaced-elements/image-element-container.d.ts +8 -0
  441. package/node_modules/html2canvas/dist/types/dom/replaced-elements/index.d.ts +4 -0
  442. package/node_modules/html2canvas/dist/types/dom/replaced-elements/input-element-container.d.ts +12 -0
  443. package/node_modules/html2canvas/dist/types/dom/replaced-elements/pseudo-elements.d.ts +0 -0
  444. package/node_modules/html2canvas/dist/types/dom/replaced-elements/svg-element-container.d.ts +8 -0
  445. package/node_modules/html2canvas/dist/types/dom/text-container.d.ts +8 -0
  446. package/node_modules/html2canvas/dist/types/index.d.ts +10 -0
  447. package/node_modules/html2canvas/dist/types/invariant.d.ts +1 -0
  448. package/node_modules/html2canvas/dist/types/render/background.d.ts +16 -0
  449. package/node_modules/html2canvas/dist/types/render/bezier-curve.d.ts +14 -0
  450. package/node_modules/html2canvas/dist/types/render/border.d.ts +6 -0
  451. package/node_modules/html2canvas/dist/types/render/bound-curves.d.ts +32 -0
  452. package/node_modules/html2canvas/dist/types/render/box-sizing.d.ts +4 -0
  453. package/node_modules/html2canvas/dist/types/render/canvas/canvas-renderer.d.ts +53 -0
  454. package/node_modules/html2canvas/dist/types/render/canvas/foreignobject-renderer.d.ts +11 -0
  455. package/node_modules/html2canvas/dist/types/render/effects.d.ts +38 -0
  456. package/node_modules/html2canvas/dist/types/render/font-metrics.d.ts +11 -0
  457. package/node_modules/html2canvas/dist/types/render/path.d.ts +13 -0
  458. package/node_modules/html2canvas/dist/types/render/renderer.d.ts +7 -0
  459. package/node_modules/html2canvas/dist/types/render/stacking-context.d.ts +24 -0
  460. package/node_modules/html2canvas/dist/types/render/vector.d.ts +9 -0
  461. package/node_modules/html2canvas/package.json +124 -0
  462. package/node_modules/html2canvas/tsconfig.json +21 -0
  463. package/node_modules/text-segmentation/CHANGELOG.md +43 -0
  464. package/node_modules/text-segmentation/LICENSE +22 -0
  465. package/node_modules/text-segmentation/README.md +27 -0
  466. package/node_modules/text-segmentation/dist/lib/GraphemeBreak.js +218 -0
  467. package/node_modules/text-segmentation/dist/lib/GraphemeBreak.js.map +1 -0
  468. package/node_modules/text-segmentation/dist/lib/grapheme-break-trie.js +6 -0
  469. package/node_modules/text-segmentation/dist/lib/grapheme-break-trie.js.map +1 -0
  470. package/node_modules/text-segmentation/dist/lib/index.js +9 -0
  471. package/node_modules/text-segmentation/dist/lib/index.js.map +1 -0
  472. package/node_modules/text-segmentation/dist/text-segmentation.es5.js +384 -0
  473. package/node_modules/text-segmentation/dist/text-segmentation.es5.js.map +1 -0
  474. package/node_modules/text-segmentation/dist/text-segmentation.umd.js +397 -0
  475. package/node_modules/text-segmentation/dist/text-segmentation.umd.js.map +1 -0
  476. package/node_modules/text-segmentation/dist/types/GraphemeBreak.d.ts +21 -0
  477. package/node_modules/text-segmentation/dist/types/grapheme-break-trie.d.ts +2 -0
  478. package/node_modules/text-segmentation/dist/types/index.d.ts +1 -0
  479. package/node_modules/text-segmentation/package.json +55 -0
  480. package/node_modules/text-segmentation/rollup.config.ts +40 -0
  481. package/node_modules/utrie/CHANGELOG.md +32 -0
  482. package/node_modules/utrie/LICENSE +22 -0
  483. package/node_modules/utrie/dist/lib/Trie.js +143 -0
  484. package/node_modules/utrie/dist/lib/Trie.js.map +1 -0
  485. package/node_modules/utrie/dist/lib/TrieBuilder.js +888 -0
  486. package/node_modules/utrie/dist/lib/TrieBuilder.js.map +1 -0
  487. package/node_modules/utrie/dist/lib/Util.js +54 -0
  488. package/node_modules/utrie/dist/lib/Util.js.map +1 -0
  489. package/node_modules/utrie/dist/lib/index.js +10 -0
  490. package/node_modules/utrie/dist/lib/index.js.map +1 -0
  491. package/node_modules/utrie/dist/types/Trie.d.ts +76 -0
  492. package/node_modules/utrie/dist/types/TrieBuilder.d.ts +65 -0
  493. package/node_modules/utrie/dist/types/Util.d.ts +3 -0
  494. package/node_modules/utrie/dist/types/index.d.ts +2 -0
  495. package/node_modules/utrie/dist/utrie.es5.js +1101 -0
  496. package/node_modules/utrie/dist/utrie.es5.js.map +1 -0
  497. package/node_modules/utrie/dist/utrie.umd.js +1114 -0
  498. package/node_modules/utrie/dist/utrie.umd.js.map +1 -0
  499. package/node_modules/utrie/package.json +53 -0
  500. package/node_modules/utrie/rollup.config.ts +40 -0
  501. package/package.json +1 -1
  502. package/packages/cli/bin/groove.js +10 -1
  503. package/packages/cli/package.json +1 -1
  504. package/packages/cli/src/commands/connect.js +116 -205
  505. package/packages/cli/src/commands/disconnect.js +38 -62
  506. package/packages/cli/src/commands/remotes.js +75 -0
  507. package/packages/daemon/package.json +1 -1
  508. package/packages/daemon/src/api.js +115 -7
  509. package/packages/daemon/src/conversations.js +29 -3
  510. package/packages/daemon/src/process.js +56 -1
  511. package/packages/daemon/src/providers/codex.js +28 -10
  512. package/packages/daemon/src/registry.js +30 -0
  513. package/packages/daemon/src/validate.js +23 -0
  514. package/packages/gui/dist/assets/index-BSqk8cbI.css +1 -0
  515. package/packages/gui/dist/assets/index-B_igwWvq.js +8642 -0
  516. package/packages/gui/dist/index.html +2 -2
  517. package/packages/gui/package.json +2 -1
  518. package/packages/gui/src/components/agents/agent-file-tree.jsx +254 -0
  519. package/packages/gui/src/components/agents/code-review.jsx +177 -0
  520. package/packages/gui/src/components/agents/diff-viewer.jsx +148 -0
  521. package/packages/gui/src/components/agents/workspace-mode.jsx +377 -0
  522. package/packages/gui/src/components/chat/chat-input.jsx +117 -40
  523. package/packages/gui/src/components/chat/chat-messages.jsx +10 -13
  524. package/packages/gui/src/components/chat/chat-view.jsx +26 -1
  525. package/packages/gui/src/components/chat/conversation-list.jsx +14 -14
  526. package/packages/gui/src/components/chat/model-picker.jsx +5 -0
  527. package/packages/gui/src/components/preview/preview-workspace.jsx +6 -5
  528. package/packages/gui/src/components/preview/screenshot-overlay.jsx +41 -29
  529. package/packages/gui/src/stores/groove.js +138 -3
  530. package/packages/gui/src/views/agents.jsx +36 -3
  531. package/packages/gui/src/views/settings.jsx +104 -26
  532. package/test/doomsday-clock/index.html +55 -0
  533. package/test/doomsday-clock/script.js +66 -0
  534. package/test/doomsday-clock/style.css +315 -0
  535. package/node_modules/@groove-dev/gui/dist/assets/index-BbDDgazC.js +0 -8616
  536. package/node_modules/@groove-dev/gui/dist/assets/index-fhMxiPGp.css +0 -1
  537. package/packages/gui/dist/assets/index-BbDDgazC.js +0 -8616
  538. package/packages/gui/dist/assets/index-fhMxiPGp.css +0 -1
@@ -6,12 +6,12 @@
6
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
7
  <link rel="icon" type="image/png" href="/favicon.png" />
8
8
  <title>Groove GUI</title>
9
- <script type="module" crossorigin src="/assets/index-BbDDgazC.js"></script>
9
+ <script type="module" crossorigin src="/assets/index-B_igwWvq.js"></script>
10
10
  <link rel="modulepreload" crossorigin href="/assets/vendor-C0HXlhrU.js">
11
11
  <link rel="modulepreload" crossorigin href="/assets/reactflow-BQPfi37R.js">
12
12
  <link rel="modulepreload" crossorigin href="/assets/codemirror-BBL3i_JW.js">
13
13
  <link rel="modulepreload" crossorigin href="/assets/xterm--7_ns2zW.js">
14
- <link rel="stylesheet" crossorigin href="/assets/index-fhMxiPGp.css">
14
+ <link rel="stylesheet" crossorigin href="/assets/index-BSqk8cbI.css">
15
15
  </head>
16
16
  <body>
17
17
  <div id="root"></div>
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@groove-dev/gui",
3
- "version": "0.27.86",
3
+ "version": "0.27.88",
4
4
  "description": "GROOVE GUI — visual agent control plane",
5
5
  "license": "FSL-1.1-Apache-2.0",
6
6
  "type": "module",
@@ -38,6 +38,7 @@
38
38
  "@xyflow/react": "^12.0.0",
39
39
  "clsx": "^2.1.1",
40
40
  "framer-motion": "^12.38.0",
41
+ "html2canvas": "^1.4.1",
41
42
  "lucide-react": "^1.7.0",
42
43
  "react": "^19.0.0",
43
44
  "react-dom": "^19.0.0",
@@ -0,0 +1,254 @@
1
+ // FSL-1.1-Apache-2.0 — see LICENSE
2
+ import { useState, useEffect, useRef, useCallback } from 'react';
3
+ import { useGrooveStore } from '../../stores/groove';
4
+ import { cn } from '../../lib/cn';
5
+ import { api } from '../../lib/api';
6
+ import { ChevronRight, ChevronDown, File, Folder, FolderOpen, Clock } from 'lucide-react';
7
+ import { ScrollArea } from '../ui/scroll-area';
8
+
9
+ const FILE_COLORS = {
10
+ js: 'text-warning', jsx: 'text-warning', ts: 'text-info', tsx: 'text-info',
11
+ css: 'text-info', html: 'text-orange', json: 'text-warning',
12
+ md: 'text-text-2', py: 'text-success', rs: 'text-orange',
13
+ go: 'text-accent', sh: 'text-success', yaml: 'text-danger', yml: 'text-danger',
14
+ sql: 'text-purple', xml: 'text-orange', svg: 'text-warning',
15
+ };
16
+
17
+ function getFileColor(name) {
18
+ const ext = name.split('.').pop()?.toLowerCase();
19
+ return FILE_COLORS[ext] || 'text-text-3';
20
+ }
21
+
22
+ function matchesScope(filePath, scopePatterns) {
23
+ if (!scopePatterns || scopePatterns.length === 0) return true;
24
+ for (const pattern of scopePatterns) {
25
+ const escaped = pattern
26
+ .replace(/[.+^${}()|[\]\\]/g, '\\$&')
27
+ .replace(/\*\*/g, '<<GLOBSTAR>>')
28
+ .replace(/\*/g, '[^/]*')
29
+ .replace(/<<GLOBSTAR>>/g, '.*');
30
+ if (new RegExp(`^${escaped}$`).test(filePath) || new RegExp(`^${escaped}`).test(filePath)) {
31
+ return true;
32
+ }
33
+ }
34
+ return false;
35
+ }
36
+
37
+ function TreeEntry({ entry, depth, onOpen, expandedDirs, onToggleDir }) {
38
+ const isDir = entry.type === 'directory';
39
+ const isExpanded = expandedDirs.has(entry.path);
40
+ const fileColor = isDir ? 'text-accent' : getFileColor(entry.name);
41
+
42
+ return (
43
+ <>
44
+ <button
45
+ onClick={() => isDir ? onToggleDir(entry.path) : onOpen(entry.path)}
46
+ className={cn(
47
+ 'w-full flex items-center gap-1.5 py-1 text-xs font-sans cursor-pointer',
48
+ 'hover:bg-surface-4/50 transition-colors text-left',
49
+ )}
50
+ style={{ paddingLeft: depth * 14 + 8 }}
51
+ >
52
+ {isDir ? (
53
+ <>
54
+ {isExpanded ? <ChevronDown size={12} className="text-text-4 flex-shrink-0" /> : <ChevronRight size={12} className="text-text-4 flex-shrink-0" />}
55
+ {isExpanded ? <FolderOpen size={13} className={cn(fileColor, 'flex-shrink-0')} /> : <Folder size={13} className={cn(fileColor, 'flex-shrink-0')} />}
56
+ </>
57
+ ) : (
58
+ <>
59
+ <span className="w-3 flex-shrink-0" />
60
+ <File size={13} className={cn(fileColor, 'flex-shrink-0')} />
61
+ </>
62
+ )}
63
+ <span className="truncate text-text-1">{entry.name}</span>
64
+ </button>
65
+ {isDir && isExpanded && entry.children?.map((child) => (
66
+ <TreeEntry
67
+ key={child.path}
68
+ entry={child}
69
+ depth={depth + 1}
70
+ onOpen={onOpen}
71
+ expandedDirs={expandedDirs}
72
+ onToggleDir={onToggleDir}
73
+ />
74
+ ))}
75
+ </>
76
+ );
77
+ }
78
+
79
+ export function AgentFileTree({ agentId }) {
80
+ const agents = useGrooveStore((s) => s.agents);
81
+ const activityLog = useGrooveStore((s) => s.activityLog);
82
+ const openFile = useGrooveStore((s) => s.openFile);
83
+ const editorActiveFile = useGrooveStore((s) => s.editorActiveFile);
84
+
85
+ const agent = agents.find((a) => a.id === agentId);
86
+ const scope = agent?.scope || [];
87
+ const log = activityLog[agentId] || [];
88
+
89
+ const [treeData, setTreeData] = useState([]);
90
+ const [expandedDirs, setExpandedDirs] = useState(new Set());
91
+ const [loading, setLoading] = useState(true);
92
+ const fetchedRef = useRef(new Set());
93
+
94
+ const recentFiles = (() => {
95
+ const seen = new Set();
96
+ const files = [];
97
+ for (let i = log.length - 1; i >= 0; i--) {
98
+ const t = (log[i].text || '').toLowerCase();
99
+ if (!(t.includes('writ') || t.includes('edit') || t.includes('creat') || t.includes('read'))) continue;
100
+ const match = log[i].text.match(/(?:Write|Edit|Create|Read|wrote|editing|writing|reading)\S*\s+(\S+)/i);
101
+ if (!match) continue;
102
+ const path = match[1];
103
+ if (seen.has(path) || path.startsWith('.') || path.includes('node_modules')) continue;
104
+ seen.add(path);
105
+ files.push(path);
106
+ if (files.length >= 10) break;
107
+ }
108
+ return files;
109
+ })();
110
+
111
+ const fetchDir = useCallback(async (dirPath) => {
112
+ if (fetchedRef.current.has(dirPath)) return;
113
+ fetchedRef.current.add(dirPath);
114
+ try {
115
+ const data = await api.get(`/files/tree?path=${encodeURIComponent(dirPath)}`);
116
+ return data.entries || [];
117
+ } catch {
118
+ return [];
119
+ }
120
+ }, []);
121
+
122
+ useEffect(() => {
123
+ let cancelled = false;
124
+ async function loadTree() {
125
+ setLoading(true);
126
+ fetchedRef.current = new Set();
127
+
128
+ if (scope.length === 0) {
129
+ const entries = await fetchDir('');
130
+ if (!cancelled) setTreeData(entries);
131
+ setLoading(false);
132
+ return;
133
+ }
134
+
135
+ const dirs = new Set();
136
+ for (const pattern of scope) {
137
+ const parts = pattern.split('/');
138
+ let dir = '';
139
+ for (let i = 0; i < parts.length; i++) {
140
+ if (parts[i].includes('*')) break;
141
+ dir = dir ? `${dir}/${parts[i]}` : parts[i];
142
+ }
143
+ if (dir) dirs.add(dir);
144
+ }
145
+
146
+ if (dirs.size === 0) {
147
+ const entries = await fetchDir('');
148
+ if (!cancelled) setTreeData(entries);
149
+ setLoading(false);
150
+ return;
151
+ }
152
+
153
+ const results = [];
154
+ for (const dir of dirs) {
155
+ const entries = await fetchDir(dir);
156
+ if (entries.length > 0) {
157
+ results.push({ name: dir.split('/').pop(), path: dir, type: 'directory', children: entries });
158
+ }
159
+ }
160
+ if (!cancelled) setTreeData(results);
161
+ setLoading(false);
162
+ }
163
+ loadTree();
164
+ return () => { cancelled = true; };
165
+ }, [agentId, scope.join(','), fetchDir]);
166
+
167
+ async function handleToggleDir(path) {
168
+ const next = new Set(expandedDirs);
169
+ if (next.has(path)) {
170
+ next.delete(path);
171
+ } else {
172
+ next.add(path);
173
+ const entries = await fetchDir(path);
174
+ setTreeData((prev) => updateTreeChildren(prev, path, entries));
175
+ }
176
+ setExpandedDirs(next);
177
+ }
178
+
179
+ function handleOpen(path) {
180
+ openFile(path);
181
+ }
182
+
183
+ return (
184
+ <ScrollArea className="h-full">
185
+ <div className="py-2">
186
+ {recentFiles.length > 0 && (
187
+ <div className="mb-3">
188
+ <div className="flex items-center gap-1.5 px-3 py-1.5 text-2xs font-semibold text-text-3 uppercase tracking-wider">
189
+ <Clock size={10} />
190
+ Recently Touched
191
+ </div>
192
+ {recentFiles.map((path) => {
193
+ const name = path.split('/').pop();
194
+ return (
195
+ <button
196
+ key={path}
197
+ onClick={() => openFile(path)}
198
+ className={cn(
199
+ 'w-full flex items-center gap-1.5 px-3 py-1 text-xs font-sans cursor-pointer',
200
+ 'hover:bg-surface-4/50 transition-colors text-left',
201
+ editorActiveFile === path && 'bg-accent/8 text-accent',
202
+ )}
203
+ >
204
+ <File size={12} className={cn(getFileColor(name), 'flex-shrink-0')} />
205
+ <span className="truncate text-text-1">{name}</span>
206
+ </button>
207
+ );
208
+ })}
209
+ <div className="h-px bg-border-subtle mx-3 mt-2" />
210
+ </div>
211
+ )}
212
+
213
+ {loading ? (
214
+ <div className="flex items-center justify-center py-8 text-text-4 text-xs font-sans">
215
+ Loading...
216
+ </div>
217
+ ) : treeData.length === 0 ? (
218
+ <div className="flex items-center justify-center py-8 text-text-4 text-xs font-sans">
219
+ No files in scope
220
+ </div>
221
+ ) : (
222
+ <div className="px-1">
223
+ <div className="flex items-center gap-1.5 px-2 py-1.5 text-2xs font-semibold text-text-3 uppercase tracking-wider">
224
+ <Folder size={10} />
225
+ Scope
226
+ </div>
227
+ {treeData.map((entry) => (
228
+ <TreeEntry
229
+ key={entry.path}
230
+ entry={entry}
231
+ depth={0}
232
+ onOpen={handleOpen}
233
+ expandedDirs={expandedDirs}
234
+ onToggleDir={handleToggleDir}
235
+ />
236
+ ))}
237
+ </div>
238
+ )}
239
+ </div>
240
+ </ScrollArea>
241
+ );
242
+ }
243
+
244
+ function updateTreeChildren(tree, targetPath, children) {
245
+ return tree.map((entry) => {
246
+ if (entry.path === targetPath) {
247
+ return { ...entry, children };
248
+ }
249
+ if (entry.children) {
250
+ return { ...entry, children: updateTreeChildren(entry.children, targetPath, children) };
251
+ }
252
+ return entry;
253
+ });
254
+ }
@@ -0,0 +1,177 @@
1
+ // FSL-1.1-Apache-2.0 — see LICENSE
2
+ import { useState } from 'react';
3
+ import { useGrooveStore } from '../../stores/groove';
4
+ import { cn } from '../../lib/cn';
5
+ import { ScrollArea } from '../ui/scroll-area';
6
+ import { Button } from '../ui/button';
7
+ import { DiffViewer } from './diff-viewer';
8
+ import { Check, X, MessageSquare, ChevronLeft, CheckCircle2, XCircle, Send } from 'lucide-react';
9
+
10
+ export function CodeReview({ agentId }) {
11
+ const reviewFiles = useGrooveStore((s) => s.workspaceReviewFiles);
12
+ const approveFile = useGrooveStore((s) => s.approveFile);
13
+ const rejectFile = useGrooveStore((s) => s.rejectFile);
14
+ const commentFile = useGrooveStore((s) => s.commentFile);
15
+ const instructAgent = useGrooveStore((s) => s.instructAgent);
16
+ const toggleReviewMode = useGrooveStore((s) => s.toggleReviewMode);
17
+ const openFile = useGrooveStore((s) => s.openFile);
18
+
19
+ const [selectedFile, setSelectedFile] = useState(null);
20
+ const [commentingPath, setCommentingPath] = useState(null);
21
+ const [commentText, setCommentText] = useState('');
22
+
23
+ const approved = reviewFiles.filter((f) => f.status === 'approved').length;
24
+ const rejected = reviewFiles.filter((f) => f.status === 'rejected').length;
25
+
26
+ function handleComment(path) {
27
+ if (!commentText.trim()) return;
28
+ commentFile(path, commentText.trim());
29
+ setCommentText('');
30
+ setCommentingPath(null);
31
+ }
32
+
33
+ function handleApproveAll() {
34
+ for (const f of reviewFiles) {
35
+ approveFile(f.path);
36
+ }
37
+ }
38
+
39
+ async function handleRequestChanges() {
40
+ const comments = reviewFiles
41
+ .filter((f) => f.comment || f.status === 'rejected')
42
+ .map((f) => {
43
+ const status = f.status === 'rejected' ? '[REJECTED]' : '[COMMENT]';
44
+ return `${status} ${f.path}: ${f.comment || 'Changes needed'}`;
45
+ });
46
+ if (comments.length > 0) {
47
+ await instructAgent(agentId, `Code review feedback:\n${comments.join('\n')}`);
48
+ }
49
+ toggleReviewMode();
50
+ }
51
+
52
+ if (selectedFile) {
53
+ return (
54
+ <div className="flex flex-col h-full">
55
+ <div className="flex items-center gap-2 px-4 py-2 bg-surface-1 border-b border-border flex-shrink-0">
56
+ <button
57
+ onClick={() => setSelectedFile(null)}
58
+ className="p-1 rounded hover:bg-surface-4 text-text-3 hover:text-text-1 cursor-pointer"
59
+ >
60
+ <ChevronLeft size={14} />
61
+ </button>
62
+ <span className="text-xs font-mono text-text-1 truncate">{selectedFile}</span>
63
+ </div>
64
+ <div className="flex-1 min-h-0">
65
+ <DiffViewer filePath={selectedFile} />
66
+ </div>
67
+ </div>
68
+ );
69
+ }
70
+
71
+ return (
72
+ <div className="flex flex-col h-full">
73
+ <div className="flex items-center gap-3 px-4 py-3 bg-surface-1 border-b border-border flex-shrink-0">
74
+ <span className="text-sm font-semibold text-text-0 font-sans flex-1">Review Changes</span>
75
+ <span className="text-xs text-text-3 font-sans">
76
+ {reviewFiles.length} file{reviewFiles.length !== 1 ? 's' : ''} changed
77
+ </span>
78
+ {approved > 0 && <span className="text-xs text-success font-sans">{approved} approved</span>}
79
+ {rejected > 0 && <span className="text-xs text-danger font-sans">{rejected} rejected</span>}
80
+ </div>
81
+
82
+ <ScrollArea className="flex-1">
83
+ <div className="p-2 space-y-1">
84
+ {reviewFiles.length === 0 && (
85
+ <div className="flex items-center justify-center py-12 text-text-4 text-xs font-sans">
86
+ No modified files found
87
+ </div>
88
+ )}
89
+ {reviewFiles.map((file) => (
90
+ <div key={file.path} className="rounded-md border border-border-subtle bg-surface-2">
91
+ <div className="flex items-center gap-2 px-3 py-2">
92
+ <button
93
+ onClick={() => { openFile(file.path); setSelectedFile(file.path); }}
94
+ className="flex-1 min-w-0 text-xs font-mono text-text-1 hover:text-accent truncate text-left cursor-pointer"
95
+ >
96
+ {file.path}
97
+ </button>
98
+ <div className="flex items-center gap-1 flex-shrink-0">
99
+ <button
100
+ onClick={() => approveFile(file.path)}
101
+ className={cn(
102
+ 'p-1 rounded cursor-pointer transition-colors',
103
+ file.status === 'approved'
104
+ ? 'bg-success/15 text-success'
105
+ : 'text-text-4 hover:text-success hover:bg-success/10',
106
+ )}
107
+ title="Approve"
108
+ >
109
+ <Check size={14} />
110
+ </button>
111
+ <button
112
+ onClick={() => rejectFile(file.path)}
113
+ className={cn(
114
+ 'p-1 rounded cursor-pointer transition-colors',
115
+ file.status === 'rejected'
116
+ ? 'bg-danger/15 text-danger'
117
+ : 'text-text-4 hover:text-danger hover:bg-danger/10',
118
+ )}
119
+ title="Reject"
120
+ >
121
+ <X size={14} />
122
+ </button>
123
+ <button
124
+ onClick={() => setCommentingPath(commentingPath === file.path ? null : file.path)}
125
+ className={cn(
126
+ 'p-1 rounded cursor-pointer transition-colors',
127
+ file.comment
128
+ ? 'bg-accent/15 text-accent'
129
+ : 'text-text-4 hover:text-accent hover:bg-accent/10',
130
+ )}
131
+ title="Comment"
132
+ >
133
+ <MessageSquare size={14} />
134
+ </button>
135
+ </div>
136
+ </div>
137
+ {file.comment && commentingPath !== file.path && (
138
+ <div className="px-3 pb-2 text-2xs text-text-2 font-sans italic">
139
+ {file.comment}
140
+ </div>
141
+ )}
142
+ {commentingPath === file.path && (
143
+ <div className="flex items-center gap-1.5 px-3 pb-2">
144
+ <input
145
+ value={commentText}
146
+ onChange={(e) => setCommentText(e.target.value)}
147
+ onKeyDown={(e) => { if (e.key === 'Enter') handleComment(file.path); if (e.key === 'Escape') setCommentingPath(null); }}
148
+ placeholder="Add review comment..."
149
+ className="flex-1 h-7 px-2 text-xs bg-surface-0 border border-border-subtle rounded text-text-0 font-sans focus:outline-none focus:border-accent"
150
+ autoFocus
151
+ />
152
+ <button
153
+ onClick={() => handleComment(file.path)}
154
+ className="p-1 text-accent hover:text-accent/80 cursor-pointer"
155
+ >
156
+ <Send size={12} />
157
+ </button>
158
+ </div>
159
+ )}
160
+ </div>
161
+ ))}
162
+ </div>
163
+ </ScrollArea>
164
+
165
+ <div className="flex items-center gap-2 px-4 py-3 border-t border-border bg-surface-1 flex-shrink-0">
166
+ <Button variant="ghost" size="sm" onClick={handleApproveAll} className="gap-1.5">
167
+ <CheckCircle2 size={13} />
168
+ Approve All
169
+ </Button>
170
+ <Button variant="ghost" size="sm" onClick={handleRequestChanges} className="gap-1.5 text-warning">
171
+ <XCircle size={13} />
172
+ Request Changes
173
+ </Button>
174
+ </div>
175
+ </div>
176
+ );
177
+ }
@@ -0,0 +1,148 @@
1
+ // FSL-1.1-Apache-2.0 — see LICENSE
2
+ import { useMemo } from 'react';
3
+ import { useGrooveStore } from '../../stores/groove';
4
+ import { cn } from '../../lib/cn';
5
+ import { ScrollArea } from '../ui/scroll-area';
6
+
7
+ function computeDiff(original, modified) {
8
+ const origLines = (original || '').split('\n');
9
+ const modLines = (modified || '').split('\n');
10
+ const result = [];
11
+
12
+ const maxLen = Math.max(origLines.length, modLines.length);
13
+ let oi = 0, mi = 0;
14
+
15
+ while (oi < origLines.length || mi < modLines.length) {
16
+ if (oi >= origLines.length) {
17
+ result.push({ type: 'add', lineNum: mi + 1, text: modLines[mi] });
18
+ mi++;
19
+ } else if (mi >= modLines.length) {
20
+ result.push({ type: 'del', lineNum: oi + 1, text: origLines[oi] });
21
+ oi++;
22
+ } else if (origLines[oi] === modLines[mi]) {
23
+ result.push({ type: 'same', lineNum: mi + 1, origLineNum: oi + 1, text: modLines[mi] });
24
+ oi++;
25
+ mi++;
26
+ } else {
27
+ let foundOrig = -1;
28
+ let foundMod = -1;
29
+ const lookAhead = Math.min(10, maxLen);
30
+
31
+ for (let k = 1; k <= lookAhead; k++) {
32
+ if (mi + k < modLines.length && origLines[oi] === modLines[mi + k]) {
33
+ foundMod = mi + k;
34
+ break;
35
+ }
36
+ }
37
+ for (let k = 1; k <= lookAhead; k++) {
38
+ if (oi + k < origLines.length && origLines[oi + k] === modLines[mi]) {
39
+ foundOrig = oi + k;
40
+ break;
41
+ }
42
+ }
43
+
44
+ if (foundMod >= 0 && (foundOrig < 0 || foundMod - mi <= foundOrig - oi)) {
45
+ while (mi < foundMod) {
46
+ result.push({ type: 'add', lineNum: mi + 1, text: modLines[mi] });
47
+ mi++;
48
+ }
49
+ } else if (foundOrig >= 0) {
50
+ while (oi < foundOrig) {
51
+ result.push({ type: 'del', lineNum: oi + 1, text: origLines[oi] });
52
+ oi++;
53
+ }
54
+ } else {
55
+ result.push({ type: 'del', lineNum: oi + 1, text: origLines[oi] });
56
+ result.push({ type: 'add', lineNum: mi + 1, text: modLines[mi] });
57
+ oi++;
58
+ mi++;
59
+ }
60
+ }
61
+ }
62
+
63
+ return result;
64
+ }
65
+
66
+ export function DiffViewer({ filePath }) {
67
+ const file = useGrooveStore((s) => s.editorFiles[filePath]);
68
+ const snapshot = useGrooveStore((s) => s.workspaceSnapshots[filePath]);
69
+
70
+ const original = snapshot || file?.originalContent || '';
71
+ const modified = file?.content || '';
72
+
73
+ const diffLines = useMemo(() => computeDiff(original, modified), [original, modified]);
74
+
75
+ const stats = useMemo(() => {
76
+ let adds = 0, dels = 0;
77
+ for (const line of diffLines) {
78
+ if (line.type === 'add') adds++;
79
+ if (line.type === 'del') dels++;
80
+ }
81
+ return { adds, dels };
82
+ }, [diffLines]);
83
+
84
+ if (!file) {
85
+ return (
86
+ <div className="flex items-center justify-center h-full text-text-4 text-xs font-sans">
87
+ No file loaded
88
+ </div>
89
+ );
90
+ }
91
+
92
+ if (original === modified) {
93
+ return (
94
+ <div className="flex items-center justify-center h-full text-text-4 text-xs font-sans">
95
+ No changes detected
96
+ </div>
97
+ );
98
+ }
99
+
100
+ return (
101
+ <div className="flex flex-col h-full">
102
+ <div className="flex items-center gap-3 px-4 py-2 bg-surface-1 border-b border-border-subtle text-xs font-sans flex-shrink-0">
103
+ <span className="text-text-2">{filePath.split('/').pop()}</span>
104
+ <span className="text-success">+{stats.adds}</span>
105
+ <span className="text-danger">-{stats.dels}</span>
106
+ </div>
107
+ <ScrollArea className="flex-1">
108
+ <div className="font-mono text-xs leading-5">
109
+ {diffLines.map((line, i) => (
110
+ <div
111
+ key={i}
112
+ className={cn(
113
+ 'flex',
114
+ line.type === 'add' && 'bg-success/8',
115
+ line.type === 'del' && 'bg-danger/8',
116
+ )}
117
+ >
118
+ <span className={cn(
119
+ 'w-12 flex-shrink-0 text-right pr-3 select-none',
120
+ line.type === 'add' ? 'text-success/60' : line.type === 'del' ? 'text-danger/60' : 'text-text-4',
121
+ )}>
122
+ {line.type === 'add' ? '' : (line.origLineNum || line.lineNum)}
123
+ </span>
124
+ <span className={cn(
125
+ 'w-12 flex-shrink-0 text-right pr-3 select-none',
126
+ line.type === 'add' ? 'text-success/60' : line.type === 'del' ? 'text-danger/60' : 'text-text-4',
127
+ )}>
128
+ {line.type === 'del' ? '' : line.lineNum}
129
+ </span>
130
+ <span className={cn(
131
+ 'w-5 flex-shrink-0 text-center select-none font-bold',
132
+ line.type === 'add' ? 'text-success' : line.type === 'del' ? 'text-danger' : 'text-text-4',
133
+ )}>
134
+ {line.type === 'add' ? '+' : line.type === 'del' ? '-' : ' '}
135
+ </span>
136
+ <span className={cn(
137
+ 'flex-1 whitespace-pre px-2',
138
+ line.type === 'add' ? 'text-success/90' : line.type === 'del' ? 'text-danger/90' : 'text-text-1',
139
+ )}>
140
+ {line.text}
141
+ </span>
142
+ </div>
143
+ ))}
144
+ </div>
145
+ </ScrollArea>
146
+ </div>
147
+ );
148
+ }