Theme variable `iconFamily` is not applied correctly
See original GitHub issuehttps://github.com/GeekyAnts/NativeBase/blob/ba39355c3be5ba4600dd05bdec0aee5859a863b8/src/basic/IconNB.js#L28
In IconNB
component, setIcon()
is called in component’s constructor.
But at that time, this.context
seems to be undefined
so the value of iconFamily
is not applied except for Ionicons
and because of this, icons are not rendered correctly.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:5
Top Results From Across the Web
Next Experience theming variables - ServiceNow Community
Hello, I'm currently working on making new theme for Next Experience UI and I was looking for list of all variables(like:
Read more >Theming guide - Material Design
The application-wide theme colors that are used as the default across your entire application can be set in Sass. This is as easy...
Read more >Customize - NativeBase
You can change the variables (for color, fontFamily, iconFamily etc) for a uniform look ... This theme is not 100% material yet but,...
Read more >jQuery tablesorter 2.0 - Theme Materialize - GitHub Pages
This demo shows how to get around an issue with the filter widget: The zebra widget button below was added to show that...
Read more >Plugin: macOS theme for Joplin
No icons? If you have the 'Icon family'-setting set to 'macOS native (SF Pro)' you need to have SF Pro installed from the...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Same here. The context is not setup in the constructor
It seems that importing the context in the constructor solves the issue
Thats is to say in
IconNB
replacingconstructor(props) { super(props); this.setIcon(props.type); }
By
constructor(props,context) { super(props,context); this.setIcon(props.type); }
maybe it is linked to react version. I’m in 16.12.0 and react native 0.61.5
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.