Skip to content

Commit

Permalink
Add support new navigation for maps (#635)
Browse files Browse the repository at this point in the history
Signed-off-by: Junqiu Lei <junqiu@amazon.com>
  • Loading branch information
junqiu-lei authored Jul 18, 2024
1 parent 605e894 commit f7fdf0a
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

## [Unreleased 2.x](https://github.com/opensearch-project/dashboards-maps/compare/2.15...2.x)
### Features
* Add support new navigation for maps ([#635](https://github.com/opensearch-project/dashboards-maps/pull/635))
### Enhancements
### Bug Fixes
* Fixed broken wms custom layer update ([#601](https://github.com/opensearch-project/dashboards-maps/pull/631))
Expand Down
20 changes: 20 additions & 0 deletions public/plugin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ import {
AppMountParameters,
CoreSetup,
CoreStart,
DEFAULT_APP_CATEGORIES,
DEFAULT_NAV_GROUPS,
Plugin,
PluginInitializerContext,
} from '../../../src/core/public';
Expand Down Expand Up @@ -100,6 +102,24 @@ export class CustomImportMapPlugin
},
});

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

core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS['security-analytics'], [{
id: MAPS_APP_ID,
category: DEFAULT_APP_CATEGORIES.visualizeAndReport,
order: 200,
}]);

core.chrome.navGroup.addNavLinksToGroup(DEFAULT_NAV_GROUPS.search, [{
id: MAPS_APP_ID,
category: DEFAULT_APP_CATEGORIES.analyzeSearch,
order: 200,
}]);

const mapEmbeddableFactory = new MapEmbeddableFactoryDefinition(async () => {
const [coreStart, depsStart] = await core.getStartServices();
const { navigation, data: useData } = depsStart as AppPluginStartDependencies;
Expand Down

0 comments on commit f7fdf0a

Please sign in to comment.