Skip to content

Commit

Permalink
Improve styling
Browse files Browse the repository at this point in the history
  • Loading branch information
geido committed Feb 22, 2022
1 parent dd3143f commit a3af166
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
8 changes: 2 additions & 6 deletions superset-frontend/plugins/plugin-chart-table/src/Styles.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,14 @@ export default styled.div`
}
thead > tr > th {
padding-right: 1.4em;
padding-right: 0;
position: relative;
background: ${({ theme: { colors } }) => colors.grayscale.light5};
text-align: left;
}
th svg {
color: ${({ theme: { colors } }) => colors.grayscale.light2};
position: absolute;
vertical-align: middle;
top: ${({ theme: { gridUnit } }) => gridUnit * 2}px;
margin: 0 ${({ theme: { gridUnit } }) => gridUnit}px;
right: 0;
margin: ${({ theme: { gridUnit } }) => gridUnit / 2}px;
}
th.is-sorted svg {
color: ${({ theme: { colors } }) => colors.grayscale.base};
Expand Down
11 changes: 9 additions & 2 deletions superset-frontend/plugins/plugin-chart-table/src/TableChart.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -430,8 +430,15 @@ export default function TableChart<D extends DataRecord = DataRecord>(
}}
/>
) : null}
{label}
<SortIcon column={col} />
<div
css={{
display: 'inline-flex',
alignItems: 'center',
}}
>
<span>{label}</span>
<SortIcon column={col} />
</div>
</th>
),
Footer: totals ? (
Expand Down

0 comments on commit a3af166

Please sign in to comment.