mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-19 16:10:12 +01:00
🎨 Title localization when creating a document https://github.com/siyuan-note/siyuan/issues/10719
This commit is contained in:
parent
f5043a8c46
commit
2a8809bc7e
25 changed files with 72 additions and 61 deletions
|
|
@ -54,7 +54,7 @@ export const reloadSync = (app: App, data: { upsertRootIDs: string[], removeRoot
|
|||
id: window.siyuan.mobile.editor.protyle.block.rootID
|
||||
}, (response) => {
|
||||
setTitle(response.data.name);
|
||||
(document.getElementById("toolbarName") as HTMLInputElement).value = response.data.name === "Untitled" ? "" : response.data.name;
|
||||
(document.getElementById("toolbarName") as HTMLInputElement).value = response.data.name === window.siyuan.languages.untitled ? "" : response.data.name;
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
@ -389,7 +389,7 @@ export const setTitle = (title: string) => {
|
|||
dragElement.setAttribute("title", versionTitle);
|
||||
}
|
||||
} else {
|
||||
title = title || "Untitled";
|
||||
title = title || window.siyuan.languages.untitled;
|
||||
document.title = `${title} - ${workspaceName} - ${window.siyuan.languages.siyuanNote} v${Constants.SIYUAN_VERSION}`;
|
||||
if (!dragElement) {
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue