import { colorToRgba , OpacityFn , overrideOpacity } from '../../../common/color_library_wrappers' ; import { getColorFromVariant , mergePartial } from '../../../utils/common' ; import { PointGeometryStyle } from '../../../utils/geometry' ; import { PointShape , PointStyle } from '../../../utils/themes/theme' ; internal export function buildPointGeometryStyles ( color , themePointStyle , overrides ? ) { const pointStyle = mergePartial ( themePointStyle , overrides ) ; const opacityFn = ( opacity ) => opacity * pointStyle . opacity ; return { fill : { color : overrideOpacity ( colorToRgba ( getColorFromVariant ( color , pointStyle . fill ) ) , opacityFn ) } , stroke : { color : overrideOpacity ( colorToRgba ( getColorFromVariant ( color , pointStyle . stroke ) ) , opacityFn ) , width : pointStyle . strokeWidth , } , shape : pointStyle . shape ?? PointShape . Circle , } ; }