c5b6f88e9a
* get basic hindi support to work * get web app language switcher in * Refactor i18n implementation and remove unused code * add missing strings * add dropdowns and modals missing strings * complete all hindi translations * fix merge conflicts * fix legeacy persisted state * fix data in RecommendedFeeds * fix lint
33 lines
1.1 KiB
TypeScript
33 lines
1.1 KiB
TypeScript
import React from 'react'
|
|
import {View} from 'react-native'
|
|
import {useFocusEffect} from '@react-navigation/native'
|
|
import {withAuthRequired} from 'view/com/auth/withAuthRequired'
|
|
import {NativeStackScreenProps, CommonNavigatorParams} from 'lib/routes/types'
|
|
import {ViewHeader} from '../com/util/ViewHeader'
|
|
import {PostRepostedBy as PostRepostedByComponent} from '../com/post-thread/PostRepostedBy'
|
|
import {makeRecordUri} from 'lib/strings/url-helpers'
|
|
import {useSetMinimalShellMode} from '#/state/shell'
|
|
import {useLingui} from '@lingui/react'
|
|
import {msg} from '@lingui/macro'
|
|
|
|
type Props = NativeStackScreenProps<CommonNavigatorParams, 'PostRepostedBy'>
|
|
export const PostRepostedByScreen = withAuthRequired(({route}: Props) => {
|
|
const {name, rkey} = route.params
|
|
const uri = makeRecordUri(name, 'app.bsky.feed.post', rkey)
|
|
const setMinimalShellMode = useSetMinimalShellMode()
|
|
const {_} = useLingui()
|
|
|
|
useFocusEffect(
|
|
React.useCallback(() => {
|
|
setMinimalShellMode(false)
|
|
}, [setMinimalShellMode]),
|
|
)
|
|
|
|
return (
|
|
<View>
|
|
<ViewHeader title={_(msg`Reposted by`)} />
|
|
<PostRepostedByComponent uri={uri} />
|
|
</View>
|
|
)
|
|
})
|