mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-12-25 06:28:22 +00:00
Minor: improve UI of filters in test case graph (#17775)
This commit is contained in:
parent
59854de58d
commit
d785276b8e
@ -135,6 +135,7 @@ function TestSummaryGraph({
|
||||
dataKey: info.label,
|
||||
type: 'line',
|
||||
color: info.color,
|
||||
inactive: !(activeKeys.length === 0 || activeKeys.includes(info.label)),
|
||||
}));
|
||||
|
||||
legendPayload.push({
|
||||
@ -145,7 +146,7 @@ function TestSummaryGraph({
|
||||
} as Payload);
|
||||
|
||||
return legendPayload;
|
||||
}, [chartData]);
|
||||
}, [chartData?.information, activeKeys]);
|
||||
|
||||
const handleLegendClick: LegendProps['onClick'] = (event) => {
|
||||
if (event.dataKey === 'Incident') {
|
||||
@ -226,7 +227,7 @@ function TestSummaryGraph({
|
||||
|
||||
return (
|
||||
<ResponsiveContainer
|
||||
className="bg-white"
|
||||
className="bg-white custom-test-summary-graph"
|
||||
id={`${testCaseName}_graph`}
|
||||
minHeight={minHeight ?? 400}>
|
||||
<ComposedChart
|
||||
|
||||
@ -33,3 +33,8 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.custom-test-summary-graph {
|
||||
.recharts-legend-item {
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
|
||||
@ -76,6 +76,8 @@ export const PROFILER_METRIC = [
|
||||
'customMetricsProfile',
|
||||
];
|
||||
|
||||
export const INCIDENT = 'Incident';
|
||||
|
||||
export const PROFILER_FILTER_RANGE: DateFilterType = {
|
||||
yesterday: {
|
||||
days: 1,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user