Skip to content

Commit

Permalink
review improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
Dosant committed Apr 20, 2023
1 parent 8224761 commit 7fdc84d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import React from 'react';
import ReactDOM from 'react-dom';
// eslint-disable-next-line no-restricted-imports
import { Router, Switch, Route } from 'react-router-dom';
import { Router, Switch, Route, Redirect } from 'react-router-dom';
import { RedirectAppLinks } from '@kbn/shared-ux-link-redirect-app';
import { EuiPageTemplate, EuiSideNav } from '@elastic/eui';
import { AppMountParameters, CoreStart } from '@kbn/core/public';
Expand Down Expand Up @@ -53,9 +53,7 @@ export const renderApp = (

<EuiPageTemplate.Section>
<Switch>
<Route path="/" exact={true}>
<TodoApp contentClient={contentManagement.client} />
</Route>
<Redirect from="/" to="/todos" exact />
<Route path="/todos">
<TodoApp contentClient={contentManagement.client} />
</Route>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export const MSearchApp = (props: {
<I18nProvider>
<TableListViewKibanaProvider
core={{
application: props.core.application as any, // TODO: fix it on the TableListView side
application: props.core.application,
notifications: props.core.notifications,
overlays: props.core.overlays,
http: props.core.http,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ export const MSearchTable = () => {
entityNamePlural={`ContentItems`}
tableListTitle={`MSearch Demo`}
urlStateEnabled={false}
emptyPrompt={<>No data found. Try to install some sample data first.</>}
onClickTitle={(item) => {
alert(`Clicked item ${item.attributes.title} (${item.id})`);
}}
Expand Down
4 changes: 1 addition & 3 deletions packages/content-management/table_list/src/services.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,7 @@ export interface TableListViewKibanaDependencies {
core: {
application: {
capabilities: {
advancedSettings?: {
save: boolean;
};
[key: string]: Readonly<Record<string, boolean | Record<string, boolean>>>;
};
getUrlForApp: (app: string, options: { path: string }) => string;
currentAppId$: Observable<string | undefined>;
Expand Down

0 comments on commit 7fdc84d

Please sign in to comment.