v1.3 修正 ScriptCard 动画问题 by cyfung1031 · Pull Request #1234 · scriptscat/scriptcat
Pull request overview
该 PR 旨在修复 v1.3 中 ScriptCard(卡片视图)相关的动画/拖拽表现问题,并将“引导模式下无脚本时的演示数据”逻辑从 ScriptCard 下沉到 ScriptList 统一处理,从而让卡片/表格视图共享同一份过滤后的列表数据。
Changes:
- 在
ScriptList/index.tsx中引入guideMode,并在过滤阶段对空列表注入演示脚本数据。 - 移除
ScriptCard.tsx内部对引导模式演示数据的useMemo包装,改为直接使用父组件传入的scriptList。 - 调整过滤 effect 依赖项,确保 guideMode 切换会触发过滤结果更新。
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| src/pages/options/routes/ScriptList/index.tsx | 增加 guideMode 演示数据,并在过滤逻辑中选择真实列表/演示列表作为过滤目标 |
| src/pages/options/routes/ScriptList/ScriptCard.tsx | 移除 guideMode 演示数据逻辑,统一使用父组件传入的列表,减少额外 memo 包装 |