Feat: First column style update (#1746)

reimplemented as per suggestions by lucas
This commit is contained in:
Ayush Agrawal
2023-10-04 13:55:43 +05:30
committed by GitHub
parent 5915189a5b
commit 3336144245
17 changed files with 148 additions and 47 deletions

View File

@ -0,0 +1,26 @@
import styled from '@emotion/styled';
import { motion } from 'framer-motion';
import { FloatingIconButton } from '@/ui/button/components/FloatingIconButton';
import { IconComponent } from '@/ui/icon/types/IconComponent';
const StyledEditButtonContainer = styled(motion.div)`
position: absolute;
right: 5px;
`;
type TableCellButtonProps = {
onClick?: () => void;
Icon: IconComponent;
};
export const TableCellButton = ({ onClick, Icon }: TableCellButtonProps) => (
<StyledEditButtonContainer
initial={{ opacity: 0 }}
animate={{ opacity: 1 }}
transition={{ duration: 0.1 }}
whileHover={{ scale: 1.04 }}
>
<FloatingIconButton size="small" onClick={onClick} Icon={Icon} />
</StyledEditButtonContainer>
);