File tree Expand file tree Collapse file tree
src/plugins/visualize/public/application/components Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -33,6 +33,7 @@ import {
3333import { VisualizeServices } from '../types' ;
3434import { VisualizeEditorCommon } from './visualize_editor_common' ;
3535import { VisualizeAppProps } from '../app' ;
36+ import { VisualizeConstants } from '../..' ;
3637
3738export const VisualizeByValueEditor = ( { onAppLeave } : VisualizeAppProps ) => {
3839 const [ originatingApp , setOriginatingApp ] = useState < string > ( ) ;
@@ -52,7 +53,8 @@ export const VisualizeByValueEditor = ({ onAppLeave }: VisualizeAppProps) => {
5253 setValueInput ( valueInputValue ) ;
5354 setEmbeddableId ( embeddableIdValue ) ;
5455 if ( ! valueInputValue ) {
55- history . back ( ) ;
56+ // if there is no value input to load, redirect to the visualize listing page.
57+ services . history . replace ( VisualizeConstants . LANDING_PAGE_PATH ) ;
5658 }
5759 } , [ services ] ) ;
5860
You can’t perform that action at this time.
0 commit comments