mirror of
https://github.com/tooot-app/app
synced 2024-12-27 01:42:32 +01:00
Fixed #14
https://github.com/jemise111/react-native-swipe-list-view/issues/473#issuecomment-663765462
This commit is contained in:
parent
b842458626
commit
1f4108c2d4
@ -17,6 +17,7 @@ import {
|
||||
View
|
||||
} from 'react-native'
|
||||
import FastImage from 'react-native-fast-image'
|
||||
import { PanGestureHandler } from 'react-native-gesture-handler'
|
||||
import { SwipeListView } from 'react-native-swipe-list-view'
|
||||
import { useDispatch, useSelector } from 'react-redux'
|
||||
import formatText from '../formatText'
|
||||
@ -153,20 +154,24 @@ const ComposeDraftsListRoot: React.FC<Props> = ({ timestamp }) => {
|
||||
|
||||
return (
|
||||
<>
|
||||
<SwipeListView
|
||||
data={localDrafts}
|
||||
renderItem={renderItem}
|
||||
renderHiddenItem={renderHiddenItem}
|
||||
disableRightSwipe={true}
|
||||
rightOpenValue={-actionWidth}
|
||||
// previewRowKey={
|
||||
// localDrafts?.length ? localDrafts[0].timestamp.toString() : undefined
|
||||
// }
|
||||
// previewDuration={350}
|
||||
// previewOpenValue={-actionWidth / 2}
|
||||
ItemSeparatorComponent={ComponentSeparator}
|
||||
keyExtractor={item => item.timestamp.toString()}
|
||||
/>
|
||||
<PanGestureHandler enabled={true}>
|
||||
<SwipeListView
|
||||
data={localDrafts}
|
||||
renderItem={renderItem}
|
||||
renderHiddenItem={renderHiddenItem}
|
||||
disableRightSwipe={true}
|
||||
rightOpenValue={-actionWidth}
|
||||
previewRowKey={
|
||||
localDrafts?.length
|
||||
? localDrafts[0].timestamp.toString()
|
||||
: undefined
|
||||
}
|
||||
// previewDuration={350}
|
||||
previewOpenValue={-actionWidth / 2}
|
||||
ItemSeparatorComponent={ComponentSeparator}
|
||||
keyExtractor={item => item.timestamp.toString()}
|
||||
/>
|
||||
</PanGestureHandler>
|
||||
<Modal
|
||||
transparent
|
||||
animationType='fade'
|
||||
|
Loading…
Reference in New Issue
Block a user