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
client: Translate template switch
Elian Doran3bdb87d3aaee
diff --git a/src/public/app/widgets/template_switch.js b/src/public/app/widgets/template_switch.jsindex f184409739..0c2c064caa 100644--- a/src/public/app/widgets/template_switch.js+++ b/src/public/app/widgets/template_switch.js@@ -1,5 +1,6 @@import SwitchWidget from "./switch.js";import attributeService from "../services/attributes.js";+import { t } from "../services/i18n.js";/*** Switch for the basic properties widget which allows the user to select whether the note is a template or not, which toggles the `#template` attribute.@@ -14,11 +15,11 @@ export default class TemplateSwitchWidget extends SwitchWidget {doRender() {super.doRender();- this.$switchOnName.text("Template");- this.$switchOnButton.attr("title", "Make the note a template");+ this.$switchOnName.text(t("template_switch.template"));+ this.$switchOnButton.attr("title", t("template_switch.toggle-on-hint"));this.$switchOffName.text("Template");- this.$switchOffButton.attr("title", "Remove the note as a template");+ this.$switchOffButton.attr("title", t("template_switch.toggle-off-hint"));this.$helpButton.attr("data-help-page", "template.html").show();this.$helpButton.on('click', e => utils.openHelp($(e.target)));diff --git a/src/public/translations/en/translation.json b/src/public/translations/en/translation.jsonindex 7bafb379fc..200956c70e 100644--- a/src/public/translations/en/translation.json+++ b/src/public/translations/en/translation.json@@ -1312,5 +1312,10 @@"toggle-off-title": "Unshare the note","shared-branch": "This note exists only as a shared note, unsharing would delete it. Do you want to continue and thus delete this note?","inherited": "Note cannot be unshared here because it is shared through inheritance from an ancestor."+ },+ "template_switch": {+ "template": "Template",+ "toggle-on-hint": "Make the note a template",+ "toggle-off-hint": "Remove the note as a template"}}diff --git a/src/public/translations/ro/translation.json b/src/public/translations/ro/translation.jsonindex be7f09cea6..32d20f0c15 100644--- a/src/public/translations/ro/translation.json+++ b/src/public/translations/ro/translation.json@@ -1312,5 +1312,10 @@"shared-branch": "Această notiță există doar ca o notiță partajată, anularea partajării ar cauza ștergerea ei. Sigur doriți ștergerea notiței?","toggle-off-title": "Anulează partajarea notițeii","toggle-on-title": "Partajează notița"+ },+ "template_switch": {+ "template": "Șablon",+ "toggle-off-hint": "Înlătură notița ca șablon",+ "toggle-on-hint": "Marchează notița drept șablon"}}