From 478c0e93f0f9515b207467da5af30b757a756d81 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Wed, 24 Dec 2025 12:14:54 +0200 Subject: [PATCH] fix(breadcrumbs): last arrow not displayed on overflow menu --- apps/client/src/widgets/layout/Breadcrumb.tsx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/apps/client/src/widgets/layout/Breadcrumb.tsx b/apps/client/src/widgets/layout/Breadcrumb.tsx index b4030faae..24ad806ae 100644 --- a/apps/client/src/widgets/layout/Breadcrumb.tsx +++ b/apps/client/src/widgets/layout/Breadcrumb.tsx @@ -35,7 +35,7 @@ const INITIAL_ITEMS = 2; const FINAL_ITEMS = 3; export default function Breadcrumb() { - const { note, notePath, notePaths, noteContext } = useNotePaths(); + const { notePath, notePaths, noteContext } = useNotePaths(); const parentComponent = useContext(ParentComponent); const [ hideArchivedNotes ] = useTriliumOptionBool("hideArchivedNotes_main"); const separatorProps: Omit = { noteContext, hideArchivedNotes }; @@ -57,6 +57,7 @@ export default function Breadcrumb() { ))} + ) : ( notePaths.map((item, index) => ( @@ -179,8 +180,8 @@ function BreadcrumbItem({ index, notePath, noteContext, notePathLength, parentCo } interface BreadcrumbSeparatorProps { - notePath: string, - activeNotePath: string, + notePath: string | undefined, + activeNotePath?: string, noteContext: NoteContext | undefined, hideArchivedNotes: boolean; } @@ -201,7 +202,7 @@ function BreadcrumbSeparator(props: BreadcrumbSeparatorProps) { } function BreadcrumbSeparatorDropdownContent({ notePath, noteContext, activeNotePath, hideArchivedNotes }: BreadcrumbSeparatorProps) { - const notePathComponents = notePath.split("/"); + const notePathComponents = (notePath ?? "").split("/"); const parentNoteId = notePathComponents.at(-1); const childNotes = useChildNotes(parentNoteId);