From 852897c5024f70ebb4d062ab1af1db11606c6b4c Mon Sep 17 00:00:00 2001 From: Marco Rodolfi Date: Fri, 26 May 2023 12:14:40 +0200 Subject: Fixed untranslated error message and added french suffix country code. --- frontend/src/plugin-loader.tsx | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) (limited to 'frontend/src/plugin-loader.tsx') diff --git a/frontend/src/plugin-loader.tsx b/frontend/src/plugin-loader.tsx index 7bc02c9a..fd400743 100644 --- a/frontend/src/plugin-loader.tsx +++ b/frontend/src/plugin-loader.tsx @@ -1,5 +1,6 @@ import { ConfirmModal, ModalRoot, Patch, QuickAccessTab, Router, showModal, sleep } from 'decky-frontend-lib'; import { FC, lazy } from 'react'; +import { Trans, Translation } from 'react-i18next'; import { FaCog, FaExclamationCircle, FaPlug } from 'react-icons/fa'; import { DeckyState, DeckyStateContextProvider, useDeckyState } from './components/DeckyState'; @@ -255,26 +256,25 @@ class PluginLoader extends Logger { } catch (e) { //this.error(t('PluginLoader.plugin_load_error.message', { name: name }), e); this.error('Error loading plugin ' + name, e); - /*const TheError: FC<{}> = () => ( - <> - {t('PluginLoader.error')}:{' '} -
-              {e instanceof Error ? e.stack : JSON.stringify(e)}
-            
- <>{t('PluginLoader.plugin_error_uninstall', { icon: "" })} - - );*/ const TheError: FC<{}> = () => ( - <> - Error:{' '} -
-              {e instanceof Error ? e.stack : JSON.stringify(e)}
-            
- <> - Please go to in the Decky menu if you need to uninstall this - plugin. - - + + {(t, {}) => { + return ( + <> + {t('PluginLoader.error')}:{' '} +
+                    {e instanceof Error ? e.stack : JSON.stringify(e)}
+                  
+ <> + ]} + /> + + + ); + }} +
); this.plugins.push({ name: name, -- cgit v1.2.3