fix: sync sidebar notebook counts after note creation
All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 39s

Add triggerRefresh() call after note creation in both masonry (home-client)
and tabs (notes-tabs-view) modes so NotebooksContext reloads notebook counts.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-04-26 09:45:30 +02:00
parent e76572ccd5
commit e83f1d1e52
2 changed files with 5 additions and 2 deletions

View File

@@ -352,6 +352,7 @@ export function NotesTabsView({ notes, onEdit, currentNotebookId }: NotesTabsVie
if (!newNote) return
setItems((prev) => [newNote, ...prev])
setSelectedId(newNote.id)
triggerRefresh()
} catch {
toast.error(t('notes.createFailed') || 'Impossible de créer la note')
}