hiCity-nft/src/views/Board/components/BoardCard/CardHeading.tsx

88 lines
2.0 KiB
TypeScript

import React from 'react'
import styled from 'styled-components'
import { Tag, Flex, Heading, Image } from '@pancakeswap/uikit'
import Question from 'components/QuestionHelper'
import { useTranslation } from 'contexts/Localization'
export interface ExpandableSectionProps {
name?: string
isCommunityFarm?: boolean
img?: string
tokenSymbol?: string
}
const Wrapper = styled(Flex)`
height: 90px;
background: linear-gradient(90deg, #f1ecf2 0%, #e9f1f5 100%);
font-size: 30px;
color: #280d5f;
padding-left: 20px;
border-radius: 32px 32px 0 0;
position: relative;
svg {
margin-right: 4px;
}
.ribbon {
width: 88px;
height: 89px;
overflow: hidden;
position: absolute;
top: 0px;
right: 0px;
}
.ribbon1 {
line-height: 12px;
text-align: center;
transform: rotate(50deg);
position: relative;
padding: 8px 0;
right: 15px;
top: 20px;
width: 150px;
background: linear-gradient(180deg, #b43ff9 0%, #7a44db 100%);
color: white;
box-shadow: 0 5px 5px rgba(0, 0, 0, 0.1);
letter-spacing: 1px;
font-size: 14px;
}
.ribbon1:before,
.ribbon1:after {
content: '';
border-top: 3px solid #4e7c7d;
border-left: 3px solid transparent;
border-right: 3px solid transparent;
position: absolute;
bottom: -4px;
}
.ribbon1:before {
left: 0;
}
.ribbon1:after {
right: 0;
}
`
const HeaderFlex = styled(Flex)``
const CardHeading: React.FC<ExpandableSectionProps> = ({ name, img, tokenSymbol }) => {
const { t } = useTranslation()
return (
<Wrapper justifyContent="space-between" alignItems="center" mb="12px">
{/* <Image src={`/images/nodes/${img}.png`} width={64} height={64} /> */}
<HeaderFlex>
<Heading mb="4px">{name}</Heading>
{/* <Question text={t('To join board, you need to stake at least 0.1% total supply of Token')} /> */}
</HeaderFlex>
{/* <div className="ribbon">
<div className="ribbon1">{t('Staked')}</div>
</div> */}
</Wrapper>
)
}
export default CardHeading