mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
5.6 KiB
5.6 KiB
id, title, category, permalink
| id | title | category | permalink |
|---|---|---|---|
| textstyleproptypes | TextStylePropTypes | APIs | docs/textstyleproptypes.html |
Props #
fontFamily?: string #
fontSize?: number #
fontStyle?: enum('normal', 'italic') #
fontWeight?: enum('normal', 'bold', '100', '200', '300', '400', '500', '600', '700', '800', '900') #
Specifies font weight. The values 'normal' and 'bold' are supported for most fonts. Not all fonts have a variant for each of the numeric values, in that case the closest one is chosen.
lineHeight?: number #
textAlign?: enum('auto', 'left', 'right', 'center', 'justify') #
Specifies text alignment. The value 'justify' is only supported on iOS and
fallbacks to left on Android.
textDecorationLine?: enum('none', 'underline', 'line-through', 'underline line-through') #
textShadowOffset?: {width: number, height: number} #
textShadowRadius?: number #
androidincludeFontPadding?: bool #
Set to false to remove extra font padding intended to make space for certain ascenders / descenders.
With some fonts, this padding can make text look slightly misaligned when centered vertically.
For best results also set textAlignVertical to center. Default is true.