Skip to content

chore: update maintenance dependencies#317

Merged
afc163 merged 18 commits into
masterfrom
codex/update-maintenance-deps
Jul 3, 2026
Merged

chore: update maintenance dependencies#317
afc163 merged 18 commits into
masterfrom
codex/update-maintenance-deps

Conversation

@afc163

@afc163 afc163 commented Jun 29, 2026

Copy link
Copy Markdown
Member

Summary

  • Link the Ant Design ecosystem logo in README files to https://ant.design
  • Update React, React DOM, TypeScript, ESLint, Testing Library, @types/, @typescript-eslint/, lint-staged, and related lint dependencies
  • Add ESLint flat config compatibility for ESLint 9 and TypeScript ESLint 8
  • Use grouped Dependabot updates for npm and GitHub Actions

Test Plan

  • npm run lint
  • npm run tsc

Summary by CodeRabbit

  • Documentation

    • 更新 README 中的品牌入口链接,顶部徽标现在可直接跳转到官网。
    • 同步更新中文说明中的同类链接体验。
  • Chores

    • 优化依赖更新分组方式,后续自动更新更清晰。
    • 升级并补充开发、测试与代码检查相关依赖,整体工具链更一致。
  • Bug Fixes

    • 调整类型与项目配置,提升构建、编辑器提示和测试环境兼容性。

@vercel

vercel Bot commented Jun 29, 2026

Copy link
Copy Markdown

Deployment failed with the following error:

Resource is limited - try again in 24 hours (more than 100, code: "api-deployments-free-per-day").

Learn More: https://vercel.com/react-component?upgradeToPro=build-rate-limit

@coderabbitai

coderabbitai Bot commented Jun 29, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It 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 reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

Walkthrough

本次变更升级了开发依赖版本、新增 ESLint Flat Config 配置文件、补充全局类型声明文件(global.d.ts)、调整 TypeScript 编译选项、为 Dependabot 新增依赖分组,并在 README 与 README.zh-CN 顶部标识增加了跳转链接。

Changes

工具链现代化

Layer / File(s) Summary
devDependencies 升级与新增
package.json
新增多项 ESLint/Babel/Testing Library 相关开发依赖,并升级 ESLint、TypeScript、React、React-DOM、Prettier、lint-staged 等版本。
ESLint Flat Config
eslint.config.mjs
新增基于 FlatCompat 的 Flat Config,兼容旧版 .eslintrc.js,聚合推荐与本地 @typescript-eslint 规则并归一化配置,顶层关闭部分规则。
全局类型声明与 TypeScript 配置
global.d.ts, tsconfig.json
新增全局类型声明文件覆盖测试、CSS/LESS 模块、JSX 命名空间及 vi 全局变量;tsconfig.json 调整 moduleResolution、严格性选项并纳入 global.d.ts。
Dependabot 分组与 README 链接
.github/dependabot.yml, README.md, README.zh-CN.md
Dependabot 为 npm 与 github-actions 更新新增分组配置;README 与 README.zh-CN 顶部徽标增加指向 ant.design 的链接。

Estimated code review effort: 2 (Simple) | ~12 minutes

Poem

兔子小跑修工具链,
新配置文件闪闪发光,
类型声明补齐缝隙,
链接一点跳向远方,
依赖升级不慌张,
🐇✨ 洞里也要跟上时代!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed 标题准确概括了本次以维护性依赖和相关工具链更新为主的改动。
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/update-maintenance-deps

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

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 updates the project's dependencies to React 19, ESLint 9, and TypeScript 6, introduces an ESLint flat configuration, and adds type declaration files for compatibility. Feedback on these changes emphasizes maintaining type safety: you should avoid disabling strict type-checking in tsconfig.json, refrain from globally overriding core React types in react-compat.d.ts to prevent consumer type conflicts, and remove redundant any declarations for testing globals in global.d.ts since Jest types are already referenced.

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.

Comment thread tsconfig.json Outdated
Comment thread react-compat.d.ts Outdated
Comment thread global.d.ts Outdated
@socket-security

socket-security Bot commented Jun 29, 2026

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatednpm/​@​types/​jest@​29.5.14 ⏵ 30.0.01001007780100
Addednpm/​@​types/​react@​19.2.171001007995100
Addednpm/​@​eslint/​js@​9.39.410010010088100
Addednpm/​typescript@​6.0.3100100909690
Addednpm/​eslint@​9.39.49710010096100

View full report

@socket-security

socket-security Bot commented Jun 29, 2026

Copy link
Copy Markdown

All alerts resolved. Learn more about Socket for GitHub.

This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored.

View full report

@github-actions

github-actions Bot commented Jun 29, 2026

Copy link
Copy Markdown

✅ Preview is ready!

PR preview ✅ Ready ✅ Ready
🔗 Preview https://react-component-progress-preview-pr-317.surge.sh
📝 Commita6d62cb
⏱️ Build time20.204s
📦 Size1.7 MB (+1.2 KB ⬆️) · 49 files
🪵 LogsView logs
📱 MobileScan to open preview on mobile

↩️ Previous: ⚡️ a6d62cb · react-component-progress-preview-pr-317.surge.sh (open ↗) · 2026-07-03 03:04:09 UTC

🤖 Powered by surge-preview

@vercel

vercel Bot commented Jun 29, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
progress Ready Ready Preview, Comment Jul 3, 2026 3:09am

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
package.json (1)

49-80: 🩺 Stability & Availability | 🔵 Trivial

补一条打包/文档冒烟检查。 这次同时升级了 fatherdumi,而 npm run lint / npm run tsc 覆盖不到 npm run buildnpm run docs:buildnpm run compile 这条链路;合并前至少再补一条库构建和文档站点构建检查。

🤖 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 `@package.json` around lines 49 - 80, The dependency upgrades in package.json
affect the build and docs toolchain, but the current validation only covers
linting and type checking. Add a smoke-check for the build path by running
and/or documenting verification for the library build and docs site build, using
the existing scripts such as build, docs:build, and compile, so the father and
dumi upgrade is covered before merge.
🤖 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 `@eslint.config.mjs`:
- Around line 40-48: `next.rules` 的过滤逻辑把迁移中需要保留的
`@typescript-eslint/no-explicit-any` 丢掉了,导致原来在 `.eslintrc.js` 里显式关闭的规则在 flat
config 中失效。请在 `eslint.config.mjs` 的这段 allowlist 过滤中把
`@typescript-eslint/no-explicit-any` 加回去,或者在最终的 flat config `rules`
合并结果里再次显式关闭它,确保迁移后的行为与现有配置一致。

---

Nitpick comments:
In `@package.json`:
- Around line 49-80: The dependency upgrades in package.json affect the build
and docs toolchain, but the current validation only covers linting and type
checking. Add a smoke-check for the build path by running and/or documenting
verification for the library build and docs site build, using the existing
scripts such as build, docs:build, and compile, so the father and dumi upgrade
is covered before merge.
🪄 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: a88ad097-d820-49f0-a48f-5c1622bf7c23

📥 Commits

Reviewing files that changed from the base of the PR and between a3242bc and f61a75b.

📒 Files selected for processing (8)
  • .github/dependabot.yml
  • README.md
  • README.zh-CN.md
  • eslint.config.mjs
  • global.d.ts
  • package.json
  • react-compat.d.ts
  • tsconfig.json

Comment thread eslint.config.mjs Outdated
@codecov

codecov Bot commented Jun 30, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.38%. Comparing base (a3242bc) to head (a6d62cb).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #317   +/-   ##
=======================================
  Coverage   99.38%   99.38%           
=======================================
  Files           7        7           
  Lines         162      162           
  Branches       51       51           
=======================================
  Hits          161      161           
  Misses          1        1           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 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 `@tsconfig.json`:
- Line 7: The tsconfig setting currently skips declaration checking, which can
hide issues in the new compatibility layer. Update the tsconfig entry for
skipLibCheck to stop bypassing checks so the newly added global.d.ts and
react-compat.d.ts are type-checked, and make sure the package’s d.ts output is
validated; if needed, add a type-check path that runs without skipLibCheck.
🪄 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: 1dd7cf04-88f2-4569-823e-d3cdc0f1de02

📥 Commits

Reviewing files that changed from the base of the PR and between f61a75b and 3cd96eb.

📒 Files selected for processing (3)
  • eslint.config.mjs
  • global.d.ts
  • tsconfig.json
💤 Files with no reviewable changes (1)
  • global.d.ts

Comment thread tsconfig.json
@vercel

vercel Bot commented Jun 30, 2026

Copy link
Copy Markdown

Deployment failed with the following error:

Resource is limited - try again in 24 hours (more than 100, code: "api-deployments-free-per-day").

Learn More: https://vercel.com/afc163s-projects?upgradeToPro=build-rate-limit

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
eslint.config.mjs (1)

79-89: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

建议补充注释说明 noopRule 覆盖 consistent-type-exports 的用意

这里用 noopRule 替换插件规则实现(而不是简单在 rules 中设为 'off'),结合后面 normalizeConfig 会删除旧配置数组里重复注册的 '@typescript-eslint' 插件条目,从而保证该 noop 版本不会被后续 compat.config(legacyConfig) 展开的普通插件对象覆盖。这个设计是必要且正确的,但相当隐晦——从 past review 的排查记录也能看出,仅从代码本身很难看出这层因果关系。建议在此处加一行注释说明为什么要用 noop 而不是直接关闭规则severity,方便后续维护者理解。

💡 建议的注释补充
     plugins: {
+      // 用 noop 覆盖规则实现而非仅设置 severity=off,
+      // 因为后续 compat.config(legacyConfig) 展开的配置项会重新注册未修改的
+      // '`@typescript-eslint`' 插件;normalizeConfig 已将这些旧配置里的插件条目剔除,
+      // 以保证此处的 noop 版本在合并后仍然生效。
       '`@typescript-eslint`': {
         ...tsEslintPlugin,
         rules: {
           ...tsEslintPlugin.rules,
           'consistent-type-exports': noopRule,
         },
       },
     },
🤖 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 `@eslint.config.mjs` around lines 79 - 89, This section uses noopRule to
override '`@typescript-eslint/consistent-type-exports`' instead of simply
disabling it, because the later compat.config(legacyConfig) expansion can
reintroduce a normal plugin object and overwrite a plain severity toggle. Add a
brief comment near the plugins setup and normalizeConfig mapping explaining that
the noop override is intentional and protects against legacy config collisions.
Reference noopRule, consistent-type-exports, and normalizeConfig so future
maintainers can quickly locate the rationale.
🤖 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.

Nitpick comments:
In `@eslint.config.mjs`:
- Around line 79-89: This section uses noopRule to override
'`@typescript-eslint/consistent-type-exports`' instead of simply disabling it,
because the later compat.config(legacyConfig) expansion can reintroduce a normal
plugin object and overwrite a plain severity toggle. Add a brief comment near
the plugins setup and normalizeConfig mapping explaining that the noop override
is intentional and protects against legacy config collisions. Reference
noopRule, consistent-type-exports, and normalizeConfig so future maintainers can
quickly locate the rationale.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 348ffa86-f93f-4543-83af-577d35ea94c8

📥 Commits

Reviewing files that changed from the base of the PR and between 902bb92 and 40ff399.

📒 Files selected for processing (1)
  • eslint.config.mjs

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
tsconfig.json (1)

14-20: 🎯 Functional Correctness | 🔵 Trivial | 🏗️ Heavy lift

不要把严格检查一次性全部关掉。 strict 及相关选项都设为 false,而这个包还会输出并发布 es/index.d.ts,容易把类型问题继续带到对外声明里;如果只是迁移期妥协,建议保留一份收紧计划,逐步恢复这些检查。

🤖 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 `@tsconfig.json` around lines 14 - 20, The TypeScript config is disabling all
strictness checks at once, which can let type issues leak into the published
declaration output from the package’s public API. Update the tsconfig strictness
settings so they are not all turned off together, and use the existing config
keys like strict, noImplicitAny, strictNullChecks, and
strictPropertyInitialization to keep a gradual tightening path instead of a full
blanket disable.
🤖 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 `@package.json`:
- Line 63: Remove or replace the `@umijs/fabric` dependency from the package.json
ESLint toolchain so the project can move to ESLint 9 and `@typescript-eslint` 8;
update the lint configuration around eslint.config.mjs and any shared presets
that currently rely on `@umijs/fabric`@^4.0.1, and switch to compatible
replacements so the upgrade path no longer depends on that package.

---

Nitpick comments:
In `@tsconfig.json`:
- Around line 14-20: The TypeScript config is disabling all strictness checks at
once, which can let type issues leak into the published declaration output from
the package’s public API. Update the tsconfig strictness settings so they are
not all turned off together, and use the existing config keys like strict,
noImplicitAny, strictNullChecks, and strictPropertyInitialization to keep a
gradual tightening path instead of a full blanket disable.
🪄 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: 0eae8b11-ab72-49e7-9ee9-ddadb91b21d6

📥 Commits

Reviewing files that changed from the base of the PR and between 40ff399 and c0f464f.

⛔ Files ignored due to path filters (2)
  • tests/__snapshots__/conic.spec.tsx.snap is excluded by !**/*.snap
  • tests/__snapshots__/index.spec.js.snap is excluded by !**/*.snap
📒 Files selected for processing (4)
  • README.md
  • eslint.config.mjs
  • package.json
  • tsconfig.json
💤 Files with no reviewable changes (1)
  • README.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • eslint.config.mjs

Comment thread package.json Outdated
@afc163

afc163 commented Jul 1, 2026

Copy link
Copy Markdown
Member Author

Related to ant-design/ant-design#58514.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modernizes the repository’s maintenance tooling by updating core frontend/tooling dependencies, migrating ESLint to the flat config format for ESLint 9 / TypeScript ESLint 8 compatibility, and making minor documentation and automation tweaks.

Changes:

  • Updated dev tooling dependencies (React/ReactDOM, TypeScript, ESLint + plugins, Testing Library, etc.).
  • Replaced legacy .eslintrc.js with a new eslint.config.mjs (flat config) and adjusted TypeScript configuration.
  • Updated README branding links and refreshed Jest snapshot header links; grouped Dependabot updates.

Reviewed changes

Copilot reviewed 8 out of 10 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
tsconfig.json Switches module resolution mode and restructures TS config/paths/includes.
package.json Updates devDependencies for the toolchain (ESLint 9, TS/React/testing deps, etc.).
eslint.config.mjs Introduces ESLint flat config with React/TS/Jest integration and ignores.
.eslintrc.js Removes legacy ESLint config (superseded by flat config).
global.d.ts Adds a shared global typings entrypoint and references for common test/runtime types.
.github/dependabot.yml Adds grouped updates for npm dependencies and GitHub Actions.
README.md Links Ant Design ecosystem logo to https://ant.design and removes an extra blank line.
README.zh-CN.md Links Ant Design ecosystem logo to https://ant.design.
tests/snapshots/index.spec.js.snap Updates the snapshot header URL.
tests/snapshots/conic.spec.tsx.snap Updates the snapshot header URL.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread eslint.config.mjs Outdated
Comment thread eslint.config.mjs
@afc163 afc163 merged commit 8802583 into master Jul 3, 2026
15 checks passed
@afc163 afc163 deleted the codex/update-maintenance-deps branch July 3, 2026 12:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants