-
Notifications
You must be signed in to change notification settings - Fork 112
feat: support components #375
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Walkthrough本次更改为 Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant Steps
participant Step
participant StepsContext
User->>Steps: 渲染Steps({ components: { root, item } })
Steps->>StepsContext: 提供{ ItemComponent: item }
Steps->>Step: 渲染Step
Step->>StepsContext: 获取ItemComponent
Step->>ItemComponent: 渲染Step内容
Poem
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
src/Context.tsOops! Something went wrong! :( ESLint: 8.57.1 ESLint couldn't find the config "prettier" to extend from. Please check that the name of the config is correct. The config "prettier" was referenced from the config file in "/.eslintrc.js". If you still have problems, please stop by https://eslint.org/chat/help to chat with the team. src/Step.tsxOops! Something went wrong! :( ESLint: 8.57.1 ESLint couldn't find the config "prettier" to extend from. Please check that the name of the config is correct. The config "prettier" was referenced from the config file in "/.eslintrc.js". If you still have problems, please stop by https://eslint.org/chat/help to chat with the team. src/Steps.tsxOops! Something went wrong! :( ESLint: 8.57.1 ESLint couldn't find the config "prettier" to extend from. Please check that the name of the config is correct. The config "prettier" was referenced from the config file in "/.eslintrc.js". If you still have problems, please stop by https://eslint.org/chat/help to chat with the team.
📜 Recent review detailsConfiguration used: CodeRabbit UI ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (4)
🧰 Additional context used🧬 Code Graph Analysis (2)src/Context.ts (1)
src/Steps.tsx (1)
🔇 Additional comments (9)
✨ 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:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. 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 (
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #375 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 6 6
Lines 97 99 +2
Branches 37 38 +1
=========================================
+ Hits 97 99 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
/** Internal usage of antd. Do not deps on this. */ | ||
components?: { | ||
root?: ComponentType; | ||
item?: ComponentType; |
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.
单独rc这边不给默认值吗?ol
、li
之类的
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.
这个 是定义,实现里给了默认值。另外这个库是 rc-steps,所以默认值是 div,antd里的 Timeline 才会改成 ol 和 li
Steps 组件需要支持
clickable
要用div
而 Timeline 则是ol
。否则li + click
a11y 会报错。这里添加一个 components 自定义支持。Summary by CodeRabbit
新功能
测试