Skip to content

Commit

Permalink
use KibanaThemeProvider from react-kibana-context-theme (elastic#167232)
Browse files Browse the repository at this point in the history
Fixes elastic#164369

### Acceptance criteria
- use KibanaThemeProvider from @kbn/react-kibana-context-theme for the
App component

---------

Co-authored-by: kibanamachine <[email protected]>
  • Loading branch information
mgiota and kibanamachine authored Sep 26, 2023
1 parent 2739c9d commit 22029b5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
9 changes: 3 additions & 6 deletions x-pack/plugins/observability/public/application/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,8 @@ import { Router, Routes, Route } from '@kbn/shared-ux-router';
import { AppMountParameters, APP_WRAPPER_CLASS, CoreStart } from '@kbn/core/public';
import { EuiThemeProvider } from '@kbn/kibana-react-plugin/common';
import type { LazyObservabilityPageTemplateProps } from '@kbn/observability-shared-plugin/public';
import {
KibanaContextProvider,
KibanaThemeProvider,
RedirectAppLinks,
} from '@kbn/kibana-react-plugin/public';
import { KibanaContextProvider, RedirectAppLinks } from '@kbn/kibana-react-plugin/public';
import { KibanaThemeProvider } from '@kbn/react-kibana-context-theme';
import { Storage } from '@kbn/kibana-utils-plugin/public';
import { UsageCollectionSetup } from '@kbn/usage-collection-plugin/public';
import { ObservabilityAIAssistantProvider } from '@kbn/observability-ai-assistant-plugin/public';
Expand Down Expand Up @@ -90,7 +87,7 @@ export const renderApp = ({
ReactDOM.render(
<EuiErrorBoundary>
<ApplicationUsageTrackingProvider>
<KibanaThemeProvider theme$={theme$}>
<KibanaThemeProvider {...{ theme: { theme$ } }}>
<CloudProvider>
<KibanaContextProvider
services={{
Expand Down
3 changes: 2 additions & 1 deletion x-pack/plugins/observability/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@
"@kbn/osquery-plugin",
"@kbn/aiops-plugin",
"@kbn/content-management-plugin",
"@kbn/deeplinks-observability"
"@kbn/deeplinks-observability",
"@kbn/react-kibana-context-theme"
],
"exclude": [
"target/**/*"
Expand Down

0 comments on commit 22029b5

Please sign in to comment.