Implement Luxsin audio API integration: Add proxy configuration in Vite for CORS handling, enhance luxsinApi with brand and model fetching functions, and update EQPage to support audio catalog browsing and searching. Introduce new state management for catalog brands and models.

This commit is contained in:
yangy
2026-04-20 17:51:23 +08:00
parent 0e7670c215
commit 22fdf39670
3 changed files with 660 additions and 4 deletions
+8
View File
@@ -231,6 +231,14 @@ export default defineConfig({
port: 3000,
strictPort: false, // Will find next available port if 3000 is busy
host: true,
// Browser requests with Origin are rejected (403) by the cloud API; proxy in dev avoids CORS/WAF.
proxy: {
"/luxsin-audio-api": {
target: "https://api.luxsin.com.cn",
changeOrigin: true,
rewrite: (p) => p.replace(/^\/luxsin-audio-api/, "/audio"),
},
},
allowedHosts: [
".manuspre.computer",
".manus.computer",