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: Divider Component Token #42627

Merged
merged 12 commits into from
Aug 11, 2023

Conversation

hms181231
Copy link
Contributor

@hms181231 hms181231 commented May 25, 2023

[中文版模板 / Chinese template]

🤔 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

💡 Background and solution

ref #41884

📝 Changelog

Language Changelog
🇺🇸 English Add Divider Component Token.
🇨🇳 Chinese 添加 Divider 的 Component Token。

☑️ 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 62ec5bf

Refactored the Divider component to use a new component token for the vertical gutter margin and updated the documentation in both English and Chinese to reflect this change. Deprecated the less variables related to the Divider component.

🔍 Walkthrough

🤖 Generated by Copilot at 62ec5bf

  • Rename and move dividerVerticalGutterMargin property to verticalGutterMargin in ComponentToken interface (link)
  • Update genSharedDividerStyle function to use verticalGutterMargin property instead of dividerVerticalGutterMargin property (link)
  • Remove dividerVerticalGutterMargin property from genDefaultComponentToken function (link)
  • Modify genDefaultComponentToken function to return a function that takes global token as argument and returns an object with verticalGutterMargin and sizePaddingEdgeHorizontal properties (link)
  • Add new section for Divider component in English documentation with new component token and deprecated less variables (docs/react/migrate-less-variables.en-US.md, link)
  • Add new section for Divider component in Chinese documentation with new component token and deprecated less variables (docs/react/migrate-less-variables.zh-CN.md, link)

@github-actions
Copy link
Contributor

github-actions bot commented May 25, 2023

@codecov
Copy link

codecov bot commented May 25, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (ba90af1) 100.00% compared to head (1eac958) 100.00%.
Report is 1 commits behind head on feature.

Additional details and impacted files
@@            Coverage Diff            @@
##           feature    #42627   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          663       663           
  Lines        11273     11274    +1     
  Branches      3047      3047           
=========================================
+ Hits         11273     11274    +1     
Files Changed Coverage Δ
components/divider/style/index.ts 100.00% <100.00%> (ø)

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

@yoyo837 yoyo837 mentioned this pull request May 26, 2023
51 tasks
@kiner-tang
Copy link
Member

@hms181231 可以参考这个 pr 添加一个 component token 的 debug demo

@kiner-tang
Copy link
Member

kiner-tang commented May 26, 2023

CI 挂了,可以本地运行 yarn test:update components/divider/ 更新一下快照

@hms181231
Copy link
Contributor Author

@MadCcc 大佬空了看看这个 有需要更改的 我这边及时调整

@MadCcc
Copy link
Member

MadCcc commented Aug 10, 2023

这边拖了比较久不好意思,我直接收尾了哈,感谢贡献

@argos-ci
Copy link

argos-ci bot commented Aug 10, 2023

The latest updates on your projects. Learn more about Argos notifications ↗︎

Build Status Details Updated (UTC)
default (Inspect) 👍 Changes approved 1 change Aug 11, 2023, 4:05 AM

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