feat: add dropdown component

This commit is contained in:
Sonny
2024-05-12 20:06:05 +02:00
committed by Sonny
parent 3531038321
commit 0f1dc9b69c
13 changed files with 142 additions and 16 deletions

View File

@@ -0,0 +1,17 @@
import styled from '@emotion/styled';
const DropdownContainer = styled.div<{ show: boolean }>(({ show, theme }) => ({
position: 'absolute',
top: 'calc(100% + 0.5em)',
right: 0,
minWidth: '175px',
backgroundColor: show ? theme.colors.secondary : theme.colors.background,
border: `2px solid ${theme.colors.secondary}`,
borderRadius: theme.border.radius,
boxShadow: theme.colors.boxShadow,
display: show ? 'flex' : 'none',
flexDirection: 'column',
overflow: 'hidden',
}));
export default DropdownContainer;