mirror of
https://github.com/zadam/trilium.git
synced 2025-12-21 06:44:24 +01:00
fix(breadcrumb): archived not respected by last item
This commit is contained in:
parent
94df5c9126
commit
66ed88c409
@ -130,6 +130,7 @@ function BreadcrumbLastItem({ notePath, parentComponent }: { notePath: string, p
|
|||||||
const [ note ] = useState(() => froca.getNoteFromCache(noteId!));
|
const [ note ] = useState(() => froca.getNoteFromCache(noteId!));
|
||||||
const title = useNoteProperty(note, "title");
|
const title = useNoteProperty(note, "title");
|
||||||
const colorClass = useNoteColorClass(note);
|
const colorClass = useNoteColorClass(note);
|
||||||
|
const [ archived ] = useNoteLabelBoolean(note, "archived");
|
||||||
useStaticTooltip(linkRef, {
|
useStaticTooltip(linkRef, {
|
||||||
placement: "top",
|
placement: "top",
|
||||||
title: t("breadcrumb.scroll_to_top_title")
|
title: t("breadcrumb.scroll_to_top_title")
|
||||||
@ -141,7 +142,7 @@ function BreadcrumbLastItem({ notePath, parentComponent }: { notePath: string, p
|
|||||||
<a
|
<a
|
||||||
ref={linkRef}
|
ref={linkRef}
|
||||||
href="#"
|
href="#"
|
||||||
className={clsx("breadcrumb-last-item tn-link", colorClass)}
|
className={clsx("breadcrumb-last-item tn-link", colorClass, archived && "archived")}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
const activeNtxId = appContext.tabManager.activeNtxId;
|
const activeNtxId = appContext.tabManager.activeNtxId;
|
||||||
const scrollingContainer = document.querySelector(`[data-ntx-id="${activeNtxId}"] .scrolling-container`);
|
const scrollingContainer = document.querySelector(`[data-ntx-id="${activeNtxId}"] .scrolling-container`);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user