1
0
mirror of https://github.com/tooot-app/app synced 2025-06-05 22:19:13 +02:00

Better lookback update

This commit is contained in:
Zhiyuan Zheng
2022-01-30 22:51:03 +01:00
parent 45ba984ea3
commit bd49caa52a
13 changed files with 116 additions and 106 deletions

View File

@@ -8,7 +8,6 @@ import {
RootStackScreenProps
} from '@utils/navigation/navigators'
import { useTheme } from '@utils/styles/ThemeManager'
import { findIndex } from 'lodash'
import React, { RefObject, useCallback, useRef, useState } from 'react'
import { useTranslation } from 'react-i18next'
import { Platform, Share, StatusBar, View } from 'react-native'
@@ -120,7 +119,7 @@ const ScreenImagesViewer = ({
const { mode } = useTheme()
const initialIndex = findIndex(imageUrls, ['id', id])
const initialIndex = imageUrls.findIndex(image => image.id === id)
const [currentIndex, setCurrentIndex] = useState(initialIndex)
const messageRef = useRef<FlashMessage>(null)