From 56898af16daca377855d8a9e3f76cd19568cf874 Mon Sep 17 00:00:00 2001 From: jihea-park Date: Tue, 8 Oct 2024 14:02:53 +0900 Subject: [PATCH] [#10776] Make "ALL" bold & Remove total if stack is false --- .../charts/OpenTelemetryChartCommon.tsx | 2 +- .../charts/OpenTelemetryMetricFetcher.tsx | 4 ++-- .../definition/MeticDefinitionFormFetcher.tsx | 2 +- .../v3/packages/ui/src/components/ui/chart.tsx | 15 ++++----------- 4 files changed, 8 insertions(+), 15 deletions(-) diff --git a/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryChartCommon.tsx b/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryChartCommon.tsx index 4f195b48c99d..f67aa7a3459a 100644 --- a/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryChartCommon.tsx +++ b/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryChartCommon.tsx @@ -53,7 +53,7 @@ export const OpenTelemetryChartCommon = ({ } {...restTooltipConfig} /> - } /> + } /> ); }; diff --git a/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryMetricFetcher.tsx b/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryMetricFetcher.tsx index 12b989fa8aa0..45c034e9c833 100644 --- a/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryMetricFetcher.tsx +++ b/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/charts/OpenTelemetryMetricFetcher.tsx @@ -45,7 +45,7 @@ export const OpenTelemetryMetricFetcher = ({ }); }, [metricDefinition]); - const { stack, showTotal = true } = metricDefinition; + const { stack, showTotal = false } = metricDefinition; const dataSets = data?.metricValues.reduce( @@ -101,7 +101,7 @@ export const OpenTelemetryMetricFetcher = ({ }, }} tooltipConfig={{ - showTotal, + showTotal: showTotal || stack, }} /> ) diff --git a/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/definition/MeticDefinitionFormFetcher.tsx b/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/definition/MeticDefinitionFormFetcher.tsx index 4c47d0727134..80bc607080f1 100644 --- a/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/definition/MeticDefinitionFormFetcher.tsx +++ b/web-frontend/src/main/v3/packages/ui/src/components/OpenTelemetry/definition/MeticDefinitionFormFetcher.tsx @@ -508,7 +508,7 @@ export const MetricDefinitionFormFetcher = ({ }} /> - ALL{' '} + ALL {`(Select all ${primaryForFieldAndTagRelation === 'tag' ? 'field' : 'tag'})`} diff --git a/web-frontend/src/main/v3/packages/ui/src/components/ui/chart.tsx b/web-frontend/src/main/v3/packages/ui/src/components/ui/chart.tsx index 1f8631ac27e9..26b0a3968b41 100644 --- a/web-frontend/src/main/v3/packages/ui/src/components/ui/chart.tsx +++ b/web-frontend/src/main/v3/packages/ui/src/components/ui/chart.tsx @@ -261,8 +261,7 @@ const ChartLegendContent = React.forwardRef<
@@ -273,13 +272,7 @@ const ChartLegendContent = React.forwardRef< return ( -
svg]:h-3 [&>svg]:w-3 [&>svg]:text-muted-foreground', - 'justify-center', - )} - > +
<> {itemConfig?.icon && !hideIcon ? ( @@ -291,9 +284,9 @@ const ChartLegendContent = React.forwardRef< }} /> )} - +
{itemConfig?.label} - +