Pagination size selector props are grouped with the `pageSizeChanger` prop on `rc-pagination`
Ant Design Pagination enhanced feature added in https://github.com/ant-design/ant-design/pull/46757 depends on this PR changes
The latest updates on your projects. Learn more about Vercel for Git ↗︎
| Name | Status | Preview | Comments | Updated (UTC) |
|---|---|---|---|---|
| pagination | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Sep 22, 2024 0:48am |
Waiting for the code review of this pull request. This pull request depends on fixing the Ant Design pagination issue
@afc163 Code review changes have been addressed. Please review these changes.
@afc163 @MadCcc @zombieJ Waiting for the changes in this pull request to fix the Antd pagination size selector issue. Could you please review it as soon as possible?
[!WARNING]
Rate limit exceeded
@afc163 has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 21 minutes and 41 seconds before requesting another review.
How to resolve this issue?
After the wait time has elapsed, a review can be triggered using the
@coderabbitai reviewcommand as a PR comment. Alternatively, push new commits to this PR.We recommend that you space out your commits to avoid hitting the rate limit.
How do rate limits work?
CodeRabbit enforces hourly rate limits for each developer per organization.
Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.
Please see our FAQ for further information.
Commits
Files that changed from the base of the PR and between ab723a5d12c33dc7ae0f25b194d8ad2cadc47e56 and f4c6b4bca8c3a89bdaff408b4a9426244cd8f586.
Walkthrough
此次更改涉及多个文件,主要集中在对分页组件的API文档、示例代码和功能的增强。README.md文件中的API参数描述得到了扩展和格式化,以提高可读性。新增的showSizeChanger.md文件提供了关于大小更改功能的演示文档。同时,showSizeChanger.tsx文件展示了如何在React应用中使用rc-pagination库。Options.tsx和Pagination.tsx文件中引入了新的属性和逻辑,以支持动态行为。最后,新增的测试文件确保了这些功能的正确性。
Changes
| 文件 | 更改摘要 |
|---|---|
| README.md | 更新showSizeChanger参数描述,增强API文档的可读性。 |
| docs/demo/showSizeChanger.md | 新增文档文件,包含关于大小更改功能的演示。 |
| docs/examples/showSizeChanger.tsx | 新增React组件,展示rc-pagination库的用法,包含不同配置的分页实例。 |
| src/Options.tsx | 更新OptionsProps接口,新增showSizeChanger属性。 |
| src/Pagination.tsx | 修改showSizeChanger逻辑,支持动态设置pageSizeOptions。 |
| package.json | 新增依赖@testing-library/user-event,版本^14.5.2。 |
| tests/options.test.tsx | 在WrapperOptions组件中新增showSizeChanger属性。 |
| tests/sizer.test.tsx | 新增测试用例,验证Pagination组件的大小更改功能。 |
Poem
在兔子洞里欢跳跃,
新功能来真不小。
大小更改随心选,
文档清晰乐无边。
测试确保无烦恼,
兔子欢歌庆变化。 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Tips
Chat
There are 3 ways to chat with CodeRabbit:
- Review comments: Directly reply to a review comment made by CodeRabbit. Example:
--
I pushed a fix in commit <commit_id>, please review it.--Generate unit testing code for this file.-
Open a follow-up GitHub issue for this discussion.
-
- Files and specific lines of code (under the "Files changed" tab): Tag
@coderabbitaiin a new review comment at the desired location with your query. Examples: --@coderabbitai generate unit testing code for this file.--@coderabbitai modularize this function. - PR comments: Tag
@coderabbitaiin a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples: --@coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.--@coderabbitai read src/utils.ts and generate unit testing code.--@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.--@coderabbitai help me debug CodeRabbit configuration file.
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)
-
@coderabbitai pauseto pause the reviews on a PR. -
@coderabbitai resumeto resume the paused reviews. -
@coderabbitai reviewto trigger an incremental review. This is useful when automatic reviews are disabled for the repository. -
@coderabbitai full reviewto do a full review from scratch and review all the files again. -
@coderabbitai summaryto regenerate the summary of the PR. -
@coderabbitai resolveresolve all the CodeRabbit review comments. -
@coderabbitai configurationto show the current CodeRabbit configuration for the repository. -
@coderabbitai helpto get help.
Other keywords and placeholders
- Add
@coderabbitai ignoreanywhere in the PR description to prevent this PR from being reviewed. - Add
@coderabbitai summaryto generate the high-level summary at a specific location in the PR description. - Add
@coderabbitaianywhere in the PR title to generate the title automatically.
CodeRabbit Configuration File (.coderabbit.yaml)
- You can programmatically configure CodeRabbit by adding a
.coderabbit.yamlfile to the root of your repository. - Please see the configuration documentation for more information.
- If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation:
# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
Documentation and Community
- Visit our Documentation for detailed information on how to use CodeRabbit.
- Join our Discord Community to get help, request features, and share feedback.
- Follow us on X/Twitter for updates and announcements.
[!TIP]
Early access features: enabled
We are currently testing new code review model(s) that may lead to higher noise levels in the review comments. Please disable the early access features if the noise level causes any inconvenience.
Note:
- You can enable or disable early access features from the CodeRabbit UI or by updating the CodeRabbit configuration file.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 98.75%. Comparing base (
0176824) to head (f4c6b4b). Report is 1 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #597 +/- ##
==========================================
+ Coverage 98.72% 98.75% +0.03%
==========================================
Files 3 3
Lines 314 322 +8
Branches 141 149 +8
==========================================
+ Hits 310 318 +8
Misses 4 4
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
New and removed dependencies detected. Learn more about Socket for GitHub ↗︎