Update all three section dialogs to support hide/show toggle: SectionAxisDialogManager: - onHideToggle now calls hideSection()/recoverSection() SectionBoxDialogManager: - onHideToggle now calls hideSection()/recoverSection() SectionPlanePanel: - Add isHidden state tracking - Change onHide to onHideToggle(isHidden) - Add setHiddenState/getHiddenState methods - Update button to toggle active state SectionPlaneDialogManager: - Switch to onHideToggle callback - Call hideSection()/recoverSection() based on toggle state Behavior: Click hide button to hide section, click again to recover.
1.9 KiB
1.9 KiB
Issues and Gotchas
时间: 2026-01-28
问题 1: CSS 变量未定义
发现时间: Task 6 完成后,用户反馈 --bim-component-bg-hover 未定义
根因:
BimCollapse.setTheme()方法使用的是自定义变量名(--bim-header-bg-color)- CSS 文件中使用的是标准变量名(
--bim-component-bg-hover) - 导致 CSS 中的变量引用失败
解决方案:
// 修改前
style.setProperty('--bim-header-bg-color', theme.componentBgHover);
style.setProperty('--bim-header-hover-bg-color', theme.componentBgActive);
// 修改后
style.setProperty('--bim-component-bg', theme.componentBg);
style.setProperty('--bim-component-bg-hover', theme.componentBgHover);
style.setProperty('--bim-component-bg-active', theme.componentBgActive);
影响文件:
src/components/collapse/index.ts(setTheme 方法)
学到的教训:
- CSS 变量命名必须在 TypeScript 和 CSS 文件之间保持一致
- 其他组件(Tree, Menu, ButtonGroup)都使用了标准的
--bim-component-*命名 - Collapse 组件是唯一使用自定义命名的,导致了不一致
提交记录:
- commit: fix(collapse): 添加缺失的 CSS 变量 --bim-component-bg-hover
问题 2: 子代理并行调用失败
发现时间: Wave 1 执行时,3 个并行任务都失败
错误信息: JSON Parse error: Unexpected EOF
影响:
- Task 1 (删除 PropertyPanelManager): 失败
- Task 2 (修改 Toolbar 按钮): 失败
- Task 3 (修复 CSS 样式): 失败(报告成功但实际未修改)
解决方案:
- Atlas 手动完成了这些简单任务
- 虽然系统提示应该使用代理,但由于代理失败,手动完成是必要的
根因分析:
- 可能是 prompt 过长导致 JSON 解析错误
- 可能是并行调用时的系统问题
建议:
- 对于简单的文件移动、单行修改等任务,可以考虑直接执行
- 复杂的业务逻辑和多文件修改仍应使用代理