chore: update Angular cache and TypeScript build info files

This commit is contained in:
2025-09-30 21:37:49 -04:00
parent 81d7f1f7c2
commit fe4c968367
29 changed files with 2719 additions and 98 deletions
+12 -1
View File
@@ -265,12 +265,23 @@ export function moveNode(
// Can't move a node into itself or its descendants
if (newParentCtime !== null && isDescendant(found.node, newParentCtime)) {
console.warn('Cannot move a node into its own descendant');
return doc;
}
const nodeClone = cloneNode(found.node);
const oldParentCtime = found.parent ? found.parent.ctime : null;
const oldIndex = found.index;
// If moving within the same parent, adjust index
let adjustedIndex = newIndex;
if (oldParentCtime === newParentCtime && oldIndex < newIndex) {
// When removing from earlier position, indices shift down
adjustedIndex = newIndex - 1;
}
let updated = removeNode(doc, nodeCtime);
updated = addNode(updated, nodeClone, newParentCtime, newIndex);
updated = addNode(updated, nodeClone, newParentCtime, adjustedIndex);
return updated;
}