Skip to content

Commit

Permalink
fix(pivot-table): use a scoped base selector and global sub selectors
Browse files Browse the repository at this point in the history
  • Loading branch information
HendrikThePendric committed Jun 19, 2024
1 parent 7e89545 commit dff1165
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions src/components/PivotTable/styles/PivotTable.style.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ import {
FONT_SIZE_LARGE,
} from '../../../modules/pivotTable/pivotTableConstants.js'

export const table = css.global`
export const table = css`
div.pivot-table-container {
font-family: 'Roboto', Arial, sans-serif;
overflow: auto;
color: ${colors.grey900};
}
table {
div.pivot-table-container :global(table) {
border-spacing: 0;
white-space: nowrap;
box-sizing: border-box;
Expand All @@ -26,35 +26,37 @@ export const table = css.global`
border-width: 1px 1px 0 0;
}
table.fixed-headers {
div.pivot-table-container :global(table.fixed-headers) {
border-width: 0 0 0 1px;
}
table.fixed-headers tr th,
table.fixed-headers tr td {
div.pivot-table-container :global(table.fixed-headers tr th),
div.pivot-table-container :global(table.fixed-headers tr td) {
border-width: 0 1px 1px 0;
}
table.fixed-column-headers {
div.pivot-table-container :global(table.fixed-column-headers) {
border-width: 0 1px 0 0;
}
table.fixed-column-headers tr th,
table.fixed-column-headers tr td {
div.pivot-table-container :global(table.fixed-column-headers tr th),
div.pivot-table-container :global(table.fixed-column-headers tr td) {
border-width: 0 0 1px 1px;
}
table.fixed-headers thead tr:first-of-type th,
table.fixed-column-headers thead tr:first-of-type th {
div.pivot-table-container
:global(table.fixed-headers thead tr:first-of-type th),
div.pivot-table-container
:global(table.fixed-column-headers thead tr:first-of-type th) {
border-top: 1px solid ${BORDER_COLOR};
}
table.fixed-row-headers {
div.pivot-table-container :global(table.fixed-row-headers) {
border-width: 0 0 1px 1px;
}
table.fixed-row-headers tr th,
table.fixed-row-headers tr td {
div.pivot-table-container :global(table.fixed-row-headers tr th),
div.pivot-table-container :global(table.fixed-row-headers tr td) {
border-width: 1px 1px 0 0;
}
`
Expand Down

0 comments on commit dff1165

Please sign in to comment.