@douglasneuroinformatics/libui 6.1.1 → 6.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/i18n/translator.js
CHANGED
|
@@ -75,7 +75,7 @@ let Translator = (() => {
|
|
|
75
75
|
const globalObj = globalThis;
|
|
76
76
|
globalObj[globalKey] ??= [];
|
|
77
77
|
globalObj[globalKey].push(this);
|
|
78
|
-
if (globalObj[globalKey].length >
|
|
78
|
+
if (globalObj[globalKey].length > 1) {
|
|
79
79
|
console.warn(`WARNING: Multiple Translator instances detected (existing: ${globalObj[globalKey].length})`);
|
|
80
80
|
// Check if prototypes are the same (can occur if multiple library versions are loaded)
|
|
81
81
|
const differentPrototype = globalObj[globalKey].some((inst) => {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@douglasneuroinformatics/libui",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "6.1.
|
|
4
|
+
"version": "6.1.2",
|
|
5
5
|
"packageManager": "pnpm@10.7.1",
|
|
6
6
|
"description": "Generic UI components for DNP projects, built using React and Tailwind CSS",
|
|
7
7
|
"author": "Joshua Unrau",
|
package/src/i18n/translator.ts
CHANGED
|
@@ -57,7 +57,7 @@ export class Translator implements TranslatorType<TranslationKey> {
|
|
|
57
57
|
globalObj[globalKey] ??= [];
|
|
58
58
|
globalObj[globalKey].push(this);
|
|
59
59
|
|
|
60
|
-
if (globalObj[globalKey].length >
|
|
60
|
+
if (globalObj[globalKey].length > 1) {
|
|
61
61
|
console.warn(`WARNING: Multiple Translator instances detected (existing: ${globalObj[globalKey].length})`);
|
|
62
62
|
|
|
63
63
|
// Check if prototypes are the same (can occur if multiple library versions are loaded)
|