feat: 提交多个新UI组件模块spec和相关属性设定,包括卡片封装、渐变卡片、列式布局组件等,重写了readme.md,用于AI Coding
Some checks are pending
Call HTTPS API / build (push) Waiting to run

This commit is contained in:
2025-12-27 15:42:57 +08:00
parent fc9c726de4
commit 55abf26cfa
78 changed files with 3024 additions and 103 deletions

View File

@@ -0,0 +1,40 @@
# Module Specvab-theme主题系统入口与交互
module:
id: vab-theme
name: VabTheme主题配置入口/抽屉/设置面板)
type: ui
entrypoints:
- library/components/VabTheme/index.vue
- library/components/VabTheme/components/VabThemeDrawer.vue
- library/components/VabTheme/components/VabThemeSetting.vue
- library/components/VabTheme/components/
public_api:
concept:
- "VabTheme一个刷子图标入口用于触发打开主题抽屉Drawer"
- "VabThemeDrawer主题抽屉监听事件总线打开/随机主题,并调用 settings store 的 saveTheme/resetTheme/updateTheme"
- "VabThemeSetting右侧固定设置入口主题配置/随机换肤/购买源码/清理缓存),通过事件总线触发行为"
usage_examples:
- "点击 VabTheme 触发 $pub('theme') 打开抽屉"
- "点击 VabThemeSetting 的随机换肤触发 $pub('random-theme')"
dependency_closure:
runtime:
- "Pinia settings storesrc/store/modules/settingstheme.showTheme、saveTheme/resetTheme/updateTheme 等)"
- "事件总线/全局注入library/plugins/vab.ts$pub/$sub/$unsub/$baseLoading 等)"
- "i18n translatesrc/i18n/index.ts组件内调用 translate"
- "Element PlusDrawer/Radio/Select/Button 等"
styles:
- "主题变量library/styles/variables/vab-*-variables.module.scssupdateTheme() 动态注入 CSS 变量)"
acceptance:
- "页面渲染包含主题入口(刷子图标)"
- "触发 $pub('theme') 时抽屉能打开;关闭时不报错"
- "保存/重置主题后调用 updateTheme() 生效CSS 变量与 body class 变化)"
pitfalls:
- "Theme 依赖 $pub/$sub 注入;若未安装 vab 插件,事件不会触发"
- "settings.updateTheme() 依赖 webpack 的 require 动态引入 scss module迁移到非 webpack 环境需等效实现"
- "移动端(<992某些操作会触发 reload抽取时需确认期望行为"