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 coordinate maps layers dropdown #70609

Merged
merged 2 commits into from
Jul 14, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/plugins/tile_map/public/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ import 'angular-sanitize';
import { createTileMapFn } from './tile_map_fn';
// @ts-ignore
import { createTileMapTypeDefinition } from './tile_map_type';
import { MapsLegacyPluginSetup } from '../../maps_legacy/public';
import { IServiceSettings, MapsLegacyPluginSetup } from '../../maps_legacy/public';
import { DataPublicPluginStart } from '../../data/public';
import { setFormatService, setQueryService } from './services';
import { setKibanaLegacy } from './services';
Expand All @@ -48,6 +48,7 @@ interface TileMapVisualizationDependencies {
getZoomPrecision: any;
getPrecision: any;
BaseMapsVisualization: any;
serviceSettings: IServiceSettings;
}

/** @internal */
Expand Down Expand Up @@ -81,12 +82,13 @@ export class TileMapPlugin implements Plugin<TileMapPluginSetup, TileMapPluginSt
core: CoreSetup,
{ expressions, visualizations, mapsLegacy }: TileMapPluginSetupDependencies
) {
const { getZoomPrecision, getPrecision } = mapsLegacy;
const { getZoomPrecision, getPrecision, serviceSettings } = mapsLegacy;
const visualizationDependencies: Readonly<TileMapVisualizationDependencies> = {
getZoomPrecision,
getPrecision,
BaseMapsVisualization: mapsLegacy.getBaseMapsVis(),
uiSettings: core.uiSettings,
serviceSettings,
};

expressions.registerFunction(() => createTileMapFn(visualizationDependencies));
Expand Down