fix(shortcuts): add focused editing and host undo/redo in 0.3.13 - #37
Merged
Conversation
lightninglu10
marked this pull request as ready for review
September 6, 2026 18:56
|
Starting initial review of |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes editing shortcuts from focused timeline clips and adds host-backed undo/redo in
@quantfive/freecut-editor-surface0.3.13. Delete/Backspace and C are eligible on the exact clip root outside dialogs; C falls back to the sole selected clip at the playhead when nothing is hovered. Editable targets, nested controls, ordinary buttons and dialogs stay protected.Embedded Cmd/Ctrl+Z and Cmd/Ctrl+Shift+Z call an optional
EditorHost.historyport. The host owns persistence, serialization and conflict handling, and supplies the resulting snapshot through its existing subscription. Freecut never rewinds its local temporal store in host mode; hosts without the port keep history shortcuts disabled. Standalone local undo remains available. The obsolete broader Z exemption was removed so nested controls and dialogs retain native undo.Release dependencies: merging this PR into
codepress-mainallows the existing trusted-publishing workflow to publish 0.3.13. CodePress's durable history backend is in quantfive/codepress#6428; quantfive/codepress#7026 shares its guarded history actions with the new port and prevents double keyboard dispatch. Both are unmerged dependencies. A package upgrade alone does not enable durable history in a host that lacks it. After publication, CodePress can pin 0.3.13, remove only the two original shortcut patch hunks and verify consumer integration. Tracks quantfive/codepress#7001; that issue remains open until adoption.Validation: 61 focused source tests passed across history, DOM guards, cuts and semantic clip accessibility. Added history regressions failed before the implementation. Six browser cases passed, including real Meta+Z and Control+Z plus Shift+Z redo: deleted clips stay absent until the controlled host emits its undo snapshot, return at their original ranges, and disappear again only after redo adoption. The browser fixture deliberately controls host receipts; these are package integration regressions, not a fresh live CodePress backend QA report. Full type/lint check passed across 2,499 files, and the 0.3.13 tarball builds and passes both installed-consumer tests. Provenance verification also passed during this PR.
The screenshot shows the fixture's deleted clip restored after host undo. Media resolution is disabled in this fixture; playback is not under test.