@storyshelf/core 0.7.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (531) hide show
  1. package/dist/adapter/capture-queue.d.mts +0 -2
  2. package/dist/adapter/capture-runner.d.mts +9 -4
  3. package/dist/adapter/capture-runner.mjs +6 -2
  4. package/dist/adapter/database.d.mts +63 -3
  5. package/dist/adapter/database.mjs +4 -3
  6. package/dist/adapter/database.mjs.map +1 -1
  7. package/dist/adapter/design.d.mts +0 -2
  8. package/dist/adapter/design.mjs +1 -2
  9. package/dist/adapter/email-sender.d.mts +0 -2
  10. package/dist/adapter/metadata.d.mts +0 -2
  11. package/dist/adapter/oauth.d.mts +0 -2
  12. package/dist/adapter/setup.d.mts +0 -2
  13. package/dist/adapter/setup.mjs +1 -2
  14. package/dist/adapter/storage.d.mts +1 -3
  15. package/dist/adapter/webhook-events.d.mts +0 -2
  16. package/dist/adapter/webhook-events.mjs +12 -13
  17. package/dist/adapter/webhook-events.mjs.map +1 -1
  18. package/dist/adapters/capture-target-offers.d.mts +0 -2
  19. package/dist/adapters/capture-target-offers.mjs +1 -2
  20. package/dist/adapters/capture-target.d.mts +0 -2
  21. package/dist/adapters/capture-target.mjs +1 -2
  22. package/dist/adapters/notifier/build-comment.d.mts +0 -2
  23. package/dist/adapters/notifier/build-comment.mjs +1 -2
  24. package/dist/adapters/notifier/build-state.d.mts +0 -2
  25. package/dist/adapters/notifier/build-state.mjs +1 -2
  26. package/dist/adapters/notifier/events.d.mts +0 -2
  27. package/dist/adapters/notifier/events.mjs +1 -2
  28. package/dist/adapters/notifier/format.d.mts +0 -2
  29. package/dist/adapters/notifier/format.mjs +1 -2
  30. package/dist/adapters/notifier/provider.d.mts +0 -2
  31. package/dist/adapters/notifier/provider.mjs +1 -2
  32. package/dist/adapters/notifier/state.d.mts +0 -2
  33. package/dist/adapters/notifier/state.mjs +1 -2
  34. package/dist/adapters/notifier/types.d.mts +0 -2
  35. package/dist/adapters/remote-browser.d.mts +112 -31
  36. package/dist/adapters/remote-browser.mjs +132 -34
  37. package/dist/adapters/remote-browser.mjs.map +1 -1
  38. package/dist/adapters/remote-lease-attempt.mjs +39 -0
  39. package/dist/adapters/remote-lease-attempt.mjs.map +1 -0
  40. package/dist/adapters/remote-lease-error.d.mts +25 -0
  41. package/dist/adapters/remote-lease-error.mjs +54 -0
  42. package/dist/adapters/remote-lease-error.mjs.map +1 -0
  43. package/dist/adapters/remote-lease-held.d.mts +15 -0
  44. package/dist/adapters/remote-lease-held.mjs +86 -0
  45. package/dist/adapters/remote-lease-held.mjs.map +1 -0
  46. package/dist/adapters/remote-lease-shutdown.d.mts +12 -0
  47. package/dist/adapters/remote-lease-shutdown.mjs +32 -0
  48. package/dist/adapters/remote-lease-shutdown.mjs.map +1 -0
  49. package/dist/adapters/remote-lease.d.mts +39 -0
  50. package/dist/adapters/remote-lease.mjs +175 -0
  51. package/dist/adapters/remote-lease.mjs.map +1 -0
  52. package/dist/adapters/remote-limiter.mjs +121 -0
  53. package/dist/adapters/remote-limiter.mjs.map +1 -0
  54. package/dist/adapters/remote-pool.d.mts +56 -0
  55. package/dist/adapters/remote-pool.mjs +195 -0
  56. package/dist/adapters/remote-pool.mjs.map +1 -0
  57. package/dist/adapters/render-runs.d.mts +0 -2
  58. package/dist/adapters/render-runs.mjs +1 -2
  59. package/dist/adapters/setup-runner.d.mts +0 -2
  60. package/dist/adapters/setup-runner.mjs +1 -2
  61. package/dist/adapters/sources.d.mts +0 -2
  62. package/dist/adapters/sources.mjs +1 -2
  63. package/dist/adapters/validate.d.mts +0 -2
  64. package/dist/adapters/validate.mjs +2 -2
  65. package/dist/adapters/validate.mjs.map +1 -1
  66. package/dist/ai.d.mts +0 -2
  67. package/dist/ai.mjs +1 -2
  68. package/dist/auth.d.mts +0 -2
  69. package/dist/auth.mjs +1 -2
  70. package/dist/brand-packs.d.mts +0 -2
  71. package/dist/brand-packs.mjs +0 -1
  72. package/dist/capture/a11y/axe-source.d.mts +0 -2
  73. package/dist/capture/a11y/axe-source.mjs +1 -2
  74. package/dist/capture/a11y/in-page.d.mts +1 -3
  75. package/dist/capture/a11y/in-page.mjs +3 -4
  76. package/dist/capture/a11y/in-page.mjs.map +1 -1
  77. package/dist/capture/a11y/map.d.mts +0 -2
  78. package/dist/capture/a11y/map.mjs +1 -2
  79. package/dist/capture/a11y/options.d.mts +0 -2
  80. package/dist/capture/a11y/options.mjs +1 -2
  81. package/dist/capture/adapter.d.mts +5 -2
  82. package/dist/capture/adapter.mjs +1 -2
  83. package/dist/capture/adapter.mjs.map +1 -1
  84. package/dist/capture/affected.d.mts +0 -2
  85. package/dist/capture/affected.mjs +1 -2
  86. package/dist/capture/attempt-logger.mjs +1 -2
  87. package/dist/capture/browsers.d.mts +0 -2
  88. package/dist/capture/browsers.mjs +1 -2
  89. package/dist/capture/build-state/deliver.d.mts +0 -2
  90. package/dist/capture/build-state/deliver.mjs +1 -2
  91. package/dist/capture/build-state/notify-job.d.mts +0 -2
  92. package/dist/capture/build-state/notify-job.mjs +1 -2
  93. package/dist/capture/build-state/publisher.d.mts +0 -2
  94. package/dist/capture/build-state/publisher.mjs +1 -2
  95. package/dist/capture/build-state/resume.d.mts +0 -2
  96. package/dist/capture/build-state/resume.mjs +1 -2
  97. package/dist/capture/build-state/types.d.mts +1 -3
  98. package/dist/capture/catalog/catalogue.d.mts +0 -2
  99. package/dist/capture/catalog/catalogue.mjs +1 -2
  100. package/dist/capture/catalog/components.d.mts +0 -2
  101. package/dist/capture/catalog/components.mjs +1 -2
  102. package/dist/capture/catalog/history.d.mts +0 -2
  103. package/dist/capture/catalog/history.mjs +1 -2
  104. package/dist/capture/catalog/hook.d.mts +0 -2
  105. package/dist/capture/catalog/hook.mjs +1 -2
  106. package/dist/capture/catalog/index.d.mts +2 -2
  107. package/dist/capture/catalog/load.d.mts +0 -2
  108. package/dist/capture/catalog/load.mjs +1 -2
  109. package/dist/capture/catalog/parse.d.mts +0 -2
  110. package/dist/capture/catalog/parse.mjs +1 -2
  111. package/dist/capture/catalog/read.d.mts +6 -3
  112. package/dist/capture/catalog/read.mjs +14 -8
  113. package/dist/capture/catalog/read.mjs.map +1 -1
  114. package/dist/capture/catalog/types.d.mts +0 -2
  115. package/dist/capture/comparison-reference.d.mts +27 -0
  116. package/dist/capture/comparison-reference.mjs +75 -0
  117. package/dist/capture/comparison-reference.mjs.map +1 -0
  118. package/dist/capture/consumer/capture-handler.d.mts +1 -3
  119. package/dist/capture/consumer/capture-handler.mjs +1 -2
  120. package/dist/capture/consumer/idle.d.mts +0 -2
  121. package/dist/capture/consumer/idle.mjs +1 -2
  122. package/dist/capture/consumer/index.d.mts +0 -2
  123. package/dist/capture/consumer/index.mjs +1 -2
  124. package/dist/capture/consumer/loop.mjs +1 -2
  125. package/dist/capture/consumer/metrics.d.mts +0 -2
  126. package/dist/capture/consumer/metrics.mjs +1 -2
  127. package/dist/capture/consumer/retry.d.mts +0 -2
  128. package/dist/capture/consumer/retry.mjs +1 -2
  129. package/dist/capture/consumer/run-job.mjs +1 -2
  130. package/dist/capture/consumer/startup.mjs +1 -2
  131. package/dist/capture/consumer/types.d.mts +0 -2
  132. package/dist/capture/crash-failure.d.mts +0 -2
  133. package/dist/capture/crash-failure.mjs +1 -2
  134. package/dist/capture/db-queue/cadence.d.mts +0 -2
  135. package/dist/capture/db-queue/cadence.mjs +1 -2
  136. package/dist/capture/db-queue/claim.d.mts +0 -2
  137. package/dist/capture/db-queue/claim.mjs +20 -4
  138. package/dist/capture/db-queue/claim.mjs.map +1 -1
  139. package/dist/capture/db-queue/clock.mjs +1 -2
  140. package/dist/capture/db-queue/codec.mjs +1 -2
  141. package/dist/capture/db-queue/index.d.mts +0 -2
  142. package/dist/capture/db-queue/index.mjs +3 -3
  143. package/dist/capture/db-queue/index.mjs.map +1 -1
  144. package/dist/capture/db-queue/keeper.d.mts +0 -2
  145. package/dist/capture/db-queue/keeper.mjs +1 -2
  146. package/dist/capture/db-queue/lease.mjs +1 -2
  147. package/dist/capture/db-queue/lifecycle.mjs +1 -2
  148. package/dist/capture/db-queue/operations.mjs +1 -2
  149. package/dist/capture/db-queue/poll-loop.d.mts +0 -2
  150. package/dist/capture/db-queue/poll-loop.mjs +1 -2
  151. package/dist/capture/db-queue/poll.d.mts +0 -2
  152. package/dist/capture/db-queue/poll.mjs +1 -2
  153. package/dist/capture/db-queue/timers.d.mts +0 -2
  154. package/dist/capture/db-queue/timers.mjs +1 -2
  155. package/dist/capture/db-queue/types.d.mts +0 -2
  156. package/dist/capture/db-queue/types.mjs +1 -2
  157. package/dist/capture/db-queue/types.mjs.map +1 -1
  158. package/dist/capture/db-queue/wake.mjs +1 -2
  159. package/dist/capture/design.mjs +1 -2
  160. package/dist/capture/diff-record.mjs +1 -2
  161. package/dist/capture/dispatch.d.mts +1 -3
  162. package/dist/capture/dispatch.mjs +17 -5
  163. package/dist/capture/dispatch.mjs.map +1 -1
  164. package/dist/capture/enrich.mjs +1 -2
  165. package/dist/capture/failure-sets.mjs +1 -2
  166. package/dist/capture/fingerprint.d.mts +0 -2
  167. package/dist/capture/fingerprint.mjs +1 -2
  168. package/dist/capture/forked/channel.d.mts +0 -2
  169. package/dist/capture/forked/child.d.mts +0 -2
  170. package/dist/capture/forked/child.mjs +1 -2
  171. package/dist/capture/forked/crash-tracker.mjs +1 -2
  172. package/dist/capture/forked/decision.d.mts +0 -2
  173. package/dist/capture/forked/decision.mjs +1 -2
  174. package/dist/capture/forked/exit.mjs +1 -2
  175. package/dist/capture/forked/fork.d.mts +0 -2
  176. package/dist/capture/forked/fork.mjs +1 -2
  177. package/dist/capture/forked/forked-capture.d.mts +0 -2
  178. package/dist/capture/forked/forked-capture.mjs +1 -2
  179. package/dist/capture/forked/lease-book.mjs +1 -2
  180. package/dist/capture/forked/protocol.d.mts +0 -2
  181. package/dist/capture/forked/protocol.mjs +1 -2
  182. package/dist/capture/forked/runs.mjs +1 -2
  183. package/dist/capture/guards.mjs +1 -2
  184. package/dist/capture/ignore-regions.d.mts +36 -0
  185. package/dist/capture/ignore-regions.mjs +65 -0
  186. package/dist/capture/ignore-regions.mjs.map +1 -0
  187. package/dist/capture/isolate.mjs +1 -2
  188. package/dist/capture/job-lease.d.mts +0 -2
  189. package/dist/capture/job-lease.mjs +1 -2
  190. package/dist/capture/matrix.mjs +4 -4
  191. package/dist/capture/matrix.mjs.map +1 -1
  192. package/dist/capture/modes.d.mts +0 -2
  193. package/dist/capture/modes.mjs +2 -3
  194. package/dist/capture/modes.mjs.map +1 -1
  195. package/dist/capture/orchestrator.d.mts +0 -2
  196. package/dist/capture/orchestrator.mjs +2 -3
  197. package/dist/capture/pipeline.d.mts +0 -2
  198. package/dist/capture/pipeline.mjs +37 -6
  199. package/dist/capture/pipeline.mjs.map +1 -1
  200. package/dist/capture/progress.d.mts +0 -2
  201. package/dist/capture/progress.mjs +1 -2
  202. package/dist/capture/publish/accept.d.mts +0 -2
  203. package/dist/capture/publish/accept.mjs +1 -2
  204. package/dist/capture/publish/complete.d.mts +1 -3
  205. package/dist/capture/publish/complete.mjs +1 -2
  206. package/dist/capture/publish/extract.d.mts +0 -2
  207. package/dist/capture/publish/extract.mjs +6 -5
  208. package/dist/capture/publish/extract.mjs.map +1 -1
  209. package/dist/capture/publish/handler.d.mts +1 -3
  210. package/dist/capture/publish/handler.mjs +1 -2
  211. package/dist/capture/publish/index.d.mts +2 -1
  212. package/dist/capture/publish/invalid-zip.d.mts +8 -0
  213. package/dist/capture/publish/invalid-zip.mjs +11 -0
  214. package/dist/capture/publish/invalid-zip.mjs.map +1 -0
  215. package/dist/capture/publish/limits.d.mts +0 -2
  216. package/dist/capture/publish/limits.mjs +1 -2
  217. package/dist/capture/publish/published.d.mts +0 -2
  218. package/dist/capture/publish/published.mjs +1 -2
  219. package/dist/capture/publish/run.d.mts +1 -3
  220. package/dist/capture/publish/run.mjs +1 -2
  221. package/dist/capture/rediff.d.mts +1 -3
  222. package/dist/capture/rediff.mjs +19 -6
  223. package/dist/capture/rediff.mjs.map +1 -1
  224. package/dist/capture/render.mjs +1 -2
  225. package/dist/capture/render.mjs.map +1 -1
  226. package/dist/capture/scratch.d.mts +0 -2
  227. package/dist/capture/scratch.mjs +2 -4
  228. package/dist/capture/scratch.mjs.map +1 -1
  229. package/dist/capture/shard-plan.mjs +1 -2
  230. package/dist/capture/shards/context.mjs +3 -3
  231. package/dist/capture/shards/context.mjs.map +1 -1
  232. package/dist/capture/shards/execute.mjs +4 -3
  233. package/dist/capture/shards/execute.mjs.map +1 -1
  234. package/dist/capture/shards/fan-out.mjs +1 -2
  235. package/dist/capture/shards/history.mjs +1 -2
  236. package/dist/capture/shards/reduce.mjs +1 -2
  237. package/dist/capture/sizing.d.mts +0 -2
  238. package/dist/capture/sizing.mjs +1 -2
  239. package/dist/capture/skip-checks.mjs +1 -2
  240. package/dist/capture/statics.d.mts +0 -2
  241. package/dist/capture/statics.mjs +2 -4
  242. package/dist/capture/statics.mjs.map +1 -1
  243. package/dist/capture/storybook-urls.d.mts +0 -2
  244. package/dist/capture/storybook-urls.mjs +3 -3
  245. package/dist/capture/storybook-urls.mjs.map +1 -1
  246. package/dist/capture/storybook.d.mts +0 -2
  247. package/dist/capture/storybook.mjs +8 -4
  248. package/dist/capture/storybook.mjs.map +1 -1
  249. package/dist/capture/target.mjs +1 -2
  250. package/dist/capture/targets.d.mts +0 -2
  251. package/dist/capture/targets.mjs +1 -2
  252. package/dist/capture/tests.d.mts +0 -2
  253. package/dist/capture/tests.mjs +13 -3
  254. package/dist/capture/tests.mjs.map +1 -1
  255. package/dist/capture/token-chunks.mjs +24 -7
  256. package/dist/capture/token-chunks.mjs.map +1 -1
  257. package/dist/capture.d.mts +5 -2
  258. package/dist/capture.mjs +5 -2
  259. package/dist/config.d.mts +16 -3
  260. package/dist/config.mjs +6 -3
  261. package/dist/config.mjs.map +1 -1
  262. package/dist/diff.d.mts +0 -2
  263. package/dist/diff.mjs +1 -2
  264. package/dist/index.d.mts +2 -2
  265. package/dist/index.mjs +2 -2
  266. package/dist/insights/budget.d.mts +0 -2
  267. package/dist/insights/budget.mjs +1 -2
  268. package/dist/insights/envelope.d.mts +0 -2
  269. package/dist/insights/envelope.mjs +1 -2
  270. package/dist/insights/evidence-health.d.mts +0 -2
  271. package/dist/insights/evidence-health.mjs +1 -2
  272. package/dist/insights/evidence.d.mts +0 -2
  273. package/dist/insights/evidence.mjs +1 -2
  274. package/dist/insights/hash.d.mts +0 -2
  275. package/dist/insights/hash.mjs +1 -2
  276. package/dist/insights/limits.d.mts +0 -2
  277. package/dist/insights/limits.mjs +1 -2
  278. package/dist/insights/prompts/v1.d.mts +0 -2
  279. package/dist/insights/prompts/v1.mjs +1 -2
  280. package/dist/insights/redact.d.mts +0 -2
  281. package/dist/insights/redact.mjs +1 -2
  282. package/dist/insights/text.mjs +1 -2
  283. package/dist/logger.d.mts +0 -2
  284. package/dist/logger.mjs +1 -2
  285. package/dist/models/ai-budget-alert.d.mts +0 -2
  286. package/dist/models/ai-budget-alert.mjs +1 -2
  287. package/dist/models/ai-usage.d.mts +0 -2
  288. package/dist/models/ai-usage.mjs +1 -2
  289. package/dist/models/baseline-approval.d.mts +18 -0
  290. package/dist/models/baseline-approval.mjs +41 -0
  291. package/dist/models/baseline-approval.mjs.map +1 -0
  292. package/dist/models/baseline-archive.d.mts +0 -2
  293. package/dist/models/baseline-archive.mjs +1 -2
  294. package/dist/models/baseline-atomic.mjs +66 -0
  295. package/dist/models/baseline-atomic.mjs.map +1 -0
  296. package/dist/models/baseline-conflict.d.mts +6 -0
  297. package/dist/models/baseline-conflict.mjs +9 -0
  298. package/dist/models/baseline-conflict.mjs.map +1 -0
  299. package/dist/models/baseline-export.d.mts +0 -2
  300. package/dist/models/baseline-export.mjs +1 -2
  301. package/dist/models/baseline-import.mjs +1 -2
  302. package/dist/models/baseline-origin.d.mts +16 -0
  303. package/dist/models/baseline-origin.mjs +35 -0
  304. package/dist/models/baseline-origin.mjs.map +1 -0
  305. package/dist/models/baseline-status.d.mts +0 -2
  306. package/dist/models/baseline-status.mjs +1 -2
  307. package/dist/models/baseline-transfer.d.mts +1 -2
  308. package/dist/models/baseline-transfer.mjs +30 -2
  309. package/dist/models/baseline-transfer.mjs.map +1 -1
  310. package/dist/models/baseline.d.mts +5 -2
  311. package/dist/models/baseline.mjs +91 -12
  312. package/dist/models/baseline.mjs.map +1 -1
  313. package/dist/models/build-component.d.mts +0 -2
  314. package/dist/models/build-component.mjs +1 -2
  315. package/dist/models/build-review-status.d.mts +0 -2
  316. package/dist/models/build-review-status.mjs +1 -2
  317. package/dist/models/build-review.d.mts +0 -2
  318. package/dist/models/build-review.mjs +1 -2
  319. package/dist/models/build.d.mts +1 -3
  320. package/dist/models/build.mjs +14 -15
  321. package/dist/models/build.mjs.map +1 -1
  322. package/dist/models/capture-attempt.d.mts +0 -2
  323. package/dist/models/capture-attempt.mjs +1 -2
  324. package/dist/models/capture-job.d.mts +0 -2
  325. package/dist/models/capture-job.mjs +1 -2
  326. package/dist/models/capture-log.d.mts +0 -2
  327. package/dist/models/capture-log.mjs +1 -2
  328. package/dist/models/capture-shard.d.mts +0 -2
  329. package/dist/models/capture-shard.mjs +1 -2
  330. package/dist/models/changeset.d.mts +0 -2
  331. package/dist/models/changeset.mjs +1 -2
  332. package/dist/models/columns.mjs +1 -2
  333. package/dist/models/comment.d.mts +0 -2
  334. package/dist/models/comment.mjs +1 -2
  335. package/dist/models/component.d.mts +0 -2
  336. package/dist/models/component.mjs +1 -2
  337. package/dist/models/connections.d.mts +0 -2
  338. package/dist/models/connections.mjs +1 -2
  339. package/dist/models/content-ref.d.mts +0 -2
  340. package/dist/models/content-ref.mjs +1 -2
  341. package/dist/models/credentials.d.mts +0 -2
  342. package/dist/models/credentials.mjs +1 -2
  343. package/dist/models/design-credentials.d.mts +0 -2
  344. package/dist/models/design-credentials.mjs +1 -2
  345. package/dist/models/design-health.d.mts +0 -2
  346. package/dist/models/design-health.mjs +1 -2
  347. package/dist/models/design-nodes.d.mts +2 -4
  348. package/dist/models/design-nodes.mjs +1 -2
  349. package/dist/models/design-renders.mjs +1 -2
  350. package/dist/models/design-resolve.d.mts +0 -2
  351. package/dist/models/design-resolve.mjs +1 -2
  352. package/dist/models/design.d.mts +0 -2
  353. package/dist/models/design.mjs +1 -2
  354. package/dist/models/inherited-ratio.d.mts +0 -2
  355. package/dist/models/inherited-ratio.mjs +1 -2
  356. package/dist/models/insight.d.mts +0 -2
  357. package/dist/models/insight.mjs +1 -2
  358. package/dist/models/label.d.mts +0 -2
  359. package/dist/models/label.mjs +1 -2
  360. package/dist/models/member.d.mts +0 -2
  361. package/dist/models/member.mjs +1 -2
  362. package/dist/models/notification-channel.d.mts +0 -2
  363. package/dist/models/notification-channel.mjs +1 -2
  364. package/dist/models/notification-subscription.d.mts +0 -2
  365. package/dist/models/notification-subscription.mjs +1 -2
  366. package/dist/models/project-group-mapping.d.mts +0 -2
  367. package/dist/models/project-group-mapping.mjs +1 -2
  368. package/dist/models/project.d.mts +0 -2
  369. package/dist/models/project.mjs +1 -2
  370. package/dist/models/public-origin.d.mts +0 -2
  371. package/dist/models/public-origin.mjs +1 -2
  372. package/dist/models/review-switch-off.d.mts +0 -2
  373. package/dist/models/review-switch-off.mjs +1 -2
  374. package/dist/models/site-settings.d.mts +0 -2
  375. package/dist/models/site-settings.mjs +1 -2
  376. package/dist/models/snapshot.d.mts +3 -2
  377. package/dist/models/snapshot.mjs +4 -2
  378. package/dist/models/snapshot.mjs.map +1 -1
  379. package/dist/models/token.d.mts +0 -2
  380. package/dist/models/token.mjs +1 -2
  381. package/dist/models/usage.d.mts +0 -2
  382. package/dist/models/usage.mjs +1 -2
  383. package/dist/models/user.d.mts +0 -2
  384. package/dist/models/user.mjs +1 -2
  385. package/dist/models/webhook.d.mts +0 -2
  386. package/dist/models/webhook.mjs +1 -2
  387. package/dist/models.d.mts +5 -2
  388. package/dist/models.mjs +5 -2
  389. package/dist/options.d.mts +0 -2
  390. package/dist/options.mjs +2 -4
  391. package/dist/options.mjs.map +1 -1
  392. package/dist/paths.d.mts +3 -3
  393. package/dist/paths.mjs +7 -3
  394. package/dist/paths.mjs.map +1 -1
  395. package/dist/retention/ai.d.mts +1 -3
  396. package/dist/retention/ai.mjs +0 -1
  397. package/dist/retention/pending.mjs +1 -2
  398. package/dist/retention/published-gzip-sweep.mjs +28 -0
  399. package/dist/retention/published-gzip-sweep.mjs.map +1 -0
  400. package/dist/retention/screenshot-sweep.d.mts +0 -2
  401. package/dist/retention/screenshot-sweep.mjs +1 -2
  402. package/dist/retention.d.mts +0 -2
  403. package/dist/retention.mjs +5 -2
  404. package/dist/retention.mjs.map +1 -1
  405. package/dist/schema/baseline.d.mts +2 -2
  406. package/dist/schema/build-component.d.mts +0 -2
  407. package/dist/schema/build-review.d.mts +0 -2
  408. package/dist/schema/build.d.mts +0 -2
  409. package/dist/schema/capture-attempt.d.mts +0 -2
  410. package/dist/schema/capture-job.d.mts +0 -2
  411. package/dist/schema/capture-shard.d.mts +0 -2
  412. package/dist/schema/comment.d.mts +0 -2
  413. package/dist/schema/connection.d.mts +0 -2
  414. package/dist/schema/content-ref.d.mts +0 -2
  415. package/dist/schema/design.d.mts +0 -2
  416. package/dist/schema/insight.d.mts +0 -2
  417. package/dist/schema/label.d.mts +0 -2
  418. package/dist/schema/member.d.mts +0 -2
  419. package/dist/schema/notification.d.mts +0 -2
  420. package/dist/schema/project-group-mapping.d.mts +0 -2
  421. package/dist/schema/project.d.mts +0 -2
  422. package/dist/schema/site-setting.d.mts +0 -2
  423. package/dist/schema/snapshot.d.mts +5 -2
  424. package/dist/schema/token.d.mts +0 -2
  425. package/dist/schema/usage.d.mts +0 -2
  426. package/dist/schema/user.d.mts +0 -2
  427. package/dist/schema/webhook.d.mts +0 -2
  428. package/dist/schema.d.mts +4 -6
  429. package/dist/serverless.d.mts +0 -2
  430. package/dist/serverless.mjs +1 -2
  431. package/dist/test-helpers/build-reference-contract.d.mts +14 -0
  432. package/dist/test-helpers/build-reference-contract.mjs +66 -0
  433. package/dist/test-helpers/build-reference-contract.mjs.map +1 -0
  434. package/dist/test-helpers/create-project.d.mts +0 -2
  435. package/dist/test-helpers/create-project.mjs +1 -2
  436. package/dist/test-helpers/database-contract.d.mts +0 -2
  437. package/dist/test-helpers/database-contract.mjs +37 -2
  438. package/dist/test-helpers/database-contract.mjs.map +1 -1
  439. package/dist/test-helpers/deferred.d.mts +0 -2
  440. package/dist/test-helpers/deferred.mjs +1 -2
  441. package/dist/test-helpers/design-contract.d.mts +0 -2
  442. package/dist/test-helpers/design-contract.mjs +1 -2
  443. package/dist/test-helpers/fake-adapters.d.mts +0 -2
  444. package/dist/test-helpers/fake-adapters.mjs +1 -2
  445. package/dist/test-helpers/fake-database.d.mts +0 -2
  446. package/dist/test-helpers/fake-database.mjs +7 -2
  447. package/dist/test-helpers/fake-database.mjs.map +1 -1
  448. package/dist/test-helpers/fake-design.d.mts +0 -2
  449. package/dist/test-helpers/fake-design.mjs +1 -2
  450. package/dist/test-helpers/fake-notifier.d.mts +0 -2
  451. package/dist/test-helpers/fake-notifier.mjs +1 -2
  452. package/dist/test-helpers/fake-storage.d.mts +0 -2
  453. package/dist/test-helpers/fake-storage.mjs +1 -2
  454. package/dist/test-helpers/fake-tables.mjs +5 -2
  455. package/dist/test-helpers/fake-tables.mjs.map +1 -1
  456. package/dist/test-helpers/manual-clock.d.mts +0 -2
  457. package/dist/test-helpers/manual-clock.mjs +1 -2
  458. package/dist/test-helpers/notifier-contract.d.mts +0 -2
  459. package/dist/test-helpers/notifier-contract.mjs +1 -2
  460. package/dist/test-helpers/queue-contract.d.mts +0 -2
  461. package/dist/test-helpers/queue-contract.mjs +1 -2
  462. package/dist/test-helpers/queue-multi-instance.d.mts +0 -2
  463. package/dist/test-helpers/queue-multi-instance.mjs +1 -2
  464. package/dist/test-helpers/runner-contract.d.mts +0 -2
  465. package/dist/test-helpers/runner-contract.mjs +1 -2
  466. package/dist/test-helpers/sql-chunks.mjs +2 -2
  467. package/dist/test-helpers/sql-chunks.mjs.map +1 -1
  468. package/dist/test-helpers/storage-contract.d.mts +0 -2
  469. package/dist/test-helpers/storage-contract.mjs +1 -2
  470. package/dist/test-helpers.d.mts +2 -1
  471. package/dist/test-helpers.mjs +2 -1
  472. package/dist/tracing.mjs +36 -6
  473. package/dist/tracing.mjs.map +1 -1
  474. package/dist/types.d.mts +0 -2
  475. package/dist/types.mjs +1 -2
  476. package/dist/urls.d.mts +0 -2
  477. package/dist/urls.mjs +1 -2
  478. package/dist/utils/adaptive-concurrency.d.mts +0 -2
  479. package/dist/utils/adaptive-concurrency.mjs +1 -2
  480. package/dist/utils/connect-retry.d.mts +2 -2
  481. package/dist/utils/connect-retry.mjs +2 -3
  482. package/dist/utils/connect-retry.mjs.map +1 -1
  483. package/dist/utils/encrypt.d.mts +0 -2
  484. package/dist/utils/encrypt.mjs +1 -2
  485. package/dist/utils/environment.d.mts +0 -2
  486. package/dist/utils/environment.mjs +1 -2
  487. package/dist/utils/hash.d.mts +0 -2
  488. package/dist/utils/hash.mjs +1 -2
  489. package/dist/utils/http.d.mts +13 -3
  490. package/dist/utils/http.mjs +79 -17
  491. package/dist/utils/http.mjs.map +1 -1
  492. package/dist/utils/map-adaptive.d.mts +0 -2
  493. package/dist/utils/map-adaptive.mjs +1 -2
  494. package/dist/utils/map-limit.d.mts +0 -2
  495. package/dist/utils/map-limit.mjs +1 -2
  496. package/dist/utils/mime.d.mts +0 -2
  497. package/dist/utils/mime.mjs +1 -2
  498. package/dist/utils/page-limiter.d.mts +0 -2
  499. package/dist/utils/page-limiter.mjs +1 -2
  500. package/dist/utils/path-security.d.mts +0 -2
  501. package/dist/utils/path-security.mjs +2 -4
  502. package/dist/utils/path-security.mjs.map +1 -1
  503. package/dist/utils/public-origin.d.mts +0 -2
  504. package/dist/utils/public-origin.mjs +1 -2
  505. package/dist/utils/redact.d.mts +0 -2
  506. package/dist/utils/redact.mjs +1 -2
  507. package/dist/utils/remote-environment.d.mts +40 -3
  508. package/dist/utils/remote-environment.mjs +52 -3
  509. package/dist/utils/remote-environment.mjs.map +1 -1
  510. package/dist/utils/resources.d.mts +0 -2
  511. package/dist/utils/resources.mjs +1 -2
  512. package/dist/utils/screenshot-store.d.mts +0 -2
  513. package/dist/utils/screenshot-store.mjs +1 -2
  514. package/dist/utils/session-gate.d.mts +7 -6
  515. package/dist/utils/session-gate.mjs +28 -12
  516. package/dist/utils/session-gate.mjs.map +1 -1
  517. package/dist/utils/storybook-token.d.mts +11 -3
  518. package/dist/utils/storybook-token.mjs +10 -9
  519. package/dist/utils/storybook-token.mjs.map +1 -1
  520. package/dist/utils/storybook-url.d.mts +0 -2
  521. package/dist/utils/storybook-url.mjs +1 -2
  522. package/dist/utils/timing.d.mts +0 -2
  523. package/dist/utils/timing.mjs +1 -2
  524. package/dist/utils/ulid.d.mts +0 -2
  525. package/dist/utils/ulid.mjs +1 -2
  526. package/dist/utils/zip-read.mjs +1 -2
  527. package/dist/utils/zip-write.d.mts +0 -2
  528. package/dist/utils/zip-write.mjs +1 -2
  529. package/dist/utils.d.mts +5 -5
  530. package/dist/utils.mjs +5 -5
  531. package/package.json +6 -6
@@ -1,7 +1,7 @@
1
1
  import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
- //#region src/models/content-ref.ts
4
+ // src/models/content-ref.ts
5
5
  /** Content refs for deduplicated Storybook assets. */
6
6
  var ContentRefModel = class {
7
7
  tables;
@@ -43,7 +43,6 @@ var ContentRefModel = class {
43
43
  return (await this.db.list(this.tables.contentRefs)).filter((r) => r.refCount === 0 && r.lastSeenAt < cutoff);
44
44
  }
45
45
  };
46
- //#endregion
47
46
  export { ContentRefModel };
48
47
 
49
48
  //# sourceMappingURL=content-ref.mjs.map
@@ -2,7 +2,6 @@ import __tsdown_shims_path from 'node:path';
2
2
  import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { SecretKeys } from "../utils/encrypt.mjs";
5
- //#region src/models/credentials.d.ts
6
5
  /** A row no configured key can decrypt. */
7
6
  interface UnreadableCredential {
8
7
  source: string;
@@ -31,6 +30,5 @@ declare function probeCredentials(db: DatabaseAdapter, keys: SecretKeys): Promis
31
30
  * write does not stop the rest.
32
31
  */
33
32
  declare function reencryptCredentials(db: DatabaseAdapter, keys: SecretKeys): Promise<ReencryptResult>;
34
- //#endregion
35
33
  export { CredentialProbe, ReencryptResult, UnreadableCredential, probeCredentials, reencryptCredentials };
36
34
  //# sourceMappingURL=credentials.d.mts.map
@@ -2,7 +2,7 @@ import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
4
  import { decryptWithKey, encrypt } from "../utils/encrypt.mjs";
5
- //#region src/models/credentials.ts
5
+ // src/models/credentials.ts
6
6
  /** Tables that hold encrypted credentials, with the column to read. */
7
7
  const SOURCES = [
8
8
  {
@@ -107,7 +107,6 @@ async function reencryptOne(db, keys, item) {
107
107
  return { state: "failed" };
108
108
  }
109
109
  }
110
- //#endregion
111
110
  export { probeCredentials, reencryptCredentials };
112
111
 
113
112
  //# sourceMappingURL=credentials.mjs.map
@@ -5,7 +5,6 @@ import { SecretInput } from "../utils/encrypt.mjs";
5
5
  import { DesignCredential } from "../schema/design.mjs";
6
6
  import { DesignCredentialStatus } from "./design-resolve.mjs";
7
7
  import { Table } from "drizzle-orm";
8
- //#region src/models/design-credentials.d.ts
9
8
  /** Tables required by {@link DesignCredentialModel}. */
10
9
  interface DesignCredentialTables {
11
10
  designCredentials: Table;
@@ -36,6 +35,5 @@ declare class DesignCredentialModel {
36
35
  recordStatus(projectId: string, provider: string, status: DesignCredentialStatus): Promise<void>;
37
36
  private replace;
38
37
  }
39
- //#endregion
40
38
  export { DesignCredentialModel, DesignCredentialTables, PROJECT_SCOPE };
41
39
  //# sourceMappingURL=design-credentials.d.mts.map
@@ -5,7 +5,7 @@ import { decryptCredential, encrypt } from "../utils/encrypt.mjs";
5
5
  import { ulid } from "../utils/ulid.mjs";
6
6
  import { col } from "./columns.mjs";
7
7
  import { and, eq } from "drizzle-orm";
8
- //#region src/models/design-credentials.ts
8
+ // src/models/design-credentials.ts
9
9
  /** Encrypted design-provider credentials: the project-wide token an admin pastes. */
10
10
  /** Cache scope of the shared project credential (`design_nodes.viewer_id`); a user id marks a member's own connection. */
11
11
  const PROJECT_SCOPE = "";
@@ -80,7 +80,6 @@ var DesignCredentialModel = class {
80
80
  return true;
81
81
  }
82
82
  };
83
- //#endregion
84
83
  export { DesignCredentialModel, PROJECT_SCOPE };
85
84
 
86
85
  //# sourceMappingURL=design-credentials.mjs.map
@@ -1,7 +1,6 @@
1
1
  import __tsdown_shims_path from 'node:path';
2
2
  import __tsdown_shims_url from 'node:url';
3
3
  import { DesignNode } from "../schema/design.mjs";
4
- //#region src/models/design-health.d.ts
5
4
  /** Cached metadata younger than this is served without a refetch. */
6
5
  declare const DESIGN_TTL_MS: number;
7
6
  /** True when the design changed after the baseline it is compared with was approved. */
@@ -11,6 +10,5 @@ declare function isDesignStale(node: Pick<DesignNode, "state" | "lastModified">
11
10
  * past). `issuedAt` is when the credential was set or replaced — never a status write.
12
11
  */
13
12
  declare function credentialDaysLeft(issuedAt: string, maxAgeDays: number, now?: Date): number;
14
- //#endregion
15
13
  export { DESIGN_TTL_MS, credentialDaysLeft, isDesignStale };
16
14
  //# sourceMappingURL=design-health.d.mts.map
@@ -1,7 +1,7 @@
1
1
  import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
- //#region src/models/design-health.ts
4
+ // src/models/design-health.ts
5
5
  /** Cached metadata younger than this is served without a refetch. */
6
6
  const DESIGN_TTL_MS = 9e5;
7
7
  /** True when the design changed after the baseline it is compared with was approved. */
@@ -19,7 +19,6 @@ function credentialDaysLeft(issuedAt, maxAgeDays, now = /* @__PURE__ */ new Date
19
19
  const ageDays = (now.getTime() - Date.parse(issuedAt)) / 864e5;
20
20
  return Math.ceil(maxAgeDays - ageDays);
21
21
  }
22
- //#endregion
23
22
  export { DESIGN_TTL_MS, credentialDaysLeft, isDesignStale };
24
23
 
25
24
  //# sourceMappingURL=design-health.mjs.map
@@ -1,15 +1,14 @@
1
1
  import __tsdown_shims_path from 'node:path';
2
2
  import __tsdown_shims_url from 'node:url';
3
- import { DatabaseAdapter } from "../adapter/database.mjs";
4
3
  import { Logger } from "../logger.mjs";
4
+ import { DatabaseAdapter } from "../adapter/database.mjs";
5
5
  import { DesignProvider } from "../adapter/design.mjs";
6
6
  import { StorageAdapter } from "../adapter/storage.mjs";
7
- import { ConnectionModel } from "./connections.mjs";
8
7
  import { DesignNode } from "../schema/design.mjs";
8
+ import { ConnectionModel } from "./connections.mjs";
9
9
  import { DesignCredentialModel } from "./design-credentials.mjs";
10
10
  import { Table } from "drizzle-orm";
11
11
  import { Buffer } from "node:buffer";
12
- //#region src/models/design-nodes.d.ts
13
12
  /** Tables required by {@link DesignNodeModel}. */
14
13
  interface DesignNodeTables {
15
14
  designNodes: Table;
@@ -78,6 +77,5 @@ declare class DesignNodeModel {
78
77
  */
79
78
  private store;
80
79
  }
81
- //#endregion
82
80
  export { DesignNodeModel, DesignNodeTables, RefreshOptions };
83
81
  //# sourceMappingURL=design-nodes.d.mts.map
@@ -9,7 +9,7 @@ import "./design-credentials.mjs";
9
9
  import "./design-health.mjs";
10
10
  import { DesignRenderStore } from "./design-renders.mjs";
11
11
  import { and, eq } from "drizzle-orm";
12
- //#region src/models/design-nodes.ts
12
+ // src/models/design-nodes.ts
13
13
  /** Design metadata + render cache: TTL refresh, batched per file, bounded concurrency, abortable. */
14
14
  /** Most files refreshed in parallel by one {@link DesignNodeModel.refreshMany} call. */
15
15
  const FILE_CONCURRENCY = 3;
@@ -216,7 +216,6 @@ async function memo(cache, key, load) {
216
216
  cache.set(key, created);
217
217
  return await created;
218
218
  }
219
- //#endregion
220
219
  export { DesignNodeModel };
221
220
 
222
221
  //# sourceMappingURL=design-nodes.mjs.map
@@ -2,7 +2,7 @@ import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
4
  import { designRenderPath } from "../paths.mjs";
5
- //#region src/models/design-renders.ts
5
+ // src/models/design-renders.ts
6
6
  /**
7
7
  * Renders live at `{projectId}/design/{provider}/{fileKey}/{node}.png` (a member's own
8
8
  * connection: `…/{provider}/user-{id}/{fileKey}/…`), one per
@@ -68,7 +68,6 @@ var DesignRenderStore = class {
68
68
  function needsRender(node) {
69
69
  return node.state === "ok" && node.nodeId !== "" && node.version !== null && node.renderVersion !== node.version;
70
70
  }
71
- //#endregion
72
71
  export { DesignRenderStore };
73
72
 
74
73
  //# sourceMappingURL=design-renders.mjs.map
@@ -1,7 +1,6 @@
1
1
  import __tsdown_shims_path from 'node:path';
2
2
  import __tsdown_shims_url from 'node:url';
3
3
  import { DesignLink } from "../schema/design.mjs";
4
- //#region src/models/design-resolve.d.ts
5
4
  /** Last observed health of a design credential. */
6
5
  type DesignCredentialStatus = "unknown" | "ok" | "unauthorized" | "forbidden";
7
6
  /** Where a component's resolved design link came from. */
@@ -24,6 +23,5 @@ declare function resolveDesigns(manual: readonly Pick<DesignLink, "importPath" |
24
23
  storyImportPath: string | null;
25
24
  designUrl?: string | null;
26
25
  }[]): Map<string, DesignResolution>;
27
- //#endregion
28
26
  export { DesignCredentialStatus, DesignResolution, DesignSource, normalizeImportPath, resolveDesigns };
29
27
  //# sourceMappingURL=design-resolve.d.mts.map
@@ -1,7 +1,7 @@
1
1
  import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
- //#region src/models/design-resolve.ts
4
+ // src/models/design-resolve.ts
5
5
  /** Story-file key: path without a leading `./`, so index and manual entries compare equal. */
6
6
  function normalizeImportPath(path) {
7
7
  return path.trim().replace(/^(?:\.\/)+/u, "");
@@ -35,7 +35,6 @@ function storyDesigns(snapshots) {
35
35
  }
36
36
  return resolved;
37
37
  }
38
- //#endregion
39
38
  export { normalizeImportPath, resolveDesigns };
40
39
 
41
40
  //# sourceMappingURL=design-resolve.mjs.map
@@ -4,7 +4,6 @@ import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { DesignProvider } from "../adapter/design.mjs";
5
5
  import { DesignLink } from "../schema/design.mjs";
6
6
  import { Table } from "drizzle-orm";
7
- //#region src/models/design.d.ts
8
7
  /** Tables required by {@link DesignModel}. */
9
8
  interface DesignTables {
10
9
  designLinks: Table;
@@ -34,6 +33,5 @@ declare class DesignModel {
34
33
  private links;
35
34
  private insertLink;
36
35
  }
37
- //#endregion
38
36
  export { DesignModel, DesignTables };
39
37
  //# sourceMappingURL=design.d.mts.map
@@ -6,7 +6,7 @@ import { ulid } from "../utils/ulid.mjs";
6
6
  import { col } from "./columns.mjs";
7
7
  import { normalizeImportPath } from "./design-resolve.mjs";
8
8
  import { eq } from "drizzle-orm";
9
- //#region src/models/design.ts
9
+ // src/models/design.ts
10
10
  /** Design-source links: project-level design files and per-component (story file) mappings. */
11
11
  /** Data operations for design links; URLs are validated by the configured providers. */
12
12
  var DesignModel = class {
@@ -84,7 +84,6 @@ var DesignModel = class {
84
84
  });
85
85
  }
86
86
  };
87
- //#endregion
88
87
  export { DesignModel };
89
88
 
90
89
  //# sourceMappingURL=design.mjs.map
@@ -1,7 +1,6 @@
1
1
  import __tsdown_shims_path from 'node:path';
2
2
  import __tsdown_shims_url from 'node:url';
3
3
  import { Build } from "../schema/build.mjs";
4
- //#region src/models/inherited-ratio.d.ts
5
4
  /** Builds the average looks at by default (newest first). */
6
5
  declare const RECENT_BUILDS_FOR_INHERITED_RATIO = 20;
7
6
  /** The average inherited ratio of a project's recent builds. */
@@ -16,6 +15,5 @@ interface InheritedRatio {
16
15
  * does (no data is not a 0 % skip rate). A build with no snapshots has no ratio and is skipped.
17
16
  */
18
17
  declare function averageInheritedRatio(builds: readonly Pick<Build, "createdAt" | "snapshotCount" | "inheritedCount">[], limit?: number): InheritedRatio | null;
19
- //#endregion
20
18
  export { InheritedRatio, RECENT_BUILDS_FOR_INHERITED_RATIO, averageInheritedRatio };
21
19
  //# sourceMappingURL=inherited-ratio.d.mts.map
@@ -1,7 +1,7 @@
1
1
  import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
- //#region src/models/inherited-ratio.ts
4
+ // src/models/inherited-ratio.ts
5
5
  /** Builds the average looks at by default (newest first). */
6
6
  const RECENT_BUILDS_FOR_INHERITED_RATIO = 20;
7
7
  /**
@@ -16,7 +16,6 @@ function averageInheritedRatio(builds, limit = 20) {
16
16
  builds: recent.length
17
17
  };
18
18
  }
19
- //#endregion
20
19
  export { RECENT_BUILDS_FOR_INHERITED_RATIO, averageInheritedRatio };
21
20
 
22
21
  //# sourceMappingURL=inherited-ratio.mjs.map
@@ -3,7 +3,6 @@ import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { InsightKind, InsightRow } from "../schema/insight.mjs";
5
5
  import { Table } from "drizzle-orm";
6
- //#region src/models/insight.d.ts
7
6
  /** Tables required by {@link InsightModel}. */
8
7
  interface InsightTables {
9
8
  insights: Table;
@@ -65,6 +64,5 @@ declare class InsightModel {
65
64
  private restartIfNeeded;
66
65
  private col;
67
66
  }
68
- //#endregion
69
67
  export { InsightModel, InsightResultInput, InsightStartInput, InsightStartResult, InsightTables };
70
68
  //# sourceMappingURL=insight.d.mts.map
@@ -4,7 +4,7 @@ import.meta.url;
4
4
  import { ulid } from "../utils/ulid.mjs";
5
5
  import { col } from "./columns.mjs";
6
6
  import { and, asc, desc, eq, inArray, isNull, lt } from "drizzle-orm";
7
- //#region src/models/insight.ts
7
+ // src/models/insight.ts
8
8
  /** Insight rows: pending/running/done/failed runs with dedupe by unique key. */
9
9
  /** Data operations for insights. */
10
10
  var InsightModel = class {
@@ -156,7 +156,6 @@ function pick(input) {
156
156
  promptVersion: input.promptVersion
157
157
  };
158
158
  }
159
- //#endregion
160
159
  export { InsightModel };
161
160
 
162
161
  //# sourceMappingURL=insight.mjs.map
@@ -3,7 +3,6 @@ import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { BuildLabel, LabelType } from "../schema/label.mjs";
5
5
  import { Table } from "drizzle-orm";
6
- //#region src/models/label.d.ts
7
6
  /** Tables required by {@link LabelModel}. */
8
7
  interface LabelTables {
9
8
  builds: Table;
@@ -55,6 +54,5 @@ declare class LabelModel {
55
54
  /** Ids of the project's builds marked persistent (exempt from retention). */
56
55
  persistentBuildIds(projectId: string): Promise<Set<string>>;
57
56
  }
58
- //#endregion
59
57
  export { LabelModel, LabelTables };
60
58
  //# sourceMappingURL=label.d.mts.map
@@ -5,7 +5,7 @@ import { PERSISTENT_LABEL_KEY, RESERVED_LABEL_KEYS, SEEDED_LABEL_KEYS } from "..
5
5
  import { ulid } from "../utils/ulid.mjs";
6
6
  import { col } from "./columns.mjs";
7
7
  import { and, desc, eq, inArray } from "drizzle-orm";
8
- //#region src/models/label.ts
8
+ // src/models/label.ts
9
9
  /** Build labels and project label types. */
10
10
  /** Data operations for label types and build labels. */
11
11
  var LabelModel = class {
@@ -134,7 +134,6 @@ const SEEDED_LINK_TEMPLATES = {
134
134
  pr: "https://github.com/{repo}/pull/{value}",
135
135
  mr: "https://gitlab.com/{repo}/-/merge_requests/{value}"
136
136
  };
137
- //#endregion
138
137
  export { LabelModel };
139
138
 
140
139
  //# sourceMappingURL=label.mjs.map
@@ -4,7 +4,6 @@ import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { ProjectRole, SiteRole } from "../types.mjs";
5
5
  import { ProjectMember } from "../schema/member.mjs";
6
6
  import { Table } from "drizzle-orm";
7
- //#region src/models/member.d.ts
8
7
  /** Tables required by {@link MemberModel}. */
9
8
  interface MemberTables {
10
9
  projectMembers: Table;
@@ -29,6 +28,5 @@ declare class MemberModel {
29
28
  /** Resolve a user's effective project role, honoring site-wide admins. */
30
29
  effectiveRole(siteRole: SiteRole, projectId: string, userId: string): Promise<ProjectRole | null>;
31
30
  }
32
- //#endregion
33
31
  export { MemberModel, MemberTables };
34
32
  //# sourceMappingURL=member.d.mts.map
@@ -4,7 +4,7 @@ import.meta.url;
4
4
  import { ulid } from "../utils/ulid.mjs";
5
5
  import { col } from "./columns.mjs";
6
6
  import { and, eq } from "drizzle-orm";
7
- //#region src/models/member.ts
7
+ // src/models/member.ts
8
8
  /** Project membership and role resolution. */
9
9
  /** Data operations for project membership and roles. */
10
10
  var MemberModel = class {
@@ -59,7 +59,6 @@ var MemberModel = class {
59
59
  return null;
60
60
  }
61
61
  };
62
- //#endregion
63
62
  export { MemberModel };
64
63
 
65
64
  //# sourceMappingURL=member.mjs.map
@@ -6,7 +6,6 @@ import { NotifierProvider } from "../adapters/notifier/provider.mjs";
6
6
  import { SecretInput } from "../utils/encrypt.mjs";
7
7
  import { NotificationChannelRow } from "../schema/notification.mjs";
8
8
  import { Table } from "drizzle-orm";
9
- //#region src/models/notification-channel.d.ts
10
9
  /** Tables required by {@link NotificationChannelModel}. */
11
10
  interface NotificationChannelTables {
12
11
  notificationChannels: Table;
@@ -81,6 +80,5 @@ declare class NotificationChannelModel {
81
80
  /** Decode the JSON-serialized config of a channel. */
82
81
  static configOf(row: NotificationChannelRow): Record<string, unknown>;
83
82
  }
84
- //#endregion
85
83
  export { ChannelValidation, NotificationChannelCreateInput, NotificationChannelModel, NotificationChannelTables };
86
84
  //# sourceMappingURL=notification-channel.d.mts.map
@@ -6,7 +6,7 @@ import { ulid } from "../utils/ulid.mjs";
6
6
  import { col } from "./columns.mjs";
7
7
  import { isStateProvider } from "../adapters/notifier/provider.mjs";
8
8
  import { eq, isNull } from "drizzle-orm";
9
- //#region src/models/notification-channel.ts
9
+ // src/models/notification-channel.ts
10
10
  /** Project and site-wide notification channel subscriptions. */
11
11
  /** Data operations for notification channels. */
12
12
  var NotificationChannelModel = class NotificationChannelModel {
@@ -166,7 +166,6 @@ function decodeEvents(raw) {
166
166
  return [];
167
167
  }
168
168
  }
169
- //#endregion
170
169
  export { NotificationChannelModel };
171
170
 
172
171
  //# sourceMappingURL=notification-channel.mjs.map
@@ -3,7 +3,6 @@ import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { NotificationSubscriptionRow } from "../schema/notification.mjs";
5
5
  import { Table } from "drizzle-orm";
6
- //#region src/models/notification-subscription.d.ts
7
6
  /** Tables required by {@link NotificationSubscriptionModel}. */
8
7
  interface NotificationSubscriptionTables {
9
8
  notificationSubscriptions: Table;
@@ -38,6 +37,5 @@ declare class NotificationSubscriptionModel {
38
37
  /** Decode the JSON-serialized channel list of a subscription. */
39
38
  static viaOf(row: NotificationSubscriptionRow): string[];
40
39
  }
41
- //#endregion
42
40
  export { NotificationSubscriptionInput, NotificationSubscriptionModel, NotificationSubscriptionTables };
43
41
  //# sourceMappingURL=notification-subscription.d.mts.map
@@ -4,7 +4,7 @@ import.meta.url;
4
4
  import { ulid } from "../utils/ulid.mjs";
5
5
  import { col } from "./columns.mjs";
6
6
  import { and, eq } from "drizzle-orm";
7
- //#region src/models/notification-subscription.ts
7
+ // src/models/notification-subscription.ts
8
8
  /** Per-user opt-in rows for project notifications. */
9
9
  /** Data operations for per-user notification subscriptions. */
10
10
  var NotificationSubscriptionModel = class {
@@ -81,7 +81,6 @@ function decodeList(raw) {
81
81
  return [];
82
82
  }
83
83
  }
84
- //#endregion
85
84
  export { NotificationSubscriptionModel };
86
85
 
87
86
  //# sourceMappingURL=notification-subscription.mjs.map
@@ -4,7 +4,6 @@ import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { ProjectRole } from "../types.mjs";
5
5
  import { ProjectGroupMapping } from "../schema/project-group-mapping.mjs";
6
6
  import { Table } from "drizzle-orm";
7
- //#region src/models/project-group-mapping.d.ts
8
7
  /** Tables required by {@link ProjectGroupMappingModel}. */
9
8
  interface ProjectGroupMappingTables {
10
9
  projectGroupMappings: Table;
@@ -30,6 +29,5 @@ declare class ProjectGroupMappingModel {
30
29
  /** Remove a group mapping by id within a project. */
31
30
  remove(projectId: string, id: string): Promise<void>;
32
31
  }
33
- //#endregion
34
32
  export { ProjectGroupMappingModel, ProjectGroupMappingTables };
35
33
  //# sourceMappingURL=project-group-mapping.d.mts.map
@@ -5,7 +5,7 @@ import { isProjectRole } from "../types.mjs";
5
5
  import { ulid } from "../utils/ulid.mjs";
6
6
  import { col } from "./columns.mjs";
7
7
  import { and, eq } from "drizzle-orm";
8
- //#region src/models/project-group-mapping.ts
8
+ // src/models/project-group-mapping.ts
9
9
  /** Project group-to-role mappings for OIDC team sync. */
10
10
  /** Data operations for identity-provider group mappings. */
11
11
  var ProjectGroupMappingModel = class {
@@ -50,7 +50,6 @@ var ProjectGroupMappingModel = class {
50
50
  if (rows[0]) await this.db.remove(this.tables.projectGroupMappings, rows[0].id);
51
51
  }
52
52
  };
53
- //#endregion
54
53
  export { ProjectGroupMappingModel };
55
54
 
56
55
  //# sourceMappingURL=project-group-mapping.mjs.map
@@ -3,7 +3,6 @@ import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { Project } from "../schema/project.mjs";
5
5
  import { Table } from "drizzle-orm";
6
- //#region src/models/project.d.ts
7
6
  /** Tables required by {@link ProjectModel}. */
8
7
  interface ProjectTables {
9
8
  projects: Table;
@@ -57,6 +56,5 @@ interface ProjectCreateInput {
57
56
  /** Approvals a build needs with `testing` off (column default 1 when omitted). */
58
57
  reviewApprovals?: number;
59
58
  }
60
- //#endregion
61
59
  export { ProjectCreateInput, ProjectModel, ProjectTables };
62
60
  //# sourceMappingURL=project.d.mts.map
@@ -4,7 +4,7 @@ import.meta.url;
4
4
  import { slugify, ulid } from "../utils/ulid.mjs";
5
5
  import { col } from "./columns.mjs";
6
6
  import { eq } from "drizzle-orm";
7
- //#region src/models/project.ts
7
+ // src/models/project.ts
8
8
  /** Project records and slug management. */
9
9
  /** Data operations for project records. */
10
10
  var ProjectModel = class {
@@ -82,7 +82,6 @@ var ProjectModel = class {
82
82
  return `${base}-${suffix}`;
83
83
  }
84
84
  };
85
- //#endregion
86
85
  export { ProjectModel };
87
86
 
88
87
  //# sourceMappingURL=project.mjs.map
@@ -3,7 +3,6 @@ import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { ShelfConfig } from "../config.mjs";
5
5
  import { Env } from "../utils/public-origin.mjs";
6
- //#region src/models/public-origin.d.ts
7
6
  /** Key of the stored origin in `site_settings`. */
8
7
  declare const PUBLIC_ORIGIN_KEY = "public_origin";
9
8
  /** Where the resolved origin came from. */
@@ -58,6 +57,5 @@ interface PublicOriginOptions {
58
57
  }
59
58
  /** Build the resolver for one app instance. */
60
59
  declare function createPublicOriginResolver(options: PublicOriginOptions): PublicOriginResolver;
61
- //#endregion
62
60
  export { PUBLIC_ORIGIN_KEY, PublicOriginOptions, PublicOriginResolver, PublicOriginSource, ResolvedPublicOrigin, StoredPublicOrigin, createPublicOriginResolver };
63
61
  //# sourceMappingURL=public-origin.d.mts.map
@@ -3,7 +3,7 @@ import "node:url";
3
3
  import.meta.url;
4
4
  import { detectPublicBaseUrl, normalizeOrigin } from "../utils/public-origin.mjs";
5
5
  import { SiteSettingsModel } from "./site-settings.mjs";
6
- //#region src/models/public-origin.ts
6
+ // src/models/public-origin.ts
7
7
  /** Key of the stored origin in `site_settings`. */
8
8
  const PUBLIC_ORIGIN_KEY = "public_origin";
9
9
  /** Build the resolver for one app instance. */
@@ -108,7 +108,6 @@ function parseStored(raw) {
108
108
  return null;
109
109
  }
110
110
  }
111
- //#endregion
112
111
  export { PUBLIC_ORIGIN_KEY, createPublicOriginResolver };
113
112
 
114
113
  //# sourceMappingURL=public-origin.mjs.map
@@ -2,13 +2,11 @@ import __tsdown_shims_path from 'node:path';
2
2
  import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { Build } from "../schema/build.mjs";
5
- //#region src/models/review-switch-off.d.ts
6
5
  /**
7
6
  * Accept the project's `pending` builds that have no capture attempts and no snapshots; resolves
8
7
  * to the builds it accepted. Builds a capture touched keep their status (snapshot approval decides
9
8
  * them), and a second run finds nothing left to do. No approval event is raised.
10
9
  */
11
10
  declare function acceptPendingWithoutWork(db: DatabaseAdapter, projectId: string): Promise<Build[]>;
12
- //#endregion
13
11
  export { acceptPendingWithoutWork };
14
12
  //# sourceMappingURL=review-switch-off.d.mts.map
@@ -4,7 +4,7 @@ import.meta.url;
4
4
  import { CaptureAttemptModel } from "./capture-attempt.mjs";
5
5
  import { BuildModel } from "./build.mjs";
6
6
  import { SnapshotModel } from "./snapshot.mjs";
7
- //#region src/models/review-switch-off.ts
7
+ // src/models/review-switch-off.ts
8
8
  /**
9
9
  * Accept the project's `pending` builds that have no capture attempts and no snapshots; resolves
10
10
  * to the builds it accepted. Builds a capture touched keep their status (snapshot approval decides
@@ -20,7 +20,6 @@ async function hasWork(db, buildId) {
20
20
  const [attempts, snapshots] = await Promise.all([new CaptureAttemptModel(db).listByBuild(buildId), new SnapshotModel(db).listByBuild(buildId)]);
21
21
  return attempts.length > 0 || snapshots.length > 0;
22
22
  }
23
- //#endregion
24
23
  export { acceptPendingWithoutWork };
25
24
 
26
25
  //# sourceMappingURL=review-switch-off.mjs.map
@@ -2,7 +2,6 @@ import __tsdown_shims_path from 'node:path';
2
2
  import __tsdown_shims_url from 'node:url';
3
3
  import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { Table } from "drizzle-orm";
5
- //#region src/models/site-settings.d.ts
6
5
  /** Tables required by {@link SiteSettingsModel}. */
7
6
  interface SiteSettingsTables {
8
7
  siteSettings: Table;
@@ -18,6 +17,5 @@ declare class SiteSettingsModel {
18
17
  /** Delete the setting; a no-op when it is absent. */
19
18
  remove(key: string): Promise<void>;
20
19
  }
21
- //#endregion
22
20
  export { SiteSettingsModel, SiteSettingsTables };
23
21
  //# sourceMappingURL=site-settings.d.mts.map
@@ -1,7 +1,7 @@
1
1
  import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
- //#region src/models/site-settings.ts
4
+ // src/models/site-settings.ts
5
5
  /** Data operations for `site_settings`, keyed by setting name. */
6
6
  var SiteSettingsModel = class {
7
7
  #db;
@@ -42,7 +42,6 @@ var SiteSettingsModel = class {
42
42
  await this.#db.remove(this.#table, key);
43
43
  }
44
44
  };
45
- //#endregion
46
45
  export { SiteSettingsModel };
47
46
 
48
47
  //# sourceMappingURL=site-settings.mjs.map
@@ -4,7 +4,6 @@ import { DatabaseAdapter } from "../adapter/database.mjs";
4
4
  import { SnapshotStatus } from "../types.mjs";
5
5
  import { Snapshot } from "../schema/snapshot.mjs";
6
6
  import { Table } from "drizzle-orm";
7
- //#region src/models/snapshot.d.ts
8
7
  /** Tables required by {@link SnapshotModel}. */
9
8
  interface SnapshotTables {
10
9
  snapshots: Table;
@@ -77,6 +76,9 @@ interface SnapshotCreateInput {
77
76
  /** JSON `EnvironmentChange` when accepted as an environment migration. */
78
77
  envChange?: string | null;
79
78
  inherited?: boolean;
79
+ sourceBuildId?: string | null;
80
+ comparisonImagePath?: string | null;
81
+ comparisonMetadata?: string | null;
80
82
  baselineId?: string | null;
81
83
  baselineVersion?: string | null;
82
84
  /** Resolved mode definition as JSON (display/capture only). */
@@ -88,6 +90,5 @@ interface SnapshotCreateInput {
88
90
  /** JSON array of axe violation texts found on this capture; null when none. */
89
91
  a11yViolations?: string | null;
90
92
  }
91
- //#endregion
92
93
  export { SnapshotCreateInput, SnapshotModel, SnapshotTables };
93
94
  //# sourceMappingURL=snapshot.d.mts.map