Commit 40f8f7c6 authored by tom's avatar tom

delete short locale

parent c33bf627
...@@ -36,37 +36,16 @@ dayjs.updateLocale('en', { ...@@ -36,37 +36,16 @@ dayjs.updateLocale('en', {
ss: '%d secs', ss: '%d secs',
future: 'in %s', future: 'in %s',
past: '%s ago', past: '%s ago',
m: 'a min', m: '1 min',
mm: '%d mins', mm: '%d mins',
h: 'an hour', h: '1 h',
hh: '%d hours', hh: '%d h',
d: 'a day', d: '1 d',
dd: '%d days', dd: '%d d',
M: 'a month', M: '1 mo',
MM: '%d months', MM: '%d mo',
y: 'a year', y: '1 y',
yy: '%d years', yy: '%d y',
},
});
dayjs.locale('en-short', {
name: 'en-short',
relativeTime: {
s: '1s',
future: 'in %s',
past: '%s ago',
m: '1m',
mm: '%dm',
h: '1h',
hh: '%dh',
d: '1d',
dd: '%dd',
M: '1mo',
MM: '%dmo',
y: '1y',
yy: '%dy',
// have to trick typescript 🎩 🐇
...{ ss: '%ds' },
}, },
}); });
......
...@@ -35,7 +35,7 @@ const BlocksListItem = ({ data, isPending }: Props) => { ...@@ -35,7 +35,7 @@ const BlocksListItem = ({ data, isPending }: Props) => {
{ data.height } { data.height }
</Link> </Link>
</Flex> </Flex>
<Text variant="secondary"fontWeight={ 400 }>{ dayjs(data.timestamp).locale('en-short').fromNow() }</Text> <Text variant="secondary"fontWeight={ 400 }>{ dayjs(data.timestamp).fromNow() }</Text>
</Flex> </Flex>
<Flex columnGap={ 2 }> <Flex columnGap={ 2 }>
<Text fontWeight={ 500 }>Size</Text> <Text fontWeight={ 500 }>Size</Text>
......
...@@ -33,7 +33,7 @@ const BlocksTableItem = ({ data, isPending }: Props) => { ...@@ -33,7 +33,7 @@ const BlocksTableItem = ({ data, isPending }: Props) => {
{ data.height } { data.height }
</Link> </Link>
</Flex> </Flex>
<Text variant="secondary" mt={ 2 } fontWeight={ 400 }>{ dayjs(data.timestamp).locale('en-short').fromNow() }</Text> <Text variant="secondary" mt={ 2 } fontWeight={ 400 }>{ dayjs(data.timestamp).fromNow() }</Text>
</Td> </Td>
<Td fontSize="sm">{ data.size.toLocaleString('en') } bytes</Td> <Td fontSize="sm">{ data.size.toLocaleString('en') } bytes</Td>
<Td fontSize="sm"> <Td fontSize="sm">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment