specweave 0.28.68 → 0.29.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (318) hide show
  1. package/CLAUDE.md +3 -2
  2. package/README.md +19 -2
  3. package/dist/src/cli/commands/discrepancies.d.ts +89 -0
  4. package/dist/src/cli/commands/discrepancies.d.ts.map +1 -0
  5. package/dist/src/cli/commands/discrepancies.js +385 -0
  6. package/dist/src/cli/commands/discrepancies.js.map +1 -0
  7. package/dist/src/cli/commands/notifications.d.ts +70 -0
  8. package/dist/src/cli/commands/notifications.d.ts.map +1 -0
  9. package/dist/src/cli/commands/notifications.js +236 -0
  10. package/dist/src/cli/commands/notifications.js.map +1 -0
  11. package/dist/src/cli/commands/sync-logs.d.ts +54 -0
  12. package/dist/src/cli/commands/sync-logs.d.ts.map +1 -0
  13. package/dist/src/cli/commands/sync-logs.js +240 -0
  14. package/dist/src/cli/commands/sync-logs.js.map +1 -0
  15. package/dist/src/cli/commands/sync-monitor.d.ts +42 -0
  16. package/dist/src/cli/commands/sync-monitor.d.ts.map +1 -0
  17. package/dist/src/cli/commands/sync-monitor.js +191 -0
  18. package/dist/src/cli/commands/sync-monitor.js.map +1 -0
  19. package/dist/src/cli/helpers/init/brownfield-analysis.d.ts +45 -0
  20. package/dist/src/cli/helpers/init/brownfield-analysis.d.ts.map +1 -0
  21. package/dist/src/cli/helpers/init/brownfield-analysis.js +431 -0
  22. package/dist/src/cli/helpers/init/brownfield-analysis.js.map +1 -0
  23. package/dist/src/cli/helpers/init/index.d.ts +1 -0
  24. package/dist/src/cli/helpers/init/index.d.ts.map +1 -1
  25. package/dist/src/cli/helpers/init/index.js +2 -0
  26. package/dist/src/cli/helpers/init/index.js.map +1 -1
  27. package/dist/src/cli/workers/brownfield-worker.d.ts +66 -0
  28. package/dist/src/cli/workers/brownfield-worker.d.ts.map +1 -0
  29. package/dist/src/cli/workers/brownfield-worker.js +417 -0
  30. package/dist/src/cli/workers/brownfield-worker.js.map +1 -0
  31. package/dist/src/core/background/brownfield-launcher.d.ts +86 -0
  32. package/dist/src/core/background/brownfield-launcher.d.ts.map +1 -0
  33. package/dist/src/core/background/brownfield-launcher.js +295 -0
  34. package/dist/src/core/background/brownfield-launcher.js.map +1 -0
  35. package/dist/src/core/background/index.d.ts +2 -0
  36. package/dist/src/core/background/index.d.ts.map +1 -1
  37. package/dist/src/core/background/index.js +2 -0
  38. package/dist/src/core/background/index.js.map +1 -1
  39. package/dist/src/core/background/types.d.ts +23 -2
  40. package/dist/src/core/background/types.d.ts.map +1 -1
  41. package/dist/src/core/config/index.d.ts +1 -0
  42. package/dist/src/core/config/index.d.ts.map +1 -1
  43. package/dist/src/core/config/index.js +1 -0
  44. package/dist/src/core/config/index.js.map +1 -1
  45. package/dist/src/core/config/types.d.ts +6 -0
  46. package/dist/src/core/config/types.d.ts.map +1 -1
  47. package/dist/src/core/config/types.js.map +1 -1
  48. package/dist/src/core/dashboard/dashboard-data.d.ts +156 -0
  49. package/dist/src/core/dashboard/dashboard-data.d.ts.map +1 -0
  50. package/dist/src/core/dashboard/dashboard-data.js +191 -0
  51. package/dist/src/core/dashboard/dashboard-data.js.map +1 -0
  52. package/dist/src/core/dashboard/index.d.ts +9 -0
  53. package/dist/src/core/dashboard/index.d.ts.map +1 -0
  54. package/dist/src/core/dashboard/index.js +9 -0
  55. package/dist/src/core/dashboard/index.js.map +1 -0
  56. package/dist/src/core/discrepancy/analyzers/api-route-analyzer.d.ts +77 -0
  57. package/dist/src/core/discrepancy/analyzers/api-route-analyzer.d.ts.map +1 -0
  58. package/dist/src/core/discrepancy/analyzers/api-route-analyzer.js +286 -0
  59. package/dist/src/core/discrepancy/analyzers/api-route-analyzer.js.map +1 -0
  60. package/dist/src/core/discrepancy/analyzers/index.d.ts +8 -0
  61. package/dist/src/core/discrepancy/analyzers/index.d.ts.map +1 -0
  62. package/dist/src/core/discrepancy/analyzers/index.js +8 -0
  63. package/dist/src/core/discrepancy/analyzers/index.js.map +1 -0
  64. package/dist/src/core/discrepancy/analyzers/typescript-analyzer.d.ts +96 -0
  65. package/dist/src/core/discrepancy/analyzers/typescript-analyzer.d.ts.map +1 -0
  66. package/dist/src/core/discrepancy/analyzers/typescript-analyzer.js +247 -0
  67. package/dist/src/core/discrepancy/analyzers/typescript-analyzer.js.map +1 -0
  68. package/dist/src/core/discrepancy/brownfield-manager.d.ts +88 -0
  69. package/dist/src/core/discrepancy/brownfield-manager.d.ts.map +1 -0
  70. package/dist/src/core/discrepancy/brownfield-manager.js +520 -0
  71. package/dist/src/core/discrepancy/brownfield-manager.js.map +1 -0
  72. package/dist/src/core/discrepancy/brownfield-types.d.ts +174 -0
  73. package/dist/src/core/discrepancy/brownfield-types.d.ts.map +1 -0
  74. package/dist/src/core/discrepancy/brownfield-types.js +11 -0
  75. package/dist/src/core/discrepancy/brownfield-types.js.map +1 -0
  76. package/dist/src/core/discrepancy/detector.d.ts +92 -0
  77. package/dist/src/core/discrepancy/detector.d.ts.map +1 -0
  78. package/dist/src/core/discrepancy/detector.js +346 -0
  79. package/dist/src/core/discrepancy/detector.js.map +1 -0
  80. package/dist/src/core/discrepancy/increment-generator.d.ts +51 -0
  81. package/dist/src/core/discrepancy/increment-generator.d.ts.map +1 -0
  82. package/dist/src/core/discrepancy/increment-generator.js +234 -0
  83. package/dist/src/core/discrepancy/increment-generator.js.map +1 -0
  84. package/dist/src/core/discrepancy/index.d.ts +18 -0
  85. package/dist/src/core/discrepancy/index.d.ts.map +1 -0
  86. package/dist/src/core/discrepancy/index.js +24 -0
  87. package/dist/src/core/discrepancy/index.js.map +1 -0
  88. package/dist/src/core/discrepancy/severity-classifier.d.ts +81 -0
  89. package/dist/src/core/discrepancy/severity-classifier.d.ts.map +1 -0
  90. package/dist/src/core/discrepancy/severity-classifier.js +289 -0
  91. package/dist/src/core/discrepancy/severity-classifier.js.map +1 -0
  92. package/dist/src/core/discrepancy/spec-parser.d.ts +74 -0
  93. package/dist/src/core/discrepancy/spec-parser.d.ts.map +1 -0
  94. package/dist/src/core/discrepancy/spec-parser.js +213 -0
  95. package/dist/src/core/discrepancy/spec-parser.js.map +1 -0
  96. package/dist/src/core/discrepancy/update-recommender.d.ts +77 -0
  97. package/dist/src/core/discrepancy/update-recommender.d.ts.map +1 -0
  98. package/dist/src/core/discrepancy/update-recommender.js +323 -0
  99. package/dist/src/core/discrepancy/update-recommender.js.map +1 -0
  100. package/dist/src/core/living-docs/living-docs-sync.d.ts +13 -16
  101. package/dist/src/core/living-docs/living-docs-sync.d.ts.map +1 -1
  102. package/dist/src/core/living-docs/living-docs-sync.js +31 -112
  103. package/dist/src/core/living-docs/living-docs-sync.js.map +1 -1
  104. package/dist/src/core/logs/index.d.ts +10 -0
  105. package/dist/src/core/logs/index.d.ts.map +1 -0
  106. package/dist/src/core/logs/index.js +10 -0
  107. package/dist/src/core/logs/index.js.map +1 -0
  108. package/dist/src/core/logs/log-aggregator.d.ts +130 -0
  109. package/dist/src/core/logs/log-aggregator.d.ts.map +1 -0
  110. package/dist/src/core/logs/log-aggregator.js +206 -0
  111. package/dist/src/core/logs/log-aggregator.js.map +1 -0
  112. package/dist/src/core/logs/log-exporter.d.ts +81 -0
  113. package/dist/src/core/logs/log-exporter.d.ts.map +1 -0
  114. package/dist/src/core/logs/log-exporter.js +141 -0
  115. package/dist/src/core/logs/log-exporter.js.map +1 -0
  116. package/dist/src/core/notifications/command-integration.d.ts +82 -0
  117. package/dist/src/core/notifications/command-integration.d.ts.map +1 -0
  118. package/dist/src/core/notifications/command-integration.js +80 -0
  119. package/dist/src/core/notifications/command-integration.js.map +1 -0
  120. package/dist/src/core/notifications/index.d.ts +12 -0
  121. package/dist/src/core/notifications/index.d.ts.map +1 -0
  122. package/dist/src/core/notifications/index.js +12 -0
  123. package/dist/src/core/notifications/index.js.map +1 -0
  124. package/dist/src/core/notifications/notification-display.d.ts +70 -0
  125. package/dist/src/core/notifications/notification-display.d.ts.map +1 -0
  126. package/dist/src/core/notifications/notification-display.js +177 -0
  127. package/dist/src/core/notifications/notification-display.js.map +1 -0
  128. package/dist/src/core/notifications/notification-manager.d.ts +126 -0
  129. package/dist/src/core/notifications/notification-manager.d.ts.map +1 -0
  130. package/dist/src/core/notifications/notification-manager.js +287 -0
  131. package/dist/src/core/notifications/notification-manager.js.map +1 -0
  132. package/dist/src/core/notifications/notification-types.d.ts +159 -0
  133. package/dist/src/core/notifications/notification-types.d.ts.map +1 -0
  134. package/dist/src/core/notifications/notification-types.js +93 -0
  135. package/dist/src/core/notifications/notification-types.js.map +1 -0
  136. package/dist/src/core/scheduler/index.d.ts +11 -0
  137. package/dist/src/core/scheduler/index.d.ts.map +1 -0
  138. package/dist/src/core/scheduler/index.js +11 -0
  139. package/dist/src/core/scheduler/index.js.map +1 -0
  140. package/dist/src/core/scheduler/job-scheduler.d.ts +179 -0
  141. package/dist/src/core/scheduler/job-scheduler.d.ts.map +1 -0
  142. package/dist/src/core/scheduler/job-scheduler.js +282 -0
  143. package/dist/src/core/scheduler/job-scheduler.js.map +1 -0
  144. package/dist/src/core/scheduler/schedule-persistence.d.ts +83 -0
  145. package/dist/src/core/scheduler/schedule-persistence.d.ts.map +1 -0
  146. package/dist/src/core/scheduler/schedule-persistence.js +180 -0
  147. package/dist/src/core/scheduler/schedule-persistence.js.map +1 -0
  148. package/dist/src/core/scheduler/scheduled-job.d.ts +188 -0
  149. package/dist/src/core/scheduler/scheduled-job.d.ts.map +1 -0
  150. package/dist/src/core/scheduler/scheduled-job.js +182 -0
  151. package/dist/src/core/scheduler/scheduled-job.js.map +1 -0
  152. package/dist/src/core/sync/permission-enforcer.d.ts +206 -0
  153. package/dist/src/core/sync/permission-enforcer.d.ts.map +1 -0
  154. package/dist/src/core/sync/permission-enforcer.js +268 -0
  155. package/dist/src/core/sync/permission-enforcer.js.map +1 -0
  156. package/dist/src/core/sync/sync-audit-logger.d.ts +217 -0
  157. package/dist/src/core/sync/sync-audit-logger.d.ts.map +1 -0
  158. package/dist/src/core/sync/sync-audit-logger.js +327 -0
  159. package/dist/src/core/sync/sync-audit-logger.js.map +1 -0
  160. package/dist/src/core/sync/sync-interceptor.d.ts +190 -0
  161. package/dist/src/core/sync/sync-interceptor.d.ts.map +1 -0
  162. package/dist/src/core/sync/sync-interceptor.js +224 -0
  163. package/dist/src/core/sync/sync-interceptor.js.map +1 -0
  164. package/dist/src/core/types/increment-metadata.d.ts +5 -2
  165. package/dist/src/core/types/increment-metadata.d.ts.map +1 -1
  166. package/dist/src/core/types/sync-config.d.ts +267 -0
  167. package/dist/src/core/types/sync-config.d.ts.map +1 -0
  168. package/dist/src/core/types/sync-config.js +304 -0
  169. package/dist/src/core/types/sync-config.js.map +1 -0
  170. package/dist/src/hooks/index.d.ts +11 -0
  171. package/dist/src/hooks/index.d.ts.map +1 -0
  172. package/dist/src/hooks/index.js +11 -0
  173. package/dist/src/hooks/index.js.map +1 -0
  174. package/dist/src/hooks/platform.d.ts +125 -0
  175. package/dist/src/hooks/platform.d.ts.map +1 -0
  176. package/dist/src/hooks/platform.js +325 -0
  177. package/dist/src/hooks/platform.js.map +1 -0
  178. package/dist/src/hooks/processor.d.ts +20 -0
  179. package/dist/src/hooks/processor.d.ts.map +1 -0
  180. package/dist/src/hooks/processor.js +317 -0
  181. package/dist/src/hooks/processor.js.map +1 -0
  182. package/dist/src/hooks/scheduler-startup.d.ts +19 -0
  183. package/dist/src/hooks/scheduler-startup.d.ts.map +1 -0
  184. package/dist/src/hooks/scheduler-startup.js +92 -0
  185. package/dist/src/hooks/scheduler-startup.js.map +1 -0
  186. package/dist/src/hooks/session-start.d.ts +16 -0
  187. package/dist/src/hooks/session-start.d.ts.map +1 -0
  188. package/dist/src/hooks/session-start.js +92 -0
  189. package/dist/src/hooks/session-start.js.map +1 -0
  190. package/dist/src/importers/duplicate-detector.d.ts +13 -2
  191. package/dist/src/importers/duplicate-detector.d.ts.map +1 -1
  192. package/dist/src/importers/duplicate-detector.js +21 -2
  193. package/dist/src/importers/duplicate-detector.js.map +1 -1
  194. package/dist/src/importers/item-converter.d.ts +41 -2
  195. package/dist/src/importers/item-converter.d.ts.map +1 -1
  196. package/dist/src/importers/item-converter.js +225 -38
  197. package/dist/src/importers/item-converter.js.map +1 -1
  198. package/dist/src/living-docs/fs-id-allocator.d.ts +7 -0
  199. package/dist/src/living-docs/fs-id-allocator.d.ts.map +1 -1
  200. package/dist/src/living-docs/fs-id-allocator.js +30 -4
  201. package/dist/src/living-docs/fs-id-allocator.js.map +1 -1
  202. package/dist/src/sync/ado-sync-wrapper.d.ts +137 -0
  203. package/dist/src/sync/ado-sync-wrapper.d.ts.map +1 -0
  204. package/dist/src/sync/ado-sync-wrapper.js +148 -0
  205. package/dist/src/sync/ado-sync-wrapper.js.map +1 -0
  206. package/dist/src/sync/github-sync-wrapper.d.ts +195 -0
  207. package/dist/src/sync/github-sync-wrapper.d.ts.map +1 -0
  208. package/dist/src/sync/github-sync-wrapper.js +220 -0
  209. package/dist/src/sync/github-sync-wrapper.js.map +1 -0
  210. package/dist/src/sync/jira-sync-wrapper.d.ts +155 -0
  211. package/dist/src/sync/jira-sync-wrapper.d.ts.map +1 -0
  212. package/dist/src/sync/jira-sync-wrapper.js +175 -0
  213. package/dist/src/sync/jira-sync-wrapper.js.map +1 -0
  214. package/dist/src/utils/feature-id-derivation.d.ts +58 -0
  215. package/dist/src/utils/feature-id-derivation.d.ts.map +1 -0
  216. package/dist/src/utils/feature-id-derivation.js +77 -0
  217. package/dist/src/utils/feature-id-derivation.js.map +1 -0
  218. package/package.json +3 -1
  219. package/plugins/specweave/commands/specweave-discrepancies.md +141 -0
  220. package/plugins/specweave/commands/specweave-discrepancy-to-increment.md +160 -0
  221. package/plugins/specweave/commands/specweave-jobs.md +45 -2
  222. package/plugins/specweave/commands/specweave-notifications.md +92 -0
  223. package/plugins/specweave/commands/specweave-sync-logs.md +131 -0
  224. package/plugins/specweave/commands/specweave-sync-monitor.md +57 -0
  225. package/plugins/specweave/hooks/hooks.json +3 -3
  226. package/plugins/specweave/hooks/lib/scheduler-startup.sh +72 -0
  227. package/plugins/specweave/hooks/universal/dispatcher.mjs +246 -0
  228. package/plugins/specweave/hooks/universal/session-start.cmd +16 -0
  229. package/plugins/specweave/hooks/universal/session-start.ps1 +16 -0
  230. package/plugins/specweave/hooks/v2/dispatchers/session-start.sh +14 -5
  231. package/plugins/specweave/lib/vendor/core/types/increment-metadata.d.ts +5 -2
  232. package/plugins/specweave/skills/discrepancy-viewer.md +154 -0
  233. package/plugins/specweave-github/hooks/.specweave/logs/hooks-debug.log +46 -0
  234. package/plugins/specweave-release/hooks/.specweave/logs/dora-tracking.log +69 -0
  235. package/dist/plugins/specweave-github/lib/enhanced-github-sync.d.ts +0 -26
  236. package/dist/plugins/specweave-github/lib/enhanced-github-sync.d.ts.map +0 -1
  237. package/dist/plugins/specweave-github/lib/enhanced-github-sync.js +0 -249
  238. package/dist/plugins/specweave-github/lib/enhanced-github-sync.js.map +0 -1
  239. package/dist/plugins/specweave-jira/lib/enhanced-jira-sync.d.ts +0 -28
  240. package/dist/plugins/specweave-jira/lib/enhanced-jira-sync.d.ts.map +0 -1
  241. package/dist/plugins/specweave-jira/lib/enhanced-jira-sync.js +0 -156
  242. package/dist/plugins/specweave-jira/lib/enhanced-jira-sync.js.map +0 -1
  243. package/dist/src/core/sync/bidirectional-engine.d.ts +0 -119
  244. package/dist/src/core/sync/bidirectional-engine.d.ts.map +0 -1
  245. package/dist/src/core/sync/bidirectional-engine.js +0 -359
  246. package/dist/src/core/sync/bidirectional-engine.js.map +0 -1
  247. package/dist/src/core/sync/conflict-resolver.d.ts +0 -66
  248. package/dist/src/core/sync/conflict-resolver.d.ts.map +0 -1
  249. package/dist/src/core/sync/conflict-resolver.js +0 -108
  250. package/dist/src/core/sync/conflict-resolver.js.map +0 -1
  251. package/dist/src/core/sync/enhanced-content-builder.d.ts +0 -55
  252. package/dist/src/core/sync/enhanced-content-builder.d.ts.map +0 -1
  253. package/dist/src/core/sync/enhanced-content-builder.js +0 -203
  254. package/dist/src/core/sync/enhanced-content-builder.js.map +0 -1
  255. package/dist/src/core/sync/folder-mapper.d.ts +0 -71
  256. package/dist/src/core/sync/folder-mapper.d.ts.map +0 -1
  257. package/dist/src/core/sync/folder-mapper.js +0 -203
  258. package/dist/src/core/sync/folder-mapper.js.map +0 -1
  259. package/dist/src/core/sync/label-detector.d.ts +0 -66
  260. package/dist/src/core/sync/label-detector.d.ts.map +0 -1
  261. package/dist/src/core/sync/label-detector.js +0 -224
  262. package/dist/src/core/sync/label-detector.js.map +0 -1
  263. package/dist/src/core/sync/performance-optimizer.d.ts +0 -153
  264. package/dist/src/core/sync/performance-optimizer.d.ts.map +0 -1
  265. package/dist/src/core/sync/performance-optimizer.js +0 -220
  266. package/dist/src/core/sync/performance-optimizer.js.map +0 -1
  267. package/dist/src/core/sync/profile-selector.d.ts +0 -52
  268. package/dist/src/core/sync/profile-selector.d.ts.map +0 -1
  269. package/dist/src/core/sync/profile-selector.js +0 -179
  270. package/dist/src/core/sync/profile-selector.js.map +0 -1
  271. package/dist/src/core/sync/profile-validator.d.ts +0 -52
  272. package/dist/src/core/sync/profile-validator.d.ts.map +0 -1
  273. package/dist/src/core/sync/profile-validator.js +0 -170
  274. package/dist/src/core/sync/profile-validator.js.map +0 -1
  275. package/dist/src/core/sync/rate-limiter.d.ts +0 -116
  276. package/dist/src/core/sync/rate-limiter.d.ts.map +0 -1
  277. package/dist/src/core/sync/rate-limiter.js +0 -308
  278. package/dist/src/core/sync/rate-limiter.js.map +0 -1
  279. package/dist/src/core/sync/retry-handler.d.ts +0 -98
  280. package/dist/src/core/sync/retry-handler.d.ts.map +0 -1
  281. package/dist/src/core/sync/retry-handler.js +0 -196
  282. package/dist/src/core/sync/retry-handler.js.map +0 -1
  283. package/dist/src/core/sync/retry-logic.d.ts +0 -64
  284. package/dist/src/core/sync/retry-logic.d.ts.map +0 -1
  285. package/dist/src/core/sync/retry-logic.js +0 -165
  286. package/dist/src/core/sync/retry-logic.js.map +0 -1
  287. package/dist/src/core/sync/status-cache.d.ts +0 -91
  288. package/dist/src/core/sync/status-cache.d.ts.map +0 -1
  289. package/dist/src/core/sync/status-cache.js +0 -140
  290. package/dist/src/core/sync/status-cache.js.map +0 -1
  291. package/dist/src/core/sync/status-mapper.d.ts +0 -69
  292. package/dist/src/core/sync/status-mapper.d.ts.map +0 -1
  293. package/dist/src/core/sync/status-mapper.js +0 -90
  294. package/dist/src/core/sync/status-mapper.js.map +0 -1
  295. package/dist/src/core/sync/status-sync-engine.d.ts +0 -162
  296. package/dist/src/core/sync/status-sync-engine.d.ts.map +0 -1
  297. package/dist/src/core/sync/status-sync-engine.js +0 -347
  298. package/dist/src/core/sync/status-sync-engine.js.map +0 -1
  299. package/dist/src/core/sync/sync-event-logger.d.ts +0 -113
  300. package/dist/src/core/sync/sync-event-logger.d.ts.map +0 -1
  301. package/dist/src/core/sync/sync-event-logger.js +0 -141
  302. package/dist/src/core/sync/sync-event-logger.js.map +0 -1
  303. package/dist/src/core/sync/time-range-selector.d.ts +0 -48
  304. package/dist/src/core/sync/time-range-selector.d.ts.map +0 -1
  305. package/dist/src/core/sync/time-range-selector.js +0 -224
  306. package/dist/src/core/sync/time-range-selector.js.map +0 -1
  307. package/dist/src/core/sync/types.d.ts +0 -52
  308. package/dist/src/core/sync/types.d.ts.map +0 -1
  309. package/dist/src/core/sync/types.js +0 -5
  310. package/dist/src/core/sync/types.js.map +0 -1
  311. package/dist/src/core/sync/workflow-detector.d.ts +0 -95
  312. package/dist/src/core/sync/workflow-detector.d.ts.map +0 -1
  313. package/dist/src/core/sync/workflow-detector.js +0 -175
  314. package/dist/src/core/sync/workflow-detector.js.map +0 -1
  315. package/plugins/specweave-github/lib/enhanced-github-sync.js +0 -220
  316. package/plugins/specweave-github/lib/enhanced-github-sync.ts +0 -322
  317. package/plugins/specweave-jira/lib/enhanced-jira-sync.js +0 -134
  318. package/plugins/specweave-jira/lib/enhanced-jira-sync.ts +0 -196
@@ -0,0 +1,141 @@
1
+ /**
2
+ * Log Exporter
3
+ *
4
+ * Exports log query results to various formats.
5
+ *
6
+ * @module core/logs/log-exporter
7
+ */
8
+ import { promises as fs } from 'fs';
9
+ import path from 'path';
10
+ import { consoleLogger } from '../../utils/logger.js';
11
+ /**
12
+ * LogExporter - Export log entries to files
13
+ *
14
+ * Supports:
15
+ * - JSON (single object with entries array)
16
+ * - JSONL (one entry per line)
17
+ * - CSV (for spreadsheet import)
18
+ */
19
+ export class LogExporter {
20
+ constructor(options = {}) {
21
+ this.logger = options.logger ?? consoleLogger;
22
+ }
23
+ /**
24
+ * Export query results to a file
25
+ */
26
+ async export(result, outputPath, options = {}) {
27
+ const format = options.format ?? this.detectFormat(outputPath);
28
+ const content = this.formatContent(result, format, options);
29
+ // Ensure directory exists
30
+ await fs.mkdir(path.dirname(outputPath), { recursive: true });
31
+ // Write file
32
+ await fs.writeFile(outputPath, content, 'utf-8');
33
+ this.logger.debug(`Exported ${result.entries.length} entries to ${outputPath}`);
34
+ }
35
+ /**
36
+ * Export entries to a string
37
+ */
38
+ exportToString(entries, format, options = {}) {
39
+ const result = {
40
+ entries,
41
+ total: entries.length,
42
+ hasMore: false,
43
+ query: {},
44
+ executionTimeMs: 0,
45
+ };
46
+ return this.formatContent(result, format, options);
47
+ }
48
+ /**
49
+ * Format content based on format type
50
+ */
51
+ formatContent(result, format, options) {
52
+ switch (format) {
53
+ case 'json':
54
+ return this.formatJson(result, options);
55
+ case 'jsonl':
56
+ return this.formatJsonl(result);
57
+ case 'csv':
58
+ return this.formatCsv(result);
59
+ default:
60
+ return this.formatJson(result, options);
61
+ }
62
+ }
63
+ /**
64
+ * Format as JSON
65
+ */
66
+ formatJson(result, options) {
67
+ const pretty = options.pretty ?? true;
68
+ const includeMetadata = options.includeMetadata ?? true;
69
+ const output = includeMetadata
70
+ ? {
71
+ metadata: {
72
+ exportedAt: new Date().toISOString(),
73
+ total: result.total,
74
+ hasMore: result.hasMore,
75
+ query: result.query,
76
+ executionTimeMs: result.executionTimeMs,
77
+ },
78
+ entries: result.entries,
79
+ }
80
+ : result.entries;
81
+ return pretty ? JSON.stringify(output, null, 2) : JSON.stringify(output);
82
+ }
83
+ /**
84
+ * Format as JSONL (one JSON object per line)
85
+ */
86
+ formatJsonl(result) {
87
+ return result.entries.map(e => JSON.stringify(e)).join('\n') + '\n';
88
+ }
89
+ /**
90
+ * Format as CSV
91
+ */
92
+ formatCsv(result) {
93
+ const headers = [
94
+ 'timestamp',
95
+ 'platform',
96
+ 'operation',
97
+ 'itemId',
98
+ 'result',
99
+ 'reason',
100
+ 'error',
101
+ 'durationMs',
102
+ ];
103
+ const rows = result.entries.map(entry => [
104
+ entry.timestamp,
105
+ entry.platform,
106
+ entry.operation,
107
+ entry.itemId,
108
+ entry.result,
109
+ entry.reason ?? '',
110
+ entry.error ?? '',
111
+ entry.durationMs?.toString() ?? '',
112
+ ]);
113
+ const escape = (value) => {
114
+ if (value.includes(',') || value.includes('"') || value.includes('\n')) {
115
+ return `"${value.replace(/"/g, '""')}"`;
116
+ }
117
+ return value;
118
+ };
119
+ const csvLines = [
120
+ headers.join(','),
121
+ ...rows.map(row => row.map(escape).join(',')),
122
+ ];
123
+ return csvLines.join('\n') + '\n';
124
+ }
125
+ /**
126
+ * Detect format from file extension
127
+ */
128
+ detectFormat(filePath) {
129
+ const ext = path.extname(filePath).toLowerCase();
130
+ switch (ext) {
131
+ case '.jsonl':
132
+ return 'jsonl';
133
+ case '.csv':
134
+ return 'csv';
135
+ case '.json':
136
+ default:
137
+ return 'json';
138
+ }
139
+ }
140
+ }
141
+ //# sourceMappingURL=log-exporter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"log-exporter.js","sourceRoot":"","sources":["../../../../src/core/logs/log-exporter.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,QAAQ,IAAI,EAAE,EAAE,MAAM,IAAI,CAAC;AACpC,OAAO,IAAI,MAAM,MAAM,CAAC;AAGxB,OAAO,EAAU,aAAa,EAAE,MAAM,uBA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,CAAC;YACZ,KAAK,QAAQ;gBACX,OAAO,OAAO,CAAC;YACjB,KAAK,MAAM;gBACT,OAAO,KAAK,CAAC;YACf,KAAK,OAAO,CAAC;YACb;gBACE,OAAO,MAAM,CAAC;QAClB,CAAC;IACH,CAAC;CACF"}
@@ -0,0 +1,82 @@
1
+ /**
2
+ * Notification Command Integration
3
+ *
4
+ * Helper for injecting notification summaries into command output.
5
+ * Used by SpecWeave commands like /progress, /status, /done to show
6
+ * pending notifications after their main output.
7
+ *
8
+ * @module core/notifications/command-integration
9
+ */
10
+ import { Notification } from './notification-types.js';
11
+ import { Logger } from '../../utils/logger.js';
12
+ /**
13
+ * Options for command notification display
14
+ */
15
+ export interface CommandNotificationOptions {
16
+ /**
17
+ * Path to .specweave directory
18
+ */
19
+ specweavePath?: string;
20
+ /**
21
+ * Logger instance
22
+ */
23
+ logger?: Logger;
24
+ /**
25
+ * Display style
26
+ * @default 'summary'
27
+ */
28
+ style?: 'compact' | 'summary' | 'box';
29
+ /**
30
+ * Minimum severity to show
31
+ * If 'critical', only show if critical notifications exist
32
+ */
33
+ minSeverity?: 'info' | 'warning' | 'critical';
34
+ }
35
+ /**
36
+ * Result of notification check
37
+ */
38
+ export interface NotificationCheckResult {
39
+ /**
40
+ * Number of pending notifications
41
+ */
42
+ count: number;
43
+ /**
44
+ * Whether any critical notifications exist
45
+ */
46
+ hasCritical: boolean;
47
+ /**
48
+ * Whether any warning notifications exist
49
+ */
50
+ hasWarning: boolean;
51
+ /**
52
+ * Formatted output string (empty if no notifications to show)
53
+ */
54
+ output: string;
55
+ /**
56
+ * The pending notifications
57
+ */
58
+ notifications: Notification[];
59
+ }
60
+ /**
61
+ * Check for pending notifications and format for command output
62
+ *
63
+ * @param options - Configuration options
64
+ * @returns Check result with formatted output
65
+ */
66
+ export declare function checkAndFormatNotifications(options?: CommandNotificationOptions): Promise<NotificationCheckResult>;
67
+ /**
68
+ * Print notification summary to console if there are pending notifications
69
+ *
70
+ * @param options - Configuration options
71
+ * @returns true if notifications were printed
72
+ */
73
+ export declare function printNotificationSummary(options?: CommandNotificationOptions): Promise<boolean>;
74
+ /**
75
+ * Wrapper to add notification summary to a command function
76
+ *
77
+ * @param commandFn - The command function to wrap
78
+ * @param options - Notification display options
79
+ * @returns Wrapped function that shows notifications after command
80
+ */
81
+ export declare function withNotifications<T extends (...args: unknown[]) => Promise<void>>(commandFn: T, options?: CommandNotificationOptions): T;
82
+ //# sourceMappingURL=command-integration.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"command-integration.d.ts","sourceRoot":"","sources":["../../../../src/core/notifications/command-integration.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAEvD,OAAO,EAAE,MAAM,EAAiB,MAAM,uBAAuB,CAAC;AAE9D;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;OAGG;IACH,KAAK,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,KAAK,CAAC;IAEtC;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,GAAG,UAAU,CAAC;CAC/C;AAED;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,WAAW,EAAE,OAAO,CAAC;IAErB;;OAEG;IACH,UAAU,EAAE,OAAO,CAAC;IAEpB;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,aAAa,EAAE,YAAY,EAAE,CAAC;CAC/B;AAED;;;;;GAKG;AACH,wBAAsB,2BAA2B,CAC/C,OAAO,GAAE,0BAA+B,GACvC,OAAO,CAAC,uBAAuB,CAAC,CAmClC;AAED;;;;;GAKG;AACH,wBAAsB,wBAAwB,CAC5C,OAAO,GAAE,0BAA+B,GACvC,OAAO,CAAC,OAAO,CAAC,CAUlB;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,OAAO,CAAC,IAAI,CAAC,EAC/E,SAAS,EAAE,CAAC,EACZ,OAAO,GAAE,0BAA+B,GACvC,CAAC,CAKH"}
@@ -0,0 +1,80 @@
1
+ /**
2
+ * Notification Command Integration
3
+ *
4
+ * Helper for injecting notification summaries into command output.
5
+ * Used by SpecWeave commands like /progress, /status, /done to show
6
+ * pending notifications after their main output.
7
+ *
8
+ * @module core/notifications/command-integration
9
+ */
10
+ import path from 'path';
11
+ import { NotificationManager } from './notification-manager.js';
12
+ import { formatNotificationsForOutput } from './notification-display.js';
13
+ import { consoleLogger } from '../../utils/logger.js';
14
+ /**
15
+ * Check for pending notifications and format for command output
16
+ *
17
+ * @param options - Configuration options
18
+ * @returns Check result with formatted output
19
+ */
20
+ export async function checkAndFormatNotifications(options = {}) {
21
+ const logger = options.logger ?? consoleLogger;
22
+ const specweavePath = options.specweavePath ?? path.join(process.cwd(), '.specweave');
23
+ const style = options.style ?? 'summary';
24
+ const manager = new NotificationManager({ specweavePath, logger });
25
+ let notifications;
26
+ try {
27
+ notifications = await manager.getPending();
28
+ }
29
+ catch (error) {
30
+ logger.debug(`Failed to load notifications: ${error}`);
31
+ notifications = [];
32
+ }
33
+ const hasCritical = notifications.some(n => n.severity === 'critical');
34
+ const hasWarning = notifications.some(n => n.severity === 'warning');
35
+ // Filter by minimum severity if specified
36
+ let filteredNotifications = notifications;
37
+ if (options.minSeverity === 'critical') {
38
+ filteredNotifications = hasCritical ? notifications : [];
39
+ }
40
+ else if (options.minSeverity === 'warning') {
41
+ filteredNotifications = (hasCritical || hasWarning) ? notifications : [];
42
+ }
43
+ const output = formatNotificationsForOutput(filteredNotifications, { style });
44
+ return {
45
+ count: notifications.length,
46
+ hasCritical,
47
+ hasWarning,
48
+ output,
49
+ notifications: filteredNotifications,
50
+ };
51
+ }
52
+ /**
53
+ * Print notification summary to console if there are pending notifications
54
+ *
55
+ * @param options - Configuration options
56
+ * @returns true if notifications were printed
57
+ */
58
+ export async function printNotificationSummary(options = {}) {
59
+ const result = await checkAndFormatNotifications(options);
60
+ if (result.output) {
61
+ console.log(result.output);
62
+ console.log("Run '/specweave:notifications' to view");
63
+ return true;
64
+ }
65
+ return false;
66
+ }
67
+ /**
68
+ * Wrapper to add notification summary to a command function
69
+ *
70
+ * @param commandFn - The command function to wrap
71
+ * @param options - Notification display options
72
+ * @returns Wrapped function that shows notifications after command
73
+ */
74
+ export function withNotifications(commandFn, options = {}) {
75
+ return (async (...args) => {
76
+ await commandFn(...args);
77
+ await printNotificationSummary(options);
78
+ });
79
+ }
80
+ //# sourceMappingURL=command-integration.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"command-integration.js","sourceRoot":"","sources":["../../../../src/core/notifications/command-integration.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAEhE,OAAO,EAAE,4BAA4B,EAAE,MAAM,2BAA2B,CAAC;AACzE,OAAO,EAAU,aAAa,EAAE,MAAM,uBAAuB,CAAC;AA2D9D;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,2BAA2B,CAC/C,UAAsC,EAAE;IAExC,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,IAAI,aAAa,CAAC;IAC/C,MAAM,aAAa,GAAG,OAAO,CAAC,aAAa,IAAI,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,YAAY,CAAC,CAAC;IACtF,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,IAAI,SAAS,CAAC;IAEzC,MAAM,OAAO,GAAG,IAAI,mBAAmB,CAAC,EAAE,aAAa,EAAE,MAAM,EAAE,CAAC,CAA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M,EAAE,CAAC;QAClB,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;QAC3B,OAAO,CAAC,GAAG,CAAC,wCAAwC,CAAC,CAAC;QACtD,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,iBAAiB,CAC/B,SAAY,EACZ,UAAsC,EAAE;IAExC,OAAO,CAAC,KAAK,EAAE,GAAG,IAAe,EAAE,EAAE;QACnC,MAAM,SAAS,CAAC,GAAG,IAAI,CAAC,CAAC;QACzB,MAAM,wBAAwB,CAAC,OAAO,CAAC,CAAC;IAC1C,CAAC,CAAM,CAAC;AACV,CAAC"}
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Notifications Module
3
+ *
4
+ * Exports notification functionality for the sync orchestration system.
5
+ *
6
+ * @module core/notifications
7
+ */
8
+ export * from './notification-types.js';
9
+ export * from './notification-manager.js';
10
+ export * from './notification-display.js';
11
+ export * from './command-integration.js';
12
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/core/notifications/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,yBAAyB,CAAC;AACxC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,0BAA0B,CAAC"}
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Notifications Module
3
+ *
4
+ * Exports notification functionality for the sync orchestration system.
5
+ *
6
+ * @module core/notifications
7
+ */
8
+ export * from './notification-types.js';
9
+ export * from './notification-manager.js';
10
+ export * from './notification-display.js';
11
+ export * from './command-integration.js';
12
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/core/notifications/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,yBAAyB,CAAC;AACxC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,0BAA0B,CAAC"}
@@ -0,0 +1,70 @@
1
+ /**
2
+ * Notification Display
3
+ *
4
+ * Formatting utilities for displaying notifications in CLI output.
5
+ *
6
+ * @module core/notifications/notification-display
7
+ */
8
+ import { Notification } from './notification-types.js';
9
+ /**
10
+ * Format a single notification for display
11
+ *
12
+ * @param notification - Notification to format
13
+ * @returns Formatted string
14
+ */
15
+ export declare function formatNotification(notification: Notification): string;
16
+ /**
17
+ * Format a detailed notification for display
18
+ *
19
+ * @param notification - Notification to format
20
+ * @returns Formatted string with message
21
+ */
22
+ export declare function formatNotificationDetailed(notification: Notification): string;
23
+ /**
24
+ * Format a notification summary line
25
+ *
26
+ * @param notifications - Array of pending notifications
27
+ * @returns Summary string (e.g., "3 notifications: 1 critical, 2 warnings")
28
+ */
29
+ export declare function formatNotificationSummary(notifications: Notification[]): string;
30
+ /**
31
+ * Format a notification list for CLI display
32
+ *
33
+ * @param notifications - Array of notifications
34
+ * @param options - Display options
35
+ * @returns Formatted string
36
+ */
37
+ export declare function formatNotificationList(notifications: Notification[], options?: {
38
+ maxItems?: number;
39
+ showDetails?: boolean;
40
+ }): string;
41
+ /**
42
+ * Format notifications in a box for prominent display
43
+ *
44
+ * @param notifications - Array of notifications
45
+ * @returns Formatted box string
46
+ */
47
+ export declare function formatNotificationBox(notifications: Notification[]): string;
48
+ /**
49
+ * Get a compact notification indicator for status line
50
+ *
51
+ * @param count - Number of pending notifications
52
+ * @param hasCritical - Whether any are critical
53
+ * @returns Compact indicator string
54
+ */
55
+ export declare function getNotificationIndicator(count: number, hasCritical: boolean): string;
56
+ /**
57
+ * Format notifications for injection into command output
58
+ *
59
+ * This is the main function used by hooks to display notifications
60
+ * after command execution.
61
+ *
62
+ * @param notifications - Pending notifications
63
+ * @param options - Display options
64
+ * @returns Formatted string to append to output
65
+ */
66
+ export declare function formatNotificationsForOutput(notifications: Notification[], options?: {
67
+ style?: 'compact' | 'summary' | 'box';
68
+ separator?: string;
69
+ }): string;
70
+ //# sourceMappingURL=notification-display.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"notification-display.d.ts","sourceRoot":"","sources":["../../../../src/core/notifications/notification-display.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,YAAY,EAIb,MAAM,yBAAyB,CAAC;AAEjC;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,YAAY,EAAE,YAAY,GAAG,MAAM,CAGrE;AAED;;;;;GAKG;AACH,wBAAgB,0BAA0B,CAAC,YAAY,EAAE,YAAY,GAAG,MAAM,CAI7E;AAED;;;;;GAKG;AACH,wBAAgB,yBAAyB,CAAC,aAAa,EAAE,YAAY,EAAE,GAAG,MAAM,CA8B/E;AAED;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CACpC,aAAa,EAAE,YAAY,EAAE,EAC7B,OAAO,GAAE;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,WAAW,CAAC,EAAE,OAAO,CAAA;CAAO,GACzD,MAAM,CAyBR;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,YAAY,EAAE,GAAG,MAAM,CA0C3E;AAED;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,MAAM,EACb,WAAW,EAAE,OAAO,GACnB,MAAM,CAOR;AAED;;;;;;;;;GASG;AACH,wBAAgB,4BAA4B,CAC1C,aAAa,EAAE,YAAY,EAAE,EAC7B,OAAO,GAAE;IACP,KAAK,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,KAAK,CAAC;IACtC,SAAS,CAAC,EAAE,MAAM,CAAC;CACf,GACL,MAAM,CA6BR"}
@@ -0,0 +1,177 @@
1
+ /**
2
+ * Notification Display
3
+ *
4
+ * Formatting utilities for displaying notifications in CLI output.
5
+ *
6
+ * @module core/notifications/notification-display
7
+ */
8
+ import { getSeverityEmoji, getNotificationTypeLabel, } from './notification-types.js';
9
+ /**
10
+ * Format a single notification for display
11
+ *
12
+ * @param notification - Notification to format
13
+ * @returns Formatted string
14
+ */
15
+ export function formatNotification(notification) {
16
+ const emoji = getSeverityEmoji(notification.severity);
17
+ return `${emoji} ${notification.title}`;
18
+ }
19
+ /**
20
+ * Format a detailed notification for display
21
+ *
22
+ * @param notification - Notification to format
23
+ * @returns Formatted string with message
24
+ */
25
+ export function formatNotificationDetailed(notification) {
26
+ const emoji = getSeverityEmoji(notification.severity);
27
+ const type = getNotificationTypeLabel(notification.type);
28
+ return `${emoji} [${type}] ${notification.title}\n ${notification.message}`;
29
+ }
30
+ /**
31
+ * Format a notification summary line
32
+ *
33
+ * @param notifications - Array of pending notifications
34
+ * @returns Summary string (e.g., "3 notifications: 1 critical, 2 warnings")
35
+ */
36
+ export function formatNotificationSummary(notifications) {
37
+ if (notifications.length === 0) {
38
+ return '';
39
+ }
40
+ const bySeverity = {
41
+ critical: 0,
42
+ warning: 0,
43
+ info: 0,
44
+ };
45
+ for (const n of notifications) {
46
+ bySeverity[n.severity]++;
47
+ }
48
+ const parts = [];
49
+ if (bySeverity.critical > 0) {
50
+ parts.push(`${bySeverity.critical} critical`);
51
+ }
52
+ if (bySeverity.warning > 0) {
53
+ parts.push(`${bySeverity.warning} warning${bySeverity.warning > 1 ? 's' : ''}`);
54
+ }
55
+ if (bySeverity.info > 0) {
56
+ parts.push(`${bySeverity.info} info`);
57
+ }
58
+ const count = notifications.length;
59
+ const countLabel = count === 1 ? 'notification' : 'notifications';
60
+ return `📬 ${count} ${countLabel}${parts.length > 0 ? ': ' + parts.join(', ') : ''}`;
61
+ }
62
+ /**
63
+ * Format a notification list for CLI display
64
+ *
65
+ * @param notifications - Array of notifications
66
+ * @param options - Display options
67
+ * @returns Formatted string
68
+ */
69
+ export function formatNotificationList(notifications, options = {}) {
70
+ const { maxItems = 5, showDetails = false } = options;
71
+ if (notifications.length === 0) {
72
+ return '';
73
+ }
74
+ const items = notifications.slice(0, maxItems);
75
+ const remaining = notifications.length - items.length;
76
+ const lines = [];
77
+ for (const notification of items) {
78
+ if (showDetails) {
79
+ lines.push(formatNotificationDetailed(notification));
80
+ }
81
+ else {
82
+ lines.push(formatNotification(notification));
83
+ }
84
+ }
85
+ if (remaining > 0) {
86
+ lines.push(` ... and ${remaining} more`);
87
+ }
88
+ return lines.join('\n');
89
+ }
90
+ /**
91
+ * Format notifications in a box for prominent display
92
+ *
93
+ * @param notifications - Array of notifications
94
+ * @returns Formatted box string
95
+ */
96
+ export function formatNotificationBox(notifications) {
97
+ if (notifications.length === 0) {
98
+ return '';
99
+ }
100
+ const width = 50;
101
+ const horizontalLine = '─'.repeat(width - 2);
102
+ const lines = [];
103
+ // Top border
104
+ lines.push(`╭${horizontalLine}╮`);
105
+ // Header
106
+ const header = `📬 ${notifications.length} pending notification${notifications.length > 1 ? 's' : ''}`;
107
+ lines.push(`│ ${header.padEnd(width - 3)} │`);
108
+ // Separator
109
+ lines.push(`├${horizontalLine}┤`);
110
+ // Notifications (max 5)
111
+ const maxItems = 5;
112
+ const items = notifications.slice(0, maxItems);
113
+ for (const notification of items) {
114
+ const emoji = getSeverityEmoji(notification.severity);
115
+ const text = `${emoji} ${notification.severity.toUpperCase()}: ${notification.title}`;
116
+ const truncated = text.length > width - 4 ? text.substring(0, width - 7) + '...' : text;
117
+ lines.push(`│ ${truncated.padEnd(width - 3)} │`);
118
+ }
119
+ // Remaining count
120
+ const remaining = notifications.length - items.length;
121
+ if (remaining > 0) {
122
+ const moreText = ` ... and ${remaining} more`;
123
+ lines.push(`│ ${moreText.padEnd(width - 3)} │`);
124
+ }
125
+ // Bottom border
126
+ lines.push(`╰${horizontalLine}╯`);
127
+ return lines.join('\n');
128
+ }
129
+ /**
130
+ * Get a compact notification indicator for status line
131
+ *
132
+ * @param count - Number of pending notifications
133
+ * @param hasCritical - Whether any are critical
134
+ * @returns Compact indicator string
135
+ */
136
+ export function getNotificationIndicator(count, hasCritical) {
137
+ if (count === 0) {
138
+ return '';
139
+ }
140
+ const emoji = hasCritical ? '🔔' : '📬';
141
+ return `${emoji} ${count}`;
142
+ }
143
+ /**
144
+ * Format notifications for injection into command output
145
+ *
146
+ * This is the main function used by hooks to display notifications
147
+ * after command execution.
148
+ *
149
+ * @param notifications - Pending notifications
150
+ * @param options - Display options
151
+ * @returns Formatted string to append to output
152
+ */
153
+ export function formatNotificationsForOutput(notifications, options = {}) {
154
+ const { style = 'summary', separator = '\n\n' } = options;
155
+ if (notifications.length === 0) {
156
+ return '';
157
+ }
158
+ let output;
159
+ switch (style) {
160
+ case 'compact':
161
+ const hasCritical = notifications.some((n) => n.severity === 'critical');
162
+ output = getNotificationIndicator(notifications.length, hasCritical);
163
+ break;
164
+ case 'box':
165
+ output = formatNotificationBox(notifications);
166
+ break;
167
+ case 'summary':
168
+ default:
169
+ output = [
170
+ formatNotificationSummary(notifications),
171
+ formatNotificationList(notifications, { maxItems: 3 }),
172
+ ].filter(Boolean).join('\n');
173
+ break;
174
+ }
175
+ return output ? separator + output : '';
176
+ }
177
+ //# sourceMappingURL=notification-display.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"notification-display.js","sourceRoot":"","sources":["../../../../src/core/notifications/notification-display.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAGL,gBAAgB,EAChB,wBAAwB,GACzB,MAAM,yBAAyB,CAAC;AAEjC;;;;;GAKG;AACH,MAAM,UAAU,kBAAkB,CAAC,YAA0B;IAC3D,MAAM,KAAK,GAAG,gBAAgB,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;IACtD,OAAO,GAAG,KAAK,IAAI,YAAY,CAAC,KAAK,EAAE,CAAC;AAC1C,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,0BAA0B,CAAC,YAA0B;IACnE,MAAM,KAAK,GAAG,gBAAgB,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;IACtD,MAAM,IAAI,GAAG,wBAAwB,CAA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