Touchable: add support for 'style' and keyboard

This commit is contained in:
Nicolas Gallagher
2015-09-07 14:40:37 -07:00
parent 38e4de76cd
commit 77fd21ea44
5 changed files with 67 additions and 26 deletions

View File

@@ -1,5 +1,9 @@
# Touchable
A wrapper for making views respond to mouse, keyboard, and touch presses. On
press in, the touchable area can display a highlight color, and the opacity of
the wrapped view can be decreased.
## Props
**activeHighlight** string
@@ -12,9 +16,9 @@ highlight is removed when `onPressOut` is called. Default: `transparent`.
Sets the opacity of the child view when `onPressIn` is called. The opacity is
reset when `onPressOut` is called. Default: `1`.
**component** function or string
**children** element
The backing component. Default: `div`.
A single child element.
**delayLongPress** number
@@ -36,6 +40,10 @@ Delay in ms, from the release of the touch, before `onPressOut` is called. Defau
**onPressOut** function
**style** style
[View](View.md) style
## Examples
```js

View File

@@ -57,6 +57,7 @@ therefore `pointerEvents` is excluded from `style`.
+ `bottom`
+ `boxShadow`
+ `boxSizing`
+ `cursor`
+ `flexBasis`
+ `flexDirection`
+ `flexGrow`