mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-09-18 17:31:53 +08:00
fixed title (#2356)
This commit is contained in:
parent
83f125a79f
commit
21854b4a04
@ -129,12 +129,12 @@ export default class TabManager extends Component {
|
||||
window.history.pushState(null, "", url);
|
||||
}
|
||||
|
||||
document.title = "Trilium Notes";
|
||||
|
||||
if (activeNoteContext.note) {
|
||||
const titleFragments = [
|
||||
// it helps navigating in history if note title is included in the title
|
||||
document.title += " - " + activeNoteContext.note.title;
|
||||
}
|
||||
activeNoteContext.note?.title,
|
||||
"Trilium Notes"
|
||||
].filter(Boolean);
|
||||
document.title = titleFragments.join(" - ");
|
||||
|
||||
this.triggerEvent('activeNoteChanged'); // trigger this even in on popstate event
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user