dedupe date parsing (#6267)

This commit is contained in:
Samuel Newman
2024-11-12 18:50:37 +00:00
committed by GitHub
parent df3f71286d
commit dd8d14e133
+4 -2
View File
@@ -49,6 +49,8 @@ let PostMeta = (opts: PostMetaOpts): React.ReactNode => {
precacheProfile(queryClient, opts.author) precacheProfile(queryClient, opts.author)
}, [queryClient, opts.author]) }, [queryClient, opts.author])
const timestampLabel = niceDate(i18n, opts.timestamp)
return ( return (
<View <View
style={[ style={[
@@ -115,8 +117,8 @@ let PostMeta = (opts: PostMetaOpts): React.ReactNode => {
{({timeElapsed}) => ( {({timeElapsed}) => (
<WebOnlyInlineLinkText <WebOnlyInlineLinkText
to={opts.postHref} to={opts.postHref}
label={niceDate(i18n, opts.timestamp)} label={timestampLabel}
title={niceDate(i18n, opts.timestamp)} title={timestampLabel}
disableMismatchWarning disableMismatchWarning
disableUnderline disableUnderline
onPress={onBeforePressPost} onPress={onBeforePressPost}