import _ from 'lodash' ; import { VisualProperties } from '@/data/visuals' ; interface VisualMultiplier { size ? : number ; width ? : number ; opacity ? : number ; } /**
 * Highlight effect for selected elements. The size and width are multiplied by this factor.
 */ const selectedVisualMultiplier = { size : 1.2 , width : 1.2 } ; export const multiplyVisuals = ( visuals , multiplier = selectedVisualMultiplier ) => { if ( visuals . size !== undefined && multiplier . size !== undefined ) { visuals . size *= multiplier . size ; } if ( visuals . width !== undefined && multiplier . width !== undefined ) { visuals . width *= multiplier . width ; } if ( visuals . opacity !== undefined && multiplier . opacity !== undefined ) { visuals . opacity *= multiplier . opacity ; } } ;