Skip to content

fix: make moveWindow source-authoritative and atomic - #28

Open
ddebowczyk wants to merge 1 commit into
Jeshwin:mainfrom
ddebowczyk:fix/make-window-moves-atomic
Open

fix: make moveWindow source-authoritative and atomic#28
ddebowczyk wants to merge 1 commit into
Jeshwin:mainfrom
ddebowczyk:fix/make-window-moves-atomic

Conversation

@ddebowczyk

Copy link
Copy Markdown

Summary

  • Resolve and validate both move endpoints before mutating the source state.
  • Move the stored source window and ignore the deprecated caller-supplied window payload.
  • Reject stale tiled paths, malformed or unseeded new floating destinations, unsupported floating edge drops, and self-targeting tree moves.
  • Preserve valid tree, floating, and root-edge transfers while adjusting a destination after source removal.

Validation

  • npm test -- --run tests/moveWindow.test.ts tests/reducer.test.ts (39 passed)
  • NODE_OPTIONS=--localstorage-file=/tmp/react-layman-pr03-localstorage.json npm test (76 passed)
  • npx --no-install tsc --noEmit
  • npm run lint
  • npm run build:lib

Plain npm test has the known Node 26 localStorage setup failure in persistence tests. PR 04 owns that portable test setup.

@ddebowczyk
ddebowczyk force-pushed the fix/make-window-moves-atomic branch 2 times, most recently from ac6350f to 3061d08 Compare August 12, 2026 13:42
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