-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Visualize] Deangularize and typescriptify saved_object usage (#52984)
- Loading branch information
Showing
17 changed files
with
339 additions
and
296 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
src/legacy/core_plugins/kibana/public/discover/saved_searches/saved_searches_register.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
/* | ||
* Licensed to Elasticsearch B.V. under one or more contributor | ||
* license agreements. See the NOTICE file distributed with | ||
* this work for additional information regarding copyright | ||
* ownership. Elasticsearch B.V. licenses this file to you under | ||
* the Apache License, Version 2.0 (the "License"); you may | ||
* not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, | ||
* software distributed under the License is distributed on an | ||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
* KIND, either express or implied. See the License for the | ||
* specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
import { npStart } from 'ui/new_platform'; | ||
// @ts-ignore | ||
import { uiModules } from 'ui/modules'; | ||
// @ts-ignore | ||
import { savedObjectManagementRegistry } from '../../management/saved_object_registry'; | ||
|
||
import { createSavedSearchesService } from './saved_searches'; | ||
|
||
// this is needed for saved object management | ||
// Register this service with the saved object registry so it can be | ||
// edited by the object editor. | ||
savedObjectManagementRegistry.register({ | ||
service: 'savedSearches', | ||
title: 'searches', | ||
}); | ||
const module = uiModules.get('discover/saved_searches'); | ||
module.service('savedSearches', () => { | ||
const services = { | ||
savedObjectsClient: npStart.core.savedObjects.client, | ||
indexPatterns: npStart.plugins.data.indexPatterns, | ||
chrome: npStart.core.chrome, | ||
overlays: npStart.core.overlays, | ||
}; | ||
return createSavedSearchesService(services); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
150 changes: 0 additions & 150 deletions
150
src/legacy/core_plugins/kibana/public/visualize/saved_visualizations/_saved_vis.js
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.