-
-
Notifications
You must be signed in to change notification settings - Fork 921
Feat: XMarkdown footer node #1296
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
base: next
Are you sure you want to change the base?
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. ✨ Finishing touches🧪 Generate unit tests (beta)
Tip 📝 Customizable high-level summaries are now available in beta!You can now customize how CodeRabbit generates the high-level summary in your pull requests — including its content, structure, tone, and formatting.
Example instruction:
Note: This feature is currently in beta for Pro-tier users, and pricing will be announced later. 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. Comment |
Summary of ChangesHello @Rain120, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request represents a substantial architectural shift for the project, transitioning to a monorepo setup to better manage its growing suite of components and tools. Alongside this significant restructuring, a new feature has been added to XMarkdown, enabling custom footer components for streaming content. The migration involved a comprehensive overhaul of the documentation infrastructure, build processes, and development tooling, ensuring consistency and maintainability across the newly defined packages. Highlights
Ignored Files
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
Summary of ChangesHello @Rain120, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a significant enhancement to the Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
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.
Code Review
This pull request introduces a new footer prop to the XMarkdown component, allowing a custom component to be displayed during streaming rendering. The implementation is mostly correct, but there are a few issues to address. I've found a couple of bugs in the main component logic related to memoization dependencies and when the footer is displayed. There's also a bug in the streaming simulation logic in the new demo component that could lead to resource leaks. Finally, there's a small documentation error in the English API docs. I've left detailed comments with suggestions for fixes.
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.
Code Review
This pull request introduces a new footer prop to the XMarkdown component, allowing for custom content to be displayed during streaming rendering. The implementation is generally on the right track, but there are a few areas that need attention. The useMemo hook for constructing components has an inefficient dependency array, and the footer element is appended unconditionally. More critically, the new demo component for this feature contains significant logic flaws, including a stale closure and an infinite re-render loop, which should be addressed. Additionally, there's a minor error in the English documentation for the new prop's type. My review includes suggestions to fix these issues.
Bundle ReportChanges will increase total bundle size by 244.17kB (17.83%) ⬆️
Affected Assets, Files, and Routes:view changes for bundle: x-markdown-array-pushAssets Changed:
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## next #1296 +/- ##
==========================================
- Coverage 94.06% 93.95% -0.12%
==========================================
Files 144 144
Lines 3708 3736 +28
Branches 1023 1048 +25
==========================================
+ Hits 3488 3510 +22
- Misses 218 224 +6
Partials 2 2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
合并下最新的 next 分支哈 |
|
@Div627 done |
|
测试覆盖率没有通过 |

中文版模板 / Chinese template
🤔 This is a ...
🔗 Related Issues
related #1284
💡 Background and Solution
Custom footer component in XMarkdown, for example,
Spin.📝 Change Log