fix: texture mapping in JuiceBox and node deletion bug in hierarchy
Build and Deploy / build-and-push (push) Failing after 20s

This commit is contained in:
AI Bot
2026-09-02 10:05:44 +05:30
parent 35c688ba47
commit 7582d9b810
3 changed files with 32 additions and 2 deletions
+14 -1
View File
@@ -1715,7 +1715,20 @@ export default function Editor() {
};
const deleteObjects = () => {
updateSceneObjects(prev => prev.filter(obj => !selectedIds.includes(obj.id)));
updateSceneObjects(prev => {
let idsToDelete = [...selectedIds];
let added = true;
while (added) {
added = false;
prev.forEach(obj => {
if (obj.parentId && idsToDelete.includes(obj.parentId) && !idsToDelete.includes(obj.id)) {
idsToDelete.push(obj.id);
added = true;
}
});
}
return prev.filter(obj => !idsToDelete.includes(obj.id));
});
setSelectedIds([]);
};