feat: basic UI for merging sandboxes #3741
Open
+1,761
−389
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.
Description
This PR adds UI for the sandbox merging features to allow users to consolidate their work by merging one sandbox into another. This enables a Git-like workflow where developers can experiment in isolated sandboxes and then merge their changes back into a parent or sibling project.
Key Features
MergeProjects
moduleCloses #3426 #3744
Validation Steps
Basic Merge Flow
Descendant Warnings
root -> child1 -> grandchild1
child1
grandchild1
root -> child1 -> grandchild2
child1
againDeep Nesting
root -> child -> grandchild -> great-grandchild
child
Authorization
Edge Cases
Additional Notes for the Reviewer
Design Decisions
Why close descendants? When merging a sandbox, its descendants lose their parent context. Rather than orphaning them or moving them, we close them and warn the user to merge children first if they want to preserve that work.
Why only parent/siblings? Merging into a descendant would create a circular dependency in the project hierarchy. This restriction keeps the tree structure valid.
Authorization follows update/delete Merge is a destructive operation (deletes source sandbox) and modifies the target, so it requires the same permissions as update/delete operations.
Known Limitations
AI Usage
Please disclose how you've used AI in this work (it's cool, we just want to know!):
You can read more details in our Responsible AI Policy
Pre-submission Checklist
:owner
and:admin
can merge;:viewer
cannot)