mirror of
https://github.com/zadam/trilium.git
synced 2026-02-03 12:24:24 +01:00
fix(mobile/tab_switcher): no title if empty tab
This commit is contained in:
parent
05fa1ef2fb
commit
96fa6eac44
@ -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
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user