Skip to content

Conversation

thinkasany
Copy link
Member

🤔 This is a ...

  • 🆕 New feature

📝 Change Log

Language Changelog
🇺🇸 English feat: ConfigProvider support classnames and styles for notification
🇨🇳 Chinese feat: ConfigProvider support classnames and styles for notification

Copy link

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

Copy link
Contributor

github-actions bot commented Feb 12, 2025

👁 Visual Regression Report for PR #52759 Failed ❌

🎯 Target branch: next (aaf384a)
📖 View Full Report ↗︎
📖 Alternative Report ↗︎
📊 Summary: 🔄 2 changed

Expected (Branch next) Actual (Current PR) Diff
input-group.compact.png input-group.compact.png input-group.compact.css-var.png input-group.compact.css-var.png
input-otp.compact.png input-otp.compact.png input-otp.compact.css-var.png input-otp.compact.css-var.png

Important

There are 2 diffs found in this PR: 🔄 2 changed.
Please check all items:

  • Visual diff is acceptable

Copy link
Contributor

github-actions bot commented Feb 12, 2025

Preview is ready

Copy link

Walkthrough: This pull request introduces a new feature to the ConfigProvider, allowing support for classnames and styles customization for notifications. The changes involve replacing the message property with title in notifications and adding support for classNames and styles properties.

Changes:

Files Summary
components/notification/* Replaced message with title in notification components and added classNames and styles support.
components/config-provider/context.ts Updated NotificationConfig to include classNames and styles.
components/notification/interface.ts Deprecated message in favor of title and added classNames and styles.
components/notification/style/index.ts Updated styles to reflect the change from message to title.
components/notification/useNotification.tsx Integrated classNames and styles into notification handling.
components/notification/PurePanel.tsx Enhanced PurePanel to support classNames and styles.
components/notification/demo/* Updated demo files to use title instead of message.
components/notification/tests/* Adjusted tests to reflect the changes from message to title.

@@ -34,13 +34,17 @@ export function getCloseIcon(prefixCls: string, closeIcon?: React.ReactNode): Re
export interface PureContentProps {
prefixCls: string;
icon?: React.ReactNode;
/** @deprecated Please use `title` instead */

Choose a reason for hiding this comment

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

The message property is deprecated, and title should be used instead. Ensure that all instances of message are replaced with title to maintain consistency and avoid deprecated warnings.

Copy link
Contributor

github-actions bot commented Feb 12, 2025

size-limit report 📦

Path Size
dist/antd.min.js 503.33 KB (+394 B 🔺)
dist/antd-with-locales.min.js 572.33 KB (+361 B 🔺)

Copy link

pkg-pr-new bot commented Feb 12, 2025

Copy link

codecov bot commented Feb 12, 2025

Bundle Report

Changes will increase total bundle size by 7.92MB (212.09%) ⬆️⚠️, exceeding the configured threshold of 5%.

Bundle name Size Change
antd.min-array-push 11.65MB 7.92MB (212.09%) ⬆️⚠️

Affected Assets, Files, and Routes:

view changes for bundle: antd.min-array-push

Assets Changed:

Asset Name Size Change Total Size Change (%)
antd-with-locales.js (New) 6.08MB 6.08MB 100.0% 🚀
antd.js (New) 5.57MB 5.57MB 100.0% 🚀
antd-with-locales.min.js (Deleted) -2.02MB 0 bytes -100.0% 🗑️
antd.min.js (Deleted) -1.71MB 0 bytes -100.0% 🗑️

Files in antd-with-locales.js:

  • ./components/config-provider/context.ts → Total Size: 1.51kB

Files in antd.js:

  • ./components/config-provider/context.ts → Total Size: 1.51kB

Copy link

cloudflare-workers-and-pages bot commented Feb 12, 2025

Deploying ant-design with  Cloudflare Pages  Cloudflare Pages

Latest commit: 088f36d
Status: ✅  Deploy successful!
Preview URL: https://9c0ac8bf.ant-design.pages.dev
Branch Preview URL: https://cp-notifaction.ant-design.pages.dev

View logs

Copy link

codecov bot commented Feb 12, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (e6d4eb0) to head (088f36d).
Report is 4 commits behind head on next.

Additional details and impacted files
@@            Coverage Diff            @@
##              next    #52759   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          765       765           
  Lines        13769     13781   +12     
  Branches      3601      3608    +7     
=========================================
+ Hits         13769     13781   +12     

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

@zombieJ zombieJ merged commit 2a7f2e0 into next Feb 13, 2025
42 checks passed
@zombieJ zombieJ deleted the cp-notifaction branch February 13, 2025 03:08
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