From bf43c77f5b9e4d8eb9a9690a26d5a6ad00c05c18 Mon Sep 17 00:00:00 2001 From: "opensearch-trigger-bot[bot]" <98922864+opensearch-trigger-bot[bot]@users.noreply.github.com> Date: Thu, 20 Oct 2022 12:06:28 -0700 Subject: [PATCH] [Vis Builder] Update vislib params and misc fixes (#2610) (#2630) * Updates bar, line, area visbuilder config Signed-off-by: Ashwin P Chandran * Misc fixes from functional testing Signed-off-by: Ashwin P Chandran * Adds Changelog entry Signed-off-by: Ashwin P Chandran Signed-off-by: Ashwin P Chandran (cherry picked from commit 33aed0a6bdba070a37bc3002f4a86a81a0150677) --- CHANGELOG.md | 1 + .../components/visualize_listing.tsx | 4 +++- .../embeddable/disabled_visualization.tsx | 2 +- .../public/embeddable/wizard_embeddable.tsx | 4 ++++ .../embeddable/wizard_embeddable_factory.tsx | 3 --- .../vislib/area/area_vis_type.ts | 22 +++++++++++++++++++ .../vislib/histogram/histogram_vis_type.ts | 22 +++++++++++++++++++ .../vislib/line/line_vis_type.ts | 22 +++++++++++++++++++ 8 files changed, 75 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 39946e843f0e..f0823c12d8bb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -28,6 +28,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) * [Vis Builder] Fixes auto bounds for timeseries bar chart visualization ([2401](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2401)) * [Vis Builder] Fixes visualization shift when editing agg ([2401](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2401)) * [Vis Builder] Renames "Histogram" to "Bar" in vis type picker ([2401](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2401)) +* [Vis Builder] Update vislib params and misc fixes ([2610](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2610)) * [MD] Add data source param to low-level search call in Discover ([#2431](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2431)) * [Multi DataSource] Skip data source view in index pattern step when pick default ([#2574](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/2574)) diff --git a/src/plugins/visualize/public/application/components/visualize_listing.tsx b/src/plugins/visualize/public/application/components/visualize_listing.tsx index 767793efa2d8..46db44bb066d 100644 --- a/src/plugins/visualize/public/application/components/visualize_listing.tsx +++ b/src/plugins/visualize/public/application/components/visualize_listing.tsx @@ -123,7 +123,9 @@ export const VisualizeListing = () => { .then(({ total, hits }: { total: number; hits: object[] }) => ({ total, hits: hits.filter( - (result: any) => isLabsEnabled || result.type?.stage !== 'experimental' + (result: any) => + isLabsEnabled || + (result.type?.stage !== 'experimental' && result.stage !== 'experimental') ), })); }, diff --git a/src/plugins/wizard/public/embeddable/disabled_visualization.tsx b/src/plugins/wizard/public/embeddable/disabled_visualization.tsx index 7391589dd01d..be6072c105af 100644 --- a/src/plugins/wizard/public/embeddable/disabled_visualization.tsx +++ b/src/plugins/wizard/public/embeddable/disabled_visualization.tsx @@ -11,7 +11,7 @@ import './disabled_visualization.scss'; export function DisabledVisualization({ title }: { title: string }) { return ( -
+
{ try { const savedWizard = await getSavedWizardLoader().get(savedObjectId); - const editPath = `${EDIT_PATH}/${savedObjectId}`; - const editUrl = getHttp().basePath.prepend(`/app/${PLUGIN_ID}${editPath}`); - const isLabsEnabled = getUISettings().get(VISUALIZE_ENABLE_LABS_SETTING); if (!isLabsEnabled) { diff --git a/src/plugins/wizard/public/visualizations/vislib/area/area_vis_type.ts b/src/plugins/wizard/public/visualizations/vislib/area/area_vis_type.ts index 14b524bf008f..5a42492e862e 100644 --- a/src/plugins/wizard/public/visualizations/vislib/area/area_vis_type.ts +++ b/src/plugins/wizard/public/visualizations/vislib/area/area_vis_type.ts @@ -46,6 +46,28 @@ export const createAreaConfig = (): VisualizationTypeOptions