Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: [Obs Applications > Services | Traces | Dependencies][SCREEN READER]: H1 tag should not include secondary information #193880

Merged
merged 6 commits into from
Oct 8, 2024
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* 2.0.
*/

import { EuiFlexGroup, EuiFlexItem, EuiPageHeaderProps } from '@elastic/eui';
import { EuiFlexGroup, EuiPageHeaderProps } from '@elastic/eui';
import { useKibana } from '@kbn/kibana-react-plugin/public';
import { entityCentricExperience } from '@kbn/observability-plugin/common';
import { ObservabilityPageTemplateProps } from '@kbn/observability-shared-plugin/public';
Expand Down Expand Up @@ -139,34 +139,24 @@ export function ApmMainTemplate({
noDataConfig,
});

const rightSideItems = [...(showServiceGroupSaveButton ? [<ServiceGroupSaveButton />] : [])];

const sanitizedPath = getPathForFeedback(window.location.pathname);
const pageHeaderTitle = (
<EuiFlexGroup justifyContent="spaceBetween" wrap={true}>
{pageHeader?.pageTitle ?? pageTitle}
<EuiFlexItem grow={false} />
<EuiFlexItem grow={false}>
<EuiFlexGroup justifyContent="center">
<EuiFlexItem grow={false}>
<FeatureFeedbackButton
data-test-subj="infraApmFeedbackLink"
formUrl={
isEntityCentricExperienceViewEnabled && sanitizedPath.includes('service')
? APM_NEW_EXPERIENCE_FEEDBACK_LINK
: APM_FEEDBACK_LINK
}
kibanaVersion={kibanaVersion}
isCloudEnv={isCloudEnv}
isServerlessEnv={isServerlessEnv}
sanitizedPath={sanitizedPath}
/>
</EuiFlexItem>
<EuiFlexItem grow={false}>{environmentFilter && <ApmEnvironmentFilter />}</EuiFlexItem>
</EuiFlexGroup>
</EuiFlexItem>
</EuiFlexGroup>
);

const rightSideItems = [
...(showServiceGroupSaveButton ? [<ServiceGroupSaveButton />] : []),
...(environmentFilter ? [<ApmEnvironmentFilter />] : []),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Look at where the env filter is located now:
Screenshot 2024-09-25 at 14 26 08

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cauemarcondes ok, let's wait till EUI will fix elastic/eui#8039.

<FeatureFeedbackButton
data-test-subj="infraApmFeedbackLink"
formUrl={
isEntityCentricExperienceViewEnabled && sanitizedPath.includes('service')
? APM_NEW_EXPERIENCE_FEEDBACK_LINK
: APM_FEEDBACK_LINK
}
kibanaVersion={kibanaVersion}
isCloudEnv={isCloudEnv}
isServerlessEnv={isServerlessEnv}
sanitizedPath={sanitizedPath}
/>,
];

const pageTemplate = showCustomEmptyState ? (
<CustomNoDataTemplate isPageDataLoaded={isLoading === false} noDataConfig={noDataConfig} />
Expand All @@ -182,7 +172,7 @@ export function ApmMainTemplate({
pageHeader={{
rightSideItems,
...pageHeader,
pageTitle: pageHeaderTitle,
pageTitle: pageHeader?.pageTitle ?? pageTitle,
children: (
<EuiFlexGroup direction="column">
{isEntityCentricExperienceSettingEnabled &&
Expand Down