Table: Tweak to type icon styles (#40596) (#40598)

(cherry picked from commit d179c2a4e9)

Co-authored-by: Torkel Ödegaard <torkel@grafana.org>
This commit is contained in:
Grot (@grafanabot)
2021-10-19 09:26:06 +02:00
committed by GitHub
co-authored by Torkel Ödegaard
parent 41a9638df7
commit 01ffb3852c
2 changed files with 5 additions and 1 deletions
@@ -61,7 +61,7 @@ function renderHeaderCell(column: any, tableStyles: TableStyles, field?: Field,
title={column.render('Header')}
>
{showTypeIcons && (
<Icon name={getFieldTypeIcon(field)} title={field?.type} size="sm" style={{ marginRight: '8px' }} />
<Icon name={getFieldTypeIcon(field)} title={field?.type} size="sm" className={tableStyles.typeIcon} />
)}
<div>{column.render('Header')}</div>
<div>
@@ -170,6 +170,10 @@ export const getTableStyles = (theme: GrafanaTheme2) => {
cursor: pointer;
padding: 0 ${theme.spacing(0.025)};
`,
typeIcon: css`
margin-right: ${theme.spacing(1)};
color: ${theme.colors.text.secondary};
`,
noData: css`
align-items: center;
display: flex;