chore: standardize repository maintenance#869
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
✅ Preview is ready!
↩️ Previous: ⚡️ 🤖 Powered by surge-preview |
|||||||||||||||
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
Walkthrough站点构建与发布配置改为 Changes文档站点与自动化更新
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
Code Review
This pull request updates the documentation configuration, migrates the build output directory to docs-dist, cleans up configuration files, and significantly rewrites the README. Additionally, it introduces a Vercel configuration and updates the package.json scripts. The review feedback suggests using cross-env in the gh-pages script to ensure cross-platform compatibility and recommends decoupling the documentation deployment from the postpublish script to prevent publishing pipeline issues.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #869 +/- ##
=======================================
Coverage 99.72% 99.72%
=======================================
Files 26 26
Lines 734 734
Branches 205 205
=======================================
Hits 732 732
Misses 2 2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Actionable comments posted: 4
🧹 Nitpick comments (1)
.github/workflows/react-doctor.yml (1)
9-13: 🔒 Security & Privacy | 🔵 Trivial请移除
push场景下的不必要写权限,遵循最小权限原则。根据
millionco/react-doctor官方文档,该 Action 仅需contents: read即可运行。pull-requests: write、issues: write和statuses: write仅在需要在 PR 上发表评论或更新提交状态时必需。当工作流在push事件(如推送到主分支)触发时,这些写权限通常是不必要的。当前配置将写权限应用于所有push事件,扩大了GITHUB_TOKEN的攻击面。建议将权限配置拆分:仅针对
pull_request事件授予写权限,或为push事件定义仅包含contents: read的专用权限块。建议的权限配置示例
permissions: contents: read # 默认仅保留读权限 # 针对需要写权限的 PR 事件进行覆盖 on: pull_request: permissions: contents: read pull-requests: write issues: write statuses: write push: permissions: contents: read🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/react-doctor.yml around lines 9 - 13, The workflow permissions are too broad for push-triggered runs, so split the permissions in react-doctor.yml to keep only contents: read for push while reserving pull-requests: write, issues: write, and statuses: write for pull_request runs. Update the workflow-level permissions block and the on: pull_request / on: push configuration so the React Doctor action still has write access only when it needs to comment or update statuses, using the existing permissions and react-doctor job setup as the anchor points.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.github/workflows/react-component-ci.yml:
- Around line 6-8: Update the reusable workflow call in the test job to avoid
drift and overexposure of secrets: replace the current react-component/rc-test
workflow reference in the test job from the moving branch target to the pinned
SHA b8ebddc81ef706b50faff0242ab34ad8ecdd9a59, and remove secrets: inherit so
only the required CODECOV_TOKEN is passed explicitly via the test job’s secrets
block.
In `@README.md`:
- Line 112: Update the README prop table entry for overflowedIndicator so the
Default column matches the actual default used in Menu.tsx: change the generic
... to the string literal "..." and keep the description aligned with the
default value shown by the overflowedIndicator prop.
- Around line 130-153: `ItemType` 中 `type: 'submenu'` 的 `key` 限制为 string
需要补充原因说明,避免和 `type: 'item'` 允许 React.Key 的设计混淆。请在 `SubMenuType` 的 `key`
定义附近添加注释,明确这是为了匹配 `Menu` 组件的 `openKeys` / `defaultOpenKeys`(以及相关
`selectedKeys`)使用 string[] 的约束;同时保留 `MenuItemType` 使用 React.Key 的现状,并说明其在内部如
`onSelect` 处理时会统一转成 string。
In `@tsconfig.json`:
- Around line 16-17: TypeScript checking is pulling in the JavaScript config
file via the tsconfig.json include list, which will fail under tsc --noEmit
without allowJs. Update the tsconfig.json include configuration by removing
.fatherrc.js unless it must be type-checked, or alternatively enable allowJs in
compilerOptions if that file should stay included. Keep the fix localized to the
include/compilerOptions settings so the tsc check script stops hitting TS6504.
---
Nitpick comments:
In @.github/workflows/react-doctor.yml:
- Around line 9-13: The workflow permissions are too broad for push-triggered
runs, so split the permissions in react-doctor.yml to keep only contents: read
for push while reserving pull-requests: write, issues: write, and statuses:
write for pull_request runs. Update the workflow-level permissions block and the
on: pull_request / on: push configuration so the React Doctor action still has
write access only when it needs to comment or update statuses, using the
existing permissions and react-doctor job setup as the anchor points.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 5d94616a-9097-4b0e-8dd8-ae31330ee3c7
📒 Files selected for processing (14)
.dumirc.ts.github/FUNDING.yml.github/workflows/cloudflare-pages-preview.yml.github/workflows/codeql.yml.github/workflows/main.yml.github/workflows/react-component-ci.yml.github/workflows/react-doctor.yml.github/workflows/surge-preview.yml.gitignoreREADME.mdnow.jsonpackage.jsontsconfig.jsonvercel.json
💤 Files with no reviewable changes (2)
- now.json
- .github/workflows/main.yml
|
Deployment failed with the following error: Learn More: https://vercel.com/afc163s-projects?upgradeToPro=build-rate-limit |
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|

Summary
Standardize this rc-component repository as part of the Ant Design rc-component maintenance sweep.
Tracking issue: ant-design/ant-design#58514
Scope
types: "./es/index.d.ts", publishConfig, and release flow through@rc-component/np.react-component/rc-test/.github/workflows/test-utoo.yml@mainworkflow, React Doctor, Codecov, CodeQL, updated GitHub Actions versions, and guarded Surge preview fallback.docs-distoutput and remove legacynow-build/ Cloudflare Pages residue.Notes
secrets: inheritis kept untilreact-component/rc-test#176is merged, then it can be narrowed to explicitCODECOV_TOKENforwarding.