Skip to content
This repository was archived by the owner on Jun 22, 2025. It is now read-only.

Commit c34c0c4

Browse files
authored
Merge pull request #2293 from TriliumNext/tree
fix(tree): Unexpected collapse after hoisting a note
2 parents 59296f3 + df68ed3 commit c34c0c4

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

apps/client/src/widgets/note_tree.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1507,6 +1507,12 @@ export default class NoteTreeWidget extends NoteContextAwareWidget {
15071507
);
15081508

15091509
this.toggleHiddenNode(true); // hoisting will handle hidden note visibility
1510+
1511+
// Automatically expand the hoisted note by default
1512+
const node = this.getActiveNode();
1513+
if (node.data.noteId === this.noteContext.hoistedNoteId){
1514+
this.setExpanded(node.data.branchId, true);
1515+
}
15101516
}
15111517
}
15121518

0 commit comments

Comments
 (0)