feat(theme): 接入云海子主题通道(A 类免插件,规范 v1.12 §2/§3)
build / build (push) Successful in 8m17s

- index.html 插 A 类 loader:唯一接入点,FOUC 门/manifest 预取/link 排序全由 yh-theme-init.js 承担,主题升级走 /static 通道不重新构建
- vite 加 /static dev 代理(YH_THEME_PROXY_TARGET 可覆盖)
- host.config 回写 __APP_CONFIG__.serviceHost(仅同源):init 的 appearance 请求跨源会被直接跳过
- 顶栏头像接平台键 yh-avatar,监听 yh-appearance-updated,userInfo 兜底
- view-ui-plus 声明锁 1.3.24(对齐通道皮肤生成版本)
This commit is contained in:
lijing
2026-10-21 17:34:31 +08:00
parent 9cedc73b04
commit 483243a3d9
6 changed files with 78 additions and 3 deletions
+6
View File
@@ -94,6 +94,12 @@ export default defineConfig((): UserConfig => {
host: "localhost",
port: 8078,
proxy: {
// 主题通道本地联调(A 类接入 §2.2):默认走线上通道;联调本地通道源用
// YH_THEME_PROXY_TARGET=http://localhost:9527 npm run dev
"/static": {
target: process.env.YH_THEME_PROXY_TARGET || "http://base.yunhaixingtong.com",
changeOrigin: true,
},
// 本地联调(唯一运行模式):serviceHost 为空(.env.dev,同源相对路径 /api/...),
// 经此代理转发到真实后端,规避后端 CAS 过滤器对 /api/* 不回 CORS 头导致的浏览器直连跨域拦截。
// 默认转发到本地后端(application.yml server.port=8106,HomeLeaveApplication 启动);