Skip to content

Commit 6643a6d

Browse files
fix: translate with hierarchy change on root
1 parent 212efc3 commit 6643a6d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

editor/grida-canvas/reducers/methods/transform.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,14 @@ import type { ReducerContext } from "..";
2121

2222
/**
2323
* Determines if a node type allows hierarchy changes during translation.
24-
* Container nodes allow children to escape/enter during translation.
24+
* Container nodes and scenes allow children to escape/enter during translation.
2525
* Group and boolean nodes do not allow hierarchy changes - children must stay within their parent.
2626
*/
2727
function allows_hierarchy_change(
2828
node_type: grida.program.nodes.NodeType
2929
): boolean {
3030
switch (node_type) {
31+
case "scene":
3132
case "container":
3233
return true;
3334
case "group":

0 commit comments

Comments
 (0)