mirror of
https://github.com/kremalicious/umami.git
synced 2024-12-18 15:23:38 +01:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
f0edb2b0fe
@ -2,6 +2,7 @@ import React from 'react';
|
|||||||
import { FormattedMessage } from 'react-intl';
|
import { FormattedMessage } from 'react-intl';
|
||||||
import PageHeader from '../layout/PageHeader';
|
import PageHeader from '../layout/PageHeader';
|
||||||
import DropDown from '../common/DropDown';
|
import DropDown from '../common/DropDown';
|
||||||
|
import ActiveUsers from './ActiveUsers';
|
||||||
import MetricCard from './MetricCard';
|
import MetricCard from './MetricCard';
|
||||||
import styles from './RealtimeHeader.module.css';
|
import styles from './RealtimeHeader.module.css';
|
||||||
|
|
||||||
@ -24,6 +25,9 @@ export default function RealtimeHeader({ websites, data, websiteId, onSelect })
|
|||||||
<div>
|
<div>
|
||||||
<FormattedMessage id="label.realtime" defaultMessage="Realtime" />
|
<FormattedMessage id="label.realtime" defaultMessage="Realtime" />
|
||||||
</div>
|
</div>
|
||||||
|
<div>
|
||||||
|
<ActiveUsers className={styles.active} websiteId={websiteId} />
|
||||||
|
</div>
|
||||||
<DropDown value={websiteId} options={options} onChange={onSelect} />
|
<DropDown value={websiteId} options={options} onChange={onSelect} />
|
||||||
</PageHeader>
|
</PageHeader>
|
||||||
<div className={styles.metrics}>
|
<div className={styles.metrics}>
|
||||||
|
@ -7,7 +7,7 @@ import Tag from 'components/common/Tag';
|
|||||||
import Dot from 'components/common/Dot';
|
import Dot from 'components/common/Dot';
|
||||||
import FilterButtons from 'components/common/FilterButtons';
|
import FilterButtons from 'components/common/FilterButtons';
|
||||||
import NoData from 'components/common/NoData';
|
import NoData from 'components/common/NoData';
|
||||||
import { devices } from 'components/messages';
|
import { devices, getDeviceMessage } from 'components/messages';
|
||||||
import useLocale from 'hooks/useLocale';
|
import useLocale from 'hooks/useLocale';
|
||||||
import useCountryNames from 'hooks/useCountryNames';
|
import useCountryNames from 'hooks/useCountryNames';
|
||||||
import { BROWSERS } from 'lib/constants';
|
import { BROWSERS } from 'lib/constants';
|
||||||
@ -137,7 +137,7 @@ export default function RealtimeLog({ data, websites, websiteId }) {
|
|||||||
),
|
),
|
||||||
browser: <b>{BROWSERS[browser]}</b>,
|
browser: <b>{BROWSERS[browser]}</b>,
|
||||||
os: <b>{os}</b>,
|
os: <b>{os}</b>,
|
||||||
device: <b>{intl.formatMessage(devices[device])?.toLowerCase()}</b>,
|
device: <b>{getDeviceMessage(devices[device])}</b>,
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
@ -9,6 +9,8 @@ import { createToken } from 'lib/crypto';
|
|||||||
export default async (req, res) => {
|
export default async (req, res) => {
|
||||||
await useCors(req, res);
|
await useCors(req, res);
|
||||||
|
|
||||||
|
console.log('hi!');
|
||||||
|
|
||||||
if (isbot(req.headers['user-agent'])) {
|
if (isbot(req.headers['user-agent'])) {
|
||||||
return ok(res);
|
return ok(res);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user