From 4d574bb8aa7adf01864b12f9d9450e200b4e8e59 Mon Sep 17 00:00:00 2001 From: Uchechukwu Obasi Date: Tue, 1 Jun 2021 16:47:14 +0100 Subject: [PATCH] VizLegendTable: fixes column spacing to span to the right side (#35045) * VizLegendTable: fixes column spacing to span to the right side * reverted text alignment to right * implemented a more readable solution for tabble legend spacing --- .../grafana-ui/src/components/VizLegend/VizLegendTable.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/grafana-ui/src/components/VizLegend/VizLegendTable.tsx b/packages/grafana-ui/src/components/VizLegend/VizLegendTable.tsx index ae87bec602c..1cdd2ca5eb8 100644 --- a/packages/grafana-ui/src/components/VizLegend/VizLegendTable.tsx +++ b/packages/grafana-ui/src/components/VizLegend/VizLegendTable.tsx @@ -96,6 +96,9 @@ const getStyles = (theme: GrafanaTheme) => ({ table: css` width: 100%; margin-left: ${theme.spacing.sm}; + th:first-child { + width: 100%; + } `, header: css` color: ${theme.colors.textBlue}; @@ -103,6 +106,7 @@ const getStyles = (theme: GrafanaTheme) => ({ border-bottom: 1px solid ${theme.colors.border1}; padding: ${theme.spacing.xxs} ${theme.spacing.sm}; text-align: right; + white-space: nowrap; `, headerSortable: css` cursor: pointer;