Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Nov 25, 2025

  • Review Ant Design v6 migration guide and breaking changes
  • Update antd dependency from ^5.28.1 to ^6.0.0
  • Update peerDependencies for antd to ^6.0.0
  • Update @ant-design/cssinjs from ^1.24.0 to ^2.0.1
  • Update @ant-design/icons from ^5.6.1 to ^6.1.0
  • Update React peer dependency from >=17.0.0 to >=18.0.0
  • Fix useStyle hook to work with new useStyleRegister return type (void)
  • Update Popover styles API from 'body' to 'container'
  • Add required cssVar configuration to useCacheToken
  • Run TypeScript type check - all errors fixed
  • Run build - compilation succeeds
  • Update test snapshots for antd v6
  • Run tests to verify functionality
  • Address any test failures
  • Review and update documentation if needed
Original prompt

升级到 antd v6


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

@coderabbitai
Copy link

coderabbitai bot commented Nov 25, 2025

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


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

Co-authored-by: afc163 <507615+afc163@users.noreply.github.com>
@socket-security
Copy link

socket-security bot commented Nov 25, 2025

@afc163
Copy link
Member

afc163 commented Nov 25, 2025

@copilot snapshot 需要更新一下

Co-authored-by: afc163 <507615+afc163@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Nov 25, 2025

@copilot snapshot 需要更新一下

已更新 snapshot,提交在 84ff1af

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • at.alicdn.com
    • Triggering command: /usr/local/bin/node /usr/local/bin/node -e const sendRequest = require(&#39;http&#39;).request; const options = { &#34;method&#34;: &#34;GET&#34;, &#34;headers&#34;: { &#34;Accept&#34;: &#34;*/*&#34;, &#34;Accept-Encoding&#34;: &#34;gzip, deflate, br&#34;, &#34;Connection&#34;: &#34;close&#34;, &#34;Referer&#34; (dns block)
  • proapi.azurewebsites.net
    • Triggering command: /usr/local/bin/node /usr/local/bin/node --conditions node --conditions development /home/REDACTED/work/pro-components/pro-components/node_modules/.pnpm/tinypool@1.1.1/node_modules/tinypool/dist/index.js/../entry/process.js (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

@XuJin186
Copy link

@afc163 大佬 还继续嘛

@afc163
Copy link
Member

afc163 commented Nov 26, 2025

@XuJin186 欢迎 PR

@gin-lsl
Copy link

gin-lsl commented Dec 2, 2025

我看有许多测试用例失败只是由于 class 有变化,例如 .ant-select-selector 应该改为 .ant-select-content 之类的
但是我怎么 at 不出来 copilot @afc163

chenshuai2144 and others added 7 commits December 3, 2025 09:51
…eplacing '.ant-select-selector' with '.ant-select' and '.ant-select-selection-search-input' with '.ant-select-input' across multiple test files.
… replacing '.ant-steps-icon' with '.ant-steps-item-icon' in multiple test files, and enhancing error message checks in utils tests.
…ity, updating '.ant-select-input' to '.ant-select-selection-search-input' and adjusting query selectors to use 'document.body' for dropdown items. Enhance assertions for dropdown item counts and ensure proper interaction with the updated Ant Design components.
… Ant Design v6 compatibility. Update query selectors to use '.ant-select' and adjust dropdown item checks to ensure proper interaction with the updated components. Enhance waitFor assertions for asynchronous operations and improve overall test clarity.
… use 'orientation' prop instead of 'type'. Update Drawer and SiderMenu components to use 'size' prop instead of 'width' for better consistency across the application.
let {
token = {} as Record<string, any> as ProAliasToken,
hashed,
prefixCls,

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused variable prefixCls.

Copilot Autofix

AI about 1 month ago

To fix this issue, simply remove prefixCls from the destructured variables in the let declaration (lines 100–104). This change will not affect the logic or behavior of the function, as prefixCls is not used anywhere in the code block. There’s no need to add any imports, definitions, or other structures. Only the destructuring line needs to be edited: replace

let { token = {} as Record<string, any> as ProAliasToken, hashed, prefixCls } = useContext(ProProvider);

with

let { token = {} as Record<string, any> as ProAliasToken, hashed } = useContext(ProProvider);

Suggested changeset 1
src/provider/useStyle/index.ts

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/src/provider/useStyle/index.ts b/src/provider/useStyle/index.ts
--- a/src/provider/useStyle/index.ts
+++ b/src/provider/useStyle/index.ts
@@ -100,7 +100,6 @@
   let {
     token = {} as Record<string, any> as ProAliasToken,
     hashed,
-    prefixCls,
   } = useContext(ProProvider);
 
   const { token: antdToken, hashId, theme } = antdTheme.useToken();
EOF
@@ -100,7 +100,6 @@
let {
token = {} as Record<string, any> as ProAliasToken,
hashed,
prefixCls,
} = useContext(ProProvider);

const { token: antdToken, hashId, theme } = antdTheme.useToken();
Copilot is powered by AI and may make mistakes. Always verify output.
…, updating button selectors in list toolbar tests and adding additional wait conditions in utils tests to ensure proper rendering of popover content.
…d improve layout consistency. Update card divider classes to remove unnecessary vertical orientation and enhance layout structure across multiple demo files. Adjust footer styles in layout demos for better spacing and visual alignment.
… replacing references to '.ant-popover-inner-content' with '.ant-popover-content' to ensure accurate rendering and error message checks.
chenshuai2144 and others added 3 commits December 25, 2025 14:56
* Refactor: Update migration guide and homepage content

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Refactor: Update documentation for ProComponents

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
* Refactor: Remove unused nav property from markdown files

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Refactor: Remove hyphens from component titles

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Refactor: Update titles and add frontmatter check script

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
* Remove redundant titles from demo components

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Refactor: Remove redundant titles from code examples

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Revert "Remove redundant titles from demo components"

This reverts commit 0f1ec6b.

* feat: Add padding to all demo examples

This change adds a consistent padding of 24px to all demo examples to improve their visual presentation and spacing.

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Revert "feat: Add padding to all demo examples"

This reverts commit c8dc966.

* feat: add padding to demo components

- Wrap demo components with a div container having 24px padding
- Fix linting and formatting issues
- Rename default exports to named components for better debugging

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
@dydevel-ux
Copy link

期待。。。

chenshuai2144 and others added 8 commits December 25, 2025 18:06
* docs: update SchemaForm documentation with missing API definitions

Update SchemaForm documentation to include missing props in API and Schema tables:
- Add title, action, formRef, open to API table
- Add width, colSize, readonly, initialValue, convertValue, transform, order, debounceTime, defaultKeyWords, ignoreFormItem to Schema Definition table
- Update columns type definition

* docs: restructure SchemaForm demos by layout type

Organize code examples into clear categories:
- Layout Types: Form, Modal/Drawer, Steps, Embed
- Advanced Usage: Dependency, Performance, FormList
This improves readability and helps users find examples for specific use cases.

* docs: detail SchemaForm usage guides and API

Enhance documentation with detailed explanations:
- Add descriptions for each layout type example (Form, Modal, Steps, Embed)
- Add list of common valueTypes
- Add section explaining fieldProps vs formItemProps with code example
- Add explanation for performance optimization props (shouldUpdate/dependencies)

* docs: synchronize SchemaForm English documentation

Update English documentation to match Chinese version changes:
- Update API and Schema Definition tables with new props
- Add ProFormLayoutType section
- Add Common ValueTypes table
- Add fieldProps vs formItemProps explanation
- Restructure demos by layout types and advanced usage
- Update demo descriptions and titles

* chore: format documentation with prettier

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
…o-components into copilot/upgrade-to-antd-v6
…nsistency

- Standardized parameter tables across multiple components, including ProTable, ProForm, and ProDescriptions, for improved readability.
- Added missing properties and updated descriptions in the API tables for better user guidance.
- Enhanced demo references with consistent IDs for easier navigation and linking.
- Improved formatting and structure in migration guides and other documentation files to align with recent changes and maintain consistency.
- Introduced AGENTS.md to provide comprehensive guidelines for the ant-design/ant-design project.
- Included sections on project background, installation, development commands, coding standards, naming conventions, API documentation, TypeScript practices, styling guidelines, testing protocols, and internationalization.
- Ensured clarity and consistency in documentation to assist developers in adhering to project standards.
* Update changelog dates to 2025-07-24

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Update changelog dates to 2025-07-24

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Refactor: Update changelog for ProComponents v3

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Refactor: Update changelog for ProComponents v3.0

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

* Remove schema documentation and navigation links

Co-authored-by: qixian.cs <qixian.cs@outlook.com>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
…o-components into copilot/upgrade-to-antd-v6
@chenshuai2144 chenshuai2144 marked this pull request as ready for review December 26, 2025 05:16
Copilot AI review requested due to automatic review settings December 26, 2025 05:16
@dosubot dosubot bot added the size:XL This PR changes 500-999 lines, ignoring generated files. label Dec 26, 2025
Copy link
Contributor

Copilot AI left a comment

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 upgrades the project to Ant Design v6, implementing comprehensive breaking changes and API updates across the entire codebase to ensure compatibility with the new version.

Key Changes

  • Upgraded core dependencies to antd v6, @ant-design/icons v6, and @ant-design/cssinjs v2
  • Updated React peer dependency requirement from >=17.0.0 to >=18.0.0
  • Replaced deprecated API properties throughout components (e.g., bodyStylestyles, tabPositiontabPlacement)
  • Removed IE 11 support from browser compatibility list

Reviewed changes

Copilot reviewed 299 out of 999 changed files in this pull request and generated no comments.

Show a summary per file
File Description
package.json Updated all Ant Design dependencies to v6, updated React peer dependency to >=18.0.0, removed IE 11 from browser support
site/changelog.md Added comprehensive changelog documenting v6 upgrade and breaking changes
site/changelog.en-US.md English version of changelog with v6 upgrade details
site/components/form/LoginForm/index.md Removed LoginForm documentation file
site/components/form/LoginForm/index.en-US.md Removed English LoginForm documentation file
site/components/form/Group/index.md Removed ProFormList documentation file
site/components/form/Group/index.en-US.md Removed English ProFormList documentation file
site/components/form/FieldSet/index.md Removed ProFormFields documentation file
site/components/form/FieldSet/index.en-US.md Removed English ProFormFields documentation file
site/components/form/Dependency/index.md Removed ProFormDependency documentation file
site/components/form/Dependency/index.en-US.md Removed English ProFormDependency documentation file
site/components/field/index.md Updated navigation structure for ProField documentation
site/components/field/index.en-US.md Updated navigation and added API type information
site/components/field-set/index.md Updated documentation reference from onDropdownVisibleChange to onOpenChange
site/components/field-set/index.en-US.md Updated English documentation for API changes
site/components/editable-table/index.md Removed navigation structure from EditableProTable documentation
site/components/editable-table/index.en-US.md Removed title attribute from code example
site/components/drag-sort-table/index.md Removed title attribute from code example
site/components/descriptions/index.md Removed title attributes from code examples and updated navigation
site/components/descriptions/index.en-US.md Added missing API documentation and reorganized content
site/components/dependency/index.md Removed title attributes from code examples
site/components/check-card/index.md Removed CheckCard documentation file with comprehensive API tables
site/components/check-card/index.en-US.md Removed English CheckCard documentation file
site/components/card/index.md Updated navigation structure
site/components/card/StatisticCard/index.md Removed StatisticCard documentation file
site/components/card/StatisticCard/index.en-US.md Removed English StatisticCard documentation file
site/components/card/CheckCard/index.md Removed nested CheckCard documentation file
site/components/card/CheckCard/index.en-US.md Removed nested English CheckCard documentation file
demos/table/valueType_select.tsx Wrapped component export with padding wrapper
demos/table/valueTypeNumber.tsx Wrapped component export with padding wrapper
demos/table/valueTypeDate.tsx Wrapped component export with padding wrapper
demos/table/valueType.tsx Wrapped component export with padding wrapper
demos/table/dynamic-settings.tsx Updated bodyStyle to styles.body for ProCard
demos/list/base.tsx Updated bodyStyle to styles.body for ProCard
demos/form/modalform-test.tsx Updated bodyStyle to styles.body for ProCard
demos/form/formRef.tsx Replaced Button.Group with Space.Compact per antd v6 changes
demos/form/SchemaForm/schema.tsx Replaced deprecated direction with orientation and message with title in Alert
demos/form/SchemaForm/ModalAndDrawerForm.tsx Replaced deprecated props in Alert and Space components
demos/form/QueryFilter/light-filter-footer.tsx Replaced direction with orientation in Space component
demos/layout/footer-global-tools.tsx Replaced Alert message prop with title
demos/layout/immersive-navigation.tsx Wrapped icon image in proper img tag instead of string URL
demos/layout/Group/horizontal-layout.tsx Updated bodyStyle to styles.body for ProCard
demos/layout/PageHeader/*.tsx Added new PageHeader demo files with proper exports
Comments suppressed due to low confidence (5)

site/components/form/Group/index.md:1

  • Extra opening parenthesis before <code. Remove the ( character.
    site/components/form/Group/index.md:1
  • Missing opening quote before the path. Should be src="../../../../demos/form/Group/countLimit.tsx".
    site/components/form/Group/index.md:1
  • Double slashes in the file path. Should be src="../../../../demos/form/Group/horizontal-layout.tsx".
    site/components/form/Group/index.md:1
  • Double slashes in the file path. Should be src="../../../../demos/form/Group/list-arrowsort.tsx".
    site/components/form/FieldSet/index.md:1
  • Git merge conflict markers are present in the file. The conflict between HEAD and the current branch needs to be resolved by choosing the appropriate version and removing the conflict markers.

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

@chenshuai2144 chenshuai2144 changed the title [WIP] Upgrade to antd v6 Upgrade to antd v6 Dec 26, 2025
@chenshuai2144 chenshuai2144 merged commit f26b778 into master Dec 26, 2025
13 checks passed
@chenshuai2144 chenshuai2144 deleted the copilot/upgrade-to-antd-v6 branch December 26, 2025 06:24
@XuJin186
Copy link

发版咯

@zhengmenghuang
Copy link

大佬 666

@zhengmenghuang
Copy link

image 这个是不是 写反了

@dosubot dosubot bot mentioned this pull request Dec 26, 2025
@echoyl
Copy link
Contributor

echoyl commented Dec 26, 2025

大佬 666

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL This PR changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.