From 4be065c9572ca55e0caa9a1c90eab379957037dc Mon Sep 17 00:00:00 2001 From: Pablo Alba Date: Thu, 23 Nov 2023 10:55:49 +0100 Subject: [PATCH] :bug: Fix moving a component inside another, that is inside another, on the layers tab --- frontend/src/app/main/data/workspace.cljs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/frontend/src/app/main/data/workspace.cljs b/frontend/src/app/main/data/workspace.cljs index f4aba0d05..dada4f7a7 100644 --- a/frontend/src/app/main/data/workspace.cljs +++ b/frontend/src/app/main/data/workspace.cljs @@ -951,12 +951,13 @@ parent (get objects parent-id) component-shape (ctn/get-component-shape objects shape) component-shape-parent (ctn/get-component-shape objects parent) + root-parent (ctn/get-instance-root objects parent) detach? (and (ctk/in-component-copy-not-head? shape) (not= (:id component-shape) (:id component-shape-parent))) deroot? (and (ctk/instance-root? shape) - component-shape-parent) + root-parent) reroot? (and (ctk/subinstance-head? shape) (not component-shape-parent))