diff --git a/docs/activityindicatorios.html b/docs/activityindicatorios.html index fe1e02a00aa..04c0150279e 100644 --- a/docs/activityindicatorios.html +++ b/docs/activityindicatorios.html @@ -1,4 +1,4 @@ -React Native | A framework for building native apps using React

ActivityIndicatorIOS

Edit on GitHubProps #

animating bool #

Whether to show the indicator (true, the default) or hide it (false).

color string #

The foreground color of the spinner (default is gray).

size enum('small', 'large') #

Size of the indicator. Small has a height of 20, large has a height of 36.

Edit on GitHubExamples #

'use strict'; +React Native | A framework for building native apps using React

ActivityIndicatorIOS

Edit on GitHubProps #

animating bool #

Whether to show the indicator (true, the default) or hide it (false).

color string #

The foreground color of the spinner (default is gray).

hidesWhenStopped bool #

Whether the indicator should hide when not animating (true by default).

size enum('small', 'large') #

Size of the indicator. Small has a height of 20, large has a height of 36.

Edit on GitHubExamples #

'use strict'; var React = require('react-native'); var { diff --git a/docs/geolocation.html b/docs/geolocation.html index 66344ba19cc..753068975ac 100644 --- a/docs/geolocation.html +++ b/docs/geolocation.html @@ -1,7 +1,9 @@ React Native | A framework for building native apps using React

Geolocation

You need to include the NSLocationWhenInUseUsageDescription key in Info.plist to enable geolocation. Geolocation is enabled by default when you create a project with react-native init.

Geolocation follows the MDN specification: -https://developer.mozilla.org/en-US/docs/Web/API/Geolocation

Methods #

static getCurrentPosition(geo_success: Function, geo_error?: Function, geo_options?: Object) #

static watchPosition(success: Function, error?: Function, options?: Object) #

static clearWatch(watchID: number) #

static stopObserving() #

Edit on GitHubExamples #

Methods #

static getCurrentPosition(geo_success: Function, geo_error?: Function, geo_options?: GeoOptions) #

Invokes the success callback once with the latest location info. Supported +options: timeout (ms), maximumAge (ms), enableHighAccuracy (bool)

static watchPosition(success: Function, error?: Function, options?: GeoOptions) #

Invokes the success callback whenever the location changes. Supported +options: timeout (ms), maximumAge (ms), enableHighAccuracy (bool)

static clearWatch(watchID: number) #

static stopObserving() #

Edit on GitHubExamples #

/* eslint no-console: 0 */ 'use strict'; @@ -38,7 +40,8 @@ exports.examples : function() { navigator.geolocation.getCurrentPosition( (initialPosition) => this.setState({initialPosition}), - (error) => console.error(error) + (error) => console.error(error), + {enableHighAccuracy: true, timeout: 100, maximumAge: 1000} ); this.watchID = navigator.geolocation.watchPosition((lastPosition) => { this.setState({lastPosition}); diff --git a/docs/image.html b/docs/image.html index a966db20f50..67f08f73972 100644 --- a/docs/image.html +++ b/docs/image.html @@ -1,4 +1,4 @@ -React Native | A framework for building native apps using React

Image

A react component for displaying different types of images, +React Native | A framework for building native apps using React

Image

A React component for displaying different types of images, including network images, static resources, temporary local images, and images from local disk, such as the camera roll.

Example usage:

renderImages: function() { return ( diff --git a/docs/tabbarios-item.html b/docs/tabbarios-item.html index 81a6110fe5e..4a4e08eb8c9 100644 --- a/docs/tabbarios-item.html +++ b/docs/tabbarios-item.html @@ -1,7 +1,7 @@ React Native | A framework for building native apps using React

TabBarIOS.Item

Edit on GitHubProps #

badge union #

Little red bubble that sits at the top right of the icon.

icon Image.propTypes.source #

A custom icon for the tab. It is ignored when a system icon is defined.

onPress function #

Callback when this tab is being selected, you should change the state of your component to set selected={true}.

selected bool #

It specifies whether the children are visible or not. If you see a blank content, you probably forgot to add a selected one.

selectedIcon Image.propTypes.source #

A custom icon when the tab is selected. It is ignored when a system -icon is defined. If left empty, the icon will be tinted in blue.

systemIcon enum('bookmarks', 'contacts', 'downloads', 'favorites', 'featured', 'history', 'more', 'most-recent', 'most-viewed', 'recents', 'search', 'top-rated') #

Items comes with a few predefined system icons. Note that if you are +icon is defined. If left empty, the icon will be tinted in blue.

style View#style #

React style object.

systemIcon enum('bookmarks', 'contacts', 'downloads', 'favorites', 'featured', 'history', 'more', 'most-recent', 'most-viewed', 'recents', 'search', 'top-rated') #

Items comes with a few predefined system icons. Note that if you are using them, the title and selectedIcon will be overriden with the system ones.

title string #

Text that appears under the icon. It is ignored when a system icon is defined.

© 2015 Facebook Inc.

Text

A react component for displaying text which supports nesting, +React Native | A framework for building native apps using React

Text

A React component for displaying text which supports nesting, styling, and touch handling. In the following example, the nested title and body text will inherit the fontFamily from styles.baseText, but the title provides its own additional styles. The title and body will stack on top of diff --git a/docs/textinput.html b/docs/textinput.html index 60a118012e5..76661efaf67 100644 --- a/docs/textinput.html +++ b/docs/textinput.html @@ -100,9 +100,9 @@ maintaining selection information for a document

: 26, borderWidth: 0.5, borderColor: '#0f0f0f', - padding: 4, flex: 1, fontSize: 13, + padding: 4, }, multiline: { borderWidth: 0.5, @@ -110,6 +110,22 @@ maintaining selection information for a document

: 1, fontSize: 13, height: 50, + padding: 4, + marginBottom: 4, + }, + multilineWithFontStyles: { + color: 'blue', + fontWeight: 'bold', + fontSize: 18, + fontFamily: 'Cochin', + height: 60, + }, + multilineChild: { + width: 50, + height: 40, + position: 'absolute', + right: 5, + backgroundColor: 'red', }, eventLabel: { margin: 3, @@ -130,7 +146,7 @@ maintaining selection information for a document

}); exports.title = '<TextInput>'; -exports.description = 'Single-line text inputs.'; +exports.description = 'Single and multi-line text inputs.'; exports.examples = [ { title: 'Auto-focus', @@ -325,7 +341,7 @@ exports.examples }, { title: 'Clear and select', - render: function () { + render: function() { return ( <View> <WithLabel label="clearTextOnFocus"> @@ -348,6 +364,44 @@ exports.examples ); } }, + { + title: 'Multiline', + render: function() { + return ( + <View> + <TextInput + placeholder="multiline text input" + multiline={true} + style={styles.multiline} + /> + <TextInput + placeholder="mutliline text input with font styles and placeholder" + multiline={true} + clearTextOnFocus={true} + autoCorrect={true} + autoCapitalize="words" + placeholderTextColor="red" + keyboardType="url" + style={[styles.multiline, styles.multilineWithFontStyles]} + /> + <TextInput + placeholder="uneditable mutliline text input" + editable={false} + multiline={true} + style={styles.multiline} + /> + <TextInput + placeholder="multiline with children" + multiline={true} + enablesReturnKeyAutomatically={true} + returnKeyType="go" + style={styles.multiline}> + <View style={styles.multilineChild}/> + </TextInput> + </View> + ) + } + } ];
© 2015 Facebook Inc.

WebView

Edit on GitHubProps #

automaticallyAdjustContentInsets bool #

bounces bool #

contentInset {top: number, left: number, bottom: number, right: number} #

html string #

onNavigationStateChange function #

renderError function #

renderLoading function #

scrollEnabled bool #

shouldInjectAJAXHandler bool #

startInLoadingState bool #

url string #

Edit on GitHubExamples #

'use strict'; +React Native | A framework for building native apps using React

WebView

Edit on GitHubProps #

automaticallyAdjustContentInsets bool #

bounces bool #

contentInset {top: number, left: number, bottom: number, right: number} #

html string #

javaScriptEnabledAndroid bool #

Used for android only, JS is enabled by default for WebView on iOS

onNavigationStateChange function #

renderError function #

renderLoading function #

scrollEnabled bool #

shouldInjectAJAXHandler bool #

startInLoadingState bool #

url string #

Edit on GitHubExamples #

'use strict'; var React = require('react-native'); var StyleSheet = require('StyleSheet'); @@ -79,6 +79,7 @@ automaticallyAdjustContentInsets={false} style={styles.webView} url={this.state.url} + javaScriptEnabledAndroid={true} onNavigationStateChange={this.onNavigationStateChange} startInLoadingState={true} />