Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
fix(mobile/tab_switcher): no title if empty tab
Elian Doran96fa6eac4497
diff --git a/apps/client/src/widgets/mobile_widgets/TabSwitcher.tsx b/apps/client/src/widgets/mobile_widgets/TabSwitcher.tsxindex 4ce8ed4bf6..edbe10bbec 100644--- a/apps/client/src/widgets/mobile_widgets/TabSwitcher.tsx+++ b/apps/client/src/widgets/mobile_widgets/TabSwitcher.tsx@@ -6,6 +6,7 @@ import { useEffect, useState } from "preact/hooks";import appContext from "../../components/app_context";import NoteContext from "../../components/note_context";+import { t } from "../../services/i18n";import { NoteContent } from "../collections/legacy/ListOrGridView";import { LaunchBarActionButton } from "../launch_bar/launch_bar_widgets";import { useTriliumEvent } from "../react/hooks";@@ -63,7 +64,7 @@ function Tab({ noteContext }: {return (<div class="tab-card"><header>- <span className="title">{noteContext.note?.title}</span>+ <span className="title">{noteContext.note?.title ?? t("tab_row.new_tab")}</span></header><div className={clsx("tab-preview", `type-${note?.type ?? "empty"}`)}>{note && <NoteContent