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

fix: 🐛 Fix Button text not align center in Chrome #20059

Merged
merged 1 commit into from Dec 3, 2019

Conversation

afc163
Copy link
Member

@afc163 afc163 commented Dec 3, 2019

🤔 This is a ...

  • New feature
  • Bug fix
  • Site / document update
  • Component style update
  • TypeScript definition update
  • Refactoring
  • Code style optimization
  • Test Case
  • Branch merge
  • Other (about what?)

🔗 Related issue link

revert solution of 05181d5

close #19972
close #20058

💡 Background and solution

排查了下面所有问题,都能对齐。

📝 Changelog

Language Changelog
🇺🇸 English Fix Button text not align well in Chrome.
🇨🇳 Chinese 修复 Chrome 下 Button 文字没有垂直居中的问题。

☑️ Self Check before Merge

  • 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

@auto-add-label auto-add-label bot added the bug label Dec 3, 2019
@afc163 afc163 changed the title 🐛 Fix Button text not align center in Chrome fix: 🐛 Fix Button text not align center in Chrome Dec 3, 2019
@netlify
Copy link

netlify bot commented Dec 3, 2019

Deploy preview for ant-design ready!

Built with commit 721f97a

https://deploy-preview-20059--ant-design.netlify.com

@codesandbox-ci
Copy link

codesandbox-ci bot commented Dec 3, 2019

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 721f97a:

Sandbox Source
antd reproduction template Configuration

@codecov
Copy link

codecov bot commented Dec 3, 2019

Codecov Report

Merging #20059 into master will decrease coverage by <.01%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #20059      +/-   ##
==========================================
- Coverage   97.81%   97.81%   -0.01%     
==========================================
  Files         286      286              
  Lines        7737     7734       -3     
  Branches     2173     2173              
==========================================
- Hits         7568     7565       -3     
  Misses        169      169
Impacted Files Coverage Δ
components/table/filterDropdown.tsx 100% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 407dfda...721f97a. Read the comment docs.


> i {
vertical-align: middle;
}
Copy link
Member Author

Choose a reason for hiding this comment

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

icon 改大到 16px 之后按 baseline 对齐就会有问题。

Copy link
Contributor

Choose a reason for hiding this comment

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

没意义的 解决这些问题又会产生其他新的问题 不同浏览器的处理是有差异的

Copy link
Member Author

Choose a reason for hiding this comment

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

可以帮忙看看。

@afc163
Copy link
Member Author

afc163 commented Dec 3, 2019

效果看上去很完美。

@afc163 afc163 merged commit 43bf796 into master Dec 3, 2019
@afc163 afc163 deleted the fix-chrome-button-align branch December 3, 2019 10:06
@Satloff
Copy link
Contributor

Satloff commented Dec 16, 2019

I think this reintroduces the bug that #18139 fixed. Button text is once again uncentered, especially for larger button size:
Screen Shot 2019-12-15 at 9 59 28 PM
Screen Shot 2019-12-15 at 9 59 14 PM

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.

Button 组件中文垂直居中稍微偏下 Inconsistent vertical text position in <Button />
3 participants