Make ALT labels translatable (#9976)
This commit is contained in:
@@ -9,6 +9,7 @@ import {type AppBskyEmbedImages} from '@atproto/api'
|
|||||||
import {utils} from '@bsky.app/alf'
|
import {utils} from '@bsky.app/alf'
|
||||||
import {msg} from '@lingui/core/macro'
|
import {msg} from '@lingui/core/macro'
|
||||||
import {useLingui} from '@lingui/react'
|
import {useLingui} from '@lingui/react'
|
||||||
|
import {Trans} from '@lingui/react/macro'
|
||||||
|
|
||||||
import {type Dimensions} from '#/lib/media/types'
|
import {type Dimensions} from '#/lib/media/types'
|
||||||
import {useLargeAltBadgeEnabled} from '#/state/preferences/large-alt-badge'
|
import {useLargeAltBadgeEnabled} from '#/state/preferences/large-alt-badge'
|
||||||
@@ -186,7 +187,7 @@ export function AutoSizedImage({
|
|||||||
],
|
],
|
||||||
]}>
|
]}>
|
||||||
<Text style={[a.font_bold, largeAlt ? a.text_xs : {fontSize: 8}]}>
|
<Text style={[a.font_bold, largeAlt ? a.text_xs : {fontSize: 8}]}>
|
||||||
ALT
|
<Trans>ALT</Trans>
|
||||||
</Text>
|
</Text>
|
||||||
</View>
|
</View>
|
||||||
)}
|
)}
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import {type AppBskyEmbedImages} from '@atproto/api'
|
|||||||
import {utils} from '@bsky.app/alf'
|
import {utils} from '@bsky.app/alf'
|
||||||
import {msg} from '@lingui/core/macro'
|
import {msg} from '@lingui/core/macro'
|
||||||
import {useLingui} from '@lingui/react'
|
import {useLingui} from '@lingui/react'
|
||||||
|
import {Trans} from '@lingui/react/macro'
|
||||||
|
|
||||||
import {type Dimensions} from '#/lib/media/types'
|
import {type Dimensions} from '#/lib/media/types'
|
||||||
import {useLargeAltBadgeEnabled} from '#/state/preferences/large-alt-badge'
|
import {useLargeAltBadgeEnabled} from '#/state/preferences/large-alt-badge'
|
||||||
@@ -116,7 +117,7 @@ export function GalleryItem({
|
|||||||
]}>
|
]}>
|
||||||
<Text
|
<Text
|
||||||
style={[a.font_bold, largeAltBadge ? a.text_xs : {fontSize: 8}]}>
|
style={[a.font_bold, largeAltBadge ? a.text_xs : {fontSize: 8}]}>
|
||||||
ALT
|
<Trans>ALT</Trans>
|
||||||
</Text>
|
</Text>
|
||||||
</View>
|
</View>
|
||||||
) : null}
|
) : null}
|
||||||
|
|||||||
Reference in New Issue
Block a user