'use strict' ; import type SVGRenderer from './SVG/SVGRenderer' ; import H from '../Globals.js' ; namespace RendererRegistry { export const rendererTypes = { } ; let defaultRenderer ; param { string } rendererType return { Highcharts . Class < Highcharts . SVGRenderer > } export function getRendererType ( rendererType = defaultRenderer ) { return ( rendererTypes [ rendererType ] || rendererTypes [ defaultRenderer ] ) ; } param { string } rendererType param { Highcharts . Class < Highcharts . SVGRenderer > } rendererClass param { boolean } setAsDefault export function registerRendererType ( rendererType , rendererClass , setAsDefault ? ) { rendererTypes [ rendererType ] = rendererClass ; if ( ! defaultRenderer || setAsDefault ) { defaultRenderer = rendererType ; ( H as AnyRecord ) . Renderer = rendererClass ; } } } export default RendererRegistry ;