theme: 以 feature/theme-remote-p0 内容整体替换 main(主题通道化试点,非 merge)

- 本地 icons.css/layout.css 下线改走中央静态通道;新增 ThemeSwitcher.vue + useElementHeight.ts;
  layout/main.ts/vite/menu 及各页适配对齐 feature 试点。
- 已知回退:本轮按 feature 覆盖,冲掉了 main 上 31ca694(/approval 可达性+modId 对齐) 与
  1516eff(cc useTableHeight) 两处功能修复,待后续单独补回。
- 回滚锚点:archive/main-before-theme-20260924 = 替换前 main(1516eff)。
This commit is contained in:
chenxing
2026-09-24 11:33:13 +08:00
parent 1516effb69
commit 74b9e80b0d
26 changed files with 858 additions and 1435 deletions
+5 -1
View File
@@ -11,6 +11,8 @@ import presetUno from "@unocss/preset-uno";
import presetRemToPx from "@unocss/preset-rem-to-px";
import { yhTheme } from "@yunhai/vite-plugin-theme";
export default defineConfig(({ command, mode }: ConfigEnv): UserConfig => {
// 构建产物直出 dist/(env-config 模式,与 Cms/UserBase 同风格):CI zip 打包取 dist 根,
// 不再有 dist/base 中间层(此前 outDir=dist/base 时 zip 打 dist 整层,zip 根只有 base/
@@ -73,7 +75,6 @@ export default defineConfig(({ command, mode }: ConfigEnv): UserConfig => {
"flex-center": "flex items-center justify-center",
// 常用组件
btn: "px-16px py-8px rounded-4px cursor-pointer transition-all duration-200",
"btn-primary": "bg-blue-600 text-white hover:bg-blue-700",
card: "bg-white rounded-8px shadow-md p-16px",
// 文本截断
"text-ellipsis": "truncate",
@@ -90,6 +91,9 @@ export default defineConfig(({ command, mode }: ConfigEnv): UserConfig => {
},
},
}),
// 主题插件放末位:transformIndexHtml 用 order:'post',必须晚于 createHtmlPlugin 才能把
// init script + 兜底 style 追加到最终 html;dev 的 /static 代理也由它自动配
yhTheme(),
],
resolve: {
alias: {