Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit bc13cd2

Browse files
authored
fix: wrong date format (#1244)
1 parent 6a18b5b commit bc13cd2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/widgets/ReadableDate/AbsoluteFmt.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ type TProps = {
1717

1818
const AbsoluteFmt: FC<TProps> = ({ datetime, className, withTime }) => {
1919
const DateObj = new Date(datetime)
20-
const [month, date, year] = DateObj.toLocaleDateString().split('/')
20+
const [year, month, day] = DateObj.toLocaleDateString().split('/')
2121

2222
const hours = DateObj.getHours()
2323
const range = calcRange(hours)
@@ -31,7 +31,7 @@ const AbsoluteFmt: FC<TProps> = ({ datetime, className, withTime }) => {
3131
{month}
3232
<Space right={3} />
3333
<Space right={3} />
34-
{date}
34+
{day}
3535
<Space right={3} />
3636
{withTime && (
3737
<Fragment>

0 commit comments

Comments
 (0)