-
-
Notifications
You must be signed in to change notification settings - Fork 475
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(thought-chain): controlled mode not working #598
Conversation
📝 WalkthroughWalkthrough该提交引入了针对 Changes
Sequence Diagram(s)sequenceDiagram
participant T as 测试用例
participant C as ThoughtChain 组件
participant H as useCollapsible 钩子
participant U as 用户
T->>C: 用 expandedKeys = ["test3"] 渲染组件
Note over C: 调用 useCollapsible,初始化状态为 [],设置 value 与 onChange
U->>C: 点击项头
C->>H: 触发 onChange 回调
H->>C: 更新 mergedExpandedKeys 状态
C-->>T: 组件根据新状态重新渲染
Suggested reviewers
Poem
Tip ⚡🧪 Multi-step agentic review comment chat (experimental)
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (2)
🔇 Additional comments (5)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
WalkthroughThis pull request addresses the issue of the controlled mode not working in the Changes
|
RequiredCollapsibleOptions['expandedKeys'] | ||
>([], { | ||
value: customizeExpandedKeys, | ||
onChange: customizeOnExpand, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure that customizeOnExpand
is defined and properly handles changes to expandedKeys
. If customizeOnExpand
is not defined, it may lead to unexpected behavior when the expandedKeys
change.
Bundle ReportBundle size has no change ✅ |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #598 +/- ##
==========================================
+ Coverage 91.81% 91.88% +0.06%
==========================================
Files 67 67
Lines 1466 1466
Branches 388 388
==========================================
+ Hits 1346 1347 +1
+ Misses 120 119 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
close #590
Summary by CodeRabbit