diff --git a/README.md b/README.md index 973bf132..7a226340 100644 --- a/README.md +++ b/README.md @@ -142,10 +142,6 @@ and child content. (TODO) -### [`Swipeable`](docs/components/Swipeable.md) - -Touch bindings for swipe gestures. - ### [`Text`](docs/components/Text.md) Displays text as an inline block and supports basic press handling. @@ -183,10 +179,8 @@ welcome! Thanks to current and past members of the React and React Native teams (in particular Vjeux and Pete Hunt), and Tobias Koppers for Webpack and CSS loader. -Thanks to [react-swipeable](https://github.com/dogfessional/react-swipeable/) -for the current implementation of `Swipeable`, and to -[react-tappable](https://github.com/JedWatson/react-tappable) for backing the -current implementation of `Touchable`. +Thanks to [react-tappable](https://github.com/JedWatson/react-tappable) for +backing the current implementation of `Touchable`. ## License diff --git a/docs/components/Swipeable.md b/docs/components/Swipeable.md deleted file mode 100644 index d4aef553..00000000 --- a/docs/components/Swipeable.md +++ /dev/null @@ -1,95 +0,0 @@ -# Swipeable - -Unique to web. - -## Props - -**delta**: number = 10 - -Number of pixels that must be swiped before events are dispatched. - -**flickThreshold**: number = 0.6 - -The velocity threshold at which a swipe is considered a flick. - -**onSwiped**: function - -(SyntheticTouchEvent, deltaX, deltaY, isFlick) => swipeHandler - -Called once a swipe has ended. - -**onSwipedDown**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called once a swipe-down has ended. - -**onSwipedLeft**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called once a swipe-left has ended. - -**onSwipedUp**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called once a swipe-up has ended. - -**onSwipedRight**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called once a swipe-right has ended. - -**onSwipingDown**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called while a swipe-down is in progress. - -**onSwipingLeft**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called while a swipe-left is in progress. - -**onSwipingRight**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called while a swipe-right is in progress. - -**onSwipingUp**: function - -(SyntheticTouchEvent, delta, isFlick) => swipeHandler - -Called while a swipe-up is in progress. - -## Examples - -```js -import React, { Swipeable } from 'react-native-web' - -const { Component, PropTypes } = React; - -class Example extends Component { - static propTypes = { - } - - static defaultProps = { - } - - _onSwiped(event, x, y, isFlick) { - - } - - render() { - return ( - - ) - } -} -``` diff --git a/package.json b/package.json index e91f700a..90d4ec45 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,6 @@ "dependencies": { "inline-style-prefixer": "^0.3.3", "react": ">=0.13.3", - "react-swipeable": "^3.0.2", "react-tappable": "^0.6.0", "react-textarea-autosize": "^2.5.3" }, diff --git a/src/components/Swipeable/index.js b/src/components/Swipeable/index.js deleted file mode 100644 index 48d0725b..00000000 --- a/src/components/Swipeable/index.js +++ /dev/null @@ -1,2 +0,0 @@ -import Swipeable from 'react-swipeable' -export default Swipeable diff --git a/src/example.js b/src/example.js index 7b79a11d..7710c3b8 100644 --- a/src/example.js +++ b/src/example.js @@ -1,4 +1,4 @@ -import React, { Image, StyleSheet, Swipeable, Text, TextInput, Touchable, View } from '.' +import React, { Image, StyleSheet, Text, TextInput, Touchable, View } from '.' const { Component, PropTypes } = React @@ -58,7 +58,7 @@ class Example extends Component { React Native Web takes the core components from React Native and brings them to the web. These components provide - simple building blocks – touch and swipe handling, flexbox layout, + simple building blocks – touch handling, flexbox layout, scroll views – from which more complex components and apps can be constructed. @@ -85,21 +85,6 @@ class Example extends Component { testID='Example.image' /> - Swipeable - { console.log('Swipeable.onSwiped', e) }} - testID={'Example.swipeable'} - > - - - Text { console.log('Text.onPress', e) }} diff --git a/src/index.js b/src/index.js index 0354b50b..344e9d42 100644 --- a/src/index.js +++ b/src/index.js @@ -6,7 +6,6 @@ import StyleSheet from './modules/StyleSheet' import Image from './components/Image' import ListView from './components/ListView' import ScrollView from './components/ScrollView' -import Swipeable from './components/Swipeable' import Text from './components/Text' import TextInput from './components/TextInput' import Touchable from './components/Touchable' @@ -21,7 +20,6 @@ export { Image, ListView, ScrollView, - Swipeable, Text, TextInput, Touchable,