108 fixes (#8977)
* Translation comment * Fix error handling in starter pack generation * Allow access to DM settings for age restricted users * Leave post stat unit formatting up to translators
This commit is contained in:
@@ -10,7 +10,7 @@ import {Button, ButtonText} from '#/components/Button'
|
||||
import * as Dialog from '#/components/Dialog'
|
||||
import {CloseQuote_Stroke2_Corner1_Rounded as Quote} from '#/components/icons/Quote'
|
||||
import {Repost_Stroke2_Corner3_Rounded as Repost} from '#/components/icons/Repost'
|
||||
import {formatPostStatCount} from '#/components/PostControls/util'
|
||||
import {useFormatPostStatCount} from '#/components/PostControls/util'
|
||||
import {Text} from '#/components/Typography'
|
||||
import {
|
||||
PostControlButton,
|
||||
@@ -25,7 +25,6 @@ interface Props {
|
||||
onQuote: () => void
|
||||
big?: boolean
|
||||
embeddingDisabled: boolean
|
||||
compactCount?: boolean
|
||||
}
|
||||
|
||||
let RepostButton = ({
|
||||
@@ -35,12 +34,12 @@ let RepostButton = ({
|
||||
onQuote,
|
||||
big,
|
||||
embeddingDisabled,
|
||||
compactCount,
|
||||
}: Props): React.ReactNode => {
|
||||
const t = useTheme()
|
||||
const {_, i18n} = useLingui()
|
||||
const {_} = useLingui()
|
||||
const requireAuth = useRequireAuth()
|
||||
const dialogControl = Dialog.useDialogControl()
|
||||
const formatPostStatCount = useFormatPostStatCount()
|
||||
|
||||
const onPress = () => requireAuth(() => dialogControl.open())
|
||||
|
||||
@@ -88,7 +87,7 @@ let RepostButton = ({
|
||||
<PostControlButtonIcon icon={Repost} />
|
||||
{typeof repostCount !== 'undefined' && repostCount > 0 && (
|
||||
<PostControlButtonText testID="repostCount">
|
||||
{formatPostStatCount(i18n, repostCount, {compact: compactCount})}
|
||||
{formatPostStatCount(repostCount)}
|
||||
</PostControlButtonText>
|
||||
)}
|
||||
</PostControlButton>
|
||||
|
||||
Reference in New Issue
Block a user