Skip to content

Commit

Permalink
Add missing types
Browse files Browse the repository at this point in the history
  • Loading branch information
Maja Grubic committed Feb 23, 2023
1 parent 2a64434 commit c11b0f7
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/plugins/dashboard/public/dashboard_actions/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@ export const buildAllDashboardActions = async ({
allowByValueEmbeddables,
}: BuildAllDashboardActionsProps) => {
const { uiSettings } = core;
const { uiActions, share, presentationUtil } = plugins;
const { uiActions, share, presentationUtil, savedObjectsManagement } = plugins;

const clonePanelAction = new ClonePanelAction(core.savedObjects);
uiActions.registerAction(clonePanelAction);
uiActions.attachAction(CONTEXT_MENU_TRIGGER, clonePanelAction.id);

const SavedObjectFinder = getSavedObjectFinder(uiSettings, core.http);
const SavedObjectFinder = getSavedObjectFinder(uiSettings, core.http, savedObjectsManagement);
const changeViewAction = new ReplacePanelAction(SavedObjectFinder);
uiActions.registerAction(changeViewAction);
uiActions.attachAction(CONTEXT_MENU_TRIGGER, changeViewAction.id);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ export const providers: PluginServiceProviders<DashboardServices> = {
usageCollection: new PluginServiceProvider(usageCollectionServiceFactory),
visualizations: new PluginServiceProvider(visualizationsServiceFactory),
customBranding: new PluginServiceProvider(customBrandingServiceFactory),
savedObjectsManagement: new PluginServiceProvider(savedObjectsManagementService),
};

export const registry = new PluginServiceRegistry<DashboardServices>(providers);
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0 and the Server Side Public License, v 1; you may not use this file except
* in compliance with, at your election, the Elastic License 2.0 or the Server
* Side Public License, v 1.
*/

import { SavedObjectsManagementServiceFactory } from './saved_objects_management_service';

export const savedObjectsManagementServiceFactory: SavedObjectsManagementServiceFactory = () => {
return {
parseQuery: (query, types) => {
return {
queryText: 'some search',
};
},
getTagFindReferences: ({ selectedTags, taggingApi }) => {
return undefined;
},
};
};

0 comments on commit c11b0f7

Please sign in to comment.