diff options
author | Eric Bailey <git@esb.lol> | 2024-08-29 19:22:53 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-29 19:22:53 -0500 |
commit | 8651f31ebb7cf9c6a0949503f2c2c5755328ce46 (patch) | |
tree | 04f9c08a3770cee554a6cd421a53dc04957457fb /src/view/com/util/post-ctrls/PostCtrls.tsx | |
parent | d5a76183746bc67f88b858add49c2dba52b99bb5 (diff) | |
download | voidsky-8651f31ebb7cf9c6a0949503f2c2c5755328ce46.tar.zst |
Localize dates, counts (#5027)
* refactor: consistent localized formatting * refactor: localized date time * refactor: localize relative time with strings * chore: fix typo from copy-paste * Clean up useTimeAgo * Remove old ago * Const * Reuse * Prettier --------- Co-authored-by: Mary <git@mary.my.id>
Diffstat (limited to 'src/view/com/util/post-ctrls/PostCtrls.tsx')
-rw-r--r-- | src/view/com/util/post-ctrls/PostCtrls.tsx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/view/com/util/post-ctrls/PostCtrls.tsx b/src/view/com/util/post-ctrls/PostCtrls.tsx index a0cef8692..f577e1683 100644 --- a/src/view/com/util/post-ctrls/PostCtrls.tsx +++ b/src/view/com/util/post-ctrls/PostCtrls.tsx @@ -75,7 +75,7 @@ let PostCtrls = ({ threadgateRecord?: AppBskyFeedThreadgate.Record }): React.ReactNode => { const t = useTheme() - const {_} = useLingui() + const {_, i18n} = useLingui() const {openComposer} = useComposerControls() const {currentAccount} = useSession() const [queueLike, queueUnlike] = usePostLikeMutationQueue(post, logContext) @@ -247,7 +247,7 @@ let PostCtrls = ({ big ? a.text_md : {fontSize: 15}, a.user_select_none, ]}> - {formatCount(post.replyCount)} + {formatCount(i18n, post.replyCount)} </Text> ) : undefined} </Pressable> @@ -300,7 +300,7 @@ let PostCtrls = ({ : defaultCtrlColor, ], ]}> - {formatCount(post.likeCount)} + {formatCount(i18n, post.likeCount)} </Text> ) : undefined} </Pressable> |