[iOS] Background Color on Text highlights empty spaces and not the actual characters only #23929
Labels
Bug
Issue: Author Provided Repro
This issue can be reproduced in Snack or an attached project.
Platform: iOS
iOS applications.
Stale
There has been a lack of activity on this issue and it may be closed soon.
🐛 Bug Report
Putting a background color on long words on iOS highlights empty spaces, if the highlighted words are multi-line and can't fit into a single line.
Attaching screenshots since it's a bit difficult to explain without pics:
iOS iPhone 7
Compare this to the behavior on Android which is expected, correct behavior:
Android
To Reproduce
Text
elementText
element with a background colorExpected Behavior
Like Android screenshot above, it should not highlight empty spaces
Code Example
https://snack.expo.io/@yunibaek/aGVsbG
Environment
My current project's env where I encountered this bug
React Native Environment Info:
System:
OS: macOS 10.14.3
CPU: (8) x64 Intel(R) Core(TM) i5-8259U CPU @ 2.30GHz
Memory: 89.25 MB / 8.00 GB
Shell: 5.3 - /bin/zsh
Binaries:
Node: 10.12.0 - ~/.nvm/versions/node/v10.12.0/bin/node
Yarn: 1.10.1 - ~/.nvm/versions/node/v10.12.0/bin/yarn
npm: 6.4.1 - ~/.nvm/versions/node/v10.12.0/bin/npm
SDKs:
iOS SDK:
Platforms: iOS 12.1, macOS 10.14, tvOS 12.1, watchOS 5.1
Android SDK:
API Levels: 28
Build Tools: 28.0.3
System Images: android-28 | Google APIs Intel x86 Atom, android-28 | Google Play Intel x86 Atom
IDEs:
Android Studio: 3.2 AI-181.5540.7.32.5056338
Xcode: 10.1/10B61 - /usr/bin/xcodebuild
npmPackages:
react: 16.5.0 => 16.5.0
react-native: https://github.com/expo/react-native/archive/sdk-32.0.0.tar.gz => 0.57.1
npmGlobalPackages:
react-native-cli: 2.0.1
The text was updated successfully, but these errors were encountered: