This commit is contained in:
Julien Calixte
2023-11-26 10:35:44 +01:00
parent c7ea52c7f8
commit b5fcfdecf6

View File

@@ -13,12 +13,14 @@ export const useNote = (containerClass: string) => {
const { isMobile } = useOverlay(false)
const { stackedNotes, addStackedNote } = useRouteQueryStackedNotes()
const titles = computed(() =>
const titles = computed(
() =>
stackedNotes.value?.reduce((obj: Record<string, string>, note) => {
if (!note) {
return obj
}
const filePath = store.files.find((file) => file.sha === note)?.path ?? ''
const filePath =
store.files.find((file) => file.sha === note)?.path ?? ''
obj[note] = pathToNotePathTitle(filePath)