From b59a4fc5b889d32ae0a4baa6e6130cd0cb03ca2c Mon Sep 17 00:00:00 2001 From: Alex Spencer <52186778+alexjonspencer1@users.noreply.github.com> Date: Wed, 9 Apr 2025 09:23:47 -0600 Subject: [PATCH] TableNG: Fix some regressions after text wrap refactor (#103663) Co-authored-by: Leon Sorokin --- .../src/components/Table/TableNG/Cells/TableCellNG.tsx | 1 + packages/grafana-ui/src/components/Table/TableNG/TableNG.tsx | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/grafana-ui/src/components/Table/TableNG/Cells/TableCellNG.tsx b/packages/grafana-ui/src/components/Table/TableNG/Cells/TableCellNG.tsx index ddb099849b0..3e3138e55ef 100644 --- a/packages/grafana-ui/src/components/Table/TableNG/Cells/TableCellNG.tsx +++ b/packages/grafana-ui/src/components/Table/TableNG/Cells/TableCellNG.tsx @@ -237,6 +237,7 @@ const getStyles = (theme: GrafanaTheme2, isRightAligned: boolean, color: CellCol // TODO: follow-up on this: change styles on hover on table row level background: color.bgColor || 'none', color: color.textColor, + '&:hover': { background: color.bgHoverColor }, }), cellActions: css({ display: 'flex', diff --git a/packages/grafana-ui/src/components/Table/TableNG/TableNG.tsx b/packages/grafana-ui/src/components/Table/TableNG/TableNG.tsx index ec39b7ef8a4..446c5023645 100644 --- a/packages/grafana-ui/src/components/Table/TableNG/TableNG.tsx +++ b/packages/grafana-ui/src/components/Table/TableNG/TableNG.tsx @@ -860,7 +860,7 @@ export function mapFrameToDataGrid({ showTypeIcons={showTypeIcons} /> ), - width: fieldTableOptions.width ?? COLUMN.DEFAULT_WIDTH, + width: fieldTableOptions.width, minWidth: fieldTableOptions.minWidth || COLUMN.DEFAULT_WIDTH, }); });