Create OsCard.tsx

This commit is contained in:
Hristo Nedelkov 2023-09-11 09:53:51 +03:00
parent 4f868791fd
commit 19e4470a10

View File

@ -0,0 +1,36 @@
import { Stack, YStack } from 'tamagui'
import { Text } from '@status-im/components'
import Icon from '../../../../components/General/Icon'
type OsCardProps = {
name: string
icon: string
onClick?: () => void
isSelected?: boolean
}
const OsCard = ({ name, icon, onClick, isSelected }: OsCardProps) => {
return (
<YStack
style={{
backgroundColor: isSelected ? '#2A4AF50D' : 'none',
border: isSelected ? '1px solid #2A4AF566' : '1px solid rgba(0, 0, 0, 0.15);',
borderRadius: '16px',
padding: '12px 16px',
width: '33%',
}}
space={'$12'}
onPress={onClick}
>
<Stack>
<Text size={27} weight={'semibold'}>
{name}
</Text>
</Stack>
<Icon src={icon} width={100} height={100} />
</YStack>
)
}
export default OsCard