diff --git a/packages/common/i18next.js b/packages/common/i18next.js index 54550215ea628cb9b5b2ed433b7d3b0627b05284..21544a4663dd15b147f87c21a366d9123e3cb68d 100644 --- a/packages/common/i18next.js +++ b/packages/common/i18next.js @@ -141,7 +141,7 @@ async function fetchOverridesByLanguage(overrides, lng) { * * @param {i18next.i18n} i18n - The i18next instance * @param {HTMLElement} element - The element at which the overrides are targeted - * @param {String} overridesFile - Path to the translation file containing the overrides + * @param {string} overridesFile - Path to the translation file containing the overrides */ export async function setOverridesByFile(i18n, element, overridesFile) { // We add a special namespace which gets used with priority and falls back diff --git a/packages/common/src/i18n.js b/packages/common/src/i18n.js index ae6a0c68533a977069ae91e0bea852e438f3dba9..67966f710d678fa566707cd814800d084720d629 100644 --- a/packages/common/src/i18n.js +++ b/packages/common/src/i18n.js @@ -9,7 +9,7 @@ export function createInstance() { export async function createInstanceAsync(langFile, namespace) { if (namespace == undefined) - namespace = 'translation' + namespace = 'translation'; // check if a path to language files is given if(langFile) { diff --git a/packages/common/src/translation.js b/packages/common/src/translation.js index fd965c2e747155b3edd329bb9bfa9ddaaf2fd52b..4600097101fd507d91b98f3d9e541ec4734a524f 100644 --- a/packages/common/src/translation.js +++ b/packages/common/src/translation.js @@ -4,19 +4,6 @@ import {unsafeHTML} from 'lit/directives/unsafe-html.js'; import DBPLitElement from '../dbp-lit-element'; import {createInstanceAsync, setOverridesByFile} from './i18n.js'; -let OVERRIDE = { - 'de': { - 'dbp-translation': { - 'toolkit-showcase': 'testText' - } - }, - 'en': { - 'dbp-translation': { - 'toolkit-showcase': 'testText2' - } - } -} - export class Translation extends DBPLitElement { constructor() { super(); @@ -68,7 +55,7 @@ export class Translation extends DBPLitElement { local._i18n = response; local.requestUpdate(); }); - }) + }); } }