[RUM Dashboard] Update rum title to be consistent with APM (#70460)
This commit is contained in:
parent
006670244a
commit
9ff68e4c8c
|
@ -27,7 +27,6 @@ import { ServiceOverview } from '../ServiceOverview';
|
||||||
import { TraceOverview } from '../TraceOverview';
|
import { TraceOverview } from '../TraceOverview';
|
||||||
import { RumOverview } from '../RumDashboard';
|
import { RumOverview } from '../RumDashboard';
|
||||||
import { RumOverviewLink } from '../../shared/Links/apm/RumOverviewLink';
|
import { RumOverviewLink } from '../../shared/Links/apm/RumOverviewLink';
|
||||||
import { I18LABELS } from '../RumDashboard/translations';
|
|
||||||
|
|
||||||
function getHomeTabs({
|
function getHomeTabs({
|
||||||
serviceMapEnabled = true,
|
serviceMapEnabled = true,
|
||||||
|
@ -109,11 +108,7 @@ export function Home({ tab }: Props) {
|
||||||
<EuiFlexGroup alignItems="center">
|
<EuiFlexGroup alignItems="center">
|
||||||
<EuiFlexItem grow={false}>
|
<EuiFlexItem grow={false}>
|
||||||
<EuiTitle size="l">
|
<EuiTitle size="l">
|
||||||
<h1>
|
<h1>APM</h1>
|
||||||
{selectedTab.name === 'rum-overview'
|
|
||||||
? I18LABELS.endUserExperience
|
|
||||||
: 'APM'}
|
|
||||||
</h1>
|
|
||||||
</EuiTitle>
|
</EuiTitle>
|
||||||
</EuiFlexItem>
|
</EuiFlexItem>
|
||||||
<EuiFlexItem grow={false}>
|
<EuiFlexItem grow={false}>
|
||||||
|
|
|
@ -16,50 +16,33 @@ import { ClientMetrics } from './ClientMetrics';
|
||||||
import { PageViewsTrend } from './PageViewsTrend';
|
import { PageViewsTrend } from './PageViewsTrend';
|
||||||
import { PageLoadDistribution } from './PageLoadDistribution';
|
import { PageLoadDistribution } from './PageLoadDistribution';
|
||||||
import { I18LABELS } from './translations';
|
import { I18LABELS } from './translations';
|
||||||
import { useUrlParams } from '../../../hooks/useUrlParams';
|
|
||||||
|
|
||||||
export function RumDashboard() {
|
export function RumDashboard() {
|
||||||
const { urlParams } = useUrlParams();
|
|
||||||
|
|
||||||
const { environment } = urlParams;
|
|
||||||
|
|
||||||
let environmentLabel = environment || 'all environments';
|
|
||||||
|
|
||||||
if (environment === 'ENVIRONMENT_NOT_DEFINED') {
|
|
||||||
environmentLabel = 'undefined environment';
|
|
||||||
}
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<EuiFlexGroup direction="column" gutterSize="s">
|
||||||
<EuiTitle>
|
<EuiFlexItem>
|
||||||
<h2>{I18LABELS.getWhatIsGoingOn(environmentLabel)}</h2>
|
<EuiPanel>
|
||||||
</EuiTitle>
|
<EuiFlexGroup justifyContent="spaceBetween">
|
||||||
<EuiSpacer />
|
<EuiFlexItem grow={1} data-cy={`client-metrics`}>
|
||||||
<EuiFlexGroup direction="column" gutterSize="s">
|
<EuiTitle size="xs">
|
||||||
<EuiFlexItem>
|
<h3>{I18LABELS.pageLoadTimes}</h3>
|
||||||
<EuiPanel>
|
</EuiTitle>
|
||||||
<EuiFlexGroup justifyContent="spaceBetween">
|
<EuiSpacer size="s" />
|
||||||
<EuiFlexItem grow={1} data-cy={`client-metrics`}>
|
<ClientMetrics />
|
||||||
<EuiTitle size="xs">
|
</EuiFlexItem>
|
||||||
<h3>{I18LABELS.pageLoadTimes}</h3>
|
</EuiFlexGroup>
|
||||||
</EuiTitle>
|
</EuiPanel>
|
||||||
<EuiSpacer size="s" />
|
</EuiFlexItem>
|
||||||
<ClientMetrics />
|
<EuiFlexItem>
|
||||||
</EuiFlexItem>
|
<EuiPanel>
|
||||||
</EuiFlexGroup>
|
<EuiFlexGroup justifyContent="spaceBetween">
|
||||||
</EuiPanel>
|
<EuiFlexItem grow={3}>
|
||||||
</EuiFlexItem>
|
<PageLoadDistribution />
|
||||||
<EuiFlexItem>
|
<PageViewsTrend />
|
||||||
<EuiPanel>
|
</EuiFlexItem>
|
||||||
<EuiFlexGroup justifyContent="spaceBetween">
|
</EuiFlexGroup>
|
||||||
<EuiFlexItem grow={3}>
|
</EuiPanel>
|
||||||
<PageLoadDistribution />
|
</EuiFlexItem>
|
||||||
<PageViewsTrend />
|
</EuiFlexGroup>
|
||||||
</EuiFlexItem>
|
|
||||||
</EuiFlexGroup>
|
|
||||||
</EuiPanel>
|
|
||||||
</EuiFlexItem>
|
|
||||||
</EuiFlexGroup>
|
|
||||||
</>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,14 +7,6 @@
|
||||||
import { i18n } from '@kbn/i18n';
|
import { i18n } from '@kbn/i18n';
|
||||||
|
|
||||||
export const I18LABELS = {
|
export const I18LABELS = {
|
||||||
endUserExperience: i18n.translate('xpack.apm.rum.dashboard.title', {
|
|
||||||
defaultMessage: 'End User Experience',
|
|
||||||
}),
|
|
||||||
getWhatIsGoingOn: (environmentVal: string) =>
|
|
||||||
i18n.translate('xpack.apm.rum.dashboard.environment.title', {
|
|
||||||
defaultMessage: `What's going on in {environmentVal}?`,
|
|
||||||
values: { environmentVal },
|
|
||||||
}),
|
|
||||||
backEnd: i18n.translate('xpack.apm.rum.dashboard.backend', {
|
backEnd: i18n.translate('xpack.apm.rum.dashboard.backend', {
|
||||||
defaultMessage: 'Backend',
|
defaultMessage: 'Backend',
|
||||||
}),
|
}),
|
||||||
|
|
Loading…
Reference in a new issue