diff --git a/app/components/files/file.tsx b/app/components/files/file.tsx index bcd128795..72cf6af2f 100644 --- a/app/components/files/file.tsx +++ b/app/components/files/file.tsx @@ -25,7 +25,7 @@ type FileProps = { galleryIdentifier: string; index: number; inViewPort: boolean; - isSingleImage: boolean; + isSingleImage?: boolean; nonVisibleImagesCount: number; onPress: (index: number) => void; publicLinkEnabled: boolean; diff --git a/app/screens/home/search/results/file_result.tsx b/app/screens/home/search/results/file_result.tsx index 9125c504d..119612f8c 100644 --- a/app/screens/home/search/results/file_result.tsx +++ b/app/screens/home/search/results/file_result.tsx @@ -25,7 +25,6 @@ type Props = { channelName: string | undefined; fileInfo: FileInfo; index: number; - isSingleImage: boolean; numOptions: number; onOptionsPress: (finfo: FileInfo) => void; onPress: (idx: number) => void; @@ -41,7 +40,6 @@ const FileResult = ({ channelName, fileInfo, index, - isSingleImage, numOptions, onOptionsPress, onPress, @@ -94,7 +92,6 @@ const FileResult = ({ galleryIdentifier={galleryIdentifier} inViewPort={true} index={index} - isSingleImage={isSingleImage} nonVisibleImagesCount={0} onOptionsPress={handleOptionsPress} onPress={onPress} diff --git a/app/screens/home/search/results/file_results.tsx b/app/screens/home/search/results/file_results.tsx index 5e22bf3d2..ada3f5f98 100644 --- a/app/screens/home/search/results/file_results.tsx +++ b/app/screens/home/search/results/file_results.tsx @@ -10,7 +10,6 @@ import {useImageAttachments} from '@app/hooks/files'; import NoResultsWithTerm from '@components/no_results_with_term'; import {useTheme} from '@context/theme'; import {GalleryAction} from '@typings/screens/gallery'; -import {isImage, isVideo} from '@utils/file'; import { getChannelNamesWithID, getFileInfosIndexes, @@ -89,14 +88,12 @@ const FileResults = ({ }, [insets, isTablet, numOptions, theme]); const renderItem = useCallback(({item}: ListRenderItemInfo) => { - const isSingleImage = orderedFileInfos.length === 1 && (isImage(orderedFileInfos[0]) || isVideo(orderedFileInfos[0])); return (