Skip to content

Commit

Permalink
fix: wider clickable area in collapsible table row
Browse files Browse the repository at this point in the history
  • Loading branch information
mdeliatf authored Jan 25, 2024
1 parent 9fe8d3e commit ab4860c
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions components/Table/Table.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -217,16 +217,25 @@ export const Tr = forwardRef<ElementRef<typeof StyledTr>, TrProps>(
>
{emptyFirstColumn ? tableHead ? <Th css={{ width: 24 }} /> : <Td /> : null}
{!!collapsedContent && (
<Td>
<Td
css={{ padding: '0 0 0 $3' }}
onClick={(e) => {
e.stopPropagation();
e.preventDefault();
}}
>
<Flex
align="center"
onClick={(e) => {
e.stopPropagation();
e.preventDefault();
justify="center"
css={{
height: '40px',
'&:hover': {
color: '$tableActiveText',
},
}}
onClick={() => setIsCollapsed(!isCollapsed)}
>
<ChevronRightIcon
onClick={() => setIsCollapsed(!isCollapsed)}
style={{
cursor: 'pointer',
transition: 'transform 0.2s ease-out',
Expand Down

0 comments on commit ab4860c

Please sign in to comment.