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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix className prop issue when using Tooltip #16195

Merged
merged 2 commits into from Apr 26, 2019
Merged

Fix className prop issue when using Tooltip #16195

merged 2 commits into from Apr 26, 2019

Conversation

@swillis12
Copy link
Contributor

@swillis12 swillis12 commented Apr 19, 2019

馃 This is a ...

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

馃懟 What's the background?

  1. Cannot add className prop to Tooltip when using Typescript: #16194.
  2. TS error is thrown when adding this className prop.

馃挕 Solution

Tooltip Props now extend React.HTMLAttributes.

馃摑 Changelog

  • English Changelog:
  • Chinese Changelog (optional):

鈽戯笍 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
@swillis12 swillis12 changed the title Fix className prop issue when using Tooltip: https://github.com/ant-design/ant-design/issues/16194 Fix className prop issue when using Tooltip Apr 19, 2019
@netlify
Copy link

@netlify netlify bot commented Apr 19, 2019

Deploy preview for ant-design ready!

Built with commit fec88af

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

@swillis12
Copy link
Contributor Author

@swillis12 swillis12 commented Apr 19, 2019

Not sure if this is the correct fix, please advise if not.

@ztplz
Copy link
Contributor

@ztplz ztplz commented Apr 20, 2019

What confuse me is why you want to add classname to tooltip, I am not sure if it will work.

@swillis12
Copy link
Contributor Author

@swillis12 swillis12 commented Apr 20, 2019

What confuse me is why you want to add classname to tooltip, I am not sure if it will work.

It does work, it is for applying text-overflow style to the tooltip so I don't have to have an extra layer of DOM nesting.

components/tooltip/index.tsx Outdated Show resolved Hide resolved
@codecov
Copy link

@codecov codecov bot commented Apr 22, 2019

Codecov Report

Merging #16195 into master will decrease coverage by 0.05%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #16195      +/-   ##
==========================================
- Coverage   95.26%    95.2%   -0.06%     
==========================================
  Files         251      251              
  Lines        6741     6741              
  Branches     1969     1932      -37     
==========================================
- Hits         6422     6418       -4     
- Misses        318      322       +4     
  Partials        1        1
Impacted Files Coverage 螖
components/tooltip/index.tsx 96.38% <酶> (酶) 猬嗭笍
components/form/FormItem.tsx 96.51% <0%> (-2.33%) 猬囷笍

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 dbd3fbf...fec88af. Read the comment docs.

@buildsize
Copy link

@buildsize buildsize bot commented Apr 22, 2019

File name Previous Size New Size Change
package-lock.json 818.48聽KB 820.06聽KB 1.58聽KB (0%)

@zombieJ
Copy link
Member

@zombieJ zombieJ commented Apr 22, 2019

merge master

@afc163 afc163 merged commit e01ba57 into ant-design:master Apr 26, 2019
19 of 24 checks passed
19 of 24 checks passed
ant-design.ant-design #ant design failed
Details
ci/circleci: compile Your tests failed on CircleCI
Details
ci/circleci: lint Your tests failed on CircleCI
Details
@semantic-pull-requests[bot]
Semantic Pull Request add a semantic commit or PR title
Details
codebeat 0 issues resolved and 2 introduced
Details
@netlify[bot]
Header rules No header rules processed
Details
@netlify[bot]
Pages changed 211 new files uploaded
Details
Codacy/PR Quality Review Up to standards. A positive pull request.
Details
CodeFactor No issues found.
Details
LGTM analysis: JavaScript No new or fixed alerts
Details
@netlify[bot]
Mixed content No mixed content detected
Details
@netlify[bot]
Redirect rules 18 redirect rules processed
Details
@wip[bot]
WIP Ready for review
Details
@buildsize[bot]
buildsize Significant change of package-lock.json up by 1.58聽KB (0.19%)
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_node Your tests passed on CircleCI!
Details
ci/circleci: test_node_15 Your tests passed on CircleCI!
Details
@netlify[bot]
deploy/netlify Deploy preview ready!
Details
security/snyk - package.json (paranoidjk) No new issues
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants