Files
ai-terminal-assistant/packages/desktop/src-tauri/tauri.conf.json
T
kurihada 4ca8c413a6 fix(desktop): 修复桌面端 API 连接问题
- API 客户端使用完整后端 URL (localhost:3000)
- 添加 tauri-plugin-http 支持外部 HTTP 请求
- 配置 CSP 允许连接 localhost
- 同步 useChat hook 修复 WebSocket 错误处理
2025-12-12 15:30:01 +08:00

56 lines
1.3 KiB
JSON

{
"$schema": "https://schema.tauri.app/config/2",
"productName": "AI Assistant",
"version": "1.0.0",
"identifier": "com.ai-assistant.desktop",
"build": {
"beforeDevCommand": "pnpm dev:vite",
"devUrl": "http://localhost:5199",
"beforeBuildCommand": "pnpm build:vite",
"frontendDist": "../dist"
},
"app": {
"withGlobalTauri": true,
"windows": [
{
"title": "AI Assistant",
"width": 1200,
"height": 800,
"minWidth": 800,
"minHeight": 600,
"resizable": true,
"fullscreen": false,
"center": true
}
],
"security": {
"csp": "default-src 'self'; connect-src 'self' http://localhost:* ws://localhost:* http://127.0.0.1:* ws://127.0.0.1:*; script-src 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline'"
},
"trayIcon": {
"iconPath": "icons/icon.png",
"iconAsTemplate": true
}
},
"bundle": {
"active": true,
"targets": "all",
"icon": [
"icons/32x32.png",
"icons/128x128.png",
"icons/128x128@2x.png",
"icons/icon.icns",
"icons/icon.ico"
],
"macOS": {
"minimumSystemVersion": "10.15"
},
"windows": {
"wix": null,
"nsis": {
"installMode": "currentUser"
}
}
},
"plugins": {}
}