Skip to content

Commit

Permalink
type fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
smith committed Oct 25, 2021
1 parent a8b5af1 commit 20c1d05
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { MemoryRouter } from 'react-router-dom';
import { CoreStart } from '../../../../../../../../src/core/public';
import { createKibanaReactContext } from '../../../../../../../../src/plugins/kibana_react/public';
import { ServiceHealthStatus } from '../../../../../common/service_health_status';
import type { ApmPluginContextValue } from '../../../../context/apm_plugin';
import type { ApmPluginContextValue } from '../../../../context/apm_plugin/apm_plugin_context';
import { MockApmPluginContextWrapper } from '../../../../context/apm_plugin/mock_apm_plugin_context';
import { ServiceList } from './';
import { items } from './__fixtures__/service_api_mock_data';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@
* 2.0.
*/

import { Meta, Story } from '@storybook/react';
import { CoreStart, DocLinksStart, HttpStart } from 'kibana/public';
import type { Meta, Story } from '@storybook/react';
import type { CoreStart, DocLinksStart, HttpStart } from 'kibana/public';
import React, { ComponentProps } from 'react';
import { MemoryRouter } from 'react-router-dom';
import { createKibanaReactContext } from '../../../../../../../src/plugins/kibana_react/public';
import type { ApmPluginContextValue } from '../../../context/apm_plugin/apm_plugin_context';
import { MockApmPluginContextWrapper } from '../../../context/apm_plugin/mock_apm_plugin_context';
import { SettingsTemplate } from './settings_template';

Expand All @@ -31,7 +32,7 @@ const coreMock = {
get: () => `/basepath`,
},
get: async () => ({}),
} as HttpStart,
},
docLinks: {
DOC_LINK_VERSION: '0',
ELASTIC_WEBSITE_URL: 'https://www.elastic.co/',
Expand All @@ -52,7 +53,9 @@ const stories: Meta<Args> = {
return (
<MemoryRouter>
<KibanaReactContext.Provider>
<MockApmPluginContextWrapper value={{ core: coreMock }}>
<MockApmPluginContextWrapper
value={{ core: coreMock } as unknown as ApmPluginContextValue}
>
<StoryComponent />
</MockApmPluginContextWrapper>
</KibanaReactContext.Provider>
Expand Down

0 comments on commit 20c1d05

Please sign in to comment.