diff --git a/x-pack/plugins/maps/public/index.ts b/x-pack/plugins/maps/public/index.ts index 74ca8c3a99af7..f4d5e985d12cb 100644 --- a/x-pack/plugins/maps/public/index.ts +++ b/x-pack/plugins/maps/public/index.ts @@ -7,10 +7,11 @@ import { PluginInitializer } from 'kibana/public'; import { PluginInitializerContext } from 'kibana/public'; import { MapsPlugin, MapsPluginSetup, MapsPluginStart } from './plugin'; +import { MapsXPackConfig } from '../config'; // @ts-ignore export const plugin: PluginInitializer = ( - initContext: PluginInitializerContext + initContext: PluginInitializerContext ) => { // @ts-ignore return new MapsPlugin(initContext); diff --git a/x-pack/plugins/maps/public/kibana_services.d.ts b/x-pack/plugins/maps/public/kibana_services.d.ts index 6ce264d024abc..45a4ace8e27a5 100644 --- a/x-pack/plugins/maps/public/kibana_services.d.ts +++ b/x-pack/plugins/maps/public/kibana_services.d.ts @@ -5,6 +5,7 @@ */ import { IIndexPattern, DataPublicPluginStart } from 'src/plugins/data/public'; import { MapsConfigType } from '../config'; +import { MapsLegacyConfigType } from '../../../../src/plugins/maps_legacy/public'; export function getLicenseId(): any; export function getInspector(): any; @@ -30,7 +31,7 @@ export function getCore(): any; export function getNavigation(): any; export function getCoreI18n(): any; export function getSearchService(): DataPublicPluginStart['search']; -export function getKibanaCommonConfig(): any; +export function getKibanaCommonConfig(): MapsLegacyConfigType; export function getMapAppConfig(): MapsConfigType; export function getIsEmsEnabled(): any; export function getEmsFontLibraryUrl(): any; @@ -40,7 +41,7 @@ export function getEmsTileApiUrl(): any; export function getEmsLandingPageUrl(): any; export function getRegionmapLayers(): any; export function getTilemap(): any; -export function getKibanaVersion(): any; +export function getKibanaVersion(): string; export function getEnabled(): boolean; export function getShowMapVisualizationTypes(): boolean; export function getShowMapsInspectorAdapter(): boolean; @@ -70,6 +71,6 @@ export function setCore(args: unknown): void; export function setNavigation(args: unknown): void; export function setCoreI18n(args: unknown): void; export function setSearchService(args: DataPublicPluginStart['search']): void; -export function setKibanaCommonConfig(args: unknown): void; -export function setMapAppConfig(args: MapsConfigType): void; -export function setKibanaVersion(args: unknown): void; +export function setKibanaCommonConfig(config: MapsLegacyConfigType): void; +export function setMapAppConfig(config: MapsConfigType): void; +export function setKibanaVersion(version: string): void; diff --git a/x-pack/plugins/maps/server/index.ts b/x-pack/plugins/maps/server/index.ts index 74a1f581b5d59..a73ba91098e90 100644 --- a/x-pack/plugins/maps/server/index.ts +++ b/x-pack/plugins/maps/server/index.ts @@ -9,6 +9,8 @@ import { MapsPlugin } from './plugin'; import { configSchema, MapsXPackConfig } from '../config'; export const config: PluginConfigDescriptor = { + // exposeToBrowser specifies kibana.yml settings to expose to the browser + // the value `true` in this context signals configuration is exposed to browser exposeToBrowser: { enabled: true, showMapVisualizationTypes: true,