mirror of
https://github.com/lobehub/lobe-chat.git
synced 2026-06-14 03:30:19 +00:00
✨ feat: Add MCP marketplace and mcp plugin one-click installation in desktop (#8334)
* move plugin Component * ✨ feat(wip): Add MCP Discover Market * ✅ test: Fix test * ✅ test: Fix test * 🐛 fix: Fix build * 🐛 fix: Fix build * 💄 style: update plugin store * 💄 style: Update plugin store * ✨ feat: Update cache control headers and optimize Next.js config for performance * 💄 style: Update discover markdown * 💄 style: Update scroes step * 优化 list 细节 * 优化 list 细节 * 优化 list 细节 * 完成基础 mcp 安装实现 * 完成安装上报 * 新增安装过程 * fix * 优化插件设置页面配置 * 💄 style: update official icon * 完善安装错误状态 * 支持取消安装 * fix types * fix types * 完成系统依赖检查流程 * 完成系统依赖安装流程上报 * try to fix suspense * try to fix suspense * try to fix suspense * try to fix tests * upgrade electron * fix suspense * fix tool name issue * fix test * add i18n * fix tool call * ✅ test: fix tests * move * fix tests * refactor plugin install store * improve old plugin install * fix * fix header link * fix plugin detail * fix oldPlugin detail * fix tests * update i18n * fix i18n * 💄 style: improve style * add debug log * fix link * improve * fix link * 🚚 refactor: refactor the market runtime to nodejs * 移除 props.searchParams 调用 * ✅ test: fix tests * 尝试静态化 discover page * ♻️ refactor: refactor config to nodejs runtime * fix min width * 修正自定义插件的编辑展示区域 * fix i18n * 调整部分组件目录结构 * 完善 MCP 市场安装流程 * 完善安装上报事件 * test: fix test * ✨ feat: 实现 m2m oauth 请求 * ✨ feat: 完善 m2m 注册链路 * ✨ feat: 完善 m2m 注册链路 * 🐛 fix: 优化 debug 日志输出问题 * ✨ feat: 支持 call 上报 * 💄 style: 使用更大的版本 * 🐛 fix: tools calling report * 🐛 fix: try to fix call report * 🐛 fix: try to use expires cookies * 🐛 fix: fix cookies expires issue * test: fix customPluginInfo report * 🐛 fix: fix connection issue * 🐛 fix: fix platform report * 🐛 fix: fix version issue --------- Co-authored-by: canisminor1990 <i@canisminor.cc>
This commit is contained in:
+71
-20
@@ -42,6 +42,15 @@ const nextConfig: NextConfig = {
|
||||
},
|
||||
async headers() {
|
||||
return [
|
||||
{
|
||||
headers: [
|
||||
{
|
||||
key: 'x-robots-tag',
|
||||
value: 'all',
|
||||
},
|
||||
],
|
||||
source: '/:path*',
|
||||
},
|
||||
{
|
||||
headers: [
|
||||
{
|
||||
@@ -57,6 +66,14 @@ const nextConfig: NextConfig = {
|
||||
key: 'Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'Vercel-CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
],
|
||||
source: '/images/(.*).(png|jpe?g|gif|svg|ico|webp)',
|
||||
},
|
||||
@@ -66,6 +83,14 @@ const nextConfig: NextConfig = {
|
||||
key: 'Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'Vercel-CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
],
|
||||
source: '/videos/(.*).(mp4|webm|ogg|avi|mov|wmv|flv|mkv)',
|
||||
},
|
||||
@@ -75,6 +100,14 @@ const nextConfig: NextConfig = {
|
||||
key: 'Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'Vercel-CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
],
|
||||
source: '/screenshots/(.*).(png|jpe?g|gif|svg|ico|webp)',
|
||||
},
|
||||
@@ -84,6 +117,14 @@ const nextConfig: NextConfig = {
|
||||
key: 'Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'Vercel-CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
],
|
||||
source: '/og/(.*).(png|jpe?g|gif|svg|ico|webp)',
|
||||
},
|
||||
@@ -93,6 +134,10 @@ const nextConfig: NextConfig = {
|
||||
key: 'Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
],
|
||||
source: '/favicon.ico',
|
||||
},
|
||||
@@ -102,6 +147,10 @@ const nextConfig: NextConfig = {
|
||||
key: 'Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
],
|
||||
source: '/favicon-32x32.ico',
|
||||
},
|
||||
@@ -111,6 +160,10 @@ const nextConfig: NextConfig = {
|
||||
key: 'Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
{
|
||||
key: 'CDN-Cache-Control',
|
||||
value: 'public, max-age=31536000, immutable',
|
||||
},
|
||||
],
|
||||
source: '/apple-touch-icon.png',
|
||||
},
|
||||
@@ -134,42 +187,40 @@ const nextConfig: NextConfig = {
|
||||
permanent: true,
|
||||
source: '/sitemap-0.xml',
|
||||
},
|
||||
{
|
||||
destination: '/sitemap/plugins-1.xml',
|
||||
permanent: true,
|
||||
source: '/sitemap/plugins.xml',
|
||||
},
|
||||
{
|
||||
destination: '/sitemap/assistants-1.xml',
|
||||
permanent: true,
|
||||
source: '/sitemap/assistants.xml',
|
||||
},
|
||||
{
|
||||
destination: '/manifest.webmanifest',
|
||||
permanent: true,
|
||||
source: '/manifest.json',
|
||||
},
|
||||
{
|
||||
destination: '/discover/assistant/:slug',
|
||||
has: [
|
||||
{
|
||||
key: 'agent',
|
||||
type: 'query',
|
||||
value: '(?<slug>.*)',
|
||||
},
|
||||
],
|
||||
destination: '/discover/assistant',
|
||||
permanent: true,
|
||||
source: '/market',
|
||||
source: '/discover/assistants',
|
||||
},
|
||||
{
|
||||
destination: '/discover/assistants',
|
||||
destination: '/discover/plugin',
|
||||
permanent: true,
|
||||
source: '/discover/assistant',
|
||||
source: '/discover/plugins',
|
||||
},
|
||||
{
|
||||
destination: '/discover/models',
|
||||
destination: '/discover/model',
|
||||
permanent: true,
|
||||
source: '/discover/model',
|
||||
source: '/discover/models',
|
||||
},
|
||||
{
|
||||
destination: '/discover/plugins',
|
||||
destination: '/discover/provider',
|
||||
permanent: true,
|
||||
source: '/discover/plugin',
|
||||
},
|
||||
{
|
||||
destination: '/discover/providers',
|
||||
permanent: true,
|
||||
source: '/discover/provider',
|
||||
source: '/discover/providers',
|
||||
},
|
||||
{
|
||||
destination: '/settings/common',
|
||||
|
||||
Reference in New Issue
Block a user