Skip to content

Commit

Permalink
Set docTitle in saved objects app
Browse files Browse the repository at this point in the history
  • Loading branch information
sulemanof committed Aug 21, 2020
1 parent b75eb98 commit 2dd1a51
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import React, { lazy, Suspense } from 'react';
import ReactDOM from 'react-dom';
import { Router, Switch, Route } from 'react-router-dom';
import { I18nProvider } from '@kbn/i18n/react';
import { i18n } from '@kbn/i18n';
import { EuiLoadingSpinner } from '@elastic/eui';
import { CoreSetup } from 'src/core/public';
import { ManagementAppMountParams } from '../../../management/public';
Expand All @@ -36,6 +37,10 @@ interface MountParams {

let allowedObjectTypes: string[] | undefined;

const title = i18n.translate('savedObjectsManagement.objects.savedObjectsTitle', {
defaultMessage: 'Saved Objects',
});

const SavedObjectsEditionPage = lazy(() => import('./saved_objects_edition_page'));
const SavedObjectsTablePage = lazy(() => import('./saved_objects_table_page'));
export const mountManagementSection = async ({
Expand All @@ -49,6 +54,8 @@ export const mountManagementSection = async ({
allowedObjectTypes = await getAllowedTypes(coreStart.http);
}

coreStart.chrome.docTitle.change(title);

const capabilities = coreStart.application.capabilities;

const RedirectToHomeIfUnauthorized: React.FunctionComponent = ({ children }) => {
Expand Down

0 comments on commit 2dd1a51

Please sign in to comment.