diff --git a/locale/template/translation.js b/locale/template/translation.js index ab2d61c24..50bb960bd 100644 --- a/locale/template/translation.js +++ b/locale/template/translation.js @@ -1,4 +1,4 @@ -var translation = { +export const translation_template = { // This document is to be used as a template as all the base code is in English // Basic HTML tags are allowed such as etc. All data is sanitized https://developer.mozilla.org/en-US/docs/Web/API/Element/innerHTML diff --git a/scripts/i18n.js b/scripts/i18n.js index 4894ea52c..af7c1ff24 100644 --- a/scripts/i18n.js +++ b/scripts/i18n.js @@ -1,3 +1,4 @@ +import { translation_template } from '../locale/template/translation.js'; import { en_translation } from '../locale/en/translation.js'; import { pt_br_translation } from '../locale/pt-br/translation.js'; import { pt_pt_translation } from '../locale/pt-pt/translation.js'; @@ -14,7 +15,14 @@ import { masterKey } from './wallet.js'; import { getNetwork } from './network.js'; import { cReceiveType, guiToggleReceiveType } from './contacts-book.js'; +/** + * @type {translation_template} + */ export const ALERTS = {}; + +/** + * @type {translation_template} + */ export let translation = {}; // TRANSLATION @@ -99,7 +107,6 @@ export function tr(message, variables) { /** * Translates all static HTML based on the `data-i18n` tag * @param {Array} i18nLangs - * */ export function translateStaticHTML(i18nLangs) { if (!i18nLangs) return;