import { createCustomCachedSelector } from '../../../../state/create_selector' ; import { SeriesType } from '../../utils/specs' ; import { getSeriesSpecsSelector } from './get_specs' ; internal export const getChartTypeDescriptionSelector = createCustomCachedSelector ( [ getSeriesSpecsSelector ] , ( specs ) : string => { const seriesTypes = new Set < SeriesType > ( ) ; specs . forEach ( ( value ) => seriesTypes . add ( value . seriesType ) ) ; return seriesTypes . size > 1 ? `Mixed chart: ${ [ ... seriesTypes ] . join ( ' and ' ) } chart` : `${ [ ... seriesTypes ] } chart` ; } ) ;