mirror of
https://github.com/zadam/trilium.git
synced 2025-10-20 23:29:02 +02:00
fix(collections/list): not reacting to expand/collapse button (closes #7209)
This commit is contained in:
parent
fa7575ed00
commit
69a59f0935
@ -59,8 +59,8 @@ function ListNoteCard({ note, parentNote, expand, highlightedTokens }: { note: F
|
||||
const [ isExpanded, setExpanded ] = useState(expand);
|
||||
const notePath = getNotePath(parentNote, note);
|
||||
|
||||
// Reset expand state if switching to another note.
|
||||
useEffect(() => setExpanded(expand), [ note ]);
|
||||
// Reset expand state if switching to another note, or if user manually toggled expansion state.
|
||||
useEffect(() => setExpanded(expand), [ note, expand ]);
|
||||
|
||||
return (
|
||||
<div
|
||||
|
Loading…
x
Reference in New Issue
Block a user