Skip to content

Fix dragging layers into and out of groups - #158

Merged
git-chad merged 15 commits into
git-chad/shader-lab-v3-planfrom
git-chad/v3-group-drag-drop
Oct 1, 2026
Merged

git-chad merged 15 commits into
git-chad/shader-lab-v3-planfrom
git-chad/v3-group-drag-drop

Conversation

@git-chad

@git-chad git-chad commented Sep 17, 2026 •

Copy link
Copy Markdown
Collaborator

Dragging a child beyond its group previously changed its visual position without changing group membership. Layer handles now support reparenting and reordering in one atomic drop, so the visible hierarchy agrees with rendering and saved projects.

Group centers accept children (and open collapsed groups). Row edges mark before/after destinations; the left gutter lets a layer move to an ancestor level, including leaving the scene’s only group. Groups move with their complete subtrees. A group highlight/insertion line and destination message show the proposed move while the tree stays stable. Escape, lost capture, and releases outside the list cancel; long lists scroll near their edges. Invalid cycles, locked destinations, and excessive nesting are rejected. Existing keyboard menu/Properties alternatives remain available.

Stacked on #157 (git-chad/v3-displaced-rings), under V3 integration #150. Ring defaults are unchanged and remain for the user to tune. Nothing merges to main until V3 is complete.

Validation (CI validation/composition and preview deployment pass):

  • bun run check passes (three pre-existing local lint warnings).
  • bun run test:composition passes with new drop-state regression coverage, including atomic mutation, subtree ordering, collapsed targets, cycles/depth/locks, undo/redo, and real project hydration.
  • bun tests/composition/group-drag-ui.mjs passes against the local editor: desktop/mobile gestures, real touch input, drop feedback, nested/outdent moves, Escape/outside cancellation, long-list scrolling, UI undo/redo, and actual .lab download/import.

The pointer test runs against a local editor using SHADER_LAB_URL (default localhost:55000); store/hydration regressions run in the existing CI composition suite. Updated tests/composition/GROUPS-MANUAL-QA.md describes the focused user check. User acceptance is pending.

@vercel

vercel Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
shader-lab Ready Ready Preview Oct 1, 2026 7:05am UTC

@greptile-apps

greptile-apps Bot commented Sep 17, 2026

Copy link
Copy Markdown

RetriggerConfidence Score: 5/5

The PR appears safe to merge with no actionable correctness, security, or repository-rule violations identified.

Summary

This PR replaces sibling-only layer dragging with atomic group-aware reordering and reparenting.

  • Adds pointer-driven before, after, and inside drop targeting with cancellation and edge scrolling.
  • Moves complete group subtrees while validating cycles, locks, and nesting depth.
  • Connects drops to the layer store, history, persistence, and hierarchy feedback.
  • Adds store-level and browser-level regression coverage plus updated manual QA guidance.

Reviews (1) · Last reviewed commit: "Fix group-aware layer dragging and drop ..."

…roup failures

Media load callbacks now ignore replaced or removed passes and pending loads are cleared on disposal. Strict-mode pass failures are reported once at the originating pass instead of at every group boundary.
Publishing now drops every descendant of a hidden group and clears the
parentId of any retained layer (the audio source) whose parent was removed,
so the published scene passes hierarchy validation on reopen.
@git-chad
git-chad force-pushed the git-chad/v3-displaced-rings branch from 7f25982 to 72ee931 Compare October 1, 2026 07:04
@git-chad
git-chad force-pushed the git-chad/v3-group-drag-drop branch from 4e5a1de to 033eb38 Compare October 1, 2026 07:04
@git-chad
git-chad changed the base branch from git-chad/v3-displaced-rings to git-chad/shader-lab-v3-plan October 1, 2026 15:12
@git-chad
git-chad merged commit 033eb38 into git-chad/shader-lab-v3-plan Oct 1, 2026
5 checks passed

This branch was successfully deployed

1 active deployment
Preview — 033eb384 Deployed Oct 1, 2026 by vercel[bot]
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