From 217a7e1a9804ab0a239abb16a54ba74dad0cece4 Mon Sep 17 00:00:00 2001 From: Website Deployment Script Date: Wed, 22 Jun 2016 12:48:55 +0000 Subject: [PATCH] Updated docs for next --- releases/next/docs/image.html | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/releases/next/docs/image.html b/releases/next/docs/image.html index 19708486bfc..dbb1924e7b9 100644 --- a/releases/next/docs/image.html +++ b/releases/next/docs/image.html @@ -14,13 +14,14 @@ images from local disk, such as the camera roll.

Example usage:

/View> ); },

Props #

onLayout function #

Invoked on mount and layout changes with -{nativeEvent: {layout: {x, y, width, height}}}.

onLoad function #

Invoked when load completes successfully

onLoadEnd function #

Invoked when load either succeeds or fails

onLoadStart function #

Invoked on load start

resizeMode enum('cover', 'contain', 'stretch') #

Determines how to resize the image when the frame doesn't match the raw +{nativeEvent: {layout: {x, y, width, height}}}.

onLoad function #

Invoked when load completes successfully

onLoadEnd function #

Invoked when load either succeeds or fails

onLoadStart function #

Invoked on load start

resizeMode enum('cover', 'contain', 'stretch', 'repeat') #

Determines how to resize the image when the frame doesn't match the raw image dimensions.

'cover': Scale the image uniformly (maintain the image's aspect ratio) so that both dimensions (width and height) of the image will be equal to or larger than the corresponding dimension of the view (minus padding).

'contain': Scale the image uniformly (maintain the image's aspect ratio) so that both dimensions (width and height) of the image will be equal to or less than the corresponding dimension of the view (minus padding).

'stretch': Scale width and height independently, This may change the -aspect ratio of the src.

source ImageSourcePropType #

The image source (either a remote URL or a local file resource).

style style #

backfaceVisibility enum('visible', 'hidden')
backgroundColor color
borderBottomLeftRadius number
borderBottomRightRadius number
borderColor color
borderRadius number
borderTopLeftRadius number
borderTopRightRadius number
borderWidth number
opacity number
overflow enum('visible', 'hidden')
resizeMode Object.keys(ImageResizeMode)
tintColor color

Changes the color of all the non-transparent pixels to the tintColor.

androidoverlayColor string

When the image has rounded corners, specifying an overlayColor will +aspect ratio of the src.

'repeat': Repeat the image to cover the frame of the view. The +image will keep it's size and aspect ratio. (iOS only)

source ImageSourcePropType #

The image source (either a remote URL or a local file resource).

style style #

backfaceVisibility enum('visible', 'hidden')
backgroundColor color
borderBottomLeftRadius number
borderBottomRightRadius number
borderColor color
borderRadius number
borderTopLeftRadius number
borderTopRightRadius number
borderWidth number
opacity number
overflow enum('visible', 'hidden')
resizeMode Object.keys(ImageResizeMode)
tintColor color

Changes the color of all the non-transparent pixels to the tintColor.

androidoverlayColor string

When the image has rounded corners, specifying an overlayColor will cause the remaining space in the corners to be filled with a solid color. This is useful in cases which are not supported by the Android implementation of rounded corners: @@ -526,6 +527,18 @@ exports.examples ={image} /> </View> + { Platform.OS === 'ios' ? + <View style={styles.leftMargin}> + <Text style={[styles.resizeModeText]}> + Repeat + </Text> + <Image + style={styles.resizeMode} + resizeMode={Image.resizeMode.repeat} + source={image} + /> + </View> + : null } { Platform.OS === 'android' ? <View style={styles.leftMargin}> <Text style={[styles.resizeModeText]}>