Skip to content

fix(studio): harden composition timeline reliability#2615

Merged
miguel-heygen merged 9 commits into
mainfrom
codex/fix-studio-composition-reliability
Jul 17, 2026
Merged

fix(studio): harden composition timeline reliability#2615
miguel-heygen merged 9 commits into
mainfrom
codex/fix-studio-composition-reliability

Conversation

@miguel-heygen

@miguel-heygen miguel-heygen commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator

Summary

Composition editing in Studio is now much closer to the CapCut-style behavior Jake and Imad expected: whole comps can be moved, inserted, split, layered, and undone without the editor drifting into per-pixel history or editing the wrong nested layer.

This follow-up PR tightens the stack around the real failure modes from the Day 12 project:

  • dragging a comp from the Compositions tab can insert it at the playhead/timeline, with server-owned collision handling and cycle checks
  • dragging a comp onto an occupied lane can no longer resolve back to its origin as a silent no-op; it crosses the aimed lane in the intended direction
  • successful lane moves reassert their optimistic state and refresh the preview only after the complete lane + z transaction, so stale runtime manifests cannot make the move appear only after a browser refresh
  • moving expanded comp children no longer double-applies movement when the host is selected too
  • cuts are atomic across touched files, rollback cleanly if a later write fails, and give split composition hosts unique data-composition-id values
  • color, font-size, and numeric inspector gestures commit as one history entry instead of hundreds of one-pixel undo steps
  • text selection resolves to the paint/text element rather than the transparent mask frame around it
  • nested composition playback and playback-rate math stay canonical when trimming, splitting, or moving hosts

QA

  • pre-commit hook passed: filesize, lint, format, typecheck, tracked-artifact checks, and fallow gate
  • complete Studio suite: 2,703 tests passed (18 todo)
  • Studio Server mutation/insertion/routes suite: 87 tests passed
  • @hyperframes/studio and @hyperframes/studio-server typechecks passed
  • @hyperframes/studio production build passed
  • changed-file oxlint, oxfmt, and git diff --check passed
  • manual Codex in-browser QA with a clean copy of Day 12 HF Studio Intro.zip:
    • reproduced the stale-lane bug: disk had the correct new data-track-index values while the live timeline kept the old lanes until refresh
    • moved Headline through an occupied lane and verified the live lanes matched disk without a browser refresh
    • performed two more consecutive composition lane moves in the same Studio session; each converged after the transaction and matched the saved tracks
    • verified lane-move Undo and Redo against the saved data-track-index values
    • moved Headline horizontally and restored its authored data-start with one physical Cmd+Z
    • marquee-selected Headline + Lockup, moved both by 0.5s while Background stayed fixed, then restored both with one Cmd+Z
    • Razor-split a composition, Undo/Redo restored both states, and verified the slices use headline / headline-split without StaticGuard errors
    • inserted a colliding Headline composition at the playhead; it received a unique ID and a new track
    • final browser console error log was empty

The in-app pointer automation cannot synthesize a native HTML5 DataTransfer, so native card drag is covered by the Compositions card drag/drop contract tests; the same insertion transaction was exercised in-browser through the card's add-at-playhead action.


Compound Engineering
GPT-5

@miguel-heygen
miguel-heygen force-pushed the codex/fix-studio-composition-reliability branch from d16fa80 to 5d1249a Compare July 17, 2026 08:18
@miguel-heygen
miguel-heygen changed the base branch from fix/studio-interaction-consolidation to main July 17, 2026 08:18
@miguel-heygen
miguel-heygen force-pushed the codex/fix-studio-composition-reliability branch from 5d1249a to 143576a Compare July 17, 2026 16:12
@mintlify

mintlify Bot commented Jul 17, 2026

Copy link
Copy Markdown

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
hyperframes 🟢 Ready View Preview Jul 17, 2026, 4:13 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

Comment thread packages/studio-server/src/routes/files.ts Fixed
Comment thread packages/studio/src/utils/razorSplitTransaction.ts Fixed
Comment thread packages/studio/src/utils/razorSplitTransaction.ts Fixed
Comment thread packages/studio/src/utils/timelineCompositionInsert.ts Fixed
Comment thread packages/studio/src/utils/timelineCompositionInsert.ts Fixed
@mintlify

mintlify Bot commented Jul 17, 2026

Copy link
Copy Markdown

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
hyperframes 🟡 Building Jul 17, 2026, 4:12 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@miguel-heygen
miguel-heygen merged commit 2b65b4e into main Jul 17, 2026
53 checks passed
@miguel-heygen
miguel-heygen deleted the codex/fix-studio-composition-reliability branch July 17, 2026 18:15
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.

2 participants