mirror of
https://github.com/elastic/kibana.git
synced 2025-04-18 23:21:39 -04:00
## Summary
Part of Epic: https://github.com/elastic/kibana-team/issues/1439
Addresses https://github.com/elastic/kibana/issues/212903, but does not
remove the landing page access. The landing page access will be removed
in https://github.com/elastic/kibana/pull/210893
**Changes**
1. Converts the declaration of the Security Solution side navigation for
serverless and stateful projects into a static declaration, rather than
algorithmically parsing registered links to dynamically build the
declaration.
2. Updates the contents of the "Assets" panel to prepare for removal of
that landing page.
3. Eliminates the top-level nesting of the nav items, which removes the
extra space between the project title and the first nav items. See
45454bdc4d
**Known issue**: Clicking the "Browse integrations" button does not
close the secondary nav panel. Doing that will be a relatively simple
chore, but will require some changes in the SharedUX chrome-navigation
package, as well as the `LinkButton` component in the Security Solution
navigation-links package.
### Screenshots
Serverless

Stateful/ECH

### Checklist
Check the PR satisfies following conditions.
Reviewers should verify this PR satisfies this list as well.
- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
---------
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
38 lines
1.2 KiB
TypeScript
38 lines
1.2 KiB
TypeScript
/*
|
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
* or more contributor license agreements. Licensed under the Elastic License
|
|
* 2.0; you may not use this file except in compliance with the Elastic License
|
|
* 2.0.
|
|
*/
|
|
|
|
import { FtrProviderContext } from '../../ftr_provider_context';
|
|
|
|
export function MachineLearningNavigationProviderSecurity({ getService }: FtrProviderContext) {
|
|
const testSubjects = getService('testSubjects');
|
|
|
|
async function navigateToArea(id: string) {
|
|
await testSubjects.click('~panelOpener-deepLinkId-securitySolutionUI:machine_learning-landing');
|
|
await testSubjects.existOrFail(`~panelNavItem-id-ml:${id}`, {
|
|
timeout: 60 * 1000,
|
|
});
|
|
await testSubjects.click(`~panelNavItem-id-ml:${id}`);
|
|
}
|
|
|
|
return {
|
|
async navigateToAnomalyDetection() {
|
|
await navigateToArea('anomalyDetection');
|
|
},
|
|
async navigateToDataFrameAnalytics() {
|
|
await navigateToArea('dataFrameAnalytics');
|
|
},
|
|
async navigateToTrainedModels() {
|
|
await navigateToArea('nodesOverview');
|
|
},
|
|
async navigateToMemoryUsage() {
|
|
await navigateToArea('memoryUsage');
|
|
},
|
|
async navigateToNotifications() {
|
|
await navigateToArea('notifications');
|
|
},
|
|
};
|
|
}
|