Using `StyleSheet.hairlineWidth` in TextInputExample

Summary:
This is workaround for blury and thick borders on iOS when specified border size does not multiplier of pixel size.
Original problem is probably related to CALayer border drawing specifics; documented as T22099662 and
https://github.com/facebook/react-native/issues/14106

Before:
https://pxl.cl/9cJ7

After:
https://pxl.cl/9cJ4

Reviewed By: javache

Differential Revision: D5999752

fbshipit-source-id: ad6d1078c6ebf7c8e0a3bc3c150525480a5a7a5c
This commit is contained in:
Valentin Shergin 2017-10-09 09:28:59 -07:00 committed by Facebook Github Bot
parent bf3698323d
commit 9e220da397
1 changed files with 2 additions and 2 deletions

View File

@ -340,14 +340,14 @@ var styles = StyleSheet.create({
paddingBottom: 300,
},
default: {
borderWidth: 0.5,
borderWidth: StyleSheet.hairlineWidth,
borderColor: '#0f0f0f',
flex: 1,
fontSize: 13,
padding: 4,
},
multiline: {
borderWidth: 0.5,
borderWidth: StyleSheet.hairlineWidth,
borderColor: '#0f0f0f',
flex: 1,
fontSize: 13,