Skip to content

fix: finalize source projection before unrelated document changes - #486

Merged
Azganoth merged 1 commit into
mainfrom
bug/finalize-source-projection
Sep 20, 2026
Merged

Azganoth merged 1 commit into
mainfrom
bug/finalize-source-projection

Conversation

@Azganoth

Copy link
Copy Markdown
Owner

Summary

  • Finalize an unchanged source projection when an unrelated document change moves selection outside its range, instead of dropping the session and leaving source literal.
  • Keep that external change in native history; the clean restore maps its undo and redo steps onto canonical content.
  • Cover document, selection, serialization, dirty tracking, undo, and redo against an explicit-finalize baseline.

Related Issue

Closes #472

Verification

  • pnpm exec vitest run src/features/editor/plugins/sourceProjection.test.ts — exercises source-projection behavior, including the new unrelated-change regression.
  • pnpm check:frontend — checks formatting, TypeScript, Oxlint, production build, and frontend coverage.
  • git diff --check — confirms no whitespace errors.

Not verified: manual desktop interaction or the desktop E2E suite.

@Azganoth Azganoth added the Bug Something isn't working label Sep 20, 2026
@Azganoth Azganoth self-assigned this Sep 20, 2026
@github-project-automation github-project-automation Bot moved this to Backlog in Leafdown Sep 20, 2026
@Azganoth
Azganoth enabled auto-merge (squash) September 20, 2026 17:05
@Azganoth
Azganoth merged commit 0bddf0a into main Sep 20, 2026
3 checks passed
@Azganoth
Azganoth deleted the bug/finalize-source-projection branch September 20, 2026 17:09
@github-project-automation github-project-automation Bot moved this from Backlog to Done in Leafdown Sep 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Bug Something isn't working

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Finalize an active source projection before an unrelated document change can abandon it

1 participant