From eda42f5641df34aea5de97d9b6213b8f9ab2957e Mon Sep 17 00:00:00 2001 From: Shusui MOYATANI Date: Mon, 8 Jan 2024 20:42:42 +0900 Subject: [PATCH] feat: import/export config via clipboard --- src/components/modal/Config.tsx | 62 ++++++++++++++++++++++++++------- src/locales/en.ts | 4 ++- src/locales/ja.ts | 4 ++- 3 files changed, 55 insertions(+), 15 deletions(-) diff --git a/src/components/modal/Config.tsx b/src/components/modal/Config.tsx index 9161ae2..1c46480 100644 --- a/src/components/modal/Config.tsx +++ b/src/components/modal/Config.tsx @@ -636,6 +636,7 @@ const ConfigUI = (props: ConfigProps) => { const i18n = useTranslation(); const [menuIndex, setMenuIndex] = createSignal(null); const { canImport, importConfig } = useOldConfig(); + const { config, setConfig } = useConfig(); const menu = [ { @@ -692,19 +693,54 @@ const ConfigUI = (props: ConfigProps) => { fallback={ <>

{i18n()('config.config')}

- - - +
+ + + + + + + + + +