Fix RecordTableHeaderCell (#6383)
@Bonapara Fixed! the issue (#6365) where the `background-color` style was not set, causing the bug. Now, the background color is properly applied. https://github.com/user-attachments/assets/668bd3cc-77ea-42a9-84d4-071fca497e07
This commit is contained in:
@ -4,18 +4,25 @@ import { useRecoilValue } from 'recoil';
|
|||||||
import { useRecordTableStates } from '@/object-record/record-table/hooks/internal/useRecordTableStates';
|
import { useRecordTableStates } from '@/object-record/record-table/hooks/internal/useRecordTableStates';
|
||||||
import { useRecordTable } from '@/object-record/record-table/hooks/useRecordTable';
|
import { useRecordTable } from '@/object-record/record-table/hooks/useRecordTable';
|
||||||
import { Checkbox } from '@/ui/input/components/Checkbox';
|
import { Checkbox } from '@/ui/input/components/Checkbox';
|
||||||
import { useTheme } from '@emotion/react';
|
|
||||||
|
|
||||||
const StyledContainer = styled.div`
|
const StyledContainer = styled.div`
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
height: 32px;
|
height: 32px;
|
||||||
|
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
background-color: ${({ theme }) => theme.background.primary};
|
background-color: ${({ theme }) => theme.background.primary};
|
||||||
`;
|
`;
|
||||||
|
|
||||||
|
const StyledColumnHeaderCell = styled.th`
|
||||||
|
background-color: ${({ theme }) => theme.background.primary};
|
||||||
|
border-bottom: 1px solid ${({ theme }) => theme.border.color.light};
|
||||||
|
border-right: transparent;
|
||||||
|
border-top: 1px solid ${({ theme }) => theme.border.color.light};
|
||||||
|
max-width: 30px;
|
||||||
|
min-width: 30px;
|
||||||
|
width: 30px;
|
||||||
|
`;
|
||||||
|
|
||||||
export const RecordTableHeaderCheckboxColumn = () => {
|
export const RecordTableHeaderCheckboxColumn = () => {
|
||||||
const { allRowsSelectedStatusSelector } = useRecordTableStates();
|
const { allRowsSelectedStatusSelector } = useRecordTableStates();
|
||||||
|
|
||||||
@ -36,19 +43,8 @@ export const RecordTableHeaderCheckboxColumn = () => {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const theme = useTheme();
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<th
|
<StyledColumnHeaderCell>
|
||||||
style={{
|
|
||||||
borderBottom: `1px solid ${theme.border.color.light}`,
|
|
||||||
borderTop: `1px solid ${theme.border.color.light}`,
|
|
||||||
width: 30,
|
|
||||||
minWidth: 30,
|
|
||||||
maxWidth: 30,
|
|
||||||
borderRight: 'transparent',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<StyledContainer>
|
<StyledContainer>
|
||||||
<Checkbox
|
<Checkbox
|
||||||
checked={checked}
|
checked={checked}
|
||||||
@ -56,6 +52,6 @@ export const RecordTableHeaderCheckboxColumn = () => {
|
|||||||
indeterminate={indeterminate}
|
indeterminate={indeterminate}
|
||||||
/>
|
/>
|
||||||
</StyledContainer>
|
</StyledContainer>
|
||||||
</th>
|
</StyledColumnHeaderCell>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user