mirror of
https://github.com/umami-software/umami.git
synced 2026-02-19 12:05:41 +01:00
Update EventProperties.tsx
This commit is contained in:
parent
9697ac61d3
commit
c1eb76ded7
1 changed files with 10 additions and 1 deletions
|
|
@ -5,8 +5,11 @@ import PieChart from 'components/charts/PieChart';
|
|||
import { useState } from 'react';
|
||||
import { CHART_COLORS } from 'lib/constants';
|
||||
import styles from './EventProperties.module.css';
|
||||
import { useIntl } from 'react-intl';
|
||||
import { formatLongNumberOptions } from 'lib/format';
|
||||
|
||||
export function EventProperties({ websiteId }: { websiteId: string }) {
|
||||
const intl = useIntl();
|
||||
const [propertyName, setPropertyName] = useState('');
|
||||
const [eventName, setEventName] = useState('');
|
||||
const { formatMessage, labels } = useMessages();
|
||||
|
|
@ -49,7 +52,13 @@ export function EventProperties({ websiteId }: { websiteId: string }) {
|
|||
</div>
|
||||
)}
|
||||
</GridColumn>
|
||||
<GridColumn name="total" label={formatMessage(labels.count)} alignment="end" />
|
||||
<GridColumn name="total" label={formatMessage(labels.count)} alignment="end">
|
||||
{row => (
|
||||
<span title={intl.formatNumber(row.count)}>
|
||||
{intl.formatNumber(row.count, formatLongNumberOptions(row.count))}
|
||||
</span>
|
||||
)}
|
||||
</GridColumn>
|
||||
</GridTable>
|
||||
{propertyName && (
|
||||
<div className={styles.chart}>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue