-
Notifications
You must be signed in to change notification settings - Fork 99
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Fix icon titles #1809
Merged
Merged
Fix icon titles #1809
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Allow to use the render props pattern with the SvgIcon component. With this change it will be possible to apply the title to a children element easily.
In production setups the created svg icon in the DOM always gets a <title> element. With this change the content of this element is set to the same text as the outside <span> of <SvgIcon>. This issue got introduced with facebook/create-react-app#7118 and facebook/create-react-app#7103
The snapshot tests of the icons are mostly useless. Therefore extend the icon tests instead of relying on the snapshots.
With the latest changes the svg icon components will get a title property. In tests this results in adding a title attribute and in production it will add a title sub element.
We should always use past terms.
Removed old and not correct entry too.
Codecov Report
@@ Coverage Diff @@
## gsa-9.0 #1809 +/- ##
===========================================
+ Coverage 47.54% 47.58% +0.04%
===========================================
Files 1049 1049
Lines 24251 24273 +22
Branches 6837 6838 +1
===========================================
+ Hits 11529 11551 +22
Misses 11572 11572
Partials 1150 1150
Continue to review full report at Codecov.
|
sarahd93
requested changes
Nov 26, 2019
Co-Authored-By: sarahd93 <sarah.diedrich93@gmail.com>
sarahd93
approved these changes
Nov 26, 2019
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Finally fix the icon titles.
Checklist: