mirror of
https://github.com/router-for-me/Cli-Proxy-API-Management-Center.git
synced 2026-02-03 03:10:50 +08:00
fix(usage): prevent gaps in request trend fill by matching point colors
This commit is contained in:
@@ -638,6 +638,8 @@ export interface ChartDataset {
|
|||||||
data: number[];
|
data: number[];
|
||||||
borderColor: string;
|
borderColor: string;
|
||||||
backgroundColor: string | CanvasGradient | ((context: ScriptableContext<'line'>) => string | CanvasGradient);
|
backgroundColor: string | CanvasGradient | ((context: ScriptableContext<'line'>) => string | CanvasGradient);
|
||||||
|
pointBackgroundColor?: string;
|
||||||
|
pointBorderColor?: string;
|
||||||
fill: boolean;
|
fill: boolean;
|
||||||
tension: number;
|
tension: number;
|
||||||
}
|
}
|
||||||
@@ -743,6 +745,8 @@ export function buildChartData(
|
|||||||
backgroundColor: shouldFill
|
backgroundColor: shouldFill
|
||||||
? (ctx) => buildAreaGradient(ctx, style.borderColor, style.backgroundColor)
|
? (ctx) => buildAreaGradient(ctx, style.borderColor, style.backgroundColor)
|
||||||
: style.backgroundColor,
|
: style.backgroundColor,
|
||||||
|
pointBackgroundColor: style.borderColor,
|
||||||
|
pointBorderColor: style.borderColor,
|
||||||
fill: shouldFill,
|
fill: shouldFill,
|
||||||
tension: 0.35
|
tension: 0.35
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user