fix: make alt text selectable in Lightbox (#2563)
parent
34c1aebda6
commit
d514b13d62
|
@ -1,5 +1,5 @@
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import {Pressable, StyleSheet, View} from 'react-native'
|
import {StyleSheet, View, Pressable} from 'react-native'
|
||||||
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome'
|
||||||
import ImageView from './ImageViewing'
|
import ImageView from './ImageViewing'
|
||||||
import {shareImageModal, saveImageToMediaLibrary} from 'lib/media/manip'
|
import {shareImageModal, saveImageToMediaLibrary} from 'lib/media/manip'
|
||||||
|
@ -107,12 +107,16 @@ function LightboxFooter({imageIndex}: {imageIndex: number}) {
|
||||||
{altText ? (
|
{altText ? (
|
||||||
<Pressable
|
<Pressable
|
||||||
onPress={() => setAltExpanded(!isAltExpanded)}
|
onPress={() => setAltExpanded(!isAltExpanded)}
|
||||||
|
onLongPress={() => {}}
|
||||||
accessibilityRole="button">
|
accessibilityRole="button">
|
||||||
|
<View>
|
||||||
<Text
|
<Text
|
||||||
|
selectable
|
||||||
style={[s.gray3, styles.footerText]}
|
style={[s.gray3, styles.footerText]}
|
||||||
numberOfLines={isAltExpanded ? undefined : 3}>
|
numberOfLines={isAltExpanded ? undefined : 3}>
|
||||||
{altText}
|
{altText}
|
||||||
</Text>
|
</Text>
|
||||||
|
</View>
|
||||||
</Pressable>
|
</Pressable>
|
||||||
) : null}
|
) : null}
|
||||||
<View style={styles.footerBtns}>
|
<View style={styles.footerBtns}>
|
||||||
|
|
Loading…
Reference in New Issue