Skip to content

Commit

Permalink
[Navigation] Remove integrations from new NavGroups (#1950)
Browse files Browse the repository at this point in the history
* Remove integrations from new Nav

Signed-off-by: Adam Tackett <[email protected]>

* Integrations only in observability

Signed-off-by: Adam Tackett <[email protected]>

* Update snapshots

Signed-off-by: Adam Tackett <[email protected]>

---------

Signed-off-by: Adam Tackett <[email protected]>
Co-authored-by: Adam Tackett <[email protected]>
(cherry picked from commit 0b472ec)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
github-actions[bot] and Adam Tackett committed Jul 22, 2024
1 parent cd02824 commit f605207
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 33 deletions.
16 changes: 8 additions & 8 deletions public/plugin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,14 @@ export class ObservabilityPlugin
mount: appMountWithStartPage('applications'),
});

core.application.register({
id: observabilityIntegrationsID,
title: observabilityIntegrationsTitle,
category: DEFAULT_APP_CATEGORIES.management,
order: observabilityIntegrationsPluginOrder,
mount: appMountWithStartPage('integrations'),
});

if (core.chrome.navGroup.getNavGroupEnabled()) {
core.application.register({
id: 'observability-traces-nav',
Expand Down Expand Up @@ -351,14 +359,6 @@ export class ObservabilityPlugin
mount: appMountWithStartPage('notebooks'),
});

core.application.register({
id: observabilityIntegrationsID,
title: observabilityIntegrationsTitle,
category: DEFAULT_APP_CATEGORIES.management,
order: observabilityIntegrationsPluginOrder,
mount: appMountWithStartPage('integrations'),
});

registerAllPluginNavGroups(core);

core.application.register({
Expand Down
37 changes: 12 additions & 25 deletions public/plugin_nav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
* Copyright OpenSearch Contributors
* SPDX-License-Identifier: Apache-2.0
*/

import {
observabilityApplicationsID,
observabilityIntegrationsID,
Expand All @@ -21,6 +22,14 @@ export function registerAllPluginNavGroups(core: CoreSetup<AppPluginStartDepende
},
]);

core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.observability, [
{
id: observabilityIntegrationsID,
category: DEFAULT_APP_CATEGORIES.visualizeAndReport,
order: 500,
},
]);

core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.observability, [
{
id: observabilityMetricsID,
Expand All @@ -33,47 +42,25 @@ export function registerAllPluginNavGroups(core: CoreSetup<AppPluginStartDepende
core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.observability, [
{
id: observabilityNotebookID,
category: DEFAULT_APP_CATEGORIES.dashboardAndReport,
category: DEFAULT_APP_CATEGORIES.visualizeAndReport,
order: 400,
},
]);
core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS[`security-analytics`], [
{
id: observabilityNotebookID,
category: DEFAULT_APP_CATEGORIES.dashboardAndReport,
category: DEFAULT_APP_CATEGORIES.visualizeAndReport,
order: 400,
},
]);
core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.analytics, [
{
id: observabilityNotebookID,
category: DEFAULT_APP_CATEGORIES.dashboardAndReport,
category: DEFAULT_APP_CATEGORIES.visualizeAndReport,
order: 400,
},
]);

core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.observability, [
{
id: observabilityIntegrationsID,
category: DEFAULT_APP_CATEGORIES.dashboardAndReport,
order: 500,
},
]);
core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS[`security-analytics`], [
{
id: observabilityIntegrationsID,
category: DEFAULT_APP_CATEGORIES.dashboardAndReport,
order: 500,
},
]);
core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.analytics, [
{
id: observabilityIntegrationsID,
category: DEFAULT_APP_CATEGORIES.dashboardAndReport,
order: 500,
},
]);

core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.observability, [
{
id: 'observability-traces-nav',
Expand Down

0 comments on commit f605207

Please sign in to comment.