From 284347c37fce77c619e2138a9ec3c77205b91a3f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 7 Nov 2023 04:10:41 +0800 Subject: [PATCH 1/7] chore: upgrade deps (#45692) Co-authored-by: afc163 --- package.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 6dcd78102f..bdec8adbcf 100644 --- a/package.json +++ b/package.json @@ -121,7 +121,7 @@ "@rc-component/color-picker": "~1.4.1", "@rc-component/mutate-observer": "^1.1.0", "@rc-component/tour": "~1.10.0", - "@rc-component/trigger": "^1.18.0", + "@rc-component/trigger": "^1.18.1", "classnames": "^2.3.2", "copy-to-clipboard": "^3.3.3", "dayjs": "^1.11.1", @@ -152,12 +152,12 @@ "rc-switch": "~4.1.0", "rc-table": "~7.35.2", "rc-tabs": "~12.13.1", - "rc-textarea": "~1.5.1", + "rc-textarea": "~1.5.2", "rc-tooltip": "~6.1.2", "rc-tree": "~5.8.2", "rc-tree-select": "~5.15.0", "rc-upload": "~4.3.5", - "rc-util": "^5.38.0", + "rc-util": "^5.38.1", "scroll-into-view-if-needed": "^3.1.0", "throttle-debounce": "^5.0.0" }, From 4a680365db4d52bccf56550528297348f1122224 Mon Sep 17 00:00:00 2001 From: afc163 Date: Tue, 7 Nov 2023 15:45:51 +0800 Subject: [PATCH 2/7] chore: remove unused config files (#45697) * Delete .github/tests_checker.yml Signed-off-by: afc163 * Delete .github/lock.yml Signed-off-by: afc163 --------- Signed-off-by: afc163 --- .github/lock.yml | 14 -------------- .github/tests_checker.yml | 3 --- 2 files changed, 17 deletions(-) delete mode 100644 .github/lock.yml delete mode 100644 .github/tests_checker.yml diff --git a/.github/lock.yml b/.github/lock.yml deleted file mode 100644 index e5b9a627f1..0000000000 --- a/.github/lock.yml +++ /dev/null @@ -1,14 +0,0 @@ -# Configuration for lock-threads - https://github.com/dessant/lock-threads - -# Number of days of inactivity before a closed issue or pull request is locked -daysUntilLock: 365 -# Comment to post before locking. Set to `false` to disable -lockComment: > - This thread has been automatically locked because it has not had recent - activity. Please open a new issue for related bugs and link to relevant - comments in this thread. -# Issues or pull requests with these labels will not be locked -# exemptLabels: -# - no-locking -# Limit to only `issues` or `pulls` -only: issues diff --git a/.github/tests_checker.yml b/.github/tests_checker.yml deleted file mode 100644 index 46378d7461..0000000000 --- a/.github/tests_checker.yml +++ /dev/null @@ -1,3 +0,0 @@ -comment: 'Could you please add tests to make sure this change works as expected?', -fileExtensions: [.ts', '.tsx', '.json'] -testDir: '__tests__' From d3fc8edefde37a1bf06b2f78f7e2d357bc627c1d Mon Sep 17 00:00:00 2001 From: afc163 Date: Tue, 7 Nov 2023 16:53:03 +0800 Subject: [PATCH 3/7] chore: fix codesandbox ci (#45698) Signed-off-by: afc163 --- .codesandbox/ci.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.codesandbox/ci.json b/.codesandbox/ci.json index c1e8e1305f..96c2526e4c 100644 --- a/.codesandbox/ci.json +++ b/.codesandbox/ci.json @@ -1,4 +1,4 @@ { - "sandboxes": ["antd-reproduction-template-y9vgcf"], - "node": "14" + "sandboxes": ["antd-reproduction-template-forked-jyh2k9"], + "node": "18" } From 380649ee761b7e12451093639bb3c0d28a1a39f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kiner-tang=28=E6=96=87=E8=BE=89=29?= <1127031143@qq.com> Date: Tue, 7 Nov 2023 18:28:09 +0800 Subject: [PATCH 4/7] fix: update tag default background (#45700) * fix: update tag default background * feat: remove unused code --------- Co-authored-by: afc163 --- components/tag/style/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/tag/style/index.ts b/components/tag/style/index.ts index c54b28f1f8..9f2eed666b 100644 --- a/components/tag/style/index.ts +++ b/components/tag/style/index.ts @@ -143,7 +143,7 @@ export const prepareToken: (token: Parameters>[0]) => TagToken }; export const prepareCommonToken: (token: GlobalToken) => ComponentToken = (token) => ({ - defaultBg: token.colorFillQuaternary, + defaultBg: token.colorBgContainer, defaultColor: token.colorText, }); From c614e814c94d1c2ba2493c64905cd88798d6a067 Mon Sep 17 00:00:00 2001 From: lijianan <574980606@qq.com> Date: Wed, 8 Nov 2023 10:05:50 +0800 Subject: [PATCH 5/7] chore: update README (#45707) --- README-zh_CN.md | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README-zh_CN.md b/README-zh_CN.md index aaa74d60c8..ff2c60baa5 100644 --- a/README-zh_CN.md +++ b/README-zh_CN.md @@ -104,7 +104,7 @@ export default App; ### 🛡 TypeScript -参考 [在 TypeScript 中使用](https://ant.design/docs/react/use-in-typescript-cn)。 +`antd` 使用 TypeScript 编写,具有完整的类型定义,参考 [在 create-react-app 中使用](https://ant.design/docs/react/use-with-create-react-app-cn)。 ## 🌍 国际化 diff --git a/README.md b/README.md index cae1958768..18fbbcd8ea 100644 --- a/README.md +++ b/README.md @@ -100,7 +100,7 @@ export default App; ### TypeScript -`antd` is written in TypeScript with complete definitions, check [Use in TypeScript](https://ant.design/docs/react/use-in-typescript) to get started. +`antd` is written in TypeScript with complete definitions, check [Usage with create-react-app](https://ant.design/docs/react/use-with-create-react-app) to get started. ## 🌍 Internationalization From b3cb6b30ed38c10d46f591186cdf53e5bb6fcd26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kiner-tang=28=E6=96=87=E8=BE=89=29?= <1127031143@qq.com> Date: Wed, 8 Nov 2023 10:43:02 +0800 Subject: [PATCH 6/7] fix: update tag default background (#45711) --- components/tag/style/index.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/components/tag/style/index.ts b/components/tag/style/index.ts index 9f2eed666b..27de1907d3 100644 --- a/components/tag/style/index.ts +++ b/components/tag/style/index.ts @@ -6,6 +6,7 @@ import type { GlobalToken } from '../../theme'; import type { FullToken } from '../../theme/internal'; import { genComponentStyleHook, mergeToken } from '../../theme/internal'; import type { GenStyleFn } from '../../theme/util/genComponentStyleHook'; +import { TinyColor } from '@ctrl/tinycolor'; export interface ComponentToken { /** @@ -143,7 +144,9 @@ export const prepareToken: (token: Parameters>[0]) => TagToken }; export const prepareCommonToken: (token: GlobalToken) => ComponentToken = (token) => ({ - defaultBg: token.colorBgContainer, + defaultBg: new TinyColor(token.colorFillQuaternary) + .onBackground(token.colorBgContainer) + .toHexString(), defaultColor: token.colorText, }); From 5ac3f57b7c6f18350d3b6501249f0062e9fc4e74 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=BA=A2?= Date: Wed, 8 Nov 2023 11:10:35 +0800 Subject: [PATCH 7/7] feat(modal): PureRender support custom footer callback (#44985) * demo: update debug demo * chore: improve typo * Revert "chore: improve typo" This reverts commit d5163f98ececa6266d34d68d9d4bc9f83cf06095. * chore: update * chore: update demo * chore: update snapshots * chore: update --- components/modal/PurePanel.tsx | 7 +- .../__snapshots__/demo-extend.test.ts.snap | 158 ++++++++++++++++++ .../__snapshots__/demo.test.tsx.snap | 158 ++++++++++++++++++ components/modal/demo/render-panel.tsx | 28 +++- 4 files changed, 347 insertions(+), 4 deletions(-) diff --git a/components/modal/PurePanel.tsx b/components/modal/PurePanel.tsx index 66ee59fcf2..7abde56479 100644 --- a/components/modal/PurePanel.tsx +++ b/components/modal/PurePanel.tsx @@ -13,8 +13,8 @@ import { Footer, renderCloseIcon } from './shared'; import useStyle from './style'; export interface PurePanelProps - extends Omit, - Pick { + extends Omit, + Pick { prefixCls?: string; style?: React.CSSProperties; } @@ -28,6 +28,7 @@ const PurePanel: React.FC = (props) => { type, title, children, + footer, ...restProps } = props; const { getPrefixCls } = React.useContext(ConfigContext); @@ -60,7 +61,7 @@ const PurePanel: React.FC = (props) => { additionalProps = { closable: closable ?? true, title, - footer: props.footer === undefined ?