mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
GraphNG: Do not set fillColor from GraphNG only opacity (#29851)
* GraphNG: Do not set fillColor from GraphNG only opacity * use color settings if they exist Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
This commit is contained in:
parent
f3694935ed
commit
4e1cab1e69
@ -157,14 +157,13 @@ export const GraphNG: React.FC<GraphNGProps> = ({
|
||||
builder.addSeries({
|
||||
scaleKey,
|
||||
drawStyle: customConfig.drawStyle!,
|
||||
lineColor: seriesColor,
|
||||
lineColor: customConfig.lineColor ?? seriesColor,
|
||||
lineWidth: customConfig.lineWidth,
|
||||
lineInterpolation: customConfig.lineInterpolation,
|
||||
showPoints,
|
||||
pointSize: customConfig.pointSize,
|
||||
pointColor: seriesColor,
|
||||
pointColor: customConfig.pointColor ?? seriesColor,
|
||||
fillOpacity: customConfig.fillOpacity,
|
||||
fillColor: seriesColor,
|
||||
spanNulls: customConfig.spanNulls || false,
|
||||
});
|
||||
|
||||
|
@ -81,9 +81,11 @@ export class UPlotSeriesBuilder extends PlotConfigBuilder<SeriesProps, Series> {
|
||||
}
|
||||
|
||||
if (fillOpacityNumber !== 0) {
|
||||
fillConfig.fill = tinycolor(fillColor ?? lineColor)
|
||||
.setAlpha(fillOpacityNumber / 100)
|
||||
.toRgbString();
|
||||
fillConfig = {
|
||||
fill: tinycolor(fillColor ?? lineColor)
|
||||
.setAlpha(fillOpacityNumber / 100)
|
||||
.toRgbString(),
|
||||
};
|
||||
}
|
||||
|
||||
return {
|
||||
|
Loading…
Reference in New Issue
Block a user