mirror of
https://github.com/umami-software/umami.git
synced 2026-02-08 22:57:12 +01:00
Animated metric card.
This commit is contained in:
parent
f9a6f5f637
commit
da2d383b71
8 changed files with 41 additions and 13 deletions
|
|
@ -24,7 +24,11 @@ export default function WebsiteSummary({ websiteId, startDate, endDate }) {
|
|||
<div className={styles.container}>
|
||||
<MetricCard label="Views" value={pageviews} />
|
||||
<MetricCard label="Visitors" value={uniques} />
|
||||
<MetricCard label="Bounce rate" value={`${~~((bounces / uniques) * 100)}%`} />
|
||||
<MetricCard
|
||||
label="Bounce rate"
|
||||
value={uniques ? (bounces / uniques) * 100 : 0}
|
||||
format={n => Number(n).toFixed(0) + '%'}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue