From 472904bd0bef661f9fc5366cdfd05c9d148ba513 Mon Sep 17 00:00:00 2001 From: Miguel Angel Simon Sierra Date: Sat, 19 Sep 2026 05:13:49 -0400 Subject: [PATCH 1/7] feat(scripts): flag a capture region that briefly returns to an older picture check-capture-reversion.mjs compares cropped, downscaled frames and reports a frame that differs between two matching frames within a window. Continuous motion is not flagged. Adds a unit test and a short section in CONTRIBUTING. --- CONTRIBUTING.md | 4 + package.json | 2 +- scripts/check-capture-reversion.mjs | 137 +++++++++++++++++++++++ scripts/check-capture-reversion.test.mjs | 32 ++++++ 4 files changed, 174 insertions(+), 1 deletion(-) create mode 100644 scripts/check-capture-reversion.mjs create mode 100644 scripts/check-capture-reversion.test.mjs diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 43025de04c..53ed8631ba 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -147,6 +147,10 @@ The script wipes `docs/catalog/` before regenerating, so deleted items are autom - CI must pass before merge (build, typecheck, tests, semantic PR title) - PRs require at least 1 approval +### Checking a capture + +A screen recording attached to a PR must not show a region briefly returning to an older picture (a clip that reappears for one frame, a panel that flashes its previous state). Run `node scripts/check-capture-reversion.mjs [--crop=W:H:X:Y]