From 2a8aa2d8e87ed975b1a91d1c53320e1ca7bceecf Mon Sep 17 00:00:00 2001
From: Website Deployment Script
Date: Fri, 7 Apr 2017 05:18:19 +0000
Subject: [PATCH] Updated docs for next
---
releases/next/docs/text.html | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/releases/next/docs/text.html b/releases/next/docs/text.html
index a28b9a56a3f..836d3f6fdf3 100644
--- a/releases/next/docs/text.html
+++ b/releases/next/docs/text.html
@@ -56,7 +56,7 @@ 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.
androidtextAlignVertical enum('auto', 'top', 'bottom', 'center')
iosfontVariant [enum('small-caps', 'oldstyle-nums', 'lining-nums', 'tabular-nums', 'proportional-nums')]
iosletterSpacing number
iostextDecorationColor color
iostextDecorationStyle enum('solid', 'double', 'dotted', 'dashed')
ioswritingDirection enum('auto', 'ltr', 'rtl')
testID?: string #
Used to locate this view in end-to-end tests.
androidselectionColor?: color #
The highlight color of the text.
androidtextBreakStrategy?: enum('simple', 'highQuality', 'balanced') #
Set text break strategy on Android API Level 23+, possible values are simple, highQuality, balanced
+For best results also set textAlignVertical to center. Default is true.
androidtextAlignVertical enum('auto', 'top', 'bottom', 'center')
iosfontVariant [enum('small-caps', 'oldstyle-nums', 'lining-nums', 'tabular-nums', 'proportional-nums')]
iosletterSpacing number
iostextDecorationColor color
iostextDecorationStyle enum('solid', 'double', 'dotted', 'dashed')
ioswritingDirection enum('auto', 'ltr', 'rtl')
testID?: string #
Used to locate this view in end-to-end tests.
androiddisabled?: bool #
Specifies the disabled state of the text view for testing purposes
androidselectionColor?: color #
The highlight color of the text.
androidtextBreakStrategy?: enum('simple', 'highQuality', 'balanced') #
Set text break strategy on Android API Level 23+, possible values are simple, highQuality, balanced
The default value is highQuality.
iosadjustsFontSizeToFit?: bool #
Specifies whether font should be scaled down automatically to fit given style constraints.
iosminimumFontScale?: number #
Specifies smallest possible scale a font can reach when adjustsFontSizeToFit is enabled. (values 0.01-1.0).
iossuppressHighlighting?: bool #
When true, no visual change is made when text is pressed down. By
default, a gray oval highlights the text on press down.
You can edit the content above on GitHub and send us a pull request!
Description #
Nested Text #
Both iOS and Android allow you to display formatted text by annotating ranges of a string with specific formatting like bold or colored text (NSAttributedString on iOS, SpannableString on Android). In practice, this is very tedious. For React Native, we decided to use web paradigm for this where you can nest text to achieve the same effect.
import React, { Component } from 'react';
import { AppRegistry, Text } from 'react-native';