diff --git a/src/i18n/index.ts b/src/i18n/index.ts
index 08d40634..af249f16 100644
--- a/src/i18n/index.ts
+++ b/src/i18n/index.ts
@@ -19,7 +19,8 @@ const i18n = use(initReactI18next)
interpolation: {
escapeValue: false,
},
- debug: true,
+ returnNull: false,
+ debug: process.env.NODE_ENV !== 'production',
});
export default i18n;
diff --git a/src/i18n/locale/en.json b/src/i18n/locale/en.json
new file mode 100644
index 00000000..4274760e
--- /dev/null
+++ b/src/i18n/locale/en.json
@@ -0,0 +1,11 @@
+{
+ "screens": {
+ "Library": {
+ "Library": "Library",
+ "could-not-load-categories": "Could not load categories",
+ "your-library-is-empty": "Your Library is empty",
+ "category-is-empty": "Category is Empty",
+ "could-not-load-manga": "Could not load manga"
+ }
+ }
+}
diff --git a/src/i18n/resources/en.json b/src/i18n/resources/en.json
deleted file mode 100644
index c84c7118..00000000
--- a/src/i18n/resources/en.json
+++ /dev/null
@@ -1,4 +0,0 @@
-{
- "DefaultNavBar.navbarItems.Library": "Library",
- "screens/Library/Library": "Library"
-}
diff --git a/src/i18n/resources/fr.json b/src/i18n/resources/fr.json
deleted file mode 100644
index d1c55c47..00000000
--- a/src/i18n/resources/fr.json
+++ /dev/null
@@ -1,4 +0,0 @@
-{
- "DefaultNavBar.navbarItems.Library": "fr(Library)",
- "screens/Library/Library": "fr(Library)"
-}
diff --git a/src/i18n/translations.ts b/src/i18n/translations.ts
index 7c0e3246..4ee82e93 100644
--- a/src/i18n/translations.ts
+++ b/src/i18n/translations.ts
@@ -5,8 +5,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
-import en from 'i18n/resources/en.json';
-import fr from 'i18n/resources/fr.json';
+import en from 'i18n/locale/en.json';
const translationHelper = (lng: any) => ({
translation: lng,
@@ -14,7 +13,6 @@ const translationHelper = (lng: any) => ({
const resources = {
en: translationHelper(en),
- fr: translationHelper(fr),
};
export default resources;
diff --git a/src/screens/Library.tsx b/src/screens/Library.tsx
index 100c9af4..06b530c4 100644
--- a/src/screens/Library.tsx
+++ b/src/screens/Library.tsx
@@ -39,7 +39,7 @@ export default function Library() {
const { setTitle, setAction } = useContext(NavbarContext);
useEffect(() => {
- setTitle(t('screens/Library/Library'));
+ setTitle(t('screens.Library.Library'));
setAction(
<>
@@ -58,7 +58,12 @@ export default function Library() {
};
if (tabsError != null) {
- return ;
+ return (
+
+ );
}
if (loading) {
@@ -66,7 +71,7 @@ export default function Library() {
}
if (tabs.length === 0) {
- return ;
+ return ;
}
if (tabs.length === 1) {
@@ -74,7 +79,7 @@ export default function Library() {
);
@@ -105,14 +110,14 @@ export default function Library() {
{tab === activeTab &&
(mangaError ? (
) : (
))}