RuleStack

Configs

Stacks

Compare

Diff

RuleStack

Configs

Stacks

Compare

Diff

Read API

RuleStack

Configs

Stacks

Compare

Diff

Read API

Diff/xin-lai-codespirit-agents ↔ xin-lai-codespirit-cursor-rules-amis-cards

Comparison

A · AGENTS.md · xin-lai/CodeSpiritB · Cursor rules · xin-lai/CodeSpirit
What each file covers, counted
DimensionSharedOnly in AOnly in BOverlap
Sections114173%
Commands0200%
Section tags0300%

What each file covers

Sections

1 shared · 14 only in A · 17 only in B
  • − Copilot instructions
  • − General recommendations for working with Aspire
  • − Running the application
  • − Checking resources
  • − Listing integrations
  • − Debugging issues
  • − Other Aspire MCP tools
  • − Playwright MCP server
  • − Updating the app host
  • − Persistent containers
  • − Aspire workload
  • − Official documentation
  • − BMAD AI 工作流
  • − 与 CodeSpirit 规范集成
  • + CodeSpirit Amis Cards V2.0 基本原则
  • + 1. 完全隔离原则
  • + 2. 配置优先原则
  • + 3. 渐进增强原则
  • + 4. 模块化架构原则
  • + 5. 向后兼容原则
  • + 6. 性能优先原则
  • + 7. 响应式设计原则
  • + 8. 一致性原则
  • + 9. 用户体验原则
  • + 10. 数据安全原则
  • + 11. 权限控制原则
  • + 12. 代码质量原则
  • + 13. 测试覆盖原则
  • + 14. 文档完整性原则
  • + 15. 渐进式部署原则
  • + 16. 持续改进原则
  •   获取帮助

Commands

0 shared · 2 only in A · 0 only in B
  • − dotnet tool install --global dotnet-outdated-tool
  • − dotnet-outdated

Section tags

0 shared · 3 only in A · 0 only in B
  • − code-style
  • − agent-behaviour
  • − docs

Line diff

+212 added−71 removed31 unchanged12.8% identical
xin-lai/CodeSpirit · AGENTS.md
@@ −1 @@
1# Copilot instructions
 
 
 
 
 
2 
3This repository is set up to use Aspire. Aspire is an orchestrator for the entire application and will take care of configuring dependencies, building, and running the application. The resources that make up the application are defined in `apphost.cs` including application code and external dependencies.
4 
5## General recommendations for working with Aspire
61. Before making any changes always run the apphost using `aspire run` and inspect the state of resources to make sure you are building from a known state.
71. Changes to the _apphost.cs_ file will require a restart of the application to take effect.
82. Make changes incrementally and run the aspire application using the `aspire run` command to validate changes.
93. Use the Aspire MCP tools to check the status of resources and debug issues.
10 
11## Running the application
12To run the application run the following command:
13 
14```
15aspire run
16```
17 
18If there is already an instance of the application running it will prompt to stop the existing instance. You only need to restart the application if code in `apphost.cs` is changed, but if you experience problems it can be useful to reset everything to the starting state.
19 
20## Checking resources
21To check the status of resources defined in the app model use the _list resources_ tool. This will show you the current state of each resource and if there are any issues. If a resource is not running as expected you can use the _execute resource command_ tool to restart it or perform other actions.
 
 
 
 
 
 
22 
23## Listing integrations
24IMPORTANT! When a user asks you to add a resource to the app model you should first use the _list integrations_ tool to get a list of the current versions of all the available integrations. You should try to use the version of the integration which aligns with the version of the Aspire.AppHost.Sdk. Some integration versions may have a preview suffix. Once you have identified the correct integration you should always use the _get integration docs_ tool to fetch the latest documentation for the integration and follow the links to get additional guidance.
25 
26## Debugging issues
27IMPORTANT! Aspire is designed to capture rich logs and telemetry for all resources defined in the app model. Use the following diagnostic tools when debugging issues with the application before making changes to make sure you are focusing on the right things.
28 
291. _list structured logs_; use this tool to get details about structured logs.
302. _list console logs_; use this tool to get details about console logs.
313. _list traces_; use this tool to get details about traces.
324. _list trace structured logs_; use this tool to get logs related to a trace
 
 
33 
34## Other Aspire MCP tools
35 
361. _select apphost_; use this tool if working with multiple app hosts within a workspace.
372. _list apphosts_; use this tool to get details about active app hosts.
38 
39## Playwright MCP server
 
 
 
 
 
40 
41The playwright MCP server has also been configured in this repository and you should use it to perform functional investigations of the resources defined in the app model as you work on the codebase. To get endpoints that can be used for navigation using the playwright MCP server use the list resources tool.
 
 
 
 
42 
43## Updating the app host
44The user may request that you update the Aspire apphost. You can do this using the `aspire update` command. This will update the apphost to the latest version and some of the Aspire specific packages in referenced projects, however you may need to manually update other packages in the solution to ensure compatibility. You can consider using the `dotnet-outdated` with the users consent. To install the `dotnet-outdated` tool use the following command:
45 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
46```
47dotnet tool install --global dotnet-outdated-tool
48```
49 
50## Persistent containers
51IMPORTANT! Consider avoiding persistent containers early during development to avoid creating state management issues when restarting the app.
52 
53## Aspire workload
54IMPORTANT! The aspire workload is obsolete. You should never attempt to install or use the Aspire workload.
55 
56## Official documentation
57IMPORTANT! Always prefer official documentation when available. The following sites contain the official documentation for Aspire and related components
 
 
 
 
 
 
58 
591. https://aspire.dev
602. https://learn.microsoft.com/dotnet/aspire
613. https://nuget.org (for specific integration package details)
 
 
62 
63## BMAD AI 工作流
64 
65本项目已集成 BMAD (Breakthrough Method of Agile AI-Driven Development) 完整工作流,用于结构化的软件开发生命周期管理。
66 
67### 快速开始
 
 
 
 
68 
691. **小型任务/Bug 修复** (Quick Flow):
70 - `/quick-spec` - 创建技术规范
71 - `/quick-dev` - 实现变更
72 - `/code-review` - 代码审查
73 
742. **完整功能开发** (Full Flow):
75 - `/product-brief` - 产品需求简报
76 - `/create-prd` - 创建 PRD
77 - `/create-architecture` - 架构设计
78 - `/create-epics-and-stories` - 拆分为 Epic 和 Story
79 - `/sprint-planning` - Sprint 规划
80 - `/dev-story` - 实现 Story
81 - `/code-review` - 代码审查
82 - `/retrospective` - 复盘
83 
84### 与 CodeSpirit 规范集成
85 
86BMAD 工作流已配置为自动遵循 CodeSpirit 的所有开发规范(位于 `.cursor/rules/`)。在使用 BMAD 时:
 
 
 
 
 
 
87 
88- PRD 会自动考虑多租户、多数据库、AI 功能等项目特性
89- 架构设计会遵循依赖注入、缓存策略等规范
90- Story 实现会应用正确的命名约定、DTO 设计、控制器规范等
91- 代码审查会执行 CodeSpirit 特定的审查清单
92 
93### 获取帮助
94 
95任何时候,输入 `/bmad-help` 可获取上下文相关的指导。
 
 
 
 
96 
97详细使用指南请参考:
98- **[BMAD 使用教程](Docs/bmad/bmad-tutorial.md)** - 完整的综合教程(推荐新手阅读)
99- [BMAD 工作流指南](Docs/bmad/bmad-workflow-guide.md) - 详细的工作流使用指南
100- [BMAD 团队培训指南](Docs/bmad/bmad-team-guide.md) - 团队培训材料
101- [BMAD 集成技能](.cursor/skills/bmad-integration/SKILL.md) - BMAD 与 CodeSpirit 集成
102- [项目上下文文档](project-context.md) - 项目上下文和规范引用
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
xin-lai/CodeSpirit · .cursor/rules/amis-cards.mdc
@@ +1 @@
1---
2description:
3globs: Src/CodeSpirit.Web/wwwroot/amis-cards/*.js
4alwaysApply: false
5---
6# CodeSpirit Amis Cards V2.0 基本原则
7 
8## 概述
9 
10本文档定义了 CodeSpirit Amis Cards V2.0 项目的核心原则,确保开发过程保持一致性和高质量。
 
 
 
 
11 
12## 🎯 核心原则
 
13 
14### 1. 完全隔离原则
 
 
15 
16**原则描述**: 与现有 `cards-sdk` 完全隔离,确保两个系统可以长期并存。
17 
18**执行要求**:
19- ✅ 使用独立的命名空间 `AmisCards`
20- ✅ 所有文件路径使用 `/amis-cards/` 前缀
21- ✅ CSS类名使用 `amis-cards-` 前缀
22- ✅ 全局变量使用 `window.AmisCards` 命名空间
23- ✅ 不引用或依赖现有 `cards-sdk` 的任何文件
24- ❌ 禁止修改现有 `cards-sdk` 的任何代码
25- ❌ 禁止使用与 `cards-sdk` 相同的类名或变量名
26 
27### 2. 配置优先原则
 
28 
29**原则描述**: 优先使用配置化开发,减少手写代码,提高开发效率。
 
30 
31**执行要求**:
32- ✅ 所有卡片通过JSON配置定义
33- ✅ 页面布局通过Amis Page配置实现
34- ✅ 主题样式通过CSS变量配置
35- ❌ 禁止硬编码业务逻辑
36- ❌ 禁止在渲染器中写死样式值
37 
38### 3. 渐进增强原则
39 
40**原则描述**: 从基础功能开始,逐步增加高级功能,确保每个阶段都是可用的。
 
41 
42**执行要求**:
43- ✅ 优先实现核心卡片类型(统计卡片)
44- ✅ 确保基础功能完整可用后再添加高级功能
45- ✅ 每个功能模块独立可测试
46- ❌ 禁止一次性实现所有功能
47- ❌ 禁止跳过基础功能直接实现高级功能
48 
49**实施顺序**:
501. 核心SDK + 统计卡片
512. 图表卡片 + 信息卡片
523. 操作卡片 + 表单卡片
534. 插件系统 + 高级功能
54 
55### 4. 模块化架构原则
 
56 
57**原则描述**: 采用模块化设计,确保代码可维护、可扩展、可测试。
58 
59**执行要求**:
60- ✅ 每个卡片类型独立的渲染器文件
61- ✅ 样式按功能模块分离
62- ✅ 配置文件按业务域分组
63- ❌ 禁止模块间紧耦合
64- ❌ 禁止在一个文件中混合多个功能
65 
66### 5. 向后兼容原则
67 
68**原则描述**: 确保API和配置的向后兼容性,避免破坏性变更。
69 
70**执行要求**:
71- ✅ API接口保持稳定
72- ✅ 配置格式向后兼容
73- ✅ 提供版本迁移指南
74- ❌ 禁止直接删除已发布的API
75- ❌ 禁止修改已有配置的语义
76 
77## 🔧 技术原则
78 
79### 6. 性能优先原则
80 
81**原则描述**: 确保良好的性能表现,特别是在大数据量和移动端场景。
82 
83**执行要求**:
84- ✅ 初始化时间 < 500ms
85- ✅ 卡片渲染时间 < 300ms
86- ✅ 内存使用 < 50MB
87- ✅ 支持虚拟滚动和分页
88- ✅ 实现防抖和节流
89- ❌ 禁止内存泄漏
90- ❌ 禁止阻塞UI线程
91 
92### 7. 响应式设计原则
93 
94**原则描述**: 采用移动优先的响应式设计,确保在所有设备上都有良好体验。
95 
96**执行要求**:
97- ✅ 移动优先的CSS媒体查询
98- ✅ 流式网格布局系统
99- ✅ 触控友好的交互设计
100- ✅ 自适应的字体和间距
101- ✅ 支持横竖屏切换
102- ❌ 禁止固定像素尺寸
103- ❌ 禁止仅为桌面端优化
104 
105**响应式断点**:
106- `xs`: < 576px (手机)
107- `sm`: 576px - 768px (平板竖屏)
108- `md`: 768px - 992px (平板横屏)
109- `lg`: 992px - 1200px (桌面)
110- `xl`: ≥ 1200px (大屏桌面)
111 
112## 🎨 设计原则
113 
114### 8. 一致性原则
115 
116**原则描述**: 保持视觉和交互的一致性,提供统一的用户体验。
117 
118**执行要求**:
119- ✅ 统一的颜色系统和主题
120- ✅ 一致的组件行为和交互
121- ✅ 统一的图标和字体规范
122- ❌ 禁止随意偏离设计系统
123 
124### 9. 用户体验原则
125 
126**原则描述**: 以用户为中心,提供直观、高效的使用体验。
127 
128**执行要求**:
129- ✅ 统一的设计语言和视觉风格
130- ✅ 一致的交互模式和行为
131- ✅ 标准化的组件和样式
132- ✅ 统一的错误处理和反馈
133- ❌ 禁止不一致的视觉设计
134- ❌ 禁止相同功能的不同交互方式
135 
136**设计系统**:
137```css
138:root {
139 /* 统一的设计令牌 */
140 --amis-cards-primary: #007bff;
141 --amis-cards-border-radius: 6px;
142 --amis-cards-box-shadow: 0 2px 8px rgba(0,0,0,0.1);
143 --amis-cards-transition: all 0.3s ease;
144}
145```
 
 
146 
147### 10. 数据安全原则
 
148 
149**原则描述**: 确保数据传输和存储的安全性,防止安全漏洞。
 
150 
151**执行要求**:
152- ✅ 直观的界面布局和导航
153- ✅ 及时的反馈和状态提示
154- ✅ 合理的默认值和智能推荐
155- ✅ 流畅的动画和过渡效果
156- ✅ 容错性设计和错误恢复
157- ❌ 禁止复杂难懂的操作流程
158- ❌ 禁止无反馈的用户操作
159 
160**用户体验检查点**:
161- 新用户能否在5分钟内上手?
162- 常用操作是否在3次点击内完成?
163- 错误信息是否清晰可理解?
164- 加载状态是否有适当提示?
165 
166### 11. 权限控制原则
167 
168**原则描述**: 实现细粒度的权限控制,确保用户只能访问授权的功能。
169 
170**执行要求**:
171- ✅ 必须集成现有TokenManager认证系统
172- ✅ 支持基于角色的权限控制
173- ✅ 功能级和数据级权限验证
174- ❌ 禁止绕过权限检查
175 
176## 📋 质量原则
 
 
 
177 
178### 12. 代码质量原则
 
 
 
 
 
 
 
 
179 
180**原则描述**: 保持高质量的代码标准,确保可读性和可维护性。
181 
182**执行要求**:
183- ✅ 清晰的命名规范
184- ✅ 完整的代码注释
185- ✅ 合理的函数和类设计
186- ✅ 统一的代码风格
187- ❌ 禁止复杂的嵌套逻辑
188- ❌ 禁止重复代码
189 
190### 13. 测试覆盖原则
 
 
 
191 
192**原则描述**: 确保充分的测试覆盖,保证代码质量和功能稳定性。
193 
194**执行要求**:
195- ✅ 核心功能单元测试
196- ✅ 集成测试覆盖
197- ✅ 浏览器兼容性测试
198- ✅ 性能测试验证
199 
200## 📖 文档原则
201 
202### 14. 文档完整性原则
203 
204**原则描述**: 提供完整、准确、易懂的文档,降低使用和维护成本。
205 
206**执行要求**:
207- ✅ API接口文档完整
208- ✅ 配置选项说明详细
209- ✅ 示例代码可运行
210- ✅ 常见问题解答
211- ❌ 禁止过时的文档内容
212 
213**文档结构**:
214```
215docs/
216├── api.md # API参考文档
217├── components.md # 组件使用指南
218├── examples.md # 完整示例
219├── troubleshooting.md # 故障排除
220├── theming.md # 主题定制
221└── migration.md # 迁移指南
222```
223 
224### 15. 渐进式部署原则
225 
226**原则描述**: 采用渐进式部署策略,降低上线风险。
227 
228**执行要求**:
229- ✅ 分阶段功能发布
230- ✅ 灰度测试验证
231- ✅ 回滚方案准备
232- ❌ 禁止一次性大规模变更
233 
234### 16. 持续改进原则
235 
236**原则描述**: 基于用户反馈和性能监控,持续优化和改进系统。
237 
238**执行要求**:
239- ✅ 用户反馈收集机制
240- ✅ 性能监控和分析
241- ✅ 定期代码审查
242 
243- ✅ 技术债务管理
@@ −1 +1 @@
1−# Copilot instructions
1+---
2+description:
3+globs: Src/CodeSpirit.Web/wwwroot/amis-cards/*.js
4+alwaysApply: false
5+---
6+# CodeSpirit Amis Cards V2.0 基本原则
27  
3−This repository is set up to use Aspire. Aspire is an orchestrator for the entire application and will take care of configuring dependencies, building, and running the application. The resources that make up the application are defined in `apphost.cs` including application code and external dependencies.
8+## 概述
49  
5−## General recommendations for working with Aspire
6−1. Before making any changes always run the apphost using `aspire run` and inspect the state of resources to make sure you are building from a known state.
7−1. Changes to the _apphost.cs_ file will require a restart of the application to take effect.
8−2. Make changes incrementally and run the aspire application using the `aspire run` command to validate changes.
9−3. Use the Aspire MCP tools to check the status of resources and debug issues.
10+本文档定义了 CodeSpirit Amis Cards V2.0 项目的核心原则,确保开发过程保持一致性和高质量。
1011  
11−## Running the application
12−To run the application run the following command:
12+## 🎯 核心原则
1313  
14−```
15−aspire run
16−```
14+### 1. 完全隔离原则
1715  
18−If there is already an instance of the application running it will prompt to stop the existing instance. You only need to restart the application if code in `apphost.cs` is changed, but if you experience problems it can be useful to reset everything to the starting state.
16+**原则描述**: 与现有 `cards-sdk` 完全隔离,确保两个系统可以长期并存。
1917  
20−## Checking resources
21−To check the status of resources defined in the app model use the _list resources_ tool. This will show you the current state of each resource and if there are any issues. If a resource is not running as expected you can use the _execute resource command_ tool to restart it or perform other actions.
18+**执行要求**:
19+- ✅ 使用独立的命名空间 `AmisCards`
20+- ✅ 所有文件路径使用 `/amis-cards/` 前缀
21+- ✅ CSS类名使用 `amis-cards-` 前缀
22+- ✅ 全局变量使用 `window.AmisCards` 命名空间
23+- ✅ 不引用或依赖现有 `cards-sdk` 的任何文件
24+- ❌ 禁止修改现有 `cards-sdk` 的任何代码
25+- ❌ 禁止使用与 `cards-sdk` 相同的类名或变量名
2226  
23−## Listing integrations
24−IMPORTANT! When a user asks you to add a resource to the app model you should first use the _list integrations_ tool to get a list of the current versions of all the available integrations. You should try to use the version of the integration which aligns with the version of the Aspire.AppHost.Sdk. Some integration versions may have a preview suffix. Once you have identified the correct integration you should always use the _get integration docs_ tool to fetch the latest documentation for the integration and follow the links to get additional guidance.
27+### 2. 配置优先原则
2528  
26−## Debugging issues
27−IMPORTANT! Aspire is designed to capture rich logs and telemetry for all resources defined in the app model. Use the following diagnostic tools when debugging issues with the application before making changes to make sure you are focusing on the right things.
29+**原则描述**: 优先使用配置化开发,减少手写代码,提高开发效率。
2830  
29−1. _list structured logs_; use this tool to get details about structured logs.
30−2. _list console logs_; use this tool to get details about console logs.
31−3. _list traces_; use this tool to get details about traces.
32−4. _list trace structured logs_; use this tool to get logs related to a trace
31+**执行要求**:
32+- ✅ 所有卡片通过JSON配置定义
33+- ✅ 页面布局通过Amis Page配置实现
34+- ✅ 主题样式通过CSS变量配置
35+- ❌ 禁止硬编码业务逻辑
36+- ❌ 禁止在渲染器中写死样式值
3337  
34−## Other Aspire MCP tools
38+### 3. 渐进增强原则
3539  
36−1. _select apphost_; use this tool if working with multiple app hosts within a workspace.
37−2. _list apphosts_; use this tool to get details about active app hosts.
40+**原则描述**: 从基础功能开始,逐步增加高级功能,确保每个阶段都是可用的。
3841  
39−## Playwright MCP server
42+**执行要求**:
43+- ✅ 优先实现核心卡片类型(统计卡片)
44+- ✅ 确保基础功能完整可用后再添加高级功能
45+- ✅ 每个功能模块独立可测试
46+- ❌ 禁止一次性实现所有功能
47+- ❌ 禁止跳过基础功能直接实现高级功能
4048  
41−The playwright MCP server has also been configured in this repository and you should use it to perform functional investigations of the resources defined in the app model as you work on the codebase. To get endpoints that can be used for navigation using the playwright MCP server use the list resources tool.
49+**实施顺序**:
50+1. 核心SDK + 统计卡片
51+2. 图表卡片 + 信息卡片
52+3. 操作卡片 + 表单卡片
53+4. 插件系统 + 高级功能
4254  
43−## Updating the app host
44−The user may request that you update the Aspire apphost. You can do this using the `aspire update` command. This will update the apphost to the latest version and some of the Aspire specific packages in referenced projects, however you may need to manually update other packages in the solution to ensure compatibility. You can consider using the `dotnet-outdated` with the users consent. To install the `dotnet-outdated` tool use the following command:
55+### 4. 模块化架构原则
4556  
57+**原则描述**: 采用模块化设计,确保代码可维护、可扩展、可测试。
58+ 
59+**执行要求**:
60+- ✅ 每个卡片类型独立的渲染器文件
61+- ✅ 样式按功能模块分离
62+- ✅ 配置文件按业务域分组
63+- ❌ 禁止模块间紧耦合
64+- ❌ 禁止在一个文件中混合多个功能
65+ 
66+### 5. 向后兼容原则
67+ 
68+**原则描述**: 确保API和配置的向后兼容性,避免破坏性变更。
69+ 
70+**执行要求**:
71+- ✅ API接口保持稳定
72+- ✅ 配置格式向后兼容
73+- ✅ 提供版本迁移指南
74+- ❌ 禁止直接删除已发布的API
75+- ❌ 禁止修改已有配置的语义
76+ 
77+## 🔧 技术原则
78+ 
79+### 6. 性能优先原则
80+ 
81+**原则描述**: 确保良好的性能表现,特别是在大数据量和移动端场景。
82+ 
83+**执行要求**:
84+- ✅ 初始化时间 < 500ms
85+- ✅ 卡片渲染时间 < 300ms
86+- ✅ 内存使用 < 50MB
87+- ✅ 支持虚拟滚动和分页
88+- ✅ 实现防抖和节流
89+- ❌ 禁止内存泄漏
90+- ❌ 禁止阻塞UI线程
91+ 
92+### 7. 响应式设计原则
93+ 
94+**原则描述**: 采用移动优先的响应式设计,确保在所有设备上都有良好体验。
95+ 
96+**执行要求**:
97+- ✅ 移动优先的CSS媒体查询
98+- ✅ 流式网格布局系统
99+- ✅ 触控友好的交互设计
100+- ✅ 自适应的字体和间距
101+- ✅ 支持横竖屏切换
102+- ❌ 禁止固定像素尺寸
103+- ❌ 禁止仅为桌面端优化
104+ 
105+**响应式断点**:
106+- `xs`: < 576px (手机)
107+- `sm`: 576px - 768px (平板竖屏)
108+- `md`: 768px - 992px (平板横屏)
109+- `lg`: 992px - 1200px (桌面)
110+- `xl`: ≥ 1200px (大屏桌面)
111+ 
112+## 🎨 设计原则
113+ 
114+### 8. 一致性原则
115+ 
116+**原则描述**: 保持视觉和交互的一致性,提供统一的用户体验。
117+ 
118+**执行要求**:
119+- ✅ 统一的颜色系统和主题
120+- ✅ 一致的组件行为和交互
121+- ✅ 统一的图标和字体规范
122+- ❌ 禁止随意偏离设计系统
123+ 
124+### 9. 用户体验原则
125+ 
126+**原则描述**: 以用户为中心,提供直观、高效的使用体验。
127+ 
128+**执行要求**:
129+- ✅ 统一的设计语言和视觉风格
130+- ✅ 一致的交互模式和行为
131+- ✅ 标准化的组件和样式
132+- ✅ 统一的错误处理和反馈
133+- ❌ 禁止不一致的视觉设计
134+- ❌ 禁止相同功能的不同交互方式
135+ 
136+**设计系统**:
137+```css
138+:root {
139+ /* 统一的设计令牌 */
140+ --amis-cards-primary: #007bff;
141+ --amis-cards-border-radius: 6px;
142+ --amis-cards-box-shadow: 0 2px 8px rgba(0,0,0,0.1);
143+ --amis-cards-transition: all 0.3s ease;
144+}
46145 ```
47−dotnet tool install --global dotnet-outdated-tool
48−```
49146  
50−## Persistent containers
51−IMPORTANT! Consider avoiding persistent containers early during development to avoid creating state management issues when restarting the app.
147+### 10. 数据安全原则
52148  
53−## Aspire workload
54−IMPORTANT! The aspire workload is obsolete. You should never attempt to install or use the Aspire workload.
149+**原则描述**: 确保数据传输和存储的安全性,防止安全漏洞。
55150  
56−## Official documentation
57−IMPORTANT! Always prefer official documentation when available. The following sites contain the official documentation for Aspire and related components
151+**执行要求**:
152+- ✅ 直观的界面布局和导航
153+- ✅ 及时的反馈和状态提示
154+- ✅ 合理的默认值和智能推荐
155+- ✅ 流畅的动画和过渡效果
156+- ✅ 容错性设计和错误恢复
157+- ❌ 禁止复杂难懂的操作流程
158+- ❌ 禁止无反馈的用户操作
58159  
59−1. https://aspire.dev
60−2. https://learn.microsoft.com/dotnet/aspire
61−3. https://nuget.org (for specific integration package details)
160+**用户体验检查点**:
161+- 新用户能否在5分钟内上手?
162+- 常用操作是否在3次点击内完成?
163+- 错误信息是否清晰可理解?
164+- 加载状态是否有适当提示?
62165  
63−## BMAD AI 工作流
166+### 11. 权限控制原则
64167  
65−本项目已集成 BMAD (Breakthrough Method of Agile AI-Driven Development) 完整工作流,用于结构化的软件开发生命周期管理。
168+**原则描述**: 实现细粒度的权限控制,确保用户只能访问授权的功能。
66169  
67−### 快速开始
170+**执行要求**:
171+- ✅ 必须集成现有TokenManager认证系统
172+- ✅ 支持基于角色的权限控制
173+- ✅ 功能级和数据级权限验证
174+- ❌ 禁止绕过权限检查
68175  
69−1. **小型任务/Bug 修复** (Quick Flow):
70− - `/quick-spec` - 创建技术规范
71− - `/quick-dev` - 实现变更
72− - `/code-review` - 代码审查
176+## 📋 质量原则
73177  
74−2. **完整功能开发** (Full Flow):
75− - `/product-brief` - 产品需求简报
76− - `/create-prd` - 创建 PRD
77− - `/create-architecture` - 架构设计
78− - `/create-epics-and-stories` - 拆分为 Epic 和 Story
79− - `/sprint-planning` - Sprint 规划
80− - `/dev-story` - 实现 Story
81− - `/code-review` - 代码审查
82− - `/retrospective` - 复盘
178+### 12. 代码质量原则
83179  
84−### 与 CodeSpirit 规范集成
180+**原则描述**: 保持高质量的代码标准,确保可读性和可维护性。
85181  
86−BMAD 工作流已配置为自动遵循 CodeSpirit 的所有开发规范(位于 `.cursor/rules/`)。在使用 BMAD 时:
182+**执行要求**:
183+- ✅ 清晰的命名规范
184+- ✅ 完整的代码注释
185+- ✅ 合理的函数和类设计
186+- ✅ 统一的代码风格
187+- ❌ 禁止复杂的嵌套逻辑
188+- ❌ 禁止重复代码
87189  
88−- PRD 会自动考虑多租户、多数据库、AI 功能等项目特性
89−- 架构设计会遵循依赖注入、缓存策略等规范
90−- Story 实现会应用正确的命名约定、DTO 设计、控制器规范等
91−- 代码审查会执行 CodeSpirit 特定的审查清单
190+### 13. 测试覆盖原则
92191  
93−### 获取帮助
192+**原则描述**: 确保充分的测试覆盖,保证代码质量和功能稳定性。
94193  
95−任何时候,输入 `/bmad-help` 可获取上下文相关的指导。
194+**执行要求**:
195+- ✅ 核心功能单元测试
196+- ✅ 集成测试覆盖
197+- ✅ 浏览器兼容性测试
198+- ✅ 性能测试验证
96199  
97−详细使用指南请参考:
98−- **[BMAD 使用教程](Docs/bmad/bmad-tutorial.md)** - 完整的综合教程(推荐新手阅读)
99−- [BMAD 工作流指南](Docs/bmad/bmad-workflow-guide.md) - 详细的工作流使用指南
100−- [BMAD 团队培训指南](Docs/bmad/bmad-team-guide.md) - 团队培训材料
101−- [BMAD 集成技能](.cursor/skills/bmad-integration/SKILL.md) - BMAD 与 CodeSpirit 集成
102−- [项目上下文文档](project-context.md) - 项目上下文和规范引用
200+## 📖 文档原则
201+ 
202+### 14. 文档完整性原则
203+ 
204+**原则描述**: 提供完整、准确、易懂的文档,降低使用和维护成本。
205+ 
206+**执行要求**:
207+- ✅ API接口文档完整
208+- ✅ 配置选项说明详细
209+- ✅ 示例代码可运行
210+- ✅ 常见问题解答
211+- ❌ 禁止过时的文档内容
212+ 
213+**文档结构**:
214+```
215+docs/
216+├── api.md # API参考文档
217+├── components.md # 组件使用指南
218+├── examples.md # 完整示例
219+├── troubleshooting.md # 故障排除
220+├── theming.md # 主题定制
221+└── migration.md # 迁移指南
222+```
223+ 
224+### 15. 渐进式部署原则
225+ 
226+**原则描述**: 采用渐进式部署策略,降低上线风险。
227+ 
228+**执行要求**:
229+- ✅ 分阶段功能发布
230+- ✅ 灰度测试验证
231+- ✅ 回滚方案准备
232+- ❌ 禁止一次性大规模变更
233+ 
234+### 16. 持续改进原则
235+ 
236+**原则描述**: 基于用户反馈和性能监控,持续优化和改进系统。
237+ 
238+**执行要求**:
239+- ✅ 用户反馈收集机制
240+- ✅ 性能监控和分析
241+- ✅ 定期代码审查
242+ 
243+- ✅ 技术债务管理
RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack

RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack

RuleStack

Built by

Kynth Studio

Directory

Configs
Stacks
Compare formats
Diff two configs
Best AGENTS.md examples

Formats

AGENTS.md
CLAUDE.md
Cursor rules
Copilot instructions

Reference

Read API
Corpus health
Privacy Policy
Terms

RuleStack