Skip to content

Diff Checker: line/word diff engine, ignore toggles, copy as patch - #8

Merged
fadeltd merged 10 commits into
mainfrom
feat/diff-engine
Sep 28, 2026
Merged

fadeltd merged 10 commits into
mainfrom
feat/diff-engine

Conversation

@fadeltd

@fadeltd fadeltd commented Sep 28, 2026 •

Copy link
Copy Markdown
Owner

Added

  • Diff Checker: ignore whitespace, case, and leading/trailing whitespace
  • Copy as unified patch

Changed

  • Two-stage diff: lines first, then words within changed blocks; much faster on large or scattered edits
  • Stats count changed blocks of lines instead of character edits

@fadeltd
fadeltd merged commit 408ad92 into main Sep 28, 2026
1 check passed
@fadeltd
fadeltd deleted the feat/diff-engine branch September 28, 2026 04:14
fadeltd added a commit that referenced this pull request Oct 26, 2026
…ne (#9)

* Diff: scroll the side-by-side view with the wheel

.cm-mergeView is the one scroller for both panes. Fixed heights inside it kept
it from ever overflowing, so the content was clipped by the package's
overflow:hidden editor wrapper: the wheel did nothing and only the cursor could
move it. Use min-height instead.

* Diff: pin a reported config diff as a regression test

CodeMirror's built-in diff gave up on this pair and marked every line changed,
including the identical networking block. The two-stage engine gets it right;
keep it that way.

* Diff: copy the comparison as a share link

Both sides are deflated into the URL fragment, which browsers never send to a
server, so there is still no backend. Links are capped at 8 KB encoded, and
decoding stops at 2 MB so a crafted link cannot inflate without bound. The link
is encoded ahead of the click, since Safari refuses clipboard writes after an
await. Opening one replaces the saved diff, says so, and strips the fragment.

* Changelog: move the diff engine entries to Unreleased

#8 added its entries under [0.4.0], which had already been released, so the
release workflow found nothing to ship and the new engine never deployed.
Also record the scroll fix, the highlighting fix and share links.
@fadeltd fadeltd changed the title Diff: two-stage line/word engine, ignore toggles, copy as patch Diff Checker: line/word diff engine, ignore toggles, copy as patch Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant