Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: [Search:AppSearch:Engines page]Data from page disappears after clicking on Last updated date #201768

Merged
merged 10 commits into from
Dec 12, 2024
1 change: 1 addition & 0 deletions x-pack/plugins/enterprise_search/kibana.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"logsDataAccess",
"esUiShared",
"navigation",
"uiActions"
],
"optionalPlugins": [
"customIntegrations",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import { mlPluginMock } from '@kbn/ml-plugin/public/mocks';
import { navigationPluginMock } from '@kbn/navigation-plugin/public/mocks';
import { securityMock } from '@kbn/security-plugin/public/mocks';
import { sharePluginMock } from '@kbn/share-plugin/public/mocks';
import { uiActionsPluginMock } from '@kbn/ui-actions-plugin/public/mocks';

import { AppSearch } from './app_search';
import { EnterpriseSearchOverview } from './enterprise_search_overview';
Expand All @@ -52,6 +53,7 @@ describe('renderApp', () => {
security: securityMock.createStart(),
share: sharePluginMock.createStartContract(),
ml: mlPluginMock.createStartContract(),
uiActions: uiActionsPluginMock.createStartContract(),
user: {},
},
updateSideNavDefinition: jest.fn(),
Expand Down
58 changes: 34 additions & 24 deletions x-pack/plugins/enterprise_search/public/applications/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,11 @@ import { Store } from 'redux';

import { of } from 'rxjs';

import { CellActionsProvider } from '@kbn/cell-actions';

import { AppMountParameters, CoreStart } from '@kbn/core/public';
import { I18nProvider } from '@kbn/i18n-react';
import { EuiThemeProvider } from '@kbn/kibana-react-plugin/common';

import { KibanaContextProvider } from '@kbn/kibana-react-plugin/public';
import { KibanaThemeProvider } from '@kbn/react-kibana-context-theme';
Expand Down Expand Up @@ -146,34 +149,41 @@ export const renderApp = (
http,
readOnlyMode,
});

const unmountFlashMessagesLogic = mountFlashMessagesLogic({ notifications });
ReactDOM.render(
<I18nProvider>
<KibanaThemeProvider theme={{ theme$: params.theme$ }}>
<KibanaContextProvider
services={{
...core,
...plugins,
}}
>
<CloudContext>
<Provider store={store}>
<Router history={params.history}>
<App
access={productAccess}
appSearch={appSearch}
configuredLimits={configuredLimits}
enterpriseSearchVersion={enterpriseSearchVersion}
features={features}
kibanaVersion={kibanaVersion}
readOnlyMode={readOnlyMode}
searchOAuth={searchOAuth}
workplaceSearch={workplaceSearch}
/>
</Router>
</Provider>
</CloudContext>
</KibanaContextProvider>
<EuiThemeProvider darkMode={core.theme.getTheme().darkMode}>
<KibanaContextProvider
services={{
...core,
...plugins,
}}
>
<CellActionsProvider
getTriggerCompatibleActions={plugins.uiActions.getTriggerCompatibleActions}
>
<CloudContext>
<Provider store={store}>
<Router history={params.history}>
<App
access={productAccess}
appSearch={appSearch}
configuredLimits={configuredLimits}
enterpriseSearchVersion={enterpriseSearchVersion}
features={features}
kibanaVersion={kibanaVersion}
readOnlyMode={readOnlyMode}
searchOAuth={searchOAuth}
workplaceSearch={workplaceSearch}
/>
</Router>
</Provider>
</CloudContext>
</CellActionsProvider>
</KibanaContextProvider>
</EuiThemeProvider>
</KibanaThemeProvider>
</I18nProvider>,
params.element
Expand Down
4 changes: 3 additions & 1 deletion x-pack/plugins/enterprise_search/public/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ import {
AppStatus,
} from '@kbn/core/public';
import { DataPublicPluginStart } from '@kbn/data-plugin/public';

import { GuidedOnboardingPluginStart } from '@kbn/guided-onboarding-plugin/public';
import type { HomePublicPluginSetup } from '@kbn/home-plugin/public';
import { i18n } from '@kbn/i18n';
Expand All @@ -38,6 +37,7 @@ import type { SearchNavigationPluginStart } from '@kbn/search-navigation/public'
import { SearchPlaygroundPluginStart } from '@kbn/search-playground/public';
import { SecurityPluginSetup, SecurityPluginStart } from '@kbn/security-plugin/public';
import { SharePluginSetup, SharePluginStart } from '@kbn/share-plugin/public';
import { UiActionsSetup, UiActionsStart } from '@kbn/ui-actions-plugin/public';

import {
ANALYTICS_PLUGIN,
Expand Down Expand Up @@ -82,6 +82,7 @@ interface PluginsSetup {
licensing: LicensingPluginStart;
security?: SecurityPluginSetup;
share?: SharePluginSetup;
uiActions: UiActionsSetup;
}

export interface PluginsStart {
Expand All @@ -100,6 +101,7 @@ export interface PluginsStart {
searchPlayground?: SearchPlaygroundPluginStart;
security?: SecurityPluginStart;
share?: SharePluginStart;
uiActions: UiActionsStart;
}

export interface ESConfig {
Expand Down
2 changes: 2 additions & 0 deletions x-pack/plugins/enterprise_search/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -84,5 +84,7 @@
"@kbn/core-security-server-mocks",
"@kbn/unsaved-changes-prompt",
"@kbn/search-navigation",
"@kbn/cell-actions",
"@kbn/ui-actions-plugin",
]
}
Loading