mirror of
https://github.com/umami-software/umami.git
synced 2026-02-04 04:37:11 +01:00
commit
6a6b9df36a
3 changed files with 4 additions and 4 deletions
|
|
@ -39,7 +39,7 @@ export function SessionActivity({
|
|||
<div key={eventId} className={styles.row}>
|
||||
<div className={styles.time}>
|
||||
<StatusLight color={`#${visitId?.substring(0, 6)}`}>
|
||||
{formatTimezoneDate(createdAt, 'h:mm:ss aaa')}
|
||||
{formatTimezoneDate(createdAt, 'pp')}
|
||||
</StatusLight>
|
||||
</div>
|
||||
<Icon>{eventName ? <Icons.Bolt /> : <Icons.Eye />}</Icon>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ const formats = {
|
|||
millisecond: 'T',
|
||||
second: 'pp',
|
||||
minute: 'p',
|
||||
hour: 'h:mm aaa - PP',
|
||||
hour: 'p - PP',
|
||||
day: 'PPPP',
|
||||
week: 'PPPP',
|
||||
month: 'LLLL yyyy',
|
||||
|
|
|
|||
|
|
@ -11,11 +11,11 @@ export function renderDateLabels(unit: string, locale: string) {
|
|||
|
||||
switch (unit) {
|
||||
case 'minute':
|
||||
return formatDate(d, 'h:mm', locale);
|
||||
return formatDate(d, 'p', locale).split(' ')[0];
|
||||
case 'hour':
|
||||
return formatDate(d, 'p', locale);
|
||||
case 'day':
|
||||
return formatDate(d, 'MMM d', locale);
|
||||
return formatDate(d, 'PP', locale).replace(/\W*20\d{2}\W*/, ''); // Remove year
|
||||
case 'month':
|
||||
return formatDate(d, 'MMM', locale);
|
||||
case 'year':
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue