mirror of
https://github.com/cheeaun/phanpy.git
synced 2024-11-21 08:45:32 +03:00
Show relative time on large post too
This commit is contained in:
parent
058cf05805
commit
f10d5457ae
1 changed files with 13 additions and 0 deletions
|
@ -2267,6 +2267,19 @@ function Status({
|
|||
/> */}
|
||||
<span>{_(visibilityText[visibility])}</span> •{' '}
|
||||
<a href={url} target="_blank" rel="noopener noreferrer">
|
||||
{
|
||||
// within a day
|
||||
new Date().getTime() - createdAtDate.getTime() <
|
||||
86400000 && (
|
||||
<>
|
||||
<RelativeTime
|
||||
datetime={createdAtDate}
|
||||
format="micro"
|
||||
/>{' '}
|
||||
‒{' '}
|
||||
</>
|
||||
)
|
||||
}
|
||||
<time
|
||||
class="created"
|
||||
datetime={createdAtDate.toISOString()}
|
||||
|
|
Loading…
Reference in a new issue