Skip to content

Commit

Permalink
remove check for disable on offline to make consistent with online mode
Browse files Browse the repository at this point in the history
  • Loading branch information
huult committed Oct 19, 2024
1 parent 2ee73ab commit 1b0ebc6
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import PressableWithoutFocus from '@components/Pressable/PressableWithoutFocus';
import {ShowContextMenuContext, showContextMenuForReport} from '@components/ShowContextMenuContext';
import ThumbnailImage from '@components/ThumbnailImage';
import useLocalize from '@hooks/useLocalize';
import useNetwork from '@hooks/useNetwork';
import useTheme from '@hooks/useTheme';
import useThemeStyles from '@hooks/useThemeStyles';
import * as FileUtils from '@libs/fileDownload/FileUtils';
Expand Down Expand Up @@ -67,7 +66,6 @@ function ImageRenderer({tnode}: ImageRendererProps) {
const fileType = FileUtils.getFileType(attachmentSourceAttribute);
const fallbackIcon = fileType === CONST.ATTACHMENT_FILE_TYPE.FILE ? Expensicons.Document : Expensicons.GalleryNotFound;
const [hasLoadFailed, setHasLoadFailed] = useState(true);
const {isOffline} = useNetwork();
const theme = useTheme();

const thumbnailImageComponent = (
Expand Down Expand Up @@ -112,7 +110,7 @@ function ImageRenderer({tnode}: ImageRendererProps) {
shouldUseHapticsOnLongPress
accessibilityRole={CONST.ROLE.BUTTON}
accessibilityLabel={translate('accessibilityHints.viewAttachment')}
disabled={!isOffline && hasLoadFailed}
disabled={hasLoadFailed}
>
{thumbnailImageComponent}
</PressableWithoutFocus>
Expand Down

0 comments on commit 1b0ebc6

Please sign in to comment.