mirror of
https://github.com/umami-software/umami.git
synced 2026-02-13 17:15:37 +01:00
Added search to metrics table.
This commit is contained in:
parent
3a28fea8ac
commit
cad719fd23
12 changed files with 111 additions and 60 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import MetricsTable from './MetricsTable';
|
||||
import MetricsTable, { MetricsTableProps } from './MetricsTable';
|
||||
import FilterLink from 'components/common/FilterLink';
|
||||
import useMessages from 'components/hooks/useMessages';
|
||||
|
||||
|
|
@ -8,7 +8,7 @@ const names = {
|
|||
'Sun OS': 'SunOS',
|
||||
};
|
||||
|
||||
export function OSTable({ websiteId, limit }: { websiteId: string; limit?: number }) {
|
||||
export function OSTable(props: MetricsTableProps) {
|
||||
const { formatMessage, labels } = useMessages();
|
||||
|
||||
function renderLink({ x: os }) {
|
||||
|
|
@ -28,12 +28,11 @@ export function OSTable({ websiteId, limit }: { websiteId: string; limit?: numbe
|
|||
|
||||
return (
|
||||
<MetricsTable
|
||||
websiteId={websiteId}
|
||||
limit={limit}
|
||||
{...props}
|
||||
type="os"
|
||||
title={formatMessage(labels.os)}
|
||||
metric={formatMessage(labels.visitors)}
|
||||
renderLabel={renderLink}
|
||||
type="os"
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue