diff --git a/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_header_link.tsx b/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_header_link.tsx
index 12d3647aeb52..cd378ec84267 100644
--- a/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_header_link.tsx
+++ b/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_header_link.tsx
@@ -6,19 +6,16 @@
*/
import React, { memo, useState, useEffect } from 'react';
-import { BehaviorSubject } from 'rxjs';
import { FormattedMessage } from '@kbn/i18n/react';
import { EuiButtonEmpty } from '@elastic/eui';
import type { TutorialDirectoryHeaderLinkComponent } from 'src/plugins/home/public';
-import { useLink, useCapabilities } from '../../hooks';
-
-const tutorialDirectoryNoticeState$ = new BehaviorSubject({
- settingsDataLoaded: false,
- hasSeenNotice: false,
-});
+import { RedirectAppLinks } from '../../../../../../../../src/plugins/kibana_react/public';
+import { useLink, useCapabilities, useStartServices } from '../../hooks';
+import { tutorialDirectoryNoticeState$ } from './tutorial_directory_notice';
const TutorialDirectoryHeaderLink: TutorialDirectoryHeaderLinkComponent = memo(() => {
const { getHref } = useLink();
+ const { application } = useStartServices();
const { show: hasIngestManager } = useCapabilities();
const [noticeState, setNoticeState] = useState({
settingsDataLoaded: false,
@@ -33,12 +30,14 @@ const TutorialDirectoryHeaderLink: TutorialDirectoryHeaderLinkComponent = memo((
}, []);
return hasIngestManager && noticeState.settingsDataLoaded && noticeState.hasSeenNotice ? (
-
-
-
+
+
+
+
+
) : null;
});
diff --git a/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_notice.tsx b/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_notice.tsx
index 57a280303830..8ea0c8730fdb 100644
--- a/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_notice.tsx
+++ b/x-pack/plugins/fleet/public/applications/fleet/components/home_integration/tutorial_directory_notice.tsx
@@ -19,7 +19,14 @@ import {
EuiSpacer,
} from '@elastic/eui';
import type { TutorialDirectoryNoticeComponent } from 'src/plugins/home/public';
-import { sendPutSettings, useGetSettings, useLink, useCapabilities } from '../../hooks';
+import { RedirectAppLinks } from '../../../../../../../../src/plugins/kibana_react/public';
+import {
+ sendPutSettings,
+ useGetSettings,
+ useLink,
+ useCapabilities,
+ useStartServices,
+} from '../../hooks';
const FlexItemButtonWrapper = styled(EuiFlexItem)`
&&& {
@@ -27,13 +34,14 @@ const FlexItemButtonWrapper = styled(EuiFlexItem)`
}
`;
-const tutorialDirectoryNoticeState$ = new BehaviorSubject({
+export const tutorialDirectoryNoticeState$ = new BehaviorSubject({
settingsDataLoaded: false,
hasSeenNotice: false,
});
const TutorialDirectoryNotice: TutorialDirectoryNoticeComponent = memo(() => {
const { getHref } = useLink();
+ const { application } = useStartServices();
const { show: hasIngestManager } = useCapabilities();
const { data: settingsData, isLoading } = useGetSettings();
const [dismissedNotice, setDismissedNotice] = useState(false);
@@ -98,12 +106,14 @@ const TutorialDirectoryNotice: TutorialDirectoryNoticeComponent = memo(() => {
-
-
-
+
+
+
+
+