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: Typography warning for `ref` error #19074

Merged
merged 8 commits into from Oct 1, 2019

Conversation

@zombieJ
Copy link
Member

commented Oct 1, 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

fix #19064
ref #19066

💡 Background and solution

📝 Changelog

Language Changelog
🇺🇸 English Fix Typography warning for ref error.
🇨🇳 Chinese 修复 Typography 提示获取不到 ref 的错误信息。

☑️ 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
@pr-triage pr-triage bot added the PR: unreviewed label Oct 1, 2019
Copy link

left a comment

Could you please add tests to make sure this change works as expected?

@netlify

This comment has been minimized.

Copy link

commented Oct 1, 2019

Deploy preview for ant-design ready!

Built with commit 637425c

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

@auto-add-label auto-add-label bot added the bug label Oct 1, 2019
@codecov

This comment has been minimized.

Copy link

commented Oct 1, 2019

Codecov Report

Merging #19074 into master will decrease coverage by 0.05%.
The diff coverage is 82.75%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #19074      +/-   ##
==========================================
- Coverage   97.38%   97.32%   -0.06%     
==========================================
  Files         280      281       +1     
  Lines        7527     7548      +21     
  Branches     2063     2110      +47     
==========================================
+ Hits         7330     7346      +16     
- Misses        196      201       +5     
  Partials        1        1
Impacted Files Coverage Δ
components/typography/Base.tsx 100% <ø> (ø) ⬆️
components/typography/Typography.tsx 80% <80%> (-20%) ⬇️
components/_util/ref.ts 88.88% <88.88%> (ø)

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 3d378f2...637425c. Read the comment docs.


let RefTypography;

if (React.forwardRef) {

This comment has been minimized.

Copy link
@shaodahong

shaodahong Oct 1, 2019

Collaborator

一开始我是考虑 forwardRef 有兼容性问题,所以没有这样修,4.0 都不需要这样写,感觉需要个 to-do

This comment has been minimized.

Copy link
@zombieJ

zombieJ Oct 1, 2019

Author Member

嗯,这些 4.0 发布后再清理就行了。否则每周 4.0 merge master 都一堆冲突。

zombieJ added 4 commits Oct 1, 2019
@zombieJ

This comment has been minimized.

Copy link
Member Author

commented Oct 1, 2019

新版 eslint-plugin-react 有 bug:yannickcr/eslint-plugin-react#2423
本地降低测试通过,可以合并。

@zombieJ zombieJ merged commit 4680ddc into master Oct 1, 2019
23 of 27 checks passed
23 of 27 checks passed
build
Details
ci/circleci: lint Your tests failed on CircleCI
Details
Header rules - ant-design No header rules processed
Details
Pages changed - ant-design 217 new files uploaded
Details
LGTM analysis: JavaScript No new or fixed alerts
Details
License Compliance All checks passed.
Details
Mixed content - ant-design No mixed content detected
Details
Redirect rules - ant-design 18 redirect rules processed
Details
Semantic Pull Request ready to be squashed
Details
WIP Ready for review
Details
bundlesize Total bundle size is 586.58KB/600KB (-null)
Details
ci/circleci: check_metadata Your tests passed on CircleCI!
Details
ci/circleci: compile Your tests passed on CircleCI!
Details
ci/circleci: dist Your tests passed on CircleCI!
Details
ci/circleci: setup Your tests passed on CircleCI!
Details
ci/circleci: test_dist Your tests passed on CircleCI!
Details
ci/circleci: test_dist_15 Your tests passed on CircleCI!
Details
ci/circleci: test_dom Your tests passed on CircleCI!
Details
ci/circleci: test_dom_15 Your tests passed on CircleCI!
Details
ci/circleci: test_es Your tests passed on CircleCI!
Details
ci/circleci: test_es_15 Your tests passed on CircleCI!
Details
ci/circleci: test_lib Your tests passed on CircleCI!
Details
ci/circleci: test_lib_15 Your tests passed on CircleCI!
Details
ci/circleci: test_node Your tests passed on CircleCI!
Details
ci/circleci: test_node_15 Your tests passed on CircleCI!
Details
netlify/ant-design/deploy-preview Deploy preview ready!
Details
security/snyk - package.json (paranoidjk) No manifest changes detected
@zombieJ zombieJ deleted the typography-fix branch Oct 1, 2019
@pr-triage pr-triage bot added PR: merged and removed PR: unreviewed labels Oct 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.