Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add style/className/styles/classNames to ConfigProvider #42623

Merged
merged 5 commits into from
May 26, 2023

Conversation

LuZhenJie1999
Copy link
Member

@LuZhenJie1999 LuZhenJie1999 commented May 25, 2023

🤔 This is a ...

  • New feature
  • Bug fix
  • Site / documentation update
  • Demo update
  • Component style update
  • TypeScript definition update
  • Bundle size optimization
  • Performance optimization
  • Enhancement feature
  • Internationalization
  • Refactoring
  • Code style optimization
  • Test Case
  • Branch merge
  • Workflow
  • Other (about what?)

🔗 Related issue link

#39862

💡 Background and solution

add style/styles/className/classNames to ConfigProvider for button

📝 Changelog

Language Changelog
🇺🇸 English add style/styles/className/classNames to ConfigProvider for button
🇨🇳 Chinese ConfigProvider 可自定义 button 的 style/className/styles/classNames

☑️ Self-Check before Merge

⚠️ Please check all items below before requesting a reviewing. ⚠️

  • Doc is updated/provided or not needed
  • Demo is updated/provided or not needed
  • TypeScript definition is updated/provided or not needed
  • Changelog is provided or not needed

🚀 Summary

🤖 Generated by Copilot at 32c90ac

This pull request adds a new feature to the ConfigProvider component, which allows users to customize the style and className props of the Button component globally. It updates the Button component, the ConfigContext interfaces, and the documentation to support this feature. It also adds a test file and fixes a minor issue in the Button component.

🔍 Walkthrough

🤖 Generated by Copilot at 32c90ac

  • Add button prop to ConfigProvider component to allow customizing Button component style and className (link, link, link, link, link, link, link)
  • Import and use IconWrapper component in Button component to wrap icon prop and apply styles and classes (link, link, link, link, link)
  • Remove duplicate import of IconWrapper component in Button component (link)
  • Reorder imports and add new line in context.ts file for readability (link)
  • Add test cases for ConfigProvider.button feature in button.test.tsx file (link)

@github-actions
Copy link
Contributor

github-actions bot commented May 25, 2023

@codecov
Copy link

codecov bot commented May 26, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (f09e9cb) 100.00% compared to head (c276c55) 100.00%.

Additional details and impacted files
@@            Coverage Diff            @@
##           feature    #42623   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          641       641           
  Lines        10891     10895    +4     
  Branches      2958      2960    +2     
=========================================
+ Hits         10891     10895    +4     
Impacted Files Coverage Δ
components/config-provider/context.ts 100.00% <ø> (ø)
components/config-provider/index.tsx 100.00% <ø> (ø)
components/button/button.tsx 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@MadCcc
Copy link
Member

MadCcc commented May 26, 2023

size-limit 超了
#42554
等等这个合了

MadCcc and others added 2 commits May 26, 2023 15:07
Co-authored-by: lijianan <574980606@qq.com>
Co-authored-by: lijianan <574980606@qq.com>
@MadCcc MadCcc merged commit b6442fe into ant-design:feature May 26, 2023
@MadCcc MadCcc mentioned this pull request Jun 6, 2023
20 tasks
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.

3 participants