onOpenChange(false)}
+ />
+ )}
+
+
+
+
{t('json_editor.title')}
+
+
+
+
+
+
+
+
+ setJsonValue(value || '')}
+ theme="vs"
+ options={{
+ minimap: { enabled: true },
+ fontSize: 14,
+ scrollBeyondLastLine: false,
+ automaticLayout: true,
+ wordWrap: 'on',
+ formatOnPaste: true,
+ formatOnType: true,
+ suggest: {
+ showKeywords: true,
+ showSnippets: true,
+ },
+ }}
+ />
+
+
+ >
+ );
+}
\ No newline at end of file
diff --git a/ui/src/locales/en.json b/ui/src/locales/en.json
index cc25c27..9f1528a 100644
--- a/ui/src/locales/en.json
+++ b/ui/src/locales/en.json
@@ -87,5 +87,13 @@
"selectModel": "Select a model...",
"searchModel": "Search model...",
"noModelFound": "No model found."
+ },
+ "json_editor": {
+ "title": "JSON Editor",
+ "save": "Save",
+ "saving": "Saving...",
+ "cancel": "Cancel",
+ "save_failed": "Failed to save config",
+ "save_and_restart": "Save & Restart"
}
}
diff --git a/ui/src/locales/zh.json b/ui/src/locales/zh.json
index 95ecd21..4e1dbe9 100644
--- a/ui/src/locales/zh.json
+++ b/ui/src/locales/zh.json
@@ -87,5 +87,13 @@
"selectModel": "选择一个模型...",
"searchModel": "搜索模型...",
"noModelFound": "未找到模型."
+ },
+ "json_editor": {
+ "title": "JSON 编辑器",
+ "save": "保存",
+ "saving": "保存中...",
+ "cancel": "取消",
+ "save_failed": "配置保存失败",
+ "save_and_restart": "保存并重启"
}
}
\ No newline at end of file
diff --git a/ui/tsconfig.tsbuildinfo b/ui/tsconfig.tsbuildinfo
index 290871d..a64ee0a 100644
--- a/ui/tsconfig.tsbuildinfo
+++ b/ui/tsconfig.tsbuildinfo
@@ -1 +1 @@
-{"root":["./src/app.tsx","./src/i18n.ts","./src/main.tsx","./src/routes.tsx","./src/vite-env.d.ts","./src/components/configprovider.tsx","./src/components/login.tsx","./src/components/providerlist.tsx","./src/components/providers.tsx","./src/components/router.tsx","./src/components/settingsdialog.tsx","./src/components/transformerlist.tsx","./src/components/transformers.tsx","./src/components/ui/badge.tsx","./src/components/ui/button.tsx","./src/components/ui/card.tsx","./src/components/ui/combo-input.tsx","./src/components/ui/combobox.tsx","./src/components/ui/command.tsx","./src/components/ui/dialog.tsx","./src/components/ui/input.tsx","./src/components/ui/label.tsx","./src/components/ui/multi-combobox.tsx","./src/components/ui/popover.tsx","./src/components/ui/switch.tsx","./src/components/ui/toast.tsx","./src/lib/api.ts","./src/lib/utils.ts"],"version":"5.8.3"}
\ No newline at end of file
+{"root":["./src/app.tsx","./src/i18n.ts","./src/main.tsx","./src/routes.tsx","./src/vite-env.d.ts","./src/components/configprovider.tsx","./src/components/jsoneditor.tsx","./src/components/login.tsx","./src/components/providerlist.tsx","./src/components/providers.tsx","./src/components/router.tsx","./src/components/settingsdialog.tsx","./src/components/transformerlist.tsx","./src/components/transformers.tsx","./src/components/ui/badge.tsx","./src/components/ui/button.tsx","./src/components/ui/card.tsx","./src/components/ui/combo-input.tsx","./src/components/ui/combobox.tsx","./src/components/ui/command.tsx","./src/components/ui/dialog.tsx","./src/components/ui/input.tsx","./src/components/ui/label.tsx","./src/components/ui/multi-combobox.tsx","./src/components/ui/popover.tsx","./src/components/ui/switch.tsx","./src/components/ui/toast.tsx","./src/lib/api.ts","./src/lib/utils.ts"],"version":"5.8.3"}
\ No newline at end of file