Skip to content

Commit

Permalink
fix(PR): use color from theme and fix story
Browse files Browse the repository at this point in the history
  • Loading branch information
alexelie120 committed Jan 29, 2024
1 parent 43992e8 commit 605ccd7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion packages/react/src/components/table/table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ function getRenderedColumns<T extends object>(rowNumbers: boolean, columns: Tabl
}

const StyledTable = styled.table<StyledTableProps>`
background: white;
background: ${({ theme }) => theme.greys.white};;
border-collapse: collapse;
color: ${({ theme }) => theme.greys['neutral-90']};
width: 100%;
Expand Down
9 changes: 4 additions & 5 deletions packages/storybook/stories/table.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1089,6 +1089,9 @@ export const StickyHeaderAndFooter: Story = () => {
);
};

const StyledTableWithBackground = styled(Table<StickyFooterData>)`
background: #a9cad8;
`;
export const WithBackgroundColor: Story = () => {
const columns: TableColumn<StickyFooterData> = [
{
Expand Down Expand Up @@ -1212,13 +1215,9 @@ export const WithBackgroundColor: Story = () => {
},
];

const StyleTable = styled(Table<StickyFooterData>)`
background: #a9cad8;
`;

return (
<Wrap>
<StyleTable
<StyledTableWithBackground
selectableRows
stickyHeader
stickyFooter
Expand Down

0 comments on commit 605ccd7

Please sign in to comment.