[ios][issue] tintColor on image component does not work on ios
See original GitHub issueIs this a bug report?
Yes
Have you read the Contributing Guidelines?
Yes
Environment
OS: macOS Sierra 10.12.6 Node: 7.4.0 Yarn: Not Found npm: 5.5.1 Watchman: Not Found Xcode: N/A Android Studio: Not Found
Packages: (wanted => installed) react: ^16.0.0 => 16.0.0 react-native: ^0.51.0 => 0.51.0
Steps to Reproduce
1.Create a page with an image component in it. 2.Add a tintColor prop to the image component with any color valid color value in it 3.View the image on your screen
Expected Behavior
I though the rendered image would change to the tintColor set on the image component.
Actual Behavior
The image renders but the color has not been changed. On android the color is changed as expected just not on ios.
Reproducible Demo
Issue Analytics
- State:
- Created 6 years ago
- Comments:7
Top Results From Across the Web
React Native: "tintColor" not working for Image on iOS 15
This is working fine on Android and on iOS <15. However, the tintColor is not applied to any of my icons on iOS...
Read more >iOS13 UIButton tint misbehaving | Apple Developer Forums
In my app, I have several System UIButtons with an image (Template Image) and tint colour. I am dynamically setting the buttons tint...
Read more >Tutorial: Image processing on iOS - Visual Servoing Platform
In this tutorial you will learn how to do simple image processing on iOS devices with ViSP. This application loads a color image...
Read more >425935 - Wrong color profile with 2D canvas - chromium
The same sRGB color used in canvas and in CSS will look identical today. However, there still is a problem. This means that...
Read more >[Solved]-one touch fill color in image without border
you need to know the border RGB value. So you have to check whether the touch location color is from the border's RGB...
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 FreeTop 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
Top GitHub Comments
In the docs tintColor is listed under
style
. This works on both platforms. Actually you might should call it a bug that your code is working on android.Just change your code to
Edit:
Actually on Android style attributes are passed as props to the native image component. Which might lead to similar issues but I do not know if this is necessary for some reason.
https://github.com/facebook/react-native/blob/e76abfa036ff7ba2b9b309737cbc3d5a0ae9394b/Libraries/Image/Image.android.js#L293-L299
Still an issue.