diff --git a/x-pack/plugins/enterprise_search/public/applications/workplace_search/index.tsx b/x-pack/plugins/enterprise_search/public/applications/workplace_search/index.tsx index dd263c3bd69f5d..81df0950fb231c 100644 --- a/x-pack/plugins/enterprise_search/public/applications/workplace_search/index.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/workplace_search/index.tsx @@ -41,7 +41,6 @@ import { SourceAdded } from './views/content_sources/components/source_added'; import { SourceSubNav } from './views/content_sources/components/source_sub_nav'; import { ErrorState } from './views/error_state'; import { GroupsRouter } from './views/groups'; -import { GroupSubNav } from './views/groups/components/group_sub_nav'; import { Overview } from './views/overview'; import { RoleMappings } from './views/role_mappings'; import { Security } from './views/security'; @@ -64,7 +63,6 @@ export const WorkplaceSearchConfigured: React.FC = (props) => { // We don't want so show the subnavs on the container root pages. const showSourcesSubnav = pathname !== SOURCES_PATH && pathname !== PERSONAL_SOURCES_PATH; - const showGroupsSubnav = pathname !== GROUPS_PATH; /** * Personal dashboard urls begin with /p/ @@ -132,13 +130,7 @@ export const WorkplaceSearchConfigured: React.FC = (props) => { - } />} - restrictWidth - readOnlyMode={readOnlyMode} - > - - + diff --git a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.test.tsx b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.test.tsx index 4c13dbce3ef1e6..08140c525a84e1 100644 --- a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.test.tsx @@ -15,9 +15,6 @@ import { Route, Switch } from 'react-router-dom'; import { shallow } from 'enzyme'; -import { FlashMessages } from '../../../shared/flash_messages'; -import { SetWorkplaceSearchChrome as SetPageChrome } from '../../../shared/kibana_chrome'; - import { GroupOverview } from './components/group_overview'; import { GroupSourcePrioritization } from './components/group_source_prioritization'; import { ManageUsersModal } from './components/manage_users_modal'; @@ -40,10 +37,10 @@ describe('GroupRouter', () => { resetGroup, }); }); + it('renders', () => { const wrapper = shallow(); - expect(wrapper.find(FlashMessages)).toHaveLength(1); expect(wrapper.find(Switch)).toHaveLength(1); expect(wrapper.find(Route)).toHaveLength(2); expect(wrapper.find(GroupOverview)).toHaveLength(1); @@ -62,22 +59,4 @@ describe('GroupRouter', () => { expect(wrapper.find(ManageUsersModal)).toHaveLength(1); expect(wrapper.find(SharedSourcesModal)).toHaveLength(1); }); - - it('handles breadcrumbs while loading', () => { - setMockValues({ - sharedSourcesModalVisible: false, - manageUsersModalVisible: false, - group: {}, - }); - - const loadingBreadcrumbs = ['Groups', '...']; - - const wrapper = shallow(); - - const firstBreadCrumb = wrapper.find(SetPageChrome).first(); - const lastBreadCrumb = wrapper.find(SetPageChrome).last(); - - expect(firstBreadCrumb.prop('trail')).toEqual([...loadingBreadcrumbs, 'Source Prioritization']); - expect(lastBreadCrumb.prop('trail')).toEqual(loadingBreadcrumbs); - }); }); diff --git a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.tsx b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.tsx index a5b8bd138d0c8b..950ebb79a21c18 100644 --- a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/group_router.tsx @@ -10,10 +10,6 @@ import { Route, Switch, useParams } from 'react-router-dom'; import { useActions, useValues } from 'kea'; -import { FlashMessages } from '../../../shared/flash_messages'; -import { SetWorkplaceSearchChrome as SetPageChrome } from '../../../shared/kibana_chrome'; -import { SendWorkplaceSearchTelemetry as SendTelemetry } from '../../../shared/telemetry'; -import { NAV } from '../../constants'; import { GROUP_SOURCE_PRIORITIZATION_PATH, GROUP_PATH } from '../../routes'; import { GroupOverview } from './components/group_overview'; @@ -26,11 +22,7 @@ export const GroupRouter: React.FC = () => { const { groupId } = useParams() as { groupId: string }; const { initializeGroup, resetGroup } = useActions(GroupLogic); - const { - sharedSourcesModalVisible, - manageUsersModalVisible, - group: { name }, - } = useValues(GroupLogic); + const { sharedSourcesModalVisible, manageUsersModalVisible } = useValues(GroupLogic); useEffect(() => { initializeGroup(groupId); @@ -39,15 +31,11 @@ export const GroupRouter: React.FC = () => { return ( <> - - - - diff --git a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/groups_router.tsx b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/groups_router.tsx index d8c4f4801ba24b..06e0a18b933f2f 100644 --- a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/groups_router.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/groups/groups_router.tsx @@ -10,9 +10,6 @@ import { Route, Switch } from 'react-router-dom'; import { useActions } from 'kea'; -import { SetWorkplaceSearchChrome as SetPageChrome } from '../../../shared/kibana_chrome'; -import { SendWorkplaceSearchTelemetry as SendTelemetry } from '../../../shared/telemetry'; -import { NAV } from '../../constants'; import { GROUP_PATH, GROUPS_PATH } from '../../routes'; import { GroupRouter } from './group_router'; @@ -31,8 +28,6 @@ export const GroupsRouter: React.FC = () => { return ( - -