From 893a1e37231b3c817731944069ef27ef96932bac Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Sun, 8 Sep 2024 19:45:19 +0300 Subject: [PATCH] i18n: Translate setup screen --- .vscode/i18n-ally-custom-framework.yml | 1 + src/views/setup.ejs | 58 +++++++++++++------------- translations/en/server.json | 41 +++++++++++++++++- 3 files changed, 70 insertions(+), 30 deletions(-) diff --git a/.vscode/i18n-ally-custom-framework.yml b/.vscode/i18n-ally-custom-framework.yml index dd7f701e5..32ec786aa 100644 --- a/.vscode/i18n-ally-custom-framework.yml +++ b/.vscode/i18n-ally-custom-framework.yml @@ -26,6 +26,7 @@ scopeRangeRegex: "useTranslation\\(\\s*\\[?\\s*['\"`](.*?)['\"`]" refactorTemplates: - t("$1") - ${t("$1")} + - <%= t("$1") %> # If set to true, only enables this custom framework (will disable all built-in frameworks) diff --git a/src/views/setup.ejs b/src/views/setup.ejs index a6f71d759..a5334326f 100644 --- a/src/views/setup.ejs +++ b/src/views/setup.ejs @@ -47,7 +47,7 @@
diff --git a/translations/en/server.json b/translations/en/server.json index e65a7eda1..6281dc449 100644 --- a/translations/en/server.json +++ b/translations/en/server.json @@ -106,5 +106,44 @@ "password-confirmation": "Password confirmation", "button": "Set password" }, - "javascript-required": "Trilium requires JavaScript to be enabled." + "javascript-required": "Trilium requires JavaScript to be enabled.", + "setup": { + "heading": "TriliumNext Notes setup", + "new-document": "I'm a new user, and I want to create a new Trilium document for my notes", + "sync-from-desktop": "I have a desktop instance already, and I want to set up sync with it", + "sync-from-server": "I have a server instance already, and I want to set up sync with it", + "next": "Next", + "init-in-progress": "Document initialization in progress", + "redirecting": "You will be shortly redirected to the application." + }, + "setup_sync-from-desktop": { + "heading": "Sync from Desktop", + "description": "This setup needs to be initiated from the desktop instance:", + "step1": "Open your desktop instance of TriliumNext Notes.", + "step2": "From the Trilium Menu, click Options.", + "step3": "Click on Sync tab.", + "step4": "Change server instance address to: {{- host}} and click save.", + "step5": "Click \"Test sync\" button to verify connection is successful.", + "step6": "Once you've completed these steps, click {{- link}}." + }, + "setup_sync-from-server": { + "heading": "Sync from Server", + "instructions": "Please enter Trilium server address and credentials below. This will download the whole Trilium document from server and setup sync to it. Depending on the document size and your connection speed, this may take a while.", + "server-host": "Trilium server address", + "server-host-placeholder": "https://:", + "proxy-server": "Proxy server (optional)", + "proxy-server-placeholder": "https://:", + "note": "Note:", + "proxy-instruction": "If you leave proxy setting blank, system proxy will be used (applies to desktop/electron build only)", + "password": "Password", + "password-placeholder": "Password", + "back": "Back", + "finish-setup": "Finish setup" + }, + "setup_sync-in-progress": { + "heading": "Sync in progress", + "successful": "Sync has been correctly set up. It will take some time for the initial sync to finish. Once it's done, you'll be redirected to the login page.", + "outstanding-items": "Outstanding sync items:", + "outstanding-items-default": "N/A" + } }