Skip to content

Commit bd16e39

Browse files
committed
Finalize plugin-id and plugin-name and saved-object-type
Signed-off-by: abbyhu2000 <abigailhu2000@gmail.com>
1 parent 55d8170 commit bd16e39

File tree

12 files changed

+12
-18
lines changed

12 files changed

+12
-18
lines changed

CHANGELOG.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
1212

1313
### 📈 Features/Enhancements
1414

15-
<<<<<<< HEAD
1615
- [MD] Support legacy client for data source ([#2204](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2204))
1716
- [MD] Add data source signing support ([#2510](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2510))
1817
- [Plugin Helpers] Facilitate version changes ([#2398](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2398))
@@ -31,11 +30,8 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
3130
- [Multi DataSource] Address UX comments on Data source list and create page ([#2625](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2625))
3231
- [Vis Builder] Rename wizard to visBuilder in i18n id and formatted message id ([#2635](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2635))
3332
- [Vis Builder] Rename wizard to visBuilder in class name, type name and function name ([#2639](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2639))
34-
<<<<<<< HEAD
3533
- [Vis Builder] Rename wizard on save modal and visualization table ([#2645](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2645))
36-
=======
3734
- Change save object type, wizard id and name to visBuilder #2673 ([#2673](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2673))
38-
>>>>>>> Rename wizard in functional tests
3935

4036
### 🐛 Bug Fixes
4137

config/opensearch_dashboards.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@
222222

223223
# Set the value of this setting to true to start exploring wizard
224224
# functionality in Visualization.
225-
# visBuilder.enabled: false
225+
# vis_builder.enabled: false
226226

227227
# Set the value of this setting to true to enable the experimental multiple data source
228228
# support feature. Use with caution.

src/plugins/vis_builder/common/index.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
export const PLUGIN_ID = 'visBuilder';
6+
export const PLUGIN_ID = 'vis-builder';
77
export const PLUGIN_NAME = 'Visualization Builder';
88
export const VISUALIZE_ID = 'visualize';
9-
export const VIS_BUILDER_TYPE_SHORTHAND = 'VisBuilder';
109
export const EDIT_PATH = '/edit';
1110
export const VIS_BUILDER_CHART_TYPE = 'VisBuilder';
1211

src/plugins/vis_builder/common/vis_builder_saved_object_attributes.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
import { SavedObjectAttributes } from '../../../core/types';
77

8-
export const VISBUILDER_SAVED_OBJECT = 'visBuilder';
8+
export const VISBUILDER_SAVED_OBJECT = 'visualization-visbuilder';
99

1010
export interface VisBuilderSavedObjectAttributes extends SavedObjectAttributes {
1111
title: string;

src/plugins/vis_builder/opensearch_dashboards.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
{
22
"id": "visBuilder",
3-
"configPath": "visBuilder",
43
"version": "1.0.0",
54
"opensearchDashboardsVersion": "opensearchDashboards",
65
"server": true,

src/plugins/vis_builder/public/application/utils/get_top_nav_config.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ import {
3939
import { VisBuilderServices } from '../..';
4040
import { VisBuilderVisSavedObject } from '../../types';
4141
import { AppDispatch } from './state_management';
42-
import { EDIT_PATH } from '../../../common';
42+
import { EDIT_PATH, VISBUILDER_SAVED_OBJECT } from '../../../common';
4343
import { setEditorState } from './state_management/metadata_slice';
4444
export interface TopNavConfigParams {
4545
visualizationIdFromUrl: string;
@@ -207,7 +207,7 @@ export const getOnSave = (
207207
if (newlyCreated && stateTransfer) {
208208
// create new embeddable to transfer to originatingApp
209209
stateTransfer.navigateToWithEmbeddablePackage(originatingApp, {
210-
state: { type: 'visBuilder', input: { savedObjectId: id } },
210+
state: { type: VISBUILDER_SAVED_OBJECT, input: { savedObjectId: id } },
211211
});
212212
return { id };
213213
} else {

src/plugins/vis_builder/public/plugin.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ export class VisBuilderPlugin
130130
aliasPath: '#/',
131131
appExtensions: {
132132
visualizations: {
133-
docTypes: [PLUGIN_ID],
133+
docTypes: [VISBUILDER_SAVED_OBJECT],
134134
toListItem: ({ id, attributes, updated_at: updatedAt }) => ({
135135
description: attributes?.description,
136136
editApp: PLUGIN_ID,

src/plugins/vis_builder/server/capabilities_provider.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*/
55

66
export const capabilitiesProvider = () => ({
7-
visBuilder: {
7+
'visualization-visbuilder': {
88
// TODO: investigate which capabilities we need to provide
99
// createNew: true,
1010
// createShortUrl: true,

src/plugins/vis_builder/server/plugin.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export class VisBuilderPlugin implements Plugin<VisBuilderPluginSetup, VisBuilde
2323
}
2424

2525
public setup({ capabilities, http, savedObjects }: CoreSetup) {
26-
this.logger.debug('visBuilder: Setup');
26+
this.logger.debug('vis-builder: Setup');
2727

2828
// Register saved object types
2929
savedObjects.registerType(visBuilderSavedObjectType);
@@ -35,7 +35,7 @@ export class VisBuilderPlugin implements Plugin<VisBuilderPluginSetup, VisBuilde
3535
}
3636

3737
public start(_core: CoreStart) {
38-
this.logger.debug('visBuilder: Started');
38+
this.logger.debug('vis-builder: Started');
3939
return {};
4040
}
4141

src/plugins/vis_builder/server/saved_objects/vis_builder_app.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ export const visBuilderSavedObjectType: SavedObjectsType = {
2626
getInAppUrl({ id }: SavedObject) {
2727
return {
2828
path: `/app/${PLUGIN_ID}${EDIT_PATH}/${encodeURIComponent(id)}`,
29-
uiCapabilitiesPath: 'visBuilder.show',
29+
uiCapabilitiesPath: 'visualization-visbuilder.show',
3030
};
3131
},
3232
},

0 commit comments

Comments
 (0)