make gif alt text prompt selectable (#3879)
parent
fdb5ffff53
commit
136b0e12ab
|
@ -62,12 +62,16 @@ export function TitleText({children}: React.PropsWithChildren<{}>) {
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
export function DescriptionText({children}: React.PropsWithChildren<{}>) {
|
export function DescriptionText({
|
||||||
|
children,
|
||||||
|
selectable,
|
||||||
|
}: React.PropsWithChildren<{selectable?: boolean}>) {
|
||||||
const t = useTheme()
|
const t = useTheme()
|
||||||
const {descriptionId} = React.useContext(Context)
|
const {descriptionId} = React.useContext(Context)
|
||||||
return (
|
return (
|
||||||
<Text
|
<Text
|
||||||
nativeID={descriptionId}
|
nativeID={descriptionId}
|
||||||
|
selectable={selectable}
|
||||||
style={[a.text_md, a.leading_snug, t.atoms.text_contrast_high, a.pb_lg]}>
|
style={[a.text_md, a.leading_snug, t.atoms.text_contrast_high, a.pb_lg]}>
|
||||||
{children}
|
{children}
|
||||||
</Text>
|
</Text>
|
||||||
|
|
|
@ -174,7 +174,7 @@ function AltText({text}: {text: string}) {
|
||||||
<Prompt.TitleText>
|
<Prompt.TitleText>
|
||||||
<Trans>Alt Text</Trans>
|
<Trans>Alt Text</Trans>
|
||||||
</Prompt.TitleText>
|
</Prompt.TitleText>
|
||||||
<Prompt.DescriptionText>{text}</Prompt.DescriptionText>
|
<Prompt.DescriptionText selectable>{text}</Prompt.DescriptionText>
|
||||||
<Prompt.Actions>
|
<Prompt.Actions>
|
||||||
<Prompt.Action
|
<Prompt.Action
|
||||||
onPress={control.close}
|
onPress={control.close}
|
||||||
|
|
Loading…
Reference in New Issue