feat: bugfixing

This commit is contained in:
Nazareno Oviedo 2022-04-11 14:00:01 -03:00
parent 197d7a9e4e
commit dfc29a740c
3 changed files with 37 additions and 31 deletions

View File

@ -5,6 +5,7 @@
flex-direction: column;
width: 100%;
padding-bottom: tovw(2px, 'default', 2px);
cursor: pointer;
&-blog {
.content {

View File

@ -1,4 +1,5 @@
import clsx from 'clsx'
import NextLink from 'next/link'
import { Calendar, Clock } from '~/components/icons/events'
import Heading from '~/components/primitives/heading'
@ -18,40 +19,44 @@ interface CardProps {
const Card = ({ className, data, isNews = false }: CardProps) => {
return (
<div className={clsx(s['card'], className)}>
<div className={s['card__header']}>
{!isNews && (
<span className={s.location}>{data?.location?.toUpperCase()}</span>
)}
<div className={isNews ? s.is_news : ''}>
{isNews && (
<span className={s.author}>
BY <span className={s.separator}></span> {data?.author}
</span>
)}
<span className={s.date}>
{!isNews && <Calendar />}
{data?.date}
</span>
<NextLink href={data.link}>
<div className={clsx(s['card'], className)}>
<div className={s['card__header']}>
{!isNews && (
<span className={s.hour}>
<Clock />
{data?.time} HS
</span>
<span className={s.location}>{data?.location?.toUpperCase()}</span>
)}
<div className={isNews ? s.is_news : ''}>
{isNews && (
<span className={s.author}>
BY <span className={s.separator}></span> {data?.author}
</span>
)}
<span className={s.date}>
{!isNews && <Calendar />}
{data?.date}
</span>
{!isNews && (
<span className={s.hour}>
<Clock />
{data?.time} HS
</span>
)}
</div>
</div>
<div className={s['image__container']}>
<img alt={data?.title} loading="lazy" src={data?.imgSrc} />
</div>
<div className={s['content']}>
<Heading as="h2" variant="sm" font="tthoves">
{data?.title}
</Heading>
<p>{data?.preview}</p>
<Link href={data?.link}>
{isNews ? 'READ ARTICLE' : 'LEARN MORE'}
</Link>
</div>
</div>
<div className={s['image__container']}>
<img alt={data?.title} loading="lazy" src={data?.imgSrc} />
</div>
<div className={s['content']}>
<Heading as="h2" variant="sm" font="tthoves">
{data?.title}
</Heading>
<p>{data?.preview}</p>
<Link href={data?.link}>{isNews ? 'READ ARTICLE' : 'LEARN MORE'}</Link>
</div>
</div>
</NextLink>
)
}

View File

@ -74,7 +74,7 @@
background-position: center center;
background-repeat: no-repeat;
background-size: cover;
height: tovw(1582px, 'default', 1050px);
height: tovw(1582px, 'default', 1120px);
@include respond-to('mobile') {
margin-top: tovw(-60px, 'mobile');